ados-rcm 1.1.594 → 1.1.595
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/index.cjs.js +1 -1
- package/dist/index.es.js +1 -1
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
@@ -361,7 +361,7 @@ received: ${r.imageType}
|
|
361
361
|
To pick up a draggable item, press the space bar.
|
362
362
|
While dragging, use the arrow keys to move the item.
|
363
363
|
Press space again to drop the item in its new position, or press escape to cancel.
|
364
|
-
`},xj={onDragStart(r){let{active:e}=r;return"Picked up draggable item "+e.id+"."},onDragOver(r){let{active:e,over:t}=r;return t?"Draggable item "+e.id+" was moved over droppable area "+t.id+".":"Draggable item "+e.id+" is no longer over a droppable area."},onDragEnd(r){let{active:e,over:t}=r;return t?"Draggable item "+e.id+" was dropped over droppable area "+t.id:"Draggable item "+e.id+" was dropped."},onDragCancel(r){let{active:e}=r;return"Dragging was cancelled. Draggable item "+e.id+" was dropped."}};function wj(r){let{announcements:e=xj,container:t,hiddenTextDescribedById:n,screenReaderInstructions:o=bj}=r;const{announce:i,announcement:a}=mj(),c=Vh("DndLiveRegion"),[d,h]=S.useState(!1);if(S.useEffect(()=>{h(!0)},[]),vj(S.useMemo(()=>({onDragStart(m){let{active:g}=m;i(e.onDragStart({active:g}))},onDragMove(m){let{active:g,over:v}=m;e.onDragMove&&i(e.onDragMove({active:g,over:v}))},onDragOver(m){let{active:g,over:v}=m;i(e.onDragOver({active:g,over:v}))},onDragEnd(m){let{active:g,over:v}=m;i(e.onDragEnd({active:g,over:v}))},onDragCancel(m){let{active:g,over:v}=m;i(e.onDragCancel({active:g,over:v}))}}),[i,e])),!d)return null;const p=S.createElement(S.Fragment,null,S.createElement(pj,{id:n,value:o.draggable}),S.createElement(gj,{id:c,announcement:a}));return t?Ls.createPortal(p,t):p}var So;(function(r){r.DragStart="dragStart",r.DragMove="dragMove",r.DragEnd="dragEnd",r.DragCancel="dragCancel",r.DragOver="dragOver",r.RegisterDroppable="registerDroppable",r.SetDroppableDisabled="setDroppableDisabled",r.UnregisterDroppable="unregisterDroppable"})(So||(So={}));function mg(){}function ux(r,e){return S.useMemo(()=>({sensor:r,options:e??{}}),[r,e])}function Cj(){for(var r=arguments.length,e=new Array(r),t=0;t<r;t++)e[t]=arguments[t];return S.useMemo(()=>[...e].filter(n=>n!=null),[...e])}const va=Object.freeze({x:0,y:0});function Sj(r,e){return Math.sqrt(Math.pow(r.x-e.x,2)+Math.pow(r.y-e.y,2))}function _j(r,e){let{data:{value:t}}=r,{data:{value:n}}=e;return t-n}function Aj(r,e){let{data:{value:t}}=r,{data:{value:n}}=e;return n-t}function Ej(r,e){if(!r||r.length===0)return null;const[t]=r;return t[e]}function dx(r,e,t){return e===void 0&&(e=r.left),t===void 0&&(t=r.top),{x:e+r.width*.5,y:t+r.height*.5}}const Tj=r=>{let{collisionRect:e,droppableRects:t,droppableContainers:n}=r;const o=dx(e,e.left,e.top),i=[];for(const a of n){const{id:c}=a,d=t.get(c);if(d){const h=Sj(dx(d),o);i.push({id:c,data:{droppableContainer:a,value:h}})}}return i.sort(_j)};function Rj(r,e){const t=Math.max(e.top,r.top),n=Math.max(e.left,r.left),o=Math.min(e.left+e.width,r.left+r.width),i=Math.min(e.top+e.height,r.top+r.height),a=o-n,c=i-t;if(n<o&&t<i){const d=e.width*e.height,h=r.width*r.height,p=a*c,m=p/(d+h-p);return Number(m.toFixed(4))}return 0}const kj=r=>{let{collisionRect:e,droppableRects:t,droppableContainers:n}=r;const o=[];for(const i of n){const{id:a}=i,c=t.get(a);if(c){const d=Rj(c,e);d>0&&o.push({id:a,data:{droppableContainer:i,value:d}})}}return o.sort(Aj)};function Ij(r,e,t){return{...r,scaleX:e&&t?e.width/t.width:1,scaleY:e&&t?e.height/t.height:1}}function cS(r,e){return r&&e?{x:r.left-e.left,y:r.top-e.top}:va}function Mj(r){return function(t){for(var n=arguments.length,o=new Array(n>1?n-1:0),i=1;i<n;i++)o[i-1]=arguments[i];return o.reduce((a,c)=>({...a,top:a.top+r*c.y,bottom:a.bottom+r*c.y,left:a.left+r*c.x,right:a.right+r*c.x}),{...t})}}const Lj=Mj(1);function Dj(r){if(r.startsWith("matrix3d(")){const e=r.slice(9,-1).split(/, /);return{x:+e[12],y:+e[13],scaleX:+e[0],scaleY:+e[5]}}else if(r.startsWith("matrix(")){const e=r.slice(7,-1).split(/, /);return{x:+e[4],y:+e[5],scaleX:+e[0],scaleY:+e[3]}}return null}function Oj(r,e,t){const n=Dj(e);if(!n)return r;const{scaleX:o,scaleY:i,x:a,y:c}=n,d=r.left-a-(1-o)*parseFloat(t),h=r.top-c-(1-i)*parseFloat(t.slice(t.indexOf(" ")+1)),p=o?r.width/o:r.width,m=i?r.height/i:r.height;return{width:p,height:m,top:h,right:d+p,bottom:h+m,left:d}}const Nj={ignoreTransform:!1};function _f(r,e){e===void 0&&(e=Nj);let t=r.getBoundingClientRect();if(e.ignoreTransform){const{transform:h,transformOrigin:p}=Ni(r).getComputedStyle(r);h&&(t=Oj(t,h,p))}const{top:n,left:o,width:i,height:a,bottom:c,right:d}=t;return{top:n,left:o,width:i,height:a,bottom:c,right:d}}function fx(r){return _f(r,{ignoreTransform:!0})}function Pj(r){const e=r.innerWidth,t=r.innerHeight;return{top:0,left:0,right:e,bottom:t,width:e,height:t}}function Bj(r,e){return e===void 0&&(e=Ni(r).getComputedStyle(r)),e.position==="fixed"}function Fj(r,e){e===void 0&&(e=Ni(r).getComputedStyle(r));const t=/(auto|scroll|overlay)/;return["overflow","overflowX","overflowY"].some(o=>{const i=e[o];return typeof i=="string"?t.test(i):!1})}function iy(r,e){const t=[];function n(o){if(e!=null&&t.length>=e||!o)return t;if(ry(o)&&o.scrollingElement!=null&&!t.includes(o.scrollingElement))return t.push(o.scrollingElement),t;if(!Uh(o)||sS(o)||t.includes(o))return t;const i=Ni(r).getComputedStyle(o);return o!==r&&Fj(o,i)&&t.push(o),Bj(o,i)?t:n(o.parentNode)}return r?n(r):t}function uS(r){const[e]=iy(r,1);return e??null}function jm(r){return!Pg||!r?null:Cf(r)?r:ty(r)?ry(r)||r===Sf(r).scrollingElement?window:Uh(r)?r:null:null}function dS(r){return Cf(r)?r.scrollX:r.scrollLeft}function fS(r){return Cf(r)?r.scrollY:r.scrollTop}function gv(r){return{x:dS(r),y:fS(r)}}var Mo;(function(r){r[r.Forward=1]="Forward",r[r.Backward=-1]="Backward"})(Mo||(Mo={}));function hS(r){return!Pg||!r?!1:r===document.scrollingElement}function pS(r){const e={x:0,y:0},t=hS(r)?{height:window.innerHeight,width:window.innerWidth}:{height:r.clientHeight,width:r.clientWidth},n={x:r.scrollWidth-t.width,y:r.scrollHeight-t.height},o=r.scrollTop<=e.y,i=r.scrollLeft<=e.x,a=r.scrollTop>=n.y,c=r.scrollLeft>=n.x;return{isTop:o,isLeft:i,isBottom:a,isRight:c,maxScroll:n,minScroll:e}}const jj={x:.2,y:.2};function Hj(r,e,t,n,o){let{top:i,left:a,right:c,bottom:d}=t;n===void 0&&(n=10),o===void 0&&(o=jj);const{isTop:h,isBottom:p,isLeft:m,isRight:g}=pS(r),v={x:0,y:0},w={x:0,y:0},T={height:e.height*o.y,width:e.width*o.x};return!h&&i<=e.top+T.height?(v.y=Mo.Backward,w.y=n*Math.abs((e.top+T.height-i)/T.height)):!p&&d>=e.bottom-T.height&&(v.y=Mo.Forward,w.y=n*Math.abs((e.bottom-T.height-d)/T.height)),!g&&c>=e.right-T.width?(v.x=Mo.Forward,w.x=n*Math.abs((e.right-T.width-c)/T.width)):!m&&a<=e.left+T.width&&(v.x=Mo.Backward,w.x=n*Math.abs((e.left+T.width-a)/T.width)),{direction:v,speed:w}}function zj(r){if(r===document.scrollingElement){const{innerWidth:i,innerHeight:a}=window;return{top:0,left:0,right:i,bottom:a,width:i,height:a}}const{top:e,left:t,right:n,bottom:o}=r.getBoundingClientRect();return{top:e,left:t,right:n,bottom:o,width:r.clientWidth,height:r.clientHeight}}function gS(r){return r.reduce((e,t)=>of(e,gv(t)),va)}function $j(r){return r.reduce((e,t)=>e+dS(t),0)}function qj(r){return r.reduce((e,t)=>e+fS(t),0)}function Uj(r,e){if(e===void 0&&(e=_f),!r)return;const{top:t,left:n,bottom:o,right:i}=e(r);uS(r)&&(o<=0||i<=0||t>=window.innerHeight||n>=window.innerWidth)&&r.scrollIntoView({block:"center",inline:"center"})}const Wj=[["x",["left","right"],$j],["y",["top","bottom"],qj]];class sy{constructor(e,t){this.rect=void 0,this.width=void 0,this.height=void 0,this.top=void 0,this.bottom=void 0,this.right=void 0,this.left=void 0;const n=iy(t),o=gS(n);this.rect={...e},this.width=e.width,this.height=e.height;for(const[i,a,c]of Wj)for(const d of a)Object.defineProperty(this,d,{get:()=>{const h=c(n),p=o[i]-h;return this.rect[d]+p},enumerable:!0});Object.defineProperty(this,"rect",{enumerable:!1})}}class mh{constructor(e){this.target=void 0,this.listeners=[],this.removeAll=()=>{this.listeners.forEach(t=>{var n;return(n=this.target)==null?void 0:n.removeEventListener(...t)})},this.target=e}add(e,t,n){var o;(o=this.target)==null||o.addEventListener(e,t,n),this.listeners.push([e,t,n])}}function Vj(r){const{EventTarget:e}=Ni(r);return r instanceof e?r:Sf(r)}function Hm(r,e){const t=Math.abs(r.x),n=Math.abs(r.y);return typeof e=="number"?Math.sqrt(t**2+n**2)>e:"x"in e&&"y"in e?t>e.x&&n>e.y:"x"in e?t>e.x:"y"in e?n>e.y:!1}var Rs;(function(r){r.Click="click",r.DragStart="dragstart",r.Keydown="keydown",r.ContextMenu="contextmenu",r.Resize="resize",r.SelectionChange="selectionchange",r.VisibilityChange="visibilitychange"})(Rs||(Rs={}));function hx(r){r.preventDefault()}function Gj(r){r.stopPropagation()}var un;(function(r){r.Space="Space",r.Down="ArrowDown",r.Right="ArrowRight",r.Left="ArrowLeft",r.Up="ArrowUp",r.Esc="Escape",r.Enter="Enter",r.Tab="Tab"})(un||(un={}));const mS={start:[un.Space,un.Enter],cancel:[un.Esc],end:[un.Space,un.Enter,un.Tab]},Yj=(r,e)=>{let{currentCoordinates:t}=e;switch(r.code){case un.Right:return{...t,x:t.x+25};case un.Left:return{...t,x:t.x-25};case un.Down:return{...t,y:t.y+25};case un.Up:return{...t,y:t.y-25}}};class ay{constructor(e){this.props=void 0,this.autoScrollEnabled=!1,this.referenceCoordinates=void 0,this.listeners=void 0,this.windowListeners=void 0,this.props=e;const{event:{target:t}}=e;this.props=e,this.listeners=new mh(Sf(t)),this.windowListeners=new mh(Ni(t)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(Rs.Resize,this.handleCancel),this.windowListeners.add(Rs.VisibilityChange,this.handleCancel),setTimeout(()=>this.listeners.add(Rs.Keydown,this.handleKeyDown))}handleStart(){const{activeNode:e,onStart:t}=this.props,n=e.node.current;n&&Uj(n),t(va)}handleKeyDown(e){if(oy(e)){const{active:t,context:n,options:o}=this.props,{keyboardCodes:i=mS,coordinateGetter:a=Yj,scrollBehavior:c="smooth"}=o,{code:d}=e;if(i.end.includes(d)){this.handleEnd(e);return}if(i.cancel.includes(d)){this.handleCancel(e);return}const{collisionRect:h}=n.current,p=h?{x:h.left,y:h.top}:va;this.referenceCoordinates||(this.referenceCoordinates=p);const m=a(e,{active:t,context:n.current,currentCoordinates:p});if(m){const g=gg(m,p),v={x:0,y:0},{scrollableAncestors:w}=n.current;for(const T of w){const A=e.code,{isTop:_,isRight:R,isLeft:D,isBottom:I,maxScroll:F,minScroll:B}=pS(T),H=zj(T),j={x:Math.min(A===un.Right?H.right-H.width/2:H.right,Math.max(A===un.Right?H.left:H.left+H.width/2,m.x)),y:Math.min(A===un.Down?H.bottom-H.height/2:H.bottom,Math.max(A===un.Down?H.top:H.top+H.height/2,m.y))},V=A===un.Right&&!R||A===un.Left&&!D,fe=A===un.Down&&!I||A===un.Up&&!_;if(V&&j.x!==m.x){const P=T.scrollLeft+g.x,U=A===un.Right&&P<=F.x||A===un.Left&&P>=B.x;if(U&&!g.y){T.scrollTo({left:P,behavior:c});return}U?v.x=T.scrollLeft-P:v.x=A===un.Right?T.scrollLeft-F.x:T.scrollLeft-B.x,v.x&&T.scrollBy({left:-v.x,behavior:c});break}else if(fe&&j.y!==m.y){const P=T.scrollTop+g.y,U=A===un.Down&&P<=F.y||A===un.Up&&P>=B.y;if(U&&!g.x){T.scrollTo({top:P,behavior:c});return}U?v.y=T.scrollTop-P:v.y=A===un.Down?T.scrollTop-F.y:T.scrollTop-B.y,v.y&&T.scrollBy({top:-v.y,behavior:c});break}}this.handleMove(e,of(gg(m,this.referenceCoordinates),v))}}}handleMove(e,t){const{onMove:n}=this.props;e.preventDefault(),n(t)}handleEnd(e){const{onEnd:t}=this.props;e.preventDefault(),this.detach(),t()}handleCancel(e){const{onCancel:t}=this.props;e.preventDefault(),this.detach(),t()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll()}}ay.activators=[{eventName:"onKeyDown",handler:(r,e,t)=>{let{keyboardCodes:n=mS,onActivation:o}=e,{active:i}=t;const{code:a}=r.nativeEvent;if(n.start.includes(a)){const c=i.activatorNode.current;return c&&r.target!==c?!1:(r.preventDefault(),o==null||o({event:r.nativeEvent}),!0)}return!1}}];function px(r){return!!(r&&"distance"in r)}function gx(r){return!!(r&&"delay"in r)}class ly{constructor(e,t,n){var o;n===void 0&&(n=Vj(e.event.target)),this.props=void 0,this.events=void 0,this.autoScrollEnabled=!0,this.document=void 0,this.activated=!1,this.initialCoordinates=void 0,this.timeoutId=null,this.listeners=void 0,this.documentListeners=void 0,this.windowListeners=void 0,this.props=e,this.events=t;const{event:i}=e,{target:a}=i;this.props=e,this.events=t,this.document=Sf(a),this.documentListeners=new mh(this.document),this.listeners=new mh(n),this.windowListeners=new mh(Ni(a)),this.initialCoordinates=(o=pv(i))!=null?o:va,this.handleStart=this.handleStart.bind(this),this.handleMove=this.handleMove.bind(this),this.handleEnd=this.handleEnd.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleKeydown=this.handleKeydown.bind(this),this.removeTextSelection=this.removeTextSelection.bind(this),this.attach()}attach(){const{events:e,props:{options:{activationConstraint:t,bypassActivationConstraint:n}}}=this;if(this.listeners.add(e.move.name,this.handleMove,{passive:!1}),this.listeners.add(e.end.name,this.handleEnd),e.cancel&&this.listeners.add(e.cancel.name,this.handleCancel),this.windowListeners.add(Rs.Resize,this.handleCancel),this.windowListeners.add(Rs.DragStart,hx),this.windowListeners.add(Rs.VisibilityChange,this.handleCancel),this.windowListeners.add(Rs.ContextMenu,hx),this.documentListeners.add(Rs.Keydown,this.handleKeydown),t){if(n!=null&&n({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if(gx(t)){this.timeoutId=setTimeout(this.handleStart,t.delay),this.handlePending(t);return}if(px(t)){this.handlePending(t);return}}this.handleStart()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll(),setTimeout(this.documentListeners.removeAll,50),this.timeoutId!==null&&(clearTimeout(this.timeoutId),this.timeoutId=null)}handlePending(e,t){const{active:n,onPending:o}=this.props;o(n,e,this.initialCoordinates,t)}handleStart(){const{initialCoordinates:e}=this,{onStart:t}=this.props;e&&(this.activated=!0,this.documentListeners.add(Rs.Click,Gj,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(Rs.SelectionChange,this.removeTextSelection),t(e))}handleMove(e){var t;const{activated:n,initialCoordinates:o,props:i}=this,{onMove:a,options:{activationConstraint:c}}=i;if(!o)return;const d=(t=pv(e))!=null?t:va,h=gg(o,d);if(!n&&c){if(px(c)){if(c.tolerance!=null&&Hm(h,c.tolerance))return this.handleCancel();if(Hm(h,c.distance))return this.handleStart()}if(gx(c)&&Hm(h,c.tolerance))return this.handleCancel();this.handlePending(c,h);return}e.cancelable&&e.preventDefault(),a(d)}handleEnd(){const{onAbort:e,onEnd:t}=this.props;this.detach(),this.activated||e(this.props.active),t()}handleCancel(){const{onAbort:e,onCancel:t}=this.props;this.detach(),this.activated||e(this.props.active),t()}handleKeydown(e){e.code===un.Esc&&this.handleCancel()}removeTextSelection(){var e;(e=this.document.getSelection())==null||e.removeAllRanges()}}const Zj={cancel:{name:"pointercancel"},move:{name:"pointermove"},end:{name:"pointerup"}};class cy extends ly{constructor(e){const{event:t}=e,n=Sf(t.target);super(e,Zj,n)}}cy.activators=[{eventName:"onPointerDown",handler:(r,e)=>{let{nativeEvent:t}=r,{onActivation:n}=e;return!t.isPrimary||t.button!==0?!1:(n==null||n({event:t}),!0)}}];const Kj={move:{name:"mousemove"},end:{name:"mouseup"}};var mv;(function(r){r[r.RightClick=2]="RightClick"})(mv||(mv={}));class Xj extends ly{constructor(e){super(e,Kj,Sf(e.event.target))}}Xj.activators=[{eventName:"onMouseDown",handler:(r,e)=>{let{nativeEvent:t}=r,{onActivation:n}=e;return t.button===mv.RightClick?!1:(n==null||n({event:t}),!0)}}];const zm={cancel:{name:"touchcancel"},move:{name:"touchmove"},end:{name:"touchend"}};class Jj extends ly{constructor(e){super(e,zm)}static setup(){return window.addEventListener(zm.move.name,e,{capture:!1,passive:!1}),function(){window.removeEventListener(zm.move.name,e)};function e(){}}}Jj.activators=[{eventName:"onTouchStart",handler:(r,e)=>{let{nativeEvent:t}=r,{onActivation:n}=e;const{touches:o}=t;return o.length>1?!1:(n==null||n({event:t}),!0)}}];var vh;(function(r){r[r.Pointer=0]="Pointer",r[r.DraggableRect=1]="DraggableRect"})(vh||(vh={}));var vg;(function(r){r[r.TreeOrder=0]="TreeOrder",r[r.ReversedTreeOrder=1]="ReversedTreeOrder"})(vg||(vg={}));function Qj(r){let{acceleration:e,activator:t=vh.Pointer,canScroll:n,draggingRect:o,enabled:i,interval:a=5,order:c=vg.TreeOrder,pointerCoordinates:d,scrollableAncestors:h,scrollableAncestorRects:p,delta:m,threshold:g}=r;const v=tH({delta:m,disabled:!i}),[w,T]=cj(),A=S.useRef({x:0,y:0}),_=S.useRef({x:0,y:0}),R=S.useMemo(()=>{switch(t){case vh.Pointer:return d?{top:d.y,bottom:d.y,left:d.x,right:d.x}:null;case vh.DraggableRect:return o}},[t,o,d]),D=S.useRef(null),I=S.useCallback(()=>{const B=D.current;if(!B)return;const H=A.current.x*_.current.x,j=A.current.y*_.current.y;B.scrollBy(H,j)},[]),F=S.useMemo(()=>c===vg.TreeOrder?[...h].reverse():h,[c,h]);S.useEffect(()=>{if(!i||!h.length||!R){T();return}for(const B of F){if((n==null?void 0:n(B))===!1)continue;const H=h.indexOf(B),j=p[H];if(!j)continue;const{direction:V,speed:fe}=Hj(B,j,R,e,g);for(const P of["x","y"])v[P][V[P]]||(fe[P]=0,V[P]=0);if(fe.x>0||fe.y>0){T(),D.current=B,w(I,a),A.current=fe,_.current=V;return}}A.current={x:0,y:0},_.current={x:0,y:0},T()},[e,I,n,T,i,a,JSON.stringify(R),JSON.stringify(v),w,h,F,p,JSON.stringify(g)])}const eH={x:{[Mo.Backward]:!1,[Mo.Forward]:!1},y:{[Mo.Backward]:!1,[Mo.Forward]:!1}};function tH(r){let{delta:e,disabled:t}=r;const n=hv(e);return Wh(o=>{if(t||!n||!o)return eH;const i={x:Math.sign(e.x-n.x),y:Math.sign(e.y-n.y)};return{x:{[Mo.Backward]:o.x[Mo.Backward]||i.x===-1,[Mo.Forward]:o.x[Mo.Forward]||i.x===1},y:{[Mo.Backward]:o.y[Mo.Backward]||i.y===-1,[Mo.Forward]:o.y[Mo.Forward]||i.y===1}}},[t,e,n])}function rH(r,e){const t=e!=null?r.get(e):void 0,n=t?t.node.current:null;return Wh(o=>{var i;return e==null?null:(i=n??o)!=null?i:null},[n,e])}function nH(r,e){return S.useMemo(()=>r.reduce((t,n)=>{const{sensor:o}=n,i=o.activators.map(a=>({eventName:a.eventName,handler:e(a.handler,n)}));return[...t,...i]},[]),[r,e])}var vf;(function(r){r[r.Always=0]="Always",r[r.BeforeDragging=1]="BeforeDragging",r[r.WhileDragging=2]="WhileDragging"})(vf||(vf={}));var vv;(function(r){r.Optimized="optimized"})(vv||(vv={}));const mx=new Map;function oH(r,e){let{dragging:t,dependencies:n,config:o}=e;const[i,a]=S.useState(null),{frequency:c,measure:d,strategy:h}=o,p=S.useRef(r),m=A(),g=Nh(m),v=S.useCallback(function(_){_===void 0&&(_=[]),!g.current&&a(R=>R===null?_:R.concat(_.filter(D=>!R.includes(D))))},[g]),w=S.useRef(null),T=Wh(_=>{if(m&&!t)return mx;if(!_||_===mx||p.current!==r||i!=null){const R=new Map;for(let D of r){if(!D)continue;if(i&&i.length>0&&!i.includes(D.id)&&D.rect.current){R.set(D.id,D.rect.current);continue}const I=D.node.current,F=I?new sy(d(I),I):null;D.rect.current=F,F&&R.set(D.id,F)}return R}return _},[r,i,t,m,d]);return S.useEffect(()=>{p.current=r},[r]),S.useEffect(()=>{m||v()},[t,m]),S.useEffect(()=>{i&&i.length>0&&a(null)},[JSON.stringify(i)]),S.useEffect(()=>{m||typeof c!="number"||w.current!==null||(w.current=setTimeout(()=>{v(),w.current=null},c))},[c,m,v,...n]),{droppableRects:T,measureDroppableContainers:v,measuringScheduled:i!=null};function A(){switch(h){case vf.Always:return!1;case vf.BeforeDragging:return t;default:return!t}}}function vS(r,e){return Wh(t=>r?t||(typeof e=="function"?e(r):r):null,[e,r])}function iH(r,e){return vS(r,e)}function sH(r){let{callback:e,disabled:t}=r;const n=ny(e),o=S.useMemo(()=>{if(t||typeof window>"u"||typeof window.MutationObserver>"u")return;const{MutationObserver:i}=window;return new i(n)},[n,t]);return S.useEffect(()=>()=>o==null?void 0:o.disconnect(),[o]),o}function Bg(r){let{callback:e,disabled:t}=r;const n=ny(e),o=S.useMemo(()=>{if(t||typeof window>"u"||typeof window.ResizeObserver>"u")return;const{ResizeObserver:i}=window;return new i(n)},[t]);return S.useEffect(()=>()=>o==null?void 0:o.disconnect(),[o]),o}function aH(r){return new sy(_f(r),r)}function vx(r,e,t){e===void 0&&(e=aH);const[n,o]=S.useState(null);function i(){o(d=>{if(!r)return null;if(r.isConnected===!1){var h;return(h=d??t)!=null?h:null}const p=e(r);return JSON.stringify(d)===JSON.stringify(p)?d:p})}const a=sH({callback(d){if(r)for(const h of d){const{type:p,target:m}=h;if(p==="childList"&&m instanceof HTMLElement&&m.contains(r)){i();break}}}}),c=Bg({callback:i});return ol(()=>{i(),r?(c==null||c.observe(r),a==null||a.observe(document.body,{childList:!0,subtree:!0})):(c==null||c.disconnect(),a==null||a.disconnect())},[r]),n}function lH(r){const e=vS(r);return cS(r,e)}const yx=[];function cH(r){const e=S.useRef(r),t=Wh(n=>r?n&&n!==yx&&r&&e.current&&r.parentNode===e.current.parentNode?n:iy(r):yx,[r]);return S.useEffect(()=>{e.current=r},[r]),t}function uH(r){const[e,t]=S.useState(null),n=S.useRef(r),o=S.useCallback(i=>{const a=jm(i.target);a&&t(c=>c?(c.set(a,gv(a)),new Map(c)):null)},[]);return S.useEffect(()=>{const i=n.current;if(r!==i){a(i);const c=r.map(d=>{const h=jm(d);return h?(h.addEventListener("scroll",o,{passive:!0}),[h,gv(h)]):null}).filter(d=>d!=null);t(c.length?new Map(c):null),n.current=r}return()=>{a(r),a(i)};function a(c){c.forEach(d=>{const h=jm(d);h==null||h.removeEventListener("scroll",o)})}},[o,r]),S.useMemo(()=>r.length?e?Array.from(e.values()).reduce((i,a)=>of(i,a),va):gS(r):va,[r,e])}function bx(r,e){e===void 0&&(e=[]);const t=S.useRef(null);return S.useEffect(()=>{t.current=null},e),S.useEffect(()=>{const n=r!==va;n&&!t.current&&(t.current=r),!n&&t.current&&(t.current=null)},[r]),t.current?gg(r,t.current):va}function dH(r){S.useEffect(()=>{if(!Pg)return;const e=r.map(t=>{let{sensor:n}=t;return n.setup==null?void 0:n.setup()});return()=>{for(const t of e)t==null||t()}},r.map(e=>{let{sensor:t}=e;return t}))}function fH(r,e){return S.useMemo(()=>r.reduce((t,n)=>{let{eventName:o,handler:i}=n;return t[o]=a=>{i(a,e)},t},{}),[r,e])}function yS(r){return S.useMemo(()=>r?Pj(r):null,[r])}const xx=[];function hH(r,e){e===void 0&&(e=_f);const[t]=r,n=yS(t?Ni(t):null),[o,i]=S.useState(xx);function a(){i(()=>r.length?r.map(d=>hS(d)?n:new sy(e(d),d)):xx)}const c=Bg({callback:a});return ol(()=>{c==null||c.disconnect(),a(),r.forEach(d=>c==null?void 0:c.observe(d))},[r]),o}function pH(r){if(!r)return null;if(r.children.length>1)return r;const e=r.children[0];return Uh(e)?e:r}function gH(r){let{measure:e}=r;const[t,n]=S.useState(null),o=S.useCallback(h=>{for(const{target:p}of h)if(Uh(p)){n(m=>{const g=e(p);return m?{...m,width:g.width,height:g.height}:g});break}},[e]),i=Bg({callback:o}),a=S.useCallback(h=>{const p=pH(h);i==null||i.disconnect(),p&&(i==null||i.observe(p)),n(p?e(p):null)},[e,i]),[c,d]=pg(a);return S.useMemo(()=>({nodeRef:c,rect:t,setRef:d}),[t,c,d])}const mH=[{sensor:cy,options:{}},{sensor:ay,options:{}}],vH={current:{}},Zp={draggable:{measure:fx},droppable:{measure:fx,strategy:vf.WhileDragging,frequency:vv.Optimized},dragOverlay:{measure:_f}};class yh extends Map{get(e){var t;return e!=null&&(t=super.get(e))!=null?t:void 0}toArray(){return Array.from(this.values())}getEnabled(){return this.toArray().filter(e=>{let{disabled:t}=e;return!t})}getNodeFor(e){var t,n;return(t=(n=this.get(e))==null?void 0:n.node.current)!=null?t:void 0}}const yH={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new yh,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:mg},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:Zp,measureDroppableContainers:mg,windowRect:null,measuringScheduled:!1},bH={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:""},dispatch:mg,draggableNodes:new Map,over:null,measureDroppableContainers:mg},Fg=S.createContext(bH),bS=S.createContext(yH);function xH(){return{draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new yh}}}function wH(r,e){switch(e.type){case So.DragStart:return{...r,draggable:{...r.draggable,initialCoordinates:e.initialCoordinates,active:e.active}};case So.DragMove:return r.draggable.active==null?r:{...r,draggable:{...r.draggable,translate:{x:e.coordinates.x-r.draggable.initialCoordinates.x,y:e.coordinates.y-r.draggable.initialCoordinates.y}}};case So.DragEnd:case So.DragCancel:return{...r,draggable:{...r.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case So.RegisterDroppable:{const{element:t}=e,{id:n}=t,o=new yh(r.droppable.containers);return o.set(n,t),{...r,droppable:{...r.droppable,containers:o}}}case So.SetDroppableDisabled:{const{id:t,key:n,disabled:o}=e,i=r.droppable.containers.get(t);if(!i||n!==i.key)return r;const a=new yh(r.droppable.containers);return a.set(t,{...i,disabled:o}),{...r,droppable:{...r.droppable,containers:a}}}case So.UnregisterDroppable:{const{id:t,key:n}=e,o=r.droppable.containers.get(t);if(!o||n!==o.key)return r;const i=new yh(r.droppable.containers);return i.delete(t),{...r,droppable:{...r.droppable,containers:i}}}default:return r}}function CH(r){let{disabled:e}=r;const{active:t,activatorEvent:n,draggableNodes:o}=S.useContext(Fg),i=hv(n),a=hv(t==null?void 0:t.id);return S.useEffect(()=>{if(!e&&!n&&i&&a!=null){if(!oy(i)||document.activeElement===i.target)return;const c=o.get(a);if(!c)return;const{activatorNode:d,node:h}=c;if(!d.current&&!h.current)return;requestAnimationFrame(()=>{for(const p of[d.current,h.current]){if(!p)continue;const m=fj(p);if(m){m.focus();break}}})}},[n,e,o,a,i]),null}function SH(r,e){let{transform:t,...n}=e;return r!=null&&r.length?r.reduce((o,i)=>i({transform:o,...n}),t):t}function _H(r){return S.useMemo(()=>({draggable:{...Zp.draggable,...r==null?void 0:r.draggable},droppable:{...Zp.droppable,...r==null?void 0:r.droppable},dragOverlay:{...Zp.dragOverlay,...r==null?void 0:r.dragOverlay}}),[r==null?void 0:r.draggable,r==null?void 0:r.droppable,r==null?void 0:r.dragOverlay])}function AH(r){let{activeNode:e,measure:t,initialRect:n,config:o=!0}=r;const i=S.useRef(!1),{x:a,y:c}=typeof o=="boolean"?{x:o,y:o}:o;ol(()=>{if(!a&&!c||!e){i.current=!1;return}if(i.current||!n)return;const h=e==null?void 0:e.node.current;if(!h||h.isConnected===!1)return;const p=t(h),m=cS(p,n);if(a||(m.x=0),c||(m.y=0),i.current=!0,Math.abs(m.x)>0||Math.abs(m.y)>0){const g=uS(h);g&&g.scrollBy({top:m.y,left:m.x})}},[e,a,c,n,t])}const xS=S.createContext({...va,scaleX:1,scaleY:1});var Oc;(function(r){r[r.Uninitialized=0]="Uninitialized",r[r.Initializing=1]="Initializing",r[r.Initialized=2]="Initialized"})(Oc||(Oc={}));const EH=S.memo(function(e){var t,n,o,i;let{id:a,accessibility:c,autoScroll:d=!0,children:h,sensors:p=mH,collisionDetection:m=kj,measuring:g,modifiers:v,...w}=e;const T=S.useReducer(wH,void 0,xH),[A,_]=T,[R,D]=yj(),[I,F]=S.useState(Oc.Uninitialized),B=I===Oc.Initialized,{draggable:{active:H,nodes:j,translate:V},droppable:{containers:fe}}=A,P=H!=null?j.get(H):null,U=S.useRef({initial:null,translated:null}),G=S.useMemo(()=>{var kt;return H!=null?{id:H,data:(kt=P==null?void 0:P.data)!=null?kt:vH,rect:U}:null},[H,P]),Q=S.useRef(null),[ae,ie]=S.useState(null),[oe,ne]=S.useState(null),ye=Nh(w,Object.values(w)),te=Vh("DndDescribedBy",a),re=S.useMemo(()=>fe.getEnabled(),[fe]),ge=_H(g),{droppableRects:Ae,measureDroppableContainers:Te,measuringScheduled:se}=oH(re,{dragging:B,dependencies:[V.x,V.y],config:ge.droppable}),he=rH(j,H),Ce=S.useMemo(()=>oe?pv(oe):null,[oe]),qe=Pt(),Ee=iH(he,ge.draggable.measure);AH({activeNode:H!=null?j.get(H):null,config:qe.layoutShiftCompensation,initialRect:Ee,measure:ge.draggable.measure});const Ne=vx(he,ge.draggable.measure,Ee),Be=vx(he?he.parentElement:null),Ve=S.useRef({activatorEvent:null,active:null,activeNode:he,collisionRect:null,collisions:null,droppableRects:Ae,draggableNodes:j,draggingNode:null,draggingNodeRect:null,droppableContainers:fe,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),Pe=fe.getNodeFor((t=Ve.current.over)==null?void 0:t.id),Oe=gH({measure:ge.dragOverlay.measure}),Ie=(n=Oe.nodeRef.current)!=null?n:he,we=B?(o=Oe.rect)!=null?o:Ne:null,$e=!!(Oe.nodeRef.current&&Oe.rect),it=lH($e?null:Ne),at=yS(Ie?Ni(Ie):null),_t=cH(B?Pe??he:null),Ye=hH(_t),Xe=SH(v,{transform:{x:V.x-it.x,y:V.y-it.y,scaleX:1,scaleY:1},activatorEvent:oe,active:G,activeNodeRect:Ne,containerNodeRect:Be,draggingNodeRect:we,over:Ve.current.over,overlayNodeRect:Oe.rect,scrollableAncestors:_t,scrollableAncestorRects:Ye,windowRect:at}),ft=Ce?of(Ce,V):null,mt=uH(_t),Fe=bx(mt),Qe=bx(mt,[Ne]),At=of(Xe,Fe),Nt=we?Lj(we,Xe):null,Rt=G&&Nt?m({active:G,collisionRect:Nt,droppableRects:Ae,droppableContainers:re,pointerCoordinates:ft}):null,Ot=Ej(Rt,"id"),[Wt,rr]=S.useState(null),or=$e?Xe:of(Xe,Qe),hr=Ij(or,(i=Wt==null?void 0:Wt.rect)!=null?i:null,Ne),ur=S.useRef(null),_e=S.useCallback((kt,Ht)=>{let{sensor:Ze,options:lt}=Ht;if(Q.current==null)return;const ht=j.get(Q.current);if(!ht)return;const Ct=kt.nativeEvent,tt=new Ze({active:Q.current,activeNode:ht,event:Ct,options:lt,context:Ve,onAbort(Dt){if(!j.get(Dt))return;const{onDragAbort:ir}=ye.current,zt={id:Dt};ir==null||ir(zt),R({type:"onDragAbort",event:zt})},onPending(Dt,Gt,ir,zt){if(!j.get(Dt))return;const{onDragPending:Br}=ye.current,pr={id:Dt,constraint:Gt,initialCoordinates:ir,offset:zt};Br==null||Br(pr),R({type:"onDragPending",event:pr})},onStart(Dt){const Gt=Q.current;if(Gt==null)return;const ir=j.get(Gt);if(!ir)return;const{onDragStart:zt}=ye.current,vr={activatorEvent:Ct,active:{id:Gt,data:ir.data,rect:U}};Ls.unstable_batchedUpdates(()=>{zt==null||zt(vr),F(Oc.Initializing),_({type:So.DragStart,initialCoordinates:Dt,active:Gt}),R({type:"onDragStart",event:vr}),ie(ur.current),ne(Ct)})},onMove(Dt){_({type:So.DragMove,coordinates:Dt})},onEnd:yt(So.DragEnd),onCancel:yt(So.DragCancel)});ur.current=tt;function yt(Dt){return async function(){const{active:ir,collisions:zt,over:vr,scrollAdjustedTranslate:Br}=Ve.current;let pr=null;if(ir&&Br){const{cancelDrop:pe}=ye.current;pr={activatorEvent:Ct,active:ir,collisions:zt,delta:Br,over:vr},Dt===So.DragEnd&&typeof pe=="function"&&await Promise.resolve(pe(pr))&&(Dt=So.DragCancel)}Q.current=null,Ls.unstable_batchedUpdates(()=>{_({type:Dt}),F(Oc.Uninitialized),rr(null),ie(null),ne(null),ur.current=null;const pe=Dt===So.DragEnd?"onDragEnd":"onDragCancel";if(pr){const Me=ye.current[pe];Me==null||Me(pr),R({type:pe,event:pr})}})}}},[j]),le=S.useCallback((kt,Ht)=>(Ze,lt)=>{const ht=Ze.nativeEvent,Ct=j.get(lt);if(Q.current!==null||!Ct||ht.dndKit||ht.defaultPrevented)return;const tt={active:Ct};kt(Ze,Ht.options,tt)===!0&&(ht.dndKit={capturedBy:Ht.sensor},Q.current=lt,_e(Ze,Ht))},[j,_e]),ut=nH(p,le);dH(p),ol(()=>{Ne&&I===Oc.Initializing&&F(Oc.Initialized)},[Ne,I]),S.useEffect(()=>{const{onDragMove:kt}=ye.current,{active:Ht,activatorEvent:Ze,collisions:lt,over:ht}=Ve.current;if(!Ht||!Ze)return;const Ct={active:Ht,activatorEvent:Ze,collisions:lt,delta:{x:At.x,y:At.y},over:ht};Ls.unstable_batchedUpdates(()=>{kt==null||kt(Ct),R({type:"onDragMove",event:Ct})})},[At.x,At.y]),S.useEffect(()=>{const{active:kt,activatorEvent:Ht,collisions:Ze,droppableContainers:lt,scrollAdjustedTranslate:ht}=Ve.current;if(!kt||Q.current==null||!Ht||!ht)return;const{onDragOver:Ct}=ye.current,tt=lt.get(Ot),yt=tt&&tt.rect.current?{id:tt.id,rect:tt.rect.current,data:tt.data,disabled:tt.disabled}:null,Dt={active:kt,activatorEvent:Ht,collisions:Ze,delta:{x:ht.x,y:ht.y},over:yt};Ls.unstable_batchedUpdates(()=>{rr(yt),Ct==null||Ct(Dt),R({type:"onDragOver",event:Dt})})},[Ot]),ol(()=>{Ve.current={activatorEvent:oe,active:G,activeNode:he,collisionRect:Nt,collisions:Rt,droppableRects:Ae,draggableNodes:j,draggingNode:Ie,draggingNodeRect:we,droppableContainers:fe,over:Wt,scrollableAncestors:_t,scrollAdjustedTranslate:At},U.current={initial:we,translated:Nt}},[G,he,Rt,Nt,j,Ie,we,Ae,fe,Wt,_t,At]),Qj({...qe,delta:V,draggingRect:Nt,pointerCoordinates:ft,scrollableAncestors:_t,scrollableAncestorRects:Ye});const vt=S.useMemo(()=>({active:G,activeNode:he,activeNodeRect:Ne,activatorEvent:oe,collisions:Rt,containerNodeRect:Be,dragOverlay:Oe,draggableNodes:j,droppableContainers:fe,droppableRects:Ae,over:Wt,measureDroppableContainers:Te,scrollableAncestors:_t,scrollableAncestorRects:Ye,measuringConfiguration:ge,measuringScheduled:se,windowRect:at}),[G,he,Ne,oe,Rt,Be,Oe,j,fe,Ae,Wt,Te,_t,Ye,ge,se,at]),Ft=S.useMemo(()=>({activatorEvent:oe,activators:ut,active:G,activeNodeRect:Ne,ariaDescribedById:{draggable:te},dispatch:_,draggableNodes:j,over:Wt,measureDroppableContainers:Te}),[oe,ut,G,Ne,_,te,j,Wt,Te]);return S.createElement(lS.Provider,{value:D},S.createElement(Fg.Provider,{value:Ft},S.createElement(bS.Provider,{value:vt},S.createElement(xS.Provider,{value:hr},h)),S.createElement(CH,{disabled:(c==null?void 0:c.restoreFocus)===!1})),S.createElement(wj,{...c,hiddenTextDescribedById:te}));function Pt(){const kt=(ae==null?void 0:ae.autoScrollEnabled)===!1,Ht=typeof d=="object"?d.enabled===!1:d===!1,Ze=B&&!kt&&!Ht;return typeof d=="object"?{...d,enabled:Ze}:{enabled:Ze}}}),TH=S.createContext(null),wx="button",RH="Draggable";function kH(r){let{id:e,data:t,disabled:n=!1,attributes:o}=r;const i=Vh(RH),{activators:a,activatorEvent:c,active:d,activeNodeRect:h,ariaDescribedById:p,draggableNodes:m,over:g}=S.useContext(Fg),{role:v=wx,roleDescription:w="draggable",tabIndex:T=0}=o??{},A=(d==null?void 0:d.id)===e,_=S.useContext(A?xS:TH),[R,D]=pg(),[I,F]=pg(),B=fH(a,e),H=Nh(t);ol(()=>(m.set(e,{id:e,key:i,node:R,activatorNode:I,data:H}),()=>{const V=m.get(e);V&&V.key===i&&m.delete(e)}),[m,e]);const j=S.useMemo(()=>({role:v,tabIndex:T,"aria-disabled":n,"aria-pressed":A&&v===wx?!0:void 0,"aria-roledescription":w,"aria-describedby":p.draggable}),[n,v,T,A,w,p.draggable]);return{active:d,activatorEvent:c,activeNodeRect:h,attributes:j,isDragging:A,listeners:n?void 0:B,node:R,over:g,setNodeRef:D,setActivatorNodeRef:F,transform:_}}function IH(){return S.useContext(bS)}const MH="Droppable",LH={timeout:25};function DH(r){let{data:e,disabled:t=!1,id:n,resizeObserverConfig:o}=r;const i=Vh(MH),{active:a,dispatch:c,over:d,measureDroppableContainers:h}=S.useContext(Fg),p=S.useRef({disabled:t}),m=S.useRef(!1),g=S.useRef(null),v=S.useRef(null),{disabled:w,updateMeasurementsFor:T,timeout:A}={...LH,...o},_=Nh(T??n),R=S.useCallback(()=>{if(!m.current){m.current=!0;return}v.current!=null&&clearTimeout(v.current),v.current=setTimeout(()=>{h(Array.isArray(_.current)?_.current:[_.current]),v.current=null},A)},[A]),D=Bg({callback:R,disabled:w||!a}),I=S.useCallback((j,V)=>{D&&(V&&(D.unobserve(V),m.current=!1),j&&D.observe(j))},[D]),[F,B]=pg(I),H=Nh(e);return S.useEffect(()=>{!D||!F.current||(D.disconnect(),m.current=!1,D.observe(F.current))},[F,D]),S.useEffect(()=>(c({type:So.RegisterDroppable,element:{id:n,key:i,disabled:t,node:F,rect:g,data:H}}),()=>c({type:So.UnregisterDroppable,key:i,id:n})),[n]),S.useEffect(()=>{t!==p.current.disabled&&(c({type:So.SetDroppableDisabled,id:n,key:i,disabled:t}),p.current.disabled=t)},[n,i,t,c]),{active:a,rect:g,isOver:(d==null?void 0:d.id)===n,node:F,over:d,setNodeRef:B}}function wS(r,e,t){const n={...r};return e.top+r.y<=t.top?n.y=t.top-e.top:e.bottom+r.y>=t.top+t.height&&(n.y=t.top+t.height-e.bottom),e.left+r.x<=t.left?n.x=t.left-e.left:e.right+r.x>=t.left+t.width&&(n.x=t.left+t.width-e.right),n}const OH=r=>{let{containerNodeRect:e,draggingNodeRect:t,transform:n}=r;return!t||!e?n:wS(n,t,e)},NH=r=>{let{transform:e,draggingNodeRect:t,windowRect:n}=r;return!t||!n?e:wS(e,t,n)};function yg(r,e,t){const n=r.slice();return n.splice(t<0?n.length+t:t,0,n.splice(e,1)[0]),n}function PH(r,e){return r.reduce((t,n,o)=>{const i=e.get(n);return i&&(t[o]=i),t},Array(r.length))}function Np(r){return r!==null&&r>=0}function BH(r,e){if(r===e)return!0;if(r.length!==e.length)return!1;for(let t=0;t<r.length;t++)if(r[t]!==e[t])return!1;return!0}function FH(r){return typeof r=="boolean"?{draggable:r,droppable:r}:r}const CS=r=>{let{rects:e,activeIndex:t,overIndex:n,index:o}=r;const i=yg(e,n,t),a=e[o],c=i[o];return!c||!a?null:{x:c.left-a.left,y:c.top-a.top,scaleX:c.width/a.width,scaleY:c.height/a.height}},Pp={scaleX:1,scaleY:1},jH=r=>{var e;let{activeIndex:t,activeNodeRect:n,index:o,rects:i,overIndex:a}=r;const c=(e=i[t])!=null?e:n;if(!c)return null;if(o===t){const h=i[a];return h?{x:0,y:t<a?h.top+h.height-(c.top+c.height):h.top-c.top,...Pp}:null}const d=HH(i,o,t);return o>t&&o<=a?{x:0,y:-c.height-d,...Pp}:o<t&&o>=a?{x:0,y:c.height+d,...Pp}:{x:0,y:0,...Pp}};function HH(r,e,t){const n=r[e],o=r[e-1],i=r[e+1];return n?t<e?o?n.top-(o.top+o.height):i?i.top-(n.top+n.height):0:i?i.top-(n.top+n.height):o?n.top-(o.top+o.height):0:0}const SS="Sortable",_S=S.createContext({activeIndex:-1,containerId:SS,disableTransforms:!1,items:[],overIndex:-1,useDragOverlay:!1,sortedRects:[],strategy:CS,disabled:{draggable:!1,droppable:!1}});function zH(r){let{children:e,id:t,items:n,strategy:o=CS,disabled:i=!1}=r;const{active:a,dragOverlay:c,droppableRects:d,over:h,measureDroppableContainers:p}=IH(),m=Vh(SS,t),g=c.rect!==null,v=S.useMemo(()=>n.map(B=>typeof B=="object"&&"id"in B?B.id:B),[n]),w=a!=null,T=a?v.indexOf(a.id):-1,A=h?v.indexOf(h.id):-1,_=S.useRef(v),R=!BH(v,_.current),D=A!==-1&&T===-1||R,I=FH(i);ol(()=>{R&&w&&p(v)},[R,v,w,p]),S.useEffect(()=>{_.current=v},[v]);const F=S.useMemo(()=>({activeIndex:T,containerId:m,disabled:I,disableTransforms:D,items:v,overIndex:A,useDragOverlay:g,sortedRects:PH(v,d),strategy:o}),[T,m,I.draggable,I.droppable,D,v,A,d,g,o]);return S.createElement(_S.Provider,{value:F},e)}const $H=r=>{let{id:e,items:t,activeIndex:n,overIndex:o}=r;return yg(t,n,o).indexOf(e)},qH=r=>{let{containerId:e,isSorting:t,wasDragging:n,index:o,items:i,newIndex:a,previousItems:c,previousContainerId:d,transition:h}=r;return!h||!n||c!==i&&o===a?!1:t?!0:a!==o&&e===d},UH={duration:200,easing:"ease"},AS="transform",WH=Ph.Transition.toString({property:AS,duration:0,easing:"linear"}),VH={roleDescription:"sortable"};function GH(r){let{disabled:e,index:t,node:n,rect:o}=r;const[i,a]=S.useState(null),c=S.useRef(t);return ol(()=>{if(!e&&t!==c.current&&n.current){const d=o.current;if(d){const h=_f(n.current,{ignoreTransform:!0}),p={x:d.left-h.left,y:d.top-h.top,scaleX:d.width/h.width,scaleY:d.height/h.height};(p.x||p.y)&&a(p)}}t!==c.current&&(c.current=t)},[e,t,n,o]),S.useEffect(()=>{i&&a(null)},[i]),i}function YH(r){let{animateLayoutChanges:e=qH,attributes:t,disabled:n,data:o,getNewIndex:i=$H,id:a,strategy:c,resizeObserverConfig:d,transition:h=UH}=r;const{items:p,containerId:m,activeIndex:g,disabled:v,disableTransforms:w,sortedRects:T,overIndex:A,useDragOverlay:_,strategy:R}=S.useContext(_S),D=ZH(n,v),I=p.indexOf(a),F=S.useMemo(()=>({sortable:{containerId:m,index:I,items:p},...o}),[m,o,I,p]),B=S.useMemo(()=>p.slice(p.indexOf(a)),[p,a]),{rect:H,node:j,isOver:V,setNodeRef:fe}=DH({id:a,data:F,disabled:D.droppable,resizeObserverConfig:{updateMeasurementsFor:B,...d}}),{active:P,activatorEvent:U,activeNodeRect:G,attributes:Q,setNodeRef:ae,listeners:ie,isDragging:oe,over:ne,setActivatorNodeRef:ye,transform:te}=kH({id:a,data:F,attributes:{...VH,...t},disabled:D.draggable}),re=lj(fe,ae),ge=!!P,Ae=ge&&!w&&Np(g)&&Np(A),Te=!_&&oe,se=Te&&Ae?te:null,Ce=Ae?se??(c??R)({rects:T,activeNodeRect:G,activeIndex:g,overIndex:A,index:I}):null,qe=Np(g)&&Np(A)?i({id:a,items:p,activeIndex:g,overIndex:A}):I,Ee=P==null?void 0:P.id,Ne=S.useRef({activeId:Ee,items:p,newIndex:qe,containerId:m}),Be=p!==Ne.current.items,Ve=e({active:P,containerId:m,isDragging:oe,isSorting:ge,id:a,index:I,items:p,newIndex:Ne.current.newIndex,previousItems:Ne.current.items,previousContainerId:Ne.current.containerId,transition:h,wasDragging:Ne.current.activeId!=null}),Pe=GH({disabled:!Ve,index:I,node:j,rect:H});return S.useEffect(()=>{ge&&Ne.current.newIndex!==qe&&(Ne.current.newIndex=qe),m!==Ne.current.containerId&&(Ne.current.containerId=m),p!==Ne.current.items&&(Ne.current.items=p)},[ge,qe,m,p]),S.useEffect(()=>{if(Ee===Ne.current.activeId)return;if(Ee!=null&&Ne.current.activeId==null){Ne.current.activeId=Ee;return}const Ie=setTimeout(()=>{Ne.current.activeId=Ee},50);return()=>clearTimeout(Ie)},[Ee]),{active:P,activeIndex:g,attributes:Q,data:F,rect:H,index:I,newIndex:qe,items:p,isOver:V,isSorting:ge,isDragging:oe,listeners:ie,node:j,overIndex:A,over:ne,setNodeRef:re,setActivatorNodeRef:ye,setDroppableNodeRef:fe,setDraggableNodeRef:ae,transform:Pe??Ce,transition:Oe()};function Oe(){if(Pe||Be&&Ne.current.newIndex===I)return WH;if(!(Te&&!oy(U)||!h)&&(ge||Ve))return Ph.Transition.toString({...h,property:AS})}}function ZH(r,e){var t,n;return typeof r=="boolean"?{draggable:r,droppable:!1}:{draggable:(t=r==null?void 0:r.draggable)!=null?t:e.draggable,droppable:(n=r==null?void 0:r.droppable)!=null?n:e.droppable}}un.Down,un.Right,un.Up,un.Left;function bg(r,e){Array.isArray(r)||(r=[r]);for(const t of r){if(e(t))return t;if(!t.children||t.children.length<1)continue;const n=bg(t.children,e);if(n)return n}}function Gh(r,e){Array.isArray(r)||(r=[r]);for(const t of r)e(t),!(!t.children||t.children.length<1)&&Gh(t.children,e)}function ES(r,e){Array.isArray(r)||(r=[r]);const t=[];return Gh(r,(n,o)=>t.push(e(n,o))),t}function TS(r,e){Array.isArray(r)||(r=[r]);for(const t of r){if(!e(t))return!1;if(!(!t.children||t.children.length<1)&&!TS(t.children,e))return!1}return!0}function KH(r,e){Array.isArray(r)||(r=[r]);const t=[];return Gh(r,(n,o)=>{e(n,o)&&t.push(n)}),t}function XH(r){Array.isArray(r)||(r=[r]);let e=0;return Gh(r,()=>e++),e}function JH(r,e,t,n){if(n(e,t))return null;Array.isArray(r)||(r=[r]);const o=bg(r,a=>{var c;return(c=a.children)==null?void 0:c.some(d=>n(d,e))}),i=bg(r,a=>{var c;return(c=a.children)==null?void 0:c.some(d=>n(d,t))});if(o===void 0&&i===void 0){const a=r.findIndex(d=>n(d,e)),c=r.findIndex(d=>n(d,t));return r.splice(a,1),r.splice(c,0,e),[...r]}else if(o!==void 0&&i!==void 0&&n(o,i)&&o.children){const a=o.children.findIndex(d=>n(d,e)),c=o.children.findIndex(d=>n(d,t));return a===void 0||c===void 0?null:(o.children.splice(a,1),o.children.splice(c,0,e),o.children=[...o.children],[...r])}return null}function QH(r,e,t){const n=[],o=[...e];for(;o.length>0;){const i=o.shift();if(i&&!n.find(a=>t(a,i))&&(n.push(i),!(!i.children||i.children.length<1)))for(const a of i.children)o.push(a)}return n}function ez(r,e,t){Array.isArray(r)||(r=[r]);const n=ES(r,a=>a),o=[],i=[...e];for(;i.length>0;){const a=i.shift();if(!a||o.find(d=>t(d,a)))continue;o.push(a);const c=n.find(d=>{var h;return(h=d.children)==null?void 0:h.some(p=>t(p,a))});c&&i.push(c)}return o}const Nc={find:bg,forEach:Gh,map:ES,every:TS,filter:KH,length:XH,replace:JH,descendants:QH,ancestors:ez},tz="_AWrap_1mpkv_1",rz="_AContainer_1mpkv_10",nz="_ATree_1mpkv_18",oz="_ATreeBody_1mpkv_30",iz="_TreeTopAddon_1mpkv_36",sz="_CoverBorder_1mpkv_46",az="_InsertBorder_1mpkv_55",lz="_ATreeHeader_1mpkv_86",cz="_ATreeBodyHeader_1mpkv_92",uz="_ATreeBodyHeaderResources_1mpkv_102",dz="_ATreeItem_1mpkv_108",fz="_IsSelectUsed_1mpkv_124",hz="_IsSelected_1mpkv_127",pz="_IsSearchSelected_1mpkv_132",gz="_IsHovered_1mpkv_143",mz="_CheckBox_1mpkv_147",vz="_Indents_1mpkv_159",yz="_ExpandIcon_1mpkv_166",bz="_Content_1mpkv_178",xz="_RightSticky_1mpkv_187",wz="_SearchInputWrap_1mpkv_196",Cz="_SearchInput_1mpkv_196",Sz="_RightAddon_1mpkv_208",_z="_RightAddonIcon_1mpkv_219",Az="_Loader_1mpkv_226",Ez="_IsChildOfDragSource_1mpkv_231",mn={AWrap:tz,AContainer:rz,ATree:nz,ATreeBody:oz,TreeTopAddon:iz,CoverBorder:sz,InsertBorder:az,ATreeHeader:lz,ATreeBodyHeader:cz,ATreeBodyHeaderResources:uz,ATreeItem:dz,IsSelectUsed:fz,IsSelected:hz,IsSearchSelected:pz,IsHovered:gz,CheckBox:mz,Indents:vz,ExpandIcon:yz,Content:bz,RightSticky:xz,SearchInputWrap:wz,SearchInput:Cz,RightAddon:Sz,RightAddonIcon:_z,Loader:Az,IsChildOfDragSource:Ez},Tz=r=>{const{isEqual:e,item:t,itemId:n,selectDisabled:o,selectUnused:i,isParentDisabled:a,indents:c,extIndents:d,useExpand:h,useSelect:p,useSearch:m,showCheckbox:g,icons:v,iconWidth:w,isSelectMulti:T,isDraggable:A,isParentCheckHovered:_,hoverdItem:R,onMouseOver:D,onMouseLeave:I,ContentRenderer:F,TreeItemRenderer:B,RightStickyAddon:H,resources:j,containerRef:V,TreeItemStyle:fe,TreeItemClassName:P,searchItemStyle:U,searchItemClassName:G,height:Q,isDragSrcItem:ae,isChildOfDragItem:ie,treeItemTooltip:oe,treeItemTooltipDelay:ne,treeItemTooltipDirection:ye,treeItemTooltipDistance:te}=r,{children:re}=S.useMemo(()=>t,[t]),[ge,Ae]=S.useMemo(()=>h,[h]),[Te,se]=S.useMemo(()=>p,[p]),[he,Ce]=S.useMemo(()=>m,[m]),qe=S.useMemo(()=>i?i(t):!1,[i,t]),Ee=S.useMemo(()=>!o||a?a:o(t),[o,a,t]),Ne=S.useMemo(()=>ge.some(tt=>e(tt,t)),[ge,e,t]),Be=S.useMemo(()=>!re||re.length<1?"noChild":Ne?"expanded":"collapsed",[re,Ne]),Ve=S.useMemo(()=>Er.getContent(v,r),[v,r]),Pe=S.useMemo(()=>{const tt=Ve==null?void 0:Ve[Be];return wv.includes(tt)?C.jsx(en,{icon:tt,style:{width:w,height:w}}):tt},[Ve,w,Be]),Oe=S.useCallback(tt=>{!Ae||Be==="noChild"||(Ae(Ne?ge.filter(yt=>!e(yt,t)):[...ge,t]),tt.stopPropagation())},[Ae,ge,Ne,t,e,Be]),Ie=S.useMemo(()=>Te.some(tt=>e(tt,t)),[Te,e,t]),we=S.useCallback(()=>{!se||Ee||(se(T?Ie?Te.filter(tt=>!e(tt,t)):[...Te,t]:[t]),he&&Ce&&he.items.some(tt=>e(tt,t))&&Ce({...he,item:t}))},[T,Ee,Ie,he,Ce,se,e,Te,t]),$e=S.useMemo(()=>he==null?void 0:he.items.some(tt=>e(tt,t)),[he,e,t]),it=S.useMemo(()=>$e&&(he==null?void 0:he.item)&&e(he.item,t),[$e,he,e,t]),at=S.useRef(null),_t=S.useRef(null),{attributes:Ye,listeners:Xe,setNodeRef:ft,transform:mt,transition:Fe,isDragging:Qe}=YH({id:n||`item-${JSON.stringify(t)}`,disabled:!A||!!a||!n}),At=S.useMemo(()=>ie?ie(t):!1,[ie,t]),Nt=S.useMemo(()=>{const tt=mt?{transform:Ph.Transform.toString(mt),transition:Fe,opacity:Qe?.5:1,zIndex:Qe?1:"auto"}:{};return ae||At?{...tt,opacity:.5,zIndex:10}:tt},[mt,Fe,Qe,ae,At]);S.useEffect(()=>{n&&ft&&_t.current&&ft(_t.current)},[n,ft]),S.useEffect(()=>{setTimeout(()=>{if(it&&at.current&&V.current){const{top:tt,bottom:yt}=at.current.getBoundingClientRect(),{top:Dt,bottom:Gt}=V.current.getBoundingClientRect();(tt<Dt||yt>Gt)&&at.current.scrollIntoView({behavior:"smooth",block:"center"})}},10)},[V,it]);const[Rt,Ot]=S.useState(!1),Wt=S.useCallback(()=>!Ee&&Ot(!0),[Ee]),rr=S.useCallback(()=>!Ee&&Ot(!1),[Ee]),or=S.useMemo(()=>Nc.map(t,tt=>tt).filter(tt=>!(o!=null&&o(tt))&&!(i!=null&&i(tt))),[o,i,t]),hr=S.useMemo(()=>!g||!T?!1:Ie&&or.some(tt=>Te.some(yt=>e(tt,yt)))&&or.some(tt=>!Te.some(yt=>e(tt,yt))),[g,T,Ie,or,e,Te]),ur=S.useMemo(()=>g?T?or.every(tt=>Te.some(yt=>e(tt,yt))):Te.some(tt=>e(tt,t)):!1,[g,T,or,t,e,Te]),_e=S.useCallback(()=>{if(!(!se||Ee))if(T)if(Ie){const tt=Te.filter(yt=>!(i!=null&&i(yt))&&!(o!=null&&o(yt))&&or.some(Dt=>e(Dt,yt)));tt.length>0&&se(Te.filter(yt=>!tt.some(Dt=>e(yt,Dt))))}else{const tt=or.filter(yt=>!(i!=null&&i(yt))&&!(o!=null&&o(yt))&&!Te.some(Dt=>e(Dt,yt)));tt.length>0&&se([...Te,...tt])}else se([t])},[Ee,o,i,T,se,e,Ie,Te,or,t]),le=S.useCallback(tt=>{Ee||_e(),tt.stopPropagation()},[Ee,_e]),ut=S.useMemo(()=>{if(!g||!T||Ee)return"";if(Ie){const yt=Te.filter(Dt=>!(i!=null&&i(Dt))&&!(o!=null&&o(Dt))&&or.some(Gt=>e(Gt,Dt)));if(yt.length>0)return j["deselect n"](yt.length)}const tt=or.filter(yt=>!(i!=null&&i(yt))&&!(o!=null&&o(yt))&&!Te.some(Dt=>e(Dt,yt)));return j["select n"](tt.length)},[o,i,j,Ee,g,T,Ie,or,e,Te]),vt=S.useMemo(()=>Er.getContent(H,r),[H,r]),Ft=S.useMemo(()=>Er.getContent(fe,r),[r,fe]),Pt=S.useMemo(()=>Er.getContent(P,r),[r,P]),kt=S.useMemo(()=>Er.getContent(G,r),[r,G]),Ht=S.useMemo(()=>Er.getContent(U,r),[r,U]),Ze=S.useMemo(()=>Er.getContent(oe,r),[r,oe]),lt=S.useMemo(()=>Er.getContent(ne,r),[r,ne]),ht=S.useMemo(()=>Er.getContent(ye,r),[r,ye]),Ct=S.useMemo(()=>Er.getContent(te,r),[r,te]);return C.jsxs(S.Fragment,{children:[C.jsxs(Yr,{abaseRef:_t,isDisabled:Ee,className:Ke.clsx(mn.ATreeItem,Ie&&mn.IsSelected,!Ee&&(Rt||_)&&mn.IsHovered,$e&&mn.IsSearched,it&&(kt||mn.IsSearchSelected),!qe&&mn.IsSelectUsed,At&&mn.IsChildOfDragSource,"NoSelect",Pt),style:{...Ft,...it&&Ht?Ht:{},"--ATreeItem_height":`${Q}px`,...Nt||{}},onClick:we,onMouseLeave:tt=>I==null?void 0:I(tt,t),onMouseOver:tt=>D==null?void 0:D(tt,t),...A&&!Ee&&Ye?Ye:{},...A&&!Ee&&Xe?Xe:{},tooltip:Ze,tooltipDelay:lt,tooltipDirection:ht,tooltipDistance:Ct,children:[g&&C.jsx(af,{className:mn.CheckBox,isDisabled:Ee,isIndeterminate:hr,tooltip:ut,useCheck:[+ur,_e],style:{visibility:Ee||qe?"hidden":"visible",zIndex:Ee||qe?0:2},onClick:le,onMouseOut:rr,onMouseOver:Wt}),C.jsx("div",{className:mn.Indents,style:{paddingLeft:g?0:Ve!=null&&Ve.noChild?12:0},children:c.map((tt,yt)=>{const Dt=yt===c.length-1;return C.jsx(dC,{value:tt,map:{Collapsed:d?d({iconWidth:w}).collapsed:C.jsx(kz,{iconWidth:w}),Expanded:d?d({iconWidth:w,isLast:Dt}).expanded:C.jsx(Rz,{iconWidth:w,isLast:Dt}),IsLast:d?d({iconWidth:w}).isLast:C.jsx(Iz,{iconWidth:w})}},yt)})}),Pe&&C.jsx("div",{className:mn.ExpandIcon,style:{width:w,minWidth:w,maxWidth:w},onClick:Oe,children:Pe}),C.jsx("div",{className:Ke.clsx(mn.Content,"NoSelect"),children:C.jsx(F,{containerRef:V,ContentRenderer:F,extIndents:d,height:Q,hoverdItem:R,icons:v,iconWidth:w,indents:c,isDraggable:A,isEqual:e,isParentCheckHovered:T&&(Rt||_),isSelectMulti:T,item:t,itemId:n,resources:j,RightStickyAddon:H,searchItemClassName:kt,searchItemStyle:U,showCheckbox:g,TreeItemClassName:P,TreeItemRenderer:B,TreeItemStyle:fe,treeItemTooltip:oe,treeItemTooltipDelay:ne,treeItemTooltipDirection:ye,treeItemTooltipDistance:te,useExpand:h,useSearch:m,useSelect:p,onMouseLeave:I,onMouseOver:D})}),vt&&C.jsx("div",{className:mn.RightSticky,children:vt})]}),Ne&&(re==null?void 0:re.map((tt,yt)=>C.jsx(B,{containerRef:V,ContentRenderer:F,extIndents:d,height:Q,hoverdItem:R,icons:v,iconWidth:w,isChildOfDragItem:ie,isDraggable:A,isDragSrcItem:ae,isEqual:e,isParentCheckHovered:T&&(Rt||_),isSelectMulti:T,item:tt,itemId:n?`${n}-child-${yt}`:void 0,resources:j,RightStickyAddon:H,searchItemClassName:kt,searchItemStyle:U,selectDisabled:o,selectUnused:i,showCheckbox:g,TreeItemClassName:P,TreeItemRenderer:B,TreeItemStyle:fe,treeItemTooltip:oe,treeItemTooltipDelay:ne,treeItemTooltipDirection:ye,treeItemTooltipDistance:te,useExpand:h,useSearch:m,useSelect:p,indents:[...c.map(Dt=>Dt==="IsLast"?"Collapsed":Dt),yt===re.length-1?"IsLast":"Expanded"],onMouseLeave:I,onMouseOver:D},yt)))]})},Rz=({iconWidth:r,isLast:e})=>C.jsx("div",{style:{width:r/8*3,height:"100%",borderLeft:"var(--ATree_Indent_border)",marginLeft:r/2,marginRight:r/8,boxSizing:"border-box",transition:"border-color var(--Transition)"},children:e&&C.jsx("div",{style:{borderBottom:"var(--ATree_Indent_border)",height:"50%",transition:"border-color var(--Transition)"}})}),kz=({iconWidth:r})=>C.jsx("div",{style:{width:r,height:"100%",borderLeft:"none",marginLeft:0,transition:"border-color var(--Transition)"}}),Iz=({iconWidth:r})=>C.jsx("div",{style:{width:r/8*3,height:"50%",borderLeft:"var(--ATree_Indent_border)",borderBottom:"var(--ATree_Indent_border)",marginLeft:r/2,marginRight:r/8,boxSizing:"border-box",transition:"border-color var(--Transition)"}}),Mz=r=>{const{isEqual:e,searchResult:t,initSearch:n,searchUp:o,searchDown:i,searchEnter:a,isDisabled:c,isLoading:d,resources:h,maxLength:p,autoFocus:m}=r,g=S.useCallback(T=>{T.key==="Enter"?a():T.key==="ArrowDown"?i():T.key==="ArrowUp"&&o(),T.preventDefault(),T.stopPropagation()},[i,a,o]),v=S.useCallback(T=>{n(T)},[n]),w=S.useMemo(()=>c||d?-1:void 0,[c,d]);return C.jsx(Vc,{autoFocus:m,className:mn.SearchInput,isDisabled:c,maxLength:p,placeholder:h["Search(Placeholder)"],tabIndex:w,useValue:[(t==null?void 0:t.keyword)??"",v],RightAddon:C.jsx(Lz,{isEqual:e,resources:h,searchDown:i,searchEnter:a,searchResult:t,searchUp:o}),wrapProps:{className:mn.SearchInputWrap},onKeyDown:g})},Lz=r=>{const{isEqual:e,searchResult:t,searchUp:n,searchDown:o,searchEnter:i,resources:a}=r,c=S.useMemo(()=>!t||t.items.length<1?0:t.items.findIndex(w=>t.item&&e(w,t.item))+1,[t,e]),d=S.useMemo(()=>!t||t.items.length<1?0:t.items.length,[t]),h=S.useMemo(()=>c<2,[c]),p=S.useMemo(()=>c>=d,[c,d]),m=S.useCallback(w=>{w.stopPropagation(),!h&&n()},[n,h]),g=S.useCallback(w=>{w.stopPropagation(),!p&&o()},[o,p]),v=S.useCallback(w=>{w.stopPropagation(),i()},[i]);return C.jsx("div",{className:Ke.clsx(mn.RightAddon,"NoSelect"),children:t?C.jsxs(C.Fragment,{children:[c,"/",d,C.jsx(Yr,{isDisabled:h,onClick:m,children:C.jsx(en,{className:mn.RightAddonIcon,icon:"ArrowUp",mask:""})}),C.jsx(Yr,{isDisabled:p,onClick:g,children:C.jsx(en,{className:mn.RightAddonIcon,icon:"ArrowDown"})})]}):C.jsx(ho,{className:mn.RightAddonIcon,icon:"Search",style:{marginRight:4},tooltip:a["Search(Button)"],type:"Raw",onClick:v})})},Dz=r=>{var et;const{pk:e,selectDisabled:t,selectUnused:n,useItems:o,useExpand:i,useSelect:a,useSearch:c,showCheckbox:d,iconWidth:h=24,icons:p={noChild:"Folder",collapsed:"FolderCopy",expanded:"FolderOpen"},indents:m,isSelectMulti:g=!1,noSearch:v=!1,isDraggable:w,noSyncSearchSelect:T=!1,actionRef:A,placeholder:_,searchPredicate:R=Nz,isDisabled:D,isLoading:I,ContentRenderer:F=Oz,TreeItemRenderer:B=Tz,RightStickyAddon:H,TopRightAddon:j,TreeTopAddon:V,resources:fe,maxLength:P,autoFocus:U,TreeItemStyle:G,TreeItemClassName:Q,OverflowPadding:ae,insertBorder:ie,width:oe,searchItemClassName:ne,searchItemStyle:ye,height:te=40,treeItemTooltip:re,treeItemTooltipDelay:ge,treeItemTooltipDirection:Ae,treeItemTooltipDistance:Te,...se}=r,he=S.useMemo(()=>({...wr.ATree,...fe}),[fe]),Ce=S.useCallback((Re,rt)=>!Re||!rt?!1:e!==void 0?Array.isArray(e)?e.every(dt=>Re&&rt&&Re[dt]!==void 0&&rt[dt]!==void 0&&Ya.isEqual(Re[dt],rt[dt])):Re&&rt&&Re[e]!==void 0&&rt[e]!==void 0&&Ya.isEqual(Re[e],rt[e]):Ya.isEqual(Re,rt),[e]),qe=S.useRef(null),[Ee,Ne]=wn(o,[]),Be=S.useMemo(()=>Nc.map(Ee,Re=>Re),[Ee]),[Ve,Pe]=wn(i,[]),[Oe,Ie]=wn(a,[]),[we,$e]=wn(c,void 0),it=S.useCallback(Re=>{if(D||!Pe||Ve.some(Bt=>Ce(Bt,Re)))return;const rt=[];let dt=Re;for(;dt;){const Bt=dt;Ve.find(Yt=>Ce(Yt,Bt))||rt.push(Bt),dt=Be.find(Yt=>{var It;return(It=Yt.children)==null?void 0:It.some(me=>Ce(me,Bt))})}Pe([...Ve,...rt])},[Ve,D,Ce,Pe,Be]),at=S.useCallback(()=>{!Pe||D||Pe([...Be])},[Be,D,Pe]),_t=S.useCallback(()=>{!Pe||D||Pe([])},[Pe,D]),Ye=S.useCallback(Re=>{!Ie||D||n!=null&&n(Re)||(Ie([Re]),it(Re))},[Ie,D,n,it]),Xe=S.useCallback(Re=>{if(!$e||D)return;if(!Re||v){$e(void 0),T||Ie==null||Ie([]);return}const rt=Nc.filter(Ee,Bt=>R(Re,Bt));let dt;if(rt.find(Bt=>(we==null?void 0:we.item)&&Ce(Bt,we.item))?dt=we==null?void 0:we.item:rt.length>0&&(dt=rt[0]),$e({keyword:Re,items:rt,item:dt}),dt&&it(dt),Ie&&!T)if(g)Ie(rt);else{const Bt=rt.find(Yt=>dt&&Ce(Yt,dt));Ie(Bt?[Bt]:[])}},[Ee,D,Ce,R,$e,Ie,it,T,v,g,we]),ft=S.useRef(!1);S.useEffect(()=>{ft.current=!0},[Ee]),S.useEffect(()=>{we&&ft.current&&(Xe(we.keyword),ft.current=!1)},[Xe,we]);const mt=S.useCallback(()=>{if(!we||!$e||D)return;let Re=we.items.findIndex(rt=>we.item&&Ce(rt,we.item))-1;Re<0||($e({...we,item:we.items[Re]}),it(we.items[Re]),T||Ye(we.items[Re]))},[we,it,$e,D,Ye,Ce,T]),Fe=S.useCallback(()=>{if(!we||!$e||D)return;let Re=we.items.findIndex(rt=>we.item&&Ce(rt,we.item))+1;Re>=we.items.length||($e({...we,item:we.items[Re]}),it(we.items[Re]),T||Ye(we.items[Re]))},[we,it,D,$e,Ye,Ce,T]),Qe=S.useCallback(()=>{if(!we||!$e||D)return;let Re=we.items.findIndex(dt=>we.item&&Ce(dt,we.item));if(!T||n!=null&&n(we.items[Re])){Fe();return}if(Oe.some(dt=>we.item&&Ce(dt,we.item))){let dt=Re+1;const Bt=we.items[dt];if(dt>=we.items.length)return;$e({...we,item:Bt}),Ye(Bt)}else Ye(we.items[Re])},[we,$e,D,Oe,T,Fe,Ce,Ye,n]),[At,Nt]=S.useState(!1),Rt=S.useCallback(()=>Nt(!0),[]),Ot=S.useCallback(()=>Nt(!1),[]),Wt=S.useMemo(()=>n?Nc.map(Ee,Re=>Re).filter(Re=>!n(Re)):t?Nc.map(Ee,Re=>Re).filter(Re=>!t(Re)):Nc.map(Ee,Re=>Re),[n,t,Ee]),rr=S.useMemo(()=>!d||!g?!1:Oe.length>0&&Wt.length>Oe.length,[d,g,Oe,Wt]),or=S.useMemo(()=>!d||!g?!1:Oe.length>0&&Wt.length===Oe.length,[d,g,Oe,Wt]),hr=S.useCallback(()=>{if(!Ie||!g||D)return;const Re=Oe.filter(rt=>!(n!=null&&n(rt))&&!(t!=null&&t(rt))&&Wt.some(dt=>Ce(dt,rt)));if(Re.length>0)Ie(Oe.filter(rt=>!Re.some(dt=>Ce(rt,dt))));else{const rt=Wt.filter(dt=>!(n!=null&&n(dt))&&!(t!=null&&t(dt))&&!Oe.some(Bt=>Ce(Bt,dt)));rt.length>0&&Ie([...Oe,...rt])}},[g,D,n,t,Ie,Oe,Wt,Ce]),ur=S.useMemo(()=>{if(!d||!g||D)return"";const Re=Oe.filter(rt=>!(n!=null&&n(rt))&&!(t!=null&&t(rt))&&Wt.some(dt=>Ce(dt,rt)));if(Re.length>0)return he["deselect n"](Re.length);{const rt=Wt.filter(dt=>!(n!=null&&n(dt))&&!(t!=null&&t(dt))&&!Oe.some(Bt=>Ce(Bt,dt)));return he["select n"](rt.length)}},[n,t,D,he,d,g,Wt,Oe,Ce]),[_e,le]=S.useState(),ut=Cj(ux(cy,{activationConstraint:{distance:8}}),ux(ay)),vt=S.useRef(new Map),Ft=S.useCallback(Re=>{if(!vt.current.has(Re)){const rt=`item_${Ya.uniqueId()}`;vt.current.set(Re,rt)}return vt.current.get(Re)},[]),Pt=S.useCallback(Re=>Be.find(rt=>Ft(rt)===Re),[Be,Ft]),kt=S.useCallback(Re=>!_e||!_e.children?!1:_e.children.some(dt=>Ce(dt,Re))?!0:_e.children.some(dt=>dt.children?Nc.find(dt,Bt=>Ce(Bt,Re))!==void 0:!1),[_e,Ce]),Ht=S.useCallback(Re=>{if(!w||D)return;const rt=Pt(Re.active.id);rt&&le(rt)},[w,D,Pt]),Ze=S.useCallback((Re,rt,dt,Bt)=>{const Yt=Re.findIndex(me=>Bt(me,rt)),It=Re.findIndex(me=>Bt(me,dt));return Yt!==-1&&It!==-1?yg(Re,Yt,It):Re.map(me=>{if(!me.children)return me;const st=me.children.findIndex(dr=>Bt(dr,rt)),xt=me.children.findIndex(dr=>Bt(dr,dt));return st!==-1&&xt!==-1?{...me,children:yg(me.children,st,xt)}:me.children?{...me,children:Ze(me.children,rt,dt,Bt)}:me})},[]),lt=S.useCallback(Re=>{!w||D||!_e||!Re.over||Pt(Re.over.id)},[w,D,_e,Pt]),ht=S.useCallback(Re=>{if(!w||D||!Ne||!_e||!Re.over)return;const rt=Pt(Re.over.id);if(!rt||Ce(_e,rt)){le(void 0);return}const dt=Ze(Ee,_e,rt,Ce);Ne(dt),le(void 0)},[w,D,Ne,_e,Pt,Ce,Ee,Ze]),Ct=S.useMemo(()=>Ee.map(Re=>Ft(Re)),[Ee,Ft]);S.useEffect(()=>{var Re;d||(Re=qe.current)==null||Re.scrollTo(0,0)},[d,qe]),S.useEffect(()=>{!g&&Oe.length>1&&(Ie==null||Ie([Oe[Oe.length-1]]))},[g,Ie,Oe]),S.useEffect(()=>{A&&(A.current={expandAll:at,collapseAll:_t})},[A,at,_t]),S.useEffect(()=>{if(!t||!Ie)return;const Re=Oe.filter(rt=>!t(rt));Oe.length!==Re.length&&Ie(Re)},[t,Oe,Ie]),S.useEffect(()=>{if(!n||!Ie)return;const Re=Oe.filter(rt=>!n(rt));Oe.length!==Re.length&&Ie(Re)},[n,Oe,Ie]),S.useEffect(()=>{$e&&$e(void 0)},[$e]);const[tt,yt]=S.useState(!1);S.useEffect(()=>{yt(Re=>!Re)},[Ee]);const[Dt,Gt]=S.useState(null),ir=S.useCallback((Re,rt)=>{D||(Re.stopPropagation(),Re.preventDefault(),Gt(rt))},[D]),zt=S.useCallback((Re,rt)=>{Dt===null||D||Ce(rt,Dt)&&(Re.stopPropagation(),Re.preventDefault(),Gt(null))},[Dt,D,Ce]),vr=S.useRef(null),[Br,pr]=S.useState(!1),[pe,Me]=S.useState((et=vr.current)==null?void 0:et.scrollHeight);return S.useEffect(()=>{if(Ve.length<0)return;const Re=qe.current,rt=vr.current,dt=Re.clientHeight<rt.clientHeight;Me(dt?rt.scrollHeight:Re.clientHeight),pr(dt)},[Ve]),C.jsxs(Yr,{...se,className:Ke.clsx(se.className,mn.AWrap),isDisabled:D,children:[(!v||j)&&C.jsxs(Rn,{className:mn.ATreeHeader,children:[!v&&C.jsx(Mz,{autoFocus:U,initSearch:Xe,isDisabled:D,isEqual:Ce,isLoading:I,maxLength:P,resources:he,searchDown:Fe,searchEnter:Qe,searchResult:we,searchUp:mt}),!v&&j&&C.jsx(Nn,{w:8}),j]}),(!v||j||d&&g||w)&&C.jsx(Iv,{isLoading:I&&Ee.length!==0}),(d&&g||w)&&C.jsxs("div",{className:Ke.clsx(mn.ATreeBodyHeader,"NoSelect"),children:[d&&C.jsx(af,{className:mn.CheckBox,isDisabled:D,isIndeterminate:rr,tooltip:ur,useCheck:[+or,()=>hr()],onMouseOut:Ot,onMouseOver:Rt}),he.Items,C.jsx(Xu,{}),C.jsxs("div",{className:Ke.clsx(mn.ATreeBodyHeaderResources,"NoSelect"),style:{marginRight:Br?8:0},children:[C.jsx("span",{children:d&&he["*Click row for single select"]}),C.jsx("span",{children:w&&he["*Change order to row drag"]})]})]}),C.jsx("div",{ref:qe,className:Ke.clsx(se.className,mn.AContainer),children:C.jsxs("div",{className:mn.ATree,style:{minWidth:oe||"fit-content",marginRight:ae&&Br?8:0},children:[C.jsxs("div",{ref:vr,className:mn.ATreeBody,children:[V&&C.jsx("div",{className:mn.TreeTopAddon,children:V}),Ee.length===0?I?C.jsx(Pz,{text:he["Loading Contents..."]}):_:null,C.jsx(EH,{collisionDetection:Tj,modifiers:[OH,NH],sensors:ut,measuring:{droppable:{strategy:vf.Always}},onDragEnd:ht,onDragOver:lt,onDragStart:Ht,children:C.jsx(zH,{items:Ct,strategy:jH,children:Ee.map((Re,rt)=>C.jsx(B,{containerRef:qe,ContentRenderer:F,extIndents:m,height:te,hoverdItem:Dt,icons:p,iconWidth:h,indents:[],isChildOfDragItem:kt,isDraggable:w,isDragSrcItem:Ce(Re,_e),isEqual:Ce,isParentCheckHovered:g&&At,isParentDisabled:D,isSelectMulti:g,item:Re,itemId:Ft(Re),resources:he,RightStickyAddon:H,searchItemClassName:ne,searchItemStyle:ye,selectDisabled:t,selectUnused:n,showCheckbox:d,TreeItemClassName:Q,TreeItemRenderer:B,TreeItemStyle:G,treeItemTooltip:re,treeItemTooltipDelay:ge,treeItemTooltipDirection:Ae,treeItemTooltipDistance:Te,useExpand:[Ve,Pe],useSearch:[we,$e],useSelect:[Oe,Ie],onMouseLeave:zt,onMouseOver:ir},`${rt}${tt}`))})})]}),ie&&C.jsxs(C.Fragment,{children:[C.jsx("div",{className:mn.CoverBorder}),C.jsx("div",{className:mn.InsertBorder,style:{"--InsertBorder_height":`${te}px`,height:Br?pe:"100%"}})]})]})})]})},Oz=r=>{const{item:e}=r,t={};return ar.keys(e).forEach(n=>{n!=="children"&&(t[n]=e[n])}),JSON.stringify(t)};function Nz(r,e){return ar.some(e,(t,n)=>{var o;return(o=ar.stringify(n))==null?void 0:o.toLowerCase().includes(r.toLowerCase())})}const Pz=r=>{const{text:e}=r;return C.jsxs(Rn,{className:Ke.clsx(mn.Loader,"NoSelect"),children:[C.jsx(en,{height:40,icon:"Spinner",style:{height:40},width:40}),C.jsx(SC,{text:e})]})};var $m,Cx;function Af(){return Cx||(Cx=1,$m=TypeError),$m}const Bz={},Fz=Object.freeze(Object.defineProperty({__proto__:null,default:Bz},Symbol.toStringTag,{value:"Module"})),jz=vT(Fz);var qm,Sx;function jg(){if(Sx)return qm;Sx=1;var r=typeof Map=="function"&&Map.prototype,e=Object.getOwnPropertyDescriptor&&r?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,t=r&&e&&typeof e.get=="function"?e.get:null,n=r&&Map.prototype.forEach,o=typeof Set=="function"&&Set.prototype,i=Object.getOwnPropertyDescriptor&&o?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,a=o&&i&&typeof i.get=="function"?i.get:null,c=o&&Set.prototype.forEach,d=typeof WeakMap=="function"&&WeakMap.prototype,h=d?WeakMap.prototype.has:null,p=typeof WeakSet=="function"&&WeakSet.prototype,m=p?WeakSet.prototype.has:null,g=typeof WeakRef=="function"&&WeakRef.prototype,v=g?WeakRef.prototype.deref:null,w=Boolean.prototype.valueOf,T=Object.prototype.toString,A=Function.prototype.toString,_=String.prototype.match,R=String.prototype.slice,D=String.prototype.replace,I=String.prototype.toUpperCase,F=String.prototype.toLowerCase,B=RegExp.prototype.test,H=Array.prototype.concat,j=Array.prototype.join,V=Array.prototype.slice,fe=Math.floor,P=typeof BigInt=="function"?BigInt.prototype.valueOf:null,U=Object.getOwnPropertySymbols,G=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,Q=typeof Symbol=="function"&&typeof Symbol.iterator=="object",ae=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===Q||!0)?Symbol.toStringTag:null,ie=Object.prototype.propertyIsEnumerable,oe=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(_e){return _e.__proto__}:null);function ne(_e,le){if(_e===1/0||_e===-1/0||_e!==_e||_e&&_e>-1e3&&_e<1e3||B.call(/e/,le))return le;var ut=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof _e=="number"){var vt=_e<0?-fe(-_e):fe(_e);if(vt!==_e){var Ft=String(vt),Pt=R.call(le,Ft.length+1);return D.call(Ft,ut,"$&_")+"."+D.call(D.call(Pt,/([0-9]{3})/g,"$&_"),/_$/,"")}}return D.call(le,ut,"$&_")}var ye=jz,te=ye.custom,re=Oe(te)?te:null,ge={__proto__:null,double:'"',single:"'"},Ae={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};qm=function _e(le,ut,vt,Ft){var Pt=ut||{};if($e(Pt,"quoteStyle")&&!$e(ge,Pt.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if($e(Pt,"maxStringLength")&&(typeof Pt.maxStringLength=="number"?Pt.maxStringLength<0&&Pt.maxStringLength!==1/0:Pt.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var kt=$e(Pt,"customInspect")?Pt.customInspect:!0;if(typeof kt!="boolean"&&kt!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if($e(Pt,"indent")&&Pt.indent!==null&&Pt.indent!==" "&&!(parseInt(Pt.indent,10)===Pt.indent&&Pt.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if($e(Pt,"numericSeparator")&&typeof Pt.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var Ht=Pt.numericSeparator;if(typeof le>"u")return"undefined";if(le===null)return"null";if(typeof le=="boolean")return le?"true":"false";if(typeof le=="string")return At(le,Pt);if(typeof le=="number"){if(le===0)return 1/0/le>0?"0":"-0";var Ze=String(le);return Ht?ne(le,Ze):Ze}if(typeof le=="bigint"){var lt=String(le)+"n";return Ht?ne(le,lt):lt}var ht=typeof Pt.depth>"u"?5:Pt.depth;if(typeof vt>"u"&&(vt=0),vt>=ht&&ht>0&&typeof le=="object")return Ce(le)?"[Array]":"[Object]";var Ct=or(Pt,vt);if(typeof Ft>"u")Ft=[];else if(_t(Ft,le)>=0)return"[Circular]";function tt(It,me,st){if(me&&(Ft=V.call(Ft),Ft.push(me)),st){var xt={depth:Pt.depth};return $e(Pt,"quoteStyle")&&(xt.quoteStyle=Pt.quoteStyle),_e(It,xt,vt+1,Ft)}return _e(It,Pt,vt+1,Ft)}if(typeof le=="function"&&!Ee(le)){var yt=at(le),Dt=ur(le,tt);return"[Function"+(yt?": "+yt:" (anonymous)")+"]"+(Dt.length>0?" { "+j.call(Dt,", ")+" }":"")}if(Oe(le)){var Gt=Q?D.call(String(le),/^(Symbol\(.*\))_[^)]*$/,"$1"):G.call(le);return typeof le=="object"&&!Q?Rt(Gt):Gt}if(Qe(le)){for(var ir="<"+F.call(String(le.nodeName)),zt=le.attributes||[],vr=0;vr<zt.length;vr++)ir+=" "+zt[vr].name+"="+Te(se(zt[vr].value),"double",Pt);return ir+=">",le.childNodes&&le.childNodes.length&&(ir+="..."),ir+="</"+F.call(String(le.nodeName))+">",ir}if(Ce(le)){if(le.length===0)return"[]";var Br=ur(le,tt);return Ct&&!rr(Br)?"["+hr(Br,Ct)+"]":"[ "+j.call(Br,", ")+" ]"}if(Ne(le)){var pr=ur(le,tt);return!("cause"in Error.prototype)&&"cause"in le&&!ie.call(le,"cause")?"{ ["+String(le)+"] "+j.call(H.call("[cause]: "+tt(le.cause),pr),", ")+" }":pr.length===0?"["+String(le)+"]":"{ ["+String(le)+"] "+j.call(pr,", ")+" }"}if(typeof le=="object"&&kt){if(re&&typeof le[re]=="function"&&ye)return ye(le,{depth:ht-vt});if(kt!=="symbol"&&typeof le.inspect=="function")return le.inspect()}if(Ye(le)){var pe=[];return n&&n.call(le,function(It,me){pe.push(tt(me,le,!0)+" => "+tt(It,le))}),Wt("Map",t.call(le),pe,Ct)}if(mt(le)){var Me=[];return c&&c.call(le,function(It){Me.push(tt(It,le))}),Wt("Set",a.call(le),Me,Ct)}if(Xe(le))return Ot("WeakMap");if(Fe(le))return Ot("WeakSet");if(ft(le))return Ot("WeakRef");if(Ve(le))return Rt(tt(Number(le)));if(Ie(le))return Rt(tt(P.call(le)));if(Pe(le))return Rt(w.call(le));if(Be(le))return Rt(tt(String(le)));if(typeof window<"u"&&le===window)return"{ [object Window] }";if(typeof globalThis<"u"&&le===globalThis||typeof Di<"u"&&le===Di)return"{ [object globalThis] }";if(!qe(le)&&!Ee(le)){var et=ur(le,tt),Re=oe?oe(le)===Object.prototype:le instanceof Object||le.constructor===Object,rt=le instanceof Object?"":"null prototype",dt=!Re&&ae&&Object(le)===le&&ae in le?R.call(it(le),8,-1):rt?"Object":"",Bt=Re||typeof le.constructor!="function"?"":le.constructor.name?le.constructor.name+" ":"",Yt=Bt+(dt||rt?"["+j.call(H.call([],dt||[],rt||[]),": ")+"] ":"");return et.length===0?Yt+"{}":Ct?Yt+"{"+hr(et,Ct)+"}":Yt+"{ "+j.call(et,", ")+" }"}return String(le)};function Te(_e,le,ut){var vt=ut.quoteStyle||le,Ft=ge[vt];return Ft+_e+Ft}function se(_e){return D.call(String(_e),/"/g,""")}function he(_e){return!ae||!(typeof _e=="object"&&(ae in _e||typeof _e[ae]<"u"))}function Ce(_e){return it(_e)==="[object Array]"&&he(_e)}function qe(_e){return it(_e)==="[object Date]"&&he(_e)}function Ee(_e){return it(_e)==="[object RegExp]"&&he(_e)}function Ne(_e){return it(_e)==="[object Error]"&&he(_e)}function Be(_e){return it(_e)==="[object String]"&&he(_e)}function Ve(_e){return it(_e)==="[object Number]"&&he(_e)}function Pe(_e){return it(_e)==="[object Boolean]"&&he(_e)}function Oe(_e){if(Q)return _e&&typeof _e=="object"&&_e instanceof Symbol;if(typeof _e=="symbol")return!0;if(!_e||typeof _e!="object"||!G)return!1;try{return G.call(_e),!0}catch{}return!1}function Ie(_e){if(!_e||typeof _e!="object"||!P)return!1;try{return P.call(_e),!0}catch{}return!1}var we=Object.prototype.hasOwnProperty||function(_e){return _e in this};function $e(_e,le){return we.call(_e,le)}function it(_e){return T.call(_e)}function at(_e){if(_e.name)return _e.name;var le=_.call(A.call(_e),/^function\s*([\w$]+)/);return le?le[1]:null}function _t(_e,le){if(_e.indexOf)return _e.indexOf(le);for(var ut=0,vt=_e.length;ut<vt;ut++)if(_e[ut]===le)return ut;return-1}function Ye(_e){if(!t||!_e||typeof _e!="object")return!1;try{t.call(_e);try{a.call(_e)}catch{return!0}return _e instanceof Map}catch{}return!1}function Xe(_e){if(!h||!_e||typeof _e!="object")return!1;try{h.call(_e,h);try{m.call(_e,m)}catch{return!0}return _e instanceof WeakMap}catch{}return!1}function ft(_e){if(!v||!_e||typeof _e!="object")return!1;try{return v.call(_e),!0}catch{}return!1}function mt(_e){if(!a||!_e||typeof _e!="object")return!1;try{a.call(_e);try{t.call(_e)}catch{return!0}return _e instanceof Set}catch{}return!1}function Fe(_e){if(!m||!_e||typeof _e!="object")return!1;try{m.call(_e,m);try{h.call(_e,h)}catch{return!0}return _e instanceof WeakSet}catch{}return!1}function Qe(_e){return!_e||typeof _e!="object"?!1:typeof HTMLElement<"u"&&_e instanceof HTMLElement?!0:typeof _e.nodeName=="string"&&typeof _e.getAttribute=="function"}function At(_e,le){if(_e.length>le.maxStringLength){var ut=_e.length-le.maxStringLength,vt="... "+ut+" more character"+(ut>1?"s":"");return At(R.call(_e,0,le.maxStringLength),le)+vt}var Ft=Ae[le.quoteStyle||"single"];Ft.lastIndex=0;var Pt=D.call(D.call(_e,Ft,"\\$1"),/[\x00-\x1f]/g,Nt);return Te(Pt,"single",le)}function Nt(_e){var le=_e.charCodeAt(0),ut={8:"b",9:"t",10:"n",12:"f",13:"r"}[le];return ut?"\\"+ut:"\\x"+(le<16?"0":"")+I.call(le.toString(16))}function Rt(_e){return"Object("+_e+")"}function Ot(_e){return _e+" { ? }"}function Wt(_e,le,ut,vt){var Ft=vt?hr(ut,vt):j.call(ut,", ");return _e+" ("+le+") {"+Ft+"}"}function rr(_e){for(var le=0;le<_e.length;le++)if(_t(_e[le],`
|
364
|
+
`},xj={onDragStart(r){let{active:e}=r;return"Picked up draggable item "+e.id+"."},onDragOver(r){let{active:e,over:t}=r;return t?"Draggable item "+e.id+" was moved over droppable area "+t.id+".":"Draggable item "+e.id+" is no longer over a droppable area."},onDragEnd(r){let{active:e,over:t}=r;return t?"Draggable item "+e.id+" was dropped over droppable area "+t.id:"Draggable item "+e.id+" was dropped."},onDragCancel(r){let{active:e}=r;return"Dragging was cancelled. Draggable item "+e.id+" was dropped."}};function wj(r){let{announcements:e=xj,container:t,hiddenTextDescribedById:n,screenReaderInstructions:o=bj}=r;const{announce:i,announcement:a}=mj(),c=Vh("DndLiveRegion"),[d,h]=S.useState(!1);if(S.useEffect(()=>{h(!0)},[]),vj(S.useMemo(()=>({onDragStart(m){let{active:g}=m;i(e.onDragStart({active:g}))},onDragMove(m){let{active:g,over:v}=m;e.onDragMove&&i(e.onDragMove({active:g,over:v}))},onDragOver(m){let{active:g,over:v}=m;i(e.onDragOver({active:g,over:v}))},onDragEnd(m){let{active:g,over:v}=m;i(e.onDragEnd({active:g,over:v}))},onDragCancel(m){let{active:g,over:v}=m;i(e.onDragCancel({active:g,over:v}))}}),[i,e])),!d)return null;const p=S.createElement(S.Fragment,null,S.createElement(pj,{id:n,value:o.draggable}),S.createElement(gj,{id:c,announcement:a}));return t?Ls.createPortal(p,t):p}var So;(function(r){r.DragStart="dragStart",r.DragMove="dragMove",r.DragEnd="dragEnd",r.DragCancel="dragCancel",r.DragOver="dragOver",r.RegisterDroppable="registerDroppable",r.SetDroppableDisabled="setDroppableDisabled",r.UnregisterDroppable="unregisterDroppable"})(So||(So={}));function mg(){}function ux(r,e){return S.useMemo(()=>({sensor:r,options:e??{}}),[r,e])}function Cj(){for(var r=arguments.length,e=new Array(r),t=0;t<r;t++)e[t]=arguments[t];return S.useMemo(()=>[...e].filter(n=>n!=null),[...e])}const va=Object.freeze({x:0,y:0});function Sj(r,e){return Math.sqrt(Math.pow(r.x-e.x,2)+Math.pow(r.y-e.y,2))}function _j(r,e){let{data:{value:t}}=r,{data:{value:n}}=e;return t-n}function Aj(r,e){let{data:{value:t}}=r,{data:{value:n}}=e;return n-t}function Ej(r,e){if(!r||r.length===0)return null;const[t]=r;return t[e]}function dx(r,e,t){return e===void 0&&(e=r.left),t===void 0&&(t=r.top),{x:e+r.width*.5,y:t+r.height*.5}}const Tj=r=>{let{collisionRect:e,droppableRects:t,droppableContainers:n}=r;const o=dx(e,e.left,e.top),i=[];for(const a of n){const{id:c}=a,d=t.get(c);if(d){const h=Sj(dx(d),o);i.push({id:c,data:{droppableContainer:a,value:h}})}}return i.sort(_j)};function Rj(r,e){const t=Math.max(e.top,r.top),n=Math.max(e.left,r.left),o=Math.min(e.left+e.width,r.left+r.width),i=Math.min(e.top+e.height,r.top+r.height),a=o-n,c=i-t;if(n<o&&t<i){const d=e.width*e.height,h=r.width*r.height,p=a*c,m=p/(d+h-p);return Number(m.toFixed(4))}return 0}const kj=r=>{let{collisionRect:e,droppableRects:t,droppableContainers:n}=r;const o=[];for(const i of n){const{id:a}=i,c=t.get(a);if(c){const d=Rj(c,e);d>0&&o.push({id:a,data:{droppableContainer:i,value:d}})}}return o.sort(Aj)};function Ij(r,e,t){return{...r,scaleX:e&&t?e.width/t.width:1,scaleY:e&&t?e.height/t.height:1}}function cS(r,e){return r&&e?{x:r.left-e.left,y:r.top-e.top}:va}function Mj(r){return function(t){for(var n=arguments.length,o=new Array(n>1?n-1:0),i=1;i<n;i++)o[i-1]=arguments[i];return o.reduce((a,c)=>({...a,top:a.top+r*c.y,bottom:a.bottom+r*c.y,left:a.left+r*c.x,right:a.right+r*c.x}),{...t})}}const Lj=Mj(1);function Dj(r){if(r.startsWith("matrix3d(")){const e=r.slice(9,-1).split(/, /);return{x:+e[12],y:+e[13],scaleX:+e[0],scaleY:+e[5]}}else if(r.startsWith("matrix(")){const e=r.slice(7,-1).split(/, /);return{x:+e[4],y:+e[5],scaleX:+e[0],scaleY:+e[3]}}return null}function Oj(r,e,t){const n=Dj(e);if(!n)return r;const{scaleX:o,scaleY:i,x:a,y:c}=n,d=r.left-a-(1-o)*parseFloat(t),h=r.top-c-(1-i)*parseFloat(t.slice(t.indexOf(" ")+1)),p=o?r.width/o:r.width,m=i?r.height/i:r.height;return{width:p,height:m,top:h,right:d+p,bottom:h+m,left:d}}const Nj={ignoreTransform:!1};function _f(r,e){e===void 0&&(e=Nj);let t=r.getBoundingClientRect();if(e.ignoreTransform){const{transform:h,transformOrigin:p}=Ni(r).getComputedStyle(r);h&&(t=Oj(t,h,p))}const{top:n,left:o,width:i,height:a,bottom:c,right:d}=t;return{top:n,left:o,width:i,height:a,bottom:c,right:d}}function fx(r){return _f(r,{ignoreTransform:!0})}function Pj(r){const e=r.innerWidth,t=r.innerHeight;return{top:0,left:0,right:e,bottom:t,width:e,height:t}}function Bj(r,e){return e===void 0&&(e=Ni(r).getComputedStyle(r)),e.position==="fixed"}function Fj(r,e){e===void 0&&(e=Ni(r).getComputedStyle(r));const t=/(auto|scroll|overlay)/;return["overflow","overflowX","overflowY"].some(o=>{const i=e[o];return typeof i=="string"?t.test(i):!1})}function iy(r,e){const t=[];function n(o){if(e!=null&&t.length>=e||!o)return t;if(ry(o)&&o.scrollingElement!=null&&!t.includes(o.scrollingElement))return t.push(o.scrollingElement),t;if(!Uh(o)||sS(o)||t.includes(o))return t;const i=Ni(r).getComputedStyle(o);return o!==r&&Fj(o,i)&&t.push(o),Bj(o,i)?t:n(o.parentNode)}return r?n(r):t}function uS(r){const[e]=iy(r,1);return e??null}function jm(r){return!Pg||!r?null:Cf(r)?r:ty(r)?ry(r)||r===Sf(r).scrollingElement?window:Uh(r)?r:null:null}function dS(r){return Cf(r)?r.scrollX:r.scrollLeft}function fS(r){return Cf(r)?r.scrollY:r.scrollTop}function gv(r){return{x:dS(r),y:fS(r)}}var Mo;(function(r){r[r.Forward=1]="Forward",r[r.Backward=-1]="Backward"})(Mo||(Mo={}));function hS(r){return!Pg||!r?!1:r===document.scrollingElement}function pS(r){const e={x:0,y:0},t=hS(r)?{height:window.innerHeight,width:window.innerWidth}:{height:r.clientHeight,width:r.clientWidth},n={x:r.scrollWidth-t.width,y:r.scrollHeight-t.height},o=r.scrollTop<=e.y,i=r.scrollLeft<=e.x,a=r.scrollTop>=n.y,c=r.scrollLeft>=n.x;return{isTop:o,isLeft:i,isBottom:a,isRight:c,maxScroll:n,minScroll:e}}const jj={x:.2,y:.2};function Hj(r,e,t,n,o){let{top:i,left:a,right:c,bottom:d}=t;n===void 0&&(n=10),o===void 0&&(o=jj);const{isTop:h,isBottom:p,isLeft:m,isRight:g}=pS(r),v={x:0,y:0},w={x:0,y:0},T={height:e.height*o.y,width:e.width*o.x};return!h&&i<=e.top+T.height?(v.y=Mo.Backward,w.y=n*Math.abs((e.top+T.height-i)/T.height)):!p&&d>=e.bottom-T.height&&(v.y=Mo.Forward,w.y=n*Math.abs((e.bottom-T.height-d)/T.height)),!g&&c>=e.right-T.width?(v.x=Mo.Forward,w.x=n*Math.abs((e.right-T.width-c)/T.width)):!m&&a<=e.left+T.width&&(v.x=Mo.Backward,w.x=n*Math.abs((e.left+T.width-a)/T.width)),{direction:v,speed:w}}function zj(r){if(r===document.scrollingElement){const{innerWidth:i,innerHeight:a}=window;return{top:0,left:0,right:i,bottom:a,width:i,height:a}}const{top:e,left:t,right:n,bottom:o}=r.getBoundingClientRect();return{top:e,left:t,right:n,bottom:o,width:r.clientWidth,height:r.clientHeight}}function gS(r){return r.reduce((e,t)=>of(e,gv(t)),va)}function $j(r){return r.reduce((e,t)=>e+dS(t),0)}function qj(r){return r.reduce((e,t)=>e+fS(t),0)}function Uj(r,e){if(e===void 0&&(e=_f),!r)return;const{top:t,left:n,bottom:o,right:i}=e(r);uS(r)&&(o<=0||i<=0||t>=window.innerHeight||n>=window.innerWidth)&&r.scrollIntoView({block:"center",inline:"center"})}const Wj=[["x",["left","right"],$j],["y",["top","bottom"],qj]];class sy{constructor(e,t){this.rect=void 0,this.width=void 0,this.height=void 0,this.top=void 0,this.bottom=void 0,this.right=void 0,this.left=void 0;const n=iy(t),o=gS(n);this.rect={...e},this.width=e.width,this.height=e.height;for(const[i,a,c]of Wj)for(const d of a)Object.defineProperty(this,d,{get:()=>{const h=c(n),p=o[i]-h;return this.rect[d]+p},enumerable:!0});Object.defineProperty(this,"rect",{enumerable:!1})}}class mh{constructor(e){this.target=void 0,this.listeners=[],this.removeAll=()=>{this.listeners.forEach(t=>{var n;return(n=this.target)==null?void 0:n.removeEventListener(...t)})},this.target=e}add(e,t,n){var o;(o=this.target)==null||o.addEventListener(e,t,n),this.listeners.push([e,t,n])}}function Vj(r){const{EventTarget:e}=Ni(r);return r instanceof e?r:Sf(r)}function Hm(r,e){const t=Math.abs(r.x),n=Math.abs(r.y);return typeof e=="number"?Math.sqrt(t**2+n**2)>e:"x"in e&&"y"in e?t>e.x&&n>e.y:"x"in e?t>e.x:"y"in e?n>e.y:!1}var Rs;(function(r){r.Click="click",r.DragStart="dragstart",r.Keydown="keydown",r.ContextMenu="contextmenu",r.Resize="resize",r.SelectionChange="selectionchange",r.VisibilityChange="visibilitychange"})(Rs||(Rs={}));function hx(r){r.preventDefault()}function Gj(r){r.stopPropagation()}var un;(function(r){r.Space="Space",r.Down="ArrowDown",r.Right="ArrowRight",r.Left="ArrowLeft",r.Up="ArrowUp",r.Esc="Escape",r.Enter="Enter",r.Tab="Tab"})(un||(un={}));const mS={start:[un.Space,un.Enter],cancel:[un.Esc],end:[un.Space,un.Enter,un.Tab]},Yj=(r,e)=>{let{currentCoordinates:t}=e;switch(r.code){case un.Right:return{...t,x:t.x+25};case un.Left:return{...t,x:t.x-25};case un.Down:return{...t,y:t.y+25};case un.Up:return{...t,y:t.y-25}}};class ay{constructor(e){this.props=void 0,this.autoScrollEnabled=!1,this.referenceCoordinates=void 0,this.listeners=void 0,this.windowListeners=void 0,this.props=e;const{event:{target:t}}=e;this.props=e,this.listeners=new mh(Sf(t)),this.windowListeners=new mh(Ni(t)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(Rs.Resize,this.handleCancel),this.windowListeners.add(Rs.VisibilityChange,this.handleCancel),setTimeout(()=>this.listeners.add(Rs.Keydown,this.handleKeyDown))}handleStart(){const{activeNode:e,onStart:t}=this.props,n=e.node.current;n&&Uj(n),t(va)}handleKeyDown(e){if(oy(e)){const{active:t,context:n,options:o}=this.props,{keyboardCodes:i=mS,coordinateGetter:a=Yj,scrollBehavior:c="smooth"}=o,{code:d}=e;if(i.end.includes(d)){this.handleEnd(e);return}if(i.cancel.includes(d)){this.handleCancel(e);return}const{collisionRect:h}=n.current,p=h?{x:h.left,y:h.top}:va;this.referenceCoordinates||(this.referenceCoordinates=p);const m=a(e,{active:t,context:n.current,currentCoordinates:p});if(m){const g=gg(m,p),v={x:0,y:0},{scrollableAncestors:w}=n.current;for(const T of w){const A=e.code,{isTop:_,isRight:R,isLeft:D,isBottom:I,maxScroll:F,minScroll:B}=pS(T),H=zj(T),j={x:Math.min(A===un.Right?H.right-H.width/2:H.right,Math.max(A===un.Right?H.left:H.left+H.width/2,m.x)),y:Math.min(A===un.Down?H.bottom-H.height/2:H.bottom,Math.max(A===un.Down?H.top:H.top+H.height/2,m.y))},V=A===un.Right&&!R||A===un.Left&&!D,fe=A===un.Down&&!I||A===un.Up&&!_;if(V&&j.x!==m.x){const P=T.scrollLeft+g.x,U=A===un.Right&&P<=F.x||A===un.Left&&P>=B.x;if(U&&!g.y){T.scrollTo({left:P,behavior:c});return}U?v.x=T.scrollLeft-P:v.x=A===un.Right?T.scrollLeft-F.x:T.scrollLeft-B.x,v.x&&T.scrollBy({left:-v.x,behavior:c});break}else if(fe&&j.y!==m.y){const P=T.scrollTop+g.y,U=A===un.Down&&P<=F.y||A===un.Up&&P>=B.y;if(U&&!g.x){T.scrollTo({top:P,behavior:c});return}U?v.y=T.scrollTop-P:v.y=A===un.Down?T.scrollTop-F.y:T.scrollTop-B.y,v.y&&T.scrollBy({top:-v.y,behavior:c});break}}this.handleMove(e,of(gg(m,this.referenceCoordinates),v))}}}handleMove(e,t){const{onMove:n}=this.props;e.preventDefault(),n(t)}handleEnd(e){const{onEnd:t}=this.props;e.preventDefault(),this.detach(),t()}handleCancel(e){const{onCancel:t}=this.props;e.preventDefault(),this.detach(),t()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll()}}ay.activators=[{eventName:"onKeyDown",handler:(r,e,t)=>{let{keyboardCodes:n=mS,onActivation:o}=e,{active:i}=t;const{code:a}=r.nativeEvent;if(n.start.includes(a)){const c=i.activatorNode.current;return c&&r.target!==c?!1:(r.preventDefault(),o==null||o({event:r.nativeEvent}),!0)}return!1}}];function px(r){return!!(r&&"distance"in r)}function gx(r){return!!(r&&"delay"in r)}class ly{constructor(e,t,n){var o;n===void 0&&(n=Vj(e.event.target)),this.props=void 0,this.events=void 0,this.autoScrollEnabled=!0,this.document=void 0,this.activated=!1,this.initialCoordinates=void 0,this.timeoutId=null,this.listeners=void 0,this.documentListeners=void 0,this.windowListeners=void 0,this.props=e,this.events=t;const{event:i}=e,{target:a}=i;this.props=e,this.events=t,this.document=Sf(a),this.documentListeners=new mh(this.document),this.listeners=new mh(n),this.windowListeners=new mh(Ni(a)),this.initialCoordinates=(o=pv(i))!=null?o:va,this.handleStart=this.handleStart.bind(this),this.handleMove=this.handleMove.bind(this),this.handleEnd=this.handleEnd.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleKeydown=this.handleKeydown.bind(this),this.removeTextSelection=this.removeTextSelection.bind(this),this.attach()}attach(){const{events:e,props:{options:{activationConstraint:t,bypassActivationConstraint:n}}}=this;if(this.listeners.add(e.move.name,this.handleMove,{passive:!1}),this.listeners.add(e.end.name,this.handleEnd),e.cancel&&this.listeners.add(e.cancel.name,this.handleCancel),this.windowListeners.add(Rs.Resize,this.handleCancel),this.windowListeners.add(Rs.DragStart,hx),this.windowListeners.add(Rs.VisibilityChange,this.handleCancel),this.windowListeners.add(Rs.ContextMenu,hx),this.documentListeners.add(Rs.Keydown,this.handleKeydown),t){if(n!=null&&n({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if(gx(t)){this.timeoutId=setTimeout(this.handleStart,t.delay),this.handlePending(t);return}if(px(t)){this.handlePending(t);return}}this.handleStart()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll(),setTimeout(this.documentListeners.removeAll,50),this.timeoutId!==null&&(clearTimeout(this.timeoutId),this.timeoutId=null)}handlePending(e,t){const{active:n,onPending:o}=this.props;o(n,e,this.initialCoordinates,t)}handleStart(){const{initialCoordinates:e}=this,{onStart:t}=this.props;e&&(this.activated=!0,this.documentListeners.add(Rs.Click,Gj,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(Rs.SelectionChange,this.removeTextSelection),t(e))}handleMove(e){var t;const{activated:n,initialCoordinates:o,props:i}=this,{onMove:a,options:{activationConstraint:c}}=i;if(!o)return;const d=(t=pv(e))!=null?t:va,h=gg(o,d);if(!n&&c){if(px(c)){if(c.tolerance!=null&&Hm(h,c.tolerance))return this.handleCancel();if(Hm(h,c.distance))return this.handleStart()}if(gx(c)&&Hm(h,c.tolerance))return this.handleCancel();this.handlePending(c,h);return}e.cancelable&&e.preventDefault(),a(d)}handleEnd(){const{onAbort:e,onEnd:t}=this.props;this.detach(),this.activated||e(this.props.active),t()}handleCancel(){const{onAbort:e,onCancel:t}=this.props;this.detach(),this.activated||e(this.props.active),t()}handleKeydown(e){e.code===un.Esc&&this.handleCancel()}removeTextSelection(){var e;(e=this.document.getSelection())==null||e.removeAllRanges()}}const Zj={cancel:{name:"pointercancel"},move:{name:"pointermove"},end:{name:"pointerup"}};class cy extends ly{constructor(e){const{event:t}=e,n=Sf(t.target);super(e,Zj,n)}}cy.activators=[{eventName:"onPointerDown",handler:(r,e)=>{let{nativeEvent:t}=r,{onActivation:n}=e;return!t.isPrimary||t.button!==0?!1:(n==null||n({event:t}),!0)}}];const Kj={move:{name:"mousemove"},end:{name:"mouseup"}};var mv;(function(r){r[r.RightClick=2]="RightClick"})(mv||(mv={}));class Xj extends ly{constructor(e){super(e,Kj,Sf(e.event.target))}}Xj.activators=[{eventName:"onMouseDown",handler:(r,e)=>{let{nativeEvent:t}=r,{onActivation:n}=e;return t.button===mv.RightClick?!1:(n==null||n({event:t}),!0)}}];const zm={cancel:{name:"touchcancel"},move:{name:"touchmove"},end:{name:"touchend"}};class Jj extends ly{constructor(e){super(e,zm)}static setup(){return window.addEventListener(zm.move.name,e,{capture:!1,passive:!1}),function(){window.removeEventListener(zm.move.name,e)};function e(){}}}Jj.activators=[{eventName:"onTouchStart",handler:(r,e)=>{let{nativeEvent:t}=r,{onActivation:n}=e;const{touches:o}=t;return o.length>1?!1:(n==null||n({event:t}),!0)}}];var vh;(function(r){r[r.Pointer=0]="Pointer",r[r.DraggableRect=1]="DraggableRect"})(vh||(vh={}));var vg;(function(r){r[r.TreeOrder=0]="TreeOrder",r[r.ReversedTreeOrder=1]="ReversedTreeOrder"})(vg||(vg={}));function Qj(r){let{acceleration:e,activator:t=vh.Pointer,canScroll:n,draggingRect:o,enabled:i,interval:a=5,order:c=vg.TreeOrder,pointerCoordinates:d,scrollableAncestors:h,scrollableAncestorRects:p,delta:m,threshold:g}=r;const v=tH({delta:m,disabled:!i}),[w,T]=cj(),A=S.useRef({x:0,y:0}),_=S.useRef({x:0,y:0}),R=S.useMemo(()=>{switch(t){case vh.Pointer:return d?{top:d.y,bottom:d.y,left:d.x,right:d.x}:null;case vh.DraggableRect:return o}},[t,o,d]),D=S.useRef(null),I=S.useCallback(()=>{const B=D.current;if(!B)return;const H=A.current.x*_.current.x,j=A.current.y*_.current.y;B.scrollBy(H,j)},[]),F=S.useMemo(()=>c===vg.TreeOrder?[...h].reverse():h,[c,h]);S.useEffect(()=>{if(!i||!h.length||!R){T();return}for(const B of F){if((n==null?void 0:n(B))===!1)continue;const H=h.indexOf(B),j=p[H];if(!j)continue;const{direction:V,speed:fe}=Hj(B,j,R,e,g);for(const P of["x","y"])v[P][V[P]]||(fe[P]=0,V[P]=0);if(fe.x>0||fe.y>0){T(),D.current=B,w(I,a),A.current=fe,_.current=V;return}}A.current={x:0,y:0},_.current={x:0,y:0},T()},[e,I,n,T,i,a,JSON.stringify(R),JSON.stringify(v),w,h,F,p,JSON.stringify(g)])}const eH={x:{[Mo.Backward]:!1,[Mo.Forward]:!1},y:{[Mo.Backward]:!1,[Mo.Forward]:!1}};function tH(r){let{delta:e,disabled:t}=r;const n=hv(e);return Wh(o=>{if(t||!n||!o)return eH;const i={x:Math.sign(e.x-n.x),y:Math.sign(e.y-n.y)};return{x:{[Mo.Backward]:o.x[Mo.Backward]||i.x===-1,[Mo.Forward]:o.x[Mo.Forward]||i.x===1},y:{[Mo.Backward]:o.y[Mo.Backward]||i.y===-1,[Mo.Forward]:o.y[Mo.Forward]||i.y===1}}},[t,e,n])}function rH(r,e){const t=e!=null?r.get(e):void 0,n=t?t.node.current:null;return Wh(o=>{var i;return e==null?null:(i=n??o)!=null?i:null},[n,e])}function nH(r,e){return S.useMemo(()=>r.reduce((t,n)=>{const{sensor:o}=n,i=o.activators.map(a=>({eventName:a.eventName,handler:e(a.handler,n)}));return[...t,...i]},[]),[r,e])}var vf;(function(r){r[r.Always=0]="Always",r[r.BeforeDragging=1]="BeforeDragging",r[r.WhileDragging=2]="WhileDragging"})(vf||(vf={}));var vv;(function(r){r.Optimized="optimized"})(vv||(vv={}));const mx=new Map;function oH(r,e){let{dragging:t,dependencies:n,config:o}=e;const[i,a]=S.useState(null),{frequency:c,measure:d,strategy:h}=o,p=S.useRef(r),m=A(),g=Nh(m),v=S.useCallback(function(_){_===void 0&&(_=[]),!g.current&&a(R=>R===null?_:R.concat(_.filter(D=>!R.includes(D))))},[g]),w=S.useRef(null),T=Wh(_=>{if(m&&!t)return mx;if(!_||_===mx||p.current!==r||i!=null){const R=new Map;for(let D of r){if(!D)continue;if(i&&i.length>0&&!i.includes(D.id)&&D.rect.current){R.set(D.id,D.rect.current);continue}const I=D.node.current,F=I?new sy(d(I),I):null;D.rect.current=F,F&&R.set(D.id,F)}return R}return _},[r,i,t,m,d]);return S.useEffect(()=>{p.current=r},[r]),S.useEffect(()=>{m||v()},[t,m]),S.useEffect(()=>{i&&i.length>0&&a(null)},[JSON.stringify(i)]),S.useEffect(()=>{m||typeof c!="number"||w.current!==null||(w.current=setTimeout(()=>{v(),w.current=null},c))},[c,m,v,...n]),{droppableRects:T,measureDroppableContainers:v,measuringScheduled:i!=null};function A(){switch(h){case vf.Always:return!1;case vf.BeforeDragging:return t;default:return!t}}}function vS(r,e){return Wh(t=>r?t||(typeof e=="function"?e(r):r):null,[e,r])}function iH(r,e){return vS(r,e)}function sH(r){let{callback:e,disabled:t}=r;const n=ny(e),o=S.useMemo(()=>{if(t||typeof window>"u"||typeof window.MutationObserver>"u")return;const{MutationObserver:i}=window;return new i(n)},[n,t]);return S.useEffect(()=>()=>o==null?void 0:o.disconnect(),[o]),o}function Bg(r){let{callback:e,disabled:t}=r;const n=ny(e),o=S.useMemo(()=>{if(t||typeof window>"u"||typeof window.ResizeObserver>"u")return;const{ResizeObserver:i}=window;return new i(n)},[t]);return S.useEffect(()=>()=>o==null?void 0:o.disconnect(),[o]),o}function aH(r){return new sy(_f(r),r)}function vx(r,e,t){e===void 0&&(e=aH);const[n,o]=S.useState(null);function i(){o(d=>{if(!r)return null;if(r.isConnected===!1){var h;return(h=d??t)!=null?h:null}const p=e(r);return JSON.stringify(d)===JSON.stringify(p)?d:p})}const a=sH({callback(d){if(r)for(const h of d){const{type:p,target:m}=h;if(p==="childList"&&m instanceof HTMLElement&&m.contains(r)){i();break}}}}),c=Bg({callback:i});return ol(()=>{i(),r?(c==null||c.observe(r),a==null||a.observe(document.body,{childList:!0,subtree:!0})):(c==null||c.disconnect(),a==null||a.disconnect())},[r]),n}function lH(r){const e=vS(r);return cS(r,e)}const yx=[];function cH(r){const e=S.useRef(r),t=Wh(n=>r?n&&n!==yx&&r&&e.current&&r.parentNode===e.current.parentNode?n:iy(r):yx,[r]);return S.useEffect(()=>{e.current=r},[r]),t}function uH(r){const[e,t]=S.useState(null),n=S.useRef(r),o=S.useCallback(i=>{const a=jm(i.target);a&&t(c=>c?(c.set(a,gv(a)),new Map(c)):null)},[]);return S.useEffect(()=>{const i=n.current;if(r!==i){a(i);const c=r.map(d=>{const h=jm(d);return h?(h.addEventListener("scroll",o,{passive:!0}),[h,gv(h)]):null}).filter(d=>d!=null);t(c.length?new Map(c):null),n.current=r}return()=>{a(r),a(i)};function a(c){c.forEach(d=>{const h=jm(d);h==null||h.removeEventListener("scroll",o)})}},[o,r]),S.useMemo(()=>r.length?e?Array.from(e.values()).reduce((i,a)=>of(i,a),va):gS(r):va,[r,e])}function bx(r,e){e===void 0&&(e=[]);const t=S.useRef(null);return S.useEffect(()=>{t.current=null},e),S.useEffect(()=>{const n=r!==va;n&&!t.current&&(t.current=r),!n&&t.current&&(t.current=null)},[r]),t.current?gg(r,t.current):va}function dH(r){S.useEffect(()=>{if(!Pg)return;const e=r.map(t=>{let{sensor:n}=t;return n.setup==null?void 0:n.setup()});return()=>{for(const t of e)t==null||t()}},r.map(e=>{let{sensor:t}=e;return t}))}function fH(r,e){return S.useMemo(()=>r.reduce((t,n)=>{let{eventName:o,handler:i}=n;return t[o]=a=>{i(a,e)},t},{}),[r,e])}function yS(r){return S.useMemo(()=>r?Pj(r):null,[r])}const xx=[];function hH(r,e){e===void 0&&(e=_f);const[t]=r,n=yS(t?Ni(t):null),[o,i]=S.useState(xx);function a(){i(()=>r.length?r.map(d=>hS(d)?n:new sy(e(d),d)):xx)}const c=Bg({callback:a});return ol(()=>{c==null||c.disconnect(),a(),r.forEach(d=>c==null?void 0:c.observe(d))},[r]),o}function pH(r){if(!r)return null;if(r.children.length>1)return r;const e=r.children[0];return Uh(e)?e:r}function gH(r){let{measure:e}=r;const[t,n]=S.useState(null),o=S.useCallback(h=>{for(const{target:p}of h)if(Uh(p)){n(m=>{const g=e(p);return m?{...m,width:g.width,height:g.height}:g});break}},[e]),i=Bg({callback:o}),a=S.useCallback(h=>{const p=pH(h);i==null||i.disconnect(),p&&(i==null||i.observe(p)),n(p?e(p):null)},[e,i]),[c,d]=pg(a);return S.useMemo(()=>({nodeRef:c,rect:t,setRef:d}),[t,c,d])}const mH=[{sensor:cy,options:{}},{sensor:ay,options:{}}],vH={current:{}},Zp={draggable:{measure:fx},droppable:{measure:fx,strategy:vf.WhileDragging,frequency:vv.Optimized},dragOverlay:{measure:_f}};class yh extends Map{get(e){var t;return e!=null&&(t=super.get(e))!=null?t:void 0}toArray(){return Array.from(this.values())}getEnabled(){return this.toArray().filter(e=>{let{disabled:t}=e;return!t})}getNodeFor(e){var t,n;return(t=(n=this.get(e))==null?void 0:n.node.current)!=null?t:void 0}}const yH={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new yh,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:mg},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:Zp,measureDroppableContainers:mg,windowRect:null,measuringScheduled:!1},bH={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:""},dispatch:mg,draggableNodes:new Map,over:null,measureDroppableContainers:mg},Fg=S.createContext(bH),bS=S.createContext(yH);function xH(){return{draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new yh}}}function wH(r,e){switch(e.type){case So.DragStart:return{...r,draggable:{...r.draggable,initialCoordinates:e.initialCoordinates,active:e.active}};case So.DragMove:return r.draggable.active==null?r:{...r,draggable:{...r.draggable,translate:{x:e.coordinates.x-r.draggable.initialCoordinates.x,y:e.coordinates.y-r.draggable.initialCoordinates.y}}};case So.DragEnd:case So.DragCancel:return{...r,draggable:{...r.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case So.RegisterDroppable:{const{element:t}=e,{id:n}=t,o=new yh(r.droppable.containers);return o.set(n,t),{...r,droppable:{...r.droppable,containers:o}}}case So.SetDroppableDisabled:{const{id:t,key:n,disabled:o}=e,i=r.droppable.containers.get(t);if(!i||n!==i.key)return r;const a=new yh(r.droppable.containers);return a.set(t,{...i,disabled:o}),{...r,droppable:{...r.droppable,containers:a}}}case So.UnregisterDroppable:{const{id:t,key:n}=e,o=r.droppable.containers.get(t);if(!o||n!==o.key)return r;const i=new yh(r.droppable.containers);return i.delete(t),{...r,droppable:{...r.droppable,containers:i}}}default:return r}}function CH(r){let{disabled:e}=r;const{active:t,activatorEvent:n,draggableNodes:o}=S.useContext(Fg),i=hv(n),a=hv(t==null?void 0:t.id);return S.useEffect(()=>{if(!e&&!n&&i&&a!=null){if(!oy(i)||document.activeElement===i.target)return;const c=o.get(a);if(!c)return;const{activatorNode:d,node:h}=c;if(!d.current&&!h.current)return;requestAnimationFrame(()=>{for(const p of[d.current,h.current]){if(!p)continue;const m=fj(p);if(m){m.focus();break}}})}},[n,e,o,a,i]),null}function SH(r,e){let{transform:t,...n}=e;return r!=null&&r.length?r.reduce((o,i)=>i({transform:o,...n}),t):t}function _H(r){return S.useMemo(()=>({draggable:{...Zp.draggable,...r==null?void 0:r.draggable},droppable:{...Zp.droppable,...r==null?void 0:r.droppable},dragOverlay:{...Zp.dragOverlay,...r==null?void 0:r.dragOverlay}}),[r==null?void 0:r.draggable,r==null?void 0:r.droppable,r==null?void 0:r.dragOverlay])}function AH(r){let{activeNode:e,measure:t,initialRect:n,config:o=!0}=r;const i=S.useRef(!1),{x:a,y:c}=typeof o=="boolean"?{x:o,y:o}:o;ol(()=>{if(!a&&!c||!e){i.current=!1;return}if(i.current||!n)return;const h=e==null?void 0:e.node.current;if(!h||h.isConnected===!1)return;const p=t(h),m=cS(p,n);if(a||(m.x=0),c||(m.y=0),i.current=!0,Math.abs(m.x)>0||Math.abs(m.y)>0){const g=uS(h);g&&g.scrollBy({top:m.y,left:m.x})}},[e,a,c,n,t])}const xS=S.createContext({...va,scaleX:1,scaleY:1});var Oc;(function(r){r[r.Uninitialized=0]="Uninitialized",r[r.Initializing=1]="Initializing",r[r.Initialized=2]="Initialized"})(Oc||(Oc={}));const EH=S.memo(function(e){var t,n,o,i;let{id:a,accessibility:c,autoScroll:d=!0,children:h,sensors:p=mH,collisionDetection:m=kj,measuring:g,modifiers:v,...w}=e;const T=S.useReducer(wH,void 0,xH),[A,_]=T,[R,D]=yj(),[I,F]=S.useState(Oc.Uninitialized),B=I===Oc.Initialized,{draggable:{active:H,nodes:j,translate:V},droppable:{containers:fe}}=A,P=H!=null?j.get(H):null,U=S.useRef({initial:null,translated:null}),G=S.useMemo(()=>{var kt;return H!=null?{id:H,data:(kt=P==null?void 0:P.data)!=null?kt:vH,rect:U}:null},[H,P]),Q=S.useRef(null),[ae,ie]=S.useState(null),[oe,ne]=S.useState(null),ye=Nh(w,Object.values(w)),te=Vh("DndDescribedBy",a),re=S.useMemo(()=>fe.getEnabled(),[fe]),ge=_H(g),{droppableRects:Ae,measureDroppableContainers:Te,measuringScheduled:se}=oH(re,{dragging:B,dependencies:[V.x,V.y],config:ge.droppable}),he=rH(j,H),Ce=S.useMemo(()=>oe?pv(oe):null,[oe]),qe=Pt(),Ee=iH(he,ge.draggable.measure);AH({activeNode:H!=null?j.get(H):null,config:qe.layoutShiftCompensation,initialRect:Ee,measure:ge.draggable.measure});const Ne=vx(he,ge.draggable.measure,Ee),Be=vx(he?he.parentElement:null),Ve=S.useRef({activatorEvent:null,active:null,activeNode:he,collisionRect:null,collisions:null,droppableRects:Ae,draggableNodes:j,draggingNode:null,draggingNodeRect:null,droppableContainers:fe,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),Pe=fe.getNodeFor((t=Ve.current.over)==null?void 0:t.id),Oe=gH({measure:ge.dragOverlay.measure}),Ie=(n=Oe.nodeRef.current)!=null?n:he,we=B?(o=Oe.rect)!=null?o:Ne:null,$e=!!(Oe.nodeRef.current&&Oe.rect),it=lH($e?null:Ne),at=yS(Ie?Ni(Ie):null),_t=cH(B?Pe??he:null),Ye=hH(_t),Xe=SH(v,{transform:{x:V.x-it.x,y:V.y-it.y,scaleX:1,scaleY:1},activatorEvent:oe,active:G,activeNodeRect:Ne,containerNodeRect:Be,draggingNodeRect:we,over:Ve.current.over,overlayNodeRect:Oe.rect,scrollableAncestors:_t,scrollableAncestorRects:Ye,windowRect:at}),ft=Ce?of(Ce,V):null,mt=uH(_t),Fe=bx(mt),Qe=bx(mt,[Ne]),At=of(Xe,Fe),Nt=we?Lj(we,Xe):null,Rt=G&&Nt?m({active:G,collisionRect:Nt,droppableRects:Ae,droppableContainers:re,pointerCoordinates:ft}):null,Ot=Ej(Rt,"id"),[Wt,rr]=S.useState(null),or=$e?Xe:of(Xe,Qe),hr=Ij(or,(i=Wt==null?void 0:Wt.rect)!=null?i:null,Ne),ur=S.useRef(null),_e=S.useCallback((kt,Ht)=>{let{sensor:Ze,options:lt}=Ht;if(Q.current==null)return;const ht=j.get(Q.current);if(!ht)return;const Ct=kt.nativeEvent,tt=new Ze({active:Q.current,activeNode:ht,event:Ct,options:lt,context:Ve,onAbort(Dt){if(!j.get(Dt))return;const{onDragAbort:ir}=ye.current,zt={id:Dt};ir==null||ir(zt),R({type:"onDragAbort",event:zt})},onPending(Dt,Gt,ir,zt){if(!j.get(Dt))return;const{onDragPending:Br}=ye.current,pr={id:Dt,constraint:Gt,initialCoordinates:ir,offset:zt};Br==null||Br(pr),R({type:"onDragPending",event:pr})},onStart(Dt){const Gt=Q.current;if(Gt==null)return;const ir=j.get(Gt);if(!ir)return;const{onDragStart:zt}=ye.current,vr={activatorEvent:Ct,active:{id:Gt,data:ir.data,rect:U}};Ls.unstable_batchedUpdates(()=>{zt==null||zt(vr),F(Oc.Initializing),_({type:So.DragStart,initialCoordinates:Dt,active:Gt}),R({type:"onDragStart",event:vr}),ie(ur.current),ne(Ct)})},onMove(Dt){_({type:So.DragMove,coordinates:Dt})},onEnd:yt(So.DragEnd),onCancel:yt(So.DragCancel)});ur.current=tt;function yt(Dt){return async function(){const{active:ir,collisions:zt,over:vr,scrollAdjustedTranslate:Br}=Ve.current;let pr=null;if(ir&&Br){const{cancelDrop:pe}=ye.current;pr={activatorEvent:Ct,active:ir,collisions:zt,delta:Br,over:vr},Dt===So.DragEnd&&typeof pe=="function"&&await Promise.resolve(pe(pr))&&(Dt=So.DragCancel)}Q.current=null,Ls.unstable_batchedUpdates(()=>{_({type:Dt}),F(Oc.Uninitialized),rr(null),ie(null),ne(null),ur.current=null;const pe=Dt===So.DragEnd?"onDragEnd":"onDragCancel";if(pr){const Me=ye.current[pe];Me==null||Me(pr),R({type:pe,event:pr})}})}}},[j]),le=S.useCallback((kt,Ht)=>(Ze,lt)=>{const ht=Ze.nativeEvent,Ct=j.get(lt);if(Q.current!==null||!Ct||ht.dndKit||ht.defaultPrevented)return;const tt={active:Ct};kt(Ze,Ht.options,tt)===!0&&(ht.dndKit={capturedBy:Ht.sensor},Q.current=lt,_e(Ze,Ht))},[j,_e]),ut=nH(p,le);dH(p),ol(()=>{Ne&&I===Oc.Initializing&&F(Oc.Initialized)},[Ne,I]),S.useEffect(()=>{const{onDragMove:kt}=ye.current,{active:Ht,activatorEvent:Ze,collisions:lt,over:ht}=Ve.current;if(!Ht||!Ze)return;const Ct={active:Ht,activatorEvent:Ze,collisions:lt,delta:{x:At.x,y:At.y},over:ht};Ls.unstable_batchedUpdates(()=>{kt==null||kt(Ct),R({type:"onDragMove",event:Ct})})},[At.x,At.y]),S.useEffect(()=>{const{active:kt,activatorEvent:Ht,collisions:Ze,droppableContainers:lt,scrollAdjustedTranslate:ht}=Ve.current;if(!kt||Q.current==null||!Ht||!ht)return;const{onDragOver:Ct}=ye.current,tt=lt.get(Ot),yt=tt&&tt.rect.current?{id:tt.id,rect:tt.rect.current,data:tt.data,disabled:tt.disabled}:null,Dt={active:kt,activatorEvent:Ht,collisions:Ze,delta:{x:ht.x,y:ht.y},over:yt};Ls.unstable_batchedUpdates(()=>{rr(yt),Ct==null||Ct(Dt),R({type:"onDragOver",event:Dt})})},[Ot]),ol(()=>{Ve.current={activatorEvent:oe,active:G,activeNode:he,collisionRect:Nt,collisions:Rt,droppableRects:Ae,draggableNodes:j,draggingNode:Ie,draggingNodeRect:we,droppableContainers:fe,over:Wt,scrollableAncestors:_t,scrollAdjustedTranslate:At},U.current={initial:we,translated:Nt}},[G,he,Rt,Nt,j,Ie,we,Ae,fe,Wt,_t,At]),Qj({...qe,delta:V,draggingRect:Nt,pointerCoordinates:ft,scrollableAncestors:_t,scrollableAncestorRects:Ye});const vt=S.useMemo(()=>({active:G,activeNode:he,activeNodeRect:Ne,activatorEvent:oe,collisions:Rt,containerNodeRect:Be,dragOverlay:Oe,draggableNodes:j,droppableContainers:fe,droppableRects:Ae,over:Wt,measureDroppableContainers:Te,scrollableAncestors:_t,scrollableAncestorRects:Ye,measuringConfiguration:ge,measuringScheduled:se,windowRect:at}),[G,he,Ne,oe,Rt,Be,Oe,j,fe,Ae,Wt,Te,_t,Ye,ge,se,at]),Ft=S.useMemo(()=>({activatorEvent:oe,activators:ut,active:G,activeNodeRect:Ne,ariaDescribedById:{draggable:te},dispatch:_,draggableNodes:j,over:Wt,measureDroppableContainers:Te}),[oe,ut,G,Ne,_,te,j,Wt,Te]);return S.createElement(lS.Provider,{value:D},S.createElement(Fg.Provider,{value:Ft},S.createElement(bS.Provider,{value:vt},S.createElement(xS.Provider,{value:hr},h)),S.createElement(CH,{disabled:(c==null?void 0:c.restoreFocus)===!1})),S.createElement(wj,{...c,hiddenTextDescribedById:te}));function Pt(){const kt=(ae==null?void 0:ae.autoScrollEnabled)===!1,Ht=typeof d=="object"?d.enabled===!1:d===!1,Ze=B&&!kt&&!Ht;return typeof d=="object"?{...d,enabled:Ze}:{enabled:Ze}}}),TH=S.createContext(null),wx="button",RH="Draggable";function kH(r){let{id:e,data:t,disabled:n=!1,attributes:o}=r;const i=Vh(RH),{activators:a,activatorEvent:c,active:d,activeNodeRect:h,ariaDescribedById:p,draggableNodes:m,over:g}=S.useContext(Fg),{role:v=wx,roleDescription:w="draggable",tabIndex:T=0}=o??{},A=(d==null?void 0:d.id)===e,_=S.useContext(A?xS:TH),[R,D]=pg(),[I,F]=pg(),B=fH(a,e),H=Nh(t);ol(()=>(m.set(e,{id:e,key:i,node:R,activatorNode:I,data:H}),()=>{const V=m.get(e);V&&V.key===i&&m.delete(e)}),[m,e]);const j=S.useMemo(()=>({role:v,tabIndex:T,"aria-disabled":n,"aria-pressed":A&&v===wx?!0:void 0,"aria-roledescription":w,"aria-describedby":p.draggable}),[n,v,T,A,w,p.draggable]);return{active:d,activatorEvent:c,activeNodeRect:h,attributes:j,isDragging:A,listeners:n?void 0:B,node:R,over:g,setNodeRef:D,setActivatorNodeRef:F,transform:_}}function IH(){return S.useContext(bS)}const MH="Droppable",LH={timeout:25};function DH(r){let{data:e,disabled:t=!1,id:n,resizeObserverConfig:o}=r;const i=Vh(MH),{active:a,dispatch:c,over:d,measureDroppableContainers:h}=S.useContext(Fg),p=S.useRef({disabled:t}),m=S.useRef(!1),g=S.useRef(null),v=S.useRef(null),{disabled:w,updateMeasurementsFor:T,timeout:A}={...LH,...o},_=Nh(T??n),R=S.useCallback(()=>{if(!m.current){m.current=!0;return}v.current!=null&&clearTimeout(v.current),v.current=setTimeout(()=>{h(Array.isArray(_.current)?_.current:[_.current]),v.current=null},A)},[A]),D=Bg({callback:R,disabled:w||!a}),I=S.useCallback((j,V)=>{D&&(V&&(D.unobserve(V),m.current=!1),j&&D.observe(j))},[D]),[F,B]=pg(I),H=Nh(e);return S.useEffect(()=>{!D||!F.current||(D.disconnect(),m.current=!1,D.observe(F.current))},[F,D]),S.useEffect(()=>(c({type:So.RegisterDroppable,element:{id:n,key:i,disabled:t,node:F,rect:g,data:H}}),()=>c({type:So.UnregisterDroppable,key:i,id:n})),[n]),S.useEffect(()=>{t!==p.current.disabled&&(c({type:So.SetDroppableDisabled,id:n,key:i,disabled:t}),p.current.disabled=t)},[n,i,t,c]),{active:a,rect:g,isOver:(d==null?void 0:d.id)===n,node:F,over:d,setNodeRef:B}}function wS(r,e,t){const n={...r};return e.top+r.y<=t.top?n.y=t.top-e.top:e.bottom+r.y>=t.top+t.height&&(n.y=t.top+t.height-e.bottom),e.left+r.x<=t.left?n.x=t.left-e.left:e.right+r.x>=t.left+t.width&&(n.x=t.left+t.width-e.right),n}const OH=r=>{let{containerNodeRect:e,draggingNodeRect:t,transform:n}=r;return!t||!e?n:wS(n,t,e)},NH=r=>{let{transform:e,draggingNodeRect:t,windowRect:n}=r;return!t||!n?e:wS(e,t,n)};function yg(r,e,t){const n=r.slice();return n.splice(t<0?n.length+t:t,0,n.splice(e,1)[0]),n}function PH(r,e){return r.reduce((t,n,o)=>{const i=e.get(n);return i&&(t[o]=i),t},Array(r.length))}function Np(r){return r!==null&&r>=0}function BH(r,e){if(r===e)return!0;if(r.length!==e.length)return!1;for(let t=0;t<r.length;t++)if(r[t]!==e[t])return!1;return!0}function FH(r){return typeof r=="boolean"?{draggable:r,droppable:r}:r}const CS=r=>{let{rects:e,activeIndex:t,overIndex:n,index:o}=r;const i=yg(e,n,t),a=e[o],c=i[o];return!c||!a?null:{x:c.left-a.left,y:c.top-a.top,scaleX:c.width/a.width,scaleY:c.height/a.height}},Pp={scaleX:1,scaleY:1},jH=r=>{var e;let{activeIndex:t,activeNodeRect:n,index:o,rects:i,overIndex:a}=r;const c=(e=i[t])!=null?e:n;if(!c)return null;if(o===t){const h=i[a];return h?{x:0,y:t<a?h.top+h.height-(c.top+c.height):h.top-c.top,...Pp}:null}const d=HH(i,o,t);return o>t&&o<=a?{x:0,y:-c.height-d,...Pp}:o<t&&o>=a?{x:0,y:c.height+d,...Pp}:{x:0,y:0,...Pp}};function HH(r,e,t){const n=r[e],o=r[e-1],i=r[e+1];return n?t<e?o?n.top-(o.top+o.height):i?i.top-(n.top+n.height):0:i?i.top-(n.top+n.height):o?n.top-(o.top+o.height):0:0}const SS="Sortable",_S=S.createContext({activeIndex:-1,containerId:SS,disableTransforms:!1,items:[],overIndex:-1,useDragOverlay:!1,sortedRects:[],strategy:CS,disabled:{draggable:!1,droppable:!1}});function zH(r){let{children:e,id:t,items:n,strategy:o=CS,disabled:i=!1}=r;const{active:a,dragOverlay:c,droppableRects:d,over:h,measureDroppableContainers:p}=IH(),m=Vh(SS,t),g=c.rect!==null,v=S.useMemo(()=>n.map(B=>typeof B=="object"&&"id"in B?B.id:B),[n]),w=a!=null,T=a?v.indexOf(a.id):-1,A=h?v.indexOf(h.id):-1,_=S.useRef(v),R=!BH(v,_.current),D=A!==-1&&T===-1||R,I=FH(i);ol(()=>{R&&w&&p(v)},[R,v,w,p]),S.useEffect(()=>{_.current=v},[v]);const F=S.useMemo(()=>({activeIndex:T,containerId:m,disabled:I,disableTransforms:D,items:v,overIndex:A,useDragOverlay:g,sortedRects:PH(v,d),strategy:o}),[T,m,I.draggable,I.droppable,D,v,A,d,g,o]);return S.createElement(_S.Provider,{value:F},e)}const $H=r=>{let{id:e,items:t,activeIndex:n,overIndex:o}=r;return yg(t,n,o).indexOf(e)},qH=r=>{let{containerId:e,isSorting:t,wasDragging:n,index:o,items:i,newIndex:a,previousItems:c,previousContainerId:d,transition:h}=r;return!h||!n||c!==i&&o===a?!1:t?!0:a!==o&&e===d},UH={duration:200,easing:"ease"},AS="transform",WH=Ph.Transition.toString({property:AS,duration:0,easing:"linear"}),VH={roleDescription:"sortable"};function GH(r){let{disabled:e,index:t,node:n,rect:o}=r;const[i,a]=S.useState(null),c=S.useRef(t);return ol(()=>{if(!e&&t!==c.current&&n.current){const d=o.current;if(d){const h=_f(n.current,{ignoreTransform:!0}),p={x:d.left-h.left,y:d.top-h.top,scaleX:d.width/h.width,scaleY:d.height/h.height};(p.x||p.y)&&a(p)}}t!==c.current&&(c.current=t)},[e,t,n,o]),S.useEffect(()=>{i&&a(null)},[i]),i}function YH(r){let{animateLayoutChanges:e=qH,attributes:t,disabled:n,data:o,getNewIndex:i=$H,id:a,strategy:c,resizeObserverConfig:d,transition:h=UH}=r;const{items:p,containerId:m,activeIndex:g,disabled:v,disableTransforms:w,sortedRects:T,overIndex:A,useDragOverlay:_,strategy:R}=S.useContext(_S),D=ZH(n,v),I=p.indexOf(a),F=S.useMemo(()=>({sortable:{containerId:m,index:I,items:p},...o}),[m,o,I,p]),B=S.useMemo(()=>p.slice(p.indexOf(a)),[p,a]),{rect:H,node:j,isOver:V,setNodeRef:fe}=DH({id:a,data:F,disabled:D.droppable,resizeObserverConfig:{updateMeasurementsFor:B,...d}}),{active:P,activatorEvent:U,activeNodeRect:G,attributes:Q,setNodeRef:ae,listeners:ie,isDragging:oe,over:ne,setActivatorNodeRef:ye,transform:te}=kH({id:a,data:F,attributes:{...VH,...t},disabled:D.draggable}),re=lj(fe,ae),ge=!!P,Ae=ge&&!w&&Np(g)&&Np(A),Te=!_&&oe,se=Te&&Ae?te:null,Ce=Ae?se??(c??R)({rects:T,activeNodeRect:G,activeIndex:g,overIndex:A,index:I}):null,qe=Np(g)&&Np(A)?i({id:a,items:p,activeIndex:g,overIndex:A}):I,Ee=P==null?void 0:P.id,Ne=S.useRef({activeId:Ee,items:p,newIndex:qe,containerId:m}),Be=p!==Ne.current.items,Ve=e({active:P,containerId:m,isDragging:oe,isSorting:ge,id:a,index:I,items:p,newIndex:Ne.current.newIndex,previousItems:Ne.current.items,previousContainerId:Ne.current.containerId,transition:h,wasDragging:Ne.current.activeId!=null}),Pe=GH({disabled:!Ve,index:I,node:j,rect:H});return S.useEffect(()=>{ge&&Ne.current.newIndex!==qe&&(Ne.current.newIndex=qe),m!==Ne.current.containerId&&(Ne.current.containerId=m),p!==Ne.current.items&&(Ne.current.items=p)},[ge,qe,m,p]),S.useEffect(()=>{if(Ee===Ne.current.activeId)return;if(Ee!=null&&Ne.current.activeId==null){Ne.current.activeId=Ee;return}const Ie=setTimeout(()=>{Ne.current.activeId=Ee},50);return()=>clearTimeout(Ie)},[Ee]),{active:P,activeIndex:g,attributes:Q,data:F,rect:H,index:I,newIndex:qe,items:p,isOver:V,isSorting:ge,isDragging:oe,listeners:ie,node:j,overIndex:A,over:ne,setNodeRef:re,setActivatorNodeRef:ye,setDroppableNodeRef:fe,setDraggableNodeRef:ae,transform:Pe??Ce,transition:Oe()};function Oe(){if(Pe||Be&&Ne.current.newIndex===I)return WH;if(!(Te&&!oy(U)||!h)&&(ge||Ve))return Ph.Transition.toString({...h,property:AS})}}function ZH(r,e){var t,n;return typeof r=="boolean"?{draggable:r,droppable:!1}:{draggable:(t=r==null?void 0:r.draggable)!=null?t:e.draggable,droppable:(n=r==null?void 0:r.droppable)!=null?n:e.droppable}}un.Down,un.Right,un.Up,un.Left;function bg(r,e){Array.isArray(r)||(r=[r]);for(const t of r){if(e(t))return t;if(!t.children||t.children.length<1)continue;const n=bg(t.children,e);if(n)return n}}function Gh(r,e){Array.isArray(r)||(r=[r]);for(const t of r)e(t),!(!t.children||t.children.length<1)&&Gh(t.children,e)}function ES(r,e){Array.isArray(r)||(r=[r]);const t=[];return Gh(r,(n,o)=>t.push(e(n,o))),t}function TS(r,e){Array.isArray(r)||(r=[r]);for(const t of r){if(!e(t))return!1;if(!(!t.children||t.children.length<1)&&!TS(t.children,e))return!1}return!0}function KH(r,e){Array.isArray(r)||(r=[r]);const t=[];return Gh(r,(n,o)=>{e(n,o)&&t.push(n)}),t}function XH(r){Array.isArray(r)||(r=[r]);let e=0;return Gh(r,()=>e++),e}function JH(r,e,t,n){if(n(e,t))return null;Array.isArray(r)||(r=[r]);const o=bg(r,a=>{var c;return(c=a.children)==null?void 0:c.some(d=>n(d,e))}),i=bg(r,a=>{var c;return(c=a.children)==null?void 0:c.some(d=>n(d,t))});if(o===void 0&&i===void 0){const a=r.findIndex(d=>n(d,e)),c=r.findIndex(d=>n(d,t));return r.splice(a,1),r.splice(c,0,e),[...r]}else if(o!==void 0&&i!==void 0&&n(o,i)&&o.children){const a=o.children.findIndex(d=>n(d,e)),c=o.children.findIndex(d=>n(d,t));return a===void 0||c===void 0?null:(o.children.splice(a,1),o.children.splice(c,0,e),o.children=[...o.children],[...r])}return null}function QH(r,e,t){const n=[],o=[...e];for(;o.length>0;){const i=o.shift();if(i&&!n.find(a=>t(a,i))&&(n.push(i),!(!i.children||i.children.length<1)))for(const a of i.children)o.push(a)}return n}function ez(r,e,t){Array.isArray(r)||(r=[r]);const n=ES(r,a=>a),o=[],i=[...e];for(;i.length>0;){const a=i.shift();if(!a||o.find(d=>t(d,a)))continue;o.push(a);const c=n.find(d=>{var h;return(h=d.children)==null?void 0:h.some(p=>t(p,a))});c&&i.push(c)}return o}const Nc={find:bg,forEach:Gh,map:ES,every:TS,filter:KH,length:XH,replace:JH,descendants:QH,ancestors:ez},tz="_AWrap_1mpkv_1",rz="_AContainer_1mpkv_10",nz="_ATree_1mpkv_18",oz="_ATreeBody_1mpkv_30",iz="_TreeTopAddon_1mpkv_36",sz="_CoverBorder_1mpkv_46",az="_InsertBorder_1mpkv_55",lz="_ATreeHeader_1mpkv_86",cz="_ATreeBodyHeader_1mpkv_92",uz="_ATreeBodyHeaderResources_1mpkv_102",dz="_ATreeItem_1mpkv_108",fz="_IsSelectUsed_1mpkv_124",hz="_IsSelected_1mpkv_127",pz="_IsSearchSelected_1mpkv_132",gz="_IsHovered_1mpkv_143",mz="_CheckBox_1mpkv_147",vz="_Indents_1mpkv_159",yz="_ExpandIcon_1mpkv_166",bz="_Content_1mpkv_178",xz="_RightSticky_1mpkv_187",wz="_SearchInputWrap_1mpkv_196",Cz="_SearchInput_1mpkv_196",Sz="_RightAddon_1mpkv_208",_z="_RightAddonIcon_1mpkv_219",Az="_Loader_1mpkv_226",Ez="_IsChildOfDragSource_1mpkv_231",mn={AWrap:tz,AContainer:rz,ATree:nz,ATreeBody:oz,TreeTopAddon:iz,CoverBorder:sz,InsertBorder:az,ATreeHeader:lz,ATreeBodyHeader:cz,ATreeBodyHeaderResources:uz,ATreeItem:dz,IsSelectUsed:fz,IsSelected:hz,IsSearchSelected:pz,IsHovered:gz,CheckBox:mz,Indents:vz,ExpandIcon:yz,Content:bz,RightSticky:xz,SearchInputWrap:wz,SearchInput:Cz,RightAddon:Sz,RightAddonIcon:_z,Loader:Az,IsChildOfDragSource:Ez},Tz=r=>{const{isEqual:e,item:t,itemId:n,selectDisabled:o,selectUnused:i,isParentDisabled:a,indents:c,extIndents:d,useExpand:h,useSelect:p,useSearch:m,showCheckbox:g,icons:v,iconWidth:w,isSelectMulti:T,isDraggable:A,isParentCheckHovered:_,hoverdItem:R,onMouseOver:D,onMouseLeave:I,ContentRenderer:F,TreeItemRenderer:B,RightStickyAddon:H,resources:j,containerRef:V,TreeItemStyle:fe,TreeItemClassName:P,searchItemStyle:U,searchItemClassName:G,height:Q,isDragSrcItem:ae,isChildOfDragItem:ie,treeItemTooltip:oe,treeItemTooltipDelay:ne,treeItemTooltipDirection:ye,treeItemTooltipDistance:te}=r,{children:re}=S.useMemo(()=>t,[t]),[ge,Ae]=S.useMemo(()=>h,[h]),[Te,se]=S.useMemo(()=>p,[p]),[he,Ce]=S.useMemo(()=>m,[m]),qe=S.useMemo(()=>i?i(t):!1,[i,t]),Ee=S.useMemo(()=>!o||a?a:o(t),[o,a,t]),Ne=S.useMemo(()=>ge.some(tt=>e(tt,t)),[ge,e,t]),Be=S.useMemo(()=>!re||re.length<1?"noChild":Ne?"expanded":"collapsed",[re,Ne]),Ve=S.useMemo(()=>Er.getContent(v,r),[v,r]),Pe=S.useMemo(()=>{const tt=Ve==null?void 0:Ve[Be];return wv.includes(tt)?C.jsx(en,{icon:tt,style:{width:w,height:w}}):tt},[Ve,w,Be]),Oe=S.useCallback(tt=>{!Ae||Be==="noChild"||(Ae(Ne?ge.filter(yt=>!e(yt,t)):[...ge,t]),tt.stopPropagation())},[Ae,ge,Ne,t,e,Be]),Ie=S.useMemo(()=>Te.some(tt=>e(tt,t)),[Te,e,t]),we=S.useCallback(()=>{!se||Ee||(se(T?Ie?Te.filter(tt=>!e(tt,t)):[...Te,t]:[t]),he&&Ce&&he.items.some(tt=>e(tt,t))&&Ce({...he,item:t}))},[T,Ee,Ie,he,Ce,se,e,Te,t]),$e=S.useMemo(()=>he==null?void 0:he.items.some(tt=>e(tt,t)),[he,e,t]),it=S.useMemo(()=>$e&&(he==null?void 0:he.item)&&e(he.item,t),[$e,he,e,t]),at=S.useRef(null),_t=S.useRef(null),{attributes:Ye,listeners:Xe,setNodeRef:ft,transform:mt,transition:Fe,isDragging:Qe}=YH({id:n||`item-${JSON.stringify(t)}`,disabled:!A||!!a||!n}),At=S.useMemo(()=>ie?ie(t):!1,[ie,t]),Nt=S.useMemo(()=>{const tt=mt?{transform:Ph.Transform.toString(mt),transition:Fe,opacity:Qe?.5:1,zIndex:Qe?1:"auto"}:{};return ae||At?{...tt,opacity:.5,zIndex:10}:tt},[mt,Fe,Qe,ae,At]);S.useEffect(()=>{n&&ft&&_t.current&&ft(_t.current)},[n,ft]),S.useEffect(()=>{setTimeout(()=>{if(it&&at.current&&V.current){const{top:tt,bottom:yt}=at.current.getBoundingClientRect(),{top:Dt,bottom:Gt}=V.current.getBoundingClientRect();(tt<Dt||yt>Gt)&&at.current.scrollIntoView({behavior:"smooth",block:"center"})}},10)},[V,it]);const[Rt,Ot]=S.useState(!1),Wt=S.useCallback(()=>!Ee&&Ot(!0),[Ee]),rr=S.useCallback(()=>!Ee&&Ot(!1),[Ee]),or=S.useMemo(()=>Nc.map(t,tt=>tt).filter(tt=>!(o!=null&&o(tt))&&!(i!=null&&i(tt))),[o,i,t]),hr=S.useMemo(()=>!g||!T?!1:Ie&&or.some(tt=>Te.some(yt=>e(tt,yt)))&&or.some(tt=>!Te.some(yt=>e(tt,yt))),[g,T,Ie,or,e,Te]),ur=S.useMemo(()=>g?T?or.every(tt=>Te.some(yt=>e(tt,yt))):Te.some(tt=>e(tt,t)):!1,[g,T,or,t,e,Te]),_e=S.useCallback(()=>{if(!(!se||Ee))if(T)if(Ie){const tt=Te.filter(yt=>!(i!=null&&i(yt))&&!(o!=null&&o(yt))&&or.some(Dt=>e(Dt,yt)));tt.length>0&&se(Te.filter(yt=>!tt.some(Dt=>e(yt,Dt))))}else{const tt=or.filter(yt=>!(i!=null&&i(yt))&&!(o!=null&&o(yt))&&!Te.some(Dt=>e(Dt,yt)));tt.length>0&&se([...Te,...tt])}else se([t])},[Ee,o,i,T,se,e,Ie,Te,or,t]),le=S.useCallback(tt=>{Ee||_e(),tt.stopPropagation()},[Ee,_e]),ut=S.useMemo(()=>{if(!g||!T||Ee)return"";if(Ie){const yt=Te.filter(Dt=>!(i!=null&&i(Dt))&&!(o!=null&&o(Dt))&&or.some(Gt=>e(Gt,Dt)));if(yt.length>0)return j["deselect n"](yt.length)}const tt=or.filter(yt=>!(i!=null&&i(yt))&&!(o!=null&&o(yt))&&!Te.some(Dt=>e(Dt,yt)));return j["select n"](tt.length)},[o,i,j,Ee,g,T,Ie,or,e,Te]),vt=S.useMemo(()=>Er.getContent(H,r),[H,r]),Ft=S.useMemo(()=>Er.getContent(fe,r),[r,fe]),Pt=S.useMemo(()=>Er.getContent(P,r),[r,P]),kt=S.useMemo(()=>Er.getContent(G,r),[r,G]),Ht=S.useMemo(()=>Er.getContent(U,r),[r,U]),Ze=S.useMemo(()=>Er.getContent(oe,r),[r,oe]),lt=S.useMemo(()=>Er.getContent(ne,r),[r,ne]),ht=S.useMemo(()=>Er.getContent(ye,r),[r,ye]),Ct=S.useMemo(()=>Er.getContent(te,r),[r,te]);return C.jsxs(S.Fragment,{children:[C.jsxs(Yr,{abaseRef:_t,isDisabled:Ee,className:Ke.clsx(mn.ATreeItem,Ie&&mn.IsSelected,!Ee&&(Rt||_)&&mn.IsHovered,$e&&mn.IsSearched,it&&(kt||mn.IsSearchSelected),!qe&&mn.IsSelectUsed,At&&mn.IsChildOfDragSource,"NoSelect",Pt),style:{...Ft,...it&&Ht?Ht:{},"--ATreeItem_height":`${Q}px`,...Nt||{}},onClick:we,onMouseLeave:tt=>I==null?void 0:I(tt,t),onMouseOver:tt=>D==null?void 0:D(tt,t),...A&&!Ee&&Ye?Ye:{},...A&&!Ee&&Xe?Xe:{},tooltip:Ze,tooltipDelay:lt,tooltipDirection:ht,tooltipDistance:Ct,children:[g&&C.jsx(af,{className:mn.CheckBox,isDisabled:Ee,isIndeterminate:hr,tooltip:ut,useCheck:[+ur,_e],style:{visibility:Ee||qe?"hidden":"visible",zIndex:Ee||qe?0:2},onClick:le,onMouseOut:rr,onMouseOver:Wt}),C.jsx("div",{className:mn.Indents,style:{paddingLeft:g?0:Ve!=null&&Ve.noChild?12:0},children:c.map((tt,yt)=>{const Dt=yt===c.length-1;return C.jsx(dC,{value:tt,map:{Collapsed:d?d({iconWidth:w}).collapsed:C.jsx(kz,{iconWidth:w}),Expanded:d?d({iconWidth:w,isLast:Dt}).expanded:C.jsx(Rz,{iconWidth:w,isLast:Dt}),IsLast:d?d({iconWidth:w}).isLast:C.jsx(Iz,{iconWidth:w})}},yt)})}),Pe&&C.jsx("div",{className:mn.ExpandIcon,style:{width:w,minWidth:w,maxWidth:w},onClick:Oe,children:Pe}),C.jsx("div",{className:Ke.clsx(mn.Content,"NoSelect"),children:C.jsx(F,{containerRef:V,ContentRenderer:F,extIndents:d,height:Q,hoverdItem:R,icons:v,iconWidth:w,indents:c,isDraggable:A,isEqual:e,isParentCheckHovered:T&&(Rt||_),isSelectMulti:T,item:t,itemId:n,resources:j,RightStickyAddon:H,searchItemClassName:kt,searchItemStyle:U,showCheckbox:g,TreeItemClassName:P,TreeItemRenderer:B,TreeItemStyle:fe,treeItemTooltip:oe,treeItemTooltipDelay:ne,treeItemTooltipDirection:ye,treeItemTooltipDistance:te,useExpand:h,useSearch:m,useSelect:p,onMouseLeave:I,onMouseOver:D})}),vt&&C.jsx("div",{className:mn.RightSticky,children:vt})]}),Ne&&(re==null?void 0:re.map((tt,yt)=>C.jsx(B,{containerRef:V,ContentRenderer:F,extIndents:d,height:Q,hoverdItem:R,icons:v,iconWidth:w,isChildOfDragItem:ie,isDraggable:A,isDragSrcItem:ae,isEqual:e,isParentCheckHovered:T&&(Rt||_),isSelectMulti:T,item:tt,itemId:n?`${n}-child-${yt}`:void 0,resources:j,RightStickyAddon:H,searchItemClassName:kt,searchItemStyle:U,selectDisabled:o,selectUnused:i,showCheckbox:g,TreeItemClassName:P,TreeItemRenderer:B,TreeItemStyle:fe,treeItemTooltip:oe,treeItemTooltipDelay:ne,treeItemTooltipDirection:ye,treeItemTooltipDistance:te,useExpand:h,useSearch:m,useSelect:p,indents:[...c.map(Dt=>Dt==="IsLast"?"Collapsed":Dt),yt===re.length-1?"IsLast":"Expanded"],onMouseLeave:I,onMouseOver:D},yt)))]})},Rz=({iconWidth:r,isLast:e})=>C.jsx("div",{style:{width:r/8*3,height:"100%",borderLeft:"var(--ATree_Indent_border)",marginLeft:r/2,marginRight:r/8,boxSizing:"border-box",transition:"border-color var(--Transition)"},children:e&&C.jsx("div",{style:{borderBottom:"var(--ATree_Indent_border)",height:"50%",transition:"border-color var(--Transition)"}})}),kz=({iconWidth:r})=>C.jsx("div",{style:{width:r,height:"100%",borderLeft:"none",marginLeft:0,transition:"border-color var(--Transition)"}}),Iz=({iconWidth:r})=>C.jsx("div",{style:{width:r/8*3,height:"50%",borderLeft:"var(--ATree_Indent_border)",borderBottom:"var(--ATree_Indent_border)",marginLeft:r/2,marginRight:r/8,boxSizing:"border-box",transition:"border-color var(--Transition)"}}),Mz=r=>{const{isEqual:e,searchResult:t,initSearch:n,searchUp:o,searchDown:i,searchEnter:a,isDisabled:c,isLoading:d,resources:h,maxLength:p,autoFocus:m}=r,g=S.useCallback(T=>{T.key==="Enter"?a():T.key==="ArrowDown"?i():T.key==="ArrowUp"&&o(),T.preventDefault(),T.stopPropagation()},[i,a,o]),v=S.useCallback(T=>{n(T)},[n]),w=S.useMemo(()=>c||d?-1:void 0,[c,d]);return C.jsx(Vc,{autoFocus:m,className:mn.SearchInput,isDisabled:c,maxLength:p,placeholder:h["Search(Placeholder)"],tabIndex:w,useValue:[(t==null?void 0:t.keyword)??"",v],RightAddon:C.jsx(Lz,{isEqual:e,resources:h,searchDown:i,searchEnter:a,searchResult:t,searchUp:o}),wrapProps:{className:mn.SearchInputWrap},onKeyDown:g})},Lz=r=>{const{isEqual:e,searchResult:t,searchUp:n,searchDown:o,searchEnter:i,resources:a}=r,c=S.useMemo(()=>!t||t.items.length<1?0:t.items.findIndex(w=>t.item&&e(w,t.item))+1,[t,e]),d=S.useMemo(()=>!t||t.items.length<1?0:t.items.length,[t]),h=S.useMemo(()=>c<2,[c]),p=S.useMemo(()=>c>=d,[c,d]),m=S.useCallback(w=>{w.stopPropagation(),!h&&n()},[n,h]),g=S.useCallback(w=>{w.stopPropagation(),!p&&o()},[o,p]),v=S.useCallback(w=>{w.stopPropagation(),i()},[i]);return C.jsx("div",{className:Ke.clsx(mn.RightAddon,"NoSelect"),children:t?C.jsxs(C.Fragment,{children:[c,"/",d,C.jsx(Yr,{isDisabled:h,onClick:m,children:C.jsx(en,{className:mn.RightAddonIcon,icon:"ArrowUp",mask:""})}),C.jsx(Yr,{isDisabled:p,onClick:g,children:C.jsx(en,{className:mn.RightAddonIcon,icon:"ArrowDown"})})]}):C.jsx(ho,{className:mn.RightAddonIcon,icon:"Search",style:{marginRight:4},tooltip:a["Search(Button)"],type:"Raw",onClick:v})})},Dz=r=>{var et;const{pk:e,selectDisabled:t,selectUnused:n,useItems:o,useExpand:i,useSelect:a,useSearch:c,showCheckbox:d,iconWidth:h=24,icons:p={noChild:"Folder",collapsed:"FolderCopy",expanded:"FolderOpen"},indents:m,isSelectMulti:g=!1,noSearch:v=!1,isDraggable:w,noSyncSearchSelect:T=!1,actionRef:A,placeholder:_,searchPredicate:R=Nz,isDisabled:D,isLoading:I,ContentRenderer:F=Oz,TreeItemRenderer:B=Tz,RightStickyAddon:H,TopRightAddon:j,TreeTopAddon:V,resources:fe,maxLength:P,autoFocus:U,TreeItemStyle:G,TreeItemClassName:Q,OverflowPadding:ae,insertBorder:ie,width:oe,searchItemClassName:ne,searchItemStyle:ye,height:te=40,treeItemTooltip:re,treeItemTooltipDelay:ge,treeItemTooltipDirection:Ae,treeItemTooltipDistance:Te,...se}=r,he=S.useMemo(()=>({...wr.ATree,...fe}),[fe]),Ce=S.useCallback((Re,rt)=>!Re||!rt?!1:e!==void 0?Array.isArray(e)?e.every(dt=>Re&&rt&&Re[dt]!==void 0&&rt[dt]!==void 0&&Ya.isEqual(Re[dt],rt[dt])):Re&&rt&&Re[e]!==void 0&&rt[e]!==void 0&&Ya.isEqual(Re[e],rt[e]):Ya.isEqual(Re,rt),[e]),qe=S.useRef(null),[Ee,Ne]=wn(o,[]),Be=S.useMemo(()=>Nc.map(Ee,Re=>Re),[Ee]),[Ve,Pe]=wn(i,[]),[Oe,Ie]=wn(a,[]),[we,$e]=wn(c,void 0),it=S.useCallback(Re=>{if(D||!Pe||Ve.some(Bt=>Ce(Bt,Re)))return;const rt=[];let dt=Re;for(;dt;){const Bt=dt;Ve.find(Yt=>Ce(Yt,Bt))||rt.push(Bt),dt=Be.find(Yt=>{var It;return(It=Yt.children)==null?void 0:It.some(me=>Ce(me,Bt))})}Pe([...Ve,...rt])},[Ve,D,Ce,Pe,Be]),at=S.useCallback(()=>{!Pe||D||Pe([...Be])},[Be,D,Pe]),_t=S.useCallback(()=>{!Pe||D||Pe([])},[Pe,D]),Ye=S.useCallback(Re=>{!Ie||D||n!=null&&n(Re)||(Ie([Re]),it(Re))},[Ie,D,n,it]),Xe=S.useCallback(Re=>{if(!$e||D)return;if(!Re||v){$e(void 0),T||Ie==null||Ie([]);return}const rt=Nc.filter(Ee,Bt=>R(Re,Bt));let dt;if(rt.find(Bt=>(we==null?void 0:we.item)&&Ce(Bt,we.item))?dt=we==null?void 0:we.item:rt.length>0&&(dt=rt[0]),$e({keyword:Re,items:rt,item:dt}),dt&&it(dt),Ie&&!T)if(g)Ie(rt);else{const Bt=rt.find(Yt=>dt&&Ce(Yt,dt));Ie(Bt?[Bt]:[])}},[Ee,D,Ce,R,$e,Ie,it,T,v,g,we]),ft=S.useRef(!1);S.useEffect(()=>{ft.current=!0},[Ee]),S.useEffect(()=>{we&&ft.current&&(Xe(we.keyword),ft.current=!1)},[Xe,we]);const mt=S.useCallback(()=>{if(!we||!$e||D)return;let Re=we.items.findIndex(rt=>we.item&&Ce(rt,we.item))-1;Re<0||($e({...we,item:we.items[Re]}),it(we.items[Re]),T||Ye(we.items[Re]))},[we,it,$e,D,Ye,Ce,T]),Fe=S.useCallback(()=>{if(!we||!$e||D)return;let Re=we.items.findIndex(rt=>we.item&&Ce(rt,we.item))+1;Re>=we.items.length||($e({...we,item:we.items[Re]}),it(we.items[Re]),T||Ye(we.items[Re]))},[we,it,D,$e,Ye,Ce,T]),Qe=S.useCallback(()=>{if(!we||!$e||D)return;let Re=we.items.findIndex(dt=>we.item&&Ce(dt,we.item));if(!T||n!=null&&n(we.items[Re])){Fe();return}if(Oe.some(dt=>we.item&&Ce(dt,we.item))){let dt=Re+1;const Bt=we.items[dt];if(dt>=we.items.length)return;$e({...we,item:Bt}),Ye(Bt)}else Ye(we.items[Re])},[we,$e,D,Oe,T,Fe,Ce,Ye,n]),[At,Nt]=S.useState(!1),Rt=S.useCallback(()=>Nt(!0),[]),Ot=S.useCallback(()=>Nt(!1),[]),Wt=S.useMemo(()=>n?Nc.map(Ee,Re=>Re).filter(Re=>!n(Re)):t?Nc.map(Ee,Re=>Re).filter(Re=>!t(Re)):Nc.map(Ee,Re=>Re),[n,t,Ee]),rr=S.useMemo(()=>!d||!g?!1:Oe.length>0&&Wt.length>Oe.length,[d,g,Oe,Wt]),or=S.useMemo(()=>!d||!g?!1:Oe.length>0&&Wt.length===Oe.length,[d,g,Oe,Wt]),hr=S.useCallback(()=>{if(!Ie||!g||D)return;const Re=Oe.filter(rt=>!(n!=null&&n(rt))&&!(t!=null&&t(rt))&&Wt.some(dt=>Ce(dt,rt)));if(Re.length>0)Ie(Oe.filter(rt=>!Re.some(dt=>Ce(rt,dt))));else{const rt=Wt.filter(dt=>!(n!=null&&n(dt))&&!(t!=null&&t(dt))&&!Oe.some(Bt=>Ce(Bt,dt)));rt.length>0&&Ie([...Oe,...rt])}},[g,D,n,t,Ie,Oe,Wt,Ce]),ur=S.useMemo(()=>{if(!d||!g||D)return"";const Re=Oe.filter(rt=>!(n!=null&&n(rt))&&!(t!=null&&t(rt))&&Wt.some(dt=>Ce(dt,rt)));if(Re.length>0)return he["deselect n"](Re.length);{const rt=Wt.filter(dt=>!(n!=null&&n(dt))&&!(t!=null&&t(dt))&&!Oe.some(Bt=>Ce(Bt,dt)));return he["select n"](rt.length)}},[n,t,D,he,d,g,Wt,Oe,Ce]),[_e,le]=S.useState(),ut=Cj(ux(cy,{activationConstraint:{distance:8}}),ux(ay)),vt=S.useRef(new Map),Ft=S.useCallback(Re=>{if(!vt.current.has(Re)){const rt=`item_${Ya.uniqueId()}`;vt.current.set(Re,rt)}return vt.current.get(Re)},[]),Pt=S.useCallback(Re=>Be.find(rt=>Ft(rt)===Re),[Be,Ft]),kt=S.useCallback(Re=>!_e||!_e.children?!1:_e.children.some(dt=>Ce(dt,Re))?!0:_e.children.some(dt=>dt.children?Nc.find(dt,Bt=>Ce(Bt,Re))!==void 0:!1),[_e,Ce]),Ht=S.useCallback(Re=>{if(!w||D)return;const rt=Pt(Re.active.id);rt&&le(rt)},[w,D,Pt]),Ze=S.useCallback((Re,rt,dt,Bt)=>{const Yt=Re.findIndex(me=>Bt(me,rt)),It=Re.findIndex(me=>Bt(me,dt));return Yt!==-1&&It!==-1?yg(Re,Yt,It):Re.map(me=>{if(!me.children)return me;const st=me.children.findIndex(dr=>Bt(dr,rt)),xt=me.children.findIndex(dr=>Bt(dr,dt));return st!==-1&&xt!==-1?{...me,children:yg(me.children,st,xt)}:me.children?{...me,children:Ze(me.children,rt,dt,Bt)}:me})},[]),lt=S.useCallback(Re=>{!w||D||!_e||!Re.over||Pt(Re.over.id)},[w,D,_e,Pt]),ht=S.useCallback(Re=>{if(!w||D||!Ne||!_e||!Re.over)return;const rt=Pt(Re.over.id);if(!rt||Ce(_e,rt)){le(void 0);return}const dt=Ze(Ee,_e,rt,Ce);Ne(dt),le(void 0)},[w,D,Ne,_e,Pt,Ce,Ee,Ze]),Ct=S.useMemo(()=>Ee.map(Re=>Ft(Re)),[Ee,Ft]);S.useEffect(()=>{var Re;d||(Re=qe.current)==null||Re.scrollTo(0,0)},[d,qe]),S.useEffect(()=>{!g&&Oe.length>1&&(Ie==null||Ie([Oe[Oe.length-1]]))},[g,Ie,Oe]),S.useEffect(()=>{A&&(A.current={expandAll:at,collapseAll:_t})},[A,at,_t]),S.useEffect(()=>{if(!t||!Ie)return;const Re=Oe.filter(rt=>!t(rt));Oe.length!==Re.length&&Ie(Re)},[t,Oe,Ie]),S.useEffect(()=>{if(!n||!Ie)return;const Re=Oe.filter(rt=>!n(rt));Oe.length!==Re.length&&Ie(Re)},[n,Oe,Ie]),S.useEffect(()=>{$e&&$e(void 0)},[$e]);const[tt,yt]=S.useState(!1);S.useEffect(()=>{yt(Re=>!Re)},[Ee]);const[Dt,Gt]=S.useState(null),ir=S.useCallback((Re,rt)=>{D||(Re.stopPropagation(),Re.preventDefault(),Gt(rt))},[D]),zt=S.useCallback((Re,rt)=>{Dt===null||D||Ce(rt,Dt)&&(Re.stopPropagation(),Re.preventDefault(),Gt(null))},[Dt,D,Ce]),vr=S.useRef(null),[Br,pr]=S.useState(!1),[pe,Me]=S.useState((et=vr.current)==null?void 0:et.scrollHeight);return S.useEffect(()=>{if(Ve.length<0)return;const Re=qe.current,rt=vr.current,dt=Re.clientHeight<rt.clientHeight;Me(dt?rt.scrollHeight:Re.clientHeight),pr(dt)},[Ve]),C.jsxs(Yr,{...se,className:Ke.clsx(se.className,mn.AWrap),isDisabled:D,children:[(!v||j)&&C.jsxs(Rn,{className:mn.ATreeHeader,children:[!v&&C.jsx(Mz,{autoFocus:U,initSearch:Xe,isDisabled:D,isEqual:Ce,isLoading:I,maxLength:P,resources:he,searchDown:Fe,searchEnter:Qe,searchResult:we,searchUp:mt}),!v&&j&&C.jsx(Nn,{w:8}),j]}),(!v||j||d&&g||w)&&C.jsx(Iv,{isLoading:I&&Ee.length!==0}),(d&&g||w)&&C.jsxs("div",{className:Ke.clsx(mn.ATreeBodyHeader,"NoSelect"),children:[d&&C.jsx(af,{className:mn.CheckBox,isDisabled:D,isIndeterminate:rr,tooltip:ur,useCheck:[+or,()=>hr()],onMouseOut:Ot,onMouseOver:Rt}),he.Items,C.jsx(Xu,{}),C.jsxs("div",{className:Ke.clsx(mn.ATreeBodyHeaderResources,"NoSelect"),style:{marginRight:Br?8:0},children:[C.jsx("span",{children:d&&he["*Click row for single select"]}),C.jsx("span",{children:w&&he["*Change order to row drag"]})]})]}),V&&C.jsx("div",{className:mn.TreeTopAddon,children:V}),C.jsx("div",{ref:qe,className:Ke.clsx(se.className,mn.AContainer),children:C.jsxs("div",{className:mn.ATree,style:{minWidth:oe||"fit-content",marginRight:ae&&Br?8:0},children:[C.jsxs("div",{ref:vr,className:mn.ATreeBody,children:[Ee.length===0?I?C.jsx(Pz,{text:he["Loading Contents..."]}):_:null,C.jsx(EH,{collisionDetection:Tj,modifiers:[OH,NH],sensors:ut,measuring:{droppable:{strategy:vf.Always}},onDragEnd:ht,onDragOver:lt,onDragStart:Ht,children:C.jsx(zH,{items:Ct,strategy:jH,children:Ee.map((Re,rt)=>C.jsx(B,{containerRef:qe,ContentRenderer:F,extIndents:m,height:te,hoverdItem:Dt,icons:p,iconWidth:h,indents:[],isChildOfDragItem:kt,isDraggable:w,isDragSrcItem:Ce(Re,_e),isEqual:Ce,isParentCheckHovered:g&&At,isParentDisabled:D,isSelectMulti:g,item:Re,itemId:Ft(Re),resources:he,RightStickyAddon:H,searchItemClassName:ne,searchItemStyle:ye,selectDisabled:t,selectUnused:n,showCheckbox:d,TreeItemClassName:Q,TreeItemRenderer:B,TreeItemStyle:G,treeItemTooltip:re,treeItemTooltipDelay:ge,treeItemTooltipDirection:Ae,treeItemTooltipDistance:Te,useExpand:[Ve,Pe],useSearch:[we,$e],useSelect:[Oe,Ie],onMouseLeave:zt,onMouseOver:ir},`${rt}${tt}`))})})]}),ie&&C.jsxs(C.Fragment,{children:[C.jsx("div",{className:mn.CoverBorder}),C.jsx("div",{className:mn.InsertBorder,style:{"--InsertBorder_height":`${te}px`,height:Br?pe:"100%"}})]})]})})]})},Oz=r=>{const{item:e}=r,t={};return ar.keys(e).forEach(n=>{n!=="children"&&(t[n]=e[n])}),JSON.stringify(t)};function Nz(r,e){return ar.some(e,(t,n)=>{var o;return(o=ar.stringify(n))==null?void 0:o.toLowerCase().includes(r.toLowerCase())})}const Pz=r=>{const{text:e}=r;return C.jsxs(Rn,{className:Ke.clsx(mn.Loader,"NoSelect"),children:[C.jsx(en,{height:40,icon:"Spinner",style:{height:40},width:40}),C.jsx(SC,{text:e})]})};var $m,Cx;function Af(){return Cx||(Cx=1,$m=TypeError),$m}const Bz={},Fz=Object.freeze(Object.defineProperty({__proto__:null,default:Bz},Symbol.toStringTag,{value:"Module"})),jz=vT(Fz);var qm,Sx;function jg(){if(Sx)return qm;Sx=1;var r=typeof Map=="function"&&Map.prototype,e=Object.getOwnPropertyDescriptor&&r?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,t=r&&e&&typeof e.get=="function"?e.get:null,n=r&&Map.prototype.forEach,o=typeof Set=="function"&&Set.prototype,i=Object.getOwnPropertyDescriptor&&o?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,a=o&&i&&typeof i.get=="function"?i.get:null,c=o&&Set.prototype.forEach,d=typeof WeakMap=="function"&&WeakMap.prototype,h=d?WeakMap.prototype.has:null,p=typeof WeakSet=="function"&&WeakSet.prototype,m=p?WeakSet.prototype.has:null,g=typeof WeakRef=="function"&&WeakRef.prototype,v=g?WeakRef.prototype.deref:null,w=Boolean.prototype.valueOf,T=Object.prototype.toString,A=Function.prototype.toString,_=String.prototype.match,R=String.prototype.slice,D=String.prototype.replace,I=String.prototype.toUpperCase,F=String.prototype.toLowerCase,B=RegExp.prototype.test,H=Array.prototype.concat,j=Array.prototype.join,V=Array.prototype.slice,fe=Math.floor,P=typeof BigInt=="function"?BigInt.prototype.valueOf:null,U=Object.getOwnPropertySymbols,G=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,Q=typeof Symbol=="function"&&typeof Symbol.iterator=="object",ae=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===Q||!0)?Symbol.toStringTag:null,ie=Object.prototype.propertyIsEnumerable,oe=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(_e){return _e.__proto__}:null);function ne(_e,le){if(_e===1/0||_e===-1/0||_e!==_e||_e&&_e>-1e3&&_e<1e3||B.call(/e/,le))return le;var ut=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof _e=="number"){var vt=_e<0?-fe(-_e):fe(_e);if(vt!==_e){var Ft=String(vt),Pt=R.call(le,Ft.length+1);return D.call(Ft,ut,"$&_")+"."+D.call(D.call(Pt,/([0-9]{3})/g,"$&_"),/_$/,"")}}return D.call(le,ut,"$&_")}var ye=jz,te=ye.custom,re=Oe(te)?te:null,ge={__proto__:null,double:'"',single:"'"},Ae={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};qm=function _e(le,ut,vt,Ft){var Pt=ut||{};if($e(Pt,"quoteStyle")&&!$e(ge,Pt.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if($e(Pt,"maxStringLength")&&(typeof Pt.maxStringLength=="number"?Pt.maxStringLength<0&&Pt.maxStringLength!==1/0:Pt.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var kt=$e(Pt,"customInspect")?Pt.customInspect:!0;if(typeof kt!="boolean"&&kt!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if($e(Pt,"indent")&&Pt.indent!==null&&Pt.indent!==" "&&!(parseInt(Pt.indent,10)===Pt.indent&&Pt.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if($e(Pt,"numericSeparator")&&typeof Pt.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var Ht=Pt.numericSeparator;if(typeof le>"u")return"undefined";if(le===null)return"null";if(typeof le=="boolean")return le?"true":"false";if(typeof le=="string")return At(le,Pt);if(typeof le=="number"){if(le===0)return 1/0/le>0?"0":"-0";var Ze=String(le);return Ht?ne(le,Ze):Ze}if(typeof le=="bigint"){var lt=String(le)+"n";return Ht?ne(le,lt):lt}var ht=typeof Pt.depth>"u"?5:Pt.depth;if(typeof vt>"u"&&(vt=0),vt>=ht&&ht>0&&typeof le=="object")return Ce(le)?"[Array]":"[Object]";var Ct=or(Pt,vt);if(typeof Ft>"u")Ft=[];else if(_t(Ft,le)>=0)return"[Circular]";function tt(It,me,st){if(me&&(Ft=V.call(Ft),Ft.push(me)),st){var xt={depth:Pt.depth};return $e(Pt,"quoteStyle")&&(xt.quoteStyle=Pt.quoteStyle),_e(It,xt,vt+1,Ft)}return _e(It,Pt,vt+1,Ft)}if(typeof le=="function"&&!Ee(le)){var yt=at(le),Dt=ur(le,tt);return"[Function"+(yt?": "+yt:" (anonymous)")+"]"+(Dt.length>0?" { "+j.call(Dt,", ")+" }":"")}if(Oe(le)){var Gt=Q?D.call(String(le),/^(Symbol\(.*\))_[^)]*$/,"$1"):G.call(le);return typeof le=="object"&&!Q?Rt(Gt):Gt}if(Qe(le)){for(var ir="<"+F.call(String(le.nodeName)),zt=le.attributes||[],vr=0;vr<zt.length;vr++)ir+=" "+zt[vr].name+"="+Te(se(zt[vr].value),"double",Pt);return ir+=">",le.childNodes&&le.childNodes.length&&(ir+="..."),ir+="</"+F.call(String(le.nodeName))+">",ir}if(Ce(le)){if(le.length===0)return"[]";var Br=ur(le,tt);return Ct&&!rr(Br)?"["+hr(Br,Ct)+"]":"[ "+j.call(Br,", ")+" ]"}if(Ne(le)){var pr=ur(le,tt);return!("cause"in Error.prototype)&&"cause"in le&&!ie.call(le,"cause")?"{ ["+String(le)+"] "+j.call(H.call("[cause]: "+tt(le.cause),pr),", ")+" }":pr.length===0?"["+String(le)+"]":"{ ["+String(le)+"] "+j.call(pr,", ")+" }"}if(typeof le=="object"&&kt){if(re&&typeof le[re]=="function"&&ye)return ye(le,{depth:ht-vt});if(kt!=="symbol"&&typeof le.inspect=="function")return le.inspect()}if(Ye(le)){var pe=[];return n&&n.call(le,function(It,me){pe.push(tt(me,le,!0)+" => "+tt(It,le))}),Wt("Map",t.call(le),pe,Ct)}if(mt(le)){var Me=[];return c&&c.call(le,function(It){Me.push(tt(It,le))}),Wt("Set",a.call(le),Me,Ct)}if(Xe(le))return Ot("WeakMap");if(Fe(le))return Ot("WeakSet");if(ft(le))return Ot("WeakRef");if(Ve(le))return Rt(tt(Number(le)));if(Ie(le))return Rt(tt(P.call(le)));if(Pe(le))return Rt(w.call(le));if(Be(le))return Rt(tt(String(le)));if(typeof window<"u"&&le===window)return"{ [object Window] }";if(typeof globalThis<"u"&&le===globalThis||typeof Di<"u"&&le===Di)return"{ [object globalThis] }";if(!qe(le)&&!Ee(le)){var et=ur(le,tt),Re=oe?oe(le)===Object.prototype:le instanceof Object||le.constructor===Object,rt=le instanceof Object?"":"null prototype",dt=!Re&&ae&&Object(le)===le&&ae in le?R.call(it(le),8,-1):rt?"Object":"",Bt=Re||typeof le.constructor!="function"?"":le.constructor.name?le.constructor.name+" ":"",Yt=Bt+(dt||rt?"["+j.call(H.call([],dt||[],rt||[]),": ")+"] ":"");return et.length===0?Yt+"{}":Ct?Yt+"{"+hr(et,Ct)+"}":Yt+"{ "+j.call(et,", ")+" }"}return String(le)};function Te(_e,le,ut){var vt=ut.quoteStyle||le,Ft=ge[vt];return Ft+_e+Ft}function se(_e){return D.call(String(_e),/"/g,""")}function he(_e){return!ae||!(typeof _e=="object"&&(ae in _e||typeof _e[ae]<"u"))}function Ce(_e){return it(_e)==="[object Array]"&&he(_e)}function qe(_e){return it(_e)==="[object Date]"&&he(_e)}function Ee(_e){return it(_e)==="[object RegExp]"&&he(_e)}function Ne(_e){return it(_e)==="[object Error]"&&he(_e)}function Be(_e){return it(_e)==="[object String]"&&he(_e)}function Ve(_e){return it(_e)==="[object Number]"&&he(_e)}function Pe(_e){return it(_e)==="[object Boolean]"&&he(_e)}function Oe(_e){if(Q)return _e&&typeof _e=="object"&&_e instanceof Symbol;if(typeof _e=="symbol")return!0;if(!_e||typeof _e!="object"||!G)return!1;try{return G.call(_e),!0}catch{}return!1}function Ie(_e){if(!_e||typeof _e!="object"||!P)return!1;try{return P.call(_e),!0}catch{}return!1}var we=Object.prototype.hasOwnProperty||function(_e){return _e in this};function $e(_e,le){return we.call(_e,le)}function it(_e){return T.call(_e)}function at(_e){if(_e.name)return _e.name;var le=_.call(A.call(_e),/^function\s*([\w$]+)/);return le?le[1]:null}function _t(_e,le){if(_e.indexOf)return _e.indexOf(le);for(var ut=0,vt=_e.length;ut<vt;ut++)if(_e[ut]===le)return ut;return-1}function Ye(_e){if(!t||!_e||typeof _e!="object")return!1;try{t.call(_e);try{a.call(_e)}catch{return!0}return _e instanceof Map}catch{}return!1}function Xe(_e){if(!h||!_e||typeof _e!="object")return!1;try{h.call(_e,h);try{m.call(_e,m)}catch{return!0}return _e instanceof WeakMap}catch{}return!1}function ft(_e){if(!v||!_e||typeof _e!="object")return!1;try{return v.call(_e),!0}catch{}return!1}function mt(_e){if(!a||!_e||typeof _e!="object")return!1;try{a.call(_e);try{t.call(_e)}catch{return!0}return _e instanceof Set}catch{}return!1}function Fe(_e){if(!m||!_e||typeof _e!="object")return!1;try{m.call(_e,m);try{h.call(_e,h)}catch{return!0}return _e instanceof WeakSet}catch{}return!1}function Qe(_e){return!_e||typeof _e!="object"?!1:typeof HTMLElement<"u"&&_e instanceof HTMLElement?!0:typeof _e.nodeName=="string"&&typeof _e.getAttribute=="function"}function At(_e,le){if(_e.length>le.maxStringLength){var ut=_e.length-le.maxStringLength,vt="... "+ut+" more character"+(ut>1?"s":"");return At(R.call(_e,0,le.maxStringLength),le)+vt}var Ft=Ae[le.quoteStyle||"single"];Ft.lastIndex=0;var Pt=D.call(D.call(_e,Ft,"\\$1"),/[\x00-\x1f]/g,Nt);return Te(Pt,"single",le)}function Nt(_e){var le=_e.charCodeAt(0),ut={8:"b",9:"t",10:"n",12:"f",13:"r"}[le];return ut?"\\"+ut:"\\x"+(le<16?"0":"")+I.call(le.toString(16))}function Rt(_e){return"Object("+_e+")"}function Ot(_e){return _e+" { ? }"}function Wt(_e,le,ut,vt){var Ft=vt?hr(ut,vt):j.call(ut,", ");return _e+" ("+le+") {"+Ft+"}"}function rr(_e){for(var le=0;le<_e.length;le++)if(_t(_e[le],`
|
365
365
|
`)>=0)return!1;return!0}function or(_e,le){var ut;if(_e.indent===" ")ut=" ";else if(typeof _e.indent=="number"&&_e.indent>0)ut=j.call(Array(_e.indent+1)," ");else return null;return{base:ut,prev:j.call(Array(le+1),ut)}}function hr(_e,le){if(_e.length===0)return"";var ut=`
|
366
366
|
`+le.prev+le.base;return ut+j.call(_e,","+ut)+`
|
367
367
|
`+le.prev}function ur(_e,le){var ut=Ce(_e),vt=[];if(ut){vt.length=_e.length;for(var Ft=0;Ft<_e.length;Ft++)vt[Ft]=$e(_e,Ft)?le(_e[Ft],_e):""}var Pt=typeof U=="function"?U(_e):[],kt;if(Q){kt={};for(var Ht=0;Ht<Pt.length;Ht++)kt["$"+Pt[Ht]]=Pt[Ht]}for(var Ze in _e)$e(_e,Ze)&&(ut&&String(Number(Ze))===Ze&&Ze<_e.length||Q&&kt["$"+Ze]instanceof Symbol||(B.call(/[^\w$]/,Ze)?vt.push(le(Ze,_e)+": "+le(_e[Ze],_e)):vt.push(Ze+": "+le(_e[Ze],_e))));if(typeof U=="function")for(var lt=0;lt<Pt.length;lt++)ie.call(_e,Pt[lt])&&vt.push("["+le(Pt[lt])+"]: "+le(_e[Pt[lt]],_e));return vt}return qm}var Um,_x;function Hz(){if(_x)return Um;_x=1;var r=jg(),e=Af(),t=function(c,d,h){for(var p=c,m;(m=p.next)!=null;p=m)if(m.key===d)return p.next=m.next,h||(m.next=c.next,c.next=m),m},n=function(c,d){if(c){var h=t(c,d);return h&&h.value}},o=function(c,d,h){var p=t(c,d);p?p.value=h:c.next={key:d,next:c.next,value:h}},i=function(c,d){return c?!!t(c,d):!1},a=function(c,d){if(c)return t(c,d,!0)};return Um=function(){var d,h={assert:function(p){if(!h.has(p))throw new e("Side channel does not contain "+r(p))},delete:function(p){var m=d&&d.next,g=a(d,p);return g&&m&&m===g&&(d=void 0),!!g},get:function(p){return n(d,p)},has:function(p){return i(d,p)},set:function(p,m){d||(d={next:void 0}),o(d,p,m)}};return h},Um}var Wm,Ax;function RS(){return Ax||(Ax=1,Wm=Object),Wm}var Vm,Ex;function zz(){return Ex||(Ex=1,Vm=Error),Vm}var Gm,Tx;function $z(){return Tx||(Tx=1,Gm=EvalError),Gm}var Ym,Rx;function qz(){return Rx||(Rx=1,Ym=RangeError),Ym}var Zm,kx;function Uz(){return kx||(kx=1,Zm=ReferenceError),Zm}var Km,Ix;function Wz(){return Ix||(Ix=1,Km=SyntaxError),Km}var Xm,Mx;function Vz(){return Mx||(Mx=1,Xm=URIError),Xm}var Jm,Lx;function Gz(){return Lx||(Lx=1,Jm=Math.abs),Jm}var Qm,Dx;function Yz(){return Dx||(Dx=1,Qm=Math.floor),Qm}var e1,Ox;function Zz(){return Ox||(Ox=1,e1=Math.max),e1}var t1,Nx;function Kz(){return Nx||(Nx=1,t1=Math.min),t1}var r1,Px;function Xz(){return Px||(Px=1,r1=Math.pow),r1}var n1,Bx;function Jz(){return Bx||(Bx=1,n1=Math.round),n1}var o1,Fx;function Qz(){return Fx||(Fx=1,o1=Number.isNaN||function(e){return e!==e}),o1}var i1,jx;function e$(){if(jx)return i1;jx=1;var r=Qz();return i1=function(t){return r(t)||t===0?t:t<0?-1:1},i1}var s1,Hx;function t$(){return Hx||(Hx=1,s1=Object.getOwnPropertyDescriptor),s1}var a1,zx;function kS(){if(zx)return a1;zx=1;var r=t$();if(r)try{r([],"length")}catch{r=null}return a1=r,a1}var l1,$x;function r$(){if($x)return l1;$x=1;var r=Object.defineProperty||!1;if(r)try{r({},"a",{value:1})}catch{r=!1}return l1=r,l1}var c1,qx;function n$(){return qx||(qx=1,c1=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},t=Symbol("test"),n=Object(t);if(typeof t=="string"||Object.prototype.toString.call(t)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var o=42;e[t]=o;for(var i in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var a=Object.getOwnPropertySymbols(e);if(a.length!==1||a[0]!==t||!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var c=Object.getOwnPropertyDescriptor(e,t);if(c.value!==o||c.enumerable!==!0)return!1}return!0}),c1}var u1,Ux;function o$(){if(Ux)return u1;Ux=1;var r=typeof Symbol<"u"&&Symbol,e=n$();return u1=function(){return typeof r!="function"||typeof Symbol!="function"||typeof r("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:e()},u1}var d1,Wx;function IS(){return Wx||(Wx=1,d1=typeof Reflect<"u"&&Reflect.getPrototypeOf||null),d1}var f1,Vx;function MS(){if(Vx)return f1;Vx=1;var r=RS();return f1=r.getPrototypeOf||null,f1}var h1,Gx;function i$(){if(Gx)return h1;Gx=1;var r="Function.prototype.bind called on incompatible ",e=Object.prototype.toString,t=Math.max,n="[object Function]",o=function(d,h){for(var p=[],m=0;m<d.length;m+=1)p[m]=d[m];for(var g=0;g<h.length;g+=1)p[g+d.length]=h[g];return p},i=function(d,h){for(var p=[],m=h,g=0;m<d.length;m+=1,g+=1)p[g]=d[m];return p},a=function(c,d){for(var h="",p=0;p<c.length;p+=1)h+=c[p],p+1<c.length&&(h+=d);return h};return h1=function(d){var h=this;if(typeof h!="function"||e.apply(h)!==n)throw new TypeError(r+h);for(var p=i(arguments,1),m,g=function(){if(this instanceof m){var _=h.apply(this,o(p,arguments));return Object(_)===_?_:this}return h.apply(d,o(p,arguments))},v=t(0,h.length-p.length),w=[],T=0;T<v;T++)w[T]="$"+T;if(m=Function("binder","return function ("+a(w,",")+"){ return binder.apply(this,arguments); }")(g),h.prototype){var A=function(){};A.prototype=h.prototype,m.prototype=new A,A.prototype=null}return m},h1}var p1,Yx;function Hg(){if(Yx)return p1;Yx=1;var r=i$();return p1=Function.prototype.bind||r,p1}var g1,Zx;function uy(){return Zx||(Zx=1,g1=Function.prototype.call),g1}var m1,Kx;function LS(){return Kx||(Kx=1,m1=Function.prototype.apply),m1}var v1,Xx;function s$(){return Xx||(Xx=1,v1=typeof Reflect<"u"&&Reflect&&Reflect.apply),v1}var y1,Jx;function a$(){if(Jx)return y1;Jx=1;var r=Hg(),e=LS(),t=uy(),n=s$();return y1=n||r.call(t,e),y1}var b1,Qx;function DS(){if(Qx)return b1;Qx=1;var r=Hg(),e=Af(),t=uy(),n=a$();return b1=function(i){if(i.length<1||typeof i[0]!="function")throw new e("a function is required");return n(r,t,i)},b1}var x1,ew;function l$(){if(ew)return x1;ew=1;var r=DS(),e=kS(),t;try{t=[].__proto__===Array.prototype}catch(a){if(!a||typeof a!="object"||!("code"in a)||a.code!=="ERR_PROTO_ACCESS")throw a}var n=!!t&&e&&e(Object.prototype,"__proto__"),o=Object,i=o.getPrototypeOf;return x1=n&&typeof n.get=="function"?r([n.get]):typeof i=="function"?function(c){return i(c==null?c:o(c))}:!1,x1}var w1,tw;function c$(){if(tw)return w1;tw=1;var r=IS(),e=MS(),t=l$();return w1=r?function(o){return r(o)}:e?function(o){if(!o||typeof o!="object"&&typeof o!="function")throw new TypeError("getProto: not an object");return e(o)}:t?function(o){return t(o)}:null,w1}var C1,rw;function u$(){if(rw)return C1;rw=1;var r=Function.prototype.call,e=Object.prototype.hasOwnProperty,t=Hg();return C1=t.call(r,e),C1}var S1,nw;function dy(){if(nw)return S1;nw=1;var r,e=RS(),t=zz(),n=$z(),o=qz(),i=Uz(),a=Wz(),c=Af(),d=Vz(),h=Gz(),p=Yz(),m=Zz(),g=Kz(),v=Xz(),w=Jz(),T=e$(),A=Function,_=function(Ee){try{return A('"use strict"; return ('+Ee+").constructor;")()}catch{}},R=kS(),D=r$(),I=function(){throw new c},F=R?function(){try{return arguments.callee,I}catch{try{return R(arguments,"callee").get}catch{return I}}}():I,B=o$()(),H=c$(),j=MS(),V=IS(),fe=LS(),P=uy(),U={},G=typeof Uint8Array>"u"||!H?r:H(Uint8Array),Q={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?r:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?r:ArrayBuffer,"%ArrayIteratorPrototype%":B&&H?H([][Symbol.iterator]()):r,"%AsyncFromSyncIteratorPrototype%":r,"%AsyncFunction%":U,"%AsyncGenerator%":U,"%AsyncGeneratorFunction%":U,"%AsyncIteratorPrototype%":U,"%Atomics%":typeof Atomics>"u"?r:Atomics,"%BigInt%":typeof BigInt>"u"?r:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?r:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?r:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?r:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":t,"%eval%":eval,"%EvalError%":n,"%Float16Array%":typeof Float16Array>"u"?r:Float16Array,"%Float32Array%":typeof Float32Array>"u"?r:Float32Array,"%Float64Array%":typeof Float64Array>"u"?r:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?r:FinalizationRegistry,"%Function%":A,"%GeneratorFunction%":U,"%Int8Array%":typeof Int8Array>"u"?r:Int8Array,"%Int16Array%":typeof Int16Array>"u"?r:Int16Array,"%Int32Array%":typeof Int32Array>"u"?r:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":B&&H?H(H([][Symbol.iterator]())):r,"%JSON%":typeof JSON=="object"?JSON:r,"%Map%":typeof Map>"u"?r:Map,"%MapIteratorPrototype%":typeof Map>"u"||!B||!H?r:H(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":e,"%Object.getOwnPropertyDescriptor%":R,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?r:Promise,"%Proxy%":typeof Proxy>"u"?r:Proxy,"%RangeError%":o,"%ReferenceError%":i,"%Reflect%":typeof Reflect>"u"?r:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?r:Set,"%SetIteratorPrototype%":typeof Set>"u"||!B||!H?r:H(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?r:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":B&&H?H(""[Symbol.iterator]()):r,"%Symbol%":B?Symbol:r,"%SyntaxError%":a,"%ThrowTypeError%":F,"%TypedArray%":G,"%TypeError%":c,"%Uint8Array%":typeof Uint8Array>"u"?r:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?r:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?r:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?r:Uint32Array,"%URIError%":d,"%WeakMap%":typeof WeakMap>"u"?r:WeakMap,"%WeakRef%":typeof WeakRef>"u"?r:WeakRef,"%WeakSet%":typeof WeakSet>"u"?r:WeakSet,"%Function.prototype.call%":P,"%Function.prototype.apply%":fe,"%Object.defineProperty%":D,"%Object.getPrototypeOf%":j,"%Math.abs%":h,"%Math.floor%":p,"%Math.max%":m,"%Math.min%":g,"%Math.pow%":v,"%Math.round%":w,"%Math.sign%":T,"%Reflect.getPrototypeOf%":V};if(H)try{null.error}catch(Ee){var ae=H(H(Ee));Q["%Error.prototype%"]=ae}var ie=function Ee(Ne){var Be;if(Ne==="%AsyncFunction%")Be=_("async function () {}");else if(Ne==="%GeneratorFunction%")Be=_("function* () {}");else if(Ne==="%AsyncGeneratorFunction%")Be=_("async function* () {}");else if(Ne==="%AsyncGenerator%"){var Ve=Ee("%AsyncGeneratorFunction%");Ve&&(Be=Ve.prototype)}else if(Ne==="%AsyncIteratorPrototype%"){var Pe=Ee("%AsyncGenerator%");Pe&&H&&(Be=H(Pe.prototype))}return Q[Ne]=Be,Be},oe={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},ne=Hg(),ye=u$(),te=ne.call(P,Array.prototype.concat),re=ne.call(fe,Array.prototype.splice),ge=ne.call(P,String.prototype.replace),Ae=ne.call(P,String.prototype.slice),Te=ne.call(P,RegExp.prototype.exec),se=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,he=/\\(\\)?/g,Ce=function(Ne){var Be=Ae(Ne,0,1),Ve=Ae(Ne,-1);if(Be==="%"&&Ve!=="%")throw new a("invalid intrinsic syntax, expected closing `%`");if(Ve==="%"&&Be!=="%")throw new a("invalid intrinsic syntax, expected opening `%`");var Pe=[];return ge(Ne,se,function(Oe,Ie,we,$e){Pe[Pe.length]=we?ge($e,he,"$1"):Ie||Oe}),Pe},qe=function(Ne,Be){var Ve=Ne,Pe;if(ye(oe,Ve)&&(Pe=oe[Ve],Ve="%"+Pe[0]+"%"),ye(Q,Ve)){var Oe=Q[Ve];if(Oe===U&&(Oe=ie(Ve)),typeof Oe>"u"&&!Be)throw new c("intrinsic "+Ne+" exists, but is not available. Please file an issue!");return{alias:Pe,name:Ve,value:Oe}}throw new a("intrinsic "+Ne+" does not exist!")};return S1=function(Ne,Be){if(typeof Ne!="string"||Ne.length===0)throw new c("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof Be!="boolean")throw new c('"allowMissing" argument must be a boolean');if(Te(/^%?[^%]*%?$/,Ne)===null)throw new a("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var Ve=Ce(Ne),Pe=Ve.length>0?Ve[0]:"",Oe=qe("%"+Pe+"%",Be),Ie=Oe.name,we=Oe.value,$e=!1,it=Oe.alias;it&&(Pe=it[0],re(Ve,te([0,1],it)));for(var at=1,_t=!0;at<Ve.length;at+=1){var Ye=Ve[at],Xe=Ae(Ye,0,1),ft=Ae(Ye,-1);if((Xe==='"'||Xe==="'"||Xe==="`"||ft==='"'||ft==="'"||ft==="`")&&Xe!==ft)throw new a("property names with quotes must have matching quotes");if((Ye==="constructor"||!_t)&&($e=!0),Pe+="."+Ye,Ie="%"+Pe+"%",ye(Q,Ie))we=Q[Ie];else if(we!=null){if(!(Ye in we)){if(!Be)throw new c("base intrinsic for "+Ne+" exists, but the property is not available.");return}if(R&&at+1>=Ve.length){var mt=R(we,Ye);_t=!!mt,_t&&"get"in mt&&!("originalValue"in mt.get)?we=mt.get:we=we[Ye]}else _t=ye(we,Ye),we=we[Ye];_t&&!$e&&(Q[Ie]=we)}}return we},S1}var _1,ow;function OS(){if(ow)return _1;ow=1;var r=dy(),e=DS(),t=e([r("%String.prototype.indexOf%")]);return _1=function(o,i){var a=r(o,!!i);return typeof a=="function"&&t(o,".prototype.")>-1?e([a]):a},_1}var A1,iw;function NS(){if(iw)return A1;iw=1;var r=dy(),e=OS(),t=jg(),n=Af(),o=r("%Map%",!0),i=e("Map.prototype.get",!0),a=e("Map.prototype.set",!0),c=e("Map.prototype.has",!0),d=e("Map.prototype.delete",!0),h=e("Map.prototype.size",!0);return A1=!!o&&function(){var m,g={assert:function(v){if(!g.has(v))throw new n("Side channel does not contain "+t(v))},delete:function(v){if(m){var w=d(m,v);return h(m)===0&&(m=void 0),w}return!1},get:function(v){if(m)return i(m,v)},has:function(v){return m?c(m,v):!1},set:function(v,w){m||(m=new o),a(m,v,w)}};return g},A1}var E1,sw;function d$(){if(sw)return E1;sw=1;var r=dy(),e=OS(),t=jg(),n=NS(),o=Af(),i=r("%WeakMap%",!0),a=e("WeakMap.prototype.get",!0),c=e("WeakMap.prototype.set",!0),d=e("WeakMap.prototype.has",!0),h=e("WeakMap.prototype.delete",!0);return E1=i?function(){var m,g,v={assert:function(w){if(!v.has(w))throw new o("Side channel does not contain "+t(w))},delete:function(w){if(i&&w&&(typeof w=="object"||typeof w=="function")){if(m)return h(m,w)}else if(n&&g)return g.delete(w);return!1},get:function(w){return i&&w&&(typeof w=="object"||typeof w=="function")&&m?a(m,w):g&&g.get(w)},has:function(w){return i&&w&&(typeof w=="object"||typeof w=="function")&&m?d(m,w):!!g&&g.has(w)},set:function(w,T){i&&w&&(typeof w=="object"||typeof w=="function")?(m||(m=new i),c(m,w,T)):n&&(g||(g=n()),g.set(w,T))}};return v}:n,E1}var T1,aw;function f$(){if(aw)return T1;aw=1;var r=Af(),e=jg(),t=Hz(),n=NS(),o=d$(),i=o||n||t;return T1=function(){var c,d={assert:function(h){if(!d.has(h))throw new r("Side channel does not contain "+e(h))},delete:function(h){return!!c&&c.delete(h)},get:function(h){return c&&c.get(h)},has:function(h){return!!c&&c.has(h)},set:function(h,p){c||(c=i()),c.set(h,p)}};return d},T1}var R1,lw;function fy(){if(lw)return R1;lw=1;var r=String.prototype.replace,e=/%20/g,t={RFC1738:"RFC1738",RFC3986:"RFC3986"};return R1={default:t.RFC3986,formatters:{RFC1738:function(n){return r.call(n,e,"+")},RFC3986:function(n){return String(n)}},RFC1738:t.RFC1738,RFC3986:t.RFC3986},R1}var k1,cw;function PS(){if(cw)return k1;cw=1;var r=fy(),e=Object.prototype.hasOwnProperty,t=Array.isArray,n=function(){for(var A=[],_=0;_<256;++_)A.push("%"+((_<16?"0":"")+_.toString(16)).toUpperCase());return A}(),o=function(_){for(;_.length>1;){var R=_.pop(),D=R.obj[R.prop];if(t(D)){for(var I=[],F=0;F<D.length;++F)typeof D[F]<"u"&&I.push(D[F]);R.obj[R.prop]=I}}},i=function(_,R){for(var D=R&&R.plainObjects?{__proto__:null}:{},I=0;I<_.length;++I)typeof _[I]<"u"&&(D[I]=_[I]);return D},a=function A(_,R,D){if(!R)return _;if(typeof R!="object"&&typeof R!="function"){if(t(_))_.push(R);else if(_&&typeof _=="object")(D&&(D.plainObjects||D.allowPrototypes)||!e.call(Object.prototype,R))&&(_[R]=!0);else return[_,R];return _}if(!_||typeof _!="object")return[_].concat(R);var I=_;return t(_)&&!t(R)&&(I=i(_,D)),t(_)&&t(R)?(R.forEach(function(F,B){if(e.call(_,B)){var H=_[B];H&&typeof H=="object"&&F&&typeof F=="object"?_[B]=A(H,F,D):_.push(F)}else _[B]=F}),_):Object.keys(R).reduce(function(F,B){var H=R[B];return e.call(F,B)?F[B]=A(F[B],H,D):F[B]=H,F},I)},c=function(_,R){return Object.keys(R).reduce(function(D,I){return D[I]=R[I],D},_)},d=function(A,_,R){var D=A.replace(/\+/g," ");if(R==="iso-8859-1")return D.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(D)}catch{return D}},h=1024,p=function(_,R,D,I,F){if(_.length===0)return _;var B=_;if(typeof _=="symbol"?B=Symbol.prototype.toString.call(_):typeof _!="string"&&(B=String(_)),D==="iso-8859-1")return escape(B).replace(/%u[0-9a-f]{4}/gi,function(G){return"%26%23"+parseInt(G.slice(2),16)+"%3B"});for(var H="",j=0;j<B.length;j+=h){for(var V=B.length>=h?B.slice(j,j+h):B,fe=[],P=0;P<V.length;++P){var U=V.charCodeAt(P);if(U===45||U===46||U===95||U===126||U>=48&&U<=57||U>=65&&U<=90||U>=97&&U<=122||F===r.RFC1738&&(U===40||U===41)){fe[fe.length]=V.charAt(P);continue}if(U<128){fe[fe.length]=n[U];continue}if(U<2048){fe[fe.length]=n[192|U>>6]+n[128|U&63];continue}if(U<55296||U>=57344){fe[fe.length]=n[224|U>>12]+n[128|U>>6&63]+n[128|U&63];continue}P+=1,U=65536+((U&1023)<<10|V.charCodeAt(P)&1023),fe[fe.length]=n[240|U>>18]+n[128|U>>12&63]+n[128|U>>6&63]+n[128|U&63]}H+=fe.join("")}return H},m=function(_){for(var R=[{obj:{o:_},prop:"o"}],D=[],I=0;I<R.length;++I)for(var F=R[I],B=F.obj[F.prop],H=Object.keys(B),j=0;j<H.length;++j){var V=H[j],fe=B[V];typeof fe=="object"&&fe!==null&&D.indexOf(fe)===-1&&(R.push({obj:B,prop:V}),D.push(fe))}return o(R),_},g=function(_){return Object.prototype.toString.call(_)==="[object RegExp]"},v=function(_){return!_||typeof _!="object"?!1:!!(_.constructor&&_.constructor.isBuffer&&_.constructor.isBuffer(_))},w=function(_,R){return[].concat(_,R)},T=function(_,R){if(t(_)){for(var D=[],I=0;I<_.length;I+=1)D.push(R(_[I]));return D}return R(_)};return k1={arrayToObject:i,assign:c,combine:w,compact:m,decode:d,encode:p,isBuffer:v,isRegExp:g,maybeMap:T,merge:a},k1}var I1,uw;function h$(){if(uw)return I1;uw=1;var r=f$(),e=PS(),t=fy(),n=Object.prototype.hasOwnProperty,o={brackets:function(A){return A+"[]"},comma:"comma",indices:function(A,_){return A+"["+_+"]"},repeat:function(A){return A}},i=Array.isArray,a=Array.prototype.push,c=function(T,A){a.apply(T,i(A)?A:[A])},d=Date.prototype.toISOString,h=t.default,p={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,commaRoundTrip:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:e.encode,encodeValuesOnly:!1,filter:void 0,format:h,formatter:t.formatters[h],indices:!1,serializeDate:function(A){return d.call(A)},skipNulls:!1,strictNullHandling:!1},m=function(A){return typeof A=="string"||typeof A=="number"||typeof A=="boolean"||typeof A=="symbol"||typeof A=="bigint"},g={},v=function T(A,_,R,D,I,F,B,H,j,V,fe,P,U,G,Q,ae,ie,oe){for(var ne=A,ye=oe,te=0,re=!1;(ye=ye.get(g))!==void 0&&!re;){var ge=ye.get(A);if(te+=1,typeof ge<"u"){if(ge===te)throw new RangeError("Cyclic object value");re=!0}typeof ye.get(g)>"u"&&(te=0)}if(typeof V=="function"?ne=V(_,ne):ne instanceof Date?ne=U(ne):R==="comma"&&i(ne)&&(ne=e.maybeMap(ne,function(Ie){return Ie instanceof Date?U(Ie):Ie})),ne===null){if(F)return j&&!ae?j(_,p.encoder,ie,"key",G):_;ne=""}if(m(ne)||e.isBuffer(ne)){if(j){var Ae=ae?_:j(_,p.encoder,ie,"key",G);return[Q(Ae)+"="+Q(j(ne,p.encoder,ie,"value",G))]}return[Q(_)+"="+Q(String(ne))]}var Te=[];if(typeof ne>"u")return Te;var se;if(R==="comma"&&i(ne))ae&&j&&(ne=e.maybeMap(ne,j)),se=[{value:ne.length>0?ne.join(",")||null:void 0}];else if(i(V))se=V;else{var he=Object.keys(ne);se=fe?he.sort(fe):he}var Ce=H?String(_).replace(/\./g,"%2E"):String(_),qe=D&&i(ne)&&ne.length===1?Ce+"[]":Ce;if(I&&i(ne)&&ne.length===0)return qe+"[]";for(var Ee=0;Ee<se.length;++Ee){var Ne=se[Ee],Be=typeof Ne=="object"&&Ne&&typeof Ne.value<"u"?Ne.value:ne[Ne];if(!(B&&Be===null)){var Ve=P&&H?String(Ne).replace(/\./g,"%2E"):String(Ne),Pe=i(ne)?typeof R=="function"?R(qe,Ve):qe:qe+(P?"."+Ve:"["+Ve+"]");oe.set(A,te);var Oe=r();Oe.set(g,oe),c(Te,T(Be,Pe,R,D,I,F,B,H,R==="comma"&&ae&&i(ne)?null:j,V,fe,P,U,G,Q,ae,ie,Oe))}}return Te},w=function(A){if(!A)return p;if(typeof A.allowEmptyArrays<"u"&&typeof A.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof A.encodeDotInKeys<"u"&&typeof A.encodeDotInKeys!="boolean")throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(A.encoder!==null&&typeof A.encoder<"u"&&typeof A.encoder!="function")throw new TypeError("Encoder has to be a function.");var _=A.charset||p.charset;if(typeof A.charset<"u"&&A.charset!=="utf-8"&&A.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var R=t.default;if(typeof A.format<"u"){if(!n.call(t.formatters,A.format))throw new TypeError("Unknown format option provided.");R=A.format}var D=t.formatters[R],I=p.filter;(typeof A.filter=="function"||i(A.filter))&&(I=A.filter);var F;if(A.arrayFormat in o?F=A.arrayFormat:"indices"in A?F=A.indices?"indices":"repeat":F=p.arrayFormat,"commaRoundTrip"in A&&typeof A.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var B=typeof A.allowDots>"u"?A.encodeDotInKeys===!0?!0:p.allowDots:!!A.allowDots;return{addQueryPrefix:typeof A.addQueryPrefix=="boolean"?A.addQueryPrefix:p.addQueryPrefix,allowDots:B,allowEmptyArrays:typeof A.allowEmptyArrays=="boolean"?!!A.allowEmptyArrays:p.allowEmptyArrays,arrayFormat:F,charset:_,charsetSentinel:typeof A.charsetSentinel=="boolean"?A.charsetSentinel:p.charsetSentinel,commaRoundTrip:!!A.commaRoundTrip,delimiter:typeof A.delimiter>"u"?p.delimiter:A.delimiter,encode:typeof A.encode=="boolean"?A.encode:p.encode,encodeDotInKeys:typeof A.encodeDotInKeys=="boolean"?A.encodeDotInKeys:p.encodeDotInKeys,encoder:typeof A.encoder=="function"?A.encoder:p.encoder,encodeValuesOnly:typeof A.encodeValuesOnly=="boolean"?A.encodeValuesOnly:p.encodeValuesOnly,filter:I,format:R,formatter:D,serializeDate:typeof A.serializeDate=="function"?A.serializeDate:p.serializeDate,skipNulls:typeof A.skipNulls=="boolean"?A.skipNulls:p.skipNulls,sort:typeof A.sort=="function"?A.sort:null,strictNullHandling:typeof A.strictNullHandling=="boolean"?A.strictNullHandling:p.strictNullHandling}};return I1=function(T,A){var _=T,R=w(A),D,I;typeof R.filter=="function"?(I=R.filter,_=I("",_)):i(R.filter)&&(I=R.filter,D=I);var F=[];if(typeof _!="object"||_===null)return"";var B=o[R.arrayFormat],H=B==="comma"&&R.commaRoundTrip;D||(D=Object.keys(_)),R.sort&&D.sort(R.sort);for(var j=r(),V=0;V<D.length;++V){var fe=D[V],P=_[fe];R.skipNulls&&P===null||c(F,v(P,fe,B,H,R.allowEmptyArrays,R.strictNullHandling,R.skipNulls,R.encodeDotInKeys,R.encode?R.encoder:null,R.filter,R.sort,R.allowDots,R.serializeDate,R.format,R.formatter,R.encodeValuesOnly,R.charset,j))}var U=F.join(R.delimiter),G=R.addQueryPrefix===!0?"?":"";return R.charsetSentinel&&(R.charset==="iso-8859-1"?G+="utf8=%26%2310003%3B&":G+="utf8=%E2%9C%93&"),U.length>0?G+U:""},I1}var M1,dw;function p$(){if(dw)return M1;dw=1;var r=PS(),e=Object.prototype.hasOwnProperty,t=Array.isArray,n={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:r.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictNullHandling:!1,throwOnLimitExceeded:!1},o=function(g){return g.replace(/&#(\d+);/g,function(v,w){return String.fromCharCode(parseInt(w,10))})},i=function(g,v,w){if(g&&typeof g=="string"&&v.comma&&g.indexOf(",")>-1)return g.split(",");if(v.throwOnLimitExceeded&&w>=v.arrayLimit)throw new RangeError("Array limit exceeded. Only "+v.arrayLimit+" element"+(v.arrayLimit===1?"":"s")+" allowed in an array.");return g},a="utf8=%26%2310003%3B",c="utf8=%E2%9C%93",d=function(v,w){var T={__proto__:null},A=w.ignoreQueryPrefix?v.replace(/^\?/,""):v;A=A.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var _=w.parameterLimit===1/0?void 0:w.parameterLimit,R=A.split(w.delimiter,w.throwOnLimitExceeded?_+1:_);if(w.throwOnLimitExceeded&&R.length>_)throw new RangeError("Parameter limit exceeded. Only "+_+" parameter"+(_===1?"":"s")+" allowed.");var D=-1,I,F=w.charset;if(w.charsetSentinel)for(I=0;I<R.length;++I)R[I].indexOf("utf8=")===0&&(R[I]===c?F="utf-8":R[I]===a&&(F="iso-8859-1"),D=I,I=R.length);for(I=0;I<R.length;++I)if(I!==D){var B=R[I],H=B.indexOf("]="),j=H===-1?B.indexOf("="):H+1,V,fe;j===-1?(V=w.decoder(B,n.decoder,F,"key"),fe=w.strictNullHandling?null:""):(V=w.decoder(B.slice(0,j),n.decoder,F,"key"),fe=r.maybeMap(i(B.slice(j+1),w,t(T[V])?T[V].length:0),function(U){return w.decoder(U,n.decoder,F,"value")})),fe&&w.interpretNumericEntities&&F==="iso-8859-1"&&(fe=o(String(fe))),B.indexOf("[]=")>-1&&(fe=t(fe)?[fe]:fe);var P=e.call(T,V);P&&w.duplicates==="combine"?T[V]=r.combine(T[V],fe):(!P||w.duplicates==="last")&&(T[V]=fe)}return T},h=function(g,v,w,T){var A=0;if(g.length>0&&g[g.length-1]==="[]"){var _=g.slice(0,-1).join("");A=Array.isArray(v)&&v[_]?v[_].length:0}for(var R=T?v:i(v,w,A),D=g.length-1;D>=0;--D){var I,F=g[D];if(F==="[]"&&w.parseArrays)I=w.allowEmptyArrays&&(R===""||w.strictNullHandling&&R===null)?[]:r.combine([],R);else{I=w.plainObjects?{__proto__:null}:{};var B=F.charAt(0)==="["&&F.charAt(F.length-1)==="]"?F.slice(1,-1):F,H=w.decodeDotInKeys?B.replace(/%2E/g,"."):B,j=parseInt(H,10);!w.parseArrays&&H===""?I={0:R}:!isNaN(j)&&F!==H&&String(j)===H&&j>=0&&w.parseArrays&&j<=w.arrayLimit?(I=[],I[j]=R):H!=="__proto__"&&(I[H]=R)}R=I}return R},p=function(v,w,T,A){if(v){var _=T.allowDots?v.replace(/\.([^.[]+)/g,"[$1]"):v,R=/(\[[^[\]]*])/,D=/(\[[^[\]]*])/g,I=T.depth>0&&R.exec(_),F=I?_.slice(0,I.index):_,B=[];if(F){if(!T.plainObjects&&e.call(Object.prototype,F)&&!T.allowPrototypes)return;B.push(F)}for(var H=0;T.depth>0&&(I=D.exec(_))!==null&&H<T.depth;){if(H+=1,!T.plainObjects&&e.call(Object.prototype,I[1].slice(1,-1))&&!T.allowPrototypes)return;B.push(I[1])}if(I){if(T.strictDepth===!0)throw new RangeError("Input depth exceeded depth option of "+T.depth+" and strictDepth is true");B.push("["+_.slice(I.index)+"]")}return h(B,w,T,A)}},m=function(v){if(!v)return n;if(typeof v.allowEmptyArrays<"u"&&typeof v.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof v.decodeDotInKeys<"u"&&typeof v.decodeDotInKeys!="boolean")throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(v.decoder!==null&&typeof v.decoder<"u"&&typeof v.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof v.charset<"u"&&v.charset!=="utf-8"&&v.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");if(typeof v.throwOnLimitExceeded<"u"&&typeof v.throwOnLimitExceeded!="boolean")throw new TypeError("`throwOnLimitExceeded` option must be a boolean");var w=typeof v.charset>"u"?n.charset:v.charset,T=typeof v.duplicates>"u"?n.duplicates:v.duplicates;if(T!=="combine"&&T!=="first"&&T!=="last")throw new TypeError("The duplicates option must be either combine, first, or last");var A=typeof v.allowDots>"u"?v.decodeDotInKeys===!0?!0:n.allowDots:!!v.allowDots;return{allowDots:A,allowEmptyArrays:typeof v.allowEmptyArrays=="boolean"?!!v.allowEmptyArrays:n.allowEmptyArrays,allowPrototypes:typeof v.allowPrototypes=="boolean"?v.allowPrototypes:n.allowPrototypes,allowSparse:typeof v.allowSparse=="boolean"?v.allowSparse:n.allowSparse,arrayLimit:typeof v.arrayLimit=="number"?v.arrayLimit:n.arrayLimit,charset:w,charsetSentinel:typeof v.charsetSentinel=="boolean"?v.charsetSentinel:n.charsetSentinel,comma:typeof v.comma=="boolean"?v.comma:n.comma,decodeDotInKeys:typeof v.decodeDotInKeys=="boolean"?v.decodeDotInKeys:n.decodeDotInKeys,decoder:typeof v.decoder=="function"?v.decoder:n.decoder,delimiter:typeof v.delimiter=="string"||r.isRegExp(v.delimiter)?v.delimiter:n.delimiter,depth:typeof v.depth=="number"||v.depth===!1?+v.depth:n.depth,duplicates:T,ignoreQueryPrefix:v.ignoreQueryPrefix===!0,interpretNumericEntities:typeof v.interpretNumericEntities=="boolean"?v.interpretNumericEntities:n.interpretNumericEntities,parameterLimit:typeof v.parameterLimit=="number"?v.parameterLimit:n.parameterLimit,parseArrays:v.parseArrays!==!1,plainObjects:typeof v.plainObjects=="boolean"?v.plainObjects:n.plainObjects,strictDepth:typeof v.strictDepth=="boolean"?!!v.strictDepth:n.strictDepth,strictNullHandling:typeof v.strictNullHandling=="boolean"?v.strictNullHandling:n.strictNullHandling,throwOnLimitExceeded:typeof v.throwOnLimitExceeded=="boolean"?v.throwOnLimitExceeded:!1}};return M1=function(g,v){var w=m(v);if(g===""||g===null||typeof g>"u")return w.plainObjects?{__proto__:null}:{};for(var T=typeof g=="string"?d(g,w):g,A=w.plainObjects?{__proto__:null}:{},_=Object.keys(T),R=0;R<_.length;++R){var D=_[R],I=p(D,T[D],w,typeof g=="string");A=r.merge(A,I,w)}return w.allowSparse===!0?A:r.compact(A)},M1}var L1,fw;function g$(){if(fw)return L1;fw=1;var r=h$(),e=p$(),t=fy();return L1={formats:t,parse:e,stringify:r},L1}var m$=g$();const v$=yf(m$),yv={StoredContexts:{},defaultHandler:()=>{}},BS={Init:()=>{},Create:r=>{const e=r.method+r.url;return yv.StoredContexts[e]=r,y$(r)},FetchBaseUrl:()=>window.location.href,useDefaultHandler:r=>{yv.defaultHandler=r}};function y$(r){const e=`[${r.method}] ${r.url}`;return{Call:async n=>{let{url:o,method:i,stream:a,paramType:c}=r;const{po:d,onStream:h,onStreamEnd:p,noDefaultHandle:m=[]}=n??{};(c==="query"||i==="GET")&&d!==void 0&&(o+="?"+v$.stringify(d,{arrayFormat:"comma"}));const g={method:i,headers:{Accept:"application/json;charset=UTF-8","X-Requested-With":"XMLHttpRequest","Cache-Control":"no-cache",Pragma:"no-cache",crossDomain:"true"}};if(c==="form"){const T=new FormData;if(d!==void 0)for(const A in d){const _=d[A];T.append(A,_)}g.body=T}else(c==="body"||c===void 0&&r.method!=="GET")&&(g.body=JSON.stringify(d),g.headers["Content-Type"]="application/json;charset=UTF-8");let v={errorCode:0,message:""};const w=Date.now();o=BS.FetchBaseUrl()+o;try{let T=await fetch(o,g);if(T.ok===!1)return v.errorCode=T.status,v.message=T.statusText,v;{const A=new TextDecoder("utf-8");if(a){if(T.body){let _=T.body.getReader(),R="";for(;;){const D=await _.read();if(D.done)break;const I=A.decode(D.value).trim();R+=I;let F=null;try{const B=I.split("\0");let H=B[B.length-1];for(let j=B.length-2;j>=0;j--)if(B[j].trim().length!==0){H=B[j];break}F=await JSON.parse(H)}catch{try{const H=R.split("\0");let j=H[H.length-1];for(let V=H.length-2;V>=0;V--)if(H[V].trim().length!==0){j=H[V];break}F=await JSON.parse(j)}catch{}}if(F!=null&&(Object.keys(F).includes("err_code")?v.errorCode=F.err_code:(v.errorCode=0,v.data=F,R="",D.done?p==null||p(v.data):h==null||h(v.data))),D.done)break}}}else if(T.body){const R=await T.body.getReader().read(),D=A.decode(R.value);if(D==="null")return v;{let I=await JSON.parse(D.replaceAll("\0",""));Object.keys(I).includes("err_code")?(v.errorCode=I.err_code,v.message=I.err_msg):v.data=I}}}}catch(T){console.warn(T),v.errorCode=-1,v.message=T.message}return console.debug(`${e} ${Date.now()-w}ms`),m!==!0&&await yv.defaultHandler(v,m),v}}}exports.ABase=Yr;exports.ABaseStyleKeys=Ow;exports.AButton=Go;exports.AButtonStyleKeys=Pw;exports.AButtonTypes=Y4;exports.ACheckBox=af;exports.ACheckBoxStyleKeys=Hw;exports.AChip=_v;exports.AChipKeys=sC;exports.AChips=aR;exports.AClock=wR;exports.AColFrame=uC;exports.ADatePicker=Rv;exports.ADatePickerStyleKeys=Xw;exports.ADatePickerTypes=Yk;exports.ADateRangePicker=Ev;exports.ADateRangePickerStyleKeys=Jw;exports.ADialog=n6;exports.ADialogStyleKeys=zw;exports.ADialogTypes=r6;exports.ADivideFrame=fC;exports.AEditor=sj;exports.AEditorStyleKeys=jw;exports.AFileBox=p6;exports.AFileBoxStyleKeys=Gw;exports.AFileUploader=H6;exports.AFileUploaderStyleKeys=Yw;exports.AFloatMenu=gC;exports.AFloatMenuKeys=rC;exports.AFrameStyleKeys=tC;exports.AGrow=Xu;exports.AIcon=en;exports.AIconButton=ho;exports.AIconButtonStyleKeys=Qw;exports.AIconButtonTypes=Z4;exports.AIconHOC=e4;exports.AIcons=wv;exports.AInput=Vc;exports.AInputStyleKeys=Bw;exports.AInputTypes=OR;exports.AListView=X6;exports.AListViewStyleKeys=Zw;exports.ALoadingBorder=Iv;exports.ALoadingBorderKeys=nC;exports.AMultiSelect=_I;exports.AMultiSelectStyleKeys=qw;exports.ANumInput=V6;exports.AOverflowFrame=el;exports.AProgressBar=Cw;exports.ARadioSelect=cI;exports.ARadioSelectKeys=iC;exports.ARowFrame=Rn;exports.ASelect=Gc;exports.ASelectStyleKeys=$w;exports.ASelectTypes=ZR;exports.ASpace=Nn;exports.AStepper=jI;exports.AStepperStyleKeys=Kw;exports.ASwitch=Tw;exports.ASwitchFrame=dC;exports.ASwitchStyleKeys=Ww;exports.ATab=yC;exports.ATabStyleKeys=Vw;exports.ATabTypes=XI;exports.ATable=i9;exports.ATableStyleKeys=eC;exports.AText=SC;exports.ATextArea=m9;exports.ATextAreaStyleKeys=Fw;exports.ATextAreaTypes=g9;exports.AThemeButton=w5;exports.AThemes=uh;exports.ATooltip=Ew;exports.ATooltipStyleKeys=Nw;exports.ATree=Dz;exports.ATreeStyleKeys=Uw;exports.AWrap=Wc;exports.AWrapKeys=oC;exports.AWrapPropsExtract=Ku;exports.AWrapTypes=t5;exports.ApiContext=BS;exports.BodyStyleKeys=Dw;exports.CreateADC=c6;exports.DefaultOptionRenderer=vC;exports.EDir12=bf;exports.EDir4=Io;exports.FileSizeTrans=qu;exports.Icons=xg;exports.IsCursorPointer=yw;exports.IsFixedShape=vw;exports.IsInteractive=bw;exports.NoSelect=gw;exports.NoTransition=mw;exports.Resources=wr;exports.SetResources=g4;exports.alphanumericRegex=cR;exports.bound=ch;exports.cbF=Er;exports.changeSemanticMode=Sv;exports.componentStyleKeys=h5;exports.createEvent=Bu;exports.dateF=Qt;exports.dbF=sa;exports.defaultPredicate=xC;exports.dlgF=u6;exports.emailIdRegex=dR;exports.emailRegex=uR;exports.fileF=Fu;exports.getFileKey=pC;exports.getMonthsOptions=Sh;exports.getYearsOptions=Tv;exports.hangulRegex=hR;exports.hexRegex=fR;exports.key=pw;exports.noHanguljamoRegex=gR;exports.noSpaceRegex=pR;exports.numF=mC;exports.objF=ar;exports.paletteKeys=Rw;exports.paletteModes=wg;exports.passwordRegex=vR;exports.refinedDesignTokens=Lo;exports.sF=Ke;exports.semanticKeys=Mw;exports.semanticModes=sf;exports.setDir12Style=Cv;exports.setDir12StyleElem=_w;exports.specialCharRegex=mR;exports.strF=Av;exports.tableF=Pl;exports.textMeasurement=$u;exports.treeF=Nc;exports.useADialogCore=a6;exports.useADialogCores=s6;exports.useDB=lC;exports.useEvent=CC;exports.useInit=bC;exports.useLayoutDB=cC;exports.useValues=wn;exports.uuidRegex=yR;
|
package/dist/index.es.js
CHANGED
@@ -40462,6 +40462,7 @@ const Fu = {
|
|
40462
40462
|
/* @__PURE__ */ C.jsx("span", { children: w && fe["*Change order to row drag"] })
|
40463
40463
|
] })
|
40464
40464
|
] }),
|
40465
|
+
W && /* @__PURE__ */ C.jsx("div", { className: wn.TreeTopAddon, children: W }),
|
40465
40466
|
/* @__PURE__ */ C.jsx("div", { ref: Ue, className: Xe.clsx(ie.className, wn.AContainer), children: /* @__PURE__ */ C.jsxs(
|
40466
40467
|
"div",
|
40467
40468
|
{
|
@@ -40472,7 +40473,6 @@ const Fu = {
|
|
40472
40473
|
},
|
40473
40474
|
children: [
|
40474
40475
|
/* @__PURE__ */ C.jsxs("div", { ref: wr, className: wn.ATreeBody, children: [
|
40475
|
-
W && /* @__PURE__ */ C.jsx("div", { className: wn.TreeTopAddon, children: W }),
|
40476
40476
|
Te.length === 0 ? I ? /* @__PURE__ */ C.jsx(uz, { text: fe["Loading Contents..."] }) : S : null,
|
40477
40477
|
/* @__PURE__ */ C.jsx(
|
40478
40478
|
tH,
|