@debales/ai 1.1.40 β†’ 1.1.41

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.
@@ -70,7 +70,7 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
70
70
  *
71
71
  * This source code is licensed under the MIT license found in the
72
72
  * LICENSE file in the root directory of this source tree.
73
- */var I5;function CV(){if(I5)return s1;I5=1;var e=R5(),t=kg(),n=v3();function r(u){var f="https://react.dev/errors/"+u;if(1<arguments.length){f+="?args[]="+encodeURIComponent(arguments[1]);for(var g=2;g<arguments.length;g++)f+="&args[]="+encodeURIComponent(arguments[g])}return"Minified React error #"+u+"; visit "+f+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(u){return!(!u||u.nodeType!==1&&u.nodeType!==9&&u.nodeType!==11)}function a(u){var f=u,g=u;if(u.alternate)for(;f.return;)f=f.return;else{u=f;do f=u,(f.flags&4098)!==0&&(g=f.return),u=f.return;while(u)}return f.tag===3?g:null}function l(u){if(u.tag===13){var f=u.memoizedState;if(f===null&&(u=u.alternate,u!==null&&(f=u.memoizedState)),f!==null)return f.dehydrated}return null}function d(u){if(a(u)!==u)throw Error(r(188))}function h(u){var f=u.alternate;if(!f){if(f=a(u),f===null)throw Error(r(188));return f!==u?null:u}for(var g=u,b=f;;){var T=g.return;if(T===null)break;var D=T.alternate;if(D===null){if(b=T.return,b!==null){g=b;continue}break}if(T.child===D.child){for(D=T.child;D;){if(D===g)return d(T),u;if(D===b)return d(T),f;D=D.sibling}throw Error(r(188))}if(g.return!==b.return)g=T,b=D;else{for(var q=!1,K=T.child;K;){if(K===g){q=!0,g=T,b=D;break}if(K===b){q=!0,b=T,g=D;break}K=K.sibling}if(!q){for(K=D.child;K;){if(K===g){q=!0,g=D,b=T;break}if(K===b){q=!0,b=D,g=T;break}K=K.sibling}if(!q)throw Error(r(189))}}if(g.alternate!==b)throw Error(r(190))}if(g.tag!==3)throw Error(r(188));return g.stateNode.current===g?u:f}function p(u){var f=u.tag;if(f===5||f===26||f===27||f===6)return u;for(u=u.child;u!==null;){if(f=p(u),f!==null)return f;u=u.sibling}return null}var y=Object.assign,m=Symbol.for("react.element"),x=Symbol.for("react.transitional.element"),_=Symbol.for("react.portal"),w=Symbol.for("react.fragment"),k=Symbol.for("react.strict_mode"),A=Symbol.for("react.profiler"),E=Symbol.for("react.provider"),R=Symbol.for("react.consumer"),O=Symbol.for("react.context"),I=Symbol.for("react.forward_ref"),L=Symbol.for("react.suspense"),N=Symbol.for("react.suspense_list"),H=Symbol.for("react.memo"),V=Symbol.for("react.lazy"),W=Symbol.for("react.activity"),z=Symbol.for("react.memo_cache_sentinel"),Q=Symbol.iterator;function J(u){return u===null||typeof u!="object"?null:(u=Q&&u[Q]||u["@@iterator"],typeof u=="function"?u:null)}var ie=Symbol.for("react.client.reference");function ee(u){if(u==null)return null;if(typeof u=="function")return u.$$typeof===ie?null:u.displayName||u.name||null;if(typeof u=="string")return u;switch(u){case w:return"Fragment";case A:return"Profiler";case k:return"StrictMode";case L:return"Suspense";case N:return"SuspenseList";case W:return"Activity"}if(typeof u=="object")switch(u.$$typeof){case _:return"Portal";case O:return(u.displayName||"Context")+".Provider";case R:return(u._context.displayName||"Context")+".Consumer";case I:var f=u.render;return u=u.displayName,u||(u=f.displayName||f.name||"",u=u!==""?"ForwardRef("+u+")":"ForwardRef"),u;case H:return f=u.displayName||null,f!==null?f:ee(u.type)||"Memo";case V:f=u._payload,u=u._init;try{return ee(u(f))}catch{}}return null}var de=Array.isArray,ue=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,se=n.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,pe={pending:!1,data:null,method:null,action:null},Ce=[],B=-1;function P(u){return{current:u}}function ne(u){0>B||(u.current=Ce[B],Ce[B]=null,B--)}function U(u,f){B++,Ce[B]=u.current,u.current=f}var fe=P(null),Ae=P(null),Te=P(null),rt=P(null);function Ge(u,f){switch(U(Te,f),U(Ae,u),U(fe,null),f.nodeType){case 9:case 11:u=(u=f.documentElement)&&(u=u.namespaceURI)?Al(u):0;break;default:if(u=f.tagName,f=f.namespaceURI)f=Al(f),u=Tu(f,u);else switch(u){case"svg":u=1;break;case"math":u=2;break;default:u=0}}ne(fe),U(fe,u)}function We(){ne(fe),ne(Ae),ne(Te)}function Tt(u){u.memoizedState!==null&&U(rt,u);var f=fe.current,g=Tu(f,u.type);f!==g&&(U(Ae,u),U(fe,g))}function It(u){Ae.current===u&&(ne(fe),ne(Ae)),rt.current===u&&(ne(rt),_o._currentValue=pe)}var nt=Object.prototype.hasOwnProperty,dt=e.unstable_scheduleCallback,bt=e.unstable_cancelCallback,Et=e.unstable_shouldYield,Nt=e.unstable_requestPaint,yt=e.unstable_now,re=e.unstable_getCurrentPriorityLevel,le=e.unstable_ImmediatePriority,ve=e.unstable_UserBlockingPriority,Ee=e.unstable_NormalPriority,$e=e.unstable_LowPriority,Ve=e.unstable_IdlePriority,lt=e.log,mt=e.unstable_setDisableYieldValue,_e=null,Re=null;function Ct(u){if(typeof lt=="function"&&mt(u),Re&&typeof Re.setStrictMode=="function")try{Re.setStrictMode(_e,u)}catch{}}var ct=Math.clz32?Math.clz32:en,Rt=Math.log,Mt=Math.LN2;function en(u){return u>>>=0,u===0?32:31-(Rt(u)/Mt|0)|0}var Qt=256,gn=4194304;function pt(u){var f=u&42;if(f!==0)return f;switch(u&-u){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return u&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return u&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return u}}function Kt(u,f,g){var b=u.pendingLanes;if(b===0)return 0;var T=0,D=u.suspendedLanes,q=u.pingedLanes;u=u.warmLanes;var K=b&134217727;return K!==0?(b=K&~D,b!==0?T=pt(b):(q&=K,q!==0?T=pt(q):g||(g=K&~u,g!==0&&(T=pt(g))))):(K=b&~D,K!==0?T=pt(K):q!==0?T=pt(q):g||(g=b&~u,g!==0&&(T=pt(g)))),T===0?0:f!==0&&f!==T&&(f&D)===0&&(D=T&-T,g=f&-f,D>=g||D===32&&(g&4194048)!==0)?f:T}function _t(u,f){return(u.pendingLanes&~(u.suspendedLanes&~u.pingedLanes)&f)===0}function Y(u,f){switch(u){case 1:case 2:case 4:case 8:case 64:return f+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return f+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function xe(){var u=Qt;return Qt<<=1,(Qt&4194048)===0&&(Qt=256),u}function it(){var u=gn;return gn<<=1,(gn&62914560)===0&&(gn=4194304),u}function st(u){for(var f=[],g=0;31>g;g++)f.push(u);return f}function St(u,f){u.pendingLanes|=f,f!==268435456&&(u.suspendedLanes=0,u.pingedLanes=0,u.warmLanes=0)}function Pt(u,f,g,b,T,D){var q=u.pendingLanes;u.pendingLanes=g,u.suspendedLanes=0,u.pingedLanes=0,u.warmLanes=0,u.expiredLanes&=g,u.entangledLanes&=g,u.errorRecoveryDisabledLanes&=g,u.shellSuspendCounter=0;var K=u.entanglements,ge=u.expirationTimes,Be=u.hiddenUpdates;for(g=q&~g;0<g;){var Ke=31-ct(g),tt=1<<Ke;K[Ke]=0,ge[Ke]=-1;var Ne=Be[Ke];if(Ne!==null)for(Be[Ke]=null,Ke=0;Ke<Ne.length;Ke++){var je=Ne[Ke];je!==null&&(je.lane&=-536870913)}g&=~tt}b!==0&&Ht(u,b,0),D!==0&&T===0&&u.tag!==0&&(u.suspendedLanes|=D&~(q&~f))}function Ht(u,f,g){u.pendingLanes|=f,u.suspendedLanes&=~f;var b=31-ct(f);u.entangledLanes|=f,u.entanglements[b]=u.entanglements[b]|1073741824|g&4194090}function Yt(u,f){var g=u.entangledLanes|=f;for(u=u.entanglements;g;){var b=31-ct(g),T=1<<b;T&f|u[b]&f&&(u[b]|=f),g&=~T}}function qt(u){switch(u){case 2:u=1;break;case 8:u=4;break;case 32:u=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:u=128;break;case 268435456:u=134217728;break;default:u=0}return u}function ln(u){return u&=-u,2<u?8<u?(u&134217727)!==0?32:268435456:8:2}function hr(){var u=se.p;return u!==0?u:(u=window.event,u===void 0?32:D4(u.type))}function xr(u,f){var g=se.p;try{return se.p=u,f()}finally{se.p=g}}var Ur=Math.random().toString(36).slice(2),nn="__reactFiber$"+Ur,yn="__reactProps$"+Ur,fn="__reactContainer$"+Ur,ho="__reactEvents$"+Ur,br="__reactListeners$"+Ur,us="__reactHandles$"+Ur,ji="__reactResources$"+Ur,Ho="__reactMarker$"+Ur;function Dt(u){delete u[nn],delete u[yn],delete u[ho],delete u[br],delete u[us]}function to(u){var f=u[nn];if(f)return f;for(var g=u.parentNode;g;){if(f=g[fn]||g[nn]){if(g=f.alternate,f.child!==null||g!==null&&g.child!==null)for(u=Kf(u);u!==null;){if(g=u[nn])return g;u=Kf(u)}return f}u=g,g=u.parentNode}return null}function rr(u){if(u=u[nn]||u[fn]){var f=u.tag;if(f===5||f===6||f===13||f===26||f===27||f===3)return u}return null}function Ro(u){var f=u.tag;if(f===5||f===26||f===27||f===6)return u.stateNode;throw Error(r(33))}function po(u){var f=u[ji];return f||(f=u[ji]={hoistableStyles:new Map,hoistableScripts:new Map}),f}function qn(u){u[Ho]=!0}var ua=new Set,Oi={};function pr(u,f){Br(u,f),Br(u+"Capture",f)}function Br(u,f){for(Oi[u]=f,u=0;u<f.length;u++)ua.add(f[u])}var ca=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Kr={},ot={};function Oe(u){return nt.call(ot,u)?!0:nt.call(Kr,u)?!1:ca.test(u)?ot[u]=!0:(Kr[u]=!0,!1)}function at(u,f,g){if(Oe(f))if(g===null)u.removeAttribute(f);else{switch(typeof g){case"undefined":case"function":case"symbol":u.removeAttribute(f);return;case"boolean":var b=f.toLowerCase().slice(0,5);if(b!=="data-"&&b!=="aria-"){u.removeAttribute(f);return}}u.setAttribute(f,""+g)}}function ce(u,f,g){if(g===null)u.removeAttribute(f);else{switch(typeof g){case"undefined":case"function":case"symbol":case"boolean":u.removeAttribute(f);return}u.setAttribute(f,""+g)}}function Me(u,f,g,b){if(b===null)u.removeAttribute(g);else{switch(typeof b){case"undefined":case"function":case"symbol":case"boolean":u.removeAttribute(g);return}u.setAttributeNS(f,g,""+b)}}var j,te;function he(u){if(j===void 0)try{throw Error()}catch(g){var f=g.stack.trim().match(/\n( *(at )?)/);j=f&&f[1]||"",te=-1<g.stack.indexOf(`
73
+ */var I5;function CV(){if(I5)return s1;I5=1;var e=R5(),t=kg(),n=v3();function r(u){var f="https://react.dev/errors/"+u;if(1<arguments.length){f+="?args[]="+encodeURIComponent(arguments[1]);for(var g=2;g<arguments.length;g++)f+="&args[]="+encodeURIComponent(arguments[g])}return"Minified React error #"+u+"; visit "+f+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(u){return!(!u||u.nodeType!==1&&u.nodeType!==9&&u.nodeType!==11)}function a(u){var f=u,g=u;if(u.alternate)for(;f.return;)f=f.return;else{u=f;do f=u,(f.flags&4098)!==0&&(g=f.return),u=f.return;while(u)}return f.tag===3?g:null}function l(u){if(u.tag===13){var f=u.memoizedState;if(f===null&&(u=u.alternate,u!==null&&(f=u.memoizedState)),f!==null)return f.dehydrated}return null}function d(u){if(a(u)!==u)throw Error(r(188))}function h(u){var f=u.alternate;if(!f){if(f=a(u),f===null)throw Error(r(188));return f!==u?null:u}for(var g=u,b=f;;){var T=g.return;if(T===null)break;var D=T.alternate;if(D===null){if(b=T.return,b!==null){g=b;continue}break}if(T.child===D.child){for(D=T.child;D;){if(D===g)return d(T),u;if(D===b)return d(T),f;D=D.sibling}throw Error(r(188))}if(g.return!==b.return)g=T,b=D;else{for(var q=!1,K=T.child;K;){if(K===g){q=!0,g=T,b=D;break}if(K===b){q=!0,b=T,g=D;break}K=K.sibling}if(!q){for(K=D.child;K;){if(K===g){q=!0,g=D,b=T;break}if(K===b){q=!0,b=D,g=T;break}K=K.sibling}if(!q)throw Error(r(189))}}if(g.alternate!==b)throw Error(r(190))}if(g.tag!==3)throw Error(r(188));return g.stateNode.current===g?u:f}function p(u){var f=u.tag;if(f===5||f===26||f===27||f===6)return u;for(u=u.child;u!==null;){if(f=p(u),f!==null)return f;u=u.sibling}return null}var y=Object.assign,m=Symbol.for("react.element"),x=Symbol.for("react.transitional.element"),_=Symbol.for("react.portal"),w=Symbol.for("react.fragment"),k=Symbol.for("react.strict_mode"),A=Symbol.for("react.profiler"),E=Symbol.for("react.provider"),R=Symbol.for("react.consumer"),O=Symbol.for("react.context"),I=Symbol.for("react.forward_ref"),L=Symbol.for("react.suspense"),N=Symbol.for("react.suspense_list"),H=Symbol.for("react.memo"),V=Symbol.for("react.lazy"),W=Symbol.for("react.activity"),z=Symbol.for("react.memo_cache_sentinel"),Q=Symbol.iterator;function J(u){return u===null||typeof u!="object"?null:(u=Q&&u[Q]||u["@@iterator"],typeof u=="function"?u:null)}var ie=Symbol.for("react.client.reference");function ee(u){if(u==null)return null;if(typeof u=="function")return u.$$typeof===ie?null:u.displayName||u.name||null;if(typeof u=="string")return u;switch(u){case w:return"Fragment";case A:return"Profiler";case k:return"StrictMode";case L:return"Suspense";case N:return"SuspenseList";case W:return"Activity"}if(typeof u=="object")switch(u.$$typeof){case _:return"Portal";case O:return(u.displayName||"Context")+".Provider";case R:return(u._context.displayName||"Context")+".Consumer";case I:var f=u.render;return u=u.displayName,u||(u=f.displayName||f.name||"",u=u!==""?"ForwardRef("+u+")":"ForwardRef"),u;case H:return f=u.displayName||null,f!==null?f:ee(u.type)||"Memo";case V:f=u._payload,u=u._init;try{return ee(u(f))}catch{}}return null}var de=Array.isArray,ue=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,se=n.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,pe={pending:!1,data:null,method:null,action:null},Ce=[],B=-1;function P(u){return{current:u}}function ne(u){0>B||(u.current=Ce[B],Ce[B]=null,B--)}function U(u,f){B++,Ce[B]=u.current,u.current=f}var fe=P(null),Ae=P(null),Te=P(null),rt=P(null);function Ge(u,f){switch(U(Te,f),U(Ae,u),U(fe,null),f.nodeType){case 9:case 11:u=(u=f.documentElement)&&(u=u.namespaceURI)?Al(u):0;break;default:if(u=f.tagName,f=f.namespaceURI)f=Al(f),u=Tu(f,u);else switch(u){case"svg":u=1;break;case"math":u=2;break;default:u=0}}ne(fe),U(fe,u)}function We(){ne(fe),ne(Ae),ne(Te)}function Tt(u){u.memoizedState!==null&&U(rt,u);var f=fe.current,g=Tu(f,u.type);f!==g&&(U(Ae,u),U(fe,g))}function It(u){Ae.current===u&&(ne(fe),ne(Ae)),rt.current===u&&(ne(rt),_o._currentValue=pe)}var nt=Object.prototype.hasOwnProperty,dt=e.unstable_scheduleCallback,bt=e.unstable_cancelCallback,Et=e.unstable_shouldYield,Nt=e.unstable_requestPaint,yt=e.unstable_now,re=e.unstable_getCurrentPriorityLevel,le=e.unstable_ImmediatePriority,ve=e.unstable_UserBlockingPriority,Ee=e.unstable_NormalPriority,$e=e.unstable_LowPriority,Ve=e.unstable_IdlePriority,lt=e.log,mt=e.unstable_setDisableYieldValue,_e=null,Re=null;function Ct(u){if(typeof lt=="function"&&mt(u),Re&&typeof Re.setStrictMode=="function")try{Re.setStrictMode(_e,u)}catch{}}var ct=Math.clz32?Math.clz32:en,Rt=Math.log,Mt=Math.LN2;function en(u){return u>>>=0,u===0?32:31-(Rt(u)/Mt|0)|0}var Qt=256,gn=4194304;function pt(u){var f=u&42;if(f!==0)return f;switch(u&-u){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return u&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return u&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return u}}function Kt(u,f,g){var b=u.pendingLanes;if(b===0)return 0;var T=0,D=u.suspendedLanes,q=u.pingedLanes;u=u.warmLanes;var K=b&134217727;return K!==0?(b=K&~D,b!==0?T=pt(b):(q&=K,q!==0?T=pt(q):g||(g=K&~u,g!==0&&(T=pt(g))))):(K=b&~D,K!==0?T=pt(K):q!==0?T=pt(q):g||(g=b&~u,g!==0&&(T=pt(g)))),T===0?0:f!==0&&f!==T&&(f&D)===0&&(D=T&-T,g=f&-f,D>=g||D===32&&(g&4194048)!==0)?f:T}function _t(u,f){return(u.pendingLanes&~(u.suspendedLanes&~u.pingedLanes)&f)===0}function Y(u,f){switch(u){case 1:case 2:case 4:case 8:case 64:return f+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return f+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function xe(){var u=Qt;return Qt<<=1,(Qt&4194048)===0&&(Qt=256),u}function it(){var u=gn;return gn<<=1,(gn&62914560)===0&&(gn=4194304),u}function st(u){for(var f=[],g=0;31>g;g++)f.push(u);return f}function St(u,f){u.pendingLanes|=f,f!==268435456&&(u.suspendedLanes=0,u.pingedLanes=0,u.warmLanes=0)}function Pt(u,f,g,b,T,D){var q=u.pendingLanes;u.pendingLanes=g,u.suspendedLanes=0,u.pingedLanes=0,u.warmLanes=0,u.expiredLanes&=g,u.entangledLanes&=g,u.errorRecoveryDisabledLanes&=g,u.shellSuspendCounter=0;var K=u.entanglements,ge=u.expirationTimes,Be=u.hiddenUpdates;for(g=q&~g;0<g;){var Ke=31-ct(g),tt=1<<Ke;K[Ke]=0,ge[Ke]=-1;var Ne=Be[Ke];if(Ne!==null)for(Be[Ke]=null,Ke=0;Ke<Ne.length;Ke++){var je=Ne[Ke];je!==null&&(je.lane&=-536870913)}g&=~tt}b!==0&&Ht(u,b,0),D!==0&&T===0&&u.tag!==0&&(u.suspendedLanes|=D&~(q&~f))}function Ht(u,f,g){u.pendingLanes|=f,u.suspendedLanes&=~f;var b=31-ct(f);u.entangledLanes|=f,u.entanglements[b]=u.entanglements[b]|1073741824|g&4194090}function Yt(u,f){var g=u.entangledLanes|=f;for(u=u.entanglements;g;){var b=31-ct(g),T=1<<b;T&f|u[b]&f&&(u[b]|=f),g&=~T}}function qt(u){switch(u){case 2:u=1;break;case 8:u=4;break;case 32:u=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:u=128;break;case 268435456:u=134217728;break;default:u=0}return u}function ln(u){return u&=-u,2<u?8<u?(u&134217727)!==0?32:268435456:8:2}function hr(){var u=se.p;return u!==0?u:(u=window.event,u===void 0?32:D4(u.type))}function xr(u,f){var g=se.p;try{return se.p=u,f()}finally{se.p=g}}var Ur=Math.random().toString(36).slice(2),nn="__reactFiber$"+Ur,yn="__reactProps$"+Ur,fn="__reactContainer$"+Ur,ho="__reactEvents$"+Ur,br="__reactListeners$"+Ur,us="__reactHandles$"+Ur,ji="__reactResources$"+Ur,Ho="__reactMarker$"+Ur;function Dt(u){delete u[nn],delete u[yn],delete u[ho],delete u[br],delete u[us]}function to(u){var f=u[nn];if(f)return f;for(var g=u.parentNode;g;){if(f=g[fn]||g[nn]){if(g=f.alternate,f.child!==null||g!==null&&g.child!==null)for(u=Kf(u);u!==null;){if(g=u[nn])return g;u=Kf(u)}return f}u=g,g=u.parentNode}return null}function rr(u){if(u=u[nn]||u[fn]){var f=u.tag;if(f===5||f===6||f===13||f===26||f===27||f===3)return u}return null}function Ro(u){var f=u.tag;if(f===5||f===26||f===27||f===6)return u.stateNode;throw Error(r(33))}function po(u){var f=u[ji];return f||(f=u[ji]={hoistableStyles:new Map,hoistableScripts:new Map}),f}function qn(u){u[Ho]=!0}var ua=new Set,Oi={};function pr(u,f){Br(u,f),Br(u+"Capture",f)}function Br(u,f){for(Oi[u]=f,u=0;u<f.length;u++)ua.add(f[u])}var ca=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Kr={},ot={};function Oe(u){return nt.call(ot,u)?!0:nt.call(Kr,u)?!1:ca.test(u)?ot[u]=!0:(Kr[u]=!0,!1)}function at(u,f,g){if(Oe(f))if(g===null)u.removeAttribute(f);else{switch(typeof g){case"undefined":case"function":case"symbol":u.removeAttribute(f);return;case"boolean":var b=f.toLowerCase().slice(0,5);if(b!=="data-"&&b!=="aria-"){u.removeAttribute(f);return}}u.setAttribute(f,""+g)}}function ce(u,f,g){if(g===null)u.removeAttribute(f);else{switch(typeof g){case"undefined":case"function":case"symbol":case"boolean":u.removeAttribute(f);return}u.setAttribute(f,""+g)}}function Ie(u,f,g,b){if(b===null)u.removeAttribute(g);else{switch(typeof b){case"undefined":case"function":case"symbol":case"boolean":u.removeAttribute(g);return}u.setAttributeNS(f,g,""+b)}}var j,te;function he(u){if(j===void 0)try{throw Error()}catch(g){var f=g.stack.trim().match(/\n( *(at )?)/);j=f&&f[1]||"",te=-1<g.stack.indexOf(`
74
74
  at`)?" (<anonymous>)":-1<g.stack.indexOf("@")?"@unknown:0:0":""}return`
75
75
  `+j+u+te}var ke=!1;function we(u,f){if(!u||ke)return"";ke=!0;var g=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var b={DetermineComponentFrameRoot:function(){try{if(f){var tt=function(){throw Error()};if(Object.defineProperty(tt.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(tt,[])}catch(je){var Ne=je}Reflect.construct(u,[],tt)}else{try{tt.call()}catch(je){Ne=je}u.call(tt.prototype)}}else{try{throw Error()}catch(je){Ne=je}(tt=u())&&typeof tt.catch=="function"&&tt.catch(function(){})}}catch(je){if(je&&Ne&&typeof je.stack=="string")return[je.stack,Ne.stack]}return[null,null]}};b.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var T=Object.getOwnPropertyDescriptor(b.DetermineComponentFrameRoot,"name");T&&T.configurable&&Object.defineProperty(b.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var D=b.DetermineComponentFrameRoot(),q=D[0],K=D[1];if(q&&K){var ge=q.split(`
76
76
  `),Be=K.split(`
@@ -78,7 +78,7 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
78
78
  `+ge[b].replace(" at new "," at ");return u.displayName&&Ke.includes("<anonymous>")&&(Ke=Ke.replace("<anonymous>",u.displayName)),Ke}while(1<=b&&0<=T);break}}}finally{ke=!1,Error.prepareStackTrace=g}return(g=u?u.displayName||u.name:"")?he(g):""}function Je(u){switch(u.tag){case 26:case 27:case 5:return he(u.type);case 16:return he("Lazy");case 13:return he("Suspense");case 19:return he("SuspenseList");case 0:case 15:return we(u.type,!1);case 11:return we(u.type.render,!1);case 1:return we(u.type,!0);case 31:return he("Activity");default:return""}}function $t(u){try{var f="";do f+=Je(u),u=u.return;while(u);return f}catch(g){return`
79
79
  Error generating stack: `+g.message+`
80
80
  `+g.stack}}function an(u){switch(typeof u){case"bigint":case"boolean":case"number":case"string":case"undefined":return u;case"object":return u;default:return""}}function un(u){var f=u.type;return(u=u.nodeName)&&u.toLowerCase()==="input"&&(f==="checkbox"||f==="radio")}function Un(u){var f=un(u)?"checked":"value",g=Object.getOwnPropertyDescriptor(u.constructor.prototype,f),b=""+u[f];if(!u.hasOwnProperty(f)&&typeof g<"u"&&typeof g.get=="function"&&typeof g.set=="function"){var T=g.get,D=g.set;return Object.defineProperty(u,f,{configurable:!0,get:function(){return T.call(this)},set:function(q){b=""+q,D.call(this,q)}}),Object.defineProperty(u,f,{enumerable:g.enumerable}),{getValue:function(){return b},setValue:function(q){b=""+q},stopTracking:function(){u._valueTracker=null,delete u[f]}}}}function dn(u){u._valueTracker||(u._valueTracker=Un(u))}function gr(u){if(!u)return!1;var f=u._valueTracker;if(!f)return!0;var g=f.getValue(),b="";return u&&(b=un(u)?u.checked?"true":"false":u.value),u=b,u!==g?(f.setValue(u),!0):!1}function $r(u){if(u=u||(typeof document<"u"?document:void 0),typeof u>"u")return null;try{return u.activeElement||u.body}catch{return u.body}}var hi=/[\n"\\]/g;function ai(u){return u.replace(hi,function(f){return"\\"+f.charCodeAt(0).toString(16)+" "})}function go(u,f,g,b,T,D,q,K){u.name="",q!=null&&typeof q!="function"&&typeof q!="symbol"&&typeof q!="boolean"?u.type=q:u.removeAttribute("type"),f!=null?q==="number"?(f===0&&u.value===""||u.value!=f)&&(u.value=""+an(f)):u.value!==""+an(f)&&(u.value=""+an(f)):q!=="submit"&&q!=="reset"||u.removeAttribute("value"),f!=null?Zp(u,q,an(f)):g!=null?Zp(u,q,an(g)):b!=null&&u.removeAttribute("value"),T==null&&D!=null&&(u.defaultChecked=!!D),T!=null&&(u.checked=T&&typeof T!="function"&&typeof T!="symbol"),K!=null&&typeof K!="function"&&typeof K!="symbol"&&typeof K!="boolean"?u.name=""+an(K):u.removeAttribute("name")}function Yp(u,f,g,b,T,D,q,K){if(D!=null&&typeof D!="function"&&typeof D!="symbol"&&typeof D!="boolean"&&(u.type=D),f!=null||g!=null){if(!(D!=="submit"&&D!=="reset"||f!=null))return;g=g!=null?""+an(g):"",f=f!=null?""+an(f):g,K||f===u.value||(u.value=f),u.defaultValue=f}b=b??T,b=typeof b!="function"&&typeof b!="symbol"&&!!b,u.checked=K?u.checked:!!b,u.defaultChecked=!!b,q!=null&&typeof q!="function"&&typeof q!="symbol"&&typeof q!="boolean"&&(u.name=q)}function Zp(u,f,g){f==="number"&&$r(u.ownerDocument)===u||u.defaultValue===""+g||(u.defaultValue=""+g)}function rc(u,f,g,b){if(u=u.options,f){f={};for(var T=0;T<g.length;T++)f["$"+g[T]]=!0;for(g=0;g<u.length;g++)T=f.hasOwnProperty("$"+u[g].value),u[g].selected!==T&&(u[g].selected=T),T&&b&&(u[g].defaultSelected=!0)}else{for(g=""+an(g),f=null,T=0;T<u.length;T++){if(u[T].value===g){u[T].selected=!0,b&&(u[T].defaultSelected=!0);return}f!==null||u[T].disabled||(f=u[T])}f!==null&&(f.selected=!0)}}function Qx(u,f,g){if(f!=null&&(f=""+an(f),f!==u.value&&(u.value=f),g==null)){u.defaultValue!==f&&(u.defaultValue=f);return}u.defaultValue=g!=null?""+an(g):""}function Kx(u,f,g,b){if(f==null){if(b!=null){if(g!=null)throw Error(r(92));if(de(b)){if(1<b.length)throw Error(r(93));b=b[0]}g=b}g==null&&(g=""),f=g}g=an(f),u.defaultValue=g,b=u.textContent,b===g&&b!==""&&b!==null&&(u.value=b)}function mf(u,f){if(f){var g=u.firstChild;if(g&&g===u.lastChild&&g.nodeType===3){g.nodeValue=f;return}}u.textContent=f}var rM=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Wx(u,f,g){var b=f.indexOf("--")===0;g==null||typeof g=="boolean"||g===""?b?u.setProperty(f,""):f==="float"?u.cssFloat="":u[f]="":b?u.setProperty(f,g):typeof g!="number"||g===0||rM.has(f)?f==="float"?u.cssFloat=g:u[f]=(""+g).trim():u[f]=g+"px"}function Qm(u,f,g){if(f!=null&&typeof f!="object")throw Error(r(62));if(u=u.style,g!=null){for(var b in g)!g.hasOwnProperty(b)||f!=null&&f.hasOwnProperty(b)||(b.indexOf("--")===0?u.setProperty(b,""):b==="float"?u.cssFloat="":u[b]="");for(var T in f)b=f[T],f.hasOwnProperty(T)&&g[T]!==b&&Wx(u,T,b)}else for(var D in f)f.hasOwnProperty(D)&&Wx(u,D,f[D])}function Yd(u){if(u.indexOf("-")===-1)return!1;switch(u){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Qp=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),iM=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Kp(u){return iM.test(""+u)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":u}var Km=null;function vf(u){return u=u.target||u.srcElement||window,u.correspondingUseElement&&(u=u.correspondingUseElement),u.nodeType===3?u.parentNode:u}var yf=null,Zd=null;function RT(u){var f=rr(u);if(f&&(u=f.stateNode)){var g=u[yn]||null;e:switch(u=f.stateNode,f.type){case"input":if(go(u,g.value,g.defaultValue,g.defaultValue,g.checked,g.defaultChecked,g.type,g.name),f=g.name,g.type==="radio"&&f!=null){for(g=u;g.parentNode;)g=g.parentNode;for(g=g.querySelectorAll('input[name="'+ai(""+f)+'"][type="radio"]'),f=0;f<g.length;f++){var b=g[f];if(b!==u&&b.form===u.form){var T=b[yn]||null;if(!T)throw Error(r(90));go(b,T.value,T.defaultValue,T.defaultValue,T.checked,T.defaultChecked,T.type,T.name)}}for(f=0;f<g.length;f++)b=g[f],b.form===u.form&&gr(b)}break e;case"textarea":Qx(u,g.value,g.defaultValue);break e;case"select":f=g.value,f!=null&&rc(u,!!g.multiple,f,!1)}}}var Xx=!1;function OT(u,f,g){if(Xx)return u(f,g);Xx=!0;try{var b=u(f);return b}finally{if(Xx=!1,(yf!==null||Zd!==null)&&(j0(),yf&&(f=yf,u=Zd,Zd=yf=null,RT(f),u)))for(f=0;f<u.length;f++)RT(u[f])}}function iu(u,f){var g=u.stateNode;if(g===null)return null;var b=g[yn]||null;if(b===null)return null;g=b[f];e:switch(f){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(b=!b.disabled)||(u=u.type,b=!(u==="button"||u==="input"||u==="select"||u==="textarea")),u=!b;break e;default:u=!1}if(u)return null;if(g&&typeof g!="function")throw Error(r(231,f,typeof g));return g}var Ms=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Wm=!1;if(Ms)try{var Qd={};Object.defineProperty(Qd,"passive",{get:function(){Wm=!0}}),window.addEventListener("test",Qd,Qd),window.removeEventListener("test",Qd,Qd)}catch{Wm=!1}var cs=null,Xm=null,xf=null;function Wp(){if(xf)return xf;var u,f=Xm,g=f.length,b,T="value"in cs?cs.value:cs.textContent,D=T.length;for(u=0;u<g&&f[u]===T[u];u++);var q=g-u;for(b=1;b<=q&&f[g-b]===T[D-b];b++);return xf=T.slice(u,1<b?1-b:void 0)}function Xp(u){var f=u.keyCode;return"charCode"in u?(u=u.charCode,u===0&&f===13&&(u=13)):u=f,u===10&&(u=13),32<=u||u===13?u:0}function mo(){return!0}function DT(){return!1}function Oo(u){function f(g,b,T,D,q){this._reactName=g,this._targetInst=T,this.type=b,this.nativeEvent=D,this.target=q,this.currentTarget=null;for(var K in u)u.hasOwnProperty(K)&&(g=u[K],this[K]=g?g(D):D[K]);return this.isDefaultPrevented=(D.defaultPrevented!=null?D.defaultPrevented:D.returnValue===!1)?mo:DT,this.isPropagationStopped=DT,this}return y(f.prototype,{preventDefault:function(){this.defaultPrevented=!0;var g=this.nativeEvent;g&&(g.preventDefault?g.preventDefault():typeof g.returnValue!="unknown"&&(g.returnValue=!1),this.isDefaultPrevented=mo)},stopPropagation:function(){var g=this.nativeEvent;g&&(g.stopPropagation?g.stopPropagation():typeof g.cancelBubble!="unknown"&&(g.cancelBubble=!0),this.isPropagationStopped=mo)},persist:function(){},isPersistent:mo}),f}var ic={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(u){return u.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Jp=Oo(ic),e0=y({},ic,{view:0,detail:0}),oM=Oo(e0),Jm,Jx,Kd,ev=y({},e0,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:tv,button:0,buttons:0,relatedTarget:function(u){return u.relatedTarget===void 0?u.fromElement===u.srcElement?u.toElement:u.fromElement:u.relatedTarget},movementX:function(u){return"movementX"in u?u.movementX:(u!==Kd&&(Kd&&u.type==="mousemove"?(Jm=u.screenX-Kd.screenX,Jx=u.screenY-Kd.screenY):Jx=Jm=0,Kd=u),Jm)},movementY:function(u){return"movementY"in u?u.movementY:Jx}}),t0=Oo(ev),MT=y({},ev,{dataTransfer:0}),IT=Oo(MT),$T=y({},e0,{relatedTarget:0}),eb=Oo($T),aM=y({},ic,{animationName:0,elapsedTime:0,pseudoElement:0}),sM=Oo(aM),lM=y({},ic,{clipboardData:function(u){return"clipboardData"in u?u.clipboardData:window.clipboardData}}),uM=Oo(lM),n0=y({},ic,{data:0}),tb=Oo(n0),BT={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},LT={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},NT={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function nb(u){var f=this.nativeEvent;return f.getModifierState?f.getModifierState(u):(u=NT[u])?!!f[u]:!1}function tv(){return nb}var bf=y({},e0,{key:function(u){if(u.key){var f=BT[u.key]||u.key;if(f!=="Unidentified")return f}return u.type==="keypress"?(u=Xp(u),u===13?"Enter":String.fromCharCode(u)):u.type==="keydown"||u.type==="keyup"?LT[u.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:tv,charCode:function(u){return u.type==="keypress"?Xp(u):0},keyCode:function(u){return u.type==="keydown"||u.type==="keyup"?u.keyCode:0},which:function(u){return u.type==="keypress"?Xp(u):u.type==="keydown"||u.type==="keyup"?u.keyCode:0}}),_f=Oo(bf),Is=y({},ev,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),fa=Oo(Is),nv=y({},e0,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:tv}),rv=Oo(nv),rb=y({},ic,{propertyName:0,elapsedTime:0,pseudoElement:0}),da=Oo(rb),zT=y({},ev,{deltaX:function(u){return"deltaX"in u?u.deltaX:"wheelDeltaX"in u?-u.wheelDeltaX:0},deltaY:function(u){return"deltaY"in u?u.deltaY:"wheelDeltaY"in u?-u.wheelDeltaY:"wheelDelta"in u?-u.wheelDelta:0},deltaZ:0,deltaMode:0}),iv=Oo(zT),Sf=y({},ic,{newState:0,oldState:0}),ib=Oo(Sf),FT=[9,13,27,32],ov=Ms&&"CompositionEvent"in window,wf=null;Ms&&"documentMode"in document&&(wf=document.documentMode);var cM=Ms&&"TextEvent"in window&&!wf,av=Ms&&(!ov||wf&&8<wf&&11>=wf),xl=" ",ob=!1;function sv(u,f){switch(u){case"keyup":return FT.indexOf(f.keyCode)!==-1;case"keydown":return f.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function r0(u){return u=u.detail,typeof u=="object"&&"data"in u?u.data:null}var fs=!1;function ab(u,f){switch(u){case"compositionend":return r0(f);case"keypress":return f.which!==32?null:(ob=!0,xl);case"textInput":return u=f.data,u===xl&&ob?null:u;default:return null}}function sb(u,f){if(fs)return u==="compositionend"||!ov&&sv(u,f)?(u=Wp(),xf=Xm=cs=null,fs=!1,u):null;switch(u){case"paste":return null;case"keypress":if(!(f.ctrlKey||f.altKey||f.metaKey)||f.ctrlKey&&f.altKey){if(f.char&&1<f.char.length)return f.char;if(f.which)return String.fromCharCode(f.which)}return null;case"compositionend":return av&&f.locale!=="ko"?null:f.data;default:return null}}var Cf={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function lb(u){var f=u&&u.nodeName&&u.nodeName.toLowerCase();return f==="input"?!!Cf[u.type]:f==="textarea"}function lv(u,f,g,b){yf?Zd?Zd.push(b):Zd=[b]:yf=b,f=Mc(f,"onChange"),0<f.length&&(g=new Jp("onChange","change",null,g,b),u.push({event:g,listeners:f}))}var Ef=null,$s=null;function Af(u){ku(u,0)}function Wd(u){var f=Ro(u);if(gr(f))return u}function oc(u,f){if(u==="change")return f}var ub=!1;if(Ms){var uv;if(Ms){var kf="oninput"in document;if(!kf){var Xd=document.createElement("div");Xd.setAttribute("oninput","return;"),kf=typeof Xd.oninput=="function"}uv=kf}else uv=!1;ub=uv&&(!document.documentMode||9<document.documentMode)}function cb(){Ef&&(Ef.detachEvent("onpropertychange",Jd),$s=Ef=null)}function Jd(u){if(u.propertyName==="value"&&Wd($s)){var f=[];lv(f,$s,u,vf(u)),OT(Af,f)}}function UT(u,f,g){u==="focusin"?(cb(),Ef=f,$s=g,Ef.attachEvent("onpropertychange",Jd)):u==="focusout"&&cb()}function cv(u){if(u==="selectionchange"||u==="keyup"||u==="keydown")return Wd($s)}function ac(u,f){if(u==="click")return Wd(f)}function ou(u,f){if(u==="input"||u==="change")return Wd(f)}function fb(u,f){return u===f&&(u!==0||1/u===1/f)||u!==u&&f!==f}var qo=typeof Object.is=="function"?Object.is:fb;function au(u,f){if(qo(u,f))return!0;if(typeof u!="object"||u===null||typeof f!="object"||f===null)return!1;var g=Object.keys(u),b=Object.keys(f);if(g.length!==b.length)return!1;for(b=0;b<g.length;b++){var T=g[b];if(!nt.call(f,T)||!qo(u[T],f[T]))return!1}return!0}function i0(u){for(;u&&u.firstChild;)u=u.firstChild;return u}function sc(u,f){var g=i0(u);u=0;for(var b;g;){if(g.nodeType===3){if(b=u+g.textContent.length,u<=f&&b>=f)return{node:g,offset:f-u};u=b}e:{for(;g;){if(g.nextSibling){g=g.nextSibling;break e}g=g.parentNode}g=void 0}g=i0(g)}}function jr(u,f){return u&&f?u===f?!0:u&&u.nodeType===3?!1:f&&f.nodeType===3?jr(u,f.parentNode):"contains"in u?u.contains(f):u.compareDocumentPosition?!!(u.compareDocumentPosition(f)&16):!1:!1}function o0(u){u=u!=null&&u.ownerDocument!=null&&u.ownerDocument.defaultView!=null?u.ownerDocument.defaultView:window;for(var f=$r(u.document);f instanceof u.HTMLIFrameElement;){try{var g=typeof f.contentWindow.location.href=="string"}catch{g=!1}if(g)u=f.contentWindow;else break;f=$r(u.document)}return f}function fv(u){var f=u&&u.nodeName&&u.nodeName.toLowerCase();return f&&(f==="input"&&(u.type==="text"||u.type==="search"||u.type==="tel"||u.type==="url"||u.type==="password")||f==="textarea"||u.contentEditable==="true")}var db=Ms&&"documentMode"in document&&11>=document.documentMode,ds=null,Tf=null,za=null,eh=!1;function th(u,f,g){var b=g.window===g?g.document:g.nodeType===9?g:g.ownerDocument;eh||ds==null||ds!==$r(b)||(b=ds,"selectionStart"in b&&fv(b)?b={start:b.selectionStart,end:b.selectionEnd}:(b=(b.ownerDocument&&b.ownerDocument.defaultView||window).getSelection(),b={anchorNode:b.anchorNode,anchorOffset:b.anchorOffset,focusNode:b.focusNode,focusOffset:b.focusOffset}),za&&au(za,b)||(za=b,b=Mc(Tf,"onSelect"),0<b.length&&(f=new Jp("onSelect","select",null,f,g),u.push({event:f,listeners:b}),f.target=ds)))}function su(u,f){var g={};return g[u.toLowerCase()]=f.toLowerCase(),g["Webkit"+u]="webkit"+f,g["Moz"+u]="moz"+f,g}var lc={animationend:su("Animation","AnimationEnd"),animationiteration:su("Animation","AnimationIteration"),animationstart:su("Animation","AnimationStart"),transitionrun:su("Transition","TransitionRun"),transitionstart:su("Transition","TransitionStart"),transitioncancel:su("Transition","TransitionCancel"),transitionend:su("Transition","TransitionEnd")},dv={},Bs={};Ms&&(Bs=document.createElement("div").style,"AnimationEvent"in window||(delete lc.animationend.animation,delete lc.animationiteration.animation,delete lc.animationstart.animation),"TransitionEvent"in window||delete lc.transitionend.transition);function Do(u){if(dv[u])return dv[u];if(!lc[u])return u;var f=lc[u],g;for(g in f)if(f.hasOwnProperty(g)&&g in Bs)return dv[u]=f[g];return u}var a0=Do("animationend"),jT=Do("animationiteration"),hb=Do("animationstart"),fM=Do("transitionrun"),pb=Do("transitionstart"),hv=Do("transitioncancel"),gb=Do("transitionend"),mb=new Map,pv="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");pv.push("scrollEnd");function ha(u,f){mb.set(u,f),pr(f,[u])}var vb=new WeakMap;function Fa(u,f){if(typeof u=="object"&&u!==null){var g=vb.get(u);return g!==void 0?g:(f={value:u,source:f,stack:$t(f)},vb.set(u,f),f)}return{value:u,source:f,stack:$t(f)}}var Ua=[],uc=0,s0=0;function Ls(){for(var u=uc,f=s0=uc=0;f<u;){var g=Ua[f];Ua[f++]=null;var b=Ua[f];Ua[f++]=null;var T=Ua[f];Ua[f++]=null;var D=Ua[f];if(Ua[f++]=null,b!==null&&T!==null){var q=b.pending;q===null?T.next=T:(T.next=q.next,q.next=T),b.pending=T}D!==0&&nh(g,T,D)}}function Ns(u,f,g,b){Ua[uc++]=u,Ua[uc++]=f,Ua[uc++]=g,Ua[uc++]=b,s0|=b,u.lanes|=b,u=u.alternate,u!==null&&(u.lanes|=b)}function Rf(u,f,g,b){return Ns(u,f,g,b),cc(u)}function lu(u,f){return Ns(u,null,null,f),cc(u)}function nh(u,f,g){u.lanes|=g;var b=u.alternate;b!==null&&(b.lanes|=g);for(var T=!1,D=u.return;D!==null;)D.childLanes|=g,b=D.alternate,b!==null&&(b.childLanes|=g),D.tag===22&&(u=D.stateNode,u===null||u._visibility&1||(T=!0)),u=D,D=D.return;return u.tag===3?(D=u.stateNode,T&&f!==null&&(T=31-ct(g),u=D.hiddenUpdates,b=u[T],b===null?u[T]=[f]:b.push(f),f.lane=g|536870912),D):null}function cc(u){if(50<Bh)throw Bh=0,ty=null,Error(r(185));for(var f=u.return;f!==null;)u=f,f=u.return;return u.tag===3?u.stateNode:null}var Of={};function dM(u,f,g,b){this.tag=u,this.key=g,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=f,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=b,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function pa(u,f,g,b){return new dM(u,f,g,b)}function gv(u){return u=u.prototype,!(!u||!u.isReactComponent)}function zs(u,f){var g=u.alternate;return g===null?(g=pa(u.tag,f,u.key,u.mode),g.elementType=u.elementType,g.type=u.type,g.stateNode=u.stateNode,g.alternate=u,u.alternate=g):(g.pendingProps=f,g.type=u.type,g.flags=0,g.subtreeFlags=0,g.deletions=null),g.flags=u.flags&65011712,g.childLanes=u.childLanes,g.lanes=u.lanes,g.child=u.child,g.memoizedProps=u.memoizedProps,g.memoizedState=u.memoizedState,g.updateQueue=u.updateQueue,f=u.dependencies,g.dependencies=f===null?null:{lanes:f.lanes,firstContext:f.firstContext},g.sibling=u.sibling,g.index=u.index,g.ref=u.ref,g.refCleanup=u.refCleanup,g}function mv(u,f){u.flags&=65011714;var g=u.alternate;return g===null?(u.childLanes=0,u.lanes=f,u.child=null,u.subtreeFlags=0,u.memoizedProps=null,u.memoizedState=null,u.updateQueue=null,u.dependencies=null,u.stateNode=null):(u.childLanes=g.childLanes,u.lanes=g.lanes,u.child=g.child,u.subtreeFlags=0,u.deletions=null,u.memoizedProps=g.memoizedProps,u.memoizedState=g.memoizedState,u.updateQueue=g.updateQueue,u.type=g.type,f=g.dependencies,u.dependencies=f===null?null:{lanes:f.lanes,firstContext:f.firstContext}),u}function Cn(u,f,g,b,T,D){var q=0;if(b=u,typeof u=="function")gv(u)&&(q=1);else if(typeof u=="string")q=C4(u,g,fe.current)?26:u==="html"||u==="head"||u==="body"?27:5;else e:switch(u){case W:return u=pa(31,g,f,T),u.elementType=W,u.lanes=D,u;case w:return ut(g.children,T,D,f);case k:q=8,T|=24;break;case A:return u=pa(12,g,f,T|2),u.elementType=A,u.lanes=D,u;case L:return u=pa(13,g,f,T),u.elementType=L,u.lanes=D,u;case N:return u=pa(19,g,f,T),u.elementType=N,u.lanes=D,u;default:if(typeof u=="object"&&u!==null)switch(u.$$typeof){case E:case O:q=10;break e;case R:q=9;break e;case I:q=11;break e;case H:q=14;break e;case V:q=16,b=null;break e}q=29,g=Error(r(130,u===null?"null":typeof u,"")),b=null}return f=pa(q,g,f,T),f.elementType=u,f.type=b,f.lanes=D,f}function ut(u,f,g,b){return u=pa(7,u,b,f),u.lanes=g,u}function fc(u,f,g){return u=pa(6,u,null,f),u.lanes=g,u}function rh(u,f,g){return f=pa(4,u.children!==null?u.children:[],u.key,f),f.lanes=g,f.stateNode={containerInfo:u.containerInfo,pendingChildren:null,implementation:u.implementation},f}var Lr=[],dc=0,ih=null,l0=0,ga=[],hs=0,uu=null,Fs=1,Us="";function Di(u,f){Lr[dc++]=l0,Lr[dc++]=ih,ih=u,l0=f}function mr(u,f,g){ga[hs++]=Fs,ga[hs++]=Us,ga[hs++]=uu,uu=u;var b=Fs;u=Us;var T=32-ct(b)-1;b&=~(1<<T),g+=1;var D=32-ct(f)+T;if(30<D){var q=T-T%5;D=(b&(1<<q)-1).toString(32),b>>=q,T-=q,Fs=1<<32-ct(f)+T|g<<T|b,Us=D+u}else Fs=1<<D|g<<T|b,Us=u}function u0(u){u.return!==null&&(Di(u,1),mr(u,1,0))}function Df(u){for(;u===ih;)ih=Lr[--dc],Lr[dc]=null,l0=Lr[--dc],Lr[dc]=null;for(;u===uu;)uu=ga[--hs],ga[hs]=null,Us=ga[--hs],ga[hs]=null,Fs=ga[--hs],ga[hs]=null}var pi=null,Er=null,En=!1,cu=null,Go=!1,c0=Error(r(519));function js(u){var f=Error(r(418,""));throw sh(Fa(f,u)),c0}function vv(u){var f=u.stateNode,g=u.type,b=u.memoizedProps;switch(f[nn]=u,f[yn]=b,g){case"dialog":xn("cancel",f),xn("close",f);break;case"iframe":case"object":case"embed":xn("load",f);break;case"video":case"audio":for(g=0;g<hn.length;g++)xn(hn[g],f);break;case"source":xn("error",f);break;case"img":case"image":case"link":xn("error",f),xn("load",f);break;case"details":xn("toggle",f);break;case"input":xn("invalid",f),Yp(f,b.value,b.defaultValue,b.checked,b.defaultChecked,b.type,b.name,!0),dn(f);break;case"select":xn("invalid",f);break;case"textarea":xn("invalid",f),Kx(f,b.value,b.defaultValue,b.children),dn(f)}g=b.children,typeof g!="string"&&typeof g!="number"&&typeof g!="bigint"||f.textContent===""+g||b.suppressHydrationWarning===!0||_4(f.textContent,g)?(b.popover!=null&&(xn("beforetoggle",f),xn("toggle",f)),b.onScroll!=null&&xn("scroll",f),b.onScrollEnd!=null&&xn("scrollend",f),b.onClick!=null&&(f.onclick=Q0),f=!0):f=!1,f||js(u)}function f0(u){for(pi=u.return;pi;)switch(pi.tag){case 5:case 13:Go=!1;return;case 27:case 3:Go=!0;return;default:pi=pi.return}}function oh(u){if(u!==pi)return!1;if(!En)return f0(u),En=!0,!1;var f=u.tag,g;if((g=f!==3&&f!==27)&&((g=f===5)&&(g=u.type,g=!(g!=="form"&&g!=="button")||Qf(u.type,u.memoizedProps)),g=!g),g&&Er&&js(u),f0(u),f===13){if(u=u.memoizedState,u=u!==null?u.dehydrated:null,!u)throw Error(r(317));e:{for(u=u.nextSibling,f=0;u;){if(u.nodeType===8)if(g=u.data,g==="/$"){if(f===0){Er=el(u.nextSibling);break e}f--}else g!=="$"&&g!=="$!"&&g!=="$?"||f++;u=u.nextSibling}Er=null}}else f===27?(f=Er,xo(u.type)?(u=N_,N_=null,Er=u):Er=f):Er=pi?el(u.stateNode.nextSibling):null;return!0}function ah(){Er=pi=null,En=!1}function yb(){var u=cu;return u!==null&&(Yo===null?Yo=u:Yo.push.apply(Yo,u),cu=null),u}function sh(u){cu===null?cu=[u]:cu.push(u)}var yv=P(null),fu=null,Ps=null;function bl(u,f,g){U(yv,f._currentValue),f._currentValue=g}function _l(u){u._currentValue=yv.current,ne(yv)}function xv(u,f,g){for(;u!==null;){var b=u.alternate;if((u.childLanes&f)!==f?(u.childLanes|=f,b!==null&&(b.childLanes|=f)):b!==null&&(b.childLanes&f)!==f&&(b.childLanes|=f),u===g)break;u=u.return}}function bv(u,f,g,b){var T=u.child;for(T!==null&&(T.return=u);T!==null;){var D=T.dependencies;if(D!==null){var q=T.child;D=D.firstContext;e:for(;D!==null;){var K=D;D=T;for(var ge=0;ge<f.length;ge++)if(K.context===f[ge]){D.lanes|=g,K=D.alternate,K!==null&&(K.lanes|=g),xv(D.return,g,u),b||(q=null);break e}D=K.next}}else if(T.tag===18){if(q=T.return,q===null)throw Error(r(341));q.lanes|=g,D=q.alternate,D!==null&&(D.lanes|=g),xv(q,g,u),q=null}else q=T.child;if(q!==null)q.return=T;else for(q=T;q!==null;){if(q===u){q=null;break}if(T=q.sibling,T!==null){T.return=q.return,q=T;break}q=q.return}T=q}}function d0(u,f,g,b){u=null;for(var T=f,D=!1;T!==null;){if(!D){if((T.flags&524288)!==0)D=!0;else if((T.flags&262144)!==0)break}if(T.tag===10){var q=T.alternate;if(q===null)throw Error(r(387));if(q=q.memoizedProps,q!==null){var K=T.type;qo(T.pendingProps.value,q.value)||(u!==null?u.push(K):u=[K])}}else if(T===rt.current){if(q=T.alternate,q===null)throw Error(r(387));q.memoizedState.memoizedState!==T.memoizedState.memoizedState&&(u!==null?u.push(_o):u=[_o])}T=T.return}u!==null&&bv(f,u,g,b),f.flags|=262144}function h0(u){for(u=u.firstContext;u!==null;){if(!qo(u.context._currentValue,u.memoizedValue))return!0;u=u.next}return!1}function hc(u){fu=u,Ps=null,u=u.dependencies,u!==null&&(u.firstContext=null)}function vo(u){return xb(fu,u)}function lh(u,f){return fu===null&&hc(u),xb(u,f)}function xb(u,f){var g=f._currentValue;if(f={context:f,memoizedValue:g,next:null},Ps===null){if(u===null)throw Error(r(308));Ps=f,u.dependencies={lanes:0,firstContext:f},u.flags|=524288}else Ps=Ps.next=f;return g}var PT=typeof AbortController<"u"?AbortController:function(){var u=[],f=this.signal={aborted:!1,addEventListener:function(g,b){u.push(b)}};this.abort=function(){f.aborted=!0,u.forEach(function(g){return g()})}},uh=e.unstable_scheduleCallback,_v=e.unstable_NormalPriority,Mi={$$typeof:O,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function bb(){return{controller:new PT,data:new Map,refCount:0}}function pc(u){u.refCount--,u.refCount===0&&uh(_v,function(){u.controller.abort()})}var Sl=null,ch=0,gc=0,ps=null;function ma(u,f){if(Sl===null){var g=Sl=[];ch=0,gc=fy(),ps={status:"pending",value:void 0,then:function(b){g.push(b)}}}return ch++,f.then(p0,p0),f}function p0(){if(--ch===0&&Sl!==null){ps!==null&&(ps.status="fulfilled");var u=Sl;Sl=null,gc=0,ps=null;for(var f=0;f<u.length;f++)(0,u[f])()}}function _b(u,f){var g=[],b={status:"pending",value:null,reason:null,then:function(T){g.push(T)}};return u.then(function(){b.status="fulfilled",b.value=f;for(var T=0;T<g.length;T++)(0,g[T])(f)},function(T){for(b.status="rejected",b.reason=T,T=0;T<g.length;T++)(0,g[T])(void 0)}),b}var Sb=ue.S;ue.S=function(u,f){typeof f=="object"&&f!==null&&typeof f.then=="function"&&ma(u,f),Sb!==null&&Sb(u,f)};var du=P(null);function fh(){var u=du.current;return u!==null?u:kr.pooledCache}function dh(u,f){f===null?U(du,du.current):U(du,f.pool)}function g0(){var u=fh();return u===null?null:{parent:Mi._currentValue,pool:u}}var Mf=Error(r(460)),m0=Error(r(474)),hh=Error(r(542)),Sv={then:function(){}};function wb(u){return u=u.status,u==="fulfilled"||u==="rejected"}function ph(){}function Cb(u,f,g){switch(g=u[g],g===void 0?u.push(f):g!==f&&(f.then(ph,ph),f=g),f.status){case"fulfilled":return f.value;case"rejected":throw u=f.reason,Eb(u),u;default:if(typeof f.status=="string")f.then(ph,ph);else{if(u=kr,u!==null&&100<u.shellSuspendCounter)throw Error(r(482));u=f,u.status="pending",u.then(function(b){if(f.status==="pending"){var T=f;T.status="fulfilled",T.value=b}},function(b){if(f.status==="pending"){var T=f;T.status="rejected",T.reason=b}})}switch(f.status){case"fulfilled":return f.value;case"rejected":throw u=f.reason,Eb(u),u}throw gh=f,Mf}}var gh=null;function wv(){if(gh===null)throw Error(r(459));var u=gh;return gh=null,u}function Eb(u){if(u===Mf||u===hh)throw Error(r(483))}var hu=!1;function v0(u){u.updateQueue={baseState:u.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Cv(u,f){u=u.updateQueue,f.updateQueue===u&&(f.updateQueue={baseState:u.baseState,firstBaseUpdate:u.firstBaseUpdate,lastBaseUpdate:u.lastBaseUpdate,shared:u.shared,callbacks:null})}function pu(u){return{lane:u,tag:0,payload:null,callback:null,next:null}}function va(u,f,g){var b=u.updateQueue;if(b===null)return null;if(b=b.shared,(vr&2)!==0){var T=b.pending;return T===null?f.next=f:(f.next=T.next,T.next=f),b.pending=f,f=cc(u),nh(u,null,g),f}return Ns(u,b,f,g),cc(u)}function If(u,f,g){if(f=f.updateQueue,f!==null&&(f=f.shared,(g&4194048)!==0)){var b=f.lanes;b&=u.pendingLanes,g|=b,f.lanes=g,Yt(u,g)}}function y0(u,f){var g=u.updateQueue,b=u.alternate;if(b!==null&&(b=b.updateQueue,g===b)){var T=null,D=null;if(g=g.firstBaseUpdate,g!==null){do{var q={lane:g.lane,tag:g.tag,payload:g.payload,callback:null,next:null};D===null?T=D=q:D=D.next=q,g=g.next}while(g!==null);D===null?T=D=f:D=D.next=f}else T=D=f;g={baseState:b.baseState,firstBaseUpdate:T,lastBaseUpdate:D,shared:b.shared,callbacks:b.callbacks},u.updateQueue=g;return}u=g.lastBaseUpdate,u===null?g.firstBaseUpdate=f:u.next=f,g.lastBaseUpdate=f}var Ab=!1;function x0(){if(Ab){var u=ps;if(u!==null)throw u}}function mh(u,f,g,b){Ab=!1;var T=u.updateQueue;hu=!1;var D=T.firstBaseUpdate,q=T.lastBaseUpdate,K=T.shared.pending;if(K!==null){T.shared.pending=null;var ge=K,Be=ge.next;ge.next=null,q===null?D=Be:q.next=Be,q=ge;var Ke=u.alternate;Ke!==null&&(Ke=Ke.updateQueue,K=Ke.lastBaseUpdate,K!==q&&(K===null?Ke.firstBaseUpdate=Be:K.next=Be,Ke.lastBaseUpdate=ge))}if(D!==null){var tt=T.baseState;q=0,Ke=Be=ge=null,K=D;do{var Ne=K.lane&-536870913,je=Ne!==K.lane;if(je?(Kn&Ne)===Ne:(b&Ne)===Ne){Ne!==0&&Ne===gc&&(Ab=!0),Ke!==null&&(Ke=Ke.next={lane:0,tag:K.tag,payload:K.payload,callback:null,next:null});e:{var rn=u,Jt=K;Ne=f;var fr=g;switch(Jt.tag){case 1:if(rn=Jt.payload,typeof rn=="function"){tt=rn.call(fr,tt,Ne);break e}tt=rn;break e;case 3:rn.flags=rn.flags&-65537|128;case 0:if(rn=Jt.payload,Ne=typeof rn=="function"?rn.call(fr,tt,Ne):rn,Ne==null)break e;tt=y({},tt,Ne);break e;case 2:hu=!0}}Ne=K.callback,Ne!==null&&(u.flags|=64,je&&(u.flags|=8192),je=T.callbacks,je===null?T.callbacks=[Ne]:je.push(Ne))}else je={lane:Ne,tag:K.tag,payload:K.payload,callback:K.callback,next:null},Ke===null?(Be=Ke=je,ge=tt):Ke=Ke.next=je,q|=Ne;if(K=K.next,K===null){if(K=T.shared.pending,K===null)break;je=K,K=je.next,je.next=null,T.lastBaseUpdate=je,T.shared.pending=null}}while(!0);Ke===null&&(ge=tt),T.baseState=ge,T.firstBaseUpdate=Be,T.lastBaseUpdate=Ke,D===null&&(T.shared.lanes=0),Ec|=q,u.lanes=q,u.memoizedState=tt}}function vh(u,f){if(typeof u!="function")throw Error(r(191,u));u.call(f)}function Ev(u,f){var g=u.callbacks;if(g!==null)for(u.callbacks=null,u=0;u<g.length;u++)vh(g[u],f)}var gu=P(null),b0=P(0);function kb(u,f){u=Cu,U(b0,u),U(gu,f),Cu=u|f.baseLanes}function Pi(){U(b0,Cu),U(gu,gu.current)}function yh(){Cu=b0.current,ne(gu),ne(b0)}var Hs=0,mn=null,ur=null,si=null,$f=!1,Bf=!1,ya=!1,_0=0,gs=0,xa=null,Av=0;function li(){throw Error(r(321))}function S0(u,f){if(f===null)return!1;for(var g=0;g<f.length&&g<u.length;g++)if(!qo(u[g],f[g]))return!1;return!0}function kv(u,f,g,b,T,D){return Hs=D,mn=f,f.memoizedState=null,f.updateQueue=null,f.lanes=0,ue.H=u===null||u.memoizedState===null?KT:Vb,ya=!1,D=g(b,T),ya=!1,Bf&&(D=mc(f,g,b,T)),Tb(u),D}function Tb(u){ue.H=M0;var f=ur!==null&&ur.next!==null;if(Hs=0,si=ur=mn=null,$f=!1,gs=0,xa=null,f)throw Error(r(300));u===null||Bn||(u=u.dependencies,u!==null&&h0(u)&&(Bn=!0))}function mc(u,f,g,b){mn=u;var T=0;do{if(Bf&&(xa=null),gs=0,Bf=!1,25<=T)throw Error(r(301));if(T+=1,si=ur=null,u.updateQueue!=null){var D=u.updateQueue;D.lastEffect=null,D.events=null,D.stores=null,D.memoCache!=null&&(D.memoCache.index=0)}ue.H=WT,D=f(g,b)}while(Bf);return D}function HT(){var u=ue.H,f=u.useState()[0];return f=typeof f.then=="function"?Lf(f):f,u=u.useState()[0],(ur!==null?ur.memoizedState:null)!==u&&(mn.flags|=1024),f}function Tv(){var u=_0!==0;return _0=0,u}function Rv(u,f,g){f.updateQueue=u.updateQueue,f.flags&=-2053,u.lanes&=~g}function xh(u){if($f){for(u=u.memoizedState;u!==null;){var f=u.queue;f!==null&&(f.pending=null),u=u.next}$f=!1}Hs=0,si=ur=mn=null,Bf=!1,gs=_0=0,xa=null}function Vo(){var u={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return si===null?mn.memoizedState=si=u:si=si.next=u,si}function gi(){if(ur===null){var u=mn.alternate;u=u!==null?u.memoizedState:null}else u=ur.next;var f=si===null?mn.memoizedState:si.next;if(f!==null)si=f,ur=u;else{if(u===null)throw mn.alternate===null?Error(r(467)):Error(r(310));ur=u,u={memoizedState:ur.memoizedState,baseState:ur.baseState,baseQueue:ur.baseQueue,queue:ur.queue,next:null},si===null?mn.memoizedState=si=u:si=si.next=u}return si}function w0(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Lf(u){var f=gs;return gs+=1,xa===null&&(xa=[]),u=Cb(xa,u,f),f=mn,(si===null?f.memoizedState:si.next)===null&&(f=f.alternate,ue.H=f===null||f.memoizedState===null?KT:Vb),u}function Ov(u){if(u!==null&&typeof u=="object"){if(typeof u.then=="function")return Lf(u);if(u.$$typeof===O)return vo(u)}throw Error(r(438,String(u)))}function Hi(u){var f=null,g=mn.updateQueue;if(g!==null&&(f=g.memoCache),f==null){var b=mn.alternate;b!==null&&(b=b.updateQueue,b!==null&&(b=b.memoCache,b!=null&&(f={data:b.data.map(function(T){return T.slice()}),index:0})))}if(f==null&&(f={data:[],index:0}),g===null&&(g=w0(),mn.updateQueue=g),g.memoCache=f,g=f.data[f.index],g===void 0)for(g=f.data[f.index]=Array(u),b=0;b<u;b++)g[b]=z;return f.index++,g}function wl(u,f){return typeof f=="function"?f(u):f}function C0(u){var f=gi();return Dv(f,ur,u)}function Dv(u,f,g){var b=u.queue;if(b===null)throw Error(r(311));b.lastRenderedReducer=g;var T=u.baseQueue,D=b.pending;if(D!==null){if(T!==null){var q=T.next;T.next=D.next,D.next=q}f.baseQueue=T=D,b.pending=null}if(D=u.baseState,T===null)u.memoizedState=D;else{f=T.next;var K=q=null,ge=null,Be=f,Ke=!1;do{var tt=Be.lane&-536870913;if(tt!==Be.lane?(Kn&tt)===tt:(Hs&tt)===tt){var Ne=Be.revertLane;if(Ne===0)ge!==null&&(ge=ge.next={lane:0,revertLane:0,action:Be.action,hasEagerState:Be.hasEagerState,eagerState:Be.eagerState,next:null}),tt===gc&&(Ke=!0);else if((Hs&Ne)===Ne){Be=Be.next,Ne===gc&&(Ke=!0);continue}else tt={lane:0,revertLane:Be.revertLane,action:Be.action,hasEagerState:Be.hasEagerState,eagerState:Be.eagerState,next:null},ge===null?(K=ge=tt,q=D):ge=ge.next=tt,mn.lanes|=Ne,Ec|=Ne;tt=Be.action,ya&&g(D,tt),D=Be.hasEagerState?Be.eagerState:g(D,tt)}else Ne={lane:tt,revertLane:Be.revertLane,action:Be.action,hasEagerState:Be.hasEagerState,eagerState:Be.eagerState,next:null},ge===null?(K=ge=Ne,q=D):ge=ge.next=Ne,mn.lanes|=tt,Ec|=tt;Be=Be.next}while(Be!==null&&Be!==f);if(ge===null?q=D:ge.next=K,!qo(D,u.memoizedState)&&(Bn=!0,Ke&&(g=ps,g!==null)))throw g;u.memoizedState=D,u.baseState=q,u.baseQueue=ge,b.lastRenderedState=D}return T===null&&(b.lanes=0),[u.memoizedState,b.dispatch]}function Mv(u){var f=gi(),g=f.queue;if(g===null)throw Error(r(311));g.lastRenderedReducer=u;var b=g.dispatch,T=g.pending,D=f.memoizedState;if(T!==null){g.pending=null;var q=T=T.next;do D=u(D,q.action),q=q.next;while(q!==T);qo(D,f.memoizedState)||(Bn=!0),f.memoizedState=D,f.baseQueue===null&&(f.baseState=D),g.lastRenderedState=D}return[D,b]}function Rb(u,f,g){var b=mn,T=gi(),D=En;if(D){if(g===void 0)throw Error(r(407));g=g()}else g=f();var q=!qo((ur||T).memoizedState,g);q&&(T.memoizedState=g,Bn=!0),T=T.queue;var K=Ob.bind(null,b,T,u);if(mu(2048,8,K,[u]),T.getSnapshot!==f||q||si!==null&&si.memoizedState.tag&1){if(b.flags|=2048,vc(9,ms(),Iv.bind(null,b,T,g,f),null),kr===null)throw Error(r(349));D||(Hs&124)!==0||E0(b,f,g)}return g}function E0(u,f,g){u.flags|=16384,u={getSnapshot:f,value:g},f=mn.updateQueue,f===null?(f=w0(),mn.updateQueue=f,f.stores=[u]):(g=f.stores,g===null?f.stores=[u]:g.push(u))}function Iv(u,f,g,b){f.value=g,f.getSnapshot=b,Db(f)&&Mb(u)}function Ob(u,f,g){return g(function(){Db(f)&&Mb(u)})}function Db(u){var f=u.getSnapshot;u=u.value;try{var g=f();return!qo(u,g)}catch{return!0}}function Mb(u){var f=lu(u,2);f!==null&&ka(f,u,2)}function A0(u){var f=Vo();if(typeof u=="function"){var g=u;if(u=g(),ya){Ct(!0);try{g()}finally{Ct(!1)}}}return f.memoizedState=f.baseState=u,f.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:wl,lastRenderedState:u},f}function $v(u,f,g,b){return u.baseState=g,Dv(u,ur,typeof b=="function"?b:wl)}function Ib(u,f,g,b,T){if(Sh(u))throw Error(r(485));if(u=f.action,u!==null){var D={payload:T,action:u,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(q){D.listeners.push(q)}};ue.T!==null?g(!0):D.isTransition=!1,b(D),g=f.pending,g===null?(D.next=f.pending=D,$b(f,D)):(D.next=g.next,f.pending=g.next=D)}}function $b(u,f){var g=f.action,b=f.payload,T=u.state;if(f.isTransition){var D=ue.T,q={};ue.T=q;try{var K=g(T,b),ge=ue.S;ge!==null&&ge(q,K),Bv(u,f,K)}catch(Be){T0(u,f,Be)}finally{ue.T=D}}else try{D=g(T,b),Bv(u,f,D)}catch(Be){T0(u,f,Be)}}function Bv(u,f,g){g!==null&&typeof g=="object"&&typeof g.then=="function"?g.then(function(b){k0(u,f,b)},function(b){return T0(u,f,b)}):k0(u,f,g)}function k0(u,f,g){f.status="fulfilled",f.value=g,Bb(f),u.state=g,f=u.pending,f!==null&&(g=f.next,g===f?u.pending=null:(g=g.next,f.next=g,$b(u,g)))}function T0(u,f,g){var b=u.pending;if(u.pending=null,b!==null){b=b.next;do f.status="rejected",f.reason=g,Bb(f),f=f.next;while(f!==b)}u.action=null}function Bb(u){u=u.listeners;for(var f=0;f<u.length;f++)(0,u[f])()}function Lb(u,f){return f}function Lv(u,f){if(En){var g=kr.formState;if(g!==null){e:{var b=mn;if(En){if(Er){t:{for(var T=Er,D=Go;T.nodeType!==8;){if(!D){T=null;break t}if(T=el(T.nextSibling),T===null){T=null;break t}}D=T.data,T=D==="F!"||D==="F"?T:null}if(T){Er=el(T.nextSibling),b=T.data==="F!";break e}}js(b)}b=!1}b&&(f=g[0])}}return g=Vo(),g.memoizedState=g.baseState=f,b={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Lb,lastRenderedState:f},g.queue=b,g=Fv.bind(null,mn,b),b.dispatch=g,b=A0(!1),D=O0.bind(null,mn,!1,b.queue),b=Vo(),T={state:f,dispatch:null,action:u,pending:null},b.queue=T,g=Ib.bind(null,mn,T,D,g),T.dispatch=g,b.memoizedState=u,[f,g,!1]}function Nb(u){var f=gi();return Cl(f,ur,u)}function Cl(u,f,g){if(f=Dv(u,f,Lb)[0],u=C0(wl)[0],typeof f=="object"&&f!==null&&typeof f.then=="function")try{var b=Lf(f)}catch(q){throw q===Mf?hh:q}else b=f;f=gi();var T=f.queue,D=T.dispatch;return g!==f.memoizedState&&(mn.flags|=2048,vc(9,ms(),zb.bind(null,T,g),null)),[b,D,u]}function zb(u,f){u.action=f}function qT(u){var f=gi(),g=ur;if(g!==null)return Cl(f,g,u);gi(),f=f.memoizedState,g=gi();var b=g.queue.dispatch;return g.memoizedState=u,[f,b,!1]}function vc(u,f,g,b){return u={tag:u,create:g,deps:b,inst:f,next:null},f=mn.updateQueue,f===null&&(f=w0(),mn.updateQueue=f),g=f.lastEffect,g===null?f.lastEffect=u.next=u:(b=g.next,g.next=u,u.next=b,f.lastEffect=u),u}function ms(){return{destroy:void 0,resource:void 0}}function Fb(){return gi().memoizedState}function Nf(u,f,g,b){var T=Vo();b=b===void 0?null:b,mn.flags|=u,T.memoizedState=vc(1|f,ms(),g,b)}function mu(u,f,g,b){var T=gi();b=b===void 0?null:b;var D=T.memoizedState.inst;ur!==null&&b!==null&&S0(b,ur.memoizedState.deps)?T.memoizedState=vc(f,D,g,b):(mn.flags|=u,T.memoizedState=vc(1|f,D,g,b))}function Pr(u,f){Nf(8390656,8,u,f)}function GT(u,f){mu(2048,8,u,f)}function VT(u,f){return mu(4,2,u,f)}function Ub(u,f){return mu(4,4,u,f)}function qs(u,f){if(typeof f=="function"){u=u();var g=f(u);return function(){typeof g=="function"?g():f(null)}}if(f!=null)return u=u(),f.current=u,function(){f.current=null}}function jb(u,f,g){g=g!=null?g.concat([u]):null,mu(4,4,qs.bind(null,f,u),g)}function R0(){}function bh(u,f){var g=gi();f=f===void 0?null:f;var b=g.memoizedState;return f!==null&&S0(f,b[1])?b[0]:(g.memoizedState=[u,f],u)}function zf(u,f){var g=gi();f=f===void 0?null:f;var b=g.memoizedState;if(f!==null&&S0(f,b[1]))return b[0];if(b=u(),ya){Ct(!0);try{u()}finally{Ct(!1)}}return g.memoizedState=[b,f],b}function Nv(u,f,g){return g===void 0||(Hs&1073741824)!==0?u.memoizedState=f:(u.memoizedState=g,u=u4(),mn.lanes|=u,Ec|=u,g)}function zv(u,f,g,b){return qo(g,f)?g:gu.current!==null?(u=Nv(u,g,b),qo(u,f)||(Bn=!0),u):(Hs&42)===0?(Bn=!0,u.memoizedState=g):(u=u4(),mn.lanes|=u,Ec|=u,f)}function Pb(u,f,g,b,T){var D=se.p;se.p=D!==0&&8>D?D:8;var q=ue.T,K={};ue.T=K,O0(u,!1,f,g);try{var ge=T(),Be=ue.S;if(Be!==null&&Be(K,ge),ge!==null&&typeof ge=="object"&&typeof ge.then=="function"){var Ke=_b(ge,b);_h(u,f,Ke,Ga(u))}else _h(u,f,b,Ga(u))}catch(tt){_h(u,f,{then:function(){},status:"rejected",reason:tt},Ga())}finally{se.p=D,ue.T=q}}function hM(){}function Hb(u,f,g,b){if(u.tag!==5)throw Error(r(476));var T=qb(u).queue;Pb(u,T,f,pe,g===null?hM:function(){return YT(u),g(b)})}function qb(u){var f=u.memoizedState;if(f!==null)return f;f={memoizedState:pe,baseState:pe,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:wl,lastRenderedState:pe},next:null};var g={};return f.next={memoizedState:g,baseState:g,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:wl,lastRenderedState:g},next:null},u.memoizedState=f,u=u.alternate,u!==null&&(u.memoizedState=f),f}function YT(u){var f=qb(u).next.queue;_h(u,f,{},Ga())}function Ff(){return vo(_o)}function Gs(){return gi().memoizedState}function Gb(){return gi().memoizedState}function pM(u){for(var f=u.return;f!==null;){switch(f.tag){case 24:case 3:var g=Ga();u=pu(g);var b=va(f,u,g);b!==null&&(ka(b,f,g),If(b,f,g)),f={cache:bb()},u.payload=f;return}f=f.return}}function ZT(u,f,g){var b=Ga();g={lane:b,revertLane:0,action:g,hasEagerState:!1,eagerState:null,next:null},Sh(u)?D0(f,g):(g=Rf(u,f,g,b),g!==null&&(ka(g,u,b),QT(g,f,b)))}function Fv(u,f,g){var b=Ga();_h(u,f,g,b)}function _h(u,f,g,b){var T={lane:b,revertLane:0,action:g,hasEagerState:!1,eagerState:null,next:null};if(Sh(u))D0(f,T);else{var D=u.alternate;if(u.lanes===0&&(D===null||D.lanes===0)&&(D=f.lastRenderedReducer,D!==null))try{var q=f.lastRenderedState,K=D(q,g);if(T.hasEagerState=!0,T.eagerState=K,qo(K,q))return Ns(u,f,T,0),kr===null&&Ls(),!1}catch{}finally{}if(g=Rf(u,f,T,b),g!==null)return ka(g,u,b),QT(g,f,b),!0}return!1}function O0(u,f,g,b){if(b={lane:2,revertLane:fy(),action:b,hasEagerState:!1,eagerState:null,next:null},Sh(u)){if(f)throw Error(r(479))}else f=Rf(u,g,b,2),f!==null&&ka(f,u,2)}function Sh(u){var f=u.alternate;return u===mn||f!==null&&f===mn}function D0(u,f){Bf=$f=!0;var g=u.pending;g===null?f.next=f:(f.next=g.next,g.next=f),u.pending=f}function QT(u,f,g){if((g&4194048)!==0){var b=f.lanes;b&=u.pendingLanes,g|=b,f.lanes=g,Yt(u,g)}}var M0={readContext:vo,use:Ov,useCallback:li,useContext:li,useEffect:li,useImperativeHandle:li,useLayoutEffect:li,useInsertionEffect:li,useMemo:li,useReducer:li,useRef:li,useState:li,useDebugValue:li,useDeferredValue:li,useTransition:li,useSyncExternalStore:li,useId:li,useHostTransitionStatus:li,useFormState:li,useActionState:li,useOptimistic:li,useMemoCache:li,useCacheRefresh:li},KT={readContext:vo,use:Ov,useCallback:function(u,f){return Vo().memoizedState=[u,f===void 0?null:f],u},useContext:vo,useEffect:Pr,useImperativeHandle:function(u,f,g){g=g!=null?g.concat([u]):null,Nf(4194308,4,qs.bind(null,f,u),g)},useLayoutEffect:function(u,f){return Nf(4194308,4,u,f)},useInsertionEffect:function(u,f){Nf(4,2,u,f)},useMemo:function(u,f){var g=Vo();f=f===void 0?null:f;var b=u();if(ya){Ct(!0);try{u()}finally{Ct(!1)}}return g.memoizedState=[b,f],b},useReducer:function(u,f,g){var b=Vo();if(g!==void 0){var T=g(f);if(ya){Ct(!0);try{g(f)}finally{Ct(!1)}}}else T=f;return b.memoizedState=b.baseState=T,u={pending:null,lanes:0,dispatch:null,lastRenderedReducer:u,lastRenderedState:T},b.queue=u,u=u.dispatch=ZT.bind(null,mn,u),[b.memoizedState,u]},useRef:function(u){var f=Vo();return u={current:u},f.memoizedState=u},useState:function(u){u=A0(u);var f=u.queue,g=Fv.bind(null,mn,f);return f.dispatch=g,[u.memoizedState,g]},useDebugValue:R0,useDeferredValue:function(u,f){var g=Vo();return Nv(g,u,f)},useTransition:function(){var u=A0(!1);return u=Pb.bind(null,mn,u.queue,!0,!1),Vo().memoizedState=u,[!1,u]},useSyncExternalStore:function(u,f,g){var b=mn,T=Vo();if(En){if(g===void 0)throw Error(r(407));g=g()}else{if(g=f(),kr===null)throw Error(r(349));(Kn&124)!==0||E0(b,f,g)}T.memoizedState=g;var D={value:g,getSnapshot:f};return T.queue=D,Pr(Ob.bind(null,b,D,u),[u]),b.flags|=2048,vc(9,ms(),Iv.bind(null,b,D,g,f),null),g},useId:function(){var u=Vo(),f=kr.identifierPrefix;if(En){var g=Us,b=Fs;g=(b&~(1<<32-ct(b)-1)).toString(32)+g,f="Β«"+f+"R"+g,g=_0++,0<g&&(f+="H"+g.toString(32)),f+="Β»"}else g=Av++,f="Β«"+f+"r"+g.toString(32)+"Β»";return u.memoizedState=f},useHostTransitionStatus:Ff,useFormState:Lv,useActionState:Lv,useOptimistic:function(u){var f=Vo();f.memoizedState=f.baseState=u;var g={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return f.queue=g,f=O0.bind(null,mn,!0,g),g.dispatch=f,[u,f]},useMemoCache:Hi,useCacheRefresh:function(){return Vo().memoizedState=pM.bind(null,mn)}},Vb={readContext:vo,use:Ov,useCallback:bh,useContext:vo,useEffect:GT,useImperativeHandle:jb,useInsertionEffect:VT,useLayoutEffect:Ub,useMemo:zf,useReducer:C0,useRef:Fb,useState:function(){return C0(wl)},useDebugValue:R0,useDeferredValue:function(u,f){var g=gi();return zv(g,ur.memoizedState,u,f)},useTransition:function(){var u=C0(wl)[0],f=gi().memoizedState;return[typeof u=="boolean"?u:Lf(u),f]},useSyncExternalStore:Rb,useId:Gs,useHostTransitionStatus:Ff,useFormState:Nb,useActionState:Nb,useOptimistic:function(u,f){var g=gi();return $v(g,ur,u,f)},useMemoCache:Hi,useCacheRefresh:Gb},WT={readContext:vo,use:Ov,useCallback:bh,useContext:vo,useEffect:GT,useImperativeHandle:jb,useInsertionEffect:VT,useLayoutEffect:Ub,useMemo:zf,useReducer:Mv,useRef:Fb,useState:function(){return Mv(wl)},useDebugValue:R0,useDeferredValue:function(u,f){var g=gi();return ur===null?Nv(g,u,f):zv(g,ur.memoizedState,u,f)},useTransition:function(){var u=Mv(wl)[0],f=gi().memoizedState;return[typeof u=="boolean"?u:Lf(u),f]},useSyncExternalStore:Rb,useId:Gs,useHostTransitionStatus:Ff,useFormState:qT,useActionState:qT,useOptimistic:function(u,f){var g=gi();return ur!==null?$v(g,ur,u,f):(g.baseState=u,[u,g.queue.dispatch])},useMemoCache:Hi,useCacheRefresh:Gb},ba=null,wh=0;function I0(u){var f=wh;return wh+=1,ba===null&&(ba=[]),Cb(ba,u,f)}function $0(u,f){f=f.props.ref,u.ref=f!==void 0?f:null}function Ch(u,f){throw f.$$typeof===m?Error(r(525)):(u=Object.prototype.toString.call(f),Error(r(31,u==="[object Object]"?"object with keys {"+Object.keys(f).join(", ")+"}":u)))}function _a(u){var f=u._init;return f(u._payload)}function Yb(u){function f(De,Se){if(u){var Le=De.deletions;Le===null?(De.deletions=[Se],De.flags|=16):Le.push(Se)}}function g(De,Se){if(!u)return null;for(;Se!==null;)f(De,Se),Se=Se.sibling;return null}function b(De){for(var Se=new Map;De!==null;)De.key!==null?Se.set(De.key,De):Se.set(De.index,De),De=De.sibling;return Se}function T(De,Se){return De=zs(De,Se),De.index=0,De.sibling=null,De}function D(De,Se,Le){return De.index=Le,u?(Le=De.alternate,Le!==null?(Le=Le.index,Le<Se?(De.flags|=67108866,Se):Le):(De.flags|=67108866,Se)):(De.flags|=1048576,Se)}function q(De){return u&&De.alternate===null&&(De.flags|=67108866),De}function K(De,Se,Le,et){return Se===null||Se.tag!==6?(Se=fc(Le,De.mode,et),Se.return=De,Se):(Se=T(Se,Le),Se.return=De,Se)}function ge(De,Se,Le,et){var Ut=Le.type;return Ut===w?Ke(De,Se,Le.props.children,et,Le.key):Se!==null&&(Se.elementType===Ut||typeof Ut=="object"&&Ut!==null&&Ut.$$typeof===V&&_a(Ut)===Se.type)?(Se=T(Se,Le.props),$0(Se,Le),Se.return=De,Se):(Se=Cn(Le.type,Le.key,Le.props,null,De.mode,et),$0(Se,Le),Se.return=De,Se)}function Be(De,Se,Le,et){return Se===null||Se.tag!==4||Se.stateNode.containerInfo!==Le.containerInfo||Se.stateNode.implementation!==Le.implementation?(Se=rh(Le,De.mode,et),Se.return=De,Se):(Se=T(Se,Le.children||[]),Se.return=De,Se)}function Ke(De,Se,Le,et,Ut){return Se===null||Se.tag!==7?(Se=ut(Le,De.mode,et,Ut),Se.return=De,Se):(Se=T(Se,Le),Se.return=De,Se)}function tt(De,Se,Le){if(typeof Se=="string"&&Se!==""||typeof Se=="number"||typeof Se=="bigint")return Se=fc(""+Se,De.mode,Le),Se.return=De,Se;if(typeof Se=="object"&&Se!==null){switch(Se.$$typeof){case x:return Le=Cn(Se.type,Se.key,Se.props,null,De.mode,Le),$0(Le,Se),Le.return=De,Le;case _:return Se=rh(Se,De.mode,Le),Se.return=De,Se;case V:var et=Se._init;return Se=et(Se._payload),tt(De,Se,Le)}if(de(Se)||J(Se))return Se=ut(Se,De.mode,Le,null),Se.return=De,Se;if(typeof Se.then=="function")return tt(De,I0(Se),Le);if(Se.$$typeof===O)return tt(De,lh(De,Se),Le);Ch(De,Se)}return null}function Ne(De,Se,Le,et){var Ut=Se!==null?Se.key:null;if(typeof Le=="string"&&Le!==""||typeof Le=="number"||typeof Le=="bigint")return Ut!==null?null:K(De,Se,""+Le,et);if(typeof Le=="object"&&Le!==null){switch(Le.$$typeof){case x:return Le.key===Ut?ge(De,Se,Le,et):null;case _:return Le.key===Ut?Be(De,Se,Le,et):null;case V:return Ut=Le._init,Le=Ut(Le._payload),Ne(De,Se,Le,et)}if(de(Le)||J(Le))return Ut!==null?null:Ke(De,Se,Le,et,null);if(typeof Le.then=="function")return Ne(De,Se,I0(Le),et);if(Le.$$typeof===O)return Ne(De,Se,lh(De,Le),et);Ch(De,Le)}return null}function je(De,Se,Le,et,Ut){if(typeof et=="string"&&et!==""||typeof et=="number"||typeof et=="bigint")return De=De.get(Le)||null,K(Se,De,""+et,Ut);if(typeof et=="object"&&et!==null){switch(et.$$typeof){case x:return De=De.get(et.key===null?Le:et.key)||null,ge(Se,De,et,Ut);case _:return De=De.get(et.key===null?Le:et.key)||null,Be(Se,De,et,Ut);case V:var An=et._init;return et=An(et._payload),je(De,Se,Le,et,Ut)}if(de(et)||J(et))return De=De.get(Le)||null,Ke(Se,De,et,Ut,null);if(typeof et.then=="function")return je(De,Se,Le,I0(et),Ut);if(et.$$typeof===O)return je(De,Se,Le,lh(Se,et),Ut);Ch(Se,et)}return null}function rn(De,Se,Le,et){for(var Ut=null,An=null,Wt=Se,sn=Se=0,so=null;Wt!==null&&sn<Le.length;sn++){Wt.index>sn?(so=Wt,Wt=null):so=Wt.sibling;var ar=Ne(De,Wt,Le[sn],et);if(ar===null){Wt===null&&(Wt=so);break}u&&Wt&&ar.alternate===null&&f(De,Wt),Se=D(ar,Se,sn),An===null?Ut=ar:An.sibling=ar,An=ar,Wt=so}if(sn===Le.length)return g(De,Wt),En&&Di(De,sn),Ut;if(Wt===null){for(;sn<Le.length;sn++)Wt=tt(De,Le[sn],et),Wt!==null&&(Se=D(Wt,Se,sn),An===null?Ut=Wt:An.sibling=Wt,An=Wt);return En&&Di(De,sn),Ut}for(Wt=b(Wt);sn<Le.length;sn++)so=je(Wt,De,sn,Le[sn],et),so!==null&&(u&&so.alternate!==null&&Wt.delete(so.key===null?sn:so.key),Se=D(so,Se,sn),An===null?Ut=so:An.sibling=so,An=so);return u&&Wt.forEach(function(Il){return f(De,Il)}),En&&Di(De,sn),Ut}function Jt(De,Se,Le,et){if(Le==null)throw Error(r(151));for(var Ut=null,An=null,Wt=Se,sn=Se=0,so=null,ar=Le.next();Wt!==null&&!ar.done;sn++,ar=Le.next()){Wt.index>sn?(so=Wt,Wt=null):so=Wt.sibling;var Il=Ne(De,Wt,ar.value,et);if(Il===null){Wt===null&&(Wt=so);break}u&&Wt&&Il.alternate===null&&f(De,Wt),Se=D(Il,Se,sn),An===null?Ut=Il:An.sibling=Il,An=Il,Wt=so}if(ar.done)return g(De,Wt),En&&Di(De,sn),Ut;if(Wt===null){for(;!ar.done;sn++,ar=Le.next())ar=tt(De,ar.value,et),ar!==null&&(Se=D(ar,Se,sn),An===null?Ut=ar:An.sibling=ar,An=ar);return En&&Di(De,sn),Ut}for(Wt=b(Wt);!ar.done;sn++,ar=Le.next())ar=je(Wt,De,sn,ar.value,et),ar!==null&&(u&&ar.alternate!==null&&Wt.delete(ar.key===null?sn:ar.key),Se=D(ar,Se,sn),An===null?Ut=ar:An.sibling=ar,An=ar);return u&&Wt.forEach(function(CM){return f(De,CM)}),En&&Di(De,sn),Ut}function fr(De,Se,Le,et){if(typeof Le=="object"&&Le!==null&&Le.type===w&&Le.key===null&&(Le=Le.props.children),typeof Le=="object"&&Le!==null){switch(Le.$$typeof){case x:e:{for(var Ut=Le.key;Se!==null;){if(Se.key===Ut){if(Ut=Le.type,Ut===w){if(Se.tag===7){g(De,Se.sibling),et=T(Se,Le.props.children),et.return=De,De=et;break e}}else if(Se.elementType===Ut||typeof Ut=="object"&&Ut!==null&&Ut.$$typeof===V&&_a(Ut)===Se.type){g(De,Se.sibling),et=T(Se,Le.props),$0(et,Le),et.return=De,De=et;break e}g(De,Se);break}else f(De,Se);Se=Se.sibling}Le.type===w?(et=ut(Le.props.children,De.mode,et,Le.key),et.return=De,De=et):(et=Cn(Le.type,Le.key,Le.props,null,De.mode,et),$0(et,Le),et.return=De,De=et)}return q(De);case _:e:{for(Ut=Le.key;Se!==null;){if(Se.key===Ut)if(Se.tag===4&&Se.stateNode.containerInfo===Le.containerInfo&&Se.stateNode.implementation===Le.implementation){g(De,Se.sibling),et=T(Se,Le.children||[]),et.return=De,De=et;break e}else{g(De,Se);break}else f(De,Se);Se=Se.sibling}et=rh(Le,De.mode,et),et.return=De,De=et}return q(De);case V:return Ut=Le._init,Le=Ut(Le._payload),fr(De,Se,Le,et)}if(de(Le))return rn(De,Se,Le,et);if(J(Le)){if(Ut=J(Le),typeof Ut!="function")throw Error(r(150));return Le=Ut.call(Le),Jt(De,Se,Le,et)}if(typeof Le.then=="function")return fr(De,Se,I0(Le),et);if(Le.$$typeof===O)return fr(De,Se,lh(De,Le),et);Ch(De,Le)}return typeof Le=="string"&&Le!==""||typeof Le=="number"||typeof Le=="bigint"?(Le=""+Le,Se!==null&&Se.tag===6?(g(De,Se.sibling),et=T(Se,Le),et.return=De,De=et):(g(De,Se),et=fc(Le,De.mode,et),et.return=De,De=et),q(De)):g(De,Se)}return function(De,Se,Le,et){try{wh=0;var Ut=fr(De,Se,Le,et);return ba=null,Ut}catch(Wt){if(Wt===Mf||Wt===hh)throw Wt;var An=pa(29,Wt,null,De.mode);return An.lanes=et,An.return=De,An}finally{}}}var no=Yb(!0),Zb=Yb(!1),Ii=P(null),Vs=null;function Sa(u){var f=u.alternate;U(_i,_i.current&1),U(Ii,u),Vs===null&&(f===null||gu.current!==null||f.memoizedState!==null)&&(Vs=u)}function Qb(u){if(u.tag===22){if(U(_i,_i.current),U(Ii,u),Vs===null){var f=u.alternate;f!==null&&f.memoizedState!==null&&(Vs=u)}}else Mo()}function Mo(){U(_i,_i.current),U(Ii,Ii.current)}function Ys(u){ne(Ii),Vs===u&&(Vs=null),ne(_i)}var _i=P(0);function ja(u){for(var f=u;f!==null;){if(f.tag===13){var g=f.memoizedState;if(g!==null&&(g=g.dehydrated,g===null||g.data==="$?"||B_(g)))return f}else if(f.tag===19&&f.memoizedProps.revealOrder!==void 0){if((f.flags&128)!==0)return f}else if(f.child!==null){f.child.return=f,f=f.child;continue}if(f===u)break;for(;f.sibling===null;){if(f.return===null||f.return===u)return null;f=f.return}f.sibling.return=f.return,f=f.sibling}return null}function Uv(u,f,g,b){f=u.memoizedState,g=g(b,f),g=g==null?f:y({},f,g),u.memoizedState=g,u.lanes===0&&(u.updateQueue.baseState=g)}var yc={enqueueSetState:function(u,f,g){u=u._reactInternals;var b=Ga(),T=pu(b);T.payload=f,g!=null&&(T.callback=g),f=va(u,T,b),f!==null&&(ka(f,u,b),If(f,u,b))},enqueueReplaceState:function(u,f,g){u=u._reactInternals;var b=Ga(),T=pu(b);T.tag=1,T.payload=f,g!=null&&(T.callback=g),f=va(u,T,b),f!==null&&(ka(f,u,b),If(f,u,b))},enqueueForceUpdate:function(u,f){u=u._reactInternals;var g=Ga(),b=pu(g);b.tag=2,f!=null&&(b.callback=f),f=va(u,b,g),f!==null&&(ka(f,u,g),If(f,u,g))}};function Kb(u,f,g,b,T,D,q){return u=u.stateNode,typeof u.shouldComponentUpdate=="function"?u.shouldComponentUpdate(b,D,q):f.prototype&&f.prototype.isPureReactComponent?!au(g,b)||!au(T,D):!0}function Eh(u,f,g,b){u=f.state,typeof f.componentWillReceiveProps=="function"&&f.componentWillReceiveProps(g,b),typeof f.UNSAFE_componentWillReceiveProps=="function"&&f.UNSAFE_componentWillReceiveProps(g,b),f.state!==u&&yc.enqueueReplaceState(f,f.state,null)}function vs(u,f){var g=f;if("ref"in f){g={};for(var b in f)b!=="ref"&&(g[b]=f[b])}if(u=u.defaultProps){g===f&&(g=y({},g));for(var T in u)g[T]===void 0&&(g[T]=u[T])}return g}var B0=typeof reportError=="function"?reportError:function(u){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var f=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof u=="object"&&u!==null&&typeof u.message=="string"?String(u.message):String(u),error:u});if(!window.dispatchEvent(f))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",u);return}console.error(u)};function Wb(u){B0(u)}function Ah(u){console.error(u)}function Xb(u){B0(u)}function Uf(u,f){try{var g=u.onUncaughtError;g(f.value,{componentStack:f.stack})}catch(b){setTimeout(function(){throw b})}}function Jb(u,f,g){try{var b=u.onCaughtError;b(g.value,{componentStack:g.stack,errorBoundary:f.tag===1?f.stateNode:null})}catch(T){setTimeout(function(){throw T})}}function jv(u,f,g){return g=pu(g),g.tag=3,g.payload={element:null},g.callback=function(){Uf(u,f)},g}function XT(u){return u=pu(u),u.tag=3,u}function e_(u,f,g,b){var T=g.type.getDerivedStateFromError;if(typeof T=="function"){var D=b.value;u.payload=function(){return T(D)},u.callback=function(){Jb(f,g,b)}}var q=g.stateNode;q!==null&&typeof q.componentDidCatch=="function"&&(u.callback=function(){Jb(f,g,b),typeof T!="function"&&(El===null?El=new Set([this]):El.add(this));var K=b.stack;this.componentDidCatch(b.value,{componentStack:K!==null?K:""})})}function Pa(u,f,g,b,T){if(g.flags|=32768,b!==null&&typeof b=="object"&&typeof b.then=="function"){if(f=g.alternate,f!==null&&d0(f,g,T,!0),g=Ii.current,g!==null){switch(g.tag){case 13:return Vs===null?Rc():g.alternate===null&&vi===0&&(vi=3),g.flags&=-257,g.flags|=65536,g.lanes=T,b===Sv?g.flags|=16384:(f=g.updateQueue,f===null?g.updateQueue=new Set([b]):f.add(b),H0(u,b,T)),!1;case 22:return g.flags|=65536,b===Sv?g.flags|=16384:(f=g.updateQueue,f===null?(f={transitions:null,markerInstances:null,retryQueue:new Set([b])},g.updateQueue=f):(g=f.retryQueue,g===null?f.retryQueue=new Set([b]):g.add(b)),H0(u,b,T)),!1}throw Error(r(435,g.tag))}return H0(u,b,T),Rc(),!1}if(En)return f=Ii.current,f!==null?((f.flags&65536)===0&&(f.flags|=256),f.flags|=65536,f.lanes=T,b!==c0&&(u=Error(r(422),{cause:b}),sh(Fa(u,g)))):(b!==c0&&(f=Error(r(423),{cause:b}),sh(Fa(f,g))),u=u.current.alternate,u.flags|=65536,T&=-T,u.lanes|=T,b=Fa(b,g),T=jv(u.stateNode,b,T),y0(u,T),vi!==4&&(vi=2)),!1;var D=Error(r(520),{cause:b});if(D=Fa(D,g),U0===null?U0=[D]:U0.push(D),vi!==4&&(vi=2),f===null)return!0;b=Fa(b,g),g=f;do{switch(g.tag){case 3:return g.flags|=65536,u=T&-T,g.lanes|=u,u=jv(g.stateNode,b,u),y0(g,u),!1;case 1:if(f=g.type,D=g.stateNode,(g.flags&128)===0&&(typeof f.getDerivedStateFromError=="function"||D!==null&&typeof D.componentDidCatch=="function"&&(El===null||!El.has(D))))return g.flags|=65536,T&=-T,g.lanes|=T,T=XT(T),e_(T,u,g,b),y0(g,T),!1}g=g.return}while(g!==null);return!1}var t_=Error(r(461)),Bn=!1;function ro(u,f,g,b){f.child=u===null?Zb(f,null,g,b):no(f,u.child,g,b)}function n_(u,f,g,b,T){g=g.render;var D=f.ref;if("ref"in b){var q={};for(var K in b)K!=="ref"&&(q[K]=b[K])}else q=b;return hc(f),b=kv(u,f,g,q,D,T),K=Tv(),u!==null&&!Bn?(Rv(u,f,T),Zs(u,f,T)):(En&&K&&u0(f),f.flags|=1,ro(u,f,b,T),f.child)}function JT(u,f,g,b,T){if(u===null){var D=g.type;return typeof D=="function"&&!gv(D)&&D.defaultProps===void 0&&g.compare===null?(f.tag=15,f.type=D,vu(u,f,D,b,T)):(u=Cn(g.type,null,b,f,f.mode,T),u.ref=f.ref,u.return=f,f.child=u)}if(D=u.child,!Yv(u,T)){var q=D.memoizedProps;if(g=g.compare,g=g!==null?g:au,g(q,b)&&u.ref===f.ref)return Zs(u,f,T)}return f.flags|=1,u=zs(D,b),u.ref=f.ref,u.return=f,f.child=u}function vu(u,f,g,b,T){if(u!==null){var D=u.memoizedProps;if(au(D,b)&&u.ref===f.ref)if(Bn=!1,f.pendingProps=b=D,Yv(u,T))(u.flags&131072)!==0&&(Bn=!0);else return f.lanes=u.lanes,Zs(u,f,T)}return Hv(u,f,g,b,T)}function jf(u,f,g){var b=f.pendingProps,T=b.children,D=u!==null?u.memoizedState:null;if(b.mode==="hidden"){if((f.flags&128)!==0){if(b=D!==null?D.baseLanes|g:g,u!==null){for(T=f.child=u.child,D=0;T!==null;)D=D|T.lanes|T.childLanes,T=T.sibling;f.childLanes=D&~b}else f.childLanes=0,f.child=null;return Pv(u,f,b,g)}if((g&536870912)!==0)f.memoizedState={baseLanes:0,cachePool:null},u!==null&&dh(f,D!==null?D.cachePool:null),D!==null?kb(f,D):Pi(),Qb(f);else return f.lanes=f.childLanes=536870912,Pv(u,f,D!==null?D.baseLanes|g:g,g)}else D!==null?(dh(f,D.cachePool),kb(f,D),Mo(),f.memoizedState=null):(u!==null&&dh(f,null),Pi(),Mo());return ro(u,f,T,g),f.child}function Pv(u,f,g,b){var T=fh();return T=T===null?null:{parent:Mi._currentValue,pool:T},f.memoizedState={baseLanes:g,cachePool:T},u!==null&&dh(f,null),Pi(),Qb(f),u!==null&&d0(u,f,b,!0),null}function yu(u,f){var g=f.ref;if(g===null)u!==null&&u.ref!==null&&(f.flags|=4194816);else{if(typeof g!="function"&&typeof g!="object")throw Error(r(284));(u===null||u.ref!==g)&&(f.flags|=4194816)}}function Hv(u,f,g,b,T){return hc(f),g=kv(u,f,g,b,void 0,T),b=Tv(),u!==null&&!Bn?(Rv(u,f,T),Zs(u,f,T)):(En&&b&&u0(f),f.flags|=1,ro(u,f,g,T),f.child)}function r_(u,f,g,b,T,D){return hc(f),f.updateQueue=null,g=mc(f,b,g,T),Tb(u),b=Tv(),u!==null&&!Bn?(Rv(u,f,D),Zs(u,f,D)):(En&&b&&u0(f),f.flags|=1,ro(u,f,g,D),f.child)}function i_(u,f,g,b,T){if(hc(f),f.stateNode===null){var D=Of,q=g.contextType;typeof q=="object"&&q!==null&&(D=vo(q)),D=new g(b,D),f.memoizedState=D.state!==null&&D.state!==void 0?D.state:null,D.updater=yc,f.stateNode=D,D._reactInternals=f,D=f.stateNode,D.props=b,D.state=f.memoizedState,D.refs={},v0(f),q=g.contextType,D.context=typeof q=="object"&&q!==null?vo(q):Of,D.state=f.memoizedState,q=g.getDerivedStateFromProps,typeof q=="function"&&(Uv(f,g,q,b),D.state=f.memoizedState),typeof g.getDerivedStateFromProps=="function"||typeof D.getSnapshotBeforeUpdate=="function"||typeof D.UNSAFE_componentWillMount!="function"&&typeof D.componentWillMount!="function"||(q=D.state,typeof D.componentWillMount=="function"&&D.componentWillMount(),typeof D.UNSAFE_componentWillMount=="function"&&D.UNSAFE_componentWillMount(),q!==D.state&&yc.enqueueReplaceState(D,D.state,null),mh(f,b,D,T),x0(),D.state=f.memoizedState),typeof D.componentDidMount=="function"&&(f.flags|=4194308),b=!0}else if(u===null){D=f.stateNode;var K=f.memoizedProps,ge=vs(g,K);D.props=ge;var Be=D.context,Ke=g.contextType;q=Of,typeof Ke=="object"&&Ke!==null&&(q=vo(Ke));var tt=g.getDerivedStateFromProps;Ke=typeof tt=="function"||typeof D.getSnapshotBeforeUpdate=="function",K=f.pendingProps!==K,Ke||typeof D.UNSAFE_componentWillReceiveProps!="function"&&typeof D.componentWillReceiveProps!="function"||(K||Be!==q)&&Eh(f,D,b,q),hu=!1;var Ne=f.memoizedState;D.state=Ne,mh(f,b,D,T),x0(),Be=f.memoizedState,K||Ne!==Be||hu?(typeof tt=="function"&&(Uv(f,g,tt,b),Be=f.memoizedState),(ge=hu||Kb(f,g,ge,b,Ne,Be,q))?(Ke||typeof D.UNSAFE_componentWillMount!="function"&&typeof D.componentWillMount!="function"||(typeof D.componentWillMount=="function"&&D.componentWillMount(),typeof D.UNSAFE_componentWillMount=="function"&&D.UNSAFE_componentWillMount()),typeof D.componentDidMount=="function"&&(f.flags|=4194308)):(typeof D.componentDidMount=="function"&&(f.flags|=4194308),f.memoizedProps=b,f.memoizedState=Be),D.props=b,D.state=Be,D.context=q,b=ge):(typeof D.componentDidMount=="function"&&(f.flags|=4194308),b=!1)}else{D=f.stateNode,Cv(u,f),q=f.memoizedProps,Ke=vs(g,q),D.props=Ke,tt=f.pendingProps,Ne=D.context,Be=g.contextType,ge=Of,typeof Be=="object"&&Be!==null&&(ge=vo(Be)),K=g.getDerivedStateFromProps,(Be=typeof K=="function"||typeof D.getSnapshotBeforeUpdate=="function")||typeof D.UNSAFE_componentWillReceiveProps!="function"&&typeof D.componentWillReceiveProps!="function"||(q!==tt||Ne!==ge)&&Eh(f,D,b,ge),hu=!1,Ne=f.memoizedState,D.state=Ne,mh(f,b,D,T),x0();var je=f.memoizedState;q!==tt||Ne!==je||hu||u!==null&&u.dependencies!==null&&h0(u.dependencies)?(typeof K=="function"&&(Uv(f,g,K,b),je=f.memoizedState),(Ke=hu||Kb(f,g,Ke,b,Ne,je,ge)||u!==null&&u.dependencies!==null&&h0(u.dependencies))?(Be||typeof D.UNSAFE_componentWillUpdate!="function"&&typeof D.componentWillUpdate!="function"||(typeof D.componentWillUpdate=="function"&&D.componentWillUpdate(b,je,ge),typeof D.UNSAFE_componentWillUpdate=="function"&&D.UNSAFE_componentWillUpdate(b,je,ge)),typeof D.componentDidUpdate=="function"&&(f.flags|=4),typeof D.getSnapshotBeforeUpdate=="function"&&(f.flags|=1024)):(typeof D.componentDidUpdate!="function"||q===u.memoizedProps&&Ne===u.memoizedState||(f.flags|=4),typeof D.getSnapshotBeforeUpdate!="function"||q===u.memoizedProps&&Ne===u.memoizedState||(f.flags|=1024),f.memoizedProps=b,f.memoizedState=je),D.props=b,D.state=je,D.context=ge,b=Ke):(typeof D.componentDidUpdate!="function"||q===u.memoizedProps&&Ne===u.memoizedState||(f.flags|=4),typeof D.getSnapshotBeforeUpdate!="function"||q===u.memoizedProps&&Ne===u.memoizedState||(f.flags|=1024),b=!1)}return D=b,yu(u,f),b=(f.flags&128)!==0,D||b?(D=f.stateNode,g=b&&typeof g.getDerivedStateFromError!="function"?null:D.render(),f.flags|=1,u!==null&&b?(f.child=no(f,u.child,null,T),f.child=no(f,null,g,T)):ro(u,f,g,T),f.memoizedState=D.state,u=f.child):u=Zs(u,f,T),u}function qv(u,f,g,b){return ah(),f.flags|=256,ro(u,f,g,b),f.child}var L0={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Gv(u){return{baseLanes:u,cachePool:g0()}}function o_(u,f,g){return u=u!==null?u.childLanes&~g:0,f&&(u|=qi),u}function e4(u,f,g){var b=f.pendingProps,T=!1,D=(f.flags&128)!==0,q;if((q=D)||(q=u!==null&&u.memoizedState===null?!1:(_i.current&2)!==0),q&&(T=!0,f.flags&=-129),q=(f.flags&32)!==0,f.flags&=-33,u===null){if(En){if(T?Sa(f):Mo(),En){var K=Er,ge;if(ge=K){e:{for(ge=K,K=Go;ge.nodeType!==8;){if(!K){K=null;break e}if(ge=el(ge.nextSibling),ge===null){K=null;break e}}K=ge}K!==null?(f.memoizedState={dehydrated:K,treeContext:uu!==null?{id:Fs,overflow:Us}:null,retryLane:536870912,hydrationErrors:null},ge=pa(18,null,null,0),ge.stateNode=K,ge.return=f,f.child=ge,pi=f,Er=null,ge=!0):ge=!1}ge||js(f)}if(K=f.memoizedState,K!==null&&(K=K.dehydrated,K!==null))return B_(K)?f.lanes=32:f.lanes=536870912,null;Ys(f)}return K=b.children,b=b.fallback,T?(Mo(),T=f.mode,K=N0({mode:"hidden",children:K},T),b=ut(b,T,g,null),K.return=f,b.return=f,K.sibling=b,f.child=K,T=f.child,T.memoizedState=Gv(g),T.childLanes=o_(u,q,g),f.memoizedState=L0,b):(Sa(f),Vv(f,K))}if(ge=u.memoizedState,ge!==null&&(K=ge.dehydrated,K!==null)){if(D)f.flags&256?(Sa(f),f.flags&=-257,f=a_(u,f,g)):f.memoizedState!==null?(Mo(),f.child=u.child,f.flags|=128,f=null):(Mo(),T=b.fallback,K=f.mode,b=N0({mode:"visible",children:b.children},K),T=ut(T,K,g,null),T.flags|=2,b.return=f,T.return=f,b.sibling=T,f.child=b,no(f,u.child,null,g),b=f.child,b.memoizedState=Gv(g),b.childLanes=o_(u,q,g),f.memoizedState=L0,f=T);else if(Sa(f),B_(K)){if(q=K.nextSibling&&K.nextSibling.dataset,q)var Be=q.dgst;q=Be,b=Error(r(419)),b.stack="",b.digest=q,sh({value:b,source:null,stack:null}),f=a_(u,f,g)}else if(Bn||d0(u,f,g,!1),q=(g&u.childLanes)!==0,Bn||q){if(q=kr,q!==null&&(b=g&-g,b=(b&42)!==0?1:qt(b),b=(b&(q.suspendedLanes|g))!==0?0:b,b!==0&&b!==ge.retryLane))throw ge.retryLane=b,lu(u,b),ka(q,u,b),t_;K.data==="$?"||Rc(),f=a_(u,f,g)}else K.data==="$?"?(f.flags|=192,f.child=u.child,f=null):(u=ge.treeContext,Er=el(K.nextSibling),pi=f,En=!0,cu=null,Go=!1,u!==null&&(ga[hs++]=Fs,ga[hs++]=Us,ga[hs++]=uu,Fs=u.id,Us=u.overflow,uu=f),f=Vv(f,b.children),f.flags|=4096);return f}return T?(Mo(),T=b.fallback,K=f.mode,ge=u.child,Be=ge.sibling,b=zs(ge,{mode:"hidden",children:b.children}),b.subtreeFlags=ge.subtreeFlags&65011712,Be!==null?T=zs(Be,T):(T=ut(T,K,g,null),T.flags|=2),T.return=f,b.return=f,b.sibling=T,f.child=b,b=T,T=f.child,K=u.child.memoizedState,K===null?K=Gv(g):(ge=K.cachePool,ge!==null?(Be=Mi._currentValue,ge=ge.parent!==Be?{parent:Be,pool:Be}:ge):ge=g0(),K={baseLanes:K.baseLanes|g,cachePool:ge}),T.memoizedState=K,T.childLanes=o_(u,q,g),f.memoizedState=L0,b):(Sa(f),g=u.child,u=g.sibling,g=zs(g,{mode:"visible",children:b.children}),g.return=f,g.sibling=null,u!==null&&(q=f.deletions,q===null?(f.deletions=[u],f.flags|=16):q.push(u)),f.child=g,f.memoizedState=null,g)}function Vv(u,f){return f=N0({mode:"visible",children:f},u.mode),f.return=u,u.child=f}function N0(u,f){return u=pa(22,u,null,f),u.lanes=0,u.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},u}function a_(u,f,g){return no(f,u.child,null,g),u=Vv(f,f.pendingProps.children),u.flags|=2,f.memoizedState=null,u}function Pf(u,f,g){u.lanes|=f;var b=u.alternate;b!==null&&(b.lanes|=f),xv(u.return,f,g)}function kh(u,f,g,b,T){var D=u.memoizedState;D===null?u.memoizedState={isBackwards:f,rendering:null,renderingStartTime:0,last:b,tail:g,tailMode:T}:(D.isBackwards=f,D.rendering=null,D.renderingStartTime=0,D.last=b,D.tail=g,D.tailMode=T)}function s_(u,f,g){var b=f.pendingProps,T=b.revealOrder,D=b.tail;if(ro(u,f,b.children,g),b=_i.current,(b&2)!==0)b=b&1|2,f.flags|=128;else{if(u!==null&&(u.flags&128)!==0)e:for(u=f.child;u!==null;){if(u.tag===13)u.memoizedState!==null&&Pf(u,g,f);else if(u.tag===19)Pf(u,g,f);else if(u.child!==null){u.child.return=u,u=u.child;continue}if(u===f)break e;for(;u.sibling===null;){if(u.return===null||u.return===f)break e;u=u.return}u.sibling.return=u.return,u=u.sibling}b&=1}switch(U(_i,b),T){case"forwards":for(g=f.child,T=null;g!==null;)u=g.alternate,u!==null&&ja(u)===null&&(T=g),g=g.sibling;g=T,g===null?(T=f.child,f.child=null):(T=g.sibling,g.sibling=null),kh(f,!1,T,g,D);break;case"backwards":for(g=null,T=f.child,f.child=null;T!==null;){if(u=T.alternate,u!==null&&ja(u)===null){f.child=T;break}u=T.sibling,T.sibling=g,g=T,T=u}kh(f,!0,g,null,D);break;case"together":kh(f,!1,null,null,void 0);break;default:f.memoizedState=null}return f.child}function Zs(u,f,g){if(u!==null&&(f.dependencies=u.dependencies),Ec|=f.lanes,(g&f.childLanes)===0)if(u!==null){if(d0(u,f,g,!1),(g&f.childLanes)===0)return null}else return null;if(u!==null&&f.child!==u.child)throw Error(r(153));if(f.child!==null){for(u=f.child,g=zs(u,u.pendingProps),f.child=g,g.return=f;u.sibling!==null;)u=u.sibling,g=g.sibling=zs(u,u.pendingProps),g.return=f;g.sibling=null}return f.child}function Yv(u,f){return(u.lanes&f)!==0?!0:(u=u.dependencies,!!(u!==null&&h0(u)))}function t4(u,f,g){switch(f.tag){case 3:Ge(f,f.stateNode.containerInfo),bl(f,Mi,u.memoizedState.cache),ah();break;case 27:case 5:Tt(f);break;case 4:Ge(f,f.stateNode.containerInfo);break;case 10:bl(f,f.type,f.memoizedProps.value);break;case 13:var b=f.memoizedState;if(b!==null)return b.dehydrated!==null?(Sa(f),f.flags|=128,null):(g&f.child.childLanes)!==0?e4(u,f,g):(Sa(f),u=Zs(u,f,g),u!==null?u.sibling:null);Sa(f);break;case 19:var T=(u.flags&128)!==0;if(b=(g&f.childLanes)!==0,b||(d0(u,f,g,!1),b=(g&f.childLanes)!==0),T){if(b)return s_(u,f,g);f.flags|=128}if(T=f.memoizedState,T!==null&&(T.rendering=null,T.tail=null,T.lastEffect=null),U(_i,_i.current),b)break;return null;case 22:case 23:return f.lanes=0,jf(u,f,g);case 24:bl(f,Mi,u.memoizedState.cache)}return Zs(u,f,g)}function l_(u,f,g){if(u!==null)if(u.memoizedProps!==f.pendingProps)Bn=!0;else{if(!Yv(u,g)&&(f.flags&128)===0)return Bn=!1,t4(u,f,g);Bn=(u.flags&131072)!==0}else Bn=!1,En&&(f.flags&1048576)!==0&&mr(f,l0,f.index);switch(f.lanes=0,f.tag){case 16:e:{u=f.pendingProps;var b=f.elementType,T=b._init;if(b=T(b._payload),f.type=b,typeof b=="function")gv(b)?(u=vs(b,u),f.tag=1,f=i_(null,f,b,u,g)):(f.tag=0,f=Hv(null,f,b,u,g));else{if(b!=null){if(T=b.$$typeof,T===I){f.tag=11,f=n_(null,f,b,u,g);break e}else if(T===H){f.tag=14,f=JT(null,f,b,u,g);break e}}throw f=ee(b)||b,Error(r(306,f,""))}}return f;case 0:return Hv(u,f,f.type,f.pendingProps,g);case 1:return b=f.type,T=vs(b,f.pendingProps),i_(u,f,b,T,g);case 3:e:{if(Ge(f,f.stateNode.containerInfo),u===null)throw Error(r(387));b=f.pendingProps;var D=f.memoizedState;T=D.element,Cv(u,f),mh(f,b,null,g);var q=f.memoizedState;if(b=q.cache,bl(f,Mi,b),b!==D.cache&&bv(f,[Mi],g,!0),x0(),b=q.element,D.isDehydrated)if(D={element:b,isDehydrated:!1,cache:q.cache},f.updateQueue.baseState=D,f.memoizedState=D,f.flags&256){f=qv(u,f,b,g);break e}else if(b!==T){T=Fa(Error(r(424)),f),sh(T),f=qv(u,f,b,g);break e}else{switch(u=f.stateNode.containerInfo,u.nodeType){case 9:u=u.body;break;default:u=u.nodeName==="HTML"?u.ownerDocument.body:u}for(Er=el(u.firstChild),pi=f,En=!0,cu=null,Go=!0,g=Zb(f,null,b,g),f.child=g;g;)g.flags=g.flags&-3|4096,g=g.sibling}else{if(ah(),b===T){f=Zs(u,f,g);break e}ro(u,f,b,g)}f=f.child}return f;case 26:return yu(u,f),u===null?(g=_y(f.type,null,f.pendingProps,null))?f.memoizedState=g:En||(g=f.type,u=f.pendingProps,b=Ph(Te.current).createElement(g),b[nn]=f,b[yn]=u,Fe(b,g,u),qn(b),f.stateNode=b):f.memoizedState=_y(f.type,u.memoizedProps,f.pendingProps,u.memoizedState),null;case 27:return Tt(f),u===null&&En&&(b=f.stateNode=bo(f.type,f.pendingProps,Te.current),pi=f,Go=!0,T=Er,xo(f.type)?(N_=T,Er=el(b.firstChild)):Er=T),ro(u,f,f.pendingProps.children,g),yu(u,f),u===null&&(f.flags|=4194304),f.child;case 5:return u===null&&En&&((T=b=Er)&&(b=$_(b,f.type,f.pendingProps,Go),b!==null?(f.stateNode=b,pi=f,Er=el(b.firstChild),Go=!1,T=!0):T=!1),T||js(f)),Tt(f),T=f.type,D=f.pendingProps,q=u!==null?u.memoizedProps:null,b=D.children,Qf(T,D)?b=null:q!==null&&Qf(T,q)&&(f.flags|=32),f.memoizedState!==null&&(T=kv(u,f,HT,null,null,g),_o._currentValue=T),yu(u,f),ro(u,f,b,g),f.child;case 6:return u===null&&En&&((u=g=Er)&&(g=Hh(g,f.pendingProps,Go),g!==null?(f.stateNode=g,pi=f,Er=null,u=!0):u=!1),u||js(f)),null;case 13:return e4(u,f,g);case 4:return Ge(f,f.stateNode.containerInfo),b=f.pendingProps,u===null?f.child=no(f,null,b,g):ro(u,f,b,g),f.child;case 11:return n_(u,f,f.type,f.pendingProps,g);case 7:return ro(u,f,f.pendingProps,g),f.child;case 8:return ro(u,f,f.pendingProps.children,g),f.child;case 12:return ro(u,f,f.pendingProps.children,g),f.child;case 10:return b=f.pendingProps,bl(f,f.type,b.value),ro(u,f,b.children,g),f.child;case 9:return T=f.type._context,b=f.pendingProps.children,hc(f),T=vo(T),b=b(T),f.flags|=1,ro(u,f,b,g),f.child;case 14:return JT(u,f,f.type,f.pendingProps,g);case 15:return vu(u,f,f.type,f.pendingProps,g);case 19:return s_(u,f,g);case 31:return b=f.pendingProps,g=f.mode,b={mode:b.mode,children:b.children},u===null?(g=N0(b,g),g.ref=f.ref,f.child=g,g.return=f,f=g):(g=zs(u.child,b),g.ref=f.ref,f.child=g,g.return=f,f=g),f;case 22:return jf(u,f,g);case 24:return hc(f),b=vo(Mi),u===null?(T=fh(),T===null&&(T=kr,D=bb(),T.pooledCache=D,D.refCount++,D!==null&&(T.pooledCacheLanes|=g),T=D),f.memoizedState={parent:b,cache:T},v0(f),bl(f,Mi,T)):((u.lanes&g)!==0&&(Cv(u,f),mh(f,null,null,g),x0()),T=u.memoizedState,D=f.memoizedState,T.parent!==b?(T={parent:b,cache:b},f.memoizedState=T,f.lanes===0&&(f.memoizedState=f.updateQueue.baseState=T),bl(f,Mi,b)):(b=D.cache,bl(f,Mi,b),b!==T.cache&&bv(f,[Mi],g,!0))),ro(u,f,f.pendingProps.children,g),f.child;case 29:throw f.pendingProps}throw Error(r(156,f.tag))}function xu(u){u.flags|=4}function u_(u,f){if(f.type!=="stylesheet"||(f.state.loading&4)!==0)u.flags&=-16777217;else if(u.flags|=16777216,!j_(f)){if(f=Ii.current,f!==null&&((Kn&4194048)===Kn?Vs!==null:(Kn&62914560)!==Kn&&(Kn&536870912)===0||f!==Vs))throw gh=Sv,m0;u.flags|=8192}}function xc(u,f){f!==null&&(u.flags|=4),u.flags&16384&&(f=u.tag!==22?it():536870912,u.lanes|=f,Ih|=f)}function Th(u,f){if(!En)switch(u.tailMode){case"hidden":f=u.tail;for(var g=null;f!==null;)f.alternate!==null&&(g=f),f=f.sibling;g===null?u.tail=null:g.sibling=null;break;case"collapsed":g=u.tail;for(var b=null;g!==null;)g.alternate!==null&&(b=g),g=g.sibling;b===null?f||u.tail===null?u.tail=null:u.tail.sibling=null:b.sibling=null}}function Wr(u){var f=u.alternate!==null&&u.alternate.child===u.child,g=0,b=0;if(f)for(var T=u.child;T!==null;)g|=T.lanes|T.childLanes,b|=T.subtreeFlags&65011712,b|=T.flags&65011712,T.return=u,T=T.sibling;else for(T=u.child;T!==null;)g|=T.lanes|T.childLanes,b|=T.subtreeFlags,b|=T.flags,T.return=u,T=T.sibling;return u.subtreeFlags|=b,u.childLanes=g,f}function Ar(u,f,g){var b=f.pendingProps;switch(Df(f),f.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Wr(f),null;case 1:return Wr(f),null;case 3:return g=f.stateNode,b=null,u!==null&&(b=u.memoizedState.cache),f.memoizedState.cache!==b&&(f.flags|=2048),_l(Mi),We(),g.pendingContext&&(g.context=g.pendingContext,g.pendingContext=null),(u===null||u.child===null)&&(oh(f)?xu(f):u===null||u.memoizedState.isDehydrated&&(f.flags&256)===0||(f.flags|=1024,yb())),Wr(f),null;case 26:return g=f.memoizedState,u===null?(xu(f),g!==null?(Wr(f),u_(f,g)):(Wr(f),f.flags&=-16777217)):g?g!==u.memoizedState?(xu(f),Wr(f),u_(f,g)):(Wr(f),f.flags&=-16777217):(u.memoizedProps!==b&&xu(f),Wr(f),f.flags&=-16777217),null;case 27:It(f),g=Te.current;var T=f.type;if(u!==null&&f.stateNode!=null)u.memoizedProps!==b&&xu(f);else{if(!b){if(f.stateNode===null)throw Error(r(166));return Wr(f),null}u=fe.current,oh(f)?vv(f):(u=bo(T,b,g),f.stateNode=u,xu(f))}return Wr(f),null;case 5:if(It(f),g=f.type,u!==null&&f.stateNode!=null)u.memoizedProps!==b&&xu(f);else{if(!b){if(f.stateNode===null)throw Error(r(166));return Wr(f),null}if(u=fe.current,oh(f))vv(f);else{switch(T=Ph(Te.current),u){case 1:u=T.createElementNS("http://www.w3.org/2000/svg",g);break;case 2:u=T.createElementNS("http://www.w3.org/1998/Math/MathML",g);break;default:switch(g){case"svg":u=T.createElementNS("http://www.w3.org/2000/svg",g);break;case"math":u=T.createElementNS("http://www.w3.org/1998/Math/MathML",g);break;case"script":u=T.createElement("div"),u.innerHTML="<script><\/script>",u=u.removeChild(u.firstChild);break;case"select":u=typeof b.is=="string"?T.createElement("select",{is:b.is}):T.createElement("select"),b.multiple?u.multiple=!0:b.size&&(u.size=b.size);break;default:u=typeof b.is=="string"?T.createElement(g,{is:b.is}):T.createElement(g)}}u[nn]=f,u[yn]=b;e:for(T=f.child;T!==null;){if(T.tag===5||T.tag===6)u.appendChild(T.stateNode);else if(T.tag!==4&&T.tag!==27&&T.child!==null){T.child.return=T,T=T.child;continue}if(T===f)break e;for(;T.sibling===null;){if(T.return===null||T.return===f)break e;T=T.return}T.sibling.return=T.return,T=T.sibling}f.stateNode=u;e:switch(Fe(u,g,b),g){case"button":case"input":case"select":case"textarea":u=!!b.autoFocus;break e;case"img":u=!0;break e;default:u=!1}u&&xu(f)}}return Wr(f),f.flags&=-16777217,null;case 6:if(u&&f.stateNode!=null)u.memoizedProps!==b&&xu(f);else{if(typeof b!="string"&&f.stateNode===null)throw Error(r(166));if(u=Te.current,oh(f)){if(u=f.stateNode,g=f.memoizedProps,b=null,T=pi,T!==null)switch(T.tag){case 27:case 5:b=T.memoizedProps}u[nn]=f,u=!!(u.nodeValue===g||b!==null&&b.suppressHydrationWarning===!0||_4(u.nodeValue,g)),u||js(f)}else u=Ph(u).createTextNode(b),u[nn]=f,f.stateNode=u}return Wr(f),null;case 13:if(b=f.memoizedState,u===null||u.memoizedState!==null&&u.memoizedState.dehydrated!==null){if(T=oh(f),b!==null&&b.dehydrated!==null){if(u===null){if(!T)throw Error(r(318));if(T=f.memoizedState,T=T!==null?T.dehydrated:null,!T)throw Error(r(317));T[nn]=f}else ah(),(f.flags&128)===0&&(f.memoizedState=null),f.flags|=4;Wr(f),T=!1}else T=yb(),u!==null&&u.memoizedState!==null&&(u.memoizedState.hydrationErrors=T),T=!0;if(!T)return f.flags&256?(Ys(f),f):(Ys(f),null)}if(Ys(f),(f.flags&128)!==0)return f.lanes=g,f;if(g=b!==null,u=u!==null&&u.memoizedState!==null,g){b=f.child,T=null,b.alternate!==null&&b.alternate.memoizedState!==null&&b.alternate.memoizedState.cachePool!==null&&(T=b.alternate.memoizedState.cachePool.pool);var D=null;b.memoizedState!==null&&b.memoizedState.cachePool!==null&&(D=b.memoizedState.cachePool.pool),D!==T&&(b.flags|=2048)}return g!==u&&g&&(f.child.flags|=8192),xc(f,f.updateQueue),Wr(f),null;case 4:return We(),u===null&&Y0(f.stateNode.containerInfo),Wr(f),null;case 10:return _l(f.type),Wr(f),null;case 19:if(ne(_i),T=f.memoizedState,T===null)return Wr(f),null;if(b=(f.flags&128)!==0,D=T.rendering,D===null)if(b)Th(T,!1);else{if(vi!==0||u!==null&&(u.flags&128)!==0)for(u=f.child;u!==null;){if(D=ja(u),D!==null){for(f.flags|=128,Th(T,!1),u=D.updateQueue,f.updateQueue=u,xc(f,u),f.subtreeFlags=0,u=g,g=f.child;g!==null;)mv(g,u),g=g.sibling;return U(_i,_i.current&1|2),f.child}u=u.sibling}T.tail!==null&&yt()>Xv&&(f.flags|=128,b=!0,Th(T,!1),f.lanes=4194304)}else{if(!b)if(u=ja(D),u!==null){if(f.flags|=128,b=!0,u=u.updateQueue,f.updateQueue=u,xc(f,u),Th(T,!0),T.tail===null&&T.tailMode==="hidden"&&!D.alternate&&!En)return Wr(f),null}else 2*yt()-T.renderingStartTime>Xv&&g!==536870912&&(f.flags|=128,b=!0,Th(T,!1),f.lanes=4194304);T.isBackwards?(D.sibling=f.child,f.child=D):(u=T.last,u!==null?u.sibling=D:f.child=D,T.last=D)}return T.tail!==null?(f=T.tail,T.rendering=f,T.tail=f.sibling,T.renderingStartTime=yt(),f.sibling=null,u=_i.current,U(_i,b?u&1|2:u&1),f):(Wr(f),null);case 22:case 23:return Ys(f),yh(),b=f.memoizedState!==null,u!==null?u.memoizedState!==null!==b&&(f.flags|=8192):b&&(f.flags|=8192),b?(g&536870912)!==0&&(f.flags&128)===0&&(Wr(f),f.subtreeFlags&6&&(f.flags|=8192)):Wr(f),g=f.updateQueue,g!==null&&xc(f,g.retryQueue),g=null,u!==null&&u.memoizedState!==null&&u.memoizedState.cachePool!==null&&(g=u.memoizedState.cachePool.pool),b=null,f.memoizedState!==null&&f.memoizedState.cachePool!==null&&(b=f.memoizedState.cachePool.pool),b!==g&&(f.flags|=2048),u!==null&&ne(du),null;case 24:return g=null,u!==null&&(g=u.memoizedState.cache),f.memoizedState.cache!==g&&(f.flags|=2048),_l(Mi),Wr(f),null;case 25:return null;case 30:return null}throw Error(r(156,f.tag))}function c_(u,f){switch(Df(f),f.tag){case 1:return u=f.flags,u&65536?(f.flags=u&-65537|128,f):null;case 3:return _l(Mi),We(),u=f.flags,(u&65536)!==0&&(u&128)===0?(f.flags=u&-65537|128,f):null;case 26:case 27:case 5:return It(f),null;case 13:if(Ys(f),u=f.memoizedState,u!==null&&u.dehydrated!==null){if(f.alternate===null)throw Error(r(340));ah()}return u=f.flags,u&65536?(f.flags=u&-65537|128,f):null;case 19:return ne(_i),null;case 4:return We(),null;case 10:return _l(f.type),null;case 22:case 23:return Ys(f),yh(),u!==null&&ne(du),u=f.flags,u&65536?(f.flags=u&-65537|128,f):null;case 24:return _l(Mi),null;case 25:return null;default:return null}}function n4(u,f){switch(Df(f),f.tag){case 3:_l(Mi),We();break;case 26:case 27:case 5:It(f);break;case 4:We();break;case 13:Ys(f);break;case 19:ne(_i);break;case 10:_l(f.type);break;case 22:case 23:Ys(f),yh(),u!==null&&ne(du);break;case 24:_l(Mi)}}function Rh(u,f){try{var g=f.updateQueue,b=g!==null?g.lastEffect:null;if(b!==null){var T=b.next;g=T;do{if((g.tag&u)===u){b=void 0;var D=g.create,q=g.inst;b=D(),q.destroy=b}g=g.next}while(g!==T)}}catch(K){Tr(f,f.return,K)}}function bc(u,f,g){try{var b=f.updateQueue,T=b!==null?b.lastEffect:null;if(T!==null){var D=T.next;b=D;do{if((b.tag&u)===u){var q=b.inst,K=q.destroy;if(K!==void 0){q.destroy=void 0,T=f;var ge=g,Be=K;try{Be()}catch(Ke){Tr(T,ge,Ke)}}}b=b.next}while(b!==D)}}catch(Ke){Tr(f,f.return,Ke)}}function r4(u){var f=u.updateQueue;if(f!==null){var g=u.stateNode;try{Ev(f,g)}catch(b){Tr(u,u.return,b)}}}function Zv(u,f,g){g.props=vs(u.type,u.memoizedProps),g.state=u.memoizedState;try{g.componentWillUnmount()}catch(b){Tr(u,f,b)}}function Oh(u,f){try{var g=u.ref;if(g!==null){switch(u.tag){case 26:case 27:case 5:var b=u.stateNode;break;case 30:b=u.stateNode;break;default:b=u.stateNode}typeof g=="function"?u.refCleanup=g(b):g.current=b}}catch(T){Tr(u,f,T)}}function Qs(u,f){var g=u.ref,b=u.refCleanup;if(g!==null)if(typeof b=="function")try{b()}catch(T){Tr(u,f,T)}finally{u.refCleanup=null,u=u.alternate,u!=null&&(u.refCleanup=null)}else if(typeof g=="function")try{g(null)}catch(T){Tr(u,f,T)}else g.current=null}function f_(u){var f=u.type,g=u.memoizedProps,b=u.stateNode;try{e:switch(f){case"button":case"input":case"select":case"textarea":g.autoFocus&&b.focus();break e;case"img":g.src?b.src=g.src:g.srcSet&&(b.srcset=g.srcSet)}}catch(T){Tr(u,u.return,T)}}function Hf(u,f,g){try{var b=u.stateNode;cr(b,u.type,g,f),b[yn]=f}catch(T){Tr(u,u.return,T)}}function i4(u){return u.tag===5||u.tag===3||u.tag===26||u.tag===27&&xo(u.type)||u.tag===4}function d_(u){e:for(;;){for(;u.sibling===null;){if(u.return===null||i4(u.return))return null;u=u.return}for(u.sibling.return=u.return,u=u.sibling;u.tag!==5&&u.tag!==6&&u.tag!==18;){if(u.tag===27&&xo(u.type)||u.flags&2||u.child===null||u.tag===4)continue e;u.child.return=u,u=u.child}if(!(u.flags&2))return u.stateNode}}function ys(u,f,g){var b=u.tag;if(b===5||b===6)u=u.stateNode,f?(g.nodeType===9?g.body:g.nodeName==="HTML"?g.ownerDocument.body:g).insertBefore(u,f):(f=g.nodeType===9?g.body:g.nodeName==="HTML"?g.ownerDocument.body:g,f.appendChild(u),g=g._reactRootContainer,g!=null||f.onclick!==null||(f.onclick=Q0));else if(b!==4&&(b===27&&xo(u.type)&&(g=u.stateNode,f=null),u=u.child,u!==null))for(ys(u,f,g),u=u.sibling;u!==null;)ys(u,f,g),u=u.sibling}function _c(u,f,g){var b=u.tag;if(b===5||b===6)u=u.stateNode,f?g.insertBefore(u,f):g.appendChild(u);else if(b!==4&&(b===27&&xo(u.type)&&(g=u.stateNode),u=u.child,u!==null))for(_c(u,f,g),u=u.sibling;u!==null;)_c(u,f,g),u=u.sibling}function o4(u){var f=u.stateNode,g=u.memoizedProps;try{for(var b=u.type,T=f.attributes;T.length;)f.removeAttributeNode(T[0]);Fe(f,b,g),f[nn]=u,f[yn]=g}catch(D){Tr(u,u.return,D)}}var Ks=!1,mi=!1,Qv=!1,h_=typeof WeakSet=="function"?WeakSet:Set,$i=null;function a4(u,f){if(u=u.containerInfo,M_=rg,u=o0(u),fv(u)){if("selectionStart"in u)var g={start:u.selectionStart,end:u.selectionEnd};else e:{g=(g=u.ownerDocument)&&g.defaultView||window;var b=g.getSelection&&g.getSelection();if(b&&b.rangeCount!==0){g=b.anchorNode;var T=b.anchorOffset,D=b.focusNode;b=b.focusOffset;try{g.nodeType,D.nodeType}catch{g=null;break e}var q=0,K=-1,ge=-1,Be=0,Ke=0,tt=u,Ne=null;t:for(;;){for(var je;tt!==g||T!==0&&tt.nodeType!==3||(K=q+T),tt!==D||b!==0&&tt.nodeType!==3||(ge=q+b),tt.nodeType===3&&(q+=tt.nodeValue.length),(je=tt.firstChild)!==null;)Ne=tt,tt=je;for(;;){if(tt===u)break t;if(Ne===g&&++Be===T&&(K=q),Ne===D&&++Ke===b&&(ge=q),(je=tt.nextSibling)!==null)break;tt=Ne,Ne=tt.parentNode}tt=je}g=K===-1||ge===-1?null:{start:K,end:ge}}else g=null}g=g||{start:0,end:0}}else g=null;for(K0={focusedElem:u,selectionRange:g},rg=!1,$i=f;$i!==null;)if(f=$i,u=f.child,(f.subtreeFlags&1024)!==0&&u!==null)u.return=f,$i=u;else for(;$i!==null;){switch(f=$i,D=f.alternate,u=f.flags,f.tag){case 0:break;case 11:case 15:break;case 1:if((u&1024)!==0&&D!==null){u=void 0,g=f,T=D.memoizedProps,D=D.memoizedState,b=g.stateNode;try{var rn=vs(g.type,T,g.elementType===g.type);u=b.getSnapshotBeforeUpdate(rn,D),b.__reactInternalSnapshotBeforeUpdate=u}catch(Jt){Tr(g,g.return,Jt)}}break;case 3:if((u&1024)!==0){if(u=f.stateNode.containerInfo,g=u.nodeType,g===9)W0(u);else if(g===1)switch(u.nodeName){case"HEAD":case"HTML":case"BODY":W0(u);break;default:u.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((u&1024)!==0)throw Error(r(163))}if(u=f.sibling,u!==null){u.return=f.return,$i=u;break}$i=f.return}}function Kv(u,f,g){var b=g.flags;switch(g.tag){case 0:case 11:case 15:bu(u,g),b&4&&Rh(5,g);break;case 1:if(bu(u,g),b&4)if(u=g.stateNode,f===null)try{u.componentDidMount()}catch(q){Tr(g,g.return,q)}else{var T=vs(g.type,f.memoizedProps);f=f.memoizedState;try{u.componentDidUpdate(T,f,u.__reactInternalSnapshotBeforeUpdate)}catch(q){Tr(g,g.return,q)}}b&64&&r4(g),b&512&&Oh(g,g.return);break;case 3:if(bu(u,g),b&64&&(u=g.updateQueue,u!==null)){if(f=null,g.child!==null)switch(g.child.tag){case 27:case 5:f=g.child.stateNode;break;case 1:f=g.child.stateNode}try{Ev(u,f)}catch(q){Tr(g,g.return,q)}}break;case 27:f===null&&b&4&&o4(g);case 26:case 5:bu(u,g),f===null&&b&4&&f_(g),b&512&&Oh(g,g.return);break;case 12:bu(u,g);break;case 13:bu(u,g),b&4&&Ln(u,g),b&64&&(u=g.memoizedState,u!==null&&(u=u.dehydrated,u!==null&&(g=y4.bind(null,g),L_(u,g))));break;case 22:if(b=g.memoizedState!==null||Ks,!b){f=f!==null&&f.memoizedState!==null||mi,T=Ks;var D=mi;Ks=b,(mi=f)&&!D?qr(u,g,(g.subtreeFlags&8772)!==0):bu(u,g),Ks=T,mi=D}break;case 30:break;default:bu(u,g)}}function p_(u){var f=u.alternate;f!==null&&(u.alternate=null,p_(f)),u.child=null,u.deletions=null,u.sibling=null,u.tag===5&&(f=u.stateNode,f!==null&&Dt(f)),u.stateNode=null,u.return=null,u.dependencies=null,u.memoizedProps=null,u.memoizedState=null,u.pendingProps=null,u.stateNode=null,u.updateQueue=null}var Hr=null,wa=!1;function xs(u,f,g){for(g=g.child;g!==null;)g_(u,f,g),g=g.sibling}function g_(u,f,g){if(Re&&typeof Re.onCommitFiberUnmount=="function")try{Re.onCommitFiberUnmount(_e,g)}catch{}switch(g.tag){case 26:mi||Qs(g,f),xs(u,f,g),g.memoizedState?g.memoizedState.count--:g.stateNode&&(g=g.stateNode,g.parentNode.removeChild(g));break;case 27:mi||Qs(g,f);var b=Hr,T=wa;xo(g.type)&&(Hr=g.stateNode,wa=!1),xs(u,f,g),Bt(g.stateNode),Hr=b,wa=T;break;case 5:mi||Qs(g,f);case 6:if(b=Hr,T=wa,Hr=null,xs(u,f,g),Hr=b,wa=T,Hr!==null)if(wa)try{(Hr.nodeType===9?Hr.body:Hr.nodeName==="HTML"?Hr.ownerDocument.body:Hr).removeChild(g.stateNode)}catch(D){Tr(g,f,D)}else try{Hr.removeChild(g.stateNode)}catch(D){Tr(g,f,D)}break;case 18:Hr!==null&&(wa?(u=Hr,w4(u.nodeType===9?u.body:u.nodeName==="HTML"?u.ownerDocument.body:u,g.stateNode),Qh(u)):w4(Hr,g.stateNode));break;case 4:b=Hr,T=wa,Hr=g.stateNode.containerInfo,wa=!0,xs(u,f,g),Hr=b,wa=T;break;case 0:case 11:case 14:case 15:mi||bc(2,g,f),mi||bc(4,g,f),xs(u,f,g);break;case 1:mi||(Qs(g,f),b=g.stateNode,typeof b.componentWillUnmount=="function"&&Zv(g,f,b)),xs(u,f,g);break;case 21:xs(u,f,g);break;case 22:mi=(b=mi)||g.memoizedState!==null,xs(u,f,g),mi=b;break;default:xs(u,f,g)}}function Ln(u,f){if(f.memoizedState===null&&(u=f.alternate,u!==null&&(u=u.memoizedState,u!==null&&(u=u.dehydrated,u!==null))))try{Qh(u)}catch(g){Tr(f,f.return,g)}}function m_(u){switch(u.tag){case 13:case 19:var f=u.stateNode;return f===null&&(f=u.stateNode=new h_),f;case 22:return u=u.stateNode,f=u._retryCache,f===null&&(f=u._retryCache=new h_),f;default:throw Error(r(435,u.tag))}}function z0(u,f){var g=m_(u);f.forEach(function(b){var T=gM.bind(null,u,b);g.has(b)||(g.add(b),b.then(T,T))})}function Ca(u,f){var g=f.deletions;if(g!==null)for(var b=0;b<g.length;b++){var T=g[b],D=u,q=f,K=q;e:for(;K!==null;){switch(K.tag){case 27:if(xo(K.type)){Hr=K.stateNode,wa=!1;break e}break;case 5:Hr=K.stateNode,wa=!1;break e;case 3:case 4:Hr=K.stateNode.containerInfo,wa=!0;break e}K=K.return}if(Hr===null)throw Error(r(160));g_(D,q,T),Hr=null,wa=!1,D=T.alternate,D!==null&&(D.return=null),T.return=null}if(f.subtreeFlags&13878)for(f=f.child;f!==null;)Dh(f,u),f=f.sibling}var Ha=null;function Dh(u,f){var g=u.alternate,b=u.flags;switch(u.tag){case 0:case 11:case 14:case 15:Ca(f,u),Io(u),b&4&&(bc(3,u,u.return),Rh(3,u),bc(5,u,u.return));break;case 1:Ca(f,u),Io(u),b&512&&(mi||g===null||Qs(g,g.return)),b&64&&Ks&&(u=u.updateQueue,u!==null&&(b=u.callbacks,b!==null&&(g=u.shared.hiddenCallbacks,u.shared.hiddenCallbacks=g===null?b:g.concat(b))));break;case 26:var T=Ha;if(Ca(f,u),Io(u),b&512&&(mi||g===null||Qs(g,g.return)),b&4){var D=g!==null?g.memoizedState:null;if(b=u.memoizedState,g===null)if(b===null)if(u.stateNode===null){e:{b=u.type,g=u.memoizedProps,T=T.ownerDocument||T;t:switch(b){case"title":D=T.getElementsByTagName("title")[0],(!D||D[Ho]||D[nn]||D.namespaceURI==="http://www.w3.org/2000/svg"||D.hasAttribute("itemprop"))&&(D=T.createElement(b),T.head.insertBefore(D,T.querySelector("head > title"))),Fe(D,b,g),D[nn]=u,qn(D),b=D;break e;case"link":var q=Gh("link","href",T).get(b+(g.href||""));if(q){for(var K=0;K<q.length;K++)if(D=q[K],D.getAttribute("href")===(g.href==null||g.href===""?null:g.href)&&D.getAttribute("rel")===(g.rel==null?null:g.rel)&&D.getAttribute("title")===(g.title==null?null:g.title)&&D.getAttribute("crossorigin")===(g.crossOrigin==null?null:g.crossOrigin)){q.splice(K,1);break t}}D=T.createElement(b),Fe(D,b,g),T.head.appendChild(D);break;case"meta":if(q=Gh("meta","content",T).get(b+(g.content||""))){for(K=0;K<q.length;K++)if(D=q[K],D.getAttribute("content")===(g.content==null?null:""+g.content)&&D.getAttribute("name")===(g.name==null?null:g.name)&&D.getAttribute("property")===(g.property==null?null:g.property)&&D.getAttribute("http-equiv")===(g.httpEquiv==null?null:g.httpEquiv)&&D.getAttribute("charset")===(g.charSet==null?null:g.charSet)){q.splice(K,1);break t}}D=T.createElement(b),Fe(D,b,g),T.head.appendChild(D);break;default:throw Error(r(468,b))}D[nn]=u,qn(D),b=D}u.stateNode=b}else U_(T,u.type,u.stateNode);else u.stateNode=Sy(T,b,u.memoizedProps);else D!==b?(D===null?g.stateNode!==null&&(g=g.stateNode,g.parentNode.removeChild(g)):D.count--,b===null?U_(T,u.type,u.stateNode):Sy(T,b,u.memoizedProps)):b===null&&u.stateNode!==null&&Hf(u,u.memoizedProps,g.memoizedProps)}break;case 27:Ca(f,u),Io(u),b&512&&(mi||g===null||Qs(g,g.return)),g!==null&&b&4&&Hf(u,u.memoizedProps,g.memoizedProps);break;case 5:if(Ca(f,u),Io(u),b&512&&(mi||g===null||Qs(g,g.return)),u.flags&32){T=u.stateNode;try{mf(T,"")}catch(je){Tr(u,u.return,je)}}b&4&&u.stateNode!=null&&(T=u.memoizedProps,Hf(u,T,g!==null?g.memoizedProps:T)),b&1024&&(Qv=!0);break;case 6:if(Ca(f,u),Io(u),b&4){if(u.stateNode===null)throw Error(r(162));b=u.memoizedProps,g=u.stateNode;try{g.nodeValue=b}catch(je){Tr(u,u.return,je)}}break;case 3:if(eg=null,T=Ha,Ha=oo(f.containerInfo),Ca(f,u),Ha=T,Io(u),b&4&&g!==null&&g.memoizedState.isDehydrated)try{Qh(f.containerInfo)}catch(je){Tr(u,u.return,je)}Qv&&(Qv=!1,qf(u));break;case 4:b=Ha,Ha=oo(u.stateNode.containerInfo),Ca(f,u),Io(u),Ha=b;break;case 12:Ca(f,u),Io(u);break;case 13:Ca(f,u),Io(u),u.child.flags&8192&&u.memoizedState!==null!=(g!==null&&g.memoizedState!==null)&&(S_=yt()),b&4&&(b=u.updateQueue,b!==null&&(u.updateQueue=null,z0(u,b)));break;case 22:T=u.memoizedState!==null;var ge=g!==null&&g.memoizedState!==null,Be=Ks,Ke=mi;if(Ks=Be||T,mi=Ke||ge,Ca(f,u),mi=Ke,Ks=Be,Io(u),b&8192)e:for(f=u.stateNode,f._visibility=T?f._visibility&-2:f._visibility|1,T&&(g===null||ge||Ks||mi||_u(u)),g=null,f=u;;){if(f.tag===5||f.tag===26){if(g===null){ge=g=f;try{if(D=ge.stateNode,T)q=D.style,typeof q.setProperty=="function"?q.setProperty("display","none","important"):q.display="none";else{K=ge.stateNode;var tt=ge.memoizedProps.style,Ne=tt!=null&&tt.hasOwnProperty("display")?tt.display:null;K.style.display=Ne==null||typeof Ne=="boolean"?"":(""+Ne).trim()}}catch(je){Tr(ge,ge.return,je)}}}else if(f.tag===6){if(g===null){ge=f;try{ge.stateNode.nodeValue=T?"":ge.memoizedProps}catch(je){Tr(ge,ge.return,je)}}}else if((f.tag!==22&&f.tag!==23||f.memoizedState===null||f===u)&&f.child!==null){f.child.return=f,f=f.child;continue}if(f===u)break e;for(;f.sibling===null;){if(f.return===null||f.return===u)break e;g===f&&(g=null),f=f.return}g===f&&(g=null),f.sibling.return=f.return,f=f.sibling}b&4&&(b=u.updateQueue,b!==null&&(g=b.retryQueue,g!==null&&(b.retryQueue=null,z0(u,g))));break;case 19:Ca(f,u),Io(u),b&4&&(b=u.updateQueue,b!==null&&(u.updateQueue=null,z0(u,b)));break;case 30:break;case 21:break;default:Ca(f,u),Io(u)}}function Io(u){var f=u.flags;if(f&2){try{for(var g,b=u.return;b!==null;){if(i4(b)){g=b;break}b=b.return}if(g==null)throw Error(r(160));switch(g.tag){case 27:var T=g.stateNode,D=d_(u);_c(u,D,T);break;case 5:var q=g.stateNode;g.flags&32&&(mf(q,""),g.flags&=-33);var K=d_(u);_c(u,K,q);break;case 3:case 4:var ge=g.stateNode.containerInfo,Be=d_(u);ys(u,Be,ge);break;default:throw Error(r(161))}}catch(Ke){Tr(u,u.return,Ke)}u.flags&=-3}f&4096&&(u.flags&=-4097)}function qf(u){if(u.subtreeFlags&1024)for(u=u.child;u!==null;){var f=u;qf(f),f.tag===5&&f.flags&1024&&f.stateNode.reset(),u=u.sibling}}function bu(u,f){if(f.subtreeFlags&8772)for(f=f.child;f!==null;)Kv(u,f.alternate,f),f=f.sibling}function _u(u){for(u=u.child;u!==null;){var f=u;switch(f.tag){case 0:case 11:case 14:case 15:bc(4,f,f.return),_u(f);break;case 1:Qs(f,f.return);var g=f.stateNode;typeof g.componentWillUnmount=="function"&&Zv(f,f.return,g),_u(f);break;case 27:Bt(f.stateNode);case 26:case 5:Qs(f,f.return),_u(f);break;case 22:f.memoizedState===null&&_u(f);break;case 30:_u(f);break;default:_u(f)}u=u.sibling}}function qr(u,f,g){for(g=g&&(f.subtreeFlags&8772)!==0,f=f.child;f!==null;){var b=f.alternate,T=u,D=f,q=D.flags;switch(D.tag){case 0:case 11:case 15:qr(T,D,g),Rh(4,D);break;case 1:if(qr(T,D,g),b=D,T=b.stateNode,typeof T.componentDidMount=="function")try{T.componentDidMount()}catch(Be){Tr(b,b.return,Be)}if(b=D,T=b.updateQueue,T!==null){var K=b.stateNode;try{var ge=T.shared.hiddenCallbacks;if(ge!==null)for(T.shared.hiddenCallbacks=null,T=0;T<ge.length;T++)vh(ge[T],K)}catch(Be){Tr(b,b.return,Be)}}g&&q&64&&r4(D),Oh(D,D.return);break;case 27:o4(D);case 26:case 5:qr(T,D,g),g&&b===null&&q&4&&f_(D),Oh(D,D.return);break;case 12:qr(T,D,g);break;case 13:qr(T,D,g),g&&q&4&&Ln(T,D);break;case 22:D.memoizedState===null&&qr(T,D,g),Oh(D,D.return);break;case 30:break;default:qr(T,D,g)}f=f.sibling}}function v_(u,f){var g=null;u!==null&&u.memoizedState!==null&&u.memoizedState.cachePool!==null&&(g=u.memoizedState.cachePool.pool),u=null,f.memoizedState!==null&&f.memoizedState.cachePool!==null&&(u=f.memoizedState.cachePool.pool),u!==g&&(u!=null&&u.refCount++,g!=null&&pc(g))}function bs(u,f){u=null,f.alternate!==null&&(u=f.alternate.memoizedState.cache),f=f.memoizedState.cache,f!==u&&(f.refCount++,u!=null&&pc(u))}function Ws(u,f,g,b){if(f.subtreeFlags&10256)for(f=f.child;f!==null;)Su(u,f,g,b),f=f.sibling}function Su(u,f,g,b){var T=f.flags;switch(f.tag){case 0:case 11:case 15:Ws(u,f,g,b),T&2048&&Rh(9,f);break;case 1:Ws(u,f,g,b);break;case 3:Ws(u,f,g,b),T&2048&&(u=null,f.alternate!==null&&(u=f.alternate.memoizedState.cache),f=f.memoizedState.cache,f!==u&&(f.refCount++,u!=null&&pc(u)));break;case 12:if(T&2048){Ws(u,f,g,b),u=f.stateNode;try{var D=f.memoizedProps,q=D.id,K=D.onPostCommit;typeof K=="function"&&K(q,f.alternate===null?"mount":"update",u.passiveEffectDuration,-0)}catch(ge){Tr(f,f.return,ge)}}else Ws(u,f,g,b);break;case 13:Ws(u,f,g,b);break;case 23:break;case 22:D=f.stateNode,q=f.alternate,f.memoizedState!==null?D._visibility&2?Ws(u,f,g,b):Sc(u,f):D._visibility&2?Ws(u,f,g,b):(D._visibility|=2,Gf(u,f,g,b,(f.subtreeFlags&10256)!==0)),T&2048&&v_(q,f);break;case 24:Ws(u,f,g,b),T&2048&&bs(f.alternate,f);break;default:Ws(u,f,g,b)}}function Gf(u,f,g,b,T){for(T=T&&(f.subtreeFlags&10256)!==0,f=f.child;f!==null;){var D=u,q=f,K=g,ge=b,Be=q.flags;switch(q.tag){case 0:case 11:case 15:Gf(D,q,K,ge,T),Rh(8,q);break;case 23:break;case 22:var Ke=q.stateNode;q.memoizedState!==null?Ke._visibility&2?Gf(D,q,K,ge,T):Sc(D,q):(Ke._visibility|=2,Gf(D,q,K,ge,T)),T&&Be&2048&&v_(q.alternate,q);break;case 24:Gf(D,q,K,ge,T),T&&Be&2048&&bs(q.alternate,q);break;default:Gf(D,q,K,ge,T)}f=f.sibling}}function Sc(u,f){if(f.subtreeFlags&10256)for(f=f.child;f!==null;){var g=u,b=f,T=b.flags;switch(b.tag){case 22:Sc(g,b),T&2048&&v_(b.alternate,b);break;case 24:Sc(g,b),T&2048&&bs(b.alternate,b);break;default:Sc(g,b)}f=f.sibling}}var ir=8192;function wc(u){if(u.subtreeFlags&ir)for(u=u.child;u!==null;)io(u),u=u.sibling}function io(u){switch(u.tag){case 26:wc(u),u.flags&ir&&u.memoizedState!==null&&A4(Ha,u.memoizedState,u.memoizedProps);break;case 5:wc(u);break;case 3:case 4:var f=Ha;Ha=oo(u.stateNode.containerInfo),wc(u),Ha=f;break;case 22:u.memoizedState===null&&(f=u.alternate,f!==null&&f.memoizedState!==null?(f=ir,ir=16777216,wc(u),ir=f):wc(u));break;default:wc(u)}}function s4(u){var f=u.alternate;if(f!==null&&(u=f.child,u!==null)){f.child=null;do f=u.sibling,u.sibling=null,u=f;while(u!==null)}}function Mh(u){var f=u.deletions;if((u.flags&16)!==0){if(f!==null)for(var g=0;g<f.length;g++){var b=f[g];$i=b,qa(b,u)}s4(u)}if(u.subtreeFlags&10256)for(u=u.child;u!==null;)Wv(u),u=u.sibling}function Wv(u){switch(u.tag){case 0:case 11:case 15:Mh(u),u.flags&2048&&bc(9,u,u.return);break;case 3:Mh(u);break;case 12:Mh(u);break;case 22:var f=u.stateNode;u.memoizedState!==null&&f._visibility&2&&(u.return===null||u.return.tag!==13)?(f._visibility&=-3,F0(u)):Mh(u);break;default:Mh(u)}}function F0(u){var f=u.deletions;if((u.flags&16)!==0){if(f!==null)for(var g=0;g<f.length;g++){var b=f[g];$i=b,qa(b,u)}s4(u)}for(u=u.child;u!==null;){switch(f=u,f.tag){case 0:case 11:case 15:bc(8,f,f.return),F0(f);break;case 22:g=f.stateNode,g._visibility&2&&(g._visibility&=-3,F0(f));break;default:F0(f)}u=u.sibling}}function qa(u,f){for(;$i!==null;){var g=$i;switch(g.tag){case 0:case 11:case 15:bc(8,g,f);break;case 23:case 22:if(g.memoizedState!==null&&g.memoizedState.cachePool!==null){var b=g.memoizedState.cachePool.pool;b!=null&&b.refCount++}break;case 24:pc(g.memoizedState.cache)}if(b=g.child,b!==null)b.return=g,$i=b;else e:for(g=u;$i!==null;){b=$i;var T=b.sibling,D=b.return;if(p_(b),b===g){$i=null;break e}if(T!==null){T.return=D,$i=T;break e}$i=D}}}var l4={getCacheForType:function(u){var f=vo(Mi),g=f.data.get(u);return g===void 0&&(g=u(),f.data.set(u,g)),g}},y_=typeof WeakMap=="function"?WeakMap:Map,vr=0,kr=null,Nn=null,Kn=0,or=0,Ea=null,wu=!1,Cc=!1,x_=!1,Cu=0,vi=0,Ec=0,Ac=0,b_=0,qi=0,Ih=0,U0=null,Yo=null,__=!1,S_=0,Xv=1/0,Jv=null,El=null,yo=0,kc=null,Tc=null,$h=0,Aa=0,ey=null,w_=null,Bh=0,ty=null;function Ga(){if((vr&2)!==0&&Kn!==0)return Kn&-Kn;if(ue.T!==null){var u=gc;return u!==0?u:fy()}return hr()}function u4(){qi===0&&(qi=(Kn&536870912)===0||En?xe():536870912);var u=Ii.current;return u!==null&&(u.flags|=32),qi}function ka(u,f,g){(u===kr&&(or===2||or===9)||u.cancelPendingCommit!==null)&&(Xs(u,0),Eu(u,Kn,qi,!1)),St(u,g),((vr&2)===0||u!==kr)&&(u===kr&&((vr&2)===0&&(Ac|=g),vi===4&&Eu(u,Kn,qi,!1)),Js(u))}function c4(u,f,g){if((vr&6)!==0)throw Error(r(327));var b=!g&&(f&124)===0&&(f&u.expiredLanes)===0||_t(u,f),T=b?ry(u,f):Vf(u,f,!0),D=b;do{if(T===0){Cc&&!b&&Eu(u,f,0,!1);break}else{if(g=u.current.alternate,D&&!ny(g)){T=Vf(u,f,!1),D=!1;continue}if(T===2){if(D=f,u.errorRecoveryDisabledLanes&D)var q=0;else q=u.pendingLanes&-536870913,q=q!==0?q:q&536870912?536870912:0;if(q!==0){f=q;e:{var K=u;T=U0;var ge=K.current.memoizedState.isDehydrated;if(ge&&(Xs(K,q).flags|=256),q=Vf(K,q,!1),q!==2){if(x_&&!ge){K.errorRecoveryDisabledLanes|=D,Ac|=D,T=4;break e}D=Yo,Yo=T,D!==null&&(Yo===null?Yo=D:Yo.push.apply(Yo,D))}T=q}if(D=!1,T!==2)continue}}if(T===1){Xs(u,0),Eu(u,f,0,!0);break}e:{switch(b=u,D=T,D){case 0:case 1:throw Error(r(345));case 4:if((f&4194048)!==f)break;case 6:Eu(b,f,qi,!wu);break e;case 2:Yo=null;break;case 3:case 5:break;default:throw Error(r(329))}if((f&62914560)===f&&(T=S_+300-yt(),10<T)){if(Eu(b,f,qi,!wu),Kt(b,0,!0)!==0)break e;b.timeoutHandle=Tl(Lh.bind(null,b,g,Yo,Jv,__,f,qi,Ac,Ih,wu,D,2,-0,0),T);break e}Lh(b,g,Yo,Jv,__,f,qi,Ac,Ih,wu,D,0,-0,0)}}break}while(!0);Js(u)}function Lh(u,f,g,b,T,D,q,K,ge,Be,Ke,tt,Ne,je){if(u.timeoutHandle=-1,tt=f.subtreeFlags,(tt&8192||(tt&16785408)===16785408)&&(Vh={stylesheets:null,count:0,unsuspend:E4},io(f),tt=k4(),tt!==null)){u.cancelPendingCommit=tt(h4.bind(null,u,f,D,g,b,T,q,K,ge,Ke,1,Ne,je)),Eu(u,D,q,!Be);return}h4(u,f,D,g,b,T,q,K,ge)}function ny(u){for(var f=u;;){var g=f.tag;if((g===0||g===11||g===15)&&f.flags&16384&&(g=f.updateQueue,g!==null&&(g=g.stores,g!==null)))for(var b=0;b<g.length;b++){var T=g[b],D=T.getSnapshot;T=T.value;try{if(!qo(D(),T))return!1}catch{return!1}}if(g=f.child,f.subtreeFlags&16384&&g!==null)g.return=f,f=g;else{if(f===u)break;for(;f.sibling===null;){if(f.return===null||f.return===u)return!0;f=f.return}f.sibling.return=f.return,f=f.sibling}}return!0}function Eu(u,f,g,b){f&=~b_,f&=~Ac,u.suspendedLanes|=f,u.pingedLanes&=~f,b&&(u.warmLanes|=f),b=u.expirationTimes;for(var T=f;0<T;){var D=31-ct(T),q=1<<D;b[D]=-1,T&=~q}g!==0&&Ht(u,g,f)}function j0(){return(vr&6)===0?(Au(0),!1):!0}function Nh(){if(Nn!==null){if(or===0)var u=Nn.return;else u=Nn,Ps=fu=null,xh(u),ba=null,wh=0,u=Nn;for(;u!==null;)n4(u.alternate,u),u=u.return;Nn=null}}function Xs(u,f){var g=u.timeoutHandle;g!==-1&&(u.timeoutHandle=-1,I_(g)),g=u.cancelPendingCommit,g!==null&&(u.cancelPendingCommit=null,g()),Nh(),kr=u,Nn=g=zs(u.current,null),Kn=f,or=0,Ea=null,wu=!1,Cc=_t(u,f),x_=!1,Ih=qi=b_=Ac=Ec=vi=0,Yo=U0=null,__=!1,(f&8)!==0&&(f|=f&32);var b=u.entangledLanes;if(b!==0)for(u=u.entanglements,b&=f;0<b;){var T=31-ct(b),D=1<<T;f|=u[T],b&=~D}return Cu=f,Ls(),g}function zh(u,f){mn=null,ue.H=M0,f===Mf||f===hh?(f=wv(),or=3):f===m0?(f=wv(),or=4):or=f===t_?8:f!==null&&typeof f=="object"&&typeof f.then=="function"?6:1,Ea=f,Nn===null&&(vi=1,Uf(u,Fa(f,u.current)))}function C_(){var u=ue.H;return ue.H=M0,u===null?M0:u}function f4(){var u=ue.A;return ue.A=l4,u}function Rc(){vi=4,wu||(Kn&4194048)!==Kn&&Ii.current!==null||(Cc=!0),(Ec&134217727)===0&&(Ac&134217727)===0||kr===null||Eu(kr,Kn,qi,!1)}function Vf(u,f,g){var b=vr;vr|=2;var T=C_(),D=f4();(kr!==u||Kn!==f)&&(Jv=null,Xs(u,f)),f=!1;var q=vi;e:do try{if(or!==0&&Nn!==null){var K=Nn,ge=Ea;switch(or){case 8:Nh(),q=6;break e;case 3:case 2:case 9:case 6:Ii.current===null&&(f=!0);var Be=or;if(or=0,Ea=null,Yf(u,K,ge,Be),g&&Cc){q=0;break e}break;default:Be=or,or=0,Ea=null,Yf(u,K,ge,Be)}}d4(),q=vi;break}catch(Ke){zh(u,Ke)}while(!0);return f&&u.shellSuspendCounter++,Ps=fu=null,vr=b,ue.H=T,ue.A=D,Nn===null&&(kr=null,Kn=0,Ls()),q}function d4(){for(;Nn!==null;)iy(Nn)}function ry(u,f){var g=vr;vr|=2;var b=C_(),T=f4();kr!==u||Kn!==f?(Jv=null,Xv=yt()+500,Xs(u,f)):Cc=_t(u,f);e:do try{if(or!==0&&Nn!==null){f=Nn;var D=Ea;t:switch(or){case 1:or=0,Ea=null,Yf(u,f,D,1);break;case 2:case 9:if(wb(D)){or=0,Ea=null,A_(f);break}f=function(){or!==2&&or!==9||kr!==u||(or=7),Js(u)},D.then(f,f);break e;case 3:or=7;break e;case 4:or=5;break e;case 7:wb(D)?(or=0,Ea=null,A_(f)):(or=0,Ea=null,Yf(u,f,D,7));break;case 5:var q=null;switch(Nn.tag){case 26:q=Nn.memoizedState;case 5:case 27:var K=Nn;if(!q||j_(q)){or=0,Ea=null;var ge=K.sibling;if(ge!==null)Nn=ge;else{var Be=K.return;Be!==null?(Nn=Be,oy(Be)):Nn=null}break t}}or=0,Ea=null,Yf(u,f,D,5);break;case 6:or=0,Ea=null,Yf(u,f,D,6);break;case 8:Nh(),vi=6;break e;default:throw Error(r(462))}}E_();break}catch(Ke){zh(u,Ke)}while(!0);return Ps=fu=null,ue.H=b,ue.A=T,vr=g,Nn!==null?0:(kr=null,Kn=0,Ls(),vi)}function E_(){for(;Nn!==null&&!Et();)iy(Nn)}function iy(u){var f=l_(u.alternate,u,Cu);u.memoizedProps=u.pendingProps,f===null?oy(u):Nn=f}function A_(u){var f=u,g=f.alternate;switch(f.tag){case 15:case 0:f=r_(g,f,f.pendingProps,f.type,void 0,Kn);break;case 11:f=r_(g,f,f.pendingProps,f.type.render,f.ref,Kn);break;case 5:xh(f);default:n4(g,f),f=Nn=mv(f,Cu),f=l_(g,f,Cu)}u.memoizedProps=u.pendingProps,f===null?oy(u):Nn=f}function Yf(u,f,g,b){Ps=fu=null,xh(f),ba=null,wh=0;var T=f.return;try{if(Pa(u,T,f,g,Kn)){vi=1,Uf(u,Fa(g,u.current)),Nn=null;return}}catch(D){if(T!==null)throw Nn=T,D;vi=1,Uf(u,Fa(g,u.current)),Nn=null;return}f.flags&32768?(En||b===1?u=!0:Cc||(Kn&536870912)!==0?u=!1:(wu=u=!0,(b===2||b===9||b===3||b===6)&&(b=Ii.current,b!==null&&b.tag===13&&(b.flags|=16384))),k_(f,u)):oy(f)}function oy(u){var f=u;do{if((f.flags&32768)!==0){k_(f,wu);return}u=f.return;var g=Ar(f.alternate,f,Cu);if(g!==null){Nn=g;return}if(f=f.sibling,f!==null){Nn=f;return}Nn=f=u}while(f!==null);vi===0&&(vi=5)}function k_(u,f){do{var g=c_(u.alternate,u);if(g!==null){g.flags&=32767,Nn=g;return}if(g=u.return,g!==null&&(g.flags|=32768,g.subtreeFlags=0,g.deletions=null),!f&&(u=u.sibling,u!==null)){Nn=u;return}Nn=u=g}while(u!==null);vi=6,Nn=null}function h4(u,f,g,b,T,D,q,K,ge){u.cancelPendingCommit=null;do sy();while(yo!==0);if((vr&6)!==0)throw Error(r(327));if(f!==null){if(f===u.current)throw Error(r(177));if(D=f.lanes|f.childLanes,D|=s0,Pt(u,g,D,q,K,ge),u===kr&&(Nn=kr=null,Kn=0),Tc=f,kc=u,$h=g,Aa=D,ey=T,w_=b,(f.subtreeFlags&10256)!==0||(f.flags&10256)!==0?(u.callbackNode=null,u.callbackPriority=0,mM(Ee,function(){return m4(),null})):(u.callbackNode=null,u.callbackPriority=0),b=(f.flags&13878)!==0,(f.subtreeFlags&13878)!==0||b){b=ue.T,ue.T=null,T=se.p,se.p=2,q=vr,vr|=4;try{a4(u,f,g)}finally{vr=q,se.p=T,ue.T=b}}yo=1,p4(),g4(),P0()}}function p4(){if(yo===1){yo=0;var u=kc,f=Tc,g=(f.flags&13878)!==0;if((f.subtreeFlags&13878)!==0||g){g=ue.T,ue.T=null;var b=se.p;se.p=2;var T=vr;vr|=4;try{Dh(f,u);var D=K0,q=o0(u.containerInfo),K=D.focusedElem,ge=D.selectionRange;if(q!==K&&K&&K.ownerDocument&&jr(K.ownerDocument.documentElement,K)){if(ge!==null&&fv(K)){var Be=ge.start,Ke=ge.end;if(Ke===void 0&&(Ke=Be),"selectionStart"in K)K.selectionStart=Be,K.selectionEnd=Math.min(Ke,K.value.length);else{var tt=K.ownerDocument||document,Ne=tt&&tt.defaultView||window;if(Ne.getSelection){var je=Ne.getSelection(),rn=K.textContent.length,Jt=Math.min(ge.start,rn),fr=ge.end===void 0?Jt:Math.min(ge.end,rn);!je.extend&&Jt>fr&&(q=fr,fr=Jt,Jt=q);var De=sc(K,Jt),Se=sc(K,fr);if(De&&Se&&(je.rangeCount!==1||je.anchorNode!==De.node||je.anchorOffset!==De.offset||je.focusNode!==Se.node||je.focusOffset!==Se.offset)){var Le=tt.createRange();Le.setStart(De.node,De.offset),je.removeAllRanges(),Jt>fr?(je.addRange(Le),je.extend(Se.node,Se.offset)):(Le.setEnd(Se.node,Se.offset),je.addRange(Le))}}}}for(tt=[],je=K;je=je.parentNode;)je.nodeType===1&&tt.push({element:je,left:je.scrollLeft,top:je.scrollTop});for(typeof K.focus=="function"&&K.focus(),K=0;K<tt.length;K++){var et=tt[K];et.element.scrollLeft=et.left,et.element.scrollTop=et.top}}rg=!!M_,K0=M_=null}finally{vr=T,se.p=b,ue.T=g}}u.current=f,yo=2}}function g4(){if(yo===2){yo=0;var u=kc,f=Tc,g=(f.flags&8772)!==0;if((f.subtreeFlags&8772)!==0||g){g=ue.T,ue.T=null;var b=se.p;se.p=2;var T=vr;vr|=4;try{Kv(u,f.alternate,f)}finally{vr=T,se.p=b,ue.T=g}}yo=3}}function P0(){if(yo===4||yo===3){yo=0,Nt();var u=kc,f=Tc,g=$h,b=w_;(f.subtreeFlags&10256)!==0||(f.flags&10256)!==0?yo=5:(yo=0,Tc=kc=null,ay(u,u.pendingLanes));var T=u.pendingLanes;if(T===0&&(El=null),ln(g),f=f.stateNode,Re&&typeof Re.onCommitFiberRoot=="function")try{Re.onCommitFiberRoot(_e,f,void 0,(f.current.flags&128)===128)}catch{}if(b!==null){f=ue.T,T=se.p,se.p=2,ue.T=null;try{for(var D=u.onRecoverableError,q=0;q<b.length;q++){var K=b[q];D(K.value,{componentStack:K.stack})}}finally{ue.T=f,se.p=T}}($h&3)!==0&&sy(),Js(u),T=u.pendingLanes,(g&4194090)!==0&&(T&42)!==0?u===ty?Bh++:(Bh=0,ty=u):Bh=0,Au(0)}}function ay(u,f){(u.pooledCacheLanes&=f)===0&&(f=u.pooledCache,f!=null&&(u.pooledCache=null,pc(f)))}function sy(u){return p4(),g4(),P0(),m4()}function m4(){if(yo!==5)return!1;var u=kc,f=Aa;Aa=0;var g=ln($h),b=ue.T,T=se.p;try{se.p=32>g?32:g,ue.T=null,g=ey,ey=null;var D=kc,q=$h;if(yo=0,Tc=kc=null,$h=0,(vr&6)!==0)throw Error(r(331));var K=vr;if(vr|=4,Wv(D.current),Su(D,D.current,q,g),vr=K,Au(0,!1),Re&&typeof Re.onPostCommitFiberRoot=="function")try{Re.onPostCommitFiberRoot(_e,D)}catch{}return!0}finally{se.p=T,ue.T=b,ay(u,f)}}function T_(u,f,g){f=Fa(g,f),f=jv(u.stateNode,f,2),u=va(u,f,2),u!==null&&(St(u,2),Js(u))}function Tr(u,f,g){if(u.tag===3)T_(u,u,g);else for(;f!==null;){if(f.tag===3){T_(f,u,g);break}else if(f.tag===1){var b=f.stateNode;if(typeof f.type.getDerivedStateFromError=="function"||typeof b.componentDidCatch=="function"&&(El===null||!El.has(b))){u=Fa(g,u),g=XT(2),b=va(f,g,2),b!==null&&(e_(g,b,f,u),St(b,2),Js(b));break}}f=f.return}}function H0(u,f,g){var b=u.pingCache;if(b===null){b=u.pingCache=new y_;var T=new Set;b.set(f,T)}else T=b.get(f),T===void 0&&(T=new Set,b.set(f,T));T.has(g)||(x_=!0,T.add(g),u=v4.bind(null,u,f,g),f.then(u,u))}function v4(u,f,g){var b=u.pingCache;b!==null&&b.delete(f),u.pingedLanes|=u.suspendedLanes&g,u.warmLanes&=~g,kr===u&&(Kn&g)===g&&(vi===4||vi===3&&(Kn&62914560)===Kn&&300>yt()-S_?(vr&2)===0&&Xs(u,0):b_|=g,Ih===Kn&&(Ih=0)),Js(u)}function ly(u,f){f===0&&(f=it()),u=lu(u,f),u!==null&&(St(u,f),Js(u))}function y4(u){var f=u.memoizedState,g=0;f!==null&&(g=f.retryLane),ly(u,g)}function gM(u,f){var g=0;switch(u.tag){case 13:var b=u.stateNode,T=u.memoizedState;T!==null&&(g=T.retryLane);break;case 19:b=u.stateNode;break;case 22:b=u.stateNode._retryCache;break;default:throw Error(r(314))}b!==null&&b.delete(f),ly(u,g)}function mM(u,f){return dt(u,f)}var uy=null,Fh=null,q0=!1,Uh=!1,G0=!1,Oc=0;function Js(u){u!==Fh&&u.next===null&&(Fh===null?uy=Fh=u:Fh=Fh.next=u),Uh=!0,q0||(q0=!0,cy())}function Au(u,f){if(!G0&&Uh){G0=!0;do for(var g=!1,b=uy;b!==null;){if(u!==0){var T=b.pendingLanes;if(T===0)var D=0;else{var q=b.suspendedLanes,K=b.pingedLanes;D=(1<<31-ct(42|u)+1)-1,D&=T&~(q&~K),D=D&201326741?D&201326741|1:D?D|2:0}D!==0&&(g=!0,x4(b,D))}else D=Kn,D=Kt(b,b===kr?D:0,b.cancelPendingCommit!==null||b.timeoutHandle!==-1),(D&3)===0||_t(b,D)||(g=!0,x4(b,D));b=b.next}while(g);G0=!1}}function vM(){R_()}function R_(){Uh=q0=!1;var u=0;Oc!==0&&(yy()&&(u=Oc),Oc=0);for(var f=yt(),g=null,b=uy;b!==null;){var T=b.next,D=V0(b,f);D===0?(b.next=null,g===null?uy=T:g.next=T,T===null&&(Fh=g)):(g=b,(u!==0||(D&3)!==0)&&(Uh=!0)),b=T}Au(u)}function V0(u,f){for(var g=u.suspendedLanes,b=u.pingedLanes,T=u.expirationTimes,D=u.pendingLanes&-62914561;0<D;){var q=31-ct(D),K=1<<q,ge=T[q];ge===-1?((K&g)===0||(K&b)!==0)&&(T[q]=Y(K,f)):ge<=f&&(u.expiredLanes|=K),D&=~K}if(f=kr,g=Kn,g=Kt(u,u===f?g:0,u.cancelPendingCommit!==null||u.timeoutHandle!==-1),b=u.callbackNode,g===0||u===f&&(or===2||or===9)||u.cancelPendingCommit!==null)return b!==null&&b!==null&&bt(b),u.callbackNode=null,u.callbackPriority=0;if((g&3)===0||_t(u,g)){if(f=g&-g,f===u.callbackPriority)return f;switch(b!==null&&bt(b),ln(g)){case 2:case 8:g=ve;break;case 32:g=Ee;break;case 268435456:g=Ve;break;default:g=Ee}return b=O_.bind(null,u),g=dt(g,b),u.callbackPriority=f,u.callbackNode=g,f}return b!==null&&b!==null&&bt(b),u.callbackPriority=2,u.callbackNode=null,2}function O_(u,f){if(yo!==0&&yo!==5)return u.callbackNode=null,u.callbackPriority=0,null;var g=u.callbackNode;if(sy()&&u.callbackNode!==g)return null;var b=Kn;return b=Kt(u,u===kr?b:0,u.cancelPendingCommit!==null||u.timeoutHandle!==-1),b===0?null:(c4(u,b,f),V0(u,yt()),u.callbackNode!=null&&u.callbackNode===g?O_.bind(null,u):null)}function x4(u,f){if(sy())return null;c4(u,f,!0)}function cy(){bM(function(){(vr&6)!==0?dt(le,vM):R_()})}function fy(){return Oc===0&&(Oc=xe()),Oc}function jh(u){return u==null||typeof u=="symbol"||typeof u=="boolean"?null:typeof u=="function"?u:Kp(""+u)}function dy(u,f){var g=f.ownerDocument.createElement("input");return g.name=f.name,g.value=f.value,u.id&&g.setAttribute("form",u.id),f.parentNode.insertBefore(g,f),u=new FormData(u),g.parentNode.removeChild(g),u}function hy(u,f,g,b,T){if(f==="submit"&&g&&g.stateNode===T){var D=jh((T[yn]||null).action),q=b.submitter;q&&(f=(f=q[yn]||null)?jh(f.formAction):q.getAttribute("formAction"),f!==null&&(D=f,q=null));var K=new Jp("action","action",null,b,T);u.push({event:K,listeners:[{instance:null,listener:function(){if(b.defaultPrevented){if(Oc!==0){var ge=q?dy(T,q):new FormData(T);Hb(g,{pending:!0,data:ge,method:T.method,action:D},null,ge)}}else typeof D=="function"&&(K.preventDefault(),ge=q?dy(T,q):new FormData(T),Hb(g,{pending:!0,data:ge,method:T.method,action:D},D,ge))},currentTarget:T}]})}}for(var py=0;py<pv.length;py++){var yi=pv[py],D_=yi.toLowerCase(),yM=yi[0].toUpperCase()+yi.slice(1);ha(D_,"on"+yM)}ha(a0,"onAnimationEnd"),ha(jT,"onAnimationIteration"),ha(hb,"onAnimationStart"),ha("dblclick","onDoubleClick"),ha("focusin","onFocus"),ha("focusout","onBlur"),ha(fM,"onTransitionRun"),ha(pb,"onTransitionStart"),ha(hv,"onTransitionCancel"),ha(gb,"onTransitionEnd"),Br("onMouseEnter",["mouseout","mouseover"]),Br("onMouseLeave",["mouseout","mouseover"]),Br("onPointerEnter",["pointerout","pointerover"]),Br("onPointerLeave",["pointerout","pointerover"]),pr("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),pr("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),pr("onBeforeInput",["compositionend","keypress","textInput","paste"]),pr("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),pr("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),pr("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var hn="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),xM=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(hn));function ku(u,f){f=(f&4)!==0;for(var g=0;g<u.length;g++){var b=u[g],T=b.event;b=b.listeners;e:{var D=void 0;if(f)for(var q=b.length-1;0<=q;q--){var K=b[q],ge=K.instance,Be=K.currentTarget;if(K=K.listener,ge!==D&&T.isPropagationStopped())break e;D=K,T.currentTarget=Be;try{D(T)}catch(Ke){B0(Ke)}T.currentTarget=null,D=ge}else for(q=0;q<b.length;q++){if(K=b[q],ge=K.instance,Be=K.currentTarget,K=K.listener,ge!==D&&T.isPropagationStopped())break e;D=K,T.currentTarget=Be;try{D(T)}catch(Ke){B0(Ke)}T.currentTarget=null,D=ge}}}}function xn(u,f){var g=f[ho];g===void 0&&(g=f[ho]=new Set);var b=u+"__bubble";g.has(b)||(b4(f,u,2,!1),g.add(b))}function Dc(u,f,g){var b=0;f&&(b|=4),b4(g,u,b,f)}var Zf="_reactListening"+Math.random().toString(36).slice(2);function Y0(u){if(!u[Zf]){u[Zf]=!0,ua.forEach(function(g){g!=="selectionchange"&&(xM.has(g)||Dc(g,!1,u),Dc(g,!0,u))});var f=u.nodeType===9?u:u.ownerDocument;f===null||f[Zf]||(f[Zf]=!0,Dc("selectionchange",!1,f))}}function b4(u,f,g,b){switch(D4(f)){case 2:var T=R4;break;case 8:T=O4;break;default:T=Ay}g=T.bind(null,f,g,u),T=void 0,!Wm||f!=="touchstart"&&f!=="touchmove"&&f!=="wheel"||(T=!0),b?T!==void 0?u.addEventListener(f,g,{capture:!0,passive:T}):u.addEventListener(f,g,!0):T!==void 0?u.addEventListener(f,g,{passive:T}):u.addEventListener(f,g,!1)}function Z0(u,f,g,b,T){var D=b;if((f&1)===0&&(f&2)===0&&b!==null)e:for(;;){if(b===null)return;var q=b.tag;if(q===3||q===4){var K=b.stateNode.containerInfo;if(K===T)break;if(q===4)for(q=b.return;q!==null;){var ge=q.tag;if((ge===3||ge===4)&&q.stateNode.containerInfo===T)return;q=q.return}for(;K!==null;){if(q=to(K),q===null)return;if(ge=q.tag,ge===5||ge===6||ge===26||ge===27){b=D=q;continue e}K=K.parentNode}}b=b.return}OT(function(){var Be=D,Ke=vf(g),tt=[];e:{var Ne=mb.get(u);if(Ne!==void 0){var je=Jp,rn=u;switch(u){case"keypress":if(Xp(g)===0)break e;case"keydown":case"keyup":je=_f;break;case"focusin":rn="focus",je=eb;break;case"focusout":rn="blur",je=eb;break;case"beforeblur":case"afterblur":je=eb;break;case"click":if(g.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":je=t0;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":je=IT;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":je=rv;break;case a0:case jT:case hb:je=sM;break;case gb:je=da;break;case"scroll":case"scrollend":je=oM;break;case"wheel":je=iv;break;case"copy":case"cut":case"paste":je=uM;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":je=fa;break;case"toggle":case"beforetoggle":je=ib}var Jt=(f&4)!==0,fr=!Jt&&(u==="scroll"||u==="scrollend"),De=Jt?Ne!==null?Ne+"Capture":null:Ne;Jt=[];for(var Se=Be,Le;Se!==null;){var et=Se;if(Le=et.stateNode,et=et.tag,et!==5&&et!==26&&et!==27||Le===null||De===null||(et=iu(Se,De),et!=null&&Jt.push(Ta(Se,et,Le))),fr)break;Se=Se.return}0<Jt.length&&(Ne=new je(Ne,rn,null,g,Ke),tt.push({event:Ne,listeners:Jt}))}}if((f&7)===0){e:{if(Ne=u==="mouseover"||u==="pointerover",je=u==="mouseout"||u==="pointerout",Ne&&g!==Km&&(rn=g.relatedTarget||g.fromElement)&&(to(rn)||rn[fn]))break e;if((je||Ne)&&(Ne=Ke.window===Ke?Ke:(Ne=Ke.ownerDocument)?Ne.defaultView||Ne.parentWindow:window,je?(rn=g.relatedTarget||g.toElement,je=Be,rn=rn?to(rn):null,rn!==null&&(fr=a(rn),Jt=rn.tag,rn!==fr||Jt!==5&&Jt!==27&&Jt!==6)&&(rn=null)):(je=null,rn=Be),je!==rn)){if(Jt=t0,et="onMouseLeave",De="onMouseEnter",Se="mouse",(u==="pointerout"||u==="pointerover")&&(Jt=fa,et="onPointerLeave",De="onPointerEnter",Se="pointer"),fr=je==null?Ne:Ro(je),Le=rn==null?Ne:Ro(rn),Ne=new Jt(et,Se+"leave",je,g,Ke),Ne.target=fr,Ne.relatedTarget=Le,et=null,to(Ke)===Be&&(Jt=new Jt(De,Se+"enter",rn,g,Ke),Jt.target=Le,Jt.relatedTarget=fr,et=Jt),fr=et,je&&rn)t:{for(Jt=je,De=rn,Se=0,Le=Jt;Le;Le=Ic(Le))Se++;for(Le=0,et=De;et;et=Ic(et))Le++;for(;0<Se-Le;)Jt=Ic(Jt),Se--;for(;0<Le-Se;)De=Ic(De),Le--;for(;Se--;){if(Jt===De||De!==null&&Jt===De.alternate)break t;Jt=Ic(Jt),De=Ic(De)}Jt=null}else Jt=null;je!==null&&gy(tt,Ne,je,Jt,!1),rn!==null&&fr!==null&&gy(tt,fr,rn,Jt,!0)}}e:{if(Ne=Be?Ro(Be):window,je=Ne.nodeName&&Ne.nodeName.toLowerCase(),je==="select"||je==="input"&&Ne.type==="file")var Ut=oc;else if(lb(Ne))if(ub)Ut=ou;else{Ut=cv;var An=UT}else je=Ne.nodeName,!je||je.toLowerCase()!=="input"||Ne.type!=="checkbox"&&Ne.type!=="radio"?Be&&Yd(Be.elementType)&&(Ut=oc):Ut=ac;if(Ut&&(Ut=Ut(u,Be))){lv(tt,Ut,g,Ke);break e}An&&An(u,Ne,Be),u==="focusout"&&Be&&Ne.type==="number"&&Be.memoizedProps.value!=null&&Zp(Ne,"number",Ne.value)}switch(An=Be?Ro(Be):window,u){case"focusin":(lb(An)||An.contentEditable==="true")&&(ds=An,Tf=Be,za=null);break;case"focusout":za=Tf=ds=null;break;case"mousedown":eh=!0;break;case"contextmenu":case"mouseup":case"dragend":eh=!1,th(tt,g,Ke);break;case"selectionchange":if(db)break;case"keydown":case"keyup":th(tt,g,Ke)}var Wt;if(ov)e:{switch(u){case"compositionstart":var sn="onCompositionStart";break e;case"compositionend":sn="onCompositionEnd";break e;case"compositionupdate":sn="onCompositionUpdate";break e}sn=void 0}else fs?sv(u,g)&&(sn="onCompositionEnd"):u==="keydown"&&g.keyCode===229&&(sn="onCompositionStart");sn&&(av&&g.locale!=="ko"&&(fs||sn!=="onCompositionStart"?sn==="onCompositionEnd"&&fs&&(Wt=Wp()):(cs=Ke,Xm="value"in cs?cs.value:cs.textContent,fs=!0)),An=Mc(Be,sn),0<An.length&&(sn=new tb(sn,u,null,g,Ke),tt.push({event:sn,listeners:An}),Wt?sn.data=Wt:(Wt=r0(g),Wt!==null&&(sn.data=Wt)))),(Wt=cM?ab(u,g):sb(u,g))&&(sn=Mc(Be,"onBeforeInput"),0<sn.length&&(An=new tb("onBeforeInput","beforeinput",null,g,Ke),tt.push({event:An,listeners:sn}),An.data=Wt)),hy(tt,u,Be,g,Ke)}ku(tt,f)})}function Ta(u,f,g){return{instance:u,listener:f,currentTarget:g}}function Mc(u,f){for(var g=f+"Capture",b=[];u!==null;){var T=u,D=T.stateNode;if(T=T.tag,T!==5&&T!==26&&T!==27||D===null||(T=iu(u,g),T!=null&&b.unshift(Ta(u,T,D)),T=iu(u,f),T!=null&&b.push(Ta(u,T,D))),u.tag===3)return b;u=u.return}return[]}function Ic(u){if(u===null)return null;do u=u.return;while(u&&u.tag!==5&&u.tag!==27);return u||null}function gy(u,f,g,b,T){for(var D=f._reactName,q=[];g!==null&&g!==b;){var K=g,ge=K.alternate,Be=K.stateNode;if(K=K.tag,ge!==null&&ge===b)break;K!==5&&K!==26&&K!==27||Be===null||(ge=Be,T?(Be=iu(g,D),Be!=null&&q.unshift(Ta(g,Be,ge))):T||(Be=iu(g,D),Be!=null&&q.push(Ta(g,Be,ge)))),g=g.return}q.length!==0&&u.push({event:f,listeners:q})}var my=/\r\n?/g,Va=/\u0000|\uFFFD/g;function vy(u){return(typeof u=="string"?u:""+u).replace(my,`
81
- `).replace(Va,"")}function _4(u,f){return f=vy(f),vy(u)===f}function Q0(){}function Rr(u,f,g,b,T,D){switch(g){case"children":typeof b=="string"?f==="body"||f==="textarea"&&b===""||mf(u,b):(typeof b=="number"||typeof b=="bigint")&&f!=="body"&&mf(u,""+b);break;case"className":ce(u,"class",b);break;case"tabIndex":ce(u,"tabindex",b);break;case"dir":case"role":case"viewBox":case"width":case"height":ce(u,g,b);break;case"style":Qm(u,b,D);break;case"data":if(f!=="object"){ce(u,"data",b);break}case"src":case"href":if(b===""&&(f!=="a"||g!=="href")){u.removeAttribute(g);break}if(b==null||typeof b=="function"||typeof b=="symbol"||typeof b=="boolean"){u.removeAttribute(g);break}b=Kp(""+b),u.setAttribute(g,b);break;case"action":case"formAction":if(typeof b=="function"){u.setAttribute(g,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof D=="function"&&(g==="formAction"?(f!=="input"&&Rr(u,f,"name",T.name,T,null),Rr(u,f,"formEncType",T.formEncType,T,null),Rr(u,f,"formMethod",T.formMethod,T,null),Rr(u,f,"formTarget",T.formTarget,T,null)):(Rr(u,f,"encType",T.encType,T,null),Rr(u,f,"method",T.method,T,null),Rr(u,f,"target",T.target,T,null)));if(b==null||typeof b=="symbol"||typeof b=="boolean"){u.removeAttribute(g);break}b=Kp(""+b),u.setAttribute(g,b);break;case"onClick":b!=null&&(u.onclick=Q0);break;case"onScroll":b!=null&&xn("scroll",u);break;case"onScrollEnd":b!=null&&xn("scrollend",u);break;case"dangerouslySetInnerHTML":if(b!=null){if(typeof b!="object"||!("__html"in b))throw Error(r(61));if(g=b.__html,g!=null){if(T.children!=null)throw Error(r(60));u.innerHTML=g}}break;case"multiple":u.multiple=b&&typeof b!="function"&&typeof b!="symbol";break;case"muted":u.muted=b&&typeof b!="function"&&typeof b!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(b==null||typeof b=="function"||typeof b=="boolean"||typeof b=="symbol"){u.removeAttribute("xlink:href");break}g=Kp(""+b),u.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",g);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":b!=null&&typeof b!="function"&&typeof b!="symbol"?u.setAttribute(g,""+b):u.removeAttribute(g);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":b&&typeof b!="function"&&typeof b!="symbol"?u.setAttribute(g,""):u.removeAttribute(g);break;case"capture":case"download":b===!0?u.setAttribute(g,""):b!==!1&&b!=null&&typeof b!="function"&&typeof b!="symbol"?u.setAttribute(g,b):u.removeAttribute(g);break;case"cols":case"rows":case"size":case"span":b!=null&&typeof b!="function"&&typeof b!="symbol"&&!isNaN(b)&&1<=b?u.setAttribute(g,b):u.removeAttribute(g);break;case"rowSpan":case"start":b==null||typeof b=="function"||typeof b=="symbol"||isNaN(b)?u.removeAttribute(g):u.setAttribute(g,b);break;case"popover":xn("beforetoggle",u),xn("toggle",u),at(u,"popover",b);break;case"xlinkActuate":Me(u,"http://www.w3.org/1999/xlink","xlink:actuate",b);break;case"xlinkArcrole":Me(u,"http://www.w3.org/1999/xlink","xlink:arcrole",b);break;case"xlinkRole":Me(u,"http://www.w3.org/1999/xlink","xlink:role",b);break;case"xlinkShow":Me(u,"http://www.w3.org/1999/xlink","xlink:show",b);break;case"xlinkTitle":Me(u,"http://www.w3.org/1999/xlink","xlink:title",b);break;case"xlinkType":Me(u,"http://www.w3.org/1999/xlink","xlink:type",b);break;case"xmlBase":Me(u,"http://www.w3.org/XML/1998/namespace","xml:base",b);break;case"xmlLang":Me(u,"http://www.w3.org/XML/1998/namespace","xml:lang",b);break;case"xmlSpace":Me(u,"http://www.w3.org/XML/1998/namespace","xml:space",b);break;case"is":at(u,"is",b);break;case"innerText":case"textContent":break;default:(!(2<g.length)||g[0]!=="o"&&g[0]!=="O"||g[1]!=="n"&&g[1]!=="N")&&(g=Qp.get(g)||g,at(u,g,b))}}function Gi(u,f,g,b,T,D){switch(g){case"style":Qm(u,b,D);break;case"dangerouslySetInnerHTML":if(b!=null){if(typeof b!="object"||!("__html"in b))throw Error(r(61));if(g=b.__html,g!=null){if(T.children!=null)throw Error(r(60));u.innerHTML=g}}break;case"children":typeof b=="string"?mf(u,b):(typeof b=="number"||typeof b=="bigint")&&mf(u,""+b);break;case"onScroll":b!=null&&xn("scroll",u);break;case"onScrollEnd":b!=null&&xn("scrollend",u);break;case"onClick":b!=null&&(u.onclick=Q0);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Oi.hasOwnProperty(g))e:{if(g[0]==="o"&&g[1]==="n"&&(T=g.endsWith("Capture"),f=g.slice(2,T?g.length-7:void 0),D=u[yn]||null,D=D!=null?D[g]:null,typeof D=="function"&&u.removeEventListener(f,D,T),typeof b=="function")){typeof D!="function"&&D!==null&&(g in u?u[g]=null:u.hasAttribute(g)&&u.removeAttribute(g)),u.addEventListener(f,b,T);break e}g in u?u[g]=b:b===!0?u.setAttribute(g,""):at(u,g,b)}}}function Fe(u,f,g){switch(f){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":xn("error",u),xn("load",u);var b=!1,T=!1,D;for(D in g)if(g.hasOwnProperty(D)){var q=g[D];if(q!=null)switch(D){case"src":b=!0;break;case"srcSet":T=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,f));default:Rr(u,f,D,q,g,null)}}T&&Rr(u,f,"srcSet",g.srcSet,g,null),b&&Rr(u,f,"src",g.src,g,null);return;case"input":xn("invalid",u);var K=D=q=T=null,ge=null,Be=null;for(b in g)if(g.hasOwnProperty(b)){var Ke=g[b];if(Ke!=null)switch(b){case"name":T=Ke;break;case"type":q=Ke;break;case"checked":ge=Ke;break;case"defaultChecked":Be=Ke;break;case"value":D=Ke;break;case"defaultValue":K=Ke;break;case"children":case"dangerouslySetInnerHTML":if(Ke!=null)throw Error(r(137,f));break;default:Rr(u,f,b,Ke,g,null)}}Yp(u,D,K,ge,Be,q,T,!1),dn(u);return;case"select":xn("invalid",u),b=q=D=null;for(T in g)if(g.hasOwnProperty(T)&&(K=g[T],K!=null))switch(T){case"value":D=K;break;case"defaultValue":q=K;break;case"multiple":b=K;default:Rr(u,f,T,K,g,null)}f=D,g=q,u.multiple=!!b,f!=null?rc(u,!!b,f,!1):g!=null&&rc(u,!!b,g,!0);return;case"textarea":xn("invalid",u),D=T=b=null;for(q in g)if(g.hasOwnProperty(q)&&(K=g[q],K!=null))switch(q){case"value":b=K;break;case"defaultValue":T=K;break;case"children":D=K;break;case"dangerouslySetInnerHTML":if(K!=null)throw Error(r(91));break;default:Rr(u,f,q,K,g,null)}Kx(u,b,T,D),dn(u);return;case"option":for(ge in g)if(g.hasOwnProperty(ge)&&(b=g[ge],b!=null))switch(ge){case"selected":u.selected=b&&typeof b!="function"&&typeof b!="symbol";break;default:Rr(u,f,ge,b,g,null)}return;case"dialog":xn("beforetoggle",u),xn("toggle",u),xn("cancel",u),xn("close",u);break;case"iframe":case"object":xn("load",u);break;case"video":case"audio":for(b=0;b<hn.length;b++)xn(hn[b],u);break;case"image":xn("error",u),xn("load",u);break;case"details":xn("toggle",u);break;case"embed":case"source":case"link":xn("error",u),xn("load",u);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(Be in g)if(g.hasOwnProperty(Be)&&(b=g[Be],b!=null))switch(Be){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,f));default:Rr(u,f,Be,b,g,null)}return;default:if(Yd(f)){for(Ke in g)g.hasOwnProperty(Ke)&&(b=g[Ke],b!==void 0&&Gi(u,f,Ke,b,g,void 0));return}}for(K in g)g.hasOwnProperty(K)&&(b=g[K],b!=null&&Rr(u,f,K,b,g,null))}function cr(u,f,g,b){switch(f){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var T=null,D=null,q=null,K=null,ge=null,Be=null,Ke=null;for(je in g){var tt=g[je];if(g.hasOwnProperty(je)&&tt!=null)switch(je){case"checked":break;case"value":break;case"defaultValue":ge=tt;default:b.hasOwnProperty(je)||Rr(u,f,je,null,b,tt)}}for(var Ne in b){var je=b[Ne];if(tt=g[Ne],b.hasOwnProperty(Ne)&&(je!=null||tt!=null))switch(Ne){case"type":D=je;break;case"name":T=je;break;case"checked":Be=je;break;case"defaultChecked":Ke=je;break;case"value":q=je;break;case"defaultValue":K=je;break;case"children":case"dangerouslySetInnerHTML":if(je!=null)throw Error(r(137,f));break;default:je!==tt&&Rr(u,f,Ne,je,b,tt)}}go(u,q,K,ge,Be,Ke,D,T);return;case"select":je=q=K=Ne=null;for(D in g)if(ge=g[D],g.hasOwnProperty(D)&&ge!=null)switch(D){case"value":break;case"multiple":je=ge;default:b.hasOwnProperty(D)||Rr(u,f,D,null,b,ge)}for(T in b)if(D=b[T],ge=g[T],b.hasOwnProperty(T)&&(D!=null||ge!=null))switch(T){case"value":Ne=D;break;case"defaultValue":K=D;break;case"multiple":q=D;default:D!==ge&&Rr(u,f,T,D,b,ge)}f=K,g=q,b=je,Ne!=null?rc(u,!!g,Ne,!1):!!b!=!!g&&(f!=null?rc(u,!!g,f,!0):rc(u,!!g,g?[]:"",!1));return;case"textarea":je=Ne=null;for(K in g)if(T=g[K],g.hasOwnProperty(K)&&T!=null&&!b.hasOwnProperty(K))switch(K){case"value":break;case"children":break;default:Rr(u,f,K,null,b,T)}for(q in b)if(T=b[q],D=g[q],b.hasOwnProperty(q)&&(T!=null||D!=null))switch(q){case"value":Ne=T;break;case"defaultValue":je=T;break;case"children":break;case"dangerouslySetInnerHTML":if(T!=null)throw Error(r(91));break;default:T!==D&&Rr(u,f,q,T,b,D)}Qx(u,Ne,je);return;case"option":for(var rn in g)if(Ne=g[rn],g.hasOwnProperty(rn)&&Ne!=null&&!b.hasOwnProperty(rn))switch(rn){case"selected":u.selected=!1;break;default:Rr(u,f,rn,null,b,Ne)}for(ge in b)if(Ne=b[ge],je=g[ge],b.hasOwnProperty(ge)&&Ne!==je&&(Ne!=null||je!=null))switch(ge){case"selected":u.selected=Ne&&typeof Ne!="function"&&typeof Ne!="symbol";break;default:Rr(u,f,ge,Ne,b,je)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Jt in g)Ne=g[Jt],g.hasOwnProperty(Jt)&&Ne!=null&&!b.hasOwnProperty(Jt)&&Rr(u,f,Jt,null,b,Ne);for(Be in b)if(Ne=b[Be],je=g[Be],b.hasOwnProperty(Be)&&Ne!==je&&(Ne!=null||je!=null))switch(Be){case"children":case"dangerouslySetInnerHTML":if(Ne!=null)throw Error(r(137,f));break;default:Rr(u,f,Be,Ne,b,je)}return;default:if(Yd(f)){for(var fr in g)Ne=g[fr],g.hasOwnProperty(fr)&&Ne!==void 0&&!b.hasOwnProperty(fr)&&Gi(u,f,fr,void 0,b,Ne);for(Ke in b)Ne=b[Ke],je=g[Ke],!b.hasOwnProperty(Ke)||Ne===je||Ne===void 0&&je===void 0||Gi(u,f,Ke,Ne,b,je);return}}for(var De in g)Ne=g[De],g.hasOwnProperty(De)&&Ne!=null&&!b.hasOwnProperty(De)&&Rr(u,f,De,null,b,Ne);for(tt in b)Ne=b[tt],je=g[tt],!b.hasOwnProperty(tt)||Ne===je||Ne==null&&je==null||Rr(u,f,tt,Ne,b,je)}var M_=null,K0=null;function Ph(u){return u.nodeType===9?u:u.ownerDocument}function Al(u){switch(u){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Tu(u,f){if(u===0)switch(f){case"svg":return 1;case"math":return 2;default:return 0}return u===1&&f==="foreignObject"?0:u}function Qf(u,f){return u==="textarea"||u==="noscript"||typeof f.children=="string"||typeof f.children=="number"||typeof f.children=="bigint"||typeof f.dangerouslySetInnerHTML=="object"&&f.dangerouslySetInnerHTML!==null&&f.dangerouslySetInnerHTML.__html!=null}var kl=null;function yy(){var u=window.event;return u&&u.type==="popstate"?u===kl?!1:(kl=u,!0):(kl=null,!1)}var Tl=typeof setTimeout=="function"?setTimeout:void 0,I_=typeof clearTimeout=="function"?clearTimeout:void 0,S4=typeof Promise=="function"?Promise:void 0,bM=typeof queueMicrotask=="function"?queueMicrotask:typeof S4<"u"?function(u){return S4.resolve(null).then(u).catch(_M)}:Tl;function _M(u){setTimeout(function(){throw u})}function xo(u){return u==="head"}function w4(u,f){var g=f,b=0,T=0;do{var D=g.nextSibling;if(u.removeChild(g),D&&D.nodeType===8)if(g=D.data,g==="/$"){if(0<b&&8>b){g=b;var q=u.ownerDocument;if(g&1&&Bt(q.documentElement),g&2&&Bt(q.body),g&4)for(g=q.head,Bt(g),q=g.firstChild;q;){var K=q.nextSibling,ge=q.nodeName;q[Ho]||ge==="SCRIPT"||ge==="STYLE"||ge==="LINK"&&q.rel.toLowerCase()==="stylesheet"||g.removeChild(q),q=K}}if(T===0){u.removeChild(D),Qh(f);return}T--}else g==="$"||g==="$?"||g==="$!"?T++:b=g.charCodeAt(0)-48;else b=0;g=D}while(g);Qh(f)}function W0(u){var f=u.firstChild;for(f&&f.nodeType===10&&(f=f.nextSibling);f;){var g=f;switch(f=f.nextSibling,g.nodeName){case"HTML":case"HEAD":case"BODY":W0(g),Dt(g);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(g.rel.toLowerCase()==="stylesheet")continue}u.removeChild(g)}}function $_(u,f,g,b){for(;u.nodeType===1;){var T=g;if(u.nodeName.toLowerCase()!==f.toLowerCase()){if(!b&&(u.nodeName!=="INPUT"||u.type!=="hidden"))break}else if(b){if(!u[Ho])switch(f){case"meta":if(!u.hasAttribute("itemprop"))break;return u;case"link":if(D=u.getAttribute("rel"),D==="stylesheet"&&u.hasAttribute("data-precedence"))break;if(D!==T.rel||u.getAttribute("href")!==(T.href==null||T.href===""?null:T.href)||u.getAttribute("crossorigin")!==(T.crossOrigin==null?null:T.crossOrigin)||u.getAttribute("title")!==(T.title==null?null:T.title))break;return u;case"style":if(u.hasAttribute("data-precedence"))break;return u;case"script":if(D=u.getAttribute("src"),(D!==(T.src==null?null:T.src)||u.getAttribute("type")!==(T.type==null?null:T.type)||u.getAttribute("crossorigin")!==(T.crossOrigin==null?null:T.crossOrigin))&&D&&u.hasAttribute("async")&&!u.hasAttribute("itemprop"))break;return u;default:return u}}else if(f==="input"&&u.type==="hidden"){var D=T.name==null?null:""+T.name;if(T.type==="hidden"&&u.getAttribute("name")===D)return u}else return u;if(u=el(u.nextSibling),u===null)break}return null}function Hh(u,f,g){if(f==="")return null;for(;u.nodeType!==3;)if((u.nodeType!==1||u.nodeName!=="INPUT"||u.type!=="hidden")&&!g||(u=el(u.nextSibling),u===null))return null;return u}function B_(u){return u.data==="$!"||u.data==="$?"&&u.ownerDocument.readyState==="complete"}function L_(u,f){var g=u.ownerDocument;if(u.data!=="$?"||g.readyState==="complete")f();else{var b=function(){f(),g.removeEventListener("DOMContentLoaded",b)};g.addEventListener("DOMContentLoaded",b),u._reactRetry=b}}function el(u){for(;u!=null;u=u.nextSibling){var f=u.nodeType;if(f===1||f===3)break;if(f===8){if(f=u.data,f==="$"||f==="$!"||f==="$?"||f==="F!"||f==="F")break;if(f==="/$")return null}}return u}var N_=null;function Kf(u){u=u.previousSibling;for(var f=0;u;){if(u.nodeType===8){var g=u.data;if(g==="$"||g==="$!"||g==="$?"){if(f===0)return u;f--}else g==="/$"&&f++}u=u.previousSibling}return null}function bo(u,f,g){switch(f=Ph(g),u){case"html":if(u=f.documentElement,!u)throw Error(r(452));return u;case"head":if(u=f.head,!u)throw Error(r(453));return u;case"body":if(u=f.body,!u)throw Error(r(454));return u;default:throw Error(r(451))}}function Bt(u){for(var f=u.attributes;f.length;)u.removeAttributeNode(f[0]);Dt(u)}var Si=new Map,_s=new Set;function oo(u){return typeof u.getRootNode=="function"?u.getRootNode():u.nodeType===9?u:u.ownerDocument}var Ru=se.d;se.d={f:SM,r:xy,D:Rl,C:Du,L:by,m:$c,X:Ra,S:$o,M:Bc};function SM(){var u=Ru.f(),f=j0();return u||f}function xy(u){var f=rr(u);f!==null&&f.tag===5&&f.type==="form"?YT(f):Ru.r(u)}var Ou=typeof document>"u"?null:document;function Ya(u,f,g){var b=Ou;if(b&&typeof f=="string"&&f){var T=ai(f);T='link[rel="'+u+'"][href="'+T+'"]',typeof g=="string"&&(T+='[crossorigin="'+g+'"]'),_s.has(T)||(_s.add(T),u={rel:u,crossOrigin:g,href:f},b.querySelector(T)===null&&(f=b.createElement("link"),Fe(f,"link",u),qn(f),b.head.appendChild(f)))}}function Rl(u){Ru.D(u),Ya("dns-prefetch",u,null)}function Du(u,f){Ru.C(u,f),Ya("preconnect",u,f)}function by(u,f,g){Ru.L(u,f,g);var b=Ou;if(b&&u&&f){var T='link[rel="preload"][as="'+ai(f)+'"]';f==="image"&&g&&g.imageSrcSet?(T+='[imagesrcset="'+ai(g.imageSrcSet)+'"]',typeof g.imageSizes=="string"&&(T+='[imagesizes="'+ai(g.imageSizes)+'"]')):T+='[href="'+ai(u)+'"]';var D=T;switch(f){case"style":D=qh(u);break;case"script":D=Wf(u)}Si.has(D)||(u=y({rel:"preload",href:f==="image"&&g&&g.imageSrcSet?void 0:u,as:f},g),Si.set(D,u),b.querySelector(T)!==null||f==="style"&&b.querySelector(X0(D))||f==="script"&&b.querySelector(tl(D))||(f=b.createElement("link"),Fe(f,"link",u),qn(f),b.head.appendChild(f)))}}function $c(u,f){Ru.m(u,f);var g=Ou;if(g&&u){var b=f&&typeof f.as=="string"?f.as:"script",T='link[rel="modulepreload"][as="'+ai(b)+'"][href="'+ai(u)+'"]',D=T;switch(b){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":D=Wf(u)}if(!Si.has(D)&&(u=y({rel:"modulepreload",href:u},f),Si.set(D,u),g.querySelector(T)===null)){switch(b){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(g.querySelector(tl(D)))return}b=g.createElement("link"),Fe(b,"link",u),qn(b),g.head.appendChild(b)}}}function $o(u,f,g){Ru.S(u,f,g);var b=Ou;if(b&&u){var T=po(b).hoistableStyles,D=qh(u);f=f||"default";var q=T.get(D);if(!q){var K={loading:0,preload:null};if(q=b.querySelector(X0(D)))K.loading=5;else{u=y({rel:"stylesheet",href:u,"data-precedence":f},g),(g=Si.get(D))&&F_(u,g);var ge=q=b.createElement("link");qn(ge),Fe(ge,"link",u),ge._p=new Promise(function(Be,Ke){ge.onload=Be,ge.onerror=Ke}),ge.addEventListener("load",function(){K.loading|=1}),ge.addEventListener("error",function(){K.loading|=2}),K.loading|=4,wy(q,f,b)}q={type:"stylesheet",instance:q,count:1,state:K},T.set(D,q)}}}function Ra(u,f){Ru.X(u,f);var g=Ou;if(g&&u){var b=po(g).hoistableScripts,T=Wf(u),D=b.get(T);D||(D=g.querySelector(tl(T)),D||(u=y({src:u,async:!0},f),(f=Si.get(T))&&Cy(u,f),D=g.createElement("script"),qn(D),Fe(D,"link",u),g.head.appendChild(D)),D={type:"script",instance:D,count:1,state:null},b.set(T,D))}}function Bc(u,f){Ru.M(u,f);var g=Ou;if(g&&u){var b=po(g).hoistableScripts,T=Wf(u),D=b.get(T);D||(D=g.querySelector(tl(T)),D||(u=y({src:u,async:!0,type:"module"},f),(f=Si.get(T))&&Cy(u,f),D=g.createElement("script"),qn(D),Fe(D,"link",u),g.head.appendChild(D)),D={type:"script",instance:D,count:1,state:null},b.set(T,D))}}function _y(u,f,g,b){var T=(T=Te.current)?oo(T):null;if(!T)throw Error(r(446));switch(u){case"meta":case"title":return null;case"style":return typeof g.precedence=="string"&&typeof g.href=="string"?(f=qh(g.href),g=po(T).hoistableStyles,b=g.get(f),b||(b={type:"style",instance:null,count:0,state:null},g.set(f,b)),b):{type:"void",instance:null,count:0,state:null};case"link":if(g.rel==="stylesheet"&&typeof g.href=="string"&&typeof g.precedence=="string"){u=qh(g.href);var D=po(T).hoistableStyles,q=D.get(u);if(q||(T=T.ownerDocument||T,q={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},D.set(u,q),(D=T.querySelector(X0(u)))&&!D._p&&(q.instance=D,q.state.loading=5),Si.has(u)||(g={rel:"preload",as:"style",href:g.href,crossOrigin:g.crossOrigin,integrity:g.integrity,media:g.media,hrefLang:g.hrefLang,referrerPolicy:g.referrerPolicy},Si.set(u,g),D||J0(T,u,g,q.state))),f&&b===null)throw Error(r(528,""));return q}if(f&&b!==null)throw Error(r(529,""));return null;case"script":return f=g.async,g=g.src,typeof g=="string"&&f&&typeof f!="function"&&typeof f!="symbol"?(f=Wf(g),g=po(T).hoistableScripts,b=g.get(f),b||(b={type:"script",instance:null,count:0,state:null},g.set(f,b)),b):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,u))}}function qh(u){return'href="'+ai(u)+'"'}function X0(u){return'link[rel="stylesheet"]['+u+"]"}function z_(u){return y({},u,{"data-precedence":u.precedence,precedence:null})}function J0(u,f,g,b){u.querySelector('link[rel="preload"][as="style"]['+f+"]")?b.loading=1:(f=u.createElement("link"),b.preload=f,f.addEventListener("load",function(){return b.loading|=1}),f.addEventListener("error",function(){return b.loading|=2}),Fe(f,"link",g),qn(f),u.head.appendChild(f))}function Wf(u){return'[src="'+ai(u)+'"]'}function tl(u){return"script[async]"+u}function Sy(u,f,g){if(f.count++,f.instance===null)switch(f.type){case"style":var b=u.querySelector('style[data-href~="'+ai(g.href)+'"]');if(b)return f.instance=b,qn(b),b;var T=y({},g,{"data-href":g.href,"data-precedence":g.precedence,href:null,precedence:null});return b=(u.ownerDocument||u).createElement("style"),qn(b),Fe(b,"style",T),wy(b,g.precedence,u),f.instance=b;case"stylesheet":T=qh(g.href);var D=u.querySelector(X0(T));if(D)return f.state.loading|=4,f.instance=D,qn(D),D;b=z_(g),(T=Si.get(T))&&F_(b,T),D=(u.ownerDocument||u).createElement("link"),qn(D);var q=D;return q._p=new Promise(function(K,ge){q.onload=K,q.onerror=ge}),Fe(D,"link",b),f.state.loading|=4,wy(D,g.precedence,u),f.instance=D;case"script":return D=Wf(g.src),(T=u.querySelector(tl(D)))?(f.instance=T,qn(T),T):(b=g,(T=Si.get(D))&&(b=y({},g),Cy(b,T)),u=u.ownerDocument||u,T=u.createElement("script"),qn(T),Fe(T,"link",b),u.head.appendChild(T),f.instance=T);case"void":return null;default:throw Error(r(443,f.type))}else f.type==="stylesheet"&&(f.state.loading&4)===0&&(b=f.instance,f.state.loading|=4,wy(b,g.precedence,u));return f.instance}function wy(u,f,g){for(var b=g.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),T=b.length?b[b.length-1]:null,D=T,q=0;q<b.length;q++){var K=b[q];if(K.dataset.precedence===f)D=K;else if(D!==T)break}D?D.parentNode.insertBefore(u,D.nextSibling):(f=g.nodeType===9?g.head:g,f.insertBefore(u,f.firstChild))}function F_(u,f){u.crossOrigin==null&&(u.crossOrigin=f.crossOrigin),u.referrerPolicy==null&&(u.referrerPolicy=f.referrerPolicy),u.title==null&&(u.title=f.title)}function Cy(u,f){u.crossOrigin==null&&(u.crossOrigin=f.crossOrigin),u.referrerPolicy==null&&(u.referrerPolicy=f.referrerPolicy),u.integrity==null&&(u.integrity=f.integrity)}var eg=null;function Gh(u,f,g){if(eg===null){var b=new Map,T=eg=new Map;T.set(g,b)}else T=eg,b=T.get(g),b||(b=new Map,T.set(g,b));if(b.has(u))return b;for(b.set(u,null),g=g.getElementsByTagName(u),T=0;T<g.length;T++){var D=g[T];if(!(D[Ho]||D[nn]||u==="link"&&D.getAttribute("rel")==="stylesheet")&&D.namespaceURI!=="http://www.w3.org/2000/svg"){var q=D.getAttribute(f)||"";q=u+q;var K=b.get(q);K?K.push(D):b.set(q,[D])}}return b}function U_(u,f,g){u=u.ownerDocument||u,u.head.insertBefore(g,f==="title"?u.querySelector("head > title"):null)}function C4(u,f,g){if(g===1||f.itemProp!=null)return!1;switch(u){case"meta":case"title":return!0;case"style":if(typeof f.precedence!="string"||typeof f.href!="string"||f.href==="")break;return!0;case"link":if(typeof f.rel!="string"||typeof f.href!="string"||f.href===""||f.onLoad||f.onError)break;switch(f.rel){case"stylesheet":return u=f.disabled,typeof f.precedence=="string"&&u==null;default:return!0}case"script":if(f.async&&typeof f.async!="function"&&typeof f.async!="symbol"&&!f.onLoad&&!f.onError&&f.src&&typeof f.src=="string")return!0}return!1}function j_(u){return!(u.type==="stylesheet"&&(u.state.loading&3)===0)}var Vh=null;function E4(){}function A4(u,f,g){if(Vh===null)throw Error(r(475));var b=Vh;if(f.type==="stylesheet"&&(typeof g.media!="string"||matchMedia(g.media).matches!==!1)&&(f.state.loading&4)===0){if(f.instance===null){var T=qh(g.href),D=u.querySelector(X0(T));if(D){u=D._p,u!==null&&typeof u=="object"&&typeof u.then=="function"&&(b.count++,b=Yh.bind(b),u.then(b,b)),f.state.loading|=4,f.instance=D,qn(D);return}D=u.ownerDocument||u,g=z_(g),(T=Si.get(T))&&F_(g,T),D=D.createElement("link"),qn(D);var q=D;q._p=new Promise(function(K,ge){q.onload=K,q.onerror=ge}),Fe(D,"link",g),f.instance=D}b.stylesheets===null&&(b.stylesheets=new Map),b.stylesheets.set(f,u),(u=f.state.preload)&&(f.state.loading&3)===0&&(b.count++,f=Yh.bind(b),u.addEventListener("load",f),u.addEventListener("error",f))}}function k4(){if(Vh===null)throw Error(r(475));var u=Vh;return u.stylesheets&&u.count===0&&ng(u,u.stylesheets),0<u.count?function(f){var g=setTimeout(function(){if(u.stylesheets&&ng(u,u.stylesheets),u.unsuspend){var b=u.unsuspend;u.unsuspend=null,b()}},6e4);return u.unsuspend=f,function(){u.unsuspend=null,clearTimeout(g)}}:null}function Yh(){if(this.count--,this.count===0){if(this.stylesheets)ng(this,this.stylesheets);else if(this.unsuspend){var u=this.unsuspend;this.unsuspend=null,u()}}}var tg=null;function ng(u,f){u.stylesheets=null,u.unsuspend!==null&&(u.count++,tg=new Map,f.forEach(P_,u),tg=null,Yh.call(u))}function P_(u,f){if(!(f.state.loading&4)){var g=tg.get(u);if(g)var b=g.get(null);else{g=new Map,tg.set(u,g);for(var T=u.querySelectorAll("link[data-precedence],style[data-precedence]"),D=0;D<T.length;D++){var q=T[D];(q.nodeName==="LINK"||q.getAttribute("media")!=="not all")&&(g.set(q.dataset.precedence,q),b=q)}b&&g.set(null,b)}T=f.instance,q=T.getAttribute("data-precedence"),D=g.get(q)||b,D===b&&g.set(null,T),g.set(q,T),this.count++,b=Yh.bind(this),T.addEventListener("load",b),T.addEventListener("error",b),D?D.parentNode.insertBefore(T,D.nextSibling):(u=u.nodeType===9?u.head:u,u.insertBefore(T,u.firstChild)),f.state.loading|=4}}var _o={$$typeof:O,Provider:null,Consumer:null,_currentValue:pe,_currentValue2:pe,_threadCount:0};function Ol(u,f,g,b,T,D,q,K){this.tag=1,this.containerInfo=u,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=st(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=st(0),this.hiddenUpdates=st(null),this.identifierPrefix=b,this.onUncaughtError=T,this.onCaughtError=D,this.onRecoverableError=q,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=K,this.incompleteTransitions=new Map}function T4(u,f,g,b,T,D,q,K,ge,Be,Ke,tt){return u=new Ol(u,f,g,q,K,ge,Be,tt),f=1,D===!0&&(f|=24),D=pa(3,null,null,f),u.current=D,D.stateNode=u,f=bb(),f.refCount++,u.pooledCache=f,f.refCount++,D.memoizedState={element:b,isDehydrated:g,cache:f},v0(D),u}function H_(u){return u?(u=Of,u):Of}function q_(u,f,g,b,T,D){T=H_(T),b.context===null?b.context=T:b.pendingContext=T,b=pu(f),b.payload={element:g},D=D===void 0?null:D,D!==null&&(b.callback=D),g=va(u,b,f),g!==null&&(ka(g,u,f),If(g,u,f))}function G_(u,f){if(u=u.memoizedState,u!==null&&u.dehydrated!==null){var g=u.retryLane;u.retryLane=g!==0&&g<f?g:f}}function Ey(u,f){G_(u,f),(u=u.alternate)&&G_(u,f)}function V_(u){if(u.tag===13){var f=lu(u,67108864);f!==null&&ka(f,u,67108864),Ey(u,67108864)}}var rg=!0;function R4(u,f,g,b){var T=ue.T;ue.T=null;var D=se.p;try{se.p=2,Ay(u,f,g,b)}finally{se.p=D,ue.T=T}}function O4(u,f,g,b){var T=ue.T;ue.T=null;var D=se.p;try{se.p=8,Ay(u,f,g,b)}finally{se.p=D,ue.T=T}}function Ay(u,f,g,b){if(rg){var T=Y_(b);if(T===null)Z0(u,f,b,ig,g),Q_(u,b);else if(K_(T,u,f,g,b))b.stopPropagation();else if(Q_(u,b),f&4&&-1<wM.indexOf(u)){for(;T!==null;){var D=rr(T);if(D!==null)switch(D.tag){case 3:if(D=D.stateNode,D.current.memoizedState.isDehydrated){var q=pt(D.pendingLanes);if(q!==0){var K=D;for(K.pendingLanes|=2,K.entangledLanes|=2;q;){var ge=1<<31-ct(q);K.entanglements[1]|=ge,q&=~ge}Js(D),(vr&6)===0&&(Xv=yt()+500,Au(0))}}break;case 13:K=lu(D,2),K!==null&&ka(K,D,2),j0(),Ey(D,2)}if(D=Y_(b),D===null&&Z0(u,f,b,ig,g),D===T)break;T=D}T!==null&&b.stopPropagation()}else Z0(u,f,b,null,g)}}function Y_(u){return u=vf(u),Z_(u)}var ig=null;function Z_(u){if(ig=null,u=to(u),u!==null){var f=a(u);if(f===null)u=null;else{var g=f.tag;if(g===13){if(u=l(f),u!==null)return u;u=null}else if(g===3){if(f.stateNode.current.memoizedState.isDehydrated)return f.tag===3?f.stateNode.containerInfo:null;u=null}else f!==u&&(u=null)}}return ig=u,null}function D4(u){switch(u){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(re()){case le:return 2;case ve:return 8;case Ee:case $e:return 32;case Ve:return 268435456;default:return 32}default:return 32}}var ky=!1,nl=null,Dl=null,Mu=null,Zh=new Map,og=new Map,Lc=[],wM="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Q_(u,f){switch(u){case"focusin":case"focusout":nl=null;break;case"dragenter":case"dragleave":Dl=null;break;case"mouseover":case"mouseout":Mu=null;break;case"pointerover":case"pointerout":Zh.delete(f.pointerId);break;case"gotpointercapture":case"lostpointercapture":og.delete(f.pointerId)}}function Ml(u,f,g,b,T,D){return u===null||u.nativeEvent!==D?(u={blockedOn:f,domEventName:g,eventSystemFlags:b,nativeEvent:D,targetContainers:[T]},f!==null&&(f=rr(f),f!==null&&V_(f)),u):(u.eventSystemFlags|=b,f=u.targetContainers,T!==null&&f.indexOf(T)===-1&&f.push(T),u)}function K_(u,f,g,b,T){switch(f){case"focusin":return nl=Ml(nl,u,f,g,b,T),!0;case"dragenter":return Dl=Ml(Dl,u,f,g,b,T),!0;case"mouseover":return Mu=Ml(Mu,u,f,g,b,T),!0;case"pointerover":var D=T.pointerId;return Zh.set(D,Ml(Zh.get(D)||null,u,f,g,b,T)),!0;case"gotpointercapture":return D=T.pointerId,og.set(D,Ml(og.get(D)||null,u,f,g,b,T)),!0}return!1}function W_(u){var f=to(u.target);if(f!==null){var g=a(f);if(g!==null){if(f=g.tag,f===13){if(f=l(g),f!==null){u.blockedOn=f,xr(u.priority,function(){if(g.tag===13){var b=Ga();b=qt(b);var T=lu(g,b);T!==null&&ka(T,g,b),Ey(g,b)}});return}}else if(f===3&&g.stateNode.current.memoizedState.isDehydrated){u.blockedOn=g.tag===3?g.stateNode.containerInfo:null;return}}}u.blockedOn=null}function ag(u){if(u.blockedOn!==null)return!1;for(var f=u.targetContainers;0<f.length;){var g=Y_(u.nativeEvent);if(g===null){g=u.nativeEvent;var b=new g.constructor(g.type,g);Km=b,g.target.dispatchEvent(b),Km=null}else return f=rr(g),f!==null&&V_(f),u.blockedOn=g,!1;f.shift()}return!0}function X_(u,f,g){ag(u)&&g.delete(f)}function Ty(){ky=!1,nl!==null&&ag(nl)&&(nl=null),Dl!==null&&ag(Dl)&&(Dl=null),Mu!==null&&ag(Mu)&&(Mu=null),Zh.forEach(X_),og.forEach(X_)}function Iu(u,f){u.blockedOn===f&&(u.blockedOn=null,ky||(ky=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,Ty)))}var Ry=null;function sg(u){Ry!==u&&(Ry=u,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){Ry===u&&(Ry=null);for(var f=0;f<u.length;f+=3){var g=u[f],b=u[f+1],T=u[f+2];if(typeof b!="function"){if(Z_(b||g)===null)continue;break}var D=rr(g);D!==null&&(u.splice(f,3),f-=3,Hb(D,{pending:!0,data:T,method:g.method,action:b},b,T))}}))}function Qh(u){function f(ge){return Iu(ge,u)}nl!==null&&Iu(nl,u),Dl!==null&&Iu(Dl,u),Mu!==null&&Iu(Mu,u),Zh.forEach(f),og.forEach(f);for(var g=0;g<Lc.length;g++){var b=Lc[g];b.blockedOn===u&&(b.blockedOn=null)}for(;0<Lc.length&&(g=Lc[0],g.blockedOn===null);)W_(g),g.blockedOn===null&&Lc.shift();if(g=(u.ownerDocument||u).$$reactFormReplay,g!=null)for(b=0;b<g.length;b+=3){var T=g[b],D=g[b+1],q=T[yn]||null;if(typeof D=="function")q||sg(g);else if(q){var K=null;if(D&&D.hasAttribute("formAction")){if(T=D,q=D[yn]||null)K=q.formAction;else if(Z_(T)!==null)continue}else K=q.action;typeof K=="function"?g[b+1]=K:(g.splice(b,3),b-=3),sg(g)}}}function Nc(u){this._internalRoot=u}Oy.prototype.render=Nc.prototype.render=function(u){var f=this._internalRoot;if(f===null)throw Error(r(409));var g=f.current,b=Ga();q_(g,b,u,f,null,null)},Oy.prototype.unmount=Nc.prototype.unmount=function(){var u=this._internalRoot;if(u!==null){this._internalRoot=null;var f=u.containerInfo;q_(u.current,2,null,u,null,null),j0(),f[fn]=null}};function Oy(u){this._internalRoot=u}Oy.prototype.unstable_scheduleHydration=function(u){if(u){var f=hr();u={blockedOn:null,target:u,priority:f};for(var g=0;g<Lc.length&&f!==0&&f<Lc[g].priority;g++);Lc.splice(g,0,u),g===0&&W_(u)}};var M4=t.version;if(M4!=="19.1.0")throw Error(r(527,M4,"19.1.0"));se.findDOMNode=function(u){var f=u._reactInternals;if(f===void 0)throw typeof u.render=="function"?Error(r(188)):(u=Object.keys(u).join(","),Error(r(268,u)));return u=h(f),u=u!==null?p(u):null,u=u===null?null:u.stateNode,u};var I4={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:ue,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ao=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ao.isDisabled&&ao.supportsFiber)try{_e=ao.inject(I4),Re=ao}catch{}}return s1.createRoot=function(u,f){if(!o(u))throw Error(r(299));var g=!1,b="",T=Wb,D=Ah,q=Xb,K=null;return f!=null&&(f.unstable_strictMode===!0&&(g=!0),f.identifierPrefix!==void 0&&(b=f.identifierPrefix),f.onUncaughtError!==void 0&&(T=f.onUncaughtError),f.onCaughtError!==void 0&&(D=f.onCaughtError),f.onRecoverableError!==void 0&&(q=f.onRecoverableError),f.unstable_transitionCallbacks!==void 0&&(K=f.unstable_transitionCallbacks)),f=T4(u,1,!1,null,null,g,b,T,D,q,K,null),u[fn]=f.current,Y0(u),new Nc(f)},s1.hydrateRoot=function(u,f,g){if(!o(u))throw Error(r(299));var b=!1,T="",D=Wb,q=Ah,K=Xb,ge=null,Be=null;return g!=null&&(g.unstable_strictMode===!0&&(b=!0),g.identifierPrefix!==void 0&&(T=g.identifierPrefix),g.onUncaughtError!==void 0&&(D=g.onUncaughtError),g.onCaughtError!==void 0&&(q=g.onCaughtError),g.onRecoverableError!==void 0&&(K=g.onRecoverableError),g.unstable_transitionCallbacks!==void 0&&(ge=g.unstable_transitionCallbacks),g.formState!==void 0&&(Be=g.formState)),f=T4(u,1,!0,f,g??null,b,T,D,q,K,ge,Be),f.context=H_(null),g=f.current,b=Ga(),b=qt(b),T=pu(b),T.callback=null,va(g,T,b),g=b,f.current.lanes=g,St(f,g),Js(f),u[fn]=f.current,Y0(u),new Oy(f)},s1.version="19.1.0",s1}var l1={},$5;function EV(){if($5)return l1;$5=1;var e={};/**
81
+ `).replace(Va,"")}function _4(u,f){return f=vy(f),vy(u)===f}function Q0(){}function Rr(u,f,g,b,T,D){switch(g){case"children":typeof b=="string"?f==="body"||f==="textarea"&&b===""||mf(u,b):(typeof b=="number"||typeof b=="bigint")&&f!=="body"&&mf(u,""+b);break;case"className":ce(u,"class",b);break;case"tabIndex":ce(u,"tabindex",b);break;case"dir":case"role":case"viewBox":case"width":case"height":ce(u,g,b);break;case"style":Qm(u,b,D);break;case"data":if(f!=="object"){ce(u,"data",b);break}case"src":case"href":if(b===""&&(f!=="a"||g!=="href")){u.removeAttribute(g);break}if(b==null||typeof b=="function"||typeof b=="symbol"||typeof b=="boolean"){u.removeAttribute(g);break}b=Kp(""+b),u.setAttribute(g,b);break;case"action":case"formAction":if(typeof b=="function"){u.setAttribute(g,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof D=="function"&&(g==="formAction"?(f!=="input"&&Rr(u,f,"name",T.name,T,null),Rr(u,f,"formEncType",T.formEncType,T,null),Rr(u,f,"formMethod",T.formMethod,T,null),Rr(u,f,"formTarget",T.formTarget,T,null)):(Rr(u,f,"encType",T.encType,T,null),Rr(u,f,"method",T.method,T,null),Rr(u,f,"target",T.target,T,null)));if(b==null||typeof b=="symbol"||typeof b=="boolean"){u.removeAttribute(g);break}b=Kp(""+b),u.setAttribute(g,b);break;case"onClick":b!=null&&(u.onclick=Q0);break;case"onScroll":b!=null&&xn("scroll",u);break;case"onScrollEnd":b!=null&&xn("scrollend",u);break;case"dangerouslySetInnerHTML":if(b!=null){if(typeof b!="object"||!("__html"in b))throw Error(r(61));if(g=b.__html,g!=null){if(T.children!=null)throw Error(r(60));u.innerHTML=g}}break;case"multiple":u.multiple=b&&typeof b!="function"&&typeof b!="symbol";break;case"muted":u.muted=b&&typeof b!="function"&&typeof b!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(b==null||typeof b=="function"||typeof b=="boolean"||typeof b=="symbol"){u.removeAttribute("xlink:href");break}g=Kp(""+b),u.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",g);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":b!=null&&typeof b!="function"&&typeof b!="symbol"?u.setAttribute(g,""+b):u.removeAttribute(g);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":b&&typeof b!="function"&&typeof b!="symbol"?u.setAttribute(g,""):u.removeAttribute(g);break;case"capture":case"download":b===!0?u.setAttribute(g,""):b!==!1&&b!=null&&typeof b!="function"&&typeof b!="symbol"?u.setAttribute(g,b):u.removeAttribute(g);break;case"cols":case"rows":case"size":case"span":b!=null&&typeof b!="function"&&typeof b!="symbol"&&!isNaN(b)&&1<=b?u.setAttribute(g,b):u.removeAttribute(g);break;case"rowSpan":case"start":b==null||typeof b=="function"||typeof b=="symbol"||isNaN(b)?u.removeAttribute(g):u.setAttribute(g,b);break;case"popover":xn("beforetoggle",u),xn("toggle",u),at(u,"popover",b);break;case"xlinkActuate":Ie(u,"http://www.w3.org/1999/xlink","xlink:actuate",b);break;case"xlinkArcrole":Ie(u,"http://www.w3.org/1999/xlink","xlink:arcrole",b);break;case"xlinkRole":Ie(u,"http://www.w3.org/1999/xlink","xlink:role",b);break;case"xlinkShow":Ie(u,"http://www.w3.org/1999/xlink","xlink:show",b);break;case"xlinkTitle":Ie(u,"http://www.w3.org/1999/xlink","xlink:title",b);break;case"xlinkType":Ie(u,"http://www.w3.org/1999/xlink","xlink:type",b);break;case"xmlBase":Ie(u,"http://www.w3.org/XML/1998/namespace","xml:base",b);break;case"xmlLang":Ie(u,"http://www.w3.org/XML/1998/namespace","xml:lang",b);break;case"xmlSpace":Ie(u,"http://www.w3.org/XML/1998/namespace","xml:space",b);break;case"is":at(u,"is",b);break;case"innerText":case"textContent":break;default:(!(2<g.length)||g[0]!=="o"&&g[0]!=="O"||g[1]!=="n"&&g[1]!=="N")&&(g=Qp.get(g)||g,at(u,g,b))}}function Gi(u,f,g,b,T,D){switch(g){case"style":Qm(u,b,D);break;case"dangerouslySetInnerHTML":if(b!=null){if(typeof b!="object"||!("__html"in b))throw Error(r(61));if(g=b.__html,g!=null){if(T.children!=null)throw Error(r(60));u.innerHTML=g}}break;case"children":typeof b=="string"?mf(u,b):(typeof b=="number"||typeof b=="bigint")&&mf(u,""+b);break;case"onScroll":b!=null&&xn("scroll",u);break;case"onScrollEnd":b!=null&&xn("scrollend",u);break;case"onClick":b!=null&&(u.onclick=Q0);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Oi.hasOwnProperty(g))e:{if(g[0]==="o"&&g[1]==="n"&&(T=g.endsWith("Capture"),f=g.slice(2,T?g.length-7:void 0),D=u[yn]||null,D=D!=null?D[g]:null,typeof D=="function"&&u.removeEventListener(f,D,T),typeof b=="function")){typeof D!="function"&&D!==null&&(g in u?u[g]=null:u.hasAttribute(g)&&u.removeAttribute(g)),u.addEventListener(f,b,T);break e}g in u?u[g]=b:b===!0?u.setAttribute(g,""):at(u,g,b)}}}function Fe(u,f,g){switch(f){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":xn("error",u),xn("load",u);var b=!1,T=!1,D;for(D in g)if(g.hasOwnProperty(D)){var q=g[D];if(q!=null)switch(D){case"src":b=!0;break;case"srcSet":T=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,f));default:Rr(u,f,D,q,g,null)}}T&&Rr(u,f,"srcSet",g.srcSet,g,null),b&&Rr(u,f,"src",g.src,g,null);return;case"input":xn("invalid",u);var K=D=q=T=null,ge=null,Be=null;for(b in g)if(g.hasOwnProperty(b)){var Ke=g[b];if(Ke!=null)switch(b){case"name":T=Ke;break;case"type":q=Ke;break;case"checked":ge=Ke;break;case"defaultChecked":Be=Ke;break;case"value":D=Ke;break;case"defaultValue":K=Ke;break;case"children":case"dangerouslySetInnerHTML":if(Ke!=null)throw Error(r(137,f));break;default:Rr(u,f,b,Ke,g,null)}}Yp(u,D,K,ge,Be,q,T,!1),dn(u);return;case"select":xn("invalid",u),b=q=D=null;for(T in g)if(g.hasOwnProperty(T)&&(K=g[T],K!=null))switch(T){case"value":D=K;break;case"defaultValue":q=K;break;case"multiple":b=K;default:Rr(u,f,T,K,g,null)}f=D,g=q,u.multiple=!!b,f!=null?rc(u,!!b,f,!1):g!=null&&rc(u,!!b,g,!0);return;case"textarea":xn("invalid",u),D=T=b=null;for(q in g)if(g.hasOwnProperty(q)&&(K=g[q],K!=null))switch(q){case"value":b=K;break;case"defaultValue":T=K;break;case"children":D=K;break;case"dangerouslySetInnerHTML":if(K!=null)throw Error(r(91));break;default:Rr(u,f,q,K,g,null)}Kx(u,b,T,D),dn(u);return;case"option":for(ge in g)if(g.hasOwnProperty(ge)&&(b=g[ge],b!=null))switch(ge){case"selected":u.selected=b&&typeof b!="function"&&typeof b!="symbol";break;default:Rr(u,f,ge,b,g,null)}return;case"dialog":xn("beforetoggle",u),xn("toggle",u),xn("cancel",u),xn("close",u);break;case"iframe":case"object":xn("load",u);break;case"video":case"audio":for(b=0;b<hn.length;b++)xn(hn[b],u);break;case"image":xn("error",u),xn("load",u);break;case"details":xn("toggle",u);break;case"embed":case"source":case"link":xn("error",u),xn("load",u);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(Be in g)if(g.hasOwnProperty(Be)&&(b=g[Be],b!=null))switch(Be){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,f));default:Rr(u,f,Be,b,g,null)}return;default:if(Yd(f)){for(Ke in g)g.hasOwnProperty(Ke)&&(b=g[Ke],b!==void 0&&Gi(u,f,Ke,b,g,void 0));return}}for(K in g)g.hasOwnProperty(K)&&(b=g[K],b!=null&&Rr(u,f,K,b,g,null))}function cr(u,f,g,b){switch(f){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var T=null,D=null,q=null,K=null,ge=null,Be=null,Ke=null;for(je in g){var tt=g[je];if(g.hasOwnProperty(je)&&tt!=null)switch(je){case"checked":break;case"value":break;case"defaultValue":ge=tt;default:b.hasOwnProperty(je)||Rr(u,f,je,null,b,tt)}}for(var Ne in b){var je=b[Ne];if(tt=g[Ne],b.hasOwnProperty(Ne)&&(je!=null||tt!=null))switch(Ne){case"type":D=je;break;case"name":T=je;break;case"checked":Be=je;break;case"defaultChecked":Ke=je;break;case"value":q=je;break;case"defaultValue":K=je;break;case"children":case"dangerouslySetInnerHTML":if(je!=null)throw Error(r(137,f));break;default:je!==tt&&Rr(u,f,Ne,je,b,tt)}}go(u,q,K,ge,Be,Ke,D,T);return;case"select":je=q=K=Ne=null;for(D in g)if(ge=g[D],g.hasOwnProperty(D)&&ge!=null)switch(D){case"value":break;case"multiple":je=ge;default:b.hasOwnProperty(D)||Rr(u,f,D,null,b,ge)}for(T in b)if(D=b[T],ge=g[T],b.hasOwnProperty(T)&&(D!=null||ge!=null))switch(T){case"value":Ne=D;break;case"defaultValue":K=D;break;case"multiple":q=D;default:D!==ge&&Rr(u,f,T,D,b,ge)}f=K,g=q,b=je,Ne!=null?rc(u,!!g,Ne,!1):!!b!=!!g&&(f!=null?rc(u,!!g,f,!0):rc(u,!!g,g?[]:"",!1));return;case"textarea":je=Ne=null;for(K in g)if(T=g[K],g.hasOwnProperty(K)&&T!=null&&!b.hasOwnProperty(K))switch(K){case"value":break;case"children":break;default:Rr(u,f,K,null,b,T)}for(q in b)if(T=b[q],D=g[q],b.hasOwnProperty(q)&&(T!=null||D!=null))switch(q){case"value":Ne=T;break;case"defaultValue":je=T;break;case"children":break;case"dangerouslySetInnerHTML":if(T!=null)throw Error(r(91));break;default:T!==D&&Rr(u,f,q,T,b,D)}Qx(u,Ne,je);return;case"option":for(var rn in g)if(Ne=g[rn],g.hasOwnProperty(rn)&&Ne!=null&&!b.hasOwnProperty(rn))switch(rn){case"selected":u.selected=!1;break;default:Rr(u,f,rn,null,b,Ne)}for(ge in b)if(Ne=b[ge],je=g[ge],b.hasOwnProperty(ge)&&Ne!==je&&(Ne!=null||je!=null))switch(ge){case"selected":u.selected=Ne&&typeof Ne!="function"&&typeof Ne!="symbol";break;default:Rr(u,f,ge,Ne,b,je)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Jt in g)Ne=g[Jt],g.hasOwnProperty(Jt)&&Ne!=null&&!b.hasOwnProperty(Jt)&&Rr(u,f,Jt,null,b,Ne);for(Be in b)if(Ne=b[Be],je=g[Be],b.hasOwnProperty(Be)&&Ne!==je&&(Ne!=null||je!=null))switch(Be){case"children":case"dangerouslySetInnerHTML":if(Ne!=null)throw Error(r(137,f));break;default:Rr(u,f,Be,Ne,b,je)}return;default:if(Yd(f)){for(var fr in g)Ne=g[fr],g.hasOwnProperty(fr)&&Ne!==void 0&&!b.hasOwnProperty(fr)&&Gi(u,f,fr,void 0,b,Ne);for(Ke in b)Ne=b[Ke],je=g[Ke],!b.hasOwnProperty(Ke)||Ne===je||Ne===void 0&&je===void 0||Gi(u,f,Ke,Ne,b,je);return}}for(var De in g)Ne=g[De],g.hasOwnProperty(De)&&Ne!=null&&!b.hasOwnProperty(De)&&Rr(u,f,De,null,b,Ne);for(tt in b)Ne=b[tt],je=g[tt],!b.hasOwnProperty(tt)||Ne===je||Ne==null&&je==null||Rr(u,f,tt,Ne,b,je)}var M_=null,K0=null;function Ph(u){return u.nodeType===9?u:u.ownerDocument}function Al(u){switch(u){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Tu(u,f){if(u===0)switch(f){case"svg":return 1;case"math":return 2;default:return 0}return u===1&&f==="foreignObject"?0:u}function Qf(u,f){return u==="textarea"||u==="noscript"||typeof f.children=="string"||typeof f.children=="number"||typeof f.children=="bigint"||typeof f.dangerouslySetInnerHTML=="object"&&f.dangerouslySetInnerHTML!==null&&f.dangerouslySetInnerHTML.__html!=null}var kl=null;function yy(){var u=window.event;return u&&u.type==="popstate"?u===kl?!1:(kl=u,!0):(kl=null,!1)}var Tl=typeof setTimeout=="function"?setTimeout:void 0,I_=typeof clearTimeout=="function"?clearTimeout:void 0,S4=typeof Promise=="function"?Promise:void 0,bM=typeof queueMicrotask=="function"?queueMicrotask:typeof S4<"u"?function(u){return S4.resolve(null).then(u).catch(_M)}:Tl;function _M(u){setTimeout(function(){throw u})}function xo(u){return u==="head"}function w4(u,f){var g=f,b=0,T=0;do{var D=g.nextSibling;if(u.removeChild(g),D&&D.nodeType===8)if(g=D.data,g==="/$"){if(0<b&&8>b){g=b;var q=u.ownerDocument;if(g&1&&Bt(q.documentElement),g&2&&Bt(q.body),g&4)for(g=q.head,Bt(g),q=g.firstChild;q;){var K=q.nextSibling,ge=q.nodeName;q[Ho]||ge==="SCRIPT"||ge==="STYLE"||ge==="LINK"&&q.rel.toLowerCase()==="stylesheet"||g.removeChild(q),q=K}}if(T===0){u.removeChild(D),Qh(f);return}T--}else g==="$"||g==="$?"||g==="$!"?T++:b=g.charCodeAt(0)-48;else b=0;g=D}while(g);Qh(f)}function W0(u){var f=u.firstChild;for(f&&f.nodeType===10&&(f=f.nextSibling);f;){var g=f;switch(f=f.nextSibling,g.nodeName){case"HTML":case"HEAD":case"BODY":W0(g),Dt(g);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(g.rel.toLowerCase()==="stylesheet")continue}u.removeChild(g)}}function $_(u,f,g,b){for(;u.nodeType===1;){var T=g;if(u.nodeName.toLowerCase()!==f.toLowerCase()){if(!b&&(u.nodeName!=="INPUT"||u.type!=="hidden"))break}else if(b){if(!u[Ho])switch(f){case"meta":if(!u.hasAttribute("itemprop"))break;return u;case"link":if(D=u.getAttribute("rel"),D==="stylesheet"&&u.hasAttribute("data-precedence"))break;if(D!==T.rel||u.getAttribute("href")!==(T.href==null||T.href===""?null:T.href)||u.getAttribute("crossorigin")!==(T.crossOrigin==null?null:T.crossOrigin)||u.getAttribute("title")!==(T.title==null?null:T.title))break;return u;case"style":if(u.hasAttribute("data-precedence"))break;return u;case"script":if(D=u.getAttribute("src"),(D!==(T.src==null?null:T.src)||u.getAttribute("type")!==(T.type==null?null:T.type)||u.getAttribute("crossorigin")!==(T.crossOrigin==null?null:T.crossOrigin))&&D&&u.hasAttribute("async")&&!u.hasAttribute("itemprop"))break;return u;default:return u}}else if(f==="input"&&u.type==="hidden"){var D=T.name==null?null:""+T.name;if(T.type==="hidden"&&u.getAttribute("name")===D)return u}else return u;if(u=el(u.nextSibling),u===null)break}return null}function Hh(u,f,g){if(f==="")return null;for(;u.nodeType!==3;)if((u.nodeType!==1||u.nodeName!=="INPUT"||u.type!=="hidden")&&!g||(u=el(u.nextSibling),u===null))return null;return u}function B_(u){return u.data==="$!"||u.data==="$?"&&u.ownerDocument.readyState==="complete"}function L_(u,f){var g=u.ownerDocument;if(u.data!=="$?"||g.readyState==="complete")f();else{var b=function(){f(),g.removeEventListener("DOMContentLoaded",b)};g.addEventListener("DOMContentLoaded",b),u._reactRetry=b}}function el(u){for(;u!=null;u=u.nextSibling){var f=u.nodeType;if(f===1||f===3)break;if(f===8){if(f=u.data,f==="$"||f==="$!"||f==="$?"||f==="F!"||f==="F")break;if(f==="/$")return null}}return u}var N_=null;function Kf(u){u=u.previousSibling;for(var f=0;u;){if(u.nodeType===8){var g=u.data;if(g==="$"||g==="$!"||g==="$?"){if(f===0)return u;f--}else g==="/$"&&f++}u=u.previousSibling}return null}function bo(u,f,g){switch(f=Ph(g),u){case"html":if(u=f.documentElement,!u)throw Error(r(452));return u;case"head":if(u=f.head,!u)throw Error(r(453));return u;case"body":if(u=f.body,!u)throw Error(r(454));return u;default:throw Error(r(451))}}function Bt(u){for(var f=u.attributes;f.length;)u.removeAttributeNode(f[0]);Dt(u)}var Si=new Map,_s=new Set;function oo(u){return typeof u.getRootNode=="function"?u.getRootNode():u.nodeType===9?u:u.ownerDocument}var Ru=se.d;se.d={f:SM,r:xy,D:Rl,C:Du,L:by,m:$c,X:Ra,S:$o,M:Bc};function SM(){var u=Ru.f(),f=j0();return u||f}function xy(u){var f=rr(u);f!==null&&f.tag===5&&f.type==="form"?YT(f):Ru.r(u)}var Ou=typeof document>"u"?null:document;function Ya(u,f,g){var b=Ou;if(b&&typeof f=="string"&&f){var T=ai(f);T='link[rel="'+u+'"][href="'+T+'"]',typeof g=="string"&&(T+='[crossorigin="'+g+'"]'),_s.has(T)||(_s.add(T),u={rel:u,crossOrigin:g,href:f},b.querySelector(T)===null&&(f=b.createElement("link"),Fe(f,"link",u),qn(f),b.head.appendChild(f)))}}function Rl(u){Ru.D(u),Ya("dns-prefetch",u,null)}function Du(u,f){Ru.C(u,f),Ya("preconnect",u,f)}function by(u,f,g){Ru.L(u,f,g);var b=Ou;if(b&&u&&f){var T='link[rel="preload"][as="'+ai(f)+'"]';f==="image"&&g&&g.imageSrcSet?(T+='[imagesrcset="'+ai(g.imageSrcSet)+'"]',typeof g.imageSizes=="string"&&(T+='[imagesizes="'+ai(g.imageSizes)+'"]')):T+='[href="'+ai(u)+'"]';var D=T;switch(f){case"style":D=qh(u);break;case"script":D=Wf(u)}Si.has(D)||(u=y({rel:"preload",href:f==="image"&&g&&g.imageSrcSet?void 0:u,as:f},g),Si.set(D,u),b.querySelector(T)!==null||f==="style"&&b.querySelector(X0(D))||f==="script"&&b.querySelector(tl(D))||(f=b.createElement("link"),Fe(f,"link",u),qn(f),b.head.appendChild(f)))}}function $c(u,f){Ru.m(u,f);var g=Ou;if(g&&u){var b=f&&typeof f.as=="string"?f.as:"script",T='link[rel="modulepreload"][as="'+ai(b)+'"][href="'+ai(u)+'"]',D=T;switch(b){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":D=Wf(u)}if(!Si.has(D)&&(u=y({rel:"modulepreload",href:u},f),Si.set(D,u),g.querySelector(T)===null)){switch(b){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(g.querySelector(tl(D)))return}b=g.createElement("link"),Fe(b,"link",u),qn(b),g.head.appendChild(b)}}}function $o(u,f,g){Ru.S(u,f,g);var b=Ou;if(b&&u){var T=po(b).hoistableStyles,D=qh(u);f=f||"default";var q=T.get(D);if(!q){var K={loading:0,preload:null};if(q=b.querySelector(X0(D)))K.loading=5;else{u=y({rel:"stylesheet",href:u,"data-precedence":f},g),(g=Si.get(D))&&F_(u,g);var ge=q=b.createElement("link");qn(ge),Fe(ge,"link",u),ge._p=new Promise(function(Be,Ke){ge.onload=Be,ge.onerror=Ke}),ge.addEventListener("load",function(){K.loading|=1}),ge.addEventListener("error",function(){K.loading|=2}),K.loading|=4,wy(q,f,b)}q={type:"stylesheet",instance:q,count:1,state:K},T.set(D,q)}}}function Ra(u,f){Ru.X(u,f);var g=Ou;if(g&&u){var b=po(g).hoistableScripts,T=Wf(u),D=b.get(T);D||(D=g.querySelector(tl(T)),D||(u=y({src:u,async:!0},f),(f=Si.get(T))&&Cy(u,f),D=g.createElement("script"),qn(D),Fe(D,"link",u),g.head.appendChild(D)),D={type:"script",instance:D,count:1,state:null},b.set(T,D))}}function Bc(u,f){Ru.M(u,f);var g=Ou;if(g&&u){var b=po(g).hoistableScripts,T=Wf(u),D=b.get(T);D||(D=g.querySelector(tl(T)),D||(u=y({src:u,async:!0,type:"module"},f),(f=Si.get(T))&&Cy(u,f),D=g.createElement("script"),qn(D),Fe(D,"link",u),g.head.appendChild(D)),D={type:"script",instance:D,count:1,state:null},b.set(T,D))}}function _y(u,f,g,b){var T=(T=Te.current)?oo(T):null;if(!T)throw Error(r(446));switch(u){case"meta":case"title":return null;case"style":return typeof g.precedence=="string"&&typeof g.href=="string"?(f=qh(g.href),g=po(T).hoistableStyles,b=g.get(f),b||(b={type:"style",instance:null,count:0,state:null},g.set(f,b)),b):{type:"void",instance:null,count:0,state:null};case"link":if(g.rel==="stylesheet"&&typeof g.href=="string"&&typeof g.precedence=="string"){u=qh(g.href);var D=po(T).hoistableStyles,q=D.get(u);if(q||(T=T.ownerDocument||T,q={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},D.set(u,q),(D=T.querySelector(X0(u)))&&!D._p&&(q.instance=D,q.state.loading=5),Si.has(u)||(g={rel:"preload",as:"style",href:g.href,crossOrigin:g.crossOrigin,integrity:g.integrity,media:g.media,hrefLang:g.hrefLang,referrerPolicy:g.referrerPolicy},Si.set(u,g),D||J0(T,u,g,q.state))),f&&b===null)throw Error(r(528,""));return q}if(f&&b!==null)throw Error(r(529,""));return null;case"script":return f=g.async,g=g.src,typeof g=="string"&&f&&typeof f!="function"&&typeof f!="symbol"?(f=Wf(g),g=po(T).hoistableScripts,b=g.get(f),b||(b={type:"script",instance:null,count:0,state:null},g.set(f,b)),b):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,u))}}function qh(u){return'href="'+ai(u)+'"'}function X0(u){return'link[rel="stylesheet"]['+u+"]"}function z_(u){return y({},u,{"data-precedence":u.precedence,precedence:null})}function J0(u,f,g,b){u.querySelector('link[rel="preload"][as="style"]['+f+"]")?b.loading=1:(f=u.createElement("link"),b.preload=f,f.addEventListener("load",function(){return b.loading|=1}),f.addEventListener("error",function(){return b.loading|=2}),Fe(f,"link",g),qn(f),u.head.appendChild(f))}function Wf(u){return'[src="'+ai(u)+'"]'}function tl(u){return"script[async]"+u}function Sy(u,f,g){if(f.count++,f.instance===null)switch(f.type){case"style":var b=u.querySelector('style[data-href~="'+ai(g.href)+'"]');if(b)return f.instance=b,qn(b),b;var T=y({},g,{"data-href":g.href,"data-precedence":g.precedence,href:null,precedence:null});return b=(u.ownerDocument||u).createElement("style"),qn(b),Fe(b,"style",T),wy(b,g.precedence,u),f.instance=b;case"stylesheet":T=qh(g.href);var D=u.querySelector(X0(T));if(D)return f.state.loading|=4,f.instance=D,qn(D),D;b=z_(g),(T=Si.get(T))&&F_(b,T),D=(u.ownerDocument||u).createElement("link"),qn(D);var q=D;return q._p=new Promise(function(K,ge){q.onload=K,q.onerror=ge}),Fe(D,"link",b),f.state.loading|=4,wy(D,g.precedence,u),f.instance=D;case"script":return D=Wf(g.src),(T=u.querySelector(tl(D)))?(f.instance=T,qn(T),T):(b=g,(T=Si.get(D))&&(b=y({},g),Cy(b,T)),u=u.ownerDocument||u,T=u.createElement("script"),qn(T),Fe(T,"link",b),u.head.appendChild(T),f.instance=T);case"void":return null;default:throw Error(r(443,f.type))}else f.type==="stylesheet"&&(f.state.loading&4)===0&&(b=f.instance,f.state.loading|=4,wy(b,g.precedence,u));return f.instance}function wy(u,f,g){for(var b=g.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),T=b.length?b[b.length-1]:null,D=T,q=0;q<b.length;q++){var K=b[q];if(K.dataset.precedence===f)D=K;else if(D!==T)break}D?D.parentNode.insertBefore(u,D.nextSibling):(f=g.nodeType===9?g.head:g,f.insertBefore(u,f.firstChild))}function F_(u,f){u.crossOrigin==null&&(u.crossOrigin=f.crossOrigin),u.referrerPolicy==null&&(u.referrerPolicy=f.referrerPolicy),u.title==null&&(u.title=f.title)}function Cy(u,f){u.crossOrigin==null&&(u.crossOrigin=f.crossOrigin),u.referrerPolicy==null&&(u.referrerPolicy=f.referrerPolicy),u.integrity==null&&(u.integrity=f.integrity)}var eg=null;function Gh(u,f,g){if(eg===null){var b=new Map,T=eg=new Map;T.set(g,b)}else T=eg,b=T.get(g),b||(b=new Map,T.set(g,b));if(b.has(u))return b;for(b.set(u,null),g=g.getElementsByTagName(u),T=0;T<g.length;T++){var D=g[T];if(!(D[Ho]||D[nn]||u==="link"&&D.getAttribute("rel")==="stylesheet")&&D.namespaceURI!=="http://www.w3.org/2000/svg"){var q=D.getAttribute(f)||"";q=u+q;var K=b.get(q);K?K.push(D):b.set(q,[D])}}return b}function U_(u,f,g){u=u.ownerDocument||u,u.head.insertBefore(g,f==="title"?u.querySelector("head > title"):null)}function C4(u,f,g){if(g===1||f.itemProp!=null)return!1;switch(u){case"meta":case"title":return!0;case"style":if(typeof f.precedence!="string"||typeof f.href!="string"||f.href==="")break;return!0;case"link":if(typeof f.rel!="string"||typeof f.href!="string"||f.href===""||f.onLoad||f.onError)break;switch(f.rel){case"stylesheet":return u=f.disabled,typeof f.precedence=="string"&&u==null;default:return!0}case"script":if(f.async&&typeof f.async!="function"&&typeof f.async!="symbol"&&!f.onLoad&&!f.onError&&f.src&&typeof f.src=="string")return!0}return!1}function j_(u){return!(u.type==="stylesheet"&&(u.state.loading&3)===0)}var Vh=null;function E4(){}function A4(u,f,g){if(Vh===null)throw Error(r(475));var b=Vh;if(f.type==="stylesheet"&&(typeof g.media!="string"||matchMedia(g.media).matches!==!1)&&(f.state.loading&4)===0){if(f.instance===null){var T=qh(g.href),D=u.querySelector(X0(T));if(D){u=D._p,u!==null&&typeof u=="object"&&typeof u.then=="function"&&(b.count++,b=Yh.bind(b),u.then(b,b)),f.state.loading|=4,f.instance=D,qn(D);return}D=u.ownerDocument||u,g=z_(g),(T=Si.get(T))&&F_(g,T),D=D.createElement("link"),qn(D);var q=D;q._p=new Promise(function(K,ge){q.onload=K,q.onerror=ge}),Fe(D,"link",g),f.instance=D}b.stylesheets===null&&(b.stylesheets=new Map),b.stylesheets.set(f,u),(u=f.state.preload)&&(f.state.loading&3)===0&&(b.count++,f=Yh.bind(b),u.addEventListener("load",f),u.addEventListener("error",f))}}function k4(){if(Vh===null)throw Error(r(475));var u=Vh;return u.stylesheets&&u.count===0&&ng(u,u.stylesheets),0<u.count?function(f){var g=setTimeout(function(){if(u.stylesheets&&ng(u,u.stylesheets),u.unsuspend){var b=u.unsuspend;u.unsuspend=null,b()}},6e4);return u.unsuspend=f,function(){u.unsuspend=null,clearTimeout(g)}}:null}function Yh(){if(this.count--,this.count===0){if(this.stylesheets)ng(this,this.stylesheets);else if(this.unsuspend){var u=this.unsuspend;this.unsuspend=null,u()}}}var tg=null;function ng(u,f){u.stylesheets=null,u.unsuspend!==null&&(u.count++,tg=new Map,f.forEach(P_,u),tg=null,Yh.call(u))}function P_(u,f){if(!(f.state.loading&4)){var g=tg.get(u);if(g)var b=g.get(null);else{g=new Map,tg.set(u,g);for(var T=u.querySelectorAll("link[data-precedence],style[data-precedence]"),D=0;D<T.length;D++){var q=T[D];(q.nodeName==="LINK"||q.getAttribute("media")!=="not all")&&(g.set(q.dataset.precedence,q),b=q)}b&&g.set(null,b)}T=f.instance,q=T.getAttribute("data-precedence"),D=g.get(q)||b,D===b&&g.set(null,T),g.set(q,T),this.count++,b=Yh.bind(this),T.addEventListener("load",b),T.addEventListener("error",b),D?D.parentNode.insertBefore(T,D.nextSibling):(u=u.nodeType===9?u.head:u,u.insertBefore(T,u.firstChild)),f.state.loading|=4}}var _o={$$typeof:O,Provider:null,Consumer:null,_currentValue:pe,_currentValue2:pe,_threadCount:0};function Ol(u,f,g,b,T,D,q,K){this.tag=1,this.containerInfo=u,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=st(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=st(0),this.hiddenUpdates=st(null),this.identifierPrefix=b,this.onUncaughtError=T,this.onCaughtError=D,this.onRecoverableError=q,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=K,this.incompleteTransitions=new Map}function T4(u,f,g,b,T,D,q,K,ge,Be,Ke,tt){return u=new Ol(u,f,g,q,K,ge,Be,tt),f=1,D===!0&&(f|=24),D=pa(3,null,null,f),u.current=D,D.stateNode=u,f=bb(),f.refCount++,u.pooledCache=f,f.refCount++,D.memoizedState={element:b,isDehydrated:g,cache:f},v0(D),u}function H_(u){return u?(u=Of,u):Of}function q_(u,f,g,b,T,D){T=H_(T),b.context===null?b.context=T:b.pendingContext=T,b=pu(f),b.payload={element:g},D=D===void 0?null:D,D!==null&&(b.callback=D),g=va(u,b,f),g!==null&&(ka(g,u,f),If(g,u,f))}function G_(u,f){if(u=u.memoizedState,u!==null&&u.dehydrated!==null){var g=u.retryLane;u.retryLane=g!==0&&g<f?g:f}}function Ey(u,f){G_(u,f),(u=u.alternate)&&G_(u,f)}function V_(u){if(u.tag===13){var f=lu(u,67108864);f!==null&&ka(f,u,67108864),Ey(u,67108864)}}var rg=!0;function R4(u,f,g,b){var T=ue.T;ue.T=null;var D=se.p;try{se.p=2,Ay(u,f,g,b)}finally{se.p=D,ue.T=T}}function O4(u,f,g,b){var T=ue.T;ue.T=null;var D=se.p;try{se.p=8,Ay(u,f,g,b)}finally{se.p=D,ue.T=T}}function Ay(u,f,g,b){if(rg){var T=Y_(b);if(T===null)Z0(u,f,b,ig,g),Q_(u,b);else if(K_(T,u,f,g,b))b.stopPropagation();else if(Q_(u,b),f&4&&-1<wM.indexOf(u)){for(;T!==null;){var D=rr(T);if(D!==null)switch(D.tag){case 3:if(D=D.stateNode,D.current.memoizedState.isDehydrated){var q=pt(D.pendingLanes);if(q!==0){var K=D;for(K.pendingLanes|=2,K.entangledLanes|=2;q;){var ge=1<<31-ct(q);K.entanglements[1]|=ge,q&=~ge}Js(D),(vr&6)===0&&(Xv=yt()+500,Au(0))}}break;case 13:K=lu(D,2),K!==null&&ka(K,D,2),j0(),Ey(D,2)}if(D=Y_(b),D===null&&Z0(u,f,b,ig,g),D===T)break;T=D}T!==null&&b.stopPropagation()}else Z0(u,f,b,null,g)}}function Y_(u){return u=vf(u),Z_(u)}var ig=null;function Z_(u){if(ig=null,u=to(u),u!==null){var f=a(u);if(f===null)u=null;else{var g=f.tag;if(g===13){if(u=l(f),u!==null)return u;u=null}else if(g===3){if(f.stateNode.current.memoizedState.isDehydrated)return f.tag===3?f.stateNode.containerInfo:null;u=null}else f!==u&&(u=null)}}return ig=u,null}function D4(u){switch(u){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(re()){case le:return 2;case ve:return 8;case Ee:case $e:return 32;case Ve:return 268435456;default:return 32}default:return 32}}var ky=!1,nl=null,Dl=null,Mu=null,Zh=new Map,og=new Map,Lc=[],wM="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Q_(u,f){switch(u){case"focusin":case"focusout":nl=null;break;case"dragenter":case"dragleave":Dl=null;break;case"mouseover":case"mouseout":Mu=null;break;case"pointerover":case"pointerout":Zh.delete(f.pointerId);break;case"gotpointercapture":case"lostpointercapture":og.delete(f.pointerId)}}function Ml(u,f,g,b,T,D){return u===null||u.nativeEvent!==D?(u={blockedOn:f,domEventName:g,eventSystemFlags:b,nativeEvent:D,targetContainers:[T]},f!==null&&(f=rr(f),f!==null&&V_(f)),u):(u.eventSystemFlags|=b,f=u.targetContainers,T!==null&&f.indexOf(T)===-1&&f.push(T),u)}function K_(u,f,g,b,T){switch(f){case"focusin":return nl=Ml(nl,u,f,g,b,T),!0;case"dragenter":return Dl=Ml(Dl,u,f,g,b,T),!0;case"mouseover":return Mu=Ml(Mu,u,f,g,b,T),!0;case"pointerover":var D=T.pointerId;return Zh.set(D,Ml(Zh.get(D)||null,u,f,g,b,T)),!0;case"gotpointercapture":return D=T.pointerId,og.set(D,Ml(og.get(D)||null,u,f,g,b,T)),!0}return!1}function W_(u){var f=to(u.target);if(f!==null){var g=a(f);if(g!==null){if(f=g.tag,f===13){if(f=l(g),f!==null){u.blockedOn=f,xr(u.priority,function(){if(g.tag===13){var b=Ga();b=qt(b);var T=lu(g,b);T!==null&&ka(T,g,b),Ey(g,b)}});return}}else if(f===3&&g.stateNode.current.memoizedState.isDehydrated){u.blockedOn=g.tag===3?g.stateNode.containerInfo:null;return}}}u.blockedOn=null}function ag(u){if(u.blockedOn!==null)return!1;for(var f=u.targetContainers;0<f.length;){var g=Y_(u.nativeEvent);if(g===null){g=u.nativeEvent;var b=new g.constructor(g.type,g);Km=b,g.target.dispatchEvent(b),Km=null}else return f=rr(g),f!==null&&V_(f),u.blockedOn=g,!1;f.shift()}return!0}function X_(u,f,g){ag(u)&&g.delete(f)}function Ty(){ky=!1,nl!==null&&ag(nl)&&(nl=null),Dl!==null&&ag(Dl)&&(Dl=null),Mu!==null&&ag(Mu)&&(Mu=null),Zh.forEach(X_),og.forEach(X_)}function Iu(u,f){u.blockedOn===f&&(u.blockedOn=null,ky||(ky=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,Ty)))}var Ry=null;function sg(u){Ry!==u&&(Ry=u,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){Ry===u&&(Ry=null);for(var f=0;f<u.length;f+=3){var g=u[f],b=u[f+1],T=u[f+2];if(typeof b!="function"){if(Z_(b||g)===null)continue;break}var D=rr(g);D!==null&&(u.splice(f,3),f-=3,Hb(D,{pending:!0,data:T,method:g.method,action:b},b,T))}}))}function Qh(u){function f(ge){return Iu(ge,u)}nl!==null&&Iu(nl,u),Dl!==null&&Iu(Dl,u),Mu!==null&&Iu(Mu,u),Zh.forEach(f),og.forEach(f);for(var g=0;g<Lc.length;g++){var b=Lc[g];b.blockedOn===u&&(b.blockedOn=null)}for(;0<Lc.length&&(g=Lc[0],g.blockedOn===null);)W_(g),g.blockedOn===null&&Lc.shift();if(g=(u.ownerDocument||u).$$reactFormReplay,g!=null)for(b=0;b<g.length;b+=3){var T=g[b],D=g[b+1],q=T[yn]||null;if(typeof D=="function")q||sg(g);else if(q){var K=null;if(D&&D.hasAttribute("formAction")){if(T=D,q=D[yn]||null)K=q.formAction;else if(Z_(T)!==null)continue}else K=q.action;typeof K=="function"?g[b+1]=K:(g.splice(b,3),b-=3),sg(g)}}}function Nc(u){this._internalRoot=u}Oy.prototype.render=Nc.prototype.render=function(u){var f=this._internalRoot;if(f===null)throw Error(r(409));var g=f.current,b=Ga();q_(g,b,u,f,null,null)},Oy.prototype.unmount=Nc.prototype.unmount=function(){var u=this._internalRoot;if(u!==null){this._internalRoot=null;var f=u.containerInfo;q_(u.current,2,null,u,null,null),j0(),f[fn]=null}};function Oy(u){this._internalRoot=u}Oy.prototype.unstable_scheduleHydration=function(u){if(u){var f=hr();u={blockedOn:null,target:u,priority:f};for(var g=0;g<Lc.length&&f!==0&&f<Lc[g].priority;g++);Lc.splice(g,0,u),g===0&&W_(u)}};var M4=t.version;if(M4!=="19.1.0")throw Error(r(527,M4,"19.1.0"));se.findDOMNode=function(u){var f=u._reactInternals;if(f===void 0)throw typeof u.render=="function"?Error(r(188)):(u=Object.keys(u).join(","),Error(r(268,u)));return u=h(f),u=u!==null?p(u):null,u=u===null?null:u.stateNode,u};var I4={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:ue,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ao=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ao.isDisabled&&ao.supportsFiber)try{_e=ao.inject(I4),Re=ao}catch{}}return s1.createRoot=function(u,f){if(!o(u))throw Error(r(299));var g=!1,b="",T=Wb,D=Ah,q=Xb,K=null;return f!=null&&(f.unstable_strictMode===!0&&(g=!0),f.identifierPrefix!==void 0&&(b=f.identifierPrefix),f.onUncaughtError!==void 0&&(T=f.onUncaughtError),f.onCaughtError!==void 0&&(D=f.onCaughtError),f.onRecoverableError!==void 0&&(q=f.onRecoverableError),f.unstable_transitionCallbacks!==void 0&&(K=f.unstable_transitionCallbacks)),f=T4(u,1,!1,null,null,g,b,T,D,q,K,null),u[fn]=f.current,Y0(u),new Nc(f)},s1.hydrateRoot=function(u,f,g){if(!o(u))throw Error(r(299));var b=!1,T="",D=Wb,q=Ah,K=Xb,ge=null,Be=null;return g!=null&&(g.unstable_strictMode===!0&&(b=!0),g.identifierPrefix!==void 0&&(T=g.identifierPrefix),g.onUncaughtError!==void 0&&(D=g.onUncaughtError),g.onCaughtError!==void 0&&(q=g.onCaughtError),g.onRecoverableError!==void 0&&(K=g.onRecoverableError),g.unstable_transitionCallbacks!==void 0&&(ge=g.unstable_transitionCallbacks),g.formState!==void 0&&(Be=g.formState)),f=T4(u,1,!0,f,g??null,b,T,D,q,K,ge,Be),f.context=H_(null),g=f.current,b=Ga(),b=qt(b),T=pu(b),T.callback=null,va(g,T,b),g=b,f.current.lanes=g,St(f,g),Js(f),u[fn]=f.current,Y0(u),new Oy(f)},s1.version="19.1.0",s1}var l1={},$5;function EV(){if($5)return l1;$5=1;var e={};/**
82
82
  * @license React
83
83
  * react-dom-client.development.js
84
84
  *
@@ -102,7 +102,7 @@ Error generating stack: `+X.message+`
102
102
  Error generating stack: `+$.message+`
103
103
  `+$.stack}return C}function Dt(i,s,c,v,S,C,$){var F=_o;to(i);try{return i!==null&&i._debugTask?i._debugTask.run(s.bind(null,c,v,S,C,$)):s(c,v,S,C,$)}finally{to(F)}throw Error("runWithFiberInDEV should never be called in production. This is a bug in React.")}function to(i){Fe.getCurrentStack=i===null?null:Ho,Ol=!1,_o=i}function rr(i){switch(typeof i){case"bigint":case"boolean":case"number":case"string":case"undefined":return i;case"object":return Ae(i),i;default:return""}}function Ro(i){var s=i.type;return(i=i.nodeName)&&i.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function po(i){var s=Ro(i)?"checked":"value",c=Object.getOwnPropertyDescriptor(i.constructor.prototype,s);Ae(i[s]);var v=""+i[s];if(!i.hasOwnProperty(s)&&typeof c<"u"&&typeof c.get=="function"&&typeof c.set=="function"){var S=c.get,C=c.set;return Object.defineProperty(i,s,{configurable:!0,get:function(){return S.call(this)},set:function($){Ae($),v=""+$,C.call(this,$)}}),Object.defineProperty(i,s,{enumerable:c.enumerable}),{getValue:function(){return v},setValue:function($){Ae($),v=""+$},stopTracking:function(){i._valueTracker=null,delete i[s]}}}}function qn(i){i._valueTracker||(i._valueTracker=po(i))}function ua(i){if(!i)return!1;var s=i._valueTracker;if(!s)return!0;var c=s.getValue(),v="";return i&&(v=Ro(i)?i.checked?"true":"false":i.value),i=v,i!==c?(s.setValue(i),!0):!1}function Oi(i){if(i=i||(typeof document<"u"?document:void 0),typeof i>"u")return null;try{return i.activeElement||i.body}catch{return i.body}}function pr(i){return i.replace(T4,function(s){return"\\"+s.charCodeAt(0).toString(16)+" "})}function Br(i,s){s.checked===void 0||s.defaultChecked===void 0||q_||(console.error("%s contains an input of type %s with both checked and defaultChecked props. Input elements must be either controlled or uncontrolled (specify either the checked prop, or the defaultChecked prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://react.dev/link/controlled-components",ji()||"A component",s.type),q_=!0),s.value===void 0||s.defaultValue===void 0||H_||(console.error("%s contains an input of type %s with both value and defaultValue props. Input elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://react.dev/link/controlled-components",ji()||"A component",s.type),H_=!0)}function ca(i,s,c,v,S,C,$,F){i.name="",$!=null&&typeof $!="function"&&typeof $!="symbol"&&typeof $!="boolean"?(U($,"type"),i.type=$):i.removeAttribute("type"),s!=null?$==="number"?(s===0&&i.value===""||i.value!=s)&&(i.value=""+rr(s)):i.value!==""+rr(s)&&(i.value=""+rr(s)):$!=="submit"&&$!=="reset"||i.removeAttribute("value"),s!=null?ot(i,$,rr(s)):c!=null?ot(i,$,rr(c)):v!=null&&i.removeAttribute("value"),S==null&&C!=null&&(i.defaultChecked=!!C),S!=null&&(i.checked=S&&typeof S!="function"&&typeof S!="symbol"),F!=null&&typeof F!="function"&&typeof F!="symbol"&&typeof F!="boolean"?(U(F,"name"),i.name=""+rr(F)):i.removeAttribute("name")}function Kr(i,s,c,v,S,C,$,F){if(C!=null&&typeof C!="function"&&typeof C!="symbol"&&typeof C!="boolean"&&(U(C,"type"),i.type=C),s!=null||c!=null){if(!(C!=="submit"&&C!=="reset"||s!=null))return;c=c!=null?""+rr(c):"",s=s!=null?""+rr(s):c,F||s===i.value||(i.value=s),i.defaultValue=s}v=v??S,v=typeof v!="function"&&typeof v!="symbol"&&!!v,i.checked=F?i.checked:!!v,i.defaultChecked=!!v,$!=null&&typeof $!="function"&&typeof $!="symbol"&&typeof $!="boolean"&&(U($,"name"),i.name=$)}function ot(i,s,c){s==="number"&&Oi(i.ownerDocument)===i||i.defaultValue===""+c||(i.defaultValue=""+c)}function Oe(i,s){s.value==null&&(typeof s.children=="object"&&s.children!==null?D_.Children.forEach(s.children,function(c){c==null||typeof c=="string"||typeof c=="number"||typeof c=="bigint"||Ey||(Ey=!0,console.error("Cannot infer the option value of complex children. Pass a `value` prop or use a plain string as children to <option>."))}):s.dangerouslySetInnerHTML==null||V_||(V_=!0,console.error("Pass a `value` prop if you set dangerouslyInnerHTML so React knows which value should be selected."))),s.selected==null||G_||(console.error("Use the `defaultValue` or `value` props on <select> instead of setting `selected` on <option>."),G_=!0)}function at(){var i=ji();return i?`
104
104
 
105
- Check the render method of \``+i+"`.":""}function ce(i,s,c,v){if(i=i.options,s){s={};for(var S=0;S<c.length;S++)s["$"+c[S]]=!0;for(c=0;c<i.length;c++)S=s.hasOwnProperty("$"+i[c].value),i[c].selected!==S&&(i[c].selected=S),S&&v&&(i[c].defaultSelected=!0)}else{for(c=""+rr(c),s=null,S=0;S<i.length;S++){if(i[S].value===c){i[S].selected=!0,v&&(i[S].defaultSelected=!0);return}s!==null||i[S].disabled||(s=i[S])}s!==null&&(s.selected=!0)}}function Me(i,s){for(i=0;i<R4.length;i++){var c=R4[i];if(s[c]!=null){var v=Gi(s[c]);s.multiple&&!v?console.error("The `%s` prop supplied to <select> must be an array if `multiple` is true.%s",c,at()):!s.multiple&&v&&console.error("The `%s` prop supplied to <select> must be a scalar value if `multiple` is false.%s",c,at())}}s.value===void 0||s.defaultValue===void 0||rg||(console.error("Select elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled select element and remove one of these props. More info: https://react.dev/link/controlled-components"),rg=!0)}function j(i,s){s.value===void 0||s.defaultValue===void 0||O4||(console.error("%s contains a textarea with both value and defaultValue props. Textarea elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled textarea and remove one of these props. More info: https://react.dev/link/controlled-components",ji()||"A component"),O4=!0),s.children!=null&&s.value==null&&console.error("Use the `defaultValue` or `value` props instead of setting children on <textarea>.")}function te(i,s,c){if(s!=null&&(s=""+rr(s),s!==i.value&&(i.value=s),c==null)){i.defaultValue!==s&&(i.defaultValue=s);return}i.defaultValue=c!=null?""+rr(c):""}function he(i,s,c,v){if(s==null){if(v!=null){if(c!=null)throw Error("If you supply `defaultValue` on a <textarea>, do not pass children.");if(Gi(v)){if(1<v.length)throw Error("<textarea> can only have at most one child.");v=v[0]}c=v}c==null&&(c=""),s=c}c=rr(s),i.defaultValue=c,v=i.textContent,v===c&&v!==""&&v!==null&&(i.value=v)}function ke(i,s){return i.serverProps===void 0&&i.serverTail.length===0&&i.children.length===1&&3<i.distanceFromLeaf&&i.distanceFromLeaf>15-s?ke(i.children[0],s):i}function we(i){return" "+" ".repeat(i)}function Je(i){return"+ "+" ".repeat(i)}function $t(i){return"- "+" ".repeat(i)}function an(i){switch(i.tag){case 26:case 27:case 5:return i.type;case 16:return"Lazy";case 13:return"Suspense";case 19:return"SuspenseList";case 0:case 15:return i=i.type,i.displayName||i.name||null;case 11:return i=i.type.render,i.displayName||i.name||null;case 1:return i=i.type,i.displayName||i.name||null;default:return null}}function un(i,s){return Ay.test(i)?(i=JSON.stringify(i),i.length>s-2?8>s?'{"..."}':"{"+i.slice(0,s-7)+'..."}':"{"+i+"}"):i.length>s?5>s?'{"..."}':i.slice(0,s-3)+"...":i}function Un(i,s,c){var v=120-2*c;if(s===null)return Je(c)+un(i,v)+`
105
+ Check the render method of \``+i+"`.":""}function ce(i,s,c,v){if(i=i.options,s){s={};for(var S=0;S<c.length;S++)s["$"+c[S]]=!0;for(c=0;c<i.length;c++)S=s.hasOwnProperty("$"+i[c].value),i[c].selected!==S&&(i[c].selected=S),S&&v&&(i[c].defaultSelected=!0)}else{for(c=""+rr(c),s=null,S=0;S<i.length;S++){if(i[S].value===c){i[S].selected=!0,v&&(i[S].defaultSelected=!0);return}s!==null||i[S].disabled||(s=i[S])}s!==null&&(s.selected=!0)}}function Ie(i,s){for(i=0;i<R4.length;i++){var c=R4[i];if(s[c]!=null){var v=Gi(s[c]);s.multiple&&!v?console.error("The `%s` prop supplied to <select> must be an array if `multiple` is true.%s",c,at()):!s.multiple&&v&&console.error("The `%s` prop supplied to <select> must be a scalar value if `multiple` is false.%s",c,at())}}s.value===void 0||s.defaultValue===void 0||rg||(console.error("Select elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled select element and remove one of these props. More info: https://react.dev/link/controlled-components"),rg=!0)}function j(i,s){s.value===void 0||s.defaultValue===void 0||O4||(console.error("%s contains a textarea with both value and defaultValue props. Textarea elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled textarea and remove one of these props. More info: https://react.dev/link/controlled-components",ji()||"A component"),O4=!0),s.children!=null&&s.value==null&&console.error("Use the `defaultValue` or `value` props instead of setting children on <textarea>.")}function te(i,s,c){if(s!=null&&(s=""+rr(s),s!==i.value&&(i.value=s),c==null)){i.defaultValue!==s&&(i.defaultValue=s);return}i.defaultValue=c!=null?""+rr(c):""}function he(i,s,c,v){if(s==null){if(v!=null){if(c!=null)throw Error("If you supply `defaultValue` on a <textarea>, do not pass children.");if(Gi(v)){if(1<v.length)throw Error("<textarea> can only have at most one child.");v=v[0]}c=v}c==null&&(c=""),s=c}c=rr(s),i.defaultValue=c,v=i.textContent,v===c&&v!==""&&v!==null&&(i.value=v)}function ke(i,s){return i.serverProps===void 0&&i.serverTail.length===0&&i.children.length===1&&3<i.distanceFromLeaf&&i.distanceFromLeaf>15-s?ke(i.children[0],s):i}function we(i){return" "+" ".repeat(i)}function Je(i){return"+ "+" ".repeat(i)}function $t(i){return"- "+" ".repeat(i)}function an(i){switch(i.tag){case 26:case 27:case 5:return i.type;case 16:return"Lazy";case 13:return"Suspense";case 19:return"SuspenseList";case 0:case 15:return i=i.type,i.displayName||i.name||null;case 11:return i=i.type.render,i.displayName||i.name||null;case 1:return i=i.type,i.displayName||i.name||null;default:return null}}function un(i,s){return Ay.test(i)?(i=JSON.stringify(i),i.length>s-2?8>s?'{"..."}':"{"+i.slice(0,s-7)+'..."}':"{"+i+"}"):i.length>s?5>s?'{"..."}':i.slice(0,s-3)+"...":i}function Un(i,s,c){var v=120-2*c;if(s===null)return Je(c)+un(i,v)+`
106
106
  `;if(typeof s=="string"){for(var S=0;S<s.length&&S<i.length&&s.charCodeAt(S)===i.charCodeAt(S);S++);return S>v-8&&10<S&&(i="..."+i.slice(S-8),s="..."+s.slice(S-8)),Je(c)+un(i,v)+`
107
107
  `+$t(c)+un(s,v)+`
108
108
  `}return we(c)+un(i,v)+`
@@ -150,7 +150,7 @@ Check the render method of \``+$+"`."),$=29,c=Error("Element type is invalid: ex
150
150
 
151
151
  It can also happen if the client has a browser extension installed which messes with the HTML before React loaded.
152
152
 
153
- https://react.dev/link/hydration-mismatch`+s),i)),IM}function ub(i){var s=i.stateNode,c=i.type,v=i.memoizedProps;switch(s[$o]=i,s[Ra]=v,_u(c,v),c){case"dialog":Ln("cancel",s),Ln("close",s);break;case"iframe":case"object":case"embed":Ln("load",s);break;case"video":case"audio":for(c=0;c<AS.length;c++)Ln(AS[c],s);break;case"source":Ln("error",s);break;case"img":case"image":case"link":Ln("error",s),Ln("load",s);break;case"details":Ln("toggle",s);break;case"input":St("input",v),Ln("invalid",s),Br(s,v),Kr(s,v.value,v.defaultValue,v.checked,v.defaultChecked,v.type,v.name,!0),qn(s);break;case"option":Oe(s,v);break;case"select":St("select",v),Ln("invalid",s),Me(s,v);break;case"textarea":St("textarea",v),Ln("invalid",s),j(s,v),he(s,v.value,v.defaultValue,v.children),qn(s)}c=v.children,typeof c!="string"&&typeof c!="number"&&typeof c!="bigint"||s.textContent===""+c||v.suppressHydrationWarning===!0||Gf(s.textContent,c)?(v.popover!=null&&(Ln("beforetoggle",s),Ln("toggle",s)),v.onScroll!=null&&Ln("scroll",s),v.onScrollEnd!=null&&Ln("scrollend",s),v.onClick!=null&&(s.onclick=Sc),s=!0):s=!1,s||oc(i)}function uv(i){for(Qa=i.return;Qa;)switch(Qa.tag){case 5:case 13:zc=!1;return;case 27:case 3:zc=!0;return;default:Qa=Qa.return}}function kf(i){if(i!==Qa)return!1;if(!sr)return uv(i),sr=!0,!1;var s=i.tag,c;if((c=s!==3&&s!==27)&&((c=s===5)&&(c=i.type,c=!(c!=="form"&&c!=="button")||Cc(i.type,i.memoizedProps)),c=!c),c&&Bi){for(c=Bi;c;){var v=Af(i,0),S=ey(c);v.serverTail.push(S),c=S.type==="Suspense"?Bh(c):Aa(c.nextSibling)}oc(i)}if(uv(i),s===13){if(i=i.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error("Expected to have a hydrated suspense instance. This error is likely caused by a bug in React. Please file an issue.");Bi=Bh(i)}else s===27?(s=Bi,qi(i.type)?(i=b5,b5=null,Bi=i):Bi=s):Bi=Qa?Aa(i.stateNode.nextSibling):null;return!0}function Xd(){Bi=Qa=null,ed=sr=!1}function cb(){var i=cg;return i!==null&&(Xa===null?Xa=i:Xa.push.apply(Xa,i),cg=null),i}function Jd(i){cg===null?cg=[i]:cg.push(i)}function UT(){var i=zl;if(i!==null){zl=null;for(var s=rc(i);0<i.children.length;)i=i.children[0];Dt(i.fiber,function(){console.error(`A tree hydrated but some attributes of the server rendered HTML didn't match the client properties. This won't be patched up. This can happen if a SSR-ed Client Component used:
153
+ https://react.dev/link/hydration-mismatch`+s),i)),IM}function ub(i){var s=i.stateNode,c=i.type,v=i.memoizedProps;switch(s[$o]=i,s[Ra]=v,_u(c,v),c){case"dialog":Ln("cancel",s),Ln("close",s);break;case"iframe":case"object":case"embed":Ln("load",s);break;case"video":case"audio":for(c=0;c<AS.length;c++)Ln(AS[c],s);break;case"source":Ln("error",s);break;case"img":case"image":case"link":Ln("error",s),Ln("load",s);break;case"details":Ln("toggle",s);break;case"input":St("input",v),Ln("invalid",s),Br(s,v),Kr(s,v.value,v.defaultValue,v.checked,v.defaultChecked,v.type,v.name,!0),qn(s);break;case"option":Oe(s,v);break;case"select":St("select",v),Ln("invalid",s),Ie(s,v);break;case"textarea":St("textarea",v),Ln("invalid",s),j(s,v),he(s,v.value,v.defaultValue,v.children),qn(s)}c=v.children,typeof c!="string"&&typeof c!="number"&&typeof c!="bigint"||s.textContent===""+c||v.suppressHydrationWarning===!0||Gf(s.textContent,c)?(v.popover!=null&&(Ln("beforetoggle",s),Ln("toggle",s)),v.onScroll!=null&&Ln("scroll",s),v.onScrollEnd!=null&&Ln("scrollend",s),v.onClick!=null&&(s.onclick=Sc),s=!0):s=!1,s||oc(i)}function uv(i){for(Qa=i.return;Qa;)switch(Qa.tag){case 5:case 13:zc=!1;return;case 27:case 3:zc=!0;return;default:Qa=Qa.return}}function kf(i){if(i!==Qa)return!1;if(!sr)return uv(i),sr=!0,!1;var s=i.tag,c;if((c=s!==3&&s!==27)&&((c=s===5)&&(c=i.type,c=!(c!=="form"&&c!=="button")||Cc(i.type,i.memoizedProps)),c=!c),c&&Bi){for(c=Bi;c;){var v=Af(i,0),S=ey(c);v.serverTail.push(S),c=S.type==="Suspense"?Bh(c):Aa(c.nextSibling)}oc(i)}if(uv(i),s===13){if(i=i.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error("Expected to have a hydrated suspense instance. This error is likely caused by a bug in React. Please file an issue.");Bi=Bh(i)}else s===27?(s=Bi,qi(i.type)?(i=b5,b5=null,Bi=i):Bi=s):Bi=Qa?Aa(i.stateNode.nextSibling):null;return!0}function Xd(){Bi=Qa=null,ed=sr=!1}function cb(){var i=cg;return i!==null&&(Xa===null?Xa=i:Xa.push.apply(Xa,i),cg=null),i}function Jd(i){cg===null?cg=[i]:cg.push(i)}function UT(){var i=zl;if(i!==null){zl=null;for(var s=rc(i);0<i.children.length;)i=i.children[0];Dt(i.fiber,function(){console.error(`A tree hydrated but some attributes of the server rendered HTML didn't match the client properties. This won't be patched up. This can happen if a SSR-ed Client Component used:
154
154
 
155
155
  - A server/client branch \`if (typeof window !== 'undefined')\`.
156
156
  - Variable input such as \`Date.now()\` or \`Math.random()\` which changes each time it's called.
@@ -241,7 +241,7 @@ act(() => {
241
241
  /* assert on the output */
242
242
 
243
243
  This ensures that you're testing the behavior the user would see in the browser. Learn more at https://react.dev/link/wrap-tests-with-act`,z(i))})}function ys(i){i!==r1&&i.next===null&&(r1===null?J4=r1=i:r1=r1.next=i),e3=!0,Fe.actQueue!==null?f5||(f5=!0,a4()):c5||(c5=!0,a4())}function _c(i,s){if(!d5&&e3){d5=!0;do for(var c=!1,v=J4;v!==null;){if(i!==0){var S=v.pendingLanes;if(S===0)var C=0;else{var $=v.suspendedLanes,F=v.pingedLanes;C=(1<<31-oo(42|i)+1)-1,C&=S&~($&~F),C=C&201326741?C&201326741|1:C?C|2:0}C!==0&&(c=!0,h_(v,C))}else C=jn,C=re(v,v===Gr?C:0,v.cancelPendingCommit!==null||v.timeoutHandle!==Cg),(C&3)===0||le(v,C)||(c=!0,h_(v,C));v=v.next}while(c);d5=!1}}function o4(){Ks()}function Ks(){e3=f5=c5=!1;var i=0;Sg!==0&&(x_()&&(i=Sg),Sg=0);for(var s=xo(),c=null,v=J4;v!==null;){var S=v.next,C=mi(v,s);C===0?(v.next=null,c===null?J4=S:c.next=S,S===null&&(r1=c)):(c=v,(i!==0||(C&3)!==0)&&(e3=!0)),v=S}_c(i)}function mi(i,s){for(var c=i.suspendedLanes,v=i.pingedLanes,S=i.expirationTimes,C=i.pendingLanes&-62914561;0<C;){var $=31-oo(C),F=1<<$,X=S[$];X===-1?((F&c)===0||(F&v)!==0)&&(S[$]=ve(F,s)):X<=s&&(i.expiredLanes|=F),C&=~F}if(s=Gr,c=jn,c=re(i,i===s?c:0,i.cancelPendingCommit!==null||i.timeoutHandle!==Cg),v=i.callbackNode,c===0||i===s&&(Or===vg||Or===yg)||i.cancelPendingCommit!==null)return v!==null&&$i(v),i.callbackNode=null,i.callbackPriority=0;if((c&3)===0||le(i,c)){if(s=c&-c,s!==i.callbackPriority||Fe.actQueue!==null&&v!==h5)$i(v);else return s;switch(Mt(c)){case Ya:case Rl:c=$_;break;case Du:c=Hh;break;case by:c=L_;break;default:c=Hh}return v=Qv.bind(null,i),Fe.actQueue!==null?(Fe.actQueue.push(v),c=h5):c=I_(c,v),i.callbackPriority=s,i.callbackNode=c,s}return v!==null&&$i(v),i.callbackPriority=2,i.callbackNode=null,2}function Qv(i,s){if(F4=z4=!1,Ko!==bg&&Ko!==o5)return i.callbackNode=null,i.callbackPriority=0,null;var c=i.callbackNode;if(xc()&&i.callbackNode!==c)return null;var v=jn;return v=re(i,i===Gr?v:0,i.cancelPendingCommit!==null||i.timeoutHandle!==Cg),v===0?null:(ro(i,v,s),mi(i,xo()),i.callbackNode!=null&&i.callbackNode===c?Qv.bind(null,i):null)}function h_(i,s){if(xc())return null;z4=F4,F4=!1,ro(i,s,!0)}function $i(i){i!==h5&&i!==null&&S4(i)}function a4(){Fe.actQueue!==null&&Fe.actQueue.push(function(){return Ks(),null}),Rye(function(){(_r&(Wa|zu))!==rl?I_(W0,o4):Ks()})}function Kv(){return Sg===0&&(Sg=Ee()),Sg}function p_(i){return i==null||typeof i=="symbol"||typeof i=="boolean"?null:typeof i=="function"?i:(U(i,"action"),iu(""+i))}function Hr(i,s){var c=s.ownerDocument.createElement("input");return c.name=s.name,c.value=s.value,i.id&&c.setAttribute("form",i.id),s.parentNode.insertBefore(c,s),i=new FormData(i),c.parentNode.removeChild(c),i}function wa(i,s,c,v,S){if(s==="submit"&&c&&c.stateNode===S){var C=p_((S[Ra]||null).action),$=v.submitter;$&&(s=(s=$[Ra]||null)?p_(s.formAction):$.getAttribute("formAction"),s!==null&&(C=s,$=null));var F=new fr("action","action",null,v,S);i.push({event:F,listeners:[{instance:null,listener:function(){if(v.defaultPrevented){if(Sg!==0){var X=$?Hr(S,$):new FormData(S),oe={pending:!0,data:X,method:S.method,action:C};Object.freeze(oe),wv(c,oe,null,X)}}else typeof C=="function"&&(F.preventDefault(),X=$?Hr(S,$):new FormData(S),oe={pending:!0,data:X,method:S.method,action:C},Object.freeze(oe),wv(c,oe,C,X))},currentTarget:S}]})}}function xs(i,s,c){i.currentTarget=c;try{s(i)}catch(v){ZM(v)}i.currentTarget=null}function g_(i,s){s=(s&4)!==0;for(var c=0;c<i.length;c++){var v=i[c];e:{var S=void 0,C=v.event;if(v=v.listeners,s)for(var $=v.length-1;0<=$;$--){var F=v[$],X=F.instance,oe=F.currentTarget;if(F=F.listener,X!==S&&C.isPropagationStopped())break e;X!==null?Dt(X,xs,C,F,oe):xs(C,F,oe),S=X}else for($=0;$<v.length;$++){if(F=v[$],X=F.instance,oe=F.currentTarget,F=F.listener,X!==S&&C.isPropagationStopped())break e;X!==null?Dt(X,xs,C,F,oe):xs(C,F,oe),S=X}}}}function Ln(i,s){p5.has(i)||console.error('Did not expect a listenToNonDelegatedEvent() call for "%s". This is a bug in React. Please file an issue.',i);var c=s[_y];c===void 0&&(c=s[_y]=new Set);var v=i+"__bubble";c.has(v)||(Ca(s,i,2,!1),c.add(v))}function m_(i,s,c){p5.has(i)&&!s&&console.error('Did not expect a listenToNativeEvent() call for "%s" in the bubble phase. This is a bug in React. Please file an issue.',i);var v=0;s&&(v|=4),Ca(c,i,v,s)}function z0(i){if(!i[t3]){i[t3]=!0,Wf.forEach(function(c){c!=="selectionchange"&&(p5.has(c)||m_(c,!1,i),m_(c,!0,i))});var s=i.nodeType===9?i:i.ownerDocument;s===null||s[t3]||(s[t3]=!0,m_("selectionchange",!1,s))}}function Ca(i,s,c,v){switch(Oc(s)){case Ya:var S=uy;break;case Rl:S=Fh;break;default:S=q0}c=S.bind(null,s,c,i),S=void 0,!Ke||s!=="touchstart"&&s!=="touchmove"&&s!=="wheel"||(S=!0),v?S!==void 0?i.addEventListener(s,c,{capture:!0,passive:S}):i.addEventListener(s,c,!0):S!==void 0?i.addEventListener(s,c,{passive:S}):i.addEventListener(s,c,!1)}function Ha(i,s,c,v,S){var C=v;if((s&1)===0&&(s&2)===0&&v!==null)e:for(;;){if(v===null)return;var $=v.tag;if($===3||$===4){var F=v.stateNode.containerInfo;if(F===S)break;if($===4)for($=v.return;$!==null;){var X=$.tag;if((X===3||X===4)&&$.stateNode.containerInfo===S)return;$=$.return}for(;F!==null;){if($=pt(F),$===null)return;if(X=$.tag,X===5||X===6||X===26||X===27){v=C=$;continue e}F=F.parentNode}}v=v.return}Qd(function(){var oe=C,Ue=Ms(c),qe=[];e:{var ze=Mq.get(i);if(ze!==void 0){var Ze=fr,Gt=i;switch(i){case"keypress":if(xf(c)===0)break e;case"keydown":case"keyup":Ze=Lve;break;case"focusin":Gt="focus",Ze=Il;break;case"focusout":Gt="blur",Ze=Il;break;case"beforeblur":case"afterblur":Ze=Il;break;case"click":if(c.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":Ze=Wt;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":Ze=so;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":Ze=Fve;break;case Tq:case Rq:case Oq:Ze=kve;break;case Dq:Ze=jve;break;case"scroll":case"scrollend":Ze=Se;break;case"wheel":Ze=Hve;break;case"copy":case"cut":case"paste":Ze=Rve;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":Ze=bq;break;case"toggle":case"beforetoggle":Ze=Gve}var cn=(s&4)!==0,Vr=!cn&&(i==="scroll"||i==="scrollend"),Gn=cn?ze!==null?ze+"Capture":null:ze;cn=[];for(var me=oe,ye;me!==null;){var be=me;if(ye=be.stateNode,be=be.tag,be!==5&&be!==26&&be!==27||ye===null||Gn===null||(be=cs(me,Gn),be!=null&&cn.push(Dh(me,be,ye))),Vr)break;me=me.return}0<cn.length&&(ze=new Ze(ze,Gt,null,c,Ue),qe.push({event:ze,listeners:cn}))}}if((s&7)===0){e:{if(ze=i==="mouseover"||i==="pointerover",Ze=i==="mouseout"||i==="pointerout",ze&&c!==D&&(Gt=c.relatedTarget||c.fromElement)&&(pt(Gt)||Gt[Bc]))break e;if((Ze||ze)&&(ze=Ue.window===Ue?Ue:(ze=Ue.ownerDocument)?ze.defaultView||ze.parentWindow:window,Ze?(Gt=c.relatedTarget||c.toElement,Ze=oe,Gt=Gt?pt(Gt):null,Gt!==null&&(Vr=R(Gt),cn=Gt.tag,Gt!==Vr||cn!==5&&cn!==27&&cn!==6)&&(Gt=null)):(Ze=null,Gt=oe),Ze!==Gt)){if(cn=Wt,be="onMouseLeave",Gn="onMouseEnter",me="mouse",(i==="pointerout"||i==="pointerover")&&(cn=bq,be="onPointerLeave",Gn="onPointerEnter",me="pointer"),Vr=Ze==null?ze:_t(Ze),ye=Gt==null?ze:_t(Gt),ze=new cn(be,me+"leave",Ze,c,Ue),ze.target=Vr,ze.relatedTarget=ye,be=null,pt(Ue)===oe&&(cn=new cn(Gn,me+"enter",Gt,c,Ue),cn.target=ye,cn.relatedTarget=Vr,be=cn),Vr=be,Ze&&Gt)t:{for(cn=Ze,Gn=Gt,me=0,ye=cn;ye;ye=qf(ye))me++;for(ye=0,be=Gn;be;be=qf(be))ye++;for(;0<me-ye;)cn=qf(cn),me--;for(;0<ye-me;)Gn=qf(Gn),ye--;for(;me--;){if(cn===Gn||Gn!==null&&cn===Gn.alternate)break t;cn=qf(cn),Gn=qf(Gn)}cn=null}else cn=null;Ze!==null&&bu(qe,ze,Ze,cn,!1),Gt!==null&&Vr!==null&&bu(qe,Vr,Gt,cn,!0)}}e:{if(ze=oe?_t(oe):window,Ze=ze.nodeName&&ze.nodeName.toLowerCase(),Ze==="select"||Ze==="input"&&ze.type==="file")var Qe=MT;else if(Jm(ze))if(Aq)Qe=lM;else{Qe=aM;var Ot=eb}else Ze=ze.nodeName,!Ze||Ze.toLowerCase()!=="input"||ze.type!=="checkbox"&&ze.type!=="radio"?oe&&vf(oe.elementType)&&(Qe=MT):Qe=sM;if(Qe&&(Qe=Qe(i,oe))){Kd(qe,Qe,c,Ue);break e}Ot&&Ot(i,ze,oe),i==="focusout"&&oe&&ze.type==="number"&&oe.memoizedProps.value!=null&&ot(ze,"number",ze.value)}switch(Ot=oe?_t(oe):window,i){case"focusin":(Jm(Ot)||Ot.contentEditable==="true")&&(My=Ot,AM=oe,nS=null);break;case"focusout":nS=AM=My=null;break;case"mousedown":kM=!0;break;case"contextmenu":case"mouseup":case"dragend":kM=!1,tv(qe,c,Ue);break;case"selectionchange":if(Qve)break;case"keydown":case"keyup":tv(qe,c,Ue)}var bn;if(EM)e:{switch(i){case"compositionstart":var Vt="onCompositionStart";break e;case"compositionend":Vt="onCompositionEnd";break e;case"compositionupdate":Vt="onCompositionUpdate";break e}Vt=void 0}else Dy?ic(i,c)&&(Vt="onCompositionEnd"):i==="keydown"&&c.keyCode===_q&&(Vt="onCompositionStart");Vt&&(Sq&&c.locale!=="ko"&&(Dy||Vt!=="onCompositionStart"?Vt==="onCompositionEnd"&&Dy&&(bn=Xm()):(Ne=Ue,je="value"in Ne?Ne.value:Ne.textContent,Dy=!0)),Ot=Io(oe,Vt),0<Ot.length&&(Vt=new xq(Vt,i,null,c,Ue),qe.push({event:Vt,listeners:Ot}),bn?Vt.data=bn:(bn=Jp(c),bn!==null&&(Vt.data=bn)))),(bn=Yve?e0(i,c):oM(i,c))&&(Vt=Io(oe,"onBeforeInput"),0<Vt.length&&(Ot=new Dve("onBeforeInput","beforeinput",null,c,Ue),qe.push({event:Ot,listeners:Vt}),Ot.data=bn)),wa(qe,i,oe,c,Ue)}g_(qe,s)})}function Dh(i,s,c){return{instance:i,listener:s,currentTarget:c}}function Io(i,s){for(var c=s+"Capture",v=[];i!==null;){var S=i,C=S.stateNode;if(S=S.tag,S!==5&&S!==26&&S!==27||C===null||(S=cs(i,c),S!=null&&v.unshift(Dh(i,S,C)),S=cs(i,s),S!=null&&v.push(Dh(i,S,C))),i.tag===3)return v;i=i.return}return[]}function qf(i){if(i===null)return null;do i=i.return;while(i&&i.tag!==5&&i.tag!==27);return i||null}function bu(i,s,c,v,S){for(var C=s._reactName,$=[];c!==null&&c!==v;){var F=c,X=F.alternate,oe=F.stateNode;if(F=F.tag,X!==null&&X===v)break;F!==5&&F!==26&&F!==27||oe===null||(X=oe,S?(oe=cs(c,C),oe!=null&&$.unshift(Dh(c,oe,X))):S||(oe=cs(c,C),oe!=null&&$.push(Dh(c,oe,X)))),c=c.return}$.length!==0&&i.push({event:s,listeners:$})}function _u(i,s){RT(i,s),i!=="input"&&i!=="textarea"&&i!=="select"||s==null||s.value!==null||I4||(I4=!0,i==="select"&&s.multiple?console.error("`value` prop on `%s` should not be null. Consider using an empty array when `multiple` is set to `true` to clear the component or `undefined` for uncontrolled components.",i):console.error("`value` prop on `%s` should not be null. Consider using an empty string to clear the component or `undefined` for uncontrolled components.",i));var c={registrationNameDependencies:tl,possibleRegistrationNames:Sy};vf(i)||typeof s.is=="string"||OT(i,s,c),s.contentEditable&&!s.suppressContentEditableWarning&&s.children!=null&&console.error("A component is `contentEditable` and contains `children` managed by React. It is now your responsibility to guarantee that none of those nodes are unexpectedly modified or duplicated. This is probably not intentional.")}function qr(i,s,c,v){s!==c&&(c=Su(c),Su(s)!==c&&(v[i]=s))}function v_(i,s,c){s.forEach(function(v){c[Mh(v)]=v==="style"?Wv(i):i.getAttribute(v)})}function bs(i,s){s===!1?console.error("Expected `%s` listener to be a function, instead got `false`.\n\nIf you used to conditionally omit it with %s={condition && value}, pass %s={condition ? value : undefined} instead.",i,i,i):console.error("Expected `%s` listener to be a function, instead got a value of `%s` type.",i,typeof s)}function Ws(i,s){return i=i.namespaceURI===Ty||i.namespaceURI===Iu?i.ownerDocument.createElementNS(i.namespaceURI,i.tagName):i.ownerDocument.createElement(i.tagName),i.innerHTML=s,i.innerHTML}function Su(i){return P(i)&&(console.error("The provided HTML markup uses a value of unsupported type %s. This value must be coerced to a string before using it here.",B(i)),ne(i)),(typeof i=="string"?i:""+i).replace(bye,`
244
- `).replace(_ye,"")}function Gf(i,s){return s=Su(s),Su(i)===s}function Sc(){}function ir(i,s,c,v,S,C){switch(c){case"children":typeof v=="string"?(Yd(v,s,!1),s==="body"||s==="textarea"&&v===""||Qp(i,v)):(typeof v=="number"||typeof v=="bigint")&&(Yd(""+v,s,!1),s!=="body"&&Qp(i,""+v));break;case"className":qt(i,"class",v);break;case"tabIndex":qt(i,"tabindex",v);break;case"dir":case"role":case"viewBox":case"width":case"height":qt(i,c,v);break;case"style":Km(i,v,C);break;case"data":if(s!=="object"){qt(i,"data",v);break}case"src":case"href":if(v===""&&(s!=="a"||c!=="href")){console.error(c==="src"?'An empty string ("") was passed to the %s attribute. This may cause the browser to download the whole page again over the network. To fix this, either do not render the element at all or pass null to %s instead of an empty string.':'An empty string ("") was passed to the %s attribute. To fix this, either do not render the element at all or pass null to %s instead of an empty string.',c,c),i.removeAttribute(c);break}if(v==null||typeof v=="function"||typeof v=="symbol"||typeof v=="boolean"){i.removeAttribute(c);break}U(v,c),v=iu(""+v),i.setAttribute(c,v);break;case"action":case"formAction":if(v!=null&&(s==="form"?c==="formAction"?console.error("You can only pass the formAction prop to <input> or <button>. Use the action prop on <form>."):typeof v=="function"&&(S.encType==null&&S.method==null||i3||(i3=!0,console.error("Cannot specify a encType or method for a form that specifies a function as the action. React provides those automatically. They will get overridden.")),S.target==null||r3||(r3=!0,console.error("Cannot specify a target for a form that specifies a function as the action. The function will always be executed in the same window."))):s==="input"||s==="button"?c==="action"?console.error("You can only pass the action prop to <form>. Use the formAction prop on <input> or <button>."):s!=="input"||S.type==="submit"||S.type==="image"||n3?s!=="button"||S.type==null||S.type==="submit"||n3?typeof v=="function"&&(S.name==null||YG||(YG=!0,console.error('Cannot specify a "name" prop for a button that specifies a function as a formAction. React needs it to encode which action should be invoked. It will get overridden.')),S.formEncType==null&&S.formMethod==null||i3||(i3=!0,console.error("Cannot specify a formEncType or formMethod for a button that specifies a function as a formAction. React provides those automatically. They will get overridden.")),S.formTarget==null||r3||(r3=!0,console.error("Cannot specify a formTarget for a button that specifies a function as a formAction. The function will always be executed in the same window."))):(n3=!0,console.error('A button can only specify a formAction along with type="submit" or no type.')):(n3=!0,console.error('An input can only specify a formAction along with type="submit" or type="image".')):console.error(c==="action"?"You can only pass the action prop to <form>.":"You can only pass the formAction prop to <input> or <button>.")),typeof v=="function"){i.setAttribute(c,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof C=="function"&&(c==="formAction"?(s!=="input"&&ir(i,s,"name",S.name,S,null),ir(i,s,"formEncType",S.formEncType,S,null),ir(i,s,"formMethod",S.formMethod,S,null),ir(i,s,"formTarget",S.formTarget,S,null)):(ir(i,s,"encType",S.encType,S,null),ir(i,s,"method",S.method,S,null),ir(i,s,"target",S.target,S,null)));if(v==null||typeof v=="symbol"||typeof v=="boolean"){i.removeAttribute(c);break}U(v,c),v=iu(""+v),i.setAttribute(c,v);break;case"onClick":v!=null&&(typeof v!="function"&&bs(c,v),i.onclick=Sc);break;case"onScroll":v!=null&&(typeof v!="function"&&bs(c,v),Ln("scroll",i));break;case"onScrollEnd":v!=null&&(typeof v!="function"&&bs(c,v),Ln("scrollend",i));break;case"dangerouslySetInnerHTML":if(v!=null){if(typeof v!="object"||!("__html"in v))throw Error("`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://react.dev/link/dangerously-set-inner-html for more information.");if(c=v.__html,c!=null){if(S.children!=null)throw Error("Can only set one of `children` or `props.dangerouslySetInnerHTML`.");i.innerHTML=c}}break;case"multiple":i.multiple=v&&typeof v!="function"&&typeof v!="symbol";break;case"muted":i.muted=v&&typeof v!="function"&&typeof v!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(v==null||typeof v=="function"||typeof v=="boolean"||typeof v=="symbol"){i.removeAttribute("xlink:href");break}U(v,c),c=iu(""+v),i.setAttributeNS(wg,"xlink:href",c);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":v!=null&&typeof v!="function"&&typeof v!="symbol"?(U(v,c),i.setAttribute(c,""+v)):i.removeAttribute(c);break;case"inert":v!==""||o3[c]||(o3[c]=!0,console.error("Received an empty string for a boolean attribute `%s`. This will treat the attribute as if it were false. Either pass `false` to silence this warning, or pass `true` if you used an empty string in earlier versions of React to indicate this attribute is true.",c));case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":v&&typeof v!="function"&&typeof v!="symbol"?i.setAttribute(c,""):i.removeAttribute(c);break;case"capture":case"download":v===!0?i.setAttribute(c,""):v!==!1&&v!=null&&typeof v!="function"&&typeof v!="symbol"?(U(v,c),i.setAttribute(c,v)):i.removeAttribute(c);break;case"cols":case"rows":case"size":case"span":v!=null&&typeof v!="function"&&typeof v!="symbol"&&!isNaN(v)&&1<=v?(U(v,c),i.setAttribute(c,v)):i.removeAttribute(c);break;case"rowSpan":case"start":v==null||typeof v=="function"||typeof v=="symbol"||isNaN(v)?i.removeAttribute(c):(U(v,c),i.setAttribute(c,v));break;case"popover":Ln("beforetoggle",i),Ln("toggle",i),Yt(i,"popover",v);break;case"xlinkActuate":ln(i,wg,"xlink:actuate",v);break;case"xlinkArcrole":ln(i,wg,"xlink:arcrole",v);break;case"xlinkRole":ln(i,wg,"xlink:role",v);break;case"xlinkShow":ln(i,wg,"xlink:show",v);break;case"xlinkTitle":ln(i,wg,"xlink:title",v);break;case"xlinkType":ln(i,wg,"xlink:type",v);break;case"xmlBase":ln(i,g5,"xml:base",v);break;case"xmlLang":ln(i,g5,"xml:lang",v);break;case"xmlSpace":ln(i,g5,"xml:space",v);break;case"is":C!=null&&console.error('Cannot update the "is" prop after it has been initialized.'),Yt(i,"is",v);break;case"innerText":case"textContent":break;case"popoverTarget":ZG||v==null||typeof v!="object"||(ZG=!0,console.error("The `popoverTarget` prop expects the ID of an Element as a string. Received %s instead.",v));default:!(2<c.length)||c[0]!=="o"&&c[0]!=="O"||c[1]!=="n"&&c[1]!=="N"?(c=yf(c),Yt(i,c,v)):tl.hasOwnProperty(c)&&v!=null&&typeof v!="function"&&bs(c,v)}}function wc(i,s,c,v,S,C){switch(c){case"style":Km(i,v,C);break;case"dangerouslySetInnerHTML":if(v!=null){if(typeof v!="object"||!("__html"in v))throw Error("`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://react.dev/link/dangerously-set-inner-html for more information.");if(c=v.__html,c!=null){if(S.children!=null)throw Error("Can only set one of `children` or `props.dangerouslySetInnerHTML`.");i.innerHTML=c}}break;case"children":typeof v=="string"?Qp(i,v):(typeof v=="number"||typeof v=="bigint")&&Qp(i,""+v);break;case"onScroll":v!=null&&(typeof v!="function"&&bs(c,v),Ln("scroll",i));break;case"onScrollEnd":v!=null&&(typeof v!="function"&&bs(c,v),Ln("scrollend",i));break;case"onClick":v!=null&&(typeof v!="function"&&bs(c,v),i.onclick=Sc);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(tl.hasOwnProperty(c))v!=null&&typeof v!="function"&&bs(c,v);else e:{if(c[0]==="o"&&c[1]==="n"&&(S=c.endsWith("Capture"),s=c.slice(2,S?c.length-7:void 0),C=i[Ra]||null,C=C!=null?C[c]:null,typeof C=="function"&&i.removeEventListener(s,C,S),typeof v=="function")){typeof C!="function"&&C!==null&&(c in i?i[c]=null:i.hasAttribute(c)&&i.removeAttribute(c)),i.addEventListener(s,v,S);break e}c in i?i[c]=v:v===!0?i.setAttribute(c,""):Yt(i,c,v)}}}function io(i,s,c){switch(_u(s,c),s){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Ln("error",i),Ln("load",i);var v=!1,S=!1,C;for(C in c)if(c.hasOwnProperty(C)){var $=c[C];if($!=null)switch(C){case"src":v=!0;break;case"srcSet":S=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:ir(i,s,C,$,c,null)}}S&&ir(i,s,"srcSet",c.srcSet,c,null),v&&ir(i,s,"src",c.src,c,null);return;case"input":St("input",c),Ln("invalid",i);var F=C=$=S=null,X=null,oe=null;for(v in c)if(c.hasOwnProperty(v)){var Ue=c[v];if(Ue!=null)switch(v){case"name":S=Ue;break;case"type":$=Ue;break;case"checked":X=Ue;break;case"defaultChecked":oe=Ue;break;case"value":C=Ue;break;case"defaultValue":F=Ue;break;case"children":case"dangerouslySetInnerHTML":if(Ue!=null)throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");break;default:ir(i,s,v,Ue,c,null)}}Br(i,c),Kr(i,C,F,X,oe,$,S,!1),qn(i);return;case"select":St("select",c),Ln("invalid",i),v=$=C=null;for(S in c)if(c.hasOwnProperty(S)&&(F=c[S],F!=null))switch(S){case"value":C=F;break;case"defaultValue":$=F;break;case"multiple":v=F;default:ir(i,s,S,F,c,null)}Me(i,c),s=C,c=$,i.multiple=!!v,s!=null?ce(i,!!v,s,!1):c!=null&&ce(i,!!v,c,!0);return;case"textarea":St("textarea",c),Ln("invalid",i),C=S=v=null;for($ in c)if(c.hasOwnProperty($)&&(F=c[$],F!=null))switch($){case"value":v=F;break;case"defaultValue":S=F;break;case"children":C=F;break;case"dangerouslySetInnerHTML":if(F!=null)throw Error("`dangerouslySetInnerHTML` does not make sense on <textarea>.");break;default:ir(i,s,$,F,c,null)}j(i,c),he(i,v,S,C),qn(i);return;case"option":Oe(i,c);for(X in c)if(c.hasOwnProperty(X)&&(v=c[X],v!=null))switch(X){case"selected":i.selected=v&&typeof v!="function"&&typeof v!="symbol";break;default:ir(i,s,X,v,c,null)}return;case"dialog":Ln("beforetoggle",i),Ln("toggle",i),Ln("cancel",i),Ln("close",i);break;case"iframe":case"object":Ln("load",i);break;case"video":case"audio":for(v=0;v<AS.length;v++)Ln(AS[v],i);break;case"image":Ln("error",i),Ln("load",i);break;case"details":Ln("toggle",i);break;case"embed":case"source":case"link":Ln("error",i),Ln("load",i);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(oe in c)if(c.hasOwnProperty(oe)&&(v=c[oe],v!=null))switch(oe){case"children":case"dangerouslySetInnerHTML":throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:ir(i,s,oe,v,c,null)}return;default:if(vf(s)){for(Ue in c)c.hasOwnProperty(Ue)&&(v=c[Ue],v!==void 0&&wc(i,s,Ue,v,c,void 0));return}}for(F in c)c.hasOwnProperty(F)&&(v=c[F],v!=null&&ir(i,s,F,v,c,null))}function s4(i,s,c,v){switch(_u(s,v),s){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var S=null,C=null,$=null,F=null,X=null,oe=null,Ue=null;for(Ze in c){var qe=c[Ze];if(c.hasOwnProperty(Ze)&&qe!=null)switch(Ze){case"checked":break;case"value":break;case"defaultValue":X=qe;default:v.hasOwnProperty(Ze)||ir(i,s,Ze,null,v,qe)}}for(var ze in v){var Ze=v[ze];if(qe=c[ze],v.hasOwnProperty(ze)&&(Ze!=null||qe!=null))switch(ze){case"type":C=Ze;break;case"name":S=Ze;break;case"checked":oe=Ze;break;case"defaultChecked":Ue=Ze;break;case"value":$=Ze;break;case"defaultValue":F=Ze;break;case"children":case"dangerouslySetInnerHTML":if(Ze!=null)throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");break;default:Ze!==qe&&ir(i,s,ze,Ze,v,qe)}}s=c.type==="checkbox"||c.type==="radio"?c.checked!=null:c.value!=null,v=v.type==="checkbox"||v.type==="radio"?v.checked!=null:v.value!=null,s||!v||VG||(console.error("A component is changing an uncontrolled input to be controlled. This is likely caused by the value changing from undefined to a defined value, which should not happen. Decide between using a controlled or uncontrolled input element for the lifetime of the component. More info: https://react.dev/link/controlled-components"),VG=!0),!s||v||GG||(console.error("A component is changing a controlled input to be uncontrolled. This is likely caused by the value changing from a defined to undefined, which should not happen. Decide between using a controlled or uncontrolled input element for the lifetime of the component. More info: https://react.dev/link/controlled-components"),GG=!0),ca(i,$,F,X,oe,Ue,C,S);return;case"select":Ze=$=F=ze=null;for(C in c)if(X=c[C],c.hasOwnProperty(C)&&X!=null)switch(C){case"value":break;case"multiple":Ze=X;default:v.hasOwnProperty(C)||ir(i,s,C,null,v,X)}for(S in v)if(C=v[S],X=c[S],v.hasOwnProperty(S)&&(C!=null||X!=null))switch(S){case"value":ze=C;break;case"defaultValue":F=C;break;case"multiple":$=C;default:C!==X&&ir(i,s,S,C,v,X)}v=F,s=$,c=Ze,ze!=null?ce(i,!!s,ze,!1):!!c!=!!s&&(v!=null?ce(i,!!s,v,!0):ce(i,!!s,s?[]:"",!1));return;case"textarea":Ze=ze=null;for(F in c)if(S=c[F],c.hasOwnProperty(F)&&S!=null&&!v.hasOwnProperty(F))switch(F){case"value":break;case"children":break;default:ir(i,s,F,null,v,S)}for($ in v)if(S=v[$],C=c[$],v.hasOwnProperty($)&&(S!=null||C!=null))switch($){case"value":ze=S;break;case"defaultValue":Ze=S;break;case"children":break;case"dangerouslySetInnerHTML":if(S!=null)throw Error("`dangerouslySetInnerHTML` does not make sense on <textarea>.");break;default:S!==C&&ir(i,s,$,S,v,C)}te(i,ze,Ze);return;case"option":for(var Gt in c)if(ze=c[Gt],c.hasOwnProperty(Gt)&&ze!=null&&!v.hasOwnProperty(Gt))switch(Gt){case"selected":i.selected=!1;break;default:ir(i,s,Gt,null,v,ze)}for(X in v)if(ze=v[X],Ze=c[X],v.hasOwnProperty(X)&&ze!==Ze&&(ze!=null||Ze!=null))switch(X){case"selected":i.selected=ze&&typeof ze!="function"&&typeof ze!="symbol";break;default:ir(i,s,X,ze,v,Ze)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var cn in c)ze=c[cn],c.hasOwnProperty(cn)&&ze!=null&&!v.hasOwnProperty(cn)&&ir(i,s,cn,null,v,ze);for(oe in v)if(ze=v[oe],Ze=c[oe],v.hasOwnProperty(oe)&&ze!==Ze&&(ze!=null||Ze!=null))switch(oe){case"children":case"dangerouslySetInnerHTML":if(ze!=null)throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");break;default:ir(i,s,oe,ze,v,Ze)}return;default:if(vf(s)){for(var Vr in c)ze=c[Vr],c.hasOwnProperty(Vr)&&ze!==void 0&&!v.hasOwnProperty(Vr)&&wc(i,s,Vr,void 0,v,ze);for(Ue in v)ze=v[Ue],Ze=c[Ue],!v.hasOwnProperty(Ue)||ze===Ze||ze===void 0&&Ze===void 0||wc(i,s,Ue,ze,v,Ze);return}}for(var Gn in c)ze=c[Gn],c.hasOwnProperty(Gn)&&ze!=null&&!v.hasOwnProperty(Gn)&&ir(i,s,Gn,null,v,ze);for(qe in v)ze=v[qe],Ze=c[qe],!v.hasOwnProperty(qe)||ze===Ze||ze==null&&Ze==null||ir(i,s,qe,ze,v,Ze)}function Mh(i){switch(i){case"class":return"className";case"for":return"htmlFor";default:return i}}function Wv(i){var s={};i=i.style;for(var c=0;c<i.length;c++){var v=i[c];s[v]=i.getPropertyValue(v)}return s}function F0(i,s,c){if(s!=null&&typeof s!="object")console.error("The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + 'em'}} when using JSX.");else{var v,S=v="",C;for(C in s)if(s.hasOwnProperty(C)){var $=s[C];$!=null&&typeof $!="boolean"&&$!==""&&(C.indexOf("--")===0?(fe($,C),v+=S+C+":"+(""+$).trim()):typeof $!="number"||$===0||X_.has(C)?(fe($,C),v+=S+C.replace(Mu,"-$1").toLowerCase().replace(Zh,"-ms-")+":"+(""+$).trim()):v+=S+C.replace(Mu,"-$1").toLowerCase().replace(Zh,"-ms-")+":"+$+"px",S=";")}v=v||null,s=i.getAttribute("style"),s!==v&&(v=Su(v),Su(s)!==v&&(c.style=Wv(i)))}}function qa(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null)switch(typeof v){case"undefined":case"function":case"symbol":case"boolean":return}else if(v!=null)switch(typeof v){case"function":case"symbol":case"boolean":break;default:if(U(v,s),i===""+v)return}qr(s,i,v,C)}function l4(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null){switch(typeof v){case"function":case"symbol":return}if(!v)return}else switch(typeof v){case"function":case"symbol":break;default:if(v)return}qr(s,i,v,C)}function y_(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null)switch(typeof v){case"undefined":case"function":case"symbol":return}else if(v!=null)switch(typeof v){case"function":case"symbol":break;default:if(U(v,c),i===""+v)return}qr(s,i,v,C)}function vr(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null)switch(typeof v){case"undefined":case"function":case"symbol":case"boolean":return;default:if(isNaN(v))return}else if(v!=null)switch(typeof v){case"function":case"symbol":case"boolean":break;default:if(!isNaN(v)&&(U(v,s),i===""+v))return}qr(s,i,v,C)}function kr(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null)switch(typeof v){case"undefined":case"function":case"symbol":case"boolean":return}else if(v!=null)switch(typeof v){case"function":case"symbol":case"boolean":break;default:if(U(v,s),c=iu(""+v),i===c)return}qr(s,i,v,C)}function Nn(i,s,c,v){for(var S={},C=new Set,$=i.attributes,F=0;F<$.length;F++)switch($[F].name.toLowerCase()){case"value":break;case"checked":break;case"selected":break;default:C.add($[F].name)}if(vf(s)){for(var X in c)if(c.hasOwnProperty(X)){var oe=c[X];if(oe!=null){if(tl.hasOwnProperty(X))typeof oe!="function"&&bs(X,oe);else if(c.suppressHydrationWarning!==!0)switch(X){case"children":typeof oe!="string"&&typeof oe!="number"||qr("children",i.textContent,oe,S);continue;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":continue;case"dangerouslySetInnerHTML":$=i.innerHTML,oe=oe?oe.__html:void 0,oe!=null&&(oe=Ws(i,oe),qr(X,$,oe,S));continue;case"style":C.delete(X),F0(i,oe,S);continue;case"offsetParent":case"offsetTop":case"offsetLeft":case"offsetWidth":case"offsetHeight":case"isContentEditable":case"outerText":case"outerHTML":C.delete(X.toLowerCase()),console.error("Assignment to read-only property will result in a no-op: `%s`",X);continue;case"className":C.delete("class"),$=Ht(i,"class",oe),qr("className",$,oe,S);continue;default:v.context===ad&&s!=="svg"&&s!=="math"?C.delete(X.toLowerCase()):C.delete(X),$=Ht(i,X,oe),qr(X,$,oe,S)}}}}else for(oe in c)if(c.hasOwnProperty(oe)&&(X=c[oe],X!=null)){if(tl.hasOwnProperty(oe))typeof X!="function"&&bs(oe,X);else if(c.suppressHydrationWarning!==!0)switch(oe){case"children":typeof X!="string"&&typeof X!="number"||qr("children",i.textContent,X,S);continue;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"value":case"checked":case"selected":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":continue;case"dangerouslySetInnerHTML":$=i.innerHTML,X=X?X.__html:void 0,X!=null&&(X=Ws(i,X),$!==X&&(S[oe]={__html:$}));continue;case"className":qa(i,oe,"class",X,C,S);continue;case"tabIndex":qa(i,oe,"tabindex",X,C,S);continue;case"style":C.delete(oe),F0(i,X,S);continue;case"multiple":C.delete(oe),qr(oe,i.multiple,X,S);continue;case"muted":C.delete(oe),qr(oe,i.muted,X,S);continue;case"autoFocus":C.delete("autofocus"),qr(oe,i.autofocus,X,S);continue;case"data":if(s!=="object"){C.delete(oe),$=i.getAttribute("data"),qr(oe,$,X,S);continue}case"src":case"href":if(!(X!==""||s==="a"&&oe==="href"||s==="object"&&oe==="data")){console.error(oe==="src"?'An empty string ("") was passed to the %s attribute. This may cause the browser to download the whole page again over the network. To fix this, either do not render the element at all or pass null to %s instead of an empty string.':'An empty string ("") was passed to the %s attribute. To fix this, either do not render the element at all or pass null to %s instead of an empty string.',oe,oe);continue}kr(i,oe,oe,X,C,S);continue;case"action":case"formAction":if($=i.getAttribute(oe),typeof X=="function"){C.delete(oe.toLowerCase()),oe==="formAction"?(C.delete("name"),C.delete("formenctype"),C.delete("formmethod"),C.delete("formtarget")):(C.delete("enctype"),C.delete("method"),C.delete("target"));continue}else if($===Sye){C.delete(oe.toLowerCase()),qr(oe,"function",X,S);continue}kr(i,oe,oe.toLowerCase(),X,C,S);continue;case"xlinkHref":kr(i,oe,"xlink:href",X,C,S);continue;case"contentEditable":y_(i,oe,"contenteditable",X,C,S);continue;case"spellCheck":y_(i,oe,"spellcheck",X,C,S);continue;case"draggable":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":y_(i,oe,oe,X,C,S);continue;case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":l4(i,oe,oe.toLowerCase(),X,C,S);continue;case"capture":case"download":e:{F=i;var Ue=$=oe,qe=S;if(C.delete(Ue),F=F.getAttribute(Ue),F===null)switch(typeof X){case"undefined":case"function":case"symbol":break e;default:if(X===!1)break e}else if(X!=null)switch(typeof X){case"function":case"symbol":break;case"boolean":if(X===!0&&F==="")break e;break;default:if(U(X,$),F===""+X)break e}qr($,F,X,qe)}continue;case"cols":case"rows":case"size":case"span":e:{if(F=i,Ue=$=oe,qe=S,C.delete(Ue),F=F.getAttribute(Ue),F===null)switch(typeof X){case"undefined":case"function":case"symbol":case"boolean":break e;default:if(isNaN(X)||1>X)break e}else if(X!=null)switch(typeof X){case"function":case"symbol":case"boolean":break;default:if(!(isNaN(X)||1>X)&&(U(X,$),F===""+X))break e}qr($,F,X,qe)}continue;case"rowSpan":vr(i,oe,"rowspan",X,C,S);continue;case"start":vr(i,oe,oe,X,C,S);continue;case"xHeight":qa(i,oe,"x-height",X,C,S);continue;case"xlinkActuate":qa(i,oe,"xlink:actuate",X,C,S);continue;case"xlinkArcrole":qa(i,oe,"xlink:arcrole",X,C,S);continue;case"xlinkRole":qa(i,oe,"xlink:role",X,C,S);continue;case"xlinkShow":qa(i,oe,"xlink:show",X,C,S);continue;case"xlinkTitle":qa(i,oe,"xlink:title",X,C,S);continue;case"xlinkType":qa(i,oe,"xlink:type",X,C,S);continue;case"xmlBase":qa(i,oe,"xml:base",X,C,S);continue;case"xmlLang":qa(i,oe,"xml:lang",X,C,S);continue;case"xmlSpace":qa(i,oe,"xml:space",X,C,S);continue;case"inert":X!==""||o3[oe]||(o3[oe]=!0,console.error("Received an empty string for a boolean attribute `%s`. This will treat the attribute as if it were false. Either pass `false` to silence this warning, or pass `true` if you used an empty string in earlier versions of React to indicate this attribute is true.",oe)),l4(i,oe,oe,X,C,S);continue;default:if(!(2<oe.length)||oe[0]!=="o"&&oe[0]!=="O"||oe[1]!=="n"&&oe[1]!=="N"){F=yf(oe),$=!1,v.context===ad&&s!=="svg"&&s!=="math"?C.delete(F.toLowerCase()):(Ue=oe.toLowerCase(),Ue=sg.hasOwnProperty(Ue)&&sg[Ue]||null,Ue!==null&&Ue!==oe&&($=!0,C.delete(Ue)),C.delete(F));e:if(Ue=i,qe=F,F=X,Pt(qe))if(Ue.hasAttribute(qe))Ue=Ue.getAttribute(qe),U(F,qe),F=Ue===""+F?F:Ue;else{switch(typeof F){case"function":case"symbol":break e;case"boolean":if(Ue=qe.toLowerCase().slice(0,5),Ue!=="data-"&&Ue!=="aria-")break e}F=F===void 0?void 0:null}else F=void 0;$||qr(oe,F,X,S)}}}return 0<C.size&&c.suppressHydrationWarning!==!0&&v_(i,C,S),Object.keys(S).length===0?null:S}function Kn(i,s){switch(i.length){case 0:return"";case 1:return i[0];case 2:return i[0]+" "+s+" "+i[1];default:return i.slice(0,-1).join(", ")+", "+s+" "+i[i.length-1]}}function or(i){return i.nodeType===9?i:i.ownerDocument}function Ea(i){switch(i){case Iu:return i1;case Ty:return l3;default:return ad}}function wu(i,s){if(i===ad)switch(s){case"svg":return i1;case"math":return l3;default:return ad}return i===i1&&s==="foreignObject"?ad:i}function Cc(i,s){return i==="textarea"||i==="noscript"||typeof s.children=="string"||typeof s.children=="number"||typeof s.children=="bigint"||typeof s.dangerouslySetInnerHTML=="object"&&s.dangerouslySetInnerHTML!==null&&s.dangerouslySetInnerHTML.__html!=null}function x_(){var i=window.event;return i&&i.type==="popstate"?i===x5?!1:(x5=i,!0):(x5=null,!1)}function Cu(i){setTimeout(function(){throw i})}function vi(i,s,c){switch(s){case"button":case"input":case"select":case"textarea":c.autoFocus&&i.focus();break;case"img":c.src?i.src=c.src:c.srcSet&&(i.srcset=c.srcSet)}}function Ec(i,s,c,v){s4(i,s,c,v),i[Ra]=v}function Ac(i){Qp(i,"")}function b_(i,s,c){i.nodeValue=c}function qi(i){return i==="head"}function Ih(i,s){i.removeChild(s)}function U0(i,s){(i.nodeType===9?i.body:i.nodeName==="HTML"?i.ownerDocument.body:i).removeChild(s)}function Yo(i,s){var c=s,v=0,S=0;do{var C=c.nextSibling;if(i.removeChild(c),C&&C.nodeType===8)if(c=C.data,c===s3){if(0<v&&8>v){c=v;var $=i.ownerDocument;if(c&Cye&&Lh($.documentElement),c&Eye&&Lh($.body),c&Aye)for(c=$.head,Lh(c),$=c.firstChild;$;){var F=$.nextSibling,X=$.nodeName;$[J0]||X==="SCRIPT"||X==="STYLE"||X==="LINK"&&$.rel.toLowerCase()==="stylesheet"||c.removeChild($),$=F}}if(S===0){i.removeChild(C),jh(s);return}S--}else c===a3||c===od||c===kS?S++:v=c.charCodeAt(0)-48;else v=0;c=C}while(c);jh(s)}function __(i){i=i.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none"}function S_(i){i.nodeValue=""}function Xv(i,s){s=s[kye],s=s!=null&&s.hasOwnProperty("display")?s.display:null,i.style.display=s==null||typeof s=="boolean"?"":(""+s).trim()}function Jv(i,s){i.nodeValue=s}function El(i){var s=i.firstChild;for(s&&s.nodeType===10&&(s=s.nextSibling);s;){var c=s;switch(s=s.nextSibling,c.nodeName){case"HTML":case"HEAD":case"BODY":El(c),gn(c);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(c.rel.toLowerCase()==="stylesheet")continue}i.removeChild(c)}}function yo(i,s,c,v){for(;i.nodeType===1;){var S=c;if(i.nodeName.toLowerCase()!==s.toLowerCase()){if(!v&&(i.nodeName!=="INPUT"||i.type!=="hidden"))break}else if(v){if(!i[J0])switch(s){case"meta":if(!i.hasAttribute("itemprop"))break;return i;case"link":if(C=i.getAttribute("rel"),C==="stylesheet"&&i.hasAttribute("data-precedence"))break;if(C!==S.rel||i.getAttribute("href")!==(S.href==null||S.href===""?null:S.href)||i.getAttribute("crossorigin")!==(S.crossOrigin==null?null:S.crossOrigin)||i.getAttribute("title")!==(S.title==null?null:S.title))break;return i;case"style":if(i.hasAttribute("data-precedence"))break;return i;case"script":if(C=i.getAttribute("src"),(C!==(S.src==null?null:S.src)||i.getAttribute("type")!==(S.type==null?null:S.type)||i.getAttribute("crossorigin")!==(S.crossOrigin==null?null:S.crossOrigin))&&C&&i.hasAttribute("async")&&!i.hasAttribute("itemprop"))break;return i;default:return i}}else if(s==="input"&&i.type==="hidden"){U(S.name,"name");var C=S.name==null?null:""+S.name;if(S.type==="hidden"&&i.getAttribute("name")===C)return i}else return i;if(i=Aa(i.nextSibling),i===null)break}return null}function kc(i,s,c){if(s==="")return null;for(;i.nodeType!==3;)if((i.nodeType!==1||i.nodeName!=="INPUT"||i.type!=="hidden")&&!c||(i=Aa(i.nextSibling),i===null))return null;return i}function Tc(i){return i.data===kS||i.data===od&&i.ownerDocument.readyState===KG}function $h(i,s){var c=i.ownerDocument;if(i.data!==od||c.readyState===KG)s();else{var v=function(){s(),c.removeEventListener("DOMContentLoaded",v)};c.addEventListener("DOMContentLoaded",v),i._reactRetry=v}}function Aa(i){for(;i!=null;i=i.nextSibling){var s=i.nodeType;if(s===1||s===3)break;if(s===8){if(s=i.data,s===a3||s===kS||s===od||s===m5||s===QG)break;if(s===s3)return null}}return i}function ey(i){if(i.nodeType===1){for(var s=i.nodeName.toLowerCase(),c={},v=i.attributes,S=0;S<v.length;S++){var C=v[S];c[Mh(C.name)]=C.name.toLowerCase()==="style"?Wv(i):C.value}return{type:s,props:c}}return i.nodeType===8?{type:"Suspense",props:{}}:i.nodeValue}function w_(i,s,c){return c===null||c[wye]!==!0?(i.nodeValue===s?i=null:(s=Su(s),i=Su(i.nodeValue)===s?null:i.nodeValue),i):null}function Bh(i){i=i.nextSibling;for(var s=0;i;){if(i.nodeType===8){var c=i.data;if(c===s3){if(s===0)return Aa(i.nextSibling);s--}else c!==a3&&c!==kS&&c!==od||s++}i=i.nextSibling}return null}function ty(i){i=i.previousSibling;for(var s=0;i;){if(i.nodeType===8){var c=i.data;if(c===a3||c===kS||c===od){if(s===0)return i;s--}else c===s3&&s++}i=i.previousSibling}return null}function Ga(i){jh(i)}function u4(i){jh(i)}function ka(i,s,c,v,S){switch(S&&Qm(i,v.ancestorInfo),s=or(c),i){case"html":if(i=s.documentElement,!i)throw Error("React expected an <html> element (document.documentElement) to exist in the Document but one was not found. React never removes the documentElement for any Document it renders into so the cause is likely in some other script running on this page.");return i;case"head":if(i=s.head,!i)throw Error("React expected a <head> element (document.head) to exist in the Document but one was not found. React never removes the head for any Document it renders into so the cause is likely in some other script running on this page.");return i;case"body":if(i=s.body,!i)throw Error("React expected a <body> element (document.body) to exist in the Document but one was not found. React never removes the body for any Document it renders into so the cause is likely in some other script running on this page.");return i;default:throw Error("resolveSingletonInstance was called with an element type that is not supported. This is a bug in React.")}}function c4(i,s,c,v){if(!c[Bc]&&Kt(c)){var S=c.tagName.toLowerCase();console.error("You are mounting a new %s component when a previous one has not first unmounted. It is an error to render more than one %s component at a time and attributes and children of these components will likely fail in unpredictable ways. Please only render a single instance of <%s> and if you need to mount a new one, ensure any previous ones have unmounted first.",S,S,S)}switch(i){case"html":case"head":case"body":break;default:console.error("acquireSingletonInstance was called with an element type that is not supported. This is a bug in React.")}for(S=c.attributes;S.length;)c.removeAttributeNode(S[0]);io(c,i,s),c[$o]=v,c[Ra]=s}function Lh(i){for(var s=i.attributes;s.length;)i.removeAttributeNode(s[0]);gn(i)}function ny(i){return typeof i.getRootNode=="function"?i.getRootNode():i.nodeType===9?i:i.ownerDocument}function Eu(i,s,c){var v=o1;if(v&&typeof s=="string"&&s){var S=pr(s);S='link[rel="'+i+'"][href="'+S+'"]',typeof c=="string"&&(S+='[crossorigin="'+c+'"]'),nV.has(S)||(nV.add(S),i={rel:i,crossOrigin:c,href:s},v.querySelector(S)===null&&(s=v.createElement("link"),io(s,"link",i),xe(s),v.head.appendChild(s)))}}function j0(i,s,c,v){var S=(S=kl.current)?ny(S):null;if(!S)throw Error('"resourceRoot" was expected to exist. This is a bug in React.');switch(i){case"meta":case"title":return null;case"style":return typeof c.precedence=="string"&&typeof c.href=="string"?(c=Xs(c.href),s=Y(S).hoistableStyles,v=s.get(c),v||(v={type:"style",instance:null,count:0,state:null},s.set(c,v)),v):{type:"void",instance:null,count:0,state:null};case"link":if(c.rel==="stylesheet"&&typeof c.href=="string"&&typeof c.precedence=="string"){i=Xs(c.href);var C=Y(S).hoistableStyles,$=C.get(i);if(!$&&(S=S.ownerDocument||S,$={type:"stylesheet",instance:null,count:0,state:{loading:Eg,preload:null}},C.set(i,$),(C=S.querySelector(zh(i)))&&!C._p&&($.instance=C,$.state.loading=TS|Hl),!ql.has(i))){var F={rel:"preload",as:"style",href:c.href,crossOrigin:c.crossOrigin,integrity:c.integrity,media:c.media,hrefLang:c.hrefLang,referrerPolicy:c.referrerPolicy};ql.set(i,F),C||f4(S,i,F,$.state)}if(s&&v===null)throw c=`
244
+ `).replace(_ye,"")}function Gf(i,s){return s=Su(s),Su(i)===s}function Sc(){}function ir(i,s,c,v,S,C){switch(c){case"children":typeof v=="string"?(Yd(v,s,!1),s==="body"||s==="textarea"&&v===""||Qp(i,v)):(typeof v=="number"||typeof v=="bigint")&&(Yd(""+v,s,!1),s!=="body"&&Qp(i,""+v));break;case"className":qt(i,"class",v);break;case"tabIndex":qt(i,"tabindex",v);break;case"dir":case"role":case"viewBox":case"width":case"height":qt(i,c,v);break;case"style":Km(i,v,C);break;case"data":if(s!=="object"){qt(i,"data",v);break}case"src":case"href":if(v===""&&(s!=="a"||c!=="href")){console.error(c==="src"?'An empty string ("") was passed to the %s attribute. This may cause the browser to download the whole page again over the network. To fix this, either do not render the element at all or pass null to %s instead of an empty string.':'An empty string ("") was passed to the %s attribute. To fix this, either do not render the element at all or pass null to %s instead of an empty string.',c,c),i.removeAttribute(c);break}if(v==null||typeof v=="function"||typeof v=="symbol"||typeof v=="boolean"){i.removeAttribute(c);break}U(v,c),v=iu(""+v),i.setAttribute(c,v);break;case"action":case"formAction":if(v!=null&&(s==="form"?c==="formAction"?console.error("You can only pass the formAction prop to <input> or <button>. Use the action prop on <form>."):typeof v=="function"&&(S.encType==null&&S.method==null||i3||(i3=!0,console.error("Cannot specify a encType or method for a form that specifies a function as the action. React provides those automatically. They will get overridden.")),S.target==null||r3||(r3=!0,console.error("Cannot specify a target for a form that specifies a function as the action. The function will always be executed in the same window."))):s==="input"||s==="button"?c==="action"?console.error("You can only pass the action prop to <form>. Use the formAction prop on <input> or <button>."):s!=="input"||S.type==="submit"||S.type==="image"||n3?s!=="button"||S.type==null||S.type==="submit"||n3?typeof v=="function"&&(S.name==null||YG||(YG=!0,console.error('Cannot specify a "name" prop for a button that specifies a function as a formAction. React needs it to encode which action should be invoked. It will get overridden.')),S.formEncType==null&&S.formMethod==null||i3||(i3=!0,console.error("Cannot specify a formEncType or formMethod for a button that specifies a function as a formAction. React provides those automatically. They will get overridden.")),S.formTarget==null||r3||(r3=!0,console.error("Cannot specify a formTarget for a button that specifies a function as a formAction. The function will always be executed in the same window."))):(n3=!0,console.error('A button can only specify a formAction along with type="submit" or no type.')):(n3=!0,console.error('An input can only specify a formAction along with type="submit" or type="image".')):console.error(c==="action"?"You can only pass the action prop to <form>.":"You can only pass the formAction prop to <input> or <button>.")),typeof v=="function"){i.setAttribute(c,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof C=="function"&&(c==="formAction"?(s!=="input"&&ir(i,s,"name",S.name,S,null),ir(i,s,"formEncType",S.formEncType,S,null),ir(i,s,"formMethod",S.formMethod,S,null),ir(i,s,"formTarget",S.formTarget,S,null)):(ir(i,s,"encType",S.encType,S,null),ir(i,s,"method",S.method,S,null),ir(i,s,"target",S.target,S,null)));if(v==null||typeof v=="symbol"||typeof v=="boolean"){i.removeAttribute(c);break}U(v,c),v=iu(""+v),i.setAttribute(c,v);break;case"onClick":v!=null&&(typeof v!="function"&&bs(c,v),i.onclick=Sc);break;case"onScroll":v!=null&&(typeof v!="function"&&bs(c,v),Ln("scroll",i));break;case"onScrollEnd":v!=null&&(typeof v!="function"&&bs(c,v),Ln("scrollend",i));break;case"dangerouslySetInnerHTML":if(v!=null){if(typeof v!="object"||!("__html"in v))throw Error("`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://react.dev/link/dangerously-set-inner-html for more information.");if(c=v.__html,c!=null){if(S.children!=null)throw Error("Can only set one of `children` or `props.dangerouslySetInnerHTML`.");i.innerHTML=c}}break;case"multiple":i.multiple=v&&typeof v!="function"&&typeof v!="symbol";break;case"muted":i.muted=v&&typeof v!="function"&&typeof v!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(v==null||typeof v=="function"||typeof v=="boolean"||typeof v=="symbol"){i.removeAttribute("xlink:href");break}U(v,c),c=iu(""+v),i.setAttributeNS(wg,"xlink:href",c);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":v!=null&&typeof v!="function"&&typeof v!="symbol"?(U(v,c),i.setAttribute(c,""+v)):i.removeAttribute(c);break;case"inert":v!==""||o3[c]||(o3[c]=!0,console.error("Received an empty string for a boolean attribute `%s`. This will treat the attribute as if it were false. Either pass `false` to silence this warning, or pass `true` if you used an empty string in earlier versions of React to indicate this attribute is true.",c));case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":v&&typeof v!="function"&&typeof v!="symbol"?i.setAttribute(c,""):i.removeAttribute(c);break;case"capture":case"download":v===!0?i.setAttribute(c,""):v!==!1&&v!=null&&typeof v!="function"&&typeof v!="symbol"?(U(v,c),i.setAttribute(c,v)):i.removeAttribute(c);break;case"cols":case"rows":case"size":case"span":v!=null&&typeof v!="function"&&typeof v!="symbol"&&!isNaN(v)&&1<=v?(U(v,c),i.setAttribute(c,v)):i.removeAttribute(c);break;case"rowSpan":case"start":v==null||typeof v=="function"||typeof v=="symbol"||isNaN(v)?i.removeAttribute(c):(U(v,c),i.setAttribute(c,v));break;case"popover":Ln("beforetoggle",i),Ln("toggle",i),Yt(i,"popover",v);break;case"xlinkActuate":ln(i,wg,"xlink:actuate",v);break;case"xlinkArcrole":ln(i,wg,"xlink:arcrole",v);break;case"xlinkRole":ln(i,wg,"xlink:role",v);break;case"xlinkShow":ln(i,wg,"xlink:show",v);break;case"xlinkTitle":ln(i,wg,"xlink:title",v);break;case"xlinkType":ln(i,wg,"xlink:type",v);break;case"xmlBase":ln(i,g5,"xml:base",v);break;case"xmlLang":ln(i,g5,"xml:lang",v);break;case"xmlSpace":ln(i,g5,"xml:space",v);break;case"is":C!=null&&console.error('Cannot update the "is" prop after it has been initialized.'),Yt(i,"is",v);break;case"innerText":case"textContent":break;case"popoverTarget":ZG||v==null||typeof v!="object"||(ZG=!0,console.error("The `popoverTarget` prop expects the ID of an Element as a string. Received %s instead.",v));default:!(2<c.length)||c[0]!=="o"&&c[0]!=="O"||c[1]!=="n"&&c[1]!=="N"?(c=yf(c),Yt(i,c,v)):tl.hasOwnProperty(c)&&v!=null&&typeof v!="function"&&bs(c,v)}}function wc(i,s,c,v,S,C){switch(c){case"style":Km(i,v,C);break;case"dangerouslySetInnerHTML":if(v!=null){if(typeof v!="object"||!("__html"in v))throw Error("`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://react.dev/link/dangerously-set-inner-html for more information.");if(c=v.__html,c!=null){if(S.children!=null)throw Error("Can only set one of `children` or `props.dangerouslySetInnerHTML`.");i.innerHTML=c}}break;case"children":typeof v=="string"?Qp(i,v):(typeof v=="number"||typeof v=="bigint")&&Qp(i,""+v);break;case"onScroll":v!=null&&(typeof v!="function"&&bs(c,v),Ln("scroll",i));break;case"onScrollEnd":v!=null&&(typeof v!="function"&&bs(c,v),Ln("scrollend",i));break;case"onClick":v!=null&&(typeof v!="function"&&bs(c,v),i.onclick=Sc);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(tl.hasOwnProperty(c))v!=null&&typeof v!="function"&&bs(c,v);else e:{if(c[0]==="o"&&c[1]==="n"&&(S=c.endsWith("Capture"),s=c.slice(2,S?c.length-7:void 0),C=i[Ra]||null,C=C!=null?C[c]:null,typeof C=="function"&&i.removeEventListener(s,C,S),typeof v=="function")){typeof C!="function"&&C!==null&&(c in i?i[c]=null:i.hasAttribute(c)&&i.removeAttribute(c)),i.addEventListener(s,v,S);break e}c in i?i[c]=v:v===!0?i.setAttribute(c,""):Yt(i,c,v)}}}function io(i,s,c){switch(_u(s,c),s){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Ln("error",i),Ln("load",i);var v=!1,S=!1,C;for(C in c)if(c.hasOwnProperty(C)){var $=c[C];if($!=null)switch(C){case"src":v=!0;break;case"srcSet":S=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:ir(i,s,C,$,c,null)}}S&&ir(i,s,"srcSet",c.srcSet,c,null),v&&ir(i,s,"src",c.src,c,null);return;case"input":St("input",c),Ln("invalid",i);var F=C=$=S=null,X=null,oe=null;for(v in c)if(c.hasOwnProperty(v)){var Ue=c[v];if(Ue!=null)switch(v){case"name":S=Ue;break;case"type":$=Ue;break;case"checked":X=Ue;break;case"defaultChecked":oe=Ue;break;case"value":C=Ue;break;case"defaultValue":F=Ue;break;case"children":case"dangerouslySetInnerHTML":if(Ue!=null)throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");break;default:ir(i,s,v,Ue,c,null)}}Br(i,c),Kr(i,C,F,X,oe,$,S,!1),qn(i);return;case"select":St("select",c),Ln("invalid",i),v=$=C=null;for(S in c)if(c.hasOwnProperty(S)&&(F=c[S],F!=null))switch(S){case"value":C=F;break;case"defaultValue":$=F;break;case"multiple":v=F;default:ir(i,s,S,F,c,null)}Ie(i,c),s=C,c=$,i.multiple=!!v,s!=null?ce(i,!!v,s,!1):c!=null&&ce(i,!!v,c,!0);return;case"textarea":St("textarea",c),Ln("invalid",i),C=S=v=null;for($ in c)if(c.hasOwnProperty($)&&(F=c[$],F!=null))switch($){case"value":v=F;break;case"defaultValue":S=F;break;case"children":C=F;break;case"dangerouslySetInnerHTML":if(F!=null)throw Error("`dangerouslySetInnerHTML` does not make sense on <textarea>.");break;default:ir(i,s,$,F,c,null)}j(i,c),he(i,v,S,C),qn(i);return;case"option":Oe(i,c);for(X in c)if(c.hasOwnProperty(X)&&(v=c[X],v!=null))switch(X){case"selected":i.selected=v&&typeof v!="function"&&typeof v!="symbol";break;default:ir(i,s,X,v,c,null)}return;case"dialog":Ln("beforetoggle",i),Ln("toggle",i),Ln("cancel",i),Ln("close",i);break;case"iframe":case"object":Ln("load",i);break;case"video":case"audio":for(v=0;v<AS.length;v++)Ln(AS[v],i);break;case"image":Ln("error",i),Ln("load",i);break;case"details":Ln("toggle",i);break;case"embed":case"source":case"link":Ln("error",i),Ln("load",i);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(oe in c)if(c.hasOwnProperty(oe)&&(v=c[oe],v!=null))switch(oe){case"children":case"dangerouslySetInnerHTML":throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:ir(i,s,oe,v,c,null)}return;default:if(vf(s)){for(Ue in c)c.hasOwnProperty(Ue)&&(v=c[Ue],v!==void 0&&wc(i,s,Ue,v,c,void 0));return}}for(F in c)c.hasOwnProperty(F)&&(v=c[F],v!=null&&ir(i,s,F,v,c,null))}function s4(i,s,c,v){switch(_u(s,v),s){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var S=null,C=null,$=null,F=null,X=null,oe=null,Ue=null;for(Ze in c){var qe=c[Ze];if(c.hasOwnProperty(Ze)&&qe!=null)switch(Ze){case"checked":break;case"value":break;case"defaultValue":X=qe;default:v.hasOwnProperty(Ze)||ir(i,s,Ze,null,v,qe)}}for(var ze in v){var Ze=v[ze];if(qe=c[ze],v.hasOwnProperty(ze)&&(Ze!=null||qe!=null))switch(ze){case"type":C=Ze;break;case"name":S=Ze;break;case"checked":oe=Ze;break;case"defaultChecked":Ue=Ze;break;case"value":$=Ze;break;case"defaultValue":F=Ze;break;case"children":case"dangerouslySetInnerHTML":if(Ze!=null)throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");break;default:Ze!==qe&&ir(i,s,ze,Ze,v,qe)}}s=c.type==="checkbox"||c.type==="radio"?c.checked!=null:c.value!=null,v=v.type==="checkbox"||v.type==="radio"?v.checked!=null:v.value!=null,s||!v||VG||(console.error("A component is changing an uncontrolled input to be controlled. This is likely caused by the value changing from undefined to a defined value, which should not happen. Decide between using a controlled or uncontrolled input element for the lifetime of the component. More info: https://react.dev/link/controlled-components"),VG=!0),!s||v||GG||(console.error("A component is changing a controlled input to be uncontrolled. This is likely caused by the value changing from a defined to undefined, which should not happen. Decide between using a controlled or uncontrolled input element for the lifetime of the component. More info: https://react.dev/link/controlled-components"),GG=!0),ca(i,$,F,X,oe,Ue,C,S);return;case"select":Ze=$=F=ze=null;for(C in c)if(X=c[C],c.hasOwnProperty(C)&&X!=null)switch(C){case"value":break;case"multiple":Ze=X;default:v.hasOwnProperty(C)||ir(i,s,C,null,v,X)}for(S in v)if(C=v[S],X=c[S],v.hasOwnProperty(S)&&(C!=null||X!=null))switch(S){case"value":ze=C;break;case"defaultValue":F=C;break;case"multiple":$=C;default:C!==X&&ir(i,s,S,C,v,X)}v=F,s=$,c=Ze,ze!=null?ce(i,!!s,ze,!1):!!c!=!!s&&(v!=null?ce(i,!!s,v,!0):ce(i,!!s,s?[]:"",!1));return;case"textarea":Ze=ze=null;for(F in c)if(S=c[F],c.hasOwnProperty(F)&&S!=null&&!v.hasOwnProperty(F))switch(F){case"value":break;case"children":break;default:ir(i,s,F,null,v,S)}for($ in v)if(S=v[$],C=c[$],v.hasOwnProperty($)&&(S!=null||C!=null))switch($){case"value":ze=S;break;case"defaultValue":Ze=S;break;case"children":break;case"dangerouslySetInnerHTML":if(S!=null)throw Error("`dangerouslySetInnerHTML` does not make sense on <textarea>.");break;default:S!==C&&ir(i,s,$,S,v,C)}te(i,ze,Ze);return;case"option":for(var Gt in c)if(ze=c[Gt],c.hasOwnProperty(Gt)&&ze!=null&&!v.hasOwnProperty(Gt))switch(Gt){case"selected":i.selected=!1;break;default:ir(i,s,Gt,null,v,ze)}for(X in v)if(ze=v[X],Ze=c[X],v.hasOwnProperty(X)&&ze!==Ze&&(ze!=null||Ze!=null))switch(X){case"selected":i.selected=ze&&typeof ze!="function"&&typeof ze!="symbol";break;default:ir(i,s,X,ze,v,Ze)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var cn in c)ze=c[cn],c.hasOwnProperty(cn)&&ze!=null&&!v.hasOwnProperty(cn)&&ir(i,s,cn,null,v,ze);for(oe in v)if(ze=v[oe],Ze=c[oe],v.hasOwnProperty(oe)&&ze!==Ze&&(ze!=null||Ze!=null))switch(oe){case"children":case"dangerouslySetInnerHTML":if(ze!=null)throw Error(s+" is a void element tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");break;default:ir(i,s,oe,ze,v,Ze)}return;default:if(vf(s)){for(var Vr in c)ze=c[Vr],c.hasOwnProperty(Vr)&&ze!==void 0&&!v.hasOwnProperty(Vr)&&wc(i,s,Vr,void 0,v,ze);for(Ue in v)ze=v[Ue],Ze=c[Ue],!v.hasOwnProperty(Ue)||ze===Ze||ze===void 0&&Ze===void 0||wc(i,s,Ue,ze,v,Ze);return}}for(var Gn in c)ze=c[Gn],c.hasOwnProperty(Gn)&&ze!=null&&!v.hasOwnProperty(Gn)&&ir(i,s,Gn,null,v,ze);for(qe in v)ze=v[qe],Ze=c[qe],!v.hasOwnProperty(qe)||ze===Ze||ze==null&&Ze==null||ir(i,s,qe,ze,v,Ze)}function Mh(i){switch(i){case"class":return"className";case"for":return"htmlFor";default:return i}}function Wv(i){var s={};i=i.style;for(var c=0;c<i.length;c++){var v=i[c];s[v]=i.getPropertyValue(v)}return s}function F0(i,s,c){if(s!=null&&typeof s!="object")console.error("The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + 'em'}} when using JSX.");else{var v,S=v="",C;for(C in s)if(s.hasOwnProperty(C)){var $=s[C];$!=null&&typeof $!="boolean"&&$!==""&&(C.indexOf("--")===0?(fe($,C),v+=S+C+":"+(""+$).trim()):typeof $!="number"||$===0||X_.has(C)?(fe($,C),v+=S+C.replace(Mu,"-$1").toLowerCase().replace(Zh,"-ms-")+":"+(""+$).trim()):v+=S+C.replace(Mu,"-$1").toLowerCase().replace(Zh,"-ms-")+":"+$+"px",S=";")}v=v||null,s=i.getAttribute("style"),s!==v&&(v=Su(v),Su(s)!==v&&(c.style=Wv(i)))}}function qa(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null)switch(typeof v){case"undefined":case"function":case"symbol":case"boolean":return}else if(v!=null)switch(typeof v){case"function":case"symbol":case"boolean":break;default:if(U(v,s),i===""+v)return}qr(s,i,v,C)}function l4(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null){switch(typeof v){case"function":case"symbol":return}if(!v)return}else switch(typeof v){case"function":case"symbol":break;default:if(v)return}qr(s,i,v,C)}function y_(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null)switch(typeof v){case"undefined":case"function":case"symbol":return}else if(v!=null)switch(typeof v){case"function":case"symbol":break;default:if(U(v,c),i===""+v)return}qr(s,i,v,C)}function vr(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null)switch(typeof v){case"undefined":case"function":case"symbol":case"boolean":return;default:if(isNaN(v))return}else if(v!=null)switch(typeof v){case"function":case"symbol":case"boolean":break;default:if(!isNaN(v)&&(U(v,s),i===""+v))return}qr(s,i,v,C)}function kr(i,s,c,v,S,C){if(S.delete(c),i=i.getAttribute(c),i===null)switch(typeof v){case"undefined":case"function":case"symbol":case"boolean":return}else if(v!=null)switch(typeof v){case"function":case"symbol":case"boolean":break;default:if(U(v,s),c=iu(""+v),i===c)return}qr(s,i,v,C)}function Nn(i,s,c,v){for(var S={},C=new Set,$=i.attributes,F=0;F<$.length;F++)switch($[F].name.toLowerCase()){case"value":break;case"checked":break;case"selected":break;default:C.add($[F].name)}if(vf(s)){for(var X in c)if(c.hasOwnProperty(X)){var oe=c[X];if(oe!=null){if(tl.hasOwnProperty(X))typeof oe!="function"&&bs(X,oe);else if(c.suppressHydrationWarning!==!0)switch(X){case"children":typeof oe!="string"&&typeof oe!="number"||qr("children",i.textContent,oe,S);continue;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":continue;case"dangerouslySetInnerHTML":$=i.innerHTML,oe=oe?oe.__html:void 0,oe!=null&&(oe=Ws(i,oe),qr(X,$,oe,S));continue;case"style":C.delete(X),F0(i,oe,S);continue;case"offsetParent":case"offsetTop":case"offsetLeft":case"offsetWidth":case"offsetHeight":case"isContentEditable":case"outerText":case"outerHTML":C.delete(X.toLowerCase()),console.error("Assignment to read-only property will result in a no-op: `%s`",X);continue;case"className":C.delete("class"),$=Ht(i,"class",oe),qr("className",$,oe,S);continue;default:v.context===ad&&s!=="svg"&&s!=="math"?C.delete(X.toLowerCase()):C.delete(X),$=Ht(i,X,oe),qr(X,$,oe,S)}}}}else for(oe in c)if(c.hasOwnProperty(oe)&&(X=c[oe],X!=null)){if(tl.hasOwnProperty(oe))typeof X!="function"&&bs(oe,X);else if(c.suppressHydrationWarning!==!0)switch(oe){case"children":typeof X!="string"&&typeof X!="number"||qr("children",i.textContent,X,S);continue;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"value":case"checked":case"selected":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":continue;case"dangerouslySetInnerHTML":$=i.innerHTML,X=X?X.__html:void 0,X!=null&&(X=Ws(i,X),$!==X&&(S[oe]={__html:$}));continue;case"className":qa(i,oe,"class",X,C,S);continue;case"tabIndex":qa(i,oe,"tabindex",X,C,S);continue;case"style":C.delete(oe),F0(i,X,S);continue;case"multiple":C.delete(oe),qr(oe,i.multiple,X,S);continue;case"muted":C.delete(oe),qr(oe,i.muted,X,S);continue;case"autoFocus":C.delete("autofocus"),qr(oe,i.autofocus,X,S);continue;case"data":if(s!=="object"){C.delete(oe),$=i.getAttribute("data"),qr(oe,$,X,S);continue}case"src":case"href":if(!(X!==""||s==="a"&&oe==="href"||s==="object"&&oe==="data")){console.error(oe==="src"?'An empty string ("") was passed to the %s attribute. This may cause the browser to download the whole page again over the network. To fix this, either do not render the element at all or pass null to %s instead of an empty string.':'An empty string ("") was passed to the %s attribute. To fix this, either do not render the element at all or pass null to %s instead of an empty string.',oe,oe);continue}kr(i,oe,oe,X,C,S);continue;case"action":case"formAction":if($=i.getAttribute(oe),typeof X=="function"){C.delete(oe.toLowerCase()),oe==="formAction"?(C.delete("name"),C.delete("formenctype"),C.delete("formmethod"),C.delete("formtarget")):(C.delete("enctype"),C.delete("method"),C.delete("target"));continue}else if($===Sye){C.delete(oe.toLowerCase()),qr(oe,"function",X,S);continue}kr(i,oe,oe.toLowerCase(),X,C,S);continue;case"xlinkHref":kr(i,oe,"xlink:href",X,C,S);continue;case"contentEditable":y_(i,oe,"contenteditable",X,C,S);continue;case"spellCheck":y_(i,oe,"spellcheck",X,C,S);continue;case"draggable":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":y_(i,oe,oe,X,C,S);continue;case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":l4(i,oe,oe.toLowerCase(),X,C,S);continue;case"capture":case"download":e:{F=i;var Ue=$=oe,qe=S;if(C.delete(Ue),F=F.getAttribute(Ue),F===null)switch(typeof X){case"undefined":case"function":case"symbol":break e;default:if(X===!1)break e}else if(X!=null)switch(typeof X){case"function":case"symbol":break;case"boolean":if(X===!0&&F==="")break e;break;default:if(U(X,$),F===""+X)break e}qr($,F,X,qe)}continue;case"cols":case"rows":case"size":case"span":e:{if(F=i,Ue=$=oe,qe=S,C.delete(Ue),F=F.getAttribute(Ue),F===null)switch(typeof X){case"undefined":case"function":case"symbol":case"boolean":break e;default:if(isNaN(X)||1>X)break e}else if(X!=null)switch(typeof X){case"function":case"symbol":case"boolean":break;default:if(!(isNaN(X)||1>X)&&(U(X,$),F===""+X))break e}qr($,F,X,qe)}continue;case"rowSpan":vr(i,oe,"rowspan",X,C,S);continue;case"start":vr(i,oe,oe,X,C,S);continue;case"xHeight":qa(i,oe,"x-height",X,C,S);continue;case"xlinkActuate":qa(i,oe,"xlink:actuate",X,C,S);continue;case"xlinkArcrole":qa(i,oe,"xlink:arcrole",X,C,S);continue;case"xlinkRole":qa(i,oe,"xlink:role",X,C,S);continue;case"xlinkShow":qa(i,oe,"xlink:show",X,C,S);continue;case"xlinkTitle":qa(i,oe,"xlink:title",X,C,S);continue;case"xlinkType":qa(i,oe,"xlink:type",X,C,S);continue;case"xmlBase":qa(i,oe,"xml:base",X,C,S);continue;case"xmlLang":qa(i,oe,"xml:lang",X,C,S);continue;case"xmlSpace":qa(i,oe,"xml:space",X,C,S);continue;case"inert":X!==""||o3[oe]||(o3[oe]=!0,console.error("Received an empty string for a boolean attribute `%s`. This will treat the attribute as if it were false. Either pass `false` to silence this warning, or pass `true` if you used an empty string in earlier versions of React to indicate this attribute is true.",oe)),l4(i,oe,oe,X,C,S);continue;default:if(!(2<oe.length)||oe[0]!=="o"&&oe[0]!=="O"||oe[1]!=="n"&&oe[1]!=="N"){F=yf(oe),$=!1,v.context===ad&&s!=="svg"&&s!=="math"?C.delete(F.toLowerCase()):(Ue=oe.toLowerCase(),Ue=sg.hasOwnProperty(Ue)&&sg[Ue]||null,Ue!==null&&Ue!==oe&&($=!0,C.delete(Ue)),C.delete(F));e:if(Ue=i,qe=F,F=X,Pt(qe))if(Ue.hasAttribute(qe))Ue=Ue.getAttribute(qe),U(F,qe),F=Ue===""+F?F:Ue;else{switch(typeof F){case"function":case"symbol":break e;case"boolean":if(Ue=qe.toLowerCase().slice(0,5),Ue!=="data-"&&Ue!=="aria-")break e}F=F===void 0?void 0:null}else F=void 0;$||qr(oe,F,X,S)}}}return 0<C.size&&c.suppressHydrationWarning!==!0&&v_(i,C,S),Object.keys(S).length===0?null:S}function Kn(i,s){switch(i.length){case 0:return"";case 1:return i[0];case 2:return i[0]+" "+s+" "+i[1];default:return i.slice(0,-1).join(", ")+", "+s+" "+i[i.length-1]}}function or(i){return i.nodeType===9?i:i.ownerDocument}function Ea(i){switch(i){case Iu:return i1;case Ty:return l3;default:return ad}}function wu(i,s){if(i===ad)switch(s){case"svg":return i1;case"math":return l3;default:return ad}return i===i1&&s==="foreignObject"?ad:i}function Cc(i,s){return i==="textarea"||i==="noscript"||typeof s.children=="string"||typeof s.children=="number"||typeof s.children=="bigint"||typeof s.dangerouslySetInnerHTML=="object"&&s.dangerouslySetInnerHTML!==null&&s.dangerouslySetInnerHTML.__html!=null}function x_(){var i=window.event;return i&&i.type==="popstate"?i===x5?!1:(x5=i,!0):(x5=null,!1)}function Cu(i){setTimeout(function(){throw i})}function vi(i,s,c){switch(s){case"button":case"input":case"select":case"textarea":c.autoFocus&&i.focus();break;case"img":c.src?i.src=c.src:c.srcSet&&(i.srcset=c.srcSet)}}function Ec(i,s,c,v){s4(i,s,c,v),i[Ra]=v}function Ac(i){Qp(i,"")}function b_(i,s,c){i.nodeValue=c}function qi(i){return i==="head"}function Ih(i,s){i.removeChild(s)}function U0(i,s){(i.nodeType===9?i.body:i.nodeName==="HTML"?i.ownerDocument.body:i).removeChild(s)}function Yo(i,s){var c=s,v=0,S=0;do{var C=c.nextSibling;if(i.removeChild(c),C&&C.nodeType===8)if(c=C.data,c===s3){if(0<v&&8>v){c=v;var $=i.ownerDocument;if(c&Cye&&Lh($.documentElement),c&Eye&&Lh($.body),c&Aye)for(c=$.head,Lh(c),$=c.firstChild;$;){var F=$.nextSibling,X=$.nodeName;$[J0]||X==="SCRIPT"||X==="STYLE"||X==="LINK"&&$.rel.toLowerCase()==="stylesheet"||c.removeChild($),$=F}}if(S===0){i.removeChild(C),jh(s);return}S--}else c===a3||c===od||c===kS?S++:v=c.charCodeAt(0)-48;else v=0;c=C}while(c);jh(s)}function __(i){i=i.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none"}function S_(i){i.nodeValue=""}function Xv(i,s){s=s[kye],s=s!=null&&s.hasOwnProperty("display")?s.display:null,i.style.display=s==null||typeof s=="boolean"?"":(""+s).trim()}function Jv(i,s){i.nodeValue=s}function El(i){var s=i.firstChild;for(s&&s.nodeType===10&&(s=s.nextSibling);s;){var c=s;switch(s=s.nextSibling,c.nodeName){case"HTML":case"HEAD":case"BODY":El(c),gn(c);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(c.rel.toLowerCase()==="stylesheet")continue}i.removeChild(c)}}function yo(i,s,c,v){for(;i.nodeType===1;){var S=c;if(i.nodeName.toLowerCase()!==s.toLowerCase()){if(!v&&(i.nodeName!=="INPUT"||i.type!=="hidden"))break}else if(v){if(!i[J0])switch(s){case"meta":if(!i.hasAttribute("itemprop"))break;return i;case"link":if(C=i.getAttribute("rel"),C==="stylesheet"&&i.hasAttribute("data-precedence"))break;if(C!==S.rel||i.getAttribute("href")!==(S.href==null||S.href===""?null:S.href)||i.getAttribute("crossorigin")!==(S.crossOrigin==null?null:S.crossOrigin)||i.getAttribute("title")!==(S.title==null?null:S.title))break;return i;case"style":if(i.hasAttribute("data-precedence"))break;return i;case"script":if(C=i.getAttribute("src"),(C!==(S.src==null?null:S.src)||i.getAttribute("type")!==(S.type==null?null:S.type)||i.getAttribute("crossorigin")!==(S.crossOrigin==null?null:S.crossOrigin))&&C&&i.hasAttribute("async")&&!i.hasAttribute("itemprop"))break;return i;default:return i}}else if(s==="input"&&i.type==="hidden"){U(S.name,"name");var C=S.name==null?null:""+S.name;if(S.type==="hidden"&&i.getAttribute("name")===C)return i}else return i;if(i=Aa(i.nextSibling),i===null)break}return null}function kc(i,s,c){if(s==="")return null;for(;i.nodeType!==3;)if((i.nodeType!==1||i.nodeName!=="INPUT"||i.type!=="hidden")&&!c||(i=Aa(i.nextSibling),i===null))return null;return i}function Tc(i){return i.data===kS||i.data===od&&i.ownerDocument.readyState===KG}function $h(i,s){var c=i.ownerDocument;if(i.data!==od||c.readyState===KG)s();else{var v=function(){s(),c.removeEventListener("DOMContentLoaded",v)};c.addEventListener("DOMContentLoaded",v),i._reactRetry=v}}function Aa(i){for(;i!=null;i=i.nextSibling){var s=i.nodeType;if(s===1||s===3)break;if(s===8){if(s=i.data,s===a3||s===kS||s===od||s===m5||s===QG)break;if(s===s3)return null}}return i}function ey(i){if(i.nodeType===1){for(var s=i.nodeName.toLowerCase(),c={},v=i.attributes,S=0;S<v.length;S++){var C=v[S];c[Mh(C.name)]=C.name.toLowerCase()==="style"?Wv(i):C.value}return{type:s,props:c}}return i.nodeType===8?{type:"Suspense",props:{}}:i.nodeValue}function w_(i,s,c){return c===null||c[wye]!==!0?(i.nodeValue===s?i=null:(s=Su(s),i=Su(i.nodeValue)===s?null:i.nodeValue),i):null}function Bh(i){i=i.nextSibling;for(var s=0;i;){if(i.nodeType===8){var c=i.data;if(c===s3){if(s===0)return Aa(i.nextSibling);s--}else c!==a3&&c!==kS&&c!==od||s++}i=i.nextSibling}return null}function ty(i){i=i.previousSibling;for(var s=0;i;){if(i.nodeType===8){var c=i.data;if(c===a3||c===kS||c===od){if(s===0)return i;s--}else c===s3&&s++}i=i.previousSibling}return null}function Ga(i){jh(i)}function u4(i){jh(i)}function ka(i,s,c,v,S){switch(S&&Qm(i,v.ancestorInfo),s=or(c),i){case"html":if(i=s.documentElement,!i)throw Error("React expected an <html> element (document.documentElement) to exist in the Document but one was not found. React never removes the documentElement for any Document it renders into so the cause is likely in some other script running on this page.");return i;case"head":if(i=s.head,!i)throw Error("React expected a <head> element (document.head) to exist in the Document but one was not found. React never removes the head for any Document it renders into so the cause is likely in some other script running on this page.");return i;case"body":if(i=s.body,!i)throw Error("React expected a <body> element (document.body) to exist in the Document but one was not found. React never removes the body for any Document it renders into so the cause is likely in some other script running on this page.");return i;default:throw Error("resolveSingletonInstance was called with an element type that is not supported. This is a bug in React.")}}function c4(i,s,c,v){if(!c[Bc]&&Kt(c)){var S=c.tagName.toLowerCase();console.error("You are mounting a new %s component when a previous one has not first unmounted. It is an error to render more than one %s component at a time and attributes and children of these components will likely fail in unpredictable ways. Please only render a single instance of <%s> and if you need to mount a new one, ensure any previous ones have unmounted first.",S,S,S)}switch(i){case"html":case"head":case"body":break;default:console.error("acquireSingletonInstance was called with an element type that is not supported. This is a bug in React.")}for(S=c.attributes;S.length;)c.removeAttributeNode(S[0]);io(c,i,s),c[$o]=v,c[Ra]=s}function Lh(i){for(var s=i.attributes;s.length;)i.removeAttributeNode(s[0]);gn(i)}function ny(i){return typeof i.getRootNode=="function"?i.getRootNode():i.nodeType===9?i:i.ownerDocument}function Eu(i,s,c){var v=o1;if(v&&typeof s=="string"&&s){var S=pr(s);S='link[rel="'+i+'"][href="'+S+'"]',typeof c=="string"&&(S+='[crossorigin="'+c+'"]'),nV.has(S)||(nV.add(S),i={rel:i,crossOrigin:c,href:s},v.querySelector(S)===null&&(s=v.createElement("link"),io(s,"link",i),xe(s),v.head.appendChild(s)))}}function j0(i,s,c,v){var S=(S=kl.current)?ny(S):null;if(!S)throw Error('"resourceRoot" was expected to exist. This is a bug in React.');switch(i){case"meta":case"title":return null;case"style":return typeof c.precedence=="string"&&typeof c.href=="string"?(c=Xs(c.href),s=Y(S).hoistableStyles,v=s.get(c),v||(v={type:"style",instance:null,count:0,state:null},s.set(c,v)),v):{type:"void",instance:null,count:0,state:null};case"link":if(c.rel==="stylesheet"&&typeof c.href=="string"&&typeof c.precedence=="string"){i=Xs(c.href);var C=Y(S).hoistableStyles,$=C.get(i);if(!$&&(S=S.ownerDocument||S,$={type:"stylesheet",instance:null,count:0,state:{loading:Eg,preload:null}},C.set(i,$),(C=S.querySelector(zh(i)))&&!C._p&&($.instance=C,$.state.loading=TS|Hl),!ql.has(i))){var F={rel:"preload",as:"style",href:c.href,crossOrigin:c.crossOrigin,integrity:c.integrity,media:c.media,hrefLang:c.hrefLang,referrerPolicy:c.referrerPolicy};ql.set(i,F),C||f4(S,i,F,$.state)}if(s&&v===null)throw c=`
245
245
 
246
246
  - `+Nh(s)+`
247
247
  + `+Nh(c),Error("Expected <link> not to update to be updated to a stylesheet with precedence. Check the `rel`, `href`, and `precedence` props of this component. Alternatively, check whether two different <link> components render in the same slot or share the same key."+c);return $}if(s&&v!==null)throw c=`
@@ -476,7 +476,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
476
476
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var I,L=!0,N=!1;return{s:function(){E=E.call(k)},n:function(){var V=E.next();return L=V.done,V},e:function(V){N=!0,I=V},f:function(){try{L||E.return==null||E.return()}finally{if(N)throw I}}}}function p(k,A){if(k){if(typeof k=="string")return y(k,A);var E={}.toString.call(k).slice(8,-1);return E==="Object"&&k.constructor&&(E=k.constructor.name),E==="Map"||E==="Set"?Array.from(k):E==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(E)?y(k,A):void 0}}function y(k,A){(A==null||A>k.length)&&(A=k.length);for(var E=0,R=Array(A);E<A;E++)R[E]=k[E];return R}var m={format:"YYYY/MM/DD",delimiters:["/","-"],strictMode:!1};function x(k){return/(^(y{4}|y{2})[.\/-](m{1,2})[.\/-](d{1,2})$)|(^(m{1,2})[.\/-](d{1,2})[.\/-]((y{4}|y{2})$))|(^(d{1,2})[.\/-](m{1,2})[.\/-]((y{4}|y{2})$))/gi.test(k)}function _(k,A){for(var E=[],R=Math.max(k.length,A.length),O=0;O<R;O++)E.push([k[O],A[O]]);return E}function w(k,A){if(typeof A=="string"?A=(0,n.default)({format:A},m):A=(0,n.default)(A,m),typeof k=="string"&&x(A.format)){if(A.strictMode&&k.length!==A.format.length)return!1;var E=A.delimiters.find(function(de){return A.format.indexOf(de)!==-1}),R=A.strictMode?E:A.delimiters.find(function(de){return k.indexOf(de)!==-1}),O=_(k.split(R),A.format.toLowerCase().split(E)),I={},L=h(O),N;try{for(L.s();!(N=L.n()).done;){var H=o(N.value,2),V=H[0],W=H[1];if(!V||!W||V.length!==W.length)return!1;I[W.charAt(0)]=V}}catch(de){L.e(de)}finally{L.f()}var z=I.y;if(z.startsWith("-"))return!1;if(I.y.length===2){var Q=parseInt(I.y,10);if(isNaN(Q))return!1;var J=new Date().getFullYear()%100;Q<J?z="20".concat(I.y):z="19".concat(I.y)}var ie=I.m;I.m.length===1&&(ie="0".concat(I.m));var ee=I.d;return I.d.length===1&&(ee="0".concat(I.d)),new Date("".concat(z,"-").concat(ie,"-").concat(ee,"T00:00:00.000Z")).getUTCDate()===+I.d}return A.strictMode?!1:Object.prototype.toString.call(k)==="[object Date]"&&isFinite(k)}e.exports=t.default,e.exports.default=t.default}(FE,FE.exports)),FE.exports}var UE={exports:{}},SF;function Kle(){return SF||(SF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=r(Na());function r(d){return d&&d.__esModule?d:{default:d}}var o={hourFormat:"hour24",mode:"default"},a={hour24:{default:/^([01]?[0-9]|2[0-3]):([0-5][0-9])$/,withSeconds:/^([01]?[0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9])$/},hour12:{default:/^(0?[1-9]|1[0-2]):([0-5][0-9]) (A|P)M$/,withSeconds:/^(0?[1-9]|1[0-2]):([0-5][0-9]):([0-5][0-9]) (A|P)M$/}};function l(d,h){return h=(0,n.default)(h,o),typeof d!="string"?!1:a[h.hourFormat][h.mode].test(d)}e.exports=t.default,e.exports.default=t.default}(UE,UE.exports)),UE.exports}var jE={exports:{}},wF;function Wle(){return wF||(wF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=r(gt());function r(h){return h&&h.__esModule?h:{default:h}}var o={loose:!1},a=["true","false","1","0"],l=[].concat(a,["yes","no"]);function d(h){var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:o;return(0,n.default)(h),p.loose?l.includes(h.toLowerCase()):a.includes(h)}e.exports=t.default,e.exports.default=t.default}(jE,jE.exports)),jE.exports}var PE={exports:{}},CF;function Xle(){return CF||(CF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=R;var n=r(gt());function r(O){return O&&O.__esModule?O:{default:O}}var o="([A-Za-z]{3}(-[A-Za-z]{3}){0,2})",a="(([a-zA-Z]{2,3}(-".concat(o,")?)|([a-zA-Z]{5,8}))"),l="([A-Za-z]{4})",d="([A-Za-z]{2}|\\d{3})",h="([A-Za-z0-9]{5,8}|(\\d[A-Z-a-z0-9]{3}))",p="(\\d|[A-W]|[Y-Z]|[a-w]|[y-z])",y="(".concat(p,"(-[A-Za-z0-9]{2,8})+)"),m="(x(-[A-Za-z0-9]{1,8})+)",x="((en-GB-oed)|(i-ami)|(i-bnn)|(i-default)|(i-enochian)|(i-hak)|(i-klingon)|(i-lux)|(i-mingo)|(i-navajo)|(i-pwn)|(i-tao)|(i-tay)|(i-tsu)|(sgn-BE-FR)|(sgn-BE-NL)|(sgn-CH-DE))",_="((art-lojban)|(cel-gaulish)|(no-bok)|(no-nyn)|(zh-guoyu)|(zh-hakka)|(zh-min)|(zh-min-nan)|(zh-xiang))",w="(".concat(x,"|").concat(_,")"),k="(-|_)",A="".concat(a,"(").concat(k).concat(l,")?(").concat(k).concat(d,")?(").concat(k).concat(h,")*(").concat(k).concat(y,")*(").concat(k).concat(m,")?"),E=new RegExp("(^".concat(m,"$)|(^").concat(w,"$)|(^").concat(A,"$)"));function R(O){return(0,n.default)(O),E.test(O)}e.exports=t.default,e.exports.default=t.default}(PE,PE.exports)),PE.exports}var HE={exports:{}},EF;function Jle(){return EF||(EF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^(?!(1[3-9])|(20)|(3[3-9])|(4[0-9])|(5[0-9])|(60)|(7[3-9])|(8[1-9])|(9[0-2])|(9[3-9]))[0-9]{9}$/;function a(l){if((0,n.default)(l),!o.test(l))return!1;for(var d=0,h=0;h<l.length;h++)h%3===0?d+=l[h]*3:h%3===1?d+=l[h]*7:d+=l[h]*1;return d%10===0}e.exports=t.default,e.exports.default=t.default}(HE,HE.exports)),HE.exports}var Em={},AF;function eue(){if(AF)return Em;AF=1,Object.defineProperty(Em,"__esModule",{value:!0}),Em.default=r,Em.locales=void 0;var e=n(gt()),t=Ex();function n(o){return o&&o.__esModule?o:{default:o}}function r(o){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"en-US",l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};(0,e.default)(o);var d=o,h=l.ignore;if(h)if(h instanceof RegExp)d=d.replace(h,"");else if(typeof h=="string")d=d.replace(new RegExp("[".concat(h.replace(/[-[\]{}()*+?.,\\^$|#\\s]/g,"\\$&"),"]"),"g"),"");else throw new Error("ignore should be instance of a String or RegExp");if(a in t.alpha)return t.alpha[a].test(d);throw new Error("Invalid locale '".concat(a,"'"))}return Em.locales=Object.keys(t.alpha),Em}var Am={},kF;function tue(){if(kF)return Am;kF=1,Object.defineProperty(Am,"__esModule",{value:!0}),Am.default=r,Am.locales=void 0;var e=n(gt()),t=Ex();function n(o){return o&&o.__esModule?o:{default:o}}function r(o){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"en-US",l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};(0,e.default)(o);var d=o,h=l.ignore;if(h)if(h instanceof RegExp)d=d.replace(h,"");else if(typeof h=="string")d=d.replace(new RegExp("[".concat(h.replace(/[-[\]{}()*+?.,\\^$|#\\s]/g,"\\$&"),"]"),"g"),"");else throw new Error("ignore should be instance of a String or RegExp");if(a in t.alphanumeric)return t.alphanumeric[a].test(d);throw new Error("Invalid locale '".concat(a,"'"))}return Am.locales=Object.keys(t.alphanumeric),Am}var qE={exports:{}},TF;function nue(){return TF||(TF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=o(gt()),r=Ex();function o(d){return d&&d.__esModule?d:{default:d}}var a=/^[0-9]+$/;function l(d,h){return(0,n.default)(d),h&&h.no_symbols?a.test(d):new RegExp("^[+-]?([0-9]*[".concat((h||{}).locale?r.decimal[h.locale]:".","])?[0-9]+$")).test(d)}e.exports=t.default,e.exports.default=t.default}(qE,qE.exports)),qE.exports}var km={},RF;function rue(){if(RF)return km;RF=1,Object.defineProperty(km,"__esModule",{value:!0}),km.default=r,km.locales=void 0;var e=t(gt());function t(o){return o&&o.__esModule?o:{default:o}}var n={AM:/^[A-Z]{2}\d{7}$/,AR:/^[A-Z]{3}\d{6}$/,AT:/^[A-Z]\d{7}$/,AU:/^[A-Z]\d{7}$/,AZ:/^[A-Z]{1}\d{8}$/,BE:/^[A-Z]{2}\d{6}$/,BG:/^\d{9}$/,BR:/^[A-Z]{2}\d{6}$/,BY:/^[A-Z]{2}\d{7}$/,CA:/^[A-Z]{2}\d{6}$/,CH:/^[A-Z]\d{7}$/,CN:/^G\d{8}$|^E(?![IO])[A-Z0-9]\d{7}$/,CY:/^[A-Z](\d{6}|\d{8})$/,CZ:/^\d{8}$/,DE:/^[CFGHJKLMNPRTVWXYZ0-9]{9}$/,DK:/^\d{9}$/,DZ:/^\d{9}$/,EE:/^([A-Z]\d{7}|[A-Z]{2}\d{7})$/,ES:/^[A-Z0-9]{2}([A-Z0-9]?)\d{6}$/,FI:/^[A-Z]{2}\d{7}$/,FR:/^\d{2}[A-Z]{2}\d{5}$/,GB:/^\d{9}$/,GR:/^[A-Z]{2}\d{7}$/,HR:/^\d{9}$/,HU:/^[A-Z]{2}(\d{6}|\d{7})$/,IE:/^[A-Z0-9]{2}\d{7}$/,IN:/^[A-Z]{1}-?\d{7}$/,ID:/^[A-C]\d{7}$/,IR:/^[A-Z]\d{8}$/,IS:/^(A)\d{7}$/,IT:/^[A-Z0-9]{2}\d{7}$/,JM:/^[Aa]\d{7}$/,JP:/^[A-Z]{2}\d{7}$/,KR:/^[MS]\d{8}$/,KZ:/^[a-zA-Z]\d{7}$/,LI:/^[a-zA-Z]\d{5}$/,LT:/^[A-Z0-9]{8}$/,LU:/^[A-Z0-9]{8}$/,LV:/^[A-Z0-9]{2}\d{7}$/,LY:/^[A-Z0-9]{8}$/,MT:/^\d{7}$/,MZ:/^([A-Z]{2}\d{7})|(\d{2}[A-Z]{2}\d{5})$/,MY:/^[AHK]\d{8}$/,MX:/^\d{10,11}$/,NL:/^[A-Z]{2}[A-Z0-9]{6}\d$/,NZ:/^([Ll]([Aa]|[Dd]|[Ff]|[Hh])|[Ee]([Aa]|[Pp])|[Nn])\d{6}$/,PH:/^([A-Z](\d{6}|\d{7}[A-Z]))|([A-Z]{2}(\d{6}|\d{7}))$/,PK:/^[A-Z]{2}\d{7}$/,PL:/^[A-Z]{2}\d{7}$/,PT:/^[A-Z]\d{6}$/,RO:/^\d{8,9}$/,RU:/^\d{9}$/,SE:/^\d{8}$/,SL:/^(P)[A-Z]\d{7}$/,SK:/^[0-9A-Z]\d{7}$/,TH:/^[A-Z]{1,2}\d{6,7}$/,TR:/^[A-Z]\d{8}$/,UA:/^[A-Z]{2}\d{6}$/,US:/^\d{9}$/,ZA:/^[TAMD]\d{8}$/};km.locales=Object.keys(n);function r(o,a){(0,e.default)(o);var l=o.replace(/\s/g,"").toUpperCase();return a.toUpperCase()in n&&n[a].test(l)}return km}var GE={exports:{}},VE={exports:{}},OF;function ZD(){return OF||(OF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=o(gt()),r=o(Qz());function o(h){return h&&h.__esModule?h:{default:h}}var a=/^(?:[-+]?(?:0|[1-9][0-9]*))$/,l=/^[-+]?[0-9]+$/;function d(h,p){(0,n.default)(h),p=p||{};var y=p.allow_leading_zeroes===!1?a:l,m=!p.hasOwnProperty("min")||(0,r.default)(p.min)||h>=p.min,x=!p.hasOwnProperty("max")||(0,r.default)(p.max)||h<=p.max,_=!p.hasOwnProperty("lt")||(0,r.default)(p.lt)||h<p.lt,w=!p.hasOwnProperty("gt")||(0,r.default)(p.gt)||h>p.gt;return y.test(h)&&m&&x&&_&&w}e.exports=t.default,e.exports.default=t.default}(VE,VE.exports)),VE.exports}var DF;function iue(){return DF||(DF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(ZD());function r(a){return a&&a.__esModule?a:{default:a}}function o(a){return(0,n.default)(a,{allow_leading_zeroes:!1,min:0,max:65535})}e.exports=t.default,e.exports.default=t.default}(GE,GE.exports)),GE.exports}var YE={exports:{}},MF;function oue(){return MF||(MF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a){return(0,n.default)(a),a===a.toLowerCase()}e.exports=t.default,e.exports.default=t.default}(YE,YE.exports)),YE.exports}var ZE={exports:{}},IF;function aue(){return IF||(IF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a){return(0,n.default)(a),a===a.toUpperCase()}e.exports=t.default,e.exports.default=t.default}(ZE,ZE.exports)),ZE.exports}var QE={exports:{}},$F;function sue(){return $F||($F=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=r(gt());function r(d){return d&&d.__esModule?d:{default:d}}var o=/^[0-9]{15}$/,a=/^\d{2}-\d{6}-\d{6}-\d{1}$/;function l(d,h){(0,n.default)(d),h=h||{};var p=o;if(h.allow_hyphens&&(p=a),!p.test(d))return!1;d=d.replace(/-/g,"");for(var y=0,m=2,x=14,_=0;_<x;_++){var w=d.substring(x-_-1,x-_),k=parseInt(w,10)*m;k>=10?y+=k%10+1:y+=k,m===1?m+=1:m-=1}var A=(10-y%10)%10;return A===parseInt(d.substring(14,15),10)}e.exports=t.default,e.exports.default=t.default}(QE,QE.exports)),QE.exports}var KE={exports:{}},BF;function lue(){return BF||(BF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^[\x00-\x7F]+$/;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(KE,KE.exports)),KE.exports}var Tm={},LF;function NF(){if(LF)return Tm;LF=1,Object.defineProperty(Tm,"__esModule",{value:!0}),Tm.default=r,Tm.fullWidth=void 0;var e=t(gt());function t(o){return o&&o.__esModule?o:{default:o}}var n=Tm.fullWidth=/[^\u0020-\u007E\uFF61-\uFF9F\uFFA0-\uFFDC\uFFE8-\uFFEE0-9a-zA-Z]/;function r(o){return(0,e.default)(o),n.test(o)}return Tm}var Rm={},zF;function FF(){if(zF)return Rm;zF=1,Object.defineProperty(Rm,"__esModule",{value:!0}),Rm.default=r,Rm.halfWidth=void 0;var e=t(gt());function t(o){return o&&o.__esModule?o:{default:o}}var n=Rm.halfWidth=/[\u0020-\u007E\uFF61-\uFF9F\uFFA0-\uFFDC\uFFE8-\uFFEE0-9a-zA-Z]/;function r(o){return(0,e.default)(o),n.test(o)}return Rm}var WE={exports:{}},UF;function uue(){return UF||(UF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=a(gt()),r=NF(),o=FF();function a(d){return d&&d.__esModule?d:{default:d}}function l(d){return(0,n.default)(d),r.fullWidth.test(d)&&o.halfWidth.test(d)}e.exports=t.default,e.exports.default=t.default}(WE,WE.exports)),WE.exports}var XE={exports:{}},jF;function cue(){return jF||(jF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/[^\x00-\x7F]/;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(XE,XE.exports)),XE.exports}var JE={exports:{}},eA={exports:{}},PF;function fue(){return PF||(PF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function n(r,o){var a=r.join("");return new RegExp(a,o)}e.exports=t.default,e.exports.default=t.default}(eA,eA.exports)),eA.exports}var HF;function due(){return HF||(HF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=o(gt()),r=o(fue());function o(d){return d&&d.__esModule?d:{default:d}}var a=(0,r.default)(["^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)","(?:-((?:0|[1-9]\\d*|\\d*[a-z-][0-9a-z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-z-][0-9a-z-]*))*))","?(?:\\+([0-9a-z-]+(?:\\.[0-9a-z-]+)*))?$"],"i");function l(d){return(0,n.default)(d),a.test(d)}e.exports=t.default,e.exports.default=t.default}(JE,JE.exports)),JE.exports}var tA={exports:{}},qF;function hue(){return qF||(qF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/[\uD800-\uDBFF][\uDC00-\uDFFF]/;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(tA,tA.exports)),tA.exports}var nA={exports:{}},rA={exports:{}},GF;function pue(){return GF||(GF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=function(o,a){return o.some(function(l){return a===l})};t.default=n,e.exports=t.default,e.exports.default=t.default}(rA,rA.exports)),rA.exports}var VF;function gue(){return VF||(VF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=y;var n=l(Na()),r=l(gt()),o=l(pue()),a=Ex();function l(m){return m&&m.__esModule?m:{default:m}}function d(m){var x=new RegExp("^[-+]?([0-9]+)?(\\".concat(a.decimal[m.locale],"[0-9]{").concat(m.decimal_digits,"})").concat(m.force_decimal?"":"?","$"));return x}var h={force_decimal:!1,decimal_digits:"1,",locale:"en-US"},p=["","-","+"];function y(m,x){if((0,r.default)(m),x=(0,n.default)(x,h),x.locale in a.decimal)return!(0,o.default)(p,m.replace(/ /g,""))&&d(x).test(m);throw new Error("Invalid locale '".concat(x.locale,"'"))}e.exports=t.default,e.exports.default=t.default}(nA,nA.exports)),nA.exports}var iA={exports:{}},YF;function ZF(){return YF||(YF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^(0x|0h)?[0-9A-F]+$/i;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(iA,iA.exports)),iA.exports}var oA={exports:{}},QF;function mue(){return QF||(QF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^(0o)?[0-7]+$/i;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(oA,oA.exports)),oA.exports}var aA={exports:{}},KF;function vue(){return KF||(KF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=o(gt()),r=o(eF());function o(l){return l&&l.__esModule?l:{default:l}}function a(l,d){return(0,n.default)(l),(0,r.default)(l)%parseInt(d,10)===0}e.exports=t.default,e.exports.default=t.default}(aA,aA.exports)),aA.exports}var sA={exports:{}},WF;function yue(){return WF||(WF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^#?([0-9A-F]{3}|[0-9A-F]{4}|[0-9A-F]{6}|[0-9A-F]{8})$/i;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(sA,sA.exports)),sA.exports}var lA={exports:{}},XF;function xue(){return XF||(XF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=y;var n=r(gt());function r(m){return m&&m.__esModule?m:{default:m}}function o(m){"@babel/helpers - typeof";return o=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(x){return typeof x}:function(x){return x&&typeof Symbol=="function"&&x.constructor===Symbol&&x!==Symbol.prototype?"symbol":typeof x},o(m)}var a=/^rgb\((([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5]),){2}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\)$/,l=/^rgba\((([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5]),){3}(0?\.\d|1(\.0)?|0(\.0)?)\)$/,d=/^rgb\((([0-9]%|[1-9][0-9]%|100%),){2}([0-9]%|[1-9][0-9]%|100%)\)$/,h=/^rgba\((([0-9]%|[1-9][0-9]%|100%),){3}(0?\.\d|1(\.0)?|0(\.0)?)\)$/,p=/^rgba?/;function y(m,x){(0,n.default)(m);var _=!1,w=!0;if(o(x)!=="object"?arguments.length>=2&&(w=arguments[1]):(_=x.allowSpaces!==void 0?x.allowSpaces:_,w=x.includePercentValues!==void 0?x.includePercentValues:w),_){if(!p.test(m))return!1;m=m.replace(/\s/g,"")}return w?a.test(m)||l.test(m)||d.test(m)||h.test(m):a.test(m)||l.test(m)}e.exports=t.default,e.exports.default=t.default}(lA,lA.exports)),lA.exports}var uA={exports:{}},JF;function bue(){return JF||(JF=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=r(gt());function r(d){return d&&d.__esModule?d:{default:d}}var o=/^hsla?\(((\+|\-)?([0-9]+(\.[0-9]+)?(e(\+|\-)?[0-9]+)?|\.[0-9]+(e(\+|\-)?[0-9]+)?))(deg|grad|rad|turn)?(,(\+|\-)?([0-9]+(\.[0-9]+)?(e(\+|\-)?[0-9]+)?|\.[0-9]+(e(\+|\-)?[0-9]+)?)%){2}(,((\+|\-)?([0-9]+(\.[0-9]+)?(e(\+|\-)?[0-9]+)?|\.[0-9]+(e(\+|\-)?[0-9]+)?)%?))?\)$/i,a=/^hsla?\(((\+|\-)?([0-9]+(\.[0-9]+)?(e(\+|\-)?[0-9]+)?|\.[0-9]+(e(\+|\-)?[0-9]+)?))(deg|grad|rad|turn)?(\s(\+|\-)?([0-9]+(\.[0-9]+)?(e(\+|\-)?[0-9]+)?|\.[0-9]+(e(\+|\-)?[0-9]+)?)%){2}\s?(\/\s((\+|\-)?([0-9]+(\.[0-9]+)?(e(\+|\-)?[0-9]+)?|\.[0-9]+(e(\+|\-)?[0-9]+)?)%?)\s?)?\)$/i;function l(d){(0,n.default)(d);var h=d.replace(/\s+/g," ").replace(/\s?(hsla?\(|\)|,)\s?/ig,"$1");return h.indexOf(",")!==-1?o.test(h):a.test(h)}e.exports=t.default,e.exports.default=t.default}(uA,uA.exports)),uA.exports}var cA={exports:{}},eU;function _ue(){return eU||(eU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^[A-Z]{2}[0-9A-Z]{3}\d{2}\d{5}$/;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(cA,cA.exports)),cA.exports}var Om={},tU;function Sue(){if(tU)return Om;tU=1,Object.defineProperty(Om,"__esModule",{value:!0}),Om.default=l,Om.locales=void 0;var e=t(gt());function t(d){return d&&d.__esModule?d:{default:d}}var n={AD:/^(AD[0-9]{2})\d{8}[A-Z0-9]{12}$/,AE:/^(AE[0-9]{2})\d{3}\d{16}$/,AL:/^(AL[0-9]{2})\d{8}[A-Z0-9]{16}$/,AT:/^(AT[0-9]{2})\d{16}$/,AZ:/^(AZ[0-9]{2})[A-Z0-9]{4}\d{20}$/,BA:/^(BA[0-9]{2})\d{16}$/,BE:/^(BE[0-9]{2})\d{12}$/,BG:/^(BG[0-9]{2})[A-Z]{4}\d{6}[A-Z0-9]{8}$/,BH:/^(BH[0-9]{2})[A-Z]{4}[A-Z0-9]{14}$/,BR:/^(BR[0-9]{2})\d{23}[A-Z]{1}[A-Z0-9]{1}$/,BY:/^(BY[0-9]{2})[A-Z0-9]{4}\d{20}$/,CH:/^(CH[0-9]{2})\d{5}[A-Z0-9]{12}$/,CR:/^(CR[0-9]{2})\d{18}$/,CY:/^(CY[0-9]{2})\d{8}[A-Z0-9]{16}$/,CZ:/^(CZ[0-9]{2})\d{20}$/,DE:/^(DE[0-9]{2})\d{18}$/,DK:/^(DK[0-9]{2})\d{14}$/,DO:/^(DO[0-9]{2})[A-Z]{4}\d{20}$/,DZ:/^(DZ\d{24})$/,EE:/^(EE[0-9]{2})\d{16}$/,EG:/^(EG[0-9]{2})\d{25}$/,ES:/^(ES[0-9]{2})\d{20}$/,FI:/^(FI[0-9]{2})\d{14}$/,FO:/^(FO[0-9]{2})\d{14}$/,FR:/^(FR[0-9]{2})\d{10}[A-Z0-9]{11}\d{2}$/,GB:/^(GB[0-9]{2})[A-Z]{4}\d{14}$/,GE:/^(GE[0-9]{2})[A-Z0-9]{2}\d{16}$/,GI:/^(GI[0-9]{2})[A-Z]{4}[A-Z0-9]{15}$/,GL:/^(GL[0-9]{2})\d{14}$/,GR:/^(GR[0-9]{2})\d{7}[A-Z0-9]{16}$/,GT:/^(GT[0-9]{2})[A-Z0-9]{4}[A-Z0-9]{20}$/,HR:/^(HR[0-9]{2})\d{17}$/,HU:/^(HU[0-9]{2})\d{24}$/,IE:/^(IE[0-9]{2})[A-Z]{4}\d{14}$/,IL:/^(IL[0-9]{2})\d{19}$/,IQ:/^(IQ[0-9]{2})[A-Z]{4}\d{15}$/,IR:/^(IR[0-9]{2})0\d{2}0\d{18}$/,IS:/^(IS[0-9]{2})\d{22}$/,IT:/^(IT[0-9]{2})[A-Z]{1}\d{10}[A-Z0-9]{12}$/,JO:/^(JO[0-9]{2})[A-Z]{4}\d{22}$/,KW:/^(KW[0-9]{2})[A-Z]{4}[A-Z0-9]{22}$/,KZ:/^(KZ[0-9]{2})\d{3}[A-Z0-9]{13}$/,LB:/^(LB[0-9]{2})\d{4}[A-Z0-9]{20}$/,LC:/^(LC[0-9]{2})[A-Z]{4}[A-Z0-9]{24}$/,LI:/^(LI[0-9]{2})\d{5}[A-Z0-9]{12}$/,LT:/^(LT[0-9]{2})\d{16}$/,LU:/^(LU[0-9]{2})\d{3}[A-Z0-9]{13}$/,LV:/^(LV[0-9]{2})[A-Z]{4}[A-Z0-9]{13}$/,MA:/^(MA[0-9]{26})$/,MC:/^(MC[0-9]{2})\d{10}[A-Z0-9]{11}\d{2}$/,MD:/^(MD[0-9]{2})[A-Z0-9]{20}$/,ME:/^(ME[0-9]{2})\d{18}$/,MK:/^(MK[0-9]{2})\d{3}[A-Z0-9]{10}\d{2}$/,MR:/^(MR[0-9]{2})\d{23}$/,MT:/^(MT[0-9]{2})[A-Z]{4}\d{5}[A-Z0-9]{18}$/,MU:/^(MU[0-9]{2})[A-Z]{4}\d{19}[A-Z]{3}$/,MZ:/^(MZ[0-9]{2})\d{21}$/,NL:/^(NL[0-9]{2})[A-Z]{4}\d{10}$/,NO:/^(NO[0-9]{2})\d{11}$/,PK:/^(PK[0-9]{2})[A-Z0-9]{4}\d{16}$/,PL:/^(PL[0-9]{2})\d{24}$/,PS:/^(PS[0-9]{2})[A-Z]{4}[A-Z0-9]{21}$/,PT:/^(PT[0-9]{2})\d{21}$/,QA:/^(QA[0-9]{2})[A-Z]{4}[A-Z0-9]{21}$/,RO:/^(RO[0-9]{2})[A-Z]{4}[A-Z0-9]{16}$/,RS:/^(RS[0-9]{2})\d{18}$/,SA:/^(SA[0-9]{2})\d{2}[A-Z0-9]{18}$/,SC:/^(SC[0-9]{2})[A-Z]{4}\d{20}[A-Z]{3}$/,SE:/^(SE[0-9]{2})\d{20}$/,SI:/^(SI[0-9]{2})\d{15}$/,SK:/^(SK[0-9]{2})\d{20}$/,SM:/^(SM[0-9]{2})[A-Z]{1}\d{10}[A-Z0-9]{12}$/,SV:/^(SV[0-9]{2})[A-Z0-9]{4}\d{20}$/,TL:/^(TL[0-9]{2})\d{19}$/,TN:/^(TN[0-9]{2})\d{20}$/,TR:/^(TR[0-9]{2})\d{5}[A-Z0-9]{17}$/,UA:/^(UA[0-9]{2})\d{6}[A-Z0-9]{19}$/,VA:/^(VA[0-9]{2})\d{18}$/,VG:/^(VG[0-9]{2})[A-Z]{4}\d{16}$/,XK:/^(XK[0-9]{2})\d{16}$/};function r(d){var h=d.filter(function(p){return!(p in n)});return!(h.length>0)}function o(d,h){var p=d.replace(/[\s\-]+/gi,"").toUpperCase(),y=p.slice(0,2).toUpperCase(),m=y in n;if(h.whitelist){if(!r(h.whitelist))return!1;var x=h.whitelist.includes(y);if(!x)return!1}if(h.blacklist){var _=h.blacklist.includes(y);if(_)return!1}return m&&n[y].test(p)}function a(d){var h=d.replace(/[^A-Z0-9]+/gi,"").toUpperCase(),p=h.slice(4)+h.slice(0,4),y=p.replace(/[A-Z]/g,function(x){return x.charCodeAt(0)-55}),m=y.match(/\d{1,7}/g).reduce(function(x,_){return Number(x+_)%97},"");return m===1}function l(d){var h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(0,e.default)(d),o(d,h)&&a(d)}return Om.locales=Object.keys(n),Om}var fA={exports:{}},Dm={},nU;function rU(){if(nU)return Dm;nU=1,Object.defineProperty(Dm,"__esModule",{value:!0}),Dm.CountryCodes=void 0,Dm.default=r;var e=t(gt());function t(o){return o&&o.__esModule?o:{default:o}}var n=new Set(["AD","AE","AF","AG","AI","AL","AM","AO","AQ","AR","AS","AT","AU","AW","AX","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BV","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","EH","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GS","GT","GU","GW","GY","HK","HM","HN","HR","HT","HU","ID","IE","IL","IM","IN","IO","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TF","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","UM","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]);function r(o){return(0,e.default)(o),n.has(o.toUpperCase())}return Dm.CountryCodes=n,Dm}var iU;function wue(){return iU||(iU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=o(gt()),r=rU();function o(d){return d&&d.__esModule?d:{default:d}}var a=/^[A-Za-z]{6}[A-Za-z0-9]{2}([A-Za-z0-9]{3})?$/;function l(d){(0,n.default)(d);var h=d.slice(4,6).toUpperCase();return!r.CountryCodes.has(h)&&h!=="XK"?!1:a.test(d)}e.exports=t.default,e.exports.default=t.default}(fA,fA.exports)),fA.exports}var dA={exports:{}},oU;function Cue(){return oU||(oU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^[a-f0-9]{32}$/;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(dA,dA.exports)),dA.exports}var hA={exports:{}},aU;function Eue(){return aU||(aU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o={md5:32,md4:32,sha1:40,sha256:64,sha384:96,sha512:128,ripemd128:32,ripemd160:40,tiger128:32,tiger160:40,tiger192:48,crc32:8,crc32b:8};function a(l,d){(0,n.default)(l);var h=new RegExp("^[a-fA-F0-9]{".concat(o[d],"}$"));return h.test(l)}e.exports=t.default,e.exports.default=t.default}(hA,hA.exports)),hA.exports}var pA={exports:{}},gA={exports:{}},sU;function lU(){return sU||(sU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=h;var n=o(gt()),r=o(Na());function o(p){return p&&p.__esModule?p:{default:p}}var a=/[^A-Z0-9+\/=]/i,l=/^[A-Z0-9_\-]*$/i,d={urlSafe:!1};function h(p,y){(0,n.default)(p),y=(0,r.default)(y,d);var m=p.length;if(y.urlSafe)return l.test(p);if(m%4!==0||a.test(p))return!1;var x=p.indexOf("=");return x===-1||x===m-1||x===m-2&&p[m-1]==="="}e.exports=t.default,e.exports.default=t.default}(gA,gA.exports)),gA.exports}var uU;function Aue(){return uU||(uU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=o(gt()),r=o(lU());function o(l){return l&&l.__esModule?l:{default:l}}function a(l){(0,n.default)(l);var d=l.split("."),h=d.length;return h!==3?!1:d.reduce(function(p,y){return p&&(0,r.default)(y,{urlSafe:!0})},!0)}e.exports=t.default,e.exports.default=t.default}(pA,pA.exports)),pA.exports}var mA={exports:{}},cU;function kue(){return cU||(cU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=o(gt()),r=o(Na());function o(h){return h&&h.__esModule?h:{default:h}}function a(h){"@babel/helpers - typeof";return a=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(p){return typeof p}:function(p){return p&&typeof Symbol=="function"&&p.constructor===Symbol&&p!==Symbol.prototype?"symbol":typeof p},a(h)}var l={allow_primitives:!1};function d(h,p){(0,n.default)(h);try{p=(0,r.default)(p,l);var y=[];p.allow_primitives&&(y=[null,!1,!0]);var m=JSON.parse(h);return y.includes(m)||!!m&&a(m)==="object"}catch{}return!1}e.exports=t.default,e.exports.default=t.default}(mA,mA.exports)),mA.exports}var vA={exports:{}},fU;function Tue(){return fU||(fU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=o(gt()),r=o(Na());function o(d){return d&&d.__esModule?d:{default:d}}var a={ignore_whitespace:!1};function l(d,h){return(0,n.default)(d),h=(0,r.default)(h,a),(h.ignore_whitespace?d.trim().length:d.length)===0}e.exports=t.default,e.exports.default=t.default}(vA,vA.exports)),vA.exports}var yA={exports:{}},dU;function Rue(){return dU||(dU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}function o(l){"@babel/helpers - typeof";return o=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(d){return typeof d}:function(d){return d&&typeof Symbol=="function"&&d.constructor===Symbol&&d!==Symbol.prototype?"symbol":typeof d},o(l)}function a(l,d){(0,n.default)(l);var h,p;o(d)==="object"?(h=d.min||0,p=d.max):(h=arguments[1]||0,p=arguments[2]);var y=l.match(/(\uFE0F|\uFE0E)/g)||[],m=l.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g)||[],x=l.length-y.length-m.length,_=x>=h&&(typeof p>"u"||x<=p);return _&&Array.isArray(d==null?void 0:d.discreteLengths)?d.discreteLengths.some(function(w){return w===x}):_}e.exports=t.default,e.exports.default=t.default}(yA,yA.exports)),yA.exports}var xA={exports:{}},hU;function Oue(){return hU||(hU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a){return(0,n.default)(a),/^[0-7][0-9A-HJKMNP-TV-Z]{25}$/i.test(a)}e.exports=t.default,e.exports.default=t.default}(xA,xA.exports)),xA.exports}var bA={exports:{}},pU;function Due(){return pU||(pU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o={1:/^[0-9A-F]{8}-[0-9A-F]{4}-1[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,2:/^[0-9A-F]{8}-[0-9A-F]{4}-2[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,3:/^[0-9A-F]{8}-[0-9A-F]{4}-3[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,4:/^[0-9A-F]{8}-[0-9A-F]{4}-4[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,5:/^[0-9A-F]{8}-[0-9A-F]{4}-5[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,6:/^[0-9A-F]{8}-[0-9A-F]{4}-6[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,7:/^[0-9A-F]{8}-[0-9A-F]{4}-7[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,8:/^[0-9A-F]{8}-[0-9A-F]{4}-8[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,nil:/^00000000-0000-0000-0000-000000000000$/i,max:/^ffffffff-ffff-ffff-ffff-ffffffffffff$/i,all:/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-8][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/i};function a(l,d){return(0,n.default)(l),d==null&&(d="all"),d in o?o[d].test(l):!1}e.exports=t.default,e.exports.default=t.default}(bA,bA.exports)),bA.exports}var _A={exports:{}},gU;function Mue(){return gU||(gU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=o(gt()),r=o(ZF());function o(l){return l&&l.__esModule?l:{default:l}}function a(l){return(0,n.default)(l),(0,r.default)(l)&&l.length===24}e.exports=t.default,e.exports.default=t.default}(_A,_A.exports)),_A.exports}var SA={exports:{}},mU;function Iue(){return mU||(mU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(VD());function r(a){return a&&a.__esModule?a:{default:a}}function o(a,l){var d=(l==null?void 0:l.comparisonDate)||l||Date().toString(),h=(0,n.default)(d),p=(0,n.default)(a);return!!(p&&h&&p>h)}e.exports=t.default,e.exports.default=t.default}(SA,SA.exports)),SA.exports}var wA={exports:{}},vU;function $ue(){return vU||(vU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=o(gt()),r=o(VD());function o(l){return l&&l.__esModule?l:{default:l}}function a(l){var d=arguments.length>1&&arguments[1]!==void 0?arguments[1]:String(new Date);(0,n.default)(l);var h=(0,r.default)(d),p=(0,r.default)(l);return!!(p&&h&&p<h)}e.exports=t.default,e.exports.default=t.default}(wA,wA.exports)),wA.exports}var CA={exports:{}},yU;function Bue(){return yU||(yU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=o(gt()),r=o(oF());function o(d){return d&&d.__esModule?d:{default:d}}function a(d){"@babel/helpers - typeof";return a=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(h){return typeof h}:function(h){return h&&typeof Symbol=="function"&&h.constructor===Symbol&&h!==Symbol.prototype?"symbol":typeof h},a(d)}function l(d,h){(0,n.default)(d);var p;if(Object.prototype.toString.call(h)==="[object Array]"){var y=[];for(p in h)({}).hasOwnProperty.call(h,p)&&(y[p]=(0,r.default)(h[p]));return y.indexOf(d)>=0}else{if(a(h)==="object")return h.hasOwnProperty(d);if(h&&typeof h.indexOf=="function")return h.indexOf(d)>=0}return!1}e.exports=t.default,e.exports.default=t.default}(CA,CA.exports)),CA.exports}var EA={exports:{}},xU;function bU(){return xU||(xU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a){(0,n.default)(a);for(var l=a.replace(/[- ]+/g,""),d=0,h,p,y,m=l.length-1;m>=0;m--)h=l.substring(m,m+1),p=parseInt(h,10),y?(p*=2,p>=10?d+=p%10+1:d+=p):d+=p,y=!y;return!!(d%10===0&&l)}e.exports=t.default,e.exports.default=t.default}(EA,EA.exports)),EA.exports}var AA={exports:{}},_U;function Lue(){return _U||(_U=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=o(gt()),r=o(bU());function o(h){return h&&h.__esModule?h:{default:h}}var a={amex:/^3[47][0-9]{13}$/,dinersclub:/^3(?:0[0-5]|[68][0-9])[0-9]{11}$/,discover:/^6(?:011|5[0-9][0-9])[0-9]{12,15}$/,jcb:/^(?:2131|1800|35\d{3})\d{11}$/,mastercard:/^5[1-5][0-9]{2}|(222[1-9]|22[3-9][0-9]|2[3-6][0-9]{2}|27[01][0-9]|2720)[0-9]{12}$/,unionpay:/^(6[27][0-9]{14}|^(81[0-9]{14,17}))$/,visa:/^(?:4[0-9]{12})(?:[0-9]{3,6})?$/},l=function(){var h=[];for(var p in a)a.hasOwnProperty(p)&&h.push(a[p]);return h}();function d(h){var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};(0,n.default)(h);var y=p.provider,m=h.replace(/[- ]+/g,"");if(y&&y.toLowerCase()in a){if(!a[y.toLowerCase()].test(m))return!1}else{if(y&&!(y.toLowerCase()in a))throw new Error("".concat(y," is not a valid credit card provider."));if(!l.some(function(x){return x.test(m)}))return!1}return(0,r.default)(h)}e.exports=t.default,e.exports.default=t.default}(AA,AA.exports)),AA.exports}var kA={exports:{}},SU;function Nue(){return SU||(SU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=o(gt()),r=o(ZD());function o(d){return d&&d.__esModule?d:{default:d}}var a={PL:function(h){(0,n.default)(h);var p={1:1,2:3,3:7,4:9,5:1,6:3,7:7,8:9,9:1,10:3,11:0};if(h!=null&&h.length===11&&(0,r.default)(h,{allow_leading_zeroes:!0})){var y=h.split("").slice(0,-1),m=y.reduce(function(w,k,A){return w+Number(k)*p[A+1]},0),x=m%10,_=Number(h.charAt(h.length-1));if(x===0&&_===0||_===10-x)return!0}return!1},ES:function(h){(0,n.default)(h);var p=/^[0-9X-Z][0-9]{7}[TRWAGMYFPDXBNJZSQVHLCKE]$/,y={X:0,Y:1,Z:2},m=["T","R","W","A","G","M","Y","F","P","D","X","B","N","J","Z","S","Q","V","H","L","C","K","E"],x=h.trim().toUpperCase();if(!p.test(x))return!1;var _=x.slice(0,-1).replace(/[X,Y,Z]/g,function(w){return y[w]});return x.endsWith(m[_%23])},FI:function(h){if((0,n.default)(h),h.length!==11||!h.match(/^\d{6}[\-A\+]\d{3}[0-9ABCDEFHJKLMNPRSTUVWXY]{1}$/))return!1;var p="0123456789ABCDEFHJKLMNPRSTUVWXY",y=parseInt(h.slice(0,6),10)*1e3+parseInt(h.slice(7,10),10),m=y%31,x=p[m];return x===h.slice(10,11)},IN:function(h){var p=/^[1-9]\d{3}\s?\d{4}\s?\d{4}$/,y=[[0,1,2,3,4,5,6,7,8,9],[1,2,3,4,0,6,7,8,9,5],[2,3,4,0,1,7,8,9,5,6],[3,4,0,1,2,8,9,5,6,7],[4,0,1,2,3,9,5,6,7,8],[5,9,8,7,6,0,4,3,2,1],[6,5,9,8,7,1,0,4,3,2],[7,6,5,9,8,2,1,0,4,3],[8,7,6,5,9,3,2,1,0,4],[9,8,7,6,5,4,3,2,1,0]],m=[[0,1,2,3,4,5,6,7,8,9],[1,5,7,6,2,8,3,0,9,4],[5,8,0,3,7,9,6,1,4,2],[8,9,1,6,0,4,3,5,2,7],[9,4,5,3,1,2,6,8,7,0],[4,2,8,6,5,7,3,9,0,1],[2,7,9,3,8,0,6,4,1,5],[7,0,4,6,9,1,3,2,5,8]],x=h.trim();if(!p.test(x))return!1;var _=0,w=x.replace(/\s/g,"").split("").map(Number).reverse();return w.forEach(function(k,A){_=y[_][m[A%8][k]]}),_===0},IR:function(h){if(!h.match(/^\d{10}$/)||(h="0000".concat(h).slice(h.length-6),parseInt(h.slice(3,9),10)===0))return!1;for(var p=parseInt(h.slice(9,10),10),y=0,m=0;m<9;m++)y+=parseInt(h.slice(m,m+1),10)*(10-m);return y%=11,y<2&&p===y||y>=2&&p===11-y},IT:function(h){return h.length!==9||h==="CA00000AA"?!1:h.search(/C[A-Z]\d{5}[A-Z]{2}/i)>-1},NO:function(h){var p=h.trim();if(isNaN(Number(p))||p.length!==11||p==="00000000000")return!1;var y=p.split("").map(Number),m=(11-(3*y[0]+7*y[1]+6*y[2]+1*y[3]+8*y[4]+9*y[5]+4*y[6]+5*y[7]+2*y[8])%11)%11,x=(11-(5*y[0]+4*y[1]+3*y[2]+2*y[3]+7*y[4]+6*y[5]+5*y[6]+4*y[7]+3*y[8]+2*m)%11)%11;return!(m!==y[9]||x!==y[10])},TH:function(h){if(!h.match(/^[1-8]\d{12}$/))return!1;for(var p=0,y=0;y<12;y++)p+=parseInt(h[y],10)*(13-y);return h[12]===((11-p%11)%10).toString()},LK:function(h){var p=/^[1-9]\d{8}[vx]$/i,y=/^[1-9]\d{11}$/i;return h.length===10&&p.test(h)?!0:!!(h.length===12&&y.test(h))},"he-IL":function(h){var p=/^\d{9}$/,y=h.trim();if(!p.test(y))return!1;for(var m=y,x=0,_,w=0;w<m.length;w++)_=Number(m[w])*(w%2+1),x+=_>9?_-9:_;return x%10===0},"ar-LY":function(h){var p=/^(1|2)\d{11}$/,y=h.trim();return!!p.test(y)},"ar-TN":function(h){var p=/^\d{8}$/,y=h.trim();return!!p.test(y)},"zh-CN":function(h){var p=["11","12","13","14","15","21","22","23","31","32","33","34","35","36","37","41","42","43","44","45","46","50","51","52","53","54","61","62","63","64","65","71","81","82","91"],y=["7","9","10","5","8","4","2","1","6","3","7","9","10","5","8","4","2"],m=["1","0","X","9","8","7","6","5","4","3","2"],x=function(I){return p.includes(I)},_=function(I){var L=parseInt(I.substring(0,4),10),N=parseInt(I.substring(4,6),10),H=parseInt(I.substring(6),10),V=new Date(L,N-1,H);return V>new Date?!1:V.getFullYear()===L&&V.getMonth()===N-1&&V.getDate()===H},w=function(I){for(var L=I.substring(0,17),N=0,H=0;H<17;H++)N+=parseInt(L.charAt(H),10)*parseInt(y[H],10);var V=N%11;return m[V]},k=function(I){return w(I)===I.charAt(17).toUpperCase()},A=function(I){var L=/^[1-9]\d{7}((0[1-9])|(1[0-2]))((0[1-9])|([1-2][0-9])|(3[0-1]))\d{3}$/.test(I);if(!L)return!1;var N=I.substring(0,2);if(L=x(N),!L)return!1;var H="19".concat(I.substring(6,12));return L=_(H),!!L},E=function(I){var L=/^[1-9]\d{5}[1-9]\d{3}((0[1-9])|(1[0-2]))((0[1-9])|([1-2][0-9])|(3[0-1]))\d{3}(\d|x|X)$/.test(I);if(!L)return!1;var N=I.substring(0,2);if(L=x(N),!L)return!1;var H=I.substring(6,14);return L=_(H),L?k(I):!1},R=function(I){var L=/^\d{15}|(\d{17}(\d|x|X))$/.test(I);return L?I.length===15?A(I):E(I):!1};return R(h)},"zh-HK":function(h){h=h.trim();var p=/^[A-Z]{1,2}[0-9]{6}((\([0-9A]\))|(\[[0-9A]\])|([0-9A]))$/,y=/^[0-9]$/;if(h=h.toUpperCase(),!p.test(h))return!1;h=h.replace(/\[|\]|\(|\)/g,""),h.length===8&&(h="3".concat(h));for(var m=0,x=0;x<=7;x++){var _=void 0;y.test(h[x])?_=h[x]:_=(h[x].charCodeAt(0)-55)%11,m+=_*(9-x)}m%=11;var w;return m===0?w="0":m===1?w="A":w=String(11-m),w===h[h.length-1]},"zh-TW":function(h){var p={A:10,B:11,C:12,D:13,E:14,F:15,G:16,H:17,I:34,J:18,K:19,L:20,M:21,N:22,O:35,P:23,Q:24,R:25,S:26,T:27,U:28,V:29,W:32,X:30,Y:31,Z:33},y=h.trim().toUpperCase();return/^[A-Z][0-9]{9}$/.test(y)?Array.from(y).reduce(function(m,x,_){if(_===0){var w=p[x];return w%10*9+Math.floor(w/10)}return _===9?(10-m%10-Number(x))%10===0:m+Number(x)*(9-_)},0):!1},PK:function(h){var p=/^[1-7][0-9]{4}-[0-9]{7}-[1-9]$/,y=h.trim();return p.test(y)}};function l(d,h){if((0,n.default)(d),h in a)return a[h](d);if(h==="any"){for(var p in a)if(a.hasOwnProperty(p)){var y=a[p];if(y(d))return!0}return!1}throw new Error("Invalid locale '".concat(h,"'"))}e.exports=t.default,e.exports.default=t.default}(kA,kA.exports)),kA.exports}var TA={exports:{}},wU;function zue(){return wU||(wU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=p;var n=r(gt());function r(y){return y&&y.__esModule?y:{default:y}}var o=8,a=14,l=/^(\d{8}|\d{13}|\d{14})$/;function d(y,m){return y===o||y===a?m%2===0?3:1:m%2===0?1:3}function h(y){var m=y.slice(0,-1).split("").map(function(_,w){return Number(_)*d(y.length,w)}).reduce(function(_,w){return _+w},0),x=10-m%10;return x<10?x:0}function p(y){(0,n.default)(y);var m=Number(y.slice(-1));return l.test(y)&&m===h(y)}e.exports=t.default,e.exports.default=t.default}(TA,TA.exports)),TA.exports}var RA={exports:{}},CU;function Fue(){return CU||(CU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^[A-Z]{2}[0-9A-Z]{9}[0-9]$/;function a(l){if((0,n.default)(l),!o.test(l))return!1;for(var d=!0,h=0,p=l.length-2;p>=0;p--)if(l[p]>="A"&&l[p]<="Z")for(var y=l[p].charCodeAt(0)-55,m=y%10,x=Math.trunc(y/10),_=0,w=[m,x];_<w.length;_++){var k=w[_];d?k>=5?h+=1+(k-5)*2:h+=k*2:h+=k,d=!d}else{var A=l[p].charCodeAt(0)-48;d?A>=5?h+=1+(A-5)*2:h+=A*2:h+=A,d=!d}var E=Math.trunc((h+9)/10)*10-h;return+l[l.length-1]===E}e.exports=t.default,e.exports.default=t.default}(RA,RA.exports)),RA.exports}var OA={exports:{}},EU;function Uue(){return EU||(EU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=r(gt());function r(h){return h&&h.__esModule?h:{default:h}}var o=/^(?:[0-9]{9}X|[0-9]{10})$/,a=/^(?:[0-9]{13})$/,l=[1,3];function d(h,p){(0,n.default)(h);var y=String((p==null?void 0:p.version)||p);if(!(p!=null&&p.version||p))return d(h,{version:10})||d(h,{version:13});var m=h.replace(/[\s-]+/g,""),x=0;if(y==="10"){if(!o.test(m))return!1;for(var _=0;_<y-1;_++)x+=(_+1)*m.charAt(_);if(m.charAt(9)==="X"?x+=100:x+=10*m.charAt(9),x%11===0)return!0}else if(y==="13"){if(!a.test(m))return!1;for(var w=0;w<12;w++)x+=l[w%2]*m.charAt(w);if(m.charAt(12)-(10-x%10)%10===0)return!0}return!1}e.exports=t.default,e.exports.default=t.default}(OA,OA.exports)),OA.exports}var DA={exports:{}},AU;function jue(){return AU||(AU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o="^\\d{4}-?\\d{3}[\\dX]$";function a(l){var d=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};(0,n.default)(l);var h=o;if(h=d.require_hyphen?h.replace("?",""):h,h=d.case_sensitive?new RegExp(h):new RegExp(h,"i"),!h.test(l))return!1;for(var p=l.replace("-","").toUpperCase(),y=0,m=0;m<p.length;m++){var x=p[m];y+=(x==="X"?10:+x)*(8-m)}return y%11===0}e.exports=t.default,e.exports.default=t.default}(DA,DA.exports)),DA.exports}var MA={exports:{}},Bp={},kU;function TU(){if(kU)return Bp;kU=1,Object.defineProperty(Bp,"__esModule",{value:!0}),Bp.iso7064Check=e,Bp.luhnCheck=t,Bp.reverseMultiplyAndSum=n,Bp.verhoeffCheck=r;function e(o){for(var a=10,l=0;l<o.length-1;l++)a=(parseInt(o[l],10)+a)%10===0?9:(parseInt(o[l],10)+a)%10*2%11;return a=a===1?0:11-a,a===parseInt(o[10],10)}function t(o){for(var a=0,l=!1,d=o.length-1;d>=0;d--){if(l){var h=parseInt(o[d],10)*2;h>9?a+=h.toString().split("").map(function(p){return parseInt(p,10)}).reduce(function(p,y){return p+y},0):a+=h}else a+=parseInt(o[d],10);l=!l}return a%10===0}function n(o,a){for(var l=0,d=0;d<o.length;d++)l+=o[d]*(a-d);return l}function r(o){for(var a=[[0,1,2,3,4,5,6,7,8,9],[1,2,3,4,0,6,7,8,9,5],[2,3,4,0,1,7,8,9,5,6],[3,4,0,1,2,8,9,5,6,7],[4,0,1,2,3,9,5,6,7,8],[5,9,8,7,6,0,4,3,2,1],[6,5,9,8,7,1,0,4,3,2],[7,6,5,9,8,2,1,0,4,3],[8,7,6,5,9,3,2,1,0,4],[9,8,7,6,5,4,3,2,1,0]],l=[[0,1,2,3,4,5,6,7,8,9],[1,5,7,6,2,8,3,0,9,4],[5,8,0,3,7,9,6,1,4,2],[8,9,1,6,0,4,3,5,2,7],[9,4,5,3,1,2,6,8,7,0],[4,2,8,6,5,7,3,9,0,1],[2,7,9,3,8,0,6,4,1,5],[7,0,4,6,9,1,3,2,5,8]],d=o.split("").reverse().join(""),h=0,p=0;p<d.length;p++)h=a[h][l[p%8][parseInt(d[p],10)]];return h===0}return Bp}var RU;function Pue(){return RU||(RU=1,function(e,t){function n(re){"@babel/helpers - typeof";return n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(le){return typeof le}:function(le){return le&&typeof Symbol=="function"&&le.constructor===Symbol&&le!==Symbol.prototype?"symbol":typeof le},n(re)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=yt;var r=h(gt()),o=d(TU()),a=h(_F());function l(re){if(typeof WeakMap!="function")return null;var le=new WeakMap,ve=new WeakMap;return(l=function($e){return $e?ve:le})(re)}function d(re,le){if(re&&re.__esModule)return re;if(re===null||n(re)!="object"&&typeof re!="function")return{default:re};var ve=l(le);if(ve&&ve.has(re))return ve.get(re);var Ee={__proto__:null},$e=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var Ve in re)if(Ve!=="default"&&{}.hasOwnProperty.call(re,Ve)){var lt=$e?Object.getOwnPropertyDescriptor(re,Ve):null;lt&&(lt.get||lt.set)?Object.defineProperty(Ee,Ve,lt):Ee[Ve]=re[Ve]}return Ee.default=re,ve&&ve.set(re,Ee),Ee}function h(re){return re&&re.__esModule?re:{default:re}}function p(re){return _(re)||x(re)||m(re)||y()}function y(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
477
477
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function m(re,le){if(re){if(typeof re=="string")return w(re,le);var ve={}.toString.call(re).slice(8,-1);return ve==="Object"&&re.constructor&&(ve=re.constructor.name),ve==="Map"||ve==="Set"?Array.from(re):ve==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ve)?w(re,le):void 0}}function x(re){if(typeof Symbol<"u"&&re[Symbol.iterator]!=null||re["@@iterator"]!=null)return Array.from(re)}function _(re){if(Array.isArray(re))return w(re)}function w(re,le){(le==null||le>re.length)&&(le=re.length);for(var ve=0,Ee=Array(le);ve<le;ve++)Ee[ve]=re[ve];return Ee}function k(re){var le=re.slice(0,2),ve=parseInt(re.slice(2,4),10);ve>40?(ve-=40,le="20".concat(le)):ve>20?(ve-=20,le="18".concat(le)):le="19".concat(le),ve<10&&(ve="0".concat(ve));var Ee="".concat(le,"/").concat(ve,"/").concat(re.slice(4,6));if(!(0,a.default)(Ee,"YYYY/MM/DD"))return!1;for(var $e=re.split("").map(function(_e){return parseInt(_e,10)}),Ve=[2,4,8,5,10,9,7,3,6],lt=0,mt=0;mt<Ve.length;mt++)lt+=$e[mt]*Ve[mt];return lt=lt%11===10?0:lt%11,lt===$e[9]}function A(re){var le=re.split(""),ve=le.filter(function($e,Ve){return Ve%2}).map(function($e){return Number($e)*2}).join("").split(""),Ee=le.filter(function($e,Ve){return!(Ve%2)}).concat(ve).map(function($e){return Number($e)}).reduce(function($e,Ve){return $e+Ve});return Ee%10===0}function E(re){re=re.replace(/\W/,"");var le=parseInt(re.slice(0,2),10);if(re.length===10)le<54?le="20".concat(le):le="19".concat(le);else{if(re.slice(6)==="000")return!1;if(le<54)le="19".concat(le);else return!1}le.length===3&&(le=[le.slice(0,2),"0",le.slice(2)].join(""));var ve=parseInt(re.slice(2,4),10);if(ve>50&&(ve-=50),ve>20){if(parseInt(le,10)<2004)return!1;ve-=20}ve<10&&(ve="0".concat(ve));var Ee="".concat(le,"/").concat(ve,"/").concat(re.slice(4,6));if(!(0,a.default)(Ee,"YYYY/MM/DD"))return!1;if(re.length===10&&parseInt(re,10)%11!==0){var $e=parseInt(re.slice(0,9),10)%11;if(parseInt(le,10)<1986&&$e===10){if(parseInt(re.slice(9),10)!==0)return!1}else return!1}return!0}function R(re){return o.luhnCheck(re)}function O(re){for(var le=re.split("").map(function(_e){return parseInt(_e,10)}),ve=[],Ee=0;Ee<le.length-1;Ee++){ve.push("");for(var $e=0;$e<le.length-1;$e++)le[Ee]===le[$e]&&(ve[Ee]+=$e)}if(ve=ve.filter(function(_e){return _e.length>1}),ve.length!==2&&ve.length!==3)return!1;if(ve[0].length===3){for(var Ve=ve[0].split("").map(function(_e){return parseInt(_e,10)}),lt=0,mt=0;mt<Ve.length-1;mt++)Ve[mt]+1===Ve[mt+1]&&(lt+=1);if(lt===2)return!1}return o.iso7064Check(re)}function I(re){re=re.replace(/\W/,"");var le=parseInt(re.slice(4,6),10),ve=re.slice(6,7);switch(ve){case"0":case"1":case"2":case"3":le="19".concat(le);break;case"4":case"9":le<37?le="20".concat(le):le="19".concat(le);break;default:if(le<37)le="20".concat(le);else if(le>58)le="18".concat(le);else return!1;break}le.length===3&&(le=[le.slice(0,2),"0",le.slice(2)].join(""));var Ee="".concat(le,"/").concat(re.slice(2,4),"/").concat(re.slice(0,2));if(!(0,a.default)(Ee,"YYYY/MM/DD"))return!1;for(var $e=re.split("").map(function(_e){return parseInt(_e,10)}),Ve=0,lt=4,mt=0;mt<9;mt++)Ve+=$e[mt]*lt,lt-=1,lt===1&&(lt=7);return Ve%=11,Ve===1?!1:Ve===0?$e[9]===0:$e[9]===11-Ve}function L(re){for(var le=re.slice(0,8).split("").map(function(Ve){return parseInt(Ve,10)}),ve=0,Ee=1;Ee<le.length;Ee+=2)ve+=le[Ee];for(var $e=0;$e<le.length;$e+=2)le[$e]<2?ve+=1-le[$e]:(ve+=2*(le[$e]-2)+5,le[$e]>4&&(ve+=2));return String.fromCharCode(ve%26+65)===re.charAt(8)}function N(re){for(var le=re.split("").map(function($e){return parseInt($e,10)}),ve=0,Ee=0;Ee<8;Ee++)ve+=le[Ee]*Math.pow(2,8-Ee);return ve%11%10===le[8]}function H(re){var le=o.reverseMultiplyAndSum(re.split("").slice(0,7).map(function(ve){return parseInt(ve,10)}),8);return re.length===9&&re[8]!=="W"&&(le+=(re[8].charCodeAt(0)-64)*9),le%=23,le===0?re[7].toUpperCase()==="W":re[7].toUpperCase()===String.fromCharCode(64+le)}var V={andover:["10","12"],atlanta:["60","67"],austin:["50","53"],brookhaven:["01","02","03","04","05","06","11","13","14","16","21","22","23","25","34","51","52","54","55","56","57","58","59","65"],cincinnati:["30","32","35","36","37","38","61"],fresno:["15","24"],internet:["20","26","27","45","46","47"],kansas:["40","44"],memphis:["94","95"],ogden:["80","90"],philadelphia:["33","39","41","42","43","46","48","62","63","64","66","68","71","72","73","74","75","76","77","81","82","83","84","85","86","87","88","91","92","93","98","99"],sba:["31"]};function W(){var re=[];for(var le in V)V.hasOwnProperty(le)&&re.push.apply(re,p(V[le]));return re}function z(re){return W().indexOf(re.slice(0,2))!==-1}function Q(re){for(var le=0,ve=re.split(""),Ee=parseInt(ve.pop(),10),$e=0;$e<ve.length;$e++)le+=ve[9-$e]*(2+$e%6);var Ve=11-le%11;return Ve===11?Ve=0:Ve===10&&(Ve=9),Ee===Ve}function J(re){var le=re.toUpperCase().split("");if(isNaN(parseInt(le[0],10))&&le.length>1){var ve=0;switch(le[0]){case"Y":ve=1;break;case"Z":ve=2;break}le.splice(0,1,ve)}else for(;le.length<9;)le.unshift(0);var Ee=["T","R","W","A","G","M","Y","F","P","D","X","B","N","J","Z","S","Q","V","H","L","C","K","E"];le=le.join("");var $e=parseInt(le.slice(0,8),10)%23;return le[8]===Ee[$e]}function ie(re){var le=re.slice(1,3),ve=re.slice(0,1);switch(ve){case"1":case"2":le="18".concat(le);break;case"3":case"4":le="19".concat(le);break;default:le="20".concat(le);break}var Ee="".concat(le,"/").concat(re.slice(3,5),"/").concat(re.slice(5,7));if(!(0,a.default)(Ee,"YYYY/MM/DD"))return!1;for(var $e=re.split("").map(function(Re){return parseInt(Re,10)}),Ve=0,lt=1,mt=0;mt<10;mt++)Ve+=$e[mt]*lt,lt+=1,lt===10&&(lt=1);if(Ve%11===10){Ve=0,lt=3;for(var _e=0;_e<10;_e++)Ve+=$e[_e]*lt,lt+=1,lt===10&&(lt=1);if(Ve%11===10)return $e[10]===0}return Ve%11===$e[10]}function ee(re){var le=re.slice(4,6),ve=re.slice(6,7);switch(ve){case"+":le="18".concat(le);break;case"-":le="19".concat(le);break;default:le="20".concat(le);break}var Ee="".concat(le,"/").concat(re.slice(2,4),"/").concat(re.slice(0,2));if(!(0,a.default)(Ee,"YYYY/MM/DD"))return!1;var $e=parseInt(re.slice(0,6)+re.slice(7,10),10)%31;if($e<10)return $e===parseInt(re.slice(10),10);$e-=10;var Ve=["A","B","C","D","E","F","H","J","K","L","M","N","P","R","S","T","U","V","W","X","Y"];return Ve[$e]===re.slice(10)}function de(re){if(re.slice(2,4)!=="00"||re.slice(4,6)!=="00"){var le="".concat(re.slice(0,2),"/").concat(re.slice(2,4),"/").concat(re.slice(4,6));if(!(0,a.default)(le,"YY/MM/DD"))return!1}var ve=97-parseInt(re.slice(0,9),10)%97,Ee=parseInt(re.slice(9,11),10);return!(ve!==Ee&&(ve=97-parseInt("2".concat(re.slice(0,9)),10)%97,ve!==Ee))}function ue(re){re=re.replace(/\s/g,"");var le=parseInt(re.slice(0,10),10)%511,ve=parseInt(re.slice(10,13),10);return le===ve}function se(re){var le="".concat(re.slice(0,4),"/").concat(re.slice(4,6),"/").concat(re.slice(6,8));return!(0,a.default)(le,"YYYY/MM/DD")||!o.luhnCheck(re.slice(0,12))?!1:o.verhoeffCheck("".concat(re.slice(0,11)).concat(re[12]))}function pe(re){return o.iso7064Check(re)}function Ce(re){for(var le=re.split("").map(function($e){return parseInt($e,10)}),ve=8,Ee=1;Ee<9;Ee++)ve+=le[Ee]*(Ee+1);return ve%11===le[9]}function B(re){for(var le=!1,ve=!1,Ee=0;Ee<3;Ee++)if(!le&&/[AEIOU]/.test(re[Ee]))le=!0;else if(!ve&&le&&re[Ee]==="X")ve=!0;else if(Ee>0&&(le&&!ve&&!/[AEIOU]/.test(re[Ee])||ve&&!/X/.test(re[Ee])))return!1;return!0}function P(re){var le=re.toUpperCase().split("");if(!B(le.slice(0,3))||!B(le.slice(3,6)))return!1;for(var ve=[6,7,9,10,12,13,14],Ee={L:"0",M:"1",N:"2",P:"3",Q:"4",R:"5",S:"6",T:"7",U:"8",V:"9"},$e=0,Ve=ve;$e<Ve.length;$e++){var lt=Ve[$e];le[lt]in Ee&&le.splice(lt,1,Ee[le[lt]])}var mt={A:"01",B:"02",C:"03",D:"04",E:"05",H:"06",L:"07",M:"08",P:"09",R:"10",S:"11",T:"12"},_e=mt[le[8]],Re=parseInt(le[9]+le[10],10);Re>40&&(Re-=40),Re<10&&(Re="0".concat(Re));var Ct="".concat(le[6]).concat(le[7],"/").concat(_e,"/").concat(Re);if(!(0,a.default)(Ct,"YY/MM/DD"))return!1;for(var ct=0,Rt=1;Rt<le.length-1;Rt+=2){var Mt=parseInt(le[Rt],10);isNaN(Mt)&&(Mt=le[Rt].charCodeAt(0)-65),ct+=Mt}for(var en={A:1,B:0,C:5,D:7,E:9,F:13,G:15,H:17,I:19,J:21,K:2,L:4,M:18,N:20,O:11,P:3,Q:6,R:8,S:12,T:14,U:16,V:10,W:22,X:25,Y:24,Z:23,0:1,1:0},Qt=0;Qt<le.length-1;Qt+=2){var gn=0;if(le[Qt]in en)gn=en[le[Qt]];else{var pt=parseInt(le[Qt],10);gn=2*pt+1,pt>4&&(gn+=2)}ct+=gn}return String.fromCharCode(65+ct%26)===le[15]}function ne(re){re=re.replace(/\W/,"");var le=re.slice(0,2);if(le!=="32"){var ve=re.slice(2,4);if(ve!=="00"){var Ee=re.slice(4,6);switch(re[6]){case"0":Ee="18".concat(Ee);break;case"1":Ee="19".concat(Ee);break;default:Ee="20".concat(Ee);break}var $e="".concat(Ee,"/").concat(re.slice(2,4),"/").concat(le);if(!(0,a.default)($e,"YYYY/MM/DD"))return!1}for(var Ve=1101,lt=[1,6,3,7,9,10,5,8,4,2],mt=0;mt<re.length-1;mt++)Ve-=parseInt(re[mt],10)*lt[mt];return parseInt(re[10],10)===Ve%11}return!0}function U(re){if(re.length!==9){for(var le=re.toUpperCase().split("");le.length<8;)le.unshift(0);switch(re[7]){case"A":case"P":if(parseInt(le[6],10)===0)return!1;break;default:{var ve=parseInt(le.join("").slice(0,5),10);if(ve>32e3)return!1;var Ee=parseInt(le.join("").slice(5,7),10);if(ve===Ee)return!1}}}return!0}function fe(re){return o.reverseMultiplyAndSum(re.split("").slice(0,8).map(function(le){return parseInt(le,10)}),9)%11===parseInt(re[8],10)}function Ae(re){if(re.length===10){for(var le=[6,5,7,2,3,4,5,6,7],ve=0,Ee=0;Ee<le.length;Ee++)ve+=parseInt(re[Ee],10)*le[Ee];return ve%=11,ve===10?!1:ve===parseInt(re[9],10)}var $e=re.slice(0,2),Ve=parseInt(re.slice(2,4),10);Ve>80?($e="18".concat($e),Ve-=80):Ve>60?($e="22".concat($e),Ve-=60):Ve>40?($e="21".concat($e),Ve-=40):Ve>20?($e="20".concat($e),Ve-=20):$e="19".concat($e),Ve<10&&(Ve="0".concat(Ve));var lt="".concat($e,"/").concat(Ve,"/").concat(re.slice(4,6));if(!(0,a.default)(lt,"YYYY/MM/DD"))return!1;for(var mt=0,_e=1,Re=0;Re<re.length-1;Re++)mt+=parseInt(re[Re],10)*_e%10,_e+=2,_e>10?_e=1:_e===5&&(_e+=2);return mt=10-mt%10,mt===parseInt(re[10],10)}function Te(re){if(re.length===11){var le,ve;if(le=0,re==="11111111111"||re==="22222222222"||re==="33333333333"||re==="44444444444"||re==="55555555555"||re==="66666666666"||re==="77777777777"||re==="88888888888"||re==="99999999999"||re==="00000000000")return!1;for(var Ee=1;Ee<=9;Ee++)le+=parseInt(re.substring(Ee-1,Ee),10)*(11-Ee);if(ve=le*10%11,ve===10&&(ve=0),ve!==parseInt(re.substring(9,10),10))return!1;le=0;for(var $e=1;$e<=10;$e++)le+=parseInt(re.substring($e-1,$e),10)*(12-$e);return ve=le*10%11,ve===10&&(ve=0),ve===parseInt(re.substring(10,11),10)}if(re==="00000000000000"||re==="11111111111111"||re==="22222222222222"||re==="33333333333333"||re==="44444444444444"||re==="55555555555555"||re==="66666666666666"||re==="77777777777777"||re==="88888888888888"||re==="99999999999999")return!1;for(var Ve=re.length-2,lt=re.substring(0,Ve),mt=re.substring(Ve),_e=0,Re=Ve-7,Ct=Ve;Ct>=1;Ct--)_e+=lt.charAt(Ve-Ct)*Re,Re-=1,Re<2&&(Re=9);var ct=_e%11<2?0:11-_e%11;if(ct!==parseInt(mt.charAt(0),10))return!1;Ve+=1,lt=re.substring(0,Ve),_e=0,Re=Ve-7;for(var Rt=Ve;Rt>=1;Rt--)_e+=lt.charAt(Ve-Rt)*Re,Re-=1,Re<2&&(Re=9);return ct=_e%11<2?0:11-_e%11,ct===parseInt(mt.charAt(1),10)}function rt(re){var le=11-o.reverseMultiplyAndSum(re.split("").slice(0,8).map(function(ve){return parseInt(ve,10)}),9)%11;return le>9?parseInt(re[8],10)===0:le===parseInt(re[8],10)}function Ge(re){if(re.slice(0,4)!=="9000"){var le=re.slice(1,3);switch(re[0]){case"1":case"2":le="19".concat(le);break;case"3":case"4":le="18".concat(le);break;case"5":case"6":le="20".concat(le);break}var ve="".concat(le,"/").concat(re.slice(3,5),"/").concat(re.slice(5,7));if(ve.length===8){if(!(0,a.default)(ve,"YY/MM/DD"))return!1}else if(!(0,a.default)(ve,"YYYY/MM/DD"))return!1;for(var Ee=re.split("").map(function(mt){return parseInt(mt,10)}),$e=[2,7,9,1,4,6,3,5,8,2,7,9],Ve=0,lt=0;lt<$e.length;lt++)Ve+=Ee[lt]*$e[lt];return Ve%11===10?Ee[12]===1:Ee[12]===Ve%11}return!0}function We(re){if(re.length===9){if(re=re.replace(/\W/,""),re.slice(6)==="000")return!1;var le=parseInt(re.slice(0,2),10);if(le>53)return!1;le<10?le="190".concat(le):le="19".concat(le);var ve=parseInt(re.slice(2,4),10);ve>50&&(ve-=50),ve<10&&(ve="0".concat(ve));var Ee="".concat(le,"/").concat(ve,"/").concat(re.slice(4,6));if(!(0,a.default)(Ee,"YYYY/MM/DD"))return!1}return!0}function Tt(re){var le=11-o.reverseMultiplyAndSum(re.split("").slice(0,7).map(function(ve){return parseInt(ve,10)}),8)%11;return le===10?parseInt(re[7],10)===0:le===parseInt(re[7],10)}function It(re){var le=re.slice(0);re.length>11&&(le=le.slice(2));var ve="",Ee=le.slice(2,4),$e=parseInt(le.slice(4,6),10);if(re.length>11)ve=re.slice(0,4);else if(ve=re.slice(0,2),re.length===11&&$e<60){var Ve=new Date().getFullYear().toString(),lt=parseInt(Ve.slice(0,2),10);if(Ve=parseInt(Ve,10),re[6]==="-")parseInt("".concat(lt).concat(ve),10)>Ve?ve="".concat(lt-1).concat(ve):ve="".concat(lt).concat(ve);else if(ve="".concat(lt-1).concat(ve),Ve-parseInt(ve,10)<100)return!1}$e>60&&($e-=60),$e<10&&($e="0".concat($e));var mt="".concat(ve,"/").concat(Ee,"/").concat($e);if(mt.length===8){if(!(0,a.default)(mt,"YY/MM/DD"))return!1}else if(!(0,a.default)(mt,"YYYY/MM/DD"))return!1;return o.luhnCheck(re.replace(/\W/,""))}function nt(re){for(var le=re.split("").map(function(Ve){return parseInt(Ve,10)}),ve=[-1,5,7,9,4,6,10,5,7],Ee=0,$e=0;$e<ve.length;$e++)Ee+=le[$e]*ve[$e];return Ee%11===10?le[9]===0:le[9]===Ee%11}var dt={"bg-BG":/^\d{10}$/,"cs-CZ":/^\d{6}\/{0,1}\d{3,4}$/,"de-AT":/^\d{9}$/,"de-DE":/^[1-9]\d{10}$/,"dk-DK":/^\d{6}-{0,1}\d{4}$/,"el-CY":/^[09]\d{7}[A-Z]$/,"el-GR":/^([0-4]|[7-9])\d{8}$/,"en-CA":/^\d{9}$/,"en-GB":/^\d{10}$|^(?!GB|NK|TN|ZZ)(?![DFIQUV])[A-Z](?![DFIQUVO])[A-Z]\d{6}[ABCD ]$/i,"en-IE":/^\d{7}[A-W][A-IW]{0,1}$/i,"en-US":/^\d{2}[- ]{0,1}\d{7}$/,"es-AR":/(20|23|24|27|30|33|34)[0-9]{8}[0-9]/,"es-ES":/^(\d{0,8}|[XYZKLM]\d{7})[A-HJ-NP-TV-Z]$/i,"et-EE":/^[1-6]\d{6}(00[1-9]|0[1-9][0-9]|[1-6][0-9]{2}|70[0-9]|710)\d$/,"fi-FI":/^\d{6}[-+A]\d{3}[0-9A-FHJ-NPR-Y]$/i,"fr-BE":/^\d{11}$/,"fr-FR":/^[0-3]\d{12}$|^[0-3]\d\s\d{2}(\s\d{3}){3}$/,"fr-LU":/^\d{13}$/,"hr-HR":/^\d{11}$/,"hu-HU":/^8\d{9}$/,"it-IT":/^[A-Z]{6}[L-NP-V0-9]{2}[A-EHLMPRST][L-NP-V0-9]{2}[A-ILMZ][L-NP-V0-9]{3}[A-Z]$/i,"lv-LV":/^\d{6}-{0,1}\d{5}$/,"mt-MT":/^\d{3,7}[APMGLHBZ]$|^([1-8])\1\d{7}$/i,"nl-NL":/^\d{9}$/,"pl-PL":/^\d{10,11}$/,"pt-BR":/(?:^\d{11}$)|(?:^\d{14}$)/,"pt-PT":/^\d{9}$/,"ro-RO":/^\d{13}$/,"sk-SK":/^\d{6}\/{0,1}\d{3,4}$/,"sl-SI":/^[1-9]\d{7}$/,"sv-SE":/^(\d{6}[-+]{0,1}\d{4}|(18|19|20)\d{6}[-+]{0,1}\d{4})$/,"uk-UA":/^\d{10}$/};dt["lb-LU"]=dt["fr-LU"],dt["lt-LT"]=dt["et-EE"],dt["nl-BE"]=dt["fr-BE"],dt["fr-CA"]=dt["en-CA"];var bt={"bg-BG":k,"cs-CZ":E,"de-AT":R,"de-DE":O,"dk-DK":I,"el-CY":L,"el-GR":N,"en-CA":A,"en-IE":H,"en-US":z,"es-AR":Q,"es-ES":J,"et-EE":ie,"fi-FI":ee,"fr-BE":de,"fr-FR":ue,"fr-LU":se,"hr-HR":pe,"hu-HU":Ce,"it-IT":P,"lv-LV":ne,"mt-MT":U,"nl-NL":fe,"pl-PL":Ae,"pt-BR":Te,"pt-PT":rt,"ro-RO":Ge,"sk-SK":We,"sl-SI":Tt,"sv-SE":It,"uk-UA":nt};bt["lb-LU"]=bt["fr-LU"],bt["lt-LT"]=bt["et-EE"],bt["nl-BE"]=bt["fr-BE"],bt["fr-CA"]=bt["en-CA"];var Et=/[-\\\/!@#$%\^&\*\(\)\+\=\[\]]+/g,Nt={"de-AT":Et,"de-DE":/[\/\\]/g,"fr-BE":Et};Nt["nl-BE"]=Nt["fr-BE"];function yt(re){var le=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"en-US";(0,r.default)(re);var ve=re.slice(0);if(le in dt)return le in Nt&&(ve=ve.replace(Nt[le],"")),dt[le].test(ve)?le in bt?bt[le](ve):!0:!1;throw new Error("Invalid locale '".concat(le,"'"))}e.exports=t.default,e.exports.default=t.default}(MA,MA.exports)),MA.exports}var Mm={},OU;function Hue(){if(OU)return Mm;OU=1,Object.defineProperty(Mm,"__esModule",{value:!0}),Mm.default=r,Mm.locales=void 0;var e=t(gt());function t(o){return o&&o.__esModule?o:{default:o}}var n={"am-AM":/^(\+?374|0)(33|4[134]|55|77|88|9[13-689])\d{6}$/,"ar-AE":/^((\+?971)|0)?5[024568]\d{7}$/,"ar-BH":/^(\+?973)?(3|6)\d{7}$/,"ar-DZ":/^(\+?213|0)(5|6|7)\d{8}$/,"ar-LB":/^(\+?961)?((3|81)\d{6}|7\d{7})$/,"ar-EG":/^((\+?20)|0)?1[0125]\d{8}$/,"ar-IQ":/^(\+?964|0)?7[0-9]\d{8}$/,"ar-JO":/^(\+?962|0)?7[789]\d{7}$/,"ar-KW":/^(\+?965)([569]\d{7}|41\d{6})$/,"ar-LY":/^((\+?218)|0)?(9[1-6]\d{7}|[1-8]\d{7,9})$/,"ar-MA":/^(?:(?:\+|00)212|0)[5-7]\d{8}$/,"ar-OM":/^((\+|00)968)?(9[1-9])\d{6}$/,"ar-PS":/^(\+?970|0)5[6|9](\d{7})$/,"ar-SA":/^(!?(\+?966)|0)?5\d{8}$/,"ar-SD":/^((\+?249)|0)?(9[012369]|1[012])\d{7}$/,"ar-SY":/^(!?(\+?963)|0)?9\d{8}$/,"ar-TN":/^(\+?216)?[2459]\d{7}$/,"az-AZ":/^(\+994|0)(10|5[015]|7[07]|99)\d{7}$/,"bs-BA":/^((((\+|00)3876)|06))((([0-3]|[5-6])\d{6})|(4\d{7}))$/,"be-BY":/^(\+?375)?(24|25|29|33|44)\d{7}$/,"bg-BG":/^(\+?359|0)?8[789]\d{7}$/,"bn-BD":/^(\+?880|0)1[13456789][0-9]{8}$/,"ca-AD":/^(\+376)?[346]\d{5}$/,"cs-CZ":/^(\+?420)? ?[1-9][0-9]{2} ?[0-9]{3} ?[0-9]{3}$/,"da-DK":/^(\+?45)?\s?\d{2}\s?\d{2}\s?\d{2}\s?\d{2}$/,"de-DE":/^((\+49|0)1)(5[0-25-9]\d|6([23]|0\d?)|7([0-57-9]|6\d))\d{7,9}$/,"de-AT":/^(\+43|0)\d{1,4}\d{3,12}$/,"de-CH":/^(\+41|0)([1-9])\d{1,9}$/,"de-LU":/^(\+352)?((6\d1)\d{6})$/,"dv-MV":/^(\+?960)?(7[2-9]|9[1-9])\d{5}$/,"el-GR":/^(\+?30|0)?6(8[5-9]|9(?![26])[0-9])\d{7}$/,"el-CY":/^(\+?357?)?(9(9|6)\d{6})$/,"en-AI":/^(\+?1|0)264(?:2(35|92)|4(?:6[1-2]|76|97)|5(?:3[6-9]|8[1-4])|7(?:2(4|9)|72))\d{4}$/,"en-AU":/^(\+?61|0)4\d{8}$/,"en-AG":/^(?:\+1|1)268(?:464|7(?:1[3-9]|[28]\d|3[0246]|64|7[0-689]))\d{4}$/,"en-BM":/^(\+?1)?441(((3|7)\d{6}$)|(5[0-3][0-9]\d{4}$)|(59\d{5}$))/,"en-BS":/^(\+?1[-\s]?|0)?\(?242\)?[-\s]?\d{3}[-\s]?\d{4}$/,"en-GB":/^(\+?44|0)7[1-9]\d{8}$/,"en-GG":/^(\+?44|0)1481\d{6}$/,"en-GH":/^(\+233|0)(20|50|24|54|27|57|26|56|23|53|28|55|59)\d{7}$/,"en-GY":/^(\+592|0)6\d{6}$/,"en-HK":/^(\+?852[-\s]?)?[456789]\d{3}[-\s]?\d{4}$/,"en-MO":/^(\+?853[-\s]?)?[6]\d{3}[-\s]?\d{4}$/,"en-IE":/^(\+?353|0)8[356789]\d{7}$/,"en-IN":/^(\+?91|0)?[6789]\d{9}$/,"en-JM":/^(\+?876)?\d{7}$/,"en-KE":/^(\+?254|0)(7|1)\d{8}$/,"fr-CF":/^(\+?236| ?)(70|75|77|72|21|22)\d{6}$/,"en-SS":/^(\+?211|0)(9[1257])\d{7}$/,"en-KI":/^((\+686|686)?)?( )?((6|7)(2|3|8)[0-9]{6})$/,"en-KN":/^(?:\+1|1)869(?:46\d|48[89]|55[6-8]|66\d|76[02-7])\d{4}$/,"en-LS":/^(\+?266)(22|28|57|58|59|27|52)\d{6}$/,"en-MT":/^(\+?356|0)?(99|79|77|21|27|22|25)[0-9]{6}$/,"en-MU":/^(\+?230|0)?\d{8}$/,"en-MW":/^(\+?265|0)(((77|88|31|99|98|21)\d{7})|(((111)|1)\d{6})|(32000\d{4}))$/,"en-NA":/^(\+?264|0)(6|8)\d{7}$/,"en-NG":/^(\+?234|0)?[789]\d{9}$/,"en-NZ":/^(\+?64|0)[28]\d{7,9}$/,"en-PG":/^(\+?675|0)?(7\d|8[18])\d{6}$/,"en-PK":/^((00|\+)?92|0)3[0-6]\d{8}$/,"en-PH":/^(09|\+639)\d{9}$/,"en-RW":/^(\+?250|0)?[7]\d{8}$/,"en-SG":/^(\+65)?[3689]\d{7}$/,"en-SL":/^(\+?232|0)\d{8}$/,"en-TZ":/^(\+?255|0)?[67]\d{8}$/,"en-UG":/^(\+?256|0)?[7]\d{8}$/,"en-US":/^((\+1|1)?( |-)?)?(\([2-9][0-9]{2}\)|[2-9][0-9]{2})( |-)?([2-9][0-9]{2}( |-)?[0-9]{4})$/,"en-ZA":/^(\+?27|0)\d{9}$/,"en-ZM":/^(\+?26)?0[79][567]\d{7}$/,"en-ZW":/^(\+263)[0-9]{9}$/,"en-BW":/^(\+?267)?(7[1-8]{1})\d{6}$/,"es-AR":/^\+?549(11|[2368]\d)\d{8}$/,"es-BO":/^(\+?591)?(6|7)\d{7}$/,"es-CO":/^(\+?57)?3(0(0|1|2|4|5)|1\d|2[0-4]|5(0|1))\d{7}$/,"es-CL":/^(\+?56|0)[2-9]\d{1}\d{7}$/,"es-CR":/^(\+506)?[2-8]\d{7}$/,"es-CU":/^(\+53|0053)?5\d{7}$/,"es-DO":/^(\+?1)?8[024]9\d{7}$/,"es-HN":/^(\+?504)?[9|8|3|2]\d{7}$/,"es-EC":/^(\+?593|0)([2-7]|9[2-9])\d{7}$/,"es-ES":/^(\+?34)?[6|7]\d{8}$/,"es-GT":/^(\+?502)?[2|6|7]\d{7}$/,"es-PE":/^(\+?51)?9\d{8}$/,"es-MX":/^(\+?52)?(1|01)?\d{10,11}$/,"es-NI":/^(\+?505)\d{7,8}$/,"es-PA":/^(\+?507)\d{7,8}$/,"es-PY":/^(\+?595|0)9[9876]\d{7}$/,"es-SV":/^(\+?503)?[67]\d{7}$/,"es-UY":/^(\+598|0)9[1-9][\d]{6}$/,"es-VE":/^(\+?58)?(2|4)\d{9}$/,"et-EE":/^(\+?372)?\s?(5|8[1-4])\s?([0-9]\s?){6,7}$/,"fa-IR":/^(\+?98[\-\s]?|0)9[0-39]\d[\-\s]?\d{3}[\-\s]?\d{4}$/,"fi-FI":/^(\+?358|0)\s?(4[0-6]|50)\s?(\d\s?){4,8}$/,"fj-FJ":/^(\+?679)?\s?\d{3}\s?\d{4}$/,"fo-FO":/^(\+?298)?\s?\d{2}\s?\d{2}\s?\d{2}$/,"fr-BF":/^(\+226|0)[67]\d{7}$/,"fr-BJ":/^(\+229)\d{8}$/,"fr-CD":/^(\+?243|0)?(8|9)\d{8}$/,"fr-CM":/^(\+?237)6[0-9]{8}$/,"fr-FR":/^(\+?33|0)[67]\d{8}$/,"fr-GF":/^(\+?594|0|00594)[67]\d{8}$/,"fr-GP":/^(\+?590|0|00590)[67]\d{8}$/,"fr-MQ":/^(\+?596|0|00596)[67]\d{8}$/,"fr-PF":/^(\+?689)?8[789]\d{6}$/,"fr-RE":/^(\+?262|0|00262)[67]\d{8}$/,"fr-WF":/^(\+681)?\d{6}$/,"he-IL":/^(\+972|0)([23489]|5[012345689]|77)[1-9]\d{6}$/,"hu-HU":/^(\+?36|06)(20|30|31|50|70)\d{7}$/,"id-ID":/^(\+?62|0)8(1[123456789]|2[1238]|3[1238]|5[12356789]|7[78]|9[56789]|8[123456789])([\s?|\d]{5,11})$/,"ir-IR":/^(\+98|0)?9\d{9}$/,"it-IT":/^(\+?39)?\s?3\d{2} ?\d{6,7}$/,"it-SM":/^((\+378)|(0549)|(\+390549)|(\+3780549))?6\d{5,9}$/,"ja-JP":/^(\+81[ \-]?(\(0\))?|0)[6789]0[ \-]?\d{4}[ \-]?\d{4}$/,"ka-GE":/^(\+?995)?(79\d{7}|5\d{8})$/,"kk-KZ":/^(\+?7|8)?7\d{9}$/,"kl-GL":/^(\+?299)?\s?\d{2}\s?\d{2}\s?\d{2}$/,"ko-KR":/^((\+?82)[ \-]?)?0?1([0|1|6|7|8|9]{1})[ \-]?\d{3,4}[ \-]?\d{4}$/,"ky-KG":/^(\+996\s?)?(22[0-9]|50[0-9]|55[0-9]|70[0-9]|75[0-9]|77[0-9]|880|990|995|996|997|998)\s?\d{3}\s?\d{3}$/,"lt-LT":/^(\+370|8)\d{8}$/,"lv-LV":/^(\+?371)2\d{7}$/,"mg-MG":/^((\+?261|0)(2|3)\d)?\d{7}$/,"mn-MN":/^(\+|00|011)?976(77|81|88|91|94|95|96|99)\d{6}$/,"my-MM":/^(\+?959|09|9)(2[5-7]|3[1-2]|4[0-5]|6[6-9]|7[5-9]|9[6-9])[0-9]{7}$/,"ms-MY":/^(\+?60|0)1(([0145](-|\s)?\d{7,8})|([236-9](-|\s)?\d{7}))$/,"mz-MZ":/^(\+?258)?8[234567]\d{7}$/,"nb-NO":/^(\+?47)?[49]\d{7}$/,"ne-NP":/^(\+?977)?9[78]\d{8}$/,"nl-BE":/^(\+?32|0)4\d{8}$/,"nl-NL":/^(((\+|00)?31\(0\))|((\+|00)?31)|0)6{1}\d{8}$/,"nl-AW":/^(\+)?297(56|59|64|73|74|99)\d{5}$/,"nn-NO":/^(\+?47)?[49]\d{7}$/,"pl-PL":/^(\+?48)? ?([5-8]\d|45) ?\d{3} ?\d{2} ?\d{2}$/,"pt-BR":/^((\+?55\ ?[1-9]{2}\ ?)|(\+?55\ ?\([1-9]{2}\)\ ?)|(0[1-9]{2}\ ?)|(\([1-9]{2}\)\ ?)|([1-9]{2}\ ?))((\d{4}\-?\d{4})|(9[1-9]{1}\d{3}\-?\d{4}))$/,"pt-PT":/^(\+?351)?9[1236]\d{7}$/,"pt-AO":/^(\+244)\d{9}$/,"ro-MD":/^(\+?373|0)((6(0|1|2|6|7|8|9))|(7(6|7|8|9)))\d{6}$/,"ro-RO":/^(\+?40|0)\s?7\d{2}(\/|\s|\.|-)?\d{3}(\s|\.|-)?\d{3}$/,"ru-RU":/^(\+?7|8)?9\d{9}$/,"si-LK":/^(?:0|94|\+94)?(7(0|1|2|4|5|6|7|8)( |-)?)\d{7}$/,"sl-SI":/^(\+386\s?|0)(\d{1}\s?\d{3}\s?\d{2}\s?\d{2}|\d{2}\s?\d{3}\s?\d{3})$/,"sk-SK":/^(\+?421)? ?[1-9][0-9]{2} ?[0-9]{3} ?[0-9]{3}$/,"so-SO":/^(\+?252|0)((6[0-9])\d{7}|(7[1-9])\d{7})$/,"sq-AL":/^(\+355|0)6[2-9]\d{7}$/,"sr-RS":/^(\+3816|06)[- \d]{5,9}$/,"sv-SE":/^(\+?46|0)[\s\-]?7[\s\-]?[02369]([\s\-]?\d){7}$/,"tg-TJ":/^(\+?992)?[5][5]\d{7}$/,"th-TH":/^(\+66|66|0)\d{9}$/,"tr-TR":/^(\+?90|0)?5\d{9}$/,"tk-TM":/^(\+993|993|8)\d{8}$/,"uk-UA":/^(\+?38)?0(50|6[36-8]|7[357]|9[1-9])\d{7}$/,"uz-UZ":/^(\+?998)?(6[125-79]|7[1-69]|88|9\d)\d{7}$/,"vi-VN":/^((\+?84)|0)((3([2-9]))|(5([25689]))|(7([0|6-9]))|(8([1-9]))|(9([0-9])))([0-9]{7})$/,"zh-CN":/^((\+|00)86)?(1[3-9]|9[28])\d{9}$/,"zh-TW":/^(\+?886\-?|0)?9\d{8}$/,"dz-BT":/^(\+?975|0)?(17|16|77|02)\d{6}$/,"ar-YE":/^(((\+|00)9677|0?7)[0137]\d{7}|((\+|00)967|0)[1-7]\d{6})$/,"ar-EH":/^(\+?212|0)[\s\-]?(5288|5289)[\s\-]?\d{5}$/,"fa-AF":/^(\+93|0)?(2{1}[0-8]{1}|[3-5]{1}[0-4]{1})(\d{7})$/,"mk-MK":/^(\+?389|0)?((?:2[2-9]\d{6}|(?:3[1-4]|4[2-8])\d{6}|500\d{5}|5[2-9]\d{6}|7[0-9][2-9]\d{5}|8[1-9]\d{6}|800\d{5}|8009\d{4}))$/};n["en-CA"]=n["en-US"],n["fr-CA"]=n["en-CA"],n["fr-BE"]=n["nl-BE"],n["zh-HK"]=n["en-HK"],n["zh-MO"]=n["en-MO"],n["ga-IE"]=n["en-IE"],n["fr-CH"]=n["de-CH"],n["it-CH"]=n["fr-CH"];function r(o,a,l){if((0,e.default)(o),l&&l.strictMode&&!o.startsWith("+"))return!1;if(Array.isArray(a))return a.some(function(p){if(n.hasOwnProperty(p)){var y=n[p];if(y.test(o))return!0}return!1});if(a in n)return n[a].test(o);if(!a||a==="any"){for(var d in n)if(n.hasOwnProperty(d)){var h=n[d];if(h.test(o))return!0}return!1}throw new Error("Invalid locale '".concat(a,"'"))}return Mm.locales=Object.keys(n),Mm}var IA={exports:{}},DU;function que(){return DU||(DU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^(0x)[0-9a-f]{40}$/i;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(IA,IA.exports)),IA.exports}var $A={exports:{}},MU;function Gue(){return MU||(MU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=o(Na()),r=o(gt());function o(h){return h&&h.__esModule?h:{default:h}}function a(h){var p="\\d{".concat(h.digits_after_decimal[0],"}");h.digits_after_decimal.forEach(function(R,O){O!==0&&(p="".concat(p,"|\\d{").concat(R,"}"))});var y="(".concat(h.symbol.replace(/\W/,function(R){return"\\".concat(R)}),")").concat(h.require_symbol?"":"?"),m="-?",x="[1-9]\\d*",_="[1-9]\\d{0,2}(\\".concat(h.thousands_separator,"\\d{3})*"),w=["0",x,_],k="(".concat(w.join("|"),")?"),A="(\\".concat(h.decimal_separator,"(").concat(p,"))").concat(h.require_decimal?"":"?"),E=k+(h.allow_decimal||h.require_decimal?A:"");return h.allow_negatives&&!h.parens_for_negatives&&(h.negative_sign_after_digits?E+=m:h.negative_sign_before_digits&&(E=m+E)),h.allow_negative_sign_placeholder?E="( (?!\\-))?".concat(E):h.allow_space_after_symbol?E=" ?".concat(E):h.allow_space_after_digits&&(E+="( (?!$))?"),h.symbol_after_digits?E+=y:E=y+E,h.allow_negatives&&(h.parens_for_negatives?E="(\\(".concat(E,"\\)|").concat(E,")"):h.negative_sign_before_digits||h.negative_sign_after_digits||(E=m+E)),new RegExp("^(?!-? )(?=.*\\d)".concat(E,"$"))}var l={symbol:"$",require_symbol:!1,allow_space_after_symbol:!1,symbol_after_digits:!1,allow_negatives:!0,parens_for_negatives:!1,negative_sign_before_digits:!1,negative_sign_after_digits:!1,allow_negative_sign_placeholder:!1,thousands_separator:",",decimal_separator:".",allow_decimal:!0,require_decimal:!1,digits_after_decimal:[2],allow_space_after_digits:!1};function d(h,p){return(0,r.default)(h),p=(0,n.default)(p,l),a(p).test(h)}e.exports=t.default,e.exports.default=t.default}($A,$A.exports)),$A.exports}var BA={exports:{}},IU;function Vue(){return IU||(IU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var n=r(gt());function r(d){return d&&d.__esModule?d:{default:d}}var o=/^(bc1|tb1|bc1p|tb1p)[ac-hj-np-z02-9]{39,58}$/,a=/^(1|2|3|m)[A-HJ-NP-Za-km-z1-9]{25,39}$/;function l(d){return(0,n.default)(d),o.test(d)||a.test(d)}e.exports=t.default,e.exports.default=t.default}(BA,BA.exports)),BA.exports}var Im={},$U;function Yue(){if($U)return Im;$U=1,Object.defineProperty(Im,"__esModule",{value:!0}),Im.isFreightContainerID=void 0,Im.isISO6346=o;var e=t(gt());function t(a){return a&&a.__esModule?a:{default:a}}var n=/^[A-Z]{3}(U[0-9]{7})|([J,Z][0-9]{6,7})$/,r=/^[0-9]$/;function o(a){if((0,e.default)(a),a=a.toUpperCase(),!n.test(a))return!1;if(a.length===11){for(var l=0,d=0;d<a.length-1;d++)if(r.test(a[d]))l+=a[d]*Math.pow(2,d);else{var h=void 0,p=a.charCodeAt(d)-55;p<11?h=p:p>=11&&p<=20?h=12+p%11:p>=21&&p<=30?h=23+p%21:h=34+p%31,l+=h*Math.pow(2,d)}var y=l%11;return y===10&&(y=0),Number(a[a.length-1])===y}return!0}return Im.isFreightContainerID=o,Im}var LA={exports:{}},BU;function Zue(){return BU||(BU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=new Set(["aa","ab","ae","af","ak","am","an","ar","as","av","ay","az","az","ba","be","bg","bh","bi","bm","bn","bo","br","bs","ca","ce","ch","co","cr","cs","cu","cv","cy","da","de","dv","dz","ee","el","en","eo","es","et","eu","fa","ff","fi","fj","fo","fr","fy","ga","gd","gl","gn","gu","gv","ha","he","hi","ho","hr","ht","hu","hy","hz","ia","id","ie","ig","ii","ik","io","is","it","iu","ja","jv","ka","kg","ki","kj","kk","kl","km","kn","ko","kr","ks","ku","kv","kw","ky","la","lb","lg","li","ln","lo","lt","lu","lv","mg","mh","mi","mk","ml","mn","mr","ms","mt","my","na","nb","nd","ne","ng","nl","nn","no","nr","nv","ny","oc","oj","om","or","os","pa","pi","pl","ps","pt","qu","rm","rn","ro","ru","rw","sa","sc","sd","se","sg","si","sk","sl","sm","sn","so","sq","sr","ss","st","su","sv","sw","ta","te","tg","th","ti","tk","tl","tn","to","tr","ts","tt","tw","ty","ug","uk","ur","uz","ve","vi","vo","wa","wo","xh","yi","yo","za","zh","zu"]);function a(l){return(0,n.default)(l),o.has(l)}e.exports=t.default,e.exports.default=t.default}(LA,LA.exports)),LA.exports}var NA={exports:{}},LU;function Que(){return LU||(LU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=r(gt());function r(h){return h&&h.__esModule?h:{default:h}}var o=/^([\+-]?\d{4}(?!\d{2}\b))((-?)((0[1-9]|1[0-2])(\3([12]\d|0[1-9]|3[01]))?|W([0-4]\d|5[0-3])(-?[1-7])?|(00[1-9]|0[1-9]\d|[12]\d{2}|3([0-5]\d|6[1-6])))([T\s]((([01]\d|2[0-3])((:?)[0-5]\d)?|24:?00)([\.,]\d+(?!:))?)?(\17[0-5]\d([\.,]\d+)?)?([zZ]|([\+-])([01]\d|2[0-3]):?([0-5]\d)?)?)?)?$/,a=/^([\+-]?\d{4}(?!\d{2}\b))((-?)((0[1-9]|1[0-2])(\3([12]\d|0[1-9]|3[01]))?|W([0-4]\d|5[0-3])(-?[1-7])?|(00[1-9]|0[1-9]\d|[12]\d{2}|3([0-5]\d|6[1-6])))([T]((([01]\d|2[0-3])((:?)[0-5]\d)?|24:?00)([\.,]\d+(?!:))?)?(\17[0-5]\d([\.,]\d+)?)?([zZ]|([\+-])([01]\d|2[0-3]):?([0-5]\d)?)?)?)?$/,l=function(p){var y=p.match(/^(\d{4})-?(\d{3})([ T]{1}\.*|$)/);if(y){var m=Number(y[1]),x=Number(y[2]);return m%4===0&&m%100!==0||m%400===0?x<=366:x<=365}var _=p.match(/(\d{4})-?(\d{0,2})-?(\d*)/).map(Number),w=_[1],k=_[2],A=_[3],E=k&&"0".concat(k).slice(-2),R=A&&"0".concat(A).slice(-2),O=new Date("".concat(w,"-").concat(E||"01","-").concat(R||"01"));return k&&A?O.getUTCFullYear()===w&&O.getUTCMonth()+1===k&&O.getUTCDate()===A:!0};function d(h){var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};(0,n.default)(h);var y=p.strictSeparator?a.test(h):o.test(h);return y&&p.strict?l(h):y}e.exports=t.default,e.exports.default=t.default}(NA,NA.exports)),NA.exports}var zA={exports:{}},NU;function Kue(){return NU||(NU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=E;var n=r(gt());function r(R){return R&&R.__esModule?R:{default:R}}var o=/[0-9]{4}/,a=/(0[1-9]|1[0-2])/,l=/([12]\d|0[1-9]|3[01])/,d=/([01][0-9]|2[0-3])/,h=/[0-5][0-9]/,p=/([0-5][0-9]|60)/,y=/(\.[0-9]+)?/,m=new RegExp("[-+]".concat(d.source,":").concat(h.source)),x=new RegExp("([zZ]|".concat(m.source,")")),_=new RegExp("".concat(d.source,":").concat(h.source,":").concat(p.source).concat(y.source)),w=new RegExp("".concat(o.source,"-").concat(a.source,"-").concat(l.source)),k=new RegExp("".concat(_.source).concat(x.source)),A=new RegExp("^".concat(w.source,"[ tT]").concat(k.source,"$"));function E(R){return(0,n.default)(R),A.test(R)}e.exports=t.default,e.exports.default=t.default}(zA,zA.exports)),zA.exports}var $m={},zU;function Wue(){if(zU)return $m;zU=1,Object.defineProperty($m,"__esModule",{value:!0}),$m.ScriptCodes=void 0,$m.default=r;var e=t(gt());function t(o){return o&&o.__esModule?o:{default:o}}var n=new Set(["Adlm","Afak","Aghb","Ahom","Arab","Aran","Armi","Armn","Avst","Bali","Bamu","Bass","Batk","Beng","Bhks","Blis","Bopo","Brah","Brai","Bugi","Buhd","Cakm","Cans","Cari","Cham","Cher","Chis","Chrs","Cirt","Copt","Cpmn","Cprt","Cyrl","Cyrs","Deva","Diak","Dogr","Dsrt","Dupl","Egyd","Egyh","Egyp","Elba","Elym","Ethi","Gara","Geok","Geor","Glag","Gong","Gonm","Goth","Gran","Grek","Gujr","Gukh","Guru","Hanb","Hang","Hani","Hano","Hans","Hant","Hatr","Hebr","Hira","Hluw","Hmng","Hmnp","Hrkt","Hung","Inds","Ital","Jamo","Java","Jpan","Jurc","Kali","Kana","Kawi","Khar","Khmr","Khoj","Kitl","Kits","Knda","Kore","Kpel","Krai","Kthi","Lana","Laoo","Latf","Latg","Latn","Leke","Lepc","Limb","Lina","Linb","Lisu","Loma","Lyci","Lydi","Mahj","Maka","Mand","Mani","Marc","Maya","Medf","Mend","Merc","Mero","Mlym","Modi","Mong","Moon","Mroo","Mtei","Mult","Mymr","Nagm","Nand","Narb","Nbat","Newa","Nkdb","Nkgb","Nkoo","Nshu","Ogam","Olck","Onao","Orkh","Orya","Osge","Osma","Ougr","Palm","Pauc","Pcun","Pelm","Perm","Phag","Phli","Phlp","Phlv","Phnx","Plrd","Piqd","Prti","Psin","Qaaa","Qaab","Qaac","Qaad","Qaae","Qaaf","Qaag","Qaah","Qaai","Qaaj","Qaak","Qaal","Qaam","Qaan","Qaao","Qaap","Qaaq","Qaar","Qaas","Qaat","Qaau","Qaav","Qaaw","Qaax","Qaay","Qaaz","Qaba","Qabb","Qabc","Qabd","Qabe","Qabf","Qabg","Qabh","Qabi","Qabj","Qabk","Qabl","Qabm","Qabn","Qabo","Qabp","Qabq","Qabr","Qabs","Qabt","Qabu","Qabv","Qabw","Qabx","Ranj","Rjng","Rohg","Roro","Runr","Samr","Sara","Sarb","Saur","Sgnw","Shaw","Shrd","Shui","Sidd","Sidt","Sind","Sinh","Sogd","Sogo","Sora","Soyo","Sund","Sunu","Sylo","Syrc","Syre","Syrj","Syrn","Tagb","Takr","Tale","Talu","Taml","Tang","Tavt","Tayo","Telu","Teng","Tfng","Tglg","Thaa","Thai","Tibt","Tirh","Tnsa","Todr","Tols","Toto","Tutg","Ugar","Vaii","Visp","Vith","Wara","Wcho","Wole","Xpeo","Xsux","Yezi","Yiii","Zanb","Zinh","Zmth","Zsye","Zsym","Zxxx","Zyyy","Zzzz"]);function r(o){return(0,e.default)(o),n.has(o)}return $m.ScriptCodes=n,$m}var FA={exports:{}},FU;function Xue(){return FU||(FU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=new Set(["AFG","ALA","ALB","DZA","ASM","AND","AGO","AIA","ATA","ATG","ARG","ARM","ABW","AUS","AUT","AZE","BHS","BHR","BGD","BRB","BLR","BEL","BLZ","BEN","BMU","BTN","BOL","BES","BIH","BWA","BVT","BRA","IOT","BRN","BGR","BFA","BDI","KHM","CMR","CAN","CPV","CYM","CAF","TCD","CHL","CHN","CXR","CCK","COL","COM","COG","COD","COK","CRI","CIV","HRV","CUB","CUW","CYP","CZE","DNK","DJI","DMA","DOM","ECU","EGY","SLV","GNQ","ERI","EST","ETH","FLK","FRO","FJI","FIN","FRA","GUF","PYF","ATF","GAB","GMB","GEO","DEU","GHA","GIB","GRC","GRL","GRD","GLP","GUM","GTM","GGY","GIN","GNB","GUY","HTI","HMD","VAT","HND","HKG","HUN","ISL","IND","IDN","IRN","IRQ","IRL","IMN","ISR","ITA","JAM","JPN","JEY","JOR","KAZ","KEN","KIR","PRK","KOR","KWT","KGZ","LAO","LVA","LBN","LSO","LBR","LBY","LIE","LTU","LUX","MAC","MKD","MDG","MWI","MYS","MDV","MLI","MLT","MHL","MTQ","MRT","MUS","MYT","MEX","FSM","MDA","MCO","MNG","MNE","MSR","MAR","MOZ","MMR","NAM","NRU","NPL","NLD","NCL","NZL","NIC","NER","NGA","NIU","NFK","MNP","NOR","OMN","PAK","PLW","PSE","PAN","PNG","PRY","PER","PHL","PCN","POL","PRT","PRI","QAT","REU","ROU","RUS","RWA","BLM","SHN","KNA","LCA","MAF","SPM","VCT","WSM","SMR","STP","SAU","SEN","SRB","SYC","SLE","SGP","SXM","SVK","SVN","SLB","SOM","ZAF","SGS","SSD","ESP","LKA","SDN","SUR","SJM","SWZ","SWE","CHE","SYR","TWN","TJK","TZA","THA","TLS","TGO","TKL","TON","TTO","TUN","TUR","TKM","TCA","TUV","UGA","UKR","ARE","GBR","USA","UMI","URY","UZB","VUT","VEN","VNM","VGB","VIR","WLF","ESH","YEM","ZMB","ZWE"]);function a(l){return(0,n.default)(l),o.has(l.toUpperCase())}e.exports=t.default,e.exports.default=t.default}(FA,FA.exports)),FA.exports}var UA={exports:{}},UU;function Jue(){return UU||(UU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=new Set(["004","008","010","012","016","020","024","028","031","032","036","040","044","048","050","051","052","056","060","064","068","070","072","074","076","084","086","090","092","096","100","104","108","112","116","120","124","132","136","140","144","148","152","156","158","162","166","170","174","175","178","180","184","188","191","192","196","203","204","208","212","214","218","222","226","231","232","233","234","238","239","242","246","248","250","254","258","260","262","266","268","270","275","276","288","292","296","300","304","308","312","316","320","324","328","332","334","336","340","344","348","352","356","360","364","368","372","376","380","384","388","392","398","400","404","408","410","414","417","418","422","426","428","430","434","438","440","442","446","450","454","458","462","466","470","474","478","480","484","492","496","498","499","500","504","508","512","516","520","524","528","531","533","534","535","540","548","554","558","562","566","570","574","578","580","581","583","584","585","586","591","598","600","604","608","612","616","620","624","626","630","634","638","642","643","646","652","654","659","660","662","663","666","670","674","678","682","686","688","690","694","702","703","704","705","706","710","716","724","728","729","732","740","744","748","752","756","760","762","764","768","772","776","780","784","788","792","795","796","798","800","804","807","818","826","831","832","833","834","840","850","854","858","860","862","876","882","887","894"]);function a(l){return(0,n.default)(l),o.has(l)}e.exports=t.default,e.exports.default=t.default}(UA,UA.exports)),UA.exports}var Bm={},jU;function ece(){if(jU)return Bm;jU=1,Object.defineProperty(Bm,"__esModule",{value:!0}),Bm.CurrencyCodes=void 0,Bm.default=r;var e=t(gt());function t(o){return o&&o.__esModule?o:{default:o}}var n=new Set(["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BOV","BRL","BSD","BTN","BWP","BYN","BZD","CAD","CDF","CHE","CHF","CHW","CLF","CLP","CNY","COP","COU","CRC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRU","MUR","MVR","MWK","MXN","MXV","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SLE","SLL","SOS","SRD","SSP","STN","SVC","SYP","SZL","THB","TJS","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","USN","UYI","UYU","UYW","UZS","VED","VES","VND","VUV","WST","XAF","XAG","XAU","XBA","XBB","XBC","XBD","XCD","XDR","XOF","XPD","XPF","XPT","XSU","XTS","XUA","XXX","YER","ZAR","ZMW","ZWL"]);function r(o){return(0,e.default)(o),n.has(o.toUpperCase())}return Bm.CurrencyCodes=n,Bm}var jA={exports:{}},PU;function tce(){return PU||(PU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=h;var n=o(gt()),r=o(Na());function o(p){return p&&p.__esModule?p:{default:p}}var a=/^[A-Z2-7]+=*$/,l=/^[A-HJKMNP-TV-Z0-9]+$/,d={crockford:!1};function h(p,y){if((0,n.default)(p),y=(0,r.default)(y,d),y.crockford)return l.test(p);var m=p.length;return!!(m%8===0&&a.test(p))}e.exports=t.default,e.exports.default=t.default}(jA,jA.exports)),jA.exports}var PA={exports:{}},HU;function nce(){return HU||(HU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^[A-HJ-NP-Za-km-z1-9]*$/;function a(l){return(0,n.default)(l),!!o.test(l)}e.exports=t.default,e.exports.default=t.default}(PA,PA.exports)),PA.exports}var HA={exports:{}},qU;function rce(){return qU||(qU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=r(gt());function r(h){return h&&h.__esModule?h:{default:h}}var o=/^[a-z]+\/[a-z0-9\-\+\._]+$/i,a=/^[a-z\-]+=[a-z0-9\-]+$/i,l=/^[a-z0-9!\$&'\(\)\*\+,;=\-\._~:@\/\?%\s]*$/i;function d(h){(0,n.default)(h);var p=h.split(",");if(p.length<2)return!1;var y=p.shift().trim().split(";"),m=y.shift();if(m.slice(0,5)!=="data:")return!1;var x=m.slice(5);if(x!==""&&!o.test(x))return!1;for(var _=0;_<y.length;_++)if(!(_===y.length-1&&y[_].toLowerCase()==="base64")&&!a.test(y[_]))return!1;for(var w=0;w<p.length;w++)if(!l.test(p[w]))return!1;return!0}e.exports=t.default,e.exports.default=t.default}(HA,HA.exports)),HA.exports}var qA={exports:{}},GU;function ice(){return GU||(GU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/(?:^magnet:\?|[^?&]&)xt(?:\.1)?=urn:(?:(?:aich|bitprint|btih|ed2k|ed2khash|kzhash|md5|sha1|tree:tiger):[a-z0-9]{32}(?:[a-z0-9]{8})?|btmh:1220[a-z0-9]{64})(?:$|&)/i;function a(l){return(0,n.default)(l),l.indexOf("magnet:?")!==0?!1:o.test(l)}e.exports=t.default,e.exports.default=t.default}(qA,qA.exports)),qA.exports}var GA={exports:{}},VA={exports:{}},YA={exports:{}},VU;function YU(){return VU||(VU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a,l){if((0,n.default)(a),l){var d=new RegExp("[".concat(l.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"]+$"),"g");return a.replace(d,"")}for(var h=a.length-1;/\s/.test(a.charAt(h));)h-=1;return a.slice(0,h+1)}e.exports=t.default,e.exports.default=t.default}(YA,YA.exports)),YA.exports}var ZA={exports:{}},ZU;function QU(){return ZU||(ZU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a,l){(0,n.default)(a);var d=l?new RegExp("^[".concat(l.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"]+"),"g"):/^\s+/g;return a.replace(d,"")}e.exports=t.default,e.exports.default=t.default}(ZA,ZA.exports)),ZA.exports}var KU;function WU(){return KU||(KU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=o(YU()),r=o(QU());function o(l){return l&&l.__esModule?l:{default:l}}function a(l,d){return(0,n.default)((0,r.default)(l,d),d)}e.exports=t.default,e.exports.default=t.default}(VA,VA.exports)),VA.exports}var XU;function oce(){return XU||(XU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=w;var n=a(WU()),r=a(mF()),o=a(gt());function a(k){return k&&k.__esModule?k:{default:k}}function l(k,A){return p(k)||h(k,A)||m(k,A)||d()}function d(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
478
478
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function h(k,A){var E=k==null?null:typeof Symbol<"u"&&k[Symbol.iterator]||k["@@iterator"];if(E!=null){var R,O,I,L,N=[],H=!0,V=!1;try{if(I=(E=E.call(k)).next,A!==0)for(;!(H=(R=I.call(E)).done)&&(N.push(R.value),N.length!==A);H=!0);}catch(W){V=!0,O=W}finally{try{if(!H&&E.return!=null&&(L=E.return(),Object(L)!==L))return}finally{if(V)throw O}}return N}}function p(k){if(Array.isArray(k))return k}function y(k,A){var E=typeof Symbol<"u"&&k[Symbol.iterator]||k["@@iterator"];if(!E){if(Array.isArray(k)||(E=m(k))||A){E&&(k=E);var R=0,O=function(){};return{s:O,n:function(){return R>=k.length?{done:!0}:{done:!1,value:k[R++]}},e:function(V){throw V},f:O}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
479
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var I,L=!0,N=!1;return{s:function(){E=E.call(k)},n:function(){var V=E.next();return L=V.done,V},e:function(V){N=!0,I=V},f:function(){try{L||E.return==null||E.return()}finally{if(N)throw I}}}}function m(k,A){if(k){if(typeof k=="string")return x(k,A);var E={}.toString.call(k).slice(8,-1);return E==="Object"&&k.constructor&&(E=k.constructor.name),E==="Map"||E==="Set"?Array.from(k):E==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(E)?x(k,A):void 0}}function x(k,A){(A==null||A>k.length)&&(A=k.length);for(var E=0,R=Array(A);E<A;E++)R[E]=k[E];return R}function _(k){var A=new Set(["subject","body","cc","bcc"]),E={cc:"",bcc:""},R=!1,O=k.split("&");if(O.length>4)return!1;var I=y(O),L;try{for(I.s();!(L=I.n()).done;){var N=L.value,H=N.split("="),V=l(H,2),W=V[0],z=V[1];if(W&&!A.has(W)){R=!0;break}z&&(W==="cc"||W==="bcc")&&(E[W]=z),W&&A.delete(W)}}catch(Q){I.e(Q)}finally{I.f()}return R?!1:E}function w(k,A){if((0,o.default)(k),k.indexOf("mailto:")!==0)return!1;var E=k.replace("mailto:","").split("?"),R=l(E,2),O=R[0],I=R[1],L=I===void 0?"":I;if(!O&&!L)return!0;var N=_(L);return N?"".concat(O,",").concat(N.cc,",").concat(N.bcc).split(",").every(function(H){return H=(0,n.default)(H," "),H?(0,r.default)(H,A):!0}):!1}e.exports=t.default,e.exports.default=t.default}(GA,GA.exports)),GA.exports}var QA={exports:{}},JU;function ace(){return JU||(JU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=r(gt());function r(h){return h&&h.__esModule?h:{default:h}}var o=/^(application|audio|font|image|message|model|multipart|text|video)\/[a-zA-Z0-9\.\-\+_]{1,100}$/i,a=/^text\/[a-zA-Z0-9\.\-\+]{1,100};\s?charset=("[a-zA-Z0-9\.\-\+\s]{0,70}"|[a-zA-Z0-9\.\-\+]{0,70})(\s?\([a-zA-Z0-9\.\-\+\s]{1,20}\))?$/i,l=/^multipart\/[a-zA-Z0-9\.\-\+]{1,100}(;\s?(boundary|charset)=("[a-zA-Z0-9\.\-\+\s]{0,70}"|[a-zA-Z0-9\.\-\+]{0,70})(\s?\([a-zA-Z0-9\.\-\+\s]{1,20}\))?){0,2}$/i;function d(h){return(0,n.default)(h),o.test(h)||a.test(h)||l.test(h)}e.exports=t.default,e.exports.default=t.default}(QA,QA.exports)),QA.exports}var KA={exports:{}},ej;function sce(){return ej||(ej=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=y;var n=o(gt()),r=o(Na());function o(m){return m&&m.__esModule?m:{default:m}}var a=/^\(?[+-]?(90(\.0+)?|[1-8]?\d(\.\d+)?)$/,l=/^\s?[+-]?(180(\.0+)?|1[0-7]\d(\.\d+)?|\d{1,2}(\.\d+)?)\)?$/,d=/^(([1-8]?\d)\D+([1-5]?\d|60)\D+([1-5]?\d|60)(\.\d+)?|90\D+0\D+0)\D+[NSns]?$/i,h=/^\s*([1-7]?\d{1,2}\D+([1-5]?\d|60)\D+([1-5]?\d|60)(\.\d+)?|180\D+0\D+0)\D+[EWew]?$/i,p={checkDMS:!1};function y(m,x){if((0,n.default)(m),x=(0,r.default)(x,p),!m.includes(","))return!1;var _=m.split(",");return _[0].startsWith("(")&&!_[1].endsWith(")")||_[1].endsWith(")")&&!_[0].startsWith("(")?!1:x.checkDMS?d.test(_[0])&&h.test(_[1]):a.test(_[0])&&l.test(_[1])}e.exports=t.default,e.exports.default=t.default}(KA,KA.exports)),KA.exports}var Lm={},tj;function lce(){if(tj)return Lm;tj=1,Object.defineProperty(Lm,"__esModule",{value:!0}),Lm.default=d,Lm.locales=void 0;var e=t(gt());function t(h){return h&&h.__esModule?h:{default:h}}var n=/^\d{3}$/,r=/^\d{4}$/,o=/^\d{5}$/,a=/^\d{6}$/,l={AD:/^AD\d{3}$/,AT:r,AU:r,AZ:/^AZ\d{4}$/,BA:/^([7-8]\d{4}$)/,BE:r,BG:r,BR:/^\d{5}-?\d{3}$/,BY:/^2[1-4]\d{4}$/,CA:/^[ABCEGHJKLMNPRSTVXY]\d[ABCEGHJ-NPRSTV-Z][\s\-]?\d[ABCEGHJ-NPRSTV-Z]\d$/i,CH:r,CN:/^(0[1-7]|1[012356]|2[0-7]|3[0-6]|4[0-7]|5[1-7]|6[1-7]|7[1-5]|8[1345]|9[09])\d{4}$/,CO:/^(05|08|11|13|15|17|18|19|20|23|25|27|41|44|47|50|52|54|63|66|68|70|73|76|81|85|86|88|91|94|95|97|99)(\d{4})$/,CZ:/^\d{3}\s?\d{2}$/,DE:o,DK:r,DO:o,DZ:o,EE:o,ES:/^(5[0-2]{1}|[0-4]{1}\d{1})\d{3}$/,FI:o,FR:/^\d{2}\s?\d{3}$/,GB:/^(gir\s?0aa|[a-z]{1,2}\d[\da-z]?\s?(\d[a-z]{2})?)$/i,GR:/^\d{3}\s?\d{2}$/,HR:/^([1-5]\d{4}$)/,HT:/^HT\d{4}$/,HU:r,ID:o,IE:/^(?!.*(?:o))[A-Za-z]\d[\dw]\s\w{4}$/i,IL:/^(\d{5}|\d{7})$/,IN:/^((?!10|29|35|54|55|65|66|86|87|88|89)[1-9][0-9]{5})$/,IR:/^(?!(\d)\1{3})[13-9]{4}[1346-9][013-9]{5}$/,IS:n,IT:o,JP:/^\d{3}\-\d{4}$/,KE:o,KR:/^(\d{5}|\d{6})$/,LI:/^(948[5-9]|949[0-7])$/,LT:/^LT\-\d{5}$/,LU:r,LV:/^LV\-\d{4}$/,LK:o,MG:n,MX:o,MT:/^[A-Za-z]{3}\s{0,1}\d{4}$/,MY:o,NL:/^[1-9]\d{3}\s?(?!sa|sd|ss)[a-z]{2}$/i,NO:r,NP:/^(10|21|22|32|33|34|44|45|56|57)\d{3}$|^(977)$/i,NZ:r,PL:/^\d{2}\-\d{3}$/,PR:/^00[679]\d{2}([ -]\d{4})?$/,PT:/^\d{4}\-\d{3}?$/,RO:a,RU:a,SA:o,SE:/^[1-9]\d{2}\s?\d{2}$/,SG:a,SI:r,SK:/^\d{3}\s?\d{2}$/,TH:o,TN:r,TW:/^\d{3}(\d{2})?$/,UA:o,US:/^\d{5}(-\d{4})?$/,ZA:r,ZM:o};Lm.locales=Object.keys(l);function d(h,p){if((0,e.default)(h),p in l)return l[p].test(h);if(p==="any"){for(var y in l)if(l.hasOwnProperty(y)){var m=l[y];if(m.test(h))return!0}return!1}throw new Error("Invalid locale '".concat(p,"'"))}return Lm}var WA={exports:{}},nj;function uce(){return nj||(nj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a){return(0,n.default)(a),a.replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\//g,"&#x2F;").replace(/\\/g,"&#x5C;").replace(/`/g,"&#96;")}e.exports=t.default,e.exports.default=t.default}(WA,WA.exports)),WA.exports}var XA={exports:{}},rj;function cce(){return rj||(rj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a){return(0,n.default)(a),a.replace(/&quot;/g,'"').replace(/&#x27;/g,"'").replace(/&lt;/g,"<").replace(/&gt;/g,">").replace(/&#x2F;/g,"/").replace(/&#x5C;/g,"\\").replace(/&#96;/g,"`").replace(/&amp;/g,"&")}e.exports=t.default,e.exports.default=t.default}(XA,XA.exports)),XA.exports}var JA={exports:{}},ek={exports:{}},ij;function oj(){return ij||(ij=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a,l){return(0,n.default)(a),a.replace(new RegExp("[".concat(l,"]+"),"g"),"")}e.exports=t.default,e.exports.default=t.default}(ek,ek.exports)),ek.exports}var aj;function fce(){return aj||(aj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=o(gt()),r=o(oj());function o(l){return l&&l.__esModule?l:{default:l}}function a(l,d){(0,n.default)(l);var h=d?"\\x00-\\x09\\x0B\\x0C\\x0E-\\x1F\\x7F":"\\x00-\\x1F\\x7F";return(0,r.default)(l,h)}e.exports=t.default,e.exports.default=t.default}(JA,JA.exports)),JA.exports}var tk={exports:{}},sj;function dce(){return sj||(sj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a,l){return(0,n.default)(a),a.replace(new RegExp("[^".concat(l,"]+"),"g"),"")}e.exports=t.default,e.exports.default=t.default}(tk,tk.exports)),tk.exports}var nk={exports:{}},lj;function hce(){return lj||(lj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a,l){(0,n.default)(a);for(var d=a.length-1;d>=0;d--)if(l.indexOf(a[d])===-1)return!1;return!0}e.exports=t.default,e.exports.default=t.default}(nk,nk.exports)),nk.exports}var rk={exports:{}},uj;function pce(){return uj||(uj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=y;var n=r(Na());function r(m){return m&&m.__esModule?m:{default:m}}var o={all_lowercase:!0,gmail_lowercase:!0,gmail_remove_dots:!0,gmail_remove_subaddress:!0,gmail_convert_googlemaildotcom:!0,outlookdotcom_lowercase:!0,outlookdotcom_remove_subaddress:!0,yahoo_lowercase:!0,yahoo_remove_subaddress:!0,yandex_lowercase:!0,yandex_convert_yandexru:!0,icloud_lowercase:!0,icloud_remove_subaddress:!0},a=["icloud.com","me.com"],l=["hotmail.at","hotmail.be","hotmail.ca","hotmail.cl","hotmail.co.il","hotmail.co.nz","hotmail.co.th","hotmail.co.uk","hotmail.com","hotmail.com.ar","hotmail.com.au","hotmail.com.br","hotmail.com.gr","hotmail.com.mx","hotmail.com.pe","hotmail.com.tr","hotmail.com.vn","hotmail.cz","hotmail.de","hotmail.dk","hotmail.es","hotmail.fr","hotmail.hu","hotmail.id","hotmail.ie","hotmail.in","hotmail.it","hotmail.jp","hotmail.kr","hotmail.lv","hotmail.my","hotmail.ph","hotmail.pt","hotmail.sa","hotmail.sg","hotmail.sk","live.be","live.co.uk","live.com","live.com.ar","live.com.mx","live.de","live.es","live.eu","live.fr","live.it","live.nl","msn.com","outlook.at","outlook.be","outlook.cl","outlook.co.il","outlook.co.nz","outlook.co.th","outlook.com","outlook.com.ar","outlook.com.au","outlook.com.br","outlook.com.gr","outlook.com.pe","outlook.com.tr","outlook.com.vn","outlook.cz","outlook.de","outlook.dk","outlook.es","outlook.fr","outlook.hu","outlook.id","outlook.ie","outlook.in","outlook.it","outlook.jp","outlook.kr","outlook.lv","outlook.my","outlook.ph","outlook.pt","outlook.sa","outlook.sg","outlook.sk","passport.com"],d=["rocketmail.com","yahoo.ca","yahoo.co.uk","yahoo.com","yahoo.de","yahoo.fr","yahoo.in","yahoo.it","ymail.com"],h=["yandex.ru","yandex.ua","yandex.kz","yandex.com","yandex.by","ya.ru"];function p(m){return m.length>1?m:""}function y(m,x){x=(0,n.default)(x,o);var _=m.split("@"),w=_.pop(),k=_.join("@"),A=[k,w];if(A[1]=A[1].toLowerCase(),A[1]==="gmail.com"||A[1]==="googlemail.com"){if(x.gmail_remove_subaddress&&(A[0]=A[0].split("+")[0]),x.gmail_remove_dots&&(A[0]=A[0].replace(/\.+/g,p)),!A[0].length)return!1;(x.all_lowercase||x.gmail_lowercase)&&(A[0]=A[0].toLowerCase()),A[1]=x.gmail_convert_googlemaildotcom?"gmail.com":A[1]}else if(a.indexOf(A[1])>=0){if(x.icloud_remove_subaddress&&(A[0]=A[0].split("+")[0]),!A[0].length)return!1;(x.all_lowercase||x.icloud_lowercase)&&(A[0]=A[0].toLowerCase())}else if(l.indexOf(A[1])>=0){if(x.outlookdotcom_remove_subaddress&&(A[0]=A[0].split("+")[0]),!A[0].length)return!1;(x.all_lowercase||x.outlookdotcom_lowercase)&&(A[0]=A[0].toLowerCase())}else if(d.indexOf(A[1])>=0){if(x.yahoo_remove_subaddress){var E=A[0].split("-");A[0]=E.length>1?E.slice(0,-1).join("-"):E[0]}if(!A[0].length)return!1;(x.all_lowercase||x.yahoo_lowercase)&&(A[0]=A[0].toLowerCase())}else h.indexOf(A[1])>=0?((x.all_lowercase||x.yandex_lowercase)&&(A[0]=A[0].toLowerCase()),A[1]=x.yandex_convert_yandexru?"yandex.ru":A[1]):x.all_lowercase&&(A[0]=A[0].toLowerCase());return A.join("@")}e.exports=t.default,e.exports.default=t.default}(rk,rk.exports)),rk.exports}var ik={exports:{}},cj;function gce(){return cj||(cj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^[^\s-_](?!.*?[-_]{2,})[a-z0-9-\\][^\s]*[^-_\s]$/;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(ik,ik.exports)),ik.exports}var ok={exports:{}},fj;function mce(){return fj||(fj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o={"cs-CZ":function(d){return/^(([ABCDEFHIJKLMNPRSTUVXYZ]|[0-9])-?){5,8}$/.test(d)},"de-DE":function(d){return/^((A|AA|AB|AC|AE|AH|AK|AM|AN|AΓ–|AP|AS|AT|AU|AW|AZ|B|BA|BB|BC|BE|BF|BH|BI|BK|BL|BM|BN|BO|BΓ–|BS|BT|BZ|C|CA|CB|CE|CO|CR|CW|D|DA|DD|DE|DH|DI|DL|DM|DN|DO|DU|DW|DZ|E|EA|EB|ED|EE|EF|EG|EH|EI|EL|EM|EN|ER|ES|EU|EW|F|FB|FD|FF|FG|FI|FL|FN|FO|FR|FS|FT|FÜ|FW|FZ|G|GA|GC|GD|GE|GF|GG|GI|GK|GL|GM|GN|GΓ–|GP|GR|GS|GT|GÜ|GV|GW|GZ|H|HA|HB|HC|HD|HE|HF|HG|HH|HI|HK|HL|HM|HN|HO|HP|HR|HS|HU|HV|HX|HY|HZ|IK|IL|IN|IZ|J|JE|JL|K|KA|KB|KC|KE|KF|KG|KH|KI|KK|KL|KM|KN|KO|KR|KS|KT|KU|KW|KY|L|LA|LB|LC|LD|LF|LG|LH|LI|LL|LM|LN|LΓ–|LP|LR|LU|M|MA|MB|MC|MD|ME|MG|MH|MI|MK|ML|MM|MN|MO|MQ|MR|MS|MÜ|MW|MY|MZ|N|NB|ND|NE|NF|NH|NI|NK|NM|NΓ–|NP|NR|NT|NU|NW|NY|NZ|OA|OB|OC|OD|OE|OF|OG|OH|OK|OL|OP|OS|OZ|P|PA|PB|PE|PF|PI|PL|PM|PN|PR|PS|PW|PZ|R|RA|RC|RD|RE|RG|RH|RI|RL|RM|RN|RO|RP|RS|RT|RU|RV|RW|RZ|S|SB|SC|SE|SG|SI|SK|SL|SM|SN|SO|SP|SR|ST|SU|SW|SY|SZ|TE|TF|TG|TO|TP|TR|TS|TT|TÜ|ÜB|UE|UH|UL|UM|UN|V|VB|VG|VK|VR|VS|W|WA|WB|WE|WF|WI|WK|WL|WM|WN|WO|WR|WS|WT|WÜ|WW|WZ|Z|ZE|ZI|ZP|ZR|ZW|ZZ)[- ]?[A-Z]{1,2}[- ]?\d{1,4}|(ABG|ABI|AIB|AIC|ALF|ALZ|ANA|ANG|ANK|APD|ARN|ART|ASL|ASZ|AUR|AZE|BAD|BAR|BBG|BCH|BED|BER|BGD|BGL|BID|BIN|BIR|BIT|BIW|BKS|BLB|BLK|BNA|BOG|BOH|BOR|BOT|BRA|BRB|BRG|BRK|BRL|BRV|BSB|BSK|BTF|BÜD|BUL|BÜR|BÜS|BÜZ|CAS|CHA|CLP|CLZ|COC|COE|CUX|DAH|DAN|DAU|DBR|DEG|DEL|DGF|DIL|DIN|DIZ|DKB|DLG|DON|DUD|DÜW|EBE|EBN|EBS|ECK|EIC|EIL|EIN|EIS|EMD|EMS|ERB|ERH|ERK|ERZ|ESB|ESW|FDB|FDS|FEU|FFB|FKB|FLΓ–|FOR|FRG|FRI|FRW|FTL|FÜS|GAN|GAP|GDB|GEL|GEO|GER|GHA|GHC|GLA|GMN|GNT|GOA|GOH|GRA|GRH|GRI|GRM|GRZ|GTH|GUB|GUN|GVM|HAB|HAL|HAM|HAS|HBN|HBS|HCH|HDH|HDL|HEB|HEF|HEI|HER|HET|HGN|HGW|HHM|HIG|HIP|HMÜ|HOG|HOH|HOL|HOM|HOR|HΓ–S|HOT|HRO|HSK|HST|HVL|HWI|IGB|ILL|JÜL|KEH|KEL|KEM|KIB|KLE|KLZ|KΓ–N|KΓ–T|KΓ–Z|KRU|KÜN|KUS|KYF|LAN|LAU|LBS|LBZ|LDK|LDS|LEO|LER|LEV|LIB|LIF|LIP|LΓ–B|LOS|LRO|LSZ|LÜN|LUP|LWL|MAB|MAI|MAK|MAL|MED|MEG|MEI|MEK|MEL|MER|MET|MGH|MGN|MHL|MIL|MKK|MOD|MOL|MON|MOS|MSE|MSH|MSP|MST|MTK|MTL|MÜB|MÜR|MYK|MZG|NAB|NAI|NAU|NDH|NEA|NEB|NEC|NEN|NES|NEW|NMB|NMS|NOH|NOL|NOM|NOR|NVP|NWM|OAL|OBB|OBG|OCH|OHA|Γ–HR|OHV|OHZ|OPR|OSL|OVI|OVL|OVP|PAF|PAN|PAR|PCH|PEG|PIR|PLΓ–|PRÜ|QFT|QLB|RDG|REG|REH|REI|RID|RIE|ROD|ROF|ROK|ROL|ROS|ROT|ROW|RSL|RÜD|RÜG|SAB|SAD|SAN|SAW|SBG|SBK|SCZ|SDH|SDL|SDT|SEB|SEE|SEF|SEL|SFB|SFT|SGH|SHA|SHG|SHK|SHL|SIG|SIM|SLE|SLF|SLK|SLN|SLS|SLÜ|SLZ|SMÜ|SOB|SOG|SOK|SΓ–M|SON|SPB|SPN|SRB|SRO|STA|STB|STD|STE|STL|SUL|SÜW|SWA|SZB|TBB|TDO|TET|TIR|TΓ–L|TUT|UEM|UER|UFF|USI|VAI|VEC|VER|VIB|VIE|VIT|VOH|WAF|WAK|WAN|WAR|WAT|WBS|WDA|WEL|WEN|WER|WES|WHV|WIL|WIS|WIT|WIZ|WLG|WMS|WND|WOB|WOH|WOL|WOR|WOS|WRN|WSF|WST|WSW|WTL|WTM|WUG|WÜM|WUN|WUR|WZL|ZEL|ZIG)[- ]?(([A-Z][- ]?\d{1,4})|([A-Z]{2}[- ]?\d{1,3})))[- ]?(E|H)?$/.test(d)},"de-LI":function(d){return/^FL[- ]?\d{1,5}[UZ]?$/.test(d)},"en-IN":function(d){return/^[A-Z]{2}[ -]?[0-9]{1,2}(?:[ -]?[A-Z])(?:[ -]?[A-Z]*)?[ -]?[0-9]{4}$/.test(d)},"en-SG":function(d){return/^[A-Z]{3}[ -]?[\d]{4}[ -]?[A-Z]{1}$/.test(d)},"es-AR":function(d){return/^(([A-Z]{2} ?[0-9]{3} ?[A-Z]{2})|([A-Z]{3} ?[0-9]{3}))$/.test(d)},"fi-FI":function(d){return/^(?=.{4,7})(([A-Z]{1,3}|[0-9]{1,3})[\s-]?([A-Z]{1,3}|[0-9]{1,5}))$/.test(d)},"hu-HU":function(d){return/^((((?!AAA)(([A-NPRSTVZWXY]{1})([A-PR-Z]{1})([A-HJ-NPR-Z]))|(A[ABC]I)|A[ABC]O|A[A-W]Q|BPI|BPO|UCO|UDO|XAO)-(?!000)\d{3})|(M\d{6})|((CK|DT|CD|HC|H[ABEFIKLMNPRSTVX]|MA|OT|R[A-Z]) \d{2}-\d{2})|(CD \d{3}-\d{3})|(C-(C|X) \d{4})|(X-(A|B|C) \d{4})|(([EPVZ]-\d{5}))|(S A[A-Z]{2} \d{2})|(SP \d{2}-\d{2}))$/.test(d)},"pt-BR":function(d){return/^[A-Z]{3}[ -]?[0-9][A-Z][0-9]{2}|[A-Z]{3}[ -]?[0-9]{4}$/.test(d)},"pt-PT":function(d){return/^([A-Z]{2}|[0-9]{2})[ -Β·]?([A-Z]{2}|[0-9]{2})[ -Β·]?([A-Z]{2}|[0-9]{2})$/.test(d)},"sq-AL":function(d){return/^[A-Z]{2}[- ]?((\d{3}[- ]?(([A-Z]{2})|T))|(R[- ]?\d{3}))$/.test(d)},"sv-SE":function(d){return/^[A-HJ-PR-UW-Z]{3} ?[\d]{2}[A-HJ-PR-UW-Z1-9]$|(^[A-ZÅÄÖ ]{2,7}$)/.test(d.trim())},"en-PK":function(d){return/(^[A-Z]{2}((\s|-){0,1})[0-9]{3,4}((\s|-)[0-9]{2}){0,1}$)|(^[A-Z]{3}((\s|-){0,1})[0-9]{3,4}((\s|-)[0-9]{2}){0,1}$)|(^[A-Z]{4}((\s|-){0,1})[0-9]{3,4}((\s|-)[0-9]{2}){0,1}$)|(^[A-Z]((\s|-){0,1})[0-9]{4}((\s|-)[0-9]{2}){0,1}$)/.test(d.trim())}};function a(l,d){if((0,n.default)(l),d in o)return o[d](l);if(d==="any"){for(var h in o){var p=o[h];if(p(l))return!0}return!1}throw new Error("Invalid locale '".concat(d,"'"))}e.exports=t.default,e.exports.default=t.default}(ok,ok.exports)),ok.exports}var ak={exports:{}},dj;function vce(){return dj||(dj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=_;var n=o(Na()),r=o(gt());function o(w){return w&&w.__esModule?w:{default:w}}var a=/^[A-Z]$/,l=/^[a-z]$/,d=/^[0-9]$/,h=/^[-#!$@Β£%^&*()_+|~=`{}\[\]:";'<>?,.\/\\ ]$/,p={minLength:8,minLowercase:1,minUppercase:1,minNumbers:1,minSymbols:1,returnScore:!1,pointsPerUnique:1,pointsPerRepeat:.5,pointsForContainingLower:10,pointsForContainingUpper:10,pointsForContainingNumber:10,pointsForContainingSymbol:10};function y(w){var k={};return Array.from(w).forEach(function(A){var E=k[A];E?k[A]+=1:k[A]=1}),k}function m(w){var k=y(w),A={length:w.length,uniqueChars:Object.keys(k).length,uppercaseCount:0,lowercaseCount:0,numberCount:0,symbolCount:0};return Object.keys(k).forEach(function(E){a.test(E)?A.uppercaseCount+=k[E]:l.test(E)?A.lowercaseCount+=k[E]:d.test(E)?A.numberCount+=k[E]:h.test(E)&&(A.symbolCount+=k[E])}),A}function x(w,k){var A=0;return A+=w.uniqueChars*k.pointsPerUnique,A+=(w.length-w.uniqueChars)*k.pointsPerRepeat,w.lowercaseCount>0&&(A+=k.pointsForContainingLower),w.uppercaseCount>0&&(A+=k.pointsForContainingUpper),w.numberCount>0&&(A+=k.pointsForContainingNumber),w.symbolCount>0&&(A+=k.pointsForContainingSymbol),A}function _(w){var k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;(0,r.default)(w);var A=m(w);return k=(0,n.default)(k||{},p),k.returnScore?x(A,k):A.length>=k.minLength&&A.lowercaseCount>=k.minLowercase&&A.uppercaseCount>=k.minUppercase&&A.numberCount>=k.minNumbers&&A.symbolCount>=k.minSymbols}e.exports=t.default,e.exports.default=t.default}(ak,ak.exports)),ak.exports}var Nm={},hj;function yce(){if(hj)return Nm;hj=1;function e(m){"@babel/helpers - typeof";return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(x){return typeof x}:function(x){return x&&typeof Symbol=="function"&&x.constructor===Symbol&&x!==Symbol.prototype?"symbol":typeof x},e(m)}Object.defineProperty(Nm,"__esModule",{value:!0}),Nm.default=y,Nm.vatMatchers=void 0;var t=a(gt()),n=o(TU());function r(m){if(typeof WeakMap!="function")return null;var x=new WeakMap,_=new WeakMap;return(r=function(k){return k?_:x})(m)}function o(m,x){if(m&&m.__esModule)return m;if(m===null||e(m)!="object"&&typeof m!="function")return{default:m};var _=r(x);if(_&&_.has(m))return _.get(m);var w={__proto__:null},k=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var A in m)if(A!=="default"&&{}.hasOwnProperty.call(m,A)){var E=k?Object.getOwnPropertyDescriptor(m,A):null;E&&(E.get||E.set)?Object.defineProperty(w,A,E):w[A]=m[A]}return w.default=m,_&&_.set(m,w),w}function a(m){return m&&m.__esModule?m:{default:m}}var l=function(x){var _=x.match(/^(AU)?(\d{11})$/);if(!_)return!1;var w=[10,1,3,5,7,9,11,13,15,17,19];x=x.replace(/^AU/,"");for(var k=(parseInt(x.slice(0,1),10)-1).toString()+x.slice(1),A=0,E=0;E<11;E++)A+=w[E]*k.charAt(E);return A!==0&&A%89===0},d=function(x){var _=function(k){var A=k.pop(),E=[5,4,3,2,7,6,5,4],R=(11-k.reduce(function(O,I,L){return O+I*E[L]},0)%11)%11;return A===R};return/^(CHE[- ]?)?(\d{9}|(\d{3}\.\d{3}\.\d{3})|(\d{3} \d{3} \d{3})) ?(TVA|MWST|IVA)?$/.test(x)&&_(x.match(/\d/g).map(function(w){return+w}))},h=function(x){var _=x.match(/^(PT)?(\d{9})$/);if(!_)return!1;var w=_[2],k=11-n.reverseMultiplyAndSum(w.split("").slice(0,8).map(function(A){return parseInt(A,10)}),9)%11;return k>9?parseInt(w[8],10)===0:k===parseInt(w[8],10)},p=Nm.vatMatchers={AT:function(x){return/^(AT)?U\d{8}$/.test(x)},BE:function(x){return/^(BE)?\d{10}$/.test(x)},BG:function(x){return/^(BG)?\d{9,10}$/.test(x)},HR:function(x){return/^(HR)?\d{11}$/.test(x)},CY:function(x){return/^(CY)?\w{9}$/.test(x)},CZ:function(x){return/^(CZ)?\d{8,10}$/.test(x)},DK:function(x){return/^(DK)?\d{8}$/.test(x)},EE:function(x){return/^(EE)?\d{9}$/.test(x)},FI:function(x){return/^(FI)?\d{8}$/.test(x)},FR:function(x){return/^(FR)?\w{2}\d{9}$/.test(x)},DE:function(x){return/^(DE)?\d{9}$/.test(x)},EL:function(x){return/^(EL)?\d{9}$/.test(x)},HU:function(x){return/^(HU)?\d{8}$/.test(x)},IE:function(x){return/^(IE)?\d{7}\w{1}(W)?$/.test(x)},IT:function(x){return/^(IT)?\d{11}$/.test(x)},LV:function(x){return/^(LV)?\d{11}$/.test(x)},LT:function(x){return/^(LT)?\d{9,12}$/.test(x)},LU:function(x){return/^(LU)?\d{8}$/.test(x)},MT:function(x){return/^(MT)?\d{8}$/.test(x)},NL:function(x){return/^(NL)?\d{9}B\d{2}$/.test(x)},PL:function(x){return/^(PL)?(\d{10}|(\d{3}-\d{3}-\d{2}-\d{2})|(\d{3}-\d{2}-\d{2}-\d{3}))$/.test(x)},PT:h,RO:function(x){return/^(RO)?\d{2,10}$/.test(x)},SK:function(x){return/^(SK)?\d{10}$/.test(x)},SI:function(x){return/^(SI)?\d{8}$/.test(x)},ES:function(x){return/^(ES)?\w\d{7}[A-Z]$/.test(x)},SE:function(x){return/^(SE)?\d{12}$/.test(x)},AL:function(x){return/^(AL)?\w{9}[A-Z]$/.test(x)},MK:function(x){return/^(MK)?\d{13}$/.test(x)},AU:l,BY:function(x){return/^(УНП )?\d{9}$/.test(x)},CA:function(x){return/^(CA)?\d{9}$/.test(x)},IS:function(x){return/^(IS)?\d{5,6}$/.test(x)},IN:function(x){return/^(IN)?\d{15}$/.test(x)},ID:function(x){return/^(ID)?(\d{15}|(\d{2}.\d{3}.\d{3}.\d{1}-\d{3}.\d{3}))$/.test(x)},IL:function(x){return/^(IL)?\d{9}$/.test(x)},KZ:function(x){return/^(KZ)?\d{12}$/.test(x)},NZ:function(x){return/^(NZ)?\d{9}$/.test(x)},NG:function(x){return/^(NG)?(\d{12}|(\d{8}-\d{4}))$/.test(x)},NO:function(x){return/^(NO)?\d{9}MVA$/.test(x)},PH:function(x){return/^(PH)?(\d{12}|\d{3} \d{3} \d{3} \d{3})$/.test(x)},RU:function(x){return/^(RU)?(\d{10}|\d{12})$/.test(x)},SM:function(x){return/^(SM)?\d{5}$/.test(x)},SA:function(x){return/^(SA)?\d{15}$/.test(x)},RS:function(x){return/^(RS)?\d{9}$/.test(x)},CH:d,TR:function(x){return/^(TR)?\d{10}$/.test(x)},UA:function(x){return/^(UA)?\d{12}$/.test(x)},GB:function(x){return/^GB((\d{3} \d{4} ([0-8][0-9]|9[0-6]))|(\d{9} \d{3})|(((GD[0-4])|(HA[5-9]))[0-9]{2}))$/.test(x)},UZ:function(x){return/^(UZ)?\d{9}$/.test(x)},AR:function(x){return/^(AR)?\d{11}$/.test(x)},BO:function(x){return/^(BO)?\d{7}$/.test(x)},BR:function(x){return/^(BR)?((\d{2}.\d{3}.\d{3}\/\d{4}-\d{2})|(\d{3}.\d{3}.\d{3}-\d{2}))$/.test(x)},CL:function(x){return/^(CL)?\d{8}-\d{1}$/.test(x)},CO:function(x){return/^(CO)?\d{10}$/.test(x)},CR:function(x){return/^(CR)?\d{9,12}$/.test(x)},EC:function(x){return/^(EC)?\d{13}$/.test(x)},SV:function(x){return/^(SV)?\d{4}-\d{6}-\d{3}-\d{1}$/.test(x)},GT:function(x){return/^(GT)?\d{7}-\d{1}$/.test(x)},HN:function(x){return/^(HN)?$/.test(x)},MX:function(x){return/^(MX)?\w{3,4}\d{6}\w{3}$/.test(x)},NI:function(x){return/^(NI)?\d{3}-\d{6}-\d{4}\w{1}$/.test(x)},PA:function(x){return/^(PA)?$/.test(x)},PY:function(x){return/^(PY)?\d{6,8}-\d{1}$/.test(x)},PE:function(x){return/^(PE)?\d{11}$/.test(x)},DO:function(x){return/^(DO)?(\d{11}|(\d{3}-\d{7}-\d{1})|[1,4,5]{1}\d{8}|([1,4,5]{1})-\d{2}-\d{5}-\d{1})$/.test(x)},UY:function(x){return/^(UY)?\d{12}$/.test(x)},VE:function(x){return/^(VE)?[J,G,V,E]{1}-(\d{9}|(\d{8}-\d{1}))$/.test(x)}};function y(m,x){if((0,t.default)(m),(0,t.default)(x),x in p)return p[x](m);throw new Error("Invalid country code: '".concat(x,"'"))}return Nm}var pj;function xce(){return pj||(pj=1,function(e,t){function n(ce){"@babel/helpers - typeof";return n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Me){return typeof Me}:function(Me){return Me&&typeof Symbol=="function"&&Me.constructor===Symbol&&Me!==Symbol.prototype?"symbol":typeof Me},n(ce)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=ot(VD()),o=ot(eF()),a=ot(Ple()),l=ot(Hle()),d=ot(qle()),h=ot(Gle()),p=ot(Vle()),y=ot(mF()),m=ot(Yle()),x=ot(Zle()),_=ot(BE()),w=ot(Qle()),k=ot(YD()),A=ot(_F()),E=ot(Kle()),R=ot(Wle()),O=ot(Xle()),I=ot(Jle()),L=Kr(eue()),N=Kr(tue()),H=ot(nue()),V=Kr(rue()),W=ot(iue()),z=ot(oue()),Q=ot(aue()),J=ot(sue()),ie=ot(lue()),ee=ot(NF()),de=ot(FF()),ue=ot(uue()),se=ot(cue()),pe=ot(due()),Ce=ot(hue()),B=ot(ZD()),P=Kr(Xz()),ne=ot(gue()),U=ot(ZF()),fe=ot(mue()),Ae=ot(vue()),Te=ot(yue()),rt=ot(xue()),Ge=ot(bue()),We=ot(_ue()),Tt=Kr(Sue()),It=ot(wue()),nt=ot(Cue()),dt=ot(Eue()),bt=ot(Aue()),Et=ot(kue()),Nt=ot(Tue()),yt=ot(Rue()),re=ot(dF()),le=ot(Oue()),ve=ot(Due()),Ee=ot(Mue()),$e=ot(Iue()),Ve=ot($ue()),lt=ot(Bue()),mt=ot(bU()),_e=ot(Lue()),Re=ot(Nue()),Ct=ot(zue()),ct=ot(Fue()),Rt=ot(Uue()),Mt=ot(jue()),en=ot(Pue()),Qt=Kr(Hue()),gn=ot(que()),pt=ot(Gue()),Kt=ot(Vue()),_t=Yue(),Y=ot(Zue()),xe=ot(Que()),it=ot(Kue()),st=ot(Wue()),St=ot(rU()),Pt=ot(Xue()),Ht=ot(Jue()),Yt=ot(ece()),qt=ot(tce()),ln=ot(nce()),hr=ot(lU()),xr=ot(rce()),Ur=ot(ice()),nn=ot(oce()),yn=ot(ace()),fn=ot(sce()),ho=Kr(lce()),br=ot(QU()),us=ot(YU()),ji=ot(WU()),Ho=ot(uce()),Dt=ot(cce()),to=ot(fce()),rr=ot(dce()),Ro=ot(oj()),po=ot(hce()),qn=ot(pce()),ua=ot(gce()),Oi=ot(mce()),pr=ot(vce()),Br=ot(yce());function ca(ce){if(typeof WeakMap!="function")return null;var Me=new WeakMap,j=new WeakMap;return(ca=function(he){return he?j:Me})(ce)}function Kr(ce,Me){if(ce&&ce.__esModule)return ce;if(ce===null||n(ce)!="object"&&typeof ce!="function")return{default:ce};var j=ca(Me);if(j&&j.has(ce))return j.get(ce);var te={__proto__:null},he=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ke in ce)if(ke!=="default"&&{}.hasOwnProperty.call(ce,ke)){var we=he?Object.getOwnPropertyDescriptor(ce,ke):null;we&&(we.get||we.set)?Object.defineProperty(te,ke,we):te[ke]=ce[ke]}return te.default=ce,j&&j.set(ce,te),te}function ot(ce){return ce&&ce.__esModule?ce:{default:ce}}var Oe="13.15.0",at={version:Oe,toDate:r.default,toFloat:o.default,toInt:a.default,toBoolean:l.default,equals:d.default,contains:h.default,matches:p.default,isEmail:y.default,isURL:m.default,isMACAddress:x.default,isIP:_.default,isIPRange:w.default,isFQDN:k.default,isBoolean:R.default,isIBAN:Tt.default,isBIC:It.default,isAbaRouting:I.default,isAlpha:L.default,isAlphaLocales:L.locales,isAlphanumeric:N.default,isAlphanumericLocales:N.locales,isNumeric:H.default,isPassportNumber:V.default,passportNumberLocales:V.locales,isPort:W.default,isLowercase:z.default,isUppercase:Q.default,isAscii:ie.default,isFullWidth:ee.default,isHalfWidth:de.default,isVariableWidth:ue.default,isMultibyte:se.default,isSemVer:pe.default,isSurrogatePair:Ce.default,isInt:B.default,isIMEI:J.default,isFloat:P.default,isFloatLocales:P.locales,isDecimal:ne.default,isHexadecimal:U.default,isOctal:fe.default,isDivisibleBy:Ae.default,isHexColor:Te.default,isRgbColor:rt.default,isHSL:Ge.default,isISRC:We.default,isMD5:nt.default,isHash:dt.default,isJWT:bt.default,isJSON:Et.default,isEmpty:Nt.default,isLength:yt.default,isLocale:O.default,isByteLength:re.default,isULID:le.default,isUUID:ve.default,isMongoId:Ee.default,isAfter:$e.default,isBefore:Ve.default,isIn:lt.default,isLuhnNumber:mt.default,isCreditCard:_e.default,isIdentityCard:Re.default,isEAN:Ct.default,isISIN:ct.default,isISBN:Rt.default,isISSN:Mt.default,isMobilePhone:Qt.default,isMobilePhoneLocales:Qt.locales,isPostalCode:ho.default,isPostalCodeLocales:ho.locales,isEthereumAddress:gn.default,isCurrency:pt.default,isBtcAddress:Kt.default,isISO6346:_t.isISO6346,isFreightContainerID:_t.isFreightContainerID,isISO6391:Y.default,isISO8601:xe.default,isISO15924:st.default,isRFC3339:it.default,isISO31661Alpha2:St.default,isISO31661Alpha3:Pt.default,isISO31661Numeric:Ht.default,isISO4217:Yt.default,isBase32:qt.default,isBase58:ln.default,isBase64:hr.default,isDataURI:xr.default,isMagnetURI:Ur.default,isMailtoURI:nn.default,isMimeType:yn.default,isLatLong:fn.default,ltrim:br.default,rtrim:us.default,trim:ji.default,escape:Ho.default,unescape:Dt.default,stripLow:to.default,whitelist:rr.default,blacklist:Ro.default,isWhitelisted:po.default,normalizeEmail:qn.default,toString,isSlug:ua.default,isStrongPassword:pr.default,isTaxID:en.default,isDate:A.default,isTime:E.default,isLicensePlate:Oi.default,isVAT:Br.default,ibanLocales:Tt.locales};t.default=at,e.exports=t.default,e.exports.default=t.default}(yE,yE.exports)),yE.exports}var zm=xce();const tn={OPEN_STATE_CHANGE:"open_state_change",CHAT_BUTTON_CLICKED:"Chat button clicked",USER_FORM_FILLED:"User form filled",ADD_BULK_ITEM:"Add bulk item",USER_FORM_CLOSE:"user_form_close",CHECKOUT_CLICKED:"Checkout Clicked",ADD_TO_CART_CLICKED:"add to cart clicked",SUGGESTED_QUESTION_CLICKED:"Suggested Question Clicked",INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED:"Initial Leading Query Suggested Question Clicked",LEADING_QUERY_CLICKED:"Leading Query Clicked",COLLECTION_VIDEO_CLICKED:"Collection Video Clicked",COLLECTION_IMAGE_CLICKED:"Collection Image Clicked",VIEW_PRODUCT_CLICKED:"view product clicked",PRODUCT_VIDEO_CLICKED:"Product Video Clicked",PRODUCT_IMAGE_CLICKED:"Product Image Clicked",SHOW_SIMILAR_CLICKED:"show similar clicked",CHAT_MESSAGE_SENT:"chat_message_sent",CHAT_MESSAGE_TYPING_STARTED:"chat_message_typing_started",CHAT_MESSAGE_TYPING_ENDED:"chat_message_typing_ended",DISCOUNT_VIEWED:"discount_viewed",SHOPIFY_LINK_CLICKED:"shopify_link_clicked"},Qr={OPEN_STATE_CHANGE:"open_state_change"},gj=Z.createContext(null),Fd=()=>{const e=Z.useContext(gj);if(!e)throw new Error("useCart must be used within a CartProvider");return e};var bce="2.0.0",Fm="",mj="?",sk="function",Ud="undefined",Um="object",QD="string",Ax="major",xt="model",ht="name",ft="type",At="vendor",vt="version",ss="architecture",jm="console",Mn="mobile",di="tablet",la="smarttv",kx="wearable",KD="xr",WD="embedded",Tx="inapp",vj="user-agent",XD=500,JD="brands",Lp="formFactors",e8="fullVersionList",Pm="platform",t8="platformVersion",lk="bitness",jd="sec-ch-ua",_ce=jd+"-full-version-list",Sce=jd+"-arch",wce=jd+"-"+lk,Cce=jd+"-form-factors",Ece=jd+"-"+Mn,Ace=jd+"-"+xt,yj=jd+"-"+Pm,kce=yj+"-version",xj=[JD,e8,Mn,xt,Pm,t8,ss,Lp,lk],Rs="browser",lf="cpu",Wu="device",uf="engine",gl="os",Hm="result",uk="Amazon",Rx="Apple",bj="ASUS",_j="BlackBerry",Np="Google",Sj="Huawei",wj="Lenovo",Tce="Honor",n8="LG",ck="Microsoft",Cj="Motorola",Ox="Samsung",Ej="Sharp",fk="Sony",r8="Xiaomi",i8="Zebra",qm="Mobile ",Dx=" Browser",Aj="Chrome",Pd="Chromecast",Rce="Edge",Mx="Firefox",Ix="Opera",kj="Facebook",Tj="Sogou",o8="Windows",Oce=typeof window!==Ud,ls=Oce&&window.navigator?window.navigator:void 0,Hd=ls&&ls.userAgentData?ls.userAgentData:void 0,Dce=function(e,t){var n={},r=t;if(!hk(t)){r={};for(var o in t)for(var a in t[o])r[a]=t[o][a].concat(r[a]?r[a]:[])}for(var l in e)n[l]=r[l]&&r[l].length%2===0?r[l].concat(e[l]):e[l];return n},dk=function(e){for(var t={},n=0;n<e.length;n++)t[e[n].toUpperCase()]=e[n];return t},a8=function(e,t){if(typeof e===Um&&e.length>0){for(var n in e)if(cf(e[n])==cf(t))return!0;return!1}return Gm(e)?cf(t).indexOf(cf(e))!==-1:!1},hk=function(e,t){for(var n in e)return/^(browser|cpu|device|engine|os)$/.test(n)||(t?hk(e[n]):!1)},Gm=function(e){return typeof e===QD},s8=function(e){if(e){for(var t=[],n=zp(/\\?\"/g,e).split(","),r=0;r<n.length;r++)if(n[r].indexOf(";")>-1){var o=Bx(n[r]).split(";v=");t[r]={brand:o[0],version:o[1]}}else t[r]=Bx(n[r]);return t}},cf=function(e){return Gm(e)?e.toLowerCase():e},l8=function(e){return Gm(e)?zp(/[^\d\.]/g,e).split(".")[0]:void 0},ff=function(e){for(var t in e){var n=e[t];typeof n==Um&&n.length==2?this[n[0]]=n[1]:this[n]=void 0}return this},zp=function(e,t){return Gm(t)?t.replace(e,Fm):t},$x=function(e){return zp(/\\?\"/g,e)},Bx=function(e,t){if(Gm(e))return e=zp(/^\s\s*/,e),typeof t===Ud?e:e.substring(0,XD)},Rj=function(e,t){if(!(!e||!t))for(var n=0,r,o,a,l,d,h;n<t.length&&!d;){var p=t[n],y=t[n+1];for(r=o=0;r<p.length&&!d&&p[r];)if(d=p[r++].exec(e),d)for(a=0;a<y.length;a++)h=d[++o],l=y[a],typeof l===Um&&l.length>0?l.length===2?typeof l[1]==sk?this[l[0]]=l[1].call(this,h):this[l[0]]=l[1]:l.length===3?typeof l[1]===sk&&!(l[1].exec&&l[1].test)?this[l[0]]=h?l[1].call(this,h,l[2]):void 0:this[l[0]]=h?h.replace(l[1],l[2]):void 0:l.length===4&&(this[l[0]]=h?l[3].call(this,h.replace(l[1],l[2])):void 0):this[l]=h||void 0;n+=2}},Lx=function(e,t){for(var n in t)if(typeof t[n]===Um&&t[n].length>0){for(var r=0;r<t[n].length;r++)if(a8(t[n][r],e))return n===mj?void 0:n}else if(a8(t[n],e))return n===mj?void 0:n;return t.hasOwnProperty("*")?t["*"]:e},Oj={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2","8.1":"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},Dj={embedded:"Automotive",mobile:"Mobile",tablet:["Tablet","EInk"],smarttv:"TV",wearable:"Watch",xr:["VR","XR"],"?":["Desktop","Unknown"],"*":void 0},Mj={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[vt,[ht,qm+"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[vt,[ht,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[ht,vt],[/opios[\/ ]+([\w\.]+)/i],[vt,[ht,Ix+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[vt,[ht,Ix+" GX"]],[/\bopr\/([\w\.]+)/i],[vt,[ht,Ix]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[vt,[ht,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[vt,[ht,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon)\/([-\w\.]+)/i,/(heytap|ovi|115)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[ht,vt],[/quark(?:pc)?\/([-\w\.]+)/i],[vt,[ht,"Quark"]],[/\bddg\/([\w\.]+)/i],[vt,[ht,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[vt,[ht,"UCBrowser"]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[vt,[ht,"WeChat"]],[/konqueror\/([\w\.]+)/i],[vt,[ht,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[vt,[ht,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[vt,[ht,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[vt,[ht,"Smart "+wj+Dx]],[/(avast|avg)\/([\w\.]+)/i],[[ht,/(.+)/,"$1 Secure"+Dx],vt],[/\bfocus\/([\w\.]+)/i],[vt,[ht,Mx+" Focus"]],[/\bopt\/([\w\.]+)/i],[vt,[ht,Ix+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[vt,[ht,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[vt,[ht,"Dolphin"]],[/coast\/([\w\.]+)/i],[vt,[ht,Ix+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[vt,[ht,"MIUI"+Dx]],[/fxios\/([\w\.-]+)/i],[vt,[ht,qm+Mx]],[/\bqihoobrowser\/?([\w\.]*)/i],[vt,[ht,"360"]],[/\b(qq)\/([\w\.]+)/i],[[ht,/(.+)/,"$1Browser"],vt],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[ht,/(.+)/,"$1"+Dx],vt],[/samsungbrowser\/([\w\.]+)/i],[vt,[ht,Ox+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[vt,[ht,Tj+" Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[ht,Tj+" Mobile"],vt],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[ht,vt],[/(lbbrowser|rekonq)/i],[ht],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[vt,ht],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[ht,kj],vt,[ft,Tx]],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(instagram|snapchat)[\/ ]([-\w\.]+)/i],[ht,vt,[ft,Tx]],[/\bgsa\/([\w\.]+) .*safari\//i],[vt,[ht,"GSA"],[ft,Tx]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[vt,[ht,"TikTok"],[ft,Tx]],[/\[(linkedin)app\]/i],[ht,[ft,Tx]],[/(chromium)[\/ ]([-\w\.]+)/i],[ht,vt],[/headlesschrome(?:\/([\w\.]+)| )/i],[vt,[ht,Aj+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[ht,Aj+" WebView"],vt],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[vt,[ht,"Android"+Dx]],[/chrome\/([\w\.]+) mobile/i],[vt,[ht,qm+"Chrome"]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[ht,vt],[/version\/([\w\.\,]+) .*mobile(?:\/\w+ | ?)safari/i],[vt,[ht,qm+"Safari"]],[/iphone .*mobile(?:\/\w+ | ?)safari/i],[[ht,qm+"Safari"]],[/version\/([\w\.\,]+) .*(safari)/i],[vt,ht],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[ht,[vt,"1"]],[/(webkit|khtml)\/([\w\.]+)/i],[ht,vt],[/(?:mobile|tablet);.*(firefox)\/([\w\.-]+)/i],[[ht,qm+Mx],vt],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[ht,"Netscape"],vt],[/(wolvic|librewolf)\/([\w\.]+)/i],[ht,vt],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[vt,[ht,Mx+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/\b(links) \(([\w\.]+)/i],[ht,[vt,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[ht,[vt,/[^\d\.]+./,Fm]]],cpu:[[/\b(?:(amd|x|x86[-_]?|wow|win)64)\b/i],[[ss,"amd64"]],[/(ia32(?=;))/i,/((?:i[346]|x)86)[;\)]/i],[[ss,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[ss,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[ss,"armhf"]],[/windows (ce|mobile); ppc;/i],[[ss,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[ss,/ower/,Fm,cf]],[/(sun4\w)[;\)]/i],[[ss,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[ss,cf]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[xt,[At,Ox],[ft,di]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr])[-\w]+)/i,/sec-(sgh\w+)/i],[xt,[At,Ox],[ft,Mn]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[xt,[At,Rx],[ft,Mn]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[xt,[At,Rx],[ft,di]],[/(macintosh);/i],[xt,[At,Rx]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[xt,[At,Ej],[ft,Mn]],[/(?:honor)([-\w ]+)[;\)]/i],[xt,[At,Tce],[ft,Mn]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[xt,[At,Sj],[ft,di]],[/(?:huawei)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[xt,[At,Sj],[ft,Mn]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite|pro)?)(?: bui|\))/i],[[xt,/_/g," "],[At,r8],[ft,Mn]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[xt,/_/g," "],[At,r8],[ft,di]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[xt,[At,"OPPO"],[ft,Mn]],[/\b(opd2\d{3}a?) bui/i],[xt,[At,"OPPO"],[ft,di]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[xt,[At,"Vivo"],[ft,Mn]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[xt,[At,"Realme"],[ft,Mn]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[xt,[At,Cj],[ft,Mn]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[xt,[At,Cj],[ft,di]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[xt,[At,n8],[ft,di]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[xt,[At,n8],[ft,Mn]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[xt,[At,wj],[ft,di]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[xt,/_/g," "],[At,"Nokia"],[ft,Mn]],[/(pixel c)\b/i],[xt,[At,Np],[ft,di]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[xt,[At,Np],[ft,Mn]],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[xt,[At,fk],[ft,Mn]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[xt,"Xperia Tablet"],[At,fk],[ft,di]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[xt,[At,"OnePlus"],[ft,Mn]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[xt,[At,uk],[ft,di]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[xt,/(.+)/g,"Fire Phone $1"],[At,uk],[ft,Mn]],[/(playbook);[-\w\),; ]+(rim)/i],[xt,At,[ft,di]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[xt,[At,_j],[ft,Mn]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[xt,[At,bj],[ft,di]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[xt,[At,bj],[ft,Mn]],[/(nexus 9)/i],[xt,[At,"HTC"],[ft,di]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[At,[xt,/_/g," "],[ft,Mn]],[/tcl (xess p17aa)/i,/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])(_\w(\w|\w\w))?(\)| bui)/i],[xt,[At,"TCL"],[ft,di]],[/droid [\w\.]+; (418(?:7d|8v)|5087z|5102l|61(?:02[dh]|25[adfh]|27[ai]|56[dh]|59k|65[ah])|a509dl|t(?:43(?:0w|1[adepqu])|50(?:6d|7[adju])|6(?:09dl|10k|12b|71[efho]|76[hjk])|7(?:66[ahju]|67[hw]|7[045][bh]|71[hk]|73o|76[ho]|79w|81[hks]?|82h|90[bhsy]|99b)|810[hs]))(_\w(\w|\w\w))?(\)| bui)/i],[xt,[At,"TCL"],[ft,Mn]],[/(itel) ((\w+))/i],[[At,cf],xt,[ft,Lx,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[xt,[At,"Acer"],[ft,di]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[xt,[At,"Meizu"],[ft,Mn]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[xt,[At,"Ulefone"],[ft,Mn]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[xt,[At,"Energizer"],[ft,Mn]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[xt,[At,"Cat"],[ft,Mn]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[xt,[At,"Smartfren"],[ft,Mn]],[/droid.+; (a(?:015|06[35]|142p?))/i],[xt,[At,"Nothing"],[ft,Mn]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (imo) ((?!tab)[\w ]+?)(?: bui|\))/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[At,xt,[ft,Mn]],[/(imo) (tab \w+)/i,/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i],[At,xt,[ft,di]],[/(surface duo)/i],[xt,[At,ck],[ft,di]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[xt,[At,"Fairphone"],[ft,Mn]],[/(shield[\w ]+) b/i],[xt,[At,"Nvidia"],[ft,di]],[/(sprint) (\w+)/i],[At,xt,[ft,Mn]],[/(kin\.[onetw]{3})/i],[[xt,/\./g," "],[At,ck],[ft,Mn]],[/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[xt,[At,i8],[ft,di]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[xt,[At,i8],[ft,Mn]],[/smart-tv.+(samsung)/i],[At,[ft,la]],[/hbbtv.+maple;(\d+)/i],[[xt,/^/,"SmartTV"],[At,Ox],[ft,la]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[At,n8],[ft,la]],[/(apple) ?tv/i],[At,[xt,Rx+" TV"],[ft,la]],[/crkey.*devicetype\/chromecast/i],[[xt,Pd+" Third Generation"],[At,Np],[ft,la]],[/crkey.*devicetype\/([^/]*)/i],[[xt,/^/,"Chromecast "],[At,Np],[ft,la]],[/fuchsia.*crkey/i],[[xt,Pd+" Nest Hub"],[At,Np],[ft,la]],[/crkey/i],[[xt,Pd],[At,Np],[ft,la]],[/droid.+aft(\w+)( bui|\))/i],[xt,[At,uk],[ft,la]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[xt,[At,Ej],[ft,la]],[/(bravia[\w ]+)( bui|\))/i],[xt,[At,fk],[ft,la]],[/(mitv-\w{5}) bui/i],[xt,[At,r8],[ft,la]],[/Hbbtv.*(technisat) (.*);/i],[At,xt,[ft,la]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[At,Bx],[xt,Bx],[ft,la]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[ft,la]],[/(ouya)/i,/(nintendo) (\w+)/i],[At,xt,[ft,jm]],[/droid.+; (shield) bui/i],[xt,[At,"Nvidia"],[ft,jm]],[/(playstation \w+)/i],[xt,[At,fk],[ft,jm]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[xt,[At,ck],[ft,jm]],[/\b(sm-[lr]\d\d[05][fnuw]?s?)\b/i],[xt,[At,Ox],[ft,kx]],[/((pebble))app/i],[At,xt,[ft,kx]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[xt,[At,Rx],[ft,kx]],[/droid.+; (wt63?0{2,3})\)/i],[xt,[At,i8],[ft,kx]],[/droid.+; (glass) \d/i],[xt,[At,Np],[ft,KD]],[/(pico) (4|neo3(?: link|pro)?)/i],[At,xt,[ft,KD]],[/; (quest( \d| pro)?)/i],[xt,[At,kj],[ft,KD]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[At,[ft,WD]],[/(aeobc)\b/i],[xt,[At,uk],[ft,WD]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[xt,[ft,Mn]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[xt,[ft,di]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[ft,di]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[ft,Mn]],[/(android[-\w\. ]{0,9});.+buil/i],[xt,[At,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[vt,[ht,Rce+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[ht,vt],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[vt,[ht,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[ht,vt],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[vt,ht]],os:[[/microsoft (windows) (vista|xp)/i],[ht,vt],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[ht,[vt,Lx,Oj]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[vt,Lx,Oj],[ht,o8]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[vt,/_/g,"."],[ht,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[ht,"macOS"],[vt,/_/g,"."]],[/android ([\d\.]+).*crkey/i],[vt,[ht,Pd+" Android"]],[/fuchsia.*crkey\/([\d\.]+)/i],[vt,[ht,Pd+" Fuchsia"]],[/crkey\/([\d\.]+).*devicetype\/smartspeaker/i],[vt,[ht,Pd+" SmartSpeaker"]],[/linux.*crkey\/([\d\.]+)/i],[vt,[ht,Pd+" Linux"]],[/crkey\/([\d\.]+)/i],[vt,[ht,Pd]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[vt,ht],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish|openharmony)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[ht,vt],[/\(bb(10);/i],[vt,[ht,_j]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[vt,[ht,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[vt,[ht,Mx+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[vt,[ht,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[vt,[ht,"watchOS"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[ht,"Chrome OS"],vt],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) (\w+)/i,/(xbox); +xbox ([^\);]+)/i,/(pico) .+os([\w\.]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[ht,vt],[/(sunos) ?([\w\.\d]*)/i],[[ht,"Solaris"],vt],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[ht,vt]]},pk=function(){var e={init:{},isIgnore:{},isIgnoreRgx:{},toString:{}};return ff.call(e.init,[[Rs,[ht,vt,Ax,ft]],[lf,[ss]],[Wu,[ft,xt,At]],[uf,[ht,vt]],[gl,[ht,vt]]]),ff.call(e.isIgnore,[[Rs,[vt,Ax]],[uf,[vt]],[gl,[vt]]]),ff.call(e.isIgnoreRgx,[[Rs,/ ?browser$/i],[gl,/ ?os$/i]]),ff.call(e.toString,[[Rs,[ht,vt]],[lf,[ss]],[Wu,[At,xt]],[uf,[ht,vt]],[gl,[ht,vt]]]),e}(),Mce=function(e,t){var n=pk.init[t],r=pk.isIgnore[t]||0,o=pk.isIgnoreRgx[t]||0,a=pk.toString[t]||0;function l(){ff.call(this,n)}return l.prototype.getItem=function(){return e},l.prototype.withClientHints=function(){return Hd?Hd.getHighEntropyValues(xj).then(function(d){return e.setCH(new Ij(d,!1)).parseCH().get()}):e.parseCH().get()},l.prototype.withFeatureCheck=function(){return e.detectFeature().get()},t!=Hm&&(l.prototype.is=function(d){var h=!1;for(var p in this)if(this.hasOwnProperty(p)&&!a8(r,p)&&cf(o?zp(o,this[p]):this[p])==cf(o?zp(o,d):d)){if(h=!0,d!=Ud)break}else if(d==Ud&&h){h=!h;break}return h},l.prototype.toString=function(){var d=Fm;for(var h in a)typeof this[a[h]]!==Ud&&(d+=(d?" ":Fm)+this[a[h]]);return d||Ud}),Hd||(l.prototype.then=function(d){var h=this,p=function(){for(var m in h)h.hasOwnProperty(m)&&(this[m]=h[m])};p.prototype={is:l.prototype.is,toString:l.prototype.toString};var y=new p;return d(y),y}),new l};function Ij(e,t){if(e=e||{},ff.call(this,xj),t)ff.call(this,[[JD,s8(e[jd])],[e8,s8(e[_ce])],[Mn,/\?1/.test(e[Ece])],[xt,$x(e[Ace])],[Pm,$x(e[yj])],[t8,$x(e[kce])],[ss,$x(e[Sce])],[Lp,s8(e[Cce])],[lk,$x(e[wce])]]);else for(var n in e)this.hasOwnProperty(n)&&typeof e[n]!==Ud&&(this[n]=e[n])}function $j(e,t,n,r){return this.get=function(o){return o?this.data.hasOwnProperty(o)?this.data[o]:void 0:this.data},this.set=function(o,a){return this.data[o]=a,this},this.setCH=function(o){return this.uaCH=o,this},this.detectFeature=function(){if(ls&&ls.userAgent==this.ua)switch(this.itemType){case Rs:ls.brave&&typeof ls.brave.isBrave==sk&&this.set(ht,"Brave");break;case Wu:!this.get(ft)&&Hd&&Hd[Mn]&&this.set(ft,Mn),this.get(xt)=="Macintosh"&&ls&&typeof ls.standalone!==Ud&&ls.maxTouchPoints&&ls.maxTouchPoints>2&&this.set(xt,"iPad").set(ft,di);break;case gl:!this.get(ht)&&Hd&&Hd[Pm]&&this.set(ht,Hd[Pm]);break;case Hm:var o=this.data,a=function(l){return o[l].getItem().detectFeature().get()};this.set(Rs,a(Rs)).set(lf,a(lf)).set(Wu,a(Wu)).set(uf,a(uf)).set(gl,a(gl))}return this},this.parseUA=function(){return this.itemType!=Hm&&Rj.call(this.data,this.ua,this.rgxMap),this.itemType==Rs&&this.set(Ax,l8(this.get(vt))),this},this.parseCH=function(){var o=this.uaCH,a=this.rgxMap;switch(this.itemType){case Rs:var l=o[e8]||o[JD],d;if(l)for(var h in l){var p=zp(/(Google|Microsoft) /,l[h].brand||l[h]),y=l[h].version;!/not.a.brand/i.test(p)&&(!d||/chrom/i.test(d)&&!/chromi/i.test(p))&&(this.set(ht,p).set(vt,y).set(Ax,l8(y)),d=p)}break;case lf:var m=o[ss];m&&(m&&o[lk]=="64"&&(m+="64"),Rj.call(this.data,m+";",a));break;case Wu:if(o[Mn]&&this.set(ft,Mn),o[xt]&&this.set(xt,o[xt]),o[xt]=="Xbox"&&this.set(ft,jm).set(At,ck),o[Lp]){var x;if(typeof o[Lp]!="string")for(var _=0;!x&&_<o[Lp].length;)x=Lx(o[Lp][_++],Dj);else x=Lx(o[Lp],Dj);this.set(ft,x)}break;case gl:var w=o[Pm];if(w){var k=o[t8];w==o8&&(k=parseInt(l8(k),10)>=13?"11":"10"),this.set(ht,w).set(vt,k)}this.get(ht)==o8&&o[xt]=="Xbox"&&this.set(ht,"Xbox").set(vt,void 0);break;case Hm:var A=this.data,E=function(R){return A[R].getItem().setCH(o).parseCH().get()};this.set(Rs,E(Rs)).set(lf,E(lf)).set(Wu,E(Wu)).set(uf,E(uf)).set(gl,E(gl))}return this},ff.call(this,[["itemType",e],["ua",t],["uaCH",r],["rgxMap",n],["data",Mce(this,e)]]),this}function df(e,t,n){if(typeof e===Um?(hk(e,!0)?(typeof t===Um&&(n=t),t=e):(n=e,t=void 0),e=void 0):typeof e===QD&&!hk(t,!0)&&(n=t,t=void 0),n&&typeof n.append===sk){var r={};n.forEach(function(h,p){r[p]=h}),n=r}if(!(this instanceof df))return new df(e,t,n).getResult();var o=typeof e===QD?e:n&&n[vj]?n[vj]:ls&&ls.userAgent?ls.userAgent:Fm,a=new Ij(n,!0),l=t?Dce(Mj,t):Mj,d=function(h){return h==Hm?function(){return new $j(h,o,l,a).set("ua",o).set(Rs,this.getBrowser()).set(lf,this.getCPU()).set(Wu,this.getDevice()).set(uf,this.getEngine()).set(gl,this.getOS()).get()}:function(){return new $j(h,o,l[h],a).parseUA().get()}};return ff.call(this,[["getBrowser",d(Rs)],["getCPU",d(lf)],["getDevice",d(Wu)],["getEngine",d(uf)],["getOS",d(gl)],["getResult",d(Hm)],["getUA",function(){return o}],["setUA",function(h){return Gm(h)&&(o=h.length>XD?Bx(h,XD):h),this}]]).setUA(o),this}df.VERSION=bce,df.BROWSER=dk([ht,vt,Ax,ft]),df.CPU=dk([ss]),df.DEVICE=dk([xt,At,ft,jm,Mn,la,di,kx,WD]),df.ENGINE=df.OS=dk([ht,vt]);const yl=class yl{constructor(t){ei(this,"config");ei(this,"storedData");ei(this,"deviceInfo");ei(this,"localStorageKey","_dsjfs312313kj3debales_analytics_");this.config=t,this.deviceInfo=this.getDeviceInfo(),this.localStorageKey=t.localStorageKey||this.localStorageKey+this.config.projectName,this.config.testing=t.testing||(()=>!1);const n=localStorage.getItem(this.localStorageKey);if(n)this.storedData=JSON.parse(n),this.config.debug&&console.log("Using Existing Stored data:",this.storedData);else{const r=crypto.randomUUID();this.storedData={projectName:this.config.projectName,anonId:r,distinctId:r},this.config.debug&&console.log("Using New Stored data:",this.storedData),this.updateStorage()}this.config.debug&&console.log("Analytics initialized:",this.storedData)}static init(t){yl.instance||(yl.instance=new yl(t))}static getInstance(){if(!yl.instance)throw new Error("DebalesAnalytics is not initialized. Call init() first.");return yl.instance}static async identify(t,n){return yl.getInstance().identifyInternal(t,n)}static track(t,n){yl.getInstance().trackInternal(t,n)}static getDistinctId(){return yl.getInstance().storedData.distinctId}static getAnonId(){return yl.getInstance().storedData.anonId}async identifyInternal(t,n){try{if(this.config.testing&&this.config.testing())return;let r,o,a;if(n){const{name:h,phone:p,...y}=n;r=h,o=p,a=y}const l={distinctId:this.storedData.distinctId,anonId:[this.storedData.anonId],projectName:this.config.projectName,email:t,name:r,phone:o,properties:a},d=await this.sendRequest("/api/analytic/identify",l);d&&d.success&&d.distinctId&&(this.config.debug&&console.log("identify success new distint id"),this.storedData.distinctId=d.distinctId,this.storedData.email=t,this.updateStorage(),d.isIdentified&&this.trackInternal("identify")),this.config.debug&&console.log("Identify event sent:",l)}catch(r){console.error("Failed to identify user:",r)}}trackInternal(t,n){if(this.config.testing&&this.config.testing())return;const r={projectName:this.config.projectName,distinctId:this.storedData.distinctId,anonId:this.storedData.anonId,eventName:t,osVersion:this.deviceInfo.osVersion,browserVersion:this.deviceInfo.browserVersion,operatingSystem:this.deviceInfo.os,browser:this.deviceInfo.browser,referrer:document.referrer,currentUrl:window.location.href,chatId:nr()+this.config.projectName,properties:n};this.sendRequest("/api/analytic/track",r),this.config.debug&&console.log("Track event sent:",r)}updateStorage(){localStorage.setItem(this.localStorageKey,JSON.stringify(this.storedData))}async sendRequest(t,n){try{const r=await fetch(`${Ti}${t}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(n)});if(!r.ok)throw new Error(`HTTP error! status: ${r.status}`);return await r.json()}catch(r){console.error("Failed to send analytics data:",r)}}getDeviceInfo(){const n=new df().getResult();return{browser:n.browser.name,os:n.os.name,browserVersion:n.browser.version,osVersion:n.os.version}}};ei(yl,"instance",null);let u8=yl;const Xu=u8,gk=e=>{window.DebalesChat||(window.DebalesChat={isOpen:!1,projectId:e,getSessionId:()=>nr(),getChatId:()=>nr()+"_"+e,getAnonId:()=>Xu.getAnonId(),isIdentified:()=>{if(ul._isIdentified())return!0;const t=jo();return!!(t&&t.email)},getIdentifiedUser:()=>jo(),getDistinctId:()=>ul.get_distinct_id(),getOldDistinctId:()=>Xu.getDistinctId(),debug:!1,identify:(t,n)=>{ul._isIdentified()||ul.identify(t,{...n,project:e}),Xu.identify(t,n),sf({email:t,name:n==null?void 0:n.name,phone:n==null?void 0:n.phone})},track:(t,n)=>{Xu.track(t,{...n,sessionId:window.DebalesChat.getSessionId()}),ul.capture(t,{...n}),Nle(t,{...n,sessionId:nr(),projectId:e})},onOpenChange:t=>{const n=r=>{t(r.detail.isOpen)};return window.addEventListener(Qr.OPEN_STATE_CHANGE,n),()=>window.removeEventListener(Qr.OPEN_STATE_CHANGE,n)},removeOpenChangeListener:t=>{const n=r=>{t(r.detail.isOpen)};window.removeEventListener(Qr.OPEN_STATE_CHANGE,n)},open:()=>{window.DebalesChat.isOpen||window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:!0,projectId:e}}))},close:()=>{window.DebalesChat.isOpen&&window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:!1,projectId:e}}))},toggle:()=>{window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:!window.DebalesChat.isOpen,projectId:e}}))}})};var xi=(e=>(e.DEFAULT="DEFAULT",e.SHOPIFY="SHOPIFY",e.WOOCOMMERCE="WOOCOMMERCE",e.MAGENTO="MAGENTO",e.UNKNOWN="UNKNOWN",e.THE_COLLECTIVE="THE_COLLECTIVE",e))(xi||{});class hf{static detect(){var t,n,r,o,a,l;if(typeof window<"u"&&window.Shopify!==void 0&&window.Shopify.routes!==void 0)return xi.SHOPIFY;if(typeof window<"u"&&window.location.hostname.endsWith(".thecollective.in"))return xi.THE_COLLECTIVE;if(typeof window<"u"&&document.body.classList.contains("woocommerce"))return xi.WOOCOMMERCE;if(typeof window<"u"){if(window.MAGENTO_VERSION!==void 0||window.MAGE!==void 0||window.Mage!==void 0||["page-wrapper","magento-theme","catalog-product-view","catalog-category-view"].some(m=>document.body.classList.contains(m)))return xi.MAGENTO;const h=document.getElementsByTagName("script");for(const m of Array.from(h))if(m.src.includes("mage/")||m.src.includes("magento")||(t=m.textContent)!=null&&t.includes("Mage.")||(n=m.textContent)!=null&&n.includes("require(")||(r=m.getAttribute("data-requiremodule"))!=null&&r.startsWith("mage")||(o=m.getAttribute("data-requiremodule"))!=null&&o.startsWith("Magento"))return xi.MAGENTO;if(document.cookie.split(";").some(m=>m.trim().startsWith("mage-")||m.trim().startsWith("form_key")))return xi.MAGENTO;const y=document.getElementsByTagName("meta");for(const m of Array.from(y))if((a=m.getAttribute("content"))!=null&&a.includes("Magento")||(l=m.getAttribute("name"))!=null&&l.includes("magento"))return xi.MAGENTO}return xi.UNKNOWN}}var Ice={MESSAGE:"MESSAGE"},$ce={USER:"USER"};function Fp(e){try{let t=e.trim();/^[a-zA-Z]+:\/\//.test(t)||(t="https://"+t);const r={protocols:["http","https"],require_tld:!0,require_protocol:!1,require_host:!0,require_valid_protocol:!0,validate_length:!0,allow_underscores:!0,allow_trailing_dot:!1,allow_protocol_relative_urls:!1};if(!zm.isURL(t,r))throw new Error("Invalid URL format");return{isValid:!0,url:new URL(t)}}catch(t){return{isValid:!1,error:t instanceof Error?t.message:"Unknown error"}}}const Ie=e=>e==="the-collective"||e==="the-collective-prod"||e==="debales-testing"||e==="the-collective-test",Bj=e=>{if(!e||typeof e!="string")return!1;const t=Fp(e);if(!t.isValid)return!1;const n=t.url.pathname.toLowerCase();return[".mp4",".webm",".ogg",".avi",".mov",".wmv",".flv",".mkv",".m4v",".3gp"].some(o=>n.endsWith(o))},mk=ae.button`
479
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var I,L=!0,N=!1;return{s:function(){E=E.call(k)},n:function(){var V=E.next();return L=V.done,V},e:function(V){N=!0,I=V},f:function(){try{L||E.return==null||E.return()}finally{if(N)throw I}}}}function m(k,A){if(k){if(typeof k=="string")return x(k,A);var E={}.toString.call(k).slice(8,-1);return E==="Object"&&k.constructor&&(E=k.constructor.name),E==="Map"||E==="Set"?Array.from(k):E==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(E)?x(k,A):void 0}}function x(k,A){(A==null||A>k.length)&&(A=k.length);for(var E=0,R=Array(A);E<A;E++)R[E]=k[E];return R}function _(k){var A=new Set(["subject","body","cc","bcc"]),E={cc:"",bcc:""},R=!1,O=k.split("&");if(O.length>4)return!1;var I=y(O),L;try{for(I.s();!(L=I.n()).done;){var N=L.value,H=N.split("="),V=l(H,2),W=V[0],z=V[1];if(W&&!A.has(W)){R=!0;break}z&&(W==="cc"||W==="bcc")&&(E[W]=z),W&&A.delete(W)}}catch(Q){I.e(Q)}finally{I.f()}return R?!1:E}function w(k,A){if((0,o.default)(k),k.indexOf("mailto:")!==0)return!1;var E=k.replace("mailto:","").split("?"),R=l(E,2),O=R[0],I=R[1],L=I===void 0?"":I;if(!O&&!L)return!0;var N=_(L);return N?"".concat(O,",").concat(N.cc,",").concat(N.bcc).split(",").every(function(H){return H=(0,n.default)(H," "),H?(0,r.default)(H,A):!0}):!1}e.exports=t.default,e.exports.default=t.default}(GA,GA.exports)),GA.exports}var QA={exports:{}},JU;function ace(){return JU||(JU=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var n=r(gt());function r(h){return h&&h.__esModule?h:{default:h}}var o=/^(application|audio|font|image|message|model|multipart|text|video)\/[a-zA-Z0-9\.\-\+_]{1,100}$/i,a=/^text\/[a-zA-Z0-9\.\-\+]{1,100};\s?charset=("[a-zA-Z0-9\.\-\+\s]{0,70}"|[a-zA-Z0-9\.\-\+]{0,70})(\s?\([a-zA-Z0-9\.\-\+\s]{1,20}\))?$/i,l=/^multipart\/[a-zA-Z0-9\.\-\+]{1,100}(;\s?(boundary|charset)=("[a-zA-Z0-9\.\-\+\s]{0,70}"|[a-zA-Z0-9\.\-\+]{0,70})(\s?\([a-zA-Z0-9\.\-\+\s]{1,20}\))?){0,2}$/i;function d(h){return(0,n.default)(h),o.test(h)||a.test(h)||l.test(h)}e.exports=t.default,e.exports.default=t.default}(QA,QA.exports)),QA.exports}var KA={exports:{}},ej;function sce(){return ej||(ej=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=y;var n=o(gt()),r=o(Na());function o(m){return m&&m.__esModule?m:{default:m}}var a=/^\(?[+-]?(90(\.0+)?|[1-8]?\d(\.\d+)?)$/,l=/^\s?[+-]?(180(\.0+)?|1[0-7]\d(\.\d+)?|\d{1,2}(\.\d+)?)\)?$/,d=/^(([1-8]?\d)\D+([1-5]?\d|60)\D+([1-5]?\d|60)(\.\d+)?|90\D+0\D+0)\D+[NSns]?$/i,h=/^\s*([1-7]?\d{1,2}\D+([1-5]?\d|60)\D+([1-5]?\d|60)(\.\d+)?|180\D+0\D+0)\D+[EWew]?$/i,p={checkDMS:!1};function y(m,x){if((0,n.default)(m),x=(0,r.default)(x,p),!m.includes(","))return!1;var _=m.split(",");return _[0].startsWith("(")&&!_[1].endsWith(")")||_[1].endsWith(")")&&!_[0].startsWith("(")?!1:x.checkDMS?d.test(_[0])&&h.test(_[1]):a.test(_[0])&&l.test(_[1])}e.exports=t.default,e.exports.default=t.default}(KA,KA.exports)),KA.exports}var Lm={},tj;function lce(){if(tj)return Lm;tj=1,Object.defineProperty(Lm,"__esModule",{value:!0}),Lm.default=d,Lm.locales=void 0;var e=t(gt());function t(h){return h&&h.__esModule?h:{default:h}}var n=/^\d{3}$/,r=/^\d{4}$/,o=/^\d{5}$/,a=/^\d{6}$/,l={AD:/^AD\d{3}$/,AT:r,AU:r,AZ:/^AZ\d{4}$/,BA:/^([7-8]\d{4}$)/,BE:r,BG:r,BR:/^\d{5}-?\d{3}$/,BY:/^2[1-4]\d{4}$/,CA:/^[ABCEGHJKLMNPRSTVXY]\d[ABCEGHJ-NPRSTV-Z][\s\-]?\d[ABCEGHJ-NPRSTV-Z]\d$/i,CH:r,CN:/^(0[1-7]|1[012356]|2[0-7]|3[0-6]|4[0-7]|5[1-7]|6[1-7]|7[1-5]|8[1345]|9[09])\d{4}$/,CO:/^(05|08|11|13|15|17|18|19|20|23|25|27|41|44|47|50|52|54|63|66|68|70|73|76|81|85|86|88|91|94|95|97|99)(\d{4})$/,CZ:/^\d{3}\s?\d{2}$/,DE:o,DK:r,DO:o,DZ:o,EE:o,ES:/^(5[0-2]{1}|[0-4]{1}\d{1})\d{3}$/,FI:o,FR:/^\d{2}\s?\d{3}$/,GB:/^(gir\s?0aa|[a-z]{1,2}\d[\da-z]?\s?(\d[a-z]{2})?)$/i,GR:/^\d{3}\s?\d{2}$/,HR:/^([1-5]\d{4}$)/,HT:/^HT\d{4}$/,HU:r,ID:o,IE:/^(?!.*(?:o))[A-Za-z]\d[\dw]\s\w{4}$/i,IL:/^(\d{5}|\d{7})$/,IN:/^((?!10|29|35|54|55|65|66|86|87|88|89)[1-9][0-9]{5})$/,IR:/^(?!(\d)\1{3})[13-9]{4}[1346-9][013-9]{5}$/,IS:n,IT:o,JP:/^\d{3}\-\d{4}$/,KE:o,KR:/^(\d{5}|\d{6})$/,LI:/^(948[5-9]|949[0-7])$/,LT:/^LT\-\d{5}$/,LU:r,LV:/^LV\-\d{4}$/,LK:o,MG:n,MX:o,MT:/^[A-Za-z]{3}\s{0,1}\d{4}$/,MY:o,NL:/^[1-9]\d{3}\s?(?!sa|sd|ss)[a-z]{2}$/i,NO:r,NP:/^(10|21|22|32|33|34|44|45|56|57)\d{3}$|^(977)$/i,NZ:r,PL:/^\d{2}\-\d{3}$/,PR:/^00[679]\d{2}([ -]\d{4})?$/,PT:/^\d{4}\-\d{3}?$/,RO:a,RU:a,SA:o,SE:/^[1-9]\d{2}\s?\d{2}$/,SG:a,SI:r,SK:/^\d{3}\s?\d{2}$/,TH:o,TN:r,TW:/^\d{3}(\d{2})?$/,UA:o,US:/^\d{5}(-\d{4})?$/,ZA:r,ZM:o};Lm.locales=Object.keys(l);function d(h,p){if((0,e.default)(h),p in l)return l[p].test(h);if(p==="any"){for(var y in l)if(l.hasOwnProperty(y)){var m=l[y];if(m.test(h))return!0}return!1}throw new Error("Invalid locale '".concat(p,"'"))}return Lm}var WA={exports:{}},nj;function uce(){return nj||(nj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a){return(0,n.default)(a),a.replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\//g,"&#x2F;").replace(/\\/g,"&#x5C;").replace(/`/g,"&#96;")}e.exports=t.default,e.exports.default=t.default}(WA,WA.exports)),WA.exports}var XA={exports:{}},rj;function cce(){return rj||(rj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a){return(0,n.default)(a),a.replace(/&quot;/g,'"').replace(/&#x27;/g,"'").replace(/&lt;/g,"<").replace(/&gt;/g,">").replace(/&#x2F;/g,"/").replace(/&#x5C;/g,"\\").replace(/&#96;/g,"`").replace(/&amp;/g,"&")}e.exports=t.default,e.exports.default=t.default}(XA,XA.exports)),XA.exports}var JA={exports:{}},ek={exports:{}},ij;function oj(){return ij||(ij=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a,l){return(0,n.default)(a),a.replace(new RegExp("[".concat(l,"]+"),"g"),"")}e.exports=t.default,e.exports.default=t.default}(ek,ek.exports)),ek.exports}var aj;function fce(){return aj||(aj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=o(gt()),r=o(oj());function o(l){return l&&l.__esModule?l:{default:l}}function a(l,d){(0,n.default)(l);var h=d?"\\x00-\\x09\\x0B\\x0C\\x0E-\\x1F\\x7F":"\\x00-\\x1F\\x7F";return(0,r.default)(l,h)}e.exports=t.default,e.exports.default=t.default}(JA,JA.exports)),JA.exports}var tk={exports:{}},sj;function dce(){return sj||(sj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a,l){return(0,n.default)(a),a.replace(new RegExp("[^".concat(l,"]+"),"g"),"")}e.exports=t.default,e.exports.default=t.default}(tk,tk.exports)),tk.exports}var nk={exports:{}},lj;function hce(){return lj||(lj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(gt());function r(a){return a&&a.__esModule?a:{default:a}}function o(a,l){(0,n.default)(a);for(var d=a.length-1;d>=0;d--)if(l.indexOf(a[d])===-1)return!1;return!0}e.exports=t.default,e.exports.default=t.default}(nk,nk.exports)),nk.exports}var rk={exports:{}},uj;function pce(){return uj||(uj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=y;var n=r(Na());function r(m){return m&&m.__esModule?m:{default:m}}var o={all_lowercase:!0,gmail_lowercase:!0,gmail_remove_dots:!0,gmail_remove_subaddress:!0,gmail_convert_googlemaildotcom:!0,outlookdotcom_lowercase:!0,outlookdotcom_remove_subaddress:!0,yahoo_lowercase:!0,yahoo_remove_subaddress:!0,yandex_lowercase:!0,yandex_convert_yandexru:!0,icloud_lowercase:!0,icloud_remove_subaddress:!0},a=["icloud.com","me.com"],l=["hotmail.at","hotmail.be","hotmail.ca","hotmail.cl","hotmail.co.il","hotmail.co.nz","hotmail.co.th","hotmail.co.uk","hotmail.com","hotmail.com.ar","hotmail.com.au","hotmail.com.br","hotmail.com.gr","hotmail.com.mx","hotmail.com.pe","hotmail.com.tr","hotmail.com.vn","hotmail.cz","hotmail.de","hotmail.dk","hotmail.es","hotmail.fr","hotmail.hu","hotmail.id","hotmail.ie","hotmail.in","hotmail.it","hotmail.jp","hotmail.kr","hotmail.lv","hotmail.my","hotmail.ph","hotmail.pt","hotmail.sa","hotmail.sg","hotmail.sk","live.be","live.co.uk","live.com","live.com.ar","live.com.mx","live.de","live.es","live.eu","live.fr","live.it","live.nl","msn.com","outlook.at","outlook.be","outlook.cl","outlook.co.il","outlook.co.nz","outlook.co.th","outlook.com","outlook.com.ar","outlook.com.au","outlook.com.br","outlook.com.gr","outlook.com.pe","outlook.com.tr","outlook.com.vn","outlook.cz","outlook.de","outlook.dk","outlook.es","outlook.fr","outlook.hu","outlook.id","outlook.ie","outlook.in","outlook.it","outlook.jp","outlook.kr","outlook.lv","outlook.my","outlook.ph","outlook.pt","outlook.sa","outlook.sg","outlook.sk","passport.com"],d=["rocketmail.com","yahoo.ca","yahoo.co.uk","yahoo.com","yahoo.de","yahoo.fr","yahoo.in","yahoo.it","ymail.com"],h=["yandex.ru","yandex.ua","yandex.kz","yandex.com","yandex.by","ya.ru"];function p(m){return m.length>1?m:""}function y(m,x){x=(0,n.default)(x,o);var _=m.split("@"),w=_.pop(),k=_.join("@"),A=[k,w];if(A[1]=A[1].toLowerCase(),A[1]==="gmail.com"||A[1]==="googlemail.com"){if(x.gmail_remove_subaddress&&(A[0]=A[0].split("+")[0]),x.gmail_remove_dots&&(A[0]=A[0].replace(/\.+/g,p)),!A[0].length)return!1;(x.all_lowercase||x.gmail_lowercase)&&(A[0]=A[0].toLowerCase()),A[1]=x.gmail_convert_googlemaildotcom?"gmail.com":A[1]}else if(a.indexOf(A[1])>=0){if(x.icloud_remove_subaddress&&(A[0]=A[0].split("+")[0]),!A[0].length)return!1;(x.all_lowercase||x.icloud_lowercase)&&(A[0]=A[0].toLowerCase())}else if(l.indexOf(A[1])>=0){if(x.outlookdotcom_remove_subaddress&&(A[0]=A[0].split("+")[0]),!A[0].length)return!1;(x.all_lowercase||x.outlookdotcom_lowercase)&&(A[0]=A[0].toLowerCase())}else if(d.indexOf(A[1])>=0){if(x.yahoo_remove_subaddress){var E=A[0].split("-");A[0]=E.length>1?E.slice(0,-1).join("-"):E[0]}if(!A[0].length)return!1;(x.all_lowercase||x.yahoo_lowercase)&&(A[0]=A[0].toLowerCase())}else h.indexOf(A[1])>=0?((x.all_lowercase||x.yandex_lowercase)&&(A[0]=A[0].toLowerCase()),A[1]=x.yandex_convert_yandexru?"yandex.ru":A[1]):x.all_lowercase&&(A[0]=A[0].toLowerCase());return A.join("@")}e.exports=t.default,e.exports.default=t.default}(rk,rk.exports)),rk.exports}var ik={exports:{}},cj;function gce(){return cj||(cj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o=/^[^\s-_](?!.*?[-_]{2,})[a-z0-9-\\][^\s]*[^-_\s]$/;function a(l){return(0,n.default)(l),o.test(l)}e.exports=t.default,e.exports.default=t.default}(ik,ik.exports)),ik.exports}var ok={exports:{}},fj;function mce(){return fj||(fj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(gt());function r(l){return l&&l.__esModule?l:{default:l}}var o={"cs-CZ":function(d){return/^(([ABCDEFHIJKLMNPRSTUVXYZ]|[0-9])-?){5,8}$/.test(d)},"de-DE":function(d){return/^((A|AA|AB|AC|AE|AH|AK|AM|AN|AΓ–|AP|AS|AT|AU|AW|AZ|B|BA|BB|BC|BE|BF|BH|BI|BK|BL|BM|BN|BO|BΓ–|BS|BT|BZ|C|CA|CB|CE|CO|CR|CW|D|DA|DD|DE|DH|DI|DL|DM|DN|DO|DU|DW|DZ|E|EA|EB|ED|EE|EF|EG|EH|EI|EL|EM|EN|ER|ES|EU|EW|F|FB|FD|FF|FG|FI|FL|FN|FO|FR|FS|FT|FÜ|FW|FZ|G|GA|GC|GD|GE|GF|GG|GI|GK|GL|GM|GN|GΓ–|GP|GR|GS|GT|GÜ|GV|GW|GZ|H|HA|HB|HC|HD|HE|HF|HG|HH|HI|HK|HL|HM|HN|HO|HP|HR|HS|HU|HV|HX|HY|HZ|IK|IL|IN|IZ|J|JE|JL|K|KA|KB|KC|KE|KF|KG|KH|KI|KK|KL|KM|KN|KO|KR|KS|KT|KU|KW|KY|L|LA|LB|LC|LD|LF|LG|LH|LI|LL|LM|LN|LΓ–|LP|LR|LU|M|MA|MB|MC|MD|ME|MG|MH|MI|MK|ML|MM|MN|MO|MQ|MR|MS|MÜ|MW|MY|MZ|N|NB|ND|NE|NF|NH|NI|NK|NM|NΓ–|NP|NR|NT|NU|NW|NY|NZ|OA|OB|OC|OD|OE|OF|OG|OH|OK|OL|OP|OS|OZ|P|PA|PB|PE|PF|PI|PL|PM|PN|PR|PS|PW|PZ|R|RA|RC|RD|RE|RG|RH|RI|RL|RM|RN|RO|RP|RS|RT|RU|RV|RW|RZ|S|SB|SC|SE|SG|SI|SK|SL|SM|SN|SO|SP|SR|ST|SU|SW|SY|SZ|TE|TF|TG|TO|TP|TR|TS|TT|TÜ|ÜB|UE|UH|UL|UM|UN|V|VB|VG|VK|VR|VS|W|WA|WB|WE|WF|WI|WK|WL|WM|WN|WO|WR|WS|WT|WÜ|WW|WZ|Z|ZE|ZI|ZP|ZR|ZW|ZZ)[- ]?[A-Z]{1,2}[- ]?\d{1,4}|(ABG|ABI|AIB|AIC|ALF|ALZ|ANA|ANG|ANK|APD|ARN|ART|ASL|ASZ|AUR|AZE|BAD|BAR|BBG|BCH|BED|BER|BGD|BGL|BID|BIN|BIR|BIT|BIW|BKS|BLB|BLK|BNA|BOG|BOH|BOR|BOT|BRA|BRB|BRG|BRK|BRL|BRV|BSB|BSK|BTF|BÜD|BUL|BÜR|BÜS|BÜZ|CAS|CHA|CLP|CLZ|COC|COE|CUX|DAH|DAN|DAU|DBR|DEG|DEL|DGF|DIL|DIN|DIZ|DKB|DLG|DON|DUD|DÜW|EBE|EBN|EBS|ECK|EIC|EIL|EIN|EIS|EMD|EMS|ERB|ERH|ERK|ERZ|ESB|ESW|FDB|FDS|FEU|FFB|FKB|FLΓ–|FOR|FRG|FRI|FRW|FTL|FÜS|GAN|GAP|GDB|GEL|GEO|GER|GHA|GHC|GLA|GMN|GNT|GOA|GOH|GRA|GRH|GRI|GRM|GRZ|GTH|GUB|GUN|GVM|HAB|HAL|HAM|HAS|HBN|HBS|HCH|HDH|HDL|HEB|HEF|HEI|HER|HET|HGN|HGW|HHM|HIG|HIP|HMÜ|HOG|HOH|HOL|HOM|HOR|HΓ–S|HOT|HRO|HSK|HST|HVL|HWI|IGB|ILL|JÜL|KEH|KEL|KEM|KIB|KLE|KLZ|KΓ–N|KΓ–T|KΓ–Z|KRU|KÜN|KUS|KYF|LAN|LAU|LBS|LBZ|LDK|LDS|LEO|LER|LEV|LIB|LIF|LIP|LΓ–B|LOS|LRO|LSZ|LÜN|LUP|LWL|MAB|MAI|MAK|MAL|MED|MEG|MEI|MEK|MEL|MER|MET|MGH|MGN|MHL|MIL|MKK|MOD|MOL|MON|MOS|MSE|MSH|MSP|MST|MTK|MTL|MÜB|MÜR|MYK|MZG|NAB|NAI|NAU|NDH|NEA|NEB|NEC|NEN|NES|NEW|NMB|NMS|NOH|NOL|NOM|NOR|NVP|NWM|OAL|OBB|OBG|OCH|OHA|Γ–HR|OHV|OHZ|OPR|OSL|OVI|OVL|OVP|PAF|PAN|PAR|PCH|PEG|PIR|PLΓ–|PRÜ|QFT|QLB|RDG|REG|REH|REI|RID|RIE|ROD|ROF|ROK|ROL|ROS|ROT|ROW|RSL|RÜD|RÜG|SAB|SAD|SAN|SAW|SBG|SBK|SCZ|SDH|SDL|SDT|SEB|SEE|SEF|SEL|SFB|SFT|SGH|SHA|SHG|SHK|SHL|SIG|SIM|SLE|SLF|SLK|SLN|SLS|SLÜ|SLZ|SMÜ|SOB|SOG|SOK|SΓ–M|SON|SPB|SPN|SRB|SRO|STA|STB|STD|STE|STL|SUL|SÜW|SWA|SZB|TBB|TDO|TET|TIR|TΓ–L|TUT|UEM|UER|UFF|USI|VAI|VEC|VER|VIB|VIE|VIT|VOH|WAF|WAK|WAN|WAR|WAT|WBS|WDA|WEL|WEN|WER|WES|WHV|WIL|WIS|WIT|WIZ|WLG|WMS|WND|WOB|WOH|WOL|WOR|WOS|WRN|WSF|WST|WSW|WTL|WTM|WUG|WÜM|WUN|WUR|WZL|ZEL|ZIG)[- ]?(([A-Z][- ]?\d{1,4})|([A-Z]{2}[- ]?\d{1,3})))[- ]?(E|H)?$/.test(d)},"de-LI":function(d){return/^FL[- ]?\d{1,5}[UZ]?$/.test(d)},"en-IN":function(d){return/^[A-Z]{2}[ -]?[0-9]{1,2}(?:[ -]?[A-Z])(?:[ -]?[A-Z]*)?[ -]?[0-9]{4}$/.test(d)},"en-SG":function(d){return/^[A-Z]{3}[ -]?[\d]{4}[ -]?[A-Z]{1}$/.test(d)},"es-AR":function(d){return/^(([A-Z]{2} ?[0-9]{3} ?[A-Z]{2})|([A-Z]{3} ?[0-9]{3}))$/.test(d)},"fi-FI":function(d){return/^(?=.{4,7})(([A-Z]{1,3}|[0-9]{1,3})[\s-]?([A-Z]{1,3}|[0-9]{1,5}))$/.test(d)},"hu-HU":function(d){return/^((((?!AAA)(([A-NPRSTVZWXY]{1})([A-PR-Z]{1})([A-HJ-NPR-Z]))|(A[ABC]I)|A[ABC]O|A[A-W]Q|BPI|BPO|UCO|UDO|XAO)-(?!000)\d{3})|(M\d{6})|((CK|DT|CD|HC|H[ABEFIKLMNPRSTVX]|MA|OT|R[A-Z]) \d{2}-\d{2})|(CD \d{3}-\d{3})|(C-(C|X) \d{4})|(X-(A|B|C) \d{4})|(([EPVZ]-\d{5}))|(S A[A-Z]{2} \d{2})|(SP \d{2}-\d{2}))$/.test(d)},"pt-BR":function(d){return/^[A-Z]{3}[ -]?[0-9][A-Z][0-9]{2}|[A-Z]{3}[ -]?[0-9]{4}$/.test(d)},"pt-PT":function(d){return/^([A-Z]{2}|[0-9]{2})[ -Β·]?([A-Z]{2}|[0-9]{2})[ -Β·]?([A-Z]{2}|[0-9]{2})$/.test(d)},"sq-AL":function(d){return/^[A-Z]{2}[- ]?((\d{3}[- ]?(([A-Z]{2})|T))|(R[- ]?\d{3}))$/.test(d)},"sv-SE":function(d){return/^[A-HJ-PR-UW-Z]{3} ?[\d]{2}[A-HJ-PR-UW-Z1-9]$|(^[A-ZÅÄÖ ]{2,7}$)/.test(d.trim())},"en-PK":function(d){return/(^[A-Z]{2}((\s|-){0,1})[0-9]{3,4}((\s|-)[0-9]{2}){0,1}$)|(^[A-Z]{3}((\s|-){0,1})[0-9]{3,4}((\s|-)[0-9]{2}){0,1}$)|(^[A-Z]{4}((\s|-){0,1})[0-9]{3,4}((\s|-)[0-9]{2}){0,1}$)|(^[A-Z]((\s|-){0,1})[0-9]{4}((\s|-)[0-9]{2}){0,1}$)/.test(d.trim())}};function a(l,d){if((0,n.default)(l),d in o)return o[d](l);if(d==="any"){for(var h in o){var p=o[h];if(p(l))return!0}return!1}throw new Error("Invalid locale '".concat(d,"'"))}e.exports=t.default,e.exports.default=t.default}(ok,ok.exports)),ok.exports}var ak={exports:{}},dj;function vce(){return dj||(dj=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=_;var n=o(Na()),r=o(gt());function o(w){return w&&w.__esModule?w:{default:w}}var a=/^[A-Z]$/,l=/^[a-z]$/,d=/^[0-9]$/,h=/^[-#!$@Β£%^&*()_+|~=`{}\[\]:";'<>?,.\/\\ ]$/,p={minLength:8,minLowercase:1,minUppercase:1,minNumbers:1,minSymbols:1,returnScore:!1,pointsPerUnique:1,pointsPerRepeat:.5,pointsForContainingLower:10,pointsForContainingUpper:10,pointsForContainingNumber:10,pointsForContainingSymbol:10};function y(w){var k={};return Array.from(w).forEach(function(A){var E=k[A];E?k[A]+=1:k[A]=1}),k}function m(w){var k=y(w),A={length:w.length,uniqueChars:Object.keys(k).length,uppercaseCount:0,lowercaseCount:0,numberCount:0,symbolCount:0};return Object.keys(k).forEach(function(E){a.test(E)?A.uppercaseCount+=k[E]:l.test(E)?A.lowercaseCount+=k[E]:d.test(E)?A.numberCount+=k[E]:h.test(E)&&(A.symbolCount+=k[E])}),A}function x(w,k){var A=0;return A+=w.uniqueChars*k.pointsPerUnique,A+=(w.length-w.uniqueChars)*k.pointsPerRepeat,w.lowercaseCount>0&&(A+=k.pointsForContainingLower),w.uppercaseCount>0&&(A+=k.pointsForContainingUpper),w.numberCount>0&&(A+=k.pointsForContainingNumber),w.symbolCount>0&&(A+=k.pointsForContainingSymbol),A}function _(w){var k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;(0,r.default)(w);var A=m(w);return k=(0,n.default)(k||{},p),k.returnScore?x(A,k):A.length>=k.minLength&&A.lowercaseCount>=k.minLowercase&&A.uppercaseCount>=k.minUppercase&&A.numberCount>=k.minNumbers&&A.symbolCount>=k.minSymbols}e.exports=t.default,e.exports.default=t.default}(ak,ak.exports)),ak.exports}var Nm={},hj;function yce(){if(hj)return Nm;hj=1;function e(m){"@babel/helpers - typeof";return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(x){return typeof x}:function(x){return x&&typeof Symbol=="function"&&x.constructor===Symbol&&x!==Symbol.prototype?"symbol":typeof x},e(m)}Object.defineProperty(Nm,"__esModule",{value:!0}),Nm.default=y,Nm.vatMatchers=void 0;var t=a(gt()),n=o(TU());function r(m){if(typeof WeakMap!="function")return null;var x=new WeakMap,_=new WeakMap;return(r=function(k){return k?_:x})(m)}function o(m,x){if(m&&m.__esModule)return m;if(m===null||e(m)!="object"&&typeof m!="function")return{default:m};var _=r(x);if(_&&_.has(m))return _.get(m);var w={__proto__:null},k=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var A in m)if(A!=="default"&&{}.hasOwnProperty.call(m,A)){var E=k?Object.getOwnPropertyDescriptor(m,A):null;E&&(E.get||E.set)?Object.defineProperty(w,A,E):w[A]=m[A]}return w.default=m,_&&_.set(m,w),w}function a(m){return m&&m.__esModule?m:{default:m}}var l=function(x){var _=x.match(/^(AU)?(\d{11})$/);if(!_)return!1;var w=[10,1,3,5,7,9,11,13,15,17,19];x=x.replace(/^AU/,"");for(var k=(parseInt(x.slice(0,1),10)-1).toString()+x.slice(1),A=0,E=0;E<11;E++)A+=w[E]*k.charAt(E);return A!==0&&A%89===0},d=function(x){var _=function(k){var A=k.pop(),E=[5,4,3,2,7,6,5,4],R=(11-k.reduce(function(O,I,L){return O+I*E[L]},0)%11)%11;return A===R};return/^(CHE[- ]?)?(\d{9}|(\d{3}\.\d{3}\.\d{3})|(\d{3} \d{3} \d{3})) ?(TVA|MWST|IVA)?$/.test(x)&&_(x.match(/\d/g).map(function(w){return+w}))},h=function(x){var _=x.match(/^(PT)?(\d{9})$/);if(!_)return!1;var w=_[2],k=11-n.reverseMultiplyAndSum(w.split("").slice(0,8).map(function(A){return parseInt(A,10)}),9)%11;return k>9?parseInt(w[8],10)===0:k===parseInt(w[8],10)},p=Nm.vatMatchers={AT:function(x){return/^(AT)?U\d{8}$/.test(x)},BE:function(x){return/^(BE)?\d{10}$/.test(x)},BG:function(x){return/^(BG)?\d{9,10}$/.test(x)},HR:function(x){return/^(HR)?\d{11}$/.test(x)},CY:function(x){return/^(CY)?\w{9}$/.test(x)},CZ:function(x){return/^(CZ)?\d{8,10}$/.test(x)},DK:function(x){return/^(DK)?\d{8}$/.test(x)},EE:function(x){return/^(EE)?\d{9}$/.test(x)},FI:function(x){return/^(FI)?\d{8}$/.test(x)},FR:function(x){return/^(FR)?\w{2}\d{9}$/.test(x)},DE:function(x){return/^(DE)?\d{9}$/.test(x)},EL:function(x){return/^(EL)?\d{9}$/.test(x)},HU:function(x){return/^(HU)?\d{8}$/.test(x)},IE:function(x){return/^(IE)?\d{7}\w{1}(W)?$/.test(x)},IT:function(x){return/^(IT)?\d{11}$/.test(x)},LV:function(x){return/^(LV)?\d{11}$/.test(x)},LT:function(x){return/^(LT)?\d{9,12}$/.test(x)},LU:function(x){return/^(LU)?\d{8}$/.test(x)},MT:function(x){return/^(MT)?\d{8}$/.test(x)},NL:function(x){return/^(NL)?\d{9}B\d{2}$/.test(x)},PL:function(x){return/^(PL)?(\d{10}|(\d{3}-\d{3}-\d{2}-\d{2})|(\d{3}-\d{2}-\d{2}-\d{3}))$/.test(x)},PT:h,RO:function(x){return/^(RO)?\d{2,10}$/.test(x)},SK:function(x){return/^(SK)?\d{10}$/.test(x)},SI:function(x){return/^(SI)?\d{8}$/.test(x)},ES:function(x){return/^(ES)?\w\d{7}[A-Z]$/.test(x)},SE:function(x){return/^(SE)?\d{12}$/.test(x)},AL:function(x){return/^(AL)?\w{9}[A-Z]$/.test(x)},MK:function(x){return/^(MK)?\d{13}$/.test(x)},AU:l,BY:function(x){return/^(УНП )?\d{9}$/.test(x)},CA:function(x){return/^(CA)?\d{9}$/.test(x)},IS:function(x){return/^(IS)?\d{5,6}$/.test(x)},IN:function(x){return/^(IN)?\d{15}$/.test(x)},ID:function(x){return/^(ID)?(\d{15}|(\d{2}.\d{3}.\d{3}.\d{1}-\d{3}.\d{3}))$/.test(x)},IL:function(x){return/^(IL)?\d{9}$/.test(x)},KZ:function(x){return/^(KZ)?\d{12}$/.test(x)},NZ:function(x){return/^(NZ)?\d{9}$/.test(x)},NG:function(x){return/^(NG)?(\d{12}|(\d{8}-\d{4}))$/.test(x)},NO:function(x){return/^(NO)?\d{9}MVA$/.test(x)},PH:function(x){return/^(PH)?(\d{12}|\d{3} \d{3} \d{3} \d{3})$/.test(x)},RU:function(x){return/^(RU)?(\d{10}|\d{12})$/.test(x)},SM:function(x){return/^(SM)?\d{5}$/.test(x)},SA:function(x){return/^(SA)?\d{15}$/.test(x)},RS:function(x){return/^(RS)?\d{9}$/.test(x)},CH:d,TR:function(x){return/^(TR)?\d{10}$/.test(x)},UA:function(x){return/^(UA)?\d{12}$/.test(x)},GB:function(x){return/^GB((\d{3} \d{4} ([0-8][0-9]|9[0-6]))|(\d{9} \d{3})|(((GD[0-4])|(HA[5-9]))[0-9]{2}))$/.test(x)},UZ:function(x){return/^(UZ)?\d{9}$/.test(x)},AR:function(x){return/^(AR)?\d{11}$/.test(x)},BO:function(x){return/^(BO)?\d{7}$/.test(x)},BR:function(x){return/^(BR)?((\d{2}.\d{3}.\d{3}\/\d{4}-\d{2})|(\d{3}.\d{3}.\d{3}-\d{2}))$/.test(x)},CL:function(x){return/^(CL)?\d{8}-\d{1}$/.test(x)},CO:function(x){return/^(CO)?\d{10}$/.test(x)},CR:function(x){return/^(CR)?\d{9,12}$/.test(x)},EC:function(x){return/^(EC)?\d{13}$/.test(x)},SV:function(x){return/^(SV)?\d{4}-\d{6}-\d{3}-\d{1}$/.test(x)},GT:function(x){return/^(GT)?\d{7}-\d{1}$/.test(x)},HN:function(x){return/^(HN)?$/.test(x)},MX:function(x){return/^(MX)?\w{3,4}\d{6}\w{3}$/.test(x)},NI:function(x){return/^(NI)?\d{3}-\d{6}-\d{4}\w{1}$/.test(x)},PA:function(x){return/^(PA)?$/.test(x)},PY:function(x){return/^(PY)?\d{6,8}-\d{1}$/.test(x)},PE:function(x){return/^(PE)?\d{11}$/.test(x)},DO:function(x){return/^(DO)?(\d{11}|(\d{3}-\d{7}-\d{1})|[1,4,5]{1}\d{8}|([1,4,5]{1})-\d{2}-\d{5}-\d{1})$/.test(x)},UY:function(x){return/^(UY)?\d{12}$/.test(x)},VE:function(x){return/^(VE)?[J,G,V,E]{1}-(\d{9}|(\d{8}-\d{1}))$/.test(x)}};function y(m,x){if((0,t.default)(m),(0,t.default)(x),x in p)return p[x](m);throw new Error("Invalid country code: '".concat(x,"'"))}return Nm}var pj;function xce(){return pj||(pj=1,function(e,t){function n(ce){"@babel/helpers - typeof";return n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Ie){return typeof Ie}:function(Ie){return Ie&&typeof Symbol=="function"&&Ie.constructor===Symbol&&Ie!==Symbol.prototype?"symbol":typeof Ie},n(ce)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=ot(VD()),o=ot(eF()),a=ot(Ple()),l=ot(Hle()),d=ot(qle()),h=ot(Gle()),p=ot(Vle()),y=ot(mF()),m=ot(Yle()),x=ot(Zle()),_=ot(BE()),w=ot(Qle()),k=ot(YD()),A=ot(_F()),E=ot(Kle()),R=ot(Wle()),O=ot(Xle()),I=ot(Jle()),L=Kr(eue()),N=Kr(tue()),H=ot(nue()),V=Kr(rue()),W=ot(iue()),z=ot(oue()),Q=ot(aue()),J=ot(sue()),ie=ot(lue()),ee=ot(NF()),de=ot(FF()),ue=ot(uue()),se=ot(cue()),pe=ot(due()),Ce=ot(hue()),B=ot(ZD()),P=Kr(Xz()),ne=ot(gue()),U=ot(ZF()),fe=ot(mue()),Ae=ot(vue()),Te=ot(yue()),rt=ot(xue()),Ge=ot(bue()),We=ot(_ue()),Tt=Kr(Sue()),It=ot(wue()),nt=ot(Cue()),dt=ot(Eue()),bt=ot(Aue()),Et=ot(kue()),Nt=ot(Tue()),yt=ot(Rue()),re=ot(dF()),le=ot(Oue()),ve=ot(Due()),Ee=ot(Mue()),$e=ot(Iue()),Ve=ot($ue()),lt=ot(Bue()),mt=ot(bU()),_e=ot(Lue()),Re=ot(Nue()),Ct=ot(zue()),ct=ot(Fue()),Rt=ot(Uue()),Mt=ot(jue()),en=ot(Pue()),Qt=Kr(Hue()),gn=ot(que()),pt=ot(Gue()),Kt=ot(Vue()),_t=Yue(),Y=ot(Zue()),xe=ot(Que()),it=ot(Kue()),st=ot(Wue()),St=ot(rU()),Pt=ot(Xue()),Ht=ot(Jue()),Yt=ot(ece()),qt=ot(tce()),ln=ot(nce()),hr=ot(lU()),xr=ot(rce()),Ur=ot(ice()),nn=ot(oce()),yn=ot(ace()),fn=ot(sce()),ho=Kr(lce()),br=ot(QU()),us=ot(YU()),ji=ot(WU()),Ho=ot(uce()),Dt=ot(cce()),to=ot(fce()),rr=ot(dce()),Ro=ot(oj()),po=ot(hce()),qn=ot(pce()),ua=ot(gce()),Oi=ot(mce()),pr=ot(vce()),Br=ot(yce());function ca(ce){if(typeof WeakMap!="function")return null;var Ie=new WeakMap,j=new WeakMap;return(ca=function(he){return he?j:Ie})(ce)}function Kr(ce,Ie){if(ce&&ce.__esModule)return ce;if(ce===null||n(ce)!="object"&&typeof ce!="function")return{default:ce};var j=ca(Ie);if(j&&j.has(ce))return j.get(ce);var te={__proto__:null},he=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ke in ce)if(ke!=="default"&&{}.hasOwnProperty.call(ce,ke)){var we=he?Object.getOwnPropertyDescriptor(ce,ke):null;we&&(we.get||we.set)?Object.defineProperty(te,ke,we):te[ke]=ce[ke]}return te.default=ce,j&&j.set(ce,te),te}function ot(ce){return ce&&ce.__esModule?ce:{default:ce}}var Oe="13.15.0",at={version:Oe,toDate:r.default,toFloat:o.default,toInt:a.default,toBoolean:l.default,equals:d.default,contains:h.default,matches:p.default,isEmail:y.default,isURL:m.default,isMACAddress:x.default,isIP:_.default,isIPRange:w.default,isFQDN:k.default,isBoolean:R.default,isIBAN:Tt.default,isBIC:It.default,isAbaRouting:I.default,isAlpha:L.default,isAlphaLocales:L.locales,isAlphanumeric:N.default,isAlphanumericLocales:N.locales,isNumeric:H.default,isPassportNumber:V.default,passportNumberLocales:V.locales,isPort:W.default,isLowercase:z.default,isUppercase:Q.default,isAscii:ie.default,isFullWidth:ee.default,isHalfWidth:de.default,isVariableWidth:ue.default,isMultibyte:se.default,isSemVer:pe.default,isSurrogatePair:Ce.default,isInt:B.default,isIMEI:J.default,isFloat:P.default,isFloatLocales:P.locales,isDecimal:ne.default,isHexadecimal:U.default,isOctal:fe.default,isDivisibleBy:Ae.default,isHexColor:Te.default,isRgbColor:rt.default,isHSL:Ge.default,isISRC:We.default,isMD5:nt.default,isHash:dt.default,isJWT:bt.default,isJSON:Et.default,isEmpty:Nt.default,isLength:yt.default,isLocale:O.default,isByteLength:re.default,isULID:le.default,isUUID:ve.default,isMongoId:Ee.default,isAfter:$e.default,isBefore:Ve.default,isIn:lt.default,isLuhnNumber:mt.default,isCreditCard:_e.default,isIdentityCard:Re.default,isEAN:Ct.default,isISIN:ct.default,isISBN:Rt.default,isISSN:Mt.default,isMobilePhone:Qt.default,isMobilePhoneLocales:Qt.locales,isPostalCode:ho.default,isPostalCodeLocales:ho.locales,isEthereumAddress:gn.default,isCurrency:pt.default,isBtcAddress:Kt.default,isISO6346:_t.isISO6346,isFreightContainerID:_t.isFreightContainerID,isISO6391:Y.default,isISO8601:xe.default,isISO15924:st.default,isRFC3339:it.default,isISO31661Alpha2:St.default,isISO31661Alpha3:Pt.default,isISO31661Numeric:Ht.default,isISO4217:Yt.default,isBase32:qt.default,isBase58:ln.default,isBase64:hr.default,isDataURI:xr.default,isMagnetURI:Ur.default,isMailtoURI:nn.default,isMimeType:yn.default,isLatLong:fn.default,ltrim:br.default,rtrim:us.default,trim:ji.default,escape:Ho.default,unescape:Dt.default,stripLow:to.default,whitelist:rr.default,blacklist:Ro.default,isWhitelisted:po.default,normalizeEmail:qn.default,toString,isSlug:ua.default,isStrongPassword:pr.default,isTaxID:en.default,isDate:A.default,isTime:E.default,isLicensePlate:Oi.default,isVAT:Br.default,ibanLocales:Tt.locales};t.default=at,e.exports=t.default,e.exports.default=t.default}(yE,yE.exports)),yE.exports}var zm=xce();const tn={OPEN_STATE_CHANGE:"open_state_change",CHAT_BUTTON_CLICKED:"Chat button clicked",USER_FORM_FILLED:"User form filled",ADD_BULK_ITEM:"Add bulk item",USER_FORM_CLOSE:"user_form_close",CHECKOUT_CLICKED:"Checkout Clicked",ADD_TO_CART_CLICKED:"add to cart clicked",SUGGESTED_QUESTION_CLICKED:"Suggested Question Clicked",INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED:"Initial Leading Query Suggested Question Clicked",LEADING_QUERY_CLICKED:"Leading Query Clicked",COLLECTION_VIDEO_CLICKED:"Collection Video Clicked",COLLECTION_IMAGE_CLICKED:"Collection Image Clicked",VIEW_PRODUCT_CLICKED:"view product clicked",PRODUCT_VIDEO_CLICKED:"Product Video Clicked",PRODUCT_IMAGE_CLICKED:"Product Image Clicked",SHOW_SIMILAR_CLICKED:"show similar clicked",CHAT_MESSAGE_SENT:"chat_message_sent",CHAT_MESSAGE_TYPING_STARTED:"chat_message_typing_started",CHAT_MESSAGE_TYPING_ENDED:"chat_message_typing_ended",DISCOUNT_VIEWED:"discount_viewed",SHOPIFY_LINK_CLICKED:"shopify_link_clicked"},Qr={OPEN_STATE_CHANGE:"open_state_change"},gj=Z.createContext(null),Fd=()=>{const e=Z.useContext(gj);if(!e)throw new Error("useCart must be used within a CartProvider");return e};var bce="2.0.0",Fm="",mj="?",sk="function",Ud="undefined",Um="object",QD="string",Ax="major",xt="model",ht="name",ft="type",At="vendor",vt="version",ss="architecture",jm="console",Mn="mobile",di="tablet",la="smarttv",kx="wearable",KD="xr",WD="embedded",Tx="inapp",vj="user-agent",XD=500,JD="brands",Lp="formFactors",e8="fullVersionList",Pm="platform",t8="platformVersion",lk="bitness",jd="sec-ch-ua",_ce=jd+"-full-version-list",Sce=jd+"-arch",wce=jd+"-"+lk,Cce=jd+"-form-factors",Ece=jd+"-"+Mn,Ace=jd+"-"+xt,yj=jd+"-"+Pm,kce=yj+"-version",xj=[JD,e8,Mn,xt,Pm,t8,ss,Lp,lk],Rs="browser",lf="cpu",Wu="device",uf="engine",gl="os",Hm="result",uk="Amazon",Rx="Apple",bj="ASUS",_j="BlackBerry",Np="Google",Sj="Huawei",wj="Lenovo",Tce="Honor",n8="LG",ck="Microsoft",Cj="Motorola",Ox="Samsung",Ej="Sharp",fk="Sony",r8="Xiaomi",i8="Zebra",qm="Mobile ",Dx=" Browser",Aj="Chrome",Pd="Chromecast",Rce="Edge",Mx="Firefox",Ix="Opera",kj="Facebook",Tj="Sogou",o8="Windows",Oce=typeof window!==Ud,ls=Oce&&window.navigator?window.navigator:void 0,Hd=ls&&ls.userAgentData?ls.userAgentData:void 0,Dce=function(e,t){var n={},r=t;if(!hk(t)){r={};for(var o in t)for(var a in t[o])r[a]=t[o][a].concat(r[a]?r[a]:[])}for(var l in e)n[l]=r[l]&&r[l].length%2===0?r[l].concat(e[l]):e[l];return n},dk=function(e){for(var t={},n=0;n<e.length;n++)t[e[n].toUpperCase()]=e[n];return t},a8=function(e,t){if(typeof e===Um&&e.length>0){for(var n in e)if(cf(e[n])==cf(t))return!0;return!1}return Gm(e)?cf(t).indexOf(cf(e))!==-1:!1},hk=function(e,t){for(var n in e)return/^(browser|cpu|device|engine|os)$/.test(n)||(t?hk(e[n]):!1)},Gm=function(e){return typeof e===QD},s8=function(e){if(e){for(var t=[],n=zp(/\\?\"/g,e).split(","),r=0;r<n.length;r++)if(n[r].indexOf(";")>-1){var o=Bx(n[r]).split(";v=");t[r]={brand:o[0],version:o[1]}}else t[r]=Bx(n[r]);return t}},cf=function(e){return Gm(e)?e.toLowerCase():e},l8=function(e){return Gm(e)?zp(/[^\d\.]/g,e).split(".")[0]:void 0},ff=function(e){for(var t in e){var n=e[t];typeof n==Um&&n.length==2?this[n[0]]=n[1]:this[n]=void 0}return this},zp=function(e,t){return Gm(t)?t.replace(e,Fm):t},$x=function(e){return zp(/\\?\"/g,e)},Bx=function(e,t){if(Gm(e))return e=zp(/^\s\s*/,e),typeof t===Ud?e:e.substring(0,XD)},Rj=function(e,t){if(!(!e||!t))for(var n=0,r,o,a,l,d,h;n<t.length&&!d;){var p=t[n],y=t[n+1];for(r=o=0;r<p.length&&!d&&p[r];)if(d=p[r++].exec(e),d)for(a=0;a<y.length;a++)h=d[++o],l=y[a],typeof l===Um&&l.length>0?l.length===2?typeof l[1]==sk?this[l[0]]=l[1].call(this,h):this[l[0]]=l[1]:l.length===3?typeof l[1]===sk&&!(l[1].exec&&l[1].test)?this[l[0]]=h?l[1].call(this,h,l[2]):void 0:this[l[0]]=h?h.replace(l[1],l[2]):void 0:l.length===4&&(this[l[0]]=h?l[3].call(this,h.replace(l[1],l[2])):void 0):this[l]=h||void 0;n+=2}},Lx=function(e,t){for(var n in t)if(typeof t[n]===Um&&t[n].length>0){for(var r=0;r<t[n].length;r++)if(a8(t[n][r],e))return n===mj?void 0:n}else if(a8(t[n],e))return n===mj?void 0:n;return t.hasOwnProperty("*")?t["*"]:e},Oj={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2","8.1":"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},Dj={embedded:"Automotive",mobile:"Mobile",tablet:["Tablet","EInk"],smarttv:"TV",wearable:"Watch",xr:["VR","XR"],"?":["Desktop","Unknown"],"*":void 0},Mj={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[vt,[ht,qm+"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[vt,[ht,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[ht,vt],[/opios[\/ ]+([\w\.]+)/i],[vt,[ht,Ix+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[vt,[ht,Ix+" GX"]],[/\bopr\/([\w\.]+)/i],[vt,[ht,Ix]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[vt,[ht,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[vt,[ht,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon)\/([-\w\.]+)/i,/(heytap|ovi|115)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[ht,vt],[/quark(?:pc)?\/([-\w\.]+)/i],[vt,[ht,"Quark"]],[/\bddg\/([\w\.]+)/i],[vt,[ht,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[vt,[ht,"UCBrowser"]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[vt,[ht,"WeChat"]],[/konqueror\/([\w\.]+)/i],[vt,[ht,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[vt,[ht,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[vt,[ht,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[vt,[ht,"Smart "+wj+Dx]],[/(avast|avg)\/([\w\.]+)/i],[[ht,/(.+)/,"$1 Secure"+Dx],vt],[/\bfocus\/([\w\.]+)/i],[vt,[ht,Mx+" Focus"]],[/\bopt\/([\w\.]+)/i],[vt,[ht,Ix+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[vt,[ht,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[vt,[ht,"Dolphin"]],[/coast\/([\w\.]+)/i],[vt,[ht,Ix+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[vt,[ht,"MIUI"+Dx]],[/fxios\/([\w\.-]+)/i],[vt,[ht,qm+Mx]],[/\bqihoobrowser\/?([\w\.]*)/i],[vt,[ht,"360"]],[/\b(qq)\/([\w\.]+)/i],[[ht,/(.+)/,"$1Browser"],vt],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[ht,/(.+)/,"$1"+Dx],vt],[/samsungbrowser\/([\w\.]+)/i],[vt,[ht,Ox+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[vt,[ht,Tj+" Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[ht,Tj+" Mobile"],vt],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[ht,vt],[/(lbbrowser|rekonq)/i],[ht],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[vt,ht],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[ht,kj],vt,[ft,Tx]],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(instagram|snapchat)[\/ ]([-\w\.]+)/i],[ht,vt,[ft,Tx]],[/\bgsa\/([\w\.]+) .*safari\//i],[vt,[ht,"GSA"],[ft,Tx]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[vt,[ht,"TikTok"],[ft,Tx]],[/\[(linkedin)app\]/i],[ht,[ft,Tx]],[/(chromium)[\/ ]([-\w\.]+)/i],[ht,vt],[/headlesschrome(?:\/([\w\.]+)| )/i],[vt,[ht,Aj+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[ht,Aj+" WebView"],vt],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[vt,[ht,"Android"+Dx]],[/chrome\/([\w\.]+) mobile/i],[vt,[ht,qm+"Chrome"]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[ht,vt],[/version\/([\w\.\,]+) .*mobile(?:\/\w+ | ?)safari/i],[vt,[ht,qm+"Safari"]],[/iphone .*mobile(?:\/\w+ | ?)safari/i],[[ht,qm+"Safari"]],[/version\/([\w\.\,]+) .*(safari)/i],[vt,ht],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[ht,[vt,"1"]],[/(webkit|khtml)\/([\w\.]+)/i],[ht,vt],[/(?:mobile|tablet);.*(firefox)\/([\w\.-]+)/i],[[ht,qm+Mx],vt],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[ht,"Netscape"],vt],[/(wolvic|librewolf)\/([\w\.]+)/i],[ht,vt],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[vt,[ht,Mx+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/\b(links) \(([\w\.]+)/i],[ht,[vt,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[ht,[vt,/[^\d\.]+./,Fm]]],cpu:[[/\b(?:(amd|x|x86[-_]?|wow|win)64)\b/i],[[ss,"amd64"]],[/(ia32(?=;))/i,/((?:i[346]|x)86)[;\)]/i],[[ss,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[ss,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[ss,"armhf"]],[/windows (ce|mobile); ppc;/i],[[ss,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[ss,/ower/,Fm,cf]],[/(sun4\w)[;\)]/i],[[ss,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[ss,cf]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[xt,[At,Ox],[ft,di]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr])[-\w]+)/i,/sec-(sgh\w+)/i],[xt,[At,Ox],[ft,Mn]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[xt,[At,Rx],[ft,Mn]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[xt,[At,Rx],[ft,di]],[/(macintosh);/i],[xt,[At,Rx]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[xt,[At,Ej],[ft,Mn]],[/(?:honor)([-\w ]+)[;\)]/i],[xt,[At,Tce],[ft,Mn]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[xt,[At,Sj],[ft,di]],[/(?:huawei)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[xt,[At,Sj],[ft,Mn]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite|pro)?)(?: bui|\))/i],[[xt,/_/g," "],[At,r8],[ft,Mn]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[xt,/_/g," "],[At,r8],[ft,di]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[xt,[At,"OPPO"],[ft,Mn]],[/\b(opd2\d{3}a?) bui/i],[xt,[At,"OPPO"],[ft,di]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[xt,[At,"Vivo"],[ft,Mn]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[xt,[At,"Realme"],[ft,Mn]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[xt,[At,Cj],[ft,Mn]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[xt,[At,Cj],[ft,di]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[xt,[At,n8],[ft,di]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[xt,[At,n8],[ft,Mn]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[xt,[At,wj],[ft,di]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[xt,/_/g," "],[At,"Nokia"],[ft,Mn]],[/(pixel c)\b/i],[xt,[At,Np],[ft,di]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[xt,[At,Np],[ft,Mn]],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[xt,[At,fk],[ft,Mn]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[xt,"Xperia Tablet"],[At,fk],[ft,di]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[xt,[At,"OnePlus"],[ft,Mn]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[xt,[At,uk],[ft,di]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[xt,/(.+)/g,"Fire Phone $1"],[At,uk],[ft,Mn]],[/(playbook);[-\w\),; ]+(rim)/i],[xt,At,[ft,di]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[xt,[At,_j],[ft,Mn]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[xt,[At,bj],[ft,di]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[xt,[At,bj],[ft,Mn]],[/(nexus 9)/i],[xt,[At,"HTC"],[ft,di]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[At,[xt,/_/g," "],[ft,Mn]],[/tcl (xess p17aa)/i,/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])(_\w(\w|\w\w))?(\)| bui)/i],[xt,[At,"TCL"],[ft,di]],[/droid [\w\.]+; (418(?:7d|8v)|5087z|5102l|61(?:02[dh]|25[adfh]|27[ai]|56[dh]|59k|65[ah])|a509dl|t(?:43(?:0w|1[adepqu])|50(?:6d|7[adju])|6(?:09dl|10k|12b|71[efho]|76[hjk])|7(?:66[ahju]|67[hw]|7[045][bh]|71[hk]|73o|76[ho]|79w|81[hks]?|82h|90[bhsy]|99b)|810[hs]))(_\w(\w|\w\w))?(\)| bui)/i],[xt,[At,"TCL"],[ft,Mn]],[/(itel) ((\w+))/i],[[At,cf],xt,[ft,Lx,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[xt,[At,"Acer"],[ft,di]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[xt,[At,"Meizu"],[ft,Mn]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[xt,[At,"Ulefone"],[ft,Mn]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[xt,[At,"Energizer"],[ft,Mn]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[xt,[At,"Cat"],[ft,Mn]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[xt,[At,"Smartfren"],[ft,Mn]],[/droid.+; (a(?:015|06[35]|142p?))/i],[xt,[At,"Nothing"],[ft,Mn]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (imo) ((?!tab)[\w ]+?)(?: bui|\))/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[At,xt,[ft,Mn]],[/(imo) (tab \w+)/i,/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i],[At,xt,[ft,di]],[/(surface duo)/i],[xt,[At,ck],[ft,di]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[xt,[At,"Fairphone"],[ft,Mn]],[/(shield[\w ]+) b/i],[xt,[At,"Nvidia"],[ft,di]],[/(sprint) (\w+)/i],[At,xt,[ft,Mn]],[/(kin\.[onetw]{3})/i],[[xt,/\./g," "],[At,ck],[ft,Mn]],[/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[xt,[At,i8],[ft,di]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[xt,[At,i8],[ft,Mn]],[/smart-tv.+(samsung)/i],[At,[ft,la]],[/hbbtv.+maple;(\d+)/i],[[xt,/^/,"SmartTV"],[At,Ox],[ft,la]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[At,n8],[ft,la]],[/(apple) ?tv/i],[At,[xt,Rx+" TV"],[ft,la]],[/crkey.*devicetype\/chromecast/i],[[xt,Pd+" Third Generation"],[At,Np],[ft,la]],[/crkey.*devicetype\/([^/]*)/i],[[xt,/^/,"Chromecast "],[At,Np],[ft,la]],[/fuchsia.*crkey/i],[[xt,Pd+" Nest Hub"],[At,Np],[ft,la]],[/crkey/i],[[xt,Pd],[At,Np],[ft,la]],[/droid.+aft(\w+)( bui|\))/i],[xt,[At,uk],[ft,la]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[xt,[At,Ej],[ft,la]],[/(bravia[\w ]+)( bui|\))/i],[xt,[At,fk],[ft,la]],[/(mitv-\w{5}) bui/i],[xt,[At,r8],[ft,la]],[/Hbbtv.*(technisat) (.*);/i],[At,xt,[ft,la]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[At,Bx],[xt,Bx],[ft,la]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[ft,la]],[/(ouya)/i,/(nintendo) (\w+)/i],[At,xt,[ft,jm]],[/droid.+; (shield) bui/i],[xt,[At,"Nvidia"],[ft,jm]],[/(playstation \w+)/i],[xt,[At,fk],[ft,jm]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[xt,[At,ck],[ft,jm]],[/\b(sm-[lr]\d\d[05][fnuw]?s?)\b/i],[xt,[At,Ox],[ft,kx]],[/((pebble))app/i],[At,xt,[ft,kx]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[xt,[At,Rx],[ft,kx]],[/droid.+; (wt63?0{2,3})\)/i],[xt,[At,i8],[ft,kx]],[/droid.+; (glass) \d/i],[xt,[At,Np],[ft,KD]],[/(pico) (4|neo3(?: link|pro)?)/i],[At,xt,[ft,KD]],[/; (quest( \d| pro)?)/i],[xt,[At,kj],[ft,KD]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[At,[ft,WD]],[/(aeobc)\b/i],[xt,[At,uk],[ft,WD]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[xt,[ft,Mn]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[xt,[ft,di]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[ft,di]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[ft,Mn]],[/(android[-\w\. ]{0,9});.+buil/i],[xt,[At,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[vt,[ht,Rce+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[ht,vt],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[vt,[ht,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[ht,vt],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[vt,ht]],os:[[/microsoft (windows) (vista|xp)/i],[ht,vt],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[ht,[vt,Lx,Oj]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[vt,Lx,Oj],[ht,o8]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[vt,/_/g,"."],[ht,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[ht,"macOS"],[vt,/_/g,"."]],[/android ([\d\.]+).*crkey/i],[vt,[ht,Pd+" Android"]],[/fuchsia.*crkey\/([\d\.]+)/i],[vt,[ht,Pd+" Fuchsia"]],[/crkey\/([\d\.]+).*devicetype\/smartspeaker/i],[vt,[ht,Pd+" SmartSpeaker"]],[/linux.*crkey\/([\d\.]+)/i],[vt,[ht,Pd+" Linux"]],[/crkey\/([\d\.]+)/i],[vt,[ht,Pd]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[vt,ht],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish|openharmony)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[ht,vt],[/\(bb(10);/i],[vt,[ht,_j]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[vt,[ht,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[vt,[ht,Mx+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[vt,[ht,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[vt,[ht,"watchOS"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[ht,"Chrome OS"],vt],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) (\w+)/i,/(xbox); +xbox ([^\);]+)/i,/(pico) .+os([\w\.]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[ht,vt],[/(sunos) ?([\w\.\d]*)/i],[[ht,"Solaris"],vt],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[ht,vt]]},pk=function(){var e={init:{},isIgnore:{},isIgnoreRgx:{},toString:{}};return ff.call(e.init,[[Rs,[ht,vt,Ax,ft]],[lf,[ss]],[Wu,[ft,xt,At]],[uf,[ht,vt]],[gl,[ht,vt]]]),ff.call(e.isIgnore,[[Rs,[vt,Ax]],[uf,[vt]],[gl,[vt]]]),ff.call(e.isIgnoreRgx,[[Rs,/ ?browser$/i],[gl,/ ?os$/i]]),ff.call(e.toString,[[Rs,[ht,vt]],[lf,[ss]],[Wu,[At,xt]],[uf,[ht,vt]],[gl,[ht,vt]]]),e}(),Mce=function(e,t){var n=pk.init[t],r=pk.isIgnore[t]||0,o=pk.isIgnoreRgx[t]||0,a=pk.toString[t]||0;function l(){ff.call(this,n)}return l.prototype.getItem=function(){return e},l.prototype.withClientHints=function(){return Hd?Hd.getHighEntropyValues(xj).then(function(d){return e.setCH(new Ij(d,!1)).parseCH().get()}):e.parseCH().get()},l.prototype.withFeatureCheck=function(){return e.detectFeature().get()},t!=Hm&&(l.prototype.is=function(d){var h=!1;for(var p in this)if(this.hasOwnProperty(p)&&!a8(r,p)&&cf(o?zp(o,this[p]):this[p])==cf(o?zp(o,d):d)){if(h=!0,d!=Ud)break}else if(d==Ud&&h){h=!h;break}return h},l.prototype.toString=function(){var d=Fm;for(var h in a)typeof this[a[h]]!==Ud&&(d+=(d?" ":Fm)+this[a[h]]);return d||Ud}),Hd||(l.prototype.then=function(d){var h=this,p=function(){for(var m in h)h.hasOwnProperty(m)&&(this[m]=h[m])};p.prototype={is:l.prototype.is,toString:l.prototype.toString};var y=new p;return d(y),y}),new l};function Ij(e,t){if(e=e||{},ff.call(this,xj),t)ff.call(this,[[JD,s8(e[jd])],[e8,s8(e[_ce])],[Mn,/\?1/.test(e[Ece])],[xt,$x(e[Ace])],[Pm,$x(e[yj])],[t8,$x(e[kce])],[ss,$x(e[Sce])],[Lp,s8(e[Cce])],[lk,$x(e[wce])]]);else for(var n in e)this.hasOwnProperty(n)&&typeof e[n]!==Ud&&(this[n]=e[n])}function $j(e,t,n,r){return this.get=function(o){return o?this.data.hasOwnProperty(o)?this.data[o]:void 0:this.data},this.set=function(o,a){return this.data[o]=a,this},this.setCH=function(o){return this.uaCH=o,this},this.detectFeature=function(){if(ls&&ls.userAgent==this.ua)switch(this.itemType){case Rs:ls.brave&&typeof ls.brave.isBrave==sk&&this.set(ht,"Brave");break;case Wu:!this.get(ft)&&Hd&&Hd[Mn]&&this.set(ft,Mn),this.get(xt)=="Macintosh"&&ls&&typeof ls.standalone!==Ud&&ls.maxTouchPoints&&ls.maxTouchPoints>2&&this.set(xt,"iPad").set(ft,di);break;case gl:!this.get(ht)&&Hd&&Hd[Pm]&&this.set(ht,Hd[Pm]);break;case Hm:var o=this.data,a=function(l){return o[l].getItem().detectFeature().get()};this.set(Rs,a(Rs)).set(lf,a(lf)).set(Wu,a(Wu)).set(uf,a(uf)).set(gl,a(gl))}return this},this.parseUA=function(){return this.itemType!=Hm&&Rj.call(this.data,this.ua,this.rgxMap),this.itemType==Rs&&this.set(Ax,l8(this.get(vt))),this},this.parseCH=function(){var o=this.uaCH,a=this.rgxMap;switch(this.itemType){case Rs:var l=o[e8]||o[JD],d;if(l)for(var h in l){var p=zp(/(Google|Microsoft) /,l[h].brand||l[h]),y=l[h].version;!/not.a.brand/i.test(p)&&(!d||/chrom/i.test(d)&&!/chromi/i.test(p))&&(this.set(ht,p).set(vt,y).set(Ax,l8(y)),d=p)}break;case lf:var m=o[ss];m&&(m&&o[lk]=="64"&&(m+="64"),Rj.call(this.data,m+";",a));break;case Wu:if(o[Mn]&&this.set(ft,Mn),o[xt]&&this.set(xt,o[xt]),o[xt]=="Xbox"&&this.set(ft,jm).set(At,ck),o[Lp]){var x;if(typeof o[Lp]!="string")for(var _=0;!x&&_<o[Lp].length;)x=Lx(o[Lp][_++],Dj);else x=Lx(o[Lp],Dj);this.set(ft,x)}break;case gl:var w=o[Pm];if(w){var k=o[t8];w==o8&&(k=parseInt(l8(k),10)>=13?"11":"10"),this.set(ht,w).set(vt,k)}this.get(ht)==o8&&o[xt]=="Xbox"&&this.set(ht,"Xbox").set(vt,void 0);break;case Hm:var A=this.data,E=function(R){return A[R].getItem().setCH(o).parseCH().get()};this.set(Rs,E(Rs)).set(lf,E(lf)).set(Wu,E(Wu)).set(uf,E(uf)).set(gl,E(gl))}return this},ff.call(this,[["itemType",e],["ua",t],["uaCH",r],["rgxMap",n],["data",Mce(this,e)]]),this}function df(e,t,n){if(typeof e===Um?(hk(e,!0)?(typeof t===Um&&(n=t),t=e):(n=e,t=void 0),e=void 0):typeof e===QD&&!hk(t,!0)&&(n=t,t=void 0),n&&typeof n.append===sk){var r={};n.forEach(function(h,p){r[p]=h}),n=r}if(!(this instanceof df))return new df(e,t,n).getResult();var o=typeof e===QD?e:n&&n[vj]?n[vj]:ls&&ls.userAgent?ls.userAgent:Fm,a=new Ij(n,!0),l=t?Dce(Mj,t):Mj,d=function(h){return h==Hm?function(){return new $j(h,o,l,a).set("ua",o).set(Rs,this.getBrowser()).set(lf,this.getCPU()).set(Wu,this.getDevice()).set(uf,this.getEngine()).set(gl,this.getOS()).get()}:function(){return new $j(h,o,l[h],a).parseUA().get()}};return ff.call(this,[["getBrowser",d(Rs)],["getCPU",d(lf)],["getDevice",d(Wu)],["getEngine",d(uf)],["getOS",d(gl)],["getResult",d(Hm)],["getUA",function(){return o}],["setUA",function(h){return Gm(h)&&(o=h.length>XD?Bx(h,XD):h),this}]]).setUA(o),this}df.VERSION=bce,df.BROWSER=dk([ht,vt,Ax,ft]),df.CPU=dk([ss]),df.DEVICE=dk([xt,At,ft,jm,Mn,la,di,kx,WD]),df.ENGINE=df.OS=dk([ht,vt]);const yl=class yl{constructor(t){ei(this,"config");ei(this,"storedData");ei(this,"deviceInfo");ei(this,"localStorageKey","_dsjfs312313kj3debales_analytics_");this.config=t,this.deviceInfo=this.getDeviceInfo(),this.localStorageKey=t.localStorageKey||this.localStorageKey+this.config.projectName,this.config.testing=t.testing||(()=>!1);const n=localStorage.getItem(this.localStorageKey);if(n)this.storedData=JSON.parse(n),this.config.debug&&console.log("Using Existing Stored data:",this.storedData);else{const r=crypto.randomUUID();this.storedData={projectName:this.config.projectName,anonId:r,distinctId:r},this.config.debug&&console.log("Using New Stored data:",this.storedData),this.updateStorage()}this.config.debug&&console.log("Analytics initialized:",this.storedData)}static init(t){yl.instance||(yl.instance=new yl(t))}static getInstance(){if(!yl.instance)throw new Error("DebalesAnalytics is not initialized. Call init() first.");return yl.instance}static async identify(t,n){return yl.getInstance().identifyInternal(t,n)}static track(t,n){yl.getInstance().trackInternal(t,n)}static getDistinctId(){return yl.getInstance().storedData.distinctId}static getAnonId(){return yl.getInstance().storedData.anonId}async identifyInternal(t,n){try{if(this.config.testing&&this.config.testing())return;let r,o,a;if(n){const{name:h,phone:p,...y}=n;r=h,o=p,a=y}const l={distinctId:this.storedData.distinctId,anonId:[this.storedData.anonId],projectName:this.config.projectName,email:t,name:r,phone:o,properties:a},d=await this.sendRequest("/api/analytic/identify",l);d&&d.success&&d.distinctId&&(this.config.debug&&console.log("identify success new distint id"),this.storedData.distinctId=d.distinctId,this.storedData.email=t,this.updateStorage(),d.isIdentified&&this.trackInternal("identify")),this.config.debug&&console.log("Identify event sent:",l)}catch(r){console.error("Failed to identify user:",r)}}trackInternal(t,n){if(this.config.testing&&this.config.testing())return;const r={projectName:this.config.projectName,distinctId:this.storedData.distinctId,anonId:this.storedData.anonId,eventName:t,osVersion:this.deviceInfo.osVersion,browserVersion:this.deviceInfo.browserVersion,operatingSystem:this.deviceInfo.os,browser:this.deviceInfo.browser,referrer:document.referrer,currentUrl:window.location.href,chatId:nr()+this.config.projectName,properties:n};this.sendRequest("/api/analytic/track",r),this.config.debug&&console.log("Track event sent:",r)}updateStorage(){localStorage.setItem(this.localStorageKey,JSON.stringify(this.storedData))}async sendRequest(t,n){try{const r=await fetch(`${Ti}${t}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(n)});if(!r.ok)throw new Error(`HTTP error! status: ${r.status}`);return await r.json()}catch(r){console.error("Failed to send analytics data:",r)}}getDeviceInfo(){const n=new df().getResult();return{browser:n.browser.name,os:n.os.name,browserVersion:n.browser.version,osVersion:n.os.version}}};ei(yl,"instance",null);let u8=yl;const Xu=u8,gk=e=>{window.DebalesChat||(window.DebalesChat={isOpen:!1,projectId:e,getSessionId:()=>nr(),getChatId:()=>nr()+"_"+e,getAnonId:()=>Xu.getAnonId(),isIdentified:()=>{if(ul._isIdentified())return!0;const t=jo();return!!(t&&t.email)},getIdentifiedUser:()=>jo(),getDistinctId:()=>ul.get_distinct_id(),getOldDistinctId:()=>Xu.getDistinctId(),debug:!1,identify:(t,n)=>{ul._isIdentified()||ul.identify(t,{...n,project:e}),Xu.identify(t,n),sf({email:t,name:n==null?void 0:n.name,phone:n==null?void 0:n.phone})},track:(t,n)=>{Xu.track(t,{...n,sessionId:window.DebalesChat.getSessionId()}),ul.capture(t,{...n}),Nle(t,{...n,sessionId:nr(),projectId:e})},onOpenChange:t=>{const n=r=>{t(r.detail.isOpen)};return window.addEventListener(Qr.OPEN_STATE_CHANGE,n),()=>window.removeEventListener(Qr.OPEN_STATE_CHANGE,n)},removeOpenChangeListener:t=>{const n=r=>{t(r.detail.isOpen)};window.removeEventListener(Qr.OPEN_STATE_CHANGE,n)},open:()=>{window.DebalesChat.isOpen||window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:!0,projectId:e}}))},close:()=>{window.DebalesChat.isOpen&&window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:!1,projectId:e}}))},toggle:()=>{window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:!window.DebalesChat.isOpen,projectId:e}}))}})};var xi=(e=>(e.DEFAULT="DEFAULT",e.SHOPIFY="SHOPIFY",e.WOOCOMMERCE="WOOCOMMERCE",e.MAGENTO="MAGENTO",e.UNKNOWN="UNKNOWN",e.THE_COLLECTIVE="THE_COLLECTIVE",e))(xi||{});class hf{static detect(){var t,n,r,o,a,l;if(typeof window<"u"&&window.Shopify!==void 0&&window.Shopify.routes!==void 0)return xi.SHOPIFY;if(typeof window<"u"&&window.location.hostname.endsWith(".thecollective.in"))return xi.THE_COLLECTIVE;if(typeof window<"u"&&document.body.classList.contains("woocommerce"))return xi.WOOCOMMERCE;if(typeof window<"u"){if(window.MAGENTO_VERSION!==void 0||window.MAGE!==void 0||window.Mage!==void 0||["page-wrapper","magento-theme","catalog-product-view","catalog-category-view"].some(m=>document.body.classList.contains(m)))return xi.MAGENTO;const h=document.getElementsByTagName("script");for(const m of Array.from(h))if(m.src.includes("mage/")||m.src.includes("magento")||(t=m.textContent)!=null&&t.includes("Mage.")||(n=m.textContent)!=null&&n.includes("require(")||(r=m.getAttribute("data-requiremodule"))!=null&&r.startsWith("mage")||(o=m.getAttribute("data-requiremodule"))!=null&&o.startsWith("Magento"))return xi.MAGENTO;if(document.cookie.split(";").some(m=>m.trim().startsWith("mage-")||m.trim().startsWith("form_key")))return xi.MAGENTO;const y=document.getElementsByTagName("meta");for(const m of Array.from(y))if((a=m.getAttribute("content"))!=null&&a.includes("Magento")||(l=m.getAttribute("name"))!=null&&l.includes("magento"))return xi.MAGENTO}return xi.UNKNOWN}}var Ice={MESSAGE:"MESSAGE"},$ce={USER:"USER"};function Fp(e){try{let t=e.trim();/^[a-zA-Z]+:\/\//.test(t)||(t="https://"+t);const r={protocols:["http","https"],require_tld:!0,require_protocol:!1,require_host:!0,require_valid_protocol:!0,validate_length:!0,allow_underscores:!0,allow_trailing_dot:!1,allow_protocol_relative_urls:!1};if(!zm.isURL(t,r))throw new Error("Invalid URL format");return{isValid:!0,url:new URL(t)}}catch(t){return{isValid:!1,error:t instanceof Error?t.message:"Unknown error"}}}const Me=e=>e==="the-collective"||e==="the-collective-prod"||e==="debales-testing"||e==="the-collective-test",Bj=e=>{if(!e||typeof e!="string")return!1;const t=Fp(e);if(!t.isValid)return!1;const n=t.url.pathname.toLowerCase();return[".mp4",".webm",".ogg",".avi",".mov",".wmv",".flv",".mkv",".m4v",".3gp"].some(o=>n.endsWith(o))},mk=ae.button`
480
480
  width: max-content;
481
481
  cursor: pointer;
482
482
  border-radius: 50px !important;
@@ -509,7 +509,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
509
509
 
510
510
  span {
511
511
  font-size: 14px;
512
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
512
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
513
513
  }
514
514
  `;ae.button`
515
515
  // Use CSS clamp() for responsive padding
@@ -519,9 +519,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
519
519
  align-items: center;
520
520
  gap: 4px;
521
521
  border: none;
522
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
522
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
523
523
  font-size: 14px;
524
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
524
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
525
525
  cursor: pointer;
526
526
  transition: all 0.2s ease-in-out;
527
527
 
@@ -544,14 +544,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
544
544
  gap: 4px;
545
545
  position: relative;
546
546
  padding: 4px 12px;
547
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
547
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
548
548
  border: none;
549
549
  background: linear-gradient(45deg, #54565a, #4ecdc4, #37cf95, #4eb919);
550
550
  background-size: 200% 200%;
551
551
  animation: gradient 3s ease infinite;
552
552
  color: white;
553
553
  font-size: 14px;
554
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
554
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
555
555
  letter-spacing: normal !important;
556
556
  cursor: pointer;
557
557
 
@@ -633,7 +633,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
633
633
 
634
634
  span {
635
635
  font-size: 14px;
636
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
636
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
637
637
  }
638
638
  `,Ri=ae.div`
639
639
  all: unset;
@@ -646,7 +646,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
646
646
  flex-direction: column;
647
647
  align-items: flex-start;
648
648
  gap: 4px;
649
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
649
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
650
650
  padding: 8px 13px !important;
651
651
  letter-spacing: 0.5px !important;
652
652
  position: relative;
@@ -659,7 +659,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
659
659
  margin: 0 0 0px 0;
660
660
  font-size: 16px;
661
661
  line-height: 1.2 !important;
662
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
662
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
663
663
  }
664
664
 
665
665
  h1,
@@ -672,7 +672,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
672
672
  margin-top: 16px;
673
673
  margin-bottom: 8px;
674
674
  line-height: 1.2 !important;
675
- font-weight: ${e=>Ie(e.theme.botId)?"400":"600"};
675
+ font-weight: ${e=>Me(e.theme.botId)?"400":"600"};
676
676
  }
677
677
 
678
678
  h1 {
@@ -715,7 +715,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
715
715
  a {
716
716
  color: #0366d6;
717
717
  text-decoration: none;
718
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
718
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
719
719
  &:hover {
720
720
  text-decoration: underline;
721
721
  }
@@ -725,19 +725,19 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
725
725
  font-family: "Courier New", Courier, monospace;
726
726
  background-color: #f6f8fa;
727
727
  padding: 2px 4px !important;
728
- border-radius: ${e=>Ie(e.theme.botId)?"0":"3px"} !important;
728
+ border-radius: ${e=>Me(e.theme.botId)?"0":"3px"} !important;
729
729
  font-size: 16px;
730
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
730
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
731
731
  }
732
732
 
733
733
  pre {
734
734
  background-color: #f6f8fa;
735
735
  padding: 8px !important;
736
736
  overflow-x: auto;
737
- border-radius: ${e=>Ie(e.theme.botId)?"0":"3px"} !important;
737
+ border-radius: ${e=>Me(e.theme.botId)?"0":"3px"} !important;
738
738
  font-size: 16px;
739
739
  width: 100%;
740
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
740
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
741
741
  }
742
742
 
743
743
  blockquote {
@@ -745,7 +745,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
745
745
  padding: 0 8px !important;
746
746
  color: #6a737d;
747
747
  border-left: 3px solid #dfe2e5;
748
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
748
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
749
749
  }
750
750
 
751
751
  @media screen and (max-width: 768px) {
@@ -782,7 +782,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
782
782
  align-items: flex-start;
783
783
  `,Gfe=({onCheckout:e})=>{const{cart:t,generateCartUrl:n}=Fd(),{uiData:r}=qd();return M.jsxs(qfe,{children:[M.jsx(Ri,{isBot:!0,style:{width:"max-content"},dangerouslySetInnerHTML:{__html:`<span style="display: flex; align-items: center; justify-content: center;">Total Price: ${Ok((t==null?void 0:t.total)??0,(t==null?void 0:t.currency)??"USD")} </span>`}}),M.jsxs(jfe,{href:n((r==null?void 0:r.shopifyShopDomain)??""),onClick:e,children:[M.jsx("span",{children:"Checkout"}),M.jsx(zfe,{style:{width:"20px",fill:r==null?void 0:r.callToActionFontColor}})]})]})};var Vfe={grad:.9,turn:360,rad:360/(2*Math.PI)},pf=function(e){return typeof e=="string"?e.length>0:typeof e=="number"},ko=function(e,t,n){return t===void 0&&(t=0),n===void 0&&(n=Math.pow(10,t)),Math.round(n*e)/n+0},vl=function(e,t,n){return t===void 0&&(t=0),n===void 0&&(n=1),e>n?n:e>t?e:t},uP=function(e){return(e=isFinite(e)?e%360:0)>0?e:e+360},cP=function(e){return{r:vl(e.r,0,255),g:vl(e.g,0,255),b:vl(e.b,0,255),a:vl(e.a)}},k8=function(e){return{r:ko(e.r),g:ko(e.g),b:ko(e.b),a:ko(e.a,3)}},Yfe=/^#([0-9a-f]{3,8})$/i,Dk=function(e){var t=e.toString(16);return t.length<2?"0"+t:t},fP=function(e){var t=e.r,n=e.g,r=e.b,o=e.a,a=Math.max(t,n,r),l=a-Math.min(t,n,r),d=l?a===t?(n-r)/l:a===n?2+(r-t)/l:4+(t-n)/l:0;return{h:60*(d<0?d+6:d),s:a?l/a*100:0,v:a/255*100,a:o}},dP=function(e){var t=e.h,n=e.s,r=e.v,o=e.a;t=t/360*6,n/=100,r/=100;var a=Math.floor(t),l=r*(1-n),d=r*(1-(t-a)*n),h=r*(1-(1-t+a)*n),p=a%6;return{r:255*[r,d,l,l,h,r][p],g:255*[h,r,r,d,l,l][p],b:255*[l,l,h,r,r,d][p],a:o}},hP=function(e){return{h:uP(e.h),s:vl(e.s,0,100),l:vl(e.l,0,100),a:vl(e.a)}},pP=function(e){return{h:ko(e.h),s:ko(e.s),l:ko(e.l),a:ko(e.a,3)}},gP=function(e){return dP((n=(t=e).s,{h:t.h,s:(n*=((r=t.l)<50?r:100-r)/100)>0?2*n/(r+n)*100:0,v:r+n,a:t.a}));var t,n,r},jx=function(e){return{h:(t=fP(e)).h,s:(o=(200-(n=t.s))*(r=t.v)/100)>0&&o<200?n*r/100/(o<=100?o:200-o)*100:0,l:o/2,a:t.a};var t,n,r,o},Zfe=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,Qfe=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,Kfe=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,Wfe=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,mP={string:[[function(e){var t=Yfe.exec(e);return t?(e=t[1]).length<=4?{r:parseInt(e[0]+e[0],16),g:parseInt(e[1]+e[1],16),b:parseInt(e[2]+e[2],16),a:e.length===4?ko(parseInt(e[3]+e[3],16)/255,2):1}:e.length===6||e.length===8?{r:parseInt(e.substr(0,2),16),g:parseInt(e.substr(2,2),16),b:parseInt(e.substr(4,2),16),a:e.length===8?ko(parseInt(e.substr(6,2),16)/255,2):1}:null:null},"hex"],[function(e){var t=Kfe.exec(e)||Wfe.exec(e);return t?t[2]!==t[4]||t[4]!==t[6]?null:cP({r:Number(t[1])/(t[2]?100/255:1),g:Number(t[3])/(t[4]?100/255:1),b:Number(t[5])/(t[6]?100/255:1),a:t[7]===void 0?1:Number(t[7])/(t[8]?100:1)}):null},"rgb"],[function(e){var t=Zfe.exec(e)||Qfe.exec(e);if(!t)return null;var n,r,o=hP({h:(n=t[1],r=t[2],r===void 0&&(r="deg"),Number(n)*(Vfe[r]||1)),s:Number(t[3]),l:Number(t[4]),a:t[5]===void 0?1:Number(t[5])/(t[6]?100:1)});return gP(o)},"hsl"]],object:[[function(e){var t=e.r,n=e.g,r=e.b,o=e.a,a=o===void 0?1:o;return pf(t)&&pf(n)&&pf(r)?cP({r:Number(t),g:Number(n),b:Number(r),a:Number(a)}):null},"rgb"],[function(e){var t=e.h,n=e.s,r=e.l,o=e.a,a=o===void 0?1:o;if(!pf(t)||!pf(n)||!pf(r))return null;var l=hP({h:Number(t),s:Number(n),l:Number(r),a:Number(a)});return gP(l)},"hsl"],[function(e){var t=e.h,n=e.s,r=e.v,o=e.a,a=o===void 0?1:o;if(!pf(t)||!pf(n)||!pf(r))return null;var l=function(d){return{h:uP(d.h),s:vl(d.s,0,100),v:vl(d.v,0,100),a:vl(d.a)}}({h:Number(t),s:Number(n),v:Number(r),a:Number(a)});return dP(l)},"hsv"]]},vP=function(e,t){for(var n=0;n<t.length;n++){var r=t[n][0](e);if(r)return[r,t[n][1]]}return[null,void 0]},Xfe=function(e){return typeof e=="string"?vP(e.trim(),mP.string):typeof e=="object"&&e!==null?vP(e,mP.object):[null,void 0]},T8=function(e,t){var n=jx(e);return{h:n.h,s:vl(n.s+100*t,0,100),l:n.l,a:n.a}},R8=function(e){return(299*e.r+587*e.g+114*e.b)/1e3/255},yP=function(e,t){var n=jx(e);return{h:n.h,s:n.s,l:vl(n.l+100*t,0,100),a:n.a}},xP=function(){function e(t){this.parsed=Xfe(t)[0],this.rgba=this.parsed||{r:0,g:0,b:0,a:1}}return e.prototype.isValid=function(){return this.parsed!==null},e.prototype.brightness=function(){return ko(R8(this.rgba),2)},e.prototype.isDark=function(){return R8(this.rgba)<.5},e.prototype.isLight=function(){return R8(this.rgba)>=.5},e.prototype.toHex=function(){return t=k8(this.rgba),n=t.r,r=t.g,o=t.b,l=(a=t.a)<1?Dk(ko(255*a)):"","#"+Dk(n)+Dk(r)+Dk(o)+l;var t,n,r,o,a,l},e.prototype.toRgb=function(){return k8(this.rgba)},e.prototype.toRgbString=function(){return t=k8(this.rgba),n=t.r,r=t.g,o=t.b,(a=t.a)<1?"rgba("+n+", "+r+", "+o+", "+a+")":"rgb("+n+", "+r+", "+o+")";var t,n,r,o,a},e.prototype.toHsl=function(){return pP(jx(this.rgba))},e.prototype.toHslString=function(){return t=pP(jx(this.rgba)),n=t.h,r=t.s,o=t.l,(a=t.a)<1?"hsla("+n+", "+r+"%, "+o+"%, "+a+")":"hsl("+n+", "+r+"%, "+o+"%)";var t,n,r,o,a},e.prototype.toHsv=function(){return t=fP(this.rgba),{h:ko(t.h),s:ko(t.s),v:ko(t.v),a:ko(t.a,3)};var t},e.prototype.invert=function(){return tc({r:255-(t=this.rgba).r,g:255-t.g,b:255-t.b,a:t.a});var t},e.prototype.saturate=function(t){return t===void 0&&(t=.1),tc(T8(this.rgba,t))},e.prototype.desaturate=function(t){return t===void 0&&(t=.1),tc(T8(this.rgba,-t))},e.prototype.grayscale=function(){return tc(T8(this.rgba,-1))},e.prototype.lighten=function(t){return t===void 0&&(t=.1),tc(yP(this.rgba,t))},e.prototype.darken=function(t){return t===void 0&&(t=.1),tc(yP(this.rgba,-t))},e.prototype.rotate=function(t){return t===void 0&&(t=15),this.hue(this.hue()+t)},e.prototype.alpha=function(t){return typeof t=="number"?tc({r:(n=this.rgba).r,g:n.g,b:n.b,a:t}):ko(this.rgba.a,3);var n},e.prototype.hue=function(t){var n=jx(this.rgba);return typeof t=="number"?tc({h:t,s:n.s,l:n.l,a:n.a}):ko(n.h)},e.prototype.isEqual=function(t){return this.toHex()===tc(t).toHex()},e}(),tc=function(e){return e instanceof xP?e:new xP(e)};const Jfe=ae.div`
784
784
  border: 1px solid rgba(0, 0, 0, 0.1);
785
- border-radius: 12px !important;
785
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
786
786
  padding: 8px 13px !important;
787
787
  width: fit-content;
788
788
  max-width: 100%;
@@ -800,7 +800,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
800
800
  color: ${e=>e.theme.colors.bot.font};
801
801
  line-height: 1.2;
802
802
  `,bP=ae.button`
803
- border-radius: 10px;
803
+ border-radius: ${e=>Me(e.theme.botId)?"0":"10px"};
804
804
  padding: 8px 0;
805
805
  text-align: center;
806
806
  font-weight: 500;
@@ -891,7 +891,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
891
891
  width: 100% !important;
892
892
  box-sizing: border-box;
893
893
  `,Gde=ae.span`
894
- font-weight: ${e=>Ie(e.theme.botId)?"300":"600"};
894
+ font-weight: ${e=>Me(e.theme.botId)?"300":"600"};
895
895
  overflow: hidden;
896
896
  display: -webkit-box;
897
897
  -webkit-box-orient: vertical;
@@ -1410,7 +1410,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1410
1410
  flex-direction: column;
1411
1411
  background-color: rgba(255, 255, 255, 0.8);
1412
1412
  align-items: center;
1413
- border-radius: ${e=>Ie(e.$botId)?"0":"8px"};
1413
+ border-radius: ${e=>Me(e.$botId)?"0":"8px"};
1414
1414
  cursor: ${e=>e.$disabled?"default":"pointer"};
1415
1415
  border: 1px solid rgba(0, 0, 0, 0.1);
1416
1416
  overflow: hidden;
@@ -1442,7 +1442,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1442
1442
  gap: 8px;
1443
1443
  box-sizing: border-box;
1444
1444
  `,The=ae.span`
1445
- font-weight: ${e=>Ie(e.theme.botId)?"300":"600"};
1445
+ font-weight: ${e=>Me(e.theme.botId)?"300":"600"};
1446
1446
  overflow: hidden;
1447
1447
  display: -webkit-box;
1448
1448
  -webkit-box-orient: vertical;
@@ -1459,7 +1459,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1459
1459
  font-size: 14px;
1460
1460
  }
1461
1461
  font-size: 16px;
1462
- font-weight: ${e=>Ie(e.theme.botId)?"400":"600"};
1462
+ font-weight: ${e=>Me(e.theme.botId)?"400":"600"};
1463
1463
  `,Rhe=ae.a`
1464
1464
  display: flex;
1465
1465
  padding: ${e=>e.$botId.toLowerCase().includes("gtk")?"6px 10px":"2px 10px"} !important;
@@ -1475,7 +1475,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1475
1475
  font-weight: 500;
1476
1476
  line-height: normal;
1477
1477
  transition: all 0.05s ease;
1478
- border-radius: ${e=>Ie(e.$botId)?"0":e.$botId.toLowerCase().includes("gtk")?"30px":"0px"} !important;
1478
+ border-radius: ${e=>Me(e.$botId)?"0":e.$botId.toLowerCase().includes("gtk")?"30px":"0px"} !important;
1479
1479
  background-color: ${e=>e.$botId.toLowerCase().includes("gtk")?e.$backgroundColor:"transparent"} !important;
1480
1480
 
1481
1481
  &:hover {
@@ -1492,7 +1492,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1492
1492
  justify-content: center;
1493
1493
  align-items: center;
1494
1494
  align-self: stretch;
1495
- border-radius: ${e=>Ie(e.$botId)?"0":"30px"} !important;
1495
+ border-radius: ${e=>Me(e.$botId)?"0":"30px"} !important;
1496
1496
  color: white;
1497
1497
  border: none;
1498
1498
  cursor: pointer;
@@ -1544,7 +1544,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1544
1544
  position: absolute;
1545
1545
  top: 50% !important;
1546
1546
  transform: translateY(-50%);
1547
- border-radius: ${e=>Ie(e.$botId)?"0":"50%"} !important;
1547
+ border-radius: ${e=>Me(e.$botId)?"0":"50%"} !important;
1548
1548
  border: none;
1549
1549
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
1550
1550
  z-index: 100;
@@ -1566,7 +1566,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1566
1566
  }
1567
1567
  `,Bhe=ae(LP)`
1568
1568
  left: ${e=>Po(e.$botId||"")?"0px":"5px"};
1569
- border-radius: ${e=>Ie(e.$botId||"")?"0":Po(e.$botId||"")?"0 50% 50% 0":"50%"} !important;
1569
+ border-radius: ${e=>Me(e.$botId||"")?"0":Po(e.$botId||"")?"0 50% 50% 0":"50%"} !important;
1570
1570
 
1571
1571
  @media (max-width: 768px) {
1572
1572
  left: ${e=>Po(e.$botId||"")?"0px":"10px"};
@@ -1574,19 +1574,19 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1574
1574
  }
1575
1575
  `,Lhe=ae(LP)`
1576
1576
  right: ${e=>Po(e.$botId||"")?"0px":"5px"};
1577
- border-radius: ${e=>Ie(e.$botId||"")?"0":Po(e.$botId||"")?"50% 0 0 50%":"50%"} !important;
1577
+ border-radius: ${e=>Me(e.$botId||"")?"0":Po(e.$botId||"")?"50% 0 0 50%":"50%"} !important;
1578
1578
 
1579
1579
  @media (max-width: 768px) {
1580
1580
  right: ${e=>Po(e.$botId||"")?"0px":"10px"};
1581
1581
  z-index: 110; /* Ensure it's above other elements */
1582
1582
  }
1583
- `,Uk=({message:e,botId:t,uidata:n,onSendMessage:r,loading:o,storeMetaData:a,platform:l,setShowVariantModel:d,setSelectedProduct:h,setCartVersion:p})=>{const[y,m]=Bk({align:"center",containScroll:"trimSnaps",dragFree:!0}),[x,_]=Z.useState(!1),[w,k]=Z.useState(!0),[A,E]=Z.useState(0),R=Z.useRef([]),O=Z.useRef(null),{addToCart:I,generateProductUrl:L,addCartAttributes:N,cart:H}=Fd(),V=Z.useCallback(()=>m&&m.scrollPrev(),[m]),W=Z.useCallback(()=>m&&m.scrollNext(),[m]),z=Z.useCallback(()=>{m&&(_(m.canScrollPrev()),k(m.canScrollNext()),E(m.selectedScrollSnap()))},[m]),Q=Z.useCallback(ee=>{ee.forEach(de=>{de.isIntersecting?R.current.forEach((ue,se)=>{ue&&(se===A?ue.play():ue.pause())}):R.current.forEach(ue=>{ue&&ue.pause()})})},[A]),J=Z.useCallback(ee=>{if(!ee.compare_at_price||!ee.price)return null;const de=parseFloat(ee.compare_at_price),ue=parseFloat(ee.price);if(de<=ue)return null;const se=(de-ue)/de*100;return se>0?Math.round(se):null},[]);Z.useEffect(()=>{if(m)return m.on("select",z),z(),()=>{m.off("select",z)}},[m,z]),Z.useEffect(()=>{if(!O.current)return;const ee=new IntersectionObserver(Q,{root:null,rootMargin:"0px",threshold:.6}),de=O.current;return ee.observe(de),()=>{ee.unobserve(de)}},[Q]),Z.useEffect(()=>{if(!m)return;const ee=()=>{m.reInit()};return window.addEventListener("resize",ee),()=>{window.removeEventListener("resize",ee)}},[m]);const ie=(ee,de,ue)=>{let se=ee.link;try{if(de==="GTK-Restaurant"){const pe=ee.name.toLowerCase().replace(/[^a-z0-9\s-]/g,"").replace(/\s+/g,"-");se=new URL(`/order/want-gtk-hoboken/item-${pe}_${ee.product_id}`,se.replace("www.","")).toString()}else if(de==="gtk-catering")se=new URL(`https://${ue}/catering/want-gtk-hoboken/items/add/${ee.handle}`).toString();else return L(ue,ee);return se}catch(pe){return console.error("Error formatting product URL:",pe),se}};return!e.products||e.products.length===0?null:M.jsxs(_he,{ref:O,children:[M.jsx(She,{ref:y,$botId:t,children:M.jsx(whe,{children:e.products.map((ee,de)=>{var ue;return M.jsxs(Che,{$botId:t,children:[!Ie(t)&&ee.compare_at_price&&J(ee)&&M.jsx(Dhe,{children:M.jsxs(Mhe,{children:[J(ee),"% OFF"]})}),M.jsxs(Ehe,{onClick:()=>{o||(t.toLowerCase().includes("gtk")||Ie(t)?(window.open(ie(ee,t,n.shopifyShopDomain||""),"_blank"),window.DebalesChat.track(tn.VIEW_PRODUCT_CLICKED,{productName:ee.name,productPrice:ee.price?Rk(ee.price):void 0,productLink:ee.link,message:e.conversationId})):r({message:"Tell me about "+ee.name+" product"}))},$disabled:o,$botId:t,children:[M.jsx(Ahe,{$botId:t,children:(ue=ee==null?void 0:ee.image)!=null&&ue[0]&&Bj(ee.image[0])?M.jsx("video",{ref:se=>{R.current[de]=se},style:{width:"100%",height:"auto",objectFit:"cover",aspectRatio:"1/1",margin:"0"},muted:!0,loop:!0,onClick:()=>{window.DebalesChat.track(tn.PRODUCT_VIDEO_CLICKED,{product:ee,message:e.conversationId})},src:ee.image[0]}):M.jsx("img",{style:{width:"100%",height:"auto",objectFit:"cover",aspectRatio:"1/1",margin:"0"},onClick:()=>{window.DebalesChat.track(tn.PRODUCT_IMAGE_CLICKED,{product:ee,message:e.conversationId})},src:ee.image[0]==="No image available"?"https://upload.wikimedia.org/wikipedia/commons/6/65/No-Image-Placeholder.svg":ee.image[0],alt:"Product Image Not Available"})}),M.jsxs(khe,{children:[M.jsx(The,{title:ee.name,children:ee.name}),ee.price&&M.jsxs($he,{children:[Ie(t)?M.jsx($P,{children:Ok(ee.price,n.currency||"INR",Ie(t))}):M.jsx($P,{dangerouslySetInnerHTML:{__html:lP(ee.price,a)}}),ee.compare_at_price&&J(ee)&&M.jsx(Ihe,{children:Ie(t)?M.jsxs(M.Fragment,{children:[M.jsx(BP,{children:Ok(ee.compare_at_price,n.currency||"INR",!0)}),M.jsxs("span",{style:{color:"#ef4444"},children:[J(ee),"% OFF"]})]}):M.jsx(BP,{dangerouslySetInnerHTML:{__html:lP(ee.compare_at_price,a)}})})]}),l!==xi.DEFAULT&&l!==xi.UNKNOWN&&ee.price&&M.jsx(M.Fragment,{children:M.jsx(Ohe,{$botId:t,style:{backgroundColor:n.callToActionBackgroundColor||"#F48722",color:n.callToActionFontColor||"#ffffff"},onClick:se=>{var Ce;se.stopPropagation();const pe=((Ce=ee.options)==null?void 0:Ce.every(B=>B.values.length===1))||!1;l===xi.SHOPIFY||l===xi.THE_COLLECTIVE&&!pe?(d(!0),h(ee)):(console.log("AddToCartButton: Adding to cart",ee),I(ee.variantId||"",1,{productId:ee.productId||""}),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:ee.name,price:ee.price?Rk(ee.price):void 0,link:ee.link,message:e.conversationId,currentCart:H})),p(B=>B+1)},children:Ie(t)?"Add to Bag":"Add to Cart"})}),ee.price&&M.jsxs(Rhe,{$botId:t,$backgroundColor:n.callToActionBackgroundColor||"#F48722",title:"product-link",href:ie(ee,t,n.shopifyShopDomain||""),onClick:se=>{se.stopPropagation(),t.toLowerCase().includes("gtk")&&(se.preventDefault(),r({message:"Show products similar to "+ee.name})),window.DebalesChat.track(t.toLowerCase().includes("gtk")?tn.SHOW_SIMILAR_CLICKED:tn.VIEW_PRODUCT_CLICKED,{productName:ee.name,productPrice:ee.price?Rk(ee.price):void 0,productLink:ee.link,message:e.conversationId}),N({dbls_method:"view_product"})},children:[M.jsx("span",{style:{marginRight:"6px"},children:t.toLowerCase().includes("gtk")?"Show Similar":"View Product"}),t.toLowerCase().includes("gtk")?M.jsx(Ufe,{}):M.jsx(Ffe,{})]})]})]})]},de)})})}),e.products.length>1&&M.jsxs(M.Fragment,{children:[M.jsx(Bhe,{onClick:V,disabled:!x,$botId:t,style:{backgroundColor:n.callToActionBackgroundColor||"#F48722",color:n.callToActionFontColor||"#ffffff"},children:M.jsx(aP,{uiData:n})}),M.jsx(Lhe,{onClick:W,disabled:!w,$botId:t,style:{backgroundColor:n.callToActionBackgroundColor||"#F48722",color:n.callToActionFontColor||"#ffffff"},children:M.jsx(sP,{uiData:n})})]})]})},Nhe=ae.div`
1583
+ `,Uk=({message:e,botId:t,uidata:n,onSendMessage:r,loading:o,storeMetaData:a,platform:l,setShowVariantModel:d,setSelectedProduct:h,setCartVersion:p})=>{const[y,m]=Bk({align:"center",containScroll:"trimSnaps",dragFree:!0}),[x,_]=Z.useState(!1),[w,k]=Z.useState(!0),[A,E]=Z.useState(0),R=Z.useRef([]),O=Z.useRef(null),{addToCart:I,generateProductUrl:L,addCartAttributes:N,cart:H}=Fd(),V=Z.useCallback(()=>m&&m.scrollPrev(),[m]),W=Z.useCallback(()=>m&&m.scrollNext(),[m]),z=Z.useCallback(()=>{m&&(_(m.canScrollPrev()),k(m.canScrollNext()),E(m.selectedScrollSnap()))},[m]),Q=Z.useCallback(ee=>{ee.forEach(de=>{de.isIntersecting?R.current.forEach((ue,se)=>{ue&&(se===A?ue.play():ue.pause())}):R.current.forEach(ue=>{ue&&ue.pause()})})},[A]),J=Z.useCallback(ee=>{if(!ee.compare_at_price||!ee.price)return null;const de=parseFloat(ee.compare_at_price),ue=parseFloat(ee.price);if(de<=ue)return null;const se=(de-ue)/de*100;return se>0?Math.round(se):null},[]);Z.useEffect(()=>{if(m)return m.on("select",z),z(),()=>{m.off("select",z)}},[m,z]),Z.useEffect(()=>{if(!O.current)return;const ee=new IntersectionObserver(Q,{root:null,rootMargin:"0px",threshold:.6}),de=O.current;return ee.observe(de),()=>{ee.unobserve(de)}},[Q]),Z.useEffect(()=>{if(!m)return;const ee=()=>{m.reInit()};return window.addEventListener("resize",ee),()=>{window.removeEventListener("resize",ee)}},[m]);const ie=(ee,de,ue)=>{let se=ee.link;try{if(de==="GTK-Restaurant"){const pe=ee.name.toLowerCase().replace(/[^a-z0-9\s-]/g,"").replace(/\s+/g,"-");se=new URL(`/order/want-gtk-hoboken/item-${pe}_${ee.product_id}`,se.replace("www.","")).toString()}else if(de==="gtk-catering")se=new URL(`https://${ue}/catering/want-gtk-hoboken/items/add/${ee.handle}`).toString();else return L(ue,ee);return se}catch(pe){return console.error("Error formatting product URL:",pe),se}};return!e.products||e.products.length===0?null:M.jsxs(_he,{ref:O,children:[M.jsx(She,{ref:y,$botId:t,children:M.jsx(whe,{children:e.products.map((ee,de)=>{var ue;return M.jsxs(Che,{$botId:t,children:[!Me(t)&&ee.compare_at_price&&J(ee)&&M.jsx(Dhe,{children:M.jsxs(Mhe,{children:[J(ee),"% OFF"]})}),M.jsxs(Ehe,{onClick:()=>{o||(t.toLowerCase().includes("gtk")||Me(t)?(window.open(ie(ee,t,n.shopifyShopDomain||""),"_blank"),window.DebalesChat.track(tn.VIEW_PRODUCT_CLICKED,{productName:ee.name,productPrice:ee.price?Rk(ee.price):void 0,productLink:ee.link,message:e.conversationId})):r({message:"Tell me about "+ee.name+" product"}))},$disabled:o,$botId:t,children:[M.jsx(Ahe,{$botId:t,children:(ue=ee==null?void 0:ee.image)!=null&&ue[0]&&Bj(ee.image[0])?M.jsx("video",{ref:se=>{R.current[de]=se},style:{width:"100%",height:"auto",objectFit:"cover",aspectRatio:"1/1",margin:"0"},muted:!0,loop:!0,onClick:()=>{window.DebalesChat.track(tn.PRODUCT_VIDEO_CLICKED,{product:ee,message:e.conversationId})},src:ee.image[0]}):M.jsx("img",{style:{width:"100%",height:"auto",objectFit:"cover",aspectRatio:"1/1",margin:"0"},onClick:()=>{window.DebalesChat.track(tn.PRODUCT_IMAGE_CLICKED,{product:ee,message:e.conversationId})},src:ee.image[0]==="No image available"?"https://upload.wikimedia.org/wikipedia/commons/6/65/No-Image-Placeholder.svg":ee.image[0],alt:"Product Image Not Available"})}),M.jsxs(khe,{children:[M.jsx(The,{title:ee.name,children:ee.name}),ee.price&&M.jsxs($he,{children:[Me(t)?M.jsx($P,{children:Ok(ee.price,n.currency||"INR",Me(t))}):M.jsx($P,{dangerouslySetInnerHTML:{__html:lP(ee.price,a)}}),ee.compare_at_price&&J(ee)&&M.jsx(Ihe,{children:Me(t)?M.jsxs(M.Fragment,{children:[M.jsx(BP,{children:Ok(ee.compare_at_price,n.currency||"INR",!0)}),M.jsxs("span",{style:{color:"#ef4444"},children:[J(ee),"% OFF"]})]}):M.jsx(BP,{dangerouslySetInnerHTML:{__html:lP(ee.compare_at_price,a)}})})]}),l!==xi.DEFAULT&&l!==xi.UNKNOWN&&ee.price&&M.jsx(M.Fragment,{children:M.jsx(Ohe,{$botId:t,style:{backgroundColor:n.callToActionBackgroundColor||"#F48722",color:n.callToActionFontColor||"#ffffff"},onClick:se=>{var Ce;se.stopPropagation();const pe=((Ce=ee.options)==null?void 0:Ce.every(B=>B.values.length===1))||!1;l===xi.SHOPIFY||l===xi.THE_COLLECTIVE&&!pe?(d(!0),h(ee)):(console.log("AddToCartButton: Adding to cart",ee),I(ee.variantId||"",1,{productId:ee.productId||""}),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:ee.name,price:ee.price?Rk(ee.price):void 0,link:ee.link,message:e.conversationId,currentCart:H})),p(B=>B+1)},children:Me(t)?"Add to Bag":"Add to Cart"})}),ee.price&&M.jsxs(Rhe,{$botId:t,$backgroundColor:n.callToActionBackgroundColor||"#F48722",title:"product-link",href:ie(ee,t,n.shopifyShopDomain||""),onClick:se=>{se.stopPropagation(),t.toLowerCase().includes("gtk")&&(se.preventDefault(),r({message:"Show products similar to "+ee.name})),window.DebalesChat.track(t.toLowerCase().includes("gtk")?tn.SHOW_SIMILAR_CLICKED:tn.VIEW_PRODUCT_CLICKED,{productName:ee.name,productPrice:ee.price?Rk(ee.price):void 0,productLink:ee.link,message:e.conversationId}),N({dbls_method:"view_product"})},children:[M.jsx("span",{style:{marginRight:"6px"},children:t.toLowerCase().includes("gtk")?"Show Similar":"View Product"}),t.toLowerCase().includes("gtk")?M.jsx(Ufe,{}):M.jsx(Ffe,{})]})]})]})]},de)})})}),e.products.length>1&&M.jsxs(M.Fragment,{children:[M.jsx(Bhe,{onClick:V,disabled:!x,$botId:t,style:{backgroundColor:n.callToActionBackgroundColor||"#F48722",color:n.callToActionFontColor||"#ffffff"},children:M.jsx(aP,{uiData:n})}),M.jsx(Lhe,{onClick:W,disabled:!w,$botId:t,style:{backgroundColor:n.callToActionBackgroundColor||"#F48722",color:n.callToActionFontColor||"#ffffff"},children:M.jsx(sP,{uiData:n})})]})]})},Nhe=ae.div`
1584
1584
  display: flex;
1585
1585
  flex-direction: column;
1586
1586
  gap: 4px;
1587
1587
  `,zhe=ae.label`
1588
1588
  font-size: 14px;
1589
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
1589
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
1590
1590
  color: #344054;
1591
1591
 
1592
1592
  span {
@@ -1597,7 +1597,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1597
1597
  border: 1px solid #d0d5dd;
1598
1598
  border-radius: 8px;
1599
1599
  font-size: 14px;
1600
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
1600
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
1601
1601
  width: 93%;
1602
1602
  outline: none;
1603
1603
 
@@ -1654,7 +1654,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1654
1654
  gap: 4px;
1655
1655
  padding: 8px 10px !important;
1656
1656
  border: 1px solid rgba(0, 0, 0, 0.2) !important;
1657
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"};
1657
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"};
1658
1658
  cursor: pointer;
1659
1659
  min-width: 55px;
1660
1660
  background: white;
@@ -1662,7 +1662,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1662
1662
 
1663
1663
  span {
1664
1664
  font-size: 14px;
1665
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
1665
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
1666
1666
  }
1667
1667
 
1668
1668
  span.flag {
@@ -1676,7 +1676,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1676
1676
  border-bottom: 1px solid rgba(0, 0, 0, 0.2) !important;
1677
1677
  padding: 8px 0 !important;
1678
1678
  font-size: 16px !important;
1679
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
1679
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
1680
1680
  outline: none !important;
1681
1681
  line-height: normal !important;
1682
1682
  height: 20px !important;
@@ -1814,7 +1814,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1814
1814
  flex-direction: column;
1815
1815
  gap: 4px;
1816
1816
  background-color: ${e=>e.theme.colors.bot.message||"#fff"};
1817
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"};
1817
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"};
1818
1818
  padding: 16px;
1819
1819
  margin-top: 8px;
1820
1820
  margin-bottom: 8px;
@@ -1824,7 +1824,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1824
1824
  gap: 4px;
1825
1825
  `,HP=ae.label`
1826
1826
  font-size: 14px;
1827
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
1827
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
1828
1828
  color: #344054;
1829
1829
 
1830
1830
  span {
@@ -1843,7 +1843,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1843
1843
  gap: 6.402px;
1844
1844
  border-radius: 8px !important;
1845
1845
  border: 1px solid rgba(0, 0, 0, 0.2);
1846
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
1846
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
1847
1847
  font-size: 14px;
1848
1848
  background: transparent !important;
1849
1849
  cursor: pointer;
@@ -1858,7 +1858,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1858
1858
  height: auto !important;
1859
1859
  color: rgba(0, 0, 0, 0.8);
1860
1860
  font-size: 16px;
1861
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
1861
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
1862
1862
  line-height: normal !important;
1863
1863
  word-wrap: break-word;
1864
1864
  `,ipe=ae.div`
@@ -1873,9 +1873,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1873
1873
  justify-content: center;
1874
1874
  align-items: center;
1875
1875
  gap: 6.402px;
1876
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
1876
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
1877
1877
  border: none;
1878
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
1878
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
1879
1879
  font-size: 14px;
1880
1880
  background: ${e=>e.theme.colors.cta.background} !important;
1881
1881
  box-shadow: 0px 0px 8.963px 0px rgba(0, 0, 0, 0.3);
@@ -1921,7 +1921,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1921
1921
  cursor: pointer;
1922
1922
  `,spe=ae.div`
1923
1923
  font-size: 16px;
1924
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
1924
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
1925
1925
  color: #101828;
1926
1926
  margin-bottom: 12px;
1927
1927
  `,lpe=ae.div`
@@ -1931,9 +1931,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1931
1931
  margin-bottom: 8px;
1932
1932
  padding: 8px 12px;
1933
1933
  background-color: ${e=>e.theme.colors.bot.message||"#f0f4f9"};
1934
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"};
1934
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"};
1935
1935
  width: fit-content;
1936
- `,jk=({inChat:e=!1,showFormInstructions:t=!1,setShowModel:n})=>{const[r,o]=Z.useState(null),[a,l]=Z.useState(""),[d,h]=Z.useState({name:"",email:"",phone:""}),{pendingQuestion:p,onSendMessage:y,showUserInfoModel:m,uiData:x,setUserInfo:_,setIsFormClosedByUser:w}=qd(),k=A=>{var O,I;console.log("handle submit called"),A.preventDefault();const E=Ie(window.DebalesChat.projectId||"")?{name:d.name.trim(),email:d.email.trim(),phone:d.phone.trim()||a.trim()}:{name:(O=new FormData(A.currentTarget).get("name"))==null?void 0:O.toString().trim(),email:(I=new FormData(A.currentTarget).get("email"))==null?void 0:I.toString().trim(),phone:a.trim()},R=/^[A-Za-z\s]+$/;if(x!=null&&x.pluginConfig.collectedUserInfo.name)if(E.name){if(!R.test(E.name)){o({field:"name",message:"Only letters and spaces are allowed"});return}}else{o({field:"name",message:"Name is required"});return}if(x!=null&&x.pluginConfig.collectedUserInfo.email)if(E.email){if(!zm.isEmail(E.email)){o({field:"email",message:"Invalid email address"});return}}else{o({field:"email",message:"Email is required"});return}if(x!=null&&x.pluginConfig.collectedUserInfo.phone){if(!E.phone){o({field:"phone",message:"Phone number is required"});return}if(!/^\+?\d{1,3} \d{10}$/.test(E.phone)){o({field:"phone",message:"Please enter a valid 10-digit phone number with country code"});return}}E.phone=E.phone.replace(/\s+/g,""),_(E),n(!1),console.log("closinginfo model"),window.DebalesChat.projectId==="blossom-and-rhyme-6"&&(E!=null&&E.email&&zd.identify(E.email),E!=null&&E.name&&zd.people.set({$name:E.name}),E!=null&&E.phone&&zd.people.set({$phone:E.phone})),E&&E.email&&(window.DebalesChat.identify(E.email,{name:E.name,phone:E.phone,email:E.email}),x!=null&&x.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:E.email,first_name:E.name,phone:E.phone,from:"Debales-Chatbot"})),window.DebalesChat.track(tn.USER_FORM_FILLED,{name:E==null?void 0:E.name,email:E==null?void 0:E.email,phone:E==null?void 0:E.phone}),o(null),console.log("pendingQuestion",p),setTimeout(()=>{p&&y({message:p.question,answer:p.answer,products:p.products})},0)};if(Z.useEffect(()=>{console.log("showUserInfoModel",m)},[m]),!m)return null;if(e){const A=x!=null&&x.pluginConfig?x.pluginConfig.collectedUserInfo.modelHeading:"Fill in your details to start chat!πŸš€";return M.jsxs("div",{style:{marginInline:"10px",marginBlock:"8px"},children:[!t&&M.jsx(lpe,{children:A}),M.jsxs(npe,{onSubmit:k,"data-testid":"user-info-form-container-in-chat",children:[t&&M.jsx(spe,{children:A}),(x==null?void 0:x.pluginConfig.collectedUserInfo.name)&&(Ie(window.DebalesChat.projectId||"")?M.jsx(ru,{label:"Name",name:"name",type:"text",value:d.name,onChange:E=>h(R=>({...R,name:E.target.value})),required:!0,error:r&&r.field==="name"?r.message:void 0,isCollectiveBot:!0}):M.jsx(NP,{label:"Name",name:"name",type:"text",FieldError:r,placeholder:"John Doe","data-testid":"user-info-model-name-input"})),(x==null?void 0:x.pluginConfig.collectedUserInfo.email)&&(Ie(window.DebalesChat.projectId||"")?M.jsx(ru,{label:window.DebalesChat.projectId==="catch-org-ai"?"Business Mail":"Email",name:"email",type:"email",value:d.email,onChange:E=>h(R=>({...R,email:E.target.value})),required:!0,error:r&&r.field==="email"?r.message:void 0,isCollectiveBot:!0}):M.jsx(NP,{label:window.DebalesChat.projectId==="catch-org-ai"?"Business Mail":"Email",name:"email",type:"text",placeholder:"johndoe@gmail.com",FieldError:r,"data-testid":"user-info-model-email-input"})),(x==null?void 0:x.pluginConfig.collectedUserInfo.phone)&&M.jsxs(PP,{children:[M.jsxs(HP,{children:["Phone",M.jsx("span",{children:"*"})]}),M.jsx(jP,{label:"Phone",name:"phone",FieldError:r,onChange:E=>{l(E)},countryCode:x==null?void 0:x.countryCode,"data-testid":"user-info-model-phone-input"})]}),M.jsxs(YP,{children:["By submitting, you agree to our"," ",M.jsx(ZP,{href:`${Ti}/privacy-policy`,target:"_blank",children:"Privacy Policy"})]}),M.jsxs(qP,{children:[M.jsx(VP,{type:"submit","data-testid":"user-info-model-submit-button",children:"Submit"}),(x==null?void 0:x.pluginConfig.collectedUserInfo.isOptional)===!0&&M.jsx(GP,{onClick:E=>{E.preventDefault(),w(!0),p&&y({message:p.question,answer:p.answer,products:p.products}),window.DebalesChat.track(tn.USER_FORM_CLOSE,{source:"skip_button_clicked"}),n(!1)},"data-testid":"user-info-model-skip-button",children:"Skip"})]})]})]})}return M.jsxs(M.Fragment,{children:[M.jsx(epe,{}),M.jsxs(tpe,{"data-testid":"user-info-model-container",children:[M.jsxs("div",{style:{width:"100%",height:"40px",display:"flex",justifyContent:"space-between",alignItems:"center"},children:[M.jsx(rpe,{children:x!=null&&x.pluginConfig?x==null?void 0:x.pluginConfig.collectedUserInfo.modelHeading:"Fill in your details to start chat!πŸš€"}),(x==null?void 0:x.pluginConfig.collectedUserInfo.isOptional)===!0&&M.jsx(ope,{onClick:()=>{w(!0),p&&y({message:p.question,answer:p.answer,products:p.products}),window.DebalesChat.track(tn.USER_FORM_CLOSE,{source:"close_button_clicked"}),n(!1)},"data-cy":"user-info-model-close-button",children:M.jsx(Zm,{botNameColor:x==null?void 0:x.headerFontColor})})]}),M.jsx(ipe,{children:M.jsxs(ape,{onSubmit:k,children:[(x==null?void 0:x.pluginConfig.collectedUserInfo.name)&&M.jsx(zP,{label:"Name",name:"name",type:"text",FieldError:r,placeholder:"John Doe","data-cy":"user-info-model-name-input"}),(x==null?void 0:x.pluginConfig.collectedUserInfo.email)&&(Ie(window.DebalesChat.projectId||"")?M.jsx(ru,{label:window.DebalesChat.projectId==="catch-org-ai"?"Business Mail":"Email",name:"email",type:"email",value:d.email,onChange:A=>h(E=>({...E,email:A.target.value})),required:!0,error:r&&r.field==="email"?r.message:void 0,isCollectiveBot:!0}):M.jsx(zP,{label:window.DebalesChat.projectId==="catch-org-ai"?"Business Mail":"Email",name:"email",type:"text",placeholder:"johndoe@gmail.com",FieldError:r,"data-cy":"user-info-model-email-input"})),(x==null?void 0:x.pluginConfig.collectedUserInfo.phone)&&M.jsxs(PP,{children:[M.jsxs(HP,{children:["Phone",M.jsx("span",{children:"*"})]}),M.jsx(jP,{label:"Phone",name:"phone",FieldError:r,onChange:A=>{l(A)},"data-cy":"user-info-model-phone-input",countryCode:x==null?void 0:x.countryCode})]}),M.jsxs(YP,{children:["By submitting, you agree to our"," ",M.jsx(ZP,{href:`${Ti}/privacy-policy`,target:"_blank",children:"Privacy Policy"})]}),M.jsxs(qP,{children:[M.jsx(VP,{type:"submit","data-cy":"user-info-model-submit-button",children:"Submit"}),(x==null?void 0:x.pluginConfig.collectedUserInfo.isOptional)===!0&&M.jsx(GP,{onClick:A=>{A.preventDefault(),w(!0),p&&y({message:p.question,answer:p.answer,products:p.products}),window.DebalesChat.track(tn.USER_FORM_CLOSE,{source:"skip_button_clicked"}),n(!1)},"data-cy":"user-info-model-skip-button",children:"Skip"})]})]})})]})]})},upe=ae.div`
1936
+ `,jk=({inChat:e=!1,showFormInstructions:t=!1,setShowModel:n})=>{const[r,o]=Z.useState(null),[a,l]=Z.useState(""),[d,h]=Z.useState({name:"",email:"",phone:""}),{pendingQuestion:p,onSendMessage:y,showUserInfoModel:m,uiData:x,setUserInfo:_,setIsFormClosedByUser:w}=qd(),k=A=>{var O,I;console.log("handle submit called"),A.preventDefault();const E=Me(window.DebalesChat.projectId||"")?{name:d.name.trim(),email:d.email.trim(),phone:d.phone.trim()||a.trim()}:{name:(O=new FormData(A.currentTarget).get("name"))==null?void 0:O.toString().trim(),email:(I=new FormData(A.currentTarget).get("email"))==null?void 0:I.toString().trim(),phone:a.trim()},R=/^[A-Za-z\s]+$/;if(x!=null&&x.pluginConfig.collectedUserInfo.name)if(E.name){if(!R.test(E.name)){o({field:"name",message:"Only letters and spaces are allowed"});return}}else{o({field:"name",message:"Name is required"});return}if(x!=null&&x.pluginConfig.collectedUserInfo.email)if(E.email){if(!zm.isEmail(E.email)){o({field:"email",message:"Invalid email address"});return}}else{o({field:"email",message:"Email is required"});return}if(x!=null&&x.pluginConfig.collectedUserInfo.phone){if(!E.phone){o({field:"phone",message:"Phone number is required"});return}if(!/^\+?\d{1,3} \d{10}$/.test(E.phone)){o({field:"phone",message:"Please enter a valid 10-digit phone number with country code"});return}}E.phone=E.phone.replace(/\s+/g,""),_(E),n(!1),console.log("closinginfo model"),window.DebalesChat.projectId==="blossom-and-rhyme-6"&&(E!=null&&E.email&&zd.identify(E.email),E!=null&&E.name&&zd.people.set({$name:E.name}),E!=null&&E.phone&&zd.people.set({$phone:E.phone})),E&&E.email&&(window.DebalesChat.identify(E.email,{name:E.name,phone:E.phone,email:E.email}),x!=null&&x.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:E.email,first_name:E.name,phone:E.phone,from:"Debales-Chatbot"})),window.DebalesChat.track(tn.USER_FORM_FILLED,{name:E==null?void 0:E.name,email:E==null?void 0:E.email,phone:E==null?void 0:E.phone}),o(null),console.log("pendingQuestion",p),setTimeout(()=>{p&&y({message:p.question,answer:p.answer,products:p.products})},0)};if(Z.useEffect(()=>{console.log("showUserInfoModel",m)},[m]),!m)return null;if(e){const A=x!=null&&x.pluginConfig?x.pluginConfig.collectedUserInfo.modelHeading:"Fill in your details to start chat!πŸš€";return M.jsxs("div",{style:{marginInline:"10px",marginBlock:"8px"},children:[!t&&M.jsx(lpe,{children:A}),M.jsxs(npe,{onSubmit:k,"data-testid":"user-info-form-container-in-chat",children:[t&&M.jsx(spe,{children:A}),(x==null?void 0:x.pluginConfig.collectedUserInfo.name)&&(Me(window.DebalesChat.projectId||"")?M.jsx(ru,{label:"Name",name:"name",type:"text",value:d.name,onChange:E=>h(R=>({...R,name:E.target.value})),required:!0,error:r&&r.field==="name"?r.message:void 0,isCollectiveBot:!0}):M.jsx(NP,{label:"Name",name:"name",type:"text",FieldError:r,placeholder:"John Doe","data-testid":"user-info-model-name-input"})),(x==null?void 0:x.pluginConfig.collectedUserInfo.email)&&(Me(window.DebalesChat.projectId||"")?M.jsx(ru,{label:window.DebalesChat.projectId==="catch-org-ai"?"Business Mail":"Email",name:"email",type:"email",value:d.email,onChange:E=>h(R=>({...R,email:E.target.value})),required:!0,error:r&&r.field==="email"?r.message:void 0,isCollectiveBot:!0}):M.jsx(NP,{label:window.DebalesChat.projectId==="catch-org-ai"?"Business Mail":"Email",name:"email",type:"text",placeholder:"johndoe@gmail.com",FieldError:r,"data-testid":"user-info-model-email-input"})),(x==null?void 0:x.pluginConfig.collectedUserInfo.phone)&&M.jsxs(PP,{children:[M.jsxs(HP,{children:["Phone",M.jsx("span",{children:"*"})]}),M.jsx(jP,{label:"Phone",name:"phone",FieldError:r,onChange:E=>{l(E)},countryCode:x==null?void 0:x.countryCode,"data-testid":"user-info-model-phone-input"})]}),M.jsxs(YP,{children:["By submitting, you agree to our"," ",M.jsx(ZP,{href:`${Ti}/privacy-policy`,target:"_blank",children:"Privacy Policy"})]}),M.jsxs(qP,{children:[M.jsx(VP,{type:"submit","data-testid":"user-info-model-submit-button",children:"Submit"}),(x==null?void 0:x.pluginConfig.collectedUserInfo.isOptional)===!0&&M.jsx(GP,{onClick:E=>{E.preventDefault(),w(!0),p&&y({message:p.question,answer:p.answer,products:p.products}),window.DebalesChat.track(tn.USER_FORM_CLOSE,{source:"skip_button_clicked"}),n(!1)},"data-testid":"user-info-model-skip-button",children:"Skip"})]})]})]})}return M.jsxs(M.Fragment,{children:[M.jsx(epe,{}),M.jsxs(tpe,{"data-testid":"user-info-model-container",children:[M.jsxs("div",{style:{width:"100%",height:"40px",display:"flex",justifyContent:"space-between",alignItems:"center"},children:[M.jsx(rpe,{children:x!=null&&x.pluginConfig?x==null?void 0:x.pluginConfig.collectedUserInfo.modelHeading:"Fill in your details to start chat!πŸš€"}),(x==null?void 0:x.pluginConfig.collectedUserInfo.isOptional)===!0&&M.jsx(ope,{onClick:()=>{w(!0),p&&y({message:p.question,answer:p.answer,products:p.products}),window.DebalesChat.track(tn.USER_FORM_CLOSE,{source:"close_button_clicked"}),n(!1)},"data-cy":"user-info-model-close-button",children:M.jsx(Zm,{botNameColor:x==null?void 0:x.headerFontColor})})]}),M.jsx(ipe,{children:M.jsxs(ape,{onSubmit:k,children:[(x==null?void 0:x.pluginConfig.collectedUserInfo.name)&&M.jsx(zP,{label:"Name",name:"name",type:"text",FieldError:r,placeholder:"John Doe","data-cy":"user-info-model-name-input"}),(x==null?void 0:x.pluginConfig.collectedUserInfo.email)&&(Me(window.DebalesChat.projectId||"")?M.jsx(ru,{label:window.DebalesChat.projectId==="catch-org-ai"?"Business Mail":"Email",name:"email",type:"email",value:d.email,onChange:A=>h(E=>({...E,email:A.target.value})),required:!0,error:r&&r.field==="email"?r.message:void 0,isCollectiveBot:!0}):M.jsx(zP,{label:window.DebalesChat.projectId==="catch-org-ai"?"Business Mail":"Email",name:"email",type:"text",placeholder:"johndoe@gmail.com",FieldError:r,"data-cy":"user-info-model-email-input"})),(x==null?void 0:x.pluginConfig.collectedUserInfo.phone)&&M.jsxs(PP,{children:[M.jsxs(HP,{children:["Phone",M.jsx("span",{children:"*"})]}),M.jsx(jP,{label:"Phone",name:"phone",FieldError:r,onChange:A=>{l(A)},"data-cy":"user-info-model-phone-input",countryCode:x==null?void 0:x.countryCode})]}),M.jsxs(YP,{children:["By submitting, you agree to our"," ",M.jsx(ZP,{href:`${Ti}/privacy-policy`,target:"_blank",children:"Privacy Policy"})]}),M.jsxs(qP,{children:[M.jsx(VP,{type:"submit","data-cy":"user-info-model-submit-button",children:"Submit"}),(x==null?void 0:x.pluginConfig.collectedUserInfo.isOptional)===!0&&M.jsx(GP,{onClick:A=>{A.preventDefault(),w(!0),p&&y({message:p.question,answer:p.answer,products:p.products}),window.DebalesChat.track(tn.USER_FORM_CLOSE,{source:"skip_button_clicked"}),n(!1)},"data-cy":"user-info-model-skip-button",children:"Skip"})]})]})})]})]})},upe=ae.div`
1937
1937
  position: absolute;
1938
1938
  top: 0 !important;
1939
1939
  left: 0 !important;
@@ -1955,7 +1955,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1955
1955
  flex-direction: column;
1956
1956
  align-items: flex-start;
1957
1957
  gap: 8px;
1958
- border-radius: ${e=>Ie(e.$botId)?"0":"16px"} !important;
1958
+ border-radius: ${e=>Me(e.$botId)?"0":"16px"} !important;
1959
1959
  color: #000000;
1960
1960
  background: #fff;
1961
1961
  box-shadow: 0px 128px 36px 0px rgba(0, 0, 0, 0);
@@ -1976,7 +1976,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
1976
1976
  `,ppe=ae.button`
1977
1977
  width: 100%;
1978
1978
  padding: 8px;
1979
- border-radius: ${e=>Ie(e.$botId)?"0":"4px"};
1979
+ border-radius: ${e=>Me(e.$botId)?"0":"4px"};
1980
1980
  border: 1px solid #ddd;
1981
1981
  background-color: #fff;
1982
1982
  text-align: left;
@@ -2015,7 +2015,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2015
2015
  max-height: 144px;
2016
2016
  overflow-y: auto;
2017
2017
  border: 1px solid #ddd;
2018
- border-radius: ${e=>Ie(e.$botId)?"0":"4px"};
2018
+ border-radius: ${e=>Me(e.$botId)?"0":"4px"};
2019
2019
  background-color: #fff;
2020
2020
  list-style: none;
2021
2021
  margin: 2px 0 0 0;
@@ -2045,12 +2045,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2045
2045
 
2046
2046
  &::-webkit-scrollbar-track {
2047
2047
  background: #f1f1f1;
2048
- border-radius: ${e=>Ie(e.$botId)?"0":"3px"};
2048
+ border-radius: ${e=>Me(e.$botId)?"0":"3px"};
2049
2049
  }
2050
2050
 
2051
2051
  &::-webkit-scrollbar-thumb {
2052
2052
  background: #888;
2053
- border-radius: ${e=>Ie(e.$botId)?"0":"3px"};
2053
+ border-radius: ${e=>Me(e.$botId)?"0":"3px"};
2054
2054
  }
2055
2055
 
2056
2056
  &::-webkit-scrollbar-thumb:hover {
@@ -2104,20 +2104,20 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2104
2104
  height: auto !important;
2105
2105
  color: rgba(0, 0, 0, 0.8);
2106
2106
  font-size: 16px;
2107
- font-weight: ${e=>Ie(e.theme.botId)?"400":"700"};
2107
+ font-weight: ${e=>Me(e.theme.botId)?"400":"700"};
2108
2108
  line-height: normal !important;
2109
2109
  word-wrap: break-word;
2110
- `,Pk=({uidata:e,product:t,showModel:n,setShowModel:r,onVariantSelect:o,botId:a})=>{const[l,d]=Z.useState([]),[h,p]=Z.useState([]),[y,m]=Z.useState({}),[x,_]=Z.useState(!0),[w,k]=Z.useState(null),[A,E]=Z.useState(""),R=hf.detect();Z.useEffect(()=>{const H=async()=>{try{const W=Fp(e.shopifyShopDomain||"");if(!W.isValid)throw new Error("Invalid URL");let z;if(t!=null&&t.handle)z=await fetch(new URL(`/products/${t.handle}.js`,W.url));else{const pe=t==null?void 0:t.link.replace(/^https:\/\/https:\/\//,"https://"),Ce=new URL((pe==null?void 0:pe.split("?")[0])+".js");Ce.hostname=W.url.hostname,z=await fetch(Ce)}const Q=await z.json(),J=Q.variants.filter(pe=>pe.available),ie={};Q.options.forEach(pe=>{ie[pe.name]=new Set}),J.forEach(pe=>{pe.options.forEach((Ce,B)=>{ie[Q.options[B].name].add(Ce)})});const ee=Q.options.map(pe=>({name:pe.name,values:Array.from(ie[pe.name])})).filter(pe=>pe.values.length>0);d(ee);const de=ee.every(pe=>pe.values.length===1),ue=J.map(pe=>({id:pe.id.toString(),title:Q.title,options:pe.options,available:pe.available,price:Number((pe.price/100).toFixed(2))}));p(ue);const se={};if(ee.forEach(pe=>{se[pe.name]=pe.values[0]}),m(se),de){const pe=ue.find(Ce=>ee.every((B,P)=>Ce.options[P]===B.values[0]));pe&&(o(pe),r(!1))}_(!1)}catch(W){console.error("⛓️‍πŸ’₯⛓️‍πŸ’₯Error fetching product data:",W),_(!1)}},V=async()=>{var W,z;try{if(!(t!=null&&t.options)){console.warn("No product options available for The Collective product"),_(!1);return}if(t.options.every(de=>de.values.length===1)){const de={id:((W=t.variantId)==null?void 0:W.toString())||"default",title:t.name||"",options:t.options.map(ue=>ue.values[0]),available:!0,price:((z=t.price)==null?void 0:z.toString())||"0"};o(de),r(!1),_(!1);return}const J=t.options.filter(de=>de.values.length>1);if(J.length===0){console.log("No variant options found for The Collective product"),_(!1);return}d(J);const ie=[];J.forEach((de,ue)=>{de.values.forEach((se,pe)=>{var ne,U;const Ce=((ne=de.sizeids)==null?void 0:ne[pe])||`variant-${ue}-${pe}`,B=J.map((fe,Ae)=>Ae===ue?se:fe.values[0]),P={id:Ce,title:t.name||"",options:B,available:!0,price:((U=t.price)==null?void 0:U.toString())||"0"};ie.push(P)})}),p(ie);const ee={};J.forEach(de=>{ee[de.name]=de.values[0]}),m(ee),_(!1)}catch(Q){console.error("⛓️‍πŸ’₯⛓️‍πŸ’₯Error processing The Collective product data:",Q),_(!1)}};n&&t&&R===xi.SHOPIFY?H():n&&t&&R===xi.THE_COLLECTIVE&&V()},[t,n,o,r,e.shopifyShopDomain,R]);const O=(H,V)=>{m(W=>({...W,[H]:V}))},I=()=>(console.log("Selected Options:",y),console.log("Available Variants:",h),h.find(V=>{const W=l.every((z,Q)=>V.options[Q]===y[z.name]);return console.log("Checking variant:",V,"Matches:",W),W})),L=()=>l.every(H=>y[H.name]&&y[H.name].trim()!==""),N=()=>{if(!L()){E("Please select all options to continue");return}const H=I();H?(E(""),o(H),r(!1)):E("This variant combination is not available")};return Z.useEffect(()=>{E("")},[y]),Z.useEffect(()=>{n||k(null)},[n]),!n||l.length===0||l.every(H=>H.values.length===1)||x?null:M.jsxs(M.Fragment,{children:[M.jsx(upe,{}),M.jsxs(cpe,{$botId:a,children:[M.jsx(ype,{onClick:()=>r(!1),type:"button",children:"Γ—"}),M.jsx(bpe,{children:"Please Select from Options"}),l.map(H=>M.jsxs(fpe,{children:[M.jsx(dpe,{children:H.name}),M.jsx(xpe,{options:H.values,selectedOption:y[H.name],onSelect:V=>O(H.name,V),name:H.name,activeDropdown:w,setActiveDropdown:k,botId:a})]},H.name)),A&&M.jsx(vpe,{children:A}),M.jsx("button",{onClick:N,type:"button",style:{backgroundColor:e.callToActionBackgroundColor||"#F48722",color:e.callToActionFontColor||"#fff",padding:"10px",border:"none",borderRadius:"8px",width:"100%",cursor:"pointer",minHeight:"44px",fontSize:"16px",textTransform:Ie(a)?"uppercase":"capitalize"},title:"Select Variant",children:"Continue"})]})]})},_pe=ae.form`
2110
+ `,Pk=({uidata:e,product:t,showModel:n,setShowModel:r,onVariantSelect:o,botId:a})=>{const[l,d]=Z.useState([]),[h,p]=Z.useState([]),[y,m]=Z.useState({}),[x,_]=Z.useState(!0),[w,k]=Z.useState(null),[A,E]=Z.useState(""),R=hf.detect();Z.useEffect(()=>{const H=async()=>{try{const W=Fp(e.shopifyShopDomain||"");if(!W.isValid)throw new Error("Invalid URL");let z;if(t!=null&&t.handle)z=await fetch(new URL(`/products/${t.handle}.js`,W.url));else{const pe=t==null?void 0:t.link.replace(/^https:\/\/https:\/\//,"https://"),Ce=new URL((pe==null?void 0:pe.split("?")[0])+".js");Ce.hostname=W.url.hostname,z=await fetch(Ce)}const Q=await z.json(),J=Q.variants.filter(pe=>pe.available),ie={};Q.options.forEach(pe=>{ie[pe.name]=new Set}),J.forEach(pe=>{pe.options.forEach((Ce,B)=>{ie[Q.options[B].name].add(Ce)})});const ee=Q.options.map(pe=>({name:pe.name,values:Array.from(ie[pe.name])})).filter(pe=>pe.values.length>0);d(ee);const de=ee.every(pe=>pe.values.length===1),ue=J.map(pe=>({id:pe.id.toString(),title:Q.title,options:pe.options,available:pe.available,price:Number((pe.price/100).toFixed(2))}));p(ue);const se={};if(ee.forEach(pe=>{se[pe.name]=pe.values[0]}),m(se),de){const pe=ue.find(Ce=>ee.every((B,P)=>Ce.options[P]===B.values[0]));pe&&(o(pe),r(!1))}_(!1)}catch(W){console.error("⛓️‍πŸ’₯⛓️‍πŸ’₯Error fetching product data:",W),_(!1)}},V=async()=>{var W,z;try{if(!(t!=null&&t.options)){console.warn("No product options available for The Collective product"),_(!1);return}if(t.options.every(de=>de.values.length===1)){const de={id:((W=t.variantId)==null?void 0:W.toString())||"default",title:t.name||"",options:t.options.map(ue=>ue.values[0]),available:!0,price:((z=t.price)==null?void 0:z.toString())||"0"};o(de),r(!1),_(!1);return}const J=t.options.filter(de=>de.values.length>1);if(J.length===0){console.log("No variant options found for The Collective product"),_(!1);return}d(J);const ie=[];J.forEach((de,ue)=>{de.values.forEach((se,pe)=>{var ne,U;const Ce=((ne=de.sizeids)==null?void 0:ne[pe])||`variant-${ue}-${pe}`,B=J.map((fe,Ae)=>Ae===ue?se:fe.values[0]),P={id:Ce,title:t.name||"",options:B,available:!0,price:((U=t.price)==null?void 0:U.toString())||"0"};ie.push(P)})}),p(ie);const ee={};J.forEach(de=>{ee[de.name]=de.values[0]}),m(ee),_(!1)}catch(Q){console.error("⛓️‍πŸ’₯⛓️‍πŸ’₯Error processing The Collective product data:",Q),_(!1)}};n&&t&&R===xi.SHOPIFY?H():n&&t&&R===xi.THE_COLLECTIVE&&V()},[t,n,o,r,e.shopifyShopDomain,R]);const O=(H,V)=>{m(W=>({...W,[H]:V}))},I=()=>(console.log("Selected Options:",y),console.log("Available Variants:",h),h.find(V=>{const W=l.every((z,Q)=>V.options[Q]===y[z.name]);return console.log("Checking variant:",V,"Matches:",W),W})),L=()=>l.every(H=>y[H.name]&&y[H.name].trim()!==""),N=()=>{if(!L()){E("Please select all options to continue");return}const H=I();H?(E(""),o(H),r(!1)):E("This variant combination is not available")};return Z.useEffect(()=>{E("")},[y]),Z.useEffect(()=>{n||k(null)},[n]),!n||l.length===0||l.every(H=>H.values.length===1)||x?null:M.jsxs(M.Fragment,{children:[M.jsx(upe,{}),M.jsxs(cpe,{$botId:a,children:[M.jsx(ype,{onClick:()=>r(!1),type:"button",children:"Γ—"}),M.jsx(bpe,{children:"Please Select from Options"}),l.map(H=>M.jsxs(fpe,{children:[M.jsx(dpe,{children:H.name}),M.jsx(xpe,{options:H.values,selectedOption:y[H.name],onSelect:V=>O(H.name,V),name:H.name,activeDropdown:w,setActiveDropdown:k,botId:a})]},H.name)),A&&M.jsx(vpe,{children:A}),M.jsx("button",{onClick:N,type:"button",style:{backgroundColor:e.callToActionBackgroundColor||"#F48722",color:e.callToActionFontColor||"#fff",padding:"10px",border:"none",borderRadius:Me(a)?"0":"8px",width:"100%",cursor:"pointer",minHeight:"44px",fontSize:"16px",textTransform:Me(a)?"uppercase":"capitalize"},title:"Select Variant",children:"Continue"})]})]})},_pe=ae.form`
2111
2111
  padding: 2px;
2112
2112
  margin: 8px 12px;
2113
2113
  position: relative;
2114
2114
  z-index: 3;
2115
2115
  flex: 0 0 auto;
2116
2116
  box-sizing: border-box;
2117
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
2117
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
2118
2118
  background: #fff;
2119
2119
  overflow: hidden;
2120
- box-shadow: ${e=>Ie(e.theme.botId)?"none":"0 0 15px rgba(55, 155, 251, 0.3)"};
2120
+ box-shadow: ${e=>Me(e.theme.botId)?"none":"0 0 15px rgba(55, 155, 251, 0.3)"};
2121
2121
 
2122
2122
  &::before {
2123
2123
  content: "";
@@ -2128,7 +2128,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2128
2128
  bottom: 0;
2129
2129
  border-radius: inherit;
2130
2130
  padding: 2px; /* 3px border thickness */
2131
- background: ${e=>Ie(e.theme.botId)?"#000":"conic-gradient(from 0deg, #0ead3f, #00b200, #1ca77e, #379bfb, #0ead3f)"};
2131
+ background: ${e=>Me(e.theme.botId)?"#000":"conic-gradient(from 0deg, #0ead3f, #00b200, #1ca77e, #379bfb, #0ead3f)"};
2132
2132
  mask:
2133
2133
  linear-gradient(#fff 0 0) content-box,
2134
2134
  linear-gradient(#fff 0 0);
@@ -2170,7 +2170,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2170
2170
  position: relative;
2171
2171
  z-index: 1;
2172
2172
  background-color: #fff;
2173
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
2173
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
2174
2174
  `,wpe=ae.input`
2175
2175
  all: unset;
2176
2176
  border: none;
@@ -2178,7 +2178,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2178
2178
  height: 48px !important;
2179
2179
  resize: none;
2180
2180
  font-size: 16px !important;
2181
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
2181
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
2182
2182
  line-height: 24px !important;
2183
2183
  overflow: hidden;
2184
2184
  -webkit-box-flex: 1;
@@ -2227,7 +2227,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2227
2227
  margin-top: 0 !important;
2228
2228
  margin-bottom: 0 !important;
2229
2229
  border-width: 0 !important;
2230
- border-radius: ${e=>Ie(e.theme.botId)?"0":"50%"} !important;
2230
+ border-radius: ${e=>Me(e.theme.botId)?"0":"50%"} !important;
2231
2231
  line-height: normal !important;
2232
2232
 
2233
2233
  &:hover {
@@ -2361,7 +2361,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2361
2361
  -ms-flex-negative: 0;
2362
2362
  flex-shrink: 0;
2363
2363
  object-fit: contain;
2364
- border-radius: ${e=>Ie(e.theme.botId)?"0":"50%"} !important;
2364
+ border-radius: ${e=>Me(e.theme.botId)?"0":"50%"} !important;
2365
2365
  padding: 2px !important;
2366
2366
 
2367
2367
  @media screen and (max-width: 768px) {
@@ -2415,7 +2415,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2415
2415
  z-index: 2147483647;
2416
2416
  background-color: ${e=>e.$backgroundColor};
2417
2417
  color: ${e=>e.$headerFontColor};
2418
- border-radius: ${e=>Ie(e.theme.botId)?"0":"16px"} !important;
2418
+ border-radius: ${e=>Me(e.theme.botId)?"0":"16px"} !important;
2419
2419
  padding: 0 !important;
2420
2420
  margin: 0 !important;
2421
2421
  display: flex;
@@ -2441,7 +2441,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2441
2441
  left: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$isLeft?"16px":"auto":e.$fullScreenOnMobile?"0":e.$isLeft?"16px":"auto"};
2442
2442
  right: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$isLeft?"auto":"16px":e.$fullScreenOnMobile?"0":e.$isLeft?"auto":"16px"};
2443
2443
  bottom: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$topOffset||"16px":e.$fullScreenOnMobile?"0":e.$topOffset||"16px"};
2444
- border-radius: ${e=>Ie(e.theme.botId)||e.$mobileDisplayMode==="full-screen"?"0":e.$mobileDisplayMode==="half-screen"?"16px 16px 0 0":"16px"} !important;
2444
+ border-radius: ${e=>Me(e.theme.botId)||e.$mobileDisplayMode==="full-screen"?"0":e.$mobileDisplayMode==="half-screen"?"16px 16px 0 0":"16px"} !important;
2445
2445
  overflow: hidden;
2446
2446
  touch-action: manipulation;
2447
2447
  /* Apply proper touch action for mobile modes to allow content scrolling */
@@ -2464,14 +2464,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2464
2464
  display: flex;
2465
2465
  align-items: center;
2466
2466
  padding: 2px;
2467
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
2467
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
2468
2468
  background: conic-gradient(#0ead3f, #00b200, #1ca77e, #379bfb, #0ead3f);
2469
2469
  `,Lpe=ae.div`
2470
2470
  display: flex;
2471
2471
  align-items: center;
2472
2472
  background: #fff;
2473
2473
  padding: 0 16px 0 3px; /* Adjusted padding */
2474
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
2474
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
2475
2475
  height: 40px; /* Adjusted height */
2476
2476
  font-weight: 600;
2477
2477
  font-size: 16px; /* Adjusted font-size */
@@ -2479,9 +2479,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2479
2479
  `,WP=ae.button`
2480
2480
  width: 40px;
2481
2481
  height: 40px;
2482
- border-radius: ${e=>Ie(e.theme.botId)?"0":"50%"} !important;
2482
+ border-radius: ${e=>Me(e.theme.botId)?"0":"50%"} !important;
2483
2483
  border: 1.5px solid rgba(0, 0, 0, 0.3);
2484
- background: ${e=>Ie(e.theme.botId)?e.$iconBG:"#fff"};
2484
+ background: ${e=>Me(e.theme.botId)?e.$iconBG:"#fff"};
2485
2485
  display: flex;
2486
2486
  align-items: center;
2487
2487
  justify-content: center;
@@ -2489,7 +2489,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2489
2489
  cursor: pointer;
2490
2490
  transition: background 0.2s;
2491
2491
  &:hover {
2492
- background: ${e=>!Ie(e.theme.botId)&&"#f5f5f5"};
2492
+ background: ${e=>!Me(e.theme.botId)&&"#f5f5f5"};
2493
2493
  }
2494
2494
  `,Npe=ae.div`
2495
2495
  z-index: 2147483647;
@@ -2518,12 +2518,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2518
2518
 
2519
2519
  &::-webkit-scrollbar-track {
2520
2520
  background: #f8f5f5;
2521
- border-radius: ${e=>Ie(e.theme.botId)?"0":"5px"} !important;
2521
+ border-radius: ${e=>Me(e.theme.botId)?"0":"5px"} !important;
2522
2522
  }
2523
2523
 
2524
2524
  &::-webkit-scrollbar-thumb {
2525
2525
  background: #7a7979;
2526
- border-radius: ${e=>Ie(e.theme.botId)?"0":"5px"} !important;
2526
+ border-radius: ${e=>Me(e.theme.botId)?"0":"5px"} !important;
2527
2527
  }
2528
2528
 
2529
2529
  /* Improved scrolling behavior for all mobile modes */
@@ -2658,12 +2658,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2658
2658
  justify-content: center;
2659
2659
  text-align: left;
2660
2660
  align-self: stretch;
2661
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
2661
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
2662
2662
  color: white;
2663
2663
  border: none;
2664
2664
  cursor: ${e=>e.$disabled?"default":"pointer"};
2665
2665
  font-size: 14px;
2666
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
2666
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
2667
2667
  line-height: 20px !important;
2668
2668
  transition: all 0.05s ease;
2669
2669
  height: auto !important;
@@ -2853,7 +2853,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2853
2853
  margin: 4px 10px 4px;
2854
2854
  padding: 16px 16px;
2855
2855
  background-color: ${e=>e.theme.colors.bot.message||"#fff"};
2856
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
2856
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
2857
2857
  width: 100%;
2858
2858
  max-width: 320px;
2859
2859
  `,z8=ae.div`
@@ -2867,7 +2867,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2867
2867
  margin-bottom: 8px;
2868
2868
  font-size: 16px;
2869
2869
  color: #1c1c1c;
2870
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
2870
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
2871
2871
 
2872
2872
  span {
2873
2873
  color: #ff3b30;
@@ -2876,30 +2876,30 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2876
2876
  width: calc(100% - 26px);
2877
2877
  padding: 12px;
2878
2878
  border: 1px solid #d0d5dd;
2879
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
2879
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
2880
2880
  font-size: 16px;
2881
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
2882
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
2881
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
2882
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
2883
2883
 
2884
2884
  &:focus {
2885
2885
  outline: none;
2886
2886
  border-color: #f48722;
2887
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
2887
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
2888
2888
  }
2889
2889
  `,Kpe=ae.textarea`
2890
2890
  width: calc(100% - 26px);
2891
2891
  padding: 12px;
2892
2892
  border: 1px solid #d0d5dd;
2893
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
2893
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
2894
2894
  font-size: 16px;
2895
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
2896
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
2895
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
2896
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
2897
2897
  resize: none;
2898
2898
 
2899
2899
  &:focus {
2900
2900
  outline: none;
2901
2901
  border-color: #f48722;
2902
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
2902
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
2903
2903
  }
2904
2904
  `,Wpe=ae.button`
2905
2905
  height: 40px !important;
@@ -2908,9 +2908,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2908
2908
  background-color: ${e=>e.theme.colors.cta.background};
2909
2909
  color: ${e=>e.theme.colors.cta.font};
2910
2910
  border: none;
2911
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
2911
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
2912
2912
  font-size: 14px;
2913
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
2913
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
2914
2914
  cursor: pointer;
2915
2915
  transition: all 0.3s ease;
2916
2916
  justify-content: center;
@@ -2970,11 +2970,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2970
2970
  opacity: 0;
2971
2971
  z-index: 1;
2972
2972
  bottom: 0;
2973
- `,oH=({botId:e})=>{var Kr,ot;const{uiData:t,storeMetaData:n,onSendMessage:r,isKlaviyoMessage:o,isLoading:a,lastedBotmessageId:l,setLastedBotmessageId:d,messages:h,isMessageLoading:p,setIsMessageLoading:y,setMessages:m,saveConversation:x,loadConversation:_,suggestedQuestions:w,setSuggestedQuestions:k,showUserInfoModel:A,setShowUserInfoModel:E,isUserInfoNeeded:R,setPendingQuestion:O}=qd(),{cart:I,addToCart:L,generateCartUrl:N,addCartAttributes:H}=Fd(),V=Qc("use-chatbot-icon-size"),W=hf.detect(),z=t==null?void 0:t.isLeft,Q=xk(),J=t==null?void 0:t.heightOption,[ie,ee]=Z.useState(!1),[de,ue]=Z.useState(!1),[se,pe]=Z.useState(""),[Ce,B]=Z.useState(""),[,P]=Z.useState(0);Z.useEffect(()=>{e&&gk(e)},[e]),Z.useEffect(()=>{mE(e)},[e]),Z.useEffect(()=>{let Oe=jo();if(!Oe&&window.Thinkific){const at=window.Thinkific.current_user;at&&(Oe={name:at.full_name,email:at.email},sf(Oe))}Xu.init({projectName:e,debug:!1,testing:Cx}),Oe&&Oe.email&&(window.DebalesChat.identify(Oe.email,{name:Oe.name,phone:Oe.phone,email:Oe.email}),t!=null&&t.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:Oe.email,first_name:Oe.name,phone:Oe.phone,from:"Debales-Chatbot"}))},[e,t==null?void 0:t.KlaviyoIntegration]);const ne=Z.useRef(null),U=Qn(On.CLICKED_QUESTIONS,{botId:e}),[fe,Ae]=Z.useState(()=>{try{const Oe=sessionStorage.getItem(U);return Oe?new Set(JSON.parse(Oe)):new Set}catch{return new Set}});Z.useEffect(()=>{try{sessionStorage.setItem(U,JSON.stringify(Array.from(fe)))}catch(Oe){console.error("Failed to save to sessionStorage:",Oe)}},[fe]);const Te=Z.useCallback((Oe,at)=>{Oe?(window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:Oe,source:at,projectId:e}})),setTimeout(()=>{ue(!0)},50)):(ue(!1),window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:Oe,source:at,projectId:e}})))},[]);Z.useEffect(()=>{const Oe=at=>{ee(at.detail.isOpen),at.detail.isOpen&&setTimeout(()=>ue(!0),50),window.DebalesChat.isOpen=at.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:at.detail.isOpen,source:at.detail.source})};return window.addEventListener(Qr.OPEN_STATE_CHANGE,Oe),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,Oe)}},[]),Z.useEffect(()=>{const Oe=at=>{ee(at.detail.isOpen),window.DebalesChat.isOpen=at.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:at.detail.isOpen})};return window.addEventListener(Qr.OPEN_STATE_CHANGE,Oe),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,Oe)}},[]);const[rt,Ge]=Z.useState(!1),[We,Tt]=Z.useState(()=>{const Oe=Qn(On.PENDING_BULK_ITEMS,{botId:e}),at=sessionStorage.getItem(Oe);return at?JSON.parse(at):[]});Z.useEffect(()=>{const Oe=Qn(On.PENDING_BULK_ITEMS,{botId:e});sessionStorage.setItem(Oe,JSON.stringify(We))},[We,e]);const[It,nt]=Z.useState(!1),[dt,bt]=Z.useState({name:"",email:"",message:""}),[Et,Nt]=Z.useState([]),[yt,re]=Z.useState({name:"",email:"",message:""}),[le,ve]=Z.useState(null),[Ee,$e]=Z.useState(!1),Ve=Ql("exit_model"),[lt,mt]=Z.useState({text:!0,leadingQueries:!0,collections:!0,products:!0,variants:!0,cartSummary:!0,bulkItems:!0}),[_e,Re]=Z.useState({suggestions:!1,products:!1,collections:!1,leadingQueries:!1,initialMessage:!1,cartSummary:!1,bulkItems:!1}),[Ct,ct]=Z.useState(!1),[Rt,Mt]=Z.useState(!0),[en,Qt]=Z.useState(!1),[gn,pt]=Z.useState(!1),[Kt,_t]=Z.useState(!1),[Y,xe]=Z.useState(!1),it=2e3,st=Z.useCallback(()=>{const Oe=ne.current;if(!Oe){_t(!1),xe(!1),Mt(!0);return}if(Ie(e)){_t(!1);return}const at=Oe.scrollTop,ce=Oe.scrollHeight,Me=Oe.clientHeight,j=ce>Me,te=1,he=at<=te,ke=at+Me>=ce-te;j?(_t(!he),xe(!ke),Mt(ke)):(_t(!1),xe(!1),Mt(!0))},[ne,_t,xe,Mt]);Z.useEffect(()=>{const Oe=ne.current;if(ie&&Oe){st(),Oe.addEventListener("scroll",st);const at=new ResizeObserver(st);return at.observe(Oe),()=>{Oe.removeEventListener("scroll",st),at.unobserve(Oe)}}else ie||(_t(!1),xe(!1),Mt(!0))},[ie,h,Ct,st]);const[St,Pt]=Vm(On.SHOW_CART_SUMMARY,!0);Z.useEffect(()=>{var Oe,at,ce,Me,j,te;if(h.length>0&&!p){const he=h[h.length-1],ke=sessionStorage.getItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e})),we=he.isBot&&he.conversationId===l&&he.conversationId!==ke,Je=(I==null?void 0:I.itemCount)&&(I==null?void 0:I.itemCount)>0&&he.conversationId===l;if(we){ct(!0),Re(Un=>({...Un,initialMessage:!0})),sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),he.conversationId||""),mt({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1});const $t=2e3;let an=$t;const un=[{type:"collections",condition:((Oe=he.collections)==null?void 0:Oe.length)&&((at=he.collections)==null?void 0:at.length)>0},{type:"products",condition:((ce=he.products)==null?void 0:ce.length)&&((Me=he.products)==null?void 0:Me.length)>0},{type:"leadingQueries",condition:h.length>=1&&((j=he.leading_queries)==null?void 0:j.length)&&((te=he.leading_queries)==null?void 0:te.length)>0},{type:"cartSummary",condition:(I==null?void 0:I.itemCount)&&(I==null?void 0:I.itemCount)>0},{type:"bulkItems",condition:(We==null?void 0:We.length)>0}].filter(Un=>Un.condition);if(un.length===0){ct(!1),Re(Un=>({...Un,initialMessage:!1,leadingQueries:!1}));return}un.forEach(({type:Un},dn)=>{setTimeout(()=>{if(Re(gr=>({...gr,[Un]:!0})),mt(gr=>({...gr,[Un]:!0})),Rt&&ne.current){const gr=ne.current;gr.scrollHeight-gr.scrollTop<=gr.clientHeight&&La(ne)}dn===un.length-1&&ct(!1)},an),an+=$t})}else Je&&mt($t=>({...$t,cartSummary:!0}))}},[h,p,l,I==null?void 0:I.itemCount,We==null?void 0:We.length,Rt,e]),Z.useEffect(()=>{if(!o&&h.length>0){const Oe=ne.current;Oe&&Rt&&Oe.scrollHeight-Oe.scrollTop<=Oe.clientHeight+100&&setTimeout(()=>La(ne),100)}},[h.length,o,Rt]),Z.useEffect(()=>{const Oe=document.querySelector('meta[name="viewport"]'),at=Oe==null?void 0:Oe.content;if(ie){let ce=Oe;const Me=window.matchMedia("(max-width: 768px)").matches;ce?ce.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no":(ce=document.createElement("meta"),ce.name="viewport",ce.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no",document.head.appendChild(ce)),Me&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="hidden");const j=ce;return()=>{at&&j&&(j.content=at),Me&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}}return()=>{window.matchMedia("(max-width: 768px)").matches&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}},[ie,t==null?void 0:t.mobileDisplayMode]),Z.useEffect(()=>{const Oe=setTimeout(()=>{Ge(!0)},1e3);return()=>clearTimeout(Oe)},[]),Z.useEffect(()=>{if(ie&&h.length>0&&!o){const Oe=ne.current;Oe&&setTimeout(()=>{Oe.scrollTop=Oe.scrollHeight},100)}},[ie,h.length,o]),Z.useEffect(()=>{I!=null&&I.itemCount&&I.itemCount===0&&!o&&setTimeout(()=>La(ne),100)},[I==null?void 0:I.itemCount,o]),Z.useEffect(()=>{l&&sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),l)},[l,e]);const Ht=Z.useRef(window.location.pathname.split("?")[0]),Yt=Z.useRef(w),qt=Ql("acquisition_agent");Z.useEffect(()=>{Yt.current=w},[w]);const ln=Z.useCallback(async Oe=>{console.log("Calling acquisition API for path:",Oe);try{const at=await fetch(`${Ti}/api/wordpress/acquisition`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,timestamp:new Date().toISOString(),page_information:window.location.href.split("?")[0],botid:e})});if(at.ok){const ce=await at.json();if(ce.Popup_Message){const Me=[...Yt.current];Me.push({question:ce.Popup_Message,answer:"",path:Oe,nameSpace:e,type:"dynamic",Follow_up_Question:ce.Follow_up_Question}),k(Me)}}}catch(at){console.error("Error fetching acquisition data:",at)}},[e,k]),hr=Z.useCallback(()=>{const Oe=window.location.pathname.split("?")[0],at=Ht.current;console.log("URL change detected:",{currentPath:at,newPath:Oe}),Oe!==at&&(console.log("Path changed, calling acquisition API"),Ht.current=Oe,ln(Oe))},[ln]);Z.useEffect(()=>{if(!qt||(t==null?void 0:t.show_bot)===!1)return;console.log("Setting up acquisition agent");const Oe=window.location.pathname.split("?")[0];ln(Oe);const at=()=>{hr()},ce=history.pushState,Me=history.replaceState;return history.pushState=function(...j){ce.apply(this,j),setTimeout(hr,0)},history.replaceState=function(...j){Me.apply(this,j),setTimeout(hr,0)},window.addEventListener("popstate",at),()=>{window.removeEventListener("popstate",at),history.pushState=ce,history.replaceState=Me}},[qt,t==null?void 0:t.show_bot,ln,hr]);const[xr,Ur]=Z.useState(!1),[nn,yn]=Z.useState(!1),[fn,ho]=Z.useState(null),br=async Oe=>{const at=nr();if(ue(!1),Oe&&h.length>1)try{(await fetch(`${Ti}/api/wordpress/userRating`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sessionId:at,userRating:Oe,nameSpace:e})})).ok||console.error("Error submitting rating")}catch(ce){console.error("Error submitting rating:",ce)}setTimeout(()=>{yn(!1),Te(!1,"close_button_clicked")},1e3)},us=Oe=>{y(!0),We.forEach(ce=>{console.debug("handleBulkItemsAddition : Adding item to cart:",ce),L(ce.id,ce.quantity)}),Pt(!0),window.DebalesChat.track(tn.ADD_BULK_ITEM,{products:We,message:Oe});const at=[...h,{text:"πŸŽ‰ Bulk items added to cart successfully.",leading_queries:["Get GST Invoice for the order","Explore more products"],conversationId:Oe,isBot:!0}];m(at),x(at),d(Oe),Tt([]),y(!1)},ji=()=>{var Oe;switch(e){case"minature":case"bodytales":case"imemyselfcare-com":if(window.triggerGokwikCustomCheckout)return window.triggerGokwikCustomCheckout(),!0;break;case"athflex":if((Oe=window.shiprocketCheckoutEvents)!=null&&Oe.buyCart)return window.shiprocketCheckoutEvents.buyCart(),!0;break;case"www":if(window.openRzpCheckout)return window.openRzpCheckout(),!0;break;default:return window.location.href=N((t==null?void 0:t.shopifyShopDomain)??""),!1}return window.location.href=N((t==null?void 0:t.shopifyShopDomain)??""),!1},Ho=async Oe=>{Oe.preventDefault(),window.DebalesChat.track(tn.CHECKOUT_CLICKED,{chatId:nr()+e,cartValue:Number(I==null?void 0:I.total),cart:I}),H({dbls_method:"checkout_clicked"}),ji()&&Te(!1,"checkout_clicked")},[Dt,to]=Z.useState([]);Z.useEffect(()=>{const Oe=Fle(gE(w));to(Oe)},[w]);const rr=Z.useMemo(()=>Dt.map(Oe=>{if(Array.isArray(Oe)){const at=Oe.filter(Me=>!fe.has(Me.question));if(at.length===0)return null;const ce={isHighlighted:Oe[0].isHighlighted,enable:Oe[0].enable,type:Oe[0].type};return at.map(Me=>({...Me,...ce}))}else return fe.has(Oe.question)?null:Oe}).filter(Boolean),[Dt,fe]);Z.useEffect(()=>{const Oe=Me=>{const j=Me.detail.formId;switch(Me.detail.type){case"open":case"embedOpen":setTimeout(()=>{const he=at(j);he&&pe(he)},800);break;case"close":se&&(t==null?void 0:t.KlaviyoFormIntegration)===!0&&setTimeout(()=>{Te(!0,"klaviyo_form_closed"),B(j),r({message:se,fromKlaviyo:!0})},1e4);break}},at=Me=>{const j=document.querySelector(`[data-testid="klaviyo-form-${Me}"]`);if(console.log(`formElement text ${Me} =>`,j==null?void 0:j.innerText,j==null?void 0:j.textContent),j instanceof HTMLElement){const te=j.innerText||j.textContent;if(te)return console.log("Found form text:",te),`=> Klaviyo form content:
2973
+ `,oH=({botId:e})=>{var Kr,ot;const{uiData:t,storeMetaData:n,onSendMessage:r,isKlaviyoMessage:o,isLoading:a,lastedBotmessageId:l,setLastedBotmessageId:d,messages:h,isMessageLoading:p,setIsMessageLoading:y,setMessages:m,saveConversation:x,loadConversation:_,suggestedQuestions:w,setSuggestedQuestions:k,showUserInfoModel:A,setShowUserInfoModel:E,isUserInfoNeeded:R,setPendingQuestion:O}=qd(),{cart:I,addToCart:L,generateCartUrl:N,addCartAttributes:H}=Fd(),V=Qc("use-chatbot-icon-size"),W=hf.detect(),z=t==null?void 0:t.isLeft,Q=xk(),J=t==null?void 0:t.heightOption,[ie,ee]=Z.useState(!1),[de,ue]=Z.useState(!1),[se,pe]=Z.useState(""),[Ce,B]=Z.useState(""),[,P]=Z.useState(0);Z.useEffect(()=>{e&&gk(e)},[e]),Z.useEffect(()=>{mE(e)},[e]),Z.useEffect(()=>{let Oe=jo();if(!Oe&&window.Thinkific){const at=window.Thinkific.current_user;at&&(Oe={name:at.full_name,email:at.email},sf(Oe))}Xu.init({projectName:e,debug:!1,testing:Cx}),Oe&&Oe.email&&(window.DebalesChat.identify(Oe.email,{name:Oe.name,phone:Oe.phone,email:Oe.email}),t!=null&&t.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:Oe.email,first_name:Oe.name,phone:Oe.phone,from:"Debales-Chatbot"}))},[e,t==null?void 0:t.KlaviyoIntegration]);const ne=Z.useRef(null),U=Qn(On.CLICKED_QUESTIONS,{botId:e}),[fe,Ae]=Z.useState(()=>{try{const Oe=sessionStorage.getItem(U);return Oe?new Set(JSON.parse(Oe)):new Set}catch{return new Set}});Z.useEffect(()=>{try{sessionStorage.setItem(U,JSON.stringify(Array.from(fe)))}catch(Oe){console.error("Failed to save to sessionStorage:",Oe)}},[fe]);const Te=Z.useCallback((Oe,at)=>{Oe?(window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:Oe,source:at,projectId:e}})),setTimeout(()=>{ue(!0)},50)):(ue(!1),window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:Oe,source:at,projectId:e}})))},[]);Z.useEffect(()=>{const Oe=at=>{ee(at.detail.isOpen),at.detail.isOpen&&setTimeout(()=>ue(!0),50),window.DebalesChat.isOpen=at.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:at.detail.isOpen,source:at.detail.source})};return window.addEventListener(Qr.OPEN_STATE_CHANGE,Oe),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,Oe)}},[]),Z.useEffect(()=>{const Oe=at=>{ee(at.detail.isOpen),window.DebalesChat.isOpen=at.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:at.detail.isOpen})};return window.addEventListener(Qr.OPEN_STATE_CHANGE,Oe),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,Oe)}},[]);const[rt,Ge]=Z.useState(!1),[We,Tt]=Z.useState(()=>{const Oe=Qn(On.PENDING_BULK_ITEMS,{botId:e}),at=sessionStorage.getItem(Oe);return at?JSON.parse(at):[]});Z.useEffect(()=>{const Oe=Qn(On.PENDING_BULK_ITEMS,{botId:e});sessionStorage.setItem(Oe,JSON.stringify(We))},[We,e]);const[It,nt]=Z.useState(!1),[dt,bt]=Z.useState({name:"",email:"",message:""}),[Et,Nt]=Z.useState([]),[yt,re]=Z.useState({name:"",email:"",message:""}),[le,ve]=Z.useState(null),[Ee,$e]=Z.useState(!1),Ve=Ql("exit_model"),[lt,mt]=Z.useState({text:!0,leadingQueries:!0,collections:!0,products:!0,variants:!0,cartSummary:!0,bulkItems:!0}),[_e,Re]=Z.useState({suggestions:!1,products:!1,collections:!1,leadingQueries:!1,initialMessage:!1,cartSummary:!1,bulkItems:!1}),[Ct,ct]=Z.useState(!1),[Rt,Mt]=Z.useState(!0),[en,Qt]=Z.useState(!1),[gn,pt]=Z.useState(!1),[Kt,_t]=Z.useState(!1),[Y,xe]=Z.useState(!1),it=2e3,st=Z.useCallback(()=>{const Oe=ne.current;if(!Oe){_t(!1),xe(!1),Mt(!0);return}if(Me(e)){_t(!1);return}const at=Oe.scrollTop,ce=Oe.scrollHeight,Ie=Oe.clientHeight,j=ce>Ie,te=1,he=at<=te,ke=at+Ie>=ce-te;j?(_t(!he),xe(!ke),Mt(ke)):(_t(!1),xe(!1),Mt(!0))},[ne,_t,xe,Mt]);Z.useEffect(()=>{const Oe=ne.current;if(ie&&Oe){st(),Oe.addEventListener("scroll",st);const at=new ResizeObserver(st);return at.observe(Oe),()=>{Oe.removeEventListener("scroll",st),at.unobserve(Oe)}}else ie||(_t(!1),xe(!1),Mt(!0))},[ie,h,Ct,st]);const[St,Pt]=Vm(On.SHOW_CART_SUMMARY,!0);Z.useEffect(()=>{var Oe,at,ce,Ie,j,te;if(h.length>0&&!p){const he=h[h.length-1],ke=sessionStorage.getItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e})),we=he.isBot&&he.conversationId===l&&he.conversationId!==ke,Je=(I==null?void 0:I.itemCount)&&(I==null?void 0:I.itemCount)>0&&he.conversationId===l;if(we){ct(!0),Re(Un=>({...Un,initialMessage:!0})),sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),he.conversationId||""),mt({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1});const $t=2e3;let an=$t;const un=[{type:"collections",condition:((Oe=he.collections)==null?void 0:Oe.length)&&((at=he.collections)==null?void 0:at.length)>0},{type:"products",condition:((ce=he.products)==null?void 0:ce.length)&&((Ie=he.products)==null?void 0:Ie.length)>0},{type:"leadingQueries",condition:h.length>=1&&((j=he.leading_queries)==null?void 0:j.length)&&((te=he.leading_queries)==null?void 0:te.length)>0},{type:"cartSummary",condition:(I==null?void 0:I.itemCount)&&(I==null?void 0:I.itemCount)>0},{type:"bulkItems",condition:(We==null?void 0:We.length)>0}].filter(Un=>Un.condition);if(un.length===0){ct(!1),Re(Un=>({...Un,initialMessage:!1,leadingQueries:!1}));return}un.forEach(({type:Un},dn)=>{setTimeout(()=>{if(Re(gr=>({...gr,[Un]:!0})),mt(gr=>({...gr,[Un]:!0})),Rt&&ne.current){const gr=ne.current;gr.scrollHeight-gr.scrollTop<=gr.clientHeight&&La(ne)}dn===un.length-1&&ct(!1)},an),an+=$t})}else Je&&mt($t=>({...$t,cartSummary:!0}))}},[h,p,l,I==null?void 0:I.itemCount,We==null?void 0:We.length,Rt,e]),Z.useEffect(()=>{if(!o&&h.length>0){const Oe=ne.current;Oe&&Rt&&Oe.scrollHeight-Oe.scrollTop<=Oe.clientHeight+100&&setTimeout(()=>La(ne),100)}},[h.length,o,Rt]),Z.useEffect(()=>{const Oe=document.querySelector('meta[name="viewport"]'),at=Oe==null?void 0:Oe.content;if(ie){let ce=Oe;const Ie=window.matchMedia("(max-width: 768px)").matches;ce?ce.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no":(ce=document.createElement("meta"),ce.name="viewport",ce.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no",document.head.appendChild(ce)),Ie&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="hidden");const j=ce;return()=>{at&&j&&(j.content=at),Ie&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}}return()=>{window.matchMedia("(max-width: 768px)").matches&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}},[ie,t==null?void 0:t.mobileDisplayMode]),Z.useEffect(()=>{const Oe=setTimeout(()=>{Ge(!0)},1e3);return()=>clearTimeout(Oe)},[]),Z.useEffect(()=>{if(ie&&h.length>0&&!o){const Oe=ne.current;Oe&&setTimeout(()=>{Oe.scrollTop=Oe.scrollHeight},100)}},[ie,h.length,o]),Z.useEffect(()=>{I!=null&&I.total&&!o&&setTimeout(()=>La(ne),100)},[I==null?void 0:I.total,o]),Z.useEffect(()=>{l&&sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),l)},[l,e]);const Ht=Z.useRef(window.location.pathname.split("?")[0]),Yt=Z.useRef(w),qt=Ql("acquisition_agent");Z.useEffect(()=>{Yt.current=w},[w]);const ln=Z.useCallback(async Oe=>{console.log("Calling acquisition API for path:",Oe);try{const at=await fetch(`${Ti}/api/wordpress/acquisition`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,timestamp:new Date().toISOString(),page_information:window.location.href.split("?")[0],botid:e})});if(at.ok){const ce=await at.json();if(ce.Popup_Message){const Ie=[...Yt.current];Ie.push({question:ce.Popup_Message,answer:"",path:Oe,nameSpace:e,type:"dynamic",Follow_up_Question:ce.Follow_up_Question}),k(Ie)}}}catch(at){console.error("Error fetching acquisition data:",at)}},[e,k]),hr=Z.useCallback(()=>{const Oe=window.location.pathname.split("?")[0],at=Ht.current;console.log("URL change detected:",{currentPath:at,newPath:Oe}),Oe!==at&&(console.log("Path changed, calling acquisition API"),Ht.current=Oe,ln(Oe))},[ln]);Z.useEffect(()=>{if(!qt||(t==null?void 0:t.show_bot)===!1)return;console.log("Setting up acquisition agent");const Oe=window.location.pathname.split("?")[0];ln(Oe);const at=()=>{hr()},ce=history.pushState,Ie=history.replaceState;return history.pushState=function(...j){ce.apply(this,j),setTimeout(hr,0)},history.replaceState=function(...j){Ie.apply(this,j),setTimeout(hr,0)},window.addEventListener("popstate",at),()=>{window.removeEventListener("popstate",at),history.pushState=ce,history.replaceState=Ie}},[qt,t==null?void 0:t.show_bot,ln,hr]);const[xr,Ur]=Z.useState(!1),[nn,yn]=Z.useState(!1),[fn,ho]=Z.useState(null),br=async Oe=>{const at=nr();if(ue(!1),Oe&&h.length>1)try{(await fetch(`${Ti}/api/wordpress/userRating`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sessionId:at,userRating:Oe,nameSpace:e})})).ok||console.error("Error submitting rating")}catch(ce){console.error("Error submitting rating:",ce)}setTimeout(()=>{yn(!1),Te(!1,"close_button_clicked")},1e3)},us=Oe=>{y(!0),We.forEach(ce=>{console.debug("handleBulkItemsAddition : Adding item to cart:",ce),L(ce.id,ce.quantity)}),Pt(!0),window.DebalesChat.track(tn.ADD_BULK_ITEM,{products:We,message:Oe});const at=[...h,{text:"πŸŽ‰ Bulk items added to cart successfully.",leading_queries:["Get GST Invoice for the order","Explore more products"],conversationId:Oe,isBot:!0}];m(at),x(at),d(Oe),Tt([]),y(!1)},ji=()=>{var Oe;switch(e){case"minature":case"bodytales":case"imemyselfcare-com":if(window.triggerGokwikCustomCheckout)return window.triggerGokwikCustomCheckout(),!0;break;case"athflex":if((Oe=window.shiprocketCheckoutEvents)!=null&&Oe.buyCart)return window.shiprocketCheckoutEvents.buyCart(),!0;break;case"www":if(window.openRzpCheckout)return window.openRzpCheckout(),!0;break;default:return window.location.href=N((t==null?void 0:t.shopifyShopDomain)??""),!1}return window.location.href=N((t==null?void 0:t.shopifyShopDomain)??""),!1},Ho=async Oe=>{Oe.preventDefault(),window.DebalesChat.track(tn.CHECKOUT_CLICKED,{chatId:nr()+e,cartValue:Number(I==null?void 0:I.total),cart:I}),H({dbls_method:"checkout_clicked"}),ji()&&Te(!1,"checkout_clicked")},[Dt,to]=Z.useState([]);Z.useEffect(()=>{const Oe=Fle(gE(w));to(Oe)},[w]);const rr=Z.useMemo(()=>Dt.map(Oe=>{if(Array.isArray(Oe)){const at=Oe.filter(Ie=>!fe.has(Ie.question));if(at.length===0)return null;const ce={isHighlighted:Oe[0].isHighlighted,enable:Oe[0].enable,type:Oe[0].type};return at.map(Ie=>({...Ie,...ce}))}else return fe.has(Oe.question)?null:Oe}).filter(Boolean),[Dt,fe]);Z.useEffect(()=>{const Oe=Ie=>{const j=Ie.detail.formId;switch(Ie.detail.type){case"open":case"embedOpen":setTimeout(()=>{const he=at(j);he&&pe(he)},800);break;case"close":se&&(t==null?void 0:t.KlaviyoFormIntegration)===!0&&setTimeout(()=>{Te(!0,"klaviyo_form_closed"),B(j),r({message:se,fromKlaviyo:!0})},1e4);break}},at=Ie=>{const j=document.querySelector(`[data-testid="klaviyo-form-${Ie}"]`);if(console.log(`formElement text ${Ie} =>`,j==null?void 0:j.innerText,j==null?void 0:j.textContent),j instanceof HTMLElement){const te=j.innerText||j.textContent;if(te)return console.log("Found form text:",te),`=> Klaviyo form content:
2974
2974
 
2975
2975
  `+te+`
2976
2976
 
2977
- => User Action: Klaviyo form closed`}return""},ce=Me=>{Me instanceof CustomEvent&&Oe(Me)};return window.addEventListener("klaviyoForms",ce),()=>{window.removeEventListener("klaviyoForms",ce)}},[se,t,r]);const[Ro,po]=Z.useState(!1),qn=J==="Highest"?"120px":J==="Higher"?"60px":"15px",ua=async()=>{if(Ee){console.warn("Support request called while already in support mode");return}try{const Oe=await fetch(`${Ti}/api/wordpress/support`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatid:nr()+e,nameSpace:e,userName:dt.name,userEmail:dt.email,userMessage:dt.message,tag:"support"})});if(Oe.ok){const at=await Oe.json(),{contactId:ce,ticketId:Me}=at;if(ce&&Me){const te=Up.connect(`${Hz}/api/v1/live-agent`);if(!te){console.error("Failed to create support socket connection"),m(un=>[...un,{text:"Sorry, we couldn't establish a connection to support. Please try again.",isBot:!0,conversationId:`support-error-${Date.now()}`}]);return}te.emit("join_ticket_conversation",{ticketID:Me,role:"contact",contactID:ce,nameSpace:e});const he=un=>{console.log("Joined support conversation:",un),m(Un=>[...Un,{text:"You are now connected to live support. A support agent will join shortly.",isBot:!0,conversationId:`support-live-${Date.now()}`}])},ke=un=>{console.log("Received conversation history:",un.length,"messages")},we=un=>{console.log("Support agent joined:",un),m(Un=>[...Un,{text:"A support agent has joined the conversation. You can now chat directly with them.",isBot:!0,conversationId:`agent-joined-${Date.now()}`}])},Je=un=>{console.log("New support message:",un),m(Un=>[...Un,{text:un.text||un.content,isBot:!0,conversationId:`support-msg-${Date.now()}`}])},$t=()=>{console.log("Support connection disconnected"),m(un=>[...un,{text:"Support connection has ended. You can continue chatting with me or request support again.",isBot:!0,conversationId:`support-end-${Date.now()}`}]),$e(!1)};te.on("joined_ticket_conversation",he),te.on("conversation_history",ke),te.on("participant_joined",we),te.on("message",Je),te.on("disconnect",$t),ve(te),$e(!0);const an=()=>{te.off("joined_ticket_conversation",he),te.off("conversation_history",ke),te.off("participant_joined",we),te.off("new_message",Je),te.off("disconnect",$t)};te.cleanupHandlers=an}const j=`support-confirm-${Date.now()}`;m(te=>[...te,{text:"Thanks for reaching out! Our support team has received your request and will get back to you within 24 hours.<br>In the meantime, feel free to continue chatting with me - I'll do my best to help!",isBot:!0,leading_queries:Et,conversationId:j}]),d(j),mt(te=>({...te,leadingQueries:!0})),Nt([]),console.log("Connected to support with existing user info:",jo())}else{const at=await Oe.json();console.error("Failed to connect to support:",at),m(ce=>[...ce,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}}catch{m(at=>[...at,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}},Oi=()=>{if(Ie(e)){const Me=Fp("https://test.thecollective.in/content/customersupport");Me.isValid&&(t!=null&&t.shopifyShopDomain&&(Me.url.hostname=t==null?void 0:t.shopifyShopDomain),window.open(Os(Me.url.toString()),"_blank"));return}if(Ee){console.warn("Already in support mode");return}const Oe=jo();let at=[];const ce=h[h.length-1];ce!=null&&ce.leading_queries&&ce.leading_queries.length>0?at=ce.leading_queries:h.length<=1&&(at=Dt.flatMap(Me=>Array.isArray(Me)?Me.map(j=>j.question):[Me.question]).slice(0,4)),Nt(at),Oe&&Oe.name&&Oe.email&&bt({name:Oe==null?void 0:Oe.name,email:Oe==null?void 0:Oe.email,message:""}),m(Me=>[...Me,{text:"Please provide your name, email and message to connect with support.",isBot:!0}]),nt(!0)},pr=async Oe=>{Oe.preventDefault();const at={name:"",email:"",message:""};let ce=!0;const Me=dt.name.trim(),j=dt.message.trim();Me||(at.name="Name cannot be empty or just whitespace.",ce=!1),(!dt.email||!zm.isEmail(dt.email))&&(at.email="Please enter a valid email address.",ce=!1),j||(at.message="Message cannot be empty or just whitespace.",ce=!1),re(at),ce&&(sf({name:Me,email:dt.email}),nt(!1),m(te=>te.slice(0,-1)),await ua())};Z.useEffect(()=>{if(h.length===1&&h[0].isBot){Re(at=>({...at,leadingQueries:!0}));const Oe=setTimeout(()=>{Re(at=>({...at,leadingQueries:!1}))},2e3);return()=>clearTimeout(Oe)}},[h]),Z.useEffect(()=>()=>{le&&(le.cleanupHandlers&&le.cleanupHandlers(),Up.disconnect(),ve(null),$e(!1))},[le]);const Br=()=>{Up.emit("send_message",{content:"The Contact has left the conversation.",type:"text",timestamp:new Date().toISOString()}),Up.emit("leave_conversation",{role:"contact"}),le&&(le.cleanupHandlers&&le.cleanupHandlers(),Up.disconnect(),ve(null),$e(!1),m(Oe=>[...Oe,{text:"You have exited live support mode. You can continue chatting with me or request support again.",isBot:!0,conversationId:`support-exit-${Date.now()}`}]))},ca=Oe=>{if(!Ee){console.warn("Attempted to send support message when not in support mode");return}if(!Up.getIsConnected()){console.error("Support socket is not connected"),m(at=>[...at,{text:"Connection lost. Please wait while we reconnect you to support.",isBot:!0,conversationId:`support-error-${Date.now()}`}]);return}Up.emit("send_message",{content:Oe,type:"text",timestamp:new Date().toISOString()}),m(at=>[...at,{text:Oe,isBot:!1,conversationId:`support-user-${Date.now()}`}])};return console.debug("main render"),!t||t.show_bot===!1||a?null:M.jsxs(Jw,{theme:pE(t,e),children:[M.jsx("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),M.jsx("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap",rel:"stylesheet"}),M.jsx(Ype,{}),!ie&&(rr==null?void 0:rr.length)!==0&&M.jsx(Vpe,{className:rt?"visible":"",$botId:e,$iconSize:V,$removeLogoBackground:t.removeLogoBackground,topOffset:qn,style:{right:z?"auto":"24px",left:z?"24px":"auto",display:"flex",flexDirection:"column",alignItems:z?"flex-start":"flex-end"},children:_e.suggestions?M.jsx(Ri,{isBot:!0,children:M.jsx(Ds,{loading:_e.suggestions})}):rr.map((Oe,at)=>{if(Array.isArray(Oe)){const ce=Oe.map(Me=>({question:Me.question,isHighlighted:Me.isHighlighted??!1})).filter(Me=>!fe.has(Me.question));return M.jsx(nH,{$index:at,$totalCount:rr.length,children:M.jsx(ohe,{messages:ce,botId:e,uiData:t,onClick:Me=>{const j=Oe.find(te=>te.question===Me);Te(!0,"suggested_question_clicked"),Ae(te=>{const he=new Set(te);return he.add(Me),he}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:j}),!R&&j?(Qt(!1),pt(!0),r({message:j.Follow_up_Question??j.question,answer:j==null?void 0:j.answer,products:j==null?void 0:j.products,fromKlaviyo:!1,leading_queries:j==null?void 0:j.leading_queries,followUpQuestion:j==null?void 0:j.Follow_up_Question,messType:"suggested_question"})):(Qt(!1),pt(!0),E(!0),O(j))}})},at)}else return M.jsx(nH,{$index:at,$totalCount:rr.length,children:M.jsx(rhe,{value:`${Oe.question}`,index:at,botId:e,uiData:t,onClose:()=>{Ae(ce=>{const Me=new Set(ce);return Me.add(Oe.question),Me})},onClick:()=>{Te(!0,"suggested_question_clicked"),Ae(ce=>{const Me=new Set(ce);return Me.add(Oe.question),Me}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:Oe}),R?(Qt(!1),pt(!0),E(!0),O(Oe)):(Qt(!1),pt(!0),r({message:Oe.question,answer:Oe.answer,products:Oe.products,leading_queries:Oe.leading_queries,followUpQuestion:Oe.Follow_up_Question,messType:"suggested_question"}))},isHighlighted:Oe.isHighlighted??!1})},at)})}),M.jsxs(kpe,{$topOffset:qn,$removeLogoBackground:t.removeLogoBackground,style:{display:ie?"none":"inline-flex",right:z?"auto":"24px",left:z?"24px":"auto"},children:[M.jsx(Tpe,{$showAnimation:t.enableChatButtonBackgroundAnimation??!1,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",$backgroundColor:t.backgroundColor||"#fff",$removeLogoBackground:t.removeLogoBackground,$topOffset:qn,$iconSize:V}),M.jsx(Rpe,{$backgroundColor:t.removeLogoBackground?"transparent":t.backgroundColor||"#fff",$botId:e,$iconSize:V,$removeLogoBackground:t.removeLogoBackground,topOffset:qn,$showAnimation:t.enableChatButtonBackgroundAnimation,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",id:"debales-chat-button","data-testid":"debales-chat-button",onClick:()=>{if(window.DebalesChat.track(tn.CHAT_BUTTON_CLICKED),Te(!ie,"chat_button_clicked"),!ie){const Oe=_();Oe.length>0?(m(Oe),Qt(!1),pt(!0)):(Qt(!0),pt(!1),Re(at=>({...at,initialMessage:!0,leadingQueries:!0})),mt({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1}),setTimeout(()=>{Qt(!1),pt(!0),Re(ce=>({...ce,initialMessage:!1}));const at={text:(t==null?void 0:t.initialMessage)||"Hi, I am an AI chatbot, how can I help you today?",isBot:!0};m([at]),Re(ce=>({...ce,leadingQueries:!0})),setTimeout(()=>{mt(ce=>({...ce,leadingQueries:!0}))},it)},it))}},"aria-label":"Chat",style:{display:ie?"none":"inline-flex",right:z?"auto":"24px",left:z?"24px":"auto"},children:M.jsx(Ope,{$botId:e,$removeLogoBackground:t.removeLogoBackground,"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"})})]}),ie&&vw.createPortal(M.jsx(M.Fragment,{children:M.jsxs($pe,{$backgroundColor:t.backgroundColor||"#fff",$fullScreenOnMobile:t.fullScreenOnMobile,$headerFontColor:t.headerFontColor||"#1C1C1C",$isLeft:z,$topOffset:qn,$mobileDisplayMode:t.mobileDisplayMode,$isVisible:de,"data-testid":"debales-chat-container",children:[M.jsxs(Npe,{$backgroundColor:Ie(e)?t.backgroundColor:t.botBackgroundColor||"#fff",style:{color:t.headerFontColor},children:[M.jsx("div",{style:{flexGrow:.1,display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden",marginRight:"8px",gap:"10px"},children:Ie(e)?M.jsxs(M.Fragment,{children:[M.jsx(KP,{"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),Ie(e)?M.jsx("div",{children:M.jsx("img",{src:yk,alt:"Chat Bot Icon",style:{height:"36px"}})}):M.jsxs(Dpe,{$botNameColor:t.headerFontColor,children:[M.jsxs("div",{style:{fontWeight:"700",wordBreak:"break-word"},children:[t.chatbotName,e==="catch-org-ai"&&M.jsx(Ipe,{$backgroundColor:t.callToActionBackgroundColor,$fontColor:t.callToActionFontColor,children:"Beta"})]}),M.jsx(Mpe,{})]})]}):M.jsx(Bpe,{children:M.jsxs(Lpe,{children:[M.jsx(KP,{src:t.bot_logo,alt:"Chat Bot Icon"}),M.jsx("span",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",display:"inline-block",maxWidth:"22ch"},children:t.chatbotName})]})})}),M.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"8px",marginLeft:"auto",flexShrink:0},children:[Ee&&M.jsxs("div",{style:{background:"#4CAF50",color:"white",padding:"4px 8px",borderRadius:"12px",fontSize:"12px",fontWeight:"500",display:"flex",alignItems:"center",gap:"4px"},children:[M.jsx("span",{style:{fontSize:"8px"},children:"●"}),"Live Support",M.jsx("button",{onClick:Br,style:{background:"none",border:"none",color:"white",cursor:"pointer",fontSize:"12px",marginLeft:"4px",padding:"2px 4px",borderRadius:"4px"},title:"Exit Support",children:"βœ•"})]}),M.jsxs(Zpe,{children:[M.jsx(WP,{$iconBG:t.backgroundColor,onClick:Oi,"aria-label":"Support","data-testid":"debales-support-button",disabled:Ee,style:{opacity:Ee?.5:1,cursor:Ee?"not-allowed":"pointer"},children:M.jsx(Tk,{color:t.headerFontColor})}),M.jsx(rH,{children:Ee?"Already connected to live support":"Click to chat with a Live Support Agent now."})]}),M.jsx(WP,{$iconBG:t.backgroundColor,onClick:()=>{Ve?yn(!0):Te(!1,"close_button_clicked")},id:"debales-minimize-button","data-testid":"debales-minimize-button","aria-label":"Minimize",children:M.jsx(Zm,{botNameColor:t.headerFontColor})})]}),M.jsx(t0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Kt?1:0}})]}),M.jsxs(Upe,{$backgroundColor:t.botBackgroundColor||"#fff",$mobileDisplayMode:t.mobileDisplayMode,children:[Ro&&((ot=(Kr=t.pluginConfig)==null?void 0:Kr.collectedUserInfo)==null?void 0:ot.discount)&&M.jsx(Nk,{discount:t.pluginConfig.collectedUserInfo.discount,uiData:t,onClose:()=>{po(!1),window.DebalesChat.track(tn.DISCOUNT_VIEWED,{discount:t.pluginConfig.collectedUserInfo.discount})}}),M.jsx(kk,{}),M.jsx(Pk,{uidata:t,product:fn,showModel:xr,setShowModel:Ur,onVariantSelect:Oe=>{console.debug("VariantSelectionModel : Adding item to cart:",Oe),L(Oe.id,1,{productId:(fn==null?void 0:fn.productId)||""}),Pt(!0),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:Oe.title,price:Number(Oe.price),link:`https://${t.shopifyShopDomain}/variants/${Oe.id}`,message:l,chatId:nr()+e})},botId:e}),nn&&M.jsx(zk,{setShowExitModal:yn,handleCloseChatbot:br,chatId:nr()+e}),M.jsxs(zpe,{id:"debales-conversation-group",$botBackgroundColor:t.botBackgroundColor||"#fff",ref:ne,$mobileDisplayMode:t.mobileDisplayMode,"data-testid":"debales-conversation-group",children:[M.jsx(Jpe,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Kt?1:0}}),M.jsxs(Fpe,{children:[gn&&h.map((Oe,at)=>{const ce=Oe.isBot,Me=$p(Oe.text);return Oe.hideConfirmation?null:M.jsxs(Z.Fragment,{children:[ce&&M.jsxs(XP,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff","data-testid":"debales-ai-message-container",children:[M.jsx("img",{src:ce?t.bot_logo:t.userMessage_logo,alt:"Chat User Icon",style:{marginLeft:"8px"}}),M.jsxs(tH,{children:[Me.map(j=>M.jsx("div",{children:M.jsx(Ri,{isBot:ce,children:M.jsx(bd,{components:{a:({href:te,children:he})=>{const ke=()=>{te!=null&&te.startsWith("https://shop.catch.org/")&&window.DebalesChat.track(tn.SHOPIFY_LINK_CLICKED)};return M.jsx("a",{href:te,target:"_blank",onClick:ke,children:he})}},remarkPlugins:[Mw,vE],children:j})})})),Oe.collections&&l===Oe.conversationId&&lt.collections&&M.jsx(Lk,{message:Oe,botId:e,uidata:t,onSendMessage:r,loading:p}),Oe.products&&l===Oe.conversationId&&lt.products&&M.jsx(Uk,{message:Oe,botId:e,uidata:t,onSendMessage:r,loading:p,storeMetaData:n,platform:W,setShowVariantModel:Ur,setSelectedProduct:ho,setCartVersion:P}),o&&M.jsx(N8,{children:M.jsx(Nx,{onClick:()=>{window._klOnsite&&(window._klOnsite.push(["openForm",Ce]),Te(!1,"klaviyo_grab_deal_button"))},children:"πŸš€ Grab Deal Now!"})}),I&&I.itemCount>0&&l===Oe.conversationId&&lt.cartSummary&&St&&M.jsx(Mk,{onCheckout:Ho,onKeepShopping:()=>{Pt(!1)}}),We&&We.length>0&&l===Oe.conversationId&&lt.bulkItems&&M.jsx(mk,{onClick:()=>us(Oe.conversationId),children:"Add Bulk Items to Cart"}),A&&h.indexOf(Oe)===h.length-1&&M.jsx(M.Fragment,{children:M.jsx(jk,{setShowModel:j=>{var he,ke;const te=typeof j=="function"?j(A):j;E(te),!te&&((ke=(he=t.pluginConfig)==null?void 0:he.collectedUserInfo)!=null&&ke.discount)&&po(!0)},inChat:!0,showFormInstructions:!1})}),It&&h.indexOf(Oe)===h.length-1&&M.jsxs(Qpe,{onSubmit:pr,noValidate:!0,"data-testid":"debales-support-form",children:[Ie(e)?M.jsxs(M.Fragment,{children:[M.jsx(ru,{label:"Name",name:"name",type:"text",value:dt.name,onChange:j=>bt(te=>({...te,name:j.target.value})),required:!0,error:yt.name,isCollectiveBot:!0}),M.jsx(ru,{label:"Email",name:"email",type:"email",value:dt.email,onChange:j=>bt(te=>({...te,email:j.target.value})),required:!0,error:yt.email,isCollectiveBot:!0}),M.jsx(Fk,{label:"Message",name:"message",value:dt.message,onChange:j=>bt(te=>({...te,message:j.target.value})),required:!0,error:yt.message,rows:4,isCollectiveBot:!0})]}):M.jsxs(M.Fragment,{children:[M.jsxs(z8,{children:[M.jsxs(F8,{children:["Name",M.jsx("span",{children:"*"})]}),M.jsx(iH,{type:"text",required:!0,value:dt.name,onChange:j=>bt(te=>({...te,name:j.target.value})),placeholder:"John"}),yt.name&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:yt.name})]}),M.jsxs(z8,{children:[M.jsxs(F8,{children:["Email",M.jsx("span",{children:"*"})]}),M.jsx(iH,{type:"email",required:!0,value:dt.email,onChange:j=>bt(te=>({...te,email:j.target.value})),placeholder:"olivia@untitledui.com"}),yt.email&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:yt.email})]}),M.jsxs(z8,{children:[M.jsxs(F8,{children:["Message",M.jsx("span",{children:"*"})]}),M.jsx(Kpe,{required:!0,value:dt.message,onChange:j=>bt(te=>({...te,message:j.target.value})),placeholder:"I need help with..."}),yt.message&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:yt.message})]})]}),M.jsx(Xpe,{children:M.jsx(Wpe,{type:"submit",children:"Submit"})})]}),Ct&&!p&&l===Oe.conversationId&&M.jsx(Ri,{isBot:ce,children:M.jsx(Ds,{loading:Ct})})]})]}),!ce&&M.jsx(qpe,{$fontColor:t.userFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:M.jsx(Ri,{isBot:!!ce,children:M.jsx(bd,{children:Oe.text})})}),h.length==1&&at==0&&!A&&M.jsx(N8,{children:_e.leadingQueries?M.jsx(Ri,{isBot:ce??!0,children:M.jsx(Ds,{loading:_e.leadingQueries})}):Dt.map(j=>Array.isArray(j)?j[0]:j).map((j,te)=>M.jsxs(eH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{R?(E(!0),O({question:j.question,answer:j.answer,products:j.products,path:"/",nameSpace:window.DebalesChat.projectId})):(Qt(!1),pt(!0),r({message:j.question,answer:j.answer,products:j.products,leading_queries:j.leading_queries,followUpQuestion:j.Follow_up_Question,messType:"leading_query"})),Ae(he=>{const ke=new Set(he);return ke.add(j.question),ke}),window.DebalesChat.track(tn.INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED,{question:j.question})},disabled:p,$disabled:p,children:[j.question,M.jsx(JP,{color:t.callToActionFontColor})]},te))}),Oe.leading_queries&&Oe.leading_queries.length>0&&l===Oe.conversationId&&lt.leadingQueries&&!o&&!A&&M.jsx(N8,{children:Oe.leading_queries.map((j,te)=>M.jsxs(eH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{R?(E(!0),O({question:j,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:j,messType:"leading_query"}),window.DebalesChat.track(tn.LEADING_QUERY_CLICKED,{query:j})},disabled:p,$disabled:p,children:[j,M.jsx(JP,{color:t.callToActionFontColor})]},te))})]},at)}),(p||en)&&!Ee&&M.jsxs(XP,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:[M.jsx("img",{src:t.bot_logo,alt:"Chat User Icon"}),M.jsx(tH,{children:M.jsx(Ri,{isBot:!0,children:M.jsx("div",{style:{display:"flex",alignItems:"center",gap:"4px",animation:"fadeIn 0.3s ease-in-out"},children:M.jsx(Ds,{loading:p||en})})})})]})]}),M.jsx(e0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Y?1:0}})]}),M.jsxs("div",{className:"debales-footer-container",style:{width:"calc(100%-24px)",backgroundColor:t.botBackgroundColor||"#fff",color:t.fontColor||"#000"},children:[(e==="catch-org-ai"||e==="letsgo-catch")&&M.jsx(Hpe,{children:M.jsx("span",{children:`"${t.chatbotName}" can make mistakes.`})}),M.jsx("div",{children:M.jsx(Hk,{disabled:p,inputState:!1,isInSupportMode:Ee,onSupportMessage:ca})}),(t.debales_branding??!0)&&M.jsxs(jpe,{href:"https://debales.ai/?open=true",target:"_blank",title:"debales-link",style:{color:t.fontColor?t.fontColor:"fff",marginTop:e==="catch-org-ai"?"0":"9px"},children:[M.jsx("p",{children:"Powered by"}),M.jsxs(Ppe,{children:[M.jsx("img",{src:`${Ti}/images/debales_logo_d.png`,alt:"Debales logo"}),M.jsx("p",{children:"DEBALES"})]})]})]})]})]})}),Q.shadowRoot)]})},n0e=ae.p`
2977
+ => User Action: Klaviyo form closed`}return""},ce=Ie=>{Ie instanceof CustomEvent&&Oe(Ie)};return window.addEventListener("klaviyoForms",ce),()=>{window.removeEventListener("klaviyoForms",ce)}},[se,t,r]);const[Ro,po]=Z.useState(!1),qn=J==="Highest"?"120px":J==="Higher"?"60px":"15px",ua=async()=>{if(Ee){console.warn("Support request called while already in support mode");return}try{const Oe=await fetch(`${Ti}/api/wordpress/support`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatid:nr()+e,nameSpace:e,userName:dt.name,userEmail:dt.email,userMessage:dt.message,tag:"support"})});if(Oe.ok){const at=await Oe.json(),{contactId:ce,ticketId:Ie}=at;if(ce&&Ie){const te=Up.connect(`${Hz}/api/v1/live-agent`);if(!te){console.error("Failed to create support socket connection"),m(un=>[...un,{text:"Sorry, we couldn't establish a connection to support. Please try again.",isBot:!0,conversationId:`support-error-${Date.now()}`}]);return}te.emit("join_ticket_conversation",{ticketID:Ie,role:"contact",contactID:ce,nameSpace:e});const he=un=>{console.log("Joined support conversation:",un),m(Un=>[...Un,{text:"You are now connected to live support. A support agent will join shortly.",isBot:!0,conversationId:`support-live-${Date.now()}`}])},ke=un=>{console.log("Received conversation history:",un.length,"messages")},we=un=>{console.log("Support agent joined:",un),m(Un=>[...Un,{text:"A support agent has joined the conversation. You can now chat directly with them.",isBot:!0,conversationId:`agent-joined-${Date.now()}`}])},Je=un=>{console.log("New support message:",un),m(Un=>[...Un,{text:un.text||un.content,isBot:!0,conversationId:`support-msg-${Date.now()}`}])},$t=()=>{console.log("Support connection disconnected"),m(un=>[...un,{text:"Support connection has ended. You can continue chatting with me or request support again.",isBot:!0,conversationId:`support-end-${Date.now()}`}]),$e(!1)};te.on("joined_ticket_conversation",he),te.on("conversation_history",ke),te.on("participant_joined",we),te.on("message",Je),te.on("disconnect",$t),ve(te),$e(!0);const an=()=>{te.off("joined_ticket_conversation",he),te.off("conversation_history",ke),te.off("participant_joined",we),te.off("new_message",Je),te.off("disconnect",$t)};te.cleanupHandlers=an}const j=`support-confirm-${Date.now()}`;m(te=>[...te,{text:"Thanks for reaching out! Our support team has received your request and will get back to you within 24 hours.<br>In the meantime, feel free to continue chatting with me - I'll do my best to help!",isBot:!0,leading_queries:Et,conversationId:j}]),d(j),mt(te=>({...te,leadingQueries:!0})),Nt([]),console.log("Connected to support with existing user info:",jo())}else{const at=await Oe.json();console.error("Failed to connect to support:",at),m(ce=>[...ce,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}}catch{m(at=>[...at,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}},Oi=()=>{if(Me(e)){const Ie=Fp("https://test.thecollective.in/content/customersupport");Ie.isValid&&(t!=null&&t.shopifyShopDomain&&(Ie.url.hostname=t==null?void 0:t.shopifyShopDomain),window.open(Os(Ie.url.toString()),"_blank"));return}if(Ee){console.warn("Already in support mode");return}const Oe=jo();let at=[];const ce=h[h.length-1];ce!=null&&ce.leading_queries&&ce.leading_queries.length>0?at=ce.leading_queries:h.length<=1&&(at=Dt.flatMap(Ie=>Array.isArray(Ie)?Ie.map(j=>j.question):[Ie.question]).slice(0,4)),Nt(at),Oe&&Oe.name&&Oe.email&&bt({name:Oe==null?void 0:Oe.name,email:Oe==null?void 0:Oe.email,message:""}),m(Ie=>[...Ie,{text:"Please provide your name, email and message to connect with support.",isBot:!0}]),nt(!0)},pr=async Oe=>{Oe.preventDefault();const at={name:"",email:"",message:""};let ce=!0;const Ie=dt.name.trim(),j=dt.message.trim();Ie||(at.name="Name cannot be empty or just whitespace.",ce=!1),(!dt.email||!zm.isEmail(dt.email))&&(at.email="Please enter a valid email address.",ce=!1),j||(at.message="Message cannot be empty or just whitespace.",ce=!1),re(at),ce&&(sf({name:Ie,email:dt.email}),nt(!1),m(te=>te.slice(0,-1)),await ua())};Z.useEffect(()=>{if(h.length===1&&h[0].isBot){Re(at=>({...at,leadingQueries:!0}));const Oe=setTimeout(()=>{Re(at=>({...at,leadingQueries:!1}))},2e3);return()=>clearTimeout(Oe)}},[h]),Z.useEffect(()=>()=>{le&&(le.cleanupHandlers&&le.cleanupHandlers(),Up.disconnect(),ve(null),$e(!1))},[le]);const Br=()=>{Up.emit("send_message",{content:"The Contact has left the conversation.",type:"text",timestamp:new Date().toISOString()}),Up.emit("leave_conversation",{role:"contact"}),le&&(le.cleanupHandlers&&le.cleanupHandlers(),Up.disconnect(),ve(null),$e(!1),m(Oe=>[...Oe,{text:"You have exited live support mode. You can continue chatting with me or request support again.",isBot:!0,conversationId:`support-exit-${Date.now()}`}]))},ca=Oe=>{if(!Ee){console.warn("Attempted to send support message when not in support mode");return}if(!Up.getIsConnected()){console.error("Support socket is not connected"),m(at=>[...at,{text:"Connection lost. Please wait while we reconnect you to support.",isBot:!0,conversationId:`support-error-${Date.now()}`}]);return}Up.emit("send_message",{content:Oe,type:"text",timestamp:new Date().toISOString()}),m(at=>[...at,{text:Oe,isBot:!1,conversationId:`support-user-${Date.now()}`}])};return console.debug("main render"),!t||t.show_bot===!1||a?null:M.jsxs(Jw,{theme:pE(t,e),children:[M.jsx("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),M.jsx("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap",rel:"stylesheet"}),M.jsx(Ype,{}),!ie&&(rr==null?void 0:rr.length)!==0&&M.jsx(Vpe,{className:rt?"visible":"",$botId:e,$iconSize:V,$removeLogoBackground:t.removeLogoBackground,topOffset:qn,style:{right:z?"auto":"24px",left:z?"24px":"auto",display:"flex",flexDirection:"column",alignItems:z?"flex-start":"flex-end"},children:_e.suggestions?M.jsx(Ri,{isBot:!0,children:M.jsx(Ds,{loading:_e.suggestions})}):rr.map((Oe,at)=>{if(Array.isArray(Oe)){const ce=Oe.map(Ie=>({question:Ie.question,isHighlighted:Ie.isHighlighted??!1})).filter(Ie=>!fe.has(Ie.question));return M.jsx(nH,{$index:at,$totalCount:rr.length,children:M.jsx(ohe,{messages:ce,botId:e,uiData:t,onClick:Ie=>{const j=Oe.find(te=>te.question===Ie);Te(!0,"suggested_question_clicked"),Ae(te=>{const he=new Set(te);return he.add(Ie),he}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:j}),!R&&j?(Qt(!1),pt(!0),r({message:j.Follow_up_Question??j.question,answer:j==null?void 0:j.answer,products:j==null?void 0:j.products,fromKlaviyo:!1,leading_queries:j==null?void 0:j.leading_queries,followUpQuestion:j==null?void 0:j.Follow_up_Question,messType:"suggested_question"})):(Qt(!1),pt(!0),E(!0),O(j))}})},at)}else return M.jsx(nH,{$index:at,$totalCount:rr.length,children:M.jsx(rhe,{value:`${Oe.question}`,index:at,botId:e,uiData:t,onClose:()=>{Ae(ce=>{const Ie=new Set(ce);return Ie.add(Oe.question),Ie})},onClick:()=>{Te(!0,"suggested_question_clicked"),Ae(ce=>{const Ie=new Set(ce);return Ie.add(Oe.question),Ie}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:Oe}),R?(Qt(!1),pt(!0),E(!0),O(Oe)):(Qt(!1),pt(!0),r({message:Oe.question,answer:Oe.answer,products:Oe.products,leading_queries:Oe.leading_queries,followUpQuestion:Oe.Follow_up_Question,messType:"suggested_question"}))},isHighlighted:Oe.isHighlighted??!1})},at)})}),M.jsxs(kpe,{$topOffset:qn,$removeLogoBackground:t.removeLogoBackground,style:{display:ie?"none":"inline-flex",right:z?"auto":"24px",left:z?"24px":"auto"},children:[M.jsx(Tpe,{$showAnimation:t.enableChatButtonBackgroundAnimation??!1,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",$backgroundColor:t.backgroundColor||"#fff",$removeLogoBackground:t.removeLogoBackground,$topOffset:qn,$iconSize:V}),M.jsx(Rpe,{$backgroundColor:t.removeLogoBackground?"transparent":t.backgroundColor||"#fff",$botId:e,$iconSize:V,$removeLogoBackground:t.removeLogoBackground,topOffset:qn,$showAnimation:t.enableChatButtonBackgroundAnimation,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",id:"debales-chat-button","data-testid":"debales-chat-button",onClick:()=>{if(window.DebalesChat.track(tn.CHAT_BUTTON_CLICKED),Te(!ie,"chat_button_clicked"),!ie){const Oe=_();Oe.length>0?(m(Oe),Qt(!1),pt(!0)):(Qt(!0),pt(!1),Re(at=>({...at,initialMessage:!0,leadingQueries:!0})),mt({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1}),setTimeout(()=>{Qt(!1),pt(!0),Re(ce=>({...ce,initialMessage:!1}));const at={text:(t==null?void 0:t.initialMessage)||"Hi, I am an AI chatbot, how can I help you today?",isBot:!0};m([at]),Re(ce=>({...ce,leadingQueries:!0})),setTimeout(()=>{mt(ce=>({...ce,leadingQueries:!0}))},it)},it))}},"aria-label":"Chat",style:{display:ie?"none":"inline-flex",right:z?"auto":"24px",left:z?"24px":"auto"},children:M.jsx(Ope,{$botId:e,$removeLogoBackground:t.removeLogoBackground,"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"})})]}),ie&&vw.createPortal(M.jsx(M.Fragment,{children:M.jsxs($pe,{$backgroundColor:t.backgroundColor||"#fff",$fullScreenOnMobile:t.fullScreenOnMobile,$headerFontColor:t.headerFontColor||"#1C1C1C",$isLeft:z,$topOffset:qn,$mobileDisplayMode:t.mobileDisplayMode,$isVisible:de,"data-testid":"debales-chat-container",children:[M.jsxs(Npe,{$backgroundColor:Me(e)?t.backgroundColor:t.botBackgroundColor||"#fff",style:{color:t.headerFontColor},children:[M.jsx("div",{style:{flexGrow:.1,display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden",marginRight:"8px",gap:"10px"},children:Me(e)?M.jsxs(M.Fragment,{children:[M.jsx(KP,{"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),Me(e)?M.jsx("div",{children:M.jsx("img",{src:yk,alt:"Chat Bot Icon",style:{height:"36px"}})}):M.jsxs(Dpe,{$botNameColor:t.headerFontColor,children:[M.jsxs("div",{style:{fontWeight:"700",wordBreak:"break-word"},children:[t.chatbotName,e==="catch-org-ai"&&M.jsx(Ipe,{$backgroundColor:t.callToActionBackgroundColor,$fontColor:t.callToActionFontColor,children:"Beta"})]}),M.jsx(Mpe,{})]})]}):M.jsx(Bpe,{children:M.jsxs(Lpe,{children:[M.jsx(KP,{src:t.bot_logo,alt:"Chat Bot Icon"}),M.jsx("span",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",display:"inline-block",maxWidth:"22ch"},children:t.chatbotName})]})})}),M.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"8px",marginLeft:"auto",flexShrink:0},children:[Ee&&M.jsxs("div",{style:{background:"#4CAF50",color:"white",padding:"4px 8px",borderRadius:"12px",fontSize:"12px",fontWeight:"500",display:"flex",alignItems:"center",gap:"4px"},children:[M.jsx("span",{style:{fontSize:"8px"},children:"●"}),"Live Support",M.jsx("button",{onClick:Br,style:{background:"none",border:"none",color:"white",cursor:"pointer",fontSize:"12px",marginLeft:"4px",padding:"2px 4px",borderRadius:"4px"},title:"Exit Support",children:"βœ•"})]}),M.jsxs(Zpe,{children:[M.jsx(WP,{$iconBG:t.backgroundColor,onClick:Oi,"aria-label":"Support","data-testid":"debales-support-button",disabled:Ee,style:{opacity:Ee?.5:1,cursor:Ee?"not-allowed":"pointer"},children:M.jsx(Tk,{color:t.headerFontColor})}),M.jsx(rH,{children:Ee?"Already connected to live support":"Click to chat with a Live Support Agent now."})]}),M.jsx(WP,{$iconBG:t.backgroundColor,onClick:()=>{Ve?yn(!0):Te(!1,"close_button_clicked")},id:"debales-minimize-button","data-testid":"debales-minimize-button","aria-label":"Minimize",children:M.jsx(Zm,{botNameColor:t.headerFontColor})})]}),M.jsx(t0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Kt?1:0}})]}),M.jsxs(Upe,{$backgroundColor:t.botBackgroundColor||"#fff",$mobileDisplayMode:t.mobileDisplayMode,children:[Ro&&((ot=(Kr=t.pluginConfig)==null?void 0:Kr.collectedUserInfo)==null?void 0:ot.discount)&&M.jsx(Nk,{discount:t.pluginConfig.collectedUserInfo.discount,uiData:t,onClose:()=>{po(!1),window.DebalesChat.track(tn.DISCOUNT_VIEWED,{discount:t.pluginConfig.collectedUserInfo.discount})}}),M.jsx(kk,{}),M.jsx(Pk,{uidata:t,product:fn,showModel:xr,setShowModel:Ur,onVariantSelect:Oe=>{console.debug("VariantSelectionModel : Adding item to cart:",Oe),L(Oe.id,1,{productId:(fn==null?void 0:fn.productId)||""}),Pt(!0),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:Oe.title,price:Number(Oe.price),link:`https://${t.shopifyShopDomain}/variants/${Oe.id}`,message:l,chatId:nr()+e})},botId:e}),nn&&M.jsx(zk,{setShowExitModal:yn,handleCloseChatbot:br,chatId:nr()+e}),M.jsxs(zpe,{id:"debales-conversation-group",$botBackgroundColor:t.botBackgroundColor||"#fff",ref:ne,$mobileDisplayMode:t.mobileDisplayMode,"data-testid":"debales-conversation-group",children:[M.jsx(Jpe,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Kt?1:0}}),M.jsxs(Fpe,{children:[gn&&h.map((Oe,at)=>{const ce=Oe.isBot,Ie=$p(Oe.text);return Oe.hideConfirmation?null:M.jsxs(Z.Fragment,{children:[ce&&M.jsxs(XP,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff","data-testid":"debales-ai-message-container",children:[M.jsx("img",{src:ce?t.bot_logo:t.userMessage_logo,alt:"Chat User Icon",style:{marginLeft:"8px"}}),M.jsxs(tH,{children:[Ie.map(j=>M.jsx("div",{children:M.jsx(Ri,{isBot:ce,children:M.jsx(bd,{components:{a:({href:te,children:he})=>{const ke=()=>{te!=null&&te.startsWith("https://shop.catch.org/")&&window.DebalesChat.track(tn.SHOPIFY_LINK_CLICKED)};return M.jsx("a",{href:te,target:"_blank",onClick:ke,children:he})}},remarkPlugins:[Mw,vE],children:j})})})),Oe.collections&&l===Oe.conversationId&&lt.collections&&M.jsx(Lk,{message:Oe,botId:e,uidata:t,onSendMessage:r,loading:p}),Oe.products&&l===Oe.conversationId&&lt.products&&M.jsx(Uk,{message:Oe,botId:e,uidata:t,onSendMessage:r,loading:p,storeMetaData:n,platform:W,setShowVariantModel:Ur,setSelectedProduct:ho,setCartVersion:P}),o&&M.jsx(N8,{children:M.jsx(Nx,{onClick:()=>{window._klOnsite&&(window._klOnsite.push(["openForm",Ce]),Te(!1,"klaviyo_grab_deal_button"))},children:"πŸš€ Grab Deal Now!"})}),I&&I.itemCount>0&&l===Oe.conversationId&&lt.cartSummary&&St&&M.jsx(Mk,{onCheckout:Ho,onKeepShopping:()=>{Pt(!1)}}),We&&We.length>0&&l===Oe.conversationId&&lt.bulkItems&&M.jsx(mk,{onClick:()=>us(Oe.conversationId),children:"Add Bulk Items to Cart"}),A&&h.indexOf(Oe)===h.length-1&&M.jsx(M.Fragment,{children:M.jsx(jk,{setShowModel:j=>{var he,ke;const te=typeof j=="function"?j(A):j;E(te),!te&&((ke=(he=t.pluginConfig)==null?void 0:he.collectedUserInfo)!=null&&ke.discount)&&po(!0)},inChat:!0,showFormInstructions:!1})}),It&&h.indexOf(Oe)===h.length-1&&M.jsxs(Qpe,{onSubmit:pr,noValidate:!0,"data-testid":"debales-support-form",children:[Me(e)?M.jsxs(M.Fragment,{children:[M.jsx(ru,{label:"Name",name:"name",type:"text",value:dt.name,onChange:j=>bt(te=>({...te,name:j.target.value})),required:!0,error:yt.name,isCollectiveBot:!0}),M.jsx(ru,{label:"Email",name:"email",type:"email",value:dt.email,onChange:j=>bt(te=>({...te,email:j.target.value})),required:!0,error:yt.email,isCollectiveBot:!0}),M.jsx(Fk,{label:"Message",name:"message",value:dt.message,onChange:j=>bt(te=>({...te,message:j.target.value})),required:!0,error:yt.message,rows:4,isCollectiveBot:!0})]}):M.jsxs(M.Fragment,{children:[M.jsxs(z8,{children:[M.jsxs(F8,{children:["Name",M.jsx("span",{children:"*"})]}),M.jsx(iH,{type:"text",required:!0,value:dt.name,onChange:j=>bt(te=>({...te,name:j.target.value})),placeholder:"John"}),yt.name&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:yt.name})]}),M.jsxs(z8,{children:[M.jsxs(F8,{children:["Email",M.jsx("span",{children:"*"})]}),M.jsx(iH,{type:"email",required:!0,value:dt.email,onChange:j=>bt(te=>({...te,email:j.target.value})),placeholder:"olivia@untitledui.com"}),yt.email&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:yt.email})]}),M.jsxs(z8,{children:[M.jsxs(F8,{children:["Message",M.jsx("span",{children:"*"})]}),M.jsx(Kpe,{required:!0,value:dt.message,onChange:j=>bt(te=>({...te,message:j.target.value})),placeholder:"I need help with..."}),yt.message&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:yt.message})]})]}),M.jsx(Xpe,{children:M.jsx(Wpe,{type:"submit",children:"Submit"})})]}),Ct&&!p&&l===Oe.conversationId&&M.jsx(Ri,{isBot:ce,children:M.jsx(Ds,{loading:Ct})})]})]}),!ce&&M.jsx(qpe,{$fontColor:t.userFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:M.jsx(Ri,{isBot:!!ce,children:M.jsx(bd,{children:Oe.text})})}),h.length==1&&at==0&&!A&&M.jsx(N8,{children:_e.leadingQueries?M.jsx(Ri,{isBot:ce??!0,children:M.jsx(Ds,{loading:_e.leadingQueries})}):Dt.map(j=>Array.isArray(j)?j[0]:j).map((j,te)=>M.jsxs(eH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{R?(E(!0),O({question:j.question,answer:j.answer,products:j.products,path:"/",nameSpace:window.DebalesChat.projectId})):(Qt(!1),pt(!0),r({message:j.question,answer:j.answer,products:j.products,leading_queries:j.leading_queries,followUpQuestion:j.Follow_up_Question,messType:"leading_query"})),Ae(he=>{const ke=new Set(he);return ke.add(j.question),ke}),window.DebalesChat.track(tn.INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED,{question:j.question})},disabled:p,$disabled:p,children:[j.question,M.jsx(JP,{color:t.callToActionFontColor})]},te))}),Oe.leading_queries&&Oe.leading_queries.length>0&&l===Oe.conversationId&&lt.leadingQueries&&!o&&!A&&M.jsx(N8,{children:Oe.leading_queries.map((j,te)=>M.jsxs(eH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{R?(E(!0),O({question:j,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:j,messType:"leading_query"}),window.DebalesChat.track(tn.LEADING_QUERY_CLICKED,{query:j})},disabled:p,$disabled:p,children:[j,M.jsx(JP,{color:t.callToActionFontColor})]},te))})]},at)}),(p||en)&&!Ee&&M.jsxs(XP,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:[M.jsx("img",{src:t.bot_logo,alt:"Chat User Icon"}),M.jsx(tH,{children:M.jsx(Ri,{isBot:!0,children:M.jsx("div",{style:{display:"flex",alignItems:"center",gap:"4px",animation:"fadeIn 0.3s ease-in-out"},children:M.jsx(Ds,{loading:p||en})})})})]})]}),M.jsx(e0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Y?1:0}})]}),M.jsxs("div",{className:"debales-footer-container",style:{width:"calc(100%-24px)",backgroundColor:t.botBackgroundColor||"#fff",color:t.fontColor||"#000"},children:[(e==="catch-org-ai"||e==="letsgo-catch")&&M.jsx(Hpe,{children:M.jsx("span",{children:`"${t.chatbotName}" can make mistakes.`})}),M.jsx("div",{children:M.jsx(Hk,{disabled:p,inputState:!1,isInSupportMode:Ee,onSupportMessage:ca})}),(t.debales_branding??!0)&&M.jsxs(jpe,{href:"https://debales.ai/?open=true",target:"_blank",title:"debales-link",style:{color:t.fontColor?t.fontColor:"fff",marginTop:e==="catch-org-ai"?"0":"9px"},children:[M.jsx("p",{children:"Powered by"}),M.jsxs(Ppe,{children:[M.jsx("img",{src:`${Ti}/images/debales_logo_d.png`,alt:"Debales logo"}),M.jsx("p",{children:"DEBALES"})]})]})]})]})]})}),Q.shadowRoot)]})},n0e=ae.p`
2978
2978
  margin: 0;
2979
2979
  font-size: 16px;
2980
2980
  text-align: left;
@@ -3137,7 +3137,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3137
3137
  -ms-flex-negative: 0;
3138
3138
  flex-shrink: 0;
3139
3139
  object-fit: contain;
3140
- border-radius: ${e=>Ie(e.theme.botId)?"0":"50%"} !important;
3140
+ border-radius: ${e=>Me(e.theme.botId)?"0":"50%"} !important;
3141
3141
  padding: 2px !important;
3142
3142
 
3143
3143
  @media screen and (max-width: 768px) {
@@ -3191,7 +3191,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3191
3191
  z-index: 2147483647;
3192
3192
  background-color: ${e=>e.$backgroundColor};
3193
3193
  color: ${e=>e.$headerFontColor};
3194
- border-radius: ${e=>Ie(e.theme.botId)?"0":"16px"} !important;
3194
+ border-radius: ${e=>Me(e.theme.botId)?"0":"16px"} !important;
3195
3195
  padding: 0 !important;
3196
3196
  margin: 0 !important;
3197
3197
  display: flex;
@@ -3217,7 +3217,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3217
3217
  left: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$isLeft?"16px":"auto":e.$fullScreenOnMobile?"0":e.$isLeft?"16px":"auto"};
3218
3218
  right: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$isLeft?"auto":"16px":e.$fullScreenOnMobile?"0":e.$isLeft?"auto":"16px"};
3219
3219
  bottom: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$topOffset||"16px":e.$fullScreenOnMobile?"0":e.$topOffset||"16px"};
3220
- border-radius: ${e=>Ie(e.theme.botId)||e.$mobileDisplayMode==="full-screen"?"0":e.$mobileDisplayMode==="half-screen"?"16px 16px 0 0":"16px"} !important;
3220
+ border-radius: ${e=>Me(e.theme.botId)||e.$mobileDisplayMode==="full-screen"?"0":e.$mobileDisplayMode==="half-screen"?"16px 16px 0 0":"16px"} !important;
3221
3221
  overflow: hidden;
3222
3222
  touch-action: manipulation;
3223
3223
  /* Apply proper touch action for mobile modes to allow content scrolling */
@@ -3240,14 +3240,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3240
3240
  display: flex;
3241
3241
  align-items: center;
3242
3242
  padding: 2px;
3243
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
3243
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
3244
3244
  background: conic-gradient(#0ead3f, #00b200, #1ca77e, #379bfb, #0ead3f);
3245
3245
  `,v0e=ae.div`
3246
3246
  display: flex;
3247
3247
  align-items: center;
3248
3248
  background: #fff;
3249
3249
  padding: 0 16px 0 3px; /* Adjusted padding */
3250
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
3250
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
3251
3251
  height: 40px; /* Adjusted height */
3252
3252
  font-weight: 600;
3253
3253
  font-size: 16px; /* Adjusted font-size */
@@ -3255,9 +3255,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3255
3255
  `,lH=ae.button`
3256
3256
  width: 40px;
3257
3257
  height: 40px;
3258
- border-radius: ${e=>Ie(e.theme.botId)?"0":"50%"} !important;
3258
+ border-radius: ${e=>Me(e.theme.botId)?"0":"50%"} !important;
3259
3259
  border: 1.5px solid rgba(0, 0, 0, 0.3);
3260
- background: ${e=>Ie(e.theme.botId)?e.$iconBG:"#fff"};
3260
+ background: ${e=>Me(e.theme.botId)?e.$iconBG:"#fff"};
3261
3261
  display: flex;
3262
3262
  align-items: center;
3263
3263
  justify-content: center;
@@ -3265,7 +3265,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3265
3265
  cursor: pointer;
3266
3266
  transition: background 0.2s;
3267
3267
  &:hover {
3268
- background: ${e=>!Ie(e.theme.botId)&&"#f5f5f5"};
3268
+ background: ${e=>!Me(e.theme.botId)&&"#f5f5f5"};
3269
3269
  }
3270
3270
  `,y0e=ae.div`
3271
3271
  z-index: 2147483647;
@@ -3299,7 +3299,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3299
3299
 
3300
3300
  &::-webkit-scrollbar-thumb {
3301
3301
  background: #7a7979;
3302
- border-radius: ${e=>Ie(e.theme.botId)?"0":"5px"} !important;
3302
+ border-radius: ${e=>Me(e.theme.botId)?"0":"5px"} !important;
3303
3303
  }
3304
3304
 
3305
3305
  /* Improved scrolling behavior for all mobile modes */
@@ -3435,12 +3435,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3435
3435
  justify-content: center;
3436
3436
  text-align: left;
3437
3437
  align-self: stretch;
3438
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
3438
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
3439
3439
  color: white;
3440
3440
  border: none;
3441
3441
  cursor: ${e=>e.$disabled?"default":"pointer"};
3442
3442
  font-size: 14px;
3443
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
3443
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
3444
3444
  line-height: 20px !important;
3445
3445
  transition: all 0.05s ease;
3446
3446
  height: auto !important;
@@ -3615,7 +3615,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3615
3615
  margin: 4px 10px 4px;
3616
3616
  padding: 16px 16px;
3617
3617
  background-color: ${e=>e.theme.colors.bot.message||"#fff"};
3618
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
3618
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
3619
3619
  width: 100%;
3620
3620
  max-width: 320px;
3621
3621
  `,P8=ae.div`
@@ -3629,7 +3629,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3629
3629
  margin-bottom: 8px;
3630
3630
  font-size: 16px;
3631
3631
  color: #1c1c1c;
3632
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
3632
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
3633
3633
 
3634
3634
  span {
3635
3635
  color: #ff3b30;
@@ -3638,30 +3638,30 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3638
3638
  width: calc(100% - 26px);
3639
3639
  padding: 12px;
3640
3640
  border: 1px solid #d0d5dd;
3641
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
3641
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
3642
3642
  font-size: 16px;
3643
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
3644
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
3643
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
3644
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
3645
3645
 
3646
3646
  &:focus {
3647
3647
  outline: none;
3648
3648
  border-color: #f48722;
3649
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
3649
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
3650
3650
  }
3651
3651
  `,M0e=ae.textarea`
3652
3652
  width: calc(100% - 26px);
3653
3653
  padding: 12px;
3654
3654
  border: 1px solid #d0d5dd;
3655
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
3655
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
3656
3656
  font-size: 16px;
3657
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
3658
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
3657
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
3658
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
3659
3659
  resize: none;
3660
3660
 
3661
3661
  &:focus {
3662
3662
  outline: none;
3663
3663
  border-color: #f48722;
3664
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
3664
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
3665
3665
  }
3666
3666
  `,I0e=ae.button`
3667
3667
  height: 40px !important;
@@ -3670,9 +3670,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3670
3670
  background-color: ${e=>e.theme.colors.cta.background};
3671
3671
  color: ${e=>e.theme.colors.cta.font};
3672
3672
  border: none;
3673
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
3673
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
3674
3674
  font-size: 14px;
3675
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
3675
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
3676
3676
  cursor: pointer;
3677
3677
  transition: all 0.3s ease;
3678
3678
  justify-content: center;
@@ -3732,11 +3732,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3732
3732
  opacity: 0;
3733
3733
  z-index: 1;
3734
3734
  bottom: 0;
3735
- `,z0e=({botId:e})=>{var ce,Me;const{uiData:t,storeMetaData:n,onSendMessage:r,isKlaviyoMessage:o,isLoading:a,lastedBotmessageId:l,setLastedBotmessageId:d,messages:h,isMessageLoading:p,setIsMessageLoading:y,setMessages:m,saveConversation:x,loadConversation:_,suggestedQuestions:w,showUserInfoModel:k,setShowUserInfoModel:A,isUserInfoNeeded:E,setPendingQuestion:R}=qd(),{cart:O,addToCart:I,generateCartUrl:L,addCartAttributes:N}=Fd(),H=Qc("use-chatbot-icon-size"),V=hf.detect(),W=t==null?void 0:t.isLeft,z=xk(),Q=t==null?void 0:t.heightOption,J=Z.useRef(0),ee=Qc("new-suggested-question-design"),[de,ue]=Z.useState(!1),[se,pe]=Z.useState(!1),[Ce,B]=Z.useState(!1),[P,ne]=Z.useState([]),[U,fe]=Z.useState(0),[Ae,Te]=Z.useState(!1),[rt,Ge]=Z.useState(!1),We=Ql("acquisition_agent"),[Tt,It]=Z.useState(window.location.pathname),nt=Z.useCallback(async()=>{try{if(!We||(t==null?void 0:t.show_bot)===!1)return;const j=await fetch(`${Ti}/api/wordpress/acquisition`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,timestamp:new Date().toISOString(),page_information:window.location.href.split("?")[0],botid:e})});if(j.ok){const te=await j.json(),he=window.location.pathname,ke=3;ne(we=>{const Je=[...we],$t={question:te.Popup_Message,answer:"",path:he,nameSpace:e,type:"dynamic",Follow_up_Question:te.Follow_up_Question};return Je.length>=ke&&Je.shift(),Je.push($t),console.log("updated questions in ChatbotComponent1",Je),Je})}else console.error("Failed to fetch new acquisition question")}catch(j){console.error("Error fetching new acquisition question:",j)}},[e,We,t==null?void 0:t.show_bot]);Z.useEffect(()=>{const j=()=>{const ke=window.location.pathname;ke!==Tt&&(It(ke),nt())};window.addEventListener("popstate",j);const te=history.pushState,he=history.replaceState;return history.pushState=function(...ke){te.apply(this,ke),j()},history.replaceState=function(...ke){he.apply(this,ke),j()},()=>{window.removeEventListener("popstate",j),history.pushState=te,history.replaceState=he}},[Tt,nt]),Z.useEffect(()=>{const j=dn=>{if(typeof window<"u"&&typeof document<"u"&&document.documentElement){const gr=document.documentElement.scrollHeight,$r=document.documentElement.clientHeight,hi=window.scrollY,ai=gr-$r;return ai<=0?dn:hi/ai*100>50?0:dn}return dn};if(ee&&!Ae&&(J.current=j(ee.showing_delay||2e3)),!ee||Ae||P.length===0)return;let te,he,ke,we;const Je=ee.showing_delay||2e3,$t=ee.showing_delay||2e3,an=ee.show_for||4e3,un=ee.hide_timing||4e3,Un=async()=>{if(P.length===0||!P[U]){we=setTimeout(()=>{P.length>0&&fe(dn=>dn%P.length)},un+500);return}te=setTimeout(()=>{Ae||(ue(!0),he=setTimeout(async()=>{Ae||(pe(!0),B(!0),ke=setTimeout(async()=>{Ae||(B(!1),pe(!1),ue(!1),fe(dn=>(dn+1)%P.length),we=setTimeout(()=>{Un()},un))},an))},$t))},J.current)};return P.length===0&&e?nt().then(()=>{if(!Ae&&P.length>0){fe(0);const dn=j(Je);J.current=dn,Un()}}):!Ae&&P.length>0&&Un(),()=>{clearTimeout(te),clearTimeout(he),clearTimeout(ke),clearTimeout(we)}},[ee,Ae,nt,P,U,e]);const[dt,bt]=Z.useState(!1);Z.useEffect(()=>{const j=()=>{bt(window.matchMedia("(max-width: 768px)").matches)};return j(),window.addEventListener("resize",j),()=>window.removeEventListener("resize",j)},[]);const[Et,Nt]=Z.useState(""),[yt,re]=Z.useState(""),[,le]=Z.useState(0);Z.useEffect(()=>{e&&gk(e)},[e]),Z.useEffect(()=>{mE(e)},[e]),Z.useEffect(()=>{let j=jo();if(!j&&window.Thinkific){const te=window.Thinkific.current_user;te&&(j={name:te.full_name,email:te.email},sf(j))}Xu.init({projectName:e,debug:!1,testing:Cx}),j&&j.email&&(window.DebalesChat.identify(j.email,{name:j.name,phone:j.phone,email:j.email}),t!=null&&t.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:j.email,first_name:j.name,phone:j.phone,from:"Debales-Chatbot"}))},[e,t==null?void 0:t.KlaviyoIntegration]);const ve=Z.useRef(null),Ee=Qn(On.CLICKED_QUESTIONS,{botId:e}),[$e,Ve]=Z.useState(()=>{try{const j=sessionStorage.getItem(Ee);return j?new Set(JSON.parse(j)):new Set}catch{return new Set}});Z.useEffect(()=>{try{sessionStorage.setItem(Ee,JSON.stringify(Array.from($e)))}catch(j){console.error("Failed to save to sessionStorage:",j)}},[$e]);const lt=Z.useCallback((j,te)=>{j?(window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:j,source:te,projectId:e}})),setTimeout(()=>{Ge(!0)},50)):(Ge(!1),window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:j,source:te,projectId:e}})))},[]),[mt,_e]=Vm(On.SHOW_CART_SUMMARY,!0);Z.useEffect(()=>{const j=te=>{Te(te.detail.isOpen),te.detail.isOpen&&setTimeout(()=>Ge(!0),50),window.DebalesChat.isOpen=te.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:te.detail.isOpen,source:te.detail.source})};return window.addEventListener(Qr.OPEN_STATE_CHANGE,j),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,j)}},[]),Z.useEffect(()=>{const j=te=>{Te(te.detail.isOpen),window.DebalesChat.isOpen=te.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:te.detail.isOpen})};return window.addEventListener(Qr.OPEN_STATE_CHANGE,j),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,j)}},[]);const[Re,Ct]=Z.useState(()=>{const j=Qn(On.PENDING_BULK_ITEMS,{botId:e}),te=sessionStorage.getItem(j);return te?JSON.parse(te):[]});Z.useEffect(()=>{const j=Qn(On.PENDING_BULK_ITEMS,{botId:e});sessionStorage.setItem(j,JSON.stringify(Re))},[Re,e]);const[ct,Rt]=Z.useState(!1),[Mt,en]=Z.useState({name:"",email:"",message:""}),[Qt,gn]=Z.useState([]),[pt,Kt]=Z.useState({name:"",email:"",message:""}),_t=Ql("exit_model"),[Y,xe]=Z.useState({text:!0,leadingQueries:!0,collections:!0,products:!0,variants:!0,cartSummary:!0,bulkItems:!0}),[it,st]=Z.useState({suggestions:!1,products:!1,collections:!1,leadingQueries:!1,initialMessage:!1,cartSummary:!1,bulkItems:!1});Z.useEffect(()=>{if(h.length===1&&!k){st(te=>({...te,leadingQueries:!0}));const j=setTimeout(()=>{st(te=>({...te,leadingQueries:!1}))},2e3);return()=>clearTimeout(j)}},[h,k]);const[St,Pt]=Z.useState(!1),[Ht,Yt]=Z.useState(!0),[qt,ln]=Z.useState(!1),[hr,xr]=Z.useState(!1),[Ur,nn]=Z.useState(!1),[yn,fn]=Z.useState(!1),ho=500,br=Z.useCallback(()=>{const j=ve.current;if(!j){nn(!1),fn(!1),Yt(!0);return}if(Ie(e)){nn(!1);return}const te=j.scrollTop,he=j.scrollHeight,ke=j.clientHeight,we=he>ke,Je=1,$t=te<=Je,an=te+ke>=he-Je;we?(nn(!$t),fn(!an),Yt(an)):(nn(!1),fn(!1),Yt(!0))},[ve,nn,fn,Yt]);Z.useEffect(()=>{const j=ve.current;if(Ae&&j){br(),j.addEventListener("scroll",br);const te=new ResizeObserver(br);return te.observe(j),()=>{j.removeEventListener("scroll",br),te.unobserve(j)}}else Ae||(nn(!1),fn(!1),Yt(!0))},[Ae,h,St,br]),Z.useEffect(()=>{var j,te,he,ke,we,Je;if(h.length>0&&!p){const $t=h[h.length-1],an=sessionStorage.getItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e})),un=$t.isBot&&$t.conversationId===l&&$t.conversationId!==an,Un=(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0&&$t.conversationId===l;if(un){Pt(!0),sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),$t.conversationId||""),xe({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1});const dn=2e3;let gr=dn;const $r=[{type:"collections",condition:((j=$t.collections)==null?void 0:j.length)&&((te=$t.collections)==null?void 0:te.length)>0},{type:"products",condition:((he=$t.products)==null?void 0:he.length)&&((ke=$t.products)==null?void 0:ke.length)>0},{type:"leadingQueries",condition:((we=$t.leading_queries)==null?void 0:we.length)&&((Je=$t.leading_queries)==null?void 0:Je.length)>0},{type:"cartSummary",condition:(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0},{type:"bulkItems",condition:(Re==null?void 0:Re.length)>0}].filter(hi=>hi.condition);if($r.length===0){Pt(!1);return}$r.forEach(({type:hi},ai)=>{setTimeout(()=>{if(xe(go=>({...go,[hi]:!0})),Ht&&ve.current){const go=ve.current;go.scrollHeight-go.scrollTop<=go.clientHeight&&La(ve)}ai===$r.length-1&&Pt(!1)},gr),gr+=dn})}else Un&&xe(dn=>({...dn,cartSummary:!0}))}},[h,p,l,O==null?void 0:O.itemCount,Re==null?void 0:Re.length,Ht,e]),Z.useEffect(()=>{if(!o&&h.length>0){const j=ve.current;j&&Ht&&j.scrollHeight-j.scrollTop<=j.clientHeight+100&&setTimeout(()=>La(ve),100)}},[h.length,o,Ht]),Z.useEffect(()=>{const j=document.querySelector('meta[name="viewport"]'),te=j==null?void 0:j.content;if(Ae){let he=j;const ke=window.matchMedia("(max-width: 768px)").matches;he?he.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no":(he=document.createElement("meta"),he.name="viewport",he.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no",document.head.appendChild(he)),ke&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="hidden");const we=he;return()=>{te&&we&&(we.content=te),ke&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}}return()=>{window.matchMedia("(max-width: 768px)").matches&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}},[Ae,t==null?void 0:t.mobileDisplayMode]),Z.useEffect(()=>{if(Ae&&h.length>0&&!o){const j=setTimeout(()=>{ve.current&&La(ve)},150);return()=>clearTimeout(j)}},[Ae,h.length,o]),Z.useEffect(()=>{O!=null&&O.itemCount&&O.itemCount===0&&!o&&setTimeout(()=>La(ve),100)},[O==null?void 0:O.itemCount,o]),Z.useEffect(()=>{l&&sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),l)},[l,e]);const[us,ji]=Z.useState(!1),[Ho,Dt]=Z.useState(!1),[to,rr]=Z.useState(null),Ro=async j=>{const te=nr();if(Ge(!1),j&&h.length>1)try{(await fetch(`${Ti}/api/wordpress/userRating`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sessionId:te,userRating:j,nameSpace:e})})).ok||console.error("Error submitting rating")}catch(he){console.error("Error submitting rating:",he)}setTimeout(()=>{Dt(!1),lt(!1,"close_button_clicked")},1e3)},po=j=>{y(!0),Re.forEach(he=>{I(he.id,he.quantity)}),_e(!0),window.DebalesChat.track(tn.ADD_BULK_ITEM,{products:Re,message:j});const te=[...h,{text:"πŸŽ‰ Bulk items added to cart successfully.",leading_queries:["Get GST Invoice for the order","Explore more products"],conversationId:j,isBot:!0}];m(te),x(te),d(j),Ct([]),y(!1)},qn=()=>{var j;switch(e){case"minature":case"bodytales":case"imemyselfcare-com":if(window.triggerGokwikCustomCheckout)return window.triggerGokwikCustomCheckout(),!0;break;case"athflex":if((j=window.shiprocketCheckoutEvents)!=null&&j.buyCart)return window.shiprocketCheckoutEvents.buyCart(),!0;break;case"www":if(window.openRzpCheckout)return window.openRzpCheckout(),!0;break;default:return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1}return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1},ua=async j=>{j.preventDefault(),window.DebalesChat.track(tn.CHECKOUT_CLICKED,{chatId:nr()+e,cartValue:Number(O==null?void 0:O.total),cart:O}),N({dbls_method:"checkout_clicked"}),qn()&&lt(!1,"checkout_clicked")};Z.useEffect(()=>{const j=gE(w);ne(te=>[...j.filter(ke=>!te.some(we=>we.question===ke.question))])},[w]),Z.useEffect(()=>{const j=ke=>{const we=ke.detail.formId;switch(ke.detail.type){case"open":case"embedOpen":setTimeout(()=>{const $t=te(we);$t&&Nt($t)},800);break;case"close":Et&&(t==null?void 0:t.KlaviyoFormIntegration)===!0&&setTimeout(()=>{lt(!0,"klaviyo_form_closed"),re(we),r({message:Et,fromKlaviyo:!0})},1e4);break}},te=ke=>{const we=document.querySelector(`[data-testid="klaviyo-form-${ke}"]`);if(console.log(`formElement text ${ke} =>`,we==null?void 0:we.innerText,we==null?void 0:we.textContent),we instanceof HTMLElement){const Je=we.innerText||we.textContent;if(Je)return console.log("Found form text:",Je),`=> Klaviyo form content:
3735
+ `,z0e=({botId:e})=>{var ce,Ie;const{uiData:t,storeMetaData:n,onSendMessage:r,isKlaviyoMessage:o,isLoading:a,lastedBotmessageId:l,setLastedBotmessageId:d,messages:h,isMessageLoading:p,setIsMessageLoading:y,setMessages:m,saveConversation:x,loadConversation:_,suggestedQuestions:w,showUserInfoModel:k,setShowUserInfoModel:A,isUserInfoNeeded:E,setPendingQuestion:R}=qd(),{cart:O,addToCart:I,generateCartUrl:L,addCartAttributes:N}=Fd(),H=Qc("use-chatbot-icon-size"),V=hf.detect(),W=t==null?void 0:t.isLeft,z=xk(),Q=t==null?void 0:t.heightOption,J=Z.useRef(0),ee=Qc("new-suggested-question-design"),[de,ue]=Z.useState(!1),[se,pe]=Z.useState(!1),[Ce,B]=Z.useState(!1),[P,ne]=Z.useState([]),[U,fe]=Z.useState(0),[Ae,Te]=Z.useState(!1),[rt,Ge]=Z.useState(!1),We=Ql("acquisition_agent"),[Tt,It]=Z.useState(window.location.pathname),nt=Z.useCallback(async()=>{try{if(!We||(t==null?void 0:t.show_bot)===!1)return;const j=await fetch(`${Ti}/api/wordpress/acquisition`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,timestamp:new Date().toISOString(),page_information:window.location.href.split("?")[0],botid:e})});if(j.ok){const te=await j.json(),he=window.location.pathname,ke=3;ne(we=>{const Je=[...we],$t={question:te.Popup_Message,answer:"",path:he,nameSpace:e,type:"dynamic",Follow_up_Question:te.Follow_up_Question};return Je.length>=ke&&Je.shift(),Je.push($t),console.log("updated questions in ChatbotComponent1",Je),Je})}else console.error("Failed to fetch new acquisition question")}catch(j){console.error("Error fetching new acquisition question:",j)}},[e,We,t==null?void 0:t.show_bot]);Z.useEffect(()=>{const j=()=>{const ke=window.location.pathname;ke!==Tt&&(It(ke),nt())};window.addEventListener("popstate",j);const te=history.pushState,he=history.replaceState;return history.pushState=function(...ke){te.apply(this,ke),j()},history.replaceState=function(...ke){he.apply(this,ke),j()},()=>{window.removeEventListener("popstate",j),history.pushState=te,history.replaceState=he}},[Tt,nt]),Z.useEffect(()=>{const j=dn=>{if(typeof window<"u"&&typeof document<"u"&&document.documentElement){const gr=document.documentElement.scrollHeight,$r=document.documentElement.clientHeight,hi=window.scrollY,ai=gr-$r;return ai<=0?dn:hi/ai*100>50?0:dn}return dn};if(ee&&!Ae&&(J.current=j(ee.showing_delay||2e3)),!ee||Ae||P.length===0)return;let te,he,ke,we;const Je=ee.showing_delay||2e3,$t=ee.showing_delay||2e3,an=ee.show_for||4e3,un=ee.hide_timing||4e3,Un=async()=>{if(P.length===0||!P[U]){we=setTimeout(()=>{P.length>0&&fe(dn=>dn%P.length)},un+500);return}te=setTimeout(()=>{Ae||(ue(!0),he=setTimeout(async()=>{Ae||(pe(!0),B(!0),ke=setTimeout(async()=>{Ae||(B(!1),pe(!1),ue(!1),fe(dn=>(dn+1)%P.length),we=setTimeout(()=>{Un()},un))},an))},$t))},J.current)};return P.length===0&&e?nt().then(()=>{if(!Ae&&P.length>0){fe(0);const dn=j(Je);J.current=dn,Un()}}):!Ae&&P.length>0&&Un(),()=>{clearTimeout(te),clearTimeout(he),clearTimeout(ke),clearTimeout(we)}},[ee,Ae,nt,P,U,e]);const[dt,bt]=Z.useState(!1);Z.useEffect(()=>{const j=()=>{bt(window.matchMedia("(max-width: 768px)").matches)};return j(),window.addEventListener("resize",j),()=>window.removeEventListener("resize",j)},[]);const[Et,Nt]=Z.useState(""),[yt,re]=Z.useState(""),[,le]=Z.useState(0);Z.useEffect(()=>{e&&gk(e)},[e]),Z.useEffect(()=>{mE(e)},[e]),Z.useEffect(()=>{let j=jo();if(!j&&window.Thinkific){const te=window.Thinkific.current_user;te&&(j={name:te.full_name,email:te.email},sf(j))}Xu.init({projectName:e,debug:!1,testing:Cx}),j&&j.email&&(window.DebalesChat.identify(j.email,{name:j.name,phone:j.phone,email:j.email}),t!=null&&t.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:j.email,first_name:j.name,phone:j.phone,from:"Debales-Chatbot"}))},[e,t==null?void 0:t.KlaviyoIntegration]);const ve=Z.useRef(null),Ee=Qn(On.CLICKED_QUESTIONS,{botId:e}),[$e,Ve]=Z.useState(()=>{try{const j=sessionStorage.getItem(Ee);return j?new Set(JSON.parse(j)):new Set}catch{return new Set}});Z.useEffect(()=>{try{sessionStorage.setItem(Ee,JSON.stringify(Array.from($e)))}catch(j){console.error("Failed to save to sessionStorage:",j)}},[$e]);const lt=Z.useCallback((j,te)=>{j?(window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:j,source:te,projectId:e}})),setTimeout(()=>{Ge(!0)},50)):(Ge(!1),window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:j,source:te,projectId:e}})))},[]),[mt,_e]=Vm(On.SHOW_CART_SUMMARY,!0);Z.useEffect(()=>{const j=te=>{Te(te.detail.isOpen),te.detail.isOpen&&setTimeout(()=>Ge(!0),50),window.DebalesChat.isOpen=te.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:te.detail.isOpen,source:te.detail.source})};return window.addEventListener(Qr.OPEN_STATE_CHANGE,j),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,j)}},[]),Z.useEffect(()=>{const j=te=>{Te(te.detail.isOpen),window.DebalesChat.isOpen=te.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:te.detail.isOpen})};return window.addEventListener(Qr.OPEN_STATE_CHANGE,j),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,j)}},[]);const[Re,Ct]=Z.useState(()=>{const j=Qn(On.PENDING_BULK_ITEMS,{botId:e}),te=sessionStorage.getItem(j);return te?JSON.parse(te):[]});Z.useEffect(()=>{const j=Qn(On.PENDING_BULK_ITEMS,{botId:e});sessionStorage.setItem(j,JSON.stringify(Re))},[Re,e]);const[ct,Rt]=Z.useState(!1),[Mt,en]=Z.useState({name:"",email:"",message:""}),[Qt,gn]=Z.useState([]),[pt,Kt]=Z.useState({name:"",email:"",message:""}),_t=Ql("exit_model"),[Y,xe]=Z.useState({text:!0,leadingQueries:!0,collections:!0,products:!0,variants:!0,cartSummary:!0,bulkItems:!0}),[it,st]=Z.useState({suggestions:!1,products:!1,collections:!1,leadingQueries:!1,initialMessage:!1,cartSummary:!1,bulkItems:!1});Z.useEffect(()=>{if(h.length===1&&!k){st(te=>({...te,leadingQueries:!0}));const j=setTimeout(()=>{st(te=>({...te,leadingQueries:!1}))},2e3);return()=>clearTimeout(j)}},[h,k]);const[St,Pt]=Z.useState(!1),[Ht,Yt]=Z.useState(!0),[qt,ln]=Z.useState(!1),[hr,xr]=Z.useState(!1),[Ur,nn]=Z.useState(!1),[yn,fn]=Z.useState(!1),ho=500,br=Z.useCallback(()=>{const j=ve.current;if(!j){nn(!1),fn(!1),Yt(!0);return}if(Me(e)){nn(!1);return}const te=j.scrollTop,he=j.scrollHeight,ke=j.clientHeight,we=he>ke,Je=1,$t=te<=Je,an=te+ke>=he-Je;we?(nn(!$t),fn(!an),Yt(an)):(nn(!1),fn(!1),Yt(!0))},[ve,nn,fn,Yt]);Z.useEffect(()=>{const j=ve.current;if(Ae&&j){br(),j.addEventListener("scroll",br);const te=new ResizeObserver(br);return te.observe(j),()=>{j.removeEventListener("scroll",br),te.unobserve(j)}}else Ae||(nn(!1),fn(!1),Yt(!0))},[Ae,h,St,br]),Z.useEffect(()=>{var j,te,he,ke,we,Je;if(h.length>0&&!p){const $t=h[h.length-1],an=sessionStorage.getItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e})),un=$t.isBot&&$t.conversationId===l&&$t.conversationId!==an,Un=(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0&&$t.conversationId===l;if(un){Pt(!0),sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),$t.conversationId||""),xe({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1});const dn=2e3;let gr=dn;const $r=[{type:"collections",condition:((j=$t.collections)==null?void 0:j.length)&&((te=$t.collections)==null?void 0:te.length)>0},{type:"products",condition:((he=$t.products)==null?void 0:he.length)&&((ke=$t.products)==null?void 0:ke.length)>0},{type:"leadingQueries",condition:((we=$t.leading_queries)==null?void 0:we.length)&&((Je=$t.leading_queries)==null?void 0:Je.length)>0},{type:"cartSummary",condition:(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0},{type:"bulkItems",condition:(Re==null?void 0:Re.length)>0}].filter(hi=>hi.condition);if($r.length===0){Pt(!1);return}$r.forEach(({type:hi},ai)=>{setTimeout(()=>{if(xe(go=>({...go,[hi]:!0})),Ht&&ve.current){const go=ve.current;go.scrollHeight-go.scrollTop<=go.clientHeight&&La(ve)}ai===$r.length-1&&Pt(!1)},gr),gr+=dn})}else Un&&xe(dn=>({...dn,cartSummary:!0}))}},[h,p,l,O==null?void 0:O.itemCount,Re==null?void 0:Re.length,Ht,e]),Z.useEffect(()=>{if(!o&&h.length>0){const j=ve.current;j&&Ht&&j.scrollHeight-j.scrollTop<=j.clientHeight+100&&setTimeout(()=>La(ve),100)}},[h.length,o,Ht]),Z.useEffect(()=>{const j=document.querySelector('meta[name="viewport"]'),te=j==null?void 0:j.content;if(Ae){let he=j;const ke=window.matchMedia("(max-width: 768px)").matches;he?he.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no":(he=document.createElement("meta"),he.name="viewport",he.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no",document.head.appendChild(he)),ke&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="hidden");const we=he;return()=>{te&&we&&(we.content=te),ke&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}}return()=>{window.matchMedia("(max-width: 768px)").matches&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}},[Ae,t==null?void 0:t.mobileDisplayMode]),Z.useEffect(()=>{if(Ae&&h.length>0&&!o){const j=setTimeout(()=>{ve.current&&La(ve)},150);return()=>clearTimeout(j)}},[Ae,h.length,o]),Z.useEffect(()=>{O!=null&&O.total&&!o&&setTimeout(()=>La(ve),100)},[O==null?void 0:O.total,o]),Z.useEffect(()=>{l&&sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),l)},[l,e]);const[us,ji]=Z.useState(!1),[Ho,Dt]=Z.useState(!1),[to,rr]=Z.useState(null),Ro=async j=>{const te=nr();if(Ge(!1),j&&h.length>1)try{(await fetch(`${Ti}/api/wordpress/userRating`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sessionId:te,userRating:j,nameSpace:e})})).ok||console.error("Error submitting rating")}catch(he){console.error("Error submitting rating:",he)}setTimeout(()=>{Dt(!1),lt(!1,"close_button_clicked")},1e3)},po=j=>{y(!0),Re.forEach(he=>{I(he.id,he.quantity)}),_e(!0),window.DebalesChat.track(tn.ADD_BULK_ITEM,{products:Re,message:j});const te=[...h,{text:"πŸŽ‰ Bulk items added to cart successfully.",leading_queries:["Get GST Invoice for the order","Explore more products"],conversationId:j,isBot:!0}];m(te),x(te),d(j),Ct([]),y(!1)},qn=()=>{var j;switch(e){case"minature":case"bodytales":case"imemyselfcare-com":if(window.triggerGokwikCustomCheckout)return window.triggerGokwikCustomCheckout(),!0;break;case"athflex":if((j=window.shiprocketCheckoutEvents)!=null&&j.buyCart)return window.shiprocketCheckoutEvents.buyCart(),!0;break;case"www":if(window.openRzpCheckout)return window.openRzpCheckout(),!0;break;default:return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1}return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1},ua=async j=>{j.preventDefault(),window.DebalesChat.track(tn.CHECKOUT_CLICKED,{chatId:nr()+e,cartValue:Number(O==null?void 0:O.total),cart:O}),N({dbls_method:"checkout_clicked"}),qn()&&lt(!1,"checkout_clicked")};Z.useEffect(()=>{const j=gE(w);ne(te=>[...j.filter(ke=>!te.some(we=>we.question===ke.question))])},[w]),Z.useEffect(()=>{const j=ke=>{const we=ke.detail.formId;switch(ke.detail.type){case"open":case"embedOpen":setTimeout(()=>{const $t=te(we);$t&&Nt($t)},800);break;case"close":Et&&(t==null?void 0:t.KlaviyoFormIntegration)===!0&&setTimeout(()=>{lt(!0,"klaviyo_form_closed"),re(we),r({message:Et,fromKlaviyo:!0})},1e4);break}},te=ke=>{const we=document.querySelector(`[data-testid="klaviyo-form-${ke}"]`);if(console.log(`formElement text ${ke} =>`,we==null?void 0:we.innerText,we==null?void 0:we.textContent),we instanceof HTMLElement){const Je=we.innerText||we.textContent;if(Je)return console.log("Found form text:",Je),`=> Klaviyo form content:
3736
3736
 
3737
3737
  `+Je+`
3738
3738
 
3739
- => User Action: Klaviyo form closed`}return""},he=ke=>{ke instanceof CustomEvent&&j(ke)};return window.addEventListener("klaviyoForms",he),()=>{window.removeEventListener("klaviyoForms",he)}},[Et,t,r]),Z.useEffect(()=>{const j=ve.current;return Ae&&j?(j.addEventListener("scroll",br),()=>{j&&j.removeEventListener("scroll",br)}):()=>{}},[Ae,br]);const[Oi,pr]=Z.useState(!1),Br=Q==="Highest"?"120px":Q==="Higher"?"60px":"15px",ca=async()=>{try{const j=await fetch(`${Ti}/api/wordpress/support`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatid:nr()+e,nameSpace:e,userName:Mt.name,userEmail:Mt.email,userMessage:Mt.message,tag:"support"})});if(j.ok){const te=`support-confirm-${Date.now()}`;m(he=>[...he,{text:"Thanks for reaching out! Our support team has received your request and will get back to you within 24 hours.<br>In the meantime, feel free to continue chatting with me - I'll do my best to help!",isBot:!0,leading_queries:Qt,conversationId:te}]),d(te),xe(he=>({...he,leadingQueries:!0})),gn([]),console.log("Connected to support with existing user info:",jo())}else{const te=await j.json();console.error("Failed to connect to support:",te),m(he=>[...he,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}}catch{m(te=>[...te,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}},Kr=()=>{if(Ie(e)){const ke=Fp("https://test.thecollective.in/content/customersupport");ke.isValid&&(t!=null&&t.shopifyShopDomain&&(ke.url.hostname=t==null?void 0:t.shopifyShopDomain),window.open(Os(ke.url.toString()),"_blank"));return}const j=jo();let te=[];const he=h[h.length-1];he!=null&&he.leading_queries&&he.leading_queries.length>0?te=he.leading_queries:h.length<=1&&(te=P.flatMap(ke=>Array.isArray(ke)?ke.map(we=>we.question):[ke.question]).slice(0,4)),gn(te),j&&j.name&&j.email&&en({name:j==null?void 0:j.name,email:j==null?void 0:j.email,message:""}),m(ke=>[...ke,{text:"Please provide your name, email and message to connect with support.",isBot:!0}]),Rt(!0)},ot=async j=>{j.preventDefault();const te={name:"",email:"",message:""};let he=!0;const ke=Mt.name.trim(),we=Mt.message.trim();ke||(te.name="Name cannot be empty or just whitespace.",he=!1),(!Mt.email||!zm.isEmail(Mt.email))&&(te.email="Please enter a valid email address.",he=!1),we||(te.message="Message cannot be empty or just whitespace.",he=!1),Kt(te),he&&(sf({name:ke,email:Mt.email}),Rt(!1),m(Je=>Je.slice(0,-1)),await ca())},[Oe,at]=Z.useState({});return Z.useEffect(()=>{hr&&(h.forEach((j,te)=>{if(!j.isBot)return;const he=$p(j.text);if(!(te in Oe)||Oe[te]<he.length){let ke;const we=Je=>{Je<he.length&&(ke=setTimeout(()=>{at($t=>({...$t,[te]:Je+1})),we(Je+1)},ho))};return te in Oe?we(Oe[te]):(at(Je=>({...Je,[te]:1})),we(1)),()=>clearTimeout(ke)}}),at(j=>{const te={};return h.forEach((he,ke)=>{j[ke]!==void 0&&(te[ke]=j[ke])}),te}))},[h,hr]),!t||t.show_bot===!1||a?null:M.jsxs(Jw,{theme:pE(t,e),children:[M.jsx("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),M.jsx("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",rel:"stylesheet"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap",rel:"stylesheet"}),M.jsx(R0e,{}),M.jsxs(s0e,{$topOffset:Br,$isLeft:W,children:[!Ae&&P.length>0&&P[U]&&se&&M.jsx(k0e,{className:Ce?"visible":"",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Br,style:{display:"flex",flexDirection:W?"row":"row-reverse",alignItems:"center",marginLeft:dt?"60px":"85px",marginRight:dt?"60px":"85px",left:W?"24px":"auto",right:W?"auto":"24px",opacity:Ce?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length>0&&P[U]&&(()=>{const j=P[U];return M.jsx(T0e,{children:M.jsx(i0e,{messages:[{question:j.question,isHighlighted:j.isHighlighted??!1,show_for:(ee==null?void 0:ee.show_for)||4e3,hide_timing:(ee==null?void 0:ee.hide_timing)||4e3}],botId:e,uiData:t,onClose:()=>{Ve(te=>{const he=new Set(te);return he.add(j.question),he})},onClick:()=>{const te=j;lt(!0,"suggested_question_clicked"),Ve(he=>{const ke=new Set(he);return ke.add(te.question),ke}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:te}),E?(ln(!1),xr(!0),A(!0),R(te)):(ln(!1),xr(!0),r({message:te.Follow_up_Question??te.question,answer:te.answer,products:te.products,fromKlaviyo:!1,leading_queries:te.leading_queries,followUpQuestion:te.Follow_up_Question,messType:"suggested_question"}))}})},j.question)})()}),M.jsxs(l0e,{$topOffset:Br,$removeLogoBackground:t.removeLogoBackground,$isLeft:W,style:{display:Ae?"none":"inline-flex"},children:[M.jsx(u0e,{$showAnimation:t.enableChatButtonBackgroundAnimation??!1,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",$backgroundColor:t.backgroundColor||"#fff",$removeLogoBackground:t.removeLogoBackground,$topOffset:Br,$iconSize:H}),M.jsxs(c0e,{$backgroundColor:t.removeLogoBackground?"transparent":t.backgroundColor||"#fff",$botId:e,$isLeft:W,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Br,$showAnimation:t.enableChatButtonBackgroundAnimation,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",id:"debales-chat-button","data-testid":"debales-chat-button",onClick:()=>{if(window.DebalesChat.track(tn.CHAT_BUTTON_CLICKED),lt(!Ae,"chat_button_clicked"),!Ae){const j=_();j.length>0?(m(j),ln(!1),xr(!0)):(ln(!0),xr(!1),setTimeout(()=>{ln(!1),xr(!0);const te={text:(t==null?void 0:t.initialMessage)||"Hi, I am an AI chatbot, how can I help you today?",isBot:!0};m([te])},(ee==null?void 0:ee.showing_delay)||2e3))}},"aria-label":"Chat",style:{display:Ae?"none":"inline-flex"},children:[M.jsx(f0e,{$botId:e,$removeLogoBackground:t.removeLogoBackground,"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),(P==null?void 0:P.length)>0&&!Ae&&de&&M.jsx("div",{style:{position:"absolute",top:"-5px",right:"-5px",backgroundColor:"#f44336",color:"white",borderRadius:"50%",width:"20px",height:"20px",display:"flex",justifyContent:"center",alignItems:"center",fontSize:"12px",fontWeight:"bold",zIndex:2,opacity:de?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length})]})]})]}),Ae&&vw.createPortal(M.jsx(M.Fragment,{children:M.jsxs(g0e,{$backgroundColor:t.backgroundColor||"#fff",$fullScreenOnMobile:t.fullScreenOnMobile,$headerFontColor:t.headerFontColor||"#1C1C1C",$isLeft:W,$topOffset:Br,$mobileDisplayMode:t.mobileDisplayMode,$isVisible:rt,"data-testid":"debales-chat-container",children:[M.jsxs(y0e,{$backgroundColor:Ie(e)?t.backgroundColor:t.botBackgroundColor||"#fff",style:{color:t.headerFontColor},children:[M.jsx("div",{style:{flexGrow:.1,display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden",marginRight:"8px",gap:"10px"},children:Ie(e)?M.jsxs(M.Fragment,{children:[M.jsx(sH,{"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),Ie(e)?M.jsx("div",{children:M.jsx("img",{src:yk,alt:"Chat Bot Icon",style:{height:"36px"}})}):M.jsxs(d0e,{$botNameColor:t.headerFontColor,children:[M.jsxs("div",{style:{fontWeight:"700",wordBreak:"break-word"},children:[t.chatbotName,e==="catch-org-ai"&&M.jsx(p0e,{$backgroundColor:t.callToActionBackgroundColor,$fontColor:t.callToActionFontColor,children:"Beta"})]}),M.jsx(h0e,{})]})]}):M.jsx(m0e,{children:M.jsxs(v0e,{children:[M.jsx(sH,{src:t.bot_logo,alt:"Chat Bot Icon"}),M.jsx("span",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",display:"inline-block",maxWidth:"22ch"},children:t.chatbotName})]})})}),M.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"8px",marginLeft:"auto",flexShrink:0},children:[M.jsxs(O0e,{children:[M.jsx(lH,{$iconBG:t.backgroundColor,onClick:Kr,"aria-label":"Support","data-testid":"debales-support-button",children:M.jsx(Tk,{color:t.headerFontColor})}),M.jsx(hH,{children:"Click to chat with a Live Support Agent now."})]}),M.jsx(lH,{$iconBG:t.backgroundColor,onClick:()=>{_t?Dt(!0):lt(!1,"close_button_clicked")},id:"debales-minimize-button","data-testid":"debales-minimize-button","aria-label":"Minimize",children:M.jsx(Zm,{botNameColor:t.headerFontColor})})]}),M.jsx(N0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}})]}),M.jsxs(_0e,{$backgroundColor:t.botBackgroundColor||"#fff",$mobileDisplayMode:t.mobileDisplayMode,children:[Oi&&((Me=(ce=t.pluginConfig)==null?void 0:ce.collectedUserInfo)==null?void 0:Me.discount)&&M.jsx(Nk,{discount:t.pluginConfig.collectedUserInfo.discount,uiData:t,onClose:()=>{pr(!1),window.DebalesChat.track(tn.DISCOUNT_VIEWED,{discount:t.pluginConfig.collectedUserInfo.discount})}}),M.jsx(kk,{}),M.jsx(Pk,{uidata:t,product:to,showModel:us,setShowModel:ji,onVariantSelect:j=>{I(j.id,1),_e(!0),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:j.title,price:Number(j.price),link:`https://${t.shopifyShopDomain}/variants/${j.id}`,message:l,chatId:nr()+e})},botId:e}),Ho&&M.jsx(zk,{setShowExitModal:Dt,handleCloseChatbot:Ro,chatId:nr()+e}),M.jsxs(x0e,{id:"debales-conversation-group",$botBackgroundColor:t.botBackgroundColor||"#fff",ref:ve,$mobileDisplayMode:t.mobileDisplayMode,children:[M.jsx(B0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}}),M.jsxs(b0e,{children:[hr&&h.map((j,te)=>{const he=j.isBot,ke=$p(j.text);return j.hideConfirmation?null:M.jsxs(Z.Fragment,{children:[he&&M.jsxs(uH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff","data-testid":"debales-ai-message-container",children:[M.jsx("img",{src:he?t.bot_logo:t.userMessage_logo,alt:"Chat User Icon",style:{marginLeft:"8px"}}),M.jsxs(dH,{children:[ke.slice(0,Oe[te]||0).map((we,Je)=>M.jsx("div",{children:M.jsx(Ri,{isBot:he,children:M.jsx(bd,{remarkPlugins:[Mw,vE],children:we})})},Je)),j.collections&&l===j.conversationId&&Y.collections&&M.jsx(Lk,{message:j,botId:e,uidata:t,onSendMessage:r,loading:p}),j.products&&l===j.conversationId&&Y.products&&M.jsx(Uk,{message:j,botId:e,uidata:t,onSendMessage:r,loading:p,storeMetaData:n,platform:V,setShowVariantModel:ji,setSelectedProduct:rr,setCartVersion:le}),o&&M.jsx(j8,{children:M.jsx(Nx,{onClick:()=>{window._klOnsite&&(window._klOnsite.push(["openForm",yt]),lt(!1,"klaviyo_grab_deal_button"))},children:"πŸš€ Grab Deal Now!"})}),O&&O.itemCount>0&&l===j.conversationId&&Y.cartSummary&&mt&&M.jsx(Mk,{onCheckout:ua,onKeepShopping:()=>{_e(!1)}}),Re&&Re.length>0&&l===j.conversationId&&Y.bulkItems&&M.jsx(mk,{onClick:()=>po(j.conversationId),children:"Add Bulk Items to Cart"}),k&&h.indexOf(j)===h.length-1&&M.jsx(M.Fragment,{children:M.jsx(jk,{setShowModel:we=>{var $t,an;const Je=typeof we=="function"?we(k):we;A(Je),!Je&&((an=($t=t.pluginConfig)==null?void 0:$t.collectedUserInfo)!=null&&an.discount)&&pr(!0)},inChat:!0,showFormInstructions:!1})}),ct&&h.indexOf(j)===h.length-1&&M.jsxs(D0e,{onSubmit:ot,noValidate:!0,"data-testid":"debales-support-form",children:[Ie(e)?M.jsxs(M.Fragment,{children:[M.jsx(ru,{label:"Name",name:"name",type:"text",value:Mt.name,onChange:we=>en(Je=>({...Je,name:we.target.value})),required:!0,error:pt.name,isCollectiveBot:!0}),M.jsx(ru,{label:"Email",name:"email",type:"email",value:Mt.email,onChange:we=>en(Je=>({...Je,email:we.target.value})),required:!0,error:pt.email,isCollectiveBot:!0}),M.jsx(Fk,{label:"Message",name:"message",value:Mt.message,onChange:we=>en(Je=>({...Je,message:we.target.value})),required:!0,error:pt.message,rows:4,isCollectiveBot:!0})]}):M.jsxs(M.Fragment,{children:[M.jsxs(P8,{children:[M.jsxs(H8,{children:["Name",M.jsx("span",{children:"*"})]}),M.jsx(pH,{type:"text",required:!0,value:Mt.name,onChange:we=>en(Je=>({...Je,name:we.target.value})),placeholder:"John"}),pt.name&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.name})]}),M.jsxs(P8,{children:[M.jsxs(H8,{children:["Email",M.jsx("span",{children:"*"})]}),M.jsx(pH,{type:"email",required:!0,value:Mt.email,onChange:we=>en(Je=>({...Je,email:we.target.value})),placeholder:"olivia@untitledui.com"}),pt.email&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.email})]}),M.jsxs(P8,{children:[M.jsxs(H8,{children:["Message",M.jsx("span",{children:"*"})]}),M.jsx(M0e,{required:!0,value:Mt.message,onChange:we=>en(Je=>({...Je,message:we.target.value})),placeholder:"I need help with..."}),pt.message&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.message})]})]}),M.jsx($0e,{children:M.jsx(I0e,{type:"submit",children:"Submit"})})]}),St&&!p&&l===j.conversationId&&M.jsx(Ri,{isBot:he,children:M.jsx(Ds,{loading:St})})]})]}),!he&&M.jsx(E0e,{$fontColor:t.userFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:M.jsx(Ri,{isBot:!!he,children:M.jsx(bd,{children:j.text})})}),h.length==1&&te==0&&!k&&M.jsx(j8,{children:it.leadingQueries?M.jsx(Ri,{isBot:!0,children:M.jsx(Ds,{loading:it.leadingQueries})}):P.map((we,Je)=>M.jsxs(fH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor,opacity:$e.has(we.question)?.5:1},onClick:()=>{E?(A(!0),R({question:we.question,answer:we.answer,products:we.products,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:we.question,answer:we.answer,products:we.products,leading_queries:we.leading_queries,followUpQuestion:we.Follow_up_Question,messType:"leading_query"}),Ve($t=>{const an=new Set($t);return an.add(we.question),an}),window.DebalesChat.track(tn.INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED,{question:we.question})},disabled:p,$disabled:p,children:[we.question,M.jsx(cH,{color:t.callToActionFontColor})]},Je))}),j.leading_queries&&j.leading_queries.length>0&&l===j.conversationId&&Y.leadingQueries&&!o&&!k&&M.jsx(j8,{children:j.leading_queries.map((we,Je)=>M.jsxs(fH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{E?(A(!0),R({question:we,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:we,messType:"leading_query"}),window.DebalesChat.track(tn.LEADING_QUERY_CLICKED,{query:we})},disabled:p,$disabled:p,children:[we,M.jsx(cH,{color:t.callToActionFontColor})]},Je))})]},te)}),(p||qt)&&M.jsxs(uH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:[M.jsx("img",{src:t.bot_logo,alt:"Chat User Icon"}),M.jsx(dH,{children:M.jsx(Ri,{isBot:!0,children:M.jsx("div",{style:{display:"flex",alignItems:"center",gap:"4px",animation:"fadeIn 0.3s ease-in-out"},children:M.jsx(Ds,{loading:p||qt})})})})]})]}),M.jsx(L0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:yn?1:0}})]}),M.jsxs("div",{className:"debales-footer-container",style:{width:"100%",backgroundColor:t.botBackgroundColor||"#fff",color:t.fontColor||"#000"},children:[(e==="catch-org-ai"||e==="letsgo-catch")&&M.jsx(C0e,{children:M.jsx("span",{children:`"${t.chatbotName}" can make mistakes.`})}),M.jsx("div",{children:M.jsx(Hk,{disabled:p,inputState:!1})}),(t.debales_branding??!0)&&M.jsxs(S0e,{href:"https://debales.ai/?open=true",target:"_blank",title:"debales-link",style:{color:t.fontColor?t.fontColor:"fff",marginTop:e==="catch-org-ai"?"0":"9px"},children:[M.jsx("p",{children:"Powered by"}),M.jsxs(w0e,{children:[M.jsx("img",{src:`${Ti}/images/debales_logo_d.png`,alt:"Debales logo"}),M.jsx("p",{children:"DEBALES"})]})]})]})]})]})}),z.shadowRoot)]})},F0e=ae.p`
3739
+ => User Action: Klaviyo form closed`}return""},he=ke=>{ke instanceof CustomEvent&&j(ke)};return window.addEventListener("klaviyoForms",he),()=>{window.removeEventListener("klaviyoForms",he)}},[Et,t,r]),Z.useEffect(()=>{const j=ve.current;return Ae&&j?(j.addEventListener("scroll",br),()=>{j&&j.removeEventListener("scroll",br)}):()=>{}},[Ae,br]);const[Oi,pr]=Z.useState(!1),Br=Q==="Highest"?"120px":Q==="Higher"?"60px":"15px",ca=async()=>{try{const j=await fetch(`${Ti}/api/wordpress/support`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatid:nr()+e,nameSpace:e,userName:Mt.name,userEmail:Mt.email,userMessage:Mt.message,tag:"support"})});if(j.ok){const te=`support-confirm-${Date.now()}`;m(he=>[...he,{text:"Thanks for reaching out! Our support team has received your request and will get back to you within 24 hours.<br>In the meantime, feel free to continue chatting with me - I'll do my best to help!",isBot:!0,leading_queries:Qt,conversationId:te}]),d(te),xe(he=>({...he,leadingQueries:!0})),gn([]),console.log("Connected to support with existing user info:",jo())}else{const te=await j.json();console.error("Failed to connect to support:",te),m(he=>[...he,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}}catch{m(te=>[...te,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}},Kr=()=>{if(Me(e)){const ke=Fp("https://test.thecollective.in/content/customersupport");ke.isValid&&(t!=null&&t.shopifyShopDomain&&(ke.url.hostname=t==null?void 0:t.shopifyShopDomain),window.open(Os(ke.url.toString()),"_blank"));return}const j=jo();let te=[];const he=h[h.length-1];he!=null&&he.leading_queries&&he.leading_queries.length>0?te=he.leading_queries:h.length<=1&&(te=P.flatMap(ke=>Array.isArray(ke)?ke.map(we=>we.question):[ke.question]).slice(0,4)),gn(te),j&&j.name&&j.email&&en({name:j==null?void 0:j.name,email:j==null?void 0:j.email,message:""}),m(ke=>[...ke,{text:"Please provide your name, email and message to connect with support.",isBot:!0}]),Rt(!0)},ot=async j=>{j.preventDefault();const te={name:"",email:"",message:""};let he=!0;const ke=Mt.name.trim(),we=Mt.message.trim();ke||(te.name="Name cannot be empty or just whitespace.",he=!1),(!Mt.email||!zm.isEmail(Mt.email))&&(te.email="Please enter a valid email address.",he=!1),we||(te.message="Message cannot be empty or just whitespace.",he=!1),Kt(te),he&&(sf({name:ke,email:Mt.email}),Rt(!1),m(Je=>Je.slice(0,-1)),await ca())},[Oe,at]=Z.useState({});return Z.useEffect(()=>{hr&&(h.forEach((j,te)=>{if(!j.isBot)return;const he=$p(j.text);if(!(te in Oe)||Oe[te]<he.length){let ke;const we=Je=>{Je<he.length&&(ke=setTimeout(()=>{at($t=>({...$t,[te]:Je+1})),we(Je+1)},ho))};return te in Oe?we(Oe[te]):(at(Je=>({...Je,[te]:1})),we(1)),()=>clearTimeout(ke)}}),at(j=>{const te={};return h.forEach((he,ke)=>{j[ke]!==void 0&&(te[ke]=j[ke])}),te}))},[h,hr]),!t||t.show_bot===!1||a?null:M.jsxs(Jw,{theme:pE(t,e),children:[M.jsx("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),M.jsx("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",rel:"stylesheet"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap",rel:"stylesheet"}),M.jsx(R0e,{}),M.jsxs(s0e,{$topOffset:Br,$isLeft:W,children:[!Ae&&P.length>0&&P[U]&&se&&M.jsx(k0e,{className:Ce?"visible":"",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Br,style:{display:"flex",flexDirection:W?"row":"row-reverse",alignItems:"center",marginLeft:dt?"60px":"85px",marginRight:dt?"60px":"85px",left:W?"24px":"auto",right:W?"auto":"24px",opacity:Ce?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length>0&&P[U]&&(()=>{const j=P[U];return M.jsx(T0e,{children:M.jsx(i0e,{messages:[{question:j.question,isHighlighted:j.isHighlighted??!1,show_for:(ee==null?void 0:ee.show_for)||4e3,hide_timing:(ee==null?void 0:ee.hide_timing)||4e3}],botId:e,uiData:t,onClose:()=>{Ve(te=>{const he=new Set(te);return he.add(j.question),he})},onClick:()=>{const te=j;lt(!0,"suggested_question_clicked"),Ve(he=>{const ke=new Set(he);return ke.add(te.question),ke}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:te}),E?(ln(!1),xr(!0),A(!0),R(te)):(ln(!1),xr(!0),r({message:te.Follow_up_Question??te.question,answer:te.answer,products:te.products,fromKlaviyo:!1,leading_queries:te.leading_queries,followUpQuestion:te.Follow_up_Question,messType:"suggested_question"}))}})},j.question)})()}),M.jsxs(l0e,{$topOffset:Br,$removeLogoBackground:t.removeLogoBackground,$isLeft:W,style:{display:Ae?"none":"inline-flex"},children:[M.jsx(u0e,{$showAnimation:t.enableChatButtonBackgroundAnimation??!1,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",$backgroundColor:t.backgroundColor||"#fff",$removeLogoBackground:t.removeLogoBackground,$topOffset:Br,$iconSize:H}),M.jsxs(c0e,{$backgroundColor:t.removeLogoBackground?"transparent":t.backgroundColor||"#fff",$botId:e,$isLeft:W,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Br,$showAnimation:t.enableChatButtonBackgroundAnimation,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",id:"debales-chat-button","data-testid":"debales-chat-button",onClick:()=>{if(window.DebalesChat.track(tn.CHAT_BUTTON_CLICKED),lt(!Ae,"chat_button_clicked"),!Ae){const j=_();j.length>0?(m(j),ln(!1),xr(!0)):(ln(!0),xr(!1),setTimeout(()=>{ln(!1),xr(!0);const te={text:(t==null?void 0:t.initialMessage)||"Hi, I am an AI chatbot, how can I help you today?",isBot:!0};m([te])},(ee==null?void 0:ee.showing_delay)||2e3))}},"aria-label":"Chat",style:{display:Ae?"none":"inline-flex"},children:[M.jsx(f0e,{$botId:e,$removeLogoBackground:t.removeLogoBackground,"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),(P==null?void 0:P.length)>0&&!Ae&&de&&M.jsx("div",{style:{position:"absolute",top:"-5px",right:"-5px",backgroundColor:"#f44336",color:"white",borderRadius:"50%",width:"20px",height:"20px",display:"flex",justifyContent:"center",alignItems:"center",fontSize:"12px",fontWeight:"bold",zIndex:2,opacity:de?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length})]})]})]}),Ae&&vw.createPortal(M.jsx(M.Fragment,{children:M.jsxs(g0e,{$backgroundColor:t.backgroundColor||"#fff",$fullScreenOnMobile:t.fullScreenOnMobile,$headerFontColor:t.headerFontColor||"#1C1C1C",$isLeft:W,$topOffset:Br,$mobileDisplayMode:t.mobileDisplayMode,$isVisible:rt,"data-testid":"debales-chat-container",children:[M.jsxs(y0e,{$backgroundColor:Me(e)?t.backgroundColor:t.botBackgroundColor||"#fff",style:{color:t.headerFontColor},children:[M.jsx("div",{style:{flexGrow:.1,display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden",marginRight:"8px",gap:"10px"},children:Me(e)?M.jsxs(M.Fragment,{children:[M.jsx(sH,{"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),Me(e)?M.jsx("div",{children:M.jsx("img",{src:yk,alt:"Chat Bot Icon",style:{height:"36px"}})}):M.jsxs(d0e,{$botNameColor:t.headerFontColor,children:[M.jsxs("div",{style:{fontWeight:"700",wordBreak:"break-word"},children:[t.chatbotName,e==="catch-org-ai"&&M.jsx(p0e,{$backgroundColor:t.callToActionBackgroundColor,$fontColor:t.callToActionFontColor,children:"Beta"})]}),M.jsx(h0e,{})]})]}):M.jsx(m0e,{children:M.jsxs(v0e,{children:[M.jsx(sH,{src:t.bot_logo,alt:"Chat Bot Icon"}),M.jsx("span",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",display:"inline-block",maxWidth:"22ch"},children:t.chatbotName})]})})}),M.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"8px",marginLeft:"auto",flexShrink:0},children:[M.jsxs(O0e,{children:[M.jsx(lH,{$iconBG:t.backgroundColor,onClick:Kr,"aria-label":"Support","data-testid":"debales-support-button",children:M.jsx(Tk,{color:t.headerFontColor})}),M.jsx(hH,{children:"Click to chat with a Live Support Agent now."})]}),M.jsx(lH,{$iconBG:t.backgroundColor,onClick:()=>{_t?Dt(!0):lt(!1,"close_button_clicked")},id:"debales-minimize-button","data-testid":"debales-minimize-button","aria-label":"Minimize",children:M.jsx(Zm,{botNameColor:t.headerFontColor})})]}),M.jsx(N0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}})]}),M.jsxs(_0e,{$backgroundColor:t.botBackgroundColor||"#fff",$mobileDisplayMode:t.mobileDisplayMode,children:[Oi&&((Ie=(ce=t.pluginConfig)==null?void 0:ce.collectedUserInfo)==null?void 0:Ie.discount)&&M.jsx(Nk,{discount:t.pluginConfig.collectedUserInfo.discount,uiData:t,onClose:()=>{pr(!1),window.DebalesChat.track(tn.DISCOUNT_VIEWED,{discount:t.pluginConfig.collectedUserInfo.discount})}}),M.jsx(kk,{}),M.jsx(Pk,{uidata:t,product:to,showModel:us,setShowModel:ji,onVariantSelect:j=>{I(j.id,1),_e(!0),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:j.title,price:Number(j.price),link:`https://${t.shopifyShopDomain}/variants/${j.id}`,message:l,chatId:nr()+e})},botId:e}),Ho&&M.jsx(zk,{setShowExitModal:Dt,handleCloseChatbot:Ro,chatId:nr()+e}),M.jsxs(x0e,{id:"debales-conversation-group",$botBackgroundColor:t.botBackgroundColor||"#fff",ref:ve,$mobileDisplayMode:t.mobileDisplayMode,children:[M.jsx(B0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}}),M.jsxs(b0e,{children:[hr&&h.map((j,te)=>{const he=j.isBot,ke=$p(j.text);return j.hideConfirmation?null:M.jsxs(Z.Fragment,{children:[he&&M.jsxs(uH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff","data-testid":"debales-ai-message-container",children:[M.jsx("img",{src:he?t.bot_logo:t.userMessage_logo,alt:"Chat User Icon",style:{marginLeft:"8px"}}),M.jsxs(dH,{children:[ke.slice(0,Oe[te]||0).map((we,Je)=>M.jsx("div",{children:M.jsx(Ri,{isBot:he,children:M.jsx(bd,{remarkPlugins:[Mw,vE],children:we})})},Je)),j.collections&&l===j.conversationId&&Y.collections&&M.jsx(Lk,{message:j,botId:e,uidata:t,onSendMessage:r,loading:p}),j.products&&l===j.conversationId&&Y.products&&M.jsx(Uk,{message:j,botId:e,uidata:t,onSendMessage:r,loading:p,storeMetaData:n,platform:V,setShowVariantModel:ji,setSelectedProduct:rr,setCartVersion:le}),o&&M.jsx(j8,{children:M.jsx(Nx,{onClick:()=>{window._klOnsite&&(window._klOnsite.push(["openForm",yt]),lt(!1,"klaviyo_grab_deal_button"))},children:"πŸš€ Grab Deal Now!"})}),O&&O.itemCount>0&&l===j.conversationId&&Y.cartSummary&&mt&&M.jsx(Mk,{onCheckout:ua,onKeepShopping:()=>{_e(!1)}}),Re&&Re.length>0&&l===j.conversationId&&Y.bulkItems&&M.jsx(mk,{onClick:()=>po(j.conversationId),children:"Add Bulk Items to Cart"}),k&&h.indexOf(j)===h.length-1&&M.jsx(M.Fragment,{children:M.jsx(jk,{setShowModel:we=>{var $t,an;const Je=typeof we=="function"?we(k):we;A(Je),!Je&&((an=($t=t.pluginConfig)==null?void 0:$t.collectedUserInfo)!=null&&an.discount)&&pr(!0)},inChat:!0,showFormInstructions:!1})}),ct&&h.indexOf(j)===h.length-1&&M.jsxs(D0e,{onSubmit:ot,noValidate:!0,"data-testid":"debales-support-form",children:[Me(e)?M.jsxs(M.Fragment,{children:[M.jsx(ru,{label:"Name",name:"name",type:"text",value:Mt.name,onChange:we=>en(Je=>({...Je,name:we.target.value})),required:!0,error:pt.name,isCollectiveBot:!0}),M.jsx(ru,{label:"Email",name:"email",type:"email",value:Mt.email,onChange:we=>en(Je=>({...Je,email:we.target.value})),required:!0,error:pt.email,isCollectiveBot:!0}),M.jsx(Fk,{label:"Message",name:"message",value:Mt.message,onChange:we=>en(Je=>({...Je,message:we.target.value})),required:!0,error:pt.message,rows:4,isCollectiveBot:!0})]}):M.jsxs(M.Fragment,{children:[M.jsxs(P8,{children:[M.jsxs(H8,{children:["Name",M.jsx("span",{children:"*"})]}),M.jsx(pH,{type:"text",required:!0,value:Mt.name,onChange:we=>en(Je=>({...Je,name:we.target.value})),placeholder:"John"}),pt.name&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.name})]}),M.jsxs(P8,{children:[M.jsxs(H8,{children:["Email",M.jsx("span",{children:"*"})]}),M.jsx(pH,{type:"email",required:!0,value:Mt.email,onChange:we=>en(Je=>({...Je,email:we.target.value})),placeholder:"olivia@untitledui.com"}),pt.email&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.email})]}),M.jsxs(P8,{children:[M.jsxs(H8,{children:["Message",M.jsx("span",{children:"*"})]}),M.jsx(M0e,{required:!0,value:Mt.message,onChange:we=>en(Je=>({...Je,message:we.target.value})),placeholder:"I need help with..."}),pt.message&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.message})]})]}),M.jsx($0e,{children:M.jsx(I0e,{type:"submit",children:"Submit"})})]}),St&&!p&&l===j.conversationId&&M.jsx(Ri,{isBot:he,children:M.jsx(Ds,{loading:St})})]})]}),!he&&M.jsx(E0e,{$fontColor:t.userFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:M.jsx(Ri,{isBot:!!he,children:M.jsx(bd,{children:j.text})})}),h.length==1&&te==0&&!k&&M.jsx(j8,{children:it.leadingQueries?M.jsx(Ri,{isBot:!0,children:M.jsx(Ds,{loading:it.leadingQueries})}):P.map((we,Je)=>M.jsxs(fH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor,opacity:$e.has(we.question)?.5:1},onClick:()=>{E?(A(!0),R({question:we.question,answer:we.answer,products:we.products,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:we.question,answer:we.answer,products:we.products,leading_queries:we.leading_queries,followUpQuestion:we.Follow_up_Question,messType:"leading_query"}),Ve($t=>{const an=new Set($t);return an.add(we.question),an}),window.DebalesChat.track(tn.INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED,{question:we.question})},disabled:p,$disabled:p,children:[we.question,M.jsx(cH,{color:t.callToActionFontColor})]},Je))}),j.leading_queries&&j.leading_queries.length>0&&l===j.conversationId&&Y.leadingQueries&&!o&&!k&&M.jsx(j8,{children:j.leading_queries.map((we,Je)=>M.jsxs(fH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{E?(A(!0),R({question:we,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:we,messType:"leading_query"}),window.DebalesChat.track(tn.LEADING_QUERY_CLICKED,{query:we})},disabled:p,$disabled:p,children:[we,M.jsx(cH,{color:t.callToActionFontColor})]},Je))})]},te)}),(p||qt)&&M.jsxs(uH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:[M.jsx("img",{src:t.bot_logo,alt:"Chat User Icon"}),M.jsx(dH,{children:M.jsx(Ri,{isBot:!0,children:M.jsx("div",{style:{display:"flex",alignItems:"center",gap:"4px",animation:"fadeIn 0.3s ease-in-out"},children:M.jsx(Ds,{loading:p||qt})})})})]})]}),M.jsx(L0e,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:yn?1:0}})]}),M.jsxs("div",{className:"debales-footer-container",style:{width:"100%",backgroundColor:t.botBackgroundColor||"#fff",color:t.fontColor||"#000"},children:[(e==="catch-org-ai"||e==="letsgo-catch")&&M.jsx(C0e,{children:M.jsx("span",{children:`"${t.chatbotName}" can make mistakes.`})}),M.jsx("div",{children:M.jsx(Hk,{disabled:p,inputState:!1})}),(t.debales_branding??!0)&&M.jsxs(S0e,{href:"https://debales.ai/?open=true",target:"_blank",title:"debales-link",style:{color:t.fontColor?t.fontColor:"fff",marginTop:e==="catch-org-ai"?"0":"9px"},children:[M.jsx("p",{children:"Powered by"}),M.jsxs(w0e,{children:[M.jsx("img",{src:`${Ti}/images/debales_logo_d.png`,alt:"Debales logo"}),M.jsx("p",{children:"DEBALES"})]})]})]})]})]})}),z.shadowRoot)]})},F0e=ae.p`
3740
3740
  margin: 0;
3741
3741
  font-size: 16px;
3742
3742
  min-height: 24px;
@@ -3866,7 +3866,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3866
3866
  -ms-flex-negative: 0;
3867
3867
  flex-shrink: 0;
3868
3868
  object-fit: contain;
3869
- border-radius: ${e=>Ie(e.theme.botId)?"0":"50%"} !important;
3869
+ border-radius: ${e=>Me(e.theme.botId)?"0":"50%"} !important;
3870
3870
  padding: 2px !important;
3871
3871
 
3872
3872
  @media screen and (max-width: 768px) {
@@ -3920,7 +3920,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3920
3920
  z-index: 2147483647;
3921
3921
  background-color: ${e=>e.$backgroundColor};
3922
3922
  color: ${e=>e.$headerFontColor};
3923
- border-radius: ${e=>Ie(e.theme.botId)?"0":"16px"} !important;
3923
+ border-radius: ${e=>Me(e.theme.botId)?"0":"16px"} !important;
3924
3924
  padding: 0 !important;
3925
3925
  margin: 0 !important;
3926
3926
  display: flex;
@@ -3946,7 +3946,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3946
3946
  left: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$isLeft?"16px":"auto":e.$fullScreenOnMobile?"0":e.$isLeft?"16px":"auto"};
3947
3947
  right: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$isLeft?"auto":"16px":e.$fullScreenOnMobile?"0":e.$isLeft?"auto":"16px"};
3948
3948
  bottom: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$topOffset||"16px":e.$fullScreenOnMobile?"0":e.$topOffset||"16px"};
3949
- border-radius: ${e=>Ie(e.theme.botId)||e.$mobileDisplayMode==="full-screen"?"0":e.$mobileDisplayMode==="half-screen"?"16px 16px 0 0":"16px"} !important;
3949
+ border-radius: ${e=>Me(e.theme.botId)||e.$mobileDisplayMode==="full-screen"?"0":e.$mobileDisplayMode==="half-screen"?"16px 16px 0 0":"16px"} !important;
3950
3950
  overflow: hidden;
3951
3951
  touch-action: manipulation;
3952
3952
  /* Apply proper touch action for mobile modes to allow content scrolling */
@@ -3969,14 +3969,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3969
3969
  display: flex;
3970
3970
  align-items: center;
3971
3971
  padding: 2px;
3972
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
3972
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
3973
3973
  background: conic-gradient(#0ead3f, #00b200, #1ca77e, #379bfb, #0ead3f);
3974
3974
  `,J0e=ae.div`
3975
3975
  display: flex;
3976
3976
  align-items: center;
3977
3977
  background: #fff;
3978
3978
  padding: 0 16px 0 3px; /* Adjusted padding */
3979
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
3979
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
3980
3980
  height: 40px; /* Adjusted height */
3981
3981
  font-weight: 600;
3982
3982
  font-size: 16px; /* Adjusted font-size */
@@ -3984,9 +3984,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3984
3984
  `,mH=ae.button`
3985
3985
  width: 40px;
3986
3986
  height: 40px;
3987
- border-radius: ${e=>Ie(e.theme.botId)?"0":"50%"} !important;
3987
+ border-radius: ${e=>Me(e.theme.botId)?"0":"50%"} !important;
3988
3988
  border: 1.5px solid rgba(0, 0, 0, 0.3);
3989
- background: ${e=>Ie(e.theme.botId)?e.$iconBG:"#fff"};
3989
+ background: ${e=>Me(e.theme.botId)?e.$iconBG:"#fff"};
3990
3990
  display: flex;
3991
3991
  align-items: center;
3992
3992
  justify-content: center;
@@ -3994,7 +3994,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
3994
3994
  cursor: pointer;
3995
3995
  transition: background 0.2s;
3996
3996
  &:hover {
3997
- background: ${e=>!Ie(e.theme.botId)&&"#f5f5f5"};
3997
+ background: ${e=>!Me(e.theme.botId)&&"#f5f5f5"};
3998
3998
  }
3999
3999
  `,ege=ae.div`
4000
4000
  z-index: 2147483647;
@@ -4028,7 +4028,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4028
4028
 
4029
4029
  &::-webkit-scrollbar-thumb {
4030
4030
  background: #7a7979;
4031
- border-radius: ${e=>Ie(e.theme.botId)?"0":"5px"} !important;
4031
+ border-radius: ${e=>Me(e.theme.botId)?"0":"5px"} !important;
4032
4032
  }
4033
4033
 
4034
4034
  /* Improved scrolling behavior for all mobile modes */
@@ -4164,12 +4164,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4164
4164
  justify-content: center;
4165
4165
  text-align: left;
4166
4166
  align-self: stretch;
4167
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
4167
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
4168
4168
  color: white;
4169
4169
  border: none;
4170
4170
  cursor: ${e=>e.$disabled?"default":"pointer"};
4171
4171
  font-size: 14px;
4172
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
4172
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
4173
4173
  line-height: 20px !important;
4174
4174
  transition: all 0.05s ease;
4175
4175
  height: auto !important;
@@ -4239,7 +4239,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4239
4239
  display: flex;
4240
4240
  align-items: center;
4241
4241
  background: ${e=>e.$removeLogoBackground?"transparent":e.theme.colors.background};
4242
- border-radius: ${e=>Ie(e.theme.botId)?"0":"16px"} !important;
4242
+ border-radius: ${e=>Me(e.theme.botId)?"0":"16px"} !important;
4243
4243
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
4244
4244
  gap: 12px;
4245
4245
  position: relative;
@@ -4368,7 +4368,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4368
4368
  margin: 4px 10px 4px;
4369
4369
  padding: 16px 16px;
4370
4370
  background-color: ${e=>e.theme.colors.bot.message||"#fff"};
4371
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
4371
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
4372
4372
  width: 100%;
4373
4373
  max-width: 320px;
4374
4374
  `,V8=ae.div`
@@ -4382,7 +4382,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4382
4382
  margin-bottom: 8px;
4383
4383
  font-size: 16px;
4384
4384
  color: #1c1c1c;
4385
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
4385
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
4386
4386
 
4387
4387
  span {
4388
4388
  color: #ff3b30;
@@ -4391,30 +4391,30 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4391
4391
  width: calc(100% - 26px);
4392
4392
  padding: 12px;
4393
4393
  border: 1px solid #d0d5dd;
4394
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
4394
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
4395
4395
  font-size: 16px;
4396
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
4397
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
4396
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
4397
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
4398
4398
 
4399
4399
  &:focus {
4400
4400
  outline: none;
4401
4401
  border-color: #f48722;
4402
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
4402
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
4403
4403
  }
4404
4404
  `,gge=ae.textarea`
4405
4405
  width: calc(100% - 26px);
4406
4406
  padding: 12px;
4407
4407
  border: 1px solid #d0d5dd;
4408
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
4408
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
4409
4409
  font-size: 16px;
4410
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
4411
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
4410
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
4411
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
4412
4412
  resize: none;
4413
4413
 
4414
4414
  &:focus {
4415
4415
  outline: none;
4416
4416
  border-color: #f48722;
4417
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
4417
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
4418
4418
  }
4419
4419
  `,mge=ae.button`
4420
4420
  height: 40px !important;
@@ -4423,9 +4423,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4423
4423
  background-color: ${e=>e.theme.colors.cta.background};
4424
4424
  color: ${e=>e.theme.colors.cta.font};
4425
4425
  border: none;
4426
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
4426
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
4427
4427
  font-size: 14px;
4428
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
4428
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
4429
4429
  cursor: pointer;
4430
4430
  transition: all 0.3s ease;
4431
4431
  justify-content: center;
@@ -4485,11 +4485,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4485
4485
  opacity: 0;
4486
4486
  z-index: 1;
4487
4487
  bottom: 0;
4488
- `,_ge=({botId:e})=>{var ce,Me;const{uiData:t,storeMetaData:n,onSendMessage:r,isKlaviyoMessage:o,isLoading:a,lastedBotmessageId:l,setLastedBotmessageId:d,messages:h,isMessageLoading:p,setIsMessageLoading:y,setMessages:m,saveConversation:x,loadConversation:_,suggestedQuestions:w,showUserInfoModel:k,setShowUserInfoModel:A,isUserInfoNeeded:E,setPendingQuestion:R}=qd(),{cart:O,addToCart:I,generateCartUrl:L,addCartAttributes:N}=Fd(),H=Qc("use-chatbot-icon-size"),V=hf.detect(),W=t==null?void 0:t.isLeft,z=xk(),Q=t==null?void 0:t.heightOption,J=Z.useRef(0),ee=Qc("new-suggested-question-design"),[de,ue]=Z.useState(!1),[se,pe]=Z.useState(!1),[Ce,B]=Z.useState(!1),[P,ne]=Z.useState([]),[U,fe]=Z.useState(0),[Ae,Te]=Z.useState(!1),[rt,Ge]=Z.useState(!1),We=Ql("acquisition_agent"),[Tt,It]=Z.useState(window.location.pathname),nt=Z.useCallback(async()=>{try{if(!We||(t==null?void 0:t.show_bot)===!1)return;const j=await fetch(`${Ti}/api/wordpress/acquisition`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,timestamp:new Date().toISOString(),page_information:window.location.href.split("?")[0],botid:e})});if(j.ok){const te=await j.json(),he=window.location.pathname,ke=3;ne(we=>{const Je=[...we],$t={question:te.Popup_Message,answer:"",path:he,nameSpace:e,type:"dynamic",Follow_up_Question:te.Follow_up_Question};return Je.length>=ke&&Je.shift(),Je.push($t),console.log("updated questions in ChatbotComponent2",Je),Je})}else console.error("Failed to fetch new acquisition question")}catch(j){console.error("Error fetching new acquisition question:",j)}},[e,We,t==null?void 0:t.show_bot]);Z.useEffect(()=>{const j=()=>{const ke=window.location.pathname;ke!==Tt&&(It(ke),nt())};window.addEventListener("popstate",j);const te=history.pushState,he=history.replaceState;return history.pushState=function(...ke){te.apply(this,ke),j()},history.replaceState=function(...ke){he.apply(this,ke),j()},()=>{window.removeEventListener("popstate",j),history.pushState=te,history.replaceState=he}},[Tt,nt]),Z.useEffect(()=>{const j=dn=>{if(typeof window<"u"&&typeof document<"u"&&document.documentElement){const gr=document.documentElement.scrollHeight,$r=document.documentElement.clientHeight,hi=window.scrollY,ai=gr-$r;return ai<=0?dn:hi/ai*100>50?0:dn}return dn};if(ee&&!Ae&&(J.current=j(ee.showing_delay||2e3)),!ee||Ae||P.length===0)return;let te,he,ke,we;const Je=ee.showing_delay||2e3,$t=ee.showing_delay||2e3,an=ee.show_for||4e3,un=ee.hide_timing||4e3,Un=async()=>{if(P.length===0||!P[U]){we=setTimeout(()=>{P.length>0&&fe(dn=>dn%P.length)},un+500);return}te=setTimeout(()=>{Ae||(ue(!0),he=setTimeout(async()=>{Ae||(pe(!0),B(!0),ke=setTimeout(async()=>{Ae||(B(!1),pe(!1),ue(!1),fe(dn=>(dn+1)%P.length),we=setTimeout(()=>{Un()},un))},an))},$t))},J.current)};return P.length===0&&e?nt().then(()=>{if(!Ae&&P.length>0){fe(0);const dn=j(Je);J.current=dn,Un()}}):!Ae&&P.length>0&&Un(),()=>{clearTimeout(te),clearTimeout(he),clearTimeout(ke),clearTimeout(we)}},[ee,Ae,nt,P,U,e]);const[dt,bt]=Vm(On.SHOW_CART_SUMMARY,!0),[Et,Nt]=Z.useState(!1);Z.useEffect(()=>{const j=()=>{Nt(window.matchMedia("(max-width: 768px)").matches)};return j(),()=>window.removeEventListener("resize",j)},[]);const[yt,re]=Z.useState(""),[le,ve]=Z.useState(""),[,Ee]=Z.useState(0);Z.useEffect(()=>{e&&gk(e)},[e]),Z.useEffect(()=>{mE(e)},[e]),Z.useEffect(()=>{let j=jo();if(!j&&window.Thinkific){const te=window.Thinkific.current_user;te&&(j={name:te.full_name,email:te.email},sf(j))}Xu.init({projectName:e,debug:!1,testing:Cx}),j&&j.email&&(window.DebalesChat.identify(j.email,{name:j.name,phone:j.phone,email:j.email}),t!=null&&t.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:j.email,first_name:j.name,phone:j.phone,from:"Debales-Chatbot"}))},[e,t==null?void 0:t.KlaviyoIntegration]);const $e=Z.useRef(null),Ve=Qn(On.CLICKED_QUESTIONS,{botId:e}),[lt,mt]=Z.useState(()=>{try{const j=sessionStorage.getItem(Ve);return j?new Set(JSON.parse(j)):new Set}catch{return new Set}});Z.useEffect(()=>{try{sessionStorage.setItem(Ve,JSON.stringify(Array.from(lt)))}catch(j){console.error("Failed to save to sessionStorage:",j)}},[lt]);const _e=Z.useCallback((j,te)=>{j?(window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:j,source:te,projectId:e}})),setTimeout(()=>{Ge(!0)},50)):(Ge(!1),window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:j,source:te,projectId:e}})))},[]);Z.useEffect(()=>{const j=te=>{te.detail.projectId===e&&(Te(te.detail.isOpen),te.detail.isOpen&&setTimeout(()=>Ge(!0),50),window.DebalesChat.isOpen=te.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:te.detail.isOpen,source:te.detail.source}))};return window.addEventListener(Qr.OPEN_STATE_CHANGE,j),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,j)}},[e,Te,Ge]);const[Re,Ct]=Z.useState(()=>{const j=Qn(On.PENDING_BULK_ITEMS,{botId:e}),te=sessionStorage.getItem(j);return te?JSON.parse(te):[]});Z.useEffect(()=>{const j=Qn(On.PENDING_BULK_ITEMS,{botId:e});sessionStorage.setItem(j,JSON.stringify(Re))},[Re,e]);const[ct,Rt]=Z.useState(!1),[Mt,en]=Z.useState({name:"",email:"",message:""}),[Qt,gn]=Z.useState([]),[pt,Kt]=Z.useState({name:"",email:"",message:""}),_t=Ql("exit_model"),[Y,xe]=Z.useState({text:!0,leadingQueries:!0,collections:!0,products:!0,variants:!0,cartSummary:!0,bulkItems:!0}),[it,st]=Z.useState({suggestions:!1,products:!1,collections:!1,leadingQueries:!1,initialMessage:!1,cartSummary:!1,bulkItems:!1});Z.useEffect(()=>{if(h.length===1&&!k){st(te=>({...te,leadingQueries:!0}));const j=setTimeout(()=>{st(te=>({...te,leadingQueries:!1}))},2e3);return()=>clearTimeout(j)}},[h,k]);const[St,Pt]=Z.useState(!1),[Ht,Yt]=Z.useState(!0),[qt,ln]=Z.useState(!1),[hr,xr]=Z.useState(!1),[Ur,nn]=Z.useState(!1),[yn,fn]=Z.useState(!1),ho=500,br=Z.useCallback(()=>{const j=$e.current;if(!j){nn(!1),fn(!1),Yt(!0);return}if(Ie(e)){nn(!1);return}const te=j.scrollTop,he=j.scrollHeight,ke=j.clientHeight,we=he>ke,Je=1,$t=te<=Je,an=te+ke>=he-Je;we?(nn(!$t),fn(!an),Yt(an)):(nn(!1),fn(!1),Yt(!0))},[$e,nn,fn,Yt]);Z.useEffect(()=>{const j=$e.current;if(Ae&&j){br(),j.addEventListener("scroll",br);const te=new ResizeObserver(br);return te.observe(j),()=>{j.removeEventListener("scroll",br),te.unobserve(j)}}else Ae||(nn(!1),fn(!1),Yt(!0))},[Ae,h,St,br]),Z.useEffect(()=>{var j,te,he,ke,we,Je;if(h.length>0&&!p){const $t=h[h.length-1],an=sessionStorage.getItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e})),un=$t.isBot&&$t.conversationId===l&&$t.conversationId!==an,Un=(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0&&$t.conversationId===l;if(un){Pt(!0),sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),$t.conversationId||""),xe({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1});const dn=2e3;let gr=dn;const $r=[{type:"collections",condition:((j=$t.collections)==null?void 0:j.length)&&((te=$t.collections)==null?void 0:te.length)>0},{type:"products",condition:((he=$t.products)==null?void 0:he.length)&&((ke=$t.products)==null?void 0:ke.length)>0},{type:"leadingQueries",condition:((we=$t.leading_queries)==null?void 0:we.length)&&((Je=$t.leading_queries)==null?void 0:Je.length)>0},{type:"cartSummary",condition:(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0},{type:"bulkItems",condition:(Re==null?void 0:Re.length)>0}].filter(hi=>hi.condition);if($r.length===0){Pt(!1);return}$r.forEach(({type:hi},ai)=>{setTimeout(()=>{if(xe(go=>({...go,[hi]:!0})),Ht&&$e.current){const go=$e.current;go.scrollHeight-go.scrollTop<=go.clientHeight&&La($e)}ai===$r.length-1&&Pt(!1)},gr),gr+=dn})}else Un&&xe(dn=>({...dn,cartSummary:!0}))}},[h,p,l,O==null?void 0:O.itemCount,Re==null?void 0:Re.length,Ht,e]),Z.useEffect(()=>{if(!o&&h.length>0){const j=$e.current;j&&Ht&&j.scrollHeight-j.scrollTop<=j.clientHeight+100&&setTimeout(()=>La($e),100)}},[h.length,o,Ht]),Z.useEffect(()=>{const j=document.querySelector('meta[name="viewport"]'),te=j==null?void 0:j.content;if(Ae){let he=j;const ke=window.matchMedia("(max-width: 768px)").matches;he?he.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no":(he=document.createElement("meta"),he.name="viewport",he.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no",document.head.appendChild(he)),ke&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="hidden");const we=he;return()=>{te&&we&&(we.content=te),ke&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}}return()=>{window.matchMedia("(max-width: 768px)").matches&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}},[Ae,t==null?void 0:t.mobileDisplayMode]),Z.useEffect(()=>{if(Ae&&h.length>0&&!o){const j=setTimeout(()=>{$e.current&&La($e)},150);return()=>clearTimeout(j)}},[Ae,h.length,o]),Z.useEffect(()=>{O!=null&&O.itemCount&&O.itemCount===0&&!o&&setTimeout(()=>La($e),100)},[O==null?void 0:O.itemCount,o]),Z.useEffect(()=>{l&&sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),l)},[l,e]);const[us,ji]=Z.useState(!1),[Ho,Dt]=Z.useState(!1),[to,rr]=Z.useState(null),Ro=async j=>{const te=nr();if(Ge(!1),j&&h.length>1)try{(await fetch(`${Ti}/api/wordpress/userRating`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sessionId:te,userRating:j,nameSpace:e})})).ok||console.error("Error submitting rating")}catch(he){console.error("Error submitting rating:",he)}setTimeout(()=>{Dt(!1),_e(!1,"close_button_clicked")},1e3)},po=j=>{y(!0),Re.forEach(he=>{I(he.id,he.quantity)}),bt(!0),window.DebalesChat.track(tn.ADD_BULK_ITEM,{products:Re,message:j});const te=[...h,{text:"πŸŽ‰ Bulk items added to cart successfully.",leading_queries:["Get GST Invoice for the order","Explore more products"],conversationId:j,isBot:!0}];m(te),x(te),d(j),Ct([]),y(!1)},qn=()=>{var j;switch(e){case"minature":case"bodytales":case"imemyselfcare-com":if(window.triggerGokwikCustomCheckout)return window.triggerGokwikCustomCheckout(),!0;break;case"athflex":if((j=window.shiprocketCheckoutEvents)!=null&&j.buyCart)return window.shiprocketCheckoutEvents.buyCart(),!0;break;case"www":if(window.openRzpCheckout)return window.openRzpCheckout(),!0;break;default:return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1}return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1},ua=async j=>{j.preventDefault(),window.DebalesChat.track(tn.CHECKOUT_CLICKED,{chatId:nr()+e,cartValue:Number(O==null?void 0:O.total),cart:O}),N({dbls_method:"checkout_clicked"}),qn()&&_e(!1,"checkout_clicked")};Z.useEffect(()=>{const j=gE(w);ne(te=>[...j.filter(ke=>!te.some(we=>we.question===ke.question))])},[w]),Z.useEffect(()=>{const j=ke=>{const we=ke.detail.formId;switch(ke.detail.type){case"open":case"embedOpen":setTimeout(()=>{const $t=te(we);$t&&re($t)},800);break;case"close":yt&&(t==null?void 0:t.KlaviyoFormIntegration)===!0&&setTimeout(()=>{_e(!0,"klaviyo_form_closed"),ve(we),r({message:yt,fromKlaviyo:!0})},1e4);break}},te=ke=>{const we=document.querySelector(`[data-testid="klaviyo-form-${ke}"]`);if(console.log(`formElement text ${ke} =>`,we==null?void 0:we.innerText,we==null?void 0:we.textContent),we instanceof HTMLElement){const Je=we.innerText||we.textContent;if(Je)return console.log("Found form text:",Je),`=> Klaviyo form content:
4488
+ `,_ge=({botId:e})=>{var ce,Ie;const{uiData:t,storeMetaData:n,onSendMessage:r,isKlaviyoMessage:o,isLoading:a,lastedBotmessageId:l,setLastedBotmessageId:d,messages:h,isMessageLoading:p,setIsMessageLoading:y,setMessages:m,saveConversation:x,loadConversation:_,suggestedQuestions:w,showUserInfoModel:k,setShowUserInfoModel:A,isUserInfoNeeded:E,setPendingQuestion:R}=qd(),{cart:O,addToCart:I,generateCartUrl:L,addCartAttributes:N}=Fd(),H=Qc("use-chatbot-icon-size"),V=hf.detect(),W=t==null?void 0:t.isLeft,z=xk(),Q=t==null?void 0:t.heightOption,J=Z.useRef(0),ee=Qc("new-suggested-question-design"),[de,ue]=Z.useState(!1),[se,pe]=Z.useState(!1),[Ce,B]=Z.useState(!1),[P,ne]=Z.useState([]),[U,fe]=Z.useState(0),[Ae,Te]=Z.useState(!1),[rt,Ge]=Z.useState(!1),We=Ql("acquisition_agent"),[Tt,It]=Z.useState(window.location.pathname),nt=Z.useCallback(async()=>{try{if(!We||(t==null?void 0:t.show_bot)===!1)return;const j=await fetch(`${Ti}/api/wordpress/acquisition`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,timestamp:new Date().toISOString(),page_information:window.location.href.split("?")[0],botid:e})});if(j.ok){const te=await j.json(),he=window.location.pathname,ke=3;ne(we=>{const Je=[...we],$t={question:te.Popup_Message,answer:"",path:he,nameSpace:e,type:"dynamic",Follow_up_Question:te.Follow_up_Question};return Je.length>=ke&&Je.shift(),Je.push($t),console.log("updated questions in ChatbotComponent2",Je),Je})}else console.error("Failed to fetch new acquisition question")}catch(j){console.error("Error fetching new acquisition question:",j)}},[e,We,t==null?void 0:t.show_bot]);Z.useEffect(()=>{const j=()=>{const ke=window.location.pathname;ke!==Tt&&(It(ke),nt())};window.addEventListener("popstate",j);const te=history.pushState,he=history.replaceState;return history.pushState=function(...ke){te.apply(this,ke),j()},history.replaceState=function(...ke){he.apply(this,ke),j()},()=>{window.removeEventListener("popstate",j),history.pushState=te,history.replaceState=he}},[Tt,nt]),Z.useEffect(()=>{const j=dn=>{if(typeof window<"u"&&typeof document<"u"&&document.documentElement){const gr=document.documentElement.scrollHeight,$r=document.documentElement.clientHeight,hi=window.scrollY,ai=gr-$r;return ai<=0?dn:hi/ai*100>50?0:dn}return dn};if(ee&&!Ae&&(J.current=j(ee.showing_delay||2e3)),!ee||Ae||P.length===0)return;let te,he,ke,we;const Je=ee.showing_delay||2e3,$t=ee.showing_delay||2e3,an=ee.show_for||4e3,un=ee.hide_timing||4e3,Un=async()=>{if(P.length===0||!P[U]){we=setTimeout(()=>{P.length>0&&fe(dn=>dn%P.length)},un+500);return}te=setTimeout(()=>{Ae||(ue(!0),he=setTimeout(async()=>{Ae||(pe(!0),B(!0),ke=setTimeout(async()=>{Ae||(B(!1),pe(!1),ue(!1),fe(dn=>(dn+1)%P.length),we=setTimeout(()=>{Un()},un))},an))},$t))},J.current)};return P.length===0&&e?nt().then(()=>{if(!Ae&&P.length>0){fe(0);const dn=j(Je);J.current=dn,Un()}}):!Ae&&P.length>0&&Un(),()=>{clearTimeout(te),clearTimeout(he),clearTimeout(ke),clearTimeout(we)}},[ee,Ae,nt,P,U,e]);const[dt,bt]=Vm(On.SHOW_CART_SUMMARY,!0),[Et,Nt]=Z.useState(!1);Z.useEffect(()=>{const j=()=>{Nt(window.matchMedia("(max-width: 768px)").matches)};return j(),()=>window.removeEventListener("resize",j)},[]);const[yt,re]=Z.useState(""),[le,ve]=Z.useState(""),[,Ee]=Z.useState(0);Z.useEffect(()=>{e&&gk(e)},[e]),Z.useEffect(()=>{mE(e)},[e]),Z.useEffect(()=>{let j=jo();if(!j&&window.Thinkific){const te=window.Thinkific.current_user;te&&(j={name:te.full_name,email:te.email},sf(j))}Xu.init({projectName:e,debug:!1,testing:Cx}),j&&j.email&&(window.DebalesChat.identify(j.email,{name:j.name,phone:j.phone,email:j.email}),t!=null&&t.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:j.email,first_name:j.name,phone:j.phone,from:"Debales-Chatbot"}))},[e,t==null?void 0:t.KlaviyoIntegration]);const $e=Z.useRef(null),Ve=Qn(On.CLICKED_QUESTIONS,{botId:e}),[lt,mt]=Z.useState(()=>{try{const j=sessionStorage.getItem(Ve);return j?new Set(JSON.parse(j)):new Set}catch{return new Set}});Z.useEffect(()=>{try{sessionStorage.setItem(Ve,JSON.stringify(Array.from(lt)))}catch(j){console.error("Failed to save to sessionStorage:",j)}},[lt]);const _e=Z.useCallback((j,te)=>{j?(window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:j,source:te,projectId:e}})),setTimeout(()=>{Ge(!0)},50)):(Ge(!1),window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:j,source:te,projectId:e}})))},[]);Z.useEffect(()=>{const j=te=>{te.detail.projectId===e&&(Te(te.detail.isOpen),te.detail.isOpen&&setTimeout(()=>Ge(!0),50),window.DebalesChat.isOpen=te.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:te.detail.isOpen,source:te.detail.source}))};return window.addEventListener(Qr.OPEN_STATE_CHANGE,j),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,j)}},[e,Te,Ge]);const[Re,Ct]=Z.useState(()=>{const j=Qn(On.PENDING_BULK_ITEMS,{botId:e}),te=sessionStorage.getItem(j);return te?JSON.parse(te):[]});Z.useEffect(()=>{const j=Qn(On.PENDING_BULK_ITEMS,{botId:e});sessionStorage.setItem(j,JSON.stringify(Re))},[Re,e]);const[ct,Rt]=Z.useState(!1),[Mt,en]=Z.useState({name:"",email:"",message:""}),[Qt,gn]=Z.useState([]),[pt,Kt]=Z.useState({name:"",email:"",message:""}),_t=Ql("exit_model"),[Y,xe]=Z.useState({text:!0,leadingQueries:!0,collections:!0,products:!0,variants:!0,cartSummary:!0,bulkItems:!0}),[it,st]=Z.useState({suggestions:!1,products:!1,collections:!1,leadingQueries:!1,initialMessage:!1,cartSummary:!1,bulkItems:!1});Z.useEffect(()=>{if(h.length===1&&!k){st(te=>({...te,leadingQueries:!0}));const j=setTimeout(()=>{st(te=>({...te,leadingQueries:!1}))},2e3);return()=>clearTimeout(j)}},[h,k]);const[St,Pt]=Z.useState(!1),[Ht,Yt]=Z.useState(!0),[qt,ln]=Z.useState(!1),[hr,xr]=Z.useState(!1),[Ur,nn]=Z.useState(!1),[yn,fn]=Z.useState(!1),ho=500,br=Z.useCallback(()=>{const j=$e.current;if(!j){nn(!1),fn(!1),Yt(!0);return}if(Me(e)){nn(!1);return}const te=j.scrollTop,he=j.scrollHeight,ke=j.clientHeight,we=he>ke,Je=1,$t=te<=Je,an=te+ke>=he-Je;we?(nn(!$t),fn(!an),Yt(an)):(nn(!1),fn(!1),Yt(!0))},[$e,nn,fn,Yt]);Z.useEffect(()=>{const j=$e.current;if(Ae&&j){br(),j.addEventListener("scroll",br);const te=new ResizeObserver(br);return te.observe(j),()=>{j.removeEventListener("scroll",br),te.unobserve(j)}}else Ae||(nn(!1),fn(!1),Yt(!0))},[Ae,h,St,br]),Z.useEffect(()=>{var j,te,he,ke,we,Je;if(h.length>0&&!p){const $t=h[h.length-1],an=sessionStorage.getItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e})),un=$t.isBot&&$t.conversationId===l&&$t.conversationId!==an,Un=(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0&&$t.conversationId===l;if(un){Pt(!0),sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),$t.conversationId||""),xe({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1});const dn=2e3;let gr=dn;const $r=[{type:"collections",condition:((j=$t.collections)==null?void 0:j.length)&&((te=$t.collections)==null?void 0:te.length)>0},{type:"products",condition:((he=$t.products)==null?void 0:he.length)&&((ke=$t.products)==null?void 0:ke.length)>0},{type:"leadingQueries",condition:((we=$t.leading_queries)==null?void 0:we.length)&&((Je=$t.leading_queries)==null?void 0:Je.length)>0},{type:"cartSummary",condition:(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0},{type:"bulkItems",condition:(Re==null?void 0:Re.length)>0}].filter(hi=>hi.condition);if($r.length===0){Pt(!1);return}$r.forEach(({type:hi},ai)=>{setTimeout(()=>{if(xe(go=>({...go,[hi]:!0})),Ht&&$e.current){const go=$e.current;go.scrollHeight-go.scrollTop<=go.clientHeight&&La($e)}ai===$r.length-1&&Pt(!1)},gr),gr+=dn})}else Un&&xe(dn=>({...dn,cartSummary:!0}))}},[h,p,l,O==null?void 0:O.itemCount,Re==null?void 0:Re.length,Ht,e]),Z.useEffect(()=>{if(!o&&h.length>0){const j=$e.current;j&&Ht&&j.scrollHeight-j.scrollTop<=j.clientHeight+100&&setTimeout(()=>La($e),100)}},[h.length,o,Ht]),Z.useEffect(()=>{const j=document.querySelector('meta[name="viewport"]'),te=j==null?void 0:j.content;if(Ae){let he=j;const ke=window.matchMedia("(max-width: 768px)").matches;he?he.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no":(he=document.createElement("meta"),he.name="viewport",he.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no",document.head.appendChild(he)),ke&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="hidden");const we=he;return()=>{te&&we&&(we.content=te),ke&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}}return()=>{window.matchMedia("(max-width: 768px)").matches&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}},[Ae,t==null?void 0:t.mobileDisplayMode]),Z.useEffect(()=>{if(Ae&&h.length>0&&!o){const j=setTimeout(()=>{$e.current&&La($e)},150);return()=>clearTimeout(j)}},[Ae,h.length,o]),Z.useEffect(()=>{O!=null&&O.total&&!o&&setTimeout(()=>La($e),100)},[O==null?void 0:O.total,o]),Z.useEffect(()=>{l&&sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),l)},[l,e]);const[us,ji]=Z.useState(!1),[Ho,Dt]=Z.useState(!1),[to,rr]=Z.useState(null),Ro=async j=>{const te=nr();if(Ge(!1),j&&h.length>1)try{(await fetch(`${Ti}/api/wordpress/userRating`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sessionId:te,userRating:j,nameSpace:e})})).ok||console.error("Error submitting rating")}catch(he){console.error("Error submitting rating:",he)}setTimeout(()=>{Dt(!1),_e(!1,"close_button_clicked")},1e3)},po=j=>{y(!0),Re.forEach(he=>{I(he.id,he.quantity)}),bt(!0),window.DebalesChat.track(tn.ADD_BULK_ITEM,{products:Re,message:j});const te=[...h,{text:"πŸŽ‰ Bulk items added to cart successfully.",leading_queries:["Get GST Invoice for the order","Explore more products"],conversationId:j,isBot:!0}];m(te),x(te),d(j),Ct([]),y(!1)},qn=()=>{var j;switch(e){case"minature":case"bodytales":case"imemyselfcare-com":if(window.triggerGokwikCustomCheckout)return window.triggerGokwikCustomCheckout(),!0;break;case"athflex":if((j=window.shiprocketCheckoutEvents)!=null&&j.buyCart)return window.shiprocketCheckoutEvents.buyCart(),!0;break;case"www":if(window.openRzpCheckout)return window.openRzpCheckout(),!0;break;default:return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1}return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1},ua=async j=>{j.preventDefault(),window.DebalesChat.track(tn.CHECKOUT_CLICKED,{chatId:nr()+e,cartValue:Number(O==null?void 0:O.total),cart:O}),N({dbls_method:"checkout_clicked"}),qn()&&_e(!1,"checkout_clicked")};Z.useEffect(()=>{const j=gE(w);ne(te=>[...j.filter(ke=>!te.some(we=>we.question===ke.question))])},[w]),Z.useEffect(()=>{const j=ke=>{const we=ke.detail.formId;switch(ke.detail.type){case"open":case"embedOpen":setTimeout(()=>{const $t=te(we);$t&&re($t)},800);break;case"close":yt&&(t==null?void 0:t.KlaviyoFormIntegration)===!0&&setTimeout(()=>{_e(!0,"klaviyo_form_closed"),ve(we),r({message:yt,fromKlaviyo:!0})},1e4);break}},te=ke=>{const we=document.querySelector(`[data-testid="klaviyo-form-${ke}"]`);if(console.log(`formElement text ${ke} =>`,we==null?void 0:we.innerText,we==null?void 0:we.textContent),we instanceof HTMLElement){const Je=we.innerText||we.textContent;if(Je)return console.log("Found form text:",Je),`=> Klaviyo form content:
4489
4489
 
4490
4490
  `+Je+`
4491
4491
 
4492
- => User Action: Klaviyo form closed`}return""},he=ke=>{ke instanceof CustomEvent&&j(ke)};return window.addEventListener("klaviyoForms",he),()=>{window.removeEventListener("klaviyoForms",he)}},[yt,t,r]),Z.useEffect(()=>{const j=$e.current;return Ae&&j?(j.addEventListener("scroll",br),()=>{j&&j.removeEventListener("scroll",br)}):()=>{}},[Ae,br]);const[Oi,pr]=Z.useState(!1),Br=Q==="Highest"?"120px":Q==="Higher"?"60px":"15px",ca=async()=>{try{const j=await fetch(`${Ti}/api/wordpress/support`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatid:nr()+e,nameSpace:e,userName:Mt.name,userEmail:Mt.email,userMessage:Mt.message,tag:"support"})});if(j.ok){const te=`support-confirm-${Date.now()}`;m(he=>[...he,{text:"Thanks for reaching out! Our support team has received your request and will get back to you within 24 hours.<br>In the meantime, feel free to continue chatting with me - I'll do my best to help!",isBot:!0,leading_queries:Qt,conversationId:te}]),d(te),xe(he=>({...he,leadingQueries:!0})),gn([]),console.log("Connected to support with existing user info:",jo())}else{const te=await j.json();console.error("Failed to connect to support:",te),m(he=>[...he,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}}catch{m(te=>[...te,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}},Kr=()=>{if(Ie(e)){const ke=Fp("https://test.thecollective.in/content/customersupport");ke.isValid&&(t!=null&&t.shopifyShopDomain&&(ke.url.hostname=t==null?void 0:t.shopifyShopDomain),window.open(Os(ke.url.toString()),"_blank"));return}const j=jo();let te=[];const he=h[h.length-1];he!=null&&he.leading_queries&&he.leading_queries.length>0?te=he.leading_queries:h.length<=1&&(te=P.flatMap(ke=>Array.isArray(ke)?ke.map(we=>we.question):[ke.question]).slice(0,4)),gn(te),j&&j.name&&j.email&&en({name:j==null?void 0:j.name,email:j==null?void 0:j.email,message:""}),m(ke=>[...ke,{text:"Please provide your name, email and message to connect with support.",isBot:!0}]),Rt(!0)},ot=async j=>{j.preventDefault();const te={name:"",email:"",message:""};let he=!0;const ke=Mt.name.trim(),we=Mt.message.trim();ke||(te.name="Name cannot be empty or just whitespace.",he=!1),(!Mt.email||!zm.isEmail(Mt.email))&&(te.email="Please enter a valid email address.",he=!1),we||(te.message="Message cannot be empty or just whitespace.",he=!1),Kt(te),he&&(sf({name:ke,email:Mt.email}),Rt(!1),m(Je=>Je.slice(0,-1)),await ca())},[Oe,at]=Z.useState({});return Z.useEffect(()=>{hr&&(h.forEach((j,te)=>{if(!j.isBot)return;const he=$p(j.text);if(!(te in Oe)||Oe[te]<he.length){let ke;const we=Je=>{Je<he.length&&(ke=setTimeout(()=>{at($t=>({...$t,[te]:Je+1})),we(Je+1)},ho))};return te in Oe?we(Oe[te]):(at(Je=>({...Je,[te]:1})),we(1)),()=>clearTimeout(ke)}}),at(j=>{const te={};return h.forEach((he,ke)=>{j[ke]!==void 0&&(te[ke]=j[ke])}),te}))},[h,hr]),!t||t.show_bot===!1||a?null:M.jsxs(Jw,{theme:pE(t,e),children:[M.jsx("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),M.jsx("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",rel:"stylesheet"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap",rel:"stylesheet"}),M.jsx(dge,{}),M.jsx(q0e,{$topOffset:Br,$isLeft:W,children:M.jsxs(uge,{$isLeft:W,$removeLogoBackground:t.removeLogoBackground,children:[!Ae&&P.length>0&&P[U]&&se&&M.jsx(cge,{className:Ce?"visible":"",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Br,$isLeft:W,style:{display:"flex",flexDirection:W?"row":"row-reverse",alignItems:"center",marginRight:W?"0px":Et?"10px":"5px",marginTop:Et?"0px":"10px",left:W?"24px":"auto",right:W?"auto":"24px",opacity:Ce?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length>0&&P[U]&&(()=>{const j=P[U];return M.jsx(fge,{children:M.jsx(j0e,{messages:[{question:j.question,isHighlighted:j.isHighlighted??!1,show_for:(ee==null?void 0:ee.show_for)||4e3,hide_timing:(ee==null?void 0:ee.hide_timing)||4e3}],botId:e,uiData:t,isLeft:W,onClose:()=>{mt(te=>{const he=new Set(te);return he.add(j.question),he})},onClick:()=>{const te=j;_e(!0,"suggested_question_clicked"),mt(he=>{const ke=new Set(he);return ke.add(te.question),ke}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:te}),E?(ln(!1),xr(!0),A(!0),R(te)):(ln(!1),xr(!0),r({message:te.Follow_up_Question??te.question,answer:te.answer,products:te.products,fromKlaviyo:!1,leading_queries:te.leading_queries,messType:"suggested_question"}))}})},j.question)})()}),M.jsx(G0e,{$topOffset:Br,$removeLogoBackground:t.removeLogoBackground,style:{display:Ae?"none":"inline-flex"},children:M.jsxs(V0e,{$backgroundColor:t.removeLogoBackground?"transparent":t.backgroundColor||"#fff",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Br,$showAnimation:t.enableChatButtonBackgroundAnimation,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",id:"debales-chat-button","data-testid":"debales-chat-button",onClick:()=>{if(window.DebalesChat.track(tn.CHAT_BUTTON_CLICKED),_e(!Ae,"chat_button_clicked"),!Ae){const j=_();j.length>0?(m(j),ln(!1),xr(!0)):(ln(!0),xr(!1),setTimeout(()=>{ln(!1),xr(!0);const te={text:(t==null?void 0:t.initialMessage)||"Hi, I am an AI chatbot, how can I help you today?",isBot:!0};m([te])},(ee==null?void 0:ee.showing_delay)||2e3))}},"aria-label":"Chat",style:{display:Ae?"none":"inline-flex"},children:[M.jsx(Y0e,{$botId:e,$removeLogoBackground:t.removeLogoBackground,"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),(P==null?void 0:P.length)>0&&!Ae&&de&&!se&&M.jsx("div",{style:{position:"absolute",top:"-5px",right:"-5px",backgroundColor:"#f44336",color:"white",borderRadius:"50%",width:"20px",height:"20px",display:"flex",justifyContent:"center",alignItems:"center",fontSize:"12px",fontWeight:"bold",zIndex:2,opacity:de?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length})]})})]})}),Ae&&vw.createPortal(M.jsx(M.Fragment,{children:M.jsxs(W0e,{$backgroundColor:t.backgroundColor||"#fff",$fullScreenOnMobile:t.fullScreenOnMobile,$headerFontColor:t.headerFontColor||"#1C1C1C",$isLeft:W,$topOffset:Br,$mobileDisplayMode:t.mobileDisplayMode,$isVisible:rt,"data-testid":"debales-chat-container",children:[M.jsxs(ege,{$backgroundColor:Ie(e)?t.backgroundColor:t.botBackgroundColor||"#fff",style:{color:t.headerFontColor},children:[M.jsx("div",{style:{flexGrow:.1,display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden",marginRight:"8px",gap:"10px"},children:Ie(e)?M.jsxs(M.Fragment,{children:[M.jsx(gH,{"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),Ie(e)?M.jsx("div",{children:M.jsx("img",{src:yk,alt:"Chat Bot Icon",style:{height:"36px"}})}):M.jsxs(Z0e,{$botNameColor:t.headerFontColor,children:[M.jsxs("div",{style:{fontWeight:"700",wordBreak:"break-word"},children:[t.chatbotName,e==="catch-org-ai"&&M.jsx(K0e,{$backgroundColor:t.callToActionBackgroundColor,$fontColor:t.callToActionFontColor,children:"Beta"})]}),M.jsx(Q0e,{})]})]}):M.jsx(X0e,{children:M.jsxs(J0e,{children:[M.jsx(gH,{src:t.bot_logo,alt:"Chat Bot Icon"}),M.jsx("span",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",display:"inline-block",maxWidth:"22ch"},children:t.chatbotName})]})})}),M.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"8px",marginLeft:"auto",flexShrink:0},children:[M.jsxs(hge,{children:[M.jsx(mH,{$iconBG:t.backgroundColor,onClick:Kr,"aria-label":"Support","data-testid":"debales-support-button",children:M.jsx(Tk,{color:t.headerFontColor})}),M.jsx(_H,{children:"Click to chat with a Live Support Agent now."})]}),M.jsx(mH,{$iconBG:t.backgroundColor,onClick:()=>{_t?Dt(!0):_e(!1,"close_button_clicked")},id:"debales-minimize-button","data-testid":"debales-minimize-button","aria-label":"Minimize",children:M.jsx(Zm,{botNameColor:t.headerFontColor})})]}),M.jsx(bge,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}})]}),M.jsxs(rge,{$backgroundColor:t.botBackgroundColor||"#fff",$mobileDisplayMode:t.mobileDisplayMode,children:[Oi&&((Me=(ce=t.pluginConfig)==null?void 0:ce.collectedUserInfo)==null?void 0:Me.discount)&&M.jsx(Nk,{discount:t.pluginConfig.collectedUserInfo.discount,uiData:t,onClose:()=>{pr(!1),window.DebalesChat.track(tn.DISCOUNT_VIEWED,{discount:t.pluginConfig.collectedUserInfo.discount})}}),M.jsx(kk,{}),M.jsx(Pk,{uidata:t,product:to,showModel:us,setShowModel:ji,onVariantSelect:j=>{I(j.id,1),bt(!0),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:j.title,price:Number(j.price),link:`https://${t.shopifyShopDomain}/variants/${j.id}`,message:l,chatId:nr()+e})},botId:e}),Ho&&M.jsx(zk,{setShowExitModal:Dt,handleCloseChatbot:Ro,chatId:nr()+e}),M.jsxs(tge,{id:"debales-conversation-group",$botBackgroundColor:t.botBackgroundColor||"#fff",ref:$e,$mobileDisplayMode:t.mobileDisplayMode,children:[M.jsx(yge,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}}),M.jsxs(nge,{children:[hr&&h.map((j,te)=>{const he=j.isBot,ke=$p(j.text);return j.hideConfirmation?null:M.jsxs(Z.Fragment,{children:[he&&M.jsxs(vH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff","data-testid":"debales-ai-message-container",children:[M.jsx("img",{src:he?t.bot_logo:t.userMessage_logo,alt:"Chat User Icon",style:{marginLeft:"8px"}}),M.jsxs(bH,{children:[ke.slice(0,Oe[te]||0).map((we,Je)=>M.jsx("div",{children:M.jsx(Ri,{isBot:he,children:M.jsx(bd,{remarkPlugins:[Mw,vE],children:we})})},Je)),j.collections&&l===j.conversationId&&Y.collections&&M.jsx(Lk,{message:j,botId:e,uidata:t,onSendMessage:r,loading:p}),j.products&&l===j.conversationId&&Y.products&&M.jsx(Uk,{message:j,botId:e,uidata:t,onSendMessage:r,loading:p,storeMetaData:n,platform:V,setShowVariantModel:ji,setSelectedProduct:rr,setCartVersion:Ee}),o&&M.jsx(G8,{children:M.jsx(Nx,{onClick:()=>{window._klOnsite&&(window._klOnsite.push(["openForm",le]),_e(!1,"klaviyo_grab_deal_button"))},children:"πŸš€ Grab Deal Now!"})}),O&&O.itemCount>0&&l===j.conversationId&&Y.cartSummary&&dt&&M.jsx(Mk,{onCheckout:ua,onKeepShopping:()=>{bt(!1)}}),Re&&Re.length>0&&l===j.conversationId&&Y.bulkItems&&M.jsx(mk,{onClick:()=>po(j.conversationId),children:"Add Bulk Items to Cart"}),k&&h.indexOf(j)===h.length-1&&M.jsx(M.Fragment,{children:M.jsx(jk,{setShowModel:we=>{var $t,an;const Je=typeof we=="function"?we(k):we;A(Je),!Je&&((an=($t=t.pluginConfig)==null?void 0:$t.collectedUserInfo)!=null&&an.discount)&&pr(!0)},inChat:!0,showFormInstructions:!1})}),ct&&h.indexOf(j)===h.length-1&&M.jsxs(pge,{onSubmit:ot,noValidate:!0,"data-testid":"debales-support-form",children:[Ie(e)?M.jsxs(M.Fragment,{children:[M.jsx(ru,{label:"Name",name:"name",type:"text",value:Mt.name,onChange:we=>en(Je=>({...Je,name:we.target.value})),required:!0,error:pt.name,isCollectiveBot:!0}),M.jsx(ru,{label:"Email",name:"email",type:"email",value:Mt.email,onChange:we=>en(Je=>({...Je,email:we.target.value})),required:!0,error:pt.email,isCollectiveBot:!0}),M.jsx(Fk,{label:"Message",name:"message",value:Mt.message,onChange:we=>en(Je=>({...Je,message:we.target.value})),required:!0,error:pt.message,rows:4,isCollectiveBot:!0})]}):M.jsxs(M.Fragment,{children:[M.jsxs(V8,{children:[M.jsxs(Y8,{children:["Name",M.jsx("span",{children:"*"})]}),M.jsx(SH,{type:"text",required:!0,value:Mt.name,onChange:we=>en(Je=>({...Je,name:we.target.value})),placeholder:"John"}),pt.name&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.name})]}),M.jsxs(V8,{children:[M.jsxs(Y8,{children:["Email",M.jsx("span",{children:"*"})]}),M.jsx(SH,{type:"email",required:!0,value:Mt.email,onChange:we=>en(Je=>({...Je,email:we.target.value})),placeholder:"olivia@untitledui.com"}),pt.email&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.email})]}),M.jsxs(V8,{children:[M.jsxs(Y8,{children:["Message",M.jsx("span",{children:"*"})]}),M.jsx(gge,{required:!0,value:Mt.message,onChange:we=>en(Je=>({...Je,message:we.target.value})),placeholder:"I need help with..."}),pt.message&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.message})]})]}),M.jsx(vge,{children:M.jsx(mge,{type:"submit",children:"Submit"})})]}),St&&!p&&l===j.conversationId&&M.jsx(Ri,{isBot:he,children:M.jsx(Ds,{loading:St,loadingPhrases:["🎨 Loading","✨ Almost","πŸš€ Ready"]})})]})]}),!he&&M.jsx(sge,{$fontColor:t.userFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:M.jsx(Ri,{isBot:!!he,children:M.jsx(bd,{children:j.text})})}),h.length==1&&te==0&&!k&&M.jsx(G8,{children:it.leadingQueries?M.jsx(Ri,{isBot:!0,children:M.jsx(Ds,{loading:it.leadingQueries})}):P.map((we,Je)=>M.jsxs(xH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor,opacity:lt.has(we.question)?.5:1},onClick:()=>{E?(A(!0),R({question:we.question,answer:we.answer,products:we.products,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:we.question,answer:we.answer,products:we.products,messType:"leading_query"}),mt($t=>{const an=new Set($t);return an.add(we.question),an}),window.DebalesChat.track(tn.INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED,{question:we.question})},disabled:p,$disabled:p,children:[we.question,M.jsx(yH,{color:t.callToActionFontColor})]},Je))}),j.leading_queries&&j.leading_queries.length>0&&l===j.conversationId&&Y.leadingQueries&&!o&&!k&&M.jsx(G8,{children:j.leading_queries.map((we,Je)=>M.jsxs(xH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{E?(A(!0),R({question:we,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:we,messType:"leading_query"}),window.DebalesChat.track(tn.LEADING_QUERY_CLICKED,{query:we})},disabled:p,$disabled:p,children:[we,M.jsx(yH,{color:t.callToActionFontColor})]},Je))})]},te)}),(p||qt)&&M.jsxs(vH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:[M.jsx("img",{src:t.bot_logo,alt:"Chat User Icon"}),M.jsx(bH,{children:M.jsx(Ri,{isBot:!0,children:M.jsx("div",{style:{display:"flex",alignItems:"center",gap:"4px",animation:"fadeIn 0.3s ease-in-out"},children:M.jsx(Ds,{loading:p||qt})})})})]})]}),M.jsx(xge,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:yn?1:0}})]}),M.jsxs("div",{className:"debales-footer-container",style:{width:"100%",backgroundColor:t.botBackgroundColor||"#fff",color:t.fontColor||"#000"},children:[(e==="catch-org-ai"||e==="letsgo-catch")&&M.jsx(age,{children:M.jsx("span",{children:`"${t.chatbotName}" can make mistakes.`})}),M.jsx("div",{children:M.jsx(Hk,{disabled:p,inputState:!1})}),(t.debales_branding??!0)&&M.jsxs(ige,{href:"https://debales.ai/?open=true",target:"_blank",title:"debales-link",style:{color:t.fontColor?t.fontColor:"fff",marginTop:e==="catch-org-ai"?"0":"9px"},children:[M.jsx("p",{children:"Powered by"}),M.jsxs(oge,{children:[M.jsx("img",{src:`${Ti}/images/debales_logo_d.png`,alt:"Debales logo"}),M.jsx("p",{children:"DEBALES"})]})]})]})]})]})}),z.shadowRoot)]})},Sge=ae.p`
4492
+ => User Action: Klaviyo form closed`}return""},he=ke=>{ke instanceof CustomEvent&&j(ke)};return window.addEventListener("klaviyoForms",he),()=>{window.removeEventListener("klaviyoForms",he)}},[yt,t,r]),Z.useEffect(()=>{const j=$e.current;return Ae&&j?(j.addEventListener("scroll",br),()=>{j&&j.removeEventListener("scroll",br)}):()=>{}},[Ae,br]);const[Oi,pr]=Z.useState(!1),Br=Q==="Highest"?"120px":Q==="Higher"?"60px":"15px",ca=async()=>{try{const j=await fetch(`${Ti}/api/wordpress/support`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatid:nr()+e,nameSpace:e,userName:Mt.name,userEmail:Mt.email,userMessage:Mt.message,tag:"support"})});if(j.ok){const te=`support-confirm-${Date.now()}`;m(he=>[...he,{text:"Thanks for reaching out! Our support team has received your request and will get back to you within 24 hours.<br>In the meantime, feel free to continue chatting with me - I'll do my best to help!",isBot:!0,leading_queries:Qt,conversationId:te}]),d(te),xe(he=>({...he,leadingQueries:!0})),gn([]),console.log("Connected to support with existing user info:",jo())}else{const te=await j.json();console.error("Failed to connect to support:",te),m(he=>[...he,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}}catch{m(te=>[...te,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}},Kr=()=>{if(Me(e)){const ke=Fp("https://test.thecollective.in/content/customersupport");ke.isValid&&(t!=null&&t.shopifyShopDomain&&(ke.url.hostname=t==null?void 0:t.shopifyShopDomain),window.open(Os(ke.url.toString()),"_blank"));return}const j=jo();let te=[];const he=h[h.length-1];he!=null&&he.leading_queries&&he.leading_queries.length>0?te=he.leading_queries:h.length<=1&&(te=P.flatMap(ke=>Array.isArray(ke)?ke.map(we=>we.question):[ke.question]).slice(0,4)),gn(te),j&&j.name&&j.email&&en({name:j==null?void 0:j.name,email:j==null?void 0:j.email,message:""}),m(ke=>[...ke,{text:"Please provide your name, email and message to connect with support.",isBot:!0}]),Rt(!0)},ot=async j=>{j.preventDefault();const te={name:"",email:"",message:""};let he=!0;const ke=Mt.name.trim(),we=Mt.message.trim();ke||(te.name="Name cannot be empty or just whitespace.",he=!1),(!Mt.email||!zm.isEmail(Mt.email))&&(te.email="Please enter a valid email address.",he=!1),we||(te.message="Message cannot be empty or just whitespace.",he=!1),Kt(te),he&&(sf({name:ke,email:Mt.email}),Rt(!1),m(Je=>Je.slice(0,-1)),await ca())},[Oe,at]=Z.useState({});return Z.useEffect(()=>{hr&&(h.forEach((j,te)=>{if(!j.isBot)return;const he=$p(j.text);if(!(te in Oe)||Oe[te]<he.length){let ke;const we=Je=>{Je<he.length&&(ke=setTimeout(()=>{at($t=>({...$t,[te]:Je+1})),we(Je+1)},ho))};return te in Oe?we(Oe[te]):(at(Je=>({...Je,[te]:1})),we(1)),()=>clearTimeout(ke)}}),at(j=>{const te={};return h.forEach((he,ke)=>{j[ke]!==void 0&&(te[ke]=j[ke])}),te}))},[h,hr]),!t||t.show_bot===!1||a?null:M.jsxs(Jw,{theme:pE(t,e),children:[M.jsx("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),M.jsx("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",rel:"stylesheet"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap",rel:"stylesheet"}),M.jsx(dge,{}),M.jsx(q0e,{$topOffset:Br,$isLeft:W,children:M.jsxs(uge,{$isLeft:W,$removeLogoBackground:t.removeLogoBackground,children:[!Ae&&P.length>0&&P[U]&&se&&M.jsx(cge,{className:Ce?"visible":"",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Br,$isLeft:W,style:{display:"flex",flexDirection:W?"row":"row-reverse",alignItems:"center",marginRight:W?"0px":Et?"10px":"5px",marginTop:Et?"0px":"10px",left:W?"24px":"auto",right:W?"auto":"24px",opacity:Ce?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length>0&&P[U]&&(()=>{const j=P[U];return M.jsx(fge,{children:M.jsx(j0e,{messages:[{question:j.question,isHighlighted:j.isHighlighted??!1,show_for:(ee==null?void 0:ee.show_for)||4e3,hide_timing:(ee==null?void 0:ee.hide_timing)||4e3}],botId:e,uiData:t,isLeft:W,onClose:()=>{mt(te=>{const he=new Set(te);return he.add(j.question),he})},onClick:()=>{const te=j;_e(!0,"suggested_question_clicked"),mt(he=>{const ke=new Set(he);return ke.add(te.question),ke}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:te}),E?(ln(!1),xr(!0),A(!0),R(te)):(ln(!1),xr(!0),r({message:te.Follow_up_Question??te.question,answer:te.answer,products:te.products,fromKlaviyo:!1,leading_queries:te.leading_queries,messType:"suggested_question"}))}})},j.question)})()}),M.jsx(G0e,{$topOffset:Br,$removeLogoBackground:t.removeLogoBackground,style:{display:Ae?"none":"inline-flex"},children:M.jsxs(V0e,{$backgroundColor:t.removeLogoBackground?"transparent":t.backgroundColor||"#fff",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Br,$showAnimation:t.enableChatButtonBackgroundAnimation,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",id:"debales-chat-button","data-testid":"debales-chat-button",onClick:()=>{if(window.DebalesChat.track(tn.CHAT_BUTTON_CLICKED),_e(!Ae,"chat_button_clicked"),!Ae){const j=_();j.length>0?(m(j),ln(!1),xr(!0)):(ln(!0),xr(!1),setTimeout(()=>{ln(!1),xr(!0);const te={text:(t==null?void 0:t.initialMessage)||"Hi, I am an AI chatbot, how can I help you today?",isBot:!0};m([te])},(ee==null?void 0:ee.showing_delay)||2e3))}},"aria-label":"Chat",style:{display:Ae?"none":"inline-flex"},children:[M.jsx(Y0e,{$botId:e,$removeLogoBackground:t.removeLogoBackground,"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),(P==null?void 0:P.length)>0&&!Ae&&de&&!se&&M.jsx("div",{style:{position:"absolute",top:"-5px",right:"-5px",backgroundColor:"#f44336",color:"white",borderRadius:"50%",width:"20px",height:"20px",display:"flex",justifyContent:"center",alignItems:"center",fontSize:"12px",fontWeight:"bold",zIndex:2,opacity:de?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length})]})})]})}),Ae&&vw.createPortal(M.jsx(M.Fragment,{children:M.jsxs(W0e,{$backgroundColor:t.backgroundColor||"#fff",$fullScreenOnMobile:t.fullScreenOnMobile,$headerFontColor:t.headerFontColor||"#1C1C1C",$isLeft:W,$topOffset:Br,$mobileDisplayMode:t.mobileDisplayMode,$isVisible:rt,"data-testid":"debales-chat-container",children:[M.jsxs(ege,{$backgroundColor:Me(e)?t.backgroundColor:t.botBackgroundColor||"#fff",style:{color:t.headerFontColor},children:[M.jsx("div",{style:{flexGrow:.1,display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden",marginRight:"8px",gap:"10px"},children:Me(e)?M.jsxs(M.Fragment,{children:[M.jsx(gH,{"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),Me(e)?M.jsx("div",{children:M.jsx("img",{src:yk,alt:"Chat Bot Icon",style:{height:"36px"}})}):M.jsxs(Z0e,{$botNameColor:t.headerFontColor,children:[M.jsxs("div",{style:{fontWeight:"700",wordBreak:"break-word"},children:[t.chatbotName,e==="catch-org-ai"&&M.jsx(K0e,{$backgroundColor:t.callToActionBackgroundColor,$fontColor:t.callToActionFontColor,children:"Beta"})]}),M.jsx(Q0e,{})]})]}):M.jsx(X0e,{children:M.jsxs(J0e,{children:[M.jsx(gH,{src:t.bot_logo,alt:"Chat Bot Icon"}),M.jsx("span",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",display:"inline-block",maxWidth:"22ch"},children:t.chatbotName})]})})}),M.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"8px",marginLeft:"auto",flexShrink:0},children:[M.jsxs(hge,{children:[M.jsx(mH,{$iconBG:t.backgroundColor,onClick:Kr,"aria-label":"Support","data-testid":"debales-support-button",children:M.jsx(Tk,{color:t.headerFontColor})}),M.jsx(_H,{children:"Click to chat with a Live Support Agent now."})]}),M.jsx(mH,{$iconBG:t.backgroundColor,onClick:()=>{_t?Dt(!0):_e(!1,"close_button_clicked")},id:"debales-minimize-button","data-testid":"debales-minimize-button","aria-label":"Minimize",children:M.jsx(Zm,{botNameColor:t.headerFontColor})})]}),M.jsx(bge,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}})]}),M.jsxs(rge,{$backgroundColor:t.botBackgroundColor||"#fff",$mobileDisplayMode:t.mobileDisplayMode,children:[Oi&&((Ie=(ce=t.pluginConfig)==null?void 0:ce.collectedUserInfo)==null?void 0:Ie.discount)&&M.jsx(Nk,{discount:t.pluginConfig.collectedUserInfo.discount,uiData:t,onClose:()=>{pr(!1),window.DebalesChat.track(tn.DISCOUNT_VIEWED,{discount:t.pluginConfig.collectedUserInfo.discount})}}),M.jsx(kk,{}),M.jsx(Pk,{uidata:t,product:to,showModel:us,setShowModel:ji,onVariantSelect:j=>{I(j.id,1),bt(!0),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:j.title,price:Number(j.price),link:`https://${t.shopifyShopDomain}/variants/${j.id}`,message:l,chatId:nr()+e})},botId:e}),Ho&&M.jsx(zk,{setShowExitModal:Dt,handleCloseChatbot:Ro,chatId:nr()+e}),M.jsxs(tge,{id:"debales-conversation-group",$botBackgroundColor:t.botBackgroundColor||"#fff",ref:$e,$mobileDisplayMode:t.mobileDisplayMode,children:[M.jsx(yge,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}}),M.jsxs(nge,{children:[hr&&h.map((j,te)=>{const he=j.isBot,ke=$p(j.text);return j.hideConfirmation?null:M.jsxs(Z.Fragment,{children:[he&&M.jsxs(vH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff","data-testid":"debales-ai-message-container",children:[M.jsx("img",{src:he?t.bot_logo:t.userMessage_logo,alt:"Chat User Icon",style:{marginLeft:"8px"}}),M.jsxs(bH,{children:[ke.slice(0,Oe[te]||0).map((we,Je)=>M.jsx("div",{children:M.jsx(Ri,{isBot:he,children:M.jsx(bd,{remarkPlugins:[Mw,vE],children:we})})},Je)),j.collections&&l===j.conversationId&&Y.collections&&M.jsx(Lk,{message:j,botId:e,uidata:t,onSendMessage:r,loading:p}),j.products&&l===j.conversationId&&Y.products&&M.jsx(Uk,{message:j,botId:e,uidata:t,onSendMessage:r,loading:p,storeMetaData:n,platform:V,setShowVariantModel:ji,setSelectedProduct:rr,setCartVersion:Ee}),o&&M.jsx(G8,{children:M.jsx(Nx,{onClick:()=>{window._klOnsite&&(window._klOnsite.push(["openForm",le]),_e(!1,"klaviyo_grab_deal_button"))},children:"πŸš€ Grab Deal Now!"})}),O&&O.itemCount>0&&l===j.conversationId&&Y.cartSummary&&dt&&M.jsx(Mk,{onCheckout:ua,onKeepShopping:()=>{bt(!1)}}),Re&&Re.length>0&&l===j.conversationId&&Y.bulkItems&&M.jsx(mk,{onClick:()=>po(j.conversationId),children:"Add Bulk Items to Cart"}),k&&h.indexOf(j)===h.length-1&&M.jsx(M.Fragment,{children:M.jsx(jk,{setShowModel:we=>{var $t,an;const Je=typeof we=="function"?we(k):we;A(Je),!Je&&((an=($t=t.pluginConfig)==null?void 0:$t.collectedUserInfo)!=null&&an.discount)&&pr(!0)},inChat:!0,showFormInstructions:!1})}),ct&&h.indexOf(j)===h.length-1&&M.jsxs(pge,{onSubmit:ot,noValidate:!0,"data-testid":"debales-support-form",children:[Me(e)?M.jsxs(M.Fragment,{children:[M.jsx(ru,{label:"Name",name:"name",type:"text",value:Mt.name,onChange:we=>en(Je=>({...Je,name:we.target.value})),required:!0,error:pt.name,isCollectiveBot:!0}),M.jsx(ru,{label:"Email",name:"email",type:"email",value:Mt.email,onChange:we=>en(Je=>({...Je,email:we.target.value})),required:!0,error:pt.email,isCollectiveBot:!0}),M.jsx(Fk,{label:"Message",name:"message",value:Mt.message,onChange:we=>en(Je=>({...Je,message:we.target.value})),required:!0,error:pt.message,rows:4,isCollectiveBot:!0})]}):M.jsxs(M.Fragment,{children:[M.jsxs(V8,{children:[M.jsxs(Y8,{children:["Name",M.jsx("span",{children:"*"})]}),M.jsx(SH,{type:"text",required:!0,value:Mt.name,onChange:we=>en(Je=>({...Je,name:we.target.value})),placeholder:"John"}),pt.name&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.name})]}),M.jsxs(V8,{children:[M.jsxs(Y8,{children:["Email",M.jsx("span",{children:"*"})]}),M.jsx(SH,{type:"email",required:!0,value:Mt.email,onChange:we=>en(Je=>({...Je,email:we.target.value})),placeholder:"olivia@untitledui.com"}),pt.email&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.email})]}),M.jsxs(V8,{children:[M.jsxs(Y8,{children:["Message",M.jsx("span",{children:"*"})]}),M.jsx(gge,{required:!0,value:Mt.message,onChange:we=>en(Je=>({...Je,message:we.target.value})),placeholder:"I need help with..."}),pt.message&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:pt.message})]})]}),M.jsx(vge,{children:M.jsx(mge,{type:"submit",children:"Submit"})})]}),St&&!p&&l===j.conversationId&&M.jsx(Ri,{isBot:he,children:M.jsx(Ds,{loading:St,loadingPhrases:["🎨 Loading","✨ Almost","πŸš€ Ready"]})})]})]}),!he&&M.jsx(sge,{$fontColor:t.userFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:M.jsx(Ri,{isBot:!!he,children:M.jsx(bd,{children:j.text})})}),h.length==1&&te==0&&!k&&M.jsx(G8,{children:it.leadingQueries?M.jsx(Ri,{isBot:!0,children:M.jsx(Ds,{loading:it.leadingQueries})}):P.map((we,Je)=>M.jsxs(xH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor,opacity:lt.has(we.question)?.5:1},onClick:()=>{E?(A(!0),R({question:we.question,answer:we.answer,products:we.products,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:we.question,answer:we.answer,products:we.products,messType:"leading_query"}),mt($t=>{const an=new Set($t);return an.add(we.question),an}),window.DebalesChat.track(tn.INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED,{question:we.question})},disabled:p,$disabled:p,children:[we.question,M.jsx(yH,{color:t.callToActionFontColor})]},Je))}),j.leading_queries&&j.leading_queries.length>0&&l===j.conversationId&&Y.leadingQueries&&!o&&!k&&M.jsx(G8,{children:j.leading_queries.map((we,Je)=>M.jsxs(xH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{E?(A(!0),R({question:we,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:we,messType:"leading_query"}),window.DebalesChat.track(tn.LEADING_QUERY_CLICKED,{query:we})},disabled:p,$disabled:p,children:[we,M.jsx(yH,{color:t.callToActionFontColor})]},Je))})]},te)}),(p||qt)&&M.jsxs(vH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:[M.jsx("img",{src:t.bot_logo,alt:"Chat User Icon"}),M.jsx(bH,{children:M.jsx(Ri,{isBot:!0,children:M.jsx("div",{style:{display:"flex",alignItems:"center",gap:"4px",animation:"fadeIn 0.3s ease-in-out"},children:M.jsx(Ds,{loading:p||qt})})})})]})]}),M.jsx(xge,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:yn?1:0}})]}),M.jsxs("div",{className:"debales-footer-container",style:{width:"100%",backgroundColor:t.botBackgroundColor||"#fff",color:t.fontColor||"#000"},children:[(e==="catch-org-ai"||e==="letsgo-catch")&&M.jsx(age,{children:M.jsx("span",{children:`"${t.chatbotName}" can make mistakes.`})}),M.jsx("div",{children:M.jsx(Hk,{disabled:p,inputState:!1})}),(t.debales_branding??!0)&&M.jsxs(ige,{href:"https://debales.ai/?open=true",target:"_blank",title:"debales-link",style:{color:t.fontColor?t.fontColor:"fff",marginTop:e==="catch-org-ai"?"0":"9px"},children:[M.jsx("p",{children:"Powered by"}),M.jsxs(oge,{children:[M.jsx("img",{src:`${Ti}/images/debales_logo_d.png`,alt:"Debales logo"}),M.jsx("p",{children:"DEBALES"})]})]})]})]})]})}),z.shadowRoot)]})},Sge=ae.p`
4493
4493
  margin: 0;
4494
4494
  font-size: 16px;
4495
4495
  text-align: left;
@@ -4711,7 +4711,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4711
4711
  z-index: 2147483647;
4712
4712
  background-color: ${e=>e.$backgroundColor};
4713
4713
  color: ${e=>e.$headerFontColor};
4714
- border-radius: ${e=>Ie(e.theme.botId)?"0":"16px"} !important;
4714
+ border-radius: ${e=>Me(e.theme.botId)?"0":"16px"} !important;
4715
4715
  padding: 0 !important;
4716
4716
  margin: 0 !important;
4717
4717
  display: flex;
@@ -4737,7 +4737,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4737
4737
  left: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$isLeft?"16px":"auto":e.$fullScreenOnMobile?"0":e.$isLeft?"16px":"auto"};
4738
4738
  right: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$isLeft?"auto":"16px":e.$fullScreenOnMobile?"0":e.$isLeft?"auto":"16px"};
4739
4739
  bottom: ${e=>e.$mobileDisplayMode==="full-screen"||e.$mobileDisplayMode==="half-screen"?"0":e.$mobileDisplayMode==="normal"?e.$topOffset||"16px":e.$fullScreenOnMobile?"0":e.$topOffset||"16px"};
4740
- border-radius: ${e=>Ie(e.theme.botId)||e.$mobileDisplayMode==="full-screen"?"0":e.$mobileDisplayMode==="half-screen"?"16px 16px 0 0":"16px"} !important;
4740
+ border-radius: ${e=>Me(e.theme.botId)||e.$mobileDisplayMode==="full-screen"?"0":e.$mobileDisplayMode==="half-screen"?"16px 16px 0 0":"16px"} !important;
4741
4741
  overflow: hidden;
4742
4742
  touch-action: manipulation;
4743
4743
  /* Apply proper touch action for mobile modes to allow content scrolling */
@@ -4760,14 +4760,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4760
4760
  display: flex;
4761
4761
  align-items: center;
4762
4762
  padding: 2px;
4763
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
4763
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
4764
4764
  background: conic-gradient(#0ead3f, #00b200, #1ca77e, #379bfb, #0ead3f);
4765
4765
  `,Nge=ae.div`
4766
4766
  display: flex;
4767
4767
  align-items: center;
4768
4768
  background: #fff;
4769
4769
  padding: 0 16px 0 3px; /* Adjusted padding */
4770
- border-radius: ${e=>Ie(e.theme.botId)?"0":"999px"} !important;
4770
+ border-radius: ${e=>Me(e.theme.botId)?"0":"999px"} !important;
4771
4771
  height: 40px; /* Adjusted height */
4772
4772
  font-weight: 600;
4773
4773
  font-size: 16px; /* Adjusted font-size */
@@ -4775,9 +4775,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4775
4775
  `,EH=ae.button`
4776
4776
  width: 40px;
4777
4777
  height: 40px;
4778
- border-radius: ${e=>Ie(e.theme.botId)?"0":"50%"} !important;
4778
+ border-radius: ${e=>Me(e.theme.botId)?"0":"50%"} !important;
4779
4779
  border: 1.5px solid rgba(0, 0, 0, 0.3);
4780
- background: ${e=>Ie(e.theme.botId)?e.$iconBG:"#fff"};
4780
+ background: ${e=>Me(e.theme.botId)?e.$iconBG:"#fff"};
4781
4781
  display: flex;
4782
4782
  align-items: center;
4783
4783
  justify-content: center;
@@ -4785,7 +4785,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4785
4785
  cursor: pointer;
4786
4786
  transition: background 0.2s;
4787
4787
  &:hover {
4788
- background: ${e=>!Ie(e.theme.botId)&&"#f5f5f5"};
4788
+ background: ${e=>!Me(e.theme.botId)&&"#f5f5f5"};
4789
4789
  }
4790
4790
  `,zge=ae.div`
4791
4791
  z-index: 2147483647;
@@ -4819,7 +4819,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4819
4819
 
4820
4820
  &::-webkit-scrollbar-thumb {
4821
4821
  background: #7a7979;
4822
- border-radius: ${e=>Ie(e.theme.botId)?"0":"5px"} !important;
4822
+ border-radius: ${e=>Me(e.theme.botId)?"0":"5px"} !important;
4823
4823
  }
4824
4824
 
4825
4825
  /* Improved scrolling behavior for all mobile modes */
@@ -4955,12 +4955,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
4955
4955
  justify-content: center;
4956
4956
  text-align: left;
4957
4957
  align-self: stretch;
4958
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
4958
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
4959
4959
  color: white;
4960
4960
  border: none;
4961
4961
  cursor: ${e=>e.$disabled?"default":"pointer"};
4962
4962
  font-size: 14px;
4963
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
4963
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
4964
4964
  line-height: 20px !important;
4965
4965
  transition: all 0.05s ease;
4966
4966
  height: auto !important;
@@ -5134,7 +5134,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
5134
5134
  margin: 4px 10px 4px;
5135
5135
  padding: 16px 16px;
5136
5136
  background-color: ${e=>e.theme.colors.bot.message||"#fff"};
5137
- border-radius: ${e=>Ie(e.theme.botId)?"0":"12px"} !important;
5137
+ border-radius: ${e=>Me(e.theme.botId)?"0":"12px"} !important;
5138
5138
  width: 100%;
5139
5139
  max-width: 320px;
5140
5140
  `,K8=ae.div`
@@ -5148,7 +5148,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
5148
5148
  margin-bottom: 8px;
5149
5149
  font-size: 16px;
5150
5150
  color: #1c1c1c;
5151
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
5151
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
5152
5152
 
5153
5153
  span {
5154
5154
  color: #ff3b30;
@@ -5157,30 +5157,30 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
5157
5157
  width: calc(100% - 26px);
5158
5158
  padding: 12px;
5159
5159
  border: 1px solid #d0d5dd;
5160
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
5160
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
5161
5161
  font-size: 16px;
5162
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
5163
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
5162
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
5163
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
5164
5164
 
5165
5165
  &:focus {
5166
5166
  outline: none;
5167
5167
  border-color: #f48722;
5168
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
5168
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
5169
5169
  }
5170
5170
  `,Xge=ae.textarea`
5171
5171
  width: calc(100% - 26px);
5172
5172
  padding: 12px;
5173
5173
  border: 1px solid #d0d5dd;
5174
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
5174
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
5175
5175
  font-size: 16px;
5176
- font-weight: ${e=>Ie(e.theme.botId)?"300":"400"};
5177
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
5176
+ font-weight: ${e=>Me(e.theme.botId)?"300":"400"};
5177
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#f1f5f9"};
5178
5178
  resize: none;
5179
5179
 
5180
5180
  &:focus {
5181
5181
  outline: none;
5182
5182
  border-color: #f48722;
5183
- background-color: ${e=>Ie(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
5183
+ background-color: ${e=>Me(e.theme.botId)?e.theme.colors.bot.message:"#fff"};
5184
5184
  }
5185
5185
  `,Jge=ae.button`
5186
5186
  height: 40px !important;
@@ -5189,9 +5189,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
5189
5189
  background-color: ${e=>e.theme.colors.cta.background};
5190
5190
  color: ${e=>e.theme.colors.cta.font};
5191
5191
  border: none;
5192
- border-radius: ${e=>Ie(e.theme.botId)?"0":"8px"} !important;
5192
+ border-radius: ${e=>Me(e.theme.botId)?"0":"8px"} !important;
5193
5193
  font-size: 14px;
5194
- font-weight: ${e=>Ie(e.theme.botId)?"300":"500"};
5194
+ font-weight: ${e=>Me(e.theme.botId)?"300":"500"};
5195
5195
  cursor: pointer;
5196
5196
  transition: all 0.3s ease;
5197
5197
  justify-content: center;
@@ -5251,11 +5251,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
5251
5251
  opacity: 0;
5252
5252
  z-index: 1;
5253
5253
  bottom: 0;
5254
- `,ime=({botId:e})=>{var Oe,at;const{uiData:t,storeMetaData:n,onSendMessage:r,isKlaviyoMessage:o,isLoading:a,lastedBotmessageId:l,setLastedBotmessageId:d,messages:h,isMessageLoading:p,setIsMessageLoading:y,setMessages:m,saveConversation:x,loadConversation:_,suggestedQuestions:w,showUserInfoModel:k,setShowUserInfoModel:A,isUserInfoNeeded:E,setPendingQuestion:R}=qd(),{cart:O,addToCart:I,generateCartUrl:L,addCartAttributes:N}=Fd(),H=Qc("use-chatbot-icon-size"),V=hf.detect(),W=t==null?void 0:t.isLeft,z=xk(),Q=t==null?void 0:t.heightOption,J=Z.useRef(0),ee=Qc("new-suggested-question-design"),[de,ue]=Z.useState(!1),[se,pe]=Z.useState(!1),[Ce,B]=Z.useState(!1),[P,ne]=Z.useState([]),[U,fe]=Z.useState(0),Ae=Ql("acquisition_agent"),[Te,rt]=Z.useState(window.location.pathname),Ge=Z.useCallback(async()=>{try{if(!Ae||(t==null?void 0:t.show_bot)===!1)return;const ce=await fetch(`${Ti}/api/wordpress/acquisition`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,timestamp:new Date().toISOString(),page_information:window.location.href.split("?")[0],botid:e})});if(ce.ok){const Me=await ce.json(),j=window.location.pathname,te=3;ne(he=>{const ke=[...he],we={question:Me.Popup_Message,answer:"",path:j,nameSpace:e,type:"dynamic",Follow_up_Question:Me.Follow_up_Question};return ke.length>=te&&ke.shift(),ke.push(we),console.log("updated quesitons",ke),ke})}else console.error("Failed to fetch new acquisition question")}catch(ce){console.error("Error fetching new acquisition question:",ce)}},[e,Ae,t==null?void 0:t.show_bot]),[We,Tt]=Z.useState(!1),[It,nt]=Z.useState(!1),[dt,bt]=Z.useState(""),[Et,Nt]=Z.useState(""),[,yt]=Z.useState(0),[re,le]=Vm(On.SHOW_CART_SUMMARY,!0);Z.useEffect(()=>{e&&gk(e)},[e]),Z.useEffect(()=>{mE(e)},[e]),Z.useEffect(()=>{let ce=jo();if(!ce&&window.Thinkific){const Me=window.Thinkific.current_user;Me&&(ce={name:Me.full_name,email:Me.email},sf(ce))}Xu.init({projectName:e,debug:!1,testing:Cx}),ce&&ce.email&&(window.DebalesChat.identify(ce.email,{name:ce.name,phone:ce.phone,email:ce.email}),t!=null&&t.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:ce.email,first_name:ce.name,phone:ce.phone,from:"Debales-Chatbot"}))},[e,t==null?void 0:t.KlaviyoIntegration]);const ve=Z.useRef(null),Ee=Qn(On.CLICKED_QUESTIONS,{botId:e}),[$e,Ve]=Z.useState(()=>{try{const ce=sessionStorage.getItem(Ee);return ce?new Set(JSON.parse(ce)):new Set}catch{return new Set}});Z.useEffect(()=>{try{sessionStorage.setItem(Ee,JSON.stringify(Array.from($e)))}catch(ce){console.error("Failed to save to sessionStorage:",ce)}},[$e]);const lt=Z.useCallback((ce,Me)=>{ce?(window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:ce,source:Me,projectId:e}})),setTimeout(()=>{nt(!0)},50)):(nt(!1),window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:ce,source:Me,projectId:e}})))},[e]);Z.useEffect(()=>{const ce=Me=>{Me.detail.projectId===e&&(Tt(Me.detail.isOpen),Me.detail.isOpen&&setTimeout(()=>nt(!0),50),window.DebalesChat.isOpen=Me.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:Me.detail.isOpen,source:Me.detail.source}))};return window.addEventListener(Qr.OPEN_STATE_CHANGE,ce),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,ce)}},[e]),Z.useEffect(()=>{const ce=()=>{const te=window.location.pathname;te!==Te&&(rt(te),Ge())};window.addEventListener("popstate",ce);const Me=history.pushState,j=history.replaceState;return history.pushState=function(...te){Me.apply(this,te),ce()},history.replaceState=function(...te){j.apply(this,te),ce()},()=>{window.removeEventListener("popstate",ce),history.pushState=Me,history.replaceState=j}},[Te,Ge]),Z.useEffect(()=>{const ce=un=>{if(typeof window<"u"&&typeof document<"u"&&document.documentElement){const Un=document.documentElement.scrollHeight,dn=document.documentElement.clientHeight,gr=window.scrollY,$r=Un-dn;return $r<=0?un:gr/$r*100>50?0:un}return un};if(ee&&!We&&(J.current=ce(ee.showing_delay||2e3)),!ee||We||P.length===0)return;let Me,j,te,he;const ke=ee.showing_delay||2e3,we=ee.showing_delay||2e3,Je=ee.show_for||4e3,$t=ee.hide_timing||4e3,an=async()=>{if(P.length===0||!P[U]){he=setTimeout(()=>{P.length>0&&fe(un=>un%P.length)},$t+500);return}Me=setTimeout(()=>{We||(ue(!0),j=setTimeout(async()=>{We||(pe(!0),B(!0),te=setTimeout(async()=>{We||(B(!1),pe(!1),ue(!1),fe(un=>(un+1)%P.length),he=setTimeout(()=>{an()},$t))},Je))},we))},J.current)};return P.length===0&&e?Ge().then(()=>{if(!We&&P.length>0){fe(0);const un=ce(ke);J.current=un,an()}else!We&&P.length}):!We&&P.length>0&&an(),()=>{clearTimeout(Me),clearTimeout(j),clearTimeout(te),clearTimeout(he)}},[ee,We,Ge,P,U,e]);const[mt,_e]=Z.useState(()=>{const ce=Qn(On.PENDING_BULK_ITEMS,{botId:e}),Me=sessionStorage.getItem(ce);return Me?JSON.parse(Me):[]});Z.useEffect(()=>{const ce=Qn(On.PENDING_BULK_ITEMS,{botId:e});sessionStorage.setItem(ce,JSON.stringify(mt))},[mt,e]);const[Re,Ct]=Z.useState(!1),[ct,Rt]=Z.useState({name:"",email:"",message:""}),[Mt,en]=Z.useState([]),[Qt,gn]=Z.useState({name:"",email:"",message:""}),pt=Ql("exit_model"),[Kt,_t]=Z.useState({text:!0,leadingQueries:!0,collections:!0,products:!0,variants:!0,cartSummary:!0,bulkItems:!0}),[Y,xe]=Z.useState({suggestions:!1,products:!1,collections:!1,leadingQueries:!1,initialMessage:!1,cartSummary:!1,bulkItems:!1});Z.useEffect(()=>{if(h.length===1&&!k){xe(Me=>({...Me,leadingQueries:!0}));const ce=setTimeout(()=>{xe(Me=>({...Me,leadingQueries:!1}))},2e3);return()=>clearTimeout(ce)}},[h,k]);const[it,st]=Z.useState(!1),[St,Pt]=Z.useState(!0),[Ht,Yt]=Z.useState(!1),[qt,ln]=Z.useState(!1),[hr,xr]=Z.useState(!1),[Ur,nn]=Z.useState(!1),yn=500,fn=Z.useCallback(()=>{const ce=ve.current;if(!ce){xr(!1),nn(!1),Pt(!0);return}if(Ie(e)){xr(!1);return}const Me=ce.scrollTop,j=ce.scrollHeight,te=ce.clientHeight,he=j>te,ke=1,we=Me<=ke,Je=Me+te>=j-ke;he?(xr(!we),nn(!Je),Pt(Je)):(xr(!1),nn(!1),Pt(!0))},[ve,xr,nn,Pt]);Z.useEffect(()=>{const ce=ve.current;if(We&&ce){fn(),ce.addEventListener("scroll",fn);const Me=new ResizeObserver(fn);return Me.observe(ce),()=>{ce.removeEventListener("scroll",fn),Me.unobserve(ce)}}else We||(xr(!1),nn(!1),Pt(!0))},[We,h,it,fn]),Z.useEffect(()=>{var ce,Me,j,te,he,ke;if(h.length>0&&!p){const we=h[h.length-1],Je=sessionStorage.getItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e})),$t=we.isBot&&we.conversationId===l&&we.conversationId!==Je,an=(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0&&we.conversationId===l;if($t){st(!0),sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),we.conversationId||""),_t({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1});const un=2e3;let Un=un;const dn=[{type:"collections",condition:((ce=we.collections)==null?void 0:ce.length)&&((Me=we.collections)==null?void 0:Me.length)>0},{type:"products",condition:((j=we.products)==null?void 0:j.length)&&((te=we.products)==null?void 0:te.length)>0},{type:"leadingQueries",condition:((he=we.leading_queries)==null?void 0:he.length)&&((ke=we.leading_queries)==null?void 0:ke.length)>0},{type:"cartSummary",condition:(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0},{type:"bulkItems",condition:(mt==null?void 0:mt.length)>0}].filter(gr=>gr.condition);if(dn.length===0){st(!1);return}dn.forEach(({type:gr},$r)=>{setTimeout(()=>{if(_t(hi=>({...hi,[gr]:!0})),St&&ve.current){const hi=ve.current;hi.scrollHeight-hi.scrollTop<=hi.clientHeight&&La(ve)}$r===dn.length-1&&st(!1)},Un),Un+=un})}else an&&_t(un=>({...un,cartSummary:!0}))}},[h,p,l,O==null?void 0:O.itemCount,mt==null?void 0:mt.length,St,e]),Z.useEffect(()=>{if(!o&&h.length>0){const ce=ve.current;ce&&St&&ce.scrollHeight-ce.scrollTop<=ce.clientHeight+100&&setTimeout(()=>La(ve),100)}},[h.length,o,St]),Z.useEffect(()=>{const ce=document.querySelector('meta[name="viewport"]'),Me=ce==null?void 0:ce.content;if(We){let j=ce;const te=window.matchMedia("(max-width: 768px)").matches;j?j.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no":(j=document.createElement("meta"),j.name="viewport",j.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no",document.head.appendChild(j)),te&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="hidden");const he=j;return()=>{Me&&he&&(he.content=Me),te&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}}return()=>{window.matchMedia("(max-width: 768px)").matches&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}},[We,t==null?void 0:t.mobileDisplayMode]),Z.useEffect(()=>{if(We&&h.length>0&&!o){const ce=setTimeout(()=>{ve.current&&La(ve)},150);return()=>clearTimeout(ce)}},[We,h.length,o]),Z.useEffect(()=>{O!=null&&O.itemCount&&O.itemCount===0&&!o&&setTimeout(()=>La(ve),100)},[O==null?void 0:O.itemCount,o]),Z.useEffect(()=>{l&&sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),l)},[l,e]);const[ho,br]=Z.useState(!1),[us,ji]=Z.useState(!1),[Ho,Dt]=Z.useState(null),to=async ce=>{const Me=nr();if(nt(!1),ce&&h.length>1)try{(await fetch(`${Ti}/api/wordpress/userRating`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sessionId:Me,userRating:ce,nameSpace:e})})).ok||console.error("Error submitting rating")}catch(j){console.error("Error submitting rating:",j)}setTimeout(()=>{ji(!1),lt(!1,"close_button_clicked")},1e3)},rr=ce=>{y(!0),mt.forEach(j=>{I(j.id,j.quantity)}),le(!0),window.DebalesChat.track(tn.ADD_BULK_ITEM,{products:mt,message:ce});const Me=[...h,{text:"πŸŽ‰ Bulk items added to cart successfully.",leading_queries:["Get GST Invoice for the order","Explore more products"],conversationId:ce,isBot:!0}];m(Me),x(Me),d(ce),_e([]),y(!1)},Ro=()=>{var ce;switch(e){case"minature":case"bodytales":case"imemyselfcare-com":if(window.triggerGokwikCustomCheckout)return window.triggerGokwikCustomCheckout(),!0;break;case"athflex":if((ce=window.shiprocketCheckoutEvents)!=null&&ce.buyCart)return window.shiprocketCheckoutEvents.buyCart(),!0;break;case"www":if(window.openRzpCheckout)return window.openRzpCheckout(),!0;break;default:return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1}return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1},po=async ce=>{ce.preventDefault(),window.DebalesChat.track(tn.CHECKOUT_CLICKED,{chatId:nr()+e,cartValue:Number(O==null?void 0:O.total),cart:O}),N({dbls_method:"checkout_clicked"}),Ro()&&lt(!1,"checkout_clicked")};Z.useEffect(()=>{const ce=gE(w);ne(Me=>[...ce.filter(te=>!Me.some(he=>he.question===te.question))])},[w]),Z.useEffect(()=>{const ce=te=>{const he=te.detail.formId;switch(te.detail.type){case"open":case"embedOpen":setTimeout(()=>{const we=Me(he);we&&bt(we)},800);break;case"close":dt&&(t==null?void 0:t.KlaviyoFormIntegration)===!0&&setTimeout(()=>{lt(!0,"klaviyo_form_closed"),Nt(he),r({message:dt,fromKlaviyo:!0})},1e4);break}},Me=te=>{const he=document.querySelector(`[data-testid="klaviyo-form-${te}"]`);if(console.log(`formElement text ${te} =>`,he==null?void 0:he.innerText,he==null?void 0:he.textContent),he instanceof HTMLElement){const ke=he.innerText||he.textContent;if(ke)return console.log("Found form text:",ke),`=> Klaviyo form content:
5254
+ `,ime=({botId:e})=>{var Oe,at;const{uiData:t,storeMetaData:n,onSendMessage:r,isKlaviyoMessage:o,isLoading:a,lastedBotmessageId:l,setLastedBotmessageId:d,messages:h,isMessageLoading:p,setIsMessageLoading:y,setMessages:m,saveConversation:x,loadConversation:_,suggestedQuestions:w,showUserInfoModel:k,setShowUserInfoModel:A,isUserInfoNeeded:E,setPendingQuestion:R}=qd(),{cart:O,addToCart:I,generateCartUrl:L,addCartAttributes:N}=Fd(),H=Qc("use-chatbot-icon-size"),V=hf.detect(),W=t==null?void 0:t.isLeft,z=xk(),Q=t==null?void 0:t.heightOption,J=Z.useRef(0),ee=Qc("new-suggested-question-design"),[de,ue]=Z.useState(!1),[se,pe]=Z.useState(!1),[Ce,B]=Z.useState(!1),[P,ne]=Z.useState([]),[U,fe]=Z.useState(0),Ae=Ql("acquisition_agent"),[Te,rt]=Z.useState(window.location.pathname),Ge=Z.useCallback(async()=>{try{if(!Ae||(t==null?void 0:t.show_bot)===!1)return;const ce=await fetch(`${Ti}/api/wordpress/acquisition`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,timestamp:new Date().toISOString(),page_information:window.location.href.split("?")[0],botid:e})});if(ce.ok){const Ie=await ce.json(),j=window.location.pathname,te=3;ne(he=>{const ke=[...he],we={question:Ie.Popup_Message,answer:"",path:j,nameSpace:e,type:"dynamic",Follow_up_Question:Ie.Follow_up_Question};return ke.length>=te&&ke.shift(),ke.push(we),console.log("updated quesitons",ke),ke})}else console.error("Failed to fetch new acquisition question")}catch(ce){console.error("Error fetching new acquisition question:",ce)}},[e,Ae,t==null?void 0:t.show_bot]),[We,Tt]=Z.useState(!1),[It,nt]=Z.useState(!1),[dt,bt]=Z.useState(""),[Et,Nt]=Z.useState(""),[,yt]=Z.useState(0),[re,le]=Vm(On.SHOW_CART_SUMMARY,!0);Z.useEffect(()=>{e&&gk(e)},[e]),Z.useEffect(()=>{mE(e)},[e]),Z.useEffect(()=>{let ce=jo();if(!ce&&window.Thinkific){const Ie=window.Thinkific.current_user;Ie&&(ce={name:Ie.full_name,email:Ie.email},sf(ce))}Xu.init({projectName:e,debug:!1,testing:Cx}),ce&&ce.email&&(window.DebalesChat.identify(ce.email,{name:ce.name,phone:ce.phone,email:ce.email}),t!=null&&t.KlaviyoIntegration&&window.klaviyo&&window.klaviyo.identify({email:ce.email,first_name:ce.name,phone:ce.phone,from:"Debales-Chatbot"}))},[e,t==null?void 0:t.KlaviyoIntegration]);const ve=Z.useRef(null),Ee=Qn(On.CLICKED_QUESTIONS,{botId:e}),[$e,Ve]=Z.useState(()=>{try{const ce=sessionStorage.getItem(Ee);return ce?new Set(JSON.parse(ce)):new Set}catch{return new Set}});Z.useEffect(()=>{try{sessionStorage.setItem(Ee,JSON.stringify(Array.from($e)))}catch(ce){console.error("Failed to save to sessionStorage:",ce)}},[$e]);const lt=Z.useCallback((ce,Ie)=>{ce?(window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:ce,source:Ie,projectId:e}})),setTimeout(()=>{nt(!0)},50)):(nt(!1),window.dispatchEvent(new CustomEvent(Qr.OPEN_STATE_CHANGE,{detail:{isOpen:ce,source:Ie,projectId:e}})))},[e]);Z.useEffect(()=>{const ce=Ie=>{Ie.detail.projectId===e&&(Tt(Ie.detail.isOpen),Ie.detail.isOpen&&setTimeout(()=>nt(!0),50),window.DebalesChat.isOpen=Ie.detail.isOpen,window.DebalesChat.track(tn.OPEN_STATE_CHANGE,{isOpen:Ie.detail.isOpen,source:Ie.detail.source}))};return window.addEventListener(Qr.OPEN_STATE_CHANGE,ce),()=>{window.removeEventListener(Qr.OPEN_STATE_CHANGE,ce)}},[e]),Z.useEffect(()=>{const ce=()=>{const te=window.location.pathname;te!==Te&&(rt(te),Ge())};window.addEventListener("popstate",ce);const Ie=history.pushState,j=history.replaceState;return history.pushState=function(...te){Ie.apply(this,te),ce()},history.replaceState=function(...te){j.apply(this,te),ce()},()=>{window.removeEventListener("popstate",ce),history.pushState=Ie,history.replaceState=j}},[Te,Ge]),Z.useEffect(()=>{const ce=un=>{if(typeof window<"u"&&typeof document<"u"&&document.documentElement){const Un=document.documentElement.scrollHeight,dn=document.documentElement.clientHeight,gr=window.scrollY,$r=Un-dn;return $r<=0?un:gr/$r*100>50?0:un}return un};if(ee&&!We&&(J.current=ce(ee.showing_delay||2e3)),!ee||We||P.length===0)return;let Ie,j,te,he;const ke=ee.showing_delay||2e3,we=ee.showing_delay||2e3,Je=ee.show_for||4e3,$t=ee.hide_timing||4e3,an=async()=>{if(P.length===0||!P[U]){he=setTimeout(()=>{P.length>0&&fe(un=>un%P.length)},$t+500);return}Ie=setTimeout(()=>{We||(ue(!0),j=setTimeout(async()=>{We||(pe(!0),B(!0),te=setTimeout(async()=>{We||(B(!1),pe(!1),ue(!1),fe(un=>(un+1)%P.length),he=setTimeout(()=>{an()},$t))},Je))},we))},J.current)};return P.length===0&&e?Ge().then(()=>{if(!We&&P.length>0){fe(0);const un=ce(ke);J.current=un,an()}else!We&&P.length}):!We&&P.length>0&&an(),()=>{clearTimeout(Ie),clearTimeout(j),clearTimeout(te),clearTimeout(he)}},[ee,We,Ge,P,U,e]);const[mt,_e]=Z.useState(()=>{const ce=Qn(On.PENDING_BULK_ITEMS,{botId:e}),Ie=sessionStorage.getItem(ce);return Ie?JSON.parse(Ie):[]});Z.useEffect(()=>{const ce=Qn(On.PENDING_BULK_ITEMS,{botId:e});sessionStorage.setItem(ce,JSON.stringify(mt))},[mt,e]);const[Re,Ct]=Z.useState(!1),[ct,Rt]=Z.useState({name:"",email:"",message:""}),[Mt,en]=Z.useState([]),[Qt,gn]=Z.useState({name:"",email:"",message:""}),pt=Ql("exit_model"),[Kt,_t]=Z.useState({text:!0,leadingQueries:!0,collections:!0,products:!0,variants:!0,cartSummary:!0,bulkItems:!0}),[Y,xe]=Z.useState({suggestions:!1,products:!1,collections:!1,leadingQueries:!1,initialMessage:!1,cartSummary:!1,bulkItems:!1});Z.useEffect(()=>{if(h.length===1&&!k){xe(Ie=>({...Ie,leadingQueries:!0}));const ce=setTimeout(()=>{xe(Ie=>({...Ie,leadingQueries:!1}))},2e3);return()=>clearTimeout(ce)}},[h,k]);const[it,st]=Z.useState(!1),[St,Pt]=Z.useState(!0),[Ht,Yt]=Z.useState(!1),[qt,ln]=Z.useState(!1),[hr,xr]=Z.useState(!1),[Ur,nn]=Z.useState(!1),yn=500,fn=Z.useCallback(()=>{const ce=ve.current;if(!ce){xr(!1),nn(!1),Pt(!0);return}if(Me(e)){xr(!1);return}const Ie=ce.scrollTop,j=ce.scrollHeight,te=ce.clientHeight,he=j>te,ke=1,we=Ie<=ke,Je=Ie+te>=j-ke;he?(xr(!we),nn(!Je),Pt(Je)):(xr(!1),nn(!1),Pt(!0))},[ve,xr,nn,Pt]);Z.useEffect(()=>{const ce=ve.current;if(We&&ce){fn(),ce.addEventListener("scroll",fn);const Ie=new ResizeObserver(fn);return Ie.observe(ce),()=>{ce.removeEventListener("scroll",fn),Ie.unobserve(ce)}}else We||(xr(!1),nn(!1),Pt(!0))},[We,h,it,fn]),Z.useEffect(()=>{var ce,Ie,j,te,he,ke;if(h.length>0&&!p){const we=h[h.length-1],Je=sessionStorage.getItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e})),$t=we.isBot&&we.conversationId===l&&we.conversationId!==Je,an=(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0&&we.conversationId===l;if($t){st(!0),sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),we.conversationId||""),_t({text:!0,leadingQueries:!1,collections:!1,products:!1,variants:!1,cartSummary:!1,bulkItems:!1});const un=2e3;let Un=un;const dn=[{type:"collections",condition:((ce=we.collections)==null?void 0:ce.length)&&((Ie=we.collections)==null?void 0:Ie.length)>0},{type:"products",condition:((j=we.products)==null?void 0:j.length)&&((te=we.products)==null?void 0:te.length)>0},{type:"leadingQueries",condition:((he=we.leading_queries)==null?void 0:he.length)&&((ke=we.leading_queries)==null?void 0:ke.length)>0},{type:"cartSummary",condition:(O==null?void 0:O.itemCount)&&(O==null?void 0:O.itemCount)>0},{type:"bulkItems",condition:(mt==null?void 0:mt.length)>0}].filter(gr=>gr.condition);if(dn.length===0){st(!1);return}dn.forEach(({type:gr},$r)=>{setTimeout(()=>{if(_t(hi=>({...hi,[gr]:!0})),St&&ve.current){const hi=ve.current;hi.scrollHeight-hi.scrollTop<=hi.clientHeight&&La(ve)}$r===dn.length-1&&st(!1)},Un),Un+=un})}else an&&_t(un=>({...un,cartSummary:!0}))}},[h,p,l,O==null?void 0:O.itemCount,mt==null?void 0:mt.length,St,e]),Z.useEffect(()=>{if(!o&&h.length>0){const ce=ve.current;ce&&St&&ce.scrollHeight-ce.scrollTop<=ce.clientHeight+100&&setTimeout(()=>La(ve),100)}},[h.length,o,St]),Z.useEffect(()=>{const ce=document.querySelector('meta[name="viewport"]'),Ie=ce==null?void 0:ce.content;if(We){let j=ce;const te=window.matchMedia("(max-width: 768px)").matches;j?j.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no":(j=document.createElement("meta"),j.name="viewport",j.content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no",document.head.appendChild(j)),te&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="hidden");const he=j;return()=>{Ie&&he&&(he.content=Ie),te&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}}return()=>{window.matchMedia("(max-width: 768px)").matches&&(t==null?void 0:t.mobileDisplayMode)==="full-screen"&&(document.body.style.overflow="")}},[We,t==null?void 0:t.mobileDisplayMode]),Z.useEffect(()=>{if(We&&h.length>0&&!o){const ce=setTimeout(()=>{ve.current&&La(ve)},150);return()=>clearTimeout(ce)}},[We,h.length,o]),Z.useEffect(()=>{O!=null&&O.total&&!o&&setTimeout(()=>La(ve),100)},[O==null?void 0:O.total,o]),Z.useEffect(()=>{l&&sessionStorage.setItem(Qn(On.LAST_SHOWN_MESSAGE_ID,{botId:e}),l)},[l,e]);const[ho,br]=Z.useState(!1),[us,ji]=Z.useState(!1),[Ho,Dt]=Z.useState(null),to=async ce=>{const Ie=nr();if(nt(!1),ce&&h.length>1)try{(await fetch(`${Ti}/api/wordpress/userRating`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sessionId:Ie,userRating:ce,nameSpace:e})})).ok||console.error("Error submitting rating")}catch(j){console.error("Error submitting rating:",j)}setTimeout(()=>{ji(!1),lt(!1,"close_button_clicked")},1e3)},rr=ce=>{y(!0),mt.forEach(j=>{I(j.id,j.quantity)}),le(!0),window.DebalesChat.track(tn.ADD_BULK_ITEM,{products:mt,message:ce});const Ie=[...h,{text:"πŸŽ‰ Bulk items added to cart successfully.",leading_queries:["Get GST Invoice for the order","Explore more products"],conversationId:ce,isBot:!0}];m(Ie),x(Ie),d(ce),_e([]),y(!1)},Ro=()=>{var ce;switch(e){case"minature":case"bodytales":case"imemyselfcare-com":if(window.triggerGokwikCustomCheckout)return window.triggerGokwikCustomCheckout(),!0;break;case"athflex":if((ce=window.shiprocketCheckoutEvents)!=null&&ce.buyCart)return window.shiprocketCheckoutEvents.buyCart(),!0;break;case"www":if(window.openRzpCheckout)return window.openRzpCheckout(),!0;break;default:return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1}return window.location.href=L((t==null?void 0:t.shopifyShopDomain)??""),!1},po=async ce=>{ce.preventDefault(),window.DebalesChat.track(tn.CHECKOUT_CLICKED,{chatId:nr()+e,cartValue:Number(O==null?void 0:O.total),cart:O}),N({dbls_method:"checkout_clicked"}),Ro()&&lt(!1,"checkout_clicked")};Z.useEffect(()=>{const ce=gE(w);ne(Ie=>[...ce.filter(te=>!Ie.some(he=>he.question===te.question))])},[w]),Z.useEffect(()=>{const ce=te=>{const he=te.detail.formId;switch(te.detail.type){case"open":case"embedOpen":setTimeout(()=>{const we=Ie(he);we&&bt(we)},800);break;case"close":dt&&(t==null?void 0:t.KlaviyoFormIntegration)===!0&&setTimeout(()=>{lt(!0,"klaviyo_form_closed"),Nt(he),r({message:dt,fromKlaviyo:!0})},1e4);break}},Ie=te=>{const he=document.querySelector(`[data-testid="klaviyo-form-${te}"]`);if(console.log(`formElement text ${te} =>`,he==null?void 0:he.innerText,he==null?void 0:he.textContent),he instanceof HTMLElement){const ke=he.innerText||he.textContent;if(ke)return console.log("Found form text:",ke),`=> Klaviyo form content:
5255
5255
 
5256
5256
  `+ke+`
5257
5257
 
5258
- => User Action: Klaviyo form closed`}return""},j=te=>{te instanceof CustomEvent&&ce(te)};return window.addEventListener("klaviyoForms",j),()=>{window.removeEventListener("klaviyoForms",j)}},[dt,t,r]),Z.useEffect(()=>{const ce=ve.current;return We&&ce?(ce.addEventListener("scroll",fn),()=>{ce&&ce.removeEventListener("scroll",fn)}):()=>{}},[We,fn]);const[qn,ua]=Z.useState(!1),Oi=Q==="Highest"?"120px":Q==="Higher"?"60px":"15px",pr=async()=>{try{const ce=await fetch(`${Ti}/api/wordpress/support`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatid:nr()+e,nameSpace:e,userName:ct.name,userEmail:ct.email,userMessage:ct.message,tag:"support"})});if(ce.ok){const Me=`support-confirm-${Date.now()}`;m(j=>[...j,{text:"Thanks for reaching out! Our support team has received your request and will get back to you within 24 hours.<br>In the meantime, feel free to continue chatting with me - I'll do my best to help!",isBot:!0,leading_queries:Mt,conversationId:Me}]),d(Me),_t(j=>({...j,leadingQueries:!0})),en([]),console.log("Connected to support with existing user info:",jo())}else{const Me=await ce.json();console.error("Failed to connect to support:",Me),m(j=>[...j,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}}catch{m(Me=>[...Me,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}},Br=()=>{if(Ie(e)){const te=Fp("https://test.thecollective.in/content/customersupport");te.isValid&&(t!=null&&t.shopifyShopDomain&&(te.url.hostname=t==null?void 0:t.shopifyShopDomain),window.open(Os(te.url.toString()),"_blank"));return}const ce=jo();let Me=[];const j=h[h.length-1];j!=null&&j.leading_queries&&j.leading_queries.length>0?Me=j.leading_queries:h.length<=1&&(Me=P.flatMap(te=>Array.isArray(te)?te.map(he=>he.question):[te.question]).slice(0,4)),en(Me),ce&&ce.name&&ce.email&&Rt({name:ce==null?void 0:ce.name,email:ce==null?void 0:ce.email,message:""}),m(te=>[...te,{text:"Please provide your name, email and message to connect with support.",isBot:!0}]),Ct(!0)},ca=async ce=>{ce.preventDefault();const Me={name:"",email:"",message:""};let j=!0;const te=ct.name.trim(),he=ct.message.trim();te||(Me.name="Name cannot be empty or just whitespace.",j=!1),(!ct.email||!zm.isEmail(ct.email))&&(Me.email="Please enter a valid email address.",j=!1),he||(Me.message="Message cannot be empty or just whitespace.",j=!1),gn(Me),j&&(sf({name:te,email:ct.email}),Ct(!1),m(ke=>ke.slice(0,-1)),await pr())},[Kr,ot]=Z.useState({});return Z.useEffect(()=>{qt&&(h.forEach((ce,Me)=>{if(!ce.isBot)return;const j=$p(ce.text);if(!(Me in Kr)||Kr[Me]<j.length){let te;const he=ke=>{ke<j.length&&(te=setTimeout(()=>{ot(we=>({...we,[Me]:ke+1})),he(ke+1)},yn))};return Me in Kr?he(Kr[Me]):(ot(ke=>({...ke,[Me]:1})),he(1)),()=>clearTimeout(te)}}),ot(ce=>{const Me={};return h.forEach((j,te)=>{ce[te]!==void 0&&(Me[te]=ce[te])}),Me}))},[h,qt]),!t||t.show_bot===!1||a?null:M.jsxs(Jw,{theme:pE(t,e),children:[M.jsx("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),M.jsx("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",rel:"stylesheet"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap",rel:"stylesheet"}),M.jsx(Qge,{}),M.jsxs(kge,{$topOffset:Oi,$isLeft:W,children:[!We&&P.length>0&&P[U]&&se&&M.jsx(Yge,{className:Ce?"visible":"",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Oi,style:{display:"flex",flexDirection:"column",alignItems:"center",opacity:Ce?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length>0&&P[U]&&M.jsx(Zge,{children:M.jsx(Cge,{messages:[{question:P[U].question,isHighlighted:P[U].isHighlighted??!1,show_for:(ee==null?void 0:ee.show_for)||4e3,hide_timing:(ee==null?void 0:ee.hide_timing)||4e3}],botId:e,uiData:t,onClose:()=>{Ve(ce=>{const Me=new Set(ce);return Me.add(P[U].question),Me})},onClick:()=>{const ce=P[U];lt(!0,"suggested_question_clicked"),Ve(Me=>{const j=new Set(Me);return j.add(ce.question),j}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:ce}),E?(Yt(!1),ln(!0),A(!0),R(ce)):(Yt(!1),ln(!0),r({message:ce.Follow_up_Question??ce.question,answer:ce.answer,products:ce.products,fromKlaviyo:!1,leading_queries:ce.leading_queries,followUpQuestion:ce.Follow_up_Question,messType:"suggested_question"}))}})},P[U].question)}),M.jsxs(Tge,{$topOffset:Oi,$removeLogoBackground:t.removeLogoBackground,style:{display:We||se?"none":"flex"},children:[M.jsx(Rge,{$showAnimation:t.enableChatButtonBackgroundAnimation??!1,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",$backgroundColor:t.backgroundColor||"#fff",$removeLogoBackground:t.removeLogoBackground,$topOffset:Oi,$iconSize:H}),M.jsxs(Oge,{$backgroundColor:t.removeLogoBackground?"transparent":t.backgroundColor||"#fff",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Oi,$showAnimation:t.enableChatButtonBackgroundAnimation,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",id:"debales-chat-button","data-testid":"debales-chat-button",onClick:()=>{if(window.DebalesChat.track(tn.CHAT_BUTTON_CLICKED),lt(!We,"chat_button_clicked"),!We){const ce=_();ce.length>0?(m(ce),Yt(!1),ln(!0)):(Yt(!0),ln(!1),setTimeout(()=>{Yt(!1),ln(!0);const Me={text:(t==null?void 0:t.initialMessage)||"Hi, I am an AI chatbot, how can I help you today?",isBot:!0};m([Me])},(ee==null?void 0:ee.showing_delay)||2e3))}},"aria-label":"Chat",style:{display:We||se?"none":"flex"},children:[M.jsx(Dge,{$botId:e,$removeLogoBackground:t.removeLogoBackground,"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),(P==null?void 0:P.length)>0&&!We&&de&&M.jsx("div",{style:{position:"absolute",top:"0px",right:"0px",backgroundColor:"#f44336",color:"white",borderRadius:"50%",width:"20px",height:"20px",display:"flex",justifyContent:"center",alignItems:"center",fontSize:"12px",fontWeight:"bold",zIndex:2,opacity:de?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length})]})]})]}),We&&vw.createPortal(M.jsx(M.Fragment,{children:M.jsxs(Bge,{$backgroundColor:t.backgroundColor||"#fff",$fullScreenOnMobile:t.fullScreenOnMobile,$headerFontColor:t.headerFontColor||"#1C1C1C",$isLeft:W,$topOffset:Oi,$mobileDisplayMode:t.mobileDisplayMode,$isVisible:It,"data-testid":"debales-chat-container",children:[M.jsxs(zge,{$backgroundColor:Ie(e)?t.backgroundColor:t.botBackgroundColor||"#fff",style:{color:t.headerFontColor},children:[M.jsx("div",{style:{flexGrow:.1,display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden",marginRight:"8px",gap:"10px"},children:Ie(e)?M.jsxs(M.Fragment,{children:[M.jsx(CH,{"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),Ie(e)?M.jsx("div",{children:M.jsx("img",{src:yk,alt:"Chat Bot Icon",style:{height:"36px"}})}):M.jsxs(Mge,{$botNameColor:t.headerFontColor,children:[M.jsxs("div",{style:{fontWeight:"700",wordBreak:"break-word"},children:[t.chatbotName,e==="catch-org-ai"&&M.jsx($ge,{$backgroundColor:t.callToActionBackgroundColor,$fontColor:t.callToActionFontColor,children:"Beta"})]}),M.jsx(Ige,{})]})]}):M.jsx(Lge,{children:M.jsxs(Nge,{children:[M.jsx(CH,{src:t.bot_logo,alt:"Chat Bot Icon"}),M.jsx("span",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",display:"inline-block",maxWidth:"22ch"},children:t.chatbotName})]})})}),M.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"8px",marginLeft:"auto",flexShrink:0},children:[M.jsxs(Kge,{children:[M.jsx(EH,{$iconBG:t.backgroundColor,onClick:Br,"aria-label":"Support","data-testid":"debales-support-button",children:M.jsx(Tk,{color:t.headerFontColor})}),M.jsx(OH,{children:"Click to chat with a Live Support Agent now."})]}),M.jsx(EH,{$iconBG:t.backgroundColor,onClick:()=>{pt?ji(!0):lt(!1,"close_button_clicked")},id:"debales-minimize-button","data-testid":"debales-minimize-button","aria-label":"Minimize",children:M.jsx(Zm,{botNameColor:t.headerFontColor})})]}),M.jsx(rme,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:hr?1:0}})]}),M.jsxs(jge,{$backgroundColor:t.botBackgroundColor||"#fff",$mobileDisplayMode:t.mobileDisplayMode,children:[qn&&((at=(Oe=t.pluginConfig)==null?void 0:Oe.collectedUserInfo)==null?void 0:at.discount)&&M.jsx(Nk,{discount:t.pluginConfig.collectedUserInfo.discount,uiData:t,onClose:()=>{ua(!1),window.DebalesChat.track(tn.DISCOUNT_VIEWED,{discount:t.pluginConfig.collectedUserInfo.discount})}}),M.jsx(kk,{}),M.jsx(Pk,{uidata:t,product:Ho,showModel:ho,setShowModel:br,onVariantSelect:ce=>{I(ce.id,1),le(!0),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:ce.title,price:Number(ce.price),link:`https://${t.shopifyShopDomain}/variants/${ce.id}`,message:l,chatId:nr()+e})},botId:e}),us&&M.jsx(zk,{setShowExitModal:ji,handleCloseChatbot:to,chatId:nr()+e}),M.jsxs(Fge,{id:"debales-conversation-group",$botBackgroundColor:t.botBackgroundColor||"#fff",ref:ve,$mobileDisplayMode:t.mobileDisplayMode,children:[M.jsx(tme,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:hr?1:0}}),M.jsxs(Uge,{children:[qt&&h.map((ce,Me)=>{const j=ce.isBot,te=$p(ce.text);return ce.hideConfirmation?null:M.jsxs(Z.Fragment,{children:[j&&M.jsxs(AH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff","data-testid":"debales-ai-message-container",children:[M.jsx("img",{src:j?t.bot_logo:t.userMessage_logo,alt:"Chat User Icon",style:{marginLeft:"8px"}}),M.jsxs(RH,{children:[te.slice(0,Kr[Me]||0).map((he,ke)=>M.jsx("div",{children:M.jsx(Ri,{isBot:j,children:M.jsx(bd,{remarkPlugins:[Mw,vE],children:he})})},ke)),ce.collections&&l===ce.conversationId&&Kt.collections&&M.jsx(Lk,{message:ce,botId:e,uidata:t,onSendMessage:r,loading:p}),ce.products&&l===ce.conversationId&&Kt.products&&M.jsx(Uk,{message:ce,botId:e,uidata:t,onSendMessage:r,loading:p,storeMetaData:n,platform:V,setShowVariantModel:br,setSelectedProduct:Dt,setCartVersion:yt}),o&&M.jsx(Q8,{children:M.jsx(Nx,{onClick:()=>{window._klOnsite&&(window._klOnsite.push(["openForm",Et]),lt(!1,"klaviyo_grab_deal_button"))},children:"πŸš€ Grab Deal Now!"})}),O&&O.itemCount>0&&l===ce.conversationId&&Kt.cartSummary&&re&&M.jsx(Mk,{onCheckout:po,onKeepShopping:()=>{le(!1)}}),mt&&mt.length>0&&l===ce.conversationId&&Kt.bulkItems&&M.jsx(mk,{onClick:()=>rr(ce.conversationId),children:"Add Bulk Items to Cart"}),k&&h.indexOf(ce)===h.length-1&&M.jsx(M.Fragment,{children:M.jsx(jk,{setShowModel:he=>{var we,Je;const ke=typeof he=="function"?he(k):he;A(ke),!ke&&((Je=(we=t.pluginConfig)==null?void 0:we.collectedUserInfo)!=null&&Je.discount)&&ua(!0)},inChat:!0,showFormInstructions:!1})}),Re&&h.indexOf(ce)===h.length-1&&M.jsxs(Wge,{onSubmit:ca,noValidate:!0,"data-testid":"debales-support-form",children:[Ie(e)?M.jsxs(M.Fragment,{children:[M.jsx(ru,{label:"Name",name:"name",type:"text",value:ct.name,onChange:he=>Rt(ke=>({...ke,name:he.target.value})),required:!0,error:Qt.name,isCollectiveBot:!0}),M.jsx(ru,{label:"Email",name:"email",type:"email",value:ct.email,onChange:he=>Rt(ke=>({...ke,email:he.target.value})),required:!0,error:Qt.email,isCollectiveBot:!0}),M.jsx(Fk,{label:"Message",name:"message",value:ct.message,onChange:he=>Rt(ke=>({...ke,message:he.target.value})),required:!0,error:Qt.message,rows:4,isCollectiveBot:!0})]}):M.jsxs(M.Fragment,{children:[M.jsxs(K8,{children:[M.jsxs(W8,{children:["Name",M.jsx("span",{children:"*"})]}),M.jsx(DH,{type:"text",required:!0,value:ct.name,onChange:he=>Rt(ke=>({...ke,name:he.target.value})),placeholder:"John"}),Qt.name&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:Qt.name})]}),M.jsxs(K8,{children:[M.jsxs(W8,{children:["Email",M.jsx("span",{children:"*"})]}),M.jsx(DH,{type:"email",required:!0,value:ct.email,onChange:he=>Rt(ke=>({...ke,email:he.target.value})),placeholder:"olivia@untitledui.com"}),Qt.email&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:Qt.email})]}),M.jsxs(K8,{children:[M.jsxs(W8,{children:["Message",M.jsx("span",{children:"*"})]}),M.jsx(Xge,{required:!0,value:ct.message,onChange:he=>Rt(ke=>({...ke,message:he.target.value})),placeholder:"I need help with..."}),Qt.message&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:Qt.message})]})]}),M.jsx(eme,{children:M.jsx(Jge,{type:"submit",children:"Submit"})})]}),it&&!p&&l===ce.conversationId&&M.jsx(Ri,{isBot:j,children:M.jsx(Ds,{loading:it,loadingPhrases:["🎨 Loading","✨ Almost","πŸš€ Ready"]})})]})]}),!j&&M.jsx(Gge,{$fontColor:t.userFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:M.jsx(Ri,{isBot:!!j,children:M.jsx(bd,{children:ce.text})})}),h.length==1&&Me==0&&!k&&M.jsx(Q8,{children:Y.leadingQueries?M.jsx(Ri,{isBot:!0,children:M.jsx(Ds,{loading:Y.leadingQueries})}):P.map((he,ke)=>M.jsxs(TH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor,opacity:$e.has(he.question)?.5:1},onClick:()=>{E?(A(!0),R({question:he.question,answer:he.answer,products:he.products,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:he.question,answer:he.answer,products:he.products,messType:"leading_query"}),Ve(we=>{const Je=new Set(we);return Je.add(he.question),Je}),window.DebalesChat.track(tn.INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED,{question:he.question})},disabled:p,$disabled:p,children:[he.question,M.jsx(kH,{color:t.callToActionFontColor})]},ke))}),ce.leading_queries&&ce.leading_queries.length>0&&l===ce.conversationId&&Kt.leadingQueries&&!o&&!k&&M.jsx(Q8,{children:ce.leading_queries.map((he,ke)=>M.jsxs(TH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{E?(A(!0),R({question:he,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:he,messType:"leading_query"}),window.DebalesChat.track(tn.LEADING_QUERY_CLICKED,{query:he})},disabled:p,$disabled:p,children:[he,M.jsx(kH,{color:t.callToActionFontColor})]},ke))})]},Me)}),(p||Ht)&&M.jsxs(AH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:[M.jsx("img",{src:t.bot_logo,alt:"Chat User Icon"}),M.jsx(RH,{children:M.jsx(Ri,{isBot:!0,children:M.jsx("div",{style:{display:"flex",alignItems:"center",gap:"4px",animation:"fadeIn 0.3s ease-in-out"},children:M.jsx(Ds,{loading:p||Ht})})})})]})]}),M.jsx(nme,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}})]}),M.jsxs("div",{className:"debales-footer-container",style:{width:"calc(100%-24px)",backgroundColor:t.botBackgroundColor||"#fff",color:t.fontColor||"#000"},children:[(e==="catch-org-ai"||e==="letsgo-catch")&&M.jsx(qge,{children:M.jsx("span",{children:`"${t.chatbotName}" can make mistakes.`})}),M.jsx("div",{children:M.jsx(Hk,{disabled:p,inputState:!1})}),(t.debales_branding??!0)&&M.jsxs(Pge,{href:"https://debales.ai/?open=true",target:"_blank",title:"debales-link",style:{color:t.fontColor?t.fontColor:"fff",marginTop:e==="catch-org-ai"?"0":"9px"},children:[M.jsx("p",{children:"Powered by"}),M.jsxs(Hge,{children:[M.jsx("img",{src:`${Ti}/images/debales_logo_d.png`,alt:"Debales logo"}),M.jsx("p",{children:"DEBALES"})]})]})]})]})]})}),z.shadowRoot)]})},ome=({botId:e})=>{const t=NZ("new-suggested-question-design");let n;return t==="variant-1"?n=z0e:t==="variant-2"?n=_ge:t==="variant-3"?n=ime:n=oH,M.jsx(n,{botId:e})},MH="debales-ai-assistant",IH="debales-chatbot-container",ame=Z.forwardRef(({children:e,globalStyles:t="",containerStyles:n={},onReady:r},o)=>{const a=Z.useRef(null),[l,d]=Z.useState(null),h=Z.useRef(null),p=Z.useRef(null),y=Z.useRef({get shadowRoot(){return h.current},get container(){return l},querySelector:m=>{var x;return((x=h.current)==null?void 0:x.querySelector(m))||null},querySelectorAll:m=>{var x;return((x=h.current)==null?void 0:x.querySelectorAll(m))||null}});return Z.useImperativeHandle(o,()=>y.current,[]),Z.useEffect(()=>{const m=document.getElementById(MH);if(m?a.current=m:a.current&&(a.current.id=MH),a.current&&(a.current.style.cssText="position: absolute; top: 0; left: 0; width: 0; height: 0;"),a.current){if(a.current.shadowRoot){h.current=a.current.shadowRoot;const w=h.current.querySelector(`#${IH}`);w&&d(w);return}const x=a.current.attachShadow({mode:"open"});if(h.current=x,t){const w=document.createElement("style");w.textContent=t,x.appendChild(w)}const _=document.createElement("div");_.id=IH,_.style.cssText="position: absolute; top: 0; left: 0; width: 0; height: 0;",x.appendChild(_),d(_),r&&r(x,_)}},[t,r]),Z.useEffect(()=>(l&&!p.current&&(p.current=L5.createRoot(l)),p.current&&l&&p.current.render(M.jsx(Xte,{target:l,children:M.jsx(Uj,{value:y.current,children:e})})),()=>{p.current&&p.current.unmount()}),[l,e]),M.jsx("div",{ref:a,style:n})});class qk{isSupported(){return hf.detect()===this.platform}createSuccessResult(t,n){return{success:!0,data:t,message:n}}createErrorResult(t){return{success:!1,error:t}}}class sme extends qk{constructor(){super(...arguments);ei(this,"platform",xi.DEFAULT)}async fetchCart(){return console.log("DefaultCartAdapter: fetchCart called"),this.createSuccessResult({items:[],total:0,itemCount:0,currency:"USD",token:"default-token"},"Default cart fetched")}async addToCart(n,r=1,o){return console.log("DefaultCartAdapter: addToCart called",{variantId:n,quantity:r,properties:o}),this.createSuccessResult(void 0,"Item added to cart (mock)")}async removeFromCart(n){return console.log("DefaultCartAdapter: removeFromCart called",{itemId:n}),this.createSuccessResult(void 0,"Item removed from cart (mock)")}async updateQuantity(n){return console.log("DefaultCartAdapter: updateQuantity called",{cartItem:n}),this.createSuccessResult(void 0,"Item quantity updated (mock)")}async clearCart(){return console.log("DefaultCartAdapter: clearCart called"),this.createSuccessResult(void 0,"Cart cleared (mock)")}generateCartUrl(n){const r=n.replace(/^https?:\/\//,"");return console.log("DefaultCartAdapter: generateCartUrl called",{domain:n,sanitizedDomain:r}),`https://${r}/cart`}generateProductUrl(n,r){if(r.handle){const o=new URL(`https://${n}/products/${r.handle}`);return o.searchParams.append("variant",r.product_id),Os(o.toString())}else return Os(r.link)}async addCartAttributes(n={}){return console.log("MethodNotImplemented: addCartAttributes called",{attributes:n}),this.createSuccessResult(void 0,"Cart attributes added (mock)")}}class lme extends qk{constructor(){var n,r;super();ei(this,"platform",xi.SHOPIFY);ei(this,"cartEndpoint");ei(this,"localCartKey","debales_track_cart");this.cartEndpoint=((r=(n=window.Shopify)==null?void 0:n.routes)==null?void 0:r.root)||"/"}normalizeCartData(n){return{items:n.items.map(r=>({id:r.id,variant_id:r.variant_id,quantity:r.quantity,title:r.title,price:r.price,properties:r.properties})),total:n.total_price/100,itemCount:n.item_count,currency:n.currency,token:n.token.split("?")[0]}}generateProductUrl(n,r){const o=c8(n);if(!o.isValid)return"";if(r.handle){const a=new URL(`/products/${r.handle}`,o.url);return a.searchParams.append("variant",r.product_id),Os(a.toString())}else return Os(r.link)}updateTrackCart({cartToken:n,sessionId:r=nr()}){localStorage.setItem(this.localCartKey,JSON.stringify({sessionId:r,cartToken:n}))}async fetchCart(){try{const n=await fetch(`${this.cartEndpoint}cart.js`),r=await n.json();if(!n.ok){const a=r;return this.createErrorResult(a.description||`Failed to fetch cart: ${n.status}`)}const o=r;return this.createSuccessResult(this.normalizeCartData(o),"Cart fetched successfully")}catch(n){return this.createErrorResult(n instanceof Error?`Error fetching cart: ${n.message}`:"Unknown error occurred while fetching cart")}}async addToCart(n,r=1,o){try{const a=await fetch(`${this.cartEndpoint}cart/add.js`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({items:[{id:n,quantity:r,properties:o}],attributes:{dbls_order_source:"direct_recommendation",dbls_session_id:nr(),dbls_method:"add_to_cart"}})}),l=await a.json();if(!a.ok){const d=l;return this.createErrorResult(d.description||`Failed to add item to cart: ${a.status}`)}return this.fetchCart().then(d=>{d.success&&this.updateTrackCart({cartToken:d==null?void 0:d.data.token})}),this.createSuccessResult(void 0,`Successfully added ${r} item(s) to cart`)}catch(a){return this.createErrorResult(a instanceof Error?`Error adding to cart: ${a.message}`:"Unknown error occurred while adding to cart")}}async removeFromCart(n){return this.updateQuantity({id:n,quantity:0})}async updateQuantity(n){try{const r=await fetch(`${this.cartEndpoint}cart/change.js`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({id:n.id,quantity:n.quantity})}),o=await r.json();if(!r.ok){const a=o;return this.createErrorResult(a.description||`Failed to update item quantity: ${r.status}`)}return this.fetchCart().then(a=>{a.success&&this.updateTrackCart({cartToken:a==null?void 0:a.data.token})}),this.createSuccessResult(void 0,n.quantity===0?"Item removed from cart":`Quantity updated to ${n.quantity}`)}catch(r){return this.createErrorResult(r instanceof Error?`Error updating quantity: ${r.message}`:"Unknown error occurred while updating quantity")}}async clearCart(){try{const n=await fetch(`${this.cartEndpoint}cart/clear.js`,{method:"POST"});if(!n.ok){const r=await n.json();return this.createErrorResult(r.description||`Failed to clear cart: ${n.status}`)}return this.createSuccessResult(void 0,"Cart cleared successfully")}catch(n){return this.createErrorResult(n instanceof Error?`Error clearing cart: ${n.message}`:"Unknown error occurred while clearing cart")}}async addCartAttributes(n={}){try{const r=await fetch(`${this.cartEndpoint}cart/update.js`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({attributes:{dbls_order_source:"direct_recommendation",dbls_session_id:nr(),...n}})});if(!r.ok){const o=await r.json();return this.createErrorResult(o.description||`Failed to update cart attributes: ${r.status}`)}return this.createSuccessResult(void 0,"Cart attributes updated successfully")}catch(r){return this.createErrorResult(r instanceof Error?`Error updating cart attributes: ${r.message}`:"Unknown error occurred while updating cart attributes")}}generateCartUrl(n){const r=c8(n);if(!r.isValid)return"";const o=new URL("/cart",r.url);return o.searchParams.append("ref",`debales-ai-${new Date().toISOString()}`),o.searchParams.append("attributes[from]","debales-ai-chatbot"),o.searchParams.append("attributes[through]","add-to-cart"),o.searchParams.append("attributes[dbls_session_id]",nr()),o.searchParams.append("timestamp",Date.now().toString()),Os(o.toString())}}class ume extends qk{constructor(){var n,r;super();ei(this,"platform",xi.MAGENTO);ei(this,"checkoutEndpoint");ei(this,"baseUrl");this.checkoutEndpoint=((n=window.checkout)==null?void 0:n.checkoutUrl)||"/",this.baseUrl=((r=window.checkout)==null?void 0:r.baseUrl)||"/"}normalizeCartData(n){return{items:n.items.map(r=>({id:parseInt(r.item_id),variant_id:parseInt(r.product_id),quantity:r.qty,title:r.product_name,price:r.product_price_value,properties:{name:r.product_name}})),total:parseFloat(n.subtotalAmount),itemCount:n.summary_count,currency:"USD",token:n.data_id.toString()}}async fetchCart(){try{const n=await fetch(`${this.baseUrl}customer/section/load/?sections=cart&update_section_id=false`),r=await n.json();if(!n.ok)return this.createErrorResult(`Failed to fetch cart: ${n.status}`);const o=r.cart;return this.createSuccessResult(this.normalizeCartData(o),"Cart fetched successfully")}catch(n){return this.createErrorResult(n instanceof Error?`Error fetching cart: ${n.message}`:"Unknown error occurred while fetching cart")}}async addToCart(n,r=1){var o;try{const a=(o=document.querySelector('input[name="form_key"]'))==null?void 0:o.value;if(!a)return this.createErrorResult("Form key not found");const l=await fetch(`${this.checkoutEndpoint}cart/add`,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded","X-Requested-With":"XMLHttpRequest"},body:new URLSearchParams({product:n,qty:r.toString(),form_key:a})});if(!l.ok)return this.createErrorResult(`Failed to add item to cart: ${l.status}`);try{window.require(["Magento_Customer/js/customer-data"],d=>d.reload(["cart"],!0))}catch(d){console.warn("Failed to reload cart data:",d)}return this.createSuccessResult(void 0,`Successfully added ${r} item(s) to cart`)}catch(a){return this.createErrorResult(a instanceof Error?`Error adding to cart: ${a.message}`:"Unknown error occurred while adding to cart")}}async removeFromCart(n){return console.log("MethodNotImplemented: removeFromCart called",{itemId:n}),this.createSuccessResult(void 0,"Item removed from cart (mock)")}async updateQuantity(n){return console.log("MethodNotImplemented: updateQuantity called",{cartItem:n}),this.createSuccessResult(void 0,"Item quantity updated (mock)")}async clearCart(){return console.log("MethodNotImplemented: clearCart called"),this.createSuccessResult(void 0,"Cart cleared (mock)")}generateCartUrl(n){const r=new URL(`https://${n}/checkout/cart?ref=debales-ai-${new Date().toISOString()}&attributes[from]=debales-ai-chatbot&attributes[through]=add-to-cart`);return r.searchParams.append("timestamp",Date.now().toString()),r.toString()}generateProductUrl(n,r){const o=c8(n);if(!o.isValid)return"";if(r.handle){const a=new URL(`/${r.handle}.html`,o.url);return Os(a.toString())}else return Os(r.link)}async addCartAttributes(n={}){return console.log("MethodNotImplemented: addCartAttributes called",{attributes:n}),this.createSuccessResult(void 0,"Cart attributes added (mock)")}}var Gk={exports:{}};function cme(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Vk={exports:{}};const fme=vV(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var dme=Vk.exports,$H;function Jn(){return $H||($H=1,function(e,t){(function(n,r){e.exports=r()})(dme,function(){var n=n||function(r,o){var a;if(typeof window<"u"&&window.crypto&&(a=window.crypto),typeof self<"u"&&self.crypto&&(a=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(a=globalThis.crypto),!a&&typeof window<"u"&&window.msCrypto&&(a=window.msCrypto),!a&&typeof Gl<"u"&&Gl.crypto&&(a=Gl.crypto),!a&&typeof cme=="function")try{a=fme}catch{}var l=function(){if(a){if(typeof a.getRandomValues=="function")try{return a.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof a.randomBytes=="function")try{return a.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},d=Object.create||function(){function R(){}return function(O){var I;return R.prototype=O,I=new R,R.prototype=null,I}}(),h={},p=h.lib={},y=p.Base=function(){return{extend:function(R){var O=d(this);return R&&O.mixIn(R),(!O.hasOwnProperty("init")||this.init===O.init)&&(O.init=function(){O.$super.init.apply(this,arguments)}),O.init.prototype=O,O.$super=this,O},create:function(){var R=this.extend();return R.init.apply(R,arguments),R},init:function(){},mixIn:function(R){for(var O in R)R.hasOwnProperty(O)&&(this[O]=R[O]);R.hasOwnProperty("toString")&&(this.toString=R.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),m=p.WordArray=y.extend({init:function(R,O){R=this.words=R||[],O!=o?this.sigBytes=O:this.sigBytes=R.length*4},toString:function(R){return(R||_).stringify(this)},concat:function(R){var O=this.words,I=R.words,L=this.sigBytes,N=R.sigBytes;if(this.clamp(),L%4)for(var H=0;H<N;H++){var V=I[H>>>2]>>>24-H%4*8&255;O[L+H>>>2]|=V<<24-(L+H)%4*8}else for(var W=0;W<N;W+=4)O[L+W>>>2]=I[W>>>2];return this.sigBytes+=N,this},clamp:function(){var R=this.words,O=this.sigBytes;R[O>>>2]&=4294967295<<32-O%4*8,R.length=r.ceil(O/4)},clone:function(){var R=y.clone.call(this);return R.words=this.words.slice(0),R},random:function(R){for(var O=[],I=0;I<R;I+=4)O.push(l());return new m.init(O,R)}}),x=h.enc={},_=x.Hex={stringify:function(R){for(var O=R.words,I=R.sigBytes,L=[],N=0;N<I;N++){var H=O[N>>>2]>>>24-N%4*8&255;L.push((H>>>4).toString(16)),L.push((H&15).toString(16))}return L.join("")},parse:function(R){for(var O=R.length,I=[],L=0;L<O;L+=2)I[L>>>3]|=parseInt(R.substr(L,2),16)<<24-L%8*4;return new m.init(I,O/2)}},w=x.Latin1={stringify:function(R){for(var O=R.words,I=R.sigBytes,L=[],N=0;N<I;N++){var H=O[N>>>2]>>>24-N%4*8&255;L.push(String.fromCharCode(H))}return L.join("")},parse:function(R){for(var O=R.length,I=[],L=0;L<O;L++)I[L>>>2]|=(R.charCodeAt(L)&255)<<24-L%4*8;return new m.init(I,O)}},k=x.Utf8={stringify:function(R){try{return decodeURIComponent(escape(w.stringify(R)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(R){return w.parse(unescape(encodeURIComponent(R)))}},A=p.BufferedBlockAlgorithm=y.extend({reset:function(){this._data=new m.init,this._nDataBytes=0},_append:function(R){typeof R=="string"&&(R=k.parse(R)),this._data.concat(R),this._nDataBytes+=R.sigBytes},_process:function(R){var O,I=this._data,L=I.words,N=I.sigBytes,H=this.blockSize,V=H*4,W=N/V;R?W=r.ceil(W):W=r.max((W|0)-this._minBufferSize,0);var z=W*H,Q=r.min(z*4,N);if(z){for(var J=0;J<z;J+=H)this._doProcessBlock(L,J);O=L.splice(0,z),I.sigBytes-=Q}return new m.init(O,Q)},clone:function(){var R=y.clone.call(this);return R._data=this._data.clone(),R},_minBufferSize:0});p.Hasher=A.extend({cfg:y.extend(),init:function(R){this.cfg=this.cfg.extend(R),this.reset()},reset:function(){A.reset.call(this),this._doReset()},update:function(R){return this._append(R),this._process(),this},finalize:function(R){R&&this._append(R);var O=this._doFinalize();return O},blockSize:16,_createHelper:function(R){return function(O,I){return new R.init(I).finalize(O)}},_createHmacHelper:function(R){return function(O,I){return new E.HMAC.init(R,I).finalize(O)}}});var E=h.algo={};return h}(Math);return n})}(Vk)),Vk.exports}var Yk={exports:{}},hme=Yk.exports,BH;function Zk(){return BH||(BH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(hme,function(n){return function(r){var o=n,a=o.lib,l=a.Base,d=a.WordArray,h=o.x64={};h.Word=l.extend({init:function(p,y){this.high=p,this.low=y}}),h.WordArray=l.extend({init:function(p,y){p=this.words=p||[],y!=r?this.sigBytes=y:this.sigBytes=p.length*8},toX32:function(){for(var p=this.words,y=p.length,m=[],x=0;x<y;x++){var _=p[x];m.push(_.high),m.push(_.low)}return d.create(m,this.sigBytes)},clone:function(){for(var p=l.clone.call(this),y=p.words=this.words.slice(0),m=y.length,x=0;x<m;x++)y[x]=y[x].clone();return p}})}(),n})}(Yk)),Yk.exports}var Qk={exports:{}},pme=Qk.exports,LH;function gme(){return LH||(LH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(pme,function(n){return function(){if(typeof ArrayBuffer=="function"){var r=n,o=r.lib,a=o.WordArray,l=a.init,d=a.init=function(h){if(h instanceof ArrayBuffer&&(h=new Uint8Array(h)),(h instanceof Int8Array||typeof Uint8ClampedArray<"u"&&h instanceof Uint8ClampedArray||h instanceof Int16Array||h instanceof Uint16Array||h instanceof Int32Array||h instanceof Uint32Array||h instanceof Float32Array||h instanceof Float64Array)&&(h=new Uint8Array(h.buffer,h.byteOffset,h.byteLength)),h instanceof Uint8Array){for(var p=h.byteLength,y=[],m=0;m<p;m++)y[m>>>2]|=h[m]<<24-m%4*8;l.call(this,y,p)}else l.apply(this,arguments)};d.prototype=a}}(),n.lib.WordArray})}(Qk)),Qk.exports}var Kk={exports:{}},mme=Kk.exports,NH;function vme(){return NH||(NH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(mme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=r.enc;l.Utf16=l.Utf16BE={stringify:function(h){for(var p=h.words,y=h.sigBytes,m=[],x=0;x<y;x+=2){var _=p[x>>>2]>>>16-x%4*8&65535;m.push(String.fromCharCode(_))}return m.join("")},parse:function(h){for(var p=h.length,y=[],m=0;m<p;m++)y[m>>>1]|=h.charCodeAt(m)<<16-m%2*16;return a.create(y,p*2)}},l.Utf16LE={stringify:function(h){for(var p=h.words,y=h.sigBytes,m=[],x=0;x<y;x+=2){var _=d(p[x>>>2]>>>16-x%4*8&65535);m.push(String.fromCharCode(_))}return m.join("")},parse:function(h){for(var p=h.length,y=[],m=0;m<p;m++)y[m>>>1]|=d(h.charCodeAt(m)<<16-m%2*16);return a.create(y,p*2)}};function d(h){return h<<8&4278255360|h>>>8&16711935}}(),n.enc.Utf16})}(Kk)),Kk.exports}var Wk={exports:{}},yme=Wk.exports,zH;function Pp(){return zH||(zH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(yme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=r.enc;l.Base64={stringify:function(h){var p=h.words,y=h.sigBytes,m=this._map;h.clamp();for(var x=[],_=0;_<y;_+=3)for(var w=p[_>>>2]>>>24-_%4*8&255,k=p[_+1>>>2]>>>24-(_+1)%4*8&255,A=p[_+2>>>2]>>>24-(_+2)%4*8&255,E=w<<16|k<<8|A,R=0;R<4&&_+R*.75<y;R++)x.push(m.charAt(E>>>6*(3-R)&63));var O=m.charAt(64);if(O)for(;x.length%4;)x.push(O);return x.join("")},parse:function(h){var p=h.length,y=this._map,m=this._reverseMap;if(!m){m=this._reverseMap=[];for(var x=0;x<y.length;x++)m[y.charCodeAt(x)]=x}var _=y.charAt(64);if(_){var w=h.indexOf(_);w!==-1&&(p=w)}return d(h,p,m)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function d(h,p,y){for(var m=[],x=0,_=0;_<p;_++)if(_%4){var w=y[h.charCodeAt(_-1)]<<_%4*2,k=y[h.charCodeAt(_)]>>>6-_%4*2,A=w|k;m[x>>>2]|=A<<24-x%4*8,x++}return a.create(m,x)}}(),n.enc.Base64})}(Wk)),Wk.exports}var Xk={exports:{}},xme=Xk.exports,FH;function bme(){return FH||(FH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(xme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=r.enc;l.Base64url={stringify:function(h,p){p===void 0&&(p=!0);var y=h.words,m=h.sigBytes,x=p?this._safe_map:this._map;h.clamp();for(var _=[],w=0;w<m;w+=3)for(var k=y[w>>>2]>>>24-w%4*8&255,A=y[w+1>>>2]>>>24-(w+1)%4*8&255,E=y[w+2>>>2]>>>24-(w+2)%4*8&255,R=k<<16|A<<8|E,O=0;O<4&&w+O*.75<m;O++)_.push(x.charAt(R>>>6*(3-O)&63));var I=x.charAt(64);if(I)for(;_.length%4;)_.push(I);return _.join("")},parse:function(h,p){p===void 0&&(p=!0);var y=h.length,m=p?this._safe_map:this._map,x=this._reverseMap;if(!x){x=this._reverseMap=[];for(var _=0;_<m.length;_++)x[m.charCodeAt(_)]=_}var w=m.charAt(64);if(w){var k=h.indexOf(w);k!==-1&&(y=k)}return d(h,y,x)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function d(h,p,y){for(var m=[],x=0,_=0;_<p;_++)if(_%4){var w=y[h.charCodeAt(_-1)]<<_%4*2,k=y[h.charCodeAt(_)]>>>6-_%4*2,A=w|k;m[x>>>2]|=A<<24-x%4*8,x++}return a.create(m,x)}}(),n.enc.Base64url})}(Xk)),Xk.exports}var Jk={exports:{}},_me=Jk.exports,UH;function Hp(){return UH||(UH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(_me,function(n){return function(r){var o=n,a=o.lib,l=a.WordArray,d=a.Hasher,h=o.algo,p=[];(function(){for(var k=0;k<64;k++)p[k]=r.abs(r.sin(k+1))*4294967296|0})();var y=h.MD5=d.extend({_doReset:function(){this._hash=new l.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(k,A){for(var E=0;E<16;E++){var R=A+E,O=k[R];k[R]=(O<<8|O>>>24)&16711935|(O<<24|O>>>8)&4278255360}var I=this._hash.words,L=k[A+0],N=k[A+1],H=k[A+2],V=k[A+3],W=k[A+4],z=k[A+5],Q=k[A+6],J=k[A+7],ie=k[A+8],ee=k[A+9],de=k[A+10],ue=k[A+11],se=k[A+12],pe=k[A+13],Ce=k[A+14],B=k[A+15],P=I[0],ne=I[1],U=I[2],fe=I[3];P=m(P,ne,U,fe,L,7,p[0]),fe=m(fe,P,ne,U,N,12,p[1]),U=m(U,fe,P,ne,H,17,p[2]),ne=m(ne,U,fe,P,V,22,p[3]),P=m(P,ne,U,fe,W,7,p[4]),fe=m(fe,P,ne,U,z,12,p[5]),U=m(U,fe,P,ne,Q,17,p[6]),ne=m(ne,U,fe,P,J,22,p[7]),P=m(P,ne,U,fe,ie,7,p[8]),fe=m(fe,P,ne,U,ee,12,p[9]),U=m(U,fe,P,ne,de,17,p[10]),ne=m(ne,U,fe,P,ue,22,p[11]),P=m(P,ne,U,fe,se,7,p[12]),fe=m(fe,P,ne,U,pe,12,p[13]),U=m(U,fe,P,ne,Ce,17,p[14]),ne=m(ne,U,fe,P,B,22,p[15]),P=x(P,ne,U,fe,N,5,p[16]),fe=x(fe,P,ne,U,Q,9,p[17]),U=x(U,fe,P,ne,ue,14,p[18]),ne=x(ne,U,fe,P,L,20,p[19]),P=x(P,ne,U,fe,z,5,p[20]),fe=x(fe,P,ne,U,de,9,p[21]),U=x(U,fe,P,ne,B,14,p[22]),ne=x(ne,U,fe,P,W,20,p[23]),P=x(P,ne,U,fe,ee,5,p[24]),fe=x(fe,P,ne,U,Ce,9,p[25]),U=x(U,fe,P,ne,V,14,p[26]),ne=x(ne,U,fe,P,ie,20,p[27]),P=x(P,ne,U,fe,pe,5,p[28]),fe=x(fe,P,ne,U,H,9,p[29]),U=x(U,fe,P,ne,J,14,p[30]),ne=x(ne,U,fe,P,se,20,p[31]),P=_(P,ne,U,fe,z,4,p[32]),fe=_(fe,P,ne,U,ie,11,p[33]),U=_(U,fe,P,ne,ue,16,p[34]),ne=_(ne,U,fe,P,Ce,23,p[35]),P=_(P,ne,U,fe,N,4,p[36]),fe=_(fe,P,ne,U,W,11,p[37]),U=_(U,fe,P,ne,J,16,p[38]),ne=_(ne,U,fe,P,de,23,p[39]),P=_(P,ne,U,fe,pe,4,p[40]),fe=_(fe,P,ne,U,L,11,p[41]),U=_(U,fe,P,ne,V,16,p[42]),ne=_(ne,U,fe,P,Q,23,p[43]),P=_(P,ne,U,fe,ee,4,p[44]),fe=_(fe,P,ne,U,se,11,p[45]),U=_(U,fe,P,ne,B,16,p[46]),ne=_(ne,U,fe,P,H,23,p[47]),P=w(P,ne,U,fe,L,6,p[48]),fe=w(fe,P,ne,U,J,10,p[49]),U=w(U,fe,P,ne,Ce,15,p[50]),ne=w(ne,U,fe,P,z,21,p[51]),P=w(P,ne,U,fe,se,6,p[52]),fe=w(fe,P,ne,U,V,10,p[53]),U=w(U,fe,P,ne,de,15,p[54]),ne=w(ne,U,fe,P,N,21,p[55]),P=w(P,ne,U,fe,ie,6,p[56]),fe=w(fe,P,ne,U,B,10,p[57]),U=w(U,fe,P,ne,Q,15,p[58]),ne=w(ne,U,fe,P,pe,21,p[59]),P=w(P,ne,U,fe,W,6,p[60]),fe=w(fe,P,ne,U,ue,10,p[61]),U=w(U,fe,P,ne,H,15,p[62]),ne=w(ne,U,fe,P,ee,21,p[63]),I[0]=I[0]+P|0,I[1]=I[1]+ne|0,I[2]=I[2]+U|0,I[3]=I[3]+fe|0},_doFinalize:function(){var k=this._data,A=k.words,E=this._nDataBytes*8,R=k.sigBytes*8;A[R>>>5]|=128<<24-R%32;var O=r.floor(E/4294967296),I=E;A[(R+64>>>9<<4)+15]=(O<<8|O>>>24)&16711935|(O<<24|O>>>8)&4278255360,A[(R+64>>>9<<4)+14]=(I<<8|I>>>24)&16711935|(I<<24|I>>>8)&4278255360,k.sigBytes=(A.length+1)*4,this._process();for(var L=this._hash,N=L.words,H=0;H<4;H++){var V=N[H];N[H]=(V<<8|V>>>24)&16711935|(V<<24|V>>>8)&4278255360}return L},clone:function(){var k=d.clone.call(this);return k._hash=this._hash.clone(),k}});function m(k,A,E,R,O,I,L){var N=k+(A&E|~A&R)+O+L;return(N<<I|N>>>32-I)+A}function x(k,A,E,R,O,I,L){var N=k+(A&R|E&~R)+O+L;return(N<<I|N>>>32-I)+A}function _(k,A,E,R,O,I,L){var N=k+(A^E^R)+O+L;return(N<<I|N>>>32-I)+A}function w(k,A,E,R,O,I,L){var N=k+(E^(A|~R))+O+L;return(N<<I|N>>>32-I)+A}o.MD5=d._createHelper(y),o.HmacMD5=d._createHmacHelper(y)}(Math),n.MD5})}(Jk)),Jk.exports}var eT={exports:{}},Sme=eT.exports,jH;function PH(){return jH||(jH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(Sme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=o.Hasher,d=r.algo,h=[],p=d.SHA1=l.extend({_doReset:function(){this._hash=new a.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(y,m){for(var x=this._hash.words,_=x[0],w=x[1],k=x[2],A=x[3],E=x[4],R=0;R<80;R++){if(R<16)h[R]=y[m+R]|0;else{var O=h[R-3]^h[R-8]^h[R-14]^h[R-16];h[R]=O<<1|O>>>31}var I=(_<<5|_>>>27)+E+h[R];R<20?I+=(w&k|~w&A)+1518500249:R<40?I+=(w^k^A)+1859775393:R<60?I+=(w&k|w&A|k&A)-1894007588:I+=(w^k^A)-899497514,E=A,A=k,k=w<<30|w>>>2,w=_,_=I}x[0]=x[0]+_|0,x[1]=x[1]+w|0,x[2]=x[2]+k|0,x[3]=x[3]+A|0,x[4]=x[4]+E|0},_doFinalize:function(){var y=this._data,m=y.words,x=this._nDataBytes*8,_=y.sigBytes*8;return m[_>>>5]|=128<<24-_%32,m[(_+64>>>9<<4)+14]=Math.floor(x/4294967296),m[(_+64>>>9<<4)+15]=x,y.sigBytes=m.length*4,this._process(),this._hash},clone:function(){var y=l.clone.call(this);return y._hash=this._hash.clone(),y}});r.SHA1=l._createHelper(p),r.HmacSHA1=l._createHmacHelper(p)}(),n.SHA1})}(eT)),eT.exports}var tT={exports:{}},wme=tT.exports,HH;function J8(){return HH||(HH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(wme,function(n){return function(r){var o=n,a=o.lib,l=a.WordArray,d=a.Hasher,h=o.algo,p=[],y=[];(function(){function _(E){for(var R=r.sqrt(E),O=2;O<=R;O++)if(!(E%O))return!1;return!0}function w(E){return(E-(E|0))*4294967296|0}for(var k=2,A=0;A<64;)_(k)&&(A<8&&(p[A]=w(r.pow(k,.5))),y[A]=w(r.pow(k,.3333333333333333)),A++),k++})();var m=[],x=h.SHA256=d.extend({_doReset:function(){this._hash=new l.init(p.slice(0))},_doProcessBlock:function(_,w){for(var k=this._hash.words,A=k[0],E=k[1],R=k[2],O=k[3],I=k[4],L=k[5],N=k[6],H=k[7],V=0;V<64;V++){if(V<16)m[V]=_[w+V]|0;else{var W=m[V-15],z=(W<<25|W>>>7)^(W<<14|W>>>18)^W>>>3,Q=m[V-2],J=(Q<<15|Q>>>17)^(Q<<13|Q>>>19)^Q>>>10;m[V]=z+m[V-7]+J+m[V-16]}var ie=I&L^~I&N,ee=A&E^A&R^E&R,de=(A<<30|A>>>2)^(A<<19|A>>>13)^(A<<10|A>>>22),ue=(I<<26|I>>>6)^(I<<21|I>>>11)^(I<<7|I>>>25),se=H+ue+ie+y[V]+m[V],pe=de+ee;H=N,N=L,L=I,I=O+se|0,O=R,R=E,E=A,A=se+pe|0}k[0]=k[0]+A|0,k[1]=k[1]+E|0,k[2]=k[2]+R|0,k[3]=k[3]+O|0,k[4]=k[4]+I|0,k[5]=k[5]+L|0,k[6]=k[6]+N|0,k[7]=k[7]+H|0},_doFinalize:function(){var _=this._data,w=_.words,k=this._nDataBytes*8,A=_.sigBytes*8;return w[A>>>5]|=128<<24-A%32,w[(A+64>>>9<<4)+14]=r.floor(k/4294967296),w[(A+64>>>9<<4)+15]=k,_.sigBytes=w.length*4,this._process(),this._hash},clone:function(){var _=d.clone.call(this);return _._hash=this._hash.clone(),_}});o.SHA256=d._createHelper(x),o.HmacSHA256=d._createHmacHelper(x)}(Math),n.SHA256})}(tT)),tT.exports}var nT={exports:{}},Cme=nT.exports,qH;function Eme(){return qH||(qH=1,function(e,t){(function(n,r,o){e.exports=r(Jn(),J8())})(Cme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=r.algo,d=l.SHA256,h=l.SHA224=d.extend({_doReset:function(){this._hash=new a.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var p=d._doFinalize.call(this);return p.sigBytes-=4,p}});r.SHA224=d._createHelper(h),r.HmacSHA224=d._createHmacHelper(h)}(),n.SHA224})}(nT)),nT.exports}var rT={exports:{}},Ame=rT.exports,GH;function VH(){return GH||(GH=1,function(e,t){(function(n,r,o){e.exports=r(Jn(),Zk())})(Ame,function(n){return function(){var r=n,o=r.lib,a=o.Hasher,l=r.x64,d=l.Word,h=l.WordArray,p=r.algo;function y(){return d.create.apply(d,arguments)}var m=[y(1116352408,3609767458),y(1899447441,602891725),y(3049323471,3964484399),y(3921009573,2173295548),y(961987163,4081628472),y(1508970993,3053834265),y(2453635748,2937671579),y(2870763221,3664609560),y(3624381080,2734883394),y(310598401,1164996542),y(607225278,1323610764),y(1426881987,3590304994),y(1925078388,4068182383),y(2162078206,991336113),y(2614888103,633803317),y(3248222580,3479774868),y(3835390401,2666613458),y(4022224774,944711139),y(264347078,2341262773),y(604807628,2007800933),y(770255983,1495990901),y(1249150122,1856431235),y(1555081692,3175218132),y(1996064986,2198950837),y(2554220882,3999719339),y(2821834349,766784016),y(2952996808,2566594879),y(3210313671,3203337956),y(3336571891,1034457026),y(3584528711,2466948901),y(113926993,3758326383),y(338241895,168717936),y(666307205,1188179964),y(773529912,1546045734),y(1294757372,1522805485),y(1396182291,2643833823),y(1695183700,2343527390),y(1986661051,1014477480),y(2177026350,1206759142),y(2456956037,344077627),y(2730485921,1290863460),y(2820302411,3158454273),y(3259730800,3505952657),y(3345764771,106217008),y(3516065817,3606008344),y(3600352804,1432725776),y(4094571909,1467031594),y(275423344,851169720),y(430227734,3100823752),y(506948616,1363258195),y(659060556,3750685593),y(883997877,3785050280),y(958139571,3318307427),y(1322822218,3812723403),y(1537002063,2003034995),y(1747873779,3602036899),y(1955562222,1575990012),y(2024104815,1125592928),y(2227730452,2716904306),y(2361852424,442776044),y(2428436474,593698344),y(2756734187,3733110249),y(3204031479,2999351573),y(3329325298,3815920427),y(3391569614,3928383900),y(3515267271,566280711),y(3940187606,3454069534),y(4118630271,4000239992),y(116418474,1914138554),y(174292421,2731055270),y(289380356,3203993006),y(460393269,320620315),y(685471733,587496836),y(852142971,1086792851),y(1017036298,365543100),y(1126000580,2618297676),y(1288033470,3409855158),y(1501505948,4234509866),y(1607167915,987167468),y(1816402316,1246189591)],x=[];(function(){for(var w=0;w<80;w++)x[w]=y()})();var _=p.SHA512=a.extend({_doReset:function(){this._hash=new h.init([new d.init(1779033703,4089235720),new d.init(3144134277,2227873595),new d.init(1013904242,4271175723),new d.init(2773480762,1595750129),new d.init(1359893119,2917565137),new d.init(2600822924,725511199),new d.init(528734635,4215389547),new d.init(1541459225,327033209)])},_doProcessBlock:function(w,k){for(var A=this._hash.words,E=A[0],R=A[1],O=A[2],I=A[3],L=A[4],N=A[5],H=A[6],V=A[7],W=E.high,z=E.low,Q=R.high,J=R.low,ie=O.high,ee=O.low,de=I.high,ue=I.low,se=L.high,pe=L.low,Ce=N.high,B=N.low,P=H.high,ne=H.low,U=V.high,fe=V.low,Ae=W,Te=z,rt=Q,Ge=J,We=ie,Tt=ee,It=de,nt=ue,dt=se,bt=pe,Et=Ce,Nt=B,yt=P,re=ne,le=U,ve=fe,Ee=0;Ee<80;Ee++){var $e,Ve,lt=x[Ee];if(Ee<16)Ve=lt.high=w[k+Ee*2]|0,$e=lt.low=w[k+Ee*2+1]|0;else{var mt=x[Ee-15],_e=mt.high,Re=mt.low,Ct=(_e>>>1|Re<<31)^(_e>>>8|Re<<24)^_e>>>7,ct=(Re>>>1|_e<<31)^(Re>>>8|_e<<24)^(Re>>>7|_e<<25),Rt=x[Ee-2],Mt=Rt.high,en=Rt.low,Qt=(Mt>>>19|en<<13)^(Mt<<3|en>>>29)^Mt>>>6,gn=(en>>>19|Mt<<13)^(en<<3|Mt>>>29)^(en>>>6|Mt<<26),pt=x[Ee-7],Kt=pt.high,_t=pt.low,Y=x[Ee-16],xe=Y.high,it=Y.low;$e=ct+_t,Ve=Ct+Kt+($e>>>0<ct>>>0?1:0),$e=$e+gn,Ve=Ve+Qt+($e>>>0<gn>>>0?1:0),$e=$e+it,Ve=Ve+xe+($e>>>0<it>>>0?1:0),lt.high=Ve,lt.low=$e}var st=dt&Et^~dt&yt,St=bt&Nt^~bt&re,Pt=Ae&rt^Ae&We^rt&We,Ht=Te&Ge^Te&Tt^Ge&Tt,Yt=(Ae>>>28|Te<<4)^(Ae<<30|Te>>>2)^(Ae<<25|Te>>>7),qt=(Te>>>28|Ae<<4)^(Te<<30|Ae>>>2)^(Te<<25|Ae>>>7),ln=(dt>>>14|bt<<18)^(dt>>>18|bt<<14)^(dt<<23|bt>>>9),hr=(bt>>>14|dt<<18)^(bt>>>18|dt<<14)^(bt<<23|dt>>>9),xr=m[Ee],Ur=xr.high,nn=xr.low,yn=ve+hr,fn=le+ln+(yn>>>0<ve>>>0?1:0),yn=yn+St,fn=fn+st+(yn>>>0<St>>>0?1:0),yn=yn+nn,fn=fn+Ur+(yn>>>0<nn>>>0?1:0),yn=yn+$e,fn=fn+Ve+(yn>>>0<$e>>>0?1:0),ho=qt+Ht,br=Yt+Pt+(ho>>>0<qt>>>0?1:0);le=yt,ve=re,yt=Et,re=Nt,Et=dt,Nt=bt,bt=nt+yn|0,dt=It+fn+(bt>>>0<nt>>>0?1:0)|0,It=We,nt=Tt,We=rt,Tt=Ge,rt=Ae,Ge=Te,Te=yn+ho|0,Ae=fn+br+(Te>>>0<yn>>>0?1:0)|0}z=E.low=z+Te,E.high=W+Ae+(z>>>0<Te>>>0?1:0),J=R.low=J+Ge,R.high=Q+rt+(J>>>0<Ge>>>0?1:0),ee=O.low=ee+Tt,O.high=ie+We+(ee>>>0<Tt>>>0?1:0),ue=I.low=ue+nt,I.high=de+It+(ue>>>0<nt>>>0?1:0),pe=L.low=pe+bt,L.high=se+dt+(pe>>>0<bt>>>0?1:0),B=N.low=B+Nt,N.high=Ce+Et+(B>>>0<Nt>>>0?1:0),ne=H.low=ne+re,H.high=P+yt+(ne>>>0<re>>>0?1:0),fe=V.low=fe+ve,V.high=U+le+(fe>>>0<ve>>>0?1:0)},_doFinalize:function(){var w=this._data,k=w.words,A=this._nDataBytes*8,E=w.sigBytes*8;k[E>>>5]|=128<<24-E%32,k[(E+128>>>10<<5)+30]=Math.floor(A/4294967296),k[(E+128>>>10<<5)+31]=A,w.sigBytes=k.length*4,this._process();var R=this._hash.toX32();return R},clone:function(){var w=a.clone.call(this);return w._hash=this._hash.clone(),w},blockSize:1024/32});r.SHA512=a._createHelper(_),r.HmacSHA512=a._createHmacHelper(_)}(),n.SHA512})}(rT)),rT.exports}var iT={exports:{}},kme=iT.exports,YH;function Tme(){return YH||(YH=1,function(e,t){(function(n,r,o){e.exports=r(Jn(),Zk(),VH())})(kme,function(n){return function(){var r=n,o=r.x64,a=o.Word,l=o.WordArray,d=r.algo,h=d.SHA512,p=d.SHA384=h.extend({_doReset:function(){this._hash=new l.init([new a.init(3418070365,3238371032),new a.init(1654270250,914150663),new a.init(2438529370,812702999),new a.init(355462360,4144912697),new a.init(1731405415,4290775857),new a.init(2394180231,1750603025),new a.init(3675008525,1694076839),new a.init(1203062813,3204075428)])},_doFinalize:function(){var y=h._doFinalize.call(this);return y.sigBytes-=16,y}});r.SHA384=h._createHelper(p),r.HmacSHA384=h._createHmacHelper(p)}(),n.SHA384})}(iT)),iT.exports}var oT={exports:{}},Rme=oT.exports,ZH;function Ome(){return ZH||(ZH=1,function(e,t){(function(n,r,o){e.exports=r(Jn(),Zk())})(Rme,function(n){return function(r){var o=n,a=o.lib,l=a.WordArray,d=a.Hasher,h=o.x64,p=h.Word,y=o.algo,m=[],x=[],_=[];(function(){for(var A=1,E=0,R=0;R<24;R++){m[A+5*E]=(R+1)*(R+2)/2%64;var O=E%5,I=(2*A+3*E)%5;A=O,E=I}for(var A=0;A<5;A++)for(var E=0;E<5;E++)x[A+5*E]=E+(2*A+3*E)%5*5;for(var L=1,N=0;N<24;N++){for(var H=0,V=0,W=0;W<7;W++){if(L&1){var z=(1<<W)-1;z<32?V^=1<<z:H^=1<<z-32}L&128?L=L<<1^113:L<<=1}_[N]=p.create(H,V)}})();var w=[];(function(){for(var A=0;A<25;A++)w[A]=p.create()})();var k=y.SHA3=d.extend({cfg:d.cfg.extend({outputLength:512}),_doReset:function(){for(var A=this._state=[],E=0;E<25;E++)A[E]=new p.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(A,E){for(var R=this._state,O=this.blockSize/2,I=0;I<O;I++){var L=A[E+2*I],N=A[E+2*I+1];L=(L<<8|L>>>24)&16711935|(L<<24|L>>>8)&4278255360,N=(N<<8|N>>>24)&16711935|(N<<24|N>>>8)&4278255360;var H=R[I];H.high^=N,H.low^=L}for(var V=0;V<24;V++){for(var W=0;W<5;W++){for(var z=0,Q=0,J=0;J<5;J++){var H=R[W+5*J];z^=H.high,Q^=H.low}var ie=w[W];ie.high=z,ie.low=Q}for(var W=0;W<5;W++)for(var ee=w[(W+4)%5],de=w[(W+1)%5],ue=de.high,se=de.low,z=ee.high^(ue<<1|se>>>31),Q=ee.low^(se<<1|ue>>>31),J=0;J<5;J++){var H=R[W+5*J];H.high^=z,H.low^=Q}for(var pe=1;pe<25;pe++){var z,Q,H=R[pe],Ce=H.high,B=H.low,P=m[pe];P<32?(z=Ce<<P|B>>>32-P,Q=B<<P|Ce>>>32-P):(z=B<<P-32|Ce>>>64-P,Q=Ce<<P-32|B>>>64-P);var ne=w[x[pe]];ne.high=z,ne.low=Q}var U=w[0],fe=R[0];U.high=fe.high,U.low=fe.low;for(var W=0;W<5;W++)for(var J=0;J<5;J++){var pe=W+5*J,H=R[pe],Ae=w[pe],Te=w[(W+1)%5+5*J],rt=w[(W+2)%5+5*J];H.high=Ae.high^~Te.high&rt.high,H.low=Ae.low^~Te.low&rt.low}var H=R[0],Ge=_[V];H.high^=Ge.high,H.low^=Ge.low}},_doFinalize:function(){var A=this._data,E=A.words;this._nDataBytes*8;var R=A.sigBytes*8,O=this.blockSize*32;E[R>>>5]|=1<<24-R%32,E[(r.ceil((R+1)/O)*O>>>5)-1]|=128,A.sigBytes=E.length*4,this._process();for(var I=this._state,L=this.cfg.outputLength/8,N=L/8,H=[],V=0;V<N;V++){var W=I[V],z=W.high,Q=W.low;z=(z<<8|z>>>24)&16711935|(z<<24|z>>>8)&4278255360,Q=(Q<<8|Q>>>24)&16711935|(Q<<24|Q>>>8)&4278255360,H.push(Q),H.push(z)}return new l.init(H,L)},clone:function(){for(var A=d.clone.call(this),E=A._state=this._state.slice(0),R=0;R<25;R++)E[R]=E[R].clone();return A}});o.SHA3=d._createHelper(k),o.HmacSHA3=d._createHmacHelper(k)}(Math),n.SHA3})}(oT)),oT.exports}var aT={exports:{}},Dme=aT.exports,QH;function Mme(){return QH||(QH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(Dme,function(n){/** @preserve
5258
+ => User Action: Klaviyo form closed`}return""},j=te=>{te instanceof CustomEvent&&ce(te)};return window.addEventListener("klaviyoForms",j),()=>{window.removeEventListener("klaviyoForms",j)}},[dt,t,r]),Z.useEffect(()=>{const ce=ve.current;return We&&ce?(ce.addEventListener("scroll",fn),()=>{ce&&ce.removeEventListener("scroll",fn)}):()=>{}},[We,fn]);const[qn,ua]=Z.useState(!1),Oi=Q==="Highest"?"120px":Q==="Higher"?"60px":"15px",pr=async()=>{try{const ce=await fetch(`${Ti}/api/wordpress/support`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatid:nr()+e,nameSpace:e,userName:ct.name,userEmail:ct.email,userMessage:ct.message,tag:"support"})});if(ce.ok){const Ie=`support-confirm-${Date.now()}`;m(j=>[...j,{text:"Thanks for reaching out! Our support team has received your request and will get back to you within 24 hours.<br>In the meantime, feel free to continue chatting with me - I'll do my best to help!",isBot:!0,leading_queries:Mt,conversationId:Ie}]),d(Ie),_t(j=>({...j,leadingQueries:!0})),en([]),console.log("Connected to support with existing user info:",jo())}else{const Ie=await ce.json();console.error("Failed to connect to support:",Ie),m(j=>[...j,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}}catch{m(Ie=>[...Ie,{text:"Sorry, we couldn't connect you to support at the moment.<br>Please try again later.",isBot:!0}])}},Br=()=>{if(Me(e)){const te=Fp("https://test.thecollective.in/content/customersupport");te.isValid&&(t!=null&&t.shopifyShopDomain&&(te.url.hostname=t==null?void 0:t.shopifyShopDomain),window.open(Os(te.url.toString()),"_blank"));return}const ce=jo();let Ie=[];const j=h[h.length-1];j!=null&&j.leading_queries&&j.leading_queries.length>0?Ie=j.leading_queries:h.length<=1&&(Ie=P.flatMap(te=>Array.isArray(te)?te.map(he=>he.question):[te.question]).slice(0,4)),en(Ie),ce&&ce.name&&ce.email&&Rt({name:ce==null?void 0:ce.name,email:ce==null?void 0:ce.email,message:""}),m(te=>[...te,{text:"Please provide your name, email and message to connect with support.",isBot:!0}]),Ct(!0)},ca=async ce=>{ce.preventDefault();const Ie={name:"",email:"",message:""};let j=!0;const te=ct.name.trim(),he=ct.message.trim();te||(Ie.name="Name cannot be empty or just whitespace.",j=!1),(!ct.email||!zm.isEmail(ct.email))&&(Ie.email="Please enter a valid email address.",j=!1),he||(Ie.message="Message cannot be empty or just whitespace.",j=!1),gn(Ie),j&&(sf({name:te,email:ct.email}),Ct(!1),m(ke=>ke.slice(0,-1)),await pr())},[Kr,ot]=Z.useState({});return Z.useEffect(()=>{qt&&(h.forEach((ce,Ie)=>{if(!ce.isBot)return;const j=$p(ce.text);if(!(Ie in Kr)||Kr[Ie]<j.length){let te;const he=ke=>{ke<j.length&&(te=setTimeout(()=>{ot(we=>({...we,[Ie]:ke+1})),he(ke+1)},yn))};return Ie in Kr?he(Kr[Ie]):(ot(ke=>({...ke,[Ie]:1})),he(1)),()=>clearTimeout(te)}}),ot(ce=>{const Ie={};return h.forEach((j,te)=>{ce[te]!==void 0&&(Ie[te]=ce[te])}),Ie}))},[h,qt]),!t||t.show_bot===!1||a?null:M.jsxs(Jw,{theme:pE(t,e),children:[M.jsx("link",{rel:"preconnect",href:"https://fonts.googleapis.com"}),M.jsx("link",{rel:"preconnect",href:"https://fonts.gstatic.com",crossOrigin:"anonymous"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",rel:"stylesheet"}),M.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap",rel:"stylesheet"}),M.jsx(Qge,{}),M.jsxs(kge,{$topOffset:Oi,$isLeft:W,children:[!We&&P.length>0&&P[U]&&se&&M.jsx(Yge,{className:Ce?"visible":"",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Oi,style:{display:"flex",flexDirection:"column",alignItems:"center",opacity:Ce?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length>0&&P[U]&&M.jsx(Zge,{children:M.jsx(Cge,{messages:[{question:P[U].question,isHighlighted:P[U].isHighlighted??!1,show_for:(ee==null?void 0:ee.show_for)||4e3,hide_timing:(ee==null?void 0:ee.hide_timing)||4e3}],botId:e,uiData:t,onClose:()=>{Ve(ce=>{const Ie=new Set(ce);return Ie.add(P[U].question),Ie})},onClick:()=>{const ce=P[U];lt(!0,"suggested_question_clicked"),Ve(Ie=>{const j=new Set(Ie);return j.add(ce.question),j}),window.DebalesChat.track(tn.SUGGESTED_QUESTION_CLICKED,{suggested_question:ce}),E?(Yt(!1),ln(!0),A(!0),R(ce)):(Yt(!1),ln(!0),r({message:ce.Follow_up_Question??ce.question,answer:ce.answer,products:ce.products,fromKlaviyo:!1,leading_queries:ce.leading_queries,followUpQuestion:ce.Follow_up_Question,messType:"suggested_question"}))}})},P[U].question)}),M.jsxs(Tge,{$topOffset:Oi,$removeLogoBackground:t.removeLogoBackground,style:{display:We||se?"none":"flex"},children:[M.jsx(Rge,{$showAnimation:t.enableChatButtonBackgroundAnimation??!1,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",$backgroundColor:t.backgroundColor||"#fff",$removeLogoBackground:t.removeLogoBackground,$topOffset:Oi,$iconSize:H}),M.jsxs(Oge,{$backgroundColor:t.removeLogoBackground?"transparent":t.backgroundColor||"#fff",$botId:e,$iconSize:H,$removeLogoBackground:t.removeLogoBackground,topOffset:Oi,$showAnimation:t.enableChatButtonBackgroundAnimation,$animationType:"Ping",$animationColor:t.chatButtonBackgroundAnimationColor||"#f48722",id:"debales-chat-button","data-testid":"debales-chat-button",onClick:()=>{if(window.DebalesChat.track(tn.CHAT_BUTTON_CLICKED),lt(!We,"chat_button_clicked"),!We){const ce=_();ce.length>0?(m(ce),Yt(!1),ln(!0)):(Yt(!0),ln(!1),setTimeout(()=>{Yt(!1),ln(!0);const Ie={text:(t==null?void 0:t.initialMessage)||"Hi, I am an AI chatbot, how can I help you today?",isBot:!0};m([Ie])},(ee==null?void 0:ee.showing_delay)||2e3))}},"aria-label":"Chat",style:{display:We||se?"none":"flex"},children:[M.jsx(Dge,{$botId:e,$removeLogoBackground:t.removeLogoBackground,"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),(P==null?void 0:P.length)>0&&!We&&de&&M.jsx("div",{style:{position:"absolute",top:"0px",right:"0px",backgroundColor:"#f44336",color:"white",borderRadius:"50%",width:"20px",height:"20px",display:"flex",justifyContent:"center",alignItems:"center",fontSize:"12px",fontWeight:"bold",zIndex:2,opacity:de?1:0,transition:"opacity 0.3s ease-in-out"},children:P.length})]})]})]}),We&&vw.createPortal(M.jsx(M.Fragment,{children:M.jsxs(Bge,{$backgroundColor:t.backgroundColor||"#fff",$fullScreenOnMobile:t.fullScreenOnMobile,$headerFontColor:t.headerFontColor||"#1C1C1C",$isLeft:W,$topOffset:Oi,$mobileDisplayMode:t.mobileDisplayMode,$isVisible:It,"data-testid":"debales-chat-container",children:[M.jsxs(zge,{$backgroundColor:Me(e)?t.backgroundColor:t.botBackgroundColor||"#fff",style:{color:t.headerFontColor},children:[M.jsx("div",{style:{flexGrow:.1,display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden",marginRight:"8px",gap:"10px"},children:Me(e)?M.jsxs(M.Fragment,{children:[M.jsx(CH,{"aria-hidden":"true",src:t.bot_logo,alt:"Chat Bot Icon"}),Me(e)?M.jsx("div",{children:M.jsx("img",{src:yk,alt:"Chat Bot Icon",style:{height:"36px"}})}):M.jsxs(Mge,{$botNameColor:t.headerFontColor,children:[M.jsxs("div",{style:{fontWeight:"700",wordBreak:"break-word"},children:[t.chatbotName,e==="catch-org-ai"&&M.jsx($ge,{$backgroundColor:t.callToActionBackgroundColor,$fontColor:t.callToActionFontColor,children:"Beta"})]}),M.jsx(Ige,{})]})]}):M.jsx(Lge,{children:M.jsxs(Nge,{children:[M.jsx(CH,{src:t.bot_logo,alt:"Chat Bot Icon"}),M.jsx("span",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",display:"inline-block",maxWidth:"22ch"},children:t.chatbotName})]})})}),M.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"8px",marginLeft:"auto",flexShrink:0},children:[M.jsxs(Kge,{children:[M.jsx(EH,{$iconBG:t.backgroundColor,onClick:Br,"aria-label":"Support","data-testid":"debales-support-button",children:M.jsx(Tk,{color:t.headerFontColor})}),M.jsx(OH,{children:"Click to chat with a Live Support Agent now."})]}),M.jsx(EH,{$iconBG:t.backgroundColor,onClick:()=>{pt?ji(!0):lt(!1,"close_button_clicked")},id:"debales-minimize-button","data-testid":"debales-minimize-button","aria-label":"Minimize",children:M.jsx(Zm,{botNameColor:t.headerFontColor})})]}),M.jsx(rme,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:hr?1:0}})]}),M.jsxs(jge,{$backgroundColor:t.botBackgroundColor||"#fff",$mobileDisplayMode:t.mobileDisplayMode,children:[qn&&((at=(Oe=t.pluginConfig)==null?void 0:Oe.collectedUserInfo)==null?void 0:at.discount)&&M.jsx(Nk,{discount:t.pluginConfig.collectedUserInfo.discount,uiData:t,onClose:()=>{ua(!1),window.DebalesChat.track(tn.DISCOUNT_VIEWED,{discount:t.pluginConfig.collectedUserInfo.discount})}}),M.jsx(kk,{}),M.jsx(Pk,{uidata:t,product:Ho,showModel:ho,setShowModel:br,onVariantSelect:ce=>{I(ce.id,1),le(!0),window.DebalesChat.track(tn.ADD_TO_CART_CLICKED,{product:ce.title,price:Number(ce.price),link:`https://${t.shopifyShopDomain}/variants/${ce.id}`,message:l,chatId:nr()+e})},botId:e}),us&&M.jsx(zk,{setShowExitModal:ji,handleCloseChatbot:to,chatId:nr()+e}),M.jsxs(Fge,{id:"debales-conversation-group",$botBackgroundColor:t.botBackgroundColor||"#fff",ref:ve,$mobileDisplayMode:t.mobileDisplayMode,children:[M.jsx(tme,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:hr?1:0}}),M.jsxs(Uge,{children:[qt&&h.map((ce,Ie)=>{const j=ce.isBot,te=$p(ce.text);return ce.hideConfirmation?null:M.jsxs(Z.Fragment,{children:[j&&M.jsxs(AH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff","data-testid":"debales-ai-message-container",children:[M.jsx("img",{src:j?t.bot_logo:t.userMessage_logo,alt:"Chat User Icon",style:{marginLeft:"8px"}}),M.jsxs(RH,{children:[te.slice(0,Kr[Ie]||0).map((he,ke)=>M.jsx("div",{children:M.jsx(Ri,{isBot:j,children:M.jsx(bd,{remarkPlugins:[Mw,vE],children:he})})},ke)),ce.collections&&l===ce.conversationId&&Kt.collections&&M.jsx(Lk,{message:ce,botId:e,uidata:t,onSendMessage:r,loading:p}),ce.products&&l===ce.conversationId&&Kt.products&&M.jsx(Uk,{message:ce,botId:e,uidata:t,onSendMessage:r,loading:p,storeMetaData:n,platform:V,setShowVariantModel:br,setSelectedProduct:Dt,setCartVersion:yt}),o&&M.jsx(Q8,{children:M.jsx(Nx,{onClick:()=>{window._klOnsite&&(window._klOnsite.push(["openForm",Et]),lt(!1,"klaviyo_grab_deal_button"))},children:"πŸš€ Grab Deal Now!"})}),O&&O.itemCount>0&&l===ce.conversationId&&Kt.cartSummary&&re&&M.jsx(Mk,{onCheckout:po,onKeepShopping:()=>{le(!1)}}),mt&&mt.length>0&&l===ce.conversationId&&Kt.bulkItems&&M.jsx(mk,{onClick:()=>rr(ce.conversationId),children:"Add Bulk Items to Cart"}),k&&h.indexOf(ce)===h.length-1&&M.jsx(M.Fragment,{children:M.jsx(jk,{setShowModel:he=>{var we,Je;const ke=typeof he=="function"?he(k):he;A(ke),!ke&&((Je=(we=t.pluginConfig)==null?void 0:we.collectedUserInfo)!=null&&Je.discount)&&ua(!0)},inChat:!0,showFormInstructions:!1})}),Re&&h.indexOf(ce)===h.length-1&&M.jsxs(Wge,{onSubmit:ca,noValidate:!0,"data-testid":"debales-support-form",children:[Me(e)?M.jsxs(M.Fragment,{children:[M.jsx(ru,{label:"Name",name:"name",type:"text",value:ct.name,onChange:he=>Rt(ke=>({...ke,name:he.target.value})),required:!0,error:Qt.name,isCollectiveBot:!0}),M.jsx(ru,{label:"Email",name:"email",type:"email",value:ct.email,onChange:he=>Rt(ke=>({...ke,email:he.target.value})),required:!0,error:Qt.email,isCollectiveBot:!0}),M.jsx(Fk,{label:"Message",name:"message",value:ct.message,onChange:he=>Rt(ke=>({...ke,message:he.target.value})),required:!0,error:Qt.message,rows:4,isCollectiveBot:!0})]}):M.jsxs(M.Fragment,{children:[M.jsxs(K8,{children:[M.jsxs(W8,{children:["Name",M.jsx("span",{children:"*"})]}),M.jsx(DH,{type:"text",required:!0,value:ct.name,onChange:he=>Rt(ke=>({...ke,name:he.target.value})),placeholder:"John"}),Qt.name&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:Qt.name})]}),M.jsxs(K8,{children:[M.jsxs(W8,{children:["Email",M.jsx("span",{children:"*"})]}),M.jsx(DH,{type:"email",required:!0,value:ct.email,onChange:he=>Rt(ke=>({...ke,email:he.target.value})),placeholder:"olivia@untitledui.com"}),Qt.email&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:Qt.email})]}),M.jsxs(K8,{children:[M.jsxs(W8,{children:["Message",M.jsx("span",{children:"*"})]}),M.jsx(Xge,{required:!0,value:ct.message,onChange:he=>Rt(ke=>({...ke,message:he.target.value})),placeholder:"I need help with..."}),Qt.message&&M.jsx("p",{style:{color:"red",fontSize:"12px",margin:"4px 0 0"},children:Qt.message})]})]}),M.jsx(eme,{children:M.jsx(Jge,{type:"submit",children:"Submit"})})]}),it&&!p&&l===ce.conversationId&&M.jsx(Ri,{isBot:j,children:M.jsx(Ds,{loading:it,loadingPhrases:["🎨 Loading","✨ Almost","πŸš€ Ready"]})})]})]}),!j&&M.jsx(Gge,{$fontColor:t.userFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:M.jsx(Ri,{isBot:!!j,children:M.jsx(bd,{children:ce.text})})}),h.length==1&&Ie==0&&!k&&M.jsx(Q8,{children:Y.leadingQueries?M.jsx(Ri,{isBot:!0,children:M.jsx(Ds,{loading:Y.leadingQueries})}):P.map((he,ke)=>M.jsxs(TH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor,opacity:$e.has(he.question)?.5:1},onClick:()=>{E?(A(!0),R({question:he.question,answer:he.answer,products:he.products,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:he.question,answer:he.answer,products:he.products,messType:"leading_query"}),Ve(we=>{const Je=new Set(we);return Je.add(he.question),Je}),window.DebalesChat.track(tn.INITIAL_LEADING_QUERY_SUGGESTED_QUESTION_CLICKED,{question:he.question})},disabled:p,$disabled:p,children:[he.question,M.jsx(kH,{color:t.callToActionFontColor})]},ke))}),ce.leading_queries&&ce.leading_queries.length>0&&l===ce.conversationId&&Kt.leadingQueries&&!o&&!k&&M.jsx(Q8,{children:ce.leading_queries.map((he,ke)=>M.jsxs(TH,{style:{backgroundColor:t.callToActionBackgroundColor,color:t.callToActionFontColor},onClick:()=>{E?(A(!0),R({question:he,path:"/",nameSpace:window.DebalesChat.projectId})):r({message:he,messType:"leading_query"}),window.DebalesChat.track(tn.LEADING_QUERY_CLICKED,{query:he})},disabled:p,$disabled:p,children:[he,M.jsx(kH,{color:t.callToActionFontColor})]},ke))})]},Ie)}),(p||Ht)&&M.jsxs(AH,{$fontColor:t.botFontColor||"#000",$botMessageColor:t.botBackgroundColor||"#fff",children:[M.jsx("img",{src:t.bot_logo,alt:"Chat User Icon"}),M.jsx(RH,{children:M.jsx(Ri,{isBot:!0,children:M.jsx("div",{style:{display:"flex",alignItems:"center",gap:"4px",animation:"fadeIn 0.3s ease-in-out"},children:M.jsx(Ds,{loading:p||Ht})})})})]})]}),M.jsx(nme,{$backgroundColor:t.botBackgroundColor||"#fff",style:{opacity:Ur?1:0}})]}),M.jsxs("div",{className:"debales-footer-container",style:{width:"calc(100%-24px)",backgroundColor:t.botBackgroundColor||"#fff",color:t.fontColor||"#000"},children:[(e==="catch-org-ai"||e==="letsgo-catch")&&M.jsx(qge,{children:M.jsx("span",{children:`"${t.chatbotName}" can make mistakes.`})}),M.jsx("div",{children:M.jsx(Hk,{disabled:p,inputState:!1})}),(t.debales_branding??!0)&&M.jsxs(Pge,{href:"https://debales.ai/?open=true",target:"_blank",title:"debales-link",style:{color:t.fontColor?t.fontColor:"fff",marginTop:e==="catch-org-ai"?"0":"9px"},children:[M.jsx("p",{children:"Powered by"}),M.jsxs(Hge,{children:[M.jsx("img",{src:`${Ti}/images/debales_logo_d.png`,alt:"Debales logo"}),M.jsx("p",{children:"DEBALES"})]})]})]})]})]})}),z.shadowRoot)]})},ome=({botId:e})=>{const t=NZ("new-suggested-question-design");let n;return t==="variant-1"?n=z0e:t==="variant-2"?n=_ge:t==="variant-3"?n=ime:n=oH,M.jsx(n,{botId:e})},MH="debales-ai-assistant",IH="debales-chatbot-container",ame=Z.forwardRef(({children:e,globalStyles:t="",containerStyles:n={},onReady:r},o)=>{const a=Z.useRef(null),[l,d]=Z.useState(null),h=Z.useRef(null),p=Z.useRef(null),y=Z.useRef({get shadowRoot(){return h.current},get container(){return l},querySelector:m=>{var x;return((x=h.current)==null?void 0:x.querySelector(m))||null},querySelectorAll:m=>{var x;return((x=h.current)==null?void 0:x.querySelectorAll(m))||null}});return Z.useImperativeHandle(o,()=>y.current,[]),Z.useEffect(()=>{const m=document.getElementById(MH);if(m?a.current=m:a.current&&(a.current.id=MH),a.current&&(a.current.style.cssText="position: absolute; top: 0; left: 0; width: 0; height: 0;"),a.current){if(a.current.shadowRoot){h.current=a.current.shadowRoot;const w=h.current.querySelector(`#${IH}`);w&&d(w);return}const x=a.current.attachShadow({mode:"open"});if(h.current=x,t){const w=document.createElement("style");w.textContent=t,x.appendChild(w)}const _=document.createElement("div");_.id=IH,_.style.cssText="position: absolute; top: 0; left: 0; width: 0; height: 0;",x.appendChild(_),d(_),r&&r(x,_)}},[t,r]),Z.useEffect(()=>(l&&!p.current&&(p.current=L5.createRoot(l)),p.current&&l&&p.current.render(M.jsx(Xte,{target:l,children:M.jsx(Uj,{value:y.current,children:e})})),()=>{p.current&&p.current.unmount()}),[l,e]),M.jsx("div",{ref:a,style:n})});class qk{isSupported(){return hf.detect()===this.platform}createSuccessResult(t,n){return{success:!0,data:t,message:n}}createErrorResult(t){return{success:!1,error:t}}}class sme extends qk{constructor(){super(...arguments);ei(this,"platform",xi.DEFAULT)}async fetchCart(){return console.log("DefaultCartAdapter: fetchCart called"),this.createSuccessResult({items:[],total:0,itemCount:0,currency:"USD",token:"default-token"},"Default cart fetched")}async addToCart(n,r=1,o){return console.log("DefaultCartAdapter: addToCart called",{variantId:n,quantity:r,properties:o}),this.createSuccessResult(void 0,"Item added to cart (mock)")}async removeFromCart(n){return console.log("DefaultCartAdapter: removeFromCart called",{itemId:n}),this.createSuccessResult(void 0,"Item removed from cart (mock)")}async updateQuantity(n){return console.log("DefaultCartAdapter: updateQuantity called",{cartItem:n}),this.createSuccessResult(void 0,"Item quantity updated (mock)")}async clearCart(){return console.log("DefaultCartAdapter: clearCart called"),this.createSuccessResult(void 0,"Cart cleared (mock)")}generateCartUrl(n){const r=n.replace(/^https?:\/\//,"");return console.log("DefaultCartAdapter: generateCartUrl called",{domain:n,sanitizedDomain:r}),`https://${r}/cart`}generateProductUrl(n,r){if(r.handle){const o=new URL(`https://${n}/products/${r.handle}`);return o.searchParams.append("variant",r.product_id),Os(o.toString())}else return Os(r.link)}async addCartAttributes(n={}){return console.log("MethodNotImplemented: addCartAttributes called",{attributes:n}),this.createSuccessResult(void 0,"Cart attributes added (mock)")}}class lme extends qk{constructor(){var n,r;super();ei(this,"platform",xi.SHOPIFY);ei(this,"cartEndpoint");ei(this,"localCartKey","debales_track_cart");this.cartEndpoint=((r=(n=window.Shopify)==null?void 0:n.routes)==null?void 0:r.root)||"/"}normalizeCartData(n){return{items:n.items.map(r=>({id:r.id,variant_id:r.variant_id,quantity:r.quantity,title:r.title,price:r.price,properties:r.properties})),total:n.total_price/100,itemCount:n.item_count,currency:n.currency,token:n.token.split("?")[0]}}generateProductUrl(n,r){const o=c8(n);if(!o.isValid)return"";if(r.handle){const a=new URL(`/products/${r.handle}`,o.url);return a.searchParams.append("variant",r.product_id),Os(a.toString())}else return Os(r.link)}updateTrackCart({cartToken:n,sessionId:r=nr()}){localStorage.setItem(this.localCartKey,JSON.stringify({sessionId:r,cartToken:n}))}async fetchCart(){try{const n=await fetch(`${this.cartEndpoint}cart.js`),r=await n.json();if(!n.ok){const a=r;return this.createErrorResult(a.description||`Failed to fetch cart: ${n.status}`)}const o=r;return this.createSuccessResult(this.normalizeCartData(o),"Cart fetched successfully")}catch(n){return this.createErrorResult(n instanceof Error?`Error fetching cart: ${n.message}`:"Unknown error occurred while fetching cart")}}async addToCart(n,r=1,o){try{const a=await fetch(`${this.cartEndpoint}cart/add.js`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({items:[{id:n,quantity:r,properties:o}],attributes:{dbls_order_source:"direct_recommendation",dbls_session_id:nr(),dbls_method:"add_to_cart"}})}),l=await a.json();if(!a.ok){const d=l;return this.createErrorResult(d.description||`Failed to add item to cart: ${a.status}`)}return this.fetchCart().then(d=>{d.success&&this.updateTrackCart({cartToken:d==null?void 0:d.data.token})}),this.createSuccessResult(void 0,`Successfully added ${r} item(s) to cart`)}catch(a){return this.createErrorResult(a instanceof Error?`Error adding to cart: ${a.message}`:"Unknown error occurred while adding to cart")}}async removeFromCart(n){return this.updateQuantity({id:n,quantity:0})}async updateQuantity(n){try{const r=await fetch(`${this.cartEndpoint}cart/change.js`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({id:n.id,quantity:n.quantity})}),o=await r.json();if(!r.ok){const a=o;return this.createErrorResult(a.description||`Failed to update item quantity: ${r.status}`)}return this.fetchCart().then(a=>{a.success&&this.updateTrackCart({cartToken:a==null?void 0:a.data.token})}),this.createSuccessResult(void 0,n.quantity===0?"Item removed from cart":`Quantity updated to ${n.quantity}`)}catch(r){return this.createErrorResult(r instanceof Error?`Error updating quantity: ${r.message}`:"Unknown error occurred while updating quantity")}}async clearCart(){try{const n=await fetch(`${this.cartEndpoint}cart/clear.js`,{method:"POST"});if(!n.ok){const r=await n.json();return this.createErrorResult(r.description||`Failed to clear cart: ${n.status}`)}return this.createSuccessResult(void 0,"Cart cleared successfully")}catch(n){return this.createErrorResult(n instanceof Error?`Error clearing cart: ${n.message}`:"Unknown error occurred while clearing cart")}}async addCartAttributes(n={}){try{const r=await fetch(`${this.cartEndpoint}cart/update.js`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({attributes:{dbls_order_source:"direct_recommendation",dbls_session_id:nr(),...n}})});if(!r.ok){const o=await r.json();return this.createErrorResult(o.description||`Failed to update cart attributes: ${r.status}`)}return this.createSuccessResult(void 0,"Cart attributes updated successfully")}catch(r){return this.createErrorResult(r instanceof Error?`Error updating cart attributes: ${r.message}`:"Unknown error occurred while updating cart attributes")}}generateCartUrl(n){const r=c8(n);if(!r.isValid)return"";const o=new URL("/cart",r.url);return o.searchParams.append("ref",`debales-ai-${new Date().toISOString()}`),o.searchParams.append("attributes[from]","debales-ai-chatbot"),o.searchParams.append("attributes[through]","add-to-cart"),o.searchParams.append("attributes[dbls_session_id]",nr()),o.searchParams.append("timestamp",Date.now().toString()),Os(o.toString())}}class ume extends qk{constructor(){var n,r;super();ei(this,"platform",xi.MAGENTO);ei(this,"checkoutEndpoint");ei(this,"baseUrl");this.checkoutEndpoint=((n=window.checkout)==null?void 0:n.checkoutUrl)||"/",this.baseUrl=((r=window.checkout)==null?void 0:r.baseUrl)||"/"}normalizeCartData(n){return{items:n.items.map(r=>({id:parseInt(r.item_id),variant_id:parseInt(r.product_id),quantity:r.qty,title:r.product_name,price:r.product_price_value,properties:{name:r.product_name}})),total:parseFloat(n.subtotalAmount),itemCount:n.summary_count,currency:"USD",token:n.data_id.toString()}}async fetchCart(){try{const n=await fetch(`${this.baseUrl}customer/section/load/?sections=cart&update_section_id=false`),r=await n.json();if(!n.ok)return this.createErrorResult(`Failed to fetch cart: ${n.status}`);const o=r.cart;return this.createSuccessResult(this.normalizeCartData(o),"Cart fetched successfully")}catch(n){return this.createErrorResult(n instanceof Error?`Error fetching cart: ${n.message}`:"Unknown error occurred while fetching cart")}}async addToCart(n,r=1){var o;try{const a=(o=document.querySelector('input[name="form_key"]'))==null?void 0:o.value;if(!a)return this.createErrorResult("Form key not found");const l=await fetch(`${this.checkoutEndpoint}cart/add`,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded","X-Requested-With":"XMLHttpRequest"},body:new URLSearchParams({product:n,qty:r.toString(),form_key:a})});if(!l.ok)return this.createErrorResult(`Failed to add item to cart: ${l.status}`);try{window.require(["Magento_Customer/js/customer-data"],d=>d.reload(["cart"],!0))}catch(d){console.warn("Failed to reload cart data:",d)}return this.createSuccessResult(void 0,`Successfully added ${r} item(s) to cart`)}catch(a){return this.createErrorResult(a instanceof Error?`Error adding to cart: ${a.message}`:"Unknown error occurred while adding to cart")}}async removeFromCart(n){return console.log("MethodNotImplemented: removeFromCart called",{itemId:n}),this.createSuccessResult(void 0,"Item removed from cart (mock)")}async updateQuantity(n){return console.log("MethodNotImplemented: updateQuantity called",{cartItem:n}),this.createSuccessResult(void 0,"Item quantity updated (mock)")}async clearCart(){return console.log("MethodNotImplemented: clearCart called"),this.createSuccessResult(void 0,"Cart cleared (mock)")}generateCartUrl(n){const r=new URL(`https://${n}/checkout/cart?ref=debales-ai-${new Date().toISOString()}&attributes[from]=debales-ai-chatbot&attributes[through]=add-to-cart`);return r.searchParams.append("timestamp",Date.now().toString()),r.toString()}generateProductUrl(n,r){const o=c8(n);if(!o.isValid)return"";if(r.handle){const a=new URL(`/${r.handle}.html`,o.url);return Os(a.toString())}else return Os(r.link)}async addCartAttributes(n={}){return console.log("MethodNotImplemented: addCartAttributes called",{attributes:n}),this.createSuccessResult(void 0,"Cart attributes added (mock)")}}var Gk={exports:{}};function cme(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Vk={exports:{}};const fme=vV(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var dme=Vk.exports,$H;function Jn(){return $H||($H=1,function(e,t){(function(n,r){e.exports=r()})(dme,function(){var n=n||function(r,o){var a;if(typeof window<"u"&&window.crypto&&(a=window.crypto),typeof self<"u"&&self.crypto&&(a=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(a=globalThis.crypto),!a&&typeof window<"u"&&window.msCrypto&&(a=window.msCrypto),!a&&typeof Gl<"u"&&Gl.crypto&&(a=Gl.crypto),!a&&typeof cme=="function")try{a=fme}catch{}var l=function(){if(a){if(typeof a.getRandomValues=="function")try{return a.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof a.randomBytes=="function")try{return a.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},d=Object.create||function(){function R(){}return function(O){var I;return R.prototype=O,I=new R,R.prototype=null,I}}(),h={},p=h.lib={},y=p.Base=function(){return{extend:function(R){var O=d(this);return R&&O.mixIn(R),(!O.hasOwnProperty("init")||this.init===O.init)&&(O.init=function(){O.$super.init.apply(this,arguments)}),O.init.prototype=O,O.$super=this,O},create:function(){var R=this.extend();return R.init.apply(R,arguments),R},init:function(){},mixIn:function(R){for(var O in R)R.hasOwnProperty(O)&&(this[O]=R[O]);R.hasOwnProperty("toString")&&(this.toString=R.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),m=p.WordArray=y.extend({init:function(R,O){R=this.words=R||[],O!=o?this.sigBytes=O:this.sigBytes=R.length*4},toString:function(R){return(R||_).stringify(this)},concat:function(R){var O=this.words,I=R.words,L=this.sigBytes,N=R.sigBytes;if(this.clamp(),L%4)for(var H=0;H<N;H++){var V=I[H>>>2]>>>24-H%4*8&255;O[L+H>>>2]|=V<<24-(L+H)%4*8}else for(var W=0;W<N;W+=4)O[L+W>>>2]=I[W>>>2];return this.sigBytes+=N,this},clamp:function(){var R=this.words,O=this.sigBytes;R[O>>>2]&=4294967295<<32-O%4*8,R.length=r.ceil(O/4)},clone:function(){var R=y.clone.call(this);return R.words=this.words.slice(0),R},random:function(R){for(var O=[],I=0;I<R;I+=4)O.push(l());return new m.init(O,R)}}),x=h.enc={},_=x.Hex={stringify:function(R){for(var O=R.words,I=R.sigBytes,L=[],N=0;N<I;N++){var H=O[N>>>2]>>>24-N%4*8&255;L.push((H>>>4).toString(16)),L.push((H&15).toString(16))}return L.join("")},parse:function(R){for(var O=R.length,I=[],L=0;L<O;L+=2)I[L>>>3]|=parseInt(R.substr(L,2),16)<<24-L%8*4;return new m.init(I,O/2)}},w=x.Latin1={stringify:function(R){for(var O=R.words,I=R.sigBytes,L=[],N=0;N<I;N++){var H=O[N>>>2]>>>24-N%4*8&255;L.push(String.fromCharCode(H))}return L.join("")},parse:function(R){for(var O=R.length,I=[],L=0;L<O;L++)I[L>>>2]|=(R.charCodeAt(L)&255)<<24-L%4*8;return new m.init(I,O)}},k=x.Utf8={stringify:function(R){try{return decodeURIComponent(escape(w.stringify(R)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(R){return w.parse(unescape(encodeURIComponent(R)))}},A=p.BufferedBlockAlgorithm=y.extend({reset:function(){this._data=new m.init,this._nDataBytes=0},_append:function(R){typeof R=="string"&&(R=k.parse(R)),this._data.concat(R),this._nDataBytes+=R.sigBytes},_process:function(R){var O,I=this._data,L=I.words,N=I.sigBytes,H=this.blockSize,V=H*4,W=N/V;R?W=r.ceil(W):W=r.max((W|0)-this._minBufferSize,0);var z=W*H,Q=r.min(z*4,N);if(z){for(var J=0;J<z;J+=H)this._doProcessBlock(L,J);O=L.splice(0,z),I.sigBytes-=Q}return new m.init(O,Q)},clone:function(){var R=y.clone.call(this);return R._data=this._data.clone(),R},_minBufferSize:0});p.Hasher=A.extend({cfg:y.extend(),init:function(R){this.cfg=this.cfg.extend(R),this.reset()},reset:function(){A.reset.call(this),this._doReset()},update:function(R){return this._append(R),this._process(),this},finalize:function(R){R&&this._append(R);var O=this._doFinalize();return O},blockSize:16,_createHelper:function(R){return function(O,I){return new R.init(I).finalize(O)}},_createHmacHelper:function(R){return function(O,I){return new E.HMAC.init(R,I).finalize(O)}}});var E=h.algo={};return h}(Math);return n})}(Vk)),Vk.exports}var Yk={exports:{}},hme=Yk.exports,BH;function Zk(){return BH||(BH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(hme,function(n){return function(r){var o=n,a=o.lib,l=a.Base,d=a.WordArray,h=o.x64={};h.Word=l.extend({init:function(p,y){this.high=p,this.low=y}}),h.WordArray=l.extend({init:function(p,y){p=this.words=p||[],y!=r?this.sigBytes=y:this.sigBytes=p.length*8},toX32:function(){for(var p=this.words,y=p.length,m=[],x=0;x<y;x++){var _=p[x];m.push(_.high),m.push(_.low)}return d.create(m,this.sigBytes)},clone:function(){for(var p=l.clone.call(this),y=p.words=this.words.slice(0),m=y.length,x=0;x<m;x++)y[x]=y[x].clone();return p}})}(),n})}(Yk)),Yk.exports}var Qk={exports:{}},pme=Qk.exports,LH;function gme(){return LH||(LH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(pme,function(n){return function(){if(typeof ArrayBuffer=="function"){var r=n,o=r.lib,a=o.WordArray,l=a.init,d=a.init=function(h){if(h instanceof ArrayBuffer&&(h=new Uint8Array(h)),(h instanceof Int8Array||typeof Uint8ClampedArray<"u"&&h instanceof Uint8ClampedArray||h instanceof Int16Array||h instanceof Uint16Array||h instanceof Int32Array||h instanceof Uint32Array||h instanceof Float32Array||h instanceof Float64Array)&&(h=new Uint8Array(h.buffer,h.byteOffset,h.byteLength)),h instanceof Uint8Array){for(var p=h.byteLength,y=[],m=0;m<p;m++)y[m>>>2]|=h[m]<<24-m%4*8;l.call(this,y,p)}else l.apply(this,arguments)};d.prototype=a}}(),n.lib.WordArray})}(Qk)),Qk.exports}var Kk={exports:{}},mme=Kk.exports,NH;function vme(){return NH||(NH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(mme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=r.enc;l.Utf16=l.Utf16BE={stringify:function(h){for(var p=h.words,y=h.sigBytes,m=[],x=0;x<y;x+=2){var _=p[x>>>2]>>>16-x%4*8&65535;m.push(String.fromCharCode(_))}return m.join("")},parse:function(h){for(var p=h.length,y=[],m=0;m<p;m++)y[m>>>1]|=h.charCodeAt(m)<<16-m%2*16;return a.create(y,p*2)}},l.Utf16LE={stringify:function(h){for(var p=h.words,y=h.sigBytes,m=[],x=0;x<y;x+=2){var _=d(p[x>>>2]>>>16-x%4*8&65535);m.push(String.fromCharCode(_))}return m.join("")},parse:function(h){for(var p=h.length,y=[],m=0;m<p;m++)y[m>>>1]|=d(h.charCodeAt(m)<<16-m%2*16);return a.create(y,p*2)}};function d(h){return h<<8&4278255360|h>>>8&16711935}}(),n.enc.Utf16})}(Kk)),Kk.exports}var Wk={exports:{}},yme=Wk.exports,zH;function Pp(){return zH||(zH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(yme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=r.enc;l.Base64={stringify:function(h){var p=h.words,y=h.sigBytes,m=this._map;h.clamp();for(var x=[],_=0;_<y;_+=3)for(var w=p[_>>>2]>>>24-_%4*8&255,k=p[_+1>>>2]>>>24-(_+1)%4*8&255,A=p[_+2>>>2]>>>24-(_+2)%4*8&255,E=w<<16|k<<8|A,R=0;R<4&&_+R*.75<y;R++)x.push(m.charAt(E>>>6*(3-R)&63));var O=m.charAt(64);if(O)for(;x.length%4;)x.push(O);return x.join("")},parse:function(h){var p=h.length,y=this._map,m=this._reverseMap;if(!m){m=this._reverseMap=[];for(var x=0;x<y.length;x++)m[y.charCodeAt(x)]=x}var _=y.charAt(64);if(_){var w=h.indexOf(_);w!==-1&&(p=w)}return d(h,p,m)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function d(h,p,y){for(var m=[],x=0,_=0;_<p;_++)if(_%4){var w=y[h.charCodeAt(_-1)]<<_%4*2,k=y[h.charCodeAt(_)]>>>6-_%4*2,A=w|k;m[x>>>2]|=A<<24-x%4*8,x++}return a.create(m,x)}}(),n.enc.Base64})}(Wk)),Wk.exports}var Xk={exports:{}},xme=Xk.exports,FH;function bme(){return FH||(FH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(xme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=r.enc;l.Base64url={stringify:function(h,p){p===void 0&&(p=!0);var y=h.words,m=h.sigBytes,x=p?this._safe_map:this._map;h.clamp();for(var _=[],w=0;w<m;w+=3)for(var k=y[w>>>2]>>>24-w%4*8&255,A=y[w+1>>>2]>>>24-(w+1)%4*8&255,E=y[w+2>>>2]>>>24-(w+2)%4*8&255,R=k<<16|A<<8|E,O=0;O<4&&w+O*.75<m;O++)_.push(x.charAt(R>>>6*(3-O)&63));var I=x.charAt(64);if(I)for(;_.length%4;)_.push(I);return _.join("")},parse:function(h,p){p===void 0&&(p=!0);var y=h.length,m=p?this._safe_map:this._map,x=this._reverseMap;if(!x){x=this._reverseMap=[];for(var _=0;_<m.length;_++)x[m.charCodeAt(_)]=_}var w=m.charAt(64);if(w){var k=h.indexOf(w);k!==-1&&(y=k)}return d(h,y,x)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function d(h,p,y){for(var m=[],x=0,_=0;_<p;_++)if(_%4){var w=y[h.charCodeAt(_-1)]<<_%4*2,k=y[h.charCodeAt(_)]>>>6-_%4*2,A=w|k;m[x>>>2]|=A<<24-x%4*8,x++}return a.create(m,x)}}(),n.enc.Base64url})}(Xk)),Xk.exports}var Jk={exports:{}},_me=Jk.exports,UH;function Hp(){return UH||(UH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(_me,function(n){return function(r){var o=n,a=o.lib,l=a.WordArray,d=a.Hasher,h=o.algo,p=[];(function(){for(var k=0;k<64;k++)p[k]=r.abs(r.sin(k+1))*4294967296|0})();var y=h.MD5=d.extend({_doReset:function(){this._hash=new l.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(k,A){for(var E=0;E<16;E++){var R=A+E,O=k[R];k[R]=(O<<8|O>>>24)&16711935|(O<<24|O>>>8)&4278255360}var I=this._hash.words,L=k[A+0],N=k[A+1],H=k[A+2],V=k[A+3],W=k[A+4],z=k[A+5],Q=k[A+6],J=k[A+7],ie=k[A+8],ee=k[A+9],de=k[A+10],ue=k[A+11],se=k[A+12],pe=k[A+13],Ce=k[A+14],B=k[A+15],P=I[0],ne=I[1],U=I[2],fe=I[3];P=m(P,ne,U,fe,L,7,p[0]),fe=m(fe,P,ne,U,N,12,p[1]),U=m(U,fe,P,ne,H,17,p[2]),ne=m(ne,U,fe,P,V,22,p[3]),P=m(P,ne,U,fe,W,7,p[4]),fe=m(fe,P,ne,U,z,12,p[5]),U=m(U,fe,P,ne,Q,17,p[6]),ne=m(ne,U,fe,P,J,22,p[7]),P=m(P,ne,U,fe,ie,7,p[8]),fe=m(fe,P,ne,U,ee,12,p[9]),U=m(U,fe,P,ne,de,17,p[10]),ne=m(ne,U,fe,P,ue,22,p[11]),P=m(P,ne,U,fe,se,7,p[12]),fe=m(fe,P,ne,U,pe,12,p[13]),U=m(U,fe,P,ne,Ce,17,p[14]),ne=m(ne,U,fe,P,B,22,p[15]),P=x(P,ne,U,fe,N,5,p[16]),fe=x(fe,P,ne,U,Q,9,p[17]),U=x(U,fe,P,ne,ue,14,p[18]),ne=x(ne,U,fe,P,L,20,p[19]),P=x(P,ne,U,fe,z,5,p[20]),fe=x(fe,P,ne,U,de,9,p[21]),U=x(U,fe,P,ne,B,14,p[22]),ne=x(ne,U,fe,P,W,20,p[23]),P=x(P,ne,U,fe,ee,5,p[24]),fe=x(fe,P,ne,U,Ce,9,p[25]),U=x(U,fe,P,ne,V,14,p[26]),ne=x(ne,U,fe,P,ie,20,p[27]),P=x(P,ne,U,fe,pe,5,p[28]),fe=x(fe,P,ne,U,H,9,p[29]),U=x(U,fe,P,ne,J,14,p[30]),ne=x(ne,U,fe,P,se,20,p[31]),P=_(P,ne,U,fe,z,4,p[32]),fe=_(fe,P,ne,U,ie,11,p[33]),U=_(U,fe,P,ne,ue,16,p[34]),ne=_(ne,U,fe,P,Ce,23,p[35]),P=_(P,ne,U,fe,N,4,p[36]),fe=_(fe,P,ne,U,W,11,p[37]),U=_(U,fe,P,ne,J,16,p[38]),ne=_(ne,U,fe,P,de,23,p[39]),P=_(P,ne,U,fe,pe,4,p[40]),fe=_(fe,P,ne,U,L,11,p[41]),U=_(U,fe,P,ne,V,16,p[42]),ne=_(ne,U,fe,P,Q,23,p[43]),P=_(P,ne,U,fe,ee,4,p[44]),fe=_(fe,P,ne,U,se,11,p[45]),U=_(U,fe,P,ne,B,16,p[46]),ne=_(ne,U,fe,P,H,23,p[47]),P=w(P,ne,U,fe,L,6,p[48]),fe=w(fe,P,ne,U,J,10,p[49]),U=w(U,fe,P,ne,Ce,15,p[50]),ne=w(ne,U,fe,P,z,21,p[51]),P=w(P,ne,U,fe,se,6,p[52]),fe=w(fe,P,ne,U,V,10,p[53]),U=w(U,fe,P,ne,de,15,p[54]),ne=w(ne,U,fe,P,N,21,p[55]),P=w(P,ne,U,fe,ie,6,p[56]),fe=w(fe,P,ne,U,B,10,p[57]),U=w(U,fe,P,ne,Q,15,p[58]),ne=w(ne,U,fe,P,pe,21,p[59]),P=w(P,ne,U,fe,W,6,p[60]),fe=w(fe,P,ne,U,ue,10,p[61]),U=w(U,fe,P,ne,H,15,p[62]),ne=w(ne,U,fe,P,ee,21,p[63]),I[0]=I[0]+P|0,I[1]=I[1]+ne|0,I[2]=I[2]+U|0,I[3]=I[3]+fe|0},_doFinalize:function(){var k=this._data,A=k.words,E=this._nDataBytes*8,R=k.sigBytes*8;A[R>>>5]|=128<<24-R%32;var O=r.floor(E/4294967296),I=E;A[(R+64>>>9<<4)+15]=(O<<8|O>>>24)&16711935|(O<<24|O>>>8)&4278255360,A[(R+64>>>9<<4)+14]=(I<<8|I>>>24)&16711935|(I<<24|I>>>8)&4278255360,k.sigBytes=(A.length+1)*4,this._process();for(var L=this._hash,N=L.words,H=0;H<4;H++){var V=N[H];N[H]=(V<<8|V>>>24)&16711935|(V<<24|V>>>8)&4278255360}return L},clone:function(){var k=d.clone.call(this);return k._hash=this._hash.clone(),k}});function m(k,A,E,R,O,I,L){var N=k+(A&E|~A&R)+O+L;return(N<<I|N>>>32-I)+A}function x(k,A,E,R,O,I,L){var N=k+(A&R|E&~R)+O+L;return(N<<I|N>>>32-I)+A}function _(k,A,E,R,O,I,L){var N=k+(A^E^R)+O+L;return(N<<I|N>>>32-I)+A}function w(k,A,E,R,O,I,L){var N=k+(E^(A|~R))+O+L;return(N<<I|N>>>32-I)+A}o.MD5=d._createHelper(y),o.HmacMD5=d._createHmacHelper(y)}(Math),n.MD5})}(Jk)),Jk.exports}var eT={exports:{}},Sme=eT.exports,jH;function PH(){return jH||(jH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(Sme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=o.Hasher,d=r.algo,h=[],p=d.SHA1=l.extend({_doReset:function(){this._hash=new a.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(y,m){for(var x=this._hash.words,_=x[0],w=x[1],k=x[2],A=x[3],E=x[4],R=0;R<80;R++){if(R<16)h[R]=y[m+R]|0;else{var O=h[R-3]^h[R-8]^h[R-14]^h[R-16];h[R]=O<<1|O>>>31}var I=(_<<5|_>>>27)+E+h[R];R<20?I+=(w&k|~w&A)+1518500249:R<40?I+=(w^k^A)+1859775393:R<60?I+=(w&k|w&A|k&A)-1894007588:I+=(w^k^A)-899497514,E=A,A=k,k=w<<30|w>>>2,w=_,_=I}x[0]=x[0]+_|0,x[1]=x[1]+w|0,x[2]=x[2]+k|0,x[3]=x[3]+A|0,x[4]=x[4]+E|0},_doFinalize:function(){var y=this._data,m=y.words,x=this._nDataBytes*8,_=y.sigBytes*8;return m[_>>>5]|=128<<24-_%32,m[(_+64>>>9<<4)+14]=Math.floor(x/4294967296),m[(_+64>>>9<<4)+15]=x,y.sigBytes=m.length*4,this._process(),this._hash},clone:function(){var y=l.clone.call(this);return y._hash=this._hash.clone(),y}});r.SHA1=l._createHelper(p),r.HmacSHA1=l._createHmacHelper(p)}(),n.SHA1})}(eT)),eT.exports}var tT={exports:{}},wme=tT.exports,HH;function J8(){return HH||(HH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(wme,function(n){return function(r){var o=n,a=o.lib,l=a.WordArray,d=a.Hasher,h=o.algo,p=[],y=[];(function(){function _(E){for(var R=r.sqrt(E),O=2;O<=R;O++)if(!(E%O))return!1;return!0}function w(E){return(E-(E|0))*4294967296|0}for(var k=2,A=0;A<64;)_(k)&&(A<8&&(p[A]=w(r.pow(k,.5))),y[A]=w(r.pow(k,.3333333333333333)),A++),k++})();var m=[],x=h.SHA256=d.extend({_doReset:function(){this._hash=new l.init(p.slice(0))},_doProcessBlock:function(_,w){for(var k=this._hash.words,A=k[0],E=k[1],R=k[2],O=k[3],I=k[4],L=k[5],N=k[6],H=k[7],V=0;V<64;V++){if(V<16)m[V]=_[w+V]|0;else{var W=m[V-15],z=(W<<25|W>>>7)^(W<<14|W>>>18)^W>>>3,Q=m[V-2],J=(Q<<15|Q>>>17)^(Q<<13|Q>>>19)^Q>>>10;m[V]=z+m[V-7]+J+m[V-16]}var ie=I&L^~I&N,ee=A&E^A&R^E&R,de=(A<<30|A>>>2)^(A<<19|A>>>13)^(A<<10|A>>>22),ue=(I<<26|I>>>6)^(I<<21|I>>>11)^(I<<7|I>>>25),se=H+ue+ie+y[V]+m[V],pe=de+ee;H=N,N=L,L=I,I=O+se|0,O=R,R=E,E=A,A=se+pe|0}k[0]=k[0]+A|0,k[1]=k[1]+E|0,k[2]=k[2]+R|0,k[3]=k[3]+O|0,k[4]=k[4]+I|0,k[5]=k[5]+L|0,k[6]=k[6]+N|0,k[7]=k[7]+H|0},_doFinalize:function(){var _=this._data,w=_.words,k=this._nDataBytes*8,A=_.sigBytes*8;return w[A>>>5]|=128<<24-A%32,w[(A+64>>>9<<4)+14]=r.floor(k/4294967296),w[(A+64>>>9<<4)+15]=k,_.sigBytes=w.length*4,this._process(),this._hash},clone:function(){var _=d.clone.call(this);return _._hash=this._hash.clone(),_}});o.SHA256=d._createHelper(x),o.HmacSHA256=d._createHmacHelper(x)}(Math),n.SHA256})}(tT)),tT.exports}var nT={exports:{}},Cme=nT.exports,qH;function Eme(){return qH||(qH=1,function(e,t){(function(n,r,o){e.exports=r(Jn(),J8())})(Cme,function(n){return function(){var r=n,o=r.lib,a=o.WordArray,l=r.algo,d=l.SHA256,h=l.SHA224=d.extend({_doReset:function(){this._hash=new a.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var p=d._doFinalize.call(this);return p.sigBytes-=4,p}});r.SHA224=d._createHelper(h),r.HmacSHA224=d._createHmacHelper(h)}(),n.SHA224})}(nT)),nT.exports}var rT={exports:{}},Ame=rT.exports,GH;function VH(){return GH||(GH=1,function(e,t){(function(n,r,o){e.exports=r(Jn(),Zk())})(Ame,function(n){return function(){var r=n,o=r.lib,a=o.Hasher,l=r.x64,d=l.Word,h=l.WordArray,p=r.algo;function y(){return d.create.apply(d,arguments)}var m=[y(1116352408,3609767458),y(1899447441,602891725),y(3049323471,3964484399),y(3921009573,2173295548),y(961987163,4081628472),y(1508970993,3053834265),y(2453635748,2937671579),y(2870763221,3664609560),y(3624381080,2734883394),y(310598401,1164996542),y(607225278,1323610764),y(1426881987,3590304994),y(1925078388,4068182383),y(2162078206,991336113),y(2614888103,633803317),y(3248222580,3479774868),y(3835390401,2666613458),y(4022224774,944711139),y(264347078,2341262773),y(604807628,2007800933),y(770255983,1495990901),y(1249150122,1856431235),y(1555081692,3175218132),y(1996064986,2198950837),y(2554220882,3999719339),y(2821834349,766784016),y(2952996808,2566594879),y(3210313671,3203337956),y(3336571891,1034457026),y(3584528711,2466948901),y(113926993,3758326383),y(338241895,168717936),y(666307205,1188179964),y(773529912,1546045734),y(1294757372,1522805485),y(1396182291,2643833823),y(1695183700,2343527390),y(1986661051,1014477480),y(2177026350,1206759142),y(2456956037,344077627),y(2730485921,1290863460),y(2820302411,3158454273),y(3259730800,3505952657),y(3345764771,106217008),y(3516065817,3606008344),y(3600352804,1432725776),y(4094571909,1467031594),y(275423344,851169720),y(430227734,3100823752),y(506948616,1363258195),y(659060556,3750685593),y(883997877,3785050280),y(958139571,3318307427),y(1322822218,3812723403),y(1537002063,2003034995),y(1747873779,3602036899),y(1955562222,1575990012),y(2024104815,1125592928),y(2227730452,2716904306),y(2361852424,442776044),y(2428436474,593698344),y(2756734187,3733110249),y(3204031479,2999351573),y(3329325298,3815920427),y(3391569614,3928383900),y(3515267271,566280711),y(3940187606,3454069534),y(4118630271,4000239992),y(116418474,1914138554),y(174292421,2731055270),y(289380356,3203993006),y(460393269,320620315),y(685471733,587496836),y(852142971,1086792851),y(1017036298,365543100),y(1126000580,2618297676),y(1288033470,3409855158),y(1501505948,4234509866),y(1607167915,987167468),y(1816402316,1246189591)],x=[];(function(){for(var w=0;w<80;w++)x[w]=y()})();var _=p.SHA512=a.extend({_doReset:function(){this._hash=new h.init([new d.init(1779033703,4089235720),new d.init(3144134277,2227873595),new d.init(1013904242,4271175723),new d.init(2773480762,1595750129),new d.init(1359893119,2917565137),new d.init(2600822924,725511199),new d.init(528734635,4215389547),new d.init(1541459225,327033209)])},_doProcessBlock:function(w,k){for(var A=this._hash.words,E=A[0],R=A[1],O=A[2],I=A[3],L=A[4],N=A[5],H=A[6],V=A[7],W=E.high,z=E.low,Q=R.high,J=R.low,ie=O.high,ee=O.low,de=I.high,ue=I.low,se=L.high,pe=L.low,Ce=N.high,B=N.low,P=H.high,ne=H.low,U=V.high,fe=V.low,Ae=W,Te=z,rt=Q,Ge=J,We=ie,Tt=ee,It=de,nt=ue,dt=se,bt=pe,Et=Ce,Nt=B,yt=P,re=ne,le=U,ve=fe,Ee=0;Ee<80;Ee++){var $e,Ve,lt=x[Ee];if(Ee<16)Ve=lt.high=w[k+Ee*2]|0,$e=lt.low=w[k+Ee*2+1]|0;else{var mt=x[Ee-15],_e=mt.high,Re=mt.low,Ct=(_e>>>1|Re<<31)^(_e>>>8|Re<<24)^_e>>>7,ct=(Re>>>1|_e<<31)^(Re>>>8|_e<<24)^(Re>>>7|_e<<25),Rt=x[Ee-2],Mt=Rt.high,en=Rt.low,Qt=(Mt>>>19|en<<13)^(Mt<<3|en>>>29)^Mt>>>6,gn=(en>>>19|Mt<<13)^(en<<3|Mt>>>29)^(en>>>6|Mt<<26),pt=x[Ee-7],Kt=pt.high,_t=pt.low,Y=x[Ee-16],xe=Y.high,it=Y.low;$e=ct+_t,Ve=Ct+Kt+($e>>>0<ct>>>0?1:0),$e=$e+gn,Ve=Ve+Qt+($e>>>0<gn>>>0?1:0),$e=$e+it,Ve=Ve+xe+($e>>>0<it>>>0?1:0),lt.high=Ve,lt.low=$e}var st=dt&Et^~dt&yt,St=bt&Nt^~bt&re,Pt=Ae&rt^Ae&We^rt&We,Ht=Te&Ge^Te&Tt^Ge&Tt,Yt=(Ae>>>28|Te<<4)^(Ae<<30|Te>>>2)^(Ae<<25|Te>>>7),qt=(Te>>>28|Ae<<4)^(Te<<30|Ae>>>2)^(Te<<25|Ae>>>7),ln=(dt>>>14|bt<<18)^(dt>>>18|bt<<14)^(dt<<23|bt>>>9),hr=(bt>>>14|dt<<18)^(bt>>>18|dt<<14)^(bt<<23|dt>>>9),xr=m[Ee],Ur=xr.high,nn=xr.low,yn=ve+hr,fn=le+ln+(yn>>>0<ve>>>0?1:0),yn=yn+St,fn=fn+st+(yn>>>0<St>>>0?1:0),yn=yn+nn,fn=fn+Ur+(yn>>>0<nn>>>0?1:0),yn=yn+$e,fn=fn+Ve+(yn>>>0<$e>>>0?1:0),ho=qt+Ht,br=Yt+Pt+(ho>>>0<qt>>>0?1:0);le=yt,ve=re,yt=Et,re=Nt,Et=dt,Nt=bt,bt=nt+yn|0,dt=It+fn+(bt>>>0<nt>>>0?1:0)|0,It=We,nt=Tt,We=rt,Tt=Ge,rt=Ae,Ge=Te,Te=yn+ho|0,Ae=fn+br+(Te>>>0<yn>>>0?1:0)|0}z=E.low=z+Te,E.high=W+Ae+(z>>>0<Te>>>0?1:0),J=R.low=J+Ge,R.high=Q+rt+(J>>>0<Ge>>>0?1:0),ee=O.low=ee+Tt,O.high=ie+We+(ee>>>0<Tt>>>0?1:0),ue=I.low=ue+nt,I.high=de+It+(ue>>>0<nt>>>0?1:0),pe=L.low=pe+bt,L.high=se+dt+(pe>>>0<bt>>>0?1:0),B=N.low=B+Nt,N.high=Ce+Et+(B>>>0<Nt>>>0?1:0),ne=H.low=ne+re,H.high=P+yt+(ne>>>0<re>>>0?1:0),fe=V.low=fe+ve,V.high=U+le+(fe>>>0<ve>>>0?1:0)},_doFinalize:function(){var w=this._data,k=w.words,A=this._nDataBytes*8,E=w.sigBytes*8;k[E>>>5]|=128<<24-E%32,k[(E+128>>>10<<5)+30]=Math.floor(A/4294967296),k[(E+128>>>10<<5)+31]=A,w.sigBytes=k.length*4,this._process();var R=this._hash.toX32();return R},clone:function(){var w=a.clone.call(this);return w._hash=this._hash.clone(),w},blockSize:1024/32});r.SHA512=a._createHelper(_),r.HmacSHA512=a._createHmacHelper(_)}(),n.SHA512})}(rT)),rT.exports}var iT={exports:{}},kme=iT.exports,YH;function Tme(){return YH||(YH=1,function(e,t){(function(n,r,o){e.exports=r(Jn(),Zk(),VH())})(kme,function(n){return function(){var r=n,o=r.x64,a=o.Word,l=o.WordArray,d=r.algo,h=d.SHA512,p=d.SHA384=h.extend({_doReset:function(){this._hash=new l.init([new a.init(3418070365,3238371032),new a.init(1654270250,914150663),new a.init(2438529370,812702999),new a.init(355462360,4144912697),new a.init(1731405415,4290775857),new a.init(2394180231,1750603025),new a.init(3675008525,1694076839),new a.init(1203062813,3204075428)])},_doFinalize:function(){var y=h._doFinalize.call(this);return y.sigBytes-=16,y}});r.SHA384=h._createHelper(p),r.HmacSHA384=h._createHmacHelper(p)}(),n.SHA384})}(iT)),iT.exports}var oT={exports:{}},Rme=oT.exports,ZH;function Ome(){return ZH||(ZH=1,function(e,t){(function(n,r,o){e.exports=r(Jn(),Zk())})(Rme,function(n){return function(r){var o=n,a=o.lib,l=a.WordArray,d=a.Hasher,h=o.x64,p=h.Word,y=o.algo,m=[],x=[],_=[];(function(){for(var A=1,E=0,R=0;R<24;R++){m[A+5*E]=(R+1)*(R+2)/2%64;var O=E%5,I=(2*A+3*E)%5;A=O,E=I}for(var A=0;A<5;A++)for(var E=0;E<5;E++)x[A+5*E]=E+(2*A+3*E)%5*5;for(var L=1,N=0;N<24;N++){for(var H=0,V=0,W=0;W<7;W++){if(L&1){var z=(1<<W)-1;z<32?V^=1<<z:H^=1<<z-32}L&128?L=L<<1^113:L<<=1}_[N]=p.create(H,V)}})();var w=[];(function(){for(var A=0;A<25;A++)w[A]=p.create()})();var k=y.SHA3=d.extend({cfg:d.cfg.extend({outputLength:512}),_doReset:function(){for(var A=this._state=[],E=0;E<25;E++)A[E]=new p.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(A,E){for(var R=this._state,O=this.blockSize/2,I=0;I<O;I++){var L=A[E+2*I],N=A[E+2*I+1];L=(L<<8|L>>>24)&16711935|(L<<24|L>>>8)&4278255360,N=(N<<8|N>>>24)&16711935|(N<<24|N>>>8)&4278255360;var H=R[I];H.high^=N,H.low^=L}for(var V=0;V<24;V++){for(var W=0;W<5;W++){for(var z=0,Q=0,J=0;J<5;J++){var H=R[W+5*J];z^=H.high,Q^=H.low}var ie=w[W];ie.high=z,ie.low=Q}for(var W=0;W<5;W++)for(var ee=w[(W+4)%5],de=w[(W+1)%5],ue=de.high,se=de.low,z=ee.high^(ue<<1|se>>>31),Q=ee.low^(se<<1|ue>>>31),J=0;J<5;J++){var H=R[W+5*J];H.high^=z,H.low^=Q}for(var pe=1;pe<25;pe++){var z,Q,H=R[pe],Ce=H.high,B=H.low,P=m[pe];P<32?(z=Ce<<P|B>>>32-P,Q=B<<P|Ce>>>32-P):(z=B<<P-32|Ce>>>64-P,Q=Ce<<P-32|B>>>64-P);var ne=w[x[pe]];ne.high=z,ne.low=Q}var U=w[0],fe=R[0];U.high=fe.high,U.low=fe.low;for(var W=0;W<5;W++)for(var J=0;J<5;J++){var pe=W+5*J,H=R[pe],Ae=w[pe],Te=w[(W+1)%5+5*J],rt=w[(W+2)%5+5*J];H.high=Ae.high^~Te.high&rt.high,H.low=Ae.low^~Te.low&rt.low}var H=R[0],Ge=_[V];H.high^=Ge.high,H.low^=Ge.low}},_doFinalize:function(){var A=this._data,E=A.words;this._nDataBytes*8;var R=A.sigBytes*8,O=this.blockSize*32;E[R>>>5]|=1<<24-R%32,E[(r.ceil((R+1)/O)*O>>>5)-1]|=128,A.sigBytes=E.length*4,this._process();for(var I=this._state,L=this.cfg.outputLength/8,N=L/8,H=[],V=0;V<N;V++){var W=I[V],z=W.high,Q=W.low;z=(z<<8|z>>>24)&16711935|(z<<24|z>>>8)&4278255360,Q=(Q<<8|Q>>>24)&16711935|(Q<<24|Q>>>8)&4278255360,H.push(Q),H.push(z)}return new l.init(H,L)},clone:function(){for(var A=d.clone.call(this),E=A._state=this._state.slice(0),R=0;R<25;R++)E[R]=E[R].clone();return A}});o.SHA3=d._createHelper(k),o.HmacSHA3=d._createHmacHelper(k)}(Math),n.SHA3})}(oT)),oT.exports}var aT={exports:{}},Dme=aT.exports,QH;function Mme(){return QH||(QH=1,function(e,t){(function(n,r){e.exports=r(Jn())})(Dme,function(n){/** @preserve
5259
5259
  (c) 2012 by CΓ©dric Mesnil. All rights reserved.
5260
5260
 
5261
5261
  Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: