decap-cms-widget-file 3.3.0 → 3.5.0

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/CHANGELOG.md CHANGED
@@ -3,6 +3,16 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.5.0](https://github.com/decaporg/decap-cms/compare/decap-cms-widget-file@3.4.0...decap-cms-widget-file@3.5.0) (2026-07-23)
7
+
8
+ **Note:** Version bump only for package decap-cms-widget-file
9
+
10
+ # [3.4.0](https://github.com/decaporg/decap-cms/compare/decap-cms-widget-file@3.3.0...decap-cms-widget-file@3.4.0) (2026-06-08)
11
+
12
+ ### Bug Fixes
13
+
14
+ - remove unused dependencies and specify missing dependencies ([#7833](https://github.com/decaporg/decap-cms/issues/7833)) ([e324a14](https://github.com/decaporg/decap-cms/commit/e324a142f7f0ba63c760b2e8524d971c35200f87))
15
+
6
16
  # [3.3.0](https://github.com/decaporg/decap-cms/compare/decap-cms-widget-file@3.2.0...decap-cms-widget-file@3.3.0) (2026-06-01)
7
17
 
8
18
  **Note:** Version bump only for package decap-cms-widget-file
@@ -1,8 +1,8 @@
1
1
  /*! For license information please see decap-cms-widget-file.js.LICENSE.txt */
2
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("@emotion/react"),require("react"),require("prop-types"),require("react-immutable-proptypes"),require("immutable"),require("uuid"),require("decap-cms-ui-default")):"function"==typeof define&&define.amd?define("DecapCmsWidgetFile",["@emotion/react","react","prop-types","react-immutable-proptypes","immutable","uuid","decap-cms-ui-default"],t):"object"==typeof exports?exports.DecapCmsWidgetFile=t(require("@emotion/react"),require("react"),require("prop-types"),require("react-immutable-proptypes"),require("immutable"),require("uuid"),require("decap-cms-ui-default")):e.DecapCmsWidgetFile=t(e.DecapCmsDefaultExports.EmotionCore,e.React,e.DecapCmsDefaultExports.PropTypes,e.DecapCmsDefaultExports.ImmutablePropTypes,e.DecapCmsDefaultExports.Immutable,e.DecapCmsDefaultExports.UUId,e.DecapCmsUiDefault)}(window,(e,t,n,r,o,i,a)=>(()=>{var s={650(e,t,n){var r=n(942).Symbol;e.exports=r},379(e,t,n){var r=n(650),o=n(870),i=n(5),a=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":a&&a in Object(e)?o(e):i(e)}},403(e,t,n){var r=n(945),o=/^\s+/;e.exports=function(e){return e?e.slice(0,r(e)+1).replace(o,""):e}},967(e,t,n){var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;e.exports=r},870(e,t,n){var r=n(650),o=Object.prototype,i=o.hasOwnProperty,a=o.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=i.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var o=a.call(e);return r&&(t?e[s]=n:delete e[s]),o}},5(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},942(e,t,n){var r=n(967),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();e.exports=i},945(e){var t=/\s/;e.exports=function(e){for(var n=e.length;n--&&t.test(e.charAt(n)););return n}},80(e,t,n){var r=n(642);e.exports=function(e,t){var n;if("function"!=typeof t)throw new TypeError("Expected a function");return e=r(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=void 0),n}}},580(e){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},547(e){e.exports=function(e){return null!=e&&"object"==typeof e}},187(e,t,n){var r=n(379),o=n(547);e.exports=function(e){return"symbol"==typeof e||o(e)&&"[object Symbol]"==r(e)}},354(e,t,n){var r=n(80);e.exports=function(e){return r(2,e)}},301(e,t,n){var r=n(131),o=1/0;e.exports=function(e){return e?(e=r(e))===o||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}},642(e,t,n){var r=n(301);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},131(e,t,n){var r=n(403),o=n(580),i=n(187),a=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,l=/^0o[0-7]+$/i,c=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(i(e))return NaN;if(o(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=r(e);var n=s.test(e);return n||l.test(e)?c(e.slice(2),n?2:8):a.test(e)?NaN:+e}},310(e,t,n){"use strict";var r=n(119);function o(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var i=Symbol.for("react.portal");r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;t.createPortal=function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!t||1!==t.nodeType&&9!==t.nodeType&&11!==t.nodeType)throw Error(o(299));return function(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:i,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}(e,t,null,n)},t.unstable_batchedUpdates=function(e,t){return e(t)}},144(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(310)},119(e){"use strict";e.exports=t},110(t){"use strict";t.exports=e},522(e){"use strict";e.exports=o},630(e){"use strict";e.exports=r},434(e){"use strict";e.exports=n},97(e){"use strict";e.exports=i},171(e){"use strict";e.exports=a}},l={};function c(e){var t=l[e];if(void 0!==t)return t.exports;var n=l[e]={exports:{}};return s[e](n,n.exports,c),n.exports}c.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return c.d(t,{a:t}),t},c.d=(e,t)=>{for(var n in t)c.o(t,n)&&!c.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var u={};return(()=>{"use strict";function e(){return e=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},e.apply(null,arguments)}c.d(u,{DecapCmsWidgetFile:()=>Xn});var t=c(110),n={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function r(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}var o=/[A-Z]|^ms/g,i=/_EMO_([^_]+?)_([^]*?)_EMO_/g,a=function(e){return 45===e.charCodeAt(1)},s=function(e){return null!=e&&"boolean"!=typeof e},l=r(function(e){return a(e)?e:e.replace(o,"-$&").toLowerCase()}),d=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(i,function(e,t,n){return p={name:t,styles:n,next:p},t})}return 1===n[e]||a(e)||"number"!=typeof t||0===t?t:t+"px"};function f(e,t,n){if(null==n)return"";var r=n;if(void 0!==r.__emotion_styles)return r;switch(typeof n){case"boolean":return"";case"object":var o=n;if(1===o.anim)return p={name:o.name,styles:o.styles,next:p},o.name;var i=n;if(void 0!==i.styles){var a=i.next;if(void 0!==a)for(;void 0!==a;)p={name:a.name,styles:a.styles,next:p},a=a.next;return i.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=f(e,t,n[o])+";";else for(var i in n){var a=n[i];if("object"!=typeof a){var c=a;null!=t&&void 0!==t[c]?r+=i+"{"+t[c]+"}":s(c)&&(r+=l(i)+":"+d(i,c)+";")}else if(!Array.isArray(a)||"string"!=typeof a[0]||null!=t&&void 0!==t[a[0]]){var u=f(e,t,a);switch(i){case"animation":case"animationName":r+=l(i)+":"+u+";";break;default:r+=i+"{"+u+"}"}}else for(var p=0;p<a.length;p++)s(a[p])&&(r+=l(i)+":"+d(i,a[p])+";")}return r}(e,t,n);case"function":if(void 0!==e){var c=p,u=n(e);return p=c,f(e,t,u)}}var g=n;if(null==t)return g;var h=t[g];return void 0!==h?h:g}var p,g=/label:\s*([^\s;{]+)\s*(;|$)/g,h=c(119),v=c.n(h),m=!!h.useInsertionEffect&&h.useInsertionEffect,b=m||function(e){return e()};m||h.useLayoutEffect;var y,x,w=function(e,t,n){var r=e.key+"-"+t.name;!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles)},C=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,R=r(function(e){return C.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91}),D=function(e){return"theme"!==e},E=function(e){return"string"==typeof e&&e.charCodeAt(0)>96?R:D},S=function(e,t,n){var r;if(t){var o=t.shouldForwardProp;r=e.__emotion_forwardProp&&o?function(t){return e.__emotion_forwardProp(t)&&o(t)}:o}return"function"!=typeof r&&n&&(r=e.__emotion_forwardProp),r},k=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return w(t,n,r),b(function(){return function(e,t,n){w(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var o=t;do{e.insert(t===o?"."+r:"",o,e.sheet,!0),o=o.next}while(void 0!==o)}}(t,n,r)}),null},A=function n(r,o){var i,a,s=r.__emotion_real===r,l=s&&r.__emotion_base||r;void 0!==o&&(i=o.label,a=o.target);var c=S(r,o,s),u=c||E(l),d=!u("as");return function(){var v=arguments,m=s&&void 0!==r.__emotion_styles?r.__emotion_styles.slice(0):[];if(void 0!==i&&m.push("label:"+i+";"),null==v[0]||void 0===v[0].raw)m.push.apply(m,v);else{var b=v[0];m.push(b[0]);for(var y=v.length,x=1;x<y;x++)m.push(v[x],b[x])}var w=(0,t.withEmotionCache)(function(e,n,r){var o,i,s,v,b=d&&e.as||l,y="",x=[],w=e;if(null==e.theme){for(var C in w={},e)w[C]=e[C];w.theme=h.useContext(t.ThemeContext)}"string"==typeof e.className?(o=n.registered,i=x,s=e.className,v="",s.split(" ").forEach(function(e){void 0!==o[e]?i.push(o[e]+";"):e&&(v+=e+" ")}),y=v):null!=e.className&&(y=e.className+" ");var R=function(e,t,n){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,o="";p=void 0;var i=e[0];null==i||void 0===i.raw?(r=!1,o+=f(n,t,i)):o+=i[0];for(var a=1;a<e.length;a++)o+=f(n,t,e[a]),r&&(o+=i[a]);g.lastIndex=0;for(var s,l="";null!==(s=g.exec(o));)l+="-"+s[1];var c=function(e){for(var t,n=0,r=0,o=e.length;o>=4;++r,o-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(o){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)}(o)+l;return{name:c,styles:o,next:p}}(m.concat(x),n.registered,w);y+=n.key+"-"+R.name,void 0!==a&&(y+=" "+a);var D=d&&void 0===c?E(b):u,S={};for(var A in e)d&&"as"===A||D(A)&&(S[A]=e[A]);return S.className=y,r&&(S.ref=r),h.createElement(h.Fragment,null,h.createElement(k,{cache:n,serialized:R,isStringTag:"string"==typeof b}),h.createElement(b,S))});return w.displayName=void 0!==i?i:"Styled("+("string"==typeof l?l:l.displayName||l.name||"Component")+")",w.defaultProps=r.defaultProps,w.__emotion_real=w,w.__emotion_base=l,w.__emotion_styles=m,w.__emotion_forwardProp=c,Object.defineProperty(w,"toString",{value:function(){return"."+a}}),w.withComponent=function(t,r){return n(t,e({},o,r,{shouldForwardProp:S(w,r,!0)})).apply(void 0,m)},w}},O=c(434),M=c.n(O),I=c(630),T=c.n(I),j=c(522),N=c(354),L=c.n(N),_=c(97),P=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),F=(y=["",""],x=["",""],Object.freeze(Object.defineProperties(y,{raw:{value:Object.freeze(x)}}))),q=function(){function e(){for(var t=this,n=arguments.length,r=Array(n),o=0;o<n;o++)r[o]=arguments[o];return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.tag=function(e){for(var n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return"function"==typeof e?t.interimTag.bind(t,e):"string"==typeof e?t.transformEndResult(e):(e=e.map(t.transformString.bind(t)),t.transformEndResult(e.reduce(t.processSubstitutions.bind(t,r))))},r.length>0&&Array.isArray(r[0])&&(r=r[0]),this.transformers=r.map(function(e){return"function"==typeof e?e():e}),this.tag}return P(e,[{key:"interimTag",value:function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return this.tag(F,e.apply(void 0,[t].concat(r)))}},{key:"processSubstitutions",value:function(e,t,n){var r=this.transformSubstitution(e.shift(),t);return"".concat(t,r,n)}},{key:"transformString",value:function(e){return this.transformers.reduce(function(e,t){return t.onString?t.onString(e):e},e)}},{key:"transformSubstitution",value:function(e,t){return this.transformers.reduce(function(e,n){return n.onSubstitution?n.onSubstitution(e,t):e},e)}},{key:"transformEndResult",value:function(e){return this.transformers.reduce(function(e,t){return t.onEndResult?t.onEndResult(e):e},e)}}]),e}();const B=q;var U={separator:"",conjunction:"",serial:!1};const z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:U;return{onSubstitution:function(t,n){if(Array.isArray(t)){var r=t.length,o=e.separator,i=e.conjunction,a=e.serial,s=n.match(/(\n?[^\S\n]+)$/);if(t=s?t.join(o+s[1]):t.join(o+" "),i&&r>1){var l=t.lastIndexOf(o);t=t.slice(0,l)+(a?o:"")+" "+i+t.slice(l+1)}}return t}}},W=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"initial";return{onEndResult:function(t){if("initial"===e){var n=t.match(/^[^\S\n]*(?=\S)/gm),r=n&&Math.min.apply(Math,function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(n.map(function(e){return e.length})));if(r){var o=new RegExp("^.{"+r+"}","gm");return t.replace(o,"")}return t}if("all"===e)return t.replace(/^[^\S\n]+/gm,"");throw new Error("Unknown type: "+e)}}},H=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return{onEndResult:function(t){if(""===e)return t.trim();if("start"===(e=e.toLowerCase())||"left"===e)return t.replace(/^\s*/,"");if("end"===e||"right"===e)return t.replace(/\s*$/,"");throw new Error("Side not supported: "+e)}}};new B(z({separator:","}),W,H),new B(z({separator:",",conjunction:"and"}),W,H),new B(z({separator:",",conjunction:"or"}),W,H);const X=function(e){return{onSubstitution:function(t,n){if(null==e||"string"!=typeof e)throw new Error("You need to specify a string character to split by.");return"string"==typeof t&&t.includes(e)&&(t=t.split(e)),t}}};var Y=function(e){return null!=e&&!Number.isNaN(e)&&"boolean"!=typeof e};new B(X("\n"),function(){return{onSubstitution:function(e){return Array.isArray(e)?e.filter(Y):Y(e)?e:""}}},z,W,H);const $=function(e,t){return{onSubstitution:function(n,r){if(null==e||null==t)throw new Error("replaceSubstitutionTransformer requires at least 2 arguments.");return null==n?n:n.toString().replace(e,t)}}};new B(X("\n"),z,W,H,$(/&/g,"&amp;"),$(/</g,"&lt;"),$(/>/g,"&gt;"),$(/"/g,"&quot;"),$(/'/g,"&#x27;"),$(/`/g,"&#x60;"));const K=function(e,t){return{onEndResult:function(n){if(null==e||null==t)throw new Error("replaceResultTransformer requires at least 2 arguments.");return n.replace(e,t)}}},V=new B(K(/(?:\n(?:\s*))+/g," "),H);new B(K(/(?:\n\s*)/g,""),H),new B(z({separator:","}),K(/(?:\s+)/g," "),H),new B(z({separator:",",conjunction:"or"}),K(/(?:\s+)/g," "),H),new B(z({separator:",",conjunction:"and"}),K(/(?:\s+)/g," "),H),new B(z,W,H),new B(z,K(/(?:\s+)/g," "),H),new B(W,H),new B(W("all"),H);var G=c(171);function J(e,t=""){if(""===e)return e;const n=(o=e,e=o.replace(/[\\/]+/g,"/")).split("/"),r=n[n.length-1];var o;return""===r&&n.length>1?n[n.length-2]:t.length>0&&r.slice(-t.length)===t?r.slice(0,-t.length):r}var Z=c(144);const Q="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement;function ee(e){const t=Object.prototype.toString.call(e);return"[object Window]"===t||"[object global]"===t}function te(e){return"nodeType"in e}function ne(e){var t,n;return e?ee(e)?e:te(e)&&null!=(t=null==(n=e.ownerDocument)?void 0:n.defaultView)?t:window:window}function re(e){const{Document:t}=ne(e);return e instanceof t}function oe(e){return!ee(e)&&e instanceof ne(e).HTMLElement}function ie(e){return e instanceof ne(e).SVGElement}function ae(e){return e?ee(e)?e.document:te(e)?re(e)?e:oe(e)||ie(e)?e.ownerDocument:document:document:document}const se=Q?h.useLayoutEffect:h.useEffect;function le(e){const t=(0,h.useRef)(e);return se(()=>{t.current=e}),(0,h.useCallback)(function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return null==t.current?void 0:t.current(...n)},[])}function ce(e,t){void 0===t&&(t=[e]);const n=(0,h.useRef)(e);return se(()=>{n.current!==e&&(n.current=e)},t),n}function ue(e,t){const n=(0,h.useRef)();return(0,h.useMemo)(()=>{const t=e(n.current);return n.current=t,t},[...t])}function de(e){const t=le(e),n=(0,h.useRef)(null),r=(0,h.useCallback)(e=>{e!==n.current&&(null==t||t(e,n.current)),n.current=e},[]);return[n,r]}function fe(e){const t=(0,h.useRef)();return(0,h.useEffect)(()=>{t.current=e},[e]),t.current}let pe={};function ge(e,t){return(0,h.useMemo)(()=>{if(t)return t;const n=null==pe[e]?0:pe[e]+1;return pe[e]=n,e+"-"+n},[e,t])}function he(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce((t,n)=>{const r=Object.entries(n);for(const[n,o]of r){const r=t[n];null!=r&&(t[n]=r+e*o)}return t},{...t})}}const ve=he(1),me=he(-1);function be(e){if(!e)return!1;const{KeyboardEvent:t}=ne(e.target);return t&&e instanceof t}function ye(e){if(function(e){if(!e)return!1;const{TouchEvent:t}=ne(e.target);return t&&e instanceof t}(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return function(e){return"clientX"in e&&"clientY"in e}(e)?{x:e.clientX,y:e.clientY}:null}const xe=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[xe.Translate.toString(e),xe.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),we="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function Ce(e){return e.matches(we)?e:e.querySelector(we)}const Re={display:"none"};function De(e){let{id:t,value:n}=e;return v().createElement("div",{id:t,style:Re},n)}function Ee(e){let{id:t,announcement:n,ariaLiveType:r="assertive"}=e;return v().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":r,"aria-atomic":!0},n)}const Se=(0,h.createContext)(null),ke={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 "},Ae={onDragStart(e){let{active:t}=e;return"Picked up draggable item "+t.id+"."},onDragOver(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was moved over droppable area "+n.id+".":"Draggable item "+t.id+" is no longer over a droppable area."},onDragEnd(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was dropped over droppable area "+n.id:"Draggable item "+t.id+" was dropped."},onDragCancel(e){let{active:t}=e;return"Dragging was cancelled. Draggable item "+t.id+" was dropped."}};function Oe(e){let{announcements:t=Ae,container:n,hiddenTextDescribedById:r,screenReaderInstructions:o=ke}=e;const{announce:i,announcement:a}=function(){const[e,t]=(0,h.useState)("");return{announce:(0,h.useCallback)(e=>{null!=e&&t(e)},[]),announcement:e}}(),s=ge("DndLiveRegion"),[l,c]=(0,h.useState)(!1);if((0,h.useEffect)(()=>{c(!0)},[]),function(e){const t=(0,h.useContext)(Se);(0,h.useEffect)(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t])}((0,h.useMemo)(()=>({onDragStart(e){let{active:n}=e;i(t.onDragStart({active:n}))},onDragMove(e){let{active:n,over:r}=e;t.onDragMove&&i(t.onDragMove({active:n,over:r}))},onDragOver(e){let{active:n,over:r}=e;i(t.onDragOver({active:n,over:r}))},onDragEnd(e){let{active:n,over:r}=e;i(t.onDragEnd({active:n,over:r}))},onDragCancel(e){let{active:n,over:r}=e;i(t.onDragCancel({active:n,over:r}))}}),[i,t])),!l)return null;const u=v().createElement(v().Fragment,null,v().createElement(De,{id:r,value:o.draggable}),v().createElement(Ee,{id:s,announcement:a}));return n?(0,Z.createPortal)(u,n):u}var Me;function Ie(){}function Te(e,t){return(0,h.useMemo)(()=>({sensor:e,options:null!=t?t:{}}),[e,t])}!function(e){e.DragStart="dragStart",e.DragMove="dragMove",e.DragEnd="dragEnd",e.DragCancel="dragCancel",e.DragOver="dragOver",e.RegisterDroppable="registerDroppable",e.SetDroppableDisabled="setDroppableDisabled",e.UnregisterDroppable="unregisterDroppable"}(Me||(Me={}));const je=Object.freeze({x:0,y:0});function Ne(e,t){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function Le(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return n-r}function _e(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return r-n}function Pe(e,t,n){return void 0===t&&(t=e.left),void 0===n&&(n=e.top),{x:t+.5*e.width,y:n+.5*e.height}}const Fe=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=Pe(t,t.left,t.top),i=[];for(const e of r){const{id:t}=e,r=n.get(t);if(r){const n=Ne(Pe(r),o);i.push({id:t,data:{droppableContainer:e,value:n}})}}return i.sort(Le)};function qe(e,t){const n=Math.max(t.top,e.top),r=Math.max(t.left,e.left),o=Math.min(t.left+t.width,e.left+e.width),i=Math.min(t.top+t.height,e.top+e.height),a=o-r,s=i-n;if(r<o&&n<i){const n=t.width*t.height,r=e.width*e.height,o=a*s;return Number((o/(n+r-o)).toFixed(4))}return 0}const Be=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=[];for(const e of r){const{id:r}=e,i=n.get(r);if(i){const n=qe(i,t);n>0&&o.push({id:r,data:{droppableContainer:e,value:n}})}}return o.sort(_e)};function Ue(e,t){return e&&t?{x:e.left-t.left,y:e.top-t.top}:je}function ze(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce((t,n)=>({...t,top:t.top+e*n.y,bottom:t.bottom+e*n.y,left:t.left+e*n.x,right:t.right+e*n.x}),{...t})}}const We=ze(1);const He={ignoreTransform:!1};function Xe(e,t){void 0===t&&(t=He);let n=e.getBoundingClientRect();if(t.ignoreTransform){const{transform:t,transformOrigin:r}=ne(e).getComputedStyle(e);t&&(n=function(e,t,n){const r=function(e){if(e.startsWith("matrix3d(")){const t=e.slice(9,-1).split(/, /);return{x:+t[12],y:+t[13],scaleX:+t[0],scaleY:+t[5]}}if(e.startsWith("matrix(")){const t=e.slice(7,-1).split(/, /);return{x:+t[4],y:+t[5],scaleX:+t[0],scaleY:+t[3]}}return null}(t);if(!r)return e;const{scaleX:o,scaleY:i,x:a,y:s}=r,l=e.left-a-(1-o)*parseFloat(n),c=e.top-s-(1-i)*parseFloat(n.slice(n.indexOf(" ")+1)),u=o?e.width/o:e.width,d=i?e.height/i:e.height;return{width:u,height:d,top:c,right:l+u,bottom:c+d,left:l}}(n,t,r))}const{top:r,left:o,width:i,height:a,bottom:s,right:l}=n;return{top:r,left:o,width:i,height:a,bottom:s,right:l}}function Ye(e){return Xe(e,{ignoreTransform:!0})}function $e(e,t){const n=[];return e?function r(o){if(null!=t&&n.length>=t)return n;if(!o)return n;if(re(o)&&null!=o.scrollingElement&&!n.includes(o.scrollingElement))return n.push(o.scrollingElement),n;if(!oe(o)||ie(o))return n;if(n.includes(o))return n;const i=ne(e).getComputedStyle(o);return o!==e&&function(e,t){void 0===t&&(t=ne(e).getComputedStyle(e));const n=/(auto|scroll|overlay)/;return["overflow","overflowX","overflowY"].some(e=>{const r=t[e];return"string"==typeof r&&n.test(r)})}(o,i)&&n.push(o),function(e,t){return void 0===t&&(t=ne(e).getComputedStyle(e)),"fixed"===t.position}(o,i)?n:r(o.parentNode)}(e):n}function Ke(e){const[t]=$e(e,1);return null!=t?t:null}function Ve(e){return Q&&e?ee(e)?e:te(e)?re(e)||e===ae(e).scrollingElement?window:oe(e)?e:null:null:null}function Ge(e){return ee(e)?e.scrollX:e.scrollLeft}function Je(e){return ee(e)?e.scrollY:e.scrollTop}function Ze(e){return{x:Ge(e),y:Je(e)}}var Qe;function et(e){return!(!Q||!e)&&e===document.scrollingElement}function tt(e){const t={x:0,y:0},n=et(e)?{height:window.innerHeight,width:window.innerWidth}:{height:e.clientHeight,width:e.clientWidth},r={x:e.scrollWidth-n.width,y:e.scrollHeight-n.height};return{isTop:e.scrollTop<=t.y,isLeft:e.scrollLeft<=t.x,isBottom:e.scrollTop>=r.y,isRight:e.scrollLeft>=r.x,maxScroll:r,minScroll:t}}!function(e){e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward"}(Qe||(Qe={}));const nt={x:.2,y:.2};function rt(e,t,n,r,o){let{top:i,left:a,right:s,bottom:l}=n;void 0===r&&(r=10),void 0===o&&(o=nt);const{isTop:c,isBottom:u,isLeft:d,isRight:f}=tt(e),p={x:0,y:0},g={x:0,y:0},h=t.height*o.y,v=t.width*o.x;return!c&&i<=t.top+h?(p.y=Qe.Backward,g.y=r*Math.abs((t.top+h-i)/h)):!u&&l>=t.bottom-h&&(p.y=Qe.Forward,g.y=r*Math.abs((t.bottom-h-l)/h)),!f&&s>=t.right-v?(p.x=Qe.Forward,g.x=r*Math.abs((t.right-v-s)/v)):!d&&a<=t.left+v&&(p.x=Qe.Backward,g.x=r*Math.abs((t.left+v-a)/v)),{direction:p,speed:g}}function ot(e){if(e===document.scrollingElement){const{innerWidth:e,innerHeight:t}=window;return{top:0,left:0,right:e,bottom:t,width:e,height:t}}const{top:t,left:n,right:r,bottom:o}=e.getBoundingClientRect();return{top:t,left:n,right:r,bottom:o,width:e.clientWidth,height:e.clientHeight}}function it(e){return e.reduce((e,t)=>ve(e,Ze(t)),je)}const at=[["x",["left","right"],function(e){return e.reduce((e,t)=>e+Ge(t),0)}],["y",["top","bottom"],function(e){return e.reduce((e,t)=>e+Je(t),0)}]];class st{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=$e(t),r=it(n);this.rect={...e},this.width=e.width,this.height=e.height;for(const[e,t,o]of at)for(const i of t)Object.defineProperty(this,i,{get:()=>{const t=o(n),a=r[e]-t;return this.rect[i]+a},enumerable:!0});Object.defineProperty(this,"rect",{enumerable:!1})}}class lt{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,n){var r;null==(r=this.target)||r.addEventListener(e,t,n),this.listeners.push([e,t,n])}}function ct(e,t){const n=Math.abs(e.x),r=Math.abs(e.y);return"number"==typeof t?Math.sqrt(n**2+r**2)>t:"x"in t&&"y"in t?n>t.x&&r>t.y:"x"in t?n>t.x:"y"in t&&r>t.y}var ut,dt;function ft(e){e.preventDefault()}function pt(e){e.stopPropagation()}!function(e){e.Click="click",e.DragStart="dragstart",e.Keydown="keydown",e.ContextMenu="contextmenu",e.Resize="resize",e.SelectionChange="selectionchange",e.VisibilityChange="visibilitychange"}(ut||(ut={})),function(e){e.Space="Space",e.Down="ArrowDown",e.Right="ArrowRight",e.Left="ArrowLeft",e.Up="ArrowUp",e.Esc="Escape",e.Enter="Enter",e.Tab="Tab"}(dt||(dt={}));const gt={start:[dt.Space,dt.Enter],cancel:[dt.Esc],end:[dt.Space,dt.Enter,dt.Tab]},ht=(e,t)=>{let{currentCoordinates:n}=t;switch(e.code){case dt.Right:return{...n,x:n.x+25};case dt.Left:return{...n,x:n.x-25};case dt.Down:return{...n,y:n.y+25};case dt.Up:return{...n,y:n.y-25}}};class vt{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 lt(ae(t)),this.windowListeners=new lt(ne(t)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(ut.Resize,this.handleCancel),this.windowListeners.add(ut.VisibilityChange,this.handleCancel),setTimeout(()=>this.listeners.add(ut.Keydown,this.handleKeyDown))}handleStart(){const{activeNode:e,onStart:t}=this.props,n=e.node.current;n&&function(e,t){if(void 0===t&&(t=Xe),!e)return;const{top:n,left:r,bottom:o,right:i}=t(e);Ke(e)&&(o<=0||i<=0||n>=window.innerHeight||r>=window.innerWidth)&&e.scrollIntoView({block:"center",inline:"center"})}(n),t(je)}handleKeyDown(e){if(be(e)){const{active:t,context:n,options:r}=this.props,{keyboardCodes:o=gt,coordinateGetter:i=ht,scrollBehavior:a="smooth"}=r,{code:s}=e;if(o.end.includes(s))return void this.handleEnd(e);if(o.cancel.includes(s))return void this.handleCancel(e);const{collisionRect:l}=n.current,c=l?{x:l.left,y:l.top}:je;this.referenceCoordinates||(this.referenceCoordinates=c);const u=i(e,{active:t,context:n.current,currentCoordinates:c});if(u){const t=me(u,c),r={x:0,y:0},{scrollableAncestors:o}=n.current;for(const n of o){const o=e.code,{isTop:i,isRight:s,isLeft:l,isBottom:c,maxScroll:d,minScroll:f}=tt(n),p=ot(n),g={x:Math.min(o===dt.Right?p.right-p.width/2:p.right,Math.max(o===dt.Right?p.left:p.left+p.width/2,u.x)),y:Math.min(o===dt.Down?p.bottom-p.height/2:p.bottom,Math.max(o===dt.Down?p.top:p.top+p.height/2,u.y))},h=o===dt.Right&&!s||o===dt.Left&&!l,v=o===dt.Down&&!c||o===dt.Up&&!i;if(h&&g.x!==u.x){const e=n.scrollLeft+t.x,i=o===dt.Right&&e<=d.x||o===dt.Left&&e>=f.x;if(i&&!t.y)return void n.scrollTo({left:e,behavior:a});r.x=i?n.scrollLeft-e:o===dt.Right?n.scrollLeft-d.x:n.scrollLeft-f.x,r.x&&n.scrollBy({left:-r.x,behavior:a});break}if(v&&g.y!==u.y){const e=n.scrollTop+t.y,i=o===dt.Down&&e<=d.y||o===dt.Up&&e>=f.y;if(i&&!t.x)return void n.scrollTo({top:e,behavior:a});r.y=i?n.scrollTop-e:o===dt.Down?n.scrollTop-d.y:n.scrollTop-f.y,r.y&&n.scrollBy({top:-r.y,behavior:a});break}}this.handleMove(e,ve(me(u,this.referenceCoordinates),r))}}}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()}}function mt(e){return Boolean(e&&"distance"in e)}function bt(e){return Boolean(e&&"delay"in e)}vt.activators=[{eventName:"onKeyDown",handler:(e,t,n)=>{let{keyboardCodes:r=gt,onActivation:o}=t,{active:i}=n;const{code:a}=e.nativeEvent;if(r.start.includes(a)){const t=i.activatorNode.current;return!(t&&e.target!==t||(e.preventDefault(),null==o||o({event:e.nativeEvent}),0))}return!1}}];class yt{constructor(e,t,n){var r;void 0===n&&(n=function(e){const{EventTarget:t}=ne(e);return e instanceof t?e:ae(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:o}=e,{target:i}=o;this.props=e,this.events=t,this.document=ae(i),this.documentListeners=new lt(this.document),this.listeners=new lt(n),this.windowListeners=new lt(ne(i)),this.initialCoordinates=null!=(r=ye(o))?r:je,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(ut.Resize,this.handleCancel),this.windowListeners.add(ut.DragStart,ft),this.windowListeners.add(ut.VisibilityChange,this.handleCancel),this.windowListeners.add(ut.ContextMenu,ft),this.documentListeners.add(ut.Keydown,this.handleKeydown),t){if(null!=n&&n({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if(bt(t))return this.timeoutId=setTimeout(this.handleStart,t.delay),void this.handlePending(t);if(mt(t))return void this.handlePending(t)}this.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){const{active:n,onPending:r}=this.props;r(n,e,this.initialCoordinates,t)}handleStart(){const{initialCoordinates:e}=this,{onStart:t}=this.props;e&&(this.activated=!0,this.documentListeners.add(ut.Click,pt,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(ut.SelectionChange,this.removeTextSelection),t(e))}handleMove(e){var t;const{activated:n,initialCoordinates:r,props:o}=this,{onMove:i,options:{activationConstraint:a}}=o;if(!r)return;const s=null!=(t=ye(e))?t:je,l=me(r,s);if(!n&&a){if(mt(a)){if(null!=a.tolerance&&ct(l,a.tolerance))return this.handleCancel();if(ct(l,a.distance))return this.handleStart()}return bt(a)&&ct(l,a.tolerance)?this.handleCancel():void this.handlePending(a,l)}e.cancelable&&e.preventDefault(),i(s)}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===dt.Esc&&this.handleCancel()}removeTextSelection(){var e;null==(e=this.document.getSelection())||e.removeAllRanges()}}const xt={cancel:{name:"pointercancel"},move:{name:"pointermove"},end:{name:"pointerup"}};class wt extends yt{constructor(e){const{event:t}=e,n=ae(t.target);super(e,xt,n)}}wt.activators=[{eventName:"onPointerDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return!(!n.isPrimary||0!==n.button||(null==r||r({event:n}),0))}}];const Ct={move:{name:"mousemove"},end:{name:"mouseup"}};var Rt;!function(e){e[e.RightClick=2]="RightClick"}(Rt||(Rt={}));class Dt extends yt{constructor(e){super(e,Ct,ae(e.event.target))}}Dt.activators=[{eventName:"onMouseDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return n.button!==Rt.RightClick&&(null==r||r({event:n}),!0)}}];const Et={cancel:{name:"touchcancel"},move:{name:"touchmove"},end:{name:"touchend"}};class St extends yt{constructor(e){super(e,Et)}static setup(){return window.addEventListener(Et.move.name,e,{capture:!1,passive:!1}),function(){window.removeEventListener(Et.move.name,e)};function e(){}}}var kt,At;St.activators=[{eventName:"onTouchStart",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;const{touches:o}=n;return!(o.length>1||(null==r||r({event:n}),0))}}],function(e){e[e.Pointer=0]="Pointer",e[e.DraggableRect=1]="DraggableRect"}(kt||(kt={})),function(e){e[e.TreeOrder=0]="TreeOrder",e[e.ReversedTreeOrder=1]="ReversedTreeOrder"}(At||(At={}));const Ot={x:{[Qe.Backward]:!1,[Qe.Forward]:!1},y:{[Qe.Backward]:!1,[Qe.Forward]:!1}};var Mt,It;!function(e){e[e.Always=0]="Always",e[e.BeforeDragging=1]="BeforeDragging",e[e.WhileDragging=2]="WhileDragging"}(Mt||(Mt={})),function(e){e.Optimized="optimized"}(It||(It={}));const Tt=new Map;function jt(e,t){return ue(n=>e?n||("function"==typeof t?t(e):e):null,[t,e])}function Nt(e){let{callback:t,disabled:n}=e;const r=le(t),o=(0,h.useMemo)(()=>{if(n||"undefined"==typeof window||void 0===window.ResizeObserver)return;const{ResizeObserver:e}=window;return new e(r)},[n]);return(0,h.useEffect)(()=>()=>null==o?void 0:o.disconnect(),[o]),o}function Lt(e){return new st(Xe(e),e)}function _t(e,t,n){void 0===t&&(t=Lt);const[r,o]=(0,h.useState)(null);function i(){o(r=>{if(!e)return null;var o;if(!1===e.isConnected)return null!=(o=null!=r?r:n)?o:null;const i=t(e);return JSON.stringify(r)===JSON.stringify(i)?r:i})}const a=function(e){let{callback:t,disabled:n}=e;const r=le(t),o=(0,h.useMemo)(()=>{if(n||"undefined"==typeof window||void 0===window.MutationObserver)return;const{MutationObserver:e}=window;return new e(r)},[r,n]);return(0,h.useEffect)(()=>()=>null==o?void 0:o.disconnect(),[o]),o}({callback(t){if(e)for(const n of t){const{type:t,target:r}=n;if("childList"===t&&r instanceof HTMLElement&&r.contains(e)){i();break}}}}),s=Nt({callback:i});return se(()=>{i(),e?(null==s||s.observe(e),null==a||a.observe(document.body,{childList:!0,subtree:!0})):(null==s||s.disconnect(),null==a||a.disconnect())},[e]),r}const Pt=[];function Ft(e,t){void 0===t&&(t=[]);const n=(0,h.useRef)(null);return(0,h.useEffect)(()=>{n.current=null},t),(0,h.useEffect)(()=>{const t=e!==je;t&&!n.current&&(n.current=e),!t&&n.current&&(n.current=null)},[e]),n.current?me(e,n.current):je}function qt(e){return(0,h.useMemo)(()=>e?function(e){const t=e.innerWidth,n=e.innerHeight;return{top:0,left:0,right:t,bottom:n,width:t,height:n}}(e):null,[e])}const Bt=[];const Ut=[{sensor:wt,options:{}},{sensor:vt,options:{}}],zt={current:{}},Wt={draggable:{measure:Ye},droppable:{measure:Ye,strategy:Mt.WhileDragging,frequency:It.Optimized},dragOverlay:{measure:Xe}};class Ht 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,n;return null!=(t=null==(n=this.get(e))?void 0:n.node.current)?t:void 0}}const Xt={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new Ht,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:Ie},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:Wt,measureDroppableContainers:Ie,windowRect:null,measuringScheduled:!1},Yt={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:""},dispatch:Ie,draggableNodes:new Map,over:null,measureDroppableContainers:Ie},$t=(0,h.createContext)(Yt),Kt=(0,h.createContext)(Xt);function Vt(){return{draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new Ht}}}function Gt(e,t){switch(t.type){case Me.DragStart:return{...e,draggable:{...e.draggable,initialCoordinates:t.initialCoordinates,active:t.active}};case Me.DragMove:return null==e.draggable.active?e:{...e,draggable:{...e.draggable,translate:{x:t.coordinates.x-e.draggable.initialCoordinates.x,y:t.coordinates.y-e.draggable.initialCoordinates.y}}};case Me.DragEnd:case Me.DragCancel:return{...e,draggable:{...e.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case Me.RegisterDroppable:{const{element:n}=t,{id:r}=n,o=new Ht(e.droppable.containers);return o.set(r,n),{...e,droppable:{...e.droppable,containers:o}}}case Me.SetDroppableDisabled:{const{id:n,key:r,disabled:o}=t,i=e.droppable.containers.get(n);if(!i||r!==i.key)return e;const a=new Ht(e.droppable.containers);return a.set(n,{...i,disabled:o}),{...e,droppable:{...e.droppable,containers:a}}}case Me.UnregisterDroppable:{const{id:n,key:r}=t,o=e.droppable.containers.get(n);if(!o||r!==o.key)return e;const i=new Ht(e.droppable.containers);return i.delete(n),{...e,droppable:{...e.droppable,containers:i}}}default:return e}}function Jt(e){let{disabled:t}=e;const{active:n,activatorEvent:r,draggableNodes:o}=(0,h.useContext)($t),i=fe(r),a=fe(null==n?void 0:n.id);return(0,h.useEffect)(()=>{if(!t&&!r&&i&&null!=a){if(!be(i))return;if(document.activeElement===i.target)return;const e=o.get(a);if(!e)return;const{activatorNode:t,node:n}=e;if(!t.current&&!n.current)return;requestAnimationFrame(()=>{for(const e of[t.current,n.current]){if(!e)continue;const t=Ce(e);if(t){t.focus();break}}})}},[r,t,o,a,i]),null}const Zt=(0,h.createContext)({...je,scaleX:1,scaleY:1});var Qt;!function(e){e[e.Uninitialized=0]="Uninitialized",e[e.Initializing=1]="Initializing",e[e.Initialized=2]="Initialized"}(Qt||(Qt={}));const en=(0,h.memo)(function(e){var t,n,r,o;let{id:i,accessibility:a,autoScroll:s=!0,children:l,sensors:c=Ut,collisionDetection:u=Be,measuring:d,modifiers:f,...p}=e;const g=(0,h.useReducer)(Gt,void 0,Vt),[m,b]=g,[y,x]=function(){const[e]=(0,h.useState)(()=>new Set),t=(0,h.useCallback)(t=>(e.add(t),()=>e.delete(t)),[e]),n=(0,h.useCallback)(t=>{let{type:n,event:r}=t;e.forEach(e=>{var t;return null==(t=e[n])?void 0:t.call(e,r)})},[e]);return[n,t]}(),[w,C]=(0,h.useState)(Qt.Uninitialized),R=w===Qt.Initialized,{draggable:{active:D,nodes:E,translate:S},droppable:{containers:k}}=m,A=null!=D?E.get(D):null,O=(0,h.useRef)({initial:null,translated:null}),M=(0,h.useMemo)(()=>{var e;return null!=D?{id:D,data:null!=(e=null==A?void 0:A.data)?e:zt,rect:O}:null},[D,A]),I=(0,h.useRef)(null),[T,j]=(0,h.useState)(null),[N,L]=(0,h.useState)(null),_=ce(p,Object.values(p)),P=ge("DndDescribedBy",i),F=(0,h.useMemo)(()=>k.getEnabled(),[k]),q=(B=d,(0,h.useMemo)(()=>({draggable:{...Wt.draggable,...null==B?void 0:B.draggable},droppable:{...Wt.droppable,...null==B?void 0:B.droppable},dragOverlay:{...Wt.dragOverlay,...null==B?void 0:B.dragOverlay}}),[null==B?void 0:B.draggable,null==B?void 0:B.droppable,null==B?void 0:B.dragOverlay]));var B;const{droppableRects:U,measureDroppableContainers:z,measuringScheduled:W}=function(e,t){let{dragging:n,dependencies:r,config:o}=t;const[i,a]=(0,h.useState)(null),{frequency:s,measure:l,strategy:c}=o,u=(0,h.useRef)(e),d=function(){switch(c){case Mt.Always:return!1;case Mt.BeforeDragging:return n;default:return!n}}(),f=ce(d),p=(0,h.useCallback)(function(e){void 0===e&&(e=[]),f.current||a(t=>null===t?e:t.concat(e.filter(e=>!t.includes(e))))},[f]),g=(0,h.useRef)(null),v=ue(t=>{if(d&&!n)return Tt;if(!t||t===Tt||u.current!==e||null!=i){const t=new Map;for(let n of e){if(!n)continue;if(i&&i.length>0&&!i.includes(n.id)&&n.rect.current){t.set(n.id,n.rect.current);continue}const e=n.node.current,r=e?new st(l(e),e):null;n.rect.current=r,r&&t.set(n.id,r)}return t}return t},[e,i,n,d,l]);return(0,h.useEffect)(()=>{u.current=e},[e]),(0,h.useEffect)(()=>{d||p()},[n,d]),(0,h.useEffect)(()=>{i&&i.length>0&&a(null)},[JSON.stringify(i)]),(0,h.useEffect)(()=>{d||"number"!=typeof s||null!==g.current||(g.current=setTimeout(()=>{p(),g.current=null},s))},[s,d,p,...r]),{droppableRects:v,measureDroppableContainers:p,measuringScheduled:null!=i}}(F,{dragging:R,dependencies:[S.x,S.y],config:q.droppable}),H=function(e,t){const n=null!=t?e.get(t):void 0,r=n?n.node.current:null;return ue(e=>{var n;return null==t?null:null!=(n=null!=r?r:e)?n:null},[r,t])}(E,D),X=(0,h.useMemo)(()=>N?ye(N):null,[N]),Y=function(){const e=!1===(null==T?void 0:T.autoScrollEnabled),t="object"==typeof s?!1===s.enabled:!1===s,n=R&&!e&&!t;return"object"==typeof s?{...s,enabled:n}:{enabled:n}}(),$=function(e,t){return jt(e,t)}(H,q.draggable.measure);!function(e){let{activeNode:t,measure:n,initialRect:r,config:o=!0}=e;const i=(0,h.useRef)(!1),{x:a,y:s}="boolean"==typeof o?{x:o,y:o}:o;se(()=>{if(!a&&!s||!t)return void(i.current=!1);if(i.current||!r)return;const e=null==t?void 0:t.node.current;if(!e||!1===e.isConnected)return;const o=Ue(n(e),r);if(a||(o.x=0),s||(o.y=0),i.current=!0,Math.abs(o.x)>0||Math.abs(o.y)>0){const t=Ke(e);t&&t.scrollBy({top:o.y,left:o.x})}},[t,a,s,r,n])}({activeNode:null!=D?E.get(D):null,config:Y.layoutShiftCompensation,initialRect:$,measure:q.draggable.measure});const K=_t(H,q.draggable.measure,$),V=_t(H?H.parentElement:null),G=(0,h.useRef)({activatorEvent:null,active:null,activeNode:H,collisionRect:null,collisions:null,droppableRects:U,draggableNodes:E,draggingNode:null,draggingNodeRect:null,droppableContainers:k,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),J=k.getNodeFor(null==(t=G.current.over)?void 0:t.id),ee=function(e){let{measure:t}=e;const[n,r]=(0,h.useState)(null),o=Nt({callback:(0,h.useCallback)(e=>{for(const{target:n}of e)if(oe(n)){r(e=>{const r=t(n);return e?{...e,width:r.width,height:r.height}:r});break}},[t])}),i=(0,h.useCallback)(e=>{const n=function(e){if(!e)return null;if(e.children.length>1)return e;const t=e.children[0];return oe(t)?t:e}(e);null==o||o.disconnect(),n&&(null==o||o.observe(n)),r(n?t(n):null)},[t,o]),[a,s]=de(i);return(0,h.useMemo)(()=>({nodeRef:a,rect:n,setRef:s}),[n,a,s])}({measure:q.dragOverlay.measure}),te=null!=(n=ee.nodeRef.current)?n:H,re=R?null!=(r=ee.rect)?r:K:null,ie=Boolean(ee.nodeRef.current&&ee.rect),ae=Ue(le=ie?null:K,jt(le));var le;const pe=qt(te?ne(te):null),he=function(e){const t=(0,h.useRef)(e),n=ue(n=>e?n&&n!==Pt&&e&&t.current&&e.parentNode===t.current.parentNode?n:$e(e):Pt,[e]);return(0,h.useEffect)(()=>{t.current=e},[e]),n}(R?null!=J?J:H:null),me=function(e,t){void 0===t&&(t=Xe);const[n]=e,r=qt(n?ne(n):null),[o,i]=(0,h.useState)(Bt);function a(){i(()=>e.length?e.map(e=>et(e)?r:new st(t(e),e)):Bt)}const s=Nt({callback:a});return se(()=>{null==s||s.disconnect(),a(),e.forEach(e=>null==s?void 0:s.observe(e))},[e]),o}(he),be=function(e,t){let{transform:n,...r}=t;return null!=e&&e.length?e.reduce((e,t)=>t({transform:e,...r}),n):n}(f,{transform:{x:S.x-ae.x,y:S.y-ae.y,scaleX:1,scaleY:1},activatorEvent:N,active:M,activeNodeRect:K,containerNodeRect:V,draggingNodeRect:re,over:G.current.over,overlayNodeRect:ee.rect,scrollableAncestors:he,scrollableAncestorRects:me,windowRect:pe}),xe=X?ve(X,S):null,we=function(e){const[t,n]=(0,h.useState)(null),r=(0,h.useRef)(e),o=(0,h.useCallback)(e=>{const t=Ve(e.target);t&&n(e=>e?(e.set(t,Ze(t)),new Map(e)):null)},[]);return(0,h.useEffect)(()=>{const t=r.current;if(e!==t){i(t);const a=e.map(e=>{const t=Ve(e);return t?(t.addEventListener("scroll",o,{passive:!0}),[t,Ze(t)]):null}).filter(e=>null!=e);n(a.length?new Map(a):null),r.current=e}return()=>{i(e),i(t)};function i(e){e.forEach(e=>{const t=Ve(e);null==t||t.removeEventListener("scroll",o)})}},[o,e]),(0,h.useMemo)(()=>e.length?t?Array.from(t.values()).reduce((e,t)=>ve(e,t),je):it(e):je,[e,t])}(he),Ce=Ft(we),Re=Ft(we,[K]),De=ve(be,Ce),Ee=re?We(re,be):null,ke=M&&Ee?u({active:M,collisionRect:Ee,droppableRects:U,droppableContainers:F,pointerCoordinates:xe}):null,Ae=function(e){if(!e||0===e.length)return null;const[t]=e;return t.id}(ke),[Ie,Te]=(0,h.useState)(null),Ne=function(e,t,n){return{...e,scaleX:t&&n?t.width/n.width:1,scaleY:t&&n?t.height/n.height:1}}(ie?be:ve(be,Re),null!=(o=null==Ie?void 0:Ie.rect)?o:null,K),Le=(0,h.useRef)(null),_e=(0,h.useCallback)((e,t)=>{let{sensor:n,options:r}=t;if(null==I.current)return;const o=E.get(I.current);if(!o)return;const i=e.nativeEvent,a=new n({active:I.current,activeNode:o,event:i,options:r,context:G,onAbort(e){if(!E.get(e))return;const{onDragAbort:t}=_.current,n={id:e};null==t||t(n),y({type:"onDragAbort",event:n})},onPending(e,t,n,r){if(!E.get(e))return;const{onDragPending:o}=_.current,i={id:e,constraint:t,initialCoordinates:n,offset:r};null==o||o(i),y({type:"onDragPending",event:i})},onStart(e){const t=I.current;if(null==t)return;const n=E.get(t);if(!n)return;const{onDragStart:r}=_.current,o={activatorEvent:i,active:{id:t,data:n.data,rect:O}};(0,Z.unstable_batchedUpdates)(()=>{null==r||r(o),C(Qt.Initializing),b({type:Me.DragStart,initialCoordinates:e,active:t}),y({type:"onDragStart",event:o}),j(Le.current),L(i)})},onMove(e){b({type:Me.DragMove,coordinates:e})},onEnd:s(Me.DragEnd),onCancel:s(Me.DragCancel)});function s(e){return async function(){const{active:t,collisions:n,over:r,scrollAdjustedTranslate:o}=G.current;let a=null;if(t&&o){const{cancelDrop:s}=_.current;a={activatorEvent:i,active:t,collisions:n,delta:o,over:r},e===Me.DragEnd&&"function"==typeof s&&await Promise.resolve(s(a))&&(e=Me.DragCancel)}I.current=null,(0,Z.unstable_batchedUpdates)(()=>{b({type:e}),C(Qt.Uninitialized),Te(null),j(null),L(null),Le.current=null;const t=e===Me.DragEnd?"onDragEnd":"onDragCancel";if(a){const e=_.current[t];null==e||e(a),y({type:t,event:a})}})}}Le.current=a},[E]),Pe=(0,h.useCallback)((e,t)=>(n,r)=>{const o=n.nativeEvent,i=E.get(r);if(null!==I.current||!i||o.dndKit||o.defaultPrevented)return;const a={active:i};!0===e(n,t.options,a)&&(o.dndKit={capturedBy:t.sensor},I.current=r,_e(n,t))},[E,_e]),Fe=function(e,t){return(0,h.useMemo)(()=>e.reduce((e,n)=>{const{sensor:r}=n;return[...e,...r.activators.map(e=>({eventName:e.eventName,handler:t(e.handler,n)}))]},[]),[e,t])}(c,Pe);!function(e){(0,h.useEffect)(()=>{if(!Q)return;const t=e.map(e=>{let{sensor:t}=e;return null==t.setup?void 0:t.setup()});return()=>{for(const e of t)null==e||e()}},e.map(e=>{let{sensor:t}=e;return t}))}(c),se(()=>{K&&w===Qt.Initializing&&C(Qt.Initialized)},[K,w]),(0,h.useEffect)(()=>{const{onDragMove:e}=_.current,{active:t,activatorEvent:n,collisions:r,over:o}=G.current;if(!t||!n)return;const i={active:t,activatorEvent:n,collisions:r,delta:{x:De.x,y:De.y},over:o};(0,Z.unstable_batchedUpdates)(()=>{null==e||e(i),y({type:"onDragMove",event:i})})},[De.x,De.y]),(0,h.useEffect)(()=>{const{active:e,activatorEvent:t,collisions:n,droppableContainers:r,scrollAdjustedTranslate:o}=G.current;if(!e||null==I.current||!t||!o)return;const{onDragOver:i}=_.current,a=r.get(Ae),s=a&&a.rect.current?{id:a.id,rect:a.rect.current,data:a.data,disabled:a.disabled}:null,l={active:e,activatorEvent:t,collisions:n,delta:{x:o.x,y:o.y},over:s};(0,Z.unstable_batchedUpdates)(()=>{Te(s),null==i||i(l),y({type:"onDragOver",event:l})})},[Ae]),se(()=>{G.current={activatorEvent:N,active:M,activeNode:H,collisionRect:Ee,collisions:ke,droppableRects:U,draggableNodes:E,draggingNode:te,draggingNodeRect:re,droppableContainers:k,over:Ie,scrollableAncestors:he,scrollAdjustedTranslate:De},O.current={initial:re,translated:Ee}},[M,H,ke,Ee,E,te,re,U,k,Ie,he,De]),function(e){let{acceleration:t,activator:n=kt.Pointer,canScroll:r,draggingRect:o,enabled:i,interval:a=5,order:s=At.TreeOrder,pointerCoordinates:l,scrollableAncestors:c,scrollableAncestorRects:u,delta:d,threshold:f}=e;const p=function(e){let{delta:t,disabled:n}=e;const r=fe(t);return ue(e=>{if(n||!r||!e)return Ot;const o=Math.sign(t.x-r.x),i=Math.sign(t.y-r.y);return{x:{[Qe.Backward]:e.x[Qe.Backward]||-1===o,[Qe.Forward]:e.x[Qe.Forward]||1===o},y:{[Qe.Backward]:e.y[Qe.Backward]||-1===i,[Qe.Forward]:e.y[Qe.Forward]||1===i}}},[n,t,r])}({delta:d,disabled:!i}),[g,v]=function(){const e=(0,h.useRef)(null);return[(0,h.useCallback)((t,n)=>{e.current=setInterval(t,n)},[]),(0,h.useCallback)(()=>{null!==e.current&&(clearInterval(e.current),e.current=null)},[])]}(),m=(0,h.useRef)({x:0,y:0}),b=(0,h.useRef)({x:0,y:0}),y=(0,h.useMemo)(()=>{switch(n){case kt.Pointer:return l?{top:l.y,bottom:l.y,left:l.x,right:l.x}:null;case kt.DraggableRect:return o}},[n,o,l]),x=(0,h.useRef)(null),w=(0,h.useCallback)(()=>{const e=x.current;if(!e)return;const t=m.current.x*b.current.x,n=m.current.y*b.current.y;e.scrollBy(t,n)},[]),C=(0,h.useMemo)(()=>s===At.TreeOrder?[...c].reverse():c,[s,c]);(0,h.useEffect)(()=>{if(i&&c.length&&y){for(const e of C){if(!1===(null==r?void 0:r(e)))continue;const n=c.indexOf(e),o=u[n];if(!o)continue;const{direction:i,speed:s}=rt(e,o,y,t,f);for(const e of["x","y"])p[e][i[e]]||(s[e]=0,i[e]=0);if(s.x>0||s.y>0)return v(),x.current=e,g(w,a),m.current=s,void(b.current=i)}m.current={x:0,y:0},b.current={x:0,y:0},v()}else v()},[t,w,r,v,i,a,JSON.stringify(y),JSON.stringify(p),g,c,C,u,JSON.stringify(f)])}({...Y,delta:S,draggingRect:Ee,pointerCoordinates:xe,scrollableAncestors:he,scrollableAncestorRects:me});const qe=(0,h.useMemo)(()=>({active:M,activeNode:H,activeNodeRect:K,activatorEvent:N,collisions:ke,containerNodeRect:V,dragOverlay:ee,draggableNodes:E,droppableContainers:k,droppableRects:U,over:Ie,measureDroppableContainers:z,scrollableAncestors:he,scrollableAncestorRects:me,measuringConfiguration:q,measuringScheduled:W,windowRect:pe}),[M,H,K,N,ke,V,ee,E,k,U,Ie,z,he,me,q,W,pe]),ze=(0,h.useMemo)(()=>({activatorEvent:N,activators:Fe,active:M,activeNodeRect:K,ariaDescribedById:{draggable:P},dispatch:b,draggableNodes:E,over:Ie,measureDroppableContainers:z}),[N,Fe,M,K,b,P,E,Ie,z]);return v().createElement(Se.Provider,{value:x},v().createElement($t.Provider,{value:ze},v().createElement(Kt.Provider,{value:qe},v().createElement(Zt.Provider,{value:Ne},l)),v().createElement(Jt,{disabled:!1===(null==a?void 0:a.restoreFocus)})),v().createElement(Oe,{...a,hiddenTextDescribedById:P}))}),tn=(0,h.createContext)(null),nn="button";const rn={timeout:25};function on(e,t,n){const r=e.slice();return r.splice(n<0?r.length+n:n,0,r.splice(t,1)[0]),r}function an(e,t){return e.reduce((e,n,r)=>{const o=t.get(n);return o&&(e[r]=o),e},Array(e.length))}function sn(e){return null!==e&&e>=0}const ln=e=>{let{rects:t,activeIndex:n,overIndex:r,index:o}=e;const i=on(t,r,n),a=t[o],s=i[o];return s&&a?{x:s.left-a.left,y:s.top-a.top,scaleX:s.width/a.width,scaleY:s.height/a.height}:null},cn="Sortable",un=v().createContext({activeIndex:-1,containerId:cn,disableTransforms:!1,items:[],overIndex:-1,useDragOverlay:!1,sortedRects:[],strategy:ln,disabled:{draggable:!1,droppable:!1}});function dn(e){let{children:t,id:n,items:r,strategy:o=ln,disabled:i=!1}=e;const{active:a,dragOverlay:s,droppableRects:l,over:c,measureDroppableContainers:u}=(0,h.useContext)(Kt),d=ge(cn,n),f=Boolean(null!==s.rect),p=(0,h.useMemo)(()=>r.map(e=>"object"==typeof e&&"id"in e?e.id:e),[r]),g=null!=a,m=a?p.indexOf(a.id):-1,b=c?p.indexOf(c.id):-1,y=(0,h.useRef)(p),x=!function(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}(p,y.current),w=-1!==b&&-1===m||x,C=function(e){return"boolean"==typeof e?{draggable:e,droppable:e}:e}(i);se(()=>{x&&g&&u(p)},[x,p,g,u]),(0,h.useEffect)(()=>{y.current=p},[p]);const R=(0,h.useMemo)(()=>({activeIndex:m,containerId:d,disabled:C,disableTransforms:w,items:p,overIndex:b,useDragOverlay:f,sortedRects:an(p,l),strategy:o}),[m,d,C.draggable,C.droppable,w,p,b,l,f,o]);return v().createElement(un.Provider,{value:R},t)}const fn=e=>{let{id:t,items:n,activeIndex:r,overIndex:o}=e;return on(n,r,o).indexOf(t)},pn=e=>{let{containerId:t,isSorting:n,wasDragging:r,index:o,items:i,newIndex:a,previousItems:s,previousContainerId:l,transition:c}=e;return!(!c||!r||s!==i&&o===a||!n&&(a===o||t!==l))},gn={duration:200,easing:"ease"},hn="transform",vn=xe.Transition.toString({property:hn,duration:0,easing:"linear"}),mn={roleDescription:"sortable"};function bn(e){let{animateLayoutChanges:t=pn,attributes:n,disabled:r,data:o,getNewIndex:i=fn,id:a,strategy:s,resizeObserverConfig:l,transition:c=gn}=e;const{items:u,containerId:d,activeIndex:f,disabled:p,disableTransforms:g,sortedRects:v,overIndex:m,useDragOverlay:b,strategy:y}=(0,h.useContext)(un),x=function(e,t){var n,r;return"boolean"==typeof e?{draggable:e,droppable:!1}:{draggable:null!=(n=null==e?void 0:e.draggable)?n:t.draggable,droppable:null!=(r=null==e?void 0:e.droppable)?r:t.droppable}}(r,p),w=u.indexOf(a),C=(0,h.useMemo)(()=>({sortable:{containerId:d,index:w,items:u},...o}),[d,o,w,u]),R=(0,h.useMemo)(()=>u.slice(u.indexOf(a)),[u,a]),{rect:D,node:E,isOver:S,setNodeRef:k}=function(e){let{data:t,disabled:n=!1,id:r,resizeObserverConfig:o}=e;const i=ge("Droppable"),{active:a,dispatch:s,over:l,measureDroppableContainers:c}=(0,h.useContext)($t),u=(0,h.useRef)({disabled:n}),d=(0,h.useRef)(!1),f=(0,h.useRef)(null),p=(0,h.useRef)(null),{disabled:g,updateMeasurementsFor:v,timeout:m}={...rn,...o},b=ce(null!=v?v:r),y=Nt({callback:(0,h.useCallback)(()=>{d.current?(null!=p.current&&clearTimeout(p.current),p.current=setTimeout(()=>{c(Array.isArray(b.current)?b.current:[b.current]),p.current=null},m)):d.current=!0},[m]),disabled:g||!a}),x=(0,h.useCallback)((e,t)=>{y&&(t&&(y.unobserve(t),d.current=!1),e&&y.observe(e))},[y]),[w,C]=de(x),R=ce(t);return(0,h.useEffect)(()=>{y&&w.current&&(y.disconnect(),d.current=!1,y.observe(w.current))},[w,y]),(0,h.useEffect)(()=>(s({type:Me.RegisterDroppable,element:{id:r,key:i,disabled:n,node:w,rect:f,data:R}}),()=>s({type:Me.UnregisterDroppable,key:i,id:r})),[r]),(0,h.useEffect)(()=>{n!==u.current.disabled&&(s({type:Me.SetDroppableDisabled,id:r,key:i,disabled:n}),u.current.disabled=n)},[r,i,n,s]),{active:a,rect:f,isOver:(null==l?void 0:l.id)===r,node:w,over:l,setNodeRef:C}}({id:a,data:C,disabled:x.droppable,resizeObserverConfig:{updateMeasurementsFor:R,...l}}),{active:A,activatorEvent:O,activeNodeRect:M,attributes:I,setNodeRef:T,listeners:j,isDragging:N,over:L,setActivatorNodeRef:_,transform:P}=function(e){let{id:t,data:n,disabled:r=!1,attributes:o}=e;const i=ge("Draggable"),{activators:a,activatorEvent:s,active:l,activeNodeRect:c,ariaDescribedById:u,draggableNodes:d,over:f}=(0,h.useContext)($t),{role:p=nn,roleDescription:g="draggable",tabIndex:v=0}=null!=o?o:{},m=(null==l?void 0:l.id)===t,b=(0,h.useContext)(m?Zt:tn),[y,x]=de(),[w,C]=de(),R=function(e,t){return(0,h.useMemo)(()=>e.reduce((e,n)=>{let{eventName:r,handler:o}=n;return e[r]=e=>{o(e,t)},e},{}),[e,t])}(a,t),D=ce(n);return se(()=>(d.set(t,{id:t,key:i,node:y,activatorNode:w,data:D}),()=>{const e=d.get(t);e&&e.key===i&&d.delete(t)}),[d,t]),{active:l,activatorEvent:s,activeNodeRect:c,attributes:(0,h.useMemo)(()=>({role:p,tabIndex:v,"aria-disabled":r,"aria-pressed":!(!m||p!==nn)||void 0,"aria-roledescription":g,"aria-describedby":u.draggable}),[r,p,v,m,g,u.draggable]),isDragging:m,listeners:r?void 0:R,node:y,over:f,setNodeRef:x,setActivatorNodeRef:C,transform:b}}({id:a,data:C,attributes:{...mn,...n},disabled:x.draggable}),F=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,h.useMemo)(()=>e=>{t.forEach(t=>t(e))},t)}(k,T),q=Boolean(A),B=q&&!g&&sn(f)&&sn(m),U=!b&&N,z=U&&B?P:null,W=B?null!=z?z:(null!=s?s:y)({rects:v,activeNodeRect:M,activeIndex:f,overIndex:m,index:w}):null,H=sn(f)&&sn(m)?i({id:a,items:u,activeIndex:f,overIndex:m}):w,X=null==A?void 0:A.id,Y=(0,h.useRef)({activeId:X,items:u,newIndex:H,containerId:d}),$=u!==Y.current.items,K=t({active:A,containerId:d,isDragging:N,isSorting:q,id:a,index:w,items:u,newIndex:Y.current.newIndex,previousItems:Y.current.items,previousContainerId:Y.current.containerId,transition:c,wasDragging:null!=Y.current.activeId}),V=function(e){let{disabled:t,index:n,node:r,rect:o}=e;const[i,a]=(0,h.useState)(null),s=(0,h.useRef)(n);return se(()=>{if(!t&&n!==s.current&&r.current){const e=o.current;if(e){const t=Xe(r.current,{ignoreTransform:!0}),n={x:e.left-t.left,y:e.top-t.top,scaleX:e.width/t.width,scaleY:e.height/t.height};(n.x||n.y)&&a(n)}}n!==s.current&&(s.current=n)},[t,n,r,o]),(0,h.useEffect)(()=>{i&&a(null)},[i]),i}({disabled:!K,index:w,node:E,rect:D});return(0,h.useEffect)(()=>{q&&Y.current.newIndex!==H&&(Y.current.newIndex=H),d!==Y.current.containerId&&(Y.current.containerId=d),u!==Y.current.items&&(Y.current.items=u)},[q,H,d,u]),(0,h.useEffect)(()=>{if(X===Y.current.activeId)return;if(X&&!Y.current.activeId)return void(Y.current.activeId=X);const e=setTimeout(()=>{Y.current.activeId=X},50);return()=>clearTimeout(e)},[X]),{active:A,activeIndex:f,attributes:I,data:C,rect:D,index:w,newIndex:H,items:u,isOver:S,isSorting:q,isDragging:N,listeners:j,node:E,overIndex:m,over:L,setNodeRef:F,setActivatorNodeRef:_,setDroppableNodeRef:k,setDraggableNodeRef:T,transform:null!=V?V:W,transition:V||$&&Y.current.newIndex===w?vn:U&&!be(O)||!c?void 0:q||K?xe.Transition.toString({...c,property:hn}):void 0}}dt.Down,dt.Right,dt.Up,dt.Left;const yn=e=>{let{containerNodeRect:t,draggingNodeRect:n,transform:r}=e;return n&&t?function(e,t,n){const r={...e};return t.top+e.y<=n.top?r.y=n.top-t.top:t.bottom+e.y>=n.top+n.height&&(r.y=n.top+n.height-t.bottom),t.left+e.x<=n.left?r.x=n.left-t.left:t.right+e.x>=n.left+n.width&&(r.x=n.left+n.width-t.right),r}(r,n,t):r};function xn(){return xn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},xn.apply(null,arguments)}const wn=A("div",{target:"e1hax4ql7",label:"ImageWrapper"})("flex-basis:155px;width:155px;height:100px;margin-right:20px;margin-bottom:20px;border:",G.borders.textField,";border-radius:",G.lengths.borderRadius,";overflow:hidden;",G.effects.checkerboard,";",G.shadows.inset,";cursor:",e=>e.sortable?"pointer":"auto",";"),Cn=A("div",{target:"e1hax4ql6",label:"SortableImageButtonsWrapper"})({name:"1ekgmip",styles:"display:flex;justify-content:center;column-gap:10px;margin-right:20px;margin-top:-10px;margin-bottom:10px"}),Rn=A("img",{target:"e1hax4ql5",label:"StyledImage"})({name:"ukfjzf",styles:"width:100%;height:100%;object-fit:contain"});function Dn({value:e,field:n,getAsset:r}){const[o,i]=(0,h.useState)(null);return(0,h.useEffect)(()=>{if(e){const t=r(e,n);i(t)}else i(null)},[e,n,r]),o?(0,t.jsx)(Rn,{role:"presentation",src:o}):null}function En({onRemove:e,onReplace:n}){return(0,t.jsx)(Cn,null,(0,t.jsx)(G.IconButton,{size:"small",type:"media",onClick:n}),(0,t.jsx)(G.IconButton,{size:"small",type:"close",onClick:e}))}function Sn(e){const{attributes:n,listeners:r,setNodeRef:o,transform:i,transition:a}=bn({id:e.id}),s={transform:xe.Transform.toString(i),transition:a},{itemValue:l,getAsset:c,field:u,onRemove:d,onReplace:f}=e;return(0,t.jsx)("div",xn({ref:o,style:s},n,r),(0,t.jsx)(wn,{sortable:!0},(0,t.jsx)(Dn,{value:l,field:u,getAsset:c})),(0,t.jsx)(En,{item:l,onRemove:d,onReplace:f}))}var kn={name:"a42x49-SortableMultiImageWrapper",styles:"display:flex;flex-wrap:wrap;label:SortableMultiImageWrapper;"};function An({items:e,getAsset:n,field:r,onSortEnd:o,onRemoveOne:i,onReplaceOne:a}){const s={distance:4},l=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,h.useMemo)(()=>[...t].filter(e=>null!=e),[...t])}(Te(Dt,{activationConstraint:s}),Te(St,{activationConstraint:s}));return(0,t.jsx)("div",{css:kn},(0,t.jsx)(en,{modifiers:[yn],collisionDetection:Fe,sensors:l,onDragEnd:function({active:t,over:n}){o({oldIndex:e.findIndex(e=>e.id===t.id),newIndex:e.findIndex(e=>e.id===n.id)})}},(0,t.jsx)(dn,{items:e},e.map((e,o)=>(0,t.jsx)(Sn,{key:e.id,id:e.id,index:o,itemValue:e.value,getAsset:n,field:r,onRemove:i(o),onReplace:a(o)})))))}const On=A("a",{target:"e1hax4ql4",label:"FileLink"})({name:"7mbjrw",styles:"margin-bottom:20px;font-weight:normal;color:inherit;&:hover,&:active,&:focus{text-decoration:underline;}"}),Mn=A("div",{target:"e1hax4ql3",label:"FileLinks"})({name:"cn3xcj",styles:"margin-bottom:12px"}),In=A("ul",{target:"e1hax4ql2",label:"FileLinkList"})({name:"ffhm6p",styles:"list-style-type:none"}),Tn=A("button",{target:"e1hax4ql1",label:"FileWidgetButton"})(G.buttons.button,";",G.components.badge,";margin-bottom:12px;"),jn=A("button",{target:"e1hax4ql0",label:"FileWidgetButtonRemove"})(G.buttons.button,";",G.components.badgeDanger,";");function Nn(e){return Array.isArray(e)||j.List.isList(e)}function Ln(e){return j.List.isList(e)?e.toArray():e??""}const _n=L()(e=>console.warn(V`
2
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("@emotion/react"),require("react"),require("prop-types"),require("react-immutable-proptypes"),require("immutable"),require("decap-cms-ui-default")):"function"==typeof define&&define.amd?define("DecapCmsWidgetFile",["@emotion/react","react","prop-types","react-immutable-proptypes","immutable","decap-cms-ui-default"],t):"object"==typeof exports?exports.DecapCmsWidgetFile=t(require("@emotion/react"),require("react"),require("prop-types"),require("react-immutable-proptypes"),require("immutable"),require("decap-cms-ui-default")):e.DecapCmsWidgetFile=t(e.DecapCmsDefaultExports.EmotionCore,e.React,e.DecapCmsDefaultExports.PropTypes,e.DecapCmsDefaultExports.ImmutablePropTypes,e.DecapCmsDefaultExports.Immutable,e.DecapCmsUiDefault)}(window,(e,t,n,r,o,i)=>(()=>{var a={985(e,t,n){"use strict";var r=n(524),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function l(e){return r.isMemo(e)?a:s[e.$$typeof]||o}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},s[r.Memo]=a;var c=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(h){var o=p(n);o&&o!==h&&e(t,o,r)}var a=u(n);d&&(a=a.concat(d(n)));for(var s=l(t),g=l(n),v=0;v<a.length;++v){var m=a[v];if(!(i[m]||r&&r[m]||g&&g[m]||s&&s[m])){var b=f(n,m);try{c(t,m,b)}catch(e){}}}}return t}},650(e,t,n){var r=n(942).Symbol;e.exports=r},379(e,t,n){var r=n(650),o=n(870),i=n(5),a=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":a&&a in Object(e)?o(e):i(e)}},403(e,t,n){var r=n(945),o=/^\s+/;e.exports=function(e){return e?e.slice(0,r(e)+1).replace(o,""):e}},967(e,t,n){var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;e.exports=r},870(e,t,n){var r=n(650),o=Object.prototype,i=o.hasOwnProperty,a=o.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=i.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var o=a.call(e);return r&&(t?e[s]=n:delete e[s]),o}},5(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},942(e,t,n){var r=n(967),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();e.exports=i},945(e){var t=/\s/;e.exports=function(e){for(var n=e.length;n--&&t.test(e.charAt(n)););return n}},80(e,t,n){var r=n(642);e.exports=function(e,t){var n;if("function"!=typeof t)throw new TypeError("Expected a function");return e=r(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=void 0),n}}},580(e){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},547(e){e.exports=function(e){return null!=e&&"object"==typeof e}},187(e,t,n){var r=n(379),o=n(547);e.exports=function(e){return"symbol"==typeof e||o(e)&&"[object Symbol]"==r(e)}},354(e,t,n){var r=n(80);e.exports=function(e){return r(2,e)}},301(e,t,n){var r=n(131),o=1/0;e.exports=function(e){return e?(e=r(e))===o||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}},642(e,t,n){var r=n(301);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},131(e,t,n){var r=n(403),o=n(580),i=n(187),a=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,l=/^0o[0-7]+$/i,c=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(i(e))return NaN;if(o(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=r(e);var n=s.test(e);return n||l.test(e)?c(e.slice(2),n?2:8):a.test(e)?NaN:+e}},310(e,t,n){"use strict";var r=n(119);function o(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var i=Symbol.for("react.portal");r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;t.createPortal=function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!t||1!==t.nodeType&&9!==t.nodeType&&11!==t.nodeType)throw Error(o(299));return function(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:i,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}(e,t,null,n)},t.unstable_batchedUpdates=function(e,t){return e(t)}},144(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(310)},320(e,t){"use strict";var n="function"==typeof Symbol&&Symbol.for,r=n?Symbol.for("react.element"):60103,o=n?Symbol.for("react.portal"):60106,i=n?Symbol.for("react.fragment"):60107,a=n?Symbol.for("react.strict_mode"):60108,s=n?Symbol.for("react.profiler"):60114,l=n?Symbol.for("react.provider"):60109,c=n?Symbol.for("react.context"):60110,u=n?Symbol.for("react.async_mode"):60111,d=n?Symbol.for("react.concurrent_mode"):60111,f=n?Symbol.for("react.forward_ref"):60112,p=n?Symbol.for("react.suspense"):60113,h=n?Symbol.for("react.suspense_list"):60120,g=n?Symbol.for("react.memo"):60115,v=n?Symbol.for("react.lazy"):60116,m=n?Symbol.for("react.block"):60121,b=n?Symbol.for("react.fundamental"):60117,y=n?Symbol.for("react.responder"):60118,w=n?Symbol.for("react.scope"):60119;function x(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case u:case d:case i:case s:case a:case p:return e;default:switch(e=e&&e.$$typeof){case c:case f:case v:case g:case l:return e;default:return t}}case o:return t}}}function C(e){return x(e)===d}t.AsyncMode=u,t.ConcurrentMode=d,t.ContextConsumer=c,t.ContextProvider=l,t.Element=r,t.ForwardRef=f,t.Fragment=i,t.Lazy=v,t.Memo=g,t.Portal=o,t.Profiler=s,t.StrictMode=a,t.Suspense=p,t.isAsyncMode=function(e){return C(e)||x(e)===u},t.isConcurrentMode=C,t.isContextConsumer=function(e){return x(e)===c},t.isContextProvider=function(e){return x(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===r},t.isForwardRef=function(e){return x(e)===f},t.isFragment=function(e){return x(e)===i},t.isLazy=function(e){return x(e)===v},t.isMemo=function(e){return x(e)===g},t.isPortal=function(e){return x(e)===o},t.isProfiler=function(e){return x(e)===s},t.isStrictMode=function(e){return x(e)===a},t.isSuspense=function(e){return x(e)===p},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===d||e===s||e===a||e===p||e===h||"object"==typeof e&&null!==e&&(e.$$typeof===v||e.$$typeof===g||e.$$typeof===l||e.$$typeof===c||e.$$typeof===f||e.$$typeof===b||e.$$typeof===y||e.$$typeof===w||e.$$typeof===m)},t.typeOf=x},524(e,t,n){"use strict";e.exports=n(320)},197(e,t){"use strict";var n=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function o(e,t,r){var o=null;if(void 0!==r&&(o=""+r),void 0!==t.key&&(o=""+t.key),"key"in t)for(var i in r={},t)"key"!==i&&(r[i]=t[i]);else r=t;return t=r.ref,{$$typeof:n,type:e,key:o,ref:void 0!==t?t:null,props:r}}t.Fragment=r,t.jsx=o,t.jsxs=o},85(e,t,n){"use strict";e.exports=n(197)},119(e){"use strict";e.exports=t},110(t){"use strict";t.exports=e},522(e){"use strict";e.exports=o},630(e){"use strict";e.exports=r},434(e){"use strict";e.exports=n},171(e){"use strict";e.exports=i}};const s={};function l(e){const t=s[e];if(void 0!==t)return t.exports;const n=s[e]={exports:{}};return a[e](n,n.exports,l),n.exports}l.n=e=>{const t=e&&e.__esModule?()=>e.default:()=>e;return l.d(t,{a:t}),t},l.d=(e,t)=>{if(Array.isArray(t))for(var n=0;n<t.length;){var r=t[n++],o=t[n++];l.o(e,r)?0===o&&n++:0===o?Object.defineProperty(e,r,{enumerable:!0,value:t[n++]}):Object.defineProperty(e,r,{enumerable:!0,get:o})}else for(var r in t)l.o(t,r)&&!l.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},l.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),l.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);let c={};return(()=>{"use strict";function e(){return e=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},e.apply(null,arguments)}l.d(c,{DecapCmsWidgetFile:()=>io});var t=l(110),n={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function r(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}var o=/[A-Z]|^ms/g,i=/_EMO_([^_]+?)_([^]*?)_EMO_/g,a=function(e){return 45===e.charCodeAt(1)},s=function(e){return null!=e&&"boolean"!=typeof e},u=r(function(e){return a(e)?e:e.replace(o,"-$&").toLowerCase()}),d=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(i,function(e,t,n){return p={name:t,styles:n,next:p},t})}return 1===n[e]||a(e)||"number"!=typeof t||0===t?t:t+"px"};function f(e,t,n){if(null==n)return"";var r=n;if(void 0!==r.__emotion_styles)return r;switch(typeof n){case"boolean":return"";case"object":var o=n;if(1===o.anim)return p={name:o.name,styles:o.styles,next:p},o.name;var i=n;if(void 0!==i.styles){var a=i.next;if(void 0!==a)for(;void 0!==a;)p={name:a.name,styles:a.styles,next:p},a=a.next;return i.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=f(e,t,n[o])+";";else for(var i in n){var a=n[i];if("object"!=typeof a){var l=a;null!=t&&void 0!==t[l]?r+=i+"{"+t[l]+"}":s(l)&&(r+=u(i)+":"+d(i,l)+";")}else if(!Array.isArray(a)||"string"!=typeof a[0]||null!=t&&void 0!==t[a[0]]){var c=f(e,t,a);switch(i){case"animation":case"animationName":r+=u(i)+":"+c+";";break;default:r+=i+"{"+c+"}"}}else for(var p=0;p<a.length;p++)s(a[p])&&(r+=u(i)+":"+d(i,a[p])+";")}return r}(e,t,n);case"function":if(void 0!==e){var l=p,c=n(e);return p=l,f(e,t,c)}}var h=n;if(null==t)return h;var g=t[h];return void 0!==g?g:h}var p,h=/label:\s*([^\s;{]+)\s*(;|$)/g;function g(e,t,n){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,o="";p=void 0;var i=e[0];null==i||void 0===i.raw?(r=!1,o+=f(n,t,i)):o+=i[0];for(var a=1;a<e.length;a++)o+=f(n,t,e[a]),r&&(o+=i[a]);h.lastIndex=0;for(var s,l="";null!==(s=h.exec(o));)l+="-"+s[1];var c=function(e){for(var t,n=0,r=0,o=e.length;o>=4;++r,o-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(o){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)}(o)+l;return{name:c,styles:o,next:p}}var v=l(119),m=l.n(v),b=!!v.useInsertionEffect&&v.useInsertionEffect,y=b||function(e){return e()};function w(e,t,n){var r="";return n.split(" ").forEach(function(n){void 0!==e[n]?t.push(e[n]+";"):n&&(r+=n+" ")}),r}b||v.useLayoutEffect;var x,C,S=function(e,t,n){var r=e.key+"-"+t.name;!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles)},R=function(e,t,n){S(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var o=t;do{e.insert(t===o?"."+r:"",o,e.sheet,!0),o=o.next}while(void 0!==o)}},E=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,k=r(function(e){return E.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91}),D=function(e){return"theme"!==e},A=function(e){return"string"==typeof e&&e.charCodeAt(0)>96?k:D},O=function(e,t,n){var r;if(t){var o=t.shouldForwardProp;r=e.__emotion_forwardProp&&o?function(t){return e.__emotion_forwardProp(t)&&o(t)}:o}return"function"!=typeof r&&n&&(r=e.__emotion_forwardProp),r},M=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return S(t,n,r),y(function(){return R(t,n,r)}),null},T=function n(r,o){var i,a,s=r.__emotion_real===r,l=s&&r.__emotion_base||r;void 0!==o&&(i=o.label,a=o.target);var c=O(r,o,s),u=c||A(l),d=!u("as");return function(){var f=arguments,p=s&&void 0!==r.__emotion_styles?r.__emotion_styles.slice(0):[];if(void 0!==i&&p.push("label:"+i+";"),null==f[0]||void 0===f[0].raw)p.push.apply(p,f);else{var h=f[0];p.push(h[0]);for(var m=f.length,b=1;b<m;b++)p.push(f[b],h[b])}var y=(0,t.withEmotionCache)(function(e,n,r){var o=d&&e.as||l,i="",s=[],f=e;if(null==e.theme){for(var h in f={},e)f[h]=e[h];f.theme=v.useContext(t.ThemeContext)}"string"==typeof e.className?i=w(n.registered,s,e.className):null!=e.className&&(i=e.className+" ");var m=g(p.concat(s),n.registered,f);i+=n.key+"-"+m.name,void 0!==a&&(i+=" "+a);var b=d&&void 0===c?A(o):u,y={};for(var x in e)d&&"as"===x||b(x)&&(y[x]=e[x]);return y.className=i,r&&(y.ref=r),v.createElement(v.Fragment,null,v.createElement(M,{cache:n,serialized:m,isStringTag:"string"==typeof o}),v.createElement(o,y))});return y.displayName=void 0!==i?i:"Styled("+("string"==typeof l?l:l.displayName||l.name||"Component")+")",y.defaultProps=r.defaultProps,y.__emotion_real=y,y.__emotion_base=l,y.__emotion_styles=p,y.__emotion_forwardProp=c,Object.defineProperty(y,"toString",{value:function(){return"."+a}}),y.withComponent=function(t,r){return n(t,e({},o,r,{shouldForwardProp:O(y,r,!0)})).apply(void 0,p)},y}},I=l(434),N=l.n(I),_=l(630),L=l.n(_),P=l(522),$=l(354),j=l.n($),F=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),z=(x=["",""],C=["",""],Object.freeze(Object.defineProperties(x,{raw:{value:Object.freeze(C)}}))),U=function(){function e(){for(var t=this,n=arguments.length,r=Array(n),o=0;o<n;o++)r[o]=arguments[o];return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.tag=function(e){for(var n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return"function"==typeof e?t.interimTag.bind(t,e):"string"==typeof e?t.transformEndResult(e):(e=e.map(t.transformString.bind(t)),t.transformEndResult(e.reduce(t.processSubstitutions.bind(t,r))))},r.length>0&&Array.isArray(r[0])&&(r=r[0]),this.transformers=r.map(function(e){return"function"==typeof e?e():e}),this.tag}return F(e,[{key:"interimTag",value:function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return this.tag(z,e.apply(void 0,[t].concat(r)))}},{key:"processSubstitutions",value:function(e,t,n){var r=this.transformSubstitution(e.shift(),t);return"".concat(t,r,n)}},{key:"transformString",value:function(e){return this.transformers.reduce(function(e,t){return t.onString?t.onString(e):e},e)}},{key:"transformSubstitution",value:function(e,t){return this.transformers.reduce(function(e,n){return n.onSubstitution?n.onSubstitution(e,t):e},e)}},{key:"transformEndResult",value:function(e){return this.transformers.reduce(function(e,t){return t.onEndResult?t.onEndResult(e):e},e)}}]),e}();const q=U,B=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"initial";return{onEndResult:function(t){if("initial"===e){var n=t.match(/^[^\S\n]*(?=\S)/gm),r=n&&Math.min.apply(Math,function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(n.map(function(e){return e.length})));if(r){var o=new RegExp("^.{"+r+"}","gm");return t.replace(o,"")}return t}if("all"===e)return t.replace(/^[^\S\n]+/gm,"");throw new Error("Unknown type: "+e)}}};var W={separator:"",conjunction:"",serial:!1};const H=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:W;return{onSubstitution:function(t,n){if(Array.isArray(t)){var r=t.length,o=e.separator,i=e.conjunction,a=e.serial,s=n.match(/(\n?[^\S\n]+)$/);if(t=s?t.join(o+s[1]):t.join(o+" "),i&&r>1){var l=t.lastIndexOf(o);t=t.slice(0,l)+(a?o:"")+" "+i+t.slice(l+1)}}return t}}},Y=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return{onEndResult:function(t){if(""===e)return t.trim();if("start"===(e=e.toLowerCase())||"left"===e)return t.replace(/^\s*/,"");if("end"===e||"right"===e)return t.replace(/\s*$/,"");throw new Error("Side not supported: "+e)}}};new q(H({separator:","}),B,Y),new q(H({separator:",",conjunction:"and"}),B,Y),new q(H({separator:",",conjunction:"or"}),B,Y);const X=function(e){return{onSubstitution:function(t,n){if(null==e||"string"!=typeof e)throw new Error("You need to specify a string character to split by.");return"string"==typeof t&&t.includes(e)&&(t=t.split(e)),t}}};var K=function(e){return null!=e&&!Number.isNaN(e)&&"boolean"!=typeof e};new q(X("\n"),function(){return{onSubstitution:function(e){return Array.isArray(e)?e.filter(K):K(e)?e:""}}},H,B,Y);const V=function(e,t){return{onSubstitution:function(n,r){if(null==e||null==t)throw new Error("replaceSubstitutionTransformer requires at least 2 arguments.");return null==n?n:n.toString().replace(e,t)}}};new q(X("\n"),H,B,Y,V(/&/g,"&amp;"),V(/</g,"&lt;"),V(/>/g,"&gt;"),V(/"/g,"&quot;"),V(/'/g,"&#x27;"),V(/`/g,"&#x60;"));const G=function(e,t){return{onEndResult:function(n){if(null==e||null==t)throw new Error("replaceResultTransformer requires at least 2 arguments.");return n.replace(e,t)}}},J=new q(G(/(?:\n(?:\s*))+/g," "),Y);new q(G(/(?:\n\s*)/g,""),Y),new q(H({separator:","}),G(/(?:\s+)/g," "),Y),new q(H({separator:",",conjunction:"or"}),G(/(?:\s+)/g," "),Y),new q(H({separator:",",conjunction:"and"}),G(/(?:\s+)/g," "),Y),new q(H,B,Y),new q(H,G(/(?:\s+)/g," "),Y),new q(B,Y),new q(B("all"),Y);var Z=l(171);function Q(e,t=""){if(""===e)return e;const n=(o=e,e=o.replace(/[\\/]+/g,"/")).split("/"),r=n[n.length-1];var o;return""===r&&n.length>1?n[n.length-2]:t.length>0&&r.slice(-t.length)===t?r.slice(0,-t.length):r}new RegExp("^(?:[a-z]+:)?//|^/","i");var ee=l(144);const te="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement;function ne(e){const t=Object.prototype.toString.call(e);return"[object Window]"===t||"[object global]"===t}function re(e){return"nodeType"in e}function oe(e){var t,n;return e?ne(e)?e:re(e)&&null!=(t=null==(n=e.ownerDocument)?void 0:n.defaultView)?t:window:window}function ie(e){const{Document:t}=oe(e);return e instanceof t}function ae(e){return!ne(e)&&e instanceof oe(e).HTMLElement}function se(e){return e instanceof oe(e).SVGElement}function le(e){return e?ne(e)?e.document:re(e)?ie(e)?e:ae(e)||se(e)?e.ownerDocument:document:document:document}const ce=te?v.useLayoutEffect:v.useEffect;function ue(e){const t=(0,v.useRef)(e);return ce(()=>{t.current=e}),(0,v.useCallback)(function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return null==t.current?void 0:t.current(...n)},[])}function de(e,t){void 0===t&&(t=[e]);const n=(0,v.useRef)(e);return ce(()=>{n.current!==e&&(n.current=e)},t),n}function fe(e,t){const n=(0,v.useRef)();return(0,v.useMemo)(()=>{const t=e(n.current);return n.current=t,t},[...t])}function pe(e){const t=ue(e),n=(0,v.useRef)(null),r=(0,v.useCallback)(e=>{e!==n.current&&(null==t||t(e,n.current)),n.current=e},[]);return[n,r]}function he(e){const t=(0,v.useRef)();return(0,v.useEffect)(()=>{t.current=e},[e]),t.current}let ge={};function ve(e,t){return(0,v.useMemo)(()=>{if(t)return t;const n=null==ge[e]?0:ge[e]+1;return ge[e]=n,e+"-"+n},[e,t])}function me(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce((t,n)=>{const r=Object.entries(n);for(const[n,o]of r){const r=t[n];null!=r&&(t[n]=r+e*o)}return t},{...t})}}const be=me(1),ye=me(-1);function we(e){if(!e)return!1;const{KeyboardEvent:t}=oe(e.target);return t&&e instanceof t}function xe(e){if(function(e){if(!e)return!1;const{TouchEvent:t}=oe(e.target);return t&&e instanceof t}(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return function(e){return"clientX"in e&&"clientY"in e}(e)?{x:e.clientX,y:e.clientY}:null}const Ce=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[Ce.Translate.toString(e),Ce.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),Se="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function Re(e){return e.matches(Se)?e:e.querySelector(Se)}const Ee={display:"none"};function ke(e){let{id:t,value:n}=e;return m().createElement("div",{id:t,style:Ee},n)}function De(e){let{id:t,announcement:n,ariaLiveType:r="assertive"}=e;return m().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":r,"aria-atomic":!0},n)}const Ae=(0,v.createContext)(null),Oe={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 "},Me={onDragStart(e){let{active:t}=e;return"Picked up draggable item "+t.id+"."},onDragOver(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was moved over droppable area "+n.id+".":"Draggable item "+t.id+" is no longer over a droppable area."},onDragEnd(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was dropped over droppable area "+n.id:"Draggable item "+t.id+" was dropped."},onDragCancel(e){let{active:t}=e;return"Dragging was cancelled. Draggable item "+t.id+" was dropped."}};function Te(e){let{announcements:t=Me,container:n,hiddenTextDescribedById:r,screenReaderInstructions:o=Oe}=e;const{announce:i,announcement:a}=function(){const[e,t]=(0,v.useState)("");return{announce:(0,v.useCallback)(e=>{null!=e&&t(e)},[]),announcement:e}}(),s=ve("DndLiveRegion"),[l,c]=(0,v.useState)(!1);if((0,v.useEffect)(()=>{c(!0)},[]),function(e){const t=(0,v.useContext)(Ae);(0,v.useEffect)(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t])}((0,v.useMemo)(()=>({onDragStart(e){let{active:n}=e;i(t.onDragStart({active:n}))},onDragMove(e){let{active:n,over:r}=e;t.onDragMove&&i(t.onDragMove({active:n,over:r}))},onDragOver(e){let{active:n,over:r}=e;i(t.onDragOver({active:n,over:r}))},onDragEnd(e){let{active:n,over:r}=e;i(t.onDragEnd({active:n,over:r}))},onDragCancel(e){let{active:n,over:r}=e;i(t.onDragCancel({active:n,over:r}))}}),[i,t])),!l)return null;const u=m().createElement(m().Fragment,null,m().createElement(ke,{id:r,value:o.draggable}),m().createElement(De,{id:s,announcement:a}));return n?(0,ee.createPortal)(u,n):u}var Ie;function Ne(){}function _e(e,t){return(0,v.useMemo)(()=>({sensor:e,options:null!=t?t:{}}),[e,t])}!function(e){e.DragStart="dragStart",e.DragMove="dragMove",e.DragEnd="dragEnd",e.DragCancel="dragCancel",e.DragOver="dragOver",e.RegisterDroppable="registerDroppable",e.SetDroppableDisabled="setDroppableDisabled",e.UnregisterDroppable="unregisterDroppable"}(Ie||(Ie={}));const Le=Object.freeze({x:0,y:0});function Pe(e,t){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function $e(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return n-r}function je(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return r-n}function Fe(e,t,n){return void 0===t&&(t=e.left),void 0===n&&(n=e.top),{x:t+.5*e.width,y:n+.5*e.height}}const ze=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=Fe(t,t.left,t.top),i=[];for(const e of r){const{id:t}=e,r=n.get(t);if(r){const n=Pe(Fe(r),o);i.push({id:t,data:{droppableContainer:e,value:n}})}}return i.sort($e)};function Ue(e,t){const n=Math.max(t.top,e.top),r=Math.max(t.left,e.left),o=Math.min(t.left+t.width,e.left+e.width),i=Math.min(t.top+t.height,e.top+e.height),a=o-r,s=i-n;if(r<o&&n<i){const n=t.width*t.height,r=e.width*e.height,o=a*s;return Number((o/(n+r-o)).toFixed(4))}return 0}const qe=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=[];for(const e of r){const{id:r}=e,i=n.get(r);if(i){const n=Ue(i,t);n>0&&o.push({id:r,data:{droppableContainer:e,value:n}})}}return o.sort(je)};function Be(e,t){return e&&t?{x:e.left-t.left,y:e.top-t.top}:Le}function We(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce((t,n)=>({...t,top:t.top+e*n.y,bottom:t.bottom+e*n.y,left:t.left+e*n.x,right:t.right+e*n.x}),{...t})}}const He=We(1);const Ye={ignoreTransform:!1};function Xe(e,t){void 0===t&&(t=Ye);let n=e.getBoundingClientRect();if(t.ignoreTransform){const{transform:t,transformOrigin:r}=oe(e).getComputedStyle(e);t&&(n=function(e,t,n){const r=function(e){if(e.startsWith("matrix3d(")){const t=e.slice(9,-1).split(/, /);return{x:+t[12],y:+t[13],scaleX:+t[0],scaleY:+t[5]}}if(e.startsWith("matrix(")){const t=e.slice(7,-1).split(/, /);return{x:+t[4],y:+t[5],scaleX:+t[0],scaleY:+t[3]}}return null}(t);if(!r)return e;const{scaleX:o,scaleY:i,x:a,y:s}=r,l=e.left-a-(1-o)*parseFloat(n),c=e.top-s-(1-i)*parseFloat(n.slice(n.indexOf(" ")+1)),u=o?e.width/o:e.width,d=i?e.height/i:e.height;return{width:u,height:d,top:c,right:l+u,bottom:c+d,left:l}}(n,t,r))}const{top:r,left:o,width:i,height:a,bottom:s,right:l}=n;return{top:r,left:o,width:i,height:a,bottom:s,right:l}}function Ke(e){return Xe(e,{ignoreTransform:!0})}function Ve(e,t){const n=[];return e?function r(o){if(null!=t&&n.length>=t)return n;if(!o)return n;if(ie(o)&&null!=o.scrollingElement&&!n.includes(o.scrollingElement))return n.push(o.scrollingElement),n;if(!ae(o)||se(o))return n;if(n.includes(o))return n;const i=oe(e).getComputedStyle(o);return o!==e&&function(e,t){void 0===t&&(t=oe(e).getComputedStyle(e));const n=/(auto|scroll|overlay)/;return["overflow","overflowX","overflowY"].some(e=>{const r=t[e];return"string"==typeof r&&n.test(r)})}(o,i)&&n.push(o),function(e,t){return void 0===t&&(t=oe(e).getComputedStyle(e)),"fixed"===t.position}(o,i)?n:r(o.parentNode)}(e):n}function Ge(e){const[t]=Ve(e,1);return null!=t?t:null}function Je(e){return te&&e?ne(e)?e:re(e)?ie(e)||e===le(e).scrollingElement?window:ae(e)?e:null:null:null}function Ze(e){return ne(e)?e.scrollX:e.scrollLeft}function Qe(e){return ne(e)?e.scrollY:e.scrollTop}function et(e){return{x:Ze(e),y:Qe(e)}}var tt;function nt(e){return!(!te||!e)&&e===document.scrollingElement}function rt(e){const t={x:0,y:0},n=nt(e)?{height:window.innerHeight,width:window.innerWidth}:{height:e.clientHeight,width:e.clientWidth},r={x:e.scrollWidth-n.width,y:e.scrollHeight-n.height};return{isTop:e.scrollTop<=t.y,isLeft:e.scrollLeft<=t.x,isBottom:e.scrollTop>=r.y,isRight:e.scrollLeft>=r.x,maxScroll:r,minScroll:t}}!function(e){e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward"}(tt||(tt={}));const ot={x:.2,y:.2};function it(e,t,n,r,o){let{top:i,left:a,right:s,bottom:l}=n;void 0===r&&(r=10),void 0===o&&(o=ot);const{isTop:c,isBottom:u,isLeft:d,isRight:f}=rt(e),p={x:0,y:0},h={x:0,y:0},g=t.height*o.y,v=t.width*o.x;return!c&&i<=t.top+g?(p.y=tt.Backward,h.y=r*Math.abs((t.top+g-i)/g)):!u&&l>=t.bottom-g&&(p.y=tt.Forward,h.y=r*Math.abs((t.bottom-g-l)/g)),!f&&s>=t.right-v?(p.x=tt.Forward,h.x=r*Math.abs((t.right-v-s)/v)):!d&&a<=t.left+v&&(p.x=tt.Backward,h.x=r*Math.abs((t.left+v-a)/v)),{direction:p,speed:h}}function at(e){if(e===document.scrollingElement){const{innerWidth:e,innerHeight:t}=window;return{top:0,left:0,right:e,bottom:t,width:e,height:t}}const{top:t,left:n,right:r,bottom:o}=e.getBoundingClientRect();return{top:t,left:n,right:r,bottom:o,width:e.clientWidth,height:e.clientHeight}}function st(e){return e.reduce((e,t)=>be(e,et(t)),Le)}const lt=[["x",["left","right"],function(e){return e.reduce((e,t)=>e+Ze(t),0)}],["y",["top","bottom"],function(e){return e.reduce((e,t)=>e+Qe(t),0)}]];class ct{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=Ve(t),r=st(n);this.rect={...e},this.width=e.width,this.height=e.height;for(const[e,t,o]of lt)for(const i of t)Object.defineProperty(this,i,{get:()=>{const t=o(n),a=r[e]-t;return this.rect[i]+a},enumerable:!0});Object.defineProperty(this,"rect",{enumerable:!1})}}class ut{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,n){var r;null==(r=this.target)||r.addEventListener(e,t,n),this.listeners.push([e,t,n])}}function dt(e,t){const n=Math.abs(e.x),r=Math.abs(e.y);return"number"==typeof t?Math.sqrt(n**2+r**2)>t:"x"in t&&"y"in t?n>t.x&&r>t.y:"x"in t?n>t.x:"y"in t&&r>t.y}var ft,pt;function ht(e){e.preventDefault()}function gt(e){e.stopPropagation()}!function(e){e.Click="click",e.DragStart="dragstart",e.Keydown="keydown",e.ContextMenu="contextmenu",e.Resize="resize",e.SelectionChange="selectionchange",e.VisibilityChange="visibilitychange"}(ft||(ft={})),function(e){e.Space="Space",e.Down="ArrowDown",e.Right="ArrowRight",e.Left="ArrowLeft",e.Up="ArrowUp",e.Esc="Escape",e.Enter="Enter",e.Tab="Tab"}(pt||(pt={}));const vt={start:[pt.Space,pt.Enter],cancel:[pt.Esc],end:[pt.Space,pt.Enter,pt.Tab]},mt=(e,t)=>{let{currentCoordinates:n}=t;switch(e.code){case pt.Right:return{...n,x:n.x+25};case pt.Left:return{...n,x:n.x-25};case pt.Down:return{...n,y:n.y+25};case pt.Up:return{...n,y:n.y-25}}};class bt{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 ut(le(t)),this.windowListeners=new ut(oe(t)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(ft.Resize,this.handleCancel),this.windowListeners.add(ft.VisibilityChange,this.handleCancel),setTimeout(()=>this.listeners.add(ft.Keydown,this.handleKeyDown))}handleStart(){const{activeNode:e,onStart:t}=this.props,n=e.node.current;n&&function(e,t){if(void 0===t&&(t=Xe),!e)return;const{top:n,left:r,bottom:o,right:i}=t(e);Ge(e)&&(o<=0||i<=0||n>=window.innerHeight||r>=window.innerWidth)&&e.scrollIntoView({block:"center",inline:"center"})}(n),t(Le)}handleKeyDown(e){if(we(e)){const{active:t,context:n,options:r}=this.props,{keyboardCodes:o=vt,coordinateGetter:i=mt,scrollBehavior:a="smooth"}=r,{code:s}=e;if(o.end.includes(s))return void this.handleEnd(e);if(o.cancel.includes(s))return void this.handleCancel(e);const{collisionRect:l}=n.current,c=l?{x:l.left,y:l.top}:Le;this.referenceCoordinates||(this.referenceCoordinates=c);const u=i(e,{active:t,context:n.current,currentCoordinates:c});if(u){const t=ye(u,c),r={x:0,y:0},{scrollableAncestors:o}=n.current;for(const n of o){const o=e.code,{isTop:i,isRight:s,isLeft:l,isBottom:c,maxScroll:d,minScroll:f}=rt(n),p=at(n),h={x:Math.min(o===pt.Right?p.right-p.width/2:p.right,Math.max(o===pt.Right?p.left:p.left+p.width/2,u.x)),y:Math.min(o===pt.Down?p.bottom-p.height/2:p.bottom,Math.max(o===pt.Down?p.top:p.top+p.height/2,u.y))},g=o===pt.Right&&!s||o===pt.Left&&!l,v=o===pt.Down&&!c||o===pt.Up&&!i;if(g&&h.x!==u.x){const e=n.scrollLeft+t.x,i=o===pt.Right&&e<=d.x||o===pt.Left&&e>=f.x;if(i&&!t.y)return void n.scrollTo({left:e,behavior:a});r.x=i?n.scrollLeft-e:o===pt.Right?n.scrollLeft-d.x:n.scrollLeft-f.x,r.x&&n.scrollBy({left:-r.x,behavior:a});break}if(v&&h.y!==u.y){const e=n.scrollTop+t.y,i=o===pt.Down&&e<=d.y||o===pt.Up&&e>=f.y;if(i&&!t.x)return void n.scrollTo({top:e,behavior:a});r.y=i?n.scrollTop-e:o===pt.Down?n.scrollTop-d.y:n.scrollTop-f.y,r.y&&n.scrollBy({top:-r.y,behavior:a});break}}this.handleMove(e,be(ye(u,this.referenceCoordinates),r))}}}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()}}function yt(e){return Boolean(e&&"distance"in e)}function wt(e){return Boolean(e&&"delay"in e)}bt.activators=[{eventName:"onKeyDown",handler:(e,t,n)=>{let{keyboardCodes:r=vt,onActivation:o}=t,{active:i}=n;const{code:a}=e.nativeEvent;if(r.start.includes(a)){const t=i.activatorNode.current;return!(t&&e.target!==t||(e.preventDefault(),null==o||o({event:e.nativeEvent}),0))}return!1}}];class xt{constructor(e,t,n){var r;void 0===n&&(n=function(e){const{EventTarget:t}=oe(e);return e instanceof t?e:le(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:o}=e,{target:i}=o;this.props=e,this.events=t,this.document=le(i),this.documentListeners=new ut(this.document),this.listeners=new ut(n),this.windowListeners=new ut(oe(i)),this.initialCoordinates=null!=(r=xe(o))?r:Le,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(ft.Resize,this.handleCancel),this.windowListeners.add(ft.DragStart,ht),this.windowListeners.add(ft.VisibilityChange,this.handleCancel),this.windowListeners.add(ft.ContextMenu,ht),this.documentListeners.add(ft.Keydown,this.handleKeydown),t){if(null!=n&&n({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if(wt(t))return this.timeoutId=setTimeout(this.handleStart,t.delay),void this.handlePending(t);if(yt(t))return void this.handlePending(t)}this.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){const{active:n,onPending:r}=this.props;r(n,e,this.initialCoordinates,t)}handleStart(){const{initialCoordinates:e}=this,{onStart:t}=this.props;e&&(this.activated=!0,this.documentListeners.add(ft.Click,gt,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(ft.SelectionChange,this.removeTextSelection),t(e))}handleMove(e){var t;const{activated:n,initialCoordinates:r,props:o}=this,{onMove:i,options:{activationConstraint:a}}=o;if(!r)return;const s=null!=(t=xe(e))?t:Le,l=ye(r,s);if(!n&&a){if(yt(a)){if(null!=a.tolerance&&dt(l,a.tolerance))return this.handleCancel();if(dt(l,a.distance))return this.handleStart()}return wt(a)&&dt(l,a.tolerance)?this.handleCancel():void this.handlePending(a,l)}e.cancelable&&e.preventDefault(),i(s)}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===pt.Esc&&this.handleCancel()}removeTextSelection(){var e;null==(e=this.document.getSelection())||e.removeAllRanges()}}const Ct={cancel:{name:"pointercancel"},move:{name:"pointermove"},end:{name:"pointerup"}};class St extends xt{constructor(e){const{event:t}=e,n=le(t.target);super(e,Ct,n)}}St.activators=[{eventName:"onPointerDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return!(!n.isPrimary||0!==n.button||(null==r||r({event:n}),0))}}];const Rt={move:{name:"mousemove"},end:{name:"mouseup"}};var Et;!function(e){e[e.RightClick=2]="RightClick"}(Et||(Et={}));class kt extends xt{constructor(e){super(e,Rt,le(e.event.target))}}kt.activators=[{eventName:"onMouseDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return n.button!==Et.RightClick&&(null==r||r({event:n}),!0)}}];const Dt={cancel:{name:"touchcancel"},move:{name:"touchmove"},end:{name:"touchend"}};class At extends xt{constructor(e){super(e,Dt)}static setup(){return window.addEventListener(Dt.move.name,e,{capture:!1,passive:!1}),function(){window.removeEventListener(Dt.move.name,e)};function e(){}}}var Ot,Mt;At.activators=[{eventName:"onTouchStart",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;const{touches:o}=n;return!(o.length>1||(null==r||r({event:n}),0))}}],function(e){e[e.Pointer=0]="Pointer",e[e.DraggableRect=1]="DraggableRect"}(Ot||(Ot={})),function(e){e[e.TreeOrder=0]="TreeOrder",e[e.ReversedTreeOrder=1]="ReversedTreeOrder"}(Mt||(Mt={}));const Tt={x:{[tt.Backward]:!1,[tt.Forward]:!1},y:{[tt.Backward]:!1,[tt.Forward]:!1}};var It,Nt;!function(e){e[e.Always=0]="Always",e[e.BeforeDragging=1]="BeforeDragging",e[e.WhileDragging=2]="WhileDragging"}(It||(It={})),function(e){e.Optimized="optimized"}(Nt||(Nt={}));const _t=new Map;function Lt(e,t){return fe(n=>e?n||("function"==typeof t?t(e):e):null,[t,e])}function Pt(e){let{callback:t,disabled:n}=e;const r=ue(t),o=(0,v.useMemo)(()=>{if(n||"undefined"==typeof window||void 0===window.ResizeObserver)return;const{ResizeObserver:e}=window;return new e(r)},[n]);return(0,v.useEffect)(()=>()=>null==o?void 0:o.disconnect(),[o]),o}function $t(e){return new ct(Xe(e),e)}function jt(e,t,n){void 0===t&&(t=$t);const[r,o]=(0,v.useState)(null);function i(){o(r=>{if(!e)return null;var o;if(!1===e.isConnected)return null!=(o=null!=r?r:n)?o:null;const i=t(e);return JSON.stringify(r)===JSON.stringify(i)?r:i})}const a=function(e){let{callback:t,disabled:n}=e;const r=ue(t),o=(0,v.useMemo)(()=>{if(n||"undefined"==typeof window||void 0===window.MutationObserver)return;const{MutationObserver:e}=window;return new e(r)},[r,n]);return(0,v.useEffect)(()=>()=>null==o?void 0:o.disconnect(),[o]),o}({callback(t){if(e)for(const n of t){const{type:t,target:r}=n;if("childList"===t&&r instanceof HTMLElement&&r.contains(e)){i();break}}}}),s=Pt({callback:i});return ce(()=>{i(),e?(null==s||s.observe(e),null==a||a.observe(document.body,{childList:!0,subtree:!0})):(null==s||s.disconnect(),null==a||a.disconnect())},[e]),r}const Ft=[];function zt(e,t){void 0===t&&(t=[]);const n=(0,v.useRef)(null);return(0,v.useEffect)(()=>{n.current=null},t),(0,v.useEffect)(()=>{const t=e!==Le;t&&!n.current&&(n.current=e),!t&&n.current&&(n.current=null)},[e]),n.current?ye(e,n.current):Le}function Ut(e){return(0,v.useMemo)(()=>e?function(e){const t=e.innerWidth,n=e.innerHeight;return{top:0,left:0,right:t,bottom:n,width:t,height:n}}(e):null,[e])}const qt=[];const Bt=[{sensor:St,options:{}},{sensor:bt,options:{}}],Wt={current:{}},Ht={draggable:{measure:Ke},droppable:{measure:Ke,strategy:It.WhileDragging,frequency:Nt.Optimized},dragOverlay:{measure:Xe}};class Yt 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,n;return null!=(t=null==(n=this.get(e))?void 0:n.node.current)?t:void 0}}const Xt={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new Yt,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:Ne},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:Ht,measureDroppableContainers:Ne,windowRect:null,measuringScheduled:!1},Kt={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:""},dispatch:Ne,draggableNodes:new Map,over:null,measureDroppableContainers:Ne},Vt=(0,v.createContext)(Kt),Gt=(0,v.createContext)(Xt);function Jt(){return{draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new Yt}}}function Zt(e,t){switch(t.type){case Ie.DragStart:return{...e,draggable:{...e.draggable,initialCoordinates:t.initialCoordinates,active:t.active}};case Ie.DragMove:return null==e.draggable.active?e:{...e,draggable:{...e.draggable,translate:{x:t.coordinates.x-e.draggable.initialCoordinates.x,y:t.coordinates.y-e.draggable.initialCoordinates.y}}};case Ie.DragEnd:case Ie.DragCancel:return{...e,draggable:{...e.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case Ie.RegisterDroppable:{const{element:n}=t,{id:r}=n,o=new Yt(e.droppable.containers);return o.set(r,n),{...e,droppable:{...e.droppable,containers:o}}}case Ie.SetDroppableDisabled:{const{id:n,key:r,disabled:o}=t,i=e.droppable.containers.get(n);if(!i||r!==i.key)return e;const a=new Yt(e.droppable.containers);return a.set(n,{...i,disabled:o}),{...e,droppable:{...e.droppable,containers:a}}}case Ie.UnregisterDroppable:{const{id:n,key:r}=t,o=e.droppable.containers.get(n);if(!o||r!==o.key)return e;const i=new Yt(e.droppable.containers);return i.delete(n),{...e,droppable:{...e.droppable,containers:i}}}default:return e}}function Qt(e){let{disabled:t}=e;const{active:n,activatorEvent:r,draggableNodes:o}=(0,v.useContext)(Vt),i=he(r),a=he(null==n?void 0:n.id);return(0,v.useEffect)(()=>{if(!t&&!r&&i&&null!=a){if(!we(i))return;if(document.activeElement===i.target)return;const e=o.get(a);if(!e)return;const{activatorNode:t,node:n}=e;if(!t.current&&!n.current)return;requestAnimationFrame(()=>{for(const e of[t.current,n.current]){if(!e)continue;const t=Re(e);if(t){t.focus();break}}})}},[r,t,o,a,i]),null}const en=(0,v.createContext)({...Le,scaleX:1,scaleY:1});var tn;!function(e){e[e.Uninitialized=0]="Uninitialized",e[e.Initializing=1]="Initializing",e[e.Initialized=2]="Initialized"}(tn||(tn={}));const nn=(0,v.memo)(function(e){var t,n,r,o;let{id:i,accessibility:a,autoScroll:s=!0,children:l,sensors:c=Bt,collisionDetection:u=qe,measuring:d,modifiers:f,...p}=e;const h=(0,v.useReducer)(Zt,void 0,Jt),[g,b]=h,[y,w]=function(){const[e]=(0,v.useState)(()=>new Set),t=(0,v.useCallback)(t=>(e.add(t),()=>e.delete(t)),[e]),n=(0,v.useCallback)(t=>{let{type:n,event:r}=t;e.forEach(e=>{var t;return null==(t=e[n])?void 0:t.call(e,r)})},[e]);return[n,t]}(),[x,C]=(0,v.useState)(tn.Uninitialized),S=x===tn.Initialized,{draggable:{active:R,nodes:E,translate:k},droppable:{containers:D}}=g,A=null!=R?E.get(R):null,O=(0,v.useRef)({initial:null,translated:null}),M=(0,v.useMemo)(()=>{var e;return null!=R?{id:R,data:null!=(e=null==A?void 0:A.data)?e:Wt,rect:O}:null},[R,A]),T=(0,v.useRef)(null),[I,N]=(0,v.useState)(null),[_,L]=(0,v.useState)(null),P=de(p,Object.values(p)),$=ve("DndDescribedBy",i),j=(0,v.useMemo)(()=>D.getEnabled(),[D]),F=(z=d,(0,v.useMemo)(()=>({draggable:{...Ht.draggable,...null==z?void 0:z.draggable},droppable:{...Ht.droppable,...null==z?void 0:z.droppable},dragOverlay:{...Ht.dragOverlay,...null==z?void 0:z.dragOverlay}}),[null==z?void 0:z.draggable,null==z?void 0:z.droppable,null==z?void 0:z.dragOverlay]));var z;const{droppableRects:U,measureDroppableContainers:q,measuringScheduled:B}=function(e,t){let{dragging:n,dependencies:r,config:o}=t;const[i,a]=(0,v.useState)(null),{frequency:s,measure:l,strategy:c}=o,u=(0,v.useRef)(e),d=function(){switch(c){case It.Always:return!1;case It.BeforeDragging:return n;default:return!n}}(),f=de(d),p=(0,v.useCallback)(function(e){void 0===e&&(e=[]),f.current||a(t=>null===t?e:t.concat(e.filter(e=>!t.includes(e))))},[f]),h=(0,v.useRef)(null),g=fe(t=>{if(d&&!n)return _t;if(!t||t===_t||u.current!==e||null!=i){const t=new Map;for(let n of e){if(!n)continue;if(i&&i.length>0&&!i.includes(n.id)&&n.rect.current){t.set(n.id,n.rect.current);continue}const e=n.node.current,r=e?new ct(l(e),e):null;n.rect.current=r,r&&t.set(n.id,r)}return t}return t},[e,i,n,d,l]);return(0,v.useEffect)(()=>{u.current=e},[e]),(0,v.useEffect)(()=>{d||p()},[n,d]),(0,v.useEffect)(()=>{i&&i.length>0&&a(null)},[JSON.stringify(i)]),(0,v.useEffect)(()=>{d||"number"!=typeof s||null!==h.current||(h.current=setTimeout(()=>{p(),h.current=null},s))},[s,d,p,...r]),{droppableRects:g,measureDroppableContainers:p,measuringScheduled:null!=i}}(j,{dragging:S,dependencies:[k.x,k.y],config:F.droppable}),W=function(e,t){const n=null!=t?e.get(t):void 0,r=n?n.node.current:null;return fe(e=>{var n;return null==t?null:null!=(n=null!=r?r:e)?n:null},[r,t])}(E,R),H=(0,v.useMemo)(()=>_?xe(_):null,[_]),Y=function(){const e=!1===(null==I?void 0:I.autoScrollEnabled),t="object"==typeof s?!1===s.enabled:!1===s,n=S&&!e&&!t;return"object"==typeof s?{...s,enabled:n}:{enabled:n}}(),X=function(e,t){return Lt(e,t)}(W,F.draggable.measure);!function(e){let{activeNode:t,measure:n,initialRect:r,config:o=!0}=e;const i=(0,v.useRef)(!1),{x:a,y:s}="boolean"==typeof o?{x:o,y:o}:o;ce(()=>{if(!a&&!s||!t)return void(i.current=!1);if(i.current||!r)return;const e=null==t?void 0:t.node.current;if(!e||!1===e.isConnected)return;const o=Be(n(e),r);if(a||(o.x=0),s||(o.y=0),i.current=!0,Math.abs(o.x)>0||Math.abs(o.y)>0){const t=Ge(e);t&&t.scrollBy({top:o.y,left:o.x})}},[t,a,s,r,n])}({activeNode:null!=R?E.get(R):null,config:Y.layoutShiftCompensation,initialRect:X,measure:F.draggable.measure});const K=jt(W,F.draggable.measure,X),V=jt(W?W.parentElement:null),G=(0,v.useRef)({activatorEvent:null,active:null,activeNode:W,collisionRect:null,collisions:null,droppableRects:U,draggableNodes:E,draggingNode:null,draggingNodeRect:null,droppableContainers:D,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),J=D.getNodeFor(null==(t=G.current.over)?void 0:t.id),Z=function(e){let{measure:t}=e;const[n,r]=(0,v.useState)(null),o=Pt({callback:(0,v.useCallback)(e=>{for(const{target:n}of e)if(ae(n)){r(e=>{const r=t(n);return e?{...e,width:r.width,height:r.height}:r});break}},[t])}),i=(0,v.useCallback)(e=>{const n=function(e){if(!e)return null;if(e.children.length>1)return e;const t=e.children[0];return ae(t)?t:e}(e);null==o||o.disconnect(),n&&(null==o||o.observe(n)),r(n?t(n):null)},[t,o]),[a,s]=pe(i);return(0,v.useMemo)(()=>({nodeRef:a,rect:n,setRef:s}),[n,a,s])}({measure:F.dragOverlay.measure}),Q=null!=(n=Z.nodeRef.current)?n:W,ne=S?null!=(r=Z.rect)?r:K:null,re=Boolean(Z.nodeRef.current&&Z.rect),ie=Be(se=re?null:K,Lt(se));var se;const le=Ut(Q?oe(Q):null),ue=function(e){const t=(0,v.useRef)(e),n=fe(n=>e?n&&n!==Ft&&e&&t.current&&e.parentNode===t.current.parentNode?n:Ve(e):Ft,[e]);return(0,v.useEffect)(()=>{t.current=e},[e]),n}(S?null!=J?J:W:null),ge=function(e,t){void 0===t&&(t=Xe);const[n]=e,r=Ut(n?oe(n):null),[o,i]=(0,v.useState)(qt);function a(){i(()=>e.length?e.map(e=>nt(e)?r:new ct(t(e),e)):qt)}const s=Pt({callback:a});return ce(()=>{null==s||s.disconnect(),a(),e.forEach(e=>null==s?void 0:s.observe(e))},[e]),o}(ue),me=function(e,t){let{transform:n,...r}=t;return null!=e&&e.length?e.reduce((e,t)=>t({transform:e,...r}),n):n}(f,{transform:{x:k.x-ie.x,y:k.y-ie.y,scaleX:1,scaleY:1},activatorEvent:_,active:M,activeNodeRect:K,containerNodeRect:V,draggingNodeRect:ne,over:G.current.over,overlayNodeRect:Z.rect,scrollableAncestors:ue,scrollableAncestorRects:ge,windowRect:le}),ye=H?be(H,k):null,we=function(e){const[t,n]=(0,v.useState)(null),r=(0,v.useRef)(e),o=(0,v.useCallback)(e=>{const t=Je(e.target);t&&n(e=>e?(e.set(t,et(t)),new Map(e)):null)},[]);return(0,v.useEffect)(()=>{const t=r.current;if(e!==t){i(t);const a=e.map(e=>{const t=Je(e);return t?(t.addEventListener("scroll",o,{passive:!0}),[t,et(t)]):null}).filter(e=>null!=e);n(a.length?new Map(a):null),r.current=e}return()=>{i(e),i(t)};function i(e){e.forEach(e=>{const t=Je(e);null==t||t.removeEventListener("scroll",o)})}},[o,e]),(0,v.useMemo)(()=>e.length?t?Array.from(t.values()).reduce((e,t)=>be(e,t),Le):st(e):Le,[e,t])}(ue),Ce=zt(we),Se=zt(we,[K]),Re=be(me,Ce),Ee=ne?He(ne,me):null,ke=M&&Ee?u({active:M,collisionRect:Ee,droppableRects:U,droppableContainers:j,pointerCoordinates:ye}):null,De=function(e){if(!e||0===e.length)return null;const[t]=e;return t.id}(ke),[Oe,Me]=(0,v.useState)(null),Ne=function(e,t,n){return{...e,scaleX:t&&n?t.width/n.width:1,scaleY:t&&n?t.height/n.height:1}}(re?me:be(me,Se),null!=(o=null==Oe?void 0:Oe.rect)?o:null,K),_e=(0,v.useRef)(null),Pe=(0,v.useCallback)((e,t)=>{let{sensor:n,options:r}=t;if(null==T.current)return;const o=E.get(T.current);if(!o)return;const i=e.nativeEvent,a=new n({active:T.current,activeNode:o,event:i,options:r,context:G,onAbort(e){if(!E.get(e))return;const{onDragAbort:t}=P.current,n={id:e};null==t||t(n),y({type:"onDragAbort",event:n})},onPending(e,t,n,r){if(!E.get(e))return;const{onDragPending:o}=P.current,i={id:e,constraint:t,initialCoordinates:n,offset:r};null==o||o(i),y({type:"onDragPending",event:i})},onStart(e){const t=T.current;if(null==t)return;const n=E.get(t);if(!n)return;const{onDragStart:r}=P.current,o={activatorEvent:i,active:{id:t,data:n.data,rect:O}};(0,ee.unstable_batchedUpdates)(()=>{null==r||r(o),C(tn.Initializing),b({type:Ie.DragStart,initialCoordinates:e,active:t}),y({type:"onDragStart",event:o}),N(_e.current),L(i)})},onMove(e){b({type:Ie.DragMove,coordinates:e})},onEnd:s(Ie.DragEnd),onCancel:s(Ie.DragCancel)});function s(e){return async function(){const{active:t,collisions:n,over:r,scrollAdjustedTranslate:o}=G.current;let a=null;if(t&&o){const{cancelDrop:s}=P.current;a={activatorEvent:i,active:t,collisions:n,delta:o,over:r},e===Ie.DragEnd&&"function"==typeof s&&await Promise.resolve(s(a))&&(e=Ie.DragCancel)}T.current=null,(0,ee.unstable_batchedUpdates)(()=>{b({type:e}),C(tn.Uninitialized),Me(null),N(null),L(null),_e.current=null;const t=e===Ie.DragEnd?"onDragEnd":"onDragCancel";if(a){const e=P.current[t];null==e||e(a),y({type:t,event:a})}})}}_e.current=a},[E]),$e=(0,v.useCallback)((e,t)=>(n,r)=>{const o=n.nativeEvent,i=E.get(r);if(null!==T.current||!i||o.dndKit||o.defaultPrevented)return;const a={active:i};!0===e(n,t.options,a)&&(o.dndKit={capturedBy:t.sensor},T.current=r,Pe(n,t))},[E,Pe]),je=function(e,t){return(0,v.useMemo)(()=>e.reduce((e,n)=>{const{sensor:r}=n;return[...e,...r.activators.map(e=>({eventName:e.eventName,handler:t(e.handler,n)}))]},[]),[e,t])}(c,$e);!function(e){(0,v.useEffect)(()=>{if(!te)return;const t=e.map(e=>{let{sensor:t}=e;return null==t.setup?void 0:t.setup()});return()=>{for(const e of t)null==e||e()}},e.map(e=>{let{sensor:t}=e;return t}))}(c),ce(()=>{K&&x===tn.Initializing&&C(tn.Initialized)},[K,x]),(0,v.useEffect)(()=>{const{onDragMove:e}=P.current,{active:t,activatorEvent:n,collisions:r,over:o}=G.current;if(!t||!n)return;const i={active:t,activatorEvent:n,collisions:r,delta:{x:Re.x,y:Re.y},over:o};(0,ee.unstable_batchedUpdates)(()=>{null==e||e(i),y({type:"onDragMove",event:i})})},[Re.x,Re.y]),(0,v.useEffect)(()=>{const{active:e,activatorEvent:t,collisions:n,droppableContainers:r,scrollAdjustedTranslate:o}=G.current;if(!e||null==T.current||!t||!o)return;const{onDragOver:i}=P.current,a=r.get(De),s=a&&a.rect.current?{id:a.id,rect:a.rect.current,data:a.data,disabled:a.disabled}:null,l={active:e,activatorEvent:t,collisions:n,delta:{x:o.x,y:o.y},over:s};(0,ee.unstable_batchedUpdates)(()=>{Me(s),null==i||i(l),y({type:"onDragOver",event:l})})},[De]),ce(()=>{G.current={activatorEvent:_,active:M,activeNode:W,collisionRect:Ee,collisions:ke,droppableRects:U,draggableNodes:E,draggingNode:Q,draggingNodeRect:ne,droppableContainers:D,over:Oe,scrollableAncestors:ue,scrollAdjustedTranslate:Re},O.current={initial:ne,translated:Ee}},[M,W,ke,Ee,E,Q,ne,U,D,Oe,ue,Re]),function(e){let{acceleration:t,activator:n=Ot.Pointer,canScroll:r,draggingRect:o,enabled:i,interval:a=5,order:s=Mt.TreeOrder,pointerCoordinates:l,scrollableAncestors:c,scrollableAncestorRects:u,delta:d,threshold:f}=e;const p=function(e){let{delta:t,disabled:n}=e;const r=he(t);return fe(e=>{if(n||!r||!e)return Tt;const o=Math.sign(t.x-r.x),i=Math.sign(t.y-r.y);return{x:{[tt.Backward]:e.x[tt.Backward]||-1===o,[tt.Forward]:e.x[tt.Forward]||1===o},y:{[tt.Backward]:e.y[tt.Backward]||-1===i,[tt.Forward]:e.y[tt.Forward]||1===i}}},[n,t,r])}({delta:d,disabled:!i}),[h,g]=function(){const e=(0,v.useRef)(null);return[(0,v.useCallback)((t,n)=>{e.current=setInterval(t,n)},[]),(0,v.useCallback)(()=>{null!==e.current&&(clearInterval(e.current),e.current=null)},[])]}(),m=(0,v.useRef)({x:0,y:0}),b=(0,v.useRef)({x:0,y:0}),y=(0,v.useMemo)(()=>{switch(n){case Ot.Pointer:return l?{top:l.y,bottom:l.y,left:l.x,right:l.x}:null;case Ot.DraggableRect:return o}},[n,o,l]),w=(0,v.useRef)(null),x=(0,v.useCallback)(()=>{const e=w.current;if(!e)return;const t=m.current.x*b.current.x,n=m.current.y*b.current.y;e.scrollBy(t,n)},[]),C=(0,v.useMemo)(()=>s===Mt.TreeOrder?[...c].reverse():c,[s,c]);(0,v.useEffect)(()=>{if(i&&c.length&&y){for(const e of C){if(!1===(null==r?void 0:r(e)))continue;const n=c.indexOf(e),o=u[n];if(!o)continue;const{direction:i,speed:s}=it(e,o,y,t,f);for(const e of["x","y"])p[e][i[e]]||(s[e]=0,i[e]=0);if(s.x>0||s.y>0)return g(),w.current=e,h(x,a),m.current=s,void(b.current=i)}m.current={x:0,y:0},b.current={x:0,y:0},g()}else g()},[t,x,r,g,i,a,JSON.stringify(y),JSON.stringify(p),h,c,C,u,JSON.stringify(f)])}({...Y,delta:k,draggingRect:Ee,pointerCoordinates:ye,scrollableAncestors:ue,scrollableAncestorRects:ge});const Fe=(0,v.useMemo)(()=>({active:M,activeNode:W,activeNodeRect:K,activatorEvent:_,collisions:ke,containerNodeRect:V,dragOverlay:Z,draggableNodes:E,droppableContainers:D,droppableRects:U,over:Oe,measureDroppableContainers:q,scrollableAncestors:ue,scrollableAncestorRects:ge,measuringConfiguration:F,measuringScheduled:B,windowRect:le}),[M,W,K,_,ke,V,Z,E,D,U,Oe,q,ue,ge,F,B,le]),ze=(0,v.useMemo)(()=>({activatorEvent:_,activators:je,active:M,activeNodeRect:K,ariaDescribedById:{draggable:$},dispatch:b,draggableNodes:E,over:Oe,measureDroppableContainers:q}),[_,je,M,K,b,$,E,Oe,q]);return m().createElement(Ae.Provider,{value:w},m().createElement(Vt.Provider,{value:ze},m().createElement(Gt.Provider,{value:Fe},m().createElement(en.Provider,{value:Ne},l)),m().createElement(Qt,{disabled:!1===(null==a?void 0:a.restoreFocus)})),m().createElement(Te,{...a,hiddenTextDescribedById:$}))}),rn=(0,v.createContext)(null),on="button";const an={timeout:25};function sn(e,t,n){const r=e.slice();return r.splice(n<0?r.length+n:n,0,r.splice(t,1)[0]),r}function ln(e,t){return e.reduce((e,n,r)=>{const o=t.get(n);return o&&(e[r]=o),e},Array(e.length))}function cn(e){return null!==e&&e>=0}const un=e=>{let{rects:t,activeIndex:n,overIndex:r,index:o}=e;const i=sn(t,r,n),a=t[o],s=i[o];return s&&a?{x:s.left-a.left,y:s.top-a.top,scaleX:s.width/a.width,scaleY:s.height/a.height}:null},dn="Sortable",fn=m().createContext({activeIndex:-1,containerId:dn,disableTransforms:!1,items:[],overIndex:-1,useDragOverlay:!1,sortedRects:[],strategy:un,disabled:{draggable:!1,droppable:!1}});function pn(e){let{children:t,id:n,items:r,strategy:o=un,disabled:i=!1}=e;const{active:a,dragOverlay:s,droppableRects:l,over:c,measureDroppableContainers:u}=(0,v.useContext)(Gt),d=ve(dn,n),f=Boolean(null!==s.rect),p=(0,v.useMemo)(()=>r.map(e=>"object"==typeof e&&"id"in e?e.id:e),[r]),h=null!=a,g=a?p.indexOf(a.id):-1,b=c?p.indexOf(c.id):-1,y=(0,v.useRef)(p),w=!function(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}(p,y.current),x=-1!==b&&-1===g||w,C=function(e){return"boolean"==typeof e?{draggable:e,droppable:e}:e}(i);ce(()=>{w&&h&&u(p)},[w,p,h,u]),(0,v.useEffect)(()=>{y.current=p},[p]);const S=(0,v.useMemo)(()=>({activeIndex:g,containerId:d,disabled:C,disableTransforms:x,items:p,overIndex:b,useDragOverlay:f,sortedRects:ln(p,l),strategy:o}),[g,d,C.draggable,C.droppable,x,p,b,l,f,o]);return m().createElement(fn.Provider,{value:S},t)}const hn=e=>{let{id:t,items:n,activeIndex:r,overIndex:o}=e;return sn(n,r,o).indexOf(t)},gn=e=>{let{containerId:t,isSorting:n,wasDragging:r,index:o,items:i,newIndex:a,previousItems:s,previousContainerId:l,transition:c}=e;return!(!c||!r||s!==i&&o===a||!n&&(a===o||t!==l))},vn={duration:200,easing:"ease"},mn="transform",bn=Ce.Transition.toString({property:mn,duration:0,easing:"linear"}),yn={roleDescription:"sortable"};function wn(e){let{animateLayoutChanges:t=gn,attributes:n,disabled:r,data:o,getNewIndex:i=hn,id:a,strategy:s,resizeObserverConfig:l,transition:c=vn}=e;const{items:u,containerId:d,activeIndex:f,disabled:p,disableTransforms:h,sortedRects:g,overIndex:m,useDragOverlay:b,strategy:y}=(0,v.useContext)(fn),w=function(e,t){var n,r;return"boolean"==typeof e?{draggable:e,droppable:!1}:{draggable:null!=(n=null==e?void 0:e.draggable)?n:t.draggable,droppable:null!=(r=null==e?void 0:e.droppable)?r:t.droppable}}(r,p),x=u.indexOf(a),C=(0,v.useMemo)(()=>({sortable:{containerId:d,index:x,items:u},...o}),[d,o,x,u]),S=(0,v.useMemo)(()=>u.slice(u.indexOf(a)),[u,a]),{rect:R,node:E,isOver:k,setNodeRef:D}=function(e){let{data:t,disabled:n=!1,id:r,resizeObserverConfig:o}=e;const i=ve("Droppable"),{active:a,dispatch:s,over:l,measureDroppableContainers:c}=(0,v.useContext)(Vt),u=(0,v.useRef)({disabled:n}),d=(0,v.useRef)(!1),f=(0,v.useRef)(null),p=(0,v.useRef)(null),{disabled:h,updateMeasurementsFor:g,timeout:m}={...an,...o},b=de(null!=g?g:r),y=Pt({callback:(0,v.useCallback)(()=>{d.current?(null!=p.current&&clearTimeout(p.current),p.current=setTimeout(()=>{c(Array.isArray(b.current)?b.current:[b.current]),p.current=null},m)):d.current=!0},[m]),disabled:h||!a}),w=(0,v.useCallback)((e,t)=>{y&&(t&&(y.unobserve(t),d.current=!1),e&&y.observe(e))},[y]),[x,C]=pe(w),S=de(t);return(0,v.useEffect)(()=>{y&&x.current&&(y.disconnect(),d.current=!1,y.observe(x.current))},[x,y]),(0,v.useEffect)(()=>(s({type:Ie.RegisterDroppable,element:{id:r,key:i,disabled:n,node:x,rect:f,data:S}}),()=>s({type:Ie.UnregisterDroppable,key:i,id:r})),[r]),(0,v.useEffect)(()=>{n!==u.current.disabled&&(s({type:Ie.SetDroppableDisabled,id:r,key:i,disabled:n}),u.current.disabled=n)},[r,i,n,s]),{active:a,rect:f,isOver:(null==l?void 0:l.id)===r,node:x,over:l,setNodeRef:C}}({id:a,data:C,disabled:w.droppable,resizeObserverConfig:{updateMeasurementsFor:S,...l}}),{active:A,activatorEvent:O,activeNodeRect:M,attributes:T,setNodeRef:I,listeners:N,isDragging:_,over:L,setActivatorNodeRef:P,transform:$}=function(e){let{id:t,data:n,disabled:r=!1,attributes:o}=e;const i=ve("Draggable"),{activators:a,activatorEvent:s,active:l,activeNodeRect:c,ariaDescribedById:u,draggableNodes:d,over:f}=(0,v.useContext)(Vt),{role:p=on,roleDescription:h="draggable",tabIndex:g=0}=null!=o?o:{},m=(null==l?void 0:l.id)===t,b=(0,v.useContext)(m?en:rn),[y,w]=pe(),[x,C]=pe(),S=function(e,t){return(0,v.useMemo)(()=>e.reduce((e,n)=>{let{eventName:r,handler:o}=n;return e[r]=e=>{o(e,t)},e},{}),[e,t])}(a,t),R=de(n);return ce(()=>(d.set(t,{id:t,key:i,node:y,activatorNode:x,data:R}),()=>{const e=d.get(t);e&&e.key===i&&d.delete(t)}),[d,t]),{active:l,activatorEvent:s,activeNodeRect:c,attributes:(0,v.useMemo)(()=>({role:p,tabIndex:g,"aria-disabled":r,"aria-pressed":!(!m||p!==on)||void 0,"aria-roledescription":h,"aria-describedby":u.draggable}),[r,p,g,m,h,u.draggable]),isDragging:m,listeners:r?void 0:S,node:y,over:f,setNodeRef:w,setActivatorNodeRef:C,transform:b}}({id:a,data:C,attributes:{...yn,...n},disabled:w.draggable}),j=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,v.useMemo)(()=>e=>{t.forEach(t=>t(e))},t)}(D,I),F=Boolean(A),z=F&&!h&&cn(f)&&cn(m),U=!b&&_,q=U&&z?$:null,B=z?null!=q?q:(null!=s?s:y)({rects:g,activeNodeRect:M,activeIndex:f,overIndex:m,index:x}):null,W=cn(f)&&cn(m)?i({id:a,items:u,activeIndex:f,overIndex:m}):x,H=null==A?void 0:A.id,Y=(0,v.useRef)({activeId:H,items:u,newIndex:W,containerId:d}),X=u!==Y.current.items,K=t({active:A,containerId:d,isDragging:_,isSorting:F,id:a,index:x,items:u,newIndex:Y.current.newIndex,previousItems:Y.current.items,previousContainerId:Y.current.containerId,transition:c,wasDragging:null!=Y.current.activeId}),V=function(e){let{disabled:t,index:n,node:r,rect:o}=e;const[i,a]=(0,v.useState)(null),s=(0,v.useRef)(n);return ce(()=>{if(!t&&n!==s.current&&r.current){const e=o.current;if(e){const t=Xe(r.current,{ignoreTransform:!0}),n={x:e.left-t.left,y:e.top-t.top,scaleX:e.width/t.width,scaleY:e.height/t.height};(n.x||n.y)&&a(n)}}n!==s.current&&(s.current=n)},[t,n,r,o]),(0,v.useEffect)(()=>{i&&a(null)},[i]),i}({disabled:!K,index:x,node:E,rect:R});return(0,v.useEffect)(()=>{F&&Y.current.newIndex!==W&&(Y.current.newIndex=W),d!==Y.current.containerId&&(Y.current.containerId=d),u!==Y.current.items&&(Y.current.items=u)},[F,W,d,u]),(0,v.useEffect)(()=>{if(H===Y.current.activeId)return;if(H&&!Y.current.activeId)return void(Y.current.activeId=H);const e=setTimeout(()=>{Y.current.activeId=H},50);return()=>clearTimeout(e)},[H]),{active:A,activeIndex:f,attributes:T,data:C,rect:R,index:x,newIndex:W,items:u,isOver:k,isSorting:F,isDragging:_,listeners:N,node:E,overIndex:m,over:L,setNodeRef:j,setActivatorNodeRef:P,setDroppableNodeRef:D,setDraggableNodeRef:I,transform:null!=V?V:B,transition:V||X&&Y.current.newIndex===x?bn:U&&!we(O)||!c?void 0:F||K?Ce.Transition.toString({...c,property:mn}):void 0}}pt.Down,pt.Right,pt.Up,pt.Left;const xn=e=>{let{containerNodeRect:t,draggingNodeRect:n,transform:r}=e;return n&&t?function(e,t,n){const r={...e};return t.top+e.y<=n.top?r.y=n.top-t.top:t.bottom+e.y>=n.top+n.height&&(r.y=n.top+n.height-t.bottom),t.left+e.x<=n.left?r.x=n.left-t.left:t.right+e.x>=n.left+n.width&&(r.x=n.left+n.width-t.right),r}(r,n,t):r};var Cn=l(85),Sn=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(t);try{n.insertRule(e,n.cssRules.length)}catch(e){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach(function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)}),this.tags=[],this.ctr=0},e}(),Rn=Math.abs,En=String.fromCharCode,kn=Object.assign;function Dn(e){return e.trim()}function An(e,t,n){return e.replace(t,n)}function On(e,t){return e.indexOf(t)}function Mn(e,t){return 0|e.charCodeAt(t)}function Tn(e,t,n){return e.slice(t,n)}function In(e){return e.length}function Nn(e){return e.length}function _n(e,t){return t.push(e),e}var Ln=1,Pn=1,$n=0,jn=0,Fn=0,zn="";function Un(e,t,n,r,o,i,a){return{value:e,root:t,parent:n,type:r,props:o,children:i,line:Ln,column:Pn,length:a,return:""}}function qn(e,t){return kn(Un("",null,null,"",null,null,0),e,{length:-e.length},t)}function Bn(){return Fn=jn>0?Mn(zn,--jn):0,Pn--,10===Fn&&(Pn=1,Ln--),Fn}function Wn(){return Fn=jn<$n?Mn(zn,jn++):0,Pn++,10===Fn&&(Pn=1,Ln++),Fn}function Hn(){return Mn(zn,jn)}function Yn(){return jn}function Xn(e,t){return Tn(zn,e,t)}function Kn(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function Vn(e){return Ln=Pn=1,$n=In(zn=e),jn=0,[]}function Gn(e){return zn="",e}function Jn(e){return Dn(Xn(jn-1,er(91===e?e+2:40===e?e+1:e)))}function Zn(e){for(;(Fn=Hn())&&Fn<33;)Wn();return Kn(e)>2||Kn(Fn)>3?"":" "}function Qn(e,t){for(;--t&&Wn()&&!(Fn<48||Fn>102||Fn>57&&Fn<65||Fn>70&&Fn<97););return Xn(e,Yn()+(t<6&&32==Hn()&&32==Wn()))}function er(e){for(;Wn();)switch(Fn){case e:return jn;case 34:case 39:34!==e&&39!==e&&er(Fn);break;case 40:41===e&&er(e);break;case 92:Wn()}return jn}function tr(e,t){for(;Wn()&&e+Fn!==57&&(e+Fn!==84||47!==Hn()););return"/*"+Xn(t,jn-1)+"*"+En(47===e?e:Wn())}function nr(e){for(;!Kn(Hn());)Wn();return Xn(e,jn)}var rr="-ms-",or="-moz-",ir="-webkit-",ar="comm",sr="rule",lr="decl",cr="@keyframes";function ur(e,t){for(var n="",r=Nn(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function dr(e,t,n,r){switch(e.type){case"@layer":if(e.children.length)break;case"@import":case lr:return e.return=e.return||e.value;case ar:return"";case cr:return e.return=e.value+"{"+ur(e.children,r)+"}";case sr:e.value=e.props.join(",")}return In(n=ur(e.children,r))?e.return=e.value+"{"+n+"}":""}function fr(e){return Gn(pr("",null,null,null,[""],e=Vn(e),0,[0],e))}function pr(e,t,n,r,o,i,a,s,l){for(var c=0,u=0,d=a,f=0,p=0,h=0,g=1,v=1,m=1,b=0,y="",w=o,x=i,C=r,S=y;v;)switch(h=b,b=Wn()){case 40:if(108!=h&&58==Mn(S,d-1)){-1!=On(S+=An(Jn(b),"&","&\f"),"&\f")&&(m=-1);break}case 34:case 39:case 91:S+=Jn(b);break;case 9:case 10:case 13:case 32:S+=Zn(h);break;case 92:S+=Qn(Yn()-1,7);continue;case 47:switch(Hn()){case 42:case 47:_n(gr(tr(Wn(),Yn()),t,n),l);break;default:S+="/"}break;case 123*g:s[c++]=In(S)*m;case 125*g:case 59:case 0:switch(b){case 0:case 125:v=0;case 59+u:-1==m&&(S=An(S,/\f/g,"")),p>0&&In(S)-d&&_n(p>32?vr(S+";",r,n,d-1):vr(An(S," ","")+";",r,n,d-2),l);break;case 59:S+=";";default:if(_n(C=hr(S,t,n,c,u,o,s,y,w=[],x=[],d),i),123===b)if(0===u)pr(S,t,C,C,w,i,d,s,x);else switch(99===f&&110===Mn(S,3)?100:f){case 100:case 108:case 109:case 115:pr(e,C,C,r&&_n(hr(e,C,C,0,0,o,s,y,o,w=[],d),x),o,x,d,s,r?w:x);break;default:pr(S,C,C,C,[""],x,0,s,x)}}c=u=p=0,g=m=1,y=S="",d=a;break;case 58:d=1+In(S),p=h;default:if(g<1)if(123==b)--g;else if(125==b&&0==g++&&125==Bn())continue;switch(S+=En(b),b*g){case 38:m=u>0?1:(S+="\f",-1);break;case 44:s[c++]=(In(S)-1)*m,m=1;break;case 64:45===Hn()&&(S+=Jn(Wn())),f=Hn(),u=d=In(y=S+=nr(Yn())),b++;break;case 45:45===h&&2==In(S)&&(g=0)}}return i}function hr(e,t,n,r,o,i,a,s,l,c,u){for(var d=o-1,f=0===o?i:[""],p=Nn(f),h=0,g=0,v=0;h<r;++h)for(var m=0,b=Tn(e,d+1,d=Rn(g=a[h])),y=e;m<p;++m)(y=Dn(g>0?f[m]+" "+b:An(b,/&\f/g,f[m])))&&(l[v++]=y);return Un(e,t,n,0===o?sr:s,l,c,u)}function gr(e,t,n){return Un(e,t,n,ar,En(Fn),Tn(e,2,-2),0)}function vr(e,t,n,r){return Un(e,t,n,lr,Tn(e,0,r),Tn(e,r+1,-1),r)}var mr=function(e,t,n){for(var r=0,o=0;r=o,o=Hn(),38===r&&12===o&&(t[n]=1),!Kn(o);)Wn();return Xn(e,jn)},br=new WeakMap,yr=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||br.get(n))&&!r){br.set(e,!0);for(var o=[],i=function(e,t){return Gn(function(e,t){var n=-1,r=44;do{switch(Kn(r)){case 0:38===r&&12===Hn()&&(t[n]=1),e[n]+=mr(jn-1,t,n);break;case 2:e[n]+=Jn(r);break;case 4:if(44===r){e[++n]=58===Hn()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=En(r)}}while(r=Wn());return e}(Vn(e),t))}(t,o),a=n.props,s=0,l=0;s<i.length;s++)for(var c=0;c<a.length;c++,l++)e.props[l]=o[s]?i[s].replace(/&\f/g,a[c]):a[c]+" "+i[s]}}},wr=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function xr(e,t){switch(function(e,t){return 45^Mn(e,0)?(((t<<2^Mn(e,0))<<2^Mn(e,1))<<2^Mn(e,2))<<2^Mn(e,3):0}(e,t)){case 5103:return ir+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return ir+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return ir+e+or+e+rr+e+e;case 6828:case 4268:return ir+e+rr+e+e;case 6165:return ir+e+rr+"flex-"+e+e;case 5187:return ir+e+An(e,/(\w+).+(:[^]+)/,ir+"box-$1$2"+rr+"flex-$1$2")+e;case 5443:return ir+e+rr+"flex-item-"+An(e,/flex-|-self/,"")+e;case 4675:return ir+e+rr+"flex-line-pack"+An(e,/align-content|flex-|-self/,"")+e;case 5548:return ir+e+rr+An(e,"shrink","negative")+e;case 5292:return ir+e+rr+An(e,"basis","preferred-size")+e;case 6060:return ir+"box-"+An(e,"-grow","")+ir+e+rr+An(e,"grow","positive")+e;case 4554:return ir+An(e,/([^-])(transform)/g,"$1"+ir+"$2")+e;case 6187:return An(An(An(e,/(zoom-|grab)/,ir+"$1"),/(image-set)/,ir+"$1"),e,"")+e;case 5495:case 3959:return An(e,/(image-set\([^]*)/,ir+"$1$`$1");case 4968:return An(An(e,/(.+:)(flex-)?(.*)/,ir+"box-pack:$3"+rr+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+ir+e+e;case 4095:case 3583:case 4068:case 2532:return An(e,/(.+)-inline(.+)/,ir+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(In(e)-1-t>6)switch(Mn(e,t+1)){case 109:if(45!==Mn(e,t+4))break;case 102:return An(e,/(.+:)(.+)-([^]+)/,"$1"+ir+"$2-$3$1"+or+(108==Mn(e,t+3)?"$3":"$2-$3"))+e;case 115:return~On(e,"stretch")?xr(An(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==Mn(e,t+1))break;case 6444:switch(Mn(e,In(e)-3-(~On(e,"!important")&&10))){case 107:return An(e,":",":"+ir)+e;case 101:return An(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+ir+(45===Mn(e,14)?"inline-":"")+"box$3$1"+ir+"$2$3$1"+rr+"$2box$3")+e}break;case 5936:switch(Mn(e,t+11)){case 114:return ir+e+rr+An(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return ir+e+rr+An(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return ir+e+rr+An(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return ir+e+rr+e+e}return e}var Cr=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case lr:e.return=xr(e.value,e.length);break;case cr:return ur([qn(e,{value:An(e.value,"@","@"+ir)})],r);case sr:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,function(t){switch(function(e){return(e=/(::plac\w+|:read-\w+)/.exec(e))?e[0]:e}(t)){case":read-only":case":read-write":return ur([qn(e,{props:[An(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return ur([qn(e,{props:[An(t,/:(plac\w+)/,":"+ir+"input-$1")]}),qn(e,{props:[An(t,/:(plac\w+)/,":-moz-$1")]}),qn(e,{props:[An(t,/:(plac\w+)/,rr+"input-$1")]})],r)}return""})}}],Sr=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))})}var r,o,i=e.stylisPlugins||Cr,a={},s=[];r=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n<t.length;n++)a[t[n]]=!0;s.push(e)});var l,c,u,d,f=[dr,(d=function(e){l.insert(e)},function(e){e.root||(e=e.return)&&d(e)})],p=(c=[yr,wr].concat(i,f),u=Nn(c),function(e,t,n,r){for(var o="",i=0;i<u;i++)o+=c[i](e,t,n,r)||"";return o});o=function(e,t,n,r){l=n,ur(fr(e?e+"{"+t.styles+"}":t.styles),p),r&&(h.inserted[t.name]=!0)};var h={key:t,sheet:new Sn({key:t,container:r,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:a,registered:{},insert:o};return h.sheet.hydrate(s),h},Rr=v.createContext("undefined"!=typeof HTMLElement?Sr({key:"css"}):null),Er=(Rr.Provider,function(e){return(0,v.forwardRef)(function(t,n){var r=(0,v.useContext)(Rr);return e(t,r,n)})}),kr=v.createContext({}),Dr={}.hasOwnProperty,Ar="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",Or=function(e,t){var n={};for(var r in t)Dr.call(t,r)&&(n[r]=t[r]);return n[Ar]=e,n},Mr=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return S(t,n,r),y(function(){return R(t,n,r)}),null},Tr=Er(function(e,t,n){var r=e.css;"string"==typeof r&&void 0!==t.registered[r]&&(r=t.registered[r]);var o=e[Ar],i=[r],a="";"string"==typeof e.className?a=w(t.registered,i,e.className):null!=e.className&&(a=e.className+" ");var s=g(i,void 0,v.useContext(kr));a+=t.key+"-"+s.name;var l={};for(var c in e)Dr.call(e,c)&&"css"!==c&&c!==Ar&&(l[c]=e[c]);return l.className=a,n&&(l.ref=n),v.createElement(v.Fragment,null,v.createElement(Mr,{cache:t,serialized:s,isStringTag:"string"==typeof o}),v.createElement(o,l))}),Ir=(l(985),Cn.Fragment),Nr=function(e,t,n){return Dr.call(t,"css")?Cn.jsx(Tr,Or(e,t),n):Cn.jsx(e,t,n)},_r=function(e,t,n){return Dr.call(t,"css")?Cn.jsxs(Tr,Or(e,t),n):Cn.jsxs(e,t,n)};const Lr=T("div",{target:"e1hax4ql7",label:"ImageWrapper"})("flex-basis:155px;width:155px;height:100px;margin-right:20px;margin-bottom:20px;border:",Z.borders.textField,";border-radius:",Z.lengths.borderRadius,";overflow:hidden;",Z.effects.checkerboard,";",Z.shadows.inset,";cursor:",e=>e.sortable?"pointer":"auto",";"),Pr=T("div",{target:"e1hax4ql6",label:"SortableImageButtonsWrapper"})({name:"1ekgmip",styles:"display:flex;justify-content:center;column-gap:10px;margin-right:20px;margin-top:-10px;margin-bottom:10px"}),$r=T("img",{target:"e1hax4ql5",label:"StyledImage"})({name:"ukfjzf",styles:"width:100%;height:100%;object-fit:contain"});function jr({value:e,field:t,getAsset:n}){const[r,o]=(0,v.useState)(null);return(0,v.useEffect)(()=>{if(e){const r=n(e,t);o(r)}else o(null)},[e,t,n]),r?Nr($r,{role:"presentation",src:r}):null}function Fr({onRemove:e,onReplace:t}){return _r(Pr,{children:[Nr(Z.IconButton,{size:"small",type:"media",onClick:t}),Nr(Z.IconButton,{size:"small",type:"close",onClick:e})]})}function zr(e){const{attributes:t,listeners:n,setNodeRef:r,transform:o,transition:i}=wn({id:e.id}),a={transform:Ce.Transform.toString(o),transition:i},{itemValue:s,getAsset:l,field:c,onRemove:u,onReplace:d}=e;return _r("div",{ref:r,style:a,...t,...n,children:[Nr(Lr,{sortable:!0,children:Nr(jr,{value:s,field:c,getAsset:l})}),Nr(Fr,{item:s,onRemove:u,onReplace:d})]})}var Ur={name:"a42x49-SortableMultiImageWrapper",styles:"display:flex;flex-wrap:wrap;label:SortableMultiImageWrapper;"};function qr({items:e,getAsset:t,field:n,onSortEnd:r,onRemoveOne:o,onReplaceOne:i}){const a={distance:4},s=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,v.useMemo)(()=>[...t].filter(e=>null!=e),[...t])}(_e(kt,{activationConstraint:a}),_e(At,{activationConstraint:a}));return Nr("div",{css:Ur,children:Nr(nn,{modifiers:[xn],collisionDetection:ze,sensors:s,onDragEnd:function({active:t,over:n}){r({oldIndex:e.findIndex(e=>e.id===t.id),newIndex:e.findIndex(e=>e.id===n.id)})},children:Nr(pn,{items:e,children:e.map((e,r)=>Nr(zr,{id:e.id,index:r,itemValue:e.value,getAsset:t,field:n,onRemove:o(r),onReplace:i(r)},e.id))})})})}const Br=T("a",{target:"e1hax4ql4",label:"FileLink"})({name:"7mbjrw",styles:"margin-bottom:20px;font-weight:normal;color:inherit;&:hover,&:active,&:focus{text-decoration:underline;}"}),Wr=T("div",{target:"e1hax4ql3",label:"FileLinks"})({name:"cn3xcj",styles:"margin-bottom:12px"}),Hr=T("ul",{target:"e1hax4ql2",label:"FileLinkList"})({name:"ffhm6p",styles:"list-style-type:none"}),Yr=T("button",{target:"e1hax4ql1",label:"FileWidgetButton"})(Z.buttons.button,";",Z.components.badge,";margin-bottom:12px;"),Xr=T("button",{target:"e1hax4ql0",label:"FileWidgetButtonRemove"})(Z.buttons.button,";",Z.components.badgeDanger,";");function Kr(e){return Array.isArray(e)||P.List.isList(e)}function Vr(e){return P.List.isList(e)?e.toArray():e??""}const Gr=j()(e=>console.warn(J`
3
3
  Decap CMS config: ${e.get("name")} field: property "options" has been deprecated for the
4
4
  ${e.get("widget")} widget and will be removed in the next major release. Rather than
5
5
  \`field.options.media_library\`, apply media library options for this widget under
6
6
  \`field.media_library\`.
7
- `));function Pn({forImage:e}={}){return class n extends v().Component{static propTypes={field:M().object.isRequired,getAsset:M().func.isRequired,mediaPaths:T().map.isRequired,onAddAsset:M().func.isRequired,onChange:M().func.isRequired,onRemoveInsertedMedia:M().func.isRequired,onOpenMediaLibrary:M().func.isRequired,onClearMediaControl:M().func.isRequired,onRemoveMediaControl:M().func.isRequired,classNameWrapper:M().string.isRequired,value:M().oneOfType([M().string,M().arrayOf(M().string),T().listOf(M().string)]),t:M().func.isRequired};static defaultProps={value:""};constructor(e){super(e),this.controlID=(0,_.v4)()}componentDidMount(){M().checkPropTypes(n.propTypes,this.props,"prop","FileControl")}shouldComponentUpdate(e){if(this.props.value!==e.value||this.props.getAsset!==e.getAsset)return!0;const t=e.mediaPaths.get(this.controlID);return!(!t||e.value===t)}componentDidUpdate(){const{mediaPaths:e,value:t,onRemoveInsertedMedia:n,onChange:r}=this.props,o=e.get(this.controlID);o&&o!==t?r(o):o&&o===t&&n(this.controlID)}componentWillUnmount(){this.props.onRemoveMediaControl(this.controlID)}handleChange=t=>{const{field:n,onOpenMediaLibrary:r,value:o}=this.props;t.preventDefault();const i=this.getMediaLibraryFieldOptions();return r({controlID:this.controlID,forImage:e,privateUpload:n.get("private"),value:Ln(o),allowMultiple:!!i.get("allow_multiple",!0),config:i.get("config"),field:n})};handleUrl=e=>t=>{t.preventDefault();const n=window.prompt(this.props.t(`editor.editorWidgets.${e}.promptUrl`));if(n)return this.props.onChange(n)};handleRemove=e=>(e.preventDefault(),this.props.onClearMediaControl(this.controlID),this.props.onChange(""));onRemoveOne=e=>()=>{const t=Ln(this.props.value);return t.splice(e,1),this.props.onChange(function(e){return Array.isArray(e)?e.length:j.List.isList(e)?e.size:e?1:0}(t)>0?[...t]:null)};onReplaceOne=t=>()=>{const{field:n,onOpenMediaLibrary:r,value:o}=this.props,i=this.getMediaLibraryFieldOptions();return r({controlID:this.controlID,forImage:e,privateUpload:n.get("private"),value:Ln(o),replaceIndex:t,allowMultiple:!1,config:i.get("config"),field:n})};getMediaLibraryFieldOptions=()=>{const{field:e}=this.props;return e.hasIn(["options","media_library"])?(_n(e),e.getIn(["options","media_library"],(0,j.Map)())):e.get("media_library",(0,j.Map)())};allowsMultiple=()=>{const e=this.getMediaLibraryFieldOptions();return e.get("config",!1)&&e.get("config").get("multiple",!1)};onSortEnd=({oldIndex:e,newIndex:t})=>{const{value:n}=this.props,r=(o=n,i=e,a=t,function(e,t,n){const r=t<0?e.length+t:t;if(r>=0&&r<e.length){const r=n<0?e.length+n:n,[o]=e.splice(t,1);e.splice(r,0,o)}}(o=[...o],i,a),o);var o,i,a;return this.props.onChange(r)};getValidateValue=()=>{const{value:e}=this.props;return e?Nn(e)?e.map(e=>J(e)):J(e):e};renderFileLink=e=>{if(!e||e.length<=50)return e;const n=`${e.slice(0,25)}…${e.slice(-24)}`;return(0,t.jsx)(On,{href:e,rel:"noopener",target:"_blank"},n)};renderFileLinks=()=>{const{value:e}=this.props;return Nn(e)?(0,t.jsx)(Mn,null,(0,t.jsx)(In,null,e.map(e=>(0,t.jsx)("li",{key:e},this.renderFileLink(e))))):(0,t.jsx)(Mn,null,this.renderFileLink(e))};renderImages=()=>{const{getAsset:e,value:n,field:r}=this.props,o=function(e){return Nn(e)?Ln(e).map(e=>({id:(0,_.v4)(),value:e})):e}(n);return Nn(n)?(0,t.jsx)(An,{items:o,onSortEnd:this.onSortEnd,onRemoveOne:this.onRemoveOne,onReplaceOne:this.onReplaceOne,distance:4,getAsset:e,field:r,axis:"xy",lockToContainerEdges:!0}):(0,t.jsx)(wn,null,(0,t.jsx)(Dn,{value:n,field:r,getAsset:e}))};renderSelection=n=>{const{t:r,field:o}=this.props,i=this.allowsMultiple();return(0,t.jsx)("div",null,e?this.renderImages():null,(0,t.jsx)("div",null,e?null:this.renderFileLinks(),(0,t.jsx)(Tn,{onClick:this.handleChange},r(`editor.editorWidgets.${n}.${this.allowsMultiple()?"addMore":"chooseDifferent"}`)),o.get("choose_url",!0)&&!this.allowsMultiple()?(0,t.jsx)(Tn,{onClick:this.handleUrl(n)},r(`editor.editorWidgets.${n}.replaceUrl`)):null,(0,t.jsx)(jn,{onClick:this.handleRemove},r(`editor.editorWidgets.${n}.remove${i?"All":""}`))))};renderNoSelection=e=>{const{t:n,field:r}=this.props;return(0,t.jsx)(v().Fragment,null,(0,t.jsx)(Tn,{onClick:this.handleChange},n(`editor.editorWidgets.${e}.choose${this.allowsMultiple()?"Multiple":""}`)),r.get("choose_url",!0)?(0,t.jsx)(Tn,{onClick:this.handleUrl(e)},n(`editor.editorWidgets.${e}.chooseUrl`)):null)};render(){const{value:n,classNameWrapper:r}=this.props,o=e?"image":"file";return(0,t.jsx)("div",{className:r},(0,t.jsx)("span",null,n?this.renderSelection(o):this.renderNoSelection(o)))}}}const Fn=A(({href:e,path:n})=>(0,t.jsx)("a",{href:e,rel:"noopener noreferrer",target:"_blank"},n),{target:"ecp3s3o0",label:"FileLink"})({name:"4zleql",styles:"display:block"});function qn({values:e,getAsset:n,field:r}){return(0,t.jsx)("div",null,e.map(e=>(0,t.jsx)(Fn,{key:e,path:e,href:n(e,r)})))}function Bn(e){const{value:n,getAsset:r,field:o}=e;return Array.isArray(n)||j.List.isList(n)?(0,t.jsx)(qn,{values:n,getAsset:r,field:o}):(0,t.jsx)(Fn,{key:n,path:n,href:r(n,o)})}function Un(e){return(0,t.jsx)(G.WidgetPreviewContainer,null,e.value?(0,t.jsx)(Bn,e):null)}Un.propTypes={getAsset:M().func.isRequired,value:M().node};const zn=Un,Wn={properties:{allow_multiple:{type:"boolean"}}},Hn=Pn(),Xn={Widget:function(e={}){return{name:"file",controlComponent:Hn,previewComponent:zn,schema:Wn,...e}},controlComponent:Hn,previewComponent:zn,withFileControl:Pn}})(),u.DecapCmsWidgetFile})());
7
+ `));function Jr({forImage:e}={}){return class t extends m().Component{static propTypes={field:N().object.isRequired,getAsset:N().func.isRequired,mediaPaths:L().map.isRequired,onAddAsset:N().func.isRequired,onChange:N().func.isRequired,onRemoveInsertedMedia:N().func.isRequired,onOpenMediaLibrary:N().func.isRequired,onClearMediaControl:N().func.isRequired,onRemoveMediaControl:N().func.isRequired,classNameWrapper:N().string.isRequired,value:N().oneOfType([N().string,N().arrayOf(N().string),L().listOf(N().string)]),t:N().func.isRequired};static defaultProps={value:""};constructor(e){super(e),this.controlID=crypto.randomUUID()}componentDidMount(){N().checkPropTypes(t.propTypes,this.props,"prop","FileControl")}shouldComponentUpdate(e){if(this.props.value!==e.value||this.props.getAsset!==e.getAsset)return!0;const t=e.mediaPaths.get(this.controlID);return!(!t||e.value===t)}componentDidUpdate(){const{mediaPaths:e,value:t,onRemoveInsertedMedia:n,onChange:r}=this.props,o=e.get(this.controlID);o&&o!==t?r(o):o&&o===t&&n(this.controlID)}componentWillUnmount(){this.props.onRemoveMediaControl(this.controlID)}handleChange=t=>{const{field:n,onOpenMediaLibrary:r,value:o}=this.props;t.preventDefault();const i=this.getMediaLibraryFieldOptions();return r({controlID:this.controlID,forImage:e,privateUpload:n.get("private"),value:Vr(o),allowMultiple:!!i.get("allow_multiple",!0),config:i.get("config"),field:n})};handleUrl=e=>t=>{t.preventDefault();const n=window.prompt(this.props.t(`editor.editorWidgets.${e}.promptUrl`));if(n)return this.props.onChange(n)};handleRemove=e=>(e.preventDefault(),this.props.onClearMediaControl(this.controlID),this.props.onChange(""));onRemoveOne=e=>()=>{const t=Vr(this.props.value);return t.splice(e,1),this.props.onChange(function(e){return Array.isArray(e)?e.length:P.List.isList(e)?e.size:e?1:0}(t)>0?[...t]:null)};onReplaceOne=t=>()=>{const{field:n,onOpenMediaLibrary:r,value:o}=this.props,i=this.getMediaLibraryFieldOptions();return r({controlID:this.controlID,forImage:e,privateUpload:n.get("private"),value:Vr(o),replaceIndex:t,allowMultiple:!1,config:i.get("config"),field:n})};getMediaLibraryFieldOptions=()=>{const{field:e}=this.props;return e.hasIn(["options","media_library"])?(Gr(e),e.getIn(["options","media_library"],(0,P.Map)())):e.get("media_library",(0,P.Map)())};allowsMultiple=()=>{const e=this.getMediaLibraryFieldOptions();return e.get("config",!1)&&e.get("config").get("multiple",!1)};onSortEnd=({oldIndex:e,newIndex:t})=>{const{value:n}=this.props,r=(o=n,i=e,a=t,function(e,t,n){const r=t<0?e.length+t:t;if(r>=0&&r<e.length){const r=n<0?e.length+n:n,[o]=e.splice(t,1);e.splice(r,0,o)}}(o=[...o],i,a),o);var o,i,a;return this.props.onChange(r)};getValidateValue=()=>{const{value:e}=this.props;return e?Kr(e)?e.map(e=>Q(e)):Q(e):e};renderFileLink=e=>{if(!e||e.length<=50)return e;const t=`${e.slice(0,25)}…${e.slice(-24)}`;return Nr(Br,{href:e,rel:"noopener",target:"_blank",children:t})};renderFileLinks=()=>{const{value:e}=this.props;return Kr(e)?Nr(Wr,{children:Nr(Hr,{children:e.map(e=>Nr("li",{children:this.renderFileLink(e)},e))})}):Nr(Wr,{children:this.renderFileLink(e)})};renderImages=()=>{const{getAsset:e,value:t,field:n}=this.props,r=function(e){return Kr(e)?Vr(e).map(e=>({id:crypto.randomUUID(),value:e})):e}(t);return Kr(t)?Nr(qr,{items:r,onSortEnd:this.onSortEnd,onRemoveOne:this.onRemoveOne,onReplaceOne:this.onReplaceOne,distance:4,getAsset:e,field:n,axis:"xy",lockToContainerEdges:!0}):Nr(Lr,{children:Nr(jr,{value:t,field:n,getAsset:e})})};renderSelection=t=>{const{t:n,field:r}=this.props,o=this.allowsMultiple();return _r("div",{children:[e?this.renderImages():null,_r("div",{children:[e?null:this.renderFileLinks(),Nr(Yr,{onClick:this.handleChange,children:n(`editor.editorWidgets.${t}.${this.allowsMultiple()?"addMore":"chooseDifferent"}`)}),r.get("choose_url",!0)&&!this.allowsMultiple()?Nr(Yr,{onClick:this.handleUrl(t),children:n(`editor.editorWidgets.${t}.replaceUrl`)}):null,Nr(Xr,{onClick:this.handleRemove,children:n(`editor.editorWidgets.${t}.remove${o?"All":""}`)})]})]})};renderNoSelection=e=>{const{t,field:n}=this.props;return _r(Ir,{children:[Nr(Yr,{onClick:this.handleChange,children:t(`editor.editorWidgets.${e}.choose${this.allowsMultiple()?"Multiple":""}`)}),n.get("choose_url",!0)?Nr(Yr,{onClick:this.handleUrl(e),children:t(`editor.editorWidgets.${e}.chooseUrl`)}):null]})};render(){const{value:t,classNameWrapper:n}=this.props,r=e?"image":"file";return Nr("div",{className:n,children:Nr("span",{children:t?this.renderSelection(r):this.renderNoSelection(r)})})}}}const Zr=T(({href:e,path:t})=>Nr("a",{href:e,rel:"noopener noreferrer",target:"_blank",children:t}),{target:"ecp3s3o0",label:"FileLink"})({name:"4zleql",styles:"display:block"});function Qr({values:e,getAsset:t,field:n}){return Nr("div",{children:e.map(e=>Nr(Zr,{path:e,href:t(e,n)},e))})}function eo(e){const{value:t,getAsset:n,field:r}=e;return Array.isArray(t)||P.List.isList(t)?Nr(Qr,{values:t,getAsset:n,field:r}):Nr(Zr,{path:t,href:n(t,r)},t)}function to(e){return Nr(Z.WidgetPreviewContainer,{children:e.value?Nr(eo,{...e}):null})}to.propTypes={getAsset:N().func.isRequired,value:N().node};const no=to,ro={properties:{allow_multiple:{type:"boolean"}}},oo=Jr(),io={Widget:function(e={}){return{name:"file",controlComponent:oo,previewComponent:no,schema:ro,...e}},controlComponent:oo,previewComponent:no,withFileControl:Jr}})(),c=c.DecapCmsWidgetFile,c})());
8
8
  //# sourceMappingURL=decap-cms-widget-file.js.map
@@ -7,3 +7,22 @@
7
7
  * This source code is licensed under the MIT license found in the
8
8
  * LICENSE file in the root directory of this source tree.
9
9
  */
10
+
11
+ /**
12
+ * @license React
13
+ * react-jsx-runtime.production.js
14
+ *
15
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
16
+ *
17
+ * This source code is licensed under the MIT license found in the
18
+ * LICENSE file in the root directory of this source tree.
19
+ */
20
+
21
+ /** @license React v16.13.1
22
+ * react-is.production.min.js
23
+ *
24
+ * Copyright (c) Facebook, Inc. and its affiliates.
25
+ *
26
+ * This source code is licensed under the MIT license found in the
27
+ * LICENSE file in the root directory of this source tree.
28
+ */