(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[960],{6463:function(e,t,a){"use strict";var n=a(1169);a.o(n,"useParams")&&a.d(t,{useParams:function(){return n.useParams}}),a.o(n,"usePathname")&&a.d(t,{usePathname:function(){return n.usePathname}}),a.o(n,"useRouter")&&a.d(t,{useRouter:function(){return n.useRouter}}),a.o(n,"useSearchParams")&&a.d(t,{useSearchParams:function(){return n.useSearchParams}})},357:function(e,t,a){"use strict";var n,r;e.exports=(null==(n=a.g.process)?void 0:n.env)&&"object"==typeof(null==(r=a.g.process)?void 0:r.env)?a.g.process:a(8081)},8081:function(e){!function(){var t={229:function(e){var t,a,n,r=e.exports={};function o(){throw Error("setTimeout has not been defined")}function i(){throw Error("clearTimeout has not been defined")}function s(e){if(t===setTimeout)return setTimeout(e,0);if((t===o||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(a){try{return t.call(null,e,0)}catch(a){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:o}catch(e){t=o}try{a="function"==typeof clearTimeout?clearTimeout:i}catch(e){a=i}}();var l=[],c=!1,d=-1;function u(){c&&n&&(c=!1,n.length?l=n.concat(l):d=-1,l.length&&m())}function m(){if(!c){var e=s(u);c=!0;for(var t=l.length;t;){for(n=l,l=[];++d1)for(var a=1;a1?a-1:0),r=1;r2&&void 0!==arguments[2]?arguments[2]:b;s&&s(e,null);let n=t.length;for(;n--;){let r=t[n];if("string"==typeof r){let e=a(r);e!==r&&(l(t)||(t[n]=e),r=e)}e[r]=!0}return e}function C(e){let t=f(null);for(let[a,n]of i(e))A(e,a)&&(Array.isArray(n)?t[a]=function(e){for(let t=0;t/gm),G=m(/\${[\w\W]*}/gm),X=m(/^data-[\-\w.\u00B7-\uFFFF]/),V=m(/^aria-[\-\w]+$/),q=m(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),K=m(/^(?:\w+script|data):/i),$=m(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Z=m(/^html$/i),J=Object.freeze({__proto__:null,MUSTACHE_EXPR:j,ERB_EXPR:W,TMPLIT_EXPR:G,DATA_ATTR:X,ARIA_ATTR:V,IS_ALLOWED_URI:q,IS_SCRIPT_OR_DATA:K,ATTR_WHITESPACE:$,DOCTYPE_NAME:Z,CUSTOM_ELEMENT:m(/^[a-z][a-z\d]*(-[a-z\d]+)+$/i)}),Q=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;let a=null,n="data-tt-policy-suffix";t&&t.hasAttribute(n)&&(a=t.getAttribute(n));let r="dompurify"+(a?"#"+a:"");try{return e.createPolicy(r,{createHTML:e=>e,createScriptURL:e=>e})}catch(e){return console.warn("TrustedTypes policy "+r+" could not be created."),null}},ee=function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"undefined"==typeof window?null:window,a=t=>e(t);if(a.version="3.0.10",a.removed=[],!t||!t.document||9!==t.document.nodeType)return a.isSupported=!1,a;let{document:n}=t,r=n,o=r.currentScript,{DocumentFragment:s,HTMLTemplateElement:l,Node:c,Element:d,NodeFilter:m,NamedNodeMap:p=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:h,DOMParser:_,trustedTypes:j}=t,W=d.prototype,G=L(W,"cloneNode"),X=L(W,"nextSibling"),V=L(W,"childNodes"),K=L(W,"parentNode");if("function"==typeof l){let e=n.createElement("template");e.content&&e.content.ownerDocument&&(n=e.content.ownerDocument)}let $,ee="",{implementation:et,createNodeIterator:ea,createDocumentFragment:en,getElementsByTagName:er}=n,{importNode:eo}=r,ei={};a.isSupported="function"==typeof i&&"function"==typeof K&&et&&void 0!==et.createHTMLDocument;let{MUSTACHE_EXPR:es,ERB_EXPR:el,TMPLIT_EXPR:ec,DATA_ATTR:ed,ARIA_ATTR:eu,IS_SCRIPT_OR_DATA:em,ATTR_WHITESPACE:ef,CUSTOM_ELEMENT:ep}=J,{IS_ALLOWED_URI:eh}=J,eg=null,ey=R({},[...M,...D,...I,...P,...U]),ev=null,eb=R({},[...B,...H,...F,...Y]),ew=Object.seal(f(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),ex=null,eT=null,eE=!0,eN=!0,eA=!1,eS=!0,ek=!1,e_=!1,eR=!1,eC=!1,eL=!1,eM=!1,eD=!1,eI=!0,eO=!1,eP=!0,ez=!1,eU={},eB=null,eH=R({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),eF=null,eY=R({},["audio","video","img","source","image","track"]),ej=null,eW=R({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),eG="http://www.w3.org/1998/Math/MathML",eX="http://www.w3.org/2000/svg",eV="http://www.w3.org/1999/xhtml",eq=eV,eK=!1,e$=null,eZ=R({},[eG,eX,eV],w),eJ=null,eQ=["application/xhtml+xml","text/html"],e0=null,e1=null,e2=n.createElement("form"),e5=function(e){return e instanceof RegExp||e instanceof Function},e4=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!(e1&&e1===e)){if(e&&"object"==typeof e||(e={}),e=C(e),e0="application/xhtml+xml"===(eJ=-1===eQ.indexOf(e.PARSER_MEDIA_TYPE)?"text/html":e.PARSER_MEDIA_TYPE)?w:b,eg=A(e,"ALLOWED_TAGS")?R({},e.ALLOWED_TAGS,e0):ey,ev=A(e,"ALLOWED_ATTR")?R({},e.ALLOWED_ATTR,e0):eb,e$=A(e,"ALLOWED_NAMESPACES")?R({},e.ALLOWED_NAMESPACES,w):eZ,ej=A(e,"ADD_URI_SAFE_ATTR")?R(C(eW),e.ADD_URI_SAFE_ATTR,e0):eW,eF=A(e,"ADD_DATA_URI_TAGS")?R(C(eY),e.ADD_DATA_URI_TAGS,e0):eY,eB=A(e,"FORBID_CONTENTS")?R({},e.FORBID_CONTENTS,e0):eH,ex=A(e,"FORBID_TAGS")?R({},e.FORBID_TAGS,e0):{},eT=A(e,"FORBID_ATTR")?R({},e.FORBID_ATTR,e0):{},eU=!!A(e,"USE_PROFILES")&&e.USE_PROFILES,eE=!1!==e.ALLOW_ARIA_ATTR,eN=!1!==e.ALLOW_DATA_ATTR,eA=e.ALLOW_UNKNOWN_PROTOCOLS||!1,eS=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,ek=e.SAFE_FOR_TEMPLATES||!1,e_=e.WHOLE_DOCUMENT||!1,eL=e.RETURN_DOM||!1,eM=e.RETURN_DOM_FRAGMENT||!1,eD=e.RETURN_TRUSTED_TYPE||!1,eC=e.FORCE_BODY||!1,eI=!1!==e.SANITIZE_DOM,eO=e.SANITIZE_NAMED_PROPS||!1,eP=!1!==e.KEEP_CONTENT,ez=e.IN_PLACE||!1,eh=e.ALLOWED_URI_REGEXP||q,eq=e.NAMESPACE||eV,ew=e.CUSTOM_ELEMENT_HANDLING||{},e.CUSTOM_ELEMENT_HANDLING&&e5(e.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(ew.tagNameCheck=e.CUSTOM_ELEMENT_HANDLING.tagNameCheck),e.CUSTOM_ELEMENT_HANDLING&&e5(e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(ew.attributeNameCheck=e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),e.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(ew.allowCustomizedBuiltInElements=e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),ek&&(eN=!1),eM&&(eL=!0),eU&&(eg=R({},U),ev=[],!0===eU.html&&(R(eg,M),R(ev,B)),!0===eU.svg&&(R(eg,D),R(ev,H),R(ev,Y)),!0===eU.svgFilters&&(R(eg,I),R(ev,H),R(ev,Y)),!0===eU.mathMl&&(R(eg,P),R(ev,F),R(ev,Y))),e.ADD_TAGS&&(eg===ey&&(eg=C(eg)),R(eg,e.ADD_TAGS,e0)),e.ADD_ATTR&&(ev===eb&&(ev=C(ev)),R(ev,e.ADD_ATTR,e0)),e.ADD_URI_SAFE_ATTR&&R(ej,e.ADD_URI_SAFE_ATTR,e0),e.FORBID_CONTENTS&&(eB===eH&&(eB=C(eB)),R(eB,e.FORBID_CONTENTS,e0)),eP&&(eg["#text"]=!0),e_&&R(eg,["html","head","body"]),eg.table&&(R(eg,["tbody"]),delete ex.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw k('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw k('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');ee=($=e.TRUSTED_TYPES_POLICY).createHTML("")}else void 0===$&&($=Q(j,o)),null!==$&&"string"==typeof ee&&(ee=$.createHTML(""));u&&u(e),e1=e}},e9=R({},["mi","mo","mn","ms","mtext"]),e3=R({},["foreignobject","desc","title","annotation-xml"]),e8=R({},["title","style","font","a","script"]),e7=R({},[...D,...I,...O]),e6=R({},[...P,...z]),te=function(e){let t=K(e);t&&t.tagName||(t={namespaceURI:eq,tagName:"template"});let a=b(e.tagName),n=b(t.tagName);return!!e$[e.namespaceURI]&&(e.namespaceURI===eX?t.namespaceURI===eV?"svg"===a:t.namespaceURI===eG?"svg"===a&&("annotation-xml"===n||e9[n]):!!e7[a]:e.namespaceURI===eG?t.namespaceURI===eV?"math"===a:t.namespaceURI===eX?"math"===a&&e3[n]:!!e6[a]:e.namespaceURI===eV?(t.namespaceURI!==eX||!!e3[n])&&(t.namespaceURI!==eG||!!e9[n])&&!e6[a]&&(e8[a]||!e7[a]):!!("application/xhtml+xml"===eJ&&e$[e.namespaceURI]))},tt=function(e){v(a.removed,{element:e});try{e.parentNode.removeChild(e)}catch(t){e.remove()}},ta=function(e,t){try{v(a.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){v(a.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e&&!ev[e]){if(eL||eM)try{tt(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}}},tn=function(e){let t=null,a=null;if(eC)e=""+e;else{let t=x(e,/^[\r\n\t ]+/);a=t&&t[0]}"application/xhtml+xml"===eJ&&eq===eV&&(e=''+e+"");let r=$?$.createHTML(e):e;if(eq===eV)try{t=new _().parseFromString(r,eJ)}catch(e){}if(!t||!t.documentElement){t=et.createDocument(eq,"template",null);try{t.documentElement.innerHTML=eK?ee:r}catch(e){}}let o=t.body||t.documentElement;return e&&a&&o.insertBefore(n.createTextNode(a),o.childNodes[0]||null),eq===eV?er.call(t,e_?"html":"body")[0]:e_?t.documentElement:o},tr=function(e){return ea.call(e.ownerDocument||e,e,m.SHOW_ELEMENT|m.SHOW_COMMENT|m.SHOW_TEXT|m.SHOW_PROCESSING_INSTRUCTION,null)},to=function(e){return"function"==typeof c&&e instanceof c},ti=function(e,t,n){ei[e]&&g(ei[e],e=>{e.call(a,t,n,e1)})},ts=function(e){let t=null;if(ti("beforeSanitizeElements",e,null),e instanceof h&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||!(e.attributes instanceof p)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes))return tt(e),!0;let n=e0(e.nodeName);if(ti("uponSanitizeElement",e,{tagName:n,allowedTags:eg}),e.hasChildNodes()&&!to(e.firstElementChild)&&S(/<[/\w]/g,e.innerHTML)&&S(/<[/\w]/g,e.textContent))return tt(e),!0;if(!eg[n]||ex[n]){if(!ex[n]&&tc(n)&&(ew.tagNameCheck instanceof RegExp&&S(ew.tagNameCheck,n)||ew.tagNameCheck instanceof Function&&ew.tagNameCheck(n)))return!1;if(eP&&!eB[n]){let t=K(e)||e.parentNode,a=V(e)||e.childNodes;if(a&&t){let n=a.length;for(let r=n-1;r>=0;--r)t.insertBefore(G(a[r],!0),X(e))}}return tt(e),!0}return e instanceof d&&!te(e)||("noscript"===n||"noembed"===n||"noframes"===n)&&S(/<\/no(script|embed|frames)/i,e.innerHTML)?(tt(e),!0):(ek&&3===e.nodeType&&(t=e.textContent,g([es,el,ec],e=>{t=T(t,e," ")}),e.textContent!==t&&(v(a.removed,{element:e.cloneNode()}),e.textContent=t)),ti("afterSanitizeElements",e,null),!1)},tl=function(e,t,a){if(eI&&("id"===t||"name"===t)&&(a in n||a in e2))return!1;if(!(eN&&!eT[t]&&S(ed,t))&&!(eE&&S(eu,t))){if(!ev[t]||eT[t]){if(!(tc(e)&&(ew.tagNameCheck instanceof RegExp&&S(ew.tagNameCheck,e)||ew.tagNameCheck instanceof Function&&ew.tagNameCheck(e))&&(ew.attributeNameCheck instanceof RegExp&&S(ew.attributeNameCheck,t)||ew.attributeNameCheck instanceof Function&&ew.attributeNameCheck(t))||"is"===t&&ew.allowCustomizedBuiltInElements&&(ew.tagNameCheck instanceof RegExp&&S(ew.tagNameCheck,a)||ew.tagNameCheck instanceof Function&&ew.tagNameCheck(a))))return!1}else if(!ej[t]&&!S(eh,T(a,ef,""))&&!(("src"===t||"xlink:href"===t||"href"===t)&&"script"!==e&&0===E(a,"data:")&&eF[e])&&!(eA&&!S(em,T(a,ef,"")))&&a)return!1}return!0},tc=function(e){return"annotation-xml"!==e&&x(e,ep)},td=function(e){ti("beforeSanitizeAttributes",e,null);let{attributes:t}=e;if(!t)return;let n={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:ev},r=t.length;for(;r--;){let{name:o,namespaceURI:i,value:s}=t[r],l=e0(o),c="value"===o?s:N(s);if(n.attrName=l,n.attrValue=c,n.keepAttr=!0,n.forceKeepAttr=void 0,ti("uponSanitizeAttribute",e,n),c=n.attrValue,n.forceKeepAttr||(ta(o,e),!n.keepAttr))continue;if(!eS&&S(/\/>/i,c)){ta(o,e);continue}ek&&g([es,el,ec],e=>{c=T(c,e," ")});let d=e0(e.nodeName);if(tl(d,l,c)){if(eO&&("id"===l||"name"===l)&&(ta(o,e),c="user-content-"+c),$&&"object"==typeof j&&"function"==typeof j.getAttributeType&&!i)switch(j.getAttributeType(d,l)){case"TrustedHTML":c=$.createHTML(c);break;case"TrustedScriptURL":c=$.createScriptURL(c)}try{i?e.setAttributeNS(i,o,c):e.setAttribute(o,c),y(a.removed)}catch(e){}}}ti("afterSanitizeAttributes",e,null)},tu=function e(t){let a=null,n=tr(t);for(ti("beforeSanitizeShadowDOM",t,null);a=n.nextNode();)ti("uponSanitizeShadowNode",a,null),ts(a)||(a.content instanceof s&&e(a.content),td(a));ti("afterSanitizeShadowDOM",t,null)};return a.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=null,o=null,i=null,l=null;if((eK=!e)&&(e=""),"string"!=typeof e&&!to(e)){if("function"==typeof e.toString){if("string"!=typeof(e=e.toString()))throw k("dirty is not a string, aborting")}else throw k("toString is not a function")}if(!a.isSupported)return e;if(eR||e4(t),a.removed=[],"string"==typeof e&&(ez=!1),ez){if(e.nodeName){let t=e0(e.nodeName);if(!eg[t]||ex[t])throw k("root node is forbidden and cannot be sanitized in-place")}}else if(e instanceof c)1===(o=(n=tn("")).ownerDocument.importNode(e,!0)).nodeType&&"BODY"===o.nodeName||"HTML"===o.nodeName?n=o:n.appendChild(o);else{if(!eL&&!ek&&!e_&&-1===e.indexOf("<"))return $&&eD?$.createHTML(e):e;if(!(n=tn(e)))return eL?null:eD?ee:""}n&&eC&&tt(n.firstChild);let d=tr(ez?e:n);for(;i=d.nextNode();)ts(i)||(i.content instanceof s&&tu(i.content),td(i));if(ez)return e;if(eL){if(eM)for(l=en.call(n.ownerDocument);n.firstChild;)l.appendChild(n.firstChild);else l=n;return(ev.shadowroot||ev.shadowrootmode)&&(l=eo.call(r,l,!0)),l}let u=e_?n.outerHTML:n.innerHTML;return e_&&eg["!doctype"]&&n.ownerDocument&&n.ownerDocument.doctype&&n.ownerDocument.doctype.name&&S(Z,n.ownerDocument.doctype.name)&&(u="\n"+u),ek&&g([es,el,ec],e=>{u=T(u,e," ")}),$&&eD?$.createHTML(u):u},a.setConfig=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e4(e),eR=!0},a.clearConfig=function(){e1=null,eR=!1},a.isValidAttribute=function(e,t,a){return e1||e4({}),tl(e0(e),e0(t),a)},a.addHook=function(e,t){"function"==typeof t&&(ei[e]=ei[e]||[],v(ei[e],t))},a.removeHook=function(e){if(ei[e])return y(ei[e])},a.removeHooks=function(e){ei[e]&&(ei[e]=[])},a.removeAllHooks=function(){ei={}},a}(),et=e=>{switch(e){case"success":return er;case"info":return ei;case"warning":return eo;case"error":return es;default:return null}},ea=Array(12).fill(0),en=e=>{let{visible:t}=e;return r.createElement("div",{className:"sonner-loading-wrapper","data-visible":t},r.createElement("div",{className:"sonner-spinner"},ea.map((e,t)=>r.createElement("div",{className:"sonner-loading-bar",key:"spinner-bar-".concat(t)}))))},er=r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},r.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),eo=r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},r.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),ei=r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},r.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),es=r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},r.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),el=()=>{let[e,t]=r.useState(!1);return r.useEffect(()=>{let e=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",e),()=>window.removeEventListener("visibilitychange",e)},[]),e},ec=1,ed=new class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:a,...n}=e,r="number"==typeof(null==e?void 0:e.id)||(null==(t=e.id)?void 0:t.length)>0?e.id:ec++,o=this.toasts.find(e=>e.id===r),i=void 0===e.dismissible||e.dismissible;return o?this.toasts=this.toasts.map(t=>t.id===r?(this.publish({...t,...e,id:r,title:a}),{...t,...e,id:r,dismissible:i,title:a}):t):this.addToast({title:a,...n,dismissible:i,id:r}),r},this.dismiss=e=>(e||this.toasts.forEach(e=>{this.subscribers.forEach(t=>t({id:e.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{let a;if(!t)return;void 0!==t.loading&&(a=this.create({...t,promise:e,type:"loading",message:t.loading,description:"function"!=typeof t.description?t.description:void 0}));let n=e instanceof Promise?e:e(),r=void 0!==a;return n.then(e=>{if(e&&"boolean"==typeof e.ok&&!e.ok){r=!1;let n="function"==typeof t.error?t.error("HTTP error! status: ".concat(e.status)):t.error,o="function"==typeof t.description?t.description("HTTP error! status: ".concat(e.status)):t.description;this.create({id:a,type:"error",message:n,description:o})}else if(void 0!==t.success){r=!1;let n="function"==typeof t.success?t.success(e):t.success,o="function"==typeof t.description?t.description(e):t.description;this.create({id:a,type:"success",message:n,description:o})}}).catch(e=>{if(void 0!==t.error){r=!1;let n="function"==typeof t.error?t.error(e):t.error,o="function"==typeof t.description?t.description(e):t.description;this.create({id:a,type:"error",message:n,description:o})}}).finally(()=>{var e;r&&(this.dismiss(a),a=void 0),null==(e=t.finally)||e.call(t)}),a},this.custom=(e,t)=>{let a=(null==t?void 0:t.id)||ec++;return this.create({jsx:e(a),id:a,...t}),a},this.subscribers=[],this.toasts=[]}},eu=Object.assign((e,t)=>{let a=(null==t?void 0:t.id)||ec++;return ed.addToast({title:e,...t,id:a}),a},{success:ed.success,info:ed.info,warning:ed.warning,error:ed.error,custom:ed.custom,message:ed.message,promise:ed.promise,dismiss:ed.dismiss,loading:ed.loading});function em(e){return void 0!==e.label&&"function"==typeof e.onClick}function ef(){for(var e=arguments.length,t=Array(e),a=0;a1&&void 0!==arguments[1]?arguments[1]:{};if(!e||"undefined"==typeof document)return;let a=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css","top"===t&&a.firstChild?a.insertBefore(n,a.firstChild):a.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}(':where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);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;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999}:where([data-sonner-toaster][data-x-position="right"]){right:max(var(--offset),env(safe-area-inset-right))}:where([data-sonner-toaster][data-x-position="left"]){left:max(var(--offset),env(safe-area-inset-left))}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:max(var(--offset),env(safe-area-inset-top))}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:max(var(--offset),env(safe-area-inset-bottom))}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;background:var(--gray1);color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:0;right:0;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount, 0px));transition:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation:swipe-out .2s ease-out forwards}@keyframes swipe-out{0%{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount)));opacity:1}to{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount) + var(--lift) * -100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;--mobile-offset: 16px;right:var(--mobile-offset);left:var(--mobile-offset);width:100%}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset)}[data-sonner-toaster][data-y-position=bottom]{bottom:20px}[data-sonner-toaster][data-y-position=top]{top:20px}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset);right:var(--mobile-offset);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);--error-text: hsl(358, 100%, 81%)}[data-rich-colors=true] [data-sonner-toast][data-type=success],[data-rich-colors=true] [data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true] [data-sonner-toast][data-type=info],[data-rich-colors=true] [data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true] [data-sonner-toast][data-type=warning],[data-rich-colors=true] [data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true] [data-sonner-toast][data-type=error],[data-rich-colors=true] [data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}\n');var ep=e=>{var t,a,n,o,i,s,l;let{invert:c,toast:d,unstyled:u,interacting:m,setHeights:f,visibleToasts:p,heights:h,index:g,toasts:y,expanded:v,removeToast:b,closeButton:w,style:x,cancelButtonStyle:T,actionButtonStyle:E,className:N="",descriptionClassName:A="",duration:S,position:k,gap:_,loadingIcon:R,expandByDefault:C,classNames:L,icons:M,closeButtonAriaLabel:D="Close toast",pauseWhenPageIsHidden:I,cn:O}=e,[P,z]=r.useState(!1),[U,B]=r.useState(!1),[H,F]=r.useState(!1),[Y,j]=r.useState(!1),[W,G]=r.useState(0),[X,V]=r.useState(0),q=r.useRef(null),K=r.useRef(null),$=0===g,Z=g+1<=p,J=d.type,Q=!1!==d.dismissible,ea=d.className||"",er=d.descriptionClassName||"",eo=r.useMemo(()=>h.findIndex(e=>e.toastId===d.id)||0,[h,d.id]),ei=r.useMemo(()=>{var e;return null!=(e=d.closeButton)?e:w},[d.closeButton,w]),es=r.useMemo(()=>d.duration||S||4e3,[d.duration,S]),ec=r.useRef(0),ed=r.useRef(0),eu=r.useRef(0),ef=r.useRef(null),[ep,eh]=k.split("-"),eg=r.useMemo(()=>h.reduce((e,t,a)=>a>=eo?e:e+t.height,0),[h,eo]),ey=el(),ev=d.invert||c,eb="loading"===J;ed.current=r.useMemo(()=>eo*_+eg,[eo,eg]),r.useEffect(()=>{z(!0)},[]),r.useLayoutEffect(()=>{if(!P)return;let e=K.current,t=e.style.height;e.style.height="auto";let a=e.getBoundingClientRect().height;e.style.height=t,V(a),f(e=>e.find(e=>e.toastId===d.id)?e.map(e=>e.toastId===d.id?{...e,height:a}:e):[{toastId:d.id,height:a,position:d.position},...e])},[P,d.title,d.description,f,d.id]);let ew=r.useCallback(()=>{B(!0),G(ed.current),f(e=>e.filter(e=>e.toastId!==d.id)),setTimeout(()=>{b(d)},200)},[d,b,f,ed]);function ex(e){return{__html:ee.sanitize(e)}}return r.useEffect(()=>{if(d.promise&&"loading"===J||d.duration===1/0||"loading"===d.type)return;let e,t=es;return v||m||I&&ey?(()=>{if(eu.current{var e;null==(e=d.onAutoClose)||e.call(d,d),ew()},t)),()=>clearTimeout(e)},[v,m,C,d,es,ew,d.promise,J,I,ey]),r.useEffect(()=>{let e=K.current;if(e){let t=e.getBoundingClientRect().height;return V(t),f(e=>[{toastId:d.id,height:t,position:d.position},...e]),()=>f(e=>e.filter(e=>e.toastId!==d.id))}},[f,d.id]),r.useEffect(()=>{d.delete&&ew()},[ew,d.delete]),r.createElement("li",{"aria-live":d.important?"assertive":"polite","aria-atomic":"true",role:"status",tabIndex:0,ref:K,className:O(N,ea,null==L?void 0:L.toast,null==(t=null==d?void 0:d.classNames)?void 0:t.toast,null==L?void 0:L.default,null==L?void 0:L[J],null==(a=null==d?void 0:d.classNames)?void 0:a[J]),"data-sonner-toast":"","data-styled":!(d.jsx||d.unstyled||u),"data-mounted":P,"data-promise":!!d.promise,"data-removed":U,"data-visible":Z,"data-y-position":ep,"data-x-position":eh,"data-index":g,"data-front":$,"data-swiping":H,"data-dismissible":Q,"data-type":J,"data-invert":ev,"data-swipe-out":Y,"data-expanded":!!(v||C&&P),style:{"--index":g,"--toasts-before":g,"--z-index":y.length-g,"--offset":"".concat(U?W:ed.current,"px"),"--initial-height":C?"auto":"".concat(X,"px"),...x,...d.style},onPointerDown:e=>{eb||!Q||(q.current=new Date,G(ed.current),e.target.setPointerCapture(e.pointerId),"BUTTON"!==e.target.tagName&&(F(!0),ef.current={x:e.clientX,y:e.clientY}))},onPointerUp:()=>{var e,t,a,n;if(Y||!Q)return;ef.current=null;let r=Number((null==(e=K.current)?void 0:e.style.getPropertyValue("--swipe-amount").replace("px",""))||0),o=new Date().getTime()-(null==(t=q.current)?void 0:t.getTime());if(Math.abs(r)>=20||Math.abs(r)/o>.11){G(ed.current),null==(a=d.onDismiss)||a.call(d,d),ew(),j(!0);return}null==(n=K.current)||n.style.setProperty("--swipe-amount","0px"),F(!1)},onPointerMove:e=>{var t;if(!ef.current||!Q)return;let a=e.clientY-ef.current.y,n=e.clientX-ef.current.x,r=("top"===ep?Math.min:Math.max)(0,a),o="touch"===e.pointerType?10:2;Math.abs(r)>o?null==(t=K.current)||t.style.setProperty("--swipe-amount","".concat(a,"px")):Math.abs(n)>o&&(ef.current=null)}},ei&&!d.jsx?r.createElement("button",{"aria-label":D,"data-disabled":eb,"data-close-button":!0,onClick:eb||!Q?()=>{}:()=>{var e;ew(),null==(e=d.onDismiss)||e.call(d,d)},className:O(null==L?void 0:L.closeButton,null==(n=null==d?void 0:d.classNames)?void 0:n.closeButton)},r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},r.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),r.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"}))):null,d.jsx||r.isValidElement(d.title)?d.jsx||d.title:r.createElement(r.Fragment,null,J||d.icon||d.promise?r.createElement("div",{"data-icon":"",className:O(null==L?void 0:L.icon)},d.promise||"loading"===d.type&&!d.icon?d.icon||(null!=M&&M.loading?r.createElement("div",{className:"sonner-loader","data-visible":"loading"===J},M.loading):R?r.createElement("div",{className:"sonner-loader","data-visible":"loading"===J},R):r.createElement(en,{visible:"loading"===J})):null,"loading"!==d.type?d.icon||(null==M?void 0:M[J])||et(J):null):null,r.createElement("div",{"data-content":"",className:O(null==L?void 0:L.content)},r.createElement("div",{"data-title":"",className:O(null==L?void 0:L.title,null==(o=null==d?void 0:d.classNames)?void 0:o.title),dangerouslySetInnerHTML:ex(d.title)}),d.description?r.createElement("div",{"data-description":"",className:O(A,er,null==L?void 0:L.description,null==(i=null==d?void 0:d.classNames)?void 0:i.description),dangerouslySetInnerHTML:ex(d.description)}):null),r.isValidElement(d.cancel)?d.cancel:d.cancel&&em(d.cancel)?r.createElement("button",{"data-button":!0,"data-cancel":!0,style:d.cancelButtonStyle||T,onClick:e=>{em(d.cancel)&&Q&&(ew(),d.cancel.onClick(e))},className:O(null==L?void 0:L.cancelButton,null==(s=null==d?void 0:d.classNames)?void 0:s.cancelButton)},d.cancel.label):null,r.isValidElement(d.action)?d.action:d.action&&em(d.action)?r.createElement("button",{"data-button":"",style:d.actionButtonStyle||E,onClick:e=>{em(d.action)&&(d.action.onClick(e),e.defaultPrevented||ew())},className:O(null==L?void 0:L.actionButton,null==(l=null==d?void 0:d.classNames)?void 0:l.actionButton)},d.action.label):null))};function eh(){if("undefined"==typeof window||"undefined"==typeof document)return"ltr";let e=document.documentElement.getAttribute("dir");return"auto"!==e&&e?e:window.getComputedStyle(document.documentElement).direction}var eg=e=>{let{invert:t,position:a="bottom-right",hotkey:n=["altKey","KeyT"],expand:i,closeButton:s,className:l,offset:c,theme:d="light",richColors:u,duration:m,style:f,visibleToasts:p=3,toastOptions:h,dir:g=eh(),gap:y=14,loadingIcon:v,icons:b,containerAriaLabel:w="Notifications",pauseWhenPageIsHidden:x,cn:T=ef}=e,[E,N]=r.useState([]),A=r.useMemo(()=>Array.from(new Set([a].concat(E.filter(e=>e.position).map(e=>e.position)))),[E,a]),[S,k]=r.useState([]),[_,R]=r.useState(!1),[C,L]=r.useState(!1),[M,D]=r.useState("system"!==d?d:"undefined"!=typeof window&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),I=r.useRef(null),O=n.join("+").replace(/Key/g,"").replace(/Digit/g,""),P=r.useRef(null),z=r.useRef(!1),U=r.useCallback(e=>N(t=>t.filter(t=>{let{id:a}=t;return a!==e.id})),[]);return r.useEffect(()=>ed.subscribe(e=>{if(e.dismiss){N(t=>t.map(t=>t.id===e.id?{...t,delete:!0}:t));return}setTimeout(()=>{o.flushSync(()=>{N(t=>{let a=t.findIndex(t=>t.id===e.id);return -1!==a?[...t.slice(0,a),{...t[a],...e},...t.slice(a+1)]:[e,...t]})})})}),[]),r.useEffect(()=>{if("system"!==d){D(d);return}"system"===d&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?D("dark"):D("light")),"undefined"!=typeof window&&window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change",e=>{let{matches:t}=e;D(t?"dark":"light")})},[d]),r.useEffect(()=>{E.length<=1&&R(!1)},[E]),r.useEffect(()=>{let e=e=>{var t,a;n.every(t=>e[t]||e.code===t)&&(R(!0),null==(t=I.current)||t.focus()),"Escape"===e.code&&(document.activeElement===I.current||null!=(a=I.current)&&a.contains(document.activeElement))&&R(!1)};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[n]),r.useEffect(()=>{if(I.current)return()=>{P.current&&(P.current.focus({preventScroll:!0}),P.current=null,z.current=!1)}},[I.current]),E.length?r.createElement("section",{"aria-label":"".concat(w," ").concat(O),tabIndex:-1},A.map((e,a)=>{var n;let[o,d]=e.split("-");return r.createElement("ol",{key:e,dir:"auto"===g?eh():g,tabIndex:-1,ref:I,className:l,"data-sonner-toaster":!0,"data-theme":M,"data-rich-colors":u,"data-y-position":o,"data-x-position":d,style:{"--front-toast-height":"".concat((null==(n=S[0])?void 0:n.height)||0,"px"),"--offset":"number"==typeof c?"".concat(c,"px"):c||"32px","--width":"".concat(356,"px"),"--gap":"".concat(y,"px"),...f},onBlur:e=>{z.current&&!e.currentTarget.contains(e.relatedTarget)&&(z.current=!1,P.current&&(P.current.focus({preventScroll:!0}),P.current=null))},onFocus:e=>{e.target instanceof HTMLElement&&"false"===e.target.dataset.dismissible||z.current||(z.current=!0,P.current=e.relatedTarget)},onMouseEnter:()=>R(!0),onMouseMove:()=>R(!0),onMouseLeave:()=>{C||R(!1)},onPointerDown:e=>{e.target instanceof HTMLElement&&"false"===e.target.dataset.dismissible||L(!0)},onPointerUp:()=>L(!1)},E.filter(t=>!t.position&&0===a||t.position===e).map((a,n)=>{var o,l;return r.createElement(ep,{key:a.id,icons:b,index:n,toast:a,duration:null!=(o=null==h?void 0:h.duration)?o:m,className:null==h?void 0:h.className,descriptionClassName:null==h?void 0:h.descriptionClassName,invert:t,visibleToasts:p,closeButton:null!=(l=null==h?void 0:h.closeButton)?l:s,interacting:C,position:e,style:null==h?void 0:h.style,unstyled:null==h?void 0:h.unstyled,classNames:null==h?void 0:h.classNames,cancelButtonStyle:null==h?void 0:h.cancelButtonStyle,actionButtonStyle:null==h?void 0:h.actionButtonStyle,removeToast:U,toasts:E.filter(e=>e.position==a.position),heights:S.filter(e=>e.position==a.position),setHeights:k,expandByDefault:i,gap:y,loadingIcon:v,expanded:_,pauseWhenPageIsHidden:x,cn:T})}))})):null};/*! Bundled license information: dompurify/dist/purify.es.mjs: (*! @license DOMPurify 3.0.10 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.10/LICENSE *) */}}]);