@photonhealth/elements 0.1.1 → 0.1.2
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/index.js +56 -56
- package/dist/index.mjs +737 -734
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
"use strict";const dt={};function i4(e){dt.context=e}const o4=(e,t)=>e===t,wt=Symbol("solid-proxy"),Go=Symbol("solid-track"),il={equals:o4};let ig=cg;const Kn=1,ol=2,og={owned:null,cleanups:null,context:null,owner:null};var Qe=null;let Rr=null,Be=null,Ct=null,jn=null,ah=0;const[a4,uQ]=V(!1);function is(e,t){const n=Be,r=Qe,i=e.length===0,o=i?og:{owned:null,cleanups:null,context:null,owner:t===void 0?r:t},a=i?e:()=>e(()=>H(()=>Ec(o)));Qe=o,Be=null;try{return Zr(a,!0)}finally{Be=n,Qe=r}}function V(e,t){t=t?Object.assign({},il,t):il;const n={value:e,observers:null,observerSlots:null,comparator:t.equals||void 0},r=i=>(typeof i=="function"&&(i=i(n.value)),lg(n,i));return[sg.bind(n),r]}function ag(e,t,n){const r=kc(e,t,!0,Kn);Qi(r)}function q(e,t,n){const r=kc(e,t,!1,Kn);Qi(r)}function me(e,t,n){ig=f4;const r=kc(e,t,!1,Kn);r.user=!0,jn?jn.push(r):Qi(r)}function se(e,t,n){n=n?Object.assign({},il,n):il;const r=kc(e,t,!0,0);return r.observers=null,r.observerSlots=null,r.comparator=n.equals||void 0,Qi(r),sg.bind(r)}function al(e){return Zr(e,!1)}function H(e){if(Be===null)return e();const t=Be;Be=null;try{return e()}finally{Be=t}}function ht(e){me(()=>H(e))}function Gi(e){return Qe===null||(Qe.cleanups===null?Qe.cleanups=[e]:Qe.cleanups.push(e)),e}function xc(){return Be}function A(){return Qe}function s4(e){const t=Be,n=Qe;return Promise.resolve().then(()=>{Be=t,Qe=n;let r;return Zr(e,!1),Be=Qe=null,r?r.done:void 0})}function l4(){return[a4,s4]}function sh(e,t){const n=Symbol("context");return{id:n,Provider:p4(n),defaultValue:e}}function Ki(e){let t;return(t=fg(Qe,e.id))!==void 0?t:e.defaultValue}function c4(e){const t=se(e),n=se(()=>$d(t()));return n.toArray=()=>{const r=n();return Array.isArray(r)?r:r!=null?[r]:[]},n}function sg(){const e=Rr;if(this.sources&&(this.state||e))if(this.state===Kn||e)Qi(this);else{const t=Ct;Ct=null,Zr(()=>ll(this),!1),Ct=t}if(Be){const t=this.observers?this.observers.length:0;Be.sources?(Be.sources.push(this),Be.sourceSlots.push(t)):(Be.sources=[this],Be.sourceSlots=[t]),this.observers?(this.observers.push(Be),this.observerSlots.push(Be.sources.length-1)):(this.observers=[Be],this.observerSlots=[Be.sources.length-1])}return this.value}function lg(e,t,n){let r=e.value;return(!e.comparator||!e.comparator(r,t))&&(e.value=t,e.observers&&e.observers.length&&Zr(()=>{for(let i=0;i<e.observers.length;i+=1){const o=e.observers[i],a=Rr&&Rr.running;a&&Rr.disposed.has(o),(a&&!o.tState||!a&&!o.state)&&(o.pure?Ct.push(o):jn.push(o),o.observers&&ug(o)),a||(o.state=Kn)}if(Ct.length>1e6)throw Ct=[],new Error},!1)),t}function Qi(e){if(!e.fn)return;Ec(e);const t=Qe,n=Be,r=ah;Be=Qe=e,u4(e,e.value,r),Be=n,Qe=t}function u4(e,t,n){let r;try{r=e.fn(t)}catch(i){e.pure&&(e.state=Kn,e.owned&&e.owned.forEach(Ec),e.owned=null),dg(i)}(!e.updatedAt||e.updatedAt<=n)&&(e.updatedAt!=null&&"observers"in e?lg(e,r):e.value=r,e.updatedAt=n)}function kc(e,t,n,r=Kn,i){const o={fn:e,state:r,updatedAt:null,owned:null,sources:null,sourceSlots:null,cleanups:null,value:t,owner:Qe,context:null,pure:n};return Qe===null||Qe!==og&&(Qe.owned?Qe.owned.push(o):Qe.owned=[o]),o}function sl(e){const t=Rr;if(e.state===0||t)return;if(e.state===ol||t)return ll(e);if(e.suspense&&H(e.suspense.inFallback))return e.suspense.effects.push(e);const n=[e];for(;(e=e.owner)&&(!e.updatedAt||e.updatedAt<ah);)(e.state||t)&&n.push(e);for(let r=n.length-1;r>=0;r--)if(e=n[r],e.state===Kn||t)Qi(e);else if(e.state===ol||t){const i=Ct;Ct=null,Zr(()=>ll(e,n[0]),!1),Ct=i}}function Zr(e,t){if(Ct)return e();let n=!1;t||(Ct=[]),jn?n=!0:jn=[],ah++;try{const r=e();return d4(n),r}catch(r){n||(jn=null),Ct=null,dg(r)}}function d4(e){if(Ct&&(cg(Ct),Ct=null),e)return;const t=jn;jn=null,t.length&&Zr(()=>ig(t),!1)}function cg(e){for(let t=0;t<e.length;t++)sl(e[t])}function f4(e){let t,n=0;for(t=0;t<e.length;t++){const r=e[t];r.user?e[n++]=r:sl(r)}for(dt.context&&i4(),t=0;t<n;t++)sl(e[t])}function ll(e,t){const n=Rr;e.state=0;for(let r=0;r<e.sources.length;r+=1){const i=e.sources[r];i.sources&&(i.state===Kn||n?i!==t&&sl(i):(i.state===ol||n)&&ll(i,t))}}function ug(e){const t=Rr;for(let n=0;n<e.observers.length;n+=1){const r=e.observers[n];(!r.state||t)&&(r.state=ol,r.pure?Ct.push(r):jn.push(r),r.observers&&ug(r))}}function Ec(e){let t;if(e.sources)for(;e.sources.length;){const n=e.sources.pop(),r=e.sourceSlots.pop(),i=n.observers;if(i&&i.length){const o=i.pop(),a=n.observerSlots.pop();r<i.length&&(o.sourceSlots[a]=r,i[r]=o,n.observerSlots[r]=a)}}if(e.owned){for(t=0;t<e.owned.length;t++)Ec(e.owned[t]);e.owned=null}if(e.cleanups){for(t=0;t<e.cleanups.length;t++)e.cleanups[t]();e.cleanups=null}e.state=0,e.context=null}function h4(e){return e instanceof Error||typeof e=="string"?e:new Error("Unknown error")}function dg(e){throw e=h4(e),e}function fg(e,t){return e?e.context&&e.context[t]!==void 0?e.context[t]:fg(e.owner,t):void 0}function $d(e){if(typeof e=="function"&&!e.length)return $d(e());if(Array.isArray(e)){const t=[];for(let n=0;n<e.length;n++){const r=$d(e[n]);Array.isArray(r)?t.push.apply(t,r):t.push(r)}return t}return e}function p4(e,t){return function(r){let i;return q(()=>i=H(()=>(Qe.context={[e]:r.value},c4(()=>r.children))),void 0),i}}const m4=Symbol("fallback");function A1(e){for(let t=0;t<e.length;t++)e[t]()}function v4(e,t,n={}){let r=[],i=[],o=[],a=0,s=t.length>1?[]:null;return Gi(()=>A1(o)),()=>{let c=e()||[],l,u;return c[Go],H(()=>{let f=c.length,h,p,m,v,b,y,g,_,x;if(f===0)a!==0&&(A1(o),o=[],r=[],i=[],a=0,s&&(s=[])),n.fallback&&(r=[m4],i[0]=is(O=>(o[0]=O,n.fallback())),a=1);else if(a===0){for(i=new Array(f),u=0;u<f;u++)r[u]=c[u],i[u]=is(d);a=f}else{for(m=new Array(f),v=new Array(f),s&&(b=new Array(f)),y=0,g=Math.min(a,f);y<g&&r[y]===c[y];y++);for(g=a-1,_=f-1;g>=y&&_>=y&&r[g]===c[_];g--,_--)m[_]=i[g],v[_]=o[g],s&&(b[_]=s[g]);for(h=new Map,p=new Array(_+1),u=_;u>=y;u--)x=c[u],l=h.get(x),p[u]=l===void 0?-1:l,h.set(x,u);for(l=y;l<=g;l++)x=r[l],u=h.get(x),u!==void 0&&u!==-1?(m[u]=i[l],v[u]=o[l],s&&(b[u]=s[l]),u=p[u],h.set(x,u)):o[l]();for(u=y;u<f;u++)u in m?(i[u]=m[u],o[u]=v[u],s&&(s[u]=b[u],s[u](u))):i[u]=is(d);i=i.slice(0,a=f),r=c.slice(0)}return i});function d(f){if(o[u]=f,s){const[h,p]=V(u);return s[u]=p,t(c[u],h)}return t(c[u])}}}function S(e,t){return H(()=>e(t||{}))}function Ca(){return!0}const wd={get(e,t,n){return t===wt?n:e.get(t)},has(e,t){return t===wt?!0:e.has(t)},set:Ca,deleteProperty:Ca,getOwnPropertyDescriptor(e,t){return{configurable:!0,enumerable:!0,get(){return e.get(t)},set:Ca,deleteProperty:Ca}},ownKeys(e){return e.keys()}};function iu(e){return(e=typeof e=="function"?e():e)?e:{}}function Nt(...e){let t=!1;for(let r=0;r<e.length;r++){const i=e[r];t=t||!!i&&wt in i,e[r]=typeof i=="function"?(t=!0,se(i)):i}if(t)return new Proxy({get(r){for(let i=e.length-1;i>=0;i--){const o=iu(e[i])[r];if(o!==void 0)return o}},has(r){for(let i=e.length-1;i>=0;i--)if(r in iu(e[i]))return!0;return!1},keys(){const r=[];for(let i=0;i<e.length;i++)r.push(...Object.keys(iu(e[i])));return[...new Set(r)]}},wd);const n={};for(let r=e.length-1;r>=0;r--)if(e[r]){const i=Object.getOwnPropertyDescriptors(e[r]);for(const o in i)o in n||Object.defineProperty(n,o,{enumerable:!0,get(){for(let a=e.length-1;a>=0;a--){const s=(e[a]||{})[o];if(s!==void 0)return s}}})}return n}function Ko(e,...t){const n=new Set(t.flat());if(wt in e){const i=t.map(o=>new Proxy({get(a){return o.includes(a)?e[a]:void 0},has(a){return o.includes(a)&&a in e},keys(){return o.filter(a=>a in e)}},wd));return i.push(new Proxy({get(o){return n.has(o)?void 0:e[o]},has(o){return n.has(o)?!1:o in e},keys(){return Object.keys(e).filter(o=>!n.has(o))}},wd)),i}const r=Object.getOwnPropertyDescriptors(e);return t.push(Object.keys(r).filter(i=>!n.has(i))),t.map(i=>{const o={};for(let a=0;a<i.length;a++){const s=i[a];s in e&&Object.defineProperty(o,s,r[s]?r[s]:{get(){return e[s]},set(){return!0},enumerable:!0})}return o})}let g4=0;function y4(){const e=dt.context;return e?`${e.id}${e.count++}`:`cl-${g4++}`}function sr(e){const t="fallback"in e&&{fallback:()=>e.fallback};return se(v4(()=>e.each,e.children,t||void 0))}function ee(e){let t=!1;const n=e.keyed,r=se(()=>e.when,void 0,{equals:(i,o)=>t?i===o:!i==!o});return se(()=>{const i=r();if(i){const o=e.children,a=typeof o=="function"&&o.length>0;return t=n||a,a?H(()=>o(i)):o}return e.fallback},void 0,void 0)}function b4(e,t,n){let r=n.length,i=t.length,o=r,a=0,s=0,c=t[i-1].nextSibling,l=null;for(;a<i||s<o;){if(t[a]===n[s]){a++,s++;continue}for(;t[i-1]===n[o-1];)i--,o--;if(i===a){const u=o<r?s?n[s-1].nextSibling:n[o-s]:c;for(;s<o;)e.insertBefore(n[s++],u)}else if(o===s)for(;a<i;)(!l||!l.has(t[a]))&&t[a].remove(),a++;else if(t[a]===n[o-1]&&n[s]===t[i-1]){const u=t[--i].nextSibling;e.insertBefore(n[s++],t[a++].nextSibling),e.insertBefore(n[--o],u),t[i]=n[o]}else{if(!l){l=new Map;let d=s;for(;d<o;)l.set(n[d],d++)}const u=l.get(t[a]);if(u!=null)if(s<u&&u<o){let d=a,f=1,h;for(;++d<i&&d<o&&!((h=l.get(t[d]))==null||h!==u+f);)f++;if(f>u-s){const p=t[a];for(;s<u;)e.insertBefore(n[s++],p)}else e.replaceChild(n[s++],t[a++])}else a++;else t[a++].remove()}}}const I1="_$DX_DELEGATE";function T(e,t,n){const r=document.createElement("template");r.innerHTML=e;let i=r.content.firstChild;return n&&(i=i.firstChild),i}function Yi(e,t=window.document){const n=t[I1]||(t[I1]=new Set);for(let r=0,i=e.length;r<i;r++){const o=e[r];n.has(o)||(n.add(o),t.addEventListener(o,x4))}}function $4(e,t,n){n==null?e.removeAttribute(t):e.setAttribute(t,n)}function cl(e,t){t==null?e.removeAttribute("class"):e.className=t}function w4(e,t,n={}){const r=Object.keys(t||{}),i=Object.keys(n);let o,a;for(o=0,a=i.length;o<a;o++){const s=i[o];!s||s==="undefined"||t[s]||(M1(e,s,!1),delete n[s])}for(o=0,a=r.length;o<a;o++){const s=r[o],c=!!t[s];!s||s==="undefined"||n[s]===c||!c||(M1(e,s,!0),n[s]=c)}return n}function _4(e,t,n){if(!t)return n?$4(e,"style"):t;const r=e.style;if(typeof t=="string")return r.cssText=t;typeof n=="string"&&(r.cssText=n=void 0),n||(n={}),t||(t={});let i,o;for(o in n)t[o]==null&&r.removeProperty(o),delete n[o];for(o in t)i=t[o],i!==n[o]&&(r.setProperty(o,i),n[o]=i);return n}function he(e,t,n){return H(()=>e(t,n))}function k(e,t,n,r){if(n!==void 0&&!r&&(r=[]),typeof t!="function")return ul(e,t,r,n);q(i=>ul(e,t(),i,n),r)}function M1(e,t,n){const r=t.trim().split(/\s+/);for(let i=0,o=r.length;i<o;i++)e.classList.toggle(r[i],n)}function x4(e){const t=`$$${e.type}`;let n=e.composedPath&&e.composedPath()[0]||e.target;for(e.target!==n&&Object.defineProperty(e,"target",{configurable:!0,value:n}),Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return n||document}}),dt.registry&&!dt.done&&(dt.done=!0,document.querySelectorAll("[id^=pl-]").forEach(r=>{for(;r&&r.nodeType!==8&&r.nodeValue!=="pl-"+e;){let i=r.nextSibling;r.remove(),r=i}r&&r.remove()}));n;){const r=n[t];if(r&&!n.disabled){const i=n[`${t}Data`];if(i!==void 0?r.call(n,i,e):r.call(n,e),e.cancelBubble)return}n=n._$host||n.parentNode||n.host}}function ul(e,t,n,r,i){for(dt.context&&!n&&(n=[...e.childNodes]);typeof n=="function";)n=n();if(t===n)return n;const o=typeof t,a=r!==void 0;if(e=a&&n[0]&&n[0].parentNode||e,o==="string"||o==="number"){if(dt.context)return n;if(o==="number"&&(t=t.toString()),a){let s=n[0];s&&s.nodeType===3?s.data=t:s=document.createTextNode(t),n=ri(e,n,r,s)}else n!==""&&typeof n=="string"?n=e.firstChild.data=t:n=e.textContent=t}else if(t==null||o==="boolean"){if(dt.context)return n;n=ri(e,n,r)}else{if(o==="function")return q(()=>{let s=t();for(;typeof s=="function";)s=s();n=ul(e,s,n,r)}),()=>n;if(Array.isArray(t)){const s=[],c=n&&Array.isArray(n);if(_d(s,t,n,i))return q(()=>n=ul(e,s,n,r,!0)),()=>n;if(dt.context){if(!s.length)return n;for(let l=0;l<s.length;l++)if(s[l].parentNode)return n=s}if(s.length===0){if(n=ri(e,n,r),a)return n}else c?n.length===0?D1(e,s,r):b4(e,n,s):(n&&ri(e),D1(e,s));n=s}else if(t instanceof Node){if(dt.context&&t.parentNode)return n=a?[t]:t;if(Array.isArray(n)){if(a)return n=ri(e,n,r,t);ri(e,n,null,t)}else n==null||n===""||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}}return n}function _d(e,t,n,r){let i=!1;for(let o=0,a=t.length;o<a;o++){let s=t[o],c=n&&n[o];if(s instanceof Node)e.push(s);else if(!(s==null||s===!0||s===!1))if(Array.isArray(s))i=_d(e,s,c)||i;else if(typeof s=="function")if(r){for(;typeof s=="function";)s=s();i=_d(e,Array.isArray(s)?s:[s],Array.isArray(c)?c:[c])||i}else e.push(s),i=!0;else{const l=String(s);c&&c.nodeType===3&&c.data===l?e.push(c):e.push(document.createTextNode(l))}}return i}function D1(e,t,n=null){for(let r=0,i=t.length;r<i;r++)e.insertBefore(t[r],n)}function ri(e,t,n,r){if(n===void 0)return e.textContent="";const i=r||document.createTextNode("");if(t.length){let o=!1;for(let a=t.length-1;a>=0;a--){const s=t[a];if(i!==s){const c=s.parentNode===e;!o&&!a?c?e.replaceChild(i,s):e.insertBefore(i,n):c&&s.remove()}else o=!0}}else e.insertBefore(i,n);return[i]}function k4(e){return Object.keys(e).reduce((n,r)=>{const i=e[r];return n[r]=Object.assign({},i),pg(i.value)&&!N4(i.value)&&!Array.isArray(i.value)&&(n[r].value=Object.assign({},i.value)),Array.isArray(i.value)&&(n[r].value=i.value.slice(0)),n},{})}function E4(e){return e?Object.keys(e).reduce((n,r)=>{const i=e[r];return n[r]=pg(i)&&"value"in i?i:{value:i},n[r].attribute||(n[r].attribute=C4(r)),n[r].parse="parse"in n[r]?n[r].parse:typeof n[r].value!="string",n},{}):{}}function S4(e){return Object.keys(e).reduce((n,r)=>(n[r]=e[r].value,n),{})}function O4(e,t){const n=k4(t);return Object.keys(t).forEach(i=>{const o=n[i],a=e.getAttribute(o.attribute),s=e[i];a&&(o.value=o.parse?hg(a):a),s!=null&&(o.value=Array.isArray(s)?s.slice(0):s),o.reflect&&L1(e,o.attribute,o.value),Object.defineProperty(e,i,{get(){return o.value},set(c){const l=o.value;o.value=c,o.reflect&&L1(this,o.attribute,o.value);for(let u=0,d=this.__propertyChangedCallbacks.length;u<d;u++)this.__propertyChangedCallbacks[u](i,c,l)},enumerable:!0,configurable:!0})}),n}function hg(e){if(!!e)try{return JSON.parse(e)}catch{return e}}function L1(e,t,n){if(n==null||n===!1)return e.removeAttribute(t);let r=JSON.stringify(n);e.__updating[t]=!0,r==="true"&&(r=""),e.setAttribute(t,r),Promise.resolve().then(()=>delete e.__updating[t])}function C4(e){return e.replace(/\.?([A-Z]+)/g,(t,n)=>"-"+n.toLowerCase()).replace("_","-").replace(/^-/,"")}function pg(e){return e!=null&&(typeof e=="object"||typeof e=="function")}function N4(e){return Object.prototype.toString.call(e)==="[object Function]"}function T4(e){return typeof e=="function"&&e.toString().indexOf("class")===0}let ou;function P4(e,t){const n=Object.keys(t);return class extends e{static get observedAttributes(){return n.map(i=>t[i].attribute)}constructor(){super(),this.__initialized=!1,this.__released=!1,this.__releaseCallbacks=[],this.__propertyChangedCallbacks=[],this.__updating={},this.props={}}connectedCallback(){if(this.__initialized)return;this.__releaseCallbacks=[],this.__propertyChangedCallbacks=[],this.__updating={},this.props=O4(this,t);const i=S4(this.props),o=this.Component,a=ou;try{ou=this,this.__initialized=!0,T4(o)?new o(i,{element:this}):o(i,{element:this})}finally{ou=a}}async disconnectedCallback(){if(await Promise.resolve(),this.isConnected)return;this.__propertyChangedCallbacks.length=0;let i=null;for(;i=this.__releaseCallbacks.pop();)i(this);delete this.__initialized,this.__released=!0}attributeChangedCallback(i,o,a){if(!!this.__initialized&&!this.__updating[i]&&(i=this.lookupProp(i),i in t)){if(a==null&&!this[i])return;this[i]=t[i].parse?hg(a):a}}lookupProp(i){if(!!t)return n.find(o=>i===o||i===t[o].attribute)}get renderRoot(){return this.shadowRoot||this.attachShadow({mode:"open"})}addReleaseCallback(i){this.__releaseCallbacks.push(i)}addPropertyChangedCallback(i){this.__propertyChangedCallbacks.push(i)}}}function A4(e,t={},n={}){const{BaseElement:r=HTMLElement,extension:i}=n;return o=>{if(!e)throw new Error("tag is required to register a Component");let a=customElements.get(e);return a?(a.prototype.Component=o,a):(a=P4(r,E4(t)),a.prototype.Component=o,a.prototype.registeredTag=e,customElements.define(e,a,i),a)}}function I4(e){const t=Object.keys(e),n={};for(let r=0;r<t.length;r++){const[i,o]=V(e[t[r]]);Object.defineProperty(n,t[r],{get:i,set(a){o(()=>a)}})}return n}function M4(e){if(e.assignedSlot&&e.assignedSlot._$owner)return e.assignedSlot._$owner;let t=e.parentNode;for(;t&&!t._$owner&&!(t.assignedSlot&&t.assignedSlot._$owner);)t=t.parentNode;return t&&t.assignedSlot?t.assignedSlot._$owner:e._$owner}function D4(e){return(t,n)=>{const{element:r}=n;return is(i=>{const o=I4(t);r.addPropertyChangedCallback((s,c)=>o[s]=c),r.addReleaseCallback(()=>{r.renderRoot.textContent="",i()});const a=e(o,n);return k(r.renderRoot,a)},M4(r))}}function Me(e,t,n){return arguments.length===2&&(n=t,t={}),A4(e,t)(D4(n))}const mg=sh(),pt=()=>Ki(mg),L4=/[?&]code=[^&]+/,R4=/[?&]state=[^&]+/,F4=/[?&]error=[^&]+/,z4=(e=window.location.search)=>(L4.test(e)||F4.test(e))&&R4.test(e),R1=e=>e.replace(/\w\S*/g,function(t){return t.charAt(0).toUpperCase()+t.substr(1).toLowerCase()}),j4=e=>/^\d+$/.test(e)&&e.length>=5,V4=e=>{const[t,n,r]=e.split("-");return`${n}-${r}-${t}`};var xd=function(e,t){return xd=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},xd(e,t)};function yn(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");xd(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var N=function(){return N=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},N.apply(this,arguments)};function hr(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function fe(e,t,n,r){function i(o){return o instanceof n?o:new n(function(a){a(o)})}return new(n||(n=Promise))(function(o,a){function s(u){try{l(r.next(u))}catch(d){a(d)}}function c(u){try{l(r.throw(u))}catch(d){a(d)}}function l(u){u.done?o(u.value):i(u.value).then(s,c)}l((r=r.apply(e,t||[])).next())})}function nr(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(l){return function(u){return c([l,u])}}function c(l){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(n=0)),n;)try{if(r=1,i&&(o=l[0]&2?i.return:l[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,l[1])).done)return o;switch(i=0,o&&(l=[l[0]&2,o.value]),l[0]){case 0:case 1:o=l;break;case 4:return n.label++,{value:l[1],done:!1};case 5:n.label++,i=l[1],l=[0];continue;case 7:l=n.ops.pop(),n.trys.pop();continue;default:if(o=n.trys,!(o=o.length>0&&o[o.length-1])&&(l[0]===6||l[0]===2)){n=0;continue}if(l[0]===3&&(!o||l[1]>o[0]&&l[1]<o[3])){n.label=l[1];break}if(l[0]===6&&n.label<o[1]){n.label=o[1],o=l;break}if(o&&n.label<o[2]){n.label=o[2],n.ops.push(l);break}o[2]&&n.ops.pop(),n.trys.pop();continue}l=t.call(e,n)}catch(u){l=[6,u],i=0}finally{r=o=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}function dl(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var kd=function(e,t){return kd=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},kd(e,t)};function Jr(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}kd(e,t),e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var pe=function(){return pe=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},pe.apply(this,arguments)};function Ut(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function"){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n}function xe(e,t,n,r){return new(n||(n=Promise))(function(i,o){function a(l){try{c(r.next(l))}catch(u){o(u)}}function s(l){try{c(r.throw(l))}catch(u){o(u)}}function c(l){var u;l.done?i(l.value):(u=l.value,u instanceof n?u:new n(function(d){d(u)})).then(a,s)}c((r=r.apply(e,t||[])).next())})}function ke(e,t){var n,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(c){return function(l){return function(u){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(i=2&u[0]?r.return:u[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,u[1])).done)return i;switch(r=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,r=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(i=a.trys,!((i=i.length>0&&i[i.length-1])||u[0]!==6&&u[0]!==2)){a=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(u[0]===6&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(d){u=[6,d],r=0}finally{n=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([c,l])}}}function Ai(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(t===void 0||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(s){i={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function Ed(e,t,n){if(n||arguments.length===2)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}var Sn=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function lh(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Xi(e,t){return e(t={exports:{}},t.exports),t.exports}var Yn,os,Na=function(e){return e&&e.Math==Math&&e},ve=Na(typeof globalThis=="object"&&globalThis)||Na(typeof window=="object"&&window)||Na(typeof self=="object"&&self)||Na(typeof Sn=="object"&&Sn)||function(){return this}()||Function("return this")(),ze=function(e){try{return!!e()}catch{return!0}},Ae=!ze(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7}),ma=!ze(function(){var e=function(){}.bind();return typeof e!="function"||e.hasOwnProperty("prototype")}),Ta=Function.prototype.call,Dt=ma?Ta.bind(Ta):function(){return Ta.apply(Ta,arguments)},F1={}.propertyIsEnumerable,z1=Object.getOwnPropertyDescriptor,U4=z1&&!F1.call({1:2},1)?function(e){var t=z1(this,e);return!!t&&t.enumerable}:F1,ch={f:U4},Ur=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},vg=Function,gg=vg.prototype,B4=gg.bind,Sd=gg.call,H4=ma&&B4.bind(Sd,Sd),$e=function(e){return e instanceof vg?ma?H4(e):function(){return Sd.apply(e,arguments)}:void 0},q4=$e({}.toString),W4=$e("".slice),Vn=function(e){return W4(q4(e),8,-1)},au=Object,G4=$e("".split),yg=ze(function(){return!au("z").propertyIsEnumerable(0)})?function(e){return Vn(e)=="String"?G4(e,""):au(e)}:au,Zi=function(e){return e==null},K4=TypeError,va=function(e){if(Zi(e))throw K4("Can't call method on "+e);return e},Mn=function(e){return yg(va(e))},su=typeof document=="object"&&document.all,Sc={all:su,IS_HTMLDDA:su===void 0&&su!==void 0},Q4=Sc.all,Re=Sc.IS_HTMLDDA?function(e){return typeof e=="function"||e===Q4}:function(e){return typeof e=="function"},Y4=Sc.all,qe=Sc.IS_HTMLDDA?function(e){return typeof e=="object"?e!==null:Re(e)||e===Y4}:function(e){return typeof e=="object"?e!==null:Re(e)},X4=function(e){return Re(e)?e:void 0},bn=function(e,t){return arguments.length<2?X4(ve[e]):ve[e]&&ve[e][t]},Br=$e({}.isPrototypeOf),lu=bn("navigator","userAgent")||"",j1=ve.process,V1=ve.Deno,U1=j1&&j1.versions||V1&&V1.version,B1=U1&&U1.v8;B1&&(os=(Yn=B1.split("."))[0]>0&&Yn[0]<4?1:+(Yn[0]+Yn[1])),!os&&lu&&(!(Yn=lu.match(/Edge\/(\d+)/))||Yn[1]>=74)&&(Yn=lu.match(/Chrome\/(\d+)/))&&(os=+Yn[1]);var fl=os,Jt=!!Object.getOwnPropertySymbols&&!ze(function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&fl&&fl<41}),uh=Jt&&!Symbol.sham&&typeof Symbol.iterator=="symbol",Z4=Object,Ii=uh?function(e){return typeof e=="symbol"}:function(e){var t=bn("Symbol");return Re(t)&&Br(t.prototype,Z4(e))},J4=String,Ji=function(e){try{return J4(e)}catch{return"Object"}},e7=TypeError,dh=function(e){if(Re(e))return e;throw e7(Ji(e)+" is not a function")},hl=function(e,t){var n=e[t];return Zi(n)?void 0:dh(n)},t7=TypeError,n7=Object.defineProperty,fh=function(e,t){try{n7(ve,e,{value:t,configurable:!0,writable:!0})}catch{ve[e]=t}return t},lr=ve["__core-js_shared__"]||fh("__core-js_shared__",{}),xr=Xi(function(e){(e.exports=function(t,n){return lr[t]||(lr[t]=n!==void 0?n:{})})("versions",[]).push({version:"3.25.4",mode:"global",copyright:"\xA9 2014-2022 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.25.4/LICENSE",source:"https://github.com/zloirock/core-js"})}),r7=Object,eo=function(e){return r7(va(e))},i7=$e({}.hasOwnProperty),oe=Object.hasOwn||function(e,t){return i7(eo(e),t)},o7=0,a7=Math.random(),s7=$e(1 .toString),Mi=function(e){return"Symbol("+(e===void 0?"":e)+")_"+s7(++o7+a7,36)},mo=xr("wks"),Fr=ve.Symbol,H1=Fr&&Fr.for,l7=uh?Fr:Fr&&Fr.withoutSetter||Mi,nt=function(e){if(!oe(mo,e)||!Jt&&typeof mo[e]!="string"){var t="Symbol."+e;Jt&&oe(Fr,e)?mo[e]=Fr[e]:mo[e]=uh&&H1?H1(t):l7(t)}return mo[e]},c7=TypeError,u7=nt("toPrimitive"),d7=function(e,t){if(!qe(e)||Ii(e))return e;var n,r=hl(e,u7);if(r){if(t===void 0&&(t="default"),n=Dt(r,e,t),!qe(n)||Ii(n))return n;throw c7("Can't convert object to primitive value")}return t===void 0&&(t="number"),function(i,o){var a,s;if(o==="string"&&Re(a=i.toString)&&!qe(s=Dt(a,i))||Re(a=i.valueOf)&&!qe(s=Dt(a,i))||o!=="string"&&Re(a=i.toString)&&!qe(s=Dt(a,i)))return s;throw t7("Can't convert object to primitive value")}(e,t)},Hr=function(e){var t=d7(e,"string");return Ii(t)?t:t+""},Od=ve.document,f7=qe(Od)&&qe(Od.createElement),bg=function(e){return f7?Od.createElement(e):{}},$g=!Ae&&!ze(function(){return Object.defineProperty(bg("div"),"a",{get:function(){return 7}}).a!=7}),q1=Object.getOwnPropertyDescriptor,ga={f:Ae?q1:function(e,t){if(e=Mn(e),t=Hr(t),$g)try{return q1(e,t)}catch{}if(oe(e,t))return Ur(!Dt(ch.f,e,t),e[t])}},wg=Ae&&ze(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!=42}),h7=String,p7=TypeError,bt=function(e){if(qe(e))return e;throw p7(h7(e)+" is not an object")},m7=TypeError,cu=Object.defineProperty,v7=Object.getOwnPropertyDescriptor,Pt={f:Ae?wg?function(e,t,n){if(bt(e),t=Hr(t),bt(n),typeof e=="function"&&t==="prototype"&&"value"in n&&"writable"in n&&!n.writable){var r=v7(e,t);r&&r.writable&&(e[t]=n.value,n={configurable:"configurable"in n?n.configurable:r.configurable,enumerable:"enumerable"in n?n.enumerable:r.enumerable,writable:!1})}return cu(e,t,n)}:cu:function(e,t,n){if(bt(e),t=Hr(t),bt(n),$g)try{return cu(e,t,n)}catch{}if("get"in n||"set"in n)throw m7("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},Oc=Ae?function(e,t,n){return Pt.f(e,t,Ur(1,n))}:function(e,t,n){return e[t]=n,e},_g=Function.prototype,g7=Ae&&Object.getOwnPropertyDescriptor,uu=oe(_g,"name"),hh={EXISTS:uu,PROPER:uu&&function(){}.name==="something",CONFIGURABLE:uu&&(!Ae||Ae&&g7(_g,"name").configurable)},y7=$e(Function.toString);Re(lr.inspectSource)||(lr.inspectSource=function(e){return y7(e)});var pl,jo,ml,xg=lr.inspectSource,W1=ve.WeakMap,b7=Re(W1)&&/native code/.test(String(W1)),G1=xr("keys"),Cc=function(e){return G1[e]||(G1[e]=Mi(e))},to={},Cd=ve.TypeError,$7=ve.WeakMap;if(b7||lr.state){var Er=lr.state||(lr.state=new $7),w7=$e(Er.get),K1=$e(Er.has),_7=$e(Er.set);pl=function(e,t){if(K1(Er,e))throw Cd("Object already initialized");return t.facade=e,_7(Er,e,t),t},jo=function(e){return w7(Er,e)||{}},ml=function(e){return K1(Er,e)}}else{var ii=Cc("state");to[ii]=!0,pl=function(e,t){if(oe(e,ii))throw Cd("Object already initialized");return t.facade=e,Oc(e,ii,t),t},jo=function(e){return oe(e,ii)?e[ii]:{}},ml=function(e){return oe(e,ii)}}var nn={set:pl,get:jo,has:ml,enforce:function(e){return ml(e)?jo(e):pl(e,{})},getterFor:function(e){return function(t){var n;if(!qe(t)||(n=jo(t)).type!==e)throw Cd("Incompatible receiver, "+e+" required");return n}}},x7=Xi(function(e){var t=hh.CONFIGURABLE,n=nn.enforce,r=nn.get,i=Object.defineProperty,o=Ae&&!ze(function(){return i(function(){},"length",{value:8}).length!==8}),a=String(String).split("String"),s=e.exports=function(c,l,u){String(l).slice(0,7)==="Symbol("&&(l="["+String(l).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),u&&u.getter&&(l="get "+l),u&&u.setter&&(l="set "+l),(!oe(c,"name")||t&&c.name!==l)&&(Ae?i(c,"name",{value:l,configurable:!0}):c.name=l),o&&u&&oe(u,"arity")&&c.length!==u.arity&&i(c,"length",{value:u.arity});try{u&&oe(u,"constructor")&&u.constructor?Ae&&i(c,"prototype",{writable:!1}):c.prototype&&(c.prototype=void 0)}catch{}var d=n(c);return oe(d,"source")||(d.source=a.join(typeof l=="string"?l:"")),c};Function.prototype.toString=s(function(){return Re(this)&&r(this).source||xg(this)},"toString")}),Rt=function(e,t,n,r){r||(r={});var i=r.enumerable,o=r.name!==void 0?r.name:t;if(Re(n)&&x7(n,o,r),r.global)i?e[t]=n:fh(t,n);else{try{r.unsafe?e[t]&&(i=!0):delete e[t]}catch{}i?e[t]=n:Pt.f(e,t,{value:n,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return e},k7=Math.ceil,E7=Math.floor,S7=Math.trunc||function(e){var t=+e;return(t>0?E7:k7)(t)},ph=function(e){var t=+e;return t!=t||t===0?0:S7(t)},O7=Math.max,C7=Math.min,Nd=function(e,t){var n=ph(e);return n<0?O7(n+t,0):C7(n,t)},N7=Math.min,kg=function(e){return e>0?N7(ph(e),9007199254740991):0},no=function(e){return kg(e.length)},Q1=function(e){return function(t,n,r){var i,o=Mn(t),a=no(o),s=Nd(r,a);if(e&&n!=n){for(;a>s;)if((i=o[s++])!=i)return!0}else for(;a>s;s++)if((e||s in o)&&o[s]===n)return e||s||0;return!e&&-1}},Eg={includes:Q1(!0),indexOf:Q1(!1)},T7=Eg.indexOf,Y1=$e([].push),Sg=function(e,t){var n,r=Mn(e),i=0,o=[];for(n in r)!oe(to,n)&&oe(r,n)&&Y1(o,n);for(;t.length>i;)oe(r,n=t[i++])&&(~T7(o,n)||Y1(o,n));return o},vl=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],P7=vl.concat("length","prototype"),Qo={f:Object.getOwnPropertyNames||function(e){return Sg(e,P7)}},Nc={f:Object.getOwnPropertySymbols},A7=$e([].concat),I7=bn("Reflect","ownKeys")||function(e){var t=Qo.f(bt(e)),n=Nc.f;return n?A7(t,n(e)):t},Og=function(e,t,n){for(var r=I7(t),i=Pt.f,o=ga.f,a=0;a<r.length;a++){var s=r[a];oe(e,s)||n&&oe(n,s)||i(e,s,o(t,s))}},M7=/#|\.prototype\./,ya=function(e,t){var n=L7[D7(e)];return n==F7||n!=R7&&(Re(t)?ze(t):!!t)},D7=ya.normalize=function(e){return String(e).replace(M7,".").toLowerCase()},L7=ya.data={},R7=ya.NATIVE="N",F7=ya.POLYFILL="P",Td=ya,z7=ga.f,$t=function(e,t){var n,r,i,o,a,s=e.target,c=e.global,l=e.stat;if(n=c?ve:l?ve[s]||fh(s,{}):(ve[s]||{}).prototype)for(r in t){if(o=t[r],i=e.dontCallGetSet?(a=z7(n,r))&&a.value:n[r],!Td(c?r:s+(l?".":"#")+r,e.forced)&&i!==void 0){if(typeof o==typeof i)continue;Og(o,i)}(e.sham||i&&i.sham)&&Oc(o,"sham",!0),Rt(n,r,o,e)}},Cg={};Cg[nt("toStringTag")]="z";var du,mh=String(Cg)==="[object z]",j7=nt("toStringTag"),V7=Object,U7=Vn(function(){return arguments}())=="Arguments",ei=mh?Vn:function(e){var t,n,r;return e===void 0?"Undefined":e===null?"Null":typeof(n=function(i,o){try{return i[o]}catch{}}(t=V7(e),j7))=="string"?n:U7?Vn(t):(r=Vn(t))=="Object"&&Re(t.callee)?"Arguments":r},B7=String,Bn=function(e){if(ei(e)==="Symbol")throw TypeError("Cannot convert a Symbol value to a string");return B7(e)},H7=nt("match"),q7=TypeError,Ng=function(e){if(function(t){var n;return qe(t)&&((n=t[H7])!==void 0?!!n:Vn(t)=="RegExp")}(e))throw q7("The method doesn't accept regular expressions");return e},W7=nt("match"),Tg=function(e){var t=/./;try{"/./"[e](t)}catch{try{return t[W7]=!1,"/./"[e](t)}catch{}}return!1},G7=ga.f,X1=$e("".startsWith),K7=$e("".slice),Q7=Math.min,Pg=Tg("startsWith"),Y7=!(Pg||(du=G7(String.prototype,"startsWith"),!du||du.writable));$t({target:"String",proto:!0,forced:!Y7&&!Pg},{startsWith:function(e){var t=Bn(va(this));Ng(e);var n=kg(Q7(arguments.length>1?arguments[1]:void 0,t.length)),r=Bn(e);return X1?X1(t,r,n):K7(t,n,n+r.length)===r}});var vh=function(e,t){return $e(ve[e].prototype[t])};vh("String","startsWith");var gl=Array.isArray||function(e){return Vn(e)=="Array"},X7=TypeError,Z1=function(e){if(e>9007199254740991)throw X7("Maximum allowed index exceeded");return e},Yo=function(e,t,n){var r=Hr(t);r in e?Pt.f(e,r,Ur(0,n)):e[r]=n},Ag=function(){},Z7=[],Ig=bn("Reflect","construct"),gh=/^\s*(?:class|function)\b/,J7=$e(gh.exec),e6=!gh.exec(Ag),vo=function(e){if(!Re(e))return!1;try{return Ig(Ag,Z7,e),!0}catch{return!1}},Mg=function(e){if(!Re(e))return!1;switch(ei(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return e6||!!J7(gh,xg(e))}catch{return!0}};Mg.sham=!0;var J1,yh=!Ig||ze(function(){var e;return vo(vo.call)||!vo(Object)||!vo(function(){e=!0})||e})?Mg:vo,t6=nt("species"),ep=Array,Dg=function(e,t){return new(function(n){var r;return gl(n)&&(r=n.constructor,(yh(r)&&(r===ep||gl(r.prototype))||qe(r)&&(r=r[t6])===null)&&(r=void 0)),r===void 0?ep:r}(e))(t===0?0:t)},n6=nt("species"),Lg=nt("isConcatSpreadable"),r6=fl>=51||!ze(function(){var e=[];return e[Lg]=!1,e.concat()[0]!==e}),i6=(J1="concat",fl>=51||!ze(function(){var e=[];return(e.constructor={})[n6]=function(){return{foo:1}},e[J1](Boolean).foo!==1})),o6=function(e){if(!qe(e))return!1;var t=e[Lg];return t!==void 0?!!t:gl(e)};$t({target:"Array",proto:!0,arity:1,forced:!r6||!i6},{concat:function(e){var t,n,r,i,o,a=eo(this),s=Dg(a,0),c=0;for(t=-1,r=arguments.length;t<r;t++)if(o6(o=t===-1?a:arguments[t]))for(i=no(o),Z1(c+i),n=0;n<i;n++,c++)n in o&&Yo(s,c,o[n]);else Z1(c+1),Yo(s,c++,o);return s.length=c,s}});var a6=mh?{}.toString:function(){return"[object "+ei(this)+"]"};mh||Rt(Object.prototype,"toString",a6,{unsafe:!0});var Pa,bh=Object.keys||function(e){return Sg(e,vl)},s6=Ae&&!wg?Object.defineProperties:function(e,t){bt(e);for(var n,r=Mn(t),i=bh(t),o=i.length,a=0;o>a;)Pt.f(e,n=i[a++],r[n]);return e},Rg={f:s6},l6=bn("document","documentElement"),Fg=Cc("IE_PROTO"),fu=function(){},zg=function(e){return"<script>"+e+"<\/script>"},tp=function(e){e.write(zg("")),e.close();var t=e.parentWindow.Object;return e=null,t},as=function(){try{Pa=new ActiveXObject("htmlfile")}catch{}var e,t;as=typeof document<"u"?document.domain&&Pa?tp(Pa):((t=bg("iframe")).style.display="none",l6.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(zg("document.F=Object")),e.close(),e.F):tp(Pa);for(var n=vl.length;n--;)delete as.prototype[vl[n]];return as()};to[Fg]=!0;var pr=Object.create||function(e,t){var n;return e!==null?(fu.prototype=bt(e),n=new fu,fu.prototype=null,n[Fg]=e):n=as(),t===void 0?n:Rg.f(n,t)},c6=Array,u6=Math.max,jg=Qo.f,Vg=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],d6=function(e){try{return jg(e)}catch{return function(n,r,i){for(var o=no(n),a=Nd(r,o),s=Nd(i===void 0?o:i,o),c=c6(u6(s-a,0)),l=0;a<s;a++,l++)Yo(c,l,n[a]);return c.length=l,c}(Vg)}},$h={f:function(e){return Vg&&Vn(e)=="Window"?d6(e):jg(Mn(e))}},Ug={f:nt},Xo=ve,f6=Pt.f,Bt=function(e){var t=Xo.Symbol||(Xo.Symbol={});oe(t,e)||f6(t,e,{value:Ug.f(e)})},Bg=function(){var e=bn("Symbol"),t=e&&e.prototype,n=t&&t.valueOf,r=nt("toPrimitive");t&&!t[r]&&Rt(t,r,function(i){return Dt(n,this)},{arity:1})},h6=Pt.f,np=nt("toStringTag"),ar=function(e,t,n){e&&!n&&(e=e.prototype),e&&!oe(e,np)&&h6(e,np,{configurable:!0,value:t})},p6=$e($e.bind),Tc=function(e,t){return dh(e),t===void 0?e:ma?p6(e,t):function(){return e.apply(t,arguments)}},rp=$e([].push),Xn=function(e){var t=e==1,n=e==2,r=e==3,i=e==4,o=e==6,a=e==7,s=e==5||o;return function(c,l,u,d){for(var f,h,p=eo(c),m=yg(p),v=Tc(l,u),b=no(m),y=0,g=d||Dg,_=t?g(c,b):n||a?g(c,0):void 0;b>y;y++)if((s||y in m)&&(h=v(f=m[y],y,p),e))if(t)_[y]=h;else if(h)switch(e){case 3:return!0;case 5:return f;case 6:return y;case 2:rp(_,f)}else switch(e){case 4:return!1;case 7:rp(_,f)}return o?-1:r||i?i:_}},Pc={forEach:Xn(0),map:Xn(1),filter:Xn(2),some:Xn(3),every:Xn(4),find:Xn(5),findIndex:Xn(6),filterReject:Xn(7)}.forEach,Ht=Cc("hidden"),m6=nn.set,ip=nn.getterFor("Symbol"),tn=Object.prototype,yi=ve.Symbol,Mo=yi&&yi.prototype,v6=ve.TypeError,hu=ve.QObject,Hg=ga.f,ir=Pt.f,qg=$h.f,g6=ch.f,Wg=$e([].push),Hn=xr("symbols"),ba=xr("op-symbols"),y6=xr("wks"),pu=!hu||!hu.prototype||!hu.prototype.findChild,Pd=Ae&&ze(function(){return pr(ir({},"a",{get:function(){return ir(this,"a",{value:7}).a}})).a!=7})?function(e,t,n){var r=Hg(tn,t);r&&delete tn[t],ir(e,t,n),r&&e!==tn&&ir(tn,t,r)}:ir,mu=function(e,t){var n=Hn[e]=pr(Mo);return m6(n,{type:"Symbol",tag:e,description:t}),Ae||(n.description=t),n},yl=function(e,t,n){e===tn&&yl(ba,t,n),bt(e);var r=Hr(t);return bt(n),oe(Hn,r)?(n.enumerable?(oe(e,Ht)&&e[Ht][r]&&(e[Ht][r]=!1),n=pr(n,{enumerable:Ur(0,!1)})):(oe(e,Ht)||ir(e,Ht,Ur(1,{})),e[Ht][r]=!0),Pd(e,r,n)):ir(e,r,n)},vu=function(e,t){bt(e);var n=Mn(t),r=bh(n).concat(Gg(n));return Pc(r,function(i){Ae&&!Dt(Ad,n,i)||yl(e,i,n[i])}),e},Ad=function(e){var t=Hr(e),n=Dt(g6,this,t);return!(this===tn&&oe(Hn,t)&&!oe(ba,t))&&(!(n||!oe(this,t)||!oe(Hn,t)||oe(this,Ht)&&this[Ht][t])||n)},op=function(e,t){var n=Mn(e),r=Hr(t);if(n!==tn||!oe(Hn,r)||oe(ba,r)){var i=Hg(n,r);return!i||!oe(Hn,r)||oe(n,Ht)&&n[Ht][r]||(i.enumerable=!0),i}},ap=function(e){var t=qg(Mn(e)),n=[];return Pc(t,function(r){oe(Hn,r)||oe(to,r)||Wg(n,r)}),n},Gg=function(e){var t=e===tn,n=qg(t?ba:Mn(e)),r=[];return Pc(n,function(i){!oe(Hn,i)||t&&!oe(tn,i)||Wg(r,Hn[i])}),r};Jt||(Mo=(yi=function(){if(Br(Mo,this))throw v6("Symbol is not a constructor");var e=arguments.length&&arguments[0]!==void 0?Bn(arguments[0]):void 0,t=Mi(e),n=function(r){this===tn&&Dt(n,ba,r),oe(this,Ht)&&oe(this[Ht],t)&&(this[Ht][t]=!1),Pd(this,t,Ur(1,r))};return Ae&&pu&&Pd(tn,t,{configurable:!0,set:n}),mu(t,e)}).prototype,Rt(Mo,"toString",function(){return ip(this).tag}),Rt(yi,"withoutSetter",function(e){return mu(Mi(e),e)}),ch.f=Ad,Pt.f=yl,Rg.f=vu,ga.f=op,Qo.f=$h.f=ap,Nc.f=Gg,Ug.f=function(e){return mu(nt(e),e)},Ae&&(ir(Mo,"description",{configurable:!0,get:function(){return ip(this).description}}),Rt(tn,"propertyIsEnumerable",Ad,{unsafe:!0}))),$t({global:!0,constructor:!0,wrap:!0,forced:!Jt,sham:!Jt},{Symbol:yi}),Pc(bh(y6),function(e){Bt(e)}),$t({target:"Symbol",stat:!0,forced:!Jt},{useSetter:function(){pu=!0},useSimple:function(){pu=!1}}),$t({target:"Object",stat:!0,forced:!Jt,sham:!Ae},{create:function(e,t){return t===void 0?pr(e):vu(pr(e),t)},defineProperty:yl,defineProperties:vu,getOwnPropertyDescriptor:op}),$t({target:"Object",stat:!0,forced:!Jt},{getOwnPropertyNames:ap}),Bg(),ar(yi,"Symbol"),to[Ht]=!0;var Kg=Jt&&!!Symbol.for&&!!Symbol.keyFor,gu=xr("string-to-symbol-registry"),b6=xr("symbol-to-string-registry");$t({target:"Symbol",stat:!0,forced:!Kg},{for:function(e){var t=Bn(e);if(oe(gu,t))return gu[t];var n=bn("Symbol")(t);return gu[t]=n,b6[n]=t,n}});var sp=xr("symbol-to-string-registry");$t({target:"Symbol",stat:!0,forced:!Kg},{keyFor:function(e){if(!Ii(e))throw TypeError(Ji(e)+" is not a symbol");if(oe(sp,e))return sp[e]}});var Qg=Function.prototype,lp=Qg.apply,cp=Qg.call,Yg=typeof Reflect=="object"&&Reflect.apply||(ma?cp.bind(lp):function(){return cp.apply(lp,arguments)}),wh=$e([].slice),cr=bn("JSON","stringify"),Aa=$e(/./.exec),up=$e("".charAt),$6=$e("".charCodeAt),w6=$e("".replace),_6=$e(1 .toString),x6=/[\uD800-\uDFFF]/g,dp=/^[\uD800-\uDBFF]$/,fp=/^[\uDC00-\uDFFF]$/,hp=!Jt||ze(function(){var e=bn("Symbol")();return cr([e])!="[null]"||cr({a:e})!="{}"||cr(Object(e))!="{}"}),pp=ze(function(){return cr("\uDF06\uD834")!=='"\\udf06\\ud834"'||cr("\uDEAD")!=='"\\udead"'}),k6=function(e,t){var n=wh(arguments),r=t;if((qe(t)||e!==void 0)&&!Ii(e))return gl(t)||(t=function(i,o){if(Re(r)&&(o=Dt(r,this,i,o)),!Ii(o))return o}),n[1]=t,Yg(cr,null,n)},E6=function(e,t,n){var r=up(n,t-1),i=up(n,t+1);return Aa(dp,e)&&!Aa(fp,i)||Aa(fp,e)&&!Aa(dp,r)?"\\u"+_6($6(e,0),16):e};cr&&$t({target:"JSON",stat:!0,arity:3,forced:hp||pp},{stringify:function(e,t,n){var r=wh(arguments),i=Yg(hp?k6:cr,null,r);return pp&&typeof i=="string"?w6(i,x6,E6):i}});var S6=!Jt||ze(function(){Nc.f(1)});$t({target:"Object",stat:!0,forced:S6},{getOwnPropertySymbols:function(e){var t=Nc.f;return t?t(eo(e)):[]}}),Bt("asyncIterator");var O6=Pt.f,Fn=ve.Symbol,Sr=Fn&&Fn.prototype;if(Ae&&Re(Fn)&&(!("description"in Sr)||Fn().description!==void 0)){var mp={},Ia=function(){var e=arguments.length<1||arguments[0]===void 0?void 0:Bn(arguments[0]),t=Br(Sr,this)?new Fn(e):e===void 0?Fn():Fn(e);return e===""&&(mp[t]=!0),t};Og(Ia,Fn),Ia.prototype=Sr,Sr.constructor=Ia;var C6=String(Fn("test"))=="Symbol(test)",N6=$e(Sr.valueOf),T6=$e(Sr.toString),P6=/^Symbol\((.*)\)[^)]+$/,A6=$e("".replace),I6=$e("".slice);O6(Sr,"description",{configurable:!0,get:function(){var e=N6(this);if(oe(mp,e))return"";var t=T6(e),n=C6?I6(t,7,-1):A6(t,P6,"$1");return n===""?void 0:n}}),$t({global:!0,constructor:!0,forced:!0},{Symbol:Ia})}Bt("hasInstance"),Bt("isConcatSpreadable"),Bt("iterator"),Bt("match"),Bt("matchAll"),Bt("replace"),Bt("search"),Bt("species"),Bt("split"),Bt("toPrimitive"),Bg(),Bt("toStringTag"),ar(bn("Symbol"),"Symbol"),Bt("unscopables"),ar(ve.JSON,"JSON",!0),ar(Math,"Math",!0),$t({global:!0},{Reflect:{}}),ar(ve.Reflect,"Reflect",!0),Xo.Symbol;var zr,vp,gp,M6=$e("".charAt),yp=$e("".charCodeAt),D6=$e("".slice),bp=function(e){return function(t,n){var r,i,o=Bn(va(t)),a=ph(n),s=o.length;return a<0||a>=s?e?"":void 0:(r=yp(o,a))<55296||r>56319||a+1===s||(i=yp(o,a+1))<56320||i>57343?e?M6(o,a):r:e?D6(o,a,a+2):i-56320+(r-55296<<10)+65536}},L6={codeAt:bp(!1),charAt:bp(!0)},R6=!ze(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}),$p=Cc("IE_PROTO"),Id=Object,F6=Id.prototype,mr=R6?Id.getPrototypeOf:function(e){var t=eo(e);if(oe(t,$p))return t[$p];var n=t.constructor;return Re(n)&&t instanceof n?n.prototype:t instanceof Id?F6:null},Md=nt("iterator"),Xg=!1;[].keys&&("next"in(gp=[].keys())?(vp=mr(mr(gp)))!==Object.prototype&&(zr=vp):Xg=!0);var z6=!qe(zr)||ze(function(){var e={};return zr[Md].call(e)!==e});z6&&(zr={}),Re(zr[Md])||Rt(zr,Md,function(){return this});var _h={IteratorPrototype:zr,BUGGY_SAFARI_ITERATORS:Xg},Di={},j6=_h.IteratorPrototype,V6=function(){return this},U6=String,B6=TypeError,Tn=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,n={};try{(e=$e(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),t=n instanceof Array}catch{}return function(r,i){return bt(r),function(o){if(typeof o=="object"||Re(o))return o;throw B6("Can't set "+U6(o)+" as a prototype")}(i),t?e(r,i):r.__proto__=i,r}}():void 0),H6=hh.PROPER,q6=hh.CONFIGURABLE,wp=_h.IteratorPrototype,Ma=_h.BUGGY_SAFARI_ITERATORS,go=nt("iterator"),W6=function(){return this},xh=function(e,t,n,r,i,o,a){(function(b,y,g,_){var x=y+" Iterator";b.prototype=pr(j6,{next:Ur(+!_,g)}),ar(b,x,!1),Di[x]=V6})(n,t,r);var s,c,l,u=function(b){if(b===i&&m)return m;if(!Ma&&b in h)return h[b];switch(b){case"keys":case"values":case"entries":return function(){return new n(this,b)}}return function(){return new n(this)}},d=t+" Iterator",f=!1,h=e.prototype,p=h[go]||h["@@iterator"]||i&&h[i],m=!Ma&&p||u(i),v=t=="Array"&&h.entries||p;if(v&&(s=mr(v.call(new e)))!==Object.prototype&&s.next&&(mr(s)!==wp&&(Tn?Tn(s,wp):Re(s[go])||Rt(s,go,W6)),ar(s,d,!0)),H6&&i=="values"&&p&&p.name!=="values"&&(q6?Oc(h,"name","values"):(f=!0,m=function(){return Dt(p,this)})),i)if(c={values:u("values"),keys:o?m:u("keys"),entries:u("entries")},a)for(l in c)(Ma||f||!(l in h))&&Rt(h,l,c[l]);else $t({target:t,proto:!0,forced:Ma||f},c);return h[go]!==m&&Rt(h,go,m,{name:i}),Di[t]=m,c},Li=function(e,t){return{value:e,done:t}},G6=L6.charAt,K6=nn.set,Q6=nn.getterFor("String Iterator");xh(String,"String",function(e){K6(this,{type:"String Iterator",string:Bn(e),index:0})},function(){var e,t=Q6(this),n=t.string,r=t.index;return r>=n.length?Li(void 0,!0):(e=G6(n,r),t.index+=e.length,Li(e,!1))});var Dd=function(e,t,n){var r,i;bt(e);try{if(!(r=hl(e,"return"))){if(t==="throw")throw n;return n}r=Dt(r,e)}catch(o){i=!0,r=o}if(t==="throw")throw n;if(i)throw r;return bt(r),n},Y6=function(e,t,n,r){try{return r?t(bt(n)[0],n[1]):t(n)}catch(i){Dd(e,"throw",i)}},X6=nt("iterator"),Z6=Array.prototype,Zg=function(e){return e!==void 0&&(Di.Array===e||Z6[X6]===e)},J6=nt("iterator"),kh=function(e){if(!Zi(e))return hl(e,J6)||hl(e,"@@iterator")||Di[ei(e)]},e8=TypeError,Jg=function(e,t){var n=arguments.length<2?kh(e):t;if(dh(n))return bt(Dt(n,e));throw e8(Ji(e)+" is not iterable")},_p=Array,ey=nt("iterator"),ty=!1;try{var t8=0,xp={next:function(){return{done:!!t8++}},return:function(){ty=!0}};xp[ey]=function(){return this},Array.from(xp,function(){throw 2})}catch{}var ny=function(e,t){if(!t&&!ty)return!1;var n=!1;try{var r={};r[ey]=function(){return{next:function(){return{done:n=!0}}}},e(r)}catch{}return n},n8=!ny(function(e){Array.from(e)});$t({target:"Array",stat:!0,forced:n8},{from:function(e){var t=eo(e),n=yh(this),r=arguments.length,i=r>1?arguments[1]:void 0,o=i!==void 0;o&&(i=Tc(i,r>2?arguments[2]:void 0));var a,s,c,l,u,d,f=kh(t),h=0;if(!f||this===_p&&Zg(f))for(a=no(t),s=n?new this(a):_p(a);a>h;h++)d=o?i(t[h],h):t[h],Yo(s,h,d);else for(u=(l=Jg(t,f)).next,s=n?new this:[];!(c=Dt(u,l)).done;h++)d=o?Y6(l,i,[c.value,h],!0):c.value,Yo(s,h,d);return s.length=h,s}}),Xo.Array.from;var qt,Ei,bl,r8=typeof ArrayBuffer<"u"&&typeof DataView<"u",i8=Pt.f,ry=nn.enforce,o8=nn.get,$l=ve.Int8Array,Ld=$l&&$l.prototype,kp=ve.Uint8ClampedArray,Ep=kp&&kp.prototype,xn=$l&&mr($l),hn=Ld&&mr(Ld),a8=Object.prototype,Rd=ve.TypeError,Sp=nt("toStringTag"),Fd=Mi("TYPED_ARRAY_TAG"),Un=r8&&!!Tn&&ei(ve.opera)!=="Opera",iy=!1,zn={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},Eh={BigInt64Array:8,BigUint64Array:8},oy=function(e){var t=mr(e);if(qe(t)){var n=o8(t);return n&&oe(n,"TypedArrayConstructor")?n.TypedArrayConstructor:oy(t)}},Op=function(e){if(!qe(e))return!1;var t=ei(e);return oe(zn,t)||oe(Eh,t)};for(qt in zn)(bl=(Ei=ve[qt])&&Ei.prototype)?ry(bl).TypedArrayConstructor=Ei:Un=!1;for(qt in Eh)(bl=(Ei=ve[qt])&&Ei.prototype)&&(ry(bl).TypedArrayConstructor=Ei);if((!Un||!Re(xn)||xn===Function.prototype)&&(xn=function(){throw Rd("Incorrect invocation")},Un))for(qt in zn)ve[qt]&&Tn(ve[qt],xn);if((!Un||!hn||hn===a8)&&(hn=xn.prototype,Un))for(qt in zn)ve[qt]&&Tn(ve[qt].prototype,hn);if(Un&&mr(Ep)!==hn&&Tn(Ep,hn),Ae&&!oe(hn,Sp))for(qt in iy=!0,i8(hn,Sp,{get:function(){return qe(this)?this[Fd]:void 0}}),zn)ve[qt]&&Oc(ve[qt],Fd,qt);var Ac={NATIVE_ARRAY_BUFFER_VIEWS:Un,TYPED_ARRAY_TAG:iy&&Fd,aTypedArray:function(e){if(Op(e))return e;throw Rd("Target is not a typed array")},aTypedArrayConstructor:function(e){if(Re(e)&&(!Tn||Br(xn,e)))return e;throw Rd(Ji(e)+" is not a typed array constructor")},exportTypedArrayMethod:function(e,t,n,r){if(Ae){if(n)for(var i in zn){var o=ve[i];if(o&&oe(o.prototype,e))try{delete o.prototype[e]}catch{try{o.prototype[e]=t}catch{}}}hn[e]&&!n||Rt(hn,e,n?t:Un&&Ld[e]||t,r)}},exportTypedArrayStaticMethod:function(e,t,n){var r,i;if(Ae){if(Tn){if(n){for(r in zn)if((i=ve[r])&&oe(i,e))try{delete i[e]}catch{}}if(xn[e]&&!n)return;try{return Rt(xn,e,n?t:Un&&xn[e]||t)}catch{}}for(r in zn)!(i=ve[r])||i[e]&&!n||Rt(i,e,t)}},getTypedArrayConstructor:oy,isView:function(e){if(!qe(e))return!1;var t=ei(e);return t==="DataView"||oe(zn,t)||oe(Eh,t)},isTypedArray:Op,TypedArray:xn,TypedArrayPrototype:hn},s8=TypeError,l8=nt("species"),c8=function(e,t){var n,r=bt(e).constructor;return r===void 0||Zi(n=bt(r)[l8])?t:function(i){if(yh(i))return i;throw s8(Ji(i)+" is not a constructor")}(n)},u8=Ac.aTypedArrayConstructor,d8=Ac.getTypedArrayConstructor,f8=Ac.aTypedArray;(0,Ac.exportTypedArrayMethod)("slice",function(e,t){for(var n,r=wh(f8(this),e,t),i=u8(c8(n=this,d8(n))),o=0,a=r.length,s=new i(a);a>o;)s[o]=r[o++];return s},ze(function(){new Int8Array(1).slice()}));var h8=Pt.f,zd=nt("unscopables"),jd=Array.prototype;jd[zd]==null&&h8(jd,zd,{configurable:!0,value:pr(null)});var ss=function(e){jd[zd][e]=!0},p8=Eg.includes,m8=ze(function(){return!Array(1).includes()});$t({target:"Array",proto:!0,forced:m8},{includes:function(e){return p8(this,e,arguments.length>1?arguments[1]:void 0)}}),ss("includes"),vh("Array","includes");var v8=$e("".indexOf);$t({target:"String",proto:!0,forced:!Tg("includes")},{includes:function(e){return!!~v8(Bn(va(this)),Bn(Ng(e)),arguments.length>1?arguments[1]:void 0)}}),vh("String","includes");var g8=Pt.f,y8=nn.set,b8=nn.getterFor("Array Iterator");xh(Array,"Array",function(e,t){y8(this,{type:"Array Iterator",target:Mn(e),index:0,kind:t})},function(){var e=b8(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?(e.target=void 0,Li(void 0,!0)):Li(n=="keys"?r:n=="values"?t[r]:[r,t[r]],!1)},"values");var Cp=Di.Arguments=Di.Array;if(ss("keys"),ss("values"),ss("entries"),Ae&&Cp.name!=="values")try{g8(Cp,"name",{value:"values"})}catch{}var Np=ze(function(){if(typeof ArrayBuffer=="function"){var e=new ArrayBuffer(8);Object.isExtensible(e)&&Object.defineProperty(e,"a",{value:8})}}),Da=Object.isExtensible,yu=ze(function(){Da(1)})||Np?function(e){return!!qe(e)&&(!Np||Vn(e)!="ArrayBuffer")&&(!Da||Da(e))}:Da,$8=!ze(function(){return Object.isExtensible(Object.preventExtensions({}))}),bi=Xi(function(e){var t=Pt.f,n=!1,r=Mi("meta"),i=0,o=function(s){t(s,r,{value:{objectID:"O"+i++,weakData:{}}})},a=e.exports={enable:function(){a.enable=function(){},n=!0;var s=Qo.f,c=$e([].splice),l={};l[r]=1,s(l).length&&(Qo.f=function(u){for(var d=s(u),f=0,h=d.length;f<h;f++)if(d[f]===r){c(d,f,1);break}return d},$t({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:$h.f}))},fastKey:function(s,c){if(!qe(s))return typeof s=="symbol"?s:(typeof s=="string"?"S":"P")+s;if(!oe(s,r)){if(!yu(s))return"F";if(!c)return"E";o(s)}return s[r].objectID},getWeakData:function(s,c){if(!oe(s,r)){if(!yu(s))return!0;if(!c)return!1;o(s)}return s[r].weakData},onFreeze:function(s){return $8&&n&&yu(s)&&!oe(s,r)&&o(s),s}};to[r]=!0});bi.enable,bi.fastKey,bi.getWeakData,bi.onFreeze;var w8=TypeError,ls=function(e,t){this.stopped=e,this.result=t},Tp=ls.prototype,ay=function(e,t,n){var r,i,o,a,s,c,l,u=n&&n.that,d=!(!n||!n.AS_ENTRIES),f=!(!n||!n.IS_RECORD),h=!(!n||!n.IS_ITERATOR),p=!(!n||!n.INTERRUPTED),m=Tc(t,u),v=function(y){return r&&Dd(r,"normal",y),new ls(!0,y)},b=function(y){return d?(bt(y),p?m(y[0],y[1],v):m(y[0],y[1])):p?m(y,v):m(y)};if(f)r=e.iterator;else if(h)r=e;else{if(!(i=kh(e)))throw w8(Ji(e)+" is not iterable");if(Zg(i)){for(o=0,a=no(e);a>o;o++)if((s=b(e[o]))&&Br(Tp,s))return s;return new ls(!1)}r=Jg(e,i)}for(c=f?e.next:r.next;!(l=Dt(c,r)).done;){try{s=b(l.value)}catch(y){Dd(r,"throw",y)}if(typeof s=="object"&&s&&Br(Tp,s))return s}return new ls(!1)},_8=TypeError,sy=function(e,t){if(Br(t,e))return e;throw _8("Incorrect invocation")},Pp=function(e,t,n){for(var r in t)Rt(e,r,t[r],n);return e},Ap=nt("species"),x8=Pt.f,Ip=bi.fastKey,Mp=nn.set,bu=nn.getterFor,k8={getConstructor:function(e,t,n,r){var i=e(function(l,u){sy(l,o),Mp(l,{type:t,index:pr(null),first:void 0,last:void 0,size:0}),Ae||(l.size=0),Zi(u)||ay(u,l[r],{that:l,AS_ENTRIES:n})}),o=i.prototype,a=bu(t),s=function(l,u,d){var f,h,p=a(l),m=c(l,u);return m?m.value=d:(p.last=m={index:h=Ip(u,!0),key:u,value:d,previous:f=p.last,next:void 0,removed:!1},p.first||(p.first=m),f&&(f.next=m),Ae?p.size++:l.size++,h!=="F"&&(p.index[h]=m)),l},c=function(l,u){var d,f=a(l),h=Ip(u);if(h!=="F")return f.index[h];for(d=f.first;d;d=d.next)if(d.key==u)return d};return Pp(o,{clear:function(){for(var l=a(this),u=l.index,d=l.first;d;)d.removed=!0,d.previous&&(d.previous=d.previous.next=void 0),delete u[d.index],d=d.next;l.first=l.last=void 0,Ae?l.size=0:this.size=0},delete:function(l){var u=this,d=a(u),f=c(u,l);if(f){var h=f.next,p=f.previous;delete d.index[f.index],f.removed=!0,p&&(p.next=h),h&&(h.previous=p),d.first==f&&(d.first=h),d.last==f&&(d.last=p),Ae?d.size--:u.size--}return!!f},forEach:function(l){for(var u,d=a(this),f=Tc(l,arguments.length>1?arguments[1]:void 0);u=u?u.next:d.first;)for(f(u.value,u.key,this);u&&u.removed;)u=u.previous},has:function(l){return!!c(this,l)}}),Pp(o,n?{get:function(l){var u=c(this,l);return u&&u.value},set:function(l,u){return s(this,l===0?0:l,u)}}:{add:function(l){return s(this,l=l===0?0:l,l)}}),Ae&&x8(o,"size",{get:function(){return a(this).size}}),i},setStrong:function(e,t,n){var r=t+" Iterator",i=bu(t),o=bu(r);xh(e,t,function(a,s){Mp(this,{type:r,target:a,state:i(a),kind:s,last:void 0})},function(){for(var a=o(this),s=a.kind,c=a.last;c&&c.removed;)c=c.previous;return a.target&&(a.last=c=c?c.next:a.state.first)?Li(s=="keys"?c.key:s=="values"?c.value:[c.key,c.value],!1):(a.target=void 0,Li(void 0,!0))},n?"entries":"values",!n,!0),function(a){var s=bn(a),c=Pt.f;Ae&&s&&!s[Ap]&&c(s,Ap,{configurable:!0,get:function(){return this}})}(t)}};function ly(e){var t=this.constructor;return this.then(function(n){return t.resolve(e()).then(function(){return n})},function(n){return t.resolve(e()).then(function(){return t.reject(n)})})}function cy(e){return new this(function(t,n){if(!e||e.length===void 0)return n(new TypeError(typeof e+" "+e+" is not iterable(cannot read property Symbol(Symbol.iterator))"));var r=Array.prototype.slice.call(e);if(r.length===0)return t([]);var i=r.length;function o(s,c){if(c&&(typeof c=="object"||typeof c=="function")){var l=c.then;if(typeof l=="function")return void l.call(c,function(u){o(s,u)},function(u){r[s]={status:"rejected",reason:u},--i==0&&t(r)})}r[s]={status:"fulfilled",value:c},--i==0&&t(r)}for(var a=0;a<r.length;a++)o(a,r[a])})}(function(e,t,n){var r=e.indexOf("Map")!==-1,i=e.indexOf("Weak")!==-1,o=r?"set":"add",a=ve[e],s=a&&a.prototype,c=a,l={},u=function(v){var b=$e(s[v]);Rt(s,v,v=="add"?function(y){return b(this,y===0?0:y),this}:v=="delete"?function(y){return!(i&&!qe(y))&&b(this,y===0?0:y)}:v=="get"?function(y){return i&&!qe(y)?void 0:b(this,y===0?0:y)}:v=="has"?function(y){return!(i&&!qe(y))&&b(this,y===0?0:y)}:function(y,g){return b(this,y===0?0:y,g),this})};if(Td(e,!Re(a)||!(i||s.forEach&&!ze(function(){new a().entries().next()}))))c=n.getConstructor(t,e,r,o),bi.enable();else if(Td(e,!0)){var d=new c,f=d[o](i?{}:-0,1)!=d,h=ze(function(){d.has(1)}),p=ny(function(v){new a(v)}),m=!i&&ze(function(){for(var v=new a,b=5;b--;)v[o](b,b);return!v.has(-0)});p||((c=t(function(v,b){sy(v,s);var y=function(g,_,x){var O,C;return Tn&&Re(O=_.constructor)&&O!==x&&qe(C=O.prototype)&&C!==x.prototype&&Tn(g,C),g}(new a,v,c);return Zi(b)||ay(b,y[o],{that:y,AS_ENTRIES:r}),y})).prototype=s,s.constructor=c),(h||m)&&(u("delete"),u("has"),r&&u("get")),(m||f)&&u(o),i&&s.clear&&delete s.clear}l[e]=c,$t({global:!0,constructor:!0,forced:c!=a},l),ar(c,e),i||n.setStrong(c,e,r)})("Set",function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},k8),Xo.Set;var E8=setTimeout;function Dp(e){return Boolean(e&&e.length!==void 0)}function S8(){}function Ke(e){if(!(this instanceof Ke))throw new TypeError("Promises must be constructed via new");if(typeof e!="function")throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],dy(e,this)}function uy(e,t){for(;e._state===3;)e=e._value;e._state!==0?(e._handled=!0,Ke._immediateFn(function(){var n=e._state===1?t.onFulfilled:t.onRejected;if(n!==null){var r;try{r=n(e._value)}catch(i){return void Zo(t.promise,i)}Vd(t.promise,r)}else(e._state===1?Vd:Zo)(t.promise,e._value)})):e._deferreds.push(t)}function Vd(e,t){try{if(t===e)throw new TypeError("A promise cannot be resolved with itself.");if(t&&(typeof t=="object"||typeof t=="function")){var n=t.then;if(t instanceof Ke)return e._state=3,e._value=t,void Ud(e);if(typeof n=="function")return void dy((r=n,i=t,function(){r.apply(i,arguments)}),e)}e._state=1,e._value=t,Ud(e)}catch(o){Zo(e,o)}var r,i}function Zo(e,t){e._state=2,e._value=t,Ud(e)}function Ud(e){e._state===2&&e._deferreds.length===0&&Ke._immediateFn(function(){e._handled||Ke._unhandledRejectionFn(e._value)});for(var t=0,n=e._deferreds.length;t<n;t++)uy(e,e._deferreds[t]);e._deferreds=null}function O8(e,t,n){this.onFulfilled=typeof e=="function"?e:null,this.onRejected=typeof t=="function"?t:null,this.promise=n}function dy(e,t){var n=!1;try{e(function(r){n||(n=!0,Vd(t,r))},function(r){n||(n=!0,Zo(t,r))})}catch(r){if(n)return;n=!0,Zo(t,r)}}Ke.prototype.catch=function(e){return this.then(null,e)},Ke.prototype.then=function(e,t){var n=new this.constructor(S8);return uy(this,new O8(e,t,n)),n},Ke.prototype.finally=ly,Ke.all=function(e){return new Ke(function(t,n){if(!Dp(e))return n(new TypeError("Promise.all accepts an array"));var r=Array.prototype.slice.call(e);if(r.length===0)return t([]);var i=r.length;function o(s,c){try{if(c&&(typeof c=="object"||typeof c=="function")){var l=c.then;if(typeof l=="function")return void l.call(c,function(u){o(s,u)},n)}r[s]=c,--i==0&&t(r)}catch(u){n(u)}}for(var a=0;a<r.length;a++)o(a,r[a])})},Ke.allSettled=cy,Ke.resolve=function(e){return e&&typeof e=="object"&&e.constructor===Ke?e:new Ke(function(t){t(e)})},Ke.reject=function(e){return new Ke(function(t,n){n(e)})},Ke.race=function(e){return new Ke(function(t,n){if(!Dp(e))return n(new TypeError("Promise.race accepts an array"));for(var r=0,i=e.length;r<i;r++)Ke.resolve(e[r]).then(t,n)})},Ke._immediateFn=typeof setImmediate=="function"&&function(e){setImmediate(e)}||function(e){E8(e,0)},Ke._unhandledRejectionFn=function(e){typeof console<"u"&&console&&console.warn("Possible Unhandled Promise Rejection:",e)};var oi=function(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}();typeof oi.Promise!="function"?oi.Promise=Ke:(oi.Promise.prototype.finally||(oi.Promise.prototype.finally=ly),oi.Promise.allSettled||(oi.Promise.allSettled=cy)),function(e){function t(h){for(var p=0,m=Math.min(65536,h.length+1),v=new Uint16Array(m),b=[],y=0;;){var g=p<h.length;if(!g||y>=m-1){var _=v.subarray(0,y);if(b.push(String.fromCharCode.apply(null,_)),!g)return b.join("");h=h.subarray(p),p=0,y=0}var x=h[p++];if((128&x)==0)v[y++]=x;else if((224&x)==192){var O=63&h[p++];v[y++]=(31&x)<<6|O}else if((240&x)==224){O=63&h[p++];var C=63&h[p++];v[y++]=(31&x)<<12|O<<6|C}else if((248&x)==240){var M=(7&x)<<18|(O=63&h[p++])<<12|(C=63&h[p++])<<6|63&h[p++];M>65535&&(M-=65536,v[y++]=M>>>10&1023|55296,M=56320|1023&M),v[y++]=M}}}var n="Failed to ",r=function(h,p,m){if(h)throw new Error("".concat(n).concat(p,": the '").concat(m,"' option is unsupported."))},i=typeof Buffer=="function"&&Buffer.from,o=i?function(h){return Buffer.from(h)}:function(h){for(var p=0,m=h.length,v=0,b=Math.max(32,m+(m>>>1)+7),y=new Uint8Array(b>>>3<<3);p<m;){var g=h.charCodeAt(p++);if(g>=55296&&g<=56319){if(p<m){var _=h.charCodeAt(p);(64512&_)==56320&&(++p,g=((1023&g)<<10)+(1023&_)+65536)}if(g>=55296&&g<=56319)continue}if(v+4>y.length){b+=8,b=(b*=1+p/h.length*2)>>>3<<3;var x=new Uint8Array(b);x.set(y),y=x}if((4294967168&g)!=0){if((4294965248&g)==0)y[v++]=g>>>6&31|192;else if((4294901760&g)==0)y[v++]=g>>>12&15|224,y[v++]=g>>>6&63|128;else{if((4292870144&g)!=0)continue;y[v++]=g>>>18&7|240,y[v++]=g>>>12&63|128,y[v++]=g>>>6&63|128}y[v++]=63&g|128}else y[v++]=g}return y.slice?y.slice(0,v):y.subarray(0,v)};function a(){this.encoding="utf-8"}a.prototype.encode=function(h,p){return r(p&&p.stream,"encode","stream"),o(h)};var s=!i&&typeof Blob=="function"&&typeof URL=="function"&&typeof URL.createObjectURL=="function",c=["utf-8","utf8","unicode-1-1-utf-8"],l=t;i?l=function(h,p){return(h instanceof Buffer?h:Buffer.from(h.buffer,h.byteOffset,h.byteLength)).toString(p)}:s&&(l=function(h){try{return function(p){var m;try{var v=new Blob([p],{type:"text/plain;charset=UTF-8"});m=URL.createObjectURL(v);var b=new XMLHttpRequest;return b.open("GET",m,!1),b.send(),b.responseText}finally{m&&URL.revokeObjectURL(m)}}(h)}catch{return t(h)}});var u="construct 'TextDecoder'",d="".concat(n," ").concat(u,": the ");function f(h,p){if(r(p&&p.fatal,u,"fatal"),h=h||"utf-8",!(i?Buffer.isEncoding(h):c.indexOf(h.toLowerCase())!==-1))throw new RangeError("".concat(d," encoding label provided ('").concat(h,"') is invalid."));this.encoding=h,this.fatal=!1,this.ignoreBOM=!1}f.prototype.decode=function(h,p){var m;return r(p&&p.stream,"decode","stream"),m=h instanceof Uint8Array?h:h.buffer instanceof ArrayBuffer?new Uint8Array(h.buffer):new Uint8Array(h),l(m,this.encoding)},e.TextEncoder=e.TextEncoder||a,e.TextDecoder=e.TextDecoder||f}(typeof window<"u"?window:Sn),function(){function e(v,b){if(!(v instanceof b))throw new TypeError("Cannot call a class as a function")}function t(v,b){for(var y=0;y<b.length;y++){var g=b[y];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(v,g.key,g)}}function n(v,b,y){return b&&t(v.prototype,b),y&&t(v,y),v}function r(v,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function");v.prototype=Object.create(b&&b.prototype,{constructor:{value:v,writable:!0,configurable:!0}}),b&&o(v,b)}function i(v){return i=Object.setPrototypeOf?Object.getPrototypeOf:function(b){return b.__proto__||Object.getPrototypeOf(b)},i(v)}function o(v,b){return o=Object.setPrototypeOf||function(y,g){return y.__proto__=g,y},o(v,b)}function a(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function s(v){if(v===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return v}function c(v,b){return!b||typeof b!="object"&&typeof b!="function"?s(v):b}function l(v){var b=a();return function(){var y,g=i(v);if(b){var _=i(this).constructor;y=Reflect.construct(g,arguments,_)}else y=g.apply(this,arguments);return c(this,y)}}function u(v,b){for(;!Object.prototype.hasOwnProperty.call(v,b)&&(v=i(v))!==null;);return v}function d(v,b,y){return d=typeof Reflect<"u"&&Reflect.get?Reflect.get:function(g,_,x){var O=u(g,_);if(O){var C=Object.getOwnPropertyDescriptor(O,_);return C.get?C.get.call(x):C.value}},d(v,b,y||v)}var f=function(){function v(){e(this,v),Object.defineProperty(this,"listeners",{value:{},writable:!0,configurable:!0})}return n(v,[{key:"addEventListener",value:function(b,y,g){b in this.listeners||(this.listeners[b]=[]),this.listeners[b].push({callback:y,options:g})}},{key:"removeEventListener",value:function(b,y){if(b in this.listeners){for(var g=this.listeners[b],_=0,x=g.length;_<x;_++)if(g[_].callback===y)return void g.splice(_,1)}}},{key:"dispatchEvent",value:function(b){if(b.type in this.listeners){for(var y=this.listeners[b.type].slice(),g=0,_=y.length;g<_;g++){var x=y[g];try{x.callback.call(this,b)}catch(O){Promise.resolve().then(function(){throw O})}x.options&&x.options.once&&this.removeEventListener(b.type,x.callback)}return!b.defaultPrevented}}}]),v}(),h=function(v){r(y,v);var b=l(y);function y(){var g;return e(this,y),(g=b.call(this)).listeners||f.call(s(g)),Object.defineProperty(s(g),"aborted",{value:!1,writable:!0,configurable:!0}),Object.defineProperty(s(g),"onabort",{value:null,writable:!0,configurable:!0}),g}return n(y,[{key:"toString",value:function(){return"[object AbortSignal]"}},{key:"dispatchEvent",value:function(g){g.type==="abort"&&(this.aborted=!0,typeof this.onabort=="function"&&this.onabort.call(this,g)),d(i(y.prototype),"dispatchEvent",this).call(this,g)}}]),y}(f),p=function(){function v(){e(this,v),Object.defineProperty(this,"signal",{value:new h,writable:!0,configurable:!0})}return n(v,[{key:"abort",value:function(){var b;try{b=new Event("abort")}catch{typeof document<"u"?document.createEvent?(b=document.createEvent("Event")).initEvent("abort",!1,!1):(b=document.createEventObject()).type="abort":b={type:"abort",bubbles:!1,cancelable:!1}}this.signal.dispatchEvent(b)}},{key:"toString",value:function(){return"[object AbortController]"}}]),v}();function m(v){return v.__FORCE_INSTALL_ABORTCONTROLLER_POLYFILL?(console.log("__FORCE_INSTALL_ABORTCONTROLLER_POLYFILL=true is set, will force install polyfill"),!0):typeof v.Request=="function"&&!v.Request.prototype.hasOwnProperty("signal")||!v.AbortController}typeof Symbol<"u"&&Symbol.toStringTag&&(p.prototype[Symbol.toStringTag]="AbortController",h.prototype[Symbol.toStringTag]="AbortSignal"),function(v){m(v)&&(v.AbortController=p,v.AbortSignal=h)}(typeof self<"u"?self:Sn)}();var Cr=Xi(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function r(){var i=this;this.locked=new Map,this.addToLocked=function(o,a){var s=i.locked.get(o);s===void 0?a===void 0?i.locked.set(o,[]):i.locked.set(o,[a]):a!==void 0&&(s.unshift(a),i.locked.set(o,s))},this.isLocked=function(o){return i.locked.has(o)},this.lock=function(o){return new Promise(function(a,s){i.isLocked(o)?i.addToLocked(o,a):(i.addToLocked(o),a())})},this.unlock=function(o){var a=i.locked.get(o);if(a!==void 0&&a.length!==0){var s=a.pop();i.locked.set(o,a),s!==void 0&&setTimeout(s,0)}else i.locked.delete(o)}}return r.getInstance=function(){return r.instance===void 0&&(r.instance=new r),r.instance},r}();t.default=function(){return n.getInstance()}});lh(Cr);var C8=Xi(function(e,t){var n=Sn&&Sn.__awaiter||function(c,l,u,d){return new(u||(u=Promise))(function(f,h){function p(b){try{v(d.next(b))}catch(y){h(y)}}function m(b){try{v(d.throw(b))}catch(y){h(y)}}function v(b){b.done?f(b.value):new u(function(y){y(b.value)}).then(p,m)}v((d=d.apply(c,l||[])).next())})},r=Sn&&Sn.__generator||function(c,l){var u,d,f,h,p={label:0,sent:function(){if(1&f[0])throw f[1];return f[1]},trys:[],ops:[]};return h={next:m(0),throw:m(1),return:m(2)},typeof Symbol=="function"&&(h[Symbol.iterator]=function(){return this}),h;function m(v){return function(b){return function(y){if(u)throw new TypeError("Generator is already executing.");for(;p;)try{if(u=1,d&&(f=2&y[0]?d.return:y[0]?d.throw||((f=d.return)&&f.call(d),0):d.next)&&!(f=f.call(d,y[1])).done)return f;switch(d=0,f&&(y=[2&y[0],f.value]),y[0]){case 0:case 1:f=y;break;case 4:return p.label++,{value:y[1],done:!1};case 5:p.label++,d=y[1],y=[0];continue;case 7:y=p.ops.pop(),p.trys.pop();continue;default:if(f=p.trys,!((f=f.length>0&&f[f.length-1])||y[0]!==6&&y[0]!==2)){p=0;continue}if(y[0]===3&&(!f||y[1]>f[0]&&y[1]<f[3])){p.label=y[1];break}if(y[0]===6&&p.label<f[1]){p.label=f[1],f=y;break}if(f&&p.label<f[2]){p.label=f[2],p.ops.push(y);break}f[2]&&p.ops.pop(),p.trys.pop();continue}y=l.call(c,p)}catch(g){y=[6,g],d=0}finally{u=f=0}if(5&y[0])throw y[1];return{value:y[0]?y[1]:void 0,done:!0}}([v,b])}}};Object.defineProperty(t,"__esModule",{value:!0});var i="browser-tabs-lock-key";function o(c){return new Promise(function(l){return setTimeout(l,c)})}function a(c){for(var l="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz",u="",d=0;d<c;d++)u+=l[Math.floor(Math.random()*l.length)];return u}var s=function(){function c(){this.acquiredIatSet=new Set,this.id=Date.now().toString()+a(15),this.acquireLock=this.acquireLock.bind(this),this.releaseLock=this.releaseLock.bind(this),this.releaseLock__private__=this.releaseLock__private__.bind(this),this.waitForSomethingToChange=this.waitForSomethingToChange.bind(this),this.refreshLockWhileAcquired=this.refreshLockWhileAcquired.bind(this),c.waiters===void 0&&(c.waiters=[])}return c.prototype.acquireLock=function(l,u){return u===void 0&&(u=5e3),n(this,void 0,void 0,function(){var d,f,h,p,m,v;return r(this,function(b){switch(b.label){case 0:d=Date.now()+a(4),f=Date.now()+u,h=i+"-"+l,p=window.localStorage,b.label=1;case 1:return Date.now()<f?[4,o(30)]:[3,8];case 2:return b.sent(),p.getItem(h)!==null?[3,5]:(m=this.id+"-"+l+"-"+d,[4,o(Math.floor(25*Math.random()))]);case 3:return b.sent(),p.setItem(h,JSON.stringify({id:this.id,iat:d,timeoutKey:m,timeAcquired:Date.now(),timeRefreshed:Date.now()})),[4,o(30)];case 4:return b.sent(),(v=p.getItem(h))!==null&&(v=JSON.parse(v)).id===this.id&&v.iat===d?(this.acquiredIatSet.add(d),this.refreshLockWhileAcquired(h,d),[2,!0]):[3,7];case 5:return c.lockCorrector(),[4,this.waitForSomethingToChange(f)];case 6:b.sent(),b.label=7;case 7:return d=Date.now()+a(4),[3,1];case 8:return[2,!1]}})})},c.prototype.refreshLockWhileAcquired=function(l,u){return n(this,void 0,void 0,function(){var d=this;return r(this,function(f){return setTimeout(function(){return n(d,void 0,void 0,function(){var h,p;return r(this,function(m){switch(m.label){case 0:return[4,Cr.default().lock(u)];case 1:return m.sent(),this.acquiredIatSet.has(u)?(h=window.localStorage,(p=h.getItem(l))===null?(Cr.default().unlock(u),[2]):((p=JSON.parse(p)).timeRefreshed=Date.now(),h.setItem(l,JSON.stringify(p)),Cr.default().unlock(u),this.refreshLockWhileAcquired(l,u),[2])):(Cr.default().unlock(u),[2])}})})},1e3),[2]})})},c.prototype.waitForSomethingToChange=function(l){return n(this,void 0,void 0,function(){return r(this,function(u){switch(u.label){case 0:return[4,new Promise(function(d){var f=!1,h=Date.now(),p=!1;function m(){if(p||(window.removeEventListener("storage",m),c.removeFromWaiting(m),clearTimeout(v),p=!0),!f){f=!0;var b=50-(Date.now()-h);b>0?setTimeout(d,b):d()}}window.addEventListener("storage",m),c.addToWaiting(m);var v=setTimeout(m,Math.max(0,l-Date.now()))})];case 1:return u.sent(),[2]}})})},c.addToWaiting=function(l){this.removeFromWaiting(l),c.waiters!==void 0&&c.waiters.push(l)},c.removeFromWaiting=function(l){c.waiters!==void 0&&(c.waiters=c.waiters.filter(function(u){return u!==l}))},c.notifyWaiters=function(){c.waiters!==void 0&&c.waiters.slice().forEach(function(l){return l()})},c.prototype.releaseLock=function(l){return n(this,void 0,void 0,function(){return r(this,function(u){switch(u.label){case 0:return[4,this.releaseLock__private__(l)];case 1:return[2,u.sent()]}})})},c.prototype.releaseLock__private__=function(l){return n(this,void 0,void 0,function(){var u,d,f;return r(this,function(h){switch(h.label){case 0:return u=window.localStorage,d=i+"-"+l,(f=u.getItem(d))===null?[2]:(f=JSON.parse(f)).id!==this.id?[3,2]:[4,Cr.default().lock(f.iat)];case 1:h.sent(),this.acquiredIatSet.delete(f.iat),u.removeItem(d),Cr.default().unlock(f.iat),c.notifyWaiters(),h.label=2;case 2:return[2]}})})},c.lockCorrector=function(){for(var l=Date.now()-5e3,u=window.localStorage,d=Object.keys(u),f=!1,h=0;h<d.length;h++){var p=d[h];if(p.includes(i)){var m=u.getItem(p);m!==null&&((m=JSON.parse(m)).timeRefreshed===void 0&&m.timeAcquired<l||m.timeRefreshed!==void 0&&m.timeRefreshed<l)&&(u.removeItem(p),f=!0)}}f&&c.notifyWaiters()},c.waiters=void 0,c}();t.default=s}),N8=lh(C8),T8={timeoutInSeconds:60},P8=["login_required","consent_required","interaction_required","account_selection_required","access_denied"],fy={name:"auth0-spa-js",version:"1.22.6"},hy=function(){return Date.now()},qn=function(e){function t(n,r){var i=e.call(this,r)||this;return i.error=n,i.error_description=r,Object.setPrototypeOf(i,t.prototype),i}return Jr(t,e),t.fromPayload=function(n){return new t(n.error,n.error_description)},t}(Error),A8=function(e){function t(n,r,i,o){o===void 0&&(o=null);var a=e.call(this,n,r)||this;return a.state=i,a.appState=o,Object.setPrototypeOf(a,t.prototype),a}return Jr(t,e),t}(qn),Bd=function(e){function t(){var n=e.call(this,"timeout","Timeout")||this;return Object.setPrototypeOf(n,t.prototype),n}return Jr(t,e),t}(qn),I8=function(e){function t(n){var r=e.call(this)||this;return r.popup=n,Object.setPrototypeOf(r,t.prototype),r}return Jr(t,e),t}(Bd),M8=function(e){function t(n){var r=e.call(this,"cancelled","Popup closed")||this;return r.popup=n,Object.setPrototypeOf(r,t.prototype),r}return Jr(t,e),t}(qn),D8=function(e){function t(n,r,i){var o=e.call(this,n,r)||this;return o.mfa_token=i,Object.setPrototypeOf(o,t.prototype),o}return Jr(t,e),t}(qn),L8=function(e){function t(n,r){var i=e.call(this,"missing_refresh_token","Missing Refresh Token (audience: '".concat(Rp(n,["default"]),"', scope: '").concat(Rp(r),"')"))||this;return i.audience=n,i.scope=r,Object.setPrototypeOf(i,t.prototype),i}return Jr(t,e),t}(qn),R8=function(e){return new Promise(function(t,n){var r,i=setInterval(function(){e.popup&&e.popup.closed&&(clearInterval(i),clearTimeout(o),window.removeEventListener("message",r,!1),n(new M8(e.popup)))},1e3),o=setTimeout(function(){clearInterval(i),n(new I8(e.popup)),window.removeEventListener("message",r,!1)},1e3*(e.timeoutInSeconds||60));r=function(a){if(a.data&&a.data.type==="authorization_response"){if(clearTimeout(o),clearInterval(i),window.removeEventListener("message",r,!1),e.popup.close(),a.data.response.error)return n(qn.fromPayload(a.data.response));t(a.data.response)}},window.addEventListener("message",r)})},Sh=function(){return window.crypto||window.msCrypto},py=function(){var e=Sh();return e.subtle||e.webkitSubtle},Ln=function(){var e="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_~.",t="";return Array.from(Sh().getRandomValues(new Uint8Array(43))).forEach(function(n){return t+=e[n%e.length]}),t},ai=function(e){return btoa(e)},Hd=function(e){return Object.keys(e).filter(function(t){return e[t]!==void 0}).map(function(t){return encodeURIComponent(t)+"="+encodeURIComponent(e[t])}).join("&")},$u=function(e){return xe(void 0,void 0,void 0,function(){var t;return ke(this,function(n){switch(n.label){case 0:return t=py().digest({name:"SHA-256"},new TextEncoder().encode(e)),window.msCrypto?[2,new Promise(function(r,i){t.oncomplete=function(o){r(o.target.result)},t.onerror=function(o){i(o.error)},t.onabort=function(){i("The digest operation was aborted")}})]:[4,t];case 1:return[2,n.sent()]}})})},Lp=function(e){return function(t){return decodeURIComponent(atob(t).split("").map(function(n){return"%"+("00"+n.charCodeAt(0).toString(16)).slice(-2)}).join(""))}(e.replace(/_/g,"/").replace(/-/g,"+"))},wu=function(e){var t=new Uint8Array(e);return function(n){var r={"+":"-","/":"_","=":""};return n.replace(/[+/=]/g,function(i){return r[i]})}(window.btoa(String.fromCharCode.apply(String,Ed([],Ai(Array.from(t)),!1))))};function Rp(e,t){return t===void 0&&(t=[]),e&&!t.includes(e)?e:""}var F8=function(e,t){return xe(void 0,void 0,void 0,function(){var n,r;return ke(this,function(i){switch(i.label){case 0:return[4,(o=e,a=t,a=a||{},new Promise(function(s,c){var l=new XMLHttpRequest,u=[],d=[],f={},h=function(){return{ok:(l.status/100|0)==2,statusText:l.statusText,status:l.status,url:l.responseURL,text:function(){return Promise.resolve(l.responseText)},json:function(){return Promise.resolve(l.responseText).then(JSON.parse)},blob:function(){return Promise.resolve(new Blob([l.response]))},clone:h,headers:{keys:function(){return u},entries:function(){return d},get:function(m){return f[m.toLowerCase()]},has:function(m){return m.toLowerCase()in f}}}};for(var p in l.open(a.method||"get",o,!0),l.onload=function(){l.getAllResponseHeaders().replace(/^(.*?):[^\S\n]*([\s\S]*?)$/gm,function(m,v,b){u.push(v=v.toLowerCase()),d.push([v,b]),f[v]=f[v]?f[v]+","+b:b}),s(h())},l.onerror=c,l.withCredentials=a.credentials=="include",a.headers)l.setRequestHeader(p,a.headers[p]);l.send(a.body||null)}))];case 1:return n=i.sent(),r={ok:n.ok},[4,n.json()];case 2:return[2,(r.json=i.sent(),r)]}var o,a})})},z8=function(e,t,n){return xe(void 0,void 0,void 0,function(){var r,i;return ke(this,function(o){return r=new AbortController,t.signal=r.signal,[2,Promise.race([F8(e,t),new Promise(function(a,s){i=setTimeout(function(){r.abort(),s(new Error("Timeout when executing 'fetch'"))},n)})]).finally(function(){clearTimeout(i)})]})})},j8=function(e,t,n,r,i,o,a){return xe(void 0,void 0,void 0,function(){return ke(this,function(s){return[2,(c={auth:{audience:t,scope:n},timeout:i,fetchUrl:e,fetchOptions:r,useFormData:a},l=o,new Promise(function(u,d){var f=new MessageChannel;f.port1.onmessage=function(h){h.data.error?d(new Error(h.data.error)):u(h.data),f.port1.close()},l.postMessage(c,[f.port2])}))];var c,l})})},V8=function(e,t,n,r,i,o,a){return a===void 0&&(a=1e4),xe(void 0,void 0,void 0,function(){return ke(this,function(s){return i?[2,j8(e,t,n,r,a,i,o)]:[2,z8(e,r,a)]})})};function U8(e,t,n,r,i,o,a){return xe(this,void 0,void 0,function(){var s,c,l,u,d,f,h,p,m;return ke(this,function(v){switch(v.label){case 0:s=null,l=0,v.label=1;case 1:if(!(l<3))return[3,6];v.label=2;case 2:return v.trys.push([2,4,,5]),[4,V8(e,n,r,i,o,a,t)];case 3:return c=v.sent(),s=null,[3,6];case 4:return u=v.sent(),s=u,[3,5];case 5:return l++,[3,1];case 6:if(s)throw s.message=s.message||"Failed to fetch",s;if(d=c.json,f=d.error,h=d.error_description,p=Ut(d,["error","error_description"]),!c.ok)throw m=h||"HTTP error. Unable to fetch ".concat(e),f==="mfa_required"?new D8(f,m,p.mfa_token):new qn(f||"request_error",m);return[2,p]}})})}function La(e,t){var n=e.baseUrl,r=e.timeout,i=e.audience,o=e.scope,a=e.auth0Client,s=e.useFormData,c=Ut(e,["baseUrl","timeout","audience","scope","auth0Client","useFormData"]);return xe(this,void 0,void 0,function(){var l;return ke(this,function(u){switch(u.label){case 0:return l=s?Hd(c):JSON.stringify(c),[4,U8("".concat(n,"/oauth/token"),r,i||"default",o,{method:"POST",body:l,headers:{"Content-Type":s?"application/x-www-form-urlencoded":"application/json","Auth0-Client":btoa(JSON.stringify(a||fy))}},t,s)];case 1:return[2,u.sent()]}})})}var B8=function(e){return Array.from(new Set(e))},Zn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return B8(e.join(" ").trim().split(/\s+/)).join(" ")},Ir=function(){function e(t,n){n===void 0&&(n="@@auth0spajs@@"),this.prefix=n,this.client_id=t.client_id,this.scope=t.scope,this.audience=t.audience}return e.prototype.toKey=function(){return"".concat(this.prefix,"::").concat(this.client_id,"::").concat(this.audience,"::").concat(this.scope)},e.fromKey=function(t){var n=Ai(t.split("::"),4),r=n[0],i=n[1],o=n[2];return new e({client_id:i,scope:n[3],audience:o},r)},e.fromCacheEntry=function(t){return new e({scope:t.scope,audience:t.audience,client_id:t.client_id})},e}(),H8=function(){function e(){}return e.prototype.set=function(t,n){localStorage.setItem(t,JSON.stringify(n))},e.prototype.get=function(t){var n=window.localStorage.getItem(t);if(n)try{return JSON.parse(n)}catch{return}},e.prototype.remove=function(t){localStorage.removeItem(t)},e.prototype.allKeys=function(){return Object.keys(window.localStorage).filter(function(t){return t.startsWith("@@auth0spajs@@")})},e}(),q8=function(){var e;this.enclosedCache=(e={},{set:function(t,n){e[t]=n},get:function(t){var n=e[t];if(n)return n},remove:function(t){delete e[t]},allKeys:function(){return Object.keys(e)}})},W8=function(){function e(t,n,r){this.cache=t,this.keyManifest=n,this.nowProvider=r,this.nowProvider=this.nowProvider||hy}return e.prototype.get=function(t,n){var r;return n===void 0&&(n=0),xe(this,void 0,void 0,function(){var i,o,a,s,c;return ke(this,function(l){switch(l.label){case 0:return[4,this.cache.get(t.toKey())];case 1:return(i=l.sent())?[3,4]:[4,this.getCacheKeys()];case 2:return(o=l.sent())?(a=this.matchExistingCacheKey(t,o))?[4,this.cache.get(a)]:[3,4]:[2];case 3:i=l.sent(),l.label=4;case 4:return i?[4,this.nowProvider()]:[2];case 5:return s=l.sent(),c=Math.floor(s/1e3),i.expiresAt-n<c?i.body.refresh_token?(i.body={refresh_token:i.body.refresh_token},[4,this.cache.set(t.toKey(),i)]):[3,7]:[3,10];case 6:return l.sent(),[2,i.body];case 7:return[4,this.cache.remove(t.toKey())];case 8:return l.sent(),[4,(r=this.keyManifest)===null||r===void 0?void 0:r.remove(t.toKey())];case 9:return l.sent(),[2];case 10:return[2,i.body]}})})},e.prototype.set=function(t){var n;return xe(this,void 0,void 0,function(){var r,i;return ke(this,function(o){switch(o.label){case 0:return r=new Ir({client_id:t.client_id,scope:t.scope,audience:t.audience}),[4,this.wrapCacheEntry(t)];case 1:return i=o.sent(),[4,this.cache.set(r.toKey(),i)];case 2:return o.sent(),[4,(n=this.keyManifest)===null||n===void 0?void 0:n.add(r.toKey())];case 3:return o.sent(),[2]}})})},e.prototype.clear=function(t){var n;return xe(this,void 0,void 0,function(){var r,i=this;return ke(this,function(o){switch(o.label){case 0:return[4,this.getCacheKeys()];case 1:return(r=o.sent())?[4,r.filter(function(a){return!t||a.includes(t)}).reduce(function(a,s){return xe(i,void 0,void 0,function(){return ke(this,function(c){switch(c.label){case 0:return[4,a];case 1:return c.sent(),[4,this.cache.remove(s)];case 2:return c.sent(),[2]}})})},Promise.resolve())]:[2];case 2:return o.sent(),[4,(n=this.keyManifest)===null||n===void 0?void 0:n.clear()];case 3:return o.sent(),[2]}})})},e.prototype.clearSync=function(t){var n=this,r=this.cache.allKeys();r&&r.filter(function(i){return!t||i.includes(t)}).forEach(function(i){n.cache.remove(i)})},e.prototype.wrapCacheEntry=function(t){return xe(this,void 0,void 0,function(){var n,r,i;return ke(this,function(o){switch(o.label){case 0:return[4,this.nowProvider()];case 1:return n=o.sent(),r=Math.floor(n/1e3)+t.expires_in,i=Math.min(r,t.decodedToken.claims.exp),[2,{body:t,expiresAt:i}]}})})},e.prototype.getCacheKeys=function(){var t;return xe(this,void 0,void 0,function(){var n;return ke(this,function(r){switch(r.label){case 0:return this.keyManifest?[4,this.keyManifest.get()]:[3,2];case 1:return n=(t=r.sent())===null||t===void 0?void 0:t.keys,[3,4];case 2:return[4,this.cache.allKeys()];case 3:n=r.sent(),r.label=4;case 4:return[2,n]}})})},e.prototype.matchExistingCacheKey=function(t,n){return n.filter(function(r){var i=Ir.fromKey(r),o=new Set(i.scope&&i.scope.split(" ")),a=t.scope.split(" "),s=i.scope&&a.reduce(function(c,l){return c&&o.has(l)},!0);return i.prefix==="@@auth0spajs@@"&&i.client_id===t.client_id&&i.audience===t.audience&&s})[0]},e}(),G8=function(){function e(t,n){this.storage=t,this.clientId=n,this.storageKey="".concat("a0.spajs.txs",".").concat(this.clientId),this.transaction=this.storage.get(this.storageKey)}return e.prototype.create=function(t){this.transaction=t,this.storage.save(this.storageKey,t,{daysUntilExpire:1})},e.prototype.get=function(){return this.transaction},e.prototype.remove=function(){delete this.transaction,this.storage.remove(this.storageKey)},e}(),yo=function(e){return typeof e=="number"},K8=["iss","aud","exp","nbf","iat","jti","azp","nonce","auth_time","at_hash","c_hash","acr","amr","sub_jwk","cnf","sip_from_tag","sip_date","sip_callid","sip_cseq_num","sip_via_branch","orig","dest","mky","events","toe","txn","rph","sid","vot","vtm"],Q8=function(e){if(!e.id_token)throw new Error("ID token is required but missing");var t=function(s){var c=s.split("."),l=Ai(c,3),u=l[0],d=l[1],f=l[2];if(c.length!==3||!u||!d||!f)throw new Error("ID token could not be decoded");var h=JSON.parse(Lp(d)),p={__raw:s},m={};return Object.keys(h).forEach(function(v){p[v]=h[v],K8.includes(v)||(m[v]=h[v])}),{encoded:{header:u,payload:d,signature:f},header:JSON.parse(Lp(u)),claims:p,user:m}}(e.id_token);if(!t.claims.iss)throw new Error("Issuer (iss) claim must be a string present in the ID token");if(t.claims.iss!==e.iss)throw new Error('Issuer (iss) claim mismatch in the ID token; expected "'.concat(e.iss,'", found "').concat(t.claims.iss,'"'));if(!t.user.sub)throw new Error("Subject (sub) claim must be a string present in the ID token");if(t.header.alg!=="RS256")throw new Error('Signature algorithm of "'.concat(t.header.alg,'" is not supported. Expected the ID token to be signed with "RS256".'));if(!t.claims.aud||typeof t.claims.aud!="string"&&!Array.isArray(t.claims.aud))throw new Error("Audience (aud) claim must be a string or array of strings present in the ID token");if(Array.isArray(t.claims.aud)){if(!t.claims.aud.includes(e.aud))throw new Error('Audience (aud) claim mismatch in the ID token; expected "'.concat(e.aud,'" but was not one of "').concat(t.claims.aud.join(", "),'"'));if(t.claims.aud.length>1){if(!t.claims.azp)throw new Error("Authorized Party (azp) claim must be a string present in the ID token when Audience (aud) claim has multiple values");if(t.claims.azp!==e.aud)throw new Error('Authorized Party (azp) claim mismatch in the ID token; expected "'.concat(e.aud,'", found "').concat(t.claims.azp,'"'))}}else if(t.claims.aud!==e.aud)throw new Error('Audience (aud) claim mismatch in the ID token; expected "'.concat(e.aud,'" but found "').concat(t.claims.aud,'"'));if(e.nonce){if(!t.claims.nonce)throw new Error("Nonce (nonce) claim must be a string present in the ID token");if(t.claims.nonce!==e.nonce)throw new Error('Nonce (nonce) claim mismatch in the ID token; expected "'.concat(e.nonce,'", found "').concat(t.claims.nonce,'"'))}if(e.max_age&&!yo(t.claims.auth_time))throw new Error("Authentication Time (auth_time) claim must be a number present in the ID token when Max Age (max_age) is specified");if(!yo(t.claims.exp))throw new Error("Expiration Time (exp) claim must be a number present in the ID token");if(!yo(t.claims.iat))throw new Error("Issued At (iat) claim must be a number present in the ID token");var n=e.leeway||60,r=new Date(e.now||Date.now()),i=new Date(0),o=new Date(0),a=new Date(0);if(a.setUTCSeconds(parseInt(t.claims.auth_time)+e.max_age+n),i.setUTCSeconds(t.claims.exp+n),o.setUTCSeconds(t.claims.nbf-n),r>i)throw new Error("Expiration Time (exp) claim error in the ID token; current time (".concat(r,") is after expiration time (").concat(i,")"));if(yo(t.claims.nbf)&&r<o)throw new Error("Not Before time (nbf) claim in the ID token indicates that this token can't be used just yet. Currrent time (".concat(r,") is before ").concat(o));if(yo(t.claims.auth_time)&&r>a)throw new Error("Authentication Time (auth_time) claim in the ID token indicates that too much time has passed since the last end-user authentication. Currrent time (".concat(r,") is after last auth at ").concat(a));if(e.organizationId){if(!t.claims.org_id)throw new Error("Organization ID (org_id) claim must be a string present in the ID token");if(e.organizationId!==t.claims.org_id)throw new Error('Organization ID (org_id) claim mismatch in the ID token; expected "'.concat(e.organizationId,'", found "').concat(t.claims.org_id,'"'))}return t},Dr=Xi(function(e,t){var n=Sn&&Sn.__assign||function(){return n=Object.assign||function(c){for(var l,u=1,d=arguments.length;u<d;u++)for(var f in l=arguments[u])Object.prototype.hasOwnProperty.call(l,f)&&(c[f]=l[f]);return c},n.apply(this,arguments)};function r(c,l){if(!l)return"";var u="; "+c;return l===!0?u:u+"="+l}function i(c,l,u){return encodeURIComponent(c).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/\(/g,"%28").replace(/\)/g,"%29")+"="+encodeURIComponent(l).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent)+function(d){if(typeof d.expires=="number"){var f=new Date;f.setMilliseconds(f.getMilliseconds()+864e5*d.expires),d.expires=f}return r("Expires",d.expires?d.expires.toUTCString():"")+r("Domain",d.domain)+r("Path",d.path)+r("Secure",d.secure)+r("SameSite",d.sameSite)}(u)}function o(c){for(var l={},u=c?c.split("; "):[],d=/(%[\dA-F]{2})+/gi,f=0;f<u.length;f++){var h=u[f].split("="),p=h.slice(1).join("=");p.charAt(0)==='"'&&(p=p.slice(1,-1));try{l[h[0].replace(d,decodeURIComponent)]=p.replace(d,decodeURIComponent)}catch{}}return l}function a(){return o(document.cookie)}function s(c,l,u){document.cookie=i(c,l,n({path:"/"},u))}t.__esModule=!0,t.encode=i,t.parse=o,t.getAll=a,t.get=function(c){return a()[c]},t.set=s,t.remove=function(c,l){s(c,"",n(n({},l),{expires:-1}))}});lh(Dr),Dr.encode,Dr.parse,Dr.getAll;var Y8=Dr.get,my=Dr.set,vy=Dr.remove,pi={get:function(e){var t=Y8(e);if(t!==void 0)return JSON.parse(t)},save:function(e,t,n){var r={};window.location.protocol==="https:"&&(r={secure:!0,sameSite:"none"}),n?.daysUntilExpire&&(r.expires=n.daysUntilExpire),n?.cookieDomain&&(r.domain=n.cookieDomain),my(e,JSON.stringify(t),r)},remove:function(e,t){var n={};t?.cookieDomain&&(n.domain=t.cookieDomain),vy(e,n)}},X8={get:function(e){var t=pi.get(e);return t||pi.get("".concat("_legacy_").concat(e))},save:function(e,t,n){var r={};window.location.protocol==="https:"&&(r={secure:!0}),n?.daysUntilExpire&&(r.expires=n.daysUntilExpire),my("".concat("_legacy_").concat(e),JSON.stringify(t),r),pi.save(e,t,n)},remove:function(e,t){var n={};t?.cookieDomain&&(n.domain=t.cookieDomain),vy(e,n),pi.remove(e,t),pi.remove("".concat("_legacy_").concat(e),t)}},Z8={get:function(e){if(typeof sessionStorage<"u"){var t=sessionStorage.getItem(e);if(t!==void 0)return JSON.parse(t)}},save:function(e,t){sessionStorage.setItem(e,JSON.stringify(t))},remove:function(e){sessionStorage.removeItem(e)}};function J8(e,t,n){var r=t===void 0?null:t,i=function(c,l){var u=atob(c);if(l){for(var d=new Uint8Array(u.length),f=0,h=u.length;f<h;++f)d[f]=u.charCodeAt(f);return String.fromCharCode.apply(null,new Uint16Array(d.buffer))}return u}(e,n!==void 0&&n),o=i.indexOf(`
|
|
1
|
+
"use strict";const dt={};function i4(e){dt.context=e}const o4=(e,t)=>e===t,wt=Symbol("solid-proxy"),Go=Symbol("solid-track"),il={equals:o4};let ig=cg;const Kn=1,ol=2,og={owned:null,cleanups:null,context:null,owner:null};var Qe=null;let Rr=null,Be=null,Ct=null,jn=null,ah=0;const[a4,dQ]=V(!1);function is(e,t){const n=Be,r=Qe,i=e.length===0,o=i?og:{owned:null,cleanups:null,context:null,owner:t===void 0?r:t},a=i?e:()=>e(()=>H(()=>Ec(o)));Qe=o,Be=null;try{return Zr(a,!0)}finally{Be=n,Qe=r}}function V(e,t){t=t?Object.assign({},il,t):il;const n={value:e,observers:null,observerSlots:null,comparator:t.equals||void 0},r=i=>(typeof i=="function"&&(i=i(n.value)),lg(n,i));return[sg.bind(n),r]}function ag(e,t,n){const r=kc(e,t,!0,Kn);Qi(r)}function q(e,t,n){const r=kc(e,t,!1,Kn);Qi(r)}function me(e,t,n){ig=f4;const r=kc(e,t,!1,Kn);r.user=!0,jn?jn.push(r):Qi(r)}function se(e,t,n){n=n?Object.assign({},il,n):il;const r=kc(e,t,!0,0);return r.observers=null,r.observerSlots=null,r.comparator=n.equals||void 0,Qi(r),sg.bind(r)}function al(e){return Zr(e,!1)}function H(e){if(Be===null)return e();const t=Be;Be=null;try{return e()}finally{Be=t}}function ht(e){me(()=>H(e))}function Gi(e){return Qe===null||(Qe.cleanups===null?Qe.cleanups=[e]:Qe.cleanups.push(e)),e}function xc(){return Be}function A(){return Qe}function s4(e){const t=Be,n=Qe;return Promise.resolve().then(()=>{Be=t,Qe=n;let r;return Zr(e,!1),Be=Qe=null,r?r.done:void 0})}function l4(){return[a4,s4]}function sh(e,t){const n=Symbol("context");return{id:n,Provider:p4(n),defaultValue:e}}function Ki(e){let t;return(t=fg(Qe,e.id))!==void 0?t:e.defaultValue}function c4(e){const t=se(e),n=se(()=>$d(t()));return n.toArray=()=>{const r=n();return Array.isArray(r)?r:r!=null?[r]:[]},n}function sg(){const e=Rr;if(this.sources&&(this.state||e))if(this.state===Kn||e)Qi(this);else{const t=Ct;Ct=null,Zr(()=>ll(this),!1),Ct=t}if(Be){const t=this.observers?this.observers.length:0;Be.sources?(Be.sources.push(this),Be.sourceSlots.push(t)):(Be.sources=[this],Be.sourceSlots=[t]),this.observers?(this.observers.push(Be),this.observerSlots.push(Be.sources.length-1)):(this.observers=[Be],this.observerSlots=[Be.sources.length-1])}return this.value}function lg(e,t,n){let r=e.value;return(!e.comparator||!e.comparator(r,t))&&(e.value=t,e.observers&&e.observers.length&&Zr(()=>{for(let i=0;i<e.observers.length;i+=1){const o=e.observers[i],a=Rr&&Rr.running;a&&Rr.disposed.has(o),(a&&!o.tState||!a&&!o.state)&&(o.pure?Ct.push(o):jn.push(o),o.observers&&ug(o)),a||(o.state=Kn)}if(Ct.length>1e6)throw Ct=[],new Error},!1)),t}function Qi(e){if(!e.fn)return;Ec(e);const t=Qe,n=Be,r=ah;Be=Qe=e,u4(e,e.value,r),Be=n,Qe=t}function u4(e,t,n){let r;try{r=e.fn(t)}catch(i){e.pure&&(e.state=Kn,e.owned&&e.owned.forEach(Ec),e.owned=null),dg(i)}(!e.updatedAt||e.updatedAt<=n)&&(e.updatedAt!=null&&"observers"in e?lg(e,r):e.value=r,e.updatedAt=n)}function kc(e,t,n,r=Kn,i){const o={fn:e,state:r,updatedAt:null,owned:null,sources:null,sourceSlots:null,cleanups:null,value:t,owner:Qe,context:null,pure:n};return Qe===null||Qe!==og&&(Qe.owned?Qe.owned.push(o):Qe.owned=[o]),o}function sl(e){const t=Rr;if(e.state===0||t)return;if(e.state===ol||t)return ll(e);if(e.suspense&&H(e.suspense.inFallback))return e.suspense.effects.push(e);const n=[e];for(;(e=e.owner)&&(!e.updatedAt||e.updatedAt<ah);)(e.state||t)&&n.push(e);for(let r=n.length-1;r>=0;r--)if(e=n[r],e.state===Kn||t)Qi(e);else if(e.state===ol||t){const i=Ct;Ct=null,Zr(()=>ll(e,n[0]),!1),Ct=i}}function Zr(e,t){if(Ct)return e();let n=!1;t||(Ct=[]),jn?n=!0:jn=[],ah++;try{const r=e();return d4(n),r}catch(r){n||(jn=null),Ct=null,dg(r)}}function d4(e){if(Ct&&(cg(Ct),Ct=null),e)return;const t=jn;jn=null,t.length&&Zr(()=>ig(t),!1)}function cg(e){for(let t=0;t<e.length;t++)sl(e[t])}function f4(e){let t,n=0;for(t=0;t<e.length;t++){const r=e[t];r.user?e[n++]=r:sl(r)}for(dt.context&&i4(),t=0;t<n;t++)sl(e[t])}function ll(e,t){const n=Rr;e.state=0;for(let r=0;r<e.sources.length;r+=1){const i=e.sources[r];i.sources&&(i.state===Kn||n?i!==t&&sl(i):(i.state===ol||n)&&ll(i,t))}}function ug(e){const t=Rr;for(let n=0;n<e.observers.length;n+=1){const r=e.observers[n];(!r.state||t)&&(r.state=ol,r.pure?Ct.push(r):jn.push(r),r.observers&&ug(r))}}function Ec(e){let t;if(e.sources)for(;e.sources.length;){const n=e.sources.pop(),r=e.sourceSlots.pop(),i=n.observers;if(i&&i.length){const o=i.pop(),a=n.observerSlots.pop();r<i.length&&(o.sourceSlots[a]=r,i[r]=o,n.observerSlots[r]=a)}}if(e.owned){for(t=0;t<e.owned.length;t++)Ec(e.owned[t]);e.owned=null}if(e.cleanups){for(t=0;t<e.cleanups.length;t++)e.cleanups[t]();e.cleanups=null}e.state=0,e.context=null}function h4(e){return e instanceof Error||typeof e=="string"?e:new Error("Unknown error")}function dg(e){throw e=h4(e),e}function fg(e,t){return e?e.context&&e.context[t]!==void 0?e.context[t]:fg(e.owner,t):void 0}function $d(e){if(typeof e=="function"&&!e.length)return $d(e());if(Array.isArray(e)){const t=[];for(let n=0;n<e.length;n++){const r=$d(e[n]);Array.isArray(r)?t.push.apply(t,r):t.push(r)}return t}return e}function p4(e,t){return function(r){let i;return q(()=>i=H(()=>(Qe.context={[e]:r.value},c4(()=>r.children))),void 0),i}}const m4=Symbol("fallback");function A1(e){for(let t=0;t<e.length;t++)e[t]()}function v4(e,t,n={}){let r=[],i=[],o=[],a=0,s=t.length>1?[]:null;return Gi(()=>A1(o)),()=>{let c=e()||[],l,u;return c[Go],H(()=>{let f=c.length,h,p,m,v,b,y,g,_,k;if(f===0)a!==0&&(A1(o),o=[],r=[],i=[],a=0,s&&(s=[])),n.fallback&&(r=[m4],i[0]=is(O=>(o[0]=O,n.fallback())),a=1);else if(a===0){for(i=new Array(f),u=0;u<f;u++)r[u]=c[u],i[u]=is(d);a=f}else{for(m=new Array(f),v=new Array(f),s&&(b=new Array(f)),y=0,g=Math.min(a,f);y<g&&r[y]===c[y];y++);for(g=a-1,_=f-1;g>=y&&_>=y&&r[g]===c[_];g--,_--)m[_]=i[g],v[_]=o[g],s&&(b[_]=s[g]);for(h=new Map,p=new Array(_+1),u=_;u>=y;u--)k=c[u],l=h.get(k),p[u]=l===void 0?-1:l,h.set(k,u);for(l=y;l<=g;l++)k=r[l],u=h.get(k),u!==void 0&&u!==-1?(m[u]=i[l],v[u]=o[l],s&&(b[u]=s[l]),u=p[u],h.set(k,u)):o[l]();for(u=y;u<f;u++)u in m?(i[u]=m[u],o[u]=v[u],s&&(s[u]=b[u],s[u](u))):i[u]=is(d);i=i.slice(0,a=f),r=c.slice(0)}return i});function d(f){if(o[u]=f,s){const[h,p]=V(u);return s[u]=p,t(c[u],h)}return t(c[u])}}}function S(e,t){return H(()=>e(t||{}))}function Ca(){return!0}const wd={get(e,t,n){return t===wt?n:e.get(t)},has(e,t){return t===wt?!0:e.has(t)},set:Ca,deleteProperty:Ca,getOwnPropertyDescriptor(e,t){return{configurable:!0,enumerable:!0,get(){return e.get(t)},set:Ca,deleteProperty:Ca}},ownKeys(e){return e.keys()}};function iu(e){return(e=typeof e=="function"?e():e)?e:{}}function Nt(...e){let t=!1;for(let r=0;r<e.length;r++){const i=e[r];t=t||!!i&&wt in i,e[r]=typeof i=="function"?(t=!0,se(i)):i}if(t)return new Proxy({get(r){for(let i=e.length-1;i>=0;i--){const o=iu(e[i])[r];if(o!==void 0)return o}},has(r){for(let i=e.length-1;i>=0;i--)if(r in iu(e[i]))return!0;return!1},keys(){const r=[];for(let i=0;i<e.length;i++)r.push(...Object.keys(iu(e[i])));return[...new Set(r)]}},wd);const n={};for(let r=e.length-1;r>=0;r--)if(e[r]){const i=Object.getOwnPropertyDescriptors(e[r]);for(const o in i)o in n||Object.defineProperty(n,o,{enumerable:!0,get(){for(let a=e.length-1;a>=0;a--){const s=(e[a]||{})[o];if(s!==void 0)return s}}})}return n}function Ko(e,...t){const n=new Set(t.flat());if(wt in e){const i=t.map(o=>new Proxy({get(a){return o.includes(a)?e[a]:void 0},has(a){return o.includes(a)&&a in e},keys(){return o.filter(a=>a in e)}},wd));return i.push(new Proxy({get(o){return n.has(o)?void 0:e[o]},has(o){return n.has(o)?!1:o in e},keys(){return Object.keys(e).filter(o=>!n.has(o))}},wd)),i}const r=Object.getOwnPropertyDescriptors(e);return t.push(Object.keys(r).filter(i=>!n.has(i))),t.map(i=>{const o={};for(let a=0;a<i.length;a++){const s=i[a];s in e&&Object.defineProperty(o,s,r[s]?r[s]:{get(){return e[s]},set(){return!0},enumerable:!0})}return o})}let g4=0;function y4(){const e=dt.context;return e?`${e.id}${e.count++}`:`cl-${g4++}`}function sr(e){const t="fallback"in e&&{fallback:()=>e.fallback};return se(v4(()=>e.each,e.children,t||void 0))}function ee(e){let t=!1;const n=e.keyed,r=se(()=>e.when,void 0,{equals:(i,o)=>t?i===o:!i==!o});return se(()=>{const i=r();if(i){const o=e.children,a=typeof o=="function"&&o.length>0;return t=n||a,a?H(()=>o(i)):o}return e.fallback},void 0,void 0)}function b4(e,t,n){let r=n.length,i=t.length,o=r,a=0,s=0,c=t[i-1].nextSibling,l=null;for(;a<i||s<o;){if(t[a]===n[s]){a++,s++;continue}for(;t[i-1]===n[o-1];)i--,o--;if(i===a){const u=o<r?s?n[s-1].nextSibling:n[o-s]:c;for(;s<o;)e.insertBefore(n[s++],u)}else if(o===s)for(;a<i;)(!l||!l.has(t[a]))&&t[a].remove(),a++;else if(t[a]===n[o-1]&&n[s]===t[i-1]){const u=t[--i].nextSibling;e.insertBefore(n[s++],t[a++].nextSibling),e.insertBefore(n[--o],u),t[i]=n[o]}else{if(!l){l=new Map;let d=s;for(;d<o;)l.set(n[d],d++)}const u=l.get(t[a]);if(u!=null)if(s<u&&u<o){let d=a,f=1,h;for(;++d<i&&d<o&&!((h=l.get(t[d]))==null||h!==u+f);)f++;if(f>u-s){const p=t[a];for(;s<u;)e.insertBefore(n[s++],p)}else e.replaceChild(n[s++],t[a++])}else a++;else t[a++].remove()}}}const I1="_$DX_DELEGATE";function N(e,t,n){const r=document.createElement("template");r.innerHTML=e;let i=r.content.firstChild;return n&&(i=i.firstChild),i}function Yi(e,t=window.document){const n=t[I1]||(t[I1]=new Set);for(let r=0,i=e.length;r<i;r++){const o=e[r];n.has(o)||(n.add(o),t.addEventListener(o,x4))}}function $4(e,t,n){n==null?e.removeAttribute(t):e.setAttribute(t,n)}function cl(e,t){t==null?e.removeAttribute("class"):e.className=t}function w4(e,t,n={}){const r=Object.keys(t||{}),i=Object.keys(n);let o,a;for(o=0,a=i.length;o<a;o++){const s=i[o];!s||s==="undefined"||t[s]||(M1(e,s,!1),delete n[s])}for(o=0,a=r.length;o<a;o++){const s=r[o],c=!!t[s];!s||s==="undefined"||n[s]===c||!c||(M1(e,s,!0),n[s]=c)}return n}function _4(e,t,n){if(!t)return n?$4(e,"style"):t;const r=e.style;if(typeof t=="string")return r.cssText=t;typeof n=="string"&&(r.cssText=n=void 0),n||(n={}),t||(t={});let i,o;for(o in n)t[o]==null&&r.removeProperty(o),delete n[o];for(o in t)i=t[o],i!==n[o]&&(r.setProperty(o,i),n[o]=i);return n}function he(e,t,n){return H(()=>e(t,n))}function x(e,t,n,r){if(n!==void 0&&!r&&(r=[]),typeof t!="function")return ul(e,t,r,n);q(i=>ul(e,t(),i,n),r)}function M1(e,t,n){const r=t.trim().split(/\s+/);for(let i=0,o=r.length;i<o;i++)e.classList.toggle(r[i],n)}function x4(e){const t=`$$${e.type}`;let n=e.composedPath&&e.composedPath()[0]||e.target;for(e.target!==n&&Object.defineProperty(e,"target",{configurable:!0,value:n}),Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return n||document}}),dt.registry&&!dt.done&&(dt.done=!0,document.querySelectorAll("[id^=pl-]").forEach(r=>{for(;r&&r.nodeType!==8&&r.nodeValue!=="pl-"+e;){let i=r.nextSibling;r.remove(),r=i}r&&r.remove()}));n;){const r=n[t];if(r&&!n.disabled){const i=n[`${t}Data`];if(i!==void 0?r.call(n,i,e):r.call(n,e),e.cancelBubble)return}n=n._$host||n.parentNode||n.host}}function ul(e,t,n,r,i){for(dt.context&&!n&&(n=[...e.childNodes]);typeof n=="function";)n=n();if(t===n)return n;const o=typeof t,a=r!==void 0;if(e=a&&n[0]&&n[0].parentNode||e,o==="string"||o==="number"){if(dt.context)return n;if(o==="number"&&(t=t.toString()),a){let s=n[0];s&&s.nodeType===3?s.data=t:s=document.createTextNode(t),n=ri(e,n,r,s)}else n!==""&&typeof n=="string"?n=e.firstChild.data=t:n=e.textContent=t}else if(t==null||o==="boolean"){if(dt.context)return n;n=ri(e,n,r)}else{if(o==="function")return q(()=>{let s=t();for(;typeof s=="function";)s=s();n=ul(e,s,n,r)}),()=>n;if(Array.isArray(t)){const s=[],c=n&&Array.isArray(n);if(_d(s,t,n,i))return q(()=>n=ul(e,s,n,r,!0)),()=>n;if(dt.context){if(!s.length)return n;for(let l=0;l<s.length;l++)if(s[l].parentNode)return n=s}if(s.length===0){if(n=ri(e,n,r),a)return n}else c?n.length===0?D1(e,s,r):b4(e,n,s):(n&&ri(e),D1(e,s));n=s}else if(t instanceof Node){if(dt.context&&t.parentNode)return n=a?[t]:t;if(Array.isArray(n)){if(a)return n=ri(e,n,r,t);ri(e,n,null,t)}else n==null||n===""||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}}return n}function _d(e,t,n,r){let i=!1;for(let o=0,a=t.length;o<a;o++){let s=t[o],c=n&&n[o];if(s instanceof Node)e.push(s);else if(!(s==null||s===!0||s===!1))if(Array.isArray(s))i=_d(e,s,c)||i;else if(typeof s=="function")if(r){for(;typeof s=="function";)s=s();i=_d(e,Array.isArray(s)?s:[s],Array.isArray(c)?c:[c])||i}else e.push(s),i=!0;else{const l=String(s);c&&c.nodeType===3&&c.data===l?e.push(c):e.push(document.createTextNode(l))}}return i}function D1(e,t,n=null){for(let r=0,i=t.length;r<i;r++)e.insertBefore(t[r],n)}function ri(e,t,n,r){if(n===void 0)return e.textContent="";const i=r||document.createTextNode("");if(t.length){let o=!1;for(let a=t.length-1;a>=0;a--){const s=t[a];if(i!==s){const c=s.parentNode===e;!o&&!a?c?e.replaceChild(i,s):e.insertBefore(i,n):c&&s.remove()}else o=!0}}else e.insertBefore(i,n);return[i]}function k4(e){return Object.keys(e).reduce((n,r)=>{const i=e[r];return n[r]=Object.assign({},i),pg(i.value)&&!N4(i.value)&&!Array.isArray(i.value)&&(n[r].value=Object.assign({},i.value)),Array.isArray(i.value)&&(n[r].value=i.value.slice(0)),n},{})}function E4(e){return e?Object.keys(e).reduce((n,r)=>{const i=e[r];return n[r]=pg(i)&&"value"in i?i:{value:i},n[r].attribute||(n[r].attribute=C4(r)),n[r].parse="parse"in n[r]?n[r].parse:typeof n[r].value!="string",n},{}):{}}function S4(e){return Object.keys(e).reduce((n,r)=>(n[r]=e[r].value,n),{})}function O4(e,t){const n=k4(t);return Object.keys(t).forEach(i=>{const o=n[i],a=e.getAttribute(o.attribute),s=e[i];a&&(o.value=o.parse?hg(a):a),s!=null&&(o.value=Array.isArray(s)?s.slice(0):s),o.reflect&&L1(e,o.attribute,o.value),Object.defineProperty(e,i,{get(){return o.value},set(c){const l=o.value;o.value=c,o.reflect&&L1(this,o.attribute,o.value);for(let u=0,d=this.__propertyChangedCallbacks.length;u<d;u++)this.__propertyChangedCallbacks[u](i,c,l)},enumerable:!0,configurable:!0})}),n}function hg(e){if(!!e)try{return JSON.parse(e)}catch{return e}}function L1(e,t,n){if(n==null||n===!1)return e.removeAttribute(t);let r=JSON.stringify(n);e.__updating[t]=!0,r==="true"&&(r=""),e.setAttribute(t,r),Promise.resolve().then(()=>delete e.__updating[t])}function C4(e){return e.replace(/\.?([A-Z]+)/g,(t,n)=>"-"+n.toLowerCase()).replace("_","-").replace(/^-/,"")}function pg(e){return e!=null&&(typeof e=="object"||typeof e=="function")}function N4(e){return Object.prototype.toString.call(e)==="[object Function]"}function T4(e){return typeof e=="function"&&e.toString().indexOf("class")===0}let ou;function P4(e,t){const n=Object.keys(t);return class extends e{static get observedAttributes(){return n.map(i=>t[i].attribute)}constructor(){super(),this.__initialized=!1,this.__released=!1,this.__releaseCallbacks=[],this.__propertyChangedCallbacks=[],this.__updating={},this.props={}}connectedCallback(){if(this.__initialized)return;this.__releaseCallbacks=[],this.__propertyChangedCallbacks=[],this.__updating={},this.props=O4(this,t);const i=S4(this.props),o=this.Component,a=ou;try{ou=this,this.__initialized=!0,T4(o)?new o(i,{element:this}):o(i,{element:this})}finally{ou=a}}async disconnectedCallback(){if(await Promise.resolve(),this.isConnected)return;this.__propertyChangedCallbacks.length=0;let i=null;for(;i=this.__releaseCallbacks.pop();)i(this);delete this.__initialized,this.__released=!0}attributeChangedCallback(i,o,a){if(!!this.__initialized&&!this.__updating[i]&&(i=this.lookupProp(i),i in t)){if(a==null&&!this[i])return;this[i]=t[i].parse?hg(a):a}}lookupProp(i){if(!!t)return n.find(o=>i===o||i===t[o].attribute)}get renderRoot(){return this.shadowRoot||this.attachShadow({mode:"open"})}addReleaseCallback(i){this.__releaseCallbacks.push(i)}addPropertyChangedCallback(i){this.__propertyChangedCallbacks.push(i)}}}function A4(e,t={},n={}){const{BaseElement:r=HTMLElement,extension:i}=n;return o=>{if(!e)throw new Error("tag is required to register a Component");let a=customElements.get(e);return a?(a.prototype.Component=o,a):(a=P4(r,E4(t)),a.prototype.Component=o,a.prototype.registeredTag=e,customElements.define(e,a,i),a)}}function I4(e){const t=Object.keys(e),n={};for(let r=0;r<t.length;r++){const[i,o]=V(e[t[r]]);Object.defineProperty(n,t[r],{get:i,set(a){o(()=>a)}})}return n}function M4(e){if(e.assignedSlot&&e.assignedSlot._$owner)return e.assignedSlot._$owner;let t=e.parentNode;for(;t&&!t._$owner&&!(t.assignedSlot&&t.assignedSlot._$owner);)t=t.parentNode;return t&&t.assignedSlot?t.assignedSlot._$owner:e._$owner}function D4(e){return(t,n)=>{const{element:r}=n;return is(i=>{const o=I4(t);r.addPropertyChangedCallback((s,c)=>o[s]=c),r.addReleaseCallback(()=>{r.renderRoot.textContent="",i()});const a=e(o,n);return x(r.renderRoot,a)},M4(r))}}function Me(e,t,n){return arguments.length===2&&(n=t,t={}),A4(e,t)(D4(n))}const mg=sh(),pt=()=>Ki(mg),L4=/[?&]code=[^&]+/,R4=/[?&]state=[^&]+/,F4=/[?&]error=[^&]+/,z4=(e=window.location.search)=>(L4.test(e)||F4.test(e))&&R4.test(e),R1=e=>e.replace(/\w\S*/g,function(t){return t.charAt(0).toUpperCase()+t.substr(1).toLowerCase()}),j4=e=>/^\d+$/.test(e)&&e.length>=5,V4=e=>{const[t,n,r]=e.split("-");return`${n}-${r}-${t}`};var xd=function(e,t){return xd=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},xd(e,t)};function yn(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");xd(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var T=function(){return T=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},T.apply(this,arguments)};function hr(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function fe(e,t,n,r){function i(o){return o instanceof n?o:new n(function(a){a(o)})}return new(n||(n=Promise))(function(o,a){function s(u){try{l(r.next(u))}catch(d){a(d)}}function c(u){try{l(r.throw(u))}catch(d){a(d)}}function l(u){u.done?o(u.value):i(u.value).then(s,c)}l((r=r.apply(e,t||[])).next())})}function nr(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(l){return function(u){return c([l,u])}}function c(l){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,l[0]&&(n=0)),n;)try{if(r=1,i&&(o=l[0]&2?i.return:l[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,l[1])).done)return o;switch(i=0,o&&(l=[l[0]&2,o.value]),l[0]){case 0:case 1:o=l;break;case 4:return n.label++,{value:l[1],done:!1};case 5:n.label++,i=l[1],l=[0];continue;case 7:l=n.ops.pop(),n.trys.pop();continue;default:if(o=n.trys,!(o=o.length>0&&o[o.length-1])&&(l[0]===6||l[0]===2)){n=0;continue}if(l[0]===3&&(!o||l[1]>o[0]&&l[1]<o[3])){n.label=l[1];break}if(l[0]===6&&n.label<o[1]){n.label=o[1],o=l;break}if(o&&n.label<o[2]){n.label=o[2],n.ops.push(l);break}o[2]&&n.ops.pop(),n.trys.pop();continue}l=t.call(e,n)}catch(u){l=[6,u],i=0}finally{r=o=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}function dl(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var kd=function(e,t){return kd=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},kd(e,t)};function Jr(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}kd(e,t),e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var pe=function(){return pe=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},pe.apply(this,arguments)};function Ut(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function"){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n}function xe(e,t,n,r){return new(n||(n=Promise))(function(i,o){function a(l){try{c(r.next(l))}catch(u){o(u)}}function s(l){try{c(r.throw(l))}catch(u){o(u)}}function c(l){var u;l.done?i(l.value):(u=l.value,u instanceof n?u:new n(function(d){d(u)})).then(a,s)}c((r=r.apply(e,t||[])).next())})}function ke(e,t){var n,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(c){return function(l){return function(u){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(i=2&u[0]?r.return:u[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,u[1])).done)return i;switch(r=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,r=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(i=a.trys,!((i=i.length>0&&i[i.length-1])||u[0]!==6&&u[0]!==2)){a=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(u[0]===6&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(d){u=[6,d],r=0}finally{n=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([c,l])}}}function Ai(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(t===void 0||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(s){i={error:s}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function Ed(e,t,n){if(n||arguments.length===2)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}var Sn=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function lh(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Xi(e,t){return e(t={exports:{}},t.exports),t.exports}var Yn,os,Na=function(e){return e&&e.Math==Math&&e},ve=Na(typeof globalThis=="object"&&globalThis)||Na(typeof window=="object"&&window)||Na(typeof self=="object"&&self)||Na(typeof Sn=="object"&&Sn)||function(){return this}()||Function("return this")(),ze=function(e){try{return!!e()}catch{return!0}},Ae=!ze(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7}),ma=!ze(function(){var e=function(){}.bind();return typeof e!="function"||e.hasOwnProperty("prototype")}),Ta=Function.prototype.call,Dt=ma?Ta.bind(Ta):function(){return Ta.apply(Ta,arguments)},F1={}.propertyIsEnumerable,z1=Object.getOwnPropertyDescriptor,U4=z1&&!F1.call({1:2},1)?function(e){var t=z1(this,e);return!!t&&t.enumerable}:F1,ch={f:U4},Ur=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},vg=Function,gg=vg.prototype,B4=gg.bind,Sd=gg.call,H4=ma&&B4.bind(Sd,Sd),$e=function(e){return e instanceof vg?ma?H4(e):function(){return Sd.apply(e,arguments)}:void 0},q4=$e({}.toString),W4=$e("".slice),Vn=function(e){return W4(q4(e),8,-1)},au=Object,G4=$e("".split),yg=ze(function(){return!au("z").propertyIsEnumerable(0)})?function(e){return Vn(e)=="String"?G4(e,""):au(e)}:au,Zi=function(e){return e==null},K4=TypeError,va=function(e){if(Zi(e))throw K4("Can't call method on "+e);return e},Mn=function(e){return yg(va(e))},su=typeof document=="object"&&document.all,Sc={all:su,IS_HTMLDDA:su===void 0&&su!==void 0},Q4=Sc.all,Re=Sc.IS_HTMLDDA?function(e){return typeof e=="function"||e===Q4}:function(e){return typeof e=="function"},Y4=Sc.all,qe=Sc.IS_HTMLDDA?function(e){return typeof e=="object"?e!==null:Re(e)||e===Y4}:function(e){return typeof e=="object"?e!==null:Re(e)},X4=function(e){return Re(e)?e:void 0},bn=function(e,t){return arguments.length<2?X4(ve[e]):ve[e]&&ve[e][t]},Br=$e({}.isPrototypeOf),lu=bn("navigator","userAgent")||"",j1=ve.process,V1=ve.Deno,U1=j1&&j1.versions||V1&&V1.version,B1=U1&&U1.v8;B1&&(os=(Yn=B1.split("."))[0]>0&&Yn[0]<4?1:+(Yn[0]+Yn[1])),!os&&lu&&(!(Yn=lu.match(/Edge\/(\d+)/))||Yn[1]>=74)&&(Yn=lu.match(/Chrome\/(\d+)/))&&(os=+Yn[1]);var fl=os,Jt=!!Object.getOwnPropertySymbols&&!ze(function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&fl&&fl<41}),uh=Jt&&!Symbol.sham&&typeof Symbol.iterator=="symbol",Z4=Object,Ii=uh?function(e){return typeof e=="symbol"}:function(e){var t=bn("Symbol");return Re(t)&&Br(t.prototype,Z4(e))},J4=String,Ji=function(e){try{return J4(e)}catch{return"Object"}},e7=TypeError,dh=function(e){if(Re(e))return e;throw e7(Ji(e)+" is not a function")},hl=function(e,t){var n=e[t];return Zi(n)?void 0:dh(n)},t7=TypeError,n7=Object.defineProperty,fh=function(e,t){try{n7(ve,e,{value:t,configurable:!0,writable:!0})}catch{ve[e]=t}return t},lr=ve["__core-js_shared__"]||fh("__core-js_shared__",{}),xr=Xi(function(e){(e.exports=function(t,n){return lr[t]||(lr[t]=n!==void 0?n:{})})("versions",[]).push({version:"3.25.4",mode:"global",copyright:"\xA9 2014-2022 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.25.4/LICENSE",source:"https://github.com/zloirock/core-js"})}),r7=Object,eo=function(e){return r7(va(e))},i7=$e({}.hasOwnProperty),oe=Object.hasOwn||function(e,t){return i7(eo(e),t)},o7=0,a7=Math.random(),s7=$e(1 .toString),Mi=function(e){return"Symbol("+(e===void 0?"":e)+")_"+s7(++o7+a7,36)},mo=xr("wks"),Fr=ve.Symbol,H1=Fr&&Fr.for,l7=uh?Fr:Fr&&Fr.withoutSetter||Mi,nt=function(e){if(!oe(mo,e)||!Jt&&typeof mo[e]!="string"){var t="Symbol."+e;Jt&&oe(Fr,e)?mo[e]=Fr[e]:mo[e]=uh&&H1?H1(t):l7(t)}return mo[e]},c7=TypeError,u7=nt("toPrimitive"),d7=function(e,t){if(!qe(e)||Ii(e))return e;var n,r=hl(e,u7);if(r){if(t===void 0&&(t="default"),n=Dt(r,e,t),!qe(n)||Ii(n))return n;throw c7("Can't convert object to primitive value")}return t===void 0&&(t="number"),function(i,o){var a,s;if(o==="string"&&Re(a=i.toString)&&!qe(s=Dt(a,i))||Re(a=i.valueOf)&&!qe(s=Dt(a,i))||o!=="string"&&Re(a=i.toString)&&!qe(s=Dt(a,i)))return s;throw t7("Can't convert object to primitive value")}(e,t)},Hr=function(e){var t=d7(e,"string");return Ii(t)?t:t+""},Od=ve.document,f7=qe(Od)&&qe(Od.createElement),bg=function(e){return f7?Od.createElement(e):{}},$g=!Ae&&!ze(function(){return Object.defineProperty(bg("div"),"a",{get:function(){return 7}}).a!=7}),q1=Object.getOwnPropertyDescriptor,ga={f:Ae?q1:function(e,t){if(e=Mn(e),t=Hr(t),$g)try{return q1(e,t)}catch{}if(oe(e,t))return Ur(!Dt(ch.f,e,t),e[t])}},wg=Ae&&ze(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!=42}),h7=String,p7=TypeError,bt=function(e){if(qe(e))return e;throw p7(h7(e)+" is not an object")},m7=TypeError,cu=Object.defineProperty,v7=Object.getOwnPropertyDescriptor,Pt={f:Ae?wg?function(e,t,n){if(bt(e),t=Hr(t),bt(n),typeof e=="function"&&t==="prototype"&&"value"in n&&"writable"in n&&!n.writable){var r=v7(e,t);r&&r.writable&&(e[t]=n.value,n={configurable:"configurable"in n?n.configurable:r.configurable,enumerable:"enumerable"in n?n.enumerable:r.enumerable,writable:!1})}return cu(e,t,n)}:cu:function(e,t,n){if(bt(e),t=Hr(t),bt(n),$g)try{return cu(e,t,n)}catch{}if("get"in n||"set"in n)throw m7("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},Oc=Ae?function(e,t,n){return Pt.f(e,t,Ur(1,n))}:function(e,t,n){return e[t]=n,e},_g=Function.prototype,g7=Ae&&Object.getOwnPropertyDescriptor,uu=oe(_g,"name"),hh={EXISTS:uu,PROPER:uu&&function(){}.name==="something",CONFIGURABLE:uu&&(!Ae||Ae&&g7(_g,"name").configurable)},y7=$e(Function.toString);Re(lr.inspectSource)||(lr.inspectSource=function(e){return y7(e)});var pl,jo,ml,xg=lr.inspectSource,W1=ve.WeakMap,b7=Re(W1)&&/native code/.test(String(W1)),G1=xr("keys"),Cc=function(e){return G1[e]||(G1[e]=Mi(e))},to={},Cd=ve.TypeError,$7=ve.WeakMap;if(b7||lr.state){var Er=lr.state||(lr.state=new $7),w7=$e(Er.get),K1=$e(Er.has),_7=$e(Er.set);pl=function(e,t){if(K1(Er,e))throw Cd("Object already initialized");return t.facade=e,_7(Er,e,t),t},jo=function(e){return w7(Er,e)||{}},ml=function(e){return K1(Er,e)}}else{var ii=Cc("state");to[ii]=!0,pl=function(e,t){if(oe(e,ii))throw Cd("Object already initialized");return t.facade=e,Oc(e,ii,t),t},jo=function(e){return oe(e,ii)?e[ii]:{}},ml=function(e){return oe(e,ii)}}var nn={set:pl,get:jo,has:ml,enforce:function(e){return ml(e)?jo(e):pl(e,{})},getterFor:function(e){return function(t){var n;if(!qe(t)||(n=jo(t)).type!==e)throw Cd("Incompatible receiver, "+e+" required");return n}}},x7=Xi(function(e){var t=hh.CONFIGURABLE,n=nn.enforce,r=nn.get,i=Object.defineProperty,o=Ae&&!ze(function(){return i(function(){},"length",{value:8}).length!==8}),a=String(String).split("String"),s=e.exports=function(c,l,u){String(l).slice(0,7)==="Symbol("&&(l="["+String(l).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),u&&u.getter&&(l="get "+l),u&&u.setter&&(l="set "+l),(!oe(c,"name")||t&&c.name!==l)&&(Ae?i(c,"name",{value:l,configurable:!0}):c.name=l),o&&u&&oe(u,"arity")&&c.length!==u.arity&&i(c,"length",{value:u.arity});try{u&&oe(u,"constructor")&&u.constructor?Ae&&i(c,"prototype",{writable:!1}):c.prototype&&(c.prototype=void 0)}catch{}var d=n(c);return oe(d,"source")||(d.source=a.join(typeof l=="string"?l:"")),c};Function.prototype.toString=s(function(){return Re(this)&&r(this).source||xg(this)},"toString")}),Rt=function(e,t,n,r){r||(r={});var i=r.enumerable,o=r.name!==void 0?r.name:t;if(Re(n)&&x7(n,o,r),r.global)i?e[t]=n:fh(t,n);else{try{r.unsafe?e[t]&&(i=!0):delete e[t]}catch{}i?e[t]=n:Pt.f(e,t,{value:n,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return e},k7=Math.ceil,E7=Math.floor,S7=Math.trunc||function(e){var t=+e;return(t>0?E7:k7)(t)},ph=function(e){var t=+e;return t!=t||t===0?0:S7(t)},O7=Math.max,C7=Math.min,Nd=function(e,t){var n=ph(e);return n<0?O7(n+t,0):C7(n,t)},N7=Math.min,kg=function(e){return e>0?N7(ph(e),9007199254740991):0},no=function(e){return kg(e.length)},Q1=function(e){return function(t,n,r){var i,o=Mn(t),a=no(o),s=Nd(r,a);if(e&&n!=n){for(;a>s;)if((i=o[s++])!=i)return!0}else for(;a>s;s++)if((e||s in o)&&o[s]===n)return e||s||0;return!e&&-1}},Eg={includes:Q1(!0),indexOf:Q1(!1)},T7=Eg.indexOf,Y1=$e([].push),Sg=function(e,t){var n,r=Mn(e),i=0,o=[];for(n in r)!oe(to,n)&&oe(r,n)&&Y1(o,n);for(;t.length>i;)oe(r,n=t[i++])&&(~T7(o,n)||Y1(o,n));return o},vl=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],P7=vl.concat("length","prototype"),Qo={f:Object.getOwnPropertyNames||function(e){return Sg(e,P7)}},Nc={f:Object.getOwnPropertySymbols},A7=$e([].concat),I7=bn("Reflect","ownKeys")||function(e){var t=Qo.f(bt(e)),n=Nc.f;return n?A7(t,n(e)):t},Og=function(e,t,n){for(var r=I7(t),i=Pt.f,o=ga.f,a=0;a<r.length;a++){var s=r[a];oe(e,s)||n&&oe(n,s)||i(e,s,o(t,s))}},M7=/#|\.prototype\./,ya=function(e,t){var n=L7[D7(e)];return n==F7||n!=R7&&(Re(t)?ze(t):!!t)},D7=ya.normalize=function(e){return String(e).replace(M7,".").toLowerCase()},L7=ya.data={},R7=ya.NATIVE="N",F7=ya.POLYFILL="P",Td=ya,z7=ga.f,$t=function(e,t){var n,r,i,o,a,s=e.target,c=e.global,l=e.stat;if(n=c?ve:l?ve[s]||fh(s,{}):(ve[s]||{}).prototype)for(r in t){if(o=t[r],i=e.dontCallGetSet?(a=z7(n,r))&&a.value:n[r],!Td(c?r:s+(l?".":"#")+r,e.forced)&&i!==void 0){if(typeof o==typeof i)continue;Og(o,i)}(e.sham||i&&i.sham)&&Oc(o,"sham",!0),Rt(n,r,o,e)}},Cg={};Cg[nt("toStringTag")]="z";var du,mh=String(Cg)==="[object z]",j7=nt("toStringTag"),V7=Object,U7=Vn(function(){return arguments}())=="Arguments",ei=mh?Vn:function(e){var t,n,r;return e===void 0?"Undefined":e===null?"Null":typeof(n=function(i,o){try{return i[o]}catch{}}(t=V7(e),j7))=="string"?n:U7?Vn(t):(r=Vn(t))=="Object"&&Re(t.callee)?"Arguments":r},B7=String,Bn=function(e){if(ei(e)==="Symbol")throw TypeError("Cannot convert a Symbol value to a string");return B7(e)},H7=nt("match"),q7=TypeError,Ng=function(e){if(function(t){var n;return qe(t)&&((n=t[H7])!==void 0?!!n:Vn(t)=="RegExp")}(e))throw q7("The method doesn't accept regular expressions");return e},W7=nt("match"),Tg=function(e){var t=/./;try{"/./"[e](t)}catch{try{return t[W7]=!1,"/./"[e](t)}catch{}}return!1},G7=ga.f,X1=$e("".startsWith),K7=$e("".slice),Q7=Math.min,Pg=Tg("startsWith"),Y7=!(Pg||(du=G7(String.prototype,"startsWith"),!du||du.writable));$t({target:"String",proto:!0,forced:!Y7&&!Pg},{startsWith:function(e){var t=Bn(va(this));Ng(e);var n=kg(Q7(arguments.length>1?arguments[1]:void 0,t.length)),r=Bn(e);return X1?X1(t,r,n):K7(t,n,n+r.length)===r}});var vh=function(e,t){return $e(ve[e].prototype[t])};vh("String","startsWith");var gl=Array.isArray||function(e){return Vn(e)=="Array"},X7=TypeError,Z1=function(e){if(e>9007199254740991)throw X7("Maximum allowed index exceeded");return e},Yo=function(e,t,n){var r=Hr(t);r in e?Pt.f(e,r,Ur(0,n)):e[r]=n},Ag=function(){},Z7=[],Ig=bn("Reflect","construct"),gh=/^\s*(?:class|function)\b/,J7=$e(gh.exec),e6=!gh.exec(Ag),vo=function(e){if(!Re(e))return!1;try{return Ig(Ag,Z7,e),!0}catch{return!1}},Mg=function(e){if(!Re(e))return!1;switch(ei(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return e6||!!J7(gh,xg(e))}catch{return!0}};Mg.sham=!0;var J1,yh=!Ig||ze(function(){var e;return vo(vo.call)||!vo(Object)||!vo(function(){e=!0})||e})?Mg:vo,t6=nt("species"),ep=Array,Dg=function(e,t){return new(function(n){var r;return gl(n)&&(r=n.constructor,(yh(r)&&(r===ep||gl(r.prototype))||qe(r)&&(r=r[t6])===null)&&(r=void 0)),r===void 0?ep:r}(e))(t===0?0:t)},n6=nt("species"),Lg=nt("isConcatSpreadable"),r6=fl>=51||!ze(function(){var e=[];return e[Lg]=!1,e.concat()[0]!==e}),i6=(J1="concat",fl>=51||!ze(function(){var e=[];return(e.constructor={})[n6]=function(){return{foo:1}},e[J1](Boolean).foo!==1})),o6=function(e){if(!qe(e))return!1;var t=e[Lg];return t!==void 0?!!t:gl(e)};$t({target:"Array",proto:!0,arity:1,forced:!r6||!i6},{concat:function(e){var t,n,r,i,o,a=eo(this),s=Dg(a,0),c=0;for(t=-1,r=arguments.length;t<r;t++)if(o6(o=t===-1?a:arguments[t]))for(i=no(o),Z1(c+i),n=0;n<i;n++,c++)n in o&&Yo(s,c,o[n]);else Z1(c+1),Yo(s,c++,o);return s.length=c,s}});var a6=mh?{}.toString:function(){return"[object "+ei(this)+"]"};mh||Rt(Object.prototype,"toString",a6,{unsafe:!0});var Pa,bh=Object.keys||function(e){return Sg(e,vl)},s6=Ae&&!wg?Object.defineProperties:function(e,t){bt(e);for(var n,r=Mn(t),i=bh(t),o=i.length,a=0;o>a;)Pt.f(e,n=i[a++],r[n]);return e},Rg={f:s6},l6=bn("document","documentElement"),Fg=Cc("IE_PROTO"),fu=function(){},zg=function(e){return"<script>"+e+"<\/script>"},tp=function(e){e.write(zg("")),e.close();var t=e.parentWindow.Object;return e=null,t},as=function(){try{Pa=new ActiveXObject("htmlfile")}catch{}var e,t;as=typeof document<"u"?document.domain&&Pa?tp(Pa):((t=bg("iframe")).style.display="none",l6.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(zg("document.F=Object")),e.close(),e.F):tp(Pa);for(var n=vl.length;n--;)delete as.prototype[vl[n]];return as()};to[Fg]=!0;var pr=Object.create||function(e,t){var n;return e!==null?(fu.prototype=bt(e),n=new fu,fu.prototype=null,n[Fg]=e):n=as(),t===void 0?n:Rg.f(n,t)},c6=Array,u6=Math.max,jg=Qo.f,Vg=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],d6=function(e){try{return jg(e)}catch{return function(n,r,i){for(var o=no(n),a=Nd(r,o),s=Nd(i===void 0?o:i,o),c=c6(u6(s-a,0)),l=0;a<s;a++,l++)Yo(c,l,n[a]);return c.length=l,c}(Vg)}},$h={f:function(e){return Vg&&Vn(e)=="Window"?d6(e):jg(Mn(e))}},Ug={f:nt},Xo=ve,f6=Pt.f,Bt=function(e){var t=Xo.Symbol||(Xo.Symbol={});oe(t,e)||f6(t,e,{value:Ug.f(e)})},Bg=function(){var e=bn("Symbol"),t=e&&e.prototype,n=t&&t.valueOf,r=nt("toPrimitive");t&&!t[r]&&Rt(t,r,function(i){return Dt(n,this)},{arity:1})},h6=Pt.f,np=nt("toStringTag"),ar=function(e,t,n){e&&!n&&(e=e.prototype),e&&!oe(e,np)&&h6(e,np,{configurable:!0,value:t})},p6=$e($e.bind),Tc=function(e,t){return dh(e),t===void 0?e:ma?p6(e,t):function(){return e.apply(t,arguments)}},rp=$e([].push),Xn=function(e){var t=e==1,n=e==2,r=e==3,i=e==4,o=e==6,a=e==7,s=e==5||o;return function(c,l,u,d){for(var f,h,p=eo(c),m=yg(p),v=Tc(l,u),b=no(m),y=0,g=d||Dg,_=t?g(c,b):n||a?g(c,0):void 0;b>y;y++)if((s||y in m)&&(h=v(f=m[y],y,p),e))if(t)_[y]=h;else if(h)switch(e){case 3:return!0;case 5:return f;case 6:return y;case 2:rp(_,f)}else switch(e){case 4:return!1;case 7:rp(_,f)}return o?-1:r||i?i:_}},Pc={forEach:Xn(0),map:Xn(1),filter:Xn(2),some:Xn(3),every:Xn(4),find:Xn(5),findIndex:Xn(6),filterReject:Xn(7)}.forEach,Ht=Cc("hidden"),m6=nn.set,ip=nn.getterFor("Symbol"),tn=Object.prototype,yi=ve.Symbol,Mo=yi&&yi.prototype,v6=ve.TypeError,hu=ve.QObject,Hg=ga.f,ir=Pt.f,qg=$h.f,g6=ch.f,Wg=$e([].push),Hn=xr("symbols"),ba=xr("op-symbols"),y6=xr("wks"),pu=!hu||!hu.prototype||!hu.prototype.findChild,Pd=Ae&&ze(function(){return pr(ir({},"a",{get:function(){return ir(this,"a",{value:7}).a}})).a!=7})?function(e,t,n){var r=Hg(tn,t);r&&delete tn[t],ir(e,t,n),r&&e!==tn&&ir(tn,t,r)}:ir,mu=function(e,t){var n=Hn[e]=pr(Mo);return m6(n,{type:"Symbol",tag:e,description:t}),Ae||(n.description=t),n},yl=function(e,t,n){e===tn&&yl(ba,t,n),bt(e);var r=Hr(t);return bt(n),oe(Hn,r)?(n.enumerable?(oe(e,Ht)&&e[Ht][r]&&(e[Ht][r]=!1),n=pr(n,{enumerable:Ur(0,!1)})):(oe(e,Ht)||ir(e,Ht,Ur(1,{})),e[Ht][r]=!0),Pd(e,r,n)):ir(e,r,n)},vu=function(e,t){bt(e);var n=Mn(t),r=bh(n).concat(Gg(n));return Pc(r,function(i){Ae&&!Dt(Ad,n,i)||yl(e,i,n[i])}),e},Ad=function(e){var t=Hr(e),n=Dt(g6,this,t);return!(this===tn&&oe(Hn,t)&&!oe(ba,t))&&(!(n||!oe(this,t)||!oe(Hn,t)||oe(this,Ht)&&this[Ht][t])||n)},op=function(e,t){var n=Mn(e),r=Hr(t);if(n!==tn||!oe(Hn,r)||oe(ba,r)){var i=Hg(n,r);return!i||!oe(Hn,r)||oe(n,Ht)&&n[Ht][r]||(i.enumerable=!0),i}},ap=function(e){var t=qg(Mn(e)),n=[];return Pc(t,function(r){oe(Hn,r)||oe(to,r)||Wg(n,r)}),n},Gg=function(e){var t=e===tn,n=qg(t?ba:Mn(e)),r=[];return Pc(n,function(i){!oe(Hn,i)||t&&!oe(tn,i)||Wg(r,Hn[i])}),r};Jt||(Mo=(yi=function(){if(Br(Mo,this))throw v6("Symbol is not a constructor");var e=arguments.length&&arguments[0]!==void 0?Bn(arguments[0]):void 0,t=Mi(e),n=function(r){this===tn&&Dt(n,ba,r),oe(this,Ht)&&oe(this[Ht],t)&&(this[Ht][t]=!1),Pd(this,t,Ur(1,r))};return Ae&&pu&&Pd(tn,t,{configurable:!0,set:n}),mu(t,e)}).prototype,Rt(Mo,"toString",function(){return ip(this).tag}),Rt(yi,"withoutSetter",function(e){return mu(Mi(e),e)}),ch.f=Ad,Pt.f=yl,Rg.f=vu,ga.f=op,Qo.f=$h.f=ap,Nc.f=Gg,Ug.f=function(e){return mu(nt(e),e)},Ae&&(ir(Mo,"description",{configurable:!0,get:function(){return ip(this).description}}),Rt(tn,"propertyIsEnumerable",Ad,{unsafe:!0}))),$t({global:!0,constructor:!0,wrap:!0,forced:!Jt,sham:!Jt},{Symbol:yi}),Pc(bh(y6),function(e){Bt(e)}),$t({target:"Symbol",stat:!0,forced:!Jt},{useSetter:function(){pu=!0},useSimple:function(){pu=!1}}),$t({target:"Object",stat:!0,forced:!Jt,sham:!Ae},{create:function(e,t){return t===void 0?pr(e):vu(pr(e),t)},defineProperty:yl,defineProperties:vu,getOwnPropertyDescriptor:op}),$t({target:"Object",stat:!0,forced:!Jt},{getOwnPropertyNames:ap}),Bg(),ar(yi,"Symbol"),to[Ht]=!0;var Kg=Jt&&!!Symbol.for&&!!Symbol.keyFor,gu=xr("string-to-symbol-registry"),b6=xr("symbol-to-string-registry");$t({target:"Symbol",stat:!0,forced:!Kg},{for:function(e){var t=Bn(e);if(oe(gu,t))return gu[t];var n=bn("Symbol")(t);return gu[t]=n,b6[n]=t,n}});var sp=xr("symbol-to-string-registry");$t({target:"Symbol",stat:!0,forced:!Kg},{keyFor:function(e){if(!Ii(e))throw TypeError(Ji(e)+" is not a symbol");if(oe(sp,e))return sp[e]}});var Qg=Function.prototype,lp=Qg.apply,cp=Qg.call,Yg=typeof Reflect=="object"&&Reflect.apply||(ma?cp.bind(lp):function(){return cp.apply(lp,arguments)}),wh=$e([].slice),cr=bn("JSON","stringify"),Aa=$e(/./.exec),up=$e("".charAt),$6=$e("".charCodeAt),w6=$e("".replace),_6=$e(1 .toString),x6=/[\uD800-\uDFFF]/g,dp=/^[\uD800-\uDBFF]$/,fp=/^[\uDC00-\uDFFF]$/,hp=!Jt||ze(function(){var e=bn("Symbol")();return cr([e])!="[null]"||cr({a:e})!="{}"||cr(Object(e))!="{}"}),pp=ze(function(){return cr("\uDF06\uD834")!=='"\\udf06\\ud834"'||cr("\uDEAD")!=='"\\udead"'}),k6=function(e,t){var n=wh(arguments),r=t;if((qe(t)||e!==void 0)&&!Ii(e))return gl(t)||(t=function(i,o){if(Re(r)&&(o=Dt(r,this,i,o)),!Ii(o))return o}),n[1]=t,Yg(cr,null,n)},E6=function(e,t,n){var r=up(n,t-1),i=up(n,t+1);return Aa(dp,e)&&!Aa(fp,i)||Aa(fp,e)&&!Aa(dp,r)?"\\u"+_6($6(e,0),16):e};cr&&$t({target:"JSON",stat:!0,arity:3,forced:hp||pp},{stringify:function(e,t,n){var r=wh(arguments),i=Yg(hp?k6:cr,null,r);return pp&&typeof i=="string"?w6(i,x6,E6):i}});var S6=!Jt||ze(function(){Nc.f(1)});$t({target:"Object",stat:!0,forced:S6},{getOwnPropertySymbols:function(e){var t=Nc.f;return t?t(eo(e)):[]}}),Bt("asyncIterator");var O6=Pt.f,Fn=ve.Symbol,Sr=Fn&&Fn.prototype;if(Ae&&Re(Fn)&&(!("description"in Sr)||Fn().description!==void 0)){var mp={},Ia=function(){var e=arguments.length<1||arguments[0]===void 0?void 0:Bn(arguments[0]),t=Br(Sr,this)?new Fn(e):e===void 0?Fn():Fn(e);return e===""&&(mp[t]=!0),t};Og(Ia,Fn),Ia.prototype=Sr,Sr.constructor=Ia;var C6=String(Fn("test"))=="Symbol(test)",N6=$e(Sr.valueOf),T6=$e(Sr.toString),P6=/^Symbol\((.*)\)[^)]+$/,A6=$e("".replace),I6=$e("".slice);O6(Sr,"description",{configurable:!0,get:function(){var e=N6(this);if(oe(mp,e))return"";var t=T6(e),n=C6?I6(t,7,-1):A6(t,P6,"$1");return n===""?void 0:n}}),$t({global:!0,constructor:!0,forced:!0},{Symbol:Ia})}Bt("hasInstance"),Bt("isConcatSpreadable"),Bt("iterator"),Bt("match"),Bt("matchAll"),Bt("replace"),Bt("search"),Bt("species"),Bt("split"),Bt("toPrimitive"),Bg(),Bt("toStringTag"),ar(bn("Symbol"),"Symbol"),Bt("unscopables"),ar(ve.JSON,"JSON",!0),ar(Math,"Math",!0),$t({global:!0},{Reflect:{}}),ar(ve.Reflect,"Reflect",!0),Xo.Symbol;var zr,vp,gp,M6=$e("".charAt),yp=$e("".charCodeAt),D6=$e("".slice),bp=function(e){return function(t,n){var r,i,o=Bn(va(t)),a=ph(n),s=o.length;return a<0||a>=s?e?"":void 0:(r=yp(o,a))<55296||r>56319||a+1===s||(i=yp(o,a+1))<56320||i>57343?e?M6(o,a):r:e?D6(o,a,a+2):i-56320+(r-55296<<10)+65536}},L6={codeAt:bp(!1),charAt:bp(!0)},R6=!ze(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}),$p=Cc("IE_PROTO"),Id=Object,F6=Id.prototype,mr=R6?Id.getPrototypeOf:function(e){var t=eo(e);if(oe(t,$p))return t[$p];var n=t.constructor;return Re(n)&&t instanceof n?n.prototype:t instanceof Id?F6:null},Md=nt("iterator"),Xg=!1;[].keys&&("next"in(gp=[].keys())?(vp=mr(mr(gp)))!==Object.prototype&&(zr=vp):Xg=!0);var z6=!qe(zr)||ze(function(){var e={};return zr[Md].call(e)!==e});z6&&(zr={}),Re(zr[Md])||Rt(zr,Md,function(){return this});var _h={IteratorPrototype:zr,BUGGY_SAFARI_ITERATORS:Xg},Di={},j6=_h.IteratorPrototype,V6=function(){return this},U6=String,B6=TypeError,Tn=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,n={};try{(e=$e(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),t=n instanceof Array}catch{}return function(r,i){return bt(r),function(o){if(typeof o=="object"||Re(o))return o;throw B6("Can't set "+U6(o)+" as a prototype")}(i),t?e(r,i):r.__proto__=i,r}}():void 0),H6=hh.PROPER,q6=hh.CONFIGURABLE,wp=_h.IteratorPrototype,Ma=_h.BUGGY_SAFARI_ITERATORS,go=nt("iterator"),W6=function(){return this},xh=function(e,t,n,r,i,o,a){(function(b,y,g,_){var k=y+" Iterator";b.prototype=pr(j6,{next:Ur(+!_,g)}),ar(b,k,!1),Di[k]=V6})(n,t,r);var s,c,l,u=function(b){if(b===i&&m)return m;if(!Ma&&b in h)return h[b];switch(b){case"keys":case"values":case"entries":return function(){return new n(this,b)}}return function(){return new n(this)}},d=t+" Iterator",f=!1,h=e.prototype,p=h[go]||h["@@iterator"]||i&&h[i],m=!Ma&&p||u(i),v=t=="Array"&&h.entries||p;if(v&&(s=mr(v.call(new e)))!==Object.prototype&&s.next&&(mr(s)!==wp&&(Tn?Tn(s,wp):Re(s[go])||Rt(s,go,W6)),ar(s,d,!0)),H6&&i=="values"&&p&&p.name!=="values"&&(q6?Oc(h,"name","values"):(f=!0,m=function(){return Dt(p,this)})),i)if(c={values:u("values"),keys:o?m:u("keys"),entries:u("entries")},a)for(l in c)(Ma||f||!(l in h))&&Rt(h,l,c[l]);else $t({target:t,proto:!0,forced:Ma||f},c);return h[go]!==m&&Rt(h,go,m,{name:i}),Di[t]=m,c},Li=function(e,t){return{value:e,done:t}},G6=L6.charAt,K6=nn.set,Q6=nn.getterFor("String Iterator");xh(String,"String",function(e){K6(this,{type:"String Iterator",string:Bn(e),index:0})},function(){var e,t=Q6(this),n=t.string,r=t.index;return r>=n.length?Li(void 0,!0):(e=G6(n,r),t.index+=e.length,Li(e,!1))});var Dd=function(e,t,n){var r,i;bt(e);try{if(!(r=hl(e,"return"))){if(t==="throw")throw n;return n}r=Dt(r,e)}catch(o){i=!0,r=o}if(t==="throw")throw n;if(i)throw r;return bt(r),n},Y6=function(e,t,n,r){try{return r?t(bt(n)[0],n[1]):t(n)}catch(i){Dd(e,"throw",i)}},X6=nt("iterator"),Z6=Array.prototype,Zg=function(e){return e!==void 0&&(Di.Array===e||Z6[X6]===e)},J6=nt("iterator"),kh=function(e){if(!Zi(e))return hl(e,J6)||hl(e,"@@iterator")||Di[ei(e)]},e8=TypeError,Jg=function(e,t){var n=arguments.length<2?kh(e):t;if(dh(n))return bt(Dt(n,e));throw e8(Ji(e)+" is not iterable")},_p=Array,ey=nt("iterator"),ty=!1;try{var t8=0,xp={next:function(){return{done:!!t8++}},return:function(){ty=!0}};xp[ey]=function(){return this},Array.from(xp,function(){throw 2})}catch{}var ny=function(e,t){if(!t&&!ty)return!1;var n=!1;try{var r={};r[ey]=function(){return{next:function(){return{done:n=!0}}}},e(r)}catch{}return n},n8=!ny(function(e){Array.from(e)});$t({target:"Array",stat:!0,forced:n8},{from:function(e){var t=eo(e),n=yh(this),r=arguments.length,i=r>1?arguments[1]:void 0,o=i!==void 0;o&&(i=Tc(i,r>2?arguments[2]:void 0));var a,s,c,l,u,d,f=kh(t),h=0;if(!f||this===_p&&Zg(f))for(a=no(t),s=n?new this(a):_p(a);a>h;h++)d=o?i(t[h],h):t[h],Yo(s,h,d);else for(u=(l=Jg(t,f)).next,s=n?new this:[];!(c=Dt(u,l)).done;h++)d=o?Y6(l,i,[c.value,h],!0):c.value,Yo(s,h,d);return s.length=h,s}}),Xo.Array.from;var qt,Ei,bl,r8=typeof ArrayBuffer<"u"&&typeof DataView<"u",i8=Pt.f,ry=nn.enforce,o8=nn.get,$l=ve.Int8Array,Ld=$l&&$l.prototype,kp=ve.Uint8ClampedArray,Ep=kp&&kp.prototype,xn=$l&&mr($l),hn=Ld&&mr(Ld),a8=Object.prototype,Rd=ve.TypeError,Sp=nt("toStringTag"),Fd=Mi("TYPED_ARRAY_TAG"),Un=r8&&!!Tn&&ei(ve.opera)!=="Opera",iy=!1,zn={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},Eh={BigInt64Array:8,BigUint64Array:8},oy=function(e){var t=mr(e);if(qe(t)){var n=o8(t);return n&&oe(n,"TypedArrayConstructor")?n.TypedArrayConstructor:oy(t)}},Op=function(e){if(!qe(e))return!1;var t=ei(e);return oe(zn,t)||oe(Eh,t)};for(qt in zn)(bl=(Ei=ve[qt])&&Ei.prototype)?ry(bl).TypedArrayConstructor=Ei:Un=!1;for(qt in Eh)(bl=(Ei=ve[qt])&&Ei.prototype)&&(ry(bl).TypedArrayConstructor=Ei);if((!Un||!Re(xn)||xn===Function.prototype)&&(xn=function(){throw Rd("Incorrect invocation")},Un))for(qt in zn)ve[qt]&&Tn(ve[qt],xn);if((!Un||!hn||hn===a8)&&(hn=xn.prototype,Un))for(qt in zn)ve[qt]&&Tn(ve[qt].prototype,hn);if(Un&&mr(Ep)!==hn&&Tn(Ep,hn),Ae&&!oe(hn,Sp))for(qt in iy=!0,i8(hn,Sp,{get:function(){return qe(this)?this[Fd]:void 0}}),zn)ve[qt]&&Oc(ve[qt],Fd,qt);var Ac={NATIVE_ARRAY_BUFFER_VIEWS:Un,TYPED_ARRAY_TAG:iy&&Fd,aTypedArray:function(e){if(Op(e))return e;throw Rd("Target is not a typed array")},aTypedArrayConstructor:function(e){if(Re(e)&&(!Tn||Br(xn,e)))return e;throw Rd(Ji(e)+" is not a typed array constructor")},exportTypedArrayMethod:function(e,t,n,r){if(Ae){if(n)for(var i in zn){var o=ve[i];if(o&&oe(o.prototype,e))try{delete o.prototype[e]}catch{try{o.prototype[e]=t}catch{}}}hn[e]&&!n||Rt(hn,e,n?t:Un&&Ld[e]||t,r)}},exportTypedArrayStaticMethod:function(e,t,n){var r,i;if(Ae){if(Tn){if(n){for(r in zn)if((i=ve[r])&&oe(i,e))try{delete i[e]}catch{}}if(xn[e]&&!n)return;try{return Rt(xn,e,n?t:Un&&xn[e]||t)}catch{}}for(r in zn)!(i=ve[r])||i[e]&&!n||Rt(i,e,t)}},getTypedArrayConstructor:oy,isView:function(e){if(!qe(e))return!1;var t=ei(e);return t==="DataView"||oe(zn,t)||oe(Eh,t)},isTypedArray:Op,TypedArray:xn,TypedArrayPrototype:hn},s8=TypeError,l8=nt("species"),c8=function(e,t){var n,r=bt(e).constructor;return r===void 0||Zi(n=bt(r)[l8])?t:function(i){if(yh(i))return i;throw s8(Ji(i)+" is not a constructor")}(n)},u8=Ac.aTypedArrayConstructor,d8=Ac.getTypedArrayConstructor,f8=Ac.aTypedArray;(0,Ac.exportTypedArrayMethod)("slice",function(e,t){for(var n,r=wh(f8(this),e,t),i=u8(c8(n=this,d8(n))),o=0,a=r.length,s=new i(a);a>o;)s[o]=r[o++];return s},ze(function(){new Int8Array(1).slice()}));var h8=Pt.f,zd=nt("unscopables"),jd=Array.prototype;jd[zd]==null&&h8(jd,zd,{configurable:!0,value:pr(null)});var ss=function(e){jd[zd][e]=!0},p8=Eg.includes,m8=ze(function(){return!Array(1).includes()});$t({target:"Array",proto:!0,forced:m8},{includes:function(e){return p8(this,e,arguments.length>1?arguments[1]:void 0)}}),ss("includes"),vh("Array","includes");var v8=$e("".indexOf);$t({target:"String",proto:!0,forced:!Tg("includes")},{includes:function(e){return!!~v8(Bn(va(this)),Bn(Ng(e)),arguments.length>1?arguments[1]:void 0)}}),vh("String","includes");var g8=Pt.f,y8=nn.set,b8=nn.getterFor("Array Iterator");xh(Array,"Array",function(e,t){y8(this,{type:"Array Iterator",target:Mn(e),index:0,kind:t})},function(){var e=b8(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?(e.target=void 0,Li(void 0,!0)):Li(n=="keys"?r:n=="values"?t[r]:[r,t[r]],!1)},"values");var Cp=Di.Arguments=Di.Array;if(ss("keys"),ss("values"),ss("entries"),Ae&&Cp.name!=="values")try{g8(Cp,"name",{value:"values"})}catch{}var Np=ze(function(){if(typeof ArrayBuffer=="function"){var e=new ArrayBuffer(8);Object.isExtensible(e)&&Object.defineProperty(e,"a",{value:8})}}),Da=Object.isExtensible,yu=ze(function(){Da(1)})||Np?function(e){return!!qe(e)&&(!Np||Vn(e)!="ArrayBuffer")&&(!Da||Da(e))}:Da,$8=!ze(function(){return Object.isExtensible(Object.preventExtensions({}))}),bi=Xi(function(e){var t=Pt.f,n=!1,r=Mi("meta"),i=0,o=function(s){t(s,r,{value:{objectID:"O"+i++,weakData:{}}})},a=e.exports={enable:function(){a.enable=function(){},n=!0;var s=Qo.f,c=$e([].splice),l={};l[r]=1,s(l).length&&(Qo.f=function(u){for(var d=s(u),f=0,h=d.length;f<h;f++)if(d[f]===r){c(d,f,1);break}return d},$t({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:$h.f}))},fastKey:function(s,c){if(!qe(s))return typeof s=="symbol"?s:(typeof s=="string"?"S":"P")+s;if(!oe(s,r)){if(!yu(s))return"F";if(!c)return"E";o(s)}return s[r].objectID},getWeakData:function(s,c){if(!oe(s,r)){if(!yu(s))return!0;if(!c)return!1;o(s)}return s[r].weakData},onFreeze:function(s){return $8&&n&&yu(s)&&!oe(s,r)&&o(s),s}};to[r]=!0});bi.enable,bi.fastKey,bi.getWeakData,bi.onFreeze;var w8=TypeError,ls=function(e,t){this.stopped=e,this.result=t},Tp=ls.prototype,ay=function(e,t,n){var r,i,o,a,s,c,l,u=n&&n.that,d=!(!n||!n.AS_ENTRIES),f=!(!n||!n.IS_RECORD),h=!(!n||!n.IS_ITERATOR),p=!(!n||!n.INTERRUPTED),m=Tc(t,u),v=function(y){return r&&Dd(r,"normal",y),new ls(!0,y)},b=function(y){return d?(bt(y),p?m(y[0],y[1],v):m(y[0],y[1])):p?m(y,v):m(y)};if(f)r=e.iterator;else if(h)r=e;else{if(!(i=kh(e)))throw w8(Ji(e)+" is not iterable");if(Zg(i)){for(o=0,a=no(e);a>o;o++)if((s=b(e[o]))&&Br(Tp,s))return s;return new ls(!1)}r=Jg(e,i)}for(c=f?e.next:r.next;!(l=Dt(c,r)).done;){try{s=b(l.value)}catch(y){Dd(r,"throw",y)}if(typeof s=="object"&&s&&Br(Tp,s))return s}return new ls(!1)},_8=TypeError,sy=function(e,t){if(Br(t,e))return e;throw _8("Incorrect invocation")},Pp=function(e,t,n){for(var r in t)Rt(e,r,t[r],n);return e},Ap=nt("species"),x8=Pt.f,Ip=bi.fastKey,Mp=nn.set,bu=nn.getterFor,k8={getConstructor:function(e,t,n,r){var i=e(function(l,u){sy(l,o),Mp(l,{type:t,index:pr(null),first:void 0,last:void 0,size:0}),Ae||(l.size=0),Zi(u)||ay(u,l[r],{that:l,AS_ENTRIES:n})}),o=i.prototype,a=bu(t),s=function(l,u,d){var f,h,p=a(l),m=c(l,u);return m?m.value=d:(p.last=m={index:h=Ip(u,!0),key:u,value:d,previous:f=p.last,next:void 0,removed:!1},p.first||(p.first=m),f&&(f.next=m),Ae?p.size++:l.size++,h!=="F"&&(p.index[h]=m)),l},c=function(l,u){var d,f=a(l),h=Ip(u);if(h!=="F")return f.index[h];for(d=f.first;d;d=d.next)if(d.key==u)return d};return Pp(o,{clear:function(){for(var l=a(this),u=l.index,d=l.first;d;)d.removed=!0,d.previous&&(d.previous=d.previous.next=void 0),delete u[d.index],d=d.next;l.first=l.last=void 0,Ae?l.size=0:this.size=0},delete:function(l){var u=this,d=a(u),f=c(u,l);if(f){var h=f.next,p=f.previous;delete d.index[f.index],f.removed=!0,p&&(p.next=h),h&&(h.previous=p),d.first==f&&(d.first=h),d.last==f&&(d.last=p),Ae?d.size--:u.size--}return!!f},forEach:function(l){for(var u,d=a(this),f=Tc(l,arguments.length>1?arguments[1]:void 0);u=u?u.next:d.first;)for(f(u.value,u.key,this);u&&u.removed;)u=u.previous},has:function(l){return!!c(this,l)}}),Pp(o,n?{get:function(l){var u=c(this,l);return u&&u.value},set:function(l,u){return s(this,l===0?0:l,u)}}:{add:function(l){return s(this,l=l===0?0:l,l)}}),Ae&&x8(o,"size",{get:function(){return a(this).size}}),i},setStrong:function(e,t,n){var r=t+" Iterator",i=bu(t),o=bu(r);xh(e,t,function(a,s){Mp(this,{type:r,target:a,state:i(a),kind:s,last:void 0})},function(){for(var a=o(this),s=a.kind,c=a.last;c&&c.removed;)c=c.previous;return a.target&&(a.last=c=c?c.next:a.state.first)?Li(s=="keys"?c.key:s=="values"?c.value:[c.key,c.value],!1):(a.target=void 0,Li(void 0,!0))},n?"entries":"values",!n,!0),function(a){var s=bn(a),c=Pt.f;Ae&&s&&!s[Ap]&&c(s,Ap,{configurable:!0,get:function(){return this}})}(t)}};function ly(e){var t=this.constructor;return this.then(function(n){return t.resolve(e()).then(function(){return n})},function(n){return t.resolve(e()).then(function(){return t.reject(n)})})}function cy(e){return new this(function(t,n){if(!e||e.length===void 0)return n(new TypeError(typeof e+" "+e+" is not iterable(cannot read property Symbol(Symbol.iterator))"));var r=Array.prototype.slice.call(e);if(r.length===0)return t([]);var i=r.length;function o(s,c){if(c&&(typeof c=="object"||typeof c=="function")){var l=c.then;if(typeof l=="function")return void l.call(c,function(u){o(s,u)},function(u){r[s]={status:"rejected",reason:u},--i==0&&t(r)})}r[s]={status:"fulfilled",value:c},--i==0&&t(r)}for(var a=0;a<r.length;a++)o(a,r[a])})}(function(e,t,n){var r=e.indexOf("Map")!==-1,i=e.indexOf("Weak")!==-1,o=r?"set":"add",a=ve[e],s=a&&a.prototype,c=a,l={},u=function(v){var b=$e(s[v]);Rt(s,v,v=="add"?function(y){return b(this,y===0?0:y),this}:v=="delete"?function(y){return!(i&&!qe(y))&&b(this,y===0?0:y)}:v=="get"?function(y){return i&&!qe(y)?void 0:b(this,y===0?0:y)}:v=="has"?function(y){return!(i&&!qe(y))&&b(this,y===0?0:y)}:function(y,g){return b(this,y===0?0:y,g),this})};if(Td(e,!Re(a)||!(i||s.forEach&&!ze(function(){new a().entries().next()}))))c=n.getConstructor(t,e,r,o),bi.enable();else if(Td(e,!0)){var d=new c,f=d[o](i?{}:-0,1)!=d,h=ze(function(){d.has(1)}),p=ny(function(v){new a(v)}),m=!i&&ze(function(){for(var v=new a,b=5;b--;)v[o](b,b);return!v.has(-0)});p||((c=t(function(v,b){sy(v,s);var y=function(g,_,k){var O,C;return Tn&&Re(O=_.constructor)&&O!==k&&qe(C=O.prototype)&&C!==k.prototype&&Tn(g,C),g}(new a,v,c);return Zi(b)||ay(b,y[o],{that:y,AS_ENTRIES:r}),y})).prototype=s,s.constructor=c),(h||m)&&(u("delete"),u("has"),r&&u("get")),(m||f)&&u(o),i&&s.clear&&delete s.clear}l[e]=c,$t({global:!0,constructor:!0,forced:c!=a},l),ar(c,e),i||n.setStrong(c,e,r)})("Set",function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},k8),Xo.Set;var E8=setTimeout;function Dp(e){return Boolean(e&&e.length!==void 0)}function S8(){}function Ke(e){if(!(this instanceof Ke))throw new TypeError("Promises must be constructed via new");if(typeof e!="function")throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],dy(e,this)}function uy(e,t){for(;e._state===3;)e=e._value;e._state!==0?(e._handled=!0,Ke._immediateFn(function(){var n=e._state===1?t.onFulfilled:t.onRejected;if(n!==null){var r;try{r=n(e._value)}catch(i){return void Zo(t.promise,i)}Vd(t.promise,r)}else(e._state===1?Vd:Zo)(t.promise,e._value)})):e._deferreds.push(t)}function Vd(e,t){try{if(t===e)throw new TypeError("A promise cannot be resolved with itself.");if(t&&(typeof t=="object"||typeof t=="function")){var n=t.then;if(t instanceof Ke)return e._state=3,e._value=t,void Ud(e);if(typeof n=="function")return void dy((r=n,i=t,function(){r.apply(i,arguments)}),e)}e._state=1,e._value=t,Ud(e)}catch(o){Zo(e,o)}var r,i}function Zo(e,t){e._state=2,e._value=t,Ud(e)}function Ud(e){e._state===2&&e._deferreds.length===0&&Ke._immediateFn(function(){e._handled||Ke._unhandledRejectionFn(e._value)});for(var t=0,n=e._deferreds.length;t<n;t++)uy(e,e._deferreds[t]);e._deferreds=null}function O8(e,t,n){this.onFulfilled=typeof e=="function"?e:null,this.onRejected=typeof t=="function"?t:null,this.promise=n}function dy(e,t){var n=!1;try{e(function(r){n||(n=!0,Vd(t,r))},function(r){n||(n=!0,Zo(t,r))})}catch(r){if(n)return;n=!0,Zo(t,r)}}Ke.prototype.catch=function(e){return this.then(null,e)},Ke.prototype.then=function(e,t){var n=new this.constructor(S8);return uy(this,new O8(e,t,n)),n},Ke.prototype.finally=ly,Ke.all=function(e){return new Ke(function(t,n){if(!Dp(e))return n(new TypeError("Promise.all accepts an array"));var r=Array.prototype.slice.call(e);if(r.length===0)return t([]);var i=r.length;function o(s,c){try{if(c&&(typeof c=="object"||typeof c=="function")){var l=c.then;if(typeof l=="function")return void l.call(c,function(u){o(s,u)},n)}r[s]=c,--i==0&&t(r)}catch(u){n(u)}}for(var a=0;a<r.length;a++)o(a,r[a])})},Ke.allSettled=cy,Ke.resolve=function(e){return e&&typeof e=="object"&&e.constructor===Ke?e:new Ke(function(t){t(e)})},Ke.reject=function(e){return new Ke(function(t,n){n(e)})},Ke.race=function(e){return new Ke(function(t,n){if(!Dp(e))return n(new TypeError("Promise.race accepts an array"));for(var r=0,i=e.length;r<i;r++)Ke.resolve(e[r]).then(t,n)})},Ke._immediateFn=typeof setImmediate=="function"&&function(e){setImmediate(e)}||function(e){E8(e,0)},Ke._unhandledRejectionFn=function(e){typeof console<"u"&&console&&console.warn("Possible Unhandled Promise Rejection:",e)};var oi=function(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}();typeof oi.Promise!="function"?oi.Promise=Ke:(oi.Promise.prototype.finally||(oi.Promise.prototype.finally=ly),oi.Promise.allSettled||(oi.Promise.allSettled=cy)),function(e){function t(h){for(var p=0,m=Math.min(65536,h.length+1),v=new Uint16Array(m),b=[],y=0;;){var g=p<h.length;if(!g||y>=m-1){var _=v.subarray(0,y);if(b.push(String.fromCharCode.apply(null,_)),!g)return b.join("");h=h.subarray(p),p=0,y=0}var k=h[p++];if((128&k)==0)v[y++]=k;else if((224&k)==192){var O=63&h[p++];v[y++]=(31&k)<<6|O}else if((240&k)==224){O=63&h[p++];var C=63&h[p++];v[y++]=(31&k)<<12|O<<6|C}else if((248&k)==240){var M=(7&k)<<18|(O=63&h[p++])<<12|(C=63&h[p++])<<6|63&h[p++];M>65535&&(M-=65536,v[y++]=M>>>10&1023|55296,M=56320|1023&M),v[y++]=M}}}var n="Failed to ",r=function(h,p,m){if(h)throw new Error("".concat(n).concat(p,": the '").concat(m,"' option is unsupported."))},i=typeof Buffer=="function"&&Buffer.from,o=i?function(h){return Buffer.from(h)}:function(h){for(var p=0,m=h.length,v=0,b=Math.max(32,m+(m>>>1)+7),y=new Uint8Array(b>>>3<<3);p<m;){var g=h.charCodeAt(p++);if(g>=55296&&g<=56319){if(p<m){var _=h.charCodeAt(p);(64512&_)==56320&&(++p,g=((1023&g)<<10)+(1023&_)+65536)}if(g>=55296&&g<=56319)continue}if(v+4>y.length){b+=8,b=(b*=1+p/h.length*2)>>>3<<3;var k=new Uint8Array(b);k.set(y),y=k}if((4294967168&g)!=0){if((4294965248&g)==0)y[v++]=g>>>6&31|192;else if((4294901760&g)==0)y[v++]=g>>>12&15|224,y[v++]=g>>>6&63|128;else{if((4292870144&g)!=0)continue;y[v++]=g>>>18&7|240,y[v++]=g>>>12&63|128,y[v++]=g>>>6&63|128}y[v++]=63&g|128}else y[v++]=g}return y.slice?y.slice(0,v):y.subarray(0,v)};function a(){this.encoding="utf-8"}a.prototype.encode=function(h,p){return r(p&&p.stream,"encode","stream"),o(h)};var s=!i&&typeof Blob=="function"&&typeof URL=="function"&&typeof URL.createObjectURL=="function",c=["utf-8","utf8","unicode-1-1-utf-8"],l=t;i?l=function(h,p){return(h instanceof Buffer?h:Buffer.from(h.buffer,h.byteOffset,h.byteLength)).toString(p)}:s&&(l=function(h){try{return function(p){var m;try{var v=new Blob([p],{type:"text/plain;charset=UTF-8"});m=URL.createObjectURL(v);var b=new XMLHttpRequest;return b.open("GET",m,!1),b.send(),b.responseText}finally{m&&URL.revokeObjectURL(m)}}(h)}catch{return t(h)}});var u="construct 'TextDecoder'",d="".concat(n," ").concat(u,": the ");function f(h,p){if(r(p&&p.fatal,u,"fatal"),h=h||"utf-8",!(i?Buffer.isEncoding(h):c.indexOf(h.toLowerCase())!==-1))throw new RangeError("".concat(d," encoding label provided ('").concat(h,"') is invalid."));this.encoding=h,this.fatal=!1,this.ignoreBOM=!1}f.prototype.decode=function(h,p){var m;return r(p&&p.stream,"decode","stream"),m=h instanceof Uint8Array?h:h.buffer instanceof ArrayBuffer?new Uint8Array(h.buffer):new Uint8Array(h),l(m,this.encoding)},e.TextEncoder=e.TextEncoder||a,e.TextDecoder=e.TextDecoder||f}(typeof window<"u"?window:Sn),function(){function e(v,b){if(!(v instanceof b))throw new TypeError("Cannot call a class as a function")}function t(v,b){for(var y=0;y<b.length;y++){var g=b[y];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(v,g.key,g)}}function n(v,b,y){return b&&t(v.prototype,b),y&&t(v,y),v}function r(v,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function");v.prototype=Object.create(b&&b.prototype,{constructor:{value:v,writable:!0,configurable:!0}}),b&&o(v,b)}function i(v){return i=Object.setPrototypeOf?Object.getPrototypeOf:function(b){return b.__proto__||Object.getPrototypeOf(b)},i(v)}function o(v,b){return o=Object.setPrototypeOf||function(y,g){return y.__proto__=g,y},o(v,b)}function a(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function s(v){if(v===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return v}function c(v,b){return!b||typeof b!="object"&&typeof b!="function"?s(v):b}function l(v){var b=a();return function(){var y,g=i(v);if(b){var _=i(this).constructor;y=Reflect.construct(g,arguments,_)}else y=g.apply(this,arguments);return c(this,y)}}function u(v,b){for(;!Object.prototype.hasOwnProperty.call(v,b)&&(v=i(v))!==null;);return v}function d(v,b,y){return d=typeof Reflect<"u"&&Reflect.get?Reflect.get:function(g,_,k){var O=u(g,_);if(O){var C=Object.getOwnPropertyDescriptor(O,_);return C.get?C.get.call(k):C.value}},d(v,b,y||v)}var f=function(){function v(){e(this,v),Object.defineProperty(this,"listeners",{value:{},writable:!0,configurable:!0})}return n(v,[{key:"addEventListener",value:function(b,y,g){b in this.listeners||(this.listeners[b]=[]),this.listeners[b].push({callback:y,options:g})}},{key:"removeEventListener",value:function(b,y){if(b in this.listeners){for(var g=this.listeners[b],_=0,k=g.length;_<k;_++)if(g[_].callback===y)return void g.splice(_,1)}}},{key:"dispatchEvent",value:function(b){if(b.type in this.listeners){for(var y=this.listeners[b.type].slice(),g=0,_=y.length;g<_;g++){var k=y[g];try{k.callback.call(this,b)}catch(O){Promise.resolve().then(function(){throw O})}k.options&&k.options.once&&this.removeEventListener(b.type,k.callback)}return!b.defaultPrevented}}}]),v}(),h=function(v){r(y,v);var b=l(y);function y(){var g;return e(this,y),(g=b.call(this)).listeners||f.call(s(g)),Object.defineProperty(s(g),"aborted",{value:!1,writable:!0,configurable:!0}),Object.defineProperty(s(g),"onabort",{value:null,writable:!0,configurable:!0}),g}return n(y,[{key:"toString",value:function(){return"[object AbortSignal]"}},{key:"dispatchEvent",value:function(g){g.type==="abort"&&(this.aborted=!0,typeof this.onabort=="function"&&this.onabort.call(this,g)),d(i(y.prototype),"dispatchEvent",this).call(this,g)}}]),y}(f),p=function(){function v(){e(this,v),Object.defineProperty(this,"signal",{value:new h,writable:!0,configurable:!0})}return n(v,[{key:"abort",value:function(){var b;try{b=new Event("abort")}catch{typeof document<"u"?document.createEvent?(b=document.createEvent("Event")).initEvent("abort",!1,!1):(b=document.createEventObject()).type="abort":b={type:"abort",bubbles:!1,cancelable:!1}}this.signal.dispatchEvent(b)}},{key:"toString",value:function(){return"[object AbortController]"}}]),v}();function m(v){return v.__FORCE_INSTALL_ABORTCONTROLLER_POLYFILL?(console.log("__FORCE_INSTALL_ABORTCONTROLLER_POLYFILL=true is set, will force install polyfill"),!0):typeof v.Request=="function"&&!v.Request.prototype.hasOwnProperty("signal")||!v.AbortController}typeof Symbol<"u"&&Symbol.toStringTag&&(p.prototype[Symbol.toStringTag]="AbortController",h.prototype[Symbol.toStringTag]="AbortSignal"),function(v){m(v)&&(v.AbortController=p,v.AbortSignal=h)}(typeof self<"u"?self:Sn)}();var Cr=Xi(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function r(){var i=this;this.locked=new Map,this.addToLocked=function(o,a){var s=i.locked.get(o);s===void 0?a===void 0?i.locked.set(o,[]):i.locked.set(o,[a]):a!==void 0&&(s.unshift(a),i.locked.set(o,s))},this.isLocked=function(o){return i.locked.has(o)},this.lock=function(o){return new Promise(function(a,s){i.isLocked(o)?i.addToLocked(o,a):(i.addToLocked(o),a())})},this.unlock=function(o){var a=i.locked.get(o);if(a!==void 0&&a.length!==0){var s=a.pop();i.locked.set(o,a),s!==void 0&&setTimeout(s,0)}else i.locked.delete(o)}}return r.getInstance=function(){return r.instance===void 0&&(r.instance=new r),r.instance},r}();t.default=function(){return n.getInstance()}});lh(Cr);var C8=Xi(function(e,t){var n=Sn&&Sn.__awaiter||function(c,l,u,d){return new(u||(u=Promise))(function(f,h){function p(b){try{v(d.next(b))}catch(y){h(y)}}function m(b){try{v(d.throw(b))}catch(y){h(y)}}function v(b){b.done?f(b.value):new u(function(y){y(b.value)}).then(p,m)}v((d=d.apply(c,l||[])).next())})},r=Sn&&Sn.__generator||function(c,l){var u,d,f,h,p={label:0,sent:function(){if(1&f[0])throw f[1];return f[1]},trys:[],ops:[]};return h={next:m(0),throw:m(1),return:m(2)},typeof Symbol=="function"&&(h[Symbol.iterator]=function(){return this}),h;function m(v){return function(b){return function(y){if(u)throw new TypeError("Generator is already executing.");for(;p;)try{if(u=1,d&&(f=2&y[0]?d.return:y[0]?d.throw||((f=d.return)&&f.call(d),0):d.next)&&!(f=f.call(d,y[1])).done)return f;switch(d=0,f&&(y=[2&y[0],f.value]),y[0]){case 0:case 1:f=y;break;case 4:return p.label++,{value:y[1],done:!1};case 5:p.label++,d=y[1],y=[0];continue;case 7:y=p.ops.pop(),p.trys.pop();continue;default:if(f=p.trys,!((f=f.length>0&&f[f.length-1])||y[0]!==6&&y[0]!==2)){p=0;continue}if(y[0]===3&&(!f||y[1]>f[0]&&y[1]<f[3])){p.label=y[1];break}if(y[0]===6&&p.label<f[1]){p.label=f[1],f=y;break}if(f&&p.label<f[2]){p.label=f[2],p.ops.push(y);break}f[2]&&p.ops.pop(),p.trys.pop();continue}y=l.call(c,p)}catch(g){y=[6,g],d=0}finally{u=f=0}if(5&y[0])throw y[1];return{value:y[0]?y[1]:void 0,done:!0}}([v,b])}}};Object.defineProperty(t,"__esModule",{value:!0});var i="browser-tabs-lock-key";function o(c){return new Promise(function(l){return setTimeout(l,c)})}function a(c){for(var l="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz",u="",d=0;d<c;d++)u+=l[Math.floor(Math.random()*l.length)];return u}var s=function(){function c(){this.acquiredIatSet=new Set,this.id=Date.now().toString()+a(15),this.acquireLock=this.acquireLock.bind(this),this.releaseLock=this.releaseLock.bind(this),this.releaseLock__private__=this.releaseLock__private__.bind(this),this.waitForSomethingToChange=this.waitForSomethingToChange.bind(this),this.refreshLockWhileAcquired=this.refreshLockWhileAcquired.bind(this),c.waiters===void 0&&(c.waiters=[])}return c.prototype.acquireLock=function(l,u){return u===void 0&&(u=5e3),n(this,void 0,void 0,function(){var d,f,h,p,m,v;return r(this,function(b){switch(b.label){case 0:d=Date.now()+a(4),f=Date.now()+u,h=i+"-"+l,p=window.localStorage,b.label=1;case 1:return Date.now()<f?[4,o(30)]:[3,8];case 2:return b.sent(),p.getItem(h)!==null?[3,5]:(m=this.id+"-"+l+"-"+d,[4,o(Math.floor(25*Math.random()))]);case 3:return b.sent(),p.setItem(h,JSON.stringify({id:this.id,iat:d,timeoutKey:m,timeAcquired:Date.now(),timeRefreshed:Date.now()})),[4,o(30)];case 4:return b.sent(),(v=p.getItem(h))!==null&&(v=JSON.parse(v)).id===this.id&&v.iat===d?(this.acquiredIatSet.add(d),this.refreshLockWhileAcquired(h,d),[2,!0]):[3,7];case 5:return c.lockCorrector(),[4,this.waitForSomethingToChange(f)];case 6:b.sent(),b.label=7;case 7:return d=Date.now()+a(4),[3,1];case 8:return[2,!1]}})})},c.prototype.refreshLockWhileAcquired=function(l,u){return n(this,void 0,void 0,function(){var d=this;return r(this,function(f){return setTimeout(function(){return n(d,void 0,void 0,function(){var h,p;return r(this,function(m){switch(m.label){case 0:return[4,Cr.default().lock(u)];case 1:return m.sent(),this.acquiredIatSet.has(u)?(h=window.localStorage,(p=h.getItem(l))===null?(Cr.default().unlock(u),[2]):((p=JSON.parse(p)).timeRefreshed=Date.now(),h.setItem(l,JSON.stringify(p)),Cr.default().unlock(u),this.refreshLockWhileAcquired(l,u),[2])):(Cr.default().unlock(u),[2])}})})},1e3),[2]})})},c.prototype.waitForSomethingToChange=function(l){return n(this,void 0,void 0,function(){return r(this,function(u){switch(u.label){case 0:return[4,new Promise(function(d){var f=!1,h=Date.now(),p=!1;function m(){if(p||(window.removeEventListener("storage",m),c.removeFromWaiting(m),clearTimeout(v),p=!0),!f){f=!0;var b=50-(Date.now()-h);b>0?setTimeout(d,b):d()}}window.addEventListener("storage",m),c.addToWaiting(m);var v=setTimeout(m,Math.max(0,l-Date.now()))})];case 1:return u.sent(),[2]}})})},c.addToWaiting=function(l){this.removeFromWaiting(l),c.waiters!==void 0&&c.waiters.push(l)},c.removeFromWaiting=function(l){c.waiters!==void 0&&(c.waiters=c.waiters.filter(function(u){return u!==l}))},c.notifyWaiters=function(){c.waiters!==void 0&&c.waiters.slice().forEach(function(l){return l()})},c.prototype.releaseLock=function(l){return n(this,void 0,void 0,function(){return r(this,function(u){switch(u.label){case 0:return[4,this.releaseLock__private__(l)];case 1:return[2,u.sent()]}})})},c.prototype.releaseLock__private__=function(l){return n(this,void 0,void 0,function(){var u,d,f;return r(this,function(h){switch(h.label){case 0:return u=window.localStorage,d=i+"-"+l,(f=u.getItem(d))===null?[2]:(f=JSON.parse(f)).id!==this.id?[3,2]:[4,Cr.default().lock(f.iat)];case 1:h.sent(),this.acquiredIatSet.delete(f.iat),u.removeItem(d),Cr.default().unlock(f.iat),c.notifyWaiters(),h.label=2;case 2:return[2]}})})},c.lockCorrector=function(){for(var l=Date.now()-5e3,u=window.localStorage,d=Object.keys(u),f=!1,h=0;h<d.length;h++){var p=d[h];if(p.includes(i)){var m=u.getItem(p);m!==null&&((m=JSON.parse(m)).timeRefreshed===void 0&&m.timeAcquired<l||m.timeRefreshed!==void 0&&m.timeRefreshed<l)&&(u.removeItem(p),f=!0)}}f&&c.notifyWaiters()},c.waiters=void 0,c}();t.default=s}),N8=lh(C8),T8={timeoutInSeconds:60},P8=["login_required","consent_required","interaction_required","account_selection_required","access_denied"],fy={name:"auth0-spa-js",version:"1.22.6"},hy=function(){return Date.now()},qn=function(e){function t(n,r){var i=e.call(this,r)||this;return i.error=n,i.error_description=r,Object.setPrototypeOf(i,t.prototype),i}return Jr(t,e),t.fromPayload=function(n){return new t(n.error,n.error_description)},t}(Error),A8=function(e){function t(n,r,i,o){o===void 0&&(o=null);var a=e.call(this,n,r)||this;return a.state=i,a.appState=o,Object.setPrototypeOf(a,t.prototype),a}return Jr(t,e),t}(qn),Bd=function(e){function t(){var n=e.call(this,"timeout","Timeout")||this;return Object.setPrototypeOf(n,t.prototype),n}return Jr(t,e),t}(qn),I8=function(e){function t(n){var r=e.call(this)||this;return r.popup=n,Object.setPrototypeOf(r,t.prototype),r}return Jr(t,e),t}(Bd),M8=function(e){function t(n){var r=e.call(this,"cancelled","Popup closed")||this;return r.popup=n,Object.setPrototypeOf(r,t.prototype),r}return Jr(t,e),t}(qn),D8=function(e){function t(n,r,i){var o=e.call(this,n,r)||this;return o.mfa_token=i,Object.setPrototypeOf(o,t.prototype),o}return Jr(t,e),t}(qn),L8=function(e){function t(n,r){var i=e.call(this,"missing_refresh_token","Missing Refresh Token (audience: '".concat(Rp(n,["default"]),"', scope: '").concat(Rp(r),"')"))||this;return i.audience=n,i.scope=r,Object.setPrototypeOf(i,t.prototype),i}return Jr(t,e),t}(qn),R8=function(e){return new Promise(function(t,n){var r,i=setInterval(function(){e.popup&&e.popup.closed&&(clearInterval(i),clearTimeout(o),window.removeEventListener("message",r,!1),n(new M8(e.popup)))},1e3),o=setTimeout(function(){clearInterval(i),n(new I8(e.popup)),window.removeEventListener("message",r,!1)},1e3*(e.timeoutInSeconds||60));r=function(a){if(a.data&&a.data.type==="authorization_response"){if(clearTimeout(o),clearInterval(i),window.removeEventListener("message",r,!1),e.popup.close(),a.data.response.error)return n(qn.fromPayload(a.data.response));t(a.data.response)}},window.addEventListener("message",r)})},Sh=function(){return window.crypto||window.msCrypto},py=function(){var e=Sh();return e.subtle||e.webkitSubtle},Ln=function(){var e="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_~.",t="";return Array.from(Sh().getRandomValues(new Uint8Array(43))).forEach(function(n){return t+=e[n%e.length]}),t},ai=function(e){return btoa(e)},Hd=function(e){return Object.keys(e).filter(function(t){return e[t]!==void 0}).map(function(t){return encodeURIComponent(t)+"="+encodeURIComponent(e[t])}).join("&")},$u=function(e){return xe(void 0,void 0,void 0,function(){var t;return ke(this,function(n){switch(n.label){case 0:return t=py().digest({name:"SHA-256"},new TextEncoder().encode(e)),window.msCrypto?[2,new Promise(function(r,i){t.oncomplete=function(o){r(o.target.result)},t.onerror=function(o){i(o.error)},t.onabort=function(){i("The digest operation was aborted")}})]:[4,t];case 1:return[2,n.sent()]}})})},Lp=function(e){return function(t){return decodeURIComponent(atob(t).split("").map(function(n){return"%"+("00"+n.charCodeAt(0).toString(16)).slice(-2)}).join(""))}(e.replace(/_/g,"/").replace(/-/g,"+"))},wu=function(e){var t=new Uint8Array(e);return function(n){var r={"+":"-","/":"_","=":""};return n.replace(/[+/=]/g,function(i){return r[i]})}(window.btoa(String.fromCharCode.apply(String,Ed([],Ai(Array.from(t)),!1))))};function Rp(e,t){return t===void 0&&(t=[]),e&&!t.includes(e)?e:""}var F8=function(e,t){return xe(void 0,void 0,void 0,function(){var n,r;return ke(this,function(i){switch(i.label){case 0:return[4,(o=e,a=t,a=a||{},new Promise(function(s,c){var l=new XMLHttpRequest,u=[],d=[],f={},h=function(){return{ok:(l.status/100|0)==2,statusText:l.statusText,status:l.status,url:l.responseURL,text:function(){return Promise.resolve(l.responseText)},json:function(){return Promise.resolve(l.responseText).then(JSON.parse)},blob:function(){return Promise.resolve(new Blob([l.response]))},clone:h,headers:{keys:function(){return u},entries:function(){return d},get:function(m){return f[m.toLowerCase()]},has:function(m){return m.toLowerCase()in f}}}};for(var p in l.open(a.method||"get",o,!0),l.onload=function(){l.getAllResponseHeaders().replace(/^(.*?):[^\S\n]*([\s\S]*?)$/gm,function(m,v,b){u.push(v=v.toLowerCase()),d.push([v,b]),f[v]=f[v]?f[v]+","+b:b}),s(h())},l.onerror=c,l.withCredentials=a.credentials=="include",a.headers)l.setRequestHeader(p,a.headers[p]);l.send(a.body||null)}))];case 1:return n=i.sent(),r={ok:n.ok},[4,n.json()];case 2:return[2,(r.json=i.sent(),r)]}var o,a})})},z8=function(e,t,n){return xe(void 0,void 0,void 0,function(){var r,i;return ke(this,function(o){return r=new AbortController,t.signal=r.signal,[2,Promise.race([F8(e,t),new Promise(function(a,s){i=setTimeout(function(){r.abort(),s(new Error("Timeout when executing 'fetch'"))},n)})]).finally(function(){clearTimeout(i)})]})})},j8=function(e,t,n,r,i,o,a){return xe(void 0,void 0,void 0,function(){return ke(this,function(s){return[2,(c={auth:{audience:t,scope:n},timeout:i,fetchUrl:e,fetchOptions:r,useFormData:a},l=o,new Promise(function(u,d){var f=new MessageChannel;f.port1.onmessage=function(h){h.data.error?d(new Error(h.data.error)):u(h.data),f.port1.close()},l.postMessage(c,[f.port2])}))];var c,l})})},V8=function(e,t,n,r,i,o,a){return a===void 0&&(a=1e4),xe(void 0,void 0,void 0,function(){return ke(this,function(s){return i?[2,j8(e,t,n,r,a,i,o)]:[2,z8(e,r,a)]})})};function U8(e,t,n,r,i,o,a){return xe(this,void 0,void 0,function(){var s,c,l,u,d,f,h,p,m;return ke(this,function(v){switch(v.label){case 0:s=null,l=0,v.label=1;case 1:if(!(l<3))return[3,6];v.label=2;case 2:return v.trys.push([2,4,,5]),[4,V8(e,n,r,i,o,a,t)];case 3:return c=v.sent(),s=null,[3,6];case 4:return u=v.sent(),s=u,[3,5];case 5:return l++,[3,1];case 6:if(s)throw s.message=s.message||"Failed to fetch",s;if(d=c.json,f=d.error,h=d.error_description,p=Ut(d,["error","error_description"]),!c.ok)throw m=h||"HTTP error. Unable to fetch ".concat(e),f==="mfa_required"?new D8(f,m,p.mfa_token):new qn(f||"request_error",m);return[2,p]}})})}function La(e,t){var n=e.baseUrl,r=e.timeout,i=e.audience,o=e.scope,a=e.auth0Client,s=e.useFormData,c=Ut(e,["baseUrl","timeout","audience","scope","auth0Client","useFormData"]);return xe(this,void 0,void 0,function(){var l;return ke(this,function(u){switch(u.label){case 0:return l=s?Hd(c):JSON.stringify(c),[4,U8("".concat(n,"/oauth/token"),r,i||"default",o,{method:"POST",body:l,headers:{"Content-Type":s?"application/x-www-form-urlencoded":"application/json","Auth0-Client":btoa(JSON.stringify(a||fy))}},t,s)];case 1:return[2,u.sent()]}})})}var B8=function(e){return Array.from(new Set(e))},Zn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return B8(e.join(" ").trim().split(/\s+/)).join(" ")},Ir=function(){function e(t,n){n===void 0&&(n="@@auth0spajs@@"),this.prefix=n,this.client_id=t.client_id,this.scope=t.scope,this.audience=t.audience}return e.prototype.toKey=function(){return"".concat(this.prefix,"::").concat(this.client_id,"::").concat(this.audience,"::").concat(this.scope)},e.fromKey=function(t){var n=Ai(t.split("::"),4),r=n[0],i=n[1],o=n[2];return new e({client_id:i,scope:n[3],audience:o},r)},e.fromCacheEntry=function(t){return new e({scope:t.scope,audience:t.audience,client_id:t.client_id})},e}(),H8=function(){function e(){}return e.prototype.set=function(t,n){localStorage.setItem(t,JSON.stringify(n))},e.prototype.get=function(t){var n=window.localStorage.getItem(t);if(n)try{return JSON.parse(n)}catch{return}},e.prototype.remove=function(t){localStorage.removeItem(t)},e.prototype.allKeys=function(){return Object.keys(window.localStorage).filter(function(t){return t.startsWith("@@auth0spajs@@")})},e}(),q8=function(){var e;this.enclosedCache=(e={},{set:function(t,n){e[t]=n},get:function(t){var n=e[t];if(n)return n},remove:function(t){delete e[t]},allKeys:function(){return Object.keys(e)}})},W8=function(){function e(t,n,r){this.cache=t,this.keyManifest=n,this.nowProvider=r,this.nowProvider=this.nowProvider||hy}return e.prototype.get=function(t,n){var r;return n===void 0&&(n=0),xe(this,void 0,void 0,function(){var i,o,a,s,c;return ke(this,function(l){switch(l.label){case 0:return[4,this.cache.get(t.toKey())];case 1:return(i=l.sent())?[3,4]:[4,this.getCacheKeys()];case 2:return(o=l.sent())?(a=this.matchExistingCacheKey(t,o))?[4,this.cache.get(a)]:[3,4]:[2];case 3:i=l.sent(),l.label=4;case 4:return i?[4,this.nowProvider()]:[2];case 5:return s=l.sent(),c=Math.floor(s/1e3),i.expiresAt-n<c?i.body.refresh_token?(i.body={refresh_token:i.body.refresh_token},[4,this.cache.set(t.toKey(),i)]):[3,7]:[3,10];case 6:return l.sent(),[2,i.body];case 7:return[4,this.cache.remove(t.toKey())];case 8:return l.sent(),[4,(r=this.keyManifest)===null||r===void 0?void 0:r.remove(t.toKey())];case 9:return l.sent(),[2];case 10:return[2,i.body]}})})},e.prototype.set=function(t){var n;return xe(this,void 0,void 0,function(){var r,i;return ke(this,function(o){switch(o.label){case 0:return r=new Ir({client_id:t.client_id,scope:t.scope,audience:t.audience}),[4,this.wrapCacheEntry(t)];case 1:return i=o.sent(),[4,this.cache.set(r.toKey(),i)];case 2:return o.sent(),[4,(n=this.keyManifest)===null||n===void 0?void 0:n.add(r.toKey())];case 3:return o.sent(),[2]}})})},e.prototype.clear=function(t){var n;return xe(this,void 0,void 0,function(){var r,i=this;return ke(this,function(o){switch(o.label){case 0:return[4,this.getCacheKeys()];case 1:return(r=o.sent())?[4,r.filter(function(a){return!t||a.includes(t)}).reduce(function(a,s){return xe(i,void 0,void 0,function(){return ke(this,function(c){switch(c.label){case 0:return[4,a];case 1:return c.sent(),[4,this.cache.remove(s)];case 2:return c.sent(),[2]}})})},Promise.resolve())]:[2];case 2:return o.sent(),[4,(n=this.keyManifest)===null||n===void 0?void 0:n.clear()];case 3:return o.sent(),[2]}})})},e.prototype.clearSync=function(t){var n=this,r=this.cache.allKeys();r&&r.filter(function(i){return!t||i.includes(t)}).forEach(function(i){n.cache.remove(i)})},e.prototype.wrapCacheEntry=function(t){return xe(this,void 0,void 0,function(){var n,r,i;return ke(this,function(o){switch(o.label){case 0:return[4,this.nowProvider()];case 1:return n=o.sent(),r=Math.floor(n/1e3)+t.expires_in,i=Math.min(r,t.decodedToken.claims.exp),[2,{body:t,expiresAt:i}]}})})},e.prototype.getCacheKeys=function(){var t;return xe(this,void 0,void 0,function(){var n;return ke(this,function(r){switch(r.label){case 0:return this.keyManifest?[4,this.keyManifest.get()]:[3,2];case 1:return n=(t=r.sent())===null||t===void 0?void 0:t.keys,[3,4];case 2:return[4,this.cache.allKeys()];case 3:n=r.sent(),r.label=4;case 4:return[2,n]}})})},e.prototype.matchExistingCacheKey=function(t,n){return n.filter(function(r){var i=Ir.fromKey(r),o=new Set(i.scope&&i.scope.split(" ")),a=t.scope.split(" "),s=i.scope&&a.reduce(function(c,l){return c&&o.has(l)},!0);return i.prefix==="@@auth0spajs@@"&&i.client_id===t.client_id&&i.audience===t.audience&&s})[0]},e}(),G8=function(){function e(t,n){this.storage=t,this.clientId=n,this.storageKey="".concat("a0.spajs.txs",".").concat(this.clientId),this.transaction=this.storage.get(this.storageKey)}return e.prototype.create=function(t){this.transaction=t,this.storage.save(this.storageKey,t,{daysUntilExpire:1})},e.prototype.get=function(){return this.transaction},e.prototype.remove=function(){delete this.transaction,this.storage.remove(this.storageKey)},e}(),yo=function(e){return typeof e=="number"},K8=["iss","aud","exp","nbf","iat","jti","azp","nonce","auth_time","at_hash","c_hash","acr","amr","sub_jwk","cnf","sip_from_tag","sip_date","sip_callid","sip_cseq_num","sip_via_branch","orig","dest","mky","events","toe","txn","rph","sid","vot","vtm"],Q8=function(e){if(!e.id_token)throw new Error("ID token is required but missing");var t=function(s){var c=s.split("."),l=Ai(c,3),u=l[0],d=l[1],f=l[2];if(c.length!==3||!u||!d||!f)throw new Error("ID token could not be decoded");var h=JSON.parse(Lp(d)),p={__raw:s},m={};return Object.keys(h).forEach(function(v){p[v]=h[v],K8.includes(v)||(m[v]=h[v])}),{encoded:{header:u,payload:d,signature:f},header:JSON.parse(Lp(u)),claims:p,user:m}}(e.id_token);if(!t.claims.iss)throw new Error("Issuer (iss) claim must be a string present in the ID token");if(t.claims.iss!==e.iss)throw new Error('Issuer (iss) claim mismatch in the ID token; expected "'.concat(e.iss,'", found "').concat(t.claims.iss,'"'));if(!t.user.sub)throw new Error("Subject (sub) claim must be a string present in the ID token");if(t.header.alg!=="RS256")throw new Error('Signature algorithm of "'.concat(t.header.alg,'" is not supported. Expected the ID token to be signed with "RS256".'));if(!t.claims.aud||typeof t.claims.aud!="string"&&!Array.isArray(t.claims.aud))throw new Error("Audience (aud) claim must be a string or array of strings present in the ID token");if(Array.isArray(t.claims.aud)){if(!t.claims.aud.includes(e.aud))throw new Error('Audience (aud) claim mismatch in the ID token; expected "'.concat(e.aud,'" but was not one of "').concat(t.claims.aud.join(", "),'"'));if(t.claims.aud.length>1){if(!t.claims.azp)throw new Error("Authorized Party (azp) claim must be a string present in the ID token when Audience (aud) claim has multiple values");if(t.claims.azp!==e.aud)throw new Error('Authorized Party (azp) claim mismatch in the ID token; expected "'.concat(e.aud,'", found "').concat(t.claims.azp,'"'))}}else if(t.claims.aud!==e.aud)throw new Error('Audience (aud) claim mismatch in the ID token; expected "'.concat(e.aud,'" but found "').concat(t.claims.aud,'"'));if(e.nonce){if(!t.claims.nonce)throw new Error("Nonce (nonce) claim must be a string present in the ID token");if(t.claims.nonce!==e.nonce)throw new Error('Nonce (nonce) claim mismatch in the ID token; expected "'.concat(e.nonce,'", found "').concat(t.claims.nonce,'"'))}if(e.max_age&&!yo(t.claims.auth_time))throw new Error("Authentication Time (auth_time) claim must be a number present in the ID token when Max Age (max_age) is specified");if(!yo(t.claims.exp))throw new Error("Expiration Time (exp) claim must be a number present in the ID token");if(!yo(t.claims.iat))throw new Error("Issued At (iat) claim must be a number present in the ID token");var n=e.leeway||60,r=new Date(e.now||Date.now()),i=new Date(0),o=new Date(0),a=new Date(0);if(a.setUTCSeconds(parseInt(t.claims.auth_time)+e.max_age+n),i.setUTCSeconds(t.claims.exp+n),o.setUTCSeconds(t.claims.nbf-n),r>i)throw new Error("Expiration Time (exp) claim error in the ID token; current time (".concat(r,") is after expiration time (").concat(i,")"));if(yo(t.claims.nbf)&&r<o)throw new Error("Not Before time (nbf) claim in the ID token indicates that this token can't be used just yet. Currrent time (".concat(r,") is before ").concat(o));if(yo(t.claims.auth_time)&&r>a)throw new Error("Authentication Time (auth_time) claim in the ID token indicates that too much time has passed since the last end-user authentication. Currrent time (".concat(r,") is after last auth at ").concat(a));if(e.organizationId){if(!t.claims.org_id)throw new Error("Organization ID (org_id) claim must be a string present in the ID token");if(e.organizationId!==t.claims.org_id)throw new Error('Organization ID (org_id) claim mismatch in the ID token; expected "'.concat(e.organizationId,'", found "').concat(t.claims.org_id,'"'))}return t},Dr=Xi(function(e,t){var n=Sn&&Sn.__assign||function(){return n=Object.assign||function(c){for(var l,u=1,d=arguments.length;u<d;u++)for(var f in l=arguments[u])Object.prototype.hasOwnProperty.call(l,f)&&(c[f]=l[f]);return c},n.apply(this,arguments)};function r(c,l){if(!l)return"";var u="; "+c;return l===!0?u:u+"="+l}function i(c,l,u){return encodeURIComponent(c).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/\(/g,"%28").replace(/\)/g,"%29")+"="+encodeURIComponent(l).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent)+function(d){if(typeof d.expires=="number"){var f=new Date;f.setMilliseconds(f.getMilliseconds()+864e5*d.expires),d.expires=f}return r("Expires",d.expires?d.expires.toUTCString():"")+r("Domain",d.domain)+r("Path",d.path)+r("Secure",d.secure)+r("SameSite",d.sameSite)}(u)}function o(c){for(var l={},u=c?c.split("; "):[],d=/(%[\dA-F]{2})+/gi,f=0;f<u.length;f++){var h=u[f].split("="),p=h.slice(1).join("=");p.charAt(0)==='"'&&(p=p.slice(1,-1));try{l[h[0].replace(d,decodeURIComponent)]=p.replace(d,decodeURIComponent)}catch{}}return l}function a(){return o(document.cookie)}function s(c,l,u){document.cookie=i(c,l,n({path:"/"},u))}t.__esModule=!0,t.encode=i,t.parse=o,t.getAll=a,t.get=function(c){return a()[c]},t.set=s,t.remove=function(c,l){s(c,"",n(n({},l),{expires:-1}))}});lh(Dr),Dr.encode,Dr.parse,Dr.getAll;var Y8=Dr.get,my=Dr.set,vy=Dr.remove,pi={get:function(e){var t=Y8(e);if(t!==void 0)return JSON.parse(t)},save:function(e,t,n){var r={};window.location.protocol==="https:"&&(r={secure:!0,sameSite:"none"}),n?.daysUntilExpire&&(r.expires=n.daysUntilExpire),n?.cookieDomain&&(r.domain=n.cookieDomain),my(e,JSON.stringify(t),r)},remove:function(e,t){var n={};t?.cookieDomain&&(n.domain=t.cookieDomain),vy(e,n)}},X8={get:function(e){var t=pi.get(e);return t||pi.get("".concat("_legacy_").concat(e))},save:function(e,t,n){var r={};window.location.protocol==="https:"&&(r={secure:!0}),n?.daysUntilExpire&&(r.expires=n.daysUntilExpire),my("".concat("_legacy_").concat(e),JSON.stringify(t),r),pi.save(e,t,n)},remove:function(e,t){var n={};t?.cookieDomain&&(n.domain=t.cookieDomain),vy(e,n),pi.remove(e,t),pi.remove("".concat("_legacy_").concat(e),t)}},Z8={get:function(e){if(typeof sessionStorage<"u"){var t=sessionStorage.getItem(e);if(t!==void 0)return JSON.parse(t)}},save:function(e,t){sessionStorage.setItem(e,JSON.stringify(t))},remove:function(e){sessionStorage.removeItem(e)}};function J8(e,t,n){var r=t===void 0?null:t,i=function(c,l){var u=atob(c);if(l){for(var d=new Uint8Array(u.length),f=0,h=u.length;f<h;++f)d[f]=u.charCodeAt(f);return String.fromCharCode.apply(null,new Uint16Array(d.buffer))}return u}(e,n!==void 0&&n),o=i.indexOf(`
|
|
2
2
|
`,10)+1,a=i.substring(o)+(r?"//# sourceMappingURL="+r:""),s=new Blob([a],{type:"application/javascript"});return URL.createObjectURL(s)}var Fp,zp,jp,_u,e$=(Fp="Lyogcm9sbHVwLXBsdWdpbi13ZWItd29ya2VyLWxvYWRlciAqLwohZnVuY3Rpb24oKXsidXNlIHN0cmljdCI7dmFyIHQ9ZnVuY3Rpb24oZSxyKXtyZXR1cm4gdD1PYmplY3Quc2V0UHJvdG90eXBlT2Z8fHtfX3Byb3RvX186W119aW5zdGFuY2VvZiBBcnJheSYmZnVuY3Rpb24odCxlKXt0Ll9fcHJvdG9fXz1lfXx8ZnVuY3Rpb24odCxlKXtmb3IodmFyIHIgaW4gZSlPYmplY3QucHJvdG90eXBlLmhhc093blByb3BlcnR5LmNhbGwoZSxyKSYmKHRbcl09ZVtyXSl9LHQoZSxyKX07ZnVuY3Rpb24gZShlLHIpe2lmKCJmdW5jdGlvbiIhPXR5cGVvZiByJiZudWxsIT09cil0aHJvdyBuZXcgVHlwZUVycm9yKCJDbGFzcyBleHRlbmRzIHZhbHVlICIrU3RyaW5nKHIpKyIgaXMgbm90IGEgY29uc3RydWN0b3Igb3IgbnVsbCIpO2Z1bmN0aW9uIG4oKXt0aGlzLmNvbnN0cnVjdG9yPWV9dChlLHIpLGUucHJvdG90eXBlPW51bGw9PT1yP09iamVjdC5jcmVhdGUocik6KG4ucHJvdG90eXBlPXIucHJvdG90eXBlLG5ldyBuKX12YXIgcj1mdW5jdGlvbigpe3JldHVybiByPU9iamVjdC5hc3NpZ258fGZ1bmN0aW9uKHQpe2Zvcih2YXIgZSxyPTEsbj1hcmd1bWVudHMubGVuZ3RoO3I8bjtyKyspZm9yKHZhciBvIGluIGU9YXJndW1lbnRzW3JdKU9iamVjdC5wcm90b3R5cGUuaGFzT3duUHJvcGVydHkuY2FsbChlLG8pJiYodFtvXT1lW29dKTtyZXR1cm4gdH0sci5hcHBseSh0aGlzLGFyZ3VtZW50cyl9O2Z1bmN0aW9uIG4odCxlLHIsbil7cmV0dXJuIG5ldyhyfHwocj1Qcm9taXNlKSkoKGZ1bmN0aW9uKG8sYyl7ZnVuY3Rpb24gaSh0KXt0cnl7cyhuLm5leHQodCkpfWNhdGNoKHQpe2ModCl9fWZ1bmN0aW9uIGEodCl7dHJ5e3Mobi50aHJvdyh0KSl9Y2F0Y2godCl7Yyh0KX19ZnVuY3Rpb24gcyh0KXt2YXIgZTt0LmRvbmU/byh0LnZhbHVlKTooZT10LnZhbHVlLGUgaW5zdGFuY2VvZiByP2U6bmV3IHIoKGZ1bmN0aW9uKHQpe3QoZSl9KSkpLnRoZW4oaSxhKX1zKChuPW4uYXBwbHkodCxlfHxbXSkpLm5leHQoKSl9KSl9ZnVuY3Rpb24gbyh0LGUpe3ZhciByLG4sbyxjLGk9e2xhYmVsOjAsc2VudDpmdW5jdGlvbigpe2lmKDEmb1swXSl0aHJvdyBvWzFdO3JldHVybiBvWzFdfSx0cnlzOltdLG9wczpbXX07cmV0dXJuIGM9e25leHQ6YSgwKSx0aHJvdzphKDEpLHJldHVybjphKDIpfSwiZnVuY3Rpb24iPT10eXBlb2YgU3ltYm9sJiYoY1tTeW1ib2wuaXRlcmF0b3JdPWZ1bmN0aW9uKCl7cmV0dXJuIHRoaXN9KSxjO2Z1bmN0aW9uIGEoYyl7cmV0dXJuIGZ1bmN0aW9uKGEpe3JldHVybiBmdW5jdGlvbihjKXtpZihyKXRocm93IG5ldyBUeXBlRXJyb3IoIkdlbmVyYXRvciBpcyBhbHJlYWR5IGV4ZWN1dGluZy4iKTtmb3IoO2k7KXRyeXtpZihyPTEsbiYmKG89MiZjWzBdP24ucmV0dXJuOmNbMF0/bi50aHJvd3x8KChvPW4ucmV0dXJuKSYmby5jYWxsKG4pLDApOm4ubmV4dCkmJiEobz1vLmNhbGwobixjWzFdKSkuZG9uZSlyZXR1cm4gbztzd2l0Y2gobj0wLG8mJihjPVsyJmNbMF0sby52YWx1ZV0pLGNbMF0pe2Nhc2UgMDpjYXNlIDE6bz1jO2JyZWFrO2Nhc2UgNDpyZXR1cm4gaS5sYWJlbCsrLHt2YWx1ZTpjWzFdLGRvbmU6ITF9O2Nhc2UgNTppLmxhYmVsKyssbj1jWzFdLGM9WzBdO2NvbnRpbnVlO2Nhc2UgNzpjPWkub3BzLnBvcCgpLGkudHJ5cy5wb3AoKTtjb250aW51ZTtkZWZhdWx0OmlmKCEobz1pLnRyeXMsKG89by5sZW5ndGg+MCYmb1tvLmxlbmd0aC0xXSl8fDYhPT1jWzBdJiYyIT09Y1swXSkpe2k9MDtjb250aW51ZX1pZigzPT09Y1swXSYmKCFvfHxjWzFdPm9bMF0mJmNbMV08b1szXSkpe2kubGFiZWw9Y1sxXTticmVha31pZig2PT09Y1swXSYmaS5sYWJlbDxvWzFdKXtpLmxhYmVsPW9bMV0sbz1jO2JyZWFrfWlmKG8mJmkubGFiZWw8b1syXSl7aS5sYWJlbD1vWzJdLGkub3BzLnB1c2goYyk7YnJlYWt9b1syXSYmaS5vcHMucG9wKCksaS50cnlzLnBvcCgpO2NvbnRpbnVlfWM9ZS5jYWxsKHQsaSl9Y2F0Y2godCl7Yz1bNix0XSxuPTB9ZmluYWxseXtyPW89MH1pZig1JmNbMF0pdGhyb3cgY1sxXTtyZXR1cm57dmFsdWU6Y1swXT9jWzFdOnZvaWQgMCxkb25lOiEwfX0oW2MsYV0pfX19ZnVuY3Rpb24gYyh0LGUpe3JldHVybiB2b2lkIDA9PT1lJiYoZT1bXSksdCYmIWUuaW5jbHVkZXModCk/dDoiIn12YXIgaT1mdW5jdGlvbih0KXtmdW5jdGlvbiByKGUsbil7dmFyIG89dC5jYWxsKHRoaXMsbil8fHRoaXM7cmV0dXJuIG8uZXJyb3I9ZSxvLmVycm9yX2Rlc2NyaXB0aW9uPW4sT2JqZWN0LnNldFByb3RvdHlwZU9mKG8sci5wcm90b3R5cGUpLG99cmV0dXJuIGUocix0KSxyLmZyb21QYXlsb2FkPWZ1bmN0aW9uKHQpe3JldHVybiBuZXcgcih0LmVycm9yLHQuZXJyb3JfZGVzY3JpcHRpb24pfSxyfShFcnJvcik7IWZ1bmN0aW9uKHQpe2Z1bmN0aW9uIHIoZSxuLG8sYyl7dm9pZCAwPT09YyYmKGM9bnVsbCk7dmFyIGk9dC5jYWxsKHRoaXMsZSxuKXx8dGhpcztyZXR1cm4gaS5zdGF0ZT1vLGkuYXBwU3RhdGU9YyxPYmplY3Quc2V0UHJvdG90eXBlT2YoaSxyLnByb3RvdHlwZSksaX1lKHIsdCl9KGkpLGZ1bmN0aW9uKHQpe2Z1bmN0aW9uIHIoZSl7dmFyIG49dC5jYWxsKHRoaXMpfHx0aGlzO3JldHVybiBuLnBvcHVwPWUsT2JqZWN0LnNldFByb3RvdHlwZU9mKG4sci5wcm90b3R5cGUpLG59ZShyLHQpfShmdW5jdGlvbih0KXtmdW5jdGlvbiByKCl7dmFyIGU9dC5jYWxsKHRoaXMsInRpbWVvdXQiLCJUaW1lb3V0Iil8fHRoaXM7cmV0dXJuIE9iamVjdC5zZXRQcm90b3R5cGVPZihlLHIucHJvdG90eXBlKSxlfXJldHVybiBlKHIsdCkscn0oaSkpLGZ1bmN0aW9uKHQpe2Z1bmN0aW9uIHIoZSl7dmFyIG49dC5jYWxsKHRoaXMsImNhbmNlbGxlZCIsIlBvcHVwIGNsb3NlZCIpfHx0aGlzO3JldHVybiBuLnBvcHVwPWUsT2JqZWN0LnNldFByb3RvdHlwZU9mKG4sci5wcm90b3R5cGUpLG59ZShyLHQpfShpKSxmdW5jdGlvbih0KXtmdW5jdGlvbiByKGUsbixvKXt2YXIgYz10LmNhbGwodGhpcyxlLG4pfHx0aGlzO3JldHVybiBjLm1mYV90b2tlbj1vLE9iamVjdC5zZXRQcm90b3R5cGVPZihjLHIucHJvdG90eXBlKSxjfWUocix0KX0oaSk7dmFyIGE9ZnVuY3Rpb24odCl7ZnVuY3Rpb24gcihlLG4pe3ZhciBvPXQuY2FsbCh0aGlzLCJtaXNzaW5nX3JlZnJlc2hfdG9rZW4iLCJNaXNzaW5nIFJlZnJlc2ggVG9rZW4gKGF1ZGllbmNlOiAnIi5jb25jYXQoYyhlLFsiZGVmYXVsdCJdKSwiJywgc2NvcGU6ICciKS5jb25jYXQoYyhuKSwiJykiKSl8fHRoaXM7cmV0dXJuIG8uYXVkaWVuY2U9ZSxvLnNjb3BlPW4sT2JqZWN0LnNldFByb3RvdHlwZU9mKG8sci5wcm90b3R5cGUpLG99cmV0dXJuIGUocix0KSxyfShpKSxzPXt9LHU9ZnVuY3Rpb24odCxlKXtyZXR1cm4iIi5jb25jYXQodCwifCIpLmNvbmNhdChlKX07YWRkRXZlbnRMaXN0ZW5lcigibWVzc2FnZSIsKGZ1bmN0aW9uKHQpe3ZhciBlPXQuZGF0YSxjPWUudGltZW91dCxpPWUuYXV0aCxmPWUuZmV0Y2hVcmwsbD1lLmZldGNoT3B0aW9ucyxwPWUudXNlRm9ybURhdGEsaD1mdW5jdGlvbih0LGUpe3ZhciByPSJmdW5jdGlvbiI9PXR5cGVvZiBTeW1ib2wmJnRbU3ltYm9sLml0ZXJhdG9yXTtpZighcilyZXR1cm4gdDt2YXIgbixvLGM9ci5jYWxsKHQpLGk9W107dHJ5e2Zvcig7KHZvaWQgMD09PWV8fGUtLSA+MCkmJiEobj1jLm5leHQoKSkuZG9uZTspaS5wdXNoKG4udmFsdWUpfWNhdGNoKHQpe289e2Vycm9yOnR9fWZpbmFsbHl7dHJ5e24mJiFuLmRvbmUmJihyPWMucmV0dXJuKSYmci5jYWxsKGMpfWZpbmFsbHl7aWYobyl0aHJvdyBvLmVycm9yfX1yZXR1cm4gaX0odC5wb3J0cywxKVswXTtyZXR1cm4gbih2b2lkIDAsdm9pZCAwLHZvaWQgMCwoZnVuY3Rpb24oKXt2YXIgdCxlLG4seSx2LGIsZCx3LE8sXztyZXR1cm4gbyh0aGlzLChmdW5jdGlvbihvKXtzd2l0Y2goby5sYWJlbCl7Y2FzZSAwOm49KGU9aXx8e30pLmF1ZGllbmNlLHk9ZS5zY29wZSxvLmxhYmVsPTE7Y2FzZSAxOmlmKG8udHJ5cy5wdXNoKFsxLDcsLDhdKSwhKHY9cD8obT1sLmJvZHksaz1uZXcgVVJMU2VhcmNoUGFyYW1zKG0pLFA9e30say5mb3JFYWNoKChmdW5jdGlvbih0LGUpe1BbZV09dH0pKSxQKTpKU09OLnBhcnNlKGwuYm9keSkpLnJlZnJlc2hfdG9rZW4mJiJyZWZyZXNoX3Rva2VuIj09PXYuZ3JhbnRfdHlwZSl7aWYoYj1mdW5jdGlvbih0LGUpe3JldHVybiBzW3UodCxlKV19KG4seSksIWIpdGhyb3cgbmV3IGEobix5KTtsLmJvZHk9cD9uZXcgVVJMU2VhcmNoUGFyYW1zKHIocih7fSx2KSx7cmVmcmVzaF90b2tlbjpifSkpLnRvU3RyaW5nKCk6SlNPTi5zdHJpbmdpZnkocihyKHt9LHYpLHtyZWZyZXNoX3Rva2VuOmJ9KSl9ZD12b2lkIDAsImZ1bmN0aW9uIj09dHlwZW9mIEFib3J0Q29udHJvbGxlciYmKGQ9bmV3IEFib3J0Q29udHJvbGxlcixsLnNpZ25hbD1kLnNpZ25hbCksdz12b2lkIDAsby5sYWJlbD0yO2Nhc2UgMjpyZXR1cm4gby50cnlzLnB1c2goWzIsNCwsNV0pLFs0LFByb21pc2UucmFjZShbKGc9YyxuZXcgUHJvbWlzZSgoZnVuY3Rpb24odCl7cmV0dXJuIHNldFRpbWVvdXQodCxnKX0pKSksZmV0Y2goZixyKHt9LGwpKV0pXTtjYXNlIDM6cmV0dXJuIHc9by5zZW50KCksWzMsNV07Y2FzZSA0OnJldHVybiBPPW8uc2VudCgpLGgucG9zdE1lc3NhZ2Uoe2Vycm9yOk8ubWVzc2FnZX0pLFsyXTtjYXNlIDU6cmV0dXJuIHc/WzQsdy5qc29uKCldOihkJiZkLmFib3J0KCksaC5wb3N0TWVzc2FnZSh7ZXJyb3I6IlRpbWVvdXQgd2hlbiBleGVjdXRpbmcgJ2ZldGNoJyJ9KSxbMl0pO2Nhc2UgNjpyZXR1cm4odD1vLnNlbnQoKSkucmVmcmVzaF90b2tlbj8oZnVuY3Rpb24odCxlLHIpe3NbdShlLHIpXT10fSh0LnJlZnJlc2hfdG9rZW4sbix5KSxkZWxldGUgdC5yZWZyZXNoX3Rva2VuKTpmdW5jdGlvbih0LGUpe2RlbGV0ZSBzW3UodCxlKV19KG4seSksaC5wb3N0TWVzc2FnZSh7b2s6dy5vayxqc29uOnR9KSxbMyw4XTtjYXNlIDc6cmV0dXJuIF89by5zZW50KCksaC5wb3N0TWVzc2FnZSh7b2s6ITEsanNvbjp7ZXJyb3JfZGVzY3JpcHRpb246Xy5tZXNzYWdlfX0pLFszLDhdO2Nhc2UgODpyZXR1cm5bMl19dmFyIGcsbSxrLFB9KSl9KSl9KSl9KCk7Cgo=",zp=null,jp=!1,function(e){return _u=_u||J8(Fp,zp,jp),new Worker(_u,e)}),xu={},t$=function(){function e(t,n){this.cache=t,this.clientId=n,this.manifestKey=this.createManifestKeyFrom(this.clientId)}return e.prototype.add=function(t){var n;return xe(this,void 0,void 0,function(){var r,i;return ke(this,function(o){switch(o.label){case 0:return i=Set.bind,[4,this.cache.get(this.manifestKey)];case 1:return(r=new(i.apply(Set,[void 0,((n=o.sent())===null||n===void 0?void 0:n.keys)||[]]))).add(t),[4,this.cache.set(this.manifestKey,{keys:Ed([],Ai(r),!1)})];case 2:return o.sent(),[2]}})})},e.prototype.remove=function(t){return xe(this,void 0,void 0,function(){var n,r;return ke(this,function(i){switch(i.label){case 0:return[4,this.cache.get(this.manifestKey)];case 1:return(n=i.sent())?((r=new Set(n.keys)).delete(t),r.size>0?[4,this.cache.set(this.manifestKey,{keys:Ed([],Ai(r),!1)})]:[3,3]):[3,5];case 2:case 4:return[2,i.sent()];case 3:return[4,this.cache.remove(this.manifestKey)];case 5:return[2]}})})},e.prototype.get=function(){return this.cache.get(this.manifestKey)},e.prototype.clear=function(){return this.cache.remove(this.manifestKey)},e.prototype.createManifestKeyFrom=function(t){return"".concat("@@auth0spajs@@","::").concat(t)},e}(),ku=new N8,n$={memory:function(){return new q8().enclosedCache},localstorage:function(){return new H8}},Vp=function(e){return n$[e]},r$=function(){return!/Trident.*rv:11\.0/.test(navigator.userAgent)},i$=function(){function e(t){var n,r,i,o,a=this;if(this.options=t,this._releaseLockOnPageHide=function(){return xe(a,void 0,void 0,function(){return ke(this,function(l){switch(l.label){case 0:return[4,ku.releaseLock("auth0.lock.getTokenSilently")];case 1:return l.sent(),window.removeEventListener("pagehide",this._releaseLockOnPageHide),[2]}})})},typeof window<"u"&&function(){if(!Sh())throw new Error("For security reasons, `window.crypto` is required to run `auth0-spa-js`.");if(py()===void 0)throw new Error(`
|
|
3
3
|
auth0-spa-js must run on a secure origin. See https://github.com/auth0/auth0-spa-js/blob/master/FAQ.md#why-do-i-get-auth0-spa-js-must-run-on-a-secure-origin for more information.
|
|
4
|
-
`)}(),t.cache&&t.cacheLocation&&console.warn("Both `cache` and `cacheLocation` options have been specified in the Auth0Client configuration; ignoring `cacheLocation` and using `cache`."),t.cache)i=t.cache;else{if(this.cacheLocation=t.cacheLocation||"memory",!Vp(this.cacheLocation))throw new Error('Invalid cache location "'.concat(this.cacheLocation,'"'));i=Vp(this.cacheLocation)()}this.httpTimeoutMs=t.httpTimeoutInSeconds?1e3*t.httpTimeoutInSeconds:1e4,this.cookieStorage=t.legacySameSiteCookie===!1?pi:X8,this.orgHintCookieName=(o=this.options.client_id,"auth0.".concat(o,".organization_hint")),this.isAuthenticatedCookieName=function(l){return"auth0.".concat(l,".is.authenticated")}(this.options.client_id),this.sessionCheckExpiryDays=t.sessionCheckExpiryDays||1;var s,c=t.useCookiesForTransactions?this.cookieStorage:Z8;this.scope=this.options.scope,this.transactionManager=new G8(c,this.options.client_id),this.nowProvider=this.options.nowProvider||hy,this.cacheManager=new W8(i,i.allKeys?null:new t$(i,this.options.client_id),this.nowProvider),this.domainUrl=(s=this.options.domain,/^https?:\/\//.test(s)?s:"https://".concat(s)),this.tokenIssuer=function(l,u){return l?l.startsWith("https://")?l:"https://".concat(l,"/"):"".concat(u,"/")}(this.options.issuer,this.domainUrl),this.defaultScope=Zn("openid",((r=(n=this.options)===null||n===void 0?void 0:n.advancedOptions)===null||r===void 0?void 0:r.defaultScope)!==void 0?this.options.advancedOptions.defaultScope:"openid profile email"),this.options.useRefreshTokens&&(this.scope=Zn(this.scope,"offline_access")),typeof window<"u"&&window.Worker&&this.options.useRefreshTokens&&this.cacheLocation==="memory"&&r$()&&(this.worker=new e$),this.customOptions=function(l){return l.advancedOptions,l.audience,l.auth0Client,l.authorizeTimeoutInSeconds,l.cacheLocation,l.cache,l.client_id,l.domain,l.issuer,l.leeway,l.max_age,l.nowProvider,l.redirect_uri,l.scope,l.useRefreshTokens,l.useRefreshTokensFallback,l.useCookiesForTransactions,l.useFormData,Ut(l,["advancedOptions","audience","auth0Client","authorizeTimeoutInSeconds","cacheLocation","cache","client_id","domain","issuer","leeway","max_age","nowProvider","redirect_uri","scope","useRefreshTokens","useRefreshTokensFallback","useCookiesForTransactions","useFormData"])}(t),this.useRefreshTokensFallback=this.options.useRefreshTokensFallback!==!1}return e.prototype._url=function(t){var n=encodeURIComponent(btoa(JSON.stringify(this.options.auth0Client||fy)));return"".concat(this.domainUrl).concat(t,"&auth0Client=").concat(n)},e.prototype._getParams=function(t,n,r,i,o){var a=this.options;a.useRefreshTokens,a.useCookiesForTransactions,a.useFormData,a.auth0Client,a.cacheLocation,a.advancedOptions,a.detailedResponse,a.nowProvider,a.authorizeTimeoutInSeconds,a.legacySameSiteCookie,a.sessionCheckExpiryDays,a.domain,a.leeway,a.httpTimeoutInSeconds;var s=Ut(a,["useRefreshTokens","useCookiesForTransactions","useFormData","auth0Client","cacheLocation","advancedOptions","detailedResponse","nowProvider","authorizeTimeoutInSeconds","legacySameSiteCookie","sessionCheckExpiryDays","domain","leeway","httpTimeoutInSeconds"]);return pe(pe(pe({},s),t),{scope:Zn(this.defaultScope,this.scope,t.scope),response_type:"code",response_mode:"query",state:n,nonce:r,redirect_uri:o||this.options.redirect_uri,code_challenge:i,code_challenge_method:"S256"})},e.prototype._authorizeUrl=function(t){return this._url("/authorize?".concat(Hd(t)))},e.prototype._verifyIdToken=function(t,n,r){return xe(this,void 0,void 0,function(){var i;return ke(this,function(o){switch(o.label){case 0:return[4,this.nowProvider()];case 1:return i=o.sent(),[2,Q8({iss:this.tokenIssuer,aud:this.options.client_id,id_token:t,nonce:n,organizationId:r,leeway:this.options.leeway,max_age:this._parseNumber(this.options.max_age),now:i})]}})})},e.prototype._parseNumber=function(t){return typeof t!="string"?t:parseInt(t,10)||void 0},e.prototype._processOrgIdHint=function(t){t?this.cookieStorage.save(this.orgHintCookieName,t,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}):this.cookieStorage.remove(this.orgHintCookieName,{cookieDomain:this.options.cookieDomain})},e.prototype.buildAuthorizeUrl=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u,d,f,h;return ke(this,function(p){switch(p.label){case 0:return n=t.redirect_uri,r=t.appState,i=Ut(t,["redirect_uri","appState"]),o=ai(Ln()),a=ai(Ln()),s=Ln(),[4,$u(s)];case 1:return c=p.sent(),l=wu(c),u=t.fragment?"#".concat(t.fragment):"",d=this._getParams(i,o,a,l,n),f=this._authorizeUrl(d),h=t.organization||this.options.organization,this.transactionManager.create(pe({nonce:a,code_verifier:s,appState:r,scope:d.scope,audience:d.audience||"default",redirect_uri:d.redirect_uri,state:o},h&&{organizationId:h})),[2,f+u]}})})},e.prototype.loginWithPopup=function(t,n){return xe(this,void 0,void 0,function(){var r,i,o,a,s,c,l,u,d,f,h,p,m;return ke(this,function(v){switch(v.label){case 0:if(t=t||{},!(n=n||{}).popup&&(n.popup=function(b){var y=window.screenX+(window.innerWidth-400)/2,g=window.screenY+(window.innerHeight-600)/2;return window.open(b,"auth0:authorize:popup","left=".concat(y,",top=").concat(g,",width=").concat(400,",height=").concat(600,",resizable,scrollbars=yes,status=1"))}(""),!n.popup))throw new Error("Unable to open a popup for loginWithPopup - window.open returned `null`");return r=Ut(t,[]),i=ai(Ln()),o=ai(Ln()),a=Ln(),[4,$u(a)];case 1:return s=v.sent(),c=wu(s),l=this._getParams(r,i,o,c,this.options.redirect_uri||window.location.origin),u=this._authorizeUrl(pe(pe({},l),{response_mode:"web_message"})),n.popup.location.href=u,[4,R8(pe(pe({},n),{timeoutInSeconds:n.timeoutInSeconds||this.options.authorizeTimeoutInSeconds||60}))];case 2:if(d=v.sent(),i!==d.state)throw new Error("Invalid state");return[4,La({audience:l.audience,scope:l.scope,baseUrl:this.domainUrl,client_id:this.options.client_id,code_verifier:a,code:d.code,grant_type:"authorization_code",redirect_uri:l.redirect_uri,auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:this.httpTimeoutMs},this.worker)];case 3:return f=v.sent(),h=t.organization||this.options.organization,[4,this._verifyIdToken(f.id_token,o,h)];case 4:return p=v.sent(),m=pe(pe({},f),{decodedToken:p,scope:l.scope,audience:l.audience||"default",client_id:this.options.client_id}),[4,this.cacheManager.set(m)];case 5:return v.sent(),this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this._processOrgIdHint(p.claims.org_id),[2]}})})},e.prototype.getUser=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i;return ke(this,function(o){switch(o.label){case 0:return n=t.audience||this.options.audience||"default",r=Zn(this.defaultScope,this.scope,t.scope),[4,this.cacheManager.get(new Ir({client_id:this.options.client_id,audience:n,scope:r}))];case 1:return[2,(i=o.sent())&&i.decodedToken&&i.decodedToken.user]}})})},e.prototype.getIdTokenClaims=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i;return ke(this,function(o){switch(o.label){case 0:return n=t.audience||this.options.audience||"default",r=Zn(this.defaultScope,this.scope,t.scope),[4,this.cacheManager.get(new Ir({client_id:this.options.client_id,audience:n,scope:r}))];case 1:return[2,(i=o.sent())&&i.decodedToken&&i.decodedToken.claims]}})})},e.prototype.loginWithRedirect=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i;return ke(this,function(o){switch(o.label){case 0:return n=t.redirectMethod,r=Ut(t,["redirectMethod"]),[4,this.buildAuthorizeUrl(r)];case 1:return i=o.sent(),window.location[n||"assign"](i),[2]}})})},e.prototype.handleRedirectCallback=function(t){return t===void 0&&(t=window.location.href),xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u,d;return ke(this,function(f){switch(f.label){case 0:if((n=t.split("?").slice(1)).length===0)throw new Error("There are no query params available for parsing.");if(r=function(h){h.indexOf("#")>-1&&(h=h.substr(0,h.indexOf("#")));var p=h.split("&"),m={};return p.forEach(function(v){var b=Ai(v.split("="),2),y=b[0],g=b[1];m[y]=decodeURIComponent(g)}),m.expires_in&&(m.expires_in=parseInt(m.expires_in)),m}(n.join("")),i=r.state,o=r.code,a=r.error,s=r.error_description,!(c=this.transactionManager.get()))throw new Error("Invalid state");if(this.transactionManager.remove(),a)throw new A8(a,s,i,c.appState);if(!c.code_verifier||c.state&&c.state!==i)throw new Error("Invalid state");return l={audience:c.audience,scope:c.scope,baseUrl:this.domainUrl,client_id:this.options.client_id,code_verifier:c.code_verifier,grant_type:"authorization_code",code:o,auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:this.httpTimeoutMs},c.redirect_uri!==void 0&&(l.redirect_uri=c.redirect_uri),[4,La(l,this.worker)];case 1:return u=f.sent(),[4,this._verifyIdToken(u.id_token,c.nonce,c.organizationId)];case 2:return d=f.sent(),[4,this.cacheManager.set(pe(pe(pe(pe({},u),{decodedToken:d,audience:c.audience,scope:c.scope}),u.scope?{oauthTokenScope:u.scope}:null),{client_id:this.options.client_id}))];case 3:return f.sent(),this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this._processOrgIdHint(d.claims.org_id),[2,{appState:c.appState}]}})})},e.prototype.checkSession=function(t){return xe(this,void 0,void 0,function(){var n;return ke(this,function(r){switch(r.label){case 0:if(!this.cookieStorage.get(this.isAuthenticatedCookieName)){if(!this.cookieStorage.get("auth0.is.authenticated"))return[2];this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this.cookieStorage.remove("auth0.is.authenticated")}r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.getTokenSilently(t)];case 2:return r.sent(),[3,4];case 3:if(n=r.sent(),!P8.includes(n.error))throw n;return[3,4];case 4:return[2]}})})},e.prototype.getTokenSilently=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i,o,a=this;return ke(this,function(s){switch(s.label){case 0:return n=pe(pe({audience:this.options.audience,ignoreCache:!1},t),{scope:Zn(this.defaultScope,this.scope,t.scope)}),r=n.ignoreCache,i=Ut(n,["ignoreCache"]),[4,(c=function(){return a._getTokenSilently(pe({ignoreCache:r},i))},l="".concat(this.options.client_id,"::").concat(i.audience,"::").concat(i.scope),u=xu[l],u||(u=c().finally(function(){delete xu[l],u=null}),xu[l]=u),u)];case 1:return o=s.sent(),[2,t.detailedResponse?o:o.access_token]}var c,l,u})})},e.prototype._getTokenSilently=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u;return ke(this,function(d){switch(d.label){case 0:return n=t.ignoreCache,r=Ut(t,["ignoreCache"]),n?[3,2]:[4,this._getEntryFromCache({scope:r.scope,audience:r.audience||"default",client_id:this.options.client_id})];case 1:if(i=d.sent())return[2,i];d.label=2;case 2:return[4,(f=function(){return ku.acquireLock("auth0.lock.getTokenSilently",5e3)},h=10,h===void 0&&(h=3),xe(void 0,void 0,void 0,function(){var p;return ke(this,function(m){switch(m.label){case 0:p=0,m.label=1;case 1:return p<h?[4,f()]:[3,4];case 2:if(m.sent())return[2,!0];m.label=3;case 3:return p++,[3,1];case 4:return[2,!1]}})}))];case 3:if(!d.sent())return[3,15];d.label=4;case 4:return d.trys.push([4,,12,14]),window.addEventListener("pagehide",this._releaseLockOnPageHide),n?[3,6]:[4,this._getEntryFromCache({scope:r.scope,audience:r.audience||"default",client_id:this.options.client_id})];case 5:if(i=d.sent())return[2,i];d.label=6;case 6:return this.options.useRefreshTokens?[4,this._getTokenUsingRefreshToken(r)]:[3,8];case 7:return a=d.sent(),[3,10];case 8:return[4,this._getTokenFromIFrame(r)];case 9:a=d.sent(),d.label=10;case 10:return o=a,[4,this.cacheManager.set(pe({client_id:this.options.client_id},o))];case 11:return d.sent(),this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),s=o.id_token,c=o.access_token,l=o.oauthTokenScope,u=o.expires_in,[2,pe(pe({id_token:s,access_token:c},l?{scope:l}:null),{expires_in:u})];case 12:return[4,ku.releaseLock("auth0.lock.getTokenSilently")];case 13:return d.sent(),window.removeEventListener("pagehide",this._releaseLockOnPageHide),[7];case 14:return[3,16];case 15:throw new Bd;case 16:return[2]}var f,h})})},e.prototype.getTokenWithPopup=function(t,n){return t===void 0&&(t={}),n===void 0&&(n={}),xe(this,void 0,void 0,function(){return ke(this,function(r){switch(r.label){case 0:return t.audience=t.audience||this.options.audience,t.scope=Zn(this.defaultScope,this.scope,t.scope),n=pe(pe({},T8),n),[4,this.loginWithPopup(t,n)];case 1:return r.sent(),[4,this.cacheManager.get(new Ir({scope:t.scope,audience:t.audience||"default",client_id:this.options.client_id}))];case 2:return[2,r.sent().access_token]}})})},e.prototype.isAuthenticated=function(){return xe(this,void 0,void 0,function(){return ke(this,function(t){switch(t.label){case 0:return[4,this.getUser()];case 1:return[2,!!t.sent()]}})})},e.prototype.buildLogoutUrl=function(t){t===void 0&&(t={}),t.client_id!==null?t.client_id=t.client_id||this.options.client_id:delete t.client_id;var n=t.federated,r=Ut(t,["federated"]),i=n?"&federated":"";return this._url("/v2/logout?".concat(Hd(r)))+i},e.prototype.logout=function(t){var n=this;t===void 0&&(t={});var r=t.localOnly,i=Ut(t,["localOnly"]);if(r&&i.federated)throw new Error("It is invalid to set both the `federated` and `localOnly` options to `true`");var o=function(){if(n.cookieStorage.remove(n.orgHintCookieName,{cookieDomain:n.options.cookieDomain}),n.cookieStorage.remove(n.isAuthenticatedCookieName,{cookieDomain:n.options.cookieDomain}),!r){var a=n.buildLogoutUrl(i);window.location.assign(a)}};if(this.options.cache)return this.cacheManager.clear().then(function(){return o()});this.cacheManager.clearSync(),o()},e.prototype._getTokenFromIFrame=function(t){return xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u,d,f,h,p,m,v,b,y;return ke(this,function(g){switch(g.label){case 0:return n=ai(Ln()),r=ai(Ln()),i=Ln(),[4,$u(i)];case 1:o=g.sent(),a=wu(o),s=Ut(t,["detailedResponse"]),c=this._getParams(s,n,r,a,t.redirect_uri||this.options.redirect_uri||window.location.origin),(l=this.cookieStorage.get(this.orgHintCookieName))&&!c.organization&&(c.organization=l),u=this._authorizeUrl(pe(pe({},c),{prompt:"none",response_mode:"web_message"})),g.label=2;case 2:if(g.trys.push([2,6,,7]),window.crossOriginIsolated)throw new qn("login_required","The application is running in a Cross-Origin Isolated context, silently retrieving a token without refresh token is not possible.");return d=t.timeoutInSeconds||this.options.authorizeTimeoutInSeconds,[4,(_=u,x=this.domainUrl,O=d,O===void 0&&(O=60),new Promise(function(C,M){var D=window.document.createElement("iframe");D.setAttribute("width","0"),D.setAttribute("height","0"),D.style.display="none";var F,Y=function(){window.document.body.contains(D)&&(window.document.body.removeChild(D),window.removeEventListener("message",F,!1))},J=setTimeout(function(){M(new Bd),Y()},1e3*O);F=function(G){if(G.origin==x&&G.data&&G.data.type==="authorization_response"){var j=G.source;j&&j.close(),G.data.response.error?M(qn.fromPayload(G.data.response)):C(G.data.response),clearTimeout(J),window.removeEventListener("message",F,!1),setTimeout(Y,2e3)}},window.addEventListener("message",F,!1),window.document.body.appendChild(D),D.setAttribute("src",_)}))];case 3:if(f=g.sent(),n!==f.state)throw new Error("Invalid state");return h=t.scope,p=t.audience,m=Ut(t,["scope","audience","redirect_uri","ignoreCache","timeoutInSeconds","detailedResponse"]),[4,La(pe(pe(pe({},this.customOptions),m),{scope:h,audience:p,baseUrl:this.domainUrl,client_id:this.options.client_id,code_verifier:i,code:f.code,grant_type:"authorization_code",redirect_uri:c.redirect_uri,auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:m.timeout||this.httpTimeoutMs}),this.worker)];case 4:return v=g.sent(),[4,this._verifyIdToken(v.id_token,r)];case 5:return b=g.sent(),this._processOrgIdHint(b.claims.org_id),[2,pe(pe({},v),{decodedToken:b,scope:c.scope,oauthTokenScope:v.scope,audience:c.audience||"default"})];case 6:throw(y=g.sent()).error==="login_required"&&this.logout({localOnly:!0}),y;case 7:return[2]}var _,x,O})})},e.prototype._getTokenUsingRefreshToken=function(t){return xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u;return ke(this,function(d){switch(d.label){case 0:return t.scope=Zn(this.defaultScope,this.options.scope,t.scope),[4,this.cacheManager.get(new Ir({scope:t.scope,audience:t.audience||"default",client_id:this.options.client_id}))];case 1:return(n=d.sent())&&n.refresh_token||this.worker?[3,4]:this.useRefreshTokensFallback?[4,this._getTokenFromIFrame(t)]:[3,3];case 2:return[2,d.sent()];case 3:throw new L8(t.audience||"default",t.scope);case 4:r=t.redirect_uri||this.options.redirect_uri||window.location.origin,o=t.scope,a=t.audience,s=Ut(t,["scope","audience","ignoreCache","timeoutInSeconds","detailedResponse"]),c=typeof t.timeoutInSeconds=="number"?1e3*t.timeoutInSeconds:null,d.label=5;case 5:return d.trys.push([5,7,,10]),[4,La(pe(pe(pe(pe(pe({},this.customOptions),s),{audience:a,scope:o,baseUrl:this.domainUrl,client_id:this.options.client_id,grant_type:"refresh_token",refresh_token:n&&n.refresh_token,redirect_uri:r}),c&&{timeout:c}),{auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:this.httpTimeoutMs}),this.worker)];case 6:return i=d.sent(),[3,10];case 7:return((l=d.sent()).message.indexOf("Missing Refresh Token")>-1||l.message&&l.message.indexOf("invalid refresh token")>-1)&&this.useRefreshTokensFallback?[4,this._getTokenFromIFrame(t)]:[3,9];case 8:return[2,d.sent()];case 9:throw l;case 10:return[4,this._verifyIdToken(i.id_token)];case 11:return u=d.sent(),[2,pe(pe({},i),{decodedToken:u,scope:t.scope,oauthTokenScope:i.scope,audience:t.audience||"default"})]}})})},e.prototype._getEntryFromCache=function(t){var n=t.scope,r=t.audience,i=t.client_id;return xe(this,void 0,void 0,function(){var o,a,s,c,l;return ke(this,function(u){switch(u.label){case 0:return[4,this.cacheManager.get(new Ir({scope:n,audience:r,client_id:i}),60)];case 1:return(o=u.sent())&&o.access_token?(a=o.id_token,s=o.access_token,c=o.oauthTokenScope,l=o.expires_in,[2,pe(pe({id_token:a,access_token:s},c?{scope:c}:null),{expires_in:l})]):[2]}})})},e}(),Eu="Invariant Violation",Up=Object.setPrototypeOf,o$=Up===void 0?function(e,t){return e.__proto__=t,e}:Up,Se=function(e){yn(t,e);function t(n){n===void 0&&(n=Eu);var r=e.call(this,typeof n=="number"?Eu+": "+n+" (see https://github.com/apollographql/invariant-packages)":n)||this;return r.framesToPop=1,r.name=Eu,o$(r,t.prototype),r}return t}(Error);function K(e,t){if(!e)throw new Se(t)}var gy=["debug","log","warn","error","silent"],a$=gy.indexOf("log");function Ra(e){return function(){if(gy.indexOf(e)>=a$){var t=console[e]||console.log;return t.apply(console,arguments)}}}(function(e){e.debug=Ra("debug"),e.log=Ra("log"),e.warn=Ra("warn"),e.error=Ra("error")})(K||(K={}));function en(e){try{return e()}catch{}}const Bp=en(function(){return globalThis})||en(function(){return window})||en(function(){return self})||en(function(){return global})||en(function(){return en.constructor("return this")()});var Hp="__",qp=[Hp,Hp].join("DEV");function s$(){try{return Boolean(__DEV__)}catch{return Object.defineProperty(Bp,qp,{value:en(function(){return"production"})!=="production",enumerable:!1,configurable:!0,writable:!0}),Bp[qp]}}const Su=s$();function rr(e){try{return e()}catch{}}var qd=rr(function(){return globalThis})||rr(function(){return window})||rr(function(){return self})||rr(function(){return global})||rr(function(){return rr.constructor("return this")()}),Wd=!1;function l$(){qd&&!rr(function(){return"production"})&&!rr(function(){return process})&&(Object.defineProperty(qd,"process",{value:{env:{NODE_ENV:"production"}},configurable:!0,enumerable:!1,writable:!0}),Wd=!0)}l$();function Wp(){Wd&&(delete qd.process,Wd=!1)}function cs(e,t){if(!Boolean(e))throw new Error(t)}function c$(e){return typeof e=="object"&&e!==null}function u$(e,t){if(!Boolean(e))throw new Error(t??"Unexpected invariant triggered.")}const d$=/\r\n|[\n\r]/g;function Gd(e,t){let n=0,r=1;for(const i of e.body.matchAll(d$)){if(typeof i.index=="number"||u$(!1),i.index>=t)break;n=i.index+i[0].length,r+=1}return{line:r,column:t+1-n}}function f$(e){return yy(e.source,Gd(e.source,e.start))}function yy(e,t){const n=e.locationOffset.column-1,r="".padStart(n)+e.body,i=t.line-1,o=e.locationOffset.line-1,a=t.line+o,s=t.line===1?n:0,c=t.column+s,l=`${e.name}:${a}:${c}
|
|
4
|
+
`)}(),t.cache&&t.cacheLocation&&console.warn("Both `cache` and `cacheLocation` options have been specified in the Auth0Client configuration; ignoring `cacheLocation` and using `cache`."),t.cache)i=t.cache;else{if(this.cacheLocation=t.cacheLocation||"memory",!Vp(this.cacheLocation))throw new Error('Invalid cache location "'.concat(this.cacheLocation,'"'));i=Vp(this.cacheLocation)()}this.httpTimeoutMs=t.httpTimeoutInSeconds?1e3*t.httpTimeoutInSeconds:1e4,this.cookieStorage=t.legacySameSiteCookie===!1?pi:X8,this.orgHintCookieName=(o=this.options.client_id,"auth0.".concat(o,".organization_hint")),this.isAuthenticatedCookieName=function(l){return"auth0.".concat(l,".is.authenticated")}(this.options.client_id),this.sessionCheckExpiryDays=t.sessionCheckExpiryDays||1;var s,c=t.useCookiesForTransactions?this.cookieStorage:Z8;this.scope=this.options.scope,this.transactionManager=new G8(c,this.options.client_id),this.nowProvider=this.options.nowProvider||hy,this.cacheManager=new W8(i,i.allKeys?null:new t$(i,this.options.client_id),this.nowProvider),this.domainUrl=(s=this.options.domain,/^https?:\/\//.test(s)?s:"https://".concat(s)),this.tokenIssuer=function(l,u){return l?l.startsWith("https://")?l:"https://".concat(l,"/"):"".concat(u,"/")}(this.options.issuer,this.domainUrl),this.defaultScope=Zn("openid",((r=(n=this.options)===null||n===void 0?void 0:n.advancedOptions)===null||r===void 0?void 0:r.defaultScope)!==void 0?this.options.advancedOptions.defaultScope:"openid profile email"),this.options.useRefreshTokens&&(this.scope=Zn(this.scope,"offline_access")),typeof window<"u"&&window.Worker&&this.options.useRefreshTokens&&this.cacheLocation==="memory"&&r$()&&(this.worker=new e$),this.customOptions=function(l){return l.advancedOptions,l.audience,l.auth0Client,l.authorizeTimeoutInSeconds,l.cacheLocation,l.cache,l.client_id,l.domain,l.issuer,l.leeway,l.max_age,l.nowProvider,l.redirect_uri,l.scope,l.useRefreshTokens,l.useRefreshTokensFallback,l.useCookiesForTransactions,l.useFormData,Ut(l,["advancedOptions","audience","auth0Client","authorizeTimeoutInSeconds","cacheLocation","cache","client_id","domain","issuer","leeway","max_age","nowProvider","redirect_uri","scope","useRefreshTokens","useRefreshTokensFallback","useCookiesForTransactions","useFormData"])}(t),this.useRefreshTokensFallback=this.options.useRefreshTokensFallback!==!1}return e.prototype._url=function(t){var n=encodeURIComponent(btoa(JSON.stringify(this.options.auth0Client||fy)));return"".concat(this.domainUrl).concat(t,"&auth0Client=").concat(n)},e.prototype._getParams=function(t,n,r,i,o){var a=this.options;a.useRefreshTokens,a.useCookiesForTransactions,a.useFormData,a.auth0Client,a.cacheLocation,a.advancedOptions,a.detailedResponse,a.nowProvider,a.authorizeTimeoutInSeconds,a.legacySameSiteCookie,a.sessionCheckExpiryDays,a.domain,a.leeway,a.httpTimeoutInSeconds;var s=Ut(a,["useRefreshTokens","useCookiesForTransactions","useFormData","auth0Client","cacheLocation","advancedOptions","detailedResponse","nowProvider","authorizeTimeoutInSeconds","legacySameSiteCookie","sessionCheckExpiryDays","domain","leeway","httpTimeoutInSeconds"]);return pe(pe(pe({},s),t),{scope:Zn(this.defaultScope,this.scope,t.scope),response_type:"code",response_mode:"query",state:n,nonce:r,redirect_uri:o||this.options.redirect_uri,code_challenge:i,code_challenge_method:"S256"})},e.prototype._authorizeUrl=function(t){return this._url("/authorize?".concat(Hd(t)))},e.prototype._verifyIdToken=function(t,n,r){return xe(this,void 0,void 0,function(){var i;return ke(this,function(o){switch(o.label){case 0:return[4,this.nowProvider()];case 1:return i=o.sent(),[2,Q8({iss:this.tokenIssuer,aud:this.options.client_id,id_token:t,nonce:n,organizationId:r,leeway:this.options.leeway,max_age:this._parseNumber(this.options.max_age),now:i})]}})})},e.prototype._parseNumber=function(t){return typeof t!="string"?t:parseInt(t,10)||void 0},e.prototype._processOrgIdHint=function(t){t?this.cookieStorage.save(this.orgHintCookieName,t,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}):this.cookieStorage.remove(this.orgHintCookieName,{cookieDomain:this.options.cookieDomain})},e.prototype.buildAuthorizeUrl=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u,d,f,h;return ke(this,function(p){switch(p.label){case 0:return n=t.redirect_uri,r=t.appState,i=Ut(t,["redirect_uri","appState"]),o=ai(Ln()),a=ai(Ln()),s=Ln(),[4,$u(s)];case 1:return c=p.sent(),l=wu(c),u=t.fragment?"#".concat(t.fragment):"",d=this._getParams(i,o,a,l,n),f=this._authorizeUrl(d),h=t.organization||this.options.organization,this.transactionManager.create(pe({nonce:a,code_verifier:s,appState:r,scope:d.scope,audience:d.audience||"default",redirect_uri:d.redirect_uri,state:o},h&&{organizationId:h})),[2,f+u]}})})},e.prototype.loginWithPopup=function(t,n){return xe(this,void 0,void 0,function(){var r,i,o,a,s,c,l,u,d,f,h,p,m;return ke(this,function(v){switch(v.label){case 0:if(t=t||{},!(n=n||{}).popup&&(n.popup=function(b){var y=window.screenX+(window.innerWidth-400)/2,g=window.screenY+(window.innerHeight-600)/2;return window.open(b,"auth0:authorize:popup","left=".concat(y,",top=").concat(g,",width=").concat(400,",height=").concat(600,",resizable,scrollbars=yes,status=1"))}(""),!n.popup))throw new Error("Unable to open a popup for loginWithPopup - window.open returned `null`");return r=Ut(t,[]),i=ai(Ln()),o=ai(Ln()),a=Ln(),[4,$u(a)];case 1:return s=v.sent(),c=wu(s),l=this._getParams(r,i,o,c,this.options.redirect_uri||window.location.origin),u=this._authorizeUrl(pe(pe({},l),{response_mode:"web_message"})),n.popup.location.href=u,[4,R8(pe(pe({},n),{timeoutInSeconds:n.timeoutInSeconds||this.options.authorizeTimeoutInSeconds||60}))];case 2:if(d=v.sent(),i!==d.state)throw new Error("Invalid state");return[4,La({audience:l.audience,scope:l.scope,baseUrl:this.domainUrl,client_id:this.options.client_id,code_verifier:a,code:d.code,grant_type:"authorization_code",redirect_uri:l.redirect_uri,auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:this.httpTimeoutMs},this.worker)];case 3:return f=v.sent(),h=t.organization||this.options.organization,[4,this._verifyIdToken(f.id_token,o,h)];case 4:return p=v.sent(),m=pe(pe({},f),{decodedToken:p,scope:l.scope,audience:l.audience||"default",client_id:this.options.client_id}),[4,this.cacheManager.set(m)];case 5:return v.sent(),this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this._processOrgIdHint(p.claims.org_id),[2]}})})},e.prototype.getUser=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i;return ke(this,function(o){switch(o.label){case 0:return n=t.audience||this.options.audience||"default",r=Zn(this.defaultScope,this.scope,t.scope),[4,this.cacheManager.get(new Ir({client_id:this.options.client_id,audience:n,scope:r}))];case 1:return[2,(i=o.sent())&&i.decodedToken&&i.decodedToken.user]}})})},e.prototype.getIdTokenClaims=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i;return ke(this,function(o){switch(o.label){case 0:return n=t.audience||this.options.audience||"default",r=Zn(this.defaultScope,this.scope,t.scope),[4,this.cacheManager.get(new Ir({client_id:this.options.client_id,audience:n,scope:r}))];case 1:return[2,(i=o.sent())&&i.decodedToken&&i.decodedToken.claims]}})})},e.prototype.loginWithRedirect=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i;return ke(this,function(o){switch(o.label){case 0:return n=t.redirectMethod,r=Ut(t,["redirectMethod"]),[4,this.buildAuthorizeUrl(r)];case 1:return i=o.sent(),window.location[n||"assign"](i),[2]}})})},e.prototype.handleRedirectCallback=function(t){return t===void 0&&(t=window.location.href),xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u,d;return ke(this,function(f){switch(f.label){case 0:if((n=t.split("?").slice(1)).length===0)throw new Error("There are no query params available for parsing.");if(r=function(h){h.indexOf("#")>-1&&(h=h.substr(0,h.indexOf("#")));var p=h.split("&"),m={};return p.forEach(function(v){var b=Ai(v.split("="),2),y=b[0],g=b[1];m[y]=decodeURIComponent(g)}),m.expires_in&&(m.expires_in=parseInt(m.expires_in)),m}(n.join("")),i=r.state,o=r.code,a=r.error,s=r.error_description,!(c=this.transactionManager.get()))throw new Error("Invalid state");if(this.transactionManager.remove(),a)throw new A8(a,s,i,c.appState);if(!c.code_verifier||c.state&&c.state!==i)throw new Error("Invalid state");return l={audience:c.audience,scope:c.scope,baseUrl:this.domainUrl,client_id:this.options.client_id,code_verifier:c.code_verifier,grant_type:"authorization_code",code:o,auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:this.httpTimeoutMs},c.redirect_uri!==void 0&&(l.redirect_uri=c.redirect_uri),[4,La(l,this.worker)];case 1:return u=f.sent(),[4,this._verifyIdToken(u.id_token,c.nonce,c.organizationId)];case 2:return d=f.sent(),[4,this.cacheManager.set(pe(pe(pe(pe({},u),{decodedToken:d,audience:c.audience,scope:c.scope}),u.scope?{oauthTokenScope:u.scope}:null),{client_id:this.options.client_id}))];case 3:return f.sent(),this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this._processOrgIdHint(d.claims.org_id),[2,{appState:c.appState}]}})})},e.prototype.checkSession=function(t){return xe(this,void 0,void 0,function(){var n;return ke(this,function(r){switch(r.label){case 0:if(!this.cookieStorage.get(this.isAuthenticatedCookieName)){if(!this.cookieStorage.get("auth0.is.authenticated"))return[2];this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this.cookieStorage.remove("auth0.is.authenticated")}r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.getTokenSilently(t)];case 2:return r.sent(),[3,4];case 3:if(n=r.sent(),!P8.includes(n.error))throw n;return[3,4];case 4:return[2]}})})},e.prototype.getTokenSilently=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i,o,a=this;return ke(this,function(s){switch(s.label){case 0:return n=pe(pe({audience:this.options.audience,ignoreCache:!1},t),{scope:Zn(this.defaultScope,this.scope,t.scope)}),r=n.ignoreCache,i=Ut(n,["ignoreCache"]),[4,(c=function(){return a._getTokenSilently(pe({ignoreCache:r},i))},l="".concat(this.options.client_id,"::").concat(i.audience,"::").concat(i.scope),u=xu[l],u||(u=c().finally(function(){delete xu[l],u=null}),xu[l]=u),u)];case 1:return o=s.sent(),[2,t.detailedResponse?o:o.access_token]}var c,l,u})})},e.prototype._getTokenSilently=function(t){return t===void 0&&(t={}),xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u;return ke(this,function(d){switch(d.label){case 0:return n=t.ignoreCache,r=Ut(t,["ignoreCache"]),n?[3,2]:[4,this._getEntryFromCache({scope:r.scope,audience:r.audience||"default",client_id:this.options.client_id})];case 1:if(i=d.sent())return[2,i];d.label=2;case 2:return[4,(f=function(){return ku.acquireLock("auth0.lock.getTokenSilently",5e3)},h=10,h===void 0&&(h=3),xe(void 0,void 0,void 0,function(){var p;return ke(this,function(m){switch(m.label){case 0:p=0,m.label=1;case 1:return p<h?[4,f()]:[3,4];case 2:if(m.sent())return[2,!0];m.label=3;case 3:return p++,[3,1];case 4:return[2,!1]}})}))];case 3:if(!d.sent())return[3,15];d.label=4;case 4:return d.trys.push([4,,12,14]),window.addEventListener("pagehide",this._releaseLockOnPageHide),n?[3,6]:[4,this._getEntryFromCache({scope:r.scope,audience:r.audience||"default",client_id:this.options.client_id})];case 5:if(i=d.sent())return[2,i];d.label=6;case 6:return this.options.useRefreshTokens?[4,this._getTokenUsingRefreshToken(r)]:[3,8];case 7:return a=d.sent(),[3,10];case 8:return[4,this._getTokenFromIFrame(r)];case 9:a=d.sent(),d.label=10;case 10:return o=a,[4,this.cacheManager.set(pe({client_id:this.options.client_id},o))];case 11:return d.sent(),this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),s=o.id_token,c=o.access_token,l=o.oauthTokenScope,u=o.expires_in,[2,pe(pe({id_token:s,access_token:c},l?{scope:l}:null),{expires_in:u})];case 12:return[4,ku.releaseLock("auth0.lock.getTokenSilently")];case 13:return d.sent(),window.removeEventListener("pagehide",this._releaseLockOnPageHide),[7];case 14:return[3,16];case 15:throw new Bd;case 16:return[2]}var f,h})})},e.prototype.getTokenWithPopup=function(t,n){return t===void 0&&(t={}),n===void 0&&(n={}),xe(this,void 0,void 0,function(){return ke(this,function(r){switch(r.label){case 0:return t.audience=t.audience||this.options.audience,t.scope=Zn(this.defaultScope,this.scope,t.scope),n=pe(pe({},T8),n),[4,this.loginWithPopup(t,n)];case 1:return r.sent(),[4,this.cacheManager.get(new Ir({scope:t.scope,audience:t.audience||"default",client_id:this.options.client_id}))];case 2:return[2,r.sent().access_token]}})})},e.prototype.isAuthenticated=function(){return xe(this,void 0,void 0,function(){return ke(this,function(t){switch(t.label){case 0:return[4,this.getUser()];case 1:return[2,!!t.sent()]}})})},e.prototype.buildLogoutUrl=function(t){t===void 0&&(t={}),t.client_id!==null?t.client_id=t.client_id||this.options.client_id:delete t.client_id;var n=t.federated,r=Ut(t,["federated"]),i=n?"&federated":"";return this._url("/v2/logout?".concat(Hd(r)))+i},e.prototype.logout=function(t){var n=this;t===void 0&&(t={});var r=t.localOnly,i=Ut(t,["localOnly"]);if(r&&i.federated)throw new Error("It is invalid to set both the `federated` and `localOnly` options to `true`");var o=function(){if(n.cookieStorage.remove(n.orgHintCookieName,{cookieDomain:n.options.cookieDomain}),n.cookieStorage.remove(n.isAuthenticatedCookieName,{cookieDomain:n.options.cookieDomain}),!r){var a=n.buildLogoutUrl(i);window.location.assign(a)}};if(this.options.cache)return this.cacheManager.clear().then(function(){return o()});this.cacheManager.clearSync(),o()},e.prototype._getTokenFromIFrame=function(t){return xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u,d,f,h,p,m,v,b,y;return ke(this,function(g){switch(g.label){case 0:return n=ai(Ln()),r=ai(Ln()),i=Ln(),[4,$u(i)];case 1:o=g.sent(),a=wu(o),s=Ut(t,["detailedResponse"]),c=this._getParams(s,n,r,a,t.redirect_uri||this.options.redirect_uri||window.location.origin),(l=this.cookieStorage.get(this.orgHintCookieName))&&!c.organization&&(c.organization=l),u=this._authorizeUrl(pe(pe({},c),{prompt:"none",response_mode:"web_message"})),g.label=2;case 2:if(g.trys.push([2,6,,7]),window.crossOriginIsolated)throw new qn("login_required","The application is running in a Cross-Origin Isolated context, silently retrieving a token without refresh token is not possible.");return d=t.timeoutInSeconds||this.options.authorizeTimeoutInSeconds,[4,(_=u,k=this.domainUrl,O=d,O===void 0&&(O=60),new Promise(function(C,M){var D=window.document.createElement("iframe");D.setAttribute("width","0"),D.setAttribute("height","0"),D.style.display="none";var F,Y=function(){window.document.body.contains(D)&&(window.document.body.removeChild(D),window.removeEventListener("message",F,!1))},J=setTimeout(function(){M(new Bd),Y()},1e3*O);F=function(G){if(G.origin==k&&G.data&&G.data.type==="authorization_response"){var j=G.source;j&&j.close(),G.data.response.error?M(qn.fromPayload(G.data.response)):C(G.data.response),clearTimeout(J),window.removeEventListener("message",F,!1),setTimeout(Y,2e3)}},window.addEventListener("message",F,!1),window.document.body.appendChild(D),D.setAttribute("src",_)}))];case 3:if(f=g.sent(),n!==f.state)throw new Error("Invalid state");return h=t.scope,p=t.audience,m=Ut(t,["scope","audience","redirect_uri","ignoreCache","timeoutInSeconds","detailedResponse"]),[4,La(pe(pe(pe({},this.customOptions),m),{scope:h,audience:p,baseUrl:this.domainUrl,client_id:this.options.client_id,code_verifier:i,code:f.code,grant_type:"authorization_code",redirect_uri:c.redirect_uri,auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:m.timeout||this.httpTimeoutMs}),this.worker)];case 4:return v=g.sent(),[4,this._verifyIdToken(v.id_token,r)];case 5:return b=g.sent(),this._processOrgIdHint(b.claims.org_id),[2,pe(pe({},v),{decodedToken:b,scope:c.scope,oauthTokenScope:v.scope,audience:c.audience||"default"})];case 6:throw(y=g.sent()).error==="login_required"&&this.logout({localOnly:!0}),y;case 7:return[2]}var _,k,O})})},e.prototype._getTokenUsingRefreshToken=function(t){return xe(this,void 0,void 0,function(){var n,r,i,o,a,s,c,l,u;return ke(this,function(d){switch(d.label){case 0:return t.scope=Zn(this.defaultScope,this.options.scope,t.scope),[4,this.cacheManager.get(new Ir({scope:t.scope,audience:t.audience||"default",client_id:this.options.client_id}))];case 1:return(n=d.sent())&&n.refresh_token||this.worker?[3,4]:this.useRefreshTokensFallback?[4,this._getTokenFromIFrame(t)]:[3,3];case 2:return[2,d.sent()];case 3:throw new L8(t.audience||"default",t.scope);case 4:r=t.redirect_uri||this.options.redirect_uri||window.location.origin,o=t.scope,a=t.audience,s=Ut(t,["scope","audience","ignoreCache","timeoutInSeconds","detailedResponse"]),c=typeof t.timeoutInSeconds=="number"?1e3*t.timeoutInSeconds:null,d.label=5;case 5:return d.trys.push([5,7,,10]),[4,La(pe(pe(pe(pe(pe({},this.customOptions),s),{audience:a,scope:o,baseUrl:this.domainUrl,client_id:this.options.client_id,grant_type:"refresh_token",refresh_token:n&&n.refresh_token,redirect_uri:r}),c&&{timeout:c}),{auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:this.httpTimeoutMs}),this.worker)];case 6:return i=d.sent(),[3,10];case 7:return((l=d.sent()).message.indexOf("Missing Refresh Token")>-1||l.message&&l.message.indexOf("invalid refresh token")>-1)&&this.useRefreshTokensFallback?[4,this._getTokenFromIFrame(t)]:[3,9];case 8:return[2,d.sent()];case 9:throw l;case 10:return[4,this._verifyIdToken(i.id_token)];case 11:return u=d.sent(),[2,pe(pe({},i),{decodedToken:u,scope:t.scope,oauthTokenScope:i.scope,audience:t.audience||"default"})]}})})},e.prototype._getEntryFromCache=function(t){var n=t.scope,r=t.audience,i=t.client_id;return xe(this,void 0,void 0,function(){var o,a,s,c,l;return ke(this,function(u){switch(u.label){case 0:return[4,this.cacheManager.get(new Ir({scope:n,audience:r,client_id:i}),60)];case 1:return(o=u.sent())&&o.access_token?(a=o.id_token,s=o.access_token,c=o.oauthTokenScope,l=o.expires_in,[2,pe(pe({id_token:a,access_token:s},c?{scope:c}:null),{expires_in:l})]):[2]}})})},e}(),Eu="Invariant Violation",Up=Object.setPrototypeOf,o$=Up===void 0?function(e,t){return e.__proto__=t,e}:Up,Se=function(e){yn(t,e);function t(n){n===void 0&&(n=Eu);var r=e.call(this,typeof n=="number"?Eu+": "+n+" (see https://github.com/apollographql/invariant-packages)":n)||this;return r.framesToPop=1,r.name=Eu,o$(r,t.prototype),r}return t}(Error);function K(e,t){if(!e)throw new Se(t)}var gy=["debug","log","warn","error","silent"],a$=gy.indexOf("log");function Ra(e){return function(){if(gy.indexOf(e)>=a$){var t=console[e]||console.log;return t.apply(console,arguments)}}}(function(e){e.debug=Ra("debug"),e.log=Ra("log"),e.warn=Ra("warn"),e.error=Ra("error")})(K||(K={}));function en(e){try{return e()}catch{}}const Bp=en(function(){return globalThis})||en(function(){return window})||en(function(){return self})||en(function(){return global})||en(function(){return en.constructor("return this")()});var Hp="__",qp=[Hp,Hp].join("DEV");function s$(){try{return Boolean(__DEV__)}catch{return Object.defineProperty(Bp,qp,{value:en(function(){return"production"})!=="production",enumerable:!1,configurable:!0,writable:!0}),Bp[qp]}}const Su=s$();function rr(e){try{return e()}catch{}}var qd=rr(function(){return globalThis})||rr(function(){return window})||rr(function(){return self})||rr(function(){return global})||rr(function(){return rr.constructor("return this")()}),Wd=!1;function l$(){qd&&!rr(function(){return"production"})&&!rr(function(){return process})&&(Object.defineProperty(qd,"process",{value:{env:{NODE_ENV:"production"}},configurable:!0,enumerable:!1,writable:!0}),Wd=!0)}l$();function Wp(){Wd&&(delete qd.process,Wd=!1)}function cs(e,t){if(!Boolean(e))throw new Error(t)}function c$(e){return typeof e=="object"&&e!==null}function u$(e,t){if(!Boolean(e))throw new Error(t??"Unexpected invariant triggered.")}const d$=/\r\n|[\n\r]/g;function Gd(e,t){let n=0,r=1;for(const i of e.body.matchAll(d$)){if(typeof i.index=="number"||u$(!1),i.index>=t)break;n=i.index+i[0].length,r+=1}return{line:r,column:t+1-n}}function f$(e){return yy(e.source,Gd(e.source,e.start))}function yy(e,t){const n=e.locationOffset.column-1,r="".padStart(n)+e.body,i=t.line-1,o=e.locationOffset.line-1,a=t.line+o,s=t.line===1?n:0,c=t.column+s,l=`${e.name}:${a}:${c}
|
|
5
5
|
`,u=r.split(/\r\n|[\n\r]/g),d=u[i];if(d.length>120){const f=Math.floor(c/80),h=c%80,p=[];for(let m=0;m<d.length;m+=80)p.push(d.slice(m,m+80));return l+Gp([[`${a} |`,p[0]],...p.slice(1,f+1).map(m=>["|",m]),["|","^".padStart(h)],["|",p[f+1]]])}return l+Gp([[`${a-1} |`,u[i-1]],[`${a} |`,d],["|","^".padStart(c)],[`${a+1} |`,u[i+1]]])}function Gp(e){const t=e.filter(([r,i])=>i!==void 0),n=Math.max(...t.map(([r])=>r.length));return t.map(([r,i])=>r.padStart(n)+(i?" "+i:"")).join(`
|
|
6
6
|
`)}function h$(e){const t=e[0];return t==null||"kind"in t||"length"in t?{nodes:t,source:e[1],positions:e[2],path:e[3],originalError:e[4],extensions:e[5]}:t}class Oh extends Error{constructor(t,...n){var r,i,o;const{nodes:a,source:s,positions:c,path:l,originalError:u,extensions:d}=h$(n);super(t),this.name="GraphQLError",this.path=l??void 0,this.originalError=u??void 0,this.nodes=Kp(Array.isArray(a)?a:a?[a]:void 0);const f=Kp((r=this.nodes)===null||r===void 0?void 0:r.map(p=>p.loc).filter(p=>p!=null));this.source=s??(f==null||(i=f[0])===null||i===void 0?void 0:i.source),this.positions=c??f?.map(p=>p.start),this.locations=c&&s?c.map(p=>Gd(s,p)):f?.map(p=>Gd(p.source,p.start));const h=c$(u?.extensions)?u?.extensions:void 0;this.extensions=(o=d??h)!==null&&o!==void 0?o:Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),u!=null&&u.stack?Object.defineProperty(this,"stack",{value:u.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,Oh):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let t=this.message;if(this.nodes)for(const n of this.nodes)n.loc&&(t+=`
|
|
7
7
|
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
`),d+=n,(u||l)&&(d+=`
|
|
12
12
|
`),'"""'+d+'"""'}var L;(function(e){e.SOF="<SOF>",e.EOF="<EOF>",e.BANG="!",e.DOLLAR="$",e.AMP="&",e.PAREN_L="(",e.PAREN_R=")",e.SPREAD="...",e.COLON=":",e.EQUALS="=",e.AT="@",e.BRACKET_L="[",e.BRACKET_R="]",e.BRACE_L="{",e.PIPE="|",e.BRACE_R="}",e.NAME="Name",e.INT="Int",e.FLOAT="Float",e.STRING="String",e.BLOCK_STRING="BlockString",e.COMMENT="Comment"})(L||(L={}));class $${constructor(t){const n=new by(L.SOF,0,0,0,0);this.source=t,this.lastToken=n,this.token=n,this.line=1,this.lineStart=0}get[Symbol.toStringTag](){return"Lexer"}advance(){return this.lastToken=this.token,this.token=this.lookahead()}lookahead(){let t=this.token;if(t.kind!==L.EOF)do if(t.next)t=t.next;else{const n=_$(this,t.end);t.next=n,n.prev=t,t=n}while(t.kind===L.COMMENT);return t}}function w$(e){return e===L.BANG||e===L.DOLLAR||e===L.AMP||e===L.PAREN_L||e===L.PAREN_R||e===L.SPREAD||e===L.COLON||e===L.EQUALS||e===L.AT||e===L.BRACKET_L||e===L.BRACKET_R||e===L.BRACE_L||e===L.PIPE||e===L.BRACE_R}function ro(e){return e>=0&&e<=55295||e>=57344&&e<=1114111}function Ic(e,t){return xy(e.charCodeAt(t))&&ky(e.charCodeAt(t+1))}function xy(e){return e>=55296&&e<=56319}function ky(e){return e>=56320&&e<=57343}function qr(e,t){const n=e.source.body.codePointAt(t);if(n===void 0)return L.EOF;if(n>=32&&n<=126){const r=String.fromCodePoint(n);return r==='"'?`'"'`:`"${r}"`}return"U+"+n.toString(16).toUpperCase().padStart(4,"0")}function ot(e,t,n,r,i){const o=e.line,a=1+n-e.lineStart;return new by(t,n,r,o,a,i)}function _$(e,t){const n=e.source.body,r=n.length;let i=t;for(;i<r;){const o=n.charCodeAt(i);switch(o){case 65279:case 9:case 32:case 44:++i;continue;case 10:++i,++e.line,e.lineStart=i;continue;case 13:n.charCodeAt(i+1)===10?i+=2:++i,++e.line,e.lineStart=i;continue;case 35:return x$(e,i);case 33:return ot(e,L.BANG,i,i+1);case 36:return ot(e,L.DOLLAR,i,i+1);case 38:return ot(e,L.AMP,i,i+1);case 40:return ot(e,L.PAREN_L,i,i+1);case 41:return ot(e,L.PAREN_R,i,i+1);case 46:if(n.charCodeAt(i+1)===46&&n.charCodeAt(i+2)===46)return ot(e,L.SPREAD,i,i+3);break;case 58:return ot(e,L.COLON,i,i+1);case 61:return ot(e,L.EQUALS,i,i+1);case 64:return ot(e,L.AT,i,i+1);case 91:return ot(e,L.BRACKET_L,i,i+1);case 93:return ot(e,L.BRACKET_R,i,i+1);case 123:return ot(e,L.BRACE_L,i,i+1);case 124:return ot(e,L.PIPE,i,i+1);case 125:return ot(e,L.BRACE_R,i,i+1);case 34:return n.charCodeAt(i+1)===34&&n.charCodeAt(i+2)===34?N$(e,i):E$(e,i)}if(Jo(o)||o===45)return k$(e,i,o);if(_y(o))return T$(e,i);throw gt(e.source,i,o===39?`Unexpected single quote character ('), did you mean to use a double quote (")?`:ro(o)||Ic(n,i)?`Unexpected character: ${qr(e,i)}.`:`Invalid character: ${qr(e,i)}.`)}return ot(e,L.EOF,r,r)}function x$(e,t){const n=e.source.body,r=n.length;let i=t+1;for(;i<r;){const o=n.charCodeAt(i);if(o===10||o===13)break;if(ro(o))++i;else if(Ic(n,i))i+=2;else break}return ot(e,L.COMMENT,t,i,n.slice(t+1,i))}function k$(e,t,n){const r=e.source.body;let i=t,o=n,a=!1;if(o===45&&(o=r.charCodeAt(++i)),o===48){if(o=r.charCodeAt(++i),Jo(o))throw gt(e.source,i,`Invalid number, unexpected digit after 0: ${qr(e,i)}.`)}else i=Ou(e,i,o),o=r.charCodeAt(i);if(o===46&&(a=!0,o=r.charCodeAt(++i),i=Ou(e,i,o),o=r.charCodeAt(i)),(o===69||o===101)&&(a=!0,o=r.charCodeAt(++i),(o===43||o===45)&&(o=r.charCodeAt(++i)),i=Ou(e,i,o),o=r.charCodeAt(i)),o===46||_y(o))throw gt(e.source,i,`Invalid number, expected digit but got: ${qr(e,i)}.`);return ot(e,a?L.FLOAT:L.INT,t,i,r.slice(t,i))}function Ou(e,t,n){if(!Jo(n))throw gt(e.source,t,`Invalid number, expected digit but got: ${qr(e,t)}.`);const r=e.source.body;let i=t+1;for(;Jo(r.charCodeAt(i));)++i;return i}function E$(e,t){const n=e.source.body,r=n.length;let i=t+1,o=i,a="";for(;i<r;){const s=n.charCodeAt(i);if(s===34)return a+=n.slice(o,i),ot(e,L.STRING,t,i+1,a);if(s===92){a+=n.slice(o,i);const c=n.charCodeAt(i+1)===117?n.charCodeAt(i+2)===123?S$(e,i):O$(e,i):C$(e,i);a+=c.value,i+=c.size,o=i;continue}if(s===10||s===13)break;if(ro(s))++i;else if(Ic(n,i))i+=2;else throw gt(e.source,i,`Invalid character within String: ${qr(e,i)}.`)}throw gt(e.source,i,"Unterminated string.")}function S$(e,t){const n=e.source.body;let r=0,i=3;for(;i<12;){const o=n.charCodeAt(t+i++);if(o===125){if(i<5||!ro(r))break;return{value:String.fromCodePoint(r),size:i}}if(r=r<<4|Do(o),r<0)break}throw gt(e.source,t,`Invalid Unicode escape sequence: "${n.slice(t,t+i)}".`)}function O$(e,t){const n=e.source.body,r=Yp(n,t+2);if(ro(r))return{value:String.fromCodePoint(r),size:6};if(xy(r)&&n.charCodeAt(t+6)===92&&n.charCodeAt(t+7)===117){const i=Yp(n,t+8);if(ky(i))return{value:String.fromCodePoint(r,i),size:12}}throw gt(e.source,t,`Invalid Unicode escape sequence: "${n.slice(t,t+6)}".`)}function Yp(e,t){return Do(e.charCodeAt(t))<<12|Do(e.charCodeAt(t+1))<<8|Do(e.charCodeAt(t+2))<<4|Do(e.charCodeAt(t+3))}function Do(e){return e>=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:-1}function C$(e,t){const n=e.source.body;switch(n.charCodeAt(t+1)){case 34:return{value:'"',size:2};case 92:return{value:"\\",size:2};case 47:return{value:"/",size:2};case 98:return{value:"\b",size:2};case 102:return{value:"\f",size:2};case 110:return{value:`
|
|
13
13
|
`,size:2};case 114:return{value:"\r",size:2};case 116:return{value:" ",size:2}}throw gt(e.source,t,`Invalid character escape sequence: "${n.slice(t,t+2)}".`)}function N$(e,t){const n=e.source.body,r=n.length;let i=e.lineStart,o=t+3,a=o,s="";const c=[];for(;o<r;){const l=n.charCodeAt(o);if(l===34&&n.charCodeAt(o+1)===34&&n.charCodeAt(o+2)===34){s+=n.slice(a,o),c.push(s);const u=ot(e,L.BLOCK_STRING,t,o+3,g$(c).join(`
|
|
14
|
-
`));return e.line+=c.length-1,e.lineStart=i,u}if(l===92&&n.charCodeAt(o+1)===34&&n.charCodeAt(o+2)===34&&n.charCodeAt(o+3)===34){s+=n.slice(a,o),a=o+1,o+=4;continue}if(l===10||l===13){s+=n.slice(a,o),c.push(s),l===13&&n.charCodeAt(o+1)===10?o+=2:++o,s="",a=o,i=o;continue}if(ro(l))++o;else if(Ic(n,o))o+=2;else throw gt(e.source,o,`Invalid character within String: ${qr(e,o)}.`)}throw gt(e.source,o,"Unterminated string.")}function T$(e,t){const n=e.source.body,r=n.length;let i=t+1;for(;i<r;){const o=n.charCodeAt(i);if(v$(o))++i;else break}return ot(e,L.NAME,t,i,n.slice(t,i))}const P$=10,Ey=2;function Sy(e){return Mc(e,[])}function Mc(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return A$(e,t);default:return String(e)}}function A$(e,t){if(e===null)return"null";if(t.includes(e))return"[Circular]";const n=[...t,e];if(I$(e)){const r=e.toJSON();if(r!==e)return typeof r=="string"?r:Mc(r,n)}else if(Array.isArray(e))return D$(e,n);return M$(e,n)}function I$(e){return typeof e.toJSON=="function"}function M$(e,t){const n=Object.entries(e);return n.length===0?"{}":t.length>Ey?"["+L$(e)+"]":"{ "+n.map(([i,o])=>i+": "+Mc(o,t)).join(", ")+" }"}function D$(e,t){if(e.length===0)return"[]";if(t.length>Ey)return"[Array]";const n=Math.min(P$,e.length),r=e.length-n,i=[];for(let o=0;o<n;++o)i.push(Mc(e[o],t));return r===1?i.push("... 1 more item"):r>1&&i.push(`... ${r} more items`),"["+i.join(", ")+"]"}function L$(e){const t=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if(t==="Object"&&typeof e.constructor=="function"){const n=e.constructor.name;if(typeof n=="string"&&n!=="")return n}return t}const R$=function(t,n){return t instanceof n};class Ch{constructor(t,n="GraphQL request",r={line:1,column:1}){typeof t=="string"||cs(!1,`Body must be a string. Received: ${Sy(t)}.`),this.body=t,this.name=n,this.locationOffset=r,this.locationOffset.line>0||cs(!1,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||cs(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}}function F$(e){return R$(e,Ch)}function z$(e,t){return new j$(e,t).parseDocument()}class j${constructor(t,n={}){const r=F$(t)?t:new Ch(t);this._lexer=new $$(r),this._options=n,this._tokenCounter=0}parseName(){const t=this.expectToken(L.NAME);return this.node(t,{kind:X.NAME,value:t.value})}parseDocument(){return this.node(this._lexer.token,{kind:X.DOCUMENT,definitions:this.many(L.SOF,this.parseDefinition,L.EOF)})}parseDefinition(){if(this.peek(L.BRACE_L))return this.parseOperationDefinition();const t=this.peekDescription(),n=t?this._lexer.lookahead():this._lexer.token;if(n.kind===L.NAME){switch(n.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}if(t)throw gt(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are supported only on type definitions.");switch(n.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(n)}parseOperationDefinition(){const t=this._lexer.token;if(this.peek(L.BRACE_L))return this.node(t,{kind:X.OPERATION_DEFINITION,operation:$i.QUERY,name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet()});const n=this.parseOperationType();let r;return this.peek(L.NAME)&&(r=this.parseName()),this.node(t,{kind:X.OPERATION_DEFINITION,operation:n,name:r,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){const t=this.expectToken(L.NAME);switch(t.value){case"query":return $i.QUERY;case"mutation":return $i.MUTATION;case"subscription":return $i.SUBSCRIPTION}throw this.unexpected(t)}parseVariableDefinitions(){return this.optionalMany(L.PAREN_L,this.parseVariableDefinition,L.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:X.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(L.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(L.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){const t=this._lexer.token;return this.expectToken(L.DOLLAR),this.node(t,{kind:X.VARIABLE,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:X.SELECTION_SET,selections:this.many(L.BRACE_L,this.parseSelection,L.BRACE_R)})}parseSelection(){return this.peek(L.SPREAD)?this.parseFragment():this.parseField()}parseField(){const t=this._lexer.token,n=this.parseName();let r,i;return this.expectOptionalToken(L.COLON)?(r=n,i=this.parseName()):i=n,this.node(t,{kind:X.FIELD,alias:r,name:i,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(L.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(t){const n=t?this.parseConstArgument:this.parseArgument;return this.optionalMany(L.PAREN_L,n,L.PAREN_R)}parseArgument(t=!1){const n=this._lexer.token,r=this.parseName();return this.expectToken(L.COLON),this.node(n,{kind:X.ARGUMENT,name:r,value:this.parseValueLiteral(t)})}parseConstArgument(){return this.parseArgument(!0)}parseFragment(){const t=this._lexer.token;this.expectToken(L.SPREAD);const n=this.expectOptionalKeyword("on");return!n&&this.peek(L.NAME)?this.node(t,{kind:X.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1)}):this.node(t,{kind:X.INLINE_FRAGMENT,typeCondition:n?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){const t=this._lexer.token;return this.expectKeyword("fragment"),this._options.allowLegacyFragmentVariables===!0?this.node(t,{kind:X.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()}):this.node(t,{kind:X.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()}parseValueLiteral(t){const n=this._lexer.token;switch(n.kind){case L.BRACKET_L:return this.parseList(t);case L.BRACE_L:return this.parseObject(t);case L.INT:return this.advanceLexer(),this.node(n,{kind:X.INT,value:n.value});case L.FLOAT:return this.advanceLexer(),this.node(n,{kind:X.FLOAT,value:n.value});case L.STRING:case L.BLOCK_STRING:return this.parseStringLiteral();case L.NAME:switch(this.advanceLexer(),n.value){case"true":return this.node(n,{kind:X.BOOLEAN,value:!0});case"false":return this.node(n,{kind:X.BOOLEAN,value:!1});case"null":return this.node(n,{kind:X.NULL});default:return this.node(n,{kind:X.ENUM,value:n.value})}case L.DOLLAR:if(t)if(this.expectToken(L.DOLLAR),this._lexer.token.kind===L.NAME){const r=this._lexer.token.value;throw gt(this._lexer.source,n.start,`Unexpected variable "$${r}" in constant value.`)}else throw this.unexpected(n);return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){const t=this._lexer.token;return this.advanceLexer(),this.node(t,{kind:X.STRING,value:t.value,block:t.kind===L.BLOCK_STRING})}parseList(t){const n=()=>this.parseValueLiteral(t);return this.node(this._lexer.token,{kind:X.LIST,values:this.any(L.BRACKET_L,n,L.BRACKET_R)})}parseObject(t){const n=()=>this.parseObjectField(t);return this.node(this._lexer.token,{kind:X.OBJECT,fields:this.any(L.BRACE_L,n,L.BRACE_R)})}parseObjectField(t){const n=this._lexer.token,r=this.parseName();return this.expectToken(L.COLON),this.node(n,{kind:X.OBJECT_FIELD,name:r,value:this.parseValueLiteral(t)})}parseDirectives(t){const n=[];for(;this.peek(L.AT);)n.push(this.parseDirective(t));return n}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(t){const n=this._lexer.token;return this.expectToken(L.AT),this.node(n,{kind:X.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(t)})}parseTypeReference(){const t=this._lexer.token;let n;if(this.expectOptionalToken(L.BRACKET_L)){const r=this.parseTypeReference();this.expectToken(L.BRACKET_R),n=this.node(t,{kind:X.LIST_TYPE,type:r})}else n=this.parseNamedType();return this.expectOptionalToken(L.BANG)?this.node(t,{kind:X.NON_NULL_TYPE,type:n}):n}parseNamedType(){return this.node(this._lexer.token,{kind:X.NAMED_TYPE,name:this.parseName()})}peekDescription(){return this.peek(L.STRING)||this.peek(L.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("schema");const r=this.parseConstDirectives(),i=this.many(L.BRACE_L,this.parseOperationTypeDefinition,L.BRACE_R);return this.node(t,{kind:X.SCHEMA_DEFINITION,description:n,directives:r,operationTypes:i})}parseOperationTypeDefinition(){const t=this._lexer.token,n=this.parseOperationType();this.expectToken(L.COLON);const r=this.parseNamedType();return this.node(t,{kind:X.OPERATION_TYPE_DEFINITION,operation:n,type:r})}parseScalarTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("scalar");const r=this.parseName(),i=this.parseConstDirectives();return this.node(t,{kind:X.SCALAR_TYPE_DEFINITION,description:n,name:r,directives:i})}parseObjectTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("type");const r=this.parseName(),i=this.parseImplementsInterfaces(),o=this.parseConstDirectives(),a=this.parseFieldsDefinition();return this.node(t,{kind:X.OBJECT_TYPE_DEFINITION,description:n,name:r,interfaces:i,directives:o,fields:a})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(L.AMP,this.parseNamedType):[]}parseFieldsDefinition(){return this.optionalMany(L.BRACE_L,this.parseFieldDefinition,L.BRACE_R)}parseFieldDefinition(){const t=this._lexer.token,n=this.parseDescription(),r=this.parseName(),i=this.parseArgumentDefs();this.expectToken(L.COLON);const o=this.parseTypeReference(),a=this.parseConstDirectives();return this.node(t,{kind:X.FIELD_DEFINITION,description:n,name:r,arguments:i,type:o,directives:a})}parseArgumentDefs(){return this.optionalMany(L.PAREN_L,this.parseInputValueDef,L.PAREN_R)}parseInputValueDef(){const t=this._lexer.token,n=this.parseDescription(),r=this.parseName();this.expectToken(L.COLON);const i=this.parseTypeReference();let o;this.expectOptionalToken(L.EQUALS)&&(o=this.parseConstValueLiteral());const a=this.parseConstDirectives();return this.node(t,{kind:X.INPUT_VALUE_DEFINITION,description:n,name:r,type:i,defaultValue:o,directives:a})}parseInterfaceTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("interface");const r=this.parseName(),i=this.parseImplementsInterfaces(),o=this.parseConstDirectives(),a=this.parseFieldsDefinition();return this.node(t,{kind:X.INTERFACE_TYPE_DEFINITION,description:n,name:r,interfaces:i,directives:o,fields:a})}parseUnionTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("union");const r=this.parseName(),i=this.parseConstDirectives(),o=this.parseUnionMemberTypes();return this.node(t,{kind:X.UNION_TYPE_DEFINITION,description:n,name:r,directives:i,types:o})}parseUnionMemberTypes(){return this.expectOptionalToken(L.EQUALS)?this.delimitedMany(L.PIPE,this.parseNamedType):[]}parseEnumTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("enum");const r=this.parseName(),i=this.parseConstDirectives(),o=this.parseEnumValuesDefinition();return this.node(t,{kind:X.ENUM_TYPE_DEFINITION,description:n,name:r,directives:i,values:o})}parseEnumValuesDefinition(){return this.optionalMany(L.BRACE_L,this.parseEnumValueDefinition,L.BRACE_R)}parseEnumValueDefinition(){const t=this._lexer.token,n=this.parseDescription(),r=this.parseEnumValueName(),i=this.parseConstDirectives();return this.node(t,{kind:X.ENUM_VALUE_DEFINITION,description:n,name:r,directives:i})}parseEnumValueName(){if(this._lexer.token.value==="true"||this._lexer.token.value==="false"||this._lexer.token.value==="null")throw gt(this._lexer.source,this._lexer.token.start,`${Fa(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("input");const r=this.parseName(),i=this.parseConstDirectives(),o=this.parseInputFieldsDefinition();return this.node(t,{kind:X.INPUT_OBJECT_TYPE_DEFINITION,description:n,name:r,directives:i,fields:o})}parseInputFieldsDefinition(){return this.optionalMany(L.BRACE_L,this.parseInputValueDef,L.BRACE_R)}parseTypeSystemExtension(){const t=this._lexer.lookahead();if(t.kind===L.NAME)switch(t.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(t)}parseSchemaExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");const n=this.parseConstDirectives(),r=this.optionalMany(L.BRACE_L,this.parseOperationTypeDefinition,L.BRACE_R);if(n.length===0&&r.length===0)throw this.unexpected();return this.node(t,{kind:X.SCHEMA_EXTENSION,directives:n,operationTypes:r})}parseScalarTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");const n=this.parseName(),r=this.parseConstDirectives();if(r.length===0)throw this.unexpected();return this.node(t,{kind:X.SCALAR_TYPE_EXTENSION,name:n,directives:r})}parseObjectTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");const n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),o=this.parseFieldsDefinition();if(r.length===0&&i.length===0&&o.length===0)throw this.unexpected();return this.node(t,{kind:X.OBJECT_TYPE_EXTENSION,name:n,interfaces:r,directives:i,fields:o})}parseInterfaceTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");const n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),o=this.parseFieldsDefinition();if(r.length===0&&i.length===0&&o.length===0)throw this.unexpected();return this.node(t,{kind:X.INTERFACE_TYPE_EXTENSION,name:n,interfaces:r,directives:i,fields:o})}parseUnionTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");const n=this.parseName(),r=this.parseConstDirectives(),i=this.parseUnionMemberTypes();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:X.UNION_TYPE_EXTENSION,name:n,directives:r,types:i})}parseEnumTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");const n=this.parseName(),r=this.parseConstDirectives(),i=this.parseEnumValuesDefinition();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:X.ENUM_TYPE_EXTENSION,name:n,directives:r,values:i})}parseInputObjectTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");const n=this.parseName(),r=this.parseConstDirectives(),i=this.parseInputFieldsDefinition();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:X.INPUT_OBJECT_TYPE_EXTENSION,name:n,directives:r,fields:i})}parseDirectiveDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("directive"),this.expectToken(L.AT);const r=this.parseName(),i=this.parseArgumentDefs(),o=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");const a=this.parseDirectiveLocations();return this.node(t,{kind:X.DIRECTIVE_DEFINITION,description:n,name:r,arguments:i,repeatable:o,locations:a})}parseDirectiveLocations(){return this.delimitedMany(L.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){const t=this._lexer.token,n=this.parseName();if(Object.prototype.hasOwnProperty.call(Kd,n.value))return n;throw this.unexpected(t)}node(t,n){return this._options.noLocation!==!0&&(n.loc=new p$(t,this._lexer.lastToken,this._lexer.source)),n}peek(t){return this._lexer.token.kind===t}expectToken(t){const n=this._lexer.token;if(n.kind===t)return this.advanceLexer(),n;throw gt(this._lexer.source,n.start,`Expected ${Oy(t)}, found ${Fa(n)}.`)}expectOptionalToken(t){return this._lexer.token.kind===t?(this.advanceLexer(),!0):!1}expectKeyword(t){const n=this._lexer.token;if(n.kind===L.NAME&&n.value===t)this.advanceLexer();else throw gt(this._lexer.source,n.start,`Expected "${t}", found ${Fa(n)}.`)}expectOptionalKeyword(t){const n=this._lexer.token;return n.kind===L.NAME&&n.value===t?(this.advanceLexer(),!0):!1}unexpected(t){const n=t??this._lexer.token;return gt(this._lexer.source,n.start,`Unexpected ${Fa(n)}.`)}any(t,n,r){this.expectToken(t);const i=[];for(;!this.expectOptionalToken(r);)i.push(n.call(this));return i}optionalMany(t,n,r){if(this.expectOptionalToken(t)){const i=[];do i.push(n.call(this));while(!this.expectOptionalToken(r));return i}return[]}many(t,n,r){this.expectToken(t);const i=[];do i.push(n.call(this));while(!this.expectOptionalToken(r));return i}delimitedMany(t,n){this.expectOptionalToken(t);const r=[];do r.push(n.call(this));while(this.expectOptionalToken(t));return r}advanceLexer(){const{maxTokens:t}=this._options,n=this._lexer.advance();if(t!==void 0&&n.kind!==L.EOF&&(++this._tokenCounter,this._tokenCounter>t))throw gt(this._lexer.source,n.start,`Document contains more that ${t} tokens. Parsing aborted.`)}}function Fa(e){const t=e.value;return Oy(e.kind)+(t!=null?` "${t}"`:"")}function Oy(e){return w$(e)?`"${e}"`:e}function V$(e){return`"${e.replace(U$,B$)}"`}const U$=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function B$(e){return H$[e.charCodeAt(0)]}const H$=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","",'\\"',"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"],Nh=Object.freeze({});function Wn(e,t,n=$y){const r=new Map;for(const b of Object.values(X))r.set(b,q$(t,b));let i,o=Array.isArray(e),a=[e],s=-1,c=[],l=e,u,d;const f=[],h=[];do{s++;const b=s===a.length,y=b&&c.length!==0;if(b){if(u=h.length===0?void 0:f[f.length-1],l=d,d=h.pop(),y)if(o){l=l.slice();let _=0;for(const[x,O]of c){const C=x-_;O===null?(l.splice(C,1),_++):l[C]=O}}else{l=Object.defineProperties({},Object.getOwnPropertyDescriptors(l));for(const[_,x]of c)l[_]=x}s=i.index,a=i.keys,c=i.edits,o=i.inArray,i=i.prev}else if(d){if(u=o?s:a[s],l=d[u],l==null)continue;f.push(u)}let g;if(!Array.isArray(l)){var p,m;Qp(l)||cs(!1,`Invalid AST Node: ${Sy(l)}.`);const _=b?(p=r.get(l.kind))===null||p===void 0?void 0:p.leave:(m=r.get(l.kind))===null||m===void 0?void 0:m.enter;if(g=_?.call(t,l,u,d,f,h),g===Nh)break;if(g===!1){if(!b){f.pop();continue}}else if(g!==void 0&&(c.push([u,g]),!b))if(Qp(g))l=g;else{f.pop();continue}}if(g===void 0&&y&&c.push([u,l]),b)f.pop();else{var v;i={inArray:o,index:s,keys:a,edits:c,prev:i},o=Array.isArray(l),a=o?l:(v=n[l.kind])!==null&&v!==void 0?v:[],s=-1,c=[],d&&h.push(d),d=l}}while(i!==void 0);return c.length!==0?c[c.length-1][1]:e}function q$(e,t){const n=e[t];return typeof n=="object"?n:typeof n=="function"?{enter:n,leave:void 0}:{enter:e.enter,leave:e.leave}}function W$(e){return Wn(e,K$)}const G$=80,K$={Name:{leave:e=>e.value},Variable:{leave:e=>"$"+e.name},Document:{leave:e=>Z(e.definitions,`
|
|
14
|
+
`));return e.line+=c.length-1,e.lineStart=i,u}if(l===92&&n.charCodeAt(o+1)===34&&n.charCodeAt(o+2)===34&&n.charCodeAt(o+3)===34){s+=n.slice(a,o),a=o+1,o+=4;continue}if(l===10||l===13){s+=n.slice(a,o),c.push(s),l===13&&n.charCodeAt(o+1)===10?o+=2:++o,s="",a=o,i=o;continue}if(ro(l))++o;else if(Ic(n,o))o+=2;else throw gt(e.source,o,`Invalid character within String: ${qr(e,o)}.`)}throw gt(e.source,o,"Unterminated string.")}function T$(e,t){const n=e.source.body,r=n.length;let i=t+1;for(;i<r;){const o=n.charCodeAt(i);if(v$(o))++i;else break}return ot(e,L.NAME,t,i,n.slice(t,i))}const P$=10,Ey=2;function Sy(e){return Mc(e,[])}function Mc(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return A$(e,t);default:return String(e)}}function A$(e,t){if(e===null)return"null";if(t.includes(e))return"[Circular]";const n=[...t,e];if(I$(e)){const r=e.toJSON();if(r!==e)return typeof r=="string"?r:Mc(r,n)}else if(Array.isArray(e))return D$(e,n);return M$(e,n)}function I$(e){return typeof e.toJSON=="function"}function M$(e,t){const n=Object.entries(e);return n.length===0?"{}":t.length>Ey?"["+L$(e)+"]":"{ "+n.map(([i,o])=>i+": "+Mc(o,t)).join(", ")+" }"}function D$(e,t){if(e.length===0)return"[]";if(t.length>Ey)return"[Array]";const n=Math.min(P$,e.length),r=e.length-n,i=[];for(let o=0;o<n;++o)i.push(Mc(e[o],t));return r===1?i.push("... 1 more item"):r>1&&i.push(`... ${r} more items`),"["+i.join(", ")+"]"}function L$(e){const t=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if(t==="Object"&&typeof e.constructor=="function"){const n=e.constructor.name;if(typeof n=="string"&&n!=="")return n}return t}const R$=function(t,n){return t instanceof n};class Ch{constructor(t,n="GraphQL request",r={line:1,column:1}){typeof t=="string"||cs(!1,`Body must be a string. Received: ${Sy(t)}.`),this.body=t,this.name=n,this.locationOffset=r,this.locationOffset.line>0||cs(!1,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||cs(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}}function F$(e){return R$(e,Ch)}function z$(e,t){return new j$(e,t).parseDocument()}class j${constructor(t,n={}){const r=F$(t)?t:new Ch(t);this._lexer=new $$(r),this._options=n,this._tokenCounter=0}parseName(){const t=this.expectToken(L.NAME);return this.node(t,{kind:X.NAME,value:t.value})}parseDocument(){return this.node(this._lexer.token,{kind:X.DOCUMENT,definitions:this.many(L.SOF,this.parseDefinition,L.EOF)})}parseDefinition(){if(this.peek(L.BRACE_L))return this.parseOperationDefinition();const t=this.peekDescription(),n=t?this._lexer.lookahead():this._lexer.token;if(n.kind===L.NAME){switch(n.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}if(t)throw gt(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are supported only on type definitions.");switch(n.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(n)}parseOperationDefinition(){const t=this._lexer.token;if(this.peek(L.BRACE_L))return this.node(t,{kind:X.OPERATION_DEFINITION,operation:$i.QUERY,name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet()});const n=this.parseOperationType();let r;return this.peek(L.NAME)&&(r=this.parseName()),this.node(t,{kind:X.OPERATION_DEFINITION,operation:n,name:r,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){const t=this.expectToken(L.NAME);switch(t.value){case"query":return $i.QUERY;case"mutation":return $i.MUTATION;case"subscription":return $i.SUBSCRIPTION}throw this.unexpected(t)}parseVariableDefinitions(){return this.optionalMany(L.PAREN_L,this.parseVariableDefinition,L.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:X.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(L.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(L.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){const t=this._lexer.token;return this.expectToken(L.DOLLAR),this.node(t,{kind:X.VARIABLE,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:X.SELECTION_SET,selections:this.many(L.BRACE_L,this.parseSelection,L.BRACE_R)})}parseSelection(){return this.peek(L.SPREAD)?this.parseFragment():this.parseField()}parseField(){const t=this._lexer.token,n=this.parseName();let r,i;return this.expectOptionalToken(L.COLON)?(r=n,i=this.parseName()):i=n,this.node(t,{kind:X.FIELD,alias:r,name:i,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(L.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(t){const n=t?this.parseConstArgument:this.parseArgument;return this.optionalMany(L.PAREN_L,n,L.PAREN_R)}parseArgument(t=!1){const n=this._lexer.token,r=this.parseName();return this.expectToken(L.COLON),this.node(n,{kind:X.ARGUMENT,name:r,value:this.parseValueLiteral(t)})}parseConstArgument(){return this.parseArgument(!0)}parseFragment(){const t=this._lexer.token;this.expectToken(L.SPREAD);const n=this.expectOptionalKeyword("on");return!n&&this.peek(L.NAME)?this.node(t,{kind:X.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1)}):this.node(t,{kind:X.INLINE_FRAGMENT,typeCondition:n?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){const t=this._lexer.token;return this.expectKeyword("fragment"),this._options.allowLegacyFragmentVariables===!0?this.node(t,{kind:X.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()}):this.node(t,{kind:X.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()}parseValueLiteral(t){const n=this._lexer.token;switch(n.kind){case L.BRACKET_L:return this.parseList(t);case L.BRACE_L:return this.parseObject(t);case L.INT:return this.advanceLexer(),this.node(n,{kind:X.INT,value:n.value});case L.FLOAT:return this.advanceLexer(),this.node(n,{kind:X.FLOAT,value:n.value});case L.STRING:case L.BLOCK_STRING:return this.parseStringLiteral();case L.NAME:switch(this.advanceLexer(),n.value){case"true":return this.node(n,{kind:X.BOOLEAN,value:!0});case"false":return this.node(n,{kind:X.BOOLEAN,value:!1});case"null":return this.node(n,{kind:X.NULL});default:return this.node(n,{kind:X.ENUM,value:n.value})}case L.DOLLAR:if(t)if(this.expectToken(L.DOLLAR),this._lexer.token.kind===L.NAME){const r=this._lexer.token.value;throw gt(this._lexer.source,n.start,`Unexpected variable "$${r}" in constant value.`)}else throw this.unexpected(n);return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){const t=this._lexer.token;return this.advanceLexer(),this.node(t,{kind:X.STRING,value:t.value,block:t.kind===L.BLOCK_STRING})}parseList(t){const n=()=>this.parseValueLiteral(t);return this.node(this._lexer.token,{kind:X.LIST,values:this.any(L.BRACKET_L,n,L.BRACKET_R)})}parseObject(t){const n=()=>this.parseObjectField(t);return this.node(this._lexer.token,{kind:X.OBJECT,fields:this.any(L.BRACE_L,n,L.BRACE_R)})}parseObjectField(t){const n=this._lexer.token,r=this.parseName();return this.expectToken(L.COLON),this.node(n,{kind:X.OBJECT_FIELD,name:r,value:this.parseValueLiteral(t)})}parseDirectives(t){const n=[];for(;this.peek(L.AT);)n.push(this.parseDirective(t));return n}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(t){const n=this._lexer.token;return this.expectToken(L.AT),this.node(n,{kind:X.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(t)})}parseTypeReference(){const t=this._lexer.token;let n;if(this.expectOptionalToken(L.BRACKET_L)){const r=this.parseTypeReference();this.expectToken(L.BRACKET_R),n=this.node(t,{kind:X.LIST_TYPE,type:r})}else n=this.parseNamedType();return this.expectOptionalToken(L.BANG)?this.node(t,{kind:X.NON_NULL_TYPE,type:n}):n}parseNamedType(){return this.node(this._lexer.token,{kind:X.NAMED_TYPE,name:this.parseName()})}peekDescription(){return this.peek(L.STRING)||this.peek(L.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("schema");const r=this.parseConstDirectives(),i=this.many(L.BRACE_L,this.parseOperationTypeDefinition,L.BRACE_R);return this.node(t,{kind:X.SCHEMA_DEFINITION,description:n,directives:r,operationTypes:i})}parseOperationTypeDefinition(){const t=this._lexer.token,n=this.parseOperationType();this.expectToken(L.COLON);const r=this.parseNamedType();return this.node(t,{kind:X.OPERATION_TYPE_DEFINITION,operation:n,type:r})}parseScalarTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("scalar");const r=this.parseName(),i=this.parseConstDirectives();return this.node(t,{kind:X.SCALAR_TYPE_DEFINITION,description:n,name:r,directives:i})}parseObjectTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("type");const r=this.parseName(),i=this.parseImplementsInterfaces(),o=this.parseConstDirectives(),a=this.parseFieldsDefinition();return this.node(t,{kind:X.OBJECT_TYPE_DEFINITION,description:n,name:r,interfaces:i,directives:o,fields:a})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(L.AMP,this.parseNamedType):[]}parseFieldsDefinition(){return this.optionalMany(L.BRACE_L,this.parseFieldDefinition,L.BRACE_R)}parseFieldDefinition(){const t=this._lexer.token,n=this.parseDescription(),r=this.parseName(),i=this.parseArgumentDefs();this.expectToken(L.COLON);const o=this.parseTypeReference(),a=this.parseConstDirectives();return this.node(t,{kind:X.FIELD_DEFINITION,description:n,name:r,arguments:i,type:o,directives:a})}parseArgumentDefs(){return this.optionalMany(L.PAREN_L,this.parseInputValueDef,L.PAREN_R)}parseInputValueDef(){const t=this._lexer.token,n=this.parseDescription(),r=this.parseName();this.expectToken(L.COLON);const i=this.parseTypeReference();let o;this.expectOptionalToken(L.EQUALS)&&(o=this.parseConstValueLiteral());const a=this.parseConstDirectives();return this.node(t,{kind:X.INPUT_VALUE_DEFINITION,description:n,name:r,type:i,defaultValue:o,directives:a})}parseInterfaceTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("interface");const r=this.parseName(),i=this.parseImplementsInterfaces(),o=this.parseConstDirectives(),a=this.parseFieldsDefinition();return this.node(t,{kind:X.INTERFACE_TYPE_DEFINITION,description:n,name:r,interfaces:i,directives:o,fields:a})}parseUnionTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("union");const r=this.parseName(),i=this.parseConstDirectives(),o=this.parseUnionMemberTypes();return this.node(t,{kind:X.UNION_TYPE_DEFINITION,description:n,name:r,directives:i,types:o})}parseUnionMemberTypes(){return this.expectOptionalToken(L.EQUALS)?this.delimitedMany(L.PIPE,this.parseNamedType):[]}parseEnumTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("enum");const r=this.parseName(),i=this.parseConstDirectives(),o=this.parseEnumValuesDefinition();return this.node(t,{kind:X.ENUM_TYPE_DEFINITION,description:n,name:r,directives:i,values:o})}parseEnumValuesDefinition(){return this.optionalMany(L.BRACE_L,this.parseEnumValueDefinition,L.BRACE_R)}parseEnumValueDefinition(){const t=this._lexer.token,n=this.parseDescription(),r=this.parseEnumValueName(),i=this.parseConstDirectives();return this.node(t,{kind:X.ENUM_VALUE_DEFINITION,description:n,name:r,directives:i})}parseEnumValueName(){if(this._lexer.token.value==="true"||this._lexer.token.value==="false"||this._lexer.token.value==="null")throw gt(this._lexer.source,this._lexer.token.start,`${Fa(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("input");const r=this.parseName(),i=this.parseConstDirectives(),o=this.parseInputFieldsDefinition();return this.node(t,{kind:X.INPUT_OBJECT_TYPE_DEFINITION,description:n,name:r,directives:i,fields:o})}parseInputFieldsDefinition(){return this.optionalMany(L.BRACE_L,this.parseInputValueDef,L.BRACE_R)}parseTypeSystemExtension(){const t=this._lexer.lookahead();if(t.kind===L.NAME)switch(t.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(t)}parseSchemaExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");const n=this.parseConstDirectives(),r=this.optionalMany(L.BRACE_L,this.parseOperationTypeDefinition,L.BRACE_R);if(n.length===0&&r.length===0)throw this.unexpected();return this.node(t,{kind:X.SCHEMA_EXTENSION,directives:n,operationTypes:r})}parseScalarTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");const n=this.parseName(),r=this.parseConstDirectives();if(r.length===0)throw this.unexpected();return this.node(t,{kind:X.SCALAR_TYPE_EXTENSION,name:n,directives:r})}parseObjectTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");const n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),o=this.parseFieldsDefinition();if(r.length===0&&i.length===0&&o.length===0)throw this.unexpected();return this.node(t,{kind:X.OBJECT_TYPE_EXTENSION,name:n,interfaces:r,directives:i,fields:o})}parseInterfaceTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");const n=this.parseName(),r=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),o=this.parseFieldsDefinition();if(r.length===0&&i.length===0&&o.length===0)throw this.unexpected();return this.node(t,{kind:X.INTERFACE_TYPE_EXTENSION,name:n,interfaces:r,directives:i,fields:o})}parseUnionTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");const n=this.parseName(),r=this.parseConstDirectives(),i=this.parseUnionMemberTypes();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:X.UNION_TYPE_EXTENSION,name:n,directives:r,types:i})}parseEnumTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");const n=this.parseName(),r=this.parseConstDirectives(),i=this.parseEnumValuesDefinition();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:X.ENUM_TYPE_EXTENSION,name:n,directives:r,values:i})}parseInputObjectTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");const n=this.parseName(),r=this.parseConstDirectives(),i=this.parseInputFieldsDefinition();if(r.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:X.INPUT_OBJECT_TYPE_EXTENSION,name:n,directives:r,fields:i})}parseDirectiveDefinition(){const t=this._lexer.token,n=this.parseDescription();this.expectKeyword("directive"),this.expectToken(L.AT);const r=this.parseName(),i=this.parseArgumentDefs(),o=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");const a=this.parseDirectiveLocations();return this.node(t,{kind:X.DIRECTIVE_DEFINITION,description:n,name:r,arguments:i,repeatable:o,locations:a})}parseDirectiveLocations(){return this.delimitedMany(L.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){const t=this._lexer.token,n=this.parseName();if(Object.prototype.hasOwnProperty.call(Kd,n.value))return n;throw this.unexpected(t)}node(t,n){return this._options.noLocation!==!0&&(n.loc=new p$(t,this._lexer.lastToken,this._lexer.source)),n}peek(t){return this._lexer.token.kind===t}expectToken(t){const n=this._lexer.token;if(n.kind===t)return this.advanceLexer(),n;throw gt(this._lexer.source,n.start,`Expected ${Oy(t)}, found ${Fa(n)}.`)}expectOptionalToken(t){return this._lexer.token.kind===t?(this.advanceLexer(),!0):!1}expectKeyword(t){const n=this._lexer.token;if(n.kind===L.NAME&&n.value===t)this.advanceLexer();else throw gt(this._lexer.source,n.start,`Expected "${t}", found ${Fa(n)}.`)}expectOptionalKeyword(t){const n=this._lexer.token;return n.kind===L.NAME&&n.value===t?(this.advanceLexer(),!0):!1}unexpected(t){const n=t??this._lexer.token;return gt(this._lexer.source,n.start,`Unexpected ${Fa(n)}.`)}any(t,n,r){this.expectToken(t);const i=[];for(;!this.expectOptionalToken(r);)i.push(n.call(this));return i}optionalMany(t,n,r){if(this.expectOptionalToken(t)){const i=[];do i.push(n.call(this));while(!this.expectOptionalToken(r));return i}return[]}many(t,n,r){this.expectToken(t);const i=[];do i.push(n.call(this));while(!this.expectOptionalToken(r));return i}delimitedMany(t,n){this.expectOptionalToken(t);const r=[];do r.push(n.call(this));while(this.expectOptionalToken(t));return r}advanceLexer(){const{maxTokens:t}=this._options,n=this._lexer.advance();if(t!==void 0&&n.kind!==L.EOF&&(++this._tokenCounter,this._tokenCounter>t))throw gt(this._lexer.source,n.start,`Document contains more that ${t} tokens. Parsing aborted.`)}}function Fa(e){const t=e.value;return Oy(e.kind)+(t!=null?` "${t}"`:"")}function Oy(e){return w$(e)?`"${e}"`:e}function V$(e){return`"${e.replace(U$,B$)}"`}const U$=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function B$(e){return H$[e.charCodeAt(0)]}const H$=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","",'\\"',"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"],Nh=Object.freeze({});function Wn(e,t,n=$y){const r=new Map;for(const b of Object.values(X))r.set(b,q$(t,b));let i,o=Array.isArray(e),a=[e],s=-1,c=[],l=e,u,d;const f=[],h=[];do{s++;const b=s===a.length,y=b&&c.length!==0;if(b){if(u=h.length===0?void 0:f[f.length-1],l=d,d=h.pop(),y)if(o){l=l.slice();let _=0;for(const[k,O]of c){const C=k-_;O===null?(l.splice(C,1),_++):l[C]=O}}else{l=Object.defineProperties({},Object.getOwnPropertyDescriptors(l));for(const[_,k]of c)l[_]=k}s=i.index,a=i.keys,c=i.edits,o=i.inArray,i=i.prev}else if(d){if(u=o?s:a[s],l=d[u],l==null)continue;f.push(u)}let g;if(!Array.isArray(l)){var p,m;Qp(l)||cs(!1,`Invalid AST Node: ${Sy(l)}.`);const _=b?(p=r.get(l.kind))===null||p===void 0?void 0:p.leave:(m=r.get(l.kind))===null||m===void 0?void 0:m.enter;if(g=_?.call(t,l,u,d,f,h),g===Nh)break;if(g===!1){if(!b){f.pop();continue}}else if(g!==void 0&&(c.push([u,g]),!b))if(Qp(g))l=g;else{f.pop();continue}}if(g===void 0&&y&&c.push([u,l]),b)f.pop();else{var v;i={inArray:o,index:s,keys:a,edits:c,prev:i},o=Array.isArray(l),a=o?l:(v=n[l.kind])!==null&&v!==void 0?v:[],s=-1,c=[],d&&h.push(d),d=l}}while(i!==void 0);return c.length!==0?c[c.length-1][1]:e}function q$(e,t){const n=e[t];return typeof n=="object"?n:typeof n=="function"?{enter:n,leave:void 0}:{enter:e.enter,leave:e.leave}}function W$(e){return Wn(e,K$)}const G$=80,K$={Name:{leave:e=>e.value},Variable:{leave:e=>"$"+e.name},Document:{leave:e=>Z(e.definitions,`
|
|
15
15
|
|
|
16
16
|
`)},OperationDefinition:{leave(e){const t=we("(",Z(e.variableDefinitions,", "),")"),n=Z([e.operation,Z([e.name,t]),Z(e.directives," ")]," ");return(n==="query"?"":n+" ")+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:n,directives:r})=>e+": "+t+we(" = ",n)+we(" ",Z(r," "))},SelectionSet:{leave:({selections:e})=>sn(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){const o=we("",e,": ")+t;let a=o+we("(",Z(n,", "),")");return a.length>G$&&(a=o+we(`(
|
|
17
17
|
`,us(Z(n,`
|
|
@@ -38,12 +38,12 @@
|
|
|
38
38
|
`)),`
|
|
39
39
|
}`)}function we(e,t,n=""){return t!=null&&t!==""?e+t+n:""}function us(e){return we(" ",e.replace(/\n/g,`
|
|
40
40
|
`))}function Xp(e){var t;return(t=e?.some(n=>n.includes(`
|
|
41
|
-
`)))!==null&&t!==void 0?t:!1}function Zp(e){return e.kind===X.FIELD||e.kind===X.FRAGMENT_SPREAD||e.kind===X.INLINE_FRAGMENT}function Q$(){return Wp()}function Y$(){__DEV__?K(typeof Su=="boolean",Su):K(typeof Su=="boolean",39)}Q$();Y$();function Dc(e,t){var n=e.directives;return!n||!n.length?!0:J$(n).every(function(r){var i=r.directive,o=r.ifArgument,a=!1;return o.value.kind==="Variable"?(a=t&&t[o.value.name.value],__DEV__?K(a!==void 0,"Invalid variable referenced in @".concat(i.name.value," directive.")):K(a!==void 0,40)):a=o.value.value,i.name.value==="skip"?!a:a})}function Th(e,t,n){var r=new Set(e),i=r.size;return Wn(t,{Directive:function(o){if(r.delete(o.name.value)&&(!n||!r.size))return Nh}}),n?!r.size:r.size<i}function X$(e){return e&&Th(["client","export"],e,!0)}function Z$(e){var t=e.name.value;return t==="skip"||t==="include"}function J$(e){var t=[];return e&&e.length&&e.forEach(function(n){if(!!Z$(n)){var r=n.arguments,i=n.name.value;__DEV__?K(r&&r.length===1,"Incorrect number of arguments for the @".concat(i," directive.")):K(r&&r.length===1,41);var o=r[0];__DEV__?K(o.name&&o.name.value==="if","Invalid argument for the @".concat(i," directive.")):K(o.name&&o.name.value==="if",42);var a=o.value;__DEV__?K(a&&(a.kind==="Variable"||a.kind==="BooleanValue"),"Argument for the @".concat(i," directive must be a variable or a boolean value.")):K(a&&(a.kind==="Variable"||a.kind==="BooleanValue"),43),t.push({directive:n,ifArgument:o})}}),t}function e9(e,t){var n=t,r=[];e.definitions.forEach(function(o){if(o.kind==="OperationDefinition")throw __DEV__?new Se("Found a ".concat(o.operation," operation").concat(o.name?" named '".concat(o.name.value,"'"):"",". ")+"No operations are allowed when using a fragment as a query. Only fragments are allowed."):new Se(44);o.kind==="FragmentDefinition"&&r.push(o)}),typeof n>"u"&&(__DEV__?K(r.length===1,"Found ".concat(r.length," fragments. `fragmentName` must be provided when there is not exactly 1 fragment.")):K(r.length===1,45),n=r[0].name.value);var i=N(N({},e),{definitions:dl([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:n}}]}}],e.definitions,!0)});return i}function Ph(e){e===void 0&&(e=[]);var t={};return e.forEach(function(n){t[n.name.value]=n}),t}function Ah(e,t){switch(e.kind){case"InlineFragment":return e;case"FragmentSpread":{var n=e.name.value;if(typeof t=="function")return t(n);var r=t&&t[n];return __DEV__?K(r,"No fragment named ".concat(n)):K(r,46),r||null}default:return null}}function Ye(e){return e!==null&&typeof e=="object"}function Si(e){return{__ref:String(e)}}function Pe(e){return Boolean(e&&typeof e=="object"&&typeof e.__ref=="string")}function t9(e){return Ye(e)&&e.kind==="Document"&&Array.isArray(e.definitions)}function n9(e){return e.kind==="StringValue"}function r9(e){return e.kind==="BooleanValue"}function i9(e){return e.kind==="IntValue"}function o9(e){return e.kind==="FloatValue"}function a9(e){return e.kind==="Variable"}function s9(e){return e.kind==="ObjectValue"}function l9(e){return e.kind==="ListValue"}function c9(e){return e.kind==="EnumValue"}function u9(e){return e.kind==="NullValue"}function Ri(e,t,n,r){if(i9(n)||o9(n))e[t.value]=Number(n.value);else if(r9(n)||n9(n))e[t.value]=n.value;else if(s9(n)){var i={};n.fields.map(function(a){return Ri(i,a.name,a.value,r)}),e[t.value]=i}else if(a9(n)){var o=(r||{})[n.name.value];e[t.value]=o}else if(l9(n))e[t.value]=n.values.map(function(a){var s={};return Ri(s,t,a,r),s[t.value]});else if(c9(n))e[t.value]=n.value;else if(u9(n))e[t.value]=null;else throw __DEV__?new Se('The inline argument "'.concat(t.value,'" of kind "').concat(n.kind,'"')+"is not supported. Use variables instead of inline arguments to overcome this limitation."):new Se(55)}function d9(e,t){var n=null;e.directives&&(n={},e.directives.forEach(function(i){n[i.name.value]={},i.arguments&&i.arguments.forEach(function(o){var a=o.name,s=o.value;return Ri(n[i.name.value],a,s,t)})}));var r=null;return e.arguments&&e.arguments.length&&(r={},e.arguments.forEach(function(i){var o=i.name,a=i.value;return Ri(r,o,a,t)})),Ih(e.name.value,r,n)}var f9=["connection","include","skip","client","rest","export"],Ih=Object.assign(function(e,t,n){if(t&&n&&n.connection&&n.connection.key)if(n.connection.filter&&n.connection.filter.length>0){var r=n.connection.filter?n.connection.filter:[];r.sort();var i={};return r.forEach(function(s){i[s]=t[s]}),"".concat(n.connection.key,"(").concat(bo(i),")")}else return n.connection.key;var o=e;if(t){var a=bo(t);o+="(".concat(a,")")}return n&&Object.keys(n).forEach(function(s){f9.indexOf(s)===-1&&(n[s]&&Object.keys(n[s]).length?o+="@".concat(s,"(").concat(bo(n[s]),")"):o+="@".concat(s))}),o},{setStringify:function(e){var t=bo;return bo=e,t}}),bo=function(t){return JSON.stringify(t,h9)};function h9(e,t){return Ye(t)&&!Array.isArray(t)&&(t=Object.keys(t).sort().reduce(function(n,r){return n[r]=t[r],n},{})),t}function Lc(e,t){if(e.arguments&&e.arguments.length){var n={};return e.arguments.forEach(function(r){var i=r.name,o=r.value;return Ri(n,i,o,t)}),n}return null}function Wr(e){return e.alias?e.alias.value:e.name.value}function Yd(e,t,n){if(typeof e.__typename=="string")return e.__typename;for(var r=0,i=t.selections;r<i.length;r++){var o=i[r];if(Gr(o)){if(o.name.value==="__typename")return e[Wr(o)]}else{var a=Yd(e,Ah(o,n).selectionSet,n);if(typeof a=="string")return a}}}function Gr(e){return e.kind==="Field"}function p9(e){return e.kind==="InlineFragment"}function Rc(e){__DEV__?K(e&&e.kind==="Document",'Expecting a parsed GraphQL document. Perhaps you need to wrap the query string in a "gql" tag? http://docs.apollostack.com/apollo-client/core.html#gql'):K(e&&e.kind==="Document",47);var t=e.definitions.filter(function(n){return n.kind!=="FragmentDefinition"}).map(function(n){if(n.kind!=="OperationDefinition")throw __DEV__?new Se('Schema type definitions not allowed in queries. Found: "'.concat(n.kind,'"')):new Se(48);return n});return __DEV__?K(t.length<=1,"Ambiguous GraphQL document: contains ".concat(t.length," operations")):K(t.length<=1,49),e}function $a(e){return Rc(e),e.definitions.filter(function(t){return t.kind==="OperationDefinition"})[0]}function Xd(e){return e.definitions.filter(function(t){return t.kind==="OperationDefinition"&&!!t.name}).map(function(t){return t.name.value})[0]||null}function Mh(e){return e.definitions.filter(function(t){return t.kind==="FragmentDefinition"})}function Cy(e){var t=$a(e);return __DEV__?K(t&&t.operation==="query","Must contain a query definition."):K(t&&t.operation==="query",50),t}function m9(e){__DEV__?K(e.kind==="Document",'Expecting a parsed GraphQL document. Perhaps you need to wrap the query string in a "gql" tag? http://docs.apollostack.com/apollo-client/core.html#gql'):K(e.kind==="Document",51),__DEV__?K(e.definitions.length<=1,"Fragment must have exactly one definition."):K(e.definitions.length<=1,52);var t=e.definitions[0];return __DEV__?K(t.kind==="FragmentDefinition","Must be a fragment definition."):K(t.kind==="FragmentDefinition",53),t}function Dh(e){Rc(e);for(var t,n=0,r=e.definitions;n<r.length;n++){var i=r[n];if(i.kind==="OperationDefinition"){var o=i.operation;if(o==="query"||o==="mutation"||o==="subscription")return i}i.kind==="FragmentDefinition"&&!t&&(t=i)}if(t)return t;throw __DEV__?new Se("Expected a parsed GraphQL query with a query, mutation, subscription, or a fragment."):new Se(54)}function Lh(e){var t=Object.create(null),n=e&&e.variableDefinitions;return n&&n.length&&n.forEach(function(r){r.defaultValue&&Ri(t,r.variable.name,r.defaultValue)}),t}var Xe=Array.isArray;function rn(e){return Array.isArray(e)&&e.length>0}var Jp={kind:X.FIELD,name:{kind:X.NAME,value:"__typename"}};function Ny(e,t){return!e||e.selectionSet.selections.every(function(n){return n.kind===X.FRAGMENT_SPREAD&&Ny(t[n.name.value],t)})}function v9(e){return Ny($a(e)||m9(e),Ph(Mh(e)))?null:e}function g9(e){var t=new Set,n=[];return e.forEach(function(r){r.name?t.add(r.name):r.test&&n.push(r.test)}),function(r){return t.has(r.name.value)||n.some(function(i){return i(r)})}}function e2(e){var t=new Map;return function(r){r===void 0&&(r=e);var i=t.get(r);return i||t.set(r,i={variables:new Set,fragmentSpreads:new Set}),i}}function Ty(e,t){for(var n=e2(""),r=e2(""),i=function(y){for(var g=0,_=void 0;g<y.length&&(_=y[g]);++g)if(!Xe(_)){if(_.kind===X.OPERATION_DEFINITION)return n(_.name&&_.name.value);if(_.kind===X.FRAGMENT_DEFINITION)return r(_.name.value)}return __DEV__&&K.error("Could not find operation or fragment"),null},o=0,a=t.definitions.length-1;a>=0;--a)t.definitions[a].kind===X.OPERATION_DEFINITION&&++o;var s=g9(e),c=e.some(function(y){return y.remove}),l=function(y){return c&&y&&y.some(s)},u=new Map,d=!1,f={enter:function(y){if(l(y.directives))return d=!0,null}},h=Wn(t,{Field:f,InlineFragment:f,VariableDefinition:{enter:function(){return!1}},Variable:{enter:function(y,g,_,x,O){var C=i(O);C&&C.variables.add(y.name.value)}},FragmentSpread:{enter:function(y,g,_,x,O){if(l(y.directives))return d=!0,null;var C=i(O);C&&C.fragmentSpreads.add(y.name.value)}},FragmentDefinition:{enter:function(y,g,_,x){u.set(JSON.stringify(x),y)},leave:function(y,g,_,x){var O=u.get(JSON.stringify(x));if(y===O)return y;if(o>0&&y.selectionSet.selections.every(function(C){return C.kind===X.FIELD&&C.name.value==="__typename"}))return r(y.name.value).removed=!0,d=!0,null}},Directive:{leave:function(y){if(s(y))return d=!0,null}}});if(!d)return t;var p=function(y){return y.transitiveVars||(y.transitiveVars=new Set(y.variables),y.removed||y.fragmentSpreads.forEach(function(g){p(r(g)).transitiveVars.forEach(function(_){y.transitiveVars.add(_)})})),y},m=new Set;h.definitions.forEach(function(y){y.kind===X.OPERATION_DEFINITION?p(n(y.name&&y.name.value)).fragmentSpreads.forEach(function(g){m.add(g)}):y.kind===X.FRAGMENT_DEFINITION&&o===0&&!r(y.name.value).removed&&m.add(y.name.value)}),m.forEach(function(y){p(r(y)).fragmentSpreads.forEach(function(g){m.add(g)})});var v=function(y){return!!(!m.has(y)||r(y).removed)},b={enter:function(y){if(v(y.name.value))return null}};return v9(Wn(h,{FragmentSpread:b,FragmentDefinition:b,OperationDefinition:{leave:function(y){if(y.variableDefinitions){var g=p(n(y.name&&y.name.value)).transitiveVars;if(g.size<y.variableDefinitions.length)return N(N({},y),{variableDefinitions:y.variableDefinitions.filter(function(_){return g.has(_.variable.name.value)})})}}}}))}var Rh=Object.assign(function(e){return Wn(e,{SelectionSet:{enter:function(t,n,r){if(!(r&&r.kind===X.OPERATION_DEFINITION)){var i=t.selections;if(!!i){var o=i.some(function(s){return Gr(s)&&(s.name.value==="__typename"||s.name.value.lastIndexOf("__",0)===0)});if(!o){var a=r;if(!(Gr(a)&&a.directives&&a.directives.some(function(s){return s.name.value==="export"})))return N(N({},t),{selections:dl(dl([],i,!0),[Jp],!1)})}}}}}})},{added:function(e){return e===Jp}}),y9={test:function(e){var t=e.name.value==="connection";return t&&(!e.arguments||!e.arguments.some(function(n){return n.name.value==="key"}))&&__DEV__&&K.warn("Removing an @connection directive even though it does not have a key. You may want to use the key parameter to specify a store key."),t}};function b9(e){return Ty([y9],Rc(e))}function $9(e){var t=Dh(e),n=t.operation;if(n==="query")return e;var r=Wn(e,{OperationDefinition:{enter:function(i){return N(N({},i),{operation:"query"})}}});return r}function w9(e){Rc(e);var t=Ty([{test:function(n){return n.name.value==="client"},remove:!0}],e);return t}var _9=Object.prototype.hasOwnProperty;function t2(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return Fh(e)}function Fh(e){var t=e[0]||{},n=e.length;if(n>1)for(var r=new vr,i=1;i<n;++i)t=r.merge(t,e[i]);return t}var x9=function(e,t,n){return this.merge(e[n],t[n])},vr=function(){function e(t){t===void 0&&(t=x9),this.reconciler=t,this.isObject=Ye,this.pastCopies=new Set}return e.prototype.merge=function(t,n){for(var r=this,i=[],o=2;o<arguments.length;o++)i[o-2]=arguments[o];return Ye(n)&&Ye(t)?(Object.keys(n).forEach(function(a){if(_9.call(t,a)){var s=t[a];if(n[a]!==s){var c=r.reconciler.apply(r,dl([t,n,a],i,!1));c!==s&&(t=r.shallowCopyForMerge(t),t[a]=c)}}else t=r.shallowCopyForMerge(t),t[a]=n[a]}),t):n},e.prototype.shallowCopyForMerge=function(t){return Ye(t)&&(this.pastCopies.has(t)||(Array.isArray(t)?t=t.slice(0):t=N({__proto__:Object.getPrototypeOf(t)},t),this.pastCopies.add(t))),t},e}();function k9(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=E9(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
42
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function E9(e,t){if(!!e){if(typeof e=="string")return n2(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return n2(e,t)}}function n2(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function r2(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function zh(e,t,n){return t&&r2(e.prototype,t),n&&r2(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var jh=function(){return typeof Symbol=="function"},Vh=function(e){return jh()&&Boolean(Symbol[e])},Uh=function(e){return Vh(e)?Symbol[e]:"@@"+e};jh()&&!Vh("observable")&&(Symbol.observable=Symbol("observable"));var S9=Uh("iterator"),Zd=Uh("observable"),Py=Uh("species");function wl(e,t){var n=e[t];if(n!=null){if(typeof n!="function")throw new TypeError(n+" is not a function");return n}}function $o(e){var t=e.constructor;return t!==void 0&&(t=t[Py],t===null&&(t=void 0)),t!==void 0?t:Le}function O9(e){return e instanceof Le}function Fi(e){Fi.log?Fi.log(e):setTimeout(function(){throw e})}function ds(e){Promise.resolve().then(function(){try{e()}catch(t){Fi(t)}})}function Ay(e){var t=e._cleanup;if(t!==void 0&&(e._cleanup=void 0,!!t))try{if(typeof t=="function")t();else{var n=wl(t,"unsubscribe");n&&n.call(t)}}catch(r){Fi(r)}}function Jd(e){e._observer=void 0,e._queue=void 0,e._state="closed"}function C9(e){var t=e._queue;if(!!t){e._queue=void 0,e._state="ready";for(var n=0;n<t.length&&(Iy(e,t[n].type,t[n].value),e._state!=="closed");++n);}}function Iy(e,t,n){e._state="running";var r=e._observer;try{var i=wl(r,t);switch(t){case"next":i&&i.call(r,n);break;case"error":if(Jd(e),i)i.call(r,n);else throw n;break;case"complete":Jd(e),i&&i.call(r);break}}catch(o){Fi(o)}e._state==="closed"?Ay(e):e._state==="running"&&(e._state="ready")}function Cu(e,t,n){if(e._state!=="closed"){if(e._state==="buffering"){e._queue.push({type:t,value:n});return}if(e._state!=="ready"){e._state="buffering",e._queue=[{type:t,value:n}],ds(function(){return C9(e)});return}Iy(e,t,n)}}var N9=function(){function e(n,r){this._cleanup=void 0,this._observer=n,this._queue=void 0,this._state="initializing";var i=new T9(this);try{this._cleanup=r.call(void 0,i)}catch(o){i.error(o)}this._state==="initializing"&&(this._state="ready")}var t=e.prototype;return t.unsubscribe=function(){this._state!=="closed"&&(Jd(this),Ay(this))},zh(e,[{key:"closed",get:function(){return this._state==="closed"}}]),e}(),T9=function(){function e(n){this._subscription=n}var t=e.prototype;return t.next=function(r){Cu(this._subscription,"next",r)},t.error=function(r){Cu(this._subscription,"error",r)},t.complete=function(){Cu(this._subscription,"complete")},zh(e,[{key:"closed",get:function(){return this._subscription._state==="closed"}}]),e}(),Le=function(){function e(n){if(!(this instanceof e))throw new TypeError("Observable cannot be called as a function");if(typeof n!="function")throw new TypeError("Observable initializer must be a function");this._subscriber=n}var t=e.prototype;return t.subscribe=function(r){return(typeof r!="object"||r===null)&&(r={next:r,error:arguments[1],complete:arguments[2]}),new N9(r,this._subscriber)},t.forEach=function(r){var i=this;return new Promise(function(o,a){if(typeof r!="function"){a(new TypeError(r+" is not a function"));return}function s(){c.unsubscribe(),o()}var c=i.subscribe({next:function(l){try{r(l,s)}catch(u){a(u),c.unsubscribe()}},error:a,complete:o})})},t.map=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var o=$o(this);return new o(function(a){return i.subscribe({next:function(s){try{s=r(s)}catch(c){return a.error(c)}a.next(s)},error:function(s){a.error(s)},complete:function(){a.complete()}})})},t.filter=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var o=$o(this);return new o(function(a){return i.subscribe({next:function(s){try{if(!r(s))return}catch(c){return a.error(c)}a.next(s)},error:function(s){a.error(s)},complete:function(){a.complete()}})})},t.reduce=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var o=$o(this),a=arguments.length>1,s=!1,c=arguments[1],l=c;return new o(function(u){return i.subscribe({next:function(d){var f=!s;if(s=!0,!f||a)try{l=r(l,d)}catch(h){return u.error(h)}else l=d},error:function(d){u.error(d)},complete:function(){if(!s&&!a)return u.error(new TypeError("Cannot reduce an empty sequence"));u.next(l),u.complete()}})})},t.concat=function(){for(var r=this,i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];var s=$o(this);return new s(function(c){var l,u=0;function d(f){l=f.subscribe({next:function(h){c.next(h)},error:function(h){c.error(h)},complete:function(){u===o.length?(l=void 0,c.complete()):d(s.from(o[u++]))}})}return d(r),function(){l&&(l.unsubscribe(),l=void 0)}})},t.flatMap=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var o=$o(this);return new o(function(a){var s=[],c=i.subscribe({next:function(u){if(r)try{u=r(u)}catch(f){return a.error(f)}var d=o.from(u).subscribe({next:function(f){a.next(f)},error:function(f){a.error(f)},complete:function(){var f=s.indexOf(d);f>=0&&s.splice(f,1),l()}});s.push(d)},error:function(u){a.error(u)},complete:function(){l()}});function l(){c.closed&&s.length===0&&a.complete()}return function(){s.forEach(function(u){return u.unsubscribe()}),c.unsubscribe()}})},t[Zd]=function(){return this},e.from=function(r){var i=typeof this=="function"?this:e;if(r==null)throw new TypeError(r+" is not an object");var o=wl(r,Zd);if(o){var a=o.call(r);if(Object(a)!==a)throw new TypeError(a+" is not an object");return O9(a)&&a.constructor===i?a:new i(function(s){return a.subscribe(s)})}if(Vh("iterator")&&(o=wl(r,S9),o))return new i(function(s){ds(function(){if(!s.closed){for(var c=k9(o.call(r)),l;!(l=c()).done;){var u=l.value;if(s.next(u),s.closed)return}s.complete()}})});if(Array.isArray(r))return new i(function(s){ds(function(){if(!s.closed){for(var c=0;c<r.length;++c)if(s.next(r[c]),s.closed)return;s.complete()}})});throw new TypeError(r+" is not observable")},e.of=function(){for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];var a=typeof this=="function"?this:e;return new a(function(s){ds(function(){if(!s.closed){for(var c=0;c<i.length;++c)if(s.next(i[c]),s.closed)return;s.complete()}})})},zh(e,null,[{key:Py,get:function(){return this}}]),e}();jh()&&Object.defineProperty(Le,Symbol("extensions"),{value:{symbol:Zd,hostReportError:Fi},configurable:!0});function P9(e){var t,n=e.Symbol;if(typeof n=="function")if(n.observable)t=n.observable;else{typeof n.for=="function"?t=n.for("https://github.com/benlesh/symbol-observable"):t=n("https://github.com/benlesh/symbol-observable");try{n.observable=t}catch{}}else t="@@observable";return t}var mi;typeof self<"u"?mi=self:typeof window<"u"?mi=window:typeof global<"u"?mi=global:typeof module<"u"?mi=module:mi=Function("return this")();P9(mi);var i2=Le.prototype,o2="@@observable";i2[o2]||(i2[o2]=function(){return this});var A9=Object.prototype.toString;function My(e){return e0(e)}function e0(e,t){switch(A9.call(e)){case"[object Array]":{if(t=t||new Map,t.has(e))return t.get(e);var n=e.slice(0);return t.set(e,n),n.forEach(function(i,o){n[o]=e0(i,t)}),n}case"[object Object]":{if(t=t||new Map,t.has(e))return t.get(e);var r=Object.create(Object.getPrototypeOf(e));return t.set(e,r),Object.keys(e).forEach(function(i){r[i]=e0(e[i],t)}),r}default:return e}}function I9(e){var t=new Set([e]);return t.forEach(function(n){Ye(n)&&M9(n)===n&&Object.getOwnPropertyNames(n).forEach(function(r){Ye(n[r])&&t.add(n[r])})}),e}function M9(e){if(__DEV__&&!Object.isFrozen(e))try{Object.freeze(e)}catch(t){if(t instanceof TypeError)return null;throw t}return e}function t0(e){return __DEV__&&I9(e),e}function Vo(e,t,n){var r=[];e.forEach(function(i){return i[t]&&r.push(i)}),r.forEach(function(i){return i[t](n)})}function Nu(e,t,n){return new Le(function(r){var i=r.next,o=r.error,a=r.complete,s=0,c=!1,l={then:function(h){return new Promise(function(p){return p(h())})}};function u(h,p){return h?function(m){++s;var v=function(){return h(m)};l=l.then(v,v).then(function(b){--s,i&&i.call(r,b),c&&d.complete()},function(b){throw--s,b}).catch(function(b){o&&o.call(r,b)})}:function(m){return p&&p.call(r,m)}}var d={next:u(t,i),error:u(n,o),complete:function(){c=!0,s||a&&a.call(r)}},f=e.subscribe(d);return function(){return f.unsubscribe()}})}var ti=typeof WeakMap=="function"&&en(function(){return navigator.product})!=="ReactNative",D9=typeof WeakSet=="function",Dy=typeof Symbol=="function"&&typeof Symbol.for=="function",Fc=Dy&&Symbol.asyncIterator;en(function(){return window.document.createElement});en(function(){return navigator.userAgent.indexOf("jsdom")>=0});function Ly(e){function t(n){Object.defineProperty(e,n,{value:Le})}return Dy&&Symbol.species&&t(Symbol.species),t("@@species"),e}function a2(e){return e&&typeof e.then=="function"}var Lo=function(e){yn(t,e);function t(n){var r=e.call(this,function(i){return r.addObserver(i),function(){return r.removeObserver(i)}})||this;return r.observers=new Set,r.promise=new Promise(function(i,o){r.resolve=i,r.reject=o}),r.handlers={next:function(i){r.sub!==null&&(r.latest=["next",i],r.notify("next",i),Vo(r.observers,"next",i))},error:function(i){var o=r.sub;o!==null&&(o&&setTimeout(function(){return o.unsubscribe()}),r.sub=null,r.latest=["error",i],r.reject(i),r.notify("error",i),Vo(r.observers,"error",i))},complete:function(){var i=r,o=i.sub,a=i.sources,s=a===void 0?[]:a;if(o!==null){var c=s.shift();c?a2(c)?c.then(function(l){return r.sub=l.subscribe(r.handlers)}):r.sub=c.subscribe(r.handlers):(o&&setTimeout(function(){return o.unsubscribe()}),r.sub=null,r.latest&&r.latest[0]==="next"?r.resolve(r.latest[1]):r.resolve(),r.notify("complete"),Vo(r.observers,"complete"))}}},r.nextResultListeners=new Set,r.cancel=function(i){r.reject(i),r.sources=[],r.handlers.complete()},r.promise.catch(function(i){}),typeof n=="function"&&(n=[new Le(n)]),a2(n)?n.then(function(i){return r.start(i)},r.handlers.error):r.start(n),r}return t.prototype.start=function(n){this.sub===void 0&&(this.sources=Array.from(n),this.handlers.complete())},t.prototype.deliverLastMessage=function(n){if(this.latest){var r=this.latest[0],i=n[r];i&&i.call(n,this.latest[1]),this.sub===null&&r==="next"&&n.complete&&n.complete()}},t.prototype.addObserver=function(n){this.observers.has(n)||(this.deliverLastMessage(n),this.observers.add(n))},t.prototype.removeObserver=function(n){this.observers.delete(n)&&this.observers.size<1&&this.handlers.complete()},t.prototype.notify=function(n,r){var i=this.nextResultListeners;i.size&&(this.nextResultListeners=new Set,i.forEach(function(o){return o(n,r)}))},t.prototype.beforeNext=function(n){var r=!1;this.nextResultListeners.add(function(i,o){r||(r=!0,n(i,o))})},t}(Le);Ly(Lo);function Oi(e){return"incremental"in e}function L9(e){return"hasNext"in e&&"data"in e}function R9(e){return Oi(e)||L9(e)}function Ry(e,t){var n=e,r=new vr;return Oi(t)&&rn(t.incremental)&&t.incremental.forEach(function(i){for(var o=i.data,a=i.path,s=a.length-1;s>=0;--s){var c=a[s],l=!isNaN(+c),u=l?[]:{};u[c]=o,o=u}n=r.merge(n,o)}),n}function fs(e){var t=n0(e);return rn(t)}function n0(e){var t=rn(e.errors)?e.errors.slice(0):[];return Oi(e)&&rn(e.incremental)&&e.incremental.forEach(function(n){n.errors&&t.push.apply(t,n.errors)}),t}function zc(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=Object.create(null);return e.forEach(function(r){!r||Object.keys(r).forEach(function(i){var o=r[i];o!==void 0&&(n[i]=o)})}),n}var s2=new Map;function r0(e){var t=s2.get(e)||1;return s2.set(e,t+1),"".concat(e,":").concat(t,":").concat(Math.random().toString(36).slice(2))}function F9(e){var t=r0("stringifyForDisplay");return JSON.stringify(e,function(n,r){return r===void 0?t:r}).split(JSON.stringify(t)).join("<undefined>")}function Tu(e,t){return zc(e,t,t.variables&&{variables:N(N({},e&&e.variables),t.variables)})}function l2(e){return new Le(function(t){t.error(e)})}var i0=function(e,t,n){var r=new Error(n);throw r.name="ServerError",r.response=e,r.statusCode=e.status,r.result=t,r};function z9(e){for(var t=["query","operationName","variables","extensions","context"],n=0,r=Object.keys(e);n<r.length;n++){var i=r[n];if(t.indexOf(i)<0)throw __DEV__?new Se("illegal argument: ".concat(i)):new Se(27)}return e}function j9(e,t){var n=N({},e),r=function(o){typeof o=="function"?n=N(N({},n),o(n)):n=N(N({},n),o)},i=function(){return N({},n)};return Object.defineProperty(t,"setContext",{enumerable:!1,value:r}),Object.defineProperty(t,"getContext",{enumerable:!1,value:i}),t}function V9(e){var t={variables:e.variables||{},extensions:e.extensions||{},operationName:e.operationName,query:e.query};return t.operationName||(t.operationName=typeof t.query!="string"?Xd(t.query)||void 0:""),t}function c2(e,t){return t?t(e):Le.of()}function wo(e){return typeof e=="function"?new io(e):e}function za(e){return e.request.length<=1}var U9=function(e){yn(t,e);function t(n,r){var i=e.call(this,n)||this;return i.link=r,i}return t}(Error),io=function(){function e(t){t&&(this.request=t)}return e.empty=function(){return new e(function(){return Le.of()})},e.from=function(t){return t.length===0?e.empty():t.map(wo).reduce(function(n,r){return n.concat(r)})},e.split=function(t,n,r){var i=wo(n),o=wo(r||new e(c2));return za(i)&&za(o)?new e(function(a){return t(a)?i.request(a)||Le.of():o.request(a)||Le.of()}):new e(function(a,s){return t(a)?i.request(a,s)||Le.of():o.request(a,s)||Le.of()})},e.execute=function(t,n){return t.request(j9(n.context,V9(z9(n))))||Le.of()},e.concat=function(t,n){var r=wo(t);if(za(r))return __DEV__&&K.warn(new U9("You are calling concat on a terminating link, which will have no effect",r)),r;var i=wo(n);return za(i)?new e(function(o){return r.request(o,function(a){return i.request(a)||Le.of()})||Le.of()}):new e(function(o,a){return r.request(o,function(s){return i.request(s,a)||Le.of()})||Le.of()})},e.prototype.split=function(t,n,r){return this.concat(e.split(t,n,r||new e(c2)))},e.prototype.concat=function(t){return e.concat(this,t)},e.prototype.request=function(t,n){throw __DEV__?new Se("request is not implemented"):new Se(22)},e.prototype.onError=function(t,n){if(n&&n.error)return n.error(t),!1;throw t},e.prototype.setOnError=function(t){return this.onError=t,this},e}(),o0=io.execute,B9="3.7.10";function H9(e){return!!e.body}function q9(e){return!!e.getReader}function W9(e){return!!(Fc&&e[Symbol.asyncIterator])}function G9(e){return!!e.stream}function K9(e){return!!e.arrayBuffer}function Q9(e){return!!e.pipe}function Y9(e){var t,n=e[Symbol.asyncIterator]();return t={next:function(){return n.next()}},t[Symbol.asyncIterator]=function(){return this},t}function X9(e){var t=null,n=null,r=!1,i=[],o=[];function a(d){if(!n){if(o.length){var f=o.shift();if(Array.isArray(f)&&f[0])return f[0]({value:d,done:!1})}i.push(d)}}function s(d){n=d;var f=o.slice();f.forEach(function(h){h[1](d)}),!t||t()}function c(){r=!0;var d=o.slice();d.forEach(function(f){f[0]({value:void 0,done:!0})}),!t||t()}t=function(){t=null,e.removeListener("data",a),e.removeListener("error",s),e.removeListener("end",c),e.removeListener("finish",c),e.removeListener("close",c)},e.on("data",a),e.on("error",s),e.on("end",c),e.on("finish",c),e.on("close",c);function l(){return new Promise(function(d,f){if(n)return f(n);if(i.length)return d({value:i.shift(),done:!1});if(r)return d({value:void 0,done:!0});o.push([d,f])})}var u={next:function(){return l()}};return Fc&&(u[Symbol.asyncIterator]=function(){return this}),u}function Z9(e){var t=!1,n={next:function(){return t?Promise.resolve({value:void 0,done:!0}):(t=!0,new Promise(function(r,i){e.then(function(o){r({value:o,done:!1})}).catch(i)}))}};return Fc&&(n[Symbol.asyncIterator]=function(){return this}),n}function u2(e){var t={next:function(){return e.read()}};return Fc&&(t[Symbol.asyncIterator]=function(){return this}),t}function J9(e){var t=e;if(H9(e)&&(t=e.body),W9(t))return Y9(t);if(q9(t))return u2(t.getReader());if(G9(t))return u2(t.stream().getReader());if(K9(t))return Z9(t.arrayBuffer());if(Q9(t))return X9(t);throw new Error("Unknown body type for responseIterator. Please pass a streamable response.")}var d2=Object.prototype.hasOwnProperty;function ew(e,t){var n,r,i;return fe(this,void 0,void 0,function(){var o,a,s,c,l,u,d,f,h,p,m,v,b,y,g,_,x,O,C,M;return nr(this,function(D){switch(D.label){case 0:if(TextDecoder===void 0)throw new Error("TextDecoder must be defined in the environment: please import a polyfill.");o=new TextDecoder("utf-8"),a=(n=e.headers)===null||n===void 0?void 0:n.get("content-type"),s="boundary=",c=a?.includes(s)?a?.substring(a?.indexOf(s)+s.length).replace(/['"]/g,"").replace(/\;(.*)/gm,"").trim():"-",l="--".concat(c),u="",d=J9(e),f=!0,D.label=1;case 1:return f?[4,d.next()]:[3,3];case 2:for(h=D.sent(),p=h.value,m=h.done,v=typeof p=="string"?p:o.decode(p),f=!m,u+=v,b=u.indexOf(l);b>-1;){if(y=void 0,M=[u.slice(0,b),u.slice(b+l.length)],y=M[0],u=M[1],y.trim()){if(g=y.indexOf(`\r
|
|
41
|
+
`)))!==null&&t!==void 0?t:!1}function Zp(e){return e.kind===X.FIELD||e.kind===X.FRAGMENT_SPREAD||e.kind===X.INLINE_FRAGMENT}function Q$(){return Wp()}function Y$(){__DEV__?K(typeof Su=="boolean",Su):K(typeof Su=="boolean",39)}Q$();Y$();function Dc(e,t){var n=e.directives;return!n||!n.length?!0:J$(n).every(function(r){var i=r.directive,o=r.ifArgument,a=!1;return o.value.kind==="Variable"?(a=t&&t[o.value.name.value],__DEV__?K(a!==void 0,"Invalid variable referenced in @".concat(i.name.value," directive.")):K(a!==void 0,40)):a=o.value.value,i.name.value==="skip"?!a:a})}function Th(e,t,n){var r=new Set(e),i=r.size;return Wn(t,{Directive:function(o){if(r.delete(o.name.value)&&(!n||!r.size))return Nh}}),n?!r.size:r.size<i}function X$(e){return e&&Th(["client","export"],e,!0)}function Z$(e){var t=e.name.value;return t==="skip"||t==="include"}function J$(e){var t=[];return e&&e.length&&e.forEach(function(n){if(!!Z$(n)){var r=n.arguments,i=n.name.value;__DEV__?K(r&&r.length===1,"Incorrect number of arguments for the @".concat(i," directive.")):K(r&&r.length===1,41);var o=r[0];__DEV__?K(o.name&&o.name.value==="if","Invalid argument for the @".concat(i," directive.")):K(o.name&&o.name.value==="if",42);var a=o.value;__DEV__?K(a&&(a.kind==="Variable"||a.kind==="BooleanValue"),"Argument for the @".concat(i," directive must be a variable or a boolean value.")):K(a&&(a.kind==="Variable"||a.kind==="BooleanValue"),43),t.push({directive:n,ifArgument:o})}}),t}function e9(e,t){var n=t,r=[];e.definitions.forEach(function(o){if(o.kind==="OperationDefinition")throw __DEV__?new Se("Found a ".concat(o.operation," operation").concat(o.name?" named '".concat(o.name.value,"'"):"",". ")+"No operations are allowed when using a fragment as a query. Only fragments are allowed."):new Se(44);o.kind==="FragmentDefinition"&&r.push(o)}),typeof n>"u"&&(__DEV__?K(r.length===1,"Found ".concat(r.length," fragments. `fragmentName` must be provided when there is not exactly 1 fragment.")):K(r.length===1,45),n=r[0].name.value);var i=T(T({},e),{definitions:dl([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:n}}]}}],e.definitions,!0)});return i}function Ph(e){e===void 0&&(e=[]);var t={};return e.forEach(function(n){t[n.name.value]=n}),t}function Ah(e,t){switch(e.kind){case"InlineFragment":return e;case"FragmentSpread":{var n=e.name.value;if(typeof t=="function")return t(n);var r=t&&t[n];return __DEV__?K(r,"No fragment named ".concat(n)):K(r,46),r||null}default:return null}}function Ye(e){return e!==null&&typeof e=="object"}function Si(e){return{__ref:String(e)}}function Pe(e){return Boolean(e&&typeof e=="object"&&typeof e.__ref=="string")}function t9(e){return Ye(e)&&e.kind==="Document"&&Array.isArray(e.definitions)}function n9(e){return e.kind==="StringValue"}function r9(e){return e.kind==="BooleanValue"}function i9(e){return e.kind==="IntValue"}function o9(e){return e.kind==="FloatValue"}function a9(e){return e.kind==="Variable"}function s9(e){return e.kind==="ObjectValue"}function l9(e){return e.kind==="ListValue"}function c9(e){return e.kind==="EnumValue"}function u9(e){return e.kind==="NullValue"}function Ri(e,t,n,r){if(i9(n)||o9(n))e[t.value]=Number(n.value);else if(r9(n)||n9(n))e[t.value]=n.value;else if(s9(n)){var i={};n.fields.map(function(a){return Ri(i,a.name,a.value,r)}),e[t.value]=i}else if(a9(n)){var o=(r||{})[n.name.value];e[t.value]=o}else if(l9(n))e[t.value]=n.values.map(function(a){var s={};return Ri(s,t,a,r),s[t.value]});else if(c9(n))e[t.value]=n.value;else if(u9(n))e[t.value]=null;else throw __DEV__?new Se('The inline argument "'.concat(t.value,'" of kind "').concat(n.kind,'"')+"is not supported. Use variables instead of inline arguments to overcome this limitation."):new Se(55)}function d9(e,t){var n=null;e.directives&&(n={},e.directives.forEach(function(i){n[i.name.value]={},i.arguments&&i.arguments.forEach(function(o){var a=o.name,s=o.value;return Ri(n[i.name.value],a,s,t)})}));var r=null;return e.arguments&&e.arguments.length&&(r={},e.arguments.forEach(function(i){var o=i.name,a=i.value;return Ri(r,o,a,t)})),Ih(e.name.value,r,n)}var f9=["connection","include","skip","client","rest","export"],Ih=Object.assign(function(e,t,n){if(t&&n&&n.connection&&n.connection.key)if(n.connection.filter&&n.connection.filter.length>0){var r=n.connection.filter?n.connection.filter:[];r.sort();var i={};return r.forEach(function(s){i[s]=t[s]}),"".concat(n.connection.key,"(").concat(bo(i),")")}else return n.connection.key;var o=e;if(t){var a=bo(t);o+="(".concat(a,")")}return n&&Object.keys(n).forEach(function(s){f9.indexOf(s)===-1&&(n[s]&&Object.keys(n[s]).length?o+="@".concat(s,"(").concat(bo(n[s]),")"):o+="@".concat(s))}),o},{setStringify:function(e){var t=bo;return bo=e,t}}),bo=function(t){return JSON.stringify(t,h9)};function h9(e,t){return Ye(t)&&!Array.isArray(t)&&(t=Object.keys(t).sort().reduce(function(n,r){return n[r]=t[r],n},{})),t}function Lc(e,t){if(e.arguments&&e.arguments.length){var n={};return e.arguments.forEach(function(r){var i=r.name,o=r.value;return Ri(n,i,o,t)}),n}return null}function Wr(e){return e.alias?e.alias.value:e.name.value}function Yd(e,t,n){if(typeof e.__typename=="string")return e.__typename;for(var r=0,i=t.selections;r<i.length;r++){var o=i[r];if(Gr(o)){if(o.name.value==="__typename")return e[Wr(o)]}else{var a=Yd(e,Ah(o,n).selectionSet,n);if(typeof a=="string")return a}}}function Gr(e){return e.kind==="Field"}function p9(e){return e.kind==="InlineFragment"}function Rc(e){__DEV__?K(e&&e.kind==="Document",'Expecting a parsed GraphQL document. Perhaps you need to wrap the query string in a "gql" tag? http://docs.apollostack.com/apollo-client/core.html#gql'):K(e&&e.kind==="Document",47);var t=e.definitions.filter(function(n){return n.kind!=="FragmentDefinition"}).map(function(n){if(n.kind!=="OperationDefinition")throw __DEV__?new Se('Schema type definitions not allowed in queries. Found: "'.concat(n.kind,'"')):new Se(48);return n});return __DEV__?K(t.length<=1,"Ambiguous GraphQL document: contains ".concat(t.length," operations")):K(t.length<=1,49),e}function $a(e){return Rc(e),e.definitions.filter(function(t){return t.kind==="OperationDefinition"})[0]}function Xd(e){return e.definitions.filter(function(t){return t.kind==="OperationDefinition"&&!!t.name}).map(function(t){return t.name.value})[0]||null}function Mh(e){return e.definitions.filter(function(t){return t.kind==="FragmentDefinition"})}function Cy(e){var t=$a(e);return __DEV__?K(t&&t.operation==="query","Must contain a query definition."):K(t&&t.operation==="query",50),t}function m9(e){__DEV__?K(e.kind==="Document",'Expecting a parsed GraphQL document. Perhaps you need to wrap the query string in a "gql" tag? http://docs.apollostack.com/apollo-client/core.html#gql'):K(e.kind==="Document",51),__DEV__?K(e.definitions.length<=1,"Fragment must have exactly one definition."):K(e.definitions.length<=1,52);var t=e.definitions[0];return __DEV__?K(t.kind==="FragmentDefinition","Must be a fragment definition."):K(t.kind==="FragmentDefinition",53),t}function Dh(e){Rc(e);for(var t,n=0,r=e.definitions;n<r.length;n++){var i=r[n];if(i.kind==="OperationDefinition"){var o=i.operation;if(o==="query"||o==="mutation"||o==="subscription")return i}i.kind==="FragmentDefinition"&&!t&&(t=i)}if(t)return t;throw __DEV__?new Se("Expected a parsed GraphQL query with a query, mutation, subscription, or a fragment."):new Se(54)}function Lh(e){var t=Object.create(null),n=e&&e.variableDefinitions;return n&&n.length&&n.forEach(function(r){r.defaultValue&&Ri(t,r.variable.name,r.defaultValue)}),t}var Xe=Array.isArray;function rn(e){return Array.isArray(e)&&e.length>0}var Jp={kind:X.FIELD,name:{kind:X.NAME,value:"__typename"}};function Ny(e,t){return!e||e.selectionSet.selections.every(function(n){return n.kind===X.FRAGMENT_SPREAD&&Ny(t[n.name.value],t)})}function v9(e){return Ny($a(e)||m9(e),Ph(Mh(e)))?null:e}function g9(e){var t=new Set,n=[];return e.forEach(function(r){r.name?t.add(r.name):r.test&&n.push(r.test)}),function(r){return t.has(r.name.value)||n.some(function(i){return i(r)})}}function e2(e){var t=new Map;return function(r){r===void 0&&(r=e);var i=t.get(r);return i||t.set(r,i={variables:new Set,fragmentSpreads:new Set}),i}}function Ty(e,t){for(var n=e2(""),r=e2(""),i=function(y){for(var g=0,_=void 0;g<y.length&&(_=y[g]);++g)if(!Xe(_)){if(_.kind===X.OPERATION_DEFINITION)return n(_.name&&_.name.value);if(_.kind===X.FRAGMENT_DEFINITION)return r(_.name.value)}return __DEV__&&K.error("Could not find operation or fragment"),null},o=0,a=t.definitions.length-1;a>=0;--a)t.definitions[a].kind===X.OPERATION_DEFINITION&&++o;var s=g9(e),c=e.some(function(y){return y.remove}),l=function(y){return c&&y&&y.some(s)},u=new Map,d=!1,f={enter:function(y){if(l(y.directives))return d=!0,null}},h=Wn(t,{Field:f,InlineFragment:f,VariableDefinition:{enter:function(){return!1}},Variable:{enter:function(y,g,_,k,O){var C=i(O);C&&C.variables.add(y.name.value)}},FragmentSpread:{enter:function(y,g,_,k,O){if(l(y.directives))return d=!0,null;var C=i(O);C&&C.fragmentSpreads.add(y.name.value)}},FragmentDefinition:{enter:function(y,g,_,k){u.set(JSON.stringify(k),y)},leave:function(y,g,_,k){var O=u.get(JSON.stringify(k));if(y===O)return y;if(o>0&&y.selectionSet.selections.every(function(C){return C.kind===X.FIELD&&C.name.value==="__typename"}))return r(y.name.value).removed=!0,d=!0,null}},Directive:{leave:function(y){if(s(y))return d=!0,null}}});if(!d)return t;var p=function(y){return y.transitiveVars||(y.transitiveVars=new Set(y.variables),y.removed||y.fragmentSpreads.forEach(function(g){p(r(g)).transitiveVars.forEach(function(_){y.transitiveVars.add(_)})})),y},m=new Set;h.definitions.forEach(function(y){y.kind===X.OPERATION_DEFINITION?p(n(y.name&&y.name.value)).fragmentSpreads.forEach(function(g){m.add(g)}):y.kind===X.FRAGMENT_DEFINITION&&o===0&&!r(y.name.value).removed&&m.add(y.name.value)}),m.forEach(function(y){p(r(y)).fragmentSpreads.forEach(function(g){m.add(g)})});var v=function(y){return!!(!m.has(y)||r(y).removed)},b={enter:function(y){if(v(y.name.value))return null}};return v9(Wn(h,{FragmentSpread:b,FragmentDefinition:b,OperationDefinition:{leave:function(y){if(y.variableDefinitions){var g=p(n(y.name&&y.name.value)).transitiveVars;if(g.size<y.variableDefinitions.length)return T(T({},y),{variableDefinitions:y.variableDefinitions.filter(function(_){return g.has(_.variable.name.value)})})}}}}))}var Rh=Object.assign(function(e){return Wn(e,{SelectionSet:{enter:function(t,n,r){if(!(r&&r.kind===X.OPERATION_DEFINITION)){var i=t.selections;if(!!i){var o=i.some(function(s){return Gr(s)&&(s.name.value==="__typename"||s.name.value.lastIndexOf("__",0)===0)});if(!o){var a=r;if(!(Gr(a)&&a.directives&&a.directives.some(function(s){return s.name.value==="export"})))return T(T({},t),{selections:dl(dl([],i,!0),[Jp],!1)})}}}}}})},{added:function(e){return e===Jp}}),y9={test:function(e){var t=e.name.value==="connection";return t&&(!e.arguments||!e.arguments.some(function(n){return n.name.value==="key"}))&&__DEV__&&K.warn("Removing an @connection directive even though it does not have a key. You may want to use the key parameter to specify a store key."),t}};function b9(e){return Ty([y9],Rc(e))}function $9(e){var t=Dh(e),n=t.operation;if(n==="query")return e;var r=Wn(e,{OperationDefinition:{enter:function(i){return T(T({},i),{operation:"query"})}}});return r}function w9(e){Rc(e);var t=Ty([{test:function(n){return n.name.value==="client"},remove:!0}],e);return t}var _9=Object.prototype.hasOwnProperty;function t2(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return Fh(e)}function Fh(e){var t=e[0]||{},n=e.length;if(n>1)for(var r=new vr,i=1;i<n;++i)t=r.merge(t,e[i]);return t}var x9=function(e,t,n){return this.merge(e[n],t[n])},vr=function(){function e(t){t===void 0&&(t=x9),this.reconciler=t,this.isObject=Ye,this.pastCopies=new Set}return e.prototype.merge=function(t,n){for(var r=this,i=[],o=2;o<arguments.length;o++)i[o-2]=arguments[o];return Ye(n)&&Ye(t)?(Object.keys(n).forEach(function(a){if(_9.call(t,a)){var s=t[a];if(n[a]!==s){var c=r.reconciler.apply(r,dl([t,n,a],i,!1));c!==s&&(t=r.shallowCopyForMerge(t),t[a]=c)}}else t=r.shallowCopyForMerge(t),t[a]=n[a]}),t):n},e.prototype.shallowCopyForMerge=function(t){return Ye(t)&&(this.pastCopies.has(t)||(Array.isArray(t)?t=t.slice(0):t=T({__proto__:Object.getPrototypeOf(t)},t),this.pastCopies.add(t))),t},e}();function k9(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=E9(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
42
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function E9(e,t){if(!!e){if(typeof e=="string")return n2(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return n2(e,t)}}function n2(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function r2(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function zh(e,t,n){return t&&r2(e.prototype,t),n&&r2(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var jh=function(){return typeof Symbol=="function"},Vh=function(e){return jh()&&Boolean(Symbol[e])},Uh=function(e){return Vh(e)?Symbol[e]:"@@"+e};jh()&&!Vh("observable")&&(Symbol.observable=Symbol("observable"));var S9=Uh("iterator"),Zd=Uh("observable"),Py=Uh("species");function wl(e,t){var n=e[t];if(n!=null){if(typeof n!="function")throw new TypeError(n+" is not a function");return n}}function $o(e){var t=e.constructor;return t!==void 0&&(t=t[Py],t===null&&(t=void 0)),t!==void 0?t:Le}function O9(e){return e instanceof Le}function Fi(e){Fi.log?Fi.log(e):setTimeout(function(){throw e})}function ds(e){Promise.resolve().then(function(){try{e()}catch(t){Fi(t)}})}function Ay(e){var t=e._cleanup;if(t!==void 0&&(e._cleanup=void 0,!!t))try{if(typeof t=="function")t();else{var n=wl(t,"unsubscribe");n&&n.call(t)}}catch(r){Fi(r)}}function Jd(e){e._observer=void 0,e._queue=void 0,e._state="closed"}function C9(e){var t=e._queue;if(!!t){e._queue=void 0,e._state="ready";for(var n=0;n<t.length&&(Iy(e,t[n].type,t[n].value),e._state!=="closed");++n);}}function Iy(e,t,n){e._state="running";var r=e._observer;try{var i=wl(r,t);switch(t){case"next":i&&i.call(r,n);break;case"error":if(Jd(e),i)i.call(r,n);else throw n;break;case"complete":Jd(e),i&&i.call(r);break}}catch(o){Fi(o)}e._state==="closed"?Ay(e):e._state==="running"&&(e._state="ready")}function Cu(e,t,n){if(e._state!=="closed"){if(e._state==="buffering"){e._queue.push({type:t,value:n});return}if(e._state!=="ready"){e._state="buffering",e._queue=[{type:t,value:n}],ds(function(){return C9(e)});return}Iy(e,t,n)}}var N9=function(){function e(n,r){this._cleanup=void 0,this._observer=n,this._queue=void 0,this._state="initializing";var i=new T9(this);try{this._cleanup=r.call(void 0,i)}catch(o){i.error(o)}this._state==="initializing"&&(this._state="ready")}var t=e.prototype;return t.unsubscribe=function(){this._state!=="closed"&&(Jd(this),Ay(this))},zh(e,[{key:"closed",get:function(){return this._state==="closed"}}]),e}(),T9=function(){function e(n){this._subscription=n}var t=e.prototype;return t.next=function(r){Cu(this._subscription,"next",r)},t.error=function(r){Cu(this._subscription,"error",r)},t.complete=function(){Cu(this._subscription,"complete")},zh(e,[{key:"closed",get:function(){return this._subscription._state==="closed"}}]),e}(),Le=function(){function e(n){if(!(this instanceof e))throw new TypeError("Observable cannot be called as a function");if(typeof n!="function")throw new TypeError("Observable initializer must be a function");this._subscriber=n}var t=e.prototype;return t.subscribe=function(r){return(typeof r!="object"||r===null)&&(r={next:r,error:arguments[1],complete:arguments[2]}),new N9(r,this._subscriber)},t.forEach=function(r){var i=this;return new Promise(function(o,a){if(typeof r!="function"){a(new TypeError(r+" is not a function"));return}function s(){c.unsubscribe(),o()}var c=i.subscribe({next:function(l){try{r(l,s)}catch(u){a(u),c.unsubscribe()}},error:a,complete:o})})},t.map=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var o=$o(this);return new o(function(a){return i.subscribe({next:function(s){try{s=r(s)}catch(c){return a.error(c)}a.next(s)},error:function(s){a.error(s)},complete:function(){a.complete()}})})},t.filter=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var o=$o(this);return new o(function(a){return i.subscribe({next:function(s){try{if(!r(s))return}catch(c){return a.error(c)}a.next(s)},error:function(s){a.error(s)},complete:function(){a.complete()}})})},t.reduce=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var o=$o(this),a=arguments.length>1,s=!1,c=arguments[1],l=c;return new o(function(u){return i.subscribe({next:function(d){var f=!s;if(s=!0,!f||a)try{l=r(l,d)}catch(h){return u.error(h)}else l=d},error:function(d){u.error(d)},complete:function(){if(!s&&!a)return u.error(new TypeError("Cannot reduce an empty sequence"));u.next(l),u.complete()}})})},t.concat=function(){for(var r=this,i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];var s=$o(this);return new s(function(c){var l,u=0;function d(f){l=f.subscribe({next:function(h){c.next(h)},error:function(h){c.error(h)},complete:function(){u===o.length?(l=void 0,c.complete()):d(s.from(o[u++]))}})}return d(r),function(){l&&(l.unsubscribe(),l=void 0)}})},t.flatMap=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var o=$o(this);return new o(function(a){var s=[],c=i.subscribe({next:function(u){if(r)try{u=r(u)}catch(f){return a.error(f)}var d=o.from(u).subscribe({next:function(f){a.next(f)},error:function(f){a.error(f)},complete:function(){var f=s.indexOf(d);f>=0&&s.splice(f,1),l()}});s.push(d)},error:function(u){a.error(u)},complete:function(){l()}});function l(){c.closed&&s.length===0&&a.complete()}return function(){s.forEach(function(u){return u.unsubscribe()}),c.unsubscribe()}})},t[Zd]=function(){return this},e.from=function(r){var i=typeof this=="function"?this:e;if(r==null)throw new TypeError(r+" is not an object");var o=wl(r,Zd);if(o){var a=o.call(r);if(Object(a)!==a)throw new TypeError(a+" is not an object");return O9(a)&&a.constructor===i?a:new i(function(s){return a.subscribe(s)})}if(Vh("iterator")&&(o=wl(r,S9),o))return new i(function(s){ds(function(){if(!s.closed){for(var c=k9(o.call(r)),l;!(l=c()).done;){var u=l.value;if(s.next(u),s.closed)return}s.complete()}})});if(Array.isArray(r))return new i(function(s){ds(function(){if(!s.closed){for(var c=0;c<r.length;++c)if(s.next(r[c]),s.closed)return;s.complete()}})});throw new TypeError(r+" is not observable")},e.of=function(){for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];var a=typeof this=="function"?this:e;return new a(function(s){ds(function(){if(!s.closed){for(var c=0;c<i.length;++c)if(s.next(i[c]),s.closed)return;s.complete()}})})},zh(e,null,[{key:Py,get:function(){return this}}]),e}();jh()&&Object.defineProperty(Le,Symbol("extensions"),{value:{symbol:Zd,hostReportError:Fi},configurable:!0});function P9(e){var t,n=e.Symbol;if(typeof n=="function")if(n.observable)t=n.observable;else{typeof n.for=="function"?t=n.for("https://github.com/benlesh/symbol-observable"):t=n("https://github.com/benlesh/symbol-observable");try{n.observable=t}catch{}}else t="@@observable";return t}var mi;typeof self<"u"?mi=self:typeof window<"u"?mi=window:typeof global<"u"?mi=global:typeof module<"u"?mi=module:mi=Function("return this")();P9(mi);var i2=Le.prototype,o2="@@observable";i2[o2]||(i2[o2]=function(){return this});var A9=Object.prototype.toString;function My(e){return e0(e)}function e0(e,t){switch(A9.call(e)){case"[object Array]":{if(t=t||new Map,t.has(e))return t.get(e);var n=e.slice(0);return t.set(e,n),n.forEach(function(i,o){n[o]=e0(i,t)}),n}case"[object Object]":{if(t=t||new Map,t.has(e))return t.get(e);var r=Object.create(Object.getPrototypeOf(e));return t.set(e,r),Object.keys(e).forEach(function(i){r[i]=e0(e[i],t)}),r}default:return e}}function I9(e){var t=new Set([e]);return t.forEach(function(n){Ye(n)&&M9(n)===n&&Object.getOwnPropertyNames(n).forEach(function(r){Ye(n[r])&&t.add(n[r])})}),e}function M9(e){if(__DEV__&&!Object.isFrozen(e))try{Object.freeze(e)}catch(t){if(t instanceof TypeError)return null;throw t}return e}function t0(e){return __DEV__&&I9(e),e}function Vo(e,t,n){var r=[];e.forEach(function(i){return i[t]&&r.push(i)}),r.forEach(function(i){return i[t](n)})}function Nu(e,t,n){return new Le(function(r){var i=r.next,o=r.error,a=r.complete,s=0,c=!1,l={then:function(h){return new Promise(function(p){return p(h())})}};function u(h,p){return h?function(m){++s;var v=function(){return h(m)};l=l.then(v,v).then(function(b){--s,i&&i.call(r,b),c&&d.complete()},function(b){throw--s,b}).catch(function(b){o&&o.call(r,b)})}:function(m){return p&&p.call(r,m)}}var d={next:u(t,i),error:u(n,o),complete:function(){c=!0,s||a&&a.call(r)}},f=e.subscribe(d);return function(){return f.unsubscribe()}})}var ti=typeof WeakMap=="function"&&en(function(){return navigator.product})!=="ReactNative",D9=typeof WeakSet=="function",Dy=typeof Symbol=="function"&&typeof Symbol.for=="function",Fc=Dy&&Symbol.asyncIterator;en(function(){return window.document.createElement});en(function(){return navigator.userAgent.indexOf("jsdom")>=0});function Ly(e){function t(n){Object.defineProperty(e,n,{value:Le})}return Dy&&Symbol.species&&t(Symbol.species),t("@@species"),e}function a2(e){return e&&typeof e.then=="function"}var Lo=function(e){yn(t,e);function t(n){var r=e.call(this,function(i){return r.addObserver(i),function(){return r.removeObserver(i)}})||this;return r.observers=new Set,r.promise=new Promise(function(i,o){r.resolve=i,r.reject=o}),r.handlers={next:function(i){r.sub!==null&&(r.latest=["next",i],r.notify("next",i),Vo(r.observers,"next",i))},error:function(i){var o=r.sub;o!==null&&(o&&setTimeout(function(){return o.unsubscribe()}),r.sub=null,r.latest=["error",i],r.reject(i),r.notify("error",i),Vo(r.observers,"error",i))},complete:function(){var i=r,o=i.sub,a=i.sources,s=a===void 0?[]:a;if(o!==null){var c=s.shift();c?a2(c)?c.then(function(l){return r.sub=l.subscribe(r.handlers)}):r.sub=c.subscribe(r.handlers):(o&&setTimeout(function(){return o.unsubscribe()}),r.sub=null,r.latest&&r.latest[0]==="next"?r.resolve(r.latest[1]):r.resolve(),r.notify("complete"),Vo(r.observers,"complete"))}}},r.nextResultListeners=new Set,r.cancel=function(i){r.reject(i),r.sources=[],r.handlers.complete()},r.promise.catch(function(i){}),typeof n=="function"&&(n=[new Le(n)]),a2(n)?n.then(function(i){return r.start(i)},r.handlers.error):r.start(n),r}return t.prototype.start=function(n){this.sub===void 0&&(this.sources=Array.from(n),this.handlers.complete())},t.prototype.deliverLastMessage=function(n){if(this.latest){var r=this.latest[0],i=n[r];i&&i.call(n,this.latest[1]),this.sub===null&&r==="next"&&n.complete&&n.complete()}},t.prototype.addObserver=function(n){this.observers.has(n)||(this.deliverLastMessage(n),this.observers.add(n))},t.prototype.removeObserver=function(n){this.observers.delete(n)&&this.observers.size<1&&this.handlers.complete()},t.prototype.notify=function(n,r){var i=this.nextResultListeners;i.size&&(this.nextResultListeners=new Set,i.forEach(function(o){return o(n,r)}))},t.prototype.beforeNext=function(n){var r=!1;this.nextResultListeners.add(function(i,o){r||(r=!0,n(i,o))})},t}(Le);Ly(Lo);function Oi(e){return"incremental"in e}function L9(e){return"hasNext"in e&&"data"in e}function R9(e){return Oi(e)||L9(e)}function Ry(e,t){var n=e,r=new vr;return Oi(t)&&rn(t.incremental)&&t.incremental.forEach(function(i){for(var o=i.data,a=i.path,s=a.length-1;s>=0;--s){var c=a[s],l=!isNaN(+c),u=l?[]:{};u[c]=o,o=u}n=r.merge(n,o)}),n}function fs(e){var t=n0(e);return rn(t)}function n0(e){var t=rn(e.errors)?e.errors.slice(0):[];return Oi(e)&&rn(e.incremental)&&e.incremental.forEach(function(n){n.errors&&t.push.apply(t,n.errors)}),t}function zc(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=Object.create(null);return e.forEach(function(r){!r||Object.keys(r).forEach(function(i){var o=r[i];o!==void 0&&(n[i]=o)})}),n}var s2=new Map;function r0(e){var t=s2.get(e)||1;return s2.set(e,t+1),"".concat(e,":").concat(t,":").concat(Math.random().toString(36).slice(2))}function F9(e){var t=r0("stringifyForDisplay");return JSON.stringify(e,function(n,r){return r===void 0?t:r}).split(JSON.stringify(t)).join("<undefined>")}function Tu(e,t){return zc(e,t,t.variables&&{variables:T(T({},e&&e.variables),t.variables)})}function l2(e){return new Le(function(t){t.error(e)})}var i0=function(e,t,n){var r=new Error(n);throw r.name="ServerError",r.response=e,r.statusCode=e.status,r.result=t,r};function z9(e){for(var t=["query","operationName","variables","extensions","context"],n=0,r=Object.keys(e);n<r.length;n++){var i=r[n];if(t.indexOf(i)<0)throw __DEV__?new Se("illegal argument: ".concat(i)):new Se(27)}return e}function j9(e,t){var n=T({},e),r=function(o){typeof o=="function"?n=T(T({},n),o(n)):n=T(T({},n),o)},i=function(){return T({},n)};return Object.defineProperty(t,"setContext",{enumerable:!1,value:r}),Object.defineProperty(t,"getContext",{enumerable:!1,value:i}),t}function V9(e){var t={variables:e.variables||{},extensions:e.extensions||{},operationName:e.operationName,query:e.query};return t.operationName||(t.operationName=typeof t.query!="string"?Xd(t.query)||void 0:""),t}function c2(e,t){return t?t(e):Le.of()}function wo(e){return typeof e=="function"?new io(e):e}function za(e){return e.request.length<=1}var U9=function(e){yn(t,e);function t(n,r){var i=e.call(this,n)||this;return i.link=r,i}return t}(Error),io=function(){function e(t){t&&(this.request=t)}return e.empty=function(){return new e(function(){return Le.of()})},e.from=function(t){return t.length===0?e.empty():t.map(wo).reduce(function(n,r){return n.concat(r)})},e.split=function(t,n,r){var i=wo(n),o=wo(r||new e(c2));return za(i)&&za(o)?new e(function(a){return t(a)?i.request(a)||Le.of():o.request(a)||Le.of()}):new e(function(a,s){return t(a)?i.request(a,s)||Le.of():o.request(a,s)||Le.of()})},e.execute=function(t,n){return t.request(j9(n.context,V9(z9(n))))||Le.of()},e.concat=function(t,n){var r=wo(t);if(za(r))return __DEV__&&K.warn(new U9("You are calling concat on a terminating link, which will have no effect",r)),r;var i=wo(n);return za(i)?new e(function(o){return r.request(o,function(a){return i.request(a)||Le.of()})||Le.of()}):new e(function(o,a){return r.request(o,function(s){return i.request(s,a)||Le.of()})||Le.of()})},e.prototype.split=function(t,n,r){return this.concat(e.split(t,n,r||new e(c2)))},e.prototype.concat=function(t){return e.concat(this,t)},e.prototype.request=function(t,n){throw __DEV__?new Se("request is not implemented"):new Se(22)},e.prototype.onError=function(t,n){if(n&&n.error)return n.error(t),!1;throw t},e.prototype.setOnError=function(t){return this.onError=t,this},e}(),o0=io.execute,B9="3.7.10";function H9(e){return!!e.body}function q9(e){return!!e.getReader}function W9(e){return!!(Fc&&e[Symbol.asyncIterator])}function G9(e){return!!e.stream}function K9(e){return!!e.arrayBuffer}function Q9(e){return!!e.pipe}function Y9(e){var t,n=e[Symbol.asyncIterator]();return t={next:function(){return n.next()}},t[Symbol.asyncIterator]=function(){return this},t}function X9(e){var t=null,n=null,r=!1,i=[],o=[];function a(d){if(!n){if(o.length){var f=o.shift();if(Array.isArray(f)&&f[0])return f[0]({value:d,done:!1})}i.push(d)}}function s(d){n=d;var f=o.slice();f.forEach(function(h){h[1](d)}),!t||t()}function c(){r=!0;var d=o.slice();d.forEach(function(f){f[0]({value:void 0,done:!0})}),!t||t()}t=function(){t=null,e.removeListener("data",a),e.removeListener("error",s),e.removeListener("end",c),e.removeListener("finish",c),e.removeListener("close",c)},e.on("data",a),e.on("error",s),e.on("end",c),e.on("finish",c),e.on("close",c);function l(){return new Promise(function(d,f){if(n)return f(n);if(i.length)return d({value:i.shift(),done:!1});if(r)return d({value:void 0,done:!0});o.push([d,f])})}var u={next:function(){return l()}};return Fc&&(u[Symbol.asyncIterator]=function(){return this}),u}function Z9(e){var t=!1,n={next:function(){return t?Promise.resolve({value:void 0,done:!0}):(t=!0,new Promise(function(r,i){e.then(function(o){r({value:o,done:!1})}).catch(i)}))}};return Fc&&(n[Symbol.asyncIterator]=function(){return this}),n}function u2(e){var t={next:function(){return e.read()}};return Fc&&(t[Symbol.asyncIterator]=function(){return this}),t}function J9(e){var t=e;if(H9(e)&&(t=e.body),W9(t))return Y9(t);if(q9(t))return u2(t.getReader());if(G9(t))return u2(t.stream().getReader());if(K9(t))return Z9(t.arrayBuffer());if(Q9(t))return X9(t);throw new Error("Unknown body type for responseIterator. Please pass a streamable response.")}var d2=Object.prototype.hasOwnProperty;function ew(e,t){var n,r,i;return fe(this,void 0,void 0,function(){var o,a,s,c,l,u,d,f,h,p,m,v,b,y,g,_,k,O,C,M;return nr(this,function(D){switch(D.label){case 0:if(TextDecoder===void 0)throw new Error("TextDecoder must be defined in the environment: please import a polyfill.");o=new TextDecoder("utf-8"),a=(n=e.headers)===null||n===void 0?void 0:n.get("content-type"),s="boundary=",c=a?.includes(s)?a?.substring(a?.indexOf(s)+s.length).replace(/['"]/g,"").replace(/\;(.*)/gm,"").trim():"-",l="--".concat(c),u="",d=J9(e),f=!0,D.label=1;case 1:return f?[4,d.next()]:[3,3];case 2:for(h=D.sent(),p=h.value,m=h.done,v=typeof p=="string"?p:o.decode(p),f=!m,u+=v,b=u.indexOf(l);b>-1;){if(y=void 0,M=[u.slice(0,b),u.slice(b+l.length)],y=M[0],u=M[1],y.trim()){if(g=y.indexOf(`\r
|
|
43
43
|
\r
|
|
44
|
-
`),_=tw(y.slice(0,g)),
|
|
44
|
+
`),_=tw(y.slice(0,g)),k=_["content-type"],k&&k.toLowerCase().indexOf("application/json")===-1)throw new Error("Unsupported patch content type: application/json is required.");O=y.slice(g);try{C=Fy(e,O.replace(`\r
|
|
45
45
|
`,"")),(Object.keys(C).length>1||"data"in C||"incremental"in C||"errors"in C)&&((r=t.next)===null||r===void 0||r.call(t,C))}catch(F){Bh(F,t)}}b=u.indexOf(l)}return[3,1];case 3:return(i=t.complete)===null||i===void 0||i.call(t),[2]}})})}function tw(e){var t={};return e.split(`
|
|
46
|
-
`).forEach(function(n){var r=n.indexOf(":");if(r>-1){var i=n.slice(0,r).trim().toLowerCase(),o=n.slice(r+1).trim();t[i]=o}}),t}function Fy(e,t){if(e.status>=300){var n=function(){try{return JSON.parse(t)}catch{return t}};i0(e,n(),"Response not successful: Received status code ".concat(e.status))}try{return JSON.parse(t)}catch(i){var r=i;throw r.name="ServerParseError",r.response=e,r.statusCode=e.status,r.bodyText=t,r}}function Bh(e,t){var n,r;e.name!=="AbortError"&&(e.result&&e.result.errors&&e.result.data&&((n=t.next)===null||n===void 0||n.call(t,e.result)),(r=t.error)===null||r===void 0||r.call(t,e))}function nw(e,t,n){rw(t)(e).then(function(r){var i,o;(i=n.next)===null||i===void 0||i.call(n,r),(o=n.complete)===null||o===void 0||o.call(n)}).catch(function(r){return Bh(r,n)})}function rw(e){return function(t){return t.text().then(function(n){return Fy(t,n)}).then(function(n){return t.status>=300&&i0(t,n,"Response not successful: Received status code ".concat(t.status)),!Array.isArray(n)&&!d2.call(n,"data")&&!d2.call(n,"errors")&&i0(t,n,"Server response was missing for query '".concat(Array.isArray(e)?e.map(function(r){return r.operationName}):e.operationName,"'.")),n})}}var a0=function(e,t){var n;try{n=JSON.stringify(e)}catch(i){var r=__DEV__?new Se("Network request failed. ".concat(t," is not serializable: ").concat(i.message)):new Se(24);throw r.parseError=i,r}return n},iw={includeQuery:!0,includeExtensions:!1,preserveHeaderCase:!1},ow={accept:"*/*","content-type":"application/json"},aw={method:"POST"},sw={http:iw,headers:ow,options:aw},lw=function(e,t){return t(e)};function cw(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i={},o={};n.forEach(function(d){i=
|
|
46
|
+
`).forEach(function(n){var r=n.indexOf(":");if(r>-1){var i=n.slice(0,r).trim().toLowerCase(),o=n.slice(r+1).trim();t[i]=o}}),t}function Fy(e,t){if(e.status>=300){var n=function(){try{return JSON.parse(t)}catch{return t}};i0(e,n(),"Response not successful: Received status code ".concat(e.status))}try{return JSON.parse(t)}catch(i){var r=i;throw r.name="ServerParseError",r.response=e,r.statusCode=e.status,r.bodyText=t,r}}function Bh(e,t){var n,r;e.name!=="AbortError"&&(e.result&&e.result.errors&&e.result.data&&((n=t.next)===null||n===void 0||n.call(t,e.result)),(r=t.error)===null||r===void 0||r.call(t,e))}function nw(e,t,n){rw(t)(e).then(function(r){var i,o;(i=n.next)===null||i===void 0||i.call(n,r),(o=n.complete)===null||o===void 0||o.call(n)}).catch(function(r){return Bh(r,n)})}function rw(e){return function(t){return t.text().then(function(n){return Fy(t,n)}).then(function(n){return t.status>=300&&i0(t,n,"Response not successful: Received status code ".concat(t.status)),!Array.isArray(n)&&!d2.call(n,"data")&&!d2.call(n,"errors")&&i0(t,n,"Server response was missing for query '".concat(Array.isArray(e)?e.map(function(r){return r.operationName}):e.operationName,"'.")),n})}}var a0=function(e,t){var n;try{n=JSON.stringify(e)}catch(i){var r=__DEV__?new Se("Network request failed. ".concat(t," is not serializable: ").concat(i.message)):new Se(24);throw r.parseError=i,r}return n},iw={includeQuery:!0,includeExtensions:!1,preserveHeaderCase:!1},ow={accept:"*/*","content-type":"application/json"},aw={method:"POST"},sw={http:iw,headers:ow,options:aw},lw=function(e,t){return t(e)};function cw(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i={},o={};n.forEach(function(d){i=T(T(T({},i),d.options),{headers:T(T({},i.headers),d.headers)}),d.credentials&&(i.credentials=d.credentials),o=T(T({},o),d.http)}),i.headers&&(i.headers=uw(i.headers,o.preserveHeaderCase));var a=e.operationName,s=e.extensions,c=e.variables,l=e.query,u={operationName:a,variables:c};return o.includeExtensions&&(u.extensions=s),o.includeQuery&&(u.query=t(l,W$)),{options:i,body:u}}function uw(e,t){if(!t){var n=Object.create(null);return Object.keys(Object(e)).forEach(function(o){n[o.toLowerCase()]=e[o]}),n}var r=Object.create(null);Object.keys(Object(e)).forEach(function(o){r[o.toLowerCase()]={originalName:o,value:e[o]}});var i=Object.create(null);return Object.keys(r).forEach(function(o){i[r[o].originalName]=r[o].value}),i}var dw=function(e){if(!e&&typeof fetch>"u")throw __DEV__?new Se(`
|
|
47
47
|
"fetch" has not been found globally and no fetcher has been configured. To fix this, install a fetch package (like https://www.npmjs.com/package/cross-fetch), instantiate the fetcher, and pass it into your HttpLink constructor. For example:
|
|
48
48
|
|
|
49
49
|
import fetch from 'cross-fetch';
|
|
@@ -51,7 +51,7 @@ import { ApolloClient, HttpLink } from '@apollo/client';
|
|
|
51
51
|
const client = new ApolloClient({
|
|
52
52
|
link: new HttpLink({ uri: '/graphql', fetch })
|
|
53
53
|
});
|
|
54
|
-
`):new Se(23)},fw=function(){if(typeof AbortController>"u")return{controller:!1,signal:!1};var e=new AbortController,t=e.signal;return{controller:e,signal:t}},hw=function(e,t){var n=e.getContext(),r=n.uri;return r||(typeof t=="function"?t(e):t||"/graphql")};function pw(e,t){var n=[],r=function(d,f){n.push("".concat(d,"=").concat(encodeURIComponent(f)))};if("query"in t&&r("query",t.query),t.operationName&&r("operationName",t.operationName),t.variables){var i=void 0;try{i=a0(t.variables,"Variables map")}catch(d){return{parseError:d}}r("variables",i)}if(t.extensions){var o=void 0;try{o=a0(t.extensions,"Extensions map")}catch(d){return{parseError:d}}r("extensions",o)}var a="",s=e,c=e.indexOf("#");c!==-1&&(a=e.substr(c),s=e.substr(0,c));var l=s.indexOf("?")===-1?"?":"&",u=s+l+n.join("&")+a;return{newURI:u}}var f2=en(function(){return fetch}),mw=function(e){e===void 0&&(e={});var t=e.uri,n=t===void 0?"/graphql":t,r=e.fetch,i=e.print,o=i===void 0?lw:i,a=e.includeExtensions,s=e.preserveHeaderCase,c=e.useGETForQueries,l=e.includeUnusedVariables,u=l===void 0?!1:l,d=hr(e,["uri","fetch","print","includeExtensions","preserveHeaderCase","useGETForQueries","includeUnusedVariables"]);__DEV__&&dw(r||f2);var f={http:{includeExtensions:a,preserveHeaderCase:s},options:d.fetchOptions,credentials:d.credentials,headers:d.headers};return new io(function(h){var p=hw(h,n),m=h.getContext(),v={};if(m.clientAwareness){var b=m.clientAwareness,y=b.name,g=b.version;y&&(v["apollographql-client-name"]=y),g&&(v["apollographql-client-version"]=g)}var _=N(N({},v),m.headers),x={http:m.http,options:m.fetchOptions,credentials:m.credentials,headers:_},O=cw(h,o,sw,f,x),C=O.options,M=O.body;if(M.variables&&!u){var D=new Set(Object.keys(M.variables));Wn(h.query,{Variable:function(U,W,de){de&&de.kind!=="VariableDefinition"&&D.delete(U.name.value)}}),D.size&&(M.variables=N({},M.variables),D.forEach(function(U){delete M.variables[U]}))}var F;if(!C.signal){var Y=fw(),J=Y.controller,G=Y.signal;F=J,F&&(C.signal=G)}var j=function(U){return U.kind==="OperationDefinition"&&U.operation==="mutation"};if(c&&!h.query.definitions.some(j)&&(C.method="GET"),Th(["defer"],h.query)&&(C.headers=C.headers||{},C.headers.accept="multipart/mixed; deferSpec=20220824, application/json"),C.method==="GET"){var z=pw(p,M),Q=z.newURI,I=z.parseError;if(I)return l2(I);p=Q}else try{C.body=a0(M,"Payload")}catch(U){return l2(U)}return new Le(function(U){var W=r||en(function(){return fetch})||f2;return W(p,C).then(function(de){var be;h.setContext({response:de});var P=(be=de.headers)===null||be===void 0?void 0:be.get("content-type");return P!==null&&/^multipart\/mixed/i.test(P)?ew(de,U):nw(de,h,U)}).catch(function(de){return Bh(de,U)}),function(){F&&F.abort()}})})},zy=function(e){yn(t,e);function t(n){n===void 0&&(n={});var r=e.call(this,mw(n).request)||this;return r.options=n,r}return t}(io),jy=Object.prototype,h2=jy.toString,vw=jy.hasOwnProperty,p2=Function.prototype.toString,s0=new Map;function ut(e,t){try{return l0(e,t)}finally{s0.clear()}}function l0(e,t){if(e===t)return!0;var n=h2.call(e),r=h2.call(t);if(n!==r)return!1;switch(n){case"[object Array]":if(e.length!==t.length)return!1;case"[object Object]":{if(v2(e,t))return!0;var i=m2(e),o=m2(t),a=i.length;if(a!==o.length)return!1;for(var s=0;s<a;++s)if(!vw.call(t,i[s]))return!1;for(var s=0;s<a;++s){var c=i[s];if(!l0(e[c],t[c]))return!1}return!0}case"[object Error]":return e.name===t.name&&e.message===t.message;case"[object Number]":if(e!==e)return t!==t;case"[object Boolean]":case"[object Date]":return+e==+t;case"[object RegExp]":case"[object String]":return e=="".concat(t);case"[object Map]":case"[object Set]":{if(e.size!==t.size)return!1;if(v2(e,t))return!0;for(var l=e.entries(),u=n==="[object Map]";;){var d=l.next();if(d.done)break;var f=d.value,h=f[0],p=f[1];if(!t.has(h)||u&&!l0(p,t.get(h)))return!1}return!0}case"[object Uint16Array]":case"[object Uint8Array]":case"[object Uint32Array]":case"[object Int32Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object ArrayBuffer]":e=new Uint8Array(e),t=new Uint8Array(t);case"[object DataView]":{var m=e.byteLength;if(m===t.byteLength)for(;m--&&e[m]===t[m];);return m===-1}case"[object AsyncFunction]":case"[object GeneratorFunction]":case"[object AsyncGeneratorFunction]":case"[object Function]":{var v=p2.call(e);return v!==p2.call(t)?!1:!bw(v,yw)}}return!1}function m2(e){return Object.keys(e).filter(gw,e)}function gw(e){return this[e]!==void 0}var yw="{ [native code] }";function bw(e,t){var n=e.length-t.length;return n>=0&&e.indexOf(t,n)===n}function v2(e,t){var n=s0.get(e);if(n){if(n.has(t))return!0}else s0.set(e,n=new Set);return n.add(t),!1}var $w=function(){return Object.create(null)},Vy=Array.prototype,ww=Vy.forEach,_w=Vy.slice,wa=function(){function e(t,n){t===void 0&&(t=!0),n===void 0&&(n=$w),this.weakness=t,this.makeData=n}return e.prototype.lookup=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return this.lookupArray(t)},e.prototype.lookupArray=function(t){var n=this;return ww.call(t,function(r){return n=n.getChildTrie(r)}),n.data||(n.data=this.makeData(_w.call(t)))},e.prototype.getChildTrie=function(t){var n=this.weakness&&xw(t)?this.weak||(this.weak=new WeakMap):this.strong||(this.strong=new Map),r=n.get(t);return r||n.set(t,r=new e(this.weakness,this.makeData)),r},e}();function xw(e){switch(typeof e){case"object":if(e===null)break;case"function":return!0}return!1}var Et=null,g2={},kw=1,Ew=function(){return function(){function e(){this.id=["slot",kw++,Date.now(),Math.random().toString(36).slice(2)].join(":")}return e.prototype.hasValue=function(){for(var t=Et;t;t=t.parent)if(this.id in t.slots){var n=t.slots[this.id];if(n===g2)break;return t!==Et&&(Et.slots[this.id]=n),!0}return Et&&(Et.slots[this.id]=g2),!1},e.prototype.getValue=function(){if(this.hasValue())return Et.slots[this.id]},e.prototype.withValue=function(t,n,r,i){var o,a=(o={__proto__:null},o[this.id]=t,o),s=Et;Et={parent:s,slots:a};try{return n.apply(i,r)}finally{Et=s}},e.bind=function(t){var n=Et;return function(){var r=Et;try{return Et=n,t.apply(this,arguments)}finally{Et=r}}},e.noContext=function(t,n,r){if(Et){var i=Et;try{return Et=null,t.apply(r,n)}finally{Et=i}}else return t.apply(r,n)},e}()};function y2(e){try{return e()}catch{}}var Pu="@wry/context:Slot",Sw=y2(function(){return globalThis})||y2(function(){return global})||Object.create(null),b2=Sw,jc=b2[Pu]||Array[Pu]||function(e){try{Object.defineProperty(b2,Pu,{value:e,enumerable:!1,writable:!1,configurable:!0})}finally{return e}}(Ew());jc.bind;jc.noContext;function Ow(){}var Cw=function(){function e(t,n){t===void 0&&(t=1/0),n===void 0&&(n=Ow),this.max=t,this.dispose=n,this.map=new Map,this.newest=null,this.oldest=null}return e.prototype.has=function(t){return this.map.has(t)},e.prototype.get=function(t){var n=this.getNode(t);return n&&n.value},e.prototype.getNode=function(t){var n=this.map.get(t);if(n&&n!==this.newest){var r=n.older,i=n.newer;i&&(i.older=r),r&&(r.newer=i),n.older=this.newest,n.older.newer=n,n.newer=null,this.newest=n,n===this.oldest&&(this.oldest=i)}return n},e.prototype.set=function(t,n){var r=this.getNode(t);return r?r.value=n:(r={key:t,value:n,newer:null,older:this.newest},this.newest&&(this.newest.newer=r),this.newest=r,this.oldest=this.oldest||r,this.map.set(t,r),r.value)},e.prototype.clean=function(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key)},e.prototype.delete=function(t){var n=this.map.get(t);return n?(n===this.newest&&(this.newest=n.older),n===this.oldest&&(this.oldest=n.newer),n.newer&&(n.newer.older=n.older),n.older&&(n.older.newer=n.newer),this.map.delete(t),this.dispose(n.value,t),!0):!1},e}(),Vc=new jc,Au,Nw=Object.prototype.hasOwnProperty,Hh=(Au=Array.from,Au===void 0?function(e){var t=[];return e.forEach(function(n){return t.push(n)}),t}:Au);function _l(e){var t=e.unsubscribe;typeof t=="function"&&(e.unsubscribe=void 0,t())}var ea=[],Tw=100;function zi(e,t){if(!e)throw new Error(t||"assertion failure")}function Pw(e,t){var n=e.length;return n>0&&n===t.length&&e[n-1]===t[n-1]}function Uy(e){switch(e.length){case 0:throw new Error("unknown value");case 1:return e[0];case 2:throw e[1]}}function Aw(e){return e.slice(0)}var Iw=function(){function e(t){this.fn=t,this.parents=new Set,this.childValues=new Map,this.dirtyChildren=null,this.dirty=!0,this.recomputing=!1,this.value=[],this.deps=null,++e.count}return e.prototype.peek=function(){if(this.value.length===1&&!gr(this))return $2(this),this.value[0]},e.prototype.recompute=function(t){return zi(!this.recomputing,"already recomputing"),$2(this),gr(this)?Mw(this,t):Uy(this.value)},e.prototype.setDirty=function(){this.dirty||(this.dirty=!0,this.value.length=0,By(this),_l(this))},e.prototype.dispose=function(){var t=this;this.setDirty(),Ky(this),qh(this,function(n,r){n.setDirty(),Qy(n,t)})},e.prototype.forget=function(){this.dispose()},e.prototype.dependOn=function(t){t.add(this),this.deps||(this.deps=ea.pop()||new Set),this.deps.add(t)},e.prototype.forgetDeps=function(){var t=this;this.deps&&(Hh(this.deps).forEach(function(n){return n.delete(t)}),this.deps.clear(),ea.push(this.deps),this.deps=null)},e.count=0,e}();function $2(e){var t=Vc.getValue();if(t)return e.parents.add(t),t.childValues.has(e)||t.childValues.set(e,[]),gr(e)?qy(t,e):Wy(t,e),t}function Mw(e,t){return Ky(e),Vc.withValue(e,Dw,[e,t]),Rw(e,t)&&Lw(e),Uy(e.value)}function Dw(e,t){e.recomputing=!0,e.value.length=0;try{e.value[0]=e.fn.apply(null,t)}catch(n){e.value[1]=n}e.recomputing=!1}function gr(e){return e.dirty||!!(e.dirtyChildren&&e.dirtyChildren.size)}function Lw(e){e.dirty=!1,!gr(e)&&Hy(e)}function By(e){qh(e,qy)}function Hy(e){qh(e,Wy)}function qh(e,t){var n=e.parents.size;if(n)for(var r=Hh(e.parents),i=0;i<n;++i)t(r[i],e)}function qy(e,t){zi(e.childValues.has(t)),zi(gr(t));var n=!gr(e);if(!e.dirtyChildren)e.dirtyChildren=ea.pop()||new Set;else if(e.dirtyChildren.has(t))return;e.dirtyChildren.add(t),n&&By(e)}function Wy(e,t){zi(e.childValues.has(t)),zi(!gr(t));var n=e.childValues.get(t);n.length===0?e.childValues.set(t,Aw(t.value)):Pw(n,t.value)||e.setDirty(),Gy(e,t),!gr(e)&&Hy(e)}function Gy(e,t){var n=e.dirtyChildren;n&&(n.delete(t),n.size===0&&(ea.length<Tw&&ea.push(n),e.dirtyChildren=null))}function Ky(e){e.childValues.size>0&&e.childValues.forEach(function(t,n){Qy(e,n)}),e.forgetDeps(),zi(e.dirtyChildren===null)}function Qy(e,t){t.parents.delete(e),e.childValues.delete(t),Gy(e,t)}function Rw(e,t){if(typeof e.subscribe=="function")try{_l(e),e.unsubscribe=e.subscribe.apply(null,t)}catch{return e.setDirty(),!1}return!0}var Fw={setDirty:!0,dispose:!0,forget:!0};function Yy(e){var t=new Map,n=e&&e.subscribe;function r(i){var o=Vc.getValue();if(o){var a=t.get(i);a||t.set(i,a=new Set),o.dependOn(a),typeof n=="function"&&(_l(a),a.unsubscribe=n(i))}}return r.dirty=function(o,a){var s=t.get(o);if(s){var c=a&&Nw.call(Fw,a)?a:"setDirty";Hh(s).forEach(function(l){return l[c]()}),t.delete(o),_l(s)}},r}function Xy(){var e=new wa(typeof WeakMap=="function");return function(){return e.lookupArray(arguments)}}Xy();var Iu=new Set;function xl(e,t){t===void 0&&(t=Object.create(null));var n=new Cw(t.max||Math.pow(2,16),function(l){return l.dispose()}),r=t.keyArgs,i=t.makeCacheKey||Xy(),o=function(){var l=i.apply(null,r?r.apply(null,arguments):arguments);if(l===void 0)return e.apply(null,arguments);var u=n.get(l);u||(n.set(l,u=new Iw(e)),u.subscribe=t.subscribe,u.forget=function(){return n.delete(l)});var d=u.recompute(Array.prototype.slice.call(arguments));return n.set(l,u),Iu.add(n),Vc.hasValue()||(Iu.forEach(function(f){return f.clean()}),Iu.clear()),d};Object.defineProperty(o,"size",{get:function(){return n.map.size},configurable:!1,enumerable:!1});function a(l){var u=n.get(l);u&&u.setDirty()}o.dirtyKey=a,o.dirty=function(){a(i.apply(null,arguments))};function s(l){var u=n.get(l);if(u)return u.peek()}o.peekKey=s,o.peek=function(){return s(i.apply(null,arguments))};function c(l){return n.delete(l)}return o.forgetKey=c,o.forget=function(){return c(i.apply(null,arguments))},o.makeCacheKey=i,o.getKey=r?function(){return i.apply(null,r.apply(null,arguments))}:i,Object.freeze(o)}var zw=function(){function e(){this.getFragmentDoc=xl(e9)}return e.prototype.batch=function(t){var n=this,r=typeof t.optimistic=="string"?t.optimistic:t.optimistic===!1?null:void 0,i;return this.performTransaction(function(){return i=t.update(n)},r),i},e.prototype.recordOptimisticTransaction=function(t,n){this.performTransaction(t,n)},e.prototype.transformDocument=function(t){return t},e.prototype.transformForLink=function(t){return t},e.prototype.identify=function(t){},e.prototype.gc=function(){return[]},e.prototype.modify=function(t){return!1},e.prototype.readQuery=function(t,n){return n===void 0&&(n=!!t.optimistic),this.read(N(N({},t),{rootId:t.id||"ROOT_QUERY",optimistic:n}))},e.prototype.readFragment=function(t,n){return n===void 0&&(n=!!t.optimistic),this.read(N(N({},t),{query:this.getFragmentDoc(t.fragment,t.fragmentName),rootId:t.id,optimistic:n}))},e.prototype.writeQuery=function(t){var n=t.id,r=t.data,i=hr(t,["id","data"]);return this.write(Object.assign(i,{dataId:n||"ROOT_QUERY",result:r}))},e.prototype.writeFragment=function(t){var n=t.id,r=t.data,i=t.fragment,o=t.fragmentName,a=hr(t,["id","data","fragment","fragmentName"]);return this.write(Object.assign(a,{query:this.getFragmentDoc(i,o),dataId:n,result:r}))},e.prototype.updateQuery=function(t,n){return this.batch({update:function(r){var i=r.readQuery(t),o=n(i);return o==null?i:(r.writeQuery(N(N({},t),{data:o})),o)}})},e.prototype.updateFragment=function(t,n){return this.batch({update:function(r){var i=r.readFragment(t),o=n(i);return o==null?i:(r.writeFragment(N(N({},t),{data:o})),o)}})},e}(),Zy=function(e){yn(t,e);function t(n,r,i,o){var a,s=e.call(this,n)||this;if(s.message=n,s.path=r,s.query=i,s.variables=o,Array.isArray(s.path)){s.missing=s.message;for(var c=s.path.length-1;c>=0;--c)s.missing=(a={},a[s.path[c]]=s.missing,a)}else s.missing=s.path;return s.__proto__=t.prototype,s}return t}(Error),vt=Object.prototype.hasOwnProperty;function _o(e){return e==null}function Jy(e,t){var n=e.__typename,r=e.id,i=e._id;if(typeof n=="string"&&(t&&(t.keyObject=_o(r)?_o(i)?void 0:{_id:i}:{id:r}),_o(r)&&!_o(i)&&(r=i),!_o(r)))return"".concat(n,":").concat(typeof r=="number"||typeof r=="string"?r:JSON.stringify(r))}var e3={dataIdFromObject:Jy,addTypename:!0,resultCaching:!0,canonizeResults:!1};function jw(e){return zc(e3,e)}function t3(e){var t=e.canonizeResults;return t===void 0?e3.canonizeResults:t}function Vw(e,t){return Pe(t)?e.get(t.__ref,"__typename"):t&&t.__typename}var n3=/^[_a-z][_0-9a-z]*/i;function yr(e){var t=e.match(n3);return t?t[0]:e}function c0(e,t,n){return Ye(t)?Xe(t)?t.every(function(r){return c0(e,r,n)}):e.selections.every(function(r){if(Gr(r)&&Dc(r,n)){var i=Wr(r);return vt.call(t,i)&&(!r.selectionSet||c0(r.selectionSet,t[i],n))}return!0}):!1}function wi(e){return Ye(e)&&!Pe(e)&&!Xe(e)}function Uw(){return new vr}function r3(e,t){var n=Ph(Mh(e));return{fragmentMap:n,lookupFragment:function(r){var i=n[r];return!i&&t&&(i=t.lookup(r)),i||null}}}var hs=Object.create(null),Mu=function(){return hs},w2=Object.create(null),ta=function(){function e(t,n){var r=this;this.policies=t,this.group=n,this.data=Object.create(null),this.rootIds=Object.create(null),this.refs=Object.create(null),this.getFieldValue=function(i,o){return t0(Pe(i)?r.get(i.__ref,o):i&&i[o])},this.canRead=function(i){return Pe(i)?r.has(i.__ref):typeof i=="object"},this.toReference=function(i,o){if(typeof i=="string")return Si(i);if(Pe(i))return i;var a=r.policies.identify(i)[0];if(a){var s=Si(a);return o&&r.merge(a,i),s}}}return e.prototype.toObject=function(){return N({},this.data)},e.prototype.has=function(t){return this.lookup(t,!0)!==void 0},e.prototype.get=function(t,n){if(this.group.depend(t,n),vt.call(this.data,t)){var r=this.data[t];if(r&&vt.call(r,n))return r[n]}if(n==="__typename"&&vt.call(this.policies.rootTypenamesById,t))return this.policies.rootTypenamesById[t];if(this instanceof er)return this.parent.get(t,n)},e.prototype.lookup=function(t,n){if(n&&this.group.depend(t,"__exists"),vt.call(this.data,t))return this.data[t];if(this instanceof er)return this.parent.lookup(t,n);if(this.policies.rootTypenamesById[t])return Object.create(null)},e.prototype.merge=function(t,n){var r=this,i;Pe(t)&&(t=t.__ref),Pe(n)&&(n=n.__ref);var o=typeof t=="string"?this.lookup(i=t):t,a=typeof n=="string"?this.lookup(i=n):n;if(!!a){__DEV__?K(typeof i=="string","store.merge expects a string ID"):K(typeof i=="string",1);var s=new vr(Hw).merge(o,a);if(this.data[i]=s,s!==o&&(delete this.refs[i],this.group.caching)){var c=Object.create(null);o||(c.__exists=1),Object.keys(a).forEach(function(l){if(!o||o[l]!==s[l]){c[l]=1;var u=yr(l);u!==l&&!r.policies.hasKeyArgs(s.__typename,u)&&(c[u]=1),s[l]===void 0&&!(r instanceof er)&&delete s[l]}}),c.__typename&&!(o&&o.__typename)&&this.policies.rootTypenamesById[i]===s.__typename&&delete c.__typename,Object.keys(c).forEach(function(l){return r.group.dirty(i,l)})}}},e.prototype.modify=function(t,n){var r=this,i=this.lookup(t);if(i){var o=Object.create(null),a=!1,s=!0,c={DELETE:hs,INVALIDATE:w2,isReference:Pe,toReference:this.toReference,canRead:this.canRead,readField:function(l,u){return r.policies.readField(typeof l=="string"?{fieldName:l,from:u||Si(t)}:l,{store:r})}};if(Object.keys(i).forEach(function(l){var u=yr(l),d=i[l];if(d!==void 0){var f=typeof n=="function"?n:n[l]||n[u];if(f){var h=f===Mu?hs:f(t0(d),N(N({},c),{fieldName:u,storeFieldName:l,storage:r.getStorage(t,l)}));h===w2?r.group.dirty(t,l):(h===hs&&(h=void 0),h!==d&&(o[l]=h,a=!0,d=h))}d!==void 0&&(s=!1)}}),a)return this.merge(t,o),s&&(this instanceof er?this.data[t]=void 0:delete this.data[t],this.group.dirty(t,"__exists")),!0}return!1},e.prototype.delete=function(t,n,r){var i,o=this.lookup(t);if(o){var a=this.getFieldValue(o,"__typename"),s=n&&r?this.policies.getStoreFieldName({typename:a,fieldName:n,args:r}):n;return this.modify(t,s?(i={},i[s]=Mu,i):Mu)}return!1},e.prototype.evict=function(t,n){var r=!1;return t.id&&(vt.call(this.data,t.id)&&(r=this.delete(t.id,t.fieldName,t.args)),this instanceof er&&this!==n&&(r=this.parent.evict(t,n)||r),(t.fieldName||r)&&this.group.dirty(t.id,t.fieldName||"__exists")),r},e.prototype.clear=function(){this.replace(null)},e.prototype.extract=function(){var t=this,n=this.toObject(),r=[];return this.getRootIdSet().forEach(function(i){vt.call(t.policies.rootTypenamesById,i)||r.push(i)}),r.length&&(n.__META={extraRootIds:r.sort()}),n},e.prototype.replace=function(t){var n=this;if(Object.keys(this.data).forEach(function(o){t&&vt.call(t,o)||n.delete(o)}),t){var r=t.__META,i=hr(t,["__META"]);Object.keys(i).forEach(function(o){n.merge(o,i[o])}),r&&r.extraRootIds.forEach(this.retain,this)}},e.prototype.retain=function(t){return this.rootIds[t]=(this.rootIds[t]||0)+1},e.prototype.release=function(t){if(this.rootIds[t]>0){var n=--this.rootIds[t];return n||delete this.rootIds[t],n}return 0},e.prototype.getRootIdSet=function(t){return t===void 0&&(t=new Set),Object.keys(this.rootIds).forEach(t.add,t),this instanceof er?this.parent.getRootIdSet(t):Object.keys(this.policies.rootTypenamesById).forEach(t.add,t),t},e.prototype.gc=function(){var t=this,n=this.getRootIdSet(),r=this.toObject();n.forEach(function(a){vt.call(r,a)&&(Object.keys(t.findChildRefIds(a)).forEach(n.add,n),delete r[a])});var i=Object.keys(r);if(i.length){for(var o=this;o instanceof er;)o=o.parent;i.forEach(function(a){return o.delete(a)})}return i},e.prototype.findChildRefIds=function(t){if(!vt.call(this.refs,t)){var n=this.refs[t]=Object.create(null),r=this.data[t];if(!r)return n;var i=new Set([r]);i.forEach(function(o){Pe(o)&&(n[o.__ref]=!0),Ye(o)&&Object.keys(o).forEach(function(a){var s=o[a];Ye(s)&&i.add(s)})})}return this.refs[t]},e.prototype.makeCacheKey=function(){return this.group.keyMaker.lookupArray(arguments)},e}(),i3=function(){function e(t,n){n===void 0&&(n=null),this.caching=t,this.parent=n,this.d=null,this.resetCaching()}return e.prototype.resetCaching=function(){this.d=this.caching?Yy():null,this.keyMaker=new wa(ti)},e.prototype.depend=function(t,n){if(this.d){this.d(Du(t,n));var r=yr(n);r!==n&&this.d(Du(t,r)),this.parent&&this.parent.depend(t,n)}},e.prototype.dirty=function(t,n){this.d&&this.d.dirty(Du(t,n),n==="__exists"?"forget":"setDirty")},e}();function Du(e,t){return t+"#"+e}function _2(e,t){Uo(e)&&e.group.depend(t,"__exists")}(function(e){var t=function(n){yn(r,n);function r(i){var o=i.policies,a=i.resultCaching,s=a===void 0?!0:a,c=i.seed,l=n.call(this,o,new i3(s))||this;return l.stump=new Bw(l),l.storageTrie=new wa(ti),c&&l.replace(c),l}return r.prototype.addLayer=function(i,o){return this.stump.addLayer(i,o)},r.prototype.removeLayer=function(){return this},r.prototype.getStorage=function(){return this.storageTrie.lookupArray(arguments)},r}(e);e.Root=t})(ta||(ta={}));var er=function(e){yn(t,e);function t(n,r,i,o){var a=e.call(this,r.policies,o)||this;return a.id=n,a.parent=r,a.replay=i,a.group=o,i(a),a}return t.prototype.addLayer=function(n,r){return new t(n,this,r,this.group)},t.prototype.removeLayer=function(n){var r=this,i=this.parent.removeLayer(n);return n===this.id?(this.group.caching&&Object.keys(this.data).forEach(function(o){var a=r.data[o],s=i.lookup(o);s?a?a!==s&&Object.keys(a).forEach(function(c){ut(a[c],s[c])||r.group.dirty(o,c)}):(r.group.dirty(o,"__exists"),Object.keys(s).forEach(function(c){r.group.dirty(o,c)})):r.delete(o)}),i):i===this.parent?this:i.addLayer(this.id,this.replay)},t.prototype.toObject=function(){return N(N({},this.parent.toObject()),this.data)},t.prototype.findChildRefIds=function(n){var r=this.parent.findChildRefIds(n);return vt.call(this.data,n)?N(N({},r),e.prototype.findChildRefIds.call(this,n)):r},t.prototype.getStorage=function(){for(var n=this.parent;n.parent;)n=n.parent;return n.getStorage.apply(n,arguments)},t}(ta),Bw=function(e){yn(t,e);function t(n){return e.call(this,"EntityStore.Stump",n,function(){},new i3(n.group.caching,n.group))||this}return t.prototype.removeLayer=function(){return this},t.prototype.merge=function(){return this.parent.merge.apply(this.parent,arguments)},t}(er);function Hw(e,t,n){var r=e[n],i=t[n];return ut(r,i)?r:i}function Uo(e){return!!(e instanceof ta&&e.group.caching)}function qw(e){return Ye(e)?Xe(e)?e.slice(0):N({__proto__:Object.getPrototypeOf(e)},e):e}var u0=function(){function e(){this.known=new(D9?WeakSet:Set),this.pool=new wa(ti),this.passes=new WeakMap,this.keysByJSON=new Map,this.empty=this.admit({})}return e.prototype.isKnown=function(t){return Ye(t)&&this.known.has(t)},e.prototype.pass=function(t){if(Ye(t)){var n=qw(t);return this.passes.set(n,t),n}return t},e.prototype.admit=function(t){var n=this;if(Ye(t)){var r=this.passes.get(t);if(r)return r;var i=Object.getPrototypeOf(t);switch(i){case Array.prototype:{if(this.known.has(t))return t;var o=t.map(this.admit,this),a=this.pool.lookupArray(o);return a.array||(this.known.add(a.array=o),__DEV__&&Object.freeze(o)),a.array}case null:case Object.prototype:{if(this.known.has(t))return t;var s=Object.getPrototypeOf(t),c=[s],l=this.sortedKeys(t);c.push(l.json);var u=c.length;l.sorted.forEach(function(h){c.push(n.admit(t[h]))});var a=this.pool.lookupArray(c);if(!a.object){var d=a.object=Object.create(s);this.known.add(d),l.sorted.forEach(function(h,p){d[h]=c[u+p]}),__DEV__&&Object.freeze(d)}return a.object}}}return t},e.prototype.sortedKeys=function(t){var n=Object.keys(t),r=this.pool.lookupArray(n);if(!r.keys){n.sort();var i=JSON.stringify(n);(r.keys=this.keysByJSON.get(i))||this.keysByJSON.set(i,r.keys={sorted:n,json:i})}return r.keys},e}(),jr=Object.assign(function(e){if(Ye(e)){d0===void 0&&x2();var t=d0.admit(e),n=f0.get(t);return n===void 0&&f0.set(t,n=JSON.stringify(t)),n}return JSON.stringify(e)},{reset:x2}),d0,f0;function x2(){d0=new u0,f0=new(ti?WeakMap:Map)}function k2(e){return[e.selectionSet,e.objectOrReference,e.context,e.context.canonizeResults]}var Ww=function(){function e(t){var n=this;this.knownResults=new(ti?WeakMap:Map),this.config=zc(t,{addTypename:t.addTypename!==!1,canonizeResults:t3(t)}),this.canon=t.canon||new u0,this.executeSelectionSet=xl(function(r){var i,o=r.context.canonizeResults,a=k2(r);a[3]=!o;var s=(i=n.executeSelectionSet).peek.apply(i,a);return s?o?N(N({},s),{result:n.canon.admit(s.result)}):s:(_2(r.context.store,r.enclosingRef.__ref),n.execSelectionSetImpl(r))},{max:this.config.resultCacheMaxSize,keyArgs:k2,makeCacheKey:function(r,i,o,a){if(Uo(o.store))return o.store.makeCacheKey(r,Pe(i)?i.__ref:i,o.varString,a)}}),this.executeSubSelectedArray=xl(function(r){return _2(r.context.store,r.enclosingRef.__ref),n.execSubSelectedArrayImpl(r)},{max:this.config.resultCacheMaxSize,makeCacheKey:function(r){var i=r.field,o=r.array,a=r.context;if(Uo(a.store))return a.store.makeCacheKey(i,o,a.varString)}})}return e.prototype.resetCanon=function(){this.canon=new u0},e.prototype.diffQueryAgainstStore=function(t){var n=t.store,r=t.query,i=t.rootId,o=i===void 0?"ROOT_QUERY":i,a=t.variables,s=t.returnPartialData,c=s===void 0?!0:s,l=t.canonizeResults,u=l===void 0?this.config.canonizeResults:l,d=this.config.cache.policies;a=N(N({},Lh(Cy(r))),a);var f=Si(o),h=this.executeSelectionSet({selectionSet:Dh(r).selectionSet,objectOrReference:f,enclosingRef:f,context:N({store:n,query:r,policies:d,variables:a,varString:jr(a),canonizeResults:u},r3(r,this.config.fragments))}),p;if(h.missing&&(p=[new Zy(Gw(h.missing),h.missing,r,a)],!c))throw p[0];return{result:h.result,complete:!p,missing:p}},e.prototype.isFresh=function(t,n,r,i){if(Uo(i.store)&&this.knownResults.get(t)===r){var o=this.executeSelectionSet.peek(r,n,i,this.canon.isKnown(t));if(o&&t===o.result)return!0}return!1},e.prototype.execSelectionSetImpl=function(t){var n=this,r=t.selectionSet,i=t.objectOrReference,o=t.enclosingRef,a=t.context;if(Pe(i)&&!a.policies.rootTypenamesById[i.__ref]&&!a.store.has(i.__ref))return{result:this.canon.empty,missing:"Dangling reference to missing ".concat(i.__ref," object")};var s=a.variables,c=a.policies,l=a.store,u=l.getFieldValue(i,"__typename"),d=[],f,h=new vr;this.config.addTypename&&typeof u=="string"&&!c.rootIdsByTypename[u]&&d.push({__typename:u});function p(g,_){var x;return g.missing&&(f=h.merge(f,(x={},x[_]=g.missing,x))),g.result}var m=new Set(r.selections);m.forEach(function(g){var _,x;if(!!Dc(g,s))if(Gr(g)){var O=c.readField({fieldName:g.name.value,field:g,variables:a.variables,from:i},a),C=Wr(g);O===void 0?Rh.added(g)||(f=h.merge(f,(_={},_[C]="Can't find field '".concat(g.name.value,"' on ").concat(Pe(i)?i.__ref+" object":"object "+JSON.stringify(i,null,2)),_))):Xe(O)?O=p(n.executeSubSelectedArray({field:g,array:O,enclosingRef:o,context:a}),C):g.selectionSet?O!=null&&(O=p(n.executeSelectionSet({selectionSet:g.selectionSet,objectOrReference:O,enclosingRef:Pe(O)?O:o,context:a}),C)):a.canonizeResults&&(O=n.canon.pass(O)),O!==void 0&&d.push((x={},x[C]=O,x))}else{var M=Ah(g,a.lookupFragment);if(!M&&g.kind===X.FRAGMENT_SPREAD)throw __DEV__?new Se("No fragment named ".concat(g.name.value)):new Se(5);M&&c.fragmentMatches(M,u)&&M.selectionSet.selections.forEach(m.add,m)}});var v=Fh(d),b={result:v,missing:f},y=a.canonizeResults?this.canon.admit(b):t0(b);return y.result&&this.knownResults.set(y.result,r),y},e.prototype.execSubSelectedArrayImpl=function(t){var n=this,r=t.field,i=t.array,o=t.enclosingRef,a=t.context,s,c=new vr;function l(u,d){var f;return u.missing&&(s=c.merge(s,(f={},f[d]=u.missing,f))),u.result}return r.selectionSet&&(i=i.filter(a.store.canRead)),i=i.map(function(u,d){return u===null?null:Xe(u)?l(n.executeSubSelectedArray({field:r,array:u,enclosingRef:o,context:a}),d):r.selectionSet?l(n.executeSelectionSet({selectionSet:r.selectionSet,objectOrReference:u,enclosingRef:Pe(u)?u:o,context:a}),d):(__DEV__&&Kw(a.store,r,u),u)}),{result:a.canonizeResults?this.canon.admit(i):i,missing:s}},e}();function Gw(e){try{JSON.stringify(e,function(t,n){if(typeof n=="string")throw n;return n})}catch(t){return t}}function Kw(e,t,n){if(!t.selectionSet){var r=new Set([n]);r.forEach(function(i){Ye(i)&&(__DEV__?K(!Pe(i),"Missing selection set for object of type ".concat(Vw(e,i)," returned for query field ").concat(t.name.value)):K(!Pe(i),6),Object.values(i).forEach(r.add,r))})}}var Wh=new jc,E2=new WeakMap;function Bo(e){var t=E2.get(e);return t||E2.set(e,t={vars:new Set,dep:Yy()}),t}function S2(e){Bo(e).vars.forEach(function(t){return t.forgetCache(e)})}function Qw(e){Bo(e).vars.forEach(function(t){return t.attachCache(e)})}function Yw(e){var t=new Set,n=new Set,r=function(o){if(arguments.length>0){if(e!==o){e=o,t.forEach(function(c){Bo(c).dep.dirty(r),Xw(c)});var a=Array.from(n);n.clear(),a.forEach(function(c){return c(e)})}}else{var s=Wh.getValue();s&&(i(s),Bo(s).dep(r))}return e};r.onNextChange=function(o){return n.add(o),function(){n.delete(o)}};var i=r.attachCache=function(o){return t.add(o),Bo(o).vars.add(r),r};return r.forgetCache=function(o){return t.delete(o)},r}function Xw(e){e.broadcastWatches&&e.broadcastWatches()}var O2=Object.create(null);function Gh(e){var t=JSON.stringify(e);return O2[t]||(O2[t]=Object.create(null))}function C2(e){var t=Gh(e);return t.keyFieldsFn||(t.keyFieldsFn=function(n,r){var i=function(a,s){return r.readField(s,a)},o=r.keyObject=Kh(e,function(a){var s=Ci(r.storeObject,a,i);return s===void 0&&n!==r.storeObject&&vt.call(n,a[0])&&(s=Ci(n,a,a3)),__DEV__?K(s!==void 0,"Missing field '".concat(a.join("."),"' while extracting keyFields from ").concat(JSON.stringify(n))):K(s!==void 0,2),s});return"".concat(r.typename,":").concat(JSON.stringify(o))})}function N2(e){var t=Gh(e);return t.keyArgsFn||(t.keyArgsFn=function(n,r){var i=r.field,o=r.variables,a=r.fieldName,s=Kh(e,function(l){var u=l[0],d=u.charAt(0);if(d==="@"){if(i&&rn(i.directives)){var f=u.slice(1),h=i.directives.find(function(b){return b.name.value===f}),p=h&&Lc(h,o);return p&&Ci(p,l.slice(1))}return}if(d==="$"){var m=u.slice(1);if(o&&vt.call(o,m)){var v=l.slice(0);return v[0]=m,Ci(o,v)}return}if(n)return Ci(n,l)}),c=JSON.stringify(s);return(n||c!=="{}")&&(a+=":"+c),a})}function Kh(e,t){var n=new vr;return o3(e).reduce(function(r,i){var o,a=t(i);if(a!==void 0){for(var s=i.length-1;s>=0;--s)a=(o={},o[i[s]]=a,o);r=n.merge(r,a)}return r},Object.create(null))}function o3(e){var t=Gh(e);if(!t.paths){var n=t.paths=[],r=[];e.forEach(function(i,o){Xe(i)?(o3(i).forEach(function(a){return n.push(r.concat(a))}),r.length=0):(r.push(i),Xe(e[o+1])||(n.push(r.slice(0)),r.length=0))})}return t.paths}function a3(e,t){return e[t]}function Ci(e,t,n){return n=n||a3,s3(t.reduce(function r(i,o){return Xe(i)?i.map(function(a){return r(a,o)}):i&&n(i,o)},e))}function s3(e){return Ye(e)?Xe(e)?e.map(s3):Kh(Object.keys(e).sort(),function(t){return Ci(e,t)}):e}Ih.setStringify(jr);function h0(e){return e.args!==void 0?e.args:e.field?Lc(e.field,e.variables):null}var Zw=function(){},T2=function(e,t){return t.fieldName},P2=function(e,t,n){var r=n.mergeObjects;return r(e,t)},A2=function(e,t){return t},Jw=function(){function e(t){this.config=t,this.typePolicies=Object.create(null),this.toBeAdded=Object.create(null),this.supertypeMap=new Map,this.fuzzySubtypes=new Map,this.rootIdsByTypename=Object.create(null),this.rootTypenamesById=Object.create(null),this.usingPossibleTypes=!1,this.config=N({dataIdFromObject:Jy},t),this.cache=this.config.cache,this.setRootTypename("Query"),this.setRootTypename("Mutation"),this.setRootTypename("Subscription"),t.possibleTypes&&this.addPossibleTypes(t.possibleTypes),t.typePolicies&&this.addTypePolicies(t.typePolicies)}return e.prototype.identify=function(t,n){var r,i=this,o=n&&(n.typename||((r=n.storeObject)===null||r===void 0?void 0:r.__typename))||t.__typename;if(o===this.rootTypenamesById.ROOT_QUERY)return["ROOT_QUERY"];for(var a=n&&n.storeObject||t,s=N(N({},n),{typename:o,storeObject:a,readField:n&&n.readField||function(){var f=Qh(arguments,a);return i.readField(f,{store:i.cache.data,variables:f.variables})}}),c,l=o&&this.getTypePolicy(o),u=l&&l.keyFn||this.config.dataIdFromObject;u;){var d=u(t,s);if(Xe(d))u=C2(d);else{c=d;break}}return c=c?String(c):void 0,s.keyObject?[c,s.keyObject]:[c]},e.prototype.addTypePolicies=function(t){var n=this;Object.keys(t).forEach(function(r){var i=t[r],o=i.queryType,a=i.mutationType,s=i.subscriptionType,c=hr(i,["queryType","mutationType","subscriptionType"]);o&&n.setRootTypename("Query",r),a&&n.setRootTypename("Mutation",r),s&&n.setRootTypename("Subscription",r),vt.call(n.toBeAdded,r)?n.toBeAdded[r].push(c):n.toBeAdded[r]=[c]})},e.prototype.updateTypePolicy=function(t,n){var r=this,i=this.getTypePolicy(t),o=n.keyFields,a=n.fields;function s(c,l){c.merge=typeof l=="function"?l:l===!0?P2:l===!1?A2:c.merge}s(i,n.merge),i.keyFn=o===!1?Zw:Xe(o)?C2(o):typeof o=="function"?o:i.keyFn,a&&Object.keys(a).forEach(function(c){var l=r.getFieldPolicy(t,c,!0),u=a[c];if(typeof u=="function")l.read=u;else{var d=u.keyArgs,f=u.read,h=u.merge;l.keyFn=d===!1?T2:Xe(d)?N2(d):typeof d=="function"?d:l.keyFn,typeof f=="function"&&(l.read=f),s(l,h)}l.read&&l.merge&&(l.keyFn=l.keyFn||T2)})},e.prototype.setRootTypename=function(t,n){n===void 0&&(n=t);var r="ROOT_"+t.toUpperCase(),i=this.rootTypenamesById[r];n!==i&&(__DEV__?K(!i||i===t,"Cannot change root ".concat(t," __typename more than once")):K(!i||i===t,3),i&&delete this.rootIdsByTypename[i],this.rootIdsByTypename[n]=r,this.rootTypenamesById[r]=n)},e.prototype.addPossibleTypes=function(t){var n=this;this.usingPossibleTypes=!0,Object.keys(t).forEach(function(r){n.getSupertypeSet(r,!0),t[r].forEach(function(i){n.getSupertypeSet(i,!0).add(r);var o=i.match(n3);(!o||o[0]!==i)&&n.fuzzySubtypes.set(i,new RegExp(i))})})},e.prototype.getTypePolicy=function(t){var n=this;if(!vt.call(this.typePolicies,t)){var r=this.typePolicies[t]=Object.create(null);r.fields=Object.create(null);var i=this.supertypeMap.get(t);i&&i.size&&i.forEach(function(a){var s=n.getTypePolicy(a),c=s.fields,l=hr(s,["fields"]);Object.assign(r,l),Object.assign(r.fields,c)})}var o=this.toBeAdded[t];return o&&o.length&&o.splice(0).forEach(function(a){n.updateTypePolicy(t,a)}),this.typePolicies[t]},e.prototype.getFieldPolicy=function(t,n,r){if(t){var i=this.getTypePolicy(t).fields;return i[n]||r&&(i[n]=Object.create(null))}},e.prototype.getSupertypeSet=function(t,n){var r=this.supertypeMap.get(t);return!r&&n&&this.supertypeMap.set(t,r=new Set),r},e.prototype.fragmentMatches=function(t,n,r,i){var o=this;if(!t.typeCondition)return!0;if(!n)return!1;var a=t.typeCondition.name.value;if(n===a)return!0;if(this.usingPossibleTypes&&this.supertypeMap.has(a))for(var s=this.getSupertypeSet(n,!0),c=[s],l=function(p){var m=o.getSupertypeSet(p,!1);m&&m.size&&c.indexOf(m)<0&&c.push(m)},u=!!(r&&this.fuzzySubtypes.size),d=!1,f=0;f<c.length;++f){var h=c[f];if(h.has(a))return s.has(a)||(d&&__DEV__&&K.warn("Inferring subtype ".concat(n," of supertype ").concat(a)),s.add(a)),!0;h.forEach(l),u&&f===c.length-1&&c0(t.selectionSet,r,i)&&(u=!1,d=!0,this.fuzzySubtypes.forEach(function(p,m){var v=n.match(p);v&&v[0]===n&&l(m)}))}return!1},e.prototype.hasKeyArgs=function(t,n){var r=this.getFieldPolicy(t,n,!1);return!!(r&&r.keyFn)},e.prototype.getStoreFieldName=function(t){var n=t.typename,r=t.fieldName,i=this.getFieldPolicy(n,r,!1),o,a=i&&i.keyFn;if(a&&n)for(var s={typename:n,fieldName:r,field:t.field||null,variables:t.variables},c=h0(t);a;){var l=a(c,s);if(Xe(l))a=N2(l);else{o=l||r;break}}return o===void 0&&(o=t.field?d9(t.field,t.variables):Ih(r,h0(t))),o===!1?r:r===yr(o)?o:r+":"+o},e.prototype.readField=function(t,n){var r=t.from;if(!!r){var i=t.field||t.fieldName;if(!!i){if(t.typename===void 0){var o=n.store.getFieldValue(r,"__typename");o&&(t.typename=o)}var a=this.getStoreFieldName(t),s=yr(a),c=n.store.getFieldValue(r,a),l=this.getFieldPolicy(t.typename,s,!1),u=l&&l.read;if(u){var d=I2(this,r,t,n,n.store.getStorage(Pe(r)?r.__ref:r,a));return Wh.withValue(this.cache,u,[c,d])}return c}}},e.prototype.getReadFunction=function(t,n){var r=this.getFieldPolicy(t,n,!1);return r&&r.read},e.prototype.getMergeFunction=function(t,n,r){var i=this.getFieldPolicy(t,n,!1),o=i&&i.merge;return!o&&r&&(i=this.getTypePolicy(r),o=i&&i.merge),o},e.prototype.runMergeFunction=function(t,n,r,i,o){var a=r.field,s=r.typename,c=r.merge;return c===P2?l3(i.store)(t,n):c===A2?n:(i.overwrite&&(t=void 0),c(t,n,I2(this,void 0,{typename:s,fieldName:a.name.value,field:a,variables:i.variables},i,o||Object.create(null))))},e}();function I2(e,t,n,r,i){var o=e.getStoreFieldName(n),a=yr(o),s=n.variables||r.variables,c=r.store,l=c.toReference,u=c.canRead;return{args:h0(n),field:n.field||null,fieldName:a,storeFieldName:o,variables:s,isReference:Pe,toReference:l,storage:i,cache:e.cache,canRead:u,readField:function(){return e.readField(Qh(arguments,t,s),r)},mergeObjects:l3(r.store)}}function Qh(e,t,n){var r=e[0],i=e[1],o=e.length,a;return typeof r=="string"?a={fieldName:r,from:o>1?i:t}:(a=N({},r),vt.call(a,"from")||(a.from=t)),__DEV__&&a.from===void 0&&__DEV__&&K.warn("Undefined 'from' passed to readField with arguments ".concat(F9(Array.from(e)))),a.variables===void 0&&(a.variables=n),a}function l3(e){return function(n,r){if(Xe(n)||Xe(r))throw __DEV__?new Se("Cannot automatically merge arrays"):new Se(4);if(Ye(n)&&Ye(r)){var i=e.getFieldValue(n,"__typename"),o=e.getFieldValue(r,"__typename"),a=i&&o&&i!==o;if(a)return r;if(Pe(n)&&wi(r))return e.merge(n.__ref,r),n;if(wi(n)&&Pe(r))return e.merge(n,r.__ref),r;if(wi(n)&&wi(r))return N(N({},n),r)}return r}}function Lu(e,t,n){var r="".concat(t).concat(n),i=e.flavors.get(r);return i||e.flavors.set(r,i=e.clientOnly===t&&e.deferred===n?e:N(N({},e),{clientOnly:t,deferred:n})),i}var e_=function(){function e(t,n,r){this.cache=t,this.reader=n,this.fragments=r}return e.prototype.writeToStore=function(t,n){var r=this,i=n.query,o=n.result,a=n.dataId,s=n.variables,c=n.overwrite,l=$a(i),u=Uw();s=N(N({},Lh(l)),s);var d=N(N({store:t,written:Object.create(null),merge:function(h,p){return u.merge(h,p)},variables:s,varString:jr(s)},r3(i,this.fragments)),{overwrite:!!c,incomingById:new Map,clientOnly:!1,deferred:!1,flavors:new Map}),f=this.processSelectionSet({result:o||Object.create(null),dataId:a,selectionSet:l.selectionSet,mergeTree:{map:new Map},context:d});if(!Pe(f))throw __DEV__?new Se("Could not identify object ".concat(JSON.stringify(o))):new Se(7);return d.incomingById.forEach(function(h,p){var m=h.storeObject,v=h.mergeTree,b=h.fieldNodeSet,y=Si(p);if(v&&v.map.size){var g=r.applyMerges(v,y,m,d);if(Pe(g))return;m=g}if(__DEV__&&!d.overwrite){var _=Object.create(null);b.forEach(function(C){C.selectionSet&&(_[C.name.value]=!0)});var x=function(C){return _[yr(C)]===!0},O=function(C){var M=v&&v.map.get(C);return Boolean(M&&M.info&&M.info.merge)};Object.keys(m).forEach(function(C){x(C)&&!O(C)&&t_(y,m,C,d.store)})}t.merge(p,m)}),t.retain(f.__ref),f},e.prototype.processSelectionSet=function(t){var n=this,r=t.dataId,i=t.result,o=t.selectionSet,a=t.context,s=t.mergeTree,c=this.cache.policies,l=Object.create(null),u=r&&c.rootTypenamesById[r]||Yd(i,o,a.fragmentMap)||r&&a.store.get(r,"__typename");typeof u=="string"&&(l.__typename=u);var d=function(){var g=Qh(arguments,l,a.variables);if(Pe(g.from)){var _=a.incomingById.get(g.from.__ref);if(_){var x=c.readField(N(N({},g),{from:_.storeObject}),a);if(x!==void 0)return x}}return c.readField(g,a)},f=new Set;this.flattenFields(o,i,a,u).forEach(function(g,_){var x,O=Wr(_),C=i[O];if(f.add(_),C!==void 0){var M=c.getStoreFieldName({typename:u,fieldName:_.name.value,field:_,variables:g.variables}),D=M2(s,M),F=n.processFieldValue(C,_,_.selectionSet?Lu(g,!1,!1):g,D),Y=void 0;_.selectionSet&&(Pe(F)||wi(F))&&(Y=d("__typename",F));var J=c.getMergeFunction(u,_.name.value,Y);J?D.info={field:_,typename:u,merge:J}:D2(s,M),l=g.merge(l,(x={},x[M]=F,x))}else __DEV__&&!g.clientOnly&&!g.deferred&&!Rh.added(_)&&!c.getReadFunction(u,_.name.value)&&__DEV__&&K.error("Missing field '".concat(Wr(_),"' while writing result ").concat(JSON.stringify(i,null,2)).substring(0,1e3))});try{var h=c.identify(i,{typename:u,selectionSet:o,fragmentMap:a.fragmentMap,storeObject:l,readField:d}),p=h[0],m=h[1];r=r||p,m&&(l=a.merge(l,m))}catch(g){if(!r)throw g}if(typeof r=="string"){var v=Si(r),b=a.written[r]||(a.written[r]=[]);if(b.indexOf(o)>=0||(b.push(o),this.reader&&this.reader.isFresh(i,v,o,a)))return v;var y=a.incomingById.get(r);return y?(y.storeObject=a.merge(y.storeObject,l),y.mergeTree=p0(y.mergeTree,s),f.forEach(function(g){return y.fieldNodeSet.add(g)})):a.incomingById.set(r,{storeObject:l,mergeTree:kl(s)?void 0:s,fieldNodeSet:f}),v}return l},e.prototype.processFieldValue=function(t,n,r,i){var o=this;return!n.selectionSet||t===null?__DEV__?My(t):t:Xe(t)?t.map(function(a,s){var c=o.processFieldValue(a,n,r,M2(i,s));return D2(i,s),c}):this.processSelectionSet({result:t,selectionSet:n.selectionSet,context:r,mergeTree:i})},e.prototype.flattenFields=function(t,n,r,i){i===void 0&&(i=Yd(n,t,r.fragmentMap));var o=new Map,a=this.cache.policies,s=new wa(!1);return function c(l,u){var d=s.lookup(l,u.clientOnly,u.deferred);d.visited||(d.visited=!0,l.selections.forEach(function(f){if(!!Dc(f,r.variables)){var h=u.clientOnly,p=u.deferred;if(!(h&&p)&&rn(f.directives)&&f.directives.forEach(function(b){var y=b.name.value;if(y==="client"&&(h=!0),y==="defer"){var g=Lc(b,r.variables);(!g||g.if!==!1)&&(p=!0)}}),Gr(f)){var m=o.get(f);m&&(h=h&&m.clientOnly,p=p&&m.deferred),o.set(f,Lu(r,h,p))}else{var v=Ah(f,r.lookupFragment);if(!v&&f.kind===X.FRAGMENT_SPREAD)throw __DEV__?new Se("No fragment named ".concat(f.name.value)):new Se(8);v&&a.fragmentMatches(v,i,n,r.variables)&&c(v.selectionSet,Lu(r,h,p))}}}))}(t,r),o},e.prototype.applyMerges=function(t,n,r,i,o){var a,s=this;if(t.map.size&&!Pe(r)){var c=!Xe(r)&&(Pe(n)||wi(n))?n:void 0,l=r;c&&!o&&(o=[Pe(c)?c.__ref:c]);var u,d=function(f,h){return Xe(f)?typeof h=="number"?f[h]:void 0:i.store.getFieldValue(f,String(h))};t.map.forEach(function(f,h){var p=d(c,h),m=d(l,h);if(m!==void 0){o&&o.push(h);var v=s.applyMerges(f,p,m,i,o);v!==m&&(u=u||new Map,u.set(h,v)),o&&K(o.pop()===h)}}),u&&(r=Xe(l)?l.slice(0):N({},l),u.forEach(function(f,h){r[h]=f}))}return t.info?this.cache.policies.runMergeFunction(n,r,t.info,i,o&&(a=i.store).getStorage.apply(a,o)):r},e}(),c3=[];function M2(e,t){var n=e.map;return n.has(t)||n.set(t,c3.pop()||{map:new Map}),n.get(t)}function p0(e,t){if(e===t||!t||kl(t))return e;if(!e||kl(e))return t;var n=e.info&&t.info?N(N({},e.info),t.info):e.info||t.info,r=e.map.size&&t.map.size,i=r?new Map:e.map.size?e.map:t.map,o={info:n,map:i};if(r){var a=new Set(t.map.keys());e.map.forEach(function(s,c){o.map.set(c,p0(s,t.map.get(c))),a.delete(c)}),a.forEach(function(s){o.map.set(s,p0(t.map.get(s),e.map.get(s)))})}return o}function kl(e){return!e||!(e.info||e.map.size)}function D2(e,t){var n=e.map,r=n.get(t);r&&kl(r)&&(c3.push(r),n.delete(t))}var L2=new Set;function t_(e,t,n,r){var i=function(d){var f=r.getFieldValue(d,n);return typeof f=="object"&&f},o=i(e);if(!!o){var a=i(t);if(!!a&&!Pe(o)&&!ut(o,a)&&!Object.keys(o).every(function(d){return r.getFieldValue(a,d)!==void 0})){var s=r.getFieldValue(e,"__typename")||r.getFieldValue(t,"__typename"),c=yr(n),l="".concat(s,".").concat(c);if(!L2.has(l)){L2.add(l);var u=[];!Xe(o)&&!Xe(a)&&[o,a].forEach(function(d){var f=r.getFieldValue(d,"__typename");typeof f=="string"&&!u.includes(f)&&u.push(f)}),__DEV__&&K.warn("Cache data may be lost when replacing the ".concat(c," field of a ").concat(s,` object.
|
|
54
|
+
`):new Se(23)},fw=function(){if(typeof AbortController>"u")return{controller:!1,signal:!1};var e=new AbortController,t=e.signal;return{controller:e,signal:t}},hw=function(e,t){var n=e.getContext(),r=n.uri;return r||(typeof t=="function"?t(e):t||"/graphql")};function pw(e,t){var n=[],r=function(d,f){n.push("".concat(d,"=").concat(encodeURIComponent(f)))};if("query"in t&&r("query",t.query),t.operationName&&r("operationName",t.operationName),t.variables){var i=void 0;try{i=a0(t.variables,"Variables map")}catch(d){return{parseError:d}}r("variables",i)}if(t.extensions){var o=void 0;try{o=a0(t.extensions,"Extensions map")}catch(d){return{parseError:d}}r("extensions",o)}var a="",s=e,c=e.indexOf("#");c!==-1&&(a=e.substr(c),s=e.substr(0,c));var l=s.indexOf("?")===-1?"?":"&",u=s+l+n.join("&")+a;return{newURI:u}}var f2=en(function(){return fetch}),mw=function(e){e===void 0&&(e={});var t=e.uri,n=t===void 0?"/graphql":t,r=e.fetch,i=e.print,o=i===void 0?lw:i,a=e.includeExtensions,s=e.preserveHeaderCase,c=e.useGETForQueries,l=e.includeUnusedVariables,u=l===void 0?!1:l,d=hr(e,["uri","fetch","print","includeExtensions","preserveHeaderCase","useGETForQueries","includeUnusedVariables"]);__DEV__&&dw(r||f2);var f={http:{includeExtensions:a,preserveHeaderCase:s},options:d.fetchOptions,credentials:d.credentials,headers:d.headers};return new io(function(h){var p=hw(h,n),m=h.getContext(),v={};if(m.clientAwareness){var b=m.clientAwareness,y=b.name,g=b.version;y&&(v["apollographql-client-name"]=y),g&&(v["apollographql-client-version"]=g)}var _=T(T({},v),m.headers),k={http:m.http,options:m.fetchOptions,credentials:m.credentials,headers:_},O=cw(h,o,sw,f,k),C=O.options,M=O.body;if(M.variables&&!u){var D=new Set(Object.keys(M.variables));Wn(h.query,{Variable:function(U,W,de){de&&de.kind!=="VariableDefinition"&&D.delete(U.name.value)}}),D.size&&(M.variables=T({},M.variables),D.forEach(function(U){delete M.variables[U]}))}var F;if(!C.signal){var Y=fw(),J=Y.controller,G=Y.signal;F=J,F&&(C.signal=G)}var j=function(U){return U.kind==="OperationDefinition"&&U.operation==="mutation"};if(c&&!h.query.definitions.some(j)&&(C.method="GET"),Th(["defer"],h.query)&&(C.headers=C.headers||{},C.headers.accept="multipart/mixed; deferSpec=20220824, application/json"),C.method==="GET"){var z=pw(p,M),Q=z.newURI,I=z.parseError;if(I)return l2(I);p=Q}else try{C.body=a0(M,"Payload")}catch(U){return l2(U)}return new Le(function(U){var W=r||en(function(){return fetch})||f2;return W(p,C).then(function(de){var be;h.setContext({response:de});var P=(be=de.headers)===null||be===void 0?void 0:be.get("content-type");return P!==null&&/^multipart\/mixed/i.test(P)?ew(de,U):nw(de,h,U)}).catch(function(de){return Bh(de,U)}),function(){F&&F.abort()}})})},zy=function(e){yn(t,e);function t(n){n===void 0&&(n={});var r=e.call(this,mw(n).request)||this;return r.options=n,r}return t}(io),jy=Object.prototype,h2=jy.toString,vw=jy.hasOwnProperty,p2=Function.prototype.toString,s0=new Map;function ut(e,t){try{return l0(e,t)}finally{s0.clear()}}function l0(e,t){if(e===t)return!0;var n=h2.call(e),r=h2.call(t);if(n!==r)return!1;switch(n){case"[object Array]":if(e.length!==t.length)return!1;case"[object Object]":{if(v2(e,t))return!0;var i=m2(e),o=m2(t),a=i.length;if(a!==o.length)return!1;for(var s=0;s<a;++s)if(!vw.call(t,i[s]))return!1;for(var s=0;s<a;++s){var c=i[s];if(!l0(e[c],t[c]))return!1}return!0}case"[object Error]":return e.name===t.name&&e.message===t.message;case"[object Number]":if(e!==e)return t!==t;case"[object Boolean]":case"[object Date]":return+e==+t;case"[object RegExp]":case"[object String]":return e=="".concat(t);case"[object Map]":case"[object Set]":{if(e.size!==t.size)return!1;if(v2(e,t))return!0;for(var l=e.entries(),u=n==="[object Map]";;){var d=l.next();if(d.done)break;var f=d.value,h=f[0],p=f[1];if(!t.has(h)||u&&!l0(p,t.get(h)))return!1}return!0}case"[object Uint16Array]":case"[object Uint8Array]":case"[object Uint32Array]":case"[object Int32Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object ArrayBuffer]":e=new Uint8Array(e),t=new Uint8Array(t);case"[object DataView]":{var m=e.byteLength;if(m===t.byteLength)for(;m--&&e[m]===t[m];);return m===-1}case"[object AsyncFunction]":case"[object GeneratorFunction]":case"[object AsyncGeneratorFunction]":case"[object Function]":{var v=p2.call(e);return v!==p2.call(t)?!1:!bw(v,yw)}}return!1}function m2(e){return Object.keys(e).filter(gw,e)}function gw(e){return this[e]!==void 0}var yw="{ [native code] }";function bw(e,t){var n=e.length-t.length;return n>=0&&e.indexOf(t,n)===n}function v2(e,t){var n=s0.get(e);if(n){if(n.has(t))return!0}else s0.set(e,n=new Set);return n.add(t),!1}var $w=function(){return Object.create(null)},Vy=Array.prototype,ww=Vy.forEach,_w=Vy.slice,wa=function(){function e(t,n){t===void 0&&(t=!0),n===void 0&&(n=$w),this.weakness=t,this.makeData=n}return e.prototype.lookup=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return this.lookupArray(t)},e.prototype.lookupArray=function(t){var n=this;return ww.call(t,function(r){return n=n.getChildTrie(r)}),n.data||(n.data=this.makeData(_w.call(t)))},e.prototype.getChildTrie=function(t){var n=this.weakness&&xw(t)?this.weak||(this.weak=new WeakMap):this.strong||(this.strong=new Map),r=n.get(t);return r||n.set(t,r=new e(this.weakness,this.makeData)),r},e}();function xw(e){switch(typeof e){case"object":if(e===null)break;case"function":return!0}return!1}var Et=null,g2={},kw=1,Ew=function(){return function(){function e(){this.id=["slot",kw++,Date.now(),Math.random().toString(36).slice(2)].join(":")}return e.prototype.hasValue=function(){for(var t=Et;t;t=t.parent)if(this.id in t.slots){var n=t.slots[this.id];if(n===g2)break;return t!==Et&&(Et.slots[this.id]=n),!0}return Et&&(Et.slots[this.id]=g2),!1},e.prototype.getValue=function(){if(this.hasValue())return Et.slots[this.id]},e.prototype.withValue=function(t,n,r,i){var o,a=(o={__proto__:null},o[this.id]=t,o),s=Et;Et={parent:s,slots:a};try{return n.apply(i,r)}finally{Et=s}},e.bind=function(t){var n=Et;return function(){var r=Et;try{return Et=n,t.apply(this,arguments)}finally{Et=r}}},e.noContext=function(t,n,r){if(Et){var i=Et;try{return Et=null,t.apply(r,n)}finally{Et=i}}else return t.apply(r,n)},e}()};function y2(e){try{return e()}catch{}}var Pu="@wry/context:Slot",Sw=y2(function(){return globalThis})||y2(function(){return global})||Object.create(null),b2=Sw,jc=b2[Pu]||Array[Pu]||function(e){try{Object.defineProperty(b2,Pu,{value:e,enumerable:!1,writable:!1,configurable:!0})}finally{return e}}(Ew());jc.bind;jc.noContext;function Ow(){}var Cw=function(){function e(t,n){t===void 0&&(t=1/0),n===void 0&&(n=Ow),this.max=t,this.dispose=n,this.map=new Map,this.newest=null,this.oldest=null}return e.prototype.has=function(t){return this.map.has(t)},e.prototype.get=function(t){var n=this.getNode(t);return n&&n.value},e.prototype.getNode=function(t){var n=this.map.get(t);if(n&&n!==this.newest){var r=n.older,i=n.newer;i&&(i.older=r),r&&(r.newer=i),n.older=this.newest,n.older.newer=n,n.newer=null,this.newest=n,n===this.oldest&&(this.oldest=i)}return n},e.prototype.set=function(t,n){var r=this.getNode(t);return r?r.value=n:(r={key:t,value:n,newer:null,older:this.newest},this.newest&&(this.newest.newer=r),this.newest=r,this.oldest=this.oldest||r,this.map.set(t,r),r.value)},e.prototype.clean=function(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key)},e.prototype.delete=function(t){var n=this.map.get(t);return n?(n===this.newest&&(this.newest=n.older),n===this.oldest&&(this.oldest=n.newer),n.newer&&(n.newer.older=n.older),n.older&&(n.older.newer=n.newer),this.map.delete(t),this.dispose(n.value,t),!0):!1},e}(),Vc=new jc,Au,Nw=Object.prototype.hasOwnProperty,Hh=(Au=Array.from,Au===void 0?function(e){var t=[];return e.forEach(function(n){return t.push(n)}),t}:Au);function _l(e){var t=e.unsubscribe;typeof t=="function"&&(e.unsubscribe=void 0,t())}var ea=[],Tw=100;function zi(e,t){if(!e)throw new Error(t||"assertion failure")}function Pw(e,t){var n=e.length;return n>0&&n===t.length&&e[n-1]===t[n-1]}function Uy(e){switch(e.length){case 0:throw new Error("unknown value");case 1:return e[0];case 2:throw e[1]}}function Aw(e){return e.slice(0)}var Iw=function(){function e(t){this.fn=t,this.parents=new Set,this.childValues=new Map,this.dirtyChildren=null,this.dirty=!0,this.recomputing=!1,this.value=[],this.deps=null,++e.count}return e.prototype.peek=function(){if(this.value.length===1&&!gr(this))return $2(this),this.value[0]},e.prototype.recompute=function(t){return zi(!this.recomputing,"already recomputing"),$2(this),gr(this)?Mw(this,t):Uy(this.value)},e.prototype.setDirty=function(){this.dirty||(this.dirty=!0,this.value.length=0,By(this),_l(this))},e.prototype.dispose=function(){var t=this;this.setDirty(),Ky(this),qh(this,function(n,r){n.setDirty(),Qy(n,t)})},e.prototype.forget=function(){this.dispose()},e.prototype.dependOn=function(t){t.add(this),this.deps||(this.deps=ea.pop()||new Set),this.deps.add(t)},e.prototype.forgetDeps=function(){var t=this;this.deps&&(Hh(this.deps).forEach(function(n){return n.delete(t)}),this.deps.clear(),ea.push(this.deps),this.deps=null)},e.count=0,e}();function $2(e){var t=Vc.getValue();if(t)return e.parents.add(t),t.childValues.has(e)||t.childValues.set(e,[]),gr(e)?qy(t,e):Wy(t,e),t}function Mw(e,t){return Ky(e),Vc.withValue(e,Dw,[e,t]),Rw(e,t)&&Lw(e),Uy(e.value)}function Dw(e,t){e.recomputing=!0,e.value.length=0;try{e.value[0]=e.fn.apply(null,t)}catch(n){e.value[1]=n}e.recomputing=!1}function gr(e){return e.dirty||!!(e.dirtyChildren&&e.dirtyChildren.size)}function Lw(e){e.dirty=!1,!gr(e)&&Hy(e)}function By(e){qh(e,qy)}function Hy(e){qh(e,Wy)}function qh(e,t){var n=e.parents.size;if(n)for(var r=Hh(e.parents),i=0;i<n;++i)t(r[i],e)}function qy(e,t){zi(e.childValues.has(t)),zi(gr(t));var n=!gr(e);if(!e.dirtyChildren)e.dirtyChildren=ea.pop()||new Set;else if(e.dirtyChildren.has(t))return;e.dirtyChildren.add(t),n&&By(e)}function Wy(e,t){zi(e.childValues.has(t)),zi(!gr(t));var n=e.childValues.get(t);n.length===0?e.childValues.set(t,Aw(t.value)):Pw(n,t.value)||e.setDirty(),Gy(e,t),!gr(e)&&Hy(e)}function Gy(e,t){var n=e.dirtyChildren;n&&(n.delete(t),n.size===0&&(ea.length<Tw&&ea.push(n),e.dirtyChildren=null))}function Ky(e){e.childValues.size>0&&e.childValues.forEach(function(t,n){Qy(e,n)}),e.forgetDeps(),zi(e.dirtyChildren===null)}function Qy(e,t){t.parents.delete(e),e.childValues.delete(t),Gy(e,t)}function Rw(e,t){if(typeof e.subscribe=="function")try{_l(e),e.unsubscribe=e.subscribe.apply(null,t)}catch{return e.setDirty(),!1}return!0}var Fw={setDirty:!0,dispose:!0,forget:!0};function Yy(e){var t=new Map,n=e&&e.subscribe;function r(i){var o=Vc.getValue();if(o){var a=t.get(i);a||t.set(i,a=new Set),o.dependOn(a),typeof n=="function"&&(_l(a),a.unsubscribe=n(i))}}return r.dirty=function(o,a){var s=t.get(o);if(s){var c=a&&Nw.call(Fw,a)?a:"setDirty";Hh(s).forEach(function(l){return l[c]()}),t.delete(o),_l(s)}},r}function Xy(){var e=new wa(typeof WeakMap=="function");return function(){return e.lookupArray(arguments)}}Xy();var Iu=new Set;function xl(e,t){t===void 0&&(t=Object.create(null));var n=new Cw(t.max||Math.pow(2,16),function(l){return l.dispose()}),r=t.keyArgs,i=t.makeCacheKey||Xy(),o=function(){var l=i.apply(null,r?r.apply(null,arguments):arguments);if(l===void 0)return e.apply(null,arguments);var u=n.get(l);u||(n.set(l,u=new Iw(e)),u.subscribe=t.subscribe,u.forget=function(){return n.delete(l)});var d=u.recompute(Array.prototype.slice.call(arguments));return n.set(l,u),Iu.add(n),Vc.hasValue()||(Iu.forEach(function(f){return f.clean()}),Iu.clear()),d};Object.defineProperty(o,"size",{get:function(){return n.map.size},configurable:!1,enumerable:!1});function a(l){var u=n.get(l);u&&u.setDirty()}o.dirtyKey=a,o.dirty=function(){a(i.apply(null,arguments))};function s(l){var u=n.get(l);if(u)return u.peek()}o.peekKey=s,o.peek=function(){return s(i.apply(null,arguments))};function c(l){return n.delete(l)}return o.forgetKey=c,o.forget=function(){return c(i.apply(null,arguments))},o.makeCacheKey=i,o.getKey=r?function(){return i.apply(null,r.apply(null,arguments))}:i,Object.freeze(o)}var zw=function(){function e(){this.getFragmentDoc=xl(e9)}return e.prototype.batch=function(t){var n=this,r=typeof t.optimistic=="string"?t.optimistic:t.optimistic===!1?null:void 0,i;return this.performTransaction(function(){return i=t.update(n)},r),i},e.prototype.recordOptimisticTransaction=function(t,n){this.performTransaction(t,n)},e.prototype.transformDocument=function(t){return t},e.prototype.transformForLink=function(t){return t},e.prototype.identify=function(t){},e.prototype.gc=function(){return[]},e.prototype.modify=function(t){return!1},e.prototype.readQuery=function(t,n){return n===void 0&&(n=!!t.optimistic),this.read(T(T({},t),{rootId:t.id||"ROOT_QUERY",optimistic:n}))},e.prototype.readFragment=function(t,n){return n===void 0&&(n=!!t.optimistic),this.read(T(T({},t),{query:this.getFragmentDoc(t.fragment,t.fragmentName),rootId:t.id,optimistic:n}))},e.prototype.writeQuery=function(t){var n=t.id,r=t.data,i=hr(t,["id","data"]);return this.write(Object.assign(i,{dataId:n||"ROOT_QUERY",result:r}))},e.prototype.writeFragment=function(t){var n=t.id,r=t.data,i=t.fragment,o=t.fragmentName,a=hr(t,["id","data","fragment","fragmentName"]);return this.write(Object.assign(a,{query:this.getFragmentDoc(i,o),dataId:n,result:r}))},e.prototype.updateQuery=function(t,n){return this.batch({update:function(r){var i=r.readQuery(t),o=n(i);return o==null?i:(r.writeQuery(T(T({},t),{data:o})),o)}})},e.prototype.updateFragment=function(t,n){return this.batch({update:function(r){var i=r.readFragment(t),o=n(i);return o==null?i:(r.writeFragment(T(T({},t),{data:o})),o)}})},e}(),Zy=function(e){yn(t,e);function t(n,r,i,o){var a,s=e.call(this,n)||this;if(s.message=n,s.path=r,s.query=i,s.variables=o,Array.isArray(s.path)){s.missing=s.message;for(var c=s.path.length-1;c>=0;--c)s.missing=(a={},a[s.path[c]]=s.missing,a)}else s.missing=s.path;return s.__proto__=t.prototype,s}return t}(Error),vt=Object.prototype.hasOwnProperty;function _o(e){return e==null}function Jy(e,t){var n=e.__typename,r=e.id,i=e._id;if(typeof n=="string"&&(t&&(t.keyObject=_o(r)?_o(i)?void 0:{_id:i}:{id:r}),_o(r)&&!_o(i)&&(r=i),!_o(r)))return"".concat(n,":").concat(typeof r=="number"||typeof r=="string"?r:JSON.stringify(r))}var e3={dataIdFromObject:Jy,addTypename:!0,resultCaching:!0,canonizeResults:!1};function jw(e){return zc(e3,e)}function t3(e){var t=e.canonizeResults;return t===void 0?e3.canonizeResults:t}function Vw(e,t){return Pe(t)?e.get(t.__ref,"__typename"):t&&t.__typename}var n3=/^[_a-z][_0-9a-z]*/i;function yr(e){var t=e.match(n3);return t?t[0]:e}function c0(e,t,n){return Ye(t)?Xe(t)?t.every(function(r){return c0(e,r,n)}):e.selections.every(function(r){if(Gr(r)&&Dc(r,n)){var i=Wr(r);return vt.call(t,i)&&(!r.selectionSet||c0(r.selectionSet,t[i],n))}return!0}):!1}function wi(e){return Ye(e)&&!Pe(e)&&!Xe(e)}function Uw(){return new vr}function r3(e,t){var n=Ph(Mh(e));return{fragmentMap:n,lookupFragment:function(r){var i=n[r];return!i&&t&&(i=t.lookup(r)),i||null}}}var hs=Object.create(null),Mu=function(){return hs},w2=Object.create(null),ta=function(){function e(t,n){var r=this;this.policies=t,this.group=n,this.data=Object.create(null),this.rootIds=Object.create(null),this.refs=Object.create(null),this.getFieldValue=function(i,o){return t0(Pe(i)?r.get(i.__ref,o):i&&i[o])},this.canRead=function(i){return Pe(i)?r.has(i.__ref):typeof i=="object"},this.toReference=function(i,o){if(typeof i=="string")return Si(i);if(Pe(i))return i;var a=r.policies.identify(i)[0];if(a){var s=Si(a);return o&&r.merge(a,i),s}}}return e.prototype.toObject=function(){return T({},this.data)},e.prototype.has=function(t){return this.lookup(t,!0)!==void 0},e.prototype.get=function(t,n){if(this.group.depend(t,n),vt.call(this.data,t)){var r=this.data[t];if(r&&vt.call(r,n))return r[n]}if(n==="__typename"&&vt.call(this.policies.rootTypenamesById,t))return this.policies.rootTypenamesById[t];if(this instanceof er)return this.parent.get(t,n)},e.prototype.lookup=function(t,n){if(n&&this.group.depend(t,"__exists"),vt.call(this.data,t))return this.data[t];if(this instanceof er)return this.parent.lookup(t,n);if(this.policies.rootTypenamesById[t])return Object.create(null)},e.prototype.merge=function(t,n){var r=this,i;Pe(t)&&(t=t.__ref),Pe(n)&&(n=n.__ref);var o=typeof t=="string"?this.lookup(i=t):t,a=typeof n=="string"?this.lookup(i=n):n;if(!!a){__DEV__?K(typeof i=="string","store.merge expects a string ID"):K(typeof i=="string",1);var s=new vr(Hw).merge(o,a);if(this.data[i]=s,s!==o&&(delete this.refs[i],this.group.caching)){var c=Object.create(null);o||(c.__exists=1),Object.keys(a).forEach(function(l){if(!o||o[l]!==s[l]){c[l]=1;var u=yr(l);u!==l&&!r.policies.hasKeyArgs(s.__typename,u)&&(c[u]=1),s[l]===void 0&&!(r instanceof er)&&delete s[l]}}),c.__typename&&!(o&&o.__typename)&&this.policies.rootTypenamesById[i]===s.__typename&&delete c.__typename,Object.keys(c).forEach(function(l){return r.group.dirty(i,l)})}}},e.prototype.modify=function(t,n){var r=this,i=this.lookup(t);if(i){var o=Object.create(null),a=!1,s=!0,c={DELETE:hs,INVALIDATE:w2,isReference:Pe,toReference:this.toReference,canRead:this.canRead,readField:function(l,u){return r.policies.readField(typeof l=="string"?{fieldName:l,from:u||Si(t)}:l,{store:r})}};if(Object.keys(i).forEach(function(l){var u=yr(l),d=i[l];if(d!==void 0){var f=typeof n=="function"?n:n[l]||n[u];if(f){var h=f===Mu?hs:f(t0(d),T(T({},c),{fieldName:u,storeFieldName:l,storage:r.getStorage(t,l)}));h===w2?r.group.dirty(t,l):(h===hs&&(h=void 0),h!==d&&(o[l]=h,a=!0,d=h))}d!==void 0&&(s=!1)}}),a)return this.merge(t,o),s&&(this instanceof er?this.data[t]=void 0:delete this.data[t],this.group.dirty(t,"__exists")),!0}return!1},e.prototype.delete=function(t,n,r){var i,o=this.lookup(t);if(o){var a=this.getFieldValue(o,"__typename"),s=n&&r?this.policies.getStoreFieldName({typename:a,fieldName:n,args:r}):n;return this.modify(t,s?(i={},i[s]=Mu,i):Mu)}return!1},e.prototype.evict=function(t,n){var r=!1;return t.id&&(vt.call(this.data,t.id)&&(r=this.delete(t.id,t.fieldName,t.args)),this instanceof er&&this!==n&&(r=this.parent.evict(t,n)||r),(t.fieldName||r)&&this.group.dirty(t.id,t.fieldName||"__exists")),r},e.prototype.clear=function(){this.replace(null)},e.prototype.extract=function(){var t=this,n=this.toObject(),r=[];return this.getRootIdSet().forEach(function(i){vt.call(t.policies.rootTypenamesById,i)||r.push(i)}),r.length&&(n.__META={extraRootIds:r.sort()}),n},e.prototype.replace=function(t){var n=this;if(Object.keys(this.data).forEach(function(o){t&&vt.call(t,o)||n.delete(o)}),t){var r=t.__META,i=hr(t,["__META"]);Object.keys(i).forEach(function(o){n.merge(o,i[o])}),r&&r.extraRootIds.forEach(this.retain,this)}},e.prototype.retain=function(t){return this.rootIds[t]=(this.rootIds[t]||0)+1},e.prototype.release=function(t){if(this.rootIds[t]>0){var n=--this.rootIds[t];return n||delete this.rootIds[t],n}return 0},e.prototype.getRootIdSet=function(t){return t===void 0&&(t=new Set),Object.keys(this.rootIds).forEach(t.add,t),this instanceof er?this.parent.getRootIdSet(t):Object.keys(this.policies.rootTypenamesById).forEach(t.add,t),t},e.prototype.gc=function(){var t=this,n=this.getRootIdSet(),r=this.toObject();n.forEach(function(a){vt.call(r,a)&&(Object.keys(t.findChildRefIds(a)).forEach(n.add,n),delete r[a])});var i=Object.keys(r);if(i.length){for(var o=this;o instanceof er;)o=o.parent;i.forEach(function(a){return o.delete(a)})}return i},e.prototype.findChildRefIds=function(t){if(!vt.call(this.refs,t)){var n=this.refs[t]=Object.create(null),r=this.data[t];if(!r)return n;var i=new Set([r]);i.forEach(function(o){Pe(o)&&(n[o.__ref]=!0),Ye(o)&&Object.keys(o).forEach(function(a){var s=o[a];Ye(s)&&i.add(s)})})}return this.refs[t]},e.prototype.makeCacheKey=function(){return this.group.keyMaker.lookupArray(arguments)},e}(),i3=function(){function e(t,n){n===void 0&&(n=null),this.caching=t,this.parent=n,this.d=null,this.resetCaching()}return e.prototype.resetCaching=function(){this.d=this.caching?Yy():null,this.keyMaker=new wa(ti)},e.prototype.depend=function(t,n){if(this.d){this.d(Du(t,n));var r=yr(n);r!==n&&this.d(Du(t,r)),this.parent&&this.parent.depend(t,n)}},e.prototype.dirty=function(t,n){this.d&&this.d.dirty(Du(t,n),n==="__exists"?"forget":"setDirty")},e}();function Du(e,t){return t+"#"+e}function _2(e,t){Uo(e)&&e.group.depend(t,"__exists")}(function(e){var t=function(n){yn(r,n);function r(i){var o=i.policies,a=i.resultCaching,s=a===void 0?!0:a,c=i.seed,l=n.call(this,o,new i3(s))||this;return l.stump=new Bw(l),l.storageTrie=new wa(ti),c&&l.replace(c),l}return r.prototype.addLayer=function(i,o){return this.stump.addLayer(i,o)},r.prototype.removeLayer=function(){return this},r.prototype.getStorage=function(){return this.storageTrie.lookupArray(arguments)},r}(e);e.Root=t})(ta||(ta={}));var er=function(e){yn(t,e);function t(n,r,i,o){var a=e.call(this,r.policies,o)||this;return a.id=n,a.parent=r,a.replay=i,a.group=o,i(a),a}return t.prototype.addLayer=function(n,r){return new t(n,this,r,this.group)},t.prototype.removeLayer=function(n){var r=this,i=this.parent.removeLayer(n);return n===this.id?(this.group.caching&&Object.keys(this.data).forEach(function(o){var a=r.data[o],s=i.lookup(o);s?a?a!==s&&Object.keys(a).forEach(function(c){ut(a[c],s[c])||r.group.dirty(o,c)}):(r.group.dirty(o,"__exists"),Object.keys(s).forEach(function(c){r.group.dirty(o,c)})):r.delete(o)}),i):i===this.parent?this:i.addLayer(this.id,this.replay)},t.prototype.toObject=function(){return T(T({},this.parent.toObject()),this.data)},t.prototype.findChildRefIds=function(n){var r=this.parent.findChildRefIds(n);return vt.call(this.data,n)?T(T({},r),e.prototype.findChildRefIds.call(this,n)):r},t.prototype.getStorage=function(){for(var n=this.parent;n.parent;)n=n.parent;return n.getStorage.apply(n,arguments)},t}(ta),Bw=function(e){yn(t,e);function t(n){return e.call(this,"EntityStore.Stump",n,function(){},new i3(n.group.caching,n.group))||this}return t.prototype.removeLayer=function(){return this},t.prototype.merge=function(){return this.parent.merge.apply(this.parent,arguments)},t}(er);function Hw(e,t,n){var r=e[n],i=t[n];return ut(r,i)?r:i}function Uo(e){return!!(e instanceof ta&&e.group.caching)}function qw(e){return Ye(e)?Xe(e)?e.slice(0):T({__proto__:Object.getPrototypeOf(e)},e):e}var u0=function(){function e(){this.known=new(D9?WeakSet:Set),this.pool=new wa(ti),this.passes=new WeakMap,this.keysByJSON=new Map,this.empty=this.admit({})}return e.prototype.isKnown=function(t){return Ye(t)&&this.known.has(t)},e.prototype.pass=function(t){if(Ye(t)){var n=qw(t);return this.passes.set(n,t),n}return t},e.prototype.admit=function(t){var n=this;if(Ye(t)){var r=this.passes.get(t);if(r)return r;var i=Object.getPrototypeOf(t);switch(i){case Array.prototype:{if(this.known.has(t))return t;var o=t.map(this.admit,this),a=this.pool.lookupArray(o);return a.array||(this.known.add(a.array=o),__DEV__&&Object.freeze(o)),a.array}case null:case Object.prototype:{if(this.known.has(t))return t;var s=Object.getPrototypeOf(t),c=[s],l=this.sortedKeys(t);c.push(l.json);var u=c.length;l.sorted.forEach(function(h){c.push(n.admit(t[h]))});var a=this.pool.lookupArray(c);if(!a.object){var d=a.object=Object.create(s);this.known.add(d),l.sorted.forEach(function(h,p){d[h]=c[u+p]}),__DEV__&&Object.freeze(d)}return a.object}}}return t},e.prototype.sortedKeys=function(t){var n=Object.keys(t),r=this.pool.lookupArray(n);if(!r.keys){n.sort();var i=JSON.stringify(n);(r.keys=this.keysByJSON.get(i))||this.keysByJSON.set(i,r.keys={sorted:n,json:i})}return r.keys},e}(),jr=Object.assign(function(e){if(Ye(e)){d0===void 0&&x2();var t=d0.admit(e),n=f0.get(t);return n===void 0&&f0.set(t,n=JSON.stringify(t)),n}return JSON.stringify(e)},{reset:x2}),d0,f0;function x2(){d0=new u0,f0=new(ti?WeakMap:Map)}function k2(e){return[e.selectionSet,e.objectOrReference,e.context,e.context.canonizeResults]}var Ww=function(){function e(t){var n=this;this.knownResults=new(ti?WeakMap:Map),this.config=zc(t,{addTypename:t.addTypename!==!1,canonizeResults:t3(t)}),this.canon=t.canon||new u0,this.executeSelectionSet=xl(function(r){var i,o=r.context.canonizeResults,a=k2(r);a[3]=!o;var s=(i=n.executeSelectionSet).peek.apply(i,a);return s?o?T(T({},s),{result:n.canon.admit(s.result)}):s:(_2(r.context.store,r.enclosingRef.__ref),n.execSelectionSetImpl(r))},{max:this.config.resultCacheMaxSize,keyArgs:k2,makeCacheKey:function(r,i,o,a){if(Uo(o.store))return o.store.makeCacheKey(r,Pe(i)?i.__ref:i,o.varString,a)}}),this.executeSubSelectedArray=xl(function(r){return _2(r.context.store,r.enclosingRef.__ref),n.execSubSelectedArrayImpl(r)},{max:this.config.resultCacheMaxSize,makeCacheKey:function(r){var i=r.field,o=r.array,a=r.context;if(Uo(a.store))return a.store.makeCacheKey(i,o,a.varString)}})}return e.prototype.resetCanon=function(){this.canon=new u0},e.prototype.diffQueryAgainstStore=function(t){var n=t.store,r=t.query,i=t.rootId,o=i===void 0?"ROOT_QUERY":i,a=t.variables,s=t.returnPartialData,c=s===void 0?!0:s,l=t.canonizeResults,u=l===void 0?this.config.canonizeResults:l,d=this.config.cache.policies;a=T(T({},Lh(Cy(r))),a);var f=Si(o),h=this.executeSelectionSet({selectionSet:Dh(r).selectionSet,objectOrReference:f,enclosingRef:f,context:T({store:n,query:r,policies:d,variables:a,varString:jr(a),canonizeResults:u},r3(r,this.config.fragments))}),p;if(h.missing&&(p=[new Zy(Gw(h.missing),h.missing,r,a)],!c))throw p[0];return{result:h.result,complete:!p,missing:p}},e.prototype.isFresh=function(t,n,r,i){if(Uo(i.store)&&this.knownResults.get(t)===r){var o=this.executeSelectionSet.peek(r,n,i,this.canon.isKnown(t));if(o&&t===o.result)return!0}return!1},e.prototype.execSelectionSetImpl=function(t){var n=this,r=t.selectionSet,i=t.objectOrReference,o=t.enclosingRef,a=t.context;if(Pe(i)&&!a.policies.rootTypenamesById[i.__ref]&&!a.store.has(i.__ref))return{result:this.canon.empty,missing:"Dangling reference to missing ".concat(i.__ref," object")};var s=a.variables,c=a.policies,l=a.store,u=l.getFieldValue(i,"__typename"),d=[],f,h=new vr;this.config.addTypename&&typeof u=="string"&&!c.rootIdsByTypename[u]&&d.push({__typename:u});function p(g,_){var k;return g.missing&&(f=h.merge(f,(k={},k[_]=g.missing,k))),g.result}var m=new Set(r.selections);m.forEach(function(g){var _,k;if(!!Dc(g,s))if(Gr(g)){var O=c.readField({fieldName:g.name.value,field:g,variables:a.variables,from:i},a),C=Wr(g);O===void 0?Rh.added(g)||(f=h.merge(f,(_={},_[C]="Can't find field '".concat(g.name.value,"' on ").concat(Pe(i)?i.__ref+" object":"object "+JSON.stringify(i,null,2)),_))):Xe(O)?O=p(n.executeSubSelectedArray({field:g,array:O,enclosingRef:o,context:a}),C):g.selectionSet?O!=null&&(O=p(n.executeSelectionSet({selectionSet:g.selectionSet,objectOrReference:O,enclosingRef:Pe(O)?O:o,context:a}),C)):a.canonizeResults&&(O=n.canon.pass(O)),O!==void 0&&d.push((k={},k[C]=O,k))}else{var M=Ah(g,a.lookupFragment);if(!M&&g.kind===X.FRAGMENT_SPREAD)throw __DEV__?new Se("No fragment named ".concat(g.name.value)):new Se(5);M&&c.fragmentMatches(M,u)&&M.selectionSet.selections.forEach(m.add,m)}});var v=Fh(d),b={result:v,missing:f},y=a.canonizeResults?this.canon.admit(b):t0(b);return y.result&&this.knownResults.set(y.result,r),y},e.prototype.execSubSelectedArrayImpl=function(t){var n=this,r=t.field,i=t.array,o=t.enclosingRef,a=t.context,s,c=new vr;function l(u,d){var f;return u.missing&&(s=c.merge(s,(f={},f[d]=u.missing,f))),u.result}return r.selectionSet&&(i=i.filter(a.store.canRead)),i=i.map(function(u,d){return u===null?null:Xe(u)?l(n.executeSubSelectedArray({field:r,array:u,enclosingRef:o,context:a}),d):r.selectionSet?l(n.executeSelectionSet({selectionSet:r.selectionSet,objectOrReference:u,enclosingRef:Pe(u)?u:o,context:a}),d):(__DEV__&&Kw(a.store,r,u),u)}),{result:a.canonizeResults?this.canon.admit(i):i,missing:s}},e}();function Gw(e){try{JSON.stringify(e,function(t,n){if(typeof n=="string")throw n;return n})}catch(t){return t}}function Kw(e,t,n){if(!t.selectionSet){var r=new Set([n]);r.forEach(function(i){Ye(i)&&(__DEV__?K(!Pe(i),"Missing selection set for object of type ".concat(Vw(e,i)," returned for query field ").concat(t.name.value)):K(!Pe(i),6),Object.values(i).forEach(r.add,r))})}}var Wh=new jc,E2=new WeakMap;function Bo(e){var t=E2.get(e);return t||E2.set(e,t={vars:new Set,dep:Yy()}),t}function S2(e){Bo(e).vars.forEach(function(t){return t.forgetCache(e)})}function Qw(e){Bo(e).vars.forEach(function(t){return t.attachCache(e)})}function Yw(e){var t=new Set,n=new Set,r=function(o){if(arguments.length>0){if(e!==o){e=o,t.forEach(function(c){Bo(c).dep.dirty(r),Xw(c)});var a=Array.from(n);n.clear(),a.forEach(function(c){return c(e)})}}else{var s=Wh.getValue();s&&(i(s),Bo(s).dep(r))}return e};r.onNextChange=function(o){return n.add(o),function(){n.delete(o)}};var i=r.attachCache=function(o){return t.add(o),Bo(o).vars.add(r),r};return r.forgetCache=function(o){return t.delete(o)},r}function Xw(e){e.broadcastWatches&&e.broadcastWatches()}var O2=Object.create(null);function Gh(e){var t=JSON.stringify(e);return O2[t]||(O2[t]=Object.create(null))}function C2(e){var t=Gh(e);return t.keyFieldsFn||(t.keyFieldsFn=function(n,r){var i=function(a,s){return r.readField(s,a)},o=r.keyObject=Kh(e,function(a){var s=Ci(r.storeObject,a,i);return s===void 0&&n!==r.storeObject&&vt.call(n,a[0])&&(s=Ci(n,a,a3)),__DEV__?K(s!==void 0,"Missing field '".concat(a.join("."),"' while extracting keyFields from ").concat(JSON.stringify(n))):K(s!==void 0,2),s});return"".concat(r.typename,":").concat(JSON.stringify(o))})}function N2(e){var t=Gh(e);return t.keyArgsFn||(t.keyArgsFn=function(n,r){var i=r.field,o=r.variables,a=r.fieldName,s=Kh(e,function(l){var u=l[0],d=u.charAt(0);if(d==="@"){if(i&&rn(i.directives)){var f=u.slice(1),h=i.directives.find(function(b){return b.name.value===f}),p=h&&Lc(h,o);return p&&Ci(p,l.slice(1))}return}if(d==="$"){var m=u.slice(1);if(o&&vt.call(o,m)){var v=l.slice(0);return v[0]=m,Ci(o,v)}return}if(n)return Ci(n,l)}),c=JSON.stringify(s);return(n||c!=="{}")&&(a+=":"+c),a})}function Kh(e,t){var n=new vr;return o3(e).reduce(function(r,i){var o,a=t(i);if(a!==void 0){for(var s=i.length-1;s>=0;--s)a=(o={},o[i[s]]=a,o);r=n.merge(r,a)}return r},Object.create(null))}function o3(e){var t=Gh(e);if(!t.paths){var n=t.paths=[],r=[];e.forEach(function(i,o){Xe(i)?(o3(i).forEach(function(a){return n.push(r.concat(a))}),r.length=0):(r.push(i),Xe(e[o+1])||(n.push(r.slice(0)),r.length=0))})}return t.paths}function a3(e,t){return e[t]}function Ci(e,t,n){return n=n||a3,s3(t.reduce(function r(i,o){return Xe(i)?i.map(function(a){return r(a,o)}):i&&n(i,o)},e))}function s3(e){return Ye(e)?Xe(e)?e.map(s3):Kh(Object.keys(e).sort(),function(t){return Ci(e,t)}):e}Ih.setStringify(jr);function h0(e){return e.args!==void 0?e.args:e.field?Lc(e.field,e.variables):null}var Zw=function(){},T2=function(e,t){return t.fieldName},P2=function(e,t,n){var r=n.mergeObjects;return r(e,t)},A2=function(e,t){return t},Jw=function(){function e(t){this.config=t,this.typePolicies=Object.create(null),this.toBeAdded=Object.create(null),this.supertypeMap=new Map,this.fuzzySubtypes=new Map,this.rootIdsByTypename=Object.create(null),this.rootTypenamesById=Object.create(null),this.usingPossibleTypes=!1,this.config=T({dataIdFromObject:Jy},t),this.cache=this.config.cache,this.setRootTypename("Query"),this.setRootTypename("Mutation"),this.setRootTypename("Subscription"),t.possibleTypes&&this.addPossibleTypes(t.possibleTypes),t.typePolicies&&this.addTypePolicies(t.typePolicies)}return e.prototype.identify=function(t,n){var r,i=this,o=n&&(n.typename||((r=n.storeObject)===null||r===void 0?void 0:r.__typename))||t.__typename;if(o===this.rootTypenamesById.ROOT_QUERY)return["ROOT_QUERY"];for(var a=n&&n.storeObject||t,s=T(T({},n),{typename:o,storeObject:a,readField:n&&n.readField||function(){var f=Qh(arguments,a);return i.readField(f,{store:i.cache.data,variables:f.variables})}}),c,l=o&&this.getTypePolicy(o),u=l&&l.keyFn||this.config.dataIdFromObject;u;){var d=u(t,s);if(Xe(d))u=C2(d);else{c=d;break}}return c=c?String(c):void 0,s.keyObject?[c,s.keyObject]:[c]},e.prototype.addTypePolicies=function(t){var n=this;Object.keys(t).forEach(function(r){var i=t[r],o=i.queryType,a=i.mutationType,s=i.subscriptionType,c=hr(i,["queryType","mutationType","subscriptionType"]);o&&n.setRootTypename("Query",r),a&&n.setRootTypename("Mutation",r),s&&n.setRootTypename("Subscription",r),vt.call(n.toBeAdded,r)?n.toBeAdded[r].push(c):n.toBeAdded[r]=[c]})},e.prototype.updateTypePolicy=function(t,n){var r=this,i=this.getTypePolicy(t),o=n.keyFields,a=n.fields;function s(c,l){c.merge=typeof l=="function"?l:l===!0?P2:l===!1?A2:c.merge}s(i,n.merge),i.keyFn=o===!1?Zw:Xe(o)?C2(o):typeof o=="function"?o:i.keyFn,a&&Object.keys(a).forEach(function(c){var l=r.getFieldPolicy(t,c,!0),u=a[c];if(typeof u=="function")l.read=u;else{var d=u.keyArgs,f=u.read,h=u.merge;l.keyFn=d===!1?T2:Xe(d)?N2(d):typeof d=="function"?d:l.keyFn,typeof f=="function"&&(l.read=f),s(l,h)}l.read&&l.merge&&(l.keyFn=l.keyFn||T2)})},e.prototype.setRootTypename=function(t,n){n===void 0&&(n=t);var r="ROOT_"+t.toUpperCase(),i=this.rootTypenamesById[r];n!==i&&(__DEV__?K(!i||i===t,"Cannot change root ".concat(t," __typename more than once")):K(!i||i===t,3),i&&delete this.rootIdsByTypename[i],this.rootIdsByTypename[n]=r,this.rootTypenamesById[r]=n)},e.prototype.addPossibleTypes=function(t){var n=this;this.usingPossibleTypes=!0,Object.keys(t).forEach(function(r){n.getSupertypeSet(r,!0),t[r].forEach(function(i){n.getSupertypeSet(i,!0).add(r);var o=i.match(n3);(!o||o[0]!==i)&&n.fuzzySubtypes.set(i,new RegExp(i))})})},e.prototype.getTypePolicy=function(t){var n=this;if(!vt.call(this.typePolicies,t)){var r=this.typePolicies[t]=Object.create(null);r.fields=Object.create(null);var i=this.supertypeMap.get(t);i&&i.size&&i.forEach(function(a){var s=n.getTypePolicy(a),c=s.fields,l=hr(s,["fields"]);Object.assign(r,l),Object.assign(r.fields,c)})}var o=this.toBeAdded[t];return o&&o.length&&o.splice(0).forEach(function(a){n.updateTypePolicy(t,a)}),this.typePolicies[t]},e.prototype.getFieldPolicy=function(t,n,r){if(t){var i=this.getTypePolicy(t).fields;return i[n]||r&&(i[n]=Object.create(null))}},e.prototype.getSupertypeSet=function(t,n){var r=this.supertypeMap.get(t);return!r&&n&&this.supertypeMap.set(t,r=new Set),r},e.prototype.fragmentMatches=function(t,n,r,i){var o=this;if(!t.typeCondition)return!0;if(!n)return!1;var a=t.typeCondition.name.value;if(n===a)return!0;if(this.usingPossibleTypes&&this.supertypeMap.has(a))for(var s=this.getSupertypeSet(n,!0),c=[s],l=function(p){var m=o.getSupertypeSet(p,!1);m&&m.size&&c.indexOf(m)<0&&c.push(m)},u=!!(r&&this.fuzzySubtypes.size),d=!1,f=0;f<c.length;++f){var h=c[f];if(h.has(a))return s.has(a)||(d&&__DEV__&&K.warn("Inferring subtype ".concat(n," of supertype ").concat(a)),s.add(a)),!0;h.forEach(l),u&&f===c.length-1&&c0(t.selectionSet,r,i)&&(u=!1,d=!0,this.fuzzySubtypes.forEach(function(p,m){var v=n.match(p);v&&v[0]===n&&l(m)}))}return!1},e.prototype.hasKeyArgs=function(t,n){var r=this.getFieldPolicy(t,n,!1);return!!(r&&r.keyFn)},e.prototype.getStoreFieldName=function(t){var n=t.typename,r=t.fieldName,i=this.getFieldPolicy(n,r,!1),o,a=i&&i.keyFn;if(a&&n)for(var s={typename:n,fieldName:r,field:t.field||null,variables:t.variables},c=h0(t);a;){var l=a(c,s);if(Xe(l))a=N2(l);else{o=l||r;break}}return o===void 0&&(o=t.field?d9(t.field,t.variables):Ih(r,h0(t))),o===!1?r:r===yr(o)?o:r+":"+o},e.prototype.readField=function(t,n){var r=t.from;if(!!r){var i=t.field||t.fieldName;if(!!i){if(t.typename===void 0){var o=n.store.getFieldValue(r,"__typename");o&&(t.typename=o)}var a=this.getStoreFieldName(t),s=yr(a),c=n.store.getFieldValue(r,a),l=this.getFieldPolicy(t.typename,s,!1),u=l&&l.read;if(u){var d=I2(this,r,t,n,n.store.getStorage(Pe(r)?r.__ref:r,a));return Wh.withValue(this.cache,u,[c,d])}return c}}},e.prototype.getReadFunction=function(t,n){var r=this.getFieldPolicy(t,n,!1);return r&&r.read},e.prototype.getMergeFunction=function(t,n,r){var i=this.getFieldPolicy(t,n,!1),o=i&&i.merge;return!o&&r&&(i=this.getTypePolicy(r),o=i&&i.merge),o},e.prototype.runMergeFunction=function(t,n,r,i,o){var a=r.field,s=r.typename,c=r.merge;return c===P2?l3(i.store)(t,n):c===A2?n:(i.overwrite&&(t=void 0),c(t,n,I2(this,void 0,{typename:s,fieldName:a.name.value,field:a,variables:i.variables},i,o||Object.create(null))))},e}();function I2(e,t,n,r,i){var o=e.getStoreFieldName(n),a=yr(o),s=n.variables||r.variables,c=r.store,l=c.toReference,u=c.canRead;return{args:h0(n),field:n.field||null,fieldName:a,storeFieldName:o,variables:s,isReference:Pe,toReference:l,storage:i,cache:e.cache,canRead:u,readField:function(){return e.readField(Qh(arguments,t,s),r)},mergeObjects:l3(r.store)}}function Qh(e,t,n){var r=e[0],i=e[1],o=e.length,a;return typeof r=="string"?a={fieldName:r,from:o>1?i:t}:(a=T({},r),vt.call(a,"from")||(a.from=t)),__DEV__&&a.from===void 0&&__DEV__&&K.warn("Undefined 'from' passed to readField with arguments ".concat(F9(Array.from(e)))),a.variables===void 0&&(a.variables=n),a}function l3(e){return function(n,r){if(Xe(n)||Xe(r))throw __DEV__?new Se("Cannot automatically merge arrays"):new Se(4);if(Ye(n)&&Ye(r)){var i=e.getFieldValue(n,"__typename"),o=e.getFieldValue(r,"__typename"),a=i&&o&&i!==o;if(a)return r;if(Pe(n)&&wi(r))return e.merge(n.__ref,r),n;if(wi(n)&&Pe(r))return e.merge(n,r.__ref),r;if(wi(n)&&wi(r))return T(T({},n),r)}return r}}function Lu(e,t,n){var r="".concat(t).concat(n),i=e.flavors.get(r);return i||e.flavors.set(r,i=e.clientOnly===t&&e.deferred===n?e:T(T({},e),{clientOnly:t,deferred:n})),i}var e_=function(){function e(t,n,r){this.cache=t,this.reader=n,this.fragments=r}return e.prototype.writeToStore=function(t,n){var r=this,i=n.query,o=n.result,a=n.dataId,s=n.variables,c=n.overwrite,l=$a(i),u=Uw();s=T(T({},Lh(l)),s);var d=T(T({store:t,written:Object.create(null),merge:function(h,p){return u.merge(h,p)},variables:s,varString:jr(s)},r3(i,this.fragments)),{overwrite:!!c,incomingById:new Map,clientOnly:!1,deferred:!1,flavors:new Map}),f=this.processSelectionSet({result:o||Object.create(null),dataId:a,selectionSet:l.selectionSet,mergeTree:{map:new Map},context:d});if(!Pe(f))throw __DEV__?new Se("Could not identify object ".concat(JSON.stringify(o))):new Se(7);return d.incomingById.forEach(function(h,p){var m=h.storeObject,v=h.mergeTree,b=h.fieldNodeSet,y=Si(p);if(v&&v.map.size){var g=r.applyMerges(v,y,m,d);if(Pe(g))return;m=g}if(__DEV__&&!d.overwrite){var _=Object.create(null);b.forEach(function(C){C.selectionSet&&(_[C.name.value]=!0)});var k=function(C){return _[yr(C)]===!0},O=function(C){var M=v&&v.map.get(C);return Boolean(M&&M.info&&M.info.merge)};Object.keys(m).forEach(function(C){k(C)&&!O(C)&&t_(y,m,C,d.store)})}t.merge(p,m)}),t.retain(f.__ref),f},e.prototype.processSelectionSet=function(t){var n=this,r=t.dataId,i=t.result,o=t.selectionSet,a=t.context,s=t.mergeTree,c=this.cache.policies,l=Object.create(null),u=r&&c.rootTypenamesById[r]||Yd(i,o,a.fragmentMap)||r&&a.store.get(r,"__typename");typeof u=="string"&&(l.__typename=u);var d=function(){var g=Qh(arguments,l,a.variables);if(Pe(g.from)){var _=a.incomingById.get(g.from.__ref);if(_){var k=c.readField(T(T({},g),{from:_.storeObject}),a);if(k!==void 0)return k}}return c.readField(g,a)},f=new Set;this.flattenFields(o,i,a,u).forEach(function(g,_){var k,O=Wr(_),C=i[O];if(f.add(_),C!==void 0){var M=c.getStoreFieldName({typename:u,fieldName:_.name.value,field:_,variables:g.variables}),D=M2(s,M),F=n.processFieldValue(C,_,_.selectionSet?Lu(g,!1,!1):g,D),Y=void 0;_.selectionSet&&(Pe(F)||wi(F))&&(Y=d("__typename",F));var J=c.getMergeFunction(u,_.name.value,Y);J?D.info={field:_,typename:u,merge:J}:D2(s,M),l=g.merge(l,(k={},k[M]=F,k))}else __DEV__&&!g.clientOnly&&!g.deferred&&!Rh.added(_)&&!c.getReadFunction(u,_.name.value)&&__DEV__&&K.error("Missing field '".concat(Wr(_),"' while writing result ").concat(JSON.stringify(i,null,2)).substring(0,1e3))});try{var h=c.identify(i,{typename:u,selectionSet:o,fragmentMap:a.fragmentMap,storeObject:l,readField:d}),p=h[0],m=h[1];r=r||p,m&&(l=a.merge(l,m))}catch(g){if(!r)throw g}if(typeof r=="string"){var v=Si(r),b=a.written[r]||(a.written[r]=[]);if(b.indexOf(o)>=0||(b.push(o),this.reader&&this.reader.isFresh(i,v,o,a)))return v;var y=a.incomingById.get(r);return y?(y.storeObject=a.merge(y.storeObject,l),y.mergeTree=p0(y.mergeTree,s),f.forEach(function(g){return y.fieldNodeSet.add(g)})):a.incomingById.set(r,{storeObject:l,mergeTree:kl(s)?void 0:s,fieldNodeSet:f}),v}return l},e.prototype.processFieldValue=function(t,n,r,i){var o=this;return!n.selectionSet||t===null?__DEV__?My(t):t:Xe(t)?t.map(function(a,s){var c=o.processFieldValue(a,n,r,M2(i,s));return D2(i,s),c}):this.processSelectionSet({result:t,selectionSet:n.selectionSet,context:r,mergeTree:i})},e.prototype.flattenFields=function(t,n,r,i){i===void 0&&(i=Yd(n,t,r.fragmentMap));var o=new Map,a=this.cache.policies,s=new wa(!1);return function c(l,u){var d=s.lookup(l,u.clientOnly,u.deferred);d.visited||(d.visited=!0,l.selections.forEach(function(f){if(!!Dc(f,r.variables)){var h=u.clientOnly,p=u.deferred;if(!(h&&p)&&rn(f.directives)&&f.directives.forEach(function(b){var y=b.name.value;if(y==="client"&&(h=!0),y==="defer"){var g=Lc(b,r.variables);(!g||g.if!==!1)&&(p=!0)}}),Gr(f)){var m=o.get(f);m&&(h=h&&m.clientOnly,p=p&&m.deferred),o.set(f,Lu(r,h,p))}else{var v=Ah(f,r.lookupFragment);if(!v&&f.kind===X.FRAGMENT_SPREAD)throw __DEV__?new Se("No fragment named ".concat(f.name.value)):new Se(8);v&&a.fragmentMatches(v,i,n,r.variables)&&c(v.selectionSet,Lu(r,h,p))}}}))}(t,r),o},e.prototype.applyMerges=function(t,n,r,i,o){var a,s=this;if(t.map.size&&!Pe(r)){var c=!Xe(r)&&(Pe(n)||wi(n))?n:void 0,l=r;c&&!o&&(o=[Pe(c)?c.__ref:c]);var u,d=function(f,h){return Xe(f)?typeof h=="number"?f[h]:void 0:i.store.getFieldValue(f,String(h))};t.map.forEach(function(f,h){var p=d(c,h),m=d(l,h);if(m!==void 0){o&&o.push(h);var v=s.applyMerges(f,p,m,i,o);v!==m&&(u=u||new Map,u.set(h,v)),o&&K(o.pop()===h)}}),u&&(r=Xe(l)?l.slice(0):T({},l),u.forEach(function(f,h){r[h]=f}))}return t.info?this.cache.policies.runMergeFunction(n,r,t.info,i,o&&(a=i.store).getStorage.apply(a,o)):r},e}(),c3=[];function M2(e,t){var n=e.map;return n.has(t)||n.set(t,c3.pop()||{map:new Map}),n.get(t)}function p0(e,t){if(e===t||!t||kl(t))return e;if(!e||kl(e))return t;var n=e.info&&t.info?T(T({},e.info),t.info):e.info||t.info,r=e.map.size&&t.map.size,i=r?new Map:e.map.size?e.map:t.map,o={info:n,map:i};if(r){var a=new Set(t.map.keys());e.map.forEach(function(s,c){o.map.set(c,p0(s,t.map.get(c))),a.delete(c)}),a.forEach(function(s){o.map.set(s,p0(t.map.get(s),e.map.get(s)))})}return o}function kl(e){return!e||!(e.info||e.map.size)}function D2(e,t){var n=e.map,r=n.get(t);r&&kl(r)&&(c3.push(r),n.delete(t))}var L2=new Set;function t_(e,t,n,r){var i=function(d){var f=r.getFieldValue(d,n);return typeof f=="object"&&f},o=i(e);if(!!o){var a=i(t);if(!!a&&!Pe(o)&&!ut(o,a)&&!Object.keys(o).every(function(d){return r.getFieldValue(a,d)!==void 0})){var s=r.getFieldValue(e,"__typename")||r.getFieldValue(t,"__typename"),c=yr(n),l="".concat(s,".").concat(c);if(!L2.has(l)){L2.add(l);var u=[];!Xe(o)&&!Xe(a)&&[o,a].forEach(function(d){var f=r.getFieldValue(d,"__typename");typeof f=="string"&&!u.includes(f)&&u.push(f)}),__DEV__&&K.warn("Cache data may be lost when replacing the ".concat(c," field of a ").concat(s,` object.
|
|
55
55
|
|
|
56
56
|
To address this problem (which is not a bug in Apollo Client), `).concat(u.length?"either ensure all objects of type "+u.join(" and ")+" have an ID or a custom merge function, or ":"","define a custom merge function for the ").concat(l,` field, so InMemoryCache can safely merge these objects:
|
|
57
57
|
|
|
@@ -62,13 +62,13 @@ For more information about these options, please refer to the documentation:
|
|
|
62
62
|
|
|
63
63
|
* Ensuring entity objects have IDs: https://go.apollo.dev/c/generating-unique-identifiers
|
|
64
64
|
* Defining custom merge functions: https://go.apollo.dev/c/merging-non-normalized-objects
|
|
65
|
-
`))}}}}var n_=function(e){yn(t,e);function t(n){n===void 0&&(n={});var r=e.call(this)||this;return r.watches=new Set,r.typenameDocumentCache=new Map,r.makeVar=Yw,r.txCount=0,r.config=jw(n),r.addTypename=!!r.config.addTypename,r.policies=new Jw({cache:r,dataIdFromObject:r.config.dataIdFromObject,possibleTypes:r.config.possibleTypes,typePolicies:r.config.typePolicies}),r.init(),r}return t.prototype.init=function(){var n=this.data=new ta.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=n.stump,this.resetResultCache()},t.prototype.resetResultCache=function(n){var r=this,i=this.storeReader,o=this.config.fragments;this.storeWriter=new e_(this,this.storeReader=new Ww({cache:this,addTypename:this.addTypename,resultCacheMaxSize:this.config.resultCacheMaxSize,canonizeResults:t3(this.config),canon:n?void 0:i&&i.canon,fragments:o}),o),this.maybeBroadcastWatch=xl(function(a,s){return r.broadcastWatch(a,s)},{max:this.config.resultCacheMaxSize,makeCacheKey:function(a){var s=a.optimistic?r.optimisticData:r.data;if(Uo(s)){var c=a.optimistic,l=a.id,u=a.variables;return s.makeCacheKey(a.query,a.callback,jr({optimistic:c,id:l,variables:u}))}}}),new Set([this.data.group,this.optimisticData.group]).forEach(function(a){return a.resetCaching()})},t.prototype.restore=function(n){return this.init(),n&&this.data.replace(n),this},t.prototype.extract=function(n){return n===void 0&&(n=!1),(n?this.optimisticData:this.data).extract()},t.prototype.read=function(n){var r=n.returnPartialData,i=r===void 0?!1:r;try{return this.storeReader.diffQueryAgainstStore(
|
|
65
|
+
`))}}}}var n_=function(e){yn(t,e);function t(n){n===void 0&&(n={});var r=e.call(this)||this;return r.watches=new Set,r.typenameDocumentCache=new Map,r.makeVar=Yw,r.txCount=0,r.config=jw(n),r.addTypename=!!r.config.addTypename,r.policies=new Jw({cache:r,dataIdFromObject:r.config.dataIdFromObject,possibleTypes:r.config.possibleTypes,typePolicies:r.config.typePolicies}),r.init(),r}return t.prototype.init=function(){var n=this.data=new ta.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=n.stump,this.resetResultCache()},t.prototype.resetResultCache=function(n){var r=this,i=this.storeReader,o=this.config.fragments;this.storeWriter=new e_(this,this.storeReader=new Ww({cache:this,addTypename:this.addTypename,resultCacheMaxSize:this.config.resultCacheMaxSize,canonizeResults:t3(this.config),canon:n?void 0:i&&i.canon,fragments:o}),o),this.maybeBroadcastWatch=xl(function(a,s){return r.broadcastWatch(a,s)},{max:this.config.resultCacheMaxSize,makeCacheKey:function(a){var s=a.optimistic?r.optimisticData:r.data;if(Uo(s)){var c=a.optimistic,l=a.id,u=a.variables;return s.makeCacheKey(a.query,a.callback,jr({optimistic:c,id:l,variables:u}))}}}),new Set([this.data.group,this.optimisticData.group]).forEach(function(a){return a.resetCaching()})},t.prototype.restore=function(n){return this.init(),n&&this.data.replace(n),this},t.prototype.extract=function(n){return n===void 0&&(n=!1),(n?this.optimisticData:this.data).extract()},t.prototype.read=function(n){var r=n.returnPartialData,i=r===void 0?!1:r;try{return this.storeReader.diffQueryAgainstStore(T(T({},n),{store:n.optimistic?this.optimisticData:this.data,config:this.config,returnPartialData:i})).result||null}catch(o){if(o instanceof Zy)return null;throw o}},t.prototype.write=function(n){try{return++this.txCount,this.storeWriter.writeToStore(this.data,n)}finally{!--this.txCount&&n.broadcast!==!1&&this.broadcastWatches()}},t.prototype.modify=function(n){if(vt.call(n,"id")&&!n.id)return!1;var r=n.optimistic?this.optimisticData:this.data;try{return++this.txCount,r.modify(n.id||"ROOT_QUERY",n.fields)}finally{!--this.txCount&&n.broadcast!==!1&&this.broadcastWatches()}},t.prototype.diff=function(n){return this.storeReader.diffQueryAgainstStore(T(T({},n),{store:n.optimistic?this.optimisticData:this.data,rootId:n.id||"ROOT_QUERY",config:this.config}))},t.prototype.watch=function(n){var r=this;return this.watches.size||Qw(this),this.watches.add(n),n.immediate&&this.maybeBroadcastWatch(n),function(){r.watches.delete(n)&&!r.watches.size&&S2(r),r.maybeBroadcastWatch.forget(n)}},t.prototype.gc=function(n){jr.reset();var r=this.optimisticData.gc();return n&&!this.txCount&&(n.resetResultCache?this.resetResultCache(n.resetResultIdentities):n.resetResultIdentities&&this.storeReader.resetCanon()),r},t.prototype.retain=function(n,r){return(r?this.optimisticData:this.data).retain(n)},t.prototype.release=function(n,r){return(r?this.optimisticData:this.data).release(n)},t.prototype.identify=function(n){if(Pe(n))return n.__ref;try{return this.policies.identify(n)[0]}catch(r){__DEV__&&K.warn(r)}},t.prototype.evict=function(n){if(!n.id){if(vt.call(n,"id"))return!1;n=T(T({},n),{id:"ROOT_QUERY"})}try{return++this.txCount,this.optimisticData.evict(n,this.data)}finally{!--this.txCount&&n.broadcast!==!1&&this.broadcastWatches()}},t.prototype.reset=function(n){var r=this;return this.init(),jr.reset(),n&&n.discardWatches?(this.watches.forEach(function(i){return r.maybeBroadcastWatch.forget(i)}),this.watches.clear(),S2(this)):this.broadcastWatches(),Promise.resolve()},t.prototype.removeOptimistic=function(n){var r=this.optimisticData.removeLayer(n);r!==this.optimisticData&&(this.optimisticData=r,this.broadcastWatches())},t.prototype.batch=function(n){var r=this,i=n.update,o=n.optimistic,a=o===void 0?!0:o,s=n.removeOptimistic,c=n.onWatchUpdated,l,u=function(f){var h=r,p=h.data,m=h.optimisticData;++r.txCount,f&&(r.data=r.optimisticData=f);try{return l=i(r)}finally{--r.txCount,r.data=p,r.optimisticData=m}},d=new Set;return c&&!this.txCount&&this.broadcastWatches(T(T({},n),{onWatchUpdated:function(f){return d.add(f),!1}})),typeof a=="string"?this.optimisticData=this.optimisticData.addLayer(a,u):a===!1?u(this.data):u(),typeof s=="string"&&(this.optimisticData=this.optimisticData.removeLayer(s)),c&&d.size?(this.broadcastWatches(T(T({},n),{onWatchUpdated:function(f,h){var p=c.call(this,f,h);return p!==!1&&d.delete(f),p}})),d.size&&d.forEach(function(f){return r.maybeBroadcastWatch.dirty(f)})):this.broadcastWatches(n),l},t.prototype.performTransaction=function(n,r){return this.batch({update:n,optimistic:r||r!==null})},t.prototype.transformDocument=function(n){if(this.addTypename){var r=this.typenameDocumentCache.get(n);return r||(r=Rh(n),this.typenameDocumentCache.set(n,r),this.typenameDocumentCache.set(r,r)),r}return n},t.prototype.transformForLink=function(n){var r=this.config.fragments;return r?r.transform(n):n},t.prototype.broadcastWatches=function(n){var r=this;this.txCount||this.watches.forEach(function(i){return r.maybeBroadcastWatch(i,n)})},t.prototype.broadcastWatch=function(n,r){var i=n.lastDiff,o=this.diff(n);r&&(n.optimistic&&typeof r.optimistic=="string"&&(o.fromOptimisticTransaction=!0),r.onWatchUpdated&&r.onWatchUpdated.call(this,n,o,i)===!1)||(!i||!ut(i.result,o.result))&&n.callback(n.lastDiff=o,i)},t}(zw);function r_(e){return e.hasOwnProperty("graphQLErrors")}var i_=function(e){var t="";if(rn(e.graphQLErrors)||rn(e.clientErrors)){var n=(e.graphQLErrors||[]).concat(e.clientErrors||[]);n.forEach(function(r){var i=r?r.message:"Error message not found.";t+="".concat(i,`
|
|
66
66
|
`)})}return e.networkError&&(t+="".concat(e.networkError.message,`
|
|
67
|
-
`)),t=t.replace(/\n$/,""),t},si=function(e){yn(t,e);function t(n){var r=n.graphQLErrors,i=n.clientErrors,o=n.networkError,a=n.errorMessage,s=n.extraInfo,c=e.call(this,a)||this;return c.name="ApolloError",c.graphQLErrors=r||[],c.clientErrors=i||[],c.networkError=o||null,c.message=a||i_(c),c.extraInfo=s,c.__proto__=t.prototype,c}return t}(Error),De;(function(e){e[e.loading=1]="loading",e[e.setVariables=2]="setVariables",e[e.fetchMore=3]="fetchMore",e[e.refetch=4]="refetch",e[e.poll=6]="poll",e[e.ready=7]="ready",e[e.error=8]="error"})(De||(De={}));function na(e){return e?e<7:!1}var o_=Object.assign,a_=Object.hasOwnProperty,m0=function(e){yn(t,e);function t(n){var r=n.queryManager,i=n.queryInfo,o=n.options,a=e.call(this,function(v){try{var b=v._subscription._observer;b&&!b.error&&(b.error=s_)}catch{}var y=!a.observers.size;a.observers.add(v);var g=a.last;return g&&g.error?v.error&&v.error(g.error):g&&g.result&&v.next&&v.next(g.result),y&&a.reobserve().catch(function(){}),function(){a.observers.delete(v)&&!a.observers.size&&a.tearDownQuery()}})||this;a.observers=new Set,a.subscriptions=new Set,a.queryInfo=i,a.queryManager=r,a.isTornDown=!1;var s=r.defaultOptions.watchQuery,c=s===void 0?{}:s,l=c.fetchPolicy,u=l===void 0?"cache-first":l,d=o.fetchPolicy,f=d===void 0?u:d,h=o.initialFetchPolicy,p=h===void 0?f==="standby"?u:f:h;a.options=
|
|
68
|
-
Did you mean to call refetch(variables) instead of refetch({ variables })?`))}return n&&!ut(this.options.variables,n)&&(i.variables=this.options.variables=N(N({},this.options.variables),n)),this.queryInfo.resetLastWrite(),this.reobserve(i,De.refetch)},t.prototype.fetchMore=function(n){var r=this,i=N(N({},n.query?n:N(N(N(N({},this.options),{query:this.query}),n),{variables:N(N({},this.options.variables),n.variables)})),{fetchPolicy:"no-cache"}),o=this.queryManager.generateQueryId(),a=this.queryInfo,s=a.networkStatus;a.networkStatus=De.fetchMore,i.notifyOnNetworkStatusChange&&this.observe();var c=new Set;return this.queryManager.fetchQuery(o,i,De.fetchMore).then(function(l){return r.queryManager.removeQuery(o),a.networkStatus===De.fetchMore&&(a.networkStatus=s),r.queryManager.cache.batch({update:function(u){var d=n.updateQuery;d?u.updateQuery({query:r.query,variables:r.variables,returnPartialData:!0,optimistic:!1},function(f){return d(f,{fetchMoreResult:l.data,variables:i.variables})}):u.writeQuery({query:i.query,variables:i.variables,data:l.data})},onWatchUpdated:function(u){c.add(u.query)}}),l}).finally(function(){c.has(r.query)||u3(r)})},t.prototype.subscribeToMore=function(n){var r=this,i=this.queryManager.startGraphQLSubscription({query:n.document,variables:n.variables,context:n.context}).subscribe({next:function(o){var a=n.updateQuery;a&&r.updateQuery(function(s,c){var l=c.variables;return a(s,{subscriptionData:o,variables:l})})},error:function(o){if(n.onError){n.onError(o);return}__DEV__&&K.error("Unhandled GraphQL subscription error",o)}});return this.subscriptions.add(i),function(){r.subscriptions.delete(i)&&i.unsubscribe()}},t.prototype.setOptions=function(n){return this.reobserve(n)},t.prototype.setVariables=function(n){return ut(this.variables,n)?this.observers.size?this.result():Promise.resolve():(this.options.variables=n,this.observers.size?this.reobserve({fetchPolicy:this.options.initialFetchPolicy,variables:n},De.setVariables):Promise.resolve())},t.prototype.updateQuery=function(n){var r=this.queryManager,i=r.cache.diff({query:this.options.query,variables:this.variables,returnPartialData:!0,optimistic:!1}).result,o=n(i,{variables:this.variables});o&&(r.cache.writeQuery({query:this.options.query,data:o,variables:this.variables}),r.broadcastQueries())},t.prototype.startPolling=function(n){this.options.pollInterval=n,this.updatePolling()},t.prototype.stopPolling=function(){this.options.pollInterval=0,this.updatePolling()},t.prototype.applyNextFetchPolicy=function(n,r){if(r.nextFetchPolicy){var i=r.fetchPolicy,o=i===void 0?"cache-first":i,a=r.initialFetchPolicy,s=a===void 0?o:a;o==="standby"||(typeof r.nextFetchPolicy=="function"?r.fetchPolicy=r.nextFetchPolicy(o,{reason:n,options:r,observable:this,initialFetchPolicy:s}):n==="variables-changed"?r.fetchPolicy=s:r.fetchPolicy=r.nextFetchPolicy)}return r.fetchPolicy},t.prototype.fetch=function(n,r){return this.queryManager.setObservableQuery(this),this.queryManager.fetchQueryObservable(this.queryId,n,r)},t.prototype.updatePolling=function(){var n=this;if(!this.queryManager.ssrMode){var r=this,i=r.pollingInfo,o=r.options.pollInterval;if(!o){i&&(clearTimeout(i.timeout),delete this.pollingInfo);return}if(!(i&&i.interval===o)){__DEV__?K(o,"Attempted to start a polling query without a polling interval."):K(o,13);var a=i||(this.pollingInfo={});a.interval=o;var s=function(){n.pollingInfo&&(na(n.queryInfo.networkStatus)?c():n.reobserve({fetchPolicy:n.options.initialFetchPolicy==="no-cache"?"no-cache":"network-only"},De.poll).then(c,c))},c=function(){var l=n.pollingInfo;l&&(clearTimeout(l.timeout),l.timeout=setTimeout(s,l.interval))};c()}}},t.prototype.updateLastResult=function(n,r){return r===void 0&&(r=this.variables),this.last=N(N({},this.last),{result:this.queryManager.assumeImmutableResults?n:My(n),variables:r}),rn(n.errors)||delete this.last.error,this.last},t.prototype.reobserve=function(n,r){var i=this;this.isTornDown=!1;var o=r===De.refetch||r===De.fetchMore||r===De.poll,a=this.options.variables,s=this.options.fetchPolicy,c=zc(this.options,n||{}),l=o?c:o_(this.options,c);o||(this.updatePolling(),n&&n.variables&&!ut(n.variables,a)&&l.fetchPolicy!=="standby"&&l.fetchPolicy===s&&(this.applyNextFetchPolicy("variables-changed",l),r===void 0&&(r=De.setVariables)));var u=l.variables&&N({},l.variables),d=this.fetch(l,r),f={next:function(h){i.reportResult(h,u)},error:function(h){i.reportError(h,u)}};return o||(this.concast&&this.observer&&this.concast.removeObserver(this.observer),this.concast=d,this.observer=f),d.addObserver(f),d.promise},t.prototype.observe=function(){this.reportResult(this.getCurrentResult(!1),this.variables)},t.prototype.reportResult=function(n,r){var i=this.getLastError();(i||this.isDifferentFromLastResult(n,r))&&((i||!n.partial||this.options.returnPartialData)&&this.updateLastResult(n,r),Vo(this.observers,"next",n))},t.prototype.reportError=function(n,r){var i=N(N({},this.getLastResult()),{error:n,errors:n.graphQLErrors,networkStatus:De.error,loading:!1});this.updateLastResult(i,r),Vo(this.observers,"error",this.last.error=n)},t.prototype.hasObservers=function(){return this.observers.size>0},t.prototype.tearDownQuery=function(){this.isTornDown||(this.concast&&this.observer&&(this.concast.removeObserver(this.observer),delete this.concast,delete this.observer),this.stopPolling(),this.subscriptions.forEach(function(n){return n.unsubscribe()}),this.subscriptions.clear(),this.queryManager.stopQuery(this.queryId),this.observers.clear(),this.isTornDown=!0)},t}(Le);Ly(m0);function u3(e){var t=e.options,n=t.fetchPolicy,r=t.nextFetchPolicy;return n==="cache-and-network"||n==="network-only"?e.reobserve({fetchPolicy:"cache-first",nextFetchPolicy:function(){return this.nextFetchPolicy=r,typeof r=="function"?r.apply(this,arguments):n}}):e.reobserve()}function s_(e){__DEV__&&K.error("Unhandled error",e.message,e.stack)}function d3(e){__DEV__&&e&&__DEV__&&K.debug("Missing cache result fields: ".concat(JSON.stringify(e)),e)}var f3=function(){function e(t){var n=t.cache,r=t.client,i=t.resolvers,o=t.fragmentMatcher;this.selectionsToResolveCache=new WeakMap,this.cache=n,r&&(this.client=r),i&&this.addResolvers(i),o&&this.setFragmentMatcher(o)}return e.prototype.addResolvers=function(t){var n=this;this.resolvers=this.resolvers||{},Array.isArray(t)?t.forEach(function(r){n.resolvers=t2(n.resolvers,r)}):this.resolvers=t2(this.resolvers,t)},e.prototype.setResolvers=function(t){this.resolvers={},this.addResolvers(t)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(t){var n=t.document,r=t.remoteResult,i=t.context,o=t.variables,a=t.onlyRunForcedResolvers,s=a===void 0?!1:a;return fe(this,void 0,void 0,function(){return nr(this,function(c){return n?[2,this.resolveDocument(n,r.data,i,o,this.fragmentMatcher,s).then(function(l){return N(N({},r),{data:l.result})})]:[2,r]})})},e.prototype.setFragmentMatcher=function(t){this.fragmentMatcher=t},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(t){return Th(["client"],t)&&this.resolvers?t:null},e.prototype.serverQuery=function(t){return w9(t)},e.prototype.prepareContext=function(t){var n=this.cache;return N(N({},t),{cache:n,getCacheKey:function(r){return n.identify(r)}})},e.prototype.addExportedVariables=function(t,n,r){return n===void 0&&(n={}),r===void 0&&(r={}),fe(this,void 0,void 0,function(){return nr(this,function(i){return t?[2,this.resolveDocument(t,this.buildRootValueFromCache(t,n)||{},this.prepareContext(r),n).then(function(o){return N(N({},n),o.exportedVariables)})]:[2,N({},n)]})})},e.prototype.shouldForceResolvers=function(t){var n=!1;return Wn(t,{Directive:{enter:function(r){if(r.name.value==="client"&&r.arguments&&(n=r.arguments.some(function(i){return i.name.value==="always"&&i.value.kind==="BooleanValue"&&i.value.value===!0}),n))return Nh}}}),n},e.prototype.buildRootValueFromCache=function(t,n){return this.cache.diff({query:$9(t),variables:n,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(t,n,r,i,o,a){return r===void 0&&(r={}),i===void 0&&(i={}),o===void 0&&(o=function(){return!0}),a===void 0&&(a=!1),fe(this,void 0,void 0,function(){var s,c,l,u,d,f,h,p,m,v,b;return nr(this,function(y){return s=Dh(t),c=Mh(t),l=Ph(c),u=this.collectSelectionsToResolve(s,l),d=s.operation,f=d?d.charAt(0).toUpperCase()+d.slice(1):"Query",h=this,p=h.cache,m=h.client,v={fragmentMap:l,context:N(N({},r),{cache:p,client:m}),variables:i,fragmentMatcher:o,defaultOperationType:f,exportedVariables:{},selectionsToResolve:u,onlyRunForcedResolvers:a},b=!1,[2,this.resolveSelectionSet(s.selectionSet,b,n,v).then(function(g){return{result:g,exportedVariables:v.exportedVariables}})]})})},e.prototype.resolveSelectionSet=function(t,n,r,i){return fe(this,void 0,void 0,function(){var o,a,s,c,l,u=this;return nr(this,function(d){return o=i.fragmentMap,a=i.context,s=i.variables,c=[r],l=function(f){return fe(u,void 0,void 0,function(){var h,p;return nr(this,function(m){return!n&&!i.selectionsToResolve.has(f)?[2]:Dc(f,s)?Gr(f)?[2,this.resolveField(f,n,r,i).then(function(v){var b;typeof v<"u"&&c.push((b={},b[Wr(f)]=v,b))})]:(p9(f)?h=f:(h=o[f.name.value],__DEV__?K(h,"No fragment named ".concat(f.name.value)):K(h,11)),h&&h.typeCondition&&(p=h.typeCondition.name.value,i.fragmentMatcher(r,p,a))?[2,this.resolveSelectionSet(h.selectionSet,n,r,i).then(function(v){c.push(v)})]:[2]):[2]})})},[2,Promise.all(t.selections.map(l)).then(function(){return Fh(c)})]})})},e.prototype.resolveField=function(t,n,r,i){return fe(this,void 0,void 0,function(){var o,a,s,c,l,u,d,f,h,p=this;return nr(this,function(m){return r?(o=i.variables,a=t.name.value,s=Wr(t),c=a!==s,l=r[s]||r[a],u=Promise.resolve(l),(!i.onlyRunForcedResolvers||this.shouldForceResolvers(t))&&(d=r.__typename||i.defaultOperationType,f=this.resolvers&&this.resolvers[d],f&&(h=f[c?a:s],h&&(u=Promise.resolve(Wh.withValue(this.cache,h,[r,Lc(t,o),i.context,{field:t,fragmentMap:i.fragmentMap}]))))),[2,u.then(function(v){var b,y;if(v===void 0&&(v=l),t.directives&&t.directives.forEach(function(_){_.name.value==="export"&&_.arguments&&_.arguments.forEach(function(x){x.name.value==="as"&&x.value.kind==="StringValue"&&(i.exportedVariables[x.value.value]=v)})}),!t.selectionSet||v==null)return v;var g=(y=(b=t.directives)===null||b===void 0?void 0:b.some(function(_){return _.name.value==="client"}))!==null&&y!==void 0?y:!1;if(Array.isArray(v))return p.resolveSubSelectedArray(t,n||g,v,i);if(t.selectionSet)return p.resolveSelectionSet(t.selectionSet,n||g,v,i)})]):[2,null]})})},e.prototype.resolveSubSelectedArray=function(t,n,r,i){var o=this;return Promise.all(r.map(function(a){if(a===null)return null;if(Array.isArray(a))return o.resolveSubSelectedArray(t,n,a,i);if(t.selectionSet)return o.resolveSelectionSet(t.selectionSet,n,a,i)}))},e.prototype.collectSelectionsToResolve=function(t,n){var r=function(a){return!Array.isArray(a)},i=this.selectionsToResolveCache;function o(a){if(!i.has(a)){var s=new Set;i.set(a,s),Wn(a,{Directive:function(c,l,u,d,f){c.name.value==="client"&&f.forEach(function(h){r(h)&&Zp(h)&&s.add(h)})},FragmentSpread:function(c,l,u,d,f){var h=n[c.name.value];__DEV__?K(h,"No fragment named ".concat(c.name.value)):K(h,12);var p=o(h);p.size>0&&(f.forEach(function(m){r(m)&&Zp(m)&&s.add(m)}),s.add(c),p.forEach(function(m){s.add(m)}))}})}return i.get(a)}return o(t)},e}(),_i=new(ti?WeakMap:Map);function Ru(e,t){var n=e[t];typeof n=="function"&&(e[t]=function(){return _i.set(e,(_i.get(e)+1)%1e15),n.apply(this,arguments)})}function R2(e){e.notifyTimeout&&(clearTimeout(e.notifyTimeout),e.notifyTimeout=void 0)}var Fu=function(){function e(t,n){n===void 0&&(n=t.generateQueryId()),this.queryId=n,this.listeners=new Set,this.document=null,this.lastRequestId=1,this.subscriptions=new Set,this.stopped=!1,this.dirty=!1,this.observableQuery=null;var r=this.cache=t.cache;_i.has(r)||(_i.set(r,0),Ru(r,"evict"),Ru(r,"modify"),Ru(r,"reset"))}return e.prototype.init=function(t){var n=t.networkStatus||De.loading;return this.variables&&this.networkStatus!==De.loading&&!ut(this.variables,t.variables)&&(n=De.setVariables),ut(t.variables,this.variables)||(this.lastDiff=void 0),Object.assign(this,{document:t.document,variables:t.variables,networkError:null,graphQLErrors:this.graphQLErrors||[],networkStatus:n}),t.observableQuery&&this.setObservableQuery(t.observableQuery),t.lastRequestId&&(this.lastRequestId=t.lastRequestId),this},e.prototype.reset=function(){R2(this),this.dirty=!1},e.prototype.getDiff=function(t){t===void 0&&(t=this.variables);var n=this.getDiffOptions(t);if(this.lastDiff&&ut(n,this.lastDiff.options))return this.lastDiff.diff;this.updateWatch(this.variables=t);var r=this.observableQuery;if(r&&r.options.fetchPolicy==="no-cache")return{complete:!1};var i=this.cache.diff(n);return this.updateLastDiff(i,n),i},e.prototype.updateLastDiff=function(t,n){this.lastDiff=t?{diff:t,options:n||this.getDiffOptions()}:void 0},e.prototype.getDiffOptions=function(t){var n;return t===void 0&&(t=this.variables),{query:this.document,variables:t,returnPartialData:!0,optimistic:!0,canonizeResults:(n=this.observableQuery)===null||n===void 0?void 0:n.options.canonizeResults}},e.prototype.setDiff=function(t){var n=this,r=this.lastDiff&&this.lastDiff.diff;this.updateLastDiff(t),!this.dirty&&!ut(r&&r.result,t&&t.result)&&(this.dirty=!0,this.notifyTimeout||(this.notifyTimeout=setTimeout(function(){return n.notify()},0)))},e.prototype.setObservableQuery=function(t){var n=this;t!==this.observableQuery&&(this.oqListener&&this.listeners.delete(this.oqListener),this.observableQuery=t,t?(t.queryInfo=this,this.listeners.add(this.oqListener=function(){var r=n.getDiff();r.fromOptimisticTransaction?t.observe():u3(t)})):delete this.oqListener)},e.prototype.notify=function(){var t=this;R2(this),this.shouldNotify()&&this.listeners.forEach(function(n){return n(t)}),this.dirty=!1},e.prototype.shouldNotify=function(){if(!this.dirty||!this.listeners.size)return!1;if(na(this.networkStatus)&&this.observableQuery){var t=this.observableQuery.options.fetchPolicy;if(t!=="cache-only"&&t!=="cache-and-network")return!1}return!0},e.prototype.stop=function(){if(!this.stopped){this.stopped=!0,this.reset(),this.cancel(),this.cancel=e.prototype.cancel,this.subscriptions.forEach(function(n){return n.unsubscribe()});var t=this.observableQuery;t&&t.stopPolling()}},e.prototype.cancel=function(){},e.prototype.updateWatch=function(t){var n=this;t===void 0&&(t=this.variables);var r=this.observableQuery;if(!(r&&r.options.fetchPolicy==="no-cache")){var i=N(N({},this.getDiffOptions(t)),{watcher:this,callback:function(o){return n.setDiff(o)}});(!this.lastWatch||!ut(i,this.lastWatch))&&(this.cancel(),this.cancel=this.cache.watch(this.lastWatch=i))}},e.prototype.resetLastWrite=function(){this.lastWrite=void 0},e.prototype.shouldWrite=function(t,n){var r=this.lastWrite;return!(r&&r.dmCount===_i.get(this.cache)&&ut(n,r.variables)&&ut(t.data,r.result.data))},e.prototype.markResult=function(t,n,r,i){var o=this,a=new vr,s=rn(t.errors)?t.errors.slice(0):[];if(this.reset(),"incremental"in t&&rn(t.incremental)){var c=Ry(this.getDiff().result,t);t.data=c}else if("hasNext"in t&&t.hasNext){var l=this.getDiff();t.data=a.merge(l.result,t.data)}this.graphQLErrors=s,r.fetchPolicy==="no-cache"?this.updateLastDiff({result:t.data,complete:!0},this.getDiffOptions(r.variables)):i!==0&&(v0(t,r.errorPolicy)?this.cache.performTransaction(function(u){if(o.shouldWrite(t,r.variables))u.writeQuery({query:n,data:t.data,variables:r.variables,overwrite:i===1}),o.lastWrite={result:t,variables:r.variables,dmCount:_i.get(o.cache)};else if(o.lastDiff&&o.lastDiff.diff.complete){t.data=o.lastDiff.diff.result;return}var d=o.getDiffOptions(r.variables),f=u.diff(d);o.stopped||o.updateWatch(r.variables),o.updateLastDiff(f,d),f.complete&&(t.data=f.result)}):this.lastWrite=void 0)},e.prototype.markReady=function(){return this.networkError=null,this.networkStatus=De.ready},e.prototype.markError=function(t){return this.networkStatus=De.error,this.lastWrite=void 0,this.reset(),t.graphQLErrors&&(this.graphQLErrors=t.graphQLErrors),t.networkError&&(this.networkError=t.networkError),t},e}();function v0(e,t){t===void 0&&(t="none");var n=t==="ignore"||t==="all",r=!fs(e);return!r&&n&&e.data&&(r=!0),r}var l_=Object.prototype.hasOwnProperty,c_=function(){function e(t){var n=t.cache,r=t.link,i=t.defaultOptions,o=t.queryDeduplication,a=o===void 0?!1:o,s=t.onBroadcast,c=t.ssrMode,l=c===void 0?!1:c,u=t.clientAwareness,d=u===void 0?{}:u,f=t.localState,h=t.assumeImmutableResults;this.clientAwareness={},this.queries=new Map,this.fetchCancelFns=new Map,this.transformCache=new(ti?WeakMap:Map),this.queryIdCounter=1,this.requestIdCounter=1,this.mutationIdCounter=1,this.inFlightLinkObservables=new Map,this.cache=n,this.link=r,this.defaultOptions=i||Object.create(null),this.queryDeduplication=a,this.clientAwareness=d,this.localState=f||new f3({cache:n}),this.ssrMode=l,this.assumeImmutableResults=!!h,(this.onBroadcast=s)&&(this.mutationStore=Object.create(null))}return e.prototype.stop=function(){var t=this;this.queries.forEach(function(n,r){t.stopQueryNoBroadcast(r)}),this.cancelPendingFetches(__DEV__?new Se("QueryManager stopped while query was in flight"):new Se(14))},e.prototype.cancelPendingFetches=function(t){this.fetchCancelFns.forEach(function(n){return n(t)}),this.fetchCancelFns.clear()},e.prototype.mutate=function(t){var n,r,i=t.mutation,o=t.variables,a=t.optimisticResponse,s=t.updateQueries,c=t.refetchQueries,l=c===void 0?[]:c,u=t.awaitRefetchQueries,d=u===void 0?!1:u,f=t.update,h=t.onQueryUpdated,p=t.fetchPolicy,m=p===void 0?((n=this.defaultOptions.mutate)===null||n===void 0?void 0:n.fetchPolicy)||"network-only":p,v=t.errorPolicy,b=v===void 0?((r=this.defaultOptions.mutate)===null||r===void 0?void 0:r.errorPolicy)||"none":v,y=t.keepRootFields,g=t.context;return fe(this,void 0,void 0,function(){var _,x,O,C,M,D;return nr(this,function(F){switch(F.label){case 0:return __DEV__?K(i,"mutation option is required. You must specify your GraphQL document in the mutation option."):K(i,15),__DEV__?K(m==="network-only"||m==="no-cache","Mutations support only 'network-only' or 'no-cache' fetchPolicy strings. The default `network-only` behavior automatically writes mutation results to the cache. Passing `no-cache` skips the cache write."):K(m==="network-only"||m==="no-cache",16),_=this.generateMutationId(),x=this.transform(i),O=x.document,C=x.hasClientExports,i=this.cache.transformForLink(O),o=this.getVariables(i,o),C?[4,this.localState.addExportedVariables(i,o,g)]:[3,2];case 1:o=F.sent(),F.label=2;case 2:return M=this.mutationStore&&(this.mutationStore[_]={mutation:i,variables:o,loading:!0,error:null}),a&&this.markMutationOptimistic(a,{mutationId:_,document:i,variables:o,fetchPolicy:m,errorPolicy:b,context:g,updateQueries:s,update:f,keepRootFields:y}),this.broadcastQueries(),D=this,[2,new Promise(function(Y,J){return Nu(D.getObservableFromLink(i,N(N({},g),{optimisticResponse:a}),o,!1),function(G){if(fs(G)&&b==="none")throw new si({graphQLErrors:n0(G)});M&&(M.loading=!1,M.error=null);var j=N({},G);return typeof l=="function"&&(l=l(j)),b==="ignore"&&fs(j)&&delete j.errors,D.markMutationResult({mutationId:_,result:j,document:i,variables:o,fetchPolicy:m,errorPolicy:b,context:g,update:f,updateQueries:s,awaitRefetchQueries:d,refetchQueries:l,removeOptimistic:a?_:void 0,onQueryUpdated:h,keepRootFields:y})}).subscribe({next:function(G){D.broadcastQueries(),(!("hasNext"in G)||G.hasNext===!1)&&Y(G)},error:function(G){M&&(M.loading=!1,M.error=G),a&&D.cache.removeOptimistic(_),D.broadcastQueries(),J(G instanceof si?G:new si({networkError:G}))}})})]}})})},e.prototype.markMutationResult=function(t,n){var r=this;n===void 0&&(n=this.cache);var i=t.result,o=[],a=t.fetchPolicy==="no-cache";if(!a&&v0(i,t.errorPolicy)){if(Oi(i)||o.push({result:i.data,dataId:"ROOT_MUTATION",query:t.document,variables:t.variables}),Oi(i)&&rn(i.incremental)){var s=n.diff({id:"ROOT_MUTATION",query:this.transform(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0}),c=void 0;s.result&&(c=Ry(s.result,i)),typeof c<"u"&&(i.data=c,o.push({result:c,dataId:"ROOT_MUTATION",query:t.document,variables:t.variables}))}var l=t.updateQueries;l&&this.queries.forEach(function(d,f){var h=d.observableQuery,p=h&&h.queryName;if(!(!p||!l_.call(l,p))){var m=l[p],v=r.queries.get(f),b=v.document,y=v.variables,g=n.diff({query:b,variables:y,returnPartialData:!0,optimistic:!1}),_=g.result,x=g.complete;if(x&&_){var O=m(_,{mutationResult:i,queryName:b&&Xd(b)||void 0,queryVariables:y});O&&o.push({result:O,dataId:"ROOT_QUERY",query:b,variables:y})}}})}if(o.length>0||t.refetchQueries||t.update||t.onQueryUpdated||t.removeOptimistic){var u=[];if(this.refetchQueries({updateCache:function(d){a||o.forEach(function(m){return d.write(m)});var f=t.update,h=!R9(i)||Oi(i)&&!i.hasNext;if(f){if(!a){var p=d.diff({id:"ROOT_MUTATION",query:r.transform(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0});p.complete&&(i=N(N({},i),{data:p.result}),"incremental"in i&&delete i.incremental,"hasNext"in i&&delete i.hasNext)}h&&f(d,i,{context:t.context,variables:t.variables})}!a&&!t.keepRootFields&&h&&d.modify({id:"ROOT_MUTATION",fields:function(m,v){var b=v.fieldName,y=v.DELETE;return b==="__typename"?m:y}})},include:t.refetchQueries,optimistic:!1,removeOptimistic:t.removeOptimistic,onQueryUpdated:t.onQueryUpdated||null}).forEach(function(d){return u.push(d)}),t.awaitRefetchQueries||t.onQueryUpdated)return Promise.all(u).then(function(){return i})}return Promise.resolve(i)},e.prototype.markMutationOptimistic=function(t,n){var r=this,i=typeof t=="function"?t(n.variables):t;return this.cache.recordOptimisticTransaction(function(o){try{r.markMutationResult(N(N({},n),{result:{data:i}}),o)}catch(a){__DEV__&&K.error(a)}},n.mutationId)},e.prototype.fetchQuery=function(t,n,r){return this.fetchQueryObservable(t,n,r).promise},e.prototype.getQueryStore=function(){var t=Object.create(null);return this.queries.forEach(function(n,r){t[r]={variables:n.variables,networkStatus:n.networkStatus,networkError:n.networkError,graphQLErrors:n.graphQLErrors}}),t},e.prototype.resetErrors=function(t){var n=this.queries.get(t);n&&(n.networkError=void 0,n.graphQLErrors=[])},e.prototype.transform=function(t){var n=this.transformCache;if(!n.has(t)){var r=this.cache.transformDocument(t),i=b9(r),o=this.localState.clientQuery(r),a=i&&this.localState.serverQuery(i),s={document:r,hasClientExports:X$(r),hasForcedResolvers:this.localState.shouldForceResolvers(r),clientQuery:o,serverQuery:a,defaultVars:Lh($a(r)),asQuery:N(N({},r),{definitions:r.definitions.map(function(l){return l.kind==="OperationDefinition"&&l.operation!=="query"?N(N({},l),{operation:"query"}):l})})},c=function(l){l&&!n.has(l)&&n.set(l,s)};c(t),c(r),c(o),c(a)}return n.get(t)},e.prototype.getVariables=function(t,n){return N(N({},this.transform(t).defaultVars),n)},e.prototype.watchQuery=function(t){t=N(N({},t),{variables:this.getVariables(t.query,t.variables)}),typeof t.notifyOnNetworkStatusChange>"u"&&(t.notifyOnNetworkStatusChange=!1);var n=new Fu(this),r=new m0({queryManager:this,queryInfo:n,options:t});return this.queries.set(r.queryId,n),n.init({document:r.query,observableQuery:r,variables:r.variables}),r},e.prototype.query=function(t,n){var r=this;return n===void 0&&(n=this.generateQueryId()),__DEV__?K(t.query,"query option is required. You must specify your GraphQL document in the query option."):K(t.query,17),__DEV__?K(t.query.kind==="Document",'You must wrap the query string in a "gql" tag.'):K(t.query.kind==="Document",18),__DEV__?K(!t.returnPartialData,"returnPartialData option only supported on watchQuery."):K(!t.returnPartialData,19),__DEV__?K(!t.pollInterval,"pollInterval option only supported on watchQuery."):K(!t.pollInterval,20),this.fetchQuery(n,t).finally(function(){return r.stopQuery(n)})},e.prototype.generateQueryId=function(){return String(this.queryIdCounter++)},e.prototype.generateRequestId=function(){return this.requestIdCounter++},e.prototype.generateMutationId=function(){return String(this.mutationIdCounter++)},e.prototype.stopQueryInStore=function(t){this.stopQueryInStoreNoBroadcast(t),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(t){var n=this.queries.get(t);n&&n.stop()},e.prototype.clearStore=function(t){return t===void 0&&(t={discardWatches:!0}),this.cancelPendingFetches(__DEV__?new Se("Store reset while query was in flight (not completed in link chain)"):new Se(21)),this.queries.forEach(function(n){n.observableQuery?n.networkStatus=De.loading:n.stop()}),this.mutationStore&&(this.mutationStore=Object.create(null)),this.cache.reset(t)},e.prototype.getObservableQueries=function(t){var n=this;t===void 0&&(t="active");var r=new Map,i=new Map,o=new Set;return Array.isArray(t)&&t.forEach(function(a){typeof a=="string"?i.set(a,!1):t9(a)?i.set(n.transform(a).document,!1):Ye(a)&&a.query&&o.add(a)}),this.queries.forEach(function(a,s){var c=a.observableQuery,l=a.document;if(c){if(t==="all"){r.set(s,c);return}var u=c.queryName,d=c.options.fetchPolicy;if(d==="standby"||t==="active"&&!c.hasObservers())return;(t==="active"||u&&i.has(u)||l&&i.has(l))&&(r.set(s,c),u&&i.set(u,!0),l&&i.set(l,!0))}}),o.size&&o.forEach(function(a){var s=r0("legacyOneTimeQuery"),c=n.getQuery(s).init({document:a.query,variables:a.variables}),l=new m0({queryManager:n,queryInfo:c,options:N(N({},a),{fetchPolicy:"network-only"})});K(l.queryId===s),c.setObservableQuery(l),r.set(s,l)}),__DEV__&&i.size&&i.forEach(function(a,s){a||__DEV__&&K.warn("Unknown query ".concat(typeof s=="string"?"named ":"").concat(JSON.stringify(s,null,2)," requested in refetchQueries options.include array"))}),r},e.prototype.reFetchObservableQueries=function(t){var n=this;t===void 0&&(t=!1);var r=[];return this.getObservableQueries(t?"all":"active").forEach(function(i,o){var a=i.options.fetchPolicy;i.resetLastResults(),(t||a!=="standby"&&a!=="cache-only")&&r.push(i.refetch()),n.getQuery(o).setDiff(null)}),this.broadcastQueries(),Promise.all(r)},e.prototype.setObservableQuery=function(t){this.getQuery(t.queryId).setObservableQuery(t)},e.prototype.startGraphQLSubscription=function(t){var n=this,r=t.query,i=t.fetchPolicy,o=t.errorPolicy,a=t.variables,s=t.context,c=s===void 0?{}:s;r=this.transform(r).document,a=this.getVariables(r,a);var l=function(d){return n.getObservableFromLink(r,c,d).map(function(f){if(i!=="no-cache"&&(v0(f,o)&&n.cache.write({query:r,result:f.data,dataId:"ROOT_SUBSCRIPTION",variables:d}),n.broadcastQueries()),fs(f))throw new si({graphQLErrors:f.errors});return f})};if(this.transform(r).hasClientExports){var u=this.localState.addExportedVariables(r,a,c).then(l);return new Le(function(d){var f=null;return u.then(function(h){return f=h.subscribe(d)},d.error),function(){return f&&f.unsubscribe()}})}return l(a)},e.prototype.stopQuery=function(t){this.stopQueryNoBroadcast(t),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(t){this.stopQueryInStoreNoBroadcast(t),this.removeQuery(t)},e.prototype.removeQuery=function(t){this.fetchCancelFns.delete(t),this.queries.has(t)&&(this.getQuery(t).stop(),this.queries.delete(t))},e.prototype.broadcastQueries=function(){this.onBroadcast&&this.onBroadcast(),this.queries.forEach(function(t){return t.notify()})},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(t,n,r,i){var o=this,a;i===void 0&&(i=(a=n?.queryDeduplication)!==null&&a!==void 0?a:this.queryDeduplication);var s,c=this.transform(t).serverQuery;if(c){var l=this,u=l.inFlightLinkObservables,d=l.link,f={query:c,variables:r,operationName:Xd(c)||void 0,context:this.prepareContext(N(N({},n),{forceFetch:!i}))};if(n=f.context,i){var h=u.get(c)||new Map;u.set(c,h);var p=jr(r);if(s=h.get(p),!s){var m=new Lo([o0(d,f)]);h.set(p,s=m),m.beforeNext(function(){h.delete(p)&&h.size<1&&u.delete(c)})}}else s=new Lo([o0(d,f)])}else s=new Lo([Le.of({data:{}})]),n=this.prepareContext(n);var v=this.transform(t).clientQuery;return v&&(s=Nu(s,function(b){return o.localState.runResolvers({document:v,remoteResult:b,context:n,variables:r})})),s},e.prototype.getResultsFromLink=function(t,n,r){var i=t.lastRequestId=this.generateRequestId(),o=this.cache.transformForLink(this.transform(t.document).document);return Nu(this.getObservableFromLink(o,r.context,r.variables),function(a){var s=n0(a),c=s.length>0;if(i>=t.lastRequestId){if(c&&r.errorPolicy==="none")throw t.markError(new si({graphQLErrors:s}));t.markResult(a,o,r,n),t.markReady()}var l={data:a.data,loading:!1,networkStatus:De.ready};return c&&r.errorPolicy!=="ignore"&&(l.errors=s,l.networkStatus=De.error),l},function(a){var s=r_(a)?a:new si({networkError:a});throw i>=t.lastRequestId&&t.markError(s),s})},e.prototype.fetchQueryObservable=function(t,n,r){var i=this;r===void 0&&(r=De.loading);var o=this.transform(n.query).document,a=this.getVariables(o,n.variables),s=this.getQuery(t),c=this.defaultOptions.watchQuery,l=n.fetchPolicy,u=l===void 0?c&&c.fetchPolicy||"cache-first":l,d=n.errorPolicy,f=d===void 0?c&&c.errorPolicy||"none":d,h=n.returnPartialData,p=h===void 0?!1:h,m=n.notifyOnNetworkStatusChange,v=m===void 0?!1:m,b=n.context,y=b===void 0?{}:b,g=Object.assign({},n,{query:o,variables:a,fetchPolicy:u,errorPolicy:f,returnPartialData:p,notifyOnNetworkStatusChange:v,context:y}),_=function(C){g.variables=C;var M=i.fetchQueryByPolicy(s,g,r);return g.fetchPolicy!=="standby"&&M.length>0&&s.observableQuery&&s.observableQuery.applyNextFetchPolicy("after-fetch",n),M},x=function(){return i.fetchCancelFns.delete(t)};this.fetchCancelFns.set(t,function(C){x(),setTimeout(function(){return O.cancel(C)})});var O=new Lo(this.transform(g.query).hasClientExports?this.localState.addExportedVariables(g.query,g.variables,g.context).then(_):_(g.variables));return O.promise.then(x,x),O},e.prototype.refetchQueries=function(t){var n=this,r=t.updateCache,i=t.include,o=t.optimistic,a=o===void 0?!1:o,s=t.removeOptimistic,c=s===void 0?a?r0("refetchQueries"):void 0:s,l=t.onQueryUpdated,u=new Map;i&&this.getObservableQueries(i).forEach(function(f,h){u.set(h,{oq:f,lastDiff:n.getQuery(h).getDiff()})});var d=new Map;return r&&this.cache.batch({update:r,optimistic:a&&c||!1,removeOptimistic:c,onWatchUpdated:function(f,h,p){var m=f.watcher instanceof Fu&&f.watcher.observableQuery;if(m){if(l){u.delete(m.queryId);var v=l(m,h,p);return v===!0&&(v=m.refetch()),v!==!1&&d.set(m,v),v}l!==null&&u.set(m.queryId,{oq:m,lastDiff:p,diff:h})}}}),u.size&&u.forEach(function(f,h){var p=f.oq,m=f.lastDiff,v=f.diff,b;if(l){if(!v){var y=p.queryInfo;y.reset(),v=y.getDiff()}b=l(p,v,m)}(!l||b===!0)&&(b=p.refetch()),b!==!1&&d.set(p,b),h.indexOf("legacyOneTimeQuery")>=0&&n.stopQueryNoBroadcast(h)}),c&&this.cache.removeOptimistic(c),d},e.prototype.fetchQueryByPolicy=function(t,n,r){var i=this,o=n.query,a=n.variables,s=n.fetchPolicy,c=n.refetchWritePolicy,l=n.errorPolicy,u=n.returnPartialData,d=n.context,f=n.notifyOnNetworkStatusChange,h=t.networkStatus;t.init({document:this.transform(o).document,variables:a,networkStatus:r});var p=function(){return t.getDiff(a)},m=function(_,x){x===void 0&&(x=t.networkStatus||De.loading);var O=_.result;__DEV__&&!u&&!ut(O,{})&&d3(_.missing);var C=function(M){return Le.of(N({data:M,loading:na(x),networkStatus:x},_.complete?null:{partial:!0}))};return O&&i.transform(o).hasForcedResolvers?i.localState.runResolvers({document:o,remoteResult:{data:O},context:d,variables:a,onlyRunForcedResolvers:!0}).then(function(M){return C(M.data||void 0)}):l==="none"&&x===De.refetch&&Array.isArray(_.missing)?C(void 0):C(O)},v=s==="no-cache"?0:r===De.refetch&&c!=="merge"?1:2,b=function(){return i.getResultsFromLink(t,v,{variables:a,context:d,fetchPolicy:s,errorPolicy:l})},y=f&&typeof h=="number"&&h!==r&&na(r);switch(s){default:case"cache-first":{var g=p();return g.complete?[m(g,t.markReady())]:u||y?[m(g),b()]:[b()]}case"cache-and-network":{var g=p();return g.complete||u||y?[m(g),b()]:[b()]}case"cache-only":return[m(p(),t.markReady())];case"network-only":return y?[m(p()),b()]:[b()];case"no-cache":return y?[m(t.getDiff()),b()]:[b()];case"standby":return[]}},e.prototype.getQuery=function(t){return t&&!this.queries.has(t)&&this.queries.set(t,new Fu(this,t)),this.queries.get(t)},e.prototype.prepareContext=function(t){t===void 0&&(t={});var n=this.localState.prepareContext(t);return N(N({},n),{clientAwareness:this.clientAwareness})},e}(),F2=!1,u_=function(){function e(t){var n=this;this.resetStoreCallbacks=[],this.clearStoreCallbacks=[];var r=t.uri,i=t.credentials,o=t.headers,a=t.cache,s=t.ssrMode,c=s===void 0?!1:s,l=t.ssrForceFetchDelay,u=l===void 0?0:l,d=t.connectToDevTools,f=d===void 0?typeof window=="object"&&!window.__APOLLO_CLIENT__&&__DEV__:d,h=t.queryDeduplication,p=h===void 0?!0:h,m=t.defaultOptions,v=t.assumeImmutableResults,b=v===void 0?!1:v,y=t.resolvers,g=t.typeDefs,_=t.fragmentMatcher,x=t.name,O=t.version,C=t.link;if(C||(C=r?new zy({uri:r,credentials:i,headers:o}):io.empty()),!a)throw __DEV__?new Se(`To initialize Apollo Client, you must specify a 'cache' property in the options object.
|
|
69
|
-
For more information, please visit: https://go.apollo.dev/c/docs`):new Se(9);if(this.link=C,this.cache=a,this.disableNetworkFetches=c||u>0,this.queryDeduplication=p,this.defaultOptions=m||Object.create(null),this.typeDefs=g,u&&setTimeout(function(){return n.disableNetworkFetches=!1},u),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),f&&typeof window=="object"&&(window.__APOLLO_CLIENT__=this),!F2&&f&&__DEV__&&(F2=!0,typeof window<"u"&&window.document&&window.top===window.self&&!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__)){var M=window.navigator,D=M&&M.userAgent,F=void 0;typeof D=="string"&&(D.indexOf("Chrome/")>-1?F="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":D.indexOf("Firefox/")>-1&&(F="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),F&&__DEV__&&K.log("Download the Apollo DevTools for a better development experience: "+F)}this.version=B9,this.localState=new f3({cache:a,client:this,resolvers:y,fragmentMatcher:_}),this.queryManager=new c_({cache:this.cache,link:this.link,defaultOptions:this.defaultOptions,queryDeduplication:p,ssrMode:c,clientAwareness:{name:
|
|
67
|
+
`)),t=t.replace(/\n$/,""),t},si=function(e){yn(t,e);function t(n){var r=n.graphQLErrors,i=n.clientErrors,o=n.networkError,a=n.errorMessage,s=n.extraInfo,c=e.call(this,a)||this;return c.name="ApolloError",c.graphQLErrors=r||[],c.clientErrors=i||[],c.networkError=o||null,c.message=a||i_(c),c.extraInfo=s,c.__proto__=t.prototype,c}return t}(Error),De;(function(e){e[e.loading=1]="loading",e[e.setVariables=2]="setVariables",e[e.fetchMore=3]="fetchMore",e[e.refetch=4]="refetch",e[e.poll=6]="poll",e[e.ready=7]="ready",e[e.error=8]="error"})(De||(De={}));function na(e){return e?e<7:!1}var o_=Object.assign,a_=Object.hasOwnProperty,m0=function(e){yn(t,e);function t(n){var r=n.queryManager,i=n.queryInfo,o=n.options,a=e.call(this,function(v){try{var b=v._subscription._observer;b&&!b.error&&(b.error=s_)}catch{}var y=!a.observers.size;a.observers.add(v);var g=a.last;return g&&g.error?v.error&&v.error(g.error):g&&g.result&&v.next&&v.next(g.result),y&&a.reobserve().catch(function(){}),function(){a.observers.delete(v)&&!a.observers.size&&a.tearDownQuery()}})||this;a.observers=new Set,a.subscriptions=new Set,a.queryInfo=i,a.queryManager=r,a.isTornDown=!1;var s=r.defaultOptions.watchQuery,c=s===void 0?{}:s,l=c.fetchPolicy,u=l===void 0?"cache-first":l,d=o.fetchPolicy,f=d===void 0?u:d,h=o.initialFetchPolicy,p=h===void 0?f==="standby"?u:f:h;a.options=T(T({},o),{initialFetchPolicy:p,fetchPolicy:f}),a.queryId=i.queryId||r.generateQueryId();var m=$a(a.query);return a.queryName=m&&m.name&&m.name.value,a}return Object.defineProperty(t.prototype,"query",{get:function(){return this.queryManager.transform(this.options.query).document},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"variables",{get:function(){return this.options.variables},enumerable:!1,configurable:!0}),t.prototype.result=function(){var n=this;return new Promise(function(r,i){var o={next:function(s){r(s),n.observers.delete(o),n.observers.size||n.queryManager.removeQuery(n.queryId),setTimeout(function(){a.unsubscribe()},0)},error:i},a=n.subscribe(o)})},t.prototype.getCurrentResult=function(n){n===void 0&&(n=!0);var r=this.getLastResult(!0),i=this.queryInfo.networkStatus||r&&r.networkStatus||De.ready,o=T(T({},r),{loading:na(i),networkStatus:i}),a=this.options.fetchPolicy,s=a===void 0?"cache-first":a;if(!(s==="network-only"||s==="no-cache"||s==="standby"||this.queryManager.transform(this.options.query).hasForcedResolvers)){var c=this.queryInfo.getDiff();(c.complete||this.options.returnPartialData)&&(o.data=c.result),ut(o.data,{})&&(o.data=void 0),c.complete?(delete o.partial,c.complete&&o.networkStatus===De.loading&&(s==="cache-first"||s==="cache-only")&&(o.networkStatus=De.ready,o.loading=!1)):o.partial=!0,__DEV__&&!c.complete&&!this.options.partialRefetch&&!o.loading&&!o.data&&!o.error&&d3(c.missing)}return n&&this.updateLastResult(o),o},t.prototype.isDifferentFromLastResult=function(n,r){return!this.last||!ut(this.last.result,n)||r&&!ut(this.last.variables,r)},t.prototype.getLast=function(n,r){var i=this.last;if(i&&i[n]&&(!r||ut(i.variables,this.variables)))return i[n]},t.prototype.getLastResult=function(n){return this.getLast("result",n)},t.prototype.getLastError=function(n){return this.getLast("error",n)},t.prototype.resetLastResults=function(){delete this.last,this.isTornDown=!1},t.prototype.resetQueryStoreErrors=function(){this.queryManager.resetErrors(this.queryId)},t.prototype.refetch=function(n){var r,i={pollInterval:0},o=this.options.fetchPolicy;if(o==="cache-and-network"?i.fetchPolicy=o:o==="no-cache"?i.fetchPolicy="no-cache":i.fetchPolicy="network-only",__DEV__&&n&&a_.call(n,"variables")){var a=Cy(this.query),s=a.variableDefinitions;(!s||!s.some(function(c){return c.variable.name.value==="variables"}))&&__DEV__&&K.warn("Called refetch(".concat(JSON.stringify(n),") for query ").concat(((r=a.name)===null||r===void 0?void 0:r.value)||JSON.stringify(a),`, which does not declare a $variables variable.
|
|
68
|
+
Did you mean to call refetch(variables) instead of refetch({ variables })?`))}return n&&!ut(this.options.variables,n)&&(i.variables=this.options.variables=T(T({},this.options.variables),n)),this.queryInfo.resetLastWrite(),this.reobserve(i,De.refetch)},t.prototype.fetchMore=function(n){var r=this,i=T(T({},n.query?n:T(T(T(T({},this.options),{query:this.query}),n),{variables:T(T({},this.options.variables),n.variables)})),{fetchPolicy:"no-cache"}),o=this.queryManager.generateQueryId(),a=this.queryInfo,s=a.networkStatus;a.networkStatus=De.fetchMore,i.notifyOnNetworkStatusChange&&this.observe();var c=new Set;return this.queryManager.fetchQuery(o,i,De.fetchMore).then(function(l){return r.queryManager.removeQuery(o),a.networkStatus===De.fetchMore&&(a.networkStatus=s),r.queryManager.cache.batch({update:function(u){var d=n.updateQuery;d?u.updateQuery({query:r.query,variables:r.variables,returnPartialData:!0,optimistic:!1},function(f){return d(f,{fetchMoreResult:l.data,variables:i.variables})}):u.writeQuery({query:i.query,variables:i.variables,data:l.data})},onWatchUpdated:function(u){c.add(u.query)}}),l}).finally(function(){c.has(r.query)||u3(r)})},t.prototype.subscribeToMore=function(n){var r=this,i=this.queryManager.startGraphQLSubscription({query:n.document,variables:n.variables,context:n.context}).subscribe({next:function(o){var a=n.updateQuery;a&&r.updateQuery(function(s,c){var l=c.variables;return a(s,{subscriptionData:o,variables:l})})},error:function(o){if(n.onError){n.onError(o);return}__DEV__&&K.error("Unhandled GraphQL subscription error",o)}});return this.subscriptions.add(i),function(){r.subscriptions.delete(i)&&i.unsubscribe()}},t.prototype.setOptions=function(n){return this.reobserve(n)},t.prototype.setVariables=function(n){return ut(this.variables,n)?this.observers.size?this.result():Promise.resolve():(this.options.variables=n,this.observers.size?this.reobserve({fetchPolicy:this.options.initialFetchPolicy,variables:n},De.setVariables):Promise.resolve())},t.prototype.updateQuery=function(n){var r=this.queryManager,i=r.cache.diff({query:this.options.query,variables:this.variables,returnPartialData:!0,optimistic:!1}).result,o=n(i,{variables:this.variables});o&&(r.cache.writeQuery({query:this.options.query,data:o,variables:this.variables}),r.broadcastQueries())},t.prototype.startPolling=function(n){this.options.pollInterval=n,this.updatePolling()},t.prototype.stopPolling=function(){this.options.pollInterval=0,this.updatePolling()},t.prototype.applyNextFetchPolicy=function(n,r){if(r.nextFetchPolicy){var i=r.fetchPolicy,o=i===void 0?"cache-first":i,a=r.initialFetchPolicy,s=a===void 0?o:a;o==="standby"||(typeof r.nextFetchPolicy=="function"?r.fetchPolicy=r.nextFetchPolicy(o,{reason:n,options:r,observable:this,initialFetchPolicy:s}):n==="variables-changed"?r.fetchPolicy=s:r.fetchPolicy=r.nextFetchPolicy)}return r.fetchPolicy},t.prototype.fetch=function(n,r){return this.queryManager.setObservableQuery(this),this.queryManager.fetchQueryObservable(this.queryId,n,r)},t.prototype.updatePolling=function(){var n=this;if(!this.queryManager.ssrMode){var r=this,i=r.pollingInfo,o=r.options.pollInterval;if(!o){i&&(clearTimeout(i.timeout),delete this.pollingInfo);return}if(!(i&&i.interval===o)){__DEV__?K(o,"Attempted to start a polling query without a polling interval."):K(o,13);var a=i||(this.pollingInfo={});a.interval=o;var s=function(){n.pollingInfo&&(na(n.queryInfo.networkStatus)?c():n.reobserve({fetchPolicy:n.options.initialFetchPolicy==="no-cache"?"no-cache":"network-only"},De.poll).then(c,c))},c=function(){var l=n.pollingInfo;l&&(clearTimeout(l.timeout),l.timeout=setTimeout(s,l.interval))};c()}}},t.prototype.updateLastResult=function(n,r){return r===void 0&&(r=this.variables),this.last=T(T({},this.last),{result:this.queryManager.assumeImmutableResults?n:My(n),variables:r}),rn(n.errors)||delete this.last.error,this.last},t.prototype.reobserve=function(n,r){var i=this;this.isTornDown=!1;var o=r===De.refetch||r===De.fetchMore||r===De.poll,a=this.options.variables,s=this.options.fetchPolicy,c=zc(this.options,n||{}),l=o?c:o_(this.options,c);o||(this.updatePolling(),n&&n.variables&&!ut(n.variables,a)&&l.fetchPolicy!=="standby"&&l.fetchPolicy===s&&(this.applyNextFetchPolicy("variables-changed",l),r===void 0&&(r=De.setVariables)));var u=l.variables&&T({},l.variables),d=this.fetch(l,r),f={next:function(h){i.reportResult(h,u)},error:function(h){i.reportError(h,u)}};return o||(this.concast&&this.observer&&this.concast.removeObserver(this.observer),this.concast=d,this.observer=f),d.addObserver(f),d.promise},t.prototype.observe=function(){this.reportResult(this.getCurrentResult(!1),this.variables)},t.prototype.reportResult=function(n,r){var i=this.getLastError();(i||this.isDifferentFromLastResult(n,r))&&((i||!n.partial||this.options.returnPartialData)&&this.updateLastResult(n,r),Vo(this.observers,"next",n))},t.prototype.reportError=function(n,r){var i=T(T({},this.getLastResult()),{error:n,errors:n.graphQLErrors,networkStatus:De.error,loading:!1});this.updateLastResult(i,r),Vo(this.observers,"error",this.last.error=n)},t.prototype.hasObservers=function(){return this.observers.size>0},t.prototype.tearDownQuery=function(){this.isTornDown||(this.concast&&this.observer&&(this.concast.removeObserver(this.observer),delete this.concast,delete this.observer),this.stopPolling(),this.subscriptions.forEach(function(n){return n.unsubscribe()}),this.subscriptions.clear(),this.queryManager.stopQuery(this.queryId),this.observers.clear(),this.isTornDown=!0)},t}(Le);Ly(m0);function u3(e){var t=e.options,n=t.fetchPolicy,r=t.nextFetchPolicy;return n==="cache-and-network"||n==="network-only"?e.reobserve({fetchPolicy:"cache-first",nextFetchPolicy:function(){return this.nextFetchPolicy=r,typeof r=="function"?r.apply(this,arguments):n}}):e.reobserve()}function s_(e){__DEV__&&K.error("Unhandled error",e.message,e.stack)}function d3(e){__DEV__&&e&&__DEV__&&K.debug("Missing cache result fields: ".concat(JSON.stringify(e)),e)}var f3=function(){function e(t){var n=t.cache,r=t.client,i=t.resolvers,o=t.fragmentMatcher;this.selectionsToResolveCache=new WeakMap,this.cache=n,r&&(this.client=r),i&&this.addResolvers(i),o&&this.setFragmentMatcher(o)}return e.prototype.addResolvers=function(t){var n=this;this.resolvers=this.resolvers||{},Array.isArray(t)?t.forEach(function(r){n.resolvers=t2(n.resolvers,r)}):this.resolvers=t2(this.resolvers,t)},e.prototype.setResolvers=function(t){this.resolvers={},this.addResolvers(t)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(t){var n=t.document,r=t.remoteResult,i=t.context,o=t.variables,a=t.onlyRunForcedResolvers,s=a===void 0?!1:a;return fe(this,void 0,void 0,function(){return nr(this,function(c){return n?[2,this.resolveDocument(n,r.data,i,o,this.fragmentMatcher,s).then(function(l){return T(T({},r),{data:l.result})})]:[2,r]})})},e.prototype.setFragmentMatcher=function(t){this.fragmentMatcher=t},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(t){return Th(["client"],t)&&this.resolvers?t:null},e.prototype.serverQuery=function(t){return w9(t)},e.prototype.prepareContext=function(t){var n=this.cache;return T(T({},t),{cache:n,getCacheKey:function(r){return n.identify(r)}})},e.prototype.addExportedVariables=function(t,n,r){return n===void 0&&(n={}),r===void 0&&(r={}),fe(this,void 0,void 0,function(){return nr(this,function(i){return t?[2,this.resolveDocument(t,this.buildRootValueFromCache(t,n)||{},this.prepareContext(r),n).then(function(o){return T(T({},n),o.exportedVariables)})]:[2,T({},n)]})})},e.prototype.shouldForceResolvers=function(t){var n=!1;return Wn(t,{Directive:{enter:function(r){if(r.name.value==="client"&&r.arguments&&(n=r.arguments.some(function(i){return i.name.value==="always"&&i.value.kind==="BooleanValue"&&i.value.value===!0}),n))return Nh}}}),n},e.prototype.buildRootValueFromCache=function(t,n){return this.cache.diff({query:$9(t),variables:n,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(t,n,r,i,o,a){return r===void 0&&(r={}),i===void 0&&(i={}),o===void 0&&(o=function(){return!0}),a===void 0&&(a=!1),fe(this,void 0,void 0,function(){var s,c,l,u,d,f,h,p,m,v,b;return nr(this,function(y){return s=Dh(t),c=Mh(t),l=Ph(c),u=this.collectSelectionsToResolve(s,l),d=s.operation,f=d?d.charAt(0).toUpperCase()+d.slice(1):"Query",h=this,p=h.cache,m=h.client,v={fragmentMap:l,context:T(T({},r),{cache:p,client:m}),variables:i,fragmentMatcher:o,defaultOperationType:f,exportedVariables:{},selectionsToResolve:u,onlyRunForcedResolvers:a},b=!1,[2,this.resolveSelectionSet(s.selectionSet,b,n,v).then(function(g){return{result:g,exportedVariables:v.exportedVariables}})]})})},e.prototype.resolveSelectionSet=function(t,n,r,i){return fe(this,void 0,void 0,function(){var o,a,s,c,l,u=this;return nr(this,function(d){return o=i.fragmentMap,a=i.context,s=i.variables,c=[r],l=function(f){return fe(u,void 0,void 0,function(){var h,p;return nr(this,function(m){return!n&&!i.selectionsToResolve.has(f)?[2]:Dc(f,s)?Gr(f)?[2,this.resolveField(f,n,r,i).then(function(v){var b;typeof v<"u"&&c.push((b={},b[Wr(f)]=v,b))})]:(p9(f)?h=f:(h=o[f.name.value],__DEV__?K(h,"No fragment named ".concat(f.name.value)):K(h,11)),h&&h.typeCondition&&(p=h.typeCondition.name.value,i.fragmentMatcher(r,p,a))?[2,this.resolveSelectionSet(h.selectionSet,n,r,i).then(function(v){c.push(v)})]:[2]):[2]})})},[2,Promise.all(t.selections.map(l)).then(function(){return Fh(c)})]})})},e.prototype.resolveField=function(t,n,r,i){return fe(this,void 0,void 0,function(){var o,a,s,c,l,u,d,f,h,p=this;return nr(this,function(m){return r?(o=i.variables,a=t.name.value,s=Wr(t),c=a!==s,l=r[s]||r[a],u=Promise.resolve(l),(!i.onlyRunForcedResolvers||this.shouldForceResolvers(t))&&(d=r.__typename||i.defaultOperationType,f=this.resolvers&&this.resolvers[d],f&&(h=f[c?a:s],h&&(u=Promise.resolve(Wh.withValue(this.cache,h,[r,Lc(t,o),i.context,{field:t,fragmentMap:i.fragmentMap}]))))),[2,u.then(function(v){var b,y;if(v===void 0&&(v=l),t.directives&&t.directives.forEach(function(_){_.name.value==="export"&&_.arguments&&_.arguments.forEach(function(k){k.name.value==="as"&&k.value.kind==="StringValue"&&(i.exportedVariables[k.value.value]=v)})}),!t.selectionSet||v==null)return v;var g=(y=(b=t.directives)===null||b===void 0?void 0:b.some(function(_){return _.name.value==="client"}))!==null&&y!==void 0?y:!1;if(Array.isArray(v))return p.resolveSubSelectedArray(t,n||g,v,i);if(t.selectionSet)return p.resolveSelectionSet(t.selectionSet,n||g,v,i)})]):[2,null]})})},e.prototype.resolveSubSelectedArray=function(t,n,r,i){var o=this;return Promise.all(r.map(function(a){if(a===null)return null;if(Array.isArray(a))return o.resolveSubSelectedArray(t,n,a,i);if(t.selectionSet)return o.resolveSelectionSet(t.selectionSet,n,a,i)}))},e.prototype.collectSelectionsToResolve=function(t,n){var r=function(a){return!Array.isArray(a)},i=this.selectionsToResolveCache;function o(a){if(!i.has(a)){var s=new Set;i.set(a,s),Wn(a,{Directive:function(c,l,u,d,f){c.name.value==="client"&&f.forEach(function(h){r(h)&&Zp(h)&&s.add(h)})},FragmentSpread:function(c,l,u,d,f){var h=n[c.name.value];__DEV__?K(h,"No fragment named ".concat(c.name.value)):K(h,12);var p=o(h);p.size>0&&(f.forEach(function(m){r(m)&&Zp(m)&&s.add(m)}),s.add(c),p.forEach(function(m){s.add(m)}))}})}return i.get(a)}return o(t)},e}(),_i=new(ti?WeakMap:Map);function Ru(e,t){var n=e[t];typeof n=="function"&&(e[t]=function(){return _i.set(e,(_i.get(e)+1)%1e15),n.apply(this,arguments)})}function R2(e){e.notifyTimeout&&(clearTimeout(e.notifyTimeout),e.notifyTimeout=void 0)}var Fu=function(){function e(t,n){n===void 0&&(n=t.generateQueryId()),this.queryId=n,this.listeners=new Set,this.document=null,this.lastRequestId=1,this.subscriptions=new Set,this.stopped=!1,this.dirty=!1,this.observableQuery=null;var r=this.cache=t.cache;_i.has(r)||(_i.set(r,0),Ru(r,"evict"),Ru(r,"modify"),Ru(r,"reset"))}return e.prototype.init=function(t){var n=t.networkStatus||De.loading;return this.variables&&this.networkStatus!==De.loading&&!ut(this.variables,t.variables)&&(n=De.setVariables),ut(t.variables,this.variables)||(this.lastDiff=void 0),Object.assign(this,{document:t.document,variables:t.variables,networkError:null,graphQLErrors:this.graphQLErrors||[],networkStatus:n}),t.observableQuery&&this.setObservableQuery(t.observableQuery),t.lastRequestId&&(this.lastRequestId=t.lastRequestId),this},e.prototype.reset=function(){R2(this),this.dirty=!1},e.prototype.getDiff=function(t){t===void 0&&(t=this.variables);var n=this.getDiffOptions(t);if(this.lastDiff&&ut(n,this.lastDiff.options))return this.lastDiff.diff;this.updateWatch(this.variables=t);var r=this.observableQuery;if(r&&r.options.fetchPolicy==="no-cache")return{complete:!1};var i=this.cache.diff(n);return this.updateLastDiff(i,n),i},e.prototype.updateLastDiff=function(t,n){this.lastDiff=t?{diff:t,options:n||this.getDiffOptions()}:void 0},e.prototype.getDiffOptions=function(t){var n;return t===void 0&&(t=this.variables),{query:this.document,variables:t,returnPartialData:!0,optimistic:!0,canonizeResults:(n=this.observableQuery)===null||n===void 0?void 0:n.options.canonizeResults}},e.prototype.setDiff=function(t){var n=this,r=this.lastDiff&&this.lastDiff.diff;this.updateLastDiff(t),!this.dirty&&!ut(r&&r.result,t&&t.result)&&(this.dirty=!0,this.notifyTimeout||(this.notifyTimeout=setTimeout(function(){return n.notify()},0)))},e.prototype.setObservableQuery=function(t){var n=this;t!==this.observableQuery&&(this.oqListener&&this.listeners.delete(this.oqListener),this.observableQuery=t,t?(t.queryInfo=this,this.listeners.add(this.oqListener=function(){var r=n.getDiff();r.fromOptimisticTransaction?t.observe():u3(t)})):delete this.oqListener)},e.prototype.notify=function(){var t=this;R2(this),this.shouldNotify()&&this.listeners.forEach(function(n){return n(t)}),this.dirty=!1},e.prototype.shouldNotify=function(){if(!this.dirty||!this.listeners.size)return!1;if(na(this.networkStatus)&&this.observableQuery){var t=this.observableQuery.options.fetchPolicy;if(t!=="cache-only"&&t!=="cache-and-network")return!1}return!0},e.prototype.stop=function(){if(!this.stopped){this.stopped=!0,this.reset(),this.cancel(),this.cancel=e.prototype.cancel,this.subscriptions.forEach(function(n){return n.unsubscribe()});var t=this.observableQuery;t&&t.stopPolling()}},e.prototype.cancel=function(){},e.prototype.updateWatch=function(t){var n=this;t===void 0&&(t=this.variables);var r=this.observableQuery;if(!(r&&r.options.fetchPolicy==="no-cache")){var i=T(T({},this.getDiffOptions(t)),{watcher:this,callback:function(o){return n.setDiff(o)}});(!this.lastWatch||!ut(i,this.lastWatch))&&(this.cancel(),this.cancel=this.cache.watch(this.lastWatch=i))}},e.prototype.resetLastWrite=function(){this.lastWrite=void 0},e.prototype.shouldWrite=function(t,n){var r=this.lastWrite;return!(r&&r.dmCount===_i.get(this.cache)&&ut(n,r.variables)&&ut(t.data,r.result.data))},e.prototype.markResult=function(t,n,r,i){var o=this,a=new vr,s=rn(t.errors)?t.errors.slice(0):[];if(this.reset(),"incremental"in t&&rn(t.incremental)){var c=Ry(this.getDiff().result,t);t.data=c}else if("hasNext"in t&&t.hasNext){var l=this.getDiff();t.data=a.merge(l.result,t.data)}this.graphQLErrors=s,r.fetchPolicy==="no-cache"?this.updateLastDiff({result:t.data,complete:!0},this.getDiffOptions(r.variables)):i!==0&&(v0(t,r.errorPolicy)?this.cache.performTransaction(function(u){if(o.shouldWrite(t,r.variables))u.writeQuery({query:n,data:t.data,variables:r.variables,overwrite:i===1}),o.lastWrite={result:t,variables:r.variables,dmCount:_i.get(o.cache)};else if(o.lastDiff&&o.lastDiff.diff.complete){t.data=o.lastDiff.diff.result;return}var d=o.getDiffOptions(r.variables),f=u.diff(d);o.stopped||o.updateWatch(r.variables),o.updateLastDiff(f,d),f.complete&&(t.data=f.result)}):this.lastWrite=void 0)},e.prototype.markReady=function(){return this.networkError=null,this.networkStatus=De.ready},e.prototype.markError=function(t){return this.networkStatus=De.error,this.lastWrite=void 0,this.reset(),t.graphQLErrors&&(this.graphQLErrors=t.graphQLErrors),t.networkError&&(this.networkError=t.networkError),t},e}();function v0(e,t){t===void 0&&(t="none");var n=t==="ignore"||t==="all",r=!fs(e);return!r&&n&&e.data&&(r=!0),r}var l_=Object.prototype.hasOwnProperty,c_=function(){function e(t){var n=t.cache,r=t.link,i=t.defaultOptions,o=t.queryDeduplication,a=o===void 0?!1:o,s=t.onBroadcast,c=t.ssrMode,l=c===void 0?!1:c,u=t.clientAwareness,d=u===void 0?{}:u,f=t.localState,h=t.assumeImmutableResults;this.clientAwareness={},this.queries=new Map,this.fetchCancelFns=new Map,this.transformCache=new(ti?WeakMap:Map),this.queryIdCounter=1,this.requestIdCounter=1,this.mutationIdCounter=1,this.inFlightLinkObservables=new Map,this.cache=n,this.link=r,this.defaultOptions=i||Object.create(null),this.queryDeduplication=a,this.clientAwareness=d,this.localState=f||new f3({cache:n}),this.ssrMode=l,this.assumeImmutableResults=!!h,(this.onBroadcast=s)&&(this.mutationStore=Object.create(null))}return e.prototype.stop=function(){var t=this;this.queries.forEach(function(n,r){t.stopQueryNoBroadcast(r)}),this.cancelPendingFetches(__DEV__?new Se("QueryManager stopped while query was in flight"):new Se(14))},e.prototype.cancelPendingFetches=function(t){this.fetchCancelFns.forEach(function(n){return n(t)}),this.fetchCancelFns.clear()},e.prototype.mutate=function(t){var n,r,i=t.mutation,o=t.variables,a=t.optimisticResponse,s=t.updateQueries,c=t.refetchQueries,l=c===void 0?[]:c,u=t.awaitRefetchQueries,d=u===void 0?!1:u,f=t.update,h=t.onQueryUpdated,p=t.fetchPolicy,m=p===void 0?((n=this.defaultOptions.mutate)===null||n===void 0?void 0:n.fetchPolicy)||"network-only":p,v=t.errorPolicy,b=v===void 0?((r=this.defaultOptions.mutate)===null||r===void 0?void 0:r.errorPolicy)||"none":v,y=t.keepRootFields,g=t.context;return fe(this,void 0,void 0,function(){var _,k,O,C,M,D;return nr(this,function(F){switch(F.label){case 0:return __DEV__?K(i,"mutation option is required. You must specify your GraphQL document in the mutation option."):K(i,15),__DEV__?K(m==="network-only"||m==="no-cache","Mutations support only 'network-only' or 'no-cache' fetchPolicy strings. The default `network-only` behavior automatically writes mutation results to the cache. Passing `no-cache` skips the cache write."):K(m==="network-only"||m==="no-cache",16),_=this.generateMutationId(),k=this.transform(i),O=k.document,C=k.hasClientExports,i=this.cache.transformForLink(O),o=this.getVariables(i,o),C?[4,this.localState.addExportedVariables(i,o,g)]:[3,2];case 1:o=F.sent(),F.label=2;case 2:return M=this.mutationStore&&(this.mutationStore[_]={mutation:i,variables:o,loading:!0,error:null}),a&&this.markMutationOptimistic(a,{mutationId:_,document:i,variables:o,fetchPolicy:m,errorPolicy:b,context:g,updateQueries:s,update:f,keepRootFields:y}),this.broadcastQueries(),D=this,[2,new Promise(function(Y,J){return Nu(D.getObservableFromLink(i,T(T({},g),{optimisticResponse:a}),o,!1),function(G){if(fs(G)&&b==="none")throw new si({graphQLErrors:n0(G)});M&&(M.loading=!1,M.error=null);var j=T({},G);return typeof l=="function"&&(l=l(j)),b==="ignore"&&fs(j)&&delete j.errors,D.markMutationResult({mutationId:_,result:j,document:i,variables:o,fetchPolicy:m,errorPolicy:b,context:g,update:f,updateQueries:s,awaitRefetchQueries:d,refetchQueries:l,removeOptimistic:a?_:void 0,onQueryUpdated:h,keepRootFields:y})}).subscribe({next:function(G){D.broadcastQueries(),(!("hasNext"in G)||G.hasNext===!1)&&Y(G)},error:function(G){M&&(M.loading=!1,M.error=G),a&&D.cache.removeOptimistic(_),D.broadcastQueries(),J(G instanceof si?G:new si({networkError:G}))}})})]}})})},e.prototype.markMutationResult=function(t,n){var r=this;n===void 0&&(n=this.cache);var i=t.result,o=[],a=t.fetchPolicy==="no-cache";if(!a&&v0(i,t.errorPolicy)){if(Oi(i)||o.push({result:i.data,dataId:"ROOT_MUTATION",query:t.document,variables:t.variables}),Oi(i)&&rn(i.incremental)){var s=n.diff({id:"ROOT_MUTATION",query:this.transform(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0}),c=void 0;s.result&&(c=Ry(s.result,i)),typeof c<"u"&&(i.data=c,o.push({result:c,dataId:"ROOT_MUTATION",query:t.document,variables:t.variables}))}var l=t.updateQueries;l&&this.queries.forEach(function(d,f){var h=d.observableQuery,p=h&&h.queryName;if(!(!p||!l_.call(l,p))){var m=l[p],v=r.queries.get(f),b=v.document,y=v.variables,g=n.diff({query:b,variables:y,returnPartialData:!0,optimistic:!1}),_=g.result,k=g.complete;if(k&&_){var O=m(_,{mutationResult:i,queryName:b&&Xd(b)||void 0,queryVariables:y});O&&o.push({result:O,dataId:"ROOT_QUERY",query:b,variables:y})}}})}if(o.length>0||t.refetchQueries||t.update||t.onQueryUpdated||t.removeOptimistic){var u=[];if(this.refetchQueries({updateCache:function(d){a||o.forEach(function(m){return d.write(m)});var f=t.update,h=!R9(i)||Oi(i)&&!i.hasNext;if(f){if(!a){var p=d.diff({id:"ROOT_MUTATION",query:r.transform(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0});p.complete&&(i=T(T({},i),{data:p.result}),"incremental"in i&&delete i.incremental,"hasNext"in i&&delete i.hasNext)}h&&f(d,i,{context:t.context,variables:t.variables})}!a&&!t.keepRootFields&&h&&d.modify({id:"ROOT_MUTATION",fields:function(m,v){var b=v.fieldName,y=v.DELETE;return b==="__typename"?m:y}})},include:t.refetchQueries,optimistic:!1,removeOptimistic:t.removeOptimistic,onQueryUpdated:t.onQueryUpdated||null}).forEach(function(d){return u.push(d)}),t.awaitRefetchQueries||t.onQueryUpdated)return Promise.all(u).then(function(){return i})}return Promise.resolve(i)},e.prototype.markMutationOptimistic=function(t,n){var r=this,i=typeof t=="function"?t(n.variables):t;return this.cache.recordOptimisticTransaction(function(o){try{r.markMutationResult(T(T({},n),{result:{data:i}}),o)}catch(a){__DEV__&&K.error(a)}},n.mutationId)},e.prototype.fetchQuery=function(t,n,r){return this.fetchQueryObservable(t,n,r).promise},e.prototype.getQueryStore=function(){var t=Object.create(null);return this.queries.forEach(function(n,r){t[r]={variables:n.variables,networkStatus:n.networkStatus,networkError:n.networkError,graphQLErrors:n.graphQLErrors}}),t},e.prototype.resetErrors=function(t){var n=this.queries.get(t);n&&(n.networkError=void 0,n.graphQLErrors=[])},e.prototype.transform=function(t){var n=this.transformCache;if(!n.has(t)){var r=this.cache.transformDocument(t),i=b9(r),o=this.localState.clientQuery(r),a=i&&this.localState.serverQuery(i),s={document:r,hasClientExports:X$(r),hasForcedResolvers:this.localState.shouldForceResolvers(r),clientQuery:o,serverQuery:a,defaultVars:Lh($a(r)),asQuery:T(T({},r),{definitions:r.definitions.map(function(l){return l.kind==="OperationDefinition"&&l.operation!=="query"?T(T({},l),{operation:"query"}):l})})},c=function(l){l&&!n.has(l)&&n.set(l,s)};c(t),c(r),c(o),c(a)}return n.get(t)},e.prototype.getVariables=function(t,n){return T(T({},this.transform(t).defaultVars),n)},e.prototype.watchQuery=function(t){t=T(T({},t),{variables:this.getVariables(t.query,t.variables)}),typeof t.notifyOnNetworkStatusChange>"u"&&(t.notifyOnNetworkStatusChange=!1);var n=new Fu(this),r=new m0({queryManager:this,queryInfo:n,options:t});return this.queries.set(r.queryId,n),n.init({document:r.query,observableQuery:r,variables:r.variables}),r},e.prototype.query=function(t,n){var r=this;return n===void 0&&(n=this.generateQueryId()),__DEV__?K(t.query,"query option is required. You must specify your GraphQL document in the query option."):K(t.query,17),__DEV__?K(t.query.kind==="Document",'You must wrap the query string in a "gql" tag.'):K(t.query.kind==="Document",18),__DEV__?K(!t.returnPartialData,"returnPartialData option only supported on watchQuery."):K(!t.returnPartialData,19),__DEV__?K(!t.pollInterval,"pollInterval option only supported on watchQuery."):K(!t.pollInterval,20),this.fetchQuery(n,t).finally(function(){return r.stopQuery(n)})},e.prototype.generateQueryId=function(){return String(this.queryIdCounter++)},e.prototype.generateRequestId=function(){return this.requestIdCounter++},e.prototype.generateMutationId=function(){return String(this.mutationIdCounter++)},e.prototype.stopQueryInStore=function(t){this.stopQueryInStoreNoBroadcast(t),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(t){var n=this.queries.get(t);n&&n.stop()},e.prototype.clearStore=function(t){return t===void 0&&(t={discardWatches:!0}),this.cancelPendingFetches(__DEV__?new Se("Store reset while query was in flight (not completed in link chain)"):new Se(21)),this.queries.forEach(function(n){n.observableQuery?n.networkStatus=De.loading:n.stop()}),this.mutationStore&&(this.mutationStore=Object.create(null)),this.cache.reset(t)},e.prototype.getObservableQueries=function(t){var n=this;t===void 0&&(t="active");var r=new Map,i=new Map,o=new Set;return Array.isArray(t)&&t.forEach(function(a){typeof a=="string"?i.set(a,!1):t9(a)?i.set(n.transform(a).document,!1):Ye(a)&&a.query&&o.add(a)}),this.queries.forEach(function(a,s){var c=a.observableQuery,l=a.document;if(c){if(t==="all"){r.set(s,c);return}var u=c.queryName,d=c.options.fetchPolicy;if(d==="standby"||t==="active"&&!c.hasObservers())return;(t==="active"||u&&i.has(u)||l&&i.has(l))&&(r.set(s,c),u&&i.set(u,!0),l&&i.set(l,!0))}}),o.size&&o.forEach(function(a){var s=r0("legacyOneTimeQuery"),c=n.getQuery(s).init({document:a.query,variables:a.variables}),l=new m0({queryManager:n,queryInfo:c,options:T(T({},a),{fetchPolicy:"network-only"})});K(l.queryId===s),c.setObservableQuery(l),r.set(s,l)}),__DEV__&&i.size&&i.forEach(function(a,s){a||__DEV__&&K.warn("Unknown query ".concat(typeof s=="string"?"named ":"").concat(JSON.stringify(s,null,2)," requested in refetchQueries options.include array"))}),r},e.prototype.reFetchObservableQueries=function(t){var n=this;t===void 0&&(t=!1);var r=[];return this.getObservableQueries(t?"all":"active").forEach(function(i,o){var a=i.options.fetchPolicy;i.resetLastResults(),(t||a!=="standby"&&a!=="cache-only")&&r.push(i.refetch()),n.getQuery(o).setDiff(null)}),this.broadcastQueries(),Promise.all(r)},e.prototype.setObservableQuery=function(t){this.getQuery(t.queryId).setObservableQuery(t)},e.prototype.startGraphQLSubscription=function(t){var n=this,r=t.query,i=t.fetchPolicy,o=t.errorPolicy,a=t.variables,s=t.context,c=s===void 0?{}:s;r=this.transform(r).document,a=this.getVariables(r,a);var l=function(d){return n.getObservableFromLink(r,c,d).map(function(f){if(i!=="no-cache"&&(v0(f,o)&&n.cache.write({query:r,result:f.data,dataId:"ROOT_SUBSCRIPTION",variables:d}),n.broadcastQueries()),fs(f))throw new si({graphQLErrors:f.errors});return f})};if(this.transform(r).hasClientExports){var u=this.localState.addExportedVariables(r,a,c).then(l);return new Le(function(d){var f=null;return u.then(function(h){return f=h.subscribe(d)},d.error),function(){return f&&f.unsubscribe()}})}return l(a)},e.prototype.stopQuery=function(t){this.stopQueryNoBroadcast(t),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(t){this.stopQueryInStoreNoBroadcast(t),this.removeQuery(t)},e.prototype.removeQuery=function(t){this.fetchCancelFns.delete(t),this.queries.has(t)&&(this.getQuery(t).stop(),this.queries.delete(t))},e.prototype.broadcastQueries=function(){this.onBroadcast&&this.onBroadcast(),this.queries.forEach(function(t){return t.notify()})},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(t,n,r,i){var o=this,a;i===void 0&&(i=(a=n?.queryDeduplication)!==null&&a!==void 0?a:this.queryDeduplication);var s,c=this.transform(t).serverQuery;if(c){var l=this,u=l.inFlightLinkObservables,d=l.link,f={query:c,variables:r,operationName:Xd(c)||void 0,context:this.prepareContext(T(T({},n),{forceFetch:!i}))};if(n=f.context,i){var h=u.get(c)||new Map;u.set(c,h);var p=jr(r);if(s=h.get(p),!s){var m=new Lo([o0(d,f)]);h.set(p,s=m),m.beforeNext(function(){h.delete(p)&&h.size<1&&u.delete(c)})}}else s=new Lo([o0(d,f)])}else s=new Lo([Le.of({data:{}})]),n=this.prepareContext(n);var v=this.transform(t).clientQuery;return v&&(s=Nu(s,function(b){return o.localState.runResolvers({document:v,remoteResult:b,context:n,variables:r})})),s},e.prototype.getResultsFromLink=function(t,n,r){var i=t.lastRequestId=this.generateRequestId(),o=this.cache.transformForLink(this.transform(t.document).document);return Nu(this.getObservableFromLink(o,r.context,r.variables),function(a){var s=n0(a),c=s.length>0;if(i>=t.lastRequestId){if(c&&r.errorPolicy==="none")throw t.markError(new si({graphQLErrors:s}));t.markResult(a,o,r,n),t.markReady()}var l={data:a.data,loading:!1,networkStatus:De.ready};return c&&r.errorPolicy!=="ignore"&&(l.errors=s,l.networkStatus=De.error),l},function(a){var s=r_(a)?a:new si({networkError:a});throw i>=t.lastRequestId&&t.markError(s),s})},e.prototype.fetchQueryObservable=function(t,n,r){var i=this;r===void 0&&(r=De.loading);var o=this.transform(n.query).document,a=this.getVariables(o,n.variables),s=this.getQuery(t),c=this.defaultOptions.watchQuery,l=n.fetchPolicy,u=l===void 0?c&&c.fetchPolicy||"cache-first":l,d=n.errorPolicy,f=d===void 0?c&&c.errorPolicy||"none":d,h=n.returnPartialData,p=h===void 0?!1:h,m=n.notifyOnNetworkStatusChange,v=m===void 0?!1:m,b=n.context,y=b===void 0?{}:b,g=Object.assign({},n,{query:o,variables:a,fetchPolicy:u,errorPolicy:f,returnPartialData:p,notifyOnNetworkStatusChange:v,context:y}),_=function(C){g.variables=C;var M=i.fetchQueryByPolicy(s,g,r);return g.fetchPolicy!=="standby"&&M.length>0&&s.observableQuery&&s.observableQuery.applyNextFetchPolicy("after-fetch",n),M},k=function(){return i.fetchCancelFns.delete(t)};this.fetchCancelFns.set(t,function(C){k(),setTimeout(function(){return O.cancel(C)})});var O=new Lo(this.transform(g.query).hasClientExports?this.localState.addExportedVariables(g.query,g.variables,g.context).then(_):_(g.variables));return O.promise.then(k,k),O},e.prototype.refetchQueries=function(t){var n=this,r=t.updateCache,i=t.include,o=t.optimistic,a=o===void 0?!1:o,s=t.removeOptimistic,c=s===void 0?a?r0("refetchQueries"):void 0:s,l=t.onQueryUpdated,u=new Map;i&&this.getObservableQueries(i).forEach(function(f,h){u.set(h,{oq:f,lastDiff:n.getQuery(h).getDiff()})});var d=new Map;return r&&this.cache.batch({update:r,optimistic:a&&c||!1,removeOptimistic:c,onWatchUpdated:function(f,h,p){var m=f.watcher instanceof Fu&&f.watcher.observableQuery;if(m){if(l){u.delete(m.queryId);var v=l(m,h,p);return v===!0&&(v=m.refetch()),v!==!1&&d.set(m,v),v}l!==null&&u.set(m.queryId,{oq:m,lastDiff:p,diff:h})}}}),u.size&&u.forEach(function(f,h){var p=f.oq,m=f.lastDiff,v=f.diff,b;if(l){if(!v){var y=p.queryInfo;y.reset(),v=y.getDiff()}b=l(p,v,m)}(!l||b===!0)&&(b=p.refetch()),b!==!1&&d.set(p,b),h.indexOf("legacyOneTimeQuery")>=0&&n.stopQueryNoBroadcast(h)}),c&&this.cache.removeOptimistic(c),d},e.prototype.fetchQueryByPolicy=function(t,n,r){var i=this,o=n.query,a=n.variables,s=n.fetchPolicy,c=n.refetchWritePolicy,l=n.errorPolicy,u=n.returnPartialData,d=n.context,f=n.notifyOnNetworkStatusChange,h=t.networkStatus;t.init({document:this.transform(o).document,variables:a,networkStatus:r});var p=function(){return t.getDiff(a)},m=function(_,k){k===void 0&&(k=t.networkStatus||De.loading);var O=_.result;__DEV__&&!u&&!ut(O,{})&&d3(_.missing);var C=function(M){return Le.of(T({data:M,loading:na(k),networkStatus:k},_.complete?null:{partial:!0}))};return O&&i.transform(o).hasForcedResolvers?i.localState.runResolvers({document:o,remoteResult:{data:O},context:d,variables:a,onlyRunForcedResolvers:!0}).then(function(M){return C(M.data||void 0)}):l==="none"&&k===De.refetch&&Array.isArray(_.missing)?C(void 0):C(O)},v=s==="no-cache"?0:r===De.refetch&&c!=="merge"?1:2,b=function(){return i.getResultsFromLink(t,v,{variables:a,context:d,fetchPolicy:s,errorPolicy:l})},y=f&&typeof h=="number"&&h!==r&&na(r);switch(s){default:case"cache-first":{var g=p();return g.complete?[m(g,t.markReady())]:u||y?[m(g),b()]:[b()]}case"cache-and-network":{var g=p();return g.complete||u||y?[m(g),b()]:[b()]}case"cache-only":return[m(p(),t.markReady())];case"network-only":return y?[m(p()),b()]:[b()];case"no-cache":return y?[m(t.getDiff()),b()]:[b()];case"standby":return[]}},e.prototype.getQuery=function(t){return t&&!this.queries.has(t)&&this.queries.set(t,new Fu(this,t)),this.queries.get(t)},e.prototype.prepareContext=function(t){t===void 0&&(t={});var n=this.localState.prepareContext(t);return T(T({},n),{clientAwareness:this.clientAwareness})},e}(),F2=!1,u_=function(){function e(t){var n=this;this.resetStoreCallbacks=[],this.clearStoreCallbacks=[];var r=t.uri,i=t.credentials,o=t.headers,a=t.cache,s=t.ssrMode,c=s===void 0?!1:s,l=t.ssrForceFetchDelay,u=l===void 0?0:l,d=t.connectToDevTools,f=d===void 0?typeof window=="object"&&!window.__APOLLO_CLIENT__&&__DEV__:d,h=t.queryDeduplication,p=h===void 0?!0:h,m=t.defaultOptions,v=t.assumeImmutableResults,b=v===void 0?!1:v,y=t.resolvers,g=t.typeDefs,_=t.fragmentMatcher,k=t.name,O=t.version,C=t.link;if(C||(C=r?new zy({uri:r,credentials:i,headers:o}):io.empty()),!a)throw __DEV__?new Se(`To initialize Apollo Client, you must specify a 'cache' property in the options object.
|
|
69
|
+
For more information, please visit: https://go.apollo.dev/c/docs`):new Se(9);if(this.link=C,this.cache=a,this.disableNetworkFetches=c||u>0,this.queryDeduplication=p,this.defaultOptions=m||Object.create(null),this.typeDefs=g,u&&setTimeout(function(){return n.disableNetworkFetches=!1},u),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),f&&typeof window=="object"&&(window.__APOLLO_CLIENT__=this),!F2&&f&&__DEV__&&(F2=!0,typeof window<"u"&&window.document&&window.top===window.self&&!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__)){var M=window.navigator,D=M&&M.userAgent,F=void 0;typeof D=="string"&&(D.indexOf("Chrome/")>-1?F="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":D.indexOf("Firefox/")>-1&&(F="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),F&&__DEV__&&K.log("Download the Apollo DevTools for a better development experience: "+F)}this.version=B9,this.localState=new f3({cache:a,client:this,resolvers:y,fragmentMatcher:_}),this.queryManager=new c_({cache:this.cache,link:this.link,defaultOptions:this.defaultOptions,queryDeduplication:p,ssrMode:c,clientAwareness:{name:k,version:O},localState:this.localState,assumeImmutableResults:b,onBroadcast:f?function(){n.devToolsHookCb&&n.devToolsHookCb({action:{},state:{queries:n.queryManager.getQueryStore(),mutations:n.queryManager.mutationStore||{}},dataWithOptimisticResults:n.cache.extract(!0)})}:void 0})}return e.prototype.stop=function(){this.queryManager.stop()},e.prototype.watchQuery=function(t){return this.defaultOptions.watchQuery&&(t=Tu(this.defaultOptions.watchQuery,t)),this.disableNetworkFetches&&(t.fetchPolicy==="network-only"||t.fetchPolicy==="cache-and-network")&&(t=T(T({},t),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(t)},e.prototype.query=function(t){return this.defaultOptions.query&&(t=Tu(this.defaultOptions.query,t)),__DEV__?K(t.fetchPolicy!=="cache-and-network","The cache-and-network fetchPolicy does not work with client.query, because client.query can only return a single result. Please use client.watchQuery to receive multiple results from the cache and the network, or consider using a different fetchPolicy, such as cache-first or network-only."):K(t.fetchPolicy!=="cache-and-network",10),this.disableNetworkFetches&&t.fetchPolicy==="network-only"&&(t=T(T({},t),{fetchPolicy:"cache-first"})),this.queryManager.query(t)},e.prototype.mutate=function(t){return this.defaultOptions.mutate&&(t=Tu(this.defaultOptions.mutate,t)),this.queryManager.mutate(t)},e.prototype.subscribe=function(t){return this.queryManager.startGraphQLSubscription(t)},e.prototype.readQuery=function(t,n){return n===void 0&&(n=!1),this.cache.readQuery(t,n)},e.prototype.readFragment=function(t,n){return n===void 0&&(n=!1),this.cache.readFragment(t,n)},e.prototype.writeQuery=function(t){var n=this.cache.writeQuery(t);return t.broadcast!==!1&&this.queryManager.broadcastQueries(),n},e.prototype.writeFragment=function(t){var n=this.cache.writeFragment(t);return t.broadcast!==!1&&this.queryManager.broadcastQueries(),n},e.prototype.__actionHookForDevTools=function(t){this.devToolsHookCb=t},e.prototype.__requestRaw=function(t){return o0(this.link,t)},e.prototype.resetStore=function(){var t=this;return Promise.resolve().then(function(){return t.queryManager.clearStore({discardWatches:!1})}).then(function(){return Promise.all(t.resetStoreCallbacks.map(function(n){return n()}))}).then(function(){return t.reFetchObservableQueries()})},e.prototype.clearStore=function(){var t=this;return Promise.resolve().then(function(){return t.queryManager.clearStore({discardWatches:!0})}).then(function(){return Promise.all(t.clearStoreCallbacks.map(function(n){return n()}))})},e.prototype.onResetStore=function(t){var n=this;return this.resetStoreCallbacks.push(t),function(){n.resetStoreCallbacks=n.resetStoreCallbacks.filter(function(r){return r!==t})}},e.prototype.onClearStore=function(t){var n=this;return this.clearStoreCallbacks.push(t),function(){n.clearStoreCallbacks=n.clearStoreCallbacks.filter(function(r){return r!==t})}},e.prototype.reFetchObservableQueries=function(t){return this.queryManager.reFetchObservableQueries(t)},e.prototype.refetchQueries=function(t){var n=this.queryManager.refetchQueries(t),r=[],i=[];n.forEach(function(a,s){r.push(s),i.push(a)});var o=Promise.all(i);return o.queries=r,o.results=i,o.catch(function(a){__DEV__&&K.debug("In client.refetchQueries, Promise.all promise rejected with error ".concat(a))}),o},e.prototype.getObservableQueries=function(t){return t===void 0&&(t="active"),this.queryManager.getObservableQueries(t)},e.prototype.extract=function(t){return this.cache.extract(t)},e.prototype.restore=function(t){return this.cache.restore(t)},e.prototype.addResolvers=function(t){this.localState.addResolvers(t)},e.prototype.setResolvers=function(t){this.localState.setResolvers(t)},e.prototype.getResolvers=function(){return this.localState.getResolvers()},e.prototype.setLocalStateFragmentMatcher=function(t){this.localState.setFragmentMatcher(t)},e.prototype.setLink=function(t){this.link=this.queryManager.link=t},e}(),ps=new Map,g0=new Map,h3=!0,El=!1;function p3(e){return e.replace(/[\s,]+/g," ").trim()}function d_(e){return p3(e.source.body.substring(e.start,e.end))}function f_(e){var t=new Set,n=[];return e.definitions.forEach(function(r){if(r.kind==="FragmentDefinition"){var i=r.name.value,o=d_(r.loc),a=g0.get(i);a&&!a.has(o)?h3&&console.warn("Warning: fragment with name "+i+` already exists.
|
|
70
70
|
graphql-tag enforces all fragment names across your application to be unique; read more about
|
|
71
|
-
this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a||g0.set(i,a=new Set),a.add(o),t.has(o)||(t.add(o),n.push(r))}else n.push(r)}),
|
|
71
|
+
this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a||g0.set(i,a=new Set),a.add(o),t.has(o)||(t.add(o),n.push(r))}else n.push(r)}),T(T({},e),{definitions:n})}function h_(e){var t=new Set(e.definitions);t.forEach(function(r){r.loc&&delete r.loc,Object.keys(r).forEach(function(i){var o=r[i];o&&typeof o=="object"&&t.add(o)})});var n=e.loc;return n&&(delete n.startToken,delete n.endToken),e}function p_(e){var t=p3(e);if(!ps.has(t)){var n=z$(e,{experimentalFragmentVariables:El,allowLegacyFragmentVariables:El});if(!n||n.kind!=="Document")throw new Error("Not a valid GraphQL document.");ps.set(t,h_(f_(n)))}return ps.get(t)}function ne(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];typeof e=="string"&&(e=[e]);var r=e[0];return t.forEach(function(i,o){i&&i.kind==="Document"?r+=i.loc.source.body:r+=i,r+=e[o+1]}),p_(r)}function m_(){ps.clear(),g0.clear()}function v_(){h3=!1}function g_(){El=!0}function y_(){El=!1}var xo={gql:ne,resetCaches:m_,disableFragmentWarnings:v_,enableExperimentalFragmentVariables:g_,disableExperimentalFragmentVariables:y_};(function(e){e.gql=xo.gql,e.resetCaches=xo.resetCaches,e.disableFragmentWarnings=xo.disableFragmentWarnings,e.enableExperimentalFragmentVariables=xo.enableExperimentalFragmentVariables,e.disableExperimentalFragmentVariables=xo.disableExperimentalFragmentVariables})(ne||(ne={}));ne.default=ne;const _a=ne;function b_(e){return new io(function(t,n){var r=hr(t,[]);return new Le(function(i){var o,a=!1;return Promise.resolve(r).then(function(s){return e(s,t.getContext())}).then(t.setContext).then(function(){a||(o=n(t).subscribe({next:i.next.bind(i),error:i.error.bind(i),complete:i.complete.bind(i)}))}).catch(i.error.bind(i)),function(){a=!0,o&&o.unsubscribe()}})})}const $_=/[?&]code=[^&]+/,w_=/[?&]state=[^&]+/,__=/[?&]error=[^&]+/;class z2{constructor({authentication:t,organization:n,audience:r="https://api.photon.health"}){this.authentication=t,this.organization=n,this.audience=r}login({organizationId:t,invitation:n,appState:r}){return fe(this,void 0,void 0,function*(){let i={redirectMethod:"assign"};return(t||this.organization)&&(i=Object.assign(i,{organization:t||this.organization})),n&&(i=Object.assign(i,{invitation:n})),r&&(i=Object.assign(i,{appState:r})),this.authentication.loginWithRedirect(i)})}logout({returnTo:t,federated:n=!1}){return fe(this,void 0,void 0,function*(){const r=Object.assign(Object.assign({},t?{returnTo:t}:{}),n?{federated:n}:{});return this.authentication.logout(r)})}hasAuthParams(t=window.location.search){return($_.test(t)||__.test(t))&&w_.test(t)}getAccessToken({audience:t}={audience:this.audience}){return fe(this,void 0,void 0,function*(){const n=Object.assign({audience:t||this.audience||void 0},this.organization?{organization:this.organization}:{});let r;try{r=yield this.authentication.getTokenSilently(n)}catch(i){if(i.message.includes("Consent required"))r=yield this.authentication.getTokenWithPopup(n);else throw i}return r})}getAccessTokenWithConsent({audience:t}={audience:this.audience}){return fe(this,void 0,void 0,function*(){const n=Object.assign({audience:t||this.audience||void 0},this.organization?{organization:this.organization}:{});return this.authentication.getTokenWithPopup(n)})}checkSession(){return fe(this,void 0,void 0,function*(){return this.authentication.checkSession()})}handleRedirect(t){return fe(this,void 0,void 0,function*(){try{return this.authentication.handleRedirectCallback(t)}catch(n){console.error(n)}})}getUser(){return fe(this,void 0,void 0,function*(){return this.authentication.getUser()})}isAuthenticated(){return fe(this,void 0,void 0,function*(){try{return yield this.authentication.checkSession(),yield this.authentication.isAuthenticated()}catch{return!1}})}}const ja=ne`
|
|
72
72
|
fragment OrganizationFields on Organization {
|
|
73
73
|
id
|
|
74
74
|
name
|
|
@@ -743,8 +743,8 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
743
743
|
}
|
|
744
744
|
}
|
|
745
745
|
}
|
|
746
|
-
`;class Q_{sdk;setStore;store;authentication;getSDK;clinical;constructor(t){this.sdk=t;const[n,r]=kr({authentication:{isAuthenticated:!1,isInOrg:!1,permissions:[],isLoading:!0,error:void 0,user:void 0},catalog:{isLoading:!1,treatments:[],templates:[]},catalogs:{isLoading:!1,catalogs:[]},dispenseUnits:{isLoading:!1,dispenseUnits:new Array},patients:{isLoading:!1,patients:[],finished:!1},patient:{isLoading:!1,patient:void 0},prescription:{isLoading:!1,errors:[],error:void 0,data:void 0}});this.setStore=r,this.store=n,this.authentication={state:n.authentication,handleRedirect:async i=>{try{const o=await this.sdk.authentication.handleRedirect(i);G_(o?.appState)}catch(o){const s=new URLSearchParams(window.location.search).get("error_description");o.message.includes("must be an organization id")?this.setStore("authentication",{...this.store.authentication,error:"The provided organization id is invalid or does not exist"}):s?.includes("is not part of the org")?this.setStore("authentication",{...this.store.authentication,error:"User is not authorized",isLoading:!1}):this.setStore("authentication",{...this.store.authentication,error:o.message})}},checkSession:this.checkSession.bind(this),login:this.login.bind(this),logout:this.logout.bind(this)},this.getSDK=this._getSDK.bind(this),this.clinical={catalog:{state:n.catalog,getCatalog:this.getCatalog.bind(this)},catalogs:{state:n.catalogs,getCatalogs:this.getCatalogs.bind(this)},dispenseUnits:{state:n.dispenseUnits,getDispenseUnits:this.getDispenseUnits.bind(this)},patients:{state:n.patients,getPatients:this.getPatients.bind(this)},patient:{state:n.patient,getPatient:this.getPatient.bind(this)},prescription:{state:n.prescription,createPrescription:this.createPrescription.bind(this)}}}_getSDK(){return this.sdk}async checkSession(){try{await this.sdk.authentication.checkSession();const t=await this.sdk.authentication.isAuthenticated();this.setStore("authentication",{...this.store.authentication,isAuthenticated:t});const n=await this.sdk.authentication.getUser(),r=!!this.sdk?.organization&&!!n?.org_id;let i;try{const o=await this.sdk.authentication.getAccessToken();i=b3(o)?.permissions||[]}catch{i=[]}this.setStore("authentication",{...this.store.authentication,user:n,isLoading:!1,isInOrg:t&&r&&this.sdk.organization===n.org_id,permissions:i||[]})}catch{this.setStore("authentication",{...this.store.authentication,isLoading:!1})}}async login(t={}){await this.sdk.authentication.login(t),await this.checkSession()}async logout(t={}){await this.sdk.authentication.logout(t),this.setStore("authentication",{...this.store.authentication,isAuthenticated:!1,isInOrg:!1,permissions:[],user:void 0})}async getPatients(t){t||(t={}),this.setStore("patients",{...this.store.patients,isLoading:!0});const{data:n}=await this.sdk.clinical.patient.getPatients(t);this.setStore("patients",{...this.store.patients,isLoading:!1,patients:t.clear?n.patients:this.store.patients.patients.concat(n.patients),finished:n.patients.length==0})}async getPatient(t){this.setStore("patient",{...this.store.patient,isLoading:!0});const{data:n}=await this.sdk.clinical.patient.getPatient(t);return this.setStore("patient",{...this.store.patient,isLoading:!1,patient:n.patient}),n.patient}async getCatalog(t){this.setStore("catalog",{...this.store.catalog,isLoading:!0});const{data:n}=await this.sdk.clinical.catalog.getCatalog({id:t.id,fragment:{CatalogTreatmentsFields:K_}});this.setStore("catalog",{...this.store.catalog,isLoading:!1,treatments:n.catalog.treatments.map(r=>r)||[],templates:n.catalog.templates.map(r=>r)||[]})}async getCatalogs(){this.setStore("catalogs",{...this.store.catalogs,isLoading:!0});const{data:t}=await this.sdk.clinical.catalog.getCatalogs();this.setStore("catalogs",{...this.store.catalogs,isLoading:!1,catalogs:t.catalogs})}async getDispenseUnits(){this.setStore("dispenseUnits",{...this.store.dispenseUnits,isLoading:!0});const{data:t}=await this.sdk.clinical.prescription.getDispenseUnits();this.setStore("dispenseUnits",{...this.store.dispenseUnits,isLoading:!1,dispenseUnits:t.dispenseUnits.map((n,r)=>({id:String(r),...n}))})}async createPrescription(t){this.setStore("prescription",{...this.store.prescription,isLoading:!0});const n=this.sdk.clinical.prescription.createPrescription({});try{const{data:r,errors:i}=await n({variables:t,refetchQueries:[],awaitRefetchQueries:!1});return i&&i.length>0&&this.setStore("prescription",{...this.store.prescription,errors:[...i]}),r?.createPrescription&&this.setStore("prescription",{...this.store.prescription,data:r.createPrescription}),this.setStore("prescription",{...this.store.prescription,isLoading:!1}),{data:r,errors:i}}catch(r){return this.setStore("prescription",{...this.store.prescription,error:r,isLoading:!1}),{data:null,errors:[]}}}}var Y_=(e,t,n)=>{const r=n(e,t);return Gi(()=>clearInterval(r))};const X_=T("<slot></slot>"),Z_=T("<div></div>");Me("photon-client",{domain:{attribute:"domain",value:void 0,reflect:!1,notify:!1,parse:!1},id:{attribute:"id",value:void 0,reflect:!1,notify:!1,parse:!1},redirectUri:{attribute:"redirect-uri",value:void 0,reflect:!1,notify:!1,parse:!1},redirectPath:{attribute:"redirect-path",value:void 0,reflect:!1,notify:!1,parse:!1},org:{attribute:"org",value:void 0,reflect:!1,notify:!1,parse:!1},audience:{attribute:"audience",value:void 0,reflect:!1,notify:!1,parse:!1},uri:{attribute:"uri",value:void 0,reflect:!1,notify:!1,parse:!1},developmentMode:{attribute:"dev-mode",value:!1,reflect:!0,notify:!1,parse:!0},errorMessage:{attribute:"error-message",value:"Oh snap! There was an error loading. Please contact your site's administrator",reflect:!1,notify:!1,parse:!1},autoLogin:{attribute:"auto-login",value:!1,reflect:!1,notify:!1,parse:!0}},e=>{let t;const n=new z_({domain:e.domain,audience:e.audience,uri:e.uri,clientId:e.id,redirectURI:e.redirectUri?e.redirectUri:window.location.origin,organization:e.org,developmentMode:e.developmentMode}),r=new Q_(n);e.developmentMode&&console.info("[PhotonClient]: Development mode enabled");const[i]=V(r);return me(async()=>{z4()&&i()?(await i()?.authentication.handleRedirect(),e.redirectPath&&window.location.replace(e.redirectPath)):i()&&(await i()?.authentication.checkSession(),Y_(async()=>{await i()?.authentication.checkSession()},6e4,setInterval))}),me(async()=>{if(!i()?.authentication.state.isLoading&&!i()?.authentication.state.isAuthenticated&&e.autoLogin){const o={appState:{}};e.redirectPath&&(o.appState.returnTo=e.redirectPath),await i()?.authentication.login(o)}}),(()=>{const o=Z_.cloneNode(!0),a=t;return typeof a=="function"?he(a,o):t=o,k(o,S(mg.Provider,{get value(){return i()},get children(){const s=X_.cloneNode(!0);return s._$owner=A(),s}})),o})()});const Je=`*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.fixed{position:fixed}.relative{position:relative}.left-0{left:0}.top-0{top:0}.z-10{z-index:10}.order-last{order:9999}.m-3{margin:.75rem}.my-8{margin-top:2rem;margin-bottom:2rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.mb-8{margin-bottom:2rem}.ml-1{margin-left:.25rem}.mr-1{margin-right:.25rem}.mt-2{margin-top:.5rem}.mt-6{margin-top:1.5rem}.mt-8{margin-top:2rem}.block{display:block}.inline{display:inline}.flex{display:flex}.hidden{display:none}.h-10{height:2.5rem}.h-\\[21px\\]{height:21px}.h-\\[28px\\]{height:28px}.h-full{height:100%}.h-screen{height:100vh}.min-h-screen{min-height:100vh}.w-2\\/5{width:40%}.w-\\[16px\\]{width:16px}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-screen{width:100vw}.min-w-\\[40\\%\\]{min-width:40%}.min-w-\\[48\\%\\]{min-width:48%}.max-w-sm{max-width:24rem}.flex-1{flex:1 1 0%}.flex-shrink{flex-shrink:1}.flex-grow{flex-grow:1}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-8{gap:2rem}.self-start{align-self:flex-start}.self-end{align-self:flex-end}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-scroll{overflow-y:scroll}.overflow-ellipsis{text-overflow:ellipsis}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.rounded{border-radius:.25rem}.rounded-lg{border-radius:.5rem}.border{border-width:1px}.border-2{border-width:2px}.border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.border-red-400{--tw-border-opacity: 1;border-color:rgb(248 113 113/var(--tw-border-opacity))}.border-red-500{--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity))}.bg-\\[\\#f7f4f4\\]{--tw-bg-opacity: 1;background-color:rgb(247 244 244/var(--tw-bg-opacity))}.bg-gray-800{--tw-bg-opacity: 1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.bg-photon-blue{--tw-bg-opacity: 1;background-color:rgb(49 130 206/var(--tw-bg-opacity))}.bg-red-100{--tw-bg-opacity: 1;background-color:rgb(254 226 226/var(--tw-bg-opacity))}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.p-2{padding:.5rem}.p-4{padding:1rem}.px-4{padding-left:1rem;padding-right:1rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-4{padding-top:1rem;padding-bottom:1rem}.pb-2{padding-bottom:.5rem}.pb-24{padding-bottom:6rem}.pb-4{padding-bottom:1rem}.pb-5{padding-bottom:1.25rem}.pl-1{padding-left:.25rem}.pl-2{padding-left:.5rem}.pl-\\[19\\.75px\\]{padding-left:19.75px}.pt-1{padding-top:.25rem}.pt-1\\.5{padding-top:.375rem}.pt-2{padding-top:.5rem}.pt-28{padding-top:7rem}.pt-\\[3px\\]{padding-top:3px}.text-left{text-align:left}.text-center{text-align:center}.font-sans{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji"}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-7xl{font-size:4.5rem;line-height:1}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-light{font-weight:300}.font-medium{font-weight:500}.font-normal{font-weight:400}.italic{font-style:italic}.leading-snug{line-height:1.375}.text-black{--tw-text-opacity: 1;color:rgb(0 0 0/var(--tw-text-opacity))}.text-gray-300{--tw-text-opacity: 1;color:rgb(209 213 219/var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175/var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128/var(--tw-text-opacity))}.text-gray-600{--tw-text-opacity: 1;color:rgb(75 85 99/var(--tw-text-opacity))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81/var(--tw-text-opacity))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94/var(--tw-text-opacity))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}.text-red-700{--tw-text-opacity: 1;color:rgb(185 28 28/var(--tw-text-opacity))}.text-teal-600{--tw-text-opacity: 1;color:rgb(13 148 136/var(--tw-text-opacity))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255/var(--tw-text-opacity))}.underline{text-decoration-line:underline}.shadow-card{--tw-shadow: 0px 0px 1px rgba(48, 49, 51, .05),0px 2px 4px rgba(48, 49, 51, .1);--tw-shadow-colored: 0px 0px 1px var(--tw-shadow-color), 0px 2px 4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-ring-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-shadow)}.outline{outline-style:solid}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.hover\\:cursor-pointer:hover{cursor:pointer}.hover\\:bg-blue-700:hover{--tw-bg-opacity: 1;background-color:rgb(29 78 216/var(--tw-bg-opacity))}.hover\\:bg-photon-blue-dark:hover{--tw-bg-opacity: 1;background-color:rgb(43 108 176/var(--tw-bg-opacity))}.hover\\:text-black:hover{--tw-text-opacity: 1;color:rgb(0 0 0/var(--tw-text-opacity))}.hover\\:text-gray-600:hover{--tw-text-opacity: 1;color:rgb(75 85 99/var(--tw-text-opacity))}.hover\\:underline:hover{text-decoration-line:underline}.disabled\\:bg-gray-500:disabled{--tw-bg-opacity: 1;background-color:rgb(107 114 128/var(--tw-bg-opacity))}@media (min-width: 475px){.xs\\:mx-auto{margin-left:auto;margin-right:auto}.xs\\:w-fit{width:-moz-fit-content;width:fit-content}.xs\\:min-w-\\[40\\%\\]{min-width:40%}.xs\\:min-w-\\[48\\%\\]{min-width:48%}.xs\\:flex-row{flex-direction:row}.xs\\:items-center{align-items:center}.xs\\:gap-4{gap:1rem}.xs\\:self-end{align-self:flex-end}.xs\\:pb-2{padding-bottom:.5rem}.xs\\:pt-28{padding-top:7rem}.xs\\:text-base{font-size:1rem;line-height:1.5rem}}@media (min-width: 640px){.sm\\:order-first{order:-9999}.sm\\:mt-0{margin-top:0}.sm\\:inline{display:inline}.sm\\:grid{display:grid}.sm\\:w-\\[600px\\]{width:600px}.sm\\:w-auto{width:auto}.sm\\:flex-none{flex:none}.sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\\:flex-row{flex-direction:row}.sm\\:flex-wrap{flex-wrap:wrap}.sm\\:items-center{align-items:center}.sm\\:gap-3{gap:.75rem}.sm\\:gap-4{gap:1rem}.sm\\:gap-x-4{-moz-column-gap:1rem;column-gap:1rem}.sm\\:py-2{padding-top:.5rem;padding-bottom:.5rem}.sm\\:text-right{text-align:right}}@media (min-width: 768px){.md\\:mb-0{margin-bottom:0}.md\\:w-2\\/5{width:40%}.md\\:w-3\\/5{width:60%}.md\\:max-w-\\[50\\%\\]{max-width:50%}.md\\:flex-row{flex-direction:row}.md\\:justify-center{justify-content:center}.md\\:px-4{padding-left:1rem;padding-right:1rem}.md\\:px-8{padding-left:2rem;padding-right:2rem}.md\\:py-2{padding-top:.5rem;padding-bottom:.5rem}.md\\:py-3{padding-top:.75rem;padding-bottom:.75rem}.md\\:pb-52{padding-bottom:13rem}.md\\:pr-2{padding-right:.5rem}.md\\:pt-4{padding-top:1rem}}@media (min-width: 1024px){.lg\\:gap-2{gap:.5rem}.lg\\:pt-20{padding-top:5rem}.lg\\:text-base{font-size:1rem;line-height:1.5rem}.lg\\:text-lg{font-size:1.125rem;line-height:1.75rem}.lg\\:text-sm{font-size:.875rem;line-height:1.25rem}}
|
|
747
|
-
`,J_=T("<style></style>"),ex=T('<button class="w-full disabled:bg-gray-500 bg-photon-blue hover:bg-blue-700 text-white h-10 px-4 rounded-lg font-sans hover:bg-photon-blue-dark transition ease-in-out delay-50"></button>');Me("photon-auth-button",{redirectPath:{attribute:"redirect-path",value:void 0,reflect:!1,notify:!1,parse:!1}},e=>{const t=pt();return me(()=>{t||console.error("[photon-auth-button] No valid PhotonClient instance was provided. Please ensure you are wrapping the element in a photon-client element")}),[(()=>{const n=J_.cloneNode(!0);return k(n,Je),n})(),t?(()=>{const n=ex.cloneNode(!0);return n.$$click=async()=>{const r={appState:{}};e.redirectPath&&(r.appState.returnTo=e.redirectPath),t.authentication.state.isAuthenticated?await t.authentication.logout():await t.authentication.login(r)},k(n,()=>t.authentication.state.isAuthenticated?"Log out":"Log in"),q(()=>n.disabled=t.authentication.state.isLoading),n})():null]});Yi(["click"]);const tx=T("<style></style>"),nx=T(`<div class="flex flex-col w-screen max-w-sm"><svg viewBox="0 0 305 62.61" xmlns="http://www.w3.org/2000/svg" class="h-[28px] pl-[19.75px]"><g fill="#273D52"><path d="M0 54.1169H6.81375V35.7722H18.0826C29.5481 35.7722 34.3963 30.3343 34.3963 18.7378V17.4275C34.3963 5.76548 29.417 0.655167 18.0826 0.655167H0V54.1169ZM6.81375 30.1377V6.28961H18.2792C24.7653 6.28961 27.386 8.9758 27.386 16.0516V20.0481C27.386 27.1895 24.7653 30.1377 18.2792 30.1377H6.81375Z"></path><path d="M70.9593 54.1169H77.773V0.655167H70.9593V24.4378H50.8456V0.655167H44.0319V54.1169H50.8456V30.3343H70.9593V54.1169Z"></path><path d="M107.146 54.772C119.528 54.772 125.687 46.5169 125.687 34.9205V19.7861C125.687 8.25511 119.528 0 107.146 0C94.6974 0 88.5388 8.25511 88.5388 19.7861V34.9205C88.5388 46.5169 94.6974 54.772 107.146 54.772ZM95.5491 35.9687V18.8033C95.5491 10.7448 99.4801 5.89651 107.146 5.89651C114.745 5.89651 118.677 10.7448 118.677 18.8033V35.9687C118.677 44.0928 114.745 48.8755 107.146 48.8755C99.4801 48.8755 95.5491 44.0928 95.5491 35.9687Z"></path><path d="M144.295 54.1169H151.109V6.48616H164.54V0.655167H130.864V6.48616H144.295V54.1169Z"></path><path d="M188.299 54.772C200.682 54.772 206.841 46.5169 206.841 34.9205V19.7861C206.841 8.25511 200.682 0 188.299 0C175.851 0 169.693 8.25511 169.693 19.7861V34.9205C169.693 46.5169 175.851 54.772 188.299 54.772ZM176.703 35.9687V18.8033C176.703 10.7448 180.634 5.89651 188.299 5.89651C195.899 5.89651 199.83 10.7448 199.83 18.8033V35.9687C199.83 44.0928 195.899 48.8755 188.299 48.8755C180.634 48.8755 176.703 44.0928 176.703 35.9687Z"></path><path d="M217.6 54.1169H224.021V14.3482L245.576 54.1169H252.608L248.058 45.1084L245.641 40.4239L224.086 0.655167H217.6V54.1169Z"></path></g><g fill="#B35724"><circle cx="249.798" cy="5.202" r="5.202"></circle></g></svg><h1 class="font-medium text-3xl text-center font-sans mt-6 mb-3">Log in to your account</h1><p class="text-gray-500 font-sans text-center mb-8">Don't have an account? <a href="mailto:rado@photon.health" class="text-teal-600 hover:underline hover:cursor-pointer font-sans font-light">Contact Sales</a></p><photon-auth-button></photon-auth-button></div>`);Me("photon-login",{redirectPath:{attribute:"redirect-path",value:void 0,reflect:!1,notify:!1,parse:!1}},e=>{const t=pt();return me(()=>{t||console.error("[photon-login] No valid PhotonClient instance was provided. Please ensure you are wrapping the element in a photon-client element")}),[(()=>{const n=tx.cloneNode(!0);return k(n,Je),n})(),(()=>{const n=H(()=>document.importNode(nx,!0)),r=n.firstChild,i=r.nextSibling,o=i.nextSibling,a=o.nextSibling;return a._$owner=A(),q(()=>a.redirectPath=e.redirectPath),n})()]});var $3=(e,t)=>{let n;const r=()=>clearTimeout(n);return A()&&Gi(r),Object.assign((...o)=>{n!==void 0&&r(),n=setTimeout(()=>e(...o),t)},{clear:r})},ms=window,Xh=ms.ShadowRoot&&(ms.ShadyCSS===void 0||ms.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Zh=Symbol(),n5=new WeakMap,w3=class{constructor(e,t,n){if(this._$cssResult$=!0,n!==Zh)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=e,this.t=t}get styleSheet(){let e=this.o;const t=this.t;if(Xh&&e===void 0){const n=t!==void 0&&t.length===1;n&&(e=n5.get(t)),e===void 0&&((this.o=e=new CSSStyleSheet).replaceSync(this.cssText),n&&n5.set(t,e))}return e}toString(){return this.cssText}},rx=e=>new w3(typeof e=="string"?e:e+"",void 0,Zh),_t=(e,...t)=>{const n=e.length===1?e[0]:t.reduce((r,i,o)=>r+(a=>{if(a._$cssResult$===!0)return a.cssText;if(typeof a=="number")return a;throw Error("Value passed to 'css' function must be a 'css' function result: "+a+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+e[o+1],e[0]);return new w3(n,e,Zh)},ix=(e,t)=>{Xh?e.adoptedStyleSheets=t.map(n=>n instanceof CSSStyleSheet?n:n.styleSheet):t.forEach(n=>{const r=document.createElement("style"),i=ms.litNonce;i!==void 0&&r.setAttribute("nonce",i),r.textContent=n.cssText,e.appendChild(r)})},r5=Xh?e=>e:e=>e instanceof CSSStyleSheet?(t=>{let n="";for(const r of t.cssRules)n+=r.cssText;return rx(n)})(e):e,Uu,Ol=window,i5=Ol.trustedTypes,ox=i5?i5.emptyScript:"",o5=Ol.reactiveElementPolyfillSupport,ia={toAttribute(e,t){switch(t){case Boolean:e=e?ox:null;break;case Object:case Array:e=e==null?e:JSON.stringify(e)}return e},fromAttribute(e,t){let n=e;switch(t){case Boolean:n=e!==null;break;case Number:n=e===null?null:Number(e);break;case Object:case Array:try{n=JSON.parse(e)}catch{n=null}}return n}},_3=(e,t)=>t!==e&&(t==t||e==e),Bu={attribute:!0,type:String,converter:ia,reflect:!1,hasChanged:_3},gi=class extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this.u()}static addInitializer(e){var t;this.finalize(),((t=this.h)!==null&&t!==void 0?t:this.h=[]).push(e)}static get observedAttributes(){this.finalize();const e=[];return this.elementProperties.forEach((t,n)=>{const r=this._$Ep(n,t);r!==void 0&&(this._$Ev.set(r,n),e.push(r))}),e}static createProperty(e,t=Bu){if(t.state&&(t.attribute=!1),this.finalize(),this.elementProperties.set(e,t),!t.noAccessor&&!this.prototype.hasOwnProperty(e)){const n=typeof e=="symbol"?Symbol():"__"+e,r=this.getPropertyDescriptor(e,n,t);r!==void 0&&Object.defineProperty(this.prototype,e,r)}}static getPropertyDescriptor(e,t,n){return{get(){return this[t]},set(r){const i=this[e];this[t]=r,this.requestUpdate(e,i,n)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){return this.elementProperties.get(e)||Bu}static finalize(){if(this.hasOwnProperty("finalized"))return!1;this.finalized=!0;const e=Object.getPrototypeOf(this);if(e.finalize(),e.h!==void 0&&(this.h=[...e.h]),this.elementProperties=new Map(e.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,n=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const r of n)this.createProperty(r,t[r])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(e){const t=[];if(Array.isArray(e)){const n=new Set(e.flat(1/0).reverse());for(const r of n)t.unshift(r5(r))}else e!==void 0&&t.push(r5(e));return t}static _$Ep(e,t){const n=t.attribute;return n===!1?void 0:typeof n=="string"?n:typeof e=="string"?e.toLowerCase():void 0}u(){var e;this._$E_=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$Eg(),this.requestUpdate(),(e=this.constructor.h)===null||e===void 0||e.forEach(t=>t(this))}addController(e){var t,n;((t=this._$ES)!==null&&t!==void 0?t:this._$ES=[]).push(e),this.renderRoot!==void 0&&this.isConnected&&((n=e.hostConnected)===null||n===void 0||n.call(e))}removeController(e){var t;(t=this._$ES)===null||t===void 0||t.splice(this._$ES.indexOf(e)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach((e,t)=>{this.hasOwnProperty(t)&&(this._$Ei.set(t,this[t]),delete this[t])})}createRenderRoot(){var e;const t=(e=this.shadowRoot)!==null&&e!==void 0?e:this.attachShadow(this.constructor.shadowRootOptions);return ix(t,this.constructor.elementStyles),t}connectedCallback(){var e;this.renderRoot===void 0&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(e=this._$ES)===null||e===void 0||e.forEach(t=>{var n;return(n=t.hostConnected)===null||n===void 0?void 0:n.call(t)})}enableUpdating(e){}disconnectedCallback(){var e;(e=this._$ES)===null||e===void 0||e.forEach(t=>{var n;return(n=t.hostDisconnected)===null||n===void 0?void 0:n.call(t)})}attributeChangedCallback(e,t,n){this._$AK(e,n)}_$EO(e,t,n=Bu){var r;const i=this.constructor._$Ep(e,n);if(i!==void 0&&n.reflect===!0){const o=(((r=n.converter)===null||r===void 0?void 0:r.toAttribute)!==void 0?n.converter:ia).toAttribute(t,n.type);this._$El=e,o==null?this.removeAttribute(i):this.setAttribute(i,o),this._$El=null}}_$AK(e,t){var n;const r=this.constructor,i=r._$Ev.get(e);if(i!==void 0&&this._$El!==i){const o=r.getPropertyOptions(i),a=typeof o.converter=="function"?{fromAttribute:o.converter}:((n=o.converter)===null||n===void 0?void 0:n.fromAttribute)!==void 0?o.converter:ia;this._$El=i,this[i]=a.fromAttribute(t,o.type),this._$El=null}}requestUpdate(e,t,n){let r=!0;e!==void 0&&(((n=n||this.constructor.getPropertyOptions(e)).hasChanged||_3)(this[e],t)?(this._$AL.has(e)||this._$AL.set(e,t),n.reflect===!0&&this._$El!==e&&(this._$EC===void 0&&(this._$EC=new Map),this._$EC.set(e,n))):r=!1),!this.isUpdatePending&&r&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const e=this.scheduleUpdate();return e!=null&&await e,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var e;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach((r,i)=>this[i]=r),this._$Ei=void 0);let t=!1;const n=this._$AL;try{t=this.shouldUpdate(n),t?(this.willUpdate(n),(e=this._$ES)===null||e===void 0||e.forEach(r=>{var i;return(i=r.hostUpdate)===null||i===void 0?void 0:i.call(r)}),this.update(n)):this._$Ek()}catch(r){throw t=!1,this._$Ek(),r}t&&this._$AE(n)}willUpdate(e){}_$AE(e){var t;(t=this._$ES)===null||t===void 0||t.forEach(n=>{var r;return(r=n.hostUpdated)===null||r===void 0?void 0:r.call(n)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(e){return!0}update(e){this._$EC!==void 0&&(this._$EC.forEach((t,n)=>this._$EO(n,this[n],t)),this._$EC=void 0),this._$Ek()}updated(e){}firstUpdated(e){}};gi.finalized=!0,gi.elementProperties=new Map,gi.elementStyles=[],gi.shadowRootOptions={mode:"open"},o5?.({ReactiveElement:gi}),((Uu=Ol.reactiveElementVersions)!==null&&Uu!==void 0?Uu:Ol.reactiveElementVersions=[]).push("1.6.1");var Hu,Cl=window,Vi=Cl.trustedTypes,a5=Vi?Vi.createPolicy("lit-html",{createHTML:e=>e}):void 0,or=`lit$${(Math.random()+"").slice(9)}$`,x3="?"+or,ax=`<${x3}>`,Ui=document,oa=(e="")=>Ui.createComment(e),aa=e=>e===null||typeof e!="object"&&typeof e!="function",k3=Array.isArray,sx=e=>k3(e)||typeof e?.[Symbol.iterator]=="function",Eo=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,s5=/-->/g,l5=/>/g,Or=RegExp(`>|[
|
|
746
|
+
`;class Q_{sdk;setStore;store;authentication;getSDK;clinical;constructor(t){this.sdk=t;const[n,r]=kr({authentication:{isAuthenticated:!1,isInOrg:!1,permissions:[],isLoading:!0,error:void 0,user:void 0},catalog:{isLoading:!1,treatments:[],templates:[]},catalogs:{isLoading:!1,catalogs:[]},dispenseUnits:{isLoading:!1,dispenseUnits:new Array},patients:{isLoading:!1,patients:[],finished:!1},patient:{isLoading:!1,patient:void 0},prescription:{isLoading:!1,errors:[],error:void 0,data:void 0}});this.setStore=r,this.store=n,this.authentication={state:n.authentication,handleRedirect:async i=>{try{const o=await this.sdk.authentication.handleRedirect(i);G_(o?.appState)}catch(o){const s=new URLSearchParams(window.location.search).get("error_description");o.message.includes("must be an organization id")?this.setStore("authentication",{...this.store.authentication,error:"The provided organization id is invalid or does not exist"}):s?.includes("is not part of the org")?this.setStore("authentication",{...this.store.authentication,error:"User is not authorized",isLoading:!1}):this.setStore("authentication",{...this.store.authentication,error:o.message})}},checkSession:this.checkSession.bind(this),login:this.login.bind(this),logout:this.logout.bind(this)},this.getSDK=this._getSDK.bind(this),this.clinical={catalog:{state:n.catalog,getCatalog:this.getCatalog.bind(this)},catalogs:{state:n.catalogs,getCatalogs:this.getCatalogs.bind(this)},dispenseUnits:{state:n.dispenseUnits,getDispenseUnits:this.getDispenseUnits.bind(this)},patients:{state:n.patients,getPatients:this.getPatients.bind(this)},patient:{state:n.patient,getPatient:this.getPatient.bind(this)},prescription:{state:n.prescription,createPrescription:this.createPrescription.bind(this)}}}_getSDK(){return this.sdk}async checkSession(){try{await this.sdk.authentication.checkSession();const t=await this.sdk.authentication.isAuthenticated();this.setStore("authentication",{...this.store.authentication,isAuthenticated:t});const n=await this.sdk.authentication.getUser(),r=!!this.sdk?.organization&&!!n?.org_id;let i;try{const o=await this.sdk.authentication.getAccessToken();i=b3(o)?.permissions||[]}catch{i=[]}this.setStore("authentication",{...this.store.authentication,user:n,isLoading:!1,isInOrg:t&&r&&this.sdk.organization===n.org_id,permissions:i||[]})}catch{this.setStore("authentication",{...this.store.authentication,isLoading:!1})}}async login(t={}){await this.sdk.authentication.login(t),await this.checkSession()}async logout(t={}){await this.sdk.authentication.logout(t),this.setStore("authentication",{...this.store.authentication,isAuthenticated:!1,isInOrg:!1,permissions:[],user:void 0})}async getPatients(t){t||(t={}),this.setStore("patients",{...this.store.patients,isLoading:!0});const{data:n}=await this.sdk.clinical.patient.getPatients(t);this.setStore("patients",{...this.store.patients,isLoading:!1,patients:t.clear?n.patients:this.store.patients.patients.concat(n.patients),finished:n.patients.length==0})}async getPatient(t){this.setStore("patient",{...this.store.patient,isLoading:!0});const{data:n}=await this.sdk.clinical.patient.getPatient(t);return this.setStore("patient",{...this.store.patient,isLoading:!1,patient:n.patient}),n.patient}async getCatalog(t){this.setStore("catalog",{...this.store.catalog,isLoading:!0});const{data:n}=await this.sdk.clinical.catalog.getCatalog({id:t.id,fragment:{CatalogTreatmentsFields:K_}});this.setStore("catalog",{...this.store.catalog,isLoading:!1,treatments:n.catalog.treatments.map(r=>r)||[],templates:n.catalog.templates.map(r=>r)||[]})}async getCatalogs(){this.setStore("catalogs",{...this.store.catalogs,isLoading:!0});const{data:t}=await this.sdk.clinical.catalog.getCatalogs();this.setStore("catalogs",{...this.store.catalogs,isLoading:!1,catalogs:t.catalogs})}async getDispenseUnits(){this.setStore("dispenseUnits",{...this.store.dispenseUnits,isLoading:!0});const{data:t}=await this.sdk.clinical.prescription.getDispenseUnits();this.setStore("dispenseUnits",{...this.store.dispenseUnits,isLoading:!1,dispenseUnits:t.dispenseUnits.map((n,r)=>({id:String(r),...n}))})}async createPrescription(t){this.setStore("prescription",{...this.store.prescription,isLoading:!0});const n=this.sdk.clinical.prescription.createPrescription({});try{const{data:r,errors:i}=await n({variables:t,refetchQueries:[],awaitRefetchQueries:!1});return i&&i.length>0&&this.setStore("prescription",{...this.store.prescription,errors:[...i]}),r?.createPrescription&&this.setStore("prescription",{...this.store.prescription,data:r.createPrescription}),this.setStore("prescription",{...this.store.prescription,isLoading:!1}),{data:r,errors:i}}catch(r){return this.setStore("prescription",{...this.store.prescription,error:r,isLoading:!1}),{data:null,errors:[]}}}}var Y_=(e,t,n)=>{const r=n(e,t);return Gi(()=>clearInterval(r))};const X_=N("<slot></slot>"),Z_=N("<div></div>");Me("photon-client",{domain:{attribute:"domain",value:void 0,reflect:!1,notify:!1,parse:!1},id:{attribute:"id",value:void 0,reflect:!1,notify:!1,parse:!1},redirectUri:{attribute:"redirect-uri",value:void 0,reflect:!1,notify:!1,parse:!1},redirectPath:{attribute:"redirect-path",value:void 0,reflect:!1,notify:!1,parse:!1},org:{attribute:"org",value:void 0,reflect:!1,notify:!1,parse:!1},audience:{attribute:"audience",value:void 0,reflect:!1,notify:!1,parse:!1},uri:{attribute:"uri",value:void 0,reflect:!1,notify:!1,parse:!1},developmentMode:{attribute:"dev-mode",value:!1,reflect:!0,notify:!1,parse:!0},errorMessage:{attribute:"error-message",value:"Oh snap! There was an error loading. Please contact your site's administrator",reflect:!1,notify:!1,parse:!1},autoLogin:{attribute:"auto-login",value:!1,reflect:!1,notify:!1,parse:!0}},e=>{let t;const n=new z_({domain:e.domain,audience:e.audience,uri:e.uri,clientId:e.id,redirectURI:e.redirectUri?e.redirectUri:window.location.origin,organization:e.org,developmentMode:e.developmentMode}),r=new Q_(n);e.developmentMode&&console.info("[PhotonClient]: Development mode enabled");const[i]=V(r);return me(async()=>{z4()&&i()?(await i()?.authentication.handleRedirect(),e.redirectPath&&window.location.replace(e.redirectPath)):i()&&(await i()?.authentication.checkSession(),Y_(async()=>{await i()?.authentication.checkSession()},6e4,setInterval))}),me(async()=>{if(!i()?.authentication.state.isLoading&&!i()?.authentication.state.isAuthenticated&&e.autoLogin){const o={appState:{}};e.redirectPath&&(o.appState.returnTo=e.redirectPath),await i()?.authentication.login(o)}}),(()=>{const o=Z_.cloneNode(!0),a=t;return typeof a=="function"?he(a,o):t=o,x(o,S(mg.Provider,{get value(){return i()},get children(){const s=X_.cloneNode(!0);return s._$owner=A(),s}})),o})()});const Je=`*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.fixed{position:fixed}.relative{position:relative}.left-0{left:0}.top-0{top:0}.z-10{z-index:10}.order-last{order:9999}.m-3{margin:.75rem}.my-8{margin-top:2rem;margin-bottom:2rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.mb-8{margin-bottom:2rem}.ml-1{margin-left:.25rem}.mr-1{margin-right:.25rem}.mt-2{margin-top:.5rem}.mt-6{margin-top:1.5rem}.mt-8{margin-top:2rem}.block{display:block}.inline{display:inline}.flex{display:flex}.hidden{display:none}.h-10{height:2.5rem}.h-\\[21px\\]{height:21px}.h-\\[28px\\]{height:28px}.h-full{height:100%}.h-screen{height:100vh}.min-h-screen{min-height:100vh}.w-2\\/5{width:40%}.w-\\[16px\\]{width:16px}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-screen{width:100vw}.min-w-\\[40\\%\\]{min-width:40%}.min-w-\\[48\\%\\]{min-width:48%}.max-w-sm{max-width:24rem}.flex-1{flex:1 1 0%}.flex-shrink{flex-shrink:1}.flex-grow{flex-grow:1}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-8{gap:2rem}.self-start{align-self:flex-start}.self-end{align-self:flex-end}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-scroll{overflow-y:scroll}.overflow-ellipsis{text-overflow:ellipsis}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.rounded{border-radius:.25rem}.rounded-lg{border-radius:.5rem}.border{border-width:1px}.border-2{border-width:2px}.border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.border-red-400{--tw-border-opacity: 1;border-color:rgb(248 113 113/var(--tw-border-opacity))}.border-red-500{--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity))}.bg-\\[\\#f7f4f4\\]{--tw-bg-opacity: 1;background-color:rgb(247 244 244/var(--tw-bg-opacity))}.bg-gray-800{--tw-bg-opacity: 1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.bg-photon-blue{--tw-bg-opacity: 1;background-color:rgb(49 130 206/var(--tw-bg-opacity))}.bg-red-100{--tw-bg-opacity: 1;background-color:rgb(254 226 226/var(--tw-bg-opacity))}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.p-2{padding:.5rem}.p-4{padding:1rem}.px-4{padding-left:1rem;padding-right:1rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-4{padding-top:1rem;padding-bottom:1rem}.pb-2{padding-bottom:.5rem}.pb-24{padding-bottom:6rem}.pb-4{padding-bottom:1rem}.pb-5{padding-bottom:1.25rem}.pl-1{padding-left:.25rem}.pl-2{padding-left:.5rem}.pl-\\[19\\.75px\\]{padding-left:19.75px}.pt-1{padding-top:.25rem}.pt-1\\.5{padding-top:.375rem}.pt-2{padding-top:.5rem}.pt-28{padding-top:7rem}.pt-\\[3px\\]{padding-top:3px}.text-left{text-align:left}.text-center{text-align:center}.font-sans{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji"}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-7xl{font-size:4.5rem;line-height:1}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-light{font-weight:300}.font-medium{font-weight:500}.font-normal{font-weight:400}.italic{font-style:italic}.leading-snug{line-height:1.375}.text-black{--tw-text-opacity: 1;color:rgb(0 0 0/var(--tw-text-opacity))}.text-gray-300{--tw-text-opacity: 1;color:rgb(209 213 219/var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175/var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128/var(--tw-text-opacity))}.text-gray-600{--tw-text-opacity: 1;color:rgb(75 85 99/var(--tw-text-opacity))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81/var(--tw-text-opacity))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94/var(--tw-text-opacity))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}.text-red-700{--tw-text-opacity: 1;color:rgb(185 28 28/var(--tw-text-opacity))}.text-teal-600{--tw-text-opacity: 1;color:rgb(13 148 136/var(--tw-text-opacity))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255/var(--tw-text-opacity))}.underline{text-decoration-line:underline}.shadow-card{--tw-shadow: 0px 0px 1px rgba(48, 49, 51, .05),0px 2px 4px rgba(48, 49, 51, .1);--tw-shadow-colored: 0px 0px 1px var(--tw-shadow-color), 0px 2px 4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-ring-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-shadow)}.outline{outline-style:solid}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.hover\\:cursor-pointer:hover{cursor:pointer}.hover\\:bg-blue-700:hover{--tw-bg-opacity: 1;background-color:rgb(29 78 216/var(--tw-bg-opacity))}.hover\\:bg-photon-blue-dark:hover{--tw-bg-opacity: 1;background-color:rgb(43 108 176/var(--tw-bg-opacity))}.hover\\:text-black:hover{--tw-text-opacity: 1;color:rgb(0 0 0/var(--tw-text-opacity))}.hover\\:text-gray-600:hover{--tw-text-opacity: 1;color:rgb(75 85 99/var(--tw-text-opacity))}.hover\\:underline:hover{text-decoration-line:underline}.disabled\\:bg-gray-500:disabled{--tw-bg-opacity: 1;background-color:rgb(107 114 128/var(--tw-bg-opacity))}@media (min-width: 475px){.xs\\:mx-auto{margin-left:auto;margin-right:auto}.xs\\:w-fit{width:-moz-fit-content;width:fit-content}.xs\\:min-w-\\[40\\%\\]{min-width:40%}.xs\\:min-w-\\[48\\%\\]{min-width:48%}.xs\\:flex-row{flex-direction:row}.xs\\:items-center{align-items:center}.xs\\:gap-4{gap:1rem}.xs\\:self-end{align-self:flex-end}.xs\\:pb-2{padding-bottom:.5rem}.xs\\:pt-28{padding-top:7rem}.xs\\:text-base{font-size:1rem;line-height:1.5rem}}@media (min-width: 640px){.sm\\:order-first{order:-9999}.sm\\:mt-0{margin-top:0}.sm\\:inline{display:inline}.sm\\:grid{display:grid}.sm\\:w-\\[600px\\]{width:600px}.sm\\:w-auto{width:auto}.sm\\:flex-none{flex:none}.sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\\:flex-row{flex-direction:row}.sm\\:flex-wrap{flex-wrap:wrap}.sm\\:items-center{align-items:center}.sm\\:gap-3{gap:.75rem}.sm\\:gap-4{gap:1rem}.sm\\:gap-x-4{-moz-column-gap:1rem;column-gap:1rem}.sm\\:py-2{padding-top:.5rem;padding-bottom:.5rem}.sm\\:text-right{text-align:right}}@media (min-width: 768px){.md\\:mb-0{margin-bottom:0}.md\\:w-2\\/5{width:40%}.md\\:w-3\\/5{width:60%}.md\\:max-w-\\[50\\%\\]{max-width:50%}.md\\:flex-row{flex-direction:row}.md\\:justify-center{justify-content:center}.md\\:px-4{padding-left:1rem;padding-right:1rem}.md\\:px-8{padding-left:2rem;padding-right:2rem}.md\\:py-2{padding-top:.5rem;padding-bottom:.5rem}.md\\:py-3{padding-top:.75rem;padding-bottom:.75rem}.md\\:pb-52{padding-bottom:13rem}.md\\:pr-2{padding-right:.5rem}.md\\:pt-4{padding-top:1rem}}@media (min-width: 1024px){.lg\\:gap-2{gap:.5rem}.lg\\:pt-20{padding-top:5rem}.lg\\:text-base{font-size:1rem;line-height:1.5rem}.lg\\:text-lg{font-size:1.125rem;line-height:1.75rem}.lg\\:text-sm{font-size:.875rem;line-height:1.25rem}}
|
|
747
|
+
`,J_=N("<style></style>"),ex=N('<button class="w-full disabled:bg-gray-500 bg-photon-blue hover:bg-blue-700 text-white h-10 px-4 rounded-lg font-sans hover:bg-photon-blue-dark transition ease-in-out delay-50"></button>');Me("photon-auth-button",{redirectPath:{attribute:"redirect-path",value:void 0,reflect:!1,notify:!1,parse:!1}},e=>{const t=pt();return me(()=>{t||console.error("[photon-auth-button] No valid PhotonClient instance was provided. Please ensure you are wrapping the element in a photon-client element")}),[(()=>{const n=J_.cloneNode(!0);return x(n,Je),n})(),t?(()=>{const n=ex.cloneNode(!0);return n.$$click=async()=>{const r={appState:{}};e.redirectPath&&(r.appState.returnTo=e.redirectPath),t.authentication.state.isAuthenticated?await t.authentication.logout():await t.authentication.login(r)},x(n,()=>t.authentication.state.isAuthenticated?"Log out":"Log in"),q(()=>n.disabled=t.authentication.state.isLoading),n})():null]});Yi(["click"]);const tx=N("<style></style>"),nx=N(`<div class="flex flex-col w-screen max-w-sm"><svg viewBox="0 0 305 62.61" xmlns="http://www.w3.org/2000/svg" class="h-[28px] pl-[19.75px]"><g fill="#273D52"><path d="M0 54.1169H6.81375V35.7722H18.0826C29.5481 35.7722 34.3963 30.3343 34.3963 18.7378V17.4275C34.3963 5.76548 29.417 0.655167 18.0826 0.655167H0V54.1169ZM6.81375 30.1377V6.28961H18.2792C24.7653 6.28961 27.386 8.9758 27.386 16.0516V20.0481C27.386 27.1895 24.7653 30.1377 18.2792 30.1377H6.81375Z"></path><path d="M70.9593 54.1169H77.773V0.655167H70.9593V24.4378H50.8456V0.655167H44.0319V54.1169H50.8456V30.3343H70.9593V54.1169Z"></path><path d="M107.146 54.772C119.528 54.772 125.687 46.5169 125.687 34.9205V19.7861C125.687 8.25511 119.528 0 107.146 0C94.6974 0 88.5388 8.25511 88.5388 19.7861V34.9205C88.5388 46.5169 94.6974 54.772 107.146 54.772ZM95.5491 35.9687V18.8033C95.5491 10.7448 99.4801 5.89651 107.146 5.89651C114.745 5.89651 118.677 10.7448 118.677 18.8033V35.9687C118.677 44.0928 114.745 48.8755 107.146 48.8755C99.4801 48.8755 95.5491 44.0928 95.5491 35.9687Z"></path><path d="M144.295 54.1169H151.109V6.48616H164.54V0.655167H130.864V6.48616H144.295V54.1169Z"></path><path d="M188.299 54.772C200.682 54.772 206.841 46.5169 206.841 34.9205V19.7861C206.841 8.25511 200.682 0 188.299 0C175.851 0 169.693 8.25511 169.693 19.7861V34.9205C169.693 46.5169 175.851 54.772 188.299 54.772ZM176.703 35.9687V18.8033C176.703 10.7448 180.634 5.89651 188.299 5.89651C195.899 5.89651 199.83 10.7448 199.83 18.8033V35.9687C199.83 44.0928 195.899 48.8755 188.299 48.8755C180.634 48.8755 176.703 44.0928 176.703 35.9687Z"></path><path d="M217.6 54.1169H224.021V14.3482L245.576 54.1169H252.608L248.058 45.1084L245.641 40.4239L224.086 0.655167H217.6V54.1169Z"></path></g><g fill="#B35724"><circle cx="249.798" cy="5.202" r="5.202"></circle></g></svg><h1 class="font-medium text-3xl text-center font-sans mt-6 mb-3">Log in to your account</h1><p class="text-gray-500 font-sans text-center mb-8">Don't have an account? <a href="mailto:rado@photon.health" class="text-teal-600 hover:underline hover:cursor-pointer font-sans font-light">Contact Sales</a></p><photon-auth-button></photon-auth-button></div>`);Me("photon-login",{redirectPath:{attribute:"redirect-path",value:void 0,reflect:!1,notify:!1,parse:!1}},e=>{const t=pt();return me(()=>{t||console.error("[photon-login] No valid PhotonClient instance was provided. Please ensure you are wrapping the element in a photon-client element")}),[(()=>{const n=tx.cloneNode(!0);return x(n,Je),n})(),(()=>{const n=H(()=>document.importNode(nx,!0)),r=n.firstChild,i=r.nextSibling,o=i.nextSibling,a=o.nextSibling;return a._$owner=A(),q(()=>a.redirectPath=e.redirectPath),n})()]});var $3=(e,t)=>{let n;const r=()=>clearTimeout(n);return A()&&Gi(r),Object.assign((...o)=>{n!==void 0&&r(),n=setTimeout(()=>e(...o),t)},{clear:r})},ms=window,Xh=ms.ShadowRoot&&(ms.ShadyCSS===void 0||ms.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Zh=Symbol(),n5=new WeakMap,w3=class{constructor(e,t,n){if(this._$cssResult$=!0,n!==Zh)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=e,this.t=t}get styleSheet(){let e=this.o;const t=this.t;if(Xh&&e===void 0){const n=t!==void 0&&t.length===1;n&&(e=n5.get(t)),e===void 0&&((this.o=e=new CSSStyleSheet).replaceSync(this.cssText),n&&n5.set(t,e))}return e}toString(){return this.cssText}},rx=e=>new w3(typeof e=="string"?e:e+"",void 0,Zh),_t=(e,...t)=>{const n=e.length===1?e[0]:t.reduce((r,i,o)=>r+(a=>{if(a._$cssResult$===!0)return a.cssText;if(typeof a=="number")return a;throw Error("Value passed to 'css' function must be a 'css' function result: "+a+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+e[o+1],e[0]);return new w3(n,e,Zh)},ix=(e,t)=>{Xh?e.adoptedStyleSheets=t.map(n=>n instanceof CSSStyleSheet?n:n.styleSheet):t.forEach(n=>{const r=document.createElement("style"),i=ms.litNonce;i!==void 0&&r.setAttribute("nonce",i),r.textContent=n.cssText,e.appendChild(r)})},r5=Xh?e=>e:e=>e instanceof CSSStyleSheet?(t=>{let n="";for(const r of t.cssRules)n+=r.cssText;return rx(n)})(e):e,Uu,Ol=window,i5=Ol.trustedTypes,ox=i5?i5.emptyScript:"",o5=Ol.reactiveElementPolyfillSupport,ia={toAttribute(e,t){switch(t){case Boolean:e=e?ox:null;break;case Object:case Array:e=e==null?e:JSON.stringify(e)}return e},fromAttribute(e,t){let n=e;switch(t){case Boolean:n=e!==null;break;case Number:n=e===null?null:Number(e);break;case Object:case Array:try{n=JSON.parse(e)}catch{n=null}}return n}},_3=(e,t)=>t!==e&&(t==t||e==e),Bu={attribute:!0,type:String,converter:ia,reflect:!1,hasChanged:_3},gi=class extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this.u()}static addInitializer(e){var t;this.finalize(),((t=this.h)!==null&&t!==void 0?t:this.h=[]).push(e)}static get observedAttributes(){this.finalize();const e=[];return this.elementProperties.forEach((t,n)=>{const r=this._$Ep(n,t);r!==void 0&&(this._$Ev.set(r,n),e.push(r))}),e}static createProperty(e,t=Bu){if(t.state&&(t.attribute=!1),this.finalize(),this.elementProperties.set(e,t),!t.noAccessor&&!this.prototype.hasOwnProperty(e)){const n=typeof e=="symbol"?Symbol():"__"+e,r=this.getPropertyDescriptor(e,n,t);r!==void 0&&Object.defineProperty(this.prototype,e,r)}}static getPropertyDescriptor(e,t,n){return{get(){return this[t]},set(r){const i=this[e];this[t]=r,this.requestUpdate(e,i,n)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){return this.elementProperties.get(e)||Bu}static finalize(){if(this.hasOwnProperty("finalized"))return!1;this.finalized=!0;const e=Object.getPrototypeOf(this);if(e.finalize(),e.h!==void 0&&(this.h=[...e.h]),this.elementProperties=new Map(e.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,n=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const r of n)this.createProperty(r,t[r])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(e){const t=[];if(Array.isArray(e)){const n=new Set(e.flat(1/0).reverse());for(const r of n)t.unshift(r5(r))}else e!==void 0&&t.push(r5(e));return t}static _$Ep(e,t){const n=t.attribute;return n===!1?void 0:typeof n=="string"?n:typeof e=="string"?e.toLowerCase():void 0}u(){var e;this._$E_=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$Eg(),this.requestUpdate(),(e=this.constructor.h)===null||e===void 0||e.forEach(t=>t(this))}addController(e){var t,n;((t=this._$ES)!==null&&t!==void 0?t:this._$ES=[]).push(e),this.renderRoot!==void 0&&this.isConnected&&((n=e.hostConnected)===null||n===void 0||n.call(e))}removeController(e){var t;(t=this._$ES)===null||t===void 0||t.splice(this._$ES.indexOf(e)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach((e,t)=>{this.hasOwnProperty(t)&&(this._$Ei.set(t,this[t]),delete this[t])})}createRenderRoot(){var e;const t=(e=this.shadowRoot)!==null&&e!==void 0?e:this.attachShadow(this.constructor.shadowRootOptions);return ix(t,this.constructor.elementStyles),t}connectedCallback(){var e;this.renderRoot===void 0&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(e=this._$ES)===null||e===void 0||e.forEach(t=>{var n;return(n=t.hostConnected)===null||n===void 0?void 0:n.call(t)})}enableUpdating(e){}disconnectedCallback(){var e;(e=this._$ES)===null||e===void 0||e.forEach(t=>{var n;return(n=t.hostDisconnected)===null||n===void 0?void 0:n.call(t)})}attributeChangedCallback(e,t,n){this._$AK(e,n)}_$EO(e,t,n=Bu){var r;const i=this.constructor._$Ep(e,n);if(i!==void 0&&n.reflect===!0){const o=(((r=n.converter)===null||r===void 0?void 0:r.toAttribute)!==void 0?n.converter:ia).toAttribute(t,n.type);this._$El=e,o==null?this.removeAttribute(i):this.setAttribute(i,o),this._$El=null}}_$AK(e,t){var n;const r=this.constructor,i=r._$Ev.get(e);if(i!==void 0&&this._$El!==i){const o=r.getPropertyOptions(i),a=typeof o.converter=="function"?{fromAttribute:o.converter}:((n=o.converter)===null||n===void 0?void 0:n.fromAttribute)!==void 0?o.converter:ia;this._$El=i,this[i]=a.fromAttribute(t,o.type),this._$El=null}}requestUpdate(e,t,n){let r=!0;e!==void 0&&(((n=n||this.constructor.getPropertyOptions(e)).hasChanged||_3)(this[e],t)?(this._$AL.has(e)||this._$AL.set(e,t),n.reflect===!0&&this._$El!==e&&(this._$EC===void 0&&(this._$EC=new Map),this._$EC.set(e,n))):r=!1),!this.isUpdatePending&&r&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const e=this.scheduleUpdate();return e!=null&&await e,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var e;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach((r,i)=>this[i]=r),this._$Ei=void 0);let t=!1;const n=this._$AL;try{t=this.shouldUpdate(n),t?(this.willUpdate(n),(e=this._$ES)===null||e===void 0||e.forEach(r=>{var i;return(i=r.hostUpdate)===null||i===void 0?void 0:i.call(r)}),this.update(n)):this._$Ek()}catch(r){throw t=!1,this._$Ek(),r}t&&this._$AE(n)}willUpdate(e){}_$AE(e){var t;(t=this._$ES)===null||t===void 0||t.forEach(n=>{var r;return(r=n.hostUpdated)===null||r===void 0?void 0:r.call(n)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(e){return!0}update(e){this._$EC!==void 0&&(this._$EC.forEach((t,n)=>this._$EO(n,this[n],t)),this._$EC=void 0),this._$Ek()}updated(e){}firstUpdated(e){}};gi.finalized=!0,gi.elementProperties=new Map,gi.elementStyles=[],gi.shadowRootOptions={mode:"open"},o5?.({ReactiveElement:gi}),((Uu=Ol.reactiveElementVersions)!==null&&Uu!==void 0?Uu:Ol.reactiveElementVersions=[]).push("1.6.1");var Hu,Cl=window,Vi=Cl.trustedTypes,a5=Vi?Vi.createPolicy("lit-html",{createHTML:e=>e}):void 0,or=`lit$${(Math.random()+"").slice(9)}$`,x3="?"+or,ax=`<${x3}>`,Ui=document,oa=(e="")=>Ui.createComment(e),aa=e=>e===null||typeof e!="object"&&typeof e!="function",k3=Array.isArray,sx=e=>k3(e)||typeof e?.[Symbol.iterator]=="function",Eo=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,s5=/-->/g,l5=/>/g,Or=RegExp(`>|[
|
|
748
748
|
\f\r](?:([^\\s"'>=/]+)([
|
|
749
749
|
\f\r]*=[
|
|
750
750
|
\f\r]*(?:[^
|
|
@@ -1007,7 +1007,7 @@ lit-html/directives/class-map.js:
|
|
|
1007
1007
|
background: var(--arrow-color);
|
|
1008
1008
|
z-index: -1;
|
|
1009
1009
|
}
|
|
1010
|
-
`;function oo(e){return e.split("-")[1]}function e1(e){return e==="y"?"height":"width"}function ur(e){return e.split("-")[0]}function ao(e){return["top","bottom"].includes(ur(e))?"x":"y"}function y5(e,t,n){let{reference:r,floating:i}=e;const o=r.x+r.width/2-i.width/2,a=r.y+r.height/2-i.height/2,s=ao(t),c=e1(s),l=r[c]/2-i[c]/2,u=s==="x";let d;switch(ur(t)){case"top":d={x:o,y:r.y-i.height};break;case"bottom":d={x:o,y:r.y+r.height};break;case"right":d={x:r.x+r.width,y:a};break;case"left":d={x:r.x-i.width,y:a};break;default:d={x:r.x,y:r.y}}switch(oo(t)){case"start":d[s]-=l*(n&&u?-1:1);break;case"end":d[s]+=l*(n&&u?-1:1)}return d}var Px=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:a}=n,s=o.filter(Boolean),c=await(a.isRTL==null?void 0:a.isRTL(t));let l=await a.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=y5(l,r,c),f=r,h={},p=0;for(let m=0;m<s.length;m++){const{name:v,fn:b}=s[m],{x:y,y:g,data:_,reset:x}=await b({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:h,rects:l,platform:a,elements:{reference:e,floating:t}});u=y??u,d=g??d,h=Ft(je({},h),{[v]:je(je({},h[v]),_)}),x&&p<=50&&(p++,typeof x=="object"&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=y5(l,f,c)),m=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:h}};function L3(e){return typeof e!="number"?function(t){return je({top:0,right:0,bottom:0,left:0},t)}(e):{top:e,right:e,bottom:e,left:e}}function x0(e){return Ft(je({},e),{top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height})}async function t1(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:o,rects:a,elements:s,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:f=!1,padding:h=0}=t,p=L3(h),m=s[f?d==="floating"?"reference":"floating":d],v=x0(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(m)))==null||n?m:m.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(s.floating)),boundary:l,rootBoundary:u,strategy:c})),b=d==="floating"?Ft(je({},a.floating),{x:r,y:i}):a.reference,y=await(o.getOffsetParent==null?void 0:o.getOffsetParent(s.floating)),g=await(o.isElement==null?void 0:o.isElement(y))&&await(o.getScale==null?void 0:o.getScale(y))||{x:1,y:1},_=x0(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({rect:b,offsetParent:y,strategy:c}):b);return{top:(v.top-_.top+p.top)/g.y,bottom:(_.bottom-v.bottom+p.bottom)/g.y,left:(v.left-_.left+p.left)/g.x,right:(_.right-v.right+p.right)/g.x}}var k0=Math.min,Tr=Math.max;function E0(e,t,n){return Tr(e,k0(t,n))}var Ax=e=>({name:"arrow",options:e,async fn(t){const{element:n,padding:r=0}=e||{},{x:i,y:o,placement:a,rects:s,platform:c}=t;if(n==null)return{};const l=L3(r),u={x:i,y:o},d=ao(a),f=e1(d),h=await c.getDimensions(n),p=d==="y"?"top":"left",m=d==="y"?"bottom":"right",v=s.reference[f]+s.reference[d]-u[d]-s.floating[f],b=u[d]-s.reference[d],y=await(c.getOffsetParent==null?void 0:c.getOffsetParent(n));let g=y?d==="y"?y.clientHeight||0:y.clientWidth||0:0;g===0&&(g=s.floating[f]);const _=v/2-b/2,x=l[p],O=g-h[f]-l[m],C=g/2-h[f]/2+_,M=E0(x,C,O),D=oo(a)!=null&&C!=M&&s.reference[f]/2-(C<x?l[p]:l[m])-h[f]/2<0;return{[d]:u[d]-(D?C<x?x-C:O-C:0),data:{[d]:M,centerOffset:C-M}}}}),Ix=["top","right","bottom","left"];Ix.reduce((e,t)=>e.concat(t,t+"-start",t+"-end"),[]);var Mx={left:"right",right:"left",bottom:"top",top:"bottom"};function Pl(e){return e.replace(/left|right|bottom|top/g,t=>Mx[t])}function Dx(e,t,n){n===void 0&&(n=!1);const r=oo(e),i=ao(e),o=e1(i);let a=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=Pl(a)),{main:a,cross:Pl(a)}}var Lx={start:"end",end:"start"};function Ku(e){return e.replace(/start|end/g,t=>Lx[t])}var Rx=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:i,rects:o,initialPlacement:a,platform:s,elements:c}=t,l=e,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:m=!0}=l,v=Jh(l,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]),b=ur(r),y=ur(a)===a,g=await(s.isRTL==null?void 0:s.isRTL(c.floating)),_=f||(y||!m?[Pl(a)]:function(J){const G=Pl(J);return[Ku(J),G,Ku(G)]}(a));f||p==="none"||_.push(...function(J,G,j,z){const Q=oo(J);let I=function(U,W,de){const be=["left","right"],P=["right","left"],B=["top","bottom"],Ce=["bottom","top"];switch(U){case"top":case"bottom":return de?W?P:be:W?be:P;case"left":case"right":return W?B:Ce;default:return[]}}(ur(J),j==="start",z);return Q&&(I=I.map(U=>U+"-"+Q),G&&(I=I.concat(I.map(Ku)))),I}(a,m,p,g));const x=[a,..._],O=await t1(t,v),C=[];let M=((n=i.flip)==null?void 0:n.overflows)||[];if(u&&C.push(O[b]),d){const{main:J,cross:G}=Dx(r,o,g);C.push(O[J],O[G])}if(M=[...M,{placement:r,overflows:C}],!C.every(J=>J<=0)){var D,F;const J=(((D=i.flip)==null?void 0:D.index)||0)+1,G=x[J];if(G)return{data:{index:J,overflows:M},reset:{placement:G}};let j=(F=M.filter(z=>z.overflows[0]<=0).sort((z,Q)=>z.overflows[1]-Q.overflows[1])[0])==null?void 0:F.placement;if(!j)switch(h){case"bestFit":{var Y;const z=(Y=M.map(Q=>[Q.placement,Q.overflows.filter(I=>I>0).reduce((I,U)=>I+U,0)]).sort((Q,I)=>Q[1]-I[1])[0])==null?void 0:Y[0];z&&(j=z);break}case"initialPlacement":j=a}if(r!==j)return{reset:{placement:j}}}return{}}}},Fx=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,i=await async function(o,a){const{placement:s,platform:c,elements:l}=o,u=await(c.isRTL==null?void 0:c.isRTL(l.floating)),d=ur(s),f=oo(s),h=ao(s)==="x",p=["left","top"].includes(d)?-1:1,m=u&&h?-1:1,v=typeof a=="function"?a(o):a;let{mainAxis:b,crossAxis:y,alignmentAxis:g}=typeof v=="number"?{mainAxis:v,crossAxis:0,alignmentAxis:null}:je({mainAxis:0,crossAxis:0,alignmentAxis:null},v);return f&&typeof g=="number"&&(y=f==="end"?-1*g:g),h?{x:y*m,y:b*p}:{x:b*p,y:y*m}}(t,e);return{x:n+i.x,y:r+i.y,data:i}}}};function zx(e){return e==="x"?"y":"x"}var jx=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,o=e,{mainAxis:a=!0,crossAxis:s=!1,limiter:c={fn:b=>{let{x:y,y:g}=b;return{x:y,y:g}}}}=o,l=Jh(o,["mainAxis","crossAxis","limiter"]),u={x:n,y:r},d=await t1(t,l),f=ao(ur(i)),h=zx(f);let p=u[f],m=u[h];if(a){const b=f==="y"?"bottom":"right";p=E0(p+d[f==="y"?"top":"left"],p,p-d[b])}if(s){const b=h==="y"?"bottom":"right";m=E0(m+d[h==="y"?"top":"left"],m,m-d[b])}const v=c.fn(Ft(je({},t),{[f]:p,[h]:m}));return Ft(je({},v),{data:{x:v.x-n,y:v.y-r}})}}},b5=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:i,elements:o}=t,a=e,{apply:s=()=>{}}=a,c=Jh(a,["apply"]),l=await t1(t,c),u=ur(n),d=oo(n),f=ao(n)==="x",{width:h,height:p}=r.floating;let m,v;u==="top"||u==="bottom"?(m=u,v=d===(await(i.isRTL==null?void 0:i.isRTL(o.floating))?"start":"end")?"left":"right"):(v=u,m=d==="end"?"top":"bottom");const b=p-l[m],y=h-l[v];let g=b,_=y;if(f?_=k0(h-l.right-l.left,y):g=k0(p-l.bottom-l.top,b),!t.middlewareData.shift&&!d){const O=Tr(l.left,0),C=Tr(l.right,0),M=Tr(l.top,0),D=Tr(l.bottom,0);f?_=h-2*(O!==0||C!==0?O+C:Tr(l.left,l.right)):g=p-2*(M!==0||D!==0?M+D:Tr(l.top,l.bottom))}await s(Ft(je({},t),{availableWidth:_,availableHeight:g}));const x=await i.getDimensions(o.floating);return h!==x.width||p!==x.height?{reset:{rects:!0}}:{}}}};function Gt(e){var t;return((t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Cn(e){return Gt(e).getComputedStyle(e)}var $5=Math.min,qo=Math.max,Al=Math.round;function R3(e){const t=Cn(e);let n=parseFloat(t.width),r=parseFloat(t.height);const i=e.offsetWidth,o=e.offsetHeight,a=Al(n)!==i||Al(r)!==o;return a&&(n=i,r=o),{width:n,height:r,fallback:a}}function wr(e){return z3(e)?(e.nodeName||"").toLowerCase():""}var Ba;function F3(){if(Ba)return Ba;const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?(Ba=e.brands.map(t=>t.brand+"/"+t.version).join(" "),Ba):navigator.userAgent}function Nn(e){return e instanceof Gt(e).HTMLElement}function mn(e){return e instanceof Gt(e).Element}function z3(e){return e instanceof Gt(e).Node}function w5(e){return typeof ShadowRoot>"u"?!1:e instanceof Gt(e).ShadowRoot||e instanceof ShadowRoot}function Hc(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Cn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function Vx(e){return["table","td","th"].includes(wr(e))}function S0(e){const t=/firefox/i.test(F3()),n=Cn(e),r=n.backdropFilter||n.WebkitBackdropFilter;return n.transform!=="none"||n.perspective!=="none"||!!r&&r!=="none"||t&&n.willChange==="filter"||t&&!!n.filter&&n.filter!=="none"||["transform","perspective"].some(i=>n.willChange.includes(i))||["paint","layout","strict","content"].some(i=>{const o=n.contain;return o!=null&&o.includes(i)})}function O0(){return/^((?!chrome|android).)*safari/i.test(F3())}function n1(e){return["html","body","#document"].includes(wr(e))}function j3(e){return mn(e)?e:e.contextElement}var V3={x:1,y:1};function Ti(e){const t=j3(e);if(!Nn(t))return V3;const n=t.getBoundingClientRect(),{width:r,height:i,fallback:o}=R3(t);let a=(o?Al(n.width):n.width)/r,s=(o?Al(n.height):n.height)/i;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}function Kr(e,t,n,r){var i,o;t===void 0&&(t=!1),n===void 0&&(n=!1);const a=e.getBoundingClientRect(),s=j3(e);let c=V3;t&&(r?mn(r)&&(c=Ti(r)):c=Ti(e));const l=s?Gt(s):window,u=O0()&&n;let d=(a.left+(u&&((i=l.visualViewport)==null?void 0:i.offsetLeft)||0))/c.x,f=(a.top+(u&&((o=l.visualViewport)==null?void 0:o.offsetTop)||0))/c.y,h=a.width/c.x,p=a.height/c.y;if(s){const m=Gt(s),v=r&&mn(r)?Gt(r):r;let b=m.frameElement;for(;b&&r&&v!==m;){const y=Ti(b),g=b.getBoundingClientRect(),_=getComputedStyle(b);g.x+=(b.clientLeft+parseFloat(_.paddingLeft))*y.x,g.y+=(b.clientTop+parseFloat(_.paddingTop))*y.y,d*=y.x,f*=y.y,h*=y.x,p*=y.y,d+=g.x,f+=g.y,b=Gt(b).frameElement}}return{width:h,height:p,top:f,right:d+h,bottom:f+p,left:d,x:d,y:f}}function dr(e){return((z3(e)?e.ownerDocument:e.document)||window.document).documentElement}function qc(e){return mn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function U3(e){return Kr(dr(e)).left+qc(e).scrollLeft}function sa(e){if(wr(e)==="html")return e;const t=e.assignedSlot||e.parentNode||w5(e)&&e.host||dr(e);return w5(t)?t.host:t}function B3(e){const t=sa(e);return n1(t)?t.ownerDocument.body:Nn(t)&&Hc(t)?t:B3(t)}function Wo(e,t){var n;t===void 0&&(t=[]);const r=B3(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=Gt(r);return i?t.concat(o,o.visualViewport||[],Hc(r)?r:[]):t.concat(r,Wo(r))}function _5(e,t,n){let r;if(t==="viewport")r=function(a,s){const c=Gt(a),l=dr(a),u=c.visualViewport;let d=l.clientWidth,f=l.clientHeight,h=0,p=0;if(u){d=u.width,f=u.height;const m=O0();(!m||m&&s==="fixed")&&(h=u.offsetLeft,p=u.offsetTop)}return{width:d,height:f,x:h,y:p}}(e,n);else if(t==="document")r=function(a){const s=dr(a),c=qc(a),l=a.ownerDocument.body,u=qo(s.scrollWidth,s.clientWidth,l.scrollWidth,l.clientWidth),d=qo(s.scrollHeight,s.clientHeight,l.scrollHeight,l.clientHeight);let f=-c.scrollLeft+U3(a);const h=-c.scrollTop;return Cn(l).direction==="rtl"&&(f+=qo(s.clientWidth,l.clientWidth)-u),{width:u,height:d,x:f,y:h}}(dr(e));else if(mn(t))r=function(a,s){const c=Kr(a,!0,s==="fixed"),l=c.top+a.clientTop,u=c.left+a.clientLeft,d=Nn(a)?Ti(a):{x:1,y:1};return{width:a.clientWidth*d.x,height:a.clientHeight*d.y,x:u*d.x,y:l*d.y}}(t,n);else{const a=je({},t);if(O0()){var i,o;const s=Gt(e);a.x-=((i=s.visualViewport)==null?void 0:i.offsetLeft)||0,a.y-=((o=s.visualViewport)==null?void 0:o.offsetTop)||0}r=a}return x0(r)}function x5(e,t){return Nn(e)&&Cn(e).position!=="fixed"?t?t(e):e.offsetParent:null}function k5(e,t){const n=Gt(e);let r=x5(e,t);for(;r&&Vx(r)&&Cn(r).position==="static";)r=x5(r,t);return r&&(wr(r)==="html"||wr(r)==="body"&&Cn(r).position==="static"&&!S0(r))?n:r||function(i){let o=sa(i);for(;Nn(o)&&!n1(o);){if(S0(o))return o;o=sa(o)}return null}(e)||n}function Ux(e,t,n){const r=Nn(t),i=dr(t),o=Kr(e,!0,n==="fixed",t);let a={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if(r||!r&&n!=="fixed")if((wr(t)!=="body"||Hc(i))&&(a=qc(t)),Nn(t)){const c=Kr(t,!0);s.x=c.x+t.clientLeft,s.y=c.y+t.clientTop}else i&&(s.x=U3(i));return{x:o.left+a.scrollLeft-s.x,y:o.top+a.scrollTop-s.y,width:o.width,height:o.height}}var vs={getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o=n==="clippingAncestors"?function(l,u){const d=u.get(l);if(d)return d;let f=Wo(l).filter(v=>mn(v)&&wr(v)!=="body"),h=null;const p=Cn(l).position==="fixed";let m=p?sa(l):l;for(;mn(m)&&!n1(m);){const v=Cn(m),b=S0(m);v.position==="fixed"?h=null:(p?b||h:b||v.position!=="static"||!h||!["absolute","fixed"].includes(h.position))?h=v:f=f.filter(y=>y!==m),m=sa(m)}return u.set(l,f),f}(t,this._c):[].concat(n),a=[...o,r],s=a[0],c=a.reduce((l,u)=>{const d=_5(t,u,i);return l.top=qo(d.top,l.top),l.right=$5(d.right,l.right),l.bottom=$5(d.bottom,l.bottom),l.left=qo(d.left,l.left),l},_5(t,s,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}},convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{rect:t,offsetParent:n,strategy:r}=e;const i=Nn(n),o=dr(n);if(n===o)return t;let a={scrollLeft:0,scrollTop:0},s={x:1,y:1};const c={x:0,y:0};if((i||!i&&r!=="fixed")&&((wr(n)!=="body"||Hc(o))&&(a=qc(n)),Nn(n))){const l=Kr(n);s=Ti(n),c.x=l.x+n.clientLeft,c.y=l.y+n.clientTop}return{width:t.width*s.x,height:t.height*s.y,x:t.x*s.x-a.scrollLeft*s.x+c.x,y:t.y*s.y-a.scrollTop*s.y+c.y}},isElement:mn,getDimensions:function(e){return Nn(e)?R3(e):e.getBoundingClientRect()},getOffsetParent:k5,getDocumentElement:dr,getScale:Ti,async getElementRects(e){let{reference:t,floating:n,strategy:r}=e;const i=this.getOffsetParent||k5,o=this.getDimensions;return{reference:Ux(t,await i(n),r),floating:je({x:0,y:0},await o(n))}},getClientRects:e=>Array.from(e.getClientRects()),isRTL:e=>Cn(e).direction==="rtl"};function Bx(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a=!0,animationFrame:s=!1}=r,c=i&&!s,l=c||o?[...mn(e)?Wo(e):e.contextElement?Wo(e.contextElement):[],...Wo(t)]:[];l.forEach(h=>{c&&h.addEventListener("scroll",n,{passive:!0}),o&&h.addEventListener("resize",n)});let u,d=null;if(a){let h=!0;d=new ResizeObserver(()=>{h||n(),h=!1}),mn(e)&&!s&&d.observe(e),mn(e)||!e.contextElement||s||d.observe(e.contextElement),d.observe(t)}let f=s?Kr(e):null;return s&&function h(){const p=Kr(e);!f||p.x===f.x&&p.y===f.y&&p.width===f.width&&p.height===f.height||n(),f=p,u=requestAnimationFrame(h)}(),n(),()=>{var h;l.forEach(p=>{c&&p.removeEventListener("scroll",n),o&&p.removeEventListener("resize",n)}),(h=d)==null||h.disconnect(),d=null,s&&cancelAnimationFrame(u)}}var Hx=(e,t,n)=>{const r=new Map,i=je({platform:vs},n),o=Ft(je({},i.platform),{_c:r});return Px(e,t,Ft(je({},i),{platform:o}))};function qx(e){return Wx(e)}function Qu(e){return e.assignedSlot?e.assignedSlot:e.parentNode instanceof ShadowRoot?e.parentNode.host:e.parentNode}function Wx(e){for(let t=e;t;t=Qu(t))if(t instanceof Element&&getComputedStyle(t).display==="none")return null;for(let t=Qu(e);t;t=Qu(t)){if(!(t instanceof Element))continue;const n=getComputedStyle(t);if(n.display!=="contents"&&(n.position!=="static"||n.filter!=="none"||t.tagName==="BODY"))return t}return null}var Fe=class extends xt{constructor(){super(...arguments),this.active=!1,this.placement="top",this.strategy="absolute",this.distance=0,this.skidding=0,this.arrow=!1,this.arrowPlacement="anchor",this.arrowPadding=10,this.flip=!1,this.flipFallbackPlacements="",this.flipFallbackStrategy="best-fit",this.flipPadding=0,this.shift=!1,this.shiftPadding=0,this.autoSizePadding=0}async connectedCallback(){super.connectedCallback(),await this.updateComplete,this.start()}disconnectedCallback(){this.stop()}async updated(e){super.updated(e),e.has("active")&&(this.active?this.start():this.stop()),e.has("anchor")&&this.handleAnchorChange(),this.active&&(await this.updateComplete,this.reposition())}async handleAnchorChange(){if(await this.stop(),this.anchor&&typeof this.anchor=="string"){const e=this.getRootNode();this.anchorEl=e.getElementById(this.anchor)}else this.anchor instanceof Element?this.anchorEl=this.anchor:this.anchorEl=this.querySelector('[slot="anchor"]');if(this.anchorEl instanceof HTMLSlotElement&&(this.anchorEl=this.anchorEl.assignedElements({flatten:!0})[0]),!this.anchorEl)throw new Error("Invalid anchor element: no anchor could be found using the anchor slot or the anchor attribute.");this.start()}start(){!this.anchorEl||(this.cleanup=Bx(this.anchorEl,this.popup,()=>{this.reposition()}))}async stop(){return new Promise(e=>{this.cleanup?(this.cleanup(),this.cleanup=void 0,this.removeAttribute("data-current-placement"),this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height"),requestAnimationFrame(()=>e())):e()})}reposition(){if(!this.active||!this.anchorEl)return;const e=[Fx({mainAxis:this.distance,crossAxis:this.skidding})];this.sync?e.push(b5({apply:({rects:n})=>{const r=this.sync==="width"||this.sync==="both",i=this.sync==="height"||this.sync==="both";this.popup.style.width=r?`${n.reference.width}px`:"",this.popup.style.height=i?`${n.reference.height}px`:""}})):(this.popup.style.width="",this.popup.style.height=""),this.flip&&e.push(Rx({boundary:this.flipBoundary,fallbackPlacements:this.flipFallbackPlacements,fallbackStrategy:this.flipFallbackStrategy==="best-fit"?"bestFit":"initialPlacement",padding:this.flipPadding})),this.shift&&e.push(jx({boundary:this.shiftBoundary,padding:this.shiftPadding})),this.autoSize?e.push(b5({boundary:this.autoSizeBoundary,padding:this.autoSizePadding,apply:({availableWidth:n,availableHeight:r})=>{this.autoSize==="vertical"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-height",`${r}px`):this.style.removeProperty("--auto-size-available-height"),this.autoSize==="horizontal"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-width",`${n}px`):this.style.removeProperty("--auto-size-available-width")}})):(this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height")),this.arrow&&e.push(Ax({element:this.arrowEl,padding:this.arrowPadding}));const t=this.strategy==="absolute"?n=>vs.getOffsetParent(n,qx):vs.getOffsetParent;Hx(this.anchorEl,this.popup,{placement:this.placement,middleware:e,strategy:this.strategy,platform:Ft(je({},vs),{getOffsetParent:t})}).then(({x:n,y:r,middlewareData:i,placement:o})=>{const a=getComputedStyle(this).direction==="rtl",s={top:"bottom",right:"left",bottom:"top",left:"right"}[o.split("-")[0]];if(this.setAttribute("data-current-placement",o),Object.assign(this.popup.style,{left:`${n}px`,top:`${r}px`}),this.arrow){const c=i.arrow.x,l=i.arrow.y;let u="",d="",f="",h="";if(this.arrowPlacement==="start"){const p=typeof c=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";u=typeof l=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"",d=a?p:"",h=a?"":p}else if(this.arrowPlacement==="end"){const p=typeof c=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";d=a?"":p,h=a?p:"",f=typeof l=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:""}else this.arrowPlacement==="center"?(h=typeof c=="number"?"calc(50% - var(--arrow-size-diagonal))":"",u=typeof l=="number"?"calc(50% - var(--arrow-size-diagonal))":""):(h=typeof c=="number"?`${c}px`:"",u=typeof l=="number"?`${l}px`:"");Object.assign(this.arrowEl.style,{top:u,right:d,bottom:f,left:h,[s]:"calc(var(--arrow-size-diagonal) * -1)"})}}),this.emit("sl-reposition")}render(){return We`
|
|
1010
|
+
`;function oo(e){return e.split("-")[1]}function e1(e){return e==="y"?"height":"width"}function ur(e){return e.split("-")[0]}function ao(e){return["top","bottom"].includes(ur(e))?"x":"y"}function y5(e,t,n){let{reference:r,floating:i}=e;const o=r.x+r.width/2-i.width/2,a=r.y+r.height/2-i.height/2,s=ao(t),c=e1(s),l=r[c]/2-i[c]/2,u=s==="x";let d;switch(ur(t)){case"top":d={x:o,y:r.y-i.height};break;case"bottom":d={x:o,y:r.y+r.height};break;case"right":d={x:r.x+r.width,y:a};break;case"left":d={x:r.x-i.width,y:a};break;default:d={x:r.x,y:r.y}}switch(oo(t)){case"start":d[s]-=l*(n&&u?-1:1);break;case"end":d[s]+=l*(n&&u?-1:1)}return d}var Px=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:a}=n,s=o.filter(Boolean),c=await(a.isRTL==null?void 0:a.isRTL(t));let l=await a.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=y5(l,r,c),f=r,h={},p=0;for(let m=0;m<s.length;m++){const{name:v,fn:b}=s[m],{x:y,y:g,data:_,reset:k}=await b({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:h,rects:l,platform:a,elements:{reference:e,floating:t}});u=y??u,d=g??d,h=Ft(je({},h),{[v]:je(je({},h[v]),_)}),k&&p<=50&&(p++,typeof k=="object"&&(k.placement&&(f=k.placement),k.rects&&(l=k.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:i}):k.rects),{x:u,y:d}=y5(l,f,c)),m=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:h}};function L3(e){return typeof e!="number"?function(t){return je({top:0,right:0,bottom:0,left:0},t)}(e):{top:e,right:e,bottom:e,left:e}}function x0(e){return Ft(je({},e),{top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height})}async function t1(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:o,rects:a,elements:s,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:f=!1,padding:h=0}=t,p=L3(h),m=s[f?d==="floating"?"reference":"floating":d],v=x0(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(m)))==null||n?m:m.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(s.floating)),boundary:l,rootBoundary:u,strategy:c})),b=d==="floating"?Ft(je({},a.floating),{x:r,y:i}):a.reference,y=await(o.getOffsetParent==null?void 0:o.getOffsetParent(s.floating)),g=await(o.isElement==null?void 0:o.isElement(y))&&await(o.getScale==null?void 0:o.getScale(y))||{x:1,y:1},_=x0(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({rect:b,offsetParent:y,strategy:c}):b);return{top:(v.top-_.top+p.top)/g.y,bottom:(_.bottom-v.bottom+p.bottom)/g.y,left:(v.left-_.left+p.left)/g.x,right:(_.right-v.right+p.right)/g.x}}var k0=Math.min,Tr=Math.max;function E0(e,t,n){return Tr(e,k0(t,n))}var Ax=e=>({name:"arrow",options:e,async fn(t){const{element:n,padding:r=0}=e||{},{x:i,y:o,placement:a,rects:s,platform:c}=t;if(n==null)return{};const l=L3(r),u={x:i,y:o},d=ao(a),f=e1(d),h=await c.getDimensions(n),p=d==="y"?"top":"left",m=d==="y"?"bottom":"right",v=s.reference[f]+s.reference[d]-u[d]-s.floating[f],b=u[d]-s.reference[d],y=await(c.getOffsetParent==null?void 0:c.getOffsetParent(n));let g=y?d==="y"?y.clientHeight||0:y.clientWidth||0:0;g===0&&(g=s.floating[f]);const _=v/2-b/2,k=l[p],O=g-h[f]-l[m],C=g/2-h[f]/2+_,M=E0(k,C,O),D=oo(a)!=null&&C!=M&&s.reference[f]/2-(C<k?l[p]:l[m])-h[f]/2<0;return{[d]:u[d]-(D?C<k?k-C:O-C:0),data:{[d]:M,centerOffset:C-M}}}}),Ix=["top","right","bottom","left"];Ix.reduce((e,t)=>e.concat(t,t+"-start",t+"-end"),[]);var Mx={left:"right",right:"left",bottom:"top",top:"bottom"};function Pl(e){return e.replace(/left|right|bottom|top/g,t=>Mx[t])}function Dx(e,t,n){n===void 0&&(n=!1);const r=oo(e),i=ao(e),o=e1(i);let a=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=Pl(a)),{main:a,cross:Pl(a)}}var Lx={start:"end",end:"start"};function Ku(e){return e.replace(/start|end/g,t=>Lx[t])}var Rx=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:i,rects:o,initialPlacement:a,platform:s,elements:c}=t,l=e,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:m=!0}=l,v=Jh(l,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]),b=ur(r),y=ur(a)===a,g=await(s.isRTL==null?void 0:s.isRTL(c.floating)),_=f||(y||!m?[Pl(a)]:function(J){const G=Pl(J);return[Ku(J),G,Ku(G)]}(a));f||p==="none"||_.push(...function(J,G,j,z){const Q=oo(J);let I=function(U,W,de){const be=["left","right"],P=["right","left"],B=["top","bottom"],Ce=["bottom","top"];switch(U){case"top":case"bottom":return de?W?P:be:W?be:P;case"left":case"right":return W?B:Ce;default:return[]}}(ur(J),j==="start",z);return Q&&(I=I.map(U=>U+"-"+Q),G&&(I=I.concat(I.map(Ku)))),I}(a,m,p,g));const k=[a,..._],O=await t1(t,v),C=[];let M=((n=i.flip)==null?void 0:n.overflows)||[];if(u&&C.push(O[b]),d){const{main:J,cross:G}=Dx(r,o,g);C.push(O[J],O[G])}if(M=[...M,{placement:r,overflows:C}],!C.every(J=>J<=0)){var D,F;const J=(((D=i.flip)==null?void 0:D.index)||0)+1,G=k[J];if(G)return{data:{index:J,overflows:M},reset:{placement:G}};let j=(F=M.filter(z=>z.overflows[0]<=0).sort((z,Q)=>z.overflows[1]-Q.overflows[1])[0])==null?void 0:F.placement;if(!j)switch(h){case"bestFit":{var Y;const z=(Y=M.map(Q=>[Q.placement,Q.overflows.filter(I=>I>0).reduce((I,U)=>I+U,0)]).sort((Q,I)=>Q[1]-I[1])[0])==null?void 0:Y[0];z&&(j=z);break}case"initialPlacement":j=a}if(r!==j)return{reset:{placement:j}}}return{}}}},Fx=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,i=await async function(o,a){const{placement:s,platform:c,elements:l}=o,u=await(c.isRTL==null?void 0:c.isRTL(l.floating)),d=ur(s),f=oo(s),h=ao(s)==="x",p=["left","top"].includes(d)?-1:1,m=u&&h?-1:1,v=typeof a=="function"?a(o):a;let{mainAxis:b,crossAxis:y,alignmentAxis:g}=typeof v=="number"?{mainAxis:v,crossAxis:0,alignmentAxis:null}:je({mainAxis:0,crossAxis:0,alignmentAxis:null},v);return f&&typeof g=="number"&&(y=f==="end"?-1*g:g),h?{x:y*m,y:b*p}:{x:b*p,y:y*m}}(t,e);return{x:n+i.x,y:r+i.y,data:i}}}};function zx(e){return e==="x"?"y":"x"}var jx=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,o=e,{mainAxis:a=!0,crossAxis:s=!1,limiter:c={fn:b=>{let{x:y,y:g}=b;return{x:y,y:g}}}}=o,l=Jh(o,["mainAxis","crossAxis","limiter"]),u={x:n,y:r},d=await t1(t,l),f=ao(ur(i)),h=zx(f);let p=u[f],m=u[h];if(a){const b=f==="y"?"bottom":"right";p=E0(p+d[f==="y"?"top":"left"],p,p-d[b])}if(s){const b=h==="y"?"bottom":"right";m=E0(m+d[h==="y"?"top":"left"],m,m-d[b])}const v=c.fn(Ft(je({},t),{[f]:p,[h]:m}));return Ft(je({},v),{data:{x:v.x-n,y:v.y-r}})}}},b5=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:i,elements:o}=t,a=e,{apply:s=()=>{}}=a,c=Jh(a,["apply"]),l=await t1(t,c),u=ur(n),d=oo(n),f=ao(n)==="x",{width:h,height:p}=r.floating;let m,v;u==="top"||u==="bottom"?(m=u,v=d===(await(i.isRTL==null?void 0:i.isRTL(o.floating))?"start":"end")?"left":"right"):(v=u,m=d==="end"?"top":"bottom");const b=p-l[m],y=h-l[v];let g=b,_=y;if(f?_=k0(h-l.right-l.left,y):g=k0(p-l.bottom-l.top,b),!t.middlewareData.shift&&!d){const O=Tr(l.left,0),C=Tr(l.right,0),M=Tr(l.top,0),D=Tr(l.bottom,0);f?_=h-2*(O!==0||C!==0?O+C:Tr(l.left,l.right)):g=p-2*(M!==0||D!==0?M+D:Tr(l.top,l.bottom))}await s(Ft(je({},t),{availableWidth:_,availableHeight:g}));const k=await i.getDimensions(o.floating);return h!==k.width||p!==k.height?{reset:{rects:!0}}:{}}}};function Gt(e){var t;return((t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Cn(e){return Gt(e).getComputedStyle(e)}var $5=Math.min,qo=Math.max,Al=Math.round;function R3(e){const t=Cn(e);let n=parseFloat(t.width),r=parseFloat(t.height);const i=e.offsetWidth,o=e.offsetHeight,a=Al(n)!==i||Al(r)!==o;return a&&(n=i,r=o),{width:n,height:r,fallback:a}}function wr(e){return z3(e)?(e.nodeName||"").toLowerCase():""}var Ba;function F3(){if(Ba)return Ba;const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?(Ba=e.brands.map(t=>t.brand+"/"+t.version).join(" "),Ba):navigator.userAgent}function Nn(e){return e instanceof Gt(e).HTMLElement}function mn(e){return e instanceof Gt(e).Element}function z3(e){return e instanceof Gt(e).Node}function w5(e){return typeof ShadowRoot>"u"?!1:e instanceof Gt(e).ShadowRoot||e instanceof ShadowRoot}function Hc(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Cn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function Vx(e){return["table","td","th"].includes(wr(e))}function S0(e){const t=/firefox/i.test(F3()),n=Cn(e),r=n.backdropFilter||n.WebkitBackdropFilter;return n.transform!=="none"||n.perspective!=="none"||!!r&&r!=="none"||t&&n.willChange==="filter"||t&&!!n.filter&&n.filter!=="none"||["transform","perspective"].some(i=>n.willChange.includes(i))||["paint","layout","strict","content"].some(i=>{const o=n.contain;return o!=null&&o.includes(i)})}function O0(){return/^((?!chrome|android).)*safari/i.test(F3())}function n1(e){return["html","body","#document"].includes(wr(e))}function j3(e){return mn(e)?e:e.contextElement}var V3={x:1,y:1};function Ti(e){const t=j3(e);if(!Nn(t))return V3;const n=t.getBoundingClientRect(),{width:r,height:i,fallback:o}=R3(t);let a=(o?Al(n.width):n.width)/r,s=(o?Al(n.height):n.height)/i;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}function Kr(e,t,n,r){var i,o;t===void 0&&(t=!1),n===void 0&&(n=!1);const a=e.getBoundingClientRect(),s=j3(e);let c=V3;t&&(r?mn(r)&&(c=Ti(r)):c=Ti(e));const l=s?Gt(s):window,u=O0()&&n;let d=(a.left+(u&&((i=l.visualViewport)==null?void 0:i.offsetLeft)||0))/c.x,f=(a.top+(u&&((o=l.visualViewport)==null?void 0:o.offsetTop)||0))/c.y,h=a.width/c.x,p=a.height/c.y;if(s){const m=Gt(s),v=r&&mn(r)?Gt(r):r;let b=m.frameElement;for(;b&&r&&v!==m;){const y=Ti(b),g=b.getBoundingClientRect(),_=getComputedStyle(b);g.x+=(b.clientLeft+parseFloat(_.paddingLeft))*y.x,g.y+=(b.clientTop+parseFloat(_.paddingTop))*y.y,d*=y.x,f*=y.y,h*=y.x,p*=y.y,d+=g.x,f+=g.y,b=Gt(b).frameElement}}return{width:h,height:p,top:f,right:d+h,bottom:f+p,left:d,x:d,y:f}}function dr(e){return((z3(e)?e.ownerDocument:e.document)||window.document).documentElement}function qc(e){return mn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function U3(e){return Kr(dr(e)).left+qc(e).scrollLeft}function sa(e){if(wr(e)==="html")return e;const t=e.assignedSlot||e.parentNode||w5(e)&&e.host||dr(e);return w5(t)?t.host:t}function B3(e){const t=sa(e);return n1(t)?t.ownerDocument.body:Nn(t)&&Hc(t)?t:B3(t)}function Wo(e,t){var n;t===void 0&&(t=[]);const r=B3(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=Gt(r);return i?t.concat(o,o.visualViewport||[],Hc(r)?r:[]):t.concat(r,Wo(r))}function _5(e,t,n){let r;if(t==="viewport")r=function(a,s){const c=Gt(a),l=dr(a),u=c.visualViewport;let d=l.clientWidth,f=l.clientHeight,h=0,p=0;if(u){d=u.width,f=u.height;const m=O0();(!m||m&&s==="fixed")&&(h=u.offsetLeft,p=u.offsetTop)}return{width:d,height:f,x:h,y:p}}(e,n);else if(t==="document")r=function(a){const s=dr(a),c=qc(a),l=a.ownerDocument.body,u=qo(s.scrollWidth,s.clientWidth,l.scrollWidth,l.clientWidth),d=qo(s.scrollHeight,s.clientHeight,l.scrollHeight,l.clientHeight);let f=-c.scrollLeft+U3(a);const h=-c.scrollTop;return Cn(l).direction==="rtl"&&(f+=qo(s.clientWidth,l.clientWidth)-u),{width:u,height:d,x:f,y:h}}(dr(e));else if(mn(t))r=function(a,s){const c=Kr(a,!0,s==="fixed"),l=c.top+a.clientTop,u=c.left+a.clientLeft,d=Nn(a)?Ti(a):{x:1,y:1};return{width:a.clientWidth*d.x,height:a.clientHeight*d.y,x:u*d.x,y:l*d.y}}(t,n);else{const a=je({},t);if(O0()){var i,o;const s=Gt(e);a.x-=((i=s.visualViewport)==null?void 0:i.offsetLeft)||0,a.y-=((o=s.visualViewport)==null?void 0:o.offsetTop)||0}r=a}return x0(r)}function x5(e,t){return Nn(e)&&Cn(e).position!=="fixed"?t?t(e):e.offsetParent:null}function k5(e,t){const n=Gt(e);let r=x5(e,t);for(;r&&Vx(r)&&Cn(r).position==="static";)r=x5(r,t);return r&&(wr(r)==="html"||wr(r)==="body"&&Cn(r).position==="static"&&!S0(r))?n:r||function(i){let o=sa(i);for(;Nn(o)&&!n1(o);){if(S0(o))return o;o=sa(o)}return null}(e)||n}function Ux(e,t,n){const r=Nn(t),i=dr(t),o=Kr(e,!0,n==="fixed",t);let a={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if(r||!r&&n!=="fixed")if((wr(t)!=="body"||Hc(i))&&(a=qc(t)),Nn(t)){const c=Kr(t,!0);s.x=c.x+t.clientLeft,s.y=c.y+t.clientTop}else i&&(s.x=U3(i));return{x:o.left+a.scrollLeft-s.x,y:o.top+a.scrollTop-s.y,width:o.width,height:o.height}}var vs={getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o=n==="clippingAncestors"?function(l,u){const d=u.get(l);if(d)return d;let f=Wo(l).filter(v=>mn(v)&&wr(v)!=="body"),h=null;const p=Cn(l).position==="fixed";let m=p?sa(l):l;for(;mn(m)&&!n1(m);){const v=Cn(m),b=S0(m);v.position==="fixed"?h=null:(p?b||h:b||v.position!=="static"||!h||!["absolute","fixed"].includes(h.position))?h=v:f=f.filter(y=>y!==m),m=sa(m)}return u.set(l,f),f}(t,this._c):[].concat(n),a=[...o,r],s=a[0],c=a.reduce((l,u)=>{const d=_5(t,u,i);return l.top=qo(d.top,l.top),l.right=$5(d.right,l.right),l.bottom=$5(d.bottom,l.bottom),l.left=qo(d.left,l.left),l},_5(t,s,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}},convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{rect:t,offsetParent:n,strategy:r}=e;const i=Nn(n),o=dr(n);if(n===o)return t;let a={scrollLeft:0,scrollTop:0},s={x:1,y:1};const c={x:0,y:0};if((i||!i&&r!=="fixed")&&((wr(n)!=="body"||Hc(o))&&(a=qc(n)),Nn(n))){const l=Kr(n);s=Ti(n),c.x=l.x+n.clientLeft,c.y=l.y+n.clientTop}return{width:t.width*s.x,height:t.height*s.y,x:t.x*s.x-a.scrollLeft*s.x+c.x,y:t.y*s.y-a.scrollTop*s.y+c.y}},isElement:mn,getDimensions:function(e){return Nn(e)?R3(e):e.getBoundingClientRect()},getOffsetParent:k5,getDocumentElement:dr,getScale:Ti,async getElementRects(e){let{reference:t,floating:n,strategy:r}=e;const i=this.getOffsetParent||k5,o=this.getDimensions;return{reference:Ux(t,await i(n),r),floating:je({x:0,y:0},await o(n))}},getClientRects:e=>Array.from(e.getClientRects()),isRTL:e=>Cn(e).direction==="rtl"};function Bx(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a=!0,animationFrame:s=!1}=r,c=i&&!s,l=c||o?[...mn(e)?Wo(e):e.contextElement?Wo(e.contextElement):[],...Wo(t)]:[];l.forEach(h=>{c&&h.addEventListener("scroll",n,{passive:!0}),o&&h.addEventListener("resize",n)});let u,d=null;if(a){let h=!0;d=new ResizeObserver(()=>{h||n(),h=!1}),mn(e)&&!s&&d.observe(e),mn(e)||!e.contextElement||s||d.observe(e.contextElement),d.observe(t)}let f=s?Kr(e):null;return s&&function h(){const p=Kr(e);!f||p.x===f.x&&p.y===f.y&&p.width===f.width&&p.height===f.height||n(),f=p,u=requestAnimationFrame(h)}(),n(),()=>{var h;l.forEach(p=>{c&&p.removeEventListener("scroll",n),o&&p.removeEventListener("resize",n)}),(h=d)==null||h.disconnect(),d=null,s&&cancelAnimationFrame(u)}}var Hx=(e,t,n)=>{const r=new Map,i=je({platform:vs},n),o=Ft(je({},i.platform),{_c:r});return Px(e,t,Ft(je({},i),{platform:o}))};function qx(e){return Wx(e)}function Qu(e){return e.assignedSlot?e.assignedSlot:e.parentNode instanceof ShadowRoot?e.parentNode.host:e.parentNode}function Wx(e){for(let t=e;t;t=Qu(t))if(t instanceof Element&&getComputedStyle(t).display==="none")return null;for(let t=Qu(e);t;t=Qu(t)){if(!(t instanceof Element))continue;const n=getComputedStyle(t);if(n.display!=="contents"&&(n.position!=="static"||n.filter!=="none"||t.tagName==="BODY"))return t}return null}var Fe=class extends xt{constructor(){super(...arguments),this.active=!1,this.placement="top",this.strategy="absolute",this.distance=0,this.skidding=0,this.arrow=!1,this.arrowPlacement="anchor",this.arrowPadding=10,this.flip=!1,this.flipFallbackPlacements="",this.flipFallbackStrategy="best-fit",this.flipPadding=0,this.shift=!1,this.shiftPadding=0,this.autoSizePadding=0}async connectedCallback(){super.connectedCallback(),await this.updateComplete,this.start()}disconnectedCallback(){this.stop()}async updated(e){super.updated(e),e.has("active")&&(this.active?this.start():this.stop()),e.has("anchor")&&this.handleAnchorChange(),this.active&&(await this.updateComplete,this.reposition())}async handleAnchorChange(){if(await this.stop(),this.anchor&&typeof this.anchor=="string"){const e=this.getRootNode();this.anchorEl=e.getElementById(this.anchor)}else this.anchor instanceof Element?this.anchorEl=this.anchor:this.anchorEl=this.querySelector('[slot="anchor"]');if(this.anchorEl instanceof HTMLSlotElement&&(this.anchorEl=this.anchorEl.assignedElements({flatten:!0})[0]),!this.anchorEl)throw new Error("Invalid anchor element: no anchor could be found using the anchor slot or the anchor attribute.");this.start()}start(){!this.anchorEl||(this.cleanup=Bx(this.anchorEl,this.popup,()=>{this.reposition()}))}async stop(){return new Promise(e=>{this.cleanup?(this.cleanup(),this.cleanup=void 0,this.removeAttribute("data-current-placement"),this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height"),requestAnimationFrame(()=>e())):e()})}reposition(){if(!this.active||!this.anchorEl)return;const e=[Fx({mainAxis:this.distance,crossAxis:this.skidding})];this.sync?e.push(b5({apply:({rects:n})=>{const r=this.sync==="width"||this.sync==="both",i=this.sync==="height"||this.sync==="both";this.popup.style.width=r?`${n.reference.width}px`:"",this.popup.style.height=i?`${n.reference.height}px`:""}})):(this.popup.style.width="",this.popup.style.height=""),this.flip&&e.push(Rx({boundary:this.flipBoundary,fallbackPlacements:this.flipFallbackPlacements,fallbackStrategy:this.flipFallbackStrategy==="best-fit"?"bestFit":"initialPlacement",padding:this.flipPadding})),this.shift&&e.push(jx({boundary:this.shiftBoundary,padding:this.shiftPadding})),this.autoSize?e.push(b5({boundary:this.autoSizeBoundary,padding:this.autoSizePadding,apply:({availableWidth:n,availableHeight:r})=>{this.autoSize==="vertical"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-height",`${r}px`):this.style.removeProperty("--auto-size-available-height"),this.autoSize==="horizontal"||this.autoSize==="both"?this.style.setProperty("--auto-size-available-width",`${n}px`):this.style.removeProperty("--auto-size-available-width")}})):(this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height")),this.arrow&&e.push(Ax({element:this.arrowEl,padding:this.arrowPadding}));const t=this.strategy==="absolute"?n=>vs.getOffsetParent(n,qx):vs.getOffsetParent;Hx(this.anchorEl,this.popup,{placement:this.placement,middleware:e,strategy:this.strategy,platform:Ft(je({},vs),{getOffsetParent:t})}).then(({x:n,y:r,middlewareData:i,placement:o})=>{const a=getComputedStyle(this).direction==="rtl",s={top:"bottom",right:"left",bottom:"top",left:"right"}[o.split("-")[0]];if(this.setAttribute("data-current-placement",o),Object.assign(this.popup.style,{left:`${n}px`,top:`${r}px`}),this.arrow){const c=i.arrow.x,l=i.arrow.y;let u="",d="",f="",h="";if(this.arrowPlacement==="start"){const p=typeof c=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";u=typeof l=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"",d=a?p:"",h=a?"":p}else if(this.arrowPlacement==="end"){const p=typeof c=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";d=a?"":p,h=a?p:"",f=typeof l=="number"?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:""}else this.arrowPlacement==="center"?(h=typeof c=="number"?"calc(50% - var(--arrow-size-diagonal))":"",u=typeof l=="number"?"calc(50% - var(--arrow-size-diagonal))":""):(h=typeof c=="number"?`${c}px`:"",u=typeof l=="number"?`${l}px`:"");Object.assign(this.arrowEl.style,{top:u,right:d,bottom:f,left:h,[s]:"calc(var(--arrow-size-diagonal) * -1)"})}}),this.emit("sl-reposition")}render(){return We`
|
|
1011
1011
|
<slot name="anchor" @slotchange=${this.handleAnchorChange}></slot>
|
|
1012
1012
|
|
|
1013
1013
|
<div
|
|
@@ -1819,7 +1819,7 @@ lit-html/directives/if-defined.js:
|
|
|
1819
1819
|
*/var dk=["bottom","height","left","right","top","width"],fk=function(t,n){return t===void 0&&(t={}),n===void 0&&(n={}),dk.some(function(r){return t[r]!==n[r]})},tr=new Map,q3,hk=function e(){var t=[];tr.forEach(function(n,r){var i=r.getBoundingClientRect();fk(i,n.rect)&&(n.rect=i,t.push(n))}),t.forEach(function(n){n.callbacks.forEach(function(r){return r(n.rect)})}),q3=window.requestAnimationFrame(e)};function pk(e,t){return{observe:function(){var r=tr.size===0;tr.has(e)?tr.get(e).callbacks.push(t):tr.set(e,{rect:void 0,hasRectChanged:!1,callbacks:[t]}),r&&hk()},unobserve:function(){var r=tr.get(e);if(r){var i=r.callbacks.indexOf(t);i>=0&&r.callbacks.splice(i,1),r.callbacks.length||tr.delete(e),tr.size||cancelAnimationFrame(q3)}}}}function Wa(e,t,n){let r=[],i;return()=>{let o;n.key&&n.debug!=null&&n.debug()&&(o=Date.now());const a=e();if(!(a.length!==r.length||a.some((l,u)=>r[u]!==l)))return i;r=a;let c;if(n.key&&n.debug!=null&&n.debug()&&(c=Date.now()),i=t(...a),n==null||n.onChange==null||n.onChange(i),n.key&&n.debug!=null&&n.debug()){const l=Math.round((Date.now()-o)*100)/100,u=Math.round((Date.now()-c)*100)/100,d=u/16,f=(h,p)=>{for(h=String(h);h.length<p;)h=" "+h;return h};console.info("%c\u23F1 "+f(u,5)+" /"+f(l,5)+" ms",`
|
|
1820
1820
|
font-size: .6rem;
|
|
1821
1821
|
font-weight: bold;
|
|
1822
|
-
color: hsl(`+Math.max(0,Math.min(120-120*d,120))+"deg 100% 31%);",n?.key)}return i}}const mk=e=>e,vk=e=>{const t=Math.max(e.startIndex-e.overscan,0),n=Math.min(e.endIndex+e.overscan,e.count-1),r=[];for(let i=t;i<=n;i++)r.push(i);return r},gk=(e,t)=>{const n=pk(e.scrollElement,r=>{t(r)});if(!!e.scrollElement)return t(e.scrollElement.getBoundingClientRect()),n.observe(),()=>{n.unobserve()}},yk=(e,t)=>{const n=()=>t(e.scrollElement[e.options.horizontal?"scrollLeft":"scrollTop"]);if(!!e.scrollElement)return n(),e.scrollElement.addEventListener("scroll",n,{capture:!1,passive:!0}),()=>{e.scrollElement.removeEventListener("scroll",n)}},bk=(e,t)=>e.getBoundingClientRect()[t.options.horizontal?"width":"height"],$k=(e,t,n)=>{var r;(r=n.scrollElement)==null||r.scrollTo({[n.options.horizontal?"left":"top"]:e,behavior:t?"smooth":void 0})};class wk{constructor(t){var n=this;this.unsubs=[],this.scrollElement=null,this.measurementsCache=[],this.itemMeasurementsCache={},this.pendingMeasuredCacheIndexes=[],this.measureElementCache={},this.setOptions=r=>{Object.entries(r).forEach(i=>{let[o,a]=i;typeof a>"u"&&delete r[o]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:mk,rangeExtractor:vk,enableSmoothScroll:!0,onChange:()=>{},measureElement:bk,initialRect:{width:0,height:0},...r}},this.notify=()=>{var r,i;(r=(i=this.options).onChange)==null||r.call(i,this)},this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(r=>r()),this.unsubs=[]},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{const r=this.options.getScrollElement();this.scrollElement!==r&&(this.cleanup(),this.scrollElement=r,this.unsubs.push(this.options.observeElementRect(this,i=>{this.scrollRect=i,this.notify()})),this.unsubs.push(this.options.observeElementOffset(this,i=>{this.scrollOffset=i,this.notify()})))},this.getSize=()=>this.scrollRect[this.options.horizontal?"width":"height"],this.getMeasurements=Wa(()=>[this.options.count,this.options.paddingStart,this.options.getItemKey,this.itemMeasurementsCache],(r,i,o,a)=>{const s=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];const c=this.measurementsCache.slice(0,s);for(let l=s;l<r;l++){const u=o(l),d=a[u],f=c[l-1]?c[l-1].end:i,h=typeof d=="number"?d:this.options.estimateSize(l),p=f+h;c[l]={index:l,start:f,size:h,end:p,key:u}}return this.measurementsCache=c,c},{key:!1,debug:()=>this.options.debug}),this.calculateRange=Wa(()=>[this.getMeasurements(),this.getSize(),this.scrollOffset],(r,i,o)=>xk({measurements:r,outerSize:i,scrollOffset:o}),{key:!1,debug:()=>this.options.debug}),this.getIndexes=Wa(()=>[this.options.rangeExtractor,this.calculateRange(),this.options.overscan,this.options.count],(r,i,o,a)=>r({...i,overscan:o,count:a}),{key:!1}),this.getVirtualItems=Wa(()=>[this.getIndexes(),this.getMeasurements(),this.options.measureElement],(r,i,o)=>{const a=u=>d=>{var f;const h=this.measurementsCache[u];if(!d)return;const p=o(d,this),m=(f=this.itemMeasurementsCache[h.key])!=null?f:h.size;p!==m&&(h.start<this.scrollOffset&&(this.destinationOffset||this._scrollToOffset(this.scrollOffset+(p-m),!1)),this.pendingMeasuredCacheIndexes.push(u),this.itemMeasurementsCache={...this.itemMeasurementsCache,[h.key]:p},this.notify())},s=[],c={};for(let u=0,d=r.length;u<d;u++){var l;const f=r[u],p={...i[f],measureElement:c[f]=(l=this.measureElementCache[f])!=null?l:a(f)};s.push(p)}return this.measureElementCache=c,s},{key:!1}),this.scrollToOffset=function(r,i){let{align:o}=i===void 0?{align:"start"}:i;const a=()=>{const s=n.scrollOffset,c=n.getSize();o==="auto"&&(r<=s?o="start":r>=s+c?o="end":o="start"),o==="start"?n._scrollToOffset(r,!0):o==="end"?n._scrollToOffset(r-c,!0):o==="center"&&n._scrollToOffset(r-c/2,!0)};a(),requestAnimationFrame(()=>{a()})},this.scrollToIndex=function(r,i){let{align:o,...a}=i===void 0?{align:"auto"}:i;const s=n.getMeasurements(),c=n.scrollOffset,l=n.getSize(),{count:u}=n.options,d=s[Math.max(0,Math.min(r,u-1))];if(!d)return;if(o==="auto")if(d.end>=c+l-n.options.scrollPaddingEnd)o="end";else if(d.start<=c+n.options.scrollPaddingStart)o="start";else return;const f=o==="end"?d.end+n.options.scrollPaddingEnd:d.start-n.options.scrollPaddingStart;n.scrollToOffset(f,{align:o,...a})},this.getTotalSize=()=>{var r;return(((r=this.getMeasurements()[this.options.count-1])==null?void 0:r.end)||this.options.paddingStart)+this.options.paddingEnd},this._scrollToOffset=(r,i)=>{clearTimeout(this.scrollCheckFrame),this.destinationOffset=r,this.options.scrollToFn(r,this.options.enableSmoothScroll&&i,this);let o;const a=()=>{let s=this.scrollOffset;this.scrollCheckFrame=o=setTimeout(()=>{if(this.scrollCheckFrame===o){if(this.scrollOffset===s){this.destinationOffset=void 0;return}s=this.scrollOffset,a()}},100)};a()},this.measure=()=>{this.itemMeasurementsCache={},this.notify()},this.setOptions(t),this.scrollRect=this.options.initialRect,this.scrollOffset=this.options.initialOffset}}const _k=(e,t,n,r)=>{for(;e<=t;){const i=(e+t)/2|0,o=n(i);if(o<r)e=i+1;else if(o>r)t=i-1;else return i}return e>0?e-1:0};function xk(e){let{measurements:t,outerSize:n,scrollOffset:r}=e;const i=t.length-1,a=_k(0,i,c=>t[c].start,r);let s=a;for(;s<i&&t[s].end<r+n;)s++;return{startIndex:a,endIndex:s}}function kk(e){const t=Nt(e),n=new wk(t),[r,i]=kr(n.getVirtualItems()),[o,a]=V(n.getTotalSize()),s={get(l,u){switch(u){case"getVirtualItems":return()=>r;case"getTotalSize":return()=>o();default:return Reflect.get(l,u)}}},c=new Proxy(n,s);return c.setOptions(t),ht(()=>{const l=c._didMount();c._willUpdate(),Gi(l)}),ag(()=>{c.setOptions(Nt(t,e,{onChange:l=>{l._willUpdate(),i(q_(l.getVirtualItems(),{key:"index"})),a(l.getTotalSize()),e.onChange==null||e.onChange(l)}})),c.measure()}),c}function O5(e){return kk(Nt({observeElementRect:gk,observeElementOffset:yk,scrollToFn:$k},e))}const Ek=T('<div slot="suffix" class="flex"><sl-icon class="text-gray-400 hover:text-gray-600" name="x-circle-fill"></sl-icon></div>'),Ju=T("<sl-menu-item></sl-menu-item>"),Sk=T('<sl-menu-item><p class="text-center text-gray-400 italic">Loading...</p></sl-menu-item>'),Ok=T('<div><style></style><style></style><style></style><style></style><sl-dropdown class="dropdown relative" hoist><sl-input slot="trigger" size="medium" class="input"><p slot="help-text" class="text-red-500 pt-1 font-sans"></p><div slot="suffix" class="flex"><sl-spinner slot="suffix"></sl-spinner></div><div slot="suffix" class="flex"><sl-icon></sl-icon></div></sl-input><div class="border border-gray-200 dropdown-container overflow-hidden relative"><div class="bg-white pt-2 overflow-x-hidden overflow-y-auto relative"><div></div></div></div></sl-dropdown></div>'),Ck=T('<div class="flex items-center pb-2"><p class="text-gray-700 text-sm font-sans"></p></div>'),Nk=T('<p class="pl-1 text-red-500">*</p>'),Tk=T('<p class="text-gray-400 text-xs pl-2 font-sans">Optional</p>'),C5=T("<div>Loading...</div>"),N5=T('<p class="text-center text-gray-400 italic">Loading...</p>'),T5=T('<p class="text-center text-gray-400 italic">Nothing more to load</p>'),P5=T("<p></p>"),Pk=T('<sl-menu-item class="group"></sl-menu-item>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");const wn=e=>{let t,n,r,i,o;e.actionRef&&(e.actionRef.clear=()=>{l(void 0),d(-1),i.value="",v(""),_()});const[a,s]=V(!1),[c,l]=V(),[u,d]=V(-1),[f,h]=V(O5({count:e.data.length,getScrollElement:()=>r,estimateSize:()=>36.8,overscan:25})),[p,m]=V(),v=$3(async x=>{e.onSearchChange&&await e.onSearchChange(x)},250),b=new IntersectionObserver(async x=>{x?.at(-1)?.isIntersecting&&e.hasMore&&e.fetchMore&&await e.fetchMore()});me(()=>{p()&&b.observe(p())});const y=x=>{if(x)return e.helpText?e.helpText:e.required?"Please select data...":void 0},g=x=>{const O=new CustomEvent("photon-data-selected",{composed:!0,bubbles:!0,detail:{data:x}});t?.dispatchEvent(O)},_=()=>{const x=new CustomEvent("photon-data-unselected",{composed:!0,bubbles:!0,detail:{}});t?.dispatchEvent(x)};return me(()=>{e.selectedData&&(l(e.selectedData),g(e.selectedData)),e.selectedData===void 0&&l(void 0)}),me(()=>{const x=e.data.length*36.8;r.style.minHeight=`${x}px`;const O=O5({count:e.hasMore?e.data.length+1:e.data.length,getScrollElement:()=>r,estimateSize:()=>36.8,overscan:e.fetchMore?25:e.data.length});h(O)}),ht(()=>{i&&i.addEventListener("keydown",x=>{(x.code=="Space"||x.key==" ")&&x.stopImmediatePropagation()})}),(()=>{const x=H(()=>document.importNode(Ok,!0)),O=x.firstChild,C=O.nextSibling,M=C.nextSibling,D=M.nextSibling,F=D.nextSibling,Y=F.firstChild,J=Y.firstChild,G=J.nextSibling,j=G.firstChild,z=G.nextSibling,Q=z.firstChild,I=Y.nextSibling,U=I.firstChild,W=U.firstChild,de=t;typeof de=="function"?he(de,x):t=x,k(O,Je),k(C,Xt),k(M,Yt),k(D,uk),k(x,(()=>{const te=se(()=>!!e.label);return()=>te()?(()=>{const ye=Ck.cloneNode(!0),Ne=ye.firstChild;return k(Ne,()=>e.label),k(ye,(()=>{const ce=se(()=>!!e.required);return()=>ce()?Nk.cloneNode(!0):null})(),null),k(ye,(()=>{const ce=se(()=>!!e.optional);return()=>ce()?Tk.cloneNode(!0):null})(),null),ye})():null})(),F);const be=n;typeof be=="function"?he(be,F):n=F,F.addEventListener("sl-hide",async()=>{c()||(i.value="",e.onHide&&await e.onHide()),s(!1)}),F.addEventListener("sl-show",async()=>{s(!0),e.onOpen&&await e.onOpen()}),F.style.setProperty("width","100%"),F._$owner=A();const P=i;typeof P=="function"?he(P,Y):i=Y,Y.addEventListener("sl-input",te=>{a()||n.show(),v(te.target.value)}),Y.addEventListener("sl-focus",()=>{n.children[1].style.width=`${i.clientWidth}px`,u()>0&&f().scrollToIndex(u())}),Y._$owner=A(),k(J,()=>y(e.invalid??!1)),j._$owner=A(),k(Y,S(ee,{get when(){return e.clearable},get children(){const te=H(()=>document.importNode(Ek,!0)),ye=te.firstChild;return ye.addEventListener("click",Ne=>{Ne.stopImmediatePropagation(),l(void 0),d(-1),i.value="",v(""),_(),n.hide()}),ye._$owner=A(),q(()=>te.classList.toggle("hidden",!!(e.isLoading||c()==null))),te}}),z),Q._$owner=A();const B=o;typeof B=="function"?he(B,U):o=U,U.style.setProperty("max-height","200px"),U.style.setProperty("min-height","56px"),U.style.setProperty("width","100%");const Ce=r;return typeof Ce=="function"?he(Ce,W):r=W,W.style.setProperty("min-height","36.8px"),W.style.setProperty("width","100%"),k(W,S(ee,{get when(){return e.data.length>0&&!e.groups},get children(){return S(sr,{get each(){return f().getVirtualItems()},get fallback(){return C5.cloneNode(!0)},children:te=>{const ye=te.index>e.data.length-1,Ne=e.data[te.index];return(()=>{const ce=H(()=>document.importNode(Ju,!0));return he(re=>{ye&&te.index>0&&m(re)},ce),ce.$$click=()=>{ye||(l(Ne),d(te.index),i.value="",v(""),g(Ne),n.hide())},ce.style.setProperty("width","100%"),ce._$owner=A(),k(ce,()=>ye?e.hasMore?N5.cloneNode(!0):T5.cloneNode(!0):(()=>{const re=P5.cloneNode(!0);return k(re,()=>e.displayAccessor(Ne,!0)),q(ae=>{const _e=!e.showOverflow,it=!e.showOverflow,kt=!e.showOverflow,mt=!!e.showOverflow;return _e!==ae._v$14&&re.classList.toggle("overflow-hidden",ae._v$14=_e),it!==ae._v$15&&re.classList.toggle("overflow-ellipsis",ae._v$15=it),kt!==ae._v$16&&re.classList.toggle("whitespace-nowrap",ae._v$16=kt),mt!==ae._v$17&&re.classList.toggle("whitespace-normal",ae._v$17=mt),ae},{_v$14:void 0,_v$15:void 0,_v$16:void 0,_v$17:void 0}),re})()),q(re=>{const ae=Ne&&Ne.id===c()?.id&&!ye?"selected default":"default",_e=`${te.size}px`;return ae!==re._v$12&&cl(ce,re._v$12=ae),_e!==re._v$13&&ce.style.setProperty("min-height",re._v$13=_e),re},{_v$12:void 0,_v$13:void 0}),ce})()}})}}),null),k(W,S(ee,{get when(){return e.data.length>0&&e.groups&&e.groups.length>0},get children(){return S(sr,{get each(){return e.groups||[]},children:te=>[(()=>{const ye=H(()=>document.importNode(Pk,!0));return ye._$owner=A(),k(ye,()=>te.label),q(()=>ye.classList.toggle("hidden",f().getVirtualItems().filter(Ne=>te.filter(e.data[Ne.index])).length===0)),ye})(),S(sr,{get each(){return f().getVirtualItems()},get fallback(){return C5.cloneNode(!0)},children:ye=>{const Ne=ye.index>e.data.length-1,ce=e.data[ye.index];return(()=>{const re=H(()=>document.importNode(Ju,!0));return he(ae=>{Ne&&ye.index>0&&m(ae)},re),re.$$click=()=>{Ne||(l(ce),d(ye.index),i.value="",v(""),g(ce),n.hide())},re.style.setProperty("width","100%"),re._$owner=A(),k(re,()=>Ne?e.hasMore?N5.cloneNode(!0):T5.cloneNode(!0):(()=>{const ae=P5.cloneNode(!0);return k(ae,()=>e.displayAccessor(ce,!0)),q(_e=>{const it=!e.showOverflow,kt=!e.showOverflow,mt=!e.showOverflow,Vt=!!e.showOverflow;return it!==_e._v$20&&ae.classList.toggle("overflow-hidden",_e._v$20=it),kt!==_e._v$21&&ae.classList.toggle("overflow-ellipsis",_e._v$21=kt),mt!==_e._v$22&&ae.classList.toggle("whitespace-nowrap",_e._v$22=mt),Vt!==_e._v$23&&ae.classList.toggle("whitespace-normal",_e._v$23=Vt),_e},{_v$20:void 0,_v$21:void 0,_v$22:void 0,_v$23:void 0}),ae})()),q(ae=>{const _e=ce&&ce.id===c()?.id&&!Ne?"selected default":"default",it=`${ye.size}px`;return _e!==ae._v$18&&cl(re,ae._v$18=_e),it!==ae._v$19&&re.style.setProperty("min-height",ae._v$19=it),ae},{_v$18:void 0,_v$19:void 0}),re})()}})]})}}),null),k(W,S(ee,{get when(){return e.data.length==0&&!e.isLoading},get children(){const te=H(()=>document.importNode(Ju,!0));return te._$owner=A(),k(te,()=>e.noDataMsg?e.noDataMsg:"No data found"),te}}),null),k(W,S(ee,{get when(){return e.data.length==0&&e.isLoading},get children(){const te=H(()=>document.importNode(Sk,!0));return te._$owner=A(),te}}),null),q(te=>{const ye=e.forceLabelSize&&!e.invalid?-20:e.invalid?-18:0,Ne=e.disabled??!1,ce=c()?e.displayAccessor(c(),!1):e.placeholder??"Select data...",re=e.disabled??!1,ae=!!(e.invalid??!1),_e=!!(e.disabled??!1),it=e.required,kt=!!e.forceLabelSize,mt=!e.isLoading,Vt=!!e.isLoading,Qn=a()?"chevron-up":"chevron-down";return ye!==te._v$&&(F.distance=te._v$=ye),Ne!==te._v$2&&(F.disabled=te._v$2=Ne),ce!==te._v$3&&(Y.placeholder=te._v$3=ce),re!==te._v$4&&(Y.disabled=te._v$4=re),ae!==te._v$5&&Y.classList.toggle("invalid",te._v$5=ae),_e!==te._v$6&&Y.classList.toggle("disabled",te._v$6=_e),it!==te._v$7&&(Y.required=te._v$7=it),kt!==te._v$8&&J.classList.toggle("h-[21px]",te._v$8=kt),mt!==te._v$9&&G.classList.toggle("hidden",te._v$9=mt),Vt!==te._v$10&&z.classList.toggle("hidden",te._v$10=Vt),Qn!==te._v$11&&(Q.name=te._v$11=Qn),te},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0,_v$5:void 0,_v$6:void 0,_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0,_v$11:void 0}),x})()};Yi(["click"]);const A5=_a`
|
|
1822
|
+
color: hsl(`+Math.max(0,Math.min(120-120*d,120))+"deg 100% 31%);",n?.key)}return i}}const mk=e=>e,vk=e=>{const t=Math.max(e.startIndex-e.overscan,0),n=Math.min(e.endIndex+e.overscan,e.count-1),r=[];for(let i=t;i<=n;i++)r.push(i);return r},gk=(e,t)=>{const n=pk(e.scrollElement,r=>{t(r)});if(!!e.scrollElement)return t(e.scrollElement.getBoundingClientRect()),n.observe(),()=>{n.unobserve()}},yk=(e,t)=>{const n=()=>t(e.scrollElement[e.options.horizontal?"scrollLeft":"scrollTop"]);if(!!e.scrollElement)return n(),e.scrollElement.addEventListener("scroll",n,{capture:!1,passive:!0}),()=>{e.scrollElement.removeEventListener("scroll",n)}},bk=(e,t)=>e.getBoundingClientRect()[t.options.horizontal?"width":"height"],$k=(e,t,n)=>{var r;(r=n.scrollElement)==null||r.scrollTo({[n.options.horizontal?"left":"top"]:e,behavior:t?"smooth":void 0})};class wk{constructor(t){var n=this;this.unsubs=[],this.scrollElement=null,this.measurementsCache=[],this.itemMeasurementsCache={},this.pendingMeasuredCacheIndexes=[],this.measureElementCache={},this.setOptions=r=>{Object.entries(r).forEach(i=>{let[o,a]=i;typeof a>"u"&&delete r[o]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:mk,rangeExtractor:vk,enableSmoothScroll:!0,onChange:()=>{},measureElement:bk,initialRect:{width:0,height:0},...r}},this.notify=()=>{var r,i;(r=(i=this.options).onChange)==null||r.call(i,this)},this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(r=>r()),this.unsubs=[]},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{const r=this.options.getScrollElement();this.scrollElement!==r&&(this.cleanup(),this.scrollElement=r,this.unsubs.push(this.options.observeElementRect(this,i=>{this.scrollRect=i,this.notify()})),this.unsubs.push(this.options.observeElementOffset(this,i=>{this.scrollOffset=i,this.notify()})))},this.getSize=()=>this.scrollRect[this.options.horizontal?"width":"height"],this.getMeasurements=Wa(()=>[this.options.count,this.options.paddingStart,this.options.getItemKey,this.itemMeasurementsCache],(r,i,o,a)=>{const s=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];const c=this.measurementsCache.slice(0,s);for(let l=s;l<r;l++){const u=o(l),d=a[u],f=c[l-1]?c[l-1].end:i,h=typeof d=="number"?d:this.options.estimateSize(l),p=f+h;c[l]={index:l,start:f,size:h,end:p,key:u}}return this.measurementsCache=c,c},{key:!1,debug:()=>this.options.debug}),this.calculateRange=Wa(()=>[this.getMeasurements(),this.getSize(),this.scrollOffset],(r,i,o)=>xk({measurements:r,outerSize:i,scrollOffset:o}),{key:!1,debug:()=>this.options.debug}),this.getIndexes=Wa(()=>[this.options.rangeExtractor,this.calculateRange(),this.options.overscan,this.options.count],(r,i,o,a)=>r({...i,overscan:o,count:a}),{key:!1}),this.getVirtualItems=Wa(()=>[this.getIndexes(),this.getMeasurements(),this.options.measureElement],(r,i,o)=>{const a=u=>d=>{var f;const h=this.measurementsCache[u];if(!d)return;const p=o(d,this),m=(f=this.itemMeasurementsCache[h.key])!=null?f:h.size;p!==m&&(h.start<this.scrollOffset&&(this.destinationOffset||this._scrollToOffset(this.scrollOffset+(p-m),!1)),this.pendingMeasuredCacheIndexes.push(u),this.itemMeasurementsCache={...this.itemMeasurementsCache,[h.key]:p},this.notify())},s=[],c={};for(let u=0,d=r.length;u<d;u++){var l;const f=r[u],p={...i[f],measureElement:c[f]=(l=this.measureElementCache[f])!=null?l:a(f)};s.push(p)}return this.measureElementCache=c,s},{key:!1}),this.scrollToOffset=function(r,i){let{align:o}=i===void 0?{align:"start"}:i;const a=()=>{const s=n.scrollOffset,c=n.getSize();o==="auto"&&(r<=s?o="start":r>=s+c?o="end":o="start"),o==="start"?n._scrollToOffset(r,!0):o==="end"?n._scrollToOffset(r-c,!0):o==="center"&&n._scrollToOffset(r-c/2,!0)};a(),requestAnimationFrame(()=>{a()})},this.scrollToIndex=function(r,i){let{align:o,...a}=i===void 0?{align:"auto"}:i;const s=n.getMeasurements(),c=n.scrollOffset,l=n.getSize(),{count:u}=n.options,d=s[Math.max(0,Math.min(r,u-1))];if(!d)return;if(o==="auto")if(d.end>=c+l-n.options.scrollPaddingEnd)o="end";else if(d.start<=c+n.options.scrollPaddingStart)o="start";else return;const f=o==="end"?d.end+n.options.scrollPaddingEnd:d.start-n.options.scrollPaddingStart;n.scrollToOffset(f,{align:o,...a})},this.getTotalSize=()=>{var r;return(((r=this.getMeasurements()[this.options.count-1])==null?void 0:r.end)||this.options.paddingStart)+this.options.paddingEnd},this._scrollToOffset=(r,i)=>{clearTimeout(this.scrollCheckFrame),this.destinationOffset=r,this.options.scrollToFn(r,this.options.enableSmoothScroll&&i,this);let o;const a=()=>{let s=this.scrollOffset;this.scrollCheckFrame=o=setTimeout(()=>{if(this.scrollCheckFrame===o){if(this.scrollOffset===s){this.destinationOffset=void 0;return}s=this.scrollOffset,a()}},100)};a()},this.measure=()=>{this.itemMeasurementsCache={},this.notify()},this.setOptions(t),this.scrollRect=this.options.initialRect,this.scrollOffset=this.options.initialOffset}}const _k=(e,t,n,r)=>{for(;e<=t;){const i=(e+t)/2|0,o=n(i);if(o<r)e=i+1;else if(o>r)t=i-1;else return i}return e>0?e-1:0};function xk(e){let{measurements:t,outerSize:n,scrollOffset:r}=e;const i=t.length-1,a=_k(0,i,c=>t[c].start,r);let s=a;for(;s<i&&t[s].end<r+n;)s++;return{startIndex:a,endIndex:s}}function kk(e){const t=Nt(e),n=new wk(t),[r,i]=kr(n.getVirtualItems()),[o,a]=V(n.getTotalSize()),s={get(l,u){switch(u){case"getVirtualItems":return()=>r;case"getTotalSize":return()=>o();default:return Reflect.get(l,u)}}},c=new Proxy(n,s);return c.setOptions(t),ht(()=>{const l=c._didMount();c._willUpdate(),Gi(l)}),ag(()=>{c.setOptions(Nt(t,e,{onChange:l=>{l._willUpdate(),i(q_(l.getVirtualItems(),{key:"index"})),a(l.getTotalSize()),e.onChange==null||e.onChange(l)}})),c.measure()}),c}function O5(e){return kk(Nt({observeElementRect:gk,observeElementOffset:yk,scrollToFn:$k},e))}const Ek=N('<div slot="suffix" class="flex"><sl-icon class="text-gray-400 hover:text-gray-600" name="x-circle-fill"></sl-icon></div>'),Ju=N("<sl-menu-item></sl-menu-item>"),Sk=N('<sl-menu-item><p class="text-center text-gray-400 italic">Loading...</p></sl-menu-item>'),Ok=N('<div><style></style><style></style><style></style><style></style><sl-dropdown class="dropdown relative" hoist><sl-input slot="trigger" size="medium" class="input"><p slot="help-text" class="text-red-500 pt-1 font-sans"></p><div slot="suffix" class="flex"><sl-spinner slot="suffix"></sl-spinner></div><div slot="suffix" class="flex"><sl-icon></sl-icon></div></sl-input><div class="border border-gray-200 dropdown-container overflow-hidden relative"><div class="bg-white pt-2 overflow-x-hidden overflow-y-auto relative"><div></div></div></div></sl-dropdown></div>'),Ck=N('<div class="flex items-center pb-2"><p class="text-gray-700 text-sm font-sans"></p></div>'),Nk=N('<p class="pl-1 text-red-500">*</p>'),Tk=N('<p class="text-gray-400 text-xs pl-2 font-sans">Optional</p>'),C5=N("<div>Loading...</div>"),N5=N('<p class="text-center text-gray-400 italic">Loading...</p>'),T5=N('<p class="text-center text-gray-400 italic">Nothing more to load</p>'),P5=N("<p></p>"),Pk=N('<sl-menu-item class="group"></sl-menu-item>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");const wn=e=>{let t,n,r,i,o;e.actionRef&&(e.actionRef.clear=()=>{l(void 0),d(-1),i.value="",v(""),_()});const[a,s]=V(!1),[c,l]=V(),[u,d]=V(-1),[f,h]=V(O5({count:e.data.length,getScrollElement:()=>r,estimateSize:()=>36.8,overscan:25})),[p,m]=V(),v=$3(async k=>{e.onSearchChange&&await e.onSearchChange(k)},250),b=new IntersectionObserver(async k=>{k?.at(-1)?.isIntersecting&&e.hasMore&&e.fetchMore&&await e.fetchMore()});me(()=>{p()&&b.observe(p())});const y=k=>{if(k)return e.helpText?e.helpText:e.required?"Please select data...":void 0},g=k=>{const O=new CustomEvent("photon-data-selected",{composed:!0,bubbles:!0,detail:{data:k}});t?.dispatchEvent(O)},_=()=>{const k=new CustomEvent("photon-data-unselected",{composed:!0,bubbles:!0,detail:{}});t?.dispatchEvent(k)};return me(()=>{e.selectedData&&(l(e.selectedData),g(e.selectedData)),e.selectedData===void 0&&l(void 0)}),me(()=>{const k=e.data.length*36.8;r.style.minHeight=`${k}px`;const O=O5({count:e.hasMore?e.data.length+1:e.data.length,getScrollElement:()=>r,estimateSize:()=>36.8,overscan:e.fetchMore?25:e.data.length});h(O)}),ht(()=>{i&&i.addEventListener("keydown",k=>{(k.code=="Space"||k.key==" ")&&k.stopImmediatePropagation()})}),(()=>{const k=H(()=>document.importNode(Ok,!0)),O=k.firstChild,C=O.nextSibling,M=C.nextSibling,D=M.nextSibling,F=D.nextSibling,Y=F.firstChild,J=Y.firstChild,G=J.nextSibling,j=G.firstChild,z=G.nextSibling,Q=z.firstChild,I=Y.nextSibling,U=I.firstChild,W=U.firstChild,de=t;typeof de=="function"?he(de,k):t=k,x(O,Je),x(C,Xt),x(M,Yt),x(D,uk),x(k,(()=>{const te=se(()=>!!e.label);return()=>te()?(()=>{const ye=Ck.cloneNode(!0),Ne=ye.firstChild;return x(Ne,()=>e.label),x(ye,(()=>{const ce=se(()=>!!e.required);return()=>ce()?Nk.cloneNode(!0):null})(),null),x(ye,(()=>{const ce=se(()=>!!e.optional);return()=>ce()?Tk.cloneNode(!0):null})(),null),ye})():null})(),F);const be=n;typeof be=="function"?he(be,F):n=F,F.addEventListener("sl-hide",async()=>{c()||(i.value="",e.onHide&&await e.onHide()),s(!1)}),F.addEventListener("sl-show",async()=>{s(!0),e.onOpen&&await e.onOpen()}),F.style.setProperty("width","100%"),F._$owner=A();const P=i;typeof P=="function"?he(P,Y):i=Y,Y.addEventListener("sl-input",te=>{a()||n.show(),v(te.target.value)}),Y.addEventListener("sl-focus",()=>{n.children[1].style.width=`${i.clientWidth}px`,u()>0&&f().scrollToIndex(u())}),Y._$owner=A(),x(J,()=>y(e.invalid??!1)),j._$owner=A(),x(Y,S(ee,{get when(){return e.clearable},get children(){const te=H(()=>document.importNode(Ek,!0)),ye=te.firstChild;return ye.addEventListener("click",Ne=>{Ne.stopImmediatePropagation(),l(void 0),d(-1),i.value="",v(""),_(),n.hide()}),ye._$owner=A(),q(()=>te.classList.toggle("hidden",!!(e.isLoading||c()==null))),te}}),z),Q._$owner=A();const B=o;typeof B=="function"?he(B,U):o=U,U.style.setProperty("max-height","200px"),U.style.setProperty("min-height","56px"),U.style.setProperty("width","100%");const Ce=r;return typeof Ce=="function"?he(Ce,W):r=W,W.style.setProperty("min-height","36.8px"),W.style.setProperty("width","100%"),x(W,S(ee,{get when(){return e.data.length>0&&!e.groups},get children(){return S(sr,{get each(){return f().getVirtualItems()},get fallback(){return C5.cloneNode(!0)},children:te=>{const ye=te.index>e.data.length-1,Ne=e.data[te.index];return(()=>{const ce=H(()=>document.importNode(Ju,!0));return he(re=>{ye&&te.index>0&&m(re)},ce),ce.$$click=()=>{ye||(l(Ne),d(te.index),i.value="",v(""),g(Ne),n.hide())},ce.style.setProperty("width","100%"),ce._$owner=A(),x(ce,()=>ye?e.hasMore?N5.cloneNode(!0):T5.cloneNode(!0):(()=>{const re=P5.cloneNode(!0);return x(re,()=>e.displayAccessor(Ne,!0)),q(ae=>{const _e=!e.showOverflow,it=!e.showOverflow,kt=!e.showOverflow,mt=!!e.showOverflow;return _e!==ae._v$14&&re.classList.toggle("overflow-hidden",ae._v$14=_e),it!==ae._v$15&&re.classList.toggle("overflow-ellipsis",ae._v$15=it),kt!==ae._v$16&&re.classList.toggle("whitespace-nowrap",ae._v$16=kt),mt!==ae._v$17&&re.classList.toggle("whitespace-normal",ae._v$17=mt),ae},{_v$14:void 0,_v$15:void 0,_v$16:void 0,_v$17:void 0}),re})()),q(re=>{const ae=Ne&&Ne.id===c()?.id&&!ye?"selected default":"default",_e=`${te.size}px`;return ae!==re._v$12&&cl(ce,re._v$12=ae),_e!==re._v$13&&ce.style.setProperty("min-height",re._v$13=_e),re},{_v$12:void 0,_v$13:void 0}),ce})()}})}}),null),x(W,S(ee,{get when(){return e.data.length>0&&e.groups&&e.groups.length>0},get children(){return S(sr,{get each(){return e.groups||[]},children:te=>[(()=>{const ye=H(()=>document.importNode(Pk,!0));return ye._$owner=A(),x(ye,()=>te.label),q(()=>ye.classList.toggle("hidden",f().getVirtualItems().filter(Ne=>te.filter(e.data[Ne.index])).length===0)),ye})(),S(sr,{get each(){return f().getVirtualItems()},get fallback(){return C5.cloneNode(!0)},children:ye=>{const Ne=ye.index>e.data.length-1,ce=e.data[ye.index];return(()=>{const re=H(()=>document.importNode(Ju,!0));return he(ae=>{Ne&&ye.index>0&&m(ae)},re),re.$$click=()=>{Ne||(l(ce),d(ye.index),i.value="",v(""),g(ce),n.hide())},re.style.setProperty("width","100%"),re._$owner=A(),x(re,()=>Ne?e.hasMore?N5.cloneNode(!0):T5.cloneNode(!0):(()=>{const ae=P5.cloneNode(!0);return x(ae,()=>e.displayAccessor(ce,!0)),q(_e=>{const it=!e.showOverflow,kt=!e.showOverflow,mt=!e.showOverflow,Vt=!!e.showOverflow;return it!==_e._v$20&&ae.classList.toggle("overflow-hidden",_e._v$20=it),kt!==_e._v$21&&ae.classList.toggle("overflow-ellipsis",_e._v$21=kt),mt!==_e._v$22&&ae.classList.toggle("whitespace-nowrap",_e._v$22=mt),Vt!==_e._v$23&&ae.classList.toggle("whitespace-normal",_e._v$23=Vt),_e},{_v$20:void 0,_v$21:void 0,_v$22:void 0,_v$23:void 0}),ae})()),q(ae=>{const _e=ce&&ce.id===c()?.id&&!Ne?"selected default":"default",it=`${ye.size}px`;return _e!==ae._v$18&&cl(re,ae._v$18=_e),it!==ae._v$19&&re.style.setProperty("min-height",ae._v$19=it),ae},{_v$18:void 0,_v$19:void 0}),re})()}})]})}}),null),x(W,S(ee,{get when(){return e.data.length==0&&!e.isLoading},get children(){const te=H(()=>document.importNode(Ju,!0));return te._$owner=A(),x(te,()=>e.noDataMsg?e.noDataMsg:"No data found"),te}}),null),x(W,S(ee,{get when(){return e.data.length==0&&e.isLoading},get children(){const te=H(()=>document.importNode(Sk,!0));return te._$owner=A(),te}}),null),q(te=>{const ye=e.forceLabelSize&&!e.invalid?-20:e.invalid?-18:0,Ne=e.disabled??!1,ce=c()?e.displayAccessor(c(),!1):e.placeholder??"Select data...",re=e.disabled??!1,ae=!!(e.invalid??!1),_e=!!(e.disabled??!1),it=e.required,kt=!!e.forceLabelSize,mt=!e.isLoading,Vt=!!e.isLoading,Qn=a()?"chevron-up":"chevron-down";return ye!==te._v$&&(F.distance=te._v$=ye),Ne!==te._v$2&&(F.disabled=te._v$2=Ne),ce!==te._v$3&&(Y.placeholder=te._v$3=ce),re!==te._v$4&&(Y.disabled=te._v$4=re),ae!==te._v$5&&Y.classList.toggle("invalid",te._v$5=ae),_e!==te._v$6&&Y.classList.toggle("disabled",te._v$6=_e),it!==te._v$7&&(Y.required=te._v$7=it),kt!==te._v$8&&J.classList.toggle("h-[21px]",te._v$8=kt),mt!==te._v$9&&G.classList.toggle("hidden",te._v$9=mt),Vt!==te._v$10&&z.classList.toggle("hidden",te._v$10=Vt),Qn!==te._v$11&&(Q.name=te._v$11=Qn),te},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0,_v$5:void 0,_v$6:void 0,_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0,_v$11:void 0}),k})()};Yi(["click"]);const A5=_a`
|
|
1823
1823
|
fragment PatientOrderFields on Patient {
|
|
1824
1824
|
id
|
|
1825
1825
|
externalId
|
|
@@ -1860,7 +1860,7 @@ lit-html/directives/if-defined.js:
|
|
|
1860
1860
|
phone
|
|
1861
1861
|
}
|
|
1862
1862
|
}
|
|
1863
|
-
`,Ak=()=>{const[e,t]=kr({patients:{data:[],errors:[],isLoading:!1,finished:!1},selectedPatient:{data:void 0,errors:[],isLoading:!1}}),n=async(s,c)=>{t("selectedPatient",{...e.selectedPatient,isLoading:!0});const{data:l,errors:u}=await s.clinical.patient.getPatient({id:c,fragment:{PatientOrderFields:A5}});t("selectedPatient",{...e.selectedPatient,isLoading:!1,data:l.patient,errors:u})},r=async(s,c)=>{c||(c={}),t("patients",{...e.patients,isLoading:!0});const{data:l,errors:u}=await s.clinical.patient.getPatients({first:c.first,name:c.name,fragment:{PatientOrderFields:A5}});return t("patients",{...e.patients,isLoading:!1,errors:u,data:l.patients,finished:l.patients.length===0}),(!u||u.length===0)&&l.patients.length>0?()=>i(s,{...c,after:l.patients?.at(-1).id}):void 0},i=async(s,c)=>{t("patients",{...e.patients,isLoading:!0});const{data:l,errors:u}=await s.clinical.patient.getPatients(c);return t("patients",{...e.patients,isLoading:!1,errors:u,data:[...e.patients.data,...l.patients],finished:l.patients.length===0}),(!u||u.length===0)&&l.patients.length>0?()=>i(s,{...c,after:l.patients?.at(-1).id}):void 0};return{store:e,actions:{getPatients:r,getSelectedPatient:n,clearSelectedPatient:async()=>{t("selectedPatient",{...e.selectedPatient,data:void 0})},reset:async()=>{t("patients",{data:[],errors:[],isLoading:!1,finished:!1}),t("selectedPatient",{data:void 0,errors:[],isLoading:!1})}}}},Gc=Ak(),Ik=
|
|
1863
|
+
`,Ak=()=>{const[e,t]=kr({patients:{data:[],errors:[],isLoading:!1,finished:!1},selectedPatient:{data:void 0,errors:[],isLoading:!1}}),n=async(s,c)=>{t("selectedPatient",{...e.selectedPatient,isLoading:!0});const{data:l,errors:u}=await s.clinical.patient.getPatient({id:c,fragment:{PatientOrderFields:A5}});t("selectedPatient",{...e.selectedPatient,isLoading:!1,data:l.patient,errors:u})},r=async(s,c)=>{c||(c={}),t("patients",{...e.patients,isLoading:!0});const{data:l,errors:u}=await s.clinical.patient.getPatients({first:c.first,name:c.name,fragment:{PatientOrderFields:A5}});return t("patients",{...e.patients,isLoading:!1,errors:u,data:l.patients,finished:l.patients.length===0}),(!u||u.length===0)&&l.patients.length>0?()=>i(s,{...c,after:l.patients?.at(-1).id}):void 0},i=async(s,c)=>{t("patients",{...e.patients,isLoading:!0});const{data:l,errors:u}=await s.clinical.patient.getPatients(c);return t("patients",{...e.patients,isLoading:!1,errors:u,data:[...e.patients.data,...l.patients],finished:l.patients.length===0}),(!u||u.length===0)&&l.patients.length>0?()=>i(s,{...c,after:l.patients?.at(-1).id}):void 0};return{store:e,actions:{getPatients:r,getSelectedPatient:n,clearSelectedPatient:async()=>{t("selectedPatient",{...e.selectedPatient,data:void 0})},reset:async()=>{t("patients",{data:[],errors:[],isLoading:!1,finished:!1}),t("selectedPatient",{data:void 0,errors:[],isLoading:!1})}}}},Gc=Ak(),Ik=N("<div></div>");Me("photon-patient-select",{label:void 0,required:!1,invalid:!1,helpText:void 0,selected:void 0,formName:void 0,disabled:!1,forceLabelSize:!1,sdk:void 0},e=>{let t;const n=pt(),{store:r,actions:i}=Gc;let o;ht(()=>{i.reset()});const a=c=>{const l=new CustomEvent("photon-patient-selected",{composed:!0,bubbles:!0,detail:{patient:c}});t?.dispatchEvent(l)},s=se(()=>r.selectedPatient.data?[r.selectedPatient.data,...r.patients.data.filter(c=>c?.id!==r.selectedPatient.data.id)]:r.patients.data);return me(async()=>{e.selected&&!r.selectedPatient.data&&H(async()=>{await i.getSelectedPatient(n?n.getSDK():e.sdk,e.selected)})}),(()=>{const c=Ik.cloneNode(!0),l=t;return typeof l=="function"?he(l,c):t=c,c.addEventListener("photon-data-selected",u=>{a(u.detail.data)}),x(c,S(wn,{get data(){return s()},get label(){return e.label},get forceLabelSize(){return e.forceLabelSize},get required(){return e.required},get disabled(){return e.disabled},placeholder:"Select patient...",get invalid(){return e.invalid},get isLoading(){return r.patients.isLoading||r.selectedPatient.isLoading},get hasMore(){return r.patients.data.length%25===0&&!r.patients.finished},displayAccessor:u=>u?.name?.full||"",onSearchChange:async u=>o=await i.getPatients(n.getSDK(),{name:u}),onOpen:async()=>{r.patients.data.length==0&&(o=await i.getPatients(n.getSDK()))},onHide:async()=>{o=await i.getPatients(n.getSDK())},fetchMore:async()=>{o&&(o=await o())},noDataMsg:"No patients found",get helpText(){return e.helpText},get selectedData(){return r.selectedPatient.data}})),c})()});const ed=N("<style></style>"),Mk=N("<slot></slot>"),Dk=N("<photon-login></photon-login>"),Lk=N('<div class="w-full flex justify-center"><sl-spinner></sl-spinner></div>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-auth-wrapper",{autoLogin:!1,hideLoader:!1,redirectPath:{attribute:"redirect-path",value:void 0,reflect:!1,notify:!1,parse:!1}},e=>{const t=pt(),[n,r]=V(!1),[i,o]=V(!0);return me(()=>{t||console.error("[photon-auth-wrapper] No valid PhotonClient instance was provided. Please ensure you are wrapping the element in a photon-client element")}),me(()=>{if(t?.authentication.state.isLoading)o(!0);else{if(o(!1),!t?.authentication.state.isAuthenticated&&e.autoLogin){const a={appState:{}};e.redirectPath&&(a.appState.returnTo=e.redirectPath),t?.authentication.login(a)}r(t?.authentication.state.isAuthenticated||!1)}}),[(()=>{const a=ed.cloneNode(!0);return x(a,Je),a})(),(()=>{const a=ed.cloneNode(!0);return x(a,Xt),a})(),(()=>{const a=ed.cloneNode(!0);return x(a,Yt),a})(),S(ee,{get when(){return t&&n()},get children(){const a=Mk.cloneNode(!0);return a._$owner=A(),a}}),S(ee,{get when(){return t&&!n()&&!i()&&!e.autoLogin},get children(){const a=H(()=>document.importNode(Dk,!0));return a._$owner=A(),q(()=>a.redirectPath=e.redirectPath),a}}),S(ee,{get when(){return t&&i()&&!e.hideLoader},get children(){const a=H(()=>document.importNode(Lk,!0)),s=a.firstChild;return s.style.setProperty("font-size","3rem"),s._$owner=A(),a}})]});var Rk=_t`
|
|
1864
1864
|
${At}
|
|
1865
1865
|
|
|
1866
1866
|
:host {
|
|
@@ -2252,8 +2252,8 @@ lit-html/static.js:
|
|
|
2252
2252
|
<slot part="label" class="switch__label"></slot>
|
|
2253
2253
|
</label>
|
|
2254
2254
|
`}};Tt.styles=Vk;w([rt('input[type="checkbox"]')],Tt.prototype,"input",2);w([Dn()],Tt.prototype,"hasFocus",2);w([E()],Tt.prototype,"title",2);w([E()],Tt.prototype,"name",2);w([E()],Tt.prototype,"value",2);w([E({reflect:!0})],Tt.prototype,"size",2);w([E({type:Boolean,reflect:!0})],Tt.prototype,"disabled",2);w([E({type:Boolean,reflect:!0})],Tt.prototype,"checked",2);w([Wc("checked")],Tt.prototype,"defaultChecked",2);w([E({reflect:!0})],Tt.prototype,"form",2);w([E({type:Boolean,reflect:!0})],Tt.prototype,"required",2);w([Ve("checked",{waitUntilFirstUpdate:!0})],Tt.prototype,"handleCheckedChange",1);w([Ve("disabled",{waitUntilFirstUpdate:!0})],Tt.prototype,"handleDisabledChange",1);Tt=w([It("sl-switch")],Tt);const Uk=`.remove-icon-button::part(base):hover,.remove-icon-button::part(base):focus{--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}.edit-icon-button::part(base):hover,.edit-icon-button::part(base):focus{--tw-text-opacity: 1;color:rgb(234 179 8/var(--tw-text-opacity))}.enable-switch{--width: 60px;--height: 32px;--thumb-size: 26px;--sl-color-primary-600: #22c55e}
|
|
2255
|
-
`;class Bk extends TypeError{constructor(t,n){let r;const{message:i,explanation:o,...a}=t,{path:s}=t,c=s.length===0?i:`At path: ${s.join(".")} -- ${i}`;super(o??c),o!=null&&(this.cause=c),Object.assign(this,a),this.name=this.constructor.name,this.failures=()=>r??(r=[t,...n()])}}function Hk(e){return Pi(e)&&typeof e[Symbol.iterator]=="function"}function Pi(e){return typeof e=="object"&&e!=null}function _r(e){return typeof e=="symbol"?e.toString():typeof e=="string"?JSON.stringify(e):`${e}`}function qk(e){const{done:t,value:n}=e.next();return t?void 0:n}function Wk(e,t,n,r){if(e===!0)return;e===!1?e={}:typeof e=="string"&&(e={message:e});const{path:i,branch:o}=t,{type:a}=n,{refinement:s,message:c=`Expected a value of type \`${a}\`${s?` with refinement \`${s}\``:""}, but received: \`${_r(r)}\``}=e;return{value:r,type:a,refinement:s,key:i[i.length-1],path:i,branch:o,...e,message:c}}function*P0(e,t,n,r){Hk(e)||(e=[e]);for(const i of e){const o=Wk(i,t,n,r);o&&(yield o)}}function*i1(e,t,n={}){const{path:r=[],branch:i=[e],coerce:o=!1,mask:a=!1}=n,s={path:r,branch:i};if(o&&(e=t.coercer(e,s),a&&t.type!=="type"&&Pi(t.schema)&&Pi(e)&&!Array.isArray(e)))for(const l in e)t.schema[l]===void 0&&delete e[l];let c="valid";for(const l of t.validator(e,s))l.explanation=n.message,c="not_valid",yield[l,void 0];for(let[l,u,d]of t.entries(e,s)){const f=i1(u,d,{path:l===void 0?r:[...r,l],branch:l===void 0?i:[...i,u],coerce:o,mask:a,message:n.message});for(const h of f)h[0]?(c=h[0].refinement!=null?"not_refined":"not_valid",yield[h[0],void 0]):o&&(u=h[1],l===void 0?e=u:e instanceof Map?e.set(l,u):e instanceof Set?e.add(u):Pi(e)&&(u!==void 0||l in e)&&(e[l]=u))}if(c!=="not_valid")for(const l of t.refiner(e,s))l.explanation=n.message,c="not_refined",yield[l,void 0];c==="valid"&&(yield[void 0,e])}class so{constructor(t){const{type:n,schema:r,validator:i,refiner:o,coercer:a=c=>c,entries:s=function*(){}}=t;this.type=n,this.schema=r,this.entries=s,this.coercer=a,i?this.validator=(c,l)=>{const u=i(c,l);return P0(u,l,this,c)}:this.validator=()=>[],o?this.refiner=(c,l)=>{const u=o(c,l);return P0(u,l,this,c)}:this.refiner=()=>[]}assert(t,n){return G3(t,this,n)}create(t,n){return Gk(t,this,n)}is(t){return K3(t,this)}mask(t,n){return Kk(t,this,n)}validate(t,n={}){return Ea(t,this,n)}}function G3(e,t,n){const r=Ea(e,t,{message:n});if(r[0])throw r[0]}function Gk(e,t,n){const r=Ea(e,t,{coerce:!0,message:n});if(r[0])throw r[0];return r[1]}function Kk(e,t,n){const r=Ea(e,t,{coerce:!0,mask:!0,message:n});if(r[0])throw r[0];return r[1]}function K3(e,t){return!Ea(e,t)[0]}function Ea(e,t,n={}){const r=i1(e,t,n),i=qk(r);return i[0]?[new Bk(i[0],function*(){for(const a of r)a[0]&&(yield a[0])}),void 0]:[void 0,i[1]]}function lo(e,t){return new so({type:e,schema:null,validator:t})}function co(){return lo("any",()=>!0)}function Qk(e){return new so({type:"array",schema:e,*entries(t){if(e&&Array.isArray(t))for(const[n,r]of t.entries())yield[n,r,e]},coercer(t){return Array.isArray(t)?t.slice():t},validator(t){return Array.isArray(t)||`Expected an array value, but received: ${_r(t)}`}})}function Yk(e){const t={},n=e.map(r=>_r(r)).join();for(const r of e)t[r]=r;return new so({type:"enums",schema:t,validator(r){return e.includes(r)||`Expected one of \`${n}\`, but received: ${_r(r)}`}})}function td(){return lo("number",e=>typeof e=="number"&&!isNaN(e)||`Expected a number, but received: ${_r(e)}`)}function Kc(e,t){return new so({type:"record",schema:null,*entries(n){if(Pi(n))for(const r in n){const i=n[r];yield[r,r,e],yield[r,i,t]}},validator(n){return Pi(n)||`Expected an object, but received: ${_r(n)}`}})}function Kt(){return lo("string",e=>typeof e=="string"||`Expected a string, but received: ${_r(e)}`)}function nd(e){const t=e.map(n=>n.type).join(" | ");return new so({type:"union",schema:null,coercer(n){for(const r of e){const[i,o]=r.validate(n,{coerce:!0});if(!i)return o}return n},validator(n,r){const i=[];for(const o of e){const[...a]=i1(n,o,r),[s]=a;if(s[0])for(const[c]of a)c&&i.push(c);else return[]}return[`Expected the value to satisfy a union of \`${t}\`, but received: ${_r(n)}`,...i]}})}function rd(e,t,n={}){const{exclusive:r}=n;return Sa(e,"min",i=>r?i>t:i>=t||`Expected a ${e.type} greater than ${r?"":"or equal to "}${t} but received \`${i}\``)}function fr(e,t,n=t){const r=`Expected a ${e.type}`,i=t===n?`of \`${t}\``:`between \`${t}\` and \`${n}\``;return Sa(e,"size",o=>{if(typeof o=="number"||o instanceof Date)return t<=o&&o<=n||`${r} ${i} but received \`${o}\``;if(o instanceof Map||o instanceof Set){const{size:a}=o;return t<=a&&a<=n||`${r} with a size ${i} but received one with a size of \`${a}\``}else{const{length:a}=o;return t<=a&&a<=n||`${r} with a length ${i} but received one with a length of \`${a}\``}})}function Sa(e,t,n){return new so({...e,*refiner(r,i){yield*e.refiner(r,i);const o=n(r,i),a=P0(o,i,e,r);for(const s of a)yield{...s,refinement:t}}})}const Q3=e=>{const t={};if(e){const f={};for(const h of Object.keys(e))f[h]={value:e[h],error:void 0};e=f}const[n,r]=kr(e||{}),i=({key:f,value:h})=>{r(f,{value:h,error:void 0})},o=f=>{let h=0;for(const p in n)f.includes(p)&&n[p]?.error&&(h+=1);return h>0},a=f=>{let h=[];for(const p in n)f.includes(p)&&n[p]?.error&&(h=[...h,{key:p,error:n[p]?.error??""}]);return h},s=f=>{for(const h of f)r(h,void 0)};return{store:n,actions:{updateFormValue:i,clearKeys:s,registerValidator:({key:f,validator:h})=>{if(f in t){t[f]=[...t[f],h];return}t[f]=[h]},unRegisterValidator:f=>{delete t[f]},validate:f=>{Object.entries(n).filter(([h])=>f?f.includes(h):!0).forEach(([h,p])=>{t[h]&&t[h].forEach(m=>{try{G3(p?.value,m)}catch(v){for(const b of v.failures())r(h,{value:p?.value,error:b.message})}})})},hasErrors:o,getErrors:a,reset:()=>{const f=Object.keys(n);s(f);const h=Object.keys(t);for(const p of h)delete t[p]}}}};function Wt(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function Ue(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function ys(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?ys=function(n){return typeof n}:ys=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ys(e)}function ft(e){Ue(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||ys(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function Xk(e,t){Ue(2,arguments);var n=ft(e).getTime(),r=Wt(t);return new Date(n+r)}var Zk={};function uo(){return Zk}function Y3(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}function M5(e){Ue(1,arguments);var t=ft(e);return t.setHours(0,0,0,0),t}var Jk=6e4,X3=36e5,eE=1e3;function tE(e,t){Ue(2,arguments);var n=M5(e),r=M5(t);return n.getTime()===r.getTime()}function bs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?bs=function(n){return typeof n}:bs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},bs(e)}function nE(e){return Ue(1,arguments),e instanceof Date||bs(e)==="object"&&Object.prototype.toString.call(e)==="[object Date]"}function rE(e){if(Ue(1,arguments),!nE(e)&&typeof e!="number")return!1;var t=ft(e);return!isNaN(Number(t))}function iE(e,t){return Ue(2,arguments),ft(e).getTime()-ft(t).getTime()}var D5={ceil:Math.ceil,round:Math.round,floor:Math.floor,trunc:function(t){return t<0?Math.ceil(t):Math.floor(t)}},oE="trunc";function aE(e){return e?D5[e]:D5[oE]}function sE(e,t,n){Ue(2,arguments);var r=iE(e,t)/X3;return aE(n?.roundingMethod)(r)}function Z3(e,t){Ue(2,arguments);var n=Wt(t);return Xk(e,-n)}var lE=864e5;function cE(e){Ue(1,arguments);var t=ft(e),n=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var r=t.getTime(),i=n-r;return Math.floor(i/lE)+1}function Hi(e){Ue(1,arguments);var t=1,n=ft(e),r=n.getUTCDay(),i=(r<t?7:0)+r-t;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function J3(e){Ue(1,arguments);var t=ft(e),n=t.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=Hi(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var a=Hi(o);return t.getTime()>=i.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function uE(e){Ue(1,arguments);var t=J3(e),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var r=Hi(n);return r}var dE=6048e5;function eb(e){Ue(1,arguments);var t=ft(e),n=Hi(t).getTime()-uE(t).getTime();return Math.round(n/dE)+1}function Qr(e,t){var n,r,i,o,a,s,c,l;Ue(1,arguments);var u=uo(),d=Wt((n=(r=(i=(o=t?.weekStartsOn)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.weekStartsOn)!==null&&i!==void 0?i:u.weekStartsOn)!==null&&r!==void 0?r:(c=u.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&n!==void 0?n:0);if(!(d>=0&&d<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var f=ft(e),h=f.getUTCDay(),p=(h<d?7:0)+h-d;return f.setUTCDate(f.getUTCDate()-p),f.setUTCHours(0,0,0,0),f}function o1(e,t){var n,r,i,o,a,s,c,l;Ue(1,arguments);var u=ft(e),d=u.getUTCFullYear(),f=uo(),h=Wt((n=(r=(i=(o=t?.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&i!==void 0?i:f.firstWeekContainsDate)!==null&&r!==void 0?r:(c=f.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(h>=1&&h<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var p=new Date(0);p.setUTCFullYear(d+1,0,h),p.setUTCHours(0,0,0,0);var m=Qr(p,t),v=new Date(0);v.setUTCFullYear(d,0,h),v.setUTCHours(0,0,0,0);var b=Qr(v,t);return u.getTime()>=m.getTime()?d+1:u.getTime()>=b.getTime()?d:d-1}function fE(e,t){var n,r,i,o,a,s,c,l;Ue(1,arguments);var u=uo(),d=Wt((n=(r=(i=(o=t?.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&i!==void 0?i:u.firstWeekContainsDate)!==null&&r!==void 0?r:(c=u.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&n!==void 0?n:1),f=o1(e,t),h=new Date(0);h.setUTCFullYear(f,0,d),h.setUTCHours(0,0,0,0);var p=Qr(h,t);return p}var hE=6048e5;function tb(e,t){Ue(1,arguments);var n=ft(e),r=Qr(n,t).getTime()-fE(n,t).getTime();return Math.round(r/hE)+1}function Te(e,t){for(var n=e<0?"-":"",r=Math.abs(e).toString();r.length<t;)r="0"+r;return n+r}var pE={y:function(t,n){var r=t.getUTCFullYear(),i=r>0?r:1-r;return Te(n==="yy"?i%100:i,n.length)},M:function(t,n){var r=t.getUTCMonth();return n==="M"?String(r+1):Te(r+1,2)},d:function(t,n){return Te(t.getUTCDate(),n.length)},a:function(t,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.toUpperCase();case"aaa":return r;case"aaaaa":return r[0];case"aaaa":default:return r==="am"?"a.m.":"p.m."}},h:function(t,n){return Te(t.getUTCHours()%12||12,n.length)},H:function(t,n){return Te(t.getUTCHours(),n.length)},m:function(t,n){return Te(t.getUTCMinutes(),n.length)},s:function(t,n){return Te(t.getUTCSeconds(),n.length)},S:function(t,n){var r=n.length,i=t.getUTCMilliseconds(),o=Math.floor(i*Math.pow(10,r-3));return Te(o,n.length)}};const Jn=pE;var ui={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},mE={G:function(t,n,r){var i=t.getUTCFullYear()>0?1:0;switch(n){case"G":case"GG":case"GGG":return r.era(i,{width:"abbreviated"});case"GGGGG":return r.era(i,{width:"narrow"});case"GGGG":default:return r.era(i,{width:"wide"})}},y:function(t,n,r){if(n==="yo"){var i=t.getUTCFullYear(),o=i>0?i:1-i;return r.ordinalNumber(o,{unit:"year"})}return Jn.y(t,n)},Y:function(t,n,r,i){var o=o1(t,i),a=o>0?o:1-o;if(n==="YY"){var s=a%100;return Te(s,2)}return n==="Yo"?r.ordinalNumber(a,{unit:"year"}):Te(a,n.length)},R:function(t,n){var r=J3(t);return Te(r,n.length)},u:function(t,n){var r=t.getUTCFullYear();return Te(r,n.length)},Q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"Q":return String(i);case"QQ":return Te(i,2);case"Qo":return r.ordinalNumber(i,{unit:"quarter"});case"QQQ":return r.quarter(i,{width:"abbreviated",context:"formatting"});case"QQQQQ":return r.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return r.quarter(i,{width:"wide",context:"formatting"})}},q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"q":return String(i);case"qq":return Te(i,2);case"qo":return r.ordinalNumber(i,{unit:"quarter"});case"qqq":return r.quarter(i,{width:"abbreviated",context:"standalone"});case"qqqqq":return r.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return r.quarter(i,{width:"wide",context:"standalone"})}},M:function(t,n,r){var i=t.getUTCMonth();switch(n){case"M":case"MM":return Jn.M(t,n);case"Mo":return r.ordinalNumber(i+1,{unit:"month"});case"MMM":return r.month(i,{width:"abbreviated",context:"formatting"});case"MMMMM":return r.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return r.month(i,{width:"wide",context:"formatting"})}},L:function(t,n,r){var i=t.getUTCMonth();switch(n){case"L":return String(i+1);case"LL":return Te(i+1,2);case"Lo":return r.ordinalNumber(i+1,{unit:"month"});case"LLL":return r.month(i,{width:"abbreviated",context:"standalone"});case"LLLLL":return r.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return r.month(i,{width:"wide",context:"standalone"})}},w:function(t,n,r,i){var o=tb(t,i);return n==="wo"?r.ordinalNumber(o,{unit:"week"}):Te(o,n.length)},I:function(t,n,r){var i=eb(t);return n==="Io"?r.ordinalNumber(i,{unit:"week"}):Te(i,n.length)},d:function(t,n,r){return n==="do"?r.ordinalNumber(t.getUTCDate(),{unit:"date"}):Jn.d(t,n)},D:function(t,n,r){var i=cE(t);return n==="Do"?r.ordinalNumber(i,{unit:"dayOfYear"}):Te(i,n.length)},E:function(t,n,r){var i=t.getUTCDay();switch(n){case"E":case"EE":case"EEE":return r.day(i,{width:"abbreviated",context:"formatting"});case"EEEEE":return r.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return r.day(i,{width:"short",context:"formatting"});case"EEEE":default:return r.day(i,{width:"wide",context:"formatting"})}},e:function(t,n,r,i){var o=t.getUTCDay(),a=(o-i.weekStartsOn+8)%7||7;switch(n){case"e":return String(a);case"ee":return Te(a,2);case"eo":return r.ordinalNumber(a,{unit:"day"});case"eee":return r.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return r.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return r.day(o,{width:"short",context:"formatting"});case"eeee":default:return r.day(o,{width:"wide",context:"formatting"})}},c:function(t,n,r,i){var o=t.getUTCDay(),a=(o-i.weekStartsOn+8)%7||7;switch(n){case"c":return String(a);case"cc":return Te(a,n.length);case"co":return r.ordinalNumber(a,{unit:"day"});case"ccc":return r.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return r.day(o,{width:"narrow",context:"standalone"});case"cccccc":return r.day(o,{width:"short",context:"standalone"});case"cccc":default:return r.day(o,{width:"wide",context:"standalone"})}},i:function(t,n,r){var i=t.getUTCDay(),o=i===0?7:i;switch(n){case"i":return String(o);case"ii":return Te(o,n.length);case"io":return r.ordinalNumber(o,{unit:"day"});case"iii":return r.day(i,{width:"abbreviated",context:"formatting"});case"iiiii":return r.day(i,{width:"narrow",context:"formatting"});case"iiiiii":return r.day(i,{width:"short",context:"formatting"});case"iiii":default:return r.day(i,{width:"wide",context:"formatting"})}},a:function(t,n,r){var i=t.getUTCHours(),o=i/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(t,n,r){var i=t.getUTCHours(),o;switch(i===12?o=ui.noon:i===0?o=ui.midnight:o=i/12>=1?"pm":"am",n){case"b":case"bb":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(t,n,r){var i=t.getUTCHours(),o;switch(i>=17?o=ui.evening:i>=12?o=ui.afternoon:i>=4?o=ui.morning:o=ui.night,n){case"B":case"BB":case"BBB":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(t,n,r){if(n==="ho"){var i=t.getUTCHours()%12;return i===0&&(i=12),r.ordinalNumber(i,{unit:"hour"})}return Jn.h(t,n)},H:function(t,n,r){return n==="Ho"?r.ordinalNumber(t.getUTCHours(),{unit:"hour"}):Jn.H(t,n)},K:function(t,n,r){var i=t.getUTCHours()%12;return n==="Ko"?r.ordinalNumber(i,{unit:"hour"}):Te(i,n.length)},k:function(t,n,r){var i=t.getUTCHours();return i===0&&(i=24),n==="ko"?r.ordinalNumber(i,{unit:"hour"}):Te(i,n.length)},m:function(t,n,r){return n==="mo"?r.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):Jn.m(t,n)},s:function(t,n,r){return n==="so"?r.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):Jn.s(t,n)},S:function(t,n){return Jn.S(t,n)},X:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();if(a===0)return"Z";switch(n){case"X":return R5(a);case"XXXX":case"XX":return Pr(a);case"XXXXX":case"XXX":default:return Pr(a,":")}},x:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"x":return R5(a);case"xxxx":case"xx":return Pr(a);case"xxxxx":case"xxx":default:return Pr(a,":")}},O:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"O":case"OO":case"OOO":return"GMT"+L5(a,":");case"OOOO":default:return"GMT"+Pr(a,":")}},z:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"z":case"zz":case"zzz":return"GMT"+L5(a,":");case"zzzz":default:return"GMT"+Pr(a,":")}},t:function(t,n,r,i){var o=i._originalDate||t,a=Math.floor(o.getTime()/1e3);return Te(a,n.length)},T:function(t,n,r,i){var o=i._originalDate||t,a=o.getTime();return Te(a,n.length)}};function L5(e,t){var n=e>0?"-":"+",r=Math.abs(e),i=Math.floor(r/60),o=r%60;if(o===0)return n+String(i);var a=t||"";return n+String(i)+a+Te(o,2)}function R5(e,t){if(e%60===0){var n=e>0?"-":"+";return n+Te(Math.abs(e)/60,2)}return Pr(e,t)}function Pr(e,t){var n=t||"",r=e>0?"-":"+",i=Math.abs(e),o=Te(Math.floor(i/60),2),a=Te(i%60,2);return r+o+n+a}const vE=mE;var F5=function(t,n){switch(t){case"P":return n.date({width:"short"});case"PP":return n.date({width:"medium"});case"PPP":return n.date({width:"long"});case"PPPP":default:return n.date({width:"full"})}},nb=function(t,n){switch(t){case"p":return n.time({width:"short"});case"pp":return n.time({width:"medium"});case"ppp":return n.time({width:"long"});case"pppp":default:return n.time({width:"full"})}},gE=function(t,n){var r=t.match(/(P+)(p+)?/)||[],i=r[1],o=r[2];if(!o)return F5(t,n);var a;switch(i){case"P":a=n.dateTime({width:"short"});break;case"PP":a=n.dateTime({width:"medium"});break;case"PPP":a=n.dateTime({width:"long"});break;case"PPPP":default:a=n.dateTime({width:"full"});break}return a.replace("{{date}}",F5(i,n)).replace("{{time}}",nb(o,n))},yE={p:nb,P:gE};const A0=yE;var bE=["D","DD"],$E=["YY","YYYY"];function rb(e){return bE.indexOf(e)!==-1}function ib(e){return $E.indexOf(e)!==-1}function Dl(e,t,n){if(e==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var wE={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},_E=function(t,n,r){var i,o=wE[t];return typeof o=="string"?i=o:n===1?i=o.one:i=o.other.replace("{{count}}",n.toString()),r!=null&&r.addSuffix?r.comparison&&r.comparison>0?"in "+i:i+" ago":i};const xE=_E;function id(e){return function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.width?String(t.width):e.defaultWidth,r=e.formats[n]||e.formats[e.defaultWidth];return r}}var kE={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},EE={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},SE={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},OE={date:id({formats:kE,defaultWidth:"full"}),time:id({formats:EE,defaultWidth:"full"}),dateTime:id({formats:SE,defaultWidth:"full"})};const CE=OE;var NE={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},TE=function(t,n,r,i){return NE[t]};const PE=TE;function No(e){return function(t,n){var r=n!=null&&n.context?String(n.context):"standalone",i;if(r==="formatting"&&e.formattingValues){var o=e.defaultFormattingWidth||e.defaultWidth,a=n!=null&&n.width?String(n.width):o;i=e.formattingValues[a]||e.formattingValues[o]}else{var s=e.defaultWidth,c=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[c]||e.values[s]}var l=e.argumentCallback?e.argumentCallback(t):t;return i[l]}}var AE={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},IE={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},ME={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},DE={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},LE={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},RE={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},FE=function(t,n){var r=Number(t),i=r%100;if(i>20||i<10)switch(i%10){case 1:return r+"st";case 2:return r+"nd";case 3:return r+"rd"}return r+"th"},zE={ordinalNumber:FE,era:No({values:AE,defaultWidth:"wide"}),quarter:No({values:IE,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:No({values:ME,defaultWidth:"wide"}),day:No({values:DE,defaultWidth:"wide"}),dayPeriod:No({values:LE,defaultWidth:"wide",formattingValues:RE,defaultFormattingWidth:"wide"})};const jE=zE;function To(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;var a=o[0],s=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(s)?UE(s,function(d){return d.test(a)}):VE(s,function(d){return d.test(a)}),l;l=e.valueCallback?e.valueCallback(c):c,l=n.valueCallback?n.valueCallback(l):l;var u=t.slice(a.length);return{value:l,rest:u}}}function VE(e,t){for(var n in e)if(e.hasOwnProperty(n)&&t(e[n]))return n}function UE(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return n}function BE(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.match(e.matchPattern);if(!r)return null;var i=r[0],o=t.match(e.parsePattern);if(!o)return null;var a=e.valueCallback?e.valueCallback(o[0]):o[0];a=n.valueCallback?n.valueCallback(a):a;var s=t.slice(i.length);return{value:a,rest:s}}}var HE=/^(\d+)(th|st|nd|rd)?/i,qE=/\d+/i,WE={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},GE={any:[/^b/i,/^(a|c)/i]},KE={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},QE={any:[/1/i,/2/i,/3/i,/4/i]},YE={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},XE={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},ZE={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},JE={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},eS={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},tS={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},nS={ordinalNumber:BE({matchPattern:HE,parsePattern:qE,valueCallback:function(t){return parseInt(t,10)}}),era:To({matchPatterns:WE,defaultMatchWidth:"wide",parsePatterns:GE,defaultParseWidth:"any"}),quarter:To({matchPatterns:KE,defaultMatchWidth:"wide",parsePatterns:QE,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:To({matchPatterns:YE,defaultMatchWidth:"wide",parsePatterns:XE,defaultParseWidth:"any"}),day:To({matchPatterns:ZE,defaultMatchWidth:"wide",parsePatterns:JE,defaultParseWidth:"any"}),dayPeriod:To({matchPatterns:eS,defaultMatchWidth:"any",parsePatterns:tS,defaultParseWidth:"any"})};const rS=nS;var iS={code:"en-US",formatDistance:xE,formatLong:CE,formatRelative:PE,localize:jE,match:rS,options:{weekStartsOn:0,firstWeekContainsDate:1}};const ob=iS;var oS=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,aS=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,sS=/^'([^]*?)'?$/,lS=/''/g,cS=/[a-zA-Z]/;function Qc(e,t,n){var r,i,o,a,s,c,l,u,d,f,h,p,m,v,b,y,g,_;Ue(2,arguments);var x=String(t),O=uo(),C=(r=(i=n?.locale)!==null&&i!==void 0?i:O.locale)!==null&&r!==void 0?r:ob,M=Wt((o=(a=(s=(c=n?.firstWeekContainsDate)!==null&&c!==void 0?c:n==null||(l=n.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&s!==void 0?s:O.firstWeekContainsDate)!==null&&a!==void 0?a:(d=O.locale)===null||d===void 0||(f=d.options)===null||f===void 0?void 0:f.firstWeekContainsDate)!==null&&o!==void 0?o:1);if(!(M>=1&&M<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var D=Wt((h=(p=(m=(v=n?.weekStartsOn)!==null&&v!==void 0?v:n==null||(b=n.locale)===null||b===void 0||(y=b.options)===null||y===void 0?void 0:y.weekStartsOn)!==null&&m!==void 0?m:O.weekStartsOn)!==null&&p!==void 0?p:(g=O.locale)===null||g===void 0||(_=g.options)===null||_===void 0?void 0:_.weekStartsOn)!==null&&h!==void 0?h:0);if(!(D>=0&&D<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!C.localize)throw new RangeError("locale must contain localize property");if(!C.formatLong)throw new RangeError("locale must contain formatLong property");var F=ft(e);if(!rE(F))throw new RangeError("Invalid time value");var Y=Y3(F),J=Z3(F,Y),G={firstWeekContainsDate:M,weekStartsOn:D,locale:C,_originalDate:F},j=x.match(aS).map(function(z){var Q=z[0];if(Q==="p"||Q==="P"){var I=A0[Q];return I(z,C.formatLong)}return z}).join("").match(oS).map(function(z){if(z==="''")return"'";var Q=z[0];if(Q==="'")return uS(z);var I=vE[Q];if(I)return!(n!=null&&n.useAdditionalWeekYearTokens)&&ib(z)&&Dl(z,t,String(e)),!(n!=null&&n.useAdditionalDayOfYearTokens)&&rb(z)&&Dl(z,t,String(e)),I(J,z,C.localize,G);if(Q.match(cS))throw new RangeError("Format string contains an unescaped latin alphabet character `"+Q+"`");return z}).join("");return j}function uS(e){var t=e.match(sS);return t?t[1].replace(lS,"'"):e}function dS(e,t){if(e==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}function $s(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?$s=function(n){return typeof n}:$s=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},$s(e)}function ab(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&I0(e,t)}function I0(e,t){return I0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},I0(e,t)}function sb(e){var t=hS();return function(){var r=Ll(e),i;if(t){var o=Ll(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return fS(this,i)}}function fS(e,t){return t&&($s(t)==="object"||typeof t=="function")?t:M0(e)}function M0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function hS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Ll(e){return Ll=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Ll(e)}function a1(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function z5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function s1(e,t,n){return t&&z5(e.prototype,t),n&&z5(e,n),e}function D0(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var pS=10,lb=function(){function e(){a1(this,e),D0(this,"subPriority",0)}return s1(e,[{key:"validate",value:function(n,r){return!0}}]),e}(),mS=function(e){ab(n,e);var t=sb(n);function n(r,i,o,a,s){var c;return a1(this,n),c=t.call(this),c.value=r,c.validateValue=i,c.setValue=o,c.priority=a,s&&(c.subPriority=s),c}return s1(n,[{key:"validate",value:function(i,o){return this.validateValue(i,this.value,o)}},{key:"set",value:function(i,o,a){return this.setValue(i,o,this.value,a)}}]),n}(lb),vS=function(e){ab(n,e);var t=sb(n);function n(){var r;a1(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),D0(M0(r),"priority",pS),D0(M0(r),"subPriority",-1),r}return s1(n,[{key:"set",value:function(i,o){if(o.timestampIsSet)return i;var a=new Date(0);return a.setFullYear(i.getUTCFullYear(),i.getUTCMonth(),i.getUTCDate()),a.setHours(i.getUTCHours(),i.getUTCMinutes(),i.getUTCSeconds(),i.getUTCMilliseconds()),a}}]),n}(lb);function gS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function j5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function yS(e,t,n){return t&&j5(e.prototype,t),n&&j5(e,n),e}var Oe=function(){function e(){gS(this,e)}return yS(e,[{key:"run",value:function(n,r,i,o){var a=this.parse(n,r,i,o);return a?{setter:new mS(a.value,this.validate,this.set,this.priority,this.subPriority),rest:a.rest}:null}},{key:"validate",value:function(n,r,i){return!0}}]),e}();function ws(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?ws=function(n){return typeof n}:ws=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ws(e)}function bS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function V5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function $S(e,t,n){return t&&V5(e.prototype,t),n&&V5(e,n),e}function wS(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&L0(e,t)}function L0(e,t){return L0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},L0(e,t)}function _S(e){var t=kS();return function(){var r=Rl(e),i;if(t){var o=Rl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return xS(this,i)}}function xS(e,t){return t&&(ws(t)==="object"||typeof t=="function")?t:R0(e)}function R0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function kS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Rl(e){return Rl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Rl(e)}function U5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ES=function(e){wS(n,e);var t=_S(n);function n(){var r;bS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),U5(R0(r),"priority",140),U5(R0(r),"incompatibleTokens",["R","u","t","T"]),r}return $S(n,[{key:"parse",value:function(i,o,a){switch(o){case"G":case"GG":case"GGG":return a.era(i,{width:"abbreviated"})||a.era(i,{width:"narrow"});case"GGGGG":return a.era(i,{width:"narrow"});case"GGGG":default:return a.era(i,{width:"wide"})||a.era(i,{width:"abbreviated"})||a.era(i,{width:"narrow"})}}},{key:"set",value:function(i,o,a){return o.era=a,i.setUTCFullYear(a,0,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe),et={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},kn={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function tt(e,t){return e&&{value:t(e.value),rest:e.rest}}function Ge(e,t){var n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function En(e,t){var n=t.match(e);if(!n)return null;if(n[0]==="Z")return{value:0,rest:t.slice(1)};var r=n[1]==="+"?1:-1,i=n[2]?parseInt(n[2],10):0,o=n[3]?parseInt(n[3],10):0,a=n[5]?parseInt(n[5],10):0;return{value:r*(i*X3+o*Jk+a*eE),rest:t.slice(n[0].length)}}function cb(e){return Ge(et.anyDigitsSigned,e)}function Ze(e,t){switch(e){case 1:return Ge(et.singleDigit,t);case 2:return Ge(et.twoDigits,t);case 3:return Ge(et.threeDigits,t);case 4:return Ge(et.fourDigits,t);default:return Ge(new RegExp("^\\d{1,"+e+"}"),t)}}function Fl(e,t){switch(e){case 1:return Ge(et.singleDigitSigned,t);case 2:return Ge(et.twoDigitsSigned,t);case 3:return Ge(et.threeDigitsSigned,t);case 4:return Ge(et.fourDigitsSigned,t);default:return Ge(new RegExp("^-?\\d{1,"+e+"}"),t)}}function l1(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function ub(e,t){var n=t>0,r=n?t:1-t,i;if(r<=50)i=e||100;else{var o=r+50,a=Math.floor(o/100)*100,s=e>=o%100;i=e+a-(s?100:0)}return n?i:1-i}function db(e){return e%400===0||e%4===0&&e%100!==0}function _s(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?_s=function(n){return typeof n}:_s=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},_s(e)}function SS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function B5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function OS(e,t,n){return t&&B5(e.prototype,t),n&&B5(e,n),e}function CS(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&F0(e,t)}function F0(e,t){return F0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},F0(e,t)}function NS(e){var t=PS();return function(){var r=zl(e),i;if(t){var o=zl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return TS(this,i)}}function TS(e,t){return t&&(_s(t)==="object"||typeof t=="function")?t:z0(e)}function z0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function PS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function zl(e){return zl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},zl(e)}function H5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var AS=function(e){CS(n,e);var t=NS(n);function n(){var r;SS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),H5(z0(r),"priority",130),H5(z0(r),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),r}return OS(n,[{key:"parse",value:function(i,o,a){var s=function(l){return{year:l,isTwoDigitYear:o==="yy"}};switch(o){case"y":return tt(Ze(4,i),s);case"yo":return tt(a.ordinalNumber(i,{unit:"year"}),s);default:return tt(Ze(o.length,i),s)}}},{key:"validate",value:function(i,o){return o.isTwoDigitYear||o.year>0}},{key:"set",value:function(i,o,a){var s=i.getUTCFullYear();if(a.isTwoDigitYear){var c=ub(a.year,s);return i.setUTCFullYear(c,0,1),i.setUTCHours(0,0,0,0),i}var l=!("era"in o)||o.era===1?a.year:1-a.year;return i.setUTCFullYear(l,0,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function xs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?xs=function(n){return typeof n}:xs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},xs(e)}function IS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function q5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function MS(e,t,n){return t&&q5(e.prototype,t),n&&q5(e,n),e}function DS(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&j0(e,t)}function j0(e,t){return j0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},j0(e,t)}function LS(e){var t=FS();return function(){var r=jl(e),i;if(t){var o=jl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return RS(this,i)}}function RS(e,t){return t&&(xs(t)==="object"||typeof t=="function")?t:V0(e)}function V0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function FS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function jl(e){return jl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},jl(e)}function W5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var zS=function(e){DS(n,e);var t=LS(n);function n(){var r;IS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),W5(V0(r),"priority",130),W5(V0(r),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),r}return MS(n,[{key:"parse",value:function(i,o,a){var s=function(l){return{year:l,isTwoDigitYear:o==="YY"}};switch(o){case"Y":return tt(Ze(4,i),s);case"Yo":return tt(a.ordinalNumber(i,{unit:"year"}),s);default:return tt(Ze(o.length,i),s)}}},{key:"validate",value:function(i,o){return o.isTwoDigitYear||o.year>0}},{key:"set",value:function(i,o,a,s){var c=o1(i,s);if(a.isTwoDigitYear){var l=ub(a.year,c);return i.setUTCFullYear(l,0,s.firstWeekContainsDate),i.setUTCHours(0,0,0,0),Qr(i,s)}var u=!("era"in o)||o.era===1?a.year:1-a.year;return i.setUTCFullYear(u,0,s.firstWeekContainsDate),i.setUTCHours(0,0,0,0),Qr(i,s)}}]),n}(Oe);function ks(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?ks=function(n){return typeof n}:ks=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ks(e)}function jS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function G5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function VS(e,t,n){return t&&G5(e.prototype,t),n&&G5(e,n),e}function US(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&U0(e,t)}function U0(e,t){return U0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},U0(e,t)}function BS(e){var t=qS();return function(){var r=Vl(e),i;if(t){var o=Vl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return HS(this,i)}}function HS(e,t){return t&&(ks(t)==="object"||typeof t=="function")?t:B0(e)}function B0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function qS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Vl(e){return Vl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Vl(e)}function K5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var WS=function(e){US(n,e);var t=BS(n);function n(){var r;jS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),K5(B0(r),"priority",130),K5(B0(r),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),r}return VS(n,[{key:"parse",value:function(i,o){return Fl(o==="R"?4:o.length,i)}},{key:"set",value:function(i,o,a){var s=new Date(0);return s.setUTCFullYear(a,0,4),s.setUTCHours(0,0,0,0),Hi(s)}}]),n}(Oe);function Es(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Es=function(n){return typeof n}:Es=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Es(e)}function GS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Q5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function KS(e,t,n){return t&&Q5(e.prototype,t),n&&Q5(e,n),e}function QS(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&H0(e,t)}function H0(e,t){return H0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},H0(e,t)}function YS(e){var t=ZS();return function(){var r=Ul(e),i;if(t){var o=Ul(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return XS(this,i)}}function XS(e,t){return t&&(Es(t)==="object"||typeof t=="function")?t:q0(e)}function q0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ZS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Ul(e){return Ul=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Ul(e)}function Y5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var JS=function(e){QS(n,e);var t=YS(n);function n(){var r;GS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Y5(q0(r),"priority",130),Y5(q0(r),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),r}return KS(n,[{key:"parse",value:function(i,o){return Fl(o==="u"?4:o.length,i)}},{key:"set",value:function(i,o,a){return i.setUTCFullYear(a,0,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Ss(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ss=function(n){return typeof n}:Ss=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ss(e)}function eO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function X5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function tO(e,t,n){return t&&X5(e.prototype,t),n&&X5(e,n),e}function nO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&W0(e,t)}function W0(e,t){return W0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},W0(e,t)}function rO(e){var t=oO();return function(){var r=Bl(e),i;if(t){var o=Bl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return iO(this,i)}}function iO(e,t){return t&&(Ss(t)==="object"||typeof t=="function")?t:G0(e)}function G0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function oO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Bl(e){return Bl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Bl(e)}function Z5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var aO=function(e){nO(n,e);var t=rO(n);function n(){var r;eO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Z5(G0(r),"priority",120),Z5(G0(r),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),r}return tO(n,[{key:"parse",value:function(i,o,a){switch(o){case"Q":case"QQ":return Ze(o.length,i);case"Qo":return a.ordinalNumber(i,{unit:"quarter"});case"QQQ":return a.quarter(i,{width:"abbreviated",context:"formatting"})||a.quarter(i,{width:"narrow",context:"formatting"});case"QQQQQ":return a.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return a.quarter(i,{width:"wide",context:"formatting"})||a.quarter(i,{width:"abbreviated",context:"formatting"})||a.quarter(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,o){return o>=1&&o<=4}},{key:"set",value:function(i,o,a){return i.setUTCMonth((a-1)*3,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Os(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Os=function(n){return typeof n}:Os=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Os(e)}function sO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function J5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function lO(e,t,n){return t&&J5(e.prototype,t),n&&J5(e,n),e}function cO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&K0(e,t)}function K0(e,t){return K0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},K0(e,t)}function uO(e){var t=fO();return function(){var r=Hl(e),i;if(t){var o=Hl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return dO(this,i)}}function dO(e,t){return t&&(Os(t)==="object"||typeof t=="function")?t:Q0(e)}function Q0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function fO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Hl(e){return Hl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Hl(e)}function em(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var hO=function(e){cO(n,e);var t=uO(n);function n(){var r;sO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),em(Q0(r),"priority",120),em(Q0(r),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),r}return lO(n,[{key:"parse",value:function(i,o,a){switch(o){case"q":case"qq":return Ze(o.length,i);case"qo":return a.ordinalNumber(i,{unit:"quarter"});case"qqq":return a.quarter(i,{width:"abbreviated",context:"standalone"})||a.quarter(i,{width:"narrow",context:"standalone"});case"qqqqq":return a.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return a.quarter(i,{width:"wide",context:"standalone"})||a.quarter(i,{width:"abbreviated",context:"standalone"})||a.quarter(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,o){return o>=1&&o<=4}},{key:"set",value:function(i,o,a){return i.setUTCMonth((a-1)*3,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Cs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Cs=function(n){return typeof n}:Cs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Cs(e)}function pO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function tm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function mO(e,t,n){return t&&tm(e.prototype,t),n&&tm(e,n),e}function vO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Y0(e,t)}function Y0(e,t){return Y0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Y0(e,t)}function gO(e){var t=bO();return function(){var r=ql(e),i;if(t){var o=ql(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return yO(this,i)}}function yO(e,t){return t&&(Cs(t)==="object"||typeof t=="function")?t:X0(e)}function X0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function bO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ql(e){return ql=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},ql(e)}function nm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var $O=function(e){vO(n,e);var t=gO(n);function n(){var r;pO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),nm(X0(r),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),nm(X0(r),"priority",110),r}return mO(n,[{key:"parse",value:function(i,o,a){var s=function(l){return l-1};switch(o){case"M":return tt(Ge(et.month,i),s);case"MM":return tt(Ze(2,i),s);case"Mo":return tt(a.ordinalNumber(i,{unit:"month"}),s);case"MMM":return a.month(i,{width:"abbreviated",context:"formatting"})||a.month(i,{width:"narrow",context:"formatting"});case"MMMMM":return a.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return a.month(i,{width:"wide",context:"formatting"})||a.month(i,{width:"abbreviated",context:"formatting"})||a.month(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=11}},{key:"set",value:function(i,o,a){return i.setUTCMonth(a,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Ns(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ns=function(n){return typeof n}:Ns=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ns(e)}function wO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function rm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _O(e,t,n){return t&&rm(e.prototype,t),n&&rm(e,n),e}function xO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Z0(e,t)}function Z0(e,t){return Z0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Z0(e,t)}function kO(e){var t=SO();return function(){var r=Wl(e),i;if(t){var o=Wl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return EO(this,i)}}function EO(e,t){return t&&(Ns(t)==="object"||typeof t=="function")?t:J0(e)}function J0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function SO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Wl(e){return Wl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Wl(e)}function im(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var OO=function(e){xO(n,e);var t=kO(n);function n(){var r;wO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),im(J0(r),"priority",110),im(J0(r),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),r}return _O(n,[{key:"parse",value:function(i,o,a){var s=function(l){return l-1};switch(o){case"L":return tt(Ge(et.month,i),s);case"LL":return tt(Ze(2,i),s);case"Lo":return tt(a.ordinalNumber(i,{unit:"month"}),s);case"LLL":return a.month(i,{width:"abbreviated",context:"standalone"})||a.month(i,{width:"narrow",context:"standalone"});case"LLLLL":return a.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return a.month(i,{width:"wide",context:"standalone"})||a.month(i,{width:"abbreviated",context:"standalone"})||a.month(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=11}},{key:"set",value:function(i,o,a){return i.setUTCMonth(a,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function CO(e,t,n){Ue(2,arguments);var r=ft(e),i=Wt(t),o=tb(r,n)-i;return r.setUTCDate(r.getUTCDate()-o*7),r}function Ts(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ts=function(n){return typeof n}:Ts=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ts(e)}function NO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function om(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function TO(e,t,n){return t&&om(e.prototype,t),n&&om(e,n),e}function PO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ef(e,t)}function ef(e,t){return ef=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},ef(e,t)}function AO(e){var t=MO();return function(){var r=Gl(e),i;if(t){var o=Gl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return IO(this,i)}}function IO(e,t){return t&&(Ts(t)==="object"||typeof t=="function")?t:tf(e)}function tf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function MO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Gl(e){return Gl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Gl(e)}function am(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var DO=function(e){PO(n,e);var t=AO(n);function n(){var r;NO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),am(tf(r),"priority",100),am(tf(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),r}return TO(n,[{key:"parse",value:function(i,o,a){switch(o){case"w":return Ge(et.week,i);case"wo":return a.ordinalNumber(i,{unit:"week"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=1&&o<=53}},{key:"set",value:function(i,o,a,s){return Qr(CO(i,a,s),s)}}]),n}(Oe);function LO(e,t){Ue(2,arguments);var n=ft(e),r=Wt(t),i=eb(n)-r;return n.setUTCDate(n.getUTCDate()-i*7),n}function Ps(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ps=function(n){return typeof n}:Ps=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ps(e)}function RO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function sm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function FO(e,t,n){return t&&sm(e.prototype,t),n&&sm(e,n),e}function zO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&nf(e,t)}function nf(e,t){return nf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},nf(e,t)}function jO(e){var t=UO();return function(){var r=Kl(e),i;if(t){var o=Kl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return VO(this,i)}}function VO(e,t){return t&&(Ps(t)==="object"||typeof t=="function")?t:rf(e)}function rf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function UO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Kl(e){return Kl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Kl(e)}function lm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var BO=function(e){zO(n,e);var t=jO(n);function n(){var r;RO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),lm(rf(r),"priority",100),lm(rf(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),r}return FO(n,[{key:"parse",value:function(i,o,a){switch(o){case"I":return Ge(et.week,i);case"Io":return a.ordinalNumber(i,{unit:"week"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=1&&o<=53}},{key:"set",value:function(i,o,a){return Hi(LO(i,a))}}]),n}(Oe);function As(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?As=function(n){return typeof n}:As=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},As(e)}function HO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function qO(e,t,n){return t&&cm(e.prototype,t),n&&cm(e,n),e}function WO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&of(e,t)}function of(e,t){return of=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},of(e,t)}function GO(e){var t=QO();return function(){var r=Ql(e),i;if(t){var o=Ql(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return KO(this,i)}}function KO(e,t){return t&&(As(t)==="object"||typeof t=="function")?t:Is(e)}function Is(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function QO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Ql(e){return Ql=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Ql(e)}function od(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var YO=[31,28,31,30,31,30,31,31,30,31,30,31],XO=[31,29,31,30,31,30,31,31,30,31,30,31],ZO=function(e){WO(n,e);var t=GO(n);function n(){var r;HO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),od(Is(r),"priority",90),od(Is(r),"subPriority",1),od(Is(r),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),r}return qO(n,[{key:"parse",value:function(i,o,a){switch(o){case"d":return Ge(et.date,i);case"do":return a.ordinalNumber(i,{unit:"date"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){var a=i.getUTCFullYear(),s=db(a),c=i.getUTCMonth();return s?o>=1&&o<=XO[c]:o>=1&&o<=YO[c]}},{key:"set",value:function(i,o,a){return i.setUTCDate(a),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Ms(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ms=function(n){return typeof n}:Ms=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ms(e)}function JO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function um(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function eC(e,t,n){return t&&um(e.prototype,t),n&&um(e,n),e}function tC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&af(e,t)}function af(e,t){return af=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},af(e,t)}function nC(e){var t=iC();return function(){var r=Yl(e),i;if(t){var o=Yl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return rC(this,i)}}function rC(e,t){return t&&(Ms(t)==="object"||typeof t=="function")?t:Ds(e)}function Ds(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function iC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Yl(e){return Yl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Yl(e)}function ad(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var oC=function(e){tC(n,e);var t=nC(n);function n(){var r;JO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),ad(Ds(r),"priority",90),ad(Ds(r),"subpriority",1),ad(Ds(r),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),r}return eC(n,[{key:"parse",value:function(i,o,a){switch(o){case"D":case"DD":return Ge(et.dayOfYear,i);case"Do":return a.ordinalNumber(i,{unit:"date"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){var a=i.getUTCFullYear(),s=db(a);return s?o>=1&&o<=366:o>=1&&o<=365}},{key:"set",value:function(i,o,a){return i.setUTCMonth(0,a),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function c1(e,t,n){var r,i,o,a,s,c,l,u;Ue(2,arguments);var d=uo(),f=Wt((r=(i=(o=(a=n?.weekStartsOn)!==null&&a!==void 0?a:n==null||(s=n.locale)===null||s===void 0||(c=s.options)===null||c===void 0?void 0:c.weekStartsOn)!==null&&o!==void 0?o:d.weekStartsOn)!==null&&i!==void 0?i:(l=d.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.weekStartsOn)!==null&&r!==void 0?r:0);if(!(f>=0&&f<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=ft(e),p=Wt(t),m=h.getUTCDay(),v=p%7,b=(v+7)%7,y=(b<f?7:0)+p-m;return h.setUTCDate(h.getUTCDate()+y),h}function Ls(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ls=function(n){return typeof n}:Ls=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ls(e)}function aC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function dm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function sC(e,t,n){return t&&dm(e.prototype,t),n&&dm(e,n),e}function lC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&sf(e,t)}function sf(e,t){return sf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},sf(e,t)}function cC(e){var t=dC();return function(){var r=Xl(e),i;if(t){var o=Xl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return uC(this,i)}}function uC(e,t){return t&&(Ls(t)==="object"||typeof t=="function")?t:lf(e)}function lf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function dC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Xl(e){return Xl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Xl(e)}function fm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var fC=function(e){lC(n,e);var t=cC(n);function n(){var r;aC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),fm(lf(r),"priority",90),fm(lf(r),"incompatibleTokens",["D","i","e","c","t","T"]),r}return sC(n,[{key:"parse",value:function(i,o,a){switch(o){case"E":case"EE":case"EEE":return a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"});case"EEEEE":return a.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"});case"EEEE":default:return a.day(i,{width:"wide",context:"formatting"})||a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=6}},{key:"set",value:function(i,o,a,s){return i=c1(i,a,s),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Rs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Rs=function(n){return typeof n}:Rs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Rs(e)}function hC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function pC(e,t,n){return t&&hm(e.prototype,t),n&&hm(e,n),e}function mC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&cf(e,t)}function cf(e,t){return cf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},cf(e,t)}function vC(e){var t=yC();return function(){var r=Zl(e),i;if(t){var o=Zl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return gC(this,i)}}function gC(e,t){return t&&(Rs(t)==="object"||typeof t=="function")?t:uf(e)}function uf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Zl(e){return Zl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Zl(e)}function pm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var bC=function(e){mC(n,e);var t=vC(n);function n(){var r;hC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),pm(uf(r),"priority",90),pm(uf(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),r}return pC(n,[{key:"parse",value:function(i,o,a,s){var c=function(u){var d=Math.floor((u-1)/7)*7;return(u+s.weekStartsOn+6)%7+d};switch(o){case"e":case"ee":return tt(Ze(o.length,i),c);case"eo":return tt(a.ordinalNumber(i,{unit:"day"}),c);case"eee":return a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"});case"eeeee":return a.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"});case"eeee":default:return a.day(i,{width:"wide",context:"formatting"})||a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=6}},{key:"set",value:function(i,o,a,s){return i=c1(i,a,s),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Fs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Fs=function(n){return typeof n}:Fs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Fs(e)}function $C(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function mm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function wC(e,t,n){return t&&mm(e.prototype,t),n&&mm(e,n),e}function _C(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&df(e,t)}function df(e,t){return df=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},df(e,t)}function xC(e){var t=EC();return function(){var r=Jl(e),i;if(t){var o=Jl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return kC(this,i)}}function kC(e,t){return t&&(Fs(t)==="object"||typeof t=="function")?t:ff(e)}function ff(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function EC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Jl(e){return Jl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Jl(e)}function vm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var SC=function(e){_C(n,e);var t=xC(n);function n(){var r;$C(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),vm(ff(r),"priority",90),vm(ff(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),r}return wC(n,[{key:"parse",value:function(i,o,a,s){var c=function(u){var d=Math.floor((u-1)/7)*7;return(u+s.weekStartsOn+6)%7+d};switch(o){case"c":case"cc":return tt(Ze(o.length,i),c);case"co":return tt(a.ordinalNumber(i,{unit:"day"}),c);case"ccc":return a.day(i,{width:"abbreviated",context:"standalone"})||a.day(i,{width:"short",context:"standalone"})||a.day(i,{width:"narrow",context:"standalone"});case"ccccc":return a.day(i,{width:"narrow",context:"standalone"});case"cccccc":return a.day(i,{width:"short",context:"standalone"})||a.day(i,{width:"narrow",context:"standalone"});case"cccc":default:return a.day(i,{width:"wide",context:"standalone"})||a.day(i,{width:"abbreviated",context:"standalone"})||a.day(i,{width:"short",context:"standalone"})||a.day(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=6}},{key:"set",value:function(i,o,a,s){return i=c1(i,a,s),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function OC(e,t){Ue(2,arguments);var n=Wt(t);n%7===0&&(n=n-7);var r=1,i=ft(e),o=i.getUTCDay(),a=n%7,s=(a+7)%7,c=(s<r?7:0)+n-o;return i.setUTCDate(i.getUTCDate()+c),i}function zs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?zs=function(n){return typeof n}:zs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},zs(e)}function CC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function gm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function NC(e,t,n){return t&&gm(e.prototype,t),n&&gm(e,n),e}function TC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&hf(e,t)}function hf(e,t){return hf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},hf(e,t)}function PC(e){var t=IC();return function(){var r=ec(e),i;if(t){var o=ec(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return AC(this,i)}}function AC(e,t){return t&&(zs(t)==="object"||typeof t=="function")?t:pf(e)}function pf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function IC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ec(e){return ec=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},ec(e)}function ym(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var MC=function(e){TC(n,e);var t=PC(n);function n(){var r;CC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),ym(pf(r),"priority",90),ym(pf(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),r}return NC(n,[{key:"parse",value:function(i,o,a){var s=function(l){return l===0?7:l};switch(o){case"i":case"ii":return Ze(o.length,i);case"io":return a.ordinalNumber(i,{unit:"day"});case"iii":return tt(a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"}),s);case"iiiii":return tt(a.day(i,{width:"narrow",context:"formatting"}),s);case"iiiiii":return tt(a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"}),s);case"iiii":default:return tt(a.day(i,{width:"wide",context:"formatting"})||a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"}),s)}}},{key:"validate",value:function(i,o){return o>=1&&o<=7}},{key:"set",value:function(i,o,a){return i=OC(i,a),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function js(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?js=function(n){return typeof n}:js=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},js(e)}function DC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function bm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function LC(e,t,n){return t&&bm(e.prototype,t),n&&bm(e,n),e}function RC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&mf(e,t)}function mf(e,t){return mf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},mf(e,t)}function FC(e){var t=jC();return function(){var r=tc(e),i;if(t){var o=tc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return zC(this,i)}}function zC(e,t){return t&&(js(t)==="object"||typeof t=="function")?t:vf(e)}function vf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function jC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function tc(e){return tc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},tc(e)}function $m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var VC=function(e){RC(n,e);var t=FC(n);function n(){var r;DC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),$m(vf(r),"priority",80),$m(vf(r),"incompatibleTokens",["b","B","H","k","t","T"]),r}return LC(n,[{key:"parse",value:function(i,o,a){switch(o){case"a":case"aa":case"aaa":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaaa":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})||a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,o,a){return i.setUTCHours(l1(a),0,0,0),i}}]),n}(Oe);function Vs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Vs=function(n){return typeof n}:Vs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Vs(e)}function UC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function wm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function BC(e,t,n){return t&&wm(e.prototype,t),n&&wm(e,n),e}function HC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&gf(e,t)}function gf(e,t){return gf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},gf(e,t)}function qC(e){var t=GC();return function(){var r=nc(e),i;if(t){var o=nc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return WC(this,i)}}function WC(e,t){return t&&(Vs(t)==="object"||typeof t=="function")?t:yf(e)}function yf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function GC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function nc(e){return nc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},nc(e)}function _m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var KC=function(e){HC(n,e);var t=qC(n);function n(){var r;UC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),_m(yf(r),"priority",80),_m(yf(r),"incompatibleTokens",["a","B","H","k","t","T"]),r}return BC(n,[{key:"parse",value:function(i,o,a){switch(o){case"b":case"bb":case"bbb":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbbb":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})||a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,o,a){return i.setUTCHours(l1(a),0,0,0),i}}]),n}(Oe);function Us(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Us=function(n){return typeof n}:Us=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Us(e)}function QC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function xm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function YC(e,t,n){return t&&xm(e.prototype,t),n&&xm(e,n),e}function XC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&bf(e,t)}function bf(e,t){return bf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},bf(e,t)}function ZC(e){var t=eN();return function(){var r=rc(e),i;if(t){var o=rc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return JC(this,i)}}function JC(e,t){return t&&(Us(t)==="object"||typeof t=="function")?t:$f(e)}function $f(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function eN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function rc(e){return rc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},rc(e)}function km(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var tN=function(e){XC(n,e);var t=ZC(n);function n(){var r;QC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),km($f(r),"priority",80),km($f(r),"incompatibleTokens",["a","b","t","T"]),r}return YC(n,[{key:"parse",value:function(i,o,a){switch(o){case"B":case"BB":case"BBB":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBBB":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})||a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,o,a){return i.setUTCHours(l1(a),0,0,0),i}}]),n}(Oe);function Bs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Bs=function(n){return typeof n}:Bs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Bs(e)}function nN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Em(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function rN(e,t,n){return t&&Em(e.prototype,t),n&&Em(e,n),e}function iN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&wf(e,t)}function wf(e,t){return wf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},wf(e,t)}function oN(e){var t=sN();return function(){var r=ic(e),i;if(t){var o=ic(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return aN(this,i)}}function aN(e,t){return t&&(Bs(t)==="object"||typeof t=="function")?t:_f(e)}function _f(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function sN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ic(e){return ic=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},ic(e)}function Sm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var lN=function(e){iN(n,e);var t=oN(n);function n(){var r;nN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Sm(_f(r),"priority",70),Sm(_f(r),"incompatibleTokens",["H","K","k","t","T"]),r}return rN(n,[{key:"parse",value:function(i,o,a){switch(o){case"h":return Ge(et.hour12h,i);case"ho":return a.ordinalNumber(i,{unit:"hour"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=1&&o<=12}},{key:"set",value:function(i,o,a){var s=i.getUTCHours()>=12;return s&&a<12?i.setUTCHours(a+12,0,0,0):!s&&a===12?i.setUTCHours(0,0,0,0):i.setUTCHours(a,0,0,0),i}}]),n}(Oe);function Hs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Hs=function(n){return typeof n}:Hs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Hs(e)}function cN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Om(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function uN(e,t,n){return t&&Om(e.prototype,t),n&&Om(e,n),e}function dN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&xf(e,t)}function xf(e,t){return xf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},xf(e,t)}function fN(e){var t=pN();return function(){var r=oc(e),i;if(t){var o=oc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return hN(this,i)}}function hN(e,t){return t&&(Hs(t)==="object"||typeof t=="function")?t:kf(e)}function kf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function pN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function oc(e){return oc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},oc(e)}function Cm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var mN=function(e){dN(n,e);var t=fN(n);function n(){var r;cN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Cm(kf(r),"priority",70),Cm(kf(r),"incompatibleTokens",["a","b","h","K","k","t","T"]),r}return uN(n,[{key:"parse",value:function(i,o,a){switch(o){case"H":return Ge(et.hour23h,i);case"Ho":return a.ordinalNumber(i,{unit:"hour"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=0&&o<=23}},{key:"set",value:function(i,o,a){return i.setUTCHours(a,0,0,0),i}}]),n}(Oe);function qs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?qs=function(n){return typeof n}:qs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},qs(e)}function vN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Nm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function gN(e,t,n){return t&&Nm(e.prototype,t),n&&Nm(e,n),e}function yN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ef(e,t)}function Ef(e,t){return Ef=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Ef(e,t)}function bN(e){var t=wN();return function(){var r=ac(e),i;if(t){var o=ac(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return $N(this,i)}}function $N(e,t){return t&&(qs(t)==="object"||typeof t=="function")?t:Sf(e)}function Sf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ac(e){return ac=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},ac(e)}function Tm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var _N=function(e){yN(n,e);var t=bN(n);function n(){var r;vN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Tm(Sf(r),"priority",70),Tm(Sf(r),"incompatibleTokens",["h","H","k","t","T"]),r}return gN(n,[{key:"parse",value:function(i,o,a){switch(o){case"K":return Ge(et.hour11h,i);case"Ko":return a.ordinalNumber(i,{unit:"hour"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=0&&o<=11}},{key:"set",value:function(i,o,a){var s=i.getUTCHours()>=12;return s&&a<12?i.setUTCHours(a+12,0,0,0):i.setUTCHours(a,0,0,0),i}}]),n}(Oe);function Ws(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ws=function(n){return typeof n}:Ws=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ws(e)}function xN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Pm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function kN(e,t,n){return t&&Pm(e.prototype,t),n&&Pm(e,n),e}function EN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Of(e,t)}function Of(e,t){return Of=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Of(e,t)}function SN(e){var t=CN();return function(){var r=sc(e),i;if(t){var o=sc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return ON(this,i)}}function ON(e,t){return t&&(Ws(t)==="object"||typeof t=="function")?t:Cf(e)}function Cf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function CN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function sc(e){return sc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},sc(e)}function Am(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var NN=function(e){EN(n,e);var t=SN(n);function n(){var r;xN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Am(Cf(r),"priority",70),Am(Cf(r),"incompatibleTokens",["a","b","h","H","K","t","T"]),r}return kN(n,[{key:"parse",value:function(i,o,a){switch(o){case"k":return Ge(et.hour24h,i);case"ko":return a.ordinalNumber(i,{unit:"hour"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=1&&o<=24}},{key:"set",value:function(i,o,a){var s=a<=24?a%24:a;return i.setUTCHours(s,0,0,0),i}}]),n}(Oe);function Gs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Gs=function(n){return typeof n}:Gs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Gs(e)}function TN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Im(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function PN(e,t,n){return t&&Im(e.prototype,t),n&&Im(e,n),e}function AN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Nf(e,t)}function Nf(e,t){return Nf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Nf(e,t)}function IN(e){var t=DN();return function(){var r=lc(e),i;if(t){var o=lc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return MN(this,i)}}function MN(e,t){return t&&(Gs(t)==="object"||typeof t=="function")?t:Tf(e)}function Tf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function DN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function lc(e){return lc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},lc(e)}function Mm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var LN=function(e){AN(n,e);var t=IN(n);function n(){var r;TN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Mm(Tf(r),"priority",60),Mm(Tf(r),"incompatibleTokens",["t","T"]),r}return PN(n,[{key:"parse",value:function(i,o,a){switch(o){case"m":return Ge(et.minute,i);case"mo":return a.ordinalNumber(i,{unit:"minute"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=0&&o<=59}},{key:"set",value:function(i,o,a){return i.setUTCMinutes(a,0,0),i}}]),n}(Oe);function Ks(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ks=function(n){return typeof n}:Ks=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ks(e)}function RN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Dm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function FN(e,t,n){return t&&Dm(e.prototype,t),n&&Dm(e,n),e}function zN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Pf(e,t)}function Pf(e,t){return Pf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Pf(e,t)}function jN(e){var t=UN();return function(){var r=cc(e),i;if(t){var o=cc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return VN(this,i)}}function VN(e,t){return t&&(Ks(t)==="object"||typeof t=="function")?t:Af(e)}function Af(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function UN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function cc(e){return cc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},cc(e)}function Lm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var BN=function(e){zN(n,e);var t=jN(n);function n(){var r;RN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Lm(Af(r),"priority",50),Lm(Af(r),"incompatibleTokens",["t","T"]),r}return FN(n,[{key:"parse",value:function(i,o,a){switch(o){case"s":return Ge(et.second,i);case"so":return a.ordinalNumber(i,{unit:"second"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=0&&o<=59}},{key:"set",value:function(i,o,a){return i.setUTCSeconds(a,0),i}}]),n}(Oe);function Qs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Qs=function(n){return typeof n}:Qs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Qs(e)}function HN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Rm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function qN(e,t,n){return t&&Rm(e.prototype,t),n&&Rm(e,n),e}function WN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&If(e,t)}function If(e,t){return If=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},If(e,t)}function GN(e){var t=QN();return function(){var r=uc(e),i;if(t){var o=uc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return KN(this,i)}}function KN(e,t){return t&&(Qs(t)==="object"||typeof t=="function")?t:Mf(e)}function Mf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function QN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function uc(e){return uc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},uc(e)}function Fm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var YN=function(e){WN(n,e);var t=GN(n);function n(){var r;HN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Fm(Mf(r),"priority",30),Fm(Mf(r),"incompatibleTokens",["t","T"]),r}return qN(n,[{key:"parse",value:function(i,o){var a=function(c){return Math.floor(c*Math.pow(10,-o.length+3))};return tt(Ze(o.length,i),a)}},{key:"set",value:function(i,o,a){return i.setUTCMilliseconds(a),i}}]),n}(Oe);function Ys(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ys=function(n){return typeof n}:Ys=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ys(e)}function XN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function zm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ZN(e,t,n){return t&&zm(e.prototype,t),n&&zm(e,n),e}function JN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Df(e,t)}function Df(e,t){return Df=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Df(e,t)}function eT(e){var t=nT();return function(){var r=dc(e),i;if(t){var o=dc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return tT(this,i)}}function tT(e,t){return t&&(Ys(t)==="object"||typeof t=="function")?t:Lf(e)}function Lf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function nT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function dc(e){return dc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},dc(e)}function jm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var rT=function(e){JN(n,e);var t=eT(n);function n(){var r;XN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),jm(Lf(r),"priority",10),jm(Lf(r),"incompatibleTokens",["t","T","x"]),r}return ZN(n,[{key:"parse",value:function(i,o){switch(o){case"X":return En(kn.basicOptionalMinutes,i);case"XX":return En(kn.basic,i);case"XXXX":return En(kn.basicOptionalSeconds,i);case"XXXXX":return En(kn.extendedOptionalSeconds,i);case"XXX":default:return En(kn.extended,i)}}},{key:"set",value:function(i,o,a){return o.timestampIsSet?i:new Date(i.getTime()-a)}}]),n}(Oe);function Xs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Xs=function(n){return typeof n}:Xs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Xs(e)}function iT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Vm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function oT(e,t,n){return t&&Vm(e.prototype,t),n&&Vm(e,n),e}function aT(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Rf(e,t)}function Rf(e,t){return Rf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Rf(e,t)}function sT(e){var t=cT();return function(){var r=fc(e),i;if(t){var o=fc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return lT(this,i)}}function lT(e,t){return t&&(Xs(t)==="object"||typeof t=="function")?t:Ff(e)}function Ff(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function cT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function fc(e){return fc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},fc(e)}function Um(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var uT=function(e){aT(n,e);var t=sT(n);function n(){var r;iT(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Um(Ff(r),"priority",10),Um(Ff(r),"incompatibleTokens",["t","T","X"]),r}return oT(n,[{key:"parse",value:function(i,o){switch(o){case"x":return En(kn.basicOptionalMinutes,i);case"xx":return En(kn.basic,i);case"xxxx":return En(kn.basicOptionalSeconds,i);case"xxxxx":return En(kn.extendedOptionalSeconds,i);case"xxx":default:return En(kn.extended,i)}}},{key:"set",value:function(i,o,a){return o.timestampIsSet?i:new Date(i.getTime()-a)}}]),n}(Oe);function Zs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Zs=function(n){return typeof n}:Zs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Zs(e)}function dT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Bm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function fT(e,t,n){return t&&Bm(e.prototype,t),n&&Bm(e,n),e}function hT(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&zf(e,t)}function zf(e,t){return zf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},zf(e,t)}function pT(e){var t=vT();return function(){var r=hc(e),i;if(t){var o=hc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return mT(this,i)}}function mT(e,t){return t&&(Zs(t)==="object"||typeof t=="function")?t:jf(e)}function jf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function vT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function hc(e){return hc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},hc(e)}function Hm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var gT=function(e){hT(n,e);var t=pT(n);function n(){var r;dT(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Hm(jf(r),"priority",40),Hm(jf(r),"incompatibleTokens","*"),r}return fT(n,[{key:"parse",value:function(i){return cb(i)}},{key:"set",value:function(i,o,a){return[new Date(a*1e3),{timestampIsSet:!0}]}}]),n}(Oe);function Js(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Js=function(n){return typeof n}:Js=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Js(e)}function yT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function qm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function bT(e,t,n){return t&&qm(e.prototype,t),n&&qm(e,n),e}function $T(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Vf(e,t)}function Vf(e,t){return Vf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Vf(e,t)}function wT(e){var t=xT();return function(){var r=pc(e),i;if(t){var o=pc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return _T(this,i)}}function _T(e,t){return t&&(Js(t)==="object"||typeof t=="function")?t:Uf(e)}function Uf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function xT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function pc(e){return pc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},pc(e)}function Wm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var kT=function(e){$T(n,e);var t=wT(n);function n(){var r;yT(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Wm(Uf(r),"priority",20),Wm(Uf(r),"incompatibleTokens","*"),r}return bT(n,[{key:"parse",value:function(i){return cb(i)}},{key:"set",value:function(i,o,a){return[new Date(a),{timestampIsSet:!0}]}}]),n}(Oe),ET={G:new ES,y:new AS,Y:new zS,R:new WS,u:new JS,Q:new aO,q:new hO,M:new $O,L:new OO,w:new DO,I:new BO,d:new ZO,D:new oC,E:new fC,e:new bC,c:new SC,i:new MC,a:new VC,b:new KC,B:new tN,h:new lN,H:new mN,K:new _N,k:new NN,m:new LN,s:new BN,S:new YN,X:new rT,x:new uT,t:new gT,T:new kT};function el(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?el=function(n){return typeof n}:el=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},el(e)}function Gm(e,t){var n;if(typeof Symbol>"u"||e[Symbol.iterator]==null){if(Array.isArray(e)||(n=ST(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(l){throw l},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
2256
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var o=!0,a=!1,s;return{s:function(){n=e[Symbol.iterator]()},n:function(){var l=n.next();return o=l.done,l},e:function(l){a=!0,s=l},f:function(){try{!o&&n.return!=null&&n.return()}finally{if(a)throw s}}}}function ST(e,t){if(!!e){if(typeof e=="string")return Km(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Km(e,t)}}function Km(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var OT=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,CT=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,NT=/^'([^]*?)'?$/,TT=/''/g,PT=/\S/,AT=/[a-zA-Z]/;function IT(e,t,n,r){var i,o,a,s,c,l,u,d,f,h,p,m,v,b,y,g,_,x;Ue(3,arguments);var O=String(e),C=String(t),M=uo(),D=(i=(o=r?.locale)!==null&&o!==void 0?o:M.locale)!==null&&i!==void 0?i:ob;if(!D.match)throw new RangeError("locale must contain match property");var F=Wt((a=(s=(c=(l=r?.firstWeekContainsDate)!==null&&l!==void 0?l:r==null||(u=r.locale)===null||u===void 0||(d=u.options)===null||d===void 0?void 0:d.firstWeekContainsDate)!==null&&c!==void 0?c:M.firstWeekContainsDate)!==null&&s!==void 0?s:(f=M.locale)===null||f===void 0||(h=f.options)===null||h===void 0?void 0:h.firstWeekContainsDate)!==null&&a!==void 0?a:1);if(!(F>=1&&F<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var Y=Wt((p=(m=(v=(b=r?.weekStartsOn)!==null&&b!==void 0?b:r==null||(y=r.locale)===null||y===void 0||(g=y.options)===null||g===void 0?void 0:g.weekStartsOn)!==null&&v!==void 0?v:M.weekStartsOn)!==null&&m!==void 0?m:(_=M.locale)===null||_===void 0||(x=_.options)===null||x===void 0?void 0:x.weekStartsOn)!==null&&p!==void 0?p:0);if(!(Y>=0&&Y<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(C==="")return O===""?ft(n):new Date(NaN);var J={firstWeekContainsDate:F,weekStartsOn:Y,locale:D},G=[new vS],j=C.match(CT).map(function(ce){var re=ce[0];if(re in A0){var ae=A0[re];return ae(ce,D.formatLong)}return ce}).join("").match(OT),z=[],Q=Gm(j),I;try{var U=function(){var re=I.value;!(r!=null&&r.useAdditionalWeekYearTokens)&&ib(re)&&Dl(re,C,e),!(r!=null&&r.useAdditionalDayOfYearTokens)&&rb(re)&&Dl(re,C,e);var ae=re[0],_e=ET[ae];if(_e){var it=_e.incompatibleTokens;if(Array.isArray(it)){var kt=z.find(function(Vt){return it.includes(Vt.token)||Vt.token===ae});if(kt)throw new RangeError("The format string mustn't contain `".concat(kt.fullToken,"` and `").concat(re,"` at the same time"))}else if(_e.incompatibleTokens==="*"&&z.length>0)throw new RangeError("The format string mustn't contain `".concat(re,"` and any other token at the same time"));z.push({token:ae,fullToken:re});var mt=_e.run(O,re,D.match,J);if(!mt)return{v:new Date(NaN)};G.push(mt.setter),O=mt.rest}else{if(ae.match(AT))throw new RangeError("Format string contains an unescaped latin alphabet character `"+ae+"`");if(re==="''"?re="'":ae==="'"&&(re=MT(re)),O.indexOf(re)===0)O=O.slice(re.length);else return{v:new Date(NaN)}}};for(Q.s();!(I=Q.n()).done;){var W=U();if(el(W)==="object")return W.v}}catch(ce){Q.e(ce)}finally{Q.f()}if(O.length>0&&PT.test(O))return new Date(NaN);var de=G.map(function(ce){return ce.priority}).sort(function(ce,re){return re-ce}).filter(function(ce,re,ae){return ae.indexOf(ce)===re}).map(function(ce){return G.filter(function(re){return re.priority===ce}).sort(function(re,ae){return ae.subPriority-re.subPriority})}).map(function(ce){return ce[0]}),be=ft(n);if(isNaN(be.getTime()))return new Date(NaN);var P=Z3(be,Y3(be)),B={},Ce=Gm(de),te;try{for(Ce.s();!(te=Ce.n()).done;){var ye=te.value;if(!ye.validate(P,J))return new Date(NaN);var Ne=ye.set(P,B,J);Array.isArray(Ne)?(P=Ne[0],dS(B,Ne[1])):P=Ne}}catch(ce){Ce.e(ce)}finally{Ce.f()}return P}function MT(e){return e.match(NT)[1].replace(TT,"'")}function DT(e){return Ue(1,arguments),tE(e,Date.now())}const st=(e,t)=>lo("message",n=>K3(n,e)?!0:t),LT=lo("NotFutureDate",e=>{const t=new Date(e);if(!(t instanceof Date))return!1;const n=new Date;return t<=n}),RT=(e,t=n=>IT(n,"yyyy-MM-dd",new Date))=>lo("between",function(r){return sE(t(r),e)>=0||DT(t(r))}),FT=()=>Sa(Kt(),"zipString",e=>/^\d{5}(-\d{4})?$/.test(e)),zT=()=>Sa(Kt(),"email",e=>e.length===0?!0:/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/.test(e)),sd=()=>Sa(co(),"empty",e=>e===null||e==null),jT=["allowfullscreen","async","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected"],VT=new Set(["className","value","readOnly","formNoValidate","isMap","noModule","playsInline",...jT]),UT=new Set(["innerHTML","textContent","innerText","children"]),BT=Object.assign(Object.create(null),{className:"class",htmlFor:"for"}),Qm=Object.assign(Object.create(null),{class:"className",formnovalidate:"formNoValidate",ismap:"isMap",nomodule:"noModule",playsinline:"playsInline",readonly:"readOnly"}),HT=new Set(["beforeinput","click","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"]),qT={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"};function WT(e,t,n){let r=n.length,i=t.length,o=r,a=0,s=0,c=t[i-1].nextSibling,l=null;for(;a<i||s<o;){if(t[a]===n[s]){a++,s++;continue}for(;t[i-1]===n[o-1];)i--,o--;if(i===a){const u=o<r?s?n[s-1].nextSibling:n[o-s]:c;for(;s<o;)e.insertBefore(n[s++],u)}else if(o===s)for(;a<i;)(!l||!l.has(t[a]))&&t[a].remove(),a++;else if(t[a]===n[o-1]&&n[s]===t[i-1]){const u=t[--i].nextSibling;e.insertBefore(n[s++],t[a++].nextSibling),e.insertBefore(n[--o],u),t[i]=n[o]}else{if(!l){l=new Map;let d=s;for(;d<o;)l.set(n[d],d++)}const u=l.get(t[a]);if(u!=null)if(s<u&&u<o){let d=a,f=1,h;for(;++d<i&&d<o&&!((h=l.get(t[d]))==null||h!==u+f);)f++;if(f>u-s){const p=t[a];for(;s<u;)e.insertBefore(n[s++],p)}else e.replaceChild(n[s++],t[a++])}else a++;else t[a++].remove()}}}const Ym="_$DX_DELEGATE";function $(e,t,n){const r=document.createElement("template");r.innerHTML=e;let i=r.content.firstChild;return n&&(i=i.firstChild),i}function Yc(e,t=window.document){const n=t[Ym]||(t[Ym]=new Set);for(let r=0,i=e.length;r<i;r++){const o=e[r];n.has(o)||(n.add(o),t.addEventListener(o,JT))}}function ca(e,t,n){n==null?e.removeAttribute(t):e.setAttribute(t,n)}function GT(e,t,n,r){r==null?e.removeAttributeNS(t,n):e.setAttributeNS(t,n,r)}function Oa(e,t){t==null?e.removeAttribute("class"):e.className=t}function fb(e,t,n,r){if(r)Array.isArray(n)?(e[`$$${t}`]=n[0],e[`$$${t}Data`]=n[1]):e[`$$${t}`]=n;else if(Array.isArray(n)){const i=n[0];e.addEventListener(t,n[0]=o=>i.call(e,n[1],o))}else e.addEventListener(t,n)}function KT(e,t,n={}){const r=Object.keys(t||{}),i=Object.keys(n);let o,a;for(o=0,a=i.length;o<a;o++){const s=i[o];!s||s==="undefined"||t[s]||(Xm(e,s,!1),delete n[s])}for(o=0,a=r.length;o<a;o++){const s=r[o],c=!!t[s];!s||s==="undefined"||n[s]===c||!c||(Xm(e,s,!0),n[s]=c)}return n}function QT(e,t,n){if(!t)return n?ca(e,"style"):t;const r=e.style;if(typeof t=="string")return r.cssText=t;typeof n=="string"&&(r.cssText=n=void 0),n||(n={}),t||(t={});let i,o;for(o in n)t[o]==null&&r.removeProperty(o),delete n[o];for(o in t)i=t[o],i!==n[o]&&(r.setProperty(o,i),n[o]=i);return n}function u1(e,t={},n,r){const i={};return r||q(()=>i.children=qi(e,t.children,i.children)),q(()=>t.ref&&t.ref(e)),q(()=>XT(e,t,n,!0,i,!0)),i}function YT(e,t,n){return H(()=>e(t,n))}function ie(e,t,n,r){if(n!==void 0&&!r&&(r=[]),typeof t!="function")return qi(e,t,r,n);q(i=>qi(e,t(),i,n),r)}function XT(e,t,n,r,i={},o=!1){t||(t={});for(const a in i)if(!(a in t)){if(a==="children")continue;i[a]=Zm(e,a,null,i[a],n,o)}for(const a in t){if(a==="children"){r||qi(e,t.children);continue}const s=t[a];i[a]=Zm(e,a,s,i[a],n,o)}}function ZT(e){return e.toLowerCase().replace(/-([a-z])/g,(t,n)=>n.toUpperCase())}function Xm(e,t,n){const r=t.trim().split(/\s+/);for(let i=0,o=r.length;i<o;i++)e.classList.toggle(r[i],n)}function Zm(e,t,n,r,i,o){let a,s,c;if(t==="style")return QT(e,n,r);if(t==="classList")return KT(e,n,r);if(n===r)return r;if(t==="ref")o||n(e);else if(t.slice(0,3)==="on:"){const l=t.slice(3);r&&e.removeEventListener(l,r),n&&e.addEventListener(l,n)}else if(t.slice(0,10)==="oncapture:"){const l=t.slice(10);r&&e.removeEventListener(l,r,!0),n&&e.addEventListener(l,n,!0)}else if(t.slice(0,2)==="on"){const l=t.slice(2).toLowerCase(),u=HT.has(l);if(!u&&r){const d=Array.isArray(r)?r[0]:r;e.removeEventListener(l,d)}(u||n)&&(fb(e,l,n,u),u&&Yc([l]))}else if((c=UT.has(t))||!i&&(Qm[t]||(s=VT.has(t)))||(a=e.nodeName.includes("-")))t==="class"||t==="className"?Oa(e,n):a&&!s&&!c?e[ZT(t)]=n:e[Qm[t]||t]=n;else{const l=i&&t.indexOf(":")>-1&&qT[t.split(":")[0]];l?GT(e,l,t,n):ca(e,BT[t]||t,n)}return n}function JT(e){const t=`$$${e.type}`;let n=e.composedPath&&e.composedPath()[0]||e.target;for(e.target!==n&&Object.defineProperty(e,"target",{configurable:!0,value:n}),Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return n||document}}),dt.registry&&!dt.done&&(dt.done=!0,document.querySelectorAll("[id^=pl-]").forEach(r=>{for(;r&&r.nodeType!==8&&r.nodeValue!=="pl-"+e;){let i=r.nextSibling;r.remove(),r=i}r&&r.remove()}));n;){const r=n[t];if(r&&!n.disabled){const i=n[`${t}Data`];if(i!==void 0?r.call(n,i,e):r.call(n,e),e.cancelBubble)return}n=n._$host||n.parentNode||n.host}}function qi(e,t,n,r,i){for(dt.context&&!n&&(n=[...e.childNodes]);typeof n=="function";)n=n();if(t===n)return n;const o=typeof t,a=r!==void 0;if(e=a&&n[0]&&n[0].parentNode||e,o==="string"||o==="number"){if(dt.context)return n;if(o==="number"&&(t=t.toString()),a){let s=n[0];s&&s.nodeType===3?s.data=t:s=document.createTextNode(t),n=di(e,n,r,s)}else n!==""&&typeof n=="string"?n=e.firstChild.data=t:n=e.textContent=t}else if(t==null||o==="boolean"){if(dt.context)return n;n=di(e,n,r)}else{if(o==="function")return q(()=>{let s=t();for(;typeof s=="function";)s=s();n=qi(e,s,n,r)}),()=>n;if(Array.isArray(t)){const s=[],c=n&&Array.isArray(n);if(Bf(s,t,n,i))return q(()=>n=qi(e,s,n,r,!0)),()=>n;if(dt.context){if(!s.length)return n;for(let l=0;l<s.length;l++)if(s[l].parentNode)return n=s}if(s.length===0){if(n=di(e,n,r),a)return n}else c?n.length===0?Jm(e,s,r):WT(e,n,s):(n&&di(e),Jm(e,s));n=s}else if(t instanceof Node){if(dt.context&&t.parentNode)return n=a?[t]:t;if(Array.isArray(n)){if(a)return n=di(e,n,r,t);di(e,n,null,t)}else n==null||n===""||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}}return n}function Bf(e,t,n,r){let i=!1;for(let o=0,a=t.length;o<a;o++){let s=t[o],c=n&&n[o];if(s instanceof Node)e.push(s);else if(!(s==null||s===!0||s===!1))if(Array.isArray(s))i=Bf(e,s,c)||i;else if(typeof s=="function")if(r){for(;typeof s=="function";)s=s();i=Bf(e,Array.isArray(s)?s:[s],Array.isArray(c)?c:[c])||i}else e.push(s),i=!0;else{const l=String(s);c&&c.nodeType===3&&c.data===l?e.push(c):e.push(document.createTextNode(l))}}return i}function Jm(e,t,n=null){for(let r=0,i=t.length;r<i;r++)e.insertBefore(t[r],n)}function di(e,t,n,r){if(n===void 0)return e.textContent="";const i=r||document.createTextNode("");if(t.length){let o=!1;for(let a=t.length-1;a>=0;a--){const s=t[a];if(i!==s){const c=s.parentNode===e;!o&&!a?c?e.replaceChild(i,s):e.insertBefore(i,n):c&&s.remove()}else o=!0}}else e.insertBefore(i,n);return[i]}function hb(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=hb(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Yr(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=hb(e))&&(r&&(r+=" "),r+=t);return r}const eP=$("<button></button>");function ev(e){const t=Nt({variant:"primary",size:"lg"},e),[n,r]=Ko(t,["variant","size","children","iconLeft"]),i=se(()=>Yr("font-semibold",{"shadow-sm":n.variant!=="naked","rounded-md":["xl","lg","md"].includes(n.size),rounded:!["xl","lg","md"].includes(n.size),"text-xs":n.size==="xs","text-sm":n.size!=="xs","px-3.5 py-2.5":n.size==="xl"&&n.variant!=="naked","px-3 py-2":n.size==="lg"&&n.variant!=="naked","px-2.5 py-1.5":n.size==="md"&&n.variant!=="naked","px-2 py-1":(n.size==="sm"||n.size==="xs")&&n.variant!=="naked","text-white bg-blue-600 hover:bg-blue-500 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 hover:bg-blue-500":n.variant==="primary","rounded bg-white text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 hover:bg-gray-50":n.variant==="secondary","bg-blue-50 text-blue-600 hover:bg-blue-100":n.variant==="tertiary","text-blue-600 hover:text-blue-500 bg-transparent focus:outline-none focus:ring-2 focus:ring-blue-300":n.variant==="naked","opacity-50 cursor-not-allowed":r.disabled,"justify-center inline-flex items-center gap-x-1.5":n?.iconLeft}));return(()=>{const o=eP.cloneNode(!0);return u1(o,Nt(r,{get class(){return i()},type:"button"}),!1,!0),ie(o,S(ee,{get when(){return n?.iconLeft},get children(){return n?.iconLeft}}),null),ie(o,()=>t.children,null),o})()}var mc=function(){return mc=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++){t=arguments[n];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},mc.apply(this,arguments)};function ld(e,t){if(!Boolean(e))throw new Error(t)}function tP(e){return typeof e=="object"&&e!==null}function nP(e,t){if(!Boolean(e))throw new Error(t??"Unexpected invariant triggered.")}const rP=/\r\n|[\n\r]/g;function Hf(e,t){let n=0,r=1;for(const i of e.body.matchAll(rP)){if(typeof i.index=="number"||nP(!1),i.index>=t)break;n=i.index+i[0].length,r+=1}return{line:r,column:t+1-n}}function iP(e){return pb(e.source,Hf(e.source,e.start))}function pb(e,t){const n=e.locationOffset.column-1,r="".padStart(n)+e.body,i=t.line-1,o=e.locationOffset.line-1,a=t.line+o,s=t.line===1?n:0,c=t.column+s,l=`${e.name}:${a}:${c}
|
|
2255
|
+
`;class Bk extends TypeError{constructor(t,n){let r;const{message:i,explanation:o,...a}=t,{path:s}=t,c=s.length===0?i:`At path: ${s.join(".")} -- ${i}`;super(o??c),o!=null&&(this.cause=c),Object.assign(this,a),this.name=this.constructor.name,this.failures=()=>r??(r=[t,...n()])}}function Hk(e){return Pi(e)&&typeof e[Symbol.iterator]=="function"}function Pi(e){return typeof e=="object"&&e!=null}function _r(e){return typeof e=="symbol"?e.toString():typeof e=="string"?JSON.stringify(e):`${e}`}function qk(e){const{done:t,value:n}=e.next();return t?void 0:n}function Wk(e,t,n,r){if(e===!0)return;e===!1?e={}:typeof e=="string"&&(e={message:e});const{path:i,branch:o}=t,{type:a}=n,{refinement:s,message:c=`Expected a value of type \`${a}\`${s?` with refinement \`${s}\``:""}, but received: \`${_r(r)}\``}=e;return{value:r,type:a,refinement:s,key:i[i.length-1],path:i,branch:o,...e,message:c}}function*P0(e,t,n,r){Hk(e)||(e=[e]);for(const i of e){const o=Wk(i,t,n,r);o&&(yield o)}}function*i1(e,t,n={}){const{path:r=[],branch:i=[e],coerce:o=!1,mask:a=!1}=n,s={path:r,branch:i};if(o&&(e=t.coercer(e,s),a&&t.type!=="type"&&Pi(t.schema)&&Pi(e)&&!Array.isArray(e)))for(const l in e)t.schema[l]===void 0&&delete e[l];let c="valid";for(const l of t.validator(e,s))l.explanation=n.message,c="not_valid",yield[l,void 0];for(let[l,u,d]of t.entries(e,s)){const f=i1(u,d,{path:l===void 0?r:[...r,l],branch:l===void 0?i:[...i,u],coerce:o,mask:a,message:n.message});for(const h of f)h[0]?(c=h[0].refinement!=null?"not_refined":"not_valid",yield[h[0],void 0]):o&&(u=h[1],l===void 0?e=u:e instanceof Map?e.set(l,u):e instanceof Set?e.add(u):Pi(e)&&(u!==void 0||l in e)&&(e[l]=u))}if(c!=="not_valid")for(const l of t.refiner(e,s))l.explanation=n.message,c="not_refined",yield[l,void 0];c==="valid"&&(yield[void 0,e])}class so{constructor(t){const{type:n,schema:r,validator:i,refiner:o,coercer:a=c=>c,entries:s=function*(){}}=t;this.type=n,this.schema=r,this.entries=s,this.coercer=a,i?this.validator=(c,l)=>{const u=i(c,l);return P0(u,l,this,c)}:this.validator=()=>[],o?this.refiner=(c,l)=>{const u=o(c,l);return P0(u,l,this,c)}:this.refiner=()=>[]}assert(t,n){return G3(t,this,n)}create(t,n){return Gk(t,this,n)}is(t){return K3(t,this)}mask(t,n){return Kk(t,this,n)}validate(t,n={}){return Ea(t,this,n)}}function G3(e,t,n){const r=Ea(e,t,{message:n});if(r[0])throw r[0]}function Gk(e,t,n){const r=Ea(e,t,{coerce:!0,message:n});if(r[0])throw r[0];return r[1]}function Kk(e,t,n){const r=Ea(e,t,{coerce:!0,mask:!0,message:n});if(r[0])throw r[0];return r[1]}function K3(e,t){return!Ea(e,t)[0]}function Ea(e,t,n={}){const r=i1(e,t,n),i=qk(r);return i[0]?[new Bk(i[0],function*(){for(const a of r)a[0]&&(yield a[0])}),void 0]:[void 0,i[1]]}function lo(e,t){return new so({type:e,schema:null,validator:t})}function co(){return lo("any",()=>!0)}function Qk(e){return new so({type:"array",schema:e,*entries(t){if(e&&Array.isArray(t))for(const[n,r]of t.entries())yield[n,r,e]},coercer(t){return Array.isArray(t)?t.slice():t},validator(t){return Array.isArray(t)||`Expected an array value, but received: ${_r(t)}`}})}function Yk(e){const t={},n=e.map(r=>_r(r)).join();for(const r of e)t[r]=r;return new so({type:"enums",schema:t,validator(r){return e.includes(r)||`Expected one of \`${n}\`, but received: ${_r(r)}`}})}function td(){return lo("number",e=>typeof e=="number"&&!isNaN(e)||`Expected a number, but received: ${_r(e)}`)}function Kc(e,t){return new so({type:"record",schema:null,*entries(n){if(Pi(n))for(const r in n){const i=n[r];yield[r,r,e],yield[r,i,t]}},validator(n){return Pi(n)||`Expected an object, but received: ${_r(n)}`}})}function Kt(){return lo("string",e=>typeof e=="string"||`Expected a string, but received: ${_r(e)}`)}function nd(e){const t=e.map(n=>n.type).join(" | ");return new so({type:"union",schema:null,coercer(n){for(const r of e){const[i,o]=r.validate(n,{coerce:!0});if(!i)return o}return n},validator(n,r){const i=[];for(const o of e){const[...a]=i1(n,o,r),[s]=a;if(s[0])for(const[c]of a)c&&i.push(c);else return[]}return[`Expected the value to satisfy a union of \`${t}\`, but received: ${_r(n)}`,...i]}})}function rd(e,t,n={}){const{exclusive:r}=n;return Sa(e,"min",i=>r?i>t:i>=t||`Expected a ${e.type} greater than ${r?"":"or equal to "}${t} but received \`${i}\``)}function fr(e,t,n=t){const r=`Expected a ${e.type}`,i=t===n?`of \`${t}\``:`between \`${t}\` and \`${n}\``;return Sa(e,"size",o=>{if(typeof o=="number"||o instanceof Date)return t<=o&&o<=n||`${r} ${i} but received \`${o}\``;if(o instanceof Map||o instanceof Set){const{size:a}=o;return t<=a&&a<=n||`${r} with a size ${i} but received one with a size of \`${a}\``}else{const{length:a}=o;return t<=a&&a<=n||`${r} with a length ${i} but received one with a length of \`${a}\``}})}function Sa(e,t,n){return new so({...e,*refiner(r,i){yield*e.refiner(r,i);const o=n(r,i),a=P0(o,i,e,r);for(const s of a)yield{...s,refinement:t}}})}const Q3=e=>{const t={};if(e){const f={};for(const h of Object.keys(e))f[h]={value:e[h],error:void 0};e=f}const[n,r]=kr(e||{}),i=({key:f,value:h})=>{r(f,{value:h,error:void 0})},o=f=>{let h=0;for(const p in n)f.includes(p)&&n[p]?.error&&(h+=1);return h>0},a=f=>{let h=[];for(const p in n)f.includes(p)&&n[p]?.error&&(h=[...h,{key:p,error:n[p]?.error??""}]);return h},s=f=>{for(const h of f)r(h,void 0)};return{store:n,actions:{updateFormValue:i,clearKeys:s,registerValidator:({key:f,validator:h})=>{if(f in t){t[f]=[...t[f],h];return}t[f]=[h]},unRegisterValidator:f=>{delete t[f]},validate:f=>{Object.entries(n).filter(([h])=>f?f.includes(h):!0).forEach(([h,p])=>{t[h]&&t[h].forEach(m=>{try{G3(p?.value,m)}catch(v){for(const b of v.failures())r(h,{value:p?.value,error:b.message})}})})},hasErrors:o,getErrors:a,reset:()=>{const f=Object.keys(n);s(f);const h=Object.keys(t);for(const p of h)delete t[p]}}}};function Wt(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function Ue(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function ys(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?ys=function(n){return typeof n}:ys=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ys(e)}function ft(e){Ue(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||ys(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function Xk(e,t){Ue(2,arguments);var n=ft(e).getTime(),r=Wt(t);return new Date(n+r)}var Zk={};function uo(){return Zk}function Y3(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}function M5(e){Ue(1,arguments);var t=ft(e);return t.setHours(0,0,0,0),t}var Jk=6e4,X3=36e5,eE=1e3;function tE(e,t){Ue(2,arguments);var n=M5(e),r=M5(t);return n.getTime()===r.getTime()}function bs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?bs=function(n){return typeof n}:bs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},bs(e)}function nE(e){return Ue(1,arguments),e instanceof Date||bs(e)==="object"&&Object.prototype.toString.call(e)==="[object Date]"}function rE(e){if(Ue(1,arguments),!nE(e)&&typeof e!="number")return!1;var t=ft(e);return!isNaN(Number(t))}function iE(e,t){return Ue(2,arguments),ft(e).getTime()-ft(t).getTime()}var D5={ceil:Math.ceil,round:Math.round,floor:Math.floor,trunc:function(t){return t<0?Math.ceil(t):Math.floor(t)}},oE="trunc";function aE(e){return e?D5[e]:D5[oE]}function sE(e,t,n){Ue(2,arguments);var r=iE(e,t)/X3;return aE(n?.roundingMethod)(r)}function Z3(e,t){Ue(2,arguments);var n=Wt(t);return Xk(e,-n)}var lE=864e5;function cE(e){Ue(1,arguments);var t=ft(e),n=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var r=t.getTime(),i=n-r;return Math.floor(i/lE)+1}function Hi(e){Ue(1,arguments);var t=1,n=ft(e),r=n.getUTCDay(),i=(r<t?7:0)+r-t;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function J3(e){Ue(1,arguments);var t=ft(e),n=t.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=Hi(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var a=Hi(o);return t.getTime()>=i.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function uE(e){Ue(1,arguments);var t=J3(e),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var r=Hi(n);return r}var dE=6048e5;function eb(e){Ue(1,arguments);var t=ft(e),n=Hi(t).getTime()-uE(t).getTime();return Math.round(n/dE)+1}function Qr(e,t){var n,r,i,o,a,s,c,l;Ue(1,arguments);var u=uo(),d=Wt((n=(r=(i=(o=t?.weekStartsOn)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.weekStartsOn)!==null&&i!==void 0?i:u.weekStartsOn)!==null&&r!==void 0?r:(c=u.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&n!==void 0?n:0);if(!(d>=0&&d<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var f=ft(e),h=f.getUTCDay(),p=(h<d?7:0)+h-d;return f.setUTCDate(f.getUTCDate()-p),f.setUTCHours(0,0,0,0),f}function o1(e,t){var n,r,i,o,a,s,c,l;Ue(1,arguments);var u=ft(e),d=u.getUTCFullYear(),f=uo(),h=Wt((n=(r=(i=(o=t?.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&i!==void 0?i:f.firstWeekContainsDate)!==null&&r!==void 0?r:(c=f.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(h>=1&&h<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var p=new Date(0);p.setUTCFullYear(d+1,0,h),p.setUTCHours(0,0,0,0);var m=Qr(p,t),v=new Date(0);v.setUTCFullYear(d,0,h),v.setUTCHours(0,0,0,0);var b=Qr(v,t);return u.getTime()>=m.getTime()?d+1:u.getTime()>=b.getTime()?d:d-1}function fE(e,t){var n,r,i,o,a,s,c,l;Ue(1,arguments);var u=uo(),d=Wt((n=(r=(i=(o=t?.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&i!==void 0?i:u.firstWeekContainsDate)!==null&&r!==void 0?r:(c=u.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&n!==void 0?n:1),f=o1(e,t),h=new Date(0);h.setUTCFullYear(f,0,d),h.setUTCHours(0,0,0,0);var p=Qr(h,t);return p}var hE=6048e5;function tb(e,t){Ue(1,arguments);var n=ft(e),r=Qr(n,t).getTime()-fE(n,t).getTime();return Math.round(r/hE)+1}function Te(e,t){for(var n=e<0?"-":"",r=Math.abs(e).toString();r.length<t;)r="0"+r;return n+r}var pE={y:function(t,n){var r=t.getUTCFullYear(),i=r>0?r:1-r;return Te(n==="yy"?i%100:i,n.length)},M:function(t,n){var r=t.getUTCMonth();return n==="M"?String(r+1):Te(r+1,2)},d:function(t,n){return Te(t.getUTCDate(),n.length)},a:function(t,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.toUpperCase();case"aaa":return r;case"aaaaa":return r[0];case"aaaa":default:return r==="am"?"a.m.":"p.m."}},h:function(t,n){return Te(t.getUTCHours()%12||12,n.length)},H:function(t,n){return Te(t.getUTCHours(),n.length)},m:function(t,n){return Te(t.getUTCMinutes(),n.length)},s:function(t,n){return Te(t.getUTCSeconds(),n.length)},S:function(t,n){var r=n.length,i=t.getUTCMilliseconds(),o=Math.floor(i*Math.pow(10,r-3));return Te(o,n.length)}};const Jn=pE;var ui={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},mE={G:function(t,n,r){var i=t.getUTCFullYear()>0?1:0;switch(n){case"G":case"GG":case"GGG":return r.era(i,{width:"abbreviated"});case"GGGGG":return r.era(i,{width:"narrow"});case"GGGG":default:return r.era(i,{width:"wide"})}},y:function(t,n,r){if(n==="yo"){var i=t.getUTCFullYear(),o=i>0?i:1-i;return r.ordinalNumber(o,{unit:"year"})}return Jn.y(t,n)},Y:function(t,n,r,i){var o=o1(t,i),a=o>0?o:1-o;if(n==="YY"){var s=a%100;return Te(s,2)}return n==="Yo"?r.ordinalNumber(a,{unit:"year"}):Te(a,n.length)},R:function(t,n){var r=J3(t);return Te(r,n.length)},u:function(t,n){var r=t.getUTCFullYear();return Te(r,n.length)},Q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"Q":return String(i);case"QQ":return Te(i,2);case"Qo":return r.ordinalNumber(i,{unit:"quarter"});case"QQQ":return r.quarter(i,{width:"abbreviated",context:"formatting"});case"QQQQQ":return r.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return r.quarter(i,{width:"wide",context:"formatting"})}},q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"q":return String(i);case"qq":return Te(i,2);case"qo":return r.ordinalNumber(i,{unit:"quarter"});case"qqq":return r.quarter(i,{width:"abbreviated",context:"standalone"});case"qqqqq":return r.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return r.quarter(i,{width:"wide",context:"standalone"})}},M:function(t,n,r){var i=t.getUTCMonth();switch(n){case"M":case"MM":return Jn.M(t,n);case"Mo":return r.ordinalNumber(i+1,{unit:"month"});case"MMM":return r.month(i,{width:"abbreviated",context:"formatting"});case"MMMMM":return r.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return r.month(i,{width:"wide",context:"formatting"})}},L:function(t,n,r){var i=t.getUTCMonth();switch(n){case"L":return String(i+1);case"LL":return Te(i+1,2);case"Lo":return r.ordinalNumber(i+1,{unit:"month"});case"LLL":return r.month(i,{width:"abbreviated",context:"standalone"});case"LLLLL":return r.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return r.month(i,{width:"wide",context:"standalone"})}},w:function(t,n,r,i){var o=tb(t,i);return n==="wo"?r.ordinalNumber(o,{unit:"week"}):Te(o,n.length)},I:function(t,n,r){var i=eb(t);return n==="Io"?r.ordinalNumber(i,{unit:"week"}):Te(i,n.length)},d:function(t,n,r){return n==="do"?r.ordinalNumber(t.getUTCDate(),{unit:"date"}):Jn.d(t,n)},D:function(t,n,r){var i=cE(t);return n==="Do"?r.ordinalNumber(i,{unit:"dayOfYear"}):Te(i,n.length)},E:function(t,n,r){var i=t.getUTCDay();switch(n){case"E":case"EE":case"EEE":return r.day(i,{width:"abbreviated",context:"formatting"});case"EEEEE":return r.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return r.day(i,{width:"short",context:"formatting"});case"EEEE":default:return r.day(i,{width:"wide",context:"formatting"})}},e:function(t,n,r,i){var o=t.getUTCDay(),a=(o-i.weekStartsOn+8)%7||7;switch(n){case"e":return String(a);case"ee":return Te(a,2);case"eo":return r.ordinalNumber(a,{unit:"day"});case"eee":return r.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return r.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return r.day(o,{width:"short",context:"formatting"});case"eeee":default:return r.day(o,{width:"wide",context:"formatting"})}},c:function(t,n,r,i){var o=t.getUTCDay(),a=(o-i.weekStartsOn+8)%7||7;switch(n){case"c":return String(a);case"cc":return Te(a,n.length);case"co":return r.ordinalNumber(a,{unit:"day"});case"ccc":return r.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return r.day(o,{width:"narrow",context:"standalone"});case"cccccc":return r.day(o,{width:"short",context:"standalone"});case"cccc":default:return r.day(o,{width:"wide",context:"standalone"})}},i:function(t,n,r){var i=t.getUTCDay(),o=i===0?7:i;switch(n){case"i":return String(o);case"ii":return Te(o,n.length);case"io":return r.ordinalNumber(o,{unit:"day"});case"iii":return r.day(i,{width:"abbreviated",context:"formatting"});case"iiiii":return r.day(i,{width:"narrow",context:"formatting"});case"iiiiii":return r.day(i,{width:"short",context:"formatting"});case"iiii":default:return r.day(i,{width:"wide",context:"formatting"})}},a:function(t,n,r){var i=t.getUTCHours(),o=i/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(t,n,r){var i=t.getUTCHours(),o;switch(i===12?o=ui.noon:i===0?o=ui.midnight:o=i/12>=1?"pm":"am",n){case"b":case"bb":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(t,n,r){var i=t.getUTCHours(),o;switch(i>=17?o=ui.evening:i>=12?o=ui.afternoon:i>=4?o=ui.morning:o=ui.night,n){case"B":case"BB":case"BBB":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(t,n,r){if(n==="ho"){var i=t.getUTCHours()%12;return i===0&&(i=12),r.ordinalNumber(i,{unit:"hour"})}return Jn.h(t,n)},H:function(t,n,r){return n==="Ho"?r.ordinalNumber(t.getUTCHours(),{unit:"hour"}):Jn.H(t,n)},K:function(t,n,r){var i=t.getUTCHours()%12;return n==="Ko"?r.ordinalNumber(i,{unit:"hour"}):Te(i,n.length)},k:function(t,n,r){var i=t.getUTCHours();return i===0&&(i=24),n==="ko"?r.ordinalNumber(i,{unit:"hour"}):Te(i,n.length)},m:function(t,n,r){return n==="mo"?r.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):Jn.m(t,n)},s:function(t,n,r){return n==="so"?r.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):Jn.s(t,n)},S:function(t,n){return Jn.S(t,n)},X:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();if(a===0)return"Z";switch(n){case"X":return R5(a);case"XXXX":case"XX":return Pr(a);case"XXXXX":case"XXX":default:return Pr(a,":")}},x:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"x":return R5(a);case"xxxx":case"xx":return Pr(a);case"xxxxx":case"xxx":default:return Pr(a,":")}},O:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"O":case"OO":case"OOO":return"GMT"+L5(a,":");case"OOOO":default:return"GMT"+Pr(a,":")}},z:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"z":case"zz":case"zzz":return"GMT"+L5(a,":");case"zzzz":default:return"GMT"+Pr(a,":")}},t:function(t,n,r,i){var o=i._originalDate||t,a=Math.floor(o.getTime()/1e3);return Te(a,n.length)},T:function(t,n,r,i){var o=i._originalDate||t,a=o.getTime();return Te(a,n.length)}};function L5(e,t){var n=e>0?"-":"+",r=Math.abs(e),i=Math.floor(r/60),o=r%60;if(o===0)return n+String(i);var a=t||"";return n+String(i)+a+Te(o,2)}function R5(e,t){if(e%60===0){var n=e>0?"-":"+";return n+Te(Math.abs(e)/60,2)}return Pr(e,t)}function Pr(e,t){var n=t||"",r=e>0?"-":"+",i=Math.abs(e),o=Te(Math.floor(i/60),2),a=Te(i%60,2);return r+o+n+a}const vE=mE;var F5=function(t,n){switch(t){case"P":return n.date({width:"short"});case"PP":return n.date({width:"medium"});case"PPP":return n.date({width:"long"});case"PPPP":default:return n.date({width:"full"})}},nb=function(t,n){switch(t){case"p":return n.time({width:"short"});case"pp":return n.time({width:"medium"});case"ppp":return n.time({width:"long"});case"pppp":default:return n.time({width:"full"})}},gE=function(t,n){var r=t.match(/(P+)(p+)?/)||[],i=r[1],o=r[2];if(!o)return F5(t,n);var a;switch(i){case"P":a=n.dateTime({width:"short"});break;case"PP":a=n.dateTime({width:"medium"});break;case"PPP":a=n.dateTime({width:"long"});break;case"PPPP":default:a=n.dateTime({width:"full"});break}return a.replace("{{date}}",F5(i,n)).replace("{{time}}",nb(o,n))},yE={p:nb,P:gE};const A0=yE;var bE=["D","DD"],$E=["YY","YYYY"];function rb(e){return bE.indexOf(e)!==-1}function ib(e){return $E.indexOf(e)!==-1}function Dl(e,t,n){if(e==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var wE={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},_E=function(t,n,r){var i,o=wE[t];return typeof o=="string"?i=o:n===1?i=o.one:i=o.other.replace("{{count}}",n.toString()),r!=null&&r.addSuffix?r.comparison&&r.comparison>0?"in "+i:i+" ago":i};const xE=_E;function id(e){return function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.width?String(t.width):e.defaultWidth,r=e.formats[n]||e.formats[e.defaultWidth];return r}}var kE={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},EE={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},SE={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},OE={date:id({formats:kE,defaultWidth:"full"}),time:id({formats:EE,defaultWidth:"full"}),dateTime:id({formats:SE,defaultWidth:"full"})};const CE=OE;var NE={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},TE=function(t,n,r,i){return NE[t]};const PE=TE;function No(e){return function(t,n){var r=n!=null&&n.context?String(n.context):"standalone",i;if(r==="formatting"&&e.formattingValues){var o=e.defaultFormattingWidth||e.defaultWidth,a=n!=null&&n.width?String(n.width):o;i=e.formattingValues[a]||e.formattingValues[o]}else{var s=e.defaultWidth,c=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[c]||e.values[s]}var l=e.argumentCallback?e.argumentCallback(t):t;return i[l]}}var AE={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},IE={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},ME={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},DE={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},LE={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},RE={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},FE=function(t,n){var r=Number(t),i=r%100;if(i>20||i<10)switch(i%10){case 1:return r+"st";case 2:return r+"nd";case 3:return r+"rd"}return r+"th"},zE={ordinalNumber:FE,era:No({values:AE,defaultWidth:"wide"}),quarter:No({values:IE,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:No({values:ME,defaultWidth:"wide"}),day:No({values:DE,defaultWidth:"wide"}),dayPeriod:No({values:LE,defaultWidth:"wide",formattingValues:RE,defaultFormattingWidth:"wide"})};const jE=zE;function To(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;var a=o[0],s=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(s)?UE(s,function(d){return d.test(a)}):VE(s,function(d){return d.test(a)}),l;l=e.valueCallback?e.valueCallback(c):c,l=n.valueCallback?n.valueCallback(l):l;var u=t.slice(a.length);return{value:l,rest:u}}}function VE(e,t){for(var n in e)if(e.hasOwnProperty(n)&&t(e[n]))return n}function UE(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return n}function BE(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.match(e.matchPattern);if(!r)return null;var i=r[0],o=t.match(e.parsePattern);if(!o)return null;var a=e.valueCallback?e.valueCallback(o[0]):o[0];a=n.valueCallback?n.valueCallback(a):a;var s=t.slice(i.length);return{value:a,rest:s}}}var HE=/^(\d+)(th|st|nd|rd)?/i,qE=/\d+/i,WE={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},GE={any:[/^b/i,/^(a|c)/i]},KE={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},QE={any:[/1/i,/2/i,/3/i,/4/i]},YE={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},XE={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},ZE={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},JE={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},eS={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},tS={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},nS={ordinalNumber:BE({matchPattern:HE,parsePattern:qE,valueCallback:function(t){return parseInt(t,10)}}),era:To({matchPatterns:WE,defaultMatchWidth:"wide",parsePatterns:GE,defaultParseWidth:"any"}),quarter:To({matchPatterns:KE,defaultMatchWidth:"wide",parsePatterns:QE,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:To({matchPatterns:YE,defaultMatchWidth:"wide",parsePatterns:XE,defaultParseWidth:"any"}),day:To({matchPatterns:ZE,defaultMatchWidth:"wide",parsePatterns:JE,defaultParseWidth:"any"}),dayPeriod:To({matchPatterns:eS,defaultMatchWidth:"any",parsePatterns:tS,defaultParseWidth:"any"})};const rS=nS;var iS={code:"en-US",formatDistance:xE,formatLong:CE,formatRelative:PE,localize:jE,match:rS,options:{weekStartsOn:0,firstWeekContainsDate:1}};const ob=iS;var oS=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,aS=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,sS=/^'([^]*?)'?$/,lS=/''/g,cS=/[a-zA-Z]/;function Qc(e,t,n){var r,i,o,a,s,c,l,u,d,f,h,p,m,v,b,y,g,_;Ue(2,arguments);var k=String(t),O=uo(),C=(r=(i=n?.locale)!==null&&i!==void 0?i:O.locale)!==null&&r!==void 0?r:ob,M=Wt((o=(a=(s=(c=n?.firstWeekContainsDate)!==null&&c!==void 0?c:n==null||(l=n.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&s!==void 0?s:O.firstWeekContainsDate)!==null&&a!==void 0?a:(d=O.locale)===null||d===void 0||(f=d.options)===null||f===void 0?void 0:f.firstWeekContainsDate)!==null&&o!==void 0?o:1);if(!(M>=1&&M<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var D=Wt((h=(p=(m=(v=n?.weekStartsOn)!==null&&v!==void 0?v:n==null||(b=n.locale)===null||b===void 0||(y=b.options)===null||y===void 0?void 0:y.weekStartsOn)!==null&&m!==void 0?m:O.weekStartsOn)!==null&&p!==void 0?p:(g=O.locale)===null||g===void 0||(_=g.options)===null||_===void 0?void 0:_.weekStartsOn)!==null&&h!==void 0?h:0);if(!(D>=0&&D<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!C.localize)throw new RangeError("locale must contain localize property");if(!C.formatLong)throw new RangeError("locale must contain formatLong property");var F=ft(e);if(!rE(F))throw new RangeError("Invalid time value");var Y=Y3(F),J=Z3(F,Y),G={firstWeekContainsDate:M,weekStartsOn:D,locale:C,_originalDate:F},j=k.match(aS).map(function(z){var Q=z[0];if(Q==="p"||Q==="P"){var I=A0[Q];return I(z,C.formatLong)}return z}).join("").match(oS).map(function(z){if(z==="''")return"'";var Q=z[0];if(Q==="'")return uS(z);var I=vE[Q];if(I)return!(n!=null&&n.useAdditionalWeekYearTokens)&&ib(z)&&Dl(z,t,String(e)),!(n!=null&&n.useAdditionalDayOfYearTokens)&&rb(z)&&Dl(z,t,String(e)),I(J,z,C.localize,G);if(Q.match(cS))throw new RangeError("Format string contains an unescaped latin alphabet character `"+Q+"`");return z}).join("");return j}function uS(e){var t=e.match(sS);return t?t[1].replace(lS,"'"):e}function dS(e,t){if(e==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}function $s(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?$s=function(n){return typeof n}:$s=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},$s(e)}function ab(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&I0(e,t)}function I0(e,t){return I0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},I0(e,t)}function sb(e){var t=hS();return function(){var r=Ll(e),i;if(t){var o=Ll(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return fS(this,i)}}function fS(e,t){return t&&($s(t)==="object"||typeof t=="function")?t:M0(e)}function M0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function hS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Ll(e){return Ll=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Ll(e)}function a1(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function z5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function s1(e,t,n){return t&&z5(e.prototype,t),n&&z5(e,n),e}function D0(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var pS=10,lb=function(){function e(){a1(this,e),D0(this,"subPriority",0)}return s1(e,[{key:"validate",value:function(n,r){return!0}}]),e}(),mS=function(e){ab(n,e);var t=sb(n);function n(r,i,o,a,s){var c;return a1(this,n),c=t.call(this),c.value=r,c.validateValue=i,c.setValue=o,c.priority=a,s&&(c.subPriority=s),c}return s1(n,[{key:"validate",value:function(i,o){return this.validateValue(i,this.value,o)}},{key:"set",value:function(i,o,a){return this.setValue(i,o,this.value,a)}}]),n}(lb),vS=function(e){ab(n,e);var t=sb(n);function n(){var r;a1(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),D0(M0(r),"priority",pS),D0(M0(r),"subPriority",-1),r}return s1(n,[{key:"set",value:function(i,o){if(o.timestampIsSet)return i;var a=new Date(0);return a.setFullYear(i.getUTCFullYear(),i.getUTCMonth(),i.getUTCDate()),a.setHours(i.getUTCHours(),i.getUTCMinutes(),i.getUTCSeconds(),i.getUTCMilliseconds()),a}}]),n}(lb);function gS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function j5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function yS(e,t,n){return t&&j5(e.prototype,t),n&&j5(e,n),e}var Oe=function(){function e(){gS(this,e)}return yS(e,[{key:"run",value:function(n,r,i,o){var a=this.parse(n,r,i,o);return a?{setter:new mS(a.value,this.validate,this.set,this.priority,this.subPriority),rest:a.rest}:null}},{key:"validate",value:function(n,r,i){return!0}}]),e}();function ws(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?ws=function(n){return typeof n}:ws=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ws(e)}function bS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function V5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function $S(e,t,n){return t&&V5(e.prototype,t),n&&V5(e,n),e}function wS(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&L0(e,t)}function L0(e,t){return L0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},L0(e,t)}function _S(e){var t=kS();return function(){var r=Rl(e),i;if(t){var o=Rl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return xS(this,i)}}function xS(e,t){return t&&(ws(t)==="object"||typeof t=="function")?t:R0(e)}function R0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function kS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Rl(e){return Rl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Rl(e)}function U5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ES=function(e){wS(n,e);var t=_S(n);function n(){var r;bS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),U5(R0(r),"priority",140),U5(R0(r),"incompatibleTokens",["R","u","t","T"]),r}return $S(n,[{key:"parse",value:function(i,o,a){switch(o){case"G":case"GG":case"GGG":return a.era(i,{width:"abbreviated"})||a.era(i,{width:"narrow"});case"GGGGG":return a.era(i,{width:"narrow"});case"GGGG":default:return a.era(i,{width:"wide"})||a.era(i,{width:"abbreviated"})||a.era(i,{width:"narrow"})}}},{key:"set",value:function(i,o,a){return o.era=a,i.setUTCFullYear(a,0,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe),et={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},kn={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function tt(e,t){return e&&{value:t(e.value),rest:e.rest}}function Ge(e,t){var n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function En(e,t){var n=t.match(e);if(!n)return null;if(n[0]==="Z")return{value:0,rest:t.slice(1)};var r=n[1]==="+"?1:-1,i=n[2]?parseInt(n[2],10):0,o=n[3]?parseInt(n[3],10):0,a=n[5]?parseInt(n[5],10):0;return{value:r*(i*X3+o*Jk+a*eE),rest:t.slice(n[0].length)}}function cb(e){return Ge(et.anyDigitsSigned,e)}function Ze(e,t){switch(e){case 1:return Ge(et.singleDigit,t);case 2:return Ge(et.twoDigits,t);case 3:return Ge(et.threeDigits,t);case 4:return Ge(et.fourDigits,t);default:return Ge(new RegExp("^\\d{1,"+e+"}"),t)}}function Fl(e,t){switch(e){case 1:return Ge(et.singleDigitSigned,t);case 2:return Ge(et.twoDigitsSigned,t);case 3:return Ge(et.threeDigitsSigned,t);case 4:return Ge(et.fourDigitsSigned,t);default:return Ge(new RegExp("^-?\\d{1,"+e+"}"),t)}}function l1(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function ub(e,t){var n=t>0,r=n?t:1-t,i;if(r<=50)i=e||100;else{var o=r+50,a=Math.floor(o/100)*100,s=e>=o%100;i=e+a-(s?100:0)}return n?i:1-i}function db(e){return e%400===0||e%4===0&&e%100!==0}function _s(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?_s=function(n){return typeof n}:_s=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},_s(e)}function SS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function B5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function OS(e,t,n){return t&&B5(e.prototype,t),n&&B5(e,n),e}function CS(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&F0(e,t)}function F0(e,t){return F0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},F0(e,t)}function NS(e){var t=PS();return function(){var r=zl(e),i;if(t){var o=zl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return TS(this,i)}}function TS(e,t){return t&&(_s(t)==="object"||typeof t=="function")?t:z0(e)}function z0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function PS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function zl(e){return zl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},zl(e)}function H5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var AS=function(e){CS(n,e);var t=NS(n);function n(){var r;SS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),H5(z0(r),"priority",130),H5(z0(r),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),r}return OS(n,[{key:"parse",value:function(i,o,a){var s=function(l){return{year:l,isTwoDigitYear:o==="yy"}};switch(o){case"y":return tt(Ze(4,i),s);case"yo":return tt(a.ordinalNumber(i,{unit:"year"}),s);default:return tt(Ze(o.length,i),s)}}},{key:"validate",value:function(i,o){return o.isTwoDigitYear||o.year>0}},{key:"set",value:function(i,o,a){var s=i.getUTCFullYear();if(a.isTwoDigitYear){var c=ub(a.year,s);return i.setUTCFullYear(c,0,1),i.setUTCHours(0,0,0,0),i}var l=!("era"in o)||o.era===1?a.year:1-a.year;return i.setUTCFullYear(l,0,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function xs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?xs=function(n){return typeof n}:xs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},xs(e)}function IS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function q5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function MS(e,t,n){return t&&q5(e.prototype,t),n&&q5(e,n),e}function DS(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&j0(e,t)}function j0(e,t){return j0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},j0(e,t)}function LS(e){var t=FS();return function(){var r=jl(e),i;if(t){var o=jl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return RS(this,i)}}function RS(e,t){return t&&(xs(t)==="object"||typeof t=="function")?t:V0(e)}function V0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function FS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function jl(e){return jl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},jl(e)}function W5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var zS=function(e){DS(n,e);var t=LS(n);function n(){var r;IS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),W5(V0(r),"priority",130),W5(V0(r),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),r}return MS(n,[{key:"parse",value:function(i,o,a){var s=function(l){return{year:l,isTwoDigitYear:o==="YY"}};switch(o){case"Y":return tt(Ze(4,i),s);case"Yo":return tt(a.ordinalNumber(i,{unit:"year"}),s);default:return tt(Ze(o.length,i),s)}}},{key:"validate",value:function(i,o){return o.isTwoDigitYear||o.year>0}},{key:"set",value:function(i,o,a,s){var c=o1(i,s);if(a.isTwoDigitYear){var l=ub(a.year,c);return i.setUTCFullYear(l,0,s.firstWeekContainsDate),i.setUTCHours(0,0,0,0),Qr(i,s)}var u=!("era"in o)||o.era===1?a.year:1-a.year;return i.setUTCFullYear(u,0,s.firstWeekContainsDate),i.setUTCHours(0,0,0,0),Qr(i,s)}}]),n}(Oe);function ks(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?ks=function(n){return typeof n}:ks=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ks(e)}function jS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function G5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function VS(e,t,n){return t&&G5(e.prototype,t),n&&G5(e,n),e}function US(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&U0(e,t)}function U0(e,t){return U0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},U0(e,t)}function BS(e){var t=qS();return function(){var r=Vl(e),i;if(t){var o=Vl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return HS(this,i)}}function HS(e,t){return t&&(ks(t)==="object"||typeof t=="function")?t:B0(e)}function B0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function qS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Vl(e){return Vl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Vl(e)}function K5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var WS=function(e){US(n,e);var t=BS(n);function n(){var r;jS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),K5(B0(r),"priority",130),K5(B0(r),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),r}return VS(n,[{key:"parse",value:function(i,o){return Fl(o==="R"?4:o.length,i)}},{key:"set",value:function(i,o,a){var s=new Date(0);return s.setUTCFullYear(a,0,4),s.setUTCHours(0,0,0,0),Hi(s)}}]),n}(Oe);function Es(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Es=function(n){return typeof n}:Es=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Es(e)}function GS(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Q5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function KS(e,t,n){return t&&Q5(e.prototype,t),n&&Q5(e,n),e}function QS(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&H0(e,t)}function H0(e,t){return H0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},H0(e,t)}function YS(e){var t=ZS();return function(){var r=Ul(e),i;if(t){var o=Ul(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return XS(this,i)}}function XS(e,t){return t&&(Es(t)==="object"||typeof t=="function")?t:q0(e)}function q0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ZS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Ul(e){return Ul=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Ul(e)}function Y5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var JS=function(e){QS(n,e);var t=YS(n);function n(){var r;GS(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Y5(q0(r),"priority",130),Y5(q0(r),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),r}return KS(n,[{key:"parse",value:function(i,o){return Fl(o==="u"?4:o.length,i)}},{key:"set",value:function(i,o,a){return i.setUTCFullYear(a,0,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Ss(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ss=function(n){return typeof n}:Ss=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ss(e)}function eO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function X5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function tO(e,t,n){return t&&X5(e.prototype,t),n&&X5(e,n),e}function nO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&W0(e,t)}function W0(e,t){return W0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},W0(e,t)}function rO(e){var t=oO();return function(){var r=Bl(e),i;if(t){var o=Bl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return iO(this,i)}}function iO(e,t){return t&&(Ss(t)==="object"||typeof t=="function")?t:G0(e)}function G0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function oO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Bl(e){return Bl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Bl(e)}function Z5(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var aO=function(e){nO(n,e);var t=rO(n);function n(){var r;eO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Z5(G0(r),"priority",120),Z5(G0(r),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),r}return tO(n,[{key:"parse",value:function(i,o,a){switch(o){case"Q":case"QQ":return Ze(o.length,i);case"Qo":return a.ordinalNumber(i,{unit:"quarter"});case"QQQ":return a.quarter(i,{width:"abbreviated",context:"formatting"})||a.quarter(i,{width:"narrow",context:"formatting"});case"QQQQQ":return a.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return a.quarter(i,{width:"wide",context:"formatting"})||a.quarter(i,{width:"abbreviated",context:"formatting"})||a.quarter(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,o){return o>=1&&o<=4}},{key:"set",value:function(i,o,a){return i.setUTCMonth((a-1)*3,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Os(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Os=function(n){return typeof n}:Os=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Os(e)}function sO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function J5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function lO(e,t,n){return t&&J5(e.prototype,t),n&&J5(e,n),e}function cO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&K0(e,t)}function K0(e,t){return K0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},K0(e,t)}function uO(e){var t=fO();return function(){var r=Hl(e),i;if(t){var o=Hl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return dO(this,i)}}function dO(e,t){return t&&(Os(t)==="object"||typeof t=="function")?t:Q0(e)}function Q0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function fO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Hl(e){return Hl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Hl(e)}function em(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var hO=function(e){cO(n,e);var t=uO(n);function n(){var r;sO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),em(Q0(r),"priority",120),em(Q0(r),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),r}return lO(n,[{key:"parse",value:function(i,o,a){switch(o){case"q":case"qq":return Ze(o.length,i);case"qo":return a.ordinalNumber(i,{unit:"quarter"});case"qqq":return a.quarter(i,{width:"abbreviated",context:"standalone"})||a.quarter(i,{width:"narrow",context:"standalone"});case"qqqqq":return a.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return a.quarter(i,{width:"wide",context:"standalone"})||a.quarter(i,{width:"abbreviated",context:"standalone"})||a.quarter(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,o){return o>=1&&o<=4}},{key:"set",value:function(i,o,a){return i.setUTCMonth((a-1)*3,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Cs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Cs=function(n){return typeof n}:Cs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Cs(e)}function pO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function tm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function mO(e,t,n){return t&&tm(e.prototype,t),n&&tm(e,n),e}function vO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Y0(e,t)}function Y0(e,t){return Y0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Y0(e,t)}function gO(e){var t=bO();return function(){var r=ql(e),i;if(t){var o=ql(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return yO(this,i)}}function yO(e,t){return t&&(Cs(t)==="object"||typeof t=="function")?t:X0(e)}function X0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function bO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ql(e){return ql=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},ql(e)}function nm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var $O=function(e){vO(n,e);var t=gO(n);function n(){var r;pO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),nm(X0(r),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),nm(X0(r),"priority",110),r}return mO(n,[{key:"parse",value:function(i,o,a){var s=function(l){return l-1};switch(o){case"M":return tt(Ge(et.month,i),s);case"MM":return tt(Ze(2,i),s);case"Mo":return tt(a.ordinalNumber(i,{unit:"month"}),s);case"MMM":return a.month(i,{width:"abbreviated",context:"formatting"})||a.month(i,{width:"narrow",context:"formatting"});case"MMMMM":return a.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return a.month(i,{width:"wide",context:"formatting"})||a.month(i,{width:"abbreviated",context:"formatting"})||a.month(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=11}},{key:"set",value:function(i,o,a){return i.setUTCMonth(a,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Ns(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ns=function(n){return typeof n}:Ns=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ns(e)}function wO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function rm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function _O(e,t,n){return t&&rm(e.prototype,t),n&&rm(e,n),e}function xO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Z0(e,t)}function Z0(e,t){return Z0=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Z0(e,t)}function kO(e){var t=SO();return function(){var r=Wl(e),i;if(t){var o=Wl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return EO(this,i)}}function EO(e,t){return t&&(Ns(t)==="object"||typeof t=="function")?t:J0(e)}function J0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function SO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Wl(e){return Wl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Wl(e)}function im(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var OO=function(e){xO(n,e);var t=kO(n);function n(){var r;wO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),im(J0(r),"priority",110),im(J0(r),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),r}return _O(n,[{key:"parse",value:function(i,o,a){var s=function(l){return l-1};switch(o){case"L":return tt(Ge(et.month,i),s);case"LL":return tt(Ze(2,i),s);case"Lo":return tt(a.ordinalNumber(i,{unit:"month"}),s);case"LLL":return a.month(i,{width:"abbreviated",context:"standalone"})||a.month(i,{width:"narrow",context:"standalone"});case"LLLLL":return a.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return a.month(i,{width:"wide",context:"standalone"})||a.month(i,{width:"abbreviated",context:"standalone"})||a.month(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=11}},{key:"set",value:function(i,o,a){return i.setUTCMonth(a,1),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function CO(e,t,n){Ue(2,arguments);var r=ft(e),i=Wt(t),o=tb(r,n)-i;return r.setUTCDate(r.getUTCDate()-o*7),r}function Ts(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ts=function(n){return typeof n}:Ts=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ts(e)}function NO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function om(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function TO(e,t,n){return t&&om(e.prototype,t),n&&om(e,n),e}function PO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ef(e,t)}function ef(e,t){return ef=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},ef(e,t)}function AO(e){var t=MO();return function(){var r=Gl(e),i;if(t){var o=Gl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return IO(this,i)}}function IO(e,t){return t&&(Ts(t)==="object"||typeof t=="function")?t:tf(e)}function tf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function MO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Gl(e){return Gl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Gl(e)}function am(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var DO=function(e){PO(n,e);var t=AO(n);function n(){var r;NO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),am(tf(r),"priority",100),am(tf(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),r}return TO(n,[{key:"parse",value:function(i,o,a){switch(o){case"w":return Ge(et.week,i);case"wo":return a.ordinalNumber(i,{unit:"week"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=1&&o<=53}},{key:"set",value:function(i,o,a,s){return Qr(CO(i,a,s),s)}}]),n}(Oe);function LO(e,t){Ue(2,arguments);var n=ft(e),r=Wt(t),i=eb(n)-r;return n.setUTCDate(n.getUTCDate()-i*7),n}function Ps(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ps=function(n){return typeof n}:Ps=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ps(e)}function RO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function sm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function FO(e,t,n){return t&&sm(e.prototype,t),n&&sm(e,n),e}function zO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&nf(e,t)}function nf(e,t){return nf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},nf(e,t)}function jO(e){var t=UO();return function(){var r=Kl(e),i;if(t){var o=Kl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return VO(this,i)}}function VO(e,t){return t&&(Ps(t)==="object"||typeof t=="function")?t:rf(e)}function rf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function UO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Kl(e){return Kl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Kl(e)}function lm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var BO=function(e){zO(n,e);var t=jO(n);function n(){var r;RO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),lm(rf(r),"priority",100),lm(rf(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),r}return FO(n,[{key:"parse",value:function(i,o,a){switch(o){case"I":return Ge(et.week,i);case"Io":return a.ordinalNumber(i,{unit:"week"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=1&&o<=53}},{key:"set",value:function(i,o,a){return Hi(LO(i,a))}}]),n}(Oe);function As(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?As=function(n){return typeof n}:As=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},As(e)}function HO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function qO(e,t,n){return t&&cm(e.prototype,t),n&&cm(e,n),e}function WO(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&of(e,t)}function of(e,t){return of=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},of(e,t)}function GO(e){var t=QO();return function(){var r=Ql(e),i;if(t){var o=Ql(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return KO(this,i)}}function KO(e,t){return t&&(As(t)==="object"||typeof t=="function")?t:Is(e)}function Is(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function QO(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Ql(e){return Ql=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Ql(e)}function od(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var YO=[31,28,31,30,31,30,31,31,30,31,30,31],XO=[31,29,31,30,31,30,31,31,30,31,30,31],ZO=function(e){WO(n,e);var t=GO(n);function n(){var r;HO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),od(Is(r),"priority",90),od(Is(r),"subPriority",1),od(Is(r),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),r}return qO(n,[{key:"parse",value:function(i,o,a){switch(o){case"d":return Ge(et.date,i);case"do":return a.ordinalNumber(i,{unit:"date"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){var a=i.getUTCFullYear(),s=db(a),c=i.getUTCMonth();return s?o>=1&&o<=XO[c]:o>=1&&o<=YO[c]}},{key:"set",value:function(i,o,a){return i.setUTCDate(a),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Ms(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ms=function(n){return typeof n}:Ms=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ms(e)}function JO(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function um(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function eC(e,t,n){return t&&um(e.prototype,t),n&&um(e,n),e}function tC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&af(e,t)}function af(e,t){return af=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},af(e,t)}function nC(e){var t=iC();return function(){var r=Yl(e),i;if(t){var o=Yl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return rC(this,i)}}function rC(e,t){return t&&(Ms(t)==="object"||typeof t=="function")?t:Ds(e)}function Ds(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function iC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Yl(e){return Yl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Yl(e)}function ad(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var oC=function(e){tC(n,e);var t=nC(n);function n(){var r;JO(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),ad(Ds(r),"priority",90),ad(Ds(r),"subpriority",1),ad(Ds(r),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),r}return eC(n,[{key:"parse",value:function(i,o,a){switch(o){case"D":case"DD":return Ge(et.dayOfYear,i);case"Do":return a.ordinalNumber(i,{unit:"date"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){var a=i.getUTCFullYear(),s=db(a);return s?o>=1&&o<=366:o>=1&&o<=365}},{key:"set",value:function(i,o,a){return i.setUTCMonth(0,a),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function c1(e,t,n){var r,i,o,a,s,c,l,u;Ue(2,arguments);var d=uo(),f=Wt((r=(i=(o=(a=n?.weekStartsOn)!==null&&a!==void 0?a:n==null||(s=n.locale)===null||s===void 0||(c=s.options)===null||c===void 0?void 0:c.weekStartsOn)!==null&&o!==void 0?o:d.weekStartsOn)!==null&&i!==void 0?i:(l=d.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.weekStartsOn)!==null&&r!==void 0?r:0);if(!(f>=0&&f<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=ft(e),p=Wt(t),m=h.getUTCDay(),v=p%7,b=(v+7)%7,y=(b<f?7:0)+p-m;return h.setUTCDate(h.getUTCDate()+y),h}function Ls(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ls=function(n){return typeof n}:Ls=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ls(e)}function aC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function dm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function sC(e,t,n){return t&&dm(e.prototype,t),n&&dm(e,n),e}function lC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&sf(e,t)}function sf(e,t){return sf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},sf(e,t)}function cC(e){var t=dC();return function(){var r=Xl(e),i;if(t){var o=Xl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return uC(this,i)}}function uC(e,t){return t&&(Ls(t)==="object"||typeof t=="function")?t:lf(e)}function lf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function dC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Xl(e){return Xl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Xl(e)}function fm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var fC=function(e){lC(n,e);var t=cC(n);function n(){var r;aC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),fm(lf(r),"priority",90),fm(lf(r),"incompatibleTokens",["D","i","e","c","t","T"]),r}return sC(n,[{key:"parse",value:function(i,o,a){switch(o){case"E":case"EE":case"EEE":return a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"});case"EEEEE":return a.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"});case"EEEE":default:return a.day(i,{width:"wide",context:"formatting"})||a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=6}},{key:"set",value:function(i,o,a,s){return i=c1(i,a,s),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Rs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Rs=function(n){return typeof n}:Rs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Rs(e)}function hC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function pC(e,t,n){return t&&hm(e.prototype,t),n&&hm(e,n),e}function mC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&cf(e,t)}function cf(e,t){return cf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},cf(e,t)}function vC(e){var t=yC();return function(){var r=Zl(e),i;if(t){var o=Zl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return gC(this,i)}}function gC(e,t){return t&&(Rs(t)==="object"||typeof t=="function")?t:uf(e)}function uf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Zl(e){return Zl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Zl(e)}function pm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var bC=function(e){mC(n,e);var t=vC(n);function n(){var r;hC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),pm(uf(r),"priority",90),pm(uf(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),r}return pC(n,[{key:"parse",value:function(i,o,a,s){var c=function(u){var d=Math.floor((u-1)/7)*7;return(u+s.weekStartsOn+6)%7+d};switch(o){case"e":case"ee":return tt(Ze(o.length,i),c);case"eo":return tt(a.ordinalNumber(i,{unit:"day"}),c);case"eee":return a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"});case"eeeee":return a.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"});case"eeee":default:return a.day(i,{width:"wide",context:"formatting"})||a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=6}},{key:"set",value:function(i,o,a,s){return i=c1(i,a,s),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function Fs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Fs=function(n){return typeof n}:Fs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Fs(e)}function $C(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function mm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function wC(e,t,n){return t&&mm(e.prototype,t),n&&mm(e,n),e}function _C(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&df(e,t)}function df(e,t){return df=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},df(e,t)}function xC(e){var t=EC();return function(){var r=Jl(e),i;if(t){var o=Jl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return kC(this,i)}}function kC(e,t){return t&&(Fs(t)==="object"||typeof t=="function")?t:ff(e)}function ff(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function EC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Jl(e){return Jl=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},Jl(e)}function vm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var SC=function(e){_C(n,e);var t=xC(n);function n(){var r;$C(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),vm(ff(r),"priority",90),vm(ff(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),r}return wC(n,[{key:"parse",value:function(i,o,a,s){var c=function(u){var d=Math.floor((u-1)/7)*7;return(u+s.weekStartsOn+6)%7+d};switch(o){case"c":case"cc":return tt(Ze(o.length,i),c);case"co":return tt(a.ordinalNumber(i,{unit:"day"}),c);case"ccc":return a.day(i,{width:"abbreviated",context:"standalone"})||a.day(i,{width:"short",context:"standalone"})||a.day(i,{width:"narrow",context:"standalone"});case"ccccc":return a.day(i,{width:"narrow",context:"standalone"});case"cccccc":return a.day(i,{width:"short",context:"standalone"})||a.day(i,{width:"narrow",context:"standalone"});case"cccc":default:return a.day(i,{width:"wide",context:"standalone"})||a.day(i,{width:"abbreviated",context:"standalone"})||a.day(i,{width:"short",context:"standalone"})||a.day(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,o){return o>=0&&o<=6}},{key:"set",value:function(i,o,a,s){return i=c1(i,a,s),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function OC(e,t){Ue(2,arguments);var n=Wt(t);n%7===0&&(n=n-7);var r=1,i=ft(e),o=i.getUTCDay(),a=n%7,s=(a+7)%7,c=(s<r?7:0)+n-o;return i.setUTCDate(i.getUTCDate()+c),i}function zs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?zs=function(n){return typeof n}:zs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},zs(e)}function CC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function gm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function NC(e,t,n){return t&&gm(e.prototype,t),n&&gm(e,n),e}function TC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&hf(e,t)}function hf(e,t){return hf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},hf(e,t)}function PC(e){var t=IC();return function(){var r=ec(e),i;if(t){var o=ec(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return AC(this,i)}}function AC(e,t){return t&&(zs(t)==="object"||typeof t=="function")?t:pf(e)}function pf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function IC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ec(e){return ec=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},ec(e)}function ym(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var MC=function(e){TC(n,e);var t=PC(n);function n(){var r;CC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),ym(pf(r),"priority",90),ym(pf(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),r}return NC(n,[{key:"parse",value:function(i,o,a){var s=function(l){return l===0?7:l};switch(o){case"i":case"ii":return Ze(o.length,i);case"io":return a.ordinalNumber(i,{unit:"day"});case"iii":return tt(a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"}),s);case"iiiii":return tt(a.day(i,{width:"narrow",context:"formatting"}),s);case"iiiiii":return tt(a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"}),s);case"iiii":default:return tt(a.day(i,{width:"wide",context:"formatting"})||a.day(i,{width:"abbreviated",context:"formatting"})||a.day(i,{width:"short",context:"formatting"})||a.day(i,{width:"narrow",context:"formatting"}),s)}}},{key:"validate",value:function(i,o){return o>=1&&o<=7}},{key:"set",value:function(i,o,a){return i=OC(i,a),i.setUTCHours(0,0,0,0),i}}]),n}(Oe);function js(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?js=function(n){return typeof n}:js=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},js(e)}function DC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function bm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function LC(e,t,n){return t&&bm(e.prototype,t),n&&bm(e,n),e}function RC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&mf(e,t)}function mf(e,t){return mf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},mf(e,t)}function FC(e){var t=jC();return function(){var r=tc(e),i;if(t){var o=tc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return zC(this,i)}}function zC(e,t){return t&&(js(t)==="object"||typeof t=="function")?t:vf(e)}function vf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function jC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function tc(e){return tc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},tc(e)}function $m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var VC=function(e){RC(n,e);var t=FC(n);function n(){var r;DC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),$m(vf(r),"priority",80),$m(vf(r),"incompatibleTokens",["b","B","H","k","t","T"]),r}return LC(n,[{key:"parse",value:function(i,o,a){switch(o){case"a":case"aa":case"aaa":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaaa":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})||a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,o,a){return i.setUTCHours(l1(a),0,0,0),i}}]),n}(Oe);function Vs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Vs=function(n){return typeof n}:Vs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Vs(e)}function UC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function wm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function BC(e,t,n){return t&&wm(e.prototype,t),n&&wm(e,n),e}function HC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&gf(e,t)}function gf(e,t){return gf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},gf(e,t)}function qC(e){var t=GC();return function(){var r=nc(e),i;if(t){var o=nc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return WC(this,i)}}function WC(e,t){return t&&(Vs(t)==="object"||typeof t=="function")?t:yf(e)}function yf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function GC(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function nc(e){return nc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},nc(e)}function _m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var KC=function(e){HC(n,e);var t=qC(n);function n(){var r;UC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),_m(yf(r),"priority",80),_m(yf(r),"incompatibleTokens",["a","B","H","k","t","T"]),r}return BC(n,[{key:"parse",value:function(i,o,a){switch(o){case"b":case"bb":case"bbb":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbbb":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})||a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,o,a){return i.setUTCHours(l1(a),0,0,0),i}}]),n}(Oe);function Us(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Us=function(n){return typeof n}:Us=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Us(e)}function QC(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function xm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function YC(e,t,n){return t&&xm(e.prototype,t),n&&xm(e,n),e}function XC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&bf(e,t)}function bf(e,t){return bf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},bf(e,t)}function ZC(e){var t=eN();return function(){var r=rc(e),i;if(t){var o=rc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return JC(this,i)}}function JC(e,t){return t&&(Us(t)==="object"||typeof t=="function")?t:$f(e)}function $f(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function eN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function rc(e){return rc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},rc(e)}function km(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var tN=function(e){XC(n,e);var t=ZC(n);function n(){var r;QC(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),km($f(r),"priority",80),km($f(r),"incompatibleTokens",["a","b","t","T"]),r}return YC(n,[{key:"parse",value:function(i,o,a){switch(o){case"B":case"BB":case"BBB":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBBB":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})||a.dayPeriod(i,{width:"abbreviated",context:"formatting"})||a.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,o,a){return i.setUTCHours(l1(a),0,0,0),i}}]),n}(Oe);function Bs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Bs=function(n){return typeof n}:Bs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Bs(e)}function nN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Em(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function rN(e,t,n){return t&&Em(e.prototype,t),n&&Em(e,n),e}function iN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&wf(e,t)}function wf(e,t){return wf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},wf(e,t)}function oN(e){var t=sN();return function(){var r=ic(e),i;if(t){var o=ic(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return aN(this,i)}}function aN(e,t){return t&&(Bs(t)==="object"||typeof t=="function")?t:_f(e)}function _f(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function sN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ic(e){return ic=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},ic(e)}function Sm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var lN=function(e){iN(n,e);var t=oN(n);function n(){var r;nN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Sm(_f(r),"priority",70),Sm(_f(r),"incompatibleTokens",["H","K","k","t","T"]),r}return rN(n,[{key:"parse",value:function(i,o,a){switch(o){case"h":return Ge(et.hour12h,i);case"ho":return a.ordinalNumber(i,{unit:"hour"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=1&&o<=12}},{key:"set",value:function(i,o,a){var s=i.getUTCHours()>=12;return s&&a<12?i.setUTCHours(a+12,0,0,0):!s&&a===12?i.setUTCHours(0,0,0,0):i.setUTCHours(a,0,0,0),i}}]),n}(Oe);function Hs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Hs=function(n){return typeof n}:Hs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Hs(e)}function cN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Om(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function uN(e,t,n){return t&&Om(e.prototype,t),n&&Om(e,n),e}function dN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&xf(e,t)}function xf(e,t){return xf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},xf(e,t)}function fN(e){var t=pN();return function(){var r=oc(e),i;if(t){var o=oc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return hN(this,i)}}function hN(e,t){return t&&(Hs(t)==="object"||typeof t=="function")?t:kf(e)}function kf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function pN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function oc(e){return oc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},oc(e)}function Cm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var mN=function(e){dN(n,e);var t=fN(n);function n(){var r;cN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Cm(kf(r),"priority",70),Cm(kf(r),"incompatibleTokens",["a","b","h","K","k","t","T"]),r}return uN(n,[{key:"parse",value:function(i,o,a){switch(o){case"H":return Ge(et.hour23h,i);case"Ho":return a.ordinalNumber(i,{unit:"hour"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=0&&o<=23}},{key:"set",value:function(i,o,a){return i.setUTCHours(a,0,0,0),i}}]),n}(Oe);function qs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?qs=function(n){return typeof n}:qs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},qs(e)}function vN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Nm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function gN(e,t,n){return t&&Nm(e.prototype,t),n&&Nm(e,n),e}function yN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Ef(e,t)}function Ef(e,t){return Ef=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Ef(e,t)}function bN(e){var t=wN();return function(){var r=ac(e),i;if(t){var o=ac(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return $N(this,i)}}function $N(e,t){return t&&(qs(t)==="object"||typeof t=="function")?t:Sf(e)}function Sf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ac(e){return ac=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},ac(e)}function Tm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var _N=function(e){yN(n,e);var t=bN(n);function n(){var r;vN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Tm(Sf(r),"priority",70),Tm(Sf(r),"incompatibleTokens",["h","H","k","t","T"]),r}return gN(n,[{key:"parse",value:function(i,o,a){switch(o){case"K":return Ge(et.hour11h,i);case"Ko":return a.ordinalNumber(i,{unit:"hour"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=0&&o<=11}},{key:"set",value:function(i,o,a){var s=i.getUTCHours()>=12;return s&&a<12?i.setUTCHours(a+12,0,0,0):i.setUTCHours(a,0,0,0),i}}]),n}(Oe);function Ws(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ws=function(n){return typeof n}:Ws=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ws(e)}function xN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Pm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function kN(e,t,n){return t&&Pm(e.prototype,t),n&&Pm(e,n),e}function EN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Of(e,t)}function Of(e,t){return Of=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Of(e,t)}function SN(e){var t=CN();return function(){var r=sc(e),i;if(t){var o=sc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return ON(this,i)}}function ON(e,t){return t&&(Ws(t)==="object"||typeof t=="function")?t:Cf(e)}function Cf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function CN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function sc(e){return sc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},sc(e)}function Am(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var NN=function(e){EN(n,e);var t=SN(n);function n(){var r;xN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Am(Cf(r),"priority",70),Am(Cf(r),"incompatibleTokens",["a","b","h","H","K","t","T"]),r}return kN(n,[{key:"parse",value:function(i,o,a){switch(o){case"k":return Ge(et.hour24h,i);case"ko":return a.ordinalNumber(i,{unit:"hour"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=1&&o<=24}},{key:"set",value:function(i,o,a){var s=a<=24?a%24:a;return i.setUTCHours(s,0,0,0),i}}]),n}(Oe);function Gs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Gs=function(n){return typeof n}:Gs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Gs(e)}function TN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Im(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function PN(e,t,n){return t&&Im(e.prototype,t),n&&Im(e,n),e}function AN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Nf(e,t)}function Nf(e,t){return Nf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Nf(e,t)}function IN(e){var t=DN();return function(){var r=lc(e),i;if(t){var o=lc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return MN(this,i)}}function MN(e,t){return t&&(Gs(t)==="object"||typeof t=="function")?t:Tf(e)}function Tf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function DN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function lc(e){return lc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},lc(e)}function Mm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var LN=function(e){AN(n,e);var t=IN(n);function n(){var r;TN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Mm(Tf(r),"priority",60),Mm(Tf(r),"incompatibleTokens",["t","T"]),r}return PN(n,[{key:"parse",value:function(i,o,a){switch(o){case"m":return Ge(et.minute,i);case"mo":return a.ordinalNumber(i,{unit:"minute"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=0&&o<=59}},{key:"set",value:function(i,o,a){return i.setUTCMinutes(a,0,0),i}}]),n}(Oe);function Ks(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ks=function(n){return typeof n}:Ks=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ks(e)}function RN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Dm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function FN(e,t,n){return t&&Dm(e.prototype,t),n&&Dm(e,n),e}function zN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Pf(e,t)}function Pf(e,t){return Pf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Pf(e,t)}function jN(e){var t=UN();return function(){var r=cc(e),i;if(t){var o=cc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return VN(this,i)}}function VN(e,t){return t&&(Ks(t)==="object"||typeof t=="function")?t:Af(e)}function Af(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function UN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function cc(e){return cc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},cc(e)}function Lm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var BN=function(e){zN(n,e);var t=jN(n);function n(){var r;RN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Lm(Af(r),"priority",50),Lm(Af(r),"incompatibleTokens",["t","T"]),r}return FN(n,[{key:"parse",value:function(i,o,a){switch(o){case"s":return Ge(et.second,i);case"so":return a.ordinalNumber(i,{unit:"second"});default:return Ze(o.length,i)}}},{key:"validate",value:function(i,o){return o>=0&&o<=59}},{key:"set",value:function(i,o,a){return i.setUTCSeconds(a,0),i}}]),n}(Oe);function Qs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Qs=function(n){return typeof n}:Qs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Qs(e)}function HN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Rm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function qN(e,t,n){return t&&Rm(e.prototype,t),n&&Rm(e,n),e}function WN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&If(e,t)}function If(e,t){return If=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},If(e,t)}function GN(e){var t=QN();return function(){var r=uc(e),i;if(t){var o=uc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return KN(this,i)}}function KN(e,t){return t&&(Qs(t)==="object"||typeof t=="function")?t:Mf(e)}function Mf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function QN(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function uc(e){return uc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},uc(e)}function Fm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var YN=function(e){WN(n,e);var t=GN(n);function n(){var r;HN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Fm(Mf(r),"priority",30),Fm(Mf(r),"incompatibleTokens",["t","T"]),r}return qN(n,[{key:"parse",value:function(i,o){var a=function(c){return Math.floor(c*Math.pow(10,-o.length+3))};return tt(Ze(o.length,i),a)}},{key:"set",value:function(i,o,a){return i.setUTCMilliseconds(a),i}}]),n}(Oe);function Ys(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Ys=function(n){return typeof n}:Ys=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ys(e)}function XN(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function zm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function ZN(e,t,n){return t&&zm(e.prototype,t),n&&zm(e,n),e}function JN(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Df(e,t)}function Df(e,t){return Df=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Df(e,t)}function eT(e){var t=nT();return function(){var r=dc(e),i;if(t){var o=dc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return tT(this,i)}}function tT(e,t){return t&&(Ys(t)==="object"||typeof t=="function")?t:Lf(e)}function Lf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function nT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function dc(e){return dc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},dc(e)}function jm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var rT=function(e){JN(n,e);var t=eT(n);function n(){var r;XN(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),jm(Lf(r),"priority",10),jm(Lf(r),"incompatibleTokens",["t","T","x"]),r}return ZN(n,[{key:"parse",value:function(i,o){switch(o){case"X":return En(kn.basicOptionalMinutes,i);case"XX":return En(kn.basic,i);case"XXXX":return En(kn.basicOptionalSeconds,i);case"XXXXX":return En(kn.extendedOptionalSeconds,i);case"XXX":default:return En(kn.extended,i)}}},{key:"set",value:function(i,o,a){return o.timestampIsSet?i:new Date(i.getTime()-a)}}]),n}(Oe);function Xs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Xs=function(n){return typeof n}:Xs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Xs(e)}function iT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Vm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function oT(e,t,n){return t&&Vm(e.prototype,t),n&&Vm(e,n),e}function aT(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Rf(e,t)}function Rf(e,t){return Rf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Rf(e,t)}function sT(e){var t=cT();return function(){var r=fc(e),i;if(t){var o=fc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return lT(this,i)}}function lT(e,t){return t&&(Xs(t)==="object"||typeof t=="function")?t:Ff(e)}function Ff(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function cT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function fc(e){return fc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},fc(e)}function Um(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var uT=function(e){aT(n,e);var t=sT(n);function n(){var r;iT(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Um(Ff(r),"priority",10),Um(Ff(r),"incompatibleTokens",["t","T","X"]),r}return oT(n,[{key:"parse",value:function(i,o){switch(o){case"x":return En(kn.basicOptionalMinutes,i);case"xx":return En(kn.basic,i);case"xxxx":return En(kn.basicOptionalSeconds,i);case"xxxxx":return En(kn.extendedOptionalSeconds,i);case"xxx":default:return En(kn.extended,i)}}},{key:"set",value:function(i,o,a){return o.timestampIsSet?i:new Date(i.getTime()-a)}}]),n}(Oe);function Zs(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Zs=function(n){return typeof n}:Zs=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Zs(e)}function dT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Bm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function fT(e,t,n){return t&&Bm(e.prototype,t),n&&Bm(e,n),e}function hT(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&zf(e,t)}function zf(e,t){return zf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},zf(e,t)}function pT(e){var t=vT();return function(){var r=hc(e),i;if(t){var o=hc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return mT(this,i)}}function mT(e,t){return t&&(Zs(t)==="object"||typeof t=="function")?t:jf(e)}function jf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function vT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function hc(e){return hc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},hc(e)}function Hm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var gT=function(e){hT(n,e);var t=pT(n);function n(){var r;dT(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Hm(jf(r),"priority",40),Hm(jf(r),"incompatibleTokens","*"),r}return fT(n,[{key:"parse",value:function(i){return cb(i)}},{key:"set",value:function(i,o,a){return[new Date(a*1e3),{timestampIsSet:!0}]}}]),n}(Oe);function Js(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Js=function(n){return typeof n}:Js=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Js(e)}function yT(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function qm(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function bT(e,t,n){return t&&qm(e.prototype,t),n&&qm(e,n),e}function $T(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Vf(e,t)}function Vf(e,t){return Vf=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},Vf(e,t)}function wT(e){var t=xT();return function(){var r=pc(e),i;if(t){var o=pc(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return _T(this,i)}}function _T(e,t){return t&&(Js(t)==="object"||typeof t=="function")?t:Uf(e)}function Uf(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function xT(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function pc(e){return pc=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},pc(e)}function Wm(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var kT=function(e){$T(n,e);var t=wT(n);function n(){var r;yT(this,n);for(var i=arguments.length,o=new Array(i),a=0;a<i;a++)o[a]=arguments[a];return r=t.call.apply(t,[this].concat(o)),Wm(Uf(r),"priority",20),Wm(Uf(r),"incompatibleTokens","*"),r}return bT(n,[{key:"parse",value:function(i){return cb(i)}},{key:"set",value:function(i,o,a){return[new Date(a),{timestampIsSet:!0}]}}]),n}(Oe),ET={G:new ES,y:new AS,Y:new zS,R:new WS,u:new JS,Q:new aO,q:new hO,M:new $O,L:new OO,w:new DO,I:new BO,d:new ZO,D:new oC,E:new fC,e:new bC,c:new SC,i:new MC,a:new VC,b:new KC,B:new tN,h:new lN,H:new mN,K:new _N,k:new NN,m:new LN,s:new BN,S:new YN,X:new rT,x:new uT,t:new gT,T:new kT};function el(e){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?el=function(n){return typeof n}:el=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},el(e)}function Gm(e,t){var n;if(typeof Symbol>"u"||e[Symbol.iterator]==null){if(Array.isArray(e)||(n=ST(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(l){throw l},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
2256
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var o=!0,a=!1,s;return{s:function(){n=e[Symbol.iterator]()},n:function(){var l=n.next();return o=l.done,l},e:function(l){a=!0,s=l},f:function(){try{!o&&n.return!=null&&n.return()}finally{if(a)throw s}}}}function ST(e,t){if(!!e){if(typeof e=="string")return Km(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Km(e,t)}}function Km(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var OT=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,CT=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,NT=/^'([^]*?)'?$/,TT=/''/g,PT=/\S/,AT=/[a-zA-Z]/;function IT(e,t,n,r){var i,o,a,s,c,l,u,d,f,h,p,m,v,b,y,g,_,k;Ue(3,arguments);var O=String(e),C=String(t),M=uo(),D=(i=(o=r?.locale)!==null&&o!==void 0?o:M.locale)!==null&&i!==void 0?i:ob;if(!D.match)throw new RangeError("locale must contain match property");var F=Wt((a=(s=(c=(l=r?.firstWeekContainsDate)!==null&&l!==void 0?l:r==null||(u=r.locale)===null||u===void 0||(d=u.options)===null||d===void 0?void 0:d.firstWeekContainsDate)!==null&&c!==void 0?c:M.firstWeekContainsDate)!==null&&s!==void 0?s:(f=M.locale)===null||f===void 0||(h=f.options)===null||h===void 0?void 0:h.firstWeekContainsDate)!==null&&a!==void 0?a:1);if(!(F>=1&&F<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var Y=Wt((p=(m=(v=(b=r?.weekStartsOn)!==null&&b!==void 0?b:r==null||(y=r.locale)===null||y===void 0||(g=y.options)===null||g===void 0?void 0:g.weekStartsOn)!==null&&v!==void 0?v:M.weekStartsOn)!==null&&m!==void 0?m:(_=M.locale)===null||_===void 0||(k=_.options)===null||k===void 0?void 0:k.weekStartsOn)!==null&&p!==void 0?p:0);if(!(Y>=0&&Y<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(C==="")return O===""?ft(n):new Date(NaN);var J={firstWeekContainsDate:F,weekStartsOn:Y,locale:D},G=[new vS],j=C.match(CT).map(function(ce){var re=ce[0];if(re in A0){var ae=A0[re];return ae(ce,D.formatLong)}return ce}).join("").match(OT),z=[],Q=Gm(j),I;try{var U=function(){var re=I.value;!(r!=null&&r.useAdditionalWeekYearTokens)&&ib(re)&&Dl(re,C,e),!(r!=null&&r.useAdditionalDayOfYearTokens)&&rb(re)&&Dl(re,C,e);var ae=re[0],_e=ET[ae];if(_e){var it=_e.incompatibleTokens;if(Array.isArray(it)){var kt=z.find(function(Vt){return it.includes(Vt.token)||Vt.token===ae});if(kt)throw new RangeError("The format string mustn't contain `".concat(kt.fullToken,"` and `").concat(re,"` at the same time"))}else if(_e.incompatibleTokens==="*"&&z.length>0)throw new RangeError("The format string mustn't contain `".concat(re,"` and any other token at the same time"));z.push({token:ae,fullToken:re});var mt=_e.run(O,re,D.match,J);if(!mt)return{v:new Date(NaN)};G.push(mt.setter),O=mt.rest}else{if(ae.match(AT))throw new RangeError("Format string contains an unescaped latin alphabet character `"+ae+"`");if(re==="''"?re="'":ae==="'"&&(re=MT(re)),O.indexOf(re)===0)O=O.slice(re.length);else return{v:new Date(NaN)}}};for(Q.s();!(I=Q.n()).done;){var W=U();if(el(W)==="object")return W.v}}catch(ce){Q.e(ce)}finally{Q.f()}if(O.length>0&&PT.test(O))return new Date(NaN);var de=G.map(function(ce){return ce.priority}).sort(function(ce,re){return re-ce}).filter(function(ce,re,ae){return ae.indexOf(ce)===re}).map(function(ce){return G.filter(function(re){return re.priority===ce}).sort(function(re,ae){return ae.subPriority-re.subPriority})}).map(function(ce){return ce[0]}),be=ft(n);if(isNaN(be.getTime()))return new Date(NaN);var P=Z3(be,Y3(be)),B={},Ce=Gm(de),te;try{for(Ce.s();!(te=Ce.n()).done;){var ye=te.value;if(!ye.validate(P,J))return new Date(NaN);var Ne=ye.set(P,B,J);Array.isArray(Ne)?(P=Ne[0],dS(B,Ne[1])):P=Ne}}catch(ce){Ce.e(ce)}finally{Ce.f()}return P}function MT(e){return e.match(NT)[1].replace(TT,"'")}function DT(e){return Ue(1,arguments),tE(e,Date.now())}const st=(e,t)=>lo("message",n=>K3(n,e)?!0:t),LT=lo("NotFutureDate",e=>{const t=new Date(e);if(!(t instanceof Date))return!1;const n=new Date;return t<=n}),RT=(e,t=n=>IT(n,"yyyy-MM-dd",new Date))=>lo("between",function(r){return sE(t(r),e)>=0||DT(t(r))}),FT=()=>Sa(Kt(),"zipString",e=>/^\d{5}(-\d{4})?$/.test(e)),zT=()=>Sa(Kt(),"email",e=>e.length===0?!0:/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/.test(e)),sd=()=>Sa(co(),"empty",e=>e===null||e==null),jT=["allowfullscreen","async","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected"],VT=new Set(["className","value","readOnly","formNoValidate","isMap","noModule","playsInline",...jT]),UT=new Set(["innerHTML","textContent","innerText","children"]),BT=Object.assign(Object.create(null),{className:"class",htmlFor:"for"}),Qm=Object.assign(Object.create(null),{class:"className",formnovalidate:"formNoValidate",ismap:"isMap",nomodule:"noModule",playsinline:"playsInline",readonly:"readOnly"}),HT=new Set(["beforeinput","click","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"]),qT={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"};function WT(e,t,n){let r=n.length,i=t.length,o=r,a=0,s=0,c=t[i-1].nextSibling,l=null;for(;a<i||s<o;){if(t[a]===n[s]){a++,s++;continue}for(;t[i-1]===n[o-1];)i--,o--;if(i===a){const u=o<r?s?n[s-1].nextSibling:n[o-s]:c;for(;s<o;)e.insertBefore(n[s++],u)}else if(o===s)for(;a<i;)(!l||!l.has(t[a]))&&t[a].remove(),a++;else if(t[a]===n[o-1]&&n[s]===t[i-1]){const u=t[--i].nextSibling;e.insertBefore(n[s++],t[a++].nextSibling),e.insertBefore(n[--o],u),t[i]=n[o]}else{if(!l){l=new Map;let d=s;for(;d<o;)l.set(n[d],d++)}const u=l.get(t[a]);if(u!=null)if(s<u&&u<o){let d=a,f=1,h;for(;++d<i&&d<o&&!((h=l.get(t[d]))==null||h!==u+f);)f++;if(f>u-s){const p=t[a];for(;s<u;)e.insertBefore(n[s++],p)}else e.replaceChild(n[s++],t[a++])}else a++;else t[a++].remove()}}}const Ym="_$DX_DELEGATE";function $(e,t,n){const r=document.createElement("template");r.innerHTML=e;let i=r.content.firstChild;return n&&(i=i.firstChild),i}function Yc(e,t=window.document){const n=t[Ym]||(t[Ym]=new Set);for(let r=0,i=e.length;r<i;r++){const o=e[r];n.has(o)||(n.add(o),t.addEventListener(o,JT))}}function ca(e,t,n){n==null?e.removeAttribute(t):e.setAttribute(t,n)}function GT(e,t,n,r){r==null?e.removeAttributeNS(t,n):e.setAttributeNS(t,n,r)}function Oa(e,t){t==null?e.removeAttribute("class"):e.className=t}function fb(e,t,n,r){if(r)Array.isArray(n)?(e[`$$${t}`]=n[0],e[`$$${t}Data`]=n[1]):e[`$$${t}`]=n;else if(Array.isArray(n)){const i=n[0];e.addEventListener(t,n[0]=o=>i.call(e,n[1],o))}else e.addEventListener(t,n)}function KT(e,t,n={}){const r=Object.keys(t||{}),i=Object.keys(n);let o,a;for(o=0,a=i.length;o<a;o++){const s=i[o];!s||s==="undefined"||t[s]||(Xm(e,s,!1),delete n[s])}for(o=0,a=r.length;o<a;o++){const s=r[o],c=!!t[s];!s||s==="undefined"||n[s]===c||!c||(Xm(e,s,!0),n[s]=c)}return n}function QT(e,t,n){if(!t)return n?ca(e,"style"):t;const r=e.style;if(typeof t=="string")return r.cssText=t;typeof n=="string"&&(r.cssText=n=void 0),n||(n={}),t||(t={});let i,o;for(o in n)t[o]==null&&r.removeProperty(o),delete n[o];for(o in t)i=t[o],i!==n[o]&&(r.setProperty(o,i),n[o]=i);return n}function u1(e,t={},n,r){const i={};return r||q(()=>i.children=qi(e,t.children,i.children)),q(()=>t.ref&&t.ref(e)),q(()=>XT(e,t,n,!0,i,!0)),i}function YT(e,t,n){return H(()=>e(t,n))}function ie(e,t,n,r){if(n!==void 0&&!r&&(r=[]),typeof t!="function")return qi(e,t,r,n);q(i=>qi(e,t(),i,n),r)}function XT(e,t,n,r,i={},o=!1){t||(t={});for(const a in i)if(!(a in t)){if(a==="children")continue;i[a]=Zm(e,a,null,i[a],n,o)}for(const a in t){if(a==="children"){r||qi(e,t.children);continue}const s=t[a];i[a]=Zm(e,a,s,i[a],n,o)}}function ZT(e){return e.toLowerCase().replace(/-([a-z])/g,(t,n)=>n.toUpperCase())}function Xm(e,t,n){const r=t.trim().split(/\s+/);for(let i=0,o=r.length;i<o;i++)e.classList.toggle(r[i],n)}function Zm(e,t,n,r,i,o){let a,s,c;if(t==="style")return QT(e,n,r);if(t==="classList")return KT(e,n,r);if(n===r)return r;if(t==="ref")o||n(e);else if(t.slice(0,3)==="on:"){const l=t.slice(3);r&&e.removeEventListener(l,r),n&&e.addEventListener(l,n)}else if(t.slice(0,10)==="oncapture:"){const l=t.slice(10);r&&e.removeEventListener(l,r,!0),n&&e.addEventListener(l,n,!0)}else if(t.slice(0,2)==="on"){const l=t.slice(2).toLowerCase(),u=HT.has(l);if(!u&&r){const d=Array.isArray(r)?r[0]:r;e.removeEventListener(l,d)}(u||n)&&(fb(e,l,n,u),u&&Yc([l]))}else if((c=UT.has(t))||!i&&(Qm[t]||(s=VT.has(t)))||(a=e.nodeName.includes("-")))t==="class"||t==="className"?Oa(e,n):a&&!s&&!c?e[ZT(t)]=n:e[Qm[t]||t]=n;else{const l=i&&t.indexOf(":")>-1&&qT[t.split(":")[0]];l?GT(e,l,t,n):ca(e,BT[t]||t,n)}return n}function JT(e){const t=`$$${e.type}`;let n=e.composedPath&&e.composedPath()[0]||e.target;for(e.target!==n&&Object.defineProperty(e,"target",{configurable:!0,value:n}),Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return n||document}}),dt.registry&&!dt.done&&(dt.done=!0,document.querySelectorAll("[id^=pl-]").forEach(r=>{for(;r&&r.nodeType!==8&&r.nodeValue!=="pl-"+e;){let i=r.nextSibling;r.remove(),r=i}r&&r.remove()}));n;){const r=n[t];if(r&&!n.disabled){const i=n[`${t}Data`];if(i!==void 0?r.call(n,i,e):r.call(n,e),e.cancelBubble)return}n=n._$host||n.parentNode||n.host}}function qi(e,t,n,r,i){for(dt.context&&!n&&(n=[...e.childNodes]);typeof n=="function";)n=n();if(t===n)return n;const o=typeof t,a=r!==void 0;if(e=a&&n[0]&&n[0].parentNode||e,o==="string"||o==="number"){if(dt.context)return n;if(o==="number"&&(t=t.toString()),a){let s=n[0];s&&s.nodeType===3?s.data=t:s=document.createTextNode(t),n=di(e,n,r,s)}else n!==""&&typeof n=="string"?n=e.firstChild.data=t:n=e.textContent=t}else if(t==null||o==="boolean"){if(dt.context)return n;n=di(e,n,r)}else{if(o==="function")return q(()=>{let s=t();for(;typeof s=="function";)s=s();n=qi(e,s,n,r)}),()=>n;if(Array.isArray(t)){const s=[],c=n&&Array.isArray(n);if(Bf(s,t,n,i))return q(()=>n=qi(e,s,n,r,!0)),()=>n;if(dt.context){if(!s.length)return n;for(let l=0;l<s.length;l++)if(s[l].parentNode)return n=s}if(s.length===0){if(n=di(e,n,r),a)return n}else c?n.length===0?Jm(e,s,r):WT(e,n,s):(n&&di(e),Jm(e,s));n=s}else if(t instanceof Node){if(dt.context&&t.parentNode)return n=a?[t]:t;if(Array.isArray(n)){if(a)return n=di(e,n,r,t);di(e,n,null,t)}else n==null||n===""||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}}return n}function Bf(e,t,n,r){let i=!1;for(let o=0,a=t.length;o<a;o++){let s=t[o],c=n&&n[o];if(s instanceof Node)e.push(s);else if(!(s==null||s===!0||s===!1))if(Array.isArray(s))i=Bf(e,s,c)||i;else if(typeof s=="function")if(r){for(;typeof s=="function";)s=s();i=Bf(e,Array.isArray(s)?s:[s],Array.isArray(c)?c:[c])||i}else e.push(s),i=!0;else{const l=String(s);c&&c.nodeType===3&&c.data===l?e.push(c):e.push(document.createTextNode(l))}}return i}function Jm(e,t,n=null){for(let r=0,i=t.length;r<i;r++)e.insertBefore(t[r],n)}function di(e,t,n,r){if(n===void 0)return e.textContent="";const i=r||document.createTextNode("");if(t.length){let o=!1;for(let a=t.length-1;a>=0;a--){const s=t[a];if(i!==s){const c=s.parentNode===e;!o&&!a?c?e.replaceChild(i,s):e.insertBefore(i,n):c&&s.remove()}else o=!0}}else e.insertBefore(i,n);return[i]}function hb(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=hb(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Yr(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=hb(e))&&(r&&(r+=" "),r+=t);return r}const eP=$("<button></button>");function ev(e){const t=Nt({variant:"primary",size:"lg"},e),[n,r]=Ko(t,["variant","size","children","iconLeft"]),i=se(()=>Yr("font-semibold",{"shadow-sm":n.variant!=="naked","rounded-md":["xl","lg","md"].includes(n.size),rounded:!["xl","lg","md"].includes(n.size),"text-xs":n.size==="xs","text-sm":n.size!=="xs","px-3.5 py-2.5":n.size==="xl"&&n.variant!=="naked","px-3 py-2":n.size==="lg"&&n.variant!=="naked","px-2.5 py-1.5":n.size==="md"&&n.variant!=="naked","px-2 py-1":(n.size==="sm"||n.size==="xs")&&n.variant!=="naked","text-white bg-blue-600 hover:bg-blue-500 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 hover:bg-blue-500":n.variant==="primary","rounded bg-white text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 hover:bg-gray-50":n.variant==="secondary","bg-blue-50 text-blue-600 hover:bg-blue-100":n.variant==="tertiary","text-blue-600 hover:text-blue-500 bg-transparent focus:outline-none focus:ring-2 focus:ring-blue-300":n.variant==="naked","opacity-50 cursor-not-allowed":r.disabled,"justify-center inline-flex items-center gap-x-1.5":n?.iconLeft}));return(()=>{const o=eP.cloneNode(!0);return u1(o,Nt(r,{get class(){return i()},type:"button"}),!1,!0),ie(o,S(ee,{get when(){return n?.iconLeft},get children(){return n?.iconLeft}}),null),ie(o,()=>t.children,null),o})()}var mc=function(){return mc=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++){t=arguments[n];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},mc.apply(this,arguments)};function ld(e,t){if(!Boolean(e))throw new Error(t)}function tP(e){return typeof e=="object"&&e!==null}function nP(e,t){if(!Boolean(e))throw new Error(t??"Unexpected invariant triggered.")}const rP=/\r\n|[\n\r]/g;function Hf(e,t){let n=0,r=1;for(const i of e.body.matchAll(rP)){if(typeof i.index=="number"||nP(!1),i.index>=t)break;n=i.index+i[0].length,r+=1}return{line:r,column:t+1-n}}function iP(e){return pb(e.source,Hf(e.source,e.start))}function pb(e,t){const n=e.locationOffset.column-1,r="".padStart(n)+e.body,i=t.line-1,o=e.locationOffset.line-1,a=t.line+o,s=t.line===1?n:0,c=t.column+s,l=`${e.name}:${a}:${c}
|
|
2257
2257
|
`,u=r.split(/\r\n|[\n\r]/g),d=u[i];if(d.length>120){const f=Math.floor(c/80),h=c%80,p=[];for(let m=0;m<d.length;m+=80)p.push(d.slice(m,m+80));return l+tv([[`${a} |`,p[0]],...p.slice(1,f+1).map(m=>["|",m]),["|","^".padStart(h)],["|",p[f+1]]])}return l+tv([[`${a-1} |`,u[i-1]],[`${a} |`,d],["|","^".padStart(c)],[`${a+1} |`,u[i+1]]])}function tv(e){const t=e.filter(([r,i])=>i!==void 0),n=Math.max(...t.map(([r])=>r.length));return t.map(([r,i])=>r.padStart(n)+(i?" "+i:"")).join(`
|
|
2258
2258
|
`)}function oP(e){const t=e[0];return t==null||"kind"in t||"length"in t?{nodes:t,source:e[1],positions:e[2],path:e[3],originalError:e[4],extensions:e[5]}:t}class d1 extends Error{constructor(t,...n){var r,i,o;const{nodes:a,source:s,positions:c,path:l,originalError:u,extensions:d}=oP(n);super(t),this.name="GraphQLError",this.path=l??void 0,this.originalError=u??void 0,this.nodes=nv(Array.isArray(a)?a:a?[a]:void 0);const f=nv((r=this.nodes)===null||r===void 0?void 0:r.map(p=>p.loc).filter(p=>p!=null));this.source=s??(f==null||(i=f[0])===null||i===void 0?void 0:i.source),this.positions=c??f?.map(p=>p.start),this.locations=c&&s?c.map(p=>Hf(s,p)):f?.map(p=>Hf(p.source,p.start));const h=tP(u?.extensions)?u?.extensions:void 0;this.extensions=(o=d??h)!==null&&o!==void 0?o:Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),u!=null&&u.stack?Object.defineProperty(this,"stack",{value:u.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,d1):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let t=this.message;if(this.nodes)for(const n of this.nodes)n.loc&&(t+=`
|
|
2259
2259
|
|
|
@@ -2275,7 +2275,7 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
2275
2275
|
}
|
|
2276
2276
|
}
|
|
2277
2277
|
}
|
|
2278
|
-
`;const OB=e=>e.map((t,n)=>({id:n.toString(),name:t}));function Ao(e){const t=OB(e.options);return S(Lr,{get value(){return t[e.initialIdx||0]},setSelected:n=>e.setSelected(n.name),get children(){return[S(Lr.Input,{displayValue:n=>n.name}),S(Lr.Options,{get children(){return S(sr,{each:t,children:n=>S(Lr.Option,{get key(){return n.id},value:n,get children(){return n.name}})})}})]}})}const sv={weight:{lbs:.453592,kg:1},liquid:{"mcg/kg":{mcg:1,mg:1e3,g:1e6},"mg/kg":{mcg:.001,mg:1,g:1e3},"g/kg":{mcg:1e-6,mg:.001,g:1}}},CB=$('<div class="flex items-center"><h2>Calculate Dose Quantity</h2></div>'),NB=$("<p>Enter desired dosage and patient weight to calculate total and dose quantity.</p>"),TB=$('<div class="my-8"><div class="flex items-center"><h3>Selected Medication</h3></div><p></p></div>'),PB=$('<div class="grid grid-cols-1 sm:grid-cols-2 gap-4"><div class="grid grid-cols-2 gap-4 sm:gap-2"></div><div class="flex gap-4 items-center"><div>per</div><div class="grow"></div></div></div>'),AB=$('<div class="grid grid-cols-1 sm:grid-cols-2 gap-4"><div class="grid grid-cols-2 gap-4 sm:gap-2"></div></div>'),lv=$('<div class="flex gap-4 sm:gap-2"></div>'),IB=$('<section class="mt-8"><div class="flex items-center"><h3>Dosage Inputs</h3></div><div class="grid grid-cols-1 sm:grid-cols-2 sm:gap-4"></div></section>'),MB=$('<section class="mt-8"><div class="flex items-center"><h3>Frequency</h3></div><div class="grid grid-cols-2 gap-4"></div></section>'),DB=$('<section class="mt-8"><div class="flex items-center"><h3>Dosage</h3></div><div class="grid grid-cols-2 gap-4"></div><hr class="h-px mb-4 bg-gray-200 border-0 dark:bg-gray-700 w-full"><div class="grid grid-cols-2 gap-4"></div></section>'),LB=$('<div class="mt-8 flex gap-4 justify-end"></div>'),fi=e=>parseFloat(e.toFixed(1)),cv=["mcg/kg","mg/kg","g/kg"],uv=["day","dose"],dv=["lbs","kg"],fv=["mcg","mg","g"],hv=["mL","L"],Ya=e=>isNaN(e)||!isFinite(e)?0:e;function RB(e){const[t,n]=V(0),[r,i]=V(cv[0]),[o,a]=V(uv[0]),[s,c]=V(0),[l,u]=V(dv[0]),[d,f]=V(0),[h,p]=V(fv[0]),[m,v]=V(0),[b,y]=V(hv[0]),[g,_]=V(1),[x,O]=V(1),C=se(()=>sv.weight[l()]*t()*s()),M=se(()=>{if(!d()||parseInt(d().toString(),10)===0)return 0;const j=sv.liquid[r()][h()];return C()*m()/(d()*j)}),D=se(()=>Ya(o()==="day"?C()/x():C())),F=se(()=>Ya(D()*g()*x())),Y=se(()=>r().split("/")[0]),J=se(()=>Ya(o()==="day"?M()/x():M())),G=se(()=>Ya(J()*g()*x()));return S(SB,{get open(){return e.open},get onClose(){return e.onClose},size:"lg",get children(){return[(()=>{const j=CB.cloneNode(!0),z=j.firstChild;return ie(j,S(fn,{name:"calculator",class:"mr-2"}),z),j})(),NB.cloneNode(!0),(()=>{const j=TB.cloneNode(!0),z=j.firstChild,Q=z.firstChild,I=z.nextSibling;return ie(z,S(fn,{name:"pencilSquare",class:"mr-2"}),Q),ie(I,()=>e?.medicationName||"None Selected"),q(()=>Oa(I,e?.medicationName?"":"@apply text-gray-400")),j})(),(()=>{const j=IB.cloneNode(!0),z=j.firstChild,Q=z.firstChild,I=z.nextSibling;return ie(z,S(fn,{name:"beaker",class:"mr-2"}),Q),ie(j,S(_n,{label:"Dose",get children(){const U=PB.cloneNode(!0),W=U.firstChild,de=W.nextSibling,be=de.firstChild,P=be.nextSibling;return ie(W,S(ln,{type:"number",inputmode:"decimal",get value(){return t()},onInput:B=>n(B.currentTarget?.valueAsNumber)}),null),ie(W,S(Ao,{setSelected:i,options:cv,initialIdx:1}),null),ie(P,S(Ao,{setSelected:a,options:uv})),U}}),I),ie(j,S(_n,{label:"Patient Weight",get children(){const U=AB.cloneNode(!0),W=U.firstChild;return ie(W,S(ln,{type:"number",inputmode:"decimal",get value(){return s()},onInput:de=>c(de.currentTarget?.valueAsNumber)}),null),ie(W,S(Ao,{setSelected:u,options:dv}),null),U}}),I),ie(I,S(_n,{label:"Liquid Concentration",get children(){const U=lv.cloneNode(!0);return ie(U,S(ln,{type:"number",inputmode:"decimal",get value(){return d()},onInput:W=>f(W.currentTarget?.valueAsNumber)}),null),ie(U,S(Ao,{setSelected:p,options:fv,initialIdx:1}),null),U}}),null),ie(I,S(_n,{label:"Per Volume",get children(){const U=lv.cloneNode(!0);return ie(U,S(ln,{type:"number",inputmode:"decimal",get value(){return m()},onInput:W=>v(W.currentTarget?.valueAsNumber)}),null),ie(U,S(Ao,{setSelected:y,options:hv}),null),U}}),null),j})(),(()=>{const j=MB.cloneNode(!0),z=j.firstChild,Q=z.firstChild,I=z.nextSibling;return ie(z,S(fn,{name:"clock",class:"mr-2"}),Q),ie(I,S(_n,{label:"Duration in Days",get children(){return S(ln,{type:"number",inputmode:"decimal",get value(){return g()},onInput:U=>_(U.currentTarget?.valueAsNumber)})}}),null),ie(I,S(_n,{label:"Doses per Day",get children(){return S(ln,{type:"number",inputmode:"decimal",get value(){return x()},onInput:U=>O(U.currentTarget?.valueAsNumber)})}}),null),j})(),(()=>{const j=DB.cloneNode(!0),z=j.firstChild,Q=z.firstChild,I=z.nextSibling,U=I.nextSibling,W=U.nextSibling;return ie(z,S(fn,{name:"chartPie",class:"mr-2"}),Q),ie(I,S(_n,{label:"Single Dose",get children(){return S(ln,{type:"text",get value(){return`${fi(D())} ${Y()}`},readonly:!0,copy:!0})}}),null),ie(I,S(_n,{label:"Total Quantity",get children(){return S(ln,{type:"text",get value(){return`${fi(F())} ${Y()}`},readonly:!0,copy:!0})}}),null),ie(W,S(_n,{label:"Single Liquid Dose",get children(){return S(ln,{type:"text",get value(){return`${fi(J())} ${b()}`},readonly:!0,copy:!0})}}),null),ie(W,S(_n,{label:"Total Liquid Quantity",get children(){return S(ln,{type:"text",get value(){return`${fi(G())} ${b()}`},readonly:!0,copy:!0})}}),null),j})(),(()=>{const j=LB.cloneNode(!0);return ie(j,S(ev,{variant:"secondary",get onClick(){return e.onClose},children:"Cancel"}),null),ie(j,S(ev,{onClick:()=>{e.setAutocompleteValues({days:g(),liquidDose:fi(J()),totalLiquid:fi(G()),unit:b()}),e.onClose()},get disabled(){return G()===0},children:"Autofill"}),null),j})()]}})}const FB=`*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}[type=text],[type=email],[type=url],[type=password],[type=number],[type=date],[type=datetime-local],[type=month],[type=search],[type=tel],[type=time],[type=week],[multiple],textarea,select{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#fff;border-color:#6b7280;border-width:1px;border-radius:0;padding:.5rem .75rem;font-size:1rem;line-height:1.5rem;--tw-shadow: 0 0 #0000}[type=text]:focus,[type=email]:focus,[type=url]:focus,[type=password]:focus,[type=number]:focus,[type=date]:focus,[type=datetime-local]:focus,[type=month]:focus,[type=search]:focus,[type=tel]:focus,[type=time]:focus,[type=week]:focus,[multiple]:focus,textarea:focus,select:focus{outline:2px solid transparent;outline-offset:2px;--tw-ring-inset: var(--tw-empty, );--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: #2563eb;--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);border-color:#2563eb}input::-moz-placeholder,textarea::-moz-placeholder{color:#6b7280;opacity:1}input::placeholder,textarea::placeholder{color:#6b7280;opacity:1}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-date-and-time-value{min-height:1.5em}::-webkit-datetime-edit,::-webkit-datetime-edit-year-field,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-minute-field,::-webkit-datetime-edit-second-field,::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-meridiem-field{padding-top:0;padding-bottom:0}select{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");background-position:right .5rem center;background-repeat:no-repeat;background-size:1.5em 1.5em;padding-right:2.5rem;-webkit-print-color-adjust:exact;print-color-adjust:exact}[multiple]{background-image:initial;background-position:initial;background-repeat:unset;background-size:initial;padding-right:.75rem;-webkit-print-color-adjust:unset;print-color-adjust:unset}[type=checkbox],[type=radio]{-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0;-webkit-print-color-adjust:exact;print-color-adjust:exact;display:inline-block;vertical-align:middle;background-origin:border-box;-webkit-user-select:none;-moz-user-select:none;user-select:none;flex-shrink:0;height:1rem;width:1rem;color:#2563eb;background-color:#fff;border-color:#6b7280;border-width:1px;--tw-shadow: 0 0 #0000}[type=checkbox]{border-radius:0}[type=radio]{border-radius:100%}[type=checkbox]:focus,[type=radio]:focus{outline:2px solid transparent;outline-offset:2px;--tw-ring-inset: var(--tw-empty, );--tw-ring-offset-width: 2px;--tw-ring-offset-color: #fff;--tw-ring-color: #2563eb;--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}[type=checkbox]:checked,[type=radio]:checked{border-color:transparent;background-color:currentColor;background-size:100% 100%;background-position:center;background-repeat:no-repeat}[type=checkbox]:checked{background-image:url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e")}[type=radio]:checked{background-image:url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e")}[type=checkbox]:checked:hover,[type=checkbox]:checked:focus,[type=radio]:checked:hover,[type=radio]:checked:focus{border-color:transparent;background-color:currentColor}[type=checkbox]:indeterminate{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='white' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 8h8'/%3e%3c/svg%3e");border-color:transparent;background-color:currentColor;background-size:100% 100%;background-position:center;background-repeat:no-repeat}[type=checkbox]:indeterminate:hover,[type=checkbox]:indeterminate:focus{border-color:transparent;background-color:currentColor}[type=file]{background:unset;border-color:inherit;border-width:0;border-radius:0;padding:0;font-size:unset;line-height:inherit}[type=file]:focus{outline:1px solid ButtonText;outline:1px auto -webkit-focus-ring-color}h1,h2,h3,h4,h5,h6,p,div,li,a,ul,input{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-weight:300;line-height:1.625}body,html{--tw-text-opacity: 1;color:rgb(17 24 39/var(--tw-text-opacity))}h1,h2,h3,h4,h5,h6,label{font-weight:500;line-height:1.25}h1{font-size:1.875rem;line-height:2.25rem;margin-top:.5rem;margin-bottom:.5rem}h2{font-size:1.5rem;line-height:2rem;margin-top:.5rem;margin-bottom:.5rem}h3{font-size:1.25rem;line-height:1.75rem;margin-top:.25rem;margin-bottom:.25rem}h4{font-size:1.125rem;line-height:1.75rem;margin-top:.25rem;margin-bottom:.25rem}h5{font-size:1rem;line-height:1.5rem;margin-top:.25rem;margin-bottom:.25rem}h6,label{font-size:.875rem;line-height:1.25rem;margin-top:.25rem;margin-bottom:.25rem}p{margin-top:.5rem;margin-bottom:.5rem}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-0{inset:0}.inset-y-0{top:0;bottom:0}.left-0{left:0}.right-0{right:0}.top-0{top:0}.z-10{z-index:10}.mx-auto{margin-left:auto;margin-right:auto}.my-8{margin-top:2rem;margin-bottom:2rem}.mb-1{margin-bottom:.25rem}.mb-10{margin-bottom:2.5rem}.mb-4{margin-bottom:1rem}.mr-2{margin-right:.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-5{margin-top:1.25rem}.mt-8{margin-top:2rem}.block{display:block}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.h-10{height:2.5rem}.h-12{height:3rem}.h-4{height:1rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-8{height:2rem}.h-px{height:1px}.max-h-60{max-height:15rem}.min-h-full{min-height:100%}.w-10{width:2.5rem}.w-12{width:3rem}.w-4{width:1rem}.w-5{width:1.25rem}.w-6{width:1.5rem}.w-8{width:2rem}.w-full{width:100%}.max-w-lg{max-width:32rem}.max-w-sm{max-width:24rem}.grow{flex-grow:1}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.flex-col{flex-direction:column}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.gap-4{gap:1rem}.gap-6{gap:1.5rem}.gap-8{gap:2rem}.gap-x-1{-moz-column-gap:.25rem;column-gap:.25rem}.gap-x-1\\.5{-moz-column-gap:.375rem;column-gap:.375rem}.overflow-auto{overflow:auto}.overflow-y-auto{overflow-y:auto}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rounded{border-radius:.25rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-r-md{border-top-right-radius:.375rem;border-bottom-right-radius:.375rem}.border-0{border-width:0px}.bg-blue-100{--tw-bg-opacity: 1;background-color:rgb(219 234 254/var(--tw-bg-opacity))}.bg-blue-50{--tw-bg-opacity: 1;background-color:rgb(239 246 255/var(--tw-bg-opacity))}.bg-blue-500{--tw-bg-opacity: 1;background-color:rgb(59 130 246/var(--tw-bg-opacity))}.bg-blue-600{--tw-bg-opacity: 1;background-color:rgb(37 99 235/var(--tw-bg-opacity))}.bg-gray-200{--tw-bg-opacity: 1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.bg-gray-50{--tw-bg-opacity: 1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.bg-gray-500{--tw-bg-opacity: 1;background-color:rgb(107 114 128/var(--tw-bg-opacity))}.bg-green-100{--tw-bg-opacity: 1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.bg-opacity-75{--tw-bg-opacity: .75}.fill-blue-600{fill:#2563eb}.p-4{padding:1rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-3\\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\\.5{padding-top:.625rem;padding-bottom:.625rem}.pb-4{padding-bottom:1rem}.pl-10{padding-left:2.5rem}.pl-3{padding-left:.75rem}.pr-1{padding-right:.25rem}.pr-3{padding-right:.75rem}.pr-4{padding-right:1rem}.pr-9{padding-right:2.25rem}.pt-4{padding-top:1rem}.pt-5{padding-top:1.25rem}.text-left{text-align:left}.text-center{text-align:center}.text-base{font-size:1rem;line-height:1.5rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-medium{font-weight:500}.font-semibold{font-weight:600}.leading-6{line-height:1.5rem}.text-blue-600{--tw-text-opacity: 1;color:rgb(37 99 235/var(--tw-text-opacity))}.text-gray-200{--tw-text-opacity: 1;color:rgb(229 231 235/var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175/var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128/var(--tw-text-opacity))}.text-gray-900{--tw-text-opacity: 1;color:rgb(17 24 39/var(--tw-text-opacity))}.text-green-600{--tw-text-opacity: 1;color:rgb(22 163 74/var(--tw-text-opacity))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}.text-red-600{--tw-text-opacity: 1;color:rgb(220 38 38/var(--tw-text-opacity))}.text-red-900{--tw-text-opacity: 1;color:rgb(127 29 29/var(--tw-text-opacity))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255/var(--tw-text-opacity))}.opacity-50{opacity:.5}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-ring-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-ring-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-shadow)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-ring-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-shadow)}.ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 rgba(0, 0, 0, 0))}.ring-2{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 rgba(0, 0, 0, 0))}.ring-inset{--tw-ring-inset: inset}.ring-black{--tw-ring-opacity: 1;--tw-ring-color: rgb(0 0 0 / var(--tw-ring-opacity))}.ring-blue-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(147 197 253 / var(--tw-ring-opacity))}.ring-blue-600{--tw-ring-opacity: 1;--tw-ring-color: rgb(37 99 235 / var(--tw-ring-opacity))}.ring-gray-200{--tw-ring-opacity: 1;--tw-ring-color: rgb(229 231 235 / var(--tw-ring-opacity))}.ring-gray-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(209 213 219 / var(--tw-ring-opacity))}.ring-red-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(252 165 165 / var(--tw-ring-opacity))}.ring-red-500{--tw-ring-opacity: 1;--tw-ring-color: rgb(239 68 68 / var(--tw-ring-opacity))}.ring-opacity-5{--tw-ring-opacity: .05}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.theme-photon,[data-theme=photon]{--twc-primaryText: 210 20% 98%;--twc-primary500: 238.70000000000005 83.5% 66.7%;--twc-primary600: 243.39999999999998 75.4% 58.6%;--twc-secondaryText: 220.89999999999998 39.3% 11%;--twc-secondary50: 225.89999999999998 100% 96.7%;--twc-secondary100: 226.5 100% 93.9%}.theme-weekend,[data-theme=weekend]{--twc-primaryText: 210 20% 98%;--twc-primary500: 198.60000000000002 88.7% 48.4%;--twc-primary600: 200.39999999999998 98% 39.4%;--twc-secondaryText: 220.89999999999998 39.3% 11%;--twc-secondary50: 204 100% 97.1%;--twc-secondary100: 204 93.8% 93.7%}.placeholder\\:text-gray-400::-moz-placeholder{--tw-text-opacity: 1;color:rgb(156 163 175/var(--tw-text-opacity))}.placeholder\\:text-gray-400::placeholder{--tw-text-opacity: 1;color:rgb(156 163 175/var(--tw-text-opacity))}.placeholder\\:text-red-300::-moz-placeholder{--tw-text-opacity: 1;color:rgb(252 165 165/var(--tw-text-opacity))}.placeholder\\:text-red-300::placeholder{--tw-text-opacity: 1;color:rgb(252 165 165/var(--tw-text-opacity))}.hover\\:bg-blue-100:hover{--tw-bg-opacity: 1;background-color:rgb(219 234 254/var(--tw-bg-opacity))}.hover\\:bg-blue-500:hover{--tw-bg-opacity: 1;background-color:rgb(59 130 246/var(--tw-bg-opacity))}.hover\\:bg-gray-50:hover{--tw-bg-opacity: 1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.hover\\:text-blue-500:hover{--tw-text-opacity: 1;color:rgb(59 130 246/var(--tw-text-opacity))}.hover\\:text-gray-500:hover{--tw-text-opacity: 1;color:rgb(107 114 128/var(--tw-text-opacity))}.focus\\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\\:outline-0:focus{outline-width:0px}.focus\\:ring-1:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 rgba(0, 0, 0, 0))}.focus\\:ring-2:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 rgba(0, 0, 0, 0))}.focus\\:ring-inset:focus{--tw-ring-inset: inset}.focus\\:ring-blue-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(147 197 253 / var(--tw-ring-opacity))}.focus\\:ring-blue-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(59 130 246 / var(--tw-ring-opacity))}.focus\\:ring-blue-600:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(37 99 235 / var(--tw-ring-opacity))}.focus\\:ring-gray-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(209 213 219 / var(--tw-ring-opacity))}.focus\\:ring-red-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(239 68 68 / var(--tw-ring-opacity))}.focus\\:ring-offset-2:focus{--tw-ring-offset-width: 2px}.focus-visible\\:outline:focus-visible{outline-style:solid}.focus-visible\\:outline-2:focus-visible{outline-width:2px}.focus-visible\\:outline-offset-2:focus-visible{outline-offset:2px}@media (prefers-color-scheme: dark){.dark\\:bg-gray-700{--tw-bg-opacity: 1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}.dark\\:text-gray-600{--tw-text-opacity: 1;color:rgb(75 85 99/var(--tw-text-opacity))}}@media (min-width: 640px){.sm\\:my-8{margin-top:2rem;margin-bottom:2rem}.sm\\:mt-5{margin-top:1.25rem}.sm\\:mt-6{margin-top:1.5rem}.sm\\:block{display:block}.sm\\:max-w-lg{max-width:32rem}.sm\\:max-w-sm{max-width:24rem}.sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\\:grid-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}.sm\\:items-center{align-items:center}.sm\\:gap-2{gap:.5rem}.sm\\:gap-4{gap:1rem}.sm\\:p-0{padding:0}.sm\\:p-6{padding:1.5rem}.sm\\:text-sm{font-size:.875rem;line-height:1.25rem}.sm\\:leading-6{line-height:1.5rem}}@media (min-width: 768px){.md\\:grid-cols-8{grid-template-columns:repeat(8,minmax(0,1fr))}}
|
|
2278
|
+
`;const OB=e=>e.map((t,n)=>({id:n.toString(),name:t}));function Ao(e){const t=OB(e.options);return S(Lr,{get value(){return t[e.initialIdx||0]},setSelected:n=>e.setSelected(n.name),get children(){return[S(Lr.Input,{displayValue:n=>n.name}),S(Lr.Options,{get children(){return S(sr,{each:t,children:n=>S(Lr.Option,{get key(){return n.id},value:n,get children(){return n.name}})})}})]}})}const sv={weight:{lbs:.453592,kg:1},liquid:{"mcg/kg":{mcg:1,mg:1e3,g:1e6},"mg/kg":{mcg:.001,mg:1,g:1e3},"g/kg":{mcg:1e-6,mg:.001,g:1}}},CB=$('<div class="flex items-center"><h2>Calculate Dose Quantity</h2></div>'),NB=$("<p>Enter desired dosage and patient weight to calculate total and dose quantity.</p>"),TB=$('<div class="my-8"><div class="flex items-center"><h3>Selected Medication</h3></div><p></p></div>'),PB=$('<div class="grid grid-cols-1 sm:grid-cols-2 gap-4"><div class="grid grid-cols-2 gap-4 sm:gap-2"></div><div class="flex gap-4 items-center"><div>per</div><div class="grow"></div></div></div>'),AB=$('<div class="grid grid-cols-1 sm:grid-cols-2 gap-4"><div class="grid grid-cols-2 gap-4 sm:gap-2"></div></div>'),lv=$('<div class="flex gap-4 sm:gap-2"></div>'),IB=$('<section class="mt-8"><div class="flex items-center"><h3>Dosage Inputs</h3></div><div class="grid grid-cols-1 sm:grid-cols-2 sm:gap-4"></div></section>'),MB=$('<section class="mt-8"><div class="flex items-center"><h3>Frequency</h3></div><div class="grid grid-cols-2 gap-4"></div></section>'),DB=$('<section class="mt-8"><div class="flex items-center"><h3>Dosage</h3></div><div class="grid grid-cols-2 gap-4"></div><hr class="h-px mb-4 bg-gray-200 border-0 dark:bg-gray-700 w-full"><div class="grid grid-cols-2 gap-4"></div></section>'),LB=$('<div class="mt-8 flex gap-4 justify-end"></div>'),fi=e=>parseFloat(e.toFixed(1)),cv=["mcg/kg","mg/kg","g/kg"],uv=["day","dose"],dv=["lbs","kg"],fv=["mcg","mg","g"],hv=["mL","L"],Ya=e=>isNaN(e)||!isFinite(e)?0:e;function RB(e){const[t,n]=V(0),[r,i]=V(cv[0]),[o,a]=V(uv[0]),[s,c]=V(0),[l,u]=V(dv[0]),[d,f]=V(0),[h,p]=V(fv[0]),[m,v]=V(0),[b,y]=V(hv[0]),[g,_]=V(1),[k,O]=V(1),C=se(()=>sv.weight[l()]*t()*s()),M=se(()=>{if(!d()||parseInt(d().toString(),10)===0)return 0;const j=sv.liquid[r()][h()];return C()*m()/(d()*j)}),D=se(()=>Ya(o()==="day"?C()/k():C())),F=se(()=>Ya(D()*g()*k())),Y=se(()=>r().split("/")[0]),J=se(()=>Ya(o()==="day"?M()/k():M())),G=se(()=>Ya(J()*g()*k()));return S(SB,{get open(){return e.open},get onClose(){return e.onClose},size:"lg",get children(){return[(()=>{const j=CB.cloneNode(!0),z=j.firstChild;return ie(j,S(fn,{name:"calculator",class:"mr-2"}),z),j})(),NB.cloneNode(!0),(()=>{const j=TB.cloneNode(!0),z=j.firstChild,Q=z.firstChild,I=z.nextSibling;return ie(z,S(fn,{name:"pencilSquare",class:"mr-2"}),Q),ie(I,()=>e?.medicationName||"None Selected"),q(()=>Oa(I,e?.medicationName?"":"@apply text-gray-400")),j})(),(()=>{const j=IB.cloneNode(!0),z=j.firstChild,Q=z.firstChild,I=z.nextSibling;return ie(z,S(fn,{name:"beaker",class:"mr-2"}),Q),ie(j,S(_n,{label:"Dose",get children(){const U=PB.cloneNode(!0),W=U.firstChild,de=W.nextSibling,be=de.firstChild,P=be.nextSibling;return ie(W,S(ln,{type:"number",inputmode:"decimal",get value(){return t()},onInput:B=>n(B.currentTarget?.valueAsNumber)}),null),ie(W,S(Ao,{setSelected:i,options:cv,initialIdx:1}),null),ie(P,S(Ao,{setSelected:a,options:uv})),U}}),I),ie(j,S(_n,{label:"Patient Weight",get children(){const U=AB.cloneNode(!0),W=U.firstChild;return ie(W,S(ln,{type:"number",inputmode:"decimal",get value(){return s()},onInput:de=>c(de.currentTarget?.valueAsNumber)}),null),ie(W,S(Ao,{setSelected:u,options:dv}),null),U}}),I),ie(I,S(_n,{label:"Liquid Concentration",get children(){const U=lv.cloneNode(!0);return ie(U,S(ln,{type:"number",inputmode:"decimal",get value(){return d()},onInput:W=>f(W.currentTarget?.valueAsNumber)}),null),ie(U,S(Ao,{setSelected:p,options:fv,initialIdx:1}),null),U}}),null),ie(I,S(_n,{label:"Per Volume",get children(){const U=lv.cloneNode(!0);return ie(U,S(ln,{type:"number",inputmode:"decimal",get value(){return m()},onInput:W=>v(W.currentTarget?.valueAsNumber)}),null),ie(U,S(Ao,{setSelected:y,options:hv}),null),U}}),null),j})(),(()=>{const j=MB.cloneNode(!0),z=j.firstChild,Q=z.firstChild,I=z.nextSibling;return ie(z,S(fn,{name:"clock",class:"mr-2"}),Q),ie(I,S(_n,{label:"Duration in Days",get children(){return S(ln,{type:"number",inputmode:"decimal",get value(){return g()},onInput:U=>_(U.currentTarget?.valueAsNumber)})}}),null),ie(I,S(_n,{label:"Doses per Day",get children(){return S(ln,{type:"number",inputmode:"decimal",get value(){return k()},onInput:U=>O(U.currentTarget?.valueAsNumber)})}}),null),j})(),(()=>{const j=DB.cloneNode(!0),z=j.firstChild,Q=z.firstChild,I=z.nextSibling,U=I.nextSibling,W=U.nextSibling;return ie(z,S(fn,{name:"chartPie",class:"mr-2"}),Q),ie(I,S(_n,{label:"Single Dose",get children(){return S(ln,{type:"text",get value(){return`${fi(D())} ${Y()}`},readonly:!0,copy:!0})}}),null),ie(I,S(_n,{label:"Total Quantity",get children(){return S(ln,{type:"text",get value(){return`${fi(F())} ${Y()}`},readonly:!0,copy:!0})}}),null),ie(W,S(_n,{label:"Single Liquid Dose",get children(){return S(ln,{type:"text",get value(){return`${fi(J())} ${b()}`},readonly:!0,copy:!0})}}),null),ie(W,S(_n,{label:"Total Liquid Quantity",get children(){return S(ln,{type:"text",get value(){return`${fi(G())} ${b()}`},readonly:!0,copy:!0})}}),null),j})(),(()=>{const j=LB.cloneNode(!0);return ie(j,S(ev,{variant:"secondary",get onClick(){return e.onClose},children:"Cancel"}),null),ie(j,S(ev,{onClick:()=>{e.setAutocompleteValues({days:g(),liquidDose:fi(J()),totalLiquid:fi(G()),unit:b()}),e.onClose()},get disabled(){return G()===0},children:"Autofill"}),null),j})()]}})}const FB=`*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}[type=text],[type=email],[type=url],[type=password],[type=number],[type=date],[type=datetime-local],[type=month],[type=search],[type=tel],[type=time],[type=week],[multiple],textarea,select{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#fff;border-color:#6b7280;border-width:1px;border-radius:0;padding:.5rem .75rem;font-size:1rem;line-height:1.5rem;--tw-shadow: 0 0 #0000}[type=text]:focus,[type=email]:focus,[type=url]:focus,[type=password]:focus,[type=number]:focus,[type=date]:focus,[type=datetime-local]:focus,[type=month]:focus,[type=search]:focus,[type=tel]:focus,[type=time]:focus,[type=week]:focus,[multiple]:focus,textarea:focus,select:focus{outline:2px solid transparent;outline-offset:2px;--tw-ring-inset: var(--tw-empty, );--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: #2563eb;--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);border-color:#2563eb}input::-moz-placeholder,textarea::-moz-placeholder{color:#6b7280;opacity:1}input::placeholder,textarea::placeholder{color:#6b7280;opacity:1}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-date-and-time-value{min-height:1.5em}::-webkit-datetime-edit,::-webkit-datetime-edit-year-field,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-minute-field,::-webkit-datetime-edit-second-field,::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-meridiem-field{padding-top:0;padding-bottom:0}select{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");background-position:right .5rem center;background-repeat:no-repeat;background-size:1.5em 1.5em;padding-right:2.5rem;-webkit-print-color-adjust:exact;print-color-adjust:exact}[multiple]{background-image:initial;background-position:initial;background-repeat:unset;background-size:initial;padding-right:.75rem;-webkit-print-color-adjust:unset;print-color-adjust:unset}[type=checkbox],[type=radio]{-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0;-webkit-print-color-adjust:exact;print-color-adjust:exact;display:inline-block;vertical-align:middle;background-origin:border-box;-webkit-user-select:none;-moz-user-select:none;user-select:none;flex-shrink:0;height:1rem;width:1rem;color:#2563eb;background-color:#fff;border-color:#6b7280;border-width:1px;--tw-shadow: 0 0 #0000}[type=checkbox]{border-radius:0}[type=radio]{border-radius:100%}[type=checkbox]:focus,[type=radio]:focus{outline:2px solid transparent;outline-offset:2px;--tw-ring-inset: var(--tw-empty, );--tw-ring-offset-width: 2px;--tw-ring-offset-color: #fff;--tw-ring-color: #2563eb;--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}[type=checkbox]:checked,[type=radio]:checked{border-color:transparent;background-color:currentColor;background-size:100% 100%;background-position:center;background-repeat:no-repeat}[type=checkbox]:checked{background-image:url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e")}[type=radio]:checked{background-image:url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e")}[type=checkbox]:checked:hover,[type=checkbox]:checked:focus,[type=radio]:checked:hover,[type=radio]:checked:focus{border-color:transparent;background-color:currentColor}[type=checkbox]:indeterminate{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='white' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 8h8'/%3e%3c/svg%3e");border-color:transparent;background-color:currentColor;background-size:100% 100%;background-position:center;background-repeat:no-repeat}[type=checkbox]:indeterminate:hover,[type=checkbox]:indeterminate:focus{border-color:transparent;background-color:currentColor}[type=file]{background:unset;border-color:inherit;border-width:0;border-radius:0;padding:0;font-size:unset;line-height:inherit}[type=file]:focus{outline:1px solid ButtonText;outline:1px auto -webkit-focus-ring-color}h1,h2,h3,h4,h5,h6,p,div,li,a,ul,input{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-weight:300;line-height:1.625}body,html{--tw-text-opacity: 1;color:rgb(17 24 39/var(--tw-text-opacity))}h1,h2,h3,h4,h5,h6,label{font-weight:500;line-height:1.25}h1{font-size:1.875rem;line-height:2.25rem;margin-top:.5rem;margin-bottom:.5rem}h2{font-size:1.5rem;line-height:2rem;margin-top:.5rem;margin-bottom:.5rem}h3{font-size:1.25rem;line-height:1.75rem;margin-top:.25rem;margin-bottom:.25rem}h4{font-size:1.125rem;line-height:1.75rem;margin-top:.25rem;margin-bottom:.25rem}h5{font-size:1rem;line-height:1.5rem;margin-top:.25rem;margin-bottom:.25rem}h6,label{font-size:.875rem;line-height:1.25rem;margin-top:.25rem;margin-bottom:.25rem}p{margin-top:.5rem;margin-bottom:.5rem}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-0{inset:0}.inset-y-0{top:0;bottom:0}.left-0{left:0}.right-0{right:0}.top-0{top:0}.z-10{z-index:10}.mx-auto{margin-left:auto;margin-right:auto}.my-8{margin-top:2rem;margin-bottom:2rem}.mb-1{margin-bottom:.25rem}.mb-10{margin-bottom:2.5rem}.mb-4{margin-bottom:1rem}.mr-2{margin-right:.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-5{margin-top:1.25rem}.mt-8{margin-top:2rem}.block{display:block}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.h-10{height:2.5rem}.h-12{height:3rem}.h-4{height:1rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-8{height:2rem}.h-px{height:1px}.max-h-60{max-height:15rem}.min-h-full{min-height:100%}.w-10{width:2.5rem}.w-12{width:3rem}.w-4{width:1rem}.w-5{width:1.25rem}.w-6{width:1.5rem}.w-8{width:2rem}.w-full{width:100%}.max-w-lg{max-width:32rem}.max-w-sm{max-width:24rem}.grow{flex-grow:1}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.flex-col{flex-direction:column}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.gap-4{gap:1rem}.gap-6{gap:1.5rem}.gap-8{gap:2rem}.gap-x-1{-moz-column-gap:.25rem;column-gap:.25rem}.gap-x-1\\.5{-moz-column-gap:.375rem;column-gap:.375rem}.overflow-auto{overflow:auto}.overflow-y-auto{overflow-y:auto}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rounded{border-radius:.25rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-r-md{border-top-right-radius:.375rem;border-bottom-right-radius:.375rem}.border-0{border-width:0px}.bg-blue-100{--tw-bg-opacity: 1;background-color:rgb(219 234 254/var(--tw-bg-opacity))}.bg-blue-50{--tw-bg-opacity: 1;background-color:rgb(239 246 255/var(--tw-bg-opacity))}.bg-blue-500{--tw-bg-opacity: 1;background-color:rgb(59 130 246/var(--tw-bg-opacity))}.bg-blue-600{--tw-bg-opacity: 1;background-color:rgb(37 99 235/var(--tw-bg-opacity))}.bg-gray-200{--tw-bg-opacity: 1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.bg-gray-50{--tw-bg-opacity: 1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.bg-gray-500{--tw-bg-opacity: 1;background-color:rgb(107 114 128/var(--tw-bg-opacity))}.bg-green-100{--tw-bg-opacity: 1;background-color:rgb(220 252 231/var(--tw-bg-opacity))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.bg-opacity-75{--tw-bg-opacity: .75}.fill-blue-600{fill:#2563eb}.p-4{padding:1rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-3\\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\\.5{padding-top:.625rem;padding-bottom:.625rem}.pb-4{padding-bottom:1rem}.pl-10{padding-left:2.5rem}.pl-3{padding-left:.75rem}.pr-1{padding-right:.25rem}.pr-3{padding-right:.75rem}.pr-4{padding-right:1rem}.pr-9{padding-right:2.25rem}.pt-4{padding-top:1rem}.pt-5{padding-top:1.25rem}.text-left{text-align:left}.text-center{text-align:center}.text-base{font-size:1rem;line-height:1.5rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-medium{font-weight:500}.font-semibold{font-weight:600}.leading-6{line-height:1.5rem}.text-blue-600{--tw-text-opacity: 1;color:rgb(37 99 235/var(--tw-text-opacity))}.text-gray-200{--tw-text-opacity: 1;color:rgb(229 231 235/var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175/var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128/var(--tw-text-opacity))}.text-gray-900{--tw-text-opacity: 1;color:rgb(17 24 39/var(--tw-text-opacity))}.text-green-600{--tw-text-opacity: 1;color:rgb(22 163 74/var(--tw-text-opacity))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}.text-red-600{--tw-text-opacity: 1;color:rgb(220 38 38/var(--tw-text-opacity))}.text-red-900{--tw-text-opacity: 1;color:rgb(127 29 29/var(--tw-text-opacity))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255/var(--tw-text-opacity))}.opacity-50{opacity:.5}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-ring-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-ring-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-shadow)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-ring-shadow, 0 0 rgba(0, 0, 0, 0)),var(--tw-shadow)}.ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 rgba(0, 0, 0, 0))}.ring-2{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 rgba(0, 0, 0, 0))}.ring-inset{--tw-ring-inset: inset}.ring-black{--tw-ring-opacity: 1;--tw-ring-color: rgb(0 0 0 / var(--tw-ring-opacity))}.ring-blue-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(147 197 253 / var(--tw-ring-opacity))}.ring-blue-600{--tw-ring-opacity: 1;--tw-ring-color: rgb(37 99 235 / var(--tw-ring-opacity))}.ring-gray-200{--tw-ring-opacity: 1;--tw-ring-color: rgb(229 231 235 / var(--tw-ring-opacity))}.ring-gray-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(209 213 219 / var(--tw-ring-opacity))}.ring-red-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(252 165 165 / var(--tw-ring-opacity))}.ring-red-500{--tw-ring-opacity: 1;--tw-ring-color: rgb(239 68 68 / var(--tw-ring-opacity))}.ring-opacity-5{--tw-ring-opacity: .05}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.theme-photon,[data-theme=photon]{--twc-primaryText: 210 20% 98%;--twc-primary500: 238.70000000000005 83.5% 66.7%;--twc-primary600: 243.39999999999998 75.4% 58.6%;--twc-secondaryText: 220.89999999999998 39.3% 11%;--twc-secondary50: 225.89999999999998 100% 96.7%;--twc-secondary100: 226.5 100% 93.9%}.theme-weekend,[data-theme=weekend]{--twc-primaryText: 210 20% 98%;--twc-primary500: 198.60000000000002 88.7% 48.4%;--twc-primary600: 200.39999999999998 98% 39.4%;--twc-secondaryText: 220.89999999999998 39.3% 11%;--twc-secondary50: 204 100% 97.1%;--twc-secondary100: 204 93.8% 93.7%}.placeholder\\:text-gray-400::-moz-placeholder{--tw-text-opacity: 1;color:rgb(156 163 175/var(--tw-text-opacity))}.placeholder\\:text-gray-400::placeholder{--tw-text-opacity: 1;color:rgb(156 163 175/var(--tw-text-opacity))}.placeholder\\:text-red-300::-moz-placeholder{--tw-text-opacity: 1;color:rgb(252 165 165/var(--tw-text-opacity))}.placeholder\\:text-red-300::placeholder{--tw-text-opacity: 1;color:rgb(252 165 165/var(--tw-text-opacity))}.hover\\:bg-blue-100:hover{--tw-bg-opacity: 1;background-color:rgb(219 234 254/var(--tw-bg-opacity))}.hover\\:bg-blue-500:hover{--tw-bg-opacity: 1;background-color:rgb(59 130 246/var(--tw-bg-opacity))}.hover\\:bg-gray-50:hover{--tw-bg-opacity: 1;background-color:rgb(249 250 251/var(--tw-bg-opacity))}.hover\\:text-blue-500:hover{--tw-text-opacity: 1;color:rgb(59 130 246/var(--tw-text-opacity))}.hover\\:text-gray-500:hover{--tw-text-opacity: 1;color:rgb(107 114 128/var(--tw-text-opacity))}.focus\\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\\:outline-0:focus{outline-width:0px}.focus\\:ring-1:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 rgba(0, 0, 0, 0))}.focus\\:ring-2:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 rgba(0, 0, 0, 0))}.focus\\:ring-inset:focus{--tw-ring-inset: inset}.focus\\:ring-blue-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(147 197 253 / var(--tw-ring-opacity))}.focus\\:ring-blue-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(59 130 246 / var(--tw-ring-opacity))}.focus\\:ring-blue-600:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(37 99 235 / var(--tw-ring-opacity))}.focus\\:ring-gray-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(209 213 219 / var(--tw-ring-opacity))}.focus\\:ring-red-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(239 68 68 / var(--tw-ring-opacity))}.focus\\:ring-offset-2:focus{--tw-ring-offset-width: 2px}.focus-visible\\:outline:focus-visible{outline-style:solid}.focus-visible\\:outline-2:focus-visible{outline-width:2px}.focus-visible\\:outline-offset-2:focus-visible{outline-offset:2px}@media (prefers-color-scheme: dark){.dark\\:bg-gray-700{--tw-bg-opacity: 1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}.dark\\:text-gray-600{--tw-text-opacity: 1;color:rgb(75 85 99/var(--tw-text-opacity))}}@media (min-width: 640px){.sm\\:my-8{margin-top:2rem;margin-bottom:2rem}.sm\\:mt-5{margin-top:1.25rem}.sm\\:mt-6{margin-top:1.5rem}.sm\\:block{display:block}.sm\\:max-w-lg{max-width:32rem}.sm\\:max-w-sm{max-width:24rem}.sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\\:grid-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}.sm\\:items-center{align-items:center}.sm\\:gap-2{gap:.5rem}.sm\\:gap-4{gap:1rem}.sm\\:p-0{padding:0}.sm\\:p-6{padding:1.5rem}.sm\\:text-sm{font-size:.875rem;line-height:1.25rem}.sm\\:leading-6{line-height:1.5rem}}@media (min-width: 768px){.md\\:grid-cols-8{grid-template-columns:repeat(8,minmax(0,1fr))}}
|
|
2279
2279
|
`;var zB=_t`
|
|
2280
2280
|
${At}
|
|
2281
2281
|
|
|
@@ -2891,7 +2891,7 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
2891
2891
|
${this.caret?gs` <sl-icon part="caret" class="button__caret" library="system" name="caret"></sl-icon> `:""}
|
|
2892
2892
|
${this.loading?gs`<sl-spinner></sl-spinner>`:""}
|
|
2893
2893
|
</${t}>
|
|
2894
|
-
`}};Ie.styles=zB;w([rt(".button")],Ie.prototype,"button",2);w([Dn()],Ie.prototype,"hasFocus",2);w([Dn()],Ie.prototype,"invalid",2);w([E()],Ie.prototype,"title",2);w([E({reflect:!0})],Ie.prototype,"variant",2);w([E({reflect:!0})],Ie.prototype,"size",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"caret",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"disabled",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"loading",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"outline",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"pill",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"circle",2);w([E()],Ie.prototype,"type",2);w([E()],Ie.prototype,"name",2);w([E()],Ie.prototype,"value",2);w([E()],Ie.prototype,"href",2);w([E()],Ie.prototype,"target",2);w([E()],Ie.prototype,"rel",2);w([E()],Ie.prototype,"download",2);w([E()],Ie.prototype,"form",2);w([E({attribute:"formaction"})],Ie.prototype,"formAction",2);w([E({attribute:"formenctype"})],Ie.prototype,"formEnctype",2);w([E({attribute:"formmethod"})],Ie.prototype,"formMethod",2);w([E({attribute:"formnovalidate",type:Boolean})],Ie.prototype,"formNoValidate",2);w([E({attribute:"formtarget"})],Ie.prototype,"formTarget",2);w([Ve("disabled",{waitUntilFirstUpdate:!0})],Ie.prototype,"handleDisabledChange",1);Ie=w([It("sl-button")],Ie);const Mb=(e,t)=>{e.updateFormValue({key:"treatment",value:t.treatment}),t.dispenseAsWritten&&e.updateFormValue({key:"dispenseAsWritten",value:t.dispenseAsWritten}),t.dispenseQuantity&&e.updateFormValue({key:"dispenseQuantity",value:Number(t.dispenseQuantity)}),t.dispenseUnit&&e.updateFormValue({key:"dispenseUnit",value:t.dispenseUnit}),t.daysSupply&&e.updateFormValue({key:"daysSupply",value:Number(t.daysSupply)}),t.fillsAllowed&&e.updateFormValue({key:"refillsInput",value:Number(t.fillsAllowed)-1}),t.instructions&&e.updateFormValue({key:"instructions",value:t.instructions}),t.notes&&e.updateFormValue({key:"notes",value:t.notes})},jB=T('<photon-checkbox label="Add To Templates" form-name="daw"></photon-checkbox>'),VB=T('<photon-card title="Add Prescription"><style></style><div class="flex flex-col sm:gap-3"><photon-treatment-select label="Search Treatment Catalog"></photon-treatment-select><div class="flex flex-col sm:flex-none sm:grid sm:grid-cols-2 sm:gap-4"><div class="order-last sm:order-first"><photon-checkbox label="Dispense as written" tip="This prescription will be filled generically unless this box is checked" form-name="daw" class="flex-grow"></photon-checkbox><photon-med-search-dialog></photon-med-search-dialog></div><div class="pb-4 md:py-2 text-left sm:text-right"><a class="font-sans text-gray-500 text-sm hover:text-black hover:cursor-pointer">Advanced Search \u2192</a></div></div><div class="mt-2 sm:mt-0 md:max-w-[50%] md:pr-2"><photon-datepicker label="Effective Date" required="true"></photon-datepicker></div><div class="mt-2 sm:mt-0 sm:grid sm:grid-cols-2 sm:gap-4"><div class="flex items-end gap-1"><photon-number-input class="flex-grow flex-1 w-2/5 sm:w-auto" label="Quantity" required="true" min="1"></photon-number-input><div><photon-button variant="outline" class="w-fit"><button><sl-icon name="calculator"></sl-icon></button></photon-button><div class="pt-1"></div></div></div><photon-dispense-units label="Dispense Unit" required="true" force-label-size="true"></photon-dispense-units></div><div class="sm:grid sm:grid-cols-2 sm:gap-4"><photon-number-input class="flex-grow flex-shrink flex-1" label="Days Supply" required="true" min="0"></photon-number-input><photon-number-input class="flex-grow flex-shrink flex-1" label="Refills" required="true" min="0"></photon-number-input></div><photon-textarea label="Patient Instructions (SIG)" form-name="patient_instructions" required="true" placeholder="Enter patient instructions"></photon-textarea><photon-textarea label="Pharmacy Note" placeholder="Enter pharmacy note"></photon-textarea><div class="flex flex-col xs:flex-row gap-2"><div class="flex flex-grow justify-end"><photon-button class="w-full xs:w-fit">Add Prescription</photon-button></div></div></div></photon-card>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");const UB={treatment:st(Kc(Kt(),co()),"Please select a treatment..."),dispenseQuantity:st(rd(td(),1),"Quantity must be positive"),daysSupply:st(rd(td(),0),"Days Supply must be at least 0"),refillsInput:st(rd(td(),0),"Refills must be at least 0"),instructions:st(fr(Kt(),1,1/0),"Please enter instructions for the patient..."),effectiveDate:st(RT(new Date),"Please choose a date that isn't in the past")},BB=e=>{let t;const[n,r]=V(void 0),[i]=V(void 0),[o,a]=V(!1);let s;for(const[c,l]of Object.entries(UB))e.actions.registerValidator({key:c,validator:l});return(()=>{const c=H(()=>document.importNode(VB,!0)),l=c.firstChild,u=l.nextSibling,d=u.firstChild,f=d.nextSibling,h=f.firstChild,p=h.firstChild,m=p.nextSibling,v=h.nextSibling,b=v.firstChild,y=f.nextSibling,g=y.firstChild,_=y.nextSibling,x=_.firstChild,O=x.firstChild,C=O.nextSibling,M=C.firstChild,D=M.firstChild,F=D.firstChild,Y=M.nextSibling,J=x.nextSibling,G=_.nextSibling,j=G.firstChild,z=j.nextSibling,Q=G.nextSibling,I=Q.nextSibling,U=I.nextSibling,W=U.firstChild,de=W.firstChild,be=s;typeof be=="function"?he(be,c):s=c,c._$owner=A(),k(l,FB),u.addEventListener("photon-medication-selected",B=>{r(B.detail.medication),e.actions.updateFormValue({key:"treatment",value:B.detail.medication})}),d.addEventListener("photon-treatment-selected",B=>{B.detail.data.__typename==="PrescriptionTemplate"?Mb(e.actions,B.detail.data):e.actions.updateFormValue({key:"treatment",value:B.detail.data}),e.actions.updateFormValue({key:"catalogId",value:B.detail.catalogId})}),d._$owner=A(),p.addEventListener("photon-checkbox-toggled",B=>e.actions.updateFormValue({key:"dispenseAsWritten",value:B.detail.checked})),p._$owner=A();const P=t;return typeof P=="function"?he(P,m):t=m,m._$owner=A(),b.$$click=()=>t.open=!0,g.addEventListener("photon-datepicker-selected",B=>e.actions.updateFormValue({key:"effectiveDate",value:B.detail.date})),g._$owner=A(),O.addEventListener("photon-input-changed",B=>{const Ce=Number(B.detail.input);!isNaN(Ce)&&B.detail.input!==""&&e.actions.updateFormValue({key:"dispenseQuantity",value:Ce})}),O.style.setProperty("width","100px"),O._$owner=A(),k(x,S(RB,{get open(){return o()},onClose:()=>a(!1),get medicationName(){return e.store.treatment?.value?.name},setAutocompleteValues:({liquidDose:B,totalLiquid:Ce,unit:te,days:ye})=>{e.actions.updateFormValue({key:"daysSupply",value:Number(ye)}),e.actions.updateFormValue({key:"dispenseQuantity",value:Number(Ce)}),e.actions.updateFormValue({key:"instructions",value:`${B} ${te} ${e.store.instructions?.value}`}),te==="mL"&&e.actions.updateFormValue({key:"dispenseUnit",value:"Milliliter"})}}),C),M.addEventListener("photon-clicked",()=>a(!0)),M._$owner=A(),D.$$click=()=>a(!0),F._$owner=A(),Y.style.setProperty("height","23px"),J.addEventListener("photon-dispense-unit-selected",B=>e.actions.updateFormValue({key:"dispenseUnit",value:B.detail.dispenseUnit.name})),J._$owner=A(),j.addEventListener("photon-input-changed",B=>{e.actions.updateFormValue({key:"daysSupply",value:Number(B.detail.input)})}),j._$owner=A(),z.addEventListener("photon-input-changed",B=>e.actions.updateFormValue({key:"refillsInput",value:Number(B.detail.input)})),z._$owner=A(),Q.addEventListener("photon-textarea-changed",B=>e.actions.updateFormValue({key:"instructions",value:B.detail.value})),Q._$owner=A(),I.addEventListener("photon-textarea-changed",B=>e.actions.updateFormValue({key:"notes",value:B.detail.value})),I._$owner=A(),k(U,S(ee,{get when(){return!e.hideAddToTemplates},get children(){const B=H(()=>document.importNode(jB,!0));return B.addEventListener("photon-checkbox-toggled",Ce=>e.actions.updateFormValue({key:"addToTemplates",value:Ce.detail.checked})),B._$owner=A(),q(()=>B.checked=e.store.addToTemplates?.value||!1),B}}),W),de.addEventListener("photon-clicked",()=>{const B=["treatment","effectiveDate","dispenseQuantity","daysSupply","refillsInput","instructions"];e.actions.validate(B),e.actions.hasErrors(B)||(e.actions.updateFormValue({key:"draftPrescriptions",value:[...e.store.draftPrescriptions?.value||[],{id:String(Math.random()),effectiveDate:e.store.effectiveDate.value,treatment:e.store.treatment.value,dispenseAsWritten:e.store.dispenseAsWritten.value,dispenseQuantity:e.store.dispenseQuantity.value,dispenseUnit:e.store.dispenseUnit.value,daysSupply:e.store.daysSupply.value,refillsInput:e.store.refillsInput.value,instructions:e.store.instructions.value,notes:e.store.notes.value,fillsAllowed:e.store.refillsInput.value+1,addToTemplates:e.store.addToTemplates?.value??!1,catalogId:e.store.catalogId.value??void 0}]}),e.actions.updateFormValue({key:"effectiveDate",value:Qc(new Date,"yyyy-MM-dd").toString()}),e.actions.clearKeys(["treatment","dispenseAsWritten","dispenseQuantity","dispenseUnit","daysSupply","refillsInput","instructions","notes"]),r(void 0),e.actions.updateFormValue({key:"treatment",value:void 0}),e.actions.updateFormValue({key:"refillsInput",value:0}),e.actions.updateFormValue({key:"dispenseAsWritten",value:!1}),e.actions.updateFormValue({key:"dispenseQuantity",value:null}),e.actions.updateFormValue({key:"daysSupply",value:null}),e.actions.updateFormValue({key:"instructions",value:""}),e.actions.updateFormValue({key:"notes",value:""}))}),de._$owner=A(),q(B=>{const Ce=e.store.treatment?.value??void 0,te=e.store.treatment?.error??!1,ye=e.store.treatment?.error,Ne=n(),ce=e.store.effectiveDate?.error??!1,re=e.store.effectiveDate?.error,ae=e.store.dispenseQuantity?.error??!1,_e=e.store.dispenseQuantity?.error,it=e.store.dispenseUnit?.value??i()?.name,kt=e.store.daysSupply?.error??!1,mt=e.store.daysSupply?.error,Vt=e.store.refillsInput?.error??!1,Qn=e.store.refillsInput?.error,ho=e.store.instructions?.error??!1,po=e.store.instructions?.error;return Ce!==B._v$&&(d.selected=B._v$=Ce),te!==B._v$2&&(d.invalid=B._v$2=te),ye!==B._v$3&&(d.helpText=B._v$3=ye),Ne!==B._v$4&&(d.offCatalogOption=B._v$4=Ne),ce!==B._v$5&&(g.invalid=B._v$5=ce),re!==B._v$6&&(g.helpText=B._v$6=re),ae!==B._v$7&&(O.invalid=B._v$7=ae),_e!==B._v$8&&(O.helpText=B._v$8=_e),it!==B._v$9&&(J.selected=B._v$9=it),kt!==B._v$10&&(j.invalid=B._v$10=kt),mt!==B._v$11&&(j.helpText=B._v$11=mt),Vt!==B._v$12&&(z.invalid=B._v$12=Vt),Qn!==B._v$13&&(z.helpText=B._v$13=Qn),ho!==B._v$14&&(Q.invalid=B._v$14=ho),po!==B._v$15&&(Q.helpText=B._v$15=po),B},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0,_v$5:void 0,_v$6:void 0,_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0,_v$11:void 0,_v$12:void 0,_v$13:void 0,_v$14:void 0,_v$15:void 0}),q(()=>p.checked=e.store.dispenseAsWritten?.value||!1),q(()=>O.value=e.store.dispenseQuantity?.value??null),q(()=>j.value=e.store.daysSupply?.value??null),q(()=>z.value=e.store.refillsInput?.value??0),q(()=>Q.value=e.store.instructions?.value),q(()=>I.value=e.store.notes?.value),c})()};Yi(["click"]);const HB=T("<photon-patient-select></photon-patient-select>"),qB=T('<p class="font-sans text-gray-700">, </p>'),WB=T("<photon-patient-dialog></photon-patient-dialog>"),GB=T('<p class="font-sans text-sm font-medium">Patient Address</p>'),KB=T('<div class="flex flex-col font-sans text-gray-700"><p></p><div class="flex flex-row gap-1"><div class="flex flex-row"><p>,</p><p></p></div><p></p></div></div>'),QB=T('<p class="italic font-sans text-gray-500">Please edit patient and add address</p>'),YB=T('<p class="font-sans text-red-500 text-sm"></p>'),XB=T('<photon-button class="self-end" variant="outline">Edit Patient</photon-button>'),ZB=T('<photon-card><div class="flex flex-col gap-3"><p class="font-sans text-l font-medium"></p></div></photon-card>'),JB=T("<sl-spinner></sl-spinner>"),eH=T("<p></p>"),tH=st(Kc(Kt(),co()),"Please select a patient..."),nH=st(Kc(Kt(),co()),"Please enter an address for patient..."),rH=e=>{const[t,n]=V(!1),{actions:r,store:i}=Gc;e.actions.registerValidator({key:"patient",validator:tH}),e.enableOrder&&e.actions.registerValidator({key:"address",validator:nH});const o=a=>{e.actions.updateFormValue({key:"patient",value:a.detail.patient}),e.enableOrder&&!e.hideAddress&&e.actions.updateFormValue({key:"address",value:a.detail.patient.address})};return ht(()=>{e?.patientId&&r.getSelectedPatient(e.client.getSDK(),e.patientId)}),me(()=>{i?.selectedPatient?.data&&e?.patientId&&o({detail:{patient:i?.selectedPatient?.data}})}),(()=>{const a=H(()=>document.importNode(ZB,!0)),s=a.firstChild,c=s.firstChild;return a._$owner=A(),k(c,()=>e?.patientId?"Patient":"Select Patient"),k(s,S(ee,{get when(){return!e?.patientId},get children(){const l=H(()=>document.importNode(HB,!0));return l.addEventListener("photon-patient-selected",o),l._$owner=A(),q(u=>{const d=e.store.patient?.error??!1,f=e.store.patient?.error,h=e.store.patient?.value?.id??e.patientId,p=e.client.getSDK();return d!==u._v$&&(l.invalid=u._v$=d),f!==u._v$2&&(l.helpText=u._v$2=f),h!==u._v$3&&(l.selected=u._v$3=h),p!==u._v$4&&(l.sdk=u._v$4=p),u},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0}),l}}),null),k(s,S(ee,{get when(){return e?.patientId},get children(){return S(ee,{get when(){return i?.selectedPatient?.data?.id},get fallback(){return(()=>{const l=H(()=>document.importNode(JB,!0));return l.style.setProperty("font-size","1rem"),l._$owner=A(),l})()},get children(){const l=qB.cloneNode(!0),u=l.firstChild;return k(l,()=>i?.selectedPatient?.data?.name?.full,u),k(l,()=>V4(i?.selectedPatient?.data?.dateOfBirth||""),null),l}})}}),null),k(s,S(ee,{get when(){return e.store.patient?.value?.id&&e.enableOrder&&!e.hideAddress},get children(){return[(()=>{const l=H(()=>document.importNode(WB,!0));return l.addEventListener("photon-patient-updated",()=>{r.getSelectedPatient(e.client.getSDK(),e.store.patient?.value?.id)}),l._$owner=A(),q(u=>{const d=t(),f=e.store.patient.value.id;return d!==u._v$5&&(l.open=u._v$5=d),f!==u._v$6&&(l.patientId=u._v$6=f),u},{_v$5:void 0,_v$6:void 0}),l})(),S(ee,{get when(){return e.store.patient?.value},get children(){return[GB.cloneNode(!0),S(ee,{get when(){return e.store.patient.value.address},get children(){const l=KB.cloneNode(!0),u=l.firstChild,d=u.nextSibling,f=d.firstChild,h=f.firstChild,p=h.firstChild,m=h.nextSibling,v=f.nextSibling;return k(u,()=>e.store.patient.value.address.street1),k(l,(()=>{const b=se(()=>!!e.store.patient.value.address.street2);return()=>b()?(()=>{const y=eH.cloneNode(!0);return k(y,()=>e.store.patient.value.address.street2),y})():null})(),d),k(h,()=>e.store.patient.value.address.city,p),k(m,()=>e.store.patient.value.address.state),k(v,()=>e.store.patient.value.address.postalCode),l}}),S(ee,{get when(){return!e.store.patient.value.address},get children(){return[(()=>{const l=QB.cloneNode(!0);return q(u=>{const d=!!e.store.address.error,f=!!e.store.address.error,h=!!e.store.address.error,p=!!e.store.address.error;return d!==u._v$7&&l.classList.toggle("p-2",u._v$7=d),f!==u._v$8&&l.classList.toggle("border-red-500",u._v$8=f),h!==u._v$9&&l.classList.toggle("border-2",u._v$9=h),p!==u._v$10&&l.classList.toggle("rounded",u._v$10=p),u},{_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0}),l})(),S(ee,{get when(){return e.store.address.error},get children(){const l=YB.cloneNode(!0);return k(l,()=>e.store.address.error),l}})]}})]}}),(()=>{const l=H(()=>document.importNode(XB,!0));return l.addEventListener("photon-clicked",()=>{n(!1),n(!0)}),l._$owner=A(),l})()]}}),null),a})()},iH=T('<p class="font-sans text-red-500 text-sm pt-1.5"></p>'),oH=T('<div><photon-card><p class="italic font-sans text-gray-500">No prescriptions pending</p></photon-card></div>'),aH=T('<div><photon-card><div class="w-full flex justify-between"><p class="italic font-sans text-gray-500">Loading Prescriptions...</p><sl-spinner></sl-spinner></div></photon-card></div>'),sH=T('<photon-card><photon-dialog label="Overwrite in progress prescription?" confirm-text="Yes, Overwrite" cancel-text="No, Cancel"><p class="font-sans text-lg xs:text-base">You are editing a prescription that has not been added. This will be overwritten if you edit another prescription.</p></photon-dialog><photon-dialog label="Delete pending prescription?" confirm-text="Yes, Delete" cancel-text="No, Cancel"><p class="font-sans text-lg xs:text-base">Deleting this prescription will remove it from your pending prescriptions. This action cannot be undone.</p></photon-dialog><div class="flex flex-col gap-3"><p class="font-sans text-l font-medium">Pending Prescriptions</p></div></photon-card>'),lH=T('<photon-card><div class="flex flex-row items-center"><div class="flex flex-col flex-grow"><p class="font-medium font-sans"></p><p class="font-normal text-gray-700 overflow-hidden overflow-ellipsis font-sans"> <!>, <!> refills - </p></div><div class="flex flex-row"><sl-icon-button class="self-end text-xl edit-icon-button" name="pencil-square"></sl-icon-button><sl-icon-button class="self-end text-xl remove-icon-button" name="trash3"></sl-icon-button></div></div></photon-card>'),cH=st(fr(Qk(co()),1,1/0),"You must add at least 1 Prescription"),uH=e=>{const[t,n]=V(!1),[r,i]=V(!1),[o,a]=V(void 0),[s,c]=V();e.actions.registerValidator({key:"draftPrescriptions",validator:cH});const l=()=>{o().treatment&&(Mb(e.actions,o()),e.actions.updateFormValue({key:"catalogId",value:o().catalogId}),e.actions.updateFormValue({key:"draftPrescriptions",value:e.store.draftPrescriptions.value.filter(d=>d.id!==o().id)}),window.scrollTo({behavior:"smooth",top:(e.prescriptionRef?.getBoundingClientRect().top||0)-document.body.getBoundingClientRect().top-70}))},u=d=>{const f=e.store.draftPrescriptions.value.find(h=>h.id===d);a(f),e.store.treatment.value?i(!0):(e.setIsEditing(!0),l())};return(()=>{const d=H(()=>document.importNode(sH,!0)),f=d.firstChild,h=f.nextSibling,p=h.nextSibling;return p.firstChild,d._$owner=A(),f.addEventListener("photon-dialog-confirmed",()=>{l(),i(!1),a(void 0)}),f.addEventListener("photon-dialog-canceled",()=>{i(!1),a(void 0)}),f._$owner=A(),h.addEventListener("photon-dialog-confirmed",()=>{e.actions.updateFormValue({key:"draftPrescriptions",value:e.store.draftPrescriptions.value.filter(m=>m.id!==s())}),n(!1),c(void 0)}),h.addEventListener("photon-dialog-canceled",()=>{n(!1),c(void 0)}),h._$owner=A(),k(p,S(ee,{get when(){return(e.store.draftPrescriptions?.value??[]).length===0&&!e.isLoading},get children(){const m=H(()=>document.importNode(oH,!0)),v=m.firstChild;return v._$owner=A(),k(m,S(ee,{get when(){return e.store.draftPrescriptions?.error},get children(){const b=iH.cloneNode(!0);return k(b,()=>e.store.draftPrescriptions?.error),b}}),null),q(()=>v.invalid=e.store.draftPrescriptions?.error),m}}),null),k(p,S(ee,{get when(){return e.isLoading},get children(){const m=H(()=>document.importNode(aH,!0)),v=m.firstChild,b=v.firstChild,y=b.firstChild,g=y.nextSibling;return v._$owner=A(),g.style.setProperty("font-size","1rem"),g._$owner=A(),m}}),null),k(p,S(sr,{get each(){return e.store.draftPrescriptions?.value??[]},children:m=>(()=>{const v=H(()=>document.importNode(lH,!0)),b=v.firstChild,y=b.firstChild,g=y.firstChild,_=g.nextSibling,x=_.firstChild,O=x.nextSibling,C=O.nextSibling,M=C.nextSibling;M.nextSibling;const D=y.nextSibling,F=D.firstChild,Y=F.nextSibling;return v._$owner=A(),k(g,()=>m.treatment.name),k(_,()=>m.dispenseQuantity,x),k(_,()=>m.dispenseUnit,O),k(_,()=>m.refillsInput,M),k(_,()=>m.instructions,null),F.$$click=()=>{u(m.id)},F._$owner=A(),Y.$$click=()=>{n(!0),c(m.id)},Y._$owner=A(),v})()}),null),q(m=>{const v=r(),b=t();return v!==m._v$&&(f.open=m._v$=v),b!==m._v$2&&(h.open=m._v$2=b),m},{_v$:void 0,_v$2:void 0}),d})()};Yi(["click"]);const dH=T('<photon-card><p class="italic font-sans text-gray-500">Please select a patient</p></photon-card>'),fH=T('<photon-card><p class="italic font-sans text-gray-500">Please update patient address in order to select pharmacy</p></photon-card>'),hH=T('<div class="flex flex-col gap-2"><p class="font-sans text-sm font-medium flex-grow">Search for a Local Pharmacy</p><photon-pharmacy-search></photon-pharmacy-search></div>'),pH=T('<photon-card><div class="flex flex-col gap-3"><div class="flex flex-row"><p class="font-sans text-l font-medium flex-grow">Select Pharmacy</p></div></div></photon-card>'),mH=st(Kc(Kt(),co()),"Please select or search for a pharmacy..."),vH=e=>(e.actions.registerValidator({key:"pharmacy",validator:mH}),(()=>{const t=H(()=>document.importNode(pH,!0)),n=t.firstChild;return n.firstChild,t._$owner=A(),k(n,S(ee,{get when(){return!e.store.patient?.value},get children(){const r=H(()=>document.importNode(dH,!0));return r._$owner=A(),r}}),null),k(n,S(ee,{get when(){return e.store.patient?.value&&!e.store.address?.value},get children(){const r=H(()=>document.importNode(fH,!0));return r._$owner=A(),r}}),null),k(n,S(ee,{get when(){return e.store.patient?.value&&e.store.address?.value},get children(){const r=H(()=>document.importNode(hH,!0)),i=r.firstChild,o=i.nextSibling;return o.addEventListener("photon-pharmacy-selected",a=>{e.actions.updateFormValue({key:"pharmacy",value:a.detail.pharmacy})}),o.addEventListener("photon-pharmacy-removed",()=>{e.actions.updateFormValue({key:"pharmacy",value:void 0})}),o._$owner=A(),q(a=>{const s=e.store.pharmacy?.error??!1,c=e.store.pharmacy?.error,l=e.store.patient.value.address?`${e.store.patient.value.address.street1} ${e.store.patient.value.address.street2||""} ${e.store.patient.value.address.city}, ${e.store.patient.value.address.state} ${e.store.patient.value.address.postalCode}`:"",u=e.store.patient.value.preferredPharmacies?.[0]?.id??"";return s!==a._v$&&(o.invalid=a._v$=s),c!==a._v$2&&(o.helpText=a._v$2=c),l!==a._v$3&&(o.address=a._v$3=l),u!==a._v$4&&(o.selected=a._v$4=u),a},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0}),r}}),null),t})()),gH=T("<sl-spinner></sl-spinner>"),yH=T('<div class="flex flex-col gap-2"></div>'),bH=T('<photon-card><div class="flex flex-col gap-3"><div class="flex flex-row"><p class="font-sans text-l font-medium flex-grow">Selected Pharmacy</p></div></div></photon-card>'),$H=e=>{const t=pt(),[n,r]=V({name:""});return me(async()=>{if(e.pharmacyId&&t){const{data:i}=await t.getSDK().clinical.pharmacy.getPharmacy({id:e.pharmacyId});r(i.pharmacy)}}),(()=>{const i=H(()=>document.importNode(bH,!0)),o=i.firstChild;return o.firstChild,i._$owner=A(),k(o,S(ee,{get when(){return!n()},get children(){const a=H(()=>document.importNode(gH,!0));return a.style.setProperty("font-size","1rem"),a._$owner=A(),a}}),null),k(o,S(ee,{get when(){return n()},get children(){const a=yH.cloneNode(!0);return k(a,()=>n()?.name),a}}),null),i})()},wH=T('<sl-alert variant="warning" open><sl-icon slot="icon" name="exclamation-triangle"></sl-icon><strong>You are not signed in</strong><br></sl-alert>'),_H=T('<sl-alert variant="warning" open><sl-icon slot="icon" name="exclamation-triangle"></sl-icon><strong>Something went wrong, please contact support at Photon Health <a href="mailto:support@photon.health">support@photon.health</a></strong><br></sl-alert>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");function pv(e,t){for(let n=0;n<e.length;n++)if(t.indexOf(e[n])===-1)return!1;return!0}const Db=e=>{const t=Nt({permissions:[]},e),n=pt(),[r,i]=V(n?.authentication.state.isLoading||!1),[o,a]=V(n?.authentication.state.isAuthenticated||!1),[s,c]=V(n?.authentication.state.isInOrg||!1),[l,u]=V(pv(t.permissions,n?.authentication.state.permissions||[]));return me(()=>{i(n?.authentication.state.isLoading||!1)}),me(()=>{a(n?.authentication.state.isAuthenticated||!1)}),me(()=>{c(n?.authentication.state.isInOrg||!1)}),me(()=>{u(pv(t.permissions,n?.authentication.state.permissions||[]))}),S(ee,{get when(){return n&&!r()},get children(){return[S(ee,{get when(){return!o()},get children(){const d=H(()=>document.importNode(wH,!0)),f=d.firstChild;return d._$owner=A(),f._$owner=A(),d}}),S(ee,{get when(){return se(()=>!!o())()&&(!s()||!l())},get children(){const d=H(()=>document.importNode(_H,!0)),f=d.firstChild,h=f.nextSibling,p=h.firstChild,m=p.nextSibling;return d._$owner=A(),f._$owner=A(),m.style.setProperty("text-decoration","underline"),d}}),S(ee,{get when(){return se(()=>!!s())()&&l()},get children(){return t.children}})]}})},xH=T('<div class="w-full flex justify-center"><sl-spinner></sl-spinner></div>'),kH=T("<div></div>"),EH=T('<div class="m-3"></div>'),SH=T('<photon-button class="w-full xs:w-fit" variant="outline">Add Prescription</photon-button>'),OH=T('<div class="flex flex-row justify-end gap-2"><photon-button class="w-full xs:w-fit"></photon-button></div>'),CH=T('<div><style></style><style></style><style></style><style></style><div><div class="flex flex-col gap-8"></div></div></div>'),NH=T("<div>No errors...</div>"),TH=T('<sl-alert variant="warning" open><sl-icon slot="icon" name="exclamation-triangle"></sl-icon><strong>Error with <!>: </strong><br><br></sl-alert>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");const PH=_a`
|
|
2894
|
+
`}};Ie.styles=zB;w([rt(".button")],Ie.prototype,"button",2);w([Dn()],Ie.prototype,"hasFocus",2);w([Dn()],Ie.prototype,"invalid",2);w([E()],Ie.prototype,"title",2);w([E({reflect:!0})],Ie.prototype,"variant",2);w([E({reflect:!0})],Ie.prototype,"size",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"caret",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"disabled",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"loading",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"outline",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"pill",2);w([E({type:Boolean,reflect:!0})],Ie.prototype,"circle",2);w([E()],Ie.prototype,"type",2);w([E()],Ie.prototype,"name",2);w([E()],Ie.prototype,"value",2);w([E()],Ie.prototype,"href",2);w([E()],Ie.prototype,"target",2);w([E()],Ie.prototype,"rel",2);w([E()],Ie.prototype,"download",2);w([E()],Ie.prototype,"form",2);w([E({attribute:"formaction"})],Ie.prototype,"formAction",2);w([E({attribute:"formenctype"})],Ie.prototype,"formEnctype",2);w([E({attribute:"formmethod"})],Ie.prototype,"formMethod",2);w([E({attribute:"formnovalidate",type:Boolean})],Ie.prototype,"formNoValidate",2);w([E({attribute:"formtarget"})],Ie.prototype,"formTarget",2);w([Ve("disabled",{waitUntilFirstUpdate:!0})],Ie.prototype,"handleDisabledChange",1);Ie=w([It("sl-button")],Ie);const Mb=(e,t)=>{e.updateFormValue({key:"treatment",value:t.treatment}),t.dispenseAsWritten&&e.updateFormValue({key:"dispenseAsWritten",value:t.dispenseAsWritten}),t.dispenseQuantity&&e.updateFormValue({key:"dispenseQuantity",value:Number(t.dispenseQuantity)}),t.dispenseUnit&&e.updateFormValue({key:"dispenseUnit",value:t.dispenseUnit}),t.daysSupply&&e.updateFormValue({key:"daysSupply",value:Number(t.daysSupply)}),t.fillsAllowed&&e.updateFormValue({key:"refillsInput",value:Number(t.fillsAllowed)-1}),t.instructions&&e.updateFormValue({key:"instructions",value:t.instructions}),t.notes&&e.updateFormValue({key:"notes",value:t.notes})},jB=N('<photon-checkbox label="Add To Templates" form-name="daw"></photon-checkbox>'),VB=N('<photon-card title="Add Prescription"><style></style><div class="flex flex-col sm:gap-3"><photon-treatment-select label="Search Treatment Catalog"></photon-treatment-select><div class="flex flex-col sm:flex-none sm:grid sm:grid-cols-2 sm:gap-4"><div class="order-last sm:order-first"><photon-checkbox label="Dispense as written" tip="This prescription will be filled generically unless this box is checked" form-name="daw" class="flex-grow"></photon-checkbox><photon-med-search-dialog></photon-med-search-dialog></div><div class="pb-4 md:py-2 text-left sm:text-right"><a class="font-sans text-gray-500 text-sm hover:text-black hover:cursor-pointer">Advanced Search \u2192</a></div></div><div class="mt-2 sm:mt-0 md:max-w-[50%] md:pr-2"><photon-datepicker label="Effective Date" required="true"></photon-datepicker></div><div class="mt-2 sm:mt-0 sm:grid sm:grid-cols-2 sm:gap-4"><div class="flex items-end gap-1"><photon-number-input class="flex-grow flex-1 w-2/5 sm:w-auto" label="Quantity" required="true" min="1"></photon-number-input><div><photon-button variant="outline" class="w-fit"><button><sl-icon name="calculator"></sl-icon></button></photon-button><div class="pt-1"></div></div></div><photon-dispense-units label="Dispense Unit" required="true" force-label-size="true"></photon-dispense-units></div><div class="sm:grid sm:grid-cols-2 sm:gap-4"><photon-number-input class="flex-grow flex-shrink flex-1" label="Days Supply" required="true" min="0"></photon-number-input><photon-number-input class="flex-grow flex-shrink flex-1" label="Refills" required="true" min="0"></photon-number-input></div><photon-textarea label="Patient Instructions (SIG)" form-name="patient_instructions" required="true" placeholder="Enter patient instructions"></photon-textarea><photon-textarea label="Pharmacy Note" placeholder="Enter pharmacy note"></photon-textarea><div class="flex flex-col xs:flex-row gap-2"><div class="flex flex-grow justify-end"><photon-button class="w-full xs:w-fit">Add Prescription</photon-button></div></div></div></photon-card>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");const UB={treatment:st(Kc(Kt(),co()),"Please select a treatment..."),dispenseQuantity:st(rd(td(),1),"Quantity must be positive"),daysSupply:st(rd(td(),0),"Days Supply must be at least 0"),refillsInput:st(rd(td(),0),"Refills must be at least 0"),instructions:st(fr(Kt(),1,1/0),"Please enter instructions for the patient..."),effectiveDate:st(RT(new Date),"Please choose a date that isn't in the past")},BB=e=>{let t;const[n,r]=V(void 0),[i]=V(void 0),[o,a]=V(!1);let s;for(const[c,l]of Object.entries(UB))e.actions.registerValidator({key:c,validator:l});return(()=>{const c=H(()=>document.importNode(VB,!0)),l=c.firstChild,u=l.nextSibling,d=u.firstChild,f=d.nextSibling,h=f.firstChild,p=h.firstChild,m=p.nextSibling,v=h.nextSibling,b=v.firstChild,y=f.nextSibling,g=y.firstChild,_=y.nextSibling,k=_.firstChild,O=k.firstChild,C=O.nextSibling,M=C.firstChild,D=M.firstChild,F=D.firstChild,Y=M.nextSibling,J=k.nextSibling,G=_.nextSibling,j=G.firstChild,z=j.nextSibling,Q=G.nextSibling,I=Q.nextSibling,U=I.nextSibling,W=U.firstChild,de=W.firstChild,be=s;typeof be=="function"?he(be,c):s=c,c._$owner=A(),x(l,FB),u.addEventListener("photon-medication-selected",B=>{r(B.detail.medication),e.actions.updateFormValue({key:"treatment",value:B.detail.medication})}),d.addEventListener("photon-treatment-selected",B=>{B.detail.data.__typename==="PrescriptionTemplate"?Mb(e.actions,B.detail.data):e.actions.updateFormValue({key:"treatment",value:B.detail.data}),e.actions.updateFormValue({key:"catalogId",value:B.detail.catalogId})}),d._$owner=A(),p.addEventListener("photon-checkbox-toggled",B=>e.actions.updateFormValue({key:"dispenseAsWritten",value:B.detail.checked})),p._$owner=A();const P=t;return typeof P=="function"?he(P,m):t=m,m._$owner=A(),b.$$click=()=>t.open=!0,g.addEventListener("photon-datepicker-selected",B=>e.actions.updateFormValue({key:"effectiveDate",value:B.detail.date})),g._$owner=A(),O.addEventListener("photon-input-changed",B=>{const Ce=Number(B.detail.input);!isNaN(Ce)&&B.detail.input!==""&&e.actions.updateFormValue({key:"dispenseQuantity",value:Ce})}),O.style.setProperty("width","100px"),O._$owner=A(),x(k,S(RB,{get open(){return o()},onClose:()=>a(!1),get medicationName(){return e.store.treatment?.value?.name},setAutocompleteValues:({liquidDose:B,totalLiquid:Ce,unit:te,days:ye})=>{e.actions.updateFormValue({key:"daysSupply",value:Number(ye)}),e.actions.updateFormValue({key:"dispenseQuantity",value:Number(Ce)}),e.actions.updateFormValue({key:"instructions",value:`${B} ${te} ${e.store.instructions?.value}`}),te==="mL"&&e.actions.updateFormValue({key:"dispenseUnit",value:"Milliliter"})}}),C),M.addEventListener("photon-clicked",()=>a(!0)),M._$owner=A(),D.$$click=()=>a(!0),F._$owner=A(),Y.style.setProperty("height","23px"),J.addEventListener("photon-dispense-unit-selected",B=>e.actions.updateFormValue({key:"dispenseUnit",value:B.detail.dispenseUnit.name})),J._$owner=A(),j.addEventListener("photon-input-changed",B=>{e.actions.updateFormValue({key:"daysSupply",value:Number(B.detail.input)})}),j._$owner=A(),z.addEventListener("photon-input-changed",B=>e.actions.updateFormValue({key:"refillsInput",value:Number(B.detail.input)})),z._$owner=A(),Q.addEventListener("photon-textarea-changed",B=>e.actions.updateFormValue({key:"instructions",value:B.detail.value})),Q._$owner=A(),I.addEventListener("photon-textarea-changed",B=>e.actions.updateFormValue({key:"notes",value:B.detail.value})),I._$owner=A(),x(U,S(ee,{get when(){return!e.hideAddToTemplates},get children(){const B=H(()=>document.importNode(jB,!0));return B.addEventListener("photon-checkbox-toggled",Ce=>e.actions.updateFormValue({key:"addToTemplates",value:Ce.detail.checked})),B._$owner=A(),q(()=>B.checked=e.store.addToTemplates?.value||!1),B}}),W),de.addEventListener("photon-clicked",()=>{const B=["treatment","effectiveDate","dispenseQuantity","daysSupply","refillsInput","instructions"];e.actions.validate(B),e.actions.hasErrors(B)||(e.actions.updateFormValue({key:"draftPrescriptions",value:[...e.store.draftPrescriptions?.value||[],{id:String(Math.random()),effectiveDate:e.store.effectiveDate.value,treatment:e.store.treatment.value,dispenseAsWritten:e.store.dispenseAsWritten.value,dispenseQuantity:e.store.dispenseQuantity.value,dispenseUnit:e.store.dispenseUnit.value,daysSupply:e.store.daysSupply.value,refillsInput:e.store.refillsInput.value,instructions:e.store.instructions.value,notes:e.store.notes.value,fillsAllowed:e.store.refillsInput.value+1,addToTemplates:e.store.addToTemplates?.value??!1,catalogId:e.store.catalogId.value??void 0}]}),e.actions.updateFormValue({key:"effectiveDate",value:Qc(new Date,"yyyy-MM-dd").toString()}),e.actions.clearKeys(["treatment","dispenseAsWritten","dispenseQuantity","dispenseUnit","daysSupply","refillsInput","instructions","notes"]),r(void 0),e.actions.updateFormValue({key:"treatment",value:void 0}),e.actions.updateFormValue({key:"refillsInput",value:0}),e.actions.updateFormValue({key:"dispenseAsWritten",value:!1}),e.actions.updateFormValue({key:"dispenseQuantity",value:null}),e.actions.updateFormValue({key:"daysSupply",value:null}),e.actions.updateFormValue({key:"instructions",value:""}),e.actions.updateFormValue({key:"notes",value:""}))}),de._$owner=A(),q(B=>{const Ce=e.store.treatment?.value??void 0,te=e.store.treatment?.error??!1,ye=e.store.treatment?.error,Ne=n(),ce=e.store.effectiveDate?.error??!1,re=e.store.effectiveDate?.error,ae=e.store.dispenseQuantity?.error??!1,_e=e.store.dispenseQuantity?.error,it=e.store.dispenseUnit?.value??i()?.name,kt=e.store.daysSupply?.error??!1,mt=e.store.daysSupply?.error,Vt=e.store.refillsInput?.error??!1,Qn=e.store.refillsInput?.error,ho=e.store.instructions?.error??!1,po=e.store.instructions?.error;return Ce!==B._v$&&(d.selected=B._v$=Ce),te!==B._v$2&&(d.invalid=B._v$2=te),ye!==B._v$3&&(d.helpText=B._v$3=ye),Ne!==B._v$4&&(d.offCatalogOption=B._v$4=Ne),ce!==B._v$5&&(g.invalid=B._v$5=ce),re!==B._v$6&&(g.helpText=B._v$6=re),ae!==B._v$7&&(O.invalid=B._v$7=ae),_e!==B._v$8&&(O.helpText=B._v$8=_e),it!==B._v$9&&(J.selected=B._v$9=it),kt!==B._v$10&&(j.invalid=B._v$10=kt),mt!==B._v$11&&(j.helpText=B._v$11=mt),Vt!==B._v$12&&(z.invalid=B._v$12=Vt),Qn!==B._v$13&&(z.helpText=B._v$13=Qn),ho!==B._v$14&&(Q.invalid=B._v$14=ho),po!==B._v$15&&(Q.helpText=B._v$15=po),B},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0,_v$5:void 0,_v$6:void 0,_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0,_v$11:void 0,_v$12:void 0,_v$13:void 0,_v$14:void 0,_v$15:void 0}),q(()=>p.checked=e.store.dispenseAsWritten?.value||!1),q(()=>O.value=e.store.dispenseQuantity?.value??null),q(()=>j.value=e.store.daysSupply?.value??null),q(()=>z.value=e.store.refillsInput?.value??0),q(()=>Q.value=e.store.instructions?.value),q(()=>I.value=e.store.notes?.value),c})()};Yi(["click"]);const HB=N("<photon-patient-select></photon-patient-select>"),qB=N('<p class="font-sans text-gray-700">, </p>'),WB=N("<photon-patient-dialog></photon-patient-dialog>"),GB=N('<p class="font-sans text-sm font-medium">Patient Address</p>'),KB=N('<div class="flex flex-col font-sans text-gray-700"><p></p><div class="flex flex-row gap-1"><div class="flex flex-row"><p>,</p><p></p></div><p></p></div></div>'),QB=N('<p class="italic font-sans text-gray-500">Please edit patient and add address</p>'),YB=N('<p class="font-sans text-red-500 text-sm"></p>'),XB=N('<photon-button class="self-end" variant="outline">Edit Patient</photon-button>'),ZB=N('<photon-card><div class="flex flex-col gap-3"><p class="font-sans text-l font-medium"></p></div></photon-card>'),JB=N("<sl-spinner></sl-spinner>"),eH=N("<p></p>"),tH=st(Kc(Kt(),co()),"Please select a patient..."),nH=st(Kc(Kt(),co()),"Please enter an address for patient..."),rH=e=>{const[t,n]=V(!1),{actions:r,store:i}=Gc;e.actions.registerValidator({key:"patient",validator:tH}),e.enableOrder&&e.actions.registerValidator({key:"address",validator:nH});const o=a=>{e.actions.updateFormValue({key:"patient",value:a.detail.patient}),e.enableOrder&&!e.hideAddress&&e.actions.updateFormValue({key:"address",value:a.detail.patient.address})};return ht(()=>{e?.patientId&&r.getSelectedPatient(e.client.getSDK(),e.patientId)}),me(()=>{i?.selectedPatient?.data&&e?.patientId&&o({detail:{patient:i?.selectedPatient?.data}})}),(()=>{const a=H(()=>document.importNode(ZB,!0)),s=a.firstChild,c=s.firstChild;return a._$owner=A(),x(c,()=>e?.patientId?"Patient":"Select Patient"),x(s,S(ee,{get when(){return!e?.patientId},get children(){const l=H(()=>document.importNode(HB,!0));return l.addEventListener("photon-patient-selected",o),l._$owner=A(),q(u=>{const d=e.store.patient?.error??!1,f=e.store.patient?.error,h=e.store.patient?.value?.id??e.patientId,p=e.client.getSDK();return d!==u._v$&&(l.invalid=u._v$=d),f!==u._v$2&&(l.helpText=u._v$2=f),h!==u._v$3&&(l.selected=u._v$3=h),p!==u._v$4&&(l.sdk=u._v$4=p),u},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0}),l}}),null),x(s,S(ee,{get when(){return e?.patientId},get children(){return S(ee,{get when(){return i?.selectedPatient?.data?.id},get fallback(){return(()=>{const l=H(()=>document.importNode(JB,!0));return l.style.setProperty("font-size","1rem"),l._$owner=A(),l})()},get children(){const l=qB.cloneNode(!0),u=l.firstChild;return x(l,()=>i?.selectedPatient?.data?.name?.full,u),x(l,()=>V4(i?.selectedPatient?.data?.dateOfBirth||""),null),l}})}}),null),x(s,S(ee,{get when(){return e.store.patient?.value?.id&&e.enableOrder&&!e.hideAddress},get children(){return[(()=>{const l=H(()=>document.importNode(WB,!0));return l.addEventListener("photon-patient-updated",()=>{r.getSelectedPatient(e.client.getSDK(),e.store.patient?.value?.id)}),l._$owner=A(),q(u=>{const d=t(),f=e.store.patient.value.id;return d!==u._v$5&&(l.open=u._v$5=d),f!==u._v$6&&(l.patientId=u._v$6=f),u},{_v$5:void 0,_v$6:void 0}),l})(),S(ee,{get when(){return e.store.patient?.value},get children(){return[GB.cloneNode(!0),S(ee,{get when(){return e.store.patient.value.address},get children(){const l=KB.cloneNode(!0),u=l.firstChild,d=u.nextSibling,f=d.firstChild,h=f.firstChild,p=h.firstChild,m=h.nextSibling,v=f.nextSibling;return x(u,()=>e.store.patient.value.address.street1),x(l,(()=>{const b=se(()=>!!e.store.patient.value.address.street2);return()=>b()?(()=>{const y=eH.cloneNode(!0);return x(y,()=>e.store.patient.value.address.street2),y})():null})(),d),x(h,()=>e.store.patient.value.address.city,p),x(m,()=>e.store.patient.value.address.state),x(v,()=>e.store.patient.value.address.postalCode),l}}),S(ee,{get when(){return!e.store.patient.value.address},get children(){return[(()=>{const l=QB.cloneNode(!0);return q(u=>{const d=!!e.store.address.error,f=!!e.store.address.error,h=!!e.store.address.error,p=!!e.store.address.error;return d!==u._v$7&&l.classList.toggle("p-2",u._v$7=d),f!==u._v$8&&l.classList.toggle("border-red-500",u._v$8=f),h!==u._v$9&&l.classList.toggle("border-2",u._v$9=h),p!==u._v$10&&l.classList.toggle("rounded",u._v$10=p),u},{_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0}),l})(),S(ee,{get when(){return e.store.address.error},get children(){const l=YB.cloneNode(!0);return x(l,()=>e.store.address.error),l}})]}})]}}),(()=>{const l=H(()=>document.importNode(XB,!0));return l.addEventListener("photon-clicked",()=>{n(!1),n(!0)}),l._$owner=A(),l})()]}}),null),a})()},iH=N('<p class="font-sans text-red-500 text-sm pt-1.5"></p>'),oH=N('<div><photon-card><p class="italic font-sans text-gray-500">No prescriptions pending</p></photon-card></div>'),aH=N('<div><photon-card><div class="w-full flex justify-between"><p class="italic font-sans text-gray-500">Loading Prescriptions...</p><sl-spinner></sl-spinner></div></photon-card></div>'),sH=N('<photon-card><photon-dialog label="Overwrite in progress prescription?" confirm-text="Yes, Overwrite" cancel-text="No, Cancel"><p class="font-sans text-lg xs:text-base">You are editing a prescription that has not been added. This will be overwritten if you edit another prescription.</p></photon-dialog><photon-dialog label="Delete pending prescription?" confirm-text="Yes, Delete" cancel-text="No, Cancel"><p class="font-sans text-lg xs:text-base">Deleting this prescription will remove it from your pending prescriptions. This action cannot be undone.</p></photon-dialog><div class="flex flex-col gap-3"><p class="font-sans text-l font-medium">Pending Prescriptions</p></div></photon-card>'),lH=N('<photon-card><div class="flex flex-row items-center"><div class="flex flex-col flex-grow"><p class="font-medium font-sans"></p><p class="font-normal text-gray-700 overflow-hidden overflow-ellipsis font-sans"> <!>, <!> refills - </p></div><div class="flex flex-row"><sl-icon-button class="self-end text-xl edit-icon-button" name="pencil-square"></sl-icon-button><sl-icon-button class="self-end text-xl remove-icon-button" name="trash3"></sl-icon-button></div></div></photon-card>'),cH=st(fr(Qk(co()),1,1/0),"You must add at least 1 Prescription"),uH=e=>{const[t,n]=V(!1),[r,i]=V(!1),[o,a]=V(void 0),[s,c]=V();e.actions.registerValidator({key:"draftPrescriptions",validator:cH});const l=()=>{o().treatment&&(Mb(e.actions,o()),e.actions.updateFormValue({key:"catalogId",value:o().catalogId}),e.actions.updateFormValue({key:"draftPrescriptions",value:e.store.draftPrescriptions.value.filter(d=>d.id!==o().id)}),window.scrollTo({behavior:"smooth",top:(e.prescriptionRef?.getBoundingClientRect().top||0)-document.body.getBoundingClientRect().top-70}))},u=d=>{const f=e.store.draftPrescriptions.value.find(h=>h.id===d);a(f),e.store.treatment.value?i(!0):(e.setIsEditing(!0),l())};return(()=>{const d=H(()=>document.importNode(sH,!0)),f=d.firstChild,h=f.nextSibling,p=h.nextSibling;return p.firstChild,d._$owner=A(),f.addEventListener("photon-dialog-confirmed",()=>{l(),i(!1),a(void 0)}),f.addEventListener("photon-dialog-canceled",()=>{i(!1),a(void 0)}),f._$owner=A(),h.addEventListener("photon-dialog-confirmed",()=>{e.actions.updateFormValue({key:"draftPrescriptions",value:e.store.draftPrescriptions.value.filter(m=>m.id!==s())}),n(!1),c(void 0)}),h.addEventListener("photon-dialog-canceled",()=>{n(!1),c(void 0)}),h._$owner=A(),x(p,S(ee,{get when(){return(e.store.draftPrescriptions?.value??[]).length===0&&!e.isLoading},get children(){const m=H(()=>document.importNode(oH,!0)),v=m.firstChild;return v._$owner=A(),x(m,S(ee,{get when(){return e.store.draftPrescriptions?.error},get children(){const b=iH.cloneNode(!0);return x(b,()=>e.store.draftPrescriptions?.error),b}}),null),q(()=>v.invalid=e.store.draftPrescriptions?.error),m}}),null),x(p,S(ee,{get when(){return e.isLoading},get children(){const m=H(()=>document.importNode(aH,!0)),v=m.firstChild,b=v.firstChild,y=b.firstChild,g=y.nextSibling;return v._$owner=A(),g.style.setProperty("font-size","1rem"),g._$owner=A(),m}}),null),x(p,S(sr,{get each(){return e.store.draftPrescriptions?.value??[]},children:m=>(()=>{const v=H(()=>document.importNode(lH,!0)),b=v.firstChild,y=b.firstChild,g=y.firstChild,_=g.nextSibling,k=_.firstChild,O=k.nextSibling,C=O.nextSibling,M=C.nextSibling;M.nextSibling;const D=y.nextSibling,F=D.firstChild,Y=F.nextSibling;return v._$owner=A(),x(g,()=>m.treatment.name),x(_,()=>m.dispenseQuantity,k),x(_,()=>m.dispenseUnit,O),x(_,()=>m.refillsInput,M),x(_,()=>m.instructions,null),F.$$click=()=>{u(m.id)},F._$owner=A(),Y.$$click=()=>{n(!0),c(m.id)},Y._$owner=A(),v})()}),null),q(m=>{const v=r(),b=t();return v!==m._v$&&(f.open=m._v$=v),b!==m._v$2&&(h.open=m._v$2=b),m},{_v$:void 0,_v$2:void 0}),d})()};Yi(["click"]);const dH=N('<photon-card><p class="italic font-sans text-gray-500">Please select a patient</p></photon-card>'),fH=N('<photon-card><p class="italic font-sans text-gray-500">Please update patient address in order to select pharmacy</p></photon-card>'),hH=N('<div class="flex flex-col gap-2"><p class="font-sans text-sm font-medium flex-grow">Search for a Local Pharmacy</p><photon-pharmacy-search></photon-pharmacy-search></div>'),pH=N('<photon-card><div class="flex flex-col gap-3"><div class="flex flex-row"><p class="font-sans text-l font-medium flex-grow">Select Pharmacy</p></div></div></photon-card>'),mH=st(Kc(Kt(),co()),"Please select or search for a pharmacy..."),vH=e=>(e.actions.registerValidator({key:"pharmacy",validator:mH}),(()=>{const t=H(()=>document.importNode(pH,!0)),n=t.firstChild;return n.firstChild,t._$owner=A(),x(n,S(ee,{get when(){return!e.store.patient?.value},get children(){const r=H(()=>document.importNode(dH,!0));return r._$owner=A(),r}}),null),x(n,S(ee,{get when(){return e.store.patient?.value&&!e.store.address?.value},get children(){const r=H(()=>document.importNode(fH,!0));return r._$owner=A(),r}}),null),x(n,S(ee,{get when(){return e.store.patient?.value&&e.store.address?.value},get children(){const r=H(()=>document.importNode(hH,!0)),i=r.firstChild,o=i.nextSibling;return o.addEventListener("photon-pharmacy-selected",a=>{e.actions.updateFormValue({key:"pharmacy",value:a.detail.pharmacy})}),o.addEventListener("photon-pharmacy-removed",()=>{e.actions.updateFormValue({key:"pharmacy",value:void 0})}),o._$owner=A(),q(a=>{const s=e.store.pharmacy?.error??!1,c=e.store.pharmacy?.error,l=e.store.patient.value.address?`${e.store.patient.value.address.street1} ${e.store.patient.value.address.street2||""} ${e.store.patient.value.address.city}, ${e.store.patient.value.address.state} ${e.store.patient.value.address.postalCode}`:"",u=e.store.patient.value.preferredPharmacies?.[0]?.id??"";return s!==a._v$&&(o.invalid=a._v$=s),c!==a._v$2&&(o.helpText=a._v$2=c),l!==a._v$3&&(o.address=a._v$3=l),u!==a._v$4&&(o.selected=a._v$4=u),a},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0}),r}}),null),t})()),gH=N("<sl-spinner></sl-spinner>"),yH=N('<div class="flex flex-col gap-2"></div>'),bH=N('<photon-card><div class="flex flex-col gap-3"><div class="flex flex-row"><p class="font-sans text-l font-medium flex-grow">Selected Pharmacy</p></div></div></photon-card>'),$H=e=>{const t=pt(),[n,r]=V({name:""});return me(async()=>{if(e.pharmacyId&&t){const{data:i}=await t.getSDK().clinical.pharmacy.getPharmacy({id:e.pharmacyId});r(i.pharmacy)}}),(()=>{const i=H(()=>document.importNode(bH,!0)),o=i.firstChild;return o.firstChild,i._$owner=A(),x(o,S(ee,{get when(){return!n()},get children(){const a=H(()=>document.importNode(gH,!0));return a.style.setProperty("font-size","1rem"),a._$owner=A(),a}}),null),x(o,S(ee,{get when(){return n()},get children(){const a=yH.cloneNode(!0);return x(a,()=>n()?.name),a}}),null),i})()},wH=N('<sl-alert variant="warning" open><sl-icon slot="icon" name="exclamation-triangle"></sl-icon><strong>You are not signed in</strong><br></sl-alert>'),_H=N('<sl-alert variant="warning" open><sl-icon slot="icon" name="exclamation-triangle"></sl-icon><strong>Something went wrong, please contact support at Photon Health <a href="mailto:support@photon.health">support@photon.health</a></strong><br></sl-alert>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");function pv(e,t){for(let n=0;n<e.length;n++)if(t.indexOf(e[n])===-1)return!1;return!0}const Db=e=>{const t=Nt({permissions:[]},e),n=pt(),[r,i]=V(n?.authentication.state.isLoading||!1),[o,a]=V(n?.authentication.state.isAuthenticated||!1),[s,c]=V(n?.authentication.state.isInOrg||!1),[l,u]=V(pv(t.permissions,n?.authentication.state.permissions||[]));return me(()=>{i(n?.authentication.state.isLoading||!1)}),me(()=>{a(n?.authentication.state.isAuthenticated||!1)}),me(()=>{c(n?.authentication.state.isInOrg||!1)}),me(()=>{u(pv(t.permissions,n?.authentication.state.permissions||[]))}),S(ee,{get when(){return n&&!r()},get children(){return[S(ee,{get when(){return!o()},get children(){const d=H(()=>document.importNode(wH,!0)),f=d.firstChild;return d._$owner=A(),f._$owner=A(),d}}),S(ee,{get when(){return se(()=>!!o())()&&(!s()||!l())},get children(){const d=H(()=>document.importNode(_H,!0)),f=d.firstChild,h=f.nextSibling,p=h.firstChild,m=p.nextSibling;return d._$owner=A(),f._$owner=A(),m.style.setProperty("text-decoration","underline"),d}}),S(ee,{get when(){return se(()=>!!s())()&&l()},get children(){return t.children}})]}})},xH=N('<div class="w-full flex justify-center"><sl-spinner></sl-spinner></div>'),kH=N("<div></div>"),EH=N('<div class="m-3"></div>'),SH=N('<photon-button class="w-full xs:w-fit" variant="outline">Add Prescription</photon-button>'),OH=N('<div class="flex flex-row justify-end gap-2"><photon-button class="w-full xs:w-fit"></photon-button></div>'),CH=N('<div><style></style><style></style><style></style><style></style><div><div class="flex flex-col gap-8"></div></div></div>'),NH=N("<div>No errors...</div>"),TH=N('<sl-alert variant="warning" open><sl-icon slot="icon" name="exclamation-triangle"></sl-icon><strong>Error with <!>: </strong><br><br></sl-alert>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");const PH=_a`
|
|
2895
2895
|
fragment CatalogTreatmentsFields on Catalog {
|
|
2896
2896
|
id
|
|
2897
2897
|
treatments {
|
|
@@ -2913,7 +2913,7 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
2913
2913
|
}
|
|
2914
2914
|
}
|
|
2915
2915
|
}
|
|
2916
|
-
`;Me("photon-prescribe-workflow",{patientId:void 0,templateIds:void 0,hideSubmit:!1,hideTemplates:!0,enableOrder:!1,pharmacyId:void 0,loading:!1,address:void 0},(e,t)=>{let n;const{store:r,actions:i}=Q3({dispenseAsWritten:!1,patient:void 0,treatment:void 0,draftPrescriptions:[],pharmacy:void 0,errors:[],address:void 0}),o=pt(),[a,s]=V(!e.templateIds),[c,l]=V([]),[u,d]=V(!0),[f,h]=V(!1),[p,m]=V(!1),[v,b]=V(o?.authentication.state.isAuthenticated||!1);ht(()=>{e.address&&i.updateFormValue({key:"address",value:e.address})}),me(()=>{!o?.authentication.state.isAuthenticated&&!o?.authentication.state.isLoading&&!o?.authentication.state.error&&o?.authentication.login({appState:{returnTo:window.location.pathname}})}),me(()=>{d(o?.authentication.state.isLoading||!1)}),me(()=>{b(o?.authentication.state.isAuthenticated||!1)}),me(async()=>{if(e.templateIds&&o){m(!0);const D=e.templateIds.split(","),{data:{catalogs:F}}=await o.getSDK().clinical.catalog.getCatalogs();if(F.length===0){console.error("No catalog set");return}const{data:{catalog:Y}}=await o.getSDK().clinical.catalog.getCatalog({id:F[0].id,fragment:{CatalogTreatmentsFields:PH}}),J={};Y.templates.forEach(G=>{G&&(J[G.id]=G)});for(let G=0;G<D.length;G++){const j=D[G],z=J[j];z||console.error(`Invalid template id ${j}`),!z?.treatment||!z?.dispenseQuantity||!z?.dispenseUnit||!z?.fillsAllowed||!z?.instructions?console.error(`Template is missing required prescription details ${j}`):i.updateFormValue({key:"draftPrescriptions",value:[...r.draftPrescriptions?.value||[],{id:String(Math.random()),effectiveDate:Qc(new Date,"yyyy-MM-dd").toString(),treatment:z.treatment,dispenseAsWritten:z.dispenseAsWritten,dispenseQuantity:z.dispenseQuantity,dispenseUnit:z.dispenseUnit,daysSupply:z.daysSupply,refillsInput:z.fillsAllowed?z.fillsAllowed-1:0,fillsAllowed:z.fillsAllowed,instructions:z.instructions,notes:z.notes,addToTemplates:!1,catalogId:void 0}]})}m(!1)}});const y=D=>{const F=new CustomEvent("photon-prescriptions-created",{composed:!0,bubbles:!0,detail:{prescriptions:D}});n?.dispatchEvent(F)},g=D=>{const F=new CustomEvent("photon-order-created",{composed:!0,bubbles:!0,detail:{order:D}});n?.dispatchEvent(F)},_=D=>{const F=new CustomEvent("photon-prescriptions-error",{composed:!0,bubbles:!0,detail:{errors:D}});n?.dispatchEvent(F)},
|
|
2916
|
+
`;Me("photon-prescribe-workflow",{patientId:void 0,templateIds:void 0,hideSubmit:!1,hideTemplates:!0,enableOrder:!1,pharmacyId:void 0,loading:!1,address:void 0},(e,t)=>{let n;const{store:r,actions:i}=Q3({dispenseAsWritten:!1,patient:void 0,treatment:void 0,draftPrescriptions:[],pharmacy:void 0,errors:[],address:void 0}),o=pt(),[a,s]=V(!e.templateIds),[c,l]=V([]),[u,d]=V(!0),[f,h]=V(!1),[p,m]=V(!1),[v,b]=V(o?.authentication.state.isAuthenticated||!1);ht(()=>{e.address&&i.updateFormValue({key:"address",value:e.address})}),me(()=>{!o?.authentication.state.isAuthenticated&&!o?.authentication.state.isLoading&&!o?.authentication.state.error&&o?.authentication.login({appState:{returnTo:window.location.pathname}})}),me(()=>{d(o?.authentication.state.isLoading||!1)}),me(()=>{b(o?.authentication.state.isAuthenticated||!1)}),me(async()=>{if(e.templateIds&&o){m(!0);const D=e.templateIds.split(","),{data:{catalogs:F}}=await o.getSDK().clinical.catalog.getCatalogs();if(F.length===0){console.error("No catalog set");return}const{data:{catalog:Y}}=await o.getSDK().clinical.catalog.getCatalog({id:F[0].id,fragment:{CatalogTreatmentsFields:PH}}),J={};Y.templates.forEach(G=>{G&&(J[G.id]=G)});for(let G=0;G<D.length;G++){const j=D[G],z=J[j];z||console.error(`Invalid template id ${j}`),!z?.treatment||!z?.dispenseQuantity||!z?.dispenseUnit||!z?.fillsAllowed||!z?.instructions?console.error(`Template is missing required prescription details ${j}`):i.updateFormValue({key:"draftPrescriptions",value:[...r.draftPrescriptions?.value||[],{id:String(Math.random()),effectiveDate:Qc(new Date,"yyyy-MM-dd").toString(),treatment:z.treatment,dispenseAsWritten:z.dispenseAsWritten,dispenseQuantity:z.dispenseQuantity,dispenseUnit:z.dispenseUnit,daysSupply:z.daysSupply,refillsInput:z.fillsAllowed?z.fillsAllowed-1:0,fillsAllowed:z.fillsAllowed,instructions:z.instructions,notes:z.notes,addToTemplates:!1,catalogId:void 0}]})}m(!1)}});const y=D=>{const F=new CustomEvent("photon-prescriptions-created",{composed:!0,bubbles:!0,detail:{prescriptions:D}});n?.dispatchEvent(F)},g=D=>{const F=new CustomEvent("photon-order-created",{composed:!0,bubbles:!0,detail:{order:D}});n?.dispatchEvent(F)},_=D=>{const F=new CustomEvent("photon-prescriptions-error",{composed:!0,bubbles:!0,detail:{errors:D}});n?.dispatchEvent(F)},k=D=>{const F=new CustomEvent("photon-order-error",{composed:!0,bubbles:!0,detail:{errors:D}});n?.dispatchEvent(F)},O=D=>{const F=new CustomEvent("photon-form-validate",{composed:!0,bubbles:!0,detail:{canSubmit:D,form:r,actions:i}});n?.dispatchEvent(F)},C=async D=>{l([]);const F=D?["patient","draftPrescriptions","pharmacy","address"]:["patient","draftPrescriptions"];i.validate(F);const Y=i.getErrors(F);if(Y.length===0){d(!0),i.updateFormValue({key:"errors",value:[]});const J=o.getSDK().clinical.order.createOrder({}),G=o.getSDK().clinical.prescription.createPrescriptions({}),j=[];for(const I of r.draftPrescriptions.value){const U={daysSupply:I.daysSupply,dispenseAsWritten:I.dispenseAsWritten,dispenseQuantity:I.dispenseQuantity,dispenseUnit:I.dispenseUnit,effectiveDate:I.effectiveDate,instructions:I.instructions,notes:I.notes,patientId:r.patient?.value.id,fillsAllowed:I.refillsInput?I.refillsInput+1:1,treatmentId:I.treatment.id};j.push(U)}const{data:z,errors:Q}=await G({variables:{prescriptions:j},refetchQueries:[],awaitRefetchQueries:!1});if(e.enableOrder||d(!1),Q){_(Q);return}if(y(z.createPrescriptions),e.enableOrder){const I=r?.address?.value??r?.patient?.value?.address??{},{__typename:U,name:W,...de}=I,be={street2:"",country:"US",...de},{data:P,errors:B}=await J({variables:{patientId:r.patient?.value.id,pharmacyId:e?.pharmacyId||r.pharmacy?.value.id,address:be,fills:z?.createPrescriptions.map(Ce=>({prescriptionId:Ce.id}))},refetchQueries:[],awaitRefetchQueries:!1});if(e.enableOrder&&d(!1),B){k(B);return}g(P.createOrder)}}else l(Y)};t.element.submitForm=C,me(()=>{O(Boolean(r.draftPrescriptions?.value?.length>0&&r.patient?.value))});let M;return(()=>{const D=CH.cloneNode(!0),F=D.firstChild,Y=F.nextSibling,J=Y.nextSibling,G=J.nextSibling,j=G.nextSibling,z=j.firstChild,Q=n;return typeof Q=="function"?he(Q,D):n=D,x(F,Je),x(Y,Xt),x(J,Yt),x(G,Uk),x(z,S(ee,{get when(){return se(()=>!!(!o||u()))()&&!v()},get children(){const I=H(()=>document.importNode(xH,!0)),U=I.firstChild;return U.style.setProperty("font-size","3rem"),U._$owner=A(),I}}),null),x(z,S(Db,{permissions:["write:prescription"],get children(){return[S(rH,{actions:i,store:r,get patientId(){return e.patientId},client:o,get enableOrder(){return e.enableOrder},get hideAddress(){return!!e.address}}),S(ee,{get when(){return a()||f()},get children(){const I=kH.cloneNode(!0),U=M;return typeof U=="function"?he(U,I):M=I,x(I,S(BB,{get hideAddToTemplates(){return e.hideTemplates},actions:i,store:r})),I}}),S(uH,{prescriptionRef:M,actions:i,store:r,get isLoading(){return p()},setIsEditing:h}),S(ee,{get when(){return e.enableOrder&&!e.pharmacyId},get children(){return S(vH,{store:r,actions:i})}}),S(ee,{get when(){return e.enableOrder&&e.pharmacyId},get children(){return S($H,{get pharmacyId(){return e.pharmacyId}})}}),S(ee,{get when(){return!e.hideSubmit},get children(){return[S(ee,{get when(){return c().length>0&&e.enableOrder},get children(){const I=EH.cloneNode(!0);return x(I,S(sr,{get each(){return c()},get fallback(){return NH.cloneNode(!0)},children:({key:U,error:W})=>(()=>{const de=H(()=>document.importNode(TH,!0)),be=de.firstChild,P=be.nextSibling,B=P.firstChild,Ce=B.nextSibling;Ce.nextSibling;const te=P.nextSibling,ye=te.nextSibling;return de._$owner=A(),be._$owner=A(),x(P,U,Ce),x(de,W,ye),x(de,()=>JSON.stringify(r?.[U]?.value||{}),null),de})()})),I}}),(()=>{const I=H(()=>document.importNode(OH,!0)),U=I.firstChild;return x(I,S(ee,{get when(){return!a()},get children(){const W=H(()=>document.importNode(SH,!0));return W.addEventListener("photon-clicked",async()=>s(!0)),W._$owner=A(),W}}),U),U.addEventListener("photon-clicked",async()=>await C(e.enableOrder)),U._$owner=A(),x(U,()=>e.enableOrder?"Send Order":"Save Prescriptions"),q(()=>U.loading=u()),I})()]}})]}}),null),D})()});const AH=N('<p class="font-sans text-l font-medium mb-2"></p>'),IH=N('<sl-icon-button class="self-start"></sl-icon-button>'),MH=N("<style></style>"),DH=N('<div class="rounded-lg bg-white p-4 shadow-card border border-gray-200"></div>'),LH=N('<div class="flex flex-row justify-between"></div>'),RH=N("<slot></slot>");Me("photon-card",{invalid:!1,title:null,collapsable:!1},e=>{const[t,n]=V(!0);let r=null,i=null;return e.title&&(r=(()=>{const o=AH.cloneNode(!0);return x(o,()=>e.title),o})()),e.collapsable&&(i=(()=>{const o=H(()=>document.importNode(IH,!0));return o.addEventListener("click",()=>{n(!t())}),o._$owner=A(),q(()=>o.name=t()?"chevron-right":"chevron-down"),o})()),[(()=>{const o=MH.cloneNode(!0);return x(o,Je),o})(),(()=>{const o=DH.cloneNode(!0);return x(o,r||i?(()=>{const a=LH.cloneNode(!0);return x(a,r,null),x(a,i,null),a})():null,null),x(o,(()=>{const a=se(()=>!!(e.collapsable&&t()));return()=>a()?null:(()=>{const s=RH.cloneNode(!0);return s._$owner=A(),s})()})(),null),q(a=>{const s=!!e.invalid,c=!!e.invalid;return s!==a._v$&&o.classList.toggle("border-red-500",a._v$=s),c!==a._v$2&&o.classList.toggle("border-2",a._v$2=c),a},{_v$:void 0,_v$2:void 0}),o})()]});const FH=_a`
|
|
2917
2917
|
fragment CatalogTreatmentsFields on Catalog {
|
|
2918
2918
|
id
|
|
2919
2919
|
treatments {
|
|
@@ -2936,7 +2936,7 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
2936
2936
|
}
|
|
2937
2937
|
}
|
|
2938
2938
|
}
|
|
2939
|
-
`,zH=()=>{const[e,t]=kr({catalogs:{data:[],errors:[],isLoading:!1}});return{store:e,actions:{getCatalogs:async r=>{t("catalogs",{...e.catalogs,isLoading:!0});const{data:i,errors:o}=await r.clinical.catalog.getCatalogs({fragment:{CatalogTreatmentsFields:FH}});t("catalogs",{...e.catalogs,isLoading:!1,data:i.catalogs,errors:o})}}}},jH=zH(),VH=
|
|
2939
|
+
`,zH=()=>{const[e,t]=kr({catalogs:{data:[],errors:[],isLoading:!1}});return{store:e,actions:{getCatalogs:async r=>{t("catalogs",{...e.catalogs,isLoading:!0});const{data:i,errors:o}=await r.clinical.catalog.getCatalogs({fragment:{CatalogTreatmentsFields:FH}});t("catalogs",{...e.catalogs,isLoading:!1,data:i.catalogs,errors:o})}}}},jH=zH(),VH=N("<div></div>"),UH=N('<p class="text-sm whitespace-normal leading-snug mb-2"></p>'),BH=N('<p class="text-sm whitespace-normal leading-snug"></p>'),HH=N('<p class="text-xs text-gray-500 overflow-hidden whitespace-nowrap overflow-ellipsis mb-2">QTY: <!> <!> | Days Supply: <!> | Refills: <!> | Sig: </p>');Me("photon-treatment-select",{label:void 0,required:!1,invalid:!1,helpText:void 0,catalogId:void 0,disabled:!1,formName:void 0,selected:void 0,offCatalogOption:void 0},e=>{let t;const n=pt(),{store:r,actions:i}=jH,[o,a]=V("");ht(async()=>{await i.getCatalogs(n.getSDK())});const s=l=>{const u=new CustomEvent("photon-treatment-selected",{composed:!0,bubbles:!0,detail:{data:l,catalogId:r.catalogs.data[0]?.id||""}});t?.dispatchEvent(u)},c=l=>{if(r.catalogs.data.length>0){const u=[...e.offCatalogOption?[e.offCatalogOption]:[],...r.catalogs.data[0].templates.map(f=>f),...r.catalogs.data[0].treatments.map(f=>f)];return l.length===0?u:u.filter(f=>"treatment"in f?f.treatment.name.toLowerCase().includes(l.toLowerCase()):f.name.toLowerCase().includes(l.toLowerCase()))}return[]};return(()=>{const l=VH.cloneNode(!0),u=t;return typeof u=="function"?he(u,l):t=l,l.addEventListener("photon-data-selected",d=>{s(d.detail.data)}),x(l,S(wn,{get data(){return c(o())},groups:[{label:"Off Catalog",filter:d=>d&&typeof d=="object"&&e.offCatalogOption&&d.id===e.offCatalogOption.id},{label:"Templates",filter:d=>d&&typeof d=="object"&&"treatment"in d},{label:"Catalog",filter:d=>d&&typeof d=="object"&&"name"in d&&!("treatment"in d)}],get label(){return e.label},get disabled(){return e.disabled},get required(){return e.required},placeholder:"Select a treatment...",get invalid(){return e.invalid},get isLoading(){return n?.clinical.catalog.state.isLoading||!1},hasMore:!1,get selectedData(){return e.selected??e.offCatalogOption},displayAccessor:(d,f)=>d?.__typename!=="PrescriptionTemplate"?f?(()=>{const h=UH.cloneNode(!0);return x(h,()=>d.name),h})():d?.name||"":f?[(()=>{const h=BH.cloneNode(!0);return x(h,()=>d?.name?`${d.name}: `:"",null),x(h,()=>d.treatment.name,null),h})(),(()=>{const h=HH.cloneNode(!0),p=h.firstChild,m=p.nextSibling,v=m.nextSibling,b=v.nextSibling,y=b.nextSibling,g=y.nextSibling,_=g.nextSibling,k=_.nextSibling;return k.nextSibling,x(h,()=>d.dispenseQuantity,m),x(h,()=>d.dispenseUnit,b),x(h,()=>d.daysSupply,g),x(h,()=>d.fillsAllowed?d.fillsAllowed-1:0,k),x(h,()=>d.instructions,null),h})()]:d.treatment.name,onSearchChange:async d=>a(d),onOpen:async()=>{r.catalogs.data.length===0&&await i.getCatalogs(n.getSDK())},onHide:async()=>a(""),get noDataMsg(){return r.catalogs.data.length===0&&!r.catalogs.isLoading?"No catalog found":"No treatments found"},get helpText(){return e.helpText}})),l})()});var qH=_t`
|
|
2940
2940
|
${At}
|
|
2941
2941
|
|
|
2942
2942
|
:host {
|
|
@@ -3095,7 +3095,7 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
3095
3095
|
<slot></slot>
|
|
3096
3096
|
</div>
|
|
3097
3097
|
</label>
|
|
3098
|
-
`}};St.styles=
|
|
3098
|
+
`}};St.styles=qH;w([rt('input[type="checkbox"]')],St.prototype,"input",2);w([Dn()],St.prototype,"hasFocus",2);w([E()],St.prototype,"title",2);w([E()],St.prototype,"name",2);w([E()],St.prototype,"value",2);w([E({reflect:!0})],St.prototype,"size",2);w([E({type:Boolean,reflect:!0})],St.prototype,"disabled",2);w([E({type:Boolean,reflect:!0})],St.prototype,"checked",2);w([E({type:Boolean,reflect:!0})],St.prototype,"indeterminate",2);w([Wc("checked")],St.prototype,"defaultChecked",2);w([E({reflect:!0})],St.prototype,"form",2);w([E({type:Boolean,reflect:!0})],St.prototype,"required",2);w([Ve("disabled",{waitUntilFirstUpdate:!0})],St.prototype,"handleDisabledChange",1);w([Ve(["checked","indeterminate"],{waitUntilFirstUpdate:!0})],St.prototype,"handleStateChange",1);St=w([It("sl-checkbox")],St);var WH=_t`
|
|
3099
3099
|
${At}
|
|
3100
3100
|
|
|
3101
3101
|
:host {
|
|
@@ -3175,9 +3175,9 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
3175
3175
|
${this.content}
|
|
3176
3176
|
</slot>
|
|
3177
3177
|
</sl-popup>
|
|
3178
|
-
`}};Ot.styles=
|
|
3179
|
-
`;function
|
|
3180
|
-
`,Za=
|
|
3178
|
+
`}};Ot.styles=WH;w([rt("slot:not([name])")],Ot.prototype,"defaultSlot",2);w([rt(".tooltip__body")],Ot.prototype,"body",2);w([rt("sl-popup")],Ot.prototype,"popup",2);w([E()],Ot.prototype,"content",2);w([E()],Ot.prototype,"placement",2);w([E({type:Boolean,reflect:!0})],Ot.prototype,"disabled",2);w([E({type:Number})],Ot.prototype,"distance",2);w([E({type:Boolean,reflect:!0})],Ot.prototype,"open",2);w([E({type:Number})],Ot.prototype,"skidding",2);w([E()],Ot.prototype,"trigger",2);w([E({type:Boolean})],Ot.prototype,"hoist",2);w([Ve("open",{waitUntilFirstUpdate:!0})],Ot.prototype,"handleOpenChange",1);w([Ve(["content","distance","hoist","placement","skidding"])],Ot.prototype,"handleOptionsChange",1);w([Ve("disabled")],Ot.prototype,"handleDisabledChange",1);Ot=w([It("sl-tooltip")],Ot);$n("tooltip.show",{keyframes:[{opacity:0,scale:.8},{opacity:1,scale:1}],options:{duration:150,easing:"ease"}});$n("tooltip.hide",{keyframes:[{opacity:1,scale:1},{opacity:0,scale:.8}],options:{duration:150,easing:"ease"}});const ud=N("<style></style>"),GH=N('<sl-tooltip><sl-icon name="info-circle"></sl-icon></sl-tooltip>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");const KH=e=>{const t=Nt({placement:"top"},e);return[(()=>{const n=ud.cloneNode(!0);return x(n,Je),n})(),(()=>{const n=ud.cloneNode(!0);return x(n,Xt),n})(),(()=>{const n=ud.cloneNode(!0);return x(n,Yt),n})(),(()=>{const n=H(()=>document.importNode(GH,!0)),r=n.firstChild;return n.style.setProperty("--max-width","200px"),n._$owner=A(),r._$owner=A(),q(i=>{const o=t.tip,a=t.placement;return o!==i._v$&&(n.content=i._v$=o),a!==i._v$2&&(n.placement=i._v$2=a),i},{_v$:void 0,_v$2:void 0}),n})()]},dd=N("<style></style>"),QH=N('<div class="flex items-start py-2"><div><p class="flex items-center text-gray-500 text-sm font-medium font-sans"><span class="mr-1"> </span></p><p class="text-gray-400 text-xs font-sans"></p></div></div>'),YH=N("<sl-checkbox checked></sl-checkbox>"),XH=N("<sl-checkbox></sl-checkbox>");ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-checkbox",{label:void 0,required:!1,disabled:!1,checked:!1,tip:void 0},e=>{const[t,n]=V(!1);let r;const i=o=>{const a=new CustomEvent("photon-checkbox-toggled",{composed:!0,bubbles:!0,detail:{checked:o}});r?.dispatchEvent(a)};return ht(()=>{i(t())}),me(()=>{e.checked!==t()&&n(e.checked)}),[(()=>{const o=dd.cloneNode(!0);return x(o,Je),o})(),(()=>{const o=dd.cloneNode(!0);return x(o,Xt),o})(),(()=>{const o=dd.cloneNode(!0);return x(o,Yt),o})(),(()=>{const o=QH.cloneNode(!0),a=o.firstChild,s=a.firstChild,c=s.firstChild,l=c.firstChild,u=s.nextSibling;return x(o,(()=>{const d=se(()=>!!e.checked);return()=>d()?(()=>{const f=H(()=>document.importNode(YH,!0)),h=r;return typeof h=="function"?he(h,f):r=f,f.addEventListener("sl-change",()=>{i(!t()),n(!t())}),f._$owner=A(),q(()=>f.disabled=e.disabled),f})():(()=>{const f=H(()=>document.importNode(XH,!0)),h=r;return typeof h=="function"?he(h,f):r=f,f.addEventListener("sl-change",()=>{i(!t()),n(!t())}),f._$owner=A(),q(()=>f.disabled=e.disabled),f})()})(),a),x(c,()=>e.label,l),x(s,S(ee,{get when(){return e.tip},get children(){return S(KH,{get tip(){return e.tip||""},placement:"right"})}}),null),x(u,()=>e.required?"Required":"Optional"),o})()]});const ZH=`.input::part(base){border-radius:var(--photon-border-radius, .5rem)}.invalid::part(base){--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity));border-width:2px}.invalid::part(form-control-help-text){--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity));font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";padding-top:.5rem}
|
|
3179
|
+
`;function JH(e){const t=e.split(/[/\s-]/);if(t.length!==3)return"";const[n,r,i]=t.map(o=>parseInt(o));return isNaN(n)||isNaN(r)||isNaN(i)||n<1||n>12||r<1||r>31?"":`${i}-${n.toString().padStart(2,"0")}-${r.toString().padStart(2,"0")}`}const Xa=N("<style></style>"),eq=N('<div class="md:py-2 flex flex-col"><sl-input class="input" type="date"></sl-input><p slot="help-text" class="text-sm text-red-500 pt-1 h-[21px] font-sans"></p></div>'),tq=N('<div class="flex items-center pb-2"><p class="text-gray-700 text-sm font-sans"></p></div>'),nq=N('<p class="pl-1 text-red-500">*</p>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-datepicker",{label:void 0,required:!1,invalid:!1,helpText:void 0,disabled:!1,value:void 0,noInitialDate:void 0},e=>{let t,n;const r=e?.noInitialDate?"":Qc(new Date,"yyyy-MM-dd").toString(),[i,o]=V(e?.value||r),a=s=>{const c=new CustomEvent("photon-datepicker-selected",{composed:!0,bubbles:!0,detail:{date:s}});t?.dispatchEvent(c)};return ht(()=>{a(i()),n?.addEventListener("paste",s=>{const c=s.clipboardData.getData("Text"),l=JH(c);l&&(o(l),a(l))})}),[(()=>{const s=Xa.cloneNode(!0);return x(s,Je),s})(),(()=>{const s=Xa.cloneNode(!0);return x(s,Xt),s})(),(()=>{const s=Xa.cloneNode(!0);return x(s,Yt),s})(),(()=>{const s=Xa.cloneNode(!0);return x(s,ZH),s})(),(()=>{const s=H(()=>document.importNode(eq,!0)),c=s.firstChild,l=c.nextSibling,u=t;typeof u=="function"?he(u,s):t=s,x(s,(()=>{const f=se(()=>!!e.label);return()=>f()?(()=>{const h=tq.cloneNode(!0),p=h.firstChild;return x(p,()=>e.label),x(h,(()=>{const m=se(()=>!!e.required);return()=>m()?nq.cloneNode(!0):null})(),null),h})():null})(),c);const d=n;return typeof d=="function"?he(d,c):n=c,c.addEventListener("sl-input",f=>{a(f.target.value)}),c._$owner=A(),x(l,()=>e.helpText),q(f=>{const h=e.disabled,p=!!e.invalid,m=e.invalid;return h!==f._v$&&(c.disabled=f._v$=h),p!==f._v$2&&c.classList.toggle("invalid",f._v$2=p),m!==f._v$3&&(c.invalid=f._v$3=m),f},{_v$:void 0,_v$2:void 0,_v$3:void 0}),q(()=>c.value=i()),s})()]});const rq=`.input::part(base){border-radius:var(--photon-border-radius, .5rem)}.invalid::part(base){--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity));border-width:2px}.invalid::part(form-control-help-text){--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}
|
|
3180
|
+
`,Za=N("<style></style>"),iq=N('<div class="flex flex-col font-sans"><sl-input class="input" type="number"><p slot="help-text" class="text-red-500 pt-1 h-[21px] font-sans"></p></sl-input></div>'),oq=N('<div class="flex items-center pb-2"><p class="text-gray-700 text-sm"></p></div>'),aq=N('<p class="pl-1 text-red-500">*</p>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-number-input",{label:void 0,required:!1,value:void 0,formName:void 0,min:void 0,max:void 0,invalid:!1,helpText:void 0,disabled:!1},e=>{let t;const n=r=>{const i=new CustomEvent("photon-input-changed",{composed:!0,bubbles:!0,detail:{input:r}});t?.dispatchEvent(i)};return ht(()=>{n(e.value)}),[(()=>{const r=Za.cloneNode(!0);return x(r,Je),r})(),(()=>{const r=Za.cloneNode(!0);return x(r,Xt),r})(),(()=>{const r=Za.cloneNode(!0);return x(r,Yt),r})(),(()=>{const r=Za.cloneNode(!0);return x(r,rq),r})(),(()=>{const r=H(()=>document.importNode(iq,!0)),i=r.firstChild,o=i.firstChild,a=t;return typeof a=="function"?he(a,r):t=r,x(r,(()=>{const s=se(()=>!!e.label);return()=>s()?(()=>{const c=oq.cloneNode(!0),l=c.firstChild;return x(l,()=>e.label),x(c,(()=>{const u=se(()=>!!e.required);return()=>u()?aq.cloneNode(!0):null})(),null),c})():null})(),i),i.addEventListener("sl-input",s=>{n(s.target.value)}),i.addEventListener("wheel",s=>{s.preventDefault(),s.stopPropagation(),s.stopImmediatePropagation()}),i._$owner=A(),x(o,()=>e.helpText),q(s=>{const c=!!e.invalid,l=e.disabled,u=e.min,d=e.max,f=e.invalid;return c!==s._v$&&i.classList.toggle("invalid",s._v$=c),l!==s._v$2&&(i.disabled=s._v$2=l),u!==s._v$3&&(i.min=s._v$3=u),d!==s._v$4&&(i.max=s._v$4=d),f!==s._v$5&&(i.invalid=s._v$5=f),s},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0,_v$5:void 0}),q(()=>i.value=e.value),r})()]});const sq=()=>{const[e,t]=kr({dispenseUnits:{data:[],errors:[],isLoading:!1}});return{store:e,actions:{getDispenseUnits:async r=>{t("dispenseUnits",{...e.dispenseUnits,isLoading:!0});const{data:i,errors:o}=await r.clinical.prescription.getDispenseUnits();t("dispenseUnits",{...e.dispenseUnits,isLoading:!1,data:i.dispenseUnits.map((a,s)=>({id:s.toString(),...a})),errors:o})}}}},lq=sq(),cq=N("<div></div>");Me("photon-dispense-units",{label:void 0,required:!1,invalid:!1,helpText:void 0,formName:void 0,disabled:!1,forceLabelSize:!1,selected:void 0},e=>{let t;const n=pt(),{store:r,actions:i}=lq,[o,a]=V(""),s=l=>{const u=new CustomEvent("photon-dispense-unit-selected",{composed:!0,bubbles:!0,detail:{dispenseUnit:{name:l.name}}});t?.dispatchEvent(u)};ht(async()=>{await i.getDispenseUnits(n.getSDK())});const c=l=>{if(r.dispenseUnits.data.length>0){const u=r.dispenseUnits.data;return l.length===0?u:u.filter(d=>d.name.toLowerCase().includes(l.toLowerCase()))}return[]};return(()=>{const l=cq.cloneNode(!0),u=t;return typeof u=="function"?he(u,l):t=l,l.addEventListener("photon-data-selected",d=>{s(d.detail.data)}),x(l,S(wn,{get data(){return c(o())},get label(){return e.label},get disabled(){return e.disabled},get required(){return e.required},get forceLabelSize(){return e.forceLabelSize},placeholder:"Select a dispense unit...",get invalid(){return e.invalid},get isLoading(){return n?.clinical.dispenseUnits.state.isLoading||!1},hasMore:!1,get selectedData(){return se(()=>!!e.selected)()?r.dispenseUnits.data?.filter(d=>d.name===e.selected)[0]:r.dispenseUnits.data?.[0]},displayAccessor:d=>d?.name||"",onSearchChange:async d=>{a(d)},onHide:async()=>{a("")},noDataMsg:"No dispense units found",get helpText(){return e.helpText}})),l})()});var uq=_t`
|
|
3181
3181
|
${At}
|
|
3182
3182
|
${H3}
|
|
3183
3183
|
|
|
@@ -3400,9 +3400,9 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
3400
3400
|
${this.helpText}
|
|
3401
3401
|
</slot>
|
|
3402
3402
|
</div>
|
|
3403
|
-
`}};Ee.styles=
|
|
3404
|
-
`,Ja=
|
|
3405
|
-
`,es=
|
|
3403
|
+
`}};Ee.styles=uq;w([rt(".textarea__control")],Ee.prototype,"input",2);w([Dn()],Ee.prototype,"hasFocus",2);w([E()],Ee.prototype,"title",2);w([E()],Ee.prototype,"name",2);w([E()],Ee.prototype,"value",2);w([E({reflect:!0})],Ee.prototype,"size",2);w([E({type:Boolean,reflect:!0})],Ee.prototype,"filled",2);w([E()],Ee.prototype,"label",2);w([E({attribute:"help-text"})],Ee.prototype,"helpText",2);w([E()],Ee.prototype,"placeholder",2);w([E({type:Number})],Ee.prototype,"rows",2);w([E()],Ee.prototype,"resize",2);w([E({type:Boolean,reflect:!0})],Ee.prototype,"disabled",2);w([E({type:Boolean,reflect:!0})],Ee.prototype,"readonly",2);w([E({reflect:!0})],Ee.prototype,"form",2);w([E({type:Boolean,reflect:!0})],Ee.prototype,"required",2);w([E({type:Number})],Ee.prototype,"minlength",2);w([E({type:Number})],Ee.prototype,"maxlength",2);w([E()],Ee.prototype,"autocapitalize",2);w([E()],Ee.prototype,"autocorrect",2);w([E()],Ee.prototype,"autocomplete",2);w([E({type:Boolean})],Ee.prototype,"autofocus",2);w([E()],Ee.prototype,"enterkeyhint",2);w([E({type:Boolean,converter:{fromAttribute:e=>!(!e||e==="false"),toAttribute:e=>e?"true":"false"}})],Ee.prototype,"spellcheck",2);w([E()],Ee.prototype,"inputmode",2);w([Wc()],Ee.prototype,"defaultValue",2);w([Ve("disabled",{waitUntilFirstUpdate:!0})],Ee.prototype,"handleDisabledChange",1);w([Ve("rows",{waitUntilFirstUpdate:!0})],Ee.prototype,"handleRowsChange",1);w([Ve("value",{waitUntilFirstUpdate:!0})],Ee.prototype,"handleValueChange",1);Ee=w([It("sl-textarea")],Ee);const dq=`.input::part(base){border-radius:var(--photon-border-radius, .5rem)}.invalid::part(base){--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity));border-width:2px}.invalid::part(form-control-help-text){--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}
|
|
3404
|
+
`,Ja=N("<style></style>"),fq=N('<div class="sm:py-2 flex flex-col"><sl-textarea class="input"><p slot="help-text" class="text-red-500 pt-1 h-[21px] font-sans"></p></sl-textarea></div>'),hq=N('<div class="flex items-center pb-2 font-sans"><p class="text-gray-700 text-sm"></p></div>'),pq=N('<p class="pl-1 text-red-500">*</p>'),mq=N('<p class="text-gray-400 text-xs pl-2">Optional</p>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-textarea",{label:void 0,required:!1,placeholder:void 0,value:void 0,formName:void 0,helpText:void 0,invalid:!1,disabled:!1},e=>{let t;const n=r=>{const i=new CustomEvent("photon-textarea-changed",{composed:!0,bubbles:!0,detail:{value:r}});t?.dispatchEvent(i)};return ht(()=>{n(e.value??"")}),[(()=>{const r=Ja.cloneNode(!0);return x(r,Je),r})(),(()=>{const r=Ja.cloneNode(!0);return x(r,Xt),r})(),(()=>{const r=Ja.cloneNode(!0);return x(r,Yt),r})(),(()=>{const r=Ja.cloneNode(!0);return x(r,dq),r})(),(()=>{const r=H(()=>document.importNode(fq,!0)),i=r.firstChild,o=i.firstChild,a=t;return typeof a=="function"?he(a,r):t=r,x(r,(()=>{const s=se(()=>!!e.label);return()=>s()?(()=>{const c=hq.cloneNode(!0),l=c.firstChild;return x(l,()=>e.label),x(c,(()=>{const u=se(()=>!!e.required);return()=>u()?pq.cloneNode(!0):null})(),null),x(c,(()=>{const u=se(()=>!e.required);return()=>u()?mq.cloneNode(!0):null})(),null),c})():null})(),i),i.addEventListener("sl-input",s=>{n(s.target.value)}),i._$owner=A(),x(o,()=>e.helpText),q(s=>{const c=!!e.invalid,l=e.disabled,u=e.invalid,d=e.placeholder;return c!==s._v$&&i.classList.toggle("invalid",s._v$=c),l!==s._v$2&&(i.disabled=s._v$2=l),u!==s._v$3&&(i.invalid=s._v$3=u),d!==s._v$4&&(i.placeholder=s._v$4=d),s},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0}),q(()=>i.value=e.value?e.value:""),r})()]});const vq=`.button{border-radius:var(--photon-border-radius, .375rem);--tw-text-opacity: 1;color:rgb(209 213 219/var(--tw-text-opacity))}.button:disabled{cursor:not-allowed}.button--solid{--tw-bg-opacity: 1;background-color:rgb(49 130 206/var(--tw-bg-opacity))}.button--solid:hover:disabled{background-color:#3182ce99}.button--solid:disabled{background-color:#3182ce99}.button--solid{--tw-text-opacity: 1;color:rgb(255 255 255/var(--tw-text-opacity))}.button--solid:hover{--tw-bg-opacity: 1;background-color:rgb(43 108 176/var(--tw-bg-opacity))}.button--outline{--tw-text-opacity: 1;color:rgb(49 130 206/var(--tw-text-opacity))}.button--outline:disabled{color:#3182ce99}.button--outline{border-width:1px}.button--outline:disabled{border-color:#3182ce99}.button--outline{--tw-border-opacity: 1;border-color:rgb(49 130 206/var(--tw-border-opacity))}.button--outline:hover{background-color:#3182ce33}.button--xs{height:1.5rem;padding-left:.5rem;padding-right:.5rem;font-size:.875rem;line-height:1.25rem}.button--sm{height:2rem;padding-left:.625rem;padding-right:.625rem;font-size:.875rem;line-height:1.25rem}.button--md{height:2.5rem;padding-left:1rem;padding-right:1rem}.button--lg{height:3rem;padding-left:1.5rem;padding-right:1.5rem;font-size:1.125rem;line-height:1.75rem}.spinner--solid{--indicator-color: white;--track-color: none}.spinner--outline{--indicator-color: rgb(49 130 206 / .6);--track-color: none}
|
|
3405
|
+
`,es=N("<style></style>"),gq=N('<button class="rounded-lg font-sans transition ease-in-out delay-50 flex items-center gap-1 lg:gap-2"><slot name="suffix"></slot><p><slot></slot></p><slot name="postfix"></slot></button>'),yq=N('<div class="pt-[3px]"><sl-spinner class="w-[16px]"></sl-spinner></div>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-button",{disabled:!1,loading:!1,loadingText:void 0,full:!1,variant:"solid",size:"md"},e=>{let t;const n=()=>{const i=new CustomEvent("photon-clicked",{composed:!0,bubbles:!0,detail:{}});t?.dispatchEvent(i)};let r="text-sm lg:text-base";return e.size==="lg"&&(r="text-base lg:text-lg"),e.size==="sm"&&(r="text-xs lg:text-sm"),e.size==="xs"&&(r="text-xs"),[(()=>{const i=es.cloneNode(!0);return x(i,Je),i})(),(()=>{const i=es.cloneNode(!0);return x(i,Xt),i})(),(()=>{const i=es.cloneNode(!0);return x(i,Yt),i})(),(()=>{const i=es.cloneNode(!0);return x(i,vq),i})(),(()=>{const i=gq.cloneNode(!0),o=i.firstChild,a=o.nextSibling,s=a.firstChild,c=a.nextSibling;i.$$click=()=>n();const l=t;return typeof l=="function"?he(l,i):t=i,o._$owner=A(),x(i,(()=>{const u=se(()=>!!e.loading);return()=>u()?(()=>{const d=H(()=>document.importNode(yq,!0)),f=d.firstChild;return f._$owner=A(),q(h=>{const p=e.variant==="solid",m=e.variant==="outline";return p!==h._v$3&&f.classList.toggle("spinner--solid",h._v$3=p),m!==h._v$4&&f.classList.toggle("spinner--outline",h._v$4=m),h},{_v$3:void 0,_v$4:void 0}),d})():null})(),a),cl(a,`w-full ${r}`),s._$owner=A(),c._$owner=A(),q(u=>{const d=e.disabled||e.loading,f={button:!0,"button--solid":e.variant==="solid","button--outline":e.variant==="outline","button--lg":e.size=="lg","button--md":e.size=="md","button--sm":e.size=="sm","button--xs":e.size=="xs","xs:w-fit":!0,"w-full":!0};return d!==u._v$&&(i.disabled=u._v$=d),u._v$2=w4(i,f,u._v$2),u},{_v$:void 0,_v$2:void 0}),i})()]});Yi(["click"]);const bq=_a`
|
|
3406
3406
|
fragment PatientPharmacyFields on Patient {
|
|
3407
3407
|
preferredPharmacies {
|
|
3408
3408
|
id
|
|
@@ -3418,8 +3418,8 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
3418
3418
|
phone
|
|
3419
3419
|
}
|
|
3420
3420
|
}
|
|
3421
|
-
|
|
3422
|
-
`,ts=
|
|
3421
|
+
`,$q=()=>{const[e,t]=kr({pharmacies:{data:[],address:void 0,errors:[],isLoading:!1},selectedPharmacy:{data:void 0,errors:[],isLoading:!1},preferredPharmacies:{data:void 0,errors:[],isLoading:!1}}),n=async(l,u,d,f)=>{try{const h=await u.geocode({address:d}),p=h.results[0].geometry.location.lat(),m=h.results[0].geometry.location.lng(),v=h.results[0].formatted_address;if(v&&t("pharmacies",{...e.pharmacies,address:v,errors:[]}),!p||!m){t("pharmacies",{...e.pharmacies,errors:[new Error("An unexpected error occured")]});return}await r(l,{name:f,location:{latitude:p,longitude:m,radius:20}})}catch(h){console.log("ERR",h),t("pharmacies",{...e.pharmacies,errors:[new Error("The provided address seems invalid. Please revise and try again.")]})}},r=async(l,u)=>{t("pharmacies",{...e.pharmacies,isLoading:!0});const{data:d,errors:f}=await l.clinical.pharmacy.getPharmacies({name:u.name,location:u.location,first:u.first,type:"PICK_UP"});t("pharmacies",{...e.pharmacies,isLoading:!1,data:d.pharmacies,errors:f})};return{store:e,actions:{getPharmacies:r,getPharmaciesByAddress:n,getPharmacy:async(l,u)=>{t("selectedPharmacy",{...e.selectedPharmacy,isLoading:!0});const{data:d,errors:f}=await l.clinical.pharmacy.getPharmacy({id:u});(e.pharmacies.errors||[]).filter(h=>h.message.includes("seems invalid")||h.message.includes("unexpected error")).length>0&&t("pharmacies",{...e.pharmacies,errors:[]}),t("selectedPharmacy",{...e.selectedPharmacy,isLoading:!1,data:d.pharmacy,errors:f})},clearSelectedPharmacy:()=>{t("selectedPharmacy",{...e.selectedPharmacy,data:void 0,errors:[]})},getPreferredPharmacies:async(l,u)=>{t("preferredPharmacies",{...e.preferredPharmacies,isLoading:!0});const{data:d,errors:f}=await l.clinical.patient.getPatient({id:u,fragment:{PatientPharmacyFields:bq}});t("preferredPharmacies",{...e.selectedPharmacy,isLoading:!1,data:d.patient.preferredPharmacies?.map(h=>h),errors:f})},clearPreferredPharmacies:()=>{t("preferredPharmacies",{...e.selectedPharmacy,data:[],errors:[]})},reset:async()=>{t("pharmacies",{data:[],errors:[],address:void 0,isLoading:!1}),t("selectedPharmacy",{data:void 0,errors:[],isLoading:!1}),t("preferredPharmacies",{data:void 0,errors:[],isLoading:!1})}}}},Lb=$q(),wq=N('<div class="flex flex-row gap-4 items-start"><div class="flex flex-col font-sans text-sm"><p class=" text-gray-500">Showing pharmacies near</p><p></p></div><photon-button class="self-end" variant="outline" size="xs">Change</photon-button></div>'),_q=N('<div class="flex flex-row gap-4 items-center"><div class="flex flex-col font-sans text-sm"><p class=" text-gray-500">Showing preferred pharmacy</p></div><photon-button variant="outline" size="xs">Change</photon-button></div>'),xq=N('<photon-text-input debounce-time="800" label="Enter an address or zip code"></photon-text-input>'),kq=N('<div class="flex flex-col gap-2"></div>');Me("photon-pharmacy-search",{label:void 0,required:!1,invalid:!1,helpText:void 0,selected:"",formName:void 0,disabled:!1,forceLabelSize:!1,address:"",patientId:void 0,geocodingApiKey:"AIzaSyAvuwwE6g2Bsmih66nu4dB7-H7U1_7KQ6g"},e=>{let t;const n=pt();let r;const{store:i,actions:o}=Lb,[a,s]=V(!1),[c,l]=V(""),[u,d]=V(""),[f,h]=V(""),p=b=>{const y=new CustomEvent("photon-pharmacy-selected",{composed:!0,bubbles:!0,detail:{pharmacy:b}});t?.dispatchEvent(y)},m=()=>{const b=new CustomEvent("photon-pharmacy-removed",{composed:!0,bubbles:!0,detail:{}});t?.dispatchEvent(b)},v=se(()=>{const b=i.pharmacies.data.filter(y=>!(i.preferredPharmacies.data??[]).map(g=>g.id).includes(y.id)).filter(y=>y.name.toLowerCase().includes(f().toLowerCase()));return i.selectedPharmacy.data&&u()?[i.selectedPharmacy.data,...(i.preferredPharmacies.data??[]).filter(y=>y.id!=i.selectedPharmacy.data?.id),...b]:[...i.preferredPharmacies.data??[],...b]});return ht(async()=>{const b=document.createElement("script");b.src=`https://maps.googleapis.com/maps/api/js?key=${e.geocodingApiKey}`,document.head.appendChild(b),b.onload=async()=>{r=new google.maps.Geocoder,l(e.address),d(e.selected),e.patientId&&await o.getPreferredPharmacies(n.getSDK(),e.patientId),e.address&&await o.getPharmaciesByAddress(n.getSDK(),r,String(e.address)),e.selected&&await o.getPharmacy(n.getSDK(),e.selected),!e.address&&!e.selected&&s(!0)},b.onerror=y=>{console.error("Error loading Google Maps Geocoding API: ",y)}}),me(()=>{l(e.address),d(e.selected),!e.selected&&!e.address?s(!0):s(!1),e.selected&&H(async()=>{await o.getPharmacy(n.getSDK(),e.selected)}),e.address&&!e.selected&&H(async()=>{o.clearSelectedPharmacy(),await o.getPharmaciesByAddress(n.getSDK(),r,e.address)})}),(()=>{const b=kq.cloneNode(!0),y=t;return typeof y=="function"?he(y,b):t=b,b.addEventListener("photon-data-selected",g=>{p(g.detail.data)}),x(b,S(ee,{get when(){return c()&&!a()&&(i.pharmacies.errors||[]).length==0},get children(){const g=H(()=>document.importNode(wq,!0)),_=g.firstChild,k=_.firstChild,O=k.nextSibling,C=_.nextSibling;return x(O,()=>i.pharmacies.address),C.addEventListener("photon-clicked",()=>{s(!0)}),C._$owner=A(),g}}),null),x(b,S(ee,{get when(){return u()&&!c()&&!a()&&(i.pharmacies.errors||[]).length==0},get children(){const g=H(()=>document.importNode(_q,!0)),_=g.firstChild,k=_.nextSibling;return k.addEventListener("photon-clicked",()=>{m(),s(!0)}),k._$owner=A(),g}}),null),x(b,S(ee,{get when(){return a()||(i.pharmacies.errors||[]).filter(g=>g.message.includes("seems invalid")||g.message.includes("unexpected error")).length>0},get children(){const g=H(()=>document.importNode(xq,!0));return g.addEventListener("photon-input-changed",async _=>{await o.getPharmaciesByAddress(n.getSDK(),r,_.detail.input),l(_.detail.input),d(""),o.clearSelectedPharmacy(),s(!1)}),g._$owner=A(),q(_=>{const k=e.invalid||(i.pharmacies.errors||[]).length>0,O=(i.pharmacies.errors||[]).length>0?i.pharmacies.errors[0].message:e.helpText;return k!==_._v$&&(g.invalid=_._v$=k),O!==_._v$2&&(g.helpText=_._v$2=O),_},{_v$:void 0,_v$2:void 0}),g}}),null),x(b,S(ee,{get when(){return se(()=>!!((c()||u())&&!a()))()&&(i.pharmacies.errors||[]).filter(g=>g.message.includes("seems invalid")||g.message.includes("unexpected error")).length==0},get children(){return S(wn,{get data(){return v()},get groups(){return[...f()===""?[{label:"Preferred Pharmacy",filter:g=>g?(i.preferredPharmacies.data??[]).map(_=>_.id).includes(g.id):!1}]:[],{label:"Pharmacies",filter:g=>g?!(i.preferredPharmacies.data??[]).map(_=>_.id).includes(g.id):!1}]},get label(){return e.label},get forceLabelSize(){return e.forceLabelSize},get required(){return e.required},get disabled(){return e.disabled},placeholder:"Select a pharmacy...",get invalid(){return e.invalid||(i.pharmacies.errors||[]).length>0},get isLoading(){return i.pharmacies.isLoading||i.selectedPharmacy.isLoading},hasMore:!1,displayAccessor:g=>`${g?.name||""}, ${R1(g?.address?.street1||"")}, ${R1(g?.address?.city||"")}, ${g?.address?.state||""}`,showOverflow:!0,onSearchChange:async g=>{h(g)},onOpen:async()=>{i.pharmacies.data.length==0&&c()&&r&&await o.getPharmaciesByAddress(n.getSDK(),r,c())},noDataMsg:"No pharmacies found",get helpText(){return(i.pharmacies.errors||[]).length>0?i.pharmacies.errors[0].message:e.helpText},get selectedData(){return u()?i.selectedPharmacy.data:e.patientId?i.preferredPharmacies.data?.[0]:void 0}})}}),null),b})()});const Eq=`.input::part(base){border-radius:var(--photon-border-radius, .5rem)}.invalid::part(base){--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity));border-width:2px}.invalid::part(form-control-help-text){--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}
|
|
3422
|
+
`,ts=N("<style></style>"),Sq=N('<div class="flex flex-col font-sans"><sl-input class="input" type="text"><p slot="help-text" class="text-red-500 pt-1 h-[21px] font-sans"></p></sl-input></div>'),Oq=N('<div class="flex items-center pb-2"><p class="text-gray-700 text-sm"></p></div>'),Cq=N('<p class="pl-1 text-red-500">*</p>'),Nq=N('<p class="text-gray-400 text-xs pl-2 font-sans">Optional</p>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-text-input",{label:void 0,required:!1,value:void 0,formName:void 0,invalid:!1,helpText:void 0,disabled:!1,debounceTime:250,dispatchOnMount:!1,optional:!1},e=>{let t;const n=i=>{const o=new CustomEvent("photon-input-changed",{composed:!0,bubbles:!0,detail:{input:i}});t?.dispatchEvent(o)},r=$3(i=>n(i),e.debounceTime);return ht(()=>{e.dispatchOnMount&&n(e.value??"")}),[(()=>{const i=ts.cloneNode(!0);return x(i,Je),i})(),(()=>{const i=ts.cloneNode(!0);return x(i,Xt),i})(),(()=>{const i=ts.cloneNode(!0);return x(i,Yt),i})(),(()=>{const i=ts.cloneNode(!0);return x(i,Eq),i})(),(()=>{const i=H(()=>document.importNode(Sq,!0)),o=i.firstChild,a=o.firstChild,s=t;return typeof s=="function"?he(s,i):t=i,x(i,(()=>{const c=se(()=>!!e.label);return()=>c()?(()=>{const l=Oq.cloneNode(!0),u=l.firstChild;return x(u,()=>e.label),x(l,(()=>{const d=se(()=>!!e.required);return()=>d()?Cq.cloneNode(!0):null})(),null),x(l,(()=>{const d=se(()=>!!e.optional);return()=>d()?Nq.cloneNode(!0):null})(),null),l})():null})(),o),o.addEventListener("sl-input",c=>{r(c.target.value)}),o._$owner=A(),x(a,()=>e.helpText),q(c=>{const l=!!e.invalid,u=e.disabled,d=e.invalid;return l!==c._v$&&o.classList.toggle("invalid",c._v$=l),u!==c._v$2&&(o.disabled=c._v$2=u),d!==c._v$3&&(o.invalid=c._v$3=d),c},{_v$:void 0,_v$2:void 0,_v$3:void 0}),q(()=>o.value=e.value||""),i})()]});var Io=[],Tq=class{constructor(e){this.tabDirection="forward",this.element=e,this.handleFocusIn=this.handleFocusIn.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleKeyUp=this.handleKeyUp.bind(this)}activate(){Io.push(this.element),document.addEventListener("focusin",this.handleFocusIn),document.addEventListener("keydown",this.handleKeyDown),document.addEventListener("keyup",this.handleKeyUp)}deactivate(){Io=Io.filter(e=>e!==this.element),document.removeEventListener("focusin",this.handleFocusIn),document.removeEventListener("keydown",this.handleKeyDown),document.removeEventListener("keyup",this.handleKeyUp)}isActive(){return Io[Io.length-1]===this.element}checkFocus(){if(this.isActive()&&!this.element.matches(":focus-within")){const{start:e,end:t}=S3(this.element),n=this.tabDirection==="forward"?e:t;typeof n?.focus=="function"&&n.focus({preventScroll:!0})}}handleFocusIn(){this.checkFocus()}handleKeyDown(e){e.key==="Tab"&&e.shiftKey&&(this.tabDirection="backward",requestAnimationFrame(()=>this.checkFocus()))}handleKeyUp(){this.tabDirection="forward"}},Yf=new Set;function Pq(){const e=document.documentElement.clientWidth;return Math.abs(window.innerWidth-e)}function mv(e){if(Yf.add(e),!document.body.classList.contains("sl-scroll-lock")){const t=Pq();document.body.classList.add("sl-scroll-lock"),document.body.style.setProperty("--sl-scroll-lock-size",`${t}px`)}}function vv(e){Yf.delete(e),Yf.size===0&&(document.body.classList.remove("sl-scroll-lock"),document.body.style.removeProperty("--sl-scroll-lock-size"))}var Aq=_t`
|
|
3423
3423
|
${At}
|
|
3424
3424
|
|
|
3425
3425
|
:host {
|
|
@@ -3538,7 +3538,7 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
3538
3538
|
border: solid 1px var(--sl-color-neutral-0);
|
|
3539
3539
|
}
|
|
3540
3540
|
}
|
|
3541
|
-
`,An=class extends xt{constructor(){super(...arguments),this.hasSlotController=new ka(this,"footer"),this.localize=new ni(this),this.open=!1,this.label="",this.noHeader=!1}connectedCallback(){super.connectedCallback(),this.handleDocumentKeyDown=this.handleDocumentKeyDown.bind(this),this.modal=new
|
|
3541
|
+
`,An=class extends xt{constructor(){super(...arguments),this.hasSlotController=new ka(this,"footer"),this.localize=new ni(this),this.open=!1,this.label="",this.noHeader=!1}connectedCallback(){super.connectedCallback(),this.handleDocumentKeyDown=this.handleDocumentKeyDown.bind(this),this.modal=new Tq(this)}firstUpdated(){this.dialog.hidden=!this.open,this.open&&(this.addOpenListeners(),this.modal.activate(),mv(this))}disconnectedCallback(){super.disconnectedCallback(),vv(this)}requestClose(e){if(this.emit("sl-request-close",{cancelable:!0,detail:{source:e}}).defaultPrevented){const n=un(this,"dialog.denyClose",{dir:this.localize.dir()});dn(this.panel,n.keyframes,n.options);return}this.hide()}addOpenListeners(){document.addEventListener("keydown",this.handleDocumentKeyDown)}removeOpenListeners(){document.removeEventListener("keydown",this.handleDocumentKeyDown)}handleDocumentKeyDown(e){this.open&&e.key==="Escape"&&(e.stopPropagation(),this.requestClose("keyboard"))}async handleOpenChange(){if(this.open){this.emit("sl-show"),this.addOpenListeners(),this.originalTrigger=document.activeElement,this.modal.activate(),mv(this);const e=this.querySelector("[autofocus]");e&&e.removeAttribute("autofocus"),await Promise.all([On(this.dialog),On(this.overlay)]),this.dialog.hidden=!1,requestAnimationFrame(()=>{this.emit("sl-initial-focus",{cancelable:!0}).defaultPrevented||(e?e.focus({preventScroll:!0}):this.panel.focus({preventScroll:!0})),e&&e.setAttribute("autofocus","")});const t=un(this,"dialog.show",{dir:this.localize.dir()}),n=un(this,"dialog.overlay.show",{dir:this.localize.dir()});await Promise.all([dn(this.panel,t.keyframes,t.options),dn(this.overlay,n.keyframes,n.options)]),this.emit("sl-after-show")}else{this.emit("sl-hide"),this.removeOpenListeners(),this.modal.deactivate(),await Promise.all([On(this.dialog),On(this.overlay)]);const e=un(this,"dialog.hide",{dir:this.localize.dir()}),t=un(this,"dialog.overlay.hide",{dir:this.localize.dir()});await Promise.all([dn(this.overlay,t.keyframes,t.options).then(()=>{this.overlay.hidden=!0}),dn(this.panel,e.keyframes,e.options).then(()=>{this.panel.hidden=!0})]),this.dialog.hidden=!0,this.overlay.hidden=!1,this.panel.hidden=!1,vv(this);const n=this.originalTrigger;typeof n?.focus=="function"&&setTimeout(()=>n.focus()),this.emit("sl-after-hide")}}async show(){if(!this.open)return this.open=!0,$r(this,"sl-after-show")}async hide(){if(!!this.open)return this.open=!1,$r(this,"sl-after-hide")}render(){return We`
|
|
3542
3542
|
<div
|
|
3543
3543
|
part="base"
|
|
3544
3544
|
class=${zt({dialog:!0,"dialog--open":this.open,"dialog--has-footer":this.hasSlotController.test("footer")})}
|
|
@@ -3582,28 +3582,28 @@ this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):a
|
|
|
3582
3582
|
</footer>
|
|
3583
3583
|
</div>
|
|
3584
3584
|
</div>
|
|
3585
|
-
`}};An.styles=
|
|
3586
|
-
`,ns=T("<style></style>"),Iq=T('<slot name="label"><p class="text-xl font-sans font-medium"></p></slot>'),Mq=T('<sl-dialog class="dialog"><div><slot></slot></div><div class="flex flex-col xs:flex-row justify-end gap-2" slot="footer"><photon-button variant="outline"></photon-button><photon-button></photon-button></div></sl-dialog>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-dialog",{label:void 0,header:!0,open:!1,confirmText:"Yes, Cancel",cancelText:"No, Keep Editing",disableButtons:!1,loading:!1,hideFooter:!1,disableSubmit:!1,width:"500px",overlayClose:!1},e=>{let t;const n=r=>{const i=new CustomEvent(r?"photon-dialog-confirmed":"photon-dialog-canceled",{composed:!0,bubbles:!0,detail:{}});t?.dispatchEvent(i)};return[(()=>{const r=ns.cloneNode(!0);return k(r,Je),r})(),(()=>{const r=ns.cloneNode(!0);return k(r,Xt),r})(),(()=>{const r=ns.cloneNode(!0);return k(r,Yt),r})(),(()=>{const r=ns.cloneNode(!0);return k(r,Aq),r})(),(()=>{const r=H(()=>document.importNode(Mq,!0)),i=r.firstChild,o=i.firstChild,a=i.nextSibling,s=a.firstChild,c=s.nextSibling,l=t;return typeof l=="function"?he(l,r):t=r,r.addEventListener("sl-request-close",u=>{u.detail.source==="overlay"&&!e.overlayClose||u.detail.source==="keyboard"?u.preventDefault():n(!1)}),r._$owner=A(),k(r,S(ee,{get when(){return!e.header},get children(){const u=Iq.cloneNode(!0),d=u.firstChild;return u._$owner=A(),k(d,()=>e.label),u}}),i),o._$owner=A(),s.addEventListener("photon-clicked",()=>{n(!1)}),s._$owner=A(),k(s,()=>e.cancelText),c.addEventListener("photon-clicked",()=>{n(!0)}),c._$owner=A(),k(c,()=>e.confirmText),q(u=>{const d=!!e.hideFooter,f=!!e.header,h=`--width: ${e.width};`,p=e.label,m=e.open,v=!e.header,b=`font-sans ${e.header?"pb-4":"py-4"}`,y=!!e.hideFooter,g=e.disableButtons||e.loading,_=e.disableButtons||e.disableSubmit,x=e.loading;return d!==u._v$&&r.classList.toggle("hideFooter",u._v$=d),f!==u._v$2&&r.classList.toggle("showHeader",u._v$2=f),u._v$3=_4(r,h,u._v$3),p!==u._v$4&&(r.label=u._v$4=p),m!==u._v$5&&(r.open=u._v$5=m),v!==u._v$6&&(r.noHeader=u._v$6=v),b!==u._v$7&&cl(i,u._v$7=b),y!==u._v$8&&a.classList.toggle("hidden",u._v$8=y),g!==u._v$9&&(s.disabled=u._v$9=g),_!==u._v$10&&(c.disabled=u._v$10=_),x!==u._v$11&&(c.loading=u._v$11=x),u},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0,_v$5:void 0,_v$6:void 0,_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0,_v$11:void 0}),r})()]});const Rb={version:4,country_calling_codes:{1:["US","AG","AI","AS","BB","BM","BS","CA","DM","DO","GD","GU","JM","KN","KY","LC","MP","MS","PR","SX","TC","TT","VC","VG","VI"],7:["RU","KZ"],20:["EG"],27:["ZA"],30:["GR"],31:["NL"],32:["BE"],33:["FR"],34:["ES"],36:["HU"],39:["IT","VA"],40:["RO"],41:["CH"],43:["AT"],44:["GB","GG","IM","JE"],45:["DK"],46:["SE"],47:["NO","SJ"],48:["PL"],49:["DE"],51:["PE"],52:["MX"],53:["CU"],54:["AR"],55:["BR"],56:["CL"],57:["CO"],58:["VE"],60:["MY"],61:["AU","CC","CX"],62:["ID"],63:["PH"],64:["NZ"],65:["SG"],66:["TH"],81:["JP"],82:["KR"],84:["VN"],86:["CN"],90:["TR"],91:["IN"],92:["PK"],93:["AF"],94:["LK"],95:["MM"],98:["IR"],211:["SS"],212:["MA","EH"],213:["DZ"],216:["TN"],218:["LY"],220:["GM"],221:["SN"],222:["MR"],223:["ML"],224:["GN"],225:["CI"],226:["BF"],227:["NE"],228:["TG"],229:["BJ"],230:["MU"],231:["LR"],232:["SL"],233:["GH"],234:["NG"],235:["TD"],236:["CF"],237:["CM"],238:["CV"],239:["ST"],240:["GQ"],241:["GA"],242:["CG"],243:["CD"],244:["AO"],245:["GW"],246:["IO"],247:["AC"],248:["SC"],249:["SD"],250:["RW"],251:["ET"],252:["SO"],253:["DJ"],254:["KE"],255:["TZ"],256:["UG"],257:["BI"],258:["MZ"],260:["ZM"],261:["MG"],262:["RE","YT"],263:["ZW"],264:["NA"],265:["MW"],266:["LS"],267:["BW"],268:["SZ"],269:["KM"],290:["SH","TA"],291:["ER"],297:["AW"],298:["FO"],299:["GL"],350:["GI"],351:["PT"],352:["LU"],353:["IE"],354:["IS"],355:["AL"],356:["MT"],357:["CY"],358:["FI","AX"],359:["BG"],370:["LT"],371:["LV"],372:["EE"],373:["MD"],374:["AM"],375:["BY"],376:["AD"],377:["MC"],378:["SM"],380:["UA"],381:["RS"],382:["ME"],383:["XK"],385:["HR"],386:["SI"],387:["BA"],389:["MK"],420:["CZ"],421:["SK"],423:["LI"],500:["FK"],501:["BZ"],502:["GT"],503:["SV"],504:["HN"],505:["NI"],506:["CR"],507:["PA"],508:["PM"],509:["HT"],590:["GP","BL","MF"],591:["BO"],592:["GY"],593:["EC"],594:["GF"],595:["PY"],596:["MQ"],597:["SR"],598:["UY"],599:["CW","BQ"],670:["TL"],672:["NF"],673:["BN"],674:["NR"],675:["PG"],676:["TO"],677:["SB"],678:["VU"],679:["FJ"],680:["PW"],681:["WF"],682:["CK"],683:["NU"],685:["WS"],686:["KI"],687:["NC"],688:["TV"],689:["PF"],690:["TK"],691:["FM"],692:["MH"],850:["KP"],852:["HK"],853:["MO"],855:["KH"],856:["LA"],880:["BD"],886:["TW"],960:["MV"],961:["LB"],962:["JO"],963:["SY"],964:["IQ"],965:["KW"],966:["SA"],967:["YE"],968:["OM"],970:["PS"],971:["AE"],972:["IL"],973:["BH"],974:["QA"],975:["BT"],976:["MN"],977:["NP"],992:["TJ"],993:["TM"],994:["AZ"],995:["GE"],996:["KG"],998:["UZ"]},countries:{AC:["247","00","(?:[01589]\\d|[46])\\d{4}",[5,6]],AD:["376","00","(?:1|6\\d)\\d{7}|[135-9]\\d{5}",[6,8,9],[["(\\d{3})(\\d{3})","$1 $2",["[135-9]"]],["(\\d{4})(\\d{4})","$1 $2",["1"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6"]]]],AE:["971","00","(?:[4-7]\\d|9[0-689])\\d{7}|800\\d{2,9}|[2-4679]\\d{7}",[5,6,7,8,9,10,11,12],[["(\\d{3})(\\d{2,9})","$1 $2",["60|8"]],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[236]|[479][2-8]"],"0$1"],["(\\d{3})(\\d)(\\d{5})","$1 $2 $3",["[479]"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["5"],"0$1"]],"0"],AF:["93","00","[2-7]\\d{8}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[2-7]"],"0$1"]],"0"],AG:["1","011","(?:268|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([457]\\d{6})$|1","268$1",0,"268"],AI:["1","011","(?:264|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2457]\\d{6})$|1","264$1",0,"264"],AL:["355","00","(?:700\\d\\d|900)\\d{3}|8\\d{5,7}|(?:[2-5]|6\\d)\\d{7}",[6,7,8,9],[["(\\d{3})(\\d{3,4})","$1 $2",["80|9"],"0$1"],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["4[2-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2358][2-5]|4"],"0$1"],["(\\d{3})(\\d{5})","$1 $2",["[23578]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["6"],"0$1"]],"0"],AM:["374","00","(?:[1-489]\\d|55|60|77)\\d{6}",[8],[["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[89]0"],"0 $1"],["(\\d{3})(\\d{5})","$1 $2",["2|3[12]"],"(0$1)"],["(\\d{2})(\\d{6})","$1 $2",["1|47"],"(0$1)"],["(\\d{2})(\\d{6})","$1 $2",["[3-9]"],"0$1"]],"0"],AO:["244","00","[29]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[29]"]]]],AR:["54","00","(?:11|[89]\\d\\d)\\d{8}|[2368]\\d{9}",[10,11],[["(\\d{4})(\\d{2})(\\d{4})","$1 $2-$3",["2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9])","2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8]))|2(?:2[24-9]|3[1-59]|47)","2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5[56][46]|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]","2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|58|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|54(?:4|5[13-7]|6[89])|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:454|85[56])[46]|3(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]"],"0$1",1],["(\\d{2})(\\d{4})(\\d{4})","$1 $2-$3",["1"],"0$1",1],["(\\d{3})(\\d{3})(\\d{4})","$1-$2-$3",["[68]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2-$3",["[23]"],"0$1",1],["(\\d)(\\d{4})(\\d{2})(\\d{4})","$2 15-$3-$4",["9(?:2[2-469]|3[3-578])","9(?:2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9]))","9(?:2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8])))|92(?:2[24-9]|3[1-59]|47)","9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5(?:[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]","9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|5(?:4(?:4|5[13-7]|6[89])|[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]"],"0$1",0,"$1 $2 $3-$4"],["(\\d)(\\d{2})(\\d{4})(\\d{4})","$2 15-$3-$4",["91"],"0$1",0,"$1 $2 $3-$4"],["(\\d{3})(\\d{3})(\\d{5})","$1-$2-$3",["8"],"0$1"],["(\\d)(\\d{3})(\\d{3})(\\d{4})","$2 15-$3-$4",["9"],"0$1",0,"$1 $2 $3-$4"]],"0",0,"0?(?:(11|2(?:2(?:02?|[13]|2[13-79]|4[1-6]|5[2457]|6[124-8]|7[1-4]|8[13-6]|9[1267])|3(?:02?|1[467]|2[03-6]|3[13-8]|[49][2-6]|5[2-8]|[67])|4(?:7[3-578]|9)|6(?:[0136]|2[24-6]|4[6-8]?|5[15-8])|80|9(?:0[1-3]|[19]|2\\d|3[1-6]|4[02568]?|5[2-4]|6[2-46]|72?|8[23]?))|3(?:3(?:2[79]|6|8[2578])|4(?:0[0-24-9]|[12]|3[5-8]?|4[24-7]|5[4-68]?|6[02-9]|7[126]|8[2379]?|9[1-36-8])|5(?:1|2[1245]|3[237]?|4[1-46-9]|6[2-4]|7[1-6]|8[2-5]?)|6[24]|7(?:[069]|1[1568]|2[15]|3[145]|4[13]|5[14-8]|7[2-57]|8[126])|8(?:[01]|2[15-7]|3[2578]?|4[13-6]|5[4-8]?|6[1-357-9]|7[36-8]?|8[5-8]?|9[124])))15)?","9$1"],AS:["1","011","(?:[58]\\d\\d|684|900)\\d{7}",[10],0,"1",0,"([267]\\d{6})$|1","684$1",0,"684"],AT:["43","00","1\\d{3,12}|2\\d{6,12}|43(?:(?:0\\d|5[02-9])\\d{3,9}|2\\d{4,5}|[3467]\\d{4}|8\\d{4,6}|9\\d{4,7})|5\\d{4,12}|8\\d{7,12}|9\\d{8,12}|(?:[367]\\d|4[0-24-9])\\d{4,11}",[4,5,6,7,8,9,10,11,12,13],[["(\\d)(\\d{3,12})","$1 $2",["1(?:11|[2-9])"],"0$1"],["(\\d{3})(\\d{2})","$1 $2",["517"],"0$1"],["(\\d{2})(\\d{3,5})","$1 $2",["5[079]"],"0$1"],["(\\d{3})(\\d{3,10})","$1 $2",["(?:31|4)6|51|6(?:5[0-3579]|[6-9])|7(?:20|32|8)|[89]"],"0$1"],["(\\d{4})(\\d{3,9})","$1 $2",["[2-467]|5[2-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["5"],"0$1"],["(\\d{2})(\\d{4})(\\d{4,7})","$1 $2 $3",["5"],"0$1"]],"0"],AU:["61","001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011","1(?:[0-79]\\d{7}(?:\\d(?:\\d{2})?)?|8[0-24-9]\\d{7})|[2-478]\\d{8}|1\\d{4,7}",[5,6,7,8,9,10,12],[["(\\d{2})(\\d{3,4})","$1 $2",["16"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,4})","$1 $2 $3",["16"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["14|4"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["[2378]"],"(0$1)"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1(?:30|[89])"]]],"0",0,"(183[12])|0",0,0,0,[["(?:(?:2(?:[0-26-9]\\d|3[0-8]|4[02-9]|5[0135-9])|3(?:[0-3589]\\d|4[0-578]|6[1-9]|7[0-35-9])|7(?:[013-57-9]\\d|2[0-8]))\\d{3}|8(?:51(?:0(?:0[03-9]|[12479]\\d|3[2-9]|5[0-8]|6[1-9]|8[0-7])|1(?:[0235689]\\d|1[0-69]|4[0-589]|7[0-47-9])|2(?:0[0-79]|[18][13579]|2[14-9]|3[0-46-9]|[4-6]\\d|7[89]|9[0-4]))|(?:6[0-8]|[78]\\d)\\d{3}|9(?:[02-9]\\d{3}|1(?:(?:[0-58]\\d|6[0135-9])\\d|7(?:0[0-24-9]|[1-9]\\d)|9(?:[0-46-9]\\d|5[0-79])))))\\d{3}",[9]],["4(?:79[01]|83[0-389]|93[0-6])\\d{5}|4(?:[0-3]\\d|4[047-9]|5[0-25-9]|6[016-9]|7[02-8]|8[0-24-9]|9[0-27-9])\\d{6}",[9]],["180(?:0\\d{3}|2)\\d{3}",[7,10]],["190[0-26]\\d{6}",[10]],0,0,0,["163\\d{2,6}",[5,6,7,8,9]],["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}",[9]],["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}",[6,8,10,12]]],"0011"],AW:["297","00","(?:[25-79]\\d\\d|800)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[25-9]"]]]],AX:["358","00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))","2\\d{4,9}|35\\d{4,5}|(?:60\\d\\d|800)\\d{4,6}|7\\d{5,11}|(?:[14]\\d|3[0-46-9]|50)\\d{4,8}",[5,6,7,8,9,10,11,12],0,"0",0,0,0,0,"18",0,"00"],AZ:["994","00","365\\d{6}|(?:[124579]\\d|60|88)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["90"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["1[28]|2|365|46","1[28]|2|365[45]|46","1[28]|2|365(?:4|5[02])|46"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[13-9]"],"0$1"]],"0"],BA:["387","00","6\\d{8}|(?:[35689]\\d|49|70)\\d{6}",[8,9],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["6[1-3]|[7-9]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2-$3",["[3-5]|6[56]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3 $4",["6"],"0$1"]],"0"],BB:["1","011","(?:246|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","246$1",0,"246"],BD:["880","00","[1-469]\\d{9}|8[0-79]\\d{7,8}|[2-79]\\d{8}|[2-9]\\d{7}|[3-9]\\d{6}|[57-9]\\d{5}",[6,7,8,9,10],[["(\\d{2})(\\d{4,6})","$1-$2",["31[5-8]|[459]1"],"0$1"],["(\\d{3})(\\d{3,7})","$1-$2",["3(?:[67]|8[013-9])|4(?:6[168]|7|[89][18])|5(?:6[128]|9)|6(?:28|4[14]|5)|7[2-589]|8(?:0[014-9]|[12])|9[358]|(?:3[2-5]|4[235]|5[2-578]|6[0389]|76|8[3-7]|9[24])1|(?:44|66)[01346-9]"],"0$1"],["(\\d{4})(\\d{3,6})","$1-$2",["[13-9]|22"],"0$1"],["(\\d)(\\d{7,8})","$1-$2",["2"],"0$1"]],"0"],BE:["32","00","4\\d{8}|[1-9]\\d{7}",[8,9],[["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["(?:80|9)0"],"0$1"],["(\\d)(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[239]|4[23]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[15-8]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["4"],"0$1"]],"0"],BF:["226","00","[025-7]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[025-7]"]]]],BG:["359","00","00800\\d{7}|[2-7]\\d{6,7}|[89]\\d{6,8}|2\\d{5}",[6,7,8,9,12],[["(\\d)(\\d)(\\d{2})(\\d{2})","$1 $2 $3 $4",["2"],"0$1"],["(\\d{3})(\\d{4})","$1 $2",["43[1-6]|70[1-9]"],"0$1"],["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,3})","$1 $2 $3",["[356]|4[124-7]|7[1-9]|8[1-6]|9[1-7]"],"0$1"],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["(?:70|8)0"],"0$1"],["(\\d{3})(\\d{3})(\\d{2})","$1 $2 $3",["43[1-7]|7"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[48]|9[08]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["9"],"0$1"]],"0"],BH:["973","00","[136-9]\\d{7}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[13679]|8[047]"]]]],BI:["257","00","(?:[267]\\d|31)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2367]"]]]],BJ:["229","00","[24-689]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[24-689]"]]]],BL:["590","00","590\\d{6}|(?:69|80|9\\d)\\d{7}",[9],0,"0",0,0,0,0,0,[["590(?:2[7-9]|5[12]|87)\\d{4}"],["69(?:0\\d\\d|1(?:2[2-9]|3[0-5]))\\d{4}"],["80[0-5]\\d{6}"],0,0,0,0,0,["9(?:395|76[018])\\d{5}"]]],BM:["1","011","(?:441|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","441$1",0,"441"],BN:["673","00","[2-578]\\d{6}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-578]"]]]],BO:["591","00(?:1\\d)?","(?:[2-467]\\d\\d|8001)\\d{5}",[8,9],[["(\\d)(\\d{7})","$1 $2",["[23]|4[46]"]],["(\\d{8})","$1",["[67]"]],["(\\d{3})(\\d{2})(\\d{4})","$1 $2 $3",["8"]]],"0",0,"0(1\\d)?"],BQ:["599","00","(?:[34]1|7\\d)\\d{5}",[7],0,0,0,0,0,0,"[347]"],BR:["55","00(?:1[245]|2[1-35]|31|4[13]|[56]5|99)","(?:[1-46-9]\\d\\d|5(?:[0-46-9]\\d|5[0-46-9]))\\d{8}|[1-9]\\d{9}|[3589]\\d{8}|[34]\\d{7}",[8,9,10,11],[["(\\d{4})(\\d{4})","$1-$2",["300|4(?:0[02]|37)","4(?:02|37)0|[34]00"]],["(\\d{3})(\\d{2,3})(\\d{4})","$1 $2 $3",["(?:[358]|90)0"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1 $2-$3",["(?:[14689][1-9]|2[12478]|3[1-578]|5[13-5]|7[13-579])[2-57]"],"($1)"],["(\\d{2})(\\d{5})(\\d{4})","$1 $2-$3",["[16][1-9]|[2-57-9]"],"($1)"]],"0",0,"(?:0|90)(?:(1[245]|2[1-35]|31|4[13]|[56]5|99)(\\d{10,11}))?","$2"],BS:["1","011","(?:242|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([3-8]\\d{6})$|1","242$1",0,"242"],BT:["975","00","[17]\\d{7}|[2-8]\\d{6}",[7,8],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[2-68]|7[246]"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["1[67]|7"]]]],BW:["267","00","(?:0800|(?:[37]|800)\\d)\\d{6}|(?:[2-6]\\d|90)\\d{5}",[7,8,10],[["(\\d{2})(\\d{5})","$1 $2",["90"]],["(\\d{3})(\\d{4})","$1 $2",["[24-6]|3[15-79]"]],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[37]"]],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["0"]],["(\\d{3})(\\d{4})(\\d{3})","$1 $2 $3",["8"]]]],BY:["375","810","(?:[12]\\d|33|44|902)\\d{7}|8(?:0[0-79]\\d{5,7}|[1-7]\\d{9})|8(?:1[0-489]|[5-79]\\d)\\d{7}|8[1-79]\\d{6,7}|8[0-79]\\d{5}|8\\d{5}",[6,7,8,9,10,11],[["(\\d{3})(\\d{3})","$1 $2",["800"],"8 $1"],["(\\d{3})(\\d{2})(\\d{2,4})","$1 $2 $3",["800"],"8 $1"],["(\\d{4})(\\d{2})(\\d{3})","$1 $2-$3",["1(?:5[169]|6[3-5]|7[179])|2(?:1[35]|2[34]|3[3-5])","1(?:5[169]|6(?:3[1-3]|4|5[125])|7(?:1[3-9]|7[0-24-6]|9[2-7]))|2(?:1[35]|2[34]|3[3-5])"],"8 0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2-$3-$4",["1(?:[56]|7[467])|2[1-3]"],"8 0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2-$3-$4",["[1-4]"],"8 0$1"],["(\\d{3})(\\d{3,4})(\\d{4})","$1 $2 $3",["[89]"],"8 $1"]],"8",0,"0|80?",0,0,0,0,"8~10"],BZ:["501","00","(?:0800\\d|[2-8])\\d{6}",[7,11],[["(\\d{3})(\\d{4})","$1-$2",["[2-8]"]],["(\\d)(\\d{3})(\\d{4})(\\d{3})","$1-$2-$3-$4",["0"]]]],CA:["1","011","(?:[2-8]\\d|90)\\d{8}|3\\d{6}",[7,10],0,"1",0,0,0,0,0,[["(?:2(?:04|[23]6|[48]9|50|63)|3(?:06|43|54|6[578]|82)|4(?:03|1[68]|3[178]|50|68|74)|5(?:06|1[49]|48|79|8[147])|6(?:04|[18]3|39|47|72)|7(?:0[59]|42|53|78|8[02])|8(?:[06]7|19|25|73)|90[25])[2-9]\\d{6}",[10]],["",[10]],["8(?:00|33|44|55|66|77|88)[2-9]\\d{6}",[10]],["900[2-9]\\d{6}",[10]],["52(?:3(?:[2-46-9][02-9]\\d|5(?:[02-46-9]\\d|5[0-46-9]))|4(?:[2-478][02-9]\\d|5(?:[034]\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\d)|9(?:[05-9]\\d|2[0-5]|49)))\\d{4}|52[34][2-9]1[02-9]\\d{4}|(?:5(?:00|2[125-9]|33|44|66|77|88)|622)[2-9]\\d{6}",[10]],0,["310\\d{4}",[7]],0,["600[2-9]\\d{6}",[10]]]],CC:["61","001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011","1(?:[0-79]\\d{8}(?:\\d{2})?|8[0-24-9]\\d{7})|[148]\\d{8}|1\\d{5,7}",[6,7,8,9,10,12],0,"0",0,"([59]\\d{7})$|0","8$1",0,0,[["8(?:51(?:0(?:02|31|60|89)|1(?:18|76)|223)|91(?:0(?:1[0-2]|29)|1(?:[28]2|50|79)|2(?:10|64)|3(?:[06]8|22)|4[29]8|62\\d|70[23]|959))\\d{3}",[9]],["4(?:79[01]|83[0-389]|93[0-6])\\d{5}|4(?:[0-3]\\d|4[047-9]|5[0-25-9]|6[016-9]|7[02-8]|8[0-24-9]|9[0-27-9])\\d{6}",[9]],["180(?:0\\d{3}|2)\\d{3}",[7,10]],["190[0-26]\\d{6}",[10]],0,0,0,0,["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}",[9]],["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}",[6,8,10,12]]],"0011"],CD:["243","00","[189]\\d{8}|[1-68]\\d{6}",[7,9],[["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["88"],"0$1"],["(\\d{2})(\\d{5})","$1 $2",["[1-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[89]"],"0$1"]],"0"],CF:["236","00","(?:[27]\\d{3}|8776)\\d{4}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[278]"]]]],CG:["242","00","222\\d{6}|(?:0\\d|80)\\d{7}",[9],[["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["8"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[02]"]]]],CH:["41","00","8\\d{11}|[2-9]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8[047]|90"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-79]|81"],"0$1"],["(\\d{3})(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["8"],"0$1"]],"0"],CI:["225","00","[02]\\d{9}",[10],[["(\\d{2})(\\d{2})(\\d)(\\d{5})","$1 $2 $3 $4",["2"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3 $4",["0"]]]],CK:["682","00","[2-578]\\d{4}",[5],[["(\\d{2})(\\d{3})","$1 $2",["[2-578]"]]]],CL:["56","(?:0|1(?:1[0-69]|2[02-5]|5[13-58]|69|7[0167]|8[018]))0","12300\\d{6}|6\\d{9,10}|[2-9]\\d{8}",[9,10,11],[["(\\d{5})(\\d{4})","$1 $2",["219","2196"],"($1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["44"]],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["2[1-36]"],"($1)"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["9[2-9]"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["3[2-5]|[47]|5[1-3578]|6[13-57]|8(?:0[1-9]|[1-9])"],"($1)"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["60|8"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]],["(\\d{3})(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3 $4",["60"]]]],CM:["237","00","[26]\\d{8}|88\\d{6,7}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["88"]],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["[26]|88"]]]],CN:["86","00|1(?:[12]\\d|79)\\d\\d00","1[127]\\d{8,9}|2\\d{9}(?:\\d{2})?|[12]\\d{6,7}|86\\d{6}|(?:1[03-689]\\d|6)\\d{7,9}|(?:[3-579]\\d|8[0-57-9])\\d{6,9}",[7,8,9,10,11,12],[["(\\d{2})(\\d{5,6})","$1 $2",["(?:10|2[0-57-9])[19]","(?:10|2[0-57-9])(?:10|9[56])","10(?:10|9[56])|2[0-57-9](?:100|9[56])"],"0$1"],["(\\d{3})(\\d{5,6})","$1 $2",["3(?:[157]|35|49|9[1-68])|4(?:[17]|2[179]|6[47-9]|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]|4[13]|5[1-5])|(?:4[35]|59|85)[1-9]","(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))[19]","85[23](?:10|95)|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))(?:10|9[56])","85[23](?:100|95)|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))(?:100|9[56])"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["(?:4|80)0"]],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["10|2(?:[02-57-9]|1[1-9])","10|2(?:[02-57-9]|1[1-9])","10[0-79]|2(?:[02-57-9]|1[1-79])|(?:10|21)8(?:0[1-9]|[1-9])"],"0$1",1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["3(?:[3-59]|7[02-68])|4(?:[26-8]|3[3-9]|5[2-9])|5(?:3[03-9]|[468]|7[028]|9[2-46-9])|6|7(?:[0-247]|3[04-9]|5[0-4689]|6[2368])|8(?:[1-358]|9[1-7])|9(?:[013479]|5[1-5])|(?:[34]1|55|79|87)[02-9]"],"0$1",1],["(\\d{3})(\\d{7,8})","$1 $2",["9"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["80"],"0$1",1],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["[3-578]"],"0$1",1],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["1[3-9]"]],["(\\d{2})(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3 $4",["[12]"],"0$1",1]],"0",0,"(1(?:[12]\\d|79)\\d\\d)|0",0,0,0,0,"00"],CO:["57","00(?:4(?:[14]4|56)|[579])","(?:60\\d\\d|9101)\\d{6}|(?:1\\d|3)\\d{9}",[10,11],[["(\\d{3})(\\d{7})","$1 $2",["6"],"($1)"],["(\\d{3})(\\d{7})","$1 $2",["3[0-357]|91"]],["(\\d)(\\d{3})(\\d{7})","$1-$2-$3",["1"],"0$1",0,"$1 $2 $3"]],"0",0,"0(4(?:[14]4|56)|[579])?"],CR:["506","00","(?:8\\d|90)\\d{8}|(?:[24-8]\\d{3}|3005)\\d{4}",[8,10],[["(\\d{4})(\\d{4})","$1 $2",["[2-7]|8[3-9]"]],["(\\d{3})(\\d{3})(\\d{4})","$1-$2-$3",["[89]"]]],0,0,"(19(?:0[0-2468]|1[09]|20|66|77|99))"],CU:["53","119","[27]\\d{6,7}|[34]\\d{5,7}|(?:5|8\\d\\d)\\d{7}",[6,7,8,10],[["(\\d{2})(\\d{4,6})","$1 $2",["2[1-4]|[34]"],"(0$1)"],["(\\d)(\\d{6,7})","$1 $2",["7"],"(0$1)"],["(\\d)(\\d{7})","$1 $2",["5"],"0$1"],["(\\d{3})(\\d{7})","$1 $2",["8"],"0$1"]],"0"],CV:["238","0","(?:[2-59]\\d\\d|800)\\d{4}",[7],[["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["[2-589]"]]]],CW:["599","00","(?:[34]1|60|(?:7|9\\d)\\d)\\d{5}",[7,8],[["(\\d{3})(\\d{4})","$1 $2",["[3467]"]],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["9[4-8]"]]],0,0,0,0,0,"[69]"],CX:["61","001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011","1(?:[0-79]\\d{8}(?:\\d{2})?|8[0-24-9]\\d{7})|[148]\\d{8}|1\\d{5,7}",[6,7,8,9,10,12],0,"0",0,"([59]\\d{7})$|0","8$1",0,0,[["8(?:51(?:0(?:01|30|59|88)|1(?:17|46|75)|2(?:22|35))|91(?:00[6-9]|1(?:[28]1|49|78)|2(?:09|63)|3(?:12|26|75)|4(?:56|97)|64\\d|7(?:0[01]|1[0-2])|958))\\d{3}",[9]],["4(?:79[01]|83[0-389]|93[0-6])\\d{5}|4(?:[0-3]\\d|4[047-9]|5[0-25-9]|6[016-9]|7[02-8]|8[0-24-9]|9[0-27-9])\\d{6}",[9]],["180(?:0\\d{3}|2)\\d{3}",[7,10]],["190[0-26]\\d{6}",[10]],0,0,0,0,["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}",[9]],["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}",[6,8,10,12]]],"0011"],CY:["357","00","(?:[279]\\d|[58]0)\\d{6}",[8],[["(\\d{2})(\\d{6})","$1 $2",["[257-9]"]]]],CZ:["420","00","(?:[2-578]\\d|60)\\d{7}|9\\d{8,11}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[2-8]|9[015-7]"]],["(\\d{2})(\\d{3})(\\d{3})(\\d{2})","$1 $2 $3 $4",["96"]],["(\\d{2})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["9"]],["(\\d{3})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["9"]]]],DE:["49","00","[2579]\\d{5,14}|49(?:[34]0|69|8\\d)\\d\\d?|49(?:37|49|60|7[089]|9\\d)\\d{1,3}|49(?:2[024-9]|3[2-689]|7[1-7])\\d{1,8}|(?:1|[368]\\d|4[0-8])\\d{3,13}|49(?:[015]\\d|2[13]|31|[46][1-8])\\d{1,9}",[4,5,6,7,8,9,10,11,12,13,14,15],[["(\\d{2})(\\d{3,13})","$1 $2",["3[02]|40|[68]9"],"0$1"],["(\\d{3})(\\d{3,12})","$1 $2",["2(?:0[1-389]|1[124]|2[18]|3[14])|3(?:[35-9][15]|4[015])|906|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1","2(?:0[1-389]|12[0-8])|3(?:[35-9][15]|4[015])|906|2(?:[13][14]|2[18])|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1"],"0$1"],["(\\d{4})(\\d{2,11})","$1 $2",["[24-6]|3(?:[3569][02-46-9]|4[2-4679]|7[2-467]|8[2-46-8])|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]","[24-6]|3(?:3(?:0[1-467]|2[127-9]|3[124578]|7[1257-9]|8[1256]|9[145])|4(?:2[135]|4[13578]|9[1346])|5(?:0[14]|2[1-3589]|6[1-4]|7[13468]|8[13568])|6(?:2[1-489]|3[124-6]|6[13]|7[12579]|8[1-356]|9[135])|7(?:2[1-7]|4[145]|6[1-5]|7[1-4])|8(?:21|3[1468]|6|7[1467]|8[136])|9(?:0[12479]|2[1358]|4[134679]|6[1-9]|7[136]|8[147]|9[1468]))|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]|3[68]4[1347]|3(?:47|60)[1356]|3(?:3[46]|46|5[49])[1246]|3[4579]3[1357]"],"0$1"],["(\\d{3})(\\d{4})","$1 $2",["138"],"0$1"],["(\\d{5})(\\d{2,10})","$1 $2",["3"],"0$1"],["(\\d{3})(\\d{5,11})","$1 $2",["181"],"0$1"],["(\\d{3})(\\d)(\\d{4,10})","$1 $2 $3",["1(?:3|80)|9"],"0$1"],["(\\d{3})(\\d{7,8})","$1 $2",["1[67]"],"0$1"],["(\\d{3})(\\d{7,12})","$1 $2",["8"],"0$1"],["(\\d{5})(\\d{6})","$1 $2",["185","1850","18500"],"0$1"],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["7"],"0$1"],["(\\d{4})(\\d{7})","$1 $2",["18[68]"],"0$1"],["(\\d{5})(\\d{6})","$1 $2",["15[0568]"],"0$1"],["(\\d{4})(\\d{7})","$1 $2",["15[1279]"],"0$1"],["(\\d{3})(\\d{8})","$1 $2",["18"],"0$1"],["(\\d{3})(\\d{2})(\\d{7,8})","$1 $2 $3",["1(?:6[023]|7)"],"0$1"],["(\\d{4})(\\d{2})(\\d{7})","$1 $2 $3",["15[279]"],"0$1"],["(\\d{3})(\\d{2})(\\d{8})","$1 $2 $3",["15"],"0$1"]],"0"],DJ:["253","00","(?:2\\d|77)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[27]"]]]],DK:["45","00","[2-9]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-9]"]]]],DM:["1","011","(?:[58]\\d\\d|767|900)\\d{7}",[10],0,"1",0,"([2-7]\\d{6})$|1","767$1",0,"767"],DO:["1","011","(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,0,0,0,"8001|8[024]9"],DZ:["213","00","(?:[1-4]|[5-79]\\d|80)\\d{7}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[1-4]"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["9"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-8]"],"0$1"]],"0"],EC:["593","00","1\\d{9,10}|(?:[2-7]|9\\d)\\d{7}",[8,9,10,11],[["(\\d)(\\d{3})(\\d{4})","$1 $2-$3",["[2-7]"],"(0$1)",0,"$1-$2-$3"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["9"],"0$1"],["(\\d{4})(\\d{3})(\\d{3,4})","$1 $2 $3",["1"]]],"0"],EE:["372","00","8\\d{9}|[4578]\\d{7}|(?:[3-8]\\d|90)\\d{5}",[7,8,10],[["(\\d{3})(\\d{4})","$1 $2",["[369]|4[3-8]|5(?:[0-2]|5[0-478]|6[45])|7[1-9]|88","[369]|4[3-8]|5(?:[02]|1(?:[0-8]|95)|5[0-478]|6(?:4[0-4]|5[1-589]))|7[1-9]|88"]],["(\\d{4})(\\d{3,4})","$1 $2",["[45]|8(?:00|[1-49])","[45]|8(?:00[1-9]|[1-49])"]],["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["7"]],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["8"]]]],EG:["20","00","[189]\\d{8,9}|[24-6]\\d{8}|[135]\\d{7}",[8,9,10],[["(\\d)(\\d{7,8})","$1 $2",["[23]"],"0$1"],["(\\d{2})(\\d{6,7})","$1 $2",["1[35]|[4-6]|8[2468]|9[235-7]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[189]"],"0$1"]],"0"],EH:["212","00","[5-8]\\d{8}",[9],0,"0",0,0,0,0,"528[89]"],ER:["291","00","[178]\\d{6}",[7],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[178]"],"0$1"]],"0"],ES:["34","00","[5-9]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[89]00"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-9]"]]]],ET:["251","00","(?:11|[2-579]\\d)\\d{7}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[1-579]"],"0$1"]],"0"],FI:["358","00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))","[1-35689]\\d{4}|7\\d{10,11}|(?:[124-7]\\d|3[0-46-9])\\d{8}|[1-9]\\d{5,8}",[5,6,7,8,9,10,11,12],[["(\\d)(\\d{4,9})","$1 $2",["[2568][1-8]|3(?:0[1-9]|[1-9])|9"],"0$1"],["(\\d{3})(\\d{3,7})","$1 $2",["[12]00|[368]|70[07-9]"],"0$1"],["(\\d{2})(\\d{4,8})","$1 $2",["[1245]|7[135]"],"0$1"],["(\\d{2})(\\d{6,10})","$1 $2",["7"],"0$1"]],"0",0,0,0,0,"1[03-79]|[2-9]",0,"00"],FJ:["679","0(?:0|52)","45\\d{5}|(?:0800\\d|[235-9])\\d{6}",[7,11],[["(\\d{3})(\\d{4})","$1 $2",["[235-9]|45"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["0"]]],0,0,0,0,0,0,0,"00"],FK:["500","00","[2-7]\\d{4}",[5]],FM:["691","00","(?:[39]\\d\\d|820)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[389]"]]]],FO:["298","00","[2-9]\\d{5}",[6],[["(\\d{6})","$1",["[2-9]"]]],0,0,"(10(?:01|[12]0|88))"],FR:["33","00","[1-9]\\d{8}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0 $1"],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["[1-79]"],"0$1"]],"0"],GA:["241","00","(?:[067]\\d|11)\\d{6}|[2-7]\\d{6}",[7,8],[["(\\d)(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-7]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["0"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["11|[67]"],"0$1"]],0,0,"0(11\\d{6}|60\\d{6}|61\\d{6}|6[256]\\d{6}|7[467]\\d{6})","$1"],GB:["44","00","[1-357-9]\\d{9}|[18]\\d{8}|8\\d{6}",[7,9,10],[["(\\d{3})(\\d{4})","$1 $2",["800","8001","80011","800111","8001111"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["845","8454","84546","845464"],"0$1"],["(\\d{3})(\\d{6})","$1 $2",["800"],"0$1"],["(\\d{5})(\\d{4,5})","$1 $2",["1(?:38|5[23]|69|76|94)","1(?:(?:38|69)7|5(?:24|39)|768|946)","1(?:3873|5(?:242|39[4-6])|(?:697|768)[347]|9467)"],"0$1"],["(\\d{4})(\\d{5,6})","$1 $2",["1(?:[2-69][02-9]|[78])"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["[25]|7(?:0|6[02-9])","[25]|7(?:0|6(?:[03-9]|2[356]))"],"0$1"],["(\\d{4})(\\d{6})","$1 $2",["7"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[1389]"],"0$1"]],"0",0,0,0,0,0,[["(?:1(?:1(?:3(?:[0-58]\\d\\d|73[0235])|4(?:[0-5]\\d\\d|69[7-9]|70[0-579])|(?:(?:5[0-26-9]|[78][0-49])\\d|6(?:[0-4]\\d|50))\\d)|2(?:(?:0[024-9]|2[3-9]|3[3-79]|4[1-689]|[58][02-9]|6[0-47-9]|7[013-9]|9\\d)\\d\\d|1(?:[0-7]\\d\\d|8(?:[02]\\d|1[0-246-9])))|(?:3(?:0\\d|1[0-8]|[25][02-9]|3[02-579]|[468][0-46-9]|7[1-35-79]|9[2-578])|4(?:0[03-9]|[137]\\d|[28][02-57-9]|4[02-69]|5[0-8]|[69][0-79])|5(?:0[1-35-9]|[16]\\d|2[024-9]|3[015689]|4[02-9]|5[03-9]|7[0-35-9]|8[0-468]|9[0-57-9])|6(?:0[034689]|1\\d|2[0-35689]|[38][013-9]|4[1-467]|5[0-69]|6[13-9]|7[0-8]|9[0-24578])|7(?:0[0246-9]|2\\d|3[0236-8]|4[03-9]|5[0-46-9]|6[013-9]|7[0-35-9]|8[024-9]|9[02-9])|8(?:0[35-9]|2[1-57-9]|3[02-578]|4[0-578]|5[124-9]|6[2-69]|7\\d|8[02-9]|9[02569])|9(?:0[02-589]|[18]\\d|2[02-689]|3[1-57-9]|4[2-9]|5[0-579]|6[2-47-9]|7[0-24578]|9[2-57]))\\d\\d)|2(?:0[013478]|3[0189]|4[017]|8[0-46-9]|9[0-2])\\d{3})\\d{4}|1(?:2(?:0(?:46[1-4]|87[2-9])|545[1-79]|76(?:2\\d|3[1-8]|6[1-6])|9(?:7(?:2[0-4]|3[2-5])|8(?:2[2-8]|7[0-47-9]|8[3-5])))|3(?:6(?:38[2-5]|47[23])|8(?:47[04-9]|64[0157-9]))|4(?:044[1-7]|20(?:2[23]|8\\d)|6(?:0(?:30|5[2-57]|6[1-8]|7[2-8])|140)|8(?:052|87[1-3]))|5(?:2(?:4(?:3[2-79]|6\\d)|76\\d)|6(?:26[06-9]|686))|6(?:06(?:4\\d|7[4-79])|295[5-7]|35[34]\\d|47(?:24|61)|59(?:5[08]|6[67]|74)|9(?:55[0-4]|77[23]))|7(?:26(?:6[13-9]|7[0-7])|(?:442|688)\\d|50(?:2[0-3]|[3-68]2|76))|8(?:27[56]\\d|37(?:5[2-5]|8[239])|843[2-58])|9(?:0(?:0(?:6[1-8]|85)|52\\d)|3583|4(?:66[1-8]|9(?:2[01]|81))|63(?:23|3[1-4])|9561))\\d{3}",[9,10]],["7(?:457[0-57-9]|700[01]|911[028])\\d{5}|7(?:[1-3]\\d\\d|4(?:[0-46-9]\\d|5[0-689])|5(?:0[0-8]|[13-9]\\d|2[0-35-9])|7(?:0[1-9]|[1-7]\\d|8[02-9]|9[0-689])|8(?:[014-9]\\d|[23][0-8])|9(?:[024-9]\\d|1[02-9]|3[0-689]))\\d{6}",[10]],["80[08]\\d{7}|800\\d{6}|8001111"],["(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\d|8[2-49]))\\d{7}|845464\\d",[7,10]],["70\\d{8}",[10]],0,["(?:3[0347]|55)\\d{8}",[10]],["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}",[10]],["56\\d{8}",[10]]],0," x"],GD:["1","011","(?:473|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","473$1",0,"473"],GE:["995","00","(?:[3-57]\\d\\d|800)\\d{6}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["70"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["32"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[57]"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[348]"],"0$1"]],"0"],GF:["594","00","[56]94\\d{6}|(?:80|9\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[56]|97"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[89]"],"0$1"]],"0"],GG:["44","00","(?:1481|[357-9]\\d{3})\\d{6}|8\\d{6}(?:\\d{2})?",[7,9,10],0,"0",0,"([25-9]\\d{5})$|0","1481$1",0,0,[["1481[25-9]\\d{5}",[10]],["7(?:(?:781|839)\\d|911[17])\\d{5}",[10]],["80[08]\\d{7}|800\\d{6}|8001111"],["(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\d|8[0-3]))\\d{7}|845464\\d",[7,10]],["70\\d{8}",[10]],0,["(?:3[0347]|55)\\d{8}",[10]],["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}",[10]],["56\\d{8}",[10]]]],GH:["233","00","(?:[235]\\d{3}|800)\\d{5}",[8,9],[["(\\d{3})(\\d{5})","$1 $2",["8"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[235]"],"0$1"]],"0"],GI:["350","00","(?:[25]\\d\\d|606)\\d{5}",[8],[["(\\d{3})(\\d{5})","$1 $2",["2"]]]],GL:["299","00","(?:19|[2-689]\\d|70)\\d{4}",[6],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["19|[2-9]"]]]],GM:["220","00","[2-9]\\d{6}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-9]"]]]],GN:["224","00","722\\d{6}|(?:3|6\\d)\\d{7}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["3"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[67]"]]]],GP:["590","00","590\\d{6}|(?:69|80|9\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[569]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0$1"]],"0",0,0,0,0,0,[["590(?:0[1-68]|[14][0-24-9]|2[0-68]|3[1289]|5[3-579]|6[0-489]|7[08]|8[0-689]|9\\d)\\d{4}"],["69(?:0\\d\\d|1(?:2[2-9]|3[0-5]))\\d{4}"],["80[0-5]\\d{6}"],0,0,0,0,0,["9(?:395|76[018])\\d{5}"]]],GQ:["240","00","222\\d{6}|(?:3\\d|55|[89]0)\\d{7}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[235]"]],["(\\d{3})(\\d{6})","$1 $2",["[89]"]]]],GR:["30","00","5005000\\d{3}|8\\d{9,11}|(?:[269]\\d|70)\\d{8}",[10,11,12],[["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["21|7"]],["(\\d{4})(\\d{6})","$1 $2",["2(?:2|3[2-57-9]|4[2-469]|5[2-59]|6[2-9]|7[2-69]|8[2-49])|5"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[2689]"]],["(\\d{3})(\\d{3,4})(\\d{5})","$1 $2 $3",["8"]]]],GT:["502","00","(?:1\\d{3}|[2-7])\\d{7}",[8,11],[["(\\d{4})(\\d{4})","$1 $2",["[2-7]"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]]]],GU:["1","011","(?:[58]\\d\\d|671|900)\\d{7}",[10],0,"1",0,"([3-9]\\d{6})$|1","671$1",0,"671"],GW:["245","00","[49]\\d{8}|4\\d{6}",[7,9],[["(\\d{3})(\\d{4})","$1 $2",["40"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[49]"]]]],GY:["592","001","9008\\d{3}|(?:[2-467]\\d\\d|862)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-46-9]"]]]],HK:["852","00(?:30|5[09]|[126-9]?)","8[0-46-9]\\d{6,7}|9\\d{4,7}|(?:[2-7]|9\\d{3})\\d{7}",[5,6,7,8,9,11],[["(\\d{3})(\\d{2,5})","$1 $2",["900","9003"]],["(\\d{4})(\\d{4})","$1 $2",["[2-7]|8[1-4]|9(?:0[1-9]|[1-8])"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"]],["(\\d{3})(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3 $4",["9"]]],0,0,0,0,0,0,0,"00"],HN:["504","00","8\\d{10}|[237-9]\\d{7}",[8,11],[["(\\d{4})(\\d{4})","$1-$2",["[237-9]"]]]],HR:["385","00","(?:[24-69]\\d|3[0-79])\\d{7}|80\\d{5,7}|[1-79]\\d{7}|6\\d{5,6}",[6,7,8,9],[["(\\d{2})(\\d{2})(\\d{2,3})","$1 $2 $3",["6[01]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2,3})","$1 $2 $3",["8"],"0$1"],["(\\d)(\\d{4})(\\d{3})","$1 $2 $3",["1"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[67]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["9"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-5]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"],"0$1"]],"0"],HT:["509","00","(?:[2-489]\\d|55)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["[2-589]"]]]],HU:["36","00","[235-7]\\d{8}|[1-9]\\d{7}",[8,9],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["1"],"(06 $1)"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[27][2-9]|3[2-7]|4[24-9]|5[2-79]|6|8[2-57-9]|9[2-69]"],"(06 $1)"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-9]"],"06 $1"]],"06"],ID:["62","00[89]","(?:(?:00[1-9]|8\\d)\\d{4}|[1-36])\\d{6}|00\\d{10}|[1-9]\\d{8,10}|[2-9]\\d{7}",[7,8,9,10,11,12,13],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["15"]],["(\\d{2})(\\d{5,9})","$1 $2",["2[124]|[36]1"],"(0$1)"],["(\\d{3})(\\d{5,7})","$1 $2",["800"],"0$1"],["(\\d{3})(\\d{5,8})","$1 $2",["[2-79]"],"(0$1)"],["(\\d{3})(\\d{3,4})(\\d{3})","$1-$2-$3",["8[1-35-9]"],"0$1"],["(\\d{3})(\\d{6,8})","$1 $2",["1"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["804"],"0$1"],["(\\d{3})(\\d)(\\d{3})(\\d{3})","$1 $2 $3 $4",["80"],"0$1"],["(\\d{3})(\\d{4})(\\d{4,5})","$1-$2-$3",["8"],"0$1"]],"0"],IE:["353","00","(?:1\\d|[2569])\\d{6,8}|4\\d{6,9}|7\\d{8}|8\\d{8,9}",[7,8,9,10],[["(\\d{2})(\\d{5})","$1 $2",["2[24-9]|47|58|6[237-9]|9[35-9]"],"(0$1)"],["(\\d{3})(\\d{5})","$1 $2",["[45]0"],"(0$1)"],["(\\d)(\\d{3,4})(\\d{4})","$1 $2 $3",["1"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2569]|4[1-69]|7[14]"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["70"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["81"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[78]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["4"],"(0$1)"],["(\\d{2})(\\d)(\\d{3})(\\d{4})","$1 $2 $3 $4",["8"],"0$1"]],"0"],IL:["972","0(?:0|1[2-9])","1\\d{6}(?:\\d{3,5})?|[57]\\d{8}|[1-489]\\d{7}",[7,8,9,10,11,12],[["(\\d{4})(\\d{3})","$1-$2",["125"]],["(\\d{4})(\\d{2})(\\d{2})","$1-$2-$3",["121"]],["(\\d)(\\d{3})(\\d{4})","$1-$2-$3",["[2-489]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["[57]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1-$2-$3",["12"]],["(\\d{4})(\\d{6})","$1-$2",["159"]],["(\\d)(\\d{3})(\\d{3})(\\d{3})","$1-$2-$3-$4",["1[7-9]"]],["(\\d{3})(\\d{1,2})(\\d{3})(\\d{4})","$1-$2 $3-$4",["15"]]],"0"],IM:["44","00","1624\\d{6}|(?:[3578]\\d|90)\\d{8}",[10],0,"0",0,"([25-8]\\d{5})$|0","1624$1",0,"74576|(?:16|7[56])24"],IN:["91","00","(?:000800|[2-9]\\d\\d)\\d{7}|1\\d{7,12}",[8,9,10,11,12,13],[["(\\d{8})","$1",["5(?:0|2[23]|3[03]|[67]1|88)","5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|888)","5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|8888)"],0,1],["(\\d{4})(\\d{4,5})","$1 $2",["180","1800"],0,1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["140"],0,1],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["11|2[02]|33|4[04]|79[1-7]|80[2-46]","11|2[02]|33|4[04]|79(?:[1-6]|7[19])|80(?:[2-4]|6[0-589])","11|2[02]|33|4[04]|79(?:[124-6]|3(?:[02-9]|1[0-24-9])|7(?:1|9[1-6]))|80(?:[2-4]|6[0-589])"],"0$1",1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["1(?:2[0-249]|3[0-25]|4[145]|[68]|7[1257])|2(?:1[257]|3[013]|4[01]|5[0137]|6[0158]|78|8[1568])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|5[12]|[78]1)|6(?:12|[2-4]1|5[17]|6[13]|80)|7(?:12|3[134]|4[47]|61|88)|8(?:16|2[014]|3[126]|6[136]|7[078]|8[34]|91)|(?:43|59|75)[15]|(?:1[59]|29|67|72)[14]","1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|674|7(?:(?:2[14]|3[34]|5[15])[2-6]|61[346]|88[0-8])|8(?:70[2-6]|84[235-7]|91[3-7])|(?:1(?:29|60|8[06])|261|552|6(?:12|[2-47]1|5[17]|6[13]|80)|7(?:12|31|4[47])|8(?:16|2[014]|3[126]|6[136]|7[78]|83))[2-7]","1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|6(?:12(?:[2-6]|7[0-8])|74[2-7])|7(?:(?:2[14]|5[15])[2-6]|3171|61[346]|88(?:[2-7]|82))|8(?:70[2-6]|84(?:[2356]|7[19])|91(?:[3-6]|7[19]))|73[134][2-6]|(?:74[47]|8(?:16|2[014]|3[126]|6[136]|7[78]|83))(?:[2-6]|7[19])|(?:1(?:29|60|8[06])|261|552|6(?:[2-4]1|5[17]|6[13]|7(?:1|4[0189])|80)|7(?:12|88[01]))[2-7]"],"0$1",1],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2[2457-9]|3[2-5]|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1[013-9]|28|3[129]|4[1-35689]|5[29]|6[02-5]|70)|807","1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2(?:[2457]|84|95)|3(?:[2-4]|55)|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1(?:[013-8]|9[6-9])|28[6-8]|3(?:17|2[0-49]|9[2-57])|4(?:1[2-4]|[29][0-7]|3[0-8]|[56]|8[0-24-7])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4|5[0-367])|70[13-7])|807[19]","1(?:[2-479]|5(?:[0236-9]|5[013-9]))|[2-5]|6(?:2(?:84|95)|355|83)|73179|807(?:1|9[1-3])|(?:1552|6(?:1[1358]|2[2457]|3[2-4]|4[235-7]|5[2-689]|6[24578]|7[235689]|8[124-6])\\d|7(?:1(?:[013-8]\\d|9[6-9])|28[6-8]|3(?:2[0-49]|9[2-57])|4(?:1[2-4]|[29][0-7]|3[0-8]|[56]\\d|8[0-24-7])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4\\d|5[0-367])|70[13-7]))[2-7]"],"0$1",1],["(\\d{5})(\\d{5})","$1 $2",["[6-9]"],"0$1",1],["(\\d{4})(\\d{2,4})(\\d{4})","$1 $2 $3",["1(?:6|8[06])","1(?:6|8[06]0)"],0,1],["(\\d{4})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["18"],0,1]],"0"],IO:["246","00","3\\d{6}",[7],[["(\\d{3})(\\d{4})","$1 $2",["3"]]]],IQ:["964","00","(?:1|7\\d\\d)\\d{7}|[2-6]\\d{7,8}",[8,9,10],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-6]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"0$1"]],"0"],IR:["98","00","[1-9]\\d{9}|(?:[1-8]\\d\\d|9)\\d{3,4}",[4,5,6,7,10],[["(\\d{4,5})","$1",["96"],"0$1"],["(\\d{2})(\\d{4,5})","$1 $2",["(?:1[137]|2[13-68]|3[1458]|4[145]|5[1468]|6[16]|7[1467]|8[13467])[12689]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["9"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["[1-8]"],"0$1"]],"0"],IS:["354","00|1(?:0(?:01|[12]0)|100)","(?:38\\d|[4-9])\\d{6}",[7,9],[["(\\d{3})(\\d{4})","$1 $2",["[4-9]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["3"]]],0,0,0,0,0,0,0,"00"],IT:["39","00","0\\d{5,10}|1\\d{8,10}|3(?:[0-8]\\d{7,10}|9\\d{7,8})|(?:55|70)\\d{8}|8\\d{5}(?:\\d{2,4})?",[6,7,8,9,10,11],[["(\\d{2})(\\d{4,6})","$1 $2",["0[26]"]],["(\\d{3})(\\d{3,6})","$1 $2",["0[13-57-9][0159]|8(?:03|4[17]|9[2-5])","0[13-57-9][0159]|8(?:03|4[17]|9(?:2|3[04]|[45][0-4]))"]],["(\\d{4})(\\d{2,6})","$1 $2",["0(?:[13-579][2-46-8]|8[236-8])"]],["(\\d{4})(\\d{4})","$1 $2",["894"]],["(\\d{2})(\\d{3,4})(\\d{4})","$1 $2 $3",["0[26]|5"]],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["1(?:44|[679])|[378]"]],["(\\d{3})(\\d{3,4})(\\d{4})","$1 $2 $3",["0[13-57-9][0159]|14"]],["(\\d{2})(\\d{4})(\\d{5})","$1 $2 $3",["0[26]"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["0"]],["(\\d{3})(\\d{4})(\\d{4,5})","$1 $2 $3",["3"]]],0,0,0,0,0,0,[["0669[0-79]\\d{1,6}|0(?:1(?:[0159]\\d|[27][1-5]|31|4[1-4]|6[1356]|8[2-57])|2\\d\\d|3(?:[0159]\\d|2[1-4]|3[12]|[48][1-6]|6[2-59]|7[1-7])|4(?:[0159]\\d|[23][1-9]|4[245]|6[1-5]|7[1-4]|81)|5(?:[0159]\\d|2[1-5]|3[2-6]|4[1-79]|6[4-6]|7[1-578]|8[3-8])|6(?:[0-57-9]\\d|6[0-8])|7(?:[0159]\\d|2[12]|3[1-7]|4[2-46]|6[13569]|7[13-6]|8[1-59])|8(?:[0159]\\d|2[3-578]|3[1-356]|[6-8][1-5])|9(?:[0159]\\d|[238][1-5]|4[12]|6[1-8]|7[1-6]))\\d{2,7}"],["3[1-9]\\d{8}|3[2-9]\\d{7}",[9,10]],["80(?:0\\d{3}|3)\\d{3}",[6,9]],["(?:0878\\d{3}|89(?:2\\d|3[04]|4(?:[0-4]|[5-9]\\d\\d)|5[0-4]))\\d\\d|(?:1(?:44|6[346])|89(?:38|5[5-9]|9))\\d{6}",[6,8,9,10]],["1(?:78\\d|99)\\d{6}",[9,10]],0,0,0,["55\\d{8}",[10]],["84(?:[08]\\d{3}|[17])\\d{3}",[6,9]]]],JE:["44","00","1534\\d{6}|(?:[3578]\\d|90)\\d{8}",[10],0,"0",0,"([0-24-8]\\d{5})$|0","1534$1",0,0,[["1534[0-24-8]\\d{5}"],["7(?:(?:(?:50|82)9|937)\\d|7(?:00[378]|97[7-9]))\\d{5}"],["80(?:07(?:35|81)|8901)\\d{4}"],["(?:8(?:4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|90(?:066[59]|1810|71(?:07|55)))\\d{4}"],["701511\\d{4}"],0,["(?:3(?:0(?:07(?:35|81)|8901)|3\\d{4}|4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|55\\d{4})\\d{4}"],["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}"],["56\\d{8}"]]],JM:["1","011","(?:[58]\\d\\d|658|900)\\d{7}",[10],0,"1",0,0,0,0,"658|876"],JO:["962","00","(?:(?:[2689]|7\\d)\\d|32|53)\\d{6}",[8,9],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[2356]|87"],"(0$1)"],["(\\d{3})(\\d{5,6})","$1 $2",["[89]"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["70"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["7"],"0$1"]],"0"],JP:["81","010","00[1-9]\\d{6,14}|[257-9]\\d{9}|(?:00|[1-9]\\d\\d)\\d{6}",[8,9,10,11,12,13,14,15,16,17],[["(\\d{3})(\\d{3})(\\d{3})","$1-$2-$3",["(?:12|57|99)0"],"0$1"],["(\\d{4})(\\d)(\\d{4})","$1-$2-$3",["1(?:26|3[79]|4[56]|5[4-68]|6[3-5])|499|5(?:76|97)|746|8(?:3[89]|47|51|63)|9(?:80|9[16])","1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:76|97)9|7468|8(?:3(?:8[7-9]|96)|477|51[2-9]|636)|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]","1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:769|979[2-69])|7468|8(?:3(?:8[7-9]|96[2457-9])|477|51[2-9]|636[457-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["60"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1-$2-$3",["[36]|4(?:2[09]|7[01])","[36]|4(?:2(?:0|9[02-69])|7(?:0[019]|1))"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["1(?:1|5[45]|77|88|9[69])|2(?:2[1-37]|3[0-269]|4[59]|5|6[24]|7[1-358]|8[1369]|9[0-38])|4(?:[28][1-9]|3[0-57]|[45]|6[248]|7[2-579]|9[29])|5(?:2|3[045]|4[0-369]|5[29]|8[02389]|9[0-389])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9[2-6])|8(?:2[124589]|3[27-9]|49|51|6|7[0-468]|8[68]|9[019])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9[1-489])","1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2(?:[127]|3[014-9])|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9[19])|62|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|8[1-9])|5(?:2|3[045]|4[0-369]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0-2469])|49|51|6(?:[0-24]|36|5[0-3589]|72|9[01459])|7[0-468]|8[68])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9(?:[1289]|3[34]|4[0178]))|(?:49|55|83)[29]|(?:264|837)[016-9]|2(?:57|93)[015-9]|(?:25[0468]|422|838)[01]|(?:47[59]|59[89]|8(?:6[68]|9))[019]","1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2[127]|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9(?:17|99))|6(?:2|4[016-9])|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|9[29])|5(?:2|3[045]|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0169])|3(?:[29]|7(?:[017-9]|6[6-8]))|49|51|6(?:[0-24]|36[23]|5(?:[0-389]|5[23])|6(?:[01]|9[178])|72|9[0145])|7[0-468]|8[68])|9(?:4[15]|5[138]|7[156]|8[189]|9(?:[1289]|3(?:31|4[357])|4[0178]))|(?:8294|96)[1-3]|2(?:57|93)[015-9]|(?:223|8699)[014-9]|(?:25[0468]|422|838)[01]|(?:48|8292|9[23])[1-9]|(?:47[59]|59[89]|8(?:68|9))[019]","1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2[127]|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|7[015-9]|9(?:17|99))|6(?:2|4[016-9])|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17|3[015-9]))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|9[29])|5(?:2|3[045]|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9(?:[019]|4[1-3]|6(?:[0-47-9]|5[01346-9])))|3(?:[29]|7(?:[017-9]|6[6-8]))|49|51|6(?:[0-24]|36[23]|5(?:[0-389]|5[23])|6(?:[01]|9[178])|72|9[0145])|7[0-468]|8[68])|9(?:4[15]|5[138]|6[1-3]|7[156]|8[189]|9(?:[1289]|3(?:31|4[357])|4[0178]))|(?:223|8699)[014-9]|(?:25[0468]|422|838)[01]|(?:48|829(?:2|66)|9[23])[1-9]|(?:47[59]|59[89]|8(?:68|9))[019]"],"0$1"],["(\\d{3})(\\d{2})(\\d{4})","$1-$2-$3",["[14]|[289][2-9]|5[3-9]|7[2-4679]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1-$2-$3",["800"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1-$2-$3",["[257-9]"],"0$1"]],"0"],KE:["254","000","(?:[17]\\d\\d|900)\\d{6}|(?:2|80)0\\d{6,7}|[4-6]\\d{6,8}",[7,8,9,10],[["(\\d{2})(\\d{5,7})","$1 $2",["[24-6]"],"0$1"],["(\\d{3})(\\d{6})","$1 $2",["[17]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["[89]"],"0$1"]],"0"],KG:["996","00","8\\d{9}|(?:[235-8]\\d|99)\\d{7}",[9,10],[["(\\d{4})(\\d{5})","$1 $2",["3(?:1[346]|[24-79])"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[235-79]|88"],"0$1"],["(\\d{3})(\\d{3})(\\d)(\\d{2,3})","$1 $2 $3 $4",["8"],"0$1"]],"0"],KH:["855","00[14-9]","1\\d{9}|[1-9]\\d{7,8}",[8,9,10],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[1-9]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]]],"0"],KI:["686","00","(?:[37]\\d|6[0-79])\\d{6}|(?:[2-48]\\d|50)\\d{3}",[5,8],0,"0"],KM:["269","00","[3478]\\d{6}",[7],[["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["[3478]"]]]],KN:["1","011","(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-7]\\d{6})$|1","869$1",0,"869"],KP:["850","00|99","85\\d{6}|(?:19\\d|[2-7])\\d{7}",[8,10],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["8"],"0$1"],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[2-7]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"]],"0"],KR:["82","00(?:[125689]|3(?:[46]5|91)|7(?:00|27|3|55|6[126]))","00[1-9]\\d{8,11}|(?:[12]|5\\d{3})\\d{7}|[13-6]\\d{9}|(?:[1-6]\\d|80)\\d{7}|[3-6]\\d{4,5}|(?:00|7)0\\d{8}",[5,6,8,9,10,11,12,13,14],[["(\\d{2})(\\d{3,4})","$1-$2",["(?:3[1-3]|[46][1-4]|5[1-5])1"],"0$1"],["(\\d{4})(\\d{4})","$1-$2",["1"]],["(\\d)(\\d{3,4})(\\d{4})","$1-$2-$3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["60|8"],"0$1"],["(\\d{2})(\\d{3,4})(\\d{4})","$1-$2-$3",["[1346]|5[1-5]"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1-$2-$3",["[57]"],"0$1"],["(\\d{2})(\\d{5})(\\d{4})","$1-$2-$3",["5"],"0$1"]],"0",0,"0(8(?:[1-46-8]|5\\d\\d))?"],KW:["965","00","18\\d{5}|(?:[2569]\\d|41)\\d{6}",[7,8],[["(\\d{4})(\\d{3,4})","$1 $2",["[169]|2(?:[235]|4[1-35-9])|52"]],["(\\d{3})(\\d{5})","$1 $2",["[245]"]]]],KY:["1","011","(?:345|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","345$1",0,"345"],KZ:["7","810","(?:33622|8\\d{8})\\d{5}|[78]\\d{9}",[10,14],0,"8",0,0,0,0,"33|7",0,"8~10"],LA:["856","00","[23]\\d{9}|3\\d{8}|(?:[235-8]\\d|41)\\d{6}",[8,9,10],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["2[13]|3[14]|[4-8]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3 $4",["30[013-9]"],"0$1"],["(\\d{2})(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3 $4",["[23]"],"0$1"]],"0"],LB:["961","00","[27-9]\\d{7}|[13-9]\\d{6}",[7,8],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[13-69]|7(?:[2-57]|62|8[0-7]|9[04-9])|8[02-9]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[27-9]"]]],"0"],LC:["1","011","(?:[58]\\d\\d|758|900)\\d{7}",[10],0,"1",0,"([2-8]\\d{6})$|1","758$1",0,"758"],LI:["423","00","[68]\\d{8}|(?:[2378]\\d|90)\\d{5}",[7,9],[["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["[2379]|8(?:0[09]|7)","[2379]|8(?:0(?:02|9)|7)"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["69"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6"]]],"0",0,"(1001)|0"],LK:["94","00","[1-9]\\d{8}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[1-689]"],"0$1"]],"0"],LR:["231","00","(?:[25]\\d|33|77|88)\\d{7}|(?:2\\d|[4-6])\\d{6}",[7,8,9],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[4-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[23578]"],"0$1"]],"0"],LS:["266","00","(?:[256]\\d\\d|800)\\d{5}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[2568]"]]]],LT:["370","00","(?:[3469]\\d|52|[78]0)\\d{6}",[8],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["52[0-7]"],"(8-$1)",1],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[7-9]"],"8 $1",1],["(\\d{2})(\\d{6})","$1 $2",["37|4(?:[15]|6[1-8])"],"(8-$1)",1],["(\\d{3})(\\d{5})","$1 $2",["[3-6]"],"(8-$1)",1]],"8",0,"[08]"],LU:["352","00","35[013-9]\\d{4,8}|6\\d{8}|35\\d{2,4}|(?:[2457-9]\\d|3[0-46-9])\\d{2,9}",[4,5,6,7,8,9,10,11],[["(\\d{2})(\\d{3})","$1 $2",["2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])"]],["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])"]],["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["20[2-689]"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{1,2})","$1 $2 $3 $4",["2(?:[0367]|4[3-8])"]],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["80[01]|90[015]"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3 $4",["20"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{1,2})","$1 $2 $3 $4 $5",["2(?:[0367]|4[3-8])"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{1,5})","$1 $2 $3 $4",["[3-57]|8[13-9]|9(?:0[89]|[2-579])|(?:2|80)[2-9]"]]],0,0,"(15(?:0[06]|1[12]|[35]5|4[04]|6[26]|77|88|99)\\d)"],LV:["371","00","(?:[268]\\d|90)\\d{6}",[8],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[269]|8[01]"]]]],LY:["218","00","[2-9]\\d{8}",[9],[["(\\d{2})(\\d{7})","$1-$2",["[2-9]"],"0$1"]],"0"],MA:["212","00","[5-8]\\d{8}",[9],[["(\\d{5})(\\d{4})","$1-$2",["5(?:29|38)","5(?:29[1289]|389)","529(?:1[1-46-9]|2[013-8]|90)|5(?:298|389)[0-46-9]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["5[45]"],"0$1"],["(\\d{4})(\\d{5})","$1-$2",["5(?:2[2-489]|3[5-9]|9)|892","5(?:2(?:[2-49]|8[235-9])|3[5-9]|9)|892"],"0$1"],["(\\d{2})(\\d{7})","$1-$2",["8"],"0$1"],["(\\d{3})(\\d{6})","$1-$2",["[5-7]"],"0$1"]],"0",0,0,0,0,0,[["5293[01]\\d{4}|5(?:2(?:[0-25-7]\\d|3[1-578]|4[02-46-8]|8[0235-7]|9[0-289])|3(?:[0-47]\\d|5[02-9]|6[02-8]|8[0189]|9[3-9])|(?:4[067]|5[03])\\d)\\d{5}"],["(?:6(?:[0-79]\\d|8[0-247-9])|7(?:[017]\\d|2[0-2]|6[0-8]|8[0-3]))\\d{6}"],["80\\d{7}"],["89\\d{7}"],0,0,0,0,["592(?:4[0-2]|93)\\d{4}"]]],MC:["377","00","(?:[3489]|6\\d)\\d{7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["4"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[389]"]],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["6"],"0$1"]],"0"],MD:["373","00","(?:[235-7]\\d|[89]0)\\d{6}",[8],[["(\\d{3})(\\d{5})","$1 $2",["[89]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["22|3"],"0$1"],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[25-7]"],"0$1"]],"0"],ME:["382","00","(?:20|[3-79]\\d)\\d{6}|80\\d{6,7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-9]"],"0$1"]],"0"],MF:["590","00","590\\d{6}|(?:69|80|9\\d)\\d{7}",[9],0,"0",0,0,0,0,0,[["590(?:0[079]|[14]3|[27][79]|30|5[0-268]|87)\\d{4}"],["69(?:0\\d\\d|1(?:2[2-9]|3[0-5]))\\d{4}"],["80[0-5]\\d{6}"],0,0,0,0,0,["9(?:395|76[018])\\d{5}"]]],MG:["261","00","[23]\\d{8}",[9],[["(\\d{2})(\\d{2})(\\d{3})(\\d{2})","$1 $2 $3 $4",["[23]"],"0$1"]],"0",0,"([24-9]\\d{6})$|0","20$1"],MH:["692","011","329\\d{4}|(?:[256]\\d|45)\\d{5}",[7],[["(\\d{3})(\\d{4})","$1-$2",["[2-6]"]]],"1"],MK:["389","00","[2-578]\\d{7}",[8],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["2|34[47]|4(?:[37]7|5[47]|64)"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[347]"],"0$1"],["(\\d{3})(\\d)(\\d{2})(\\d{2})","$1 $2 $3 $4",["[58]"],"0$1"]],"0"],ML:["223","00","[24-9]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[24-9]"]]]],MM:["95","00","1\\d{5,7}|95\\d{6}|(?:[4-7]|9[0-46-9])\\d{6,8}|(?:2|8\\d)\\d{5,8}",[6,7,8,9,10],[["(\\d)(\\d{2})(\\d{3})","$1 $2 $3",["16|2"],"0$1"],["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["[45]|6(?:0[23]|[1-689]|7[235-7])|7(?:[0-4]|5[2-7])|8[1-6]"],"0$1"],["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["[12]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[4-7]|8[1-35]"],"0$1"],["(\\d)(\\d{3})(\\d{4,6})","$1 $2 $3",["9(?:2[0-4]|[35-9]|4[137-9])"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["2"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"],"0$1"],["(\\d)(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["92"],"0$1"],["(\\d)(\\d{5})(\\d{4})","$1 $2 $3",["9"],"0$1"]],"0"],MN:["976","001","[12]\\d{7,9}|[5-9]\\d{7}",[8,9,10],[["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["[12]1"],"0$1"],["(\\d{4})(\\d{4})","$1 $2",["[5-9]"]],["(\\d{3})(\\d{5,6})","$1 $2",["[12]2[1-3]"],"0$1"],["(\\d{4})(\\d{5,6})","$1 $2",["[12](?:27|3[2-8]|4[2-68]|5[1-4689])","[12](?:27|3[2-8]|4[2-68]|5[1-4689])[0-3]"],"0$1"],["(\\d{5})(\\d{4,5})","$1 $2",["[12]"],"0$1"]],"0"],MO:["853","00","0800\\d{3}|(?:28|[68]\\d)\\d{6}",[7,8],[["(\\d{4})(\\d{3})","$1 $2",["0"]],["(\\d{4})(\\d{4})","$1 $2",["[268]"]]]],MP:["1","011","[58]\\d{9}|(?:67|90)0\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","670$1",0,"670"],MQ:["596","00","596\\d{6}|(?:69|80|9\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[569]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0$1"]],"0"],MR:["222","00","(?:[2-4]\\d\\d|800)\\d{5}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-48]"]]]],MS:["1","011","(?:[58]\\d\\d|664|900)\\d{7}",[10],0,"1",0,"([34]\\d{6})$|1","664$1",0,"664"],MT:["356","00","3550\\d{4}|(?:[2579]\\d\\d|800)\\d{5}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[2357-9]"]]]],MU:["230","0(?:0|[24-7]0|3[03])","(?:[57]|8\\d\\d)\\d{7}|[2-468]\\d{6}",[7,8,10],[["(\\d{3})(\\d{4})","$1 $2",["[2-46]|8[013]"]],["(\\d{4})(\\d{4})","$1 $2",["[57]"]],["(\\d{5})(\\d{5})","$1 $2",["8"]]],0,0,0,0,0,0,0,"020"],MV:["960","0(?:0|19)","(?:800|9[0-57-9]\\d)\\d{7}|[34679]\\d{6}",[7,10],[["(\\d{3})(\\d{4})","$1-$2",["[34679]"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[89]"]]],0,0,0,0,0,0,0,"00"],MW:["265","00","(?:[1289]\\d|31|77)\\d{7}|1\\d{6}",[7,9],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["1[2-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["2"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[137-9]"],"0$1"]],"0"],MX:["52","0[09]","1(?:(?:[27]2|44|99)[1-9]|65[0-689])\\d{7}|(?:1(?:[01]\\d|2[13-9]|[35][1-9]|4[0-35-9]|6[0-46-9]|7[013-9]|8[1-79]|9[1-8])|[2-9]\\d)\\d{8}",[10,11],[["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["33|5[56]|81"],0,1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[2-9]"],0,1],["(\\d)(\\d{2})(\\d{4})(\\d{4})","$2 $3 $4",["1(?:33|5[56]|81)"],0,1],["(\\d)(\\d{3})(\\d{3})(\\d{4})","$2 $3 $4",["1"],0,1]],"01",0,"0(?:[12]|4[45])|1",0,0,0,0,"00"],MY:["60","00","1\\d{8,9}|(?:3\\d|[4-9])\\d{7}",[8,9,10],[["(\\d)(\\d{3})(\\d{4})","$1-$2 $3",["[4-79]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1-$2 $3",["1(?:[02469]|[378][1-9]|53)|8","1(?:[02469]|[37][1-9]|53|8(?:[1-46-9]|5[7-9]))|8"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1-$2 $3",["3"],"0$1"],["(\\d)(\\d{3})(\\d{2})(\\d{4})","$1-$2-$3-$4",["1(?:[367]|80)"]],["(\\d{3})(\\d{3})(\\d{4})","$1-$2 $3",["15"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1-$2 $3",["1"],"0$1"]],"0"],MZ:["258","00","(?:2|8\\d)\\d{7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["2|8[2-79]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"]]]],NA:["264","00","[68]\\d{7,8}",[8,9],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["88"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["6"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["87"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["8"],"0$1"]],"0"],NC:["687","00","(?:050|[2-57-9]\\d\\d)\\d{3}",[6],[["(\\d{2})(\\d{2})(\\d{2})","$1.$2.$3",["[02-57-9]"]]]],NE:["227","00","[027-9]\\d{7}",[8],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["08"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[089]|2[013]|7[04]"]]]],NF:["672","00","[13]\\d{5}",[6],[["(\\d{2})(\\d{4})","$1 $2",["1[0-3]"]],["(\\d)(\\d{5})","$1 $2",["[13]"]]],0,0,"([0-258]\\d{4})$","3$1"],NG:["234","009","(?:[124-7]|9\\d{3})\\d{6}|[1-9]\\d{7}|[78]\\d{9,13}",[7,8,10,11,12,13,14],[["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["78"],"0$1"],["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["[12]|9(?:0[3-9]|[1-9])"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,3})","$1 $2 $3",["[3-7]|8[2-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["[7-9]"],"0$1"],["(\\d{3})(\\d{4})(\\d{4,5})","$1 $2 $3",["[78]"],"0$1"],["(\\d{3})(\\d{5})(\\d{5,6})","$1 $2 $3",["[78]"],"0$1"]],"0"],NI:["505","00","(?:1800|[25-8]\\d{3})\\d{4}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[125-8]"]]]],NL:["31","00","(?:[124-7]\\d\\d|3(?:[02-9]\\d|1[0-8]))\\d{6}|8\\d{6,9}|9\\d{6,10}|1\\d{4,5}",[5,6,7,8,9,10,11],[["(\\d{3})(\\d{4,7})","$1 $2",["[89]0"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["66"],"0$1"],["(\\d)(\\d{8})","$1 $2",["6"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["1[16-8]|2[259]|3[124]|4[17-9]|5[124679]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[1-578]|91"],"0$1"],["(\\d{3})(\\d{3})(\\d{5})","$1 $2 $3",["9"],"0$1"]],"0"],NO:["47","00","(?:0|[2-9]\\d{3})\\d{4}",[5,8],[["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[489]|59"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[235-7]"]]],0,0,0,0,0,"[02-689]|7[0-8]"],NP:["977","00","(?:1\\d|9)\\d{9}|[1-9]\\d{7}",[8,10,11],[["(\\d)(\\d{7})","$1-$2",["1[2-6]"],"0$1"],["(\\d{2})(\\d{6})","$1-$2",["1[01]|[2-8]|9(?:[1-59]|[67][2-6])"],"0$1"],["(\\d{3})(\\d{7})","$1-$2",["9"]]],"0"],NR:["674","00","(?:444|(?:55|8\\d)\\d|666)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[4-68]"]]]],NU:["683","00","(?:[47]|888\\d)\\d{3}",[4,7],[["(\\d{3})(\\d{4})","$1 $2",["8"]]]],NZ:["64","0(?:0|161)","[29]\\d{7,9}|50\\d{5}(?:\\d{2,3})?|6[0-35-9]\\d{6}|7\\d{7,8}|8\\d{4,9}|(?:11\\d|[34])\\d{7}",[5,6,7,8,9,10],[["(\\d{2})(\\d{3,8})","$1 $2",["8[1-579]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2,3})","$1 $2 $3",["50[036-8]|[89]0","50(?:[0367]|88)|[89]0"],"0$1"],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["24|[346]|7[2-57-9]|9[2-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["2(?:10|74)|[59]|80"],"0$1"],["(\\d{2})(\\d{3,4})(\\d{4})","$1 $2 $3",["1|2[028]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,5})","$1 $2 $3",["2(?:[169]|7[0-35-9])|7|86"],"0$1"]],"0",0,0,0,0,0,0,"00"],OM:["968","00","(?:1505|[279]\\d{3}|500)\\d{4}|800\\d{5,6}",[7,8,9],[["(\\d{3})(\\d{4,6})","$1 $2",["[58]"]],["(\\d{2})(\\d{6})","$1 $2",["2"]],["(\\d{4})(\\d{4})","$1 $2",["[179]"]]]],PA:["507","00","(?:00800|8\\d{3})\\d{6}|[68]\\d{7}|[1-57-9]\\d{6}",[7,8,10,11],[["(\\d{3})(\\d{4})","$1-$2",["[1-57-9]"]],["(\\d{4})(\\d{4})","$1-$2",["[68]"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"]]]],PE:["51","00|19(?:1[124]|77|90)00","(?:[14-8]|9\\d)\\d{7}",[8,9],[["(\\d{3})(\\d{5})","$1 $2",["80"],"(0$1)"],["(\\d)(\\d{7})","$1 $2",["1"],"(0$1)"],["(\\d{2})(\\d{6})","$1 $2",["[4-8]"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["9"]]],"0",0,0,0,0,0,0,"00"," Anexo "],PF:["689","00","4\\d{5}(?:\\d{2})?|8\\d{7,8}",[6,8,9],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["44"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["4|8[7-9]"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]]]],PG:["675","00|140[1-3]","(?:180|[78]\\d{3})\\d{4}|(?:[2-589]\\d|64)\\d{5}",[7,8],[["(\\d{3})(\\d{4})","$1 $2",["18|[2-69]|85"]],["(\\d{4})(\\d{4})","$1 $2",["[78]"]]],0,0,0,0,0,0,0,"00"],PH:["63","00","(?:[2-7]|9\\d)\\d{8}|2\\d{5}|(?:1800|8)\\d{7,9}",[6,8,9,10,11,12,13],[["(\\d)(\\d{5})","$1 $2",["2"],"(0$1)"],["(\\d{4})(\\d{4,6})","$1 $2",["3(?:23|39|46)|4(?:2[3-6]|[35]9|4[26]|76)|544|88[245]|(?:52|64|86)2","3(?:230|397|461)|4(?:2(?:35|[46]4|51)|396|4(?:22|63)|59[347]|76[15])|5(?:221|446)|642[23]|8(?:622|8(?:[24]2|5[13]))"],"(0$1)"],["(\\d{5})(\\d{4})","$1 $2",["346|4(?:27|9[35])|883","3469|4(?:279|9(?:30|56))|8834"],"(0$1)"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["2"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[3-7]|8[2-8]"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[89]"],"0$1"],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]],["(\\d{4})(\\d{1,2})(\\d{3})(\\d{4})","$1 $2 $3 $4",["1"]]],"0"],PK:["92","00","122\\d{6}|[24-8]\\d{10,11}|9(?:[013-9]\\d{8,10}|2(?:[01]\\d\\d|2(?:[06-8]\\d|1[01]))\\d{7})|(?:[2-8]\\d{3}|92(?:[0-7]\\d|8[1-9]))\\d{6}|[24-9]\\d{8}|[89]\\d{7}",[8,9,10,11,12],[["(\\d{3})(\\d{3})(\\d{2,7})","$1 $2 $3",["[89]0"],"0$1"],["(\\d{4})(\\d{5})","$1 $2",["1"]],["(\\d{3})(\\d{6,7})","$1 $2",["2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:2[2-8]|3[27-9]|4[2-6]|6[3569]|9[25-8])","9(?:2[3-8]|98)|(?:2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:22|3[27-9]|4[2-6]|6[3569]|9[25-7]))[2-9]"],"(0$1)"],["(\\d{2})(\\d{7,8})","$1 $2",["(?:2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91)[2-9]"],"(0$1)"],["(\\d{5})(\\d{5})","$1 $2",["58"],"(0$1)"],["(\\d{3})(\\d{7})","$1 $2",["3"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["[24-9]"],"(0$1)"]],"0"],PL:["48","00","(?:6|8\\d\\d)\\d{7}|[1-9]\\d{6}(?:\\d{2})?|[26]\\d{5}",[6,7,8,9,10],[["(\\d{5})","$1",["19"]],["(\\d{3})(\\d{3})","$1 $2",["11|20|64"]],["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])1","(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])19"]],["(\\d{3})(\\d{2})(\\d{2,3})","$1 $2 $3",["64"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["21|39|45|5[0137]|6[0469]|7[02389]|8(?:0[14]|8)"]],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["1[2-8]|[2-7]|8[1-79]|9[145]"]],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["8"]]]],PM:["508","00","[45]\\d{5}|(?:708|80\\d)\\d{6}",[6,9],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["[45]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["7"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0$1"]],"0"],PR:["1","011","(?:[589]\\d\\d|787)\\d{7}",[10],0,"1",0,0,0,0,"787|939"],PS:["970","00","[2489]2\\d{6}|(?:1\\d|5)\\d{8}",[8,9,10],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[2489]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["5"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]]],"0"],PT:["351","00","1693\\d{5}|(?:[26-9]\\d|30)\\d{7}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["2[12]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["16|[236-9]"]]]],PW:["680","01[12]","(?:[24-8]\\d\\d|345|900)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-9]"]]]],PY:["595","00","59\\d{4,6}|9\\d{5,10}|(?:[2-46-8]\\d|5[0-8])\\d{4,7}",[6,7,8,9,10,11],[["(\\d{3})(\\d{3,6})","$1 $2",["[2-9]0"],"0$1"],["(\\d{2})(\\d{5})","$1 $2",["[26]1|3[289]|4[1246-8]|7[1-3]|8[1-36]"],"(0$1)"],["(\\d{3})(\\d{4,5})","$1 $2",["2[279]|3[13-5]|4[359]|5|6(?:[34]|7[1-46-8])|7[46-8]|85"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["2[14-68]|3[26-9]|4[1246-8]|6(?:1|75)|7[1-35]|8[1-36]"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["87"]],["(\\d{3})(\\d{6})","$1 $2",["9(?:[5-79]|8[1-6])"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[2-8]"],"0$1"],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["9"]]],"0"],QA:["974","00","800\\d{4}|(?:2|800)\\d{6}|(?:0080|[3-7])\\d{7}",[7,8,9,11],[["(\\d{3})(\\d{4})","$1 $2",["2[16]|8"]],["(\\d{4})(\\d{4})","$1 $2",["[3-7]"]]]],RE:["262","00","(?:26|[689]\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2689]"],"0$1"]],"0",0,0,0,0,0,[["26(?:2\\d\\d|3(?:0\\d|1[0-3]))\\d{4}"],["(?:69(?:2\\d\\d|3(?:0[0-46]|1[013]|2[0-2]|3[0-39]|4\\d|5[0-5]|6[0-6]|7[0-27]|8[0-8]|9[0-479]))|9(?:399[0-2]|4790|76(?:2[27]|3[0-37]|9\\d)))\\d{4}"],["80\\d{7}"],["89[1-37-9]\\d{6}"],0,0,0,0,0,["8(?:1[019]|2[0156]|84|90)\\d{6}"]]],RO:["40","00","(?:[2378]\\d|90)\\d{7}|[23]\\d{5}",[6,9],[["(\\d{3})(\\d{3})","$1 $2",["2[3-6]","2[3-6]\\d9"],"0$1"],["(\\d{2})(\\d{4})","$1 $2",["219|31"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[23]1"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[237-9]"],"0$1"]],"0",0,0,0,0,0,0,0," int "],RS:["381","00","38[02-9]\\d{6,9}|6\\d{7,9}|90\\d{4,8}|38\\d{5,6}|(?:7\\d\\d|800)\\d{3,9}|(?:[12]\\d|3[0-79])\\d{5,10}",[6,7,8,9,10,11,12],[["(\\d{3})(\\d{3,9})","$1 $2",["(?:2[389]|39)0|[7-9]"],"0$1"],["(\\d{2})(\\d{5,10})","$1 $2",["[1-36]"],"0$1"]],"0"],RU:["7","810","8\\d{13}|[347-9]\\d{9}",[10,14],[["(\\d{4})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["7(?:1[0-8]|2[1-9])","7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:1[23]|[2-9]2))","7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:13[03-69]|62[013-9]))|72[1-57-9]2"],"8 ($1)",1],["(\\d{5})(\\d)(\\d{2})(\\d{2})","$1 $2 $3 $4",["7(?:1[0-68]|2[1-9])","7(?:1(?:[06][3-6]|[18]|2[35]|[3-5][3-5])|2(?:[13][3-5]|[24-689]|7[457]))","7(?:1(?:0(?:[356]|4[023])|[18]|2(?:3[013-9]|5)|3[45]|43[013-79]|5(?:3[1-8]|4[1-7]|5)|6(?:3[0-35-9]|[4-6]))|2(?:1(?:3[178]|[45])|[24-689]|3[35]|7[457]))|7(?:14|23)4[0-8]|71(?:33|45)[1-79]"],"8 ($1)",1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"8 ($1)",1],["(\\d{3})(\\d{3})(\\d{2})(\\d{2})","$1 $2-$3-$4",["[349]|8(?:[02-7]|1[1-8])"],"8 ($1)",1],["(\\d{4})(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3 $4",["8"],"8 ($1)"]],"8",0,0,0,0,"3[04-689]|[489]",0,"8~10"],RW:["250","00","(?:06|[27]\\d\\d|[89]00)\\d{6}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["0"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[7-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["2"]]],"0"],SA:["966","00","92\\d{7}|(?:[15]|8\\d)\\d{8}",[9,10],[["(\\d{4})(\\d{5})","$1 $2",["9"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["5"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["81"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"]]],"0"],SB:["677","0[01]","(?:[1-6]|[7-9]\\d\\d)\\d{4}",[5,7],[["(\\d{2})(\\d{5})","$1 $2",["7|8[4-9]|9(?:[1-8]|9[0-8])"]]]],SC:["248","010|0[0-2]","800\\d{4}|(?:[249]\\d|64)\\d{5}",[7],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[246]|9[57]"]]],0,0,0,0,0,0,0,"00"],SD:["249","00","[19]\\d{8}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[19]"],"0$1"]],"0"],SE:["46","00","(?:[26]\\d\\d|9)\\d{9}|[1-9]\\d{8}|[1-689]\\d{7}|[1-4689]\\d{6}|2\\d{5}",[6,7,8,9,10],[["(\\d{2})(\\d{2,3})(\\d{2})","$1-$2 $3",["20"],"0$1",0,"$1 $2 $3"],["(\\d{3})(\\d{4})","$1-$2",["9(?:00|39|44|9)"],"0$1",0,"$1 $2"],["(\\d{2})(\\d{3})(\\d{2})","$1-$2 $3",["[12][136]|3[356]|4[0246]|6[03]|90[1-9]"],"0$1",0,"$1 $2 $3"],["(\\d)(\\d{2,3})(\\d{2})(\\d{2})","$1-$2 $3 $4",["8"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2,3})(\\d{2})","$1-$2 $3",["1[2457]|2(?:[247-9]|5[0138])|3[0247-9]|4[1357-9]|5[0-35-9]|6(?:[125689]|4[02-57]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])"],"0$1",0,"$1 $2 $3"],["(\\d{3})(\\d{2,3})(\\d{3})","$1-$2 $3",["9(?:00|39|44)"],"0$1",0,"$1 $2 $3"],["(\\d{2})(\\d{2,3})(\\d{2})(\\d{2})","$1-$2 $3 $4",["1[13689]|2[0136]|3[1356]|4[0246]|54|6[03]|90[1-9]"],"0$1",0,"$1 $2 $3 $4"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1-$2 $3 $4",["10|7"],"0$1",0,"$1 $2 $3 $4"],["(\\d)(\\d{3})(\\d{3})(\\d{2})","$1-$2 $3 $4",["8"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1-$2 $3 $4",["[13-5]|2(?:[247-9]|5[0138])|6(?:[124-689]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2})(\\d{2})(\\d{3})","$1-$2 $3 $4",["9"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1-$2 $3 $4 $5",["[26]"],"0$1",0,"$1 $2 $3 $4 $5"]],"0"],SG:["65","0[0-3]\\d","(?:(?:1\\d|8)\\d\\d|7000)\\d{7}|[3689]\\d{7}",[8,10,11],[["(\\d{4})(\\d{4})","$1 $2",["[369]|8(?:0[1-6]|[1-9])"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"]],["(\\d{4})(\\d{4})(\\d{3})","$1 $2 $3",["7"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]]]],SH:["290","00","(?:[256]\\d|8)\\d{3}",[4,5],0,0,0,0,0,0,"[256]"],SI:["386","00|10(?:22|66|88|99)","[1-7]\\d{7}|8\\d{4,7}|90\\d{4,6}",[5,6,7,8],[["(\\d{2})(\\d{3,6})","$1 $2",["8[09]|9"],"0$1"],["(\\d{3})(\\d{5})","$1 $2",["59|8"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[37][01]|4[0139]|51|6"],"0$1"],["(\\d)(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[1-57]"],"(0$1)"]],"0",0,0,0,0,0,0,"00"],SJ:["47","00","0\\d{4}|(?:[489]\\d|[57]9)\\d{6}",[5,8],0,0,0,0,0,0,"79"],SK:["421","00","[2-689]\\d{8}|[2-59]\\d{6}|[2-5]\\d{5}",[6,7,9],[["(\\d)(\\d{2})(\\d{3,4})","$1 $2 $3",["21"],"0$1"],["(\\d{2})(\\d{2})(\\d{2,3})","$1 $2 $3",["[3-5][1-8]1","[3-5][1-8]1[67]"],"0$1"],["(\\d)(\\d{3})(\\d{3})(\\d{2})","$1/$2 $3 $4",["2"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[689]"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1/$2 $3 $4",["[3-5]"],"0$1"]],"0"],SL:["232","00","(?:[237-9]\\d|66)\\d{6}",[8],[["(\\d{2})(\\d{6})","$1 $2",["[236-9]"],"(0$1)"]],"0"],SM:["378","00","(?:0549|[5-7]\\d)\\d{6}",[8,10],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-7]"]],["(\\d{4})(\\d{6})","$1 $2",["0"]]],0,0,"([89]\\d{5})$","0549$1"],SN:["221","00","(?:[378]\\d|93)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[379]"]]]],SO:["252","00","[346-9]\\d{8}|[12679]\\d{7}|[1-5]\\d{6}|[1348]\\d{5}",[6,7,8,9],[["(\\d{2})(\\d{4})","$1 $2",["8[125]"]],["(\\d{6})","$1",["[134]"]],["(\\d)(\\d{6})","$1 $2",["[15]|2[0-79]|3[0-46-8]|4[0-7]"]],["(\\d)(\\d{7})","$1 $2",["(?:2|90)4|[67]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[3478]|64|90"]],["(\\d{2})(\\d{5,7})","$1 $2",["1|28|6(?:0[5-7]|[1-35-9])|9[2-9]"]]],"0"],SR:["597","00","(?:[2-5]|68|[78]\\d)\\d{5}",[6,7],[["(\\d{2})(\\d{2})(\\d{2})","$1-$2-$3",["56"]],["(\\d{3})(\\d{3})","$1-$2",["[2-5]"]],["(\\d{3})(\\d{4})","$1-$2",["[6-8]"]]]],SS:["211","00","[19]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[19]"],"0$1"]],"0"],ST:["239","00","(?:22|9\\d)\\d{5}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[29]"]]]],SV:["503","00","[267]\\d{7}|[89]00\\d{4}(?:\\d{4})?",[7,8,11],[["(\\d{3})(\\d{4})","$1 $2",["[89]"]],["(\\d{4})(\\d{4})","$1 $2",["[267]"]],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["[89]"]]]],SX:["1","011","7215\\d{6}|(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"(5\\d{6})$|1","721$1",0,"721"],SY:["963","00","[1-39]\\d{8}|[1-5]\\d{7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[1-5]"],"0$1",1],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["9"],"0$1",1]],"0"],SZ:["268","00","0800\\d{4}|(?:[237]\\d|900)\\d{6}",[8,9],[["(\\d{4})(\\d{4})","$1 $2",["[0237]"]],["(\\d{5})(\\d{4})","$1 $2",["9"]]]],TA:["290","00","8\\d{3}",[4],0,0,0,0,0,0,"8"],TC:["1","011","(?:[58]\\d\\d|649|900)\\d{7}",[10],0,"1",0,"([2-479]\\d{6})$|1","649$1",0,"649"],TD:["235","00|16","(?:22|[69]\\d|77)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2679]"]]],0,0,0,0,0,0,0,"00"],TG:["228","00","[279]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[279]"]]]],TH:["66","00[1-9]","(?:001800|[2-57]|[689]\\d)\\d{7}|1\\d{7,9}",[8,9,10,13],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[13-9]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]]],"0"],TJ:["992","810","(?:00|[1-57-9]\\d)\\d{7}",[9],[["(\\d{6})(\\d)(\\d{2})","$1 $2 $3",["331","3317"]],["(\\d{3})(\\d{2})(\\d{4})","$1 $2 $3",["[34]7|91[78]"]],["(\\d{4})(\\d)(\\d{4})","$1 $2 $3",["3[1-5]"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[0-57-9]"]]],0,0,0,0,0,0,0,"8~10"],TK:["690","00","[2-47]\\d{3,6}",[4,5,6,7]],TL:["670","00","7\\d{7}|(?:[2-47]\\d|[89]0)\\d{5}",[7,8],[["(\\d{3})(\\d{4})","$1 $2",["[2-489]|70"]],["(\\d{4})(\\d{4})","$1 $2",["7"]]]],TM:["993","810","[1-6]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2-$3-$4",["12"],"(8 $1)"],["(\\d{3})(\\d)(\\d{2})(\\d{2})","$1 $2-$3-$4",["[1-5]"],"(8 $1)"],["(\\d{2})(\\d{6})","$1 $2",["6"],"8 $1"]],"8",0,0,0,0,0,0,"8~10"],TN:["216","00","[2-57-9]\\d{7}",[8],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2-57-9]"]]]],TO:["676","00","(?:0800|(?:[5-8]\\d\\d|999)\\d)\\d{3}|[2-8]\\d{4}",[5,7],[["(\\d{2})(\\d{3})","$1-$2",["[2-4]|50|6[09]|7[0-24-69]|8[05]"]],["(\\d{4})(\\d{3})","$1 $2",["0"]],["(\\d{3})(\\d{4})","$1 $2",["[5-9]"]]]],TR:["90","00","4\\d{6}|8\\d{11,12}|(?:[2-58]\\d\\d|900)\\d{7}",[7,10,12,13],[["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["512|8[01589]|90"],"0$1",1],["(\\d{3})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["5(?:[0-59]|61)","5(?:[0-59]|616)","5(?:[0-59]|6161)"],"0$1",1],["(\\d{3})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[24][1-8]|3[1-9]"],"(0$1)",1],["(\\d{3})(\\d{3})(\\d{6,7})","$1 $2 $3",["80"],"0$1",1]],"0"],TT:["1","011","(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-46-8]\\d{6})$|1","868$1",0,"868"],TV:["688","00","(?:2|7\\d\\d|90)\\d{4}",[5,6,7],[["(\\d{2})(\\d{3})","$1 $2",["2"]],["(\\d{2})(\\d{4})","$1 $2",["90"]],["(\\d{2})(\\d{5})","$1 $2",["7"]]]],TW:["886","0(?:0[25-79]|19)","[2-689]\\d{8}|7\\d{9,10}|[2-8]\\d{7}|2\\d{6}",[7,8,9,10,11],[["(\\d{2})(\\d)(\\d{4})","$1 $2 $3",["202"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[258]0"],"0$1"],["(\\d)(\\d{3,4})(\\d{4})","$1 $2 $3",["[23568]|4(?:0[02-48]|[1-47-9])|7[1-9]","[23568]|4(?:0[2-48]|[1-47-9])|(?:400|7)[1-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[49]"],"0$1"],["(\\d{2})(\\d{4})(\\d{4,5})","$1 $2 $3",["7"],"0$1"]],"0",0,0,0,0,0,0,0,"#"],TZ:["255","00[056]","(?:[25-8]\\d|41|90)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{4})","$1 $2 $3",["[89]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[24]"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["5"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[67]"],"0$1"]],"0"],UA:["380","00","[89]\\d{9}|[3-9]\\d{8}",[9,10],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6[12][29]|(?:3[1-8]|4[136-8]|5[12457]|6[49])2|(?:56|65)[24]","6[12][29]|(?:35|4[1378]|5[12457]|6[49])2|(?:56|65)[24]|(?:3[1-46-8]|46)2[013-9]"],"0$1"],["(\\d{4})(\\d{5})","$1 $2",["3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6[0135689]|7[4-6])|6(?:[12][3-7]|[459])","3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6(?:[015689]|3[02389])|7[4-6])|6(?:[12][3-7]|[459])"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[3-7]|89|9[1-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["[89]"],"0$1"]],"0",0,0,0,0,0,0,"0~0"],UG:["256","00[057]","800\\d{6}|(?:[29]0|[347]\\d)\\d{7}",[9],[["(\\d{4})(\\d{5})","$1 $2",["202","2024"],"0$1"],["(\\d{3})(\\d{6})","$1 $2",["[27-9]|4(?:6[45]|[7-9])"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["[34]"],"0$1"]],"0"],US:["1","011","[2-9]\\d{9}|3\\d{6}",[10],[["(\\d{3})(\\d{4})","$1-$2",["310"],0,1],["(\\d{3})(\\d{3})(\\d{4})","($1) $2-$3",["[2-9]"],0,1,"$1-$2-$3"]],"1",0,0,0,0,0,[["(?:47220[01]|5(?:05(?:[2-57-9]\\d\\d|6(?:[0-35-9]\\d|4[46]))|57200))\\d{4}|(?:2(?:0[1-35-9]|1[02-9]|2[03-589]|3[149]|4[08]|5[1-46]|6[0279]|7[0269]|8[13])|3(?:0[1-57-9]|1[02-9]|2[01356]|3[0-24679]|4[167]|5[0-2]|6[014]|8[056])|4(?:0[124-9]|1[02-579]|2[3-5]|3[0245]|4[023578]|58|6[349]|7[0589]|8[04])|5(?:0[1-47-9]|1[0235-8]|20|3[0149]|4[01]|5[19]|6[1-47]|7[0-5]|8[0256])|6(?:0[1-35-9]|1[024-9]|2[03689]|[34][016]|5[01679]|6[0-279]|78|8[0-29])|7(?:0[1-46-8]|1[2-9]|2[04-7]|3[1247]|4[037]|5[47]|6[02359]|7[0-59]|8[156])|8(?:0[1-68]|1[02-8]|2[068]|3[0-2589]|4[03578]|5[046-9]|6[02-5]|7[028])|9(?:0[1346-9]|1[02-9]|2[0589]|3[0146-8]|4[01357-9]|5[12469]|7[0-389]|8[04-69]))[2-9]\\d{6}"],[""],["8(?:00|33|44|55|66|77|88)[2-9]\\d{6}"],["900[2-9]\\d{6}"],["52(?:3(?:[2-46-9][02-9]\\d|5(?:[02-46-9]\\d|5[0-46-9]))|4(?:[2-478][02-9]\\d|5(?:[034]\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\d)|9(?:[05-9]\\d|2[0-5]|49)))\\d{4}|52[34][2-9]1[02-9]\\d{4}|5(?:00|2[125-9]|33|44|66|77|88)[2-9]\\d{6}"]]],UY:["598","0(?:0|1[3-9]\\d)","(?:0004|4)\\d{9}|[1249]\\d{7}|(?:[49]\\d|80)\\d{5}",[7,8,10,13],[["(\\d{3})(\\d{4})","$1 $2",["405|8|90"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["9"],"0$1"],["(\\d{4})(\\d{4})","$1 $2",["[124]"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["4"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3 $4",["0"]]],"0",0,0,0,0,0,0,"00"," int. "],UZ:["998","810","(?:33|[5-79]\\d|88)\\d{7}",[9],[["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[35-9]"],"8 $1"]],"8",0,0,0,0,0,0,"8~10"],VA:["39","00","0\\d{5,10}|3[0-8]\\d{7,10}|55\\d{8}|8\\d{5}(?:\\d{2,4})?|(?:1\\d|39)\\d{7,8}",[6,7,8,9,10,11],0,0,0,0,0,0,"06698"],VC:["1","011","(?:[58]\\d\\d|784|900)\\d{7}",[10],0,"1",0,"([2-7]\\d{6})$|1","784$1",0,"784"],VE:["58","00","[68]00\\d{7}|(?:[24]\\d|[59]0)\\d{8}",[10],[["(\\d{3})(\\d{7})","$1-$2",["[24-689]"],"0$1"]],"0"],VG:["1","011","(?:284|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-578]\\d{6})$|1","284$1",0,"284"],VI:["1","011","[58]\\d{9}|(?:34|90)0\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","340$1",0,"340"],VN:["84","00","[12]\\d{9}|[135-9]\\d{8}|[16]\\d{7}|[16-8]\\d{6}",[7,8,9,10],[["(\\d{2})(\\d{5})","$1 $2",["80"],"0$1",1],["(\\d{4})(\\d{4,6})","$1 $2",["1"],0,1],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[69]"],"0$1",1],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[3578]"],"0$1",1],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["2[48]"],"0$1",1],["(\\d{3})(\\d{4})(\\d{3})","$1 $2 $3",["2"],"0$1",1]],"0"],VU:["678","00","[57-9]\\d{6}|(?:[238]\\d|48)\\d{3}",[5,7],[["(\\d{3})(\\d{4})","$1 $2",["[57-9]"]]]],WF:["681","00","(?:40|72)\\d{4}|8\\d{5}(?:\\d{3})?",[6,9],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["[478]"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]]]],WS:["685","0","(?:[2-6]|8\\d{5})\\d{4}|[78]\\d{6}|[68]\\d{5}",[5,6,7,10],[["(\\d{5})","$1",["[2-5]|6[1-9]"]],["(\\d{3})(\\d{3,7})","$1 $2",["[68]"]],["(\\d{2})(\\d{5})","$1 $2",["7"]]]],XK:["383","00","[23]\\d{7,8}|(?:4\\d\\d|[89]00)\\d{5}",[8,9],[["(\\d{3})(\\d{5})","$1 $2",["[89]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2-4]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[23]"],"0$1"]],"0"],YE:["967","00","(?:1|7\\d)\\d{7}|[1-7]\\d{6}",[7,8,9],[["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["[1-6]|7(?:[24-6]|8[0-7])"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["7"],"0$1"]],"0"],YT:["262","00","(?:(?:(?:26|63)9|80\\d)\\d\\d|93980)\\d{4}",[9],0,"0",0,0,0,0,"269|63|9398"],ZA:["27","00","[1-79]\\d{8}|8\\d{4,9}",[5,6,7,8,9,10],[["(\\d{2})(\\d{3,4})","$1 $2",["8[1-4]"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,3})","$1 $2 $3",["8[1-4]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["860"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[1-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"],"0$1"]],"0"],ZM:["260","00","800\\d{6}|(?:21|63|[79]\\d)\\d{7}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[28]"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["[79]"],"0$1"]],"0"],ZW:["263","00","2(?:[0-57-9]\\d{6,8}|6[0-24-9]\\d{6,7})|[38]\\d{9}|[35-8]\\d{8}|[3-6]\\d{7}|[1-689]\\d{6}|[1-3569]\\d{5}|[1356]\\d{4}",[5,6,7,8,9,10],[["(\\d{3})(\\d{3,5})","$1 $2",["2(?:0[45]|2[278]|[49]8)|3(?:[09]8|17)|6(?:[29]8|37|75)|[23][78]|(?:33|5[15]|6[68])[78]"],"0$1"],["(\\d)(\\d{3})(\\d{2,4})","$1 $2 $3",["[49]"],"0$1"],["(\\d{3})(\\d{4})","$1 $2",["80"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["24|8[13-59]|(?:2[05-79]|39|5[45]|6[15-8])2","2(?:02[014]|4|[56]20|[79]2)|392|5(?:42|525)|6(?:[16-8]21|52[013])|8[13-59]"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["2(?:1[39]|2[0157]|[378]|[56][14])|3(?:12|29)","2(?:1[39]|2[0157]|[378]|[56][14])|3(?:123|29)"],"0$1"],["(\\d{4})(\\d{6})","$1 $2",["8"],"0$1"],["(\\d{2})(\\d{3,5})","$1 $2",["1|2(?:0[0-36-9]|12|29|[56])|3(?:1[0-689]|[24-6])|5(?:[0236-9]|1[2-4])|6(?:[013-59]|7[0-46-9])|(?:33|55|6[68])[0-69]|(?:29|3[09]|62)[0-79]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["29[013-9]|39|54"],"0$1"],["(\\d{4})(\\d{3,5})","$1 $2",["(?:25|54)8","258|5483"],"0$1"]],"0"]},nonGeographic:{800:["800",0,"(?:00|[1-9]\\d)\\d{6}",[8],[["(\\d{4})(\\d{4})","$1 $2",["\\d"]]],0,0,0,0,0,0,[0,0,["(?:00|[1-9]\\d)\\d{6}"]]],808:["808",0,"[1-9]\\d{7}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[1-9]"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,0,["[1-9]\\d{7}"]]],870:["870",0,"7\\d{11}|[35-7]\\d{8}",[9,12],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[35-7]"]]],0,0,0,0,0,0,[0,["(?:[356]|774[45])\\d{8}|7[6-8]\\d{7}"]]],878:["878",0,"10\\d{10}",[12],[["(\\d{2})(\\d{5})(\\d{5})","$1 $2 $3",["1"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,["10\\d{10}"]]],881:["881",0,"[0-36-9]\\d{8}",[9],[["(\\d)(\\d{3})(\\d{5})","$1 $2 $3",["[0-36-9]"]]],0,0,0,0,0,0,[0,["[0-36-9]\\d{8}"]]],882:["882",0,"[13]\\d{6}(?:\\d{2,5})?|[19]\\d{7}|(?:[25]\\d\\d|4)\\d{7}(?:\\d{2})?",[7,8,9,10,11,12],[["(\\d{2})(\\d{5})","$1 $2",["16|342"]],["(\\d{2})(\\d{6})","$1 $2",["49"]],["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["1[36]|9"]],["(\\d{2})(\\d{4})(\\d{3})","$1 $2 $3",["3[23]"]],["(\\d{2})(\\d{3,4})(\\d{4})","$1 $2 $3",["16"]],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["10|23|3(?:[15]|4[57])|4|51"]],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["34"]],["(\\d{2})(\\d{4,5})(\\d{5})","$1 $2 $3",["[1-35]"]]],0,0,0,0,0,0,[0,["342\\d{4}|(?:337|49)\\d{6}|(?:3(?:2|47|7\\d{3})|50\\d{3})\\d{7}",[7,8,9,10,12]],0,0,0,0,0,0,["1(?:3(?:0[0347]|[13][0139]|2[035]|4[013568]|6[0459]|7[06]|8[15-8]|9[0689])\\d{4}|6\\d{5,10})|(?:345\\d|9[89])\\d{6}|(?:10|2(?:3|85\\d)|3(?:[15]|[69]\\d\\d)|4[15-8]|51)\\d{8}"]]],883:["883",0,"(?:[1-4]\\d|51)\\d{6,10}",[8,9,10,11,12],[["(\\d{3})(\\d{3})(\\d{2,8})","$1 $2 $3",["[14]|2[24-689]|3[02-689]|51[24-9]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["510"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["21"]],["(\\d{4})(\\d{4})(\\d{4})","$1 $2 $3",["51[13]"]],["(\\d{3})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["[235]"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,["(?:2(?:00\\d\\d|10)|(?:370[1-9]|51\\d0)\\d)\\d{7}|51(?:00\\d{5}|[24-9]0\\d{4,7})|(?:1[013-79]|2[24-689]|3[02-689]|4[0-4])0\\d{5,9}"]]],888:["888",0,"\\d{11}",[11],[["(\\d{3})(\\d{3})(\\d{5})","$1 $2 $3"]],0,0,0,0,0,0,[0,0,0,0,0,0,["\\d{11}"]]],979:["979",0,"[1359]\\d{8}",[9],[["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["[1359]"]]],0,0,0,0,0,0,[0,0,0,["[1359]\\d{8}"]]]}};function Dq(e,t){var n=Array.prototype.slice.call(t);return n.push(Rb),e.apply(this,n)}function Xf(e){return Xf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Xf(e)}function gv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Lq(e,t,n){return t&&gv(e.prototype,t),n&&gv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Rq(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Fq(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ha(e,t)}function zq(e){var t=zb();return function(){var r=pa(e),i;if(t){var o=pa(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return jq(this,i)}}function jq(e,t){if(t&&(Xf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Fb(e)}function Fb(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Zf(e){var t=typeof Map=="function"?new Map:void 0;return Zf=function(r){if(r===null||!Vq(r))return r;if(typeof r!="function")throw new TypeError("Super expression must either be null or a function");if(typeof t<"u"){if(t.has(r))return t.get(r);t.set(r,i)}function i(){return nl(r,arguments,pa(this).constructor)}return i.prototype=Object.create(r.prototype,{constructor:{value:i,enumerable:!1,writable:!0,configurable:!0}}),ha(i,r)},Zf(e)}function nl(e,t,n){return zb()?nl=Reflect.construct:nl=function(i,o,a){var s=[null];s.push.apply(s,o);var c=Function.bind.apply(i,s),l=new c;return a&&ha(l,a.prototype),l},nl.apply(null,arguments)}function zb(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Vq(e){return Function.toString.call(e).indexOf("[native code]")!==-1}function ha(e,t){return ha=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},ha(e,t)}function pa(e){return pa=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},pa(e)}var Ar=function(e){Fq(n,e);var t=zq(n);function n(r){var i;return Rq(this,n),i=t.call(this,r),Object.setPrototypeOf(Fb(i),n.prototype),i.name=i.constructor.name,i}return Lq(n)}(Zf(Error)),m1=2,Uq=17,Bq=3,an="0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9",Hq="-\u2010-\u2015\u2212\u30FC\uFF0D",qq="\uFF0F/",Wq="\uFF0E.",Gq=" \xA0\xAD\u200B\u2060\u3000",Kq="()\uFF08\uFF09\uFF3B\uFF3D\\[\\]",Qq="~\u2053\u223C\uFF5E",vn="".concat(Hq).concat(qq).concat(Wq).concat(Gq).concat(Kq).concat(Qq),eu="+\uFF0B";function yv(e,t){e=e.split("-"),t=t.split("-");for(var n=e[0].split("."),r=t[0].split("."),i=0;i<3;i++){var o=Number(n[i]),a=Number(r[i]);if(o>a)return 1;if(a>o)return-1;if(!isNaN(o)&&isNaN(a))return 1;if(isNaN(o)&&!isNaN(a))return-1}return e[1]&&t[1]?e[1]>t[1]?1:e[1]<t[1]?-1:0:!e[1]&&t[1]?1:e[1]&&!t[1]?-1:0}function bc(e){return bc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},bc(e)}function tu(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function bv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function nu(e,t,n){return t&&bv(e.prototype,t),n&&bv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var Yq="1.2.0",Xq="1.7.35",$v=" ext. ",Zq=/^\d+$/,Mt=function(){function e(t){tu(this,e),nW(t),this.metadata=t,jb.call(this,t)}return nu(e,[{key:"getCountries",value:function(){return Object.keys(this.metadata.countries).filter(function(n){return n!=="001"})}},{key:"getCountryMetadata",value:function(n){return this.metadata.countries[n]}},{key:"nonGeographic",value:function(){if(!(this.v1||this.v2||this.v3))return this.metadata.nonGeographic||this.metadata.nonGeographical}},{key:"hasCountry",value:function(n){return this.getCountryMetadata(n)!==void 0}},{key:"hasCallingCode",value:function(n){if(this.getCountryCodesForCallingCode(n))return!0;if(this.nonGeographic()){if(this.nonGeographic()[n])return!0}else{var r=this.countryCallingCodes()[n];if(r&&r.length===1&&r[0]==="001")return!0}}},{key:"isNonGeographicCallingCode",value:function(n){return this.nonGeographic()?!!this.nonGeographic()[n]:!this.getCountryCodesForCallingCode(n)}},{key:"country",value:function(n){return this.selectNumberingPlan(n)}},{key:"selectNumberingPlan",value:function(n,r){if(n&&Zq.test(n)&&(r=n,n=null),n&&n!=="001"){if(!this.hasCountry(n))throw new Error("Unknown country: ".concat(n));this.numberingPlan=new wv(this.getCountryMetadata(n),this)}else if(r){if(!this.hasCallingCode(r))throw new Error("Unknown calling code: ".concat(r));this.numberingPlan=new wv(this.getNumberingPlanMetadata(r),this)}else this.numberingPlan=void 0;return this}},{key:"getCountryCodesForCallingCode",value:function(n){var r=this.countryCallingCodes()[n];if(r)return r.length===1&&r[0].length===3?void 0:r}},{key:"getCountryCodeForCallingCode",value:function(n){var r=this.getCountryCodesForCallingCode(n);if(r)return r[0]}},{key:"getNumberingPlanMetadata",value:function(n){var r=this.getCountryCodeForCallingCode(n);if(r)return this.getCountryMetadata(r);if(this.nonGeographic()){var i=this.nonGeographic()[n];if(i)return i}else{var o=this.countryCallingCodes()[n];if(o&&o.length===1&&o[0]==="001")return this.metadata.countries["001"]}}},{key:"countryCallingCode",value:function(){return this.numberingPlan.callingCode()}},{key:"IDDPrefix",value:function(){return this.numberingPlan.IDDPrefix()}},{key:"defaultIDDPrefix",value:function(){return this.numberingPlan.defaultIDDPrefix()}},{key:"nationalNumberPattern",value:function(){return this.numberingPlan.nationalNumberPattern()}},{key:"possibleLengths",value:function(){return this.numberingPlan.possibleLengths()}},{key:"formats",value:function(){return this.numberingPlan.formats()}},{key:"nationalPrefixForParsing",value:function(){return this.numberingPlan.nationalPrefixForParsing()}},{key:"nationalPrefixTransformRule",value:function(){return this.numberingPlan.nationalPrefixTransformRule()}},{key:"leadingDigits",value:function(){return this.numberingPlan.leadingDigits()}},{key:"hasTypes",value:function(){return this.numberingPlan.hasTypes()}},{key:"type",value:function(n){return this.numberingPlan.type(n)}},{key:"ext",value:function(){return this.numberingPlan.ext()}},{key:"countryCallingCodes",value:function(){return this.v1?this.metadata.country_phone_code_to_countries:this.metadata.country_calling_codes}},{key:"chooseCountryByCountryCallingCode",value:function(n){return this.selectNumberingPlan(n)}},{key:"hasSelectedNumberingPlan",value:function(){return this.numberingPlan!==void 0}}]),e}(),wv=function(){function e(t,n){tu(this,e),this.globalMetadataObject=n,this.metadata=t,jb.call(this,n.metadata)}return nu(e,[{key:"callingCode",value:function(){return this.metadata[0]}},{key:"getDefaultCountryMetadataForRegion",value:function(){return this.globalMetadataObject.getNumberingPlanMetadata(this.callingCode())}},{key:"IDDPrefix",value:function(){if(!(this.v1||this.v2))return this.metadata[1]}},{key:"defaultIDDPrefix",value:function(){if(!(this.v1||this.v2))return this.metadata[12]}},{key:"nationalNumberPattern",value:function(){return this.v1||this.v2?this.metadata[1]:this.metadata[2]}},{key:"possibleLengths",value:function(){if(!this.v1)return this.metadata[this.v2?2:3]}},{key:"_getFormats",value:function(n){return n[this.v1?2:this.v2?3:4]}},{key:"formats",value:function(){var n=this,r=this._getFormats(this.metadata)||this._getFormats(this.getDefaultCountryMetadataForRegion())||[];return r.map(function(i){return new Jq(i,n)})}},{key:"nationalPrefix",value:function(){return this.metadata[this.v1?3:this.v2?4:5]}},{key:"_getNationalPrefixFormattingRule",value:function(n){return n[this.v1?4:this.v2?5:6]}},{key:"nationalPrefixFormattingRule",value:function(){return this._getNationalPrefixFormattingRule(this.metadata)||this._getNationalPrefixFormattingRule(this.getDefaultCountryMetadataForRegion())}},{key:"_nationalPrefixForParsing",value:function(){return this.metadata[this.v1?5:this.v2?6:7]}},{key:"nationalPrefixForParsing",value:function(){return this._nationalPrefixForParsing()||this.nationalPrefix()}},{key:"nationalPrefixTransformRule",value:function(){return this.metadata[this.v1?6:this.v2?7:8]}},{key:"_getNationalPrefixIsOptionalWhenFormatting",value:function(){return!!this.metadata[this.v1?7:this.v2?8:9]}},{key:"nationalPrefixIsOptionalWhenFormattingInNationalFormat",value:function(){return this._getNationalPrefixIsOptionalWhenFormatting(this.metadata)||this._getNationalPrefixIsOptionalWhenFormatting(this.getDefaultCountryMetadataForRegion())}},{key:"leadingDigits",value:function(){return this.metadata[this.v1?8:this.v2?9:10]}},{key:"types",value:function(){return this.metadata[this.v1?9:this.v2?10:11]}},{key:"hasTypes",value:function(){return this.types()&&this.types().length===0?!1:!!this.types()}},{key:"type",value:function(n){if(this.hasTypes()&&_v(this.types(),n))return new tW(_v(this.types(),n),this)}},{key:"ext",value:function(){return this.v1||this.v2?$v:this.metadata[13]||$v}}]),e}(),Jq=function(){function e(t,n){tu(this,e),this._format=t,this.metadata=n}return nu(e,[{key:"pattern",value:function(){return this._format[0]}},{key:"format",value:function(){return this._format[1]}},{key:"leadingDigitsPatterns",value:function(){return this._format[2]||[]}},{key:"nationalPrefixFormattingRule",value:function(){return this._format[3]||this.metadata.nationalPrefixFormattingRule()}},{key:"nationalPrefixIsOptionalWhenFormattingInNationalFormat",value:function(){return!!this._format[4]||this.metadata.nationalPrefixIsOptionalWhenFormattingInNationalFormat()}},{key:"nationalPrefixIsMandatoryWhenFormattingInNationalFormat",value:function(){return this.usesNationalPrefix()&&!this.nationalPrefixIsOptionalWhenFormattingInNationalFormat()}},{key:"usesNationalPrefix",value:function(){return!!(this.nationalPrefixFormattingRule()&&!eW.test(this.nationalPrefixFormattingRule()))}},{key:"internationalFormat",value:function(){return this._format[5]||this.format()}}]),e}(),eW=/^\(?\$1\)?$/,tW=function(){function e(t,n){tu(this,e),this.type=t,this.metadata=n}return nu(e,[{key:"pattern",value:function(){return this.metadata.v1?this.type:this.type[0]}},{key:"possibleLengths",value:function(){if(!this.metadata.v1)return this.type[1]||this.metadata.possibleLengths()}}]),e}();function _v(e,t){switch(t){case"FIXED_LINE":return e[0];case"MOBILE":return e[1];case"TOLL_FREE":return e[2];case"PREMIUM_RATE":return e[3];case"PERSONAL_NUMBER":return e[4];case"VOICEMAIL":return e[5];case"UAN":return e[6];case"PAGER":return e[7];case"VOIP":return e[8];case"SHARED_COST":return e[9]}}function nW(e){if(!e)throw new Error("[libphonenumber-js] `metadata` argument not passed. Check your arguments.");if(!fd(e)||!fd(e.countries))throw new Error("[libphonenumber-js] `metadata` argument was passed but it's not a valid metadata. Must be an object having `.countries` child object property. Got ".concat(fd(e)?"an object of shape: { "+Object.keys(e).join(", ")+" }":"a "+rW(e)+": "+e,"."))}var fd=function(t){return bc(t)==="object"},rW=function(t){return bc(t)};function v1(e,t){if(t=new Mt(t),t.hasCountry(e))return t.country(e).countryCallingCode();throw new Error("Unknown country: ".concat(e))}function jb(e){var t=e.version;typeof t=="number"?(this.v1=t===1,this.v2=t===2,this.v3=t===3,this.v4=t===4):t?yv(t,Yq)===-1?this.v2=!0:yv(t,Xq)===-1?this.v3=!0:this.v4=!0:this.v1=!0}var iW=";ext=",hi=function(t){return"([".concat(an,"]{1,").concat(t,"})")};function Vb(e){var t="20",n="15",r="9",i="6",o="[ \xA0\\t,]*",a="[:\\.\uFF0E]?[ \xA0\\t,-]*",s="#?",c="(?:e?xt(?:ensi(?:o\u0301?|\xF3))?n?|\uFF45?\uFF58\uFF54\uFF4E?|\u0434\u043E\u0431|anexo)",l="(?:[x\uFF58#\uFF03~\uFF5E]|int|\uFF49\uFF4E\uFF54)",u="[- ]+",d="[ \xA0\\t]*",f="(?:,{2}|;)",h=iW+hi(t),p=o+c+a+hi(t)+s,m=o+l+a+hi(r)+s,v=u+hi(i)+"#",b=d+f+a+hi(n)+s,y=d+"(?:,)+"+a+hi(r)+s;return h+"|"+p+"|"+m+"|"+v+"|"+b+"|"+y}var oW="["+an+"]{"+m1+"}",aW="["+eu+"]{0,1}(?:["+vn+"]*["+an+"]){3,}["+vn+an+"]*",sW=new RegExp("^["+eu+"]{0,1}(?:["+vn+"]*["+an+"]){1,2}$","i"),lW=aW+"(?:"+Vb()+")?",cW=new RegExp("^"+oW+"$|^"+lW+"$","i");function Ub(e){return e.length>=m1&&cW.test(e)}function uW(e){return sW.test(e)}var xv=new RegExp("(?:"+Vb()+")$","i");function dW(e){var t=e.search(xv);if(t<0)return{};for(var n=e.slice(0,t),r=e.match(xv),i=1;i<r.length;){if(r[i])return{number:n,ext:r[i]};i++}}function fW(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=hW(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3587
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3588
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3589
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3590
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3591
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Wb(e,t){if(!!e){if(typeof e=="string")return Cv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Cv(e,t)}}function Cv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function
|
|
3592
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3593
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3594
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3595
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3596
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3597
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3585
|
+
`}};An.styles=Aq;w([rt(".dialog")],An.prototype,"dialog",2);w([rt(".dialog__panel")],An.prototype,"panel",2);w([rt(".dialog__overlay")],An.prototype,"overlay",2);w([E({type:Boolean,reflect:!0})],An.prototype,"open",2);w([E({reflect:!0})],An.prototype,"label",2);w([E({attribute:"no-header",type:Boolean,reflect:!0})],An.prototype,"noHeader",2);w([Ve("open",{waitUntilFirstUpdate:!0})],An.prototype,"handleOpenChange",1);An=w([It("sl-dialog")],An);$n("dialog.show",{keyframes:[{opacity:0,scale:.8},{opacity:1,scale:1}],options:{duration:250,easing:"ease"}});$n("dialog.hide",{keyframes:[{opacity:1,scale:1},{opacity:0,scale:.8}],options:{duration:250,easing:"ease"}});$n("dialog.denyClose",{keyframes:[{scale:1},{scale:1.02},{scale:1}],options:{duration:250}});$n("dialog.overlay.show",{keyframes:[{opacity:0},{opacity:1}],options:{duration:250}});$n("dialog.overlay.hide",{keyframes:[{opacity:1},{opacity:0}],options:{duration:250}});const Iq=`.dialog::part(overlay){background-color:#0000007a}.dialog::part(body){padding-bottom:.25rem}.dialog::part(footer){padding-top:0}.hideFooter::part(footer){display:none}.showHeader::part(body){padding-top:0}.dialog::part(title){font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-weight:500}
|
|
3586
|
+
`,ns=N("<style></style>"),Mq=N('<slot name="label"><p class="text-xl font-sans font-medium"></p></slot>'),Dq=N('<sl-dialog class="dialog"><div><slot></slot></div><div class="flex flex-col xs:flex-row justify-end gap-2" slot="footer"><photon-button variant="outline"></photon-button><photon-button></photon-button></div></sl-dialog>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-dialog",{label:void 0,header:!0,open:!1,confirmText:"Yes, Cancel",cancelText:"No, Keep Editing",disableButtons:!1,loading:!1,hideFooter:!1,disableSubmit:!1,width:"500px",overlayClose:!1},e=>{let t;const n=r=>{const i=new CustomEvent(r?"photon-dialog-confirmed":"photon-dialog-canceled",{composed:!0,bubbles:!0,detail:{}});t?.dispatchEvent(i)};return[(()=>{const r=ns.cloneNode(!0);return x(r,Je),r})(),(()=>{const r=ns.cloneNode(!0);return x(r,Xt),r})(),(()=>{const r=ns.cloneNode(!0);return x(r,Yt),r})(),(()=>{const r=ns.cloneNode(!0);return x(r,Iq),r})(),(()=>{const r=H(()=>document.importNode(Dq,!0)),i=r.firstChild,o=i.firstChild,a=i.nextSibling,s=a.firstChild,c=s.nextSibling,l=t;return typeof l=="function"?he(l,r):t=r,r.addEventListener("sl-request-close",u=>{u.detail.source==="overlay"&&!e.overlayClose||u.detail.source==="keyboard"?u.preventDefault():n(!1)}),r._$owner=A(),x(r,S(ee,{get when(){return!e.header},get children(){const u=Mq.cloneNode(!0),d=u.firstChild;return u._$owner=A(),x(d,()=>e.label),u}}),i),o._$owner=A(),s.addEventListener("photon-clicked",()=>{n(!1)}),s._$owner=A(),x(s,()=>e.cancelText),c.addEventListener("photon-clicked",()=>{n(!0)}),c._$owner=A(),x(c,()=>e.confirmText),q(u=>{const d=!!e.hideFooter,f=!!e.header,h=`--width: ${e.width};`,p=e.label,m=e.open,v=!e.header,b=`font-sans ${e.header?"pb-4":"py-4"}`,y=!!e.hideFooter,g=e.disableButtons||e.loading,_=e.disableButtons||e.disableSubmit,k=e.loading;return d!==u._v$&&r.classList.toggle("hideFooter",u._v$=d),f!==u._v$2&&r.classList.toggle("showHeader",u._v$2=f),u._v$3=_4(r,h,u._v$3),p!==u._v$4&&(r.label=u._v$4=p),m!==u._v$5&&(r.open=u._v$5=m),v!==u._v$6&&(r.noHeader=u._v$6=v),b!==u._v$7&&cl(i,u._v$7=b),y!==u._v$8&&a.classList.toggle("hidden",u._v$8=y),g!==u._v$9&&(s.disabled=u._v$9=g),_!==u._v$10&&(c.disabled=u._v$10=_),k!==u._v$11&&(c.loading=u._v$11=k),u},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0,_v$5:void 0,_v$6:void 0,_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0,_v$11:void 0}),r})()]});const Rb={version:4,country_calling_codes:{1:["US","AG","AI","AS","BB","BM","BS","CA","DM","DO","GD","GU","JM","KN","KY","LC","MP","MS","PR","SX","TC","TT","VC","VG","VI"],7:["RU","KZ"],20:["EG"],27:["ZA"],30:["GR"],31:["NL"],32:["BE"],33:["FR"],34:["ES"],36:["HU"],39:["IT","VA"],40:["RO"],41:["CH"],43:["AT"],44:["GB","GG","IM","JE"],45:["DK"],46:["SE"],47:["NO","SJ"],48:["PL"],49:["DE"],51:["PE"],52:["MX"],53:["CU"],54:["AR"],55:["BR"],56:["CL"],57:["CO"],58:["VE"],60:["MY"],61:["AU","CC","CX"],62:["ID"],63:["PH"],64:["NZ"],65:["SG"],66:["TH"],81:["JP"],82:["KR"],84:["VN"],86:["CN"],90:["TR"],91:["IN"],92:["PK"],93:["AF"],94:["LK"],95:["MM"],98:["IR"],211:["SS"],212:["MA","EH"],213:["DZ"],216:["TN"],218:["LY"],220:["GM"],221:["SN"],222:["MR"],223:["ML"],224:["GN"],225:["CI"],226:["BF"],227:["NE"],228:["TG"],229:["BJ"],230:["MU"],231:["LR"],232:["SL"],233:["GH"],234:["NG"],235:["TD"],236:["CF"],237:["CM"],238:["CV"],239:["ST"],240:["GQ"],241:["GA"],242:["CG"],243:["CD"],244:["AO"],245:["GW"],246:["IO"],247:["AC"],248:["SC"],249:["SD"],250:["RW"],251:["ET"],252:["SO"],253:["DJ"],254:["KE"],255:["TZ"],256:["UG"],257:["BI"],258:["MZ"],260:["ZM"],261:["MG"],262:["RE","YT"],263:["ZW"],264:["NA"],265:["MW"],266:["LS"],267:["BW"],268:["SZ"],269:["KM"],290:["SH","TA"],291:["ER"],297:["AW"],298:["FO"],299:["GL"],350:["GI"],351:["PT"],352:["LU"],353:["IE"],354:["IS"],355:["AL"],356:["MT"],357:["CY"],358:["FI","AX"],359:["BG"],370:["LT"],371:["LV"],372:["EE"],373:["MD"],374:["AM"],375:["BY"],376:["AD"],377:["MC"],378:["SM"],380:["UA"],381:["RS"],382:["ME"],383:["XK"],385:["HR"],386:["SI"],387:["BA"],389:["MK"],420:["CZ"],421:["SK"],423:["LI"],500:["FK"],501:["BZ"],502:["GT"],503:["SV"],504:["HN"],505:["NI"],506:["CR"],507:["PA"],508:["PM"],509:["HT"],590:["GP","BL","MF"],591:["BO"],592:["GY"],593:["EC"],594:["GF"],595:["PY"],596:["MQ"],597:["SR"],598:["UY"],599:["CW","BQ"],670:["TL"],672:["NF"],673:["BN"],674:["NR"],675:["PG"],676:["TO"],677:["SB"],678:["VU"],679:["FJ"],680:["PW"],681:["WF"],682:["CK"],683:["NU"],685:["WS"],686:["KI"],687:["NC"],688:["TV"],689:["PF"],690:["TK"],691:["FM"],692:["MH"],850:["KP"],852:["HK"],853:["MO"],855:["KH"],856:["LA"],880:["BD"],886:["TW"],960:["MV"],961:["LB"],962:["JO"],963:["SY"],964:["IQ"],965:["KW"],966:["SA"],967:["YE"],968:["OM"],970:["PS"],971:["AE"],972:["IL"],973:["BH"],974:["QA"],975:["BT"],976:["MN"],977:["NP"],992:["TJ"],993:["TM"],994:["AZ"],995:["GE"],996:["KG"],998:["UZ"]},countries:{AC:["247","00","(?:[01589]\\d|[46])\\d{4}",[5,6]],AD:["376","00","(?:1|6\\d)\\d{7}|[135-9]\\d{5}",[6,8,9],[["(\\d{3})(\\d{3})","$1 $2",["[135-9]"]],["(\\d{4})(\\d{4})","$1 $2",["1"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6"]]]],AE:["971","00","(?:[4-7]\\d|9[0-689])\\d{7}|800\\d{2,9}|[2-4679]\\d{7}",[5,6,7,8,9,10,11,12],[["(\\d{3})(\\d{2,9})","$1 $2",["60|8"]],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[236]|[479][2-8]"],"0$1"],["(\\d{3})(\\d)(\\d{5})","$1 $2 $3",["[479]"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["5"],"0$1"]],"0"],AF:["93","00","[2-7]\\d{8}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[2-7]"],"0$1"]],"0"],AG:["1","011","(?:268|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([457]\\d{6})$|1","268$1",0,"268"],AI:["1","011","(?:264|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2457]\\d{6})$|1","264$1",0,"264"],AL:["355","00","(?:700\\d\\d|900)\\d{3}|8\\d{5,7}|(?:[2-5]|6\\d)\\d{7}",[6,7,8,9],[["(\\d{3})(\\d{3,4})","$1 $2",["80|9"],"0$1"],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["4[2-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2358][2-5]|4"],"0$1"],["(\\d{3})(\\d{5})","$1 $2",["[23578]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["6"],"0$1"]],"0"],AM:["374","00","(?:[1-489]\\d|55|60|77)\\d{6}",[8],[["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[89]0"],"0 $1"],["(\\d{3})(\\d{5})","$1 $2",["2|3[12]"],"(0$1)"],["(\\d{2})(\\d{6})","$1 $2",["1|47"],"(0$1)"],["(\\d{2})(\\d{6})","$1 $2",["[3-9]"],"0$1"]],"0"],AO:["244","00","[29]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[29]"]]]],AR:["54","00","(?:11|[89]\\d\\d)\\d{8}|[2368]\\d{9}",[10,11],[["(\\d{4})(\\d{2})(\\d{4})","$1 $2-$3",["2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9])","2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8]))|2(?:2[24-9]|3[1-59]|47)","2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5[56][46]|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]","2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|58|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|54(?:4|5[13-7]|6[89])|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:454|85[56])[46]|3(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]"],"0$1",1],["(\\d{2})(\\d{4})(\\d{4})","$1 $2-$3",["1"],"0$1",1],["(\\d{3})(\\d{3})(\\d{4})","$1-$2-$3",["[68]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2-$3",["[23]"],"0$1",1],["(\\d)(\\d{4})(\\d{2})(\\d{4})","$2 15-$3-$4",["9(?:2[2-469]|3[3-578])","9(?:2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9]))","9(?:2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8])))|92(?:2[24-9]|3[1-59]|47)","9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5(?:[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]","9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|5(?:4(?:4|5[13-7]|6[89])|[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]"],"0$1",0,"$1 $2 $3-$4"],["(\\d)(\\d{2})(\\d{4})(\\d{4})","$2 15-$3-$4",["91"],"0$1",0,"$1 $2 $3-$4"],["(\\d{3})(\\d{3})(\\d{5})","$1-$2-$3",["8"],"0$1"],["(\\d)(\\d{3})(\\d{3})(\\d{4})","$2 15-$3-$4",["9"],"0$1",0,"$1 $2 $3-$4"]],"0",0,"0?(?:(11|2(?:2(?:02?|[13]|2[13-79]|4[1-6]|5[2457]|6[124-8]|7[1-4]|8[13-6]|9[1267])|3(?:02?|1[467]|2[03-6]|3[13-8]|[49][2-6]|5[2-8]|[67])|4(?:7[3-578]|9)|6(?:[0136]|2[24-6]|4[6-8]?|5[15-8])|80|9(?:0[1-3]|[19]|2\\d|3[1-6]|4[02568]?|5[2-4]|6[2-46]|72?|8[23]?))|3(?:3(?:2[79]|6|8[2578])|4(?:0[0-24-9]|[12]|3[5-8]?|4[24-7]|5[4-68]?|6[02-9]|7[126]|8[2379]?|9[1-36-8])|5(?:1|2[1245]|3[237]?|4[1-46-9]|6[2-4]|7[1-6]|8[2-5]?)|6[24]|7(?:[069]|1[1568]|2[15]|3[145]|4[13]|5[14-8]|7[2-57]|8[126])|8(?:[01]|2[15-7]|3[2578]?|4[13-6]|5[4-8]?|6[1-357-9]|7[36-8]?|8[5-8]?|9[124])))15)?","9$1"],AS:["1","011","(?:[58]\\d\\d|684|900)\\d{7}",[10],0,"1",0,"([267]\\d{6})$|1","684$1",0,"684"],AT:["43","00","1\\d{3,12}|2\\d{6,12}|43(?:(?:0\\d|5[02-9])\\d{3,9}|2\\d{4,5}|[3467]\\d{4}|8\\d{4,6}|9\\d{4,7})|5\\d{4,12}|8\\d{7,12}|9\\d{8,12}|(?:[367]\\d|4[0-24-9])\\d{4,11}",[4,5,6,7,8,9,10,11,12,13],[["(\\d)(\\d{3,12})","$1 $2",["1(?:11|[2-9])"],"0$1"],["(\\d{3})(\\d{2})","$1 $2",["517"],"0$1"],["(\\d{2})(\\d{3,5})","$1 $2",["5[079]"],"0$1"],["(\\d{3})(\\d{3,10})","$1 $2",["(?:31|4)6|51|6(?:5[0-3579]|[6-9])|7(?:20|32|8)|[89]"],"0$1"],["(\\d{4})(\\d{3,9})","$1 $2",["[2-467]|5[2-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["5"],"0$1"],["(\\d{2})(\\d{4})(\\d{4,7})","$1 $2 $3",["5"],"0$1"]],"0"],AU:["61","001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011","1(?:[0-79]\\d{7}(?:\\d(?:\\d{2})?)?|8[0-24-9]\\d{7})|[2-478]\\d{8}|1\\d{4,7}",[5,6,7,8,9,10,12],[["(\\d{2})(\\d{3,4})","$1 $2",["16"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,4})","$1 $2 $3",["16"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["14|4"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["[2378]"],"(0$1)"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1(?:30|[89])"]]],"0",0,"(183[12])|0",0,0,0,[["(?:(?:2(?:[0-26-9]\\d|3[0-8]|4[02-9]|5[0135-9])|3(?:[0-3589]\\d|4[0-578]|6[1-9]|7[0-35-9])|7(?:[013-57-9]\\d|2[0-8]))\\d{3}|8(?:51(?:0(?:0[03-9]|[12479]\\d|3[2-9]|5[0-8]|6[1-9]|8[0-7])|1(?:[0235689]\\d|1[0-69]|4[0-589]|7[0-47-9])|2(?:0[0-79]|[18][13579]|2[14-9]|3[0-46-9]|[4-6]\\d|7[89]|9[0-4]))|(?:6[0-8]|[78]\\d)\\d{3}|9(?:[02-9]\\d{3}|1(?:(?:[0-58]\\d|6[0135-9])\\d|7(?:0[0-24-9]|[1-9]\\d)|9(?:[0-46-9]\\d|5[0-79])))))\\d{3}",[9]],["4(?:79[01]|83[0-389]|93[0-6])\\d{5}|4(?:[0-3]\\d|4[047-9]|5[0-25-9]|6[016-9]|7[02-8]|8[0-24-9]|9[0-27-9])\\d{6}",[9]],["180(?:0\\d{3}|2)\\d{3}",[7,10]],["190[0-26]\\d{6}",[10]],0,0,0,["163\\d{2,6}",[5,6,7,8,9]],["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}",[9]],["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}",[6,8,10,12]]],"0011"],AW:["297","00","(?:[25-79]\\d\\d|800)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[25-9]"]]]],AX:["358","00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))","2\\d{4,9}|35\\d{4,5}|(?:60\\d\\d|800)\\d{4,6}|7\\d{5,11}|(?:[14]\\d|3[0-46-9]|50)\\d{4,8}",[5,6,7,8,9,10,11,12],0,"0",0,0,0,0,"18",0,"00"],AZ:["994","00","365\\d{6}|(?:[124579]\\d|60|88)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["90"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["1[28]|2|365|46","1[28]|2|365[45]|46","1[28]|2|365(?:4|5[02])|46"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[13-9]"],"0$1"]],"0"],BA:["387","00","6\\d{8}|(?:[35689]\\d|49|70)\\d{6}",[8,9],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["6[1-3]|[7-9]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2-$3",["[3-5]|6[56]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3 $4",["6"],"0$1"]],"0"],BB:["1","011","(?:246|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","246$1",0,"246"],BD:["880","00","[1-469]\\d{9}|8[0-79]\\d{7,8}|[2-79]\\d{8}|[2-9]\\d{7}|[3-9]\\d{6}|[57-9]\\d{5}",[6,7,8,9,10],[["(\\d{2})(\\d{4,6})","$1-$2",["31[5-8]|[459]1"],"0$1"],["(\\d{3})(\\d{3,7})","$1-$2",["3(?:[67]|8[013-9])|4(?:6[168]|7|[89][18])|5(?:6[128]|9)|6(?:28|4[14]|5)|7[2-589]|8(?:0[014-9]|[12])|9[358]|(?:3[2-5]|4[235]|5[2-578]|6[0389]|76|8[3-7]|9[24])1|(?:44|66)[01346-9]"],"0$1"],["(\\d{4})(\\d{3,6})","$1-$2",["[13-9]|22"],"0$1"],["(\\d)(\\d{7,8})","$1-$2",["2"],"0$1"]],"0"],BE:["32","00","4\\d{8}|[1-9]\\d{7}",[8,9],[["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["(?:80|9)0"],"0$1"],["(\\d)(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[239]|4[23]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[15-8]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["4"],"0$1"]],"0"],BF:["226","00","[025-7]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[025-7]"]]]],BG:["359","00","00800\\d{7}|[2-7]\\d{6,7}|[89]\\d{6,8}|2\\d{5}",[6,7,8,9,12],[["(\\d)(\\d)(\\d{2})(\\d{2})","$1 $2 $3 $4",["2"],"0$1"],["(\\d{3})(\\d{4})","$1 $2",["43[1-6]|70[1-9]"],"0$1"],["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,3})","$1 $2 $3",["[356]|4[124-7]|7[1-9]|8[1-6]|9[1-7]"],"0$1"],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["(?:70|8)0"],"0$1"],["(\\d{3})(\\d{3})(\\d{2})","$1 $2 $3",["43[1-7]|7"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[48]|9[08]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["9"],"0$1"]],"0"],BH:["973","00","[136-9]\\d{7}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[13679]|8[047]"]]]],BI:["257","00","(?:[267]\\d|31)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2367]"]]]],BJ:["229","00","[24-689]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[24-689]"]]]],BL:["590","00","590\\d{6}|(?:69|80|9\\d)\\d{7}",[9],0,"0",0,0,0,0,0,[["590(?:2[7-9]|5[12]|87)\\d{4}"],["69(?:0\\d\\d|1(?:2[2-9]|3[0-5]))\\d{4}"],["80[0-5]\\d{6}"],0,0,0,0,0,["9(?:395|76[018])\\d{5}"]]],BM:["1","011","(?:441|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","441$1",0,"441"],BN:["673","00","[2-578]\\d{6}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-578]"]]]],BO:["591","00(?:1\\d)?","(?:[2-467]\\d\\d|8001)\\d{5}",[8,9],[["(\\d)(\\d{7})","$1 $2",["[23]|4[46]"]],["(\\d{8})","$1",["[67]"]],["(\\d{3})(\\d{2})(\\d{4})","$1 $2 $3",["8"]]],"0",0,"0(1\\d)?"],BQ:["599","00","(?:[34]1|7\\d)\\d{5}",[7],0,0,0,0,0,0,"[347]"],BR:["55","00(?:1[245]|2[1-35]|31|4[13]|[56]5|99)","(?:[1-46-9]\\d\\d|5(?:[0-46-9]\\d|5[0-46-9]))\\d{8}|[1-9]\\d{9}|[3589]\\d{8}|[34]\\d{7}",[8,9,10,11],[["(\\d{4})(\\d{4})","$1-$2",["300|4(?:0[02]|37)","4(?:02|37)0|[34]00"]],["(\\d{3})(\\d{2,3})(\\d{4})","$1 $2 $3",["(?:[358]|90)0"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1 $2-$3",["(?:[14689][1-9]|2[12478]|3[1-578]|5[13-5]|7[13-579])[2-57]"],"($1)"],["(\\d{2})(\\d{5})(\\d{4})","$1 $2-$3",["[16][1-9]|[2-57-9]"],"($1)"]],"0",0,"(?:0|90)(?:(1[245]|2[1-35]|31|4[13]|[56]5|99)(\\d{10,11}))?","$2"],BS:["1","011","(?:242|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([3-8]\\d{6})$|1","242$1",0,"242"],BT:["975","00","[17]\\d{7}|[2-8]\\d{6}",[7,8],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[2-68]|7[246]"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["1[67]|7"]]]],BW:["267","00","(?:0800|(?:[37]|800)\\d)\\d{6}|(?:[2-6]\\d|90)\\d{5}",[7,8,10],[["(\\d{2})(\\d{5})","$1 $2",["90"]],["(\\d{3})(\\d{4})","$1 $2",["[24-6]|3[15-79]"]],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[37]"]],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["0"]],["(\\d{3})(\\d{4})(\\d{3})","$1 $2 $3",["8"]]]],BY:["375","810","(?:[12]\\d|33|44|902)\\d{7}|8(?:0[0-79]\\d{5,7}|[1-7]\\d{9})|8(?:1[0-489]|[5-79]\\d)\\d{7}|8[1-79]\\d{6,7}|8[0-79]\\d{5}|8\\d{5}",[6,7,8,9,10,11],[["(\\d{3})(\\d{3})","$1 $2",["800"],"8 $1"],["(\\d{3})(\\d{2})(\\d{2,4})","$1 $2 $3",["800"],"8 $1"],["(\\d{4})(\\d{2})(\\d{3})","$1 $2-$3",["1(?:5[169]|6[3-5]|7[179])|2(?:1[35]|2[34]|3[3-5])","1(?:5[169]|6(?:3[1-3]|4|5[125])|7(?:1[3-9]|7[0-24-6]|9[2-7]))|2(?:1[35]|2[34]|3[3-5])"],"8 0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2-$3-$4",["1(?:[56]|7[467])|2[1-3]"],"8 0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2-$3-$4",["[1-4]"],"8 0$1"],["(\\d{3})(\\d{3,4})(\\d{4})","$1 $2 $3",["[89]"],"8 $1"]],"8",0,"0|80?",0,0,0,0,"8~10"],BZ:["501","00","(?:0800\\d|[2-8])\\d{6}",[7,11],[["(\\d{3})(\\d{4})","$1-$2",["[2-8]"]],["(\\d)(\\d{3})(\\d{4})(\\d{3})","$1-$2-$3-$4",["0"]]]],CA:["1","011","(?:[2-8]\\d|90)\\d{8}|3\\d{6}",[7,10],0,"1",0,0,0,0,0,[["(?:2(?:04|[23]6|[48]9|50|63)|3(?:06|43|54|6[578]|82)|4(?:03|1[68]|3[178]|50|68|74)|5(?:06|1[49]|48|79|8[147])|6(?:04|[18]3|39|47|72)|7(?:0[59]|42|53|78|8[02])|8(?:[06]7|19|25|73)|90[25])[2-9]\\d{6}",[10]],["",[10]],["8(?:00|33|44|55|66|77|88)[2-9]\\d{6}",[10]],["900[2-9]\\d{6}",[10]],["52(?:3(?:[2-46-9][02-9]\\d|5(?:[02-46-9]\\d|5[0-46-9]))|4(?:[2-478][02-9]\\d|5(?:[034]\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\d)|9(?:[05-9]\\d|2[0-5]|49)))\\d{4}|52[34][2-9]1[02-9]\\d{4}|(?:5(?:00|2[125-9]|33|44|66|77|88)|622)[2-9]\\d{6}",[10]],0,["310\\d{4}",[7]],0,["600[2-9]\\d{6}",[10]]]],CC:["61","001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011","1(?:[0-79]\\d{8}(?:\\d{2})?|8[0-24-9]\\d{7})|[148]\\d{8}|1\\d{5,7}",[6,7,8,9,10,12],0,"0",0,"([59]\\d{7})$|0","8$1",0,0,[["8(?:51(?:0(?:02|31|60|89)|1(?:18|76)|223)|91(?:0(?:1[0-2]|29)|1(?:[28]2|50|79)|2(?:10|64)|3(?:[06]8|22)|4[29]8|62\\d|70[23]|959))\\d{3}",[9]],["4(?:79[01]|83[0-389]|93[0-6])\\d{5}|4(?:[0-3]\\d|4[047-9]|5[0-25-9]|6[016-9]|7[02-8]|8[0-24-9]|9[0-27-9])\\d{6}",[9]],["180(?:0\\d{3}|2)\\d{3}",[7,10]],["190[0-26]\\d{6}",[10]],0,0,0,0,["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}",[9]],["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}",[6,8,10,12]]],"0011"],CD:["243","00","[189]\\d{8}|[1-68]\\d{6}",[7,9],[["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["88"],"0$1"],["(\\d{2})(\\d{5})","$1 $2",["[1-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[89]"],"0$1"]],"0"],CF:["236","00","(?:[27]\\d{3}|8776)\\d{4}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[278]"]]]],CG:["242","00","222\\d{6}|(?:0\\d|80)\\d{7}",[9],[["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["8"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[02]"]]]],CH:["41","00","8\\d{11}|[2-9]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8[047]|90"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-79]|81"],"0$1"],["(\\d{3})(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["8"],"0$1"]],"0"],CI:["225","00","[02]\\d{9}",[10],[["(\\d{2})(\\d{2})(\\d)(\\d{5})","$1 $2 $3 $4",["2"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3 $4",["0"]]]],CK:["682","00","[2-578]\\d{4}",[5],[["(\\d{2})(\\d{3})","$1 $2",["[2-578]"]]]],CL:["56","(?:0|1(?:1[0-69]|2[02-5]|5[13-58]|69|7[0167]|8[018]))0","12300\\d{6}|6\\d{9,10}|[2-9]\\d{8}",[9,10,11],[["(\\d{5})(\\d{4})","$1 $2",["219","2196"],"($1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["44"]],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["2[1-36]"],"($1)"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["9[2-9]"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["3[2-5]|[47]|5[1-3578]|6[13-57]|8(?:0[1-9]|[1-9])"],"($1)"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["60|8"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]],["(\\d{3})(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3 $4",["60"]]]],CM:["237","00","[26]\\d{8}|88\\d{6,7}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["88"]],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["[26]|88"]]]],CN:["86","00|1(?:[12]\\d|79)\\d\\d00","1[127]\\d{8,9}|2\\d{9}(?:\\d{2})?|[12]\\d{6,7}|86\\d{6}|(?:1[03-689]\\d|6)\\d{7,9}|(?:[3-579]\\d|8[0-57-9])\\d{6,9}",[7,8,9,10,11,12],[["(\\d{2})(\\d{5,6})","$1 $2",["(?:10|2[0-57-9])[19]","(?:10|2[0-57-9])(?:10|9[56])","10(?:10|9[56])|2[0-57-9](?:100|9[56])"],"0$1"],["(\\d{3})(\\d{5,6})","$1 $2",["3(?:[157]|35|49|9[1-68])|4(?:[17]|2[179]|6[47-9]|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]|4[13]|5[1-5])|(?:4[35]|59|85)[1-9]","(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))[19]","85[23](?:10|95)|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))(?:10|9[56])","85[23](?:100|95)|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))(?:100|9[56])"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["(?:4|80)0"]],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["10|2(?:[02-57-9]|1[1-9])","10|2(?:[02-57-9]|1[1-9])","10[0-79]|2(?:[02-57-9]|1[1-79])|(?:10|21)8(?:0[1-9]|[1-9])"],"0$1",1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["3(?:[3-59]|7[02-68])|4(?:[26-8]|3[3-9]|5[2-9])|5(?:3[03-9]|[468]|7[028]|9[2-46-9])|6|7(?:[0-247]|3[04-9]|5[0-4689]|6[2368])|8(?:[1-358]|9[1-7])|9(?:[013479]|5[1-5])|(?:[34]1|55|79|87)[02-9]"],"0$1",1],["(\\d{3})(\\d{7,8})","$1 $2",["9"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["80"],"0$1",1],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["[3-578]"],"0$1",1],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["1[3-9]"]],["(\\d{2})(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3 $4",["[12]"],"0$1",1]],"0",0,"(1(?:[12]\\d|79)\\d\\d)|0",0,0,0,0,"00"],CO:["57","00(?:4(?:[14]4|56)|[579])","(?:60\\d\\d|9101)\\d{6}|(?:1\\d|3)\\d{9}",[10,11],[["(\\d{3})(\\d{7})","$1 $2",["6"],"($1)"],["(\\d{3})(\\d{7})","$1 $2",["3[0-357]|91"]],["(\\d)(\\d{3})(\\d{7})","$1-$2-$3",["1"],"0$1",0,"$1 $2 $3"]],"0",0,"0(4(?:[14]4|56)|[579])?"],CR:["506","00","(?:8\\d|90)\\d{8}|(?:[24-8]\\d{3}|3005)\\d{4}",[8,10],[["(\\d{4})(\\d{4})","$1 $2",["[2-7]|8[3-9]"]],["(\\d{3})(\\d{3})(\\d{4})","$1-$2-$3",["[89]"]]],0,0,"(19(?:0[0-2468]|1[09]|20|66|77|99))"],CU:["53","119","[27]\\d{6,7}|[34]\\d{5,7}|(?:5|8\\d\\d)\\d{7}",[6,7,8,10],[["(\\d{2})(\\d{4,6})","$1 $2",["2[1-4]|[34]"],"(0$1)"],["(\\d)(\\d{6,7})","$1 $2",["7"],"(0$1)"],["(\\d)(\\d{7})","$1 $2",["5"],"0$1"],["(\\d{3})(\\d{7})","$1 $2",["8"],"0$1"]],"0"],CV:["238","0","(?:[2-59]\\d\\d|800)\\d{4}",[7],[["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["[2-589]"]]]],CW:["599","00","(?:[34]1|60|(?:7|9\\d)\\d)\\d{5}",[7,8],[["(\\d{3})(\\d{4})","$1 $2",["[3467]"]],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["9[4-8]"]]],0,0,0,0,0,"[69]"],CX:["61","001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011","1(?:[0-79]\\d{8}(?:\\d{2})?|8[0-24-9]\\d{7})|[148]\\d{8}|1\\d{5,7}",[6,7,8,9,10,12],0,"0",0,"([59]\\d{7})$|0","8$1",0,0,[["8(?:51(?:0(?:01|30|59|88)|1(?:17|46|75)|2(?:22|35))|91(?:00[6-9]|1(?:[28]1|49|78)|2(?:09|63)|3(?:12|26|75)|4(?:56|97)|64\\d|7(?:0[01]|1[0-2])|958))\\d{3}",[9]],["4(?:79[01]|83[0-389]|93[0-6])\\d{5}|4(?:[0-3]\\d|4[047-9]|5[0-25-9]|6[016-9]|7[02-8]|8[0-24-9]|9[0-27-9])\\d{6}",[9]],["180(?:0\\d{3}|2)\\d{3}",[7,10]],["190[0-26]\\d{6}",[10]],0,0,0,0,["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}",[9]],["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}",[6,8,10,12]]],"0011"],CY:["357","00","(?:[279]\\d|[58]0)\\d{6}",[8],[["(\\d{2})(\\d{6})","$1 $2",["[257-9]"]]]],CZ:["420","00","(?:[2-578]\\d|60)\\d{7}|9\\d{8,11}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[2-8]|9[015-7]"]],["(\\d{2})(\\d{3})(\\d{3})(\\d{2})","$1 $2 $3 $4",["96"]],["(\\d{2})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["9"]],["(\\d{3})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["9"]]]],DE:["49","00","[2579]\\d{5,14}|49(?:[34]0|69|8\\d)\\d\\d?|49(?:37|49|60|7[089]|9\\d)\\d{1,3}|49(?:2[024-9]|3[2-689]|7[1-7])\\d{1,8}|(?:1|[368]\\d|4[0-8])\\d{3,13}|49(?:[015]\\d|2[13]|31|[46][1-8])\\d{1,9}",[4,5,6,7,8,9,10,11,12,13,14,15],[["(\\d{2})(\\d{3,13})","$1 $2",["3[02]|40|[68]9"],"0$1"],["(\\d{3})(\\d{3,12})","$1 $2",["2(?:0[1-389]|1[124]|2[18]|3[14])|3(?:[35-9][15]|4[015])|906|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1","2(?:0[1-389]|12[0-8])|3(?:[35-9][15]|4[015])|906|2(?:[13][14]|2[18])|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1"],"0$1"],["(\\d{4})(\\d{2,11})","$1 $2",["[24-6]|3(?:[3569][02-46-9]|4[2-4679]|7[2-467]|8[2-46-8])|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]","[24-6]|3(?:3(?:0[1-467]|2[127-9]|3[124578]|7[1257-9]|8[1256]|9[145])|4(?:2[135]|4[13578]|9[1346])|5(?:0[14]|2[1-3589]|6[1-4]|7[13468]|8[13568])|6(?:2[1-489]|3[124-6]|6[13]|7[12579]|8[1-356]|9[135])|7(?:2[1-7]|4[145]|6[1-5]|7[1-4])|8(?:21|3[1468]|6|7[1467]|8[136])|9(?:0[12479]|2[1358]|4[134679]|6[1-9]|7[136]|8[147]|9[1468]))|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]|3[68]4[1347]|3(?:47|60)[1356]|3(?:3[46]|46|5[49])[1246]|3[4579]3[1357]"],"0$1"],["(\\d{3})(\\d{4})","$1 $2",["138"],"0$1"],["(\\d{5})(\\d{2,10})","$1 $2",["3"],"0$1"],["(\\d{3})(\\d{5,11})","$1 $2",["181"],"0$1"],["(\\d{3})(\\d)(\\d{4,10})","$1 $2 $3",["1(?:3|80)|9"],"0$1"],["(\\d{3})(\\d{7,8})","$1 $2",["1[67]"],"0$1"],["(\\d{3})(\\d{7,12})","$1 $2",["8"],"0$1"],["(\\d{5})(\\d{6})","$1 $2",["185","1850","18500"],"0$1"],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["7"],"0$1"],["(\\d{4})(\\d{7})","$1 $2",["18[68]"],"0$1"],["(\\d{5})(\\d{6})","$1 $2",["15[0568]"],"0$1"],["(\\d{4})(\\d{7})","$1 $2",["15[1279]"],"0$1"],["(\\d{3})(\\d{8})","$1 $2",["18"],"0$1"],["(\\d{3})(\\d{2})(\\d{7,8})","$1 $2 $3",["1(?:6[023]|7)"],"0$1"],["(\\d{4})(\\d{2})(\\d{7})","$1 $2 $3",["15[279]"],"0$1"],["(\\d{3})(\\d{2})(\\d{8})","$1 $2 $3",["15"],"0$1"]],"0"],DJ:["253","00","(?:2\\d|77)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[27]"]]]],DK:["45","00","[2-9]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-9]"]]]],DM:["1","011","(?:[58]\\d\\d|767|900)\\d{7}",[10],0,"1",0,"([2-7]\\d{6})$|1","767$1",0,"767"],DO:["1","011","(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,0,0,0,"8001|8[024]9"],DZ:["213","00","(?:[1-4]|[5-79]\\d|80)\\d{7}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[1-4]"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["9"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-8]"],"0$1"]],"0"],EC:["593","00","1\\d{9,10}|(?:[2-7]|9\\d)\\d{7}",[8,9,10,11],[["(\\d)(\\d{3})(\\d{4})","$1 $2-$3",["[2-7]"],"(0$1)",0,"$1-$2-$3"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["9"],"0$1"],["(\\d{4})(\\d{3})(\\d{3,4})","$1 $2 $3",["1"]]],"0"],EE:["372","00","8\\d{9}|[4578]\\d{7}|(?:[3-8]\\d|90)\\d{5}",[7,8,10],[["(\\d{3})(\\d{4})","$1 $2",["[369]|4[3-8]|5(?:[0-2]|5[0-478]|6[45])|7[1-9]|88","[369]|4[3-8]|5(?:[02]|1(?:[0-8]|95)|5[0-478]|6(?:4[0-4]|5[1-589]))|7[1-9]|88"]],["(\\d{4})(\\d{3,4})","$1 $2",["[45]|8(?:00|[1-49])","[45]|8(?:00[1-9]|[1-49])"]],["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["7"]],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["8"]]]],EG:["20","00","[189]\\d{8,9}|[24-6]\\d{8}|[135]\\d{7}",[8,9,10],[["(\\d)(\\d{7,8})","$1 $2",["[23]"],"0$1"],["(\\d{2})(\\d{6,7})","$1 $2",["1[35]|[4-6]|8[2468]|9[235-7]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[189]"],"0$1"]],"0"],EH:["212","00","[5-8]\\d{8}",[9],0,"0",0,0,0,0,"528[89]"],ER:["291","00","[178]\\d{6}",[7],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[178]"],"0$1"]],"0"],ES:["34","00","[5-9]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[89]00"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-9]"]]]],ET:["251","00","(?:11|[2-579]\\d)\\d{7}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[1-579]"],"0$1"]],"0"],FI:["358","00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))","[1-35689]\\d{4}|7\\d{10,11}|(?:[124-7]\\d|3[0-46-9])\\d{8}|[1-9]\\d{5,8}",[5,6,7,8,9,10,11,12],[["(\\d)(\\d{4,9})","$1 $2",["[2568][1-8]|3(?:0[1-9]|[1-9])|9"],"0$1"],["(\\d{3})(\\d{3,7})","$1 $2",["[12]00|[368]|70[07-9]"],"0$1"],["(\\d{2})(\\d{4,8})","$1 $2",["[1245]|7[135]"],"0$1"],["(\\d{2})(\\d{6,10})","$1 $2",["7"],"0$1"]],"0",0,0,0,0,"1[03-79]|[2-9]",0,"00"],FJ:["679","0(?:0|52)","45\\d{5}|(?:0800\\d|[235-9])\\d{6}",[7,11],[["(\\d{3})(\\d{4})","$1 $2",["[235-9]|45"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["0"]]],0,0,0,0,0,0,0,"00"],FK:["500","00","[2-7]\\d{4}",[5]],FM:["691","00","(?:[39]\\d\\d|820)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[389]"]]]],FO:["298","00","[2-9]\\d{5}",[6],[["(\\d{6})","$1",["[2-9]"]]],0,0,"(10(?:01|[12]0|88))"],FR:["33","00","[1-9]\\d{8}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0 $1"],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["[1-79]"],"0$1"]],"0"],GA:["241","00","(?:[067]\\d|11)\\d{6}|[2-7]\\d{6}",[7,8],[["(\\d)(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-7]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["0"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["11|[67]"],"0$1"]],0,0,"0(11\\d{6}|60\\d{6}|61\\d{6}|6[256]\\d{6}|7[467]\\d{6})","$1"],GB:["44","00","[1-357-9]\\d{9}|[18]\\d{8}|8\\d{6}",[7,9,10],[["(\\d{3})(\\d{4})","$1 $2",["800","8001","80011","800111","8001111"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["845","8454","84546","845464"],"0$1"],["(\\d{3})(\\d{6})","$1 $2",["800"],"0$1"],["(\\d{5})(\\d{4,5})","$1 $2",["1(?:38|5[23]|69|76|94)","1(?:(?:38|69)7|5(?:24|39)|768|946)","1(?:3873|5(?:242|39[4-6])|(?:697|768)[347]|9467)"],"0$1"],["(\\d{4})(\\d{5,6})","$1 $2",["1(?:[2-69][02-9]|[78])"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["[25]|7(?:0|6[02-9])","[25]|7(?:0|6(?:[03-9]|2[356]))"],"0$1"],["(\\d{4})(\\d{6})","$1 $2",["7"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[1389]"],"0$1"]],"0",0,0,0,0,0,[["(?:1(?:1(?:3(?:[0-58]\\d\\d|73[0235])|4(?:[0-5]\\d\\d|69[7-9]|70[0-579])|(?:(?:5[0-26-9]|[78][0-49])\\d|6(?:[0-4]\\d|50))\\d)|2(?:(?:0[024-9]|2[3-9]|3[3-79]|4[1-689]|[58][02-9]|6[0-47-9]|7[013-9]|9\\d)\\d\\d|1(?:[0-7]\\d\\d|8(?:[02]\\d|1[0-246-9])))|(?:3(?:0\\d|1[0-8]|[25][02-9]|3[02-579]|[468][0-46-9]|7[1-35-79]|9[2-578])|4(?:0[03-9]|[137]\\d|[28][02-57-9]|4[02-69]|5[0-8]|[69][0-79])|5(?:0[1-35-9]|[16]\\d|2[024-9]|3[015689]|4[02-9]|5[03-9]|7[0-35-9]|8[0-468]|9[0-57-9])|6(?:0[034689]|1\\d|2[0-35689]|[38][013-9]|4[1-467]|5[0-69]|6[13-9]|7[0-8]|9[0-24578])|7(?:0[0246-9]|2\\d|3[0236-8]|4[03-9]|5[0-46-9]|6[013-9]|7[0-35-9]|8[024-9]|9[02-9])|8(?:0[35-9]|2[1-57-9]|3[02-578]|4[0-578]|5[124-9]|6[2-69]|7\\d|8[02-9]|9[02569])|9(?:0[02-589]|[18]\\d|2[02-689]|3[1-57-9]|4[2-9]|5[0-579]|6[2-47-9]|7[0-24578]|9[2-57]))\\d\\d)|2(?:0[013478]|3[0189]|4[017]|8[0-46-9]|9[0-2])\\d{3})\\d{4}|1(?:2(?:0(?:46[1-4]|87[2-9])|545[1-79]|76(?:2\\d|3[1-8]|6[1-6])|9(?:7(?:2[0-4]|3[2-5])|8(?:2[2-8]|7[0-47-9]|8[3-5])))|3(?:6(?:38[2-5]|47[23])|8(?:47[04-9]|64[0157-9]))|4(?:044[1-7]|20(?:2[23]|8\\d)|6(?:0(?:30|5[2-57]|6[1-8]|7[2-8])|140)|8(?:052|87[1-3]))|5(?:2(?:4(?:3[2-79]|6\\d)|76\\d)|6(?:26[06-9]|686))|6(?:06(?:4\\d|7[4-79])|295[5-7]|35[34]\\d|47(?:24|61)|59(?:5[08]|6[67]|74)|9(?:55[0-4]|77[23]))|7(?:26(?:6[13-9]|7[0-7])|(?:442|688)\\d|50(?:2[0-3]|[3-68]2|76))|8(?:27[56]\\d|37(?:5[2-5]|8[239])|843[2-58])|9(?:0(?:0(?:6[1-8]|85)|52\\d)|3583|4(?:66[1-8]|9(?:2[01]|81))|63(?:23|3[1-4])|9561))\\d{3}",[9,10]],["7(?:457[0-57-9]|700[01]|911[028])\\d{5}|7(?:[1-3]\\d\\d|4(?:[0-46-9]\\d|5[0-689])|5(?:0[0-8]|[13-9]\\d|2[0-35-9])|7(?:0[1-9]|[1-7]\\d|8[02-9]|9[0-689])|8(?:[014-9]\\d|[23][0-8])|9(?:[024-9]\\d|1[02-9]|3[0-689]))\\d{6}",[10]],["80[08]\\d{7}|800\\d{6}|8001111"],["(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\d|8[2-49]))\\d{7}|845464\\d",[7,10]],["70\\d{8}",[10]],0,["(?:3[0347]|55)\\d{8}",[10]],["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}",[10]],["56\\d{8}",[10]]],0," x"],GD:["1","011","(?:473|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","473$1",0,"473"],GE:["995","00","(?:[3-57]\\d\\d|800)\\d{6}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["70"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["32"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[57]"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[348]"],"0$1"]],"0"],GF:["594","00","[56]94\\d{6}|(?:80|9\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[56]|97"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[89]"],"0$1"]],"0"],GG:["44","00","(?:1481|[357-9]\\d{3})\\d{6}|8\\d{6}(?:\\d{2})?",[7,9,10],0,"0",0,"([25-9]\\d{5})$|0","1481$1",0,0,[["1481[25-9]\\d{5}",[10]],["7(?:(?:781|839)\\d|911[17])\\d{5}",[10]],["80[08]\\d{7}|800\\d{6}|8001111"],["(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\d|8[0-3]))\\d{7}|845464\\d",[7,10]],["70\\d{8}",[10]],0,["(?:3[0347]|55)\\d{8}",[10]],["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}",[10]],["56\\d{8}",[10]]]],GH:["233","00","(?:[235]\\d{3}|800)\\d{5}",[8,9],[["(\\d{3})(\\d{5})","$1 $2",["8"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[235]"],"0$1"]],"0"],GI:["350","00","(?:[25]\\d\\d|606)\\d{5}",[8],[["(\\d{3})(\\d{5})","$1 $2",["2"]]]],GL:["299","00","(?:19|[2-689]\\d|70)\\d{4}",[6],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["19|[2-9]"]]]],GM:["220","00","[2-9]\\d{6}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-9]"]]]],GN:["224","00","722\\d{6}|(?:3|6\\d)\\d{7}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["3"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[67]"]]]],GP:["590","00","590\\d{6}|(?:69|80|9\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[569]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0$1"]],"0",0,0,0,0,0,[["590(?:0[1-68]|[14][0-24-9]|2[0-68]|3[1289]|5[3-579]|6[0-489]|7[08]|8[0-689]|9\\d)\\d{4}"],["69(?:0\\d\\d|1(?:2[2-9]|3[0-5]))\\d{4}"],["80[0-5]\\d{6}"],0,0,0,0,0,["9(?:395|76[018])\\d{5}"]]],GQ:["240","00","222\\d{6}|(?:3\\d|55|[89]0)\\d{7}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[235]"]],["(\\d{3})(\\d{6})","$1 $2",["[89]"]]]],GR:["30","00","5005000\\d{3}|8\\d{9,11}|(?:[269]\\d|70)\\d{8}",[10,11,12],[["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["21|7"]],["(\\d{4})(\\d{6})","$1 $2",["2(?:2|3[2-57-9]|4[2-469]|5[2-59]|6[2-9]|7[2-69]|8[2-49])|5"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[2689]"]],["(\\d{3})(\\d{3,4})(\\d{5})","$1 $2 $3",["8"]]]],GT:["502","00","(?:1\\d{3}|[2-7])\\d{7}",[8,11],[["(\\d{4})(\\d{4})","$1 $2",["[2-7]"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]]]],GU:["1","011","(?:[58]\\d\\d|671|900)\\d{7}",[10],0,"1",0,"([3-9]\\d{6})$|1","671$1",0,"671"],GW:["245","00","[49]\\d{8}|4\\d{6}",[7,9],[["(\\d{3})(\\d{4})","$1 $2",["40"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[49]"]]]],GY:["592","001","9008\\d{3}|(?:[2-467]\\d\\d|862)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-46-9]"]]]],HK:["852","00(?:30|5[09]|[126-9]?)","8[0-46-9]\\d{6,7}|9\\d{4,7}|(?:[2-7]|9\\d{3})\\d{7}",[5,6,7,8,9,11],[["(\\d{3})(\\d{2,5})","$1 $2",["900","9003"]],["(\\d{4})(\\d{4})","$1 $2",["[2-7]|8[1-4]|9(?:0[1-9]|[1-8])"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"]],["(\\d{3})(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3 $4",["9"]]],0,0,0,0,0,0,0,"00"],HN:["504","00","8\\d{10}|[237-9]\\d{7}",[8,11],[["(\\d{4})(\\d{4})","$1-$2",["[237-9]"]]]],HR:["385","00","(?:[24-69]\\d|3[0-79])\\d{7}|80\\d{5,7}|[1-79]\\d{7}|6\\d{5,6}",[6,7,8,9],[["(\\d{2})(\\d{2})(\\d{2,3})","$1 $2 $3",["6[01]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2,3})","$1 $2 $3",["8"],"0$1"],["(\\d)(\\d{4})(\\d{3})","$1 $2 $3",["1"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[67]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["9"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-5]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"],"0$1"]],"0"],HT:["509","00","(?:[2-489]\\d|55)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["[2-589]"]]]],HU:["36","00","[235-7]\\d{8}|[1-9]\\d{7}",[8,9],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["1"],"(06 $1)"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[27][2-9]|3[2-7]|4[24-9]|5[2-79]|6|8[2-57-9]|9[2-69]"],"(06 $1)"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-9]"],"06 $1"]],"06"],ID:["62","00[89]","(?:(?:00[1-9]|8\\d)\\d{4}|[1-36])\\d{6}|00\\d{10}|[1-9]\\d{8,10}|[2-9]\\d{7}",[7,8,9,10,11,12,13],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["15"]],["(\\d{2})(\\d{5,9})","$1 $2",["2[124]|[36]1"],"(0$1)"],["(\\d{3})(\\d{5,7})","$1 $2",["800"],"0$1"],["(\\d{3})(\\d{5,8})","$1 $2",["[2-79]"],"(0$1)"],["(\\d{3})(\\d{3,4})(\\d{3})","$1-$2-$3",["8[1-35-9]"],"0$1"],["(\\d{3})(\\d{6,8})","$1 $2",["1"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["804"],"0$1"],["(\\d{3})(\\d)(\\d{3})(\\d{3})","$1 $2 $3 $4",["80"],"0$1"],["(\\d{3})(\\d{4})(\\d{4,5})","$1-$2-$3",["8"],"0$1"]],"0"],IE:["353","00","(?:1\\d|[2569])\\d{6,8}|4\\d{6,9}|7\\d{8}|8\\d{8,9}",[7,8,9,10],[["(\\d{2})(\\d{5})","$1 $2",["2[24-9]|47|58|6[237-9]|9[35-9]"],"(0$1)"],["(\\d{3})(\\d{5})","$1 $2",["[45]0"],"(0$1)"],["(\\d)(\\d{3,4})(\\d{4})","$1 $2 $3",["1"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2569]|4[1-69]|7[14]"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["70"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["81"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[78]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["4"],"(0$1)"],["(\\d{2})(\\d)(\\d{3})(\\d{4})","$1 $2 $3 $4",["8"],"0$1"]],"0"],IL:["972","0(?:0|1[2-9])","1\\d{6}(?:\\d{3,5})?|[57]\\d{8}|[1-489]\\d{7}",[7,8,9,10,11,12],[["(\\d{4})(\\d{3})","$1-$2",["125"]],["(\\d{4})(\\d{2})(\\d{2})","$1-$2-$3",["121"]],["(\\d)(\\d{3})(\\d{4})","$1-$2-$3",["[2-489]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["[57]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1-$2-$3",["12"]],["(\\d{4})(\\d{6})","$1-$2",["159"]],["(\\d)(\\d{3})(\\d{3})(\\d{3})","$1-$2-$3-$4",["1[7-9]"]],["(\\d{3})(\\d{1,2})(\\d{3})(\\d{4})","$1-$2 $3-$4",["15"]]],"0"],IM:["44","00","1624\\d{6}|(?:[3578]\\d|90)\\d{8}",[10],0,"0",0,"([25-8]\\d{5})$|0","1624$1",0,"74576|(?:16|7[56])24"],IN:["91","00","(?:000800|[2-9]\\d\\d)\\d{7}|1\\d{7,12}",[8,9,10,11,12,13],[["(\\d{8})","$1",["5(?:0|2[23]|3[03]|[67]1|88)","5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|888)","5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|8888)"],0,1],["(\\d{4})(\\d{4,5})","$1 $2",["180","1800"],0,1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["140"],0,1],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["11|2[02]|33|4[04]|79[1-7]|80[2-46]","11|2[02]|33|4[04]|79(?:[1-6]|7[19])|80(?:[2-4]|6[0-589])","11|2[02]|33|4[04]|79(?:[124-6]|3(?:[02-9]|1[0-24-9])|7(?:1|9[1-6]))|80(?:[2-4]|6[0-589])"],"0$1",1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["1(?:2[0-249]|3[0-25]|4[145]|[68]|7[1257])|2(?:1[257]|3[013]|4[01]|5[0137]|6[0158]|78|8[1568])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|5[12]|[78]1)|6(?:12|[2-4]1|5[17]|6[13]|80)|7(?:12|3[134]|4[47]|61|88)|8(?:16|2[014]|3[126]|6[136]|7[078]|8[34]|91)|(?:43|59|75)[15]|(?:1[59]|29|67|72)[14]","1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|674|7(?:(?:2[14]|3[34]|5[15])[2-6]|61[346]|88[0-8])|8(?:70[2-6]|84[235-7]|91[3-7])|(?:1(?:29|60|8[06])|261|552|6(?:12|[2-47]1|5[17]|6[13]|80)|7(?:12|31|4[47])|8(?:16|2[014]|3[126]|6[136]|7[78]|83))[2-7]","1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|6(?:12(?:[2-6]|7[0-8])|74[2-7])|7(?:(?:2[14]|5[15])[2-6]|3171|61[346]|88(?:[2-7]|82))|8(?:70[2-6]|84(?:[2356]|7[19])|91(?:[3-6]|7[19]))|73[134][2-6]|(?:74[47]|8(?:16|2[014]|3[126]|6[136]|7[78]|83))(?:[2-6]|7[19])|(?:1(?:29|60|8[06])|261|552|6(?:[2-4]1|5[17]|6[13]|7(?:1|4[0189])|80)|7(?:12|88[01]))[2-7]"],"0$1",1],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2[2457-9]|3[2-5]|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1[013-9]|28|3[129]|4[1-35689]|5[29]|6[02-5]|70)|807","1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2(?:[2457]|84|95)|3(?:[2-4]|55)|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1(?:[013-8]|9[6-9])|28[6-8]|3(?:17|2[0-49]|9[2-57])|4(?:1[2-4]|[29][0-7]|3[0-8]|[56]|8[0-24-7])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4|5[0-367])|70[13-7])|807[19]","1(?:[2-479]|5(?:[0236-9]|5[013-9]))|[2-5]|6(?:2(?:84|95)|355|83)|73179|807(?:1|9[1-3])|(?:1552|6(?:1[1358]|2[2457]|3[2-4]|4[235-7]|5[2-689]|6[24578]|7[235689]|8[124-6])\\d|7(?:1(?:[013-8]\\d|9[6-9])|28[6-8]|3(?:2[0-49]|9[2-57])|4(?:1[2-4]|[29][0-7]|3[0-8]|[56]\\d|8[0-24-7])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4\\d|5[0-367])|70[13-7]))[2-7]"],"0$1",1],["(\\d{5})(\\d{5})","$1 $2",["[6-9]"],"0$1",1],["(\\d{4})(\\d{2,4})(\\d{4})","$1 $2 $3",["1(?:6|8[06])","1(?:6|8[06]0)"],0,1],["(\\d{4})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["18"],0,1]],"0"],IO:["246","00","3\\d{6}",[7],[["(\\d{3})(\\d{4})","$1 $2",["3"]]]],IQ:["964","00","(?:1|7\\d\\d)\\d{7}|[2-6]\\d{7,8}",[8,9,10],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-6]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"0$1"]],"0"],IR:["98","00","[1-9]\\d{9}|(?:[1-8]\\d\\d|9)\\d{3,4}",[4,5,6,7,10],[["(\\d{4,5})","$1",["96"],"0$1"],["(\\d{2})(\\d{4,5})","$1 $2",["(?:1[137]|2[13-68]|3[1458]|4[145]|5[1468]|6[16]|7[1467]|8[13467])[12689]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["9"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["[1-8]"],"0$1"]],"0"],IS:["354","00|1(?:0(?:01|[12]0)|100)","(?:38\\d|[4-9])\\d{6}",[7,9],[["(\\d{3})(\\d{4})","$1 $2",["[4-9]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["3"]]],0,0,0,0,0,0,0,"00"],IT:["39","00","0\\d{5,10}|1\\d{8,10}|3(?:[0-8]\\d{7,10}|9\\d{7,8})|(?:55|70)\\d{8}|8\\d{5}(?:\\d{2,4})?",[6,7,8,9,10,11],[["(\\d{2})(\\d{4,6})","$1 $2",["0[26]"]],["(\\d{3})(\\d{3,6})","$1 $2",["0[13-57-9][0159]|8(?:03|4[17]|9[2-5])","0[13-57-9][0159]|8(?:03|4[17]|9(?:2|3[04]|[45][0-4]))"]],["(\\d{4})(\\d{2,6})","$1 $2",["0(?:[13-579][2-46-8]|8[236-8])"]],["(\\d{4})(\\d{4})","$1 $2",["894"]],["(\\d{2})(\\d{3,4})(\\d{4})","$1 $2 $3",["0[26]|5"]],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["1(?:44|[679])|[378]"]],["(\\d{3})(\\d{3,4})(\\d{4})","$1 $2 $3",["0[13-57-9][0159]|14"]],["(\\d{2})(\\d{4})(\\d{5})","$1 $2 $3",["0[26]"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["0"]],["(\\d{3})(\\d{4})(\\d{4,5})","$1 $2 $3",["3"]]],0,0,0,0,0,0,[["0669[0-79]\\d{1,6}|0(?:1(?:[0159]\\d|[27][1-5]|31|4[1-4]|6[1356]|8[2-57])|2\\d\\d|3(?:[0159]\\d|2[1-4]|3[12]|[48][1-6]|6[2-59]|7[1-7])|4(?:[0159]\\d|[23][1-9]|4[245]|6[1-5]|7[1-4]|81)|5(?:[0159]\\d|2[1-5]|3[2-6]|4[1-79]|6[4-6]|7[1-578]|8[3-8])|6(?:[0-57-9]\\d|6[0-8])|7(?:[0159]\\d|2[12]|3[1-7]|4[2-46]|6[13569]|7[13-6]|8[1-59])|8(?:[0159]\\d|2[3-578]|3[1-356]|[6-8][1-5])|9(?:[0159]\\d|[238][1-5]|4[12]|6[1-8]|7[1-6]))\\d{2,7}"],["3[1-9]\\d{8}|3[2-9]\\d{7}",[9,10]],["80(?:0\\d{3}|3)\\d{3}",[6,9]],["(?:0878\\d{3}|89(?:2\\d|3[04]|4(?:[0-4]|[5-9]\\d\\d)|5[0-4]))\\d\\d|(?:1(?:44|6[346])|89(?:38|5[5-9]|9))\\d{6}",[6,8,9,10]],["1(?:78\\d|99)\\d{6}",[9,10]],0,0,0,["55\\d{8}",[10]],["84(?:[08]\\d{3}|[17])\\d{3}",[6,9]]]],JE:["44","00","1534\\d{6}|(?:[3578]\\d|90)\\d{8}",[10],0,"0",0,"([0-24-8]\\d{5})$|0","1534$1",0,0,[["1534[0-24-8]\\d{5}"],["7(?:(?:(?:50|82)9|937)\\d|7(?:00[378]|97[7-9]))\\d{5}"],["80(?:07(?:35|81)|8901)\\d{4}"],["(?:8(?:4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|90(?:066[59]|1810|71(?:07|55)))\\d{4}"],["701511\\d{4}"],0,["(?:3(?:0(?:07(?:35|81)|8901)|3\\d{4}|4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|55\\d{4})\\d{4}"],["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}"],["56\\d{8}"]]],JM:["1","011","(?:[58]\\d\\d|658|900)\\d{7}",[10],0,"1",0,0,0,0,"658|876"],JO:["962","00","(?:(?:[2689]|7\\d)\\d|32|53)\\d{6}",[8,9],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[2356]|87"],"(0$1)"],["(\\d{3})(\\d{5,6})","$1 $2",["[89]"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["70"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["7"],"0$1"]],"0"],JP:["81","010","00[1-9]\\d{6,14}|[257-9]\\d{9}|(?:00|[1-9]\\d\\d)\\d{6}",[8,9,10,11,12,13,14,15,16,17],[["(\\d{3})(\\d{3})(\\d{3})","$1-$2-$3",["(?:12|57|99)0"],"0$1"],["(\\d{4})(\\d)(\\d{4})","$1-$2-$3",["1(?:26|3[79]|4[56]|5[4-68]|6[3-5])|499|5(?:76|97)|746|8(?:3[89]|47|51|63)|9(?:80|9[16])","1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:76|97)9|7468|8(?:3(?:8[7-9]|96)|477|51[2-9]|636)|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]","1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:769|979[2-69])|7468|8(?:3(?:8[7-9]|96[2457-9])|477|51[2-9]|636[457-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["60"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1-$2-$3",["[36]|4(?:2[09]|7[01])","[36]|4(?:2(?:0|9[02-69])|7(?:0[019]|1))"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["1(?:1|5[45]|77|88|9[69])|2(?:2[1-37]|3[0-269]|4[59]|5|6[24]|7[1-358]|8[1369]|9[0-38])|4(?:[28][1-9]|3[0-57]|[45]|6[248]|7[2-579]|9[29])|5(?:2|3[045]|4[0-369]|5[29]|8[02389]|9[0-389])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9[2-6])|8(?:2[124589]|3[27-9]|49|51|6|7[0-468]|8[68]|9[019])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9[1-489])","1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2(?:[127]|3[014-9])|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9[19])|62|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|8[1-9])|5(?:2|3[045]|4[0-369]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0-2469])|49|51|6(?:[0-24]|36|5[0-3589]|72|9[01459])|7[0-468]|8[68])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9(?:[1289]|3[34]|4[0178]))|(?:49|55|83)[29]|(?:264|837)[016-9]|2(?:57|93)[015-9]|(?:25[0468]|422|838)[01]|(?:47[59]|59[89]|8(?:6[68]|9))[019]","1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2[127]|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9(?:17|99))|6(?:2|4[016-9])|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|9[29])|5(?:2|3[045]|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0169])|3(?:[29]|7(?:[017-9]|6[6-8]))|49|51|6(?:[0-24]|36[23]|5(?:[0-389]|5[23])|6(?:[01]|9[178])|72|9[0145])|7[0-468]|8[68])|9(?:4[15]|5[138]|7[156]|8[189]|9(?:[1289]|3(?:31|4[357])|4[0178]))|(?:8294|96)[1-3]|2(?:57|93)[015-9]|(?:223|8699)[014-9]|(?:25[0468]|422|838)[01]|(?:48|8292|9[23])[1-9]|(?:47[59]|59[89]|8(?:68|9))[019]","1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2[127]|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|7[015-9]|9(?:17|99))|6(?:2|4[016-9])|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17|3[015-9]))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|9[29])|5(?:2|3[045]|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9(?:[019]|4[1-3]|6(?:[0-47-9]|5[01346-9])))|3(?:[29]|7(?:[017-9]|6[6-8]))|49|51|6(?:[0-24]|36[23]|5(?:[0-389]|5[23])|6(?:[01]|9[178])|72|9[0145])|7[0-468]|8[68])|9(?:4[15]|5[138]|6[1-3]|7[156]|8[189]|9(?:[1289]|3(?:31|4[357])|4[0178]))|(?:223|8699)[014-9]|(?:25[0468]|422|838)[01]|(?:48|829(?:2|66)|9[23])[1-9]|(?:47[59]|59[89]|8(?:68|9))[019]"],"0$1"],["(\\d{3})(\\d{2})(\\d{4})","$1-$2-$3",["[14]|[289][2-9]|5[3-9]|7[2-4679]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1-$2-$3",["800"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1-$2-$3",["[257-9]"],"0$1"]],"0"],KE:["254","000","(?:[17]\\d\\d|900)\\d{6}|(?:2|80)0\\d{6,7}|[4-6]\\d{6,8}",[7,8,9,10],[["(\\d{2})(\\d{5,7})","$1 $2",["[24-6]"],"0$1"],["(\\d{3})(\\d{6})","$1 $2",["[17]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["[89]"],"0$1"]],"0"],KG:["996","00","8\\d{9}|(?:[235-8]\\d|99)\\d{7}",[9,10],[["(\\d{4})(\\d{5})","$1 $2",["3(?:1[346]|[24-79])"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[235-79]|88"],"0$1"],["(\\d{3})(\\d{3})(\\d)(\\d{2,3})","$1 $2 $3 $4",["8"],"0$1"]],"0"],KH:["855","00[14-9]","1\\d{9}|[1-9]\\d{7,8}",[8,9,10],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[1-9]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]]],"0"],KI:["686","00","(?:[37]\\d|6[0-79])\\d{6}|(?:[2-48]\\d|50)\\d{3}",[5,8],0,"0"],KM:["269","00","[3478]\\d{6}",[7],[["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["[3478]"]]]],KN:["1","011","(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-7]\\d{6})$|1","869$1",0,"869"],KP:["850","00|99","85\\d{6}|(?:19\\d|[2-7])\\d{7}",[8,10],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["8"],"0$1"],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[2-7]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"]],"0"],KR:["82","00(?:[125689]|3(?:[46]5|91)|7(?:00|27|3|55|6[126]))","00[1-9]\\d{8,11}|(?:[12]|5\\d{3})\\d{7}|[13-6]\\d{9}|(?:[1-6]\\d|80)\\d{7}|[3-6]\\d{4,5}|(?:00|7)0\\d{8}",[5,6,8,9,10,11,12,13,14],[["(\\d{2})(\\d{3,4})","$1-$2",["(?:3[1-3]|[46][1-4]|5[1-5])1"],"0$1"],["(\\d{4})(\\d{4})","$1-$2",["1"]],["(\\d)(\\d{3,4})(\\d{4})","$1-$2-$3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["60|8"],"0$1"],["(\\d{2})(\\d{3,4})(\\d{4})","$1-$2-$3",["[1346]|5[1-5]"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1-$2-$3",["[57]"],"0$1"],["(\\d{2})(\\d{5})(\\d{4})","$1-$2-$3",["5"],"0$1"]],"0",0,"0(8(?:[1-46-8]|5\\d\\d))?"],KW:["965","00","18\\d{5}|(?:[2569]\\d|41)\\d{6}",[7,8],[["(\\d{4})(\\d{3,4})","$1 $2",["[169]|2(?:[235]|4[1-35-9])|52"]],["(\\d{3})(\\d{5})","$1 $2",["[245]"]]]],KY:["1","011","(?:345|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","345$1",0,"345"],KZ:["7","810","(?:33622|8\\d{8})\\d{5}|[78]\\d{9}",[10,14],0,"8",0,0,0,0,"33|7",0,"8~10"],LA:["856","00","[23]\\d{9}|3\\d{8}|(?:[235-8]\\d|41)\\d{6}",[8,9,10],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["2[13]|3[14]|[4-8]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3 $4",["30[013-9]"],"0$1"],["(\\d{2})(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3 $4",["[23]"],"0$1"]],"0"],LB:["961","00","[27-9]\\d{7}|[13-9]\\d{6}",[7,8],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[13-69]|7(?:[2-57]|62|8[0-7]|9[04-9])|8[02-9]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[27-9]"]]],"0"],LC:["1","011","(?:[58]\\d\\d|758|900)\\d{7}",[10],0,"1",0,"([2-8]\\d{6})$|1","758$1",0,"758"],LI:["423","00","[68]\\d{8}|(?:[2378]\\d|90)\\d{5}",[7,9],[["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["[2379]|8(?:0[09]|7)","[2379]|8(?:0(?:02|9)|7)"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["69"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6"]]],"0",0,"(1001)|0"],LK:["94","00","[1-9]\\d{8}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[1-689]"],"0$1"]],"0"],LR:["231","00","(?:[25]\\d|33|77|88)\\d{7}|(?:2\\d|[4-6])\\d{6}",[7,8,9],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[4-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[23578]"],"0$1"]],"0"],LS:["266","00","(?:[256]\\d\\d|800)\\d{5}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[2568]"]]]],LT:["370","00","(?:[3469]\\d|52|[78]0)\\d{6}",[8],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["52[0-7]"],"(8-$1)",1],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[7-9]"],"8 $1",1],["(\\d{2})(\\d{6})","$1 $2",["37|4(?:[15]|6[1-8])"],"(8-$1)",1],["(\\d{3})(\\d{5})","$1 $2",["[3-6]"],"(8-$1)",1]],"8",0,"[08]"],LU:["352","00","35[013-9]\\d{4,8}|6\\d{8}|35\\d{2,4}|(?:[2457-9]\\d|3[0-46-9])\\d{2,9}",[4,5,6,7,8,9,10,11],[["(\\d{2})(\\d{3})","$1 $2",["2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])"]],["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])"]],["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["20[2-689]"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{1,2})","$1 $2 $3 $4",["2(?:[0367]|4[3-8])"]],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["80[01]|90[015]"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3 $4",["20"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{1,2})","$1 $2 $3 $4 $5",["2(?:[0367]|4[3-8])"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{1,5})","$1 $2 $3 $4",["[3-57]|8[13-9]|9(?:0[89]|[2-579])|(?:2|80)[2-9]"]]],0,0,"(15(?:0[06]|1[12]|[35]5|4[04]|6[26]|77|88|99)\\d)"],LV:["371","00","(?:[268]\\d|90)\\d{6}",[8],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[269]|8[01]"]]]],LY:["218","00","[2-9]\\d{8}",[9],[["(\\d{2})(\\d{7})","$1-$2",["[2-9]"],"0$1"]],"0"],MA:["212","00","[5-8]\\d{8}",[9],[["(\\d{5})(\\d{4})","$1-$2",["5(?:29|38)","5(?:29[1289]|389)","529(?:1[1-46-9]|2[013-8]|90)|5(?:298|389)[0-46-9]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["5[45]"],"0$1"],["(\\d{4})(\\d{5})","$1-$2",["5(?:2[2-489]|3[5-9]|9)|892","5(?:2(?:[2-49]|8[235-9])|3[5-9]|9)|892"],"0$1"],["(\\d{2})(\\d{7})","$1-$2",["8"],"0$1"],["(\\d{3})(\\d{6})","$1-$2",["[5-7]"],"0$1"]],"0",0,0,0,0,0,[["5293[01]\\d{4}|5(?:2(?:[0-25-7]\\d|3[1-578]|4[02-46-8]|8[0235-7]|9[0-289])|3(?:[0-47]\\d|5[02-9]|6[02-8]|8[0189]|9[3-9])|(?:4[067]|5[03])\\d)\\d{5}"],["(?:6(?:[0-79]\\d|8[0-247-9])|7(?:[017]\\d|2[0-2]|6[0-8]|8[0-3]))\\d{6}"],["80\\d{7}"],["89\\d{7}"],0,0,0,0,["592(?:4[0-2]|93)\\d{4}"]]],MC:["377","00","(?:[3489]|6\\d)\\d{7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["4"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[389]"]],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["6"],"0$1"]],"0"],MD:["373","00","(?:[235-7]\\d|[89]0)\\d{6}",[8],[["(\\d{3})(\\d{5})","$1 $2",["[89]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["22|3"],"0$1"],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[25-7]"],"0$1"]],"0"],ME:["382","00","(?:20|[3-79]\\d)\\d{6}|80\\d{6,7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-9]"],"0$1"]],"0"],MF:["590","00","590\\d{6}|(?:69|80|9\\d)\\d{7}",[9],0,"0",0,0,0,0,0,[["590(?:0[079]|[14]3|[27][79]|30|5[0-268]|87)\\d{4}"],["69(?:0\\d\\d|1(?:2[2-9]|3[0-5]))\\d{4}"],["80[0-5]\\d{6}"],0,0,0,0,0,["9(?:395|76[018])\\d{5}"]]],MG:["261","00","[23]\\d{8}",[9],[["(\\d{2})(\\d{2})(\\d{3})(\\d{2})","$1 $2 $3 $4",["[23]"],"0$1"]],"0",0,"([24-9]\\d{6})$|0","20$1"],MH:["692","011","329\\d{4}|(?:[256]\\d|45)\\d{5}",[7],[["(\\d{3})(\\d{4})","$1-$2",["[2-6]"]]],"1"],MK:["389","00","[2-578]\\d{7}",[8],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["2|34[47]|4(?:[37]7|5[47]|64)"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[347]"],"0$1"],["(\\d{3})(\\d)(\\d{2})(\\d{2})","$1 $2 $3 $4",["[58]"],"0$1"]],"0"],ML:["223","00","[24-9]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[24-9]"]]]],MM:["95","00","1\\d{5,7}|95\\d{6}|(?:[4-7]|9[0-46-9])\\d{6,8}|(?:2|8\\d)\\d{5,8}",[6,7,8,9,10],[["(\\d)(\\d{2})(\\d{3})","$1 $2 $3",["16|2"],"0$1"],["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["[45]|6(?:0[23]|[1-689]|7[235-7])|7(?:[0-4]|5[2-7])|8[1-6]"],"0$1"],["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["[12]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[4-7]|8[1-35]"],"0$1"],["(\\d)(\\d{3})(\\d{4,6})","$1 $2 $3",["9(?:2[0-4]|[35-9]|4[137-9])"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["2"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"],"0$1"],["(\\d)(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["92"],"0$1"],["(\\d)(\\d{5})(\\d{4})","$1 $2 $3",["9"],"0$1"]],"0"],MN:["976","001","[12]\\d{7,9}|[5-9]\\d{7}",[8,9,10],[["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["[12]1"],"0$1"],["(\\d{4})(\\d{4})","$1 $2",["[5-9]"]],["(\\d{3})(\\d{5,6})","$1 $2",["[12]2[1-3]"],"0$1"],["(\\d{4})(\\d{5,6})","$1 $2",["[12](?:27|3[2-8]|4[2-68]|5[1-4689])","[12](?:27|3[2-8]|4[2-68]|5[1-4689])[0-3]"],"0$1"],["(\\d{5})(\\d{4,5})","$1 $2",["[12]"],"0$1"]],"0"],MO:["853","00","0800\\d{3}|(?:28|[68]\\d)\\d{6}",[7,8],[["(\\d{4})(\\d{3})","$1 $2",["0"]],["(\\d{4})(\\d{4})","$1 $2",["[268]"]]]],MP:["1","011","[58]\\d{9}|(?:67|90)0\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","670$1",0,"670"],MQ:["596","00","596\\d{6}|(?:69|80|9\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[569]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0$1"]],"0"],MR:["222","00","(?:[2-4]\\d\\d|800)\\d{5}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-48]"]]]],MS:["1","011","(?:[58]\\d\\d|664|900)\\d{7}",[10],0,"1",0,"([34]\\d{6})$|1","664$1",0,"664"],MT:["356","00","3550\\d{4}|(?:[2579]\\d\\d|800)\\d{5}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[2357-9]"]]]],MU:["230","0(?:0|[24-7]0|3[03])","(?:[57]|8\\d\\d)\\d{7}|[2-468]\\d{6}",[7,8,10],[["(\\d{3})(\\d{4})","$1 $2",["[2-46]|8[013]"]],["(\\d{4})(\\d{4})","$1 $2",["[57]"]],["(\\d{5})(\\d{5})","$1 $2",["8"]]],0,0,0,0,0,0,0,"020"],MV:["960","0(?:0|19)","(?:800|9[0-57-9]\\d)\\d{7}|[34679]\\d{6}",[7,10],[["(\\d{3})(\\d{4})","$1-$2",["[34679]"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[89]"]]],0,0,0,0,0,0,0,"00"],MW:["265","00","(?:[1289]\\d|31|77)\\d{7}|1\\d{6}",[7,9],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["1[2-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["2"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[137-9]"],"0$1"]],"0"],MX:["52","0[09]","1(?:(?:[27]2|44|99)[1-9]|65[0-689])\\d{7}|(?:1(?:[01]\\d|2[13-9]|[35][1-9]|4[0-35-9]|6[0-46-9]|7[013-9]|8[1-79]|9[1-8])|[2-9]\\d)\\d{8}",[10,11],[["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["33|5[56]|81"],0,1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[2-9]"],0,1],["(\\d)(\\d{2})(\\d{4})(\\d{4})","$2 $3 $4",["1(?:33|5[56]|81)"],0,1],["(\\d)(\\d{3})(\\d{3})(\\d{4})","$2 $3 $4",["1"],0,1]],"01",0,"0(?:[12]|4[45])|1",0,0,0,0,"00"],MY:["60","00","1\\d{8,9}|(?:3\\d|[4-9])\\d{7}",[8,9,10],[["(\\d)(\\d{3})(\\d{4})","$1-$2 $3",["[4-79]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1-$2 $3",["1(?:[02469]|[378][1-9]|53)|8","1(?:[02469]|[37][1-9]|53|8(?:[1-46-9]|5[7-9]))|8"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1-$2 $3",["3"],"0$1"],["(\\d)(\\d{3})(\\d{2})(\\d{4})","$1-$2-$3-$4",["1(?:[367]|80)"]],["(\\d{3})(\\d{3})(\\d{4})","$1-$2 $3",["15"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1-$2 $3",["1"],"0$1"]],"0"],MZ:["258","00","(?:2|8\\d)\\d{7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["2|8[2-79]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"]]]],NA:["264","00","[68]\\d{7,8}",[8,9],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["88"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["6"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["87"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["8"],"0$1"]],"0"],NC:["687","00","(?:050|[2-57-9]\\d\\d)\\d{3}",[6],[["(\\d{2})(\\d{2})(\\d{2})","$1.$2.$3",["[02-57-9]"]]]],NE:["227","00","[027-9]\\d{7}",[8],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["08"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[089]|2[013]|7[04]"]]]],NF:["672","00","[13]\\d{5}",[6],[["(\\d{2})(\\d{4})","$1 $2",["1[0-3]"]],["(\\d)(\\d{5})","$1 $2",["[13]"]]],0,0,"([0-258]\\d{4})$","3$1"],NG:["234","009","(?:[124-7]|9\\d{3})\\d{6}|[1-9]\\d{7}|[78]\\d{9,13}",[7,8,10,11,12,13,14],[["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["78"],"0$1"],["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["[12]|9(?:0[3-9]|[1-9])"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,3})","$1 $2 $3",["[3-7]|8[2-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["[7-9]"],"0$1"],["(\\d{3})(\\d{4})(\\d{4,5})","$1 $2 $3",["[78]"],"0$1"],["(\\d{3})(\\d{5})(\\d{5,6})","$1 $2 $3",["[78]"],"0$1"]],"0"],NI:["505","00","(?:1800|[25-8]\\d{3})\\d{4}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[125-8]"]]]],NL:["31","00","(?:[124-7]\\d\\d|3(?:[02-9]\\d|1[0-8]))\\d{6}|8\\d{6,9}|9\\d{6,10}|1\\d{4,5}",[5,6,7,8,9,10,11],[["(\\d{3})(\\d{4,7})","$1 $2",["[89]0"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["66"],"0$1"],["(\\d)(\\d{8})","$1 $2",["6"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["1[16-8]|2[259]|3[124]|4[17-9]|5[124679]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[1-578]|91"],"0$1"],["(\\d{3})(\\d{3})(\\d{5})","$1 $2 $3",["9"],"0$1"]],"0"],NO:["47","00","(?:0|[2-9]\\d{3})\\d{4}",[5,8],[["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[489]|59"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[235-7]"]]],0,0,0,0,0,"[02-689]|7[0-8]"],NP:["977","00","(?:1\\d|9)\\d{9}|[1-9]\\d{7}",[8,10,11],[["(\\d)(\\d{7})","$1-$2",["1[2-6]"],"0$1"],["(\\d{2})(\\d{6})","$1-$2",["1[01]|[2-8]|9(?:[1-59]|[67][2-6])"],"0$1"],["(\\d{3})(\\d{7})","$1-$2",["9"]]],"0"],NR:["674","00","(?:444|(?:55|8\\d)\\d|666)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[4-68]"]]]],NU:["683","00","(?:[47]|888\\d)\\d{3}",[4,7],[["(\\d{3})(\\d{4})","$1 $2",["8"]]]],NZ:["64","0(?:0|161)","[29]\\d{7,9}|50\\d{5}(?:\\d{2,3})?|6[0-35-9]\\d{6}|7\\d{7,8}|8\\d{4,9}|(?:11\\d|[34])\\d{7}",[5,6,7,8,9,10],[["(\\d{2})(\\d{3,8})","$1 $2",["8[1-579]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2,3})","$1 $2 $3",["50[036-8]|[89]0","50(?:[0367]|88)|[89]0"],"0$1"],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["24|[346]|7[2-57-9]|9[2-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["2(?:10|74)|[59]|80"],"0$1"],["(\\d{2})(\\d{3,4})(\\d{4})","$1 $2 $3",["1|2[028]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,5})","$1 $2 $3",["2(?:[169]|7[0-35-9])|7|86"],"0$1"]],"0",0,0,0,0,0,0,"00"],OM:["968","00","(?:1505|[279]\\d{3}|500)\\d{4}|800\\d{5,6}",[7,8,9],[["(\\d{3})(\\d{4,6})","$1 $2",["[58]"]],["(\\d{2})(\\d{6})","$1 $2",["2"]],["(\\d{4})(\\d{4})","$1 $2",["[179]"]]]],PA:["507","00","(?:00800|8\\d{3})\\d{6}|[68]\\d{7}|[1-57-9]\\d{6}",[7,8,10,11],[["(\\d{3})(\\d{4})","$1-$2",["[1-57-9]"]],["(\\d{4})(\\d{4})","$1-$2",["[68]"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"]]]],PE:["51","00|19(?:1[124]|77|90)00","(?:[14-8]|9\\d)\\d{7}",[8,9],[["(\\d{3})(\\d{5})","$1 $2",["80"],"(0$1)"],["(\\d)(\\d{7})","$1 $2",["1"],"(0$1)"],["(\\d{2})(\\d{6})","$1 $2",["[4-8]"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["9"]]],"0",0,0,0,0,0,0,"00"," Anexo "],PF:["689","00","4\\d{5}(?:\\d{2})?|8\\d{7,8}",[6,8,9],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["44"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["4|8[7-9]"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]]]],PG:["675","00|140[1-3]","(?:180|[78]\\d{3})\\d{4}|(?:[2-589]\\d|64)\\d{5}",[7,8],[["(\\d{3})(\\d{4})","$1 $2",["18|[2-69]|85"]],["(\\d{4})(\\d{4})","$1 $2",["[78]"]]],0,0,0,0,0,0,0,"00"],PH:["63","00","(?:[2-7]|9\\d)\\d{8}|2\\d{5}|(?:1800|8)\\d{7,9}",[6,8,9,10,11,12,13],[["(\\d)(\\d{5})","$1 $2",["2"],"(0$1)"],["(\\d{4})(\\d{4,6})","$1 $2",["3(?:23|39|46)|4(?:2[3-6]|[35]9|4[26]|76)|544|88[245]|(?:52|64|86)2","3(?:230|397|461)|4(?:2(?:35|[46]4|51)|396|4(?:22|63)|59[347]|76[15])|5(?:221|446)|642[23]|8(?:622|8(?:[24]2|5[13]))"],"(0$1)"],["(\\d{5})(\\d{4})","$1 $2",["346|4(?:27|9[35])|883","3469|4(?:279|9(?:30|56))|8834"],"(0$1)"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["2"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[3-7]|8[2-8]"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[89]"],"0$1"],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]],["(\\d{4})(\\d{1,2})(\\d{3})(\\d{4})","$1 $2 $3 $4",["1"]]],"0"],PK:["92","00","122\\d{6}|[24-8]\\d{10,11}|9(?:[013-9]\\d{8,10}|2(?:[01]\\d\\d|2(?:[06-8]\\d|1[01]))\\d{7})|(?:[2-8]\\d{3}|92(?:[0-7]\\d|8[1-9]))\\d{6}|[24-9]\\d{8}|[89]\\d{7}",[8,9,10,11,12],[["(\\d{3})(\\d{3})(\\d{2,7})","$1 $2 $3",["[89]0"],"0$1"],["(\\d{4})(\\d{5})","$1 $2",["1"]],["(\\d{3})(\\d{6,7})","$1 $2",["2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:2[2-8]|3[27-9]|4[2-6]|6[3569]|9[25-8])","9(?:2[3-8]|98)|(?:2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:22|3[27-9]|4[2-6]|6[3569]|9[25-7]))[2-9]"],"(0$1)"],["(\\d{2})(\\d{7,8})","$1 $2",["(?:2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91)[2-9]"],"(0$1)"],["(\\d{5})(\\d{5})","$1 $2",["58"],"(0$1)"],["(\\d{3})(\\d{7})","$1 $2",["3"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["[24-9]"],"(0$1)"]],"0"],PL:["48","00","(?:6|8\\d\\d)\\d{7}|[1-9]\\d{6}(?:\\d{2})?|[26]\\d{5}",[6,7,8,9,10],[["(\\d{5})","$1",["19"]],["(\\d{3})(\\d{3})","$1 $2",["11|20|64"]],["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])1","(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])19"]],["(\\d{3})(\\d{2})(\\d{2,3})","$1 $2 $3",["64"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["21|39|45|5[0137]|6[0469]|7[02389]|8(?:0[14]|8)"]],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["1[2-8]|[2-7]|8[1-79]|9[145]"]],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["8"]]]],PM:["508","00","[45]\\d{5}|(?:708|80\\d)\\d{6}",[6,9],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["[45]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["7"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0$1"]],"0"],PR:["1","011","(?:[589]\\d\\d|787)\\d{7}",[10],0,"1",0,0,0,0,"787|939"],PS:["970","00","[2489]2\\d{6}|(?:1\\d|5)\\d{8}",[8,9,10],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[2489]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["5"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]]],"0"],PT:["351","00","1693\\d{5}|(?:[26-9]\\d|30)\\d{7}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["2[12]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["16|[236-9]"]]]],PW:["680","01[12]","(?:[24-8]\\d\\d|345|900)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-9]"]]]],PY:["595","00","59\\d{4,6}|9\\d{5,10}|(?:[2-46-8]\\d|5[0-8])\\d{4,7}",[6,7,8,9,10,11],[["(\\d{3})(\\d{3,6})","$1 $2",["[2-9]0"],"0$1"],["(\\d{2})(\\d{5})","$1 $2",["[26]1|3[289]|4[1246-8]|7[1-3]|8[1-36]"],"(0$1)"],["(\\d{3})(\\d{4,5})","$1 $2",["2[279]|3[13-5]|4[359]|5|6(?:[34]|7[1-46-8])|7[46-8]|85"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["2[14-68]|3[26-9]|4[1246-8]|6(?:1|75)|7[1-35]|8[1-36]"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["87"]],["(\\d{3})(\\d{6})","$1 $2",["9(?:[5-79]|8[1-6])"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[2-8]"],"0$1"],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["9"]]],"0"],QA:["974","00","800\\d{4}|(?:2|800)\\d{6}|(?:0080|[3-7])\\d{7}",[7,8,9,11],[["(\\d{3})(\\d{4})","$1 $2",["2[16]|8"]],["(\\d{4})(\\d{4})","$1 $2",["[3-7]"]]]],RE:["262","00","(?:26|[689]\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2689]"],"0$1"]],"0",0,0,0,0,0,[["26(?:2\\d\\d|3(?:0\\d|1[0-3]))\\d{4}"],["(?:69(?:2\\d\\d|3(?:0[0-46]|1[013]|2[0-2]|3[0-39]|4\\d|5[0-5]|6[0-6]|7[0-27]|8[0-8]|9[0-479]))|9(?:399[0-2]|4790|76(?:2[27]|3[0-37]|9\\d)))\\d{4}"],["80\\d{7}"],["89[1-37-9]\\d{6}"],0,0,0,0,0,["8(?:1[019]|2[0156]|84|90)\\d{6}"]]],RO:["40","00","(?:[2378]\\d|90)\\d{7}|[23]\\d{5}",[6,9],[["(\\d{3})(\\d{3})","$1 $2",["2[3-6]","2[3-6]\\d9"],"0$1"],["(\\d{2})(\\d{4})","$1 $2",["219|31"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[23]1"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[237-9]"],"0$1"]],"0",0,0,0,0,0,0,0," int "],RS:["381","00","38[02-9]\\d{6,9}|6\\d{7,9}|90\\d{4,8}|38\\d{5,6}|(?:7\\d\\d|800)\\d{3,9}|(?:[12]\\d|3[0-79])\\d{5,10}",[6,7,8,9,10,11,12],[["(\\d{3})(\\d{3,9})","$1 $2",["(?:2[389]|39)0|[7-9]"],"0$1"],["(\\d{2})(\\d{5,10})","$1 $2",["[1-36]"],"0$1"]],"0"],RU:["7","810","8\\d{13}|[347-9]\\d{9}",[10,14],[["(\\d{4})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["7(?:1[0-8]|2[1-9])","7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:1[23]|[2-9]2))","7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:13[03-69]|62[013-9]))|72[1-57-9]2"],"8 ($1)",1],["(\\d{5})(\\d)(\\d{2})(\\d{2})","$1 $2 $3 $4",["7(?:1[0-68]|2[1-9])","7(?:1(?:[06][3-6]|[18]|2[35]|[3-5][3-5])|2(?:[13][3-5]|[24-689]|7[457]))","7(?:1(?:0(?:[356]|4[023])|[18]|2(?:3[013-9]|5)|3[45]|43[013-79]|5(?:3[1-8]|4[1-7]|5)|6(?:3[0-35-9]|[4-6]))|2(?:1(?:3[178]|[45])|[24-689]|3[35]|7[457]))|7(?:14|23)4[0-8]|71(?:33|45)[1-79]"],"8 ($1)",1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"8 ($1)",1],["(\\d{3})(\\d{3})(\\d{2})(\\d{2})","$1 $2-$3-$4",["[349]|8(?:[02-7]|1[1-8])"],"8 ($1)",1],["(\\d{4})(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3 $4",["8"],"8 ($1)"]],"8",0,0,0,0,"3[04-689]|[489]",0,"8~10"],RW:["250","00","(?:06|[27]\\d\\d|[89]00)\\d{6}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["0"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[7-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["2"]]],"0"],SA:["966","00","92\\d{7}|(?:[15]|8\\d)\\d{8}",[9,10],[["(\\d{4})(\\d{5})","$1 $2",["9"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["5"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["81"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"]]],"0"],SB:["677","0[01]","(?:[1-6]|[7-9]\\d\\d)\\d{4}",[5,7],[["(\\d{2})(\\d{5})","$1 $2",["7|8[4-9]|9(?:[1-8]|9[0-8])"]]]],SC:["248","010|0[0-2]","800\\d{4}|(?:[249]\\d|64)\\d{5}",[7],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[246]|9[57]"]]],0,0,0,0,0,0,0,"00"],SD:["249","00","[19]\\d{8}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[19]"],"0$1"]],"0"],SE:["46","00","(?:[26]\\d\\d|9)\\d{9}|[1-9]\\d{8}|[1-689]\\d{7}|[1-4689]\\d{6}|2\\d{5}",[6,7,8,9,10],[["(\\d{2})(\\d{2,3})(\\d{2})","$1-$2 $3",["20"],"0$1",0,"$1 $2 $3"],["(\\d{3})(\\d{4})","$1-$2",["9(?:00|39|44|9)"],"0$1",0,"$1 $2"],["(\\d{2})(\\d{3})(\\d{2})","$1-$2 $3",["[12][136]|3[356]|4[0246]|6[03]|90[1-9]"],"0$1",0,"$1 $2 $3"],["(\\d)(\\d{2,3})(\\d{2})(\\d{2})","$1-$2 $3 $4",["8"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2,3})(\\d{2})","$1-$2 $3",["1[2457]|2(?:[247-9]|5[0138])|3[0247-9]|4[1357-9]|5[0-35-9]|6(?:[125689]|4[02-57]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])"],"0$1",0,"$1 $2 $3"],["(\\d{3})(\\d{2,3})(\\d{3})","$1-$2 $3",["9(?:00|39|44)"],"0$1",0,"$1 $2 $3"],["(\\d{2})(\\d{2,3})(\\d{2})(\\d{2})","$1-$2 $3 $4",["1[13689]|2[0136]|3[1356]|4[0246]|54|6[03]|90[1-9]"],"0$1",0,"$1 $2 $3 $4"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1-$2 $3 $4",["10|7"],"0$1",0,"$1 $2 $3 $4"],["(\\d)(\\d{3})(\\d{3})(\\d{2})","$1-$2 $3 $4",["8"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1-$2 $3 $4",["[13-5]|2(?:[247-9]|5[0138])|6(?:[124-689]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2})(\\d{2})(\\d{3})","$1-$2 $3 $4",["9"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1-$2 $3 $4 $5",["[26]"],"0$1",0,"$1 $2 $3 $4 $5"]],"0"],SG:["65","0[0-3]\\d","(?:(?:1\\d|8)\\d\\d|7000)\\d{7}|[3689]\\d{7}",[8,10,11],[["(\\d{4})(\\d{4})","$1 $2",["[369]|8(?:0[1-6]|[1-9])"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"]],["(\\d{4})(\\d{4})(\\d{3})","$1 $2 $3",["7"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]]]],SH:["290","00","(?:[256]\\d|8)\\d{3}",[4,5],0,0,0,0,0,0,"[256]"],SI:["386","00|10(?:22|66|88|99)","[1-7]\\d{7}|8\\d{4,7}|90\\d{4,6}",[5,6,7,8],[["(\\d{2})(\\d{3,6})","$1 $2",["8[09]|9"],"0$1"],["(\\d{3})(\\d{5})","$1 $2",["59|8"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[37][01]|4[0139]|51|6"],"0$1"],["(\\d)(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[1-57]"],"(0$1)"]],"0",0,0,0,0,0,0,"00"],SJ:["47","00","0\\d{4}|(?:[489]\\d|[57]9)\\d{6}",[5,8],0,0,0,0,0,0,"79"],SK:["421","00","[2-689]\\d{8}|[2-59]\\d{6}|[2-5]\\d{5}",[6,7,9],[["(\\d)(\\d{2})(\\d{3,4})","$1 $2 $3",["21"],"0$1"],["(\\d{2})(\\d{2})(\\d{2,3})","$1 $2 $3",["[3-5][1-8]1","[3-5][1-8]1[67]"],"0$1"],["(\\d)(\\d{3})(\\d{3})(\\d{2})","$1/$2 $3 $4",["2"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[689]"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1/$2 $3 $4",["[3-5]"],"0$1"]],"0"],SL:["232","00","(?:[237-9]\\d|66)\\d{6}",[8],[["(\\d{2})(\\d{6})","$1 $2",["[236-9]"],"(0$1)"]],"0"],SM:["378","00","(?:0549|[5-7]\\d)\\d{6}",[8,10],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-7]"]],["(\\d{4})(\\d{6})","$1 $2",["0"]]],0,0,"([89]\\d{5})$","0549$1"],SN:["221","00","(?:[378]\\d|93)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[379]"]]]],SO:["252","00","[346-9]\\d{8}|[12679]\\d{7}|[1-5]\\d{6}|[1348]\\d{5}",[6,7,8,9],[["(\\d{2})(\\d{4})","$1 $2",["8[125]"]],["(\\d{6})","$1",["[134]"]],["(\\d)(\\d{6})","$1 $2",["[15]|2[0-79]|3[0-46-8]|4[0-7]"]],["(\\d)(\\d{7})","$1 $2",["(?:2|90)4|[67]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[3478]|64|90"]],["(\\d{2})(\\d{5,7})","$1 $2",["1|28|6(?:0[5-7]|[1-35-9])|9[2-9]"]]],"0"],SR:["597","00","(?:[2-5]|68|[78]\\d)\\d{5}",[6,7],[["(\\d{2})(\\d{2})(\\d{2})","$1-$2-$3",["56"]],["(\\d{3})(\\d{3})","$1-$2",["[2-5]"]],["(\\d{3})(\\d{4})","$1-$2",["[6-8]"]]]],SS:["211","00","[19]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[19]"],"0$1"]],"0"],ST:["239","00","(?:22|9\\d)\\d{5}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[29]"]]]],SV:["503","00","[267]\\d{7}|[89]00\\d{4}(?:\\d{4})?",[7,8,11],[["(\\d{3})(\\d{4})","$1 $2",["[89]"]],["(\\d{4})(\\d{4})","$1 $2",["[267]"]],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["[89]"]]]],SX:["1","011","7215\\d{6}|(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"(5\\d{6})$|1","721$1",0,"721"],SY:["963","00","[1-39]\\d{8}|[1-5]\\d{7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[1-5]"],"0$1",1],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["9"],"0$1",1]],"0"],SZ:["268","00","0800\\d{4}|(?:[237]\\d|900)\\d{6}",[8,9],[["(\\d{4})(\\d{4})","$1 $2",["[0237]"]],["(\\d{5})(\\d{4})","$1 $2",["9"]]]],TA:["290","00","8\\d{3}",[4],0,0,0,0,0,0,"8"],TC:["1","011","(?:[58]\\d\\d|649|900)\\d{7}",[10],0,"1",0,"([2-479]\\d{6})$|1","649$1",0,"649"],TD:["235","00|16","(?:22|[69]\\d|77)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2679]"]]],0,0,0,0,0,0,0,"00"],TG:["228","00","[279]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[279]"]]]],TH:["66","00[1-9]","(?:001800|[2-57]|[689]\\d)\\d{7}|1\\d{7,9}",[8,9,10,13],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[13-9]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]]],"0"],TJ:["992","810","(?:00|[1-57-9]\\d)\\d{7}",[9],[["(\\d{6})(\\d)(\\d{2})","$1 $2 $3",["331","3317"]],["(\\d{3})(\\d{2})(\\d{4})","$1 $2 $3",["[34]7|91[78]"]],["(\\d{4})(\\d)(\\d{4})","$1 $2 $3",["3[1-5]"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[0-57-9]"]]],0,0,0,0,0,0,0,"8~10"],TK:["690","00","[2-47]\\d{3,6}",[4,5,6,7]],TL:["670","00","7\\d{7}|(?:[2-47]\\d|[89]0)\\d{5}",[7,8],[["(\\d{3})(\\d{4})","$1 $2",["[2-489]|70"]],["(\\d{4})(\\d{4})","$1 $2",["7"]]]],TM:["993","810","[1-6]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2-$3-$4",["12"],"(8 $1)"],["(\\d{3})(\\d)(\\d{2})(\\d{2})","$1 $2-$3-$4",["[1-5]"],"(8 $1)"],["(\\d{2})(\\d{6})","$1 $2",["6"],"8 $1"]],"8",0,0,0,0,0,0,"8~10"],TN:["216","00","[2-57-9]\\d{7}",[8],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2-57-9]"]]]],TO:["676","00","(?:0800|(?:[5-8]\\d\\d|999)\\d)\\d{3}|[2-8]\\d{4}",[5,7],[["(\\d{2})(\\d{3})","$1-$2",["[2-4]|50|6[09]|7[0-24-69]|8[05]"]],["(\\d{4})(\\d{3})","$1 $2",["0"]],["(\\d{3})(\\d{4})","$1 $2",["[5-9]"]]]],TR:["90","00","4\\d{6}|8\\d{11,12}|(?:[2-58]\\d\\d|900)\\d{7}",[7,10,12,13],[["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["512|8[01589]|90"],"0$1",1],["(\\d{3})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["5(?:[0-59]|61)","5(?:[0-59]|616)","5(?:[0-59]|6161)"],"0$1",1],["(\\d{3})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[24][1-8]|3[1-9]"],"(0$1)",1],["(\\d{3})(\\d{3})(\\d{6,7})","$1 $2 $3",["80"],"0$1",1]],"0"],TT:["1","011","(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-46-8]\\d{6})$|1","868$1",0,"868"],TV:["688","00","(?:2|7\\d\\d|90)\\d{4}",[5,6,7],[["(\\d{2})(\\d{3})","$1 $2",["2"]],["(\\d{2})(\\d{4})","$1 $2",["90"]],["(\\d{2})(\\d{5})","$1 $2",["7"]]]],TW:["886","0(?:0[25-79]|19)","[2-689]\\d{8}|7\\d{9,10}|[2-8]\\d{7}|2\\d{6}",[7,8,9,10,11],[["(\\d{2})(\\d)(\\d{4})","$1 $2 $3",["202"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[258]0"],"0$1"],["(\\d)(\\d{3,4})(\\d{4})","$1 $2 $3",["[23568]|4(?:0[02-48]|[1-47-9])|7[1-9]","[23568]|4(?:0[2-48]|[1-47-9])|(?:400|7)[1-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[49]"],"0$1"],["(\\d{2})(\\d{4})(\\d{4,5})","$1 $2 $3",["7"],"0$1"]],"0",0,0,0,0,0,0,0,"#"],TZ:["255","00[056]","(?:[25-8]\\d|41|90)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{4})","$1 $2 $3",["[89]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[24]"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["5"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[67]"],"0$1"]],"0"],UA:["380","00","[89]\\d{9}|[3-9]\\d{8}",[9,10],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6[12][29]|(?:3[1-8]|4[136-8]|5[12457]|6[49])2|(?:56|65)[24]","6[12][29]|(?:35|4[1378]|5[12457]|6[49])2|(?:56|65)[24]|(?:3[1-46-8]|46)2[013-9]"],"0$1"],["(\\d{4})(\\d{5})","$1 $2",["3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6[0135689]|7[4-6])|6(?:[12][3-7]|[459])","3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6(?:[015689]|3[02389])|7[4-6])|6(?:[12][3-7]|[459])"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[3-7]|89|9[1-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["[89]"],"0$1"]],"0",0,0,0,0,0,0,"0~0"],UG:["256","00[057]","800\\d{6}|(?:[29]0|[347]\\d)\\d{7}",[9],[["(\\d{4})(\\d{5})","$1 $2",["202","2024"],"0$1"],["(\\d{3})(\\d{6})","$1 $2",["[27-9]|4(?:6[45]|[7-9])"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["[34]"],"0$1"]],"0"],US:["1","011","[2-9]\\d{9}|3\\d{6}",[10],[["(\\d{3})(\\d{4})","$1-$2",["310"],0,1],["(\\d{3})(\\d{3})(\\d{4})","($1) $2-$3",["[2-9]"],0,1,"$1-$2-$3"]],"1",0,0,0,0,0,[["(?:47220[01]|5(?:05(?:[2-57-9]\\d\\d|6(?:[0-35-9]\\d|4[46]))|57200))\\d{4}|(?:2(?:0[1-35-9]|1[02-9]|2[03-589]|3[149]|4[08]|5[1-46]|6[0279]|7[0269]|8[13])|3(?:0[1-57-9]|1[02-9]|2[01356]|3[0-24679]|4[167]|5[0-2]|6[014]|8[056])|4(?:0[124-9]|1[02-579]|2[3-5]|3[0245]|4[023578]|58|6[349]|7[0589]|8[04])|5(?:0[1-47-9]|1[0235-8]|20|3[0149]|4[01]|5[19]|6[1-47]|7[0-5]|8[0256])|6(?:0[1-35-9]|1[024-9]|2[03689]|[34][016]|5[01679]|6[0-279]|78|8[0-29])|7(?:0[1-46-8]|1[2-9]|2[04-7]|3[1247]|4[037]|5[47]|6[02359]|7[0-59]|8[156])|8(?:0[1-68]|1[02-8]|2[068]|3[0-2589]|4[03578]|5[046-9]|6[02-5]|7[028])|9(?:0[1346-9]|1[02-9]|2[0589]|3[0146-8]|4[01357-9]|5[12469]|7[0-389]|8[04-69]))[2-9]\\d{6}"],[""],["8(?:00|33|44|55|66|77|88)[2-9]\\d{6}"],["900[2-9]\\d{6}"],["52(?:3(?:[2-46-9][02-9]\\d|5(?:[02-46-9]\\d|5[0-46-9]))|4(?:[2-478][02-9]\\d|5(?:[034]\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\d)|9(?:[05-9]\\d|2[0-5]|49)))\\d{4}|52[34][2-9]1[02-9]\\d{4}|5(?:00|2[125-9]|33|44|66|77|88)[2-9]\\d{6}"]]],UY:["598","0(?:0|1[3-9]\\d)","(?:0004|4)\\d{9}|[1249]\\d{7}|(?:[49]\\d|80)\\d{5}",[7,8,10,13],[["(\\d{3})(\\d{4})","$1 $2",["405|8|90"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["9"],"0$1"],["(\\d{4})(\\d{4})","$1 $2",["[124]"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["4"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3 $4",["0"]]],"0",0,0,0,0,0,0,"00"," int. "],UZ:["998","810","(?:33|[5-79]\\d|88)\\d{7}",[9],[["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[35-9]"],"8 $1"]],"8",0,0,0,0,0,0,"8~10"],VA:["39","00","0\\d{5,10}|3[0-8]\\d{7,10}|55\\d{8}|8\\d{5}(?:\\d{2,4})?|(?:1\\d|39)\\d{7,8}",[6,7,8,9,10,11],0,0,0,0,0,0,"06698"],VC:["1","011","(?:[58]\\d\\d|784|900)\\d{7}",[10],0,"1",0,"([2-7]\\d{6})$|1","784$1",0,"784"],VE:["58","00","[68]00\\d{7}|(?:[24]\\d|[59]0)\\d{8}",[10],[["(\\d{3})(\\d{7})","$1-$2",["[24-689]"],"0$1"]],"0"],VG:["1","011","(?:284|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-578]\\d{6})$|1","284$1",0,"284"],VI:["1","011","[58]\\d{9}|(?:34|90)0\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","340$1",0,"340"],VN:["84","00","[12]\\d{9}|[135-9]\\d{8}|[16]\\d{7}|[16-8]\\d{6}",[7,8,9,10],[["(\\d{2})(\\d{5})","$1 $2",["80"],"0$1",1],["(\\d{4})(\\d{4,6})","$1 $2",["1"],0,1],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[69]"],"0$1",1],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[3578]"],"0$1",1],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["2[48]"],"0$1",1],["(\\d{3})(\\d{4})(\\d{3})","$1 $2 $3",["2"],"0$1",1]],"0"],VU:["678","00","[57-9]\\d{6}|(?:[238]\\d|48)\\d{3}",[5,7],[["(\\d{3})(\\d{4})","$1 $2",["[57-9]"]]]],WF:["681","00","(?:40|72)\\d{4}|8\\d{5}(?:\\d{3})?",[6,9],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["[478]"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]]]],WS:["685","0","(?:[2-6]|8\\d{5})\\d{4}|[78]\\d{6}|[68]\\d{5}",[5,6,7,10],[["(\\d{5})","$1",["[2-5]|6[1-9]"]],["(\\d{3})(\\d{3,7})","$1 $2",["[68]"]],["(\\d{2})(\\d{5})","$1 $2",["7"]]]],XK:["383","00","[23]\\d{7,8}|(?:4\\d\\d|[89]00)\\d{5}",[8,9],[["(\\d{3})(\\d{5})","$1 $2",["[89]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2-4]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[23]"],"0$1"]],"0"],YE:["967","00","(?:1|7\\d)\\d{7}|[1-7]\\d{6}",[7,8,9],[["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["[1-6]|7(?:[24-6]|8[0-7])"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["7"],"0$1"]],"0"],YT:["262","00","(?:(?:(?:26|63)9|80\\d)\\d\\d|93980)\\d{4}",[9],0,"0",0,0,0,0,"269|63|9398"],ZA:["27","00","[1-79]\\d{8}|8\\d{4,9}",[5,6,7,8,9,10],[["(\\d{2})(\\d{3,4})","$1 $2",["8[1-4]"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,3})","$1 $2 $3",["8[1-4]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["860"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[1-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"],"0$1"]],"0"],ZM:["260","00","800\\d{6}|(?:21|63|[79]\\d)\\d{7}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[28]"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["[79]"],"0$1"]],"0"],ZW:["263","00","2(?:[0-57-9]\\d{6,8}|6[0-24-9]\\d{6,7})|[38]\\d{9}|[35-8]\\d{8}|[3-6]\\d{7}|[1-689]\\d{6}|[1-3569]\\d{5}|[1356]\\d{4}",[5,6,7,8,9,10],[["(\\d{3})(\\d{3,5})","$1 $2",["2(?:0[45]|2[278]|[49]8)|3(?:[09]8|17)|6(?:[29]8|37|75)|[23][78]|(?:33|5[15]|6[68])[78]"],"0$1"],["(\\d)(\\d{3})(\\d{2,4})","$1 $2 $3",["[49]"],"0$1"],["(\\d{3})(\\d{4})","$1 $2",["80"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["24|8[13-59]|(?:2[05-79]|39|5[45]|6[15-8])2","2(?:02[014]|4|[56]20|[79]2)|392|5(?:42|525)|6(?:[16-8]21|52[013])|8[13-59]"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["2(?:1[39]|2[0157]|[378]|[56][14])|3(?:12|29)","2(?:1[39]|2[0157]|[378]|[56][14])|3(?:123|29)"],"0$1"],["(\\d{4})(\\d{6})","$1 $2",["8"],"0$1"],["(\\d{2})(\\d{3,5})","$1 $2",["1|2(?:0[0-36-9]|12|29|[56])|3(?:1[0-689]|[24-6])|5(?:[0236-9]|1[2-4])|6(?:[013-59]|7[0-46-9])|(?:33|55|6[68])[0-69]|(?:29|3[09]|62)[0-79]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["29[013-9]|39|54"],"0$1"],["(\\d{4})(\\d{3,5})","$1 $2",["(?:25|54)8","258|5483"],"0$1"]],"0"]},nonGeographic:{800:["800",0,"(?:00|[1-9]\\d)\\d{6}",[8],[["(\\d{4})(\\d{4})","$1 $2",["\\d"]]],0,0,0,0,0,0,[0,0,["(?:00|[1-9]\\d)\\d{6}"]]],808:["808",0,"[1-9]\\d{7}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[1-9]"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,0,["[1-9]\\d{7}"]]],870:["870",0,"7\\d{11}|[35-7]\\d{8}",[9,12],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[35-7]"]]],0,0,0,0,0,0,[0,["(?:[356]|774[45])\\d{8}|7[6-8]\\d{7}"]]],878:["878",0,"10\\d{10}",[12],[["(\\d{2})(\\d{5})(\\d{5})","$1 $2 $3",["1"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,["10\\d{10}"]]],881:["881",0,"[0-36-9]\\d{8}",[9],[["(\\d)(\\d{3})(\\d{5})","$1 $2 $3",["[0-36-9]"]]],0,0,0,0,0,0,[0,["[0-36-9]\\d{8}"]]],882:["882",0,"[13]\\d{6}(?:\\d{2,5})?|[19]\\d{7}|(?:[25]\\d\\d|4)\\d{7}(?:\\d{2})?",[7,8,9,10,11,12],[["(\\d{2})(\\d{5})","$1 $2",["16|342"]],["(\\d{2})(\\d{6})","$1 $2",["49"]],["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["1[36]|9"]],["(\\d{2})(\\d{4})(\\d{3})","$1 $2 $3",["3[23]"]],["(\\d{2})(\\d{3,4})(\\d{4})","$1 $2 $3",["16"]],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["10|23|3(?:[15]|4[57])|4|51"]],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["34"]],["(\\d{2})(\\d{4,5})(\\d{5})","$1 $2 $3",["[1-35]"]]],0,0,0,0,0,0,[0,["342\\d{4}|(?:337|49)\\d{6}|(?:3(?:2|47|7\\d{3})|50\\d{3})\\d{7}",[7,8,9,10,12]],0,0,0,0,0,0,["1(?:3(?:0[0347]|[13][0139]|2[035]|4[013568]|6[0459]|7[06]|8[15-8]|9[0689])\\d{4}|6\\d{5,10})|(?:345\\d|9[89])\\d{6}|(?:10|2(?:3|85\\d)|3(?:[15]|[69]\\d\\d)|4[15-8]|51)\\d{8}"]]],883:["883",0,"(?:[1-4]\\d|51)\\d{6,10}",[8,9,10,11,12],[["(\\d{3})(\\d{3})(\\d{2,8})","$1 $2 $3",["[14]|2[24-689]|3[02-689]|51[24-9]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["510"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["21"]],["(\\d{4})(\\d{4})(\\d{4})","$1 $2 $3",["51[13]"]],["(\\d{3})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["[235]"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,["(?:2(?:00\\d\\d|10)|(?:370[1-9]|51\\d0)\\d)\\d{7}|51(?:00\\d{5}|[24-9]0\\d{4,7})|(?:1[013-79]|2[24-689]|3[02-689]|4[0-4])0\\d{5,9}"]]],888:["888",0,"\\d{11}",[11],[["(\\d{3})(\\d{3})(\\d{5})","$1 $2 $3"]],0,0,0,0,0,0,[0,0,0,0,0,0,["\\d{11}"]]],979:["979",0,"[1359]\\d{8}",[9],[["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["[1359]"]]],0,0,0,0,0,0,[0,0,0,["[1359]\\d{8}"]]]}};function Lq(e,t){var n=Array.prototype.slice.call(t);return n.push(Rb),e.apply(this,n)}function Xf(e){return Xf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Xf(e)}function gv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Rq(e,t,n){return t&&gv(e.prototype,t),n&&gv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Fq(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function zq(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ha(e,t)}function jq(e){var t=zb();return function(){var r=pa(e),i;if(t){var o=pa(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Vq(this,i)}}function Vq(e,t){if(t&&(Xf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Fb(e)}function Fb(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Zf(e){var t=typeof Map=="function"?new Map:void 0;return Zf=function(r){if(r===null||!Uq(r))return r;if(typeof r!="function")throw new TypeError("Super expression must either be null or a function");if(typeof t<"u"){if(t.has(r))return t.get(r);t.set(r,i)}function i(){return nl(r,arguments,pa(this).constructor)}return i.prototype=Object.create(r.prototype,{constructor:{value:i,enumerable:!1,writable:!0,configurable:!0}}),ha(i,r)},Zf(e)}function nl(e,t,n){return zb()?nl=Reflect.construct:nl=function(i,o,a){var s=[null];s.push.apply(s,o);var c=Function.bind.apply(i,s),l=new c;return a&&ha(l,a.prototype),l},nl.apply(null,arguments)}function zb(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Uq(e){return Function.toString.call(e).indexOf("[native code]")!==-1}function ha(e,t){return ha=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},ha(e,t)}function pa(e){return pa=Object.setPrototypeOf?Object.getPrototypeOf:function(n){return n.__proto__||Object.getPrototypeOf(n)},pa(e)}var Ar=function(e){zq(n,e);var t=jq(n);function n(r){var i;return Fq(this,n),i=t.call(this,r),Object.setPrototypeOf(Fb(i),n.prototype),i.name=i.constructor.name,i}return Rq(n)}(Zf(Error)),m1=2,Bq=17,Hq=3,an="0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9",qq="-\u2010-\u2015\u2212\u30FC\uFF0D",Wq="\uFF0F/",Gq="\uFF0E.",Kq=" \xA0\xAD\u200B\u2060\u3000",Qq="()\uFF08\uFF09\uFF3B\uFF3D\\[\\]",Yq="~\u2053\u223C\uFF5E",vn="".concat(qq).concat(Wq).concat(Gq).concat(Kq).concat(Qq).concat(Yq),eu="+\uFF0B";function yv(e,t){e=e.split("-"),t=t.split("-");for(var n=e[0].split("."),r=t[0].split("."),i=0;i<3;i++){var o=Number(n[i]),a=Number(r[i]);if(o>a)return 1;if(a>o)return-1;if(!isNaN(o)&&isNaN(a))return 1;if(isNaN(o)&&!isNaN(a))return-1}return e[1]&&t[1]?e[1]>t[1]?1:e[1]<t[1]?-1:0:!e[1]&&t[1]?1:e[1]&&!t[1]?-1:0}function bc(e){return bc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},bc(e)}function tu(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function bv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function nu(e,t,n){return t&&bv(e.prototype,t),n&&bv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var Xq="1.2.0",Zq="1.7.35",$v=" ext. ",Jq=/^\d+$/,Mt=function(){function e(t){tu(this,e),rW(t),this.metadata=t,jb.call(this,t)}return nu(e,[{key:"getCountries",value:function(){return Object.keys(this.metadata.countries).filter(function(n){return n!=="001"})}},{key:"getCountryMetadata",value:function(n){return this.metadata.countries[n]}},{key:"nonGeographic",value:function(){if(!(this.v1||this.v2||this.v3))return this.metadata.nonGeographic||this.metadata.nonGeographical}},{key:"hasCountry",value:function(n){return this.getCountryMetadata(n)!==void 0}},{key:"hasCallingCode",value:function(n){if(this.getCountryCodesForCallingCode(n))return!0;if(this.nonGeographic()){if(this.nonGeographic()[n])return!0}else{var r=this.countryCallingCodes()[n];if(r&&r.length===1&&r[0]==="001")return!0}}},{key:"isNonGeographicCallingCode",value:function(n){return this.nonGeographic()?!!this.nonGeographic()[n]:!this.getCountryCodesForCallingCode(n)}},{key:"country",value:function(n){return this.selectNumberingPlan(n)}},{key:"selectNumberingPlan",value:function(n,r){if(n&&Jq.test(n)&&(r=n,n=null),n&&n!=="001"){if(!this.hasCountry(n))throw new Error("Unknown country: ".concat(n));this.numberingPlan=new wv(this.getCountryMetadata(n),this)}else if(r){if(!this.hasCallingCode(r))throw new Error("Unknown calling code: ".concat(r));this.numberingPlan=new wv(this.getNumberingPlanMetadata(r),this)}else this.numberingPlan=void 0;return this}},{key:"getCountryCodesForCallingCode",value:function(n){var r=this.countryCallingCodes()[n];if(r)return r.length===1&&r[0].length===3?void 0:r}},{key:"getCountryCodeForCallingCode",value:function(n){var r=this.getCountryCodesForCallingCode(n);if(r)return r[0]}},{key:"getNumberingPlanMetadata",value:function(n){var r=this.getCountryCodeForCallingCode(n);if(r)return this.getCountryMetadata(r);if(this.nonGeographic()){var i=this.nonGeographic()[n];if(i)return i}else{var o=this.countryCallingCodes()[n];if(o&&o.length===1&&o[0]==="001")return this.metadata.countries["001"]}}},{key:"countryCallingCode",value:function(){return this.numberingPlan.callingCode()}},{key:"IDDPrefix",value:function(){return this.numberingPlan.IDDPrefix()}},{key:"defaultIDDPrefix",value:function(){return this.numberingPlan.defaultIDDPrefix()}},{key:"nationalNumberPattern",value:function(){return this.numberingPlan.nationalNumberPattern()}},{key:"possibleLengths",value:function(){return this.numberingPlan.possibleLengths()}},{key:"formats",value:function(){return this.numberingPlan.formats()}},{key:"nationalPrefixForParsing",value:function(){return this.numberingPlan.nationalPrefixForParsing()}},{key:"nationalPrefixTransformRule",value:function(){return this.numberingPlan.nationalPrefixTransformRule()}},{key:"leadingDigits",value:function(){return this.numberingPlan.leadingDigits()}},{key:"hasTypes",value:function(){return this.numberingPlan.hasTypes()}},{key:"type",value:function(n){return this.numberingPlan.type(n)}},{key:"ext",value:function(){return this.numberingPlan.ext()}},{key:"countryCallingCodes",value:function(){return this.v1?this.metadata.country_phone_code_to_countries:this.metadata.country_calling_codes}},{key:"chooseCountryByCountryCallingCode",value:function(n){return this.selectNumberingPlan(n)}},{key:"hasSelectedNumberingPlan",value:function(){return this.numberingPlan!==void 0}}]),e}(),wv=function(){function e(t,n){tu(this,e),this.globalMetadataObject=n,this.metadata=t,jb.call(this,n.metadata)}return nu(e,[{key:"callingCode",value:function(){return this.metadata[0]}},{key:"getDefaultCountryMetadataForRegion",value:function(){return this.globalMetadataObject.getNumberingPlanMetadata(this.callingCode())}},{key:"IDDPrefix",value:function(){if(!(this.v1||this.v2))return this.metadata[1]}},{key:"defaultIDDPrefix",value:function(){if(!(this.v1||this.v2))return this.metadata[12]}},{key:"nationalNumberPattern",value:function(){return this.v1||this.v2?this.metadata[1]:this.metadata[2]}},{key:"possibleLengths",value:function(){if(!this.v1)return this.metadata[this.v2?2:3]}},{key:"_getFormats",value:function(n){return n[this.v1?2:this.v2?3:4]}},{key:"formats",value:function(){var n=this,r=this._getFormats(this.metadata)||this._getFormats(this.getDefaultCountryMetadataForRegion())||[];return r.map(function(i){return new eW(i,n)})}},{key:"nationalPrefix",value:function(){return this.metadata[this.v1?3:this.v2?4:5]}},{key:"_getNationalPrefixFormattingRule",value:function(n){return n[this.v1?4:this.v2?5:6]}},{key:"nationalPrefixFormattingRule",value:function(){return this._getNationalPrefixFormattingRule(this.metadata)||this._getNationalPrefixFormattingRule(this.getDefaultCountryMetadataForRegion())}},{key:"_nationalPrefixForParsing",value:function(){return this.metadata[this.v1?5:this.v2?6:7]}},{key:"nationalPrefixForParsing",value:function(){return this._nationalPrefixForParsing()||this.nationalPrefix()}},{key:"nationalPrefixTransformRule",value:function(){return this.metadata[this.v1?6:this.v2?7:8]}},{key:"_getNationalPrefixIsOptionalWhenFormatting",value:function(){return!!this.metadata[this.v1?7:this.v2?8:9]}},{key:"nationalPrefixIsOptionalWhenFormattingInNationalFormat",value:function(){return this._getNationalPrefixIsOptionalWhenFormatting(this.metadata)||this._getNationalPrefixIsOptionalWhenFormatting(this.getDefaultCountryMetadataForRegion())}},{key:"leadingDigits",value:function(){return this.metadata[this.v1?8:this.v2?9:10]}},{key:"types",value:function(){return this.metadata[this.v1?9:this.v2?10:11]}},{key:"hasTypes",value:function(){return this.types()&&this.types().length===0?!1:!!this.types()}},{key:"type",value:function(n){if(this.hasTypes()&&_v(this.types(),n))return new nW(_v(this.types(),n),this)}},{key:"ext",value:function(){return this.v1||this.v2?$v:this.metadata[13]||$v}}]),e}(),eW=function(){function e(t,n){tu(this,e),this._format=t,this.metadata=n}return nu(e,[{key:"pattern",value:function(){return this._format[0]}},{key:"format",value:function(){return this._format[1]}},{key:"leadingDigitsPatterns",value:function(){return this._format[2]||[]}},{key:"nationalPrefixFormattingRule",value:function(){return this._format[3]||this.metadata.nationalPrefixFormattingRule()}},{key:"nationalPrefixIsOptionalWhenFormattingInNationalFormat",value:function(){return!!this._format[4]||this.metadata.nationalPrefixIsOptionalWhenFormattingInNationalFormat()}},{key:"nationalPrefixIsMandatoryWhenFormattingInNationalFormat",value:function(){return this.usesNationalPrefix()&&!this.nationalPrefixIsOptionalWhenFormattingInNationalFormat()}},{key:"usesNationalPrefix",value:function(){return!!(this.nationalPrefixFormattingRule()&&!tW.test(this.nationalPrefixFormattingRule()))}},{key:"internationalFormat",value:function(){return this._format[5]||this.format()}}]),e}(),tW=/^\(?\$1\)?$/,nW=function(){function e(t,n){tu(this,e),this.type=t,this.metadata=n}return nu(e,[{key:"pattern",value:function(){return this.metadata.v1?this.type:this.type[0]}},{key:"possibleLengths",value:function(){if(!this.metadata.v1)return this.type[1]||this.metadata.possibleLengths()}}]),e}();function _v(e,t){switch(t){case"FIXED_LINE":return e[0];case"MOBILE":return e[1];case"TOLL_FREE":return e[2];case"PREMIUM_RATE":return e[3];case"PERSONAL_NUMBER":return e[4];case"VOICEMAIL":return e[5];case"UAN":return e[6];case"PAGER":return e[7];case"VOIP":return e[8];case"SHARED_COST":return e[9]}}function rW(e){if(!e)throw new Error("[libphonenumber-js] `metadata` argument not passed. Check your arguments.");if(!fd(e)||!fd(e.countries))throw new Error("[libphonenumber-js] `metadata` argument was passed but it's not a valid metadata. Must be an object having `.countries` child object property. Got ".concat(fd(e)?"an object of shape: { "+Object.keys(e).join(", ")+" }":"a "+iW(e)+": "+e,"."))}var fd=function(t){return bc(t)==="object"},iW=function(t){return bc(t)};function v1(e,t){if(t=new Mt(t),t.hasCountry(e))return t.country(e).countryCallingCode();throw new Error("Unknown country: ".concat(e))}function jb(e){var t=e.version;typeof t=="number"?(this.v1=t===1,this.v2=t===2,this.v3=t===3,this.v4=t===4):t?yv(t,Xq)===-1?this.v2=!0:yv(t,Zq)===-1?this.v3=!0:this.v4=!0:this.v1=!0}var oW=";ext=",hi=function(t){return"([".concat(an,"]{1,").concat(t,"})")};function Vb(e){var t="20",n="15",r="9",i="6",o="[ \xA0\\t,]*",a="[:\\.\uFF0E]?[ \xA0\\t,-]*",s="#?",c="(?:e?xt(?:ensi(?:o\u0301?|\xF3))?n?|\uFF45?\uFF58\uFF54\uFF4E?|\u0434\u043E\u0431|anexo)",l="(?:[x\uFF58#\uFF03~\uFF5E]|int|\uFF49\uFF4E\uFF54)",u="[- ]+",d="[ \xA0\\t]*",f="(?:,{2}|;)",h=oW+hi(t),p=o+c+a+hi(t)+s,m=o+l+a+hi(r)+s,v=u+hi(i)+"#",b=d+f+a+hi(n)+s,y=d+"(?:,)+"+a+hi(r)+s;return h+"|"+p+"|"+m+"|"+v+"|"+b+"|"+y}var aW="["+an+"]{"+m1+"}",sW="["+eu+"]{0,1}(?:["+vn+"]*["+an+"]){3,}["+vn+an+"]*",lW=new RegExp("^["+eu+"]{0,1}(?:["+vn+"]*["+an+"]){1,2}$","i"),cW=sW+"(?:"+Vb()+")?",uW=new RegExp("^"+aW+"$|^"+cW+"$","i");function Ub(e){return e.length>=m1&&uW.test(e)}function dW(e){return lW.test(e)}var xv=new RegExp("(?:"+Vb()+")$","i");function fW(e){var t=e.search(xv);if(t<0)return{};for(var n=e.slice(0,t),r=e.match(xv),i=1;i<r.length;){if(r[i])return{number:n,ext:r[i]};i++}}function hW(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=pW(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3587
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function pW(e,t){if(!!e){if(typeof e=="string")return kv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return kv(e,t)}}function kv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var mW={0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9","\uFF10":"0","\uFF11":"1","\uFF12":"2","\uFF13":"3","\uFF14":"4","\uFF15":"5","\uFF16":"6","\uFF17":"7","\uFF18":"8","\uFF19":"9","\u0660":"0","\u0661":"1","\u0662":"2","\u0663":"3","\u0664":"4","\u0665":"5","\u0666":"6","\u0667":"7","\u0668":"8","\u0669":"9","\u06F0":"0","\u06F1":"1","\u06F2":"2","\u06F3":"3","\u06F4":"4","\u06F5":"5","\u06F6":"6","\u06F7":"7","\u06F8":"8","\u06F9":"9"};function Bb(e){return mW[e]}function $c(e){for(var t="",n=hW(e.split("")),r;!(r=n()).done;){var i=r.value,o=Bb(i);o&&(t+=o)}return t}function vW(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=gW(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3588
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function gW(e,t){if(!!e){if(typeof e=="string")return Ev(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ev(e,t)}}function Ev(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Sv(e){for(var t="",n=vW(e.split("")),r;!(r=n()).done;){var i=r.value;t+=yW(i,t)||""}return t}function yW(e,t){return e==="+"?t?void 0:"+":Bb(e)}function bW(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=$W(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3589
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function $W(e,t){if(!!e){if(typeof e=="string")return Ov(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ov(e,t)}}function Ov(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function wW(e,t){for(var n=e.slice(),r=bW(t),i;!(i=r()).done;){var o=i.value;e.indexOf(o)<0&&n.push(o)}return n.sort(function(a,s){return a-s})}function ru(e,t){return Hb(e,void 0,t)}function Hb(e,t,n){var r=n.type(t),i=r&&r.possibleLengths()||n.possibleLengths();if(!i)return"IS_POSSIBLE";if(t==="FIXED_LINE_OR_MOBILE"){if(!n.type("FIXED_LINE"))return Hb(e,"MOBILE",n);var o=n.type("MOBILE");o&&(i=wW(i,o.possibleLengths()))}else if(t&&!r)return"INVALID_LENGTH";var a=e.length,s=i[0];return s===a?"IS_POSSIBLE":s>a?"TOO_SHORT":i[i.length-1]<a?"TOO_LONG":i.indexOf(a,1)>=0?"IS_POSSIBLE":"INVALID_LENGTH"}function _W(e,t,n){if(t===void 0&&(t={}),n=new Mt(n),t.v2){if(!e.countryCallingCode)throw new Error("Invalid phone number object passed");n.selectNumberingPlan(e.countryCallingCode)}else{if(!e.phone)return!1;if(e.country){if(!n.hasCountry(e.country))throw new Error("Unknown country: ".concat(e.country));n.country(e.country)}else{if(!e.countryCallingCode)throw new Error("Invalid phone number object passed");n.selectNumberingPlan(e.countryCallingCode)}}if(n.possibleLengths())return qb(e.phone||e.nationalNumber,n);if(e.countryCallingCode&&n.isNonGeographicCallingCode(e.countryCallingCode))return!0;throw new Error('Missing "possibleLengths" in metadata. Perhaps the metadata has been generated before v1.0.18.')}function qb(e,t){switch(ru(e,t)){case"IS_POSSIBLE":return!0;default:return!1}}function xW(e,t){return SW(e)||EW(e,t)||Wb(e,t)||kW()}function kW(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
3590
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function EW(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],i=!0,o=!1,a,s;try{for(n=n.call(e);!(i=(a=n.next()).done)&&(r.push(a.value),!(t&&r.length===t));i=!0);}catch(c){o=!0,s=c}finally{try{!i&&n.return!=null&&n.return()}finally{if(o)throw s}}return r}}function SW(e){if(Array.isArray(e))return e}function OW(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=Wb(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3591
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Wb(e,t){if(!!e){if(typeof e=="string")return Cv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Cv(e,t)}}function Cv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function CW(e){var t,n;e=e.replace(/^tel:/,"tel=");for(var r=OW(e.split(";")),i;!(i=r()).done;){var o=i.value,a=o.split("="),s=xW(a,2),c=s[0],l=s[1];switch(c){case"tel":t=l;break;case"ext":n=l;break;case"phone-context":l[0]==="+"&&(t=l+t);break}}if(!Ub(t))return{};var u={number:t};return n&&(u.ext=n),u}function NW(e){var t=e.number,n=e.ext;if(!t)return"";if(t[0]!=="+")throw new Error('"formatRFC3966()" expects "number" to be in E.164 format.');return"tel:".concat(t).concat(n?";ext="+n:"")}function Gn(e,t){return e=e||"",new RegExp("^(?:"+t+")$").test(e)}function TW(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=PW(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3592
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function PW(e,t){if(!!e){if(typeof e=="string")return Nv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Nv(e,t)}}function Nv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var AW=["MOBILE","PREMIUM_RATE","TOLL_FREE","SHARED_COST","VOIP","PERSONAL_NUMBER","PAGER","UAN","VOICEMAIL"];function g1(e,t,n){if(t=t||{},!!e.country){n=new Mt(n),n.selectNumberingPlan(e.country,e.countryCallingCode);var r=t.v2?e.nationalNumber:e.phone;if(!!Gn(r,n.nationalNumberPattern())){if(hd(r,"FIXED_LINE",n))return n.type("MOBILE")&&n.type("MOBILE").pattern()===""||!n.type("MOBILE")||hd(r,"MOBILE",n)?"FIXED_LINE_OR_MOBILE":"FIXED_LINE";for(var i=TW(AW),o;!(o=i()).done;){var a=o.value;if(hd(r,a,n))return a}}}}function hd(e,t,n){return t=n.type(t),!t||!t.pattern()||t.possibleLengths()&&t.possibleLengths().indexOf(e.length)<0?!1:Gn(e,t.pattern())}function IW(e,t,n){if(t=t||{},n=new Mt(n),n.selectNumberingPlan(e.country,e.countryCallingCode),n.hasTypes())return g1(e,t,n.metadata)!==void 0;var r=t.v2?e.nationalNumber:e.phone;return Gn(r,n.nationalNumberPattern())}function MW(e,t,n){var r=new Mt(n),i=r.getCountryCodesForCallingCode(e);return i?i.filter(function(o){return DW(t,o,n)}):[]}function DW(e,t,n){var r=new Mt(n);return r.selectNumberingPlan(t),r.numberingPlan.possibleLengths().indexOf(e.length)>=0}function Gb(e){return e.replace(new RegExp("[".concat(vn,"]+"),"g")," ").trim()}var Kb=/(\$\d)/;function Qb(e,t,n){var r=n.useInternationalFormat,i=n.withNationalPrefix;n.carrierCode,n.metadata;var o=e.replace(new RegExp(t.pattern()),r?t.internationalFormat():i&&t.nationalPrefixFormattingRule()?t.format().replace(Kb,t.nationalPrefixFormattingRule()):t.format());return r?Gb(o):o}var LW=/^[\d]+(?:[~\u2053\u223C\uFF5E][\d]+)?$/;function RW(e,t,n){var r=new Mt(n);if(r.selectNumberingPlan(e,t),r.defaultIDDPrefix())return r.defaultIDDPrefix();if(LW.test(r.IDDPrefix()))return r.IDDPrefix()}function FW(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=zW(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3593
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function zW(e,t){if(!!e){if(typeof e=="string")return Tv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Tv(e,t)}}function Tv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Pv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Av(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Pv(Object(n),!0).forEach(function(r){jW(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pv(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function jW(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Iv={formatExtension:function(t,n,r){return"".concat(t).concat(r.ext()).concat(n)}};function VW(e,t,n,r){if(n?n=Av(Av({},Iv),n):n=Iv,r=new Mt(r),e.country&&e.country!=="001"){if(!r.hasCountry(e.country))throw new Error("Unknown country: ".concat(e.country));r.country(e.country)}else if(e.countryCallingCode)r.selectNumberingPlan(e.countryCallingCode);else return e.phone||"";var i=r.countryCallingCode(),o=n.v2?e.nationalNumber:e.phone,a;switch(t){case"NATIONAL":return o?(a=wc(o,e.carrierCode,"NATIONAL",r,n),pd(a,e.ext,r,n.formatExtension)):"";case"INTERNATIONAL":return o?(a=wc(o,null,"INTERNATIONAL",r,n),a="+".concat(i," ").concat(a),pd(a,e.ext,r,n.formatExtension)):"+".concat(i);case"E.164":return"+".concat(i).concat(o);case"RFC3966":return NW({number:"+".concat(i).concat(o),ext:e.ext});case"IDD":if(!n.fromCountry)return;var s=BW(o,e.carrierCode,i,n.fromCountry,r);return pd(s,e.ext,r,n.formatExtension);default:throw new Error('Unknown "format" argument passed to "formatNumber()": "'.concat(t,'"'))}}function wc(e,t,n,r,i){var o=UW(r.formats(),e);return o?Qb(e,o,{useInternationalFormat:n==="INTERNATIONAL",withNationalPrefix:!(o.nationalPrefixIsOptionalWhenFormattingInNationalFormat()&&i&&i.nationalPrefix===!1),carrierCode:t,metadata:r}):e}function UW(e,t){for(var n=FW(e),r;!(r=n()).done;){var i=r.value;if(i.leadingDigitsPatterns().length>0){var o=i.leadingDigitsPatterns()[i.leadingDigitsPatterns().length-1];if(t.search(o)!==0)continue}if(Gn(t,i.pattern()))return i}}function pd(e,t,n,r){return t?r(e,t,n):e}function BW(e,t,n,r,i){var o=v1(r,i.metadata);if(o===n){var a=wc(e,t,"NATIONAL",i);return n==="1"?n+" "+a:a}var s=RW(r,void 0,i.metadata);if(s)return"".concat(s," ").concat(n," ").concat(wc(e,null,"INTERNATIONAL",i))}function Mv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Dv(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Mv(Object(n),!0).forEach(function(r){HW(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mv(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function HW(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qW(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Lv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function WW(e,t,n){return t&&Lv(e.prototype,t),n&&Lv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var Yb=function(){function e(t,n,r){if(qW(this,e),!t)throw new TypeError("`country` or `countryCallingCode` not passed");if(!n)throw new TypeError("`nationalNumber` not passed");if(!r)throw new TypeError("`metadata` not passed");var i=KW(t,r),o=i.country,a=i.countryCallingCode;this.country=o,this.countryCallingCode=a,this.nationalNumber=n,this.number="+"+this.countryCallingCode+this.nationalNumber,this.metadata=r}return WW(e,[{key:"setExt",value:function(n){this.ext=n}},{key:"getPossibleCountries",value:function(){return this.country?[this.country]:MW(this.countryCallingCode,this.nationalNumber,this.metadata)}},{key:"isPossible",value:function(){return _W(this,{v2:!0},this.metadata)}},{key:"isValid",value:function(){return IW(this,{v2:!0},this.metadata)}},{key:"isNonGeographic",value:function(){var n=new Mt(this.metadata);return n.isNonGeographicCallingCode(this.countryCallingCode)}},{key:"isEqual",value:function(n){return this.number===n.number&&this.ext===n.ext}},{key:"getType",value:function(){return g1(this,{v2:!0},this.metadata)}},{key:"format",value:function(n,r){return VW(this,n,r?Dv(Dv({},r),{},{v2:!0}):{v2:!0},this.metadata)}},{key:"formatNational",value:function(n){return this.format("NATIONAL",n)}},{key:"formatInternational",value:function(n){return this.format("INTERNATIONAL",n)}},{key:"getURI",value:function(n){return this.format("RFC3966",n)}}]),e}(),GW=function(t){return/^[A-Z]{2}$/.test(t)};function KW(e,t){var n,r,i=new Mt(t);return GW(e)?(n=e,i.selectNumberingPlan(n),r=i.countryCallingCode()):r=e,{country:n,countryCallingCode:r}}var QW=new RegExp("(["+an+"])");function Xb(e,t,n,r){if(!!t){var i=new Mt(r);i.selectNumberingPlan(t,n);var o=new RegExp(i.IDDPrefix());if(e.search(o)===0){e=e.slice(e.match(o)[0].length);var a=e.match(QW);if(!(a&&a[1]!=null&&a[1].length>0&&a[1]==="0"))return e}}}function Jf(e,t){if(e&&t.numberingPlan.nationalPrefixForParsing()){var n=new RegExp("^(?:"+t.numberingPlan.nationalPrefixForParsing()+")"),r=n.exec(e);if(r){var i,o,a=r.length-1,s=a>0&&r[a];if(t.nationalPrefixTransformRule()&&s)i=e.replace(n,t.nationalPrefixTransformRule()),a>1&&(o=r[1]);else{var c=r[0];i=e.slice(c.length),s&&(o=r[1])}var l;if(s){var u=e.indexOf(r[1]),d=e.slice(0,u);d===t.numberingPlan.nationalPrefix()&&(l=t.numberingPlan.nationalPrefix())}else l=r[0];return{nationalNumber:i,nationalPrefix:l,carrierCode:o}}}return{nationalNumber:e}}function eh(e,t){var n=Jf(e,t),r=n.carrierCode,i=n.nationalNumber;if(i!==e){if(!YW(e,i,t))return{nationalNumber:e};if(t.possibleLengths()&&!XW(i,t))return{nationalNumber:e}}return{nationalNumber:i,carrierCode:r}}function YW(e,t,n){return!(Gn(e,n.nationalNumberPattern())&&!Gn(t,n.nationalNumberPattern()))}function XW(e,t){switch(ru(e,t)){case"TOO_SHORT":case"INVALID_LENGTH":return!1;default:return!0}}function Zb(e,t,n,r){var i=t?v1(t,r):n;if(e.indexOf(i)===0){r=new Mt(r),r.selectNumberingPlan(t,n);var o=e.slice(i.length),a=eh(o,r),s=a.nationalNumber,c=eh(e,r),l=c.nationalNumber;if(!Gn(l,r.nationalNumberPattern())&&Gn(s,r.nationalNumberPattern())||ru(l,r)==="TOO_LONG")return{countryCallingCode:i,number:o}}return{number:e}}function Jb(e,t,n,r){if(!e)return{};if(e[0]!=="+"){var i=Xb(e,t,n,r);if(i&&i!==e)e="+"+i;else{if(t||n){var o=Zb(e,t,n,r),a=o.countryCallingCode,s=o.number;if(a)return{countryCallingCode:a,number:s}}return{number:e}}}if(e[1]==="0")return{};r=new Mt(r);for(var c=2;c-1<=Hq&&c<=e.length;){var l=e.slice(1,c);if(r.hasCallingCode(l))return r.selectNumberingPlan(l),{countryCallingCode:l,number:e.slice(c)};c++}return{}}function ZW(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=JW(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3594
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function JW(e,t){if(!!e){if(typeof e=="string")return Rv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Rv(e,t)}}function Rv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function eG(e,t,n){n=new Mt(n);for(var r=ZW(e),i;!(i=r()).done;){var o=i.value;if(n.country(o),n.leadingDigits()){if(t&&t.search(n.leadingDigits())===0)return o}else if(g1({phone:t,country:o},void 0,n.metadata))return o}}var tG=!1;function e4(e,t,n){if(tG&&n.isNonGeographicCallingCode(e))return"001";var r=n.getCountryCodesForCallingCode(e);if(!!r)return r.length===1?r[0]:eG(r,t,n.metadata)}var nG=250,rG=new RegExp("["+eu+an+"]"),iG=new RegExp("[^"+an+"#]+$");function oG(e,t,n){if(t=t||{},n=new Mt(n),t.defaultCountry&&!n.hasCountry(t.defaultCountry))throw t.v2?new Ar("INVALID_COUNTRY"):new Error("Unknown country: ".concat(t.defaultCountry));var r=sG(e,t.v2,t.extract),i=r.number,o=r.ext,a=r.error;if(!i){if(t.v2)throw a==="TOO_SHORT"?new Ar("TOO_SHORT"):new Ar("NOT_A_NUMBER");return{}}var s=cG(i,t.defaultCountry,t.defaultCallingCode,n),c=s.country,l=s.nationalNumber,u=s.countryCallingCode,d=s.carrierCode;if(!n.hasSelectedNumberingPlan()){if(t.v2)throw new Ar("INVALID_COUNTRY");return{}}if(!l||l.length<m1){if(t.v2)throw new Ar("TOO_SHORT");return{}}if(l.length>Bq){if(t.v2)throw new Ar("TOO_LONG");return{}}if(t.v2){var f=new Yb(u,l,n.metadata);return c&&(f.country=c),d&&(f.carrierCode=d),o&&(f.ext=o),f}var h=(t.extended?n.hasSelectedNumberingPlan():c)?Gn(l,n.nationalNumberPattern()):!1;return t.extended?{country:c,countryCallingCode:u,carrierCode:d,valid:h,possible:h?!0:!!(t.extended===!0&&n.possibleLengths()&&qb(l,n)),phone:l,ext:o}:h?lG(c,l,o):{}}function aG(e,t,n){if(!!e){if(e.length>nG){if(n)throw new Ar("TOO_LONG");return}if(t===!1)return e;var r=e.search(rG);if(!(r<0))return e.slice(r).replace(iG,"")}}function sG(e,t,n){if(e&&e.indexOf("tel:")===0)return CW(e);var r=aG(e,n,t);if(!r)return{};if(!Ub(r))return dW(r)?{error:"TOO_SHORT"}:{};var i=fW(r);return i.ext?i:{number:r}}function lG(e,t,n){var r={country:e,phone:t};return n&&(r.ext=n),r}function cG(e,t,n,r){var i=Jb(Sv(e),t,n,r.metadata),o=i.countryCallingCode,a=i.number,s;if(o)r.selectNumberingPlan(o);else if(a&&(t||n))r.selectNumberingPlan(t,n),t&&(s=t),o=n||v1(t,r.metadata);else return{};if(!a)return{countryCallingCode:o};var c=eh(Sv(a),r),l=c.nationalNumber,u=c.carrierCode,d=e4(o,l,r);return d&&(s=d,d==="001"||r.country(s)),{country:s,countryCallingCode:o,nationalNumber:l,carrierCode:u}}function Fv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function zv(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Fv(Object(n),!0).forEach(function(r){uG(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fv(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uG(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function dG(e,t,n){return oG(e,zv(zv({},t),{},{v2:!0}),n)}function th(e){return th=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},th(e)}function jv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function fG(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?jv(Object(n),!0).forEach(function(r){hG(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jv(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function hG(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pG(e,t){return yG(e)||gG(e,t)||vG(e,t)||mG()}function mG(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
3595
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vG(e,t){if(!!e){if(typeof e=="string")return Vv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Vv(e,t)}}function Vv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function gG(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],i=!0,o=!1,a,s;try{for(n=n.call(e);!(i=(a=n.next()).done)&&(r.push(a.value),!(t&&r.length===t));i=!0);}catch(c){o=!0,s=c}finally{try{!i&&n.return!=null&&n.return()}finally{if(o)throw s}}return r}}function yG(e){if(Array.isArray(e))return e}function bG(e){var t=Array.prototype.slice.call(e),n=pG(t,4),r=n[0],i=n[1],o=n[2],a=n[3],s,c,l;if(typeof r=="string")s=r;else throw new TypeError("A text for parsing must be a string.");if(!i||typeof i=="string")a?(c=o,l=a):(c=void 0,l=o),i&&(c=fG({defaultCountry:i},c));else if($G(i))o?(c=i,l=o):l=i;else throw new Error("Invalid second argument: ".concat(i));return{text:s,options:c,metadata:l}}var $G=function(t){return th(t)==="object"};function wG(){var e=bG(arguments),t=e.text,n=e.options,r=e.metadata;return dG(t,n,r)}function _G(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Uv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function xG(e,t,n){return t&&Uv(e.prototype,t),n&&Uv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var kG=function(){function e(t){var n=t.onCountryChange,r=t.onCallingCodeChange;_G(this,e),this.onCountryChange=n,this.onCallingCodeChange=r}return xG(e,[{key:"reset",value:function(n){var r=n.country,i=n.callingCode;this.international=!1,this.IDDPrefix=void 0,this.missingPlus=void 0,this.callingCode=void 0,this.digits="",this.resetNationalSignificantNumber(),this.initCountryAndCallingCode(r,i)}},{key:"resetNationalSignificantNumber",value:function(){this.nationalSignificantNumber=this.getNationalDigits(),this.nationalSignificantNumberMatchesInput=!0,this.nationalPrefix=void 0,this.carrierCode=void 0,this.complexPrefixBeforeNationalSignificantNumber=void 0}},{key:"update",value:function(n){for(var r=0,i=Object.keys(n);r<i.length;r++){var o=i[r];this[o]=n[o]}}},{key:"initCountryAndCallingCode",value:function(n,r){this.setCountry(n),this.setCallingCode(r)}},{key:"setCountry",value:function(n){this.country=n,this.onCountryChange(n)}},{key:"setCallingCode",value:function(n){this.callingCode=n,this.onCallingCodeChange(n,this.country)}},{key:"startInternationalNumber",value:function(n,r){this.international=!0,this.initCountryAndCallingCode(n,r)}},{key:"appendDigits",value:function(n){this.digits+=n}},{key:"appendNationalSignificantNumberDigits",value:function(n){this.nationalSignificantNumber+=n}},{key:"getNationalDigits",value:function(){return this.international?this.digits.slice((this.IDDPrefix?this.IDDPrefix.length:0)+(this.callingCode?this.callingCode.length:0)):this.digits}},{key:"getDigitsWithoutInternationalPrefix",value:function(){return this.international&&this.IDDPrefix?this.digits.slice(this.IDDPrefix.length):this.digits}}]),e}();function EG(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=SG(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3596
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function SG(e,t){if(!!e){if(typeof e=="string")return Bv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Bv(e,t)}}function Bv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var cn="x",md=new RegExp(cn);function rl(e,t){if(t<1)return"";for(var n="";t>1;)t&1&&(n+=e),t>>=1,e+=e;return n+e}function Hv(e,t){return e[t]===")"&&t++,OG(e.slice(0,t))}function OG(e){for(var t=[],n=0;n<e.length;)e[n]==="("?t.push(n):e[n]===")"&&t.pop(),n++;var r=0,i="";t.push(e.length);for(var o=0,a=t;o<a.length;o++){var s=a[o];i+=e.slice(r,s),r=s+1}return i}function CG(e,t,n){for(var r=EG(n.split("")),i;!(i=r()).done;){var o=i.value;if(e.slice(t+1).search(md)<0)return;t=e.search(md),e=e.replace(md,o)}return[e,t]}function NG(e,t,n){var r=n.metadata,i=n.shouldTryNationalPrefixFormattingRule,o=n.getSeparatorAfterNationalPrefix,a=new RegExp("^(?:".concat(t.pattern(),")$"));if(a.test(e.nationalSignificantNumber))return PG(e,t,{metadata:r,shouldTryNationalPrefixFormattingRule:i,getSeparatorAfterNationalPrefix:o})}function TG(e,t){return ru(e,t)==="IS_POSSIBLE"}function PG(e,t,n){var r=n.metadata,i=n.shouldTryNationalPrefixFormattingRule,o=n.getSeparatorAfterNationalPrefix;if(e.nationalSignificantNumber,e.international,e.nationalPrefix,e.carrierCode,i(t)){var a=qv(e,t,{useNationalPrefixFormattingRule:!0,getSeparatorAfterNationalPrefix:o,metadata:r});if(a)return a}return qv(e,t,{useNationalPrefixFormattingRule:!1,getSeparatorAfterNationalPrefix:o,metadata:r})}function qv(e,t,n){var r=n.metadata,i=n.useNationalPrefixFormattingRule,o=n.getSeparatorAfterNationalPrefix,a=Qb(e.nationalSignificantNumber,t,{carrierCode:e.carrierCode,useInternationalFormat:e.international,withNationalPrefix:i,metadata:r});if(i||(e.nationalPrefix?a=e.nationalPrefix+o(t)+a:e.complexPrefixBeforeNationalSignificantNumber&&(a=e.complexPrefixBeforeNationalSignificantNumber+" "+a)),AG(a,e))return a}function AG(e,t){return $c(e)===t.getNationalDigits()}function IG(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Wv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function MG(e,t,n){return t&&Wv(e.prototype,t),n&&Wv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var DG=function(){function e(){IG(this,e)}return MG(e,[{key:"parse",value:function(n){if(this.context=[{or:!0,instructions:[]}],this.parsePattern(n),this.context.length!==1)throw new Error("Non-finalized contexts left when pattern parse ended");var r=this.context[0],i=r.branches,o=r.instructions;if(i)return{op:"|",args:i.concat([vd(o)])};if(o.length===0)throw new Error("Pattern is required");return o.length===1?o[0]:o}},{key:"startContext",value:function(n){this.context.push(n)}},{key:"endContext",value:function(){this.context.pop()}},{key:"getContext",value:function(){return this.context[this.context.length-1]}},{key:"parsePattern",value:function(n){if(!n)throw new Error("Pattern is required");var r=n.match(FG);if(!r){if(RG.test(n))throw new Error("Illegal characters found in a pattern: ".concat(n));this.getContext().instructions=this.getContext().instructions.concat(n.split(""));return}var i=r[1],o=n.slice(0,r.index),a=n.slice(r.index+i.length);switch(i){case"(?:":o&&this.parsePattern(o),this.startContext({or:!0,instructions:[],branches:[]});break;case")":if(!this.getContext().or)throw new Error('")" operator must be preceded by "(?:" operator');if(o&&this.parsePattern(o),this.getContext().instructions.length===0)throw new Error('No instructions found after "|" operator in an "or" group');var s=this.getContext(),c=s.branches;c.push(vd(this.getContext().instructions)),this.endContext(),this.getContext().instructions.push({op:"|",args:c});break;case"|":if(!this.getContext().or)throw new Error('"|" operator can only be used inside "or" groups');if(o&&this.parsePattern(o),!this.getContext().branches)if(this.context.length===1)this.getContext().branches=[];else throw new Error('"branches" not found in an "or" group context');this.getContext().branches.push(vd(this.getContext().instructions)),this.getContext().instructions=[];break;case"[":o&&this.parsePattern(o),this.startContext({oneOfSet:!0});break;case"]":if(!this.getContext().oneOfSet)throw new Error('"]" operator must be preceded by "[" operator');this.endContext(),this.getContext().instructions.push({op:"[]",args:LG(o)});break;default:throw new Error("Unknown operator: ".concat(i))}a&&this.parsePattern(a)}}]),e}();function LG(e){for(var t=[],n=0;n<e.length;){if(e[n]==="-"){if(n===0||n===e.length-1)throw new Error("Couldn't parse a one-of set pattern: ".concat(e));for(var r=e[n-1].charCodeAt(0)+1,i=e[n+1].charCodeAt(0)-1,o=r;o<=i;)t.push(String.fromCharCode(o)),o++}else t.push(e[n]);n++}return t}var RG=/[\(\)\[\]\?\:\|]/,FG=new RegExp("(\\||\\(\\?\\:|\\)|\\[|\\])");function vd(e){return e.length===1?e[0]:e}function Gv(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=zG(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3597
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function zG(e,t){if(!!e){if(typeof e=="string")return Kv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Kv(e,t)}}function Kv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function jG(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Qv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function VG(e,t,n){return t&&Qv(e.prototype,t),n&&Qv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var UG=function(){function e(t){jG(this,e),this.matchTree=new DG().parse(t)}return VG(e,[{key:"match",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.allowOverflow;if(!n)throw new Error("String is required");var o=nh(n.split(""),this.matchTree,!0);if(o&&o.match&&delete o.matchedChars,!(o&&o.overflow&&!i))return o}}]),e}();function nh(e,t,n){if(typeof t=="string"){var r=e.join("");return t.indexOf(r)===0?e.length===t.length?{match:!0,matchedChars:e}:{partialMatch:!0}:r.indexOf(t)===0?n&&e.length>t.length?{overflow:!0}:{match:!0,matchedChars:e.slice(0,t.length)}:void 0}if(Array.isArray(t)){for(var i=e.slice(),o=0;o<t.length;){var a=t[o],s=nh(i,a,n&&o===t.length-1);if(s){if(s.overflow)return s;if(s.match){if(i=i.slice(s.matchedChars.length),i.length===0)return o===t.length-1?{match:!0,matchedChars:e}:{partialMatch:!0}}else{if(s.partialMatch)return{partialMatch:!0};throw new Error(`Unsupported match result:
|
|
3598
3598
|
`.concat(JSON.stringify(s,null,2)))}}else return;o++}return n?{overflow:!0}:{match:!0,matchedChars:e.slice(0,e.length-i.length)}}switch(t.op){case"|":for(var c,l=Gv(t.args),u;!(u=l()).done;){var d=u.value,f=nh(e,d,n);if(f){if(f.overflow)return f;if(f.match)return{match:!0,matchedChars:f.matchedChars};if(f.partialMatch)c=!0;else throw new Error(`Unsupported match result:
|
|
3599
|
-
`.concat(JSON.stringify(f,null,2)))}}return c?{partialMatch:!0}:void 0;case"[]":for(var h=Gv(t.args),p;!(p=h()).done;){var m=p.value;if(e[0]===m)return e.length===1?{match:!0,matchedChars:e}:n?{overflow:!0}:{match:!0,matchedChars:[m]}}return;default:throw new Error("Unsupported instruction tree: ".concat(t))}}function Yv(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=
|
|
3600
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3601
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3602
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function
|
|
3603
|
-
`,rs=
|
|
3604
|
-
`,
|
|
3605
|
-
`,OK=T("<div><style></style><style></style></div>"),yd=[{id:"1",name:"Male/Man"},{id:"2",name:"Female/Woman"},{id:"3",name:"TransMale/TransMan"},{id:"4",name:"TransFemale/TransWoman"},{id:"5",name:"Genderqueery/Gender nonconforming"},{id:"6",name:"Something else"},{id:"7",name:"Decline to answer"}];Me("photon-gender-input",{label:void 0,required:!1,value:void 0,invalid:!1,helpText:void 0,disabled:!1,selected:void 0},e=>{const[t,n]=V("");let r;const i=s=>s.length===0?yd:yd.filter(c=>c.name.toLowerCase().includes(s.toLowerCase())),o=s=>{const c=new CustomEvent("photon-gender-selected",{composed:!0,bubbles:!0,detail:{gender:s}});r?.dispatchEvent(c)},a=()=>{const s=new CustomEvent("photon-gender-deselected",{composed:!0,bubbles:!0,detail:{}});r?.dispatchEvent(s)};return(()=>{const s=OK.cloneNode(!0),c=s.firstChild,l=c.nextSibling,u=r;return typeof u=="function"?he(u,s):r=s,s.addEventListener("photon-data-selected",d=>{o(d.detail.data.name)}),s.addEventListener("photon-data-unselected",()=>{a()}),k(c,Je),k(l,SK),k(s,S(wn,{get data(){return i(t())},get label(){return e.label},get required(){return e.required},placeholder:"",get disabled(){return e.disabled},get invalid(){return e.invalid},isLoading:!1,hasMore:!1,displayAccessor:d=>d?.name||"",showOverflow:!0,onSearchChange:async d=>{n(d)},onHide:async()=>{n("")},noDataMsg:"",get optional(){return!e.required},get helpText(){return e.helpText},get selectedData(){return yd.filter(d=>d.name===e.selected)?.[0]}}),null),s})()});const CK=T('<div class="flex align-center justify-center h-screen"><sl-spinner class="mt-8"></sl-spinner></div>'),NK=T('<photon-card title="Personal"><div class="flex flex-col xs:flex-row xs:gap-4"><photon-text-input class="flex-grow min-w-[40%]" debounce-time="0" label="First Name"></photon-text-input><photon-text-input class="min-w-[48%]" debounce-time="0" label="Last Name"></photon-text-input></div><div class="flex flex-col xs:flex-row items-center xs:gap-4"><photon-datepicker no-initial-date="true" class="flex-grow w-full xs:min-w-[40%]" label="Date of Birth"></photon-datepicker><photon-phone-input class="w-full xs:min-w-[48%]" label="Phone Number"></photon-phone-input></div><div class="flex flex-col xs:flex-row justify-between xs:gap-4"><div class="flex-grow w-full xs:min-w-[40%]"><photon-gender-input label="Gender" required="false"></photon-gender-input></div><div class="flex-grow w-full xs:min-w-[40%]"><photon-sex-input label="Sex at Birth" required="false"></photon-sex-input></div></div><photon-text-input debounce-time="0" label="Email"></photon-text-input><hr class="py-2"><p class="font-sans text-lg flex-grow">Address</p><photon-text-input debounce-time="0" label="Street 1"></photon-text-input><photon-text-input debounce-time="0" label="Street 2"></photon-text-input><photon-text-input debounce-time="0" label="City"></photon-text-input><div class="flex gap-4 pb-5 xs:pb-2"><photon-state-input class="flex-grow min-w-[40%]" label="State" required="false"></photon-state-input><photon-text-input debounce-time="0" class="flex-grow min-w-[40%]" label="Zip Code"></photon-text-input></div><hr class="py-2"><p class="font-sans text-lg flex-grow">Preferred Local Pharmacy</p><photon-pharmacy-search></photon-pharmacy-search></photon-card>'),TK=T('<div class="w-full h-full relative"><style></style><style></style><style></style></div>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");const PK=(e,t)=>{const n=e.selectedPatient.data?.address;return t.address_zip?.value&&j4(t.address_zip?.value)&&t.address_zip?.value!=n?.postalCode?t.address_zip?.value:n?`${n.street1} ${n.street2??""} ${n.city}, ${n.state} ${n.postalCode}`:""};Me("photon-patient-form",{patientId:""},e=>{let t;const n=pt(),{store:r,actions:i}=Gc,{actions:o}=Lb,{store:a,actions:s}=Q3({firstName:void 0,lastName:void 0,dateOfBirth:void 0,phone:void 0,gender:void 0,sex:void 0,email:void 0,address_street1:void 0,address_street2:void 0,address_city:void 0,address_state:void 0,address_zip:void 0,preferredPharmacy:void 0});s.registerValidator({key:"firstName",validator:st(fr(Kt(),1,1/0),"Please enter a first name.")}),s.registerValidator({key:"lastName",validator:st(fr(Kt(),1,1/0),"Please enter a last name.")}),s.registerValidator({key:"dateOfBirth",validator:st(nd([LT,sd()]),"Please enter a valid date of birth.")}),s.registerValidator({key:"sex",validator:st(Yk(oh.map(l=>l.name)),"Please enter Sex at Birth.")}),s.registerValidator({key:"phone",validator:st(fr(Kt(),12),"Please enter a valid phone number.")}),s.registerValidator({key:"email",validator:st(nd([zT(),sd()]),"Please enter a valid email.")}),s.registerValidator({key:"address_zip",validator:st(nd([FT(),sd()]),"Please enter a valid zip code...")}),ht(()=>{e.patientId?i.getSelectedPatient(n.getSDK(),e.patientId):i.clearSelectedPatient()});const c=l=>{const u=new CustomEvent("photon-form-updated",{composed:!0,bubbles:!0,detail:{form:l,actions:s,selected:r,reset:()=>{s.reset(),i.reset(),o.reset()}}});t?.dispatchEvent(u)};return me(()=>{r.selectedPatient.data&&(s.updateFormValue({key:"firstName",value:r.selectedPatient.data.name.first}),s.updateFormValue({key:"lastName",value:r.selectedPatient.data.name.last}),s.updateFormValue({key:"phone",value:r.selectedPatient.data.phone}),s.updateFormValue({key:"gender",value:r.selectedPatient.data.gender}),s.updateFormValue({key:"sex",value:r.selectedPatient.data.sex}),s.updateFormValue({key:"email",value:r.selectedPatient.data.email}),s.updateFormValue({key:"address_street1",value:r.selectedPatient.data.address?.street1}),s.updateFormValue({key:"address_street2",value:r.selectedPatient.data.address?.street2}),s.updateFormValue({key:"address_city",value:r.selectedPatient.data.address?.city}),s.updateFormValue({key:"address_state",value:r.selectedPatient.data.address?.state}),s.updateFormValue({key:"address_zip",value:r.selectedPatient.data.address?.postalCode}),s.updateFormValue({key:"preferredPharmacy",value:r.selectedPatient.data.preferredPharmacies?.[0]?.id}))}),me(()=>{c(a)}),Gi(()=>{i.clearSelectedPatient(),s.reset()}),(()=>{const l=TK.cloneNode(!0),u=l.firstChild,d=u.nextSibling,f=d.nextSibling,h=t;return typeof h=="function"?he(h,l):t=l,k(u,Je),k(d,Xt),k(f,Yt),k(l,S(ee,{get when(){return r.selectedPatient.isLoading},get children(){const p=H(()=>document.importNode(CK,!0)),m=p.firstChild;return m.style.setProperty("font-size","3rem"),m._$owner=A(),p}}),null),k(l,S(ee,{get when(){return!r.selectedPatient.isLoading},get children(){return S(Db,{permissions:["write:patient"],get children(){const p=H(()=>document.importNode(NK,!0)),m=p.firstChild,v=m.firstChild,b=v.nextSibling,y=m.nextSibling,g=y.firstChild,_=g.nextSibling,x=y.nextSibling,O=x.firstChild,C=O.firstChild,M=O.nextSibling,D=M.firstChild,F=x.nextSibling,Y=F.nextSibling,J=Y.nextSibling,G=J.nextSibling,j=G.nextSibling,z=j.nextSibling,Q=z.nextSibling,I=Q.firstChild,U=I.nextSibling,W=Q.nextSibling,de=W.nextSibling,be=de.nextSibling;return p._$owner=A(),v.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"firstName",value:P.detail.input})}),v._$owner=A(),b.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"lastName",value:P.detail.input})}),b._$owner=A(),g.addEventListener("photon-datepicker-selected",async P=>{s.updateFormValue({key:"dateOfBirth",value:P.detail.date})}),g._$owner=A(),_.addEventListener("photon-phone-changed",async P=>{s.updateFormValue({key:"phone",value:P.detail.phone})}),_._$owner=A(),C.addEventListener("photon-gender-selected",P=>{s.updateFormValue({key:"gender",value:P.detail.gender})}),C.addEventListener("photon-gender-deselected",()=>{s.updateFormValue({key:"gender",value:void 0})}),C._$owner=A(),D.addEventListener("photon-sex-selected",P=>{s.updateFormValue({key:"sex",value:P.detail.sex})}),D.addEventListener("photon-sex-deselected",()=>{s.updateFormValue({key:"sex",value:void 0})}),D._$owner=A(),F.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"email",value:P.detail.input})}),F._$owner=A(),G.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"address_street1",value:P.detail.input})}),G._$owner=A(),j.optional=!0,j.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"address_street2",value:P.detail.input})}),j._$owner=A(),z.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"address_city",value:P.detail.input})}),z._$owner=A(),I.addEventListener("photon-state-selected",P=>{s.updateFormValue({key:"address_state",value:P.detail.state})}),I._$owner=A(),U.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"address_zip",value:P.detail.input})}),U._$owner=A(),be.addEventListener("photon-pharmacy-selected",P=>{s.updateFormValue({key:"preferredPharmacy",value:P.detail.pharmacy.id})}),be._$owner=A(),q(P=>{const B=a.firstName?.error,Ce=a.firstName?.error,te=a.lastName?.error,ye=a.lastName?.error,Ne=a.dateOfBirth?.error,ce=a.dateOfBirth?.error,re=a.phone?.error,ae=a.phone?.error,_e=a.gender?.error,it=a.gender?.error!==void 0,kt=r.selectedPatient.data?.gender,mt=a.sex?.error,Vt=a.sex?.error!==void 0,Qn=r.selectedPatient.data?.sex,ho=a.email?.error,po=a.email?.error,y1=a.address_street1?.error,b1=a.address_street1?.error,$1=a.address_street2?.error,w1=a.address_street2?.error,_1=a.address_city?.error,x1=a.address_city?.error,k1=a.address_state?.error,E1=a.address_state?.error!==void 0,S1=a.state?.value??r.selectedPatient.data?.address?.state,O1=a.address_zip?.error,C1=a.address_zip?.error,N1=PK(r,a),T1=e.patientId,P1=r.selectedPatient.data?.preferredPharmacies?.[0]?.id;return B!==P._v$&&(v.invalid=P._v$=B),Ce!==P._v$2&&(v.helpText=P._v$2=Ce),te!==P._v$3&&(b.invalid=P._v$3=te),ye!==P._v$4&&(b.helpText=P._v$4=ye),Ne!==P._v$5&&(g.invalid=P._v$5=Ne),ce!==P._v$6&&(g.helpText=P._v$6=ce),re!==P._v$7&&(_.invalid=P._v$7=re),ae!==P._v$8&&(_.helpText=P._v$8=ae),_e!==P._v$9&&(C.helpText=P._v$9=_e),it!==P._v$10&&(C.invalid=P._v$10=it),kt!==P._v$11&&(C.selected=P._v$11=kt),mt!==P._v$12&&(D.helpText=P._v$12=mt),Vt!==P._v$13&&(D.invalid=P._v$13=Vt),Qn!==P._v$14&&(D.selected=P._v$14=Qn),ho!==P._v$15&&(F.invalid=P._v$15=ho),po!==P._v$16&&(F.helpText=P._v$16=po),y1!==P._v$17&&(G.invalid=P._v$17=y1),b1!==P._v$18&&(G.helpText=P._v$18=b1),$1!==P._v$19&&(j.invalid=P._v$19=$1),w1!==P._v$20&&(j.helpText=P._v$20=w1),_1!==P._v$21&&(z.invalid=P._v$21=_1),x1!==P._v$22&&(z.helpText=P._v$22=x1),k1!==P._v$23&&(I.helpText=P._v$23=k1),E1!==P._v$24&&(I.invalid=P._v$24=E1),S1!==P._v$25&&(I.selected=P._v$25=S1),O1!==P._v$26&&(U.invalid=P._v$26=O1),C1!==P._v$27&&(U.helpText=P._v$27=C1),N1!==P._v$28&&(be.address=P._v$28=N1),T1!==P._v$29&&(be.patientId=P._v$29=T1),P1!==P._v$30&&(be.selected=P._v$30=P1),P},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0,_v$5:void 0,_v$6:void 0,_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0,_v$11:void 0,_v$12:void 0,_v$13:void 0,_v$14:void 0,_v$15:void 0,_v$16:void 0,_v$17:void 0,_v$18:void 0,_v$19:void 0,_v$20:void 0,_v$21:void 0,_v$22:void 0,_v$23:void 0,_v$24:void 0,_v$25:void 0,_v$26:void 0,_v$27:void 0,_v$28:void 0,_v$29:void 0,_v$30:void 0}),q(()=>v.value=a.firstName?.value??r.selectedPatient.data?.name.first),q(()=>b.value=a.lastName?.value??r.selectedPatient.data?.name.last),q(()=>g.value=e.patientId?r.selectedPatient.data?.dateOfBirth:a.dateOfBirth?.value),q(()=>_.value=a.phone?.value??r.selectedPatient.data?.phone),q(()=>F.value=a.email?.value??r.selectedPatient.data?.email),q(()=>G.value=a.address_street1?.value??r.selectedPatient.data?.address?.street1),q(()=>j.value=a.address_street2?.value??r.selectedPatient.data?.address?.street2),q(()=>z.value=a.address_city?.value??r.selectedPatient.data?.address?.city),q(()=>U.value=a.address_zip?.value??r.selectedPatient.data?.address?.postalCode),p}})}}),null),l})()});const AK=`.input::part(base){border-radius:var(--photon-border-radius, .5rem)}.invalid::part(base){--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity));border-width:2px}.invalid::part(form-control-help-text){--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}
|
|
3606
|
-
`,IK=T("<div><style></style><style></style></div>"),bd=[{id:"1",name:"AL"},{id:"2",name:"AK"},{id:"3",name:"AZ"},{id:"4",name:"AR"},{id:"5",name:"CA"},{id:"6",name:"CO"},{id:"7",name:"CT"},{id:"8",name:"DE"},{id:"9",name:"DC"},{id:"10",name:"FL"},{id:"11",name:"GA"},{id:"12",name:"HI"},{id:"13",name:"ID"},{id:"14",name:"IL"},{id:"15",name:"IN"},{id:"16",name:"IA"},{id:"17",name:"KS"},{id:"18",name:"KY"},{id:"19",name:"LA"},{id:"20",name:"ME"},{id:"21",name:"MD"},{id:"22",name:"MA"},{id:"23",name:"MI"},{id:"24",name:"MN"},{id:"25",name:"MS"},{id:"26",name:"MO"},{id:"27",name:"MT"},{id:"28",name:"NB"},{id:"29",name:"NV"},{id:"30",name:"NH"},{id:"31",name:"NJ"},{id:"32",name:"NM"},{id:"33",name:"NY"},{id:"34",name:"NC"},{id:"35",name:"ND"},{id:"36",name:"OH"},{id:"37",name:"OK"},{id:"38",name:"OR"},{id:"39",name:"PA"},{id:"40",name:"PR"},{id:"41",name:"RI"},{id:"42",name:"SC"},{id:"43",name:"SD"},{id:"44",name:"TN"},{id:"45",name:"TX"},{id:"46",name:"UT"},{id:"47",name:"VT"},{id:"48",name:"VA"},{id:"49",name:"WA"},{id:"50",name:"WV"},{id:"51",name:"WI"},{id:"52",name:"WY"}];Me("photon-state-input",{label:void 0,required:!1,value:void 0,invalid:!1,helpText:void 0,disabled:!1,selected:void 0},e=>{const[t,n]=V("");let r;const i=a=>{const s=new CustomEvent("photon-state-selected",{composed:!0,bubbles:!0,detail:{state:a}});r?.dispatchEvent(s)},o=a=>a.length===0?bd:bd.filter(s=>s.name.toLowerCase().includes(a.toLowerCase()));return(()=>{const a=IK.cloneNode(!0),s=a.firstChild,c=s.nextSibling,l=r;return typeof l=="function"?he(l,a):r=a,a.addEventListener("photon-data-selected",u=>{i(u.detail.data.name)}),k(s,Je),k(c,AK),k(a,S(wn,{get data(){return o(t())},get label(){return e.label},get required(){return e.required},placeholder:"",get disabled(){return e.disabled},get invalid(){return e.invalid},isLoading:!1,hasMore:!1,displayAccessor:u=>u?.name||"",showOverflow:!0,onSearchChange:async u=>{n(u)},onHide:async()=>{n("")},noDataMsg:"",optional:!1,get helpText(){return e.helpText},get selectedData(){return bd.filter(u=>u.name===e.selected)?.[0]}}),null),a})()});const MK=T("<sl-icon></sl-icon>"),DK=T('<div class="flex-1 flex justify-end"></div>'),LK=T('<div class="fixed top-0 left-0 w-full h-screen z-10 overflow-y-scroll"><style></style><photon-dialog confirm-text="Yes, Close" cancel-text="Keep Editing"><p class="font-sans text-lg xs:text-base"></p></photon-dialog><div class="flex items-center px-4 py-2 md:px-8 md:py-3 bg-white fixed w-full z-10 shadow-card"><div class="md:w-2/5 flex justify-start"><photon-button class="close-button" size="small" circle variant="naked"><div class="text-black text-3xl"><sl-icon name="x"></sl-icon></div></photon-button></div><div class="w-full md:w-3/5 flex flex-col md:flex-row"><div class="mb-2 md:mb-0 flex justify-center md:justify-center items-center"><p class="ml-1 font-sans text-xl font-medium"></p></div></div></div><div class="overflow-y-scroll w-full min-h-screen bg-[#f7f4f4] pt-28 xs:pt-28 lg:pt-20"><div class="px-4 pb-24 md:pt-4 md:pb-52 md:px-4 w-full h-full sm:w-[600px] xs:mx-auto"></div></div></div>'),r4=e=>{const t=Nt({closeTitle:"Lose unsaved changes?",closeBody:"You will not be able to recover unsaved changes.",checkShouldWarn:()=>!1},e);let n;const[r,i]=V(!1);return(()=>{const o=H(()=>document.importNode(LK,!0)),a=o.firstChild,s=a.nextSibling,c=s.firstChild,l=s.nextSibling,u=l.firstChild,d=u.firstChild,f=d.firstChild,h=f.firstChild,p=u.nextSibling,m=p.firstChild,v=m.firstChild,b=l.nextSibling,y=b.firstChild,g=n;return typeof g=="function"?he(g,o):n=o,k(a,Je),s.addEventListener("photon-dialog-confirmed",()=>{i(!1),t.onClosed()}),s.addEventListener("photon-dialog-canceled",()=>{i(!1)}),s._$owner=A(),k(c,()=>t.closeBody),d.addEventListener("click",()=>{t.checkShouldWarn()?i(!0):t.onClosed()}),d._$owner=A(),h.style.setProperty("display","block"),h._$owner=A(),k(m,S(ee,{get when(){return t.titleIconName},get children(){const _=H(()=>document.importNode(MK,!0));return _._$owner=A(),q(()=>_.name=t.titleIconName),_}}),v),k(v,()=>t.title),k(p,S(ee,{get when(){return t.headerRight},get children(){const _=DK.cloneNode(!0);return k(_,()=>t.headerRight),_}}),null),k(y,()=>t.form),q(_=>{const x=t.closeTitle,O=r();return x!==_._v$&&(s.label=_._v$=x),O!==_._v$2&&(s.open=_._v$2=O),_},{_v$:void 0,_v$2:void 0}),o})()},RK=T("<div></div>"),FK=T('<div class="flex flex-row gap-1 lg:gap-2 justify-end items-end"><photon-button size="sm" variant="outline">Save and Create Prescription</photon-button><photon-button size="sm">Save</photon-button></div>'),zK=T('<div class="bg-red-100 border border-red-400 text-red-700 px-4 py-3 rounded relative mb-4" role="alert"><span class="block sm:inline"></span></div>'),jK=T('<photon-patient-form slot="form"></photon-patient-form>');Me("photon-patient-dialog",{patientId:"",open:!1},e=>{let t;const n=pt(),[r,i]=V(!1),[o,a]=V(!1),[s,c]=V(void 0),[l,u]=V(void 0),[d,f]=V(void 0),[h,p]=V(void 0),m=(g,_=!1)=>{const x=new CustomEvent("photon-patient-updated",{composed:!0,bubbles:!0,detail:{patientId:g,createPrescription:_}});t?.dispatchEvent(x)},v=(g,_=!1)=>{const x=new CustomEvent("photon-patient-created",{composed:!0,bubbles:!0,detail:{patientId:g,createPrescription:_}});t?.dispatchEvent(x)},b=()=>{const g=new CustomEvent("photon-patient-closed",{composed:!0,bubbles:!0,detail:{}});t?.dispatchEvent(g)},y=async(g,_,x,O=!1)=>{p(void 0),a(O),i(!0);let C=["firstName","lastName","dateOfBirth","phone","sex","email"];if(g.address_street1?.value!==void 0||g.address_city?.value!==void 0||g.address_state?.value!==void 0||g.address_zip?.value!==void 0)_.registerValidator({key:"address_street1",validator:st(fr(Kt(),1,1/0),"Please enter a valid Street 1..")}),_.registerValidator({key:"address_city",validator:st(fr(Kt(),1,1/0),"Please enter a valid City..")}),_.registerValidator({key:"address_state",validator:st(fr(Kt(),2,2),"Please enter a valid State..")}),C=[...C,"address_zip","address_street1","address_city","address_state"];else{const D=["address_street1","address_city","address_state"];for(const F of D)_.unRegisterValidator(F)}if(_.validate(C),_.hasErrors(C))return i(!1),!0;g.preferredPharmacy.value&&x.selectedPatient.data?.preferredPharmacies&&x.selectedPatient.data?.preferredPharmacies.length!==0&&!x.selectedPatient.data?.preferredPharmacies?.map(D=>D?.id).filter(D=>D!==null).includes(g.preferredPharmacy.value)&&await n.getSDK().clinical.patient.removePatientPreferredPharmacy({})({variables:{patientId:e.patientId,pharmacyId:x.selectedPatient.data?.preferredPharmacies[0].id},awaitRefetchQueries:!1});const M={...e?.patientId?{id:e.patientId}:{},name:{first:g.firstName.value,last:g.lastName.value},gender:g.gender.value,email:g.email.value,phone:g.phone.value,dateOfBirth:g.dateOfBirth.value,sex:g.sex.value,address:g.address_street1.value!==void 0?{street1:g.address_street1.value,street2:g.address_street2.value,city:g.address_city.value,state:g.address_state.value,postalCode:g.address_zip.value,country:"US"}:void 0,preferredPharmacies:g.preferredPharmacy.value?[g.preferredPharmacy.value]:[]};try{if(e?.patientId)await n.getSDK().clinical.patient.updatePatient({})({variables:M,awaitRefetchQueries:!1}),m(e.patientId,O);else{const F=await n.getSDK().clinical.patient.createPatient({})({variables:M,awaitRefetchQueries:!1});v(F?.data?.createPatient?.id||"",O)}i(!1),_.resetStores(),e.open=!1}catch(D){i(!1),p(D?.message||"An error occurred while saving the patient.")}};return(()=>{const g=RK.cloneNode(!0),_=t;return typeof _=="function"?he(_,g):t=g,k(g,S(ee,{get when(){return e.open},get children(){return S(r4,{onClosed:()=>{b(),d().resetStores(),e.open=!1},get title(){return e?.patientId?"Update Patient":"Create Patient"},get titleIconName(){return e?.patientId?"pencil-square":"person-plus"},get headerRight(){return(()=>{const x=H(()=>document.importNode(FK,!0)),O=x.firstChild,C=O.nextSibling;return O.$$click=()=>y(s(),d(),l(),!0),O._$owner=A(),C.$$click=()=>y(s(),d(),l(),!1),C._$owner=A(),q(M=>{const D=r(),F=r()&&o(),Y=r(),J=r()&&!o();return D!==M._v$&&(O.disabled=M._v$=D),F!==M._v$2&&(O.loading=M._v$2=F),Y!==M._v$3&&(C.disabled=M._v$3=Y),J!==M._v$4&&(C.loading=M._v$4=J),M},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0}),x})()},get form(){return[S(ee,{get when(){return h()},get children(){const x=zK.cloneNode(!0),O=x.firstChild;return k(O,h),x}}),(()=>{const x=H(()=>document.importNode(jK,!0));return x.addEventListener("photon-form-updated",O=>{c(O.detail.form),f(Object.assign({},O.detail.actions,{resetStores:O.detail.reset})),u(O.detail.selected)}),x._$owner=A(),q(()=>x.patientId=e.patientId),x})()]}})}})),g})()});Yi(["click"]);const VK=T("<photon-patient-dialog></photon-patient-dialog>");Me("photon-update-patient-dialog",{patientId:"",open:!1},e=>(console.warn("photon-update-patient-dialog will be deprecated soon. Please use photon-patient-dialog instead."),(()=>{const t=H(()=>document.importNode(VK,!0));return t._$owner=A(),q(n=>{const r=e.patientId,i=e.open;return r!==n._v$&&(t.patientId=n._v$=r),i!==n._v$2&&(t.open=n._v$2=i),n},{_v$:void 0,_v$2:void 0}),t})()));const UK=T('<div class="w-full"></div>'),BK=T('<p class="text-sm whitespace-normal leading-snug mb-2"></p>'),HK=()=>{let e;const t=pt(),[n,r]=V(!1),[i,o]=V(""),[a,s]=V(),[c,l]=V([]),u=d=>{const f=new CustomEvent("photon-name-selected",{composed:!0,bubbles:!0,detail:{medicationId:d}});e?.dispatchEvent(f)};return me(async()=>{i().length>0&&(r(!0),H(async()=>{const d=String(Math.random());s(d);const{data:f}=await t.getSDK().clinical.searchMedication.getConcepts({name:i()});d===a()&&l(f.medicationConcepts??[]),r(!1)}))}),(()=>{const d=UK.cloneNode(!0),f=e;return typeof f=="function"?he(f,d):e=d,d.addEventListener("photon-data-selected",h=>{u(h.detail.data.id)}),k(d,S(wn,{get data(){return c()},label:"Medication Name",placeholder:"Enter a medication name...",get isLoading(){return n()},hasMore:!1,displayAccessor:(h,p)=>p?(()=>{const m=BK.cloneNode(!0);return k(m,()=>h?.name||""),m})():h?.name||"",onSearchChange:async h=>o(h),onHide:async()=>{o("")},noDataMsg:"No medications found",required:!1})),d})()},qK=T('<div class="w-full"></div>'),WK=e=>{const t=pt(),[n,r]=V(),[i,o]=V(!1),[a,s]=V([]),c=f=>{const h=new CustomEvent("photon-strength-selected",{composed:!0,bubbles:!0,detail:{strengthId:f}});d?.dispatchEvent(h)},l=()=>{const f=new CustomEvent("photon-strength-deselected",{composed:!0,bubbles:!0,detail:{}});d?.dispatchEvent(f)};me(async()=>{u.clear(),e.medicationId.length>0&&(o(!0),H(async()=>{const f=String(Math.random());r(f);const{data:h}=await t.getSDK().clinical.searchMedication.getStrengths({id:e.medicationId});f===n()&&s(h.medicationStrengths??[]),o(!1)}))});const u={};let d;return(()=>{const f=qK.cloneNode(!0),h=d;return typeof h=="function"?he(h,f):d=f,f.addEventListener("photon-data-selected",p=>{c(p.detail.data.id)}),f.addEventListener("photon-data-unselected",()=>{l()}),k(f,S(wn,{actionRef:u,get data(){return a()},label:"Strength",get disabled(){return e.disabled},placeholder:"Select a strength...",get isLoading(){return i()},hasMore:!1,displayAccessor:p=>p?.name||"",noDataMsg:"No strengths found",required:!1})),f})()},GK=T('<div class="w-full"></div>'),KK=e=>{const t=pt(),[n,r]=V(),[i,o]=V(!1),[a,s]=V([]),c=f=>{const h=new CustomEvent("photon-route-selected",{composed:!0,bubbles:!0,detail:{routeId:f}});d?.dispatchEvent(h)},l=()=>{const f=new CustomEvent("photon-route-deselected",{composed:!0,bubbles:!0,detail:{}});d?.dispatchEvent(f)};me(async()=>{u.clear(),e.medicationId.length>0&&(o(!0),H(async()=>{const f=String(Math.random());r(f);const{data:h}=await t.getSDK().clinical.searchMedication.getRoutes({id:e.medicationId});f===n()&&s(h.medicationRoutes??[]),o(!1)}))});const u={};let d;return(()=>{const f=GK.cloneNode(!0),h=d;return typeof h=="function"?he(h,f):d=f,f.addEventListener("photon-data-selected",p=>{c(p.detail.data.id)}),f.addEventListener("photon-data-unselected",()=>{l()}),k(f,S(wn,{actionRef:u,get data(){return a()},label:"Route",get disabled(){return e.disabled},placeholder:"Select a route...",get isLoading(){return i()},hasMore:!1,displayAccessor:p=>p?.name||"",noDataMsg:"No routes found",required:!1})),f})()},QK=T('<div class="w-full"></div>'),YK=e=>{const t=pt(),[n,r]=V(!1),[i,o]=V(),[a,s]=V([]),c=f=>{const h=new CustomEvent("photon-form-selected",{composed:!0,bubbles:!0,detail:{formId:f}});d?.dispatchEvent(h)},l=()=>{const f=new CustomEvent("photon-form-deselected",{composed:!0,bubbles:!0,detail:{}});d?.dispatchEvent(f)};me(async()=>{u.clear(),e.medicationId.length>0&&(r(!0),H(async()=>{const f=String(Math.random());o(f);const{data:h}=await t.getSDK().clinical.searchMedication.getForms({id:e.medicationId});f===i()&&s(h.medicationForms??[]),r(!1)}))});const u={};let d;return(()=>{const f=QK.cloneNode(!0),h=d;return typeof h=="function"?he(h,f):d=f,f.addEventListener("photon-data-selected",p=>{c(p.detail.data.id)}),f.addEventListener("photon-data-unselected",()=>{l()}),k(f,S(wn,{actionRef:u,get data(){return a()},label:"Form",get disabled(){return e.disabled},placeholder:"Select a form...",get isLoading(){return n()},hasMore:!1,displayAccessor:p=>p.form,noDataMsg:"No forms found",required:!1})),f})()},XK=T('<photon-checkbox label="Add Medication to Catalog"></photon-checkbox>'),ZK=T('<div><p class="font-sans text-lg text-gray-700 pb-2">Advanced Medication Search</p><div class="flex flex-col xs:flex-row gap-4"></div><div class="flex flex-col xs:flex-row gap-4"></div><div class="flex flex-col xs:flex-row gap-4"></div><div class="flex flex-col xs:flex-row gap-4"></div><hr class="my-8"><p class="font-sans text-gray-700 pb-4">Select a medication:</p><div><photon-radio-group></photon-radio-group></div></div>'),JK=T("<photon-radio-card></photon-radio-card>");ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-med-search",{},()=>{let e;const t=pt(),[n,r]=V(""),[i,o]=V(""),[a,s]=V(""),[c,l]=V(""),[u,d]=V([]),[f,h]=V(!1),[p,m]=V(void 0),[v,b]=V(""),y=(g,_)=>{const x=new CustomEvent("photon-form-updated",{composed:!0,bubbles:!0,detail:{medication:g,addToCatalog:_,catalogId:v()}});e?.dispatchEvent(x)};return ht(async()=>{const{data:g}=await t.getSDK().clinical.catalog.getCatalogs();g.catalogs.length>0&&b(g.catalogs[0].id)}),me(()=>{const g=c()||a()||i()||n();g.length>0&&H(async()=>{const{data:_}=await t.getSDK().clinical.searchMedication.getProducts({id:g});h(!1),m(void 0),d(_.medicationProducts)})}),me(()=>{p()&&y(p(),f())}),(()=>{const g=H(()=>document.importNode(ZK,!0)),_=g.firstChild,x=_.nextSibling,O=x.nextSibling,C=O.nextSibling,M=C.nextSibling,D=M.nextSibling,F=D.nextSibling,Y=F.nextSibling,J=Y.firstChild,G=e;return typeof G=="function"?he(G,g):e=g,g.addEventListener("photon-name-selected",j=>{r(j.detail.medicationId)}),g.addEventListener("photon-strength-selected",j=>{o(j.detail.strengthId)}),g.addEventListener("photon-strength-deselected",()=>{o("")}),g.addEventListener("photon-route-selected",j=>{s(j.detail.routeId)}),g.addEventListener("photon-route-deselected",()=>{s("")}),g.addEventListener("photon-form-selected",j=>{l(j.detail.formId)}),g.addEventListener("photon-form-deselected",()=>{l("")}),k(x,S(HK,{})),k(O,S(WK,{get medicationId(){return n()},get disabled(){return n().length==0}})),k(C,S(KK,{get medicationId(){return i()},get disabled(){return i().length==0}})),k(M,S(YK,{get medicationId(){return a()},get disabled(){return a().length==0}})),Y.addEventListener("photon-option-selected",j=>{m(j.detail.value)}),J._$owner=A(),k(J,S(sr,{get each(){return u().filter((j,z,Q)=>{const I=Q.findIndex(U=>U.name===j.name);if(z===I)return!0}).sort((j,z)=>j.name.toLowerCase()>z.name.toLowerCase()?-1:1)},children:j=>(()=>{const z=H(()=>document.importNode(JK,!0));return z.value=j,z._$owner=A(),k(z,()=>j.name),z})()})),k(g,S(ee,{get when(){return v().length>0},get children(){const j=H(()=>document.importNode(XK,!0));return j.addEventListener("photon-checkbox-toggled",z=>h(z.detail.checked)),j._$owner=A(),q(()=>j.disabled=!p()),q(()=>j.checked=f()),j}}),null),g})()});var eQ=_t`
|
|
3599
|
+
`.concat(JSON.stringify(f,null,2)))}}return c?{partialMatch:!0}:void 0;case"[]":for(var h=Gv(t.args),p;!(p=h()).done;){var m=p.value;if(e[0]===m)return e.length===1?{match:!0,matchedChars:e}:n?{overflow:!0}:{match:!0,matchedChars:[m]}}return;default:throw new Error("Unsupported instruction tree: ".concat(t))}}function Yv(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=BG(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3600
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function BG(e,t){if(!!e){if(typeof e=="string")return Xv(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Xv(e,t)}}function Xv(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function HG(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Zv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function qG(e,t,n){return t&&Zv(e.prototype,t),n&&Zv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var rh="9",WG=15,GG=rl(rh,WG),KG=/[- ]/,QG=function(){return/\[([^\[\]])*\]/g},YG=function(){return/\d(?=[^,}][^,}])/g},XG=new RegExp("["+vn+"]*\\$1["+vn+"]*(\\$\\d["+vn+"]*)*$"),Jv=3,ZG=function(){function e(t){t.state;var n=t.metadata;HG(this,e),this.metadata=n,this.resetFormat()}return qG(e,[{key:"resetFormat",value:function(){this.chosenFormat=void 0,this.template=void 0,this.nationalNumberTemplate=void 0,this.populatedNationalNumberTemplate=void 0,this.populatedNationalNumberTemplatePosition=-1}},{key:"reset",value:function(n,r){this.resetFormat(),n?(this.isNANP=n.callingCode()==="1",this.matchingFormats=n.formats(),r.nationalSignificantNumber&&this.narrowDownMatchingFormats(r)):(this.isNANP=void 0,this.matchingFormats=[])}},{key:"format",value:function(n,r){var i=this;if(TG(r.nationalSignificantNumber,this.metadata))for(var o=Yv(this.matchingFormats),a;!(a=o()).done;){var s=a.value,c=NG(r,s,{metadata:this.metadata,shouldTryNationalPrefixFormattingRule:function(u){return i.shouldTryNationalPrefixFormattingRule(u,{international:r.international,nationalPrefix:r.nationalPrefix})},getSeparatorAfterNationalPrefix:function(u){return i.getSeparatorAfterNationalPrefix(u)}});if(c)return this.resetFormat(),this.chosenFormat=s,this.setNationalNumberTemplate(c.replace(/\d/g,cn),r),this.populatedNationalNumberTemplate=c,this.populatedNationalNumberTemplatePosition=this.template.lastIndexOf(cn),c}return this.formatNationalNumberWithNextDigits(n,r)}},{key:"formatNationalNumberWithNextDigits",value:function(n,r){var i=this.chosenFormat,o=this.chooseFormat(r);if(o)return o===i?this.formatNextNationalNumberDigits(n):this.formatNextNationalNumberDigits(r.getNationalDigits())}},{key:"narrowDownMatchingFormats",value:function(n){var r=this,i=n.nationalSignificantNumber,o=n.nationalPrefix,a=n.international,s=i,c=s.length-Jv;c<0&&(c=0),this.matchingFormats=this.matchingFormats.filter(function(l){return r.formatSuits(l,a,o)&&r.formatMatches(l,s,c)}),this.chosenFormat&&this.matchingFormats.indexOf(this.chosenFormat)===-1&&this.resetFormat()}},{key:"formatSuits",value:function(n,r,i){return!(i&&!n.usesNationalPrefix()&&!n.nationalPrefixIsOptionalWhenFormattingInNationalFormat()||!r&&!i&&n.nationalPrefixIsMandatoryWhenFormattingInNationalFormat())}},{key:"formatMatches",value:function(n,r,i){var o=n.leadingDigitsPatterns().length;if(o===0)return!0;i=Math.min(i,o-1);var a=n.leadingDigitsPatterns()[i];if(r.length<Jv)try{return new UG(a).match(r,{allowOverflow:!0})!==void 0}catch(s){return console.error(s),!0}return new RegExp("^(".concat(a,")")).test(r)}},{key:"getFormatFormat",value:function(n,r){return r?n.internationalFormat():n.format()}},{key:"chooseFormat",value:function(n){for(var r=this,i=function(){var l=a.value;return r.chosenFormat===l?"break":XG.test(r.getFormatFormat(l,n.international))?r.createTemplateForFormat(l,n)?(r.chosenFormat=l,"break"):(r.matchingFormats=r.matchingFormats.filter(function(u){return u!==l}),"continue"):"continue"},o=Yv(this.matchingFormats.slice()),a;!(a=o()).done;){var s=i();if(s==="break")break}return this.chosenFormat||this.resetFormat(),this.chosenFormat}},{key:"createTemplateForFormat",value:function(n,r){if(!(n.pattern().indexOf("|")>=0)){var i=this.getTemplateForFormat(n,r);if(i)return this.setNationalNumberTemplate(i,r),!0}}},{key:"getSeparatorAfterNationalPrefix",value:function(n){return this.isNANP||n&&n.nationalPrefixFormattingRule()&&KG.test(n.nationalPrefixFormattingRule())?" ":""}},{key:"getInternationalPrefixBeforeCountryCallingCode",value:function(n,r){var i=n.IDDPrefix,o=n.missingPlus;return i?r&&r.spacing===!1?i:i+" ":o?"":"+"}},{key:"getTemplate",value:function(n){if(!!this.template){for(var r=-1,i=0,o=n.international?this.getInternationalPrefixBeforeCountryCallingCode(n,{spacing:!1}):"";i<o.length+n.getDigitsWithoutInternationalPrefix().length;)r=this.template.indexOf(cn,r+1),i++;return Hv(this.template,r+1)}}},{key:"setNationalNumberTemplate",value:function(n,r){this.nationalNumberTemplate=n,this.populatedNationalNumberTemplate=n,this.populatedNationalNumberTemplatePosition=-1,r.international?this.template=this.getInternationalPrefixBeforeCountryCallingCode(r).replace(/[\d\+]/g,cn)+rl(cn,r.callingCode.length)+" "+n:this.template=n}},{key:"getTemplateForFormat",value:function(n,r){var i=r.nationalSignificantNumber,o=r.international,a=r.nationalPrefix,s=r.complexPrefixBeforeNationalSignificantNumber,c=n.pattern();c=c.replace(QG(),"\\d").replace(YG(),"\\d");var l=GG.match(c)[0];if(!(i.length>l.length)){var u=new RegExp("^"+c+"$"),d=i.replace(/\d/g,rh);u.test(d)&&(l=d);var f=this.getFormatFormat(n,o),h;if(this.shouldTryNationalPrefixFormattingRule(n,{international:o,nationalPrefix:a})){var p=f.replace(Kb,n.nationalPrefixFormattingRule());if($c(n.nationalPrefixFormattingRule())===(a||"")+$c("$1")&&(f=p,h=!0,a))for(var m=a.length;m>0;)f=f.replace(/\d/,cn),m--}var v=l.replace(new RegExp(c),f).replace(new RegExp(rh,"g"),cn);return h||(s?v=rl(cn,s.length)+" "+v:a&&(v=rl(cn,a.length)+this.getSeparatorAfterNationalPrefix(n)+v)),o&&(v=Gb(v)),v}}},{key:"formatNextNationalNumberDigits",value:function(n){var r=CG(this.populatedNationalNumberTemplate,this.populatedNationalNumberTemplatePosition,n);if(!r){this.resetFormat();return}return this.populatedNationalNumberTemplate=r[0],this.populatedNationalNumberTemplatePosition=r[1],Hv(this.populatedNationalNumberTemplate,this.populatedNationalNumberTemplatePosition+1)}},{key:"shouldTryNationalPrefixFormattingRule",value:function(n,r){var i=r.international,o=r.nationalPrefix;if(n.nationalPrefixFormattingRule()){var a=n.usesNationalPrefix();if(a&&o||!a&&!i)return!0}}}]),e}();function t4(e,t){return nK(e)||tK(e,t)||eK(e,t)||JG()}function JG(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
3601
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function eK(e,t){if(!!e){if(typeof e=="string")return eg(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return eg(e,t)}}function eg(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function tK(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],i=!0,o=!1,a,s;try{for(n=n.call(e);!(i=(a=n.next()).done)&&(r.push(a.value),!(t&&r.length===t));i=!0);}catch(c){o=!0,s=c}finally{try{!i&&n.return!=null&&n.return()}finally{if(o)throw s}}return r}}function nK(e){if(Array.isArray(e))return e}function rK(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function tg(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function iK(e,t,n){return t&&tg(e.prototype,t),n&&tg(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var oK="["+vn+an+"]+",aK=new RegExp("^"+oK+"$","i"),sK="(?:["+eu+"]["+vn+an+"]*|["+vn+an+"]+)",lK=new RegExp("[^"+vn+an+"]+.*$"),cK=/[^\d\[\]]/,uK=function(){function e(t){var n=t.defaultCountry,r=t.defaultCallingCode,i=t.metadata,o=t.onNationalSignificantNumberChange;rK(this,e),this.defaultCountry=n,this.defaultCallingCode=r,this.metadata=i,this.onNationalSignificantNumberChange=o}return iK(e,[{key:"input",value:function(n,r){var i=hK(n),o=t4(i,2),a=o[0],s=o[1],c=$c(a),l;return s&&(r.digits||(r.startInternationalNumber(),c||(l=!0))),c&&this.inputDigits(c,r),{digits:c,justLeadingPlus:l}}},{key:"inputDigits",value:function(n,r){var i=r.digits,o=i.length<3&&i.length+n.length>=3;if(r.appendDigits(n),o&&this.extractIddPrefix(r),this.isWaitingForCountryCallingCode(r)){if(!this.extractCountryCallingCode(r))return}else r.appendNationalSignificantNumberDigits(n);r.international||this.hasExtractedNationalSignificantNumber||this.extractNationalSignificantNumber(r.getNationalDigits(),function(a){return r.update(a)})}},{key:"isWaitingForCountryCallingCode",value:function(n){var r=n.international,i=n.callingCode;return r&&!i}},{key:"extractCountryCallingCode",value:function(n){var r=Jb("+"+n.getDigitsWithoutInternationalPrefix(),this.defaultCountry,this.defaultCallingCode,this.metadata.metadata),i=r.countryCallingCode,o=r.number;if(i)return n.setCallingCode(i),n.update({nationalSignificantNumber:o}),!0}},{key:"reset",value:function(n){if(n){this.hasSelectedNumberingPlan=!0;var r=n._nationalPrefixForParsing();this.couldPossiblyExtractAnotherNationalSignificantNumber=r&&cK.test(r)}else this.hasSelectedNumberingPlan=void 0,this.couldPossiblyExtractAnotherNationalSignificantNumber=void 0}},{key:"extractNationalSignificantNumber",value:function(n,r){if(!!this.hasSelectedNumberingPlan){var i=Jf(n,this.metadata),o=i.nationalPrefix,a=i.nationalNumber,s=i.carrierCode;if(a!==n)return this.onExtractedNationalNumber(o,s,a,n,r),!0}}},{key:"extractAnotherNationalSignificantNumber",value:function(n,r,i){if(!this.hasExtractedNationalSignificantNumber)return this.extractNationalSignificantNumber(n,i);if(!!this.couldPossiblyExtractAnotherNationalSignificantNumber){var o=Jf(n,this.metadata),a=o.nationalPrefix,s=o.nationalNumber,c=o.carrierCode;if(s!==r)return this.onExtractedNationalNumber(a,c,s,n,i),!0}}},{key:"onExtractedNationalNumber",value:function(n,r,i,o,a){var s,c,l=o.lastIndexOf(i);if(l>=0&&l===o.length-i.length){c=!0;var u=o.slice(0,l);u!==n&&(s=u)}a({nationalPrefix:n,carrierCode:r,nationalSignificantNumber:i,nationalSignificantNumberMatchesInput:c,complexPrefixBeforeNationalSignificantNumber:s}),this.hasExtractedNationalSignificantNumber=!0,this.onNationalSignificantNumberChange()}},{key:"reExtractNationalSignificantNumber",value:function(n){if(this.extractAnotherNationalSignificantNumber(n.getNationalDigits(),n.nationalSignificantNumber,function(r){return n.update(r)}))return!0;if(this.extractIddPrefix(n))return this.extractCallingCodeAndNationalSignificantNumber(n),!0;if(this.fixMissingPlus(n))return this.extractCallingCodeAndNationalSignificantNumber(n),!0}},{key:"extractIddPrefix",value:function(n){var r=n.international,i=n.IDDPrefix,o=n.digits;if(n.nationalSignificantNumber,!(r||i)){var a=Xb(o,this.defaultCountry,this.defaultCallingCode,this.metadata.metadata);if(a!==void 0&&a!==o)return n.update({IDDPrefix:o.slice(0,o.length-a.length)}),this.startInternationalNumber(n,{country:void 0,callingCode:void 0}),!0}}},{key:"fixMissingPlus",value:function(n){if(!n.international){var r=Zb(n.digits,this.defaultCountry,this.defaultCallingCode,this.metadata.metadata),i=r.countryCallingCode;if(r.number,i)return n.update({missingPlus:!0}),this.startInternationalNumber(n,{country:n.country,callingCode:i}),!0}}},{key:"startInternationalNumber",value:function(n,r){var i=r.country,o=r.callingCode;n.startInternationalNumber(i,o),n.nationalSignificantNumber&&(n.resetNationalSignificantNumber(),this.onNationalSignificantNumberChange(),this.hasExtractedNationalSignificantNumber=void 0)}},{key:"extractCallingCodeAndNationalSignificantNumber",value:function(n){this.extractCountryCallingCode(n)&&this.extractNationalSignificantNumber(n.getNationalDigits(),function(r){return n.update(r)})}}]),e}();function dK(e){var t=e.search(sK);if(!(t<0)){e=e.slice(t);var n;return e[0]==="+"&&(n=!0,e=e.slice(1)),e=e.replace(lK,""),n&&(e="+"+e),e}}function fK(e){var t=dK(e)||"";return t[0]==="+"?[t.slice(1),!0]:[t]}function hK(e){var t=fK(e),n=t4(t,2),r=n[0],i=n[1];return aK.test(r)||(r=""),[r,i]}function ih(e){return ih=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ih(e)}function pK(e,t){return yK(e)||gK(e,t)||vK(e,t)||mK()}function mK(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
3602
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vK(e,t){if(!!e){if(typeof e=="string")return ng(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ng(e,t)}}function ng(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function gK(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],i=!0,o=!1,a,s;try{for(n=n.call(e);!(i=(a=n.next()).done)&&(r.push(a.value),!(t&&r.length===t));i=!0);}catch(c){o=!0,s=c}finally{try{!i&&n.return!=null&&n.return()}finally{if(o)throw s}}return r}}function yK(e){if(Array.isArray(e))return e}function bK(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function rg(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function $K(e,t,n){return t&&rg(e.prototype,t),n&&rg(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var n4=function(){function e(t,n){bK(this,e),this.metadata=new Mt(n);var r=this.getCountryAndCallingCode(t),i=pK(r,2),o=i[0],a=i[1];this.defaultCountry=o,this.defaultCallingCode=a,this.reset()}return $K(e,[{key:"getCountryAndCallingCode",value:function(n){var r,i;return n&&(ih(n)==="object"?(r=n.defaultCountry,i=n.defaultCallingCode):r=n),r&&!this.metadata.hasCountry(r)&&(r=void 0),[r,i]}},{key:"input",value:function(n){var r=this.parser.input(n,this.state),i=r.digits,o=r.justLeadingPlus;if(o)this.formattedOutput="+";else if(i){this.determineTheCountryIfNeeded(),this.state.nationalSignificantNumber&&this.formatter.narrowDownMatchingFormats(this.state);var a;if(this.metadata.hasSelectedNumberingPlan()&&(a=this.formatter.format(i,this.state)),a===void 0&&this.parser.reExtractNationalSignificantNumber(this.state)){this.determineTheCountryIfNeeded();var s=this.state.getNationalDigits();s&&(a=this.formatter.format(s,this.state))}this.formattedOutput=a?this.getFullNumber(a):this.getNonFormattedNumber()}return this.formattedOutput}},{key:"reset",value:function(){var n=this;return this.state=new kG({onCountryChange:function(i){n.country=i},onCallingCodeChange:function(i,o){n.metadata.selectNumberingPlan(o,i),n.formatter.reset(n.metadata.numberingPlan,n.state),n.parser.reset(n.metadata.numberingPlan)}}),this.formatter=new ZG({state:this.state,metadata:this.metadata}),this.parser=new uK({defaultCountry:this.defaultCountry,defaultCallingCode:this.defaultCallingCode,metadata:this.metadata,state:this.state,onNationalSignificantNumberChange:function(){n.determineTheCountryIfNeeded(),n.formatter.reset(n.metadata.numberingPlan,n.state)}}),this.state.reset({country:this.defaultCountry,callingCode:this.defaultCallingCode}),this.formattedOutput="",this}},{key:"isInternational",value:function(){return this.state.international}},{key:"getCallingCode",value:function(){if(this.isInternational())return this.state.callingCode}},{key:"getCountryCallingCode",value:function(){return this.getCallingCode()}},{key:"getCountry",value:function(){var n=this.state.digits;if(n)return this._getCountry()}},{key:"_getCountry",value:function(){var n=this.state.country;return n}},{key:"determineTheCountryIfNeeded",value:function(){(!this.state.country||this.isCountryCallingCodeAmbiguous())&&this.determineTheCountry()}},{key:"getFullNumber",value:function(n){var r=this;if(this.isInternational()){var i=function(s){return r.formatter.getInternationalPrefixBeforeCountryCallingCode(r.state,{spacing:!!s})+s},o=this.state.callingCode;return i(o?n?"".concat(o," ").concat(n):o:"".concat(this.state.getDigitsWithoutInternationalPrefix()))}return n}},{key:"getNonFormattedNationalNumberWithPrefix",value:function(){var n=this.state,r=n.nationalSignificantNumber,i=n.complexPrefixBeforeNationalSignificantNumber,o=n.nationalPrefix,a=r,s=i||o;return s&&(a=s+a),a}},{key:"getNonFormattedNumber",value:function(){var n=this.state.nationalSignificantNumberMatchesInput;return this.getFullNumber(n?this.getNonFormattedNationalNumberWithPrefix():this.state.getNationalDigits())}},{key:"getNonFormattedTemplate",value:function(){var n=this.getNonFormattedNumber();if(n)return n.replace(/[\+\d]/g,cn)}},{key:"isCountryCallingCodeAmbiguous",value:function(){var n=this.state.callingCode,r=this.metadata.getCountryCodesForCallingCode(n);return r&&r.length>1}},{key:"determineTheCountry",value:function(){this.state.setCountry(e4(this.isInternational()?this.state.callingCode:this.defaultCallingCode,this.state.nationalSignificantNumber,this.metadata))}},{key:"getNumberValue",value:function(){var n=this.state,r=n.digits,i=n.callingCode,o=n.country,a=n.nationalSignificantNumber;if(!!r){if(this.isInternational())return i?"+"+i+a:"+"+r;if(o||i){var s=o?this.metadata.countryCallingCode():i;return"+"+s+a}}}},{key:"getNumber",value:function(){var n=this.state,r=n.nationalSignificantNumber,i=n.carrierCode,o=n.callingCode,a=this._getCountry();if(!!r&&!(!a&&!o)){var s=new Yb(a||o,r,this.metadata.metadata);return i&&(s.carrierCode=i),s}}},{key:"isPossible",value:function(){var n=this.getNumber();return n?n.isPossible():!1}},{key:"isValid",value:function(){var n=this.getNumber();return n?n.isValid():!1}},{key:"getNationalNumber",value:function(){return this.state.nationalSignificantNumber}},{key:"getChars",value:function(){return(this.state.international?"+":"")+this.state.digits}},{key:"getTemplate",value:function(){return this.formatter.getTemplate(this.state)||this.getNonFormattedTemplate()||""}}]),e}();function gd(){return Lq(wG,arguments)}function _c(e){return n4.call(this,e,Rb)}_c.prototype=Object.create(n4.prototype,{});_c.prototype.constructor=_c;const wK=`.input::part(base){border-radius:var(--photon-border-radius, .5rem)}.invalid::part(base){--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity));border-width:2px}.invalid::part(form-control-help-text){--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}
|
|
3603
|
+
`,rs=N("<style></style>"),_K=N('<div class="md:py-2 flex flex-col font-sans"><sl-input class="input" type="tel" placeholder="( ) ___-____"><p slot="help-text" class="text-red-500 pt-1 h-[21px] font-sans"></p></sl-input></div>'),xK=N('<div class="flex items-center pb-2"><p class="text-gray-700 text-sm"></p></div>'),kK=N('<p class="pl-1 text-red-500">*</p>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-phone-input",{label:void 0,required:!1,value:void 0,invalid:!1,helpText:void 0,disabled:!1},e=>{let t;const n=i=>{const o=new CustomEvent("photon-phone-changed",{composed:!0,bubbles:!0,detail:{phone:i}});t?.dispatchEvent(o)};ht(()=>{e.value&&n(gd(e.value,"US").format("E.164"))});const r=se(()=>e.value?e.value.length>2?new _c("US").input(gd(e.value,"US").formatNational()):e.value:"");return[(()=>{const i=rs.cloneNode(!0);return x(i,Je),i})(),(()=>{const i=rs.cloneNode(!0);return x(i,Xt),i})(),(()=>{const i=rs.cloneNode(!0);return x(i,Yt),i})(),(()=>{const i=rs.cloneNode(!0);return x(i,wK),i})(),(()=>{const i=H(()=>document.importNode(_K,!0)),o=i.firstChild,a=o.firstChild,s=t;return typeof s=="function"?he(s,i):t=i,x(i,(()=>{const c=se(()=>!!e.label);return()=>c()?(()=>{const l=xK.cloneNode(!0),u=l.firstChild;return x(u,()=>e.label),x(l,(()=>{const d=se(()=>!!e.required);return()=>d()?kK.cloneNode(!0):null})(),null),l})():null})(),o),o.addEventListener("sl-input",c=>{try{const l=gd(c.target.value,"US").format("E.164");n(l)}catch{n(c.target?.value||"")}}),o._$owner=A(),x(a,()=>e.helpText),q(c=>{const l=!!e.invalid,u=e.disabled,d=e.invalid;return l!==c._v$&&o.classList.toggle("invalid",c._v$=l),u!==c._v$2&&(o.disabled=c._v$2=u),d!==c._v$3&&(o.invalid=c._v$3=d),c},{_v$:void 0,_v$2:void 0,_v$3:void 0}),q(()=>o.value=r()),i})()]});const EK=`.input::part(base){border-radius:var(--photon-border-radius, .5rem)}.invalid::part(base){--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity));border-width:2px}.invalid::part(form-control-help-text){--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}
|
|
3604
|
+
`,SK=N("<div><style></style><style></style></div>"),oh=[{id:"1",name:"MALE"},{id:"2",name:"FEMALE"},{id:"3",name:"UNKNOWN"}];Me("photon-sex-input",{label:void 0,required:!1,value:void 0,invalid:!1,helpText:void 0,disabled:!1,selected:void 0},e=>{let t;const n=r=>{const i=new CustomEvent("photon-sex-selected",{composed:!0,bubbles:!0,detail:{sex:r}});t?.dispatchEvent(i)};return(()=>{const r=SK.cloneNode(!0),i=r.firstChild,o=i.nextSibling,a=t;return typeof a=="function"?he(a,r):t=r,r.addEventListener("photon-data-selected",s=>{n(s.detail.data.name)}),x(i,Je),x(o,EK),x(r,S(wn,{data:oh,get label(){return e.label},get required(){return e.required},placeholder:"",get disabled(){return e.disabled},get invalid(){return e.invalid},isLoading:!1,hasMore:!1,displayAccessor:s=>s?.name||"",showOverflow:!0,noDataMsg:"",optional:!1,get helpText(){return e.helpText},get selectedData(){return oh.filter(s=>s.name.toUpperCase()===e.selected)?.[0]}}),null),r})()});const OK=`.input::part(base){border-radius:var(--photon-border-radius, .5rem)}.invalid::part(base){--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity));border-width:2px}.invalid::part(form-control-help-text){--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}
|
|
3605
|
+
`,CK=N("<div><style></style><style></style></div>"),yd=[{id:"1",name:"Male/Man"},{id:"2",name:"Female/Woman"},{id:"3",name:"TransMale/TransMan"},{id:"4",name:"TransFemale/TransWoman"},{id:"5",name:"Genderqueery/Gender nonconforming"},{id:"6",name:"Something else"},{id:"7",name:"Decline to answer"}];Me("photon-gender-input",{label:void 0,required:!1,value:void 0,invalid:!1,helpText:void 0,disabled:!1,selected:void 0},e=>{const[t,n]=V("");let r;const i=s=>s.length===0?yd:yd.filter(c=>c.name.toLowerCase().includes(s.toLowerCase())),o=s=>{const c=new CustomEvent("photon-gender-selected",{composed:!0,bubbles:!0,detail:{gender:s}});r?.dispatchEvent(c)},a=()=>{const s=new CustomEvent("photon-gender-deselected",{composed:!0,bubbles:!0,detail:{}});r?.dispatchEvent(s)};return(()=>{const s=CK.cloneNode(!0),c=s.firstChild,l=c.nextSibling,u=r;return typeof u=="function"?he(u,s):r=s,s.addEventListener("photon-data-selected",d=>{o(d.detail.data.name)}),s.addEventListener("photon-data-unselected",()=>{a()}),x(c,Je),x(l,OK),x(s,S(wn,{get data(){return i(t())},get label(){return e.label},get required(){return e.required},placeholder:"",get disabled(){return e.disabled},get invalid(){return e.invalid},isLoading:!1,hasMore:!1,displayAccessor:d=>d?.name||"",showOverflow:!0,onSearchChange:async d=>{n(d)},onHide:async()=>{n("")},noDataMsg:"",get optional(){return!e.required},get helpText(){return e.helpText},get selectedData(){return yd.filter(d=>d.name===e.selected)?.[0]}}),null),s})()});const NK=N('<div class="flex align-center justify-center h-screen"><sl-spinner class="mt-8"></sl-spinner></div>'),TK=N('<photon-card title="Personal"><div class="flex flex-col xs:flex-row xs:gap-4"><photon-text-input class="flex-grow min-w-[40%]" debounce-time="0" label="First Name"></photon-text-input><photon-text-input class="min-w-[48%]" debounce-time="0" label="Last Name"></photon-text-input></div><div class="flex flex-col xs:flex-row items-center xs:gap-4"><photon-datepicker no-initial-date="true" class="flex-grow w-full xs:min-w-[40%]" label="Date of Birth"></photon-datepicker><photon-phone-input class="w-full xs:min-w-[48%]" label="Phone Number"></photon-phone-input></div><div class="flex flex-col xs:flex-row justify-between xs:gap-4"><div class="flex-grow w-full xs:min-w-[40%]"><photon-gender-input label="Gender" required="false"></photon-gender-input></div><div class="flex-grow w-full xs:min-w-[40%]"><photon-sex-input label="Sex at Birth" required="false"></photon-sex-input></div></div><photon-text-input debounce-time="0" label="Email"></photon-text-input><hr class="py-2"><p class="font-sans text-lg flex-grow">Address</p><photon-text-input debounce-time="0" label="Street 1"></photon-text-input><photon-text-input debounce-time="0" label="Street 2"></photon-text-input><photon-text-input debounce-time="0" label="City"></photon-text-input><div class="flex gap-4 pb-5 xs:pb-2"><photon-state-input class="flex-grow min-w-[40%]" label="State" required="false"></photon-state-input><photon-text-input debounce-time="0" class="flex-grow min-w-[40%]" label="Zip Code"></photon-text-input></div><hr class="py-2"><p class="font-sans text-lg flex-grow">Preferred Local Pharmacy</p><photon-pharmacy-search></photon-pharmacy-search></photon-card>'),PK=N('<div class="w-full h-full relative"><style></style><style></style><style></style></div>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");const AK=(e,t)=>{const n=e.selectedPatient.data?.address;return t.address_zip?.value&&j4(t.address_zip?.value)&&t.address_zip?.value!=n?.postalCode?t.address_zip?.value:n?`${n.street1} ${n.street2??""} ${n.city}, ${n.state} ${n.postalCode}`:""};Me("photon-patient-form",{patientId:""},e=>{let t;const n=pt(),{store:r,actions:i}=Gc,{actions:o}=Lb,{store:a,actions:s}=Q3({firstName:void 0,lastName:void 0,dateOfBirth:void 0,phone:void 0,gender:void 0,sex:void 0,email:void 0,address_street1:void 0,address_street2:void 0,address_city:void 0,address_state:void 0,address_zip:void 0,preferredPharmacy:void 0});s.registerValidator({key:"firstName",validator:st(fr(Kt(),1,1/0),"Please enter a first name.")}),s.registerValidator({key:"lastName",validator:st(fr(Kt(),1,1/0),"Please enter a last name.")}),s.registerValidator({key:"dateOfBirth",validator:st(nd([LT,sd()]),"Please enter a valid date of birth.")}),s.registerValidator({key:"sex",validator:st(Yk(oh.map(l=>l.name)),"Please enter Sex at Birth.")}),s.registerValidator({key:"phone",validator:st(fr(Kt(),12),"Please enter a valid phone number.")}),s.registerValidator({key:"email",validator:st(nd([zT(),sd()]),"Please enter a valid email.")}),s.registerValidator({key:"address_zip",validator:st(nd([FT(),sd()]),"Please enter a valid zip code...")}),ht(()=>{e.patientId?i.getSelectedPatient(n.getSDK(),e.patientId):i.clearSelectedPatient()});const c=l=>{const u=new CustomEvent("photon-form-updated",{composed:!0,bubbles:!0,detail:{form:l,actions:s,selected:r,reset:()=>{s.reset(),i.reset(),o.reset()}}});t?.dispatchEvent(u)};return me(()=>{r.selectedPatient.data&&(s.updateFormValue({key:"firstName",value:r.selectedPatient.data.name.first}),s.updateFormValue({key:"lastName",value:r.selectedPatient.data.name.last}),s.updateFormValue({key:"phone",value:r.selectedPatient.data.phone}),s.updateFormValue({key:"gender",value:r.selectedPatient.data.gender}),s.updateFormValue({key:"sex",value:r.selectedPatient.data.sex}),s.updateFormValue({key:"email",value:r.selectedPatient.data.email}),s.updateFormValue({key:"address_street1",value:r.selectedPatient.data.address?.street1}),s.updateFormValue({key:"address_street2",value:r.selectedPatient.data.address?.street2}),s.updateFormValue({key:"address_city",value:r.selectedPatient.data.address?.city}),s.updateFormValue({key:"address_state",value:r.selectedPatient.data.address?.state}),s.updateFormValue({key:"address_zip",value:r.selectedPatient.data.address?.postalCode}),s.updateFormValue({key:"preferredPharmacy",value:r.selectedPatient.data.preferredPharmacies?.[0]?.id}))}),me(()=>{c(a)}),Gi(()=>{i.clearSelectedPatient(),s.reset()}),(()=>{const l=PK.cloneNode(!0),u=l.firstChild,d=u.nextSibling,f=d.nextSibling,h=t;return typeof h=="function"?he(h,l):t=l,x(u,Je),x(d,Xt),x(f,Yt),x(l,S(ee,{get when(){return r.selectedPatient.isLoading},get children(){const p=H(()=>document.importNode(NK,!0)),m=p.firstChild;return m.style.setProperty("font-size","3rem"),m._$owner=A(),p}}),null),x(l,S(ee,{get when(){return!r.selectedPatient.isLoading},get children(){return S(Db,{permissions:["write:patient"],get children(){const p=H(()=>document.importNode(TK,!0)),m=p.firstChild,v=m.firstChild,b=v.nextSibling,y=m.nextSibling,g=y.firstChild,_=g.nextSibling,k=y.nextSibling,O=k.firstChild,C=O.firstChild,M=O.nextSibling,D=M.firstChild,F=k.nextSibling,Y=F.nextSibling,J=Y.nextSibling,G=J.nextSibling,j=G.nextSibling,z=j.nextSibling,Q=z.nextSibling,I=Q.firstChild,U=I.nextSibling,W=Q.nextSibling,de=W.nextSibling,be=de.nextSibling;return p._$owner=A(),v.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"firstName",value:P.detail.input})}),v._$owner=A(),b.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"lastName",value:P.detail.input})}),b._$owner=A(),g.addEventListener("photon-datepicker-selected",async P=>{s.updateFormValue({key:"dateOfBirth",value:P.detail.date})}),g._$owner=A(),_.addEventListener("photon-phone-changed",async P=>{s.updateFormValue({key:"phone",value:P.detail.phone})}),_._$owner=A(),C.addEventListener("photon-gender-selected",P=>{s.updateFormValue({key:"gender",value:P.detail.gender})}),C.addEventListener("photon-gender-deselected",()=>{s.updateFormValue({key:"gender",value:void 0})}),C._$owner=A(),D.addEventListener("photon-sex-selected",P=>{s.updateFormValue({key:"sex",value:P.detail.sex})}),D.addEventListener("photon-sex-deselected",()=>{s.updateFormValue({key:"sex",value:void 0})}),D._$owner=A(),F.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"email",value:P.detail.input})}),F._$owner=A(),G.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"address_street1",value:P.detail.input})}),G._$owner=A(),j.optional=!0,j.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"address_street2",value:P.detail.input})}),j._$owner=A(),z.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"address_city",value:P.detail.input})}),z._$owner=A(),I.addEventListener("photon-state-selected",P=>{s.updateFormValue({key:"address_state",value:P.detail.state})}),I._$owner=A(),U.addEventListener("photon-input-changed",async P=>{s.updateFormValue({key:"address_zip",value:P.detail.input})}),U._$owner=A(),be.addEventListener("photon-pharmacy-selected",P=>{s.updateFormValue({key:"preferredPharmacy",value:P.detail.pharmacy.id})}),be._$owner=A(),q(P=>{const B=a.firstName?.error,Ce=a.firstName?.error,te=a.lastName?.error,ye=a.lastName?.error,Ne=a.dateOfBirth?.error,ce=a.dateOfBirth?.error,re=a.phone?.error,ae=a.phone?.error,_e=a.gender?.error,it=a.gender?.error!==void 0,kt=r.selectedPatient.data?.gender,mt=a.sex?.error,Vt=a.sex?.error!==void 0,Qn=r.selectedPatient.data?.sex,ho=a.email?.error,po=a.email?.error,y1=a.address_street1?.error,b1=a.address_street1?.error,$1=a.address_street2?.error,w1=a.address_street2?.error,_1=a.address_city?.error,x1=a.address_city?.error,k1=a.address_state?.error,E1=a.address_state?.error!==void 0,S1=a.state?.value??r.selectedPatient.data?.address?.state,O1=a.address_zip?.error,C1=a.address_zip?.error,N1=AK(r,a),T1=e.patientId,P1=r.selectedPatient.data?.preferredPharmacies?.[0]?.id;return B!==P._v$&&(v.invalid=P._v$=B),Ce!==P._v$2&&(v.helpText=P._v$2=Ce),te!==P._v$3&&(b.invalid=P._v$3=te),ye!==P._v$4&&(b.helpText=P._v$4=ye),Ne!==P._v$5&&(g.invalid=P._v$5=Ne),ce!==P._v$6&&(g.helpText=P._v$6=ce),re!==P._v$7&&(_.invalid=P._v$7=re),ae!==P._v$8&&(_.helpText=P._v$8=ae),_e!==P._v$9&&(C.helpText=P._v$9=_e),it!==P._v$10&&(C.invalid=P._v$10=it),kt!==P._v$11&&(C.selected=P._v$11=kt),mt!==P._v$12&&(D.helpText=P._v$12=mt),Vt!==P._v$13&&(D.invalid=P._v$13=Vt),Qn!==P._v$14&&(D.selected=P._v$14=Qn),ho!==P._v$15&&(F.invalid=P._v$15=ho),po!==P._v$16&&(F.helpText=P._v$16=po),y1!==P._v$17&&(G.invalid=P._v$17=y1),b1!==P._v$18&&(G.helpText=P._v$18=b1),$1!==P._v$19&&(j.invalid=P._v$19=$1),w1!==P._v$20&&(j.helpText=P._v$20=w1),_1!==P._v$21&&(z.invalid=P._v$21=_1),x1!==P._v$22&&(z.helpText=P._v$22=x1),k1!==P._v$23&&(I.helpText=P._v$23=k1),E1!==P._v$24&&(I.invalid=P._v$24=E1),S1!==P._v$25&&(I.selected=P._v$25=S1),O1!==P._v$26&&(U.invalid=P._v$26=O1),C1!==P._v$27&&(U.helpText=P._v$27=C1),N1!==P._v$28&&(be.address=P._v$28=N1),T1!==P._v$29&&(be.patientId=P._v$29=T1),P1!==P._v$30&&(be.selected=P._v$30=P1),P},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0,_v$5:void 0,_v$6:void 0,_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0,_v$11:void 0,_v$12:void 0,_v$13:void 0,_v$14:void 0,_v$15:void 0,_v$16:void 0,_v$17:void 0,_v$18:void 0,_v$19:void 0,_v$20:void 0,_v$21:void 0,_v$22:void 0,_v$23:void 0,_v$24:void 0,_v$25:void 0,_v$26:void 0,_v$27:void 0,_v$28:void 0,_v$29:void 0,_v$30:void 0}),q(()=>v.value=a.firstName?.value??r.selectedPatient.data?.name.first),q(()=>b.value=a.lastName?.value??r.selectedPatient.data?.name.last),q(()=>g.value=e.patientId?r.selectedPatient.data?.dateOfBirth:a.dateOfBirth?.value),q(()=>_.value=a.phone?.value??r.selectedPatient.data?.phone),q(()=>F.value=a.email?.value??r.selectedPatient.data?.email),q(()=>G.value=a.address_street1?.value??r.selectedPatient.data?.address?.street1),q(()=>j.value=a.address_street2?.value??r.selectedPatient.data?.address?.street2),q(()=>z.value=a.address_city?.value??r.selectedPatient.data?.address?.city),q(()=>U.value=a.address_zip?.value??r.selectedPatient.data?.address?.postalCode),p}})}}),null),l})()});const IK=`.input::part(base){border-radius:var(--photon-border-radius, .5rem)}.invalid::part(base){--tw-border-opacity: 1;border-color:rgb(239 68 68/var(--tw-border-opacity));border-width:2px}.invalid::part(form-control-help-text){--tw-text-opacity: 1;color:rgb(239 68 68/var(--tw-text-opacity))}
|
|
3606
|
+
`,MK=N("<div><style></style><style></style></div>"),bd=[{id:"1",name:"AL"},{id:"2",name:"AK"},{id:"3",name:"AZ"},{id:"4",name:"AR"},{id:"5",name:"CA"},{id:"6",name:"CO"},{id:"7",name:"CT"},{id:"8",name:"DE"},{id:"9",name:"DC"},{id:"10",name:"FL"},{id:"11",name:"GA"},{id:"12",name:"HI"},{id:"13",name:"ID"},{id:"14",name:"IL"},{id:"15",name:"IN"},{id:"16",name:"IA"},{id:"17",name:"KS"},{id:"18",name:"KY"},{id:"19",name:"LA"},{id:"20",name:"ME"},{id:"21",name:"MD"},{id:"22",name:"MA"},{id:"23",name:"MI"},{id:"24",name:"MN"},{id:"25",name:"MS"},{id:"26",name:"MO"},{id:"27",name:"MT"},{id:"28",name:"NB"},{id:"29",name:"NV"},{id:"30",name:"NH"},{id:"31",name:"NJ"},{id:"32",name:"NM"},{id:"33",name:"NY"},{id:"34",name:"NC"},{id:"35",name:"ND"},{id:"36",name:"OH"},{id:"37",name:"OK"},{id:"38",name:"OR"},{id:"39",name:"PA"},{id:"40",name:"PR"},{id:"41",name:"RI"},{id:"42",name:"SC"},{id:"43",name:"SD"},{id:"44",name:"TN"},{id:"45",name:"TX"},{id:"46",name:"UT"},{id:"47",name:"VT"},{id:"48",name:"VA"},{id:"49",name:"WA"},{id:"50",name:"WV"},{id:"51",name:"WI"},{id:"52",name:"WY"}];Me("photon-state-input",{label:void 0,required:!1,value:void 0,invalid:!1,helpText:void 0,disabled:!1,selected:void 0},e=>{const[t,n]=V("");let r;const i=a=>{const s=new CustomEvent("photon-state-selected",{composed:!0,bubbles:!0,detail:{state:a}});r?.dispatchEvent(s)},o=a=>a.length===0?bd:bd.filter(s=>s.name.toLowerCase().includes(a.toLowerCase()));return(()=>{const a=MK.cloneNode(!0),s=a.firstChild,c=s.nextSibling,l=r;return typeof l=="function"?he(l,a):r=a,a.addEventListener("photon-data-selected",u=>{i(u.detail.data.name)}),x(s,Je),x(c,IK),x(a,S(wn,{get data(){return o(t())},get label(){return e.label},get required(){return e.required},placeholder:"",get disabled(){return e.disabled},get invalid(){return e.invalid},isLoading:!1,hasMore:!1,displayAccessor:u=>u?.name||"",showOverflow:!0,onSearchChange:async u=>{n(u)},onHide:async()=>{n("")},noDataMsg:"",optional:!1,get helpText(){return e.helpText},get selectedData(){return bd.filter(u=>u.name===e.selected)?.[0]}}),null),a})()});const DK=N("<sl-icon></sl-icon>"),LK=N('<div class="flex-1 flex justify-end"></div>'),RK=N('<div class="fixed top-0 left-0 w-full h-screen z-10 overflow-y-scroll"><style></style><photon-dialog confirm-text="Yes, Close" cancel-text="Keep Editing"><p class="font-sans text-lg xs:text-base"></p></photon-dialog><div class="flex items-center px-4 py-2 md:px-8 md:py-3 bg-white fixed w-full z-10 shadow-card"><div class="md:w-2/5 flex justify-start"><photon-button class="close-button" size="small" circle variant="naked"><div class="text-black text-3xl"><sl-icon name="x"></sl-icon></div></photon-button></div><div class="w-full md:w-3/5 flex flex-col md:flex-row"><div class="mb-2 md:mb-0 flex justify-center md:justify-center items-center"><p class="ml-1 font-sans text-xl font-medium"></p></div></div></div><div class="overflow-y-scroll w-full min-h-screen bg-[#f7f4f4] pt-28 xs:pt-28 lg:pt-20"><div class="px-4 pb-24 md:pt-4 md:pb-52 md:px-4 w-full h-full sm:w-[600px] xs:mx-auto"></div></div></div>'),r4=e=>{const t=Nt({closeTitle:"Lose unsaved changes?",closeBody:"You will not be able to recover unsaved changes.",checkShouldWarn:()=>!1},e);let n;const[r,i]=V(!1);return(()=>{const o=H(()=>document.importNode(RK,!0)),a=o.firstChild,s=a.nextSibling,c=s.firstChild,l=s.nextSibling,u=l.firstChild,d=u.firstChild,f=d.firstChild,h=f.firstChild,p=u.nextSibling,m=p.firstChild,v=m.firstChild,b=l.nextSibling,y=b.firstChild,g=n;return typeof g=="function"?he(g,o):n=o,x(a,Je),s.addEventListener("photon-dialog-confirmed",()=>{i(!1),t.onClosed()}),s.addEventListener("photon-dialog-canceled",()=>{i(!1)}),s._$owner=A(),x(c,()=>t.closeBody),d.addEventListener("click",()=>{t.checkShouldWarn()?i(!0):t.onClosed()}),d._$owner=A(),h.style.setProperty("display","block"),h._$owner=A(),x(m,S(ee,{get when(){return t.titleIconName},get children(){const _=H(()=>document.importNode(DK,!0));return _._$owner=A(),q(()=>_.name=t.titleIconName),_}}),v),x(v,()=>t.title),x(p,S(ee,{get when(){return t.headerRight},get children(){const _=LK.cloneNode(!0);return x(_,()=>t.headerRight),_}}),null),x(y,()=>t.form),q(_=>{const k=t.closeTitle,O=r();return k!==_._v$&&(s.label=_._v$=k),O!==_._v$2&&(s.open=_._v$2=O),_},{_v$:void 0,_v$2:void 0}),o})()},FK=N("<div></div>"),zK=N('<div class="flex flex-row gap-1 lg:gap-2 justify-end items-end"><photon-button size="sm" variant="outline">Save and Create Prescription</photon-button><photon-button size="sm">Save</photon-button></div>'),jK=N('<div class="bg-red-100 border border-red-400 text-red-700 px-4 py-3 rounded relative mb-4" role="alert"><span class="block sm:inline"></span></div>'),VK=N('<photon-patient-form slot="form"></photon-patient-form>');Me("photon-patient-dialog",{patientId:"",open:!1},e=>{let t;const n=pt(),[r,i]=V(!1),[o,a]=V(!1),[s,c]=V(void 0),[l,u]=V(void 0),[d,f]=V(void 0),[h,p]=V(void 0),m=(g,_=!1)=>{const k=new CustomEvent("photon-patient-updated",{composed:!0,bubbles:!0,detail:{patientId:g,createPrescription:_}});t?.dispatchEvent(k)},v=(g,_=!1)=>{const k=new CustomEvent("photon-patient-created",{composed:!0,bubbles:!0,detail:{patientId:g,createPrescription:_}});t?.dispatchEvent(k)},b=()=>{const g=new CustomEvent("photon-patient-closed",{composed:!0,bubbles:!0,detail:{}});t?.dispatchEvent(g)},y=async(g,_,k,O=!1)=>{p(void 0),a(O),i(!0);let C=["firstName","lastName","dateOfBirth","phone","sex","email"];if(g.address_street1?.value!==void 0||g.address_city?.value!==void 0||g.address_state?.value!==void 0||g.address_zip?.value!==void 0)_.registerValidator({key:"address_street1",validator:st(fr(Kt(),1,1/0),"Please enter a valid Street 1..")}),_.registerValidator({key:"address_city",validator:st(fr(Kt(),1,1/0),"Please enter a valid City..")}),_.registerValidator({key:"address_state",validator:st(fr(Kt(),2,2),"Please enter a valid State..")}),C=[...C,"address_zip","address_street1","address_city","address_state"];else{const D=["address_street1","address_city","address_state"];for(const F of D)_.unRegisterValidator(F)}if(_.validate(C),_.hasErrors(C))return i(!1),!0;g.preferredPharmacy.value&&k.selectedPatient.data?.preferredPharmacies&&k.selectedPatient.data?.preferredPharmacies.length!==0&&!k.selectedPatient.data?.preferredPharmacies?.map(D=>D?.id).filter(D=>D!==null).includes(g.preferredPharmacy.value)&&await n.getSDK().clinical.patient.removePatientPreferredPharmacy({})({variables:{patientId:e.patientId,pharmacyId:k.selectedPatient.data?.preferredPharmacies[0].id},awaitRefetchQueries:!1});const M={...e?.patientId?{id:e.patientId}:{},name:{first:g.firstName.value,last:g.lastName.value},gender:g.gender.value,email:g.email.value,phone:g.phone.value,dateOfBirth:g.dateOfBirth.value,sex:g.sex.value,address:g.address_street1.value!==void 0?{street1:g.address_street1.value,street2:g.address_street2.value,city:g.address_city.value,state:g.address_state.value,postalCode:g.address_zip.value,country:"US"}:void 0,preferredPharmacies:g.preferredPharmacy.value?[g.preferredPharmacy.value]:[]};try{if(e?.patientId)await n.getSDK().clinical.patient.updatePatient({})({variables:M,awaitRefetchQueries:!1}),m(e.patientId,O);else{const F=await n.getSDK().clinical.patient.createPatient({})({variables:M,awaitRefetchQueries:!1});v(F?.data?.createPatient?.id||"",O)}i(!1),_.resetStores(),e.open=!1}catch(D){i(!1),p(D?.message||"An error occurred while saving the patient.")}};return(()=>{const g=FK.cloneNode(!0),_=t;return typeof _=="function"?he(_,g):t=g,x(g,S(ee,{get when(){return e.open},get children(){return S(r4,{onClosed:()=>{b(),d().resetStores(),e.open=!1},get title(){return e?.patientId?"Update Patient":"Create Patient"},get titleIconName(){return e?.patientId?"pencil-square":"person-plus"},get headerRight(){return(()=>{const k=H(()=>document.importNode(zK,!0)),O=k.firstChild,C=O.nextSibling;return O.$$click=()=>y(s(),d(),l(),!0),O._$owner=A(),C.$$click=()=>y(s(),d(),l(),!1),C._$owner=A(),q(M=>{const D=r(),F=r()&&o(),Y=r(),J=r()&&!o();return D!==M._v$&&(O.disabled=M._v$=D),F!==M._v$2&&(O.loading=M._v$2=F),Y!==M._v$3&&(C.disabled=M._v$3=Y),J!==M._v$4&&(C.loading=M._v$4=J),M},{_v$:void 0,_v$2:void 0,_v$3:void 0,_v$4:void 0}),k})()},get form(){return[S(ee,{get when(){return h()},get children(){const k=jK.cloneNode(!0),O=k.firstChild;return x(O,h),k}}),(()=>{const k=H(()=>document.importNode(VK,!0));return k.addEventListener("photon-form-updated",O=>{c(O.detail.form),f(Object.assign({},O.detail.actions,{resetStores:O.detail.reset})),u(O.detail.selected)}),k._$owner=A(),q(()=>k.patientId=e.patientId),k})()]}})}})),g})()});Yi(["click"]);const UK=N("<photon-patient-dialog></photon-patient-dialog>");Me("photon-update-patient-dialog",{patientId:"",open:!1},e=>(console.warn("photon-update-patient-dialog will be deprecated soon. Please use photon-patient-dialog instead."),(()=>{const t=H(()=>document.importNode(UK,!0));return t._$owner=A(),q(n=>{const r=e.patientId,i=e.open;return r!==n._v$&&(t.patientId=n._v$=r),i!==n._v$2&&(t.open=n._v$2=i),n},{_v$:void 0,_v$2:void 0}),t})()));const BK=N('<div class="w-full"></div>'),HK=N('<p class="text-sm whitespace-normal leading-snug mb-2"></p>'),qK=()=>{let e;const t=pt(),[n,r]=V(!1),[i,o]=V(""),[a,s]=V(),[c,l]=V([]),u=d=>{const f=new CustomEvent("photon-name-selected",{composed:!0,bubbles:!0,detail:{medicationId:d}});e?.dispatchEvent(f)};return me(async()=>{i().length>0&&(r(!0),H(async()=>{const d=String(Math.random());s(d);const{data:f}=await t.getSDK().clinical.searchMedication.getConcepts({name:i()});d===a()&&l(f.medicationConcepts??[]),r(!1)}))}),(()=>{const d=BK.cloneNode(!0),f=e;return typeof f=="function"?he(f,d):e=d,d.addEventListener("photon-data-selected",h=>{u(h.detail.data.id)}),x(d,S(wn,{get data(){return c()},label:"Medication Name",placeholder:"Enter a medication name...",get isLoading(){return n()},hasMore:!1,displayAccessor:(h,p)=>p?(()=>{const m=HK.cloneNode(!0);return x(m,()=>h?.name||""),m})():h?.name||"",onSearchChange:async h=>o(h),onHide:async()=>{o("")},noDataMsg:"No medications found",required:!1})),d})()},WK=N('<div class="w-full"></div>'),GK=e=>{const t=pt(),[n,r]=V(),[i,o]=V(!1),[a,s]=V([]),c=f=>{const h=new CustomEvent("photon-strength-selected",{composed:!0,bubbles:!0,detail:{strengthId:f}});d?.dispatchEvent(h)},l=()=>{const f=new CustomEvent("photon-strength-deselected",{composed:!0,bubbles:!0,detail:{}});d?.dispatchEvent(f)};me(async()=>{u.clear(),e.medicationId.length>0&&(o(!0),H(async()=>{const f=String(Math.random());r(f);const{data:h}=await t.getSDK().clinical.searchMedication.getStrengths({id:e.medicationId});f===n()&&s(h.medicationStrengths??[]),o(!1)}))});const u={};let d;return(()=>{const f=WK.cloneNode(!0),h=d;return typeof h=="function"?he(h,f):d=f,f.addEventListener("photon-data-selected",p=>{c(p.detail.data.id)}),f.addEventListener("photon-data-unselected",()=>{l()}),x(f,S(wn,{actionRef:u,get data(){return a()},label:"Strength",get disabled(){return e.disabled},placeholder:"Select a strength...",get isLoading(){return i()},hasMore:!1,displayAccessor:p=>p?.name||"",noDataMsg:"No strengths found",required:!1})),f})()},KK=N('<div class="w-full"></div>'),QK=e=>{const t=pt(),[n,r]=V(),[i,o]=V(!1),[a,s]=V([]),c=f=>{const h=new CustomEvent("photon-route-selected",{composed:!0,bubbles:!0,detail:{routeId:f}});d?.dispatchEvent(h)},l=()=>{const f=new CustomEvent("photon-route-deselected",{composed:!0,bubbles:!0,detail:{}});d?.dispatchEvent(f)};me(async()=>{u.clear(),e.medicationId.length>0&&(o(!0),H(async()=>{const f=String(Math.random());r(f);const{data:h}=await t.getSDK().clinical.searchMedication.getRoutes({id:e.medicationId});f===n()&&s(h.medicationRoutes??[]),o(!1)}))});const u={};let d;return(()=>{const f=KK.cloneNode(!0),h=d;return typeof h=="function"?he(h,f):d=f,f.addEventListener("photon-data-selected",p=>{c(p.detail.data.id)}),f.addEventListener("photon-data-unselected",()=>{l()}),x(f,S(wn,{actionRef:u,get data(){return a()},label:"Route",get disabled(){return e.disabled},placeholder:"Select a route...",get isLoading(){return i()},hasMore:!1,displayAccessor:p=>p?.name||"",noDataMsg:"No routes found",required:!1})),f})()},YK=N('<div class="w-full"></div>'),XK=e=>{const t=pt(),[n,r]=V(!1),[i,o]=V(),[a,s]=V([]),c=f=>{const h=new CustomEvent("photon-form-selected",{composed:!0,bubbles:!0,detail:{formId:f}});d?.dispatchEvent(h)},l=()=>{const f=new CustomEvent("photon-form-deselected",{composed:!0,bubbles:!0,detail:{}});d?.dispatchEvent(f)};me(async()=>{u.clear(),e.medicationId.length>0&&(r(!0),H(async()=>{const f=String(Math.random());o(f);const{data:h}=await t.getSDK().clinical.searchMedication.getForms({id:e.medicationId});f===i()&&s(h.medicationForms??[]),r(!1)}))});const u={};let d;return(()=>{const f=YK.cloneNode(!0),h=d;return typeof h=="function"?he(h,f):d=f,f.addEventListener("photon-data-selected",p=>{c(p.detail.data.id)}),f.addEventListener("photon-data-unselected",()=>{l()}),x(f,S(wn,{actionRef:u,get data(){return a()},label:"Form",get disabled(){return e.disabled},placeholder:"Select a form...",get isLoading(){return n()},hasMore:!1,displayAccessor:p=>p.form,noDataMsg:"No forms found",required:!1})),f})()},ZK=N('<photon-checkbox label="Add Medication to Catalog"></photon-checkbox>'),JK=N('<div><p class="font-sans text-lg text-gray-700 pb-2">Advanced Medication Search</p><div class="flex flex-col xs:flex-row gap-4"></div><div class="flex flex-col xs:flex-row gap-4"></div><div class="flex flex-col xs:flex-row gap-4"></div><div class="flex flex-col xs:flex-row gap-4"></div><hr class="my-8"><p class="font-sans text-gray-700 pb-4">Select a medication:</p><div><photon-radio-group></photon-radio-group></div></div>'),eQ=N("<photon-radio-card></photon-radio-card>");ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-med-search",{},()=>{let e;const t=pt(),[n,r]=V(""),[i,o]=V(""),[a,s]=V(""),[c,l]=V(""),[u,d]=V([]),[f,h]=V(!1),[p,m]=V(void 0),[v,b]=V(""),y=(g,_)=>{const k=new CustomEvent("photon-form-updated",{composed:!0,bubbles:!0,detail:{medication:g,addToCatalog:_,catalogId:v()}});e?.dispatchEvent(k)};return ht(async()=>{const{data:g}=await t.getSDK().clinical.catalog.getCatalogs();g.catalogs.length>0&&b(g.catalogs[0].id)}),me(()=>{const g=c()||a()||i()||n();g.length>0&&H(async()=>{const{data:_}=await t.getSDK().clinical.searchMedication.getProducts({id:g});h(!1),m(void 0),d(_.medicationProducts)})}),me(()=>{p()&&y(p(),f())}),(()=>{const g=H(()=>document.importNode(JK,!0)),_=g.firstChild,k=_.nextSibling,O=k.nextSibling,C=O.nextSibling,M=C.nextSibling,D=M.nextSibling,F=D.nextSibling,Y=F.nextSibling,J=Y.firstChild,G=e;return typeof G=="function"?he(G,g):e=g,g.addEventListener("photon-name-selected",j=>{r(j.detail.medicationId)}),g.addEventListener("photon-strength-selected",j=>{o(j.detail.strengthId)}),g.addEventListener("photon-strength-deselected",()=>{o("")}),g.addEventListener("photon-route-selected",j=>{s(j.detail.routeId)}),g.addEventListener("photon-route-deselected",()=>{s("")}),g.addEventListener("photon-form-selected",j=>{l(j.detail.formId)}),g.addEventListener("photon-form-deselected",()=>{l("")}),x(k,S(qK,{})),x(O,S(GK,{get medicationId(){return n()},get disabled(){return n().length==0}})),x(C,S(QK,{get medicationId(){return i()},get disabled(){return i().length==0}})),x(M,S(XK,{get medicationId(){return a()},get disabled(){return a().length==0}})),Y.addEventListener("photon-option-selected",j=>{m(j.detail.value)}),J._$owner=A(),x(J,S(sr,{get each(){return u().filter((j,z,Q)=>{const I=Q.findIndex(U=>U.name===j.name);if(z===I)return!0}).sort((j,z)=>j.name.toLowerCase()>z.name.toLowerCase()?-1:1)},children:j=>(()=>{const z=H(()=>document.importNode(eQ,!0));return z.value=j,z._$owner=A(),x(z,()=>j.name),z})()})),x(g,S(ee,{get when(){return v().length>0},get children(){const j=H(()=>document.importNode(ZK,!0));return j.addEventListener("photon-checkbox-toggled",z=>h(z.detail.checked)),j._$owner=A(),q(()=>j.disabled=!p()),q(()=>j.checked=f()),j}}),null),g})()});var tQ=_t`
|
|
3607
3607
|
${At}
|
|
3608
3608
|
|
|
3609
3609
|
:host {
|
|
@@ -3724,4 +3724,4 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
3724
3724
|
|
|
3725
3725
|
<slot part="label" class="radio__label"></slot>
|
|
3726
3726
|
</span>
|
|
3727
|
-
`}};In.styles=
|
|
3727
|
+
`}};In.styles=tQ;w([Dn()],In.prototype,"checked",2);w([Dn()],In.prototype,"hasFocus",2);w([E()],In.prototype,"value",2);w([E({reflect:!0})],In.prototype,"size",2);w([E({type:Boolean,reflect:!0})],In.prototype,"disabled",2);w([Ve("checked")],In.prototype,"handleCheckedChange",1);w([Ve("disabled",{waitUntilFirstUpdate:!0})],In.prototype,"handleDisabledChange",1);In=w([It("sl-radio")],In);const nQ=N('<div><style></style><photon-card><div class="flex items-center gap-2"><p class="font-sans flex-grow text-gray-600 text-sm"><slot></slot></p><input type="radio"></div></photon-card></div>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-radio-card",{selected:!1,value:""},e=>{let t;const n=()=>{const r=new CustomEvent("photon-radio-selected",{composed:!0,bubbles:!0,detail:{value:e.value}});t?.dispatchEvent(r)};return(()=>{const r=H(()=>document.importNode(nQ,!0)),i=r.firstChild,o=i.nextSibling,a=o.firstChild,s=a.firstChild,c=s.firstChild,l=s.nextSibling,u=t;return typeof u=="function"?he(u,r):t=r,x(i,Je),o.addEventListener("click",()=>n()),o._$owner=A(),c._$owner=A(),q(()=>l.checked=e.selected),r})()});function rQ(e){const[t,n]=kr(Array());return me(()=>{if(!e)return;const r=()=>{n(e()?.assignedElements()||[])};return e()?.addEventListener("slotchange",r)}),t}const iQ=N('<div><style></style><div class="flex flex-col gap-3"><slot></slot></div></div>');ct("https://cdn.jsdelivr.net/npm/@shoelace-style/shoelace@2.4.0/dist/");Me("photon-radio-group",{},()=>{let e;const[t,n]=V(),r=rQ(t),i=o=>{const a=new CustomEvent("photon-option-selected",{composed:!0,bubbles:!0,detail:{value:o}});e?.dispatchEvent(a)};return(()=>{const o=iQ.cloneNode(!0),a=o.firstChild,s=a.nextSibling,c=s.firstChild,l=e;return typeof l=="function"?he(l,o):e=o,o.addEventListener("photon-radio-selected",u=>{u.stopImmediatePropagation(),u.stopPropagation();for(const d of r)d.value.id===u.detail.value.id||d.value===u.detail.value?d.selected=!0:d.selected=!1;i(u.detail.value)}),x(a,Je),he(u=>n(u),c),c._$owner=A(),o})()});const oQ=N('<div><photon-dialog cancel-text="Back" confirm-text="Select Medication"><photon-med-search></photon-med-search></photon-dialog></div>');Me("photon-med-search-dialog",{open:{value:!1,reflect:!0,notify:!1,attribute:"open",parse:!0}},e=>{const t=pt();let n;const[r,i]=V(void 0),[o,a]=V(!1),[s,c]=V(""),[l,u]=V(!1),d=()=>{const f=new CustomEvent("photon-medication-selected",{composed:!0,bubbles:!0,detail:{medication:r()}});n?.dispatchEvent(f)};return(()=>{const f=H(()=>document.importNode(oQ,!0)),h=f.firstChild,p=h.firstChild,m=n;return typeof m=="function"?he(m,f):n=f,f.addEventListener("photon-form-updated",v=>{i(v.detail.medication),a(v.detail.addToCatalog),c(v.detail.catalogId)}),h.addEventListener("photon-dialog-confirmed",async()=>{if(u(!0),o()){const v=t.getSDK().clinical.catalog.addToCatalog({});try{await v({variables:{catalogId:s(),treatmentId:r()?.id},awaitRefetchQueries:!1})}catch(b){console.log("Error adding to catalog: ",b?.message)}}d(),u(!1),e.open=!1}),h.addEventListener("photon-dialog-canceled",()=>{e.open=!1}),h._$owner=A(),p._$owner=A(),q(v=>{const b=e.open,y=l(),g=!r();return b!==v._v$&&(h.open=v._v$=b),y!==v._v$2&&(h.loading=v._v$2=y),g!==v._v$3&&(h.disableSubmit=v._v$3=g),v},{_v$:void 0,_v$2:void 0,_v$3:void 0}),f})()});const aQ=N(`<div><photon-dialog label="Lose Unsaved Prescription?" confirm-text="Yes, Continue" cancel-text="Keep Editing" width="500px"><p class="font-sans text-lg xs:text-base">You have a prescription "<!>" that hasn't been added. Please add it or continue.</p></photon-dialog><photon-dialog label="Save prescriptions without an order?" confirm-text="Save and create order" cancel-text="Yes, Save Only" width="500px"><p class="font-sans text-lg xs:text-base">You're about to save prescriptions without creating a pharmacy order. You can create an order now, or at a later date.</p></photon-dialog></div>`),sQ=N('<div class="flex flex-row gap-1 lg:gap-2 justify-end items-end"><photon-button size="sm" variant="outline">Save prescriptions</photon-button><photon-button size="sm">Save and create order</photon-button></div>'),lQ=N('<div class="w-full h-full bg-[#f7f4f4]"><div class="w-full h-full sm:w-[600px] xs:mx-auto"><photon-prescribe-workflow hide-submit="true"></photon-prescribe-workflow></div></div>'),cQ=N('<div class="pt-2"><sl-alert variant="danger" open><div class="flex items-start xs:items-center gap-4"><sl-icon slot="icon" name="exclamation-octagon" class="text-red-500"></sl-icon><p class="font-sans"></p></div></sl-alert></div>'),uQ=e=>e().notes?.value.length>0||e().instructions?.value.length>0||e().treatment?.value||e().patient?.value||e().dispenseAsWritten?.value!=!1||e().dispenseQuantity?.value!=1||e().dispenseUnit?.value!="Each"||e().daysSupply?.value!=30||e().refillsInput?.value!=0||e().addToTemplates?.value!=!1||e().effectiveDate?.value!=Qc(new Date,"yyyy-MM-dd").toString()||e().draftPrescriptions?.value.length>0;Me("photon-multirx-form-wrapper",{hideTemplates:!1,patientId:void 0,templateIds:void 0},e=>{let t;const n=pt(),[r,i]=V(!1),[o,a]=V([]),[s,c]=V(!1),[l,u]=V(!1),[d,f]=V(!1),[h,p]=V(),[m,v]=V(),[b,y]=V(!1),[g,_]=V(!1),{actions:k}=Gc;ht(async()=>{const D=await n.getSDK().authentication.getAccessToken();b3(D).permissions?.includes("write:prescription")&&c(!0)});const O=(D,F,Y)=>{const J=new CustomEvent("photon-prescriptions-created",{composed:!0,bubbles:!0,detail:{patientId:Y,prescriptionIds:F,createOrder:D}});t?.dispatchEvent(J)},C=()=>{const D=new CustomEvent("photon-prescriptions-closed",{composed:!0,bubbles:!0,detail:{}});t?.dispatchEvent(D)},M=async(D,F,Y)=>{f(Y),a([]);const J=["patient","draftPrescriptions"];if(F.validate(J),!F.hasErrors(J)){u(!0),F.updateFormValue({key:"errors",value:[]});const j=n.getSDK().clinical.prescription.createPrescriptions({}),z=n.getSDK().clinical.prescriptionTemplate.createPrescriptionTemplate({}),Q=[];for(const I of D.draftPrescriptions.value){if(I.addToTemplates)try{const{errors:W}=await z({variables:{catalogId:I.catalogId,treatmentId:I.treatment.id,dispenseAsWritten:I.dispenseAsWritten,dispenseQuantity:I.dispenseQuantity,dispenseUnit:I.dispenseUnit,fillsAllowed:I.refillsInput+1,daysSupply:I.daysSupply,instructions:I.instructions,notes:I.notes},awaitRefetchQueries:!1});W&&a(W)}catch(W){a([W])}const U={daysSupply:I.daysSupply,dispenseAsWritten:I.dispenseAsWritten,dispenseQuantity:I.dispenseQuantity,dispenseUnit:I.dispenseUnit,effectiveDate:I.effectiveDate,instructions:I.instructions,notes:I.notes,patientId:D.patient?.value.id,fillsAllowed:I.refillsInput+1,treatmentId:I.treatment.id};Q.push(U)}if(o().length>0)return;try{const{data:I,errors:U}=await j({variables:{prescriptions:Q},refetchQueries:[],awaitRefetchQueries:!1});if(U){a(U);return}O(Y,I.createPrescriptions.map(W=>W.id),D.patient?.value.id),k.clearSelectedPatient()}catch(I){a([I])}u(!1)}};return(()=>{const D=H(()=>document.importNode(aQ,!0)),F=D.firstChild,Y=F.firstChild,J=Y.firstChild,G=J.nextSibling;G.nextSibling;const j=F.nextSibling,z=t;return typeof z=="function"?he(z,D):t=D,F.addEventListener("photon-dialog-confirmed",()=>{y(!1),M(h(),m(),!0)}),F.addEventListener("photon-dialog-canceled",()=>{y(!1)}),F._$owner=A(),x(Y,()=>h()?.treatment?.value?.name,G),j.addEventListener("photon-dialog-confirmed",()=>{_(!1),M(h(),m(),!0)}),j.addEventListener("photon-dialog-canceled",()=>{_(!1),M(h(),m(),!1)}),j._$owner=A(),x(D,S(r4,{closeTitle:"Lose unsaved prescriptions?",closeBody:"You will not be able to recover unsaved prescriptions.",onClosed:()=>{C(),k.clearSelectedPatient()},checkShouldWarn:()=>uQ(h),title:"New Prescriptions",titleIconName:"prescription",get headerRight(){return(()=>{const Q=H(()=>document.importNode(sQ,!0)),I=Q.firstChild,U=I.nextSibling;return I.addEventListener("photon-clicked",()=>_(!0)),I._$owner=A(),U.addEventListener("photon-clicked",()=>h()?.treatment?.value?.name?y(!0):M(h(),m(),!0)),U._$owner=A(),q(W=>{const de=!r()||!s(),be=l()&&!d(),P=!r()||!s(),B=l()&&d();return de!==W._v$3&&(I.disabled=W._v$3=de),be!==W._v$4&&(I.loading=W._v$4=be),P!==W._v$5&&(U.disabled=W._v$5=P),B!==W._v$6&&(U.loading=W._v$6=B),W},{_v$3:void 0,_v$4:void 0,_v$5:void 0,_v$6:void 0}),Q})()},get form(){return(()=>{const Q=H(()=>document.importNode(lQ,!0)),I=Q.firstChild,U=I.firstChild;return x(Q,S(ee,{get when(){return o().length>0},get children(){return S(sr,{get each(){return o()},children:W=>(()=>{const de=H(()=>document.importNode(cQ,!0)),be=de.firstChild,P=be.firstChild,B=P.firstChild,Ce=B.nextSibling;return be._$owner=A(),B.style.setProperty("font-size","24px"),B._$owner=A(),x(Ce,()=>W.message),de})()})}}),I),U.addEventListener("photon-form-validate",W=>{i(W.detail.canSubmit),v(W.detail.actions),p(W.detail.form)}),U._$owner=A(),q(W=>{const de=e.hideTemplates,be=l(),P=e.patientId,B=e.templateIds;return de!==W._v$7&&(U.hideTemplates=W._v$7=de),be!==W._v$8&&(U.loading=W._v$8=be),P!==W._v$9&&(U.patientId=W._v$9=P),B!==W._v$10&&(U.templateIds=W._v$10=B),W},{_v$7:void 0,_v$8:void 0,_v$9:void 0,_v$10:void 0}),Q})()}}),null),q(Q=>{const I=b(),U=g();return I!==Q._v$&&(F.open=Q._v$=I),U!==Q._v$2&&(j.open=Q._v$2=U),Q},{_v$:void 0,_v$2:void 0}),D})()});
|