@wellesley/network 1.0.702 → 1.0.704

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.
Files changed (2) hide show
  1. package/index.mjs +1 -1
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -85,7 +85,7 @@ const R5=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),rA=(...e)=>e.f
85
85
  *
86
86
  * This source code is licensed under the MIT license found in the
87
87
  * LICENSE file in the root directory of this source tree.
88
- */function K8(){if(eR)return nn;eR=1;var e,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),s=Symbol.for("react.context"),u=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),m=Symbol.for("react.offscreen");function v(e){if("object"==typeof e&&null!==e){var m=e.$$typeof;switch(m){case t:switch(e=e.type){case r:case a:case o:case c:case d:return e;default:switch(e=e&&e.$$typeof){case u:case s:case l:case p:case f:case i:return e;default:return m}}case n:return m}}}return e=Symbol.for("react.module.reference"),nn.ContextConsumer=s,nn.ContextProvider=i,nn.Element=t,nn.ForwardRef=l,nn.Fragment=r,nn.Lazy=p,nn.Memo=f,nn.Portal=n,nn.Profiler=a,nn.StrictMode=o,nn.Suspense=c,nn.SuspenseList=d,nn.isAsyncMode=function(){return!1},nn.isConcurrentMode=function(){return!1},nn.isContextConsumer=function(e){return v(e)===s},nn.isContextProvider=function(e){return v(e)===i},nn.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},nn.isForwardRef=function(e){return v(e)===l},nn.isFragment=function(e){return v(e)===r},nn.isLazy=function(e){return v(e)===p},nn.isMemo=function(e){return v(e)===f},nn.isPortal=function(e){return v(e)===n},nn.isProfiler=function(e){return v(e)===a},nn.isStrictMode=function(e){return v(e)===o},nn.isSuspense=function(e){return v(e)===c},nn.isSuspenseList=function(e){return v(e)===d},nn.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===r||t===a||t===o||t===c||t===d||t===m||"object"==typeof t&&null!==t&&(t.$$typeof===p||t.$$typeof===f||t.$$typeof===i||t.$$typeof===s||t.$$typeof===l||t.$$typeof===e||void 0!==t.getModuleId)},nn.typeOf=v,nn}function Y8(){return tR||(tR=1,Xw.exports=K8()),Xw.exports}function hM(){if(nR)return Jw;nR=1;var e=Cl(),t=ta();return Jw=function(n){return"number"==typeof n||t(n)&&"[object Number]"==e(n)}}function Q8(){if(rR)return Zw;rR=1;var e=hM();return Zw=function(t){return e(t)&&t!=+t}}Y8(),Q8(),hM();var tb,oR,nb,iR,rb,aR,ob,sR,ib,uR,ab,lR,sb,cR,ub,dR,lb,fR,cb,pR,db,mR,fb,hR,pb,vR,mb,gR,hb,yR,vb,wR,gb,bR,yb,_R,wb,xR,bb,SR,_b,ER,xb,$R,Sb,CR,Eb,IR,Eg=function(e){return H8(e)&&e.indexOf("%")===e.length-1},X8=function(e){return"string"==typeof e?e:e?e.displayName||e.name||"Component":""},eb=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o]};function J8(){if(oR)return tb;oR=1;var e=Ty();return tb=function(){this.__data__=new e,this.size=0}}function Z8(){if(iR)return nb;return iR=1,nb=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}}function e9(){if(aR)return rb;return aR=1,rb=function(e){return this.__data__.get(e)}}function t9(){if(sR)return ob;return sR=1,ob=function(e){return this.__data__.has(e)}}function n9(){if(uR)return ib;uR=1;var e=Ty(),t=DE(),n=NE();return ib=function(r,o){var a=this.__data__;if(a instanceof e){var i=a.__data__;if(!t||i.length<199)return i.push([r,o]),this.size=++a.size,this;a=this.__data__=new n(i)}return a.set(r,o),this.size=a.size,this}}function kE(){if(lR)return ab;lR=1;var e=Ty(),t=J8(),n=Z8(),r=e9(),o=t9(),a=n9();function i(t){var n=this.__data__=new e(t);this.size=n.size}return i.prototype.clear=t,i.prototype.delete=n,i.prototype.get=r,i.prototype.has=o,i.prototype.set=a,ab=i}function r9(){if(cR)return sb;cR=1;return sb=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}}function o9(){if(dR)return ub;return dR=1,ub=function(e){return this.__data__.has(e)}}function i9(){if(fR)return lb;fR=1;var e=NE(),t=r9(),n=o9();function r(t){var n=-1,r=null==t?0:t.length;for(this.__data__=new e;++n<r;)this.add(t[n])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,lb=r}function a9(){if(pR)return cb;return pR=1,cb=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}}function s9(){if(mR)return db;return mR=1,db=function(e,t){return e.has(t)}}function vM(){if(hR)return fb;hR=1;var e=i9(),t=a9(),n=s9();return fb=function(r,o,a,i,s,u){var l=1&a,c=r.length,d=o.length;if(c!=d&&!(l&&d>c))return!1;var f=u.get(r),p=u.get(o);if(f&&p)return f==o&&p==r;var m=-1,v=!0,h=2&a?new e:void 0;for(u.set(r,o),u.set(o,r);++m<c;){var g=r[m],y=o[m];if(i)var b=l?i(y,g,m,o,r,u):i(g,y,m,r,o,u);if(void 0!==b){if(b)continue;v=!1;break}if(h){if(!t(o,(function(e,t){if(!n(h,t)&&(g===e||s(g,e,a,i,u)))return h.push(t)}))){v=!1;break}}else if(g!==y&&!s(g,y,a,i,u)){v=!1;break}}return u.delete(r),u.delete(o),v}}function gM(){if(vR)return pb;vR=1;var e=ri().Uint8Array;return pb=e}function u9(){if(gR)return mb;return gR=1,mb=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}}function l9(){if(yR)return hb;return yR=1,hb=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}}function c9(){if(wR)return vb;wR=1;var e=zm(),t=gM(),n=ME(),r=vM(),o=u9(),a=l9(),i=e?e.prototype:void 0,s=i?i.valueOf:void 0;return vb=function(e,i,u,l,c,d,f){switch(u){case"[object DataView]":if(e.byteLength!=i.byteLength||e.byteOffset!=i.byteOffset)return!1;e=e.buffer,i=i.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=i.byteLength||!d(new t(e),new t(i)));case"[object Boolean]":case"[object Date]":case"[object Number]":return n(+e,+i);case"[object Error]":return e.name==i.name&&e.message==i.message;case"[object RegExp]":case"[object String]":return e==i+"";case"[object Map]":var p=o;case"[object Set]":var m=1&l;if(p||(p=a),e.size!=i.size&&!m)return!1;var v=f.get(e);if(v)return v==i;l|=2,f.set(e,i);var h=r(p(e),p(i),l,c,d,f);return f.delete(e),h;case"[object Symbol]":if(s)return s.call(e)==s.call(i)}return!1}}function LE(){if(bR)return gb;return bR=1,gb=function(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}}function yM(){if(_R)return yb;_R=1;var e=LE(),t=Ei();return yb=function(n,r,o){var a=r(n);return t(n)?a:e(a,o(n))}}function d9(){if(xR)return wb;return xR=1,wb=function(e,t){for(var n=-1,r=null==e?0:e.length,o=0,a=[];++n<r;){var i=e[n];t(i,n,e)&&(a[o++]=i)}return a}}function wM(){if(SR)return bb;return SR=1,bb=function(){return[]}}function FE(){if(ER)return _b;ER=1;var e=d9(),t=wM(),n=Object.prototype.propertyIsEnumerable,r=Object.getOwnPropertySymbols;return _b=r?function(t){return null==t?[]:(t=Object(t),e(r(t),(function(e){return n.call(t,e)})))}:t}function f9(){if($R)return xb;return $R=1,xb=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}}function p9(){if(CR)return Sb;CR=1;var e=Cl(),t=ta();return Sb=function(n){return t(n)&&"[object Arguments]"==e(n)}}function BE(){if(IR)return Eb;IR=1;var e=p9(),t=ta(),n=Object.prototype,r=n.hasOwnProperty,o=n.propertyIsEnumerable,a=e(function(){return arguments}())?e:function(e){return t(e)&&r.call(e,"callee")&&!o.call(e,"callee")};return Eb=a}var $b,RR,PR,Cb,TR,Ib,OR,Rb,AR,Pb,MR,Xh={exports:{}};function m9(){if(RR)return $b;return RR=1,$b=function(){return!1}}function jE(){return PR||(PR=1,e=Xh,t=Xh.exports,n=ri(),r=m9(),o=t&&!t.nodeType&&t,a=o&&e&&!e.nodeType&&e,i=a&&a.exports===o?n.Buffer:void 0,s=(i?i.isBuffer:void 0)||r,e.exports=s),Xh.exports;var e,t,n,r,o,a,i,s}function zE(){if(TR)return Cb;TR=1;var e=/^(?:0|[1-9]\d*)$/;return Cb=function(t,n){var r=typeof t;return!!(n=n??9007199254740991)&&("number"==r||"symbol"!=r&&e.test(t))&&t>-1&&t%1==0&&t<n}}function VE(){if(OR)return Ib;OR=1;return Ib=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}}function h9(){if(AR)return Rb;AR=1;var e=Cl(),t=VE(),n=ta(),r={};return r["[object Float32Array]"]=r["[object Float64Array]"]=r["[object Int8Array]"]=r["[object Int16Array]"]=r["[object Int32Array]"]=r["[object Uint8Array]"]=r["[object Uint8ClampedArray]"]=r["[object Uint16Array]"]=r["[object Uint32Array]"]=!0,r["[object Arguments]"]=r["[object Array]"]=r["[object ArrayBuffer]"]=r["[object Boolean]"]=r["[object DataView]"]=r["[object Date]"]=r["[object Error]"]=r["[object Function]"]=r["[object Map]"]=r["[object Number]"]=r["[object Object]"]=r["[object RegExp]"]=r["[object Set]"]=r["[object String]"]=r["[object WeakMap]"]=!1,Rb=function(o){return n(o)&&t(o.length)&&!!r[e(o)]}}function UE(){if(MR)return Pb;return MR=1,Pb=function(e){return function(t){return e(t)}}}Xh.exports;var DR,Tb,NR,Ob,kR,Ab,LR,Mb,FR,Db,BR,Nb,jR,kb,zR,Lb,VR,Fb,UR,Bb,WR,jb,qR,zb,GR,Vb,HR,Ub,KR,Wb,YR,qb,QR,Gb,XR,Hb,JR,Kb,ZR,Yb,eP,Qb,tP,Xb,nP,Jb,rP,Zb,oP,e_,iP,t_,aP,n_,sP,r_,uP,o_,lP,i_,cP,a_,dP,s_,fP,u_,pP,l_,mP,c_,hP,d_,vP,f_,gP,p_,yP,m_,wP,h_,bP,v_,_P,g_,xP,y_,SP,w_,EP,b_,$P,__,CP,x_,IP,S_,RP,E_,PP,$_,TP,C_,OP,I_,AP,Jh={exports:{}};function WE(){return DR||(DR=1,e=Jh,t=Jh.exports,n=sM(),r=t&&!t.nodeType&&t,o=r&&e&&!e.nodeType&&e,a=o&&o.exports===r&&n.process,i=function(){try{return o&&o.require&&o.require("util").types||a&&a.binding&&a.binding("util")}catch{}}(),e.exports=i),Jh.exports;var e,t,n,r,o,a,i}function bM(){if(NR)return Tb;NR=1;var e=h9(),t=UE(),n=WE(),r=n&&n.isTypedArray,o=r?t(r):e;return Tb=o}function _M(){if(kR)return Ob;kR=1;var e=f9(),t=BE(),n=Ei(),r=jE(),o=zE(),a=bM(),i=Object.prototype.hasOwnProperty;return Ob=function(s,u){var l=n(s),c=!l&&t(s),d=!l&&!c&&r(s),f=!l&&!c&&!d&&a(s),p=l||c||d||f,m=p?e(s.length,String):[],v=m.length;for(var h in s)(u||i.call(s,h))&&(!p||!("length"==h||d&&("offset"==h||"parent"==h)||f&&("buffer"==h||"byteLength"==h||"byteOffset"==h)||o(h,v)))&&m.push(h);return m}}function qE(){if(LR)return Ab;LR=1;var e=Object.prototype;return Ab=function(t){var n=t&&t.constructor;return t===("function"==typeof n&&n.prototype||e)}}function xM(){if(FR)return Mb;return FR=1,Mb=function(e,t){return function(n){return e(t(n))}}}function v9(){if(BR)return Db;BR=1;var e=xM()(Object.keys,Object);return Db=e}function SM(){if(jR)return Nb;jR=1;var e=qE(),t=v9(),n=Object.prototype.hasOwnProperty;return Nb=function(r){if(!e(r))return t(r);var o=[];for(var a in Object(r))n.call(r,a)&&"constructor"!=a&&o.push(a);return o}}function EM(){if(zR)return kb;zR=1;var e=Iy(),t=VE();return kb=function(n){return null!=n&&t(n.length)&&!e(n)}}function Ay(){if(VR)return Lb;VR=1;var e=_M(),t=SM(),n=EM();return Lb=function(r){return n(r)?e(r):t(r)}}function $M(){if(UR)return Fb;UR=1;var e=yM(),t=FE(),n=Ay();return Fb=function(r){return e(r,n,t)}}function g9(){if(WR)return Bb;WR=1;var e=$M(),t=Object.prototype.hasOwnProperty;return Bb=function(n,r,o,a,i,s){var u=1&o,l=e(n),c=l.length;if(c!=e(r).length&&!u)return!1;for(var d=c;d--;){var f=l[d];if(!(u?f in r:t.call(r,f)))return!1}var p=s.get(n),m=s.get(r);if(p&&m)return p==r&&m==n;var v=!0;s.set(n,r),s.set(r,n);for(var h=u;++d<c;){var g=n[f=l[d]],y=r[f];if(a)var b=u?a(y,g,f,r,n,s):a(g,y,f,n,r,s);if(!(void 0===b?g===y||i(g,y,o,a,s):b)){v=!1;break}h||(h="constructor"==f)}if(v&&!h){var w=n.constructor,x=r.constructor;w!=x&&"constructor"in n&&"constructor"in r&&!("function"==typeof w&&w instanceof w&&"function"==typeof x&&x instanceof x)&&(v=!1)}return s.delete(n),s.delete(r),v}}function y9(){if(qR)return jb;qR=1;var e=Zf()(ri(),"DataView");return jb=e}function w9(){if(GR)return zb;GR=1;var e=Zf()(ri(),"Promise");return zb=e}function b9(){if(HR)return Vb;HR=1;var e=Zf()(ri(),"Set");return Vb=e}function CM(){if(KR)return Ub;KR=1;var e=Zf()(ri(),"WeakMap");return Ub=e}function kv(){if(YR)return Wb;YR=1;var e=y9(),t=DE(),n=w9(),r=b9(),o=CM(),a=Cl(),i=uM(),s="[object Map]",u="[object Promise]",l="[object Set]",c="[object WeakMap]",d="[object DataView]",f=i(e),p=i(t),m=i(n),v=i(r),h=i(o),g=a;return(e&&g(new e(new ArrayBuffer(1)))!=d||t&&g(new t)!=s||n&&g(n.resolve())!=u||r&&g(new r)!=l||o&&g(new o)!=c)&&(g=function(e){var t=a(e),n="[object Object]"==t?e.constructor:void 0,r=n?i(n):"";if(r)switch(r){case f:return d;case p:return s;case m:return u;case v:return l;case h:return c}return t}),Wb=g}function _9(){if(QR)return qb;QR=1;var e=kE(),t=vM(),n=c9(),r=g9(),o=kv(),a=Ei(),i=jE(),s=bM(),u="[object Arguments]",l="[object Array]",c="[object Object]",d=Object.prototype.hasOwnProperty;return qb=function(f,p,m,v,h,g){var y=a(f),b=a(p),w=y?l:o(f),x=b?l:o(p),_=(w=w==u?c:w)==c,E=(x=x==u?c:x)==c,S=w==x;if(S&&i(f)){if(!i(p))return!1;y=!0,_=!1}if(S&&!_)return g||(g=new e),y||s(f)?t(f,p,m,v,h,g):n(f,p,w,m,v,h,g);if(!(1&m)){var I=_&&d.call(f,"__wrapped__"),A=E&&d.call(p,"__wrapped__");if(I||A){var k=I?f.value():f,C=A?p.value():p;return g||(g=new e),h(k,C,m,v,g)}}return!!S&&(g||(g=new e),r(f,p,m,v,h,g))}}function IM(){if(XR)return Gb;XR=1;var e=_9(),t=ta();return Gb=function n(r,o,a,i,s){return r===o||(null==r||null==o||!t(r)&&!t(o)?r!=r&&o!=o:e(r,o,a,i,n,s))},Gb}function x9(){if(JR)return Hb;JR=1;var e=kE(),t=IM();return Hb=function(n,r,o,a){var i=o.length,s=i,u=!a;if(null==n)return!s;for(n=Object(n);i--;){var l=o[i];if(u&&l[2]?l[1]!==n[l[0]]:!(l[0]in n))return!1}for(;++i<s;){var c=(l=o[i])[0],d=n[c],f=l[1];if(u&&l[2]){if(void 0===d&&!(c in n))return!1}else{var p=new e;if(a)var m=a(d,f,c,n,r,p);if(!(void 0===m?t(f,d,3,a,p):m))return!1}}return!0}}function RM(){if(ZR)return Kb;ZR=1;var e=bs();return Kb=function(t){return t==t&&!e(t)}}function S9(){if(eP)return Yb;eP=1;var e=RM(),t=Ay();return Yb=function(n){for(var r=t(n),o=r.length;o--;){var a=r[o],i=n[a];r[o]=[a,i,e(i)]}return r}}function PM(){if(tP)return Qb;return tP=1,Qb=function(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}}function E9(){if(nP)return Xb;nP=1;var e=x9(),t=S9(),n=PM();return Xb=function(r){var o=t(r);return 1==o.length&&o[0][2]?n(o[0][0],o[0][1]):function(t){return t===r||e(t,r,o)}}}function $9(){if(rP)return Jb;return rP=1,Jb=function(e,t){return null!=e&&t in Object(e)}}function C9(){if(oP)return Zb;oP=1;var e=fM(),t=BE(),n=Ei(),r=zE(),o=VE(),a=Nv();return Zb=function(i,s,u){for(var l=-1,c=(s=e(s,i)).length,d=!1;++l<c;){var f=a(s[l]);if(!(d=null!=i&&u(i,f)))break;i=i[f]}return d||++l!=c?d:!!(c=null==i?0:i.length)&&o(c)&&r(f,c)&&(n(i)||t(i))}}function I9(){if(iP)return e_;iP=1;var e=$9(),t=C9();return e_=function(n,r){return null!=n&&t(n,r,e)}}function R9(){if(aP)return t_;aP=1;var e=IM(),t=mM(),n=I9(),r=AE(),o=RM(),a=PM(),i=Nv();return t_=function(s,u){return r(s)&&o(u)?a(i(s),u):function(r){var o=t(r,s);return void 0===o&&o===u?n(r,s):e(u,o,3)}}}function GE(){if(sP)return n_;return sP=1,n_=function(e){return e}}function P9(){if(uP)return r_;return uP=1,r_=function(e){return function(t){return null==t?void 0:t[e]}}}function T9(){if(lP)return o_;lP=1;var e=pM();return o_=function(t){return function(n){return e(n,t)}}}function O9(){if(cP)return i_;cP=1;var e=P9(),t=T9(),n=AE(),r=Nv();return i_=function(o){return n(o)?e(r(o)):t(o)}}function A9(){if(dP)return a_;dP=1;var e=E9(),t=R9(),n=GE(),r=Ei(),o=O9();return a_=function(a){return"function"==typeof a?a:null==a?n:"object"==typeof a?r(a)?t(a[0],a[1]):e(a):o(a)}}function M9(){if(fP)return s_;return fP=1,s_=function(e,t,n,r){for(var o=e.length,a=n+(r?1:-1);r?a--:++a<o;)if(t(e[a],a,e))return a;return-1}}function D9(){if(pP)return u_;return pP=1,u_=function(e){return e!=e}}function N9(){if(mP)return l_;return mP=1,l_=function(e,t,n){for(var r=n-1,o=e.length;++r<o;)if(e[r]===t)return r;return-1}}function k9(){if(hP)return c_;hP=1;var e=M9(),t=D9(),n=N9();return c_=function(r,o,a){return o==o?n(r,o,a):e(r,t,a)}}function L9(){if(vP)return d_;vP=1;var e=k9();return d_=function(t,n){return!!(null==t?0:t.length)&&e(t,n,0)>-1}}function F9(){if(gP)return f_;return gP=1,f_=function(){}}function B9(){if(yP)return p_;yP=1;var e=zm(),t=BE(),n=Ei(),r=e?e.isConcatSpreadable:void 0;return p_=function(e){return n(e)||t(e)||!!(r&&e&&e[r])}}function j9(){if(wP)return m_;wP=1;var e=LE(),t=B9();return m_=function n(r,o,a,i,s){var u=-1,l=r.length;for(a||(a=t),s||(s=[]);++u<l;){var c=r[u];o>0&&a(c)?o>1?n(c,o-1,a,i,s):e(s,c):i||(s[s.length]=c)}return s},m_}function HE(){if(bP)return h_;return bP=1,h_=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}}function z9(){if(_P)return v_;_P=1;var e=HE(),t=Math.max;return v_=function(n,r,o){return r=t(void 0===r?n.length-1:r,0),function(){for(var a=arguments,i=-1,s=t(a.length-r,0),u=Array(s);++i<s;)u[i]=a[r+i];i=-1;for(var l=Array(r+1);++i<r;)l[i]=a[i];return l[r]=o(u),e(n,this,l)}},v_}function V9(){if(xP)return g_;return xP=1,g_=function(e){return function(){return e}}}function TM(){if(SP)return y_;SP=1;var e=Zf(),t=function(){try{var t=e(Object,"defineProperty");return t({},"",{}),t}catch{}}();return y_=t}function U9(){if(EP)return w_;EP=1;var e=V9(),t=TM(),n=GE();return w_=t?function(n,r){return t(n,"toString",{configurable:!0,enumerable:!1,value:e(r),writable:!0})}:n}function OM(){if($P)return b_;$P=1;var e=Date.now;return b_=function(t){var n=0,r=0;return function(){var o=e(),a=16-(o-r);if(r=o,a>0){if(++n>=800)return arguments[0]}else n=0;return t.apply(void 0,arguments)}},b_}function AM(){if(CP)return __;CP=1;var e=U9(),t=OM()(e);return __=t}function W9(){if(IP)return x_;IP=1;var e=ri();return x_=function(){return e.Date.now()}}function q9(){if(RP)return S_;RP=1;var e=/\s/;return S_=function(t){for(var n=t.length;n--&&e.test(t.charAt(n)););return n}}function G9(){if(PP)return E_;PP=1;var e=q9(),t=/^\s+/;return E_=function(n){return n&&n.slice(0,e(n)+1).replace(t,"")}}function MM(){if(TP)return $_;TP=1;var e=G9(),t=bs(),n=Dv(),r=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,a=/^0o[0-7]+$/i,i=parseInt;return $_=function(s){if("number"==typeof s)return s;if(n(s))return NaN;if(t(s)){var u="function"==typeof s.valueOf?s.valueOf():s;s=t(u)?u+"":u}if("string"!=typeof s)return 0===s?s:+s;s=e(s);var l=o.test(s);return l||a.test(s)?i(s.slice(2),l?2:8):r.test(s)?NaN:+s}}function DM(){if(OP)return C_;OP=1;var e=bs(),t=W9(),n=MM(),r=Math.max,o=Math.min;return C_=function(a,i,s){var u,l,c,d,f,p,m=0,v=!1,h=!1,g=!0;if("function"!=typeof a)throw new TypeError("Expected a function");function y(e){var t=u,n=l;return u=l=void 0,m=e,d=a.apply(n,t)}function b(e){var t=e-p;return void 0===p||t>=i||t<0||h&&e-m>=c}function w(){var e=t();if(b(e))return x(e);f=setTimeout(w,function(e){var t=i-(e-p);return h?o(t,c-(e-m)):t}(e))}function x(e){return f=void 0,g&&u?y(e):(u=l=void 0,d)}function _(){var e=t(),n=b(e);if(u=arguments,l=this,p=e,n){if(void 0===f)return function(e){return m=e,f=setTimeout(w,i),v?y(e):d}(p);if(h)return clearTimeout(f),f=setTimeout(w,i),y(p)}return void 0===f&&(f=setTimeout(w,i)),d}return i=n(i)||0,e(s)&&(v=!!s.leading,c=(h="maxWait"in s)?r(n(s.maxWait)||0,i):c,g="trailing"in s?!!s.trailing:g),_.cancel=function(){void 0!==f&&clearTimeout(f),m=0,u=p=l=f=void 0},_.flush=function(){return void 0===f?d:x(t())},_},C_}function H9(){if(AP)return I_;AP=1;var e=DM(),t=bs();return I_=function(n,r,o){var a=!0,i=!0;if("function"!=typeof n)throw new TypeError("Expected a function");return t(o)&&(a="leading"in o?!!o.leading:a,i="trailing"in o?!!o.trailing:i),e(n,r,{leading:a,maxWait:r,trailing:i})}}Jh.exports;var K9=H9();const Y9=my(K9);function vv(e){return(vv="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function MP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function $g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?MP(Object(n),!0).forEach((function(t){Q9(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):MP(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Q9(e,t,n){return(t=X9(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function X9(e){var t=J9(e,"string");return"symbol"==vv(t)?t:t+""}function J9(e,t){if("object"!=vv(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=vv(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function Z9(e,t){return rF(e)||nF(e,t)||tF(e,t)||eF()}function eF(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function tF(e,t){if(e){if("string"==typeof e)return DP(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return DP(e,t)}}function DP(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function nF(e,t){var n=null==e?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],u=!0,l=!1;try{if(a=(n=n.call(e)).next,0!==t)for(;!(u=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);u=!0);}catch(e){l=!0,o=e}finally{try{if(!u&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(l)throw o}}return s}}function rF(e){if(Array.isArray(e))return e}var R_,NP,P_,kP,T_,LP,O_,FP,A_,BP,M_,jP,D_,zP,N_,VP,k_,UP,L_,WP,F_,qP,B_,GP,j_,HP,oF=v.forwardRef((function(e,t){var n=e.aspect,r=e.initialDimension,o=void 0===r?{width:-1,height:-1}:r,a=e.width,i=void 0===a?"100%":a,s=e.height,u=void 0===s?"100%":s,l=e.minWidth,c=void 0===l?0:l,d=e.minHeight,f=e.maxHeight,p=e.children,m=e.debounce,h=void 0===m?0:m,g=e.id,y=e.className,b=e.onResize,w=e.style,x=void 0===w?{}:w,_=v.useRef(null),E=v.useRef();E.current=b,v.useImperativeHandle(t,(function(){return Object.defineProperty(_.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),_.current},configurable:!0})}));var S=Z9(v.useState({containerWidth:o.width,containerHeight:o.height}),2),I=S[0],A=S[1],k=v.useCallback((function(e,t){A((function(n){var r=Math.round(e),o=Math.round(t);return n.containerWidth===r&&n.containerHeight===o?n:{containerWidth:r,containerHeight:o}}))}),[]);v.useEffect((function(){var e=function(e){var t,n=e[0].contentRect,r=n.width,o=n.height;k(r,o),null===(t=E.current)||void 0===t||t.call(E,r,o)};h>0&&(e=Y9(e,h,{trailing:!0,leading:!1}));var t=new ResizeObserver(e),n=_.current.getBoundingClientRect(),r=n.width,o=n.height;return k(r,o),t.observe(_.current),function(){t.disconnect()}}),[k,h]);var C=v.useMemo((function(){var e=I.containerWidth,t=I.containerHeight;if(e<0||t<0)return null;eb(Eg(i)||Eg(u),"The width(%s) and height(%s) are both fixed numbers,\n maybe you don't need to use a ResponsiveContainer.",i,u),eb(!n||n>0,"The aspect(%s) must be greater than zero.",n);var r=Eg(i)?e:i,o=Eg(u)?t:u;n&&n>0&&(r?o=r/n:o&&(r=o*n),f&&o>f&&(o=f)),eb(r>0||o>0,"The width(%s) and height(%s) of chart should be greater than 0,\n please check the style of container, or the props width(%s) and height(%s),\n or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the\n height and width.",r,o,i,u,c,d,n);var a=!Array.isArray(p)&&X8(p.type).endsWith("Chart");return Ue.Children.map(p,(function(e){return Ue.isValidElement(e)?v.cloneElement(e,$g({width:r,height:o},a?{style:$g({height:"100%",width:"100%",maxHeight:o,maxWidth:r},e.props.style)}:{})):e}))}),[n,p,u,f,d,c,I,i]);return Ue.createElement("div",{id:g?"".concat(g):void 0,className:cA("recharts-responsive-container",y),style:$g($g({},x),{},{width:i,height:u,minWidth:c,minHeight:d,maxHeight:f}),ref:_},C)}));function KE(){if(NP)return R_;NP=1;var e=xM()(Object.getPrototypeOf,Object);return R_=e}function iF(){if(kP)return P_;kP=1;var e=Cl(),t=KE(),n=ta(),r=Function.prototype,o=Object.prototype,a=r.toString,i=o.hasOwnProperty,s=a.call(Object);return P_=function(r){if(!n(r)||"[object Object]"!=e(r))return!1;var o=t(r);if(null===o)return!0;var u=i.call(o,"constructor")&&o.constructor;return"function"==typeof u&&u instanceof u&&a.call(u)==s}}function aF(){if(LP)return T_;LP=1;var e=MM(),t=1/0;return T_=function(n){return n?(n=e(n))===t||n===-t?17976931348623157e292*(n<0?-1:1):n==n?n:0:0===n?n:0}}function NM(){if(FP)return O_;FP=1;var e=TM();return O_=function(t,n,r){"__proto__"==n&&e?e(t,n,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[n]=r}}function kM(){if(BP)return A_;BP=1;var e=aF();return A_=function(t){var n=e(t),r=n%1;return n==n?r?n-r:n:0}}function YE(){if(jP)return M_;return jP=1,M_=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}}function LM(){if(zP)return D_;zP=1;var e=NM(),t=ME(),n=Object.prototype.hasOwnProperty;return D_=function(r,o,a){var i=r[o];(!n.call(r,o)||!t(i,a)||void 0===a&&!(o in r))&&e(r,o,a)}}function My(){if(VP)return N_;VP=1;var e=LM(),t=NM();return N_=function(n,r,o,a){var i=!o;o||(o={});for(var s=-1,u=r.length;++s<u;){var l=r[s],c=a?a(o[l],n[l],l,o,n):void 0;void 0===c&&(c=n[l]),i?t(o,l,c):e(o,l,c)}return o}}function FM(){if(UP)return k_;UP=1;var e=My(),t=Ay();return k_=function(n,r){return n&&e(r,t(r),n)}}function sF(){if(WP)return L_;return WP=1,L_=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}}function uF(){if(qP)return F_;qP=1;var e=bs(),t=qE(),n=sF(),r=Object.prototype.hasOwnProperty;return F_=function(o){if(!e(o))return n(o);var a=t(o),i=[];for(var s in o)"constructor"==s&&(a||!r.call(o,s))||i.push(s);return i}}function QE(){if(GP)return B_;GP=1;var e=_M(),t=uF(),n=EM();return B_=function(r){return n(r)?e(r,!0):t(r)}}function lF(){if(HP)return j_;HP=1;var e=My(),t=QE();return j_=function(n,r){return n&&e(r,t(r),n)}}var KP,z_,YP,V_,QP,U_,XP,W_,JP,q_,ZP,G_,eT,H_,tT,K_,nT,Y_,rT,Q_,oT,X_,iT,J_,aT,Z_,sT,ex,uT,tx,lT,nx,cT,rx,dT,ox,fT,ix,pT,ax,mT,sx,hT,Zh={exports:{}};function cF(){return KP||(KP=1,e=Zh,t=Zh.exports,n=ri(),r=t&&!t.nodeType&&t,o=r&&e&&!e.nodeType&&e,a=o&&o.exports===r?n.Buffer:void 0,i=a?a.allocUnsafe:void 0,e.exports=function(e,t){if(t)return e.slice();var n=e.length,r=i?i(n):new e.constructor(n);return e.copy(r),r}),Zh.exports;var e,t,n,r,o,a,i}function Dy(){if(YP)return z_;return YP=1,z_=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}}function dF(){if(QP)return V_;QP=1;var e=My(),t=FE();return V_=function(n,r){return e(n,t(n),r)}}function BM(){if(XP)return U_;XP=1;var e=LE(),t=KE(),n=FE(),r=wM(),o=Object.getOwnPropertySymbols;return U_=o?function(r){for(var o=[];r;)e(o,n(r)),r=t(r);return o}:r}function fF(){if(JP)return W_;JP=1;var e=My(),t=BM();return W_=function(n,r){return e(n,t(n),r)}}function pF(){if(ZP)return q_;ZP=1;var e=yM(),t=BM(),n=QE();return q_=function(r){return e(r,n,t)}}function mF(){if(eT)return G_;eT=1;var e=Object.prototype.hasOwnProperty;return G_=function(t){var n=t.length,r=new t.constructor(n);return n&&"string"==typeof t[0]&&e.call(t,"index")&&(r.index=t.index,r.input=t.input),r}}function XE(){if(tT)return H_;tT=1;var e=gM();return H_=function(t){var n=new t.constructor(t.byteLength);return new e(n).set(new e(t)),n}}function hF(){if(nT)return K_;nT=1;var e=XE();return K_=function(t,n){var r=n?e(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}}function vF(){if(rT)return Y_;rT=1;var e=/\w*$/;return Y_=function(t){var n=new t.constructor(t.source,e.exec(t));return n.lastIndex=t.lastIndex,n}}function gF(){if(oT)return Q_;oT=1;var e=zm(),t=e?e.prototype:void 0,n=t?t.valueOf:void 0;return Q_=function(e){return n?Object(n.call(e)):{}}}function yF(){if(iT)return X_;iT=1;var e=XE();return X_=function(t,n){var r=n?e(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}}function wF(){if(aT)return J_;aT=1;var e=XE(),t=hF(),n=vF(),r=gF(),o=yF();return J_=function(a,i,s){var u=a.constructor;switch(i){case"[object ArrayBuffer]":return e(a);case"[object Boolean]":case"[object Date]":return new u(+a);case"[object DataView]":return t(a,s);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return o(a,s);case"[object Map]":case"[object Set]":return new u;case"[object Number]":case"[object String]":return new u(a);case"[object RegExp]":return n(a);case"[object Symbol]":return r(a)}}}function Ny(){if(sT)return Z_;sT=1;var e=bs(),t=Object.create;return Z_=function(){function n(){}return function(r){if(!e(r))return{};if(t)return t(r);n.prototype=r;var o=new n;return n.prototype=void 0,o}}()}function bF(){if(uT)return ex;uT=1;var e=Ny(),t=KE(),n=qE();return ex=function(r){return"function"!=typeof r.constructor||n(r)?{}:e(t(r))}}function _F(){if(lT)return tx;lT=1;var e=kv(),t=ta();return tx=function(n){return t(n)&&"[object Map]"==e(n)}}function xF(){if(cT)return nx;cT=1;var e=_F(),t=UE(),n=WE(),r=n&&n.isMap,o=r?t(r):e;return nx=o}function SF(){if(dT)return rx;dT=1;var e=kv(),t=ta();return rx=function(n){return t(n)&&"[object Set]"==e(n)}}function EF(){if(fT)return ox;fT=1;var e=SF(),t=UE(),n=WE(),r=n&&n.isSet,o=r?t(r):e;return ox=o}function jM(){if(pT)return ix;pT=1;var e=kE(),t=YE(),n=LM(),r=FM(),o=lF(),a=cF(),i=Dy(),s=dF(),u=fF(),l=$M(),c=pF(),d=kv(),f=mF(),p=wF(),m=bF(),v=Ei(),h=jE(),g=xF(),y=bs(),b=EF(),w=Ay(),x=QE(),_="[object Arguments]",E="[object Function]",S="[object Object]",I={};return I[_]=I["[object Array]"]=I["[object ArrayBuffer]"]=I["[object DataView]"]=I["[object Boolean]"]=I["[object Date]"]=I["[object Float32Array]"]=I["[object Float64Array]"]=I["[object Int8Array]"]=I["[object Int16Array]"]=I["[object Int32Array]"]=I["[object Map]"]=I["[object Number]"]=I[S]=I["[object RegExp]"]=I["[object Set]"]=I["[object String]"]=I["[object Symbol]"]=I["[object Uint8Array]"]=I["[object Uint8ClampedArray]"]=I["[object Uint16Array]"]=I["[object Uint32Array]"]=!0,I["[object Error]"]=I[E]=I["[object WeakMap]"]=!1,ix=function A(k,C,T,R,P,O){var N,M=1&C,j=2&C,D=4&C;if(T&&(N=P?T(k,R,P,O):T(k)),void 0!==N)return N;if(!y(k))return k;var q=v(k);if(q){if(N=f(k),!M)return i(k,N)}else{var z=d(k),L=z==E||"[object GeneratorFunction]"==z;if(h(k))return a(k,M);if(z==S||z==_||L&&!P){if(N=j||L?{}:m(k),!M)return j?u(k,o(N,k)):s(k,r(N,k))}else{if(!I[z])return P?k:{};N=p(k,z,M)}}O||(O=new e);var $=O.get(k);if($)return $;O.set(k,N),b(k)?k.forEach((function(e){N.add(A(e,C,T,e,k,O))})):g(k)&&k.forEach((function(e,t){N.set(t,A(e,C,T,t,k,O))}));var V=q?void 0:(D?j?c:l:j?x:w)(k);return t(V||k,(function(e,t){V&&(e=k[t=e]),n(N,t,A(e,C,T,t,k,O))})),N},ix}function $F(){if(mT)return ax;mT=1;var e=j9();return ax=function(t){return(null==t?0:t.length)?e(t,1):[]}}function CF(){if(hT)return sx;hT=1;var e=$F(),t=z9(),n=AM();return sx=function(r){return n(t(r,void 0,e),r+"")}}Zh.exports;const IF={light:"",dark:".dark"},zM=v.createContext(null);function VM(){const e=v.useContext(zM);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}const RF=v.forwardRef((({id:e,className:t,children:n,config:r,...o},a)=>{const i=v.useId(),s=`chart-${e||i.replace(/:/g,"")}`;return G.jsx(zM.Provider,{value:{config:r},children:G.jsxs("div",{"data-chart":s,ref:a,className:we("flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-none [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-sector]:outline-none [&_.recharts-surface]:outline-none",t),...o,children:[G.jsx(PF,{id:s,config:r}),G.jsx(oF,{children:n})]})})}));RF.displayName="Chart";const PF=({id:e,config:t})=>{const n=Object.entries(t).filter((([,e])=>e.theme||e.color));return n.length?G.jsx("style",{dangerouslySetInnerHTML:{__html:Object.entries(IF).map((([t,r])=>`\n${r} [data-chart=${e}] {\n${n.map((([e,n])=>{var r;const o=(null==(r=n.theme)?void 0:r[t])||n.color;return o?` --color-${e}: ${o};`:null})).join("\n")}\n}\n`)).join("\n")}}):null},TF=v.forwardRef((({active:e,payload:t,className:n,indicator:r="dot",hideLabel:o=!1,hideIndicator:a=!1,label:i,labelFormatter:s,labelClassName:u,formatter:l,color:c,nameKey:d,labelKey:f,hoveredItem:p,onItemHover:m},h)=>{const{config:g}=VM(),y=v.useMemo((()=>{var e;if(o||null==t||!t.length)return null;const[n]=t,r=`${f||(null==n?void 0:n.dataKey)||(null==n?void 0:n.name)||"value"}`,a=NS(g,n,r),l=f||"string"!=typeof i?null==a?void 0:a.label:(null==(e=g[i])?void 0:e.label)||i;return s?G.jsx("div",{className:we("font-medium",u),children:s(l,t)}):l?G.jsx("div",{className:we("font-medium",u),children:l}):null}),[i,s,t,o,u,g,f]);if(!e||null==t||!t.length)return null;const b=1===t.length&&"dot"!==r,w=t.length>10;return G.jsxs("div",{ref:h,className:we("grid min-w-[8rem] items-start gap-xxs rounded-sm border border-border/50 bg-background px-xs py-xxs text-xs shadow-xl",w&&"min-w-[16rem]",n),children:[b?null:y,G.jsx("div",{className:we("grid gap-xxs",w&&"grid-cols-2 gap-x-s"),children:t.map(((e,t)=>{var n;const o=`${d||e.name||e.dataKey||"value"}`,i=NS(g,e,o),s=c||(null==(n=e.payload)?void 0:n.fill)||e.color||"",u=o===p;return G.jsx("div",{className:we("flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5 [&>svg]:text-muted-foreground","dot"===r&&"items-center",u?"":p?"opacity-40":""),onMouseEnter:()=>null==m?void 0:m(o),onMouseLeave:()=>null==m?void 0:m(null),children:l&&void 0!==(null==e?void 0:e.value)&&void 0!==(null==e?void 0:e.payload)&&e.name?l(e.value,e.name,e,t,[e.payload]):G.jsxs(G.Fragment,{children:[null!=i&&i.icon?G.jsx(i.icon,{}):!a&&G.jsx("div",{className:we("shrink-0 rounded-full border-[--color-border] bg-[--color-bg]",{"h-2.5 w-2.5":"dot"===r,"w-1":"line"===r,"w-0 border border-dashed bg-transparent":"dashed"===r,"my-0.5":b&&"dashed"===r}),style:{"--color-bg":s,"--color-border":s}}),G.jsxs("div",{className:we("flex flex-1 justify-between leading-none",b?"items-end":"items-center"),children:[G.jsxs("div",{className:"grid gap-xxs",children:[b?y:null,G.jsx("span",{className:we("text-muted-foreground",u&&"font-medium text-foreground"),children:(null==i?void 0:i.label)||e.name})]}),e.value&&G.jsx("span",{className:we("font-mono font-medium tabular-nums text-foreground",u&&"font-bold"),children:e.value.toLocaleString()})]})]})},e.dataKey)}))})]})}));TF.displayName="ChartTooltip";const OF=v.forwardRef((({className:e,hideIcon:t=!1,payload:n,nameKey:r,onItemHover:o,hoveredItem:a},i)=>{const{config:s}=VM(),u=v.useRef({});return v.useEffect((()=>{if(a&&u.current[a]){const e=u.current[a];e&&e.scrollIntoView({behavior:"smooth",block:"nearest"})}}),[a]),null!=n&&n.length?G.jsx("div",{ref:i,className:we("flex h-[150px] w-full flex-wrap items-center justify-center gap-l overflow-y-auto pb-xl",e),children:n.map((e=>{var n;const i=`${r||e.dataKey||"value"}`,l=NS(s,e,i),c=!!o&&i===a;return G.jsxs("div",{ref:e=>{e?u.current[i]=e:delete u.current[i]},className:we("group flex cursor-pointer select-none items-center gap-xs text-base transition-all duration-150",c?"scale-105 text-black":a?"text-gray-700 opacity-40":"text-gray-700"),onMouseEnter:()=>null==o?void 0:o(e.dataKey),onMouseLeave:()=>null==o?void 0:o(null),children:[null!=l&&l.icon&&!t?G.jsx(l.icon,{}):G.jsx("div",{className:"h-2 w-2 shrink-0 rounded-full",style:{backgroundColor:e.color||""}}),G.jsx("span",{className:"min-w-[max-content]",children:(null==l?void 0:l.label)||e.name})]},(null==(n=e.value)?void 0:n.toString())||i)}))}):null}));function NS(e,t,n){if("object"!=typeof t||null===t)return;const r="payload"in t&&"object"==typeof t.payload&&null!==t.payload?t.payload:void 0;let o=n;return n in t&&"string"==typeof t[n]?o=t[n]:r&&n in r&&"string"==typeof r[n]&&(o=r[n]),o in e?e[o]:e[n]}OF.displayName="ChartLegend";const AF=({children:e,className:t})=>G.jsx("div",{className:we("flex flex-wrap gap-xxxs",t),children:e}),UM=({text:e,icon:t,disabled:n,isLoading:r,avatarSrc:o,onClick:a,onRemove:i,className:s})=>G.jsxs("div",{onClick:n?void 0:a,className:we("flex cursor-pointer items-center gap-xxxs rounded-sm bg-gray-100 p-xxs text-sm font-medium text-gray-900 transition-all hover:bg-gray-200 [&_svg]:size-4",n&&"cursor-not-allowed bg-gray-100 text-gray-300",s),children:[o&&G.jsxs(JA,{className:we("size-6 text-[10px]"),children:[G.jsx(ZA,{src:o,alt:e}),G.jsx(eM,{className:"text-xs",children:e.charAt(0).toUpperCase()})]}),t,G.jsx("span",{children:e}),i&&!r&&G.jsx("span",{role:"button",tabIndex:-1,onClick:e=>{e.stopPropagation(),e.preventDefault(),!n&&(null==i||i())},onPointerDown:e=>{e.stopPropagation(),e.preventDefault()},className:we("pointer-events-auto cursor-pointer",n&&"pointer-events-none cursor-not-allowed opacity-50"),children:G.jsx(gy,{size:16})}),r&&G.jsx(sA,{size:16,className:"animate-spin"})]});function ky(e){const t=v.useRef({value:e,previous:e});return v.useMemo((()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous)),[e])}function Ly(e){const[t,n]=v.useState(void 0);return Vo((()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const t=new ResizeObserver((t=>{if(!Array.isArray(t)||!t.length)return;const r=t[0];let o,a;if("borderBoxSize"in r){const e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;o=t.inlineSize,a=t.blockSize}else o=e.offsetWidth,a=e.offsetHeight;n({width:o,height:a})}));return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)}),[e]),t}const WM="Checkbox",[MF,UJ]=ni(WM),[DF,NF]=MF(WM),kF=v.forwardRef(((e,t)=>{const{__scopeCheckbox:n,name:r,checked:o,defaultChecked:a,required:i,disabled:s,value:u="on",onCheckedChange:l,...c}=e,[d,f]=v.useState(null),p=Vt(t,(e=>f(e))),m=v.useRef(!1),h=!d||!!d.closest("form"),[g=!1,y]=fd({prop:o,defaultProp:a,onChange:l}),b=v.useRef(g);return v.useEffect((()=>{const e=null==d?void 0:d.form;if(e){const t=()=>y(b.current);return e.addEventListener("reset",t),()=>e.removeEventListener("reset",t)}}),[d,y]),v.createElement(DF,{scope:n,state:g,disabled:s},v.createElement(ft.button,Te({type:"button",role:"checkbox","aria-checked":Bf(g)?"mixed":g,"aria-required":i,"data-state":qM(g),"data-disabled":s?"":void 0,disabled:s,value:u},c,{ref:p,onKeyDown:et(e.onKeyDown,(e=>{"Enter"===e.key&&e.preventDefault()})),onClick:et(e.onClick,(e=>{y((e=>!!Bf(e)||!e)),h&&(m.current=e.isPropagationStopped(),m.current||e.stopPropagation())}))})),h&&v.createElement(BF,{control:d,bubbles:!m.current,name:r,value:u,checked:g,required:i,disabled:s,style:{transform:"translateX(-100%)"}}))})),LF="CheckboxIndicator",FF=v.forwardRef(((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...o}=e,a=NF(LF,n);return v.createElement(ea,{present:r||Bf(a.state)||!0===a.state},v.createElement(ft.span,Te({"data-state":qM(a.state),"data-disabled":a.disabled?"":void 0},o,{ref:t,style:{pointerEvents:"none",...e.style}})))})),BF=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,a=v.useRef(null),i=ky(n),s=Ly(t);return v.useEffect((()=>{const e=a.current,t=window.HTMLInputElement.prototype,o=Object.getOwnPropertyDescriptor(t,"checked").set;if(i!==n&&o){const t=new Event("click",{bubbles:r});e.indeterminate=Bf(n),o.call(e,!Bf(n)&&n),e.dispatchEvent(t)}}),[i,n,r]),v.createElement("input",Te({type:"checkbox","aria-hidden":!0,defaultChecked:!Bf(n)&&n},o,{tabIndex:-1,ref:a,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function Bf(e){return"indeterminate"===e}function qM(e){return Bf(e)?"indeterminate":e?"checked":"unchecked"}const GM=kF,jF=FF,zF=gu("relative overflow-hidden ",{variants:{size:{default:"size-xs"},variant:{default:"peer shrink-0 rounded-sm border disabled:cursor-not-allowed disabled:!border-0 disabled:!bg-gray-100"}},defaultVariants:{size:"default",variant:"default"}}),JE=v.forwardRef((({className:e,size:t,variant:n,iconType:r,...o},a)=>{const i=o.checked,[s]=v.useState(i),[u,l]=v.useState(!1);v.useEffect((()=>{s!==i&&l(!0)}),[i]);const c=e=>"minus"===r?G.jsx(q5,{...e}):G.jsx(vE,{...e});return G.jsxs(GM,{ref:a,className:we(zF({size:t,variant:n}),"transition-[border] duration-100 ease-linear",i?"border-0":"border-gray-300 hover:border-2",e),...o,children:[G.jsx("div",{className:we("transform-origin-center absolute left-0 top-0 size-full rounded-full bg-blue_100",i?"scale-[1.2]":"scale-0",{"animate-fill-in":i&&u,"animate-fill-out":!i&&u})}),G.jsx(jF,{className:"relative flex items-center justify-center text-current",children:G.jsx(c,{className:"size-xxxs",color:o.disabled?"var(--gray-300)":"white"})})]})}));JE.displayName=GM.displayName;var vT=1,VF=.9,UF=.8,WF=.17,ux=.1,lx=.999,qF=.9999,GF=.99,HF=/[\\\/_+.#"@\[\(\{&]/,KF=/[\\\/_+.#"@\[\(\{&]/g,YF=/[\s-]/,HM=/[\s-]/g;function kS(e,t,n,r,o,a,i){if(a===t.length)return o===e.length?vT:GF;var s=`${o},${a}`;if(void 0!==i[s])return i[s];for(var u,l,c,d,f=r.charAt(a),p=n.indexOf(f,o),m=0;p>=0;)(u=kS(e,t,n,r,p+1,a+1,i))>m&&(p===o?u*=vT:HF.test(e.charAt(p-1))?(u*=UF,(c=e.slice(o,p-1).match(KF))&&o>0&&(u*=Math.pow(lx,c.length))):YF.test(e.charAt(p-1))?(u*=VF,(d=e.slice(o,p-1).match(HM))&&o>0&&(u*=Math.pow(lx,d.length))):(u*=WF,o>0&&(u*=Math.pow(lx,p-o))),e.charAt(p)!==t.charAt(a)&&(u*=qF)),(u<ux&&n.charAt(p-1)===r.charAt(a+1)||r.charAt(a+1)===r.charAt(a)&&n.charAt(p-1)!==r.charAt(a))&&((l=kS(e,t,n,r,p+1,a+2,i))*ux>u&&(u=l*ux)),u>m&&(m=u),p=n.indexOf(f,p+1);return i[s]=m,m}function gT(e){return e.toLowerCase().replace(HM," ")}function QF(e,t,n){return kS(e=n&&n.length>0?""+(e+" "+n.join(" ")):e,t,gT(e),gT(t),0,0,{})}var Wh='[cmdk-group=""]',cx='[cmdk-group-items=""]',XF='[cmdk-group-heading=""]',ZE='[cmdk-item=""]',yT=`${ZE}:not([aria-disabled="true"])`,LS="cmdk-item-select",Nf="data-value",JF=(e,t,n)=>QF(e,t,n),KM=v.createContext(void 0),Lv=()=>v.useContext(KM),YM=v.createContext(void 0),e$=()=>v.useContext(YM),QM=v.createContext(void 0),XM=v.forwardRef(((e,t)=>{let n=$m((()=>{var t,n;return{search:"",value:null!=(n=null!=(t=e.value)?t:e.defaultValue)?n:"",filtered:{count:0,items:new Map,groups:new Set}}})),r=$m((()=>new Set)),o=$m((()=>new Map)),a=$m((()=>new Map)),i=$m((()=>new Set)),s=JM(e),{label:u,children:l,value:c,onValueChange:d,filter:f,shouldFilter:p,loop:m,disablePointerSelection:h=!1,vimBindings:g=!0,...y}=e,b=v.useId(),w=v.useId(),x=v.useId(),_=v.useRef(null),E=lB();Hf((()=>{if(void 0!==c){let e=c.trim();n.current.value=e,S.emit()}}),[c]),Hf((()=>{E(6,R)}),[]);let S=v.useMemo((()=>({subscribe:e=>(i.current.add(e),()=>i.current.delete(e)),snapshot:()=>n.current,setState:(e,t,r)=>{var o,a,i;if(!Object.is(n.current[e],t)){if(n.current[e]=t,"search"===e)T(),k(),E(1,C);else if("value"===e&&(r||E(5,R),void 0!==(null==(o=s.current)?void 0:o.value))){let e=t??"";return void(null==(i=(a=s.current).onValueChange)||i.call(a,e))}S.emit()}},emit:()=>{i.current.forEach((e=>e()))}})),[]),I=v.useMemo((()=>({value:(e,t,r)=>{var o;t!==(null==(o=a.current.get(e))?void 0:o.value)&&(a.current.set(e,{value:t,keywords:r}),n.current.filtered.items.set(e,A(t,r)),E(2,(()=>{k(),S.emit()})))},item:(e,t)=>(r.current.add(e),t&&(o.current.has(t)?o.current.get(t).add(e):o.current.set(t,new Set([e]))),E(3,(()=>{T(),k(),n.current.value||C(),S.emit()})),()=>{a.current.delete(e),r.current.delete(e),n.current.filtered.items.delete(e);let t=P();E(4,(()=>{T(),(null==t?void 0:t.getAttribute("id"))===e&&C(),S.emit()}))}),group:e=>(o.current.has(e)||o.current.set(e,new Set),()=>{a.current.delete(e),o.current.delete(e)}),filter:()=>s.current.shouldFilter,label:u||e["aria-label"],disablePointerSelection:h,listId:b,inputId:x,labelId:w,listInnerRef:_})),[]);function A(e,t){var r,o;let a=null!=(o=null==(r=s.current)?void 0:r.filter)?o:JF;return e?a(e,n.current.search,t):0}function k(){if(!n.current.search||!1===s.current.shouldFilter)return;let e=n.current.filtered.items,t=[];n.current.filtered.groups.forEach((n=>{let r=o.current.get(n),a=0;r.forEach((t=>{let n=e.get(t);a=Math.max(n,a)})),t.push([n,a])}));let r=_.current;O().sort(((t,n)=>{var r,o;let a=t.getAttribute("id"),i=n.getAttribute("id");return(null!=(r=e.get(i))?r:0)-(null!=(o=e.get(a))?o:0)})).forEach((e=>{let t=e.closest(cx);t?t.appendChild(e.parentElement===t?e:e.closest(`${cx} > *`)):r.appendChild(e.parentElement===r?e:e.closest(`${cx} > *`))})),t.sort(((e,t)=>t[1]-e[1])).forEach((e=>{let t=_.current.querySelector(`${Wh}[${Nf}="${encodeURIComponent(e[0])}"]`);null==t||t.parentElement.appendChild(t)}))}function C(){let e=O().find((e=>"true"!==e.getAttribute("aria-disabled"))),t=null==e?void 0:e.getAttribute(Nf);S.setState("value",t||void 0)}function T(){var e,t,i,u;if(!n.current.search||!1===s.current.shouldFilter)return void(n.current.filtered.count=r.current.size);n.current.filtered.groups=new Set;let l=0;for(let o of r.current){let r=A(null!=(t=null==(e=a.current.get(o))?void 0:e.value)?t:"",null!=(u=null==(i=a.current.get(o))?void 0:i.keywords)?u:[]);n.current.filtered.items.set(o,r),r>0&&l++}for(let[e,t]of o.current)for(let r of t)if(n.current.filtered.items.get(r)>0){n.current.filtered.groups.add(e);break}n.current.filtered.count=l}function R(){var e,t,n;let r=P();r&&((null==(e=r.parentElement)?void 0:e.firstChild)===r&&(null==(n=null==(t=r.closest(Wh))?void 0:t.querySelector(XF))||n.scrollIntoView({block:"nearest"})),r.scrollIntoView({block:"nearest"}))}function P(){var e;return null==(e=_.current)?void 0:e.querySelector(`${ZE}[aria-selected="true"]`)}function O(){var e;return Array.from(null==(e=_.current)?void 0:e.querySelectorAll(yT))}function N(e){let t=O()[e];t&&S.setState("value",t.getAttribute(Nf))}function M(e){var t;let n=P(),r=O(),o=r.findIndex((e=>e===n)),a=r[o+e];null!=(t=s.current)&&t.loop&&(a=o+e<0?r[r.length-1]:o+e===r.length?r[0]:r[o+e]),a&&S.setState("value",a.getAttribute(Nf))}function j(e){let t,n=P(),r=null==n?void 0:n.closest(Wh);for(;r&&!t;)r=e>0?sB(r,Wh):uB(r,Wh),t=null==r?void 0:r.querySelector(yT);t?S.setState("value",t.getAttribute(Nf)):M(e)}let D=()=>N(O().length-1),q=e=>{e.preventDefault(),e.metaKey?D():e.altKey?j(1):M(1)},z=e=>{e.preventDefault(),e.metaKey?N(0):e.altKey?j(-1):M(-1)};return v.createElement(ft.div,{ref:t,tabIndex:-1,...y,"cmdk-root":"",onKeyDown:e=>{var t;if(null==(t=y.onKeyDown)||t.call(y,e),!e.defaultPrevented)switch(e.key){case"n":case"j":g&&e.ctrlKey&&q(e);break;case"ArrowDown":q(e);break;case"p":case"k":g&&e.ctrlKey&&z(e);break;case"ArrowUp":z(e);break;case"Home":e.preventDefault(),N(0);break;case"End":e.preventDefault(),D();break;case"Enter":if(!e.nativeEvent.isComposing&&229!==e.keyCode){e.preventDefault();let t=P();if(t){let e=new Event(LS);t.dispatchEvent(e)}}}}},v.createElement("label",{"cmdk-label":"",htmlFor:I.inputId,id:I.labelId,style:dB},u),Fy(e,(e=>v.createElement(YM.Provider,{value:S},v.createElement(KM.Provider,{value:I},e)))))})),ZF=v.forwardRef(((e,t)=>{var n,r;let o=v.useId(),a=v.useRef(null),i=v.useContext(QM),s=Lv(),u=JM(e),l=null!=(r=null==(n=u.current)?void 0:n.forceMount)?r:null==i?void 0:i.forceMount;Hf((()=>{if(!l)return s.item(o,null==i?void 0:i.id)}),[l]);let c=ZM(o,a,[e.value,e.children,a],e.keywords),d=e$(),f=Kf((e=>e.value&&e.value===c.current)),p=Kf((e=>!(!l&&!1!==s.filter())||(!e.search||e.filtered.items.get(o)>0)));function m(){var e,t;h(),null==(t=(e=u.current).onSelect)||t.call(e,c.current)}function h(){d.setState("value",c.current,!0)}if(v.useEffect((()=>{let t=a.current;if(t&&!e.disabled)return t.addEventListener(LS,m),()=>t.removeEventListener(LS,m)}),[p,e.onSelect,e.disabled]),!p)return null;let{disabled:g,value:y,onSelect:b,forceMount:w,keywords:x,..._}=e;return v.createElement(ft.div,{ref:gv([a,t]),..._,id:o,"cmdk-item":"",role:"option","aria-disabled":!!g,"aria-selected":!!f,"data-disabled":!!g,"data-selected":!!f,onPointerMove:g||s.disablePointerSelection?void 0:h,onClick:g?void 0:m},e.children)})),eB=v.forwardRef(((e,t)=>{let{heading:n,children:r,forceMount:o,...a}=e,i=v.useId(),s=v.useRef(null),u=v.useRef(null),l=v.useId(),c=Lv(),d=Kf((e=>!(!o&&!1!==c.filter())||(!e.search||e.filtered.groups.has(i))));Hf((()=>c.group(i)),[]),ZM(i,s,[e.value,e.heading,u]);let f=v.useMemo((()=>({id:i,forceMount:o})),[o]);return v.createElement(ft.div,{ref:gv([s,t]),...a,"cmdk-group":"",role:"presentation",hidden:!d||void 0},n&&v.createElement("div",{ref:u,"cmdk-group-heading":"","aria-hidden":!0,id:l},n),Fy(e,(e=>v.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":n?l:void 0},v.createElement(QM.Provider,{value:f},e)))))})),tB=v.forwardRef(((e,t)=>{let{alwaysRender:n,...r}=e,o=v.useRef(null),a=Kf((e=>!e.search));return n||a?v.createElement(ft.div,{ref:gv([o,t]),...r,"cmdk-separator":"",role:"separator"}):null})),nB=v.forwardRef(((e,t)=>{let{onValueChange:n,...r}=e,o=null!=e.value,a=e$(),i=Kf((e=>e.search)),s=Kf((e=>e.value)),u=Lv(),l=v.useMemo((()=>{var e;let t=null==(e=u.listInnerRef.current)?void 0:e.querySelector(`${ZE}[${Nf}="${encodeURIComponent(s)}"]`);return null==t?void 0:t.getAttribute("id")}),[]);return v.useEffect((()=>{null!=e.value&&a.setState("search",e.value)}),[e.value]),v.createElement(ft.input,{ref:t,...r,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":u.listId,"aria-labelledby":u.labelId,"aria-activedescendant":l,id:u.inputId,type:"text",value:o?e.value:i,onChange:e=>{o||a.setState("search",e.target.value),null==n||n(e.target.value)}})})),rB=v.forwardRef(((e,t)=>{let{children:n,label:r="Suggestions",...o}=e,a=v.useRef(null),i=v.useRef(null),s=Lv();return v.useEffect((()=>{if(i.current&&a.current){let e,t=i.current,n=a.current,r=new ResizeObserver((()=>{e=requestAnimationFrame((()=>{let e=t.offsetHeight;n.style.setProperty("--cmdk-list-height",e.toFixed(1)+"px")}))}));return r.observe(t),()=>{cancelAnimationFrame(e),r.unobserve(t)}}}),[]),v.createElement(ft.div,{ref:gv([a,t]),...o,"cmdk-list":"",role:"listbox","aria-label":r,id:s.listId},Fy(e,(e=>v.createElement("div",{ref:gv([i,s.listInnerRef]),"cmdk-list-sizer":""},e))))})),oB=v.forwardRef(((e,t)=>{let{open:n,onOpenChange:r,overlayClassName:o,contentClassName:a,container:i,...s}=e;return v.createElement(FA,{open:n,onOpenChange:r},v.createElement(Ey,{container:i},v.createElement(Bm,{"cmdk-overlay":"",className:o}),v.createElement(jm,{"aria-label":e.label,"cmdk-dialog":"",className:a},v.createElement(XM,{ref:t,...s}))))})),iB=v.forwardRef(((e,t)=>Kf((e=>0===e.filtered.count))?v.createElement(ft.div,{ref:t,...e,"cmdk-empty":"",role:"presentation"}):null)),aB=v.forwardRef(((e,t)=>{let{progress:n,children:r,label:o="Loading...",...a}=e;return v.createElement(ft.div,{ref:t,...a,"cmdk-loading":"",role:"progressbar","aria-valuenow":n,"aria-valuemin":0,"aria-valuemax":100,"aria-label":o},Fy(e,(e=>v.createElement("div",{"aria-hidden":!0},e))))})),$i=Object.assign(XM,{List:rB,Item:ZF,Input:nB,Group:eB,Separator:tB,Dialog:oB,Empty:iB,Loading:aB});function sB(e,t){let n=e.nextElementSibling;for(;n;){if(n.matches(t))return n;n=n.nextElementSibling}}function uB(e,t){let n=e.previousElementSibling;for(;n;){if(n.matches(t))return n;n=n.previousElementSibling}}function JM(e){let t=v.useRef(e);return Hf((()=>{t.current=e})),t}var Hf=typeof window>"u"?v.useEffect:v.useLayoutEffect;function $m(e){let t=v.useRef();return void 0===t.current&&(t.current=e()),t}function gv(e){return t=>{e.forEach((e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)}))}}function Kf(e){let t=e$(),n=()=>e(t.snapshot());return v.useSyncExternalStore(t.subscribe,n,n)}function ZM(e,t,n,r=[]){let o=v.useRef(),a=Lv();return Hf((()=>{var i;let s=(()=>{var e;for(let t of n){if("string"==typeof t)return t.trim();if("object"==typeof t&&"current"in t)return t.current?null==(e=t.current.textContent)?void 0:e.trim():o.current}})(),u=r.map((e=>e.trim()));a.value(e,s,u),null==(i=t.current)||i.setAttribute(Nf,s),o.current=s})),o}var lB=()=>{let[e,t]=v.useState(),n=$m((()=>new Map));return Hf((()=>{n.current.forEach((e=>e())),n.current=new Map}),[e]),(e,r)=>{n.current.set(e,r),t({})}};function cB(e){let t=e.type;return"function"==typeof t?t(e.props):"render"in t?t.render(e.props):e}function Fy({asChild:e,children:t},n){return e&&v.isValidElement(t)?v.cloneElement(cB(t),{ref:t.ref},n(t.props.children)):n(t)}var dB={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};const fB=Ey,eD=v.forwardRef((({className:e,...t},n)=>(v.useEffect((()=>{const e=document.querySelectorAll(".blured-modal-overlay");return e.forEach((e=>e&&(e.style.filter="blur(5px)"))),()=>{0===Array.from(document.querySelectorAll('[role="dialog"]')).length&&e.forEach((e=>e&&(e.style.filter="none")))}}),[]),G.jsx(Bm,{ref:n,"data-testid":"dialog_overlay",className:we("fixed inset-0 z-dialog bg-black opacity-[0.8] data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}))));eD.displayName=Bm.displayName;const pB=gu("",{variants:{closeVariant:{none:"",insideCard:"absolute right-m top-m rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground text-gray-400",outsideCard:"fixed right-[30px] top-[30px] z-100 text-gray-400",mobileGallery:"fixed right-m top-[62px] text-white z-[110]"}},defaultVariants:{closeVariant:"outsideCard"}}),mB=gu("",{variants:{closeSize:{small:"size-6",big:"size-[42px]","18x18":"size-[18px]"}},defaultVariants:{closeSize:"small"}}),hB=v.forwardRef((({title:e,titleIcon:t,className:n,dialogName:r,showClose:o=!0,closeVariant:a="outsideCard",closeSize:i="big",children:s,titleClassName:u,overlayClassName:l,childrenClassName:c,footerClassName:d,onBack:f,onCloseModal:p,renderFooter:m,onScroll:v,...h},g)=>{const y=G.jsxs($y,{className:we(pB({closeVariant:a})),children:[G.jsx(gy,{onClick:p,fill:"currentColor",className:we(mB({closeSize:i}))}),G.jsx("span",{className:"sr-only",children:"Close"})]});return G.jsxs(fB,{children:[G.jsx(eD,{className:l,onClick:p}),o&&"insideCard"!==a&&y,G.jsxs(jm,{ref:g,className:we("fixed left-[50%] top-[50%] z-[101] grid max-w-[600px] translate-x-[-50%] translate-y-[-50%] !overflow-visible rounded-sm bg-background shadow-lg outline-none duration-200 data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] max-md:w-[calc(100vw-32px)] md:w-full [&>div]:min-w-0",n),...h,children:[e&&G.jsxs("h3",{className:we("flex items-center justify-center gap-xxs border-b border-gray-200 p-m text-center text-lg font-semibold text-gray-700",u),children:[t,e]}),G.jsx("div",{id:r||"dialog-content",className:we("p-m",c),onScroll:v,children:s}),o&&"insideCard"===a&&y,f&&G.jsx("button",{"data-testid":"dialog-back-button","aria-label":"Back",onClick:f,className:"absolute left-m top-m",children:G.jsx(iA,{color:"var(--gray-400)",size:24})}),G.jsx(tD,{className:we("empty:hidden",d),children:null==m?void 0:m()})]})]})}));hB.displayName=jm.displayName;const tD=({className:e,...t})=>G.jsx("div",{className:we("flex border-t border-gray-200 p-m",e),...t});tD.displayName="DialogFooter";const vB=v.forwardRef((({className:e,...t},n)=>G.jsx(Ov,{ref:n,className:we("text-lg font-semibold leading-none tracking-tight",e),...t})));vB.displayName=Ov.displayName;const gB=v.forwardRef((({className:e,...t},n)=>G.jsx(Av,{ref:n,className:we("text-sm text-muted-foreground",e),...t})));gB.displayName=Av.displayName;const yB=v.forwardRef((({className:e,...t},n)=>G.jsx($i,{ref:n,className:we("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t})));yB.displayName=$i.displayName;const wB=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{className:"flex items-center border-b px-3","cmdk-input-wrapper":"",children:G.jsx($i.Input,{ref:n,className:we("flex h-11 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",e),...t})})));wB.displayName=$i.Input.displayName;const bB=v.forwardRef((({className:e,...t},n)=>G.jsx($i.List,{ref:n,className:we("mt-2 max-h-[300px] overflow-y-auto overflow-x-hidden",e),...t})));bB.displayName=$i.List.displayName;const _B=v.forwardRef(((e,t)=>G.jsx($i.Empty,{ref:t,className:"py-6 text-center text-sm",...e})));_B.displayName=$i.Empty.displayName;const xB=v.forwardRef((({className:e,...t},n)=>G.jsx($i.Group,{ref:n,className:we("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t})));xB.displayName=$i.Group.displayName;const SB=v.forwardRef((({className:e,...t},n)=>G.jsx($i.Separator,{ref:n,className:we("-mx-1 h-px bg-border",e),...t})));SB.displayName=$i.Separator.displayName;const EB=v.forwardRef((({className:e,...t},n)=>G.jsx($i.Item,{ref:n,className:we("relative flex max-w-[215px] cursor-default select-none items-center rounded-xs px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50",e),...t})));function sd(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function wT(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function nD(...e){return t=>{let n=!1;const r=e.map((e=>{const r=wT(e,t);return!n&&"function"==typeof r&&(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():wT(e[t],null)}}}}function ep(...e){return v.useCallback(nD(...e),e)}function $B(e,t){const n=v.createContext(t),r=e=>{const{children:t,...r}=e,o=v.useMemo((()=>r),Object.values(r));return G.jsx(n.Provider,{value:o,children:t})};return r.displayName=e+"Provider",[r,function(r){const o=v.useContext(n);if(o)return o;if(void 0!==t)return t;throw new Error(`\`${r}\` must be used within \`${e}\``)}]}function CB(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>v.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return v.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const o=v.createContext(r),a=n.length;n=[...n,r];const i=t=>{var n;const{scope:r,children:i,...s}=t,u=(null==(n=null==r?void 0:r[e])?void 0:n[a])||o,l=v.useMemo((()=>s),Object.values(s));return G.jsx(u.Provider,{value:l,children:i})};return i.displayName=t+"Provider",[i,function(n,i){var s;const u=(null==(s=null==i?void 0:i[e])?void 0:s[a])||o,l=v.useContext(u);if(l)return l;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},IB(r,...t)]}function IB(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return v.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}EB.displayName=$i.Item.displayName;var Xg=null!=globalThis&&globalThis.document?v.useLayoutEffect:()=>{},RB=Yg[" useId ".trim().toString()]||(()=>{}),PB=0;function dx(e){const[t,n]=v.useState(RB());return Xg((()=>{e||n((e=>e??String(PB++)))}),[e]),e||(t?`radix-${t}`:"")}function Yf(e){const t=v.useRef(e);return v.useEffect((()=>{t.current=e})),v.useMemo((()=>(...e)=>{var n;return null==(n=t.current)?void 0:n.call(t,...e)}),[])}function TB({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=OB({defaultProp:t,onChange:n}),a=void 0!==e,i=a?e:r,s=Yf(n);return[i,v.useCallback((t=>{if(a){const n="function"==typeof t?t(e):t;n!==e&&s(n)}else o(t)}),[a,e,o,s])]}function OB({defaultProp:e,onChange:t}){const n=v.useState(e),[r]=n,o=v.useRef(r),a=Yf(t);return v.useEffect((()=>{o.current!==r&&(a(r),o.current=r)}),[r,o,a]),n}function rD(e){const t=AB(e),n=v.forwardRef(((e,n)=>{const{children:r,...o}=e,a=v.Children.toArray(r),i=a.find(DB);if(i){const e=i.props.children,r=a.map((t=>t===i?v.Children.count(e)>1?v.Children.only(null):v.isValidElement(e)?e.props.children:null:t));return G.jsx(t,{...o,ref:n,children:v.isValidElement(e)?v.cloneElement(e,void 0,r):null})}return G.jsx(t,{...o,ref:n,children:r})}));return n.displayName=`${e}.Slot`,n}function AB(e){const t=v.forwardRef(((e,t)=>{const{children:n,...r}=e;if(v.isValidElement(n)){const e=kB(n),o=NB(r,n.props);return n.type!==v.Fragment&&(o.ref=t?nD(t,e):e),v.cloneElement(n,o)}return v.Children.count(n)>1?v.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}var MB=Symbol("radix.slottable");function DB(e){return v.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===MB}function NB(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...e)=>{a(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...a}:"className"===r&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}function kB(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?e.ref:(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o?e.props.ref:e.props.ref||e.ref)}var LB=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],Il=LB.reduce(((e,t)=>{const n=rD(`Primitive.${t}`),r=v.forwardRef(((e,r)=>{const{asChild:o,...a}=e,i=o?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),G.jsx(i,{...a,ref:r})}));return r.displayName=`Primitive.${t}`,{...e,[t]:r}}),{});function FB(e,t){e&&vu.flushSync((()=>e.dispatchEvent(t)))}function BB(e,t=(null==globalThis?void 0:globalThis.document)){const n=Yf(e);v.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})}),[n,t])}var bT,jB="DismissableLayer",FS="dismissableLayer.update",zB="dismissableLayer.pointerDownOutside",VB="dismissableLayer.focusOutside",oD=v.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),iD=v.forwardRef(((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:i,onDismiss:s,...u}=e,l=v.useContext(oD),[c,d]=v.useState(null),f=(null==c?void 0:c.ownerDocument)??(null==globalThis?void 0:globalThis.document),[,p]=v.useState({}),m=ep(t,(e=>d(e))),h=Array.from(l.layers),[g]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),y=h.indexOf(g),b=c?h.indexOf(c):-1,w=l.layersWithOutsidePointerEventsDisabled.size>0,x=b>=y,_=qB((e=>{const t=e.target,n=[...l.branches].some((e=>e.contains(t)));!x||n||(null==o||o(e),null==i||i(e),e.defaultPrevented||null==s||s())}),f),E=GB((e=>{const t=e.target;[...l.branches].some((e=>e.contains(t)))||(null==a||a(e),null==i||i(e),e.defaultPrevented||null==s||s())}),f);return BB((e=>{b===l.layers.size-1&&(null==r||r(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))}),f),v.useEffect((()=>{if(c)return n&&(0===l.layersWithOutsidePointerEventsDisabled.size&&(bT=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(c)),l.layers.add(c),_T(),()=>{n&&1===l.layersWithOutsidePointerEventsDisabled.size&&(f.body.style.pointerEvents=bT)}}),[c,f,n,l]),v.useEffect((()=>()=>{c&&(l.layers.delete(c),l.layersWithOutsidePointerEventsDisabled.delete(c),_T())}),[c,l]),v.useEffect((()=>{const e=()=>p({});return document.addEventListener(FS,e),()=>document.removeEventListener(FS,e)}),[]),G.jsx(Il.div,{...u,ref:m,style:{pointerEvents:w?x?"auto":"none":void 0,...e.style},onFocusCapture:sd(e.onFocusCapture,E.onFocusCapture),onBlurCapture:sd(e.onBlurCapture,E.onBlurCapture),onPointerDownCapture:sd(e.onPointerDownCapture,_.onPointerDownCapture)})}));iD.displayName=jB;var UB="DismissableLayerBranch",WB=v.forwardRef(((e,t)=>{const n=v.useContext(oD),r=v.useRef(null),o=ep(t,r);return v.useEffect((()=>{const e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}}),[n.branches]),G.jsx(Il.div,{...e,ref:o})}));function qB(e,t=(null==globalThis?void 0:globalThis.document)){const n=Yf(e),r=v.useRef(!1),o=v.useRef((()=>{}));return v.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){aD(zB,n,a,{discrete:!0})};const a={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",o.current),o.current=r,t.addEventListener("click",o.current,{once:!0})):r()}else t.removeEventListener("click",o.current);r.current=!1},a=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",e),t.removeEventListener("click",o.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}function GB(e,t=(null==globalThis?void 0:globalThis.document)){const n=Yf(e),r=v.useRef(!1);return v.useEffect((()=>{const e=e=>{e.target&&!r.current&&aD(VB,n,{originalEvent:e},{discrete:!1})};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function _T(){const e=new CustomEvent(FS);document.dispatchEvent(e)}function aD(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?FB(o,a):o.dispatchEvent(a)}WB.displayName=UB;var fx="focusScope.autoFocusOnMount",px="focusScope.autoFocusOnUnmount",xT={bubbles:!1,cancelable:!0},HB="FocusScope",sD=v.forwardRef(((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...i}=e,[s,u]=v.useState(null),l=Yf(o),c=Yf(a),d=v.useRef(null),f=ep(t,(e=>u(e))),p=v.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;v.useEffect((()=>{if(r){let e=function(e){if(p.paused||!s)return;const t=e.target;s.contains(t)?d.current=t:id(d.current,{select:!0})},t=function(e){if(p.paused||!s)return;const t=e.relatedTarget;null!==t&&(s.contains(t)||id(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(const t of e)t.removedNodes.length>0&&id(s)};document.addEventListener("focusin",e),document.addEventListener("focusout",t);const r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),r.disconnect()}}}),[r,s,p.paused]),v.useEffect((()=>{if(s){ET.add(p);const e=document.activeElement;if(!s.contains(e)){const t=new CustomEvent(fx,xT);s.addEventListener(fx,l),s.dispatchEvent(t),t.defaultPrevented||(KB(ZB(uD(s)),{select:!0}),document.activeElement===e&&id(s))}return()=>{s.removeEventListener(fx,l),setTimeout((()=>{const t=new CustomEvent(px,xT);s.addEventListener(px,c),s.dispatchEvent(t),t.defaultPrevented||id(e??document.body,{select:!0}),s.removeEventListener(px,c),ET.remove(p)}),0)}}}),[s,l,c,p]);const m=v.useCallback((e=>{if(!n&&!r||p.paused)return;const t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,o=document.activeElement;if(t&&o){const t=e.currentTarget,[r,a]=YB(t);r&&a?e.shiftKey||o!==a?e.shiftKey&&o===r&&(e.preventDefault(),n&&id(a,{select:!0})):(e.preventDefault(),n&&id(r,{select:!0})):o===t&&e.preventDefault()}}),[n,r,p.paused]);return G.jsx(Il.div,{tabIndex:-1,...i,ref:f,onKeyDown:m})}));function KB(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(id(r,{select:t}),document.activeElement!==n)return}function YB(e){const t=uD(e);return[ST(t,e),ST(t.reverse(),e)]}function uD(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{const t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function ST(e,t){for(const n of e)if(!QB(n,{upTo:t}))return n}function QB(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function XB(e){return e instanceof HTMLInputElement&&"select"in e}function id(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&XB(e)&&t&&e.select()}}sD.displayName=HB;var ET=JB();function JB(){let e=[];return{add(t){const n=e[0];t!==n&&(null==n||n.pause()),e=$T(e,t),e.unshift(t)},remove(t){var n;e=$T(e,t),null==(n=e[0])||n.resume()}}}function $T(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}function ZB(e){return e.filter((e=>"A"!==e.tagName))}var ej="Portal",lD=v.forwardRef(((e,t)=>{var n;const{container:r,...o}=e,[a,i]=v.useState(!1);Xg((()=>i(!0)),[]);const s=r||a&&(null==(n=null==globalThis?void 0:globalThis.document)?void 0:n.body);return s?eA.createPortal(G.jsx(Il.div,{...o,ref:t}),s):null}));function tj(e,t){return v.useReducer(((e,n)=>t[e][n]??e),e)}lD.displayName=ej;var By=e=>{const{present:t,children:n}=e,r=nj(t),o="function"==typeof n?n({present:r.isPresent}):v.Children.only(n),a=ep(r.ref,rj(o));return"function"==typeof n||r.isPresent?v.cloneElement(o,{ref:a}):null};function nj(e){const[t,n]=v.useState(),r=v.useRef({}),o=v.useRef(e),a=v.useRef("none"),i=e?"mounted":"unmounted",[s,u]=tj(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect((()=>{const e=Cg(r.current);a.current="mounted"===s?e:"none"}),[s]),Xg((()=>{const t=r.current,n=o.current;if(n!==e){const r=a.current,i=Cg(t);e?u("MOUNT"):"none"===i||"none"===(null==t?void 0:t.display)?u("UNMOUNT"):u(n&&r!==i?"ANIMATION_OUT":"UNMOUNT"),o.current=e}}),[e,u]),Xg((()=>{if(t){let e;const n=t.ownerDocument.defaultView??window,i=a=>{const i=Cg(r.current).includes(a.animationName);if(a.target===t&&i&&(u("ANIMATION_END"),!o.current)){const r=t.style.animationFillMode;t.style.animationFillMode="forwards",e=n.setTimeout((()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=r)}))}},s=e=>{e.target===t&&(a.current=Cg(r.current))};return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",i),t.addEventListener("animationend",i),()=>{n.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",i),t.removeEventListener("animationend",i)}}u("ANIMATION_END")}),[t,u]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:v.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}function Cg(e){return(null==e?void 0:e.animationName)||"none"}function rj(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?e.ref:(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o?e.props.ref:e.props.ref||e.ref)}By.displayName="Presence";var mx=0;function oj(){v.useEffect((()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??CT()),document.body.insertAdjacentElement("beforeend",e[1]??CT()),mx++,()=>{1===mx&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),mx--}}),[])}function CT(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var cD=_A(),hx=function(){},jy=v.forwardRef((function(e,t){var n=v.useRef(null),r=v.useState({onScrollCapture:hx,onWheelCapture:hx,onTouchMoveCapture:hx}),o=r[0],a=r[1],i=e.forwardProps,s=e.children,u=e.className,l=e.removeScrollBar,c=e.enabled,d=e.shards,f=e.sideCar,p=e.noIsolation,m=e.inert,h=e.allowPinchZoom,g=e.as,y=void 0===g?"div":g,b=e.gapMode,w=EE(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),x=f,_=bA([n,t]),E=zo(zo({},w),o);return v.createElement(v.Fragment,null,c&&v.createElement(x,{sideCar:cD,removeScrollBar:l,shards:d,noIsolation:p,inert:m,setCallbacks:a,allowPinchZoom:!!h,lockRef:n,gapMode:b}),i?v.cloneElement(v.Children.only(s),zo(zo({},E),{ref:_})):v.createElement(y,zo({},E,{className:u,ref:_}),s))}));jy.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},jy.classNames={fullWidth:iv,zeroRight:ov};var BS=!1;if(typeof window<"u")try{var Ig=Object.defineProperty({},"passive",{get:function(){return BS=!0,!0}});window.addEventListener("test",Ig,Ig),window.removeEventListener("test",Ig,Ig)}catch{BS=!1}var _m=!!BS&&{passive:!1},ij=function(e){return"TEXTAREA"===e.tagName},dD=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&!(n.overflowY===n.overflowX&&!ij(e)&&"visible"===n[t])},aj=function(e){return dD(e,"overflowY")},sj=function(e){return dD(e,"overflowX")},IT=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host),fD(e,r)){var o=pD(e,r);if(o[1]>o[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},uj=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},lj=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},fD=function(e,t){return"v"===e?aj(t):sj(t)},pD=function(e,t){return"v"===e?uj(t):lj(t)},cj=function(e,t){return"h"===e&&"rtl"===t?-1:1},dj=function(e,t,n,r,o){var a=cj(e,window.getComputedStyle(t).direction),i=a*r,s=n.target,u=t.contains(s),l=!1,c=i>0,d=0,f=0;do{var p=pD(e,s),m=p[0],v=p[1]-p[2]-a*m;(m||v)&&fD(e,s)&&(d+=v,f+=m),s=s instanceof ShadowRoot?s.host:s.parentNode}while(!u&&s!==document.body||u&&(t.contains(s)||t===s));return(c&&(Math.abs(d)<1||!o)||!c&&(Math.abs(f)<1||!o))&&(l=!0),l},Rg=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},RT=function(e){return[e.deltaX,e.deltaY]},PT=function(e){return e&&"current"in e?e.current:e},fj=function(e,t){return e[0]===t[0]&&e[1]===t[1]},pj=function(e){return"\n .block-interactivity-".concat(e," {pointer-events: none;}\n .allow-interactivity-").concat(e," {pointer-events: all;}\n")},mj=0,xm=[];function hj(e){var t=v.useRef([]),n=v.useRef([0,0]),r=v.useRef(),o=v.useState(mj++)[0],a=v.useState($E)[0],i=v.useRef(e);v.useEffect((function(){i.current=e}),[e]),v.useEffect((function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var t=wA([e.lockRef.current],(e.shards||[]).map(PT),!0).filter(Boolean);return t.forEach((function(e){return e.classList.add("allow-interactivity-".concat(o))})),function(){document.body.classList.remove("block-interactivity-".concat(o)),t.forEach((function(e){return e.classList.remove("allow-interactivity-".concat(o))}))}}}),[e.inert,e.lockRef.current,e.shards]);var s=v.useCallback((function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!i.current.allowPinchZoom;var o,a=Rg(e),s=n.current,u="deltaX"in e?e.deltaX:s[0]-a[0],l="deltaY"in e?e.deltaY:s[1]-a[1],c=e.target,d=Math.abs(u)>Math.abs(l)?"h":"v";if("touches"in e&&"h"===d&&"range"===c.type)return!1;var f=IT(d,c);if(!f)return!0;if(f?o=d:(o="v"===d?"h":"v",f=IT(d,c)),!f)return!1;if(!r.current&&"changedTouches"in e&&(u||l)&&(r.current=o),!o)return!0;var p=r.current||o;return dj(p,t,e,"h"===p?u:l,!0)}),[]),u=v.useCallback((function(e){var n=e;if(xm.length&&xm[xm.length-1]===a){var r="deltaY"in n?RT(n):Rg(n),o=t.current.filter((function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&fj(e.delta,r)}))[0];if(o&&o.should)return void(n.cancelable&&n.preventDefault());if(!o){var u=(i.current.shards||[]).map(PT).filter(Boolean).filter((function(e){return e.contains(n.target)}));(u.length>0?s(n,u[0]):!i.current.noIsolation)&&n.cancelable&&n.preventDefault()}}}),[]),l=v.useCallback((function(e,n,r,o){var a={name:e,delta:n,target:r,should:o,shadowParent:vj(r)};t.current.push(a),setTimeout((function(){t.current=t.current.filter((function(e){return e!==a}))}),1)}),[]),c=v.useCallback((function(e){n.current=Rg(e),r.current=void 0}),[]),d=v.useCallback((function(t){l(t.type,RT(t),t.target,s(t,e.lockRef.current))}),[]),f=v.useCallback((function(t){l(t.type,Rg(t),t.target,s(t,e.lockRef.current))}),[]);v.useEffect((function(){return xm.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener("wheel",u,_m),document.addEventListener("touchmove",u,_m),document.addEventListener("touchstart",c,_m),function(){xm=xm.filter((function(e){return e!==a})),document.removeEventListener("wheel",u,_m),document.removeEventListener("touchmove",u,_m),document.removeEventListener("touchstart",c,_m)}}),[]);var p=e.removeScrollBar,m=e.inert;return v.createElement(v.Fragment,null,m?v.createElement(a,{styles:pj(o)}):null,p?v.createElement($A,{gapMode:e.gapMode}):null)}function vj(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const gj=SA(cD,hj);var mD=v.forwardRef((function(e,t){return v.createElement(jy,zo({},e,{ref:t,sideCar:gj}))}));mD.classNames=jy.classNames;var t$="Dialog",[hD,WJ]=CB(t$),[yj,_s]=hD(t$),vD=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:a,modal:i=!0}=e,s=v.useRef(null),u=v.useRef(null),[l=!1,c]=TB({prop:r,defaultProp:o,onChange:a});return G.jsx(yj,{scope:t,triggerRef:s,contentRef:u,contentId:dx(),titleId:dx(),descriptionId:dx(),open:l,onOpenChange:c,onOpenToggle:v.useCallback((()=>c((e=>!e))),[c]),modal:i,children:n})};vD.displayName=t$;var gD="DialogTrigger",yD=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s(gD,n),a=ep(t,o.triggerRef);return G.jsx(Il.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":o$(o.open),...r,ref:a,onClick:sd(e.onClick,o.onOpenToggle)})}));yD.displayName=gD;var n$="DialogPortal",[wj,wD]=hD(n$,{forceMount:void 0}),bD=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,a=_s(n$,t);return G.jsx(wj,{scope:t,forceMount:n,children:v.Children.map(r,(e=>G.jsx(By,{present:n||a.open,children:G.jsx(lD,{asChild:!0,container:o,children:e})})))})};bD.displayName=n$;var Jg="DialogOverlay",_D=v.forwardRef(((e,t)=>{const n=wD(Jg,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=_s(Jg,e.__scopeDialog);return a.modal?G.jsx(By,{present:r||a.open,children:G.jsx(_j,{...o,ref:t})}):null}));_D.displayName=Jg;var bj=rD("DialogOverlay.RemoveScroll"),_j=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s(Jg,n);return G.jsx(mD,{as:bj,allowPinchZoom:!0,shards:[o.contentRef],children:G.jsx(Il.div,{"data-state":o$(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})})),Qf="DialogContent",xD=v.forwardRef(((e,t)=>{const n=wD(Qf,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=_s(Qf,e.__scopeDialog);return G.jsx(By,{present:r||a.open,children:a.modal?G.jsx(xj,{...o,ref:t}):G.jsx(Sj,{...o,ref:t})})}));xD.displayName=Qf;var xj=v.forwardRef(((e,t)=>{const n=_s(Qf,e.__scopeDialog),r=v.useRef(null),o=ep(t,n.contentRef,r);return v.useEffect((()=>{const e=r.current;if(e)return Sy(e)}),[]),G.jsx(SD,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:sd(e.onCloseAutoFocus,(e=>{var t;e.preventDefault(),null==(t=n.triggerRef.current)||t.focus()})),onPointerDownOutside:sd(e.onPointerDownOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey;(2===t.button||n)&&e.preventDefault()})),onFocusOutside:sd(e.onFocusOutside,(e=>e.preventDefault()))})})),Sj=v.forwardRef(((e,t)=>{const n=_s(Qf,e.__scopeDialog),r=v.useRef(!1),o=v.useRef(!1);return G.jsx(SD,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var a,i;null==(a=e.onCloseAutoFocus)||a.call(e,t),t.defaultPrevented||(r.current||null==(i=n.triggerRef.current)||i.focus(),t.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:t=>{var a,i;null==(a=e.onInteractOutside)||a.call(e,t),t.defaultPrevented||(r.current=!0,"pointerdown"===t.detail.originalEvent.type&&(o.current=!0));const s=t.target;(null==(i=n.triggerRef.current)?void 0:i.contains(s))&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&o.current&&t.preventDefault()}})})),SD=v.forwardRef(((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,...i}=e,s=_s(Qf,n),u=v.useRef(null),l=ep(t,u);return oj(),G.jsxs(G.Fragment,{children:[G.jsx(sD,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:a,children:G.jsx(iD,{role:"dialog",id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":o$(s.open),...i,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),G.jsxs(G.Fragment,{children:[G.jsx(Ej,{titleId:s.titleId}),G.jsx(Cj,{contentRef:u,descriptionId:s.descriptionId})]})]})})),r$="DialogTitle",ED=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s(r$,n);return G.jsx(Il.h2,{id:o.titleId,...r,ref:t})}));ED.displayName=r$;var $D="DialogDescription",CD=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s($D,n);return G.jsx(Il.p,{id:o.descriptionId,...r,ref:t})}));CD.displayName=$D;var ID="DialogClose",RD=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s(ID,n);return G.jsx(Il.button,{type:"button",...r,ref:t,onClick:sd(e.onClick,(()=>o.onOpenChange(!1)))})}));function o$(e){return e?"open":"closed"}RD.displayName=ID;var PD="DialogTitleWarning",[qJ,TD]=$B(PD,{contentName:Qf,titleName:r$,docsSlug:"dialog"}),Ej=({titleId:e})=>{const t=TD(PD),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.\n\nIf you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.\n\nFor more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return v.useEffect((()=>{e&&(document.getElementById(e)||console.error(n))}),[n,e]),null},$j="DialogDescriptionWarning",Cj=({contentRef:e,descriptionId:t})=>{const n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${TD($j).contentName}}.`;return v.useEffect((()=>{var r;const o=null==(r=e.current)?void 0:r.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(n))}),[n,e,t]),null},Ij=vD,Rj=yD,Pj=bD,Tj=_D,Oj=xD,Aj=ED,Mj=CD,Dj=RD;function Nj(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const OD=Ue.createContext({drawerRef:{current:null},overlayRef:{current:null},onPress:()=>{},onRelease:()=>{},onDrag:()=>{},onNestedDrag:()=>{},onNestedOpenChange:()=>{},onNestedRelease:()=>{},openProp:void 0,dismissible:!1,isOpen:!1,isDragging:!1,keyboardIsOpen:{current:!1},snapPointsOffset:null,snapPoints:null,handleOnly:!1,modal:!1,shouldFade:!1,activeSnapPoint:null,onOpenChange:()=>{},setActiveSnapPoint:()=>{},closeDrawer:()=>{},direction:"bottom",shouldScaleBackground:!1,setBackgroundColorOnScale:!0,noBodyStyles:!1,container:null,autoFocus:!1}),Vm=()=>{const e=Ue.useContext(OD);if(!e)throw new Error("useDrawerContext must be used within a Drawer.Root");return e};Nj("[data-vaul-drawer]{touch-action:none;will-change:transform;transition:transform .5s cubic-bezier(.32, .72, 0, 1);animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=open]{animation-name:slideFromBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=closed]{animation-name:slideToBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=open]{animation-name:slideFromTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=closed]{animation-name:slideToTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=open]{animation-name:slideFromLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=closed]{animation-name:slideToLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=open]{animation-name:slideFromRight}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=closed]{animation-name:slideToRight}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,100%,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,-100%,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(-100%,0,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(100%,0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-overlay][data-vaul-snap-points=false]{animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-overlay][data-vaul-snap-points=false][data-state=open]{animation-name:fadeIn}[data-vaul-overlay][data-state=closed]{animation-name:fadeOut}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:0;transition:opacity .5s cubic-bezier(.32, .72, 0, 1)}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:1}[data-vaul-drawer]:not([data-vaul-custom-container=true])::after{content:'';position:absolute;background:inherit;background-color:inherit}[data-vaul-drawer][data-vaul-drawer-direction=top]::after{top:initial;bottom:100%;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=bottom]::after{top:100%;bottom:initial;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=left]::after{left:initial;right:100%;top:0;bottom:0;width:200%}[data-vaul-drawer][data-vaul-drawer-direction=right]::after{left:100%;right:initial;top:0;bottom:0;width:200%}[data-vaul-overlay][data-vaul-snap-points=true]:not([data-vaul-snap-points-overlay=true]):not(\n[data-state=closed]\n){opacity:0}[data-vaul-overlay][data-vaul-snap-points-overlay=true]{opacity:1}[data-vaul-handle]{display:block;position:relative;opacity:.7;background:#e2e2e4;margin-left:auto;margin-right:auto;height:5px;width:32px;border-radius:1rem;touch-action:pan-y}[data-vaul-handle]:active,[data-vaul-handle]:hover{opacity:1}[data-vaul-handle-hitarea]{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:max(100%,2.75rem);height:max(100%,2.75rem);touch-action:inherit}@media (hover:hover) and (pointer:fine){[data-vaul-drawer]{user-select:none}}@media (pointer:fine){[data-vaul-handle-hitarea]:{width:100%;height:100%}}@keyframes fadeIn{from{opacity:0}to{opacity:1}}@keyframes fadeOut{to{opacity:0}}@keyframes slideFromBottom{from{transform:translate3d(0,100%,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToBottom{to{transform:translate3d(0,100%,0)}}@keyframes slideFromTop{from{transform:translate3d(0,-100%,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToTop{to{transform:translate3d(0,-100%,0)}}@keyframes slideFromLeft{from{transform:translate3d(-100%,0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToLeft{to{transform:translate3d(-100%,0,0)}}@keyframes slideFromRight{from{transform:translate3d(100%,0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToRight{to{transform:translate3d(100%,0,0)}}");const kj=24,Lj=typeof window<"u"?v.useLayoutEffect:v.useEffect;function TT(...e){return(...t)=>{for(let n of e)"function"==typeof n&&n(...t)}}function Fj(){return i$(/^Mac/)}function Bj(){return i$(/^iPhone/)}function OT(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}function jj(){return i$(/^iPad/)||Fj()&&navigator.maxTouchPoints>1}function AD(){return Bj()||jj()}function i$(e){return typeof window<"u"&&null!=window.navigator?e.test(window.navigator.platform):void 0}const vx=typeof document<"u"&&window.visualViewport;function AT(e){let t=window.getComputedStyle(e);return/(auto|scroll)/.test(t.overflow+t.overflowX+t.overflowY)}function MD(e){for(AT(e)&&(e=e.parentElement);e&&!AT(e);)e=e.parentElement;return e||document.scrollingElement||document.documentElement}const zj=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);let gx,Pg=0;function Vj(e={}){let{isDisabled:t}=e;Lj((()=>{if(!t)return Pg++,1===Pg&&AD()&&(gx=Uj()),()=>{Pg--,0===Pg&&(null==gx||gx())}}),[t])}function Uj(){let e,t=0,n=window.pageXOffset,r=window.pageYOffset,o=TT(Wj(document.documentElement,"paddingRight",window.innerWidth-document.documentElement.clientWidth+"px"));window.scrollTo(0,0);let a=TT(qh(document,"touchstart",(n=>{e=MD(n.target),(e!==document.documentElement||e!==document.body)&&(t=n.changedTouches[0].pageY)}),{passive:!1,capture:!0}),qh(document,"touchmove",(n=>{if(!e||e===document.documentElement||e===document.body)return void n.preventDefault();let r=n.changedTouches[0].pageY,o=e.scrollTop,a=e.scrollHeight-e.clientHeight;0!==a&&((o<=0&&r>t||o>=a&&r<t)&&n.preventDefault(),t=r)}),{passive:!1,capture:!0}),qh(document,"touchend",(e=>{let t=e.target;jS(t)&&t!==document.activeElement&&(e.preventDefault(),t.style.transform="translateY(-2000px)",t.focus(),requestAnimationFrame((()=>{t.style.transform=""})))}),{passive:!1,capture:!0}),qh(document,"focus",(e=>{let t=e.target;jS(t)&&(t.style.transform="translateY(-2000px)",requestAnimationFrame((()=>{t.style.transform="",vx&&(vx.height<window.innerHeight?requestAnimationFrame((()=>{MT(t)})):vx.addEventListener("resize",(()=>MT(t)),{once:!0}))})))}),!0),qh(window,"scroll",(()=>{window.scrollTo(0,0)})));return()=>{o(),a(),window.scrollTo(n,r)}}function Wj(e,t,n){let r=e.style[t];return e.style[t]=n,()=>{e.style[t]=r}}function qh(e,t,n,r){return e.addEventListener(t,n,r),()=>{e.removeEventListener(t,n,r)}}function MT(e){let t=document.scrollingElement||document.documentElement;for(;e&&e!==t;){let t=MD(e);if(t!==document.documentElement&&t!==document.body&&t!==e){let n=t.getBoundingClientRect().top,r=e.getBoundingClientRect().top;e.getBoundingClientRect().bottom>t.getBoundingClientRect().bottom+24&&(t.scrollTop+=r-n)}e=t.parentElement}}function jS(e){return e instanceof HTMLInputElement&&!zj.has(e.type)||e instanceof HTMLTextAreaElement||e instanceof HTMLElement&&e.isContentEditable}function qj(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Gj(...e){return t=>e.forEach((e=>qj(e,t)))}function DD(...e){return v.useCallback(Gj(...e),e)}const ND=new WeakMap;function Ur(e,t,n=!1){if(!(e&&e instanceof HTMLElement))return;let r={};Object.entries(t).forEach((([t,n])=>{t.startsWith("--")?e.style.setProperty(t,n):(r[t]=e.style[t],e.style[t]=n)})),!n&&ND.set(e,r)}function Hj(e,t){if(!(e&&e instanceof HTMLElement))return;let n=ND.get(e);n&&(e.style[t]=n[t])}const Wr=e=>{switch(e){case"top":case"bottom":return!0;case"left":case"right":return!1;default:return e}};function Tg(e,t){if(!e)return null;const n=window.getComputedStyle(e),r=n.transform||n.webkitTransform||n.mozTransform;let o=r.match(/^matrix3d\((.+)\)$/);return o?parseFloat(o[1].split(", ")[Wr(t)?13:12]):(o=r.match(/^matrix\((.+)\)$/),o?parseFloat(o[1].split(", ")[Wr(t)?5:4]):null)}function Kj(e){return 8*(Math.log(e+1)-2)}function yx(e,t){if(!e)return()=>{};const n=e.style.cssText;return Object.assign(e.style,t),()=>{e.style.cssText=n}}function Yj(...e){return(...t)=>{for(const n of e)"function"==typeof n&&n(...t)}}const zn={DURATION:.5,EASE:[.32,.72,0,1]},kD=.4,Qj=.25,Xj=100,LD=8,Af=16,zS=26,wx="vaul-dragging";function FD(e){const t=Ue.useRef(e);return Ue.useEffect((()=>{t.current=e})),Ue.useMemo((()=>(...e)=>null==t.current?void 0:t.current.call(t,...e)),[])}function Jj({defaultProp:e,onChange:t}){const n=Ue.useState(e),[r]=n,o=Ue.useRef(r),a=FD(t);return Ue.useEffect((()=>{o.current!==r&&(a(r),o.current=r)}),[r,o,a]),n}function BD({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=Jj({defaultProp:t,onChange:n}),a=void 0!==e,i=a?e:r,s=FD(n);return[i,Ue.useCallback((t=>{if(a){const n="function"==typeof t?t(e):t;n!==e&&s(n)}else o(t)}),[a,e,o,s])]}function Zj({activeSnapPointProp:e,setActiveSnapPointProp:t,snapPoints:n,drawerRef:r,overlayRef:o,fadeFromIndex:a,onSnapPointChange:i,direction:s="bottom",container:u,snapToSequentialPoint:l}){const[c,d]=BD({prop:e,defaultProp:null==n?void 0:n[0],onChange:t}),[f,p]=Ue.useState(typeof window<"u"?{innerWidth:window.innerWidth,innerHeight:window.innerHeight}:void 0);Ue.useEffect((()=>{function e(){p({innerWidth:window.innerWidth,innerHeight:window.innerHeight})}return window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)}),[]);const m=Ue.useMemo((()=>c===(null==n?void 0:n[n.length-1])||null),[n,c]),v=Ue.useMemo((()=>null==n?void 0:n.findIndex((e=>e===c))),[n,c]),h=n&&n.length>0&&(a||0===a)&&!Number.isNaN(a)&&n[a]===c||!n,g=Ue.useMemo((()=>{const e=u?{width:u.getBoundingClientRect().width,height:u.getBoundingClientRect().height}:typeof window<"u"?{width:window.innerWidth,height:window.innerHeight}:{width:0,height:0};var t;return null!=(t=null==n?void 0:n.map((t=>{const n="string"==typeof t;let r=0;if(n&&(r=parseInt(t,10)),Wr(s)){const o=n?r:f?t*e.height:0;return f?"bottom"===s?e.height-o:-e.height+o:o}const o=n?r:f?t*e.width:0;return f?"right"===s?e.width-o:-e.width+o:o})))?t:[]}),[n,f,u]),y=Ue.useMemo((()=>null!==v?null==g?void 0:g[v]:null),[g,v]),b=Ue.useCallback((e=>{var t;const u=null!=(t=null==g?void 0:g.findIndex((t=>t===e)))?t:null;i(u),Ur(r.current,{transition:`transform ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,transform:Wr(s)?`translate3d(0, ${e}px, 0)`:`translate3d(${e}px, 0, 0)`}),g&&u!==g.length-1&&u!==a&&u<a?Ur(o.current,{transition:`opacity ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,opacity:"0"}):Ur(o.current,{transition:`opacity ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,opacity:"1"}),d(null==n?void 0:n[Math.max(u,0)])}),[r.current,n,g,a,o,d]);return Ue.useEffect((()=>{if(c||e){var t;const r=null!=(t=null==n?void 0:n.findIndex((t=>t===e||t===c)))?t:-1;g&&-1!==r&&"number"==typeof g[r]&&b(g[r])}}),[c,e,n,g,b]),{isLastSnapPoint:m,activeSnapPoint:c,shouldFade:h,getPercentageDragged:function(e,t){if(!n||"number"!=typeof v||!g||void 0===a)return null;const r=v===a-1;if(v>=a&&t)return 0;if(r&&!t)return 1;if(!h&&!r)return null;const o=r?v+1:v-1,i=r?g[o]-g[o-1]:g[o+1]-g[o],s=e/Math.abs(i);return r?1-s:s},setActiveSnapPoint:d,activeSnapPointIndex:v,onRelease:function({draggedDistance:e,closeDrawer:t,velocity:r,dismissible:i}){if(void 0===a)return;const u="bottom"===s||"right"===s?(y??0)-e:(y??0)+e,c=0===v,d=e>0;if(v===a-1&&Ur(o.current,{transition:`opacity ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`}),!l&&r>2&&!d)return void(i?t():b(g[0]));if(!l&&r>2&&d&&g&&n)return void b(g[n.length-1]);const f=null==g?void 0:g.reduce(((e,t)=>"number"!=typeof e||"number"!=typeof t?e:Math.abs(t-u)<Math.abs(e-u)?t:e)),p=Wr(s)?window.innerHeight:window.innerWidth;if(r>kD&&Math.abs(e)<.4*p){const e=d?1:-1;if(e>0&&m)return void b(g[n.length-1]);if(c&&e<0&&i&&t(),null===v)return;b(g[v+e])}else b(f)},onDrag:function({draggedDistance:e}){if(null===y)return;const t="bottom"===s||"right"===s?y-e:y+e;("bottom"===s||"right"===s)&&t<g[g.length-1]||("top"===s||"left"===s)&&t>g[g.length-1]||Ur(r.current,{transform:Wr(s)?`translate3d(0, ${t}px, 0)`:`translate3d(${t}px, 0, 0)`})},snapPointsOffset:g}}const ez=()=>()=>{};function tz(){const{direction:e,isOpen:t,shouldScaleBackground:n,setBackgroundColorOnScale:r,noBodyStyles:o}=Vm(),a=Ue.useRef(null),i=v.useMemo((()=>document.body.style.backgroundColor),[]);function s(){return(window.innerWidth-26)/window.innerWidth}Ue.useEffect((()=>{if(t&&n){a.current&&clearTimeout(a.current);const t=document.querySelector("[data-vaul-drawer-wrapper]")||document.querySelector("[vaul-drawer-wrapper]");if(!t)return;Yj(r&&!o?yx(document.body,{background:"black"}):ez,yx(t,{transformOrigin:Wr(e)?"top":"left",transitionProperty:"transform, border-radius",transitionDuration:`${zn.DURATION}s`,transitionTimingFunction:`cubic-bezier(${zn.EASE.join(",")})`}));const n=yx(t,{borderRadius:"8px",overflow:"hidden",...Wr(e)?{transform:`scale(${s()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`}:{transform:`scale(${s()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`}});return()=>{n(),a.current=window.setTimeout((()=>{i?document.body.style.background=i:document.body.style.removeProperty("background")}),1e3*zn.DURATION)}}}),[t,n,i])}let Gh=null;function nz({isOpen:e,modal:t,nested:n,hasBeenOpened:r,preventScrollRestoration:o,noBodyStyles:a}){const[i,s]=Ue.useState((()=>typeof window<"u"?window.location.href:"")),u=Ue.useRef(0),l=Ue.useCallback((()=>{if(OT()&&null===Gh&&e&&!a){Gh={position:document.body.style.position,top:document.body.style.top,left:document.body.style.left,height:document.body.style.height,right:"unset"};const{scrollX:e,innerHeight:t}=window;document.body.style.setProperty("position","fixed","important"),Object.assign(document.body.style,{top:-u.current+"px",left:-e+"px",right:"0px",height:"auto"}),window.setTimeout((()=>window.requestAnimationFrame((()=>{const e=t-window.innerHeight;e&&u.current>=t&&(document.body.style.top=-(u.current+e)+"px")}))),300)}}),[e]),c=Ue.useCallback((()=>{if(OT()&&null!==Gh&&!a){const e=-parseInt(document.body.style.top,10),t=-parseInt(document.body.style.left,10);Object.assign(document.body.style,Gh),window.requestAnimationFrame((()=>{o&&i!==window.location.href?s(window.location.href):window.scrollTo(t,e)})),Gh=null}}),[i]);return Ue.useEffect((()=>{function e(){u.current=window.scrollY}return e(),window.addEventListener("scroll",e),()=>{window.removeEventListener("scroll",e)}}),[]),Ue.useEffect((()=>{n||!r||(e?(!window.matchMedia("(display-mode: standalone)").matches&&l(),t||window.setTimeout((()=>{c()}),500)):c())}),[e,r,i,t,n,l,c]),{restorePositionSetting:c}}function jD({open:e,onOpenChange:t,children:n,onDrag:r,onRelease:o,snapPoints:a,shouldScaleBackground:i=!1,setBackgroundColorOnScale:s=!0,closeThreshold:u=Qj,scrollLockTimeout:l=Xj,dismissible:c=!0,handleOnly:d=!1,fadeFromIndex:f=a&&a.length-1,activeSnapPoint:p,setActiveSnapPoint:m,fixed:v,modal:h=!0,onClose:g,nested:y,noBodyStyles:b,direction:w="bottom",defaultOpen:x=!1,disablePreventScroll:_=!0,snapToSequentialPoint:E=!1,preventScrollRestoration:S=!1,repositionInputs:I=!0,onAnimationEnd:A,container:k,autoFocus:C=!1}){var T,R;const[P=!1,O]=BD({defaultProp:x,prop:e,onChange:e=>{null==t||t(e),!e&&!y&&ue(),setTimeout((()=>{null==A||A(e)}),1e3*zn.DURATION),e&&!h&&typeof window<"u"&&window.requestAnimationFrame((()=>{document.body.style.pointerEvents="auto"})),e||(document.body.style.pointerEvents="auto")}}),[N,M]=Ue.useState(!1),[j,D]=Ue.useState(!1),[q,z]=Ue.useState(!1),L=Ue.useRef(null),$=Ue.useRef(null),V=Ue.useRef(null),B=Ue.useRef(null),F=Ue.useRef(null),U=Ue.useRef(!1),G=Ue.useRef(null),W=Ue.useRef(0),H=Ue.useRef(!1),Q=Ue.useRef(0),K=Ue.useRef(null),Y=Ue.useRef((null==(T=K.current)?void 0:T.getBoundingClientRect().height)||0),J=Ue.useRef((null==(R=K.current)?void 0:R.getBoundingClientRect().width)||0),X=Ue.useRef(0),Z=Ue.useCallback((e=>{a&&e===oe.length-1&&($.current=new Date)}),[]),{activeSnapPoint:ee,activeSnapPointIndex:te,setActiveSnapPoint:ne,onRelease:re,snapPointsOffset:oe,onDrag:ae,shouldFade:ie,getPercentageDragged:se}=Zj({snapPoints:a,activeSnapPointProp:p,setActiveSnapPointProp:m,drawerRef:K,fadeFromIndex:f,overlayRef:L,onSnapPointChange:Z,direction:w,container:k,snapToSequentialPoint:E});Vj({isDisabled:!P||j||!h||q||!N||!I||!_});const{restorePositionSetting:ue}=nz({isOpen:P,modal:h,nested:y,hasBeenOpened:N,preventScrollRestoration:S,noBodyStyles:b});function le(){return(window.innerWidth-26)/window.innerWidth}function ce(e,t){var n,r;let o=e;const a=null==(n=window.getSelection())?void 0:n.toString(),i=K.current?Tg(K.current,w):null,s=new Date;if(o.hasAttribute("data-vaul-no-drag")||o.closest("[data-vaul-no-drag]"))return!1;if("right"===w||"left"===w)return!0;if($.current&&s.getTime()-$.current.getTime()<500)return!1;if(null!==i&&("bottom"===w?i>0:i<0))return!0;if(a&&a.length>0)return!1;if(s.getTime()-(null==(r=F.current)?void 0:r.getTime())<l&&0===i||t)return F.current=s,!1;for(;o;){if(o.scrollHeight>o.clientHeight){if(0!==o.scrollTop)return F.current=new Date,!1;if("dialog"===o.getAttribute("role"))return!0}o=o.parentNode}return!0}function de(e){!j||!K.current||(K.current.classList.remove(wx),U.current=!1,D(!1),B.current=new Date),null==g||g(),e||O(!1),setTimeout((()=>{a&&ne(a[0])}),1e3*zn.DURATION)}function fe(){if(!K.current)return;const e=document.querySelector("[data-vaul-drawer-wrapper]"),t=Tg(K.current,w);Ur(K.current,{transform:"translate3d(0, 0, 0)",transition:`transform ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`}),Ur(L.current,{transition:`opacity ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,opacity:"1"}),i&&t&&t>0&&P&&Ur(e,{borderRadius:"8px",overflow:"hidden",...Wr(w)?{transform:`scale(${le()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`,transformOrigin:"top"}:{transform:`scale(${le()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`,transformOrigin:"left"},transitionProperty:"transform, border-radius",transitionDuration:`${zn.DURATION}s`,transitionTimingFunction:`cubic-bezier(${zn.EASE.join(",")})`},!0)}return Ue.useEffect((()=>{var e;function t(){if(!K.current||!I)return;if(jS(document.activeElement)||H.current){var e;const t=(null==(e=window.visualViewport)?void 0:e.height)||0,n=window.innerHeight;let r=n-t;const o=K.current.getBoundingClientRect().height||0,i=o>.8*n;X.current||(X.current=o);const s=K.current.getBoundingClientRect().top;if(Math.abs(Q.current-r)>60&&(H.current=!H.current),a&&a.length>0&&oe&&te){r+=oe[te]||0}if(Q.current=r,o>t||H.current){const e=K.current.getBoundingClientRect().height;let n=e;e>t&&(n=t-(i?s:26)),K.current.style.height=v?e-Math.max(r,0)+"px":`${Math.max(n,t-s)}px`}else K.current.style.height=`${X.current}px`;a&&a.length>0&&!H.current?K.current.style.bottom="0px":K.current.style.bottom=`${Math.max(r,0)}px`}}return null==(e=window.visualViewport)||e.addEventListener("resize",t),()=>{var e;return null==(e=window.visualViewport)?void 0:e.removeEventListener("resize",t)}}),[te,a,oe]),Ue.useEffect((()=>(P&&(Ur(document.documentElement,{scrollBehavior:"auto"}),$.current=new Date),()=>{Hj(document.documentElement,"scrollBehavior")})),[P]),Ue.createElement(Ij,{defaultOpen:x,onOpenChange:e=>{!c&&!e||(e?M(!0):de(!0),O(e))},open:P},Ue.createElement(OD.Provider,{value:{activeSnapPoint:ee,snapPoints:a,setActiveSnapPoint:ne,drawerRef:K,overlayRef:L,onOpenChange:t,onPress:function(e){var t,n;!c&&!a||K.current&&!K.current.contains(e.target)||(Y.current=(null==(t=K.current)?void 0:t.getBoundingClientRect().height)||0,J.current=(null==(n=K.current)?void 0:n.getBoundingClientRect().width)||0,D(!0),V.current=new Date,AD()&&window.addEventListener("touchend",(()=>U.current=!1),{once:!0}),e.target.setPointerCapture(e.pointerId),W.current=Wr(w)?e.pageY:e.pageX)},onRelease:function(e){if(!j||!K.current)return;K.current.classList.remove(wx),U.current=!1,D(!1),B.current=new Date;const t=Tg(K.current,w);if(!ce(e.target,!1)||!t||Number.isNaN(t)||null===V.current)return;const n=B.current.getTime()-V.current.getTime(),r=W.current-(Wr(w)?e.pageY:e.pageX),i=Math.abs(r)/n;if(i>.05&&(z(!0),setTimeout((()=>{z(!1)}),200)),a)return re({draggedDistance:r*("bottom"===w||"right"===w?1:-1),closeDrawer:de,velocity:i,dismissible:c}),void(null==o||o(e,!0));if("bottom"===w||"right"===w?r>0:r<0)return fe(),void(null==o||o(e,!0));if(i>kD)return de(),void(null==o||o(e,!1));var s;const l=Math.min(null!=(s=K.current.getBoundingClientRect().height)?s:0,window.innerHeight);var d;const f=Math.min(null!=(d=K.current.getBoundingClientRect().width)?d:0,window.innerWidth),p="left"===w||"right"===w;if(Math.abs(t)>=(p?f:l)*u)return de(),void(null==o||o(e,!1));null==o||o(e,!0),fe()},onDrag:function(e){if(K.current&&j){const t="bottom"===w||"right"===w?1:-1,n=(W.current-(Wr(w)?e.pageY:e.pageX))*t,o=n>0,s=a&&!c&&!o;if(s&&0===te)return;const u=Math.abs(n),l=document.querySelector("[data-vaul-drawer-wrapper]");let d=u/("bottom"===w||"top"===w?Y.current:J.current);const p=se(u,o);if(null!==p&&(d=p),s&&d>=1||!U.current&&!ce(e.target,o))return;if(K.current.classList.add(wx),U.current=!0,Ur(K.current,{transition:"none"}),Ur(L.current,{transition:"none"}),a&&ae({draggedDistance:n}),o&&!a){const e=Kj(n),r=Math.min(-1*e,0)*t;return void Ur(K.current,{transform:Wr(w)?`translate3d(0, ${r}px, 0)`:`translate3d(${r}px, 0, 0)`})}const m=1-d;if((ie||f&&te===f-1)&&(null==r||r(e,d),Ur(L.current,{opacity:`${m}`,transition:"none"},!0)),l&&L.current&&i){const e=Math.min(le()+d*(1-le()),1),t=8-8*d,n=Math.max(0,14-14*d);Ur(l,{borderRadius:`${t}px`,transform:Wr(w)?`scale(${e}) translate3d(0, ${n}px, 0)`:`scale(${e}) translate3d(${n}px, 0, 0)`,transition:"none"},!0)}if(!a){const e=u*t;Ur(K.current,{transform:Wr(w)?`translate3d(0, ${e}px, 0)`:`translate3d(${e}px, 0, 0)`})}}},dismissible:c,handleOnly:d,isOpen:P,isDragging:j,shouldFade:ie,closeDrawer:de,onNestedDrag:function(e,t){if(t<0)return;const n=(window.innerWidth-16)/window.innerWidth,r=n+t*(1-n),o=16*t-16;Ur(K.current,{transform:Wr(w)?`scale(${r}) translate3d(0, ${o}px, 0)`:`scale(${r}) translate3d(${o}px, 0, 0)`,transition:"none"})},onNestedOpenChange:function(e){const t=e?(window.innerWidth-16)/window.innerWidth:1,n=e?-16:0;G.current&&window.clearTimeout(G.current),Ur(K.current,{transition:`transform ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,transform:`scale(${t}) translate3d(0, ${n}px, 0)`}),!e&&K.current&&(G.current=setTimeout((()=>{const e=Tg(K.current,w);Ur(K.current,{transition:"none",transform:Wr(w)?`translate3d(0, ${e}px, 0)`:`translate3d(${e}px, 0, 0)`})}),500))},onNestedRelease:function(e,t){const n=Wr(w)?window.innerHeight:window.innerWidth,r=t?(n-16)/n:1,o=t?-16:0;t&&Ur(K.current,{transition:`transform ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,transform:Wr(w)?`scale(${r}) translate3d(0, ${o}px, 0)`:`scale(${r}) translate3d(${o}px, 0, 0)`})},keyboardIsOpen:H,modal:h,snapPointsOffset:oe,direction:w,shouldScaleBackground:i,setBackgroundColorOnScale:s,noBodyStyles:b,container:k,autoFocus:C}},n))}const zD=Ue.forwardRef((function({...e},t){const{overlayRef:n,snapPoints:r,onRelease:o,shouldFade:a,isOpen:i,modal:s}=Vm(),u=DD(t,n),l=r&&r.length>0;return s?Ue.createElement(Tj,{onMouseUp:o,ref:u,"data-vaul-overlay":"","data-vaul-snap-points":i&&l?"true":"false","data-vaul-snap-points-overlay":i&&a?"true":"false",...e}):(typeof window<"u"&&window.requestAnimationFrame((()=>{document.body.style.pointerEvents="auto"})),null)}));zD.displayName="Drawer.Overlay";const VD=Ue.forwardRef((function({onPointerDownOutside:e,style:t,onOpenAutoFocus:n,...r},o){const{drawerRef:a,onPress:i,onRelease:s,onDrag:u,keyboardIsOpen:l,snapPointsOffset:c,modal:d,isOpen:f,direction:p,snapPoints:m,container:v,handleOnly:h,autoFocus:g}=Vm(),[y,b]=Ue.useState(!1),w=DD(o,a),x=Ue.useRef(null),_=Ue.useRef(null),E=Ue.useRef(!1),S=m&&m.length>0;tz();function I(e){x.current=null,E.current=!1,s(e)}return Ue.useEffect((()=>{S&&window.requestAnimationFrame((()=>{b(!0)}))}),[]),Ue.createElement(Oj,{"data-vaul-drawer-direction":p,"data-vaul-drawer":"","data-vaul-delayed-snap-points":y?"true":"false","data-vaul-snap-points":f&&S?"true":"false","data-vaul-custom-container":v?"true":"false",...r,ref:w,style:c&&c.length>0?{"--snap-point-height":`${c[0]}px`,...t}:t,onPointerDown:e=>{h||(null==r.onPointerDown||r.onPointerDown.call(r,e),x.current={x:e.pageX,y:e.pageY},i(e))},onOpenAutoFocus:e=>{null==n||n(e),g||e.preventDefault()},onPointerDownOutside:t=>{null==e||e(t),d&&!t.defaultPrevented?l.current&&(l.current=!1):t.preventDefault()},onFocusOutside:e=>{d||e.preventDefault()},onPointerMove:e=>{if(_.current=e,h||(null==r.onPointerMove||r.onPointerMove.call(r,e),!x.current))return;const t=e.pageY-x.current.y,n=e.pageX-x.current.x,o="touch"===e.pointerType?10:2;((e,t,n=0)=>{if(E.current)return!0;const r=Math.abs(e.y),o=Math.abs(e.x),a=o>r,i=["bottom","right"].includes(t)?1:-1;if("left"===t||"right"===t){if(!(e.x*i<0)&&o>=0&&o<=n)return a}else if(!(e.y*i<0)&&r>=0&&r<=n)return!a;return E.current=!0,!0})({x:n,y:t},p,o)?u(e):(Math.abs(n)>o||Math.abs(t)>o)&&(x.current=null)},onPointerUp:e=>{null==r.onPointerUp||r.onPointerUp.call(r,e),x.current=null,E.current=!1,s(e)},onPointerOut:e=>{null==r.onPointerOut||r.onPointerOut.call(r,e),I(_.current)},onContextMenu:e=>{null==r.onContextMenu||r.onContextMenu.call(r,e),I(_.current)}})}));VD.displayName="Drawer.Content";const rz=250,oz=120,UD=Ue.forwardRef((function({preventCycle:e=!1,children:t,...n},r){const{closeDrawer:o,isDragging:a,snapPoints:i,activeSnapPoint:s,setActiveSnapPoint:u,dismissible:l,handleOnly:c,isOpen:d,onPress:f,onDrag:p}=Vm(),m=Ue.useRef(null),v=Ue.useRef(!1);function h(){window.clearTimeout(m.current),v.current=!1}return Ue.createElement("div",{onClick:function(){v.current?h():window.setTimeout((()=>{!function(){if(a||e||v.current)return void h();if(h(),(!i||0===i.length)&&l)return void o();if(s===i[i.length-1]&&l)return void o();const t=i.findIndex((e=>e===s));if(-1===t)return;const n=i[t+1];u(n)}()}),oz)},onPointerCancel:h,onPointerDown:e=>{c&&f(e),m.current=window.setTimeout((()=>{v.current=!0}),rz)},onPointerMove:e=>{c&&p(e)},ref:r,"data-vaul-drawer-visible":d?"true":"false","data-vaul-handle":"","aria-hidden":"true",...n},Ue.createElement("span",{"data-vaul-handle-hitarea":"","aria-hidden":"true"},t))}));function iz({onDrag:e,onOpenChange:t,...n}){const{onNestedDrag:r,onNestedOpenChange:o,onNestedRelease:a}=Vm();if(!r)throw new Error("Drawer.NestedRoot must be placed in another drawer");return Ue.createElement(jD,{nested:!0,onClose:()=>{o(!1)},onDrag:(t,n)=>{r(t,n),null==e||e(t,n)},onOpenChange:e=>{e&&o(e)},onRelease:a,...n})}function az(e){const t=Vm(),{container:n=t.container,...r}=e;return Ue.createElement(Pj,{container:n,...r})}UD.displayName="Drawer.Handle";const wd={Root:jD,NestedRoot:iz,Content:VD,Overlay:zD,Trigger:Rj,Portal:az,Handle:UD,Close:Dj,Title:Aj,Description:Mj},sz=wd.Portal,WD=v.forwardRef((({className:e,...t},n)=>G.jsx(wd.Overlay,{ref:n,className:we("fixed inset-0 z-50 bg-black/5",e),...t})));WD.displayName=wd.Overlay.displayName;const uz=v.forwardRef((({className:e,children:t,direction:n="bottom",...r},o)=>G.jsxs(sz,{children:[G.jsx(WD,{}),G.jsxs(wd.Content,{ref:o,className:we("fixed z-50 border bg-background shadow-lg","bottom"===n&&"inset-x-0 bottom-0 mt-24 flex h-auto flex-col rounded-t-sm","top"===n&&"inset-x-0 top-0 mb-24 flex h-auto flex-col rounded-b-sm","left"===n&&"inset-y-0 left-0 flex h-full flex-col","right"===n&&"inset-y-0 right-0 flex h-full w-[346px] flex-col sm:w-[435px]",e),...r,children:["bottom"===n&&G.jsx("div",{className:"mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted"}),t]})]})));uz.displayName="DrawerContent";const lz=v.forwardRef((({className:e,...t},n)=>G.jsx(wd.Title,{ref:n,className:we("text-lg font-semibold leading-none tracking-tight",e),...t})));lz.displayName=wd.Title.displayName;const cz=v.forwardRef((({className:e,...t},n)=>G.jsx(wd.Description,{ref:n,className:we("text-sm text-muted-foreground",e),...t})));function a$(e){const t=e+"CollectionProvider",[n,r]=ni(t),[o,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=e+"CollectionSlot",s=e+"CollectionItemSlot",u="data-radix-collection-item";return[{Provider:e=>{const{scope:t,children:n}=e,r=Ue.useRef(null),a=Ue.useRef(new Map).current;return Ue.createElement(o,{scope:t,itemMap:a,collectionRef:r},n)},Slot:Ue.forwardRef(((e,t)=>{const{scope:n,children:r}=e,o=Vt(t,a(i,n).collectionRef);return Ue.createElement(qf,{ref:o},r)})),ItemSlot:Ue.forwardRef(((e,t)=>{const{scope:n,children:r,...o}=e,i=Ue.useRef(null),l=Vt(t,i),c=a(s,n);return Ue.useEffect((()=>(c.itemMap.set(i,{ref:i,...o}),()=>{c.itemMap.delete(i)}))),Ue.createElement(qf,{[u]:"",ref:l},r)}))},function(t){const n=a(e+"CollectionConsumer",t);return Ue.useCallback((()=>{const e=n.collectionRef.current;if(!e)return[];const t=Array.from(e.querySelectorAll(`[${u}]`));return Array.from(n.itemMap.values()).sort(((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current)))}),[n.collectionRef,n.itemMap])},r]}cz.displayName=wd.Description.displayName;const dz=v.createContext(void 0);function s$(e){const t=v.useContext(dz);return e||t||"ltr"}const fz=["top","right","bottom","left"],pd=Math.min,Xi=Math.max,Zg=Math.round,Og=Math.floor,md=e=>({x:e,y:e}),pz={left:"right",right:"left",bottom:"top",top:"bottom"},mz={start:"end",end:"start"};function VS(e,t,n){return Xi(e,pd(t,n))}function Sl(e,t){return"function"==typeof e?e(t):e}function El(e){return e.split("-")[0]}function Um(e){return e.split("-")[1]}function u$(e){return"x"===e?"y":"x"}function l$(e){return"y"===e?"height":"width"}function hd(e){return["top","bottom"].includes(El(e))?"y":"x"}function c$(e){return u$(hd(e))}function hz(e,t,n){void 0===n&&(n=!1);const r=Um(e),o=c$(e),a=l$(o);let i="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[a]>t.floating[a]&&(i=ey(i)),[i,ey(i)]}function vz(e){const t=ey(e);return[US(e),t,US(t)]}function US(e){return e.replace(/start|end/g,(e=>mz[e]))}function gz(e,t,n){const r=["left","right"],o=["right","left"],a=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?a:i;default:return[]}}function yz(e,t,n,r){const o=Um(e);let a=gz(El(e),"start"===n,r);return o&&(a=a.map((e=>e+"-"+o)),t&&(a=a.concat(a.map(US)))),a}function ey(e){return e.replace(/left|right|bottom|top/g,(e=>pz[e]))}function wz(e){return{top:0,right:0,bottom:0,left:0,...e}}function qD(e){return"number"!=typeof e?wz(e):{top:e,right:e,bottom:e,left:e}}function ty(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function DT(e,t,n){let{reference:r,floating:o}=e;const a=hd(t),i=c$(t),s=l$(i),u=El(t),l="y"===a,c=r.x+r.width/2-o.width/2,d=r.y+r.height/2-o.height/2,f=r[s]/2-o[s]/2;let p;switch(u){case"top":p={x:c,y:r.y-o.height};break;case"bottom":p={x:c,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:d};break;case"left":p={x:r.x-o.width,y:d};break;default:p={x:r.x,y:r.y}}switch(Um(t)){case"start":p[i]-=f*(n&&l?-1:1);break;case"end":p[i]+=f*(n&&l?-1:1)}return p}const bz=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:i}=n,s=a.filter(Boolean),u=await(null==i.isRTL?void 0:i.isRTL(t));let l=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:d}=DT(l,r,u),f=r,p={},m=0;for(let n=0;n<s.length;n++){const{name:a,fn:v}=s[n],{x:h,y:g,data:y,reset:b}=await v({x:c,y:d,initialPlacement:r,placement:f,strategy:o,middlewareData:p,rects:l,platform:i,elements:{reference:e,floating:t}});c=h??c,d=g??d,p={...p,[a]:{...p[a],...y}},b&&m<=50&&(m++,"object"==typeof b&&(b.placement&&(f=b.placement),b.rects&&(l=!0===b.rects?await i.getElementRects({reference:e,floating:t,strategy:o}):b.rects),({x:c,y:d}=DT(l,f,u))),n=-1)}return{x:c,y:d,placement:f,strategy:o,middlewareData:p}};async function yv(e,t){var n;void 0===t&&(t={});const{x:r,y:o,platform:a,rects:i,elements:s,strategy:u}=e,{boundary:l="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=Sl(t,e),m=qD(p),v=s[f?"floating"===d?"reference":"floating":d],h=ty(await a.getClippingRect({element:null==(n=await(null==a.isElement?void 0:a.isElement(v)))||n?v:v.contextElement||await(null==a.getDocumentElement?void 0:a.getDocumentElement(s.floating)),boundary:l,rootBoundary:c,strategy:u})),g="floating"===d?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,y=await(null==a.getOffsetParent?void 0:a.getOffsetParent(s.floating)),b=await(null==a.isElement?void 0:a.isElement(y))&&await(null==a.getScale?void 0:a.getScale(y))||{x:1,y:1},w=ty(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:g,offsetParent:y,strategy:u}):g);return{top:(h.top-w.top+m.top)/b.y,bottom:(w.bottom-h.bottom+m.bottom)/b.y,left:(h.left-w.left+m.left)/b.x,right:(w.right-h.right+m.right)/b.x}}const _z=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:a,platform:i,elements:s,middlewareData:u}=t,{element:l,padding:c=0}=Sl(e,t)||{};if(null==l)return{};const d=qD(c),f={x:n,y:r},p=c$(o),m=l$(p),v=await i.getDimensions(l),h="y"===p,g=h?"top":"left",y=h?"bottom":"right",b=h?"clientHeight":"clientWidth",w=a.reference[m]+a.reference[p]-f[p]-a.floating[m],x=f[p]-a.reference[p],_=await(null==i.getOffsetParent?void 0:i.getOffsetParent(l));let E=_?_[b]:0;(!E||!await(null==i.isElement?void 0:i.isElement(_)))&&(E=s.floating[b]||a.floating[m]);const S=w/2-x/2,I=E/2-v[m]/2-1,A=pd(d[g],I),k=pd(d[y],I),C=A,T=E-v[m]-k,R=E/2-v[m]/2+S,P=VS(C,R,T),O=!u.arrow&&null!=Um(o)&&R!==P&&a.reference[m]/2-(R<C?A:k)-v[m]/2<0,N=O?R<C?R-C:R-T:0;return{[p]:f[p]+N,data:{[p]:P,centerOffset:R-P-N,...O&&{alignmentOffset:N}},reset:O}}}),xz=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:a,rects:i,initialPlacement:s,platform:u,elements:l}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:v=!0,...h}=Sl(e,t);if(null!=(n=a.arrow)&&n.alignmentOffset)return{};const g=El(o),y=hd(s),b=El(s)===s,w=await(null==u.isRTL?void 0:u.isRTL(l.floating)),x=f||(b||!v?[ey(s)]:vz(s)),_="none"!==m;!f&&_&&x.push(...yz(s,v,m,w));const E=[s,...x],S=await yv(t,h),I=[];let A=(null==(r=a.flip)?void 0:r.overflows)||[];if(c&&I.push(S[g]),d){const e=hz(o,i,w);I.push(S[e[0]],S[e[1]])}if(A=[...A,{placement:o,overflows:I}],!I.every((e=>e<=0))){var k,C;const e=((null==(k=a.flip)?void 0:k.index)||0)+1,t=E[e];if(t)return{data:{index:e,overflows:A},reset:{placement:t}};let n=null==(C=A.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:C.placement;if(!n)switch(p){case"bestFit":{var T;const e=null==(T=A.filter((e=>{if(_){const t=hd(e.placement);return t===y||"y"===t}return!0})).map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:T[0];e&&(n=e);break}case"initialPlacement":n=s}if(o!==n)return{reset:{placement:n}}}return{}}}};function NT(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function kT(e){return fz.some((t=>e[t]>=0))}const Sz=function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=Sl(e,t);switch(r){case"referenceHidden":{const e=NT(await yv(t,{...o,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:kT(e)}}}case"escaped":{const e=NT(await yv(t,{...o,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:kT(e)}}}default:return{}}}}};async function Ez(e,t){const{placement:n,platform:r,elements:o}=e,a=await(null==r.isRTL?void 0:r.isRTL(o.floating)),i=El(n),s=Um(n),u="y"===hd(n),l=["left","top"].includes(i)?-1:1,c=a&&u?-1:1,d=Sl(t,e);let{mainAxis:f,crossAxis:p,alignmentAxis:m}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof m&&(p="end"===s?-1*m:m),u?{x:p*c,y:f*l}:{x:f*l,y:p*c}}const $z=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:a,placement:i,middlewareData:s}=t,u=await Ez(t,e);return i===(null==(n=s.offset)?void 0:n.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:o+u.x,y:a+u.y,data:{...u,placement:i}}}}},Cz=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:i=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...u}=Sl(e,t),l={x:n,y:r},c=await yv(t,u),d=hd(El(o)),f=u$(d);let p=l[f],m=l[d];if(a){const e="y"===f?"bottom":"right";p=VS(p+c["y"===f?"top":"left"],p,p-c[e])}if(i){const e="y"===d?"bottom":"right";m=VS(m+c["y"===d?"top":"left"],m,m-c[e])}const v=s.fn({...t,[f]:p,[d]:m});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[f]:a,[d]:i}}}}}},Iz=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:i}=t,{offset:s=0,mainAxis:u=!0,crossAxis:l=!0}=Sl(e,t),c={x:n,y:r},d=hd(o),f=u$(d);let p=c[f],m=c[d];const v=Sl(s,t),h="number"==typeof v?{mainAxis:v,crossAxis:0}:{mainAxis:0,crossAxis:0,...v};if(u){const e="y"===f?"height":"width",t=a.reference[f]-a.floating[e]+h.mainAxis,n=a.reference[f]+a.reference[e]-h.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){var g,y;const e="y"===f?"width":"height",t=["top","left"].includes(El(o)),n=a.reference[d]-a.floating[e]+(t&&(null==(g=i.offset)?void 0:g[d])||0)+(t?0:h.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:(null==(y=i.offset)?void 0:y[d])||0)-(t?h.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[f]:p,[d]:m}}}},Rz=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:a,platform:i,elements:s}=t,{apply:u=()=>{},...l}=Sl(e,t),c=await yv(t,l),d=El(o),f=Um(o),p="y"===hd(o),{width:m,height:v}=a.floating;let h,g;"top"===d||"bottom"===d?(h=d,g=f===(await(null==i.isRTL?void 0:i.isRTL(s.floating))?"start":"end")?"left":"right"):(g=d,h="end"===f?"top":"bottom");const y=v-c.top-c.bottom,b=m-c.left-c.right,w=pd(v-c[h],y),x=pd(m-c[g],b),_=!t.middlewareData.shift;let E=w,S=x;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(S=b),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(E=y),_&&!f){const e=Xi(c.left,0),t=Xi(c.right,0),n=Xi(c.top,0),r=Xi(c.bottom,0);p?S=m-2*(0!==e||0!==t?e+t:Xi(c.left,c.right)):E=v-2*(0!==n||0!==r?n+r:Xi(c.top,c.bottom))}await u({...t,availableWidth:S,availableHeight:E});const I=await i.getDimensions(s.floating);return m!==I.width||v!==I.height?{reset:{rects:!0}}:{}}}};function zy(){return typeof window<"u"}function vd(e){return GD(e)?(e.nodeName||"").toLowerCase():"#document"}function Ji(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Rl(e){var t;return null==(t=(GD(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function GD(e){return!!zy()&&(e instanceof Node||e instanceof Ji(e).Node)}function pu(e){return!!zy()&&(e instanceof Element||e instanceof Ji(e).Element)}function mu(e){return!!zy()&&(e instanceof HTMLElement||e instanceof Ji(e).HTMLElement)}function LT(e){return!(!zy()||typeof ShadowRoot>"u")&&(e instanceof ShadowRoot||e instanceof Ji(e).ShadowRoot)}function Fv(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Na(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function Pz(e){return["table","td","th"].includes(vd(e))}function Tz(e){return[":popover-open",":modal"].some((t=>{try{return e.matches(t)}catch{return!1}}))}function d$(e){const t=f$(),n=pu(e)?Na(e):e;return"none"!==n.transform||"none"!==n.perspective||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((e=>(n.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(n.contain||"").includes(e)))}function HD(e){let t=Nm(e);for(;mu(t)&&!Vy(t);){if(d$(t))return t;if(Tz(t))return null;t=Nm(t)}return null}function f$(){return!(typeof CSS>"u"||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function Vy(e){return["html","body","#document"].includes(vd(e))}function Na(e){return Ji(e).getComputedStyle(e)}function Uy(e){return pu(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Nm(e){if("html"===vd(e))return e;const t=e.assignedSlot||e.parentNode||LT(e)&&e.host||Rl(e);return LT(t)?t.host:t}function KD(e){const t=Nm(e);return Vy(t)?e.ownerDocument?e.ownerDocument.body:e.body:mu(t)&&Fv(t)?t:KD(t)}function wv(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const o=KD(e),a=o===(null==(r=e.ownerDocument)?void 0:r.body),i=Ji(o);if(a){const e=Oz(i);return t.concat(i,i.visualViewport||[],Fv(o)?o:[],e&&n?wv(e):[])}return t.concat(o,wv(o,[],n))}function Oz(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function YD(e){const t=Na(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=mu(e),a=o?e.offsetWidth:n,i=o?e.offsetHeight:r,s=Zg(n)!==a||Zg(r)!==i;return s&&(n=a,r=i),{width:n,height:r,$:s}}function p$(e){return pu(e)?e:e.contextElement}function Pm(e){const t=p$(e);if(!mu(t))return md(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=YD(t);let i=(a?Zg(n.width):n.width)/r,s=(a?Zg(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!s||!Number.isFinite(s))&&(s=1),{x:i,y:s}}const Az=md(0);function QD(e){const t=Ji(e);return f$()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Az}function Mz(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==Ji(e))&&t}function Xf(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const o=e.getBoundingClientRect(),a=p$(e);let i=md(1);t&&(r?pu(r)&&(i=Pm(r)):i=Pm(e));const s=Mz(a,n,r)?QD(a):md(0);let u=(o.left+s.x)/i.x,l=(o.top+s.y)/i.y,c=o.width/i.x,d=o.height/i.y;if(a){const e=Ji(a),t=r&&pu(r)?Ji(r):r;let n=e.frameElement;for(;n&&r&&t!==e;){const e=Pm(n),t=n.getBoundingClientRect(),r=Na(n),o=t.left+(n.clientLeft+parseFloat(r.paddingLeft))*e.x,a=t.top+(n.clientTop+parseFloat(r.paddingTop))*e.y;u*=e.x,l*=e.y,c*=e.x,d*=e.y,u+=o,l+=a,n=Ji(n).frameElement}}return ty({width:c,height:d,x:u,y:l})}const Dz=[":popover-open",":modal"];function XD(e){let t=!1,n=0,r=0;if(Dz.forEach((n=>{!function(n){try{t=t||e.matches(n)}catch{}}(n)})),t){const t=HD(e);if(t){const e=t.getBoundingClientRect();n=e.x,r=e.y}}return[t,n,r]}function Nz(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=Rl(r),[i]=t?XD(t.floating):[!1];if(r===a||i)return n;let s={scrollLeft:0,scrollTop:0},u=md(1);const l=md(0),c=mu(r);if((c||!c&&"fixed"!==o)&&(("body"!==vd(r)||Fv(a))&&(s=Uy(r)),mu(r))){const e=Xf(r);u=Pm(r),l.x=e.x+r.clientLeft,l.y=e.y+r.clientTop}return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-s.scrollLeft*u.x+l.x,y:n.y*u.y-s.scrollTop*u.y+l.y}}function kz(e){return Array.from(e.getClientRects())}function JD(e){return Xf(Rl(e)).left+Uy(e).scrollLeft}function Lz(e){const t=Rl(e),n=Uy(e),r=e.ownerDocument.body,o=Xi(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Xi(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+JD(e);const s=-n.scrollTop;return"rtl"===Na(r).direction&&(i+=Xi(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:i,y:s}}function Fz(e,t){const n=Ji(e),r=Rl(e),o=n.visualViewport;let a=r.clientWidth,i=r.clientHeight,s=0,u=0;if(o){a=o.width,i=o.height;const e=f$();(!e||e&&"fixed"===t)&&(s=o.offsetLeft,u=o.offsetTop)}return{width:a,height:i,x:s,y:u}}function Bz(e,t){const n=Xf(e,!0,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=mu(e)?Pm(e):md(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:o*a.x,y:r*a.y}}function FT(e,t,n){let r;if("viewport"===t)r=Fz(e,n);else if("document"===t)r=Lz(Rl(e));else if(pu(t))r=Bz(t,n);else{const n=QD(e);r={...t,x:t.x-n.x,y:t.y-n.y}}return ty(r)}function ZD(e,t){const n=Nm(e);return!(n===t||!pu(n)||Vy(n))&&("fixed"===Na(n).position||ZD(n,t))}function jz(e,t){const n=t.get(e);if(n)return n;let r=wv(e,[],!1).filter((e=>pu(e)&&"body"!==vd(e))),o=null;const a="fixed"===Na(e).position;let i=a?Nm(e):e;for(;pu(i)&&!Vy(i);){const t=Na(i),n=d$(i);!n&&"fixed"===t.position&&(o=null),(a?!n&&!o:!n&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||Fv(i)&&!n&&ZD(e,i))?r=r.filter((e=>e!==i)):o=t,i=Nm(i)}return t.set(e,r),r}function zz(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[..."clippingAncestors"===n?jz(t,this._c):[].concat(n),r],i=a[0],s=a.reduce(((e,n)=>{const r=FT(t,n,o);return e.top=Xi(r.top,e.top),e.right=pd(r.right,e.right),e.bottom=pd(r.bottom,e.bottom),e.left=Xi(r.left,e.left),e}),FT(t,i,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}}function Vz(e){const{width:t,height:n}=YD(e);return{width:t,height:n}}function Uz(e,t,n,r){const o=mu(t),a=Rl(t),i="fixed"===n,s=Xf(e,!0,i,t);let u={scrollLeft:0,scrollTop:0};const l=md(0);if(o||!o&&!i)if(("body"!==vd(t)||Fv(a))&&(u=Uy(t)),o){const e=Xf(t,!0,i,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else a&&(l.x=JD(a));let c=s.left+u.scrollLeft-l.x,d=s.top+u.scrollTop-l.y;const[f,p,m]=XD(r);return f&&(c+=p,d+=m,o&&(c+=t.clientLeft,d+=t.clientTop)),{x:c,y:d,width:s.width,height:s.height}}function BT(e,t){return mu(e)&&"fixed"!==Na(e).position?t?t(e):e.offsetParent:null}function eN(e,t){const n=Ji(e);if(!mu(e))return n;let r=BT(e,t);for(;r&&Pz(r)&&"static"===Na(r).position;)r=BT(r,t);return r&&("html"===vd(r)||"body"===vd(r)&&"static"===Na(r).position&&!d$(r))?n:r||HD(e)||n}const Wz=async function(e){const t=this.getOffsetParent||eN,n=this.getDimensions;return{reference:Uz(e.reference,await t(e.floating),e.strategy,e.floating),floating:{x:0,y:0,...await n(e.floating)}}};function qz(e){return"rtl"===Na(e).direction}const Gz={convertOffsetParentRelativeRectToViewportRelativeRect:Nz,getDocumentElement:Rl,getClippingRect:zz,getOffsetParent:eN,getElementRects:Wz,getClientRects:kz,getDimensions:Vz,getScale:Pm,isElement:pu,isRTL:qz};function Hz(e,t){let n,r=null;const o=Rl(e);function a(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function i(s,u){void 0===s&&(s=!1),void 0===u&&(u=1),a();const{left:l,top:c,width:d,height:f}=e.getBoundingClientRect();if(s||t(),!d||!f)return;const p={rootMargin:-Og(c)+"px "+-Og(o.clientWidth-(l+d))+"px "+-Og(o.clientHeight-(c+f))+"px "+-Og(l)+"px",threshold:Xi(0,pd(1,u))||1};let m=!0;function v(e){const t=e[0].intersectionRatio;if(t!==u){if(!m)return i();t?i(!1,t):n=setTimeout((()=>{i(!1,1e-7)}),100)}m=!1}try{r=new IntersectionObserver(v,{...p,root:o.ownerDocument})}catch{r=new IntersectionObserver(v,p)}r.observe(e)}(!0),a}function Kz(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:i="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:u=!1}=r,l=p$(e),c=o||a?[...l?wv(l):[],...wv(t)]:[];c.forEach((e=>{o&&e.addEventListener("scroll",n,{passive:!0}),a&&e.addEventListener("resize",n)}));const d=l&&s?Hz(l,n):null;let f=-1,p=null;i&&(p=new ResizeObserver((e=>{let[r]=e;r&&r.target===l&&p&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame((()=>{var e;null==(e=p)||e.observe(t)}))),n()})),l&&!u&&p.observe(l),p.observe(t));let m,v=u?Xf(e):null;return u&&function t(){const r=Xf(e);v&&(r.x!==v.x||r.y!==v.y||r.width!==v.width||r.height!==v.height)&&n(),v=r,m=requestAnimationFrame(t)}(),n(),()=>{var e;c.forEach((e=>{o&&e.removeEventListener("scroll",n),a&&e.removeEventListener("resize",n)})),null==d||d(),null==(e=p)||e.disconnect(),p=null,u&&cancelAnimationFrame(m)}}const Yz=Cz,Qz=xz,Xz=Rz,Jz=Sz,jT=_z,Zz=Iz,eV=(e,t,n)=>{const r=new Map,o={platform:Gz,...n},a={...o.platform,_c:r};return bz(e,t,{...o,platform:a})};var Vg=typeof document<"u"?v.useLayoutEffect:v.useEffect;function ny(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;0!=r--;)if(!ny(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){const n=o[r];if(!("_owner"===n&&e.$$typeof||ny(e[n],t[n])))return!1}return!0}return e!=e&&t!=t}function tN(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function zT(e,t){const n=tN(e);return Math.round(t*n)/n}function bx(e){const t=v.useRef(e);return Vg((()=>{t.current=e})),t}function tV(e){void 0===e&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:a,floating:i}={},transform:s=!0,whileElementsMounted:u,open:l}=e,[c,d]=v.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=v.useState(r);ny(f,r)||p(r);const[m,h]=v.useState(null),[g,y]=v.useState(null),b=v.useCallback((e=>{e!==E.current&&(E.current=e,h(e))}),[]),w=v.useCallback((e=>{e!==S.current&&(S.current=e,y(e))}),[]),x=a||m,_=i||g,E=v.useRef(null),S=v.useRef(null),I=v.useRef(c),A=null!=u,k=bx(u),C=bx(o),T=bx(l),R=v.useCallback((()=>{if(!E.current||!S.current)return;const e={placement:t,strategy:n,middleware:f};C.current&&(e.platform=C.current),eV(E.current,S.current,e).then((e=>{const t={...e,isPositioned:!1!==T.current};P.current&&!ny(I.current,t)&&(I.current=t,vu.flushSync((()=>{d(t)})))}))}),[f,t,n,C,T]);Vg((()=>{!1===l&&I.current.isPositioned&&(I.current.isPositioned=!1,d((e=>({...e,isPositioned:!1}))))}),[l]);const P=v.useRef(!1);Vg((()=>(P.current=!0,()=>{P.current=!1})),[]),Vg((()=>{if(x&&(E.current=x),_&&(S.current=_),x&&_){if(k.current)return k.current(x,_,R);R()}}),[x,_,R,k,A]);const O=v.useMemo((()=>({reference:E,floating:S,setReference:b,setFloating:w})),[b,w]),N=v.useMemo((()=>({reference:x,floating:_})),[x,_]),M=v.useMemo((()=>{const e={position:n,left:0,top:0};if(!N.floating)return e;const t=zT(N.floating,c.x),r=zT(N.floating,c.y);return s?{...e,transform:"translate("+t+"px, "+r+"px)",...tN(N.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}}),[n,s,N.floating,c.x,c.y]);return v.useMemo((()=>({...c,update:R,refs:O,elements:N,floatingStyles:M})),[c,R,O,N,M])}const nV=e=>({name:"arrow",options:e,fn(t){const{element:n,padding:r}="function"==typeof e?e(t):e;return n&&function(e){return{}.hasOwnProperty.call(e,"current")}(n)?null!=n.current?jT({element:n.current,padding:r}).fn(t):{}:n?jT({element:n,padding:r}).fn(t):{}}}),rV=(e,t)=>({...$z(e),options:[e,t]}),oV=(e,t)=>({...Yz(e),options:[e,t]}),iV=(e,t)=>({...Zz(e),options:[e,t]}),aV=(e,t)=>({...Qz(e),options:[e,t]}),sV=(e,t)=>({...Xz(e),options:[e,t]}),uV=(e,t)=>({...Jz(e),options:[e,t]}),lV=(e,t)=>({...nV(e),options:[e,t]}),nN="Popper",[rN,Wm]=ni(nN),[cV,oN]=rN(nN),dV=e=>{const{__scopePopper:t,children:n}=e,[r,o]=v.useState(null);return v.createElement(cV,{scope:t,anchor:r,onAnchorChange:o},n)},fV="PopperAnchor",pV=v.forwardRef(((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,a=oN(fV,n),i=v.useRef(null),s=Vt(t,i);return v.useEffect((()=>{a.onAnchorChange((null==r?void 0:r.current)||i.current)})),r?null:v.createElement(ft.div,Te({},o,{ref:s}))})),iN="PopperContent",[mV,GJ]=rN(iN),hV=v.forwardRef(((e,t)=>{var n,r,o,a,i,s,u,l;const{__scopePopper:c,side:d="bottom",sideOffset:f=0,align:p="center",alignOffset:m=0,arrowPadding:h=0,avoidCollisions:g=!0,collisionBoundary:y=[],collisionPadding:b=0,sticky:w="partial",hideWhenDetached:x=!1,updatePositionStrategy:_="optimized",onPlaced:E,...S}=e,I=oN(iN,c),[A,k]=v.useState(null),C=Vt(t,(e=>k(e))),[T,R]=v.useState(null),P=Ly(T),O=null!==(n=null==P?void 0:P.width)&&void 0!==n?n:0,N=null!==(r=null==P?void 0:P.height)&&void 0!==r?r:0,M=d+("center"!==p?"-"+p:""),j="number"==typeof b?b:{top:0,right:0,bottom:0,left:0,...b},D=Array.isArray(y)?y:[y],q=D.length>0,z={padding:j,boundary:D.filter(vV),altBoundary:q},{refs:L,floatingStyles:$,placement:V,isPositioned:B,middlewareData:F}=tV({strategy:"fixed",placement:M,whileElementsMounted:(...e)=>Kz(...e,{animationFrame:"always"===_}),elements:{reference:I.anchor},middleware:[rV({mainAxis:f+N,alignmentAxis:m}),g&&oV({mainAxis:!0,crossAxis:!1,limiter:"partial"===w?iV():void 0,...z}),g&&aV({...z}),sV({...z,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:o,height:a}=t.reference,i=e.floating.style;i.setProperty("--radix-popper-available-width",`${n}px`),i.setProperty("--radix-popper-available-height",`${r}px`),i.setProperty("--radix-popper-anchor-width",`${o}px`),i.setProperty("--radix-popper-anchor-height",`${a}px`)}}),T&&lV({element:T,padding:h}),gV({arrowWidth:O,arrowHeight:N}),x&&uV({strategy:"referenceHidden",...z})]}),[U,G]=aN(V),W=ws(E);Vo((()=>{B&&(null==W||W())}),[B,W]);const H=null===(o=F.arrow)||void 0===o?void 0:o.x,Q=null===(a=F.arrow)||void 0===a?void 0:a.y,K=0!==(null===(i=F.arrow)||void 0===i?void 0:i.centerOffset),[Y,J]=v.useState();return Vo((()=>{A&&J(window.getComputedStyle(A).zIndex)}),[A]),v.createElement("div",{ref:L.setFloating,"data-radix-popper-content-wrapper":"",style:{...$,transform:B?$.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Y,"--radix-popper-transform-origin":[null===(s=F.transformOrigin)||void 0===s?void 0:s.x,null===(u=F.transformOrigin)||void 0===u?void 0:u.y].join(" ")},dir:e.dir},v.createElement(mV,{scope:c,placedSide:U,onArrowChange:R,arrowX:H,arrowY:Q,shouldHideArrow:K},v.createElement(ft.div,Te({"data-side":U,"data-align":G},S,{ref:C,style:{...S.style,animation:B?void 0:"none",opacity:null!==(l=F.hide)&&void 0!==l&&l.referenceHidden?0:void 0}}))))}));function vV(e){return null!==e}const gV=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,a,i;const{placement:s,rects:u,middlewareData:l}=t,c=0!==(null===(n=l.arrow)||void 0===n?void 0:n.centerOffset),d=c?0:e.arrowWidth,f=c?0:e.arrowHeight,[p,m]=aN(s),v={start:"0%",center:"50%",end:"100%"}[m],h=(null!==(r=null===(o=l.arrow)||void 0===o?void 0:o.x)&&void 0!==r?r:0)+d/2,g=(null!==(a=null===(i=l.arrow)||void 0===i?void 0:i.y)&&void 0!==a?a:0)+f/2;let y="",b="";return"bottom"===p?(y=c?v:`${h}px`,b=-f+"px"):"top"===p?(y=c?v:`${h}px`,b=`${u.floating.height+f}px`):"right"===p?(y=-f+"px",b=c?v:`${g}px`):"left"===p&&(y=`${u.floating.width+f}px`,b=c?v:`${g}px`),{data:{x:y,y:b}}}});function aN(e){const[t,n="center"]=e.split("-");return[t,n]}const sN=dV,m$=pV,h$=hV,_x="rovingFocusGroup.onEntryFocus",yV={bubbles:!1,cancelable:!0},v$="RovingFocusGroup",[WS,uN,wV]=a$(v$),[bV,qm]=ni(v$,[wV]),[_V,xV]=bV(v$),SV=v.forwardRef(((e,t)=>v.createElement(WS.Provider,{scope:e.__scopeRovingFocusGroup},v.createElement(WS.Slot,{scope:e.__scopeRovingFocusGroup},v.createElement(EV,Te({},e,{ref:t})))))),EV=v.forwardRef(((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:a,currentTabStopId:i,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:u,onEntryFocus:l,...c}=e,d=v.useRef(null),f=Vt(t,d),p=s$(a),[m=null,h]=fd({prop:i,defaultProp:s,onChange:u}),[g,y]=v.useState(!1),b=ws(l),w=uN(n),x=v.useRef(!1),[_,E]=v.useState(0);return v.useEffect((()=>{const e=d.current;if(e)return e.addEventListener(_x,b),()=>e.removeEventListener(_x,b)}),[b]),v.createElement(_V,{scope:n,orientation:r,dir:p,loop:o,currentTabStopId:m,onItemFocus:v.useCallback((e=>h(e)),[h]),onItemShiftTab:v.useCallback((()=>y(!0)),[]),onFocusableItemAdd:v.useCallback((()=>E((e=>e+1))),[]),onFocusableItemRemove:v.useCallback((()=>E((e=>e-1))),[])},v.createElement(ft.div,Te({tabIndex:g||0===_?-1:0,"data-orientation":r},c,{ref:f,style:{outline:"none",...e.style},onMouseDown:et(e.onMouseDown,(()=>{x.current=!0})),onFocus:et(e.onFocus,(e=>{const t=!x.current;if(e.target===e.currentTarget&&t&&!g){const t=new CustomEvent(_x,yV);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){const e=w().filter((e=>e.focusable));lN([e.find((e=>e.active)),e.find((e=>e.id===m)),...e].filter(Boolean).map((e=>e.ref.current)))}}x.current=!1})),onBlur:et(e.onBlur,(()=>y(!1)))})))})),$V="RovingFocusGroupItem",CV=v.forwardRef(((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:a,...i}=e,s=ad(),u=a||s,l=xV($V,n),c=l.currentTabStopId===u,d=uN(n),{onFocusableItemAdd:f,onFocusableItemRemove:p}=l;return v.useEffect((()=>{if(r)return f(),()=>p()}),[r,f,p]),v.createElement(WS.ItemSlot,{scope:n,id:u,focusable:r,active:o},v.createElement(ft.span,Te({tabIndex:c?0:-1,"data-orientation":l.orientation},i,{ref:t,onMouseDown:et(e.onMouseDown,(e=>{r?l.onItemFocus(u):e.preventDefault()})),onFocus:et(e.onFocus,(()=>l.onItemFocus(u))),onKeyDown:et(e.onKeyDown,(e=>{if("Tab"===e.key&&e.shiftKey)return void l.onItemShiftTab();if(e.target!==e.currentTarget)return;const t=PV(e,l.orientation,l.dir);if(void 0!==t){e.preventDefault();let n=d().filter((e=>e.focusable)).map((e=>e.ref.current));if("last"===t)n.reverse();else if("prev"===t||"next"===t){"prev"===t&&n.reverse();const r=n.indexOf(e.currentTarget);n=l.loop?TV(n,r+1):n.slice(r+1)}setTimeout((()=>lN(n)))}}))})))})),IV={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function RV(e,t){return"rtl"!==t?e:"ArrowLeft"===e?"ArrowRight":"ArrowRight"===e?"ArrowLeft":e}function PV(e,t,n){const r=RV(e.key,n);if(!("vertical"===t&&["ArrowLeft","ArrowRight"].includes(r)||"horizontal"===t&&["ArrowUp","ArrowDown"].includes(r)))return IV[r]}function lN(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function TV(e,t){return e.map(((n,r)=>e[(t+r)%e.length]))}const g$=SV,y$=CV,qS=["Enter"," "],OV=["ArrowDown","PageUp","Home"],cN=["ArrowUp","PageDown","End"],AV=[...OV,...cN],MV={ltr:[...qS,"ArrowRight"],rtl:[...qS,"ArrowLeft"]},DV={ltr:["ArrowLeft"],rtl:["ArrowRight"]},Wy="Menu",[bv,NV,kV]=a$(Wy),[tp,dN]=ni(Wy,[kV,Wm,qm]),fN=Wm(),pN=qm(),[HJ,np]=tp(Wy),[KJ,Bv]=tp(Wy),LV=v.forwardRef(((e,t)=>{const{__scopeMenu:n,...r}=e,o=fN(n);return v.createElement(m$,Te({},o,r,{ref:t}))})),mN="MenuPortal",[FV,hN]=tp(mN,{forceMount:void 0}),BV=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,a=np(mN,t);return v.createElement(FV,{scope:t,forceMount:n},v.createElement(ea,{present:n||a.open},v.createElement(by,{asChild:!0,container:o},r)))},vs="MenuContent",[jV,w$]=tp(vs),zV=v.forwardRef(((e,t)=>{const n=hN(vs,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=np(vs,e.__scopeMenu),i=Bv(vs,e.__scopeMenu);return v.createElement(bv.Provider,{scope:e.__scopeMenu},v.createElement(ea,{present:r||a.open},v.createElement(bv.Slot,{scope:e.__scopeMenu},i.modal?v.createElement(VV,Te({},o,{ref:t})):v.createElement(UV,Te({},o,{ref:t})))))})),VV=v.forwardRef(((e,t)=>{const n=np(vs,e.__scopeMenu),r=v.useRef(null),o=Vt(t,r);return v.useEffect((()=>{const e=r.current;if(e)return Sy(e)}),[]),v.createElement(b$,Te({},e,{ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:et(e.onFocusOutside,(e=>e.preventDefault()),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)}))})),UV=v.forwardRef(((e,t)=>{const n=np(vs,e.__scopeMenu);return v.createElement(b$,Te({},e,{ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)}))})),b$=v.forwardRef(((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:i,disableOutsidePointerEvents:s,onEntryFocus:u,onEscapeKeyDown:l,onPointerDownOutside:c,onFocusOutside:d,onInteractOutside:f,onDismiss:p,disableOutsideScroll:m,...h}=e,g=np(vs,n),y=Bv(vs,n),b=fN(n),w=pN(n),x=NV(n),[_,E]=v.useState(null),S=v.useRef(null),I=Vt(t,S,g.onContentChange),A=v.useRef(0),k=v.useRef(""),C=v.useRef(0),T=v.useRef(null),R=v.useRef("right"),P=v.useRef(0),O=m?xy:v.Fragment,N=m?{as:qf,allowPinchZoom:!0}:void 0;v.useEffect((()=>()=>window.clearTimeout(A.current)),[]),SE();const M=v.useCallback((e=>{var t,n;return R.current===(null===(t=T.current)||void 0===t?void 0:t.side)&&sU(e,null===(n=T.current)||void 0===n?void 0:n.area)}),[]);return v.createElement(jV,{scope:n,searchRef:k,onItemEnter:v.useCallback((e=>{M(e)&&e.preventDefault()}),[M]),onItemLeave:v.useCallback((e=>{var t;M(e)||(null===(t=S.current)||void 0===t||t.focus(),E(null))}),[M]),onTriggerLeave:v.useCallback((e=>{M(e)&&e.preventDefault()}),[M]),pointerGraceTimerRef:C,onPointerGraceIntentChange:v.useCallback((e=>{T.current=e}),[])},v.createElement(O,N,v.createElement(xE,{asChild:!0,trapped:o,onMountAutoFocus:et(a,(e=>{var t;e.preventDefault(),null===(t=S.current)||void 0===t||t.focus()})),onUnmountAutoFocus:i},v.createElement(wy,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:c,onFocusOutside:d,onInteractOutside:f,onDismiss:p},v.createElement(g$,Te({asChild:!0},w,{dir:y.dir,orientation:"vertical",loop:r,currentTabStopId:_,onCurrentTabStopIdChange:E,onEntryFocus:et(u,(e=>{y.isUsingKeyboardRef.current||e.preventDefault()}))}),v.createElement(h$,Te({role:"menu","aria-orientation":"vertical","data-state":bN(g.open),"data-radix-menu-content":"",dir:y.dir},b,h,{ref:I,style:{outline:"none",...h.style},onKeyDown:et(h.onKeyDown,(e=>{const t=e.target.closest("[data-radix-menu-content]")===e.currentTarget,n=e.ctrlKey||e.altKey||e.metaKey,r=1===e.key.length;t&&("Tab"===e.key&&e.preventDefault(),!n&&r&&(e=>{var t,n;const r=k.current+e,o=x().filter((e=>!e.disabled)),a=document.activeElement,i=null===(t=o.find((e=>e.ref.current===a)))||void 0===t?void 0:t.textValue,s=iU(o.map((e=>e.textValue)),r,i),u=null===(n=o.find((e=>e.textValue===s)))||void 0===n?void 0:n.ref.current;(function e(t){k.current=t,window.clearTimeout(A.current),""!==t&&(A.current=window.setTimeout((()=>e("")),1e3))})(r),u&&setTimeout((()=>u.focus()))})(e.key));const o=S.current;if(e.target!==o||!AV.includes(e.key))return;e.preventDefault();const a=x().filter((e=>!e.disabled)).map((e=>e.ref.current));cN.includes(e.key)&&a.reverse(),rU(a)})),onBlur:et(e.onBlur,(e=>{e.currentTarget.contains(e.target)||(window.clearTimeout(A.current),k.current="")})),onPointerMove:et(e.onPointerMove,_v((e=>{const t=e.target,n=P.current!==e.clientX;if(e.currentTarget.contains(t)&&n){const t=e.clientX>P.current?"right":"left";R.current=t,P.current=e.clientX}})))})))))))})),WV=v.forwardRef(((e,t)=>{const{__scopeMenu:n,...r}=e;return v.createElement(ft.div,Te({},r,{ref:t}))})),GS="MenuItem",VT="menu.itemSelect",_$=v.forwardRef(((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,a=v.useRef(null),i=Bv(GS,e.__scopeMenu),s=w$(GS,e.__scopeMenu),u=Vt(t,a),l=v.useRef(!1);return v.createElement(vN,Te({},o,{ref:u,disabled:n,onClick:et(e.onClick,(()=>{const e=a.current;if(!n&&e){const t=new CustomEvent(VT,{bubbles:!0,cancelable:!0});e.addEventListener(VT,(e=>null==r?void 0:r(e)),{once:!0}),vA(e,t),t.defaultPrevented?l.current=!1:i.onClose()}})),onPointerDown:t=>{var n;null===(n=e.onPointerDown)||void 0===n||n.call(e,t),l.current=!0},onPointerUp:et(e.onPointerUp,(e=>{var t;l.current||null===(t=e.currentTarget)||void 0===t||t.click()})),onKeyDown:et(e.onKeyDown,(e=>{const t=""!==s.searchRef.current;n||t&&" "===e.key||qS.includes(e.key)&&(e.currentTarget.click(),e.preventDefault())}))}))})),vN=v.forwardRef(((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...a}=e,i=w$(GS,n),s=pN(n),u=v.useRef(null),l=Vt(t,u),[c,d]=v.useState(!1),[f,p]=v.useState("");return v.useEffect((()=>{const e=u.current;var t;e&&p((null!==(t=e.textContent)&&void 0!==t?t:"").trim())}),[a.children]),v.createElement(bv.ItemSlot,{scope:n,disabled:r,textValue:o??f},v.createElement(y$,Te({asChild:!0},s,{focusable:!r}),v.createElement(ft.div,Te({role:"menuitem","data-highlighted":c?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0},a,{ref:l,onPointerMove:et(e.onPointerMove,_v((e=>{r?i.onItemLeave(e):(i.onItemEnter(e),e.defaultPrevented||e.currentTarget.focus())}))),onPointerLeave:et(e.onPointerLeave,_v((e=>i.onItemLeave(e)))),onFocus:et(e.onFocus,(()=>d(!0))),onBlur:et(e.onBlur,(()=>d(!1)))}))))})),qV=v.forwardRef(((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return v.createElement(yN,{scope:e.__scopeMenu,checked:n},v.createElement(_$,Te({role:"menuitemcheckbox","aria-checked":ry(n)?"mixed":n},o,{ref:t,"data-state":x$(n),onSelect:et(o.onSelect,(()=>null==r?void 0:r(!!ry(n)||!n)),{checkForDefaultPrevented:!1})})))})),GV="MenuRadioGroup",[YJ,HV]=tp(GV,{value:void 0,onValueChange:()=>{}}),KV="MenuRadioItem",YV=v.forwardRef(((e,t)=>{const{value:n,...r}=e,o=HV(KV,e.__scopeMenu),a=n===o.value;return v.createElement(yN,{scope:e.__scopeMenu,checked:a},v.createElement(_$,Te({role:"menuitemradio","aria-checked":a},r,{ref:t,"data-state":x$(a),onSelect:et(r.onSelect,(()=>{var e;return null===(e=o.onValueChange)||void 0===e?void 0:e.call(o,n)}),{checkForDefaultPrevented:!1})})))})),gN="MenuItemIndicator",[yN,QV]=tp(gN,{checked:!1}),XV=v.forwardRef(((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,a=QV(gN,n);return v.createElement(ea,{present:r||ry(a.checked)||!0===a.checked},v.createElement(ft.span,Te({},o,{ref:t,"data-state":x$(a.checked)})))})),JV=v.forwardRef(((e,t)=>{const{__scopeMenu:n,...r}=e;return v.createElement(ft.div,Te({role:"separator","aria-orientation":"horizontal"},r,{ref:t}))})),ZV="MenuSub",[QJ,wN]=tp(ZV),Ag="MenuSubTrigger",eU=v.forwardRef(((e,t)=>{const n=np(Ag,e.__scopeMenu),r=Bv(Ag,e.__scopeMenu),o=wN(Ag,e.__scopeMenu),a=w$(Ag,e.__scopeMenu),i=v.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:u}=a,l={__scopeMenu:e.__scopeMenu},c=v.useCallback((()=>{i.current&&window.clearTimeout(i.current),i.current=null}),[]);return v.useEffect((()=>c),[c]),v.useEffect((()=>{const e=s.current;return()=>{window.clearTimeout(e),u(null)}}),[s,u]),v.createElement(LV,Te({asChild:!0},l),v.createElement(vN,Te({id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":bN(n.open)},e,{ref:bE(t,o.onTriggerChange),onClick:t=>{var r;null===(r=e.onClick)||void 0===r||r.call(e,t),!e.disabled&&!t.defaultPrevented&&(t.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:et(e.onPointerMove,_v((t=>{a.onItemEnter(t),!t.defaultPrevented&&!e.disabled&&!n.open&&!i.current&&(a.onPointerGraceIntentChange(null),i.current=window.setTimeout((()=>{n.onOpenChange(!0),c()}),100))}))),onPointerLeave:et(e.onPointerLeave,_v((e=>{var t;c();const r=null===(t=n.content)||void 0===t?void 0:t.getBoundingClientRect();if(r){var o;const t=null===(o=n.content)||void 0===o?void 0:o.dataset.side,i="right"===t,u=i?-5:5,l=r[i?"left":"right"],c=r[i?"right":"left"];a.onPointerGraceIntentChange({area:[{x:e.clientX+u,y:e.clientY},{x:l,y:r.top},{x:c,y:r.top},{x:c,y:r.bottom},{x:l,y:r.bottom}],side:t}),window.clearTimeout(s.current),s.current=window.setTimeout((()=>a.onPointerGraceIntentChange(null)),300)}else{if(a.onTriggerLeave(e),e.defaultPrevented)return;a.onPointerGraceIntentChange(null)}}))),onKeyDown:et(e.onKeyDown,(t=>{const o=""!==a.searchRef.current;var i;e.disabled||o&&" "===t.key||!MV[r.dir].includes(t.key)||(n.onOpenChange(!0),null===(i=n.content)||void 0===i||i.focus(),t.preventDefault())}))})))})),tU="MenuSubContent",nU=v.forwardRef(((e,t)=>{const n=hN(vs,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=np(vs,e.__scopeMenu),i=Bv(vs,e.__scopeMenu),s=wN(tU,e.__scopeMenu),u=v.useRef(null),l=Vt(t,u);return v.createElement(bv.Provider,{scope:e.__scopeMenu},v.createElement(ea,{present:r||a.open},v.createElement(bv.Slot,{scope:e.__scopeMenu},v.createElement(b$,Te({id:s.contentId,"aria-labelledby":s.triggerId},o,{ref:l,align:"start",side:"rtl"===i.dir?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:e=>{var t;i.isUsingKeyboardRef.current&&(null===(t=u.current)||void 0===t||t.focus()),e.preventDefault()},onCloseAutoFocus:e=>e.preventDefault(),onFocusOutside:et(e.onFocusOutside,(e=>{e.target!==s.trigger&&a.onOpenChange(!1)})),onEscapeKeyDown:et(e.onEscapeKeyDown,(e=>{i.onClose(),e.preventDefault()})),onKeyDown:et(e.onKeyDown,(e=>{const t=e.currentTarget.contains(e.target),n=DV[i.dir].includes(e.key);var r;t&&n&&(a.onOpenChange(!1),null===(r=s.trigger)||void 0===r||r.focus(),e.preventDefault())}))})))))}));function bN(e){return e?"open":"closed"}function ry(e){return"indeterminate"===e}function x$(e){return ry(e)?"indeterminate":e?"checked":"unchecked"}function rU(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function oU(e,t){return e.map(((n,r)=>e[(t+r)%e.length]))}function iU(e,t,n){const r=t.length>1&&Array.from(t).every((e=>e===t[0]))?t[0]:t,o=n?e.indexOf(n):-1;let a=oU(e,Math.max(o,0));1===r.length&&(a=a.filter((e=>e!==n)));const i=a.find((e=>e.toLowerCase().startsWith(r.toLowerCase())));return i!==n?i:void 0}function aU(e,t){const{x:n,y:r}=e;let o=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){const i=t[e].x,s=t[e].y,u=t[a].x,l=t[a].y;s>r!=l>r&&n<(u-i)*(r-s)/(l-s)+i&&(o=!o)}return o}function sU(e,t){if(!t)return!1;return aU({x:e.clientX,y:e.clientY},t)}function _v(e){return t=>"mouse"===t.pointerType?e(t):void 0}const uU=BV,lU=zV,cU=WV,dU=_$,fU=qV,pU=YV,mU=XV,hU=JV,vU=eU,gU=nU,_N="DropdownMenu",[yU,XJ]=ni(_N,[dN]),wu=dN(),[JJ,wU]=yU(_N),bU=e=>{const{__scopeDropdownMenu:t,...n}=e,r=wu(t);return v.createElement(uU,Te({},r,n))},_U="DropdownMenuContent",xU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wU(_U,n),a=wu(n),i=v.useRef(!1);return v.createElement(lU,Te({id:o.contentId,"aria-labelledby":o.triggerId},a,r,{ref:t,onCloseAutoFocus:et(e.onCloseAutoFocus,(e=>{var t;i.current||null===(t=o.triggerRef.current)||void 0===t||t.focus(),i.current=!1,e.preventDefault()})),onInteractOutside:et(e.onInteractOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey,r=2===t.button||n;(!o.modal||r)&&(i.current=!0)})),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))})),SU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(cU,Te({},o,r,{ref:t}))})),EU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(dU,Te({},o,r,{ref:t}))})),$U=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(fU,Te({},o,r,{ref:t}))})),CU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(pU,Te({},o,r,{ref:t}))})),IU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(mU,Te({},o,r,{ref:t}))})),RU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(hU,Te({},o,r,{ref:t}))})),PU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(vU,Te({},o,r,{ref:t}))})),TU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(gU,Te({},o,r,{ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))})),OU=bU,xN=xU,SN=SU,EN=EU,$N=$U,CN=CU,AU=IU,S$=RU,IN=PU,RN=TU,MU=v.forwardRef((({className:e,inset:t,children:n,...r},o)=>G.jsxs(IN,{ref:o,className:we("flex cursor-default select-none items-center rounded-xs px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent",t&&"pl-8",e),...r,children:[n,G.jsx(aA,{className:"ml-auto h-4 w-4"})]})));MU.displayName=IN.displayName;const DU=v.forwardRef((({className:e,...t},n)=>G.jsx(RN,{ref:n,className:we("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...t})));DU.displayName=RN.displayName;const UT=e=>{e.preventDefault()},NU=v.forwardRef((({className:e,sideOffset:t=4,isPortal:n,...r},o)=>{const a=G.jsx(xN,{ref:o,sideOffset:t,onOpenAutoFocus:UT,onCloseAutoFocus:UT,className:we("z-[101] flex max-h-[var(--radix-dropdown-menu-content-available-height)] min-w-[8rem] flex-col gap-xxxs overflow-y-auto rounded-lg border border-gray-200 bg-white p-xxs text-popover-foreground ","shadow-[0px_0px_12px_0px_rgba(0,0,0,0.08)] ","data-[state=open]:animate-in data-[state=closed]:animate-out","data-[state=open]:fade-in data-[state=open]:slide-in-from-top-2","data-[state=closed]:fade-out data-[state=closed]:slide-out-to-top-2","data-[state=closed]:duration-150 data-[state=open]:duration-150","data-[state=closed]:[animation-timing-function:ease-in] data-[state=open]:[animation-timing-function:ease-out]",e),...r});return n?G.jsx(OU,{children:a}):a}));NU.displayName=xN.displayName;const kU=v.forwardRef((({className:e,inset:t,...n},r)=>G.jsx(EN,{ref:r,className:we("relative flex cursor-default select-none items-center gap-xxs rounded-m p-xxs text-base font-medium text-gray-900 outline-none transition-colors hover:bg-gray-100 data-[disabled]:pointer-events-none data-[disabled]:opacity-50",t&&"pl-xl",e),...n})));kU.displayName=EN.displayName;const LU=v.forwardRef((({className:e,children:t,checked:n,checkboxPosition:r="right",...o},a)=>{const i=G.jsx(JE,{size:"default",variant:"default",checked:n});return G.jsxs($N,{ref:a,className:we("relative flex cursor-default select-none items-center gap-xxs rounded-m p-xxs text-base font-medium text-gray-900"," outline-none transition-colors hover:bg-gray-100 focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:n,onSelect:e=>e.preventDefault(),...o,children:["left"===r&&i,G.jsx("div",{className:"flex flex-1 items-center gap-xxs",children:t}),"right"===r&&i]})}));LU.displayName=$N.displayName;const FU=v.forwardRef((({className:e,children:t,radioPosition:n="right",...r},o)=>{const a=G.jsx("div",{className:"flex h-xxs items-center justify-center",children:G.jsx(AU,{children:G.jsx(vE,{size:20})})});return G.jsxs(CN,{ref:o,className:we("relative flex cursor-default select-none items-center gap-xxs rounded-m p-xxs text-base font-medium text-gray-900"," outline-none transition-colors hover:bg-gray-100 focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),onSelect:e=>e.preventDefault(),...r,children:["left"===n&&a,G.jsx("div",{className:"flex flex-1 items-center gap-xxs",children:t}),"right"===n&&a]})}));FU.displayName=CN.displayName;const BU=v.forwardRef((({className:e,inset:t,...n},r)=>G.jsx(SN,{ref:r,className:we("text-sm font-semibold",t&&"pl-xl",e),...n})));BU.displayName=SN.displayName;const jU=v.forwardRef((({className:e,...t},n)=>G.jsx(S$,{ref:n,className:we("-mx-1 my-1 h-px bg-muted",e),...t})));jU.displayName=S$.displayName;const zU=Ue.createContext(null),VU=()=>Ue.useContext(zU),UU=v.forwardRef(((e,t)=>v.createElement(ft.label,Te({},e,{ref:t,onMouseDown:t=>{var n;null===(n=e.onMouseDown)||void 0===n||n.call(e,t),!t.defaultPrevented&&t.detail>1&&t.preventDefault()}})))),PN=UU,WU=gu("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),TN=v.forwardRef((({className:e,...t},n)=>G.jsx(PN,{ref:n,className:we(WU(),e),...t})));function WT(e,[t,n]){return Math.min(n,Math.max(t,e))}TN.displayName=PN.displayName;const ON=v.forwardRef(((e,t)=>v.createElement(ft.span,Te({},e,{ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}})))),qU=ON,GU=[" ","Enter","ArrowUp","ArrowDown"],HU=[" ","Enter"],qy="Select",[Gy,Hy,KU]=a$(qy),[Gm,ZJ]=ni(qy,[KU,Wm]),E$=Wm(),[YU,rp]=Gm(qy),[QU,XU]=Gm(qy),JU=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:a,value:i,defaultValue:s,onValueChange:u,dir:l,name:c,autoComplete:d,disabled:f,required:p}=e,m=E$(t),[h,g]=v.useState(null),[y,b]=v.useState(null),[w,x]=v.useState(!1),_=s$(l),[E=!1,S]=fd({prop:r,defaultProp:o,onChange:a}),[I,A]=fd({prop:i,defaultProp:s,onChange:u}),k=v.useRef(null),C=!h||!!h.closest("form"),[T,R]=v.useState(new Set),P=Array.from(T).map((e=>e.props.value)).join(";");return v.createElement(sN,m,v.createElement(YU,{required:p,scope:t,trigger:h,onTriggerChange:g,valueNode:y,onValueNodeChange:b,valueNodeHasChildren:w,onValueNodeHasChildrenChange:x,contentId:ad(),value:I,onValueChange:A,open:E,onOpenChange:S,dir:_,triggerPointerDownPosRef:k,disabled:f},v.createElement(Gy.Provider,{scope:t},v.createElement(QU,{scope:e.__scopeSelect,onNativeOptionAdd:v.useCallback((e=>{R((t=>new Set(t).add(e)))}),[]),onNativeOptionRemove:v.useCallback((e=>{R((t=>{const n=new Set(t);return n.delete(e),n}))}),[])},n)),C?v.createElement(kN,{key:P,"aria-hidden":!0,required:p,tabIndex:-1,name:c,autoComplete:d,value:I,onChange:e=>A(e.target.value),disabled:f},void 0===I?v.createElement("option",{value:""}):null,Array.from(T)):null))},ZU="SelectTrigger",eW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,a=E$(n),i=rp(ZU,n),s=i.disabled||r,u=Vt(t,i.onTriggerChange),l=Hy(n),[c,d,f]=LN((e=>{const t=l().filter((e=>!e.disabled)),n=t.find((e=>e.value===i.value)),r=FN(t,e,n);void 0!==r&&i.onValueChange(r.value)})),p=()=>{s||(i.onOpenChange(!0),f())};return v.createElement(m$,Te({asChild:!0},a),v.createElement(ft.button,Te({type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:s,"data-disabled":s?"":void 0,"data-placeholder":NN(i.value)?"":void 0},o,{ref:u,onClick:et(o.onClick,(e=>{e.currentTarget.focus()})),onPointerDown:et(o.onPointerDown,(e=>{const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),0===e.button&&!1===e.ctrlKey&&(p(),i.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)},e.preventDefault())})),onKeyDown:et(o.onKeyDown,(e=>{const t=""!==c.current;!(e.ctrlKey||e.altKey||e.metaKey)&&1===e.key.length&&d(e.key),(!t||" "!==e.key)&&GU.includes(e.key)&&(p(),e.preventDefault())}))})))})),tW="SelectValue",nW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:a,placeholder:i="",...s}=e,u=rp(tW,n),{onValueNodeHasChildrenChange:l}=u,c=void 0!==a,d=Vt(t,u.onValueNodeChange);return Vo((()=>{l(c)}),[l,c]),v.createElement(ft.span,Te({},s,{ref:d,style:{pointerEvents:"none"}}),NN(u.value)?v.createElement(v.Fragment,null,i):a)})),rW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return v.createElement(ft.span,Te({"aria-hidden":!0},o,{ref:t}),r||"▼")})),oW=e=>v.createElement(by,Te({asChild:!0},e)),km="SelectContent",iW=v.forwardRef(((e,t)=>{const n=rp(km,e.__scopeSelect),[r,o]=v.useState();if(Vo((()=>{o(new DocumentFragment)}),[]),!n.open){const t=r;return t?vu.createPortal(v.createElement(AN,{scope:e.__scopeSelect},v.createElement(Gy.Slot,{scope:e.__scopeSelect},v.createElement("div",null,e.children))),t):null}return v.createElement(aW,Te({},e,{ref:t}))})),bl=10,[AN,op]=Gm(km),aW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:a,onPointerDownOutside:i,side:s,sideOffset:u,align:l,alignOffset:c,arrowPadding:d,collisionBoundary:f,collisionPadding:p,sticky:m,hideWhenDetached:h,avoidCollisions:g,...y}=e,b=rp(km,n),[w,x]=v.useState(null),[_,E]=v.useState(null),S=Vt(t,(e=>x(e))),[I,A]=v.useState(null),[k,C]=v.useState(null),T=Hy(n),[R,P]=v.useState(!1),O=v.useRef(!1);v.useEffect((()=>{if(w)return Sy(w)}),[w]),SE();const N=v.useCallback((e=>{const[t,...n]=T().map((e=>e.ref.current)),[r]=n.slice(-1),o=document.activeElement;for(const n of e)if(n===o||(null==n||n.scrollIntoView({block:"nearest"}),n===t&&_&&(_.scrollTop=0),n===r&&_&&(_.scrollTop=_.scrollHeight),null==n||n.focus(),document.activeElement!==o))return}),[T,_]),M=v.useCallback((()=>N([I,w])),[N,I,w]);v.useEffect((()=>{R&&M()}),[R,M]);const{onOpenChange:j,triggerPointerDownPosRef:D}=b;v.useEffect((()=>{if(w){let e={x:0,y:0};const t=t=>{var n,r,o,a;e={x:Math.abs(Math.round(t.pageX)-(null!==(n=null===(r=D.current)||void 0===r?void 0:r.x)&&void 0!==n?n:0)),y:Math.abs(Math.round(t.pageY)-(null!==(o=null===(a=D.current)||void 0===a?void 0:a.y)&&void 0!==o?o:0))}},n=n=>{e.x<=10&&e.y<=10?n.preventDefault():w.contains(n.target)||j(!1),document.removeEventListener("pointermove",t),D.current=null};return null!==D.current&&(document.addEventListener("pointermove",t),document.addEventListener("pointerup",n,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerup",n,{capture:!0})}}}),[w,j,D]),v.useEffect((()=>{const e=()=>j(!1);return window.addEventListener("blur",e),window.addEventListener("resize",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("resize",e)}}),[j]);const[q,z]=LN((e=>{const t=T().filter((e=>!e.disabled)),n=t.find((e=>e.ref.current===document.activeElement)),r=FN(t,e,n);r&&setTimeout((()=>r.ref.current.focus()))})),L=v.useCallback(((e,t,n)=>{const r=!O.current&&!n;(void 0!==b.value&&b.value===t||r)&&(A(e),r&&(O.current=!0))}),[b.value]),$=v.useCallback((()=>null==w?void 0:w.focus()),[w]),V=v.useCallback(((e,t,n)=>{const r=!O.current&&!n;(void 0!==b.value&&b.value===t||r)&&C(e)}),[b.value]),B="popper"===r?qT:sW,F=B===qT?{side:s,sideOffset:u,align:l,alignOffset:c,arrowPadding:d,collisionBoundary:f,collisionPadding:p,sticky:m,hideWhenDetached:h,avoidCollisions:g}:{};return v.createElement(AN,{scope:n,content:w,viewport:_,onViewportChange:E,itemRefCallback:L,selectedItem:I,onItemLeave:$,itemTextRefCallback:V,focusSelectedItem:M,selectedItemText:k,position:r,isPositioned:R,searchRef:q},v.createElement(xy,{as:qf,allowPinchZoom:!0},v.createElement(xE,{asChild:!0,trapped:b.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:et(o,(e=>{var t;null===(t=b.trigger)||void 0===t||t.focus({preventScroll:!0}),e.preventDefault()}))},v.createElement(wy,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>b.onOpenChange(!1)},v.createElement(B,Te({role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:e=>e.preventDefault()},y,F,{onPlaced:()=>P(!0),ref:S,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:et(y.onKeyDown,(e=>{const t=e.ctrlKey||e.altKey||e.metaKey;if("Tab"===e.key&&e.preventDefault(),!t&&1===e.key.length&&z(e.key),["ArrowUp","ArrowDown","Home","End"].includes(e.key)){let t=T().filter((e=>!e.disabled)).map((e=>e.ref.current));if(["ArrowUp","End"].includes(e.key)&&(t=t.slice().reverse()),["ArrowUp","ArrowDown"].includes(e.key)){const n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout((()=>N(t))),e.preventDefault()}}))}))))))})),sW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,a=rp(km,n),i=op(km,n),[s,u]=v.useState(null),[l,c]=v.useState(null),d=Vt(t,(e=>c(e))),f=Hy(n),p=v.useRef(!1),m=v.useRef(!0),{viewport:h,selectedItem:g,selectedItemText:y,focusSelectedItem:b}=i,w=v.useCallback((()=>{if(a.trigger&&a.valueNode&&s&&l&&h&&g&&y){const e=a.trigger.getBoundingClientRect(),t=l.getBoundingClientRect(),n=a.valueNode.getBoundingClientRect(),o=y.getBoundingClientRect();if("rtl"!==a.dir){const r=o.left-t.left,a=n.left-r,i=e.left-a,u=e.width+i,l=Math.max(u,t.width),c=window.innerWidth-bl,d=WT(a,[bl,c-l]);s.style.minWidth=u+"px",s.style.left=d+"px"}else{const r=t.right-o.right,a=window.innerWidth-n.right-r,i=window.innerWidth-e.right-a,u=e.width+i,l=Math.max(u,t.width),c=window.innerWidth-bl,d=WT(a,[bl,c-l]);s.style.minWidth=u+"px",s.style.right=d+"px"}const i=f(),u=window.innerHeight-2*bl,c=h.scrollHeight,d=window.getComputedStyle(l),m=parseInt(d.borderTopWidth,10),v=parseInt(d.paddingTop,10),b=parseInt(d.borderBottomWidth,10),w=m+v+c+parseInt(d.paddingBottom,10)+b,x=Math.min(5*g.offsetHeight,w),_=window.getComputedStyle(h),E=parseInt(_.paddingTop,10),S=parseInt(_.paddingBottom,10),I=e.top+e.height/2-bl,A=u-I,k=g.offsetHeight/2,C=m+v+(g.offsetTop+k),T=w-C;if(C<=I){const e=g===i[i.length-1].ref.current;s.style.bottom="0px";const t=l.clientHeight-h.offsetTop-h.offsetHeight,n=C+Math.max(A,k+(e?S:0)+t+b);s.style.height=n+"px"}else{const e=g===i[0].ref.current;s.style.top="0px";const t=Math.max(I,m+h.offsetTop+(e?E:0)+k)+T;s.style.height=t+"px",h.scrollTop=C-I+h.offsetTop}s.style.margin=`${bl}px 0`,s.style.minHeight=x+"px",s.style.maxHeight=u+"px",null==r||r(),requestAnimationFrame((()=>p.current=!0))}}),[f,a.trigger,a.valueNode,s,l,h,g,y,a.dir,r]);Vo((()=>w()),[w]);const[x,_]=v.useState();Vo((()=>{l&&_(window.getComputedStyle(l).zIndex)}),[l]);const E=v.useCallback((e=>{e&&!0===m.current&&(w(),null==b||b(),m.current=!1)}),[w,b]);return v.createElement(uW,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:p,onScrollButtonChange:E},v.createElement("div",{ref:u,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:x}},v.createElement(ft.div,Te({},o,{ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}}))))})),qT=v.forwardRef(((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=bl,...a}=e,i=E$(n);return v.createElement(h$,Te({},i,a,{ref:t,align:r,collisionPadding:o,style:{boxSizing:"border-box",...a.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}}))})),[uW,$$]=Gm(km,{}),GT="SelectViewport",lW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,o=op(GT,n),a=$$(GT,n),i=Vt(t,o.onViewportChange),s=v.useRef(0);return v.createElement(v.Fragment,null,v.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"}}),v.createElement(Gy.Slot,{scope:n},v.createElement(ft.div,Te({"data-radix-select-viewport":"",role:"presentation"},r,{ref:i,style:{position:"relative",flex:1,overflow:"auto",...r.style},onScroll:et(r.onScroll,(e=>{const t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=a;if(null!=r&&r.current&&n){const e=Math.abs(s.current-t.scrollTop);if(e>0){const r=window.innerHeight-2*bl,o=parseFloat(n.style.minHeight),a=parseFloat(n.style.height),i=Math.max(o,a);if(i<r){const o=i+e,a=Math.min(r,o),s=o-a;n.style.height=a+"px","0px"===n.style.bottom&&(t.scrollTop=s>0?s:0,n.style.justifyContent="flex-end")}}}s.current=t.scrollTop}))}))))})),cW="SelectGroup",[dW,fW]=Gm(cW),pW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,o=ad();return v.createElement(dW,{scope:n,id:o},v.createElement(ft.div,Te({role:"group","aria-labelledby":o},r,{ref:t})))})),mW="SelectLabel",hW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,o=fW(mW,n);return v.createElement(ft.div,Te({id:o.id},r,{ref:t}))})),HS="SelectItem",[vW,MN]=Gm(HS),gW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:a,...i}=e,s=rp(HS,n),u=op(HS,n),l=s.value===r,[c,d]=v.useState(a??""),[f,p]=v.useState(!1),m=Vt(t,(e=>{var t;return null===(t=u.itemRefCallback)||void 0===t?void 0:t.call(u,e,r,o)})),h=ad(),g=()=>{o||(s.onValueChange(r),s.onOpenChange(!1))};if(""===r)throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return v.createElement(vW,{scope:n,value:r,disabled:o,textId:h,isSelected:l,onItemTextChange:v.useCallback((e=>{d((t=>{var n;return t||(null!==(n=null==e?void 0:e.textContent)&&void 0!==n?n:"").trim()}))}),[])},v.createElement(Gy.ItemSlot,{scope:n,value:r,disabled:o,textValue:c},v.createElement(ft.div,Te({role:"option","aria-labelledby":h,"data-highlighted":f?"":void 0,"aria-selected":l&&f,"data-state":l?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1},i,{ref:m,onFocus:et(i.onFocus,(()=>p(!0))),onBlur:et(i.onBlur,(()=>p(!1))),onPointerUp:et(i.onPointerUp,g),onPointerMove:et(i.onPointerMove,(e=>{var t;o?null===(t=u.onItemLeave)||void 0===t||t.call(u):e.currentTarget.focus({preventScroll:!0})})),onPointerLeave:et(i.onPointerLeave,(e=>{var t;e.currentTarget===document.activeElement&&(null===(t=u.onItemLeave)||void 0===t||t.call(u))})),onKeyDown:et(i.onKeyDown,(e=>{var t;""!==(null===(t=u.searchRef)||void 0===t?void 0:t.current)&&" "===e.key||(HU.includes(e.key)&&g()," "===e.key&&e.preventDefault())}))}))))})),Mg="SelectItemText",yW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,className:r,style:o,...a}=e,i=rp(Mg,n),s=op(Mg,n),u=MN(Mg,n),l=XU(Mg,n),[c,d]=v.useState(null),f=Vt(t,(e=>d(e)),u.onItemTextChange,(e=>{var t;return null===(t=s.itemTextRefCallback)||void 0===t?void 0:t.call(s,e,u.value,u.disabled)})),p=null==c?void 0:c.textContent,m=v.useMemo((()=>v.createElement("option",{key:u.value,value:u.value,disabled:u.disabled},p)),[u.disabled,u.value,p]),{onNativeOptionAdd:h,onNativeOptionRemove:g}=l;return Vo((()=>(h(m),()=>g(m))),[h,g,m]),v.createElement(v.Fragment,null,v.createElement(ft.span,Te({id:u.textId},a,{ref:f})),u.isSelected&&i.valueNode&&!i.valueNodeHasChildren?vu.createPortal(a.children,i.valueNode):null)})),wW="SelectItemIndicator",bW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e;return MN(wW,n).isSelected?v.createElement(ft.span,Te({"aria-hidden":!0},r,{ref:t})):null})),HT="SelectScrollUpButton",_W=v.forwardRef(((e,t)=>{const n=op(HT,e.__scopeSelect),r=$$(HT,e.__scopeSelect),[o,a]=v.useState(!1),i=Vt(t,r.onScrollButtonChange);return Vo((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollTop>0;a(e)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),o?v.createElement(DN,Te({},e,{ref:i,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop-t.offsetHeight)}})):null})),KT="SelectScrollDownButton",xW=v.forwardRef(((e,t)=>{const n=op(KT,e.__scopeSelect),r=$$(KT,e.__scopeSelect),[o,a]=v.useState(!1),i=Vt(t,r.onScrollButtonChange);return Vo((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollHeight-t.clientHeight,n=Math.ceil(t.scrollTop)<e;a(n)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),o?v.createElement(DN,Te({},e,{ref:i,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop+t.offsetHeight)}})):null})),DN=v.forwardRef(((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,a=op("SelectScrollButton",n),i=v.useRef(null),s=Hy(n),u=v.useCallback((()=>{null!==i.current&&(window.clearInterval(i.current),i.current=null)}),[]);return v.useEffect((()=>()=>u()),[u]),Vo((()=>{var e;const t=s().find((e=>e.ref.current===document.activeElement));null==t||null===(e=t.ref.current)||void 0===e||e.scrollIntoView({block:"nearest"})}),[s]),v.createElement(ft.div,Te({"aria-hidden":!0},o,{ref:t,style:{flexShrink:0,...o.style},onPointerDown:et(o.onPointerDown,(()=>{null===i.current&&(i.current=window.setInterval(r,50))})),onPointerMove:et(o.onPointerMove,(()=>{var e;null===(e=a.onItemLeave)||void 0===e||e.call(a),null===i.current&&(i.current=window.setInterval(r,50))})),onPointerLeave:et(o.onPointerLeave,(()=>{u()}))}))})),SW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e;return v.createElement(ft.div,Te({"aria-hidden":!0},r,{ref:t}))}));function NN(e){return""===e||void 0===e}const kN=v.forwardRef(((e,t)=>{const{value:n,...r}=e,o=v.useRef(null),a=Vt(t,o),i=ky(n);return v.useEffect((()=>{const e=o.current,t=window.HTMLSelectElement.prototype,r=Object.getOwnPropertyDescriptor(t,"value").set;if(i!==n&&r){const t=new Event("change",{bubbles:!0});r.call(e,n),e.dispatchEvent(t)}}),[i,n]),v.createElement(ON,{asChild:!0},v.createElement("select",Te({},r,{ref:a,defaultValue:n})))}));function LN(e){const t=ws(e),n=v.useRef(""),r=v.useRef(0),o=v.useCallback((e=>{const o=n.current+e;t(o),function e(t){n.current=t,window.clearTimeout(r.current),""!==t&&(r.current=window.setTimeout((()=>e("")),1e3))}(o)}),[t]),a=v.useCallback((()=>{n.current="",window.clearTimeout(r.current)}),[]);return v.useEffect((()=>()=>window.clearTimeout(r.current)),[]),[n,o,a]}function FN(e,t,n){const r=t.length>1&&Array.from(t).every((e=>e===t[0]))?t[0]:t,o=n?e.indexOf(n):-1;let a=EW(e,Math.max(o,0));1===r.length&&(a=a.filter((e=>e!==n)));const i=a.find((e=>e.textValue.toLowerCase().startsWith(r.toLowerCase())));return i!==n?i:void 0}function EW(e,t){return e.map(((n,r)=>e[(t+r)%e.length]))}kN.displayName="BubbleSelect";const BN=JU,C$=eW,jN=nW,$W=rW,CW=oW,zN=iW,IW=lW,VN=pW,UN=hW,WN=gW,RW=yW,PW=bW,qN=_W,GN=xW,HN=SW,TW=BN,I$=v.forwardRef((({...e},t)=>G.jsx(TW,{ref:t,...e})));I$.displayName=BN.displayName;const KN=v.forwardRef(((e,t)=>G.jsx(VN,{ref:t,...e})));KN.displayName=VN.displayName;const YN=v.forwardRef(((e,t)=>G.jsx(jN,{ref:t,...e})));YN.displayName=jN.displayName;const R$=v.forwardRef((({className:e,children:t,caption:n,error:r,icon:o,renderCaret:a,...i},s)=>{const u=a?a():G.jsx(oA,{size:20,className:"transition-transform duration-200 group-data-[state=open]/select:rotate-180"});return G.jsxs("div",{className:"w-full",children:[G.jsxs(C$,{ref:s,className:we("group/select flex h-l w-full items-center justify-between rounded-m border bg-background p-xxs text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus-visible:ring-gray-700 focus-visible:ring-offset-1 disabled:cursor-not-allowed disabled:opacity-50",r?"border-red-500":"border-input",e),...i,children:[G.jsxs("div",{className:we("flex w-full flex-1 items-center gap-xxs",{"max-w-[calc(100%-20px)]":u}),children:[o&&G.jsx("span",{className:we("text-muted-foreground",{"text-red-dark":r}),children:o}),t]}),G.jsx($W,{asChild:!0,children:u})]}),n||r?r?G.jsxs("div",{className:"mt-xxs flex items-center gap-xxxs text-sm text-red-600",children:[G.jsx(gE,{size:16}),r]}):G.jsxs("div",{className:"mt-xxs flex items-center gap-xxxs text-sm text-muted-foreground",children:[G.jsx(V5,{size:16}),n]}):null]})}));R$.displayName="SelectTriggerWrapper";const QN=v.forwardRef((({className:e,children:t,caption:n,error:r,icon:o,...a},i)=>G.jsx(R$,{ref:i,className:we("[&>span]:line-clamp-1 [&>span]:text-left",e),caption:n,error:r,icon:o,...a,children:t})));QN.displayName=C$.displayName;const P$=v.forwardRef((({className:e,children:t,position:n="popper",...r},o)=>{const a=v.useMemo((()=>{const e=t=>{var n,r;if(!t)return!1;if(Array.isArray(t))return t.some(e);if(v.isValidElement(t)){const o=null==(n=t.type)?void 0:n.displayName;return"SelectActions"===o||"SelectFooter"===o||e(null==(r=t.props)?void 0:r.children)}return!1};return e(t)}),[t]);return G.jsx(CW,{children:G.jsx(zN,{ref:o,className:we("z-[101] flex max-h-[var(--radix-select-content-available-height)] min-w-[8rem] flex-col rounded-lg border border-gray-200 bg-white text-popover-foreground","shadow-[0px_0px_12px_0px_rgba(0,0,0,0.08)]","data-[state=open]:animate-in data-[state=closed]:animate-out ","data-[state=open]:fade-in data-[state=open]:slide-in-from-top-2 ","data-[state=closed]:fade-out data-[state=closed]:slide-out-to-top-2 ","data-[state=closed]:duration-150 data-[state=open]:duration-150 ","data-[state=closed]:[animation-timing-function:ease-in] data-[state=open]:[animation-timing-function:ease-out]","popper"===n&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:n,...r,children:G.jsx(IW,{className:we("flex flex-col gap-xxxs overflow-y-auto px-xxs",{"py-xxs":!a},"popper"===n&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t})})})}));P$.displayName=zN.displayName;const XN=v.forwardRef((({className:e,...t},n)=>G.jsx(UN,{ref:n,className:we("text-sm font-medium text-gray-900",e),...t})));XN.displayName=UN.displayName;const JN=v.forwardRef((({className:e,showCheck:t=!0,checkPosition:n="right",children:r,...o},a)=>{const i=G.jsx(PW,{children:G.jsx(vE,{size:20})});return G.jsxs(WN,{ref:a,className:we("relative flex cursor-default select-none items-center gap-xxs rounded-m p-xxs","text-base font-medium text-gray-900 outline-none transition-colors hover:bg-gray-100","focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...o,children:[t&&"left"===n&&i,G.jsx("div",{className:"flex flex-1 items-center gap-xxs",children:G.jsx(RW,{children:r})}),t&&"right"===n&&i]})}));JN.displayName=WN.displayName;const ZN=v.forwardRef((({className:e,...t},n)=>G.jsx(HN,{ref:n,className:we("-mx-1 my-1 h-px bg-gray-200",e),...t})));ZN.displayName=HN.displayName;const OW=({selectedValues:e=[],onRemoveValue:t})=>{const n=v.useRef(null),[r,o]=v.useState(e.length);return v.useLayoutEffect((()=>{if(!n.current||0===e.length)return void o(e.length);const r=n.current.offsetWidth-60,a=document.createElement("div");Object.assign(a.style,{position:"absolute",visibility:"hidden",whiteSpace:"nowrap",display:"flex",gap:"4px",top:"-9999px",left:"-9999px"}),document.body.appendChild(a);let i=0,s=0;for(const n of e){const e=document.createElement("div");e.className="gap-xxxs p-xxs flex cursor-pointer items-center rounded-sm bg-gray-100 text-sm font-medium text-gray-900";const o=document.createElement("span");if(o.textContent="string"==typeof n?n:n.value,e.appendChild(o),"string"!=typeof n&&n.avatar){const t=document.createElement("div");t.className="w-6 h-6 rounded-full bg-gray-300 flex-shrink-0",e.insertBefore(t,o)}if(t){const t=document.createElement("button");t.innerHTML="×",t.className="ml-1 rounded-full outline-none",e.appendChild(t)}a.appendChild(e);const u=e.offsetWidth+4;if(!(i+u<=r))break;i+=u,s++}document.body.removeChild(a),o(Math.max(1,s))}),[e,t]),{containerRef:n,visibleCount:r}},ek=({hiddenCount:e,selectedValues:t=[],onRemoveValue:n})=>{const r=e=>{e.stopPropagation(),e.preventDefault()};return G.jsx("div",{onPointerDown:r,onMouseDown:r,onClick:r,children:G.jsxs(I$,{name:"hidden-chips-counter",children:[G.jsx(C$,{asChild:!0,children:G.jsx("div",{children:G.jsx(UM,{text:`+${e}`})})}),G.jsx(P$,{align:"end",className:"max-h-[250px] w-screen max-w-[300px] gap-xxxs overflow-y-auto",children:t.map((e=>{const t="string"==typeof e?e:e.value;return G.jsxs("div",{className:"flex justify-between p-xxs",onClick:e=>e.stopPropagation(),children:[G.jsx("span",{children:t}),G.jsx(gy,{size:16,className:"cursor-pointer",onClick:()=>null==n?void 0:n(t)})]},t)}))})]})})};ek.displayName="SelectHiddenChipsCounter";const AW=v.forwardRef(((e,t)=>{const{className:n,selectedValues:r=[],placeholder:o,onRemoveValue:a,icon:i,caption:s,error:u,...l}=e,{containerRef:c,visibleCount:d}=OW({selectedValues:r,onRemoveValue:a}),f=r.length-d;return G.jsx(R$,{ref:t,className:n,caption:s,error:u,icon:i,...l,children:G.jsx("div",{ref:c,className:"flex w-full flex-1 flex-nowrap overflow-hidden",children:0===r.length?G.jsx("span",{children:o||"Select options..."}):G.jsxs(AF,{children:[r.slice(0,d).map((e=>{const t="string"==typeof e?e:e.value;return G.jsx(UM,{avatarSrc:"string"==typeof e?void 0:e.avatar,text:t,onRemove:()=>null==a?void 0:a(t)},t)})),f>0&&G.jsx(ek,{hiddenCount:f,onRemoveValue:a,selectedValues:r})]})})})}));AW.displayName="SelectMultiTrigger";const MW=v.forwardRef((({value:e,isSelected:t=!1,isLoading:n=!1,checkboxPosition:r="right",onSelect:o,className:a,children:i,...s},u)=>{const l=n?G.jsx(sA,{size:24,className:"flex-shrink-0 animate-spin text-blue_100"}):G.jsx(JE,{size:"default",variant:"default",checked:t}),c=()=>{null==o||o(e)};return G.jsxs("div",{ref:u,className:we("relative flex cursor-pointer select-none items-center gap-xxs rounded-m","p-xxs text-base font-medium text-gray-900 outline-none transition-colors hover:bg-gray-100","focus:bg-accent focus:text-accent-foreground",{"pointer-events-none":n},a),onClick:c,role:"button",tabIndex:0,onKeyDown:e=>{("Enter"===e.key||" "===e.key)&&(e.preventDefault(),c())},...s,children:["left"===r&&l,G.jsx("div",{className:"flex flex-1 items-center gap-xxs",children:i}),"right"===r&&l]})}));MW.displayName="SelectCheckboxItem";const DW=v.forwardRef((({className:e,...t},n)=>G.jsx(qN,{ref:n,className:we("flex cursor-default items-center justify-center py-xxs",e),...t,children:G.jsx(k5,{size:16})})));DW.displayName=qN.displayName;const NW=v.forwardRef((({className:e,...t},n)=>G.jsx(GN,{ref:n,className:we("flex cursor-default items-center justify-center p-xxs",e),...t,children:G.jsx(oA,{size:16})})));NW.displayName=GN.displayName;const kW=v.forwardRef((({className:e,children:t,...n},r)=>G.jsx("div",{ref:r,className:we("sticky top-0 z-20 bg-white p-xxs",e),...n,children:t})));kW.displayName="SelectActions";const LW=v.forwardRef((({className:e,children:t,...n},r)=>G.jsx("div",{ref:r,className:we("sticky bottom-0 z-20 bg-white p-xxs",e),...n,children:t})));LW.displayName="SelectFooter";const FW=v.createContext({}),bd=()=>{const e=v.useContext(FW),t=v.useContext(tk),n=VU();e||console.error("useFormContext must be used within a FormProvider");const{getFieldState:r,formState:o}=n,a=r(e.name,o);if(!e)throw new Error("useFormField should be used within <FormField>");const{id:i}=t;return{id:i,name:e.name,formItemId:`${i}-form-item`,formDescriptionId:`${i}-form-item-description`,formMessageId:`${i}-form-item-message`,...a}},tk=v.createContext({}),BW=v.forwardRef((({className:e,...t},n)=>{const r=v.useId();return G.jsx(tk.Provider,{value:{id:r},children:G.jsx("div",{ref:n,className:we("mt-[8px]",e),...t})})}));BW.displayName="FormItem";const jW=v.forwardRef((({className:e,isRequired:t,...n},r)=>{const{formItemId:o}=bd();return G.jsxs(TN,{ref:r,className:we("mb-2 text-sm font-medium",e),htmlFor:o,...n,children:[t&&"*",n.children]})}));jW.displayName="FormLabel";const zW=v.forwardRef((({...e},t)=>{const{error:n,formItemId:r,formDescriptionId:o,formMessageId:a}=bd();return G.jsx(yd,{ref:t,id:r,"aria-describedby":n?`${o} ${a}`:`${o}`,"aria-invalid":!!n,...e})}));zW.displayName="FormControl";const VW=v.forwardRef((({className:e,...t},n)=>{const{formDescriptionId:r}=bd();return G.jsx("p",{ref:n,id:r,className:we("text-sm text-muted-foreground",e),...t})}));VW.displayName="FormDescription";const UW=v.forwardRef((({className:e,children:t,...n},r)=>{const{error:o,formMessageId:a}=bd(),i=o?String(null==o?void 0:o.message):t;return i?G.jsxs("p",{ref:r,id:a,className:we("flex items-start gap-1 pt-xxs text-sm text-red-dark",e),...n,children:[G.jsx(gE,{size:16,className:"text-red-dark"})," ",i]}):null}));UW.displayName="FormMessage";const WW=v.forwardRef((({...e},t)=>{const{name:n}=bd();return G.jsx(I$,{ref:t,name:n,...e})}));WW.displayName="FormSelect";const qW=v.forwardRef((({className:e,children:t,...n},r)=>{const{formItemId:o}=bd();return G.jsx(QN,{ref:r,id:o,className:e,...n,children:t})}));qW.displayName="FormSelectTrigger";const GW=v.forwardRef(((e,t)=>G.jsx(P$,{ref:t,...e})));GW.displayName="FormSelectContent";const HW=v.forwardRef(((e,t)=>G.jsx(JN,{ref:t,...e})));HW.displayName="FormSelectItem";const KW=v.forwardRef(((e,t)=>G.jsx(KN,{ref:t,...e})));KW.displayName="FormSelectGroup";const YW=v.forwardRef(((e,t)=>G.jsx(XN,{ref:t,...e})));YW.displayName="FormSelectLabel";const QW=v.forwardRef(((e,t)=>G.jsx(ZN,{ref:t,...e})));QW.displayName="FormSelectSeparator";const XW=v.forwardRef(((e,t)=>G.jsx(YN,{ref:t,...e})));function jf(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function nk(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>v.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return v.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const o=v.createContext(r),a=n.length;function i(t){const{scope:n,children:r,...i}=t,s=(null==n?void 0:n[e][a])||o,u=v.useMemo((()=>i),Object.values(i));return v.createElement(s.Provider,{value:u},r)}return n=[...n,r],i.displayName=t+"Provider",[i,function(n,i){const s=(null==i?void 0:i[e][a])||o,u=v.useContext(s);if(u)return u;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},JW(r,...t)]}function JW(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return v.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}function Ky(e){const t=v.useRef(e);return v.useEffect((()=>{t.current=e})),v.useMemo((()=>(...e)=>{var n;return null===(n=t.current)||void 0===n?void 0:n.call(t,...e)}),[])}function ZW(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function eq(...e){return t=>e.forEach((e=>ZW(e,t)))}function tq(...e){return v.useCallback(eq(...e),e)}function ip(e){return e.split("-")[0]}function jv(e){return e.split("-")[1]}function Hm(e){return["top","bottom"].includes(ip(e))?"x":"y"}function T$(e){return"y"===e?"height":"width"}function YT(e,t,n){let{reference:r,floating:o}=e;const a=r.x+r.width/2-o.width/2,i=r.y+r.height/2-o.height/2,s=Hm(t),u=T$(s),l=r[u]/2-o[u]/2,c="x"===s;let d;switch(ip(t)){case"top":d={x:a,y:r.y-o.height};break;case"bottom":d={x:a,y:r.y+r.height};break;case"right":d={x:r.x+r.width,y:i};break;case"left":d={x:r.x-o.width,y:i};break;default:d={x:r.x,y:r.y}}switch(jv(t)){case"start":d[s]-=l*(n&&c?-1:1);break;case"end":d[s]+=l*(n&&c?-1:1)}return d}XW.displayName="FormSelectValue";const nq=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:i}=n,s=await(null==i.isRTL?void 0:i.isRTL(t));let u=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:l,y:c}=YT(u,r,s),d=r,f={},p=0;for(let n=0;n<a.length;n++){const{name:m,fn:v}=a[n],{x:h,y:g,data:y,reset:b}=await v({x:l,y:c,initialPlacement:r,placement:d,strategy:o,middlewareData:f,rects:u,platform:i,elements:{reference:e,floating:t}});l=h??l,c=g??c,f={...f,[m]:{...f[m],...y}},b&&p<=50&&(p++,"object"==typeof b&&(b.placement&&(d=b.placement),b.rects&&(u=!0===b.rects?await i.getElementRects({reference:e,floating:t,strategy:o}):b.rects),({x:l,y:c}=YT(u,d,s))),n=-1)}return{x:l,y:c,placement:d,strategy:o,middlewareData:f}};function rk(e){return"number"!=typeof e?(t=e,{top:0,right:0,bottom:0,left:0,...t}):{top:e,right:e,bottom:e,left:e};var t}function oy(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}async function xv(e,t){var n;void 0===t&&(t={});const{x:r,y:o,platform:a,rects:i,elements:s,strategy:u}=e,{boundary:l="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=t,m=rk(p),v=s[f?"floating"===d?"reference":"floating":d],h=oy(await a.getClippingRect({element:null==(n=await(null==a.isElement?void 0:a.isElement(v)))||n?v:v.contextElement||await(null==a.getDocumentElement?void 0:a.getDocumentElement(s.floating)),boundary:l,rootBoundary:c,strategy:u})),g=oy(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({rect:"floating"===d?{...i.floating,x:r,y:o}:i.reference,offsetParent:await(null==a.getOffsetParent?void 0:a.getOffsetParent(s.floating)),strategy:u}):i[d]);return{top:h.top-g.top+m.top,bottom:g.bottom-h.bottom+m.bottom,left:h.left-g.left+m.left,right:g.right-h.right+m.right}}const rq=Math.min,Df=Math.max;function KS(e,t,n){return Df(e,rq(t,n))}const QT=e=>({name:"arrow",options:e,async fn(t){const{element:n,padding:r=0}=e??{},{x:o,y:a,placement:i,rects:s,platform:u}=t;if(null==n)return{};const l=rk(r),c={x:o,y:a},d=Hm(i),f=jv(i),p=T$(d),m=await u.getDimensions(n),v="y"===d?"top":"left",h="y"===d?"bottom":"right",g=s.reference[p]+s.reference[d]-c[d]-s.floating[p],y=c[d]-s.reference[d],b=await(null==u.getOffsetParent?void 0:u.getOffsetParent(n));let w=b?"y"===d?b.clientHeight||0:b.clientWidth||0:0;0===w&&(w=s.floating[p]);const x=g/2-y/2,_=l[v],E=w-m[p]-l[h],S=w/2-m[p]/2+x,I=KS(_,S,E),A=("start"===f?l[v]:l[h])>0&&S!==I&&s.reference[p]<=s.floating[p];return{[d]:c[d]-(A?S<_?_-S:E-S:0),data:{[d]:I,centerOffset:S-I}}}}),oq={left:"right",right:"left",bottom:"top",top:"bottom"};function iy(e){return e.replace(/left|right|bottom|top/g,(e=>oq[e]))}function iq(e,t,n){void 0===n&&(n=!1);const r=jv(e),o=Hm(e),a=T$(o);let i="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[a]>t.floating[a]&&(i=iy(i)),{main:i,cross:iy(i)}}const aq={start:"end",end:"start"};function XT(e){return e.replace(/start|end/g,(e=>aq[e]))}const ok=["top","right","bottom","left"];ok.reduce(((e,t)=>e.concat(t,t+"-start",t+"-end")),[]);const sq=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:o,rects:a,initialPlacement:i,platform:s,elements:u}=t,{mainAxis:l=!0,crossAxis:c=!0,fallbackPlacements:d,fallbackStrategy:f="bestFit",flipAlignment:p=!0,...m}=e,v=ip(r),h=[i,...d||(v!==i&&p?function(e){const t=iy(e);return[XT(e),t,XT(t)]}(i):[iy(i)])],g=await xv(t,m),y=[];let b=(null==(n=o.flip)?void 0:n.overflows)||[];if(l&&y.push(g[v]),c){const{main:e,cross:t}=iq(r,a,await(null==s.isRTL?void 0:s.isRTL(u.floating)));y.push(g[e],g[t])}if(b=[...b,{placement:r,overflows:y}],!y.every((e=>e<=0))){var w,x;const e=(null!=(w=null==(x=o.flip)?void 0:x.index)?w:0)+1,t=h[e];if(t)return{data:{index:e,overflows:b},reset:{placement:t}};let n="bottom";switch(f){case"bestFit":{var _;const e=null==(_=b.map((e=>[e,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:_[0].placement;e&&(n=e);break}case"initialPlacement":n=i}if(r!==n)return{reset:{placement:n}}}return{}}}};function JT(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ZT(e){return ok.some((t=>e[t]>=0))}const uq=function(e){let{strategy:t="referenceHidden",...n}=void 0===e?{}:e;return{name:"hide",async fn(e){const{rects:r}=e;switch(t){case"referenceHidden":{const t=JT(await xv(e,{...n,elementContext:"reference"}),r.reference);return{data:{referenceHiddenOffsets:t,referenceHidden:ZT(t)}}}case"escaped":{const t=JT(await xv(e,{...n,altBoundary:!0}),r.floating);return{data:{escapedOffsets:t,escaped:ZT(t)}}}default:return{}}}}},lq=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,o=await async function(e,t){const{placement:n,platform:r,elements:o}=e,a=await(null==r.isRTL?void 0:r.isRTL(o.floating)),i=ip(n),s=jv(n),u="x"===Hm(n),l=["left","top"].includes(i)?-1:1,c=a&&u?-1:1,d="function"==typeof t?t(e):t;let{mainAxis:f,crossAxis:p,alignmentAxis:m}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...d};return s&&"number"==typeof m&&(p="end"===s?-1*m:m),u?{x:p*c,y:f*l}:{x:f*l,y:p*c}}(t,e);return{x:n+o.x,y:r+o.y,data:o}}}};function ik(e){return"x"===e?"y":"x"}const cq=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:i=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...u}=e,l={x:n,y:r},c=await xv(t,u),d=Hm(ip(o)),f=ik(d);let p=l[d],m=l[f];if(a){const e="y"===d?"bottom":"right";p=KS(p+c["y"===d?"top":"left"],p,p-c[e])}if(i){const e="y"===f?"bottom":"right";m=KS(m+c["y"===f?"top":"left"],m,m-c[e])}const v=s.fn({...t,[d]:p,[f]:m});return{...v,data:{x:v.x-n,y:v.y-r}}}}},dq=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:i}=t,{offset:s=0,mainAxis:u=!0,crossAxis:l=!0}=e,c={x:n,y:r},d=Hm(o),f=ik(d);let p=c[d],m=c[f];const v="function"==typeof s?s({...a,placement:o}):s,h="number"==typeof v?{mainAxis:v,crossAxis:0}:{mainAxis:0,crossAxis:0,...v};if(u){const e="y"===d?"height":"width",t=a.reference[d]-a.floating[e]+h.mainAxis,n=a.reference[d]+a.reference[e]-h.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){var g,y,b,w;const e="y"===d?"width":"height",t=["top","left"].includes(ip(o)),n=a.reference[f]-a.floating[e]+(t&&null!=(g=null==(y=i.offset)?void 0:y[f])?g:0)+(t?0:h.crossAxis),r=a.reference[f]+a.reference[e]+(t?0:null!=(b=null==(w=i.offset)?void 0:w[f])?b:0)-(t?h.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[d]:p,[f]:m}}}},fq=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:a}=t,{apply:i,...s}=e,u=await xv(t,s),l=ip(n),c=jv(n);let d,f;"top"===l||"bottom"===l?(d=l,f=c===(await(null==o.isRTL?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(f=l,d="end"===c?"top":"bottom");const p=Df(u.left,0),m=Df(u.right,0),v=Df(u.top,0),h=Df(u.bottom,0),g={availableHeight:r.floating.height-(["left","right"].includes(n)?2*(0!==v||0!==h?v+h:Df(u.top,u.bottom)):u[d]),availableWidth:r.floating.width-(["top","bottom"].includes(n)?2*(0!==p||0!==m?p+m:Df(u.left,u.right)):u[f])},y=await o.getDimensions(a.floating);null==i||i({...t,...g});const b=await o.getDimensions(a.floating);return y.width!==b.width||y.height!==b.height?{reset:{rects:!0}}:{}}}};function ak(e){return e&&e.document&&e.location&&e.alert&&e.setInterval}function Pl(e){if(null==e)return window;if(!ak(e)){const t=e.ownerDocument;return t&&t.defaultView||window}return e}function zv(e){return Pl(e).getComputedStyle(e)}function _l(e){return ak(e)?"":e?(e.nodeName||"").toLowerCase():""}function sk(){const e=navigator.userAgentData;return null!=e&&e.brands?e.brands.map((e=>e.brand+"/"+e.version)).join(" "):navigator.userAgent}function hu(e){return e instanceof Pl(e).HTMLElement}function gd(e){return e instanceof Pl(e).Element}function O$(e){return!(typeof ShadowRoot>"u")&&(e instanceof Pl(e).ShadowRoot||e instanceof ShadowRoot)}function Yy(e){const{overflow:t,overflowX:n,overflowY:r}=zv(e);return/auto|scroll|overlay|hidden/.test(t+r+n)}function pq(e){return["table","td","th"].includes(_l(e))}function e2(e){const t=/firefox/i.test(sk()),n=zv(e);return"none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||["transform","perspective"].includes(n.willChange)||t&&"filter"===n.willChange||t&&!!n.filter&&"none"!==n.filter}function uk(){return!/^((?!chrome|android).)*safari/i.test(sk())}const t2=Math.min,sv=Math.max,ay=Math.round;function xl(e,t,n){var r,o,a,i;void 0===t&&(t=!1),void 0===n&&(n=!1);const s=e.getBoundingClientRect();let u=1,l=1;t&&hu(e)&&(u=e.offsetWidth>0&&ay(s.width)/e.offsetWidth||1,l=e.offsetHeight>0&&ay(s.height)/e.offsetHeight||1);const c=gd(e)?Pl(e):window,d=!uk()&&n,f=(s.left+(d&&null!=(r=null==(o=c.visualViewport)?void 0:o.offsetLeft)?r:0))/u,p=(s.top+(d&&null!=(a=null==(i=c.visualViewport)?void 0:i.offsetTop)?a:0))/l,m=s.width/u,v=s.height/l;return{width:m,height:v,top:p,right:f+m,bottom:p+v,left:f,x:f,y:p}}function ud(e){return(t=e,(t instanceof Pl(t).Node?e.ownerDocument:e.document)||window.document).documentElement;var t}function Qy(e){return gd(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function lk(e){return xl(ud(e)).left+Qy(e).scrollLeft}function mq(e,t,n){const r=hu(t),o=ud(t),a=xl(e,r&&function(e){const t=xl(e);return ay(t.width)!==e.offsetWidth||ay(t.height)!==e.offsetHeight}(t),"fixed"===n);let i={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if(r||!r&&"fixed"!==n)if(("body"!==_l(t)||Yy(o))&&(i=Qy(t)),hu(t)){const e=xl(t,!0);s.x=e.x+t.clientLeft,s.y=e.y+t.clientTop}else o&&(s.x=lk(o));return{x:a.left+i.scrollLeft-s.x,y:a.top+i.scrollTop-s.y,width:a.width,height:a.height}}function ck(e){return"html"===_l(e)?e:e.assignedSlot||e.parentNode||(O$(e)?e.host:null)||ud(e)}function n2(e){return hu(e)&&"fixed"!==getComputedStyle(e).position?e.offsetParent:null}function YS(e){const t=Pl(e);let n=n2(e);for(;n&&pq(n)&&"static"===getComputedStyle(n).position;)n=n2(n);return n&&("html"===_l(n)||"body"===_l(n)&&"static"===getComputedStyle(n).position&&!e2(n))?t:n||function(e){let t=ck(e);for(O$(t)&&(t=t.host);hu(t)&&!["html","body"].includes(_l(t));){if(e2(t))return t;t=t.parentNode}return null}(e)||t}function r2(e){if(hu(e))return{width:e.offsetWidth,height:e.offsetHeight};const t=xl(e);return{width:t.width,height:t.height}}function dk(e){const t=ck(e);return["html","body","#document"].includes(_l(t))?e.ownerDocument.body:hu(t)&&Yy(t)?t:dk(t)}function sy(e,t){var n;void 0===t&&(t=[]);const r=dk(e),o=r===(null==(n=e.ownerDocument)?void 0:n.body),a=Pl(r),i=o?[a].concat(a.visualViewport||[],Yy(r)?r:[]):r,s=t.concat(i);return o?s:s.concat(sy(i))}function o2(e,t,n){return"viewport"===t?oy(function(e,t){const n=Pl(e),r=ud(e),o=n.visualViewport;let a=r.clientWidth,i=r.clientHeight,s=0,u=0;if(o){a=o.width,i=o.height;const e=uk();(e||!e&&"fixed"===t)&&(s=o.offsetLeft,u=o.offsetTop)}return{width:a,height:i,x:s,y:u}}(e,n)):gd(t)?function(e,t){const n=xl(e,!1,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft;return{top:r,left:o,x:o,y:r,right:o+e.clientWidth,bottom:r+e.clientHeight,width:e.clientWidth,height:e.clientHeight}}(t,n):oy(function(e){var t;const n=ud(e),r=Qy(e),o=null==(t=e.ownerDocument)?void 0:t.body,a=sv(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=sv(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0);let s=-r.scrollLeft+lk(e);const u=-r.scrollTop;return"rtl"===zv(o||n).direction&&(s+=sv(n.clientWidth,o?o.clientWidth:0)-a),{width:a,height:i,x:s,y:u}}(ud(e)))}function hq(e){const t=sy(e),n=["absolute","fixed"].includes(zv(e).position)&&hu(e)?YS(e):e;return gd(n)?t.filter((e=>gd(e)&&function(e,t){const n=null==t.getRootNode?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&O$(n)){let n=t;do{if(n&&e===n)return!0;n=n.parentNode||n.host}while(n)}return!1}(e,n)&&"body"!==_l(e))):[]}const vq={getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[..."clippingAncestors"===n?hq(t):[].concat(n),r],i=a[0],s=a.reduce(((e,n)=>{const r=o2(t,n,o);return e.top=sv(r.top,e.top),e.right=t2(r.right,e.right),e.bottom=t2(r.bottom,e.bottom),e.left=sv(r.left,e.left),e}),o2(t,i,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=hu(n),a=ud(n);if(n===a)return t;let i={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if((o||!o&&"fixed"!==r)&&(("body"!==_l(n)||Yy(a))&&(i=Qy(n)),hu(n))){const e=xl(n,!0);s.x=e.x+n.clientLeft,s.y=e.y+n.clientTop}return{...t,x:t.x-i.scrollLeft+s.x,y:t.y-i.scrollTop+s.y}},isElement:gd,getDimensions:r2,getOffsetParent:YS,getDocumentElement:ud,getElementRects:e=>{let{reference:t,floating:n,strategy:r}=e;return{reference:mq(t,YS(n),r),floating:{...r2(n),x:0,y:0}}},getClientRects:e=>Array.from(e.getClientRects()),isRTL:e=>"rtl"===zv(e).direction};function gq(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:i=!0,animationFrame:s=!1}=r,u=o&&!s,l=a&&!s,c=u||l?[...gd(e)?sy(e):[],...sy(t)]:[];c.forEach((e=>{u&&e.addEventListener("scroll",n,{passive:!0}),l&&e.addEventListener("resize",n)}));let d,f=null;if(i){let r=!0;f=new ResizeObserver((()=>{r||n(),r=!1})),gd(e)&&!s&&f.observe(e),f.observe(t)}let p=s?xl(e):null;return s&&function t(){const r=xl(e);!p||r.x===p.x&&r.y===p.y&&r.width===p.width&&r.height===p.height||n(),p=r,d=requestAnimationFrame(t)}(),n(),()=>{var e;c.forEach((e=>{u&&e.removeEventListener("scroll",n),l&&e.removeEventListener("resize",n)})),null==(e=f)||e.disconnect(),f=null,s&&cancelAnimationFrame(d)}}const yq=(e,t,n)=>nq(e,t,{platform:vq,...n});var QS=typeof document<"u"?v.useLayoutEffect:v.useEffect;function XS(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;0!=r--;)if(!XS(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!Object.prototype.hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){const n=o[r];if(!("_owner"===n&&e.$$typeof||XS(e[n],t[n])))return!1}return!0}return e!=e&&t!=t}function wq(e){const t=v.useRef(e);return QS((()=>{t.current=e})),t}function bq(e){let{middleware:t,placement:n="bottom",strategy:r="absolute",whileElementsMounted:o}=void 0===e?{}:e;const a=v.useRef(null),i=v.useRef(null),s=wq(o),u=v.useRef(null),[l,c]=v.useState({x:null,y:null,strategy:r,placement:n,middlewareData:{}}),[d,f]=v.useState(t);XS(null==d?void 0:d.map((e=>{let{options:t}=e;return t})),null==t?void 0:t.map((e=>{let{options:t}=e;return t})))||f(t);const p=v.useCallback((()=>{!a.current||!i.current||yq(a.current,i.current,{middleware:d,placement:n,strategy:r}).then((e=>{m.current&&vu.flushSync((()=>{c(e)}))}))}),[d,n,r]);QS((()=>{m.current&&p()}),[p]);const m=v.useRef(!1);QS((()=>(m.current=!0,()=>{m.current=!1})),[]);const h=v.useCallback((()=>{if("function"==typeof u.current&&(u.current(),u.current=null),a.current&&i.current)if(s.current){const e=s.current(a.current,i.current,p);u.current=e}else p()}),[p,s]),g=v.useCallback((e=>{a.current=e,h()}),[h]),y=v.useCallback((e=>{i.current=e,h()}),[h]),b=v.useMemo((()=>({reference:a,floating:i})),[]);return v.useMemo((()=>({...l,update:p,refs:b,reference:g,floating:y})),[l,p,b,g,y])}const _q=e=>{const{element:t,padding:n}=e;return{name:"arrow",options:e,fn:e=>function(e){return Object.prototype.hasOwnProperty.call(e,"current")}(t)?null!=t.current?QT({element:t.current,padding:n}).fn(e):{}:t?QT({element:t,padding:n}).fn(e):{}}};function xq(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Sq(...e){return t=>e.forEach((e=>xq(e,t)))}const fk=v.forwardRef(((e,t)=>{const{children:n,...r}=e,o=v.Children.toArray(n),a=o.find($q);if(a){const e=a.props.children,n=o.map((t=>t===a?v.Children.count(e)>1?v.Children.only(null):v.isValidElement(e)?e.props.children:null:t));return v.createElement(JS,Te({},r,{ref:t}),v.isValidElement(e)?v.cloneElement(e,void 0,n):null)}return v.createElement(JS,Te({},r,{ref:t}),n)}));fk.displayName="Slot";const JS=v.forwardRef(((e,t)=>{const{children:n,...r}=e;return v.isValidElement(n)?v.cloneElement(n,{...Cq(r,n.props),ref:Sq(t,n.ref)}):v.Children.count(n)>1?v.Children.only(null):null}));JS.displayName="SlotClone";const Eq=({children:e})=>v.createElement(v.Fragment,null,e);function $q(e){return v.isValidElement(e)&&e.type===Eq}function Cq(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...e)=>{a(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...a}:"className"===r&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}const Iq=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],ZS=Iq.reduce(((e,t)=>{const n=v.forwardRef(((e,n)=>{const{asChild:r,...o}=e,a=r?fk:t;return v.useEffect((()=>{window[Symbol.for("radix-ui")]=!0}),[]),v.createElement(a,Te({},o,{ref:n}))}));return n.displayName=`Primitive.${t}`,{...e,[t]:n}}),{});function Rq(e,t){e&&vu.flushSync((()=>e.dispatchEvent(t)))}function Pq(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Tq(...e){return t=>e.forEach((e=>Pq(e,t)))}function Oq(...e){return v.useCallback(Tq(...e),e)}const Lf=null!=globalThis&&globalThis.document?v.useLayoutEffect:()=>{};function Aq(e){const[t,n]=v.useState(void 0);return Lf((()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const t=new ResizeObserver((t=>{if(!Array.isArray(t)||!t.length)return;const r=t[0];let o,a;if("borderBoxSize"in r){const e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;o=t.inlineSize,a=t.blockSize}else o=e.offsetWidth,a=e.offsetHeight;n({width:o,height:a})}));return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)}),[e]),t}const pk="Popper",[A$,mk]=nk(pk),[eZ,Mq]=A$(pk),uy="PopperContent",[Dq,tZ]=A$(uy),[Nq,kq]=A$(uy,{hasParent:!1,positionUpdateFns:new Set}),Lq=v.forwardRef(((e,t)=>{var n,r,o,a,i,s,u,l;const{__scopePopper:c,side:d="bottom",sideOffset:f=0,align:p="center",alignOffset:m=0,arrowPadding:h=0,collisionBoundary:g=[],collisionPadding:y=0,sticky:b="partial",hideWhenDetached:w=!1,avoidCollisions:x=!0,onPlaced:_,...E}=e,S=Mq(uy,c),[I,A]=v.useState(null),k=Oq(t,(e=>A(e))),[C,T]=v.useState(null),R=Aq(C),P=null!==(n=null==R?void 0:R.width)&&void 0!==n?n:0,O=null!==(r=null==R?void 0:R.height)&&void 0!==r?r:0,N=d+("center"!==p?"-"+p:""),M="number"==typeof y?y:{top:0,right:0,bottom:0,left:0,...y},j=Array.isArray(g)?g:[g],D=j.length>0,q={padding:M,boundary:j.filter(Bq),altBoundary:D},{reference:z,floating:L,strategy:$,x:V,y:B,placement:F,middlewareData:U,update:G}=bq({strategy:"fixed",placement:N,whileElementsMounted:gq,middleware:[jq(),lq({mainAxis:f+O,alignmentAxis:m}),x?cq({mainAxis:!0,crossAxis:!1,limiter:"partial"===b?dq():void 0,...q}):void 0,C?_q({element:C,padding:h}):void 0,x?sq({...q}):void 0,fq({...q,apply:({elements:e,availableWidth:t,availableHeight:n})=>{e.floating.style.setProperty("--radix-popper-available-width",`${t}px`),e.floating.style.setProperty("--radix-popper-available-height",`${n}px`)}}),zq({arrowWidth:P,arrowHeight:O}),w?uq({strategy:"referenceHidden"}):void 0].filter(Fq)});Lf((()=>{z(S.anchor)}),[z,S.anchor]);const W=null!==V&&null!==B,[H,Q]=hk(F),K=Ky(_);Lf((()=>{W&&(null==K||K())}),[W,K]);const Y=null===(o=U.arrow)||void 0===o?void 0:o.x,J=null===(a=U.arrow)||void 0===a?void 0:a.y,X=0!==(null===(i=U.arrow)||void 0===i?void 0:i.centerOffset),[Z,ee]=v.useState();Lf((()=>{I&&ee(window.getComputedStyle(I).zIndex)}),[I]);const{hasParent:te,positionUpdateFns:ne}=kq(uy,c),re=!te;v.useLayoutEffect((()=>{if(!re)return ne.add(G),()=>{ne.delete(G)}}),[re,ne,G]),Lf((()=>{re&&W&&Array.from(ne).reverse().forEach((e=>requestAnimationFrame(e)))}),[re,W,ne]);const oe={"data-side":H,"data-align":Q,...E,ref:k,style:{...E.style,animation:W?void 0:"none",opacity:null!==(s=U.hide)&&void 0!==s&&s.referenceHidden?0:void 0}};return v.createElement("div",{ref:L,"data-radix-popper-content-wrapper":"",style:{position:$,left:0,top:0,transform:W?`translate3d(${Math.round(V)}px, ${Math.round(B)}px, 0)`:"translate3d(0, -200%, 0)",minWidth:"max-content",zIndex:Z,"--radix-popper-transform-origin":[null===(u=U.transformOrigin)||void 0===u?void 0:u.x,null===(l=U.transformOrigin)||void 0===l?void 0:l.y].join(" ")},dir:e.dir},v.createElement(Dq,{scope:c,placedSide:H,onArrowChange:T,arrowX:Y,arrowY:J,shouldHideArrow:X},re?v.createElement(Nq,{scope:c,hasParent:!0,positionUpdateFns:ne},v.createElement(ZS.div,oe)):v.createElement(ZS.div,oe)))}));function Fq(e){return void 0!==e}function Bq(e){return null!==e}const jq=()=>({name:"anchorCssProperties",fn(e){const{rects:t,elements:n}=e,{width:r,height:o}=t.reference;return n.floating.style.setProperty("--radix-popper-anchor-width",`${r}px`),n.floating.style.setProperty("--radix-popper-anchor-height",`${o}px`),{}}}),zq=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,a,i;const{placement:s,rects:u,middlewareData:l}=t,c=0!==(null===(n=l.arrow)||void 0===n?void 0:n.centerOffset),d=c?0:e.arrowWidth,f=c?0:e.arrowHeight,[p,m]=hk(s),v={start:"0%",center:"50%",end:"100%"}[m],h=(null!==(r=null===(o=l.arrow)||void 0===o?void 0:o.x)&&void 0!==r?r:0)+d/2,g=(null!==(a=null===(i=l.arrow)||void 0===i?void 0:i.y)&&void 0!==a?a:0)+f/2;let y="",b="";return"bottom"===p?(y=c?v:`${h}px`,b=-f+"px"):"top"===p?(y=c?v:`${h}px`,b=`${u.floating.height+f}px`):"right"===p?(y=-f+"px",b=c?v:`${g}px`):"left"===p&&(y=`${u.floating.width+f}px`,b=c?v:`${g}px`),{data:{x:y,y:b}}}});function hk(e){const[t,n="center"]=e.split("-");return[t,n]}const Vq=Lq;function Uq(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Wq(...e){return t=>e.forEach((e=>Uq(e,t)))}function qq(...e){return v.useCallback(Wq(...e),e)}function Gq(e,t){return v.useReducer(((e,n)=>t[e][n]??e),e)}const vk=e=>{const{present:t,children:n}=e,r=Hq(t),o="function"==typeof n?n({present:r.isPresent}):v.Children.only(n),a=qq(r.ref,o.ref);return"function"==typeof n||r.isPresent?v.cloneElement(o,{ref:a}):null};function Hq(e){const[t,n]=v.useState(),r=v.useRef({}),o=v.useRef(e),a=v.useRef("none"),i=e?"mounted":"unmounted",[s,u]=Gq(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect((()=>{const e=Dg(r.current);a.current="mounted"===s?e:"none"}),[s]),Lf((()=>{const t=r.current,n=o.current;if(n!==e){const r=a.current,i=Dg(t);e?u("MOUNT"):"none"===i||"none"===(null==t?void 0:t.display)?u("UNMOUNT"):u(n&&r!==i?"ANIMATION_OUT":"UNMOUNT"),o.current=e}}),[e,u]),Lf((()=>{if(t){const e=e=>{const n=Dg(r.current).includes(e.animationName);e.target===t&&n&&vu.flushSync((()=>u("ANIMATION_END")))},n=e=>{e.target===t&&(a.current=Dg(r.current))};return t.addEventListener("animationstart",n),t.addEventListener("animationcancel",e),t.addEventListener("animationend",e),()=>{t.removeEventListener("animationstart",n),t.removeEventListener("animationcancel",e),t.removeEventListener("animationend",e)}}u("ANIMATION_END")}),[t,u]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:v.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}function Dg(e){return(null==e?void 0:e.animationName)||"none"}function Kq(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Yq(...e){return t=>e.forEach((e=>Kq(e,t)))}function Qq(...e){return v.useCallback(Yq(...e),e)}function Xq(e,t=(null==globalThis?void 0:globalThis.document)){const n=Ky(e);v.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e),()=>t.removeEventListener("keydown",e)}),[n,t])}vk.displayName="Presence";const eE="dismissableLayer.update",Jq="dismissableLayer.pointerDownOutside",Zq="dismissableLayer.focusOutside";let i2;const eG=v.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),tG=v.forwardRef(((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:i,onInteractOutside:s,onDismiss:u,...l}=e,c=v.useContext(eG),[d,f]=v.useState(null),p=null!==(n=null==d?void 0:d.ownerDocument)&&void 0!==n?n:null==globalThis?void 0:globalThis.document,[,m]=v.useState({}),h=Qq(t,(e=>f(e))),g=Array.from(c.layers),[y]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),b=g.indexOf(y),w=d?g.indexOf(d):-1,x=c.layersWithOutsidePointerEventsDisabled.size>0,_=w>=b,E=nG((e=>{const t=e.target,n=[...c.branches].some((e=>e.contains(t)));!_||n||(null==a||a(e),null==s||s(e),e.defaultPrevented||null==u||u())}),p),S=rG((e=>{const t=e.target;[...c.branches].some((e=>e.contains(t)))||(null==i||i(e),null==s||s(e),e.defaultPrevented||null==u||u())}),p);return Xq((e=>{w===c.layers.size-1&&(null==o||o(e),!e.defaultPrevented&&u&&(e.preventDefault(),u()))}),p),v.useEffect((()=>{if(d)return r&&(0===c.layersWithOutsidePointerEventsDisabled.size&&(i2=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(d)),c.layers.add(d),a2(),()=>{r&&1===c.layersWithOutsidePointerEventsDisabled.size&&(p.body.style.pointerEvents=i2)}}),[d,p,r,c]),v.useEffect((()=>()=>{d&&(c.layers.delete(d),c.layersWithOutsidePointerEventsDisabled.delete(d),a2())}),[d,c]),v.useEffect((()=>{const e=()=>m({});return document.addEventListener(eE,e),()=>document.removeEventListener(eE,e)}),[]),v.createElement(ZS.div,Te({},l,{ref:h,style:{pointerEvents:x?_?"auto":"none":void 0,...e.style},onFocusCapture:jf(e.onFocusCapture,S.onFocusCapture),onBlurCapture:jf(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:jf(e.onPointerDownCapture,E.onPointerDownCapture)}))}));function nG(e,t=(null==globalThis?void 0:globalThis.document)){const n=Ky(e),r=v.useRef(!1),o=v.useRef((()=>{}));return v.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){gk(Jq,n,a,{discrete:!0})};const a={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",o.current),o.current=r,t.addEventListener("click",o.current,{once:!0})):r()}r.current=!1},a=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",e),t.removeEventListener("click",o.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}function rG(e,t=(null==globalThis?void 0:globalThis.document)){const n=Ky(e),r=v.useRef(!1);return v.useEffect((()=>{const e=e=>{e.target&&!r.current&&gk(Zq,n,{originalEvent:e},{discrete:!1})};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function a2(){const e=new CustomEvent(eE);document.dispatchEvent(e)}function gk(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Rq(o,a):o.dispatchEvent(a)}let xx;const yk="HoverCard",[wk,nZ]=nk(yk,[mk]),oG=mk(),[rZ,bk]=wk(yk),iG="HoverCardPortal",[oZ,aG]=wk(iG,{forceMount:void 0}),tE="HoverCardContent",sG=v.forwardRef(((e,t)=>{const n=aG(tE,e.__scopeHoverCard),{forceMount:r=n.forceMount,...o}=e,a=bk(tE,e.__scopeHoverCard);return v.createElement(vk,{present:r||a.open},v.createElement(uG,Te({"data-state":a.open?"open":"closed"},o,{onPointerEnter:jf(e.onPointerEnter,s2(a.onOpen)),onPointerLeave:jf(e.onPointerLeave,s2(a.onClose)),ref:t})))})),uG=v.forwardRef(((e,t)=>{const{__scopeHoverCard:n,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:i,...s}=e,u=bk(tE,n),l=oG(n),c=v.useRef(null),d=tq(t,c),[f,p]=v.useState(!1);return v.useEffect((()=>{if(f){const e=document.body;return xx=e.style.userSelect||e.style.webkitUserSelect,e.style.userSelect="none",e.style.webkitUserSelect="none",()=>{e.style.userSelect=xx,e.style.webkitUserSelect=xx}}}),[f]),v.useEffect((()=>{if(c.current){const e=()=>{p(!1),u.isPointerDownOnContentRef.current=!1,setTimeout((()=>{var e;""!==(null===(e=document.getSelection())||void 0===e?void 0:e.toString())&&(u.hasSelectionRef.current=!0)}))};return document.addEventListener("pointerup",e),()=>{document.removeEventListener("pointerup",e),u.hasSelectionRef.current=!1,u.isPointerDownOnContentRef.current=!1}}}),[u.isPointerDownOnContentRef,u.hasSelectionRef]),v.useEffect((()=>{c.current&&lG(c.current).forEach((e=>e.setAttribute("tabindex","-1")))})),v.createElement(tG,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:i,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:jf(a,(e=>{e.preventDefault()})),onDismiss:u.onDismiss},v.createElement(Vq,Te({},l,s,{onPointerDown:jf(s.onPointerDown,(e=>{e.currentTarget.contains(e.target)&&p(!0),u.hasSelectionRef.current=!1,u.isPointerDownOnContentRef.current=!0})),ref:d,style:{...s.style,userSelect:f?"text":void 0,WebkitUserSelect:f?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})))}));function s2(e){return t=>"touch"===t.pointerType?void 0:e()}function lG(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;n.nextNode();)t.push(n.currentNode);return t}const _k=sG,cG=v.forwardRef((({className:e,align:t="center",sideOffset:n=4,...r},o)=>G.jsx(_k,{ref:o,align:t,sideOffset:n,className:we("z-50 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...r})));cG.displayName=_k.displayName;const xk=v.forwardRef((({className:e,type:t,...n},r)=>{const{error:o}=bd();return G.jsx("input",{type:t,title:n.disabled?"Disabled":"",className:we("flex w-full rounded-m px-s py-3.5 text-base text-gray-900 outline outline-1 outline-input ring-offset-background transition-all duration-200 ease-in-out file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-base placeholder:text-gray-400 placeholder:text-muted-foreground focus-visible:bg-gray-50 focus-visible:text-gray-900 focus-visible:outline-2 focus-visible:outline-blue_120 enabled:hover:outline-2 enabled:hover:outline-gray-400 disabled:bg-transparent disabled:text-gray-300 disabled:outline-gray-200 disabled:ring-0 disabled:ring-transparent disabled:placeholder:text-gray-300",{"bg-red_30_17 outline-red-dark":!!o},e),ref:r,...n})}));function dG(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>v.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return v.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const o=v.createContext(r),a=n.length;n=[...n,r];const i=t=>{var n;const{scope:r,children:i,...s}=t,u=(null==(n=null==r?void 0:r[e])?void 0:n[a])||o,l=v.useMemo((()=>s),Object.values(s));return G.jsx(u.Provider,{value:l,children:i})};return i.displayName=t+"Provider",[i,function(n,i){var s;const u=(null==(s=null==i?void 0:i[e])?void 0:s[a])||o,l=v.useContext(u);if(l)return l;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},fG(r,...t)]}function fG(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return v.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}function u2(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function pG(...e){return t=>{let n=!1;const r=e.map((e=>{const r=u2(e,t);return!n&&"function"==typeof r&&(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():u2(e[t],null)}}}}function mG(e){const t=hG(e),n=v.forwardRef(((e,n)=>{const{children:r,...o}=e,a=v.Children.toArray(r),i=a.find(gG);if(i){const e=i.props.children,r=a.map((t=>t===i?v.Children.count(e)>1?v.Children.only(null):v.isValidElement(e)?e.props.children:null:t));return G.jsx(t,{...o,ref:n,children:v.isValidElement(e)?v.cloneElement(e,void 0,r):null})}return G.jsx(t,{...o,ref:n,children:r})}));return n.displayName=`${e}.Slot`,n}function hG(e){const t=v.forwardRef(((e,t)=>{const{children:n,...r}=e;if(v.isValidElement(n)){const e=wG(n),o=yG(r,n.props);return n.type!==v.Fragment&&(o.ref=t?pG(t,e):e),v.cloneElement(n,o)}return v.Children.count(n)>1?v.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}xk.displayName="Input";var vG=Symbol("radix.slottable");function gG(e){return v.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===vG}function yG(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...e)=>{const t=a(...e);return o(...e),t}:o&&(n[r]=o):"style"===r?n[r]={...o,...a}:"className"===r&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}function wG(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?e.ref:(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o?e.props.ref:e.props.ref||e.ref)}var bG=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Sk=bG.reduce(((e,t)=>{const n=mG(`Primitive.${t}`),r=v.forwardRef(((e,r)=>{const{asChild:o,...a}=e,i=o?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),G.jsx(i,{...a,ref:r})}));return r.displayName=`Primitive.${t}`,{...e,[t]:r}}),{}),M$="Progress",D$=100,[_G,iZ]=dG(M$),[xG,SG]=_G(M$),Ek=v.forwardRef(((e,t)=>{const{__scopeProgress:n,value:r=null,max:o,getValueLabel:a=EG,...i}=e;(o||0===o)&&!l2(o)&&console.error($G(`${o}`,"Progress"));const s=l2(o)?o:D$;null!==r&&!c2(r,s)&&console.error(CG(`${r}`,"Progress"));const u=c2(r,s)?r:null,l=ly(u)?a(u,s):void 0;return G.jsx(xG,{scope:n,value:u,max:s,children:G.jsx(Sk.div,{"aria-valuemax":s,"aria-valuemin":0,"aria-valuenow":ly(u)?u:void 0,"aria-valuetext":l,role:"progressbar","data-state":Ik(u,s),"data-value":u??void 0,"data-max":s,...i,ref:t})})}));Ek.displayName=M$;var $k="ProgressIndicator",Ck=v.forwardRef(((e,t)=>{const{__scopeProgress:n,...r}=e,o=SG($k,n);return G.jsx(Sk.div,{"data-state":Ik(o.value,o.max),"data-value":o.value??void 0,"data-max":o.max,...r,ref:t})}));function EG(e,t){return`${Math.round(e/t*100)}%`}function Ik(e,t){return null==e?"indeterminate":e===t?"complete":"loading"}function ly(e){return"number"==typeof e}function l2(e){return ly(e)&&!isNaN(e)&&e>0}function c2(e,t){return ly(e)&&!isNaN(e)&&e<=t&&e>=0}function $G(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${D$}\`.`}function CG(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:\n - a positive number\n - less than the value passed to \`max\` (or ${D$} if no \`max\` prop is set)\n - \`null\` or \`undefined\` if the progress is indeterminate.\n\nDefaulting to \`null\`.`}Ck.displayName=$k;var Rk=Ek,IG=Ck;const RG=v.forwardRef((({className:e,value:t,indicatorClassName:n,...r},o)=>G.jsx(Rk,{ref:o,className:we("relative h-[7px] w-full overflow-hidden rounded-full bg-blue_10",e),...r,children:G.jsx(IG,{className:we("h-full w-full flex-1 rounded-full bg-blue_100 transition-all",n),style:{transform:`translateX(-${100-(t||0)}%)`}})})));RG.displayName=Rk.displayName;const Pk="Radio",[PG,Tk]=ni(Pk),[TG,OG]=PG(Pk),AG=v.forwardRef(((e,t)=>{const{__scopeRadio:n,name:r,checked:o=!1,required:a,disabled:i,value:s="on",onCheck:u,...l}=e,[c,d]=v.useState(null),f=Vt(t,(e=>d(e))),p=v.useRef(!1),m=!c||!!c.closest("form");return v.createElement(TG,{scope:n,checked:o,disabled:i},v.createElement(ft.button,Te({type:"button",role:"radio","aria-checked":o,"data-state":Ok(o),"data-disabled":i?"":void 0,disabled:i,value:s},l,{ref:f,onClick:et(e.onClick,(e=>{o||null==u||u(),m&&(p.current=e.isPropagationStopped(),p.current||e.stopPropagation())}))})),m&&v.createElement(NG,{control:c,bubbles:!p.current,name:r,value:s,checked:o,required:a,disabled:i,style:{transform:"translateX(-100%)"}}))})),MG="RadioIndicator",DG=v.forwardRef(((e,t)=>{const{__scopeRadio:n,forceMount:r,...o}=e,a=OG(MG,n);return v.createElement(ea,{present:r||a.checked},v.createElement(ft.span,Te({"data-state":Ok(a.checked),"data-disabled":a.disabled?"":void 0},o,{ref:t})))})),NG=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,a=v.useRef(null),i=ky(n),s=Ly(t);return v.useEffect((()=>{const e=a.current,t=window.HTMLInputElement.prototype,o=Object.getOwnPropertyDescriptor(t,"checked").set;if(i!==n&&o){const t=new Event("click",{bubbles:r});o.call(e,n),e.dispatchEvent(t)}}),[i,n,r]),v.createElement("input",Te({type:"radio","aria-hidden":!0,defaultChecked:n},o,{tabIndex:-1,ref:a,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function Ok(e){return e?"checked":"unchecked"}const kG=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Ak="RadioGroup",[LG,aZ]=ni(Ak,[qm,Tk]),Mk=qm(),Dk=Tk(),[FG,BG]=LG(Ak),jG=v.forwardRef(((e,t)=>{const{__scopeRadioGroup:n,name:r,defaultValue:o,value:a,required:i=!1,disabled:s=!1,orientation:u,dir:l,loop:c=!0,onValueChange:d,...f}=e,p=Mk(n),m=s$(l),[h,g]=fd({prop:a,defaultProp:o,onChange:d});return v.createElement(FG,{scope:n,name:r,required:i,disabled:s,value:h,onValueChange:g},v.createElement(g$,Te({asChild:!0},p,{orientation:u,dir:m,loop:c}),v.createElement(ft.div,Te({role:"radiogroup","aria-required":i,"aria-orientation":u,"data-disabled":s?"":void 0,dir:m},f,{ref:t}))))})),zG="RadioGroupItem",VG=v.forwardRef(((e,t)=>{const{__scopeRadioGroup:n,disabled:r,...o}=e,a=BG(zG,n),i=a.disabled||r,s=Mk(n),u=Dk(n),l=v.useRef(null),c=Vt(t,l),d=a.value===o.value,f=v.useRef(!1);return v.useEffect((()=>{const e=e=>{kG.includes(e.key)&&(f.current=!0)},t=()=>f.current=!1;return document.addEventListener("keydown",e),document.addEventListener("keyup",t),()=>{document.removeEventListener("keydown",e),document.removeEventListener("keyup",t)}}),[]),v.createElement(y$,Te({asChild:!0},s,{focusable:!i,active:d}),v.createElement(AG,Te({disabled:i,required:a.required,checked:d},u,o,{name:a.name,ref:c,onCheck:()=>a.onValueChange(o.value),onKeyDown:et((e=>{"Enter"===e.key&&e.preventDefault()})),onFocus:et(o.onFocus,(()=>{var e;f.current&&(null===(e=l.current)||void 0===e||e.click())}))})))})),UG=v.forwardRef(((e,t)=>{const{__scopeRadioGroup:n,...r}=e,o=Dk(n);return v.createElement(DG,Te({},o,r,{ref:t}))})),Nk=jG,kk=VG,WG=UG,qG=v.forwardRef((({className:e,...t},n)=>G.jsx(Nk,{className:we("grid gap-2",e),...t,ref:n})));qG.displayName=Nk.displayName;const GG=v.forwardRef((({className:e,...t},n)=>G.jsx(kk,{ref:n,className:we("aspect-square size-6 rounded-full border border-gray-300 disabled:cursor-not-allowed disabled:border-gray-100 disabled:bg-gray-100","data-[state=checked]:border-blue_100 data-[state=checked]:bg-blue_100 hover:data-[state=checked]:border-blue_120","disabled:data-[state=checked]:border-gray-100 disabled:data-[state=checked]:bg-gray-100","transition-[border] duration-200 hover:data-[state=checked]:bg-blue_120 md:hover:border-2",e),...t,children:G.jsx(WG,{className:"flex items-center justify-center",children:G.jsx(j5,{className:"stack-animate size-2 border-none",style:{fill:t.disabled?"var(--gray-300)":"white",color:t.disabled?"var(--gray-300)":"white"}})})})));GG.displayName=kk.displayName;const HG=FA,KG=Ey,Lk=v.forwardRef((({className:e,...t},n)=>G.jsx(Bm,{className:we("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:n})));Lk.displayName=Bm.displayName;const YG=gu("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),Fk=v.forwardRef((({side:e="right",className:t,overlayClassName:n,children:r,...o},a)=>G.jsxs(KG,{children:[G.jsx(Lk,{className:we("bg-gray-900/70",n)}),G.jsxs(jm,{ref:a,className:we(YG({side:e}),t),...o,children:[r,G.jsxs($y,{className:"absolute right-4 top-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary",children:[G.jsx(gy,{className:"h-4 w-4"}),G.jsx("span",{className:"sr-only",children:"Close"})]})]})]})));Fk.displayName=jm.displayName;const Bk=({className:e,...t})=>G.jsx("div",{className:we("flex flex-col space-y-2 text-center sm:text-left",e),...t});Bk.displayName="SheetHeader";const jk=v.forwardRef((({className:e,...t},n)=>G.jsx(Ov,{ref:n,className:we("text-lg font-semibold text-foreground",e),...t})));jk.displayName=Ov.displayName;const zk=v.forwardRef((({className:e,...t},n)=>G.jsx(Av,{ref:n,className:we("text-sm text-muted-foreground",e),...t})));zk.displayName=Av.displayName;const[Xy,sZ]=ni("Tooltip",[Wm]),N$=Wm(),QG="TooltipProvider",XG=700,nE="tooltip.open",[JG,k$]=Xy(QG),ZG=e=>{const{__scopeTooltip:t,delayDuration:n=XG,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:a}=e,[i,s]=v.useState(!0),u=v.useRef(!1),l=v.useRef(0);return v.useEffect((()=>{const e=l.current;return()=>window.clearTimeout(e)}),[]),v.createElement(JG,{scope:t,isOpenDelayed:i,delayDuration:n,onOpen:v.useCallback((()=>{window.clearTimeout(l.current),s(!1)}),[]),onClose:v.useCallback((()=>{window.clearTimeout(l.current),l.current=window.setTimeout((()=>s(!0)),r)}),[r]),isPointerInTransitRef:u,onPointerInTransitChange:v.useCallback((e=>{u.current=e}),[]),disableHoverableContent:o},a)},L$="Tooltip",[eH,Vv]=Xy(L$),tH=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o=!1,onOpenChange:a,disableHoverableContent:i,delayDuration:s}=e,u=k$(L$,e.__scopeTooltip),l=N$(t),[c,d]=v.useState(null),f=ad(),p=v.useRef(0),m=i??u.disableHoverableContent,h=s??u.delayDuration,g=v.useRef(!1),[y=!1,b]=fd({prop:r,defaultProp:o,onChange:e=>{e?(u.onOpen(),document.dispatchEvent(new CustomEvent(nE))):u.onClose(),null==a||a(e)}}),w=v.useMemo((()=>y?g.current?"delayed-open":"instant-open":"closed"),[y]),x=v.useCallback((()=>{window.clearTimeout(p.current),g.current=!1,b(!0)}),[b]),_=v.useCallback((()=>{window.clearTimeout(p.current),b(!1)}),[b]),E=v.useCallback((()=>{window.clearTimeout(p.current),p.current=window.setTimeout((()=>{g.current=!0,b(!0)}),h)}),[h,b]);return v.useEffect((()=>()=>window.clearTimeout(p.current)),[]),v.createElement(sN,l,v.createElement(eH,{scope:t,contentId:f,open:y,stateAttribute:w,trigger:c,onTriggerChange:d,onTriggerEnter:v.useCallback((()=>{u.isOpenDelayed?E():x()}),[u.isOpenDelayed,E,x]),onTriggerLeave:v.useCallback((()=>{m?_():window.clearTimeout(p.current)}),[_,m]),onOpen:x,onClose:_,disableHoverableContent:m},n))},d2="TooltipTrigger",nH=v.forwardRef(((e,t)=>{const{__scopeTooltip:n,...r}=e,o=Vv(d2,n),a=k$(d2,n),i=N$(n),s=Vt(t,v.useRef(null),o.onTriggerChange),u=v.useRef(!1),l=v.useRef(!1),c=v.useCallback((()=>u.current=!1),[]);return v.useEffect((()=>()=>document.removeEventListener("pointerup",c)),[c]),v.createElement(m$,Te({asChild:!0},i),v.createElement(ft.button,Te({"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute},r,{ref:s,onPointerMove:et(e.onPointerMove,(e=>{"touch"!==e.pointerType&&!l.current&&!a.isPointerInTransitRef.current&&(o.onTriggerEnter(),l.current=!0)})),onPointerLeave:et(e.onPointerLeave,(()=>{o.onTriggerLeave(),l.current=!1})),onPointerDown:et(e.onPointerDown,(()=>{u.current=!0,document.addEventListener("pointerup",c,{once:!0})})),onFocus:et(e.onFocus,(()=>{u.current||o.onOpen()})),onBlur:et(e.onBlur,o.onClose),onClick:et(e.onClick,o.onClose)})))})),Vk="TooltipPortal",[rH,oH]=Xy(Vk,{forceMount:void 0}),iH=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,a=Vv(Vk,t);return v.createElement(rH,{scope:t,forceMount:n},v.createElement(ea,{present:n||a.open},v.createElement(by,{asChild:!0,container:o},r)))},Sv="TooltipContent",Uk=v.forwardRef(((e,t)=>{const n=oH(Sv,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...a}=e,i=Vv(Sv,e.__scopeTooltip);return v.createElement(ea,{present:r||i.open},i.disableHoverableContent?v.createElement(Wk,Te({side:o},a,{ref:t})):v.createElement(aH,Te({side:o},a,{ref:t})))})),aH=v.forwardRef(((e,t)=>{const n=Vv(Sv,e.__scopeTooltip),r=k$(Sv,e.__scopeTooltip),o=v.useRef(null),a=Vt(t,o),[i,s]=v.useState(null),{trigger:u,onClose:l}=n,c=o.current,{onPointerInTransitChange:d}=r,f=v.useCallback((()=>{s(null),d(!1)}),[d]),p=v.useCallback(((e,t)=>{const n=e.currentTarget,r={x:e.clientX,y:e.clientY},o=fH([...lH(r,uH(r,n.getBoundingClientRect())),...cH(t.getBoundingClientRect())]);s(o),d(!0)}),[d]);return v.useEffect((()=>()=>f()),[f]),v.useEffect((()=>{if(u&&c){const e=e=>p(e,c),t=e=>p(e,u);return u.addEventListener("pointerleave",e),c.addEventListener("pointerleave",t),()=>{u.removeEventListener("pointerleave",e),c.removeEventListener("pointerleave",t)}}}),[u,c,p,f]),v.useEffect((()=>{if(i){const e=e=>{const t=e.target,n={x:e.clientX,y:e.clientY},r=(null==u?void 0:u.contains(t))||(null==c?void 0:c.contains(t)),o=!dH(n,i);r?f():o&&(f(),l())};return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}}),[u,c,i,l,f]),v.createElement(Wk,Te({},e,{ref:a}))})),[sH,uZ]=Xy(L$,{isInside:!1}),Wk=v.forwardRef(((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:a,onPointerDownOutside:i,...s}=e,u=Vv(Sv,n),l=N$(n),{onClose:c}=u;return v.useEffect((()=>(document.addEventListener(nE,c),()=>document.removeEventListener(nE,c))),[c]),v.useEffect((()=>{if(u.trigger){const e=e=>{const t=e.target;null!=t&&t.contains(u.trigger)&&c()};return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}}),[u.trigger,c]),v.createElement(wy,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:e=>e.preventDefault(),onDismiss:c},v.createElement(h$,Te({"data-state":u.stateAttribute},l,s,{ref:t,style:{...s.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"}}),v.createElement(_E,null,r),v.createElement(sH,{scope:n,isInside:!0},v.createElement(qU,{id:u.contentId,role:"tooltip"},o||r))))}));function uH(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,o,a)){case a:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function lH(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n})}return r}function cH(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function dH(e,t){const{x:n,y:r}=e;let o=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){const i=t[e].x,s=t[e].y,u=t[a].x,l=t[a].y;s>r!=l>r&&n<(u-i)*(r-s)/(l-s)+i&&(o=!o)}return o}function fH(e){const t=e.slice();return t.sort(((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:e.y>t.y?1:0)),pH(t)}function pH(e){if(e.length<=1)return e.slice();const t=[];for(let n=0;n<e.length;n++){const r=e[n];for(;t.length>=2;){const e=t[t.length-1],n=t[t.length-2];if(!((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x)))break;t.pop()}t.push(r)}t.pop();const n=[];for(let t=e.length-1;t>=0;t--){const r=e[t];for(;n.length>=2;){const e=n[n.length-1],t=n[n.length-2];if(!((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.x)))break;n.pop()}n.push(r)}return n.pop(),1===t.length&&1===n.length&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}const mH=iH,qk=Uk,hH=()=>{const e=window.innerWidth;return e<768?"mobile":e<1024?"tablet":"desktop"},vH=e=>{if("object"!=typeof e||null===e)return!1;let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||null===Object.getPrototypeOf(e)},gH=e=>vH(e)&&"type"in e&&"string"==typeof e.type,wt=e=>{const t=t=>({type:e,payload:t});return t.toString=()=>`${e}`,t.type=e,t.match=t=>gH(t)&&t.type===e,t};wt("remoteReady"),wt("askLogin"),wt("reselectUser"),wt("requestLogout");const yH=wt("setConfirmLeavePage"),wH=wt("requestChangePath");wt("wsSubscribe"),wt("wsUnSubscribe"),wt("hostStoreConnect"),wt("remoteLogin");const bH=wt("remoteLogout");wt("wsOnMessage");const _H=wt("setRouterPath"),xH=wt("setDeviceType"),SH=wt("setDeviceWidth"),EH=wt("setUserError"),$H=wt("setUserIsError"),CH=wt("setUserPending"),IH=wt("setUserSuccess"),RH=wt("setUserData"),PH=wt("updateAccountData"),TH=wt("updateUser"),OH=wt("addNotification"),AH=wt("markNotification"),MH=wt("setNotificationsError"),DH=wt("setNotificationsList"),NH=wt("setNotificationsPending"),kH=wt("setNotificationsTotalCount"),LH=wt("setNotificationsUnreadCount"),FH=wt("acceptAllFollowRequests"),BH=wt("resetNotificationsState"),jH=wt("undoNotification"),zH=wt("setInstanceInfo"),VH=wt("setInstanceInfoPending"),UH=wt("setInstanceInfoError"),WH=wt("setPlatformSettings"),qH=wt("setProfileSettings");wt("setGroupData"),wt("setGroupLoading"),wt("requestLocalStorageGet"),wt("requestLocalStorageSet"),wt("requestLocalStorageRemove"),wt("requestLocalStorageClear"),wt("requestLocalStorageKeys"),wt("requestLocalStorageHas"),wt("sendLocalStorageResponse"),wt("sendLocalStorageChanged");const uv="8.48.0",$l=globalThis;function F$(e,t,n){const r=$l,o=r.__SENTRY__=r.__SENTRY__||{},a=o[uv]=o[uv]||{};return a[e]||(a[e]=t())}const Gk=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,GH="Sentry Logger ",f2=["debug","info","warn","error","log","assert","trace"],p2={};function HH(e){if(!("console"in $l))return e();const t=$l.console,n={},r=Object.keys(p2);r.forEach((e=>{const r=p2[e];n[e]=t[e],t[e]=r}));try{return e()}finally{r.forEach((e=>{t[e]=n[e]}))}}function KH(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return Gk?f2.forEach((n=>{t[n]=(...t)=>{e&&HH((()=>{$l.console[n](`${GH}[${n}]:`,...t)}))}})):f2.forEach((e=>{t[e]=()=>{}})),t}const Ug=F$("logger",KH);function B$(){return j$($l),$l}function j$(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||uv,t[uv]=t[uv]||{}}const YH=Object.prototype.toString;function QH(e,t){return YH.call(e)===`[object ${t}]`}function XH(e){return QH(e,"Object")}function JH(e){return!(!e||!e.then||"function"!=typeof e.then)}function ZH(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{Gk&&Ug.log(`Failed to add non-enumerable property "${t}" to object`,e)}}const Hk=1e3;function Kk(){return Date.now()/Hk}function eK(){const{performance:e}=$l;if(!e||!e.now)return Kk;const t=Date.now()-e.now(),n=null==e.timeOrigin?t:e.timeOrigin;return()=>(n+e.now())/Hk}const tK=eK();function Tm(){const e=$l,t=e.crypto||e.msCrypto;let n=()=>16*Math.random();try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{const e=new Uint8Array(1);return t.getRandomValues(e),e[0]})}catch{}return"10000000100040008000100000000000".replace(/[018]/g,(e=>(e^(15&n())>>e/4).toString(16)))}function nK(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||tK(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=32===t.sid.length?t.sid:Tm()),void 0!==t.init&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),"number"==typeof t.started&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if("number"==typeof t.duration)e.duration=t.duration;else{const t=e.timestamp-e.started;e.duration=t>=0?t:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),"number"==typeof t.errors&&(e.errors=t.errors),t.status&&(e.status=t.status)}function m2(){return Tm()}function h2(){return Tm().substring(16)}function Yk(e,t,n=2){if(!t||"object"!=typeof t||n<=0)return t;if(e&&t&&0===Object.keys(t).length)return e;const r={...e};for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(r[e]=Yk(r[e],t[e],n-1));return r}(()=>{const{performance:e}=$l;if(!e||!e.now)return;const t=36e5,n=e.now(),r=Date.now(),o=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,a=o<t,i=e.timing&&e.timing.navigationStart,s="number"==typeof i?Math.abs(i+n-r):t;(a||s<t)&&(o<=s&&e.timeOrigin)})();const rE="_sentrySpan";function v2(e,t){t?ZH(e,rE,t):delete e[rE]}function g2(e){return e[rE]}const rK=100;class z${constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:m2(),spanId:h2()}}clone(){const e=new z$;return e._breadcrumbs=[...this._breadcrumbs],e._tags={...this._tags},e._extra={...this._extra},e._contexts={...this._contexts},this._contexts.flags&&(e._contexts.flags={values:[...this._contexts.flags.values]}),e._user=this._user,e._level=this._level,e._session=this._session,e._transactionName=this._transactionName,e._fingerprint=this._fingerprint,e._eventProcessors=[...this._eventProcessors],e._requestSession=this._requestSession,e._attachments=[...this._attachments],e._sdkProcessingMetadata={...this._sdkProcessingMetadata},e._propagationContext={...this._propagationContext},e._client=this._client,e._lastEventId=this._lastEventId,v2(e,g2(this)),e}setClient(e){this._client=e}setLastEventId(e){this._lastEventId=e}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&nK(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(e){return this._requestSession=e,this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this._tags={...this._tags,[e]:t},this._notifyScopeListeners(),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return null===t?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(e){if(!e)return this;const t="function"==typeof e?e(this):e,[n,r]=t instanceof Ev?[t.getScopeData(),t.getRequestSession()]:XH(t)?[e,e.requestSession]:[],{tags:o,extra:a,user:i,contexts:s,level:u,fingerprint:l=[],propagationContext:c}=n||{};return this._tags={...this._tags,...o},this._extra={...this._extra,...a},this._contexts={...this._contexts,...s},i&&Object.keys(i).length&&(this._user=i),u&&(this._level=u),l.length&&(this._fingerprint=l),c&&(this._propagationContext=c),r&&(this._requestSession=r),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._session=void 0,v2(this,void 0),this._attachments=[],this.setPropagationContext({traceId:m2()}),this._notifyScopeListeners(),this}addBreadcrumb(e,t){const n="number"==typeof t?t:rK;if(n<=0)return this;const r={timestamp:Kk(),...e},o=this._breadcrumbs;return o.push(r),this._breadcrumbs=o.length>n?o.slice(-n):o,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:g2(this)}}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata=Yk(this._sdkProcessingMetadata,e,2),this}setPropagationContext(e){return this._propagationContext={spanId:h2(),...e},this}getPropagationContext(){return this._propagationContext}captureException(e,t){const n=t&&t.event_id?t.event_id:Tm();if(!this._client)return Ug.warn("No client configured on scope - will not capture exception!"),n;const r=new Error("Sentry syntheticException");return this._client.captureException(e,{originalException:e,syntheticException:r,...t,event_id:n},this),n}captureMessage(e,t,n){const r=n&&n.event_id?n.event_id:Tm();if(!this._client)return Ug.warn("No client configured on scope - will not capture message!"),r;const o=new Error(e);return this._client.captureMessage(e,t,{originalException:e,syntheticException:o,...n,event_id:r},this),r}captureEvent(e,t){const n=t&&t.event_id?t.event_id:Tm();return this._client?(this._client.captureEvent(e,{...t,event_id:n},this),n):(Ug.warn("No client configured on scope - will not capture event!"),n)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((e=>{e(this)})),this._notifyingListeners=!1)}}const Ev=z$;function oK(){return F$("defaultCurrentScope",(()=>new Ev))}function iK(){return F$("defaultIsolationScope",(()=>new Ev))}class aK{constructor(e,t){let n,r;n=e||new Ev,r=t||new Ev,this._stack=[{scope:n}],this._isolationScope=r}withScope(e){const t=this._pushScope();let n;try{n=e(t)}catch(e){throw this._popScope(),e}return JH(n)?n.then((e=>(this._popScope(),e)),(e=>{throw this._popScope(),e})):(this._popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const e=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:e}),e}_popScope(){return!(this._stack.length<=1)&&!!this._stack.pop()}}function Lm(){const e=j$(B$());return e.stack=e.stack||new aK(oK(),iK())}function sK(e){return Lm().withScope(e)}function uK(e,t){const n=Lm();return n.withScope((()=>(n.getStackTop().scope=e,t(e))))}function y2(e){return Lm().withScope((()=>e(Lm().getIsolationScope())))}function lK(){return{withIsolationScope:y2,withScope:sK,withSetScope:uK,withSetIsolationScope:(e,t)=>y2(t),getCurrentScope:()=>Lm().getScope(),getIsolationScope:()=>Lm().getIsolationScope()}}function Qk(e){const t=j$(e);return t.acs?t.acs:lK()}function Xk(){return Qk(B$()).getCurrentScope()}function cK(){return Qk(B$()).getIsolationScope()}function dK(e,t){return Xk().captureException(e,void 0)}function fK(e,t){const n={captureContext:t};return Xk().captureMessage(e,void 0,n)}function pK(e,t){cK().setExtra(e,t)}const mK=(...e)=>{let t="";for(const n of e){if(n instanceof Error){const e=n;return pK("exceptionMessage",t),void dK(e)}if("object"!=typeof n)t+=n;else try{t+=" "+JSON.stringify(n)}catch{t+=" "+n}}fK(t)},Jy=()=>"object"!=typeof window,hK="wlsy",Jk=()=>{try{return window.localStorage}catch(e){console.warn("Error getting window.localStorage storage",e)}},vK=()=>{const e=new Set,t=Jk();if(!t)return[];for(let n=0;n<(null==t?void 0:t.length);n+=1){const r=null==t?void 0:t.key(n);"string"==typeof r&&e.add(r)}return Array.from(e)},V$=e=>{const t=`${hK}${e?`:${e}`:""}`,n=e=>`${t}:${e}`,r=()=>vK().filter((e=>e.startsWith(`${t}:`))),o=e=>e.slice(t.length+1),a=Jk(),i=e=>{try{return null==a?void 0:a.getItem(n(e))}catch{return null}},s=(e,t)=>{try{null==a||a.setItem(n(e),String(t))}catch{return}};return{getItem:i,setItem:s,removeItem:e=>{try{null==a||a.removeItem(n(e))}catch{return}},clear:()=>{try{r().forEach((e=>null==a?void 0:a.removeItem(e)))}catch{return}},keys:()=>r().map(o),has:e=>null!==i(e),getJSON:e=>{const t=i(e);if(null==t)return null;try{return JSON.parse(t)}catch{return null}},setJSON:(e,t)=>{try{s(e,JSON.stringify(t))}catch{return}}}},w2=["debug","info","warn","error"],gK=(e,t)=>{const n=w2.indexOf(e);return w2.indexOf(t)>=n},Ng=(e,t,n,...r)=>{gK(t,e)&&console.log(`[${e}] ${n}`,...r)},yK=()=>V$().getItem("logger_lvl"),wK=(e=(Jy()?"info":yK()||"warn"))=>{let t=e;return{debug:(e,...n)=>Ng("debug",t,e,...n),info:(e,...n)=>Ng("info",t,e,...n),warn:(e,...n)=>Ng("warn",t,e,...n),error:(e,...n)=>(mK(e,...n),Ng("error",t,e,...n)),setLevel:e=>{t=e},getLevel:()=>t}},ap=wK(),bK=e=>{try{const{type:t,payload:n}=e,r={type:t};return void 0!==n&&(r.payload=JSON.parse(JSON.stringify(n))),r}catch(t){return ap.warn(`Could not serialize action type: ${e.type}`,t),{type:e.type,payload:`[Non-serializable payload for action: ${e.type}]`}}},Zk=({action:e,windowElement:t,whitelist:n})=>{if(t)try{const{type:r}=e;if(!n.some((({type:e})=>e===r||"*"===e)))return;const o=bK(e);t.postMessage(o,"*")}catch(e){ap.error("Failed to process or send message:",e)}},e3=({onMessage:e,whitelist:t,sourceWindow:n})=>{const r=r=>{const o=r.origin===window.location.origin,a=!n||r.source===n,i=r.data&&"object"==typeof r.data&&"type"in r.data,s=t.some((({type:e})=>e===r.data.type||"*"===e));!o&&a&&i&&s&&e(r.data)};return window.addEventListener("message",r),()=>{window.removeEventListener("message",r)}},Cm=()=>{try{return window.self!==window.top}catch{return!0}},b2=Vn("requestMicroFrontendFetch"),_K=Vn("sendMicroFrontendFetchResponse"),xK={deviceType:hH(),deviceWidth:window.innerWidth},t3=oo({name:"ui",initialState:xK,reducers:{},extraReducers:e=>{e.addCase(xH,((e,{payload:t})=>{e.deviceType=t})),e.addCase(SH,((e,{payload:t})=>{e.deviceWidth=t}))},selectors:{selectDeviceType:e=>e.deviceType,selectDeviceWidth:e=>e.deviceWidth,selectIsMobile:e=>"mobile"===e.deviceType,selectIsTablet:e=>"tablet"===e.deviceType,selectIsDesktop:e=>"desktop"===e.deviceType}});var Sx,_2,Ex,x2,$x,S2,Cx,E2,Ix,$2,Rx,C2,Px,I2,Tx,R2,Ox,P2,Ax,T2,Mx,O2,Dx,A2,Nx,M2,kx,D2,Lx,N2,Fx,k2,Bx,L2,jx,F2,zx,B2,Vx,j2,Ux,z2,Wx,V2,qx,U2,Gx,W2,Hx,q2,Kx,G2,Yx,H2,Qx,K2,Xx,Y2,Jx,Q2,Zx,X2,eS,J2,tS,Z2,nS,eO,rS,tO,oS,nO,iS,rO,aS,oO,sS,iO,uS,aO,lS,sO;function n3(){if(_2)return Sx;_2=1;var e=CM(),t=e&&new e;return Sx=t}function r3(){if(x2)return Ex;x2=1;var e=GE(),t=n3();return Ex=t?function(e,n){return t.set(e,n),e}:e}function Zy(){if(S2)return $x;S2=1;var e=Ny(),t=bs();return $x=function(n){return function(){var r=arguments;switch(r.length){case 0:return new n;case 1:return new n(r[0]);case 2:return new n(r[0],r[1]);case 3:return new n(r[0],r[1],r[2]);case 4:return new n(r[0],r[1],r[2],r[3]);case 5:return new n(r[0],r[1],r[2],r[3],r[4]);case 6:return new n(r[0],r[1],r[2],r[3],r[4],r[5]);case 7:return new n(r[0],r[1],r[2],r[3],r[4],r[5],r[6])}var o=e(n.prototype),a=n.apply(o,r);return t(a)?a:o}},$x}function SK(){if(E2)return Cx;E2=1;var e=Zy(),t=ri();return Cx=function(n,r,o){var a=1&r,i=e(n);return function e(){return(this&&this!==t&&this instanceof e?i:n).apply(a?o:this,arguments)}},Cx}function o3(){if($2)return Ix;$2=1;var e=Math.max;return Ix=function(t,n,r,o){for(var a=-1,i=t.length,s=r.length,u=-1,l=n.length,c=e(i-s,0),d=Array(l+c),f=!o;++u<l;)d[u]=n[u];for(;++a<s;)(f||a<i)&&(d[r[a]]=t[a]);for(;c--;)d[u++]=t[a++];return d}}function i3(){if(C2)return Rx;C2=1;var e=Math.max;return Rx=function(t,n,r,o){for(var a=-1,i=t.length,s=-1,u=r.length,l=-1,c=n.length,d=e(i-u,0),f=Array(d+c),p=!o;++a<d;)f[a]=t[a];for(var m=a;++l<c;)f[m+l]=n[l];for(;++s<u;)(p||a<i)&&(f[m+r[s]]=t[a++]);return f}}function EK(){if(I2)return Px;return I2=1,Px=function(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}}function U$(){if(R2)return Tx;return R2=1,Tx=function(){}}function W$(){if(P2)return Ox;P2=1;var e=Ny(),t=U$();function n(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}return n.prototype=e(t.prototype),n.prototype.constructor=n,Ox=n}function a3(){if(T2)return Ax;T2=1;var e=n3(),t=F9();return Ax=e?function(t){return e.get(t)}:t}function $K(){if(O2)return Mx;O2=1;return Mx={}}function CK(){if(A2)return Dx;A2=1;var e=$K(),t=Object.prototype.hasOwnProperty;return Dx=function(n){for(var r=n.name+"",o=e[r],a=t.call(e,r)?o.length:0;a--;){var i=o[a],s=i.func;if(null==s||s==n)return i.name}return r}}function s3(){if(M2)return Nx;M2=1;var e=Ny(),t=U$();function n(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}return n.prototype=e(t.prototype),n.prototype.constructor=n,Nx=n}function IK(){if(D2)return kx;D2=1;var e=W$(),t=s3(),n=Dy();return kx=function(r){if(r instanceof e)return r.clone();var o=new t(r.__wrapped__,r.__chain__);return o.__actions__=n(r.__actions__),o.__index__=r.__index__,o.__values__=r.__values__,o}}function RK(){if(N2)return Lx;N2=1;var e=W$(),t=s3(),n=U$(),r=Ei(),o=ta(),a=IK(),i=Object.prototype.hasOwnProperty;function s(n){if(o(n)&&!r(n)&&!(n instanceof e)){if(n instanceof t)return n;if(i.call(n,"__wrapped__"))return a(n)}return new t(n)}return s.prototype=n.prototype,s.prototype.constructor=s,Lx=s}function PK(){if(k2)return Fx;k2=1;var e=W$(),t=a3(),n=CK(),r=RK();return Fx=function(o){var a=n(o),i=r[a];if("function"!=typeof i||!(a in e.prototype))return!1;if(o===i)return!0;var s=t(i);return!!s&&o===s[0]}}function u3(){if(L2)return Bx;L2=1;var e=r3(),t=OM()(e);return Bx=t}function TK(){if(F2)return jx;F2=1;var e=/\{\n\/\* \[wrapped with (.+)\] \*/,t=/,? & /;return jx=function(n){var r=n.match(e);return r?r[1].split(t):[]}}function OK(){if(B2)return zx;B2=1;var e=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;return zx=function(t,n){var r=n.length;if(!r)return t;var o=r-1;return n[o]=(r>1?"& ":"")+n[o],n=n.join(r>2?", ":" "),t.replace(e,"{\n/* [wrapped with "+n+"] */\n")}}function AK(){if(j2)return Vx;j2=1;var e=YE(),t=L9(),n=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]];return Vx=function(r,o){return e(n,(function(e){var n="_."+e[0];o&e[1]&&!t(r,n)&&r.push(n)})),r.sort()}}function l3(){if(z2)return Ux;z2=1;var e=TK(),t=OK(),n=AM(),r=AK();return Ux=function(o,a,i){var s=a+"";return n(o,t(s,r(e(s),i)))}}function c3(){if(V2)return Wx;V2=1;var e=PK(),t=u3(),n=l3();return Wx=function(r,o,a,i,s,u,l,c,d,f){var p=8&o;o|=p?32:64,4&(o&=~(p?64:32))||(o&=-4);var m=[r,o,s,p?u:void 0,p?l:void 0,p?void 0:u,p?void 0:l,c,d,f],v=a.apply(void 0,m);return e(r)&&t(v,m),v.placeholder=i,n(v,r,o)}}function d3(){if(U2)return qx;return U2=1,qx=function(e){return e.placeholder}}function MK(){if(W2)return Gx;W2=1;var e=Dy(),t=zE(),n=Math.min;return Gx=function(r,o){for(var a=r.length,i=n(o.length,a),s=e(r);i--;){var u=o[i];r[i]=t(u,a)?s[u]:void 0}return r}}function q$(){if(q2)return Hx;q2=1;var e="__lodash_placeholder__";return Hx=function(t,n){for(var r=-1,o=t.length,a=0,i=[];++r<o;){var s=t[r];(s===n||s===e)&&(t[r]=e,i[a++]=r)}return i}}function f3(){if(G2)return Kx;G2=1;var e=o3(),t=i3(),n=EK(),r=Zy(),o=c3(),a=d3(),i=MK(),s=q$(),u=ri();return Kx=function l(c,d,f,p,m,v,h,g,y,b){var w=128&d,x=1&d,_=2&d,E=24&d,S=512&d,I=_?void 0:r(c);return function A(){for(var k=arguments.length,C=Array(k),T=k;T--;)C[T]=arguments[T];if(E)var R=a(A),P=n(C,R);if(p&&(C=e(C,p,m,E)),v&&(C=t(C,v,h,E)),k-=P,E&&k<b){var O=s(C,R);return o(c,d,l,A.placeholder,f,C,O,g,y,b-k)}var N=x?f:this,M=_?N[c]:c;return k=C.length,g?C=i(C,g):S&&k>1&&C.reverse(),w&&y<k&&(C.length=y),this&&this!==u&&this instanceof A&&(M=I||r(M)),M.apply(N,C)}},Kx}function DK(){if(H2)return Yx;H2=1;var e=HE(),t=Zy(),n=f3(),r=c3(),o=d3(),a=q$(),i=ri();return Yx=function(s,u,l){var c=t(s);return function t(){for(var d=arguments.length,f=Array(d),p=d,m=o(t);p--;)f[p]=arguments[p];var v=d<3&&f[0]!==m&&f[d-1]!==m?[]:a(f,m);return(d-=v.length)<l?r(s,u,n,t.placeholder,void 0,f,v,void 0,void 0,l-d):e(this&&this!==i&&this instanceof t?c:s,this,f)}},Yx}function NK(){if(K2)return Qx;K2=1;var e=HE(),t=Zy(),n=ri();return Qx=function(r,o,a,i){var s=1&o,u=t(r);return function t(){for(var o=-1,l=arguments.length,c=-1,d=i.length,f=Array(d+l),p=this&&this!==n&&this instanceof t?u:r;++c<d;)f[c]=i[c];for(;l--;)f[c++]=arguments[++o];return e(p,s?a:this,f)}},Qx}function kK(){if(Y2)return Xx;Y2=1;var e=o3(),t=i3(),n=q$(),r="__lodash_placeholder__",o=128,a=Math.min;return Xx=function(i,s){var u=i[1],l=s[1],c=u|l,d=c<131,f=l==o&&8==u||l==o&&256==u&&i[7].length<=s[8]||384==l&&s[7].length<=s[8]&&8==u;if(!d&&!f)return i;1&l&&(i[2]=s[2],c|=1&u?0:4);var p=s[3];if(p){var m=i[3];i[3]=m?e(m,p,s[4]):p,i[4]=m?n(i[3],r):s[4]}return(p=s[5])&&(m=i[5],i[5]=m?t(m,p,s[6]):p,i[6]=m?n(i[5],r):s[6]),(p=s[7])&&(i[7]=p),l&o&&(i[8]=null==i[8]?s[8]:a(i[8],s[8])),null==i[9]&&(i[9]=s[9]),i[0]=s[0],i[1]=c,i}}function G$(){if(Q2)return Jx;Q2=1;var e=r3(),t=SK(),n=DK(),r=f3(),o=NK(),a=a3(),i=kK(),s=u3(),u=l3(),l=kM(),c=Math.max;return Jx=function(d,f,p,m,v,h,g,y){var b=2&f;if(!b&&"function"!=typeof d)throw new TypeError("Expected a function");var w=m?m.length:0;if(w||(f&=-97,m=v=void 0),g=void 0===g?g:c(l(g),0),y=void 0===y?y:l(y),w-=v?v.length:0,64&f){var x=m,_=v;m=v=void 0}var E=b?void 0:a(d),S=[d,f,p,m,v,x,_,h,g,y];if(E&&i(S,E),d=S[0],f=S[1],p=S[2],m=S[3],v=S[4],!(y=S[9]=void 0===S[9]?b?0:d.length:c(S[9]-w,0))&&24&f&&(f&=-25),f&&1!=f)I=8==f||16==f?n(d,f,y):32!=f&&33!=f||v.length?r.apply(void 0,S):o(d,f,p,m);else var I=t(d,f,p);return u((E?e:s)(I,S),d,f)}}function LK(){if(X2)return Zx;X2=1;var e=G$();return Zx=function(t,n,r){return n=r?void 0:n,n=t&&null==n?t.length:n,e(t,128,void 0,void 0,void 0,void 0,n)}}function FK(){if(J2)return eS;J2=1;var e=jM();return eS=function(t){return e(t,4)}}function BK(){if(Z2)return tS;Z2=1;var e=G$();function t(n,r,o){var a=e(n,8,void 0,void 0,void 0,void 0,void 0,r=o?void 0:r);return a.placeholder=t.placeholder,a}return t.placeholder={},tS=t}function jK(){if(eO)return nS;eO=1;var e=Cl(),t=ta(),n=iF();return nS=function(r){if(!t(r))return!1;var o=e(r);return"[object Error]"==o||"[object DOMException]"==o||"string"==typeof r.message&&"string"==typeof r.name&&!n(r)}}function zK(){if(tO)return rS;tO=1;var e=kv(),t=ta();return rS=function(n){return t(n)&&"[object WeakMap]"==e(n)}}function VK(){if(nO)return oS;nO=1;var e=jM(),t=A9();return oS=function(n){return t("function"==typeof n?n:e(n,1))}}function UK(){if(rO)return iS;rO=1;var e=G$(),t=CF(),n=t((function(t,n){return e(t,256,void 0,void 0,void 0,n)}));return iS=n}function WK(){if(oO)return aS;oO=1;var e=cM(),t=Dy(),n=Ei(),r=Dv(),o=lM(),a=Nv(),i=dM();return aS=function(s){return n(s)?e(s,a):r(s)?[s]:t(o(i(s)))}}function qK(){return iO||(iO=1,sS={ary:LK(),assign:FM(),clone:FK(),curry:BK(),forEach:YE(),isArray:Ei(),isError:jK(),isFunction:Iy(),isWeakMap:zK(),iteratee:VK(),keys:SM(),rearg:UK(),toInteger:kM(),toPath:WK()}),sS}function GK(){if(aO)return uS;aO=1;var e=nA(),t=qK();return uS=function(n,r,o){return e(t,n,r,o)}}function HK(){if(sO)return lS;sO=1;var e=GK()("debounce",DM());return e.placeholder=tA(),lS=e}function uO(e,t,n=window){const r=v.useRef(t);v.useEffect((()=>{r.current=t}),[t]),v.useEffect((()=>{if(!n)return;const t=e=>r.current(e);return n.addEventListener(e,t),()=>{n.removeEventListener(e,t)}}),[e,n])}HK();const KK=()=>vy(t3.selectors.selectIsMobile);function lO({className:e,...t}){return G.jsx("div",{className:we("animate-pulse rounded-md bg-muted",e),...t})}const YK="sidebar_state",QK=604800,XK="12rem",JK="18rem",ZK="2rem",eY="b",p3=v.createContext(null);function e0(){const e=v.useContext(p3);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const tY=v.forwardRef((({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:a,...i},s)=>{const u=KK(),[l,c]=v.useState(!1),[d,f]=v.useState(e),p=t??d,m=v.useCallback((e=>{const t="function"==typeof e?e(p):e;n?n(t):f(t),document.cookie=`${YK}=${t}; path=/; max-age=${QK}`}),[n,p]),h=v.useCallback((()=>u?c((e=>!e)):m((e=>!e))),[u,m,c]);v.useEffect((()=>{const e=e=>{e.key===eY&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),h())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)}),[h]);const g=p?"expanded":"collapsed",y=v.useMemo((()=>({state:g,open:p,setOpen:m,isMobile:u,openMobile:l,setOpenMobile:c,toggleSidebar:h})),[g,p,m,u,l,c,h]);return G.jsx(p3.Provider,{value:y,children:G.jsx(ZG,{delayDuration:0,children:G.jsx("div",{style:{"--sidebar-width":XK,"--sidebar-width-icon":ZK,...o},className:we("group/sidebar-wrapper flex min-h-svh w-full bg-gray-100 has-[[data-variant=inset]]:bg-sidebar",r),ref:s,...i,children:a})})})}));tY.displayName="SidebarProvider";const nY=v.forwardRef((({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...a},i)=>{const{isMobile:s,state:u,openMobile:l,setOpenMobile:c}=e0();return"none"===n?G.jsx("div",{className:we("flex h-full w-[--sidebar-width] flex-col bg-sidebar text-sidebar-foreground",r),ref:i,...a,children:o}):s?G.jsx(HG,{open:l,onOpenChange:c,children:G.jsxs(Fk,{"data-sidebar":"sidebar","data-mobile":"true",className:"w-[--sidebar-width] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":JK},side:e,children:[G.jsxs(Bk,{className:"sr-only",children:[G.jsx(jk,{children:"Sidebar"}),G.jsx(zk,{children:"Displays the mobile sidebar."})]}),G.jsx("div",{className:"flex h-full w-full flex-col",children:o})]})}):G.jsxs("div",{ref:i,className:"group peer hidden text-sidebar-foreground md:block","data-state":u,"data-collapsible":"collapsed"===u?n:"","data-variant":t,"data-side":e,children:[G.jsx("div",{className:we("relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180","floating"===t||"inset"===t?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),G.jsx("div",{className:we("fixed inset-y-0 z-10 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear md:flex","left"===e?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]","floating"===t||"inset"===t?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",r),...a,children:G.jsx("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-sm group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow",children:o})})]})}));nY.displayName="Sidebar";const rY=v.forwardRef((({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o,open:a}=e0();return G.jsx(yy,{ref:r,"data-sidebar":"trigger",variant:"tertiary",size:"icon_m",className:we("size-6 text-gray-900",e),onClick:e=>{null==t||t(e),o()},...n,children:a?G.jsx(Y5,{size:16}):G.jsx(H5,{size:16})})}));rY.displayName="SidebarTrigger";const oY=v.forwardRef((({className:e,...t},n)=>{const{toggleSidebar:r}=e0();return G.jsx("button",{ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:we("absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...t})}));oY.displayName="SidebarRail";const iY=v.forwardRef((({className:e,...t},n)=>G.jsx("main",{ref:n,className:we("relative flex w-full flex-1 flex-col bg-background","md:peer-data-[variant=inset]:m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-m md:peer-data-[variant=inset]:shadow",e),...t})));iY.displayName="SidebarInset";const aY=v.forwardRef((({className:e,...t},n)=>G.jsx(xk,{ref:n,"data-sidebar":"input",className:we("h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",e),...t})));aY.displayName="SidebarInput";const sY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"header",className:we("flex flex-col gap-xxs p-xs",e),...t})));sY.displayName="SidebarHeader";const uY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"footer",className:we("flex flex-col gap-2 p-2",e),...t})));uY.displayName="SidebarFooter";const lY=v.forwardRef((({className:e,...t},n)=>G.jsx(S$,{ref:n,"data-sidebar":"separator",className:we("mx-2 w-auto bg-sidebar-border",e),...t})));lY.displayName="SidebarSeparator";const cY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"content",className:we("flex min-h-0 flex-1 flex-col gap-xxxs overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...t})));cY.displayName="SidebarContent";const dY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"group",className:we("relative flex w-full min-w-0 flex-col pt-xs",e),...t})));dY.displayName="SidebarGroup";const fY=v.forwardRef((({className:e,asChild:t=!1,...n},r)=>{const o=t?yd:"div";return G.jsx(o,{ref:r,"data-sidebar":"group-label",className:we("flex h-s shrink-0 items-center rounded-md px-xxs py-xxs text-xs font-semibold text-gray-700 opacity-60 outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-xl group-data-[collapsible=icon]:opacity-0",e),...n})}));fY.displayName="SidebarGroupLabel";const pY=v.forwardRef((({className:e,asChild:t=!1,...n},r)=>{const o=t?yd:"button";return G.jsx(o,{ref:r,"data-sidebar":"group-action",className:we("absolute right-xs top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","group-data-[collapsible=icon]:hidden",e),...n})}));pY.displayName="SidebarGroupAction";const mY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"group-content",className:we("w-full text-sm",e),...t})));mY.displayName="SidebarGroupContent";const hY=v.forwardRef((({className:e,...t},n)=>G.jsx("ul",{ref:n,"data-sidebar":"menu",className:we("flex w-full min-w-0 flex-col p-xs font-semibold text-gray-700 [&_svg]:size-4",e),...t})));hY.displayName="SidebarMenu";const vY=v.forwardRef((({className:e,...t},n)=>G.jsx("li",{ref:n,"data-sidebar":"menu-item",className:we("group/menu-item relative",e),...t})));vY.displayName="SidebarMenuItem";const gY=gu("peer/menu-button flex w-full items-center gap-xxs overflow-hidden rounded-sm p-xxs text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:text-blue_100 hover:bg-white focus-visible:ring-2 active:bg-white active:text-blue_100 disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-white data-[active=true]:font-medium data-[active=true]:text-blue_100 data-[state=open]:hover:bg-white data-[state=open]:hover:text-blue_100 group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:text-blue_100 hover:bg-white",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-white hover:text-blue_100 hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-s text-sm",sm:"h-m text-xs",lg:"h-l text-sm group-data-[collapsible=icon]:!p-0"}},defaultVariants:{variant:"default",size:"default"}}),yY=v.forwardRef((({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:a,...i},s)=>{const u=e?yd:"button",{isMobile:l,state:c}=e0(),d=G.jsx(u,{ref:s,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:we(gY({variant:n,size:r}),a),...i});return o?("string"==typeof o&&(o={children:o}),G.jsxs(tH,{children:[G.jsx(nH,{asChild:!0,children:d}),G.jsx(Uk,{side:"right",align:"center",hidden:"collapsed"!==c||l,...o})]})):d}));yY.displayName="SidebarMenuButton";const wY=v.forwardRef((({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const a=t?yd:"button";return G.jsx(a,{ref:o,"data-sidebar":"menu-action",className:we("absolute right-xxxs top-xxs flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","peer-data-[size=sm]/menu-button:top-xxxs","peer-data-[size=default]/menu-button:top-xxs","peer-data-[size=lg]/menu-button:top-xs","group-data-[collapsible=icon]:hidden",n&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground md:opacity-0",e),...r})}));wY.displayName="SidebarMenuAction";const bY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:we("pointer-events-none absolute right-xxxs flex h-m min-w-5 select-none items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-xxxs","peer-data-[size=default]/menu-button:top-xxs","peer-data-[size=lg]/menu-button:top-xs","group-data-[collapsible=icon]:hidden",e),...t})));bY.displayName="SidebarMenuBadge";const _Y=v.forwardRef((({className:e,showIcon:t=!1,...n},r)=>{const o=v.useMemo((()=>`${Math.floor(40*Math.random())+50}%`),[]);return G.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:we("flex h-8 items-center gap-xxs rounded-md px-xxs",e),...n,children:[t&&G.jsx(lO,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),G.jsx(lO,{className:"h-xxxs max-w-[--skeleton-width] flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})}));_Y.displayName="SidebarMenuSkeleton";const xY=v.forwardRef((({className:e,...t},n)=>G.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:we("flex min-w-0 translate-x-px flex-col gap-xxxs border-l border-sidebar-border","group-data-[collapsible=icon]:hidden",e),...t})));xY.displayName="SidebarMenuSub";const SY=v.forwardRef((({...e},t)=>G.jsx("li",{ref:t,...e})));SY.displayName="SidebarMenuSubItem";const EY=v.forwardRef((({asChild:e=!1,size:t="md",isActive:n,className:r,...o},a)=>{const i=e?yd:"a";return G.jsx(i,{ref:a,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:we("flex h-s min-w-0 -translate-x-px items-center gap-xxs overflow-hidden rounded-sm px-xxs text-sm text-gray-700 outline-none ring-sidebar-ring hover:bg-white hover:text-blue_100 focus-visible:ring-2 active:bg-white active:text-blue_100 disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-blue_100","data-[active=true]:bg-white data-[active=true]:text-blue_100","sm"===t&&"text-xs","md"===t&&"text-sm","group-data-[collapsible=icon]:hidden",r),...o})}));EY.displayName="SidebarMenuSubButton";const m3="Switch",[$Y,lZ]=ni(m3),[CY,IY]=$Y(m3),RY=v.forwardRef(((e,t)=>{const{__scopeSwitch:n,name:r,checked:o,defaultChecked:a,required:i,disabled:s,value:u="on",onCheckedChange:l,...c}=e,[d,f]=v.useState(null),p=Vt(t,(e=>f(e))),m=v.useRef(!1),h=!d||!!d.closest("form"),[g=!1,y]=fd({prop:o,defaultProp:a,onChange:l});return v.createElement(CY,{scope:n,checked:g,disabled:s},v.createElement(ft.button,Te({type:"button",role:"switch","aria-checked":g,"aria-required":i,"data-state":h3(g),"data-disabled":s?"":void 0,disabled:s,value:u},c,{ref:p,onClick:et(e.onClick,(e=>{y((e=>!e)),h&&(m.current=e.isPropagationStopped(),m.current||e.stopPropagation())}))})),h&&v.createElement(OY,{control:d,bubbles:!m.current,name:r,value:u,checked:g,required:i,disabled:s,style:{transform:"translateX(-100%)"}}))})),PY="SwitchThumb",TY=v.forwardRef(((e,t)=>{const{__scopeSwitch:n,...r}=e,o=IY(PY,n);return v.createElement(ft.span,Te({"data-state":h3(o.checked),"data-disabled":o.disabled?"":void 0},r,{ref:t}))})),OY=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,a=v.useRef(null),i=ky(n),s=Ly(t);return v.useEffect((()=>{const e=a.current,t=window.HTMLInputElement.prototype,o=Object.getOwnPropertyDescriptor(t,"checked").set;if(i!==n&&o){const t=new Event("click",{bubbles:r});o.call(e,n),e.dispatchEvent(t)}}),[i,n,r]),v.createElement("input",Te({type:"checkbox","aria-hidden":!0,defaultChecked:n},o,{tabIndex:-1,ref:a,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function h3(e){return e?"checked":"unchecked"}const v3=RY,AY=TY,MY=v.forwardRef((({className:e,...t},n)=>G.jsx(v3,{className:we("group peer inline-flex h-xs w-[44px] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background data-[state=checked]:bg-blue_100 data-[state=unchecked]:bg-gray-200","disabled:cursor-not-allowed disabled:!bg-gray-100 md:hover:data-[state=checked]:bg-blue_120 md:hover:data-[state=unchecked]:!bg-gray-300",e),...t,ref:n,children:G.jsx(AY,{className:we("pointer-events-none block size-xxs rounded-full bg-background shadow-lg ring-0 transition-[transform,width] data-[state=checked]:translate-x-[20px] data-[state=unchecked]:translate-x-0",{"md:group-hover:w-[26px] md:group-hover:data-[state=checked]:translate-x-[14px]":!t.disabled,"bg-gray-300":t.disabled})})})));MY.displayName=v3.displayName;var DY={USER:"teamcity",npm_config_user_agent:"npm/10.9.3 node/v22.18.0 linux x64 workspaces/true",SENTRY_AUTH_TOKEN:"1d93ff28a44e4c3aaaaff854277cd8583c1de670bd8744bc895670dfd9300840",npm_node_execpath:"/home/teamcity/.nvm/versions/node/v22.18.0/bin/node",npm_config_noproxy:"",HOME:"/home/teamcity",npm_package_json:"/mnt/agent/work/70fcd8585843667f/packages/network/package.json",npm_config_userconfig:"/home/teamcity/.npmrc",npm_config_local_prefix:"/mnt/agent/work/70fcd8585843667f",COLOR:"1",npm_config_progress:"",TEMP:"/mnt/agent/temp/buildTmp",npm_config_prefix:"/home/teamcity/.nvm/versions/node/v22.18.0",npm_config_npm_version:"10.9.3",npm_config_cache:"/home/teamcity/.npm",USE_NPM_LIBS:"false",npm_config_ignore_scripts:"true",npm_config_node_gyp:"/home/teamcity/.nvm/versions/node/v22.18.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js",PATH:"/mnt/agent/work/70fcd8585843667f/packages/network/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/packages/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.18.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.18.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/home/teamcity/.cargo/bin:/home/teamcity/.rvm/gems/ruby-3.3.9/bin:/home/teamcity/.rvm/gems/ruby-3.3.9@global/bin:/home/teamcity/.rvm/rubies/ruby-3.3.9/bin:/home/teamcity/.rvm/bin:/home/teamcity/.local/bin:/usr/lib/jvm/java-21-amazon-corretto/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin:/usr/share/dotnet:/usr/share/dotnet/tools:/home/teamcity/google-cloud-sdk/bin:/home/teamcity/go/bin:/usr/bin/mvn:/home/teamcity/.nvm/versions/node/v22.18.0/bin",TURBO_HASH:"1649a1420aff6e12",NODE:"/home/teamcity/.nvm/versions/node/v22.18.0/bin/node",npm_package_name:"@wellesley/network",npm_config_color:"always",DOMAIN_ENV:"test",LANG:"en_US.UTF-8",TURBO_TEAM:"wellesley",TMP:"/mnt/agent/temp/buildTmp",TURBO_API:"https://turborepo-remote-cache-fo3np.ondigitalocean.app",npm_lifecycle_script:"vite build",SHELL:"/bin/bash",npm_package_version:"1.0.702",npm_lifecycle_event:"build",TURBO_CACHE:"remote:rw",SENTRY_MAPS_UPLOAD:"true",npm_config_globalconfig:"/home/teamcity/.nvm/versions/node/v22.18.0/etc/npmrc",npm_config_init_module:"/home/teamcity/.npm-init.js",PWD:"/mnt/agent/work/70fcd8585843667f/packages/network",npm_execpath:"/home/teamcity/.nvm/versions/node/v22.18.0/lib/node_modules/npm/bin/npm-cli.js",npm_config_global_prefix:"/home/teamcity/.nvm/versions/node/v22.18.0",npm_command:"run-script",TURBO_TOKEN:"wellesley-turbo-token",USE_PACKAGES_FROM_NPM:"false",INIT_CWD:"/mnt/agent/work/70fcd8585843667f/packages/network",EDITOR:"vi",NODE_ENV:"production",BUILD_NUMBER:"3785",APP_NAME:"@wellesley/network"},g3=(e=>(e.uninitialized="uninitialized",e.pending="pending",e.fulfilled="fulfilled",e.rejected="rejected",e))(g3||{});function NY(e){return{status:e,isUninitialized:"uninitialized"===e,isLoading:"pending"===e,isSuccess:"fulfilled"===e,isError:"rejected"===e}}function kY(e){return new RegExp("(^|:)//").test(e)}var LY=e=>e.replace(/\/$/,""),FY=e=>e.replace(/^\//,"");function BY(e,t){if(!e)return t;if(!t)return e;if(kY(t))return t;const n=e.endsWith("/")||!t.startsWith("?")?"/":"";return`${e=LY(e)}${n}${t=FY(t)}`}var cO=e=>[].concat(...e);function jY(){return typeof navigator>"u"||void 0===navigator.onLine||navigator.onLine}function zY(){return typeof document>"u"||"hidden"!==document.visibilityState}var dO=ld;function y3(e,t){if(e===t||!(dO(e)&&dO(t)||Array.isArray(e)&&Array.isArray(t)))return t;const n=Object.keys(t),r=Object.keys(e);let o=n.length===r.length;const a=Array.isArray(t)?[]:{};for(const r of n)a[r]=y3(e[r],t[r]),o&&(o=e[r]===a[r]);return o?e:a}var fO=(...e)=>fetch(...e),VY=e=>e.status>=200&&e.status<=299,UY=e=>/ion\/(vnd\.api\+)?json/.test(e.get("content-type")||"");function pO(e){if(!ld(e))return e;const t={...e};for(const[e,n]of Object.entries(t))void 0===n&&delete t[e];return t}function WY({baseUrl:e,prepareHeaders:t=e=>e,fetchFn:n=fO,paramsSerializer:r,isJsonContentType:o=UY,jsonContentType:a="application/json",jsonReplacer:i,timeout:s,responseHandler:u,validateStatus:l,...c}={}){return typeof fetch>"u"&&n===fO&&console.warn("Warning: `fetch` is not available. Please supply a custom `fetchFn` property to use `fetchBaseQuery` on SSR environments."),async(f,p)=>{const{signal:m,getState:v,extra:h,endpoint:g,forced:y,type:b}=p;let w,{url:x,headers:_=new Headers(c.headers),params:E,responseHandler:S=u??"json",validateStatus:I=l??VY,timeout:A=s,...k}="string"==typeof f?{url:f}:f,C={...c,signal:m,...k};_=new Headers(pO(_)),C.headers=await t(_,{getState:v,extra:h,endpoint:g,forced:y,type:b})||_;const T=e=>"object"==typeof e&&(ld(e)||Array.isArray(e)||"function"==typeof e.toJSON);if(!C.headers.has("content-type")&&T(C.body)&&C.headers.set("content-type",a),T(C.body)&&o(C.headers)&&(C.body=JSON.stringify(C.body,i)),E){const e=~x.indexOf("?")?"&":"?";x+=e+(r?r(E):new URLSearchParams(pO(E)))}x=BY(e,x);const R=new Request(x,C);w={request:new Request(x,C)};let P,O=!1,N=A&&setTimeout((()=>{O=!0,p.abort()}),A);try{P=await n(R)}catch(e){return{error:{status:O?"TIMEOUT_ERROR":"FETCH_ERROR",error:String(e)},meta:w}}finally{N&&clearTimeout(N)}const M=P.clone();w.response=M;let j,D="";try{let e;if(await Promise.all([d(P,S).then((e=>j=e),(t=>e=t)),M.text().then((e=>D=e),(()=>{}))]),e)throw e}catch(e){return{error:{status:"PARSING_ERROR",originalStatus:P.status,data:D,error:String(e)},meta:w}}return I(P,j)?{data:j,meta:w}:{error:{status:P.status,data:j},meta:w}};async function d(e,t){if("function"==typeof t)return t(e);if("content-type"===t&&(t=o(e.headers)?"json":"text"),"json"===t){const t=await e.text();return t.length?JSON.parse(t):null}return e.text()}}var mO=class{constructor(e,t=void 0){this.value=e,this.meta=t}},H$=Vn("__rtkq/focused"),w3=Vn("__rtkq/unfocused"),K$=Vn("__rtkq/online"),b3=Vn("__rtkq/offline");function _3(e){return"query"===e.type}function qY(e){return"mutation"===e.type}function Y$(e,t,n,r,o,a){return GY(e)?e(t,n,r,o).map(oE).map(a):Array.isArray(e)?e.map(oE).map(a):[]}function GY(e){return"function"==typeof e}function oE(e){return"string"==typeof e?{type:e}:e}function hO(e){return null!=e}function Om(e){let t=0;for(const n in e)t++;return t}function HY(e,t){return e.catch(t)}var $v=Symbol("forceQueryFn"),iE=e=>"function"==typeof e[$v];function KY({serializeQueryArgs:e,queryThunk:t,mutationThunk:n,api:r,context:o}){const a=new Map,i=new Map,{unsubscribeQueryResult:s,removeMutationResult:u,updateSubscriptionOptions:l}=r.internalActions;return{buildInitiateQuery:function(n,o){const i=(u,{subscribe:c=!0,forceRefetch:d,subscriptionOptions:f,[$v]:p,...m}={})=>(v,h)=>{var g;const y=e({queryArgs:u,endpointDefinition:o,endpointName:n}),b=t({...m,type:"query",subscribe:c,forceRefetch:d,subscriptionOptions:f,endpointName:n,originalArgs:u,queryCacheKey:y,[$v]:p}),w=r.endpoints[n].select(u),x=v(b),_=w(h()),{requestId:E,abort:S}=x,I=_.requestId!==E,A=null==(g=a.get(v))?void 0:g[y],k=()=>w(h()),C=Object.assign(p?x.then(k):I&&!A?Promise.resolve(_):Promise.all([A,x]).then(k),{arg:u,requestId:E,subscriptionOptions:f,queryCacheKey:y,abort:S,async unwrap(){const e=await C;if(e.isError)throw e.error;return e.data},refetch:()=>v(i(u,{subscribe:!1,forceRefetch:!0})),unsubscribe(){c&&v(s({queryCacheKey:y,requestId:E}))},updateSubscriptionOptions(e){C.subscriptionOptions=e,v(l({endpointName:n,requestId:E,queryCacheKey:y,options:e}))}});if(!A&&!I&&!p){const e=a.get(v)||{};e[y]=C,a.set(v,e),C.then((()=>{delete e[y],Om(e)||a.delete(v)}))}return C};return i},buildInitiateMutation:function(e){return(t,{track:r=!0,fixedCacheKey:o}={})=>(a,s)=>{const l=n({type:"mutation",endpointName:e,originalArgs:t,track:r,fixedCacheKey:o}),c=a(l),{requestId:d,abort:f,unwrap:p}=c,m=HY(c.unwrap().then((e=>({data:e}))),(e=>({error:e}))),v=Object.assign(m,{arg:c.arg,requestId:d,abort:f,unwrap:p,reset:()=>{a(u({requestId:d,fixedCacheKey:o}))}}),h=i.get(a)||{};return i.set(a,h),h[d]=v,v.then((()=>{delete h[d],Om(h)||i.delete(a)})),o&&(h[o]=v,v.then((()=>{h[o]===v&&(delete h[o],Om(h)||i.delete(a))}))),v}},getRunningQueryThunk:function(t,n){return r=>{var i;const s=o.endpointDefinitions[t],u=e({queryArgs:n,endpointDefinition:s,endpointName:t});return null==(i=a.get(r))?void 0:i[u]}},getRunningMutationThunk:function(e,t){return e=>{var n;return null==(n=i.get(e))?void 0:n[t]}},getRunningQueriesThunk:function(){return e=>Object.values(a.get(e)||{}).filter(hO)},getRunningMutationsThunk:function(){return e=>Object.values(i.get(e)||{}).filter(hO)}}}function vO(e){return e}function YY({reducerPath:e,baseQuery:t,context:{endpointDefinitions:n},serializeQueryArgs:r,api:o,assertTagType:a}){const i=async(e,{signal:r,abort:o,rejectWithValue:a,fulfillWithValue:i,dispatch:u,getState:l,extra:c})=>{const d=n[e.endpointName];try{let n,a=vO;const f={signal:r,abort:o,dispatch:u,getState:l,extra:c,endpoint:e.endpointName,type:e.type,forced:"query"===e.type?s(e,l()):void 0},p="query"===e.type?e[$v]:void 0;if(p?n=p():d.query?(n=await t(d.query(e.originalArgs),f,d.extraOptions),d.transformResponse&&(a=d.transformResponse)):n=await d.queryFn(e.originalArgs,f,d.extraOptions,(e=>t(e,f,d.extraOptions))),typeof process<"u"&&DY.NODE_ENV,n.error)throw new mO(n.error,n.meta);return i(await a(n.data,n.meta,e.originalArgs),{fulfilledTimeStamp:Date.now(),baseQueryMeta:n.meta,[Yh]:!0})}catch(t){let n=t;if(n instanceof mO){let t=vO;d.query&&d.transformErrorResponse&&(t=d.transformErrorResponse);try{return a(await t(n.value,n.meta,e.originalArgs),{baseQueryMeta:n.meta,[Yh]:!0})}catch(e){n=e}}throw console.error(n),n}};function s(t,n){var r,o,a;const i=null==(o=null==(r=n[e])?void 0:r.queries)?void 0:o[t.queryCacheKey],s=null==(a=n[e])?void 0:a.config.refetchOnMountOrArgChange,u=null==i?void 0:i.fulfilledTimeStamp,l=t.forceRefetch??(t.subscribe&&s);return!!l&&(!0===l||(Number(new Date)-Number(u))/1e3>=l)}const u=vC(`${e}/executeQuery`,i,{getPendingMeta:()=>({startedTimeStamp:Date.now(),[Yh]:!0}),condition(t,{getState:r}){var o,a,i;const u=r(),l=null==(a=null==(o=u[e])?void 0:o.queries)?void 0:a[t.queryCacheKey],c=null==l?void 0:l.fulfilledTimeStamp,d=t.originalArgs,f=null==l?void 0:l.originalArgs,p=n[t.endpointName];return!!iE(t)||"pending"!==(null==l?void 0:l.status)&&(!!(s(t,u)||_3(p)&&null!=(i=null==p?void 0:p.forceRefetch)&&i.call(p,{currentArg:d,previousArg:f,endpointState:l,state:u}))||!c)},dispatchConditionRejection:!0}),l=vC(`${e}/executeMutation`,i,{getPendingMeta:()=>({startedTimeStamp:Date.now(),[Yh]:!0})});function c(e){return t=>{var n,r;return(null==(r=null==(n=null==t?void 0:t.meta)?void 0:n.arg)?void 0:r.endpointName)===e}}return{queryThunk:u,mutationThunk:l,prefetch:(e,t,n)=>(r,a)=>{const i=(e=>"force"in e)(n)&&n.force,s=(e=>"ifOlderThan"in e)(n)&&n.ifOlderThan,u=(n=!0)=>{const r={forceRefetch:n,isPrefetch:!0};return o.endpoints[e].initiate(t,r)},l=o.endpoints[e].select(t)(a());if(i)r(u());else if(s){const e=null==l?void 0:l.fulfilledTimeStamp;if(!e)return void r(u());(Number(new Date)-Number(new Date(e)))/1e3>=s&&r(u())}else r(u(!1))},updateQueryData:(e,t,n,r=!0)=>(a,i)=>{const s=o.endpoints[e].select(t)(i());let u,l={patches:[],inversePatches:[],undo:()=>a(o.util.patchQueryData(e,t,l.inversePatches,r))};if("uninitialized"===s.status)return l;if("data"in s)if(ys(s.data)){const[e,t,r]=GO(s.data,n);l.patches.push(...t),l.inversePatches.push(...r),u=e}else u=n(s.data),l.patches.push({op:"replace",path:[],value:u}),l.inversePatches.push({op:"replace",path:[],value:s.data});return a(o.util.patchQueryData(e,t,l.patches,r)),l},upsertQueryData:(e,t,n)=>r=>r(o.endpoints[e].initiate(t,{subscribe:!1,forceRefetch:!0,[$v]:()=>({data:n})})),patchQueryData:(e,t,i,s)=>(u,l)=>{const c=n[e],d=r({queryArgs:t,endpointDefinition:c,endpointName:e});if(u(o.internalActions.queryResultPatched({queryCacheKey:d,patches:i})),!s)return;const f=o.endpoints[e].select(t)(l()),p=Y$(c.providesTags,f.data,void 0,t,{},a);u(o.internalActions.updateProvidedBy({queryCacheKey:d,providedTags:p}))},buildMatchThunkActions:function(e,t){return{matchPending:nv(dE(e),c(t)),matchFulfilled:nv(dd(e),c(t)),matchRejected:nv(Mm(e),c(t))}}}}function x3(e,t,n,r){return Y$(n[e.meta.arg.endpointName][t],dd(e)?e.payload:void 0,py(e)?e.payload:void 0,e.meta.arg.originalArgs,"baseQueryMeta"in e.meta?e.meta.baseQueryMeta:void 0,r)}function kg(e,t,n){const r=e[t];r&&n(r)}function Cv(e){return("arg"in e?e.arg.fixedCacheKey:e.fixedCacheKey)??e.requestId}function gO(e,t,n){const r=e[Cv(t)];r&&n(r)}var Hh={};function QY({reducerPath:e,queryThunk:t,mutationThunk:n,context:{endpointDefinitions:r,apiUid:o,extractRehydrationInfo:a,hasRehydrationInfo:i},assertTagType:s,config:u}){const l=Vn(`${e}/resetApiState`),c=oo({name:`${e}/queries`,initialState:Hh,reducers:{removeQueryResult:{reducer(e,{payload:{queryCacheKey:t}}){delete e[t]},prepare:jh()},queryResultPatched:{reducer(e,{payload:{queryCacheKey:t,patches:n}}){kg(e,t,(e=>{e.data=dC(e.data,n.concat())}))},prepare:jh()}},extraReducers(e){e.addCase(t.pending,((e,{meta:t,meta:{arg:n}})=>{var r;const o=iE(n);e[r=n.queryCacheKey]??(e[r]={status:"uninitialized",endpointName:n.endpointName}),kg(e,n.queryCacheKey,(e=>{e.status="pending",e.requestId=o&&e.requestId?e.requestId:t.requestId,void 0!==n.originalArgs&&(e.originalArgs=n.originalArgs),e.startedTimeStamp=t.startedTimeStamp}))})).addCase(t.fulfilled,((e,{meta:t,payload:n})=>{kg(e,t.arg.queryCacheKey,(e=>{if(e.requestId!==t.requestId&&!iE(t.arg))return;const{merge:o}=r[t.arg.endpointName];if(e.status="fulfilled",o)if(void 0!==e.data){const{fulfilledTimeStamp:r,arg:a,baseQueryMeta:i,requestId:s}=t;let u=Pv(e.data,(e=>o(e,n,{arg:a.originalArgs,baseQueryMeta:i,fulfilledTimeStamp:r,requestId:s})));e.data=u}else e.data=n;else e.data=r[t.arg.endpointName].structuralSharing??1?y3(gs(e.data)?Z3(e.data):e.data,n):n;delete e.error,e.fulfilledTimeStamp=t.fulfilledTimeStamp}))})).addCase(t.rejected,((e,{meta:{condition:t,arg:n,requestId:r},error:o,payload:a})=>{kg(e,n.queryCacheKey,(e=>{if(!t){if(e.requestId!==r)return;e.status="rejected",e.error=a??o}}))})).addMatcher(i,((e,t)=>{const{queries:n}=a(t);for(const[t,r]of Object.entries(n))("fulfilled"===(null==r?void 0:r.status)||"rejected"===(null==r?void 0:r.status))&&(e[t]=r)}))}}),d=oo({name:`${e}/mutations`,initialState:Hh,reducers:{removeMutationResult:{reducer(e,{payload:t}){const n=Cv(t);n in e&&delete e[n]},prepare:jh()}},extraReducers(e){e.addCase(n.pending,((e,{meta:t,meta:{requestId:n,arg:r,startedTimeStamp:o}})=>{r.track&&(e[Cv(t)]={requestId:n,status:"pending",endpointName:r.endpointName,startedTimeStamp:o})})).addCase(n.fulfilled,((e,{payload:t,meta:n})=>{n.arg.track&&gO(e,n,(e=>{e.requestId===n.requestId&&(e.status="fulfilled",e.data=t,e.fulfilledTimeStamp=n.fulfilledTimeStamp)}))})).addCase(n.rejected,((e,{payload:t,error:n,meta:r})=>{r.arg.track&&gO(e,r,(e=>{e.requestId===r.requestId&&(e.status="rejected",e.error=t??n)}))})).addMatcher(i,((e,t)=>{const{mutations:n}=a(t);for(const[t,r]of Object.entries(n))("fulfilled"===(null==r?void 0:r.status)||"rejected"===(null==r?void 0:r.status))&&t!==(null==r?void 0:r.requestId)&&(e[t]=r)}))}}),f=oo({name:`${e}/invalidation`,initialState:Hh,reducers:{updateProvidedBy:{reducer(e,t){var n,r;const{queryCacheKey:o,providedTags:a}=t.payload;for(const t of Object.values(e))for(const e of Object.values(t)){const t=e.indexOf(o);-1!==t&&e.splice(t,1)}for(const{type:t,id:i}of a){const a=(n=e[t]??(e[t]={}))[r=i||"__internal_without_id"]??(n[r]=[]);a.includes(o)||a.push(o)}},prepare:jh()}},extraReducers(e){e.addCase(c.actions.removeQueryResult,((e,{payload:{queryCacheKey:t}})=>{for(const n of Object.values(e))for(const e of Object.values(n)){const n=e.indexOf(t);-1!==n&&e.splice(n,1)}})).addMatcher(i,((e,t)=>{var n,r;const{provided:o}=a(t);for(const[t,a]of Object.entries(o))for(const[o,i]of Object.entries(a)){const a=(n=e[t]??(e[t]={}))[r=o||"__internal_without_id"]??(n[r]=[]);for(const e of i)a.includes(e)||a.push(e)}})).addMatcher(cd(dd(t),py(t)),((e,t)=>{const n=x3(t,"providesTags",r,s),{queryCacheKey:o}=t.meta.arg;f.caseReducers.updateProvidedBy(e,f.actions.updateProvidedBy({queryCacheKey:o,providedTags:n}))}))}}),p=oo({name:`${e}/subscriptions`,initialState:Hh,reducers:{updateSubscriptionOptions(e,t){},unsubscribeQueryResult(e,t){},internal_getRTKQSubscriptions(){}}}),m=oo({name:`${e}/internalSubscriptions`,initialState:Hh,reducers:{subscriptionsUpdated:{reducer:(e,t)=>dC(e,t.payload),prepare:jh()}}}),v=oo({name:`${e}/config`,initialState:{online:jY(),focused:zY(),middlewareRegistered:!1,...u},reducers:{middlewareRegistered(e,{payload:t}){e.middlewareRegistered="conflict"!==e.middlewareRegistered&&o===t||"conflict"}},extraReducers:e=>{e.addCase(K$,(e=>{e.online=!0})).addCase(b3,(e=>{e.online=!1})).addCase(H$,(e=>{e.focused=!0})).addCase(w3,(e=>{e.focused=!1})).addMatcher(i,(e=>({...e})))}}),h=FO({queries:c.reducer,mutations:d.reducer,provided:f.reducer,subscriptions:m.reducer,config:v.reducer});return{reducer:(e,t)=>h(l.match(t)?void 0:e,t),actions:{...v.actions,...c.actions,...p.actions,...m.actions,...d.actions,...f.actions,resetApiState:l}}}var Ff=Symbol.for("RTKQ/skipToken"),S3={status:"uninitialized"},yO=Pv(S3,(()=>{})),wO=Pv(S3,(()=>{}));function XY({serializeQueryArgs:e,reducerPath:t,createSelector:n}){const r=e=>yO,o=e=>wO;return{buildQuerySelector:function(t,o){return s=>{const u=e({queryArgs:s,endpointDefinition:o,endpointName:t});return n(s===Ff?r:e=>{var t,n;return(null==(n=null==(t=i(e))?void 0:t.queries)?void 0:n[u])??yO},a)}},buildMutationSelector:function(){return e=>{let t;return t="object"==typeof e?Cv(e)??Ff:e,n(t===Ff?o:e=>{var n,r;return(null==(r=null==(n=i(e))?void 0:n.mutations)?void 0:r[t])??wO},a)}},selectInvalidatedBy:function(e,n){const r=e[t],o=new Set;for(const e of n.map(oE)){const t=r.provided[e.type];if(!t)continue;let n=(void 0!==e.id?t[e.id]:cO(Object.values(t)))??[];for(const e of n)o.add(e)}return cO(Array.from(o.values()).map((e=>{const t=r.queries[e];return t?[{queryCacheKey:e,endpointName:t.endpointName,originalArgs:t.originalArgs}]:[]})))},selectCachedArgsForQuery:function(e,n){return Object.values(e[t].queries).filter((e=>(null==e?void 0:e.endpointName)===n&&"uninitialized"!==e.status)).map((e=>e.originalArgs))}};function a(e){return{...e,...NY(e.status)}}function i(e){return e[t]}}var Sm=WeakMap?new WeakMap:void 0,bO=({endpointName:e,queryArgs:t})=>{let n="";const r=null==Sm?void 0:Sm.get(t);if("string"==typeof r)n=r;else{const e=JSON.stringify(t,((e,t)=>ld(t)?Object.keys(t).sort().reduce(((e,n)=>(e[n]=t[n],e)),{}):t));ld(t)&&(null==Sm||Sm.set(t,e)),n=e}return`${e}(${n})`};function JY(...e){return function(t){const n=fv((e=>{var n;return null==(n=t.extractRehydrationInfo)?void 0:n.call(t,e,{reducerPath:t.reducerPath??"api"})})),r={reducerPath:"api",keepUnusedDataFor:60,refetchOnMountOrArgChange:!1,refetchOnFocus:!1,refetchOnReconnect:!1,invalidationBehavior:"delayed",...t,extractRehydrationInfo:n,serializeQueryArgs(e){let n=bO;if("serializeQueryArgs"in e.endpointDefinition){const t=e.endpointDefinition.serializeQueryArgs;n=e=>{const n=t(e);return"string"==typeof n?n:bO({...e,queryArgs:n})}}else t.serializeQueryArgs&&(n=t.serializeQueryArgs);return n(e)},tagTypes:[...t.tagTypes||[]]},o={endpointDefinitions:{},batch(e){e()},apiUid:dy(),extractRehydrationInfo:n,hasRehydrationInfo:fv((e=>null!=n(e)))},a={injectEndpoints:function(e){const t=e.endpoints({query:e=>({...e,type:"query"}),mutation:e=>({...e,type:"mutation"})});for(const[n,r]of Object.entries(t))if(!0!==e.overrideExisting&&n in o.endpointDefinitions){if("throw"===e.overrideExisting)throw new Error($o(39))}else{o.endpointDefinitions[n]=r;for(const e of i)e.injectEndpoint(n,r)}return a},enhanceEndpoints({addTagTypes:e,endpoints:t}){if(e)for(const t of e)r.tagTypes.includes(t)||r.tagTypes.push(t);if(t)for(const[e,n]of Object.entries(t))"function"==typeof n?n(o.endpointDefinitions[e]):Object.assign(o.endpointDefinitions[e]||{},n);return a}},i=e.map((e=>e.init(a,r,o)));return a.injectEndpoints({endpoints:t.endpoints})}}function ZY(e){for(let t in e)return!1;return!0}var eQ=2147482.647,tQ=({reducerPath:e,api:t,context:n,internalState:r})=>{const{removeQueryResult:o,unsubscribeQueryResult:a}=t.internalActions;function i(e){const t=r.currentSubscriptions[e];return!!t&&!ZY(t)}const s={};function u(e,t,r,a){const u=n.endpointDefinitions[t],l=(null==u?void 0:u.keepUnusedDataFor)??a.keepUnusedDataFor;if(l===1/0)return;const c=Math.max(0,Math.min(l,eQ));if(!i(e)){const t=s[e];t&&clearTimeout(t),s[e]=setTimeout((()=>{i(e)||r.dispatch(o({queryCacheKey:e})),delete s[e]}),1e3*c)}}return(r,o,i)=>{var l;if(a.match(r)){const t=o.getState()[e],{queryCacheKey:n}=r.payload;u(n,null==(l=t.queries[n])?void 0:l.endpointName,o,t.config)}if(t.util.resetApiState.match(r))for(const[e,t]of Object.entries(s))t&&clearTimeout(t),delete s[e];if(n.hasRehydrationInfo(r)){const t=o.getState()[e],{queries:a}=n.extractRehydrationInfo(r);for(const[e,n]of Object.entries(a))u(e,null==n?void 0:n.endpointName,o,t.config)}}},nQ=({reducerPath:e,context:t,context:{endpointDefinitions:n},mutationThunk:r,queryThunk:o,api:a,assertTagType:i,refetchQuery:s,internalState:u})=>{const{removeQueryResult:l}=a.internalActions,c=cd(dd(r),py(r)),d=cd(dd(r,o),Mm(r,o));let f=[];function p(n,r){const o=r.getState(),i=o[e];if(f.push(...n),"delayed"===i.config.invalidationBehavior&&function(e){var t,n;for(const n in e.queries)if("pending"===(null==(t=e.queries[n])?void 0:t.status))return!0;for(const t in e.mutations)if("pending"===(null==(n=e.mutations[t])?void 0:n.status))return!0;return!1}(i))return;const c=f;if(f=[],0===c.length)return;const d=a.util.selectInvalidatedBy(o,c);t.batch((()=>{const e=Array.from(d.values());for(const{queryCacheKey:t}of e){const e=i.queries[t],n=u.currentSubscriptions[t]??{};e&&(0===Om(n)?r.dispatch(l({queryCacheKey:t})):"uninitialized"!==e.status&&r.dispatch(s(e,t)))}}))}return(e,t)=>{c(e)?p(x3(e,"invalidatesTags",n,i),t):d(e)?p([],t):a.util.invalidateTags.match(e)&&p(Y$(e.payload,void 0,void 0,void 0,void 0,i),t)}},rQ=({reducerPath:e,queryThunk:t,api:n,refetchQuery:r,internalState:o})=>{const a={};function i({queryCacheKey:t},n){const s=n.getState()[e],u=s.queries[t],c=o.currentSubscriptions[t];if(!u||"uninitialized"===u.status)return;const{lowestPollingInterval:d,skipPollingIfUnfocused:f}=l(c);if(!Number.isFinite(d))return;const p=a[t];null!=p&&p.timeout&&(clearTimeout(p.timeout),p.timeout=void 0);const m=Date.now()+d;a[t]={nextPollTimestamp:m,pollingInterval:d,timeout:setTimeout((()=>{(s.config.focused||!f)&&n.dispatch(r(u,t)),i({queryCacheKey:t},n)}),d)}}function s({queryCacheKey:t},n){const r=n.getState()[e].queries[t],s=o.currentSubscriptions[t];if(!r||"uninitialized"===r.status)return;const{lowestPollingInterval:c}=l(s);if(!Number.isFinite(c))return void u(t);const d=a[t],f=Date.now()+c;(!d||f<d.nextPollTimestamp)&&i({queryCacheKey:t},n)}function u(e){const t=a[e];null!=t&&t.timeout&&clearTimeout(t.timeout),delete a[e]}function l(e={}){let t=!1,n=Number.POSITIVE_INFINITY;for(let r in e)e[r].pollingInterval&&(n=Math.min(e[r].pollingInterval,n),t=e[r].skipPollingIfUnfocused||t);return{lowestPollingInterval:n,skipPollingIfUnfocused:t}}return(e,r)=>{(n.internalActions.updateSubscriptionOptions.match(e)||n.internalActions.unsubscribeQueryResult.match(e))&&s(e.payload,r),(t.pending.match(e)||t.rejected.match(e)&&e.meta.condition)&&s(e.meta.arg,r),(t.fulfilled.match(e)||t.rejected.match(e)&&!e.meta.condition)&&i(e.meta.arg,r),n.util.resetApiState.match(e)&&function(){for(const e of Object.keys(a))u(e)}()}},oQ=({reducerPath:e,context:t,api:n,refetchQuery:r,internalState:o})=>{const{removeQueryResult:a}=n.internalActions;function i(n,i){const s=n.getState()[e],u=s.queries,l=o.currentSubscriptions;t.batch((()=>{for(const e of Object.keys(l)){const t=u[e],o=l[e];o&&t&&((Object.values(o).some((e=>!0===e[i]))||Object.values(o).every((e=>void 0===e[i]))&&s.config[i])&&(0===Om(o)?n.dispatch(a({queryCacheKey:e})):"uninitialized"!==t.status&&n.dispatch(r(t,e))))}}))}return(e,t)=>{H$.match(e)&&i(t,"refetchOnFocus"),K$.match(e)&&i(t,"refetchOnReconnect")}},_O=new Error("Promise never resolved before cacheEntryRemoved."),iQ=({api:e,reducerPath:t,context:n,queryThunk:r,mutationThunk:o,internalState:a})=>{const i=$S(r),s=$S(o),u=dd(r,o),l={};function c(t,r,o,a,i){const s=n.endpointDefinitions[t],u=null==s?void 0:s.onCacheEntryAdded;if(!u)return;let c={};const d=new Promise((e=>{c.cacheEntryRemoved=e})),f=Promise.race([new Promise((e=>{c.valueResolved=e})),d.then((()=>{throw _O}))]);f.catch((()=>{})),l[o]=c;const p=e.endpoints[t].select("query"===s.type?r:o),m=a.dispatch(((e,t,n)=>n)),v={...a,getCacheEntry:()=>p(a.getState()),requestId:i,extra:m,updateCachedData:"query"===s.type?n=>a.dispatch(e.util.updateQueryData(t,r,n)):void 0,cacheDataLoaded:f,cacheEntryRemoved:d},h=u(r,v);Promise.resolve(h).catch((e=>{if(e!==_O)throw e}))}return(n,a,d)=>{const f=function(t){return i(t)?t.meta.arg.queryCacheKey:s(t)?t.meta.arg.fixedCacheKey??t.meta.requestId:e.internalActions.removeQueryResult.match(t)?t.payload.queryCacheKey:e.internalActions.removeMutationResult.match(t)?Cv(t.payload):""}(n);if(r.pending.match(n)){const e=d[t].queries[f],r=a.getState()[t].queries[f];!e&&r&&c(n.meta.arg.endpointName,n.meta.arg.originalArgs,f,a,n.meta.requestId)}else if(o.pending.match(n))a.getState()[t].mutations[f]&&c(n.meta.arg.endpointName,n.meta.arg.originalArgs,f,a,n.meta.requestId);else if(u(n)){const e=l[f];null!=e&&e.valueResolved&&(e.valueResolved({data:n.payload,meta:n.meta.baseQueryMeta}),delete e.valueResolved)}else if(e.internalActions.removeQueryResult.match(n)||e.internalActions.removeMutationResult.match(n)){const e=l[f];e&&(delete l[f],e.cacheEntryRemoved())}else if(e.util.resetApiState.match(n))for(const[e,t]of Object.entries(l))delete l[e],t.cacheEntryRemoved()}},aQ=({api:e,context:t,queryThunk:n,mutationThunk:r})=>{const o=dE(n,r),a=Mm(n,r),i=dd(n,r),s={};return(n,r)=>{var u,l;if(o(n)){const{requestId:o,arg:{endpointName:a,originalArgs:i}}=n.meta,u=t.endpointDefinitions[a],l=null==u?void 0:u.onQueryStarted;if(l){const t={},n=new Promise(((e,n)=>{t.resolve=e,t.reject=n}));n.catch((()=>{})),s[o]=t;const c=e.endpoints[a].select("query"===u.type?i:o),d=r.dispatch(((e,t,n)=>n)),f={...r,getCacheEntry:()=>c(r.getState()),requestId:o,extra:d,updateCachedData:"query"===u.type?t=>r.dispatch(e.util.updateQueryData(a,i,t)):void 0,queryFulfilled:n};l(i,f)}}else if(i(n)){const{requestId:e,baseQueryMeta:t}=n.meta;null==(u=s[e])||u.resolve({data:n.payload,meta:t}),delete s[e]}else if(a(n)){const{requestId:e,rejectedWithValue:t,baseQueryMeta:r}=n.meta;null==(l=s[e])||l.reject({error:n.payload??n.error,isUnhandledError:!t,meta:r}),delete s[e]}}},sQ=({api:e,context:{apiUid:t},reducerPath:n})=>(n,r)=>{e.util.resetApiState.match(n)&&r.dispatch(e.internalActions.middlewareRegistered(t))},uQ=({api:e,queryThunk:t,internalState:n})=>{const r=`${e.reducerPath}/subscriptions`;let o=null,a=null;const{updateSubscriptionOptions:i,unsubscribeQueryResult:s}=e.internalActions,u=()=>n.currentSubscriptions,l={getSubscriptions:u,getSubscriptionCount:e=>Om(u()[e]??{}),isRequestSubscribed:(e,t)=>{var n;const r=u();return!(null==(n=null==r?void 0:r[e])||!n[t])}};return(u,c)=>{if(o||(o=JSON.parse(JSON.stringify(n.currentSubscriptions))),e.util.resetApiState.match(u))return o=n.currentSubscriptions={},a=null,[!0,!1];if(e.internalActions.internal_getRTKQSubscriptions.match(u))return[!1,l];const d=((n,r)=>{var o,a,u;if(i.match(r)){const{queryCacheKey:e,requestId:t,options:a}=r.payload;return null!=(o=null==n?void 0:n[e])&&o[t]&&(n[e][t]=a),!0}if(s.match(r)){const{queryCacheKey:e,requestId:t}=r.payload;return n[e]&&delete n[e][t],!0}if(e.internalActions.removeQueryResult.match(r))return delete n[r.payload.queryCacheKey],!0;if(t.pending.match(r)){const{meta:{arg:e,requestId:t}}=r,o=n[a=e.queryCacheKey]??(n[a]={});return o[`${t}_running`]={},e.subscribe&&(o[t]=e.subscriptionOptions??o[t]??{}),!0}let l=!1;if(t.fulfilled.match(r)||t.rejected.match(r)){const e=n[r.meta.arg.queryCacheKey]||{},t=`${r.meta.requestId}_running`;l||(l=!!e[t]),delete e[t]}if(t.rejected.match(r)){const{meta:{condition:e,arg:t,requestId:o}}=r;if(e&&t.subscribe){const e=n[u=t.queryCacheKey]??(n[u]={});e[o]=t.subscriptionOptions??e[o]??{},l=!0}}return l})(n.currentSubscriptions,u);let f=!0;if(d){a||(a=setTimeout((()=>{const t=JSON.parse(JSON.stringify(n.currentSubscriptions)),[,r]=GO(o,(()=>t));c.next(e.internalActions.subscriptionsUpdated(r)),o=t,a=null}),500));const i="string"==typeof u.type&&!!u.type.startsWith(r),s=t.rejected.match(u)&&u.meta.condition&&!!u.meta.arg.subscribe;f=!i&&!s}return[f,!1]}};function lQ(e){const{reducerPath:t,queryThunk:n,api:r,context:o}=e,{apiUid:a}=o,i={invalidateTags:Vn(`${t}/invalidateTags`)},s=e=>e.type.startsWith(`${t}/`),u=[sQ,tQ,nQ,rQ,iQ,aQ];return{middleware:n=>{let i=!1;const c={...e,internalState:{currentSubscriptions:{}},refetchQuery:l,isThisApiSliceAction:s},d=u.map((e=>e(c))),f=uQ(c),p=oQ(c);return e=>u=>{if(!BO(u))return e(u);i||(i=!0,n.dispatch(r.internalActions.middlewareRegistered(a)));const l={...n,next:e},c=n.getState(),[m,v]=f(u,l,c);let h;if(h=m?e(u):v,n.getState()[t]&&(p(u,l,c),s(u)||o.hasRehydrationInfo(u)))for(let e of d)e(u,l,c);return h}},actions:i};function l(e,t,r={}){return n({type:"query",endpointName:e.endpointName,originalArgs:e.originalArgs,subscribe:!1,forceRefetch:!0,queryCacheKey:t,...r})}}function rd(e,...t){return Object.assign(e,...t)}var xO=Symbol(),cQ=({createSelector:e=Zn}={})=>({name:xO,init(t,{baseQuery:n,tagTypes:r,reducerPath:o,serializeQueryArgs:a,keepUnusedDataFor:i,refetchOnMountOrArgChange:s,refetchOnFocus:u,refetchOnReconnect:l,invalidationBehavior:c},d){uL();const f=e=>e;Object.assign(t,{reducerPath:o,endpoints:{},internalActions:{onOnline:K$,onOffline:b3,onFocus:H$,onFocusLost:w3},util:{}});const{queryThunk:p,mutationThunk:m,patchQueryData:v,updateQueryData:h,upsertQueryData:g,prefetch:y,buildMatchThunkActions:b}=YY({baseQuery:n,reducerPath:o,context:d,api:t,serializeQueryArgs:a,assertTagType:f}),{reducer:w,actions:x}=QY({context:d,queryThunk:p,mutationThunk:m,reducerPath:o,assertTagType:f,config:{refetchOnFocus:u,refetchOnReconnect:l,refetchOnMountOrArgChange:s,keepUnusedDataFor:i,reducerPath:o,invalidationBehavior:c}});rd(t.util,{patchQueryData:v,updateQueryData:h,upsertQueryData:g,prefetch:y,resetApiState:x.resetApiState}),rd(t.internalActions,x);const{middleware:_,actions:E}=lQ({reducerPath:o,context:d,queryThunk:p,mutationThunk:m,api:t,assertTagType:f});rd(t.util,E),rd(t,{reducer:w,middleware:_});const{buildQuerySelector:S,buildMutationSelector:I,selectInvalidatedBy:A,selectCachedArgsForQuery:k}=XY({serializeQueryArgs:a,reducerPath:o,createSelector:e});rd(t.util,{selectInvalidatedBy:A,selectCachedArgsForQuery:k});const{buildInitiateQuery:C,buildInitiateMutation:T,getRunningMutationThunk:R,getRunningMutationsThunk:P,getRunningQueriesThunk:O,getRunningQueryThunk:N}=KY({queryThunk:p,mutationThunk:m,api:t,serializeQueryArgs:a,context:d});return rd(t.util,{getRunningMutationThunk:R,getRunningMutationsThunk:P,getRunningQueryThunk:N,getRunningQueriesThunk:O}),{name:xO,injectEndpoint(e,n){var r;const o=t;(r=o.endpoints)[e]??(r[e]={}),_3(n)?rd(o.endpoints[e],{name:e,select:S(e,n),initiate:C(e,n)},b(p,e)):qY(n)&&rd(o.endpoints[e],{name:e,select:I(),initiate:T(e)},b(m,e))}}}});function dQ(e){return"query"===e.type}function fQ(e){return"mutation"===e.type}function Lg(e,...t){return Object.assign(e,...t)}function cS(e){return e.replace(e[0],e[0].toUpperCase())}var Em=WeakMap?new WeakMap:void 0,pQ=({endpointName:e,queryArgs:t})=>{let n="";const r=null==Em?void 0:Em.get(t);if("string"==typeof r)n=r;else{const e=JSON.stringify(t,((e,t)=>ld(t)?Object.keys(t).sort().reduce(((e,n)=>(e[n]=t[n],e)),{}):t));ld(t)&&(null==Em||Em.set(t,e)),n=e}return`${e}(${n})`},dS=Symbol();function SO(e,t,n,r){const o=v.useMemo((()=>({queryArgs:e,serialized:"object"==typeof e?t({queryArgs:e,endpointDefinition:n,endpointName:r}):e})),[e,t,n,r]),a=v.useRef(o);return v.useEffect((()=>{a.current.serialized!==o.serialized&&(a.current=o)}),[o]),a.current.serialized===o.serialized?a.current.queryArgs:e}function fS(e){const t=v.useRef(e);return v.useEffect((()=>{rv(t.current,e)||(t.current=e)}),[e]),rv(t.current,e)?t.current:e}var mQ=typeof window<"u"&&window.document&&window.document.createElement?v.useLayoutEffect:v.useEffect,hQ=e=>e.isUninitialized?{...e,isUninitialized:!1,isFetching:!0,isLoading:void 0===e.data,status:g3.pending}:e;function vQ({api:e,moduleOptions:{batch:t,hooks:{useDispatch:n,useSelector:r,useStore:o},unstable__sideEffectsInRender:a,createSelector:i},serializeQueryArgs:s,context:u}){const l=a?e=>e():v.useEffect;return{buildQueryHooks:function(a){const d=(t,{refetchOnReconnect:r,refetchOnFocus:o,refetchOnMountOrArgChange:i,skip:s=!1,pollingInterval:c=0,skipPollingIfUnfocused:d=!1}={})=>{const{initiate:f}=e.endpoints[a],p=n(),m=v.useRef();if(!m.current){const t=p(e.internalActions.internal_getRTKQSubscriptions());m.current=t}const h=SO(s?Ff:t,pQ,u.endpointDefinitions[a],a),g=fS({refetchOnReconnect:r,refetchOnFocus:o,pollingInterval:c,skipPollingIfUnfocused:d}),y=v.useRef(!1),b=v.useRef();let{queryCacheKey:w,requestId:x}=b.current||{},_=!1;w&&x&&(_=m.current.isRequestSubscribed(w,x));const E=!_&&y.current;return l((()=>{y.current=_})),l((()=>{E&&(b.current=void 0)}),[E]),l((()=>{var e;const t=b.current;if(h===Ff)return null==t||t.unsubscribe(),void(b.current=void 0);const n=null==(e=b.current)?void 0:e.subscriptionOptions;if(t&&t.arg===h)g!==n&&t.updateSubscriptionOptions(g);else{null==t||t.unsubscribe();const e=p(f(h,{subscriptionOptions:g,forceRefetch:i}));b.current=e}}),[p,f,i,h,g,E]),v.useEffect((()=>()=>{var e;null==(e=b.current)||e.unsubscribe(),b.current=void 0}),[]),v.useMemo((()=>({refetch:()=>{var e;if(!b.current)throw new Error($o(38));return null==(e=b.current)?void 0:e.refetch()}})),[])},f=({refetchOnReconnect:r,refetchOnFocus:o,pollingInterval:i=0,skipPollingIfUnfocused:s=!1}={})=>{const{initiate:u}=e.endpoints[a],c=n(),[d,f]=v.useState(dS),p=v.useRef(),m=fS({refetchOnReconnect:r,refetchOnFocus:o,pollingInterval:i,skipPollingIfUnfocused:s});l((()=>{var e,t;const n=null==(e=p.current)?void 0:e.subscriptionOptions;m!==n&&(null==(t=p.current)||t.updateSubscriptionOptions(m))}),[m]);const h=v.useRef(m);l((()=>{h.current=m}),[m]);const g=v.useCallback((function(e,n=!1){let r;return t((()=>{var t;null==(t=p.current)||t.unsubscribe(),p.current=r=c(u(e,{subscriptionOptions:h.current,forceRefetch:!n})),f(e)})),r}),[c,u]);return v.useEffect((()=>()=>{var e;null==(e=null==p?void 0:p.current)||e.unsubscribe()}),[]),v.useEffect((()=>{d!==dS&&!p.current&&g(d,!0)}),[d,g]),v.useMemo((()=>[g,d]),[g,d])},p=(t,{skip:n=!1,selectFromResult:l}={})=>{const{select:d}=e.endpoints[a],f=SO(n?Ff:t,s,u.endpointDefinitions[a],a),p=v.useRef(),m=v.useMemo((()=>i([d(f),(e,t)=>t,e=>f],c,{memoizeOptions:{resultEqualityCheck:rv}})),[d,f]),h=v.useMemo((()=>l?i([m],l,{devModeChecks:{identityFunctionCheck:"never"}}):m),[m,l]),g=r((e=>h(e,p.current)),rv),y=o(),b=m(y.getState(),p.current);return mQ((()=>{p.current=b}),[b]),g};return{useQueryState:p,useQuerySubscription:d,useLazyQuerySubscription:f,useLazyQuery(e){const[t,n]=f(e),r=p(n,{...e,skip:n===dS}),o=v.useMemo((()=>({lastArg:n})),[n]);return v.useMemo((()=>[t,r,o]),[t,r,o])},useQuery(e,t){const n=d(e,t),r=p(e,{selectFromResult:e===Ff||null!=t&&t.skip?void 0:hQ,...t}),{data:o,status:a,isLoading:i,isSuccess:s,isError:u,error:l}=r;return v.useDebugValue({data:o,status:a,isLoading:i,isSuccess:s,isError:u,error:l}),v.useMemo((()=>({...r,...n})),[r,n])}}},buildMutationHook:function(o){return({selectFromResult:a,fixedCacheKey:s}={})=>{const{select:u,initiate:l}=e.endpoints[o],c=n(),[d,f]=v.useState();v.useEffect((()=>()=>{null!=d&&d.arg.fixedCacheKey||null==d||d.reset()}),[d]);const p=v.useCallback((function(e){const t=c(l(e,{fixedCacheKey:s}));return f(t),t}),[c,l,s]),{requestId:m}=d||{},h=v.useMemo((()=>u({fixedCacheKey:s,requestId:null==d?void 0:d.requestId})),[s,d,u]),g=v.useMemo((()=>a?i([h],a):h),[a,h]),y=r(g,rv),b=null==s?null==d?void 0:d.arg.originalArgs:void 0,w=v.useCallback((()=>{t((()=>{d&&f(void 0),s&&c(e.internalActions.removeMutationResult({requestId:m,fixedCacheKey:s}))}))}),[c,s,d,m]),{endpointName:x,data:_,status:E,isLoading:S,isSuccess:I,isError:A,error:k}=y;v.useDebugValue({endpointName:x,data:_,status:E,isLoading:S,isSuccess:I,isError:A,error:k});const C=v.useMemo((()=>({...y,originalArgs:b,reset:w})),[y,b,w]);return v.useMemo((()=>[p,C]),[p,C])}},usePrefetch:function(t,r){const o=n(),a=fS(r);return v.useCallback(((n,r)=>o(e.util.prefetch(t,n,{...a,...r}))),[t,o,a])}};function c(e,t,n){if(null!=t&&t.endpointName&&e.isUninitialized){const{endpointName:e}=t,r=u.endpointDefinitions[e];s({queryArgs:t.originalArgs,endpointDefinition:r,endpointName:e})===s({queryArgs:n,endpointDefinition:r,endpointName:e})&&(t=void 0)}let r=e.isSuccess?e.data:null==t?void 0:t.data;void 0===r&&(r=e.data);const o=void 0!==r,a=e.isLoading,i=!o&&a,l=e.isSuccess||a&&o;return{...e,data:r,currentData:e.data,isFetching:a,isLoading:i,isSuccess:l}}}var gQ=Symbol(),yQ=({batch:e=l5,hooks:t={useDispatch:hE,useSelector:vy,useStore:ZO},createSelector:n=Zn,unstable__sideEffectsInRender:r=!1,...o}={})=>({name:gQ,init(o,{serializeQueryArgs:a},i){const s=o,{buildQueryHooks:u,buildMutationHook:l,usePrefetch:c}=vQ({api:o,moduleOptions:{batch:e,hooks:t,unstable__sideEffectsInRender:r,createSelector:n},serializeQueryArgs:a,context:i});return Lg(s,{usePrefetch:c}),Lg(i,{batch:e}),{injectEndpoint(e,t){if(dQ(t)){const{useQuery:t,useLazyQuery:n,useLazyQuerySubscription:r,useQueryState:a,useQuerySubscription:i}=u(e);Lg(s.endpoints[e],{useQuery:t,useLazyQuery:n,useLazyQuerySubscription:r,useQueryState:a,useQuerySubscription:i}),o[`use${cS(e)}Query`]=t,o[`useLazy${cS(e)}Query`]=n}else if(fQ(t)){const t=l(e);Lg(s.endpoints[e],{useMutation:t}),o[`use${cS(e)}Mutation`]=t}}}}}),wQ=JY(cQ(),yQ());const E3=()=>I3()?location.hostname:location.hostname.replace(/\w\w\w\.|^/,"."),$3=e=>{const t=new Date;return t.setTime(t.getTime()+24*e*60*60*1e3),t.toUTCString()},C3=e=>Object.keys(e).reduce(((t,n)=>`${t}${n}${!0===e[n]?"":`=${e[n]}`};`),""),bQ=(e,t)=>{const n=Jy()?"":document.cookie,r=`; ${t||n}`.split(`; ${e}=`);if(2===r.length)return(r.pop()||"").replace("=","").split(";").shift()},_Q=(e,t)=>{Jy()||(document.cookie=C3({[e]:"",path:"/",domain:t||E3(),expires:"Thu, 01 Jan 1970 00:00:01 GMT"}))},xQ=["localhost","127.0.0.1","dev.localtest.me","wellesleydev.localtest.me"],I3=()=>xQ.includes(location.hostname),SQ=(e,t="",n=10,r)=>{Jy()||(document.cookie=C3({[e]:t,path:"/",domain:r||E3(),expires:$3(n),...!I3()&&{SameSite:"None",Secure:!0}}))},Q$={set:SQ,remove:_Q,get:bQ,getExpireDate:$3},X$="auth_token",R3=()=>Q$.get(X$)||void 0,EQ=e=>Q$.set(X$,e),$Q=()=>Q$.remove(X$),CQ=()=>!!R3(),J$={getToken:R3,setToken:EQ,removeToken:$Q,hasToken:CQ},IQ=e=>{J$.removeToken(),e(bH()),V$("user").clear()},RQ=e=>async(t,n,r)=>{const o=await e(t,n,r);return o.error&&[401].includes(o.error.status)&&IQ(n.dispatch),o},PQ=async(e,t=2e3)=>{for(;!e();)await new Promise((e=>setTimeout(e,t)))},TQ=5,OQ=e=>t=>!!e&&t.includes(e.status),EO=e=>new Promise((t=>setTimeout(t,1e3*e))),AQ=e=>async(t,n,r)=>{const o=(null==r?void 0:r.maxRetries)??5;await PQ((()=>n.getState().network.isOnline));let a=0;const i=async()=>{var s,u,l,c;const d=await e(t,n,r),f=d.error;if(a>=o)return d;a>0&&await EO(Math.pow(2,a)),a++;const p=OQ(f);switch(!0){case"mutation"===n.type:return d;case!navigator.onLine:case p([408,404]):case f&&"FETCH_ERROR"===(null==f?void 0:f.status):case f&&f.status>=500:return await i();case 429===(null==(s=null==d?void 0:d.error)?void 0:s.status):{const e=null==(c=null==(l=null==(u=d.meta)?void 0:u.response)?void 0:l.headers)?void 0:c.get("Retry-After");return await EO(+(e||"0")),await i()}default:return d}};return await i()},$O=Vn("requestOpenapiHydrationCacheHas"),CO=Vn("requestOpenapiHydrationCacheAdd"),IO=Vn("requestOpenapiHydrationCacheRemove"),RO=Vn("requestOpenapiHydrationCacheClear"),PO=Vn("sendOpenapiHydrationCacheResponse"),MQ=()=>Math.random().toString(16).slice(2),DQ=()=>{try{return!!Cm()&&window.location.origin!==window.parent.location.origin}catch{return!0}},Fg=()=>{const e=window.parent;return e.__wlsy_openapiHydrationCache||(e.__wlsy_openapiHydrationCache=new Set),e.__wlsy_openapiHydrationCache},Bg=new Set,NQ=()=>{const e=DQ(),t=new Map,n=(()=>{let n=null;return()=>{!e||n||(n=e3({sourceWindow:window.parent,onMessage:e=>{if(!PO.match(e))return;const{id:n,value:r,success:o,error:a}=e.payload,i=t.get(n);i&&(t.delete(n),window.clearTimeout(i.timeoutId),o?i.resolve(r):i.reject(new Error(a||"Unknown error")))},whitelist:[PO]}))}})(),r=(e,r)=>{const o=MQ();return new Promise(((a,i)=>{const s=window.setTimeout((()=>{t.delete(o),i(new Error("OpenAPI hydration cache request timed out"))}),8e3);t.set(o,{resolve:a,reject:i,timeoutId:s}),(e=>{n(),Zk({action:e,windowElement:window.parent,whitelist:[$O,CO,IO,RO]})})(e({id:o,...r}))}))};return{has:async t=>e?!!await r($O,{key:t}):(t=>Cm()&&!e?Fg().has(t):Bg.has(t))(t),add:async t=>{e?await r(CO,{key:t}):(t=>{!Cm()||e?Bg.add(t):Fg().add(t)})(t)},remove:async t=>{e?await r(IO,{key:t}):(t=>{!Cm()||e?Bg.delete(t):Fg().delete(t)})(t)},clear:async()=>{e?await r(RO,{}):!Cm()||e?Bg.clear():Fg().clear()}}},kQ=e=>"object"==typeof e&&null!==e,TO=NQ(),LQ=e=>async(t,n,r)=>{var o,a,i,s;if("mutation"===n.type)return e(t,n,r);const u=n.endpoint;if(!u||!(null!=r&&r.initialDataKey||null!=r&&r.initialDataKeyResolver||null!=r&&r.initialDataResolver))return e(t,n,r);const l=(null==(o=null==r?void 0:r.initialDataKeyResolver)?void 0:o.call(r,{endpoint:u,requestArgs:t}))??(null==r?void 0:r.initialDataKey),c=(null==(a=null==r?void 0:r.hydrationCacheKeyResolver)?void 0:a.call(r,{endpoint:u,requestArgs:t,initialDataKey:l}))??(l?`initialDataKey:${l}`:u);if(await TO.has(c))return e(t,n,r);const d=null==(i=n.getState().initialState)?void 0:i.value,f=(null==(s=null==r?void 0:r.initialDataResolver)?void 0:s.call(r,{endpoint:u,requestArgs:t,initialState:d}))??(()=>{if(l)return kQ(d)?d[l]:void 0})();return void 0===f?e(t,n,r):(await TO.add(c),{data:f})};var P3=(e=>(e.SERVER_RULES="serverRules",e.INVITE_PEOPLE="invitePeople",e))(P3||{});const t0="staticState",T3=V$(),Wg={path:"",baseUrl:"",search:""},FQ=e=>{if(!e)return Wg;try{return JSON.parse(decodeURIComponent(e))||Wg}catch(e){return ap.error("Error parsing static state",e),Wg}},O3=()=>new URLSearchParams(window.location.search).get(t0),BQ=({path:e,baseUrl:t,search:n}={})=>{const{pathname:r,origin:o,search:a}=window.location;return`${t0}=${encodeURIComponent(JSON.stringify({path:e||r,baseUrl:t||o,search:n||a}))}`},jQ=()=>{const e=O3();return e&&T3.setItem(t0,e),A3()},A3=()=>{try{const e=T3.getItem(t0)||O3();return FQ(e)}catch(e){return ap.error("Error parsing static state",e),Wg}},zQ={create:BQ,init:jQ,get:A3},VQ=async e=>{const t={};e.headers.forEach(((e,n)=>{t[n]=e}));return{body:["get","head"].includes(e.method.toLowerCase())?null:await(async()=>{try{return await e.text()}catch(e){return ap.error("No body or error reading body:",e),null}})(),headers:t,url:e.url,method:e.method,mode:e.mode,credentials:e.credentials,cache:e.cache,redirect:e.redirect,referrer:e.referrer,integrity:e.integrity}},UQ=e=>{const{url:t,status:n,statusText:r,headers:o,body:a}=e,i=new Response(JSON.stringify(a),{status:n,statusText:r,headers:o});return Object.defineProperties(i,{url:{value:t},type:{value:"cors"}}),i},WQ=async e=>{const t=crypto.randomUUID();return new Promise(((n,r)=>{const o=e3({onMessage:({payload:{id:e,response:r}})=>{t===e&&(null==o||o(),n(UQ(r)))},whitelist:[_K]});(async()=>{try{Zk({action:b2({id:t,options:await VQ(e)}),windowElement:window.parent,whitelist:[b2]})}catch(e){r(e)}})()}))};new EventTarget;const Z$=()=>{var e;try{return(null==(e=window.wellesley)?void 0:e.v1)||window.wellesley}catch(e){ap.error("Error getting window.wellesley:",e)}},qQ=e=>new Response(JSON.stringify(e),{status:200,statusText:"OK",headers:{"Content-Type":"application/json"}}),GQ=e=>{var t,n;if(e.url.includes("accounts/profile")){const e=null==(n=null==(t=Z$())?void 0:t.initialState)?void 0:n.currentAccount;return!(null==e||!e.selectedUserId)&&qQ(e)}},HQ=Object.freeze(Object.defineProperty({__proto__:null,userHandler:GQ},Symbol.toStringTag,{value:"Module"})),KQ=e=>Object.values(HQ).reduce(((t,n)=>t||n(e)),void 0),YQ=async e=>KQ(e)||await fetch(e),QQ=()=>e=>Cm()?WQ(e):YQ(e),XQ=zQ.get().baseUrl,JQ=XQ||"",ZQ=WY({fetchFn:QQ(),baseUrl:JQ,responseHandler:e=>{const t=e.headers.get("content-type");if(!(null==t?void 0:t.startsWith("application/json")))return e.text();try{return e.json()}catch{return e.text()}},prepareHeaders:e=>{const t=J$.getToken();return t&&e.set("authorization",`Bearer ${t}`),e}}),eX=RQ(LQ(AQ(ZQ))),tX=wQ({tagTypes:["Secure","Post","Follow","Like","Settings","UserSettings","RBAC","Rbac_Config","Admin_Apps","Admin_Platform_Data","Admin_Ai_Agents_Assignments","Admin_Users","Admin_Groups","Admin_Audit_Logs","Admin_Reports","Admin_Signup_Requests","Admin_Posts","Admin_Uploads","Admin_Roles","Admin_Jobs_Stats","Admin_Federation","Admin_Domain_Block","Admin_Custom_Emojis","Admin_Domain_Allow","Admin_Link_Service_Configure","Groups","Group_Channels","GroupMembers","GroupMembership","GroupRules","Group_Roles","Group_Join_Requests","Group_Apps","Group_Ai_Agents_Assignments","User_Apps","Account","Profile","UserNoHtml","Relationship","Bookmarks","Global_Search","Events","Event","EventAttendees",...Object.values(P3)],reducerPath:"openapi",baseQuery:eX,endpoints:()=>({})}),nX=tX.injectEndpoints({endpoints:e=>({getApiMetaCompat:e.query({query:()=>({url:"/api/meta/compat"})}),postApiV1AccountsAddReason:e.mutation({query:e=>({url:"/api/v1/accounts/add-reason",method:"POST",body:e.signupReasonParams})}),postApiV1AccountsAuthenticateEmail:e.mutation({query:e=>({url:"/api/v1/accounts/authenticate/email",method:"POST",body:e.authRequest})}),postApiV1AccountsAuthenticatePhone:e.mutation({query:e=>({url:"/api/v1/accounts/authenticate/phone",method:"POST",body:e.authPhoneRequest})}),putApiV1AccountsChangeName:e.mutation({query:e=>({url:"/api/v1/accounts/change/name",method:"PUT",params:{id:e.id,name:e.name,username:e.username}})}),postApiV1AccountsCheckCaptcha:e.mutation({query:e=>({url:"/api/v1/accounts/check-captcha",method:"POST",body:e.captchaVerificationParams})}),postApiV1AccountsConfirmEmail:e.mutation({query:e=>({url:"/api/v1/accounts/confirm-email",method:"POST",body:e.codeVerificationParams})}),postApiV1AccountsConfirmPhone:e.mutation({query:e=>({url:"/api/v1/accounts/confirm-phone",method:"POST",body:e.codeVerificationParams})}),deleteApiV1AccountsDelete:e.mutation({query:()=>({url:"/api/v1/accounts/delete",method:"DELETE"})}),postApiV1AccountsEmailChangeConfirm:e.mutation({query:e=>({url:"/api/v1/accounts/email/change/confirm",method:"POST",body:e.body})}),postApiV1AccountsEmailChangeRequest:e.mutation({query:e=>({url:"/api/v1/accounts/email/change/request",method:"POST",body:e.emailChangeRequest})}),putApiV1AccountsEmailChangeResendCode:e.mutation({query:()=>({url:"/api/v1/accounts/email/change/resend-code",method:"PUT"})}),postApiV1AccountsFinishCreating:e.mutation({query:e=>({url:"/api/v1/accounts/finish-creating",method:"POST",body:e.finishCreatingAccountParams,params:{htmlContent:e.htmlContent}})}),putApiV1AccountsGetTokenByHash:e.mutation({query:e=>({url:`/api/v1/accounts/get-token/${e.hash}`,method:"PUT"})}),postApiV1AccountsLoginsAddEmailPassword:e.mutation({query:e=>({url:"/api/v1/accounts/logins/add-email-password",method:"POST",body:e.addEmailRequest})}),postApiV1AccountsLoginsAddEmailPasswordConfirm:e.mutation({query:e=>({url:"/api/v1/accounts/logins/add-email-password/confirm",method:"POST",body:e.body})}),putApiV1AccountsLoginsAddEmailPasswordResendCode:e.mutation({query:()=>({url:"/api/v1/accounts/logins/add-email-password/resend-code",method:"PUT"})}),postApiV1AccountsLoginsAddPhone:e.mutation({query:e=>({url:"/api/v1/accounts/logins/add-phone",method:"POST",body:e.addPhoneRequest})}),deleteApiV1AccountsLoginsRemoveEmailPassword:e.mutation({query:()=>({url:"/api/v1/accounts/logins/remove-email-password",method:"DELETE"})}),deleteApiV1AccountsLoginsRemovePhone:e.mutation({query:()=>({url:"/api/v1/accounts/logins/remove-phone",method:"DELETE"})}),postApiV1AccountsPasswordChangeConfirm:e.mutation({query:e=>({url:"/api/v1/accounts/password/change/confirm",method:"POST",body:e.body})}),postApiV1AccountsPasswordChangeRequest:e.mutation({query:e=>({url:"/api/v1/accounts/password/change/request",method:"POST",body:e.passwordChangeRequest})}),putApiV1AccountsPasswordChangeResendCode:e.mutation({query:()=>({url:"/api/v1/accounts/password/change/resend-code",method:"PUT"})}),postApiV1AccountsPasswordRecover:e.mutation({query:e=>({url:"/api/v1/accounts/password/recover",method:"POST",body:e.passwordRecoveryRequest})}),postApiV1AccountsPasswordRecoverChange:e.mutation({query:e=>({url:"/api/v1/accounts/password/recover/change",method:"POST",body:e.passwordRecoveryChange})}),postApiV1AccountsPasswordRecoverCheckCode:e.mutation({query:e=>({url:"/api/v1/accounts/password/recover/check-code",method:"POST",body:e.passwordRecoveryCode})}),postApiV1AccountsPhoneChangeConfirmAuth:e.mutation({query:e=>({url:"/api/v1/accounts/phone/change/confirm/auth",method:"POST",body:e.body})}),postApiV1AccountsPhoneChangeConfirmNewPhone:e.mutation({query:e=>({url:"/api/v1/accounts/phone/change/confirm/new-phone",method:"POST",body:e.body})}),postApiV1AccountsPhoneChangeNewPhone:e.mutation({query:e=>({url:"/api/v1/accounts/phone/change/new-phone",method:"POST",body:e.addPhoneRequest})}),putApiV1AccountsPhoneChangeRequest:e.mutation({query:()=>({url:"/api/v1/accounts/phone/change/request",method:"PUT"})}),putApiV1AccountsPhoneChangeResendCodeAuth:e.mutation({query:()=>({url:"/api/v1/accounts/phone/change/resend-code/auth",method:"PUT"})}),putApiV1AccountsPhoneChangeResendCodeNewPhone:e.mutation({query:()=>({url:"/api/v1/accounts/phone/change/resend-code/new-phone",method:"PUT"})}),getApiV1AccountsProfile:e.query({query:e=>({url:"/api/v1/accounts/profile",params:{htmlContent:e.htmlContent}})}),putApiV1AccountsResendCodeByHash:e.mutation({query:e=>({url:`/api/v1/accounts/resend-code/${e.hash}`,method:"PUT"})}),putApiV1AccountsResendEmailByHash:e.mutation({query:e=>({url:`/api/v1/accounts/resend-email/${e.hash}`,method:"PUT"})}),postApiV1AccountsSignup:e.mutation({query:e=>({url:"/api/v1/accounts/signup",method:"POST",body:e.accountCreate})}),postApiV1AccountsSignupPhone:e.mutation({query:e=>({url:"/api/v1/accounts/signup-phone",method:"POST",body:e.phoneSignup})}),postApiV1AccountsUserReselectUser:e.mutation({query:e=>({url:"/api/v1/accounts/user/reselect-user",method:"POST",params:{userId:e.userId,userName:e.userName}})}),getApiV1AddressesSuggest:e.query({query:e=>({url:"/api/v1/addresses/suggest",params:{lang:e.lang,text:e.text}})}),getApiV1AdminAccountByAccountId:e.query({query:e=>({url:`/api/v1/admin/account/${e.accountId}`,params:{htmlContent:e.htmlContent}})}),getApiV1AdminAuditLog:e.query({query:e=>({url:"/api/v1/admin/audit_log",params:{accountId:e.accountId,action:e.action,appId:e.appId,domainSearch:e.domainSearch,email:e.email,group:e.group,groupId:e.groupId,lastId:e.lastId,limit:e.limit,offset:e.offset,ruleId:e.ruleId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId,username:e.username}})}),putApiV1AdminChangeEmail:e.mutation({query:e=>({url:"/api/v1/admin/change/email",method:"PUT",params:{email:e.email,id:e.id,username:e.username}})}),putApiV1AdminChangePassword:e.mutation({query:e=>({url:"/api/v1/admin/change/password",method:"PUT",params:{id:e.id,password:e.password,username:e.username}})}),putApiV1AdminChangeRoleAssign:e.mutation({query:e=>({url:"/api/v1/admin/change/role/assign",method:"PUT",params:{id:e.id,role:e.role,username:e.username,htmlContent:e.htmlContent}})}),putApiV1AdminChangeRoleRevoke:e.mutation({query:e=>({url:"/api/v1/admin/change/role/revoke",method:"PUT",params:{id:e.id,role:e.role,username:e.username,htmlContent:e.htmlContent}})}),postApiV1AdminClearApErrors:e.mutation({query:e=>({url:"/api/v1/admin/clear-ap-errors",method:"POST",params:{domain:e.domain}})}),postApiV1AdminCreateAccount:e.mutation({query:e=>({url:"/api/v1/admin/create-account",method:"POST",body:e.accountCreate,params:{htmlContent:e.htmlContent}})}),postApiV1AdminCreateUser:e.mutation({query:e=>({url:"/api/v1/admin/create-user",method:"POST",body:e.userCreate,params:{account_id:e.accountId,htmlContent:e.htmlContent}})}),deleteApiV1AdminDelete:e.mutation({query:e=>({url:"/api/v1/admin/delete",method:"DELETE",params:{email:e.email,id:e.id,username:e.username}})}),deleteApiV1AdminDeleteUser:e.mutation({query:e=>({url:"/api/v1/admin/delete-user",method:"DELETE",params:{id:e.id,username:e.username}})}),getApiV1AdminDomainAllow:e.query({query:e=>({url:"/api/v1/admin/domain-allow",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1AdminDomainAllow:e.mutation({query:e=>({url:"/api/v1/admin/domain-allow",method:"POST",body:e.allowedDomainReq})}),deleteApiV1AdminDomainAllowByDomain:e.mutation({query:e=>({url:`/api/v1/admin/domain-allow/${e.domain}`,method:"DELETE"})}),putApiV1AdminDomainBlock:e.mutation({query:e=>({url:"/api/v1/admin/domain-block",method:"PUT",body:e.blockDomainReq})}),getApiV1AdminDomainBlock:e.query({query:e=>({url:"/api/v1/admin/domain-block",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1AdminDomainBlock:e.mutation({query:e=>({url:"/api/v1/admin/domain-block",method:"POST",body:e.blockDomainReq})}),deleteApiV1AdminDomainBlockByDomain:e.mutation({query:e=>({url:`/api/v1/admin/domain-block/${e.domain}`,method:"DELETE"})}),getApiV1AdminEmailAllow:e.query({query:()=>({url:"/api/v1/admin/email-allow"})}),postApiV1AdminEmailAllow:e.mutation({query:e=>({url:"/api/v1/admin/email-allow",method:"POST",body:e.allowedDomainReq})}),deleteApiV1AdminEmailAllowByDomain:e.mutation({query:e=>({url:`/api/v1/admin/email-allow/${e.domain}`,method:"DELETE"})}),getApiV1AdminEmailBlock:e.query({query:()=>({url:"/api/v1/admin/email-block"})}),postApiV1AdminEmailBlock:e.mutation({query:e=>({url:"/api/v1/admin/email-block",method:"POST",body:e.blockEmailRequest})}),deleteApiV1AdminEmailBlockByPattern:e.mutation({query:e=>({url:`/api/v1/admin/email-block/${e.pattern}`,method:"DELETE"})}),getApiV1AdminFederation:e.query({query:e=>({url:"/api/v1/admin/federation",params:{blockState:e.blockState,lastId:e.lastId,limit:e.limit,offset:e.offset,search:e.search,sortBy:e.sortBy,sortOrder:e.sortOrder,unavailable:e.unavailable,untilId:e.untilId,warning:e.warning}})}),getApiV1AdminFederationMetricsOperations:e.query({query:e=>({url:"/api/v1/admin/federation/metrics/operations",params:{window:e.window}})}),getApiV1AdminFederationMetricsRunningAverageSingle:e.query({query:e=>({url:"/api/v1/admin/federation/metrics/running-average-single",params:{operation:e.operation,window:e.window}})}),getApiV1AdminFederationMetricsRunningAveragesAll:e.query({query:e=>({url:"/api/v1/admin/federation/metrics/running-averages-all",params:{operations:e.operations,window:e.window}})}),getApiV1AdminFederationByDomain:e.query({query:e=>({url:`/api/v1/admin/federation/${e.domain}`})}),postApiV1AdminFeedClearUserFeed:e.mutation({query:e=>({url:"/api/v1/admin/feed/clear-user-feed",method:"POST",params:{userId:e.userId,username:e.username}})}),getApiV1AdminFeedDiagnose:e.query({query:e=>({url:"/api/v1/admin/feed/diagnose",params:{limit:e.limit,skipExactMatch:e.skipExactMatch,skipFull:e.skipFull,skipOrderMismatch:e.skipOrderMismatch,userId:e.userId,username:e.username}})}),getApiV1AdminFeedMetricsGlobalAllOperation:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/global-all-operation",params:{window:e.window}})}),getApiV1AdminFeedMetricsGlobalSingle:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/global-single",params:{operation:e.operation,window:e.window}})}),getApiV1AdminFeedMetricsHistory:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/history",params:{limit:e.limit,operation:e.operation,userId:e.userId}})}),getApiV1AdminFeedMetricsHistoryAll:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/history/all",params:{limit:e.limit,userId:e.userId}})}),getApiV1AdminFeedMetricsRunningAverageSingle:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/running-average-single",params:{operation:e.operation,userId:e.userId,window:e.window}})}),getApiV1AdminFeedMetricsRunningAveragesAll:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/running-averages-all",params:{userId:e.userId,window:e.window}})}),getApiV1AdminFeedMetricsSlowestOperations:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/slowest-operations",params:{limit:e.limit,window:e.window}})}),getApiV1AdminFeedMetricsSlowestUsers:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/slowest-users",params:{limit:e.limit,operation:e.operation,window:e.window}})}),getApiV1AdminFeedMetricsSlowestUsersAll:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/slowest-users-all",params:{limit:e.limit,sortDesc:e.sortDesc,window:e.window}})}),getApiV1AdminFeedMetricsSlowestUsersSingle:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/slowest-users-single",params:{limit:e.limit,operation:e.operation,sortDesc:e.sortDesc,window:e.window}})}),getApiV1AdminFeedMetricsSummary:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/summary",params:{includeUserCounts:e.includeUserCounts,window:e.window}})}),getApiV1AdminFeedMetricsUserCountAll:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/user-count-all",params:{window:e.window}})}),getApiV1AdminFeedMetricsUserCountSingle:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/user-count-single",params:{operation:e.operation,window:e.window}})}),postApiV1AdminFeedRegenerateUserFeed:e.mutation({query:e=>({url:"/api/v1/admin/feed/regenerate-user-feed",method:"POST",params:{clear:e.clear,userId:e.userId,username:e.username}})}),getApiV1AdminGroupsSearch:e.query({query:e=>({url:"/api/v1/admin/groups/search",params:{accountId:e.accountId,displayName:e.displayName,domain:e.domain,email:e.email,joinMode:e.joinMode,lastId:e.lastId,limit:e.limit,offset:e.offset,privacy:e.privacy,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId,username:e.username,visibility:e.visibility}})}),getApiV1AdminGroupsUserByUserId:e.query({query:e=>({url:`/api/v1/admin/groups/user/${e.userId}`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,roles:e.roles,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1AdminGroupsByAccountId:e.query({query:e=>({url:`/api/v1/admin/groups/${e.accountId}`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1AdminGroupsByGroupIdCategories:e.query({query:e=>({url:`/api/v1/admin/groups/${e.groupId}/categories`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1AdminGroupsByGroupIdChannels:e.query({query:e=>({url:`/api/v1/admin/groups/${e.groupId}/channels`})}),getApiV1AdminGroupsByGroupIdEvents:e.query({query:e=>({url:`/api/v1/admin/groups/${e.groupId}/events`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,withTranslation:e.withTranslation}})}),getApiV1AdminImpersonate:e.query({query:e=>({url:"/api/v1/admin/impersonate",params:{username:e.username}})}),getApiV1AdminLinkService:e.query({query:()=>({url:"/api/v1/admin/link-service"})}),postApiV1AdminLinkServiceConfigure:e.mutation({query:e=>({url:"/api/v1/admin/link-service/configure",method:"POST",body:e.configureRequest})}),postApiV1AdminPostsDelete:e.mutation({query:e=>({url:"/api/v1/admin/posts/delete",method:"POST",body:e.postDelete})}),deleteApiV1AdminPurge:e.mutation({query:e=>({url:"/api/v1/admin/purge",method:"DELETE",params:{id:e.id}})}),postApiV1AdminRegenerateKeys:e.mutation({query:e=>({url:"/api/v1/admin/regenerate-keys",method:"POST",params:{userId:e.userId,username:e.username}})}),postApiV1AdminRegenerateKeysAll:e.mutation({query:e=>({url:"/api/v1/admin/regenerate-keys-all",method:"POST",params:{batch:e.batch}})}),postApiV1AdminReleaseUsername:e.mutation({query:e=>({url:"/api/v1/admin/release-username",method:"POST",params:{username:e.username}})}),postApiV1AdminReportsDeletePosts:e.mutation({query:e=>({url:"/api/v1/admin/reports/delete-posts",method:"POST",body:e.body})}),getApiV1AdminReportsList:e.query({query:e=>({url:"/api/v1/admin/reports/list",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,open:e.open,postId:e.postId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId}})}),getApiV1AdminReportsByReportId:e.query({query:e=>({url:`/api/v1/admin/reports/${e.reportId}`})}),postApiV1AdminReportsByReportIdAddNote:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/add-note`,method:"POST",body:e.body})}),postApiV1AdminReportsByReportIdAssignToSelf:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/assign-to-self`,method:"POST"})}),deleteApiV1AdminReportsByReportIdDelete:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/delete`,method:"DELETE"})}),postApiV1AdminReportsByReportIdRemoveNote:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/remove-note`,method:"POST",params:{index:e.index}})}),postApiV1AdminReportsByReportIdReopen:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/reopen`,method:"POST"})}),postApiV1AdminReportsByReportIdResolve:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/resolve`,method:"POST"})}),postApiV1AdminReportsByReportIdUnassign:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/unassign`,method:"POST"})}),postApiV1AdminRestartApDelivery:e.mutation({query:e=>({url:"/api/v1/admin/restart-ap-delivery",method:"POST",params:{domain:e.domain}})}),getApiV1AdminSearch:e.query({query:e=>({url:"/api/v1/admin/search",params:{accountId:e.accountId,actorType:e.actorType,country:e.country,displayName:e.displayName,domain:e.domain,email:e.email,ip:e.ip,kind:e.kind,lastId:e.lastId,limit:e.limit,offset:e.offset,role:e.role,search:e.search,sortBy:e.sortBy,sortOrder:e.sortOrder,state:e.state,untilId:e.untilId,userId:e.userId,username:e.username}})}),putApiV1AdminSignupRequestsApproveByHash:e.mutation({query:e=>({url:`/api/v1/admin/signup_requests/approve/${e.hash}`,method:"PUT"})}),deleteApiV1AdminSignupRequestsDeleteByHash:e.mutation({query:e=>({url:`/api/v1/admin/signup_requests/delete/${e.hash}`,method:"DELETE"})}),getApiV1AdminSignupRequestsList:e.query({query:e=>({url:"/api/v1/admin/signup_requests/list",params:{email:e.email,hash:e.hash,ip:e.ip,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),putApiV1AdminSignupRequestsRejectByHash:e.mutation({query:e=>({url:`/api/v1/admin/signup_requests/reject/${e.hash}`,method:"PUT",params:{reason:e.reason}})}),getApiV1AdminUploadsJobsQueueByQueueName:e.query({query:e=>({url:`/api/v1/admin/uploads/jobs/queue/${e.queueName}`,params:{limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,uploadType:e.uploadType}})}),getApiV1AdminUploadsJobsSummary:e.query({query:()=>({url:"/api/v1/admin/uploads/jobs/summary"})}),getApiV1AdminUploadsSearch:e.query({query:e=>({url:"/api/v1/admin/uploads/search",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,tag:e.tag,untilId:e.untilId,uploadType:e.uploadType,userId:e.userId}})}),getApiV1AdminUploadsStorageByUserId:e.query({query:e=>({url:`/api/v1/admin/uploads/storage/${e.userId}`})}),postApiV1AdminUserChangeState:e.mutation({query:e=>({url:"/api/v1/admin/user/change-state",method:"POST",body:e.changeUserState})}),postApiV1AdminUserChangeStateBulk:e.mutation({query:e=>({url:"/api/v1/admin/user/change-state-bulk",method:"POST",body:e.changeUserStateBulk})}),getApiV1AdminUserByUserId:e.query({query:e=>({url:`/api/v1/admin/user/${e.userId}`})}),getApiV1AiAgentsAssignments:e.query({query:e=>({url:"/api/v1/ai-agents/assignments",params:{resourceId:e.resourceId,type:e.type}})}),deleteApiV1AiAgentsAssignments:e.mutation({query:e=>({url:"/api/v1/ai-agents/assignments",method:"DELETE",params:{id:e.id}})}),postApiV1AiAgentsAssignments:e.mutation({query:e=>({url:"/api/v1/ai-agents/assignments",method:"POST",body:e.aiAgentAssignmentCreate})}),getApiV1AiAgentsPosts:e.query({query:e=>({url:"/api/v1/ai-agents/posts",params:{limit:e.limit,ownerId:e.ownerId,since:e.since,htmlContent:e.htmlContent}})}),getApiV1AiModels:e.query({query:e=>({url:"/api/v1/ai-models",params:{capabilities:e.capabilities,deprecated:e.deprecated,enabled:e.enabled,maxContextWindow:e.maxContextWindow,maxInputPrice:e.maxInputPrice,maxMaxOutputTokens:e.maxMaxOutputTokens,maxOutputPrice:e.maxOutputPrice,minContextWindow:e.minContextWindow,minMaxOutputTokens:e.minMaxOutputTokens,modalities:e.modalities,openWeights:e.openWeights,page:e.page,pageSize:e.pageSize,providerId:e.providerId,search:e.search}})}),putApiV1AiModelsByModelId:e.mutation({query:e=>({url:`/api/v1/ai-models/${e.modelId}`,method:"PUT",body:e.aiModelUpdate,params:{scope:e.scope}})}),getApiV1AiModelsByModelId:e.query({query:e=>({url:`/api/v1/ai-models/${e.modelId}`})}),deleteApiV1AiModelsByModelId:e.mutation({query:e=>({url:`/api/v1/ai-models/${e.modelId}`,method:"DELETE",params:{scope:e.scope}})}),getApiV1AiModelsByModelIdMigrationPath:e.query({query:e=>({url:`/api/v1/ai-models/${e.modelId}/migration-path`})}),getApiV1AiModelsByModelIdResolve:e.query({query:e=>({url:`/api/v1/ai-models/${e.modelId}/resolve`})}),getApiV1AiProviders:e.query({query:e=>({url:"/api/v1/ai-providers",params:{enabledOnly:e.enabledOnly,scope:e.scope}})}),postApiV1AiProviders:e.mutation({query:e=>({url:"/api/v1/ai-providers",method:"POST",body:e.aiProviderCreate,params:{scope:e.scope}})}),putApiV1AiProvidersByProviderId:e.mutation({query:e=>({url:`/api/v1/ai-providers/${e.providerId}`,method:"PUT",body:e.aiProviderUpdate,params:{scope:e.scope}})}),getApiV1AiProvidersByProviderId:e.query({query:e=>({url:`/api/v1/ai-providers/${e.providerId}`,params:{scope:e.scope}})}),deleteApiV1AiProvidersByProviderId:e.mutation({query:e=>({url:`/api/v1/ai-providers/${e.providerId}`,method:"DELETE",params:{scope:e.scope}})}),getApiV1AiProvidersByProviderIdModels:e.query({query:e=>({url:`/api/v1/ai-providers/${e.providerId}/models`,params:{enabledOnly:e.enabledOnly,includeDeprecated:e.includeDeprecated}})}),postApiV1AiProvidersByProviderIdModels:e.mutation({query:e=>({url:`/api/v1/ai-providers/${e.providerId}/models`,method:"POST",body:e.aiModelCreate,params:{scope:e.scope}})}),postApiV1Apps:e.mutation({query:e=>({url:"/api/v1/apps",method:"POST",body:e.body,params:{enable:e.enable}})}),getApiV1Apps:e.query({query:()=>({url:"/api/v1/apps"})}),getApiV1AppsEnabled:e.query({query:()=>({url:"/api/v1/apps/enabled"})}),getApiV1AppsInstalled:e.query({query:()=>({url:"/api/v1/apps/installed"})}),getApiV1AppsUser:e.query({query:()=>({url:"/api/v1/apps/user"})}),deleteApiV1AppsUserByAppId:e.mutation({query:e=>({url:`/api/v1/apps/user/${e.appId}`,method:"DELETE"})}),putApiV1AppsUserByAppId:e.mutation({query:e=>({url:`/api/v1/apps/user/${e.appId}`,method:"PUT"})}),putApiV1AppsByAppId:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}`,method:"PUT",body:e.body,params:{enable:e.enable}})}),getApiV1AppsByAppId:e.query({query:e=>({url:`/api/v1/apps/${e.appId}`})}),deleteApiV1AppsByAppId:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}`,method:"DELETE"})}),getApiV1AppsByAppIdData:e.query({query:e=>({url:`/api/v1/apps/${e.appId}/data`,params:{owner:e.owner,tags:e.tags,type:e.type}})}),postApiV1AppsByAppIdData:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/data`,method:"POST",body:e.dataCreate})}),putApiV1AppsByAppIdDataAndId:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/data/${e.id}`,method:"PUT",body:e.dataCreate})}),deleteApiV1AppsByAppIdDataAndId:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/data/${e.id}`,method:"DELETE"})}),putApiV1AppsByAppIdDefault:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/default`,method:"PUT"})}),putApiV1AppsByAppIdDisable:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/disable`,method:"PUT"})}),putApiV1AppsByAppIdEnable:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/enable`,method:"PUT"})}),getApiV1AppsByAppIdStats:e.query({query:e=>({url:`/api/v1/apps/${e.appId}/stats`})}),putApiV1AppsByAppIdUserDefault:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/user-default`,method:"PUT"})}),deleteApiV1AppsByAppIdUserDefault:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/user-default`,method:"DELETE"})}),getApiV1Block:e.query({query:e=>({url:"/api/v1/block",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1BlockBy:e.query({query:e=>({url:"/api/v1/block/by",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),deleteApiV1BlockByUserId:e.mutation({query:e=>({url:`/api/v1/block/${e.userId}`,method:"DELETE"})}),postApiV1BlockByUserId:e.mutation({query:e=>({url:`/api/v1/block/${e.userId}`,method:"POST"})}),getApiV1CustomEmojis:e.query({query:e=>({url:"/api/v1/custom_emojis",params:{category:e.category,lastId:e.lastId,limit:e.limit,offset:e.offset,shortcode:e.shortcode,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),deleteApiV1CustomEmojis:e.mutation({query:e=>({url:"/api/v1/custom_emojis",method:"DELETE",params:{category:e.category,shortcode:e.shortcode}})}),postApiV1CustomEmojis:e.mutation({query:e=>({url:"/api/v1/custom_emojis",method:"POST",body:e.emoji,params:{overwrite:e.overwrite}})}),getApiV1CustomEmojisCategories:e.query({query:e=>({url:"/api/v1/custom_emojis/categories",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1CustomEmojisExport:e.query({query:e=>({url:"/api/v1/custom_emojis/export",params:{category:e.category}})}),postApiV1CustomEmojisImport:e.mutation({query:e=>({url:"/api/v1/custom_emojis/import",method:"POST",body:e.body,params:{category:e.category,domain:e.domain,overwrite:e.overwrite,visible:e.visible}})}),postApiV1CustomEmojisImportUpload:e.mutation({query:e=>({url:"/api/v1/custom_emojis/import/upload",method:"POST",params:{category:e.category,domain:e.domain,overwrite:e.overwrite,uploadId:e.uploadId,visible:e.visible}})}),getApiV1CustomEmojisSearch:e.query({query:e=>({url:"/api/v1/custom_emojis/search",params:{category:e.category,lastId:e.lastId,limit:e.limit,offset:e.offset,shortcode:e.shortcode,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1CustomEmojisUpload:e.mutation({query:e=>({url:"/api/v1/custom_emojis/upload",method:"POST",params:{category:e.category,domain:e.domain,overwrite:e.overwrite,shortcode:e.shortcode,uploadId:e.uploadId,visible:e.visible}})}),patchApiV1CustomEmojisByShortcode:e.mutation({query:e=>({url:`/api/v1/custom_emojis/${e.shortcode}`,method:"PATCH",body:e.emojiPatchRequest})}),getApiV1Data:e.query({query:e=>({url:"/api/v1/data",params:{owner:e.owner,tags:e.tags,type:e.type}})}),postApiV1Data:e.mutation({query:e=>({url:"/api/v1/data",method:"POST",body:e.dataCreate})}),putApiV1DataById:e.mutation({query:e=>({url:`/api/v1/data/${e.id}`,method:"PUT",body:e.dataCreate})}),deleteApiV1DataById:e.mutation({query:e=>({url:`/api/v1/data/${e.id}`,method:"DELETE"})}),putApiV1Devices:e.mutation({query:e=>({url:"/api/v1/devices",method:"PUT",body:e.deviceRegistrationRequest})}),getApiV1Devices:e.query({query:()=>({url:"/api/v1/devices"})}),deleteApiV1DevicesAll:e.mutation({query:()=>({url:"/api/v1/devices/all",method:"DELETE"})}),getApiV1DevicesVapidPublicKey:e.query({query:()=>({url:"/api/v1/devices/vapid-public-key"})}),deleteApiV1DevicesByDeviceId:e.mutation({query:e=>({url:`/api/v1/devices/${e.deviceId}`,method:"DELETE"})}),getApiV1DomainBlock:e.query({query:e=>({url:"/api/v1/domain-block",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1Drafts:e.query({query:e=>({url:"/api/v1/drafts",params:{ownerId:e.ownerId}})}),postApiV1Drafts:e.mutation({query:e=>({url:"/api/v1/drafts",method:"POST",body:e.createDraftRequest,params:{ownerId:e.ownerId}})}),getApiV1DraftsPostByPostId:e.query({query:e=>({url:`/api/v1/drafts/post/${e.postId}`})}),putApiV1DraftsByDraftId:e.mutation({query:e=>({url:`/api/v1/drafts/${e.draftId}`,method:"PUT",body:e.updateDraftRequest})}),getApiV1DraftsByDraftId:e.query({query:e=>({url:`/api/v1/drafts/${e.draftId}`})}),deleteApiV1DraftsByDraftId:e.mutation({query:e=>({url:`/api/v1/drafts/${e.draftId}`,method:"DELETE"})}),postApiV1DraftsByDraftIdPublish:e.mutation({query:e=>({url:`/api/v1/drafts/${e.draftId}/publish`,method:"POST",params:{htmlContent:e.htmlContent}})}),getApiV1Events:e.query({query:e=>({url:"/api/v1/events",params:{groupId:e.groupId,limit:e.limit,offset:e.offset,organizerId:e.organizerId,username:e.username,withTranslation:e.withTranslation}})}),postApiV1Events:e.mutation({query:e=>({url:"/api/v1/events",method:"POST",body:e.createEvent})}),getApiV1EventsCalendarGByGroupnameIcs:e.query({query:e=>({url:`/api/v1/events/calendar/g/${e.groupname}.ics`})}),getApiV1EventsCalendarPByIdIcs:e.query({query:e=>({url:`/api/v1/events/calendar/p/${e.id}.ics`})}),getApiV1EventsCalendarUByUsernameIcs:e.query({query:e=>({url:`/api/v1/events/calendar/u/${e.username}.ics`})}),getApiV1EventsFollowing:e.query({query:e=>({url:"/api/v1/events/following",params:{limit:e.limit,offset:e.offset,withTranslation:e.withTranslation}})}),getApiV1EventsMy:e.query({query:e=>({url:"/api/v1/events/my",params:{limit:e.limit,notRespondedOnly:e.notRespondedOnly,offset:e.offset,organizedOnly:e.organizedOnly,past:e.past,withTranslation:e.withTranslation}})}),getApiV1EventsSettings:e.query({query:e=>({url:"/api/v1/events/settings",params:{ownerId:e.ownerId}})}),postApiV1EventsSettingsRegeneratePrivateId:e.mutation({query:e=>({url:"/api/v1/events/settings/regeneratePrivateId",method:"POST",params:{ownerId:e.ownerId}})}),postApiV1EventsSettingsUpdate:e.mutation({query:e=>({url:"/api/v1/events/settings/update",method:"POST",body:e.updateEventsSettings,params:{ownerId:e.ownerId}})}),putApiV1EventsByEventId:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}`,method:"PUT",body:e.updateEvent})}),getApiV1EventsByEventId:e.query({query:e=>({url:`/api/v1/events/${e.eventId}`,params:{withTranslation:e.withTranslation}})}),deleteApiV1EventsByEventId:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}`,method:"DELETE"})}),getApiV1EventsByEventIdIcs:e.query({query:e=>({url:`/api/v1/events/${e.eventId}.ics`})}),postApiV1EventsByEventIdAccept:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/accept`,method:"POST"})}),getApiV1EventsByEventIdAttendees:e.query({query:e=>({url:`/api/v1/events/${e.eventId}/attendees`,params:{limit:e.limit,offset:e.offset}})}),deleteApiV1EventsByEventIdAttendeesAndUserId:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/attendees/${e.userId}`,method:"DELETE"})}),postApiV1EventsByEventIdAttendeesAndUserId:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/attendees/${e.userId}`,method:"POST"})}),postApiV1EventsByEventIdCancel:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/cancel`,method:"POST"})}),postApiV1EventsByEventIdInterested:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/interested`,method:"POST"})}),postApiV1EventsByEventIdJoin:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/join`,method:"POST"})}),deleteApiV1EventsByEventIdJoinOrInterested:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/joinOrInterested`,method:"DELETE"})}),postApiV1EventsByEventIdMaybe:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/maybe`,method:"POST"})}),getApiV1EventsByEventIdMutual:e.query({query:e=>({url:`/api/v1/events/${e.eventId}/mutual`,params:{limit:e.limit,offset:e.offset}})}),postApiV1EventsByEventIdReject:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/reject`,method:"POST"})}),postApiV1EventsByEventIdTranslate:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/translate`,method:"POST",params:{lang:e.lang}})}),postApiV1FaspClear:e.mutation({query:()=>({url:"/api/v1/fasp/clear",method:"POST"})}),getApiV1FaspDebugV0CallbackCallbacks:e.query({query:()=>({url:"/api/v1/fasp/debug/v0/callback/callbacks"})}),deleteApiV1FaspDebugV0CallbackCallbacksById:e.mutation({query:e=>({url:`/api/v1/fasp/debug/v0/callback/callbacks/${e.id}`,method:"DELETE"})}),postApiV1FaspRegistration:e.mutation({query:e=>({url:"/api/v1/fasp/registration",method:"POST",body:e.registrationRequest})}),postApiV1FaspByProviderIdCapabilities:e.mutation({query:e=>({url:`/api/v1/fasp/${e.providerId}/capabilities`,method:"POST",body:e.body})}),postApiV1FaspByProviderIdDebugCall:e.mutation({query:e=>({url:`/api/v1/fasp/${e.providerId}/debug-call`,method:"POST",body:e.body})}),getApiV1FaspByProviderIdRegistrationFinish:e.query({query:e=>({url:`/api/v1/fasp/${e.providerId}/registration-finish`})}),postApiV1FaspByProviderIdRegistrationFinish:e.mutation({query:e=>({url:`/api/v1/fasp/${e.providerId}/registration-finish`,method:"POST"})}),postApiV1FaspByProviderIdRequestBackfill:e.mutation({query:e=>({url:`/api/v1/fasp/${e.providerId}/request_backfill`,method:"POST",params:{category:e.category}})}),postApiV1FederationTokens:e.mutation({query:e=>({url:"/api/v1/federation/tokens",method:"POST",body:e.groupFederationTokenRequest})}),getApiV1Geo:e.query({query:e=>({url:"/api/v1/geo",params:{latitude:e.latitude,longitude:e.longitude}})}),getApiV1Groups:e.query({query:e=>({url:"/api/v1/groups",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1Groups:e.mutation({query:e=>({url:"/api/v1/groups",method:"POST",body:e.groupCreate})}),getApiV1GroupsApps:e.query({query:()=>({url:"/api/v1/groups/apps"})}),getApiV1GroupsInvites:e.query({query:e=>({url:"/api/v1/groups/invites",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),getApiV1GroupsInvitesByGroupInviteId:e.query({query:e=>({url:`/api/v1/groups/invites/${e.groupInviteId}`})}),getApiV1GroupsMemberByUserId:e.query({query:e=>({url:`/api/v1/groups/member/${e.userId}`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsMemberByUserIdGroups:e.query({query:e=>({url:`/api/v1/groups/member/${e.userId}/groups`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsMyGroups:e.query({query:e=>({url:"/api/v1/groups/my-groups",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsNameByGroupname:e.query({query:e=>({url:`/api/v1/groups/name/${e.groupname}`})}),getApiV1GroupsOwned:e.query({query:e=>({url:"/api/v1/groups/owned",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsPinned:e.query({query:e=>({url:"/api/v1/groups/pinned",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsSearch:e.query({query:e=>({url:"/api/v1/groups/search",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,substring:e.substring,untilId:e.untilId}})}),getApiV1GroupsUsersByUserIdMutual:e.query({query:e=>({url:`/api/v1/groups/users/${e.userId}/mutual`})}),putApiV1GroupsByGroupId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}`,method:"PUT",body:e.groupUpdate})}),getApiV1GroupsByGroupId:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}`})}),deleteApiV1GroupsByGroupId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}`,method:"DELETE"})}),getApiV1GroupsByGroupIdAiAgentsAssignments:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/ai-agents/assignments`,params:{resourceId:e.resourceId,type:e.type}})}),deleteApiV1GroupsByGroupIdAiAgentsAssignments:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/ai-agents/assignments`,method:"DELETE",params:{assignmentId:e.assignmentId}})}),postApiV1GroupsByGroupIdAiAgentsAssignments:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/ai-agents/assignments`,method:"POST",body:e.aiAgentAssignmentCreate})}),getApiV1GroupsByGroupIdApps:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/apps`})}),deleteApiV1GroupsByGroupIdAppsAndAppId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/apps/${e.appId}`,method:"DELETE"})}),putApiV1GroupsByGroupIdAppsAndAppId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/apps/${e.appId}`,method:"PUT"})}),putApiV1GroupsByGroupIdBranding:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/branding`,method:"PUT",body:e.groupBrandingUpdate})}),getApiV1GroupsByGroupIdCategories:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/categories`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1GroupsByGroupIdCategories:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/categories`,method:"POST",body:e.categoryCreate})}),getApiV1GroupsByGroupIdCategoriesNameAndCategoryName:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/categories/name/${e.categoryName}`})}),putApiV1GroupsByGroupIdCategoriesAndCategoryId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/categories/${e.categoryId}`,method:"PUT",body:e.categoryUpdate})}),getApiV1GroupsByGroupIdCategoriesAndCategoryId:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/categories/${e.categoryId}`})}),deleteApiV1GroupsByGroupIdCategoriesAndCategoryId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/categories/${e.categoryId}`,method:"DELETE"})}),getApiV1GroupsByGroupIdChannels:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels`})}),postApiV1GroupsByGroupIdChannels:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels`,method:"POST",body:e.body,params:{htmlContent:e.htmlContent}})}),getApiV1GroupsByGroupIdChannelsDefault:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/default`})}),getApiV1GroupsByGroupIdChannelsLookup:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/lookup`,params:{full:e.full,username:e.username,htmlContent:e.htmlContent}})}),getApiV1GroupsByGroupIdChannelsMain:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/main`,params:{htmlContent:e.htmlContent}})}),getApiV1GroupsByGroupIdChannelsPublic:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/public`})}),putApiV1GroupsByGroupIdChannelsAndChannelId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}`,method:"PUT",body:e.body,params:{htmlContent:e.htmlContent}})}),getApiV1GroupsByGroupIdChannelsAndChannelId:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}`,params:{full:e.full,htmlContent:e.htmlContent}})}),deleteApiV1GroupsByGroupIdChannelsAndChannelId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}`,method:"DELETE"})}),putApiV1GroupsByGroupIdChannelsAndChannelIdDefault:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}/default`,method:"PUT",params:{isDefault:e.isDefault,htmlContent:e.htmlContent}})}),putApiV1GroupsByGroupIdChannelsAndChannelIdMain:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}/main`,method:"PUT",params:{htmlContent:e.htmlContent}})}),putApiV1GroupsByGroupIdChannelsAndChannelIdUsername:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}/username`,method:"PUT",body:e.body,params:{htmlContent:e.htmlContent}})}),postApiV1GroupsByGroupIdFederationToken:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/federation-token`,method:"POST"})}),putApiV1GroupsByGroupIdForum:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/forum`,method:"PUT",body:e.forumUpdate})}),getApiV1GroupsByGroupIdForum:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/forum`})}),deleteApiV1GroupsByGroupIdForum:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/forum`,method:"DELETE"})}),deleteApiV1GroupsByGroupIdForumHard:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/forum/hard`,method:"DELETE"})}),getApiV1GroupsByGroupIdForumStats:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/forum/stats`})}),getApiV1GroupsByGroupIdForumTags:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/forum/tags`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsByGroupIdForumTagsSearch:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/forum/tags/search`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsByGroupIdInvites:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/invites`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),postApiV1GroupsByGroupIdInvites:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/invites`,method:"POST",body:e.groupInviteCreate})}),deleteApiV1GroupsByGroupIdInvitesAndGroupInviteId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/invites/${e.groupInviteId}`,method:"DELETE"})}),postApiV1GroupsByGroupIdInvitesAndGroupInviteIdAccept:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/invites/${e.groupInviteId}/accept`,method:"POST"})}),postApiV1GroupsByGroupIdInvitesAndGroupInviteIdReject:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/invites/${e.groupInviteId}/reject`,method:"POST"})}),postApiV1GroupsByGroupIdJoin:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/join`,method:"POST",params:{answerToken:e.answerToken}})}),deleteApiV1GroupsByGroupIdJoin:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/join`,method:"DELETE"})}),getApiV1GroupsByGroupIdJoinRequests:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/join-requests`,params:{createdFrom:e.createdFrom,createdTo:e.createdTo,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId,username:e.username}})}),deleteApiV1GroupsByGroupIdJoinRequestsAndGroupJoinRequestId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/join-requests/${e.groupJoinRequestId}`,method:"DELETE",params:{purge:e.purge,reason:e.reason}})}),putApiV1GroupsByGroupIdJoinRequestsAndGroupJoinRequestId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/join-requests/${e.groupJoinRequestId}`,method:"PUT",params:{reason:e.reason}})}),putApiV1GroupsByGroupIdMemberSettings:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/member-settings`,method:"PUT",body:e.groupMemberSettings})}),getApiV1GroupsByGroupIdMemberSettings:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/member-settings`,params:{keys:e.keys}})}),deleteApiV1GroupsByGroupIdMemberSettings:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/member-settings`,method:"DELETE",params:{keys:e.keys}})}),getApiV1GroupsByGroupIdMembers:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/members`,params:{actorType:e.actorType,createdAfter:e.createdAfter,displayName:e.displayName,domain:e.domain,limit:e.limit,offset:e.offset,order:e.order,role:e.role,sort:e.sort,username:e.username}})}),postApiV1GroupsByGroupIdMembers:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/members`,method:"POST",body:e.groupMemberCreate})}),getApiV1GroupsByGroupIdMembersSearch:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/members/search`,params:{actorType:e.actorType,country:e.country,createdAfter:e.createdAfter,displayName:e.displayName,domain:e.domain,ip:e.ip,lastId:e.lastId,limit:e.limit,offset:e.offset,role:e.role,roles:e.roles,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,username:e.username}})}),putApiV1GroupsByGroupIdMembersAndMemberId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/members/${e.memberId}`,method:"PUT",body:e.groupMemberUpdate})}),deleteApiV1GroupsByGroupIdMembersAndMemberId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/members/${e.memberId}`,method:"DELETE",params:{reason:e.reason}})}),deleteApiV1GroupsByGroupIdMembership:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/membership`,method:"DELETE"})}),getApiV1GroupsByGroupIdMembership:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/membership`})}),deleteApiV1GroupsByGroupIdPin:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/pin`,method:"DELETE"})}),putApiV1GroupsByGroupIdPin:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/pin`,method:"PUT",params:{pin:e.pin}})}),getApiV1GroupsByGroupIdQuestions:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/questions`})}),postApiV1GroupsByGroupIdQuestions:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/questions`,method:"POST",body:e.questionCreate})}),postApiV1GroupsByGroupIdQuestionsAnswers:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/questions/answers`,method:"POST",body:e.questionAnswerCreate})}),putApiV1GroupsByGroupIdQuestionsAndQuestionId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/questions/${e.questionId}`,method:"PUT",body:e.questionUpdate})}),deleteApiV1GroupsByGroupIdQuestionsAndQuestionId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/questions/${e.questionId}`,method:"DELETE"})}),postApiV1GroupsByGroupIdReportsDeletePosts:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/delete-posts`,method:"POST",body:e.body})}),getApiV1GroupsByGroupIdReportsList:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/list`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,open:e.open,postId:e.postId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId}})}),getApiV1GroupsByGroupIdReportsAndReportId:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}`})}),postApiV1GroupsByGroupIdReportsAndReportIdAddNote:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}/add-note`,method:"POST",body:e.body})}),postApiV1GroupsByGroupIdReportsAndReportIdRemoveNote:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}/remove-note`,method:"POST",params:{index:e.index}})}),postApiV1GroupsByGroupIdReportsAndReportIdReopen:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}/reopen`,method:"POST"})}),postApiV1GroupsByGroupIdReportsAndReportIdResolve:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}/resolve`,method:"POST"})}),getApiV1GroupsByGroupIdRules:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/rules`})}),postApiV1GroupsByGroupIdRules:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/rules`,method:"POST",params:{hint:e.hint,ordering:e.ordering,text:e.text}})}),postApiV1GroupsByGroupIdRulesReorder:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/rules/reorder`,method:"POST",body:e.body})}),deleteApiV1GroupsByGroupIdRulesAndId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/rules/${e.id}`,method:"DELETE"})}),putApiV1GroupsByGroupIdRulesAndRuleId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/rules/${e.ruleId}`,method:"PUT",body:e.ruleUpdate})}),putApiV1GroupsByGroupIdSettings:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/settings`,method:"PUT",body:e.groupSettings})}),getApiV1GroupsByGroupIdSettings:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/settings`,params:{keys:e.keys}})}),deleteApiV1GroupsByGroupIdSettings:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/settings`,method:"DELETE",params:{keys:e.keys}})}),getApiV1GroupsByGroupIdUsers:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/users`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,order:e.order,role:e.role,sort:e.sort,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1Import:e.query({query:()=>({url:"/api/v1/import"})}),postApiV1Import:e.mutation({query:e=>({url:"/api/v1/import",method:"POST",body:e.body,params:{overwrite:e.overwrite,type:e.type}})}),postApiV1ImportStartById:e.mutation({query:e=>({url:`/api/v1/import/start/${e.id}`,method:"POST"})}),getApiV1ImportById:e.query({query:e=>({url:`/api/v1/import/${e.id}`})}),getApiV1Instance:e.query({query:()=>({url:"/api/v1/instance"})}),getApiV1InstanceCountries:e.query({query:()=>({url:"/api/v1/instance/countries"})}),getApiV1InstanceDomains:e.query({query:e=>({url:"/api/v1/instance/domains",params:{domain:e.domain,limit:e.limit,software:e.software}})}),getApiV1InstanceExtendedDescription:e.query({query:()=>({url:"/api/v1/instance/extended_description"})}),getApiV1InstanceSupportedLanguages:e.query({query:()=>({url:"/api/v1/instance/supported_languages"})}),getApiV1InstanceTimezones:e.query({query:()=>({url:"/api/v1/instance/timezones"})}),getApiV1JobsListJobs:e.query({query:e=>({url:"/api/v1/jobs/list-jobs",params:{limit:e.limit,offset:e.offset}})}),getApiV1JobsListStats:e.query({query:e=>({url:"/api/v1/jobs/list-stats",params:{queue:e.queue}})}),getApiV1JobsListStatsAll:e.query({query:()=>({url:"/api/v1/jobs/list-stats-all"})}),getApiV1JobsLists:e.query({query:e=>({url:"/api/v1/jobs/lists",params:{limit:e.limit,listKind:e.listKind,offset:e.offset,queue:e.queue}})}),getApiV1JobsStats:e.query({query:()=>({url:"/api/v1/jobs/stats"})}),getApiV1JobsStatsPerDay:e.query({query:e=>({url:"/api/v1/jobs/stats-per-day",params:{lastDays:e.lastDays,queue:e.queue}})}),getApiV1Links:e.query({query:e=>({url:"/api/v1/links",params:{url:e.url}})}),getApiV1Lists:e.query({query:()=>({url:"/api/v1/lists"})}),postApiV1Lists:e.mutation({query:e=>({url:"/api/v1/lists",method:"POST",body:e.userListCreate})}),putApiV1ListsByListId:e.mutation({query:e=>({url:`/api/v1/lists/${e.listId}`,method:"PUT",body:e.userListCreate})}),getApiV1ListsByListId:e.query({query:e=>({url:`/api/v1/lists/${e.listId}`})}),deleteApiV1ListsByListId:e.mutation({query:e=>({url:`/api/v1/lists/${e.listId}`,method:"DELETE"})}),getApiV1ListsByListIdUsers:e.query({query:e=>({url:`/api/v1/lists/${e.listId}/users`})}),deleteApiV1ListsByListIdUsersAndUserId:e.mutation({query:e=>({url:`/api/v1/lists/${e.listId}/users/${e.userId}`,method:"DELETE"})}),postApiV1ListsByListIdUsersAndUserId:e.mutation({query:e=>({url:`/api/v1/lists/${e.listId}/users/${e.userId}`,method:"POST"})}),putApiV1Markdown:e.mutation({query:e=>({url:"/api/v1/markdown",method:"PUT",body:e.body,params:{skipAutolink:e.skipAutolink}})}),getApiV1Metrics:e.query({query:e=>({url:"/api/v1/metrics",params:{from:e.from,period:e.period,to:e.to}})}),getApiV1MetricsTotals:e.query({query:()=>({url:"/api/v1/metrics/totals"})}),getApiV1Mute:e.query({query:e=>({url:"/api/v1/mute",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),deleteApiV1MuteByUserId:e.mutation({query:e=>({url:`/api/v1/mute/${e.userId}`,method:"DELETE"})}),postApiV1MuteByUserId:e.mutation({query:e=>({url:`/api/v1/mute/${e.userId}`,method:"POST",params:{duration:e.duration}})}),getApiV1NamesCheck:e.query({query:e=>({url:"/api/v1/names/check",params:{name:e.name,nameScope:e.nameScope,scope:e.scope}})}),putApiV1Notes:e.mutation({query:e=>({url:"/api/v1/notes",method:"PUT",body:e.noteUpdate})}),getApiV1Notes:e.query({query:e=>({url:"/api/v1/notes",params:{userIds:e.userIds}})}),deleteApiV1NotesByUserId:e.mutation({query:e=>({url:`/api/v1/notes/${e.userId}`,method:"DELETE"})}),getApiV1Notifications:e.query({query:e=>({url:"/api/v1/notifications",params:{excludeTypes:e.excludeTypes,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,types:e.types,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1NotificationsCount:e.query({query:e=>({url:"/api/v1/notifications/count",params:{excludeTypes:e.excludeTypes,status:e.status,types:e.types}})}),postApiV1NotificationsMarkAll:e.mutation({query:e=>({url:"/api/v1/notifications/mark-all",method:"POST",params:{status:e.status}})}),getApiV1NotificationsById:e.query({query:e=>({url:`/api/v1/notifications/${e.id}`,params:{htmlContent:e.htmlContent}})}),postApiV1NotificationsByIdMark:e.mutation({query:e=>({url:`/api/v1/notifications/${e.id}/mark`,method:"POST",params:{status:e.status,htmlContent:e.htmlContent}})}),getApiV1Passkeys:e.query({query:()=>({url:"/api/v1/passkeys"})}),getApiV1PasskeysBeginAuth:e.query({query:e=>({url:"/api/v1/passkeys/begin-auth",params:{username:e.username}})}),getApiV1PasskeysBeginRegister:e.query({query:()=>({url:"/api/v1/passkeys/begin-register"})}),postApiV1PasskeysFinishAuth:e.mutation({query:e=>({url:"/api/v1/passkeys/finish-auth",method:"POST",body:e.jsonObject})}),postApiV1PasskeysFinishRegister:e.mutation({query:e=>({url:"/api/v1/passkeys/finish-register",method:"POST",body:e.jsonObject})}),deleteApiV1PasskeysByCredentialId:e.mutation({query:e=>({url:`/api/v1/passkeys/${e.credentialId}`,method:"DELETE"})}),postApiV1PollsByPollIdRefresh:e.mutation({query:e=>({url:`/api/v1/polls/${e.pollId}/refresh`,method:"POST"})}),postApiV1PollsByPollIdVote:e.mutation({query:e=>({url:`/api/v1/polls/${e.pollId}/vote`,method:"POST",body:e.body})}),getApiV1Posts:e.query({query:e=>({url:"/api/v1/posts",params:{all:e.all,bookmarkedOnly:e.bookmarkedOnly,forumTags:e.forumTags,includeBookmarkStatus:e.includeBookmarkStatus,includeComments:e.includeComments,includeFollowStatus:e.includeFollowStatus,includePinnedStatus:e.includePinnedStatus,includeReply:e.includeReply,lastId:e.lastId,limit:e.limit,limitFirstLevelComments:e.limitFirstLevelComments,limitSecondLevelComments:e.limitSecondLevelComments,listId:e.listId,maxLevel:e.maxLevel,minLevel:e.minLevel,offset:e.offset,ownerId:e.ownerId,pinned:e.pinned,repostKind:e.repostKind,repostOf:e.repostOf,repostsOnly:e.repostsOnly,search:e.search,skipReposts:e.skipReposts,sortBy:e.sortBy,sortOrder:e.sortOrder,tag:e.tag,untilId:e.untilId,userId:e.userId,username:e.username,withRepostedBy:e.withRepostedBy,withTranslation:e.withTranslation,withTrends:e.withTrends,htmlContent:e.htmlContent}})}),postApiV1Posts:e.mutation({query:e=>({url:"/api/v1/posts",method:"POST",body:e.createPost,params:{ownerId:e.ownerId,htmlContent:e.htmlContent}})}),getApiV1PostsBookmarked:e.query({query:e=>({url:"/api/v1/posts/bookmarked",params:{includeComments:e.includeComments,includeReply:e.includeReply,lastId:e.lastId,limit:e.limit,my:e.my,offset:e.offset,ownerId:e.ownerId,search:e.search,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1PostsFeedsFollowing:e.query({query:e=>({url:"/api/v1/posts/feeds/following",params:{ignoreCache:e.ignoreCache,includeBookmarkStatus:e.includeBookmarkStatus,includeFollowStatus:e.includeFollowStatus,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,withRepostedBy:e.withRepostedBy,withTranslation:e.withTranslation,htmlContent:e.htmlContent}})}),getApiV1PostsFeedsPublic:e.query({query:e=>({url:"/api/v1/posts/feeds/public",params:{includeBookmarkStatus:e.includeBookmarkStatus,includeFollowStatus:e.includeFollowStatus,lastId:e.lastId,limit:e.limit,local:e.local,offset:e.offset,skipReposts:e.skipReposts,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,withRepostedBy:e.withRepostedBy,withTranslation:e.withTranslation,withTrends:e.withTrends,htmlContent:e.htmlContent}})}),getApiV1PostsLiked:e.query({query:e=>({url:"/api/v1/posts/liked",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1PostsMentioned:e.query({query:e=>({url:"/api/v1/posts/mentioned",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,private:e.private,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1PostsMy:e.query({query:e=>({url:"/api/v1/posts/my",params:{bookmarkedOnly:e.bookmarkedOnly,includeBookmarkStatus:e.includeBookmarkStatus,includeComments:e.includeComments,lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,repostsOnly:e.repostsOnly,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1PostsPins:e.query({query:e=>({url:"/api/v1/posts/pins",params:{ownerId:e.ownerId,postOnly:e.postOnly}})}),deleteApiV1PostsPinsByPostId:e.mutation({query:e=>({url:`/api/v1/posts/pins/${e.postId}`,method:"DELETE"})}),postApiV1PostsPinsByPostId:e.mutation({query:e=>({url:`/api/v1/posts/pins/${e.postId}`,method:"POST"})}),getApiV1PostsReplies:e.query({query:e=>({url:"/api/v1/posts/replies",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId,username:e.username,htmlContent:e.htmlContent}})}),getApiV1PostsSubscribe:e.query({query:e=>({url:"/api/v1/posts/subscribe",params:{all:e.all,ownerId:e.ownerId,htmlContent:e.htmlContent}})}),putApiV1PostsByPostId:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}`,method:"PUT",body:e.createPost,params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostId:e.query({query:e=>({url:`/api/v1/posts/${e.postId}`,params:{includeBookmarkStatus:e.includeBookmarkStatus,limitFirstLevelComments:e.limitFirstLevelComments,limitSecondLevelComments:e.limitSecondLevelComments,maxLevel:e.maxLevel,minLevel:e.minLevel,withComments:e.withComments,withParents:e.withParents,withRepostedBy:e.withRepostedBy,withRootParent:e.withRootParent,withTranslation:e.withTranslation,withTrends:e.withTrends,htmlContent:e.htmlContent}})}),deleteApiV1PostsByPostId:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}`,method:"DELETE"})}),getApiV1PostsByPostIdActiveUsers:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/active-users`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),deleteApiV1PostsByPostIdBookmark:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/bookmark`,method:"DELETE"})}),postApiV1PostsByPostIdBookmark:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/bookmark`,method:"POST"})}),getApiV1PostsByPostIdComments:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/comments`,params:{lastId:e.lastId,limit:e.limit,limitFirstLevelComments:e.limitFirstLevelComments,maxLevel:e.maxLevel,minLevel:e.minLevel,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),postApiV1PostsByPostIdComments:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/comments`,method:"POST",body:e.createPost,params:{htmlContent:e.htmlContent}})}),putApiV1PostsByPostIdCommentsAndCommentId:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/comments/${e.commentId}`,method:"PUT",body:e.createPost,params:{htmlContent:e.htmlContent}})}),deleteApiV1PostsByPostIdCommentsAndCommentId:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/comments/${e.commentId}`,method:"DELETE"})}),postApiV1PostsByPostIdDetach:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/detach`,method:"POST"})}),postApiV1PostsByPostIdDownvote:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/downvote`,method:"POST",params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostIdEdits:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/edits`,params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostIdLikes:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/likes`,params:{includeFollowedStatus:e.includeFollowedStatus,includeFollowingStatus:e.includeFollowingStatus,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),deleteApiV1PostsByPostIdLikes:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/likes`,method:"DELETE"})}),postApiV1PostsByPostIdLikes:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/likes`,method:"POST"})}),postApiV1PostsByPostIdRefreshCard:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/refresh-card`,method:"POST"})}),deleteApiV1PostsByPostIdRepost:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/repost`,method:"DELETE"})}),postApiV1PostsByPostIdRepost:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/repost`,method:"POST",body:e.createPost,params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostIdReposts:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/reposts`,params:{includeFollowedStatus:e.includeFollowedStatus,includeFollowingStatus:e.includeFollowingStatus,kind:e.kind,lastId:e.lastId,limit:e.limit,offset:e.offset,skipDuplicates:e.skipDuplicates,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),postApiV1PostsByPostIdSubscribe:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/subscribe`,method:"POST"})}),deleteApiV1PostsByPostIdSubscribe:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/subscribe`,method:"DELETE"})}),postApiV1PostsByPostIdTrackView:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/track-view`,method:"POST"})}),postApiV1PostsByPostIdTranslate:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/translate`,method:"POST",params:{htmlContent:e.htmlContent,lang:e.lang}})}),postApiV1PostsByPostIdUpvote:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/upvote`,method:"POST",params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostIdVotes:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/votes`,params:{htmlContent:e.htmlContent}})}),getApiV1Rbac:e.query({query:()=>({url:"/api/v1/rbac"})}),getApiV1RbacActorsByActorIdPermissions:e.query({query:e=>({url:`/api/v1/rbac/actors/${e.actorId}/permissions`,params:{targetScope:e.targetScope}})}),getApiV1RbacActorsByActorIdRoles:e.query({query:e=>({url:`/api/v1/rbac/actors/${e.actorId}/roles`,params:{targetScope:e.targetScope}})}),putApiV1RbacRolesByRoleId:e.mutation({query:e=>({url:`/api/v1/rbac/roles/${e.roleId}`,method:"PUT",body:e.rbacRoleTemplate})}),getApiV1RbacScopesByScopeRoles:e.query({query:e=>({url:`/api/v1/rbac/scopes/${e.scope}/roles`})}),postApiV1RbacScopesByScopeRoles:e.mutation({query:e=>({url:`/api/v1/rbac/scopes/${e.scope}/roles`,method:"POST",body:e.rbacRoleTemplate})}),deleteApiV1RbacScopesByScopeRolesAndRoleName:e.mutation({query:e=>({url:`/api/v1/rbac/scopes/${e.scope}/roles/${e.roleName}`,method:"DELETE"})}),getApiV1RbacByResource:e.query({query:e=>({url:`/api/v1/rbac/${e.resource}`})}),postApiV1Reports:e.mutation({query:e=>({url:"/api/v1/reports",method:"POST",body:e.createReport})}),putApiV1Rules:e.mutation({query:e=>({url:"/api/v1/rules",method:"PUT",body:e.rule})}),getApiV1Rules:e.query({query:()=>({url:"/api/v1/rules"})}),postApiV1Rules:e.mutation({query:e=>({url:"/api/v1/rules",method:"POST",body:e.ruleCreate})}),postApiV1RulesReorder:e.mutation({query:e=>({url:"/api/v1/rules/reorder",method:"POST",body:e.body})}),deleteApiV1RulesById:e.mutation({query:e=>({url:`/api/v1/rules/${e.id}`,method:"DELETE"})}),getApiV1Search:e.query({query:e=>({url:"/api/v1/search",params:{actorType:e.actorType,fasp:e.fasp,faspHydrated:e.faspHydrated,filter:e.filter,followStatus:e.followStatus,followers:e.followers,following:e.following,groupId:e.groupId,groupMemberRole:e.groupMemberRole,includeRelations:e.includeRelations,lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,q:e.q,resolve:e.resolve,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,withComments:e.withComments,withParent:e.withParent,htmlContent:e.htmlContent}})}),deleteApiV1SessionsAll:e.mutation({query:()=>({url:"/api/v1/sessions/all",method:"DELETE"})}),getApiV1SessionsList:e.query({query:()=>({url:"/api/v1/sessions/list"})}),putApiV1SessionsRevokeAll:e.mutation({query:()=>({url:"/api/v1/sessions/revoke/all",method:"PUT"})}),putApiV1SessionsRevokeBySessionKey:e.mutation({query:e=>({url:`/api/v1/sessions/revoke/${e.sessionKey}`,method:"PUT"})}),deleteApiV1SessionsBySessionKey:e.mutation({query:e=>({url:`/api/v1/sessions/${e.sessionKey}`,method:"DELETE"})}),putApiV1Settings:e.mutation({query:e=>({url:"/api/v1/settings",method:"PUT",body:e.platformSettings})}),getApiV1Settings:e.query({query:e=>({url:"/api/v1/settings",params:{keys:e.keys}})}),deleteApiV1Settings:e.mutation({query:e=>({url:"/api/v1/settings",method:"DELETE",params:{keys:e.keys}})}),getApiV1SettingsNames:e.query({query:e=>({url:"/api/v1/settings/names",params:{type:e.type}})}),putApiV1SettingsUser:e.mutation({query:e=>({url:"/api/v1/settings/user",method:"PUT",body:e.userSettings})}),getApiV1SettingsUser:e.query({query:e=>({url:"/api/v1/settings/user",params:{keys:e.keys}})}),deleteApiV1SettingsUser:e.mutation({query:e=>({url:"/api/v1/settings/user",method:"DELETE",params:{keys:e.keys}})}),getApiV1TagsFeatured:e.query({query:e=>({url:"/api/v1/tags/featured",params:{scope:e.scope,userId:e.userId}})}),deleteApiV1TagsFeaturedByName:e.mutation({query:e=>({url:`/api/v1/tags/featured/${e.name}`,method:"DELETE",params:{scope:e.scope}})}),postApiV1TagsFeaturedByName:e.mutation({query:e=>({url:`/api/v1/tags/featured/${e.name}`,method:"POST",params:{scope:e.scope}})}),postApiV1TagsFollowByName:e.mutation({query:e=>({url:`/api/v1/tags/follow/${e.name}`,method:"POST",params:{scope:e.scope}})}),getApiV1TagsFollowed:e.query({query:e=>({url:"/api/v1/tags/followed",params:{scope:e.scope}})}),putApiV1TagsList:e.mutation({query:e=>({url:"/api/v1/tags/list",method:"PUT",body:e.body,params:{scope:e.scope,soft:e.soft,type:e.type}})}),patchApiV1TagsList:e.mutation({query:e=>({url:"/api/v1/tags/list",method:"PATCH",body:e.body,params:{scope:e.scope,soft:e.soft,type:e.type}})}),getApiV1TagsList:e.query({query:e=>({url:"/api/v1/tags/list",params:{scope:e.scope,soft:e.soft,type:e.type}})}),deleteApiV1TagsList:e.mutation({query:e=>({url:"/api/v1/tags/list",method:"DELETE",body:e.body,params:{scope:e.scope,soft:e.soft,type:e.type}})}),putApiV1TagsPolicy:e.mutation({query:e=>({url:"/api/v1/tags/policy",method:"PUT",body:e.setTagPolicyRequest,params:{scope:e.scope}})}),getApiV1TagsPolicy:e.query({query:e=>({url:"/api/v1/tags/policy",params:{scope:e.scope}})}),postApiV1TagsReport:e.mutation({query:e=>({url:"/api/v1/tags/report",method:"POST",body:e.createTagReportRequest,params:{name:e.name,scope:e.scope}})}),getApiV1TagsReports:e.query({query:e=>({url:"/api/v1/tags/reports",params:{scope:e.scope}})}),getApiV1TagsSearch:e.query({query:e=>({url:"/api/v1/tags/search",params:{limit:e.limit,name:e.name,offset:e.offset,scope:e.scope}})}),getApiV1TagsTrending:e.query({query:e=>({url:"/api/v1/tags/trending",params:{limit:e.limit,offset:e.offset,scope:e.scope,sortBy:e.sortBy,sortOrder:e.sortOrder}})}),postApiV1TagsUnfollowByName:e.mutation({query:e=>({url:`/api/v1/tags/unfollow/${e.name}`,method:"POST",params:{scope:e.scope}})}),getApiV1TagsByName:e.query({query:e=>({url:`/api/v1/tags/${e.name}`,params:{historySince:e.historySince,scope:e.scope}})}),postApiV1TranslateText:e.mutation({query:e=>({url:"/api/v1/translate/text",method:"POST",body:e.translationRequest})}),getApiV1TrendsLinks:e.query({query:()=>({url:"/api/v1/trends/links"})}),getApiV1TrendsPosts:e.query({query:e=>({url:"/api/v1/trends/posts",params:{htmlContent:e.htmlContent}})}),getApiV1TrendsTags:e.query({query:e=>({url:"/api/v1/trends/tags",params:{scope:e.scope}})}),postApiV1Uploads:e.mutation({query:e=>({url:"/api/v1/uploads",method:"POST",body:e.createUpload})}),postApiV1UploadsBatch:e.mutation({query:e=>({url:"/api/v1/uploads/batch",method:"POST",body:e.body})}),postApiV1UploadsList:e.mutation({query:e=>({url:"/api/v1/uploads/list",method:"POST",body:e.uploadList})}),getApiV1UploadsSearch:e.query({query:e=>({url:"/api/v1/uploads/search",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,tag:e.tag,untilId:e.untilId,uploadType:e.uploadType}})}),getApiV1UploadsUsages:e.query({query:e=>({url:"/api/v1/uploads/usages",params:{ids:e.ids}})}),getApiV1UploadsById:e.query({query:e=>({url:`/api/v1/uploads/${e.id}`})}),deleteApiV1UploadsById:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}`,method:"DELETE"})}),postApiV1UploadsByIdMeta:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/meta`,method:"POST",body:e.body})}),putApiV1UploadsByIdMeta:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/meta`,method:"PUT",body:e.body})}),postApiV1UploadsByIdPrivacy:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/privacy`,method:"POST",body:e.updateUploadPrivacy})}),postApiV1UploadsByIdTags:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/tags`,method:"POST",body:e.body})}),putApiV1UploadsByIdTags:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/tags`,method:"PUT",body:e.body})}),postApiV1UploadsByIdThumbnail:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/thumbnail`,method:"POST",body:e.changeVideoThumbnail})}),getApiV1UserAlias:e.query({query:()=>({url:"/api/v1/user-alias"})}),deleteApiV1UserAlias:e.mutation({query:e=>({url:"/api/v1/user-alias",method:"DELETE",params:{uri:e.uri}})}),postApiV1UserAlias:e.mutation({query:e=>({url:"/api/v1/user-alias",method:"POST",params:{acct:e.acct}})}),getApiV1UserDomainBlock:e.query({query:()=>({url:"/api/v1/user-domain-block"})}),deleteApiV1UserDomainBlockByDomain:e.mutation({query:e=>({url:`/api/v1/user-domain-block/${e.domain}`,method:"DELETE"})}),postApiV1UserDomainBlockByDomain:e.mutation({query:e=>({url:`/api/v1/user-domain-block/${e.domain}`,method:"POST"})}),deleteApiV1Users:e.mutation({query:e=>({url:"/api/v1/users",method:"DELETE",params:{id:e.id,name:e.name}})}),postApiV1Users:e.mutation({query:e=>({url:"/api/v1/users",method:"POST",body:e.userCreate,params:{htmlContent:e.htmlContent}})}),getApiV1Users:e.query({query:e=>({url:"/api/v1/users",params:{full:e.full,includeBlockedByStatus:e.includeBlockedByStatus,includeBlockedStatus:e.includeBlockedStatus,includeFollowedStatus:e.includeFollowedStatus,includeFollowingStatus:e.includeFollowingStatus,includeMutedStatus:e.includeMutedStatus,relations:e.relations,username:e.username,htmlContent:e.htmlContent}})}),getApiV1UsersConnections:e.query({query:e=>({url:"/api/v1/users/connections",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),postApiV1UsersFollowByUsername:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}`,method:"POST",params:{domain:e.domain,mutual:e.mutual,scheme:e.scheme}})}),postApiV1UsersFollowByUsernameAccept:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}/accept`,method:"POST"})}),postApiV1UsersFollowByUsernamePend:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}/pend`,method:"POST"})}),postApiV1UsersFollowByUsernameReject:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}/reject`,method:"POST"})}),postApiV1UsersFollowByUsernameUndo:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}/undo`,method:"POST",params:{domain:e.domain,mutual:e.mutual,scheme:e.scheme}})}),getApiV1UsersFollowees:e.query({query:e=>({url:"/api/v1/users/followees",params:{anyStatus:e.anyStatus,lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),getApiV1UsersFollowers:e.query({query:e=>({url:"/api/v1/users/followers",params:{anyStatus:e.anyStatus,lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),getApiV1UsersInviteLinks:e.query({query:e=>({url:"/api/v1/users/invite-links",params:{active:e.active,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1UsersInviteLinks:e.mutation({query:e=>({url:"/api/v1/users/invite-links",method:"POST",body:e.signupInviteLinkCreate})}),putApiV1UsersInviteLinksDeactivateByCode:e.mutation({query:e=>({url:`/api/v1/users/invite-links/deactivate/${e.code}`,method:"PUT"})}),getApiV1UsersProfile:e.query({query:e=>({url:"/api/v1/users/profile",params:{htmlContent:e.htmlContent}})}),getApiV1UsersRelationships:e.query({query:e=>({url:"/api/v1/users/relationships",params:{filter:e.filter,targets:e.targets}})}),getApiV1UsersRemoteByUserNameFullFollowers:e.query({query:e=>({url:`/api/v1/users/remote/${e.userNameFull}/followers`,params:{limit:e.limit,offset:e.offset}})}),getApiV1UsersRemoteByUserNameFullFollowing:e.query({query:e=>({url:`/api/v1/users/remote/${e.userNameFull}/following`,params:{limit:e.limit,offset:e.offset}})}),getApiV1UsersRenameHistory:e.query({query:()=>({url:"/api/v1/users/rename-history"})}),putApiV1UsersByUserId:e.mutation({query:e=>({url:`/api/v1/users/${e.userId}`,method:"PUT",body:e.userUpdate,params:{htmlContent:e.htmlContent}})}),getApiV1UsersByUserId:e.query({query:e=>({url:`/api/v1/users/${e.userId}`,params:{full:e.full,includeBlockedByStatus:e.includeBlockedByStatus,includeBlockedStatus:e.includeBlockedStatus,includeFollowedStatus:e.includeFollowedStatus,includeFollowingStatus:e.includeFollowingStatus,includeMutedStatus:e.includeMutedStatus,relations:e.relations,htmlContent:e.htmlContent}})}),getApiV1UsersByUserIdFollowers:e.query({query:e=>({url:`/api/v1/users/${e.userId}/followers`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1UsersByUserIdFollowing:e.query({query:e=>({url:`/api/v1/users/${e.userId}/following`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),putApiV1UsersByUserIdMedia:e.mutation({query:e=>({url:`/api/v1/users/${e.userId}/media`,method:"PUT",body:e.userUpdateMedia,params:{htmlContent:e.htmlContent}})}),getRoot:e.query({query:e=>({url:"/",params:{format:e.format}})}),getUser:e.query({query:e=>({url:`/@${e.username}`,params:{format:e.format}})}),getUserEvent:e.query({query:e=>({url:`/@${e.username}/events/${e.eventId}`,params:{format:e.format}})}),getUserPost:e.query({query:e=>({url:`/@${e.username}/posts/${e.postId}`,params:{format:e.format}})}),getAbout:e.query({query:e=>({url:"/about",params:{format:e.format}})}),getFeed:e.query({query:e=>({url:"/feed",params:{format:e.format}})}),getFeedDiscover:e.query({query:e=>({url:"/feed/discover",params:{format:e.format}})}),getFeedFollowing:e.query({query:e=>({url:"/feed/following",params:{format:e.format}})}),getGroup:e.query({query:e=>({url:`/g/${e.groupName}`,params:{format:e.format}})}),getGroupChannel:e.query({query:e=>({url:`/g/${e.groupName}/@${e.channelName}`,params:{format:e.format}})}),getGroupChannelPost:e.query({query:e=>({url:`/g/${e.groupName}/@${e.channelName}/posts/${e.postId}`,params:{format:e.format}})}),getGroupEvent:e.query({query:e=>({url:`/g/${e.groupName}/events/${e.eventId}`,params:{format:e.format}})}),getGroupForumCategory:e.query({query:e=>({url:`/g/${e.groupName}/forum/c/${e.categoryName}`,params:{format:e.format}})}),getGroupForumPost:e.query({query:e=>({url:`/g/${e.groupName}/forum/posts/${e.postId}`,params:{format:e.format}})}),getForumTag:e.query({query:e=>({url:`/g/${e.groupName}/forum/tag/${e.tagName}`,params:{format:e.format}})}),getPrivacy:e.query({query:e=>({url:"/privacy",params:{format:e.format}})}),getTerms:e.query({query:e=>({url:"/terms",params:{format:e.format}})})}),overrideExisting:!1}),OO={forgotPasswordStep:"request",forgotPasswordFields:null,signupStep:"rules",signupFields:null,token:null,newEmail:null,isPending:!!J$.getToken(),isAuthenticated:!1,isAskLoginOpen:!1},rX=oo({name:"auth",initialState:OO,reducers:{setAskLoginOpen:(e,t)=>{e.isAskLoginOpen=t.payload},login:(e,t)=>{e.isAuthenticated=!0,e.token=t.payload||null,e.isPending=!1},logout:()=>({...OO,isPending:!1}),setNewEmail:(e,t)=>{e.newEmail=t.payload},setForgotPasswordStep:(e,t)=>{e.forgotPasswordStep=t.payload},updateForgotPasswordFields:(e,t)=>{e.forgotPasswordFields={...e.forgotPasswordFields,...t.payload}},resetForgotPasswordFields:e=>{e.forgotPasswordFields=null},setSignupStep:(e,t)=>{e.signupStep=t.payload},updateSignupFields:(e,t)=>{e.signupFields={...e.signupFields,...t.payload}},resetSignupFields:e=>{e.signupFields=null},setPending:(e,t)=>{e.isPending=t.payload}},selectors:{selectAskLoginOpen:e=>e.isAskLoginOpen,selectToken:e=>e.token,selectNewEmail:e=>e.newEmail,selectForgotPasswordStep:e=>e.forgotPasswordStep,selectForgotPasswordFields:e=>e.forgotPasswordFields,selectSignupStep:e=>e.signupStep,selectSignupFields:e=>e.signupFields,selectPending:e=>e.isPending,selectIsAuthenticated:e=>e.isAuthenticated}}),oX={data:null,isPending:!1,isSuccess:!1},iX=oo({name:"userNoHTML",initialState:oX,reducers:{setUser:(e,t)=>{e.data=t.payload},setPending:(e,t)=>{e.isPending=t.payload},setSuccess:(e,{payload:t})=>{e.isSuccess=t},setError:(e,{payload:t})=>{e.error=t}},selectors:{selectUser:e=>e.data,selectPending:e=>e.isPending,selectError:e=>e.error,selectSuccess:e=>e.isSuccess}}),AO={data:null,isError:!1,isPending:!1,isSuccess:!1},aX=oo({name:"user",initialState:AO,reducers:{reset:e=>{Object.assign(e,AO)}},extraReducers:e=>{e.addCase(RH,((e,{payload:t})=>{e.data=t})).addCase(PH,((e,{payload:t})=>{e.data&&Object.assign(e.data,t||{})})).addCase(IH,((e,{payload:t})=>{e.isSuccess=t})).addCase(CH,((e,{payload:t})=>{e.isPending=t})).addCase($H,((e,{payload:t})=>{e.isError=t})).addCase(EH,((e,{payload:t})=>{e.error=t})).addCase(TH,((e,{payload:t})=>{var n;null!=(n=e.data)&&n.users&&(e.data.users=e.data.users.map((e=>t.id===e.id?t:e)))}))},selectors:{selectIsError:e=>e.isError,selectError:e=>e.error,selectPending:e=>e.isPending,selectData:e=>e.data,selectAccount:e=>{var t;return null==(t=e.data)?void 0:t.account},selectAccountId:e=>{var t;return null==(t=e.data)?void 0:t.account.id},selectUsers:e=>{var t;return null==(t=e.data)?void 0:t.users},selectUserById:(e,t)=>{var n;return null==(n=e.data)?void 0:n.users.find((({id:e})=>e===t))},selectCurrentUser:e=>{var t;return null==(t=e.data)?void 0:t.users.find((({id:t})=>{var n;return t===(null==(n=e.data)?void 0:n.selectedUserId)}))},selectSelectedUserId:e=>{var t;return null==(t=e.data)?void 0:t.selectedUserId},selectSuccess:e=>e.isSuccess}});var LO;const sX={value:(null==(LO=Z$())?void 0:LO.initialState)??null},uX=oo({name:"initialState",initialState:sX,reducers:{setInitialState:(e,t)=>{e.value=t.payload},clearInitialState:e=>{e.value=null}},selectors:{selectInitialState:e=>e.value}}),eC=e=>e,n0=Zn(eC,(e=>e.data)),lX=Zn(eC,(e=>e.error)),cX=Zn(eC,(e=>e.isPending)),dX=Zn(n0,(e=>null==e?void 0:e.rules)),fX=Zn(n0,(e=>null==e?void 0:e.contact_account)),pX=Zn(n0,(e=>(null==e?void 0:e.stats)&&Object.fromEntries(Object.entries(e.stats).map((([e,t])=>[e,t??0]))))),mX={data:null,isPending:!1},hX=oo({name:"instanceInfo",initialState:mX,reducers:{},extraReducers:e=>{e.addCase(zH,((e,{payload:t})=>{e.data=t})).addCase(VH,((e,{payload:t})=>{e.isPending=t})).addCase(UH,((e,{payload:t})=>{e.error=t}))},selectors:{selectInstanceInfo:n0,selectInstanceInfoError:lX,selectInstanceInfoPending:cX,selectPlatformRules:dX,selectInstanceContacts:fX,selectInstanceStats:pX,selectDescription:e=>{var t;return null==(t=e.data)?void 0:t.description},selectStats:e=>{var t;return null==(t=e.data)?void 0:t.stats},selectRegistrations:e=>{var t;return null==(t=e.data)?void 0:t.configuration.registrations}}}),vX={data:null,isPending:!1,isSuccess:!1},gX=oo({name:"profileSettings",initialState:vX,reducers:{setPending:(e,t)=>{e.isPending=t.payload},setSuccess:(e,{payload:t})=>{e.isSuccess=t},setError:(e,{payload:t})=>{e.error=t}},extraReducers:e=>{e.addCase(qH,((e,{payload:t})=>{e.data=t}))},selectors:{selectProfileSettings:e=>e.data,selectPending:e=>e.isPending,selectError:e=>e.error,selectSuccess:e=>e.isSuccess}}),yX={sms:"wellesley.admin.sms",openai:"wellesley.admin.openai",uploads:"wellesley.admin.uploads",captcha:"wellesley.admin.captcha",language:"wellesley.admin.language",mediacache:"wellesley.admin.mediacache",translation:"wellesley.admin.translation",link_service:"wellesley.admin.link_service"},aE={posts:"wellesley.posts",translation:"wellesley.translation",registration:"wellesley.registration",confirmationCode:"wellesley.confirmationCode",uploadsPolicyDoc:"wellesley.uploads.policy.doc",uploadsPolicyAudio:"wellesley.uploads.policy.audio",uploadsPolicyImage:"wellesley.uploads.policy.image",uploadsPolicyVideo:"wellesley.uploads.policy.video",captcha:"wellesley.captcha",access:"wellesley.access",branding:"wellesley.branding",instanceAdmin:"wellesley.instance.admin",legal:"wellesley.instance.legal",domainBlocks:"wellesley.instance.domainBlocks",contacts:"wellesley.instance.contacts"},Im=e=>(null==e?void 0:e.map((e=>e.value||e)))||[],wX={data:null,isPending:!1},{posts:pS,uploadsPolicyDoc:MO,uploadsPolicyAudio:mS,uploadsPolicyImage:jg,uploadsPolicyVideo:Kh,registration:M3,captcha:bX,instanceAdmin:_X,branding:xX,translation:SX,domainBlocks:EX,access:$X}=aE,{captcha:CX,language:IX,translation:RX,openai:PX,link_service:TX}=yX,sp=e=>e.data,OX=Zn(sp,(e=>{var t,n,r;return{max_characters:(null==(t=null==e?void 0:e[pS])?void 0:t.max_characters)||0,max_media_attachments:(null==(n=null==e?void 0:e[pS])?void 0:n.max_media_attachments)||0,max_pins:(null==(r=null==e?void 0:e[pS])?void 0:r.max_pins)||0}})),tC=Zn(sp,(e=>{var t,n,r;return{...null==e?void 0:e[jg],maxSize:(null==(t=null==e?void 0:e[jg])?void 0:t.maxSize)||0,maxMatrix:(null==(n=null==e?void 0:e[jg])?void 0:n.maxMatrix)||0,maxResolution:(null==(r=null==e?void 0:e[jg])?void 0:r.maxResolution)||0}})),AX=Zn(tC,(e=>Im(e.extensions))),nC=Zn(sp,(e=>{var t,n,r,o;return{...null==e?void 0:e[Kh],maxSize:(null==(t=null==e?void 0:e[Kh])?void 0:t.maxSize)||0,maxMatrix:(null==(n=null==e?void 0:e[Kh])?void 0:n.maxMatrix)||0,maxDuration:(null==(r=null==e?void 0:e[Kh])?void 0:r.maxDuration)||0,maxResolution:(null==(o=null==e?void 0:e[Kh])?void 0:o.maxResolution)||0}})),MX=Zn(nC,(e=>Im(e.extensions))),D3=Zn(sp,(e=>{var t,n;return{...null==e?void 0:e[mS],maxSize:null==(t=null==e?void 0:e[mS])?void 0:t.maxSize,keepOriginal:(null==(n=null==e?void 0:e[mS])?void 0:n.keepOriginal)||0}})),N3=Zn(sp,(e=>{var t;return{...null==e?void 0:e[MO],maxSize:(null==(t=null==e?void 0:e[MO])?void 0:t.maxSize)||0}})),k3=Zn([tC,nC,D3,N3],((e,t,n,r)=>({IMAGE:Im(null==e?void 0:e.extensions),VIDEO:Im(null==t?void 0:t.extensions),AUDIO:Im(null==n?void 0:n.extensions),DOCUMENT:Im(null==r?void 0:r.extensions)}))),DX=Zn(k3,(e=>Object.keys(e).reduce(((t,n)=>[...t,...e[n]||[]]),[]))),NX=Zn(sp,(e=>{var t;return null==(t=null==e?void 0:e[M3])?void 0:t.invites})),kX=oo({name:"platformSettings",initialState:wX,reducers:{setError:(e,t)=>{e.error=t.payload},setPending:(e,t)=>{e.isPending=t.payload}},extraReducers:e=>{e.addCase(WH,((e,{payload:t})=>{e.data={...e.data,...t}}))},selectors:{selectSettings:sp,selectPostConfig:OX,selectDocPolicy:N3,selectImagePolicy:tC,selectVideoPolicy:nC,selectAudioPolicy:D3,selectInvitesEnabled:NX,selectImageExtensions:AX,selectVideoExtensions:MX,selectSupportedExtensions:k3,selectFullExtensionsList:DX,selectRegistration:e=>{var t;return null==(t=e.data)?void 0:t[M3]},selectLanguageDetection:e=>{var t;return null==(t=e.data)?void 0:t[IX]},selectLanguageTranslation:e=>{var t;return null==(t=e.data)?void 0:t[RX]},selectOpenai:e=>{var t;return null==(t=e.data)?void 0:t[PX]},selectCaptcha:e=>{var t;return null==(t=e.data)?void 0:t[bX]},selectAdminCaptcha:e=>{var t;return null==(t=e.data)?void 0:t[CX]},selectPlatformTranslation:e=>{var t;return null==(t=e.data)?void 0:t[SX]},selectAccess:e=>{var t;return null==(t=e.data)?void 0:t[$X]},selectBranding:e=>{var t;return null==(t=e.data)?void 0:t[xX]},selectLinkService:e=>{var t;return null==(t=e.data)?void 0:t[TX]},selectInstanceAdmin:e=>{var t;return null==(t=e.data)?void 0:t[_X]},selectLegal:e=>{var t;return null==(t=e.data)?void 0:t[aE.legal]},selectDomainBlocks:e=>{var t;return null==(t=e.data)?void 0:t[EX]},selectContacts:e=>{var t;return null==(t=e.data)?void 0:t[aE.contacts]}}}),DO={data:{userId:"",list:[]},count:{},isPending:!1},LX=e=>e,FX=e=>e.error,BX=e=>e.isPending,jX=e=>{var t;return null==(t=e.count)?void 0:t.total},zX=e=>{var t;return null==(t=e.count)?void 0:t.unread},VX=e=>e.data.userId,rC=Zn(LX,(e=>e.data.list)),UX=Zn(rC,(e=>null==e?void 0:e.filter((e=>"UNREAD"===e.status)))),WX=Zn(rC,(e=>null==e?void 0:e.at(-1))),qX=oo({name:"notifications",initialState:DO,reducers:{updateNotification:(e,t)=>{var n;if(!e.data.list)return;const r=t.payload;e.data.list=null==(n=e.data.list)?void 0:n.map((e=>e.id===r.id?{...e,...r}:e))},readAll:e=>{var t;e.data.list&&(e.data.list=null==(t=e.data.list)?void 0:t.map((e=>({...e,status:"READ"}))))}},extraReducers:e=>{e.addCase(NH,((e,t)=>{e.isPending=t.payload})).addCase(MH,((e,t)=>{e.error=t.payload})).addCase(DH,((e,t)=>{const n=t.payload.userId,r=t.payload.list;e.data={userId:n,list:[...e.data.list||[],...r.filter((t=>{var n;return!(null!=(n=e.data.list)&&n.some((e=>e.id===t.id)))}))]}})).addCase(OH,((e,t)=>{e.count.unread=(e.count.unread||0)+1,e.data.list&&(e.data.list=[t.payload,...e.data.list||[]])})).addCase(AH,((e,t)=>{e.data.list&&(e.data.list=e.data.list.map((e=>e.id===t.payload.id?{...e,status:t.payload.status}:e)))})).addCase(kH,((e,t)=>{e.count.total=t.payload})).addCase(LH,((e,t)=>{e.count.unread=t.payload})).addCase(BH,(()=>DO)).addCase(jH,((e,t)=>{var n,r,o;const a=t.payload;"UNREAD"===(null==(r=null==(n=e.data.list)?void 0:n.find((e=>e.id===a)))?void 0:r.status)&&e.count.unread&&(e.count.unread-=1),e.data.list=(null==(o=e.data.list)?void 0:o.filter((e=>e.id!==a)))||[]})).addCase(FH,(e=>{e.data.list&&(e.data.list=e.data.list.map((e=>"FOLLOW_REQUEST"===e.type?{...e,followResponse:"Accepted"}:e)))}))},selectors:{selectError:FX,selectIsPending:BX,selectTotalCount:jX,selectUnreadCount:zX,selectNotifications:rC,selectUnreadNotifications:UX,selectLastNotification:WX,selectNotificationsOwner:VX}}),L3=KL(nX,Kg,t3,rX,aX,iX,uX,hX,qX,gX,kX);Vn("app/hydrate");var NO,ev={exports:{}},GX=ev.exports;
88
+ */function K8(){if(eR)return nn;eR=1;var e,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),s=Symbol.for("react.context"),u=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),m=Symbol.for("react.offscreen");function v(e){if("object"==typeof e&&null!==e){var m=e.$$typeof;switch(m){case t:switch(e=e.type){case r:case a:case o:case c:case d:return e;default:switch(e=e&&e.$$typeof){case u:case s:case l:case p:case f:case i:return e;default:return m}}case n:return m}}}return e=Symbol.for("react.module.reference"),nn.ContextConsumer=s,nn.ContextProvider=i,nn.Element=t,nn.ForwardRef=l,nn.Fragment=r,nn.Lazy=p,nn.Memo=f,nn.Portal=n,nn.Profiler=a,nn.StrictMode=o,nn.Suspense=c,nn.SuspenseList=d,nn.isAsyncMode=function(){return!1},nn.isConcurrentMode=function(){return!1},nn.isContextConsumer=function(e){return v(e)===s},nn.isContextProvider=function(e){return v(e)===i},nn.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},nn.isForwardRef=function(e){return v(e)===l},nn.isFragment=function(e){return v(e)===r},nn.isLazy=function(e){return v(e)===p},nn.isMemo=function(e){return v(e)===f},nn.isPortal=function(e){return v(e)===n},nn.isProfiler=function(e){return v(e)===a},nn.isStrictMode=function(e){return v(e)===o},nn.isSuspense=function(e){return v(e)===c},nn.isSuspenseList=function(e){return v(e)===d},nn.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===r||t===a||t===o||t===c||t===d||t===m||"object"==typeof t&&null!==t&&(t.$$typeof===p||t.$$typeof===f||t.$$typeof===i||t.$$typeof===s||t.$$typeof===l||t.$$typeof===e||void 0!==t.getModuleId)},nn.typeOf=v,nn}function Y8(){return tR||(tR=1,Xw.exports=K8()),Xw.exports}function hM(){if(nR)return Jw;nR=1;var e=Cl(),t=ta();return Jw=function(n){return"number"==typeof n||t(n)&&"[object Number]"==e(n)}}function Q8(){if(rR)return Zw;rR=1;var e=hM();return Zw=function(t){return e(t)&&t!=+t}}Y8(),Q8(),hM();var tb,oR,nb,iR,rb,aR,ob,sR,ib,uR,ab,lR,sb,cR,ub,dR,lb,fR,cb,pR,db,mR,fb,hR,pb,vR,mb,gR,hb,yR,vb,wR,gb,bR,yb,_R,wb,xR,bb,SR,_b,ER,xb,$R,Sb,CR,Eb,IR,Eg=function(e){return H8(e)&&e.indexOf("%")===e.length-1},X8=function(e){return"string"==typeof e?e:e?e.displayName||e.name||"Component":""},eb=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o]};function J8(){if(oR)return tb;oR=1;var e=Ty();return tb=function(){this.__data__=new e,this.size=0}}function Z8(){if(iR)return nb;return iR=1,nb=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}}function e9(){if(aR)return rb;return aR=1,rb=function(e){return this.__data__.get(e)}}function t9(){if(sR)return ob;return sR=1,ob=function(e){return this.__data__.has(e)}}function n9(){if(uR)return ib;uR=1;var e=Ty(),t=DE(),n=NE();return ib=function(r,o){var a=this.__data__;if(a instanceof e){var i=a.__data__;if(!t||i.length<199)return i.push([r,o]),this.size=++a.size,this;a=this.__data__=new n(i)}return a.set(r,o),this.size=a.size,this}}function kE(){if(lR)return ab;lR=1;var e=Ty(),t=J8(),n=Z8(),r=e9(),o=t9(),a=n9();function i(t){var n=this.__data__=new e(t);this.size=n.size}return i.prototype.clear=t,i.prototype.delete=n,i.prototype.get=r,i.prototype.has=o,i.prototype.set=a,ab=i}function r9(){if(cR)return sb;cR=1;return sb=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}}function o9(){if(dR)return ub;return dR=1,ub=function(e){return this.__data__.has(e)}}function i9(){if(fR)return lb;fR=1;var e=NE(),t=r9(),n=o9();function r(t){var n=-1,r=null==t?0:t.length;for(this.__data__=new e;++n<r;)this.add(t[n])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,lb=r}function a9(){if(pR)return cb;return pR=1,cb=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}}function s9(){if(mR)return db;return mR=1,db=function(e,t){return e.has(t)}}function vM(){if(hR)return fb;hR=1;var e=i9(),t=a9(),n=s9();return fb=function(r,o,a,i,s,u){var l=1&a,c=r.length,d=o.length;if(c!=d&&!(l&&d>c))return!1;var f=u.get(r),p=u.get(o);if(f&&p)return f==o&&p==r;var m=-1,v=!0,h=2&a?new e:void 0;for(u.set(r,o),u.set(o,r);++m<c;){var g=r[m],y=o[m];if(i)var b=l?i(y,g,m,o,r,u):i(g,y,m,r,o,u);if(void 0!==b){if(b)continue;v=!1;break}if(h){if(!t(o,(function(e,t){if(!n(h,t)&&(g===e||s(g,e,a,i,u)))return h.push(t)}))){v=!1;break}}else if(g!==y&&!s(g,y,a,i,u)){v=!1;break}}return u.delete(r),u.delete(o),v}}function gM(){if(vR)return pb;vR=1;var e=ri().Uint8Array;return pb=e}function u9(){if(gR)return mb;return gR=1,mb=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}}function l9(){if(yR)return hb;return yR=1,hb=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}}function c9(){if(wR)return vb;wR=1;var e=zm(),t=gM(),n=ME(),r=vM(),o=u9(),a=l9(),i=e?e.prototype:void 0,s=i?i.valueOf:void 0;return vb=function(e,i,u,l,c,d,f){switch(u){case"[object DataView]":if(e.byteLength!=i.byteLength||e.byteOffset!=i.byteOffset)return!1;e=e.buffer,i=i.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=i.byteLength||!d(new t(e),new t(i)));case"[object Boolean]":case"[object Date]":case"[object Number]":return n(+e,+i);case"[object Error]":return e.name==i.name&&e.message==i.message;case"[object RegExp]":case"[object String]":return e==i+"";case"[object Map]":var p=o;case"[object Set]":var m=1&l;if(p||(p=a),e.size!=i.size&&!m)return!1;var v=f.get(e);if(v)return v==i;l|=2,f.set(e,i);var h=r(p(e),p(i),l,c,d,f);return f.delete(e),h;case"[object Symbol]":if(s)return s.call(e)==s.call(i)}return!1}}function LE(){if(bR)return gb;return bR=1,gb=function(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}}function yM(){if(_R)return yb;_R=1;var e=LE(),t=Ei();return yb=function(n,r,o){var a=r(n);return t(n)?a:e(a,o(n))}}function d9(){if(xR)return wb;return xR=1,wb=function(e,t){for(var n=-1,r=null==e?0:e.length,o=0,a=[];++n<r;){var i=e[n];t(i,n,e)&&(a[o++]=i)}return a}}function wM(){if(SR)return bb;return SR=1,bb=function(){return[]}}function FE(){if(ER)return _b;ER=1;var e=d9(),t=wM(),n=Object.prototype.propertyIsEnumerable,r=Object.getOwnPropertySymbols;return _b=r?function(t){return null==t?[]:(t=Object(t),e(r(t),(function(e){return n.call(t,e)})))}:t}function f9(){if($R)return xb;return $R=1,xb=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}}function p9(){if(CR)return Sb;CR=1;var e=Cl(),t=ta();return Sb=function(n){return t(n)&&"[object Arguments]"==e(n)}}function BE(){if(IR)return Eb;IR=1;var e=p9(),t=ta(),n=Object.prototype,r=n.hasOwnProperty,o=n.propertyIsEnumerable,a=e(function(){return arguments}())?e:function(e){return t(e)&&r.call(e,"callee")&&!o.call(e,"callee")};return Eb=a}var $b,RR,PR,Cb,TR,Ib,OR,Rb,AR,Pb,MR,Xh={exports:{}};function m9(){if(RR)return $b;return RR=1,$b=function(){return!1}}function jE(){return PR||(PR=1,e=Xh,t=Xh.exports,n=ri(),r=m9(),o=t&&!t.nodeType&&t,a=o&&e&&!e.nodeType&&e,i=a&&a.exports===o?n.Buffer:void 0,s=(i?i.isBuffer:void 0)||r,e.exports=s),Xh.exports;var e,t,n,r,o,a,i,s}function zE(){if(TR)return Cb;TR=1;var e=/^(?:0|[1-9]\d*)$/;return Cb=function(t,n){var r=typeof t;return!!(n=n??9007199254740991)&&("number"==r||"symbol"!=r&&e.test(t))&&t>-1&&t%1==0&&t<n}}function VE(){if(OR)return Ib;OR=1;return Ib=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}}function h9(){if(AR)return Rb;AR=1;var e=Cl(),t=VE(),n=ta(),r={};return r["[object Float32Array]"]=r["[object Float64Array]"]=r["[object Int8Array]"]=r["[object Int16Array]"]=r["[object Int32Array]"]=r["[object Uint8Array]"]=r["[object Uint8ClampedArray]"]=r["[object Uint16Array]"]=r["[object Uint32Array]"]=!0,r["[object Arguments]"]=r["[object Array]"]=r["[object ArrayBuffer]"]=r["[object Boolean]"]=r["[object DataView]"]=r["[object Date]"]=r["[object Error]"]=r["[object Function]"]=r["[object Map]"]=r["[object Number]"]=r["[object Object]"]=r["[object RegExp]"]=r["[object Set]"]=r["[object String]"]=r["[object WeakMap]"]=!1,Rb=function(o){return n(o)&&t(o.length)&&!!r[e(o)]}}function UE(){if(MR)return Pb;return MR=1,Pb=function(e){return function(t){return e(t)}}}Xh.exports;var DR,Tb,NR,Ob,kR,Ab,LR,Mb,FR,Db,BR,Nb,jR,kb,zR,Lb,VR,Fb,UR,Bb,WR,jb,qR,zb,GR,Vb,HR,Ub,KR,Wb,YR,qb,QR,Gb,XR,Hb,JR,Kb,ZR,Yb,eP,Qb,tP,Xb,nP,Jb,rP,Zb,oP,e_,iP,t_,aP,n_,sP,r_,uP,o_,lP,i_,cP,a_,dP,s_,fP,u_,pP,l_,mP,c_,hP,d_,vP,f_,gP,p_,yP,m_,wP,h_,bP,v_,_P,g_,xP,y_,SP,w_,EP,b_,$P,__,CP,x_,IP,S_,RP,E_,PP,$_,TP,C_,OP,I_,AP,Jh={exports:{}};function WE(){return DR||(DR=1,e=Jh,t=Jh.exports,n=sM(),r=t&&!t.nodeType&&t,o=r&&e&&!e.nodeType&&e,a=o&&o.exports===r&&n.process,i=function(){try{return o&&o.require&&o.require("util").types||a&&a.binding&&a.binding("util")}catch{}}(),e.exports=i),Jh.exports;var e,t,n,r,o,a,i}function bM(){if(NR)return Tb;NR=1;var e=h9(),t=UE(),n=WE(),r=n&&n.isTypedArray,o=r?t(r):e;return Tb=o}function _M(){if(kR)return Ob;kR=1;var e=f9(),t=BE(),n=Ei(),r=jE(),o=zE(),a=bM(),i=Object.prototype.hasOwnProperty;return Ob=function(s,u){var l=n(s),c=!l&&t(s),d=!l&&!c&&r(s),f=!l&&!c&&!d&&a(s),p=l||c||d||f,m=p?e(s.length,String):[],v=m.length;for(var h in s)(u||i.call(s,h))&&(!p||!("length"==h||d&&("offset"==h||"parent"==h)||f&&("buffer"==h||"byteLength"==h||"byteOffset"==h)||o(h,v)))&&m.push(h);return m}}function qE(){if(LR)return Ab;LR=1;var e=Object.prototype;return Ab=function(t){var n=t&&t.constructor;return t===("function"==typeof n&&n.prototype||e)}}function xM(){if(FR)return Mb;return FR=1,Mb=function(e,t){return function(n){return e(t(n))}}}function v9(){if(BR)return Db;BR=1;var e=xM()(Object.keys,Object);return Db=e}function SM(){if(jR)return Nb;jR=1;var e=qE(),t=v9(),n=Object.prototype.hasOwnProperty;return Nb=function(r){if(!e(r))return t(r);var o=[];for(var a in Object(r))n.call(r,a)&&"constructor"!=a&&o.push(a);return o}}function EM(){if(zR)return kb;zR=1;var e=Iy(),t=VE();return kb=function(n){return null!=n&&t(n.length)&&!e(n)}}function Ay(){if(VR)return Lb;VR=1;var e=_M(),t=SM(),n=EM();return Lb=function(r){return n(r)?e(r):t(r)}}function $M(){if(UR)return Fb;UR=1;var e=yM(),t=FE(),n=Ay();return Fb=function(r){return e(r,n,t)}}function g9(){if(WR)return Bb;WR=1;var e=$M(),t=Object.prototype.hasOwnProperty;return Bb=function(n,r,o,a,i,s){var u=1&o,l=e(n),c=l.length;if(c!=e(r).length&&!u)return!1;for(var d=c;d--;){var f=l[d];if(!(u?f in r:t.call(r,f)))return!1}var p=s.get(n),m=s.get(r);if(p&&m)return p==r&&m==n;var v=!0;s.set(n,r),s.set(r,n);for(var h=u;++d<c;){var g=n[f=l[d]],y=r[f];if(a)var b=u?a(y,g,f,r,n,s):a(g,y,f,n,r,s);if(!(void 0===b?g===y||i(g,y,o,a,s):b)){v=!1;break}h||(h="constructor"==f)}if(v&&!h){var w=n.constructor,x=r.constructor;w!=x&&"constructor"in n&&"constructor"in r&&!("function"==typeof w&&w instanceof w&&"function"==typeof x&&x instanceof x)&&(v=!1)}return s.delete(n),s.delete(r),v}}function y9(){if(qR)return jb;qR=1;var e=Zf()(ri(),"DataView");return jb=e}function w9(){if(GR)return zb;GR=1;var e=Zf()(ri(),"Promise");return zb=e}function b9(){if(HR)return Vb;HR=1;var e=Zf()(ri(),"Set");return Vb=e}function CM(){if(KR)return Ub;KR=1;var e=Zf()(ri(),"WeakMap");return Ub=e}function kv(){if(YR)return Wb;YR=1;var e=y9(),t=DE(),n=w9(),r=b9(),o=CM(),a=Cl(),i=uM(),s="[object Map]",u="[object Promise]",l="[object Set]",c="[object WeakMap]",d="[object DataView]",f=i(e),p=i(t),m=i(n),v=i(r),h=i(o),g=a;return(e&&g(new e(new ArrayBuffer(1)))!=d||t&&g(new t)!=s||n&&g(n.resolve())!=u||r&&g(new r)!=l||o&&g(new o)!=c)&&(g=function(e){var t=a(e),n="[object Object]"==t?e.constructor:void 0,r=n?i(n):"";if(r)switch(r){case f:return d;case p:return s;case m:return u;case v:return l;case h:return c}return t}),Wb=g}function _9(){if(QR)return qb;QR=1;var e=kE(),t=vM(),n=c9(),r=g9(),o=kv(),a=Ei(),i=jE(),s=bM(),u="[object Arguments]",l="[object Array]",c="[object Object]",d=Object.prototype.hasOwnProperty;return qb=function(f,p,m,v,h,g){var y=a(f),b=a(p),w=y?l:o(f),x=b?l:o(p),_=(w=w==u?c:w)==c,E=(x=x==u?c:x)==c,S=w==x;if(S&&i(f)){if(!i(p))return!1;y=!0,_=!1}if(S&&!_)return g||(g=new e),y||s(f)?t(f,p,m,v,h,g):n(f,p,w,m,v,h,g);if(!(1&m)){var I=_&&d.call(f,"__wrapped__"),A=E&&d.call(p,"__wrapped__");if(I||A){var k=I?f.value():f,C=A?p.value():p;return g||(g=new e),h(k,C,m,v,g)}}return!!S&&(g||(g=new e),r(f,p,m,v,h,g))}}function IM(){if(XR)return Gb;XR=1;var e=_9(),t=ta();return Gb=function n(r,o,a,i,s){return r===o||(null==r||null==o||!t(r)&&!t(o)?r!=r&&o!=o:e(r,o,a,i,n,s))},Gb}function x9(){if(JR)return Hb;JR=1;var e=kE(),t=IM();return Hb=function(n,r,o,a){var i=o.length,s=i,u=!a;if(null==n)return!s;for(n=Object(n);i--;){var l=o[i];if(u&&l[2]?l[1]!==n[l[0]]:!(l[0]in n))return!1}for(;++i<s;){var c=(l=o[i])[0],d=n[c],f=l[1];if(u&&l[2]){if(void 0===d&&!(c in n))return!1}else{var p=new e;if(a)var m=a(d,f,c,n,r,p);if(!(void 0===m?t(f,d,3,a,p):m))return!1}}return!0}}function RM(){if(ZR)return Kb;ZR=1;var e=bs();return Kb=function(t){return t==t&&!e(t)}}function S9(){if(eP)return Yb;eP=1;var e=RM(),t=Ay();return Yb=function(n){for(var r=t(n),o=r.length;o--;){var a=r[o],i=n[a];r[o]=[a,i,e(i)]}return r}}function PM(){if(tP)return Qb;return tP=1,Qb=function(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}}function E9(){if(nP)return Xb;nP=1;var e=x9(),t=S9(),n=PM();return Xb=function(r){var o=t(r);return 1==o.length&&o[0][2]?n(o[0][0],o[0][1]):function(t){return t===r||e(t,r,o)}}}function $9(){if(rP)return Jb;return rP=1,Jb=function(e,t){return null!=e&&t in Object(e)}}function C9(){if(oP)return Zb;oP=1;var e=fM(),t=BE(),n=Ei(),r=zE(),o=VE(),a=Nv();return Zb=function(i,s,u){for(var l=-1,c=(s=e(s,i)).length,d=!1;++l<c;){var f=a(s[l]);if(!(d=null!=i&&u(i,f)))break;i=i[f]}return d||++l!=c?d:!!(c=null==i?0:i.length)&&o(c)&&r(f,c)&&(n(i)||t(i))}}function I9(){if(iP)return e_;iP=1;var e=$9(),t=C9();return e_=function(n,r){return null!=n&&t(n,r,e)}}function R9(){if(aP)return t_;aP=1;var e=IM(),t=mM(),n=I9(),r=AE(),o=RM(),a=PM(),i=Nv();return t_=function(s,u){return r(s)&&o(u)?a(i(s),u):function(r){var o=t(r,s);return void 0===o&&o===u?n(r,s):e(u,o,3)}}}function GE(){if(sP)return n_;return sP=1,n_=function(e){return e}}function P9(){if(uP)return r_;return uP=1,r_=function(e){return function(t){return null==t?void 0:t[e]}}}function T9(){if(lP)return o_;lP=1;var e=pM();return o_=function(t){return function(n){return e(n,t)}}}function O9(){if(cP)return i_;cP=1;var e=P9(),t=T9(),n=AE(),r=Nv();return i_=function(o){return n(o)?e(r(o)):t(o)}}function A9(){if(dP)return a_;dP=1;var e=E9(),t=R9(),n=GE(),r=Ei(),o=O9();return a_=function(a){return"function"==typeof a?a:null==a?n:"object"==typeof a?r(a)?t(a[0],a[1]):e(a):o(a)}}function M9(){if(fP)return s_;return fP=1,s_=function(e,t,n,r){for(var o=e.length,a=n+(r?1:-1);r?a--:++a<o;)if(t(e[a],a,e))return a;return-1}}function D9(){if(pP)return u_;return pP=1,u_=function(e){return e!=e}}function N9(){if(mP)return l_;return mP=1,l_=function(e,t,n){for(var r=n-1,o=e.length;++r<o;)if(e[r]===t)return r;return-1}}function k9(){if(hP)return c_;hP=1;var e=M9(),t=D9(),n=N9();return c_=function(r,o,a){return o==o?n(r,o,a):e(r,t,a)}}function L9(){if(vP)return d_;vP=1;var e=k9();return d_=function(t,n){return!!(null==t?0:t.length)&&e(t,n,0)>-1}}function F9(){if(gP)return f_;return gP=1,f_=function(){}}function B9(){if(yP)return p_;yP=1;var e=zm(),t=BE(),n=Ei(),r=e?e.isConcatSpreadable:void 0;return p_=function(e){return n(e)||t(e)||!!(r&&e&&e[r])}}function j9(){if(wP)return m_;wP=1;var e=LE(),t=B9();return m_=function n(r,o,a,i,s){var u=-1,l=r.length;for(a||(a=t),s||(s=[]);++u<l;){var c=r[u];o>0&&a(c)?o>1?n(c,o-1,a,i,s):e(s,c):i||(s[s.length]=c)}return s},m_}function HE(){if(bP)return h_;return bP=1,h_=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}}function z9(){if(_P)return v_;_P=1;var e=HE(),t=Math.max;return v_=function(n,r,o){return r=t(void 0===r?n.length-1:r,0),function(){for(var a=arguments,i=-1,s=t(a.length-r,0),u=Array(s);++i<s;)u[i]=a[r+i];i=-1;for(var l=Array(r+1);++i<r;)l[i]=a[i];return l[r]=o(u),e(n,this,l)}},v_}function V9(){if(xP)return g_;return xP=1,g_=function(e){return function(){return e}}}function TM(){if(SP)return y_;SP=1;var e=Zf(),t=function(){try{var t=e(Object,"defineProperty");return t({},"",{}),t}catch{}}();return y_=t}function U9(){if(EP)return w_;EP=1;var e=V9(),t=TM(),n=GE();return w_=t?function(n,r){return t(n,"toString",{configurable:!0,enumerable:!1,value:e(r),writable:!0})}:n}function OM(){if($P)return b_;$P=1;var e=Date.now;return b_=function(t){var n=0,r=0;return function(){var o=e(),a=16-(o-r);if(r=o,a>0){if(++n>=800)return arguments[0]}else n=0;return t.apply(void 0,arguments)}},b_}function AM(){if(CP)return __;CP=1;var e=U9(),t=OM()(e);return __=t}function W9(){if(IP)return x_;IP=1;var e=ri();return x_=function(){return e.Date.now()}}function q9(){if(RP)return S_;RP=1;var e=/\s/;return S_=function(t){for(var n=t.length;n--&&e.test(t.charAt(n)););return n}}function G9(){if(PP)return E_;PP=1;var e=q9(),t=/^\s+/;return E_=function(n){return n&&n.slice(0,e(n)+1).replace(t,"")}}function MM(){if(TP)return $_;TP=1;var e=G9(),t=bs(),n=Dv(),r=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,a=/^0o[0-7]+$/i,i=parseInt;return $_=function(s){if("number"==typeof s)return s;if(n(s))return NaN;if(t(s)){var u="function"==typeof s.valueOf?s.valueOf():s;s=t(u)?u+"":u}if("string"!=typeof s)return 0===s?s:+s;s=e(s);var l=o.test(s);return l||a.test(s)?i(s.slice(2),l?2:8):r.test(s)?NaN:+s}}function DM(){if(OP)return C_;OP=1;var e=bs(),t=W9(),n=MM(),r=Math.max,o=Math.min;return C_=function(a,i,s){var u,l,c,d,f,p,m=0,v=!1,h=!1,g=!0;if("function"!=typeof a)throw new TypeError("Expected a function");function y(e){var t=u,n=l;return u=l=void 0,m=e,d=a.apply(n,t)}function b(e){var t=e-p;return void 0===p||t>=i||t<0||h&&e-m>=c}function w(){var e=t();if(b(e))return x(e);f=setTimeout(w,function(e){var t=i-(e-p);return h?o(t,c-(e-m)):t}(e))}function x(e){return f=void 0,g&&u?y(e):(u=l=void 0,d)}function _(){var e=t(),n=b(e);if(u=arguments,l=this,p=e,n){if(void 0===f)return function(e){return m=e,f=setTimeout(w,i),v?y(e):d}(p);if(h)return clearTimeout(f),f=setTimeout(w,i),y(p)}return void 0===f&&(f=setTimeout(w,i)),d}return i=n(i)||0,e(s)&&(v=!!s.leading,c=(h="maxWait"in s)?r(n(s.maxWait)||0,i):c,g="trailing"in s?!!s.trailing:g),_.cancel=function(){void 0!==f&&clearTimeout(f),m=0,u=p=l=f=void 0},_.flush=function(){return void 0===f?d:x(t())},_},C_}function H9(){if(AP)return I_;AP=1;var e=DM(),t=bs();return I_=function(n,r,o){var a=!0,i=!0;if("function"!=typeof n)throw new TypeError("Expected a function");return t(o)&&(a="leading"in o?!!o.leading:a,i="trailing"in o?!!o.trailing:i),e(n,r,{leading:a,maxWait:r,trailing:i})}}Jh.exports;var K9=H9();const Y9=my(K9);function vv(e){return(vv="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function MP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function $g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?MP(Object(n),!0).forEach((function(t){Q9(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):MP(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Q9(e,t,n){return(t=X9(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function X9(e){var t=J9(e,"string");return"symbol"==vv(t)?t:t+""}function J9(e,t){if("object"!=vv(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=vv(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function Z9(e,t){return rF(e)||nF(e,t)||tF(e,t)||eF()}function eF(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function tF(e,t){if(e){if("string"==typeof e)return DP(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return DP(e,t)}}function DP(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function nF(e,t){var n=null==e?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],u=!0,l=!1;try{if(a=(n=n.call(e)).next,0!==t)for(;!(u=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);u=!0);}catch(e){l=!0,o=e}finally{try{if(!u&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(l)throw o}}return s}}function rF(e){if(Array.isArray(e))return e}var R_,NP,P_,kP,T_,LP,O_,FP,A_,BP,M_,jP,D_,zP,N_,VP,k_,UP,L_,WP,F_,qP,B_,GP,j_,HP,oF=v.forwardRef((function(e,t){var n=e.aspect,r=e.initialDimension,o=void 0===r?{width:-1,height:-1}:r,a=e.width,i=void 0===a?"100%":a,s=e.height,u=void 0===s?"100%":s,l=e.minWidth,c=void 0===l?0:l,d=e.minHeight,f=e.maxHeight,p=e.children,m=e.debounce,h=void 0===m?0:m,g=e.id,y=e.className,b=e.onResize,w=e.style,x=void 0===w?{}:w,_=v.useRef(null),E=v.useRef();E.current=b,v.useImperativeHandle(t,(function(){return Object.defineProperty(_.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),_.current},configurable:!0})}));var S=Z9(v.useState({containerWidth:o.width,containerHeight:o.height}),2),I=S[0],A=S[1],k=v.useCallback((function(e,t){A((function(n){var r=Math.round(e),o=Math.round(t);return n.containerWidth===r&&n.containerHeight===o?n:{containerWidth:r,containerHeight:o}}))}),[]);v.useEffect((function(){var e=function(e){var t,n=e[0].contentRect,r=n.width,o=n.height;k(r,o),null===(t=E.current)||void 0===t||t.call(E,r,o)};h>0&&(e=Y9(e,h,{trailing:!0,leading:!1}));var t=new ResizeObserver(e),n=_.current.getBoundingClientRect(),r=n.width,o=n.height;return k(r,o),t.observe(_.current),function(){t.disconnect()}}),[k,h]);var C=v.useMemo((function(){var e=I.containerWidth,t=I.containerHeight;if(e<0||t<0)return null;eb(Eg(i)||Eg(u),"The width(%s) and height(%s) are both fixed numbers,\n maybe you don't need to use a ResponsiveContainer.",i,u),eb(!n||n>0,"The aspect(%s) must be greater than zero.",n);var r=Eg(i)?e:i,o=Eg(u)?t:u;n&&n>0&&(r?o=r/n:o&&(r=o*n),f&&o>f&&(o=f)),eb(r>0||o>0,"The width(%s) and height(%s) of chart should be greater than 0,\n please check the style of container, or the props width(%s) and height(%s),\n or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the\n height and width.",r,o,i,u,c,d,n);var a=!Array.isArray(p)&&X8(p.type).endsWith("Chart");return Ue.Children.map(p,(function(e){return Ue.isValidElement(e)?v.cloneElement(e,$g({width:r,height:o},a?{style:$g({height:"100%",width:"100%",maxHeight:o,maxWidth:r},e.props.style)}:{})):e}))}),[n,p,u,f,d,c,I,i]);return Ue.createElement("div",{id:g?"".concat(g):void 0,className:cA("recharts-responsive-container",y),style:$g($g({},x),{},{width:i,height:u,minWidth:c,minHeight:d,maxHeight:f}),ref:_},C)}));function KE(){if(NP)return R_;NP=1;var e=xM()(Object.getPrototypeOf,Object);return R_=e}function iF(){if(kP)return P_;kP=1;var e=Cl(),t=KE(),n=ta(),r=Function.prototype,o=Object.prototype,a=r.toString,i=o.hasOwnProperty,s=a.call(Object);return P_=function(r){if(!n(r)||"[object Object]"!=e(r))return!1;var o=t(r);if(null===o)return!0;var u=i.call(o,"constructor")&&o.constructor;return"function"==typeof u&&u instanceof u&&a.call(u)==s}}function aF(){if(LP)return T_;LP=1;var e=MM(),t=1/0;return T_=function(n){return n?(n=e(n))===t||n===-t?17976931348623157e292*(n<0?-1:1):n==n?n:0:0===n?n:0}}function NM(){if(FP)return O_;FP=1;var e=TM();return O_=function(t,n,r){"__proto__"==n&&e?e(t,n,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[n]=r}}function kM(){if(BP)return A_;BP=1;var e=aF();return A_=function(t){var n=e(t),r=n%1;return n==n?r?n-r:n:0}}function YE(){if(jP)return M_;return jP=1,M_=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}}function LM(){if(zP)return D_;zP=1;var e=NM(),t=ME(),n=Object.prototype.hasOwnProperty;return D_=function(r,o,a){var i=r[o];(!n.call(r,o)||!t(i,a)||void 0===a&&!(o in r))&&e(r,o,a)}}function My(){if(VP)return N_;VP=1;var e=LM(),t=NM();return N_=function(n,r,o,a){var i=!o;o||(o={});for(var s=-1,u=r.length;++s<u;){var l=r[s],c=a?a(o[l],n[l],l,o,n):void 0;void 0===c&&(c=n[l]),i?t(o,l,c):e(o,l,c)}return o}}function FM(){if(UP)return k_;UP=1;var e=My(),t=Ay();return k_=function(n,r){return n&&e(r,t(r),n)}}function sF(){if(WP)return L_;return WP=1,L_=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}}function uF(){if(qP)return F_;qP=1;var e=bs(),t=qE(),n=sF(),r=Object.prototype.hasOwnProperty;return F_=function(o){if(!e(o))return n(o);var a=t(o),i=[];for(var s in o)"constructor"==s&&(a||!r.call(o,s))||i.push(s);return i}}function QE(){if(GP)return B_;GP=1;var e=_M(),t=uF(),n=EM();return B_=function(r){return n(r)?e(r,!0):t(r)}}function lF(){if(HP)return j_;HP=1;var e=My(),t=QE();return j_=function(n,r){return n&&e(r,t(r),n)}}var KP,z_,YP,V_,QP,U_,XP,W_,JP,q_,ZP,G_,eT,H_,tT,K_,nT,Y_,rT,Q_,oT,X_,iT,J_,aT,Z_,sT,ex,uT,tx,lT,nx,cT,rx,dT,ox,fT,ix,pT,ax,mT,sx,hT,Zh={exports:{}};function cF(){return KP||(KP=1,e=Zh,t=Zh.exports,n=ri(),r=t&&!t.nodeType&&t,o=r&&e&&!e.nodeType&&e,a=o&&o.exports===r?n.Buffer:void 0,i=a?a.allocUnsafe:void 0,e.exports=function(e,t){if(t)return e.slice();var n=e.length,r=i?i(n):new e.constructor(n);return e.copy(r),r}),Zh.exports;var e,t,n,r,o,a,i}function Dy(){if(YP)return z_;return YP=1,z_=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}}function dF(){if(QP)return V_;QP=1;var e=My(),t=FE();return V_=function(n,r){return e(n,t(n),r)}}function BM(){if(XP)return U_;XP=1;var e=LE(),t=KE(),n=FE(),r=wM(),o=Object.getOwnPropertySymbols;return U_=o?function(r){for(var o=[];r;)e(o,n(r)),r=t(r);return o}:r}function fF(){if(JP)return W_;JP=1;var e=My(),t=BM();return W_=function(n,r){return e(n,t(n),r)}}function pF(){if(ZP)return q_;ZP=1;var e=yM(),t=BM(),n=QE();return q_=function(r){return e(r,n,t)}}function mF(){if(eT)return G_;eT=1;var e=Object.prototype.hasOwnProperty;return G_=function(t){var n=t.length,r=new t.constructor(n);return n&&"string"==typeof t[0]&&e.call(t,"index")&&(r.index=t.index,r.input=t.input),r}}function XE(){if(tT)return H_;tT=1;var e=gM();return H_=function(t){var n=new t.constructor(t.byteLength);return new e(n).set(new e(t)),n}}function hF(){if(nT)return K_;nT=1;var e=XE();return K_=function(t,n){var r=n?e(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}}function vF(){if(rT)return Y_;rT=1;var e=/\w*$/;return Y_=function(t){var n=new t.constructor(t.source,e.exec(t));return n.lastIndex=t.lastIndex,n}}function gF(){if(oT)return Q_;oT=1;var e=zm(),t=e?e.prototype:void 0,n=t?t.valueOf:void 0;return Q_=function(e){return n?Object(n.call(e)):{}}}function yF(){if(iT)return X_;iT=1;var e=XE();return X_=function(t,n){var r=n?e(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}}function wF(){if(aT)return J_;aT=1;var e=XE(),t=hF(),n=vF(),r=gF(),o=yF();return J_=function(a,i,s){var u=a.constructor;switch(i){case"[object ArrayBuffer]":return e(a);case"[object Boolean]":case"[object Date]":return new u(+a);case"[object DataView]":return t(a,s);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return o(a,s);case"[object Map]":case"[object Set]":return new u;case"[object Number]":case"[object String]":return new u(a);case"[object RegExp]":return n(a);case"[object Symbol]":return r(a)}}}function Ny(){if(sT)return Z_;sT=1;var e=bs(),t=Object.create;return Z_=function(){function n(){}return function(r){if(!e(r))return{};if(t)return t(r);n.prototype=r;var o=new n;return n.prototype=void 0,o}}()}function bF(){if(uT)return ex;uT=1;var e=Ny(),t=KE(),n=qE();return ex=function(r){return"function"!=typeof r.constructor||n(r)?{}:e(t(r))}}function _F(){if(lT)return tx;lT=1;var e=kv(),t=ta();return tx=function(n){return t(n)&&"[object Map]"==e(n)}}function xF(){if(cT)return nx;cT=1;var e=_F(),t=UE(),n=WE(),r=n&&n.isMap,o=r?t(r):e;return nx=o}function SF(){if(dT)return rx;dT=1;var e=kv(),t=ta();return rx=function(n){return t(n)&&"[object Set]"==e(n)}}function EF(){if(fT)return ox;fT=1;var e=SF(),t=UE(),n=WE(),r=n&&n.isSet,o=r?t(r):e;return ox=o}function jM(){if(pT)return ix;pT=1;var e=kE(),t=YE(),n=LM(),r=FM(),o=lF(),a=cF(),i=Dy(),s=dF(),u=fF(),l=$M(),c=pF(),d=kv(),f=mF(),p=wF(),m=bF(),v=Ei(),h=jE(),g=xF(),y=bs(),b=EF(),w=Ay(),x=QE(),_="[object Arguments]",E="[object Function]",S="[object Object]",I={};return I[_]=I["[object Array]"]=I["[object ArrayBuffer]"]=I["[object DataView]"]=I["[object Boolean]"]=I["[object Date]"]=I["[object Float32Array]"]=I["[object Float64Array]"]=I["[object Int8Array]"]=I["[object Int16Array]"]=I["[object Int32Array]"]=I["[object Map]"]=I["[object Number]"]=I[S]=I["[object RegExp]"]=I["[object Set]"]=I["[object String]"]=I["[object Symbol]"]=I["[object Uint8Array]"]=I["[object Uint8ClampedArray]"]=I["[object Uint16Array]"]=I["[object Uint32Array]"]=!0,I["[object Error]"]=I[E]=I["[object WeakMap]"]=!1,ix=function A(k,C,T,R,P,O){var N,M=1&C,j=2&C,D=4&C;if(T&&(N=P?T(k,R,P,O):T(k)),void 0!==N)return N;if(!y(k))return k;var q=v(k);if(q){if(N=f(k),!M)return i(k,N)}else{var z=d(k),L=z==E||"[object GeneratorFunction]"==z;if(h(k))return a(k,M);if(z==S||z==_||L&&!P){if(N=j||L?{}:m(k),!M)return j?u(k,o(N,k)):s(k,r(N,k))}else{if(!I[z])return P?k:{};N=p(k,z,M)}}O||(O=new e);var $=O.get(k);if($)return $;O.set(k,N),b(k)?k.forEach((function(e){N.add(A(e,C,T,e,k,O))})):g(k)&&k.forEach((function(e,t){N.set(t,A(e,C,T,t,k,O))}));var V=q?void 0:(D?j?c:l:j?x:w)(k);return t(V||k,(function(e,t){V&&(e=k[t=e]),n(N,t,A(e,C,T,t,k,O))})),N},ix}function $F(){if(mT)return ax;mT=1;var e=j9();return ax=function(t){return(null==t?0:t.length)?e(t,1):[]}}function CF(){if(hT)return sx;hT=1;var e=$F(),t=z9(),n=AM();return sx=function(r){return n(t(r,void 0,e),r+"")}}Zh.exports;const IF={light:"",dark:".dark"},zM=v.createContext(null);function VM(){const e=v.useContext(zM);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}const RF=v.forwardRef((({id:e,className:t,children:n,config:r,...o},a)=>{const i=v.useId(),s=`chart-${e||i.replace(/:/g,"")}`;return G.jsx(zM.Provider,{value:{config:r},children:G.jsxs("div",{"data-chart":s,ref:a,className:we("flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-none [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-sector]:outline-none [&_.recharts-surface]:outline-none",t),...o,children:[G.jsx(PF,{id:s,config:r}),G.jsx(oF,{children:n})]})})}));RF.displayName="Chart";const PF=({id:e,config:t})=>{const n=Object.entries(t).filter((([,e])=>e.theme||e.color));return n.length?G.jsx("style",{dangerouslySetInnerHTML:{__html:Object.entries(IF).map((([t,r])=>`\n${r} [data-chart=${e}] {\n${n.map((([e,n])=>{var r;const o=(null==(r=n.theme)?void 0:r[t])||n.color;return o?` --color-${e}: ${o};`:null})).join("\n")}\n}\n`)).join("\n")}}):null},TF=v.forwardRef((({active:e,payload:t,className:n,indicator:r="dot",hideLabel:o=!1,hideIndicator:a=!1,label:i,labelFormatter:s,labelClassName:u,formatter:l,color:c,nameKey:d,labelKey:f,hoveredItem:p,onItemHover:m},h)=>{const{config:g}=VM(),y=v.useMemo((()=>{var e;if(o||null==t||!t.length)return null;const[n]=t,r=`${f||(null==n?void 0:n.dataKey)||(null==n?void 0:n.name)||"value"}`,a=NS(g,n,r),l=f||"string"!=typeof i?null==a?void 0:a.label:(null==(e=g[i])?void 0:e.label)||i;return s?G.jsx("div",{className:we("font-medium",u),children:s(l,t)}):l?G.jsx("div",{className:we("font-medium",u),children:l}):null}),[i,s,t,o,u,g,f]);if(!e||null==t||!t.length)return null;const b=1===t.length&&"dot"!==r,w=t.length>10;return G.jsxs("div",{ref:h,className:we("grid min-w-[8rem] items-start gap-xxs rounded-sm border border-border/50 bg-background px-xs py-xxs text-xs shadow-xl",w&&"min-w-[16rem]",n),children:[b?null:y,G.jsx("div",{className:we("grid gap-xxs",w&&"grid-cols-2 gap-x-s"),children:t.map(((e,t)=>{var n;const o=`${d||e.name||e.dataKey||"value"}`,i=NS(g,e,o),s=c||(null==(n=e.payload)?void 0:n.fill)||e.color||"",u=o===p;return G.jsx("div",{className:we("flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5 [&>svg]:text-muted-foreground","dot"===r&&"items-center",u?"":p?"opacity-40":""),onMouseEnter:()=>null==m?void 0:m(o),onMouseLeave:()=>null==m?void 0:m(null),children:l&&void 0!==(null==e?void 0:e.value)&&void 0!==(null==e?void 0:e.payload)&&e.name?l(e.value,e.name,e,t,[e.payload]):G.jsxs(G.Fragment,{children:[null!=i&&i.icon?G.jsx(i.icon,{}):!a&&G.jsx("div",{className:we("shrink-0 rounded-full border-[--color-border] bg-[--color-bg]",{"h-2.5 w-2.5":"dot"===r,"w-1":"line"===r,"w-0 border border-dashed bg-transparent":"dashed"===r,"my-0.5":b&&"dashed"===r}),style:{"--color-bg":s,"--color-border":s}}),G.jsxs("div",{className:we("flex flex-1 justify-between leading-none",b?"items-end":"items-center"),children:[G.jsxs("div",{className:"grid gap-xxs",children:[b?y:null,G.jsx("span",{className:we("text-muted-foreground",u&&"font-medium text-foreground"),children:(null==i?void 0:i.label)||e.name})]}),e.value&&G.jsx("span",{className:we("font-mono font-medium tabular-nums text-foreground",u&&"font-bold"),children:e.value.toLocaleString()})]})]})},e.dataKey)}))})]})}));TF.displayName="ChartTooltip";const OF=v.forwardRef((({className:e,hideIcon:t=!1,payload:n,nameKey:r,onItemHover:o,hoveredItem:a},i)=>{const{config:s}=VM(),u=v.useRef({});return v.useEffect((()=>{if(a&&u.current[a]){const e=u.current[a];e&&e.scrollIntoView({behavior:"smooth",block:"nearest"})}}),[a]),null!=n&&n.length?G.jsx("div",{ref:i,className:we("flex h-[150px] w-full flex-wrap items-center justify-center gap-l overflow-y-auto pb-xl",e),children:n.map((e=>{var n;const i=`${r||e.dataKey||"value"}`,l=NS(s,e,i),c=!!o&&i===a;return G.jsxs("div",{ref:e=>{e?u.current[i]=e:delete u.current[i]},className:we("group flex cursor-pointer select-none items-center gap-xs text-base transition-all duration-150",c?"scale-105 text-black":a?"text-gray-700 opacity-40":"text-gray-700"),onMouseEnter:()=>null==o?void 0:o(e.dataKey),onMouseLeave:()=>null==o?void 0:o(null),children:[null!=l&&l.icon&&!t?G.jsx(l.icon,{}):G.jsx("div",{className:"h-2 w-2 shrink-0 rounded-full",style:{backgroundColor:e.color||""}}),G.jsx("span",{className:"min-w-[max-content]",children:(null==l?void 0:l.label)||e.name})]},(null==(n=e.value)?void 0:n.toString())||i)}))}):null}));function NS(e,t,n){if("object"!=typeof t||null===t)return;const r="payload"in t&&"object"==typeof t.payload&&null!==t.payload?t.payload:void 0;let o=n;return n in t&&"string"==typeof t[n]?o=t[n]:r&&n in r&&"string"==typeof r[n]&&(o=r[n]),o in e?e[o]:e[n]}OF.displayName="ChartLegend";const AF=({children:e,className:t})=>G.jsx("div",{className:we("flex flex-wrap gap-xxxs",t),children:e}),UM=({text:e,icon:t,disabled:n,isLoading:r,avatarSrc:o,onClick:a,onRemove:i,className:s})=>G.jsxs("div",{onClick:n?void 0:a,className:we("flex cursor-pointer items-center gap-xxxs rounded-sm bg-gray-100 p-xxs text-sm font-medium text-gray-900 transition-all hover:bg-gray-200 [&_svg]:size-4",n&&"cursor-not-allowed bg-gray-100 text-gray-300",s),children:[o&&G.jsxs(JA,{className:we("size-6 text-[10px]"),children:[G.jsx(ZA,{src:o,alt:e}),G.jsx(eM,{className:"text-xs",children:e.charAt(0).toUpperCase()})]}),t,G.jsx("span",{children:e}),i&&!r&&G.jsx("span",{role:"button",tabIndex:-1,onClick:e=>{e.stopPropagation(),e.preventDefault(),!n&&(null==i||i())},onPointerDown:e=>{e.stopPropagation(),e.preventDefault()},className:we("pointer-events-auto cursor-pointer",n&&"pointer-events-none cursor-not-allowed opacity-50"),children:G.jsx(gy,{size:16})}),r&&G.jsx(sA,{size:16,className:"animate-spin"})]});function ky(e){const t=v.useRef({value:e,previous:e});return v.useMemo((()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous)),[e])}function Ly(e){const[t,n]=v.useState(void 0);return Vo((()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const t=new ResizeObserver((t=>{if(!Array.isArray(t)||!t.length)return;const r=t[0];let o,a;if("borderBoxSize"in r){const e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;o=t.inlineSize,a=t.blockSize}else o=e.offsetWidth,a=e.offsetHeight;n({width:o,height:a})}));return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)}),[e]),t}const WM="Checkbox",[MF,UJ]=ni(WM),[DF,NF]=MF(WM),kF=v.forwardRef(((e,t)=>{const{__scopeCheckbox:n,name:r,checked:o,defaultChecked:a,required:i,disabled:s,value:u="on",onCheckedChange:l,...c}=e,[d,f]=v.useState(null),p=Vt(t,(e=>f(e))),m=v.useRef(!1),h=!d||!!d.closest("form"),[g=!1,y]=fd({prop:o,defaultProp:a,onChange:l}),b=v.useRef(g);return v.useEffect((()=>{const e=null==d?void 0:d.form;if(e){const t=()=>y(b.current);return e.addEventListener("reset",t),()=>e.removeEventListener("reset",t)}}),[d,y]),v.createElement(DF,{scope:n,state:g,disabled:s},v.createElement(ft.button,Te({type:"button",role:"checkbox","aria-checked":Bf(g)?"mixed":g,"aria-required":i,"data-state":qM(g),"data-disabled":s?"":void 0,disabled:s,value:u},c,{ref:p,onKeyDown:et(e.onKeyDown,(e=>{"Enter"===e.key&&e.preventDefault()})),onClick:et(e.onClick,(e=>{y((e=>!!Bf(e)||!e)),h&&(m.current=e.isPropagationStopped(),m.current||e.stopPropagation())}))})),h&&v.createElement(BF,{control:d,bubbles:!m.current,name:r,value:u,checked:g,required:i,disabled:s,style:{transform:"translateX(-100%)"}}))})),LF="CheckboxIndicator",FF=v.forwardRef(((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...o}=e,a=NF(LF,n);return v.createElement(ea,{present:r||Bf(a.state)||!0===a.state},v.createElement(ft.span,Te({"data-state":qM(a.state),"data-disabled":a.disabled?"":void 0},o,{ref:t,style:{pointerEvents:"none",...e.style}})))})),BF=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,a=v.useRef(null),i=ky(n),s=Ly(t);return v.useEffect((()=>{const e=a.current,t=window.HTMLInputElement.prototype,o=Object.getOwnPropertyDescriptor(t,"checked").set;if(i!==n&&o){const t=new Event("click",{bubbles:r});e.indeterminate=Bf(n),o.call(e,!Bf(n)&&n),e.dispatchEvent(t)}}),[i,n,r]),v.createElement("input",Te({type:"checkbox","aria-hidden":!0,defaultChecked:!Bf(n)&&n},o,{tabIndex:-1,ref:a,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function Bf(e){return"indeterminate"===e}function qM(e){return Bf(e)?"indeterminate":e?"checked":"unchecked"}const GM=kF,jF=FF,zF=gu("relative overflow-hidden ",{variants:{size:{default:"size-xs"},variant:{default:"peer shrink-0 rounded-sm border disabled:cursor-not-allowed disabled:!border-0 disabled:!bg-gray-100"}},defaultVariants:{size:"default",variant:"default"}}),JE=v.forwardRef((({className:e,size:t,variant:n,iconType:r,...o},a)=>{const i=o.checked,[s]=v.useState(i),[u,l]=v.useState(!1);v.useEffect((()=>{s!==i&&l(!0)}),[i]);const c=e=>"minus"===r?G.jsx(q5,{...e}):G.jsx(vE,{...e});return G.jsxs(GM,{ref:a,className:we(zF({size:t,variant:n}),"transition-[border] duration-100 ease-linear",i?"border-0":"border-gray-300 hover:border-2",e),...o,children:[G.jsx("div",{className:we("transform-origin-center absolute left-0 top-0 size-full rounded-full bg-blue_100",i?"scale-[1.2]":"scale-0",{"animate-fill-in":i&&u,"animate-fill-out":!i&&u})}),G.jsx(jF,{className:"relative flex items-center justify-center text-current",children:G.jsx(c,{className:"size-xxxs",color:o.disabled?"var(--gray-300)":"white"})})]})}));JE.displayName=GM.displayName;var vT=1,VF=.9,UF=.8,WF=.17,ux=.1,lx=.999,qF=.9999,GF=.99,HF=/[\\\/_+.#"@\[\(\{&]/,KF=/[\\\/_+.#"@\[\(\{&]/g,YF=/[\s-]/,HM=/[\s-]/g;function kS(e,t,n,r,o,a,i){if(a===t.length)return o===e.length?vT:GF;var s=`${o},${a}`;if(void 0!==i[s])return i[s];for(var u,l,c,d,f=r.charAt(a),p=n.indexOf(f,o),m=0;p>=0;)(u=kS(e,t,n,r,p+1,a+1,i))>m&&(p===o?u*=vT:HF.test(e.charAt(p-1))?(u*=UF,(c=e.slice(o,p-1).match(KF))&&o>0&&(u*=Math.pow(lx,c.length))):YF.test(e.charAt(p-1))?(u*=VF,(d=e.slice(o,p-1).match(HM))&&o>0&&(u*=Math.pow(lx,d.length))):(u*=WF,o>0&&(u*=Math.pow(lx,p-o))),e.charAt(p)!==t.charAt(a)&&(u*=qF)),(u<ux&&n.charAt(p-1)===r.charAt(a+1)||r.charAt(a+1)===r.charAt(a)&&n.charAt(p-1)!==r.charAt(a))&&((l=kS(e,t,n,r,p+1,a+2,i))*ux>u&&(u=l*ux)),u>m&&(m=u),p=n.indexOf(f,p+1);return i[s]=m,m}function gT(e){return e.toLowerCase().replace(HM," ")}function QF(e,t,n){return kS(e=n&&n.length>0?""+(e+" "+n.join(" ")):e,t,gT(e),gT(t),0,0,{})}var Wh='[cmdk-group=""]',cx='[cmdk-group-items=""]',XF='[cmdk-group-heading=""]',ZE='[cmdk-item=""]',yT=`${ZE}:not([aria-disabled="true"])`,LS="cmdk-item-select",Nf="data-value",JF=(e,t,n)=>QF(e,t,n),KM=v.createContext(void 0),Lv=()=>v.useContext(KM),YM=v.createContext(void 0),e$=()=>v.useContext(YM),QM=v.createContext(void 0),XM=v.forwardRef(((e,t)=>{let n=$m((()=>{var t,n;return{search:"",value:null!=(n=null!=(t=e.value)?t:e.defaultValue)?n:"",filtered:{count:0,items:new Map,groups:new Set}}})),r=$m((()=>new Set)),o=$m((()=>new Map)),a=$m((()=>new Map)),i=$m((()=>new Set)),s=JM(e),{label:u,children:l,value:c,onValueChange:d,filter:f,shouldFilter:p,loop:m,disablePointerSelection:h=!1,vimBindings:g=!0,...y}=e,b=v.useId(),w=v.useId(),x=v.useId(),_=v.useRef(null),E=lB();Hf((()=>{if(void 0!==c){let e=c.trim();n.current.value=e,S.emit()}}),[c]),Hf((()=>{E(6,R)}),[]);let S=v.useMemo((()=>({subscribe:e=>(i.current.add(e),()=>i.current.delete(e)),snapshot:()=>n.current,setState:(e,t,r)=>{var o,a,i;if(!Object.is(n.current[e],t)){if(n.current[e]=t,"search"===e)T(),k(),E(1,C);else if("value"===e&&(r||E(5,R),void 0!==(null==(o=s.current)?void 0:o.value))){let e=t??"";return void(null==(i=(a=s.current).onValueChange)||i.call(a,e))}S.emit()}},emit:()=>{i.current.forEach((e=>e()))}})),[]),I=v.useMemo((()=>({value:(e,t,r)=>{var o;t!==(null==(o=a.current.get(e))?void 0:o.value)&&(a.current.set(e,{value:t,keywords:r}),n.current.filtered.items.set(e,A(t,r)),E(2,(()=>{k(),S.emit()})))},item:(e,t)=>(r.current.add(e),t&&(o.current.has(t)?o.current.get(t).add(e):o.current.set(t,new Set([e]))),E(3,(()=>{T(),k(),n.current.value||C(),S.emit()})),()=>{a.current.delete(e),r.current.delete(e),n.current.filtered.items.delete(e);let t=P();E(4,(()=>{T(),(null==t?void 0:t.getAttribute("id"))===e&&C(),S.emit()}))}),group:e=>(o.current.has(e)||o.current.set(e,new Set),()=>{a.current.delete(e),o.current.delete(e)}),filter:()=>s.current.shouldFilter,label:u||e["aria-label"],disablePointerSelection:h,listId:b,inputId:x,labelId:w,listInnerRef:_})),[]);function A(e,t){var r,o;let a=null!=(o=null==(r=s.current)?void 0:r.filter)?o:JF;return e?a(e,n.current.search,t):0}function k(){if(!n.current.search||!1===s.current.shouldFilter)return;let e=n.current.filtered.items,t=[];n.current.filtered.groups.forEach((n=>{let r=o.current.get(n),a=0;r.forEach((t=>{let n=e.get(t);a=Math.max(n,a)})),t.push([n,a])}));let r=_.current;O().sort(((t,n)=>{var r,o;let a=t.getAttribute("id"),i=n.getAttribute("id");return(null!=(r=e.get(i))?r:0)-(null!=(o=e.get(a))?o:0)})).forEach((e=>{let t=e.closest(cx);t?t.appendChild(e.parentElement===t?e:e.closest(`${cx} > *`)):r.appendChild(e.parentElement===r?e:e.closest(`${cx} > *`))})),t.sort(((e,t)=>t[1]-e[1])).forEach((e=>{let t=_.current.querySelector(`${Wh}[${Nf}="${encodeURIComponent(e[0])}"]`);null==t||t.parentElement.appendChild(t)}))}function C(){let e=O().find((e=>"true"!==e.getAttribute("aria-disabled"))),t=null==e?void 0:e.getAttribute(Nf);S.setState("value",t||void 0)}function T(){var e,t,i,u;if(!n.current.search||!1===s.current.shouldFilter)return void(n.current.filtered.count=r.current.size);n.current.filtered.groups=new Set;let l=0;for(let o of r.current){let r=A(null!=(t=null==(e=a.current.get(o))?void 0:e.value)?t:"",null!=(u=null==(i=a.current.get(o))?void 0:i.keywords)?u:[]);n.current.filtered.items.set(o,r),r>0&&l++}for(let[e,t]of o.current)for(let r of t)if(n.current.filtered.items.get(r)>0){n.current.filtered.groups.add(e);break}n.current.filtered.count=l}function R(){var e,t,n;let r=P();r&&((null==(e=r.parentElement)?void 0:e.firstChild)===r&&(null==(n=null==(t=r.closest(Wh))?void 0:t.querySelector(XF))||n.scrollIntoView({block:"nearest"})),r.scrollIntoView({block:"nearest"}))}function P(){var e;return null==(e=_.current)?void 0:e.querySelector(`${ZE}[aria-selected="true"]`)}function O(){var e;return Array.from(null==(e=_.current)?void 0:e.querySelectorAll(yT))}function N(e){let t=O()[e];t&&S.setState("value",t.getAttribute(Nf))}function M(e){var t;let n=P(),r=O(),o=r.findIndex((e=>e===n)),a=r[o+e];null!=(t=s.current)&&t.loop&&(a=o+e<0?r[r.length-1]:o+e===r.length?r[0]:r[o+e]),a&&S.setState("value",a.getAttribute(Nf))}function j(e){let t,n=P(),r=null==n?void 0:n.closest(Wh);for(;r&&!t;)r=e>0?sB(r,Wh):uB(r,Wh),t=null==r?void 0:r.querySelector(yT);t?S.setState("value",t.getAttribute(Nf)):M(e)}let D=()=>N(O().length-1),q=e=>{e.preventDefault(),e.metaKey?D():e.altKey?j(1):M(1)},z=e=>{e.preventDefault(),e.metaKey?N(0):e.altKey?j(-1):M(-1)};return v.createElement(ft.div,{ref:t,tabIndex:-1,...y,"cmdk-root":"",onKeyDown:e=>{var t;if(null==(t=y.onKeyDown)||t.call(y,e),!e.defaultPrevented)switch(e.key){case"n":case"j":g&&e.ctrlKey&&q(e);break;case"ArrowDown":q(e);break;case"p":case"k":g&&e.ctrlKey&&z(e);break;case"ArrowUp":z(e);break;case"Home":e.preventDefault(),N(0);break;case"End":e.preventDefault(),D();break;case"Enter":if(!e.nativeEvent.isComposing&&229!==e.keyCode){e.preventDefault();let t=P();if(t){let e=new Event(LS);t.dispatchEvent(e)}}}}},v.createElement("label",{"cmdk-label":"",htmlFor:I.inputId,id:I.labelId,style:dB},u),Fy(e,(e=>v.createElement(YM.Provider,{value:S},v.createElement(KM.Provider,{value:I},e)))))})),ZF=v.forwardRef(((e,t)=>{var n,r;let o=v.useId(),a=v.useRef(null),i=v.useContext(QM),s=Lv(),u=JM(e),l=null!=(r=null==(n=u.current)?void 0:n.forceMount)?r:null==i?void 0:i.forceMount;Hf((()=>{if(!l)return s.item(o,null==i?void 0:i.id)}),[l]);let c=ZM(o,a,[e.value,e.children,a],e.keywords),d=e$(),f=Kf((e=>e.value&&e.value===c.current)),p=Kf((e=>!(!l&&!1!==s.filter())||(!e.search||e.filtered.items.get(o)>0)));function m(){var e,t;h(),null==(t=(e=u.current).onSelect)||t.call(e,c.current)}function h(){d.setState("value",c.current,!0)}if(v.useEffect((()=>{let t=a.current;if(t&&!e.disabled)return t.addEventListener(LS,m),()=>t.removeEventListener(LS,m)}),[p,e.onSelect,e.disabled]),!p)return null;let{disabled:g,value:y,onSelect:b,forceMount:w,keywords:x,..._}=e;return v.createElement(ft.div,{ref:gv([a,t]),..._,id:o,"cmdk-item":"",role:"option","aria-disabled":!!g,"aria-selected":!!f,"data-disabled":!!g,"data-selected":!!f,onPointerMove:g||s.disablePointerSelection?void 0:h,onClick:g?void 0:m},e.children)})),eB=v.forwardRef(((e,t)=>{let{heading:n,children:r,forceMount:o,...a}=e,i=v.useId(),s=v.useRef(null),u=v.useRef(null),l=v.useId(),c=Lv(),d=Kf((e=>!(!o&&!1!==c.filter())||(!e.search||e.filtered.groups.has(i))));Hf((()=>c.group(i)),[]),ZM(i,s,[e.value,e.heading,u]);let f=v.useMemo((()=>({id:i,forceMount:o})),[o]);return v.createElement(ft.div,{ref:gv([s,t]),...a,"cmdk-group":"",role:"presentation",hidden:!d||void 0},n&&v.createElement("div",{ref:u,"cmdk-group-heading":"","aria-hidden":!0,id:l},n),Fy(e,(e=>v.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":n?l:void 0},v.createElement(QM.Provider,{value:f},e)))))})),tB=v.forwardRef(((e,t)=>{let{alwaysRender:n,...r}=e,o=v.useRef(null),a=Kf((e=>!e.search));return n||a?v.createElement(ft.div,{ref:gv([o,t]),...r,"cmdk-separator":"",role:"separator"}):null})),nB=v.forwardRef(((e,t)=>{let{onValueChange:n,...r}=e,o=null!=e.value,a=e$(),i=Kf((e=>e.search)),s=Kf((e=>e.value)),u=Lv(),l=v.useMemo((()=>{var e;let t=null==(e=u.listInnerRef.current)?void 0:e.querySelector(`${ZE}[${Nf}="${encodeURIComponent(s)}"]`);return null==t?void 0:t.getAttribute("id")}),[]);return v.useEffect((()=>{null!=e.value&&a.setState("search",e.value)}),[e.value]),v.createElement(ft.input,{ref:t,...r,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":u.listId,"aria-labelledby":u.labelId,"aria-activedescendant":l,id:u.inputId,type:"text",value:o?e.value:i,onChange:e=>{o||a.setState("search",e.target.value),null==n||n(e.target.value)}})})),rB=v.forwardRef(((e,t)=>{let{children:n,label:r="Suggestions",...o}=e,a=v.useRef(null),i=v.useRef(null),s=Lv();return v.useEffect((()=>{if(i.current&&a.current){let e,t=i.current,n=a.current,r=new ResizeObserver((()=>{e=requestAnimationFrame((()=>{let e=t.offsetHeight;n.style.setProperty("--cmdk-list-height",e.toFixed(1)+"px")}))}));return r.observe(t),()=>{cancelAnimationFrame(e),r.unobserve(t)}}}),[]),v.createElement(ft.div,{ref:gv([a,t]),...o,"cmdk-list":"",role:"listbox","aria-label":r,id:s.listId},Fy(e,(e=>v.createElement("div",{ref:gv([i,s.listInnerRef]),"cmdk-list-sizer":""},e))))})),oB=v.forwardRef(((e,t)=>{let{open:n,onOpenChange:r,overlayClassName:o,contentClassName:a,container:i,...s}=e;return v.createElement(FA,{open:n,onOpenChange:r},v.createElement(Ey,{container:i},v.createElement(Bm,{"cmdk-overlay":"",className:o}),v.createElement(jm,{"aria-label":e.label,"cmdk-dialog":"",className:a},v.createElement(XM,{ref:t,...s}))))})),iB=v.forwardRef(((e,t)=>Kf((e=>0===e.filtered.count))?v.createElement(ft.div,{ref:t,...e,"cmdk-empty":"",role:"presentation"}):null)),aB=v.forwardRef(((e,t)=>{let{progress:n,children:r,label:o="Loading...",...a}=e;return v.createElement(ft.div,{ref:t,...a,"cmdk-loading":"",role:"progressbar","aria-valuenow":n,"aria-valuemin":0,"aria-valuemax":100,"aria-label":o},Fy(e,(e=>v.createElement("div",{"aria-hidden":!0},e))))})),$i=Object.assign(XM,{List:rB,Item:ZF,Input:nB,Group:eB,Separator:tB,Dialog:oB,Empty:iB,Loading:aB});function sB(e,t){let n=e.nextElementSibling;for(;n;){if(n.matches(t))return n;n=n.nextElementSibling}}function uB(e,t){let n=e.previousElementSibling;for(;n;){if(n.matches(t))return n;n=n.previousElementSibling}}function JM(e){let t=v.useRef(e);return Hf((()=>{t.current=e})),t}var Hf=typeof window>"u"?v.useEffect:v.useLayoutEffect;function $m(e){let t=v.useRef();return void 0===t.current&&(t.current=e()),t}function gv(e){return t=>{e.forEach((e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)}))}}function Kf(e){let t=e$(),n=()=>e(t.snapshot());return v.useSyncExternalStore(t.subscribe,n,n)}function ZM(e,t,n,r=[]){let o=v.useRef(),a=Lv();return Hf((()=>{var i;let s=(()=>{var e;for(let t of n){if("string"==typeof t)return t.trim();if("object"==typeof t&&"current"in t)return t.current?null==(e=t.current.textContent)?void 0:e.trim():o.current}})(),u=r.map((e=>e.trim()));a.value(e,s,u),null==(i=t.current)||i.setAttribute(Nf,s),o.current=s})),o}var lB=()=>{let[e,t]=v.useState(),n=$m((()=>new Map));return Hf((()=>{n.current.forEach((e=>e())),n.current=new Map}),[e]),(e,r)=>{n.current.set(e,r),t({})}};function cB(e){let t=e.type;return"function"==typeof t?t(e.props):"render"in t?t.render(e.props):e}function Fy({asChild:e,children:t},n){return e&&v.isValidElement(t)?v.cloneElement(cB(t),{ref:t.ref},n(t.props.children)):n(t)}var dB={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};const fB=Ey,eD=v.forwardRef((({className:e,...t},n)=>(v.useEffect((()=>{const e=document.querySelectorAll(".blured-modal-overlay");return e.forEach((e=>e&&(e.style.filter="blur(5px)"))),()=>{0===Array.from(document.querySelectorAll('[role="dialog"]')).length&&e.forEach((e=>e&&(e.style.filter="none")))}}),[]),G.jsx(Bm,{ref:n,"data-testid":"dialog_overlay",className:we("fixed inset-0 z-dialog bg-black opacity-[0.8] data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}))));eD.displayName=Bm.displayName;const pB=gu("",{variants:{closeVariant:{none:"",insideCard:"absolute right-m top-m rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground text-gray-400",outsideCard:"fixed right-[30px] top-[30px] z-100 text-gray-400",mobileGallery:"fixed right-m top-[62px] text-white z-[110]"}},defaultVariants:{closeVariant:"outsideCard"}}),mB=gu("",{variants:{closeSize:{small:"size-6",big:"size-[42px]","18x18":"size-[18px]"}},defaultVariants:{closeSize:"small"}}),hB=v.forwardRef((({title:e,titleIcon:t,className:n,dialogName:r,showClose:o=!0,closeVariant:a="outsideCard",closeSize:i="big",children:s,titleClassName:u,overlayClassName:l,childrenClassName:c,footerClassName:d,onBack:f,onCloseModal:p,renderFooter:m,onScroll:v,...h},g)=>{const y=G.jsxs($y,{className:we(pB({closeVariant:a})),children:[G.jsx(gy,{onClick:p,fill:"currentColor",className:we(mB({closeSize:i}))}),G.jsx("span",{className:"sr-only",children:"Close"})]});return G.jsxs(fB,{children:[G.jsx(eD,{className:l,onClick:p}),o&&"insideCard"!==a&&y,G.jsxs(jm,{ref:g,className:we("fixed left-[50%] top-[50%] z-[101] grid max-w-[600px] translate-x-[-50%] translate-y-[-50%] !overflow-visible rounded-sm bg-background shadow-lg outline-none duration-200 data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] max-md:w-[calc(100vw-32px)] md:w-full [&>div]:min-w-0",n),...h,children:[e&&G.jsxs("h3",{className:we("flex items-center justify-center gap-xxs border-b border-gray-200 p-m text-center text-lg font-semibold text-gray-700",u),children:[t,e]}),G.jsx("div",{id:r||"dialog-content",className:we("p-m",c),onScroll:v,children:s}),o&&"insideCard"===a&&y,f&&G.jsx("button",{"data-testid":"dialog-back-button","aria-label":"Back",onClick:f,className:"absolute left-m top-m",children:G.jsx(iA,{color:"var(--gray-400)",size:24})}),G.jsx(tD,{className:we("empty:hidden",d),children:null==m?void 0:m()})]})]})}));hB.displayName=jm.displayName;const tD=({className:e,...t})=>G.jsx("div",{className:we("flex border-t border-gray-200 p-m",e),...t});tD.displayName="DialogFooter";const vB=v.forwardRef((({className:e,...t},n)=>G.jsx(Ov,{ref:n,className:we("text-lg font-semibold leading-none tracking-tight",e),...t})));vB.displayName=Ov.displayName;const gB=v.forwardRef((({className:e,...t},n)=>G.jsx(Av,{ref:n,className:we("text-sm text-muted-foreground",e),...t})));gB.displayName=Av.displayName;const yB=v.forwardRef((({className:e,...t},n)=>G.jsx($i,{ref:n,className:we("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",e),...t})));yB.displayName=$i.displayName;const wB=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{className:"flex items-center border-b px-3","cmdk-input-wrapper":"",children:G.jsx($i.Input,{ref:n,className:we("flex h-11 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",e),...t})})));wB.displayName=$i.Input.displayName;const bB=v.forwardRef((({className:e,...t},n)=>G.jsx($i.List,{ref:n,className:we("mt-2 max-h-[300px] overflow-y-auto overflow-x-hidden",e),...t})));bB.displayName=$i.List.displayName;const _B=v.forwardRef(((e,t)=>G.jsx($i.Empty,{ref:t,className:"py-6 text-center text-sm",...e})));_B.displayName=$i.Empty.displayName;const xB=v.forwardRef((({className:e,...t},n)=>G.jsx($i.Group,{ref:n,className:we("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t})));xB.displayName=$i.Group.displayName;const SB=v.forwardRef((({className:e,...t},n)=>G.jsx($i.Separator,{ref:n,className:we("-mx-1 h-px bg-border",e),...t})));SB.displayName=$i.Separator.displayName;const EB=v.forwardRef((({className:e,...t},n)=>G.jsx($i.Item,{ref:n,className:we("relative flex max-w-[215px] cursor-default select-none items-center rounded-xs px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50",e),...t})));function sd(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function wT(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function nD(...e){return t=>{let n=!1;const r=e.map((e=>{const r=wT(e,t);return!n&&"function"==typeof r&&(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():wT(e[t],null)}}}}function ep(...e){return v.useCallback(nD(...e),e)}function $B(e,t){const n=v.createContext(t),r=e=>{const{children:t,...r}=e,o=v.useMemo((()=>r),Object.values(r));return G.jsx(n.Provider,{value:o,children:t})};return r.displayName=e+"Provider",[r,function(r){const o=v.useContext(n);if(o)return o;if(void 0!==t)return t;throw new Error(`\`${r}\` must be used within \`${e}\``)}]}function CB(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>v.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return v.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const o=v.createContext(r),a=n.length;n=[...n,r];const i=t=>{var n;const{scope:r,children:i,...s}=t,u=(null==(n=null==r?void 0:r[e])?void 0:n[a])||o,l=v.useMemo((()=>s),Object.values(s));return G.jsx(u.Provider,{value:l,children:i})};return i.displayName=t+"Provider",[i,function(n,i){var s;const u=(null==(s=null==i?void 0:i[e])?void 0:s[a])||o,l=v.useContext(u);if(l)return l;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},IB(r,...t)]}function IB(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return v.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}EB.displayName=$i.Item.displayName;var Xg=null!=globalThis&&globalThis.document?v.useLayoutEffect:()=>{},RB=Yg[" useId ".trim().toString()]||(()=>{}),PB=0;function dx(e){const[t,n]=v.useState(RB());return Xg((()=>{e||n((e=>e??String(PB++)))}),[e]),e||(t?`radix-${t}`:"")}function Yf(e){const t=v.useRef(e);return v.useEffect((()=>{t.current=e})),v.useMemo((()=>(...e)=>{var n;return null==(n=t.current)?void 0:n.call(t,...e)}),[])}function TB({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=OB({defaultProp:t,onChange:n}),a=void 0!==e,i=a?e:r,s=Yf(n);return[i,v.useCallback((t=>{if(a){const n="function"==typeof t?t(e):t;n!==e&&s(n)}else o(t)}),[a,e,o,s])]}function OB({defaultProp:e,onChange:t}){const n=v.useState(e),[r]=n,o=v.useRef(r),a=Yf(t);return v.useEffect((()=>{o.current!==r&&(a(r),o.current=r)}),[r,o,a]),n}function rD(e){const t=AB(e),n=v.forwardRef(((e,n)=>{const{children:r,...o}=e,a=v.Children.toArray(r),i=a.find(DB);if(i){const e=i.props.children,r=a.map((t=>t===i?v.Children.count(e)>1?v.Children.only(null):v.isValidElement(e)?e.props.children:null:t));return G.jsx(t,{...o,ref:n,children:v.isValidElement(e)?v.cloneElement(e,void 0,r):null})}return G.jsx(t,{...o,ref:n,children:r})}));return n.displayName=`${e}.Slot`,n}function AB(e){const t=v.forwardRef(((e,t)=>{const{children:n,...r}=e;if(v.isValidElement(n)){const e=kB(n),o=NB(r,n.props);return n.type!==v.Fragment&&(o.ref=t?nD(t,e):e),v.cloneElement(n,o)}return v.Children.count(n)>1?v.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}var MB=Symbol("radix.slottable");function DB(e){return v.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===MB}function NB(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...e)=>{a(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...a}:"className"===r&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}function kB(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?e.ref:(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o?e.props.ref:e.props.ref||e.ref)}var LB=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],Il=LB.reduce(((e,t)=>{const n=rD(`Primitive.${t}`),r=v.forwardRef(((e,r)=>{const{asChild:o,...a}=e,i=o?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),G.jsx(i,{...a,ref:r})}));return r.displayName=`Primitive.${t}`,{...e,[t]:r}}),{});function FB(e,t){e&&vu.flushSync((()=>e.dispatchEvent(t)))}function BB(e,t=(null==globalThis?void 0:globalThis.document)){const n=Yf(e);v.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})}),[n,t])}var bT,jB="DismissableLayer",FS="dismissableLayer.update",zB="dismissableLayer.pointerDownOutside",VB="dismissableLayer.focusOutside",oD=v.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),iD=v.forwardRef(((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:i,onDismiss:s,...u}=e,l=v.useContext(oD),[c,d]=v.useState(null),f=(null==c?void 0:c.ownerDocument)??(null==globalThis?void 0:globalThis.document),[,p]=v.useState({}),m=ep(t,(e=>d(e))),h=Array.from(l.layers),[g]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),y=h.indexOf(g),b=c?h.indexOf(c):-1,w=l.layersWithOutsidePointerEventsDisabled.size>0,x=b>=y,_=qB((e=>{const t=e.target,n=[...l.branches].some((e=>e.contains(t)));!x||n||(null==o||o(e),null==i||i(e),e.defaultPrevented||null==s||s())}),f),E=GB((e=>{const t=e.target;[...l.branches].some((e=>e.contains(t)))||(null==a||a(e),null==i||i(e),e.defaultPrevented||null==s||s())}),f);return BB((e=>{b===l.layers.size-1&&(null==r||r(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))}),f),v.useEffect((()=>{if(c)return n&&(0===l.layersWithOutsidePointerEventsDisabled.size&&(bT=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(c)),l.layers.add(c),_T(),()=>{n&&1===l.layersWithOutsidePointerEventsDisabled.size&&(f.body.style.pointerEvents=bT)}}),[c,f,n,l]),v.useEffect((()=>()=>{c&&(l.layers.delete(c),l.layersWithOutsidePointerEventsDisabled.delete(c),_T())}),[c,l]),v.useEffect((()=>{const e=()=>p({});return document.addEventListener(FS,e),()=>document.removeEventListener(FS,e)}),[]),G.jsx(Il.div,{...u,ref:m,style:{pointerEvents:w?x?"auto":"none":void 0,...e.style},onFocusCapture:sd(e.onFocusCapture,E.onFocusCapture),onBlurCapture:sd(e.onBlurCapture,E.onBlurCapture),onPointerDownCapture:sd(e.onPointerDownCapture,_.onPointerDownCapture)})}));iD.displayName=jB;var UB="DismissableLayerBranch",WB=v.forwardRef(((e,t)=>{const n=v.useContext(oD),r=v.useRef(null),o=ep(t,r);return v.useEffect((()=>{const e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}}),[n.branches]),G.jsx(Il.div,{...e,ref:o})}));function qB(e,t=(null==globalThis?void 0:globalThis.document)){const n=Yf(e),r=v.useRef(!1),o=v.useRef((()=>{}));return v.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){aD(zB,n,a,{discrete:!0})};const a={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",o.current),o.current=r,t.addEventListener("click",o.current,{once:!0})):r()}else t.removeEventListener("click",o.current);r.current=!1},a=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",e),t.removeEventListener("click",o.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}function GB(e,t=(null==globalThis?void 0:globalThis.document)){const n=Yf(e),r=v.useRef(!1);return v.useEffect((()=>{const e=e=>{e.target&&!r.current&&aD(VB,n,{originalEvent:e},{discrete:!1})};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function _T(){const e=new CustomEvent(FS);document.dispatchEvent(e)}function aD(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?FB(o,a):o.dispatchEvent(a)}WB.displayName=UB;var fx="focusScope.autoFocusOnMount",px="focusScope.autoFocusOnUnmount",xT={bubbles:!1,cancelable:!0},HB="FocusScope",sD=v.forwardRef(((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...i}=e,[s,u]=v.useState(null),l=Yf(o),c=Yf(a),d=v.useRef(null),f=ep(t,(e=>u(e))),p=v.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;v.useEffect((()=>{if(r){let e=function(e){if(p.paused||!s)return;const t=e.target;s.contains(t)?d.current=t:id(d.current,{select:!0})},t=function(e){if(p.paused||!s)return;const t=e.relatedTarget;null!==t&&(s.contains(t)||id(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(const t of e)t.removedNodes.length>0&&id(s)};document.addEventListener("focusin",e),document.addEventListener("focusout",t);const r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),r.disconnect()}}}),[r,s,p.paused]),v.useEffect((()=>{if(s){ET.add(p);const e=document.activeElement;if(!s.contains(e)){const t=new CustomEvent(fx,xT);s.addEventListener(fx,l),s.dispatchEvent(t),t.defaultPrevented||(KB(ZB(uD(s)),{select:!0}),document.activeElement===e&&id(s))}return()=>{s.removeEventListener(fx,l),setTimeout((()=>{const t=new CustomEvent(px,xT);s.addEventListener(px,c),s.dispatchEvent(t),t.defaultPrevented||id(e??document.body,{select:!0}),s.removeEventListener(px,c),ET.remove(p)}),0)}}}),[s,l,c,p]);const m=v.useCallback((e=>{if(!n&&!r||p.paused)return;const t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,o=document.activeElement;if(t&&o){const t=e.currentTarget,[r,a]=YB(t);r&&a?e.shiftKey||o!==a?e.shiftKey&&o===r&&(e.preventDefault(),n&&id(a,{select:!0})):(e.preventDefault(),n&&id(r,{select:!0})):o===t&&e.preventDefault()}}),[n,r,p.paused]);return G.jsx(Il.div,{tabIndex:-1,...i,ref:f,onKeyDown:m})}));function KB(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(id(r,{select:t}),document.activeElement!==n)return}function YB(e){const t=uD(e);return[ST(t,e),ST(t.reverse(),e)]}function uD(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{const t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function ST(e,t){for(const n of e)if(!QB(n,{upTo:t}))return n}function QB(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function XB(e){return e instanceof HTMLInputElement&&"select"in e}function id(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&XB(e)&&t&&e.select()}}sD.displayName=HB;var ET=JB();function JB(){let e=[];return{add(t){const n=e[0];t!==n&&(null==n||n.pause()),e=$T(e,t),e.unshift(t)},remove(t){var n;e=$T(e,t),null==(n=e[0])||n.resume()}}}function $T(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}function ZB(e){return e.filter((e=>"A"!==e.tagName))}var ej="Portal",lD=v.forwardRef(((e,t)=>{var n;const{container:r,...o}=e,[a,i]=v.useState(!1);Xg((()=>i(!0)),[]);const s=r||a&&(null==(n=null==globalThis?void 0:globalThis.document)?void 0:n.body);return s?eA.createPortal(G.jsx(Il.div,{...o,ref:t}),s):null}));function tj(e,t){return v.useReducer(((e,n)=>t[e][n]??e),e)}lD.displayName=ej;var By=e=>{const{present:t,children:n}=e,r=nj(t),o="function"==typeof n?n({present:r.isPresent}):v.Children.only(n),a=ep(r.ref,rj(o));return"function"==typeof n||r.isPresent?v.cloneElement(o,{ref:a}):null};function nj(e){const[t,n]=v.useState(),r=v.useRef({}),o=v.useRef(e),a=v.useRef("none"),i=e?"mounted":"unmounted",[s,u]=tj(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect((()=>{const e=Cg(r.current);a.current="mounted"===s?e:"none"}),[s]),Xg((()=>{const t=r.current,n=o.current;if(n!==e){const r=a.current,i=Cg(t);e?u("MOUNT"):"none"===i||"none"===(null==t?void 0:t.display)?u("UNMOUNT"):u(n&&r!==i?"ANIMATION_OUT":"UNMOUNT"),o.current=e}}),[e,u]),Xg((()=>{if(t){let e;const n=t.ownerDocument.defaultView??window,i=a=>{const i=Cg(r.current).includes(a.animationName);if(a.target===t&&i&&(u("ANIMATION_END"),!o.current)){const r=t.style.animationFillMode;t.style.animationFillMode="forwards",e=n.setTimeout((()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=r)}))}},s=e=>{e.target===t&&(a.current=Cg(r.current))};return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",i),t.addEventListener("animationend",i),()=>{n.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",i),t.removeEventListener("animationend",i)}}u("ANIMATION_END")}),[t,u]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:v.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}function Cg(e){return(null==e?void 0:e.animationName)||"none"}function rj(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?e.ref:(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o?e.props.ref:e.props.ref||e.ref)}By.displayName="Presence";var mx=0;function oj(){v.useEffect((()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??CT()),document.body.insertAdjacentElement("beforeend",e[1]??CT()),mx++,()=>{1===mx&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),mx--}}),[])}function CT(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var cD=_A(),hx=function(){},jy=v.forwardRef((function(e,t){var n=v.useRef(null),r=v.useState({onScrollCapture:hx,onWheelCapture:hx,onTouchMoveCapture:hx}),o=r[0],a=r[1],i=e.forwardProps,s=e.children,u=e.className,l=e.removeScrollBar,c=e.enabled,d=e.shards,f=e.sideCar,p=e.noIsolation,m=e.inert,h=e.allowPinchZoom,g=e.as,y=void 0===g?"div":g,b=e.gapMode,w=EE(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),x=f,_=bA([n,t]),E=zo(zo({},w),o);return v.createElement(v.Fragment,null,c&&v.createElement(x,{sideCar:cD,removeScrollBar:l,shards:d,noIsolation:p,inert:m,setCallbacks:a,allowPinchZoom:!!h,lockRef:n,gapMode:b}),i?v.cloneElement(v.Children.only(s),zo(zo({},E),{ref:_})):v.createElement(y,zo({},E,{className:u,ref:_}),s))}));jy.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},jy.classNames={fullWidth:iv,zeroRight:ov};var BS=!1;if(typeof window<"u")try{var Ig=Object.defineProperty({},"passive",{get:function(){return BS=!0,!0}});window.addEventListener("test",Ig,Ig),window.removeEventListener("test",Ig,Ig)}catch{BS=!1}var _m=!!BS&&{passive:!1},ij=function(e){return"TEXTAREA"===e.tagName},dD=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&!(n.overflowY===n.overflowX&&!ij(e)&&"visible"===n[t])},aj=function(e){return dD(e,"overflowY")},sj=function(e){return dD(e,"overflowX")},IT=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host),fD(e,r)){var o=pD(e,r);if(o[1]>o[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},uj=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},lj=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},fD=function(e,t){return"v"===e?aj(t):sj(t)},pD=function(e,t){return"v"===e?uj(t):lj(t)},cj=function(e,t){return"h"===e&&"rtl"===t?-1:1},dj=function(e,t,n,r,o){var a=cj(e,window.getComputedStyle(t).direction),i=a*r,s=n.target,u=t.contains(s),l=!1,c=i>0,d=0,f=0;do{var p=pD(e,s),m=p[0],v=p[1]-p[2]-a*m;(m||v)&&fD(e,s)&&(d+=v,f+=m),s=s instanceof ShadowRoot?s.host:s.parentNode}while(!u&&s!==document.body||u&&(t.contains(s)||t===s));return(c&&(Math.abs(d)<1||!o)||!c&&(Math.abs(f)<1||!o))&&(l=!0),l},Rg=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},RT=function(e){return[e.deltaX,e.deltaY]},PT=function(e){return e&&"current"in e?e.current:e},fj=function(e,t){return e[0]===t[0]&&e[1]===t[1]},pj=function(e){return"\n .block-interactivity-".concat(e," {pointer-events: none;}\n .allow-interactivity-").concat(e," {pointer-events: all;}\n")},mj=0,xm=[];function hj(e){var t=v.useRef([]),n=v.useRef([0,0]),r=v.useRef(),o=v.useState(mj++)[0],a=v.useState($E)[0],i=v.useRef(e);v.useEffect((function(){i.current=e}),[e]),v.useEffect((function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var t=wA([e.lockRef.current],(e.shards||[]).map(PT),!0).filter(Boolean);return t.forEach((function(e){return e.classList.add("allow-interactivity-".concat(o))})),function(){document.body.classList.remove("block-interactivity-".concat(o)),t.forEach((function(e){return e.classList.remove("allow-interactivity-".concat(o))}))}}}),[e.inert,e.lockRef.current,e.shards]);var s=v.useCallback((function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!i.current.allowPinchZoom;var o,a=Rg(e),s=n.current,u="deltaX"in e?e.deltaX:s[0]-a[0],l="deltaY"in e?e.deltaY:s[1]-a[1],c=e.target,d=Math.abs(u)>Math.abs(l)?"h":"v";if("touches"in e&&"h"===d&&"range"===c.type)return!1;var f=IT(d,c);if(!f)return!0;if(f?o=d:(o="v"===d?"h":"v",f=IT(d,c)),!f)return!1;if(!r.current&&"changedTouches"in e&&(u||l)&&(r.current=o),!o)return!0;var p=r.current||o;return dj(p,t,e,"h"===p?u:l,!0)}),[]),u=v.useCallback((function(e){var n=e;if(xm.length&&xm[xm.length-1]===a){var r="deltaY"in n?RT(n):Rg(n),o=t.current.filter((function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&fj(e.delta,r)}))[0];if(o&&o.should)return void(n.cancelable&&n.preventDefault());if(!o){var u=(i.current.shards||[]).map(PT).filter(Boolean).filter((function(e){return e.contains(n.target)}));(u.length>0?s(n,u[0]):!i.current.noIsolation)&&n.cancelable&&n.preventDefault()}}}),[]),l=v.useCallback((function(e,n,r,o){var a={name:e,delta:n,target:r,should:o,shadowParent:vj(r)};t.current.push(a),setTimeout((function(){t.current=t.current.filter((function(e){return e!==a}))}),1)}),[]),c=v.useCallback((function(e){n.current=Rg(e),r.current=void 0}),[]),d=v.useCallback((function(t){l(t.type,RT(t),t.target,s(t,e.lockRef.current))}),[]),f=v.useCallback((function(t){l(t.type,Rg(t),t.target,s(t,e.lockRef.current))}),[]);v.useEffect((function(){return xm.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener("wheel",u,_m),document.addEventListener("touchmove",u,_m),document.addEventListener("touchstart",c,_m),function(){xm=xm.filter((function(e){return e!==a})),document.removeEventListener("wheel",u,_m),document.removeEventListener("touchmove",u,_m),document.removeEventListener("touchstart",c,_m)}}),[]);var p=e.removeScrollBar,m=e.inert;return v.createElement(v.Fragment,null,m?v.createElement(a,{styles:pj(o)}):null,p?v.createElement($A,{gapMode:e.gapMode}):null)}function vj(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const gj=SA(cD,hj);var mD=v.forwardRef((function(e,t){return v.createElement(jy,zo({},e,{ref:t,sideCar:gj}))}));mD.classNames=jy.classNames;var t$="Dialog",[hD,WJ]=CB(t$),[yj,_s]=hD(t$),vD=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:a,modal:i=!0}=e,s=v.useRef(null),u=v.useRef(null),[l=!1,c]=TB({prop:r,defaultProp:o,onChange:a});return G.jsx(yj,{scope:t,triggerRef:s,contentRef:u,contentId:dx(),titleId:dx(),descriptionId:dx(),open:l,onOpenChange:c,onOpenToggle:v.useCallback((()=>c((e=>!e))),[c]),modal:i,children:n})};vD.displayName=t$;var gD="DialogTrigger",yD=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s(gD,n),a=ep(t,o.triggerRef);return G.jsx(Il.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":o$(o.open),...r,ref:a,onClick:sd(e.onClick,o.onOpenToggle)})}));yD.displayName=gD;var n$="DialogPortal",[wj,wD]=hD(n$,{forceMount:void 0}),bD=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,a=_s(n$,t);return G.jsx(wj,{scope:t,forceMount:n,children:v.Children.map(r,(e=>G.jsx(By,{present:n||a.open,children:G.jsx(lD,{asChild:!0,container:o,children:e})})))})};bD.displayName=n$;var Jg="DialogOverlay",_D=v.forwardRef(((e,t)=>{const n=wD(Jg,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=_s(Jg,e.__scopeDialog);return a.modal?G.jsx(By,{present:r||a.open,children:G.jsx(_j,{...o,ref:t})}):null}));_D.displayName=Jg;var bj=rD("DialogOverlay.RemoveScroll"),_j=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s(Jg,n);return G.jsx(mD,{as:bj,allowPinchZoom:!0,shards:[o.contentRef],children:G.jsx(Il.div,{"data-state":o$(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})})),Qf="DialogContent",xD=v.forwardRef(((e,t)=>{const n=wD(Qf,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=_s(Qf,e.__scopeDialog);return G.jsx(By,{present:r||a.open,children:a.modal?G.jsx(xj,{...o,ref:t}):G.jsx(Sj,{...o,ref:t})})}));xD.displayName=Qf;var xj=v.forwardRef(((e,t)=>{const n=_s(Qf,e.__scopeDialog),r=v.useRef(null),o=ep(t,n.contentRef,r);return v.useEffect((()=>{const e=r.current;if(e)return Sy(e)}),[]),G.jsx(SD,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:sd(e.onCloseAutoFocus,(e=>{var t;e.preventDefault(),null==(t=n.triggerRef.current)||t.focus()})),onPointerDownOutside:sd(e.onPointerDownOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey;(2===t.button||n)&&e.preventDefault()})),onFocusOutside:sd(e.onFocusOutside,(e=>e.preventDefault()))})})),Sj=v.forwardRef(((e,t)=>{const n=_s(Qf,e.__scopeDialog),r=v.useRef(!1),o=v.useRef(!1);return G.jsx(SD,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var a,i;null==(a=e.onCloseAutoFocus)||a.call(e,t),t.defaultPrevented||(r.current||null==(i=n.triggerRef.current)||i.focus(),t.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:t=>{var a,i;null==(a=e.onInteractOutside)||a.call(e,t),t.defaultPrevented||(r.current=!0,"pointerdown"===t.detail.originalEvent.type&&(o.current=!0));const s=t.target;(null==(i=n.triggerRef.current)?void 0:i.contains(s))&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&o.current&&t.preventDefault()}})})),SD=v.forwardRef(((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,...i}=e,s=_s(Qf,n),u=v.useRef(null),l=ep(t,u);return oj(),G.jsxs(G.Fragment,{children:[G.jsx(sD,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:a,children:G.jsx(iD,{role:"dialog",id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":o$(s.open),...i,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),G.jsxs(G.Fragment,{children:[G.jsx(Ej,{titleId:s.titleId}),G.jsx(Cj,{contentRef:u,descriptionId:s.descriptionId})]})]})})),r$="DialogTitle",ED=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s(r$,n);return G.jsx(Il.h2,{id:o.titleId,...r,ref:t})}));ED.displayName=r$;var $D="DialogDescription",CD=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s($D,n);return G.jsx(Il.p,{id:o.descriptionId,...r,ref:t})}));CD.displayName=$D;var ID="DialogClose",RD=v.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,o=_s(ID,n);return G.jsx(Il.button,{type:"button",...r,ref:t,onClick:sd(e.onClick,(()=>o.onOpenChange(!1)))})}));function o$(e){return e?"open":"closed"}RD.displayName=ID;var PD="DialogTitleWarning",[qJ,TD]=$B(PD,{contentName:Qf,titleName:r$,docsSlug:"dialog"}),Ej=({titleId:e})=>{const t=TD(PD),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.\n\nIf you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.\n\nFor more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return v.useEffect((()=>{e&&(document.getElementById(e)||console.error(n))}),[n,e]),null},$j="DialogDescriptionWarning",Cj=({contentRef:e,descriptionId:t})=>{const n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${TD($j).contentName}}.`;return v.useEffect((()=>{var r;const o=null==(r=e.current)?void 0:r.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(n))}),[n,e,t]),null},Ij=vD,Rj=yD,Pj=bD,Tj=_D,Oj=xD,Aj=ED,Mj=CD,Dj=RD;function Nj(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const OD=Ue.createContext({drawerRef:{current:null},overlayRef:{current:null},onPress:()=>{},onRelease:()=>{},onDrag:()=>{},onNestedDrag:()=>{},onNestedOpenChange:()=>{},onNestedRelease:()=>{},openProp:void 0,dismissible:!1,isOpen:!1,isDragging:!1,keyboardIsOpen:{current:!1},snapPointsOffset:null,snapPoints:null,handleOnly:!1,modal:!1,shouldFade:!1,activeSnapPoint:null,onOpenChange:()=>{},setActiveSnapPoint:()=>{},closeDrawer:()=>{},direction:"bottom",shouldScaleBackground:!1,setBackgroundColorOnScale:!0,noBodyStyles:!1,container:null,autoFocus:!1}),Vm=()=>{const e=Ue.useContext(OD);if(!e)throw new Error("useDrawerContext must be used within a Drawer.Root");return e};Nj("[data-vaul-drawer]{touch-action:none;will-change:transform;transition:transform .5s cubic-bezier(.32, .72, 0, 1);animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=open]{animation-name:slideFromBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=closed]{animation-name:slideToBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=open]{animation-name:slideFromTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=closed]{animation-name:slideToTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=open]{animation-name:slideFromLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=closed]{animation-name:slideToLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=open]{animation-name:slideFromRight}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=closed]{animation-name:slideToRight}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,100%,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,-100%,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(-100%,0,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(100%,0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-overlay][data-vaul-snap-points=false]{animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-overlay][data-vaul-snap-points=false][data-state=open]{animation-name:fadeIn}[data-vaul-overlay][data-state=closed]{animation-name:fadeOut}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:0;transition:opacity .5s cubic-bezier(.32, .72, 0, 1)}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:1}[data-vaul-drawer]:not([data-vaul-custom-container=true])::after{content:'';position:absolute;background:inherit;background-color:inherit}[data-vaul-drawer][data-vaul-drawer-direction=top]::after{top:initial;bottom:100%;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=bottom]::after{top:100%;bottom:initial;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=left]::after{left:initial;right:100%;top:0;bottom:0;width:200%}[data-vaul-drawer][data-vaul-drawer-direction=right]::after{left:100%;right:initial;top:0;bottom:0;width:200%}[data-vaul-overlay][data-vaul-snap-points=true]:not([data-vaul-snap-points-overlay=true]):not(\n[data-state=closed]\n){opacity:0}[data-vaul-overlay][data-vaul-snap-points-overlay=true]{opacity:1}[data-vaul-handle]{display:block;position:relative;opacity:.7;background:#e2e2e4;margin-left:auto;margin-right:auto;height:5px;width:32px;border-radius:1rem;touch-action:pan-y}[data-vaul-handle]:active,[data-vaul-handle]:hover{opacity:1}[data-vaul-handle-hitarea]{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:max(100%,2.75rem);height:max(100%,2.75rem);touch-action:inherit}@media (hover:hover) and (pointer:fine){[data-vaul-drawer]{user-select:none}}@media (pointer:fine){[data-vaul-handle-hitarea]:{width:100%;height:100%}}@keyframes fadeIn{from{opacity:0}to{opacity:1}}@keyframes fadeOut{to{opacity:0}}@keyframes slideFromBottom{from{transform:translate3d(0,100%,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToBottom{to{transform:translate3d(0,100%,0)}}@keyframes slideFromTop{from{transform:translate3d(0,-100%,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToTop{to{transform:translate3d(0,-100%,0)}}@keyframes slideFromLeft{from{transform:translate3d(-100%,0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToLeft{to{transform:translate3d(-100%,0,0)}}@keyframes slideFromRight{from{transform:translate3d(100%,0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToRight{to{transform:translate3d(100%,0,0)}}");const kj=24,Lj=typeof window<"u"?v.useLayoutEffect:v.useEffect;function TT(...e){return(...t)=>{for(let n of e)"function"==typeof n&&n(...t)}}function Fj(){return i$(/^Mac/)}function Bj(){return i$(/^iPhone/)}function OT(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}function jj(){return i$(/^iPad/)||Fj()&&navigator.maxTouchPoints>1}function AD(){return Bj()||jj()}function i$(e){return typeof window<"u"&&null!=window.navigator?e.test(window.navigator.platform):void 0}const vx=typeof document<"u"&&window.visualViewport;function AT(e){let t=window.getComputedStyle(e);return/(auto|scroll)/.test(t.overflow+t.overflowX+t.overflowY)}function MD(e){for(AT(e)&&(e=e.parentElement);e&&!AT(e);)e=e.parentElement;return e||document.scrollingElement||document.documentElement}const zj=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);let gx,Pg=0;function Vj(e={}){let{isDisabled:t}=e;Lj((()=>{if(!t)return Pg++,1===Pg&&AD()&&(gx=Uj()),()=>{Pg--,0===Pg&&(null==gx||gx())}}),[t])}function Uj(){let e,t=0,n=window.pageXOffset,r=window.pageYOffset,o=TT(Wj(document.documentElement,"paddingRight",window.innerWidth-document.documentElement.clientWidth+"px"));window.scrollTo(0,0);let a=TT(qh(document,"touchstart",(n=>{e=MD(n.target),(e!==document.documentElement||e!==document.body)&&(t=n.changedTouches[0].pageY)}),{passive:!1,capture:!0}),qh(document,"touchmove",(n=>{if(!e||e===document.documentElement||e===document.body)return void n.preventDefault();let r=n.changedTouches[0].pageY,o=e.scrollTop,a=e.scrollHeight-e.clientHeight;0!==a&&((o<=0&&r>t||o>=a&&r<t)&&n.preventDefault(),t=r)}),{passive:!1,capture:!0}),qh(document,"touchend",(e=>{let t=e.target;jS(t)&&t!==document.activeElement&&(e.preventDefault(),t.style.transform="translateY(-2000px)",t.focus(),requestAnimationFrame((()=>{t.style.transform=""})))}),{passive:!1,capture:!0}),qh(document,"focus",(e=>{let t=e.target;jS(t)&&(t.style.transform="translateY(-2000px)",requestAnimationFrame((()=>{t.style.transform="",vx&&(vx.height<window.innerHeight?requestAnimationFrame((()=>{MT(t)})):vx.addEventListener("resize",(()=>MT(t)),{once:!0}))})))}),!0),qh(window,"scroll",(()=>{window.scrollTo(0,0)})));return()=>{o(),a(),window.scrollTo(n,r)}}function Wj(e,t,n){let r=e.style[t];return e.style[t]=n,()=>{e.style[t]=r}}function qh(e,t,n,r){return e.addEventListener(t,n,r),()=>{e.removeEventListener(t,n,r)}}function MT(e){let t=document.scrollingElement||document.documentElement;for(;e&&e!==t;){let t=MD(e);if(t!==document.documentElement&&t!==document.body&&t!==e){let n=t.getBoundingClientRect().top,r=e.getBoundingClientRect().top;e.getBoundingClientRect().bottom>t.getBoundingClientRect().bottom+24&&(t.scrollTop+=r-n)}e=t.parentElement}}function jS(e){return e instanceof HTMLInputElement&&!zj.has(e.type)||e instanceof HTMLTextAreaElement||e instanceof HTMLElement&&e.isContentEditable}function qj(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Gj(...e){return t=>e.forEach((e=>qj(e,t)))}function DD(...e){return v.useCallback(Gj(...e),e)}const ND=new WeakMap;function Ur(e,t,n=!1){if(!(e&&e instanceof HTMLElement))return;let r={};Object.entries(t).forEach((([t,n])=>{t.startsWith("--")?e.style.setProperty(t,n):(r[t]=e.style[t],e.style[t]=n)})),!n&&ND.set(e,r)}function Hj(e,t){if(!(e&&e instanceof HTMLElement))return;let n=ND.get(e);n&&(e.style[t]=n[t])}const Wr=e=>{switch(e){case"top":case"bottom":return!0;case"left":case"right":return!1;default:return e}};function Tg(e,t){if(!e)return null;const n=window.getComputedStyle(e),r=n.transform||n.webkitTransform||n.mozTransform;let o=r.match(/^matrix3d\((.+)\)$/);return o?parseFloat(o[1].split(", ")[Wr(t)?13:12]):(o=r.match(/^matrix\((.+)\)$/),o?parseFloat(o[1].split(", ")[Wr(t)?5:4]):null)}function Kj(e){return 8*(Math.log(e+1)-2)}function yx(e,t){if(!e)return()=>{};const n=e.style.cssText;return Object.assign(e.style,t),()=>{e.style.cssText=n}}function Yj(...e){return(...t)=>{for(const n of e)"function"==typeof n&&n(...t)}}const zn={DURATION:.5,EASE:[.32,.72,0,1]},kD=.4,Qj=.25,Xj=100,LD=8,Af=16,zS=26,wx="vaul-dragging";function FD(e){const t=Ue.useRef(e);return Ue.useEffect((()=>{t.current=e})),Ue.useMemo((()=>(...e)=>null==t.current?void 0:t.current.call(t,...e)),[])}function Jj({defaultProp:e,onChange:t}){const n=Ue.useState(e),[r]=n,o=Ue.useRef(r),a=FD(t);return Ue.useEffect((()=>{o.current!==r&&(a(r),o.current=r)}),[r,o,a]),n}function BD({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=Jj({defaultProp:t,onChange:n}),a=void 0!==e,i=a?e:r,s=FD(n);return[i,Ue.useCallback((t=>{if(a){const n="function"==typeof t?t(e):t;n!==e&&s(n)}else o(t)}),[a,e,o,s])]}function Zj({activeSnapPointProp:e,setActiveSnapPointProp:t,snapPoints:n,drawerRef:r,overlayRef:o,fadeFromIndex:a,onSnapPointChange:i,direction:s="bottom",container:u,snapToSequentialPoint:l}){const[c,d]=BD({prop:e,defaultProp:null==n?void 0:n[0],onChange:t}),[f,p]=Ue.useState(typeof window<"u"?{innerWidth:window.innerWidth,innerHeight:window.innerHeight}:void 0);Ue.useEffect((()=>{function e(){p({innerWidth:window.innerWidth,innerHeight:window.innerHeight})}return window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)}),[]);const m=Ue.useMemo((()=>c===(null==n?void 0:n[n.length-1])||null),[n,c]),v=Ue.useMemo((()=>null==n?void 0:n.findIndex((e=>e===c))),[n,c]),h=n&&n.length>0&&(a||0===a)&&!Number.isNaN(a)&&n[a]===c||!n,g=Ue.useMemo((()=>{const e=u?{width:u.getBoundingClientRect().width,height:u.getBoundingClientRect().height}:typeof window<"u"?{width:window.innerWidth,height:window.innerHeight}:{width:0,height:0};var t;return null!=(t=null==n?void 0:n.map((t=>{const n="string"==typeof t;let r=0;if(n&&(r=parseInt(t,10)),Wr(s)){const o=n?r:f?t*e.height:0;return f?"bottom"===s?e.height-o:-e.height+o:o}const o=n?r:f?t*e.width:0;return f?"right"===s?e.width-o:-e.width+o:o})))?t:[]}),[n,f,u]),y=Ue.useMemo((()=>null!==v?null==g?void 0:g[v]:null),[g,v]),b=Ue.useCallback((e=>{var t;const u=null!=(t=null==g?void 0:g.findIndex((t=>t===e)))?t:null;i(u),Ur(r.current,{transition:`transform ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,transform:Wr(s)?`translate3d(0, ${e}px, 0)`:`translate3d(${e}px, 0, 0)`}),g&&u!==g.length-1&&u!==a&&u<a?Ur(o.current,{transition:`opacity ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,opacity:"0"}):Ur(o.current,{transition:`opacity ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,opacity:"1"}),d(null==n?void 0:n[Math.max(u,0)])}),[r.current,n,g,a,o,d]);return Ue.useEffect((()=>{if(c||e){var t;const r=null!=(t=null==n?void 0:n.findIndex((t=>t===e||t===c)))?t:-1;g&&-1!==r&&"number"==typeof g[r]&&b(g[r])}}),[c,e,n,g,b]),{isLastSnapPoint:m,activeSnapPoint:c,shouldFade:h,getPercentageDragged:function(e,t){if(!n||"number"!=typeof v||!g||void 0===a)return null;const r=v===a-1;if(v>=a&&t)return 0;if(r&&!t)return 1;if(!h&&!r)return null;const o=r?v+1:v-1,i=r?g[o]-g[o-1]:g[o+1]-g[o],s=e/Math.abs(i);return r?1-s:s},setActiveSnapPoint:d,activeSnapPointIndex:v,onRelease:function({draggedDistance:e,closeDrawer:t,velocity:r,dismissible:i}){if(void 0===a)return;const u="bottom"===s||"right"===s?(y??0)-e:(y??0)+e,c=0===v,d=e>0;if(v===a-1&&Ur(o.current,{transition:`opacity ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`}),!l&&r>2&&!d)return void(i?t():b(g[0]));if(!l&&r>2&&d&&g&&n)return void b(g[n.length-1]);const f=null==g?void 0:g.reduce(((e,t)=>"number"!=typeof e||"number"!=typeof t?e:Math.abs(t-u)<Math.abs(e-u)?t:e)),p=Wr(s)?window.innerHeight:window.innerWidth;if(r>kD&&Math.abs(e)<.4*p){const e=d?1:-1;if(e>0&&m)return void b(g[n.length-1]);if(c&&e<0&&i&&t(),null===v)return;b(g[v+e])}else b(f)},onDrag:function({draggedDistance:e}){if(null===y)return;const t="bottom"===s||"right"===s?y-e:y+e;("bottom"===s||"right"===s)&&t<g[g.length-1]||("top"===s||"left"===s)&&t>g[g.length-1]||Ur(r.current,{transform:Wr(s)?`translate3d(0, ${t}px, 0)`:`translate3d(${t}px, 0, 0)`})},snapPointsOffset:g}}const ez=()=>()=>{};function tz(){const{direction:e,isOpen:t,shouldScaleBackground:n,setBackgroundColorOnScale:r,noBodyStyles:o}=Vm(),a=Ue.useRef(null),i=v.useMemo((()=>document.body.style.backgroundColor),[]);function s(){return(window.innerWidth-26)/window.innerWidth}Ue.useEffect((()=>{if(t&&n){a.current&&clearTimeout(a.current);const t=document.querySelector("[data-vaul-drawer-wrapper]")||document.querySelector("[vaul-drawer-wrapper]");if(!t)return;Yj(r&&!o?yx(document.body,{background:"black"}):ez,yx(t,{transformOrigin:Wr(e)?"top":"left",transitionProperty:"transform, border-radius",transitionDuration:`${zn.DURATION}s`,transitionTimingFunction:`cubic-bezier(${zn.EASE.join(",")})`}));const n=yx(t,{borderRadius:"8px",overflow:"hidden",...Wr(e)?{transform:`scale(${s()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`}:{transform:`scale(${s()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`}});return()=>{n(),a.current=window.setTimeout((()=>{i?document.body.style.background=i:document.body.style.removeProperty("background")}),1e3*zn.DURATION)}}}),[t,n,i])}let Gh=null;function nz({isOpen:e,modal:t,nested:n,hasBeenOpened:r,preventScrollRestoration:o,noBodyStyles:a}){const[i,s]=Ue.useState((()=>typeof window<"u"?window.location.href:"")),u=Ue.useRef(0),l=Ue.useCallback((()=>{if(OT()&&null===Gh&&e&&!a){Gh={position:document.body.style.position,top:document.body.style.top,left:document.body.style.left,height:document.body.style.height,right:"unset"};const{scrollX:e,innerHeight:t}=window;document.body.style.setProperty("position","fixed","important"),Object.assign(document.body.style,{top:-u.current+"px",left:-e+"px",right:"0px",height:"auto"}),window.setTimeout((()=>window.requestAnimationFrame((()=>{const e=t-window.innerHeight;e&&u.current>=t&&(document.body.style.top=-(u.current+e)+"px")}))),300)}}),[e]),c=Ue.useCallback((()=>{if(OT()&&null!==Gh&&!a){const e=-parseInt(document.body.style.top,10),t=-parseInt(document.body.style.left,10);Object.assign(document.body.style,Gh),window.requestAnimationFrame((()=>{o&&i!==window.location.href?s(window.location.href):window.scrollTo(t,e)})),Gh=null}}),[i]);return Ue.useEffect((()=>{function e(){u.current=window.scrollY}return e(),window.addEventListener("scroll",e),()=>{window.removeEventListener("scroll",e)}}),[]),Ue.useEffect((()=>{n||!r||(e?(!window.matchMedia("(display-mode: standalone)").matches&&l(),t||window.setTimeout((()=>{c()}),500)):c())}),[e,r,i,t,n,l,c]),{restorePositionSetting:c}}function jD({open:e,onOpenChange:t,children:n,onDrag:r,onRelease:o,snapPoints:a,shouldScaleBackground:i=!1,setBackgroundColorOnScale:s=!0,closeThreshold:u=Qj,scrollLockTimeout:l=Xj,dismissible:c=!0,handleOnly:d=!1,fadeFromIndex:f=a&&a.length-1,activeSnapPoint:p,setActiveSnapPoint:m,fixed:v,modal:h=!0,onClose:g,nested:y,noBodyStyles:b,direction:w="bottom",defaultOpen:x=!1,disablePreventScroll:_=!0,snapToSequentialPoint:E=!1,preventScrollRestoration:S=!1,repositionInputs:I=!0,onAnimationEnd:A,container:k,autoFocus:C=!1}){var T,R;const[P=!1,O]=BD({defaultProp:x,prop:e,onChange:e=>{null==t||t(e),!e&&!y&&ue(),setTimeout((()=>{null==A||A(e)}),1e3*zn.DURATION),e&&!h&&typeof window<"u"&&window.requestAnimationFrame((()=>{document.body.style.pointerEvents="auto"})),e||(document.body.style.pointerEvents="auto")}}),[N,M]=Ue.useState(!1),[j,D]=Ue.useState(!1),[q,z]=Ue.useState(!1),L=Ue.useRef(null),$=Ue.useRef(null),V=Ue.useRef(null),B=Ue.useRef(null),F=Ue.useRef(null),U=Ue.useRef(!1),G=Ue.useRef(null),W=Ue.useRef(0),H=Ue.useRef(!1),Q=Ue.useRef(0),K=Ue.useRef(null),Y=Ue.useRef((null==(T=K.current)?void 0:T.getBoundingClientRect().height)||0),J=Ue.useRef((null==(R=K.current)?void 0:R.getBoundingClientRect().width)||0),X=Ue.useRef(0),Z=Ue.useCallback((e=>{a&&e===oe.length-1&&($.current=new Date)}),[]),{activeSnapPoint:ee,activeSnapPointIndex:te,setActiveSnapPoint:ne,onRelease:re,snapPointsOffset:oe,onDrag:ae,shouldFade:ie,getPercentageDragged:se}=Zj({snapPoints:a,activeSnapPointProp:p,setActiveSnapPointProp:m,drawerRef:K,fadeFromIndex:f,overlayRef:L,onSnapPointChange:Z,direction:w,container:k,snapToSequentialPoint:E});Vj({isDisabled:!P||j||!h||q||!N||!I||!_});const{restorePositionSetting:ue}=nz({isOpen:P,modal:h,nested:y,hasBeenOpened:N,preventScrollRestoration:S,noBodyStyles:b});function le(){return(window.innerWidth-26)/window.innerWidth}function ce(e,t){var n,r;let o=e;const a=null==(n=window.getSelection())?void 0:n.toString(),i=K.current?Tg(K.current,w):null,s=new Date;if(o.hasAttribute("data-vaul-no-drag")||o.closest("[data-vaul-no-drag]"))return!1;if("right"===w||"left"===w)return!0;if($.current&&s.getTime()-$.current.getTime()<500)return!1;if(null!==i&&("bottom"===w?i>0:i<0))return!0;if(a&&a.length>0)return!1;if(s.getTime()-(null==(r=F.current)?void 0:r.getTime())<l&&0===i||t)return F.current=s,!1;for(;o;){if(o.scrollHeight>o.clientHeight){if(0!==o.scrollTop)return F.current=new Date,!1;if("dialog"===o.getAttribute("role"))return!0}o=o.parentNode}return!0}function de(e){!j||!K.current||(K.current.classList.remove(wx),U.current=!1,D(!1),B.current=new Date),null==g||g(),e||O(!1),setTimeout((()=>{a&&ne(a[0])}),1e3*zn.DURATION)}function fe(){if(!K.current)return;const e=document.querySelector("[data-vaul-drawer-wrapper]"),t=Tg(K.current,w);Ur(K.current,{transform:"translate3d(0, 0, 0)",transition:`transform ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`}),Ur(L.current,{transition:`opacity ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,opacity:"1"}),i&&t&&t>0&&P&&Ur(e,{borderRadius:"8px",overflow:"hidden",...Wr(w)?{transform:`scale(${le()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`,transformOrigin:"top"}:{transform:`scale(${le()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`,transformOrigin:"left"},transitionProperty:"transform, border-radius",transitionDuration:`${zn.DURATION}s`,transitionTimingFunction:`cubic-bezier(${zn.EASE.join(",")})`},!0)}return Ue.useEffect((()=>{var e;function t(){if(!K.current||!I)return;if(jS(document.activeElement)||H.current){var e;const t=(null==(e=window.visualViewport)?void 0:e.height)||0,n=window.innerHeight;let r=n-t;const o=K.current.getBoundingClientRect().height||0,i=o>.8*n;X.current||(X.current=o);const s=K.current.getBoundingClientRect().top;if(Math.abs(Q.current-r)>60&&(H.current=!H.current),a&&a.length>0&&oe&&te){r+=oe[te]||0}if(Q.current=r,o>t||H.current){const e=K.current.getBoundingClientRect().height;let n=e;e>t&&(n=t-(i?s:26)),K.current.style.height=v?e-Math.max(r,0)+"px":`${Math.max(n,t-s)}px`}else K.current.style.height=`${X.current}px`;a&&a.length>0&&!H.current?K.current.style.bottom="0px":K.current.style.bottom=`${Math.max(r,0)}px`}}return null==(e=window.visualViewport)||e.addEventListener("resize",t),()=>{var e;return null==(e=window.visualViewport)?void 0:e.removeEventListener("resize",t)}}),[te,a,oe]),Ue.useEffect((()=>(P&&(Ur(document.documentElement,{scrollBehavior:"auto"}),$.current=new Date),()=>{Hj(document.documentElement,"scrollBehavior")})),[P]),Ue.createElement(Ij,{defaultOpen:x,onOpenChange:e=>{!c&&!e||(e?M(!0):de(!0),O(e))},open:P},Ue.createElement(OD.Provider,{value:{activeSnapPoint:ee,snapPoints:a,setActiveSnapPoint:ne,drawerRef:K,overlayRef:L,onOpenChange:t,onPress:function(e){var t,n;!c&&!a||K.current&&!K.current.contains(e.target)||(Y.current=(null==(t=K.current)?void 0:t.getBoundingClientRect().height)||0,J.current=(null==(n=K.current)?void 0:n.getBoundingClientRect().width)||0,D(!0),V.current=new Date,AD()&&window.addEventListener("touchend",(()=>U.current=!1),{once:!0}),e.target.setPointerCapture(e.pointerId),W.current=Wr(w)?e.pageY:e.pageX)},onRelease:function(e){if(!j||!K.current)return;K.current.classList.remove(wx),U.current=!1,D(!1),B.current=new Date;const t=Tg(K.current,w);if(!ce(e.target,!1)||!t||Number.isNaN(t)||null===V.current)return;const n=B.current.getTime()-V.current.getTime(),r=W.current-(Wr(w)?e.pageY:e.pageX),i=Math.abs(r)/n;if(i>.05&&(z(!0),setTimeout((()=>{z(!1)}),200)),a)return re({draggedDistance:r*("bottom"===w||"right"===w?1:-1),closeDrawer:de,velocity:i,dismissible:c}),void(null==o||o(e,!0));if("bottom"===w||"right"===w?r>0:r<0)return fe(),void(null==o||o(e,!0));if(i>kD)return de(),void(null==o||o(e,!1));var s;const l=Math.min(null!=(s=K.current.getBoundingClientRect().height)?s:0,window.innerHeight);var d;const f=Math.min(null!=(d=K.current.getBoundingClientRect().width)?d:0,window.innerWidth),p="left"===w||"right"===w;if(Math.abs(t)>=(p?f:l)*u)return de(),void(null==o||o(e,!1));null==o||o(e,!0),fe()},onDrag:function(e){if(K.current&&j){const t="bottom"===w||"right"===w?1:-1,n=(W.current-(Wr(w)?e.pageY:e.pageX))*t,o=n>0,s=a&&!c&&!o;if(s&&0===te)return;const u=Math.abs(n),l=document.querySelector("[data-vaul-drawer-wrapper]");let d=u/("bottom"===w||"top"===w?Y.current:J.current);const p=se(u,o);if(null!==p&&(d=p),s&&d>=1||!U.current&&!ce(e.target,o))return;if(K.current.classList.add(wx),U.current=!0,Ur(K.current,{transition:"none"}),Ur(L.current,{transition:"none"}),a&&ae({draggedDistance:n}),o&&!a){const e=Kj(n),r=Math.min(-1*e,0)*t;return void Ur(K.current,{transform:Wr(w)?`translate3d(0, ${r}px, 0)`:`translate3d(${r}px, 0, 0)`})}const m=1-d;if((ie||f&&te===f-1)&&(null==r||r(e,d),Ur(L.current,{opacity:`${m}`,transition:"none"},!0)),l&&L.current&&i){const e=Math.min(le()+d*(1-le()),1),t=8-8*d,n=Math.max(0,14-14*d);Ur(l,{borderRadius:`${t}px`,transform:Wr(w)?`scale(${e}) translate3d(0, ${n}px, 0)`:`scale(${e}) translate3d(${n}px, 0, 0)`,transition:"none"},!0)}if(!a){const e=u*t;Ur(K.current,{transform:Wr(w)?`translate3d(0, ${e}px, 0)`:`translate3d(${e}px, 0, 0)`})}}},dismissible:c,handleOnly:d,isOpen:P,isDragging:j,shouldFade:ie,closeDrawer:de,onNestedDrag:function(e,t){if(t<0)return;const n=(window.innerWidth-16)/window.innerWidth,r=n+t*(1-n),o=16*t-16;Ur(K.current,{transform:Wr(w)?`scale(${r}) translate3d(0, ${o}px, 0)`:`scale(${r}) translate3d(${o}px, 0, 0)`,transition:"none"})},onNestedOpenChange:function(e){const t=e?(window.innerWidth-16)/window.innerWidth:1,n=e?-16:0;G.current&&window.clearTimeout(G.current),Ur(K.current,{transition:`transform ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,transform:`scale(${t}) translate3d(0, ${n}px, 0)`}),!e&&K.current&&(G.current=setTimeout((()=>{const e=Tg(K.current,w);Ur(K.current,{transition:"none",transform:Wr(w)?`translate3d(0, ${e}px, 0)`:`translate3d(${e}px, 0, 0)`})}),500))},onNestedRelease:function(e,t){const n=Wr(w)?window.innerHeight:window.innerWidth,r=t?(n-16)/n:1,o=t?-16:0;t&&Ur(K.current,{transition:`transform ${zn.DURATION}s cubic-bezier(${zn.EASE.join(",")})`,transform:Wr(w)?`scale(${r}) translate3d(0, ${o}px, 0)`:`scale(${r}) translate3d(${o}px, 0, 0)`})},keyboardIsOpen:H,modal:h,snapPointsOffset:oe,direction:w,shouldScaleBackground:i,setBackgroundColorOnScale:s,noBodyStyles:b,container:k,autoFocus:C}},n))}const zD=Ue.forwardRef((function({...e},t){const{overlayRef:n,snapPoints:r,onRelease:o,shouldFade:a,isOpen:i,modal:s}=Vm(),u=DD(t,n),l=r&&r.length>0;return s?Ue.createElement(Tj,{onMouseUp:o,ref:u,"data-vaul-overlay":"","data-vaul-snap-points":i&&l?"true":"false","data-vaul-snap-points-overlay":i&&a?"true":"false",...e}):(typeof window<"u"&&window.requestAnimationFrame((()=>{document.body.style.pointerEvents="auto"})),null)}));zD.displayName="Drawer.Overlay";const VD=Ue.forwardRef((function({onPointerDownOutside:e,style:t,onOpenAutoFocus:n,...r},o){const{drawerRef:a,onPress:i,onRelease:s,onDrag:u,keyboardIsOpen:l,snapPointsOffset:c,modal:d,isOpen:f,direction:p,snapPoints:m,container:v,handleOnly:h,autoFocus:g}=Vm(),[y,b]=Ue.useState(!1),w=DD(o,a),x=Ue.useRef(null),_=Ue.useRef(null),E=Ue.useRef(!1),S=m&&m.length>0;tz();function I(e){x.current=null,E.current=!1,s(e)}return Ue.useEffect((()=>{S&&window.requestAnimationFrame((()=>{b(!0)}))}),[]),Ue.createElement(Oj,{"data-vaul-drawer-direction":p,"data-vaul-drawer":"","data-vaul-delayed-snap-points":y?"true":"false","data-vaul-snap-points":f&&S?"true":"false","data-vaul-custom-container":v?"true":"false",...r,ref:w,style:c&&c.length>0?{"--snap-point-height":`${c[0]}px`,...t}:t,onPointerDown:e=>{h||(null==r.onPointerDown||r.onPointerDown.call(r,e),x.current={x:e.pageX,y:e.pageY},i(e))},onOpenAutoFocus:e=>{null==n||n(e),g||e.preventDefault()},onPointerDownOutside:t=>{null==e||e(t),d&&!t.defaultPrevented?l.current&&(l.current=!1):t.preventDefault()},onFocusOutside:e=>{d||e.preventDefault()},onPointerMove:e=>{if(_.current=e,h||(null==r.onPointerMove||r.onPointerMove.call(r,e),!x.current))return;const t=e.pageY-x.current.y,n=e.pageX-x.current.x,o="touch"===e.pointerType?10:2;((e,t,n=0)=>{if(E.current)return!0;const r=Math.abs(e.y),o=Math.abs(e.x),a=o>r,i=["bottom","right"].includes(t)?1:-1;if("left"===t||"right"===t){if(!(e.x*i<0)&&o>=0&&o<=n)return a}else if(!(e.y*i<0)&&r>=0&&r<=n)return!a;return E.current=!0,!0})({x:n,y:t},p,o)?u(e):(Math.abs(n)>o||Math.abs(t)>o)&&(x.current=null)},onPointerUp:e=>{null==r.onPointerUp||r.onPointerUp.call(r,e),x.current=null,E.current=!1,s(e)},onPointerOut:e=>{null==r.onPointerOut||r.onPointerOut.call(r,e),I(_.current)},onContextMenu:e=>{null==r.onContextMenu||r.onContextMenu.call(r,e),I(_.current)}})}));VD.displayName="Drawer.Content";const rz=250,oz=120,UD=Ue.forwardRef((function({preventCycle:e=!1,children:t,...n},r){const{closeDrawer:o,isDragging:a,snapPoints:i,activeSnapPoint:s,setActiveSnapPoint:u,dismissible:l,handleOnly:c,isOpen:d,onPress:f,onDrag:p}=Vm(),m=Ue.useRef(null),v=Ue.useRef(!1);function h(){window.clearTimeout(m.current),v.current=!1}return Ue.createElement("div",{onClick:function(){v.current?h():window.setTimeout((()=>{!function(){if(a||e||v.current)return void h();if(h(),(!i||0===i.length)&&l)return void o();if(s===i[i.length-1]&&l)return void o();const t=i.findIndex((e=>e===s));if(-1===t)return;const n=i[t+1];u(n)}()}),oz)},onPointerCancel:h,onPointerDown:e=>{c&&f(e),m.current=window.setTimeout((()=>{v.current=!0}),rz)},onPointerMove:e=>{c&&p(e)},ref:r,"data-vaul-drawer-visible":d?"true":"false","data-vaul-handle":"","aria-hidden":"true",...n},Ue.createElement("span",{"data-vaul-handle-hitarea":"","aria-hidden":"true"},t))}));function iz({onDrag:e,onOpenChange:t,...n}){const{onNestedDrag:r,onNestedOpenChange:o,onNestedRelease:a}=Vm();if(!r)throw new Error("Drawer.NestedRoot must be placed in another drawer");return Ue.createElement(jD,{nested:!0,onClose:()=>{o(!1)},onDrag:(t,n)=>{r(t,n),null==e||e(t,n)},onOpenChange:e=>{e&&o(e)},onRelease:a,...n})}function az(e){const t=Vm(),{container:n=t.container,...r}=e;return Ue.createElement(Pj,{container:n,...r})}UD.displayName="Drawer.Handle";const wd={Root:jD,NestedRoot:iz,Content:VD,Overlay:zD,Trigger:Rj,Portal:az,Handle:UD,Close:Dj,Title:Aj,Description:Mj},sz=wd.Portal,WD=v.forwardRef((({className:e,...t},n)=>G.jsx(wd.Overlay,{ref:n,className:we("fixed inset-0 z-50 bg-black/5",e),...t})));WD.displayName=wd.Overlay.displayName;const uz=v.forwardRef((({className:e,children:t,direction:n="bottom",...r},o)=>G.jsxs(sz,{children:[G.jsx(WD,{}),G.jsxs(wd.Content,{ref:o,className:we("fixed z-50 border bg-background shadow-lg","bottom"===n&&"inset-x-0 bottom-0 mt-24 flex h-auto flex-col rounded-t-sm","top"===n&&"inset-x-0 top-0 mb-24 flex h-auto flex-col rounded-b-sm","left"===n&&"inset-y-0 left-0 flex h-full flex-col","right"===n&&"inset-y-0 right-0 flex h-full w-[346px] flex-col sm:w-[435px]",e),...r,children:["bottom"===n&&G.jsx("div",{className:"mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted"}),t]})]})));uz.displayName="DrawerContent";const lz=v.forwardRef((({className:e,...t},n)=>G.jsx(wd.Title,{ref:n,className:we("text-lg font-semibold leading-none tracking-tight",e),...t})));lz.displayName=wd.Title.displayName;const cz=v.forwardRef((({className:e,...t},n)=>G.jsx(wd.Description,{ref:n,className:we("text-sm text-muted-foreground",e),...t})));function a$(e){const t=e+"CollectionProvider",[n,r]=ni(t),[o,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=e+"CollectionSlot",s=e+"CollectionItemSlot",u="data-radix-collection-item";return[{Provider:e=>{const{scope:t,children:n}=e,r=Ue.useRef(null),a=Ue.useRef(new Map).current;return Ue.createElement(o,{scope:t,itemMap:a,collectionRef:r},n)},Slot:Ue.forwardRef(((e,t)=>{const{scope:n,children:r}=e,o=Vt(t,a(i,n).collectionRef);return Ue.createElement(qf,{ref:o},r)})),ItemSlot:Ue.forwardRef(((e,t)=>{const{scope:n,children:r,...o}=e,i=Ue.useRef(null),l=Vt(t,i),c=a(s,n);return Ue.useEffect((()=>(c.itemMap.set(i,{ref:i,...o}),()=>{c.itemMap.delete(i)}))),Ue.createElement(qf,{[u]:"",ref:l},r)}))},function(t){const n=a(e+"CollectionConsumer",t);return Ue.useCallback((()=>{const e=n.collectionRef.current;if(!e)return[];const t=Array.from(e.querySelectorAll(`[${u}]`));return Array.from(n.itemMap.values()).sort(((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current)))}),[n.collectionRef,n.itemMap])},r]}cz.displayName=wd.Description.displayName;const dz=v.createContext(void 0);function s$(e){const t=v.useContext(dz);return e||t||"ltr"}const fz=["top","right","bottom","left"],pd=Math.min,Xi=Math.max,Zg=Math.round,Og=Math.floor,md=e=>({x:e,y:e}),pz={left:"right",right:"left",bottom:"top",top:"bottom"},mz={start:"end",end:"start"};function VS(e,t,n){return Xi(e,pd(t,n))}function Sl(e,t){return"function"==typeof e?e(t):e}function El(e){return e.split("-")[0]}function Um(e){return e.split("-")[1]}function u$(e){return"x"===e?"y":"x"}function l$(e){return"y"===e?"height":"width"}function hd(e){return["top","bottom"].includes(El(e))?"y":"x"}function c$(e){return u$(hd(e))}function hz(e,t,n){void 0===n&&(n=!1);const r=Um(e),o=c$(e),a=l$(o);let i="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[a]>t.floating[a]&&(i=ey(i)),[i,ey(i)]}function vz(e){const t=ey(e);return[US(e),t,US(t)]}function US(e){return e.replace(/start|end/g,(e=>mz[e]))}function gz(e,t,n){const r=["left","right"],o=["right","left"],a=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?a:i;default:return[]}}function yz(e,t,n,r){const o=Um(e);let a=gz(El(e),"start"===n,r);return o&&(a=a.map((e=>e+"-"+o)),t&&(a=a.concat(a.map(US)))),a}function ey(e){return e.replace(/left|right|bottom|top/g,(e=>pz[e]))}function wz(e){return{top:0,right:0,bottom:0,left:0,...e}}function qD(e){return"number"!=typeof e?wz(e):{top:e,right:e,bottom:e,left:e}}function ty(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function DT(e,t,n){let{reference:r,floating:o}=e;const a=hd(t),i=c$(t),s=l$(i),u=El(t),l="y"===a,c=r.x+r.width/2-o.width/2,d=r.y+r.height/2-o.height/2,f=r[s]/2-o[s]/2;let p;switch(u){case"top":p={x:c,y:r.y-o.height};break;case"bottom":p={x:c,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:d};break;case"left":p={x:r.x-o.width,y:d};break;default:p={x:r.x,y:r.y}}switch(Um(t)){case"start":p[i]-=f*(n&&l?-1:1);break;case"end":p[i]+=f*(n&&l?-1:1)}return p}const bz=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:i}=n,s=a.filter(Boolean),u=await(null==i.isRTL?void 0:i.isRTL(t));let l=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:d}=DT(l,r,u),f=r,p={},m=0;for(let n=0;n<s.length;n++){const{name:a,fn:v}=s[n],{x:h,y:g,data:y,reset:b}=await v({x:c,y:d,initialPlacement:r,placement:f,strategy:o,middlewareData:p,rects:l,platform:i,elements:{reference:e,floating:t}});c=h??c,d=g??d,p={...p,[a]:{...p[a],...y}},b&&m<=50&&(m++,"object"==typeof b&&(b.placement&&(f=b.placement),b.rects&&(l=!0===b.rects?await i.getElementRects({reference:e,floating:t,strategy:o}):b.rects),({x:c,y:d}=DT(l,f,u))),n=-1)}return{x:c,y:d,placement:f,strategy:o,middlewareData:p}};async function yv(e,t){var n;void 0===t&&(t={});const{x:r,y:o,platform:a,rects:i,elements:s,strategy:u}=e,{boundary:l="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=Sl(t,e),m=qD(p),v=s[f?"floating"===d?"reference":"floating":d],h=ty(await a.getClippingRect({element:null==(n=await(null==a.isElement?void 0:a.isElement(v)))||n?v:v.contextElement||await(null==a.getDocumentElement?void 0:a.getDocumentElement(s.floating)),boundary:l,rootBoundary:c,strategy:u})),g="floating"===d?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,y=await(null==a.getOffsetParent?void 0:a.getOffsetParent(s.floating)),b=await(null==a.isElement?void 0:a.isElement(y))&&await(null==a.getScale?void 0:a.getScale(y))||{x:1,y:1},w=ty(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:g,offsetParent:y,strategy:u}):g);return{top:(h.top-w.top+m.top)/b.y,bottom:(w.bottom-h.bottom+m.bottom)/b.y,left:(h.left-w.left+m.left)/b.x,right:(w.right-h.right+m.right)/b.x}}const _z=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:a,platform:i,elements:s,middlewareData:u}=t,{element:l,padding:c=0}=Sl(e,t)||{};if(null==l)return{};const d=qD(c),f={x:n,y:r},p=c$(o),m=l$(p),v=await i.getDimensions(l),h="y"===p,g=h?"top":"left",y=h?"bottom":"right",b=h?"clientHeight":"clientWidth",w=a.reference[m]+a.reference[p]-f[p]-a.floating[m],x=f[p]-a.reference[p],_=await(null==i.getOffsetParent?void 0:i.getOffsetParent(l));let E=_?_[b]:0;(!E||!await(null==i.isElement?void 0:i.isElement(_)))&&(E=s.floating[b]||a.floating[m]);const S=w/2-x/2,I=E/2-v[m]/2-1,A=pd(d[g],I),k=pd(d[y],I),C=A,T=E-v[m]-k,R=E/2-v[m]/2+S,P=VS(C,R,T),O=!u.arrow&&null!=Um(o)&&R!==P&&a.reference[m]/2-(R<C?A:k)-v[m]/2<0,N=O?R<C?R-C:R-T:0;return{[p]:f[p]+N,data:{[p]:P,centerOffset:R-P-N,...O&&{alignmentOffset:N}},reset:O}}}),xz=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:a,rects:i,initialPlacement:s,platform:u,elements:l}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:v=!0,...h}=Sl(e,t);if(null!=(n=a.arrow)&&n.alignmentOffset)return{};const g=El(o),y=hd(s),b=El(s)===s,w=await(null==u.isRTL?void 0:u.isRTL(l.floating)),x=f||(b||!v?[ey(s)]:vz(s)),_="none"!==m;!f&&_&&x.push(...yz(s,v,m,w));const E=[s,...x],S=await yv(t,h),I=[];let A=(null==(r=a.flip)?void 0:r.overflows)||[];if(c&&I.push(S[g]),d){const e=hz(o,i,w);I.push(S[e[0]],S[e[1]])}if(A=[...A,{placement:o,overflows:I}],!I.every((e=>e<=0))){var k,C;const e=((null==(k=a.flip)?void 0:k.index)||0)+1,t=E[e];if(t)return{data:{index:e,overflows:A},reset:{placement:t}};let n=null==(C=A.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:C.placement;if(!n)switch(p){case"bestFit":{var T;const e=null==(T=A.filter((e=>{if(_){const t=hd(e.placement);return t===y||"y"===t}return!0})).map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:T[0];e&&(n=e);break}case"initialPlacement":n=s}if(o!==n)return{reset:{placement:n}}}return{}}}};function NT(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function kT(e){return fz.some((t=>e[t]>=0))}const Sz=function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=Sl(e,t);switch(r){case"referenceHidden":{const e=NT(await yv(t,{...o,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:kT(e)}}}case"escaped":{const e=NT(await yv(t,{...o,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:kT(e)}}}default:return{}}}}};async function Ez(e,t){const{placement:n,platform:r,elements:o}=e,a=await(null==r.isRTL?void 0:r.isRTL(o.floating)),i=El(n),s=Um(n),u="y"===hd(n),l=["left","top"].includes(i)?-1:1,c=a&&u?-1:1,d=Sl(t,e);let{mainAxis:f,crossAxis:p,alignmentAxis:m}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof m&&(p="end"===s?-1*m:m),u?{x:p*c,y:f*l}:{x:f*l,y:p*c}}const $z=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:a,placement:i,middlewareData:s}=t,u=await Ez(t,e);return i===(null==(n=s.offset)?void 0:n.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:o+u.x,y:a+u.y,data:{...u,placement:i}}}}},Cz=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:i=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...u}=Sl(e,t),l={x:n,y:r},c=await yv(t,u),d=hd(El(o)),f=u$(d);let p=l[f],m=l[d];if(a){const e="y"===f?"bottom":"right";p=VS(p+c["y"===f?"top":"left"],p,p-c[e])}if(i){const e="y"===d?"bottom":"right";m=VS(m+c["y"===d?"top":"left"],m,m-c[e])}const v=s.fn({...t,[f]:p,[d]:m});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[f]:a,[d]:i}}}}}},Iz=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:i}=t,{offset:s=0,mainAxis:u=!0,crossAxis:l=!0}=Sl(e,t),c={x:n,y:r},d=hd(o),f=u$(d);let p=c[f],m=c[d];const v=Sl(s,t),h="number"==typeof v?{mainAxis:v,crossAxis:0}:{mainAxis:0,crossAxis:0,...v};if(u){const e="y"===f?"height":"width",t=a.reference[f]-a.floating[e]+h.mainAxis,n=a.reference[f]+a.reference[e]-h.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){var g,y;const e="y"===f?"width":"height",t=["top","left"].includes(El(o)),n=a.reference[d]-a.floating[e]+(t&&(null==(g=i.offset)?void 0:g[d])||0)+(t?0:h.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:(null==(y=i.offset)?void 0:y[d])||0)-(t?h.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[f]:p,[d]:m}}}},Rz=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:a,platform:i,elements:s}=t,{apply:u=()=>{},...l}=Sl(e,t),c=await yv(t,l),d=El(o),f=Um(o),p="y"===hd(o),{width:m,height:v}=a.floating;let h,g;"top"===d||"bottom"===d?(h=d,g=f===(await(null==i.isRTL?void 0:i.isRTL(s.floating))?"start":"end")?"left":"right"):(g=d,h="end"===f?"top":"bottom");const y=v-c.top-c.bottom,b=m-c.left-c.right,w=pd(v-c[h],y),x=pd(m-c[g],b),_=!t.middlewareData.shift;let E=w,S=x;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(S=b),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(E=y),_&&!f){const e=Xi(c.left,0),t=Xi(c.right,0),n=Xi(c.top,0),r=Xi(c.bottom,0);p?S=m-2*(0!==e||0!==t?e+t:Xi(c.left,c.right)):E=v-2*(0!==n||0!==r?n+r:Xi(c.top,c.bottom))}await u({...t,availableWidth:S,availableHeight:E});const I=await i.getDimensions(s.floating);return m!==I.width||v!==I.height?{reset:{rects:!0}}:{}}}};function zy(){return typeof window<"u"}function vd(e){return GD(e)?(e.nodeName||"").toLowerCase():"#document"}function Ji(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Rl(e){var t;return null==(t=(GD(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function GD(e){return!!zy()&&(e instanceof Node||e instanceof Ji(e).Node)}function pu(e){return!!zy()&&(e instanceof Element||e instanceof Ji(e).Element)}function mu(e){return!!zy()&&(e instanceof HTMLElement||e instanceof Ji(e).HTMLElement)}function LT(e){return!(!zy()||typeof ShadowRoot>"u")&&(e instanceof ShadowRoot||e instanceof Ji(e).ShadowRoot)}function Fv(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Na(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function Pz(e){return["table","td","th"].includes(vd(e))}function Tz(e){return[":popover-open",":modal"].some((t=>{try{return e.matches(t)}catch{return!1}}))}function d$(e){const t=f$(),n=pu(e)?Na(e):e;return"none"!==n.transform||"none"!==n.perspective||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((e=>(n.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(n.contain||"").includes(e)))}function HD(e){let t=Nm(e);for(;mu(t)&&!Vy(t);){if(d$(t))return t;if(Tz(t))return null;t=Nm(t)}return null}function f$(){return!(typeof CSS>"u"||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function Vy(e){return["html","body","#document"].includes(vd(e))}function Na(e){return Ji(e).getComputedStyle(e)}function Uy(e){return pu(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Nm(e){if("html"===vd(e))return e;const t=e.assignedSlot||e.parentNode||LT(e)&&e.host||Rl(e);return LT(t)?t.host:t}function KD(e){const t=Nm(e);return Vy(t)?e.ownerDocument?e.ownerDocument.body:e.body:mu(t)&&Fv(t)?t:KD(t)}function wv(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const o=KD(e),a=o===(null==(r=e.ownerDocument)?void 0:r.body),i=Ji(o);if(a){const e=Oz(i);return t.concat(i,i.visualViewport||[],Fv(o)?o:[],e&&n?wv(e):[])}return t.concat(o,wv(o,[],n))}function Oz(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function YD(e){const t=Na(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=mu(e),a=o?e.offsetWidth:n,i=o?e.offsetHeight:r,s=Zg(n)!==a||Zg(r)!==i;return s&&(n=a,r=i),{width:n,height:r,$:s}}function p$(e){return pu(e)?e:e.contextElement}function Pm(e){const t=p$(e);if(!mu(t))return md(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=YD(t);let i=(a?Zg(n.width):n.width)/r,s=(a?Zg(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!s||!Number.isFinite(s))&&(s=1),{x:i,y:s}}const Az=md(0);function QD(e){const t=Ji(e);return f$()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Az}function Mz(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==Ji(e))&&t}function Xf(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const o=e.getBoundingClientRect(),a=p$(e);let i=md(1);t&&(r?pu(r)&&(i=Pm(r)):i=Pm(e));const s=Mz(a,n,r)?QD(a):md(0);let u=(o.left+s.x)/i.x,l=(o.top+s.y)/i.y,c=o.width/i.x,d=o.height/i.y;if(a){const e=Ji(a),t=r&&pu(r)?Ji(r):r;let n=e.frameElement;for(;n&&r&&t!==e;){const e=Pm(n),t=n.getBoundingClientRect(),r=Na(n),o=t.left+(n.clientLeft+parseFloat(r.paddingLeft))*e.x,a=t.top+(n.clientTop+parseFloat(r.paddingTop))*e.y;u*=e.x,l*=e.y,c*=e.x,d*=e.y,u+=o,l+=a,n=Ji(n).frameElement}}return ty({width:c,height:d,x:u,y:l})}const Dz=[":popover-open",":modal"];function XD(e){let t=!1,n=0,r=0;if(Dz.forEach((n=>{!function(n){try{t=t||e.matches(n)}catch{}}(n)})),t){const t=HD(e);if(t){const e=t.getBoundingClientRect();n=e.x,r=e.y}}return[t,n,r]}function Nz(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=Rl(r),[i]=t?XD(t.floating):[!1];if(r===a||i)return n;let s={scrollLeft:0,scrollTop:0},u=md(1);const l=md(0),c=mu(r);if((c||!c&&"fixed"!==o)&&(("body"!==vd(r)||Fv(a))&&(s=Uy(r)),mu(r))){const e=Xf(r);u=Pm(r),l.x=e.x+r.clientLeft,l.y=e.y+r.clientTop}return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-s.scrollLeft*u.x+l.x,y:n.y*u.y-s.scrollTop*u.y+l.y}}function kz(e){return Array.from(e.getClientRects())}function JD(e){return Xf(Rl(e)).left+Uy(e).scrollLeft}function Lz(e){const t=Rl(e),n=Uy(e),r=e.ownerDocument.body,o=Xi(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Xi(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+JD(e);const s=-n.scrollTop;return"rtl"===Na(r).direction&&(i+=Xi(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:i,y:s}}function Fz(e,t){const n=Ji(e),r=Rl(e),o=n.visualViewport;let a=r.clientWidth,i=r.clientHeight,s=0,u=0;if(o){a=o.width,i=o.height;const e=f$();(!e||e&&"fixed"===t)&&(s=o.offsetLeft,u=o.offsetTop)}return{width:a,height:i,x:s,y:u}}function Bz(e,t){const n=Xf(e,!0,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=mu(e)?Pm(e):md(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:o*a.x,y:r*a.y}}function FT(e,t,n){let r;if("viewport"===t)r=Fz(e,n);else if("document"===t)r=Lz(Rl(e));else if(pu(t))r=Bz(t,n);else{const n=QD(e);r={...t,x:t.x-n.x,y:t.y-n.y}}return ty(r)}function ZD(e,t){const n=Nm(e);return!(n===t||!pu(n)||Vy(n))&&("fixed"===Na(n).position||ZD(n,t))}function jz(e,t){const n=t.get(e);if(n)return n;let r=wv(e,[],!1).filter((e=>pu(e)&&"body"!==vd(e))),o=null;const a="fixed"===Na(e).position;let i=a?Nm(e):e;for(;pu(i)&&!Vy(i);){const t=Na(i),n=d$(i);!n&&"fixed"===t.position&&(o=null),(a?!n&&!o:!n&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||Fv(i)&&!n&&ZD(e,i))?r=r.filter((e=>e!==i)):o=t,i=Nm(i)}return t.set(e,r),r}function zz(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[..."clippingAncestors"===n?jz(t,this._c):[].concat(n),r],i=a[0],s=a.reduce(((e,n)=>{const r=FT(t,n,o);return e.top=Xi(r.top,e.top),e.right=pd(r.right,e.right),e.bottom=pd(r.bottom,e.bottom),e.left=Xi(r.left,e.left),e}),FT(t,i,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}}function Vz(e){const{width:t,height:n}=YD(e);return{width:t,height:n}}function Uz(e,t,n,r){const o=mu(t),a=Rl(t),i="fixed"===n,s=Xf(e,!0,i,t);let u={scrollLeft:0,scrollTop:0};const l=md(0);if(o||!o&&!i)if(("body"!==vd(t)||Fv(a))&&(u=Uy(t)),o){const e=Xf(t,!0,i,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else a&&(l.x=JD(a));let c=s.left+u.scrollLeft-l.x,d=s.top+u.scrollTop-l.y;const[f,p,m]=XD(r);return f&&(c+=p,d+=m,o&&(c+=t.clientLeft,d+=t.clientTop)),{x:c,y:d,width:s.width,height:s.height}}function BT(e,t){return mu(e)&&"fixed"!==Na(e).position?t?t(e):e.offsetParent:null}function eN(e,t){const n=Ji(e);if(!mu(e))return n;let r=BT(e,t);for(;r&&Pz(r)&&"static"===Na(r).position;)r=BT(r,t);return r&&("html"===vd(r)||"body"===vd(r)&&"static"===Na(r).position&&!d$(r))?n:r||HD(e)||n}const Wz=async function(e){const t=this.getOffsetParent||eN,n=this.getDimensions;return{reference:Uz(e.reference,await t(e.floating),e.strategy,e.floating),floating:{x:0,y:0,...await n(e.floating)}}};function qz(e){return"rtl"===Na(e).direction}const Gz={convertOffsetParentRelativeRectToViewportRelativeRect:Nz,getDocumentElement:Rl,getClippingRect:zz,getOffsetParent:eN,getElementRects:Wz,getClientRects:kz,getDimensions:Vz,getScale:Pm,isElement:pu,isRTL:qz};function Hz(e,t){let n,r=null;const o=Rl(e);function a(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function i(s,u){void 0===s&&(s=!1),void 0===u&&(u=1),a();const{left:l,top:c,width:d,height:f}=e.getBoundingClientRect();if(s||t(),!d||!f)return;const p={rootMargin:-Og(c)+"px "+-Og(o.clientWidth-(l+d))+"px "+-Og(o.clientHeight-(c+f))+"px "+-Og(l)+"px",threshold:Xi(0,pd(1,u))||1};let m=!0;function v(e){const t=e[0].intersectionRatio;if(t!==u){if(!m)return i();t?i(!1,t):n=setTimeout((()=>{i(!1,1e-7)}),100)}m=!1}try{r=new IntersectionObserver(v,{...p,root:o.ownerDocument})}catch{r=new IntersectionObserver(v,p)}r.observe(e)}(!0),a}function Kz(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:i="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:u=!1}=r,l=p$(e),c=o||a?[...l?wv(l):[],...wv(t)]:[];c.forEach((e=>{o&&e.addEventListener("scroll",n,{passive:!0}),a&&e.addEventListener("resize",n)}));const d=l&&s?Hz(l,n):null;let f=-1,p=null;i&&(p=new ResizeObserver((e=>{let[r]=e;r&&r.target===l&&p&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame((()=>{var e;null==(e=p)||e.observe(t)}))),n()})),l&&!u&&p.observe(l),p.observe(t));let m,v=u?Xf(e):null;return u&&function t(){const r=Xf(e);v&&(r.x!==v.x||r.y!==v.y||r.width!==v.width||r.height!==v.height)&&n(),v=r,m=requestAnimationFrame(t)}(),n(),()=>{var e;c.forEach((e=>{o&&e.removeEventListener("scroll",n),a&&e.removeEventListener("resize",n)})),null==d||d(),null==(e=p)||e.disconnect(),p=null,u&&cancelAnimationFrame(m)}}const Yz=Cz,Qz=xz,Xz=Rz,Jz=Sz,jT=_z,Zz=Iz,eV=(e,t,n)=>{const r=new Map,o={platform:Gz,...n},a={...o.platform,_c:r};return bz(e,t,{...o,platform:a})};var Vg=typeof document<"u"?v.useLayoutEffect:v.useEffect;function ny(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;0!=r--;)if(!ny(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){const n=o[r];if(!("_owner"===n&&e.$$typeof||ny(e[n],t[n])))return!1}return!0}return e!=e&&t!=t}function tN(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function zT(e,t){const n=tN(e);return Math.round(t*n)/n}function bx(e){const t=v.useRef(e);return Vg((()=>{t.current=e})),t}function tV(e){void 0===e&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:a,floating:i}={},transform:s=!0,whileElementsMounted:u,open:l}=e,[c,d]=v.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=v.useState(r);ny(f,r)||p(r);const[m,h]=v.useState(null),[g,y]=v.useState(null),b=v.useCallback((e=>{e!==E.current&&(E.current=e,h(e))}),[]),w=v.useCallback((e=>{e!==S.current&&(S.current=e,y(e))}),[]),x=a||m,_=i||g,E=v.useRef(null),S=v.useRef(null),I=v.useRef(c),A=null!=u,k=bx(u),C=bx(o),T=bx(l),R=v.useCallback((()=>{if(!E.current||!S.current)return;const e={placement:t,strategy:n,middleware:f};C.current&&(e.platform=C.current),eV(E.current,S.current,e).then((e=>{const t={...e,isPositioned:!1!==T.current};P.current&&!ny(I.current,t)&&(I.current=t,vu.flushSync((()=>{d(t)})))}))}),[f,t,n,C,T]);Vg((()=>{!1===l&&I.current.isPositioned&&(I.current.isPositioned=!1,d((e=>({...e,isPositioned:!1}))))}),[l]);const P=v.useRef(!1);Vg((()=>(P.current=!0,()=>{P.current=!1})),[]),Vg((()=>{if(x&&(E.current=x),_&&(S.current=_),x&&_){if(k.current)return k.current(x,_,R);R()}}),[x,_,R,k,A]);const O=v.useMemo((()=>({reference:E,floating:S,setReference:b,setFloating:w})),[b,w]),N=v.useMemo((()=>({reference:x,floating:_})),[x,_]),M=v.useMemo((()=>{const e={position:n,left:0,top:0};if(!N.floating)return e;const t=zT(N.floating,c.x),r=zT(N.floating,c.y);return s?{...e,transform:"translate("+t+"px, "+r+"px)",...tN(N.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}}),[n,s,N.floating,c.x,c.y]);return v.useMemo((()=>({...c,update:R,refs:O,elements:N,floatingStyles:M})),[c,R,O,N,M])}const nV=e=>({name:"arrow",options:e,fn(t){const{element:n,padding:r}="function"==typeof e?e(t):e;return n&&function(e){return{}.hasOwnProperty.call(e,"current")}(n)?null!=n.current?jT({element:n.current,padding:r}).fn(t):{}:n?jT({element:n,padding:r}).fn(t):{}}}),rV=(e,t)=>({...$z(e),options:[e,t]}),oV=(e,t)=>({...Yz(e),options:[e,t]}),iV=(e,t)=>({...Zz(e),options:[e,t]}),aV=(e,t)=>({...Qz(e),options:[e,t]}),sV=(e,t)=>({...Xz(e),options:[e,t]}),uV=(e,t)=>({...Jz(e),options:[e,t]}),lV=(e,t)=>({...nV(e),options:[e,t]}),nN="Popper",[rN,Wm]=ni(nN),[cV,oN]=rN(nN),dV=e=>{const{__scopePopper:t,children:n}=e,[r,o]=v.useState(null);return v.createElement(cV,{scope:t,anchor:r,onAnchorChange:o},n)},fV="PopperAnchor",pV=v.forwardRef(((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,a=oN(fV,n),i=v.useRef(null),s=Vt(t,i);return v.useEffect((()=>{a.onAnchorChange((null==r?void 0:r.current)||i.current)})),r?null:v.createElement(ft.div,Te({},o,{ref:s}))})),iN="PopperContent",[mV,GJ]=rN(iN),hV=v.forwardRef(((e,t)=>{var n,r,o,a,i,s,u,l;const{__scopePopper:c,side:d="bottom",sideOffset:f=0,align:p="center",alignOffset:m=0,arrowPadding:h=0,avoidCollisions:g=!0,collisionBoundary:y=[],collisionPadding:b=0,sticky:w="partial",hideWhenDetached:x=!1,updatePositionStrategy:_="optimized",onPlaced:E,...S}=e,I=oN(iN,c),[A,k]=v.useState(null),C=Vt(t,(e=>k(e))),[T,R]=v.useState(null),P=Ly(T),O=null!==(n=null==P?void 0:P.width)&&void 0!==n?n:0,N=null!==(r=null==P?void 0:P.height)&&void 0!==r?r:0,M=d+("center"!==p?"-"+p:""),j="number"==typeof b?b:{top:0,right:0,bottom:0,left:0,...b},D=Array.isArray(y)?y:[y],q=D.length>0,z={padding:j,boundary:D.filter(vV),altBoundary:q},{refs:L,floatingStyles:$,placement:V,isPositioned:B,middlewareData:F}=tV({strategy:"fixed",placement:M,whileElementsMounted:(...e)=>Kz(...e,{animationFrame:"always"===_}),elements:{reference:I.anchor},middleware:[rV({mainAxis:f+N,alignmentAxis:m}),g&&oV({mainAxis:!0,crossAxis:!1,limiter:"partial"===w?iV():void 0,...z}),g&&aV({...z}),sV({...z,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:o,height:a}=t.reference,i=e.floating.style;i.setProperty("--radix-popper-available-width",`${n}px`),i.setProperty("--radix-popper-available-height",`${r}px`),i.setProperty("--radix-popper-anchor-width",`${o}px`),i.setProperty("--radix-popper-anchor-height",`${a}px`)}}),T&&lV({element:T,padding:h}),gV({arrowWidth:O,arrowHeight:N}),x&&uV({strategy:"referenceHidden",...z})]}),[U,G]=aN(V),W=ws(E);Vo((()=>{B&&(null==W||W())}),[B,W]);const H=null===(o=F.arrow)||void 0===o?void 0:o.x,Q=null===(a=F.arrow)||void 0===a?void 0:a.y,K=0!==(null===(i=F.arrow)||void 0===i?void 0:i.centerOffset),[Y,J]=v.useState();return Vo((()=>{A&&J(window.getComputedStyle(A).zIndex)}),[A]),v.createElement("div",{ref:L.setFloating,"data-radix-popper-content-wrapper":"",style:{...$,transform:B?$.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Y,"--radix-popper-transform-origin":[null===(s=F.transformOrigin)||void 0===s?void 0:s.x,null===(u=F.transformOrigin)||void 0===u?void 0:u.y].join(" ")},dir:e.dir},v.createElement(mV,{scope:c,placedSide:U,onArrowChange:R,arrowX:H,arrowY:Q,shouldHideArrow:K},v.createElement(ft.div,Te({"data-side":U,"data-align":G},S,{ref:C,style:{...S.style,animation:B?void 0:"none",opacity:null!==(l=F.hide)&&void 0!==l&&l.referenceHidden?0:void 0}}))))}));function vV(e){return null!==e}const gV=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,a,i;const{placement:s,rects:u,middlewareData:l}=t,c=0!==(null===(n=l.arrow)||void 0===n?void 0:n.centerOffset),d=c?0:e.arrowWidth,f=c?0:e.arrowHeight,[p,m]=aN(s),v={start:"0%",center:"50%",end:"100%"}[m],h=(null!==(r=null===(o=l.arrow)||void 0===o?void 0:o.x)&&void 0!==r?r:0)+d/2,g=(null!==(a=null===(i=l.arrow)||void 0===i?void 0:i.y)&&void 0!==a?a:0)+f/2;let y="",b="";return"bottom"===p?(y=c?v:`${h}px`,b=-f+"px"):"top"===p?(y=c?v:`${h}px`,b=`${u.floating.height+f}px`):"right"===p?(y=-f+"px",b=c?v:`${g}px`):"left"===p&&(y=`${u.floating.width+f}px`,b=c?v:`${g}px`),{data:{x:y,y:b}}}});function aN(e){const[t,n="center"]=e.split("-");return[t,n]}const sN=dV,m$=pV,h$=hV,_x="rovingFocusGroup.onEntryFocus",yV={bubbles:!1,cancelable:!0},v$="RovingFocusGroup",[WS,uN,wV]=a$(v$),[bV,qm]=ni(v$,[wV]),[_V,xV]=bV(v$),SV=v.forwardRef(((e,t)=>v.createElement(WS.Provider,{scope:e.__scopeRovingFocusGroup},v.createElement(WS.Slot,{scope:e.__scopeRovingFocusGroup},v.createElement(EV,Te({},e,{ref:t})))))),EV=v.forwardRef(((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:a,currentTabStopId:i,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:u,onEntryFocus:l,...c}=e,d=v.useRef(null),f=Vt(t,d),p=s$(a),[m=null,h]=fd({prop:i,defaultProp:s,onChange:u}),[g,y]=v.useState(!1),b=ws(l),w=uN(n),x=v.useRef(!1),[_,E]=v.useState(0);return v.useEffect((()=>{const e=d.current;if(e)return e.addEventListener(_x,b),()=>e.removeEventListener(_x,b)}),[b]),v.createElement(_V,{scope:n,orientation:r,dir:p,loop:o,currentTabStopId:m,onItemFocus:v.useCallback((e=>h(e)),[h]),onItemShiftTab:v.useCallback((()=>y(!0)),[]),onFocusableItemAdd:v.useCallback((()=>E((e=>e+1))),[]),onFocusableItemRemove:v.useCallback((()=>E((e=>e-1))),[])},v.createElement(ft.div,Te({tabIndex:g||0===_?-1:0,"data-orientation":r},c,{ref:f,style:{outline:"none",...e.style},onMouseDown:et(e.onMouseDown,(()=>{x.current=!0})),onFocus:et(e.onFocus,(e=>{const t=!x.current;if(e.target===e.currentTarget&&t&&!g){const t=new CustomEvent(_x,yV);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){const e=w().filter((e=>e.focusable));lN([e.find((e=>e.active)),e.find((e=>e.id===m)),...e].filter(Boolean).map((e=>e.ref.current)))}}x.current=!1})),onBlur:et(e.onBlur,(()=>y(!1)))})))})),$V="RovingFocusGroupItem",CV=v.forwardRef(((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:a,...i}=e,s=ad(),u=a||s,l=xV($V,n),c=l.currentTabStopId===u,d=uN(n),{onFocusableItemAdd:f,onFocusableItemRemove:p}=l;return v.useEffect((()=>{if(r)return f(),()=>p()}),[r,f,p]),v.createElement(WS.ItemSlot,{scope:n,id:u,focusable:r,active:o},v.createElement(ft.span,Te({tabIndex:c?0:-1,"data-orientation":l.orientation},i,{ref:t,onMouseDown:et(e.onMouseDown,(e=>{r?l.onItemFocus(u):e.preventDefault()})),onFocus:et(e.onFocus,(()=>l.onItemFocus(u))),onKeyDown:et(e.onKeyDown,(e=>{if("Tab"===e.key&&e.shiftKey)return void l.onItemShiftTab();if(e.target!==e.currentTarget)return;const t=PV(e,l.orientation,l.dir);if(void 0!==t){e.preventDefault();let n=d().filter((e=>e.focusable)).map((e=>e.ref.current));if("last"===t)n.reverse();else if("prev"===t||"next"===t){"prev"===t&&n.reverse();const r=n.indexOf(e.currentTarget);n=l.loop?TV(n,r+1):n.slice(r+1)}setTimeout((()=>lN(n)))}}))})))})),IV={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function RV(e,t){return"rtl"!==t?e:"ArrowLeft"===e?"ArrowRight":"ArrowRight"===e?"ArrowLeft":e}function PV(e,t,n){const r=RV(e.key,n);if(!("vertical"===t&&["ArrowLeft","ArrowRight"].includes(r)||"horizontal"===t&&["ArrowUp","ArrowDown"].includes(r)))return IV[r]}function lN(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function TV(e,t){return e.map(((n,r)=>e[(t+r)%e.length]))}const g$=SV,y$=CV,qS=["Enter"," "],OV=["ArrowDown","PageUp","Home"],cN=["ArrowUp","PageDown","End"],AV=[...OV,...cN],MV={ltr:[...qS,"ArrowRight"],rtl:[...qS,"ArrowLeft"]},DV={ltr:["ArrowLeft"],rtl:["ArrowRight"]},Wy="Menu",[bv,NV,kV]=a$(Wy),[tp,dN]=ni(Wy,[kV,Wm,qm]),fN=Wm(),pN=qm(),[HJ,np]=tp(Wy),[KJ,Bv]=tp(Wy),LV=v.forwardRef(((e,t)=>{const{__scopeMenu:n,...r}=e,o=fN(n);return v.createElement(m$,Te({},o,r,{ref:t}))})),mN="MenuPortal",[FV,hN]=tp(mN,{forceMount:void 0}),BV=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,a=np(mN,t);return v.createElement(FV,{scope:t,forceMount:n},v.createElement(ea,{present:n||a.open},v.createElement(by,{asChild:!0,container:o},r)))},vs="MenuContent",[jV,w$]=tp(vs),zV=v.forwardRef(((e,t)=>{const n=hN(vs,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=np(vs,e.__scopeMenu),i=Bv(vs,e.__scopeMenu);return v.createElement(bv.Provider,{scope:e.__scopeMenu},v.createElement(ea,{present:r||a.open},v.createElement(bv.Slot,{scope:e.__scopeMenu},i.modal?v.createElement(VV,Te({},o,{ref:t})):v.createElement(UV,Te({},o,{ref:t})))))})),VV=v.forwardRef(((e,t)=>{const n=np(vs,e.__scopeMenu),r=v.useRef(null),o=Vt(t,r);return v.useEffect((()=>{const e=r.current;if(e)return Sy(e)}),[]),v.createElement(b$,Te({},e,{ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:et(e.onFocusOutside,(e=>e.preventDefault()),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)}))})),UV=v.forwardRef(((e,t)=>{const n=np(vs,e.__scopeMenu);return v.createElement(b$,Te({},e,{ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)}))})),b$=v.forwardRef(((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:i,disableOutsidePointerEvents:s,onEntryFocus:u,onEscapeKeyDown:l,onPointerDownOutside:c,onFocusOutside:d,onInteractOutside:f,onDismiss:p,disableOutsideScroll:m,...h}=e,g=np(vs,n),y=Bv(vs,n),b=fN(n),w=pN(n),x=NV(n),[_,E]=v.useState(null),S=v.useRef(null),I=Vt(t,S,g.onContentChange),A=v.useRef(0),k=v.useRef(""),C=v.useRef(0),T=v.useRef(null),R=v.useRef("right"),P=v.useRef(0),O=m?xy:v.Fragment,N=m?{as:qf,allowPinchZoom:!0}:void 0;v.useEffect((()=>()=>window.clearTimeout(A.current)),[]),SE();const M=v.useCallback((e=>{var t,n;return R.current===(null===(t=T.current)||void 0===t?void 0:t.side)&&sU(e,null===(n=T.current)||void 0===n?void 0:n.area)}),[]);return v.createElement(jV,{scope:n,searchRef:k,onItemEnter:v.useCallback((e=>{M(e)&&e.preventDefault()}),[M]),onItemLeave:v.useCallback((e=>{var t;M(e)||(null===(t=S.current)||void 0===t||t.focus(),E(null))}),[M]),onTriggerLeave:v.useCallback((e=>{M(e)&&e.preventDefault()}),[M]),pointerGraceTimerRef:C,onPointerGraceIntentChange:v.useCallback((e=>{T.current=e}),[])},v.createElement(O,N,v.createElement(xE,{asChild:!0,trapped:o,onMountAutoFocus:et(a,(e=>{var t;e.preventDefault(),null===(t=S.current)||void 0===t||t.focus()})),onUnmountAutoFocus:i},v.createElement(wy,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:c,onFocusOutside:d,onInteractOutside:f,onDismiss:p},v.createElement(g$,Te({asChild:!0},w,{dir:y.dir,orientation:"vertical",loop:r,currentTabStopId:_,onCurrentTabStopIdChange:E,onEntryFocus:et(u,(e=>{y.isUsingKeyboardRef.current||e.preventDefault()}))}),v.createElement(h$,Te({role:"menu","aria-orientation":"vertical","data-state":bN(g.open),"data-radix-menu-content":"",dir:y.dir},b,h,{ref:I,style:{outline:"none",...h.style},onKeyDown:et(h.onKeyDown,(e=>{const t=e.target.closest("[data-radix-menu-content]")===e.currentTarget,n=e.ctrlKey||e.altKey||e.metaKey,r=1===e.key.length;t&&("Tab"===e.key&&e.preventDefault(),!n&&r&&(e=>{var t,n;const r=k.current+e,o=x().filter((e=>!e.disabled)),a=document.activeElement,i=null===(t=o.find((e=>e.ref.current===a)))||void 0===t?void 0:t.textValue,s=iU(o.map((e=>e.textValue)),r,i),u=null===(n=o.find((e=>e.textValue===s)))||void 0===n?void 0:n.ref.current;(function e(t){k.current=t,window.clearTimeout(A.current),""!==t&&(A.current=window.setTimeout((()=>e("")),1e3))})(r),u&&setTimeout((()=>u.focus()))})(e.key));const o=S.current;if(e.target!==o||!AV.includes(e.key))return;e.preventDefault();const a=x().filter((e=>!e.disabled)).map((e=>e.ref.current));cN.includes(e.key)&&a.reverse(),rU(a)})),onBlur:et(e.onBlur,(e=>{e.currentTarget.contains(e.target)||(window.clearTimeout(A.current),k.current="")})),onPointerMove:et(e.onPointerMove,_v((e=>{const t=e.target,n=P.current!==e.clientX;if(e.currentTarget.contains(t)&&n){const t=e.clientX>P.current?"right":"left";R.current=t,P.current=e.clientX}})))})))))))})),WV=v.forwardRef(((e,t)=>{const{__scopeMenu:n,...r}=e;return v.createElement(ft.div,Te({},r,{ref:t}))})),GS="MenuItem",VT="menu.itemSelect",_$=v.forwardRef(((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,a=v.useRef(null),i=Bv(GS,e.__scopeMenu),s=w$(GS,e.__scopeMenu),u=Vt(t,a),l=v.useRef(!1);return v.createElement(vN,Te({},o,{ref:u,disabled:n,onClick:et(e.onClick,(()=>{const e=a.current;if(!n&&e){const t=new CustomEvent(VT,{bubbles:!0,cancelable:!0});e.addEventListener(VT,(e=>null==r?void 0:r(e)),{once:!0}),vA(e,t),t.defaultPrevented?l.current=!1:i.onClose()}})),onPointerDown:t=>{var n;null===(n=e.onPointerDown)||void 0===n||n.call(e,t),l.current=!0},onPointerUp:et(e.onPointerUp,(e=>{var t;l.current||null===(t=e.currentTarget)||void 0===t||t.click()})),onKeyDown:et(e.onKeyDown,(e=>{const t=""!==s.searchRef.current;n||t&&" "===e.key||qS.includes(e.key)&&(e.currentTarget.click(),e.preventDefault())}))}))})),vN=v.forwardRef(((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...a}=e,i=w$(GS,n),s=pN(n),u=v.useRef(null),l=Vt(t,u),[c,d]=v.useState(!1),[f,p]=v.useState("");return v.useEffect((()=>{const e=u.current;var t;e&&p((null!==(t=e.textContent)&&void 0!==t?t:"").trim())}),[a.children]),v.createElement(bv.ItemSlot,{scope:n,disabled:r,textValue:o??f},v.createElement(y$,Te({asChild:!0},s,{focusable:!r}),v.createElement(ft.div,Te({role:"menuitem","data-highlighted":c?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0},a,{ref:l,onPointerMove:et(e.onPointerMove,_v((e=>{r?i.onItemLeave(e):(i.onItemEnter(e),e.defaultPrevented||e.currentTarget.focus())}))),onPointerLeave:et(e.onPointerLeave,_v((e=>i.onItemLeave(e)))),onFocus:et(e.onFocus,(()=>d(!0))),onBlur:et(e.onBlur,(()=>d(!1)))}))))})),qV=v.forwardRef(((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return v.createElement(yN,{scope:e.__scopeMenu,checked:n},v.createElement(_$,Te({role:"menuitemcheckbox","aria-checked":ry(n)?"mixed":n},o,{ref:t,"data-state":x$(n),onSelect:et(o.onSelect,(()=>null==r?void 0:r(!!ry(n)||!n)),{checkForDefaultPrevented:!1})})))})),GV="MenuRadioGroup",[YJ,HV]=tp(GV,{value:void 0,onValueChange:()=>{}}),KV="MenuRadioItem",YV=v.forwardRef(((e,t)=>{const{value:n,...r}=e,o=HV(KV,e.__scopeMenu),a=n===o.value;return v.createElement(yN,{scope:e.__scopeMenu,checked:a},v.createElement(_$,Te({role:"menuitemradio","aria-checked":a},r,{ref:t,"data-state":x$(a),onSelect:et(r.onSelect,(()=>{var e;return null===(e=o.onValueChange)||void 0===e?void 0:e.call(o,n)}),{checkForDefaultPrevented:!1})})))})),gN="MenuItemIndicator",[yN,QV]=tp(gN,{checked:!1}),XV=v.forwardRef(((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,a=QV(gN,n);return v.createElement(ea,{present:r||ry(a.checked)||!0===a.checked},v.createElement(ft.span,Te({},o,{ref:t,"data-state":x$(a.checked)})))})),JV=v.forwardRef(((e,t)=>{const{__scopeMenu:n,...r}=e;return v.createElement(ft.div,Te({role:"separator","aria-orientation":"horizontal"},r,{ref:t}))})),ZV="MenuSub",[QJ,wN]=tp(ZV),Ag="MenuSubTrigger",eU=v.forwardRef(((e,t)=>{const n=np(Ag,e.__scopeMenu),r=Bv(Ag,e.__scopeMenu),o=wN(Ag,e.__scopeMenu),a=w$(Ag,e.__scopeMenu),i=v.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:u}=a,l={__scopeMenu:e.__scopeMenu},c=v.useCallback((()=>{i.current&&window.clearTimeout(i.current),i.current=null}),[]);return v.useEffect((()=>c),[c]),v.useEffect((()=>{const e=s.current;return()=>{window.clearTimeout(e),u(null)}}),[s,u]),v.createElement(LV,Te({asChild:!0},l),v.createElement(vN,Te({id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":bN(n.open)},e,{ref:bE(t,o.onTriggerChange),onClick:t=>{var r;null===(r=e.onClick)||void 0===r||r.call(e,t),!e.disabled&&!t.defaultPrevented&&(t.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:et(e.onPointerMove,_v((t=>{a.onItemEnter(t),!t.defaultPrevented&&!e.disabled&&!n.open&&!i.current&&(a.onPointerGraceIntentChange(null),i.current=window.setTimeout((()=>{n.onOpenChange(!0),c()}),100))}))),onPointerLeave:et(e.onPointerLeave,_v((e=>{var t;c();const r=null===(t=n.content)||void 0===t?void 0:t.getBoundingClientRect();if(r){var o;const t=null===(o=n.content)||void 0===o?void 0:o.dataset.side,i="right"===t,u=i?-5:5,l=r[i?"left":"right"],c=r[i?"right":"left"];a.onPointerGraceIntentChange({area:[{x:e.clientX+u,y:e.clientY},{x:l,y:r.top},{x:c,y:r.top},{x:c,y:r.bottom},{x:l,y:r.bottom}],side:t}),window.clearTimeout(s.current),s.current=window.setTimeout((()=>a.onPointerGraceIntentChange(null)),300)}else{if(a.onTriggerLeave(e),e.defaultPrevented)return;a.onPointerGraceIntentChange(null)}}))),onKeyDown:et(e.onKeyDown,(t=>{const o=""!==a.searchRef.current;var i;e.disabled||o&&" "===t.key||!MV[r.dir].includes(t.key)||(n.onOpenChange(!0),null===(i=n.content)||void 0===i||i.focus(),t.preventDefault())}))})))})),tU="MenuSubContent",nU=v.forwardRef(((e,t)=>{const n=hN(vs,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=np(vs,e.__scopeMenu),i=Bv(vs,e.__scopeMenu),s=wN(tU,e.__scopeMenu),u=v.useRef(null),l=Vt(t,u);return v.createElement(bv.Provider,{scope:e.__scopeMenu},v.createElement(ea,{present:r||a.open},v.createElement(bv.Slot,{scope:e.__scopeMenu},v.createElement(b$,Te({id:s.contentId,"aria-labelledby":s.triggerId},o,{ref:l,align:"start",side:"rtl"===i.dir?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:e=>{var t;i.isUsingKeyboardRef.current&&(null===(t=u.current)||void 0===t||t.focus()),e.preventDefault()},onCloseAutoFocus:e=>e.preventDefault(),onFocusOutside:et(e.onFocusOutside,(e=>{e.target!==s.trigger&&a.onOpenChange(!1)})),onEscapeKeyDown:et(e.onEscapeKeyDown,(e=>{i.onClose(),e.preventDefault()})),onKeyDown:et(e.onKeyDown,(e=>{const t=e.currentTarget.contains(e.target),n=DV[i.dir].includes(e.key);var r;t&&n&&(a.onOpenChange(!1),null===(r=s.trigger)||void 0===r||r.focus(),e.preventDefault())}))})))))}));function bN(e){return e?"open":"closed"}function ry(e){return"indeterminate"===e}function x$(e){return ry(e)?"indeterminate":e?"checked":"unchecked"}function rU(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function oU(e,t){return e.map(((n,r)=>e[(t+r)%e.length]))}function iU(e,t,n){const r=t.length>1&&Array.from(t).every((e=>e===t[0]))?t[0]:t,o=n?e.indexOf(n):-1;let a=oU(e,Math.max(o,0));1===r.length&&(a=a.filter((e=>e!==n)));const i=a.find((e=>e.toLowerCase().startsWith(r.toLowerCase())));return i!==n?i:void 0}function aU(e,t){const{x:n,y:r}=e;let o=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){const i=t[e].x,s=t[e].y,u=t[a].x,l=t[a].y;s>r!=l>r&&n<(u-i)*(r-s)/(l-s)+i&&(o=!o)}return o}function sU(e,t){if(!t)return!1;return aU({x:e.clientX,y:e.clientY},t)}function _v(e){return t=>"mouse"===t.pointerType?e(t):void 0}const uU=BV,lU=zV,cU=WV,dU=_$,fU=qV,pU=YV,mU=XV,hU=JV,vU=eU,gU=nU,_N="DropdownMenu",[yU,XJ]=ni(_N,[dN]),wu=dN(),[JJ,wU]=yU(_N),bU=e=>{const{__scopeDropdownMenu:t,...n}=e,r=wu(t);return v.createElement(uU,Te({},r,n))},_U="DropdownMenuContent",xU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wU(_U,n),a=wu(n),i=v.useRef(!1);return v.createElement(lU,Te({id:o.contentId,"aria-labelledby":o.triggerId},a,r,{ref:t,onCloseAutoFocus:et(e.onCloseAutoFocus,(e=>{var t;i.current||null===(t=o.triggerRef.current)||void 0===t||t.focus(),i.current=!1,e.preventDefault()})),onInteractOutside:et(e.onInteractOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey,r=2===t.button||n;(!o.modal||r)&&(i.current=!0)})),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))})),SU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(cU,Te({},o,r,{ref:t}))})),EU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(dU,Te({},o,r,{ref:t}))})),$U=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(fU,Te({},o,r,{ref:t}))})),CU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(pU,Te({},o,r,{ref:t}))})),IU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(mU,Te({},o,r,{ref:t}))})),RU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(hU,Te({},o,r,{ref:t}))})),PU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(vU,Te({},o,r,{ref:t}))})),TU=v.forwardRef(((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=wu(n);return v.createElement(gU,Te({},o,r,{ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))})),OU=bU,xN=xU,SN=SU,EN=EU,$N=$U,CN=CU,AU=IU,S$=RU,IN=PU,RN=TU,MU=v.forwardRef((({className:e,inset:t,children:n,...r},o)=>G.jsxs(IN,{ref:o,className:we("flex cursor-default select-none items-center rounded-xs px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent",t&&"pl-8",e),...r,children:[n,G.jsx(aA,{className:"ml-auto h-4 w-4"})]})));MU.displayName=IN.displayName;const DU=v.forwardRef((({className:e,...t},n)=>G.jsx(RN,{ref:n,className:we("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...t})));DU.displayName=RN.displayName;const UT=e=>{e.preventDefault()},NU=v.forwardRef((({className:e,sideOffset:t=4,isPortal:n,...r},o)=>{const a=G.jsx(xN,{ref:o,sideOffset:t,onOpenAutoFocus:UT,onCloseAutoFocus:UT,className:we("z-[101] flex max-h-[var(--radix-dropdown-menu-content-available-height)] min-w-[8rem] flex-col gap-xxxs overflow-y-auto rounded-lg border border-gray-200 bg-white p-xxs text-popover-foreground ","shadow-[0px_0px_12px_0px_rgba(0,0,0,0.08)] ","data-[state=open]:animate-in data-[state=closed]:animate-out","data-[state=open]:fade-in data-[state=open]:slide-in-from-top-2","data-[state=closed]:fade-out data-[state=closed]:slide-out-to-top-2","data-[state=closed]:duration-150 data-[state=open]:duration-150","data-[state=closed]:[animation-timing-function:ease-in] data-[state=open]:[animation-timing-function:ease-out]",e),...r});return n?G.jsx(OU,{children:a}):a}));NU.displayName=xN.displayName;const kU=v.forwardRef((({className:e,inset:t,...n},r)=>G.jsx(EN,{ref:r,className:we("relative flex cursor-default select-none items-center gap-xxs rounded-m p-xxs text-base font-medium text-gray-900 outline-none transition-colors hover:bg-gray-100 data-[disabled]:pointer-events-none data-[disabled]:opacity-50",t&&"pl-xl",e),...n})));kU.displayName=EN.displayName;const LU=v.forwardRef((({className:e,children:t,checked:n,checkboxPosition:r="right",...o},a)=>{const i=G.jsx(JE,{size:"default",variant:"default",checked:n});return G.jsxs($N,{ref:a,className:we("relative flex cursor-default select-none items-center gap-xxs rounded-m p-xxs text-base font-medium text-gray-900"," outline-none transition-colors hover:bg-gray-100 focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:n,onSelect:e=>e.preventDefault(),...o,children:["left"===r&&i,G.jsx("div",{className:"flex flex-1 items-center gap-xxs",children:t}),"right"===r&&i]})}));LU.displayName=$N.displayName;const FU=v.forwardRef((({className:e,children:t,radioPosition:n="right",...r},o)=>{const a=G.jsx("div",{className:"flex h-xxs items-center justify-center",children:G.jsx(AU,{children:G.jsx(vE,{size:20})})});return G.jsxs(CN,{ref:o,className:we("relative flex cursor-default select-none items-center gap-xxs rounded-m p-xxs text-base font-medium text-gray-900"," outline-none transition-colors hover:bg-gray-100 focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),onSelect:e=>e.preventDefault(),...r,children:["left"===n&&a,G.jsx("div",{className:"flex flex-1 items-center gap-xxs",children:t}),"right"===n&&a]})}));FU.displayName=CN.displayName;const BU=v.forwardRef((({className:e,inset:t,...n},r)=>G.jsx(SN,{ref:r,className:we("text-sm font-semibold",t&&"pl-xl",e),...n})));BU.displayName=SN.displayName;const jU=v.forwardRef((({className:e,...t},n)=>G.jsx(S$,{ref:n,className:we("-mx-1 my-1 h-px bg-muted",e),...t})));jU.displayName=S$.displayName;const zU=Ue.createContext(null),VU=()=>Ue.useContext(zU),UU=v.forwardRef(((e,t)=>v.createElement(ft.label,Te({},e,{ref:t,onMouseDown:t=>{var n;null===(n=e.onMouseDown)||void 0===n||n.call(e,t),!t.defaultPrevented&&t.detail>1&&t.preventDefault()}})))),PN=UU,WU=gu("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),TN=v.forwardRef((({className:e,...t},n)=>G.jsx(PN,{ref:n,className:we(WU(),e),...t})));function WT(e,[t,n]){return Math.min(n,Math.max(t,e))}TN.displayName=PN.displayName;const ON=v.forwardRef(((e,t)=>v.createElement(ft.span,Te({},e,{ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}})))),qU=ON,GU=[" ","Enter","ArrowUp","ArrowDown"],HU=[" ","Enter"],qy="Select",[Gy,Hy,KU]=a$(qy),[Gm,ZJ]=ni(qy,[KU,Wm]),E$=Wm(),[YU,rp]=Gm(qy),[QU,XU]=Gm(qy),JU=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:a,value:i,defaultValue:s,onValueChange:u,dir:l,name:c,autoComplete:d,disabled:f,required:p}=e,m=E$(t),[h,g]=v.useState(null),[y,b]=v.useState(null),[w,x]=v.useState(!1),_=s$(l),[E=!1,S]=fd({prop:r,defaultProp:o,onChange:a}),[I,A]=fd({prop:i,defaultProp:s,onChange:u}),k=v.useRef(null),C=!h||!!h.closest("form"),[T,R]=v.useState(new Set),P=Array.from(T).map((e=>e.props.value)).join(";");return v.createElement(sN,m,v.createElement(YU,{required:p,scope:t,trigger:h,onTriggerChange:g,valueNode:y,onValueNodeChange:b,valueNodeHasChildren:w,onValueNodeHasChildrenChange:x,contentId:ad(),value:I,onValueChange:A,open:E,onOpenChange:S,dir:_,triggerPointerDownPosRef:k,disabled:f},v.createElement(Gy.Provider,{scope:t},v.createElement(QU,{scope:e.__scopeSelect,onNativeOptionAdd:v.useCallback((e=>{R((t=>new Set(t).add(e)))}),[]),onNativeOptionRemove:v.useCallback((e=>{R((t=>{const n=new Set(t);return n.delete(e),n}))}),[])},n)),C?v.createElement(kN,{key:P,"aria-hidden":!0,required:p,tabIndex:-1,name:c,autoComplete:d,value:I,onChange:e=>A(e.target.value),disabled:f},void 0===I?v.createElement("option",{value:""}):null,Array.from(T)):null))},ZU="SelectTrigger",eW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,a=E$(n),i=rp(ZU,n),s=i.disabled||r,u=Vt(t,i.onTriggerChange),l=Hy(n),[c,d,f]=LN((e=>{const t=l().filter((e=>!e.disabled)),n=t.find((e=>e.value===i.value)),r=FN(t,e,n);void 0!==r&&i.onValueChange(r.value)})),p=()=>{s||(i.onOpenChange(!0),f())};return v.createElement(m$,Te({asChild:!0},a),v.createElement(ft.button,Te({type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:s,"data-disabled":s?"":void 0,"data-placeholder":NN(i.value)?"":void 0},o,{ref:u,onClick:et(o.onClick,(e=>{e.currentTarget.focus()})),onPointerDown:et(o.onPointerDown,(e=>{const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),0===e.button&&!1===e.ctrlKey&&(p(),i.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)},e.preventDefault())})),onKeyDown:et(o.onKeyDown,(e=>{const t=""!==c.current;!(e.ctrlKey||e.altKey||e.metaKey)&&1===e.key.length&&d(e.key),(!t||" "!==e.key)&&GU.includes(e.key)&&(p(),e.preventDefault())}))})))})),tW="SelectValue",nW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:a,placeholder:i="",...s}=e,u=rp(tW,n),{onValueNodeHasChildrenChange:l}=u,c=void 0!==a,d=Vt(t,u.onValueNodeChange);return Vo((()=>{l(c)}),[l,c]),v.createElement(ft.span,Te({},s,{ref:d,style:{pointerEvents:"none"}}),NN(u.value)?v.createElement(v.Fragment,null,i):a)})),rW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return v.createElement(ft.span,Te({"aria-hidden":!0},o,{ref:t}),r||"▼")})),oW=e=>v.createElement(by,Te({asChild:!0},e)),km="SelectContent",iW=v.forwardRef(((e,t)=>{const n=rp(km,e.__scopeSelect),[r,o]=v.useState();if(Vo((()=>{o(new DocumentFragment)}),[]),!n.open){const t=r;return t?vu.createPortal(v.createElement(AN,{scope:e.__scopeSelect},v.createElement(Gy.Slot,{scope:e.__scopeSelect},v.createElement("div",null,e.children))),t):null}return v.createElement(aW,Te({},e,{ref:t}))})),bl=10,[AN,op]=Gm(km),aW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:a,onPointerDownOutside:i,side:s,sideOffset:u,align:l,alignOffset:c,arrowPadding:d,collisionBoundary:f,collisionPadding:p,sticky:m,hideWhenDetached:h,avoidCollisions:g,...y}=e,b=rp(km,n),[w,x]=v.useState(null),[_,E]=v.useState(null),S=Vt(t,(e=>x(e))),[I,A]=v.useState(null),[k,C]=v.useState(null),T=Hy(n),[R,P]=v.useState(!1),O=v.useRef(!1);v.useEffect((()=>{if(w)return Sy(w)}),[w]),SE();const N=v.useCallback((e=>{const[t,...n]=T().map((e=>e.ref.current)),[r]=n.slice(-1),o=document.activeElement;for(const n of e)if(n===o||(null==n||n.scrollIntoView({block:"nearest"}),n===t&&_&&(_.scrollTop=0),n===r&&_&&(_.scrollTop=_.scrollHeight),null==n||n.focus(),document.activeElement!==o))return}),[T,_]),M=v.useCallback((()=>N([I,w])),[N,I,w]);v.useEffect((()=>{R&&M()}),[R,M]);const{onOpenChange:j,triggerPointerDownPosRef:D}=b;v.useEffect((()=>{if(w){let e={x:0,y:0};const t=t=>{var n,r,o,a;e={x:Math.abs(Math.round(t.pageX)-(null!==(n=null===(r=D.current)||void 0===r?void 0:r.x)&&void 0!==n?n:0)),y:Math.abs(Math.round(t.pageY)-(null!==(o=null===(a=D.current)||void 0===a?void 0:a.y)&&void 0!==o?o:0))}},n=n=>{e.x<=10&&e.y<=10?n.preventDefault():w.contains(n.target)||j(!1),document.removeEventListener("pointermove",t),D.current=null};return null!==D.current&&(document.addEventListener("pointermove",t),document.addEventListener("pointerup",n,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerup",n,{capture:!0})}}}),[w,j,D]),v.useEffect((()=>{const e=()=>j(!1);return window.addEventListener("blur",e),window.addEventListener("resize",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("resize",e)}}),[j]);const[q,z]=LN((e=>{const t=T().filter((e=>!e.disabled)),n=t.find((e=>e.ref.current===document.activeElement)),r=FN(t,e,n);r&&setTimeout((()=>r.ref.current.focus()))})),L=v.useCallback(((e,t,n)=>{const r=!O.current&&!n;(void 0!==b.value&&b.value===t||r)&&(A(e),r&&(O.current=!0))}),[b.value]),$=v.useCallback((()=>null==w?void 0:w.focus()),[w]),V=v.useCallback(((e,t,n)=>{const r=!O.current&&!n;(void 0!==b.value&&b.value===t||r)&&C(e)}),[b.value]),B="popper"===r?qT:sW,F=B===qT?{side:s,sideOffset:u,align:l,alignOffset:c,arrowPadding:d,collisionBoundary:f,collisionPadding:p,sticky:m,hideWhenDetached:h,avoidCollisions:g}:{};return v.createElement(AN,{scope:n,content:w,viewport:_,onViewportChange:E,itemRefCallback:L,selectedItem:I,onItemLeave:$,itemTextRefCallback:V,focusSelectedItem:M,selectedItemText:k,position:r,isPositioned:R,searchRef:q},v.createElement(xy,{as:qf,allowPinchZoom:!0},v.createElement(xE,{asChild:!0,trapped:b.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:et(o,(e=>{var t;null===(t=b.trigger)||void 0===t||t.focus({preventScroll:!0}),e.preventDefault()}))},v.createElement(wy,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>b.onOpenChange(!1)},v.createElement(B,Te({role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:e=>e.preventDefault()},y,F,{onPlaced:()=>P(!0),ref:S,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:et(y.onKeyDown,(e=>{const t=e.ctrlKey||e.altKey||e.metaKey;if("Tab"===e.key&&e.preventDefault(),!t&&1===e.key.length&&z(e.key),["ArrowUp","ArrowDown","Home","End"].includes(e.key)){let t=T().filter((e=>!e.disabled)).map((e=>e.ref.current));if(["ArrowUp","End"].includes(e.key)&&(t=t.slice().reverse()),["ArrowUp","ArrowDown"].includes(e.key)){const n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout((()=>N(t))),e.preventDefault()}}))}))))))})),sW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,a=rp(km,n),i=op(km,n),[s,u]=v.useState(null),[l,c]=v.useState(null),d=Vt(t,(e=>c(e))),f=Hy(n),p=v.useRef(!1),m=v.useRef(!0),{viewport:h,selectedItem:g,selectedItemText:y,focusSelectedItem:b}=i,w=v.useCallback((()=>{if(a.trigger&&a.valueNode&&s&&l&&h&&g&&y){const e=a.trigger.getBoundingClientRect(),t=l.getBoundingClientRect(),n=a.valueNode.getBoundingClientRect(),o=y.getBoundingClientRect();if("rtl"!==a.dir){const r=o.left-t.left,a=n.left-r,i=e.left-a,u=e.width+i,l=Math.max(u,t.width),c=window.innerWidth-bl,d=WT(a,[bl,c-l]);s.style.minWidth=u+"px",s.style.left=d+"px"}else{const r=t.right-o.right,a=window.innerWidth-n.right-r,i=window.innerWidth-e.right-a,u=e.width+i,l=Math.max(u,t.width),c=window.innerWidth-bl,d=WT(a,[bl,c-l]);s.style.minWidth=u+"px",s.style.right=d+"px"}const i=f(),u=window.innerHeight-2*bl,c=h.scrollHeight,d=window.getComputedStyle(l),m=parseInt(d.borderTopWidth,10),v=parseInt(d.paddingTop,10),b=parseInt(d.borderBottomWidth,10),w=m+v+c+parseInt(d.paddingBottom,10)+b,x=Math.min(5*g.offsetHeight,w),_=window.getComputedStyle(h),E=parseInt(_.paddingTop,10),S=parseInt(_.paddingBottom,10),I=e.top+e.height/2-bl,A=u-I,k=g.offsetHeight/2,C=m+v+(g.offsetTop+k),T=w-C;if(C<=I){const e=g===i[i.length-1].ref.current;s.style.bottom="0px";const t=l.clientHeight-h.offsetTop-h.offsetHeight,n=C+Math.max(A,k+(e?S:0)+t+b);s.style.height=n+"px"}else{const e=g===i[0].ref.current;s.style.top="0px";const t=Math.max(I,m+h.offsetTop+(e?E:0)+k)+T;s.style.height=t+"px",h.scrollTop=C-I+h.offsetTop}s.style.margin=`${bl}px 0`,s.style.minHeight=x+"px",s.style.maxHeight=u+"px",null==r||r(),requestAnimationFrame((()=>p.current=!0))}}),[f,a.trigger,a.valueNode,s,l,h,g,y,a.dir,r]);Vo((()=>w()),[w]);const[x,_]=v.useState();Vo((()=>{l&&_(window.getComputedStyle(l).zIndex)}),[l]);const E=v.useCallback((e=>{e&&!0===m.current&&(w(),null==b||b(),m.current=!1)}),[w,b]);return v.createElement(uW,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:p,onScrollButtonChange:E},v.createElement("div",{ref:u,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:x}},v.createElement(ft.div,Te({},o,{ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}}))))})),qT=v.forwardRef(((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=bl,...a}=e,i=E$(n);return v.createElement(h$,Te({},i,a,{ref:t,align:r,collisionPadding:o,style:{boxSizing:"border-box",...a.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}}))})),[uW,$$]=Gm(km,{}),GT="SelectViewport",lW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,o=op(GT,n),a=$$(GT,n),i=Vt(t,o.onViewportChange),s=v.useRef(0);return v.createElement(v.Fragment,null,v.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"}}),v.createElement(Gy.Slot,{scope:n},v.createElement(ft.div,Te({"data-radix-select-viewport":"",role:"presentation"},r,{ref:i,style:{position:"relative",flex:1,overflow:"auto",...r.style},onScroll:et(r.onScroll,(e=>{const t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=a;if(null!=r&&r.current&&n){const e=Math.abs(s.current-t.scrollTop);if(e>0){const r=window.innerHeight-2*bl,o=parseFloat(n.style.minHeight),a=parseFloat(n.style.height),i=Math.max(o,a);if(i<r){const o=i+e,a=Math.min(r,o),s=o-a;n.style.height=a+"px","0px"===n.style.bottom&&(t.scrollTop=s>0?s:0,n.style.justifyContent="flex-end")}}}s.current=t.scrollTop}))}))))})),cW="SelectGroup",[dW,fW]=Gm(cW),pW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,o=ad();return v.createElement(dW,{scope:n,id:o},v.createElement(ft.div,Te({role:"group","aria-labelledby":o},r,{ref:t})))})),mW="SelectLabel",hW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,o=fW(mW,n);return v.createElement(ft.div,Te({id:o.id},r,{ref:t}))})),HS="SelectItem",[vW,MN]=Gm(HS),gW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:a,...i}=e,s=rp(HS,n),u=op(HS,n),l=s.value===r,[c,d]=v.useState(a??""),[f,p]=v.useState(!1),m=Vt(t,(e=>{var t;return null===(t=u.itemRefCallback)||void 0===t?void 0:t.call(u,e,r,o)})),h=ad(),g=()=>{o||(s.onValueChange(r),s.onOpenChange(!1))};if(""===r)throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return v.createElement(vW,{scope:n,value:r,disabled:o,textId:h,isSelected:l,onItemTextChange:v.useCallback((e=>{d((t=>{var n;return t||(null!==(n=null==e?void 0:e.textContent)&&void 0!==n?n:"").trim()}))}),[])},v.createElement(Gy.ItemSlot,{scope:n,value:r,disabled:o,textValue:c},v.createElement(ft.div,Te({role:"option","aria-labelledby":h,"data-highlighted":f?"":void 0,"aria-selected":l&&f,"data-state":l?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1},i,{ref:m,onFocus:et(i.onFocus,(()=>p(!0))),onBlur:et(i.onBlur,(()=>p(!1))),onPointerUp:et(i.onPointerUp,g),onPointerMove:et(i.onPointerMove,(e=>{var t;o?null===(t=u.onItemLeave)||void 0===t||t.call(u):e.currentTarget.focus({preventScroll:!0})})),onPointerLeave:et(i.onPointerLeave,(e=>{var t;e.currentTarget===document.activeElement&&(null===(t=u.onItemLeave)||void 0===t||t.call(u))})),onKeyDown:et(i.onKeyDown,(e=>{var t;""!==(null===(t=u.searchRef)||void 0===t?void 0:t.current)&&" "===e.key||(HU.includes(e.key)&&g()," "===e.key&&e.preventDefault())}))}))))})),Mg="SelectItemText",yW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,className:r,style:o,...a}=e,i=rp(Mg,n),s=op(Mg,n),u=MN(Mg,n),l=XU(Mg,n),[c,d]=v.useState(null),f=Vt(t,(e=>d(e)),u.onItemTextChange,(e=>{var t;return null===(t=s.itemTextRefCallback)||void 0===t?void 0:t.call(s,e,u.value,u.disabled)})),p=null==c?void 0:c.textContent,m=v.useMemo((()=>v.createElement("option",{key:u.value,value:u.value,disabled:u.disabled},p)),[u.disabled,u.value,p]),{onNativeOptionAdd:h,onNativeOptionRemove:g}=l;return Vo((()=>(h(m),()=>g(m))),[h,g,m]),v.createElement(v.Fragment,null,v.createElement(ft.span,Te({id:u.textId},a,{ref:f})),u.isSelected&&i.valueNode&&!i.valueNodeHasChildren?vu.createPortal(a.children,i.valueNode):null)})),wW="SelectItemIndicator",bW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e;return MN(wW,n).isSelected?v.createElement(ft.span,Te({"aria-hidden":!0},r,{ref:t})):null})),HT="SelectScrollUpButton",_W=v.forwardRef(((e,t)=>{const n=op(HT,e.__scopeSelect),r=$$(HT,e.__scopeSelect),[o,a]=v.useState(!1),i=Vt(t,r.onScrollButtonChange);return Vo((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollTop>0;a(e)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),o?v.createElement(DN,Te({},e,{ref:i,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop-t.offsetHeight)}})):null})),KT="SelectScrollDownButton",xW=v.forwardRef(((e,t)=>{const n=op(KT,e.__scopeSelect),r=$$(KT,e.__scopeSelect),[o,a]=v.useState(!1),i=Vt(t,r.onScrollButtonChange);return Vo((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollHeight-t.clientHeight,n=Math.ceil(t.scrollTop)<e;a(n)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),o?v.createElement(DN,Te({},e,{ref:i,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop+t.offsetHeight)}})):null})),DN=v.forwardRef(((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,a=op("SelectScrollButton",n),i=v.useRef(null),s=Hy(n),u=v.useCallback((()=>{null!==i.current&&(window.clearInterval(i.current),i.current=null)}),[]);return v.useEffect((()=>()=>u()),[u]),Vo((()=>{var e;const t=s().find((e=>e.ref.current===document.activeElement));null==t||null===(e=t.ref.current)||void 0===e||e.scrollIntoView({block:"nearest"})}),[s]),v.createElement(ft.div,Te({"aria-hidden":!0},o,{ref:t,style:{flexShrink:0,...o.style},onPointerDown:et(o.onPointerDown,(()=>{null===i.current&&(i.current=window.setInterval(r,50))})),onPointerMove:et(o.onPointerMove,(()=>{var e;null===(e=a.onItemLeave)||void 0===e||e.call(a),null===i.current&&(i.current=window.setInterval(r,50))})),onPointerLeave:et(o.onPointerLeave,(()=>{u()}))}))})),SW=v.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e;return v.createElement(ft.div,Te({"aria-hidden":!0},r,{ref:t}))}));function NN(e){return""===e||void 0===e}const kN=v.forwardRef(((e,t)=>{const{value:n,...r}=e,o=v.useRef(null),a=Vt(t,o),i=ky(n);return v.useEffect((()=>{const e=o.current,t=window.HTMLSelectElement.prototype,r=Object.getOwnPropertyDescriptor(t,"value").set;if(i!==n&&r){const t=new Event("change",{bubbles:!0});r.call(e,n),e.dispatchEvent(t)}}),[i,n]),v.createElement(ON,{asChild:!0},v.createElement("select",Te({},r,{ref:a,defaultValue:n})))}));function LN(e){const t=ws(e),n=v.useRef(""),r=v.useRef(0),o=v.useCallback((e=>{const o=n.current+e;t(o),function e(t){n.current=t,window.clearTimeout(r.current),""!==t&&(r.current=window.setTimeout((()=>e("")),1e3))}(o)}),[t]),a=v.useCallback((()=>{n.current="",window.clearTimeout(r.current)}),[]);return v.useEffect((()=>()=>window.clearTimeout(r.current)),[]),[n,o,a]}function FN(e,t,n){const r=t.length>1&&Array.from(t).every((e=>e===t[0]))?t[0]:t,o=n?e.indexOf(n):-1;let a=EW(e,Math.max(o,0));1===r.length&&(a=a.filter((e=>e!==n)));const i=a.find((e=>e.textValue.toLowerCase().startsWith(r.toLowerCase())));return i!==n?i:void 0}function EW(e,t){return e.map(((n,r)=>e[(t+r)%e.length]))}kN.displayName="BubbleSelect";const BN=JU,C$=eW,jN=nW,$W=rW,CW=oW,zN=iW,IW=lW,VN=pW,UN=hW,WN=gW,RW=yW,PW=bW,qN=_W,GN=xW,HN=SW,TW=BN,I$=v.forwardRef((({...e},t)=>G.jsx(TW,{ref:t,...e})));I$.displayName=BN.displayName;const KN=v.forwardRef(((e,t)=>G.jsx(VN,{ref:t,...e})));KN.displayName=VN.displayName;const YN=v.forwardRef(((e,t)=>G.jsx(jN,{ref:t,...e})));YN.displayName=jN.displayName;const R$=v.forwardRef((({className:e,children:t,caption:n,error:r,icon:o,renderCaret:a,...i},s)=>{const u=a?a():G.jsx(oA,{size:20,className:"transition-transform duration-200 group-data-[state=open]/select:rotate-180"});return G.jsxs("div",{className:"w-full",children:[G.jsxs(C$,{ref:s,className:we("group/select flex h-l w-full items-center justify-between rounded-m border bg-background p-xxs text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus-visible:ring-gray-700 focus-visible:ring-offset-1 disabled:cursor-not-allowed disabled:opacity-50",r?"border-red-500":"border-input",e),...i,children:[G.jsxs("div",{className:we("flex w-full flex-1 items-center gap-xxs",{"max-w-[calc(100%-20px)]":u}),children:[o&&G.jsx("span",{className:we("text-muted-foreground",{"text-red-dark":r}),children:o}),t]}),G.jsx($W,{asChild:!0,children:u})]}),n||r?r?G.jsxs("div",{className:"mt-xxs flex items-center gap-xxxs text-sm text-red-600",children:[G.jsx(gE,{size:16}),r]}):G.jsxs("div",{className:"mt-xxs flex items-center gap-xxxs text-sm text-muted-foreground",children:[G.jsx(V5,{size:16}),n]}):null]})}));R$.displayName="SelectTriggerWrapper";const QN=v.forwardRef((({className:e,children:t,caption:n,error:r,icon:o,...a},i)=>G.jsx(R$,{ref:i,className:we("[&>span]:line-clamp-1 [&>span]:text-left",e),caption:n,error:r,icon:o,...a,children:t})));QN.displayName=C$.displayName;const P$=v.forwardRef((({className:e,children:t,position:n="popper",...r},o)=>{const a=v.useMemo((()=>{const e=t=>{var n,r;if(!t)return!1;if(Array.isArray(t))return t.some(e);if(v.isValidElement(t)){const o=null==(n=t.type)?void 0:n.displayName;return"SelectActions"===o||"SelectFooter"===o||e(null==(r=t.props)?void 0:r.children)}return!1};return e(t)}),[t]);return G.jsx(CW,{children:G.jsx(zN,{ref:o,className:we("z-[101] flex max-h-[var(--radix-select-content-available-height)] min-w-[8rem] flex-col rounded-lg border border-gray-200 bg-white text-popover-foreground","shadow-[0px_0px_12px_0px_rgba(0,0,0,0.08)]","data-[state=open]:animate-in data-[state=closed]:animate-out ","data-[state=open]:fade-in data-[state=open]:slide-in-from-top-2 ","data-[state=closed]:fade-out data-[state=closed]:slide-out-to-top-2 ","data-[state=closed]:duration-150 data-[state=open]:duration-150 ","data-[state=closed]:[animation-timing-function:ease-in] data-[state=open]:[animation-timing-function:ease-out]","popper"===n&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:n,...r,children:G.jsx(IW,{className:we("flex flex-col gap-xxxs overflow-y-auto px-xxs",{"py-xxs":!a},"popper"===n&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t})})})}));P$.displayName=zN.displayName;const XN=v.forwardRef((({className:e,...t},n)=>G.jsx(UN,{ref:n,className:we("text-sm font-medium text-gray-900",e),...t})));XN.displayName=UN.displayName;const JN=v.forwardRef((({className:e,showCheck:t=!0,checkPosition:n="right",children:r,...o},a)=>{const i=G.jsx(PW,{children:G.jsx(vE,{size:20})});return G.jsxs(WN,{ref:a,className:we("relative flex cursor-default select-none items-center gap-xxs rounded-m p-xxs","text-base font-medium text-gray-900 outline-none transition-colors hover:bg-gray-100","focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...o,children:[t&&"left"===n&&i,G.jsx("div",{className:"flex flex-1 items-center gap-xxs",children:G.jsx(RW,{children:r})}),t&&"right"===n&&i]})}));JN.displayName=WN.displayName;const ZN=v.forwardRef((({className:e,...t},n)=>G.jsx(HN,{ref:n,className:we("-mx-1 my-1 h-px bg-gray-200",e),...t})));ZN.displayName=HN.displayName;const OW=({selectedValues:e=[],onRemoveValue:t})=>{const n=v.useRef(null),[r,o]=v.useState(e.length);return v.useLayoutEffect((()=>{if(!n.current||0===e.length)return void o(e.length);const r=n.current.offsetWidth-60,a=document.createElement("div");Object.assign(a.style,{position:"absolute",visibility:"hidden",whiteSpace:"nowrap",display:"flex",gap:"4px",top:"-9999px",left:"-9999px"}),document.body.appendChild(a);let i=0,s=0;for(const n of e){const e=document.createElement("div");e.className="gap-xxxs p-xxs flex cursor-pointer items-center rounded-sm bg-gray-100 text-sm font-medium text-gray-900";const o=document.createElement("span");if(o.textContent="string"==typeof n?n:n.value,e.appendChild(o),"string"!=typeof n&&n.avatar){const t=document.createElement("div");t.className="w-6 h-6 rounded-full bg-gray-300 flex-shrink-0",e.insertBefore(t,o)}if(t){const t=document.createElement("button");t.innerHTML="×",t.className="ml-1 rounded-full outline-none",e.appendChild(t)}a.appendChild(e);const u=e.offsetWidth+4;if(!(i+u<=r))break;i+=u,s++}document.body.removeChild(a),o(Math.max(1,s))}),[e,t]),{containerRef:n,visibleCount:r}},ek=({hiddenCount:e,selectedValues:t=[],onRemoveValue:n})=>{const r=e=>{e.stopPropagation(),e.preventDefault()};return G.jsx("div",{onPointerDown:r,onMouseDown:r,onClick:r,children:G.jsxs(I$,{name:"hidden-chips-counter",children:[G.jsx(C$,{asChild:!0,children:G.jsx("div",{children:G.jsx(UM,{text:`+${e}`})})}),G.jsx(P$,{align:"end",className:"max-h-[250px] w-screen max-w-[300px] gap-xxxs overflow-y-auto",children:t.map((e=>{const t="string"==typeof e?e:e.value;return G.jsxs("div",{className:"flex justify-between p-xxs",onClick:e=>e.stopPropagation(),children:[G.jsx("span",{children:t}),G.jsx(gy,{size:16,className:"cursor-pointer",onClick:()=>null==n?void 0:n(t)})]},t)}))})]})})};ek.displayName="SelectHiddenChipsCounter";const AW=v.forwardRef(((e,t)=>{const{className:n,selectedValues:r=[],placeholder:o,onRemoveValue:a,icon:i,caption:s,error:u,...l}=e,{containerRef:c,visibleCount:d}=OW({selectedValues:r,onRemoveValue:a}),f=r.length-d;return G.jsx(R$,{ref:t,className:n,caption:s,error:u,icon:i,...l,children:G.jsx("div",{ref:c,className:"flex w-full flex-1 flex-nowrap overflow-hidden",children:0===r.length?G.jsx("span",{children:o||"Select options..."}):G.jsxs(AF,{children:[r.slice(0,d).map((e=>{const t="string"==typeof e?e:e.value;return G.jsx(UM,{avatarSrc:"string"==typeof e?void 0:e.avatar,text:t,onRemove:()=>null==a?void 0:a(t)},t)})),f>0&&G.jsx(ek,{hiddenCount:f,onRemoveValue:a,selectedValues:r})]})})})}));AW.displayName="SelectMultiTrigger";const MW=v.forwardRef((({value:e,isSelected:t=!1,isLoading:n=!1,checkboxPosition:r="right",onSelect:o,className:a,children:i,...s},u)=>{const l=n?G.jsx(sA,{size:24,className:"flex-shrink-0 animate-spin text-blue_100"}):G.jsx(JE,{size:"default",variant:"default",checked:t}),c=()=>{null==o||o(e)};return G.jsxs("div",{ref:u,className:we("relative flex cursor-pointer select-none items-center gap-xxs rounded-m","p-xxs text-base font-medium text-gray-900 outline-none transition-colors hover:bg-gray-100","focus:bg-accent focus:text-accent-foreground",{"pointer-events-none":n},a),onClick:c,role:"button",tabIndex:0,onKeyDown:e=>{("Enter"===e.key||" "===e.key)&&(e.preventDefault(),c())},...s,children:["left"===r&&l,G.jsx("div",{className:"flex flex-1 items-center gap-xxs",children:i}),"right"===r&&l]})}));MW.displayName="SelectCheckboxItem";const DW=v.forwardRef((({className:e,...t},n)=>G.jsx(qN,{ref:n,className:we("flex cursor-default items-center justify-center py-xxs",e),...t,children:G.jsx(k5,{size:16})})));DW.displayName=qN.displayName;const NW=v.forwardRef((({className:e,...t},n)=>G.jsx(GN,{ref:n,className:we("flex cursor-default items-center justify-center p-xxs",e),...t,children:G.jsx(oA,{size:16})})));NW.displayName=GN.displayName;const kW=v.forwardRef((({className:e,children:t,...n},r)=>G.jsx("div",{ref:r,className:we("sticky top-0 z-20 bg-white p-xxs",e),...n,children:t})));kW.displayName="SelectActions";const LW=v.forwardRef((({className:e,children:t,...n},r)=>G.jsx("div",{ref:r,className:we("sticky bottom-0 z-20 bg-white p-xxs",e),...n,children:t})));LW.displayName="SelectFooter";const FW=v.createContext({}),bd=()=>{const e=v.useContext(FW),t=v.useContext(tk),n=VU();e||console.error("useFormContext must be used within a FormProvider");const{getFieldState:r,formState:o}=n,a=r(e.name,o);if(!e)throw new Error("useFormField should be used within <FormField>");const{id:i}=t;return{id:i,name:e.name,formItemId:`${i}-form-item`,formDescriptionId:`${i}-form-item-description`,formMessageId:`${i}-form-item-message`,...a}},tk=v.createContext({}),BW=v.forwardRef((({className:e,...t},n)=>{const r=v.useId();return G.jsx(tk.Provider,{value:{id:r},children:G.jsx("div",{ref:n,className:we("mt-[8px]",e),...t})})}));BW.displayName="FormItem";const jW=v.forwardRef((({className:e,isRequired:t,...n},r)=>{const{formItemId:o}=bd();return G.jsxs(TN,{ref:r,className:we("mb-2 text-sm font-medium",e),htmlFor:o,...n,children:[t&&"*",n.children]})}));jW.displayName="FormLabel";const zW=v.forwardRef((({...e},t)=>{const{error:n,formItemId:r,formDescriptionId:o,formMessageId:a}=bd();return G.jsx(yd,{ref:t,id:r,"aria-describedby":n?`${o} ${a}`:`${o}`,"aria-invalid":!!n,...e})}));zW.displayName="FormControl";const VW=v.forwardRef((({className:e,...t},n)=>{const{formDescriptionId:r}=bd();return G.jsx("p",{ref:n,id:r,className:we("text-sm text-muted-foreground",e),...t})}));VW.displayName="FormDescription";const UW=v.forwardRef((({className:e,children:t,...n},r)=>{const{error:o,formMessageId:a}=bd(),i=o?String(null==o?void 0:o.message):t;return i?G.jsxs("p",{ref:r,id:a,className:we("flex items-start gap-1 pt-xxs text-sm text-red-dark",e),...n,children:[G.jsx(gE,{size:16,className:"text-red-dark"})," ",i]}):null}));UW.displayName="FormMessage";const WW=v.forwardRef((({...e},t)=>{const{name:n}=bd();return G.jsx(I$,{ref:t,name:n,...e})}));WW.displayName="FormSelect";const qW=v.forwardRef((({className:e,children:t,...n},r)=>{const{formItemId:o}=bd();return G.jsx(QN,{ref:r,id:o,className:e,...n,children:t})}));qW.displayName="FormSelectTrigger";const GW=v.forwardRef(((e,t)=>G.jsx(P$,{ref:t,...e})));GW.displayName="FormSelectContent";const HW=v.forwardRef(((e,t)=>G.jsx(JN,{ref:t,...e})));HW.displayName="FormSelectItem";const KW=v.forwardRef(((e,t)=>G.jsx(KN,{ref:t,...e})));KW.displayName="FormSelectGroup";const YW=v.forwardRef(((e,t)=>G.jsx(XN,{ref:t,...e})));YW.displayName="FormSelectLabel";const QW=v.forwardRef(((e,t)=>G.jsx(ZN,{ref:t,...e})));QW.displayName="FormSelectSeparator";const XW=v.forwardRef(((e,t)=>G.jsx(YN,{ref:t,...e})));function jf(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function nk(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>v.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return v.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const o=v.createContext(r),a=n.length;function i(t){const{scope:n,children:r,...i}=t,s=(null==n?void 0:n[e][a])||o,u=v.useMemo((()=>i),Object.values(i));return v.createElement(s.Provider,{value:u},r)}return n=[...n,r],i.displayName=t+"Provider",[i,function(n,i){const s=(null==i?void 0:i[e][a])||o,u=v.useContext(s);if(u)return u;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},JW(r,...t)]}function JW(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return v.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}function Ky(e){const t=v.useRef(e);return v.useEffect((()=>{t.current=e})),v.useMemo((()=>(...e)=>{var n;return null===(n=t.current)||void 0===n?void 0:n.call(t,...e)}),[])}function ZW(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function eq(...e){return t=>e.forEach((e=>ZW(e,t)))}function tq(...e){return v.useCallback(eq(...e),e)}function ip(e){return e.split("-")[0]}function jv(e){return e.split("-")[1]}function Hm(e){return["top","bottom"].includes(ip(e))?"x":"y"}function T$(e){return"y"===e?"height":"width"}function YT(e,t,n){let{reference:r,floating:o}=e;const a=r.x+r.width/2-o.width/2,i=r.y+r.height/2-o.height/2,s=Hm(t),u=T$(s),l=r[u]/2-o[u]/2,c="x"===s;let d;switch(ip(t)){case"top":d={x:a,y:r.y-o.height};break;case"bottom":d={x:a,y:r.y+r.height};break;case"right":d={x:r.x+r.width,y:i};break;case"left":d={x:r.x-o.width,y:i};break;default:d={x:r.x,y:r.y}}switch(jv(t)){case"start":d[s]-=l*(n&&c?-1:1);break;case"end":d[s]+=l*(n&&c?-1:1)}return d}XW.displayName="FormSelectValue";const nq=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:i}=n,s=await(null==i.isRTL?void 0:i.isRTL(t));let u=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:l,y:c}=YT(u,r,s),d=r,f={},p=0;for(let n=0;n<a.length;n++){const{name:m,fn:v}=a[n],{x:h,y:g,data:y,reset:b}=await v({x:l,y:c,initialPlacement:r,placement:d,strategy:o,middlewareData:f,rects:u,platform:i,elements:{reference:e,floating:t}});l=h??l,c=g??c,f={...f,[m]:{...f[m],...y}},b&&p<=50&&(p++,"object"==typeof b&&(b.placement&&(d=b.placement),b.rects&&(u=!0===b.rects?await i.getElementRects({reference:e,floating:t,strategy:o}):b.rects),({x:l,y:c}=YT(u,d,s))),n=-1)}return{x:l,y:c,placement:d,strategy:o,middlewareData:f}};function rk(e){return"number"!=typeof e?(t=e,{top:0,right:0,bottom:0,left:0,...t}):{top:e,right:e,bottom:e,left:e};var t}function oy(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}async function xv(e,t){var n;void 0===t&&(t={});const{x:r,y:o,platform:a,rects:i,elements:s,strategy:u}=e,{boundary:l="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=t,m=rk(p),v=s[f?"floating"===d?"reference":"floating":d],h=oy(await a.getClippingRect({element:null==(n=await(null==a.isElement?void 0:a.isElement(v)))||n?v:v.contextElement||await(null==a.getDocumentElement?void 0:a.getDocumentElement(s.floating)),boundary:l,rootBoundary:c,strategy:u})),g=oy(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({rect:"floating"===d?{...i.floating,x:r,y:o}:i.reference,offsetParent:await(null==a.getOffsetParent?void 0:a.getOffsetParent(s.floating)),strategy:u}):i[d]);return{top:h.top-g.top+m.top,bottom:g.bottom-h.bottom+m.bottom,left:h.left-g.left+m.left,right:g.right-h.right+m.right}}const rq=Math.min,Df=Math.max;function KS(e,t,n){return Df(e,rq(t,n))}const QT=e=>({name:"arrow",options:e,async fn(t){const{element:n,padding:r=0}=e??{},{x:o,y:a,placement:i,rects:s,platform:u}=t;if(null==n)return{};const l=rk(r),c={x:o,y:a},d=Hm(i),f=jv(i),p=T$(d),m=await u.getDimensions(n),v="y"===d?"top":"left",h="y"===d?"bottom":"right",g=s.reference[p]+s.reference[d]-c[d]-s.floating[p],y=c[d]-s.reference[d],b=await(null==u.getOffsetParent?void 0:u.getOffsetParent(n));let w=b?"y"===d?b.clientHeight||0:b.clientWidth||0:0;0===w&&(w=s.floating[p]);const x=g/2-y/2,_=l[v],E=w-m[p]-l[h],S=w/2-m[p]/2+x,I=KS(_,S,E),A=("start"===f?l[v]:l[h])>0&&S!==I&&s.reference[p]<=s.floating[p];return{[d]:c[d]-(A?S<_?_-S:E-S:0),data:{[d]:I,centerOffset:S-I}}}}),oq={left:"right",right:"left",bottom:"top",top:"bottom"};function iy(e){return e.replace(/left|right|bottom|top/g,(e=>oq[e]))}function iq(e,t,n){void 0===n&&(n=!1);const r=jv(e),o=Hm(e),a=T$(o);let i="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[a]>t.floating[a]&&(i=iy(i)),{main:i,cross:iy(i)}}const aq={start:"end",end:"start"};function XT(e){return e.replace(/start|end/g,(e=>aq[e]))}const ok=["top","right","bottom","left"];ok.reduce(((e,t)=>e.concat(t,t+"-start",t+"-end")),[]);const sq=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:o,rects:a,initialPlacement:i,platform:s,elements:u}=t,{mainAxis:l=!0,crossAxis:c=!0,fallbackPlacements:d,fallbackStrategy:f="bestFit",flipAlignment:p=!0,...m}=e,v=ip(r),h=[i,...d||(v!==i&&p?function(e){const t=iy(e);return[XT(e),t,XT(t)]}(i):[iy(i)])],g=await xv(t,m),y=[];let b=(null==(n=o.flip)?void 0:n.overflows)||[];if(l&&y.push(g[v]),c){const{main:e,cross:t}=iq(r,a,await(null==s.isRTL?void 0:s.isRTL(u.floating)));y.push(g[e],g[t])}if(b=[...b,{placement:r,overflows:y}],!y.every((e=>e<=0))){var w,x;const e=(null!=(w=null==(x=o.flip)?void 0:x.index)?w:0)+1,t=h[e];if(t)return{data:{index:e,overflows:b},reset:{placement:t}};let n="bottom";switch(f){case"bestFit":{var _;const e=null==(_=b.map((e=>[e,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:_[0].placement;e&&(n=e);break}case"initialPlacement":n=i}if(r!==n)return{reset:{placement:n}}}return{}}}};function JT(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ZT(e){return ok.some((t=>e[t]>=0))}const uq=function(e){let{strategy:t="referenceHidden",...n}=void 0===e?{}:e;return{name:"hide",async fn(e){const{rects:r}=e;switch(t){case"referenceHidden":{const t=JT(await xv(e,{...n,elementContext:"reference"}),r.reference);return{data:{referenceHiddenOffsets:t,referenceHidden:ZT(t)}}}case"escaped":{const t=JT(await xv(e,{...n,altBoundary:!0}),r.floating);return{data:{escapedOffsets:t,escaped:ZT(t)}}}default:return{}}}}},lq=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,o=await async function(e,t){const{placement:n,platform:r,elements:o}=e,a=await(null==r.isRTL?void 0:r.isRTL(o.floating)),i=ip(n),s=jv(n),u="x"===Hm(n),l=["left","top"].includes(i)?-1:1,c=a&&u?-1:1,d="function"==typeof t?t(e):t;let{mainAxis:f,crossAxis:p,alignmentAxis:m}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...d};return s&&"number"==typeof m&&(p="end"===s?-1*m:m),u?{x:p*c,y:f*l}:{x:f*l,y:p*c}}(t,e);return{x:n+o.x,y:r+o.y,data:o}}}};function ik(e){return"x"===e?"y":"x"}const cq=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:i=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...u}=e,l={x:n,y:r},c=await xv(t,u),d=Hm(ip(o)),f=ik(d);let p=l[d],m=l[f];if(a){const e="y"===d?"bottom":"right";p=KS(p+c["y"===d?"top":"left"],p,p-c[e])}if(i){const e="y"===f?"bottom":"right";m=KS(m+c["y"===f?"top":"left"],m,m-c[e])}const v=s.fn({...t,[d]:p,[f]:m});return{...v,data:{x:v.x-n,y:v.y-r}}}}},dq=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:i}=t,{offset:s=0,mainAxis:u=!0,crossAxis:l=!0}=e,c={x:n,y:r},d=Hm(o),f=ik(d);let p=c[d],m=c[f];const v="function"==typeof s?s({...a,placement:o}):s,h="number"==typeof v?{mainAxis:v,crossAxis:0}:{mainAxis:0,crossAxis:0,...v};if(u){const e="y"===d?"height":"width",t=a.reference[d]-a.floating[e]+h.mainAxis,n=a.reference[d]+a.reference[e]-h.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){var g,y,b,w;const e="y"===d?"width":"height",t=["top","left"].includes(ip(o)),n=a.reference[f]-a.floating[e]+(t&&null!=(g=null==(y=i.offset)?void 0:y[f])?g:0)+(t?0:h.crossAxis),r=a.reference[f]+a.reference[e]+(t?0:null!=(b=null==(w=i.offset)?void 0:w[f])?b:0)-(t?h.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[d]:p,[f]:m}}}},fq=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:a}=t,{apply:i,...s}=e,u=await xv(t,s),l=ip(n),c=jv(n);let d,f;"top"===l||"bottom"===l?(d=l,f=c===(await(null==o.isRTL?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(f=l,d="end"===c?"top":"bottom");const p=Df(u.left,0),m=Df(u.right,0),v=Df(u.top,0),h=Df(u.bottom,0),g={availableHeight:r.floating.height-(["left","right"].includes(n)?2*(0!==v||0!==h?v+h:Df(u.top,u.bottom)):u[d]),availableWidth:r.floating.width-(["top","bottom"].includes(n)?2*(0!==p||0!==m?p+m:Df(u.left,u.right)):u[f])},y=await o.getDimensions(a.floating);null==i||i({...t,...g});const b=await o.getDimensions(a.floating);return y.width!==b.width||y.height!==b.height?{reset:{rects:!0}}:{}}}};function ak(e){return e&&e.document&&e.location&&e.alert&&e.setInterval}function Pl(e){if(null==e)return window;if(!ak(e)){const t=e.ownerDocument;return t&&t.defaultView||window}return e}function zv(e){return Pl(e).getComputedStyle(e)}function _l(e){return ak(e)?"":e?(e.nodeName||"").toLowerCase():""}function sk(){const e=navigator.userAgentData;return null!=e&&e.brands?e.brands.map((e=>e.brand+"/"+e.version)).join(" "):navigator.userAgent}function hu(e){return e instanceof Pl(e).HTMLElement}function gd(e){return e instanceof Pl(e).Element}function O$(e){return!(typeof ShadowRoot>"u")&&(e instanceof Pl(e).ShadowRoot||e instanceof ShadowRoot)}function Yy(e){const{overflow:t,overflowX:n,overflowY:r}=zv(e);return/auto|scroll|overlay|hidden/.test(t+r+n)}function pq(e){return["table","td","th"].includes(_l(e))}function e2(e){const t=/firefox/i.test(sk()),n=zv(e);return"none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||["transform","perspective"].includes(n.willChange)||t&&"filter"===n.willChange||t&&!!n.filter&&"none"!==n.filter}function uk(){return!/^((?!chrome|android).)*safari/i.test(sk())}const t2=Math.min,sv=Math.max,ay=Math.round;function xl(e,t,n){var r,o,a,i;void 0===t&&(t=!1),void 0===n&&(n=!1);const s=e.getBoundingClientRect();let u=1,l=1;t&&hu(e)&&(u=e.offsetWidth>0&&ay(s.width)/e.offsetWidth||1,l=e.offsetHeight>0&&ay(s.height)/e.offsetHeight||1);const c=gd(e)?Pl(e):window,d=!uk()&&n,f=(s.left+(d&&null!=(r=null==(o=c.visualViewport)?void 0:o.offsetLeft)?r:0))/u,p=(s.top+(d&&null!=(a=null==(i=c.visualViewport)?void 0:i.offsetTop)?a:0))/l,m=s.width/u,v=s.height/l;return{width:m,height:v,top:p,right:f+m,bottom:p+v,left:f,x:f,y:p}}function ud(e){return(t=e,(t instanceof Pl(t).Node?e.ownerDocument:e.document)||window.document).documentElement;var t}function Qy(e){return gd(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function lk(e){return xl(ud(e)).left+Qy(e).scrollLeft}function mq(e,t,n){const r=hu(t),o=ud(t),a=xl(e,r&&function(e){const t=xl(e);return ay(t.width)!==e.offsetWidth||ay(t.height)!==e.offsetHeight}(t),"fixed"===n);let i={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if(r||!r&&"fixed"!==n)if(("body"!==_l(t)||Yy(o))&&(i=Qy(t)),hu(t)){const e=xl(t,!0);s.x=e.x+t.clientLeft,s.y=e.y+t.clientTop}else o&&(s.x=lk(o));return{x:a.left+i.scrollLeft-s.x,y:a.top+i.scrollTop-s.y,width:a.width,height:a.height}}function ck(e){return"html"===_l(e)?e:e.assignedSlot||e.parentNode||(O$(e)?e.host:null)||ud(e)}function n2(e){return hu(e)&&"fixed"!==getComputedStyle(e).position?e.offsetParent:null}function YS(e){const t=Pl(e);let n=n2(e);for(;n&&pq(n)&&"static"===getComputedStyle(n).position;)n=n2(n);return n&&("html"===_l(n)||"body"===_l(n)&&"static"===getComputedStyle(n).position&&!e2(n))?t:n||function(e){let t=ck(e);for(O$(t)&&(t=t.host);hu(t)&&!["html","body"].includes(_l(t));){if(e2(t))return t;t=t.parentNode}return null}(e)||t}function r2(e){if(hu(e))return{width:e.offsetWidth,height:e.offsetHeight};const t=xl(e);return{width:t.width,height:t.height}}function dk(e){const t=ck(e);return["html","body","#document"].includes(_l(t))?e.ownerDocument.body:hu(t)&&Yy(t)?t:dk(t)}function sy(e,t){var n;void 0===t&&(t=[]);const r=dk(e),o=r===(null==(n=e.ownerDocument)?void 0:n.body),a=Pl(r),i=o?[a].concat(a.visualViewport||[],Yy(r)?r:[]):r,s=t.concat(i);return o?s:s.concat(sy(i))}function o2(e,t,n){return"viewport"===t?oy(function(e,t){const n=Pl(e),r=ud(e),o=n.visualViewport;let a=r.clientWidth,i=r.clientHeight,s=0,u=0;if(o){a=o.width,i=o.height;const e=uk();(e||!e&&"fixed"===t)&&(s=o.offsetLeft,u=o.offsetTop)}return{width:a,height:i,x:s,y:u}}(e,n)):gd(t)?function(e,t){const n=xl(e,!1,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft;return{top:r,left:o,x:o,y:r,right:o+e.clientWidth,bottom:r+e.clientHeight,width:e.clientWidth,height:e.clientHeight}}(t,n):oy(function(e){var t;const n=ud(e),r=Qy(e),o=null==(t=e.ownerDocument)?void 0:t.body,a=sv(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=sv(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0);let s=-r.scrollLeft+lk(e);const u=-r.scrollTop;return"rtl"===zv(o||n).direction&&(s+=sv(n.clientWidth,o?o.clientWidth:0)-a),{width:a,height:i,x:s,y:u}}(ud(e)))}function hq(e){const t=sy(e),n=["absolute","fixed"].includes(zv(e).position)&&hu(e)?YS(e):e;return gd(n)?t.filter((e=>gd(e)&&function(e,t){const n=null==t.getRootNode?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&O$(n)){let n=t;do{if(n&&e===n)return!0;n=n.parentNode||n.host}while(n)}return!1}(e,n)&&"body"!==_l(e))):[]}const vq={getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[..."clippingAncestors"===n?hq(t):[].concat(n),r],i=a[0],s=a.reduce(((e,n)=>{const r=o2(t,n,o);return e.top=sv(r.top,e.top),e.right=t2(r.right,e.right),e.bottom=t2(r.bottom,e.bottom),e.left=sv(r.left,e.left),e}),o2(t,i,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=hu(n),a=ud(n);if(n===a)return t;let i={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if((o||!o&&"fixed"!==r)&&(("body"!==_l(n)||Yy(a))&&(i=Qy(n)),hu(n))){const e=xl(n,!0);s.x=e.x+n.clientLeft,s.y=e.y+n.clientTop}return{...t,x:t.x-i.scrollLeft+s.x,y:t.y-i.scrollTop+s.y}},isElement:gd,getDimensions:r2,getOffsetParent:YS,getDocumentElement:ud,getElementRects:e=>{let{reference:t,floating:n,strategy:r}=e;return{reference:mq(t,YS(n),r),floating:{...r2(n),x:0,y:0}}},getClientRects:e=>Array.from(e.getClientRects()),isRTL:e=>"rtl"===zv(e).direction};function gq(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:i=!0,animationFrame:s=!1}=r,u=o&&!s,l=a&&!s,c=u||l?[...gd(e)?sy(e):[],...sy(t)]:[];c.forEach((e=>{u&&e.addEventListener("scroll",n,{passive:!0}),l&&e.addEventListener("resize",n)}));let d,f=null;if(i){let r=!0;f=new ResizeObserver((()=>{r||n(),r=!1})),gd(e)&&!s&&f.observe(e),f.observe(t)}let p=s?xl(e):null;return s&&function t(){const r=xl(e);!p||r.x===p.x&&r.y===p.y&&r.width===p.width&&r.height===p.height||n(),p=r,d=requestAnimationFrame(t)}(),n(),()=>{var e;c.forEach((e=>{u&&e.removeEventListener("scroll",n),l&&e.removeEventListener("resize",n)})),null==(e=f)||e.disconnect(),f=null,s&&cancelAnimationFrame(d)}}const yq=(e,t,n)=>nq(e,t,{platform:vq,...n});var QS=typeof document<"u"?v.useLayoutEffect:v.useEffect;function XS(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;0!=r--;)if(!XS(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!Object.prototype.hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){const n=o[r];if(!("_owner"===n&&e.$$typeof||XS(e[n],t[n])))return!1}return!0}return e!=e&&t!=t}function wq(e){const t=v.useRef(e);return QS((()=>{t.current=e})),t}function bq(e){let{middleware:t,placement:n="bottom",strategy:r="absolute",whileElementsMounted:o}=void 0===e?{}:e;const a=v.useRef(null),i=v.useRef(null),s=wq(o),u=v.useRef(null),[l,c]=v.useState({x:null,y:null,strategy:r,placement:n,middlewareData:{}}),[d,f]=v.useState(t);XS(null==d?void 0:d.map((e=>{let{options:t}=e;return t})),null==t?void 0:t.map((e=>{let{options:t}=e;return t})))||f(t);const p=v.useCallback((()=>{!a.current||!i.current||yq(a.current,i.current,{middleware:d,placement:n,strategy:r}).then((e=>{m.current&&vu.flushSync((()=>{c(e)}))}))}),[d,n,r]);QS((()=>{m.current&&p()}),[p]);const m=v.useRef(!1);QS((()=>(m.current=!0,()=>{m.current=!1})),[]);const h=v.useCallback((()=>{if("function"==typeof u.current&&(u.current(),u.current=null),a.current&&i.current)if(s.current){const e=s.current(a.current,i.current,p);u.current=e}else p()}),[p,s]),g=v.useCallback((e=>{a.current=e,h()}),[h]),y=v.useCallback((e=>{i.current=e,h()}),[h]),b=v.useMemo((()=>({reference:a,floating:i})),[]);return v.useMemo((()=>({...l,update:p,refs:b,reference:g,floating:y})),[l,p,b,g,y])}const _q=e=>{const{element:t,padding:n}=e;return{name:"arrow",options:e,fn:e=>function(e){return Object.prototype.hasOwnProperty.call(e,"current")}(t)?null!=t.current?QT({element:t.current,padding:n}).fn(e):{}:t?QT({element:t,padding:n}).fn(e):{}}};function xq(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Sq(...e){return t=>e.forEach((e=>xq(e,t)))}const fk=v.forwardRef(((e,t)=>{const{children:n,...r}=e,o=v.Children.toArray(n),a=o.find($q);if(a){const e=a.props.children,n=o.map((t=>t===a?v.Children.count(e)>1?v.Children.only(null):v.isValidElement(e)?e.props.children:null:t));return v.createElement(JS,Te({},r,{ref:t}),v.isValidElement(e)?v.cloneElement(e,void 0,n):null)}return v.createElement(JS,Te({},r,{ref:t}),n)}));fk.displayName="Slot";const JS=v.forwardRef(((e,t)=>{const{children:n,...r}=e;return v.isValidElement(n)?v.cloneElement(n,{...Cq(r,n.props),ref:Sq(t,n.ref)}):v.Children.count(n)>1?v.Children.only(null):null}));JS.displayName="SlotClone";const Eq=({children:e})=>v.createElement(v.Fragment,null,e);function $q(e){return v.isValidElement(e)&&e.type===Eq}function Cq(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...e)=>{a(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...a}:"className"===r&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}const Iq=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],ZS=Iq.reduce(((e,t)=>{const n=v.forwardRef(((e,n)=>{const{asChild:r,...o}=e,a=r?fk:t;return v.useEffect((()=>{window[Symbol.for("radix-ui")]=!0}),[]),v.createElement(a,Te({},o,{ref:n}))}));return n.displayName=`Primitive.${t}`,{...e,[t]:n}}),{});function Rq(e,t){e&&vu.flushSync((()=>e.dispatchEvent(t)))}function Pq(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Tq(...e){return t=>e.forEach((e=>Pq(e,t)))}function Oq(...e){return v.useCallback(Tq(...e),e)}const Lf=null!=globalThis&&globalThis.document?v.useLayoutEffect:()=>{};function Aq(e){const[t,n]=v.useState(void 0);return Lf((()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const t=new ResizeObserver((t=>{if(!Array.isArray(t)||!t.length)return;const r=t[0];let o,a;if("borderBoxSize"in r){const e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;o=t.inlineSize,a=t.blockSize}else o=e.offsetWidth,a=e.offsetHeight;n({width:o,height:a})}));return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)}),[e]),t}const pk="Popper",[A$,mk]=nk(pk),[eZ,Mq]=A$(pk),uy="PopperContent",[Dq,tZ]=A$(uy),[Nq,kq]=A$(uy,{hasParent:!1,positionUpdateFns:new Set}),Lq=v.forwardRef(((e,t)=>{var n,r,o,a,i,s,u,l;const{__scopePopper:c,side:d="bottom",sideOffset:f=0,align:p="center",alignOffset:m=0,arrowPadding:h=0,collisionBoundary:g=[],collisionPadding:y=0,sticky:b="partial",hideWhenDetached:w=!1,avoidCollisions:x=!0,onPlaced:_,...E}=e,S=Mq(uy,c),[I,A]=v.useState(null),k=Oq(t,(e=>A(e))),[C,T]=v.useState(null),R=Aq(C),P=null!==(n=null==R?void 0:R.width)&&void 0!==n?n:0,O=null!==(r=null==R?void 0:R.height)&&void 0!==r?r:0,N=d+("center"!==p?"-"+p:""),M="number"==typeof y?y:{top:0,right:0,bottom:0,left:0,...y},j=Array.isArray(g)?g:[g],D=j.length>0,q={padding:M,boundary:j.filter(Bq),altBoundary:D},{reference:z,floating:L,strategy:$,x:V,y:B,placement:F,middlewareData:U,update:G}=bq({strategy:"fixed",placement:N,whileElementsMounted:gq,middleware:[jq(),lq({mainAxis:f+O,alignmentAxis:m}),x?cq({mainAxis:!0,crossAxis:!1,limiter:"partial"===b?dq():void 0,...q}):void 0,C?_q({element:C,padding:h}):void 0,x?sq({...q}):void 0,fq({...q,apply:({elements:e,availableWidth:t,availableHeight:n})=>{e.floating.style.setProperty("--radix-popper-available-width",`${t}px`),e.floating.style.setProperty("--radix-popper-available-height",`${n}px`)}}),zq({arrowWidth:P,arrowHeight:O}),w?uq({strategy:"referenceHidden"}):void 0].filter(Fq)});Lf((()=>{z(S.anchor)}),[z,S.anchor]);const W=null!==V&&null!==B,[H,Q]=hk(F),K=Ky(_);Lf((()=>{W&&(null==K||K())}),[W,K]);const Y=null===(o=U.arrow)||void 0===o?void 0:o.x,J=null===(a=U.arrow)||void 0===a?void 0:a.y,X=0!==(null===(i=U.arrow)||void 0===i?void 0:i.centerOffset),[Z,ee]=v.useState();Lf((()=>{I&&ee(window.getComputedStyle(I).zIndex)}),[I]);const{hasParent:te,positionUpdateFns:ne}=kq(uy,c),re=!te;v.useLayoutEffect((()=>{if(!re)return ne.add(G),()=>{ne.delete(G)}}),[re,ne,G]),Lf((()=>{re&&W&&Array.from(ne).reverse().forEach((e=>requestAnimationFrame(e)))}),[re,W,ne]);const oe={"data-side":H,"data-align":Q,...E,ref:k,style:{...E.style,animation:W?void 0:"none",opacity:null!==(s=U.hide)&&void 0!==s&&s.referenceHidden?0:void 0}};return v.createElement("div",{ref:L,"data-radix-popper-content-wrapper":"",style:{position:$,left:0,top:0,transform:W?`translate3d(${Math.round(V)}px, ${Math.round(B)}px, 0)`:"translate3d(0, -200%, 0)",minWidth:"max-content",zIndex:Z,"--radix-popper-transform-origin":[null===(u=U.transformOrigin)||void 0===u?void 0:u.x,null===(l=U.transformOrigin)||void 0===l?void 0:l.y].join(" ")},dir:e.dir},v.createElement(Dq,{scope:c,placedSide:H,onArrowChange:T,arrowX:Y,arrowY:J,shouldHideArrow:X},re?v.createElement(Nq,{scope:c,hasParent:!0,positionUpdateFns:ne},v.createElement(ZS.div,oe)):v.createElement(ZS.div,oe)))}));function Fq(e){return void 0!==e}function Bq(e){return null!==e}const jq=()=>({name:"anchorCssProperties",fn(e){const{rects:t,elements:n}=e,{width:r,height:o}=t.reference;return n.floating.style.setProperty("--radix-popper-anchor-width",`${r}px`),n.floating.style.setProperty("--radix-popper-anchor-height",`${o}px`),{}}}),zq=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,a,i;const{placement:s,rects:u,middlewareData:l}=t,c=0!==(null===(n=l.arrow)||void 0===n?void 0:n.centerOffset),d=c?0:e.arrowWidth,f=c?0:e.arrowHeight,[p,m]=hk(s),v={start:"0%",center:"50%",end:"100%"}[m],h=(null!==(r=null===(o=l.arrow)||void 0===o?void 0:o.x)&&void 0!==r?r:0)+d/2,g=(null!==(a=null===(i=l.arrow)||void 0===i?void 0:i.y)&&void 0!==a?a:0)+f/2;let y="",b="";return"bottom"===p?(y=c?v:`${h}px`,b=-f+"px"):"top"===p?(y=c?v:`${h}px`,b=`${u.floating.height+f}px`):"right"===p?(y=-f+"px",b=c?v:`${g}px`):"left"===p&&(y=`${u.floating.width+f}px`,b=c?v:`${g}px`),{data:{x:y,y:b}}}});function hk(e){const[t,n="center"]=e.split("-");return[t,n]}const Vq=Lq;function Uq(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Wq(...e){return t=>e.forEach((e=>Uq(e,t)))}function qq(...e){return v.useCallback(Wq(...e),e)}function Gq(e,t){return v.useReducer(((e,n)=>t[e][n]??e),e)}const vk=e=>{const{present:t,children:n}=e,r=Hq(t),o="function"==typeof n?n({present:r.isPresent}):v.Children.only(n),a=qq(r.ref,o.ref);return"function"==typeof n||r.isPresent?v.cloneElement(o,{ref:a}):null};function Hq(e){const[t,n]=v.useState(),r=v.useRef({}),o=v.useRef(e),a=v.useRef("none"),i=e?"mounted":"unmounted",[s,u]=Gq(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect((()=>{const e=Dg(r.current);a.current="mounted"===s?e:"none"}),[s]),Lf((()=>{const t=r.current,n=o.current;if(n!==e){const r=a.current,i=Dg(t);e?u("MOUNT"):"none"===i||"none"===(null==t?void 0:t.display)?u("UNMOUNT"):u(n&&r!==i?"ANIMATION_OUT":"UNMOUNT"),o.current=e}}),[e,u]),Lf((()=>{if(t){const e=e=>{const n=Dg(r.current).includes(e.animationName);e.target===t&&n&&vu.flushSync((()=>u("ANIMATION_END")))},n=e=>{e.target===t&&(a.current=Dg(r.current))};return t.addEventListener("animationstart",n),t.addEventListener("animationcancel",e),t.addEventListener("animationend",e),()=>{t.removeEventListener("animationstart",n),t.removeEventListener("animationcancel",e),t.removeEventListener("animationend",e)}}u("ANIMATION_END")}),[t,u]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:v.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}function Dg(e){return(null==e?void 0:e.animationName)||"none"}function Kq(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function Yq(...e){return t=>e.forEach((e=>Kq(e,t)))}function Qq(...e){return v.useCallback(Yq(...e),e)}function Xq(e,t=(null==globalThis?void 0:globalThis.document)){const n=Ky(e);v.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e),()=>t.removeEventListener("keydown",e)}),[n,t])}vk.displayName="Presence";const eE="dismissableLayer.update",Jq="dismissableLayer.pointerDownOutside",Zq="dismissableLayer.focusOutside";let i2;const eG=v.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),tG=v.forwardRef(((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:i,onInteractOutside:s,onDismiss:u,...l}=e,c=v.useContext(eG),[d,f]=v.useState(null),p=null!==(n=null==d?void 0:d.ownerDocument)&&void 0!==n?n:null==globalThis?void 0:globalThis.document,[,m]=v.useState({}),h=Qq(t,(e=>f(e))),g=Array.from(c.layers),[y]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),b=g.indexOf(y),w=d?g.indexOf(d):-1,x=c.layersWithOutsidePointerEventsDisabled.size>0,_=w>=b,E=nG((e=>{const t=e.target,n=[...c.branches].some((e=>e.contains(t)));!_||n||(null==a||a(e),null==s||s(e),e.defaultPrevented||null==u||u())}),p),S=rG((e=>{const t=e.target;[...c.branches].some((e=>e.contains(t)))||(null==i||i(e),null==s||s(e),e.defaultPrevented||null==u||u())}),p);return Xq((e=>{w===c.layers.size-1&&(null==o||o(e),!e.defaultPrevented&&u&&(e.preventDefault(),u()))}),p),v.useEffect((()=>{if(d)return r&&(0===c.layersWithOutsidePointerEventsDisabled.size&&(i2=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(d)),c.layers.add(d),a2(),()=>{r&&1===c.layersWithOutsidePointerEventsDisabled.size&&(p.body.style.pointerEvents=i2)}}),[d,p,r,c]),v.useEffect((()=>()=>{d&&(c.layers.delete(d),c.layersWithOutsidePointerEventsDisabled.delete(d),a2())}),[d,c]),v.useEffect((()=>{const e=()=>m({});return document.addEventListener(eE,e),()=>document.removeEventListener(eE,e)}),[]),v.createElement(ZS.div,Te({},l,{ref:h,style:{pointerEvents:x?_?"auto":"none":void 0,...e.style},onFocusCapture:jf(e.onFocusCapture,S.onFocusCapture),onBlurCapture:jf(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:jf(e.onPointerDownCapture,E.onPointerDownCapture)}))}));function nG(e,t=(null==globalThis?void 0:globalThis.document)){const n=Ky(e),r=v.useRef(!1),o=v.useRef((()=>{}));return v.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){gk(Jq,n,a,{discrete:!0})};const a={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",o.current),o.current=r,t.addEventListener("click",o.current,{once:!0})):r()}r.current=!1},a=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",e),t.removeEventListener("click",o.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}function rG(e,t=(null==globalThis?void 0:globalThis.document)){const n=Ky(e),r=v.useRef(!1);return v.useEffect((()=>{const e=e=>{e.target&&!r.current&&gk(Zq,n,{originalEvent:e},{discrete:!1})};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function a2(){const e=new CustomEvent(eE);document.dispatchEvent(e)}function gk(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Rq(o,a):o.dispatchEvent(a)}let xx;const yk="HoverCard",[wk,nZ]=nk(yk,[mk]),oG=mk(),[rZ,bk]=wk(yk),iG="HoverCardPortal",[oZ,aG]=wk(iG,{forceMount:void 0}),tE="HoverCardContent",sG=v.forwardRef(((e,t)=>{const n=aG(tE,e.__scopeHoverCard),{forceMount:r=n.forceMount,...o}=e,a=bk(tE,e.__scopeHoverCard);return v.createElement(vk,{present:r||a.open},v.createElement(uG,Te({"data-state":a.open?"open":"closed"},o,{onPointerEnter:jf(e.onPointerEnter,s2(a.onOpen)),onPointerLeave:jf(e.onPointerLeave,s2(a.onClose)),ref:t})))})),uG=v.forwardRef(((e,t)=>{const{__scopeHoverCard:n,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:i,...s}=e,u=bk(tE,n),l=oG(n),c=v.useRef(null),d=tq(t,c),[f,p]=v.useState(!1);return v.useEffect((()=>{if(f){const e=document.body;return xx=e.style.userSelect||e.style.webkitUserSelect,e.style.userSelect="none",e.style.webkitUserSelect="none",()=>{e.style.userSelect=xx,e.style.webkitUserSelect=xx}}}),[f]),v.useEffect((()=>{if(c.current){const e=()=>{p(!1),u.isPointerDownOnContentRef.current=!1,setTimeout((()=>{var e;""!==(null===(e=document.getSelection())||void 0===e?void 0:e.toString())&&(u.hasSelectionRef.current=!0)}))};return document.addEventListener("pointerup",e),()=>{document.removeEventListener("pointerup",e),u.hasSelectionRef.current=!1,u.isPointerDownOnContentRef.current=!1}}}),[u.isPointerDownOnContentRef,u.hasSelectionRef]),v.useEffect((()=>{c.current&&lG(c.current).forEach((e=>e.setAttribute("tabindex","-1")))})),v.createElement(tG,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:i,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:jf(a,(e=>{e.preventDefault()})),onDismiss:u.onDismiss},v.createElement(Vq,Te({},l,s,{onPointerDown:jf(s.onPointerDown,(e=>{e.currentTarget.contains(e.target)&&p(!0),u.hasSelectionRef.current=!1,u.isPointerDownOnContentRef.current=!0})),ref:d,style:{...s.style,userSelect:f?"text":void 0,WebkitUserSelect:f?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})))}));function s2(e){return t=>"touch"===t.pointerType?void 0:e()}function lG(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;n.nextNode();)t.push(n.currentNode);return t}const _k=sG,cG=v.forwardRef((({className:e,align:t="center",sideOffset:n=4,...r},o)=>G.jsx(_k,{ref:o,align:t,sideOffset:n,className:we("z-50 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...r})));cG.displayName=_k.displayName;const xk=v.forwardRef((({className:e,type:t,...n},r)=>{const{error:o}=bd();return G.jsx("input",{type:t,title:n.disabled?"Disabled":"",className:we("flex w-full rounded-m px-s py-3.5 text-base text-gray-900 outline outline-1 outline-input ring-offset-background transition-all duration-200 ease-in-out file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-base placeholder:text-gray-400 placeholder:text-muted-foreground focus-visible:bg-gray-50 focus-visible:text-gray-900 focus-visible:outline-2 focus-visible:outline-blue_120 enabled:hover:outline-2 enabled:hover:outline-gray-400 disabled:bg-transparent disabled:text-gray-300 disabled:outline-gray-200 disabled:ring-0 disabled:ring-transparent disabled:placeholder:text-gray-300",{"bg-red_30_17 outline-red-dark":!!o},e),ref:r,...n})}));function dG(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>v.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return v.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const o=v.createContext(r),a=n.length;n=[...n,r];const i=t=>{var n;const{scope:r,children:i,...s}=t,u=(null==(n=null==r?void 0:r[e])?void 0:n[a])||o,l=v.useMemo((()=>s),Object.values(s));return G.jsx(u.Provider,{value:l,children:i})};return i.displayName=t+"Provider",[i,function(n,i){var s;const u=(null==(s=null==i?void 0:i[e])?void 0:s[a])||o,l=v.useContext(u);if(l)return l;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},fG(r,...t)]}function fG(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return v.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}function u2(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function pG(...e){return t=>{let n=!1;const r=e.map((e=>{const r=u2(e,t);return!n&&"function"==typeof r&&(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():u2(e[t],null)}}}}function mG(e){const t=hG(e),n=v.forwardRef(((e,n)=>{const{children:r,...o}=e,a=v.Children.toArray(r),i=a.find(gG);if(i){const e=i.props.children,r=a.map((t=>t===i?v.Children.count(e)>1?v.Children.only(null):v.isValidElement(e)?e.props.children:null:t));return G.jsx(t,{...o,ref:n,children:v.isValidElement(e)?v.cloneElement(e,void 0,r):null})}return G.jsx(t,{...o,ref:n,children:r})}));return n.displayName=`${e}.Slot`,n}function hG(e){const t=v.forwardRef(((e,t)=>{const{children:n,...r}=e;if(v.isValidElement(n)){const e=wG(n),o=yG(r,n.props);return n.type!==v.Fragment&&(o.ref=t?pG(t,e):e),v.cloneElement(n,o)}return v.Children.count(n)>1?v.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}xk.displayName="Input";var vG=Symbol("radix.slottable");function gG(e){return v.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===vG}function yG(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...e)=>{const t=a(...e);return o(...e),t}:o&&(n[r]=o):"style"===r?n[r]={...o,...a}:"className"===r&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}function wG(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?e.ref:(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,o=r&&"isReactWarning"in r&&r.isReactWarning,o?e.props.ref:e.props.ref||e.ref)}var bG=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Sk=bG.reduce(((e,t)=>{const n=mG(`Primitive.${t}`),r=v.forwardRef(((e,r)=>{const{asChild:o,...a}=e,i=o?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),G.jsx(i,{...a,ref:r})}));return r.displayName=`Primitive.${t}`,{...e,[t]:r}}),{}),M$="Progress",D$=100,[_G,iZ]=dG(M$),[xG,SG]=_G(M$),Ek=v.forwardRef(((e,t)=>{const{__scopeProgress:n,value:r=null,max:o,getValueLabel:a=EG,...i}=e;(o||0===o)&&!l2(o)&&console.error($G(`${o}`,"Progress"));const s=l2(o)?o:D$;null!==r&&!c2(r,s)&&console.error(CG(`${r}`,"Progress"));const u=c2(r,s)?r:null,l=ly(u)?a(u,s):void 0;return G.jsx(xG,{scope:n,value:u,max:s,children:G.jsx(Sk.div,{"aria-valuemax":s,"aria-valuemin":0,"aria-valuenow":ly(u)?u:void 0,"aria-valuetext":l,role:"progressbar","data-state":Ik(u,s),"data-value":u??void 0,"data-max":s,...i,ref:t})})}));Ek.displayName=M$;var $k="ProgressIndicator",Ck=v.forwardRef(((e,t)=>{const{__scopeProgress:n,...r}=e,o=SG($k,n);return G.jsx(Sk.div,{"data-state":Ik(o.value,o.max),"data-value":o.value??void 0,"data-max":o.max,...r,ref:t})}));function EG(e,t){return`${Math.round(e/t*100)}%`}function Ik(e,t){return null==e?"indeterminate":e===t?"complete":"loading"}function ly(e){return"number"==typeof e}function l2(e){return ly(e)&&!isNaN(e)&&e>0}function c2(e,t){return ly(e)&&!isNaN(e)&&e<=t&&e>=0}function $G(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${D$}\`.`}function CG(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:\n - a positive number\n - less than the value passed to \`max\` (or ${D$} if no \`max\` prop is set)\n - \`null\` or \`undefined\` if the progress is indeterminate.\n\nDefaulting to \`null\`.`}Ck.displayName=$k;var Rk=Ek,IG=Ck;const RG=v.forwardRef((({className:e,value:t,indicatorClassName:n,...r},o)=>G.jsx(Rk,{ref:o,className:we("relative h-[7px] w-full overflow-hidden rounded-full bg-blue_10",e),...r,children:G.jsx(IG,{className:we("h-full w-full flex-1 rounded-full bg-blue_100 transition-all",n),style:{transform:`translateX(-${100-(t||0)}%)`}})})));RG.displayName=Rk.displayName;const Pk="Radio",[PG,Tk]=ni(Pk),[TG,OG]=PG(Pk),AG=v.forwardRef(((e,t)=>{const{__scopeRadio:n,name:r,checked:o=!1,required:a,disabled:i,value:s="on",onCheck:u,...l}=e,[c,d]=v.useState(null),f=Vt(t,(e=>d(e))),p=v.useRef(!1),m=!c||!!c.closest("form");return v.createElement(TG,{scope:n,checked:o,disabled:i},v.createElement(ft.button,Te({type:"button",role:"radio","aria-checked":o,"data-state":Ok(o),"data-disabled":i?"":void 0,disabled:i,value:s},l,{ref:f,onClick:et(e.onClick,(e=>{o||null==u||u(),m&&(p.current=e.isPropagationStopped(),p.current||e.stopPropagation())}))})),m&&v.createElement(NG,{control:c,bubbles:!p.current,name:r,value:s,checked:o,required:a,disabled:i,style:{transform:"translateX(-100%)"}}))})),MG="RadioIndicator",DG=v.forwardRef(((e,t)=>{const{__scopeRadio:n,forceMount:r,...o}=e,a=OG(MG,n);return v.createElement(ea,{present:r||a.checked},v.createElement(ft.span,Te({"data-state":Ok(a.checked),"data-disabled":a.disabled?"":void 0},o,{ref:t})))})),NG=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,a=v.useRef(null),i=ky(n),s=Ly(t);return v.useEffect((()=>{const e=a.current,t=window.HTMLInputElement.prototype,o=Object.getOwnPropertyDescriptor(t,"checked").set;if(i!==n&&o){const t=new Event("click",{bubbles:r});o.call(e,n),e.dispatchEvent(t)}}),[i,n,r]),v.createElement("input",Te({type:"radio","aria-hidden":!0,defaultChecked:n},o,{tabIndex:-1,ref:a,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function Ok(e){return e?"checked":"unchecked"}const kG=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Ak="RadioGroup",[LG,aZ]=ni(Ak,[qm,Tk]),Mk=qm(),Dk=Tk(),[FG,BG]=LG(Ak),jG=v.forwardRef(((e,t)=>{const{__scopeRadioGroup:n,name:r,defaultValue:o,value:a,required:i=!1,disabled:s=!1,orientation:u,dir:l,loop:c=!0,onValueChange:d,...f}=e,p=Mk(n),m=s$(l),[h,g]=fd({prop:a,defaultProp:o,onChange:d});return v.createElement(FG,{scope:n,name:r,required:i,disabled:s,value:h,onValueChange:g},v.createElement(g$,Te({asChild:!0},p,{orientation:u,dir:m,loop:c}),v.createElement(ft.div,Te({role:"radiogroup","aria-required":i,"aria-orientation":u,"data-disabled":s?"":void 0,dir:m},f,{ref:t}))))})),zG="RadioGroupItem",VG=v.forwardRef(((e,t)=>{const{__scopeRadioGroup:n,disabled:r,...o}=e,a=BG(zG,n),i=a.disabled||r,s=Mk(n),u=Dk(n),l=v.useRef(null),c=Vt(t,l),d=a.value===o.value,f=v.useRef(!1);return v.useEffect((()=>{const e=e=>{kG.includes(e.key)&&(f.current=!0)},t=()=>f.current=!1;return document.addEventListener("keydown",e),document.addEventListener("keyup",t),()=>{document.removeEventListener("keydown",e),document.removeEventListener("keyup",t)}}),[]),v.createElement(y$,Te({asChild:!0},s,{focusable:!i,active:d}),v.createElement(AG,Te({disabled:i,required:a.required,checked:d},u,o,{name:a.name,ref:c,onCheck:()=>a.onValueChange(o.value),onKeyDown:et((e=>{"Enter"===e.key&&e.preventDefault()})),onFocus:et(o.onFocus,(()=>{var e;f.current&&(null===(e=l.current)||void 0===e||e.click())}))})))})),UG=v.forwardRef(((e,t)=>{const{__scopeRadioGroup:n,...r}=e,o=Dk(n);return v.createElement(DG,Te({},o,r,{ref:t}))})),Nk=jG,kk=VG,WG=UG,qG=v.forwardRef((({className:e,...t},n)=>G.jsx(Nk,{className:we("grid gap-2",e),...t,ref:n})));qG.displayName=Nk.displayName;const GG=v.forwardRef((({className:e,...t},n)=>G.jsx(kk,{ref:n,className:we("aspect-square size-6 rounded-full border border-gray-300 disabled:cursor-not-allowed disabled:border-gray-100 disabled:bg-gray-100","data-[state=checked]:border-blue_100 data-[state=checked]:bg-blue_100 hover:data-[state=checked]:border-blue_120","disabled:data-[state=checked]:border-gray-100 disabled:data-[state=checked]:bg-gray-100","transition-[border] duration-200 hover:data-[state=checked]:bg-blue_120 md:hover:border-2",e),...t,children:G.jsx(WG,{className:"flex items-center justify-center",children:G.jsx(j5,{className:"stack-animate size-2 border-none",style:{fill:t.disabled?"var(--gray-300)":"white",color:t.disabled?"var(--gray-300)":"white"}})})})));GG.displayName=kk.displayName;const HG=FA,KG=Ey,Lk=v.forwardRef((({className:e,...t},n)=>G.jsx(Bm,{className:we("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:n})));Lk.displayName=Bm.displayName;const YG=gu("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),Fk=v.forwardRef((({side:e="right",className:t,overlayClassName:n,children:r,...o},a)=>G.jsxs(KG,{children:[G.jsx(Lk,{className:we("bg-gray-900/70",n)}),G.jsxs(jm,{ref:a,className:we(YG({side:e}),t),...o,children:[r,G.jsxs($y,{className:"absolute right-4 top-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary",children:[G.jsx(gy,{className:"h-4 w-4"}),G.jsx("span",{className:"sr-only",children:"Close"})]})]})]})));Fk.displayName=jm.displayName;const Bk=({className:e,...t})=>G.jsx("div",{className:we("flex flex-col space-y-2 text-center sm:text-left",e),...t});Bk.displayName="SheetHeader";const jk=v.forwardRef((({className:e,...t},n)=>G.jsx(Ov,{ref:n,className:we("text-lg font-semibold text-foreground",e),...t})));jk.displayName=Ov.displayName;const zk=v.forwardRef((({className:e,...t},n)=>G.jsx(Av,{ref:n,className:we("text-sm text-muted-foreground",e),...t})));zk.displayName=Av.displayName;const[Xy,sZ]=ni("Tooltip",[Wm]),N$=Wm(),QG="TooltipProvider",XG=700,nE="tooltip.open",[JG,k$]=Xy(QG),ZG=e=>{const{__scopeTooltip:t,delayDuration:n=XG,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:a}=e,[i,s]=v.useState(!0),u=v.useRef(!1),l=v.useRef(0);return v.useEffect((()=>{const e=l.current;return()=>window.clearTimeout(e)}),[]),v.createElement(JG,{scope:t,isOpenDelayed:i,delayDuration:n,onOpen:v.useCallback((()=>{window.clearTimeout(l.current),s(!1)}),[]),onClose:v.useCallback((()=>{window.clearTimeout(l.current),l.current=window.setTimeout((()=>s(!0)),r)}),[r]),isPointerInTransitRef:u,onPointerInTransitChange:v.useCallback((e=>{u.current=e}),[]),disableHoverableContent:o},a)},L$="Tooltip",[eH,Vv]=Xy(L$),tH=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o=!1,onOpenChange:a,disableHoverableContent:i,delayDuration:s}=e,u=k$(L$,e.__scopeTooltip),l=N$(t),[c,d]=v.useState(null),f=ad(),p=v.useRef(0),m=i??u.disableHoverableContent,h=s??u.delayDuration,g=v.useRef(!1),[y=!1,b]=fd({prop:r,defaultProp:o,onChange:e=>{e?(u.onOpen(),document.dispatchEvent(new CustomEvent(nE))):u.onClose(),null==a||a(e)}}),w=v.useMemo((()=>y?g.current?"delayed-open":"instant-open":"closed"),[y]),x=v.useCallback((()=>{window.clearTimeout(p.current),g.current=!1,b(!0)}),[b]),_=v.useCallback((()=>{window.clearTimeout(p.current),b(!1)}),[b]),E=v.useCallback((()=>{window.clearTimeout(p.current),p.current=window.setTimeout((()=>{g.current=!0,b(!0)}),h)}),[h,b]);return v.useEffect((()=>()=>window.clearTimeout(p.current)),[]),v.createElement(sN,l,v.createElement(eH,{scope:t,contentId:f,open:y,stateAttribute:w,trigger:c,onTriggerChange:d,onTriggerEnter:v.useCallback((()=>{u.isOpenDelayed?E():x()}),[u.isOpenDelayed,E,x]),onTriggerLeave:v.useCallback((()=>{m?_():window.clearTimeout(p.current)}),[_,m]),onOpen:x,onClose:_,disableHoverableContent:m},n))},d2="TooltipTrigger",nH=v.forwardRef(((e,t)=>{const{__scopeTooltip:n,...r}=e,o=Vv(d2,n),a=k$(d2,n),i=N$(n),s=Vt(t,v.useRef(null),o.onTriggerChange),u=v.useRef(!1),l=v.useRef(!1),c=v.useCallback((()=>u.current=!1),[]);return v.useEffect((()=>()=>document.removeEventListener("pointerup",c)),[c]),v.createElement(m$,Te({asChild:!0},i),v.createElement(ft.button,Te({"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute},r,{ref:s,onPointerMove:et(e.onPointerMove,(e=>{"touch"!==e.pointerType&&!l.current&&!a.isPointerInTransitRef.current&&(o.onTriggerEnter(),l.current=!0)})),onPointerLeave:et(e.onPointerLeave,(()=>{o.onTriggerLeave(),l.current=!1})),onPointerDown:et(e.onPointerDown,(()=>{u.current=!0,document.addEventListener("pointerup",c,{once:!0})})),onFocus:et(e.onFocus,(()=>{u.current||o.onOpen()})),onBlur:et(e.onBlur,o.onClose),onClick:et(e.onClick,o.onClose)})))})),Vk="TooltipPortal",[rH,oH]=Xy(Vk,{forceMount:void 0}),iH=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,a=Vv(Vk,t);return v.createElement(rH,{scope:t,forceMount:n},v.createElement(ea,{present:n||a.open},v.createElement(by,{asChild:!0,container:o},r)))},Sv="TooltipContent",Uk=v.forwardRef(((e,t)=>{const n=oH(Sv,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...a}=e,i=Vv(Sv,e.__scopeTooltip);return v.createElement(ea,{present:r||i.open},i.disableHoverableContent?v.createElement(Wk,Te({side:o},a,{ref:t})):v.createElement(aH,Te({side:o},a,{ref:t})))})),aH=v.forwardRef(((e,t)=>{const n=Vv(Sv,e.__scopeTooltip),r=k$(Sv,e.__scopeTooltip),o=v.useRef(null),a=Vt(t,o),[i,s]=v.useState(null),{trigger:u,onClose:l}=n,c=o.current,{onPointerInTransitChange:d}=r,f=v.useCallback((()=>{s(null),d(!1)}),[d]),p=v.useCallback(((e,t)=>{const n=e.currentTarget,r={x:e.clientX,y:e.clientY},o=fH([...lH(r,uH(r,n.getBoundingClientRect())),...cH(t.getBoundingClientRect())]);s(o),d(!0)}),[d]);return v.useEffect((()=>()=>f()),[f]),v.useEffect((()=>{if(u&&c){const e=e=>p(e,c),t=e=>p(e,u);return u.addEventListener("pointerleave",e),c.addEventListener("pointerleave",t),()=>{u.removeEventListener("pointerleave",e),c.removeEventListener("pointerleave",t)}}}),[u,c,p,f]),v.useEffect((()=>{if(i){const e=e=>{const t=e.target,n={x:e.clientX,y:e.clientY},r=(null==u?void 0:u.contains(t))||(null==c?void 0:c.contains(t)),o=!dH(n,i);r?f():o&&(f(),l())};return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}}),[u,c,i,l,f]),v.createElement(Wk,Te({},e,{ref:a}))})),[sH,uZ]=Xy(L$,{isInside:!1}),Wk=v.forwardRef(((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:a,onPointerDownOutside:i,...s}=e,u=Vv(Sv,n),l=N$(n),{onClose:c}=u;return v.useEffect((()=>(document.addEventListener(nE,c),()=>document.removeEventListener(nE,c))),[c]),v.useEffect((()=>{if(u.trigger){const e=e=>{const t=e.target;null!=t&&t.contains(u.trigger)&&c()};return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}}),[u.trigger,c]),v.createElement(wy,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:e=>e.preventDefault(),onDismiss:c},v.createElement(h$,Te({"data-state":u.stateAttribute},l,s,{ref:t,style:{...s.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"}}),v.createElement(_E,null,r),v.createElement(sH,{scope:n,isInside:!0},v.createElement(qU,{id:u.contentId,role:"tooltip"},o||r))))}));function uH(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,o,a)){case a:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function lH(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n})}return r}function cH(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function dH(e,t){const{x:n,y:r}=e;let o=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){const i=t[e].x,s=t[e].y,u=t[a].x,l=t[a].y;s>r!=l>r&&n<(u-i)*(r-s)/(l-s)+i&&(o=!o)}return o}function fH(e){const t=e.slice();return t.sort(((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:e.y>t.y?1:0)),pH(t)}function pH(e){if(e.length<=1)return e.slice();const t=[];for(let n=0;n<e.length;n++){const r=e[n];for(;t.length>=2;){const e=t[t.length-1],n=t[t.length-2];if(!((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x)))break;t.pop()}t.push(r)}t.pop();const n=[];for(let t=e.length-1;t>=0;t--){const r=e[t];for(;n.length>=2;){const e=n[n.length-1],t=n[n.length-2];if(!((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.x)))break;n.pop()}n.push(r)}return n.pop(),1===t.length&&1===n.length&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}const mH=iH,qk=Uk,hH=()=>{const e=window.innerWidth;return e<768?"mobile":e<1024?"tablet":"desktop"},vH=e=>{if("object"!=typeof e||null===e)return!1;let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||null===Object.getPrototypeOf(e)},gH=e=>vH(e)&&"type"in e&&"string"==typeof e.type,wt=e=>{const t=t=>({type:e,payload:t});return t.toString=()=>`${e}`,t.type=e,t.match=t=>gH(t)&&t.type===e,t};wt("remoteReady"),wt("askLogin"),wt("reselectUser"),wt("requestLogout");const yH=wt("setConfirmLeavePage"),wH=wt("requestChangePath");wt("wsSubscribe"),wt("wsUnSubscribe"),wt("hostStoreConnect"),wt("remoteLogin");const bH=wt("remoteLogout");wt("wsOnMessage");const _H=wt("setRouterPath"),xH=wt("setDeviceType"),SH=wt("setDeviceWidth"),EH=wt("setUserError"),$H=wt("setUserIsError"),CH=wt("setUserPending"),IH=wt("setUserSuccess"),RH=wt("setUserData"),PH=wt("updateAccountData"),TH=wt("updateUser"),OH=wt("addNotification"),AH=wt("markNotification"),MH=wt("setNotificationsError"),DH=wt("setNotificationsList"),NH=wt("setNotificationsPending"),kH=wt("setNotificationsTotalCount"),LH=wt("setNotificationsUnreadCount"),FH=wt("acceptAllFollowRequests"),BH=wt("resetNotificationsState"),jH=wt("undoNotification"),zH=wt("setInstanceInfo"),VH=wt("setInstanceInfoPending"),UH=wt("setInstanceInfoError"),WH=wt("setPlatformSettings"),qH=wt("setProfileSettings");wt("setGroupData"),wt("setGroupLoading"),wt("requestLocalStorageGet"),wt("requestLocalStorageSet"),wt("requestLocalStorageRemove"),wt("requestLocalStorageClear"),wt("requestLocalStorageKeys"),wt("requestLocalStorageHas"),wt("sendLocalStorageResponse"),wt("sendLocalStorageChanged");const uv="8.48.0",$l=globalThis;function F$(e,t,n){const r=$l,o=r.__SENTRY__=r.__SENTRY__||{},a=o[uv]=o[uv]||{};return a[e]||(a[e]=t())}const Gk=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,GH="Sentry Logger ",f2=["debug","info","warn","error","log","assert","trace"],p2={};function HH(e){if(!("console"in $l))return e();const t=$l.console,n={},r=Object.keys(p2);r.forEach((e=>{const r=p2[e];n[e]=t[e],t[e]=r}));try{return e()}finally{r.forEach((e=>{t[e]=n[e]}))}}function KH(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return Gk?f2.forEach((n=>{t[n]=(...t)=>{e&&HH((()=>{$l.console[n](`${GH}[${n}]:`,...t)}))}})):f2.forEach((e=>{t[e]=()=>{}})),t}const Ug=F$("logger",KH);function B$(){return j$($l),$l}function j$(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||uv,t[uv]=t[uv]||{}}const YH=Object.prototype.toString;function QH(e,t){return YH.call(e)===`[object ${t}]`}function XH(e){return QH(e,"Object")}function JH(e){return!(!e||!e.then||"function"!=typeof e.then)}function ZH(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{Gk&&Ug.log(`Failed to add non-enumerable property "${t}" to object`,e)}}const Hk=1e3;function Kk(){return Date.now()/Hk}function eK(){const{performance:e}=$l;if(!e||!e.now)return Kk;const t=Date.now()-e.now(),n=null==e.timeOrigin?t:e.timeOrigin;return()=>(n+e.now())/Hk}const tK=eK();function Tm(){const e=$l,t=e.crypto||e.msCrypto;let n=()=>16*Math.random();try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{const e=new Uint8Array(1);return t.getRandomValues(e),e[0]})}catch{}return"10000000100040008000100000000000".replace(/[018]/g,(e=>(e^(15&n())>>e/4).toString(16)))}function nK(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||tK(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=32===t.sid.length?t.sid:Tm()),void 0!==t.init&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),"number"==typeof t.started&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if("number"==typeof t.duration)e.duration=t.duration;else{const t=e.timestamp-e.started;e.duration=t>=0?t:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),"number"==typeof t.errors&&(e.errors=t.errors),t.status&&(e.status=t.status)}function m2(){return Tm()}function h2(){return Tm().substring(16)}function Yk(e,t,n=2){if(!t||"object"!=typeof t||n<=0)return t;if(e&&t&&0===Object.keys(t).length)return e;const r={...e};for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(r[e]=Yk(r[e],t[e],n-1));return r}(()=>{const{performance:e}=$l;if(!e||!e.now)return;const t=36e5,n=e.now(),r=Date.now(),o=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,a=o<t,i=e.timing&&e.timing.navigationStart,s="number"==typeof i?Math.abs(i+n-r):t;(a||s<t)&&(o<=s&&e.timeOrigin)})();const rE="_sentrySpan";function v2(e,t){t?ZH(e,rE,t):delete e[rE]}function g2(e){return e[rE]}const rK=100;class z${constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:m2(),spanId:h2()}}clone(){const e=new z$;return e._breadcrumbs=[...this._breadcrumbs],e._tags={...this._tags},e._extra={...this._extra},e._contexts={...this._contexts},this._contexts.flags&&(e._contexts.flags={values:[...this._contexts.flags.values]}),e._user=this._user,e._level=this._level,e._session=this._session,e._transactionName=this._transactionName,e._fingerprint=this._fingerprint,e._eventProcessors=[...this._eventProcessors],e._requestSession=this._requestSession,e._attachments=[...this._attachments],e._sdkProcessingMetadata={...this._sdkProcessingMetadata},e._propagationContext={...this._propagationContext},e._client=this._client,e._lastEventId=this._lastEventId,v2(e,g2(this)),e}setClient(e){this._client=e}setLastEventId(e){this._lastEventId=e}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&nK(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(e){return this._requestSession=e,this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this._tags={...this._tags,[e]:t},this._notifyScopeListeners(),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return null===t?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(e){if(!e)return this;const t="function"==typeof e?e(this):e,[n,r]=t instanceof Ev?[t.getScopeData(),t.getRequestSession()]:XH(t)?[e,e.requestSession]:[],{tags:o,extra:a,user:i,contexts:s,level:u,fingerprint:l=[],propagationContext:c}=n||{};return this._tags={...this._tags,...o},this._extra={...this._extra,...a},this._contexts={...this._contexts,...s},i&&Object.keys(i).length&&(this._user=i),u&&(this._level=u),l.length&&(this._fingerprint=l),c&&(this._propagationContext=c),r&&(this._requestSession=r),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._session=void 0,v2(this,void 0),this._attachments=[],this.setPropagationContext({traceId:m2()}),this._notifyScopeListeners(),this}addBreadcrumb(e,t){const n="number"==typeof t?t:rK;if(n<=0)return this;const r={timestamp:Kk(),...e},o=this._breadcrumbs;return o.push(r),this._breadcrumbs=o.length>n?o.slice(-n):o,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:g2(this)}}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata=Yk(this._sdkProcessingMetadata,e,2),this}setPropagationContext(e){return this._propagationContext={spanId:h2(),...e},this}getPropagationContext(){return this._propagationContext}captureException(e,t){const n=t&&t.event_id?t.event_id:Tm();if(!this._client)return Ug.warn("No client configured on scope - will not capture exception!"),n;const r=new Error("Sentry syntheticException");return this._client.captureException(e,{originalException:e,syntheticException:r,...t,event_id:n},this),n}captureMessage(e,t,n){const r=n&&n.event_id?n.event_id:Tm();if(!this._client)return Ug.warn("No client configured on scope - will not capture message!"),r;const o=new Error(e);return this._client.captureMessage(e,t,{originalException:e,syntheticException:o,...n,event_id:r},this),r}captureEvent(e,t){const n=t&&t.event_id?t.event_id:Tm();return this._client?(this._client.captureEvent(e,{...t,event_id:n},this),n):(Ug.warn("No client configured on scope - will not capture event!"),n)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((e=>{e(this)})),this._notifyingListeners=!1)}}const Ev=z$;function oK(){return F$("defaultCurrentScope",(()=>new Ev))}function iK(){return F$("defaultIsolationScope",(()=>new Ev))}class aK{constructor(e,t){let n,r;n=e||new Ev,r=t||new Ev,this._stack=[{scope:n}],this._isolationScope=r}withScope(e){const t=this._pushScope();let n;try{n=e(t)}catch(e){throw this._popScope(),e}return JH(n)?n.then((e=>(this._popScope(),e)),(e=>{throw this._popScope(),e})):(this._popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const e=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:e}),e}_popScope(){return!(this._stack.length<=1)&&!!this._stack.pop()}}function Lm(){const e=j$(B$());return e.stack=e.stack||new aK(oK(),iK())}function sK(e){return Lm().withScope(e)}function uK(e,t){const n=Lm();return n.withScope((()=>(n.getStackTop().scope=e,t(e))))}function y2(e){return Lm().withScope((()=>e(Lm().getIsolationScope())))}function lK(){return{withIsolationScope:y2,withScope:sK,withSetScope:uK,withSetIsolationScope:(e,t)=>y2(t),getCurrentScope:()=>Lm().getScope(),getIsolationScope:()=>Lm().getIsolationScope()}}function Qk(e){const t=j$(e);return t.acs?t.acs:lK()}function Xk(){return Qk(B$()).getCurrentScope()}function cK(){return Qk(B$()).getIsolationScope()}function dK(e,t){return Xk().captureException(e,void 0)}function fK(e,t){const n={captureContext:t};return Xk().captureMessage(e,void 0,n)}function pK(e,t){cK().setExtra(e,t)}const mK=(...e)=>{let t="";for(const n of e){if(n instanceof Error){const e=n;return pK("exceptionMessage",t),void dK(e)}if("object"!=typeof n)t+=n;else try{t+=" "+JSON.stringify(n)}catch{t+=" "+n}}fK(t)},Jy=()=>"object"!=typeof window,hK="wlsy",Jk=()=>{try{return window.localStorage}catch(e){console.warn("Error getting window.localStorage storage",e)}},vK=()=>{const e=new Set,t=Jk();if(!t)return[];for(let n=0;n<(null==t?void 0:t.length);n+=1){const r=null==t?void 0:t.key(n);"string"==typeof r&&e.add(r)}return Array.from(e)},V$=e=>{const t=`${hK}${e?`:${e}`:""}`,n=e=>`${t}:${e}`,r=()=>vK().filter((e=>e.startsWith(`${t}:`))),o=e=>e.slice(t.length+1),a=Jk(),i=e=>{try{return null==a?void 0:a.getItem(n(e))}catch{return null}},s=(e,t)=>{try{null==a||a.setItem(n(e),String(t))}catch{return}};return{getItem:i,setItem:s,removeItem:e=>{try{null==a||a.removeItem(n(e))}catch{return}},clear:()=>{try{r().forEach((e=>null==a?void 0:a.removeItem(e)))}catch{return}},keys:()=>r().map(o),has:e=>null!==i(e),getJSON:e=>{const t=i(e);if(null==t)return null;try{return JSON.parse(t)}catch{return null}},setJSON:(e,t)=>{try{s(e,JSON.stringify(t))}catch{return}}}},w2=["debug","info","warn","error"],gK=(e,t)=>{const n=w2.indexOf(e);return w2.indexOf(t)>=n},Ng=(e,t,n,...r)=>{gK(t,e)&&console.log(`[${e}] ${n}`,...r)},yK=()=>V$().getItem("logger_lvl"),wK=(e=(Jy()?"info":yK()||"warn"))=>{let t=e;return{debug:(e,...n)=>Ng("debug",t,e,...n),info:(e,...n)=>Ng("info",t,e,...n),warn:(e,...n)=>Ng("warn",t,e,...n),error:(e,...n)=>(mK(e,...n),Ng("error",t,e,...n)),setLevel:e=>{t=e},getLevel:()=>t}},ap=wK(),bK=e=>{try{const{type:t,payload:n}=e,r={type:t};return void 0!==n&&(r.payload=JSON.parse(JSON.stringify(n))),r}catch(t){return ap.warn(`Could not serialize action type: ${e.type}`,t),{type:e.type,payload:`[Non-serializable payload for action: ${e.type}]`}}},Zk=({action:e,windowElement:t,whitelist:n})=>{if(t)try{const{type:r}=e;if(!n.some((({type:e})=>e===r||"*"===e)))return;const o=bK(e);t.postMessage(o,"*")}catch(e){ap.error("Failed to process or send message:",e)}},e3=({onMessage:e,whitelist:t,sourceWindow:n})=>{const r=r=>{const o=r.origin===window.location.origin,a=!n||r.source===n,i=r.data&&"object"==typeof r.data&&"type"in r.data,s=t.some((({type:e})=>e===r.data.type||"*"===e));!o&&a&&i&&s&&e(r.data)};return window.addEventListener("message",r),()=>{window.removeEventListener("message",r)}},Cm=()=>{try{return window.self!==window.top}catch{return!0}},b2=Vn("requestMicroFrontendFetch"),_K=Vn("sendMicroFrontendFetchResponse"),xK={deviceType:hH(),deviceWidth:window.innerWidth},t3=oo({name:"ui",initialState:xK,reducers:{},extraReducers:e=>{e.addCase(xH,((e,{payload:t})=>{e.deviceType=t})),e.addCase(SH,((e,{payload:t})=>{e.deviceWidth=t}))},selectors:{selectDeviceType:e=>e.deviceType,selectDeviceWidth:e=>e.deviceWidth,selectIsMobile:e=>"mobile"===e.deviceType,selectIsTablet:e=>"tablet"===e.deviceType,selectIsDesktop:e=>"desktop"===e.deviceType}});var Sx,_2,Ex,x2,$x,S2,Cx,E2,Ix,$2,Rx,C2,Px,I2,Tx,R2,Ox,P2,Ax,T2,Mx,O2,Dx,A2,Nx,M2,kx,D2,Lx,N2,Fx,k2,Bx,L2,jx,F2,zx,B2,Vx,j2,Ux,z2,Wx,V2,qx,U2,Gx,W2,Hx,q2,Kx,G2,Yx,H2,Qx,K2,Xx,Y2,Jx,Q2,Zx,X2,eS,J2,tS,Z2,nS,eO,rS,tO,oS,nO,iS,rO,aS,oO,sS,iO,uS,aO,lS,sO;function n3(){if(_2)return Sx;_2=1;var e=CM(),t=e&&new e;return Sx=t}function r3(){if(x2)return Ex;x2=1;var e=GE(),t=n3();return Ex=t?function(e,n){return t.set(e,n),e}:e}function Zy(){if(S2)return $x;S2=1;var e=Ny(),t=bs();return $x=function(n){return function(){var r=arguments;switch(r.length){case 0:return new n;case 1:return new n(r[0]);case 2:return new n(r[0],r[1]);case 3:return new n(r[0],r[1],r[2]);case 4:return new n(r[0],r[1],r[2],r[3]);case 5:return new n(r[0],r[1],r[2],r[3],r[4]);case 6:return new n(r[0],r[1],r[2],r[3],r[4],r[5]);case 7:return new n(r[0],r[1],r[2],r[3],r[4],r[5],r[6])}var o=e(n.prototype),a=n.apply(o,r);return t(a)?a:o}},$x}function SK(){if(E2)return Cx;E2=1;var e=Zy(),t=ri();return Cx=function(n,r,o){var a=1&r,i=e(n);return function e(){return(this&&this!==t&&this instanceof e?i:n).apply(a?o:this,arguments)}},Cx}function o3(){if($2)return Ix;$2=1;var e=Math.max;return Ix=function(t,n,r,o){for(var a=-1,i=t.length,s=r.length,u=-1,l=n.length,c=e(i-s,0),d=Array(l+c),f=!o;++u<l;)d[u]=n[u];for(;++a<s;)(f||a<i)&&(d[r[a]]=t[a]);for(;c--;)d[u++]=t[a++];return d}}function i3(){if(C2)return Rx;C2=1;var e=Math.max;return Rx=function(t,n,r,o){for(var a=-1,i=t.length,s=-1,u=r.length,l=-1,c=n.length,d=e(i-u,0),f=Array(d+c),p=!o;++a<d;)f[a]=t[a];for(var m=a;++l<c;)f[m+l]=n[l];for(;++s<u;)(p||a<i)&&(f[m+r[s]]=t[a++]);return f}}function EK(){if(I2)return Px;return I2=1,Px=function(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}}function U$(){if(R2)return Tx;return R2=1,Tx=function(){}}function W$(){if(P2)return Ox;P2=1;var e=Ny(),t=U$();function n(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}return n.prototype=e(t.prototype),n.prototype.constructor=n,Ox=n}function a3(){if(T2)return Ax;T2=1;var e=n3(),t=F9();return Ax=e?function(t){return e.get(t)}:t}function $K(){if(O2)return Mx;O2=1;return Mx={}}function CK(){if(A2)return Dx;A2=1;var e=$K(),t=Object.prototype.hasOwnProperty;return Dx=function(n){for(var r=n.name+"",o=e[r],a=t.call(e,r)?o.length:0;a--;){var i=o[a],s=i.func;if(null==s||s==n)return i.name}return r}}function s3(){if(M2)return Nx;M2=1;var e=Ny(),t=U$();function n(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}return n.prototype=e(t.prototype),n.prototype.constructor=n,Nx=n}function IK(){if(D2)return kx;D2=1;var e=W$(),t=s3(),n=Dy();return kx=function(r){if(r instanceof e)return r.clone();var o=new t(r.__wrapped__,r.__chain__);return o.__actions__=n(r.__actions__),o.__index__=r.__index__,o.__values__=r.__values__,o}}function RK(){if(N2)return Lx;N2=1;var e=W$(),t=s3(),n=U$(),r=Ei(),o=ta(),a=IK(),i=Object.prototype.hasOwnProperty;function s(n){if(o(n)&&!r(n)&&!(n instanceof e)){if(n instanceof t)return n;if(i.call(n,"__wrapped__"))return a(n)}return new t(n)}return s.prototype=n.prototype,s.prototype.constructor=s,Lx=s}function PK(){if(k2)return Fx;k2=1;var e=W$(),t=a3(),n=CK(),r=RK();return Fx=function(o){var a=n(o),i=r[a];if("function"!=typeof i||!(a in e.prototype))return!1;if(o===i)return!0;var s=t(i);return!!s&&o===s[0]}}function u3(){if(L2)return Bx;L2=1;var e=r3(),t=OM()(e);return Bx=t}function TK(){if(F2)return jx;F2=1;var e=/\{\n\/\* \[wrapped with (.+)\] \*/,t=/,? & /;return jx=function(n){var r=n.match(e);return r?r[1].split(t):[]}}function OK(){if(B2)return zx;B2=1;var e=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;return zx=function(t,n){var r=n.length;if(!r)return t;var o=r-1;return n[o]=(r>1?"& ":"")+n[o],n=n.join(r>2?", ":" "),t.replace(e,"{\n/* [wrapped with "+n+"] */\n")}}function AK(){if(j2)return Vx;j2=1;var e=YE(),t=L9(),n=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]];return Vx=function(r,o){return e(n,(function(e){var n="_."+e[0];o&e[1]&&!t(r,n)&&r.push(n)})),r.sort()}}function l3(){if(z2)return Ux;z2=1;var e=TK(),t=OK(),n=AM(),r=AK();return Ux=function(o,a,i){var s=a+"";return n(o,t(s,r(e(s),i)))}}function c3(){if(V2)return Wx;V2=1;var e=PK(),t=u3(),n=l3();return Wx=function(r,o,a,i,s,u,l,c,d,f){var p=8&o;o|=p?32:64,4&(o&=~(p?64:32))||(o&=-4);var m=[r,o,s,p?u:void 0,p?l:void 0,p?void 0:u,p?void 0:l,c,d,f],v=a.apply(void 0,m);return e(r)&&t(v,m),v.placeholder=i,n(v,r,o)}}function d3(){if(U2)return qx;return U2=1,qx=function(e){return e.placeholder}}function MK(){if(W2)return Gx;W2=1;var e=Dy(),t=zE(),n=Math.min;return Gx=function(r,o){for(var a=r.length,i=n(o.length,a),s=e(r);i--;){var u=o[i];r[i]=t(u,a)?s[u]:void 0}return r}}function q$(){if(q2)return Hx;q2=1;var e="__lodash_placeholder__";return Hx=function(t,n){for(var r=-1,o=t.length,a=0,i=[];++r<o;){var s=t[r];(s===n||s===e)&&(t[r]=e,i[a++]=r)}return i}}function f3(){if(G2)return Kx;G2=1;var e=o3(),t=i3(),n=EK(),r=Zy(),o=c3(),a=d3(),i=MK(),s=q$(),u=ri();return Kx=function l(c,d,f,p,m,v,h,g,y,b){var w=128&d,x=1&d,_=2&d,E=24&d,S=512&d,I=_?void 0:r(c);return function A(){for(var k=arguments.length,C=Array(k),T=k;T--;)C[T]=arguments[T];if(E)var R=a(A),P=n(C,R);if(p&&(C=e(C,p,m,E)),v&&(C=t(C,v,h,E)),k-=P,E&&k<b){var O=s(C,R);return o(c,d,l,A.placeholder,f,C,O,g,y,b-k)}var N=x?f:this,M=_?N[c]:c;return k=C.length,g?C=i(C,g):S&&k>1&&C.reverse(),w&&y<k&&(C.length=y),this&&this!==u&&this instanceof A&&(M=I||r(M)),M.apply(N,C)}},Kx}function DK(){if(H2)return Yx;H2=1;var e=HE(),t=Zy(),n=f3(),r=c3(),o=d3(),a=q$(),i=ri();return Yx=function(s,u,l){var c=t(s);return function t(){for(var d=arguments.length,f=Array(d),p=d,m=o(t);p--;)f[p]=arguments[p];var v=d<3&&f[0]!==m&&f[d-1]!==m?[]:a(f,m);return(d-=v.length)<l?r(s,u,n,t.placeholder,void 0,f,v,void 0,void 0,l-d):e(this&&this!==i&&this instanceof t?c:s,this,f)}},Yx}function NK(){if(K2)return Qx;K2=1;var e=HE(),t=Zy(),n=ri();return Qx=function(r,o,a,i){var s=1&o,u=t(r);return function t(){for(var o=-1,l=arguments.length,c=-1,d=i.length,f=Array(d+l),p=this&&this!==n&&this instanceof t?u:r;++c<d;)f[c]=i[c];for(;l--;)f[c++]=arguments[++o];return e(p,s?a:this,f)}},Qx}function kK(){if(Y2)return Xx;Y2=1;var e=o3(),t=i3(),n=q$(),r="__lodash_placeholder__",o=128,a=Math.min;return Xx=function(i,s){var u=i[1],l=s[1],c=u|l,d=c<131,f=l==o&&8==u||l==o&&256==u&&i[7].length<=s[8]||384==l&&s[7].length<=s[8]&&8==u;if(!d&&!f)return i;1&l&&(i[2]=s[2],c|=1&u?0:4);var p=s[3];if(p){var m=i[3];i[3]=m?e(m,p,s[4]):p,i[4]=m?n(i[3],r):s[4]}return(p=s[5])&&(m=i[5],i[5]=m?t(m,p,s[6]):p,i[6]=m?n(i[5],r):s[6]),(p=s[7])&&(i[7]=p),l&o&&(i[8]=null==i[8]?s[8]:a(i[8],s[8])),null==i[9]&&(i[9]=s[9]),i[0]=s[0],i[1]=c,i}}function G$(){if(Q2)return Jx;Q2=1;var e=r3(),t=SK(),n=DK(),r=f3(),o=NK(),a=a3(),i=kK(),s=u3(),u=l3(),l=kM(),c=Math.max;return Jx=function(d,f,p,m,v,h,g,y){var b=2&f;if(!b&&"function"!=typeof d)throw new TypeError("Expected a function");var w=m?m.length:0;if(w||(f&=-97,m=v=void 0),g=void 0===g?g:c(l(g),0),y=void 0===y?y:l(y),w-=v?v.length:0,64&f){var x=m,_=v;m=v=void 0}var E=b?void 0:a(d),S=[d,f,p,m,v,x,_,h,g,y];if(E&&i(S,E),d=S[0],f=S[1],p=S[2],m=S[3],v=S[4],!(y=S[9]=void 0===S[9]?b?0:d.length:c(S[9]-w,0))&&24&f&&(f&=-25),f&&1!=f)I=8==f||16==f?n(d,f,y):32!=f&&33!=f||v.length?r.apply(void 0,S):o(d,f,p,m);else var I=t(d,f,p);return u((E?e:s)(I,S),d,f)}}function LK(){if(X2)return Zx;X2=1;var e=G$();return Zx=function(t,n,r){return n=r?void 0:n,n=t&&null==n?t.length:n,e(t,128,void 0,void 0,void 0,void 0,n)}}function FK(){if(J2)return eS;J2=1;var e=jM();return eS=function(t){return e(t,4)}}function BK(){if(Z2)return tS;Z2=1;var e=G$();function t(n,r,o){var a=e(n,8,void 0,void 0,void 0,void 0,void 0,r=o?void 0:r);return a.placeholder=t.placeholder,a}return t.placeholder={},tS=t}function jK(){if(eO)return nS;eO=1;var e=Cl(),t=ta(),n=iF();return nS=function(r){if(!t(r))return!1;var o=e(r);return"[object Error]"==o||"[object DOMException]"==o||"string"==typeof r.message&&"string"==typeof r.name&&!n(r)}}function zK(){if(tO)return rS;tO=1;var e=kv(),t=ta();return rS=function(n){return t(n)&&"[object WeakMap]"==e(n)}}function VK(){if(nO)return oS;nO=1;var e=jM(),t=A9();return oS=function(n){return t("function"==typeof n?n:e(n,1))}}function UK(){if(rO)return iS;rO=1;var e=G$(),t=CF(),n=t((function(t,n){return e(t,256,void 0,void 0,void 0,n)}));return iS=n}function WK(){if(oO)return aS;oO=1;var e=cM(),t=Dy(),n=Ei(),r=Dv(),o=lM(),a=Nv(),i=dM();return aS=function(s){return n(s)?e(s,a):r(s)?[s]:t(o(i(s)))}}function qK(){return iO||(iO=1,sS={ary:LK(),assign:FM(),clone:FK(),curry:BK(),forEach:YE(),isArray:Ei(),isError:jK(),isFunction:Iy(),isWeakMap:zK(),iteratee:VK(),keys:SM(),rearg:UK(),toInteger:kM(),toPath:WK()}),sS}function GK(){if(aO)return uS;aO=1;var e=nA(),t=qK();return uS=function(n,r,o){return e(t,n,r,o)}}function HK(){if(sO)return lS;sO=1;var e=GK()("debounce",DM());return e.placeholder=tA(),lS=e}function uO(e,t,n=window){const r=v.useRef(t);v.useEffect((()=>{r.current=t}),[t]),v.useEffect((()=>{if(!n)return;const t=e=>r.current(e);return n.addEventListener(e,t),()=>{n.removeEventListener(e,t)}}),[e,n])}HK();const KK=()=>vy(t3.selectors.selectIsMobile);function lO({className:e,...t}){return G.jsx("div",{className:we("animate-pulse rounded-md bg-muted",e),...t})}const YK="sidebar_state",QK=604800,XK="12rem",JK="18rem",ZK="2rem",eY="b",p3=v.createContext(null);function e0(){const e=v.useContext(p3);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const tY=v.forwardRef((({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:a,...i},s)=>{const u=KK(),[l,c]=v.useState(!1),[d,f]=v.useState(e),p=t??d,m=v.useCallback((e=>{const t="function"==typeof e?e(p):e;n?n(t):f(t),document.cookie=`${YK}=${t}; path=/; max-age=${QK}`}),[n,p]),h=v.useCallback((()=>u?c((e=>!e)):m((e=>!e))),[u,m,c]);v.useEffect((()=>{const e=e=>{e.key===eY&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),h())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)}),[h]);const g=p?"expanded":"collapsed",y=v.useMemo((()=>({state:g,open:p,setOpen:m,isMobile:u,openMobile:l,setOpenMobile:c,toggleSidebar:h})),[g,p,m,u,l,c,h]);return G.jsx(p3.Provider,{value:y,children:G.jsx(ZG,{delayDuration:0,children:G.jsx("div",{style:{"--sidebar-width":XK,"--sidebar-width-icon":ZK,...o},className:we("group/sidebar-wrapper flex min-h-svh w-full bg-gray-100 has-[[data-variant=inset]]:bg-sidebar",r),ref:s,...i,children:a})})})}));tY.displayName="SidebarProvider";const nY=v.forwardRef((({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...a},i)=>{const{isMobile:s,state:u,openMobile:l,setOpenMobile:c}=e0();return"none"===n?G.jsx("div",{className:we("flex h-full w-[--sidebar-width] flex-col bg-sidebar text-sidebar-foreground",r),ref:i,...a,children:o}):s?G.jsx(HG,{open:l,onOpenChange:c,children:G.jsxs(Fk,{"data-sidebar":"sidebar","data-mobile":"true",className:"w-[--sidebar-width] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":JK},side:e,children:[G.jsxs(Bk,{className:"sr-only",children:[G.jsx(jk,{children:"Sidebar"}),G.jsx(zk,{children:"Displays the mobile sidebar."})]}),G.jsx("div",{className:"flex h-full w-full flex-col",children:o})]})}):G.jsxs("div",{ref:i,className:"group peer hidden text-sidebar-foreground md:block","data-state":u,"data-collapsible":"collapsed"===u?n:"","data-variant":t,"data-side":e,children:[G.jsx("div",{className:we("relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180","floating"===t||"inset"===t?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),G.jsx("div",{className:we("fixed inset-y-0 z-10 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear md:flex","left"===e?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]","floating"===t||"inset"===t?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",r),...a,children:G.jsx("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-sm group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow",children:o})})]})}));nY.displayName="Sidebar";const rY=v.forwardRef((({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o,open:a}=e0();return G.jsx(yy,{ref:r,"data-sidebar":"trigger",variant:"tertiary",size:"icon_m",className:we("size-6 text-gray-900",e),onClick:e=>{null==t||t(e),o()},...n,children:a?G.jsx(Y5,{size:16}):G.jsx(H5,{size:16})})}));rY.displayName="SidebarTrigger";const oY=v.forwardRef((({className:e,...t},n)=>{const{toggleSidebar:r}=e0();return G.jsx("button",{ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:we("absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...t})}));oY.displayName="SidebarRail";const iY=v.forwardRef((({className:e,...t},n)=>G.jsx("main",{ref:n,className:we("relative flex w-full flex-1 flex-col bg-background","md:peer-data-[variant=inset]:m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-m md:peer-data-[variant=inset]:shadow",e),...t})));iY.displayName="SidebarInset";const aY=v.forwardRef((({className:e,...t},n)=>G.jsx(xk,{ref:n,"data-sidebar":"input",className:we("h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",e),...t})));aY.displayName="SidebarInput";const sY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"header",className:we("flex flex-col gap-xxs p-xs",e),...t})));sY.displayName="SidebarHeader";const uY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"footer",className:we("flex flex-col gap-2 p-2",e),...t})));uY.displayName="SidebarFooter";const lY=v.forwardRef((({className:e,...t},n)=>G.jsx(S$,{ref:n,"data-sidebar":"separator",className:we("mx-2 w-auto bg-sidebar-border",e),...t})));lY.displayName="SidebarSeparator";const cY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"content",className:we("flex min-h-0 flex-1 flex-col gap-xxxs overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...t})));cY.displayName="SidebarContent";const dY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"group",className:we("relative flex w-full min-w-0 flex-col pt-xs",e),...t})));dY.displayName="SidebarGroup";const fY=v.forwardRef((({className:e,asChild:t=!1,...n},r)=>{const o=t?yd:"div";return G.jsx(o,{ref:r,"data-sidebar":"group-label",className:we("flex h-s shrink-0 items-center rounded-md px-xxs py-xxs text-xs font-semibold text-gray-700 opacity-60 outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-xl group-data-[collapsible=icon]:opacity-0",e),...n})}));fY.displayName="SidebarGroupLabel";const pY=v.forwardRef((({className:e,asChild:t=!1,...n},r)=>{const o=t?yd:"button";return G.jsx(o,{ref:r,"data-sidebar":"group-action",className:we("absolute right-xs top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","group-data-[collapsible=icon]:hidden",e),...n})}));pY.displayName="SidebarGroupAction";const mY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"group-content",className:we("w-full text-sm",e),...t})));mY.displayName="SidebarGroupContent";const hY=v.forwardRef((({className:e,...t},n)=>G.jsx("ul",{ref:n,"data-sidebar":"menu",className:we("flex w-full min-w-0 flex-col p-xs font-semibold text-gray-700 [&_svg]:size-4",e),...t})));hY.displayName="SidebarMenu";const vY=v.forwardRef((({className:e,...t},n)=>G.jsx("li",{ref:n,"data-sidebar":"menu-item",className:we("group/menu-item relative",e),...t})));vY.displayName="SidebarMenuItem";const gY=gu("peer/menu-button flex w-full items-center gap-xxs overflow-hidden rounded-sm p-xxs text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:text-blue_100 hover:bg-white focus-visible:ring-2 active:bg-white active:text-blue_100 disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-white data-[active=true]:font-medium data-[active=true]:text-blue_100 data-[state=open]:hover:bg-white data-[state=open]:hover:text-blue_100 group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:text-blue_100 hover:bg-white",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-white hover:text-blue_100 hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-s text-sm",sm:"h-m text-xs",lg:"h-l text-sm group-data-[collapsible=icon]:!p-0"}},defaultVariants:{variant:"default",size:"default"}}),yY=v.forwardRef((({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:a,...i},s)=>{const u=e?yd:"button",{isMobile:l,state:c}=e0(),d=G.jsx(u,{ref:s,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:we(gY({variant:n,size:r}),a),...i});return o?("string"==typeof o&&(o={children:o}),G.jsxs(tH,{children:[G.jsx(nH,{asChild:!0,children:d}),G.jsx(Uk,{side:"right",align:"center",hidden:"collapsed"!==c||l,...o})]})):d}));yY.displayName="SidebarMenuButton";const wY=v.forwardRef((({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const a=t?yd:"button";return G.jsx(a,{ref:o,"data-sidebar":"menu-action",className:we("absolute right-xxxs top-xxs flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","peer-data-[size=sm]/menu-button:top-xxxs","peer-data-[size=default]/menu-button:top-xxs","peer-data-[size=lg]/menu-button:top-xs","group-data-[collapsible=icon]:hidden",n&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground md:opacity-0",e),...r})}));wY.displayName="SidebarMenuAction";const bY=v.forwardRef((({className:e,...t},n)=>G.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:we("pointer-events-none absolute right-xxxs flex h-m min-w-5 select-none items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-xxxs","peer-data-[size=default]/menu-button:top-xxs","peer-data-[size=lg]/menu-button:top-xs","group-data-[collapsible=icon]:hidden",e),...t})));bY.displayName="SidebarMenuBadge";const _Y=v.forwardRef((({className:e,showIcon:t=!1,...n},r)=>{const o=v.useMemo((()=>`${Math.floor(40*Math.random())+50}%`),[]);return G.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:we("flex h-8 items-center gap-xxs rounded-md px-xxs",e),...n,children:[t&&G.jsx(lO,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),G.jsx(lO,{className:"h-xxxs max-w-[--skeleton-width] flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})}));_Y.displayName="SidebarMenuSkeleton";const xY=v.forwardRef((({className:e,...t},n)=>G.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:we("flex min-w-0 translate-x-px flex-col gap-xxxs border-l border-sidebar-border","group-data-[collapsible=icon]:hidden",e),...t})));xY.displayName="SidebarMenuSub";const SY=v.forwardRef((({...e},t)=>G.jsx("li",{ref:t,...e})));SY.displayName="SidebarMenuSubItem";const EY=v.forwardRef((({asChild:e=!1,size:t="md",isActive:n,className:r,...o},a)=>{const i=e?yd:"a";return G.jsx(i,{ref:a,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:we("flex h-s min-w-0 -translate-x-px items-center gap-xxs overflow-hidden rounded-sm px-xxs text-sm text-gray-700 outline-none ring-sidebar-ring hover:bg-white hover:text-blue_100 focus-visible:ring-2 active:bg-white active:text-blue_100 disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-blue_100","data-[active=true]:bg-white data-[active=true]:text-blue_100","sm"===t&&"text-xs","md"===t&&"text-sm","group-data-[collapsible=icon]:hidden",r),...o})}));EY.displayName="SidebarMenuSubButton";const m3="Switch",[$Y,lZ]=ni(m3),[CY,IY]=$Y(m3),RY=v.forwardRef(((e,t)=>{const{__scopeSwitch:n,name:r,checked:o,defaultChecked:a,required:i,disabled:s,value:u="on",onCheckedChange:l,...c}=e,[d,f]=v.useState(null),p=Vt(t,(e=>f(e))),m=v.useRef(!1),h=!d||!!d.closest("form"),[g=!1,y]=fd({prop:o,defaultProp:a,onChange:l});return v.createElement(CY,{scope:n,checked:g,disabled:s},v.createElement(ft.button,Te({type:"button",role:"switch","aria-checked":g,"aria-required":i,"data-state":h3(g),"data-disabled":s?"":void 0,disabled:s,value:u},c,{ref:p,onClick:et(e.onClick,(e=>{y((e=>!e)),h&&(m.current=e.isPropagationStopped(),m.current||e.stopPropagation())}))})),h&&v.createElement(OY,{control:d,bubbles:!m.current,name:r,value:u,checked:g,required:i,disabled:s,style:{transform:"translateX(-100%)"}}))})),PY="SwitchThumb",TY=v.forwardRef(((e,t)=>{const{__scopeSwitch:n,...r}=e,o=IY(PY,n);return v.createElement(ft.span,Te({"data-state":h3(o.checked),"data-disabled":o.disabled?"":void 0},r,{ref:t}))})),OY=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,a=v.useRef(null),i=ky(n),s=Ly(t);return v.useEffect((()=>{const e=a.current,t=window.HTMLInputElement.prototype,o=Object.getOwnPropertyDescriptor(t,"checked").set;if(i!==n&&o){const t=new Event("click",{bubbles:r});o.call(e,n),e.dispatchEvent(t)}}),[i,n,r]),v.createElement("input",Te({type:"checkbox","aria-hidden":!0,defaultChecked:n},o,{tabIndex:-1,ref:a,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function h3(e){return e?"checked":"unchecked"}const v3=RY,AY=TY,MY=v.forwardRef((({className:e,...t},n)=>G.jsx(v3,{className:we("group peer inline-flex h-xs w-[44px] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background data-[state=checked]:bg-blue_100 data-[state=unchecked]:bg-gray-200","disabled:cursor-not-allowed disabled:!bg-gray-100 md:hover:data-[state=checked]:bg-blue_120 md:hover:data-[state=unchecked]:!bg-gray-300",e),...t,ref:n,children:G.jsx(AY,{className:we("pointer-events-none block size-xxs rounded-full bg-background shadow-lg ring-0 transition-[transform,width] data-[state=checked]:translate-x-[20px] data-[state=unchecked]:translate-x-0",{"md:group-hover:w-[26px] md:group-hover:data-[state=checked]:translate-x-[14px]":!t.disabled,"bg-gray-300":t.disabled})})})));MY.displayName=v3.displayName;var DY={USER:"teamcity",npm_config_user_agent:"npm/10.9.3 node/v22.18.0 linux x64 workspaces/true",SENTRY_AUTH_TOKEN:"1d93ff28a44e4c3aaaaff854277cd8583c1de670bd8744bc895670dfd9300840",npm_node_execpath:"/home/teamcity/.nvm/versions/node/v22.18.0/bin/node",npm_config_noproxy:"",HOME:"/home/teamcity",npm_package_json:"/mnt/agent/work/70fcd8585843667f/packages/network/package.json",npm_config_userconfig:"/home/teamcity/.npmrc",npm_config_local_prefix:"/mnt/agent/work/70fcd8585843667f",COLOR:"1",npm_config_progress:"",TEMP:"/mnt/agent/temp/buildTmp",npm_config_prefix:"/home/teamcity/.nvm/versions/node/v22.18.0",npm_config_npm_version:"10.9.3",npm_config_cache:"/home/teamcity/.npm",USE_NPM_LIBS:"false",npm_config_ignore_scripts:"true",npm_config_node_gyp:"/home/teamcity/.nvm/versions/node/v22.18.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js",PATH:"/mnt/agent/work/70fcd8585843667f/packages/network/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/packages/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.18.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.18.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/home/teamcity/.cargo/bin:/home/teamcity/.rvm/gems/ruby-3.3.9/bin:/home/teamcity/.rvm/gems/ruby-3.3.9@global/bin:/home/teamcity/.rvm/rubies/ruby-3.3.9/bin:/home/teamcity/.rvm/bin:/home/teamcity/.local/bin:/usr/lib/jvm/java-21-amazon-corretto/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin:/usr/share/dotnet:/usr/share/dotnet/tools:/home/teamcity/google-cloud-sdk/bin:/home/teamcity/go/bin:/usr/bin/mvn:/home/teamcity/.nvm/versions/node/v22.18.0/bin",TURBO_HASH:"7abe956a252e30a0",NODE:"/home/teamcity/.nvm/versions/node/v22.18.0/bin/node",npm_package_name:"@wellesley/network",npm_config_color:"always",DOMAIN_ENV:"test",LANG:"en_US.UTF-8",TURBO_TEAM:"wellesley",TMP:"/mnt/agent/temp/buildTmp",TURBO_API:"https://turborepo-remote-cache-fo3np.ondigitalocean.app",npm_lifecycle_script:"vite build",SHELL:"/bin/bash",npm_package_version:"1.0.704",npm_lifecycle_event:"build",TURBO_CACHE:"remote:rw",SENTRY_MAPS_UPLOAD:"true",npm_config_globalconfig:"/home/teamcity/.nvm/versions/node/v22.18.0/etc/npmrc",npm_config_init_module:"/home/teamcity/.npm-init.js",PWD:"/mnt/agent/work/70fcd8585843667f/packages/network",npm_execpath:"/home/teamcity/.nvm/versions/node/v22.18.0/lib/node_modules/npm/bin/npm-cli.js",npm_config_global_prefix:"/home/teamcity/.nvm/versions/node/v22.18.0",npm_command:"run-script",TURBO_TOKEN:"wellesley-turbo-token",USE_PACKAGES_FROM_NPM:"false",INIT_CWD:"/mnt/agent/work/70fcd8585843667f/packages/network",EDITOR:"vi",NODE_ENV:"production",BUILD_NUMBER:"3787",APP_NAME:"@wellesley/network"},g3=(e=>(e.uninitialized="uninitialized",e.pending="pending",e.fulfilled="fulfilled",e.rejected="rejected",e))(g3||{});function NY(e){return{status:e,isUninitialized:"uninitialized"===e,isLoading:"pending"===e,isSuccess:"fulfilled"===e,isError:"rejected"===e}}function kY(e){return new RegExp("(^|:)//").test(e)}var LY=e=>e.replace(/\/$/,""),FY=e=>e.replace(/^\//,"");function BY(e,t){if(!e)return t;if(!t)return e;if(kY(t))return t;const n=e.endsWith("/")||!t.startsWith("?")?"/":"";return`${e=LY(e)}${n}${t=FY(t)}`}var cO=e=>[].concat(...e);function jY(){return typeof navigator>"u"||void 0===navigator.onLine||navigator.onLine}function zY(){return typeof document>"u"||"hidden"!==document.visibilityState}var dO=ld;function y3(e,t){if(e===t||!(dO(e)&&dO(t)||Array.isArray(e)&&Array.isArray(t)))return t;const n=Object.keys(t),r=Object.keys(e);let o=n.length===r.length;const a=Array.isArray(t)?[]:{};for(const r of n)a[r]=y3(e[r],t[r]),o&&(o=e[r]===a[r]);return o?e:a}var fO=(...e)=>fetch(...e),VY=e=>e.status>=200&&e.status<=299,UY=e=>/ion\/(vnd\.api\+)?json/.test(e.get("content-type")||"");function pO(e){if(!ld(e))return e;const t={...e};for(const[e,n]of Object.entries(t))void 0===n&&delete t[e];return t}function WY({baseUrl:e,prepareHeaders:t=e=>e,fetchFn:n=fO,paramsSerializer:r,isJsonContentType:o=UY,jsonContentType:a="application/json",jsonReplacer:i,timeout:s,responseHandler:u,validateStatus:l,...c}={}){return typeof fetch>"u"&&n===fO&&console.warn("Warning: `fetch` is not available. Please supply a custom `fetchFn` property to use `fetchBaseQuery` on SSR environments."),async(f,p)=>{const{signal:m,getState:v,extra:h,endpoint:g,forced:y,type:b}=p;let w,{url:x,headers:_=new Headers(c.headers),params:E,responseHandler:S=u??"json",validateStatus:I=l??VY,timeout:A=s,...k}="string"==typeof f?{url:f}:f,C={...c,signal:m,...k};_=new Headers(pO(_)),C.headers=await t(_,{getState:v,extra:h,endpoint:g,forced:y,type:b})||_;const T=e=>"object"==typeof e&&(ld(e)||Array.isArray(e)||"function"==typeof e.toJSON);if(!C.headers.has("content-type")&&T(C.body)&&C.headers.set("content-type",a),T(C.body)&&o(C.headers)&&(C.body=JSON.stringify(C.body,i)),E){const e=~x.indexOf("?")?"&":"?";x+=e+(r?r(E):new URLSearchParams(pO(E)))}x=BY(e,x);const R=new Request(x,C);w={request:new Request(x,C)};let P,O=!1,N=A&&setTimeout((()=>{O=!0,p.abort()}),A);try{P=await n(R)}catch(e){return{error:{status:O?"TIMEOUT_ERROR":"FETCH_ERROR",error:String(e)},meta:w}}finally{N&&clearTimeout(N)}const M=P.clone();w.response=M;let j,D="";try{let e;if(await Promise.all([d(P,S).then((e=>j=e),(t=>e=t)),M.text().then((e=>D=e),(()=>{}))]),e)throw e}catch(e){return{error:{status:"PARSING_ERROR",originalStatus:P.status,data:D,error:String(e)},meta:w}}return I(P,j)?{data:j,meta:w}:{error:{status:P.status,data:j},meta:w}};async function d(e,t){if("function"==typeof t)return t(e);if("content-type"===t&&(t=o(e.headers)?"json":"text"),"json"===t){const t=await e.text();return t.length?JSON.parse(t):null}return e.text()}}var mO=class{constructor(e,t=void 0){this.value=e,this.meta=t}},H$=Vn("__rtkq/focused"),w3=Vn("__rtkq/unfocused"),K$=Vn("__rtkq/online"),b3=Vn("__rtkq/offline");function _3(e){return"query"===e.type}function qY(e){return"mutation"===e.type}function Y$(e,t,n,r,o,a){return GY(e)?e(t,n,r,o).map(oE).map(a):Array.isArray(e)?e.map(oE).map(a):[]}function GY(e){return"function"==typeof e}function oE(e){return"string"==typeof e?{type:e}:e}function hO(e){return null!=e}function Om(e){let t=0;for(const n in e)t++;return t}function HY(e,t){return e.catch(t)}var $v=Symbol("forceQueryFn"),iE=e=>"function"==typeof e[$v];function KY({serializeQueryArgs:e,queryThunk:t,mutationThunk:n,api:r,context:o}){const a=new Map,i=new Map,{unsubscribeQueryResult:s,removeMutationResult:u,updateSubscriptionOptions:l}=r.internalActions;return{buildInitiateQuery:function(n,o){const i=(u,{subscribe:c=!0,forceRefetch:d,subscriptionOptions:f,[$v]:p,...m}={})=>(v,h)=>{var g;const y=e({queryArgs:u,endpointDefinition:o,endpointName:n}),b=t({...m,type:"query",subscribe:c,forceRefetch:d,subscriptionOptions:f,endpointName:n,originalArgs:u,queryCacheKey:y,[$v]:p}),w=r.endpoints[n].select(u),x=v(b),_=w(h()),{requestId:E,abort:S}=x,I=_.requestId!==E,A=null==(g=a.get(v))?void 0:g[y],k=()=>w(h()),C=Object.assign(p?x.then(k):I&&!A?Promise.resolve(_):Promise.all([A,x]).then(k),{arg:u,requestId:E,subscriptionOptions:f,queryCacheKey:y,abort:S,async unwrap(){const e=await C;if(e.isError)throw e.error;return e.data},refetch:()=>v(i(u,{subscribe:!1,forceRefetch:!0})),unsubscribe(){c&&v(s({queryCacheKey:y,requestId:E}))},updateSubscriptionOptions(e){C.subscriptionOptions=e,v(l({endpointName:n,requestId:E,queryCacheKey:y,options:e}))}});if(!A&&!I&&!p){const e=a.get(v)||{};e[y]=C,a.set(v,e),C.then((()=>{delete e[y],Om(e)||a.delete(v)}))}return C};return i},buildInitiateMutation:function(e){return(t,{track:r=!0,fixedCacheKey:o}={})=>(a,s)=>{const l=n({type:"mutation",endpointName:e,originalArgs:t,track:r,fixedCacheKey:o}),c=a(l),{requestId:d,abort:f,unwrap:p}=c,m=HY(c.unwrap().then((e=>({data:e}))),(e=>({error:e}))),v=Object.assign(m,{arg:c.arg,requestId:d,abort:f,unwrap:p,reset:()=>{a(u({requestId:d,fixedCacheKey:o}))}}),h=i.get(a)||{};return i.set(a,h),h[d]=v,v.then((()=>{delete h[d],Om(h)||i.delete(a)})),o&&(h[o]=v,v.then((()=>{h[o]===v&&(delete h[o],Om(h)||i.delete(a))}))),v}},getRunningQueryThunk:function(t,n){return r=>{var i;const s=o.endpointDefinitions[t],u=e({queryArgs:n,endpointDefinition:s,endpointName:t});return null==(i=a.get(r))?void 0:i[u]}},getRunningMutationThunk:function(e,t){return e=>{var n;return null==(n=i.get(e))?void 0:n[t]}},getRunningQueriesThunk:function(){return e=>Object.values(a.get(e)||{}).filter(hO)},getRunningMutationsThunk:function(){return e=>Object.values(i.get(e)||{}).filter(hO)}}}function vO(e){return e}function YY({reducerPath:e,baseQuery:t,context:{endpointDefinitions:n},serializeQueryArgs:r,api:o,assertTagType:a}){const i=async(e,{signal:r,abort:o,rejectWithValue:a,fulfillWithValue:i,dispatch:u,getState:l,extra:c})=>{const d=n[e.endpointName];try{let n,a=vO;const f={signal:r,abort:o,dispatch:u,getState:l,extra:c,endpoint:e.endpointName,type:e.type,forced:"query"===e.type?s(e,l()):void 0},p="query"===e.type?e[$v]:void 0;if(p?n=p():d.query?(n=await t(d.query(e.originalArgs),f,d.extraOptions),d.transformResponse&&(a=d.transformResponse)):n=await d.queryFn(e.originalArgs,f,d.extraOptions,(e=>t(e,f,d.extraOptions))),typeof process<"u"&&DY.NODE_ENV,n.error)throw new mO(n.error,n.meta);return i(await a(n.data,n.meta,e.originalArgs),{fulfilledTimeStamp:Date.now(),baseQueryMeta:n.meta,[Yh]:!0})}catch(t){let n=t;if(n instanceof mO){let t=vO;d.query&&d.transformErrorResponse&&(t=d.transformErrorResponse);try{return a(await t(n.value,n.meta,e.originalArgs),{baseQueryMeta:n.meta,[Yh]:!0})}catch(e){n=e}}throw console.error(n),n}};function s(t,n){var r,o,a;const i=null==(o=null==(r=n[e])?void 0:r.queries)?void 0:o[t.queryCacheKey],s=null==(a=n[e])?void 0:a.config.refetchOnMountOrArgChange,u=null==i?void 0:i.fulfilledTimeStamp,l=t.forceRefetch??(t.subscribe&&s);return!!l&&(!0===l||(Number(new Date)-Number(u))/1e3>=l)}const u=vC(`${e}/executeQuery`,i,{getPendingMeta:()=>({startedTimeStamp:Date.now(),[Yh]:!0}),condition(t,{getState:r}){var o,a,i;const u=r(),l=null==(a=null==(o=u[e])?void 0:o.queries)?void 0:a[t.queryCacheKey],c=null==l?void 0:l.fulfilledTimeStamp,d=t.originalArgs,f=null==l?void 0:l.originalArgs,p=n[t.endpointName];return!!iE(t)||"pending"!==(null==l?void 0:l.status)&&(!!(s(t,u)||_3(p)&&null!=(i=null==p?void 0:p.forceRefetch)&&i.call(p,{currentArg:d,previousArg:f,endpointState:l,state:u}))||!c)},dispatchConditionRejection:!0}),l=vC(`${e}/executeMutation`,i,{getPendingMeta:()=>({startedTimeStamp:Date.now(),[Yh]:!0})});function c(e){return t=>{var n,r;return(null==(r=null==(n=null==t?void 0:t.meta)?void 0:n.arg)?void 0:r.endpointName)===e}}return{queryThunk:u,mutationThunk:l,prefetch:(e,t,n)=>(r,a)=>{const i=(e=>"force"in e)(n)&&n.force,s=(e=>"ifOlderThan"in e)(n)&&n.ifOlderThan,u=(n=!0)=>{const r={forceRefetch:n,isPrefetch:!0};return o.endpoints[e].initiate(t,r)},l=o.endpoints[e].select(t)(a());if(i)r(u());else if(s){const e=null==l?void 0:l.fulfilledTimeStamp;if(!e)return void r(u());(Number(new Date)-Number(new Date(e)))/1e3>=s&&r(u())}else r(u(!1))},updateQueryData:(e,t,n,r=!0)=>(a,i)=>{const s=o.endpoints[e].select(t)(i());let u,l={patches:[],inversePatches:[],undo:()=>a(o.util.patchQueryData(e,t,l.inversePatches,r))};if("uninitialized"===s.status)return l;if("data"in s)if(ys(s.data)){const[e,t,r]=GO(s.data,n);l.patches.push(...t),l.inversePatches.push(...r),u=e}else u=n(s.data),l.patches.push({op:"replace",path:[],value:u}),l.inversePatches.push({op:"replace",path:[],value:s.data});return a(o.util.patchQueryData(e,t,l.patches,r)),l},upsertQueryData:(e,t,n)=>r=>r(o.endpoints[e].initiate(t,{subscribe:!1,forceRefetch:!0,[$v]:()=>({data:n})})),patchQueryData:(e,t,i,s)=>(u,l)=>{const c=n[e],d=r({queryArgs:t,endpointDefinition:c,endpointName:e});if(u(o.internalActions.queryResultPatched({queryCacheKey:d,patches:i})),!s)return;const f=o.endpoints[e].select(t)(l()),p=Y$(c.providesTags,f.data,void 0,t,{},a);u(o.internalActions.updateProvidedBy({queryCacheKey:d,providedTags:p}))},buildMatchThunkActions:function(e,t){return{matchPending:nv(dE(e),c(t)),matchFulfilled:nv(dd(e),c(t)),matchRejected:nv(Mm(e),c(t))}}}}function x3(e,t,n,r){return Y$(n[e.meta.arg.endpointName][t],dd(e)?e.payload:void 0,py(e)?e.payload:void 0,e.meta.arg.originalArgs,"baseQueryMeta"in e.meta?e.meta.baseQueryMeta:void 0,r)}function kg(e,t,n){const r=e[t];r&&n(r)}function Cv(e){return("arg"in e?e.arg.fixedCacheKey:e.fixedCacheKey)??e.requestId}function gO(e,t,n){const r=e[Cv(t)];r&&n(r)}var Hh={};function QY({reducerPath:e,queryThunk:t,mutationThunk:n,context:{endpointDefinitions:r,apiUid:o,extractRehydrationInfo:a,hasRehydrationInfo:i},assertTagType:s,config:u}){const l=Vn(`${e}/resetApiState`),c=oo({name:`${e}/queries`,initialState:Hh,reducers:{removeQueryResult:{reducer(e,{payload:{queryCacheKey:t}}){delete e[t]},prepare:jh()},queryResultPatched:{reducer(e,{payload:{queryCacheKey:t,patches:n}}){kg(e,t,(e=>{e.data=dC(e.data,n.concat())}))},prepare:jh()}},extraReducers(e){e.addCase(t.pending,((e,{meta:t,meta:{arg:n}})=>{var r;const o=iE(n);e[r=n.queryCacheKey]??(e[r]={status:"uninitialized",endpointName:n.endpointName}),kg(e,n.queryCacheKey,(e=>{e.status="pending",e.requestId=o&&e.requestId?e.requestId:t.requestId,void 0!==n.originalArgs&&(e.originalArgs=n.originalArgs),e.startedTimeStamp=t.startedTimeStamp}))})).addCase(t.fulfilled,((e,{meta:t,payload:n})=>{kg(e,t.arg.queryCacheKey,(e=>{if(e.requestId!==t.requestId&&!iE(t.arg))return;const{merge:o}=r[t.arg.endpointName];if(e.status="fulfilled",o)if(void 0!==e.data){const{fulfilledTimeStamp:r,arg:a,baseQueryMeta:i,requestId:s}=t;let u=Pv(e.data,(e=>o(e,n,{arg:a.originalArgs,baseQueryMeta:i,fulfilledTimeStamp:r,requestId:s})));e.data=u}else e.data=n;else e.data=r[t.arg.endpointName].structuralSharing??1?y3(gs(e.data)?Z3(e.data):e.data,n):n;delete e.error,e.fulfilledTimeStamp=t.fulfilledTimeStamp}))})).addCase(t.rejected,((e,{meta:{condition:t,arg:n,requestId:r},error:o,payload:a})=>{kg(e,n.queryCacheKey,(e=>{if(!t){if(e.requestId!==r)return;e.status="rejected",e.error=a??o}}))})).addMatcher(i,((e,t)=>{const{queries:n}=a(t);for(const[t,r]of Object.entries(n))("fulfilled"===(null==r?void 0:r.status)||"rejected"===(null==r?void 0:r.status))&&(e[t]=r)}))}}),d=oo({name:`${e}/mutations`,initialState:Hh,reducers:{removeMutationResult:{reducer(e,{payload:t}){const n=Cv(t);n in e&&delete e[n]},prepare:jh()}},extraReducers(e){e.addCase(n.pending,((e,{meta:t,meta:{requestId:n,arg:r,startedTimeStamp:o}})=>{r.track&&(e[Cv(t)]={requestId:n,status:"pending",endpointName:r.endpointName,startedTimeStamp:o})})).addCase(n.fulfilled,((e,{payload:t,meta:n})=>{n.arg.track&&gO(e,n,(e=>{e.requestId===n.requestId&&(e.status="fulfilled",e.data=t,e.fulfilledTimeStamp=n.fulfilledTimeStamp)}))})).addCase(n.rejected,((e,{payload:t,error:n,meta:r})=>{r.arg.track&&gO(e,r,(e=>{e.requestId===r.requestId&&(e.status="rejected",e.error=t??n)}))})).addMatcher(i,((e,t)=>{const{mutations:n}=a(t);for(const[t,r]of Object.entries(n))("fulfilled"===(null==r?void 0:r.status)||"rejected"===(null==r?void 0:r.status))&&t!==(null==r?void 0:r.requestId)&&(e[t]=r)}))}}),f=oo({name:`${e}/invalidation`,initialState:Hh,reducers:{updateProvidedBy:{reducer(e,t){var n,r;const{queryCacheKey:o,providedTags:a}=t.payload;for(const t of Object.values(e))for(const e of Object.values(t)){const t=e.indexOf(o);-1!==t&&e.splice(t,1)}for(const{type:t,id:i}of a){const a=(n=e[t]??(e[t]={}))[r=i||"__internal_without_id"]??(n[r]=[]);a.includes(o)||a.push(o)}},prepare:jh()}},extraReducers(e){e.addCase(c.actions.removeQueryResult,((e,{payload:{queryCacheKey:t}})=>{for(const n of Object.values(e))for(const e of Object.values(n)){const n=e.indexOf(t);-1!==n&&e.splice(n,1)}})).addMatcher(i,((e,t)=>{var n,r;const{provided:o}=a(t);for(const[t,a]of Object.entries(o))for(const[o,i]of Object.entries(a)){const a=(n=e[t]??(e[t]={}))[r=o||"__internal_without_id"]??(n[r]=[]);for(const e of i)a.includes(e)||a.push(e)}})).addMatcher(cd(dd(t),py(t)),((e,t)=>{const n=x3(t,"providesTags",r,s),{queryCacheKey:o}=t.meta.arg;f.caseReducers.updateProvidedBy(e,f.actions.updateProvidedBy({queryCacheKey:o,providedTags:n}))}))}}),p=oo({name:`${e}/subscriptions`,initialState:Hh,reducers:{updateSubscriptionOptions(e,t){},unsubscribeQueryResult(e,t){},internal_getRTKQSubscriptions(){}}}),m=oo({name:`${e}/internalSubscriptions`,initialState:Hh,reducers:{subscriptionsUpdated:{reducer:(e,t)=>dC(e,t.payload),prepare:jh()}}}),v=oo({name:`${e}/config`,initialState:{online:jY(),focused:zY(),middlewareRegistered:!1,...u},reducers:{middlewareRegistered(e,{payload:t}){e.middlewareRegistered="conflict"!==e.middlewareRegistered&&o===t||"conflict"}},extraReducers:e=>{e.addCase(K$,(e=>{e.online=!0})).addCase(b3,(e=>{e.online=!1})).addCase(H$,(e=>{e.focused=!0})).addCase(w3,(e=>{e.focused=!1})).addMatcher(i,(e=>({...e})))}}),h=FO({queries:c.reducer,mutations:d.reducer,provided:f.reducer,subscriptions:m.reducer,config:v.reducer});return{reducer:(e,t)=>h(l.match(t)?void 0:e,t),actions:{...v.actions,...c.actions,...p.actions,...m.actions,...d.actions,...f.actions,resetApiState:l}}}var Ff=Symbol.for("RTKQ/skipToken"),S3={status:"uninitialized"},yO=Pv(S3,(()=>{})),wO=Pv(S3,(()=>{}));function XY({serializeQueryArgs:e,reducerPath:t,createSelector:n}){const r=e=>yO,o=e=>wO;return{buildQuerySelector:function(t,o){return s=>{const u=e({queryArgs:s,endpointDefinition:o,endpointName:t});return n(s===Ff?r:e=>{var t,n;return(null==(n=null==(t=i(e))?void 0:t.queries)?void 0:n[u])??yO},a)}},buildMutationSelector:function(){return e=>{let t;return t="object"==typeof e?Cv(e)??Ff:e,n(t===Ff?o:e=>{var n,r;return(null==(r=null==(n=i(e))?void 0:n.mutations)?void 0:r[t])??wO},a)}},selectInvalidatedBy:function(e,n){const r=e[t],o=new Set;for(const e of n.map(oE)){const t=r.provided[e.type];if(!t)continue;let n=(void 0!==e.id?t[e.id]:cO(Object.values(t)))??[];for(const e of n)o.add(e)}return cO(Array.from(o.values()).map((e=>{const t=r.queries[e];return t?[{queryCacheKey:e,endpointName:t.endpointName,originalArgs:t.originalArgs}]:[]})))},selectCachedArgsForQuery:function(e,n){return Object.values(e[t].queries).filter((e=>(null==e?void 0:e.endpointName)===n&&"uninitialized"!==e.status)).map((e=>e.originalArgs))}};function a(e){return{...e,...NY(e.status)}}function i(e){return e[t]}}var Sm=WeakMap?new WeakMap:void 0,bO=({endpointName:e,queryArgs:t})=>{let n="";const r=null==Sm?void 0:Sm.get(t);if("string"==typeof r)n=r;else{const e=JSON.stringify(t,((e,t)=>ld(t)?Object.keys(t).sort().reduce(((e,n)=>(e[n]=t[n],e)),{}):t));ld(t)&&(null==Sm||Sm.set(t,e)),n=e}return`${e}(${n})`};function JY(...e){return function(t){const n=fv((e=>{var n;return null==(n=t.extractRehydrationInfo)?void 0:n.call(t,e,{reducerPath:t.reducerPath??"api"})})),r={reducerPath:"api",keepUnusedDataFor:60,refetchOnMountOrArgChange:!1,refetchOnFocus:!1,refetchOnReconnect:!1,invalidationBehavior:"delayed",...t,extractRehydrationInfo:n,serializeQueryArgs(e){let n=bO;if("serializeQueryArgs"in e.endpointDefinition){const t=e.endpointDefinition.serializeQueryArgs;n=e=>{const n=t(e);return"string"==typeof n?n:bO({...e,queryArgs:n})}}else t.serializeQueryArgs&&(n=t.serializeQueryArgs);return n(e)},tagTypes:[...t.tagTypes||[]]},o={endpointDefinitions:{},batch(e){e()},apiUid:dy(),extractRehydrationInfo:n,hasRehydrationInfo:fv((e=>null!=n(e)))},a={injectEndpoints:function(e){const t=e.endpoints({query:e=>({...e,type:"query"}),mutation:e=>({...e,type:"mutation"})});for(const[n,r]of Object.entries(t))if(!0!==e.overrideExisting&&n in o.endpointDefinitions){if("throw"===e.overrideExisting)throw new Error($o(39))}else{o.endpointDefinitions[n]=r;for(const e of i)e.injectEndpoint(n,r)}return a},enhanceEndpoints({addTagTypes:e,endpoints:t}){if(e)for(const t of e)r.tagTypes.includes(t)||r.tagTypes.push(t);if(t)for(const[e,n]of Object.entries(t))"function"==typeof n?n(o.endpointDefinitions[e]):Object.assign(o.endpointDefinitions[e]||{},n);return a}},i=e.map((e=>e.init(a,r,o)));return a.injectEndpoints({endpoints:t.endpoints})}}function ZY(e){for(let t in e)return!1;return!0}var eQ=2147482.647,tQ=({reducerPath:e,api:t,context:n,internalState:r})=>{const{removeQueryResult:o,unsubscribeQueryResult:a}=t.internalActions;function i(e){const t=r.currentSubscriptions[e];return!!t&&!ZY(t)}const s={};function u(e,t,r,a){const u=n.endpointDefinitions[t],l=(null==u?void 0:u.keepUnusedDataFor)??a.keepUnusedDataFor;if(l===1/0)return;const c=Math.max(0,Math.min(l,eQ));if(!i(e)){const t=s[e];t&&clearTimeout(t),s[e]=setTimeout((()=>{i(e)||r.dispatch(o({queryCacheKey:e})),delete s[e]}),1e3*c)}}return(r,o,i)=>{var l;if(a.match(r)){const t=o.getState()[e],{queryCacheKey:n}=r.payload;u(n,null==(l=t.queries[n])?void 0:l.endpointName,o,t.config)}if(t.util.resetApiState.match(r))for(const[e,t]of Object.entries(s))t&&clearTimeout(t),delete s[e];if(n.hasRehydrationInfo(r)){const t=o.getState()[e],{queries:a}=n.extractRehydrationInfo(r);for(const[e,n]of Object.entries(a))u(e,null==n?void 0:n.endpointName,o,t.config)}}},nQ=({reducerPath:e,context:t,context:{endpointDefinitions:n},mutationThunk:r,queryThunk:o,api:a,assertTagType:i,refetchQuery:s,internalState:u})=>{const{removeQueryResult:l}=a.internalActions,c=cd(dd(r),py(r)),d=cd(dd(r,o),Mm(r,o));let f=[];function p(n,r){const o=r.getState(),i=o[e];if(f.push(...n),"delayed"===i.config.invalidationBehavior&&function(e){var t,n;for(const n in e.queries)if("pending"===(null==(t=e.queries[n])?void 0:t.status))return!0;for(const t in e.mutations)if("pending"===(null==(n=e.mutations[t])?void 0:n.status))return!0;return!1}(i))return;const c=f;if(f=[],0===c.length)return;const d=a.util.selectInvalidatedBy(o,c);t.batch((()=>{const e=Array.from(d.values());for(const{queryCacheKey:t}of e){const e=i.queries[t],n=u.currentSubscriptions[t]??{};e&&(0===Om(n)?r.dispatch(l({queryCacheKey:t})):"uninitialized"!==e.status&&r.dispatch(s(e,t)))}}))}return(e,t)=>{c(e)?p(x3(e,"invalidatesTags",n,i),t):d(e)?p([],t):a.util.invalidateTags.match(e)&&p(Y$(e.payload,void 0,void 0,void 0,void 0,i),t)}},rQ=({reducerPath:e,queryThunk:t,api:n,refetchQuery:r,internalState:o})=>{const a={};function i({queryCacheKey:t},n){const s=n.getState()[e],u=s.queries[t],c=o.currentSubscriptions[t];if(!u||"uninitialized"===u.status)return;const{lowestPollingInterval:d,skipPollingIfUnfocused:f}=l(c);if(!Number.isFinite(d))return;const p=a[t];null!=p&&p.timeout&&(clearTimeout(p.timeout),p.timeout=void 0);const m=Date.now()+d;a[t]={nextPollTimestamp:m,pollingInterval:d,timeout:setTimeout((()=>{(s.config.focused||!f)&&n.dispatch(r(u,t)),i({queryCacheKey:t},n)}),d)}}function s({queryCacheKey:t},n){const r=n.getState()[e].queries[t],s=o.currentSubscriptions[t];if(!r||"uninitialized"===r.status)return;const{lowestPollingInterval:c}=l(s);if(!Number.isFinite(c))return void u(t);const d=a[t],f=Date.now()+c;(!d||f<d.nextPollTimestamp)&&i({queryCacheKey:t},n)}function u(e){const t=a[e];null!=t&&t.timeout&&clearTimeout(t.timeout),delete a[e]}function l(e={}){let t=!1,n=Number.POSITIVE_INFINITY;for(let r in e)e[r].pollingInterval&&(n=Math.min(e[r].pollingInterval,n),t=e[r].skipPollingIfUnfocused||t);return{lowestPollingInterval:n,skipPollingIfUnfocused:t}}return(e,r)=>{(n.internalActions.updateSubscriptionOptions.match(e)||n.internalActions.unsubscribeQueryResult.match(e))&&s(e.payload,r),(t.pending.match(e)||t.rejected.match(e)&&e.meta.condition)&&s(e.meta.arg,r),(t.fulfilled.match(e)||t.rejected.match(e)&&!e.meta.condition)&&i(e.meta.arg,r),n.util.resetApiState.match(e)&&function(){for(const e of Object.keys(a))u(e)}()}},oQ=({reducerPath:e,context:t,api:n,refetchQuery:r,internalState:o})=>{const{removeQueryResult:a}=n.internalActions;function i(n,i){const s=n.getState()[e],u=s.queries,l=o.currentSubscriptions;t.batch((()=>{for(const e of Object.keys(l)){const t=u[e],o=l[e];o&&t&&((Object.values(o).some((e=>!0===e[i]))||Object.values(o).every((e=>void 0===e[i]))&&s.config[i])&&(0===Om(o)?n.dispatch(a({queryCacheKey:e})):"uninitialized"!==t.status&&n.dispatch(r(t,e))))}}))}return(e,t)=>{H$.match(e)&&i(t,"refetchOnFocus"),K$.match(e)&&i(t,"refetchOnReconnect")}},_O=new Error("Promise never resolved before cacheEntryRemoved."),iQ=({api:e,reducerPath:t,context:n,queryThunk:r,mutationThunk:o,internalState:a})=>{const i=$S(r),s=$S(o),u=dd(r,o),l={};function c(t,r,o,a,i){const s=n.endpointDefinitions[t],u=null==s?void 0:s.onCacheEntryAdded;if(!u)return;let c={};const d=new Promise((e=>{c.cacheEntryRemoved=e})),f=Promise.race([new Promise((e=>{c.valueResolved=e})),d.then((()=>{throw _O}))]);f.catch((()=>{})),l[o]=c;const p=e.endpoints[t].select("query"===s.type?r:o),m=a.dispatch(((e,t,n)=>n)),v={...a,getCacheEntry:()=>p(a.getState()),requestId:i,extra:m,updateCachedData:"query"===s.type?n=>a.dispatch(e.util.updateQueryData(t,r,n)):void 0,cacheDataLoaded:f,cacheEntryRemoved:d},h=u(r,v);Promise.resolve(h).catch((e=>{if(e!==_O)throw e}))}return(n,a,d)=>{const f=function(t){return i(t)?t.meta.arg.queryCacheKey:s(t)?t.meta.arg.fixedCacheKey??t.meta.requestId:e.internalActions.removeQueryResult.match(t)?t.payload.queryCacheKey:e.internalActions.removeMutationResult.match(t)?Cv(t.payload):""}(n);if(r.pending.match(n)){const e=d[t].queries[f],r=a.getState()[t].queries[f];!e&&r&&c(n.meta.arg.endpointName,n.meta.arg.originalArgs,f,a,n.meta.requestId)}else if(o.pending.match(n))a.getState()[t].mutations[f]&&c(n.meta.arg.endpointName,n.meta.arg.originalArgs,f,a,n.meta.requestId);else if(u(n)){const e=l[f];null!=e&&e.valueResolved&&(e.valueResolved({data:n.payload,meta:n.meta.baseQueryMeta}),delete e.valueResolved)}else if(e.internalActions.removeQueryResult.match(n)||e.internalActions.removeMutationResult.match(n)){const e=l[f];e&&(delete l[f],e.cacheEntryRemoved())}else if(e.util.resetApiState.match(n))for(const[e,t]of Object.entries(l))delete l[e],t.cacheEntryRemoved()}},aQ=({api:e,context:t,queryThunk:n,mutationThunk:r})=>{const o=dE(n,r),a=Mm(n,r),i=dd(n,r),s={};return(n,r)=>{var u,l;if(o(n)){const{requestId:o,arg:{endpointName:a,originalArgs:i}}=n.meta,u=t.endpointDefinitions[a],l=null==u?void 0:u.onQueryStarted;if(l){const t={},n=new Promise(((e,n)=>{t.resolve=e,t.reject=n}));n.catch((()=>{})),s[o]=t;const c=e.endpoints[a].select("query"===u.type?i:o),d=r.dispatch(((e,t,n)=>n)),f={...r,getCacheEntry:()=>c(r.getState()),requestId:o,extra:d,updateCachedData:"query"===u.type?t=>r.dispatch(e.util.updateQueryData(a,i,t)):void 0,queryFulfilled:n};l(i,f)}}else if(i(n)){const{requestId:e,baseQueryMeta:t}=n.meta;null==(u=s[e])||u.resolve({data:n.payload,meta:t}),delete s[e]}else if(a(n)){const{requestId:e,rejectedWithValue:t,baseQueryMeta:r}=n.meta;null==(l=s[e])||l.reject({error:n.payload??n.error,isUnhandledError:!t,meta:r}),delete s[e]}}},sQ=({api:e,context:{apiUid:t},reducerPath:n})=>(n,r)=>{e.util.resetApiState.match(n)&&r.dispatch(e.internalActions.middlewareRegistered(t))},uQ=({api:e,queryThunk:t,internalState:n})=>{const r=`${e.reducerPath}/subscriptions`;let o=null,a=null;const{updateSubscriptionOptions:i,unsubscribeQueryResult:s}=e.internalActions,u=()=>n.currentSubscriptions,l={getSubscriptions:u,getSubscriptionCount:e=>Om(u()[e]??{}),isRequestSubscribed:(e,t)=>{var n;const r=u();return!(null==(n=null==r?void 0:r[e])||!n[t])}};return(u,c)=>{if(o||(o=JSON.parse(JSON.stringify(n.currentSubscriptions))),e.util.resetApiState.match(u))return o=n.currentSubscriptions={},a=null,[!0,!1];if(e.internalActions.internal_getRTKQSubscriptions.match(u))return[!1,l];const d=((n,r)=>{var o,a,u;if(i.match(r)){const{queryCacheKey:e,requestId:t,options:a}=r.payload;return null!=(o=null==n?void 0:n[e])&&o[t]&&(n[e][t]=a),!0}if(s.match(r)){const{queryCacheKey:e,requestId:t}=r.payload;return n[e]&&delete n[e][t],!0}if(e.internalActions.removeQueryResult.match(r))return delete n[r.payload.queryCacheKey],!0;if(t.pending.match(r)){const{meta:{arg:e,requestId:t}}=r,o=n[a=e.queryCacheKey]??(n[a]={});return o[`${t}_running`]={},e.subscribe&&(o[t]=e.subscriptionOptions??o[t]??{}),!0}let l=!1;if(t.fulfilled.match(r)||t.rejected.match(r)){const e=n[r.meta.arg.queryCacheKey]||{},t=`${r.meta.requestId}_running`;l||(l=!!e[t]),delete e[t]}if(t.rejected.match(r)){const{meta:{condition:e,arg:t,requestId:o}}=r;if(e&&t.subscribe){const e=n[u=t.queryCacheKey]??(n[u]={});e[o]=t.subscriptionOptions??e[o]??{},l=!0}}return l})(n.currentSubscriptions,u);let f=!0;if(d){a||(a=setTimeout((()=>{const t=JSON.parse(JSON.stringify(n.currentSubscriptions)),[,r]=GO(o,(()=>t));c.next(e.internalActions.subscriptionsUpdated(r)),o=t,a=null}),500));const i="string"==typeof u.type&&!!u.type.startsWith(r),s=t.rejected.match(u)&&u.meta.condition&&!!u.meta.arg.subscribe;f=!i&&!s}return[f,!1]}};function lQ(e){const{reducerPath:t,queryThunk:n,api:r,context:o}=e,{apiUid:a}=o,i={invalidateTags:Vn(`${t}/invalidateTags`)},s=e=>e.type.startsWith(`${t}/`),u=[sQ,tQ,nQ,rQ,iQ,aQ];return{middleware:n=>{let i=!1;const c={...e,internalState:{currentSubscriptions:{}},refetchQuery:l,isThisApiSliceAction:s},d=u.map((e=>e(c))),f=uQ(c),p=oQ(c);return e=>u=>{if(!BO(u))return e(u);i||(i=!0,n.dispatch(r.internalActions.middlewareRegistered(a)));const l={...n,next:e},c=n.getState(),[m,v]=f(u,l,c);let h;if(h=m?e(u):v,n.getState()[t]&&(p(u,l,c),s(u)||o.hasRehydrationInfo(u)))for(let e of d)e(u,l,c);return h}},actions:i};function l(e,t,r={}){return n({type:"query",endpointName:e.endpointName,originalArgs:e.originalArgs,subscribe:!1,forceRefetch:!0,queryCacheKey:t,...r})}}function rd(e,...t){return Object.assign(e,...t)}var xO=Symbol(),cQ=({createSelector:e=Zn}={})=>({name:xO,init(t,{baseQuery:n,tagTypes:r,reducerPath:o,serializeQueryArgs:a,keepUnusedDataFor:i,refetchOnMountOrArgChange:s,refetchOnFocus:u,refetchOnReconnect:l,invalidationBehavior:c},d){uL();const f=e=>e;Object.assign(t,{reducerPath:o,endpoints:{},internalActions:{onOnline:K$,onOffline:b3,onFocus:H$,onFocusLost:w3},util:{}});const{queryThunk:p,mutationThunk:m,patchQueryData:v,updateQueryData:h,upsertQueryData:g,prefetch:y,buildMatchThunkActions:b}=YY({baseQuery:n,reducerPath:o,context:d,api:t,serializeQueryArgs:a,assertTagType:f}),{reducer:w,actions:x}=QY({context:d,queryThunk:p,mutationThunk:m,reducerPath:o,assertTagType:f,config:{refetchOnFocus:u,refetchOnReconnect:l,refetchOnMountOrArgChange:s,keepUnusedDataFor:i,reducerPath:o,invalidationBehavior:c}});rd(t.util,{patchQueryData:v,updateQueryData:h,upsertQueryData:g,prefetch:y,resetApiState:x.resetApiState}),rd(t.internalActions,x);const{middleware:_,actions:E}=lQ({reducerPath:o,context:d,queryThunk:p,mutationThunk:m,api:t,assertTagType:f});rd(t.util,E),rd(t,{reducer:w,middleware:_});const{buildQuerySelector:S,buildMutationSelector:I,selectInvalidatedBy:A,selectCachedArgsForQuery:k}=XY({serializeQueryArgs:a,reducerPath:o,createSelector:e});rd(t.util,{selectInvalidatedBy:A,selectCachedArgsForQuery:k});const{buildInitiateQuery:C,buildInitiateMutation:T,getRunningMutationThunk:R,getRunningMutationsThunk:P,getRunningQueriesThunk:O,getRunningQueryThunk:N}=KY({queryThunk:p,mutationThunk:m,api:t,serializeQueryArgs:a,context:d});return rd(t.util,{getRunningMutationThunk:R,getRunningMutationsThunk:P,getRunningQueryThunk:N,getRunningQueriesThunk:O}),{name:xO,injectEndpoint(e,n){var r;const o=t;(r=o.endpoints)[e]??(r[e]={}),_3(n)?rd(o.endpoints[e],{name:e,select:S(e,n),initiate:C(e,n)},b(p,e)):qY(n)&&rd(o.endpoints[e],{name:e,select:I(),initiate:T(e)},b(m,e))}}}});function dQ(e){return"query"===e.type}function fQ(e){return"mutation"===e.type}function Lg(e,...t){return Object.assign(e,...t)}function cS(e){return e.replace(e[0],e[0].toUpperCase())}var Em=WeakMap?new WeakMap:void 0,pQ=({endpointName:e,queryArgs:t})=>{let n="";const r=null==Em?void 0:Em.get(t);if("string"==typeof r)n=r;else{const e=JSON.stringify(t,((e,t)=>ld(t)?Object.keys(t).sort().reduce(((e,n)=>(e[n]=t[n],e)),{}):t));ld(t)&&(null==Em||Em.set(t,e)),n=e}return`${e}(${n})`},dS=Symbol();function SO(e,t,n,r){const o=v.useMemo((()=>({queryArgs:e,serialized:"object"==typeof e?t({queryArgs:e,endpointDefinition:n,endpointName:r}):e})),[e,t,n,r]),a=v.useRef(o);return v.useEffect((()=>{a.current.serialized!==o.serialized&&(a.current=o)}),[o]),a.current.serialized===o.serialized?a.current.queryArgs:e}function fS(e){const t=v.useRef(e);return v.useEffect((()=>{rv(t.current,e)||(t.current=e)}),[e]),rv(t.current,e)?t.current:e}var mQ=typeof window<"u"&&window.document&&window.document.createElement?v.useLayoutEffect:v.useEffect,hQ=e=>e.isUninitialized?{...e,isUninitialized:!1,isFetching:!0,isLoading:void 0===e.data,status:g3.pending}:e;function vQ({api:e,moduleOptions:{batch:t,hooks:{useDispatch:n,useSelector:r,useStore:o},unstable__sideEffectsInRender:a,createSelector:i},serializeQueryArgs:s,context:u}){const l=a?e=>e():v.useEffect;return{buildQueryHooks:function(a){const d=(t,{refetchOnReconnect:r,refetchOnFocus:o,refetchOnMountOrArgChange:i,skip:s=!1,pollingInterval:c=0,skipPollingIfUnfocused:d=!1}={})=>{const{initiate:f}=e.endpoints[a],p=n(),m=v.useRef();if(!m.current){const t=p(e.internalActions.internal_getRTKQSubscriptions());m.current=t}const h=SO(s?Ff:t,pQ,u.endpointDefinitions[a],a),g=fS({refetchOnReconnect:r,refetchOnFocus:o,pollingInterval:c,skipPollingIfUnfocused:d}),y=v.useRef(!1),b=v.useRef();let{queryCacheKey:w,requestId:x}=b.current||{},_=!1;w&&x&&(_=m.current.isRequestSubscribed(w,x));const E=!_&&y.current;return l((()=>{y.current=_})),l((()=>{E&&(b.current=void 0)}),[E]),l((()=>{var e;const t=b.current;if(h===Ff)return null==t||t.unsubscribe(),void(b.current=void 0);const n=null==(e=b.current)?void 0:e.subscriptionOptions;if(t&&t.arg===h)g!==n&&t.updateSubscriptionOptions(g);else{null==t||t.unsubscribe();const e=p(f(h,{subscriptionOptions:g,forceRefetch:i}));b.current=e}}),[p,f,i,h,g,E]),v.useEffect((()=>()=>{var e;null==(e=b.current)||e.unsubscribe(),b.current=void 0}),[]),v.useMemo((()=>({refetch:()=>{var e;if(!b.current)throw new Error($o(38));return null==(e=b.current)?void 0:e.refetch()}})),[])},f=({refetchOnReconnect:r,refetchOnFocus:o,pollingInterval:i=0,skipPollingIfUnfocused:s=!1}={})=>{const{initiate:u}=e.endpoints[a],c=n(),[d,f]=v.useState(dS),p=v.useRef(),m=fS({refetchOnReconnect:r,refetchOnFocus:o,pollingInterval:i,skipPollingIfUnfocused:s});l((()=>{var e,t;const n=null==(e=p.current)?void 0:e.subscriptionOptions;m!==n&&(null==(t=p.current)||t.updateSubscriptionOptions(m))}),[m]);const h=v.useRef(m);l((()=>{h.current=m}),[m]);const g=v.useCallback((function(e,n=!1){let r;return t((()=>{var t;null==(t=p.current)||t.unsubscribe(),p.current=r=c(u(e,{subscriptionOptions:h.current,forceRefetch:!n})),f(e)})),r}),[c,u]);return v.useEffect((()=>()=>{var e;null==(e=null==p?void 0:p.current)||e.unsubscribe()}),[]),v.useEffect((()=>{d!==dS&&!p.current&&g(d,!0)}),[d,g]),v.useMemo((()=>[g,d]),[g,d])},p=(t,{skip:n=!1,selectFromResult:l}={})=>{const{select:d}=e.endpoints[a],f=SO(n?Ff:t,s,u.endpointDefinitions[a],a),p=v.useRef(),m=v.useMemo((()=>i([d(f),(e,t)=>t,e=>f],c,{memoizeOptions:{resultEqualityCheck:rv}})),[d,f]),h=v.useMemo((()=>l?i([m],l,{devModeChecks:{identityFunctionCheck:"never"}}):m),[m,l]),g=r((e=>h(e,p.current)),rv),y=o(),b=m(y.getState(),p.current);return mQ((()=>{p.current=b}),[b]),g};return{useQueryState:p,useQuerySubscription:d,useLazyQuerySubscription:f,useLazyQuery(e){const[t,n]=f(e),r=p(n,{...e,skip:n===dS}),o=v.useMemo((()=>({lastArg:n})),[n]);return v.useMemo((()=>[t,r,o]),[t,r,o])},useQuery(e,t){const n=d(e,t),r=p(e,{selectFromResult:e===Ff||null!=t&&t.skip?void 0:hQ,...t}),{data:o,status:a,isLoading:i,isSuccess:s,isError:u,error:l}=r;return v.useDebugValue({data:o,status:a,isLoading:i,isSuccess:s,isError:u,error:l}),v.useMemo((()=>({...r,...n})),[r,n])}}},buildMutationHook:function(o){return({selectFromResult:a,fixedCacheKey:s}={})=>{const{select:u,initiate:l}=e.endpoints[o],c=n(),[d,f]=v.useState();v.useEffect((()=>()=>{null!=d&&d.arg.fixedCacheKey||null==d||d.reset()}),[d]);const p=v.useCallback((function(e){const t=c(l(e,{fixedCacheKey:s}));return f(t),t}),[c,l,s]),{requestId:m}=d||{},h=v.useMemo((()=>u({fixedCacheKey:s,requestId:null==d?void 0:d.requestId})),[s,d,u]),g=v.useMemo((()=>a?i([h],a):h),[a,h]),y=r(g,rv),b=null==s?null==d?void 0:d.arg.originalArgs:void 0,w=v.useCallback((()=>{t((()=>{d&&f(void 0),s&&c(e.internalActions.removeMutationResult({requestId:m,fixedCacheKey:s}))}))}),[c,s,d,m]),{endpointName:x,data:_,status:E,isLoading:S,isSuccess:I,isError:A,error:k}=y;v.useDebugValue({endpointName:x,data:_,status:E,isLoading:S,isSuccess:I,isError:A,error:k});const C=v.useMemo((()=>({...y,originalArgs:b,reset:w})),[y,b,w]);return v.useMemo((()=>[p,C]),[p,C])}},usePrefetch:function(t,r){const o=n(),a=fS(r);return v.useCallback(((n,r)=>o(e.util.prefetch(t,n,{...a,...r}))),[t,o,a])}};function c(e,t,n){if(null!=t&&t.endpointName&&e.isUninitialized){const{endpointName:e}=t,r=u.endpointDefinitions[e];s({queryArgs:t.originalArgs,endpointDefinition:r,endpointName:e})===s({queryArgs:n,endpointDefinition:r,endpointName:e})&&(t=void 0)}let r=e.isSuccess?e.data:null==t?void 0:t.data;void 0===r&&(r=e.data);const o=void 0!==r,a=e.isLoading,i=!o&&a,l=e.isSuccess||a&&o;return{...e,data:r,currentData:e.data,isFetching:a,isLoading:i,isSuccess:l}}}var gQ=Symbol(),yQ=({batch:e=l5,hooks:t={useDispatch:hE,useSelector:vy,useStore:ZO},createSelector:n=Zn,unstable__sideEffectsInRender:r=!1,...o}={})=>({name:gQ,init(o,{serializeQueryArgs:a},i){const s=o,{buildQueryHooks:u,buildMutationHook:l,usePrefetch:c}=vQ({api:o,moduleOptions:{batch:e,hooks:t,unstable__sideEffectsInRender:r,createSelector:n},serializeQueryArgs:a,context:i});return Lg(s,{usePrefetch:c}),Lg(i,{batch:e}),{injectEndpoint(e,t){if(dQ(t)){const{useQuery:t,useLazyQuery:n,useLazyQuerySubscription:r,useQueryState:a,useQuerySubscription:i}=u(e);Lg(s.endpoints[e],{useQuery:t,useLazyQuery:n,useLazyQuerySubscription:r,useQueryState:a,useQuerySubscription:i}),o[`use${cS(e)}Query`]=t,o[`useLazy${cS(e)}Query`]=n}else if(fQ(t)){const t=l(e);Lg(s.endpoints[e],{useMutation:t}),o[`use${cS(e)}Mutation`]=t}}}}}),wQ=JY(cQ(),yQ());const E3=()=>I3()?location.hostname:location.hostname.replace(/\w\w\w\.|^/,"."),$3=e=>{const t=new Date;return t.setTime(t.getTime()+24*e*60*60*1e3),t.toUTCString()},C3=e=>Object.keys(e).reduce(((t,n)=>`${t}${n}${!0===e[n]?"":`=${e[n]}`};`),""),bQ=(e,t)=>{const n=Jy()?"":document.cookie,r=`; ${t||n}`.split(`; ${e}=`);if(2===r.length)return(r.pop()||"").replace("=","").split(";").shift()},_Q=(e,t)=>{Jy()||(document.cookie=C3({[e]:"",path:"/",domain:t||E3(),expires:"Thu, 01 Jan 1970 00:00:01 GMT"}))},xQ=["localhost","127.0.0.1","dev.localtest.me","wellesleydev.localtest.me"],I3=()=>xQ.includes(location.hostname),SQ=(e,t="",n=10,r)=>{Jy()||(document.cookie=C3({[e]:t,path:"/",domain:r||E3(),expires:$3(n),...!I3()&&{SameSite:"None",Secure:!0}}))},Q$={set:SQ,remove:_Q,get:bQ,getExpireDate:$3},X$="auth_token",R3=()=>Q$.get(X$)||void 0,EQ=e=>Q$.set(X$,e),$Q=()=>Q$.remove(X$),CQ=()=>!!R3(),J$={getToken:R3,setToken:EQ,removeToken:$Q,hasToken:CQ},IQ=e=>{J$.removeToken(),e(bH()),V$("user").clear()},RQ=e=>async(t,n,r)=>{const o=await e(t,n,r);return o.error&&[401].includes(o.error.status)&&IQ(n.dispatch),o},PQ=async(e,t=2e3)=>{for(;!e();)await new Promise((e=>setTimeout(e,t)))},TQ=5,OQ=e=>t=>!!e&&t.includes(e.status),EO=e=>new Promise((t=>setTimeout(t,1e3*e))),AQ=e=>async(t,n,r)=>{const o=(null==r?void 0:r.maxRetries)??5;await PQ((()=>n.getState().network.isOnline));let a=0;const i=async()=>{var s,u,l,c;const d=await e(t,n,r),f=d.error;if(a>=o)return d;a>0&&await EO(Math.pow(2,a)),a++;const p=OQ(f);switch(!0){case"mutation"===n.type:return d;case!navigator.onLine:case p([408,404]):case f&&"FETCH_ERROR"===(null==f?void 0:f.status):case f&&f.status>=500:return await i();case 429===(null==(s=null==d?void 0:d.error)?void 0:s.status):{const e=null==(c=null==(l=null==(u=d.meta)?void 0:u.response)?void 0:l.headers)?void 0:c.get("Retry-After");return await EO(+(e||"0")),await i()}default:return d}};return await i()},$O=Vn("requestOpenapiHydrationCacheHas"),CO=Vn("requestOpenapiHydrationCacheAdd"),IO=Vn("requestOpenapiHydrationCacheRemove"),RO=Vn("requestOpenapiHydrationCacheClear"),PO=Vn("sendOpenapiHydrationCacheResponse"),MQ=()=>Math.random().toString(16).slice(2),DQ=()=>{try{return!!Cm()&&window.location.origin!==window.parent.location.origin}catch{return!0}},Fg=()=>{const e=window.parent;return e.__wlsy_openapiHydrationCache||(e.__wlsy_openapiHydrationCache=new Set),e.__wlsy_openapiHydrationCache},Bg=new Set,NQ=()=>{const e=DQ(),t=new Map,n=(()=>{let n=null;return()=>{!e||n||(n=e3({sourceWindow:window.parent,onMessage:e=>{if(!PO.match(e))return;const{id:n,value:r,success:o,error:a}=e.payload,i=t.get(n);i&&(t.delete(n),window.clearTimeout(i.timeoutId),o?i.resolve(r):i.reject(new Error(a||"Unknown error")))},whitelist:[PO]}))}})(),r=(e,r)=>{const o=MQ();return new Promise(((a,i)=>{const s=window.setTimeout((()=>{t.delete(o),i(new Error("OpenAPI hydration cache request timed out"))}),8e3);t.set(o,{resolve:a,reject:i,timeoutId:s}),(e=>{n(),Zk({action:e,windowElement:window.parent,whitelist:[$O,CO,IO,RO]})})(e({id:o,...r}))}))};return{has:async t=>e?!!await r($O,{key:t}):(t=>Cm()&&!e?Fg().has(t):Bg.has(t))(t),add:async t=>{e?await r(CO,{key:t}):(t=>{!Cm()||e?Bg.add(t):Fg().add(t)})(t)},remove:async t=>{e?await r(IO,{key:t}):(t=>{!Cm()||e?Bg.delete(t):Fg().delete(t)})(t)},clear:async()=>{e?await r(RO,{}):!Cm()||e?Bg.clear():Fg().clear()}}},kQ=e=>"object"==typeof e&&null!==e,TO=NQ(),LQ=e=>async(t,n,r)=>{var o,a,i,s;if("mutation"===n.type)return e(t,n,r);const u=n.endpoint;if(!u||!(null!=r&&r.initialDataKey||null!=r&&r.initialDataKeyResolver||null!=r&&r.initialDataResolver))return e(t,n,r);const l=(null==(o=null==r?void 0:r.initialDataKeyResolver)?void 0:o.call(r,{endpoint:u,requestArgs:t}))??(null==r?void 0:r.initialDataKey),c=(null==(a=null==r?void 0:r.hydrationCacheKeyResolver)?void 0:a.call(r,{endpoint:u,requestArgs:t,initialDataKey:l}))??(l?`initialDataKey:${l}`:u);if(await TO.has(c))return e(t,n,r);const d=null==(i=n.getState().initialState)?void 0:i.value,f=(null==(s=null==r?void 0:r.initialDataResolver)?void 0:s.call(r,{endpoint:u,requestArgs:t,initialState:d}))??(()=>{if(l)return kQ(d)?d[l]:void 0})();return void 0===f?e(t,n,r):(await TO.add(c),{data:f})};var P3=(e=>(e.SERVER_RULES="serverRules",e.INVITE_PEOPLE="invitePeople",e))(P3||{});const t0="staticState",T3=V$(),Wg={path:"",baseUrl:"",search:""},FQ=e=>{if(!e)return Wg;try{return JSON.parse(decodeURIComponent(e))||Wg}catch(e){return ap.error("Error parsing static state",e),Wg}},O3=()=>new URLSearchParams(window.location.search).get(t0),BQ=({path:e,baseUrl:t,search:n}={})=>{const{pathname:r,origin:o,search:a}=window.location;return`${t0}=${encodeURIComponent(JSON.stringify({path:e||r,baseUrl:t||o,search:n||a}))}`},jQ=()=>{const e=O3();return e&&T3.setItem(t0,e),A3()},A3=()=>{try{const e=T3.getItem(t0)||O3();return FQ(e)}catch(e){return ap.error("Error parsing static state",e),Wg}},zQ={create:BQ,init:jQ,get:A3},VQ=async e=>{const t={};e.headers.forEach(((e,n)=>{t[n]=e}));return{body:["get","head"].includes(e.method.toLowerCase())?null:await(async()=>{try{return await e.text()}catch(e){return ap.error("No body or error reading body:",e),null}})(),headers:t,url:e.url,method:e.method,mode:e.mode,credentials:e.credentials,cache:e.cache,redirect:e.redirect,referrer:e.referrer,integrity:e.integrity}},UQ=e=>{const{url:t,status:n,statusText:r,headers:o,body:a}=e,i=new Response(JSON.stringify(a),{status:n,statusText:r,headers:o});return Object.defineProperties(i,{url:{value:t},type:{value:"cors"}}),i},WQ=async e=>{const t=crypto.randomUUID();return new Promise(((n,r)=>{const o=e3({onMessage:({payload:{id:e,response:r}})=>{t===e&&(null==o||o(),n(UQ(r)))},whitelist:[_K]});(async()=>{try{Zk({action:b2({id:t,options:await VQ(e)}),windowElement:window.parent,whitelist:[b2]})}catch(e){r(e)}})()}))};new EventTarget;const Z$=()=>{var e;try{return(null==(e=window.wellesley)?void 0:e.v1)||window.wellesley}catch(e){ap.error("Error getting window.wellesley:",e)}},qQ=e=>new Response(JSON.stringify(e),{status:200,statusText:"OK",headers:{"Content-Type":"application/json"}}),GQ=e=>{var t,n;if(e.url.includes("accounts/profile")){const e=null==(n=null==(t=Z$())?void 0:t.initialState)?void 0:n.currentAccount;return!(null==e||!e.selectedUserId)&&qQ(e)}},HQ=Object.freeze(Object.defineProperty({__proto__:null,userHandler:GQ},Symbol.toStringTag,{value:"Module"})),KQ=e=>Object.values(HQ).reduce(((t,n)=>t||n(e)),void 0),YQ=async e=>KQ(e)||await fetch(e),QQ=()=>e=>Cm()?WQ(e):YQ(e),XQ=zQ.get().baseUrl,JQ=XQ||"",ZQ=WY({fetchFn:QQ(),baseUrl:JQ,responseHandler:e=>{const t=e.headers.get("content-type");if(!(null==t?void 0:t.startsWith("application/json")))return e.text();try{return e.json()}catch{return e.text()}},prepareHeaders:e=>{const t=J$.getToken();return t&&e.set("authorization",`Bearer ${t}`),e}}),eX=RQ(LQ(AQ(ZQ))),tX=wQ({tagTypes:["Secure","Post","Follow","Like","Settings","UserSettings","RBAC","Rbac_Config","Admin_Apps","Admin_Platform_Data","Admin_Ai_Agents_Assignments","Admin_Users","Admin_Groups","Admin_Audit_Logs","Admin_Reports","Admin_Signup_Requests","Admin_Posts","Admin_Uploads","Admin_Roles","Admin_Jobs_Stats","Admin_Federation","Admin_Domain_Block","Admin_Custom_Emojis","Admin_Domain_Allow","Admin_Link_Service_Configure","Groups","Group_Channels","GroupMembers","GroupMembership","GroupRules","Group_Roles","Group_Join_Requests","Group_Apps","Group_Ai_Agents_Assignments","User_Apps","Account","Profile","UserNoHtml","Relationship","Bookmarks","Global_Search","Events","Event","EventAttendees",...Object.values(P3)],reducerPath:"openapi",baseQuery:eX,endpoints:()=>({})}),nX=tX.injectEndpoints({endpoints:e=>({getApiMetaCompat:e.query({query:()=>({url:"/api/meta/compat"})}),postApiV1AccountsAddReason:e.mutation({query:e=>({url:"/api/v1/accounts/add-reason",method:"POST",body:e.signupReasonParams})}),postApiV1AccountsAuthenticateEmail:e.mutation({query:e=>({url:"/api/v1/accounts/authenticate/email",method:"POST",body:e.authRequest})}),postApiV1AccountsAuthenticatePhone:e.mutation({query:e=>({url:"/api/v1/accounts/authenticate/phone",method:"POST",body:e.authPhoneRequest})}),putApiV1AccountsChangeName:e.mutation({query:e=>({url:"/api/v1/accounts/change/name",method:"PUT",params:{id:e.id,name:e.name,username:e.username}})}),postApiV1AccountsCheckCaptcha:e.mutation({query:e=>({url:"/api/v1/accounts/check-captcha",method:"POST",body:e.captchaVerificationParams})}),postApiV1AccountsConfirmEmail:e.mutation({query:e=>({url:"/api/v1/accounts/confirm-email",method:"POST",body:e.codeVerificationParams})}),postApiV1AccountsConfirmPhone:e.mutation({query:e=>({url:"/api/v1/accounts/confirm-phone",method:"POST",body:e.codeVerificationParams})}),deleteApiV1AccountsDelete:e.mutation({query:()=>({url:"/api/v1/accounts/delete",method:"DELETE"})}),postApiV1AccountsEmailChangeConfirm:e.mutation({query:e=>({url:"/api/v1/accounts/email/change/confirm",method:"POST",body:e.body})}),postApiV1AccountsEmailChangeRequest:e.mutation({query:e=>({url:"/api/v1/accounts/email/change/request",method:"POST",body:e.emailChangeRequest})}),putApiV1AccountsEmailChangeResendCode:e.mutation({query:()=>({url:"/api/v1/accounts/email/change/resend-code",method:"PUT"})}),postApiV1AccountsFinishCreating:e.mutation({query:e=>({url:"/api/v1/accounts/finish-creating",method:"POST",body:e.finishCreatingAccountParams,params:{htmlContent:e.htmlContent}})}),putApiV1AccountsGetTokenByHash:e.mutation({query:e=>({url:`/api/v1/accounts/get-token/${e.hash}`,method:"PUT"})}),postApiV1AccountsLoginsAddEmailPassword:e.mutation({query:e=>({url:"/api/v1/accounts/logins/add-email-password",method:"POST",body:e.addEmailRequest})}),postApiV1AccountsLoginsAddEmailPasswordConfirm:e.mutation({query:e=>({url:"/api/v1/accounts/logins/add-email-password/confirm",method:"POST",body:e.body})}),putApiV1AccountsLoginsAddEmailPasswordResendCode:e.mutation({query:()=>({url:"/api/v1/accounts/logins/add-email-password/resend-code",method:"PUT"})}),postApiV1AccountsLoginsAddPhone:e.mutation({query:e=>({url:"/api/v1/accounts/logins/add-phone",method:"POST",body:e.addPhoneRequest})}),deleteApiV1AccountsLoginsRemoveEmailPassword:e.mutation({query:()=>({url:"/api/v1/accounts/logins/remove-email-password",method:"DELETE"})}),deleteApiV1AccountsLoginsRemovePhone:e.mutation({query:()=>({url:"/api/v1/accounts/logins/remove-phone",method:"DELETE"})}),postApiV1AccountsPasswordChangeConfirm:e.mutation({query:e=>({url:"/api/v1/accounts/password/change/confirm",method:"POST",body:e.body})}),postApiV1AccountsPasswordChangeRequest:e.mutation({query:e=>({url:"/api/v1/accounts/password/change/request",method:"POST",body:e.passwordChangeRequest})}),putApiV1AccountsPasswordChangeResendCode:e.mutation({query:()=>({url:"/api/v1/accounts/password/change/resend-code",method:"PUT"})}),postApiV1AccountsPasswordRecover:e.mutation({query:e=>({url:"/api/v1/accounts/password/recover",method:"POST",body:e.passwordRecoveryRequest})}),postApiV1AccountsPasswordRecoverChange:e.mutation({query:e=>({url:"/api/v1/accounts/password/recover/change",method:"POST",body:e.passwordRecoveryChange})}),postApiV1AccountsPasswordRecoverCheckCode:e.mutation({query:e=>({url:"/api/v1/accounts/password/recover/check-code",method:"POST",body:e.passwordRecoveryCode})}),postApiV1AccountsPhoneChangeConfirmAuth:e.mutation({query:e=>({url:"/api/v1/accounts/phone/change/confirm/auth",method:"POST",body:e.body})}),postApiV1AccountsPhoneChangeConfirmNewPhone:e.mutation({query:e=>({url:"/api/v1/accounts/phone/change/confirm/new-phone",method:"POST",body:e.body})}),postApiV1AccountsPhoneChangeNewPhone:e.mutation({query:e=>({url:"/api/v1/accounts/phone/change/new-phone",method:"POST",body:e.addPhoneRequest})}),putApiV1AccountsPhoneChangeRequest:e.mutation({query:()=>({url:"/api/v1/accounts/phone/change/request",method:"PUT"})}),putApiV1AccountsPhoneChangeResendCodeAuth:e.mutation({query:()=>({url:"/api/v1/accounts/phone/change/resend-code/auth",method:"PUT"})}),putApiV1AccountsPhoneChangeResendCodeNewPhone:e.mutation({query:()=>({url:"/api/v1/accounts/phone/change/resend-code/new-phone",method:"PUT"})}),getApiV1AccountsProfile:e.query({query:e=>({url:"/api/v1/accounts/profile",params:{htmlContent:e.htmlContent}})}),putApiV1AccountsResendCodeByHash:e.mutation({query:e=>({url:`/api/v1/accounts/resend-code/${e.hash}`,method:"PUT"})}),putApiV1AccountsResendEmailByHash:e.mutation({query:e=>({url:`/api/v1/accounts/resend-email/${e.hash}`,method:"PUT"})}),postApiV1AccountsSignup:e.mutation({query:e=>({url:"/api/v1/accounts/signup",method:"POST",body:e.accountCreate})}),postApiV1AccountsSignupPhone:e.mutation({query:e=>({url:"/api/v1/accounts/signup-phone",method:"POST",body:e.phoneSignup})}),postApiV1AccountsUserReselectUser:e.mutation({query:e=>({url:"/api/v1/accounts/user/reselect-user",method:"POST",params:{userId:e.userId,userName:e.userName}})}),getApiV1AddressesSuggest:e.query({query:e=>({url:"/api/v1/addresses/suggest",params:{lang:e.lang,text:e.text}})}),getApiV1AdminAccountByAccountId:e.query({query:e=>({url:`/api/v1/admin/account/${e.accountId}`,params:{htmlContent:e.htmlContent}})}),getApiV1AdminAuditLog:e.query({query:e=>({url:"/api/v1/admin/audit_log",params:{accountId:e.accountId,action:e.action,appId:e.appId,domainSearch:e.domainSearch,email:e.email,group:e.group,groupId:e.groupId,lastId:e.lastId,limit:e.limit,offset:e.offset,ruleId:e.ruleId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId,username:e.username}})}),putApiV1AdminChangeEmail:e.mutation({query:e=>({url:"/api/v1/admin/change/email",method:"PUT",params:{email:e.email,id:e.id,username:e.username}})}),putApiV1AdminChangePassword:e.mutation({query:e=>({url:"/api/v1/admin/change/password",method:"PUT",params:{id:e.id,password:e.password,username:e.username}})}),putApiV1AdminChangeRoleAssign:e.mutation({query:e=>({url:"/api/v1/admin/change/role/assign",method:"PUT",params:{id:e.id,role:e.role,username:e.username,htmlContent:e.htmlContent}})}),putApiV1AdminChangeRoleRevoke:e.mutation({query:e=>({url:"/api/v1/admin/change/role/revoke",method:"PUT",params:{id:e.id,role:e.role,username:e.username,htmlContent:e.htmlContent}})}),postApiV1AdminClearApErrors:e.mutation({query:e=>({url:"/api/v1/admin/clear-ap-errors",method:"POST",params:{domain:e.domain}})}),postApiV1AdminCreateAccount:e.mutation({query:e=>({url:"/api/v1/admin/create-account",method:"POST",body:e.accountCreate,params:{htmlContent:e.htmlContent}})}),postApiV1AdminCreateUser:e.mutation({query:e=>({url:"/api/v1/admin/create-user",method:"POST",body:e.userCreate,params:{account_id:e.accountId,htmlContent:e.htmlContent}})}),deleteApiV1AdminDelete:e.mutation({query:e=>({url:"/api/v1/admin/delete",method:"DELETE",params:{email:e.email,id:e.id,username:e.username}})}),deleteApiV1AdminDeleteUser:e.mutation({query:e=>({url:"/api/v1/admin/delete-user",method:"DELETE",params:{id:e.id,username:e.username}})}),getApiV1AdminDomainAllow:e.query({query:e=>({url:"/api/v1/admin/domain-allow",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1AdminDomainAllow:e.mutation({query:e=>({url:"/api/v1/admin/domain-allow",method:"POST",body:e.allowedDomainReq})}),deleteApiV1AdminDomainAllowByDomain:e.mutation({query:e=>({url:`/api/v1/admin/domain-allow/${e.domain}`,method:"DELETE"})}),putApiV1AdminDomainBlock:e.mutation({query:e=>({url:"/api/v1/admin/domain-block",method:"PUT",body:e.blockDomainReq})}),getApiV1AdminDomainBlock:e.query({query:e=>({url:"/api/v1/admin/domain-block",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1AdminDomainBlock:e.mutation({query:e=>({url:"/api/v1/admin/domain-block",method:"POST",body:e.blockDomainReq})}),deleteApiV1AdminDomainBlockByDomain:e.mutation({query:e=>({url:`/api/v1/admin/domain-block/${e.domain}`,method:"DELETE"})}),getApiV1AdminEmailAllow:e.query({query:()=>({url:"/api/v1/admin/email-allow"})}),postApiV1AdminEmailAllow:e.mutation({query:e=>({url:"/api/v1/admin/email-allow",method:"POST",body:e.allowedDomainReq})}),deleteApiV1AdminEmailAllowByDomain:e.mutation({query:e=>({url:`/api/v1/admin/email-allow/${e.domain}`,method:"DELETE"})}),getApiV1AdminEmailBlock:e.query({query:()=>({url:"/api/v1/admin/email-block"})}),postApiV1AdminEmailBlock:e.mutation({query:e=>({url:"/api/v1/admin/email-block",method:"POST",body:e.blockEmailRequest})}),deleteApiV1AdminEmailBlockByPattern:e.mutation({query:e=>({url:`/api/v1/admin/email-block/${e.pattern}`,method:"DELETE"})}),getApiV1AdminFederation:e.query({query:e=>({url:"/api/v1/admin/federation",params:{blockState:e.blockState,lastId:e.lastId,limit:e.limit,offset:e.offset,search:e.search,sortBy:e.sortBy,sortOrder:e.sortOrder,unavailable:e.unavailable,untilId:e.untilId,warning:e.warning}})}),getApiV1AdminFederationMetricsOperations:e.query({query:e=>({url:"/api/v1/admin/federation/metrics/operations",params:{window:e.window}})}),getApiV1AdminFederationMetricsRunningAverageSingle:e.query({query:e=>({url:"/api/v1/admin/federation/metrics/running-average-single",params:{operation:e.operation,window:e.window}})}),getApiV1AdminFederationMetricsRunningAveragesAll:e.query({query:e=>({url:"/api/v1/admin/federation/metrics/running-averages-all",params:{operations:e.operations,window:e.window}})}),getApiV1AdminFederationByDomain:e.query({query:e=>({url:`/api/v1/admin/federation/${e.domain}`})}),postApiV1AdminFeedClearUserFeed:e.mutation({query:e=>({url:"/api/v1/admin/feed/clear-user-feed",method:"POST",params:{userId:e.userId,username:e.username}})}),getApiV1AdminFeedDiagnose:e.query({query:e=>({url:"/api/v1/admin/feed/diagnose",params:{limit:e.limit,skipExactMatch:e.skipExactMatch,skipFull:e.skipFull,skipOrderMismatch:e.skipOrderMismatch,userId:e.userId,username:e.username}})}),getApiV1AdminFeedMetricsGlobalAllOperation:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/global-all-operation",params:{window:e.window}})}),getApiV1AdminFeedMetricsGlobalSingle:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/global-single",params:{operation:e.operation,window:e.window}})}),getApiV1AdminFeedMetricsHistory:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/history",params:{limit:e.limit,operation:e.operation,userId:e.userId}})}),getApiV1AdminFeedMetricsHistoryAll:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/history/all",params:{limit:e.limit,userId:e.userId}})}),getApiV1AdminFeedMetricsRunningAverageSingle:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/running-average-single",params:{operation:e.operation,userId:e.userId,window:e.window}})}),getApiV1AdminFeedMetricsRunningAveragesAll:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/running-averages-all",params:{userId:e.userId,window:e.window}})}),getApiV1AdminFeedMetricsSlowestOperations:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/slowest-operations",params:{limit:e.limit,window:e.window}})}),getApiV1AdminFeedMetricsSlowestUsers:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/slowest-users",params:{limit:e.limit,operation:e.operation,window:e.window}})}),getApiV1AdminFeedMetricsSlowestUsersAll:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/slowest-users-all",params:{limit:e.limit,sortDesc:e.sortDesc,window:e.window}})}),getApiV1AdminFeedMetricsSlowestUsersSingle:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/slowest-users-single",params:{limit:e.limit,operation:e.operation,sortDesc:e.sortDesc,window:e.window}})}),getApiV1AdminFeedMetricsSummary:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/summary",params:{includeUserCounts:e.includeUserCounts,window:e.window}})}),getApiV1AdminFeedMetricsUserCountAll:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/user-count-all",params:{window:e.window}})}),getApiV1AdminFeedMetricsUserCountSingle:e.query({query:e=>({url:"/api/v1/admin/feed/metrics/user-count-single",params:{operation:e.operation,window:e.window}})}),postApiV1AdminFeedRegenerateUserFeed:e.mutation({query:e=>({url:"/api/v1/admin/feed/regenerate-user-feed",method:"POST",params:{clear:e.clear,userId:e.userId,username:e.username}})}),getApiV1AdminGroupsSearch:e.query({query:e=>({url:"/api/v1/admin/groups/search",params:{accountId:e.accountId,displayName:e.displayName,domain:e.domain,email:e.email,joinMode:e.joinMode,lastId:e.lastId,limit:e.limit,offset:e.offset,privacy:e.privacy,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId,username:e.username,visibility:e.visibility}})}),getApiV1AdminGroupsUserByUserId:e.query({query:e=>({url:`/api/v1/admin/groups/user/${e.userId}`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,roles:e.roles,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1AdminGroupsByAccountId:e.query({query:e=>({url:`/api/v1/admin/groups/${e.accountId}`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1AdminGroupsByGroupIdCategories:e.query({query:e=>({url:`/api/v1/admin/groups/${e.groupId}/categories`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1AdminGroupsByGroupIdChannels:e.query({query:e=>({url:`/api/v1/admin/groups/${e.groupId}/channels`})}),getApiV1AdminGroupsByGroupIdEvents:e.query({query:e=>({url:`/api/v1/admin/groups/${e.groupId}/events`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,withTranslation:e.withTranslation}})}),getApiV1AdminImpersonate:e.query({query:e=>({url:"/api/v1/admin/impersonate",params:{username:e.username}})}),getApiV1AdminLinkService:e.query({query:()=>({url:"/api/v1/admin/link-service"})}),postApiV1AdminLinkServiceConfigure:e.mutation({query:e=>({url:"/api/v1/admin/link-service/configure",method:"POST",body:e.configureRequest})}),postApiV1AdminPostsDelete:e.mutation({query:e=>({url:"/api/v1/admin/posts/delete",method:"POST",body:e.postDelete})}),deleteApiV1AdminPurge:e.mutation({query:e=>({url:"/api/v1/admin/purge",method:"DELETE",params:{id:e.id}})}),postApiV1AdminRegenerateKeys:e.mutation({query:e=>({url:"/api/v1/admin/regenerate-keys",method:"POST",params:{userId:e.userId,username:e.username}})}),postApiV1AdminRegenerateKeysAll:e.mutation({query:e=>({url:"/api/v1/admin/regenerate-keys-all",method:"POST",params:{batch:e.batch}})}),postApiV1AdminReleaseUsername:e.mutation({query:e=>({url:"/api/v1/admin/release-username",method:"POST",params:{username:e.username}})}),postApiV1AdminReportsDeletePosts:e.mutation({query:e=>({url:"/api/v1/admin/reports/delete-posts",method:"POST",body:e.body})}),getApiV1AdminReportsList:e.query({query:e=>({url:"/api/v1/admin/reports/list",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,open:e.open,postId:e.postId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId}})}),getApiV1AdminReportsByReportId:e.query({query:e=>({url:`/api/v1/admin/reports/${e.reportId}`})}),postApiV1AdminReportsByReportIdAddNote:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/add-note`,method:"POST",body:e.body})}),postApiV1AdminReportsByReportIdAssignToSelf:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/assign-to-self`,method:"POST"})}),deleteApiV1AdminReportsByReportIdDelete:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/delete`,method:"DELETE"})}),postApiV1AdminReportsByReportIdRemoveNote:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/remove-note`,method:"POST",params:{index:e.index}})}),postApiV1AdminReportsByReportIdReopen:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/reopen`,method:"POST"})}),postApiV1AdminReportsByReportIdResolve:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/resolve`,method:"POST"})}),postApiV1AdminReportsByReportIdUnassign:e.mutation({query:e=>({url:`/api/v1/admin/reports/${e.reportId}/unassign`,method:"POST"})}),postApiV1AdminRestartApDelivery:e.mutation({query:e=>({url:"/api/v1/admin/restart-ap-delivery",method:"POST",params:{domain:e.domain}})}),getApiV1AdminSearch:e.query({query:e=>({url:"/api/v1/admin/search",params:{accountId:e.accountId,actorType:e.actorType,country:e.country,displayName:e.displayName,domain:e.domain,email:e.email,ip:e.ip,kind:e.kind,lastId:e.lastId,limit:e.limit,offset:e.offset,role:e.role,search:e.search,sortBy:e.sortBy,sortOrder:e.sortOrder,state:e.state,untilId:e.untilId,userId:e.userId,username:e.username}})}),putApiV1AdminSignupRequestsApproveByHash:e.mutation({query:e=>({url:`/api/v1/admin/signup_requests/approve/${e.hash}`,method:"PUT"})}),deleteApiV1AdminSignupRequestsDeleteByHash:e.mutation({query:e=>({url:`/api/v1/admin/signup_requests/delete/${e.hash}`,method:"DELETE"})}),getApiV1AdminSignupRequestsList:e.query({query:e=>({url:"/api/v1/admin/signup_requests/list",params:{email:e.email,hash:e.hash,ip:e.ip,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),putApiV1AdminSignupRequestsRejectByHash:e.mutation({query:e=>({url:`/api/v1/admin/signup_requests/reject/${e.hash}`,method:"PUT",params:{reason:e.reason}})}),getApiV1AdminUploadsJobsQueueByQueueName:e.query({query:e=>({url:`/api/v1/admin/uploads/jobs/queue/${e.queueName}`,params:{limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,uploadType:e.uploadType}})}),getApiV1AdminUploadsJobsSummary:e.query({query:()=>({url:"/api/v1/admin/uploads/jobs/summary"})}),getApiV1AdminUploadsSearch:e.query({query:e=>({url:"/api/v1/admin/uploads/search",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,tag:e.tag,untilId:e.untilId,uploadType:e.uploadType,userId:e.userId}})}),getApiV1AdminUploadsStorageByUserId:e.query({query:e=>({url:`/api/v1/admin/uploads/storage/${e.userId}`})}),postApiV1AdminUserChangeState:e.mutation({query:e=>({url:"/api/v1/admin/user/change-state",method:"POST",body:e.changeUserState})}),postApiV1AdminUserChangeStateBulk:e.mutation({query:e=>({url:"/api/v1/admin/user/change-state-bulk",method:"POST",body:e.changeUserStateBulk})}),getApiV1AdminUserByUserId:e.query({query:e=>({url:`/api/v1/admin/user/${e.userId}`})}),getApiV1AiAgentsAssignments:e.query({query:e=>({url:"/api/v1/ai-agents/assignments",params:{resourceId:e.resourceId,type:e.type}})}),deleteApiV1AiAgentsAssignments:e.mutation({query:e=>({url:"/api/v1/ai-agents/assignments",method:"DELETE",params:{id:e.id}})}),postApiV1AiAgentsAssignments:e.mutation({query:e=>({url:"/api/v1/ai-agents/assignments",method:"POST",body:e.aiAgentAssignmentCreate})}),getApiV1AiAgentsPosts:e.query({query:e=>({url:"/api/v1/ai-agents/posts",params:{limit:e.limit,ownerId:e.ownerId,since:e.since,htmlContent:e.htmlContent}})}),getApiV1AiModels:e.query({query:e=>({url:"/api/v1/ai-models",params:{capabilities:e.capabilities,deprecated:e.deprecated,enabled:e.enabled,maxContextWindow:e.maxContextWindow,maxInputPrice:e.maxInputPrice,maxMaxOutputTokens:e.maxMaxOutputTokens,maxOutputPrice:e.maxOutputPrice,minContextWindow:e.minContextWindow,minMaxOutputTokens:e.minMaxOutputTokens,modalities:e.modalities,openWeights:e.openWeights,page:e.page,pageSize:e.pageSize,providerId:e.providerId,search:e.search}})}),putApiV1AiModelsByModelId:e.mutation({query:e=>({url:`/api/v1/ai-models/${e.modelId}`,method:"PUT",body:e.aiModelUpdate,params:{scope:e.scope}})}),getApiV1AiModelsByModelId:e.query({query:e=>({url:`/api/v1/ai-models/${e.modelId}`})}),deleteApiV1AiModelsByModelId:e.mutation({query:e=>({url:`/api/v1/ai-models/${e.modelId}`,method:"DELETE",params:{scope:e.scope}})}),getApiV1AiModelsByModelIdMigrationPath:e.query({query:e=>({url:`/api/v1/ai-models/${e.modelId}/migration-path`})}),getApiV1AiModelsByModelIdResolve:e.query({query:e=>({url:`/api/v1/ai-models/${e.modelId}/resolve`})}),getApiV1AiProviders:e.query({query:e=>({url:"/api/v1/ai-providers",params:{enabledOnly:e.enabledOnly,scope:e.scope}})}),postApiV1AiProviders:e.mutation({query:e=>({url:"/api/v1/ai-providers",method:"POST",body:e.aiProviderCreate,params:{scope:e.scope}})}),putApiV1AiProvidersByProviderId:e.mutation({query:e=>({url:`/api/v1/ai-providers/${e.providerId}`,method:"PUT",body:e.aiProviderUpdate,params:{scope:e.scope}})}),getApiV1AiProvidersByProviderId:e.query({query:e=>({url:`/api/v1/ai-providers/${e.providerId}`,params:{scope:e.scope}})}),deleteApiV1AiProvidersByProviderId:e.mutation({query:e=>({url:`/api/v1/ai-providers/${e.providerId}`,method:"DELETE",params:{scope:e.scope}})}),getApiV1AiProvidersByProviderIdModels:e.query({query:e=>({url:`/api/v1/ai-providers/${e.providerId}/models`,params:{enabledOnly:e.enabledOnly,includeDeprecated:e.includeDeprecated}})}),postApiV1AiProvidersByProviderIdModels:e.mutation({query:e=>({url:`/api/v1/ai-providers/${e.providerId}/models`,method:"POST",body:e.aiModelCreate,params:{scope:e.scope}})}),postApiV1Apps:e.mutation({query:e=>({url:"/api/v1/apps",method:"POST",body:e.body,params:{enable:e.enable}})}),getApiV1Apps:e.query({query:()=>({url:"/api/v1/apps"})}),getApiV1AppsEnabled:e.query({query:()=>({url:"/api/v1/apps/enabled"})}),getApiV1AppsInstalled:e.query({query:()=>({url:"/api/v1/apps/installed"})}),getApiV1AppsUser:e.query({query:()=>({url:"/api/v1/apps/user"})}),deleteApiV1AppsUserByAppId:e.mutation({query:e=>({url:`/api/v1/apps/user/${e.appId}`,method:"DELETE"})}),putApiV1AppsUserByAppId:e.mutation({query:e=>({url:`/api/v1/apps/user/${e.appId}`,method:"PUT"})}),putApiV1AppsByAppId:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}`,method:"PUT",body:e.body,params:{enable:e.enable}})}),getApiV1AppsByAppId:e.query({query:e=>({url:`/api/v1/apps/${e.appId}`})}),deleteApiV1AppsByAppId:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}`,method:"DELETE"})}),getApiV1AppsByAppIdData:e.query({query:e=>({url:`/api/v1/apps/${e.appId}/data`,params:{owner:e.owner,tags:e.tags,type:e.type}})}),postApiV1AppsByAppIdData:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/data`,method:"POST",body:e.dataCreate})}),putApiV1AppsByAppIdDataAndId:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/data/${e.id}`,method:"PUT",body:e.dataCreate})}),deleteApiV1AppsByAppIdDataAndId:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/data/${e.id}`,method:"DELETE"})}),putApiV1AppsByAppIdDefault:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/default`,method:"PUT"})}),putApiV1AppsByAppIdDisable:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/disable`,method:"PUT"})}),putApiV1AppsByAppIdEnable:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/enable`,method:"PUT"})}),getApiV1AppsByAppIdStats:e.query({query:e=>({url:`/api/v1/apps/${e.appId}/stats`})}),putApiV1AppsByAppIdUserDefault:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/user-default`,method:"PUT"})}),deleteApiV1AppsByAppIdUserDefault:e.mutation({query:e=>({url:`/api/v1/apps/${e.appId}/user-default`,method:"DELETE"})}),getApiV1Block:e.query({query:e=>({url:"/api/v1/block",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1BlockBy:e.query({query:e=>({url:"/api/v1/block/by",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),deleteApiV1BlockByUserId:e.mutation({query:e=>({url:`/api/v1/block/${e.userId}`,method:"DELETE"})}),postApiV1BlockByUserId:e.mutation({query:e=>({url:`/api/v1/block/${e.userId}`,method:"POST"})}),getApiV1CustomEmojis:e.query({query:e=>({url:"/api/v1/custom_emojis",params:{category:e.category,lastId:e.lastId,limit:e.limit,offset:e.offset,shortcode:e.shortcode,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),deleteApiV1CustomEmojis:e.mutation({query:e=>({url:"/api/v1/custom_emojis",method:"DELETE",params:{category:e.category,shortcode:e.shortcode}})}),postApiV1CustomEmojis:e.mutation({query:e=>({url:"/api/v1/custom_emojis",method:"POST",body:e.emoji,params:{overwrite:e.overwrite}})}),getApiV1CustomEmojisCategories:e.query({query:e=>({url:"/api/v1/custom_emojis/categories",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1CustomEmojisExport:e.query({query:e=>({url:"/api/v1/custom_emojis/export",params:{category:e.category}})}),postApiV1CustomEmojisImport:e.mutation({query:e=>({url:"/api/v1/custom_emojis/import",method:"POST",body:e.body,params:{category:e.category,domain:e.domain,overwrite:e.overwrite,visible:e.visible}})}),postApiV1CustomEmojisImportUpload:e.mutation({query:e=>({url:"/api/v1/custom_emojis/import/upload",method:"POST",params:{category:e.category,domain:e.domain,overwrite:e.overwrite,uploadId:e.uploadId,visible:e.visible}})}),getApiV1CustomEmojisSearch:e.query({query:e=>({url:"/api/v1/custom_emojis/search",params:{category:e.category,lastId:e.lastId,limit:e.limit,offset:e.offset,shortcode:e.shortcode,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1CustomEmojisUpload:e.mutation({query:e=>({url:"/api/v1/custom_emojis/upload",method:"POST",params:{category:e.category,domain:e.domain,overwrite:e.overwrite,shortcode:e.shortcode,uploadId:e.uploadId,visible:e.visible}})}),patchApiV1CustomEmojisByShortcode:e.mutation({query:e=>({url:`/api/v1/custom_emojis/${e.shortcode}`,method:"PATCH",body:e.emojiPatchRequest})}),getApiV1Data:e.query({query:e=>({url:"/api/v1/data",params:{owner:e.owner,tags:e.tags,type:e.type}})}),postApiV1Data:e.mutation({query:e=>({url:"/api/v1/data",method:"POST",body:e.dataCreate})}),putApiV1DataById:e.mutation({query:e=>({url:`/api/v1/data/${e.id}`,method:"PUT",body:e.dataCreate})}),deleteApiV1DataById:e.mutation({query:e=>({url:`/api/v1/data/${e.id}`,method:"DELETE"})}),putApiV1Devices:e.mutation({query:e=>({url:"/api/v1/devices",method:"PUT",body:e.deviceRegistrationRequest})}),getApiV1Devices:e.query({query:()=>({url:"/api/v1/devices"})}),deleteApiV1DevicesAll:e.mutation({query:()=>({url:"/api/v1/devices/all",method:"DELETE"})}),getApiV1DevicesVapidPublicKey:e.query({query:()=>({url:"/api/v1/devices/vapid-public-key"})}),deleteApiV1DevicesByDeviceId:e.mutation({query:e=>({url:`/api/v1/devices/${e.deviceId}`,method:"DELETE"})}),getApiV1DomainBlock:e.query({query:e=>({url:"/api/v1/domain-block",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1Drafts:e.query({query:e=>({url:"/api/v1/drafts",params:{ownerId:e.ownerId}})}),postApiV1Drafts:e.mutation({query:e=>({url:"/api/v1/drafts",method:"POST",body:e.createDraftRequest,params:{ownerId:e.ownerId}})}),getApiV1DraftsPostByPostId:e.query({query:e=>({url:`/api/v1/drafts/post/${e.postId}`})}),putApiV1DraftsByDraftId:e.mutation({query:e=>({url:`/api/v1/drafts/${e.draftId}`,method:"PUT",body:e.updateDraftRequest})}),getApiV1DraftsByDraftId:e.query({query:e=>({url:`/api/v1/drafts/${e.draftId}`})}),deleteApiV1DraftsByDraftId:e.mutation({query:e=>({url:`/api/v1/drafts/${e.draftId}`,method:"DELETE"})}),postApiV1DraftsByDraftIdPublish:e.mutation({query:e=>({url:`/api/v1/drafts/${e.draftId}/publish`,method:"POST",params:{htmlContent:e.htmlContent}})}),getApiV1Events:e.query({query:e=>({url:"/api/v1/events",params:{groupId:e.groupId,limit:e.limit,offset:e.offset,organizerId:e.organizerId,username:e.username,withTranslation:e.withTranslation}})}),postApiV1Events:e.mutation({query:e=>({url:"/api/v1/events",method:"POST",body:e.createEvent})}),getApiV1EventsCalendarGByGroupnameIcs:e.query({query:e=>({url:`/api/v1/events/calendar/g/${e.groupname}.ics`})}),getApiV1EventsCalendarPByIdIcs:e.query({query:e=>({url:`/api/v1/events/calendar/p/${e.id}.ics`})}),getApiV1EventsCalendarUByUsernameIcs:e.query({query:e=>({url:`/api/v1/events/calendar/u/${e.username}.ics`})}),getApiV1EventsFollowing:e.query({query:e=>({url:"/api/v1/events/following",params:{limit:e.limit,offset:e.offset,withTranslation:e.withTranslation}})}),getApiV1EventsMy:e.query({query:e=>({url:"/api/v1/events/my",params:{limit:e.limit,notRespondedOnly:e.notRespondedOnly,offset:e.offset,organizedOnly:e.organizedOnly,past:e.past,withTranslation:e.withTranslation}})}),getApiV1EventsSettings:e.query({query:e=>({url:"/api/v1/events/settings",params:{ownerId:e.ownerId}})}),postApiV1EventsSettingsRegeneratePrivateId:e.mutation({query:e=>({url:"/api/v1/events/settings/regeneratePrivateId",method:"POST",params:{ownerId:e.ownerId}})}),postApiV1EventsSettingsUpdate:e.mutation({query:e=>({url:"/api/v1/events/settings/update",method:"POST",body:e.updateEventsSettings,params:{ownerId:e.ownerId}})}),putApiV1EventsByEventId:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}`,method:"PUT",body:e.updateEvent})}),getApiV1EventsByEventId:e.query({query:e=>({url:`/api/v1/events/${e.eventId}`,params:{withTranslation:e.withTranslation}})}),deleteApiV1EventsByEventId:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}`,method:"DELETE"})}),getApiV1EventsByEventIdIcs:e.query({query:e=>({url:`/api/v1/events/${e.eventId}.ics`})}),postApiV1EventsByEventIdAccept:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/accept`,method:"POST"})}),getApiV1EventsByEventIdAttendees:e.query({query:e=>({url:`/api/v1/events/${e.eventId}/attendees`,params:{limit:e.limit,offset:e.offset}})}),deleteApiV1EventsByEventIdAttendeesAndUserId:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/attendees/${e.userId}`,method:"DELETE"})}),postApiV1EventsByEventIdAttendeesAndUserId:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/attendees/${e.userId}`,method:"POST"})}),postApiV1EventsByEventIdCancel:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/cancel`,method:"POST"})}),postApiV1EventsByEventIdInterested:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/interested`,method:"POST"})}),postApiV1EventsByEventIdJoin:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/join`,method:"POST"})}),deleteApiV1EventsByEventIdJoinOrInterested:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/joinOrInterested`,method:"DELETE"})}),postApiV1EventsByEventIdMaybe:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/maybe`,method:"POST"})}),getApiV1EventsByEventIdMutual:e.query({query:e=>({url:`/api/v1/events/${e.eventId}/mutual`,params:{limit:e.limit,offset:e.offset}})}),postApiV1EventsByEventIdReject:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/reject`,method:"POST"})}),postApiV1EventsByEventIdTranslate:e.mutation({query:e=>({url:`/api/v1/events/${e.eventId}/translate`,method:"POST",params:{lang:e.lang}})}),postApiV1FaspClear:e.mutation({query:()=>({url:"/api/v1/fasp/clear",method:"POST"})}),getApiV1FaspDebugV0CallbackCallbacks:e.query({query:()=>({url:"/api/v1/fasp/debug/v0/callback/callbacks"})}),deleteApiV1FaspDebugV0CallbackCallbacksById:e.mutation({query:e=>({url:`/api/v1/fasp/debug/v0/callback/callbacks/${e.id}`,method:"DELETE"})}),postApiV1FaspRegistration:e.mutation({query:e=>({url:"/api/v1/fasp/registration",method:"POST",body:e.registrationRequest})}),postApiV1FaspByProviderIdCapabilities:e.mutation({query:e=>({url:`/api/v1/fasp/${e.providerId}/capabilities`,method:"POST",body:e.body})}),postApiV1FaspByProviderIdDebugCall:e.mutation({query:e=>({url:`/api/v1/fasp/${e.providerId}/debug-call`,method:"POST",body:e.body})}),getApiV1FaspByProviderIdRegistrationFinish:e.query({query:e=>({url:`/api/v1/fasp/${e.providerId}/registration-finish`})}),postApiV1FaspByProviderIdRegistrationFinish:e.mutation({query:e=>({url:`/api/v1/fasp/${e.providerId}/registration-finish`,method:"POST"})}),postApiV1FaspByProviderIdRequestBackfill:e.mutation({query:e=>({url:`/api/v1/fasp/${e.providerId}/request_backfill`,method:"POST",params:{category:e.category}})}),postApiV1FederationTokens:e.mutation({query:e=>({url:"/api/v1/federation/tokens",method:"POST",body:e.groupFederationTokenRequest})}),getApiV1Geo:e.query({query:e=>({url:"/api/v1/geo",params:{latitude:e.latitude,longitude:e.longitude}})}),getApiV1Groups:e.query({query:e=>({url:"/api/v1/groups",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1Groups:e.mutation({query:e=>({url:"/api/v1/groups",method:"POST",body:e.groupCreate})}),getApiV1GroupsApps:e.query({query:()=>({url:"/api/v1/groups/apps"})}),getApiV1GroupsInvites:e.query({query:e=>({url:"/api/v1/groups/invites",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),getApiV1GroupsInvitesByGroupInviteId:e.query({query:e=>({url:`/api/v1/groups/invites/${e.groupInviteId}`})}),getApiV1GroupsMemberByUserId:e.query({query:e=>({url:`/api/v1/groups/member/${e.userId}`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsMemberByUserIdGroups:e.query({query:e=>({url:`/api/v1/groups/member/${e.userId}/groups`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsMyGroups:e.query({query:e=>({url:"/api/v1/groups/my-groups",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsNameByGroupname:e.query({query:e=>({url:`/api/v1/groups/name/${e.groupname}`})}),getApiV1GroupsOwned:e.query({query:e=>({url:"/api/v1/groups/owned",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsPinned:e.query({query:e=>({url:"/api/v1/groups/pinned",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsSearch:e.query({query:e=>({url:"/api/v1/groups/search",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,substring:e.substring,untilId:e.untilId}})}),getApiV1GroupsUsersByUserIdMutual:e.query({query:e=>({url:`/api/v1/groups/users/${e.userId}/mutual`})}),putApiV1GroupsByGroupId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}`,method:"PUT",body:e.groupUpdate})}),getApiV1GroupsByGroupId:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}`})}),deleteApiV1GroupsByGroupId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}`,method:"DELETE"})}),getApiV1GroupsByGroupIdAiAgentsAssignments:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/ai-agents/assignments`,params:{resourceId:e.resourceId,type:e.type}})}),deleteApiV1GroupsByGroupIdAiAgentsAssignments:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/ai-agents/assignments`,method:"DELETE",params:{assignmentId:e.assignmentId}})}),postApiV1GroupsByGroupIdAiAgentsAssignments:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/ai-agents/assignments`,method:"POST",body:e.aiAgentAssignmentCreate})}),getApiV1GroupsByGroupIdApps:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/apps`})}),deleteApiV1GroupsByGroupIdAppsAndAppId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/apps/${e.appId}`,method:"DELETE"})}),putApiV1GroupsByGroupIdAppsAndAppId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/apps/${e.appId}`,method:"PUT"})}),putApiV1GroupsByGroupIdBranding:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/branding`,method:"PUT",body:e.groupBrandingUpdate})}),getApiV1GroupsByGroupIdCategories:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/categories`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1GroupsByGroupIdCategories:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/categories`,method:"POST",body:e.categoryCreate})}),getApiV1GroupsByGroupIdCategoriesNameAndCategoryName:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/categories/name/${e.categoryName}`})}),putApiV1GroupsByGroupIdCategoriesAndCategoryId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/categories/${e.categoryId}`,method:"PUT",body:e.categoryUpdate})}),getApiV1GroupsByGroupIdCategoriesAndCategoryId:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/categories/${e.categoryId}`})}),deleteApiV1GroupsByGroupIdCategoriesAndCategoryId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/categories/${e.categoryId}`,method:"DELETE"})}),getApiV1GroupsByGroupIdChannels:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels`})}),postApiV1GroupsByGroupIdChannels:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels`,method:"POST",body:e.body,params:{htmlContent:e.htmlContent}})}),getApiV1GroupsByGroupIdChannelsDefault:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/default`})}),getApiV1GroupsByGroupIdChannelsLookup:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/lookup`,params:{full:e.full,username:e.username,htmlContent:e.htmlContent}})}),getApiV1GroupsByGroupIdChannelsMain:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/main`,params:{htmlContent:e.htmlContent}})}),getApiV1GroupsByGroupIdChannelsPublic:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/public`})}),putApiV1GroupsByGroupIdChannelsAndChannelId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}`,method:"PUT",body:e.body,params:{htmlContent:e.htmlContent}})}),getApiV1GroupsByGroupIdChannelsAndChannelId:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}`,params:{full:e.full,htmlContent:e.htmlContent}})}),deleteApiV1GroupsByGroupIdChannelsAndChannelId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}`,method:"DELETE"})}),putApiV1GroupsByGroupIdChannelsAndChannelIdDefault:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}/default`,method:"PUT",params:{isDefault:e.isDefault,htmlContent:e.htmlContent}})}),putApiV1GroupsByGroupIdChannelsAndChannelIdMain:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}/main`,method:"PUT",params:{htmlContent:e.htmlContent}})}),putApiV1GroupsByGroupIdChannelsAndChannelIdUsername:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/channels/${e.channelId}/username`,method:"PUT",body:e.body,params:{htmlContent:e.htmlContent}})}),postApiV1GroupsByGroupIdFederationToken:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/federation-token`,method:"POST"})}),putApiV1GroupsByGroupIdForum:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/forum`,method:"PUT",body:e.forumUpdate})}),getApiV1GroupsByGroupIdForum:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/forum`})}),deleteApiV1GroupsByGroupIdForum:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/forum`,method:"DELETE"})}),deleteApiV1GroupsByGroupIdForumHard:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/forum/hard`,method:"DELETE"})}),getApiV1GroupsByGroupIdForumStats:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/forum/stats`})}),getApiV1GroupsByGroupIdForumTags:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/forum/tags`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsByGroupIdForumTagsSearch:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/forum/tags/search`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1GroupsByGroupIdInvites:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/invites`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),postApiV1GroupsByGroupIdInvites:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/invites`,method:"POST",body:e.groupInviteCreate})}),deleteApiV1GroupsByGroupIdInvitesAndGroupInviteId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/invites/${e.groupInviteId}`,method:"DELETE"})}),postApiV1GroupsByGroupIdInvitesAndGroupInviteIdAccept:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/invites/${e.groupInviteId}/accept`,method:"POST"})}),postApiV1GroupsByGroupIdInvitesAndGroupInviteIdReject:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/invites/${e.groupInviteId}/reject`,method:"POST"})}),postApiV1GroupsByGroupIdJoin:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/join`,method:"POST",params:{answerToken:e.answerToken}})}),deleteApiV1GroupsByGroupIdJoin:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/join`,method:"DELETE"})}),getApiV1GroupsByGroupIdJoinRequests:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/join-requests`,params:{createdFrom:e.createdFrom,createdTo:e.createdTo,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId,username:e.username}})}),deleteApiV1GroupsByGroupIdJoinRequestsAndGroupJoinRequestId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/join-requests/${e.groupJoinRequestId}`,method:"DELETE",params:{purge:e.purge,reason:e.reason}})}),putApiV1GroupsByGroupIdJoinRequestsAndGroupJoinRequestId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/join-requests/${e.groupJoinRequestId}`,method:"PUT",params:{reason:e.reason}})}),putApiV1GroupsByGroupIdMemberSettings:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/member-settings`,method:"PUT",body:e.groupMemberSettings})}),getApiV1GroupsByGroupIdMemberSettings:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/member-settings`,params:{keys:e.keys}})}),deleteApiV1GroupsByGroupIdMemberSettings:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/member-settings`,method:"DELETE",params:{keys:e.keys}})}),getApiV1GroupsByGroupIdMembers:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/members`,params:{actorType:e.actorType,createdAfter:e.createdAfter,displayName:e.displayName,domain:e.domain,limit:e.limit,offset:e.offset,order:e.order,role:e.role,sort:e.sort,username:e.username}})}),postApiV1GroupsByGroupIdMembers:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/members`,method:"POST",body:e.groupMemberCreate})}),getApiV1GroupsByGroupIdMembersSearch:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/members/search`,params:{actorType:e.actorType,country:e.country,createdAfter:e.createdAfter,displayName:e.displayName,domain:e.domain,ip:e.ip,lastId:e.lastId,limit:e.limit,offset:e.offset,role:e.role,roles:e.roles,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,username:e.username}})}),putApiV1GroupsByGroupIdMembersAndMemberId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/members/${e.memberId}`,method:"PUT",body:e.groupMemberUpdate})}),deleteApiV1GroupsByGroupIdMembersAndMemberId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/members/${e.memberId}`,method:"DELETE",params:{reason:e.reason}})}),deleteApiV1GroupsByGroupIdMembership:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/membership`,method:"DELETE"})}),getApiV1GroupsByGroupIdMembership:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/membership`})}),deleteApiV1GroupsByGroupIdPin:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/pin`,method:"DELETE"})}),putApiV1GroupsByGroupIdPin:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/pin`,method:"PUT",params:{pin:e.pin}})}),getApiV1GroupsByGroupIdQuestions:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/questions`})}),postApiV1GroupsByGroupIdQuestions:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/questions`,method:"POST",body:e.questionCreate})}),postApiV1GroupsByGroupIdQuestionsAnswers:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/questions/answers`,method:"POST",body:e.questionAnswerCreate})}),putApiV1GroupsByGroupIdQuestionsAndQuestionId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/questions/${e.questionId}`,method:"PUT",body:e.questionUpdate})}),deleteApiV1GroupsByGroupIdQuestionsAndQuestionId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/questions/${e.questionId}`,method:"DELETE"})}),postApiV1GroupsByGroupIdReportsDeletePosts:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/delete-posts`,method:"POST",body:e.body})}),getApiV1GroupsByGroupIdReportsList:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/list`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,open:e.open,postId:e.postId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId}})}),getApiV1GroupsByGroupIdReportsAndReportId:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}`})}),postApiV1GroupsByGroupIdReportsAndReportIdAddNote:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}/add-note`,method:"POST",body:e.body})}),postApiV1GroupsByGroupIdReportsAndReportIdRemoveNote:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}/remove-note`,method:"POST",params:{index:e.index}})}),postApiV1GroupsByGroupIdReportsAndReportIdReopen:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}/reopen`,method:"POST"})}),postApiV1GroupsByGroupIdReportsAndReportIdResolve:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/reports/${e.reportId}/resolve`,method:"POST"})}),getApiV1GroupsByGroupIdRules:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/rules`})}),postApiV1GroupsByGroupIdRules:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/rules`,method:"POST",params:{hint:e.hint,ordering:e.ordering,text:e.text}})}),postApiV1GroupsByGroupIdRulesReorder:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/rules/reorder`,method:"POST",body:e.body})}),deleteApiV1GroupsByGroupIdRulesAndId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/rules/${e.id}`,method:"DELETE"})}),putApiV1GroupsByGroupIdRulesAndRuleId:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/rules/${e.ruleId}`,method:"PUT",body:e.ruleUpdate})}),putApiV1GroupsByGroupIdSettings:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/settings`,method:"PUT",body:e.groupSettings})}),getApiV1GroupsByGroupIdSettings:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/settings`,params:{keys:e.keys}})}),deleteApiV1GroupsByGroupIdSettings:e.mutation({query:e=>({url:`/api/v1/groups/${e.groupId}/settings`,method:"DELETE",params:{keys:e.keys}})}),getApiV1GroupsByGroupIdUsers:e.query({query:e=>({url:`/api/v1/groups/${e.groupId}/users`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,order:e.order,role:e.role,sort:e.sort,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1Import:e.query({query:()=>({url:"/api/v1/import"})}),postApiV1Import:e.mutation({query:e=>({url:"/api/v1/import",method:"POST",body:e.body,params:{overwrite:e.overwrite,type:e.type}})}),postApiV1ImportStartById:e.mutation({query:e=>({url:`/api/v1/import/start/${e.id}`,method:"POST"})}),getApiV1ImportById:e.query({query:e=>({url:`/api/v1/import/${e.id}`})}),getApiV1Instance:e.query({query:()=>({url:"/api/v1/instance"})}),getApiV1InstanceCountries:e.query({query:()=>({url:"/api/v1/instance/countries"})}),getApiV1InstanceDomains:e.query({query:e=>({url:"/api/v1/instance/domains",params:{domain:e.domain,limit:e.limit,software:e.software}})}),getApiV1InstanceExtendedDescription:e.query({query:()=>({url:"/api/v1/instance/extended_description"})}),getApiV1InstanceSupportedLanguages:e.query({query:()=>({url:"/api/v1/instance/supported_languages"})}),getApiV1InstanceTimezones:e.query({query:()=>({url:"/api/v1/instance/timezones"})}),getApiV1JobsListJobs:e.query({query:e=>({url:"/api/v1/jobs/list-jobs",params:{limit:e.limit,offset:e.offset}})}),getApiV1JobsListStats:e.query({query:e=>({url:"/api/v1/jobs/list-stats",params:{queue:e.queue}})}),getApiV1JobsListStatsAll:e.query({query:()=>({url:"/api/v1/jobs/list-stats-all"})}),getApiV1JobsLists:e.query({query:e=>({url:"/api/v1/jobs/lists",params:{limit:e.limit,listKind:e.listKind,offset:e.offset,queue:e.queue}})}),getApiV1JobsStats:e.query({query:()=>({url:"/api/v1/jobs/stats"})}),getApiV1JobsStatsPerDay:e.query({query:e=>({url:"/api/v1/jobs/stats-per-day",params:{lastDays:e.lastDays,queue:e.queue}})}),getApiV1Links:e.query({query:e=>({url:"/api/v1/links",params:{url:e.url}})}),getApiV1Lists:e.query({query:()=>({url:"/api/v1/lists"})}),postApiV1Lists:e.mutation({query:e=>({url:"/api/v1/lists",method:"POST",body:e.userListCreate})}),putApiV1ListsByListId:e.mutation({query:e=>({url:`/api/v1/lists/${e.listId}`,method:"PUT",body:e.userListCreate})}),getApiV1ListsByListId:e.query({query:e=>({url:`/api/v1/lists/${e.listId}`})}),deleteApiV1ListsByListId:e.mutation({query:e=>({url:`/api/v1/lists/${e.listId}`,method:"DELETE"})}),getApiV1ListsByListIdUsers:e.query({query:e=>({url:`/api/v1/lists/${e.listId}/users`})}),deleteApiV1ListsByListIdUsersAndUserId:e.mutation({query:e=>({url:`/api/v1/lists/${e.listId}/users/${e.userId}`,method:"DELETE"})}),postApiV1ListsByListIdUsersAndUserId:e.mutation({query:e=>({url:`/api/v1/lists/${e.listId}/users/${e.userId}`,method:"POST"})}),putApiV1Markdown:e.mutation({query:e=>({url:"/api/v1/markdown",method:"PUT",body:e.body,params:{skipAutolink:e.skipAutolink}})}),getApiV1Metrics:e.query({query:e=>({url:"/api/v1/metrics",params:{from:e.from,period:e.period,to:e.to}})}),getApiV1MetricsTotals:e.query({query:()=>({url:"/api/v1/metrics/totals"})}),getApiV1Mute:e.query({query:e=>({url:"/api/v1/mute",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),deleteApiV1MuteByUserId:e.mutation({query:e=>({url:`/api/v1/mute/${e.userId}`,method:"DELETE"})}),postApiV1MuteByUserId:e.mutation({query:e=>({url:`/api/v1/mute/${e.userId}`,method:"POST",params:{duration:e.duration}})}),getApiV1NamesCheck:e.query({query:e=>({url:"/api/v1/names/check",params:{name:e.name,nameScope:e.nameScope,scope:e.scope}})}),putApiV1Notes:e.mutation({query:e=>({url:"/api/v1/notes",method:"PUT",body:e.noteUpdate})}),getApiV1Notes:e.query({query:e=>({url:"/api/v1/notes",params:{userIds:e.userIds}})}),deleteApiV1NotesByUserId:e.mutation({query:e=>({url:`/api/v1/notes/${e.userId}`,method:"DELETE"})}),getApiV1Notifications:e.query({query:e=>({url:"/api/v1/notifications",params:{excludeTypes:e.excludeTypes,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,types:e.types,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1NotificationsCount:e.query({query:e=>({url:"/api/v1/notifications/count",params:{excludeTypes:e.excludeTypes,status:e.status,types:e.types}})}),postApiV1NotificationsMarkAll:e.mutation({query:e=>({url:"/api/v1/notifications/mark-all",method:"POST",params:{status:e.status}})}),getApiV1NotificationsById:e.query({query:e=>({url:`/api/v1/notifications/${e.id}`,params:{htmlContent:e.htmlContent}})}),postApiV1NotificationsByIdMark:e.mutation({query:e=>({url:`/api/v1/notifications/${e.id}/mark`,method:"POST",params:{status:e.status,htmlContent:e.htmlContent}})}),getApiV1Passkeys:e.query({query:()=>({url:"/api/v1/passkeys"})}),getApiV1PasskeysBeginAuth:e.query({query:e=>({url:"/api/v1/passkeys/begin-auth",params:{username:e.username}})}),getApiV1PasskeysBeginRegister:e.query({query:()=>({url:"/api/v1/passkeys/begin-register"})}),postApiV1PasskeysFinishAuth:e.mutation({query:e=>({url:"/api/v1/passkeys/finish-auth",method:"POST",body:e.jsonObject})}),postApiV1PasskeysFinishRegister:e.mutation({query:e=>({url:"/api/v1/passkeys/finish-register",method:"POST",body:e.jsonObject})}),deleteApiV1PasskeysByCredentialId:e.mutation({query:e=>({url:`/api/v1/passkeys/${e.credentialId}`,method:"DELETE"})}),postApiV1PollsByPollIdRefresh:e.mutation({query:e=>({url:`/api/v1/polls/${e.pollId}/refresh`,method:"POST"})}),postApiV1PollsByPollIdVote:e.mutation({query:e=>({url:`/api/v1/polls/${e.pollId}/vote`,method:"POST",body:e.body})}),getApiV1Posts:e.query({query:e=>({url:"/api/v1/posts",params:{all:e.all,bookmarkedOnly:e.bookmarkedOnly,forumTags:e.forumTags,includeBookmarkStatus:e.includeBookmarkStatus,includeComments:e.includeComments,includeFollowStatus:e.includeFollowStatus,includePinnedStatus:e.includePinnedStatus,includeReply:e.includeReply,lastId:e.lastId,limit:e.limit,limitFirstLevelComments:e.limitFirstLevelComments,limitSecondLevelComments:e.limitSecondLevelComments,listId:e.listId,maxLevel:e.maxLevel,minLevel:e.minLevel,offset:e.offset,ownerId:e.ownerId,pinned:e.pinned,repostKind:e.repostKind,repostOf:e.repostOf,repostsOnly:e.repostsOnly,search:e.search,skipReposts:e.skipReposts,sortBy:e.sortBy,sortOrder:e.sortOrder,tag:e.tag,untilId:e.untilId,userId:e.userId,username:e.username,withRepostedBy:e.withRepostedBy,withTranslation:e.withTranslation,withTrends:e.withTrends,htmlContent:e.htmlContent}})}),postApiV1Posts:e.mutation({query:e=>({url:"/api/v1/posts",method:"POST",body:e.createPost,params:{ownerId:e.ownerId,htmlContent:e.htmlContent}})}),getApiV1PostsBookmarked:e.query({query:e=>({url:"/api/v1/posts/bookmarked",params:{includeComments:e.includeComments,includeReply:e.includeReply,lastId:e.lastId,limit:e.limit,my:e.my,offset:e.offset,ownerId:e.ownerId,search:e.search,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1PostsFeedsFollowing:e.query({query:e=>({url:"/api/v1/posts/feeds/following",params:{ignoreCache:e.ignoreCache,includeBookmarkStatus:e.includeBookmarkStatus,includeFollowStatus:e.includeFollowStatus,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,withRepostedBy:e.withRepostedBy,withTranslation:e.withTranslation,htmlContent:e.htmlContent}})}),getApiV1PostsFeedsPublic:e.query({query:e=>({url:"/api/v1/posts/feeds/public",params:{includeBookmarkStatus:e.includeBookmarkStatus,includeFollowStatus:e.includeFollowStatus,lastId:e.lastId,limit:e.limit,local:e.local,offset:e.offset,skipReposts:e.skipReposts,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,withRepostedBy:e.withRepostedBy,withTranslation:e.withTranslation,withTrends:e.withTrends,htmlContent:e.htmlContent}})}),getApiV1PostsLiked:e.query({query:e=>({url:"/api/v1/posts/liked",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1PostsMentioned:e.query({query:e=>({url:"/api/v1/posts/mentioned",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,private:e.private,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1PostsMy:e.query({query:e=>({url:"/api/v1/posts/my",params:{bookmarkedOnly:e.bookmarkedOnly,includeBookmarkStatus:e.includeBookmarkStatus,includeComments:e.includeComments,lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,repostsOnly:e.repostsOnly,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),getApiV1PostsPins:e.query({query:e=>({url:"/api/v1/posts/pins",params:{ownerId:e.ownerId,postOnly:e.postOnly}})}),deleteApiV1PostsPinsByPostId:e.mutation({query:e=>({url:`/api/v1/posts/pins/${e.postId}`,method:"DELETE"})}),postApiV1PostsPinsByPostId:e.mutation({query:e=>({url:`/api/v1/posts/pins/${e.postId}`,method:"POST"})}),getApiV1PostsReplies:e.query({query:e=>({url:"/api/v1/posts/replies",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,userId:e.userId,username:e.username,htmlContent:e.htmlContent}})}),getApiV1PostsSubscribe:e.query({query:e=>({url:"/api/v1/posts/subscribe",params:{all:e.all,ownerId:e.ownerId,htmlContent:e.htmlContent}})}),putApiV1PostsByPostId:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}`,method:"PUT",body:e.createPost,params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostId:e.query({query:e=>({url:`/api/v1/posts/${e.postId}`,params:{includeBookmarkStatus:e.includeBookmarkStatus,limitFirstLevelComments:e.limitFirstLevelComments,limitSecondLevelComments:e.limitSecondLevelComments,maxLevel:e.maxLevel,minLevel:e.minLevel,withComments:e.withComments,withParents:e.withParents,withRepostedBy:e.withRepostedBy,withRootParent:e.withRootParent,withTranslation:e.withTranslation,withTrends:e.withTrends,htmlContent:e.htmlContent}})}),deleteApiV1PostsByPostId:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}`,method:"DELETE"})}),getApiV1PostsByPostIdActiveUsers:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/active-users`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),deleteApiV1PostsByPostIdBookmark:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/bookmark`,method:"DELETE"})}),postApiV1PostsByPostIdBookmark:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/bookmark`,method:"POST"})}),getApiV1PostsByPostIdComments:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/comments`,params:{lastId:e.lastId,limit:e.limit,limitFirstLevelComments:e.limitFirstLevelComments,maxLevel:e.maxLevel,minLevel:e.minLevel,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),postApiV1PostsByPostIdComments:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/comments`,method:"POST",body:e.createPost,params:{htmlContent:e.htmlContent}})}),putApiV1PostsByPostIdCommentsAndCommentId:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/comments/${e.commentId}`,method:"PUT",body:e.createPost,params:{htmlContent:e.htmlContent}})}),deleteApiV1PostsByPostIdCommentsAndCommentId:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/comments/${e.commentId}`,method:"DELETE"})}),postApiV1PostsByPostIdDetach:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/detach`,method:"POST"})}),postApiV1PostsByPostIdDownvote:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/downvote`,method:"POST",params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostIdEdits:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/edits`,params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostIdLikes:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/likes`,params:{includeFollowedStatus:e.includeFollowedStatus,includeFollowingStatus:e.includeFollowingStatus,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),deleteApiV1PostsByPostIdLikes:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/likes`,method:"DELETE"})}),postApiV1PostsByPostIdLikes:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/likes`,method:"POST"})}),postApiV1PostsByPostIdRefreshCard:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/refresh-card`,method:"POST"})}),deleteApiV1PostsByPostIdRepost:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/repost`,method:"DELETE"})}),postApiV1PostsByPostIdRepost:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/repost`,method:"POST",body:e.createPost,params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostIdReposts:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/reposts`,params:{includeFollowedStatus:e.includeFollowedStatus,includeFollowingStatus:e.includeFollowingStatus,kind:e.kind,lastId:e.lastId,limit:e.limit,offset:e.offset,skipDuplicates:e.skipDuplicates,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,htmlContent:e.htmlContent}})}),postApiV1PostsByPostIdSubscribe:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/subscribe`,method:"POST"})}),deleteApiV1PostsByPostIdSubscribe:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/subscribe`,method:"DELETE"})}),postApiV1PostsByPostIdTrackView:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/track-view`,method:"POST"})}),postApiV1PostsByPostIdTranslate:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/translate`,method:"POST",params:{htmlContent:e.htmlContent,lang:e.lang}})}),postApiV1PostsByPostIdUpvote:e.mutation({query:e=>({url:`/api/v1/posts/${e.postId}/upvote`,method:"POST",params:{htmlContent:e.htmlContent}})}),getApiV1PostsByPostIdVotes:e.query({query:e=>({url:`/api/v1/posts/${e.postId}/votes`,params:{htmlContent:e.htmlContent}})}),getApiV1Rbac:e.query({query:()=>({url:"/api/v1/rbac"})}),getApiV1RbacActorsByActorIdPermissions:e.query({query:e=>({url:`/api/v1/rbac/actors/${e.actorId}/permissions`,params:{targetScope:e.targetScope}})}),getApiV1RbacActorsByActorIdRoles:e.query({query:e=>({url:`/api/v1/rbac/actors/${e.actorId}/roles`,params:{targetScope:e.targetScope}})}),putApiV1RbacRolesByRoleId:e.mutation({query:e=>({url:`/api/v1/rbac/roles/${e.roleId}`,method:"PUT",body:e.rbacRoleTemplate})}),getApiV1RbacScopesByScopeRoles:e.query({query:e=>({url:`/api/v1/rbac/scopes/${e.scope}/roles`})}),postApiV1RbacScopesByScopeRoles:e.mutation({query:e=>({url:`/api/v1/rbac/scopes/${e.scope}/roles`,method:"POST",body:e.rbacRoleTemplate})}),deleteApiV1RbacScopesByScopeRolesAndRoleName:e.mutation({query:e=>({url:`/api/v1/rbac/scopes/${e.scope}/roles/${e.roleName}`,method:"DELETE"})}),getApiV1RbacByResource:e.query({query:e=>({url:`/api/v1/rbac/${e.resource}`})}),postApiV1Reports:e.mutation({query:e=>({url:"/api/v1/reports",method:"POST",body:e.createReport})}),putApiV1Rules:e.mutation({query:e=>({url:"/api/v1/rules",method:"PUT",body:e.rule})}),getApiV1Rules:e.query({query:()=>({url:"/api/v1/rules"})}),postApiV1Rules:e.mutation({query:e=>({url:"/api/v1/rules",method:"POST",body:e.ruleCreate})}),postApiV1RulesReorder:e.mutation({query:e=>({url:"/api/v1/rules/reorder",method:"POST",body:e.body})}),deleteApiV1RulesById:e.mutation({query:e=>({url:`/api/v1/rules/${e.id}`,method:"DELETE"})}),getApiV1Search:e.query({query:e=>({url:"/api/v1/search",params:{actorType:e.actorType,fasp:e.fasp,faspHydrated:e.faspHydrated,filter:e.filter,followStatus:e.followStatus,followers:e.followers,following:e.following,groupId:e.groupId,groupMemberRole:e.groupMemberRole,includeRelations:e.includeRelations,lastId:e.lastId,limit:e.limit,offset:e.offset,ownerId:e.ownerId,q:e.q,resolve:e.resolve,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId,withComments:e.withComments,withParent:e.withParent,htmlContent:e.htmlContent}})}),deleteApiV1SessionsAll:e.mutation({query:()=>({url:"/api/v1/sessions/all",method:"DELETE"})}),getApiV1SessionsList:e.query({query:()=>({url:"/api/v1/sessions/list"})}),putApiV1SessionsRevokeAll:e.mutation({query:()=>({url:"/api/v1/sessions/revoke/all",method:"PUT"})}),putApiV1SessionsRevokeBySessionKey:e.mutation({query:e=>({url:`/api/v1/sessions/revoke/${e.sessionKey}`,method:"PUT"})}),deleteApiV1SessionsBySessionKey:e.mutation({query:e=>({url:`/api/v1/sessions/${e.sessionKey}`,method:"DELETE"})}),putApiV1Settings:e.mutation({query:e=>({url:"/api/v1/settings",method:"PUT",body:e.platformSettings})}),getApiV1Settings:e.query({query:e=>({url:"/api/v1/settings",params:{keys:e.keys}})}),deleteApiV1Settings:e.mutation({query:e=>({url:"/api/v1/settings",method:"DELETE",params:{keys:e.keys}})}),getApiV1SettingsNames:e.query({query:e=>({url:"/api/v1/settings/names",params:{type:e.type}})}),putApiV1SettingsUser:e.mutation({query:e=>({url:"/api/v1/settings/user",method:"PUT",body:e.userSettings})}),getApiV1SettingsUser:e.query({query:e=>({url:"/api/v1/settings/user",params:{keys:e.keys}})}),deleteApiV1SettingsUser:e.mutation({query:e=>({url:"/api/v1/settings/user",method:"DELETE",params:{keys:e.keys}})}),getApiV1TagsFeatured:e.query({query:e=>({url:"/api/v1/tags/featured",params:{scope:e.scope,userId:e.userId}})}),deleteApiV1TagsFeaturedByName:e.mutation({query:e=>({url:`/api/v1/tags/featured/${e.name}`,method:"DELETE",params:{scope:e.scope}})}),postApiV1TagsFeaturedByName:e.mutation({query:e=>({url:`/api/v1/tags/featured/${e.name}`,method:"POST",params:{scope:e.scope}})}),postApiV1TagsFollowByName:e.mutation({query:e=>({url:`/api/v1/tags/follow/${e.name}`,method:"POST",params:{scope:e.scope}})}),getApiV1TagsFollowed:e.query({query:e=>({url:"/api/v1/tags/followed",params:{scope:e.scope}})}),putApiV1TagsList:e.mutation({query:e=>({url:"/api/v1/tags/list",method:"PUT",body:e.body,params:{scope:e.scope,soft:e.soft,type:e.type}})}),patchApiV1TagsList:e.mutation({query:e=>({url:"/api/v1/tags/list",method:"PATCH",body:e.body,params:{scope:e.scope,soft:e.soft,type:e.type}})}),getApiV1TagsList:e.query({query:e=>({url:"/api/v1/tags/list",params:{scope:e.scope,soft:e.soft,type:e.type}})}),deleteApiV1TagsList:e.mutation({query:e=>({url:"/api/v1/tags/list",method:"DELETE",body:e.body,params:{scope:e.scope,soft:e.soft,type:e.type}})}),putApiV1TagsPolicy:e.mutation({query:e=>({url:"/api/v1/tags/policy",method:"PUT",body:e.setTagPolicyRequest,params:{scope:e.scope}})}),getApiV1TagsPolicy:e.query({query:e=>({url:"/api/v1/tags/policy",params:{scope:e.scope}})}),postApiV1TagsReport:e.mutation({query:e=>({url:"/api/v1/tags/report",method:"POST",body:e.createTagReportRequest,params:{name:e.name,scope:e.scope}})}),getApiV1TagsReports:e.query({query:e=>({url:"/api/v1/tags/reports",params:{scope:e.scope}})}),getApiV1TagsSearch:e.query({query:e=>({url:"/api/v1/tags/search",params:{limit:e.limit,name:e.name,offset:e.offset,scope:e.scope}})}),getApiV1TagsTrending:e.query({query:e=>({url:"/api/v1/tags/trending",params:{limit:e.limit,offset:e.offset,scope:e.scope,sortBy:e.sortBy,sortOrder:e.sortOrder}})}),postApiV1TagsUnfollowByName:e.mutation({query:e=>({url:`/api/v1/tags/unfollow/${e.name}`,method:"POST",params:{scope:e.scope}})}),getApiV1TagsByName:e.query({query:e=>({url:`/api/v1/tags/${e.name}`,params:{historySince:e.historySince,scope:e.scope}})}),postApiV1TranslateText:e.mutation({query:e=>({url:"/api/v1/translate/text",method:"POST",body:e.translationRequest})}),getApiV1TrendsLinks:e.query({query:()=>({url:"/api/v1/trends/links"})}),getApiV1TrendsPosts:e.query({query:e=>({url:"/api/v1/trends/posts",params:{htmlContent:e.htmlContent}})}),getApiV1TrendsTags:e.query({query:e=>({url:"/api/v1/trends/tags",params:{scope:e.scope}})}),postApiV1Uploads:e.mutation({query:e=>({url:"/api/v1/uploads",method:"POST",body:e.createUpload})}),postApiV1UploadsBatch:e.mutation({query:e=>({url:"/api/v1/uploads/batch",method:"POST",body:e.body})}),postApiV1UploadsList:e.mutation({query:e=>({url:"/api/v1/uploads/list",method:"POST",body:e.uploadList})}),getApiV1UploadsSearch:e.query({query:e=>({url:"/api/v1/uploads/search",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,tag:e.tag,untilId:e.untilId,uploadType:e.uploadType}})}),getApiV1UploadsUsages:e.query({query:e=>({url:"/api/v1/uploads/usages",params:{ids:e.ids}})}),getApiV1UploadsById:e.query({query:e=>({url:`/api/v1/uploads/${e.id}`})}),deleteApiV1UploadsById:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}`,method:"DELETE"})}),postApiV1UploadsByIdMeta:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/meta`,method:"POST",body:e.body})}),putApiV1UploadsByIdMeta:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/meta`,method:"PUT",body:e.body})}),postApiV1UploadsByIdPrivacy:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/privacy`,method:"POST",body:e.updateUploadPrivacy})}),postApiV1UploadsByIdTags:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/tags`,method:"POST",body:e.body})}),putApiV1UploadsByIdTags:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/tags`,method:"PUT",body:e.body})}),postApiV1UploadsByIdThumbnail:e.mutation({query:e=>({url:`/api/v1/uploads/${e.id}/thumbnail`,method:"POST",body:e.changeVideoThumbnail})}),getApiV1UserAlias:e.query({query:()=>({url:"/api/v1/user-alias"})}),deleteApiV1UserAlias:e.mutation({query:e=>({url:"/api/v1/user-alias",method:"DELETE",params:{uri:e.uri}})}),postApiV1UserAlias:e.mutation({query:e=>({url:"/api/v1/user-alias",method:"POST",params:{acct:e.acct}})}),getApiV1UserDomainBlock:e.query({query:()=>({url:"/api/v1/user-domain-block"})}),deleteApiV1UserDomainBlockByDomain:e.mutation({query:e=>({url:`/api/v1/user-domain-block/${e.domain}`,method:"DELETE"})}),postApiV1UserDomainBlockByDomain:e.mutation({query:e=>({url:`/api/v1/user-domain-block/${e.domain}`,method:"POST"})}),deleteApiV1Users:e.mutation({query:e=>({url:"/api/v1/users",method:"DELETE",params:{id:e.id,name:e.name}})}),postApiV1Users:e.mutation({query:e=>({url:"/api/v1/users",method:"POST",body:e.userCreate,params:{htmlContent:e.htmlContent}})}),getApiV1Users:e.query({query:e=>({url:"/api/v1/users",params:{full:e.full,includeBlockedByStatus:e.includeBlockedByStatus,includeBlockedStatus:e.includeBlockedStatus,includeFollowedStatus:e.includeFollowedStatus,includeFollowingStatus:e.includeFollowingStatus,includeMutedStatus:e.includeMutedStatus,relations:e.relations,username:e.username,htmlContent:e.htmlContent}})}),getApiV1UsersConnections:e.query({query:e=>({url:"/api/v1/users/connections",params:{lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),postApiV1UsersFollowByUsername:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}`,method:"POST",params:{domain:e.domain,mutual:e.mutual,scheme:e.scheme}})}),postApiV1UsersFollowByUsernameAccept:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}/accept`,method:"POST"})}),postApiV1UsersFollowByUsernamePend:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}/pend`,method:"POST"})}),postApiV1UsersFollowByUsernameReject:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}/reject`,method:"POST"})}),postApiV1UsersFollowByUsernameUndo:e.mutation({query:e=>({url:`/api/v1/users/follow/${e.username}/undo`,method:"POST",params:{domain:e.domain,mutual:e.mutual,scheme:e.scheme}})}),getApiV1UsersFollowees:e.query({query:e=>({url:"/api/v1/users/followees",params:{anyStatus:e.anyStatus,lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),getApiV1UsersFollowers:e.query({query:e=>({url:"/api/v1/users/followers",params:{anyStatus:e.anyStatus,lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,status:e.status,untilId:e.untilId}})}),getApiV1UsersInviteLinks:e.query({query:e=>({url:"/api/v1/users/invite-links",params:{active:e.active,lastId:e.lastId,limit:e.limit,offset:e.offset,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),postApiV1UsersInviteLinks:e.mutation({query:e=>({url:"/api/v1/users/invite-links",method:"POST",body:e.signupInviteLinkCreate})}),putApiV1UsersInviteLinksDeactivateByCode:e.mutation({query:e=>({url:`/api/v1/users/invite-links/deactivate/${e.code}`,method:"PUT"})}),getApiV1UsersProfile:e.query({query:e=>({url:"/api/v1/users/profile",params:{htmlContent:e.htmlContent}})}),getApiV1UsersRelationships:e.query({query:e=>({url:"/api/v1/users/relationships",params:{filter:e.filter,targets:e.targets}})}),getApiV1UsersRemoteByUserNameFullFollowers:e.query({query:e=>({url:`/api/v1/users/remote/${e.userNameFull}/followers`,params:{limit:e.limit,offset:e.offset}})}),getApiV1UsersRemoteByUserNameFullFollowing:e.query({query:e=>({url:`/api/v1/users/remote/${e.userNameFull}/following`,params:{limit:e.limit,offset:e.offset}})}),getApiV1UsersRenameHistory:e.query({query:()=>({url:"/api/v1/users/rename-history"})}),putApiV1UsersByUserId:e.mutation({query:e=>({url:`/api/v1/users/${e.userId}`,method:"PUT",body:e.userUpdate,params:{htmlContent:e.htmlContent}})}),getApiV1UsersByUserId:e.query({query:e=>({url:`/api/v1/users/${e.userId}`,params:{full:e.full,includeBlockedByStatus:e.includeBlockedByStatus,includeBlockedStatus:e.includeBlockedStatus,includeFollowedStatus:e.includeFollowedStatus,includeFollowingStatus:e.includeFollowingStatus,includeMutedStatus:e.includeMutedStatus,relations:e.relations,htmlContent:e.htmlContent}})}),getApiV1UsersByUserIdFollowers:e.query({query:e=>({url:`/api/v1/users/${e.userId}/followers`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),getApiV1UsersByUserIdFollowing:e.query({query:e=>({url:`/api/v1/users/${e.userId}/following`,params:{lastId:e.lastId,limit:e.limit,offset:e.offset,q:e.q,sortBy:e.sortBy,sortOrder:e.sortOrder,untilId:e.untilId}})}),putApiV1UsersByUserIdMedia:e.mutation({query:e=>({url:`/api/v1/users/${e.userId}/media`,method:"PUT",body:e.userUpdateMedia,params:{htmlContent:e.htmlContent}})}),getRoot:e.query({query:e=>({url:"/",params:{format:e.format}})}),getUser:e.query({query:e=>({url:`/@${e.username}`,params:{format:e.format}})}),getUserEvent:e.query({query:e=>({url:`/@${e.username}/events/${e.eventId}`,params:{format:e.format}})}),getUserPost:e.query({query:e=>({url:`/@${e.username}/posts/${e.postId}`,params:{format:e.format}})}),getAbout:e.query({query:e=>({url:"/about",params:{format:e.format}})}),getFeed:e.query({query:e=>({url:"/feed",params:{format:e.format}})}),getFeedDiscover:e.query({query:e=>({url:"/feed/discover",params:{format:e.format}})}),getFeedFollowing:e.query({query:e=>({url:"/feed/following",params:{format:e.format}})}),getGroup:e.query({query:e=>({url:`/g/${e.groupName}`,params:{format:e.format}})}),getGroupChannel:e.query({query:e=>({url:`/g/${e.groupName}/@${e.channelName}`,params:{format:e.format}})}),getGroupChannelPost:e.query({query:e=>({url:`/g/${e.groupName}/@${e.channelName}/posts/${e.postId}`,params:{format:e.format}})}),getGroupEvent:e.query({query:e=>({url:`/g/${e.groupName}/events/${e.eventId}`,params:{format:e.format}})}),getGroupForumCategory:e.query({query:e=>({url:`/g/${e.groupName}/forum/c/${e.categoryName}`,params:{format:e.format}})}),getGroupForumPost:e.query({query:e=>({url:`/g/${e.groupName}/forum/posts/${e.postId}`,params:{format:e.format}})}),getForumTag:e.query({query:e=>({url:`/g/${e.groupName}/forum/tag/${e.tagName}`,params:{format:e.format}})}),getPrivacy:e.query({query:e=>({url:"/privacy",params:{format:e.format}})}),getTerms:e.query({query:e=>({url:"/terms",params:{format:e.format}})})}),overrideExisting:!1}),OO={forgotPasswordStep:"request",forgotPasswordFields:null,signupStep:"rules",signupFields:null,token:null,newEmail:null,isPending:!!J$.getToken(),isAuthenticated:!1,isAskLoginOpen:!1},rX=oo({name:"auth",initialState:OO,reducers:{setAskLoginOpen:(e,t)=>{e.isAskLoginOpen=t.payload},login:(e,t)=>{e.isAuthenticated=!0,e.token=t.payload||null,e.isPending=!1},logout:()=>({...OO,isPending:!1}),setNewEmail:(e,t)=>{e.newEmail=t.payload},setForgotPasswordStep:(e,t)=>{e.forgotPasswordStep=t.payload},updateForgotPasswordFields:(e,t)=>{e.forgotPasswordFields={...e.forgotPasswordFields,...t.payload}},resetForgotPasswordFields:e=>{e.forgotPasswordFields=null},setSignupStep:(e,t)=>{e.signupStep=t.payload},updateSignupFields:(e,t)=>{e.signupFields={...e.signupFields,...t.payload}},resetSignupFields:e=>{e.signupFields=null},setPending:(e,t)=>{e.isPending=t.payload}},selectors:{selectAskLoginOpen:e=>e.isAskLoginOpen,selectToken:e=>e.token,selectNewEmail:e=>e.newEmail,selectForgotPasswordStep:e=>e.forgotPasswordStep,selectForgotPasswordFields:e=>e.forgotPasswordFields,selectSignupStep:e=>e.signupStep,selectSignupFields:e=>e.signupFields,selectPending:e=>e.isPending,selectIsAuthenticated:e=>e.isAuthenticated}}),oX={data:null,isPending:!1,isSuccess:!1},iX=oo({name:"userNoHTML",initialState:oX,reducers:{setUser:(e,t)=>{e.data=t.payload},setPending:(e,t)=>{e.isPending=t.payload},setSuccess:(e,{payload:t})=>{e.isSuccess=t},setError:(e,{payload:t})=>{e.error=t}},selectors:{selectUser:e=>e.data,selectPending:e=>e.isPending,selectError:e=>e.error,selectSuccess:e=>e.isSuccess}}),AO={data:null,isError:!1,isPending:!1,isSuccess:!1},aX=oo({name:"user",initialState:AO,reducers:{reset:e=>{Object.assign(e,AO)}},extraReducers:e=>{e.addCase(RH,((e,{payload:t})=>{e.data=t})).addCase(PH,((e,{payload:t})=>{e.data&&Object.assign(e.data,t||{})})).addCase(IH,((e,{payload:t})=>{e.isSuccess=t})).addCase(CH,((e,{payload:t})=>{e.isPending=t})).addCase($H,((e,{payload:t})=>{e.isError=t})).addCase(EH,((e,{payload:t})=>{e.error=t})).addCase(TH,((e,{payload:t})=>{var n;null!=(n=e.data)&&n.users&&(e.data.users=e.data.users.map((e=>t.id===e.id?t:e)))}))},selectors:{selectIsError:e=>e.isError,selectError:e=>e.error,selectPending:e=>e.isPending,selectData:e=>e.data,selectAccount:e=>{var t;return null==(t=e.data)?void 0:t.account},selectAccountId:e=>{var t;return null==(t=e.data)?void 0:t.account.id},selectUsers:e=>{var t;return null==(t=e.data)?void 0:t.users},selectUserById:(e,t)=>{var n;return null==(n=e.data)?void 0:n.users.find((({id:e})=>e===t))},selectCurrentUser:e=>{var t;return null==(t=e.data)?void 0:t.users.find((({id:t})=>{var n;return t===(null==(n=e.data)?void 0:n.selectedUserId)}))},selectSelectedUserId:e=>{var t;return null==(t=e.data)?void 0:t.selectedUserId},selectSuccess:e=>e.isSuccess}});var LO;const sX={value:(null==(LO=Z$())?void 0:LO.initialState)??null},uX=oo({name:"initialState",initialState:sX,reducers:{setInitialState:(e,t)=>{e.value=t.payload},clearInitialState:e=>{e.value=null}},selectors:{selectInitialState:e=>e.value}}),eC=e=>e,n0=Zn(eC,(e=>e.data)),lX=Zn(eC,(e=>e.error)),cX=Zn(eC,(e=>e.isPending)),dX=Zn(n0,(e=>null==e?void 0:e.rules)),fX=Zn(n0,(e=>null==e?void 0:e.contact_account)),pX=Zn(n0,(e=>(null==e?void 0:e.stats)&&Object.fromEntries(Object.entries(e.stats).map((([e,t])=>[e,t??0]))))),mX={data:null,isPending:!1},hX=oo({name:"instanceInfo",initialState:mX,reducers:{},extraReducers:e=>{e.addCase(zH,((e,{payload:t})=>{e.data=t})).addCase(VH,((e,{payload:t})=>{e.isPending=t})).addCase(UH,((e,{payload:t})=>{e.error=t}))},selectors:{selectInstanceInfo:n0,selectInstanceInfoError:lX,selectInstanceInfoPending:cX,selectPlatformRules:dX,selectInstanceContacts:fX,selectInstanceStats:pX,selectDescription:e=>{var t;return null==(t=e.data)?void 0:t.description},selectStats:e=>{var t;return null==(t=e.data)?void 0:t.stats},selectRegistrations:e=>{var t;return null==(t=e.data)?void 0:t.configuration.registrations}}}),vX={data:null,isPending:!1,isSuccess:!1},gX=oo({name:"profileSettings",initialState:vX,reducers:{setPending:(e,t)=>{e.isPending=t.payload},setSuccess:(e,{payload:t})=>{e.isSuccess=t},setError:(e,{payload:t})=>{e.error=t}},extraReducers:e=>{e.addCase(qH,((e,{payload:t})=>{e.data=t}))},selectors:{selectProfileSettings:e=>e.data,selectPending:e=>e.isPending,selectError:e=>e.error,selectSuccess:e=>e.isSuccess}}),yX={sms:"wellesley.admin.sms",openai:"wellesley.admin.openai",uploads:"wellesley.admin.uploads",captcha:"wellesley.admin.captcha",language:"wellesley.admin.language",mediacache:"wellesley.admin.mediacache",translation:"wellesley.admin.translation",link_service:"wellesley.admin.link_service"},aE={posts:"wellesley.posts",translation:"wellesley.translation",registration:"wellesley.registration",confirmationCode:"wellesley.confirmationCode",uploadsPolicyDoc:"wellesley.uploads.policy.doc",uploadsPolicyAudio:"wellesley.uploads.policy.audio",uploadsPolicyImage:"wellesley.uploads.policy.image",uploadsPolicyVideo:"wellesley.uploads.policy.video",captcha:"wellesley.captcha",access:"wellesley.access",branding:"wellesley.branding",instanceAdmin:"wellesley.instance.admin",legal:"wellesley.instance.legal",domainBlocks:"wellesley.instance.domainBlocks",contacts:"wellesley.instance.contacts"},Im=e=>(null==e?void 0:e.map((e=>e.value||e)))||[],wX={data:null,isPending:!1},{posts:pS,uploadsPolicyDoc:MO,uploadsPolicyAudio:mS,uploadsPolicyImage:jg,uploadsPolicyVideo:Kh,registration:M3,captcha:bX,instanceAdmin:_X,branding:xX,translation:SX,domainBlocks:EX,access:$X}=aE,{captcha:CX,language:IX,translation:RX,openai:PX,link_service:TX}=yX,sp=e=>e.data,OX=Zn(sp,(e=>{var t,n,r;return{max_characters:(null==(t=null==e?void 0:e[pS])?void 0:t.max_characters)||0,max_media_attachments:(null==(n=null==e?void 0:e[pS])?void 0:n.max_media_attachments)||0,max_pins:(null==(r=null==e?void 0:e[pS])?void 0:r.max_pins)||0}})),tC=Zn(sp,(e=>{var t,n,r;return{...null==e?void 0:e[jg],maxSize:(null==(t=null==e?void 0:e[jg])?void 0:t.maxSize)||0,maxMatrix:(null==(n=null==e?void 0:e[jg])?void 0:n.maxMatrix)||0,maxResolution:(null==(r=null==e?void 0:e[jg])?void 0:r.maxResolution)||0}})),AX=Zn(tC,(e=>Im(e.extensions))),nC=Zn(sp,(e=>{var t,n,r,o;return{...null==e?void 0:e[Kh],maxSize:(null==(t=null==e?void 0:e[Kh])?void 0:t.maxSize)||0,maxMatrix:(null==(n=null==e?void 0:e[Kh])?void 0:n.maxMatrix)||0,maxDuration:(null==(r=null==e?void 0:e[Kh])?void 0:r.maxDuration)||0,maxResolution:(null==(o=null==e?void 0:e[Kh])?void 0:o.maxResolution)||0}})),MX=Zn(nC,(e=>Im(e.extensions))),D3=Zn(sp,(e=>{var t,n;return{...null==e?void 0:e[mS],maxSize:null==(t=null==e?void 0:e[mS])?void 0:t.maxSize,keepOriginal:(null==(n=null==e?void 0:e[mS])?void 0:n.keepOriginal)||0}})),N3=Zn(sp,(e=>{var t;return{...null==e?void 0:e[MO],maxSize:(null==(t=null==e?void 0:e[MO])?void 0:t.maxSize)||0}})),k3=Zn([tC,nC,D3,N3],((e,t,n,r)=>({IMAGE:Im(null==e?void 0:e.extensions),VIDEO:Im(null==t?void 0:t.extensions),AUDIO:Im(null==n?void 0:n.extensions),DOCUMENT:Im(null==r?void 0:r.extensions)}))),DX=Zn(k3,(e=>Object.keys(e).reduce(((t,n)=>[...t,...e[n]||[]]),[]))),NX=Zn(sp,(e=>{var t;return null==(t=null==e?void 0:e[M3])?void 0:t.invites})),kX=oo({name:"platformSettings",initialState:wX,reducers:{setError:(e,t)=>{e.error=t.payload},setPending:(e,t)=>{e.isPending=t.payload}},extraReducers:e=>{e.addCase(WH,((e,{payload:t})=>{e.data={...e.data,...t}}))},selectors:{selectSettings:sp,selectPostConfig:OX,selectDocPolicy:N3,selectImagePolicy:tC,selectVideoPolicy:nC,selectAudioPolicy:D3,selectInvitesEnabled:NX,selectImageExtensions:AX,selectVideoExtensions:MX,selectSupportedExtensions:k3,selectFullExtensionsList:DX,selectRegistration:e=>{var t;return null==(t=e.data)?void 0:t[M3]},selectLanguageDetection:e=>{var t;return null==(t=e.data)?void 0:t[IX]},selectLanguageTranslation:e=>{var t;return null==(t=e.data)?void 0:t[RX]},selectOpenai:e=>{var t;return null==(t=e.data)?void 0:t[PX]},selectCaptcha:e=>{var t;return null==(t=e.data)?void 0:t[bX]},selectAdminCaptcha:e=>{var t;return null==(t=e.data)?void 0:t[CX]},selectPlatformTranslation:e=>{var t;return null==(t=e.data)?void 0:t[SX]},selectAccess:e=>{var t;return null==(t=e.data)?void 0:t[$X]},selectBranding:e=>{var t;return null==(t=e.data)?void 0:t[xX]},selectLinkService:e=>{var t;return null==(t=e.data)?void 0:t[TX]},selectInstanceAdmin:e=>{var t;return null==(t=e.data)?void 0:t[_X]},selectLegal:e=>{var t;return null==(t=e.data)?void 0:t[aE.legal]},selectDomainBlocks:e=>{var t;return null==(t=e.data)?void 0:t[EX]},selectContacts:e=>{var t;return null==(t=e.data)?void 0:t[aE.contacts]}}}),DO={data:{userId:"",list:[]},count:{},isPending:!1},LX=e=>e,FX=e=>e.error,BX=e=>e.isPending,jX=e=>{var t;return null==(t=e.count)?void 0:t.total},zX=e=>{var t;return null==(t=e.count)?void 0:t.unread},VX=e=>e.data.userId,rC=Zn(LX,(e=>e.data.list)),UX=Zn(rC,(e=>null==e?void 0:e.filter((e=>"UNREAD"===e.status)))),WX=Zn(rC,(e=>null==e?void 0:e.at(-1))),qX=oo({name:"notifications",initialState:DO,reducers:{updateNotification:(e,t)=>{var n;if(!e.data.list)return;const r=t.payload;e.data.list=null==(n=e.data.list)?void 0:n.map((e=>e.id===r.id?{...e,...r}:e))},readAll:e=>{var t;e.data.list&&(e.data.list=null==(t=e.data.list)?void 0:t.map((e=>({...e,status:"READ"}))))}},extraReducers:e=>{e.addCase(NH,((e,t)=>{e.isPending=t.payload})).addCase(MH,((e,t)=>{e.error=t.payload})).addCase(DH,((e,t)=>{const n=t.payload.userId,r=t.payload.list;e.data={userId:n,list:[...e.data.list||[],...r.filter((t=>{var n;return!(null!=(n=e.data.list)&&n.some((e=>e.id===t.id)))}))]}})).addCase(OH,((e,t)=>{e.count.unread=(e.count.unread||0)+1,e.data.list&&(e.data.list=[t.payload,...e.data.list||[]])})).addCase(AH,((e,t)=>{e.data.list&&(e.data.list=e.data.list.map((e=>e.id===t.payload.id?{...e,status:t.payload.status}:e)))})).addCase(kH,((e,t)=>{e.count.total=t.payload})).addCase(LH,((e,t)=>{e.count.unread=t.payload})).addCase(BH,(()=>DO)).addCase(jH,((e,t)=>{var n,r,o;const a=t.payload;"UNREAD"===(null==(r=null==(n=e.data.list)?void 0:n.find((e=>e.id===a)))?void 0:r.status)&&e.count.unread&&(e.count.unread-=1),e.data.list=(null==(o=e.data.list)?void 0:o.filter((e=>e.id!==a)))||[]})).addCase(FH,(e=>{e.data.list&&(e.data.list=e.data.list.map((e=>"FOLLOW_REQUEST"===e.type?{...e,followResponse:"Accepted"}:e)))}))},selectors:{selectError:FX,selectIsPending:BX,selectTotalCount:jX,selectUnreadCount:zX,selectNotifications:rC,selectUnreadNotifications:UX,selectLastNotification:WX,selectNotificationsOwner:VX}}),L3=KL(nX,Kg,t3,rX,aX,iX,uX,hX,qX,gX,kX);Vn("app/hydrate");var NO,ev={exports:{}},GX=ev.exports;
89
89
  /**
90
90
  * @license
91
91
  * Lodash <https://lodash.com/>