@riab/cpm-archiving 1.0.13-beta.3 → 1.0.13-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cpm-archiving.js +1 -1
- package/package.json +1 -1
package/dist/cpm-archiving.js
CHANGED
|
@@ -622,7 +622,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
622
622
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports}(FC)),FC.exports}var RL;function hz(){return RL||(RL=1,function(e){var t=Sme(),n=Eme(),r=lz(),i=Cme();function s(l){return t(l)||n(l)||r(l)||i()}e.exports=s,e.exports.__esModule=!0,e.exports.default=e.exports}(NC)),NC.exports}var ln={},kC={exports:{}},OL;function mz(){return OL||(OL=1,function(e){function t(n,r){return r||(r=n.slice(0)),Object.freeze(Object.defineProperties(n,{raw:{value:Object.freeze(r)}}))}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports}(kC)),kC.exports}var zh={exports:{}},Qh={exports:{}},Rme=Qh.exports,IL;function Ome(){return IL||(IL=1,function(e,t){(function(n,r){r(t)})(Rme,function(n){const r=["top","right","bottom","left"],i=["start","end"],s=r.reduce((G,re)=>G.concat(re,re+"-"+i[0],re+"-"+i[1]),[]),l=Math.min,u=Math.max,d={left:"right",right:"left",bottom:"top",top:"bottom"},m={start:"end",end:"start"};function v(G,re,fe){return u(G,l(re,fe))}function g(G,re){return typeof G=="function"?G(re):G}function y(G){return G.split("-")[0]}function b(G){return G.split("-")[1]}function A(G){return G==="x"?"y":"x"}function w(G){return G==="y"?"height":"width"}function S(G){return["top","bottom"].includes(y(G))?"y":"x"}function C(G){return A(S(G))}function M(G,re,fe){fe===void 0&&(fe=!1);const de=b(G),ce=C(G),oe=w(ce);let Ne=ce==="x"?de===(fe?"end":"start")?"right":"left":de==="start"?"bottom":"top";return re.reference[oe]>re.floating[oe]&&(Ne=O(Ne)),[Ne,O(Ne)]}function P(G){const re=O(G);return[_(G),re,_(re)]}function _(G){return G.replace(/start|end/g,re=>m[re])}function E(G,re,fe){const de=["left","right"],ce=["right","left"],oe=["top","bottom"],Ne=["bottom","top"];switch(G){case"top":case"bottom":return fe?re?ce:de:re?de:ce;case"left":case"right":return re?oe:Ne;default:return[]}}function D(G,re,fe,de){const ce=b(G);let oe=E(y(G),fe==="start",de);return ce&&(oe=oe.map(Ne=>Ne+"-"+ce),re&&(oe=oe.concat(oe.map(_)))),oe}function O(G){return G.replace(/left|right|bottom|top/g,re=>d[re])}function I(G){return{top:0,right:0,bottom:0,left:0,...G}}function T(G){return typeof G!="number"?I(G):{top:G,right:G,bottom:G,left:G}}function N(G){const{x:re,y:fe,width:de,height:ce}=G;return{width:de,height:ce,top:fe,left:re,right:re+de,bottom:fe+ce,x:re,y:fe}}function F(G,re,fe){let{reference:de,floating:ce}=G;const oe=S(re),Ne=C(re),ke=w(Ne),We=y(re),Me=oe==="y",Le=de.x+de.width/2-ce.width/2,De=de.y+de.height/2-ce.height/2,He=de[ke]/2-ce[ke]/2;let Be;switch(We){case"top":Be={x:Le,y:de.y-ce.height};break;case"bottom":Be={x:Le,y:de.y+de.height};break;case"right":Be={x:de.x+de.width,y:De};break;case"left":Be={x:de.x-ce.width,y:De};break;default:Be={x:de.x,y:de.y}}switch(b(re)){case"start":Be[Ne]-=He*(fe&&Me?-1:1);break;case"end":Be[Ne]+=He*(fe&&Me?-1:1);break}return Be}const k=async(G,re,fe)=>{const{placement:de="bottom",strategy:ce="absolute",middleware:oe=[],platform:Ne}=fe,ke=oe.filter(Boolean),We=await(Ne.isRTL==null?void 0:Ne.isRTL(re));let Me=await Ne.getElementRects({reference:G,floating:re,strategy:ce}),{x:Le,y:De}=F(Me,de,We),He=de,Be={},it=0;for(let pt=0;pt<ke.length;pt++){const{name:dt,fn:Et}=ke[pt],{x:At,y:Nt,data:It,reset:zt}=await Et({x:Le,y:De,initialPlacement:de,placement:He,strategy:ce,middlewareData:Be,rects:Me,platform:Ne,elements:{reference:G,floating:re}});Le=At??Le,De=Nt??De,Be={...Be,[dt]:{...Be[dt],...It}},zt&&it<=50&&(it++,typeof zt=="object"&&(zt.placement&&(He=zt.placement),zt.rects&&(Me=zt.rects===!0?await Ne.getElementRects({reference:G,floating:re,strategy:ce}):zt.rects),{x:Le,y:De}=F(Me,He,We)),pt=-1)}return{x:Le,y:De,placement:He,strategy:ce,middlewareData:Be}};async function H(G,re){var fe;re===void 0&&(re={});const{x:de,y:ce,platform:oe,rects:Ne,elements:ke,strategy:We}=G,{boundary:Me="clippingAncestors",rootBoundary:Le="viewport",elementContext:De="floating",altBoundary:He=!1,padding:Be=0}=g(re,G),it=T(Be),dt=ke[He?De==="floating"?"reference":"floating":De],Et=N(await oe.getClippingRect({element:(fe=await(oe.isElement==null?void 0:oe.isElement(dt)))==null||fe?dt:dt.contextElement||await(oe.getDocumentElement==null?void 0:oe.getDocumentElement(ke.floating)),boundary:Me,rootBoundary:Le,strategy:We})),At=De==="floating"?{x:de,y:ce,width:Ne.floating.width,height:Ne.floating.height}:Ne.reference,Nt=await(oe.getOffsetParent==null?void 0:oe.getOffsetParent(ke.floating)),It=await(oe.isElement==null?void 0:oe.isElement(Nt))?await(oe.getScale==null?void 0:oe.getScale(Nt))||{x:1,y:1}:{x:1,y:1},zt=N(oe.convertOffsetParentRelativeRectToViewportRelativeRect?await oe.convertOffsetParentRelativeRectToViewportRelativeRect({elements:ke,rect:At,offsetParent:Nt,strategy:We}):At);return{top:(Et.top-zt.top+it.top)/It.y,bottom:(zt.bottom-Et.bottom+it.bottom)/It.y,left:(Et.left-zt.left+it.left)/It.x,right:(zt.right-Et.right+it.right)/It.x}}const V=G=>({name:"arrow",options:G,async fn(re){const{x:fe,y:de,placement:ce,rects:oe,platform:Ne,elements:ke,middlewareData:We}=re,{element:Me,padding:Le=0}=g(G,re)||{};if(Me==null)return{};const De=T(Le),He={x:fe,y:de},Be=C(ce),it=w(Be),pt=await Ne.getDimensions(Me),dt=Be==="y",Et=dt?"top":"left",At=dt?"bottom":"right",Nt=dt?"clientHeight":"clientWidth",It=oe.reference[it]+oe.reference[Be]-He[Be]-oe.floating[it],zt=He[Be]-oe.reference[Be],J=await(Ne.getOffsetParent==null?void 0:Ne.getOffsetParent(Me));let nt=J?J[Nt]:0;(!nt||!await(Ne.isElement==null?void 0:Ne.isElement(J)))&&(nt=ke.floating[Nt]||oe.floating[it]);const ht=It/2-zt/2,te=nt/2-pt[it]/2-1,ne=l(De[Et],te),xe=l(De[At],te),Re=ne,Ve=nt-pt[it]-xe,ot=nt/2-pt[it]/2+ht,et=v(Re,ot,Ve),mt=!We.arrow&&b(ce)!=null&&ot!==et&&oe.reference[it]/2-(ot<Re?ne:xe)-pt[it]/2<0,st=mt?ot<Re?ot-Re:ot-Ve:0;return{[Be]:He[Be]+st,data:{[Be]:et,centerOffset:ot-et-st,...mt&&{alignmentOffset:st}},reset:mt}}});function ee(G,re,fe){return(G?[...fe.filter(ce=>b(ce)===G),...fe.filter(ce=>b(ce)!==G)]:fe.filter(ce=>y(ce)===ce)).filter(ce=>G?b(ce)===G||(re?_(ce)!==ce:!1):!0)}const q=function(G){return G===void 0&&(G={}),{name:"autoPlacement",options:G,async fn(re){var fe,de,ce;const{rects:oe,middlewareData:Ne,placement:ke,platform:We,elements:Me}=re,{crossAxis:Le=!1,alignment:De,allowedPlacements:He=s,autoAlignment:Be=!0,...it}=g(G,re),pt=De!==void 0||He===s?ee(De||null,Be,He):He,dt=await H(re,it),Et=((fe=Ne.autoPlacement)==null?void 0:fe.index)||0,At=pt[Et];if(At==null)return{};const Nt=M(At,oe,await(We.isRTL==null?void 0:We.isRTL(Me.floating)));if(ke!==At)return{reset:{placement:pt[0]}};const It=[dt[y(At)],dt[Nt[0]],dt[Nt[1]]],zt=[...((de=Ne.autoPlacement)==null?void 0:de.overflows)||[],{placement:At,overflows:It}],J=pt[Et+1];if(J)return{data:{index:Et+1,overflows:zt},reset:{placement:J}};const nt=zt.map(ne=>{const xe=b(ne.placement);return[ne.placement,xe&&Le?ne.overflows.slice(0,2).reduce((Re,Ve)=>Re+Ve,0):ne.overflows[0],ne.overflows]}).sort((ne,xe)=>ne[1]-xe[1]),te=((ce=nt.filter(ne=>ne[2].slice(0,b(ne[0])?2:3).every(xe=>xe<=0))[0])==null?void 0:ce[0])||nt[0][0];return te!==ke?{data:{index:Et+1,overflows:zt},reset:{placement:te}}:{}}}},Z=function(G){return G===void 0&&(G={}),{name:"flip",options:G,async fn(re){var fe,de;const{placement:ce,middlewareData:oe,rects:Ne,initialPlacement:ke,platform:We,elements:Me}=re,{mainAxis:Le=!0,crossAxis:De=!0,fallbackPlacements:He,fallbackStrategy:Be="bestFit",fallbackAxisSideDirection:it="none",flipAlignment:pt=!0,...dt}=g(G,re);if((fe=oe.arrow)!=null&&fe.alignmentOffset)return{};const Et=y(ce),At=S(ke),Nt=y(ke)===ke,It=await(We.isRTL==null?void 0:We.isRTL(Me.floating)),zt=He||(Nt||!pt?[O(ke)]:P(ke)),J=it!=="none";!He&&J&&zt.push(...D(ke,pt,it,It));const nt=[ke,...zt],ht=await H(re,dt),te=[];let ne=((de=oe.flip)==null?void 0:de.overflows)||[];if(Le&&te.push(ht[Et]),De){const et=M(ce,Ne,It);te.push(ht[et[0]],ht[et[1]])}if(ne=[...ne,{placement:ce,overflows:te}],!te.every(et=>et<=0)){var xe,Re;const et=(((xe=oe.flip)==null?void 0:xe.index)||0)+1,mt=nt[et];if(mt){var Ve;const vt=De==="alignment"?At!==S(mt):!1,Ft=((Ve=ne[0])==null?void 0:Ve.overflows[0])>0;if(!vt||Ft)return{data:{index:et,overflows:ne},reset:{placement:mt}}}let st=(Re=ne.filter(vt=>vt.overflows[0]<=0).sort((vt,Ft)=>vt.overflows[1]-Ft.overflows[1])[0])==null?void 0:Re.placement;if(!st)switch(Be){case"bestFit":{var ot;const vt=(ot=ne.filter(Ft=>{if(J){const xt=S(Ft.placement);return xt===At||xt==="y"}return!0}).map(Ft=>[Ft.placement,Ft.overflows.filter(xt=>xt>0).reduce((xt,Ht)=>xt+Ht,0)]).sort((Ft,xt)=>Ft[1]-xt[1])[0])==null?void 0:ot[0];vt&&(st=vt);break}case"initialPlacement":st=ke;break}if(ce!==st)return{reset:{placement:st}}}return{}}}};function ae(G,re){return{top:G.top-re.height,right:G.right-re.width,bottom:G.bottom-re.height,left:G.left-re.width}}function ge(G){return r.some(re=>G[re]>=0)}const Q=function(G){return G===void 0&&(G={}),{name:"hide",options:G,async fn(re){const{rects:fe}=re,{strategy:de="referenceHidden",...ce}=g(G,re);switch(de){case"referenceHidden":{const oe=await H(re,{...ce,elementContext:"reference"}),Ne=ae(oe,fe.reference);return{data:{referenceHiddenOffsets:Ne,referenceHidden:ge(Ne)}}}case"escaped":{const oe=await H(re,{...ce,altBoundary:!0}),Ne=ae(oe,fe.floating);return{data:{escapedOffsets:Ne,escaped:ge(Ne)}}}default:return{}}}}};function Y(G){const re=l(...G.map(oe=>oe.left)),fe=l(...G.map(oe=>oe.top)),de=u(...G.map(oe=>oe.right)),ce=u(...G.map(oe=>oe.bottom));return{x:re,y:fe,width:de-re,height:ce-fe}}function X(G){const re=G.slice().sort((ce,oe)=>ce.y-oe.y),fe=[];let de=null;for(let ce=0;ce<re.length;ce++){const oe=re[ce];!de||oe.y-de.y>de.height/2?fe.push([oe]):fe[fe.length-1].push(oe),de=oe}return fe.map(ce=>N(Y(ce)))}const K=function(G){return G===void 0&&(G={}),{name:"inline",options:G,async fn(re){const{placement:fe,elements:de,rects:ce,platform:oe,strategy:Ne}=re,{padding:ke=2,x:We,y:Me}=g(G,re),Le=Array.from(await(oe.getClientRects==null?void 0:oe.getClientRects(de.reference))||[]),De=X(Le),He=N(Y(Le)),Be=T(ke);function it(){if(De.length===2&&De[0].left>De[1].right&&We!=null&&Me!=null)return De.find(dt=>We>dt.left-Be.left&&We<dt.right+Be.right&&Me>dt.top-Be.top&&Me<dt.bottom+Be.bottom)||He;if(De.length>=2){if(S(fe)==="y"){const ne=De[0],xe=De[De.length-1],Re=y(fe)==="top",Ve=ne.top,ot=xe.bottom,et=Re?ne.left:xe.left,mt=Re?ne.right:xe.right,st=mt-et,vt=ot-Ve;return{top:Ve,bottom:ot,left:et,right:mt,width:st,height:vt,x:et,y:Ve}}const dt=y(fe)==="left",Et=u(...De.map(ne=>ne.right)),At=l(...De.map(ne=>ne.left)),Nt=De.filter(ne=>dt?ne.left===At:ne.right===Et),It=Nt[0].top,zt=Nt[Nt.length-1].bottom,J=At,nt=Et,ht=nt-J,te=zt-It;return{top:It,bottom:zt,left:J,right:nt,width:ht,height:te,x:J,y:It}}return He}const pt=await oe.getElementRects({reference:{getBoundingClientRect:it},floating:de.floating,strategy:Ne});return ce.reference.x!==pt.reference.x||ce.reference.y!==pt.reference.y||ce.reference.width!==pt.reference.width||ce.reference.height!==pt.reference.height?{reset:{rects:pt}}:{}}}};async function $(G,re){const{placement:fe,platform:de,elements:ce}=G,oe=await(de.isRTL==null?void 0:de.isRTL(ce.floating)),Ne=y(fe),ke=b(fe),We=S(fe)==="y",Me=["left","top"].includes(Ne)?-1:1,Le=oe&&We?-1:1,De=g(re,G);let{mainAxis:He,crossAxis:Be,alignmentAxis:it}=typeof De=="number"?{mainAxis:De,crossAxis:0,alignmentAxis:null}:{mainAxis:De.mainAxis||0,crossAxis:De.crossAxis||0,alignmentAxis:De.alignmentAxis};return ke&&typeof it=="number"&&(Be=ke==="end"?it*-1:it),We?{x:Be*Le,y:He*Me}:{x:He*Me,y:Be*Le}}const U=function(G){return G===void 0&&(G=0),{name:"offset",options:G,async fn(re){var fe,de;const{x:ce,y:oe,placement:Ne,middlewareData:ke}=re,We=await $(re,G);return Ne===((fe=ke.offset)==null?void 0:fe.placement)&&(de=ke.arrow)!=null&&de.alignmentOffset?{}:{x:ce+We.x,y:oe+We.y,data:{...We,placement:Ne}}}}},se=function(G){return G===void 0&&(G={}),{name:"shift",options:G,async fn(re){const{x:fe,y:de,placement:ce}=re,{mainAxis:oe=!0,crossAxis:Ne=!1,limiter:ke={fn:dt=>{let{x:Et,y:At}=dt;return{x:Et,y:At}}},...We}=g(G,re),Me={x:fe,y:de},Le=await H(re,We),De=S(y(ce)),He=A(De);let Be=Me[He],it=Me[De];if(oe){const dt=He==="y"?"top":"left",Et=He==="y"?"bottom":"right",At=Be+Le[dt],Nt=Be-Le[Et];Be=v(At,Be,Nt)}if(Ne){const dt=De==="y"?"top":"left",Et=De==="y"?"bottom":"right",At=it+Le[dt],Nt=it-Le[Et];it=v(At,it,Nt)}const pt=ke.fn({...re,[He]:Be,[De]:it});return{...pt,data:{x:pt.x-fe,y:pt.y-de,enabled:{[He]:oe,[De]:Ne}}}}}},je=function(G){return G===void 0&&(G={}),{options:G,fn(re){const{x:fe,y:de,placement:ce,rects:oe,middlewareData:Ne}=re,{offset:ke=0,mainAxis:We=!0,crossAxis:Me=!0}=g(G,re),Le={x:fe,y:de},De=S(ce),He=A(De);let Be=Le[He],it=Le[De];const pt=g(ke,re),dt=typeof pt=="number"?{mainAxis:pt,crossAxis:0}:{mainAxis:0,crossAxis:0,...pt};if(We){const Nt=He==="y"?"height":"width",It=oe.reference[He]-oe.floating[Nt]+dt.mainAxis,zt=oe.reference[He]+oe.reference[Nt]-dt.mainAxis;Be<It?Be=It:Be>zt&&(Be=zt)}if(Me){var Et,At;const Nt=He==="y"?"width":"height",It=["top","left"].includes(y(ce)),zt=oe.reference[De]-oe.floating[Nt]+(It&&((Et=Ne.offset)==null?void 0:Et[De])||0)+(It?0:dt.crossAxis),J=oe.reference[De]+oe.reference[Nt]+(It?0:((At=Ne.offset)==null?void 0:At[De])||0)-(It?dt.crossAxis:0);it<zt?it=zt:it>J&&(it=J)}return{[He]:Be,[De]:it}}}},me=function(G){return G===void 0&&(G={}),{name:"size",options:G,async fn(re){var fe,de;const{placement:ce,rects:oe,platform:Ne,elements:ke}=re,{apply:We=()=>{},...Me}=g(G,re),Le=await H(re,Me),De=y(ce),He=b(ce),Be=S(ce)==="y",{width:it,height:pt}=oe.floating;let dt,Et;De==="top"||De==="bottom"?(dt=De,Et=He===(await(Ne.isRTL==null?void 0:Ne.isRTL(ke.floating))?"start":"end")?"left":"right"):(Et=De,dt=He==="end"?"top":"bottom");const At=pt-Le.top-Le.bottom,Nt=it-Le.left-Le.right,It=l(pt-Le[dt],At),zt=l(it-Le[Et],Nt),J=!re.middlewareData.shift;let nt=It,ht=zt;if((fe=re.middlewareData.shift)!=null&&fe.enabled.x&&(ht=Nt),(de=re.middlewareData.shift)!=null&&de.enabled.y&&(nt=At),J&&!He){const ne=u(Le.left,0),xe=u(Le.right,0),Re=u(Le.top,0),Ve=u(Le.bottom,0);Be?ht=it-2*(ne!==0||xe!==0?ne+xe:u(Le.left,Le.right)):nt=pt-2*(Re!==0||Ve!==0?Re+Ve:u(Le.top,Le.bottom))}await We({...re,availableWidth:ht,availableHeight:nt});const te=await Ne.getDimensions(ke.floating);return it!==te.width||pt!==te.height?{reset:{rects:!0}}:{}}}};n.arrow=V,n.autoPlacement=q,n.computePosition=k,n.detectOverflow=H,n.flip=Z,n.hide=Q,n.inline=K,n.limitShift=je,n.offset=U,n.rectToClientRect=N,n.shift=se,n.size=me})}(Qh,Qh.exports)),Qh.exports}var Ime=zh.exports,DL;function Dme(){return DL||(DL=1,function(e,t){(function(n,r){r(t,Ome())})(Ime,function(n,r){const i=Math.min,s=Math.max,l=Math.round,u=Math.floor,d=te=>({x:te,y:te});function m(){return typeof window<"u"}function v(te){return b(te)?(te.nodeName||"").toLowerCase():"#document"}function g(te){var ne;return(te==null||(ne=te.ownerDocument)==null?void 0:ne.defaultView)||window}function y(te){var ne;return(ne=(b(te)?te.ownerDocument:te.document)||window.document)==null?void 0:ne.documentElement}function b(te){return m()?te instanceof Node||te instanceof g(te).Node:!1}function A(te){return m()?te instanceof Element||te instanceof g(te).Element:!1}function w(te){return m()?te instanceof HTMLElement||te instanceof g(te).HTMLElement:!1}function S(te){return!m()||typeof ShadowRoot>"u"?!1:te instanceof ShadowRoot||te instanceof g(te).ShadowRoot}function C(te){const{overflow:ne,overflowX:xe,overflowY:Re,display:Ve}=I(te);return/auto|scroll|overlay|hidden|clip/.test(ne+Re+xe)&&!["inline","contents"].includes(Ve)}function M(te){return["table","td","th"].includes(v(te))}function P(te){return[":popover-open",":modal"].some(ne=>{try{return te.matches(ne)}catch{return!1}})}function _(te){const ne=D(),xe=A(te)?I(te):te;return["transform","translate","scale","rotate","perspective"].some(Re=>xe[Re]?xe[Re]!=="none":!1)||(xe.containerType?xe.containerType!=="normal":!1)||!ne&&(xe.backdropFilter?xe.backdropFilter!=="none":!1)||!ne&&(xe.filter?xe.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(Re=>(xe.willChange||"").includes(Re))||["paint","layout","strict","content"].some(Re=>(xe.contain||"").includes(Re))}function E(te){let ne=N(te);for(;w(ne)&&!O(ne);){if(_(ne))return ne;if(P(ne))return null;ne=N(ne)}return null}function D(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function O(te){return["html","body","#document"].includes(v(te))}function I(te){return g(te).getComputedStyle(te)}function T(te){return A(te)?{scrollLeft:te.scrollLeft,scrollTop:te.scrollTop}:{scrollLeft:te.scrollX,scrollTop:te.scrollY}}function N(te){if(v(te)==="html")return te;const ne=te.assignedSlot||te.parentNode||S(te)&&te.host||y(te);return S(ne)?ne.host:ne}function F(te){const ne=N(te);return O(ne)?te.ownerDocument?te.ownerDocument.body:te.body:w(ne)&&C(ne)?ne:F(ne)}function k(te,ne,xe){var Re;ne===void 0&&(ne=[]),xe===void 0&&(xe=!0);const Ve=F(te),ot=Ve===((Re=te.ownerDocument)==null?void 0:Re.body),et=g(Ve);if(ot){const mt=H(et);return ne.concat(et,et.visualViewport||[],C(Ve)?Ve:[],mt&&xe?k(mt):[])}return ne.concat(Ve,k(Ve,[],xe))}function H(te){return te.parent&&Object.getPrototypeOf(te.parent)?te.frameElement:null}function V(te){const ne=I(te);let xe=parseFloat(ne.width)||0,Re=parseFloat(ne.height)||0;const Ve=w(te),ot=Ve?te.offsetWidth:xe,et=Ve?te.offsetHeight:Re,mt=l(xe)!==ot||l(Re)!==et;return mt&&(xe=ot,Re=et),{width:xe,height:Re,$:mt}}function ee(te){return A(te)?te:te.contextElement}function q(te){const ne=ee(te);if(!w(ne))return d(1);const xe=ne.getBoundingClientRect(),{width:Re,height:Ve,$:ot}=V(ne);let et=(ot?l(xe.width):xe.width)/Re,mt=(ot?l(xe.height):xe.height)/Ve;return(!et||!Number.isFinite(et))&&(et=1),(!mt||!Number.isFinite(mt))&&(mt=1),{x:et,y:mt}}const Z=d(0);function ae(te){const ne=g(te);return!D()||!ne.visualViewport?Z:{x:ne.visualViewport.offsetLeft,y:ne.visualViewport.offsetTop}}function ge(te,ne,xe){return ne===void 0&&(ne=!1),!xe||ne&&xe!==g(te)?!1:ne}function Q(te,ne,xe,Re){ne===void 0&&(ne=!1),xe===void 0&&(xe=!1);const Ve=te.getBoundingClientRect(),ot=ee(te);let et=d(1);ne&&(Re?A(Re)&&(et=q(Re)):et=q(te));const mt=ge(ot,xe,Re)?ae(ot):d(0);let st=(Ve.left+mt.x)/et.x,vt=(Ve.top+mt.y)/et.y,Ft=Ve.width/et.x,xt=Ve.height/et.y;if(ot){const Ht=g(ot),lt=Re&&A(Re)?g(Re):Re;let yt=Ht,kt=H(yt);for(;kt&&Re&<!==yt;){const en=q(kt),Ue=kt.getBoundingClientRect(),ct=I(kt),gt=Ue.left+(kt.clientLeft+parseFloat(ct.paddingLeft))*en.x,pe=Ue.top+(kt.clientTop+parseFloat(ct.paddingTop))*en.y;st*=en.x,vt*=en.y,Ft*=en.x,xt*=en.y,st+=gt,vt+=pe,yt=g(kt),kt=H(yt)}}return r.rectToClientRect({width:Ft,height:xt,x:st,y:vt})}function Y(te,ne){const xe=T(te).scrollLeft;return ne?ne.left+xe:Q(y(te)).left+xe}function X(te,ne,xe){xe===void 0&&(xe=!1);const Re=te.getBoundingClientRect(),Ve=Re.left+ne.scrollLeft-(xe?0:Y(te,Re)),ot=Re.top+ne.scrollTop;return{x:Ve,y:ot}}function K(te){let{elements:ne,rect:xe,offsetParent:Re,strategy:Ve}=te;const ot=Ve==="fixed",et=y(Re),mt=ne?P(ne.floating):!1;if(Re===et||mt&&ot)return xe;let st={scrollLeft:0,scrollTop:0},vt=d(1);const Ft=d(0),xt=w(Re);if((xt||!xt&&!ot)&&((v(Re)!=="body"||C(et))&&(st=T(Re)),w(Re))){const lt=Q(Re);vt=q(Re),Ft.x=lt.x+Re.clientLeft,Ft.y=lt.y+Re.clientTop}const Ht=et&&!xt&&!ot?X(et,st,!0):d(0);return{width:xe.width*vt.x,height:xe.height*vt.y,x:xe.x*vt.x-st.scrollLeft*vt.x+Ft.x+Ht.x,y:xe.y*vt.y-st.scrollTop*vt.y+Ft.y+Ht.y}}function $(te){return Array.from(te.getClientRects())}function U(te){const ne=y(te),xe=T(te),Re=te.ownerDocument.body,Ve=s(ne.scrollWidth,ne.clientWidth,Re.scrollWidth,Re.clientWidth),ot=s(ne.scrollHeight,ne.clientHeight,Re.scrollHeight,Re.clientHeight);let et=-xe.scrollLeft+Y(te);const mt=-xe.scrollTop;return I(Re).direction==="rtl"&&(et+=s(ne.clientWidth,Re.clientWidth)-Ve),{width:Ve,height:ot,x:et,y:mt}}function se(te,ne){const xe=g(te),Re=y(te),Ve=xe.visualViewport;let ot=Re.clientWidth,et=Re.clientHeight,mt=0,st=0;if(Ve){ot=Ve.width,et=Ve.height;const vt=D();(!vt||vt&&ne==="fixed")&&(mt=Ve.offsetLeft,st=Ve.offsetTop)}return{width:ot,height:et,x:mt,y:st}}function je(te,ne){const xe=Q(te,!0,ne==="fixed"),Re=xe.top+te.clientTop,Ve=xe.left+te.clientLeft,ot=w(te)?q(te):d(1),et=te.clientWidth*ot.x,mt=te.clientHeight*ot.y,st=Ve*ot.x,vt=Re*ot.y;return{width:et,height:mt,x:st,y:vt}}function me(te,ne,xe){let Re;if(ne==="viewport")Re=se(te,xe);else if(ne==="document")Re=U(y(te));else if(A(ne))Re=je(ne,xe);else{const Ve=ae(te);Re={x:ne.x-Ve.x,y:ne.y-Ve.y,width:ne.width,height:ne.height}}return r.rectToClientRect(Re)}function G(te,ne){const xe=N(te);return xe===ne||!A(xe)||O(xe)?!1:I(xe).position==="fixed"||G(xe,ne)}function re(te,ne){const xe=ne.get(te);if(xe)return xe;let Re=k(te,[],!1).filter(mt=>A(mt)&&v(mt)!=="body"),Ve=null;const ot=I(te).position==="fixed";let et=ot?N(te):te;for(;A(et)&&!O(et);){const mt=I(et),st=_(et);!st&&mt.position==="fixed"&&(Ve=null),(ot?!st&&!Ve:!st&&mt.position==="static"&&!!Ve&&["absolute","fixed"].includes(Ve.position)||C(et)&&!st&&G(te,et))?Re=Re.filter(Ft=>Ft!==et):Ve=mt,et=N(et)}return ne.set(te,Re),Re}function fe(te){let{element:ne,boundary:xe,rootBoundary:Re,strategy:Ve}=te;const et=[...xe==="clippingAncestors"?P(ne)?[]:re(ne,this._c):[].concat(xe),Re],mt=et[0],st=et.reduce((vt,Ft)=>{const xt=me(ne,Ft,Ve);return vt.top=s(xt.top,vt.top),vt.right=i(xt.right,vt.right),vt.bottom=i(xt.bottom,vt.bottom),vt.left=s(xt.left,vt.left),vt},me(ne,mt,Ve));return{width:st.right-st.left,height:st.bottom-st.top,x:st.left,y:st.top}}function de(te){const{width:ne,height:xe}=V(te);return{width:ne,height:xe}}function ce(te,ne,xe){const Re=w(ne),Ve=y(ne),ot=xe==="fixed",et=Q(te,!0,ot,ne);let mt={scrollLeft:0,scrollTop:0};const st=d(0);function vt(){st.x=Y(Ve)}if(Re||!Re&&!ot)if((v(ne)!=="body"||C(Ve))&&(mt=T(ne)),Re){const lt=Q(ne,!0,ot,ne);st.x=lt.x+ne.clientLeft,st.y=lt.y+ne.clientTop}else Ve&&vt();ot&&!Re&&Ve&&vt();const Ft=Ve&&!Re&&!ot?X(Ve,mt):d(0),xt=et.left+mt.scrollLeft-st.x-Ft.x,Ht=et.top+mt.scrollTop-st.y-Ft.y;return{x:xt,y:Ht,width:et.width,height:et.height}}function oe(te){return I(te).position==="static"}function Ne(te,ne){if(!w(te)||I(te).position==="fixed")return null;if(ne)return ne(te);let xe=te.offsetParent;return y(te)===xe&&(xe=xe.ownerDocument.body),xe}function ke(te,ne){const xe=g(te);if(P(te))return xe;if(!w(te)){let Ve=N(te);for(;Ve&&!O(Ve);){if(A(Ve)&&!oe(Ve))return Ve;Ve=N(Ve)}return xe}let Re=Ne(te,ne);for(;Re&&M(Re)&&oe(Re);)Re=Ne(Re,ne);return Re&&O(Re)&&oe(Re)&&!_(Re)?xe:Re||E(te)||xe}const We=async function(te){const ne=this.getOffsetParent||ke,xe=this.getDimensions,Re=await xe(te.floating);return{reference:ce(te.reference,await ne(te.floating),te.strategy),floating:{x:0,y:0,width:Re.width,height:Re.height}}};function Me(te){return I(te).direction==="rtl"}const Le={convertOffsetParentRelativeRectToViewportRelativeRect:K,getDocumentElement:y,getClippingRect:fe,getOffsetParent:ke,getElementRects:We,getClientRects:$,getDimensions:de,getScale:q,isElement:A,isRTL:Me};function De(te,ne){return te.x===ne.x&&te.y===ne.y&&te.width===ne.width&&te.height===ne.height}function He(te,ne){let xe=null,Re;const Ve=y(te);function ot(){var mt;clearTimeout(Re),(mt=xe)==null||mt.disconnect(),xe=null}function et(mt,st){mt===void 0&&(mt=!1),st===void 0&&(st=1),ot();const vt=te.getBoundingClientRect(),{left:Ft,top:xt,width:Ht,height:lt}=vt;if(mt||ne(),!Ht||!lt)return;const yt=u(xt),kt=u(Ve.clientWidth-(Ft+Ht)),en=u(Ve.clientHeight-(xt+lt)),Ue=u(Ft),gt={rootMargin:-yt+"px "+-kt+"px "+-en+"px "+-Ue+"px",threshold:s(0,i(1,st))||1};let pe=!0;function ve(qe){const Fe=qe[0].intersectionRatio;if(Fe!==st){if(!pe)return et();Fe?et(!1,Fe):Re=setTimeout(()=>{et(!1,1e-7)},1e3)}Fe===1&&!De(vt,te.getBoundingClientRect())&&et(),pe=!1}try{xe=new IntersectionObserver(ve,{...gt,root:Ve.ownerDocument})}catch{xe=new IntersectionObserver(ve,gt)}xe.observe(te)}return et(!0),ot}function Be(te,ne,xe,Re){Re===void 0&&(Re={});const{ancestorScroll:Ve=!0,ancestorResize:ot=!0,elementResize:et=typeof ResizeObserver=="function",layoutShift:mt=typeof IntersectionObserver=="function",animationFrame:st=!1}=Re,vt=ee(te),Ft=Ve||ot?[...vt?k(vt):[],...k(ne)]:[];Ft.forEach(Ue=>{Ve&&Ue.addEventListener("scroll",xe,{passive:!0}),ot&&Ue.addEventListener("resize",xe)});const xt=vt&&mt?He(vt,xe):null;let Ht=-1,lt=null;et&&(lt=new ResizeObserver(Ue=>{let[ct]=Ue;ct&&ct.target===vt&<&&(lt.unobserve(ne),cancelAnimationFrame(Ht),Ht=requestAnimationFrame(()=>{var gt;(gt=lt)==null||gt.observe(ne)})),xe()}),vt&&!st&<.observe(vt),lt.observe(ne));let yt,kt=st?Q(te):null;st&&en();function en(){const Ue=Q(te);kt&&!De(kt,Ue)&&xe(),kt=Ue,yt=requestAnimationFrame(en)}return xe(),()=>{var Ue;Ft.forEach(ct=>{Ve&&ct.removeEventListener("scroll",xe),ot&&ct.removeEventListener("resize",xe)}),xt?.(),(Ue=lt)==null||Ue.disconnect(),lt=null,st&&cancelAnimationFrame(yt)}}const it=r.detectOverflow,pt=r.offset,dt=r.autoPlacement,Et=r.shift,At=r.flip,Nt=r.size,It=r.hide,zt=r.arrow,J=r.inline,nt=r.limitShift,ht=(te,ne,xe)=>{const Re=new Map,Ve={platform:Le,...xe},ot={...Ve.platform,_c:Re};return r.computePosition(te,ne,{...Ve,platform:ot})};n.arrow=zt,n.autoPlacement=dt,n.autoUpdate=Be,n.computePosition=ht,n.detectOverflow=it,n.flip=At,n.getOverflowAncestors=k,n.hide=It,n.inline=J,n.limitShift=nt,n.offset=pt,n.platform=Le,n.shift=Et,n.size=Nt})}(zh,zh.exports)),zh.exports}var qC={},PL;function pz(){return PL||(PL=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=hn(),n=typeof document<"u",r=function(){},i=n?t.useLayoutEffect:r;e.default=i}(qC)),qC}var ML;function gz(){if(ML)return ln;ML=1;var e=rb(),t=Rm(),n=I0(),r=xI(),i=ib(),s=km(),l=mz(),u=AI(),d=hn(),m=h0(),v=Dme(),g=pz();function y(Ce){return Ce&&Ce.__esModule?Ce:{default:Ce}}var b=y(g),A=["className","clearValue","cx","getStyles","getClassNames","getValue","hasValue","isMulti","isRtl","options","selectOption","selectProps","setValue","theme"],w=function(){};function S(Ce,W){return W?W[0]==="-"?Ce+W:Ce+"__"+W:Ce}function C(Ce,W){for(var Oe=arguments.length,Ee=new Array(Oe>2?Oe-2:0),_e=2;_e<Oe;_e++)Ee[_e-2]=arguments[_e];var rt=[].concat(Ee);if(W&&Ce)for(var Ze in W)W.hasOwnProperty(Ze)&&W[Ze]&&rt.push("".concat(S(Ce,Ze)));return rt.filter(function(St){return St}).map(function(St){return String(St).trim()}).join(" ")}var M=function(W){return X(W)?W.filter(Boolean):s(W)==="object"&&W!==null?[W]:[]},P=function(W){W.className,W.clearValue,W.cx,W.getStyles,W.getClassNames,W.getValue,W.hasValue,W.isMulti,W.isRtl,W.options,W.selectOption,W.selectProps,W.setValue,W.theme;var Oe=i(W,A);return e({},Oe)},_=function(W,Oe,Ee){var _e=W.cx,rt=W.getStyles,Ze=W.getClassNames,St=W.className;return{css:rt(Oe,W),className:_e(Ee??{},Ze(Oe,W),St)}};function E(Ce,W,Oe){if(Oe){var Ee=Oe(Ce,W);if(typeof Ee=="string")return Ee}return Ce}function D(Ce){return[document.documentElement,document.body,window].indexOf(Ce)>-1}function O(Ce){return D(Ce)?window.innerHeight:Ce.clientHeight}function I(Ce){return D(Ce)?window.pageYOffset:Ce.scrollTop}function T(Ce,W){if(D(Ce)){window.scrollTo(0,W);return}Ce.scrollTop=W}function N(Ce){var W=getComputedStyle(Ce),Oe=W.position==="absolute",Ee=/(auto|scroll)/;if(W.position==="fixed")return document.documentElement;for(var _e=Ce;_e=_e.parentElement;)if(W=getComputedStyle(_e),!(Oe&&W.position==="static")&&Ee.test(W.overflow+W.overflowY+W.overflowX))return _e;return document.documentElement}function F(Ce,W,Oe,Ee){return Oe*((Ce=Ce/Ee-1)*Ce*Ce+1)+W}function k(Ce,W){var Oe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:200,Ee=arguments.length>3&&arguments[3]!==void 0?arguments[3]:w,_e=I(Ce),rt=W-_e,Ze=10,St=0;function _t(){St+=Ze;var An=F(St,_e,rt,Oe);T(Ce,An),St<Oe?window.requestAnimationFrame(_t):Ee(Ce)}_t()}function H(Ce,W){var Oe=Ce.getBoundingClientRect(),Ee=W.getBoundingClientRect(),_e=W.offsetHeight/3;Ee.bottom+_e>Oe.bottom?T(Ce,Math.min(W.offsetTop+W.clientHeight-Ce.offsetHeight+_e,Ce.scrollHeight)):Ee.top-_e<Oe.top&&T(Ce,Math.max(W.offsetTop-_e,0))}function V(Ce){var W=Ce.getBoundingClientRect();return{bottom:W.bottom,height:W.height,left:W.left,right:W.right,top:W.top,width:W.width}}function ee(){try{return document.createEvent("TouchEvent"),!0}catch{return!1}}function q(){try{return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}catch{return!1}}var Z=!1,ae={get passive(){return Z=!0}},ge=typeof window<"u"?window:{};ge.addEventListener&&ge.removeEventListener&&(ge.addEventListener("p",w,ae),ge.removeEventListener("p",w,!1));var Q=Z;function Y(Ce){return Ce!=null}function X(Ce){return Array.isArray(Ce)}function K(Ce,W,Oe){return Ce?W:Oe}function $(Ce){return Ce}function U(Ce){return Ce}var se=function(W){for(var Oe=arguments.length,Ee=new Array(Oe>1?Oe-1:0),_e=1;_e<Oe;_e++)Ee[_e-1]=arguments[_e];var rt=Object.entries(W).filter(function(Ze){var St=r(Ze,1),_t=St[0];return!Ee.includes(_t)});return rt.reduce(function(Ze,St){var _t=r(St,2),An=_t[0],On=_t[1];return Ze[An]=On,Ze},{})},je=["children","innerProps"],me=["children","innerProps"];function G(Ce){var W=Ce.maxHeight,Oe=Ce.menuEl,Ee=Ce.minHeight,_e=Ce.placement,rt=Ce.shouldScroll,Ze=Ce.isFixedPosition,St=Ce.controlHeight,_t=N(Oe),An={placement:"bottom",maxHeight:W};if(!Oe||!Oe.offsetParent)return An;var On=_t.getBoundingClientRect(),Mn=On.height,tr=Oe.getBoundingClientRect(),Hr=tr.bottom,ti=tr.height,Vr=tr.top,vi=Oe.offsetParent.getBoundingClientRect(),En=vi.top,Yr=Ze?window.innerHeight:O(_t),yr=I(_t),Or=parseInt(getComputedStyle(Oe).marginBottom,10),Ir=parseInt(getComputedStyle(Oe).marginTop,10),sr=En-Ir,jr=Yr-Vr,Nr=sr+yr,Vi=Mn-yr-Vr,Yi=Hr-Yr+yr+Or,ui=yr+Vr-Ir,ra=160;switch(_e){case"auto":case"bottom":if(jr>=ti)return{placement:"bottom",maxHeight:W};if(Vi>=ti&&!Ze)return rt&&k(_t,Yi,ra),{placement:"bottom",maxHeight:W};if(!Ze&&Vi>=Ee||Ze&&jr>=Ee){rt&&k(_t,Yi,ra);var Sa=Ze?jr-Or:Vi-Or;return{placement:"bottom",maxHeight:Sa}}if(_e==="auto"||Ze){var bi=W,Va=Ze?sr:Nr;return Va>=Ee&&(bi=Math.min(Va-Or-St,W)),{placement:"top",maxHeight:bi}}if(_e==="bottom")return rt&&T(_t,Yi),{placement:"bottom",maxHeight:W};break;case"top":if(sr>=ti)return{placement:"top",maxHeight:W};if(Nr>=ti&&!Ze)return rt&&k(_t,ui,ra),{placement:"top",maxHeight:W};if(!Ze&&Nr>=Ee||Ze&&sr>=Ee){var Ea=W;return(!Ze&&Nr>=Ee||Ze&&sr>=Ee)&&(Ea=Ze?sr-Ir:Nr-Ir),rt&&k(_t,ui,ra),{placement:"top",maxHeight:Ea}}return{placement:"bottom",maxHeight:W};default:throw new Error('Invalid placement provided "'.concat(_e,'".'))}return An}function re(Ce){var W={bottom:"top",top:"bottom"};return Ce?W[Ce]:"bottom"}var fe=function(W){return W==="auto"?"bottom":W},de=function(W,Oe){var Ee,_e=W.placement,rt=W.theme,Ze=rt.borderRadius,St=rt.spacing,_t=rt.colors;return e((Ee={label:"menu"},u(Ee,re(_e),"100%"),u(Ee,"position","absolute"),u(Ee,"width","100%"),u(Ee,"zIndex",1),Ee),Oe?{}:{backgroundColor:_t.neutral0,borderRadius:Ze,boxShadow:"0 0 0 1px hsla(0, 0%, 0%, 0.1), 0 4px 11px hsla(0, 0%, 0%, 0.1)",marginBottom:St.menuGutter,marginTop:St.menuGutter})},ce=d.createContext(null),oe=function(W){var Oe=W.children,Ee=W.minMenuHeight,_e=W.maxMenuHeight,rt=W.menuPlacement,Ze=W.menuPosition,St=W.menuShouldScrollIntoView,_t=W.theme,An=d.useContext(ce)||{},On=An.setPortalPlacement,Mn=d.useRef(null),tr=d.useState(_e),Hr=r(tr,2),ti=Hr[0],Vr=Hr[1],vi=d.useState(null),En=r(vi,2),Yr=En[0],yr=En[1],Or=_t.spacing.controlHeight;return b.default(function(){var Ir=Mn.current;if(Ir){var sr=Ze==="fixed",jr=St&&!sr,Nr=G({maxHeight:_e,menuEl:Ir,minHeight:Ee,placement:rt,shouldScroll:jr,isFixedPosition:sr,controlHeight:Or});Vr(Nr.maxHeight),yr(Nr.placement),On?.(Nr.placement)}},[_e,rt,Ze,St,Ee,On,Or]),Oe({ref:Mn,placerProps:e(e({},W),{},{placement:Yr||fe(rt),maxHeight:ti})})},Ne=function(W){var Oe=W.children,Ee=W.innerRef,_e=W.innerProps;return n.jsx("div",t({},_(W,"menu",{menu:!0}),{ref:Ee},_e),Oe)},ke=Ne,We=function(W,Oe){var Ee=W.maxHeight,_e=W.theme.spacing.baseUnit;return e({maxHeight:Ee,overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},Oe?{}:{paddingBottom:_e,paddingTop:_e})},Me=function(W){var Oe=W.children,Ee=W.innerProps,_e=W.innerRef,rt=W.isMulti;return n.jsx("div",t({},_(W,"menuList",{"menu-list":!0,"menu-list--is-multi":rt}),{ref:_e},Ee),Oe)},Le=function(W,Oe){var Ee=W.theme,_e=Ee.spacing.baseUnit,rt=Ee.colors;return e({textAlign:"center"},Oe?{}:{color:rt.neutral40,padding:"".concat(_e*2,"px ").concat(_e*3,"px")})},De=Le,He=Le,Be=function(W){var Oe=W.children,Ee=Oe===void 0?"No options":Oe,_e=W.innerProps,rt=i(W,je);return n.jsx("div",t({},_(e(e({},rt),{},{children:Ee,innerProps:_e}),"noOptionsMessage",{"menu-notice":!0,"menu-notice--no-options":!0}),_e),Ee)},it=function(W){var Oe=W.children,Ee=Oe===void 0?"Loading...":Oe,_e=W.innerProps,rt=i(W,me);return n.jsx("div",t({},_(e(e({},rt),{},{children:Ee,innerProps:_e}),"loadingMessage",{"menu-notice":!0,"menu-notice--loading":!0}),_e),Ee)},pt=function(W){var Oe=W.rect,Ee=W.offset,_e=W.position;return{left:Oe.left,position:_e,top:Ee,width:Oe.width,zIndex:1}},dt=function(W){var Oe=W.appendTo,Ee=W.children,_e=W.controlElement,rt=W.innerProps,Ze=W.menuPlacement,St=W.menuPosition,_t=d.useRef(null),An=d.useRef(null),On=d.useState(fe(Ze)),Mn=r(On,2),tr=Mn[0],Hr=Mn[1],ti=d.useMemo(function(){return{setPortalPlacement:Hr}},[]),Vr=d.useState(null),vi=r(Vr,2),En=vi[0],Yr=vi[1],yr=d.useCallback(function(){if(_e){var jr=V(_e),Nr=St==="fixed"?0:window.pageYOffset,Vi=jr[tr]+Nr;(Vi!==En?.offset||jr.left!==En?.rect.left||jr.width!==En?.rect.width)&&Yr({offset:Vi,rect:jr})}},[_e,St,tr,En?.offset,En?.rect.left,En?.rect.width]);b.default(function(){yr()},[yr]);var Or=d.useCallback(function(){typeof An.current=="function"&&(An.current(),An.current=null),_e&&_t.current&&(An.current=v.autoUpdate(_e,_t.current,yr,{elementResize:"ResizeObserver"in window}))},[_e,yr]);b.default(function(){Or()},[Or]);var Ir=d.useCallback(function(jr){_t.current=jr,Or()},[Or]);if(!Oe&&St!=="fixed"||!En)return null;var sr=n.jsx("div",t({ref:Ir},_(e(e({},W),{},{offset:En.offset,position:St,rect:En.rect}),"menuPortal",{"menu-portal":!0}),rt),Ee);return n.jsx(ce.Provider,{value:ti},Oe?m.createPortal(sr,Oe):sr)},Et=function(W){var Oe=W.isDisabled,Ee=W.isRtl;return{label:"container",direction:Ee?"rtl":void 0,pointerEvents:Oe?"none":void 0,position:"relative"}},At=function(W){var Oe=W.children,Ee=W.innerProps,_e=W.isDisabled,rt=W.isRtl;return n.jsx("div",t({},_(W,"container",{"--is-disabled":_e,"--is-rtl":rt}),Ee),Oe)},Nt=function(W,Oe){var Ee=W.theme.spacing,_e=W.isMulti,rt=W.hasValue,Ze=W.selectProps.controlShouldRenderValue;return e({alignItems:"center",display:_e&&rt&&Ze?"flex":"grid",flex:1,flexWrap:"wrap",WebkitOverflowScrolling:"touch",position:"relative",overflow:"hidden"},Oe?{}:{padding:"".concat(Ee.baseUnit/2,"px ").concat(Ee.baseUnit*2,"px")})},It=function(W){var Oe=W.children,Ee=W.innerProps,_e=W.isMulti,rt=W.hasValue;return n.jsx("div",t({},_(W,"valueContainer",{"value-container":!0,"value-container--is-multi":_e,"value-container--has-value":rt}),Ee),Oe)},zt=function(){return{alignItems:"center",alignSelf:"stretch",display:"flex",flexShrink:0}},J=function(W){var Oe=W.children,Ee=W.innerProps;return n.jsx("div",t({},_(W,"indicatorsContainer",{indicators:!0}),Ee),Oe)},nt,ht=["size"],te=["innerProps","isRtl","size"],ne={name:"8mmkcg",styles:"display:inline-block;fill:currentColor;line-height:1;stroke:currentColor;stroke-width:0"},xe=function(W){var Oe=W.size,Ee=i(W,ht);return n.jsx("svg",t({height:Oe,width:Oe,viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",css:ne},Ee))},Re=function(W){return n.jsx(xe,t({size:20},W),n.jsx("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"}))},Ve=function(W){return n.jsx(xe,t({size:20},W),n.jsx("path",{d:"M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747 3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0 1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502 0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0 0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z"}))},ot=function(W,Oe){var Ee=W.isFocused,_e=W.theme,rt=_e.spacing.baseUnit,Ze=_e.colors;return e({label:"indicatorContainer",display:"flex",transition:"color 150ms"},Oe?{}:{color:Ee?Ze.neutral60:Ze.neutral20,padding:rt*2,":hover":{color:Ee?Ze.neutral80:Ze.neutral40}})},et=ot,mt=function(W){var Oe=W.children,Ee=W.innerProps;return n.jsx("div",t({},_(W,"dropdownIndicator",{indicator:!0,"dropdown-indicator":!0}),Ee),Oe||n.jsx(Ve,null))},st=ot,vt=function(W){var Oe=W.children,Ee=W.innerProps;return n.jsx("div",t({},_(W,"clearIndicator",{indicator:!0,"clear-indicator":!0}),Ee),Oe||n.jsx(Re,null))},Ft=function(W,Oe){var Ee=W.isDisabled,_e=W.theme,rt=_e.spacing.baseUnit,Ze=_e.colors;return e({label:"indicatorSeparator",alignSelf:"stretch",width:1},Oe?{}:{backgroundColor:Ee?Ze.neutral10:Ze.neutral20,marginBottom:rt*2,marginTop:rt*2})},xt=function(W){var Oe=W.innerProps;return n.jsx("span",t({},Oe,_(W,"indicatorSeparator",{"indicator-separator":!0})))},Ht=n.keyframes(nt||(nt=l([`
|
|
623
623
|
0%, 80%, 100% { opacity: 0; }
|
|
624
624
|
40% { opacity: 1; }
|
|
625
|
-
`]))),lt=function(W,Oe){var Ee=W.isFocused,_e=W.size,rt=W.theme,Ze=rt.colors,St=rt.spacing.baseUnit;return e({label:"loadingIndicator",display:"flex",transition:"color 150ms",alignSelf:"center",fontSize:_e,lineHeight:1,marginRight:_e,textAlign:"center",verticalAlign:"middle"},Oe?{}:{color:Ee?Ze.neutral60:Ze.neutral20,padding:St*2})},yt=function(W){var Oe=W.delay,Ee=W.offset;return n.jsx("span",{css:n.css({animation:"".concat(Ht," 1s ease-in-out ").concat(Oe,"ms infinite;"),backgroundColor:"currentColor",borderRadius:"1em",display:"inline-block",marginLeft:Ee?"1em":void 0,height:"1em",verticalAlign:"top",width:"1em"},"","")})},kt=function(W){var Oe=W.innerProps,Ee=W.isRtl,_e=W.size,rt=_e===void 0?4:_e,Ze=i(W,te);return n.jsx("div",t({},_(e(e({},Ze),{},{innerProps:Oe,isRtl:Ee,size:rt}),"loadingIndicator",{indicator:!0,"loading-indicator":!0}),Oe),n.jsx(yt,{delay:0,offset:Ee}),n.jsx(yt,{delay:160,offset:!0}),n.jsx(yt,{delay:320,offset:!Ee}))},en=function(W,Oe){var Ee=W.isDisabled,_e=W.isFocused,rt=W.theme,Ze=rt.colors,St=rt.borderRadius,_t=rt.spacing;return e({label:"control",alignItems:"center",cursor:"default",display:"flex",flexWrap:"wrap",justifyContent:"space-between",minHeight:_t.controlHeight,outline:"0 !important",position:"relative",transition:"all 100ms"},Oe?{}:{backgroundColor:Ee?Ze.neutral5:Ze.neutral0,borderColor:Ee?Ze.neutral10:_e?Ze.primary:Ze.neutral20,borderRadius:St,borderStyle:"solid",borderWidth:1,boxShadow:_e?"0 0 0 1px ".concat(Ze.primary):void 0,"&:hover":{borderColor:_e?Ze.primary:Ze.neutral30}})},Ue=function(W){var Oe=W.children,Ee=W.isDisabled,_e=W.isFocused,rt=W.innerRef,Ze=W.innerProps,St=W.menuIsOpen;return n.jsx("div",t({ref:rt},_(W,"control",{control:!0,"control--is-disabled":Ee,"control--is-focused":_e,"control--menu-is-open":St}),Ze,{"aria-disabled":Ee||void 0}),Oe)},ct=Ue,gt=["data"],pe=function(W,Oe){var Ee=W.theme.spacing;return Oe?{}:{paddingBottom:Ee.baseUnit*2,paddingTop:Ee.baseUnit*2}},ve=function(W){var Oe=W.children,Ee=W.cx,_e=W.getStyles,rt=W.getClassNames,Ze=W.Heading,St=W.headingProps,_t=W.innerProps,An=W.label,On=W.theme,Mn=W.selectProps;return n.jsx("div",t({},_(W,"group",{group:!0}),_t),n.jsx(Ze,t({},St,{selectProps:Mn,theme:On,getStyles:_e,getClassNames:rt,cx:Ee}),An),n.jsx("div",null,Oe))},qe=function(W,Oe){var Ee=W.theme,_e=Ee.colors,rt=Ee.spacing;return e({label:"group",cursor:"default",display:"block"},Oe?{}:{color:_e.neutral40,fontSize:"75%",fontWeight:500,marginBottom:"0.25em",paddingLeft:rt.baseUnit*3,paddingRight:rt.baseUnit*3,textTransform:"uppercase"})},Fe=function(W){var Oe=P(W);Oe.data;var Ee=i(Oe,gt);return n.jsx("div",t({},_(W,"groupHeading",{"group-heading":!0}),Ee))},L=ve,Te=["innerRef","isDisabled","isHidden","inputClassName"],Qe=function(W,Oe){var Ee=W.isDisabled,_e=W.value,rt=W.theme,Ze=rt.spacing,St=rt.colors;return e(e({visibility:Ee?"hidden":"visible",transform:_e?"translateZ(0)":""},le),Oe?{}:{margin:Ze.baseUnit/2,paddingBottom:Ze.baseUnit/2,paddingTop:Ze.baseUnit/2,color:St.neutral80})},tt={gridArea:"1 / 2",font:"inherit",minWidth:"2px",border:0,margin:0,outline:0,padding:0},le={flex:"1 1 auto",display:"inline-grid",gridArea:"1 / 1 / 2 / 3",gridTemplateColumns:"0 min-content","&:after":e({content:'attr(data-value) " "',visibility:"hidden",whiteSpace:"pre"},tt)},Pe=function(W){return e({label:"input",color:"inherit",background:0,opacity:W?0:1,width:"100%"},tt)},ze=function(W){var Oe=W.cx,Ee=W.value,_e=P(W),rt=_e.innerRef,Ze=_e.isDisabled,St=_e.isHidden,_t=_e.inputClassName,An=i(_e,Te);return n.jsx("div",t({},_(W,"input",{"input-container":!0}),{"data-value":Ee||""}),n.jsx("input",t({className:Oe({input:!0},_t),ref:rt,style:Pe(St),disabled:Ze},An)))},at=ze,Ot=function(W,Oe){var Ee=W.theme,_e=Ee.spacing,rt=Ee.borderRadius,Ze=Ee.colors;return e({label:"multiValue",display:"flex",minWidth:0},Oe?{}:{backgroundColor:Ze.neutral10,borderRadius:rt/2,margin:_e.baseUnit/2})},Ct=function(W,Oe){var Ee=W.theme,_e=Ee.borderRadius,rt=Ee.colors,Ze=W.cropWithEllipsis;return e({overflow:"hidden",textOverflow:Ze||Ze===void 0?"ellipsis":void 0,whiteSpace:"nowrap"},Oe?{}:{borderRadius:_e/2,color:rt.neutral80,fontSize:"85%",padding:3,paddingLeft:6})},jt=function(W,Oe){var Ee=W.theme,_e=Ee.spacing,rt=Ee.borderRadius,Ze=Ee.colors,St=W.isFocused;return e({alignItems:"center",display:"flex"},Oe?{}:{borderRadius:rt/2,backgroundColor:St?Ze.dangerLight:void 0,paddingLeft:_e.baseUnit,paddingRight:_e.baseUnit,":hover":{backgroundColor:Ze.dangerLight,color:Ze.danger}})},ft=function(W){var Oe=W.children,Ee=W.innerProps;return n.jsx("div",Ee,Oe)},ut=ft,tn=ft;function mn(Ce){var W=Ce.children,Oe=Ce.innerProps;return n.jsx("div",t({role:"button"},Oe),W||n.jsx(Re,{size:14}))}var wn=function(W){var Oe=W.children,Ee=W.components,_e=W.data,rt=W.innerProps,Ze=W.isDisabled,St=W.removeProps,_t=W.selectProps,An=Ee.Container,On=Ee.Label,Mn=Ee.Remove;return n.jsx(An,{data:_e,innerProps:e(e({},_(W,"multiValue",{"multi-value":!0,"multi-value--is-disabled":Ze})),rt),selectProps:_t},n.jsx(On,{data:_e,innerProps:e({},_(W,"multiValueLabel",{"multi-value__label":!0})),selectProps:_t},Oe),n.jsx(Mn,{data:_e,innerProps:e(e({},_(W,"multiValueRemove",{"multi-value__remove":!0})),{},{"aria-label":"Remove ".concat(Oe||"option")},St),selectProps:_t}))},Sn=wn,yn=function(W,Oe){var Ee=W.isDisabled,_e=W.isFocused,rt=W.isSelected,Ze=W.theme,St=Ze.spacing,_t=Ze.colors;return e({label:"option",cursor:"default",display:"block",fontSize:"inherit",width:"100%",userSelect:"none",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)"},Oe?{}:{backgroundColor:rt?_t.primary:_e?_t.primary25:"transparent",color:Ee?_t.neutral20:rt?_t.neutral0:"inherit",padding:"".concat(St.baseUnit*2,"px ").concat(St.baseUnit*3,"px"),":active":{backgroundColor:Ee?void 0:rt?_t.primary:_t.primary50}})},Jn=function(W){var Oe=W.children,Ee=W.isDisabled,_e=W.isFocused,rt=W.isSelected,Ze=W.innerRef,St=W.innerProps;return n.jsx("div",t({},_(W,"option",{option:!0,"option--is-disabled":Ee,"option--is-focused":_e,"option--is-selected":rt}),{ref:Ze,"aria-disabled":Ee},St),Oe)},$n=Jn,an=function(W,Oe){var Ee=W.theme,_e=Ee.spacing,rt=Ee.colors;return e({label:"placeholder",gridArea:"1 / 1 / 2 / 3"},Oe?{}:{color:rt.neutral50,marginLeft:_e.baseUnit/2,marginRight:_e.baseUnit/2})},ar=function(W){var Oe=W.children,Ee=W.innerProps;return n.jsx("div",t({},_(W,"placeholder",{placeholder:!0}),Ee),Oe)},Rr=ar,ei=function(W,Oe){var Ee=W.isDisabled,_e=W.theme,rt=_e.spacing,Ze=_e.colors;return e({label:"singleValue",gridArea:"1 / 1 / 2 / 3",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},Oe?{}:{color:Ee?Ze.neutral40:Ze.neutral80,marginLeft:rt.baseUnit/2,marginRight:rt.baseUnit/2})},Qr=function(W){var Oe=W.children,Ee=W.isDisabled,_e=W.innerProps;return n.jsx("div",t({},_(W,"singleValue",{"single-value":!0,"single-value--is-disabled":Ee}),_e),Oe)},er=Qr,_i={ClearIndicator:vt,Control:ct,DropdownIndicator:mt,DownChevron:Ve,CrossIcon:Re,Group:L,GroupHeading:Fe,IndicatorsContainer:J,IndicatorSeparator:xt,Input:at,LoadingIndicator:kt,Menu:ke,MenuList:Me,MenuPortal:dt,LoadingMessage:it,NoOptionsMessage:Be,MultiValue:Sn,MultiValueContainer:ut,MultiValueLabel:tn,MultiValueRemove:mn,Option:$n,Placeholder:Rr,SelectContainer:At,SingleValue:er,ValueContainer:It},br=function(W){return e(e({},_i),W.components)};return ln.MenuPlacer=oe,ln.classNames=C,ln.cleanValue=M,ln.clearIndicatorCSS=st,ln.components=_i,ln.containerCSS=Et,ln.css=en,ln.css$1=ei,ln.defaultComponents=br,ln.dropdownIndicatorCSS=et,ln.groupCSS=pe,ln.groupHeadingCSS=qe,ln.handleInputChange=E,ln.indicatorSeparatorCSS=Ft,ln.indicatorsContainerCSS=zt,ln.inputCSS=Qe,ln.isDocumentElement=D,ln.isMobileDevice=q,ln.isTouchCapable=ee,ln.loadingIndicatorCSS=lt,ln.loadingMessageCSS=He,ln.menuCSS=de,ln.menuListCSS=We,ln.menuPortalCSS=pt,ln.multiValueAsValue=U,ln.multiValueCSS=Ot,ln.multiValueLabelCSS=Ct,ln.multiValueRemoveCSS=jt,ln.noOptionsMessageCSS=De,ln.noop=w,ln.notNullish=Y,ln.optionCSS=yn,ln.placeholderCSS=an,ln.removeProps=se,ln.scrollIntoView=H,ln.singleValueAsValue=$,ln.supportsPassiveEvents=Q,ln.valueContainerCSS=Nt,ln.valueTernary=K,ln}var TL=Number.isNaN||function(t){return typeof t=="number"&&t!==t};function Pme(e,t){return!!(e===t||TL(e)&&TL(t))}function Mme(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(!Pme(e[n],t[n]))return!1;return!0}function Tme(e,t){t===void 0&&(t=Mme);var n=null;function r(){for(var i=[],s=0;s<arguments.length;s++)i[s]=arguments[s];if(n&&n.lastThis===this&&t(i,n.lastArgs))return n.lastResult;var l=e.apply(this,i);return n={lastResult:l,lastArgs:i,lastThis:this},l}return r.clear=function(){n=null},r}const _me=Object.freeze(Object.defineProperty({__proto__:null,default:Tme},Symbol.toStringTag,{value:"Module"})),jme=f0(_me);var _L;function Nme(){if(_L)return Ls;_L=1;var e=Rm(),t=rb(),n=uz(),r=cz(),i=dz(),s=fz(),l=hz(),u=hn(),d=gz(),m=I0(),v=jme,g=ib();function y(pe){return pe&&pe.__esModule?pe:{default:pe}}function b(pe){if(pe&&pe.__esModule)return pe;var ve=Object.create(null);return pe&&Object.keys(pe).forEach(function(qe){if(qe!=="default"){var Fe=Object.getOwnPropertyDescriptor(pe,qe);Object.defineProperty(ve,qe,Fe.get?Fe:{enumerable:!0,get:function(){return pe[qe]}})}}),ve.default=pe,Object.freeze(ve)}for(var A=b(u),w=y(v),S={name:"7pg0cj-a11yText",styles:"label:a11yText;z-index:9999;border:0;clip:rect(1px, 1px, 1px, 1px);height:1px;width:1px;position:absolute;overflow:hidden;padding:0;white-space:nowrap"},C=function(ve){return m.jsx("span",e({css:S},ve))},M=C,P={guidance:function(ve){var qe=ve.isSearchable,Fe=ve.isMulti,L=ve.tabSelectsValue,Te=ve.context,Qe=ve.isInitialFocus;switch(Te){case"menu":return"Use Up and Down to choose options, press Enter to select the currently focused option, press Escape to exit the menu".concat(L?", press Tab to select the option and exit the menu":"",".");case"input":return Qe?"".concat(ve["aria-label"]||"Select"," is focused ").concat(qe?",type to refine list":"",", press Down to open the menu, ").concat(Fe?" press left to focus selected values":""):"";case"value":return"Use left and right to toggle between focused values, press Backspace to remove the currently focused value";default:return""}},onChange:function(ve){var qe=ve.action,Fe=ve.label,L=Fe===void 0?"":Fe,Te=ve.labels,Qe=ve.isDisabled;switch(qe){case"deselect-option":case"pop-value":case"remove-value":return"option ".concat(L,", deselected.");case"clear":return"All selected options have been cleared.";case"initial-input-focus":return"option".concat(Te.length>1?"s":""," ").concat(Te.join(","),", selected.");case"select-option":return Qe?"option ".concat(L," is disabled. Select another option."):"option ".concat(L,", selected.");default:return""}},onFocus:function(ve){var qe=ve.context,Fe=ve.focused,L=ve.options,Te=ve.label,Qe=Te===void 0?"":Te,tt=ve.selectValue,le=ve.isDisabled,Pe=ve.isSelected,ze=ve.isAppleDevice,at=function(ft,ut){return ft&&ft.length?"".concat(ft.indexOf(ut)+1," of ").concat(ft.length):""};if(qe==="value"&&tt)return"value ".concat(Qe," focused, ").concat(at(tt,Fe),".");if(qe==="menu"&&ze){var Ot=le?" disabled":"",Ct="".concat(Pe?" selected":"").concat(Ot);return"".concat(Qe).concat(Ct,", ").concat(at(L,Fe),".")}return""},onFilter:function(ve){var qe=ve.inputValue,Fe=ve.resultsMessage;return"".concat(Fe).concat(qe?" for search term "+qe:"",".")}},_=function(ve){var qe=ve.ariaSelection,Fe=ve.focusedOption,L=ve.focusedValue,Te=ve.focusableOptions,Qe=ve.isFocused,tt=ve.selectValue,le=ve.selectProps,Pe=ve.id,ze=ve.isAppleDevice,at=le.ariaLiveMessages,Ot=le.getOptionLabel,Ct=le.inputValue,jt=le.isMulti,ft=le.isOptionDisabled,ut=le.isSearchable,tn=le.menuIsOpen,mn=le.options,wn=le.screenReaderStatus,Sn=le.tabSelectsValue,yn=le.isLoading,Jn=le["aria-label"],$n=le["aria-live"],an=u.useMemo(function(){return t(t({},P),at||{})},[at]),ar=u.useMemo(function(){var br="";if(qe&&an.onChange){var Ce=qe.option,W=qe.options,Oe=qe.removedValue,Ee=qe.removedValues,_e=qe.value,rt=function(tr){return Array.isArray(tr)?null:tr},Ze=Oe||Ce||rt(_e),St=Ze?Ot(Ze):"",_t=W||Ee||void 0,An=_t?_t.map(Ot):[],On=t({isDisabled:Ze&&ft(Ze,tt),label:St,labels:An},qe);br=an.onChange(On)}return br},[qe,an,ft,tt,Ot]),Rr=u.useMemo(function(){var br="",Ce=Fe||L,W=!!(Fe&&tt&&tt.includes(Fe));if(Ce&&an.onFocus){var Oe={focused:Ce,label:Ot(Ce),isDisabled:ft(Ce,tt),isSelected:W,options:Te,context:Ce===Fe?"menu":"value",selectValue:tt,isAppleDevice:ze};br=an.onFocus(Oe)}return br},[Fe,L,Ot,ft,an,Te,tt,ze]),ei=u.useMemo(function(){var br="";if(tn&&mn.length&&!yn&&an.onFilter){var Ce=wn({count:Te.length});br=an.onFilter({inputValue:Ct,resultsMessage:Ce})}return br},[Te,Ct,tn,an,mn,wn,yn]),Qr=qe?.action==="initial-input-focus",er=u.useMemo(function(){var br="";if(an.guidance){var Ce=L?"value":tn?"menu":"input";br=an.guidance({"aria-label":Jn,context:Ce,isDisabled:Fe&&ft(Fe,tt),isMulti:jt,isSearchable:ut,tabSelectsValue:Sn,isInitialFocus:Qr})}return br},[Jn,Fe,L,jt,ft,ut,tn,an,tt,Sn,Qr]),_i=m.jsx(u.Fragment,null,m.jsx("span",{id:"aria-selection"},ar),m.jsx("span",{id:"aria-focused"},Rr),m.jsx("span",{id:"aria-results"},ei),m.jsx("span",{id:"aria-guidance"},er));return m.jsx(u.Fragment,null,m.jsx(M,{id:Pe},Qr&&_i),m.jsx(M,{"aria-live":$n,"aria-atomic":"false","aria-relevant":"additions text",role:"log"},Qe&&!Qr&&_i))},E=_,D=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],O=new RegExp("["+D.map(function(pe){return pe.letters}).join("")+"]","g"),I={},T=0;T<D.length;T++)for(var N=D[T],F=0;F<N.letters.length;F++)I[N.letters[F]]=N.base;var k=function(ve){return ve.replace(O,function(qe){return I[qe]})},H=w.default(k),V=function(ve){return ve.replace(/^\s+|\s+$/g,"")},ee=function(ve){return"".concat(ve.label," ").concat(ve.value)},q=function(ve){return function(qe,Fe){if(qe.data.__isNew__)return!0;var L=t({ignoreCase:!0,ignoreAccents:!0,stringify:ee,trim:!0,matchFrom:"any"},ve),Te=L.ignoreCase,Qe=L.ignoreAccents,tt=L.stringify,le=L.trim,Pe=L.matchFrom,ze=le?V(Fe):Fe,at=le?V(tt(qe)):tt(qe);return Te&&(ze=ze.toLowerCase(),at=at.toLowerCase()),Qe&&(ze=H(ze),at=k(at)),Pe==="start"?at.substr(0,ze.length)===ze:at.indexOf(ze)>-1}},Z=["innerRef"];function ae(pe){var ve=pe.innerRef,qe=g(pe,Z),Fe=d.removeProps(qe,"onExited","in","enter","exit","appear");return m.jsx("input",e({ref:ve},Fe,{css:m.css({label:"dummyInput",background:0,border:0,caretColor:"transparent",fontSize:"inherit",gridArea:"1 / 1 / 2 / 3",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(.01)"},"","")}))}var ge=function(ve){ve.cancelable&&ve.preventDefault(),ve.stopPropagation()};function Q(pe){var ve=pe.isEnabled,qe=pe.onBottomArrive,Fe=pe.onBottomLeave,L=pe.onTopArrive,Te=pe.onTopLeave,Qe=u.useRef(!1),tt=u.useRef(!1),le=u.useRef(0),Pe=u.useRef(null),ze=u.useCallback(function(ut,tn){if(Pe.current!==null){var mn=Pe.current,wn=mn.scrollTop,Sn=mn.scrollHeight,yn=mn.clientHeight,Jn=Pe.current,$n=tn>0,an=Sn-yn-wn,ar=!1;an>tn&&Qe.current&&(Fe&&Fe(ut),Qe.current=!1),$n&&tt.current&&(Te&&Te(ut),tt.current=!1),$n&&tn>an?(qe&&!Qe.current&&qe(ut),Jn.scrollTop=Sn,ar=!0,Qe.current=!0):!$n&&-tn>wn&&(L&&!tt.current&&L(ut),Jn.scrollTop=0,ar=!0,tt.current=!0),ar&&ge(ut)}},[qe,Fe,L,Te]),at=u.useCallback(function(ut){ze(ut,ut.deltaY)},[ze]),Ot=u.useCallback(function(ut){le.current=ut.changedTouches[0].clientY},[]),Ct=u.useCallback(function(ut){var tn=le.current-ut.changedTouches[0].clientY;ze(ut,tn)},[ze]),jt=u.useCallback(function(ut){if(ut){var tn=d.supportsPassiveEvents?{passive:!1}:!1;ut.addEventListener("wheel",at,tn),ut.addEventListener("touchstart",Ot,tn),ut.addEventListener("touchmove",Ct,tn)}},[Ct,Ot,at]),ft=u.useCallback(function(ut){ut&&(ut.removeEventListener("wheel",at,!1),ut.removeEventListener("touchstart",Ot,!1),ut.removeEventListener("touchmove",Ct,!1))},[Ct,Ot,at]);return u.useEffect(function(){if(ve){var ut=Pe.current;return jt(ut),function(){ft(ut)}}},[ve,jt,ft]),function(ut){Pe.current=ut}}var Y=["boxSizing","height","overflow","paddingRight","position"],X={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function K(pe){pe.cancelable&&pe.preventDefault()}function $(pe){pe.stopPropagation()}function U(){var pe=this.scrollTop,ve=this.scrollHeight,qe=pe+this.offsetHeight;pe===0?this.scrollTop=1:qe===ve&&(this.scrollTop=pe-1)}function se(){return"ontouchstart"in window||navigator.maxTouchPoints}var je=!!(typeof window<"u"&&window.document&&window.document.createElement),me=0,G={capture:!1,passive:!1};function re(pe){var ve=pe.isEnabled,qe=pe.accountForScrollbars,Fe=qe===void 0?!0:qe,L=u.useRef({}),Te=u.useRef(null),Qe=u.useCallback(function(le){if(je){var Pe=document.body,ze=Pe&&Pe.style;if(Fe&&Y.forEach(function(jt){var ft=ze&&ze[jt];L.current[jt]=ft}),Fe&&me<1){var at=parseInt(L.current.paddingRight,10)||0,Ot=document.body?document.body.clientWidth:0,Ct=window.innerWidth-Ot+at||0;Object.keys(X).forEach(function(jt){var ft=X[jt];ze&&(ze[jt]=ft)}),ze&&(ze.paddingRight="".concat(Ct,"px"))}Pe&&se()&&(Pe.addEventListener("touchmove",K,G),le&&(le.addEventListener("touchstart",U,G),le.addEventListener("touchmove",$,G))),me+=1}},[Fe]),tt=u.useCallback(function(le){if(je){var Pe=document.body,ze=Pe&&Pe.style;me=Math.max(me-1,0),Fe&&me<1&&Y.forEach(function(at){var Ot=L.current[at];ze&&(ze[at]=Ot)}),Pe&&se()&&(Pe.removeEventListener("touchmove",K,G),le&&(le.removeEventListener("touchstart",U,G),le.removeEventListener("touchmove",$,G)))}},[Fe]);return u.useEffect(function(){if(ve){var le=Te.current;return Qe(le),function(){tt(le)}}},[ve,Qe,tt]),function(le){Te.current=le}}var fe=function(ve){var qe=ve.target;return qe.ownerDocument.activeElement&&qe.ownerDocument.activeElement.blur()},de={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function ce(pe){var ve=pe.children,qe=pe.lockEnabled,Fe=pe.captureEnabled,L=Fe===void 0?!0:Fe,Te=pe.onBottomArrive,Qe=pe.onBottomLeave,tt=pe.onTopArrive,le=pe.onTopLeave,Pe=Q({isEnabled:L,onBottomArrive:Te,onBottomLeave:Qe,onTopArrive:tt,onTopLeave:le}),ze=re({isEnabled:qe}),at=function(Ct){Pe(Ct),ze(Ct)};return m.jsx(u.Fragment,null,qe&&m.jsx("div",{onClick:fe,css:de}),ve(at))}var oe={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},Ne=function(ve){var qe=ve.name,Fe=ve.onFocus;return m.jsx("input",{required:!0,name:qe,tabIndex:-1,"aria-hidden":"true",onFocus:Fe,css:oe,value:"",onChange:function(){}})},ke=Ne;function We(pe){var ve;return typeof window<"u"&&window.navigator!=null?pe.test(((ve=window.navigator.userAgentData)===null||ve===void 0?void 0:ve.platform)||window.navigator.platform):!1}function Me(){return We(/^iPhone/i)}function Le(){return We(/^Mac/i)}function De(){return We(/^iPad/i)||Le()&&navigator.maxTouchPoints>1}function He(){return Me()||De()}function Be(){return Le()||He()}var it=function(ve){return ve.label},pt=function(ve){return ve.label},dt=function(ve){return ve.value},Et=function(ve){return!!ve.isDisabled},At={clearIndicator:d.clearIndicatorCSS,container:d.containerCSS,control:d.css,dropdownIndicator:d.dropdownIndicatorCSS,group:d.groupCSS,groupHeading:d.groupHeadingCSS,indicatorsContainer:d.indicatorsContainerCSS,indicatorSeparator:d.indicatorSeparatorCSS,input:d.inputCSS,loadingIndicator:d.loadingIndicatorCSS,loadingMessage:d.loadingMessageCSS,menu:d.menuCSS,menuList:d.menuListCSS,menuPortal:d.menuPortalCSS,multiValue:d.multiValueCSS,multiValueLabel:d.multiValueLabelCSS,multiValueRemove:d.multiValueRemoveCSS,noOptionsMessage:d.noOptionsMessageCSS,option:d.optionCSS,placeholder:d.placeholderCSS,singleValue:d.css$1,valueContainer:d.valueContainerCSS};function Nt(pe){var ve=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},qe=t({},pe);return Object.keys(ve).forEach(function(Fe){var L=Fe;pe[L]?qe[L]=function(Te,Qe){return ve[L](pe[L](Te,Qe),Qe)}:qe[L]=ve[L]}),qe}var It={primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},zt=4,J=4,nt=38,ht=J*2,te={baseUnit:J,controlHeight:nt,menuGutter:ht},ne={borderRadius:zt,colors:It,spacing:te},xe={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:d.isTouchCapable(),captureMenuScroll:!d.isTouchCapable(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:q(),formatGroupLabel:it,getOptionLabel:pt,getOptionValue:dt,isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:Et,loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!d.isMobileDevice(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(ve){var qe=ve.count;return"".concat(qe," result").concat(qe!==1?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function Re(pe,ve,qe,Fe){var L=yt(pe,ve,qe),Te=kt(pe,ve,qe),Qe=Ht(pe,ve),tt=lt(pe,ve);return{type:"option",data:ve,isDisabled:L,isSelected:Te,label:Qe,value:tt,index:Fe}}function Ve(pe,ve){return pe.options.map(function(qe,Fe){if("options"in qe){var L=qe.options.map(function(Qe,tt){return Re(pe,Qe,ve,tt)}).filter(function(Qe){return st(pe,Qe)});return L.length>0?{type:"group",data:qe,options:L,index:Fe}:void 0}var Te=Re(pe,qe,ve,Fe);return st(pe,Te)?Te:void 0}).filter(d.notNullish)}function ot(pe){return pe.reduce(function(ve,qe){return qe.type==="group"?ve.push.apply(ve,l(qe.options.map(function(Fe){return Fe.data}))):ve.push(qe.data),ve},[])}function et(pe,ve){return pe.reduce(function(qe,Fe){return Fe.type==="group"?qe.push.apply(qe,l(Fe.options.map(function(L){return{data:L.data,id:"".concat(ve,"-").concat(Fe.index,"-").concat(L.index)}}))):qe.push({data:Fe.data,id:"".concat(ve,"-").concat(Fe.index)}),qe},[])}function mt(pe,ve){return ot(Ve(pe,ve))}function st(pe,ve){var qe=pe.inputValue,Fe=qe===void 0?"":qe,L=ve.data,Te=ve.isSelected,Qe=ve.label,tt=ve.value;return(!Ue(pe)||!Te)&&en(pe,{label:Qe,value:tt,data:L},Fe)}function vt(pe,ve){var qe=pe.focusedValue,Fe=pe.selectValue,L=Fe.indexOf(qe);if(L>-1){var Te=ve.indexOf(qe);if(Te>-1)return qe;if(L<ve.length)return ve[L]}return null}function Ft(pe,ve){var qe=pe.focusedOption;return qe&&ve.indexOf(qe)>-1?qe:ve[0]}var xt=function(ve,qe){var Fe,L=(Fe=ve.find(function(Te){return Te.data===qe}))===null||Fe===void 0?void 0:Fe.id;return L||null},Ht=function(ve,qe){return ve.getOptionLabel(qe)},lt=function(ve,qe){return ve.getOptionValue(qe)};function yt(pe,ve,qe){return typeof pe.isOptionDisabled=="function"?pe.isOptionDisabled(ve,qe):!1}function kt(pe,ve,qe){if(qe.indexOf(ve)>-1)return!0;if(typeof pe.isOptionSelected=="function")return pe.isOptionSelected(ve,qe);var Fe=lt(pe,ve);return qe.some(function(L){return lt(pe,L)===Fe})}function en(pe,ve,qe){return pe.filterOption?pe.filterOption(ve,qe):!0}var Ue=function(ve){var qe=ve.hideSelectedOptions,Fe=ve.isMulti;return qe===void 0?Fe:qe},ct=1,gt=function(pe){i(qe,pe);var ve=s(qe);function qe(Fe){var L;if(n(this,qe),L=ve.call(this,Fe),L.state={ariaSelection:null,focusedOption:null,focusedOptionId:null,focusableOptionsWithIds:[],focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0,instancePrefix:"",isAppleDevice:!1},L.blockOptionHover=!1,L.isComposing=!1,L.commonProps=void 0,L.initialTouchX=0,L.initialTouchY=0,L.openAfterFocus=!1,L.scrollToFocusedOptionOnUpdate=!1,L.userIsDragging=void 0,L.controlRef=null,L.getControlRef=function(le){L.controlRef=le},L.focusedOptionRef=null,L.getFocusedOptionRef=function(le){L.focusedOptionRef=le},L.menuListRef=null,L.getMenuListRef=function(le){L.menuListRef=le},L.inputRef=null,L.getInputRef=function(le){L.inputRef=le},L.focus=L.focusInput,L.blur=L.blurInput,L.onChange=function(le,Pe){var ze=L.props,at=ze.onChange,Ot=ze.name;Pe.name=Ot,L.ariaOnChange(le,Pe),at(le,Pe)},L.setValue=function(le,Pe,ze){var at=L.props,Ot=at.closeMenuOnSelect,Ct=at.isMulti,jt=at.inputValue;L.onInputChange("",{action:"set-value",prevInputValue:jt}),Ot&&(L.setState({inputIsHiddenAfterUpdate:!Ct}),L.onMenuClose()),L.setState({clearFocusValueOnUpdate:!0}),L.onChange(le,{action:Pe,option:ze})},L.selectOption=function(le){var Pe=L.props,ze=Pe.blurInputOnSelect,at=Pe.isMulti,Ot=Pe.name,Ct=L.state.selectValue,jt=at&&L.isOptionSelected(le,Ct),ft=L.isOptionDisabled(le,Ct);if(jt){var ut=L.getOptionValue(le);L.setValue(d.multiValueAsValue(Ct.filter(function(tn){return L.getOptionValue(tn)!==ut})),"deselect-option",le)}else if(!ft)at?L.setValue(d.multiValueAsValue([].concat(l(Ct),[le])),"select-option",le):L.setValue(d.singleValueAsValue(le),"select-option");else{L.ariaOnChange(d.singleValueAsValue(le),{action:"select-option",option:le,name:Ot});return}ze&&L.blurInput()},L.removeValue=function(le){var Pe=L.props.isMulti,ze=L.state.selectValue,at=L.getOptionValue(le),Ot=ze.filter(function(jt){return L.getOptionValue(jt)!==at}),Ct=d.valueTernary(Pe,Ot,Ot[0]||null);L.onChange(Ct,{action:"remove-value",removedValue:le}),L.focusInput()},L.clearValue=function(){var le=L.state.selectValue;L.onChange(d.valueTernary(L.props.isMulti,[],null),{action:"clear",removedValues:le})},L.popValue=function(){var le=L.props.isMulti,Pe=L.state.selectValue,ze=Pe[Pe.length-1],at=Pe.slice(0,Pe.length-1),Ot=d.valueTernary(le,at,at[0]||null);ze&&L.onChange(Ot,{action:"pop-value",removedValue:ze})},L.getFocusedOptionId=function(le){return xt(L.state.focusableOptionsWithIds,le)},L.getFocusableOptionsWithIds=function(){return et(Ve(L.props,L.state.selectValue),L.getElementId("option"))},L.getValue=function(){return L.state.selectValue},L.cx=function(){for(var le=arguments.length,Pe=new Array(le),ze=0;ze<le;ze++)Pe[ze]=arguments[ze];return d.classNames.apply(void 0,[L.props.classNamePrefix].concat(Pe))},L.getOptionLabel=function(le){return Ht(L.props,le)},L.getOptionValue=function(le){return lt(L.props,le)},L.getStyles=function(le,Pe){var ze=L.props.unstyled,at=At[le](Pe,ze);at.boxSizing="border-box";var Ot=L.props.styles[le];return Ot?Ot(at,Pe):at},L.getClassNames=function(le,Pe){var ze,at;return(ze=(at=L.props.classNames)[le])===null||ze===void 0?void 0:ze.call(at,Pe)},L.getElementId=function(le){return"".concat(L.state.instancePrefix,"-").concat(le)},L.getComponents=function(){return d.defaultComponents(L.props)},L.buildCategorizedOptions=function(){return Ve(L.props,L.state.selectValue)},L.getCategorizedOptions=function(){return L.props.menuIsOpen?L.buildCategorizedOptions():[]},L.buildFocusableOptions=function(){return ot(L.buildCategorizedOptions())},L.getFocusableOptions=function(){return L.props.menuIsOpen?L.buildFocusableOptions():[]},L.ariaOnChange=function(le,Pe){L.setState({ariaSelection:t({value:le},Pe)})},L.onMenuMouseDown=function(le){le.button===0&&(le.stopPropagation(),le.preventDefault(),L.focusInput())},L.onMenuMouseMove=function(le){L.blockOptionHover=!1},L.onControlMouseDown=function(le){if(!le.defaultPrevented){var Pe=L.props.openMenuOnClick;L.state.isFocused?L.props.menuIsOpen?le.target.tagName!=="INPUT"&&le.target.tagName!=="TEXTAREA"&&L.onMenuClose():Pe&&L.openMenu("first"):(Pe&&(L.openAfterFocus=!0),L.focusInput()),le.target.tagName!=="INPUT"&&le.target.tagName!=="TEXTAREA"&&le.preventDefault()}},L.onDropdownIndicatorMouseDown=function(le){if(!(le&&le.type==="mousedown"&&le.button!==0)&&!L.props.isDisabled){var Pe=L.props,ze=Pe.isMulti,at=Pe.menuIsOpen;L.focusInput(),at?(L.setState({inputIsHiddenAfterUpdate:!ze}),L.onMenuClose()):L.openMenu("first"),le.preventDefault()}},L.onClearIndicatorMouseDown=function(le){le&&le.type==="mousedown"&&le.button!==0||(L.clearValue(),le.preventDefault(),L.openAfterFocus=!1,le.type==="touchend"?L.focusInput():setTimeout(function(){return L.focusInput()}))},L.onScroll=function(le){typeof L.props.closeMenuOnScroll=="boolean"?le.target instanceof HTMLElement&&d.isDocumentElement(le.target)&&L.props.onMenuClose():typeof L.props.closeMenuOnScroll=="function"&&L.props.closeMenuOnScroll(le)&&L.props.onMenuClose()},L.onCompositionStart=function(){L.isComposing=!0},L.onCompositionEnd=function(){L.isComposing=!1},L.onTouchStart=function(le){var Pe=le.touches,ze=Pe&&Pe.item(0);ze&&(L.initialTouchX=ze.clientX,L.initialTouchY=ze.clientY,L.userIsDragging=!1)},L.onTouchMove=function(le){var Pe=le.touches,ze=Pe&&Pe.item(0);if(ze){var at=Math.abs(ze.clientX-L.initialTouchX),Ot=Math.abs(ze.clientY-L.initialTouchY),Ct=5;L.userIsDragging=at>Ct||Ot>Ct}},L.onTouchEnd=function(le){L.userIsDragging||(L.controlRef&&!L.controlRef.contains(le.target)&&L.menuListRef&&!L.menuListRef.contains(le.target)&&L.blurInput(),L.initialTouchX=0,L.initialTouchY=0)},L.onControlTouchEnd=function(le){L.userIsDragging||L.onControlMouseDown(le)},L.onClearIndicatorTouchEnd=function(le){L.userIsDragging||L.onClearIndicatorMouseDown(le)},L.onDropdownIndicatorTouchEnd=function(le){L.userIsDragging||L.onDropdownIndicatorMouseDown(le)},L.handleInputChange=function(le){var Pe=L.props.inputValue,ze=le.currentTarget.value;L.setState({inputIsHiddenAfterUpdate:!1}),L.onInputChange(ze,{action:"input-change",prevInputValue:Pe}),L.props.menuIsOpen||L.onMenuOpen()},L.onInputFocus=function(le){L.props.onFocus&&L.props.onFocus(le),L.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(L.openAfterFocus||L.props.openMenuOnFocus)&&L.openMenu("first"),L.openAfterFocus=!1},L.onInputBlur=function(le){var Pe=L.props.inputValue;if(L.menuListRef&&L.menuListRef.contains(document.activeElement)){L.inputRef.focus();return}L.props.onBlur&&L.props.onBlur(le),L.onInputChange("",{action:"input-blur",prevInputValue:Pe}),L.onMenuClose(),L.setState({focusedValue:null,isFocused:!1})},L.onOptionHover=function(le){if(!(L.blockOptionHover||L.state.focusedOption===le)){var Pe=L.getFocusableOptions(),ze=Pe.indexOf(le);L.setState({focusedOption:le,focusedOptionId:ze>-1?L.getFocusedOptionId(le):null})}},L.shouldHideSelectedOptions=function(){return Ue(L.props)},L.onValueInputFocus=function(le){le.preventDefault(),le.stopPropagation(),L.focus()},L.onKeyDown=function(le){var Pe=L.props,ze=Pe.isMulti,at=Pe.backspaceRemovesValue,Ot=Pe.escapeClearsValue,Ct=Pe.inputValue,jt=Pe.isClearable,ft=Pe.isDisabled,ut=Pe.menuIsOpen,tn=Pe.onKeyDown,mn=Pe.tabSelectsValue,wn=Pe.openMenuOnFocus,Sn=L.state,yn=Sn.focusedOption,Jn=Sn.focusedValue,$n=Sn.selectValue;if(!ft&&!(typeof tn=="function"&&(tn(le),le.defaultPrevented))){switch(L.blockOptionHover=!0,le.key){case"ArrowLeft":if(!ze||Ct)return;L.focusValue("previous");break;case"ArrowRight":if(!ze||Ct)return;L.focusValue("next");break;case"Delete":case"Backspace":if(Ct)return;if(Jn)L.removeValue(Jn);else{if(!at)return;ze?L.popValue():jt&&L.clearValue()}break;case"Tab":if(L.isComposing||le.shiftKey||!ut||!mn||!yn||wn&&L.isOptionSelected(yn,$n))return;L.selectOption(yn);break;case"Enter":if(le.keyCode===229)break;if(ut){if(!yn||L.isComposing)return;L.selectOption(yn);break}return;case"Escape":ut?(L.setState({inputIsHiddenAfterUpdate:!1}),L.onInputChange("",{action:"menu-close",prevInputValue:Ct}),L.onMenuClose()):jt&&Ot&&L.clearValue();break;case" ":if(Ct)return;if(!ut){L.openMenu("first");break}if(!yn)return;L.selectOption(yn);break;case"ArrowUp":ut?L.focusOption("up"):L.openMenu("last");break;case"ArrowDown":ut?L.focusOption("down"):L.openMenu("first");break;case"PageUp":if(!ut)return;L.focusOption("pageup");break;case"PageDown":if(!ut)return;L.focusOption("pagedown");break;case"Home":if(!ut)return;L.focusOption("first");break;case"End":if(!ut)return;L.focusOption("last");break;default:return}le.preventDefault()}},L.state.instancePrefix="react-select-"+(L.props.instanceId||++ct),L.state.selectValue=d.cleanValue(Fe.value),Fe.menuIsOpen&&L.state.selectValue.length){var Te=L.getFocusableOptionsWithIds(),Qe=L.buildFocusableOptions(),tt=Qe.indexOf(L.state.selectValue[0]);L.state.focusableOptionsWithIds=Te,L.state.focusedOption=Qe[tt],L.state.focusedOptionId=xt(Te,Qe[tt])}return L}return r(qe,[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&d.scrollIntoView(this.menuListRef,this.focusedOptionRef),Be()&&this.setState({isAppleDevice:!0})}},{key:"componentDidUpdate",value:function(L){var Te=this.props,Qe=Te.isDisabled,tt=Te.menuIsOpen,le=this.state.isFocused;(le&&!Qe&&L.isDisabled||le&&tt&&!L.menuIsOpen)&&this.focusInput(),le&&Qe&&!L.isDisabled?this.setState({isFocused:!1},this.onMenuClose):!le&&!Qe&&L.isDisabled&&this.inputRef===document.activeElement&&this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(d.scrollIntoView(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(L,Te){this.props.onInputChange(L,Te)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(L){var Te=this,Qe=this.state,tt=Qe.selectValue,le=Qe.isFocused,Pe=this.buildFocusableOptions(),ze=L==="first"?0:Pe.length-1;if(!this.props.isMulti){var at=Pe.indexOf(tt[0]);at>-1&&(ze=at)}this.scrollToFocusedOptionOnUpdate=!(le&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:Pe[ze],focusedOptionId:this.getFocusedOptionId(Pe[ze])},function(){return Te.onMenuOpen()})}},{key:"focusValue",value:function(L){var Te=this.state,Qe=Te.selectValue,tt=Te.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var le=Qe.indexOf(tt);tt||(le=-1);var Pe=Qe.length-1,ze=-1;if(Qe.length){switch(L){case"previous":le===0?ze=0:le===-1?ze=Pe:ze=le-1;break;case"next":le>-1&&le<Pe&&(ze=le+1);break}this.setState({inputIsHidden:ze!==-1,focusedValue:Qe[ze]})}}}},{key:"focusOption",value:function(){var L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"first",Te=this.props.pageSize,Qe=this.state.focusedOption,tt=this.getFocusableOptions();if(tt.length){var le=0,Pe=tt.indexOf(Qe);Qe||(Pe=-1),L==="up"?le=Pe>0?Pe-1:tt.length-1:L==="down"?le=(Pe+1)%tt.length:L==="pageup"?(le=Pe-Te,le<0&&(le=0)):L==="pagedown"?(le=Pe+Te,le>tt.length-1&&(le=tt.length-1)):L==="last"&&(le=tt.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:tt[le],focusedValue:null,focusedOptionId:this.getFocusedOptionId(tt[le])})}}},{key:"getTheme",value:function(){return this.props.theme?typeof this.props.theme=="function"?this.props.theme(ne):t(t({},ne),this.props.theme):ne}},{key:"getCommonProps",value:function(){var L=this.clearValue,Te=this.cx,Qe=this.getStyles,tt=this.getClassNames,le=this.getValue,Pe=this.selectOption,ze=this.setValue,at=this.props,Ot=at.isMulti,Ct=at.isRtl,jt=at.options,ft=this.hasValue();return{clearValue:L,cx:Te,getStyles:Qe,getClassNames:tt,getValue:le,hasValue:ft,isMulti:Ot,isRtl:Ct,options:jt,selectOption:Pe,selectProps:at,setValue:ze,theme:this.getTheme()}}},{key:"hasValue",value:function(){var L=this.state.selectValue;return L.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var L=this.props,Te=L.isClearable,Qe=L.isMulti;return Te===void 0?Qe:Te}},{key:"isOptionDisabled",value:function(L,Te){return yt(this.props,L,Te)}},{key:"isOptionSelected",value:function(L,Te){return kt(this.props,L,Te)}},{key:"filterOption",value:function(L,Te){return en(this.props,L,Te)}},{key:"formatOptionLabel",value:function(L,Te){if(typeof this.props.formatOptionLabel=="function"){var Qe=this.props.inputValue,tt=this.state.selectValue;return this.props.formatOptionLabel(L,{context:Te,inputValue:Qe,selectValue:tt})}else return this.getOptionLabel(L)}},{key:"formatGroupLabel",value:function(L){return this.props.formatGroupLabel(L)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var L=this.props,Te=L.isDisabled,Qe=L.isSearchable,tt=L.inputId,le=L.inputValue,Pe=L.tabIndex,ze=L.form,at=L.menuIsOpen,Ot=L.required,Ct=this.getComponents(),jt=Ct.Input,ft=this.state,ut=ft.inputIsHidden,tn=ft.ariaSelection,mn=this.commonProps,wn=tt||this.getElementId("input"),Sn=t(t(t({"aria-autocomplete":"list","aria-expanded":at,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":Ot,role:"combobox","aria-activedescendant":this.state.isAppleDevice?void 0:this.state.focusedOptionId||""},at&&{"aria-controls":this.getElementId("listbox")}),!Qe&&{"aria-readonly":!0}),this.hasValue()?tn?.action==="initial-input-focus"&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return Qe?A.createElement(jt,e({},mn,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:wn,innerRef:this.getInputRef,isDisabled:Te,isHidden:ut,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:Pe,form:ze,type:"text",value:le},Sn)):A.createElement(ae,e({id:wn,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:d.noop,onFocus:this.onInputFocus,disabled:Te,tabIndex:Pe,inputMode:"none",form:ze,value:""},Sn))}},{key:"renderPlaceholderOrValue",value:function(){var L=this,Te=this.getComponents(),Qe=Te.MultiValue,tt=Te.MultiValueContainer,le=Te.MultiValueLabel,Pe=Te.MultiValueRemove,ze=Te.SingleValue,at=Te.Placeholder,Ot=this.commonProps,Ct=this.props,jt=Ct.controlShouldRenderValue,ft=Ct.isDisabled,ut=Ct.isMulti,tn=Ct.inputValue,mn=Ct.placeholder,wn=this.state,Sn=wn.selectValue,yn=wn.focusedValue,Jn=wn.isFocused;if(!this.hasValue()||!jt)return tn?null:A.createElement(at,e({},Ot,{key:"placeholder",isDisabled:ft,isFocused:Jn,innerProps:{id:this.getElementId("placeholder")}}),mn);if(ut)return Sn.map(function(an,ar){var Rr=an===yn,ei="".concat(L.getOptionLabel(an),"-").concat(L.getOptionValue(an));return A.createElement(Qe,e({},Ot,{components:{Container:tt,Label:le,Remove:Pe},isFocused:Rr,isDisabled:ft,key:ei,index:ar,removeProps:{onClick:function(){return L.removeValue(an)},onTouchEnd:function(){return L.removeValue(an)},onMouseDown:function(er){er.preventDefault()}},data:an}),L.formatOptionLabel(an,"value"))});if(tn)return null;var $n=Sn[0];return A.createElement(ze,e({},Ot,{data:$n,isDisabled:ft}),this.formatOptionLabel($n,"value"))}},{key:"renderClearIndicator",value:function(){var L=this.getComponents(),Te=L.ClearIndicator,Qe=this.commonProps,tt=this.props,le=tt.isDisabled,Pe=tt.isLoading,ze=this.state.isFocused;if(!this.isClearable()||!Te||le||!this.hasValue()||Pe)return null;var at={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return A.createElement(Te,e({},Qe,{innerProps:at,isFocused:ze}))}},{key:"renderLoadingIndicator",value:function(){var L=this.getComponents(),Te=L.LoadingIndicator,Qe=this.commonProps,tt=this.props,le=tt.isDisabled,Pe=tt.isLoading,ze=this.state.isFocused;if(!Te||!Pe)return null;var at={"aria-hidden":"true"};return A.createElement(Te,e({},Qe,{innerProps:at,isDisabled:le,isFocused:ze}))}},{key:"renderIndicatorSeparator",value:function(){var L=this.getComponents(),Te=L.DropdownIndicator,Qe=L.IndicatorSeparator;if(!Te||!Qe)return null;var tt=this.commonProps,le=this.props.isDisabled,Pe=this.state.isFocused;return A.createElement(Qe,e({},tt,{isDisabled:le,isFocused:Pe}))}},{key:"renderDropdownIndicator",value:function(){var L=this.getComponents(),Te=L.DropdownIndicator;if(!Te)return null;var Qe=this.commonProps,tt=this.props.isDisabled,le=this.state.isFocused,Pe={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return A.createElement(Te,e({},Qe,{innerProps:Pe,isDisabled:tt,isFocused:le}))}},{key:"renderMenu",value:function(){var L=this,Te=this.getComponents(),Qe=Te.Group,tt=Te.GroupHeading,le=Te.Menu,Pe=Te.MenuList,ze=Te.MenuPortal,at=Te.LoadingMessage,Ot=Te.NoOptionsMessage,Ct=Te.Option,jt=this.commonProps,ft=this.state.focusedOption,ut=this.props,tn=ut.captureMenuScroll,mn=ut.inputValue,wn=ut.isLoading,Sn=ut.loadingMessage,yn=ut.minMenuHeight,Jn=ut.maxMenuHeight,$n=ut.menuIsOpen,an=ut.menuPlacement,ar=ut.menuPosition,Rr=ut.menuPortalTarget,ei=ut.menuShouldBlockScroll,Qr=ut.menuShouldScrollIntoView,er=ut.noOptionsMessage,_i=ut.onMenuScrollToTop,br=ut.onMenuScrollToBottom;if(!$n)return null;var Ce=function(St,_t){var An=St.type,On=St.data,Mn=St.isDisabled,tr=St.isSelected,Hr=St.label,ti=St.value,Vr=ft===On,vi=Mn?void 0:function(){return L.onOptionHover(On)},En=Mn?void 0:function(){return L.selectOption(On)},Yr="".concat(L.getElementId("option"),"-").concat(_t),yr={id:Yr,onClick:En,onMouseMove:vi,onMouseOver:vi,tabIndex:-1,role:"option","aria-selected":L.state.isAppleDevice?void 0:tr};return A.createElement(Ct,e({},jt,{innerProps:yr,data:On,isDisabled:Mn,isSelected:tr,key:Yr,label:Hr,type:An,value:ti,isFocused:Vr,innerRef:Vr?L.getFocusedOptionRef:void 0}),L.formatOptionLabel(St.data,"menu"))},W;if(this.hasOptions())W=this.getCategorizedOptions().map(function(Ze){if(Ze.type==="group"){var St=Ze.data,_t=Ze.options,An=Ze.index,On="".concat(L.getElementId("group"),"-").concat(An),Mn="".concat(On,"-heading");return A.createElement(Qe,e({},jt,{key:On,data:St,options:_t,Heading:tt,headingProps:{id:Mn,data:Ze.data},label:L.formatGroupLabel(Ze.data)}),Ze.options.map(function(tr){return Ce(tr,"".concat(An,"-").concat(tr.index))}))}else if(Ze.type==="option")return Ce(Ze,"".concat(Ze.index))});else if(wn){var Oe=Sn({inputValue:mn});if(Oe===null)return null;W=A.createElement(at,jt,Oe)}else{var Ee=er({inputValue:mn});if(Ee===null)return null;W=A.createElement(Ot,jt,Ee)}var _e={minMenuHeight:yn,maxMenuHeight:Jn,menuPlacement:an,menuPosition:ar,menuShouldScrollIntoView:Qr},rt=A.createElement(d.MenuPlacer,e({},jt,_e),function(Ze){var St=Ze.ref,_t=Ze.placerProps,An=_t.placement,On=_t.maxHeight;return A.createElement(le,e({},jt,_e,{innerRef:St,innerProps:{onMouseDown:L.onMenuMouseDown,onMouseMove:L.onMenuMouseMove},isLoading:wn,placement:An}),A.createElement(ce,{captureEnabled:tn,onTopArrive:_i,onBottomArrive:br,lockEnabled:ei},function(Mn){return A.createElement(Pe,e({},jt,{innerRef:function(Hr){L.getMenuListRef(Hr),Mn(Hr)},innerProps:{role:"listbox","aria-multiselectable":jt.isMulti,id:L.getElementId("listbox")},isLoading:wn,maxHeight:On,focusedOption:ft}),W)}))});return Rr||ar==="fixed"?A.createElement(ze,e({},jt,{appendTo:Rr,controlElement:this.controlRef,menuPlacement:an,menuPosition:ar}),rt):rt}},{key:"renderFormField",value:function(){var L=this,Te=this.props,Qe=Te.delimiter,tt=Te.isDisabled,le=Te.isMulti,Pe=Te.name,ze=Te.required,at=this.state.selectValue;if(ze&&!this.hasValue()&&!tt)return A.createElement(ke,{name:Pe,onFocus:this.onValueInputFocus});if(!(!Pe||tt))if(le)if(Qe){var Ot=at.map(function(ft){return L.getOptionValue(ft)}).join(Qe);return A.createElement("input",{name:Pe,type:"hidden",value:Ot})}else{var Ct=at.length>0?at.map(function(ft,ut){return A.createElement("input",{key:"i-".concat(ut),name:Pe,type:"hidden",value:L.getOptionValue(ft)})}):A.createElement("input",{name:Pe,type:"hidden",value:""});return A.createElement("div",null,Ct)}else{var jt=at[0]?this.getOptionValue(at[0]):"";return A.createElement("input",{name:Pe,type:"hidden",value:jt})}}},{key:"renderLiveRegion",value:function(){var L=this.commonProps,Te=this.state,Qe=Te.ariaSelection,tt=Te.focusedOption,le=Te.focusedValue,Pe=Te.isFocused,ze=Te.selectValue,at=this.getFocusableOptions();return A.createElement(E,e({},L,{id:this.getElementId("live-region"),ariaSelection:Qe,focusedOption:tt,focusedValue:le,isFocused:Pe,selectValue:ze,focusableOptions:at,isAppleDevice:this.state.isAppleDevice}))}},{key:"render",value:function(){var L=this.getComponents(),Te=L.Control,Qe=L.IndicatorsContainer,tt=L.SelectContainer,le=L.ValueContainer,Pe=this.props,ze=Pe.className,at=Pe.id,Ot=Pe.isDisabled,Ct=Pe.menuIsOpen,jt=this.state.isFocused,ft=this.commonProps=this.getCommonProps();return A.createElement(tt,e({},ft,{className:ze,innerProps:{id:at,onKeyDown:this.onKeyDown},isDisabled:Ot,isFocused:jt}),this.renderLiveRegion(),A.createElement(Te,e({},ft,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:Ot,isFocused:jt,menuIsOpen:Ct}),A.createElement(le,e({},ft,{isDisabled:Ot}),this.renderPlaceholderOrValue(),this.renderInput()),A.createElement(Qe,e({},ft,{isDisabled:Ot}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}],[{key:"getDerivedStateFromProps",value:function(L,Te){var Qe=Te.prevProps,tt=Te.clearFocusValueOnUpdate,le=Te.inputIsHiddenAfterUpdate,Pe=Te.ariaSelection,ze=Te.isFocused,at=Te.prevWasFocused,Ot=Te.instancePrefix,Ct=L.options,jt=L.value,ft=L.menuIsOpen,ut=L.inputValue,tn=L.isMulti,mn=d.cleanValue(jt),wn={};if(Qe&&(jt!==Qe.value||Ct!==Qe.options||ft!==Qe.menuIsOpen||ut!==Qe.inputValue)){var Sn=ft?mt(L,mn):[],yn=ft?et(Ve(L,mn),"".concat(Ot,"-option")):[],Jn=tt?vt(Te,mn):null,$n=Ft(Te,Sn),an=xt(yn,$n);wn={selectValue:mn,focusedOption:$n,focusedOptionId:an,focusableOptionsWithIds:yn,focusedValue:Jn,clearFocusValueOnUpdate:!1}}var ar=le!=null&&L!==Qe?{inputIsHidden:le,inputIsHiddenAfterUpdate:void 0}:{},Rr=Pe,ei=ze&&at;return ze&&!ei&&(Rr={value:d.valueTernary(tn,mn,mn[0]||null),options:mn,action:"initial-input-focus"},ei=!at),Pe?.action==="initial-input-focus"&&(Rr=null),t(t(t({},wn),ar),{},{prevProps:L,ariaSelection:Rr,prevWasFocused:ei})}}]),qe}(u.Component);return gt.defaultProps=xe,Ls.Select=gt,Ls.createFilter=q,Ls.defaultProps=xe,Ls.defaultTheme=ne,Ls.getOptionLabel=pt,Ls.getOptionValue=dt,Ls.mergeStyles=Nt,Ls}var jL;function Bme(){return jL||(jL=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=vme(),n=Rm(),r=hn(),i=Nme(),s=I0(),l=Cm(),u=gz();rb(),xI(),ib(),uz(),cz(),dz(),fz(),hz(),km(),mz(),AI(),h0(),pz();function d(w){return w&&w.__esModule?w:{default:w}}function m(w){if(w&&w.__esModule)return w;var S=Object.create(null);return w&&Object.keys(w).forEach(function(C){if(C!=="default"){var M=Object.getOwnPropertyDescriptor(w,C);Object.defineProperty(S,C,M.get?M:{enumerable:!0,get:function(){return w[C]}})}}),S.default=w,Object.freeze(S)}var v=m(r),g=d(l),y=r.forwardRef(function(w,S){var C=t.useStateManager(w);return v.createElement(i.Select,n({ref:S},C))}),b=y,A=function(w){var S=w.nonce,C=w.children,M=w.cacheKey,P=r.useMemo(function(){return g.default({key:M,nonce:S})},[M,S]);return v.createElement(s.CacheProvider,{value:P},C)};e.useStateManager=t.useStateManager,e.createFilter=i.createFilter,e.defaultTheme=i.defaultTheme,e.mergeStyles=i.mergeStyles,e.components=u.components,e.NonceProvider=A,e.default=b}(dC)),dC}var NL;function Lme(){return NL||(NL=1,cC.exports=Bme()),cC.exports}var zC={},BL;function Fme(){return BL||(BL=1,zC._default=Lme().default),zC}var LL=Fme();const vz=D0(e=>({data:[],addObject:t=>e(n=>({data:[...n.data,t]})),updateObject:(t,n)=>e(r=>({data:r.data.map((i,s)=>s===t?{...i,...n}:i)})),removeObject:t=>e(n=>({data:n.data.filter((r,i)=>i!==t)})),toggleRelationship:t=>e(n=>({data:n.data.map((r,i)=>i===t?{...r,addRelationship:!r.addRelationship}:r)})),addNestedEmail:(t,n)=>e(r=>({data:r.data.map((i,s)=>s===t?{...i,emails:[...i.emails||[],n]}:i)})),updateNestedEmail:(t,n,r)=>e(i=>({data:i.data.map((s,l)=>l===t?{...s,emails:s.emails?.map((u,d)=>d===n?{...u,...r}:u)}:s)})),removeNestedEmail:(t,n)=>e(r=>({data:r.data.map((i,s)=>s===t?{...i,emails:i.emails?.filter((l,u)=>u!==n)}:i)}))})),kme=({emails:e})=>{const{data:t,addObject:n,removeObject:r,toggleRelationship:i,addNestedEmail:s,removeNestedEmail:l}=vz(),[u,d]=j.useState(!1),[m,v]=j.useState(!1),[g,y]=j.useState(!1),[b,A]=j.useState(""),w=b&&(m||g),S=P=>new RegExp("^(?![_.-])[A-Za-z0-9._%+-]+(?<![_.-])@(?:(?!-)[A-Za-z0-9-]{1,63}(?<!-)\\.)+[A-Za-z]{2,}$").test(P)?!0:(Xe.error("Please enter a valid email address"),!1),C=()=>{const P=b;if(!P){Xe.error("Please chooose sender or receipt");return}if(!S(P))return;if(!m&&!g)return Xe.error("Please chooose sender or receipt"),!1;if(t.find(D=>D.email==P&&D.type==(m?"from":"to")))return Xe.error("Email already exists");let E="to";m&&g?E="all":m&&(E="from"),n({email:P,type:E}),A(""),v(!1),y(!1),d(!1)},M=(P,_)=>{const E=b;if(!E){Xe.error("Please chooose sender or receipt");return}S(E)&&(s(P,{email:E,type:_.type=="from"?"to":"from"}),i(P),A(""))};return h.jsxs(h.Fragment,{children:[t.length>0?t.map((P,_)=>h.jsxs("div",{className:"mb-1 py-3 border-t border-light-gray",children:[h.jsxs("div",{className:"flex justify-between",children:[h.jsxs("div",{className:"text-[#475467]",children:[h.jsx("strong",{className:"capitalize",children:P.type}),":"," ",P.email]}),h.jsx("a",{className:"text-[#C13B2D] cursor-pointer",onClick:E=>{E.stopPropagation(),r(_)},children:"Remove"})]}),P.emails&&P.emails.length>0?P.emails.map((E,D)=>h.jsx("div",{children:h.jsxs("div",{className:"flex justify-between ps-10 mt-3",children:[h.jsxs("div",{className:"text-[#475467]",children:[h.jsx(we,{icon:X3,style:{transform:"scaleX(-1)"}}),h.jsx("strong",{className:"capitalize",children:E.type}),":"," ",E.email]}),h.jsx("a",{className:"text-[#C13B2D] cursor-pointer",onClick:O=>{O.stopPropagation(),l(_,D)},children:"Remove"})]})})):null,P.addRelationship?h.jsxs("div",{className:"flex mt-2 ps-10",children:[h.jsx(LL._default,{isSearchable:!0,isClearable:!0,options:e?.map(E=>({label:E,value:E}))||[],onChange:E=>A(E?.label),value:{label:b,value:b},closeMenuOnSelect:!0,styles:{container:E=>({...E,flexGrow:1,heigt:40}),control:E=>({...E,minHeight:"40px",cursor:"pointer",borderTopRightRadius:0,borderBottomRightRadius:0})},components:{DropdownIndicator:null}}),h.jsx("button",{className:"btn-lightblue uppercase cursor-pointer bg-my-archive rounded-r",onClick:()=>M(_,P),children:"Add"})]}):null,P.type!=="all"&&h.jsx("div",{className:"text-end",children:h.jsxs("a",{className:"text-my-archive mt-1 block cursor-pointer",onClick:()=>i(_),children:[h.jsx(we,{icon:X3,style:{transform:"scaleX(-1)"}}),"Add relationship"]})})]},_)):null,u?h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex",children:[h.jsx(LL._default,{isSearchable:!0,isClearable:!0,options:e?.map(P=>({label:P,value:P}))||[],onChange:P=>A(P?.label),value:{label:b,value:b},closeMenuOnSelect:!0,styles:{container:P=>({...P,flexGrow:1,heigt:40}),control:P=>({...P,minHeight:"40px",cursor:"pointer",borderTopRightRadius:0,borderBottomRightRadius:0})},components:{DropdownIndicator:null}}),h.jsx("button",{className:"btn-lightblue uppercase cursor-pointer bg-my-archive rounded-r disabled:bg-gray-400 disabled:cursor-not-allowed",disabled:!w,onClick:C,children:"Add"})]}),h.jsxs("div",{className:"flex gap-4 mt-2",children:[h.jsx("div",{children:h.jsxs("label",{className:"flex gap-2",htmlFor:"email_sender",children:[h.jsx("input",{type:"checkbox",id:"email_sender",checked:m,onChange:P=>v(P.target.checked)}),"Sender"]})}),h.jsx("div",{children:h.jsxs("label",{className:"flex gap-2",htmlFor:"email_recipient",children:[h.jsx("input",{checked:g,type:"checkbox",id:"email_recipient",onChange:P=>y(P.target.checked)}),"Recipient"]})})]})]}):h.jsxs("div",{className:"flex items-center cursor-pointer",onClick:()=>d(!0),children:[h.jsx(we,{icon:Kn,className:"me-1"}),"Add sender or receipient"]})]})},Js=D0((e,t,n)=>({days:{startDate:new Date,endDate:new Date,key:"selection"},activeChoice:"last_30_days",emailAddresses:[],emailAttachments:!1,emailContents:"",emailKeywords:[],emailSubject:"",emailReviewStatus:{},relationalEmailAddresses:[],contents:"",keywords:[],platforms:[],publishers:[],reviewStatus:{},updateField:(r,i)=>e({[r]:i}),setActiveChoice:r=>e({activeChoice:r}),setDays:r=>e({days:r}),resetState:()=>e(n.getInitialState())})),qme=({settings:e})=>{const[t,n]=j.useState(!1),[r,i]=j.useState(!1),[s,l]=j.useState(!1),[u,d]=j.useState(!1),[m,v]=j.useState(!1),{updateField:g,emailContents:y,emailKeywords:b,emailSubject:A,emailReviewStatus:w}=Js(S=>S);return h.jsxs("div",{className:"email-filters-wrapper",children:[h.jsxs("div",{className:"mt-10",children:[h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Email Addresses"}),h.jsx(kme,{emails:e?.searchEmails})]}),h.jsx("div",{className:"mt-10",children:m&&h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{v(!m),g("emailSubject","")},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Email Subject"})]}),h.jsx("textarea",{onChange:S=>g("emailSubject",S.currentTarget.value),value:A,className:"text-sm outline-none py-3 px-5 border rounded border-[#DEE2E6] w-full h-[100px]",placeholder:"Enter text..."})]})}),h.jsx("div",{className:"mt-10",children:t&&h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{n(!n),g("emailContents","")},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Email Contents"})]}),h.jsx("textarea",{value:y,onChange:S=>g("emailContents",S.currentTarget.value),className:"text-sm outline-none py-3 px-5 border rounded border-[#DEE2E6] w-full h-[100px]",placeholder:"Enter text..."})]})}),r&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{i(!r),g("emailReviewStatus",{})},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Review Status"})]}),h.jsxs("label",{className:"flex items-center my-2",htmlFor:"reviewed_check",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"reviewed_check",checked:w.is_reviewed==="true",onChange:S=>{g("emailReviewStatus",{...w,is_reviewed:S.currentTarget.checked.toString()})}}),"Reviewed"]}),h.jsxs("label",{className:"flex items-center my-2",htmlFor:"reviewed_flagged",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"reviewed_flagged",checked:w.is_further_review==="true",onChange:S=>{g("emailReviewStatus",{...w,is_further_review:S.currentTarget.checked.toString()})}}),"Flagged For Further Review"]})]})}),s&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>l(!s),color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Keywords"})]}),h.jsx(AR,{allLabel:"All Keywords",placeholder:"Select Keywords",selectionLabel:"Keyword",selectedOptions:b.map(S=>({value:S,label:S})),setSelectedOptions:S=>g("emailKeywords",S.map(C=>C.label)),options:e?.keywords?.map(S=>({value:S,label:S}))||[]})]})}),u&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{d(!u),g("emailContents","")},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Attachments"})]}),h.jsxs("label",{className:"flex items-center",htmlFor:"email_attachments_check",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"email_attachments_check",onChange:S=>{g("emailAttachments",S.currentTarget.checked)}}),"Email includes attachment(s)"]})]})}),h.jsxs("div",{className:"mt-10 mb-20",children:[h.jsx("p",{className:"text-[#B5B3B3] border-b border-[#B5B3B3]",children:"Refine Your Search"}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>v(!m),children:[h.jsx("span",{children:m?"-":"+"})," Email Subject"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>n(!t),children:[h.jsx("span",{children:t?"-":"+"})," Email Contents"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>i(!r),children:[h.jsx("span",{children:r?"-":"+"})," Review Status"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>l(!s),children:[h.jsx("span",{children:s?"-":"+"})," Keywords"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>d(!u),children:[h.jsx("span",{children:u?"-":"+"})," Attachments"]})]})]})},zme=({settings:e})=>{const{updateField:t,contents:n,keywords:r,platforms:i,reviewStatus:s}=Js(),[l,u]=j.useState(!1),[d,m]=j.useState(!1),[v,g]=j.useState(!1),[y,b]=j.useState(!1),[A,w]=j.useState(!1),[S,C]=j.useState([]),M=j.useMemo(()=>{const P=e?.publishers?.map((_,E)=>({value:_.toString(),label:e.publishedBy?.at(E)||""}))||[];return[{label:"Firm Account",value:"0"},...P]},[e?.publishers,e?.publishedBy]);return h.jsxs("div",{className:"email-filters-wrapper",children:[h.jsx("div",{className:"mt-10",children:v&&h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{C([]),g(!v)},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Published By"})]}),h.jsx("p",{className:"my-3",children:"Include entries published by these users"}),h.jsx(AR,{allLabel:"All Users",placeholder:"Select Users",selectionLabel:"User",selectedOptions:S,setSelectedOptions:P=>{C(P),t("publishers",P.map(_=>parseInt(_.value)))},options:M})]})}),h.jsx("div",{className:"mt-10",children:A&&h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{t("contents",""),w(!A)},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Post Contents"})]}),h.jsx("textarea",{value:n,className:"text-sm outline-none py-3 px-5 border rounded border-[#DEE2E6] w-full h-[100px]",placeholder:"Enter text...",onChange:P=>t("contents",P.currentTarget.value)})]})}),y&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{t("platforms",[]),b(!y)},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Platform"})]}),e?.platforms?.map((P,_)=>h.jsxs("label",{className:"flex items-center my-2",children:[h.jsx("input",{type:"checkbox",className:"me-2",checked:i.includes(P),onChange:E=>{const D=E.currentTarget.checked?[...i,P]:i.filter(O=>O!==P);t("platforms",D)}}),e.accountTypes?.at(_)]},P))]})}),d&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{t("keywords",[]),m(!d)},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Keywords"})]}),h.jsx(AR,{allLabel:"All Keywords",placeholder:"Select Keywords",selectionLabel:"Keyword",selectedOptions:r.map(P=>({label:P,value:P})),setSelectedOptions:P=>{t("keywords",P.map(_=>_.value))},options:e?.keywords?.map(P=>({label:P,value:P}))||[]})]})}),l&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>u(!l),color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Review Status"})]}),h.jsxs("label",{className:"flex items-center my-2",htmlFor:"reviewed_check",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"reviewed_check",checked:s.is_reviewed==="true",onChange:P=>{t("reviewStatus",{...s,is_reviewed:P.currentTarget.checked.toString()})}}),"Reviewed"]}),h.jsxs("label",{className:"flex items-center my-2",htmlFor:"reviewed_flagged",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"reviewed_flagged",checked:s.is_further_review==="true",onChange:P=>{t("reviewStatus",{...s,is_further_review:P.currentTarget.checked.toString()})}}),"Flagged For Further Review"]})]})}),h.jsxs("div",{className:"mt-10 mb-20",children:[h.jsx("p",{className:"text-[#B5B3B3] border-b border-[#B5B3B3]",children:"Refine Your Search"}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{C([]),g(!v)},children:[h.jsx("span",{children:v?"-":"+"})," Published By"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{t("contents",""),w(!A)},children:[h.jsx("span",{children:A?"-":"+"})," Post Contents"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{t("platforms",[]),b(!y)},children:[h.jsx("span",{children:y?"-":"+"})," Platform"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{t("keywords",[]),m(!d)},children:[h.jsx("span",{children:d?"-":"+"})," Keywords"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{t("reviewStatus",{}),u(!l)},children:[h.jsx("span",{children:l?"-":"+"})," Review Status"]})]})]})},ki=D0(e=>({emails:[],posts:[],emailMap:{},postMap:{},searchId:"",totalResults:0,setEmails:(t,n,r)=>e(i=>{const s=t.reduce((l,u)=>(l[u.id]=u,l),i.emailMap);return{emails:t,emailMap:s,totalResults:n,posts:[],postMap:{},searchId:r}}),setPosts:(t,n,r)=>e(i=>{const s=t.reduce((l,u)=>(l[u.id]=u,l),i.postMap);return{posts:t,postMap:s,totalResults:n,emails:[],emailMap:{},searchId:r}})})),bz=(e=0,t=12)=>({queryKey:["myArchiveFolders",e,t],queryFn:()=>{const n=new URLSearchParams;return n.set("PageNumber",String(e)),n.set("PageSize",String(t)),bt.executeRequest(`/AdvancedSearch?${n.toString()}`,"GET")}}),yz=()=>{const e=Js(u=>u),t=vz(u=>u.data),n=j.useMemo(()=>t.reduce((u,d)=>{const m=[{item:d.email,itemType:d.type}];return d.emails&&d.emails.forEach(v=>m.push({item:v.email,itemType:v.type})),u.push(m),u},[]),[t]),{startDate:r,endDate:i}=wI(e.activeChoice,e.days),s=kr(),l=ki(u=>u.setEmails);return Tt({mutationFn:({pageNumber:u=0})=>bt.executeRequest("/Archiving/advanced_email_search","POST",{emailDateStart:r,emailDateEnd:i,relationalEmailAddresses:n,emailAttachments:!1,emailKeywords:e.emailKeywords,emailContents:e.emailContents,emailReviewStatus:e.emailReviewStatus,emailSubject:e.emailSubject,pageNumber:u}),onSuccess:u=>{u.success?(l(u.searchResults||[],u.totalResults,u.searchId),s({to:"/my-archive/results"})):Xe.error(u.errorMessage||"Error while searching")}})},Az=()=>{const e=Js(),t=ki(s=>s.setPosts),n=kr(),{startDate:r,endDate:i}=wI(e.activeChoice,e.days);return Tt({mutationFn:({pageNumber:s=0})=>bt.executeRequest("/socialmedia/search","POST",{start:r,end:i,publishers:e.publishers,keywords:e.keywords,contents:e.contents,platforms:e.platforms,reviewStatus:e.reviewStatus,pageNumber:s}),onSuccess:s=>{s.success?(t(s.searchResults||[],s.totalResults,s.searchId),n({to:"/my-archive/results"})):Xe.error(s.errorMessage||"Error while searching")}})},Qme=()=>Gt({queryKey:["myArchiveSettings"],queryFn:()=>bt.executeRequest("/Archiving/advanced_search","GET")}),Hme=()=>{const e=ki(n=>n.postMap),t=ki(n=>n.emailMap);return Tt({mutationFn:({folderId:n,fileIds:r})=>{const i=r.map(l=>{if(e[l])return e[l];if(t[l])return t[l]}).filter(Boolean);let s="email";return Object.keys(e).length>0&&(s="social_media"),bt.executeRequest("/AdvancedSearch/add_items_to_folder","POST",{folderId:n,selectedItems:i.map(l=>({esId:l?.id,s3Path:l?.s3Path,archivingType:s,socialMediaType:s==="email"?"NULL":l.data.social_media_type}))})}})},Vme=()=>{const e=ki(u=>u.emailMap),t=ki(u=>u.postMap),n=Js(),r=ki(u=>u.searchId),i=ki(u=>u.totalResults),{startDate:s,endDate:l}=wI(n.activeChoice,n.days);return Tt({mutationFn:({folderId:u})=>i>1e3?bt.executeRequest("/AdvancedSearch/select_all_request","POST",{folderId:u,searchId:r}):Object.keys(t).length>0?bt.executeRequest("/socialmedia/selectall","POST",{folderId:u,start:s,end:l,publishers:n.publishers,keywords:n.keywords,contents:n.contents,platforms:n.platforms,reviewStatus:n.reviewStatus,unselectedItems:[]}):Object.keys(e).length>0?bt.executeRequest("/AdvancedSearch/select_all_email_items","POST",{folderId:u,emailDateStart:s,emailDateEnd:l,emailAddresses:n.emailAddresses,relationalEmailAddresses:n.relationalEmailAddresses,emailAttachments:n.emailAttachments,emailKeywords:n.emailKeywords,emailReviewStatus:n.emailReviewStatus,emailSubject:n.emailSubject}):Promise.reject("No archive type supplied")})};function wI(e,t){const n=new Date,r=new Date;switch(e){case"last_30_days":r.setDate(n.getDate()-30);break;case"last_3_months":r.setMonth(n.getMonth()-3);break;case"last_6_months":r.setMonth(n.getMonth()-6);break;default:return{startDate:s0(t.startDate||r).toISOString(),endDate:n_(t.endDate||n).toISOString()}}return{startDate:s0(r).toISOString(),endDate:n_(n).toISOString()}}const Yme=[{id:"last_30_days",title:"Last 30 Days"},{id:"last_3_months",title:"Last 3 Months"},{id:"last_6_months",title:"Last 6 Months"},{id:"custom",title:"Custom"}],Wme=({isOpen:e,setIsOpen:t})=>{const{data:n}=Qme(),r=ki(w=>w.emails),i=ki(w=>w.posts),s=Js(w=>w.activeChoice),l=Js(w=>w.setActiveChoice),u=Js(w=>w.days),d=Js(w=>w.setDays),{mutate:m}=yz(),{mutate:v}=Az(),[g,y]=j.useState("email"),[b,A]=j.useState(!1);return h.jsx("div",{className:`absolute z-10 bg-white shadow-myarchive border-t-24 border-blue-800 h-full ${e?"w-157":"w-12"} transition-all duration-50 rounded-tr-md -mt-[24px]`,children:h.jsxs("div",{className:"flex flex-row h-full",children:[h.jsxs("div",{className:"flex flex-col gap-y-8 bg-blue-800 shrink-0 w-12",children:[h.jsx("button",{onClick:()=>t(!e),className:"py-1 text-white w-full text-center cursor-pointer",children:h.jsx(we,{icon:e?wee:sk,size:"large"})}),r.length>0||i.length>0?h.jsx(qn,{to:"/my-archive/results",className:"py-1 text-white w-full text-center cursor-pointer",children:h.jsx(we,{icon:Z3,size:"large"})}):h.jsx("button",{onClick:()=>t(!e),className:"py-1 text-white w-full text-center cursor-pointer",children:h.jsx(we,{icon:Z3,size:"large"})}),h.jsx(qn,{to:"/my-archive/folders",className:"py-1 text-white w-full text-center cursor-pointer",search:{page:void 0},onClick:()=>{t(!1)},children:h.jsx(we,{icon:dk,size:"large"})})]}),e&&h.jsxs("div",{className:"max-h-300 overflow-scroll p-4",children:[h.jsxs("div",{className:"flex justify-between mb-3 px-4",children:[h.jsxs("div",{className:"flex",children:[h.jsx("span",{onClick:()=>y("email"),className:`p-3 ${g=="email"?"bg-my-archive text-white":"bg-light-gray text-my-archive"} me-2 cursor-pointer`,children:h.jsx(we,{icon:pO,size:"large"})}),h.jsx("span",{onClick:()=>y("social_media"),className:`p-3 ${g=="social_media"?"bg-my-archive text-white":"bg-light-gray text-my-archive"} me-2 cursor-pointer`,children:h.jsx(we,{icon:Cee,size:"large"})})]}),h.jsx("button",{onClick:()=>{g==="email"&&m({},{onSuccess:w=>w.success&&t(!1)}),g==="social_media"&&v({},{onSuccess:w=>w.success&&t(!1)})},className:"btn-lightblue cursor-pointer bg-my-archive rounded",children:"Run Search"})]}),h.jsxs("div",{className:"mt-5 mb-5",children:[h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Date Range"}),h.jsx(ll,{activeChoiceId:s,onChange:w=>{w.id=="custom"&&A(!0),l(w.id)},choices:Yme,mode:"gray"}),b&&h.jsxs(bn,{title:"",width:700,onClose:()=>A(!1),appendTo:null,children:[h.jsx(dme.DateRange,{onChange:w=>d(w.selection),moveRangeOnFirstSelection:!1,months:2,ranges:[u],direction:"horizontal",rangeColors:["#007CC0"],showPreview:!0}),h.jsx("button",{className:"btn-lightblue cursor-pointer bg-my-archive rounded uppercase",onClick:()=>A(!1),children:"done"})]})]}),g=="email"&&h.jsx(qme,{settings:n?.payload.email}),g=="social_media"&&h.jsx(zme,{settings:n?.payload.socialMedia})]})]})})},Ume=()=>{const[e,t]=j.useState(!0);return h.jsxs("div",{className:"flex h-full -ml-6 -mr-5 border-t-24 border-blue-800",children:[h.jsx(Wme,{isOpen:e,setIsOpen:t}),h.jsx("div",{onClick:()=>t(!1),className:"ml-12 w-full",children:h.jsx(mu,{})})]})},ab=({children:e})=>h.jsx("div",{className:"h-12 bg-teal-50 border-b border-b-gray-50",children:e}),Gme=()=>{const e=rn();return Tt({mutationFn:t=>bt.executeRequest("/AdvancedSearch/create_adv_srch_folder","POST",{folderName:t}),onSuccess:()=>{Xe.success("Folder created successfully"),e.invalidateQueries({queryKey:["myArchiveFolders"]})},onError:t=>{Xe.error(t.message)}})},Xme=Md("/my-archive/folders"),Zme=({folder:e})=>h.jsx(qn,{to:"/my-archive/folders/$folder",params:{folder:`${e.id}`},search:{page:0,folderName:e.folderName},state:!0,className:"min-w-62 p-4 bg-white border border-blue-50 shadow-folder cursor-pointer rounded-md",children:h.jsxs("div",{className:"h-10 flex gap-8 items-center",children:[h.jsx("div",{className:"text-blue-500",children:h.jsx(we,{icon:dk,size:"large"})}),h.jsx("div",{className:"text-sm font-bold",children:e.folderName})]})}),Kme=()=>{const e=Xme.useSearch();e.page||(e.page=0);const[t,n]=j.useState(!1),[r,i]=j.useState(""),{data:s,isLoading:l,isSuccess:u}=Gt(bz(e.page)),{mutate:d,isPending:m}=Gme(),v=b=>{i(b.currentTarget.value.trimStart())},g=()=>{d(r.trim(),{onSuccess:()=>{n(!1),i("")}})},y=j.useMemo(()=>u?s.totalResults>(e.page+1)*is:!1,[s,u]);return h.jsxs(h.Fragment,{children:[h.jsx(ab,{}),h.jsxs("div",{className:"p-10",children:[h.jsxs("div",{className:"flex justify-between items-center",children:[h.jsx("div",{className:"text-xl font-bold",children:"My Folders"}),h.jsx("button",{onClick:()=>n(!0),className:"text-base text-blue-500 cursor-pointer",children:"+ Create New Folder"})]}),h.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 xl:grid-cols-3 items-center gap-y-8 gap-x-12 my-8",children:[l&&h.jsx(Jt,{}),u&&s.results?.map(b=>h.jsx(Zme,{folder:b},b.id))]}),h.jsxs("div",{className:"flex justify-end-safe",children:[h.jsx(qn,{to:".",search:b=>({...b,page:e.page-1}),disabled:e.page===0,className:"aria-disabled:text-gray-400 cursor-pointer aria-disabled:cursor-default",children:h.jsx(we,{icon:n0,size:"xxlarge"})}),h.jsx(qn,{to:".",search:b=>({...b,page:e.page+1}),disabled:!y,className:"aria-disabled:text-gray-400 cursor-pointer aria-disabled:cursor-default",children:h.jsx(we,{icon:Aee,size:"xxlarge"})})]})]}),t&&h.jsx(bn,{title:"Create new folder",onClose:()=>n(!1),appendTo:null,width:500,children:h.jsxs("div",{className:"space-y-4",children:[h.jsx("input",{type:"text",value:r,onChange:v,className:"w-full px-4 py-3 border border-gray-300 rounded-md focus:outline-none"}),h.jsx("button",{onClick:g,disabled:m||r.trim().length===0,className:"btn-blue disabled:bg-gray-400 disabled:border-gray-400 disabled:cursor-not-allowed",children:"Save"})]})})]})},d0=Md("/my-archive/folders/$folder"),Jme=({rowSelection:e,setRowSelection:t})=>{const{page:n}=d0.useSearch(),{folder:r}=d0.useParams(),{data:i,isLoading:s}=Gt(xz(r,n)),l=i?.payload?.searchResults||[],u=i?.payload?.totalResults,d=ur(),m=[d.display({id:"id",minSize:60,maxSize:60,header:({table:C})=>h.jsx("input",{id:"selectAll",type:"checkbox",checked:C.getIsAllRowsSelected(),onChange:C.getToggleAllRowsSelectedHandler()}),cell:({row:C})=>h.jsx("label",{className:"px-6 py-4",onClick:M=>{M.stopPropagation()},children:h.jsx("input",{id:`select_${C.id}`,type:"checkbox",checked:C.getIsSelected(),onChange:C.getToggleSelectedHandler()})})}),d.accessor("date",{id:"date",header:"Date",cell:C=>h.jsx("span",{children:Qi(new Date(C.getValue()),"MM/dd/yyyy")})}),d.accessor("type",{header:"Element Type",size:200,cell:C=>{let M=C.getValue();return M=="social_media"&&(M=C.row.original.socialMediaType??M),h.jsx("span",{className:"capitalize",children:M})}}),d.accessor("expiredItem",{header:"Expired",size:200,cell:C=>h.jsx("span",{className:"capitalize",children:String(C.getValue())})})],[v,g]=j.useState({pageIndex:n||0,pageSize:is}),y=kr(),b=C=>{let M=v;typeof C=="function"?M=C(M):M=C,v.pageIndex!==M.pageIndex&&(g(C),y({to:".",search:P=>({...P,page:M.pageIndex})}))},A=fr({data:l,columns:m,getCoreRowModel:cr(),getRowId:C=>C.id,manualPagination:!0,getPaginationRowModel:dr(),pageCount:Math.ceil(u/is),rowCount:u,onPaginationChange:b,onRowSelectionChange:t,state:{pagination:v,rowSelection:e}}),w=kr(),S=C=>w({to:"/my-archive/preview",search:{path:C.original.s3Path,folder:Number(r)}});return h.jsx(N0,{emptyMessage:s?h.jsx(Jt,{}):i?.errorMessage,table:A,bordered:!1,pageSizes:[is],onRowClick:C=>S(C)})},xz=(e,t)=>({queryKey:["folderContent",e,t],queryFn:()=>bt.executeRequest("/AdvancedSearch/folder_content","POST",{folderId:e,pageNumber:t})}),$me=()=>{const e=rn();return Tt({mutationFn:({folder:t,ids:n})=>{const r=Object.keys(n).map(s=>({esId:s})),i=parseInt(t);return bt.executeRequest("/AdvancedSearch/remove_items_from_folder","POST",{folderId:i,selectedItems:r})},onSuccess:()=>{e.invalidateQueries({queryKey:["folderContent"]}),Xe.success("File removed from folder.")}})},epe=()=>Tt({mutationFn:({folderId:e,includeSearchTerms:t=!1,note:n=""})=>bt.executeRequest("/AdvancedSearch/add_folder_to_compliance_log","POST",{folderId:e,includeSearchTerms:t,note:n})}),tpe=()=>{const e=d0.useParams(),t=d0.useSearch(),{data:n,isError:r}=Gt(xz(e.folder,t.page)),[i,s]=j.useState({}),{mutate:l}=$me(),[u,d]=j.useState(!1),[m,v]=j.useState(!1),[g,y]=j.useState(""),{mutate:b}=epe(),A=()=>{b({folderId:Number(e.folder),includeSearchTerms:m,note:g})};return h.jsxs(h.Fragment,{children:[h.jsx(ab,{children:h.jsxs("div",{className:"px-8 flex h-full items-center justify-between",children:[h.jsxs(qn,{to:"..",className:"cursor-pointer text-gray-800 font-bold flex items-center",children:[h.jsx(we,{icon:n0,size:"large"}),h.jsx("span",{children:"Back"})]}),h.jsxs("div",{className:"flex gap-x-4",children:[h.jsxs("button",{className:"bg-white cursor-pointer shadow-sm px-4 py-1 flex gap-2 items-center rounded-sm text-md font-semibold disabled:bg-gray-300 disabled:text-gray-800 disabled:cursor-default",disabled:Object.keys(i).length<1,onClick:()=>{l({folder:e.folder,ids:i})},children:[h.jsx(we,{icon:xa,size:"large"}),"Delete"]}),h.jsxs("button",{className:"bg-white cursor-pointer shadow-sm px-4 py-1 flex gap-2 items-center rounded-sm text-md font-semibold disabled:bg-gray-300 disabled:text-gray-800 disabled:cursor-default",disabled:!n?.payload?.complianceLogBtnActv,onClick:()=>d(!0),children:[h.jsx(we,{icon:Fee,size:"large"}),"Send Folder to Compliance Log"]})]})]})}),h.jsxs("div",{className:"m-8",children:[h.jsx("h1",{children:t.folderName}),r?h.jsx("span",{children:"An error happend while loading"}):h.jsx(Jme,{rowSelection:i,setRowSelection:w=>s(w)})]}),u&&h.jsx(bn,{title:"",width:700,appendTo:null,onClose:()=>d(!1),children:h.jsxs("div",{className:"p-3",children:[h.jsxs("div",{className:"flex items-center justify-between border-b-6 border-blue-900 pb-2",children:[h.jsxs("h2",{className:"text-blue-900 text-xl font-semibold",children:["My Archive: ",t.folderName]}),h.jsxs("button",{className:"flex items-end text-blue-900 uppercase font-semibold hover:cursor-pointer",onClick:()=>d(!1),children:[h.jsx(we,{size:"medium",className:"mr-1",icon:vn})," Close"]})]}),h.jsxs("div",{className:"py-3 space-y-4",children:[h.jsx("div",{children:"Search Result Filters"}),h.jsx("textarea",{className:"text-sm outline-none py-3 px-5 border rounded border-[#DEE2E6] w-full h-[100px]",placeholder:"Add additional notes (maximum 200 characters)",maxLength:200,value:g,onChange:w=>y(w.currentTarget.value),name:"note",id:"note"}),h.jsxs("div",{className:"flex justify-between items-end",children:[h.jsxs("label",{className:"flex gap-1 items-center",children:[h.jsx("input",{type:"checkbox",name:"searchTerms",id:"searchTerms",className:"h-5 w-5 checked:accent-blue-900",checked:m,onClick:()=>v(!m)}),"Include Search Terms"]}),h.jsx("button",{onClick:A,className:"btn-blue",children:"Add to Log"})]})]})]})})]})};var Gl={},Fs={},Xl={},FL;function SI(){if(FL)return Xl;FL=1;var e=Xl&&Xl.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Xl,"__esModule",{value:!0}),Xl.useFrame=void 0;const t=e(hn()),n=r=>t.default.useMemo(()=>r||{document:typeof document<"u"?document:void 0,window:typeof window<"u"?window:void 0},[r]);return Xl.useFrame=n,Xl}var ks={},qs={},kL;function gl(){if(kL)return qs;kL=1;var e=qs&&qs.__rest||function(s,l){var u={};for(var d in s)Object.prototype.hasOwnProperty.call(s,d)&&l.indexOf(d)<0&&(u[d]=s[d]);if(s!=null&&typeof Object.getOwnPropertySymbols=="function")for(var m=0,d=Object.getOwnPropertySymbols(s);m<d.length;m++)l.indexOf(d[m])<0&&Object.prototype.propertyIsEnumerable.call(s,d[m])&&(u[d[m]]=s[d[m]]);return u},t=qs&&qs.__importDefault||function(s){return s&&s.__esModule?s:{default:s}};Object.defineProperty(qs,"__esModule",{value:!0}),qs.EmbedStyle=void 0;const n=t(_r()),r=t(hn()),i=s=>{var l=e(s,[]);return r.default.createElement("style",Object.assign({},l,{className:(0,n.default)(l.className),style:Object.assign({},l.style)}),`
|
|
625
|
+
`]))),lt=function(W,Oe){var Ee=W.isFocused,_e=W.size,rt=W.theme,Ze=rt.colors,St=rt.spacing.baseUnit;return e({label:"loadingIndicator",display:"flex",transition:"color 150ms",alignSelf:"center",fontSize:_e,lineHeight:1,marginRight:_e,textAlign:"center",verticalAlign:"middle"},Oe?{}:{color:Ee?Ze.neutral60:Ze.neutral20,padding:St*2})},yt=function(W){var Oe=W.delay,Ee=W.offset;return n.jsx("span",{css:n.css({animation:"".concat(Ht," 1s ease-in-out ").concat(Oe,"ms infinite;"),backgroundColor:"currentColor",borderRadius:"1em",display:"inline-block",marginLeft:Ee?"1em":void 0,height:"1em",verticalAlign:"top",width:"1em"},"","")})},kt=function(W){var Oe=W.innerProps,Ee=W.isRtl,_e=W.size,rt=_e===void 0?4:_e,Ze=i(W,te);return n.jsx("div",t({},_(e(e({},Ze),{},{innerProps:Oe,isRtl:Ee,size:rt}),"loadingIndicator",{indicator:!0,"loading-indicator":!0}),Oe),n.jsx(yt,{delay:0,offset:Ee}),n.jsx(yt,{delay:160,offset:!0}),n.jsx(yt,{delay:320,offset:!Ee}))},en=function(W,Oe){var Ee=W.isDisabled,_e=W.isFocused,rt=W.theme,Ze=rt.colors,St=rt.borderRadius,_t=rt.spacing;return e({label:"control",alignItems:"center",cursor:"default",display:"flex",flexWrap:"wrap",justifyContent:"space-between",minHeight:_t.controlHeight,outline:"0 !important",position:"relative",transition:"all 100ms"},Oe?{}:{backgroundColor:Ee?Ze.neutral5:Ze.neutral0,borderColor:Ee?Ze.neutral10:_e?Ze.primary:Ze.neutral20,borderRadius:St,borderStyle:"solid",borderWidth:1,boxShadow:_e?"0 0 0 1px ".concat(Ze.primary):void 0,"&:hover":{borderColor:_e?Ze.primary:Ze.neutral30}})},Ue=function(W){var Oe=W.children,Ee=W.isDisabled,_e=W.isFocused,rt=W.innerRef,Ze=W.innerProps,St=W.menuIsOpen;return n.jsx("div",t({ref:rt},_(W,"control",{control:!0,"control--is-disabled":Ee,"control--is-focused":_e,"control--menu-is-open":St}),Ze,{"aria-disabled":Ee||void 0}),Oe)},ct=Ue,gt=["data"],pe=function(W,Oe){var Ee=W.theme.spacing;return Oe?{}:{paddingBottom:Ee.baseUnit*2,paddingTop:Ee.baseUnit*2}},ve=function(W){var Oe=W.children,Ee=W.cx,_e=W.getStyles,rt=W.getClassNames,Ze=W.Heading,St=W.headingProps,_t=W.innerProps,An=W.label,On=W.theme,Mn=W.selectProps;return n.jsx("div",t({},_(W,"group",{group:!0}),_t),n.jsx(Ze,t({},St,{selectProps:Mn,theme:On,getStyles:_e,getClassNames:rt,cx:Ee}),An),n.jsx("div",null,Oe))},qe=function(W,Oe){var Ee=W.theme,_e=Ee.colors,rt=Ee.spacing;return e({label:"group",cursor:"default",display:"block"},Oe?{}:{color:_e.neutral40,fontSize:"75%",fontWeight:500,marginBottom:"0.25em",paddingLeft:rt.baseUnit*3,paddingRight:rt.baseUnit*3,textTransform:"uppercase"})},Fe=function(W){var Oe=P(W);Oe.data;var Ee=i(Oe,gt);return n.jsx("div",t({},_(W,"groupHeading",{"group-heading":!0}),Ee))},L=ve,Te=["innerRef","isDisabled","isHidden","inputClassName"],Qe=function(W,Oe){var Ee=W.isDisabled,_e=W.value,rt=W.theme,Ze=rt.spacing,St=rt.colors;return e(e({visibility:Ee?"hidden":"visible",transform:_e?"translateZ(0)":""},le),Oe?{}:{margin:Ze.baseUnit/2,paddingBottom:Ze.baseUnit/2,paddingTop:Ze.baseUnit/2,color:St.neutral80})},tt={gridArea:"1 / 2",font:"inherit",minWidth:"2px",border:0,margin:0,outline:0,padding:0},le={flex:"1 1 auto",display:"inline-grid",gridArea:"1 / 1 / 2 / 3",gridTemplateColumns:"0 min-content","&:after":e({content:'attr(data-value) " "',visibility:"hidden",whiteSpace:"pre"},tt)},Pe=function(W){return e({label:"input",color:"inherit",background:0,opacity:W?0:1,width:"100%"},tt)},ze=function(W){var Oe=W.cx,Ee=W.value,_e=P(W),rt=_e.innerRef,Ze=_e.isDisabled,St=_e.isHidden,_t=_e.inputClassName,An=i(_e,Te);return n.jsx("div",t({},_(W,"input",{"input-container":!0}),{"data-value":Ee||""}),n.jsx("input",t({className:Oe({input:!0},_t),ref:rt,style:Pe(St),disabled:Ze},An)))},at=ze,Ot=function(W,Oe){var Ee=W.theme,_e=Ee.spacing,rt=Ee.borderRadius,Ze=Ee.colors;return e({label:"multiValue",display:"flex",minWidth:0},Oe?{}:{backgroundColor:Ze.neutral10,borderRadius:rt/2,margin:_e.baseUnit/2})},Ct=function(W,Oe){var Ee=W.theme,_e=Ee.borderRadius,rt=Ee.colors,Ze=W.cropWithEllipsis;return e({overflow:"hidden",textOverflow:Ze||Ze===void 0?"ellipsis":void 0,whiteSpace:"nowrap"},Oe?{}:{borderRadius:_e/2,color:rt.neutral80,fontSize:"85%",padding:3,paddingLeft:6})},jt=function(W,Oe){var Ee=W.theme,_e=Ee.spacing,rt=Ee.borderRadius,Ze=Ee.colors,St=W.isFocused;return e({alignItems:"center",display:"flex"},Oe?{}:{borderRadius:rt/2,backgroundColor:St?Ze.dangerLight:void 0,paddingLeft:_e.baseUnit,paddingRight:_e.baseUnit,":hover":{backgroundColor:Ze.dangerLight,color:Ze.danger}})},ft=function(W){var Oe=W.children,Ee=W.innerProps;return n.jsx("div",Ee,Oe)},ut=ft,tn=ft;function mn(Ce){var W=Ce.children,Oe=Ce.innerProps;return n.jsx("div",t({role:"button"},Oe),W||n.jsx(Re,{size:14}))}var wn=function(W){var Oe=W.children,Ee=W.components,_e=W.data,rt=W.innerProps,Ze=W.isDisabled,St=W.removeProps,_t=W.selectProps,An=Ee.Container,On=Ee.Label,Mn=Ee.Remove;return n.jsx(An,{data:_e,innerProps:e(e({},_(W,"multiValue",{"multi-value":!0,"multi-value--is-disabled":Ze})),rt),selectProps:_t},n.jsx(On,{data:_e,innerProps:e({},_(W,"multiValueLabel",{"multi-value__label":!0})),selectProps:_t},Oe),n.jsx(Mn,{data:_e,innerProps:e(e({},_(W,"multiValueRemove",{"multi-value__remove":!0})),{},{"aria-label":"Remove ".concat(Oe||"option")},St),selectProps:_t}))},Sn=wn,yn=function(W,Oe){var Ee=W.isDisabled,_e=W.isFocused,rt=W.isSelected,Ze=W.theme,St=Ze.spacing,_t=Ze.colors;return e({label:"option",cursor:"default",display:"block",fontSize:"inherit",width:"100%",userSelect:"none",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)"},Oe?{}:{backgroundColor:rt?_t.primary:_e?_t.primary25:"transparent",color:Ee?_t.neutral20:rt?_t.neutral0:"inherit",padding:"".concat(St.baseUnit*2,"px ").concat(St.baseUnit*3,"px"),":active":{backgroundColor:Ee?void 0:rt?_t.primary:_t.primary50}})},Jn=function(W){var Oe=W.children,Ee=W.isDisabled,_e=W.isFocused,rt=W.isSelected,Ze=W.innerRef,St=W.innerProps;return n.jsx("div",t({},_(W,"option",{option:!0,"option--is-disabled":Ee,"option--is-focused":_e,"option--is-selected":rt}),{ref:Ze,"aria-disabled":Ee},St),Oe)},$n=Jn,an=function(W,Oe){var Ee=W.theme,_e=Ee.spacing,rt=Ee.colors;return e({label:"placeholder",gridArea:"1 / 1 / 2 / 3"},Oe?{}:{color:rt.neutral50,marginLeft:_e.baseUnit/2,marginRight:_e.baseUnit/2})},ar=function(W){var Oe=W.children,Ee=W.innerProps;return n.jsx("div",t({},_(W,"placeholder",{placeholder:!0}),Ee),Oe)},Rr=ar,ei=function(W,Oe){var Ee=W.isDisabled,_e=W.theme,rt=_e.spacing,Ze=_e.colors;return e({label:"singleValue",gridArea:"1 / 1 / 2 / 3",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},Oe?{}:{color:Ee?Ze.neutral40:Ze.neutral80,marginLeft:rt.baseUnit/2,marginRight:rt.baseUnit/2})},Qr=function(W){var Oe=W.children,Ee=W.isDisabled,_e=W.innerProps;return n.jsx("div",t({},_(W,"singleValue",{"single-value":!0,"single-value--is-disabled":Ee}),_e),Oe)},er=Qr,_i={ClearIndicator:vt,Control:ct,DropdownIndicator:mt,DownChevron:Ve,CrossIcon:Re,Group:L,GroupHeading:Fe,IndicatorsContainer:J,IndicatorSeparator:xt,Input:at,LoadingIndicator:kt,Menu:ke,MenuList:Me,MenuPortal:dt,LoadingMessage:it,NoOptionsMessage:Be,MultiValue:Sn,MultiValueContainer:ut,MultiValueLabel:tn,MultiValueRemove:mn,Option:$n,Placeholder:Rr,SelectContainer:At,SingleValue:er,ValueContainer:It},br=function(W){return e(e({},_i),W.components)};return ln.MenuPlacer=oe,ln.classNames=C,ln.cleanValue=M,ln.clearIndicatorCSS=st,ln.components=_i,ln.containerCSS=Et,ln.css=en,ln.css$1=ei,ln.defaultComponents=br,ln.dropdownIndicatorCSS=et,ln.groupCSS=pe,ln.groupHeadingCSS=qe,ln.handleInputChange=E,ln.indicatorSeparatorCSS=Ft,ln.indicatorsContainerCSS=zt,ln.inputCSS=Qe,ln.isDocumentElement=D,ln.isMobileDevice=q,ln.isTouchCapable=ee,ln.loadingIndicatorCSS=lt,ln.loadingMessageCSS=He,ln.menuCSS=de,ln.menuListCSS=We,ln.menuPortalCSS=pt,ln.multiValueAsValue=U,ln.multiValueCSS=Ot,ln.multiValueLabelCSS=Ct,ln.multiValueRemoveCSS=jt,ln.noOptionsMessageCSS=De,ln.noop=w,ln.notNullish=Y,ln.optionCSS=yn,ln.placeholderCSS=an,ln.removeProps=se,ln.scrollIntoView=H,ln.singleValueAsValue=$,ln.supportsPassiveEvents=Q,ln.valueContainerCSS=Nt,ln.valueTernary=K,ln}var TL=Number.isNaN||function(t){return typeof t=="number"&&t!==t};function Pme(e,t){return!!(e===t||TL(e)&&TL(t))}function Mme(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(!Pme(e[n],t[n]))return!1;return!0}function Tme(e,t){t===void 0&&(t=Mme);var n=null;function r(){for(var i=[],s=0;s<arguments.length;s++)i[s]=arguments[s];if(n&&n.lastThis===this&&t(i,n.lastArgs))return n.lastResult;var l=e.apply(this,i);return n={lastResult:l,lastArgs:i,lastThis:this},l}return r.clear=function(){n=null},r}const _me=Object.freeze(Object.defineProperty({__proto__:null,default:Tme},Symbol.toStringTag,{value:"Module"})),jme=f0(_me);var _L;function Nme(){if(_L)return Ls;_L=1;var e=Rm(),t=rb(),n=uz(),r=cz(),i=dz(),s=fz(),l=hz(),u=hn(),d=gz(),m=I0(),v=jme,g=ib();function y(pe){return pe&&pe.__esModule?pe:{default:pe}}function b(pe){if(pe&&pe.__esModule)return pe;var ve=Object.create(null);return pe&&Object.keys(pe).forEach(function(qe){if(qe!=="default"){var Fe=Object.getOwnPropertyDescriptor(pe,qe);Object.defineProperty(ve,qe,Fe.get?Fe:{enumerable:!0,get:function(){return pe[qe]}})}}),ve.default=pe,Object.freeze(ve)}for(var A=b(u),w=y(v),S={name:"7pg0cj-a11yText",styles:"label:a11yText;z-index:9999;border:0;clip:rect(1px, 1px, 1px, 1px);height:1px;width:1px;position:absolute;overflow:hidden;padding:0;white-space:nowrap"},C=function(ve){return m.jsx("span",e({css:S},ve))},M=C,P={guidance:function(ve){var qe=ve.isSearchable,Fe=ve.isMulti,L=ve.tabSelectsValue,Te=ve.context,Qe=ve.isInitialFocus;switch(Te){case"menu":return"Use Up and Down to choose options, press Enter to select the currently focused option, press Escape to exit the menu".concat(L?", press Tab to select the option and exit the menu":"",".");case"input":return Qe?"".concat(ve["aria-label"]||"Select"," is focused ").concat(qe?",type to refine list":"",", press Down to open the menu, ").concat(Fe?" press left to focus selected values":""):"";case"value":return"Use left and right to toggle between focused values, press Backspace to remove the currently focused value";default:return""}},onChange:function(ve){var qe=ve.action,Fe=ve.label,L=Fe===void 0?"":Fe,Te=ve.labels,Qe=ve.isDisabled;switch(qe){case"deselect-option":case"pop-value":case"remove-value":return"option ".concat(L,", deselected.");case"clear":return"All selected options have been cleared.";case"initial-input-focus":return"option".concat(Te.length>1?"s":""," ").concat(Te.join(","),", selected.");case"select-option":return Qe?"option ".concat(L," is disabled. Select another option."):"option ".concat(L,", selected.");default:return""}},onFocus:function(ve){var qe=ve.context,Fe=ve.focused,L=ve.options,Te=ve.label,Qe=Te===void 0?"":Te,tt=ve.selectValue,le=ve.isDisabled,Pe=ve.isSelected,ze=ve.isAppleDevice,at=function(ft,ut){return ft&&ft.length?"".concat(ft.indexOf(ut)+1," of ").concat(ft.length):""};if(qe==="value"&&tt)return"value ".concat(Qe," focused, ").concat(at(tt,Fe),".");if(qe==="menu"&&ze){var Ot=le?" disabled":"",Ct="".concat(Pe?" selected":"").concat(Ot);return"".concat(Qe).concat(Ct,", ").concat(at(L,Fe),".")}return""},onFilter:function(ve){var qe=ve.inputValue,Fe=ve.resultsMessage;return"".concat(Fe).concat(qe?" for search term "+qe:"",".")}},_=function(ve){var qe=ve.ariaSelection,Fe=ve.focusedOption,L=ve.focusedValue,Te=ve.focusableOptions,Qe=ve.isFocused,tt=ve.selectValue,le=ve.selectProps,Pe=ve.id,ze=ve.isAppleDevice,at=le.ariaLiveMessages,Ot=le.getOptionLabel,Ct=le.inputValue,jt=le.isMulti,ft=le.isOptionDisabled,ut=le.isSearchable,tn=le.menuIsOpen,mn=le.options,wn=le.screenReaderStatus,Sn=le.tabSelectsValue,yn=le.isLoading,Jn=le["aria-label"],$n=le["aria-live"],an=u.useMemo(function(){return t(t({},P),at||{})},[at]),ar=u.useMemo(function(){var br="";if(qe&&an.onChange){var Ce=qe.option,W=qe.options,Oe=qe.removedValue,Ee=qe.removedValues,_e=qe.value,rt=function(tr){return Array.isArray(tr)?null:tr},Ze=Oe||Ce||rt(_e),St=Ze?Ot(Ze):"",_t=W||Ee||void 0,An=_t?_t.map(Ot):[],On=t({isDisabled:Ze&&ft(Ze,tt),label:St,labels:An},qe);br=an.onChange(On)}return br},[qe,an,ft,tt,Ot]),Rr=u.useMemo(function(){var br="",Ce=Fe||L,W=!!(Fe&&tt&&tt.includes(Fe));if(Ce&&an.onFocus){var Oe={focused:Ce,label:Ot(Ce),isDisabled:ft(Ce,tt),isSelected:W,options:Te,context:Ce===Fe?"menu":"value",selectValue:tt,isAppleDevice:ze};br=an.onFocus(Oe)}return br},[Fe,L,Ot,ft,an,Te,tt,ze]),ei=u.useMemo(function(){var br="";if(tn&&mn.length&&!yn&&an.onFilter){var Ce=wn({count:Te.length});br=an.onFilter({inputValue:Ct,resultsMessage:Ce})}return br},[Te,Ct,tn,an,mn,wn,yn]),Qr=qe?.action==="initial-input-focus",er=u.useMemo(function(){var br="";if(an.guidance){var Ce=L?"value":tn?"menu":"input";br=an.guidance({"aria-label":Jn,context:Ce,isDisabled:Fe&&ft(Fe,tt),isMulti:jt,isSearchable:ut,tabSelectsValue:Sn,isInitialFocus:Qr})}return br},[Jn,Fe,L,jt,ft,ut,tn,an,tt,Sn,Qr]),_i=m.jsx(u.Fragment,null,m.jsx("span",{id:"aria-selection"},ar),m.jsx("span",{id:"aria-focused"},Rr),m.jsx("span",{id:"aria-results"},ei),m.jsx("span",{id:"aria-guidance"},er));return m.jsx(u.Fragment,null,m.jsx(M,{id:Pe},Qr&&_i),m.jsx(M,{"aria-live":$n,"aria-atomic":"false","aria-relevant":"additions text",role:"log"},Qe&&!Qr&&_i))},E=_,D=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],O=new RegExp("["+D.map(function(pe){return pe.letters}).join("")+"]","g"),I={},T=0;T<D.length;T++)for(var N=D[T],F=0;F<N.letters.length;F++)I[N.letters[F]]=N.base;var k=function(ve){return ve.replace(O,function(qe){return I[qe]})},H=w.default(k),V=function(ve){return ve.replace(/^\s+|\s+$/g,"")},ee=function(ve){return"".concat(ve.label," ").concat(ve.value)},q=function(ve){return function(qe,Fe){if(qe.data.__isNew__)return!0;var L=t({ignoreCase:!0,ignoreAccents:!0,stringify:ee,trim:!0,matchFrom:"any"},ve),Te=L.ignoreCase,Qe=L.ignoreAccents,tt=L.stringify,le=L.trim,Pe=L.matchFrom,ze=le?V(Fe):Fe,at=le?V(tt(qe)):tt(qe);return Te&&(ze=ze.toLowerCase(),at=at.toLowerCase()),Qe&&(ze=H(ze),at=k(at)),Pe==="start"?at.substr(0,ze.length)===ze:at.indexOf(ze)>-1}},Z=["innerRef"];function ae(pe){var ve=pe.innerRef,qe=g(pe,Z),Fe=d.removeProps(qe,"onExited","in","enter","exit","appear");return m.jsx("input",e({ref:ve},Fe,{css:m.css({label:"dummyInput",background:0,border:0,caretColor:"transparent",fontSize:"inherit",gridArea:"1 / 1 / 2 / 3",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(.01)"},"","")}))}var ge=function(ve){ve.cancelable&&ve.preventDefault(),ve.stopPropagation()};function Q(pe){var ve=pe.isEnabled,qe=pe.onBottomArrive,Fe=pe.onBottomLeave,L=pe.onTopArrive,Te=pe.onTopLeave,Qe=u.useRef(!1),tt=u.useRef(!1),le=u.useRef(0),Pe=u.useRef(null),ze=u.useCallback(function(ut,tn){if(Pe.current!==null){var mn=Pe.current,wn=mn.scrollTop,Sn=mn.scrollHeight,yn=mn.clientHeight,Jn=Pe.current,$n=tn>0,an=Sn-yn-wn,ar=!1;an>tn&&Qe.current&&(Fe&&Fe(ut),Qe.current=!1),$n&&tt.current&&(Te&&Te(ut),tt.current=!1),$n&&tn>an?(qe&&!Qe.current&&qe(ut),Jn.scrollTop=Sn,ar=!0,Qe.current=!0):!$n&&-tn>wn&&(L&&!tt.current&&L(ut),Jn.scrollTop=0,ar=!0,tt.current=!0),ar&&ge(ut)}},[qe,Fe,L,Te]),at=u.useCallback(function(ut){ze(ut,ut.deltaY)},[ze]),Ot=u.useCallback(function(ut){le.current=ut.changedTouches[0].clientY},[]),Ct=u.useCallback(function(ut){var tn=le.current-ut.changedTouches[0].clientY;ze(ut,tn)},[ze]),jt=u.useCallback(function(ut){if(ut){var tn=d.supportsPassiveEvents?{passive:!1}:!1;ut.addEventListener("wheel",at,tn),ut.addEventListener("touchstart",Ot,tn),ut.addEventListener("touchmove",Ct,tn)}},[Ct,Ot,at]),ft=u.useCallback(function(ut){ut&&(ut.removeEventListener("wheel",at,!1),ut.removeEventListener("touchstart",Ot,!1),ut.removeEventListener("touchmove",Ct,!1))},[Ct,Ot,at]);return u.useEffect(function(){if(ve){var ut=Pe.current;return jt(ut),function(){ft(ut)}}},[ve,jt,ft]),function(ut){Pe.current=ut}}var Y=["boxSizing","height","overflow","paddingRight","position"],X={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function K(pe){pe.cancelable&&pe.preventDefault()}function $(pe){pe.stopPropagation()}function U(){var pe=this.scrollTop,ve=this.scrollHeight,qe=pe+this.offsetHeight;pe===0?this.scrollTop=1:qe===ve&&(this.scrollTop=pe-1)}function se(){return"ontouchstart"in window||navigator.maxTouchPoints}var je=!!(typeof window<"u"&&window.document&&window.document.createElement),me=0,G={capture:!1,passive:!1};function re(pe){var ve=pe.isEnabled,qe=pe.accountForScrollbars,Fe=qe===void 0?!0:qe,L=u.useRef({}),Te=u.useRef(null),Qe=u.useCallback(function(le){if(je){var Pe=document.body,ze=Pe&&Pe.style;if(Fe&&Y.forEach(function(jt){var ft=ze&&ze[jt];L.current[jt]=ft}),Fe&&me<1){var at=parseInt(L.current.paddingRight,10)||0,Ot=document.body?document.body.clientWidth:0,Ct=window.innerWidth-Ot+at||0;Object.keys(X).forEach(function(jt){var ft=X[jt];ze&&(ze[jt]=ft)}),ze&&(ze.paddingRight="".concat(Ct,"px"))}Pe&&se()&&(Pe.addEventListener("touchmove",K,G),le&&(le.addEventListener("touchstart",U,G),le.addEventListener("touchmove",$,G))),me+=1}},[Fe]),tt=u.useCallback(function(le){if(je){var Pe=document.body,ze=Pe&&Pe.style;me=Math.max(me-1,0),Fe&&me<1&&Y.forEach(function(at){var Ot=L.current[at];ze&&(ze[at]=Ot)}),Pe&&se()&&(Pe.removeEventListener("touchmove",K,G),le&&(le.removeEventListener("touchstart",U,G),le.removeEventListener("touchmove",$,G)))}},[Fe]);return u.useEffect(function(){if(ve){var le=Te.current;return Qe(le),function(){tt(le)}}},[ve,Qe,tt]),function(le){Te.current=le}}var fe=function(ve){var qe=ve.target;return qe.ownerDocument.activeElement&&qe.ownerDocument.activeElement.blur()},de={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function ce(pe){var ve=pe.children,qe=pe.lockEnabled,Fe=pe.captureEnabled,L=Fe===void 0?!0:Fe,Te=pe.onBottomArrive,Qe=pe.onBottomLeave,tt=pe.onTopArrive,le=pe.onTopLeave,Pe=Q({isEnabled:L,onBottomArrive:Te,onBottomLeave:Qe,onTopArrive:tt,onTopLeave:le}),ze=re({isEnabled:qe}),at=function(Ct){Pe(Ct),ze(Ct)};return m.jsx(u.Fragment,null,qe&&m.jsx("div",{onClick:fe,css:de}),ve(at))}var oe={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},Ne=function(ve){var qe=ve.name,Fe=ve.onFocus;return m.jsx("input",{required:!0,name:qe,tabIndex:-1,"aria-hidden":"true",onFocus:Fe,css:oe,value:"",onChange:function(){}})},ke=Ne;function We(pe){var ve;return typeof window<"u"&&window.navigator!=null?pe.test(((ve=window.navigator.userAgentData)===null||ve===void 0?void 0:ve.platform)||window.navigator.platform):!1}function Me(){return We(/^iPhone/i)}function Le(){return We(/^Mac/i)}function De(){return We(/^iPad/i)||Le()&&navigator.maxTouchPoints>1}function He(){return Me()||De()}function Be(){return Le()||He()}var it=function(ve){return ve.label},pt=function(ve){return ve.label},dt=function(ve){return ve.value},Et=function(ve){return!!ve.isDisabled},At={clearIndicator:d.clearIndicatorCSS,container:d.containerCSS,control:d.css,dropdownIndicator:d.dropdownIndicatorCSS,group:d.groupCSS,groupHeading:d.groupHeadingCSS,indicatorsContainer:d.indicatorsContainerCSS,indicatorSeparator:d.indicatorSeparatorCSS,input:d.inputCSS,loadingIndicator:d.loadingIndicatorCSS,loadingMessage:d.loadingMessageCSS,menu:d.menuCSS,menuList:d.menuListCSS,menuPortal:d.menuPortalCSS,multiValue:d.multiValueCSS,multiValueLabel:d.multiValueLabelCSS,multiValueRemove:d.multiValueRemoveCSS,noOptionsMessage:d.noOptionsMessageCSS,option:d.optionCSS,placeholder:d.placeholderCSS,singleValue:d.css$1,valueContainer:d.valueContainerCSS};function Nt(pe){var ve=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},qe=t({},pe);return Object.keys(ve).forEach(function(Fe){var L=Fe;pe[L]?qe[L]=function(Te,Qe){return ve[L](pe[L](Te,Qe),Qe)}:qe[L]=ve[L]}),qe}var It={primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},zt=4,J=4,nt=38,ht=J*2,te={baseUnit:J,controlHeight:nt,menuGutter:ht},ne={borderRadius:zt,colors:It,spacing:te},xe={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:d.isTouchCapable(),captureMenuScroll:!d.isTouchCapable(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:q(),formatGroupLabel:it,getOptionLabel:pt,getOptionValue:dt,isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:Et,loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!d.isMobileDevice(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(ve){var qe=ve.count;return"".concat(qe," result").concat(qe!==1?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function Re(pe,ve,qe,Fe){var L=yt(pe,ve,qe),Te=kt(pe,ve,qe),Qe=Ht(pe,ve),tt=lt(pe,ve);return{type:"option",data:ve,isDisabled:L,isSelected:Te,label:Qe,value:tt,index:Fe}}function Ve(pe,ve){return pe.options.map(function(qe,Fe){if("options"in qe){var L=qe.options.map(function(Qe,tt){return Re(pe,Qe,ve,tt)}).filter(function(Qe){return st(pe,Qe)});return L.length>0?{type:"group",data:qe,options:L,index:Fe}:void 0}var Te=Re(pe,qe,ve,Fe);return st(pe,Te)?Te:void 0}).filter(d.notNullish)}function ot(pe){return pe.reduce(function(ve,qe){return qe.type==="group"?ve.push.apply(ve,l(qe.options.map(function(Fe){return Fe.data}))):ve.push(qe.data),ve},[])}function et(pe,ve){return pe.reduce(function(qe,Fe){return Fe.type==="group"?qe.push.apply(qe,l(Fe.options.map(function(L){return{data:L.data,id:"".concat(ve,"-").concat(Fe.index,"-").concat(L.index)}}))):qe.push({data:Fe.data,id:"".concat(ve,"-").concat(Fe.index)}),qe},[])}function mt(pe,ve){return ot(Ve(pe,ve))}function st(pe,ve){var qe=pe.inputValue,Fe=qe===void 0?"":qe,L=ve.data,Te=ve.isSelected,Qe=ve.label,tt=ve.value;return(!Ue(pe)||!Te)&&en(pe,{label:Qe,value:tt,data:L},Fe)}function vt(pe,ve){var qe=pe.focusedValue,Fe=pe.selectValue,L=Fe.indexOf(qe);if(L>-1){var Te=ve.indexOf(qe);if(Te>-1)return qe;if(L<ve.length)return ve[L]}return null}function Ft(pe,ve){var qe=pe.focusedOption;return qe&&ve.indexOf(qe)>-1?qe:ve[0]}var xt=function(ve,qe){var Fe,L=(Fe=ve.find(function(Te){return Te.data===qe}))===null||Fe===void 0?void 0:Fe.id;return L||null},Ht=function(ve,qe){return ve.getOptionLabel(qe)},lt=function(ve,qe){return ve.getOptionValue(qe)};function yt(pe,ve,qe){return typeof pe.isOptionDisabled=="function"?pe.isOptionDisabled(ve,qe):!1}function kt(pe,ve,qe){if(qe.indexOf(ve)>-1)return!0;if(typeof pe.isOptionSelected=="function")return pe.isOptionSelected(ve,qe);var Fe=lt(pe,ve);return qe.some(function(L){return lt(pe,L)===Fe})}function en(pe,ve,qe){return pe.filterOption?pe.filterOption(ve,qe):!0}var Ue=function(ve){var qe=ve.hideSelectedOptions,Fe=ve.isMulti;return qe===void 0?Fe:qe},ct=1,gt=function(pe){i(qe,pe);var ve=s(qe);function qe(Fe){var L;if(n(this,qe),L=ve.call(this,Fe),L.state={ariaSelection:null,focusedOption:null,focusedOptionId:null,focusableOptionsWithIds:[],focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0,instancePrefix:"",isAppleDevice:!1},L.blockOptionHover=!1,L.isComposing=!1,L.commonProps=void 0,L.initialTouchX=0,L.initialTouchY=0,L.openAfterFocus=!1,L.scrollToFocusedOptionOnUpdate=!1,L.userIsDragging=void 0,L.controlRef=null,L.getControlRef=function(le){L.controlRef=le},L.focusedOptionRef=null,L.getFocusedOptionRef=function(le){L.focusedOptionRef=le},L.menuListRef=null,L.getMenuListRef=function(le){L.menuListRef=le},L.inputRef=null,L.getInputRef=function(le){L.inputRef=le},L.focus=L.focusInput,L.blur=L.blurInput,L.onChange=function(le,Pe){var ze=L.props,at=ze.onChange,Ot=ze.name;Pe.name=Ot,L.ariaOnChange(le,Pe),at(le,Pe)},L.setValue=function(le,Pe,ze){var at=L.props,Ot=at.closeMenuOnSelect,Ct=at.isMulti,jt=at.inputValue;L.onInputChange("",{action:"set-value",prevInputValue:jt}),Ot&&(L.setState({inputIsHiddenAfterUpdate:!Ct}),L.onMenuClose()),L.setState({clearFocusValueOnUpdate:!0}),L.onChange(le,{action:Pe,option:ze})},L.selectOption=function(le){var Pe=L.props,ze=Pe.blurInputOnSelect,at=Pe.isMulti,Ot=Pe.name,Ct=L.state.selectValue,jt=at&&L.isOptionSelected(le,Ct),ft=L.isOptionDisabled(le,Ct);if(jt){var ut=L.getOptionValue(le);L.setValue(d.multiValueAsValue(Ct.filter(function(tn){return L.getOptionValue(tn)!==ut})),"deselect-option",le)}else if(!ft)at?L.setValue(d.multiValueAsValue([].concat(l(Ct),[le])),"select-option",le):L.setValue(d.singleValueAsValue(le),"select-option");else{L.ariaOnChange(d.singleValueAsValue(le),{action:"select-option",option:le,name:Ot});return}ze&&L.blurInput()},L.removeValue=function(le){var Pe=L.props.isMulti,ze=L.state.selectValue,at=L.getOptionValue(le),Ot=ze.filter(function(jt){return L.getOptionValue(jt)!==at}),Ct=d.valueTernary(Pe,Ot,Ot[0]||null);L.onChange(Ct,{action:"remove-value",removedValue:le}),L.focusInput()},L.clearValue=function(){var le=L.state.selectValue;L.onChange(d.valueTernary(L.props.isMulti,[],null),{action:"clear",removedValues:le})},L.popValue=function(){var le=L.props.isMulti,Pe=L.state.selectValue,ze=Pe[Pe.length-1],at=Pe.slice(0,Pe.length-1),Ot=d.valueTernary(le,at,at[0]||null);ze&&L.onChange(Ot,{action:"pop-value",removedValue:ze})},L.getFocusedOptionId=function(le){return xt(L.state.focusableOptionsWithIds,le)},L.getFocusableOptionsWithIds=function(){return et(Ve(L.props,L.state.selectValue),L.getElementId("option"))},L.getValue=function(){return L.state.selectValue},L.cx=function(){for(var le=arguments.length,Pe=new Array(le),ze=0;ze<le;ze++)Pe[ze]=arguments[ze];return d.classNames.apply(void 0,[L.props.classNamePrefix].concat(Pe))},L.getOptionLabel=function(le){return Ht(L.props,le)},L.getOptionValue=function(le){return lt(L.props,le)},L.getStyles=function(le,Pe){var ze=L.props.unstyled,at=At[le](Pe,ze);at.boxSizing="border-box";var Ot=L.props.styles[le];return Ot?Ot(at,Pe):at},L.getClassNames=function(le,Pe){var ze,at;return(ze=(at=L.props.classNames)[le])===null||ze===void 0?void 0:ze.call(at,Pe)},L.getElementId=function(le){return"".concat(L.state.instancePrefix,"-").concat(le)},L.getComponents=function(){return d.defaultComponents(L.props)},L.buildCategorizedOptions=function(){return Ve(L.props,L.state.selectValue)},L.getCategorizedOptions=function(){return L.props.menuIsOpen?L.buildCategorizedOptions():[]},L.buildFocusableOptions=function(){return ot(L.buildCategorizedOptions())},L.getFocusableOptions=function(){return L.props.menuIsOpen?L.buildFocusableOptions():[]},L.ariaOnChange=function(le,Pe){L.setState({ariaSelection:t({value:le},Pe)})},L.onMenuMouseDown=function(le){le.button===0&&(le.stopPropagation(),le.preventDefault(),L.focusInput())},L.onMenuMouseMove=function(le){L.blockOptionHover=!1},L.onControlMouseDown=function(le){if(!le.defaultPrevented){var Pe=L.props.openMenuOnClick;L.state.isFocused?L.props.menuIsOpen?le.target.tagName!=="INPUT"&&le.target.tagName!=="TEXTAREA"&&L.onMenuClose():Pe&&L.openMenu("first"):(Pe&&(L.openAfterFocus=!0),L.focusInput()),le.target.tagName!=="INPUT"&&le.target.tagName!=="TEXTAREA"&&le.preventDefault()}},L.onDropdownIndicatorMouseDown=function(le){if(!(le&&le.type==="mousedown"&&le.button!==0)&&!L.props.isDisabled){var Pe=L.props,ze=Pe.isMulti,at=Pe.menuIsOpen;L.focusInput(),at?(L.setState({inputIsHiddenAfterUpdate:!ze}),L.onMenuClose()):L.openMenu("first"),le.preventDefault()}},L.onClearIndicatorMouseDown=function(le){le&&le.type==="mousedown"&&le.button!==0||(L.clearValue(),le.preventDefault(),L.openAfterFocus=!1,le.type==="touchend"?L.focusInput():setTimeout(function(){return L.focusInput()}))},L.onScroll=function(le){typeof L.props.closeMenuOnScroll=="boolean"?le.target instanceof HTMLElement&&d.isDocumentElement(le.target)&&L.props.onMenuClose():typeof L.props.closeMenuOnScroll=="function"&&L.props.closeMenuOnScroll(le)&&L.props.onMenuClose()},L.onCompositionStart=function(){L.isComposing=!0},L.onCompositionEnd=function(){L.isComposing=!1},L.onTouchStart=function(le){var Pe=le.touches,ze=Pe&&Pe.item(0);ze&&(L.initialTouchX=ze.clientX,L.initialTouchY=ze.clientY,L.userIsDragging=!1)},L.onTouchMove=function(le){var Pe=le.touches,ze=Pe&&Pe.item(0);if(ze){var at=Math.abs(ze.clientX-L.initialTouchX),Ot=Math.abs(ze.clientY-L.initialTouchY),Ct=5;L.userIsDragging=at>Ct||Ot>Ct}},L.onTouchEnd=function(le){L.userIsDragging||(L.controlRef&&!L.controlRef.contains(le.target)&&L.menuListRef&&!L.menuListRef.contains(le.target)&&L.blurInput(),L.initialTouchX=0,L.initialTouchY=0)},L.onControlTouchEnd=function(le){L.userIsDragging||L.onControlMouseDown(le)},L.onClearIndicatorTouchEnd=function(le){L.userIsDragging||L.onClearIndicatorMouseDown(le)},L.onDropdownIndicatorTouchEnd=function(le){L.userIsDragging||L.onDropdownIndicatorMouseDown(le)},L.handleInputChange=function(le){var Pe=L.props.inputValue,ze=le.currentTarget.value;L.setState({inputIsHiddenAfterUpdate:!1}),L.onInputChange(ze,{action:"input-change",prevInputValue:Pe}),L.props.menuIsOpen||L.onMenuOpen()},L.onInputFocus=function(le){L.props.onFocus&&L.props.onFocus(le),L.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(L.openAfterFocus||L.props.openMenuOnFocus)&&L.openMenu("first"),L.openAfterFocus=!1},L.onInputBlur=function(le){var Pe=L.props.inputValue;if(L.menuListRef&&L.menuListRef.contains(document.activeElement)){L.inputRef.focus();return}L.props.onBlur&&L.props.onBlur(le),L.onInputChange("",{action:"input-blur",prevInputValue:Pe}),L.onMenuClose(),L.setState({focusedValue:null,isFocused:!1})},L.onOptionHover=function(le){if(!(L.blockOptionHover||L.state.focusedOption===le)){var Pe=L.getFocusableOptions(),ze=Pe.indexOf(le);L.setState({focusedOption:le,focusedOptionId:ze>-1?L.getFocusedOptionId(le):null})}},L.shouldHideSelectedOptions=function(){return Ue(L.props)},L.onValueInputFocus=function(le){le.preventDefault(),le.stopPropagation(),L.focus()},L.onKeyDown=function(le){var Pe=L.props,ze=Pe.isMulti,at=Pe.backspaceRemovesValue,Ot=Pe.escapeClearsValue,Ct=Pe.inputValue,jt=Pe.isClearable,ft=Pe.isDisabled,ut=Pe.menuIsOpen,tn=Pe.onKeyDown,mn=Pe.tabSelectsValue,wn=Pe.openMenuOnFocus,Sn=L.state,yn=Sn.focusedOption,Jn=Sn.focusedValue,$n=Sn.selectValue;if(!ft&&!(typeof tn=="function"&&(tn(le),le.defaultPrevented))){switch(L.blockOptionHover=!0,le.key){case"ArrowLeft":if(!ze||Ct)return;L.focusValue("previous");break;case"ArrowRight":if(!ze||Ct)return;L.focusValue("next");break;case"Delete":case"Backspace":if(Ct)return;if(Jn)L.removeValue(Jn);else{if(!at)return;ze?L.popValue():jt&&L.clearValue()}break;case"Tab":if(L.isComposing||le.shiftKey||!ut||!mn||!yn||wn&&L.isOptionSelected(yn,$n))return;L.selectOption(yn);break;case"Enter":if(le.keyCode===229)break;if(ut){if(!yn||L.isComposing)return;L.selectOption(yn);break}return;case"Escape":ut?(L.setState({inputIsHiddenAfterUpdate:!1}),L.onInputChange("",{action:"menu-close",prevInputValue:Ct}),L.onMenuClose()):jt&&Ot&&L.clearValue();break;case" ":if(Ct)return;if(!ut){L.openMenu("first");break}if(!yn)return;L.selectOption(yn);break;case"ArrowUp":ut?L.focusOption("up"):L.openMenu("last");break;case"ArrowDown":ut?L.focusOption("down"):L.openMenu("first");break;case"PageUp":if(!ut)return;L.focusOption("pageup");break;case"PageDown":if(!ut)return;L.focusOption("pagedown");break;case"Home":if(!ut)return;L.focusOption("first");break;case"End":if(!ut)return;L.focusOption("last");break;default:return}le.preventDefault()}},L.state.instancePrefix="react-select-"+(L.props.instanceId||++ct),L.state.selectValue=d.cleanValue(Fe.value),Fe.menuIsOpen&&L.state.selectValue.length){var Te=L.getFocusableOptionsWithIds(),Qe=L.buildFocusableOptions(),tt=Qe.indexOf(L.state.selectValue[0]);L.state.focusableOptionsWithIds=Te,L.state.focusedOption=Qe[tt],L.state.focusedOptionId=xt(Te,Qe[tt])}return L}return r(qe,[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&d.scrollIntoView(this.menuListRef,this.focusedOptionRef),Be()&&this.setState({isAppleDevice:!0})}},{key:"componentDidUpdate",value:function(L){var Te=this.props,Qe=Te.isDisabled,tt=Te.menuIsOpen,le=this.state.isFocused;(le&&!Qe&&L.isDisabled||le&&tt&&!L.menuIsOpen)&&this.focusInput(),le&&Qe&&!L.isDisabled?this.setState({isFocused:!1},this.onMenuClose):!le&&!Qe&&L.isDisabled&&this.inputRef===document.activeElement&&this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(d.scrollIntoView(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(L,Te){this.props.onInputChange(L,Te)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(L){var Te=this,Qe=this.state,tt=Qe.selectValue,le=Qe.isFocused,Pe=this.buildFocusableOptions(),ze=L==="first"?0:Pe.length-1;if(!this.props.isMulti){var at=Pe.indexOf(tt[0]);at>-1&&(ze=at)}this.scrollToFocusedOptionOnUpdate=!(le&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:Pe[ze],focusedOptionId:this.getFocusedOptionId(Pe[ze])},function(){return Te.onMenuOpen()})}},{key:"focusValue",value:function(L){var Te=this.state,Qe=Te.selectValue,tt=Te.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var le=Qe.indexOf(tt);tt||(le=-1);var Pe=Qe.length-1,ze=-1;if(Qe.length){switch(L){case"previous":le===0?ze=0:le===-1?ze=Pe:ze=le-1;break;case"next":le>-1&&le<Pe&&(ze=le+1);break}this.setState({inputIsHidden:ze!==-1,focusedValue:Qe[ze]})}}}},{key:"focusOption",value:function(){var L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"first",Te=this.props.pageSize,Qe=this.state.focusedOption,tt=this.getFocusableOptions();if(tt.length){var le=0,Pe=tt.indexOf(Qe);Qe||(Pe=-1),L==="up"?le=Pe>0?Pe-1:tt.length-1:L==="down"?le=(Pe+1)%tt.length:L==="pageup"?(le=Pe-Te,le<0&&(le=0)):L==="pagedown"?(le=Pe+Te,le>tt.length-1&&(le=tt.length-1)):L==="last"&&(le=tt.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:tt[le],focusedValue:null,focusedOptionId:this.getFocusedOptionId(tt[le])})}}},{key:"getTheme",value:function(){return this.props.theme?typeof this.props.theme=="function"?this.props.theme(ne):t(t({},ne),this.props.theme):ne}},{key:"getCommonProps",value:function(){var L=this.clearValue,Te=this.cx,Qe=this.getStyles,tt=this.getClassNames,le=this.getValue,Pe=this.selectOption,ze=this.setValue,at=this.props,Ot=at.isMulti,Ct=at.isRtl,jt=at.options,ft=this.hasValue();return{clearValue:L,cx:Te,getStyles:Qe,getClassNames:tt,getValue:le,hasValue:ft,isMulti:Ot,isRtl:Ct,options:jt,selectOption:Pe,selectProps:at,setValue:ze,theme:this.getTheme()}}},{key:"hasValue",value:function(){var L=this.state.selectValue;return L.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var L=this.props,Te=L.isClearable,Qe=L.isMulti;return Te===void 0?Qe:Te}},{key:"isOptionDisabled",value:function(L,Te){return yt(this.props,L,Te)}},{key:"isOptionSelected",value:function(L,Te){return kt(this.props,L,Te)}},{key:"filterOption",value:function(L,Te){return en(this.props,L,Te)}},{key:"formatOptionLabel",value:function(L,Te){if(typeof this.props.formatOptionLabel=="function"){var Qe=this.props.inputValue,tt=this.state.selectValue;return this.props.formatOptionLabel(L,{context:Te,inputValue:Qe,selectValue:tt})}else return this.getOptionLabel(L)}},{key:"formatGroupLabel",value:function(L){return this.props.formatGroupLabel(L)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var L=this.props,Te=L.isDisabled,Qe=L.isSearchable,tt=L.inputId,le=L.inputValue,Pe=L.tabIndex,ze=L.form,at=L.menuIsOpen,Ot=L.required,Ct=this.getComponents(),jt=Ct.Input,ft=this.state,ut=ft.inputIsHidden,tn=ft.ariaSelection,mn=this.commonProps,wn=tt||this.getElementId("input"),Sn=t(t(t({"aria-autocomplete":"list","aria-expanded":at,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":Ot,role:"combobox","aria-activedescendant":this.state.isAppleDevice?void 0:this.state.focusedOptionId||""},at&&{"aria-controls":this.getElementId("listbox")}),!Qe&&{"aria-readonly":!0}),this.hasValue()?tn?.action==="initial-input-focus"&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return Qe?A.createElement(jt,e({},mn,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:wn,innerRef:this.getInputRef,isDisabled:Te,isHidden:ut,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:Pe,form:ze,type:"text",value:le},Sn)):A.createElement(ae,e({id:wn,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:d.noop,onFocus:this.onInputFocus,disabled:Te,tabIndex:Pe,inputMode:"none",form:ze,value:""},Sn))}},{key:"renderPlaceholderOrValue",value:function(){var L=this,Te=this.getComponents(),Qe=Te.MultiValue,tt=Te.MultiValueContainer,le=Te.MultiValueLabel,Pe=Te.MultiValueRemove,ze=Te.SingleValue,at=Te.Placeholder,Ot=this.commonProps,Ct=this.props,jt=Ct.controlShouldRenderValue,ft=Ct.isDisabled,ut=Ct.isMulti,tn=Ct.inputValue,mn=Ct.placeholder,wn=this.state,Sn=wn.selectValue,yn=wn.focusedValue,Jn=wn.isFocused;if(!this.hasValue()||!jt)return tn?null:A.createElement(at,e({},Ot,{key:"placeholder",isDisabled:ft,isFocused:Jn,innerProps:{id:this.getElementId("placeholder")}}),mn);if(ut)return Sn.map(function(an,ar){var Rr=an===yn,ei="".concat(L.getOptionLabel(an),"-").concat(L.getOptionValue(an));return A.createElement(Qe,e({},Ot,{components:{Container:tt,Label:le,Remove:Pe},isFocused:Rr,isDisabled:ft,key:ei,index:ar,removeProps:{onClick:function(){return L.removeValue(an)},onTouchEnd:function(){return L.removeValue(an)},onMouseDown:function(er){er.preventDefault()}},data:an}),L.formatOptionLabel(an,"value"))});if(tn)return null;var $n=Sn[0];return A.createElement(ze,e({},Ot,{data:$n,isDisabled:ft}),this.formatOptionLabel($n,"value"))}},{key:"renderClearIndicator",value:function(){var L=this.getComponents(),Te=L.ClearIndicator,Qe=this.commonProps,tt=this.props,le=tt.isDisabled,Pe=tt.isLoading,ze=this.state.isFocused;if(!this.isClearable()||!Te||le||!this.hasValue()||Pe)return null;var at={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return A.createElement(Te,e({},Qe,{innerProps:at,isFocused:ze}))}},{key:"renderLoadingIndicator",value:function(){var L=this.getComponents(),Te=L.LoadingIndicator,Qe=this.commonProps,tt=this.props,le=tt.isDisabled,Pe=tt.isLoading,ze=this.state.isFocused;if(!Te||!Pe)return null;var at={"aria-hidden":"true"};return A.createElement(Te,e({},Qe,{innerProps:at,isDisabled:le,isFocused:ze}))}},{key:"renderIndicatorSeparator",value:function(){var L=this.getComponents(),Te=L.DropdownIndicator,Qe=L.IndicatorSeparator;if(!Te||!Qe)return null;var tt=this.commonProps,le=this.props.isDisabled,Pe=this.state.isFocused;return A.createElement(Qe,e({},tt,{isDisabled:le,isFocused:Pe}))}},{key:"renderDropdownIndicator",value:function(){var L=this.getComponents(),Te=L.DropdownIndicator;if(!Te)return null;var Qe=this.commonProps,tt=this.props.isDisabled,le=this.state.isFocused,Pe={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return A.createElement(Te,e({},Qe,{innerProps:Pe,isDisabled:tt,isFocused:le}))}},{key:"renderMenu",value:function(){var L=this,Te=this.getComponents(),Qe=Te.Group,tt=Te.GroupHeading,le=Te.Menu,Pe=Te.MenuList,ze=Te.MenuPortal,at=Te.LoadingMessage,Ot=Te.NoOptionsMessage,Ct=Te.Option,jt=this.commonProps,ft=this.state.focusedOption,ut=this.props,tn=ut.captureMenuScroll,mn=ut.inputValue,wn=ut.isLoading,Sn=ut.loadingMessage,yn=ut.minMenuHeight,Jn=ut.maxMenuHeight,$n=ut.menuIsOpen,an=ut.menuPlacement,ar=ut.menuPosition,Rr=ut.menuPortalTarget,ei=ut.menuShouldBlockScroll,Qr=ut.menuShouldScrollIntoView,er=ut.noOptionsMessage,_i=ut.onMenuScrollToTop,br=ut.onMenuScrollToBottom;if(!$n)return null;var Ce=function(St,_t){var An=St.type,On=St.data,Mn=St.isDisabled,tr=St.isSelected,Hr=St.label,ti=St.value,Vr=ft===On,vi=Mn?void 0:function(){return L.onOptionHover(On)},En=Mn?void 0:function(){return L.selectOption(On)},Yr="".concat(L.getElementId("option"),"-").concat(_t),yr={id:Yr,onClick:En,onMouseMove:vi,onMouseOver:vi,tabIndex:-1,role:"option","aria-selected":L.state.isAppleDevice?void 0:tr};return A.createElement(Ct,e({},jt,{innerProps:yr,data:On,isDisabled:Mn,isSelected:tr,key:Yr,label:Hr,type:An,value:ti,isFocused:Vr,innerRef:Vr?L.getFocusedOptionRef:void 0}),L.formatOptionLabel(St.data,"menu"))},W;if(this.hasOptions())W=this.getCategorizedOptions().map(function(Ze){if(Ze.type==="group"){var St=Ze.data,_t=Ze.options,An=Ze.index,On="".concat(L.getElementId("group"),"-").concat(An),Mn="".concat(On,"-heading");return A.createElement(Qe,e({},jt,{key:On,data:St,options:_t,Heading:tt,headingProps:{id:Mn,data:Ze.data},label:L.formatGroupLabel(Ze.data)}),Ze.options.map(function(tr){return Ce(tr,"".concat(An,"-").concat(tr.index))}))}else if(Ze.type==="option")return Ce(Ze,"".concat(Ze.index))});else if(wn){var Oe=Sn({inputValue:mn});if(Oe===null)return null;W=A.createElement(at,jt,Oe)}else{var Ee=er({inputValue:mn});if(Ee===null)return null;W=A.createElement(Ot,jt,Ee)}var _e={minMenuHeight:yn,maxMenuHeight:Jn,menuPlacement:an,menuPosition:ar,menuShouldScrollIntoView:Qr},rt=A.createElement(d.MenuPlacer,e({},jt,_e),function(Ze){var St=Ze.ref,_t=Ze.placerProps,An=_t.placement,On=_t.maxHeight;return A.createElement(le,e({},jt,_e,{innerRef:St,innerProps:{onMouseDown:L.onMenuMouseDown,onMouseMove:L.onMenuMouseMove},isLoading:wn,placement:An}),A.createElement(ce,{captureEnabled:tn,onTopArrive:_i,onBottomArrive:br,lockEnabled:ei},function(Mn){return A.createElement(Pe,e({},jt,{innerRef:function(Hr){L.getMenuListRef(Hr),Mn(Hr)},innerProps:{role:"listbox","aria-multiselectable":jt.isMulti,id:L.getElementId("listbox")},isLoading:wn,maxHeight:On,focusedOption:ft}),W)}))});return Rr||ar==="fixed"?A.createElement(ze,e({},jt,{appendTo:Rr,controlElement:this.controlRef,menuPlacement:an,menuPosition:ar}),rt):rt}},{key:"renderFormField",value:function(){var L=this,Te=this.props,Qe=Te.delimiter,tt=Te.isDisabled,le=Te.isMulti,Pe=Te.name,ze=Te.required,at=this.state.selectValue;if(ze&&!this.hasValue()&&!tt)return A.createElement(ke,{name:Pe,onFocus:this.onValueInputFocus});if(!(!Pe||tt))if(le)if(Qe){var Ot=at.map(function(ft){return L.getOptionValue(ft)}).join(Qe);return A.createElement("input",{name:Pe,type:"hidden",value:Ot})}else{var Ct=at.length>0?at.map(function(ft,ut){return A.createElement("input",{key:"i-".concat(ut),name:Pe,type:"hidden",value:L.getOptionValue(ft)})}):A.createElement("input",{name:Pe,type:"hidden",value:""});return A.createElement("div",null,Ct)}else{var jt=at[0]?this.getOptionValue(at[0]):"";return A.createElement("input",{name:Pe,type:"hidden",value:jt})}}},{key:"renderLiveRegion",value:function(){var L=this.commonProps,Te=this.state,Qe=Te.ariaSelection,tt=Te.focusedOption,le=Te.focusedValue,Pe=Te.isFocused,ze=Te.selectValue,at=this.getFocusableOptions();return A.createElement(E,e({},L,{id:this.getElementId("live-region"),ariaSelection:Qe,focusedOption:tt,focusedValue:le,isFocused:Pe,selectValue:ze,focusableOptions:at,isAppleDevice:this.state.isAppleDevice}))}},{key:"render",value:function(){var L=this.getComponents(),Te=L.Control,Qe=L.IndicatorsContainer,tt=L.SelectContainer,le=L.ValueContainer,Pe=this.props,ze=Pe.className,at=Pe.id,Ot=Pe.isDisabled,Ct=Pe.menuIsOpen,jt=this.state.isFocused,ft=this.commonProps=this.getCommonProps();return A.createElement(tt,e({},ft,{className:ze,innerProps:{id:at,onKeyDown:this.onKeyDown},isDisabled:Ot,isFocused:jt}),this.renderLiveRegion(),A.createElement(Te,e({},ft,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:Ot,isFocused:jt,menuIsOpen:Ct}),A.createElement(le,e({},ft,{isDisabled:Ot}),this.renderPlaceholderOrValue(),this.renderInput()),A.createElement(Qe,e({},ft,{isDisabled:Ot}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}],[{key:"getDerivedStateFromProps",value:function(L,Te){var Qe=Te.prevProps,tt=Te.clearFocusValueOnUpdate,le=Te.inputIsHiddenAfterUpdate,Pe=Te.ariaSelection,ze=Te.isFocused,at=Te.prevWasFocused,Ot=Te.instancePrefix,Ct=L.options,jt=L.value,ft=L.menuIsOpen,ut=L.inputValue,tn=L.isMulti,mn=d.cleanValue(jt),wn={};if(Qe&&(jt!==Qe.value||Ct!==Qe.options||ft!==Qe.menuIsOpen||ut!==Qe.inputValue)){var Sn=ft?mt(L,mn):[],yn=ft?et(Ve(L,mn),"".concat(Ot,"-option")):[],Jn=tt?vt(Te,mn):null,$n=Ft(Te,Sn),an=xt(yn,$n);wn={selectValue:mn,focusedOption:$n,focusedOptionId:an,focusableOptionsWithIds:yn,focusedValue:Jn,clearFocusValueOnUpdate:!1}}var ar=le!=null&&L!==Qe?{inputIsHidden:le,inputIsHiddenAfterUpdate:void 0}:{},Rr=Pe,ei=ze&&at;return ze&&!ei&&(Rr={value:d.valueTernary(tn,mn,mn[0]||null),options:mn,action:"initial-input-focus"},ei=!at),Pe?.action==="initial-input-focus"&&(Rr=null),t(t(t({},wn),ar),{},{prevProps:L,ariaSelection:Rr,prevWasFocused:ei})}}]),qe}(u.Component);return gt.defaultProps=xe,Ls.Select=gt,Ls.createFilter=q,Ls.defaultProps=xe,Ls.defaultTheme=ne,Ls.getOptionLabel=pt,Ls.getOptionValue=dt,Ls.mergeStyles=Nt,Ls}var jL;function Bme(){return jL||(jL=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=vme(),n=Rm(),r=hn(),i=Nme(),s=I0(),l=Cm(),u=gz();rb(),xI(),ib(),uz(),cz(),dz(),fz(),hz(),km(),mz(),AI(),h0(),pz();function d(w){return w&&w.__esModule?w:{default:w}}function m(w){if(w&&w.__esModule)return w;var S=Object.create(null);return w&&Object.keys(w).forEach(function(C){if(C!=="default"){var M=Object.getOwnPropertyDescriptor(w,C);Object.defineProperty(S,C,M.get?M:{enumerable:!0,get:function(){return w[C]}})}}),S.default=w,Object.freeze(S)}var v=m(r),g=d(l),y=r.forwardRef(function(w,S){var C=t.useStateManager(w);return v.createElement(i.Select,n({ref:S},C))}),b=y,A=function(w){var S=w.nonce,C=w.children,M=w.cacheKey,P=r.useMemo(function(){return g.default({key:M,nonce:S})},[M,S]);return v.createElement(s.CacheProvider,{value:P},C)};e.useStateManager=t.useStateManager,e.createFilter=i.createFilter,e.defaultTheme=i.defaultTheme,e.mergeStyles=i.mergeStyles,e.components=u.components,e.NonceProvider=A,e.default=b}(dC)),dC}var NL;function Lme(){return NL||(NL=1,cC.exports=Bme()),cC.exports}var zC={},BL;function Fme(){return BL||(BL=1,zC._default=Lme().default),zC}var LL=Fme();const vz=D0(e=>({data:[],addObject:t=>e(n=>({data:[...n.data,t]})),updateObject:(t,n)=>e(r=>({data:r.data.map((i,s)=>s===t?{...i,...n}:i)})),removeObject:t=>e(n=>({data:n.data.filter((r,i)=>i!==t)})),toggleRelationship:t=>e(n=>({data:n.data.map((r,i)=>i===t?{...r,addRelationship:!r.addRelationship}:r)})),addNestedEmail:(t,n)=>e(r=>({data:r.data.map((i,s)=>s===t?{...i,emails:[...i.emails||[],n]}:i)})),updateNestedEmail:(t,n,r)=>e(i=>({data:i.data.map((s,l)=>l===t?{...s,emails:s.emails?.map((u,d)=>d===n?{...u,...r}:u)}:s)})),removeNestedEmail:(t,n)=>e(r=>({data:r.data.map((i,s)=>s===t?{...i,emails:i.emails?.filter((l,u)=>u!==n)}:i)}))})),kme=({emails:e})=>{const{data:t,addObject:n,removeObject:r,toggleRelationship:i,addNestedEmail:s,removeNestedEmail:l}=vz(),[u,d]=j.useState(!1),[m,v]=j.useState(!1),[g,y]=j.useState(!1),[b,A]=j.useState(""),w=b&&(m||g),S=P=>new RegExp("^(?![_.-])[A-Za-z0-9._%+-]+(?<![_.-])@(?:(?!-)[A-Za-z0-9-]{1,63}(?<!-)\\.)+[A-Za-z]{2,}$").test(P)?!0:(Xe.error("Please enter a valid email address"),!1),C=()=>{const P=b;if(!P){Xe.error("Please chooose sender or receipt");return}if(!S(P))return;if(!m&&!g)return Xe.error("Please chooose sender or receipt"),!1;if(t.find(D=>D.email==P&&D.type==(m?"from":"to")))return Xe.error("Email already exists");let E="to";m&&g?E="all":m&&(E="from"),n({email:P,type:E}),A(""),v(!1),y(!1),d(!1)},M=(P,_)=>{const E=b;if(!E){Xe.error("Please chooose sender or receipt");return}S(E)&&(s(P,{email:E,type:_.type=="from"?"to":"from"}),i(P),A(""))};return h.jsxs(h.Fragment,{children:[t.length>0?t.map((P,_)=>h.jsxs("div",{className:"mb-1 py-3 border-t border-light-gray",children:[h.jsxs("div",{className:"flex justify-between",children:[h.jsxs("div",{className:"text-[#475467]",children:[h.jsx("strong",{className:"capitalize",children:P.type}),":"," ",P.email]}),h.jsx("a",{className:"text-[#C13B2D] cursor-pointer",onClick:E=>{E.stopPropagation(),r(_)},children:"Remove"})]}),P.emails&&P.emails.length>0?P.emails.map((E,D)=>h.jsx("div",{children:h.jsxs("div",{className:"flex justify-between ps-10 mt-3",children:[h.jsxs("div",{className:"text-[#475467]",children:[h.jsx(we,{icon:X3,style:{transform:"scaleX(-1)"}}),h.jsx("strong",{className:"capitalize",children:E.type}),":"," ",E.email]}),h.jsx("a",{className:"text-[#C13B2D] cursor-pointer",onClick:O=>{O.stopPropagation(),l(_,D)},children:"Remove"})]})})):null,P.addRelationship?h.jsxs("div",{className:"flex mt-2 ps-10",children:[h.jsx(LL._default,{isSearchable:!0,isClearable:!0,options:e?.map(E=>({label:E,value:E}))||[],onChange:E=>A(E?.label),value:{label:b,value:b},closeMenuOnSelect:!0,styles:{container:E=>({...E,flexGrow:1,heigt:40}),control:E=>({...E,minHeight:"40px",cursor:"pointer",borderTopRightRadius:0,borderBottomRightRadius:0})},components:{DropdownIndicator:null}}),h.jsx("button",{className:"btn-lightblue uppercase cursor-pointer bg-my-archive rounded-r",onClick:()=>M(_,P),children:"Add"})]}):null,P.type!=="all"&&h.jsx("div",{className:"text-end",children:h.jsxs("a",{className:"text-my-archive mt-1 block cursor-pointer",onClick:()=>i(_),children:[h.jsx(we,{icon:X3,style:{transform:"scaleX(-1)"}}),"Add relationship"]})})]},_)):null,u?h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex",children:[h.jsx(LL._default,{isSearchable:!0,isClearable:!0,options:e?.map(P=>({label:P,value:P}))||[],onChange:P=>A(P?.label),value:{label:b,value:b},closeMenuOnSelect:!0,styles:{container:P=>({...P,flexGrow:1,heigt:40}),control:P=>({...P,minHeight:"40px",cursor:"pointer",borderTopRightRadius:0,borderBottomRightRadius:0})},components:{DropdownIndicator:null}}),h.jsx("button",{className:"btn-lightblue uppercase cursor-pointer bg-my-archive rounded-r disabled:bg-gray-400 disabled:cursor-not-allowed",disabled:!w,onClick:C,children:"Add"})]}),h.jsxs("div",{className:"flex gap-4 mt-2",children:[h.jsx("div",{children:h.jsxs("label",{className:"flex gap-2",htmlFor:"email_sender",children:[h.jsx("input",{type:"checkbox",id:"email_sender",checked:m,onChange:P=>v(P.target.checked)}),"Sender"]})}),h.jsx("div",{children:h.jsxs("label",{className:"flex gap-2",htmlFor:"email_recipient",children:[h.jsx("input",{checked:g,type:"checkbox",id:"email_recipient",onChange:P=>y(P.target.checked)}),"Recipient"]})})]})]}):h.jsxs("div",{className:"flex items-center cursor-pointer",onClick:()=>d(!0),children:[h.jsx(we,{icon:Kn,className:"me-1"}),"Add sender or receipient"]})]})},Js=D0((e,t,n)=>({days:{startDate:new Date,endDate:new Date,key:"selection"},activeChoice:"last_30_days",emailAddresses:[],emailAttachments:!1,emailContents:"",emailKeywords:[],emailSubject:"",emailReviewStatus:{},relationalEmailAddresses:[],contents:"",keywords:[],platforms:[],publishers:[],reviewStatus:{},updateField:(r,i)=>e({[r]:i}),setActiveChoice:r=>e({activeChoice:r}),setDays:r=>e({days:r}),resetState:()=>e(n.getInitialState())})),qme=({settings:e})=>{const[t,n]=j.useState(!1),[r,i]=j.useState(!1),[s,l]=j.useState(!1),[u,d]=j.useState(!1),[m,v]=j.useState(!1),{updateField:g,emailContents:y,emailKeywords:b,emailSubject:A,emailReviewStatus:w}=Js(S=>S);return h.jsxs("div",{className:"email-filters-wrapper",children:[h.jsxs("div",{className:"mt-10",children:[h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Email Addresses"}),h.jsx(kme,{emails:e?.searchEmails})]}),h.jsx("div",{className:"mt-10",children:m&&h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{v(!m),g("emailSubject","")},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Email Subject"})]}),h.jsx("textarea",{onChange:S=>g("emailSubject",S.currentTarget.value),value:A,className:"text-sm outline-none py-3 px-5 border rounded border-[#DEE2E6] w-full h-[100px]",placeholder:"Enter text..."})]})}),h.jsx("div",{className:"mt-10",children:t&&h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{n(!n),g("emailContents","")},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Email Contents"})]}),h.jsx("textarea",{value:y,onChange:S=>g("emailContents",S.currentTarget.value),className:"text-sm outline-none py-3 px-5 border rounded border-[#DEE2E6] w-full h-[100px]",placeholder:"Enter text..."})]})}),r&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{i(!r),g("emailReviewStatus",{})},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Review Status"})]}),h.jsxs("label",{className:"flex items-center my-2",htmlFor:"reviewed_check",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"reviewed_check",checked:w.is_reviewed==="true",onChange:S=>{g("emailReviewStatus",{...w,is_reviewed:S.currentTarget.checked.toString()})}}),"Reviewed"]}),h.jsxs("label",{className:"flex items-center my-2",htmlFor:"reviewed_flagged",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"reviewed_flagged",checked:w.is_further_review==="true",onChange:S=>{g("emailReviewStatus",{...w,is_further_review:S.currentTarget.checked.toString()})}}),"Flagged For Further Review"]})]})}),s&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>l(!s),color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Keywords"})]}),h.jsx(AR,{allLabel:"All Keywords",placeholder:"Select Keywords",selectionLabel:"Keyword",selectedOptions:b.map(S=>({value:S,label:S})),setSelectedOptions:S=>g("emailKeywords",S.map(C=>C.label)),options:e?.keywords?.map(S=>({value:S,label:S}))||[]})]})}),u&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{d(!u),g("emailContents","")},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Attachments"})]}),h.jsxs("label",{className:"flex items-center",htmlFor:"email_attachments_check",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"email_attachments_check",onChange:S=>{g("emailAttachments",S.currentTarget.checked)}}),"Email includes attachment(s)"]})]})}),h.jsxs("div",{className:"mt-10 mb-20",children:[h.jsx("p",{className:"text-[#B5B3B3] border-b border-[#B5B3B3]",children:"Refine Your Search"}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>v(!m),children:[h.jsx("span",{children:m?"-":"+"})," Email Subject"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>n(!t),children:[h.jsx("span",{children:t?"-":"+"})," Email Contents"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>i(!r),children:[h.jsx("span",{children:r?"-":"+"})," Review Status"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>l(!s),children:[h.jsx("span",{children:s?"-":"+"})," Keywords"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>d(!u),children:[h.jsx("span",{children:u?"-":"+"})," Attachments"]})]})]})},zme=({settings:e})=>{const{updateField:t,contents:n,keywords:r,platforms:i,reviewStatus:s}=Js(),[l,u]=j.useState(!1),[d,m]=j.useState(!1),[v,g]=j.useState(!1),[y,b]=j.useState(!1),[A,w]=j.useState(!1),[S,C]=j.useState([]),M=j.useMemo(()=>{const P=e?.publishers?.map((_,E)=>({value:_.toString(),label:e.publishedBy?.at(E)||""}))||[];return[{label:"Firm Account",value:"0"},...P]},[e?.publishers,e?.publishedBy]);return h.jsxs("div",{className:"email-filters-wrapper",children:[h.jsx("div",{className:"mt-10",children:v&&h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{C([]),g(!v)},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Published By"})]}),h.jsx("p",{className:"my-3",children:"Include entries published by these users"}),h.jsx(AR,{allLabel:"All Users",placeholder:"Select Users",selectionLabel:"User",selectedOptions:S,setSelectedOptions:P=>{C(P),t("publishers",P.map(_=>parseInt(_.value)))},options:M})]})}),h.jsx("div",{className:"mt-10",children:A&&h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{t("contents",""),w(!A)},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Post Contents"})]}),h.jsx("textarea",{value:n,className:"text-sm outline-none py-3 px-5 border rounded border-[#DEE2E6] w-full h-[100px]",placeholder:"Enter text...",onChange:P=>t("contents",P.currentTarget.value)})]})}),y&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{t("platforms",[]),b(!y)},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Platform"})]}),e?.platforms?.map((P,_)=>h.jsxs("label",{className:"flex items-center my-2",children:[h.jsx("input",{type:"checkbox",className:"me-2",checked:i.includes(P),onChange:E=>{const D=E.currentTarget.checked?[...i,P]:i.filter(O=>O!==P);t("platforms",D)}}),e.accountTypes?.at(_)]},P))]})}),d&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>{t("keywords",[]),m(!d)},color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Keywords"})]}),h.jsx(AR,{allLabel:"All Keywords",placeholder:"Select Keywords",selectionLabel:"Keyword",selectedOptions:r.map(P=>({label:P,value:P})),setSelectedOptions:P=>{t("keywords",P.map(_=>_.value))},options:e?.keywords?.map(P=>({label:P,value:P}))||[]})]})}),l&&h.jsx(h.Fragment,{children:h.jsxs("div",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center",children:[h.jsx(we,{className:"me-2 mt-[-12px] cursor-pointer",icon:ga,onClick:()=>u(!l),color:"red"}),h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle !mb-3",children:"Review Status"})]}),h.jsxs("label",{className:"flex items-center my-2",htmlFor:"reviewed_check",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"reviewed_check",checked:s.is_reviewed==="true",onChange:P=>{t("reviewStatus",{...s,is_reviewed:P.currentTarget.checked.toString()})}}),"Reviewed"]}),h.jsxs("label",{className:"flex items-center my-2",htmlFor:"reviewed_flagged",children:[h.jsx("input",{type:"checkbox",className:"me-2",id:"reviewed_flagged",checked:s.is_further_review==="true",onChange:P=>{t("reviewStatus",{...s,is_further_review:P.currentTarget.checked.toString()})}}),"Flagged For Further Review"]})]})}),h.jsxs("div",{className:"mt-10 mb-20",children:[h.jsx("p",{className:"text-[#B5B3B3] border-b border-[#B5B3B3]",children:"Refine Your Search"}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{C([]),g(!v)},children:[h.jsx("span",{children:v?"-":"+"})," Published By"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{t("contents",""),w(!A)},children:[h.jsx("span",{children:A?"-":"+"})," Post Contents"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{t("platforms",[]),b(!y)},children:[h.jsx("span",{children:y?"-":"+"})," Platform"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{t("keywords",[]),m(!d)},children:[h.jsx("span",{children:d?"-":"+"})," Keywords"]}),h.jsxs("p",{className:"text-[#B5B3B3] font-semibold mt-2 cursor-pointer",onClick:()=>{t("reviewStatus",{}),u(!l)},children:[h.jsx("span",{children:l?"-":"+"})," Review Status"]})]})]})},ki=D0(e=>({emails:[],posts:[],emailMap:{},postMap:{},searchId:"",totalResults:0,setEmails:(t,n,r)=>e(i=>{const s=t.reduce((l,u)=>(l[u.id]=u,l),i.emailMap);return{emails:t,emailMap:s,totalResults:n,posts:[],postMap:{},searchId:r}}),setPosts:(t,n,r)=>e(i=>{const s=t.reduce((l,u)=>(l[u.id]=u,l),i.postMap);return{posts:t,postMap:s,totalResults:n,emails:[],emailMap:{},searchId:r}})})),bz=(e=0,t=12)=>({queryKey:["myArchiveFolders",e,t],queryFn:()=>{const n=new URLSearchParams;return n.set("PageNumber",String(e)),n.set("PageSize",String(t)),bt.executeRequest(`/AdvancedSearch?${n.toString()}`,"GET")}}),yz=()=>{const e=Js(u=>u),t=vz(u=>u.data),n=j.useMemo(()=>t.reduce((u,d)=>{const m=[{item:d.email,itemType:d.type}];return d.emails&&d.emails.forEach(v=>m.push({item:v.email,itemType:v.type})),u.push(m),u},[]),[t]),{startDate:r,endDate:i}=wI(e.activeChoice,e.days),s=kr(),l=ki(u=>u.setEmails);return Tt({mutationFn:({pageNumber:u=0})=>bt.executeRequest("/Archiving/advanced_email_search","POST",{emailDateStart:r,emailDateEnd:i,relationalEmailAddresses:n,emailAttachments:!1,emailKeywords:e.emailKeywords,emailContents:e.emailContents,emailReviewStatus:e.emailReviewStatus,emailSubject:e.emailSubject,pageNumber:u}),onSuccess:u=>{u.success?(l(u.searchResults||[],u.totalResults,u.searchId),s({to:"/my-archive/results"})):Xe.error(u.errorMessage||"Error while searching")}})},Az=()=>{const e=Js(),t=ki(s=>s.setPosts),n=kr(),{startDate:r,endDate:i}=wI(e.activeChoice,e.days);return Tt({mutationFn:({pageNumber:s=0})=>bt.executeRequest("/socialmedia/search","POST",{start:r,end:i,publishers:e.publishers,keywords:e.keywords,contents:e.contents,platforms:e.platforms,reviewStatus:e.reviewStatus,pageNumber:s}),onSuccess:s=>{s.success?(t(s.searchResults||[],s.totalResults,s.searchId),n({to:"/my-archive/results"})):Xe.error(s.errorMessage||"Error while searching")}})},Qme=()=>Gt({queryKey:["myArchiveSettings"],queryFn:()=>bt.executeRequest("/Archiving/advanced_search","GET")}),Hme=()=>{const e=ki(n=>n.postMap),t=ki(n=>n.emailMap);return Tt({mutationFn:({folderId:n,fileIds:r})=>{const i=r.map(l=>{if(e[l])return e[l];if(t[l])return t[l]}).filter(Boolean);let s="email";return Object.keys(e).length>0&&(s="social_media"),bt.executeRequest("/AdvancedSearch/add_items_to_folder","POST",{folderId:n,selectedItems:i.map(l=>({esId:l?.id,s3Path:l?.s3Path,date:l?.date,archivingType:s,socialMediaType:s==="email"?"NULL":l.data.social_media_type}))})}})},Vme=()=>{const e=ki(u=>u.emailMap),t=ki(u=>u.postMap),n=Js(),r=ki(u=>u.searchId),i=ki(u=>u.totalResults),{startDate:s,endDate:l}=wI(n.activeChoice,n.days);return Tt({mutationFn:({folderId:u})=>i>1e3?bt.executeRequest("/AdvancedSearch/select_all_request","POST",{folderId:u,searchId:r}):Object.keys(t).length>0?bt.executeRequest("/socialmedia/selectall","POST",{folderId:u,start:s,end:l,publishers:n.publishers,keywords:n.keywords,contents:n.contents,platforms:n.platforms,reviewStatus:n.reviewStatus,unselectedItems:[]}):Object.keys(e).length>0?bt.executeRequest("/AdvancedSearch/select_all_email_items","POST",{folderId:u,emailDateStart:s,emailDateEnd:l,emailAddresses:n.emailAddresses,relationalEmailAddresses:n.relationalEmailAddresses,emailAttachments:n.emailAttachments,emailKeywords:n.emailKeywords,emailReviewStatus:n.emailReviewStatus,emailSubject:n.emailSubject}):Promise.reject("No archive type supplied")})};function wI(e,t){const n=new Date,r=new Date;switch(e){case"last_30_days":r.setDate(n.getDate()-30);break;case"last_3_months":r.setMonth(n.getMonth()-3);break;case"last_6_months":r.setMonth(n.getMonth()-6);break;default:return{startDate:s0(t.startDate||r).toISOString(),endDate:n_(t.endDate||n).toISOString()}}return{startDate:s0(r).toISOString(),endDate:n_(n).toISOString()}}const Yme=[{id:"last_30_days",title:"Last 30 Days"},{id:"last_3_months",title:"Last 3 Months"},{id:"last_6_months",title:"Last 6 Months"},{id:"custom",title:"Custom"}],Wme=({isOpen:e,setIsOpen:t})=>{const{data:n}=Qme(),r=ki(w=>w.emails),i=ki(w=>w.posts),s=Js(w=>w.activeChoice),l=Js(w=>w.setActiveChoice),u=Js(w=>w.days),d=Js(w=>w.setDays),{mutate:m}=yz(),{mutate:v}=Az(),[g,y]=j.useState("email"),[b,A]=j.useState(!1);return h.jsx("div",{className:`absolute z-10 bg-white shadow-myarchive border-t-24 border-blue-800 h-full ${e?"w-157":"w-12"} transition-all duration-50 rounded-tr-md -mt-[24px]`,children:h.jsxs("div",{className:"flex flex-row h-full",children:[h.jsxs("div",{className:"flex flex-col gap-y-8 bg-blue-800 shrink-0 w-12",children:[h.jsx("button",{onClick:()=>t(!e),className:"py-1 text-white w-full text-center cursor-pointer",children:h.jsx(we,{icon:e?wee:sk,size:"large"})}),r.length>0||i.length>0?h.jsx(qn,{to:"/my-archive/results",className:"py-1 text-white w-full text-center cursor-pointer",children:h.jsx(we,{icon:Z3,size:"large"})}):h.jsx("button",{onClick:()=>t(!e),className:"py-1 text-white w-full text-center cursor-pointer",children:h.jsx(we,{icon:Z3,size:"large"})}),h.jsx(qn,{to:"/my-archive/folders",className:"py-1 text-white w-full text-center cursor-pointer",search:{page:void 0},onClick:()=>{t(!1)},children:h.jsx(we,{icon:dk,size:"large"})})]}),e&&h.jsxs("div",{className:"max-h-300 overflow-scroll p-4",children:[h.jsxs("div",{className:"flex justify-between mb-3 px-4",children:[h.jsxs("div",{className:"flex",children:[h.jsx("span",{onClick:()=>y("email"),className:`p-3 ${g=="email"?"bg-my-archive text-white":"bg-light-gray text-my-archive"} me-2 cursor-pointer`,children:h.jsx(we,{icon:pO,size:"large"})}),h.jsx("span",{onClick:()=>y("social_media"),className:`p-3 ${g=="social_media"?"bg-my-archive text-white":"bg-light-gray text-my-archive"} me-2 cursor-pointer`,children:h.jsx(we,{icon:Cee,size:"large"})})]}),h.jsx("button",{onClick:()=>{g==="email"&&m({},{onSuccess:w=>w.success&&t(!1)}),g==="social_media"&&v({},{onSuccess:w=>w.success&&t(!1)})},className:"btn-lightblue cursor-pointer bg-my-archive rounded",children:"Run Search"})]}),h.jsxs("div",{className:"mt-5 mb-5",children:[h.jsx("h5",{className:"font-semibold myarchive-filter-subtitle mb-3",children:"Date Range"}),h.jsx(ll,{activeChoiceId:s,onChange:w=>{w.id=="custom"&&A(!0),l(w.id)},choices:Yme,mode:"gray"}),b&&h.jsxs(bn,{title:"",width:700,onClose:()=>A(!1),appendTo:null,children:[h.jsx(dme.DateRange,{onChange:w=>d(w.selection),moveRangeOnFirstSelection:!1,months:2,ranges:[u],direction:"horizontal",rangeColors:["#007CC0"],showPreview:!0}),h.jsx("button",{className:"btn-lightblue cursor-pointer bg-my-archive rounded uppercase",onClick:()=>A(!1),children:"done"})]})]}),g=="email"&&h.jsx(qme,{settings:n?.payload.email}),g=="social_media"&&h.jsx(zme,{settings:n?.payload.socialMedia})]})]})})},Ume=()=>{const[e,t]=j.useState(!0);return h.jsxs("div",{className:"flex h-full -ml-6 -mr-5 border-t-24 border-blue-800",children:[h.jsx(Wme,{isOpen:e,setIsOpen:t}),h.jsx("div",{onClick:()=>t(!1),className:"ml-12 w-full",children:h.jsx(mu,{})})]})},ab=({children:e})=>h.jsx("div",{className:"h-12 bg-teal-50 border-b border-b-gray-50",children:e}),Gme=()=>{const e=rn();return Tt({mutationFn:t=>bt.executeRequest("/AdvancedSearch/create_adv_srch_folder","POST",{folderName:t}),onSuccess:()=>{Xe.success("Folder created successfully"),e.invalidateQueries({queryKey:["myArchiveFolders"]})},onError:t=>{Xe.error(t.message)}})},Xme=Md("/my-archive/folders"),Zme=({folder:e})=>h.jsx(qn,{to:"/my-archive/folders/$folder",params:{folder:`${e.id}`},search:{page:0,folderName:e.folderName},state:!0,className:"min-w-62 p-4 bg-white border border-blue-50 shadow-folder cursor-pointer rounded-md",children:h.jsxs("div",{className:"h-10 flex gap-8 items-center",children:[h.jsx("div",{className:"text-blue-500",children:h.jsx(we,{icon:dk,size:"large"})}),h.jsx("div",{className:"text-sm font-bold",children:e.folderName})]})}),Kme=()=>{const e=Xme.useSearch();e.page||(e.page=0);const[t,n]=j.useState(!1),[r,i]=j.useState(""),{data:s,isLoading:l,isSuccess:u}=Gt(bz(e.page)),{mutate:d,isPending:m}=Gme(),v=b=>{i(b.currentTarget.value.trimStart())},g=()=>{d(r.trim(),{onSuccess:()=>{n(!1),i("")}})},y=j.useMemo(()=>u?s.totalResults>(e.page+1)*is:!1,[s,u]);return h.jsxs(h.Fragment,{children:[h.jsx(ab,{}),h.jsxs("div",{className:"p-10",children:[h.jsxs("div",{className:"flex justify-between items-center",children:[h.jsx("div",{className:"text-xl font-bold",children:"My Folders"}),h.jsx("button",{onClick:()=>n(!0),className:"text-base text-blue-500 cursor-pointer",children:"+ Create New Folder"})]}),h.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 xl:grid-cols-3 items-center gap-y-8 gap-x-12 my-8",children:[l&&h.jsx(Jt,{}),u&&s.results?.map(b=>h.jsx(Zme,{folder:b},b.id))]}),h.jsxs("div",{className:"flex justify-end-safe",children:[h.jsx(qn,{to:".",search:b=>({...b,page:e.page-1}),disabled:e.page===0,className:"aria-disabled:text-gray-400 cursor-pointer aria-disabled:cursor-default",children:h.jsx(we,{icon:n0,size:"xxlarge"})}),h.jsx(qn,{to:".",search:b=>({...b,page:e.page+1}),disabled:!y,className:"aria-disabled:text-gray-400 cursor-pointer aria-disabled:cursor-default",children:h.jsx(we,{icon:Aee,size:"xxlarge"})})]})]}),t&&h.jsx(bn,{title:"Create new folder",onClose:()=>n(!1),appendTo:null,width:500,children:h.jsxs("div",{className:"space-y-4",children:[h.jsx("input",{type:"text",value:r,onChange:v,className:"w-full px-4 py-3 border border-gray-300 rounded-md focus:outline-none"}),h.jsx("button",{onClick:g,disabled:m||r.trim().length===0,className:"btn-blue disabled:bg-gray-400 disabled:border-gray-400 disabled:cursor-not-allowed",children:"Save"})]})})]})},d0=Md("/my-archive/folders/$folder"),Jme=({rowSelection:e,setRowSelection:t})=>{const{page:n}=d0.useSearch(),{folder:r}=d0.useParams(),{data:i,isLoading:s}=Gt(xz(r,n)),l=i?.payload?.searchResults||[],u=i?.payload?.totalResults,d=ur(),m=[d.display({id:"id",minSize:60,maxSize:60,header:({table:C})=>h.jsx("input",{id:"selectAll",type:"checkbox",checked:C.getIsAllRowsSelected(),onChange:C.getToggleAllRowsSelectedHandler()}),cell:({row:C})=>h.jsx("label",{className:"px-6 py-4",onClick:M=>{M.stopPropagation()},children:h.jsx("input",{id:`select_${C.id}`,type:"checkbox",checked:C.getIsSelected(),onChange:C.getToggleSelectedHandler()})})}),d.accessor("date",{id:"date",header:"Date",cell:C=>h.jsx("span",{children:Qi(new Date(C.getValue()),"MM/dd/yyyy")})}),d.accessor("type",{header:"Element Type",size:200,cell:C=>{let M=C.getValue();return M=="social_media"&&(M=C.row.original.socialMediaType??M),h.jsx("span",{className:"capitalize",children:M})}}),d.accessor("expiredItem",{header:"Expired",size:200,cell:C=>h.jsx("span",{className:"capitalize",children:String(C.getValue())})})],[v,g]=j.useState({pageIndex:n||0,pageSize:is}),y=kr(),b=C=>{let M=v;typeof C=="function"?M=C(M):M=C,v.pageIndex!==M.pageIndex&&(g(C),y({to:".",search:P=>({...P,page:M.pageIndex})}))},A=fr({data:l,columns:m,getCoreRowModel:cr(),getRowId:C=>C.id,manualPagination:!0,getPaginationRowModel:dr(),pageCount:Math.ceil(u/is),rowCount:u,onPaginationChange:b,onRowSelectionChange:t,state:{pagination:v,rowSelection:e}}),w=kr(),S=C=>w({to:"/my-archive/preview",search:{path:C.original.s3Path,folder:Number(r)}});return h.jsx(N0,{emptyMessage:s?h.jsx(Jt,{}):i?.errorMessage,table:A,bordered:!1,pageSizes:[is],onRowClick:C=>S(C)})},xz=(e,t)=>({queryKey:["folderContent",e,t],queryFn:()=>bt.executeRequest("/AdvancedSearch/folder_content","POST",{folderId:e,pageNumber:t})}),$me=()=>{const e=rn();return Tt({mutationFn:({folder:t,ids:n})=>{const r=Object.keys(n).map(s=>({esId:s})),i=parseInt(t);return bt.executeRequest("/AdvancedSearch/remove_items_from_folder","POST",{folderId:i,selectedItems:r})},onSuccess:()=>{e.invalidateQueries({queryKey:["folderContent"]}),Xe.success("File removed from folder.")}})},epe=()=>Tt({mutationFn:({folderId:e,includeSearchTerms:t=!1,note:n=""})=>bt.executeRequest("/AdvancedSearch/add_folder_to_compliance_log","POST",{folderId:e,includeSearchTerms:t,note:n})}),tpe=()=>{const e=d0.useParams(),t=d0.useSearch(),{data:n,isError:r}=Gt(xz(e.folder,t.page)),[i,s]=j.useState({}),{mutate:l}=$me(),[u,d]=j.useState(!1),[m,v]=j.useState(!1),[g,y]=j.useState(""),{mutate:b}=epe(),A=()=>{b({folderId:Number(e.folder),includeSearchTerms:m,note:g})};return h.jsxs(h.Fragment,{children:[h.jsx(ab,{children:h.jsxs("div",{className:"px-8 flex h-full items-center justify-between",children:[h.jsxs(qn,{to:"..",className:"cursor-pointer text-gray-800 font-bold flex items-center",children:[h.jsx(we,{icon:n0,size:"large"}),h.jsx("span",{children:"Back"})]}),h.jsxs("div",{className:"flex gap-x-4",children:[h.jsxs("button",{className:"bg-white cursor-pointer shadow-sm px-4 py-1 flex gap-2 items-center rounded-sm text-md font-semibold disabled:bg-gray-300 disabled:text-gray-800 disabled:cursor-default",disabled:Object.keys(i).length<1,onClick:()=>{l({folder:e.folder,ids:i})},children:[h.jsx(we,{icon:xa,size:"large"}),"Delete"]}),h.jsxs("button",{className:"bg-white cursor-pointer shadow-sm px-4 py-1 flex gap-2 items-center rounded-sm text-md font-semibold disabled:bg-gray-300 disabled:text-gray-800 disabled:cursor-default",disabled:!n?.payload?.complianceLogBtnActv,onClick:()=>d(!0),children:[h.jsx(we,{icon:Fee,size:"large"}),"Send Folder to Compliance Log"]})]})]})}),h.jsxs("div",{className:"m-8",children:[h.jsx("h1",{children:t.folderName}),r?h.jsx("span",{children:"An error happend while loading"}):h.jsx(Jme,{rowSelection:i,setRowSelection:w=>s(w)})]}),u&&h.jsx(bn,{title:"",width:700,appendTo:null,onClose:()=>d(!1),children:h.jsxs("div",{className:"p-3",children:[h.jsxs("div",{className:"flex items-center justify-between border-b-6 border-blue-900 pb-2",children:[h.jsxs("h2",{className:"text-blue-900 text-xl font-semibold",children:["My Archive: ",t.folderName]}),h.jsxs("button",{className:"flex items-end text-blue-900 uppercase font-semibold hover:cursor-pointer",onClick:()=>d(!1),children:[h.jsx(we,{size:"medium",className:"mr-1",icon:vn})," Close"]})]}),h.jsxs("div",{className:"py-3 space-y-4",children:[h.jsx("div",{children:"Search Result Filters"}),h.jsx("textarea",{className:"text-sm outline-none py-3 px-5 border rounded border-[#DEE2E6] w-full h-[100px]",placeholder:"Add additional notes (maximum 200 characters)",maxLength:200,value:g,onChange:w=>y(w.currentTarget.value),name:"note",id:"note"}),h.jsxs("div",{className:"flex justify-between items-end",children:[h.jsxs("label",{className:"flex gap-1 items-center",children:[h.jsx("input",{type:"checkbox",name:"searchTerms",id:"searchTerms",className:"h-5 w-5 checked:accent-blue-900",checked:m,onClick:()=>v(!m)}),"Include Search Terms"]}),h.jsx("button",{onClick:A,className:"btn-blue",children:"Add to Log"})]})]})]})})]})};var Gl={},Fs={},Xl={},FL;function SI(){if(FL)return Xl;FL=1;var e=Xl&&Xl.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Xl,"__esModule",{value:!0}),Xl.useFrame=void 0;const t=e(hn()),n=r=>t.default.useMemo(()=>r||{document:typeof document<"u"?document:void 0,window:typeof window<"u"?window:void 0},[r]);return Xl.useFrame=n,Xl}var ks={},qs={},kL;function gl(){if(kL)return qs;kL=1;var e=qs&&qs.__rest||function(s,l){var u={};for(var d in s)Object.prototype.hasOwnProperty.call(s,d)&&l.indexOf(d)<0&&(u[d]=s[d]);if(s!=null&&typeof Object.getOwnPropertySymbols=="function")for(var m=0,d=Object.getOwnPropertySymbols(s);m<d.length;m++)l.indexOf(d[m])<0&&Object.prototype.propertyIsEnumerable.call(s,d[m])&&(u[d[m]]=s[d[m]]);return u},t=qs&&qs.__importDefault||function(s){return s&&s.__esModule?s:{default:s}};Object.defineProperty(qs,"__esModule",{value:!0}),qs.EmbedStyle=void 0;const n=t(_r()),r=t(hn()),i=s=>{var l=e(s,[]);return r.default.createElement("style",Object.assign({},l,{className:(0,n.default)(l.className),style:Object.assign({},l.style)}),`
|
|
626
626
|
.rsme-embed .rsme-d-none {
|
|
627
627
|
display: none;
|
|
628
628
|
}
|