PageSourceSearch

https://streetartcities.com/_next/static/chunks/1t2yerdcgv41t.js

js streetartcities.com collected 2026-09-24 08:58:41 UTC 77,393 bytes, 1 lines download raw bytes

1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,995328,e=>{"use strict";var t=e.i(26863),r=e.i(122525);let n=["shift","alt","meta","mod","ctrl","control"],i={esc:"escape",return:"enter",left:"arrowleft",right:"arrowright",up:"arrowup",down:"arrowdown",ShiftLeft:"shift",ShiftRight:"shift",AltLeft:"alt",AltRight:"alt",MetaLeft:"meta",MetaRight:"meta",OSLeft:"meta",OSRight:"meta",ControlLeft:"ctrl",ControlRight:"ctrl"};function l(e){return(i[e.trim()]||e.trim()).toLowerCase().replace(/key|digit|numpad/,"")}function a(e){return n.includes(e)}function o(e,t=","){return e.toLowerCase().split(t)}function s(e,t="+",r=">",i=!1,a,o){let d=[],u=!1;(e=e.trim()).includes(r)?(u=!0,d=e.toLocaleLowerCase().split(r).map(e=>l(e))):d=e.toLocaleLowerCase().split(t).map(e=>l(e));let c={alt:d.includes("alt"),ctrl:d.includes("ctrl")||d.includes("control"),shift:d.includes("shift"),meta:d.includes("meta"),mod:d.includes("mod"),useKey:i},h=d.filter(e=>!n.includes(e));return{...c,keys:h,description:a,isSequence:u,hotkey:e,metadata:o}}"u">typeof document&&(document.addEventListener("keydown",e=>{void 0!==e.code&&c([l(e.code)])}),document.addEventListener("keyup",e=>{void 0!==e.code&&h([l(e.code)])})),"u">typeof window&&(window.addEventListener("blur",()=>{d.clear()}),window.addEventListener("focus",()=>{d.clear()}),window.addEventListener("contextmenu",()=>{setTimeout(()=>{d.clear()},0)})),"u">typeof document&&document.addEventListener("visibilitychange",()=>{d.clear()});let d=new Set;function u(e){return Array.isArray(e)}function c(e){let t=Array.isArray(e)?e:[e];d.has("meta")&&d.forEach(e=>{a(e)||d.delete(e.toLowerCase())}),t.forEach(e=>{d.add(e.toLowerCase())})}function h(e){let t=Array.isArray(e)?e:[e];"meta"===e?d.clear():t.forEach(e=>{d.delete(e.toLowerCase())})}let f=["input","textarea","select","searchbox","slider","spinbutton","menuitem","menuitemcheckbox","menuitemradio","option","radio","textbox"];function g(e,t=!1){var r;let n,i,{target:l,composed:a}=e;return(r=l).tagName&&!r.tagName.startsWith("-")&&r.tagName.includes("-")&&a?(n=e.composedPath()[0]&&e.composedPath()[0].tagName,i=e.composedPath()[0]&&e.composedPath()[0].role):(n=l&&l.tagName,i=l&&l.role),u(t)?!!(n&&t?.some(e=>e.toLowerCase()===n.toLowerCase()||e===i)):!!(n&&t&&t)}let p=(0,r.createContext)(void 0),m=(0,r.createContext)({hotkeys:[],activeScopes:[],toggleScope:()=>{},enableScope:()=>{},disableScope:()=>{}}),v="u">typeof window?r.useLayoutEffect:r.useEffect;function w(e,t,n,i){var w;let y,[b,x]=(0,r.useState)(null),C=(0,r.useCallback)(e=>(x(e),()=>x(null)),[]),D=(0,r.useRef)(!1),E=Array.isArray(n)?Array.isArray(i)?void 0:i:n,S=u(e)?e.join(E?.delimiter):e,k=Array.isArray(n)?n:Array.isArray(i)?i:void 0,R=(0,r.useCallback)(t,k??[]),M=(0,r.useRef)(R);k?M.current=R:M.current=t;let O=(w=function(e){if(!e)return;let{enabled:t,preventDefault:r,ignoreEventWhen:n,...i}=e;return"function"==typeof t?i:{...i,enabled:t}}(E),function e(t,r){return t&&r&&"object"==typeof t&&"object"==typeof r?Object.keys(t).length===Object.keys(r).length&&Object.keys(t).reduce((n,i)=>n&&e(t[i],r[i]),!0):t===r}((y=(0,r.useRef)(void 0)).current,w)||(y.current=w),y.current),L=(0,r.useRef)(E?.enabled);L.current=E?.enabled;let N=(0,r.useRef)(E?.preventDefault);N.current=E?.preventDefault;let j=(0,r.useRef)(E?.ignoreEventWhen);j.current=E?.ignoreEventWhen;let{activeScopes:A}=(0,r.useContext)(m),T=(0,r.useContext)(p);return v(()=>{var e;if(!1===L.current||(e=O?.scopes,!((0!==A.length||!e)&&(!e||A.some(t=>e.includes(t))||A.includes("*")))))return;let t=[],r,n=(e,n=!1)=>
1{if(!(g(e,f)&&!g(e,O?.enableOnFormTags))){if(null!==b){let t=b.getRootNode();if((t instanceof Document||t instanceof ShadowRoot)&&t.activeElement!==b&&!b.contains(t.activeElement))return void(e.stopPropagation(),e.preventDefault(),e.stopImmediatePropagation())}e.target?.isContentEditable&&!O?.enableOnContentEditable||o(S,O?.delimiter).forEach(i=>{if(i.includes(O?.splitKey??"+")&&i.includes(O?.sequenceSplitKey??">"))return void console.warn(`Hotkey ${i} contains both ${O?.splitKey??"+"} and ${O?.sequenceSplitKey??">"} which is not supported.`);let o=s(i,O?.splitKey,O?.sequenceSplitKey,O?.useKey,O?.description,O?.metadata);if(o.isSequence){r=setTimeout(()=>{t=[]},O?.sequenceTimeoutMs??1e3);let n=o.useKey?e.key:l(e.code);if(a(n.toLowerCase()))return;if(t.push(n),n!==o.keys?.[t.length-1]){t=[],r&&clearTimeout(r);return}t.length===o.keys?.length&&(M.current(e,o),r&&clearTimeout(r),t=[])}else if(((e,t,r=!1)=>{let{alt:n,meta:i,mod:a,shift:o,ctrl:s,keys:c,useKey:h}=t,{code:f,key:g,ctrlKey:p,metaKey:m,shiftKey:v,altKey:w}=e,y=l(f);if(h&&c?.length===1&&c.includes(g.toLowerCase()))return!0;if(!c?.includes(y)&&!["ctrl","control","unknown","meta","alt","shift","os"].includes(y))return!1;if(!r){if(n!==w&&"alt"!==y||o!==v&&"shift"!==y)return!1;if(a){if(!(typeof navigator>"u")&&/mac/i.test(navigator.userAgent)&&!/iphone|ipad|ipod/i.test(navigator.userAgent)?!m:!p)return!1}else if(i!==m&&"meta"!==y&&"os"!==y||s!==p&&"ctrl"!==y&&"control"!==y)return!1}return!!(c&&1===c.length&&c.includes(y))||(c&&c.length>0?!!c.includes(y)&&function(e,t=","){return(u(e)?e:e.split(t)).every(e=>d.has(e.trim().toLowerCase()))}(c):!c||0===c.length)})(e,o,O?.ignoreModifiers)||o.keys?.includes("*")){var c,h;if(j.current?.(e)||n&&D.current||(("function"==typeof(c=N.current)&&c(e,o)||!0===c)&&e.preventDefault(),"function"==typeof(h=L.current)?!h(e,o):!0!==h&&void 0!==h))return;M.current(e,o),n||(D.current=!0)}})}},i=e=>{void 0!==e.code&&(c(l(e.code)),(O?.keydown===void 0&&O?.keyup!==!0||O?.keydown)&&n(e))},p=e=>{void 0!==e.code&&(h(l(e.code)),D.current=!1,O?.keyup&&n(e,!0))},m=b||E?.document||document;return m.addEventListener("keyup",p,E?.eventListenerOptions),m.addEventListener("keydown",i,E?.eventListenerOptions),T&&o(S,O?.delimiter).forEach(e=>{T.addHotkey(s(e,O?.splitKey,O?.sequenceSplitKey,O?.useKey,O?.description,O?.metadata))}),()=>{m.removeEventListener("keyup",p,E?.eventListenerOptions),m.removeEventListener("keydown",i,E?.eventListenerOptions),T&&o(S,O?.delimiter).forEach(e=>{T.removeHotkey(s(e,O?.splitKey,O?.sequenceSplitKey,O?.useKey,O?.description,O?.metadata))}),t=[],r&&clearTimeout(r)}},[b,O,A,S]),C}var y=e.i(964053);e.s(["default",0,({src:e,onClose:n})=>{let i=Array.isArray(e),[l,a]=(0,r.useState)(i?e[0]:0);if(w("left",()=>{if(e&&i)return a(Math.max(0,l-1)),!1},[e,l]),w("right",()=>{if(e&&i)return a(Math.min(e[1].length-1,l+1)),!1},[e,l]),(0,r.useEffect)(()=>{i&&a(e[0])},[e]),!e)return null;let o=i?e[1][l]:e;return(0,t.jsx)(y.Dialog.Root,{open:!0,onOpenChange:e=>{e||n()},children:(0,t.jsx)(y.Dialog.Portal,{children:(0,t.jsxs)(y.Dialog.Content,{className:"fixed inset-0 z-[1102] bg-black/70 flex flex-col items-center justify-center outline-none",onOpenAutoFocus:e=>e.preventDefault(),onCloseAutoFocus:e=>{e.preventDefault(),document.body.style.pointerEvents=""},children:[(0,t.jsx)(y.Dialog.Title,{className:"sr-only",children:"Image preview"}),(0,t.jsx)("div",{className:`p-10 flex-1 w-full cursor-pointer h-full flex items-center justify-center ${i?"pb-3":""}`,onClick:n,title:"Click to close",children:(0,t.jsx)("img",{alt:"Image",src:o,className:"cursor-default h-full max-w-full object-contain"},l)}),i&&(0,t.jsx)("div",{className:"flex mb-10 relative z-10",children:e[1].map((e,r)=>(0,t.jsx)("button",{className:`p-1 block ${r===l?"":"opacity-40 cursor-pointer"}`,onClick:()=>(a(r),!1),children:(0,t.jsx)("span",{className:"w-2 h-2 block bg-white rounded-md"})},r))})]})})})}],995328)},116019,e=>{"use strict";var t=e.i(373765);e.s(["Trash",()=>t.default])},56143,e=>{"use strict";var t=e.i(26863),r=e.i(122525);let n=(0,e.i(475254).default)("crop",[["path",{d:"M6 2v14a2 2 0 0 0 2 2h14",key:"ron5a4"}],["path",{d:"M18 22V8a2 2 0 0 0-2-2H2",key:"7s9ehn"}]]);var i=e.i(422233),l=r,a=Object.defineProperty,o=(e,t,r)=>{let n;return(n="symbol"!=typeof t?t+"":t)in e?a(e,n,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[n]=r};let s={x:0,y:0,width:0,height:0,unit:"px"},d=(e,t,r)=>
1Math.min(Math.max(e,t),r),u=(e,t)=>e===t||e.width===t.width&&e.height===t.height&&e.x===t.x&&e.y===t.y&&e.unit===t.unit;function c(e,t,r){return"%"===e.unit?{...s,...e,unit:"%"}:{unit:"%",x:e.x?e.x/t*100:0,y:e.y?e.y/r*100:0,width:e.width?e.width/t*100:0,height:e.height?e.height/r*100:0}}function h(e,t,r){return e.unit?"px"===e.unit?{...s,...e,unit:"px"}:{unit:"px",x:e.x?e.x*t/100:0,y:e.y?e.y*r/100:0,width:e.width?e.width*t/100:0,height:e.height?e.height*r/100:0}:{...s,...e,unit:"px"}}function f(e,t,r,n,i,l=0,a=0,o=n,s=i){let d={...e},u=Math.min(l,n),c=Math.min(a,i),h=Math.min(o,n),g=Math.min(s,i);t&&(t>1?(c=(u=a?a*t:u)/t,h=o*t):(u=(c=l?l/t:c)*t,g=s/t)),d.y<0&&(d.height=Math.max(d.height+d.y,c),d.y=0),d.x<0&&(d.width=Math.max(d.width+d.x,u),d.x=0);let p=n-(d.x+d.width);p<0&&(d.x=Math.min(d.x,n-u),d.width+=p);let m=i-(d.y+d.height);if(m<0&&(d.y=Math.min(d.y,i-c),d.height+=m),d.width<u&&(("sw"===r||"nw"==r)&&(d.x-=u-d.width),d.width=u),d.height<c&&(("nw"===r||"ne"==r)&&(d.y-=c-d.height),d.height=c),d.width>h&&(("sw"===r||"nw"==r)&&(d.x-=h-d.width),d.width=h),d.height>g&&(("nw"===r||"ne"==r)&&(d.y-=g-d.height),d.height=g),t){let e=d.width/d.height;if(e<t){let e=Math.max(d.width/t,c);("nw"===r||"ne"==r)&&(d.y-=e-d.height),d.height=e}else if(e>t){let e=Math.max(d.height*t,u);("sw"===r||"nw"==r)&&(d.x-=e-d.width),d.width=e}}return d}let g={capture:!0,passive:!1},p=0,m=class e extends l.PureComponent{constructor(){super(...arguments),o(this,"docMoveBound",!1),o(this,"mouseDownOnCrop",!1),o(this,"dragStarted",!1),o(this,"evData",{startClientX:0,startClientY:0,startCropX:0,startCropY:0,clientX:0,clientY:0,isResize:!0}),o(this,"componentRef",(0,l.createRef)()),o(this,"mediaRef",(0,l.createRef)()),o(this,"resizeObserver"),o(this,"initChangeCalled",!1),o(this,"instanceId",`rc-${p++}`),o(this,"state",{cropIsActive:!1,newCropIsBeingDrawn:!1}),o(this,"onCropPointerDown",e=>{let{crop:t,disabled:r}=this.props,n=this.getBox();if(!t)return;let i=h(t,n.width,n.height);if(r)return;e.cancelable&&e.preventDefault(),this.bindDocMove(),this.componentRef.current.focus({preventScroll:!0});let l=e.target.dataset.ord,a=e.clientX,o=e.clientY,s=i.x,d=i.y;if(l){let t=e.clientX-n.x,r=e.clientY-n.y,u=0,c=0;"ne"===l||"e"==l?(u=t-(i.x+i.width),c=r-i.y,s=i.x,d=i.y+i.height):"se"===l||"s"===l?(u=t-(i.x+i.width),c=r-(i.y+i.height),s=i.x,d=i.y):"sw"===l||"w"==l?(u=t-i.x,c=r-(i.y+i.height),s=i.x+i.width,d=i.y):("nw"===l||"n"==l)&&(u=t-i.x,c=r-i.y,s=i.x+i.width,d=i.y+i.height),a=s+n.x+u,o=d+n.y+c}this.evData={startClientX:a,startClientY:o,startCropX:s,startCropY:d,clientX:e.clientX,clientY:e.clientY,isResize:!!l,ord:l},this.mouseDownOnCrop=!0,this.setState({cropIsActive:!0})}),o(this,"onComponentPointerDown",e=>{let{crop:t,disabled:r,locked:n,keepSelection:i,onChange:l}=this.props,a=this.getBox();if(r||n||i&&t)return;e.cancelable&&e.preventDefault(),this.bindDocMove(),this.componentRef.current.focus({preventScroll:!0});let o=e.clientX-a.x,s=e.clientY-a.y,d={unit:"px",x:o,y:s,width:0,height:0};this.evData={startClientX:e.clientX,startClientY:e.clientY,startCropX:o,startCropY:s,clientX:e.clientX,clientY:e.clientY,isResize:!0},this.mouseDownOnCrop=!0,l(h(d,a.width,a.height),c(d,a.width,a.height)),this.setState({cropIsActive:!0,newCropIsBeingDrawn:!0})}),o(this,"onDocPointerMove",e=>{let t,{crop:r,disabled:n,onChange:i,onDragStart:l}=this.props,a=this.getBox();if(n||!r||!this.mouseDownOnCrop)return;e.cancelable&&e.preventDefault(),this.dragStarted||(this.dragStarted=!0,l&&l(e));let{evData:o}=this;o.clientX=e.clientX,o.clientY=e.clientY,u(r,t=o.isResize?this.resizeCrop():this.dragCrop())||i(h(t,a.width,a.height),c(t,a.width,a.height))}),o(this,"onComponentKeyDown",t=>{let{crop:r,disabled:n,onChange:i,onComplete:l}=this.props;if(n)return;let a=t.key,o=!1;if(!r)return;let s=this.getBox(),u=this.makePixelCrop(s),f=(navigator.platform.match("Mac")?t.metaKey:t.ctrlKey)?e.nudgeStepLarge:t.shiftKey?e.nudgeStepMedium:e.nudgeStep;if("ArrowLeft"===a?(u.x-=f,o=!0):"ArrowRight"===a?(u.x+=f,o=!0):"ArrowUp"===a?(u.y-=f,o=!0):"ArrowDown"===a&&(u.y+=f,o=!0),o){t.cancelable&&t.preventDefault(),u.x=d(u.x,0,s.width-u.width),u.y=d(u.y,0,s.height-u.height);let e=h(u,s.width,s.height),r=c(u,s.width,s.height);i(e,r),l&&l(e,r)}}),o(this,"onHandlerKeyDown",(t,r)=>{var n,i;let l,{aspect:a=0,crop:o,disabled:s,minWidth:d=0,minHeight:g=0,maxWidth:p,maxHeight:m,onChange:v,onComplete:w}=this.props,y=this.getBox();if(s||!o||"ArrowUp"!==t.key&&"ArrowDown"!==t.key&&"ArrowLeft"!==t.key&&"ArrowRight"!==t.key)return;t.stopPropagation(),t.preventDefault();let b=(navigator.platform.match("Mac")?t.metaKey:t.ctrlKey)?e.nudgeStepLarge:t.shiftKey?e.nudgeStepMedium:e.nudgeStep,x=f((n=h(o,y.width,y.height),i=t.key,l={...n},"ArrowLeft"===i?"nw"===r?(l.x-=b,l.y-=b,l.width+=b,l.height+=b):"w"===r?(l.x-=b,l.width+=b):"sw"===r?(l.x-=b,l.width+=b,l.height+=b):"ne"===r?(l.y+=b,l.width-=b,l.height-=b):"e"===r?l.width-=b:"se"===r&&(l.width-=b,l.height-=b):"ArrowRight"===i&&("nw"===r?(l.x+=b,l.y+=b,l.width-=b,l.height-=b):"w"===r?(l.x+=b,l.width-=b):"sw"===r?(l.x+=b,l.width-=b,l.height-=b):"ne"===r?(l.y-=b,l.width+=b,l.height+=b):"e"===r?l.width+=b:"se"===r&&(l.width+=b,l.height+=b)),"ArrowUp"===i?"nw"===r?(l.x-=b,l.y-=b,l.width+=b,l.height+=b):"n"===r?(l.y-=b,l.height+=b):"ne"===r?(l.y-=b,l.width+=b,l.height+=b):"sw"===r?(l.x+=b,l.width-=b,l.height-=b):"s"===r?l.height-=b:"se"===r&&(l.width-=b,l.height-=b):"ArrowDown"===i&&("nw"===r?(l.x+=b,l.y+=b,l.width-=b,l.height-=b):"n"===r?(l.y+=b,l.height-=b):"ne"===r?(l.y+=b,l.width-=b,l.height-=b):"sw"===r?(l.x-=b,l.width+=b,l.height+=b):"s"===r?l.height+=b:"se"===r&&(l.width+=b,l.height+=b)),l),a,r,y.width,y.height,d,g,p,m);if(!u(o,x)){let e=c(x,y.width,y.height);v(x,e),w&&w(x,e)}}),o(this,"onDocPointerDone",e=>{let{crop:t,disabled:r,onComplete:n,onDragEnd:i}=this.props,l=this.getBox();this.unbindDocMove(),!(r||!t)&&this.mouseDownOnCrop&&(this.mouseDownOnCrop=!1,this.dragStarted=!1,i&&i(e),n&&n(h(t,l.width,l.height),c(t,l.width,l.height)),this.setState({cropIsActive:!1,newCropIsBeingDrawn:!1}))}),o(this,"onDragFocus",()=>{var e;null==(e=this.componentRef.current)||e.scrollTo(0,0)})}get document(){return document}getBox(){let e=this.mediaRef.current;if(!e)return{x:0,y:0,width:0,height:0};let{x:t,y:r,width:n,height:i}=e.getBoundingClientRect();return{x:t,y:r,width:n,height:i}}componentDidUpdate(e){let{crop:t,onComplete:r}=this.props;if(r&&!e.crop&&t){let{width:e,height:n}=this.getBox();e&&n&&r(h(t,e,n),c(t,e,n))}}componentWillUnmount(){this.resizeObserver&&this.resizeObserver.disconnect(),this.unbindDocMove()}bindDocMove(){this.docMoveBound||(this.document.addEventListener("pointermove",this.onDocPointerMove,g),this.document.addEventListener("pointerup",this.onDocPointerDone,g),this.document.addEventListener("pointercancel",this.onDocPointerDone,g),this.docMoveBound=!0)}
1unbindDocMove(){this.docMoveBound&&(this.document.removeEventListener("pointermove",this.onDocPointerMove,g),this.document.removeEventListener("pointerup",this.onDocPointerDone,g),this.document.removeEventListener("pointercancel",this.onDocPointerDone,g),this.docMoveBound=!1)}getCropStyle(){let{crop:e}=this.props;if(e)return{top:`${e.y}${e.unit}`,left:`${e.x}${e.unit}`,width:`${e.width}${e.unit}`,height:`${e.height}${e.unit}`}}dragCrop(){let{evData:e}=this,t=this.getBox(),r=this.makePixelCrop(t),n=e.clientX-e.startClientX,i=e.clientY-e.startClientY;return r.x=d(e.startCropX+n,0,t.width-r.width),r.y=d(e.startCropY+i,0,t.height-r.height),r}getPointRegion(e,t,r,n){let i,{evData:l}=this,a=l.clientX-e.x,o=l.clientY-e.y;return i=n&&t?"nw"===t||"n"===t||"ne"===t:o<l.startCropY,(r&&t?"nw"===t||"w"===t||"sw"===t:a<l.startCropX)?i?"nw":"sw":i?"ne":"se"}resolveMinDimensions(e,t,r=0,n=0){let i=Math.min(r,e.width),l=Math.min(n,e.height);return t&&(i||l)?t>1?i?[i,i/t]:[l*t,l]:l?[l*t,l]:[i,i/t]:[i,l]}resizeCrop(){let{evData:t}=this,{aspect:r=0,maxWidth:n,maxHeight:i}=this.props,l=this.getBox(),[a,o]=this.resolveMinDimensions(l,r,this.props.minWidth,this.props.minHeight),s=this.makePixelCrop(l),u=this.getPointRegion(l,t.ord,a,o),c=t.ord||u,h=t.clientX-t.startClientX,g=t.clientY-t.startClientY;(a&&"nw"===c||"w"===c||"sw"===c)&&(h=Math.min(h,-a)),(o&&"nw"===c||"n"===c||"ne"===c)&&(g=Math.min(g,-o));let p={unit:"px",x:0,y:0,width:0,height:0};"ne"===u?(p.x=t.startCropX,p.width=h,r?p.height=p.width/r:p.height=Math.abs(g),p.y=t.startCropY-p.height):"se"===u?(p.x=t.startCropX,p.y=t.startCropY,p.width=h,r?p.height=p.width/r:p.height=g):"sw"===u?(p.x=t.startCropX+h,p.y=t.startCropY,p.width=Math.abs(h),r?p.height=p.width/r:p.height=g):"nw"===u&&(p.x=t.startCropX+h,p.width=Math.abs(h),r?(p.height=p.width/r,p.y=t.startCropY-p.height):(p.height=Math.abs(g),p.y=t.startCropY+g));let m=f(p,r,u,l.width,l.height,a,o,n,i);return r||e.xyOrds.indexOf(c)>-1?s=m:e.xOrds.indexOf(c)>-1?(s.x=m.x,s.width=m.width):e.yOrds.indexOf(c)>-1&&(s.y=m.y,s.height=m.height),s.x=d(s.x,0,l.width-s.width),s.y=d(s.y,0,l.height-s.height),s}renderCropSelection(){let{ariaLabels:t=e.defaultProps.ariaLabels,disabled:r,locked:n,renderSelectionAddon:i,ruleOfThirds:a,crop:o}=this.props,s=this.getCropStyle();if(o)return l.default.createElement("div",{style:s,className:"ReactCrop__crop-selection",onPointerDown:this.onCropPointerDown,"aria-label":t.cropArea,tabIndex:0,onKeyDown:this.onComponentKeyDown,role:"group"},!r&&!n&&l.default.createElement("div",{className:"ReactCrop__drag-elements",onFocus:this.onDragFocus},l.default.createElement("div",{className:"ReactCrop__drag-bar ord-n","data-ord":"n"}),l.default.createElement("div",{className:"ReactCrop__drag-bar ord-e","data-ord":"e"}),l.default.createElement("div",{className:"ReactCrop__drag-bar ord-s","data-ord":"s"}),l.default.createElement("div",{className:"ReactCrop__drag-bar ord-w","data-ord":"w"}),l.default.createElement("div",{className:"ReactCrop__drag-handle ord-nw","data-ord":"nw",tabIndex:0,"aria-label":t.nwDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"nw"),role:"button"}),l.default.createElement("div",{className:"ReactCrop__drag-handle ord-n","data-ord":"n",tabIndex:0,"aria-label":t.nDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"n"),role:"button"}),l.default.createElement("div",{className:"ReactCrop__drag-handle ord-ne","data-ord":"ne",tabIndex:0,"aria-label":t.neDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"ne"),role:"button"}),l.default.createElement("div",{className:"ReactCrop__drag-handle ord-e","data-ord":"e",tabIndex:0,"aria-label":t.eDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"e"),role:"button"}),l.default.createElement("div",{className:"ReactCrop__drag-handle ord-se","data-ord":"se",tabIndex:0,"aria-label":t.seDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"se"),role:"button"}),l.default.createElement("div",{className:"ReactCrop__drag-handle ord-s","data-ord":"s",tabIndex:0,"aria-label":t.sDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"s"),role:"button"}),l.default.createElement("div",{className:"ReactCrop__drag-handle ord-sw","data-ord":"sw",tabIndex:0,"aria-label":t.swDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"sw"),role:"button"}),l.default.createElement("div",{className:"ReactCrop__drag-handle ord-w","data-ord":"w",tabIndex:0,"aria-label":t.wDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"w"),role:"button"})),i&&l.default.createElement("div",{className:"ReactCrop__selection-addon",onPointerDown:e=>e.stopPropagation()},i(this.state)),a&&l.default.createElement(l.default.Fragment,null,l.default.createElement("div",{className:"ReactCrop__rule-of-thirds-hz"}),l.default.createElement("div",{className:"ReactCrop__rule-of-thirds-vt"})))}makePixelCrop(e){return h({...s,...this.props.crop||{}},e.width,e.height)}render(){let{aspect:e,children:t,circularCrop:r,className:n,crop:i,disabled:a,locked:o,style:s,ruleOfThirds:d}=this.props,{cropIsActive:u,newCropIsBeingDrawn:c}=this.state,h=i?this.renderCropSelection():null,f=((...e)=>e.filter(e=>e&&"string"==typeof e).join(" "))("ReactCrop",n,u&&"ReactCrop--active",a&&"ReactCrop--disabled",o&&"ReactCrop--locked",c&&"ReactCrop--new-crop",i&&e&&"ReactCrop--fixed-aspect",i&&r&&"ReactCrop--circular-crop",i&&d&&"ReactCrop--rule-of-thirds",!this.dragStarted&&i&&!i.width&&!i.height&&"ReactCrop--invisible-crop",r&&"ReactCrop--no-animate");return l.default.createElement("div",{ref:this.componentRef,className:f,style:s},l.default.createElement("div",{ref:this.mediaRef,className:"ReactCrop__child-wrapper",onPointerDown:this.onComponentPointerDown},t),i?l.default.createElement("svg",{className:"ReactCrop__crop-mask",width:"100%",height:"100%"},l.default.createElement("defs",null,l.default.createElement("mask",{id:`hole-${this.instanceId}`},l.default.createElement("rect",{width:"100%",height:"100%",fill:"white"}),r?l.default.createElement("ellipse",{cx:`${i.x+i.width/2}${i.unit}`,cy:`${i.y+i.height/2}${i.unit}`,rx:`${i.width/2}${i.unit}`,ry:`${i.height/2}${i.unit}`,fill:"black"}):l.default.createElement("rect",{x:`${i.x}${i.unit}`,y:`${i.y}${i.unit}`,width:`${i.width}${i.unit}`,height:`${i.height}${i.unit}`,fill:"black"}))),l.default.createElement("rect",{fill:"black",fillOpacity:.5,width:"100%",height:"100%",mask:`url(#hole-${this.instanceId})`})):void 0,h)}};o(m,"xOrds",["e","w"]),o(m,"yOrds",["n","s"]),o(m,"xyOrds",["nw","ne","se","sw"]),o(m,"nudgeStep",1),o(m,"nudgeStepMedium",10),o(m,"nudgeStepLarge",100),o(m,"defaultProps",{ariaLabels:{cropArea:"Use the arrow keys to move the crop selection area",nwDragHandle:"Use the arrow keys to move the north west drag handle to change the crop selection area",nDragHandle:"Use the up and down arrow keys to move the north drag handle to change the crop selection area",neDragHandle:"Use the arrow keys to move the north east drag handle to change the crop selection area",eDragHandle:"Use the up and down arrow keys to move the east drag handle to change the crop selection area",seDragHandle:"Use the arrow keys to move the south east drag handle to change the crop selection area",sDragHandle:"Use the up and down arrow keys to move the south drag handle to change the crop selection area",swDragHandle:"Use the arrow keys to move the south west drag handle to change the crop selection area",wDragHandle:"Use the up and down arrow keys to move the west drag handle to change the crop selection area"}});var v=e.i(713341),w=e.i(372700);
1e.s(["ImageCropDialog",0,({image:e,onChange:l})=>{let[a,o]=(0,r.useState)(!1),[s,d]=(0,r.useState)();return(0,t.jsxs)(w.Dialog,{open:a,onOpenChange:o,children:[(0,t.jsx)(w.DialogTrigger,{asChild:!0,children:(0,t.jsx)("button",{type:"button",className:"py-4 px-2",title:"Crop thumbnail",children:(0,t.jsx)(n,{size:16})})}),(0,t.jsxs)(w.DialogContent,{className:"sm:max-w-[725px]",children:[(0,t.jsxs)(w.DialogHeader,{children:[(0,t.jsx)(w.DialogTitle,{children:"Crop thumbnail"}),(0,t.jsx)(w.DialogDescription,{children:"This cropped image will be used as the thumbnail and marker image for this artwork."})]}),(0,t.jsx)("div",{className:"flex items-center justify-center overflow-hidden",children:(0,t.jsx)(m,{className:"max-h-[70vh] max-w-full",aspect:1,crop:s,keepSelection:!0,onChange:(t,r)=>{d(r),l({...e,crop:r,id:(0,i.v4)()})},children:(0,t.jsx)("img",{src:e.url,alt:"Artwork image to be cropped",onLoad:t=>{var r,n;let i,l;if(e.crop)return void d(e.crop);let{naturalWidth:a,naturalHeight:o}=t.currentTarget;d((i=h(r={unit:"%",height:95},a,o),r.width&&(i.height=i.width/1),r.height&&(i.width=+i.height),i.y+i.height>o&&(i.height=o-i.y,i.width=+i.height),i.x+i.width>a&&(i.width=a-i.x,i.height=i.width/1),(l=h(n="%"===r.unit?c(i,a,o):i,a,o)).x=(a-l.width)/2,l.y=(o-l.height)/2,"%"===n.unit?c(l,a,o):l))}})})}),(0,t.jsx)(w.DialogFooter,{children:(0,t.jsx)(v.Button,{type:"button",onClick:()=>o(!1),children:"Crop thumbnail"})})]})]})}],56143)},472076,e=>{"use strict";let t;var r,n,i,l,a,o,s,d,u,c,h,f,g,p,m,v,w,y,b,x=e.i(26863),C=e.i(122525),D=e.i(396952);let E="u">typeof window&&void 0!==window.document&&void 0!==window.document.createElement;function S(e){let t=Object.prototype.toString.call(e);return"[object Window]"===t||"[object global]"===t}function k(e){return"nodeType"in e}function R(e){var t,r;return e?S(e)?e:k(e)&&null!=(t=null==(r=e.ownerDocument)?void 0:r.defaultView)?t:window:window}function M(e){let{Document:t}=R(e);return e instanceof t}function O(e){return!S(e)&&e instanceof R(e).HTMLElement}function L(e){return e instanceof R(e).SVGElement}function N(e){return e?S(e)?e.document:k(e)?M(e)?e:O(e)||L(e)?e.ownerDocument:document:document:document}let j=E?C.useLayoutEffect:C.useEffect;function A(e){let t=(0,C.useRef)(e);return j(()=>{t.current=e}),(0,C.useCallback)(function(){for(var e=arguments.length,r=Array(e),n=0;n<e;n++)r[n]=arguments[n];return null==t.current?void 0:t.current(...r)},[])}function T(e,t){void 0===t&&(t=[e]);let r=(0,C.useRef)(e);return j(()=>{r.current!==e&&(r.current=e)},t),r}function I(e,t){let r=(0,C.useRef)();return(0,C.useMemo)(()=>{let t=e(r.current);return r.current=t,t},[...t])}function P(e){let t=A(e),r=(0,C.useRef)(null),n=(0,C.useCallback)(e=>{e!==r.current&&(null==t||t(e,r.current)),r.current=e},[]);return[r,n]}function K(e){let t=(0,C.useRef)();return(0,C.useEffect)(()=>{t.current=e},[e]),t.current}let z={};function B(e,t){return(0,C.useMemo)(()=>{if(t)return t;let r=null==z[e]?0:z[e]+1;return z[e]=r,e+"-"+r},[e,t])}function Y(e){return function(t){for(var r=arguments.length,n=Array(r>1?r-1:0),i=1;i<r;i++)n[i-1]=arguments[i];return n.reduce((t,r)=>{for(let[n,i]of Object.entries(r)){let r=t[n];null!=r&&(t[n]=r+e*i)}return t},{...t})}}let H=Y(1),X=Y(-1);function _(e){if(!e)return!1;let{KeyboardEvent:t}=R(e.target);return t&&e instanceof t}function U(e){if(function(e){if(!e)return!1;let{TouchEvent:t}=R(e.target);return t&&e instanceof t}(e)){if(e.touches&&e.touches.length){let{clientX:t,clientY:r}=e.touches[0];return{x:t,y:r}}else if(e.changedTouches&&e.changedTouches.length){let{clientX:t,clientY:r}=e.changedTouches[0];return{x:t,y:r}}}return"clientX"in e&&"clientY"in e?{x:e.clientX,y:e.clientY}:null}let $=Object.freeze({Translate:{toString(e){if(!e)return;let{x:t,y:r}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(r?Math.round(r):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;let{scaleX:t,scaleY:r}=e;return"scaleX("+t+") scaleY("+r+")"}},Transform:{toString(e){if(e)return[$.Translate.toString(e),$.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:r,easing:n}=e;return t+" "+r+"ms "+n}}}),F="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]",W={display:"none"};function q(e){let{id:t,value:r}=e;return C.default.createElement("div",{id:t,style:W},r)}function V(e){let{id:t,announcement:r,ariaLiveType:n="assertive"}=e;return C.default.createElement("div",{id:t,style:{position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"},role:"status","aria-live":n,"aria-atomic":!0},r)}let J=(0,C.createContext)(null),G={draggable:"\n    To pick up a draggable item, press the space bar.\n    While dragging, use the arrow keys to move the item.\n    Press space again to drop the item in its new position, or press escape to cancel.\n  "},Q={onDragStart(e){let{active:t}=e;return"Picked up draggable item "+t.id+"."},onDragOver(e){let{active:t,over:r}=e;return r?"Draggable item "+t.id+" was moved over droppable area "+r.id+".":"Draggable item "+t.id+" is no longer over a droppable area."},onDragEnd(e){let{active:t,over:r}=e;return r?"Draggable item "+t.id+" was dropped over droppable area "+r.id:"Draggable item "+t.id+" was dropped."},onDragCancel(e){let{active:t}=e;return"Dragging was cancelled. Draggable item "+t.id+" was dropped."}};function Z(e){var t;let r,{announcements:n=Q,container:i,hiddenTextDescribedById:l,screenReaderInstructions:a=G}=e,{announce:o,announcement:s}=function(){let[e,t]=(0,C.useState)("");return{announce:(0,C.useCallback)(e=>{null!=e&&t(e)},[]),announcement:e}}(),d=B("DndLiveRegion"),[u,c]=(0,C.useState)(!1);if((0,C.useEffect)(()=>{c(!0)},[]),t=(0,C.useMemo)(()=>({onDragStart(e){let{active:t}=e;o(n.onDragStart({active:t}))},onDragMove(e){let{active:t,over:r}=e;n.onDragMove&&o(n.onDragMove({active:t,over:r}))},onDragOver(e){let{active:t,over:r}=e;o(n.onDragOver({active:t,over:r}))},onDragEnd(e){let{active:t,over:r}=e;o(n.onDragEnd({active:t,over:r}))},onDragCancel(e){let{active:t,over:r}=e;o(n.onDragCancel({active:t,over:r}))}}),[o,n]),r=(0,C.useContext)(J),(0,C.useEffect)(()=>
1{if(!r)throw Error("useDndMonitor must be used within a children of <DndContext>");return r(t)},[t,r]),!u)return null;let h=C.default.createElement(C.default.Fragment,null,C.default.createElement(q,{id:l,value:a.draggable}),C.default.createElement(V,{id:d,announcement:s}));return i?(0,D.createPortal)(h,i):h}function ee(){}function et(e,t){return(0,C.useMemo)(()=>({sensor:e,options:null!=t?t:{}}),[e,t])}(r=c||(c={})).DragStart="dragStart",r.DragMove="dragMove",r.DragEnd="dragEnd",r.DragCancel="dragCancel",r.DragOver="dragOver",r.RegisterDroppable="registerDroppable",r.SetDroppableDisabled="setDroppableDisabled",r.UnregisterDroppable="unregisterDroppable";let er=Object.freeze({x:0,y:0});function en(e,t){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function ei(e,t){let{data:{value:r}}=e,{data:{value:n}}=t;return r-n}function el(e,t){let{data:{value:r}}=e,{data:{value:n}}=t;return n-r}function ea(e){let{left:t,top:r,height:n,width:i}=e;return[{x:t,y:r},{x:t+i,y:r},{x:t,y:r+n},{x:t+i,y:r+n}]}function eo(e,t){if(!e||0===e.length)return null;let[r]=e;return t?r[t]:r}function es(e,t,r){return void 0===t&&(t=e.left),void 0===r&&(r=e.top),{x:t+.5*e.width,y:r+.5*e.height}}let ed=e=>{let{collisionRect:t,droppableRects:r,droppableContainers:n}=e,i=es(t,t.left,t.top),l=[];for(let e of n){let{id:t}=e,n=r.get(t);if(n){let r=en(es(n),i);l.push({id:t,data:{droppableContainer:e,value:r}})}}return l.sort(ei)},eu=e=>{let{collisionRect:t,droppableRects:r,droppableContainers:n}=e,i=[];for(let e of n){let{id:n}=e,l=r.get(n);if(l){let r=function(e,t){let r=Math.max(t.top,e.top),n=Math.max(t.left,e.left),i=Math.min(t.left+t.width,e.left+e.width),l=Math.min(t.top+t.height,e.top+e.height);if(n<i&&r<l){let a=t.width*t.height,o=e.width*e.height,s=(i-n)*(l-r);return Number((s/(a+o-s)).toFixed(4))}return 0}(l,t);r>0&&i.push({id:n,data:{droppableContainer:e,value:r}})}}return i.sort(el)};function ec(e,t){return e&&t?{x:e.left-t.left,y:e.top-t.top}:er}let eh=function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];return r.reduce((e,t)=>({...e,top:e.top+ +t.y,bottom:e.bottom+ +t.y,left:e.left+ +t.x,right:e.right+ +t.x}),{...e})};function ef(e){if(e.startsWith("matrix3d(")){let t=e.slice(9,-1).split(/, /);return{x:+t[12],y:+t[13],scaleX:+t[0],scaleY:+t[5]}}if(e.startsWith("matrix(")){let t=e.slice(7,-1).split(/, /);return{x:+t[4],y:+t[5],scaleX:+t[0],scaleY:+t[3]}}return null}let eg={ignoreTransform:!1};function ep(e,t){void 0===t&&(t=eg);let r=e.getBoundingClientRect();if(t.ignoreTransform){let{transform:t,transformOrigin:n}=R(e).getComputedStyle(e);t&&(r=function(e,t,r){let n=ef(t);if(!n)return e;let{scaleX:i,scaleY:l,x:a,y:o}=n,s=e.left-a-(1-i)*parseFloat(r),d=e.top-o-(1-l)*parseFloat(r.slice(r.indexOf(" ")+1)),u=i?e.width/i:e.width,c=l?e.height/l:e.height;return{width:u,height:c,top:d,right:s+u,bottom:d+c,left:s}}(r,t,n))}let{top:n,left:i,width:l,height:a,bottom:o,right:s}=r;return{top:n,left:i,width:l,height:a,bottom:o,right:s}}function em(e){return ep(e,{ignoreTransform:!0})}function ev(e,t){let r=[];return e?function n(i){var l,a;let o;if(null!=t&&r.length>=t||!i)return r;if(M(i)&&null!=i.scrollingElement&&!r.includes(i.scrollingElement))return r.push(i.scrollingElement),r;if(!O(i)||L(i)||r.includes(i))return r;let s=R(e).getComputedStyle(i);return(i!==e&&(void 0===(l=s)&&(l=R(i).getComputedStyle(i)),o=/(auto|scroll|overlay)/,["overflow","overflowX","overflowY"].some(e=>{let t=l[e];return"string"==typeof t&&o.test(t)}))&&r.push(i),void 0===(a=s)&&(a=R(i).getComputedStyle(i)),"fixed"===a.position)?r:n(i.parentNode)}(e):r}function ew(e){let[t]=ev(e,1);return null!=t?t:null}function ey(e){return E&&e?S(e)?e:k(e)?M(e)||e===N(e).scrollingElement?window:O(e)?e:null:null:null}function eb(e){return S(e)?e.scrollX:e.scrollLeft}function ex(e){return S(e)?e.scrollY:e.scrollTop}function eC(e){return{x:eb(e),y:ex(e)}}function eD(e){return!!E&&!!e&&e===document.scrollingElement}function eE(e){let t={x:0,y:0},r=eD(e)?{height:window.innerHeight,width:window.innerWidth}:{height:e.clientHeight,width:e.clientWidth},n={x:e.scrollWidth-r.width,y:e.scrollHeight-r.height},i=e.scrollTop<=t.y,l=e.scrollLeft<=t.x;return{isTop:i,isLeft:l,isBottom:e.scrollTop>=n.y,isRight:e.scrollLeft>=n.x,maxScroll:n,minScroll:t}}(n=h||(h={}))[n.Forward=1]="Forward",n[n.Backward=-1]="Backward";let eS={x:.2,y:.2};function ek(e){return e.reduce((e,t)=>
1H(e,eC(t)),er)}function eR(e,t){if(void 0===t&&(t=ep),!e)return;let{top:r,left:n,bottom:i,right:l}=t(e);ew(e)&&(i<=0||l<=0||r>=window.innerHeight||n>=window.innerWidth)&&e.scrollIntoView({block:"center",inline:"center"})}let eM=[["x",["left","right"],function(e){return e.reduce((e,t)=>e+eb(t),0)}],["y",["top","bottom"],function(e){return e.reduce((e,t)=>e+ex(t),0)}]];class eO{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 r=ev(t),n=ek(r);for(const[t,i,l]of(this.rect={...e},this.width=e.width,this.height=e.height,eM))for(const e of i)Object.defineProperty(this,e,{get:()=>{let i=l(r),a=n[t]-i;return this.rect[e]+a},enumerable:!0});Object.defineProperty(this,"rect",{enumerable:!1})}}class eL{constructor(e){this.target=void 0,this.listeners=[],this.removeAll=()=>{this.listeners.forEach(e=>{var t;return null==(t=this.target)?void 0:t.removeEventListener(...e)})},this.target=e}add(e,t,r){var n;null==(n=this.target)||n.addEventListener(e,t,r),this.listeners.push([e,t,r])}}function eN(e,t){let r=Math.abs(e.x),n=Math.abs(e.y);return"number"==typeof t?Math.sqrt(r**2+n**2)>t:"x"in t&&"y"in t?r>t.x&&n>t.y:"x"in t?r>t.x:"y"in t&&n>t.y}function ej(e){e.preventDefault()}function eA(e){e.stopPropagation()}(i=f||(f={})).Click="click",i.DragStart="dragstart",i.Keydown="keydown",i.ContextMenu="contextmenu",i.Resize="resize",i.SelectionChange="selectionchange",i.VisibilityChange="visibilitychange",(l=g||(g={})).Space="Space",l.Down="ArrowDown",l.Right="ArrowRight",l.Left="ArrowLeft",l.Up="ArrowUp",l.Esc="Escape",l.Enter="Enter",l.Tab="Tab";let eT={start:[g.Space,g.Enter],cancel:[g.Esc],end:[g.Space,g.Enter,g.Tab]},eI=(e,t)=>{let{currentCoordinates:r}=t;switch(e.code){case g.Right:return{...r,x:r.x+25};case g.Left:return{...r,x:r.x-25};case g.Down:return{...r,y:r.y+25};case g.Up:return{...r,y:r.y-25}}};class eP{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 eL(N(t)),this.windowListeners=new eL(R(t)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(f.Resize,this.handleCancel),this.windowListeners.add(f.VisibilityChange,this.handleCancel),setTimeout(()=>this.listeners.add(f.Keydown,this.handleKeyDown))}handleStart(){let{activeNode:e,onStart:t}=this.props,r=e.node.current;r&&eR(r),t(er)}handleKeyDown(e){if(_(e)){let{active:t,context:r,options:n}=this.props,{keyboardCodes:i=eT,coordinateGetter:l=eI,scrollBehavior:a="smooth"}=n,{code:o}=e;if(i.end.includes(o))return void this.handleEnd(e);if(i.cancel.includes(o))return void this.handleCancel(e);let{collisionRect:s}=r.current,d=s?{x:s.left,y:s.top}:er;this.referenceCoordinates||(this.referenceCoordinates=d);let u=l(e,{active:t,context:r.current,currentCoordinates:d});if(u){let t=X(u,d),n={x:0,y:0},{scrollableAncestors:i}=r.current;for(let r of i){let i=e.code,{isTop:l,isRight:o,isLeft:s,isBottom:d,maxScroll:c,minScroll:h}=eE(r),f=function(e){if(e===document.scrollingElement){let{innerWidth:e,innerHeight:t}=window;return{top:0,left:0,right:e,bottom:t,width:e,height:t}}let{top:t,left:r,right:n,bottom:i}=e.getBoundingClientRect();return{top:t,left:r,right:n,bottom:i,width:e.clientWidth,height:e.clientHeight}}(r),p={x:Math.min(i===g.Right?f.right-f.width/2:f.right,Math.max(i===g.Right?f.left:f.left+f.width/2,u.x)),y:Math.min(i===g.Down?f.bottom-f.height/2:f.bottom,Math.max(i===g.Down?f.top:f.top+f.height/2,u.y))},m=i===g.Right&&!o||i===g.Left&&!s,v=i===g.Down&&!d||i===g.Up&&!l;if(m&&p.x!==u.x){let e=r.scrollLeft+t.x,l=i===g.Right&&e<=c.x||i===g.Left&&e>=h.x;if(l&&!t.y)return void r.scrollTo({left:e,behavior:a});l?n.x=r.scrollLeft-e:n.x=i===g.Right?r.scrollLeft-c.x:r.scrollLeft-h.x,n.x&&r.scrollBy({left:-n.x,behavior:a});break}if(v&&p.y!==u.y){let e=r.scrollTop+t.y,l=i===g.Down&&e<=c.y||i===g.Up&&e>=h.y;if(l&&!t.x)return void r.scrollTo({top:e,behavior:a});l?n.y=r.scrollTop-e:n.y=i===g.Down?r.scrollTop-c.y:r.scrollTop-h.y,n.y&&r.scrollBy({top:-n.y,behavior:a});break}}this.handleMove(e,H(X(u,this.referenceCoordinates),n))}}}handleMove(e,t){let{onMove:r}=this.props;e.preventDefault(),r(t)}handleEnd(e){let{onEnd:t}=this.props;e.preventDefault(),this.detach(),t()}handleCancel(e){let{onCancel:t}=this.props;e.preventDefault(),this.detach(),t()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll()}}function eK(e){return!!(e&&"distance"in e)}function ez(e){return!!(e&&"delay"in e)}eP.activators=[{eventName:"onKeyDown",handler:(e,t,r)=>{let{keyboardCodes:n=eT,onActivation:i}=t,{active:l}=r,{code:a}=e.nativeEvent;if(n.start.includes(a)){let t=l.activatorNode.current;return(!t||e.target===t)&&(e.preventDefault(),null==i||i({event:e.nativeEvent}),!0)}return!1}}];class eB{constructor(e,t,r){var n;void 0===r&&(r=function(e){let{EventTarget:t}=R(e);return e instanceof t?e:N(e)}(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:l}=i;this.props=e,this.events=t,this.document=N(l),this.documentListeners=new eL(this.document),this.listeners=new eL(r),this.windowListeners=new eL(R(l)),this.initialCoordinates=null!=(n=U(i))?n:er,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(){let{events:e,props:{options:{activationConstraint:t,bypassActivationConstraint:r}}}=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(f.Resize,this.handleCancel),this.windowListeners.add(f.DragStart,ej),this.windowListeners.add(f.VisibilityChange,this.handleCancel),this.windowListeners.add(f.ContextMenu,ej),this.documentListeners.add(f.Keydown,this.handleKeydown),t){if(null!=r&&r({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if(ez(t)){this.timeoutId=setTimeout(this.handleStart,t.delay),this.handlePending(t);return}if(eK(t))return void this.handlePending(t)}
1this.handleStart()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll(),setTimeout(this.documentListeners.removeAll,50),null!==this.timeoutId&&(clearTimeout(this.timeoutId),this.timeoutId=null)}handlePending(e,t){let{active:r,onPending:n}=this.props;n(r,e,this.initialCoordinates,t)}handleStart(){let{initialCoordinates:e}=this,{onStart:t}=this.props;e&&(this.activated=!0,this.documentListeners.add(f.Click,eA,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(f.SelectionChange,this.removeTextSelection),t(e))}handleMove(e){var t;let{activated:r,initialCoordinates:n,props:i}=this,{onMove:l,options:{activationConstraint:a}}=i;if(!n)return;let o=null!=(t=U(e))?t:er,s=X(n,o);if(!r&&a){if(eK(a)){if(null!=a.tolerance&&eN(s,a.tolerance))return this.handleCancel();if(eN(s,a.distance))return this.handleStart()}return ez(a)&&eN(s,a.tolerance)?this.handleCancel():void this.handlePending(a,s)}e.cancelable&&e.preventDefault(),l(o)}handleEnd(){let{onAbort:e,onEnd:t}=this.props;this.detach(),this.activated||e(this.props.active),t()}handleCancel(){let{onAbort:e,onCancel:t}=this.props;this.detach(),this.activated||e(this.props.active),t()}handleKeydown(e){e.code===g.Esc&&this.handleCancel()}removeTextSelection(){var e;null==(e=this.document.getSelection())||e.removeAllRanges()}}let eY={cancel:{name:"pointercancel"},move:{name:"pointermove"},end:{name:"pointerup"}};class eH extends eB{constructor(e){const{event:t}=e;super(e,eY,N(t.target))}}eH.activators=[{eventName:"onPointerDown",handler:(e,t)=>{let{nativeEvent:r}=e,{onActivation:n}=t;return!!r.isPrimary&&0===r.button&&(null==n||n({event:r}),!0)}}];(a=p||(p={}))[a.RightClick=2]="RightClick";let eX={cancel:{name:"touchcancel"},move:{name:"touchmove"},end:{name:"touchend"}};class e_ extends eB{constructor(e){super(e,eX)}static setup(){return window.addEventListener(eX.move.name,e,{capture:!1,passive:!1}),function(){window.removeEventListener(eX.move.name,e)};function e(){}}}e_.activators=[{eventName:"onTouchStart",handler:(e,t)=>{let{nativeEvent:r}=e,{onActivation:n}=t,{touches:i}=r;return!(i.length>1)&&(null==n||n({event:r}),!0)}}],(o=m||(m={}))[o.Pointer=0]="Pointer",o[o.DraggableRect=1]="DraggableRect",(s=v||(v={}))[s.TreeOrder=0]="TreeOrder",s[s.ReversedTreeOrder=1]="ReversedTreeOrder";let eU={x:{[h.Backward]:!1,[h.Forward]:!1},y:{[h.Backward]:!1,[h.Forward]:!1}};(d=w||(w={}))[d.Always=0]="Always",d[d.BeforeDragging=1]="BeforeDragging",d[d.WhileDragging=2]="WhileDragging",(y||(y={})).Optimized="optimized";let e$=new Map;function eF(e,t){return I(r=>e?r||("function"==typeof t?t(e):e):null,[t,e])}function eW(e){let{callback:t,disabled:r}=e,n=A(t),i=(0,C.useMemo)(()=>{if(r||"u"<typeof window||void 0===window.ResizeObserver)return;let{ResizeObserver:e}=window;return new e(n)},[r]);return(0,C.useEffect)(()=>()=>null==i?void 0:i.disconnect(),[i]),i}function eq(e){return new eO(ep(e),e)}function eV(e,t,r){void 0===t&&(t=eq);let[n,i]=(0,C.useState)(null);function l(){i(n=>{if(!e)return null;if(!1===e.isConnected){var i;return null!=(i=null!=n?n:r)?i:null}let l=t(e);return JSON.stringify(n)===JSON.stringify(l)?n:l})}let a=function(e){let{callback:t,disabled:r}=e,n=A(t),i=(0,C.useMemo)(()=>{if(r||"u"<typeof window||void 0===window.MutationObserver)return;let{MutationObserver:e}=window;return new e(n)},[n,r]);return(0,C.useEffect)(()=>()=>null==i?void 0:i.disconnect(),[i]),i}({callback(t){if(e)for(let r of t){let{type:t,target:n}=r;if("childList"===t&&n instanceof HTMLElement&&n.contains(e)){l();break}}}}),o=eW({callback:l});return j(()=>{l(),e?(null==o||o.observe(e),null==a||a.observe(document.body,{childList:!0,subtree:!0})):(null==o||o.disconnect(),null==a||a.disconnect())},[e]),n}let eJ=[];function eG(e,t){void 0===t&&(t=[]);let r=(0,C.useRef)(null);return(0,C.useEffect)(()=>{r.current=null},t),(0,C.useEffect)(()=>{let t=e!==er;t&&!r.current&&(r.current=e),!t&&r.current&&(r.current=null)},[e]),r.current?X(e,r.current):er}function eQ(e){return(0,C.useMemo)(()=>{let t,r;return e?(t=e.innerWidth,{top:0,left:0,right:t,bottom:r=e.innerHeight,width:t,height:r}):null},[e])}let eZ=[];function e0(e){if(!e)return null;if(e.children.length>1)return e;let t=e.children[0];return O(t)?t:e}let e1=[{sensor:eH,options:{}},{sensor:eP,options:{}}],e2={current:{}},e5={draggable:{measure:em},droppable:{measure:em,strategy:w.WhileDragging,frequency:y.Optimized},dragOverlay:{measure:ep}};class e3 extends Map{get(e){var t;return null!=e&&null!=(t=super.get(e))?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,r;
1return null!=(t=null==(r=this.get(e))?void 0:r.node.current)?t:void 0}}let e7={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new e3,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:ee},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:e5,measureDroppableContainers:ee,windowRect:null,measuringScheduled:!1},e4={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:""},dispatch:ee,draggableNodes:new Map,over:null,measureDroppableContainers:ee},e6=(0,C.createContext)(e4),e9=(0,C.createContext)(e7);function e8(){return{draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new e3}}}function te(e,t){switch(t.type){case c.DragStart:return{...e,draggable:{...e.draggable,initialCoordinates:t.initialCoordinates,active:t.active}};case c.DragMove:if(null==e.draggable.active)return e;return{...e,draggable:{...e.draggable,translate:{x:t.coordinates.x-e.draggable.initialCoordinates.x,y:t.coordinates.y-e.draggable.initialCoordinates.y}}};case c.DragEnd:case c.DragCancel:return{...e,draggable:{...e.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case c.RegisterDroppable:{let{element:r}=t,{id:n}=r,i=new e3(e.droppable.containers);return i.set(n,r),{...e,droppable:{...e.droppable,containers:i}}}case c.SetDroppableDisabled:{let{id:r,key:n,disabled:i}=t,l=e.droppable.containers.get(r);if(!l||n!==l.key)return e;let a=new e3(e.droppable.containers);return a.set(r,{...l,disabled:i}),{...e,droppable:{...e.droppable,containers:a}}}case c.UnregisterDroppable:{let{id:r,key:n}=t,i=e.droppable.containers.get(r);if(!i||n!==i.key)return e;let l=new e3(e.droppable.containers);return l.delete(r),{...e,droppable:{...e.droppable,containers:l}}}default:return e}}function tt(e){let{disabled:t}=e,{active:r,activatorEvent:n,draggableNodes:i}=(0,C.useContext)(e6),l=K(n),a=K(null==r?void 0:r.id);return(0,C.useEffect)(()=>{if(!t&&!n&&l&&null!=a){if(!_(l)||document.activeElement===l.target)return;let e=i.get(a);if(!e)return;let{activatorNode:t,node:r}=e;(t.current||r.current)&&requestAnimationFrame(()=>{for(let e of[t.current,r.current]){if(!e)continue;let t=e.matches(F)?e:e.querySelector(F);if(t){t.focus();break}}})}},[n,t,i,a,l]),null}function tr(e,t){let{transform:r,...n}=t;return null!=e&&e.length?e.reduce((e,t)=>t({transform:e,...n}),r):r}let tn=(0,C.createContext)({...er,scaleX:1,scaleY:1});(u=b||(b={}))[u.Uninitialized=0]="Uninitialized",u[u.Initializing=1]="Initializing",u[u.Initialized=2]="Initialized";let ti=(0,C.memo)(function(e){var t,r,n,i,l,a,o,s;let d,u,f,g,p,y,x,S,{id:k,accessibility:M,autoScroll:L=!0,children:N,sensors:A=e1,collisionDetection:z=eu,measuring:Y,modifiers:X,..._}=e,[$,F]=(0,C.useReducer)(te,void 0,e8),[W,q]=function(){let[e]=(0,C.useState)(()=>new Set),t=(0,C.useCallback)(t=>(e.add(t),()=>e.delete(t)),[e]);return[(0,C.useCallback)(t=>{let{type:r,event:n}=t;e.forEach(e=>{var t;return null==(t=e[r])?void 0:t.call(e,n)})},[e]),t]}(),[V,G]=(0,C.useState)(b.Uninitialized),Q=V===b.Initialized,{draggable:{active:ee,nodes:et,translate:en},droppable:{containers:ei}}=$,el=null!=ee?et.get(ee):null,ea=(0,C.useRef)({initial:null,translated:null}),es=(0,C.useMemo)(()=>{var e;return null!=ee?{id:ee,data:null!=(e=null==el?void 0:el.data)?e:e2,rect:ea}:null},[ee,el]),ed=(0,C.useRef)(null),[ef,eg]=(0,C.useState)(null),[em,eb]=(0,C.useState)(null),ex=T(_,Object.values(_)),eR=B("DndDescribedBy",k),eM=(0,C.useMemo)(()=>ei.getEnabled(),[ei]),eL=(0,C.useMemo)(()=>({draggable:{...e5.draggable,...null==Y?void 0:Y.draggable},droppable:{...e5.droppable,...null==Y?void 0:Y.droppable},dragOverlay:{...e5.dragOverlay,...null==Y?void 0:Y.dragOverlay}}),[null==Y?void 0:Y.draggable,null==Y?void 0:Y.droppable,null==Y?void 0:Y.dragOverlay]),{droppableRects:eN,measureDroppableContainers:ej,measuringScheduled:eA}=function(e,t){let{dragging:r,dependencies:n,config:i}=t,[l,a]=(0,C.useState)(null),{frequency:o,measure:s,strategy:d}=i,u=(0,C.useRef)(e),c=function(){switch(d){case w.Always:return!1;case w.BeforeDragging:return r;default:return!r}}(),h=T(c),f=(0,C.useCallback)(function(e){void 0===e&&(e=[]),h.current||a(t=>null===t?e:t.concat(e.filter(e=>!t.includes(e))))},[h]),g=(0,C.useRef)(null),p=I(t=>{if(c&&!r)return e$;if(!t||t===e$||u.current!==e||null!=l){let t=new Map;for(let r of e){if(!r)continue;if(l&&l.length>0&&!l.includes(r.id)&&r.rect.current){t.set(r.id,r.rect.current);continue}let e=r.node.current,n=e?new eO(s(e),e):null;r.rect.current=n,n&&t.set(r.id,n)}return t}return t},[e,l,r,c,s]);return(0,C.useEffect)(()=>{u.current=e},[e]),(0,C.useEffect)(()=>{c||f()},[r,c]),(0,C.useEffect)(()=>{l&&l.length>0&&a(null)},[JSON.stringify(l)]),(0,C.useEffect)(()=>{c||"number"!=typeof o||null!==g.current||(g.current=setTimeout(()=>{f(),g.current=null},o))},[o,c,f,...n]),{droppableRects:p,measureDroppableContainers:f,measuringScheduled:null!=l}}(eM,{dragging:Q,dependencies:[en.x,en.y],config:eL.droppable}),eT=I(e=>{var t;return null==ee?null:null!=(t=null!=p?p:e)?t:null},[p=(g=null!=ee?et.get(ee):void 0)?g.node.current:null,ee]),eI=(0,C.useMemo)(()=>em?U(em):null,[em]),eP=(d=(null==ef?void 0:ef.autoScrollEnabled)===!1,u="object"==typeof L?!1===L.enabled:!1===L,f=Q&&!d&&!u,"object"==typeof L?{...L,enabled:f}:{enabled:f}),eK=eF(eT,eL.draggable.measure);!function(e){let{activeNode:t,measure:r,initialRect:n,config:i=!0}=e,l=(0,C.useRef)(!1),{x:a,y:o}="boolean"==typeof i?{x:i,y:i}:i;j(()=>
1{if(!a&&!o||!t){l.current=!1;return}if(l.current||!n)return;let e=null==t?void 0:t.node.current;if(!e||!1===e.isConnected)return;let i=ec(r(e),n);if(a||(i.x=0),o||(i.y=0),l.current=!0,Math.abs(i.x)>0||Math.abs(i.y)>0){let t=ew(e);t&&t.scrollBy({top:i.y,left:i.x})}},[t,a,o,n,r])}({activeNode:null!=ee?et.get(ee):null,config:eP.layoutShiftCompensation,initialRect:eK,measure:eL.draggable.measure});let ez=eV(eT,eL.draggable.measure,eK),eB=eV(eT?eT.parentElement:null),eY=(0,C.useRef)({activatorEvent:null,active:null,activeNode:eT,collisionRect:null,collisions:null,droppableRects:eN,draggableNodes:et,draggingNode:null,draggingNodeRect:null,droppableContainers:ei,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),eH=ei.getNodeFor(null==(t=eY.current.over)?void 0:t.id),eX=function(e){let{measure:t}=e,[r,n]=(0,C.useState)(null),i=eW({callback:(0,C.useCallback)(e=>{for(let{target:r}of e)if(O(r)){n(e=>{let n=t(r);return e?{...e,width:n.width,height:n.height}:n});break}},[t])}),[l,a]=P((0,C.useCallback)(e=>{let r=e0(e);null==i||i.disconnect(),r&&(null==i||i.observe(r)),n(r?t(r):null)},[t,i]));return(0,C.useMemo)(()=>({nodeRef:l,rect:r,setRef:a}),[r,l,a])}({measure:eL.dragOverlay.measure}),e_=null!=(r=eX.nodeRef.current)?r:eT,eq=Q?null!=(n=eX.rect)?n:ez:null,e3=!!(eX.nodeRef.current&&eX.rect),e7=(y=eF(l=e3?null:ez),ec(l,y)),e4=eQ(e_?R(e_):null),ti=(a=Q?null!=eH?eH:eT:null,x=(0,C.useRef)(a),S=I(e=>a?e&&e!==eJ&&a&&x.current&&a.parentNode===x.current.parentNode?e:ev(a):eJ,[a]),(0,C.useEffect)(()=>{x.current=a},[a]),S),tl=function(e,t){void 0===t&&(t=ep);let[r]=e,n=eQ(r?R(r):null),[i,l]=(0,C.useState)(eZ);function a(){l(()=>e.length?e.map(e=>eD(e)?n:new eO(t(e),e)):eZ)}let o=eW({callback:a});return j(()=>{null==o||o.disconnect(),a(),e.forEach(e=>null==o?void 0:o.observe(e))},[e]),i}(ti),ta=tr(X,{transform:{x:en.x-e7.x,y:en.y-e7.y,scaleX:1,scaleY:1},activatorEvent:em,active:es,activeNodeRect:ez,containerNodeRect:eB,draggingNodeRect:eq,over:eY.current.over,overlayNodeRect:eX.rect,scrollableAncestors:ti,scrollableAncestorRects:tl,windowRect:e4}),to=eI?H(eI,en):null,ts=function(e){let[t,r]=(0,C.useState)(null),n=(0,C.useRef)(e),i=(0,C.useCallback)(e=>{let t=ey(e.target);t&&r(e=>e?(e.set(t,eC(t)),new Map(e)):null)},[]);return(0,C.useEffect)(()=>{let t=n.current;if(e!==t){l(t);let a=e.map(e=>{let t=ey(e);return t?(t.addEventListener("scroll",i,{passive:!0}),[t,eC(t)]):null}).filter(e=>null!=e);r(a.length?new Map(a):null),n.current=e}return()=>{l(e),l(t)};function l(e){e.forEach(e=>{let t=ey(e);null==t||t.removeEventListener("scroll",i)})}},[i,e]),(0,C.useMemo)(()=>e.length?t?Array.from(t.values()).reduce((e,t)=>H(e,t),er):ek(e):er,[e,t])}(ti),td=eG(ts),tu=eG(ts,[ez]),tc=H(ta,td),th=eq?eh(eq,ta):null,tf=es&&th?z({active:es,collisionRect:th,droppableRects:eN,droppableContainers:eM,pointerCoordinates:to}):null,tg=eo(tf,"id"),[tp,tm]=(0,C.useState)(null),tv=(o=e3?ta:H(ta,tu),s=null!=(i=null==tp?void 0:tp.rect)?i:null,{...o,scaleX:s&&ez?s.width/ez.width:1,scaleY:s&&ez?s.height/ez.height:1}),tw=(0,C.useRef)(null),ty=(0,C.useCallback)((e,t)=>{let{sensor:r,options:n}=t;if(null==ed.current)return;let i=et.get(ed.current);if(!i)return;let l=e.nativeEvent,a=new r({active:ed.current,activeNode:i,event:l,options:n,context:eY,onAbort(e){if(!et.get(e))return;let{onDragAbort:t}=ex.current,r={id:e};null==t||t(r),W({type:"onDragAbort",event:r})},onPending(e,t,r,n){if(!et.get(e))return;let{onDragPending:i}=ex.current,l={id:e,constraint:t,initialCoordinates:r,offset:n};null==i||i(l),W({type:"onDragPending",event:l})},onStart(e){let t=ed.current;if(null==t)return;let r=et.get(t);if(!r)return;let{onDragStart:n}=ex.current,i={activatorEvent:l,active:{id:t,data:r.data,rect:ea}};(0,D.unstable_batchedUpdates)(()=>{null==n||n(i),G(b.Initializing),F({type:c.DragStart,initialCoordinates:e,active:t}),W({type:"onDragStart",event:i}),eg(tw.current),eb(l)})},onMove(e){F({type:c.DragMove,coordinates:e})},onEnd:o(c.DragEnd),onCancel:o(c.DragCancel)});function o(e){return async function(){let{active:t,collisions:r,over:n,scrollAdjustedTranslate:i}=eY.current,a=null;if(t&&i){let{cancelDrop:o}=ex.current;a={activatorEvent:l,active:t,collisions:r,delta:i,over:n}
1,e===c.DragEnd&&"function"==typeof o&&await Promise.resolve(o(a))&&(e=c.DragCancel)}ed.current=null,(0,D.unstable_batchedUpdates)(()=>{F({type:e}),G(b.Uninitialized),tm(null),eg(null),eb(null),tw.current=null;let t=e===c.DragEnd?"onDragEnd":"onDragCancel";if(a){let e=ex.current[t];null==e||e(a),W({type:t,event:a})}})}}tw.current=a},[et]),tb=(0,C.useCallback)((e,t)=>(r,n)=>{let i=r.nativeEvent,l=et.get(n);null!==ed.current||!l||i.dndKit||i.defaultPrevented||!0===e(r,t.options,{active:l})&&(i.dndKit={capturedBy:t.sensor},ed.current=n,ty(r,t))},[et,ty]),tx=(0,C.useMemo)(()=>A.reduce((e,t)=>{let{sensor:r}=t;return[...e,...r.activators.map(e=>({eventName:e.eventName,handler:tb(e.handler,t)}))]},[]),[A,tb]);(0,C.useEffect)(()=>{if(!E)return;let e=A.map(e=>{let{sensor:t}=e;return null==t.setup?void 0:t.setup()});return()=>{for(let t of e)null==t||t()}},A.map(e=>{let{sensor:t}=e;return t})),j(()=>{ez&&V===b.Initializing&&G(b.Initialized)},[ez,V]),(0,C.useEffect)(()=>{let{onDragMove:e}=ex.current,{active:t,activatorEvent:r,collisions:n,over:i}=eY.current;if(!t||!r)return;let l={active:t,activatorEvent:r,collisions:n,delta:{x:tc.x,y:tc.y},over:i};(0,D.unstable_batchedUpdates)(()=>{null==e||e(l),W({type:"onDragMove",event:l})})},[tc.x,tc.y]),(0,C.useEffect)(()=>{let{active:e,activatorEvent:t,collisions:r,droppableContainers:n,scrollAdjustedTranslate:i}=eY.current;if(!e||null==ed.current||!t||!i)return;let{onDragOver:l}=ex.current,a=n.get(tg),o=a&&a.rect.current?{id:a.id,rect:a.rect.current,data:a.data,disabled:a.disabled}:null,s={active:e,activatorEvent:t,collisions:r,delta:{x:i.x,y:i.y},over:o};(0,D.unstable_batchedUpdates)(()=>{tm(o),null==l||l(s),W({type:"onDragOver",event:s})})},[tg]),j(()=>{eY.current={activatorEvent:em,active:es,activeNode:eT,collisionRect:th,collisions:tf,droppableRects:eN,draggableNodes:et,draggingNode:e_,draggingNodeRect:eq,droppableContainers:ei,over:tp,scrollableAncestors:ti,scrollAdjustedTranslate:tc},ea.current={initial:eq,translated:th}},[es,eT,tf,th,et,e_,eq,eN,ei,tp,ti,tc]),function(e){let t,{acceleration:r,activator:n=m.Pointer,canScroll:i,draggingRect:l,enabled:a,interval:o=5,order:s=v.TreeOrder,pointerCoordinates:d,scrollableAncestors:u,scrollableAncestorRects:c,delta:f,threshold:g}=e,p=function(e){let{delta:t,disabled:r}=e,n=K(t);return I(e=>{if(r||!n||!e)return eU;let i={x:Math.sign(t.x-n.x),y:Math.sign(t.y-n.y)};return{x:{[h.Backward]:e.x[h.Backward]||-1===i.x,[h.Forward]:e.x[h.Forward]||1===i.x},y:{[h.Backward]:e.y[h.Backward]||-1===i.y,[h.Forward]:e.y[h.Forward]||1===i.y}}},[r,t,n])}({delta:f,disabled:!a}),[w,y]=(t=(0,C.useRef)(null),[(0,C.useCallback)((e,r)=>{t.current=setInterval(e,r)},[]),(0,C.useCallback)(()=>{null!==t.current&&(clearInterval(t.current),t.current=null)},[])]),b=(0,C.useRef)({x:0,y:0}),x=(0,C.useRef)({x:0,y:0}),D=(0,C.useMemo)(()=>{switch(n){case m.Pointer:return d?{top:d.y,bottom:d.y,left:d.x,right:d.x}:null;case m.DraggableRect:return l}},[n,l,d]),E=(0,C.useRef)(null),S=(0,C.useCallback)(()=>{let e=E.current;if(!e)return;let t=b.current.x*x.current.x,r=b.current.y*x.current.y;e.scrollBy(t,r)},[]),k=(0,C.useMemo)(()=>s===v.TreeOrder?[...u].reverse():u,[s,u]);(0,C.useEffect)(()=>{if(!a||!u.length||!D)return void y();for(let e of k){if((null==i?void 0:i(e))===!1)continue;let t=c[u.indexOf(e)];if(!t)continue;let{direction:n,speed:l}=function(e,t,r,n,i){let{top:l,left:a,right:o,bottom:s}=r;void 0===n&&(n=10),void 0===i&&(i=eS);let{isTop:d,isBottom:u,isLeft:c,isRight:f}=eE(e),g={x:0,y:0},p={x:0,y:0},m={height:t.height*i.y,width:t.width*i.x};return!d&&l<=t.top+m.height?(g.y=h.Backward,p.y=n*Math.abs((t.top+m.height-l)/m.height)):!u&&s>=t.bottom-m.height&&(g.y=h.Forward,p.y=n*Math.abs((t.bottom-m.height-s)/m.height)),!f&&o>=t.right-m.width?(g.x=h.Forward,p.x=n*Math.abs((t.right-m.width-o)/m.width)):!c&&a<=t.left+m.width&&(g.x=h.Backward,p.x=n*Math.abs((t.left+m.width-a)/m.width)),{direction:g,speed:p}}(e,t,D,r,g);for(let e of["x","y"])p[e][n[e]]||(l[e]=0,n[e]=0);if(l.x>0||l.y>0){y(),E.current=e,w(S,o),b.current=l,x.current=n;return}}b.current={x:0,y:0},x.current={x:0,y:0},y()},[r,S,i,y,a,o,JSON.stringify(D),JSON.stringify(p),w,u,k,c,JSON.stringify(g)])}({...eP,delta:en,draggingRect:th,pointerCoordinates:to,scrollableAncestors:ti,scrollableAncestorRects:tl});let tC=(0,C.useMemo)(()=>({active:es,activeNode:eT,activeNodeRect:ez,activatorEvent:em,collisions:tf,containerNodeRect:eB,dragOverlay:eX,draggableNodes:et,droppableContainers:ei,droppableRects:eN,over:tp,measureDroppableContainers:ej,scrollableAncestors:ti,scrollableAncestorRects:tl,measuringConfiguration:eL,measuringScheduled:eA,windowRect:e4}),[es,eT,ez,em,tf,eB,eX,et,ei,eN,tp,ej,ti,tl,eL,eA,e4]),tD=(0,C.useMemo)(()=>({activatorEvent:em,activators:tx,active:es,activeNodeRect:ez,ariaDescribedById:{draggable:eR},dispatch:F,draggableNodes:et,over:tp,measureDroppableContainers:ej}),[em,tx,es,ez,F,eR,et,tp,ej]);return C.default.createElement(J.Provider,{value:q},C.default.createElement(e6.Provider,{value:tD},C.default.createElement(e9.Provider,{value:tC},C.default.createElement(tn.Provider,{value:tv}
1,N)),C.default.createElement(tt,{disabled:(null==M?void 0:M.restoreFocus)===!1})),C.default.createElement(Z,{...M,hiddenTextDescribedById:eR}))}),tl=(0,C.createContext)(null),ta="button";function to(){return(0,C.useContext)(e9)}let ts={timeout:25};function td(e){let{animation:t,children:r}=e,[n,i]=(0,C.useState)(null),[l,a]=(0,C.useState)(null),o=K(r);return r||n||!o||i(o),j(()=>{if(!l)return;let e=null==n?void 0:n.key,r=null==n?void 0:n.props.id;null==e||null==r?i(null):Promise.resolve(t(r,l)).then(()=>{i(null)})},[t,n,l]),C.default.createElement(C.default.Fragment,null,r,n?(0,C.cloneElement)(n,{ref:a}):null)}let tu={x:0,y:0,scaleX:1,scaleY:1};function tc(e){let{children:t}=e;return C.default.createElement(e6.Provider,{value:e4},C.default.createElement(tn.Provider,{value:tu},t))}let th={position:"fixed",touchAction:"none"},tf=e=>_(e)?"transform 250ms ease":void 0,tg=(0,C.forwardRef)((e,t)=>{let{as:r,activatorEvent:n,adjustScale:i,children:l,className:a,rect:o,style:s,transform:d,transition:u=tf}=e;if(!o)return null;let c=i?d:{...d,scaleX:1,scaleY:1},h={...th,width:o.width,height:o.height,top:o.top,left:o.left,transform:$.Transform.toString(c),transformOrigin:i&&n?function(e,t){let r=U(e);if(!r)return"0 0";let n={x:(r.x-t.left)/t.width*100,y:(r.y-t.top)/t.height*100};return n.x+"% "+n.y+"%"}(n,o):void 0,transition:"function"==typeof u?u(n):u,...s};return C.default.createElement(r,{className:a,style:h,ref:t},l)}),tp={duration:250,easing:"ease",keyframes:e=>{let{transform:{initial:t,final:r}}=e;return[{transform:$.Transform.toString(t)},{transform:$.Transform.toString(r)}]},sideEffects:(t={styles:{active:{opacity:"0"}}},e=>{let{active:r,dragOverlay:n}=e,i={},{styles:l,className:a}=t;if(null!=l&&l.active)for(let[e,t]of Object.entries(l.active))void 0!==t&&(i[e]=r.node.style.getPropertyValue(e),r.node.style.setProperty(e,t));if(null!=l&&l.dragOverlay)for(let[e,t]of Object.entries(l.dragOverlay))void 0!==t&&n.node.style.setProperty(e,t);return null!=a&&a.active&&r.node.classList.add(a.active),null!=a&&a.dragOverlay&&n.node.classList.add(a.dragOverlay),function(){for(let[e,t]of Object.entries(i))r.node.style.setProperty(e,t);null!=a&&a.active&&r.node.classList.remove(a.active)}})},tm=0,tv=C.default.memo(e=>{var t;let{adjustScale:r=!1,children:n,dropAnimation:i,style:l,transition:a,modifiers:o,wrapperElement:s="div",className:d,zIndex:u=999}=e,{activatorEvent:c,active:h,activeNodeRect:f,containerNodeRect:g,draggableNodes:p,droppableContainers:m,dragOverlay:v,over:w,measuringConfiguration:y,scrollableAncestors:b,scrollableAncestorRects:x,windowRect:D}=to(),E=(0,C.useContext)(tn),S=(t=null==h?void 0:h.id,(0,C.useMemo)(()=>{if(null!=t)return++tm},[t])),k=tr(o,{activatorEvent:c,active:h,activeNodeRect:f,containerNodeRect:g,draggingNodeRect:v.rect,over:w,overlayNodeRect:v.rect,scrollableAncestors:b,scrollableAncestorRects:x,transform:E,windowRect:D}),M=eF(f),O=function(e){let{config:t,draggableNodes:r,droppableContainers:n,measuringConfiguration:i}=e;return A((e,l)=>{if(null===t)return;let a=r.get(e);if(!a)return;let o=a.node.current;if(!o)return;let s=e0(l);if(!s)return;let{transform:d}=R(l).getComputedStyle(l),u=ef(d);if(!u)return;let c="function"==typeof t?t:function(e){let{duration:t,easing:r,sideEffects:n,keyframes:i}={...tp,...e};return e=>{let{active:l,dragOverlay:a,transform:o,...s}=e;if(!t)return;let d={x:a.rect.left-l.rect.left,y:a.rect.top-l.rect.top},u={scaleX:1!==o.scaleX?l.rect.width*o.scaleX/a.rect.width:1,scaleY:1!==o.scaleY?l.rect.height*o.scaleY/a.rect.height:1},c={x:o.x-d.x,y:o.y-d.y,...u},h=i({...s,active:l,dragOverlay:a,transform:{initial:o,final:c}}),[f]=h,g=h[h.length-1];if(JSON.stringify(f)===JSON.stringify(g))return;let p=null==n?void 0:n({active:l,dragOverlay:a,...s}),m=a.node.animate(h,{duration:t,easing:r,fill:"forwards"});return new Promise(e=>{m.onfinish=()=>{null==p||p(),e()}})}}(t);return eR(o,i.draggable.measure),c({active:{id:e,data:a.data,node:o,rect:i.draggable.measure(o)},draggableNodes:r,dragOverlay:{node:l,rect:i.dragOverlay.measure(s)},droppableContainers:n,measuringConfiguration:i,transform:u})})}({config:i,draggableNodes:p,droppableContainers:m,measuringConfiguration:y}),L=M?v.setRef:void 0;return C.default.createElement(tc,null,C.default.createElement(td,{animation:O},h&&S?C.default.createElement(tg,{key:S,id:h.id,ref:L,as:s,activatorEvent:c,adjustScale:r,className:d,transition:a,rect:M,style:{zIndex:u,...l},transform:k},n):null))});function tw(e,t,r){let n=e.slice();return n.splice(r<0?n.length+r:r,0,n.splice(t,1)[0]),n}function ty(e){return null!==e&&e>=0}let tb=e=>{let{rects:t,activeIndex:r,overIndex:n,index:i}=e,l=tw(t,n,r),a=t[i],o=l[i];return o&&a?{x:o.left-a.left,y:o.top-a.top,scaleX:o.width/a.width,scaleY:o.height/a.height}:null}
1,tx="Sortable",tC=C.default.createContext({activeIndex:-1,containerId:tx,disableTransforms:!1,items:[],overIndex:-1,useDragOverlay:!1,sortedRects:[],strategy:tb,disabled:{draggable:!1,droppable:!1}});function tD(e){let{children:t,id:r,items:n,strategy:i=tb,disabled:l=!1}=e,{active:a,dragOverlay:o,droppableRects:s,over:d,measureDroppableContainers:u}=to(),c=B(tx,r),h=null!==o.rect,f=(0,C.useMemo)(()=>n.map(e=>"object"==typeof e&&"id"in e?e.id:e),[n]),g=null!=a,p=a?f.indexOf(a.id):-1,m=d?f.indexOf(d.id):-1,v=(0,C.useRef)(f),w=!function(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}(f,v.current),y=-1!==m&&-1===p||w,b="boolean"==typeof l?{draggable:l,droppable:l}:l;j(()=>{w&&g&&u(f)},[w,f,g,u]),(0,C.useEffect)(()=>{v.current=f},[f]);let x=(0,C.useMemo)(()=>({activeIndex:p,containerId:c,disabled:b,disableTransforms:y,items:f,overIndex:m,useDragOverlay:h,sortedRects:f.reduce((e,t,r)=>{let n=s.get(t);return n&&(e[r]=n),e},Array(f.length)),strategy:i}),[p,c,b.draggable,b.droppable,y,f,m,s,h,i]);return C.default.createElement(tC.Provider,{value:x},t)}let tE=e=>{let{id:t,items:r,activeIndex:n,overIndex:i}=e;return tw(r,n,i).indexOf(t)},tS=e=>{let{containerId:t,isSorting:r,wasDragging:n,index:i,items:l,newIndex:a,previousItems:o,previousContainerId:s,transition:d}=e;return!!d&&!!n&&(o===l||i!==a)&&(!!r||a!==i&&t===s)},tk={duration:200,easing:"ease"},tR="transform",tM=$.Transition.toString({property:tR,duration:0,easing:"linear"}),tO={roleDescription:"sortable"};function tL(e){if(!e)return!1;let t=e.data.current;return!!t&&"sortable"in t&&"object"==typeof t.sortable&&"containerId"in t.sortable&&"items"in t.sortable&&"index"in t.sortable}let tN=[g.Down,g.Right,g.Up,g.Left],tj=(e,t)=>{let{context:{active:r,collisionRect:n,droppableRects:i,droppableContainers:l,over:a,scrollableAncestors:o}}=t;if(tN.includes(e.code)){if(e.preventDefault(),!r||!n)return;let t=[];l.getEnabled().forEach(r=>{if(!r||null!=r&&r.disabled)return;let l=i.get(r.id);if(l)switch(e.code){case g.Down:n.top<l.top&&t.push(r);break;case g.Up:n.top>l.top&&t.push(r);break;case g.Left:n.left>l.left&&t.push(r);break;case g.Right:n.left<l.left&&t.push(r)}});let u=(e=>{let{collisionRect:t,droppableRects:r,droppableContainers:n}=e,i=ea(t),l=[];for(let e of n){let{id:t}=e,n=r.get(t);if(n){let r=ea(n),a=Number((i.reduce((e,t,n)=>e+en(r[n],t),0)/4).toFixed(4));l.push({id:t,data:{droppableContainer:e,value:a}})}}return l.sort(ei)})({active:r,collisionRect:n,droppableRects:i,droppableContainers:t,pointerCoordinates:null}),c=eo(u,"id");if(c===(null==a?void 0:a.id)&&u.length>1&&(c=u[1].id),null!=c){let e=l.get(r.id),t=l.get(c),a=t?i.get(t.id):null,u=null==t?void 0:t.node.current;if(u&&a&&e&&t){var s,d;let r=ev(u).some((e,t)=>o[t]!==e),i=tA(e,t),l=(s=e,d=t,!!tL(s)&&!!tL(d)&&!!tA(s,d)&&s.data.current.sortable.index<d.data.current.sortable.index),c=r||!i?{x:0,y:0}:{x:l?n.width-a.width:0,y:l?n.height-a.height:0},h={x:a.left,y:a.top};return c.x&&c.y?h:X(h,c)}}}};function tA(e,t){return!!tL(e)&&!!tL(t)&&e.data.current.sortable.containerId===t.data.current.sortable.containerId}let tT=(0,C.createContext)(!1),tI=(0,C.createContext)({attributes:{},listeners:{}});e.s(["SortableContainer",0,e=>t=>{let[r,n]=(0,C.useState)(null),i=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return(0,C.useMemo)(()=>[...t].filter(e=>null!=e),[...t])}(et(eH),et(e_,{activationConstraint:{distance:3}}),et(eP,{coordinateGetter:tj}));return(0,x.jsx)(tT.Provider,{value:!!t.renderDragOverlay,children:(0,x.jsxs)(ti,{sensors:i,collisionDetection:ed,onDragStart:({active:e})=>n(Number(e.id)),onDragEnd:({active:e,over:r})=>{n(null),r&&e.id!==r.id&&t.onSortEnd({oldIndex:Number(e.id),newIndex:Number(r.id)})},onDragCancel:()=>n(null),children:[(0,x.jsx)(tD,{items:Object.keys(t.items),strategy:tb,children:(0,x.jsx)(e,{...t})}),(0,x.jsx)(tv,{dropAnimation:null,children:null!==r&&t.renderDragOverlay&&(0,x.jsx)("div",{className:"cursor-grabbing shadow-2xl rounded-md",children:t.renderDragOverlay(r)})})]})})},"SortableElement",0,e=>t=>{let r=(0,C.useContext)(tT),{attributes:n,listeners:i,setNodeRef:l,transform:a,transition:o,isDragging:s}=function(e){var t,r,n,i;let{animateLayoutChanges:l=tS,attributes:a,disabled:o,data:s,getNewIndex:d=tE,id:u,strategy:h,resizeObserverConfig:f,transition:g=tk}=e,{items:p,containerId:m,activeIndex:v,disabled:w,disableTransforms:y,sortedRects:b,overIndex:x,useDragOverlay:D,strategy:E}=(0,C.useContext)(tC),S=(t=o,r=w,"boolean"==typeof t?{draggable:t,droppable:!1}:{draggable:null!=(n=null==t?void 0:t.draggable)?n:r.draggable,droppable:null!=(i=null==t?void 0:t.droppable)?i:r.droppable}),k=p.indexOf(u),R=(0,C.useMemo)(()=>({sortable:{containerId:m,index:k,items:p},...s}),[m,s,k,p]),M=(0,C.useMemo)(()=>p.slice(p.indexOf(u)),[p,u]),{rect:O,node:L,isOver:N,setNodeRef:A}=function(e){let{data:t,disabled:r=!1,id:n,resizeObserverConfig:i}=e,l=B("Droppable"),{active:a,dispatch:o,over:s,measureDroppableContainers:d}=(0,C.useContext)(e6),u=(0,C.useRef)({disabled:r}),h=(0,C.useRef)(!1),f=(0,C.useRef)(null),g=(0,C.useRef)(null),{disabled:p,updateMeasurementsFor:m,timeout:v}={...ts,...i},w=T(null!=m?m:n),y=eW({callback:(0,C.useCallback)(()=>
1{if(!h.current){h.current=!0;return}null!=g.current&&clearTimeout(g.current),g.current=setTimeout(()=>{d(Array.isArray(w.current)?w.current:[w.current]),g.current=null},v)},[v]),disabled:p||!a}),[b,x]=P((0,C.useCallback)((e,t)=>{y&&(t&&(y.unobserve(t),h.current=!1),e&&y.observe(e))},[y])),D=T(t);return(0,C.useEffect)(()=>{y&&b.current&&(y.disconnect(),h.current=!1,y.observe(b.current))},[b,y]),(0,C.useEffect)(()=>(o({type:c.RegisterDroppable,element:{id:n,key:l,disabled:r,node:b,rect:f,data:D}}),()=>o({type:c.UnregisterDroppable,key:l,id:n})),[n]),(0,C.useEffect)(()=>{r!==u.current.disabled&&(o({type:c.SetDroppableDisabled,id:n,key:l,disabled:r}),u.current.disabled=r)},[n,l,r,o]),{active:a,rect:f,isOver:(null==s?void 0:s.id)===n,node:b,over:s,setNodeRef:x}}({id:u,data:R,disabled:S.droppable,resizeObserverConfig:{updateMeasurementsFor:M,...f}}),{active:I,activatorEvent:K,activeNodeRect:z,attributes:Y,setNodeRef:H,listeners:X,isDragging:U,over:F,setActivatorNodeRef:W,transform:q}=function(e){let{id:t,data:r,disabled:n=!1,attributes:i}=e,l=B("Draggable"),{activators:a,activatorEvent:o,active:s,activeNodeRect:d,ariaDescribedById:u,draggableNodes:c,over:h}=(0,C.useContext)(e6),{role:f=ta,roleDescription:g="draggable",tabIndex:p=0}=null!=i?i:{},m=(null==s?void 0:s.id)===t,v=(0,C.useContext)(m?tn:tl),[w,y]=P(),[b,x]=P(),D=(0,C.useMemo)(()=>a.reduce((e,r)=>{let{eventName:n,handler:i}=r;return e[n]=e=>{i(e,t)},e},{}),[a,t]),E=T(r);return j(()=>(c.set(t,{id:t,key:l,node:w,activatorNode:b,data:E}),()=>{let e=c.get(t);e&&e.key===l&&c.delete(t)}),[c,t]),{active:s,activatorEvent:o,activeNodeRect:d,attributes:(0,C.useMemo)(()=>({role:f,tabIndex:p,"aria-disabled":n,"aria-pressed":!!m&&f===ta||void 0,"aria-roledescription":g,"aria-describedby":u.draggable}),[n,f,p,m,g,u.draggable]),isDragging:m,listeners:n?void 0:D,node:w,over:h,setNodeRef:y,setActivatorNodeRef:x,transform:v}}({id:u,data:R,attributes:{...tO,...a},disabled:S.draggable}),V=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return(0,C.useMemo)(()=>e=>{t.forEach(t=>t(e))},t)}(A,H),J=!!I,G=J&&!y&&ty(v)&&ty(x),Q=!D&&U,Z=Q&&G?q:null,ee=G?null!=Z?Z:(null!=h?h:E)({rects:b,activeNodeRect:z,activeIndex:v,overIndex:x,index:k}):null,et=ty(v)&&ty(x)?d({id:u,items:p,activeIndex:v,overIndex:x}):k,er=null==I?void 0:I.id,en=(0,C.useRef)({activeId:er,items:p,newIndex:et,containerId:m}),ei=p!==en.current.items,el=l({active:I,containerId:m,isDragging:U,isSorting:J,id:u,index:k,items:p,newIndex:en.current.newIndex,previousItems:en.current.items,previousContainerId:en.current.containerId,transition:g,wasDragging:null!=en.current.activeId}),ea=function(e){let{disabled:t,index:r,node:n,rect:i}=e,[l,a]=(0,C.useState)(null),o=(0,C.useRef)(r);return j(()=>{if(!t&&r!==o.current&&n.current){let e=i.current;if(e){let t=ep(n.current,{ignoreTransform:!0}),r={x:e.left-t.left,y:e.top-t.top,scaleX:e.width/t.width,scaleY:e.height/t.height};(r.x||r.y)&&a(r)}}r!==o.current&&(o.current=r)},[t,r,n,i]),(0,C.useEffect)(()=>{l&&a(null)},[l]),l}({disabled:!el,index:k,node:L,rect:O});return(0,C.useEffect)(()=>{J&&en.current.newIndex!==et&&(en.current.newIndex=et),m!==en.current.containerId&&(en.current.containerId=m),p!==en.current.items&&(en.current.items=p)},[J,et,m,p]),(0,C.useEffect)(()=>{if(er===en.current.activeId)return;if(null!=er&&null==en.current.activeId){en.current.activeId=er;return}let e=setTimeout(()=>{en.current.activeId=er},50);return()=>clearTimeout(e)},[er]),{active:I,activeIndex:v,attributes:Y,data:R,rect:O,index:k,newIndex:et,items:p,isOver:N,isSorting:J,isDragging:U,listeners:X,node:L,overIndex:x,over:F,setNodeRef:V,setActivatorNodeRef:W,setDroppableNodeRef:A,setDraggableNodeRef:H,transform:null!=ea?ea:ee,transition:ea||ei&&en.current.newIndex===k?tM:(!Q||_(K))&&g&&(J||el)?$.Transition.toString({...g,property:tR}):void 0}}({id:(t.id??t.index).toString(),animateLayoutChanges:()=>!1}),d={transform:$.Transform.toString(a),transition:o,opacity:s&&r?.3:void 0};return(0,x.jsx)("div",{ref:l,style:d,children:(0,x.jsx)(tI.Provider,{value:{attributes:n,listeners:i},children:(0,x.jsx)(e,{...t})})})},"SortableHandle",0,e=>t=>{let{attributes:r,listeners:n}=(0,C.useContext)(tI);return(0,x.jsx)("div",{className:"touch-none",...r,...n,children:(0,x.jsx)(e,{...t})})}],472076)},238174,e=>{"use strict";var t=e.i(26863),r=e.i(116019),n=e.i(475254);let i=(0,n.default)("scan-search",[["path",{d:"M3 7V5a2 2 0 0 1 2-2h2",key:"aa7l1z"}],["path",{d:"M17 3h2a2 2 0 0 1 2 2v2",key:"4qcy5o"}],["path",{d:"M21 17v2a2 2 0 0 1-2 2h-2",key:"6vwrx8"}],["path",{d:"M7 21H5a2 2 0 0 1-2-2v-2",key:"ioqczr"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}],["path",{d:"m16 16-1.9-1.9",key:"1dq9hf"}]]),l=(0,n.default)("grip-horizontal",[["circle",{cx:"12",cy:"9",r:"1",key:"124mty"}],["circle",{cx:"19",cy:"9",r:"1",key:"1ruzo2"}],["circle",{cx:"5",cy:"9",r:"1",key:"1a8b28"}],["circle",{cx:"12",cy:"15",r:"1",key:"1e56xg"}],["circle",{cx:"19",cy:"15",r:"1",key:"1a92ep"}],["circle",{cx:"5",cy:"15",r:"1",key:"5r1jwy"}]]);var a=e.i(56143),o=e.i(472076),s=e.i(73084);let d=(0,o.SortableHandle)(()=>
1(0,t.jsx)("div",{className:"m-2.5 px-1.5 py-1 cursor-move rounded-md bg-zinc-300/30 hover:bg-zinc-300/50 transition",title:"Drag to reorder",children:(0,t.jsx)(l,{size:16})}));e.s(["ImageTile",0,({image:e,showAttribution:n,canCrop:l,onChange:o,onRemove:u,onViewFullscreen:c})=>(0,t.jsxs)("div",{className:"border border-zinc-300 dark:border-zinc-700 active:shadow rounded-lg bg-white dark:bg-zinc-900",children:[(0,t.jsx)("div",{className:(0,s.cn)("aspect-[4/3] min-h-12 bg-zinc-200 bg-center bg-cover rounded-t-lg overflow-hidden flex flex-col justify-start -m-px",!n&&"rounded-b-md",n&&"border-b border-zinc-200"),style:{backgroundImage:`url(${e.url})`},children:(0,t.jsxs)("div",{className:"bg-gradient-to-b pb-6 from-black text-white w-full flex items-center justify-between",children:[(0,t.jsxs)("div",{className:"flex items-center px-1.5",children:[l&&o&&(0,t.jsx)(a.ImageCropDialog,{image:e,onChange:o}),(0,t.jsx)("button",{type:"button",className:"py-4 px-2",title:"View fullscreen",onClick:c,children:(0,t.jsx)(i,{size:16})}),(0,t.jsx)("button",{type:"button",className:"p-4 pl-2",title:"Remove",onClick:u,children:(0,t.jsx)(r.Trash,{size:16})})]}),(0,t.jsx)(d,{})]})}),n&&(0,t.jsx)("input",{type:"text",value:e.attribution||"",onChange:t=>o?.({...e,attribution:t.target.value}),onBlur:t=>o?.({...e,attribution:t.target.value.trim()}),placeholder:"Photographer name...",className:"p-2 px-3 bg-transparent rounded-b-lg border-0 text-xs focus:ring-0 flex-1 w-full mr-1"})]})],238174)},176119,e=>{"use strict";var t=e.i(26863),r=e.i(122525),n=e.i(706871),i=e.i(995328),l=e.i(238174),a=e.i(472076);let o=(0,a.SortableElement)(l.ImageTile),s=(0,a.SortableContainer)(({arrayHelpers:e,items:r,setFullscreenImage:i,showAttribution:l,mediaUploadUrl:a,mediaDomain:s})=>(0,t.jsxs)("div",{className:"grid grid-cols-1 @md:grid-cols-2 @lg:grid-cols-3 gap-2 items-start p-2 border border-zinc-300 dark:border-zinc-700 dark:bg-zinc-900 rounded-md",children:[(0,t.jsx)("div",{className:"@md:col-span-2 @lg:col-span-3",children:(0,t.jsx)(n.default,{mediaUploadUrl:a,mediaDomain:s,onUpload:t=>e.push(t),className:"h-24 max-w-full bg-zinc-100 dark:bg-transparent rounded-sm",outerClassName:""})}),r.map((r,n)=>(0,t.jsx)(o,{index:n,image:r,showAttribution:l,canCrop:0===n,onChange:t=>e.replace(n,t),onRemove:()=>e.remove(n),onViewFullscreen:()=>i(n)},n))]})),d=[];e.s(["default",0,({value:e=d,onChange:n,showAttribution:a=!0,mediaUploadUrl:o,mediaDomain:u})=>{let[c,h]=(0,r.useState)(null),f=(0,r.useRef)(e),g=(0,r.useRef)(e);f.current!==e&&(f.current=e,g.current=e);let p=e=>{g.current=e,n(e)},m={push:e=>p([...g.current,e]),replace:(e,t)=>p(g.current.map((r,n)=>n===e?t:r)),remove:e=>p(g.current.filter((t,r)=>r!==e)),move:(e,t)=>{let r=[...g.current],[n]=r.splice(e,1);r.splice(t,0,n),p(r)}};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(i.default,{src:c,onClose:()=>h(null)},"preview"),(0,t.jsx)(s,{arrayHelpers:m,items:e,showAttribution:a,mediaUploadUrl:o,mediaDomain:u,setFullscreenImage:t=>h([t,e.map(e=>e.url||"")]),renderDragOverlay:r=>(0,t.jsx)(l.ImageTile,{image:e[r],showAttribution:a,canCrop:0===r}),onSortEnd:({oldIndex:e,newIndex:t})=>m.move(e,t)})]})}])}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.