(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4073],{1597:(e,t,r)=>{"use strict";r.d(t,{C6:()=>i,Cl:()=>o,Tt:()=>s,fX:()=>a});var n=function(e,t){return(n=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)};function i(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}var o=function(){return(o=Object.assign||function(e){for(var t,r=1,n=arguments.length;rt.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,n=Object.getOwnPropertySymbols(e);it.indexOf(n[i])&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r}Object.create;function a(e,t,r){if(r||2==arguments.length)for(var n,i=0,o=t.length;i{"use strict";r.d(t,{Kq:()=>l,Pj:()=>a,Xr:()=>d,fp:()=>g,md:()=>m});var n=r(77976),i=r(98540),o=r(28779);let s=(0,n.createContext)(void 0);function a(e){let t=(0,n.useContext)(s);return(null==e?void 0:e.store)||t||(0,i.zp)()}function l(e){let{children:t,store:r}=e,o=(0,n.useRef)(void 0);return r||o.current||(o.current=(0,i.y$)()),(0,n.createElement)(s.Provider,{value:r||o.current},t)}let u=e=>"function"==typeof(null==e?void 0:e.then),h=e=>{e.status||(e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}))},c=n.use||(e=>{if("pending"===e.status)throw e;if("fulfilled"===e.status)return e.value;if("rejected"===e.status)throw e.reason;throw h(e),e}),f=new WeakMap,p=(e,t)=>{let r=f.get(e);return r||(r=new Promise((n,i)=>{let s=e,a=e=>t=>{s===e&&n(t)},l=e=>t=>{s===e&&i(t)},h=()=>{try{let e=t();u(e)?(f.set(e,r),s=e,e.then(a(e),l(e)),(0,o.MO)(e,h)):n(e)}catch(e){i(e)}};e.then(a(e),l(e)),(0,o.MO)(e,h)}),f.set(e,r)),r};function m(e,t){let{delay:r,unstable_promiseStatus:i=!n.use}=t||{},o=a(t),[[s,l,f],m]=(0,n.useReducer)(t=>{let r=o.get(e);return Object.is(t[0],r)&&t[1]===o&&t[2]===e?t:[r,o,e]},void 0,()=>[o.get(e),o,e]),d=s;if((l!==o||f!==e)&&(m(),d=o.get(e)),(0,n.useEffect)(()=>{let t=o.sub(e,()=>{if(i)try{let t=o.get(e);u(t)&&h(p(t,()=>o.get(e)))}catch(e){}if("number"==typeof r)return void setTimeout(m,r);m()});return m(),t},[o,e,r,i]),(0,n.useDebugValue)(d),u(d)){let t=p(d,()=>o.get(e));return i&&h(t),c(t)}return d}function d(e,t){let r=a(t);return(0,n.useCallback)(function(){for(var t=arguments.length,n=Array(t),i=0;i{function t(e,t,r,n){return Math.round(e/r)+" "+n+(t>=1.5*r?"s":"")}e.exports=function(e,r){r=r||{};var n,i,o,s,a=typeof e;if("string"===a&&e.length>0){var l=e;if(!((l=String(l)).length>100)){var u=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(l);if(u){var h=parseFloat(u[1]);switch((u[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*h;case"weeks":case"week":case"w":return 6048e5*h;case"days":case"day":case"d":return 864e5*h;case"hours":case"hour":case"hrs":case"hr":case"h":return 36e5*h;case"minutes":case"minute":case"mins":case"min":case"m":return 6e4*h;case"seconds":case"second":case"secs":case"sec":case"s":return 1e3*h;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return h;default:break}}}return}if("number"===a&&isFinite(e)){return r.long?(i=Math.abs(n=e))>=864e5?t(n,i,864e5,"day"):i>=36e5?t(n,i,36e5,"hour"):i>=6e4?t(n,i,6e4,"minute"):i>=1e3?t(n,i,1e3,"second"):n+" ms":(s=Math.abs(o=e))>=864e5?Math.round(o/864e5)+"d":s>=36e5?Math.round(o/36e5)+"h":s>=6e4?Math.round(o/6e4)+"m":s>=1e3?Math.round(o/1e3)+"s":o+"ms"}throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},11182:(e,t,r)=>{"use strict";var n=r(72962);r.o(n,"useParams")&&r.d(t,{useParams:function(){return n.useParams}}),r.o(n,"usePathname")&&r.d(t,{usePathname:function(){return n.usePathname}}),r.o(n,"useRouter")&&r.d(t,{useRouter:function(){return n.useRouter}}),r.o(n,"useSearchParams")&&r.d(t,{useSearchParams:function(){return n.useSearchParams}})},11231:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"setAttributesFromProps",{enumerable:!0,get:function(){return o}});let r={acceptCharset:"accept-charset",className:"class",htmlFor:"for",httpEquiv:"http-equiv",noModule:"noModule"},n=["onLoad","onReady","dangerouslySetInnerHTML","children","onError","strategy","stylesheets"];function i(e){return["async","defer","noModule"].includes(e)}function o(e,t){for(let[o,s]of Object.entries(t)){if(!t.hasOwnProperty(o)||n.includes(o)||void 0===s)continue;let a=r[o]||o.toLowerCase();"SCRIPT"===e.tagName&&i(a)?e[a]=!!s:e.setAttribute(a,String(s)),(!1===s||"SCRIPT"===e.tagName&&i(a)&&(!s||"false"===s))&&(e.setAttribute(a,""),e.removeAttribute(a))}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},20392:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{default:function(){return E},handleClientScriptLoad:function(){return m},initScriptLoader:function(){return d}});let n=r(92174),i=r(62983),o=r(16852),s=n._(r(97881)),a=i._(r(77976)),l=r(58491),u=r(11231),h=r(90523),c=new Map,f=new Set,p=e=>{let{src:t,id:r,onLoad:n=()=>{},onReady:i=null,dangerouslySetInnerHTML:o,children:a="",strategy:l="afterInteractive",onError:h,stylesheets:p}=e,m=r||t;if(m&&f.has(m))return;if(c.has(t)){f.add(m),c.get(t).then(n,h);return}let d=()=>{i&&i(),f.add(m)},g=document.createElement("script"),E=new Promise((e,t)=>{g.addEventListener("load",function(t){e(),n&&n.call(this,t),d()}),g.addEventListener("error",function(e){t(e)})}).catch(function(e){h&&h(e)});o?(g.innerHTML=o.__html||"",d()):a?(g.textContent="string"==typeof a?a:Array.isArray(a)?a.join(""):"",d()):t&&(g.src=t,c.set(t,E)),(0,u.setAttributesFromProps)(g,e),"worker"===l&&g.setAttribute("type","text/partytown"),g.setAttribute("data-nscript",l),p&&(e=>{if(s.default.preinit)return e.forEach(e=>{s.default.preinit(e,{as:"style"})});{let t=document.head;e.forEach(e=>{let r=document.createElement("link");r.type="text/css",r.rel="stylesheet",r.href=e,t.appendChild(r)})}})(p),document.body.appendChild(g)};function m(e){let{strategy:t="afterInteractive"}=e;"lazyOnload"===t?window.addEventListener("load",()=>{(0,h.requestIdleCallback)(()=>p(e))}):p(e)}function d(e){e.forEach(m),[...document.querySelectorAll('[data-nscript="beforeInteractive"]'),...document.querySelectorAll('[data-nscript="beforePageRender"]')].forEach(e=>{let t=e.id||e.getAttribute("src");f.add(t)})}function g(e){let{id:t,src:r="",onLoad:n=()=>{},onReady:i=null,strategy:u="afterInteractive",onError:c,stylesheets:m,...d}=e,{updateScripts:g,scripts:E,getIsSsr:b,appDir:y,nonce:v}=(0,a.useContext)(l.HeadManagerContext);v=d.nonce||v;let C=(0,a.useRef)(!1);(0,a.useEffect)(()=>{let e=t||r;C.current||(i&&e&&f.has(e)&&i(),C.current=!0)},[i,t,r]);let _=(0,a.useRef)(!1);if((0,a.useEffect)(()=>{if(!_.current){if("afterInteractive"===u)p(e);else"lazyOnload"===u&&("complete"===document.readyState?(0,h.requestIdleCallback)(()=>p(e)):window.addEventListener("load",()=>{(0,h.requestIdleCallback)(()=>p(e))}));_.current=!0}},[e,u]),("beforeInteractive"===u||"worker"===u)&&(g?(E[u]=(E[u]||[]).concat([{id:t,src:r,onLoad:n,onReady:i,onError:c,...d,nonce:v}]),g(E)):b&&b()?f.add(t||r):b&&!b()&&p({...e,nonce:v})),y){if(m&&m.forEach(e=>{s.default.preinit(e,{as:"style"})}),"beforeInteractive"===u)if(!r)return d.dangerouslySetInnerHTML&&(d.children=d.dangerouslySetInnerHTML.__html,delete d.dangerouslySetInnerHTML),(0,o.jsx)("script",{nonce:v,dangerouslySetInnerHTML:{__html:"(self.__next_s=self.__next_s||[]).push("+JSON.stringify([0,{...d,id:t}])+")"}});else return s.default.preload(r,d.integrity?{as:"script",integrity:d.integrity,nonce:v,crossOrigin:d.crossOrigin}:{as:"script",nonce:v,crossOrigin:d.crossOrigin}),(0,o.jsx)("script",{nonce:v,dangerouslySetInnerHTML:{__html:"(self.__next_s=self.__next_s||[]).push("+JSON.stringify([r,{...d,id:t}])+")"}});"afterInteractive"===u&&r&&s.default.preload(r,d.integrity?{as:"script",integrity:d.integrity,nonce:v,crossOrigin:d.crossOrigin}:{as:"script",nonce:v,crossOrigin:d.crossOrigin})}return null}Object.defineProperty(g,"__nextScript",{value:!0});let E=g;("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},28779:(e,t,r)=>{"use strict";r.d(t,{MO:()=>d,_w:()=>m});let n=(e,t)=>e.unstable_is?e.unstable_is(t):t===e,i=e=>"v"in e||"e"in e,o=e=>{if("e"in e)throw e.e;if(!("v"in e))throw Error("[Bug] atom state is not initialized");return e.v},s=new WeakMap,a=e=>{var t;return u(e)&&!!(null==(t=s.get(e))?void 0:t[0])},l=(e,t)=>{let r=s.get(e);if(!r){r=[!0,new Set],s.set(e,r);let t=()=>{r[0]=!1};e.then(t,t)}r[1].add(t)},u=e=>"function"==typeof(null==e?void 0:e.then),h=(e,t,r)=>{r.p.has(e)||(r.p.add(e),t.then(()=>{r.p.delete(e)},()=>{r.p.delete(e)}))},c=(e,t,r)=>{let n=r(e),i="v"in n,o=n.v;if(u(t))for(let i of n.d.keys())h(e,t,r(i));n.v=t,delete n.e,i&&Object.is(o,n.v)||(++n.n,u(o)&&(e=>{let t=s.get(e);(null==t?void 0:t[0])&&(t[0]=!1,t[1].forEach(e=>e()))})(o))},f=(e,t,r)=>{var n;let i=new Set;for(let t of(null==(n=r.get(e))?void 0:n.t)||[])r.has(t)&&i.add(t);for(let e of t.p)i.add(e);return i},p=Symbol(),m=(e=new WeakMap,t=new WeakMap,r=new WeakMap,s=new Set,m=new Set,d=new Set,g={},E=(e,...t)=>e.read(...t),b=(e,...t)=>e.write(...t),y=(e,t)=>{var r;return null==(r=e.unstable_onInit)?void 0:r.call(e,t)},v=(e,t)=>{var r;return null==(r=e.onMount)?void 0:r.call(e,t)},...C)=>{let _=C[0]||(t=>{if(!t)throw Error("Atom is undefined or null");let r=e.get(t);return r||(r={d:new Map,p:new Set,n:0},e.set(t,r),null==y||y(t,M)),r}),T=C[1]||(()=>{let e=[],r=t=>{try{t()}catch(t){e.push(t)}};do{g.f&&r(g.f);let e=new Set,n=e.add.bind(e);s.forEach(e=>{var r;return null==(r=t.get(e))?void 0:r.l.forEach(n)}),s.clear(),d.forEach(n),d.clear(),m.forEach(n),m.clear(),e.forEach(r),s.size&&A()}while(s.size||d.size||m.size);if(e.length)throw AggregateError(e)}),A=C[2]||(()=>{let e=[],n=new WeakSet,i=new WeakSet,o=Array.from(s);for(;o.length;){let s=o[o.length-1],a=_(s);if(i.has(s)){o.pop();continue}if(n.has(s)){if(r.get(s)===a.n)e.push([s,a]);else if(r.has(s))throw Error("[Bug] invalidated atom exists");i.add(s),o.pop();continue}for(let e of(n.add(s),f(s,a,t)))n.has(e)||o.push(e)}for(let t=e.length-1;t>=0;--t){let[n,i]=e[t],o=!1;for(let e of i.d.keys())if(e!==n&&s.has(e)){o=!0;break}o&&(H(n),I(n)),r.delete(n)}}),H=C[3]||(e=>{var f;let p,m,d=_(e);if(i(d)&&(t.has(e)&&r.get(e)!==d.n||Array.from(d.d).every(([e,t])=>H(e).n===t)))return d;d.d.clear();let b=!0,y=()=>{t.has(e)&&(I(e),A(),T())},v=d.n;try{let r=E(e,r=>{var s;if(n(e,r)){let e=_(r);if(!i(e))if("init"in r)c(r,r.init,_);else throw Error("no atom init");return o(e)}let l=H(r);try{return o(l)}finally{d.d.set(r,l.n),a(d.v)&&h(e,d.v,l),null==(s=t.get(r))||s.t.add(e),b||y()}},{get signal(){return p||(p=new AbortController),p.signal},get setSelf(){return e.write||console.warn("setSelf function cannot be used with read-only atom"),!m&&e.write&&(m=(...t)=>{if(b&&console.warn("setSelf function cannot be called in sync"),!b)try{return B(e,...t)}finally{A(),T()}}),m}});return c(e,r,_),u(r)&&(l(r,()=>null==p?void 0:p.abort()),r.then(y,y)),d}catch(e){return delete d.v,d.e=e,++d.n,d}finally{b=!1,v!==d.n&&r.get(e)===v&&(r.set(e,d.n),s.add(e),null==(f=g.c)||f.call(g,e))}}),S=C[4]||(e=>{let n=[e];for(;n.length;){let e=n.pop(),i=_(e);for(let o of f(e,i,t)){let e=_(o);r.set(o,e.n),n.push(o)}}}),B=C[5]||((e,...t)=>{let r=!0;try{return b(e,e=>o(H(e)),(t,...i)=>{var o;let a=_(t);try{if(!n(e,t))return B(t,...i);{if(!("init"in t))throw Error("atom not writable");let e=a.n,r=i[0];c(t,r,_),I(t),e!==a.n&&(s.add(t),null==(o=g.c)||o.call(g,t),S(t));return}}finally{r||(A(),T())}},...t)}finally{r=!1}}),I=C[6]||(e=>{var r;let n=_(e),i=t.get(e);if(i&&!a(n.v)){for(let[t,o]of n.d)if(!i.d.has(t)){let n=_(t);L(t).t.add(e),i.d.add(t),o!==n.n&&(s.add(t),null==(r=g.c)||r.call(g,t),S(t))}for(let t of i.d||[])if(!n.d.has(t)){i.d.delete(t);let r=N(t);null==r||r.t.delete(e)}}}),L=C[7]||(e=>{var r;let n=_(e),i=t.get(e);if(!i){for(let t of(H(e),n.d.keys()))L(t).t.add(e);i={l:new Set,d:new Set(n.d.keys()),t:new Set},t.set(e,i),null==(r=g.m)||r.call(g,e),e.write&&m.add(()=>{let t=!0;try{let r=v(e,(...r)=>{try{return B(e,...r)}finally{t||(A(),T())}});r&&(i.u=()=>{t=!0;try{r()}finally{t=!1}})}finally{t=!1}})}return i}),N=C[8]||(e=>{var r;let n=_(e),i=t.get(e);if(i&&!i.l.size&&!Array.from(i.t).some(r=>{var n;return null==(n=t.get(r))?void 0:n.d.has(e)})){for(let o of(i.u&&d.add(i.u),i=void 0,t.delete(e),null==(r=g.u)||r.call(g,e),n.d.keys())){let t=N(o);null==t||t.t.delete(e)}return}return i}),M={get:e=>o(H(e)),set:(e,...t)=>{try{return B(e,...t)}finally{A(),T()}},sub:(e,t)=>{let r=L(e).l;return r.add(t),T(),()=>{r.delete(t),N(e),T()}}};return Object.defineProperty(M,p,{value:[e,t,r,s,m,d,g,E,b,y,v,_,T,A,H,S,B,I,L,N]}),M},d=l},31480:(e,t,r)=>{e.exports=function(e){function t(e){let r,i,o,s=null;function a(...e){if(!a.enabled)return;let n=Number(new Date);a.diff=n-(r||n),a.prev=r,a.curr=n,r=n,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let i=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,(r,n)=>{if("%%"===r)return"%";i++;let o=t.formatters[n];if("function"==typeof o){let t=e[i];r=o.call(a,t),e.splice(i,1),i--}return r}),t.formatArgs.call(a,e),(a.log||t.log).apply(a,e)}return a.namespace=e,a.useColors=t.useColors(),a.color=t.selectColor(e),a.extend=n,a.destroy=t.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(i!==t.namespaces&&(i=t.namespaces,o=t.enabled(e)),o),set:e=>{s=e}}),"function"==typeof t.init&&t.init(a),a}function n(e,r){let n=t(this.namespace+(void 0===r?":":r)+e);return n.log=this.log,n}function i(e,t){let r=0,n=0,i=-1,o=0;for(;r"-"+e)].join(",");return t.enable(""),e},t.enable=function(e){for(let r of(t.save(e),t.namespaces=e,t.names=[],t.skips=[],("string"==typeof e?e:"").trim().replace(/\s+/g,",").split(",").filter(Boolean)))"-"===r[0]?t.skips.push(r.slice(1)):t.names.push(r)},t.enabled=function(e){for(let r of t.skips)if(i(e,r))return!1;for(let r of t.names)if(i(e,r))return!0;return!1},t.humanize=r(7917),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach(r=>{t[r]=e[r]}),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let r=0;for(let t=0;t{var n=r(37811);t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;let r="color: "+this.color;t.splice(1,0,r,"color: inherit");let n=0,i=0;t[0].replace(/%[a-zA-Z%]/g,e=>{"%%"!==e&&(n++,"%c"===e&&(i=n))}),t.splice(i,0,r)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")||t.storage.getItem("DEBUG")}catch(e){}return!e&&void 0!==n&&"env"in n&&(e=n.env.DEBUG),e},t.useColors=function(){let e;return"undefined"!=typeof window&&!!window.process&&("renderer"===window.process.type||!!window.process.__nwjs)||!("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=r(31480)(t);let{formatters:i}=e.exports;i.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},85256:(e,t,r)=>{"use strict";r.d(t,{Dk:()=>eB,kc:()=>eP,c3:()=>eM});var n,i,o,s,a,l,u,h=r(77976),c=r(1597);function f(e,t){var r=t&&t.cache?t.cache:E,n=t&&t.serializer?t.serializer:d;return(t&&t.strategy?t.strategy:function(e,t){var r,n,i=1===e.length?p:m;return r=t.cache.create(),n=t.serializer,i.bind(this,e,r,n)})(e,{cache:r,serializer:n})}function p(e,t,r,n){var i=null==n||"number"==typeof n||"boolean"==typeof n?n:r(n),o=t.get(i);return void 0===o&&(o=e.call(this,n),t.set(i,o)),o}function m(e,t,r){var n=Array.prototype.slice.call(arguments,3),i=r(n),o=t.get(i);return void 0===o&&(o=e.apply(this,n),t.set(i,o)),o}var d=function(){return JSON.stringify(arguments)},g=function(){function e(){this.cache=Object.create(null)}return e.prototype.get=function(e){return this.cache[e]},e.prototype.set=function(e,t){this.cache[e]=t},e}(),E={create:function(){return new g}},b={variadic:function(e,t){var r,n;return r=t.cache.create(),n=t.serializer,m.bind(this,e,r,n)},monadic:function(e,t){var r,n;return r=t.cache.create(),n=t.serializer,p.bind(this,e,r,n)}};function y(e){return e.type===i.literal}function v(e){return e.type===i.number}function C(e){return e.type===i.date}function _(e){return e.type===i.time}function T(e){return e.type===i.select}function A(e){return e.type===i.plural}function H(e){return e.type===i.tag}function S(e){return!!(e&&"object"==typeof e&&e.type===o.number)}function B(e){return!!(e&&"object"==typeof e&&e.type===o.dateTime)}!function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"}(n||(n={})),function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"}(i||(i={})),function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"}(o||(o={}));var I=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,L=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g,N=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i,M=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,P=/^(@+)?(\+|#+)?[rs]?$/g,w=/(\*)(0+)|(#+)(0+)|(0+)/g,O=/^(0+)$/;function R(e){var t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(P,function(e,r,n){return"string"!=typeof n?(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length):"+"===n?t.minimumSignificantDigits=r.length:"#"===r[0]?t.maximumSignificantDigits=r.length:(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length+("string"==typeof n?n.length:0)),""}),t}function F(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function G(e){var t=F(e);return t||{}}var U={"001":["H","h"],419:["h","H","hB","hb"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["h","H","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["h","H","hB","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["h","H","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["h","H","hB","hb"],CU:["h","H","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["h","H","hB","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["h","H","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["h","H","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["h","H","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["h","H","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["h","H","hB","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["h","H","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["h","H","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["h","H","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"en-HK":["h","hb","H","hB"],"en-IL":["H","h","hb","hB"],"en-MY":["h","hb","H","hB"],"es-BR":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]},D=new RegExp("^".concat(I.source,"*")),k=new RegExp("".concat(I.source,"*$"));function x(e,t){return{start:e,end:t}}var j=!!String.prototype.startsWith&&"_a".startsWith("a",1),V=!!String.fromCodePoint,X=!!Object.fromEntries,K=!!String.prototype.codePointAt,Z=!!String.prototype.trimStart,z=!!String.prototype.trimEnd,Y=Number.isSafeInteger?Number.isSafeInteger:function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&0x1fffffffffffff>=Math.abs(e)},W=!0;try{W=(null==(s=er("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))?void 0:s[0])==="a"}catch(e){W=!1}var q=j?function(e,t,r){return e.startsWith(t,r)}:function(e,t,r){return e.slice(r,r+t.length)===t},J=V?String.fromCodePoint:function(){for(var e,t=[],r=0;ro;){if((e=t[o++])>1114111)throw RangeError(e+" is not a valid code point");n+=e>10)+55296,e%1024+56320)}return n},Q=X?Object.fromEntries:function(e){for(var t={},r=0;r=n)){var i=e.charCodeAt(t);return i56319||t+1===n||(r=e.charCodeAt(t+1))57343?i:(i-55296=33&&n=37&&n=46&&n=58&&n=60&&n=63&&n=162&&n=8208&&n=8214&&n=8219&&n=8224&&n=8240&&n=8251&&n=8257&&n=8263&&n=8277&&n=8592&&n=8597&&n=8602&&n=8604&&n=8609&&n=8612&&n=8615&&n=8623&&n=8654&&n=8656&&n=8661&&n=8692&&n=8960&&n=8972&&n=8992&&n=8994&&n=9003&&n=9085&&n=9115&&n=9140&&n=9180&&n=9186&&n=9255&&n=9280&&n=9291&&n=9472&&n=9656&&n=9666&&n=9720&&n=9728&&n=9840&&n=10132&&n=10176&&n=10183&&n=10224&&n=10240&&n=10496&&n=10649&&n=10716&&n=10750&&n=11008&&n=11056&&n=11077&&n=11079&&n=11085&&n=11124&&n=11126&&n=11159&&n=11776&&n=11782&&n=11790&&n=11800&&n=11806&&n=11818&&n=11824&&n=11834&&n=11836&&n=11843&&n=11856&&n=11859&&n=12289&&n=12306&&n=12318&&n=65093&&n=65536?2:1}return J.apply(void 0,r)};var ei=function(){function e(e,t){void 0===t&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return e.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(e,t,r){for(var o=[];!this.isEOF();){var s=this.char();if(123===s){var a=this.parseArgument(e,r);if(a.err)return a;o.push(a.val)}else if(125===s&&e>0)break;else if(35===s&&("plural"===t||"selectordinal"===t)){var l=this.clonePosition();this.bump(),o.push({type:i.pound,location:x(l,this.clonePosition())})}else if(60!==s||this.ignoreTag||47!==this.peek())if(60===s&&!this.ignoreTag&&eo(this.peek()||0)){var a=this.parseTag(e,t);if(a.err)return a;o.push(a.val)}else{var a=this.parseLiteral(e,t);if(a.err)return a;o.push(a.val)}else if(!r)return this.error(n.UNMATCHED_CLOSING_TAG,x(this.clonePosition(),this.clonePosition()));else break}return{val:o,err:null}},e.prototype.parseTag=function(e,t){var r=this.clonePosition();this.bump();var o=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:i.literal,value:""),location:x(r,this.clonePosition())},err:null};if(!this.bumpIf(">"))return this.error(n.INVALID_TAG,x(r,this.clonePosition()));var s=this.parseMessage(e+1,t,!0);if(s.err)return s;var a=s.val,l=this.clonePosition();if(!this.bumpIf(""))return this.error(n.UNCLOSED_TAG,x(r,this.clonePosition()));if(this.isEOF()||!eo(this.char()))return this.error(n.INVALID_TAG,x(l,this.clonePosition()));var u=this.clonePosition();return o!==this.parseTagName()?this.error(n.UNMATCHED_CLOSING_TAG,x(u,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">"))?{val:{type:i.tag,value:o,children:a,location:x(r,this.clonePosition())},err:null}:this.error(n.INVALID_TAG,x(l,this.clonePosition()))},e.prototype.parseTagName=function(){var e,t=this.offset();for(this.bump();!this.isEOF()&&(45===(e=this.char())||46===e||e>=48&&e=97&&e=65&&e=192&&e=216&&e=248&&e=895&&e=8204&&e=8255&&e=8304&&e=11264&&e=12289&&e=63744&&e=65008&&e=65536&&e0?null:(this.bump(),J(r))},e.prototype.parseArgument=function(e,t){var r=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(n.EXPECT_ARGUMENT_CLOSING_BRACE,x(r,this.clonePosition()));if(125===this.char())return this.bump(),this.error(n.EMPTY_ARGUMENT,x(r,this.clonePosition()));var o=this.parseIdentifierIfPossible().value;if(!o)return this.error(n.MALFORMED_ARGUMENT,x(r,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(n.EXPECT_ARGUMENT_CLOSING_BRACE,x(r,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:i.argument,value:o,location:x(r,this.clonePosition())},err:null};case 44:if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(n.EXPECT_ARGUMENT_CLOSING_BRACE,x(r,this.clonePosition()));return this.parseArgumentOptions(e,t,o,r);default:return this.error(n.MALFORMED_ARGUMENT,x(r,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),r=a(this.message,t),n=t+r.length;return this.bumpTo(n),{value:r,location:x(e,this.clonePosition())}},e.prototype.parseArgumentOptions=function(e,t,r,s){var a,l=this.clonePosition(),u=this.parseIdentifierIfPossible().value,h=this.clonePosition();switch(u){case"":return this.error(n.EXPECT_ARGUMENT_TYPE,x(l,h));case"number":case"date":case"time":this.bumpSpace();var f=null;if(this.bumpIf(",")){this.bumpSpace();var p=this.clonePosition(),m=this.parseSimpleArgStyleIfPossible();if(m.err)return m;var d=et(m.val);if(0===d.length)return this.error(n.EXPECT_ARGUMENT_STYLE,x(this.clonePosition(),this.clonePosition()));f={style:d,styleLocation:x(p,this.clonePosition())}}var g=this.tryParseArgumentClose(s);if(g.err)return g;var E=x(s,this.clonePosition());if(f&&q(null==f?void 0:f.style,"::",0)){var b=ee(f.style.slice(2));if("number"===u){var m=this.parseNumberSkeletonFromString(b,f.styleLocation);if(m.err)return m;return{val:{type:i.number,value:r,location:E,style:m.val},err:null}}if(0===b.length)return this.error(n.EXPECT_DATE_TIME_SKELETON,E);var y,v=b;this.locale&&(v=function(e,t){for(var r="",n=0;n>1),l=function(e){var t,r=e.hourCycle;if(void 0===r&&e.hourCycles&&e.hourCycles.length&&(r=e.hourCycles[0]),r)switch(r){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw Error("Invalid hourCycle")}var n=e.language;return"root"!==n&&(t=e.maximize().region),(U[t||""]||U[n||""]||U["".concat(n,"-001")]||U["001"])[0]}(t);for(("H"==l||"k"==l)&&(a=0);a-- >0;)r+="a";for(;s-- >0;)r=l+r}else"J"===i?r+="H":r+=i}return r}(b,this.locale));var d={type:o.dateTime,pattern:v,location:f.styleLocation,parsedOptions:this.shouldParseSkeletons?(y={},v.replace(L,function(e){var t=e.length;switch(e[0]){case"G":y.era=4===t?"long":5===t?"narrow":"short";break;case"y":y.year=2===t?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":y.month=["numeric","2-digit","short","long","narrow"][t-1];break;case"w":case"W":throw RangeError("`w/W` (week) patterns are not supported");case"d":y.day=["numeric","2-digit"][t-1];break;case"D":case"F":case"g":throw RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":y.weekday=4===t?"long":5===t?"narrow":"short";break;case"e":if(t0))return{val:this.message.slice(t.offset,this.offset()),err:null};e-=1;break;default:this.bump()}return{val:this.message.slice(t.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(e,t){var r=[];try{r=function(e){if(0===e.length)throw Error("Number skeleton cannot be empty");for(var t=e.split(N).filter(function(e){return e.length>0}),r=[],n=0;n1)throw RangeError("integer-width stems only accept a single optional option");n.options[0].replace(w,function(e,r,n,i,o,s){if(r)t.minimumIntegerDigits=n.length;else if(i&&o)throw Error("We currently do not support maximum integer digits");else if(s)throw Error("We currently do not support exact integer digits");return""});continue}if(O.test(n.stem)){t.minimumIntegerDigits=n.stem.length;continue}if(M.test(n.stem)){if(n.options.length>1)throw RangeError("Fraction-precision stems only accept a single optional option");n.stem.replace(M,function(e,r,n,i,o,s){return"*"===n?t.minimumFractionDigits=r.length:i&&"#"===i[0]?t.maximumFractionDigits=i.length:o&&s?(t.minimumFractionDigits=o.length,t.maximumFractionDigits=o.length+s.length):(t.minimumFractionDigits=r.length,t.maximumFractionDigits=r.length),""});var i=n.options[0];"w"===i?t=(0,c.Cl)((0,c.Cl)({},t),{trailingZeroDisplay:"stripIfInteger"}):i&&(t=(0,c.Cl)((0,c.Cl)({},t),R(i)));continue}if(P.test(n.stem)){t=(0,c.Cl)((0,c.Cl)({},t),R(n.stem));continue}var o=F(n.stem);o&&(t=(0,c.Cl)((0,c.Cl)({},t),o));var s=function(e){var t;if("E"===e[0]&&"E"===e[1]?(t={notation:"engineering"},e=e.slice(2)):"E"===e[0]&&(t={notation:"scientific"},e=e.slice(1)),t){var r=e.slice(0,2);if("+!"===r?(t.signDisplay="always",e=e.slice(2)):"+?"===r&&(t.signDisplay="exceptZero",e=e.slice(2)),!O.test(e))throw Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}(n.stem);s&&(t=(0,c.Cl)((0,c.Cl)({},t),s))}return t}(r):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(e,t,r,i){for(var o,s=!1,a=[],l=new Set,u=i.value,h=i.location;;){if(0===u.length){var c=this.clonePosition();if("select"!==t&&this.bumpIf("=")){var f=this.tryParseDecimalInteger(n.EXPECT_PLURAL_ARGUMENT_SELECTOR,n.INVALID_PLURAL_ARGUMENT_SELECTOR);if(f.err)return f;h=x(c,this.clonePosition()),u=this.message.slice(c.offset,this.offset())}else break}if(l.has(u))return this.error("select"===t?n.DUPLICATE_SELECT_ARGUMENT_SELECTOR:n.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,h);"other"===u&&(s=!0),this.bumpSpace();var p=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===t?n.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:n.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,x(this.clonePosition(),this.clonePosition()));var m=this.parseMessage(e+1,t,r);if(m.err)return m;var d=this.tryParseArgumentClose(p);if(d.err)return d;a.push([u,{value:m.val,location:x(p,this.clonePosition())}]),l.add(u),this.bumpSpace(),u=(o=this.parseIdentifierIfPossible()).value,h=o.location}return 0===a.length?this.error("select"===t?n.EXPECT_SELECT_ARGUMENT_SELECTOR:n.EXPECT_PLURAL_ARGUMENT_SELECTOR,x(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!s?this.error(n.MISSING_OTHER_CLAUSE,x(this.clonePosition(),this.clonePosition())):{val:a,err:null}},e.prototype.tryParseDecimalInteger=function(e,t){var r=1,n=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(r=-1);for(var i=!1,o=0;!this.isEOF();){var s=this.char();if(s>=48&&s=this.message.length)throw Error("out of bound");var t=$(this.message,e);if(void 0===t)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},e.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},e.prototype.bump=function(){if(!this.isEOF()){var e=this.char();10===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e=0?(this.bumpTo(r),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&es(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),r=this.message.charCodeAt(t+(e>=65536?2:1));return null!=r?r:null},e}();function eo(e){return e>=97&&e=65&&e=9&&e=8206&&e0?t[0]:"string"==typeof e?e:e[0])}},e.__parse=ea,e.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"},percent:{style:"percent"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},e}();class em extends Error{constructor(e,t){let r=e;t&&(r+=": "+t),super(r),this.code=e,t&&(this.originalMessage=t)}}var ed=function(e){return e.MISSING_MESSAGE="MISSING_MESSAGE",e.MISSING_FORMAT="MISSING_FORMAT",e.ENVIRONMENT_FALLBACK="ENVIRONMENT_FALLBACK",e.INSUFFICIENT_PATH="INSUFFICIENT_PATH",e.INVALID_MESSAGE="INVALID_MESSAGE",e.INVALID_KEY="INVALID_KEY",e.FORMATTING_ERROR="FORMATTING_ERROR",e}(ed||{});function eg(...e){return e.filter(Boolean).join(".")}function eE(e){return eg(e.namespace,e.key)}function eb(e){console.error(e)}function ey(){return{dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}}}function ev(e,t){return f(e,{cache:{create:()=>({get:e=>t[e],set(e,r){t[e]=r}})},strategy:b.variadic})}function eC(e,t){return ev((...t)=>new e(...t),t)}function e_(e){return{getDateTimeFormat:eC(Intl.DateTimeFormat,e.dateTime),getNumberFormat:eC(Intl.NumberFormat,e.number),getPluralRules:eC(Intl.PluralRules,e.pluralRules),getRelativeTimeFormat:eC(Intl.RelativeTimeFormat,e.relativeTime),getListFormat:eC(Intl.ListFormat,e.list),getDisplayNames:eC(Intl.DisplayNames,e.displayNames)}}function eT(e,t,r,n){let i=eg(n,r);if(!t)throw Error(i);let o=t;return r.split(".").forEach(t=>{let r=o[t];if(null==t||null==r)throw Error(i+` (${e})`);o=r}),o}let eA={second:1,seconds:1,minute:60,minutes:60,hour:3600,hours:3600,day:86400,days:86400,week:604800,weeks:604800,month:2628e3,months:2628e3,quarter:7884e3,quarters:7884e3,year:31536e3,years:31536e3};var eH=r(16852);let eS=(0,h.createContext)(void 0);function eB({children:e,formats:t,getMessageFallback:r,locale:n,messages:i,now:o,onError:s,timeZone:a}){let l=(0,h.useContext)(eS),u=(0,h.useMemo)(()=>l?.cache||ey(),[n,l?.cache]),c=(0,h.useMemo)(()=>l?.formatters||e_(u),[u,l?.formatters]),f=(0,h.useMemo)(()=>({...function({formats:e,getMessageFallback:t,messages:r,onError:n,...i}){return{...i,formats:e||void 0,messages:r||void 0,onError:n||eb,getMessageFallback:t||eE}}({locale:n,formats:void 0===t?l?.formats:t,getMessageFallback:r||l?.getMessageFallback,messages:void 0===i?l?.messages:i,now:o||l?.now,onError:s||l?.onError,timeZone:a||l?.timeZone}),formatters:c,cache:u}),[u,t,c,r,n,i,o,s,l,a]);return(0,eH.jsx)(eS.Provider,{value:f,children:e})}function eI(){let e=(0,h.useContext)(eS);if(!e)throw Error(void 0);return e}let eL=!1,eN="undefined"==typeof window;function eM(e){return function(e,t,r){let{cache:n,formats:i,formatters:o,getMessageFallback:s,locale:a,onError:l,timeZone:u}=eI(),c=e["!"],f="!"===t?void 0:t.slice((r+".").length);return u||eL||!eN||(eL=!0,l(new em(ed.ENVIRONMENT_FALLBACK,void 0))),(0,h.useMemo)(()=>(function(e){let t=function(e,t,r,n=eb){try{if(!t)throw Error(void 0);let n=r?eT(e,t,r):t;if(!n)throw Error(r);return n}catch(t){let e=new em(ed.MISSING_MESSAGE,t.message);return n(e),e}}(e.locale,e.messages,e.namespace,e.onError);return function({cache:e,formats:t,formatters:r,getMessageFallback:n=eE,locale:i,messagesOrError:o,namespace:s,onError:a,timeZone:l}){let u=o instanceof em;function c(e,t,r){let i=new em(t,r);return a(i),n({error:i,key:e,namespace:s})}function f(a,f,p){var m;let d,g;if(u)return n({error:o,key:a,namespace:s});try{d=eT(i,o,a,s)}catch(e){return c(a,ed.MISSING_MESSAGE,e.message)}if("object"==typeof d){let e;return c(a,Array.isArray(d)?ed.INVALID_MESSAGE:ed.INSUFFICIENT_PATH,e)}let E=(m=d,f||/'[{}]/.test(m)?void 0:m);if(E)return E;r.getMessageFormat||(r.getMessageFormat=ev((...e)=>new ep(e[0],e[1],e[2],{formatters:r,...e[3]}),e.message));try{g=r.getMessageFormat(d,i,function(e,t,r){let n=ep.formats.date,i=ep.formats.time,o={...e?.dateTime,...t?.dateTime},s={date:{...n,...o},time:{...i,...o},number:{...e?.number,...t?.number}};return r&&["date","time"].forEach(e=>{let t=s[e];for(let[e,n]of Object.entries(t))t[e]={timeZone:r,...n}}),s}(t,p,l),{formatters:{...r,getDateTimeFormat:(e,t)=>r.getDateTimeFormat(e,{timeZone:l,...t})}})}catch(e){return c(a,ed.INVALID_MESSAGE,e.message)}try{let e=g.format(f?function(e){let t={};return Object.keys(e).forEach(r=>{let n,i=0,o=e[r];n="function"==typeof o?e=>{let t=o(e);return(0,h.isValidElement)(t)?(0,h.cloneElement)(t,{key:r+i++}):t}:o,t[r]=n}),t}(f):f);if(null==e)throw Error(void 0);return(0,h.isValidElement)(e)||Array.isArray(e)||"string"==typeof e?e:String(e)}catch(e){return c(a,ed.FORMATTING_ERROR,e.message)}}function p(e,t,r){let n=f(e,t,r);return"string"!=typeof n?c(e,ed.INVALID_MESSAGE,void 0):n}return p.rich=f,p.markup=(e,t,r)=>f(e,t,r),p.raw=e=>{if(u)return n({error:o,key:e,namespace:s});try{return eT(i,o,e,s)}catch(t){return c(e,ed.MISSING_MESSAGE,t.message)}},p.has=e=>{if(u)return!1;try{return eT(i,o,e,s),!0}catch{return!1}},p}({...e,messagesOrError:t})})({cache:n,formatters:o,getMessageFallback:s,messages:c,namespace:f,onError:l,formats:i,locale:a,timeZone:u}),[n,o,s,c,f,l,i,a,u])}({"!":eI().messages},e?`!.${e}`:"!","!")}function eP(){let{formats:e,formatters:t,locale:r,now:n,onError:i,timeZone:o}=eI();return(0,h.useMemo)(()=>(function(e){let{_cache:t=ey(),_formatters:r=e_(t),formats:n,locale:i,onError:o=eb,timeZone:s}=e;function a(e){return e?.timeZone||(s?e={...e,timeZone:s}:o(new em(ed.ENVIRONMENT_FALLBACK,void 0))),e}function l(e,t,r,n,i){let s;try{s=function(e,t,r){let n;if("string"==typeof t){if(!(n=e?.[t])){let e=new em(ed.MISSING_FORMAT,void 0);throw o(e),e}}else n=t;return r&&(n={...n,...r}),n}(r,e,t)}catch{return i()}try{return n(s)}catch(e){return o(new em(ed.FORMATTING_ERROR,e.message)),i()}}function u(e,t,o){return l(t,o,n?.dateTime,t=>(t=a(t),r.getDateTimeFormat(i,t).format(e)),()=>String(e))}function h(){return e.now?e.now:(o(new em(ed.ENVIRONMENT_FALLBACK,void 0)),new Date)}return{dateTime:u,number:function(e,t,o){return l(t,o,n?.number,t=>r.getNumberFormat(i,t).format(e),()=>String(e))},relativeTime:function(e,t){try{var n;let o,s,a={};t instanceof Date||"number"==typeof t?o=new Date(t):t&&(o=null!=t.now?new Date(t.now):h(),s=t.unit,a.style=t.style,a.numberingSystem=t.numberingSystem),o||(o=h());let l=(new Date(e).getTime()-o.getTime())/1e3;s||(s=function(e){let t=Math.abs(e);return t{let t=r.getListFormat(i,e).formatToParts(s).map(e=>"literal"===e.type?e.value:a.get(e.value)||e.value);return a.size>0?t:t.join("")},()=>String(e))},dateTimeRange:function(e,t,o,s){return l(o,s,n?.dateTime,n=>(n=a(n),r.getDateTimeFormat(i,n).formatRange(e,t)),()=>[u(e),u(t)].join(" – "))}}})({formats:e,locale:r,now:n,onError:i,timeZone:o,_formatters:t}),[e,t,n,r,i,o])}},90523:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{cancelIdleCallback:function(){return n},requestIdleCallback:function(){return r}});let r="undefined"!=typeof self&&self.requestIdleCallback&&self.requestIdleCallback.bind(window)||function(e){let t=Date.now();return self.setTimeout(function(){e({didTimeout:!1,timeRemaining:function(){return Math.max(0,50-(Date.now()-t))}})},1)},n="undefined"!=typeof self&&self.cancelIdleCallback&&self.cancelIdleCallback.bind(window)||function(e){return clearTimeout(e)};("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},98540:(e,t,r)=>{"use strict";let n,i;r.d(t,{eU:()=>a,y$:()=>h,zp:()=>c});var o=r(28779);let s=0;function a(e,t){let r=`atom${++s}`,n={toString(){return this.debugLabel?r+":"+this.debugLabel:r}};return"function"==typeof e?n.read=e:(n.init=e,n.read=l,n.write=u),t&&(n.write=t),n}function l(e){return e(this)}function u(e,t,r){return t(this,"function"==typeof r?r(e(this)):r)}function h(){return n?n():(0,o._w)()}function c(){return i||(i=h(),globalThis.__JOTAI_DEFAULT_STORE__||(globalThis.__JOTAI_DEFAULT_STORE__=i),globalThis.__JOTAI_DEFAULT_STORE__!==i&&console.warn("Detected multiple Jotai instances. It may cause unexpected behavior with the default store. https://github.com/pmndrs/jotai/discussions/2044")),i}}}]);