cleanplate 0.2.8 → 0.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/form-controls/Date.d.ts.map +1 -1
- package/dist/components/form-controls/date/DatePickerPanel.d.ts +3 -0
- package/dist/components/form-controls/date/DatePickerPanel.d.ts.map +1 -1
- package/dist/index.css +1 -1
- package/dist/index.es.css +1 -1
- package/dist/index.es.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -2,7 +2,7 @@ import*as e from"react";import t,{useRef as n,useState as a,useEffect as r,useId
|
|
|
2
2
|
/*!
|
|
3
3
|
* tabbable 6.2.0
|
|
4
4
|
* @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
|
|
5
|
-
*/var Va=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"].join(","),Xa="undefined"==typeof Element,Ka=Xa?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Ua=!Xa&&Element.prototype.getRootNode?function(e){var t;return null==e||null===(t=e.getRootNode)||void 0===t?void 0:t.call(e)}:function(e){return null==e?void 0:e.ownerDocument},Ga=function e(t,n){var a;void 0===n&&(n=!0);var r=null==t||null===(a=t.getAttribute)||void 0===a?void 0:a.call(t,"inert");return""===r||"true"===r||n&&t&&e(t.parentNode)},Qa=function e(t,n,a){for(var r=[],o=Array.from(t);o.length;){var i=o.shift();if(!Ga(i,!1))if("SLOT"===i.tagName){var l=i.assignedElements(),s=e(l.length?l:i.children,!0,a);a.flatten?r.push.apply(r,s):r.push({scopeParent:i,candidates:s})}else{Ka.call(i,Va)&&a.filter(i)&&(n||!t.includes(i))&&r.push(i);var c=i.shadowRoot||"function"==typeof a.getShadowRoot&&a.getShadowRoot(i),u=!Ga(c,!1)&&(!a.shadowRootFilter||a.shadowRootFilter(i));if(c&&u){var d=e(!0===c?i.children:c.children,!0,a);a.flatten?r.push.apply(r,d):r.push({scopeParent:i,candidates:d})}else o.unshift.apply(o,i.children)}}return r},Za=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},Ja=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||function(e){var t,n=null==e||null===(t=e.getAttribute)||void 0===t?void 0:t.call(e,"contenteditable");return""===n||"true"===n}(e))&&!Za(e)?0:e.tabIndex},er=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},tr=function(e){return"INPUT"===e.tagName},nr=function(e){return function(e){return tr(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t,n=e.form||Ua(e),a=function(e){return n.querySelectorAll('input[type="radio"][name="'+e+'"]')};if("undefined"!=typeof window&&void 0!==window.CSS&&"function"==typeof window.CSS.escape)t=a(window.CSS.escape(e.name));else try{t=a(e.name)}catch(e){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",e.message),!1}var r=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]}(t,e.form);return!r||r===e}(e)},ar=function(e){var t=e.getBoundingClientRect(),n=t.width,a=t.height;return 0===n&&0===a},rr=function(e,t){var n=t.displayCheck,a=t.getShadowRoot;if("hidden"===getComputedStyle(e).visibility)return!0;var r=Ka.call(e,"details>summary:first-of-type")?e.parentElement:e;if(Ka.call(r,"details:not([open]) *"))return!0;if(n&&"full"!==n&&"legacy-full"!==n){if("non-zero-area"===n)return ar(e)}else{if("function"==typeof a){for(var o=e;e;){var i=e.parentElement,l=Ua(e);if(i&&!i.shadowRoot&&!0===a(i))return ar(e);e=e.assignedSlot?e.assignedSlot:i||l===e.ownerDocument?i:l.host}e=o}if(function(e){var t,n,a,r,o=e&&Ua(e),i=null===(t=o)||void 0===t?void 0:t.host,l=!1;if(o&&o!==e)for(l=!!(null!==(n=i)&&void 0!==n&&null!==(a=n.ownerDocument)&&void 0!==a&&a.contains(i)||null!=e&&null!==(r=e.ownerDocument)&&void 0!==r&&r.contains(e));!l&&i;){var s,c,u;l=!(null===(c=i=null===(s=o=Ua(i))||void 0===s?void 0:s.host)||void 0===c||null===(u=c.ownerDocument)||void 0===u||!u.contains(i))}return l}(e))return!e.getClientRects().length;if("legacy-full"!==n)return!0}return!1},or=function(e,t){return!(t.disabled||Ga(t)||function(e){return tr(e)&&"hidden"===e.type}(t)||rr(t,e)||function(e){return"DETAILS"===e.tagName&&Array.prototype.slice.apply(e.children).some(function(e){return"SUMMARY"===e.tagName})}(t)||function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if("FIELDSET"===t.tagName&&t.disabled){for(var n=0;n<t.children.length;n++){var a=t.children.item(n);if("LEGEND"===a.tagName)return!!Ka.call(t,"fieldset[disabled] *")||!a.contains(e)}return!0}t=t.parentElement}return!1}(t))},ir=function(e,t){return!(nr(t)||Ja(t)<0||!or(e,t))},lr=function(e){var t=parseInt(e.getAttribute("tabindex"),10);return!!(isNaN(t)||t>=0)},sr=function e(t){var n=[],a=[];return t.forEach(function(t,r){var o=!!t.scopeParent,i=o?t.scopeParent:t,l=function(e,t){var n=Ja(e);return n<0&&t&&!Za(e)?0:n}(i,o),s=o?e(t.candidates):i;0===l?o?n.push.apply(n,s):n.push(i):a.push({documentOrder:r,tabIndex:l,item:t,isScope:o,content:s})}),a.sort(er).reduce(function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e},[]).concat(n)},cr=function(e,t){var n;return n=(t=t||{}).getShadowRoot?Qa([e],t.includeContainer,{filter:ir.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:lr}):function(e,t,n){if(Ga(e))return[];var a=Array.prototype.slice.apply(e.querySelectorAll(Va));return t&&Ka.call(e,Va)&&a.unshift(e),a.filter(n)}(e,t.includeContainer,ir.bind(null,t)),sr(n)};function ur(e,t){if(!e||!t)return!1;const n=null==t.getRootNode?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&na(n)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function dr(e){return"composedPath"in e?e.composedPath()[0]:e.target}function mr(e,t){if(null==t)return!1;if("composedPath"in e)return e.composedPath().includes(t);const n=e;return null!=n.target&&t.contains(n.target)}function pr(e){return(null==e?void 0:e.ownerDocument)||document}function fr(e,t,n){void 0===n&&(n=!0);return e.filter(e=>{var a;return e.parentId===t&&(!n||(null==(a=e.context)?void 0:a.open))}).flatMap(t=>[t,...fr(e,t.id,n)])}function hr(e,t){return["mouse","pen"].includes(e)}var gr="undefined"!=typeof document?i:function(){};const yr={...e}.useInsertionEffect||(e=>e());function vr(t){const n=e.useRef(()=>{if("production"!==process.env.NODE_ENV)throw new Error("Cannot call an event handler while rendering.")});return yr(()=>{n.current=t}),e.useCallback(function(){for(var e=arguments.length,t=new Array(e),a=0;a<e;a++)t[a]=arguments[a];return null==n.current?void 0:n.current(...t)},[])}const br=()=>({getShadowRoot:!0,displayCheck:"function"==typeof ResizeObserver&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function wr(e,t){const n=cr(e,br()),a=n.length;if(0===a)return;const r=function(e){let t=e.activeElement;for(;null!=(null==(n=t)||null==(n=n.shadowRoot)?void 0:n.activeElement);){var n;t=t.shadowRoot.activeElement}return t}(pr(e)),o=n.indexOf(r);return n[-1===o?1===t?0:a-1:o+t]}function Er(e,t){const n=t||e.currentTarget,a=e.relatedTarget;return!a||!ur(n,a)}function xr(e){cr(e,br()).forEach(e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")})}function Nr(e){e.querySelectorAll("[data-tabindex]").forEach(e=>{const t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")})}function kr(e,t,n){let{reference:a,floating:r}=e;const o=La(t),i=$a(t),l=Ia(i),s=Oa(t),c="y"===o,u=a.x+a.width/2-r.width/2,d=a.y+a.height/2-r.height/2,m=a[l]/2-r[l]/2;let p;switch(s){case"top":p={x:u,y:a.y-r.height};break;case"bottom":p={x:u,y:a.y+a.height};break;case"right":p={x:a.x+a.width,y:d};break;case"left":p={x:a.x-r.width,y:d};break;default:p={x:a.x,y:a.y}}switch(Ra(t)){case"start":p[i]-=m*(n&&c?-1:1);break;case"end":p[i]+=m*(n&&c?-1:1)}return p}async function Mr(e,t){var n;void 0===t&&(t={});const{x:a,y:r,platform:o,rects:i,elements:l,strategy:s}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:m=!1,padding:p=0}=Ta(t,e),f=function(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}(p),h=l[m?"floating"===d?"reference":"floating":d],g=Ha(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(h)))||n?h:h.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(l.floating)),boundary:c,rootBoundary:u,strategy:s})),y="floating"===d?{x:a,y:r,width:i.floating.width,height:i.floating.height}:i.reference,v=await(null==o.getOffsetParent?void 0:o.getOffsetParent(l.floating)),b=await(null==o.isElement?void 0:o.isElement(v))&&await(null==o.getScale?void 0:o.getScale(v))||{x:1,y:1},w=Ha(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:y,offsetParent:v,strategy:s}):y);return{top:(g.top-w.top+f.top)/b.y,bottom:(w.bottom-g.bottom+f.bottom)/b.y,left:(g.left-w.left+f.left)/b.x,right:(w.right-g.right+f.right)/b.x}}const Cr=new Set(["left","top"]);function Dr(e){const t=ga(e);let n=parseFloat(t.width)||0,a=parseFloat(t.height)||0;const r=ta(e),o=r?e.offsetWidth:n,i=r?e.offsetHeight:a,l=ka(n)!==o||ka(a)!==i;return l&&(n=o,a=i),{width:n,height:a,$:l}}function Sr(e){return ea(e)?e:e.contextElement}function Pr(e){const t=Sr(e);if(!ta(t))return Ca(1);const n=t.getBoundingClientRect(),{width:a,height:r,$:o}=Dr(t);let i=(o?ka(n.width):n.width)/a,l=(o?ka(n.height):n.height)/r;return i&&Number.isFinite(i)||(i=1),l&&Number.isFinite(l)||(l=1),{x:i,y:l}}const Tr=Ca(0);function Or(e){const t=Qn(e);return pa()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Tr}function Rr(e,t,n,a){void 0===t&&(t=!1),void 0===n&&(n=!1);const r=e.getBoundingClientRect(),o=Sr(e);let i=Ca(1);t&&(a?ea(a)&&(i=Pr(a)):i=Pr(e));const l=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==Qn(e))&&t}(o,n,a)?Or(o):Ca(0);let s=(r.left+l.x)/i.x,c=(r.top+l.y)/i.y,u=r.width/i.x,d=r.height/i.y;if(o){const e=Qn(o),t=a&&ea(a)?Qn(a):a;let n=e,r=Ea(n);for(;r&&a&&t!==n;){const e=Pr(r),t=r.getBoundingClientRect(),a=ga(r),o=t.left+(r.clientLeft+parseFloat(a.paddingLeft))*e.x,i=t.top+(r.clientTop+parseFloat(a.paddingTop))*e.y;s*=e.x,c*=e.y,u*=e.x,d*=e.y,s+=o,c+=i,n=Qn(r),r=Ea(n)}}return Ha({width:u,height:d,x:s,y:c})}function Fr(e,t){const n=ya(e).scrollLeft;return t?t.left+n:Rr(Zn(e)).left+n}function Ir(e,t){const n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Fr(e,n),y:n.top+t.scrollTop}}const Ar=new Set(["absolute","fixed"]);function Lr(e,t,n){let a;if("viewport"===t)a=function(e,t){const n=Qn(e),a=Zn(e),r=n.visualViewport;let o=a.clientWidth,i=a.clientHeight,l=0,s=0;if(r){o=r.width,i=r.height;const e=pa();(!e||e&&"fixed"===t)&&(l=r.offsetLeft,s=r.offsetTop)}const c=Fr(a);if(c<=0){const e=a.ownerDocument,t=e.body,n=getComputedStyle(t),r="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(a.clientWidth-t.clientWidth-r);i<=25&&(o-=i)}else c<=25&&(o+=c);return{width:o,height:i,x:l,y:s}}(e,n);else if("document"===t)a=function(e){const t=Zn(e),n=ya(e),a=e.ownerDocument.body,r=Na(t.scrollWidth,t.clientWidth,a.scrollWidth,a.clientWidth),o=Na(t.scrollHeight,t.clientHeight,a.scrollHeight,a.clientHeight);let i=-n.scrollLeft+Fr(e);const l=-n.scrollTop;return"rtl"===ga(a).direction&&(i+=Na(t.clientWidth,a.clientWidth)-r),{width:r,height:o,x:i,y:l}}(Zn(e));else if(ea(t))a=function(e,t){const n=Rr(e,!0,"fixed"===t),a=n.top+e.clientTop,r=n.left+e.clientLeft,o=ta(e)?Pr(e):Ca(1);return{width:e.clientWidth*o.x,height:e.clientHeight*o.y,x:r*o.x,y:a*o.y}}(t,n);else{const n=Or(e);a={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Ha(a)}function $r(e,t){const n=va(e);return!(n===t||!ea(n)||ha(n))&&("fixed"===ga(n).position||$r(n,t))}function jr(e,t,n){const a=ta(t),r=Zn(t),o="fixed"===n,i=Rr(e,!0,o,t);let l={scrollLeft:0,scrollTop:0};const s=Ca(0);function c(){s.x=Fr(r)}if(a||!a&&!o)if(("body"!==Gn(t)||ra(r))&&(l=ya(t)),a){const e=Rr(t,!0,o,t);s.x=e.x+t.clientLeft,s.y=e.y+t.clientTop}else r&&c();o&&!a&&r&&c();const u=!r||a||o?Ca(0):Ir(r,l);return{x:i.left+l.scrollLeft-s.x-u.x,y:i.top+l.scrollTop-s.y-u.y,width:i.width,height:i.height}}function Br(e){return"static"===ga(e).position}function Wr(e,t){if(!ta(e)||"fixed"===ga(e).position)return null;if(t)return t(e);let n=e.offsetParent;return Zn(e)===n&&(n=n.ownerDocument.body),n}function zr(e,t){const n=Qn(e);if(sa(e))return n;if(!ta(e)){let t=va(e);for(;t&&!ha(t);){if(ea(t)&&!Br(t))return t;t=va(t)}return n}let a=Wr(e,t);for(;a&&ia(a)&&Br(a);)a=Wr(a,t);return a&&ha(a)&&Br(a)&&!ma(a)?n:a||function(e){let t=va(e);for(;ta(t)&&!ha(t);){if(ma(t))return t;if(sa(t))return null;t=va(t)}return null}(e)||n}const _r={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:a,strategy:r}=e;const o="fixed"===r,i=Zn(a),l=!!t&&sa(t.floating);if(a===i||l&&o)return n;let s={scrollLeft:0,scrollTop:0},c=Ca(1);const u=Ca(0),d=ta(a);if((d||!d&&!o)&&(("body"!==Gn(a)||ra(i))&&(s=ya(a)),ta(a))){const e=Rr(a);c=Pr(a),u.x=e.x+a.clientLeft,u.y=e.y+a.clientTop}const m=!i||d||o?Ca(0):Ir(i,s);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-s.scrollLeft*c.x+u.x+m.x,y:n.y*c.y-s.scrollTop*c.y+u.y+m.y}},getDocumentElement:Zn,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:a,strategy:r}=e;const o=[..."clippingAncestors"===n?sa(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let a=wa(e,[],!1).filter(e=>ea(e)&&"body"!==Gn(e)),r=null;const o="fixed"===ga(e).position;let i=o?va(e):e;for(;ea(i)&&!ha(i);){const t=ga(i),n=ma(i);n||"fixed"!==t.position||(r=null),(o?!n&&!r:!n&&"static"===t.position&&r&&Ar.has(r.position)||ra(i)&&!n&&$r(e,i))?a=a.filter(e=>e!==i):r=t,i=va(i)}return t.set(e,a),a}(t,this._c):[].concat(n),a],i=o[0],l=o.reduce((e,n)=>{const a=Lr(t,n,r);return e.top=Na(a.top,e.top),e.right=xa(a.right,e.right),e.bottom=xa(a.bottom,e.bottom),e.left=Na(a.left,e.left),e},Lr(t,i,r));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},getOffsetParent:zr,getElementRects:async function(e){const t=this.getOffsetParent||zr,n=this.getDimensions,a=await n(e.floating);return{reference:jr(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:a.width,height:a.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=Dr(e);return{width:t,height:n}},getScale:Pr,isElement:ea,isRTL:function(e){return"rtl"===ga(e).direction}};function qr(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Yr(e,t,n,a){void 0===a&&(a={});const{ancestorScroll:r=!0,ancestorResize:o=!0,elementResize:i="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:s=!1}=a,c=Sr(e),u=r||o?[...c?wa(c):[],...wa(t)]:[];u.forEach(e=>{r&&e.addEventListener("scroll",n,{passive:!0}),o&&e.addEventListener("resize",n)});const d=c&&l?function(e,t){let n,a=null;const r=Zn(e);function o(){var e;clearTimeout(n),null==(e=a)||e.disconnect(),a=null}return function i(l,s){void 0===l&&(l=!1),void 0===s&&(s=1),o();const c=e.getBoundingClientRect(),{left:u,top:d,width:m,height:p}=c;if(l||t(),!m||!p)return;const f={rootMargin:-Ma(d)+"px "+-Ma(r.clientWidth-(u+m))+"px "+-Ma(r.clientHeight-(d+p))+"px "+-Ma(u)+"px",threshold:Na(0,xa(1,s))||1};let h=!0;function g(t){const a=t[0].intersectionRatio;if(a!==s){if(!h)return i();a?i(!1,a):n=setTimeout(()=>{i(!1,1e-7)},1e3)}1!==a||qr(c,e.getBoundingClientRect())||i(),h=!1}try{a=new IntersectionObserver(g,{...f,root:r.ownerDocument})}catch(e){a=new IntersectionObserver(g,f)}a.observe(e)}(!0),o}(c,n):null;let m,p=-1,f=null;i&&(f=new ResizeObserver(e=>{let[a]=e;a&&a.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var e;null==(e=f)||e.observe(t)})),n()}),c&&!s&&f.observe(c),f.observe(t));let h=s?Rr(e):null;return s&&function t(){const a=Rr(e);h&&!qr(h,a)&&n();h=a,m=requestAnimationFrame(t)}(),n(),()=>{var e;u.forEach(e=>{r&&e.removeEventListener("scroll",n),o&&e.removeEventListener("resize",n)}),null==d||d(),null==(e=f)||e.disconnect(),f=null,s&&cancelAnimationFrame(m)}}const Hr=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,a;const{x:r,y:o,placement:i,middlewareData:l}=t,s=await async function(e,t){const{placement:n,platform:a,elements:r}=e,o=await(null==a.isRTL?void 0:a.isRTL(r.floating)),i=Oa(n),l=Ra(n),s="y"===La(n),c=Cr.has(i)?-1:1,u=o&&s?-1:1,d=Ta(t,e);let{mainAxis:m,crossAxis:p,alignmentAxis:f}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return l&&"number"==typeof f&&(p="end"===l?-1*f:f),s?{x:p*u,y:m*c}:{x:m*c,y:p*u}}(t,e);return i===(null==(n=l.offset)?void 0:n.placement)&&null!=(a=l.arrow)&&a.alignmentOffset?{}:{x:r+s.x,y:o+s.y,data:{...s,placement:i}}}}},Vr=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:a,placement:r}=t,{mainAxis:o=!0,crossAxis:i=!1,limiter:l={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...s}=Ta(e,t),c={x:n,y:a},u=await Mr(t,s),d=La(Oa(r)),m=Fa(d);let p=c[m],f=c[d];if(o){const e="y"===m?"bottom":"right";p=Pa(p+u["y"===m?"top":"left"],p,p-u[e])}if(i){const e="y"===d?"bottom":"right";f=Pa(f+u["y"===d?"top":"left"],f,f-u[e])}const h=l.fn({...t,[m]:p,[d]:f});return{...h,data:{x:h.x-n,y:h.y-a,enabled:{[m]:o,[d]:i}}}}}},Xr=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,a;const{placement:r,middlewareData:o,rects:i,initialPlacement:l,platform:s,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:m,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:h=!0,...g}=Ta(e,t);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const y=Oa(r),v=La(l),b=Oa(l)===l,w=await(null==s.isRTL?void 0:s.isRTL(c.floating)),E=m||(b||!h?[Ya(l)]:function(e){const t=Ya(e);return[ja(e),t,ja(t)]}(l)),x="none"!==f;!m&&x&&E.push(...qa(l,h,f,w));const N=[l,...E],k=await Mr(t,g),M=[];let C=(null==(a=o.flip)?void 0:a.overflows)||[];if(u&&M.push(k[y]),d){const e=function(e,t,n){void 0===n&&(n=!1);const a=Ra(e),r=$a(e),o=Ia(r);let i="x"===r?a===(n?"end":"start")?"right":"left":"start"===a?"bottom":"top";return t.reference[o]>t.floating[o]&&(i=Ya(i)),[i,Ya(i)]}(r,i,w);M.push(k[e[0]],k[e[1]])}if(C=[...C,{placement:r,overflows:M}],!M.every(e=>e<=0)){var D,S;const e=((null==(D=o.flip)?void 0:D.index)||0)+1,t=N[e];if(t){if(!("alignment"===d&&v!==La(t))||C.every(e=>La(e.placement)!==v||e.overflows[0]>0))return{data:{index:e,overflows:C},reset:{placement:t}}}let n=null==(S=C.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:S.placement;if(!n)switch(p){case"bestFit":{var P;const e=null==(P=C.filter(e=>{if(x){const t=La(e.placement);return t===v||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:P[0];e&&(n=e);break}case"initialPlacement":n=l}if(r!==n)return{reset:{placement:n}}}return{}}}},Kr=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,a;const{placement:r,rects:o,platform:i,elements:l}=t,{apply:s=()=>{},...c}=Ta(e,t),u=await Mr(t,c),d=Oa(r),m=Ra(r),p="y"===La(r),{width:f,height:h}=o.floating;let g,y;"top"===d||"bottom"===d?(g=d,y=m===(await(null==i.isRTL?void 0:i.isRTL(l.floating))?"start":"end")?"left":"right"):(y=d,g="end"===m?"top":"bottom");const v=h-u.top-u.bottom,b=f-u.left-u.right,w=xa(h-u[g],v),E=xa(f-u[y],b),x=!t.middlewareData.shift;let N=w,k=E;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(k=b),null!=(a=t.middlewareData.shift)&&a.enabled.y&&(N=v),x&&!m){const e=Na(u.left,0),t=Na(u.right,0),n=Na(u.top,0),a=Na(u.bottom,0);p?k=f-2*(0!==e||0!==t?e+t:Na(u.left,u.right)):N=h-2*(0!==n||0!==a?n+a:Na(u.top,u.bottom))}await s({...t,availableWidth:k,availableHeight:N});const M=await i.getDimensions(l.floating);return f!==M.width||h!==M.height?{reset:{rects:!0}}:{}}}},Ur=(e,t,n)=>{const a=new Map,r={platform:_r,...n},o={...r.platform,_c:a};return(async(e,t,n)=>{const{placement:a="bottom",strategy:r="absolute",middleware:o=[],platform:i}=n,l=o.filter(Boolean),s=await(null==i.isRTL?void 0:i.isRTL(t));let c=await i.getElementRects({reference:e,floating:t,strategy:r}),{x:u,y:d}=kr(c,a,s),m=a,p={},f=0;for(let n=0;n<l.length;n++){const{name:o,fn:h}=l[n],{x:g,y:y,data:v,reset:b}=await h({x:u,y:d,initialPlacement:a,placement:m,strategy:r,middlewareData:p,rects:c,platform:i,elements:{reference:e,floating:t}});u=null!=g?g:u,d=null!=y?y:d,p={...p,[o]:{...p[o],...v}},b&&f<=50&&(f++,"object"==typeof b&&(b.placement&&(m=b.placement),b.rects&&(c=!0===b.rects?await i.getElementRects({reference:e,floating:t,strategy:r}):b.rects),({x:u,y:d}=kr(c,m,s))),n=-1)}return{x:u,y:d,placement:m,strategy:r,middlewareData:p}})(e,t,{...r,platform:o})};var Gr="undefined"!=typeof document?i:function(){};function Qr(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,a,r;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(a=n;0!==a--;)if(!Qr(e[a],t[a]))return!1;return!0}if(r=Object.keys(e),n=r.length,n!==Object.keys(t).length)return!1;for(a=n;0!==a--;)if(!{}.hasOwnProperty.call(t,r[a]))return!1;for(a=n;0!==a--;){const n=r[a];if(("_owner"!==n||!e.$$typeof)&&!Qr(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function Zr(e){if("undefined"==typeof window)return 1;return(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Jr(e,t){const n=Zr(e);return Math.round(t*n)/n}function eo(t){const n=e.useRef(t);return Gr(()=>{n.current=t}),n}const to=(e,t)=>({...Hr(e),options:[e,t]}),no=(e,t)=>({...Vr(e),options:[e,t]}),ao=(e,t)=>({...Xr(e),options:[e,t]}),ro=(e,t)=>({...Kr(e),options:[e,t]}),oo="data-floating-ui-focusable",io="active",lo="selected",so={...e};let co=!1,uo=0;const mo=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+uo++;const po=so.useId||function(){const[t,n]=e.useState(()=>co?mo():void 0);return gr(()=>{null==t&&n(mo())},[]),e.useEffect(()=>{co=!0},[]),t};let fo;"production"!==process.env.NODE_ENV&&(fo=new Set);const ho=e.createContext(null),go=e.createContext(null),yo=()=>e.useContext(go);function vo(e){return"data-floating-ui-"+e}const bo={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0},wo=e.forwardRef(function(t,n){const[a,r]=e.useState();gr(()=>{/apple/i.test(navigator.vendor)&&r("button")},[]);const o={ref:n,tabIndex:0,role:a,"aria-hidden":!a||void 0,[vo("focus-guard")]:"",style:bo};return p("span",{...t,...o})}),Eo=e.createContext(null),xo=vo("portal");function No(t){const{children:n,id:a,root:r,preserveTabOrder:o=!0}=t,i=function(t){void 0===t&&(t={});const{id:n,root:a}=t,r=po(),o=ko(),[i,l]=e.useState(null),s=e.useRef(null);return gr(()=>()=>{null==i||i.remove(),queueMicrotask(()=>{s.current=null})},[i]),gr(()=>{if(!r)return;if(s.current)return;const e=n?document.getElementById(n):null;if(!e)return;const t=document.createElement("div");t.id=r,t.setAttribute(xo,""),e.appendChild(t),s.current=t,l(t)},[n,r]),gr(()=>{if(null===a)return;if(!r)return;if(s.current)return;let e=a||(null==o?void 0:o.portalNode);e&&!Jn(e)&&(e=e.current),e=e||document.body;let t=null;n&&(t=document.createElement("div"),t.id=n,e.appendChild(t));const i=document.createElement("div");i.id=r,i.setAttribute(xo,""),e=t||e,e.appendChild(i),s.current=i,l(i)},[n,a,r,o]),i}({id:a,root:r}),[l,s]=e.useState(null),c=e.useRef(null),u=e.useRef(null),d=e.useRef(null),h=e.useRef(null),g=null==l?void 0:l.modal,y=null==l?void 0:l.open,v=!!l&&!l.modal&&l.open&&o&&!(!r&&!i);return e.useEffect(()=>{if(i&&o&&!g)return i.addEventListener("focusin",e,!0),i.addEventListener("focusout",e,!0),()=>{i.removeEventListener("focusin",e,!0),i.removeEventListener("focusout",e,!0)};function e(e){if(i&&Er(e)){("focusin"===e.type?Nr:xr)(i)}}},[i,o,g]),e.useEffect(()=>{i&&(y||Nr(i))},[y,i]),m(Eo.Provider,{value:e.useMemo(()=>({preserveTabOrder:o,beforeOutsideRef:c,afterOutsideRef:u,beforeInsideRef:d,afterInsideRef:h,portalNode:i,setFocusManagerState:s}),[o,i]),children:[v&&i&&p(wo,{"data-type":"outside",ref:c,onFocus:e=>{if(Er(e,i)){var t;null==(t=d.current)||t.focus()}else{const e=l?l.domReference:null,t=wr(pr(n=e).body,-1)||n;null==t||t.focus()}var n}}),v&&i&&p("span",{"aria-owns":i.id,style:bo}),i&&f.createPortal(n,i),v&&i&&p(wo,{"data-type":"outside",ref:u,onFocus:e=>{if(Er(e,i)){var t;null==(t=h.current)||t.focus()}else{const t=l?l.domReference:null,a=wr(pr(n=t).body,1)||n;null==a||a.focus(),(null==l?void 0:l.closeOnFocusOut)&&(null==l||l.onOpenChange(!1,e.nativeEvent,"focus-out"))}var n}})]})}const ko=()=>e.useContext(Eo);function Mo(e){return ta(e.target)&&"BUTTON"===e.target.tagName}function Co(e){return function(e){return ta(e)&&e.matches("input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])")}(e)}function Do(t,n){void 0===n&&(n={});const{open:a,onOpenChange:r,dataRef:o,elements:{domReference:i}}=t,{enabled:l=!0,event:s="click",toggle:c=!0,ignoreMouse:u=!1,keyboardHandlers:d=!0,stickIfOpen:m=!0}=n,p=e.useRef(),f=e.useRef(!1),h=e.useMemo(()=>({onPointerDown(e){p.current=e.pointerType},onMouseDown(e){const t=p.current;0===e.button&&"click"!==s&&(hr(t)&&u||(!a||!c||o.current.openEvent&&m&&"mousedown"!==o.current.openEvent.type?(e.preventDefault(),r(!0,e.nativeEvent,"click")):r(!1,e.nativeEvent,"click")))},onClick(e){const t=p.current;"mousedown"===s&&p.current?p.current=void 0:hr(t)&&u||(!a||!c||o.current.openEvent&&m&&"click"!==o.current.openEvent.type?r(!0,e.nativeEvent,"click"):r(!1,e.nativeEvent,"click"))},onKeyDown(e){p.current=void 0,e.defaultPrevented||!d||Mo(e)||(" "!==e.key||Co(i)||(e.preventDefault(),f.current=!0),function(e){return ta(e.target)&&"A"===e.target.tagName}(e)||"Enter"===e.key&&r(!a||!c,e.nativeEvent,"click"))},onKeyUp(e){e.defaultPrevented||!d||Mo(e)||Co(i)||" "===e.key&&f.current&&(f.current=!1,r(!a||!c,e.nativeEvent,"click"))}}),[o,i,s,u,d,r,a,m,c]);return e.useMemo(()=>l?{reference:h}:{},[l,h])}const So={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},Po={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},To=e=>{var t,n;return{escapeKey:"boolean"==typeof e?e:null!=(t=null==e?void 0:e.escapeKey)&&t,outsidePress:"boolean"==typeof e?e:null==(n=null==e?void 0:e.outsidePress)||n}};function Oo(t,n){void 0===n&&(n={});const{open:a,onOpenChange:r,elements:o,dataRef:i}=t,{enabled:l=!0,escapeKey:s=!0,outsidePress:c=!0,outsidePressEvent:u="pointerdown",referencePress:d=!1,referencePressEvent:m="pointerdown",ancestorScroll:p=!1,bubbles:f,capture:h}=n,g=yo(),y=vr("function"==typeof c?c:()=>!1),v="function"==typeof c?y:c,b=e.useRef(!1),{escapeKey:w,outsidePress:E}=To(f),{escapeKey:x,outsidePress:N}=To(h),k=e.useRef(!1),M=vr(e=>{var t;if(!a||!l||!s||"Escape"!==e.key)return;if(k.current)return;const n=null==(t=i.current.floatingContext)?void 0:t.nodeId,o=g?fr(g.nodesRef.current,n):[];if(!w&&(e.stopPropagation(),o.length>0)){let e=!0;if(o.forEach(t=>{var n;null==(n=t.context)||!n.open||t.context.dataRef.current.__escapeKeyBubbles||(e=!1)}),!e)return}r(!1,function(e){return"nativeEvent"in e}(e)?e.nativeEvent:e,"escape-key")}),C=vr(e=>{var t;const n=()=>{var t;M(e),null==(t=dr(e))||t.removeEventListener("keydown",n)};null==(t=dr(e))||t.addEventListener("keydown",n)}),D=vr(e=>{var t;const n=i.current.insideReactTree;i.current.insideReactTree=!1;const a=b.current;if(b.current=!1,"click"===u&&a)return;if(n)return;if("function"==typeof v&&!v(e))return;const l=dr(e),s="["+vo("inert")+"]",c=pr(o.floating).querySelectorAll(s);let d=ea(l)?l:null;for(;d&&!ha(d);){const e=va(d);if(ha(e)||!ea(e))break;d=e}if(c.length&&ea(l)&&!l.matches("html,body")&&!ur(l,o.floating)&&Array.from(c).every(e=>!ur(d,e)))return;if(ta(l)&&T){const t=ha(l),n=ga(l),a=/auto|scroll/,r=t||a.test(n.overflowX),o=t||a.test(n.overflowY),i=r&&l.clientWidth>0&&l.scrollWidth>l.clientWidth,s=o&&l.clientHeight>0&&l.scrollHeight>l.clientHeight,c="rtl"===n.direction,u=s&&(c?e.offsetX<=l.offsetWidth-l.clientWidth:e.offsetX>l.clientWidth),d=i&&e.offsetY>l.clientHeight;if(u||d)return}const m=null==(t=i.current.floatingContext)?void 0:t.nodeId,p=g&&fr(g.nodesRef.current,m).some(t=>{var n;return mr(e,null==(n=t.context)?void 0:n.elements.floating)});if(mr(e,o.floating)||mr(e,o.domReference)||p)return;const f=g?fr(g.nodesRef.current,m):[];if(f.length>0){let e=!0;if(f.forEach(t=>{var n;null==(n=t.context)||!n.open||t.context.dataRef.current.__outsidePressBubbles||(e=!1)}),!e)return}r(!1,e,"outside-press")}),S=vr(e=>{var t;const n=()=>{var t;D(e),null==(t=dr(e))||t.removeEventListener(u,n)};null==(t=dr(e))||t.addEventListener(u,n)});e.useEffect(()=>{if(!a||!l)return;i.current.__escapeKeyBubbles=w,i.current.__outsidePressBubbles=E;let e=-1;function t(e){r(!1,e,"ancestor-scroll")}function n(){window.clearTimeout(e),k.current=!0}function c(){e=window.setTimeout(()=>{k.current=!1},pa()?5:0)}const d=pr(o.floating);s&&(d.addEventListener("keydown",x?C:M,x),d.addEventListener("compositionstart",n),d.addEventListener("compositionend",c)),v&&d.addEventListener(u,N?S:D,N);let m=[];return p&&(ea(o.domReference)&&(m=wa(o.domReference)),ea(o.floating)&&(m=m.concat(wa(o.floating))),!ea(o.reference)&&o.reference&&o.reference.contextElement&&(m=m.concat(wa(o.reference.contextElement)))),m=m.filter(e=>{var t;return e!==(null==(t=d.defaultView)?void 0:t.visualViewport)}),m.forEach(e=>{e.addEventListener("scroll",t,{passive:!0})}),()=>{s&&(d.removeEventListener("keydown",x?C:M,x),d.removeEventListener("compositionstart",n),d.removeEventListener("compositionend",c)),v&&d.removeEventListener(u,N?S:D,N),m.forEach(e=>{e.removeEventListener("scroll",t)}),window.clearTimeout(e)}},[i,o,s,v,u,a,r,p,l,w,E,M,x,C,D,N,S]),e.useEffect(()=>{i.current.insideReactTree=!1},[i,v,u]);const P=e.useMemo(()=>({onKeyDown:M,...d&&{[So[m]]:e=>{r(!1,e.nativeEvent,"reference-press")},..."click"!==m&&{onClick(e){r(!1,e.nativeEvent,"reference-press")}}}}),[M,r,d,m]),T=e.useMemo(()=>({onKeyDown:M,onMouseDown(){b.current=!0},onMouseUp(){b.current=!0},[Po[u]]:()=>{i.current.insideReactTree=!0}}),[M,u,i]);return e.useMemo(()=>l?{reference:P,floating:T}:{},[l,P,T])}function Ro(t){const{open:n=!1,onOpenChange:a,elements:r}=t,o=po(),i=e.useRef({}),[l]=e.useState(()=>function(){const e=new Map;return{emit(t,n){var a;null==(a=e.get(t))||a.forEach(e=>e(n))},on(t,n){e.has(t)||e.set(t,new Set),e.get(t).add(n)},off(t,n){var a;null==(a=e.get(t))||a.delete(n)}}}()),s=null!=((null==(c=e.useContext(ho))?void 0:c.id)||null);var c;if("production"!==process.env.NODE_ENV){const e=r.reference;e&&!ea(e)&&function(){for(var e,t=arguments.length,n=new Array(t),a=0;a<t;a++)n[a]=arguments[a];const r="Floating UI: "+n.join(" ");var o;null!=(e=fo)&&e.has(r)||(null==(o=fo)||o.add(r),console.error(r))}("Cannot pass a virtual element to the `elements.reference` option,","as it must be a real DOM element. Use `refs.setPositionReference()`","instead.")}const[u,d]=e.useState(r.reference),m=vr((e,t,n)=>{i.current.openEvent=e?t:void 0,l.emit("openchange",{open:e,event:t,reason:n,nested:s}),null==a||a(e,t,n)}),p=e.useMemo(()=>({setPositionReference:d}),[]),f=e.useMemo(()=>({reference:u||r.reference||null,floating:r.floating||null,domReference:r.reference}),[u,r.reference,r.floating]);return e.useMemo(()=>({dataRef:i,open:n,onOpenChange:m,elements:f,events:l,floatingId:o,refs:p}),[n,m,f,l,o,p])}function Fo(t){void 0===t&&(t={});const{nodeId:n}=t,a=Ro({...t,elements:{reference:null,floating:null,...t.elements}}),r=t.rootContext||a,o=r.elements,[i,l]=e.useState(null),[s,c]=e.useState(null),u=(null==o?void 0:o.domReference)||i,d=e.useRef(null),m=yo();gr(()=>{u&&(d.current=u)},[u]);const p=function(t){void 0===t&&(t={});const{placement:n="bottom",strategy:a="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:l}={},transform:s=!0,whileElementsMounted:c,open:u}=t,[d,m]=e.useState({x:0,y:0,strategy:a,placement:n,middlewareData:{},isPositioned:!1}),[p,h]=e.useState(r);Qr(p,r)||h(r);const[g,y]=e.useState(null),[v,b]=e.useState(null),w=e.useCallback(e=>{e!==k.current&&(k.current=e,y(e))},[]),E=e.useCallback(e=>{e!==M.current&&(M.current=e,b(e))},[]),x=i||g,N=l||v,k=e.useRef(null),M=e.useRef(null),C=e.useRef(d),D=null!=c,S=eo(c),P=eo(o),T=eo(u),O=e.useCallback(()=>{if(!k.current||!M.current)return;const e={placement:n,strategy:a,middleware:p};P.current&&(e.platform=P.current),Ur(k.current,M.current,e).then(e=>{const t={...e,isPositioned:!1!==T.current};R.current&&!Qr(C.current,t)&&(C.current=t,f.flushSync(()=>{m(t)}))})},[p,n,a,P,T]);Gr(()=>{!1===u&&C.current.isPositioned&&(C.current.isPositioned=!1,m(e=>({...e,isPositioned:!1})))},[u]);const R=e.useRef(!1);Gr(()=>(R.current=!0,()=>{R.current=!1}),[]),Gr(()=>{if(x&&(k.current=x),N&&(M.current=N),x&&N){if(S.current)return S.current(x,N,O);O()}},[x,N,O,S,D]);const F=e.useMemo(()=>({reference:k,floating:M,setReference:w,setFloating:E}),[w,E]),I=e.useMemo(()=>({reference:x,floating:N}),[x,N]),A=e.useMemo(()=>{const e={position:a,left:0,top:0};if(!I.floating)return e;const t=Jr(I.floating,d.x),n=Jr(I.floating,d.y);return s?{...e,transform:"translate("+t+"px, "+n+"px)",...Zr(I.floating)>=1.5&&{willChange:"transform"}}:{position:a,left:t,top:n}},[a,s,I.floating,d.x,d.y]);return e.useMemo(()=>({...d,update:O,refs:F,elements:I,floatingStyles:A}),[d,O,F,I,A])}({...t,elements:{...o,...s&&{reference:s}}}),h=e.useCallback(e=>{const t=ea(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),getClientRects:()=>e.getClientRects(),contextElement:e}:e;c(t),p.refs.setReference(t)},[p.refs]),g=e.useCallback(e=>{(ea(e)||null===e)&&(d.current=e,l(e)),(ea(p.refs.reference.current)||null===p.refs.reference.current||null!==e&&!ea(e))&&p.refs.setReference(e)},[p.refs]),y=e.useMemo(()=>({...p.refs,setReference:g,setPositionReference:h,domReference:d}),[p.refs,g,h]),v=e.useMemo(()=>({...p.elements,domReference:u}),[p.elements,u]),b=e.useMemo(()=>({...p,...r,refs:y,elements:v,nodeId:n}),[p,y,v,n,r]);return gr(()=>{r.dataRef.current.floatingContext=b;const e=null==m?void 0:m.nodesRef.current.find(e=>e.id===n);e&&(e.context=b)}),e.useMemo(()=>({...p,context:b,refs:y,elements:v}),[p,y,v,b])}function Io(e,t,n){const a=new Map,r="item"===n;let o=e;if(r&&e){const{[io]:t,[lo]:n,...a}=e;o=a}return{..."floating"===n&&{tabIndex:-1,[oo]:""},...o,...t.map(t=>{const a=t?t[n]:null;return"function"==typeof a?e?a(e):null:a}).concat(e).reduce((e,t)=>t?(Object.entries(t).forEach(t=>{let[n,o]=t;var i;r&&[io,lo].includes(n)||(0===n.indexOf("on")?(a.has(n)||a.set(n,[]),"function"==typeof o&&(null==(i=a.get(n))||i.push(o),e[n]=function(){for(var e,t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return null==(e=a.get(n))?void 0:e.map(e=>e(...r)).find(e=>void 0!==e)})):e[n]=o)}),e):e,{})}}function Ao(t){void 0===t&&(t=[]);const n=t.map(e=>null==e?void 0:e.reference),a=t.map(e=>null==e?void 0:e.floating),r=t.map(e=>null==e?void 0:e.item),o=e.useCallback(e=>Io(e,t,"reference"),n),i=e.useCallback(e=>Io(e,t,"floating"),a),l=e.useCallback(e=>Io(e,t,"item"),r);return e.useMemo(()=>({getReferenceProps:o,getFloatingProps:i,getItemProps:l}),[o,i,l])}var Lo={container:"container-Ob3K8",border:"border-3ph1E","width-small":"width-small-IGEqx","width-medium":"width-medium-H3mey","width-large":"width-large-tlvBC","width-extra-large":"width-extra-large-kn4EU","width-quarter":"width-quarter-G91IH","width-one-third":"width-one-third-tBfDm","width-half":"width-half-jWSsK","width-three-quarters":"width-three-quarters-VZ7gZ","width-full":"width-full-JBbog","display-block":"display-block-umdz7","display-inline-block":"display-inline-block-tIWBf","display-flex":"display-flex-7Pivg","align-start":"align-start-WFirh","align-center":"align-center-m-T8U","align-end":"align-end-cxB31","justify-space-between":"justify-space-between-dNWWI","justify-center":"justify-center-ASu5z","justify-space-around":"justify-space-around-tHFSj","justify-space-evenly":"justify-space-evenly-Nk5K4","justify-flex-end":"justify-flex-end-W-NWe","justify-flex-start":"justify-flex-start---fCj"};const $o=["0","1","2","3","4","5","6","7","8","9","auto","x-0","x-1","x-2","x-3","x-4","x-5","x-6","x-7","x-8","x-9","x-auto","y-0","y-1","y-2","y-3","y-4","y-5","y-6","y-7","y-8","y-9","y-auto","t-0","t-1","t-2","t-3","t-4","t-5","t-6","t-7","t-8","t-9","t-auto","r-0","r-1","r-2","r-3","r-4","r-5","r-6","r-7","r-8","r-9","r-auto","b-0","b-1","b-2","b-3","b-4","b-5","b-6","b-7","b-8","b-9","b-auto","l-0","l-1","l-2","l-3","l-4","l-5","l-6","l-7","l-8","l-9","l-auto"];Array.from({length:101},(e,t)=>{const n=1924+t;return{label:String(n),value:String(n)}}).reverse(),$o.slice(0,10);const jo=({children:e,margin:n="m-0",padding:a="p-4",display:r="",align:o="",justify:i="",width:l="",showBorder:s=!1,className:c="",onClick:u,style:d,gap:m="4",...p})=>{const f=`display-${r}`,h=`justify-${i}`,y=`align-${o}`,w=`width-${l}`,E=b(n,v,"m"),x=b(a,v,"p"),k=b(m,v,"g"),M=N(Lo.container,x,E,{[Lo.border]:s,[Lo[w]]:l,[Lo[f]]:r,[Lo[h]]:i,[Lo[y]]:o},k,c);return t.createElement("div",g({className:M,onClick:e=>{"function"==typeof u&&u(e)},style:d},p),e)};var Bo={"cp-spinner-icon":"cp-spinner-icon-Ogl8J","spin-animation":"spin-animation-0bUOu","cp-spinner":"cp-spinner-j9RsW",small:"small-K-thx",medium:"medium-MFF6v",large:"large-p--mL",dark:"dark-ZBmrh"};const Wo=({size:e="medium",variant:n="light",icon:a="progress_activity",margin:r="0",className:o=""})=>{const i=b(r,v,"m"),l=N(Bo[e],Bo[n],i,o);return t.createElement(jo,{className:N(Bo["cp-spinner"],l)},t.createElement(S,{name:a,className:Bo["cp-spinner-icon"]}))},zo={position:"fixed",left:0,right:0,bottom:0,top:"auto",width:"100%",maxWidth:"100vw",margin:0,zIndex:1100};function _o(e,t){return`${e}-list-row-${t}`}const qo=e=>{const t=e.type||"";return t.startsWith("image/")?"image":"application/pdf"===t?"picture_as_pdf":t.startsWith("video/")?"movie":t.startsWith("audio/")?"music_note":t.includes("zip")||t.includes("compressed")?"folder_zip":"description"},Yo={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function Ho(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const Vo={date:Ho({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:Ho({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:Ho({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},Xo={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function Ko(e){return(t,n)=>{let a;if("formatting"===(n?.context?String(n.context):"standalone")&&e.formattingValues){const t=e.defaultFormattingWidth||e.defaultWidth,r=n?.width?String(n.width):t;a=e.formattingValues[r]||e.formattingValues[t]}else{const t=e.defaultWidth,r=n?.width?String(n.width):e.defaultWidth;a=e.values[r]||e.values[t]}return a[e.argumentCallback?e.argumentCallback(t):t]}}const Uo={ordinalNumber:(e,t)=>{const n=Number(e),a=n%100;if(a>20||a<10)switch(a%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:Ko({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:Ko({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:e=>e-1}),month:Ko({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:Ko({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:Ko({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})};function Go(e){return(t,n={})=>{const a=n.width,r=a&&e.matchPatterns[a]||e.matchPatterns[e.defaultMatchWidth],o=t.match(r);if(!o)return null;const i=o[0],l=a&&e.parsePatterns[a]||e.parsePatterns[e.defaultParseWidth],s=Array.isArray(l)?function(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n;return}(l,e=>e.test(i)):function(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n;return}(l,e=>e.test(i));let c;c=e.valueCallback?e.valueCallback(s):s,c=n.valueCallback?n.valueCallback(c):c;return{value:c,rest:t.slice(i.length)}}}const Qo={ordinalNumber:(Zo={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:e=>parseInt(e,10)},(e,t={})=>{const n=e.match(Zo.matchPattern);if(!n)return null;const a=n[0],r=e.match(Zo.parsePattern);if(!r)return null;let o=Zo.valueCallback?Zo.valueCallback(r[0]):r[0];return o=t.valueCallback?t.valueCallback(o):o,{value:o,rest:e.slice(a.length)}}),era:Go({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:Go({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:e=>e+1}),month:Go({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:Go({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:Go({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})};var Zo;const Jo={code:"en-US",formatDistance:(e,t,n)=>{let a;const r=Yo[e];return a="string"==typeof r?r:1===t?r.one:r.other.replace("{{count}}",t.toString()),n?.addSuffix?n.comparison&&n.comparison>0?"in "+a:a+" ago":a},formatLong:Vo,formatRelative:(e,t,n,a)=>Xo[e],localize:Uo,match:Qo,options:{weekStartsOn:0,firstWeekContainsDate:1}};let ei={};function ti(){return ei}const ni=6048e5,ai=Symbol.for("constructDateFrom");function ri(e,t){return"function"==typeof e?e(t):e&&"object"==typeof e&&ai in e?e[ai](t):e instanceof Date?new e.constructor(t):new Date(t)}function oi(e,t){return ri(t||e,e)}function ii(e){const t=oi(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function li(e,...t){const n=ri.bind(null,t.find(e=>"object"==typeof e));return t.map(n)}function si(e,t){const n=oi(e,t?.in);return n.setHours(0,0,0,0),n}function ci(e,t){const n=oi(e,t?.in),a=function(e,t){const[n,a]=li(0,e,t),r=si(n),o=si(a),i=+r-ii(r),l=+o-ii(o);return Math.round((i-l)/864e5)}(n,function(e,t){const n=oi(e,t?.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}(n));return a+1}function ui(e,t){const n=ti(),a=t?.weekStartsOn??t?.locale?.options?.weekStartsOn??n.weekStartsOn??n.locale?.options?.weekStartsOn??0,r=oi(e,t?.in),o=r.getDay(),i=(o<a?7:0)+o-a;return r.setDate(r.getDate()-i),r.setHours(0,0,0,0),r}function di(e,t){return ui(e,{...t,weekStartsOn:1})}function mi(e,t){const n=oi(e,t?.in),a=n.getFullYear(),r=ri(n,0);r.setFullYear(a+1,0,4),r.setHours(0,0,0,0);const o=di(r),i=ri(n,0);i.setFullYear(a,0,4),i.setHours(0,0,0,0);const l=di(i);return n.getTime()>=o.getTime()?a+1:n.getTime()>=l.getTime()?a:a-1}function pi(e,t){const n=oi(e,t?.in),a=+di(n)-+function(e,t){const n=mi(e,t),a=ri(e,0);return a.setFullYear(n,0,4),a.setHours(0,0,0,0),di(a)}(n);return Math.round(a/ni)+1}function fi(e,t){const n=oi(e,t?.in),a=n.getFullYear(),r=ti(),o=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??r.firstWeekContainsDate??r.locale?.options?.firstWeekContainsDate??1,i=ri(t?.in||e,0);i.setFullYear(a+1,0,o),i.setHours(0,0,0,0);const l=ui(i,t),s=ri(t?.in||e,0);s.setFullYear(a,0,o),s.setHours(0,0,0,0);const c=ui(s,t);return+n>=+l?a+1:+n>=+c?a:a-1}function hi(e,t){const n=oi(e,t?.in),a=+ui(n,t)-+function(e,t){const n=ti(),a=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??n.firstWeekContainsDate??n.locale?.options?.firstWeekContainsDate??1,r=fi(e,t),o=ri(t?.in||e,0);return o.setFullYear(r,0,a),o.setHours(0,0,0,0),ui(o,t)}(n,t);return Math.round(a/ni)+1}function gi(e,t){return(e<0?"-":"")+Math.abs(e).toString().padStart(t,"0")}const yi={y(e,t){const n=e.getFullYear(),a=n>0?n:1-n;return gi("yy"===t?a%100:a,t.length)},M(e,t){const n=e.getMonth();return"M"===t?String(n+1):gi(n+1,2)},d:(e,t)=>gi(e.getDate(),t.length),a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];default:return"am"===n?"a.m.":"p.m."}},h:(e,t)=>gi(e.getHours()%12||12,t.length),H:(e,t)=>gi(e.getHours(),t.length),m:(e,t)=>gi(e.getMinutes(),t.length),s:(e,t)=>gi(e.getSeconds(),t.length),S(e,t){const n=t.length,a=e.getMilliseconds();return gi(Math.trunc(a*Math.pow(10,n-3)),t.length)}},vi="midnight",bi="noon",wi="morning",Ei="afternoon",xi="evening",Ni="night",ki={G:function(e,t,n){const a=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(a,{width:"abbreviated"});case"GGGGG":return n.era(a,{width:"narrow"});default:return n.era(a,{width:"wide"})}},y:function(e,t,n){if("yo"===t){const t=e.getFullYear(),a=t>0?t:1-t;return n.ordinalNumber(a,{unit:"year"})}return yi.y(e,t)},Y:function(e,t,n,a){const r=fi(e,a),o=r>0?r:1-r;if("YY"===t){return gi(o%100,2)}return"Yo"===t?n.ordinalNumber(o,{unit:"year"}):gi(o,t.length)},R:function(e,t){return gi(mi(e),t.length)},u:function(e,t){return gi(e.getFullYear(),t.length)},Q:function(e,t,n){const a=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(a);case"QQ":return gi(a,2);case"Qo":return n.ordinalNumber(a,{unit:"quarter"});case"QQQ":return n.quarter(a,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(a,{width:"narrow",context:"formatting"});default:return n.quarter(a,{width:"wide",context:"formatting"})}},q:function(e,t,n){const a=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(a);case"qq":return gi(a,2);case"qo":return n.ordinalNumber(a,{unit:"quarter"});case"qqq":return n.quarter(a,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(a,{width:"narrow",context:"standalone"});default:return n.quarter(a,{width:"wide",context:"standalone"})}},M:function(e,t,n){const a=e.getMonth();switch(t){case"M":case"MM":return yi.M(e,t);case"Mo":return n.ordinalNumber(a+1,{unit:"month"});case"MMM":return n.month(a,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(a,{width:"narrow",context:"formatting"});default:return n.month(a,{width:"wide",context:"formatting"})}},L:function(e,t,n){const a=e.getMonth();switch(t){case"L":return String(a+1);case"LL":return gi(a+1,2);case"Lo":return n.ordinalNumber(a+1,{unit:"month"});case"LLL":return n.month(a,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(a,{width:"narrow",context:"standalone"});default:return n.month(a,{width:"wide",context:"standalone"})}},w:function(e,t,n,a){const r=hi(e,a);return"wo"===t?n.ordinalNumber(r,{unit:"week"}):gi(r,t.length)},I:function(e,t,n){const a=pi(e);return"Io"===t?n.ordinalNumber(a,{unit:"week"}):gi(a,t.length)},d:function(e,t,n){return"do"===t?n.ordinalNumber(e.getDate(),{unit:"date"}):yi.d(e,t)},D:function(e,t,n){const a=ci(e);return"Do"===t?n.ordinalNumber(a,{unit:"dayOfYear"}):gi(a,t.length)},E:function(e,t,n){const a=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(a,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(a,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(a,{width:"short",context:"formatting"});default:return n.day(a,{width:"wide",context:"formatting"})}},e:function(e,t,n,a){const r=e.getDay(),o=(r-a.weekStartsOn+8)%7||7;switch(t){case"e":return String(o);case"ee":return gi(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(r,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},c:function(e,t,n,a){const r=e.getDay(),o=(r-a.weekStartsOn+8)%7||7;switch(t){case"c":return String(o);case"cc":return gi(o,t.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(r,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(r,{width:"narrow",context:"standalone"});case"cccccc":return n.day(r,{width:"short",context:"standalone"});default:return n.day(r,{width:"wide",context:"standalone"})}},i:function(e,t,n){const a=e.getDay(),r=0===a?7:a;switch(t){case"i":return String(r);case"ii":return gi(r,t.length);case"io":return n.ordinalNumber(r,{unit:"day"});case"iii":return n.day(a,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(a,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(a,{width:"short",context:"formatting"});default:return n.day(a,{width:"wide",context:"formatting"})}},a:function(e,t,n){const a=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(a,{width:"narrow",context:"formatting"});default:return n.dayPeriod(a,{width:"wide",context:"formatting"})}},b:function(e,t,n){const a=e.getHours();let r;switch(r=12===a?bi:0===a?vi:a/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(e,t,n){const a=e.getHours();let r;switch(r=a>=17?xi:a>=12?Ei:a>=4?wi:Ni,t){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(e,t,n){if("ho"===t){let t=e.getHours()%12;return 0===t&&(t=12),n.ordinalNumber(t,{unit:"hour"})}return yi.h(e,t)},H:function(e,t,n){return"Ho"===t?n.ordinalNumber(e.getHours(),{unit:"hour"}):yi.H(e,t)},K:function(e,t,n){const a=e.getHours()%12;return"Ko"===t?n.ordinalNumber(a,{unit:"hour"}):gi(a,t.length)},k:function(e,t,n){let a=e.getHours();return 0===a&&(a=24),"ko"===t?n.ordinalNumber(a,{unit:"hour"}):gi(a,t.length)},m:function(e,t,n){return"mo"===t?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):yi.m(e,t)},s:function(e,t,n){return"so"===t?n.ordinalNumber(e.getSeconds(),{unit:"second"}):yi.s(e,t)},S:function(e,t){return yi.S(e,t)},X:function(e,t,n){const a=e.getTimezoneOffset();if(0===a)return"Z";switch(t){case"X":return Ci(a);case"XXXX":case"XX":return Di(a);default:return Di(a,":")}},x:function(e,t,n){const a=e.getTimezoneOffset();switch(t){case"x":return Ci(a);case"xxxx":case"xx":return Di(a);default:return Di(a,":")}},O:function(e,t,n){const a=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Mi(a,":");default:return"GMT"+Di(a,":")}},z:function(e,t,n){const a=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Mi(a,":");default:return"GMT"+Di(a,":")}},t:function(e,t,n){return gi(Math.trunc(+e/1e3),t.length)},T:function(e,t,n){return gi(+e,t.length)}};function Mi(e,t=""){const n=e>0?"-":"+",a=Math.abs(e),r=Math.trunc(a/60),o=a%60;return 0===o?n+String(r):n+String(r)+t+gi(o,2)}function Ci(e,t){if(e%60==0){return(e>0?"-":"+")+gi(Math.abs(e)/60,2)}return Di(e,t)}function Di(e,t=""){const n=e>0?"-":"+",a=Math.abs(e);return n+gi(Math.trunc(a/60),2)+t+gi(a%60,2)}const Si=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});default:return t.date({width:"full"})}},Pi=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});default:return t.time({width:"full"})}},Ti={p:Pi,P:(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],a=n[1],r=n[2];if(!r)return Si(e,t);let o;switch(a){case"P":o=t.dateTime({width:"short"});break;case"PP":o=t.dateTime({width:"medium"});break;case"PPP":o=t.dateTime({width:"long"});break;default:o=t.dateTime({width:"full"})}return o.replace("{{date}}",Si(a,t)).replace("{{time}}",Pi(r,t))}},Oi=/^D+$/,Ri=/^Y+$/,Fi=["D","DD","YY","YYYY"];function Ii(e){return!(!((t=e)instanceof Date||"object"==typeof t&&"[object Date]"===Object.prototype.toString.call(t))&&"number"!=typeof e||isNaN(+oi(e)));var t}const Ai=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Li=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,$i=/^'([^]*?)'?$/,ji=/''/g,Bi=/[a-zA-Z]/;function Wi(e,t,n){const a=ti(),r=n?.locale??a.locale??Jo,o=n?.firstWeekContainsDate??n?.locale?.options?.firstWeekContainsDate??a.firstWeekContainsDate??a.locale?.options?.firstWeekContainsDate??1,i=n?.weekStartsOn??n?.locale?.options?.weekStartsOn??a.weekStartsOn??a.locale?.options?.weekStartsOn??0,l=oi(e,n?.in);if(!Ii(l))throw new RangeError("Invalid time value");let s=t.match(Li).map(e=>{const t=e[0];if("p"===t||"P"===t){return(0,Ti[t])(e,r.formatLong)}return e}).join("").match(Ai).map(e=>{if("''"===e)return{isToken:!1,value:"'"};const t=e[0];if("'"===t)return{isToken:!1,value:zi(e)};if(ki[t])return{isToken:!0,value:e};if(t.match(Bi))throw new RangeError("Format string contains an unescaped latin alphabet character `"+t+"`");return{isToken:!1,value:e}});r.localize.preprocessor&&(s=r.localize.preprocessor(l,s));const c={firstWeekContainsDate:o,weekStartsOn:i,locale:r};return s.map(a=>{if(!a.isToken)return a.value;const o=a.value;(!n?.useAdditionalWeekYearTokens&&function(e){return Ri.test(e)}(o)||!n?.useAdditionalDayOfYearTokens&&function(e){return Oi.test(e)}(o))&&function(e,t,n){const a=function(e,t,n){const a="Y"===e[0]?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${a} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}(e,t,n);if(console.warn(a),Fi.includes(e))throw new RangeError(a)}(o,t,String(e));return(0,ki[o[0]])(l,o,r.localize,c)}).join("")}function zi(e){const t=e.match($i);return t?t[1].replace(ji,"'"):e}function _i(e,t,n){const a=oi(e,n?.in);return isNaN(t)?ri(e,NaN):t?(a.setDate(a.getDate()+t),a):a}function qi(e,t,n){const a=oi(e,n?.in);if(isNaN(t))return ri(e,NaN);if(!t)return a;const r=a.getDate(),o=ri(e,a.getTime());o.setMonth(a.getMonth()+t+1,0);return r>=o.getDate()?o:(a.setFullYear(o.getFullYear(),o.getMonth(),r),a)}function Yi(e,t,n){return qi(e,12*t,n)}function Hi(e,t){const n=oi(e,t?.in);return n.setDate(1),n.setHours(0,0,0,0),n}function Vi(e,t){const n=oi(e,t?.in),a=n.getMonth();return n.setFullYear(n.getFullYear(),a+1,0),n.setHours(23,59,59,999),n}function Xi(e,t,n){const[a,r]=li(0,e,t);return a.getFullYear()===r.getFullYear()&&a.getMonth()===r.getMonth()}const Ki=({onCancel:e,onOk:n})=>t.createElement("div",{className:An},t.createElement("button",{type:"button",className:Ln,onClick:t=>{t.stopPropagation(),e()}},"Cancel"),t.createElement("button",{type:"button",className:`${Ln} ${$n}`,onClick:e=>{e.stopPropagation(),n()}},"OK"));function Ui(e){return si(e)}function Gi(e,t){if(null==e||null==t)return e===t;return Ui(e).getTime()===Ui(t).getTime()}function Qi(e){if(null!=e&&""!==e){if(e instanceof Date){const t=e.getTime();return Number.isNaN(t)?void 0:Ui(e)}if("number"==typeof e&&Number.isFinite(e)){const t=new Date(e);return Number.isNaN(t.getTime())?void 0:Ui(t)}if("string"==typeof e&&""!==e.trim()){const t=e.trim();if(/^-?\d+$/.test(t)){const e=Number(t);if(Number.isFinite(e)){const t=new Date(e);return Number.isNaN(t.getTime())?void 0:Ui(t)}}const n=new Date(t);return Number.isNaN(n.getTime())?void 0:Ui(n)}}}const Zi=({weeks:e,weekLabels:n,locale:a,staged:o,today:i,isDayUnavailable:c,onSelectDay:u,onRequestPrevMonth:d,onRequestNextMonth:m,gridLabelId:p})=>{const f=l(()=>function(e){return e.flat()}(e),[e]),h=l(()=>{const e=[];return f.forEach((t,n)=>{c(t.date)||e.push(n)}),e},[f,c]),[g,y]=t.useState(null);r(()=>{if(o){const e=Ui(o).getTime(),t=f.findIndex(t=>Ui(t.date).getTime()===e);t>=0&&y(t)}},[f,o]);const v=s(e=>{if(0===h.length)return;const t=null!=g?h.indexOf(g):null,n=null==t?e>0?-1:h.length:t,a=Math.min(h.length-1,Math.max(0,n+e));y(h[a])},[g,h]),b=s(t=>{if(null==g)return void(null!=h[0]&&y(h[0]));const n=Math.floor(g/7),a=g%7,r=n+t;if(r<0)return void d?.();if(r>=e.length)return void m?.();const o=7*r+a;if(!(o>=f.length)){if(c(f[o].date)){const e=t<0?-1:1;let n=o;for(;n>=0&&n<f.length;){if(!c(f[n].date))return void y(n);n+=e}return}y(o)}},[f,g,c,h,m,d,e.length]),w=s(e=>{const t=f.map((e,t)=>({cell:e,idx:t})).filter(({cell:e})=>e.inCurrentMonth&&!c(e.date));0!==t.length&&y(e?t[t.length-1].idx:t[0].idx)},[f,c]);return t.createElement("div",{role:"grid","aria-labelledby":p,className:Cn,tabIndex:-1,onKeyDown:e=>{switch(e.key){case"ArrowRight":return e.preventDefault(),void v(1);case"ArrowLeft":return e.preventDefault(),void v(-1);case"ArrowDown":return e.preventDefault(),void b(1);case"ArrowUp":return e.preventDefault(),void b(-1);case"PageUp":return e.preventDefault(),void d?.();case"PageDown":return e.preventDefault(),void m?.();case"Home":return e.preventDefault(),void w(!1);case"End":return e.preventDefault(),void w(!0);default:return}}},t.createElement("div",{role:"row",className:Dn},n.map((e,n)=>t.createElement("span",{key:`dow-${String(n)}-${e}`,role:"columnheader","aria-label":e,className:Sn},e))),e.map((e,n)=>t.createElement("div",{role:"row",key:`w-${String(n)}`,className:Pn},e.map((r,l)=>{const s=n*e.length+l,d=c(r.date),m=null!=o&&Gi(r.date,o),p=Gi(r.date,i),f=g===s;return t.createElement("div",{key:String(r.date.getTime()),role:"gridcell",className:Tn},t.createElement("button",{type:"button","aria-label":Wi(r.date,"PPP",{locale:a}),"aria-selected":Boolean(m),"aria-disabled":d||void 0,tabIndex:f&&!d?0:-1,disabled:d,className:N(On,!r.inCurrentMonth&&Fn,p&&In,m&&Rn),"data-flat-index":s,onClick:e=>{e.preventDefault(),e.stopPropagation(),d||u(r.date)},onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),d||u(r.date))},onFocus:()=>{d||y(s)}},r.date.getDate()))}))))},Ji=({displayedMonth:e,locale:n,monthLabelShort:a,yearLabel:r,prevMonthDisabled:o,nextMonthDisabled:i,prevYearDisabled:l,nextYearDisabled:s,onPrevMonth:c,onNextMonth:u,onPrevYear:d,onNextYear:m,onOpenMonth:p,onOpenYear:f})=>t.createElement("div",{className:xn},t.createElement("div",{className:Nn},t.createElement("button",{type:"button",className:kn,"aria-label":"Previous month",disabled:o,onClick:e=>{e.stopPropagation(),o||c()}},t.createElement(S,{name:"keyboard_arrow_left","aria-hidden":!0})),t.createElement("button",{type:"button",className:Mn,"aria-label":`Choose month, ${Wi(e,"MMMM yyyy",{locale:n})}`,onClick:e=>{e.stopPropagation(),p()}},t.createElement("span",null,a),t.createElement(S,{name:"arrow_drop_down",size:"small","aria-hidden":!0})),t.createElement("button",{type:"button",className:kn,"aria-label":"Next month",disabled:i,onClick:e=>{e.stopPropagation(),i||u()}},t.createElement(S,{name:"keyboard_arrow_right","aria-hidden":!0}))),t.createElement("div",{className:Nn},t.createElement("button",{type:"button",className:kn,"aria-label":"Previous year",disabled:l,onClick:e=>{e.stopPropagation(),l||d()}},t.createElement(S,{name:"keyboard_arrow_left","aria-hidden":!0})),t.createElement("button",{type:"button",className:Mn,"aria-label":`Choose year, ${r}`,onClick:e=>{e.stopPropagation(),f()}},t.createElement("span",null,r),t.createElement(S,{name:"arrow_drop_down",size:"small","aria-hidden":!0})),t.createElement("button",{type:"button",className:kn,"aria-label":"Next year",disabled:s,onClick:e=>{e.stopPropagation(),s||m()}},t.createElement(S,{name:"keyboard_arrow_right","aria-hidden":!0})))),el=({items:e,onPick:n,activePredicate:a,ariaLabelledBy:r})=>t.createElement("ul",{className:jn,role:"listbox","aria-labelledby":r,"aria-label":r?void 0:"Choose option"},e.map((e,r)=>{const o=Boolean(a?.(e.value));return t.createElement("li",{key:`${String(e.value)}-${String(r)}`},t.createElement("button",{type:"button",role:"option","aria-selected":o,"aria-disabled":e.disabled||void 0,tabIndex:-1,disabled:e.disabled,className:N(Bn,o&&Wn),"data-row":r,onClick:t=>{t.stopPropagation(),e.disabled||n(e.value)}},e.label))}));function tl(e){return null!=e}function nl(e){return null!=e}function al(e,t){const n=Ui(e).getTime();if(tl(t.minDate)&&n<Ui(t.minDate).getTime())return!0;if(nl(t.maxDate)&&n>Ui(t.maxDate).getTime())return!0;const a=oi(Ui(e),r?.in).getDay();var r;return!!t.disabledDaysOfWeek?.includes(a)||!!t.disabledDates?.some(t=>Gi(Ui(t),Ui(e)))}function rl(e,t){let n=Ui(e);return tl(t.minDate)&&n.getTime()<Ui(t.minDate).getTime()&&(n=Ui(t.minDate)),nl(t.maxDate)&&n.getTime()>Ui(t.maxDate).getTime()&&(n=Ui(t.maxDate)),n}function ol(e,t){if(!tl(t))return!1;return Vi(e).getTime()<Ui(t).getTime()}function il(e,t){if(!nl(t))return!1;return Hi(e).getTime()>Ui(t).getTime()}const ll=({panelId:e,gridLabelId:n,locale:a=Jo,weekStartsOn:r,constraints:o,picker:i})=>{const s=a,c=l(()=>function(e,t){const n=Hi(e),a=ui(n,{weekStartsOn:t}),r=Vi(e),o=[];let i=a;for(;o.length<42&&(o.push({date:i,inCurrentMonth:Xi(i,n)}),i=_i(i,1),!(o.length>=35&&i.getTime()>r.getTime()))&&42!==o.length;);for(;o.length%7!=0;)o.push({date:i,inCurrentMonth:Xi(i,n)}),i=_i(i,1);const l=[];for(let e=0;e<o.length;e+=7)l.push(o.slice(e,e+7));return l}(i.displayedMonth,r),[i.displayedMonth,r]),u=l(()=>{const e=ui(Hi(i.displayedMonth),{weekStartsOn:r});return Array.from({length:7},(t,n)=>Wi(_i(e,n),"EEEEE",{locale:s}))},[s,i.displayedMonth,r]),d=Wi(i.displayedMonth,"MMM",{locale:s}),m=Wi(i.displayedMonth,"yyyy",{locale:s}),p=l(()=>Ui(new Date),[]),f=Hi(qi(i.displayedMonth,-1)),h=Hi(qi(i.displayedMonth,1)),g=ol(f,o.minDate),y=il(h,o.maxDate),v=Hi(Yi(i.displayedMonth,-1)),b=Hi(Yi(i.displayedMonth,1)),w=ol(v,o.minDate),E=il(b,o.maxDate),x=l(()=>{const e=o.minDate?.getFullYear()??i.displayedMonth.getFullYear()-100,t=o.maxDate?.getFullYear()??i.displayedMonth.getFullYear()+100,n=[];for(let a=e;a<=t;a+=1){const e=Hi(new Date(a,i.displayedMonth.getMonth(),1)),t=ol(e,o.minDate)||il(e,o.maxDate);n.push({value:a,label:String(a),disabled:t})}return n},[o.maxDate,o.minDate,i.displayedMonth]),N=l(()=>{const e=i.displayedMonth.getFullYear();return Array.from({length:12},(t,n)=>{const a=Hi(new Date(e,n,1)),r=ol(a,o.minDate)||il(a,o.maxDate);return{value:n,label:Wi(new Date(2e3,n,1),"MMM",{locale:s}),disabled:r}})},[o.maxDate,o.minDate,s,i.displayedMonth]),k=`${e}-subview-month-title`,M=`${e}-subview-year-title`,C=Wi(i.displayedMonth,"yyyy",{locale:s}),D=Wi(i.displayedMonth,"MMMM",{locale:s});return t.createElement("div",{id:e,className:En},"calendar"===i.panelView?t.createElement(t.Fragment,null,t.createElement("span",{id:n,className:bn},Wi(i.displayedMonth,"MMMM yyyy",{locale:s})),t.createElement(Ji,{displayedMonth:i.displayedMonth,locale:s,monthLabelShort:d,yearLabel:m,prevMonthDisabled:g,nextMonthDisabled:y,prevYearDisabled:w,nextYearDisabled:E,onPrevMonth:i.goPrevMonth,onNextMonth:i.goNextMonth,onPrevYear:()=>{i.setDisplayedMonthFromYearMonth(i.displayedMonth.getFullYear()-1,i.displayedMonth.getMonth())},onNextYear:()=>{i.setDisplayedMonthFromYearMonth(i.displayedMonth.getFullYear()+1,i.displayedMonth.getMonth())},onOpenMonth:()=>i.setPanelView("month"),onOpenYear:()=>i.setPanelView("year")}),t.createElement(Zi,{weeks:c,weekLabels:u,locale:s,staged:i.staged,today:p,isDayUnavailable:e=>al(e,o),onSelectDay:e=>i.selectDay(e),gridLabelId:n,onRequestPrevMonth:i.goPrevMonth,onRequestNextMonth:i.goNextMonth}),t.createElement(Ki,{onCancel:i.cancel,onOk:i.confirm})):null,"month"===i.panelView?t.createElement("div",{className:zn},t.createElement("div",{className:_n},t.createElement("button",{type:"button",className:qn,"aria-label":"Back to calendar",onClick:e=>{e.stopPropagation(),i.setPanelView("calendar")}},t.createElement(S,{name:"arrow_back","aria-hidden":!0})),t.createElement("span",{id:k,className:Yn},t.createElement("span",{className:Hn},"Select a month of ",C))),t.createElement(el,{ariaLabelledBy:k,items:N,activePredicate:e=>e===i.displayedMonth.getMonth(),onPick:e=>{i.setDisplayedMonthFromYearMonth(i.displayedMonth.getFullYear(),e),i.setPanelView("calendar")}})):null,"year"===i.panelView?t.createElement("div",{className:zn},t.createElement("div",{className:_n},t.createElement("button",{type:"button",className:qn,"aria-label":"Back to calendar",onClick:e=>{e.stopPropagation(),i.setPanelView("calendar")}},t.createElement(S,{name:"arrow_back","aria-hidden":!0})),t.createElement("span",{id:M,className:Yn},t.createElement("span",{className:Hn},"Select a year for ",D))),t.createElement(el,{ariaLabelledBy:M,items:x,activePredicate:e=>e===i.displayedMonth.getFullYear(),onPick:e=>{i.setDisplayedMonthFromYearMonth(e,i.displayedMonth.getMonth()),i.setPanelView("calendar")}})):null)};function sl(e,t){return ol(e,t.minDate)&&null!=t.minDate?Hi(t.minDate):il(e,t.maxDate)&&null!=t.maxDate?Hi(t.maxDate):e}function cl(e){const t=void 0!==e.value,[n,o]=a(()=>t?null:e.defaultValue??null),i=t?e.value??null:n,[l,c]=a(!1),[u,d]=a("calendar"),[m,p]=a(null),[f,h]=a(()=>sl(Hi(i??new Date),e.constraints)),g=i?.getTime()??null,y=e.constraints.minDate?.getTime(),v=e.constraints.maxDate?.getTime(),b=e.constraints.disabledDaysOfWeek?.join(",")??"",w=e.constraints.disabledDates?.map(e=>Ui(e).getTime()).join("|")??"";r(()=>{if(l)return;const t=i??new Date,n=e.constraints;h(sl(Hi(t),n))},[l,i,g,t,y,v,b,w]);const E=s(n=>{t||o(n),e.onChange?.(n)},[e,t]),x=s(()=>{c(!1),d("calendar")},[]),N=s(()=>{if(null!=i){const t=Ui(i);p(t),h(sl(Hi(t),e.constraints))}else{const t=function(e,t){let n=rl(e,t);for(let e=0;e<120;e+=1){if(!al(n,t))return n;n=rl(_i(n,1),t)}return n}(new Date,e.constraints);p(t),h(sl(Hi(t),e.constraints))}d("calendar"),c(!0)},[e.constraints,i]),k=s(()=>{p(null==i?null:Ui(i)),x()},[x,i]),M=s(()=>{if(null==m)E(null);else{const t=rl(m,e.constraints);if(al(t,e.constraints))return void x();E(t)}x()},[e.constraints,x,E,m]),C=s(t=>{const n=rl(Ui(t),e.constraints);p(n),h(sl(Hi(n),e.constraints))},[e.constraints]),D=s(()=>{E(null),p(null),x()},[x,E]),S=s(()=>{h(t=>sl(qi(t,-1),e.constraints))},[e.constraints]),P=s(()=>{h(t=>sl(qi(t,1),e.constraints))},[e.constraints]),T=s((t,n)=>{h(sl(Hi(new Date(t,n,1)),e.constraints))},[e.constraints]);return{isOpen:l,panelView:u,setPanelView:d,committed:i,staged:m,displayedMonth:f,open:N,close:x,cancel:k,confirm:M,selectDay:C,clearCommitted:D,goPrevMonth:S,goNextMonth:P,setDisplayedMonthFromYearMonth:T}}const ul={position:"fixed",left:0,right:0,bottom:0,top:"auto",width:"100%",maxWidth:"100vw",margin:0,zIndex:1100},dl=new Set(["text","search","url","tel","password"]);var ml={Input:({name:e,id:r,onChange:l,onKeyDown:s,onBlur:c,defaultValue:u,value:d,label:m="",isDisabled:p=!1,isRequired:f=!1,isFluid:h=!1,type:y="text",className:v="",placeholder:b="",error:w="",dataTestId:E,autoComplete:x,maxLength:k,min:M,max:C,prefix:D,suffix:P,prefixA11yLabel:T,suffixA11yLabel:O})=>{const R=o(),F=r??e??R,I=`${F}-error`,A=n(null),L=n(null),$="number"===y,j="search"===y,B=$?"text":y,W=$?"numeric":void 0,z=$?"[0-9]*":void 0,_=Xn.has(B),q=void 0!==d,[Y,H]=a(u??""),V=j&&!p&&(q?d??"":Y).length>0;i(()=>{if(!q||!_)return;const e=A.current,t=L.current;if(L.current=null,!e||!t||document.activeElement!==e)return;const n=e.value.length,a=Math.max(0,Math.min(t.start,n)),r=Math.max(0,Math.min(t.end,n));Kn(e,a,r)},[d,q,_]);const X=e=>{const t=A.current;if(!t)return;const n=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value")?.set;n?.call(t,e),t.dispatchEvent(new Event("input",{bubbles:!0}))},K=Vn(D),U=Vn(P),G=!j&&Boolean(K||U),Q=N(ee,{[te]:h},v),Z=w?ie:"",J=N(oe,Z,j?ue:"",j&&V?de:"",G?ye:""),ne=N(oe,pe,Z,p?fe:""),re=K?`${F}-prefix`:void 0,ve=U?`${F}-suffix`:void 0,be=[w?I:void 0,re,ve].filter(Boolean).join(" ")||void 0,we=t.createElement("input",g({ref:A,className:J,type:B,inputMode:W,pattern:z,disabled:p,required:f,"aria-required":f||void 0,"aria-invalid":!!w||void 0,"aria-describedby":be,name:e,id:F,placeholder:b,autoComplete:x||void 0,maxLength:k,min:M,max:C},q?{value:d??""}:void 0!==u?{defaultValue:u}:{},{onChange:e=>{const t=e.target;if($&&/\D/.test(t.value)){const e=t.value.replace(/\D/g,""),n=t.value.length-e.length,a=(t.selectionStart??e.length)-n;t.value=e;const r=Math.max(0,Math.min(a,e.length));Kn(t,r,r)}q&&_&&(L.current={start:t.selectionStart??t.value.length,end:t.selectionEnd??t.value.length}),q||H(t.value),l?.(e)},onKeyDown:e=>s?.(e),onBlur:e=>{if($&&""!==e.target.value&&(void 0!==M||void 0!==C)){const t=Number(e.target.value);if(!Number.isNaN(t)){const e=void 0!==M?Number(M):-1/0,n=void 0!==C?Number(C):1/0,a=Math.min(n,Math.max(e,t));a!==t&&X(String(a))}}c?.(e)},onBeforeInput:$?e=>{if(!$)return;const t=e.nativeEvent.data;t&&/\D/.test(t)&&e.preventDefault()}:void 0,"data-testid":E}));return t.createElement("div",{className:Q},m&&t.createElement("label",{className:ae,htmlFor:F},m," ",f&&t.createElement("span",{"aria-hidden":"true"},"*")),j?t.createElement("div",{className:se},t.createElement(S,{name:"search",size:"medium","aria-hidden":!0,className:ce}),we,V&&t.createElement("button",{type:"button",onClick:()=>{X(""),A.current?.focus()},className:me,"aria-label":"Clear search","data-testid":E?`${E}-clear`:void 0},t.createElement(S,{name:"close",size:"small","aria-hidden":!0}))):G?t.createElement("div",{className:ne},K&&t.createElement("span",{id:re,className:he,"aria-label":T,"data-testid":E?`${E}-prefix`:void 0},K),we,U&&t.createElement("span",{id:ve,className:ge,"aria-label":O,"data-testid":E?`${E}-suffix`:void 0},U)):we,w&&t.createElement("p",{id:I,role:"alert",className:le},w))},TextArea:({name:e,id:n,onChange:a,defaultValue:r,value:i,label:l="",isDisabled:s=!1,isRequired:c=!1,isFluid:u=!1,className:d="",placeholder:m="",error:p="",dataTestId:f})=>{const h=o(),g=n??e??h,y=`${g}-error`,v=N(ee,{[te]:u},d),b=N(oe,Ne,p?ie:"");return t.createElement("div",{className:v},l&&t.createElement("label",{className:ae,htmlFor:g},l," ",c&&t.createElement("span",{"aria-hidden":"true"},"*")),t.createElement("textarea",{className:b,disabled:s,required:c,"aria-required":c||void 0,"aria-invalid":!!p||void 0,"aria-describedby":p?y:void 0,name:e,id:g,defaultValue:r,placeholder:m,value:i,onChange:e=>a?.(e),"data-testid":f}),p&&t.createElement("p",{id:y,role:"alert",className:le},p))},File:({name:e,id:r,onChange:i,value:l,defaultValue:s,multiple:c=!1,accept:u,variant:d="button",buttonLabel:m="Browse file",dropZoneText:p="Drag files to upload",label:f="",isDisabled:h=!1,isRequired:g=!1,isFluid:y=!1,className:v="",error:b="",dataTestId:w})=>{const E=o(),x=r??e??E,k=`${x}-error`,M=n(null),C=void 0!==l,[D,P]=a(s??[]),T=C?l:D,[O,R]=a(!1),F=N(ee,an,{[te]:y},v),I=N(rn,"card"===d?ln:on,O?dn:""),A=(e,t)=>{C||P(e),i?.(e,t)},L=e=>{h||(e.preventDefault(),e.stopPropagation(),O||R(!0))};return t.createElement("div",{className:F,"data-invalid":b?"true":void 0,"data-variant":d},f&&t.createElement("label",{className:ae,htmlFor:x},f,g&&t.createElement(t.Fragment,null," ",t.createElement("span",{"aria-hidden":"true"},"*"))),t.createElement("input",{ref:M,className:xe,type:"file",disabled:h,required:g&&0===T.length,"aria-required":g||void 0,"aria-invalid":!!b||void 0,"aria-describedby":b?k:void 0,name:e,id:x,multiple:c,accept:u,onChange:e=>{const t=e.target.files?Array.from(e.target.files):[],n=c?[...T,...t]:t;A(n,e)},"data-testid":w}),"card"===d?t.createElement("label",{htmlFor:x,className:I,onDragEnter:L,onDragOver:L,onDragLeave:e=>{e.preventDefault(),e.stopPropagation(),R(!1)},onDrop:e=>{if(e.preventDefault(),e.stopPropagation(),R(!1),h)return;const t=Array.from(e.dataTransfer?.files??[]);if(0===t.length)return;const n=c?[...T,...t]:t.slice(0,1);A(n)}},t.createElement(S,{name:"cloud_upload",size:"large","aria-hidden":!0}),t.createElement("span",{className:sn},p),t.createElement("span",{className:cn,"aria-hidden":"true"},"or"),t.createElement("span",{className:un},m)):t.createElement("label",{htmlFor:x,className:I},t.createElement(S,{name:"upload",size:"medium","aria-hidden":!0}),t.createElement("span",null,m)),T.length>0&&t.createElement("ul",{className:mn,"aria-label":"Selected "+(1===T.length?"file":"files")},T.map((e,n)=>t.createElement("li",{key:`${e.name}-${n}`,className:pn},t.createElement("span",{className:fn,"aria-hidden":"true"},t.createElement(S,{name:qo(e),size:"medium"})),t.createElement("span",{className:hn},t.createElement("span",{className:gn,title:e.name},e.name),t.createElement("span",{className:yn},(e=>{if(!Number.isFinite(e)||e<=0)return"0 B";const t=["B","KB","MB","GB","TB"],n=Math.min(Math.floor(Math.log(e)/Math.log(1024)),t.length-1),a=e/Math.pow(1024,n),r=0===n?0:a<10?1:0;return`${a.toFixed(r)} ${t[n]}`})(e.size))),t.createElement("button",{type:"button",className:vn,onClick:()=>(e=>{const t=T.filter((t,n)=>n!==e);M.current&&(M.current.value=""),A(t)})(n),disabled:h,"aria-label":`Remove ${e.name}`,"data-testid":w?`${w}-remove-${n}`:void 0},t.createElement(S,{name:"close",size:"small","aria-hidden":!0}))))),b&&t.createElement("p",{id:k,role:"alert",className:le},b))},Select:({name:e,id:c,onChange:u,value:d,label:m="",isDisabled:p=!1,className:f="",triggerClassName:h="",triggerActiveClassName:y="",contentsClassName:v="",options:b,onSearch:w,searchDebounce:E=300,searchPlaceholder:x="Search",onAddOption:k,closeOnAddOption:M=!0,isRequired:C=!1,placeholder:D="Select an option",error:P="",isFluid:T=!1,mode:O,isMulti:R=!1,triggerMaxItems:F=2,clearable:I=!0,groups:A=!1,maxSelect:L,dataTestId:$})=>{const j="multi"===(void 0!==O?O:R?"multi":"single"),B=j&&"number"==typeof L&&Number.isFinite(L)&&L>=1?Math.floor(L):null,W=null===b,z=W?[]:b??[];r(()=>{W&&!w&&console.warn("CleanPlate Select: `options={null}` requires an `onSearch` callback.")},[W,w]);const _=o(),q=c??e??_,Y=`${q}-label`,H=`${q}-trigger`,V=`${q}-listbox`,X=`${q}-search`,K=`${q}-error`,U=n(null),G=n(null),Q=n(0),[Z,J]=a(""),[re,oe]=a([]),[ie,se]=a("idle"),[ce,ue]=a(0),[de,me]=a(!1),[pe,fe]=a(null),he=n(null),ge=function(e){const[t,n]=a(()=>"undefined"!=typeof window&&"function"==typeof window.matchMedia&&window.matchMedia(e).matches);return r(()=>{if("undefined"==typeof window||"function"!=typeof window.matchMedia)return;const t=window.matchMedia(e),a=()=>{n(t.matches)};return a(),t.addEventListener("change",a),()=>t.removeEventListener("change",a)},[e]),t}("(max-width: 768px)"),ye=n(ge);ye.current=ge;const[ve,be]=a(!1),[we,Ee]=a(!1),xe=n(!1);xe.current=we;const[Ne,Nt]=a(d),kt=l(()=>ge?[]:[to(4),ao({padding:8}),no({padding:8}),ro({apply({availableHeight:e,rects:t,elements:n}){Object.assign(n.floating.style,{maxHeight:`${Math.max(96,Math.floor(e)-12)}px`,width:`${t.reference.width}px`})}})],[ge]),{refs:Mt,floatingStyles:Ct,context:Dt}=Fo({open:de,placement:ge?"bottom":"bottom-start",strategy:"fixed",transform:!ge,middleware:kt,whileElementsMounted:ge?void 0:Yr,onOpenChange(e){if(!p){if(e)return Ee(!1),void me(!0);if(de)return Ee(!0),be(!1),void me(!1);Ee(!1),me(!1)}}}),St=de||we,Pt=s(e=>{if(e.target!==e.currentTarget)return;if(!xe.current)return;const t=ye.current;t&&"transform"!==e.propertyName||(t||"opacity"===e.propertyName)&&Ee(!1)},[]),Tt=Do(Dt,{enabled:!p}),Ot=Oo(Dt,{ancestorScroll:!ge,bubbles:!1,outsidePressEvent:"pointerdown"}),{getReferenceProps:Rt,getFloatingProps:Ft}=Ao([Tt,Ot]),It=s(()=>{if(de)return Ee(!0),be(!1),void me(!1);Ee(!1),me(!1)},[de]);i(()=>{if(!de)return void(we||be(!1));const e=window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>be(!0))});return()=>window.cancelAnimationFrame(e)},[de,we]);const At=l(()=>{const e=Z.trim().toLowerCase();return e?z.filter(t=>String(t.label).toLowerCase().includes(e)||String(t.value).toLowerCase().includes(e)):z},[z,Z]),Lt=W?re:At,$t=!W&&St&&0===At.length,jt=W&&St&&("loading"===ie||"idle"===ie),Bt=W&&St&&"error"===ie,Wt=W&&St&&"success"===ie&&0===re.length,zt=St&&!$t&&!jt&&!Bt&&!Wt&&Lt.length>0,_t=0===z.length?"No options available":"No matching results",qt=Z.trim(),Yt=qt.toLowerCase(),Ht=qt.length>0&&Lt.some(e=>String(e.label).trim().toLowerCase()===Yt||String(e.value).toLowerCase()===Yt),Vt=St&&!jt&&!Bt&&0===Lt.length&&($t&&qt.length>0||Wt),Xt=Boolean(k)&&!p&&Vt&&!Ht,Kt=$t||Wt,Ut=l(()=>{if(!zt||0===Lt.length)return[];if(!A)return Lt.map(e=>({kind:"option",option:e}));let e;const t=[];return Lt.forEach((n,a)=>{const r=n.group?.trim()??"";r!==e&&(r&&t.push({kind:"header",id:`select-group-${r}-${a}`,label:r}),e=r),t.push({kind:"option",option:n})}),t},[Lt,A,zt]),Gt=l(()=>Lt.filter(e=>!e.disabled),[Lt]),Qt=Array.isArray(Ne)?Ne:[],Zt=l(()=>new Set(Qt.map(e=>e.value)),[Qt]),Jt=null!=B&&Qt.length>=B,{navigableFlat:en,presentationNavFlatIndex:tn,navigableSourceRowIndexes:nn}=l(()=>{const e=[],t=[],n=new Array(Ut.length).fill(null);return Ut.forEach((a,r)=>{if("header"===a.kind)return;const o=a.option,i=j?Qt.some(e=>e.value===o.value):Boolean(Ne&&!Array.isArray(Ne)&&Ne.value===o.value),l=j&&Jt&&!o.disabled&&!i;!o.disabled&&!l&&(n[r]=e.length,e.push(o),t.push(r))}),{navigableFlat:e,presentationNavFlatIndex:n,navigableSourceRowIndexes:t}},[Jt,j,Ut,Qt,Ne]),an=Gt.length>0&&Gt.every(e=>Zt.has(e.value)),rn=Gt.some(e=>Zt.has(e.value))&&!an,on=zt&&j&&Gt.length>0,ln=null!=Ne&&!Array.isArray(Ne),sn=j&&Qt.length>0,cn=sn||ln,un="number"==typeof F&&Number.isFinite(F)&&F>=0?Math.floor(F):2,dn=sn?Qt.slice(0,un):[],mn=sn&&un<Qt.length?Qt.length-un:0,pn=ln&&"object"==typeof Ne&&"label"in Ne?Ne.label:"",fn=`${Ae} ${de?`${Le} ${y}`:""} ${h}`,hn=()=>{const e=document.getElementById(H);e instanceof HTMLElement&&e.focus()},gn=e=>{if(!e.disabled&&!p){if(j){const t=Array.isArray(Ne)?Ne:[],n=t.map(e=>e.value).includes(e.value);if(!n&&Jt)return;if(n){const n=t.filter(t=>t.value!==e.value);Nt(n),u?.(n)}else{const n=[...t,e];Nt(n),u?.(n)}}else Nt(e),u?.(e);It()}},yn=null!=pe&&zt&&en[pe]&&void 0!==nn[pe]?_o(q,nn[pe]):void 0;return r(()=>{de||(he.current=null,fe(null))},[de]),r(()=>{fe(null)},[Z]),r(()=>{if(!de||!he.current)return;if(!zt||0===en.length)return;const e=he.current;he.current=null,fe("first"===e?0:en.length-1)},[de,zt,en]),r(()=>{null!=pe&&zt&&(0!==en.length?pe>=en.length&&fe(en.length-1):fe(null))},[pe,en,zt]),i(()=>{if(null==pe||!zt||null==en[pe]||void 0===nn[pe])return;const e=_o(q,nn[pe]);document.getElementById(e)?.scrollIntoView({block:"nearest",inline:"nearest"})},[pe,en,nn,zt,q]),r(()=>{p&&It()},[p,It]),r(()=>{if(!(ge&&(de||we)))return;const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}},[ge,de,we]),r(()=>{ge||Ee(!1)},[ge]),r(()=>{if(!we)return;const e=80+(ge?300:200),t=window.setTimeout(()=>{Ee(!1)},e);return()=>window.clearTimeout(t)},[we,ge]),r(()=>{Nt(d)},[d]),r(()=>{const e=G.current;e&&(e.indeterminate=rn)},[rn]),r(()=>{if(!St)return Q.current+=1,J(""),oe([]),void se("idle");if(!de)return;if(ge)return;const e=window.requestAnimationFrame(()=>{U.current?.focus()});return()=>window.cancelAnimationFrame(e)},[St,de,ge]),r(()=>{if(!de||!W||!w)return;let e=!1;const t=""===Z.trim()?0:Math.max(0,Number(E)||0),n=window.setTimeout(()=>{const t=Q.current+1;Q.current=t,se("loading");const n=Z.trim();w(n).then(n=>{e||Q.current===t&&(se("success"),oe(Array.isArray(n)?n:[]))}).catch(()=>{e||Q.current===t&&(se("error"),oe([]))})},t);return()=>{e=!0,window.clearTimeout(n)}},[de,W,w,E,Z,ce]),t.createElement("div",{className:N(ee,{[te]:T,[ne]:p},f),"data-testid":$},m&&t.createElement("label",{id:Y,htmlFor:H,className:ae},m," ",C&&t.createElement("span",{"aria-hidden":"true"},"*")),t.createElement("div",{className:ke,"data-invalid":P?"true":void 0},t.createElement("div",g({ref:Mt.setReference},Rt({id:H,role:"combobox",tabIndex:p?-1:0,"aria-haspopup":"listbox","aria-expanded":de,"aria-controls":de?V:void 0,"aria-labelledby":m?Y:void 0,"aria-disabled":p||void 0,"aria-required":C||void 0,"aria-invalid":!!P||void 0,"aria-describedby":P?K:void 0,className:fn,onKeyDown(e){"ArrowDown"!==e.key&&"ArrowUp"!==e.key||de||p||(e.preventDefault(),he.current="ArrowDown"===e.key?"first":"last",me(!0))}})),t.createElement("div",{className:Me},sn?t.createElement("div",{className:Ce},dn.map(e=>{return t.createElement("span",{key:String(e.value),className:De},t.createElement("span",{className:Se},e.label),t.createElement("button",{type:"button",tabIndex:-1,className:Pe,"aria-label":`Remove ${e.label}`,disabled:p,onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:(n=e,e=>{if(e.preventDefault(),e.stopPropagation(),p||!j)return;const t=(Array.isArray(Ne)?Ne:[]).filter(e=>e.value!==n.value);Nt(t),u?.(t)})},t.createElement(S,{name:"close",size:"small",color:"gray"})));var n}),mn>0&&t.createElement("span",{className:Te,"aria-label":`${mn} more selected`},"+",mn)):ln?t.createElement("span",{className:Fe},pn):t.createElement("span",{className:Ie},D)),t.createElement("div",{className:Oe},I&&cn&&!p&&t.createElement("button",{type:"button",tabIndex:-1,className:Re,"aria-label":"Clear selection",onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:e=>{e.preventDefault(),e.stopPropagation(),p||(j?(Nt([]),u?.([])):(Nt(null),u?.(null)),It())}},t.createElement(S,{name:"close",size:"small",color:"gray"})),t.createElement(S,{name:de?"arrow_drop_up":"arrow_drop_down",className:"arrow "+(de?"up":"down"),"aria-hidden":!0}))),St&&t.createElement(No,null,ge?t.createElement("div",{className:We,"data-visible":ge&&ve?"true":void 0,"aria-hidden":!0}):null,t.createElement("div",g({ref:Mt.setFloating},Ft({style:ge?zo:Ct,className:N($e,ge&&ze,ge&&ve&&Ge,!ge&&je,!ge&&ve&&Be,v),onKeyDownCapture:e=>{if(!de||p)return;const t=Mt.floating.current;if(!t?.contains(e.target))return;if("Tab"===e.key)return e.preventDefault(),It(),void queueMicrotask(hn);const n=e.target;if(!!n?.closest("button")&&!n?.closest('[role="option"]')&&"Enter"===e.key)return;if(!zt||0===en.length)return;if(!e.nativeEvent.isComposing){if("ArrowDown"===e.key)return e.preventDefault(),void fe(e=>null==e?0:Math.min(e+1,en.length-1));if("ArrowUp"===e.key)return e.preventDefault(),void fe(e=>null==e?en.length-1:Math.max(e-1,0));if("Home"===e.key)return e.preventDefault(),void fe(0);if("End"===e.key)return e.preventDefault(),void fe(en.length-1);if("Enter"===e.key){e.preventDefault();const t=null!=pe?pe:en.length>0?0:null;null!=t&&t>=0&&t<en.length&&gn(en[t])}}},onTransitionEnd:Pt,...ge?{id:`${q}-select-panel`,role:"dialog","aria-modal":!0,"aria-labelledby":m?Y:void 0}:{}})),t.createElement("div",{className:_e,role:"presentation",onPointerDown:e=>{const t=e.target;t?.closest("input, button, textarea, label")||e.preventDefault()}},t.createElement("div",{className:et},t.createElement(S,{name:"search",className:tt,"aria-hidden":!0}),t.createElement("input",{ref:U,id:X,type:"search",className:N(Ye,Z&&nt),placeholder:x,autoComplete:"off","aria-label":m?`Search ${m}`:"Search options","aria-autocomplete":"list","aria-controls":de?V:void 0,"aria-activedescendant":yn,"aria-invalid":!!P||void 0,value:Z,onChange:e=>J(e.target.value)}),Z?t.createElement("button",{type:"button",className:at,"aria-label":"Clear search",onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:e=>{e.stopPropagation(),J(""),U.current?.focus()}},t.createElement(S,{name:"close",size:"small",color:"gray"})):null)),on?t.createElement("div",{className:qe,role:"presentation",onPointerDown:e=>{const t=e.target;t?.closest("input, button, textarea, label")||e.preventDefault()}},t.createElement("label",{className:Qe},t.createElement("input",{ref:G,type:"checkbox",className:Ze,checked:an,disabled:p,tabIndex:-1,"aria-label":m?`Select all matching ${m} options`:"Select all matching options",onChange:e=>{if(e.stopPropagation(),p||!j)return;const t=Gt;if(0===t.length)return;const n=new Set(t.map(e=>e.value));if(an){const e=Qt.filter(e=>!n.has(e.value));return Nt(e),void u?.(e)}let a=[...Qt];const r=B??Number.MAX_SAFE_INTEGER,o=new Set(a.map(e=>e.value));for(const e of t){if(a.length>=r)break;o.has(e.value)||(a.push(e),o.add(e.value))}Nt(a),u?.(a)},onClick:e=>e.stopPropagation()}),t.createElement("span",null,"Select all")),t.createElement("button",{type:"button",className:Je,disabled:p||0===Qt.length,onMouseDown:e=>{e.preventDefault()},onClick:e=>{e.preventDefault(),e.stopPropagation(),!p&&j&&0!==Qt.length&&(Nt([]),u?.([]))}},"Clear all")):null,t.createElement("div",{id:V,role:zt?"listbox":"group","aria-label":zt?m?void 0:"Options":m?`${m} options panel`:"Options panel","aria-multiselectable":!(!zt||!j)||void 0,"aria-labelledby":zt&&m?Y:void 0,"aria-busy":jt||void 0,"aria-invalid":!!P||void 0,className:Ue},jt?t.createElement("div",{className:Ke,"aria-live":"polite"},t.createElement(Wo,{size:"small",margin:"0"}),t.createElement("span",{className:rt},"Loading…")):null,Bt?t.createElement("div",{className:Ke,role:"alert"},t.createElement("span",{className:ot},"Couldn’t load options. Check your connection and try again."),t.createElement("button",{type:"button",className:ct,onMouseDown:e=>{e.preventDefault()},onClick:e=>{e.stopPropagation(),ue(e=>e+1),U.current?.focus()}},"Retry")):null,Kt?t.createElement("div",{className:N(Xe,Xt&&it)},t.createElement("div",{className:Ke,"aria-live":"polite"},t.createElement("span",{className:ot},$t?_t:"No results")),Xt?t.createElement("button",{type:"button",className:st,onMouseDown:e=>{e.preventDefault()},onClick:e=>{e.preventDefault(),e.stopPropagation();const t=Z.trim();!t||p||Ht||(k?.(t),J(""),M?It():U.current?.focus())}},t.createElement(S,{name:"add_circle",size:"small",className:lt,"aria-hidden":!0}),t.createElement("span",null,'Add "',qt,'"')):null):null,zt?Ut.map((e,n)=>{if("header"===e.kind)return t.createElement("div",{key:e.id,className:Ve,role:"presentation"},e.label);const{option:a}=e,r=tn[n],o=null!=r&&r===pe,i=j?Qt.some(e=>e.value===a.value):Ne&&!Array.isArray(Ne)&&a.value===Ne.value,l=j&&Jt&&!a.disabled&&!i,s=Boolean(a.avatar||a.icon),c=_o(q,n);return t.createElement("div",{key:`${c}-${e.kind}`,id:c,role:"option","aria-selected":Boolean(i),"aria-disabled":!(!a.disabled&&!l)||void 0,className:N(He,s&&ut,a.disabled&&dt,l&&mt,i&&pt,o&>),onMouseEnter:()=>{null==r||a.disabled||p||l||fe(r)},onMouseDown:e=>{a.disabled||p||l||e.preventDefault()},onClick:e=>{return t=e,void((n=a).disabled||p||(t.stopPropagation(),t.preventDefault(),gn(n)));var t,n}},s?t.createElement("span",{className:yt,"aria-hidden":!0},a.avatar?t.createElement("img",{src:a.avatar,alt:"",className:vt,draggable:!1}):a.icon?t.createElement(S,{name:a.icon,size:"medium",className:ht}):null):null,t.createElement("div",{className:bt},t.createElement("span",{className:wt},a.label),a.meta?t.createElement("span",{className:ft},a.meta):null),t.createElement("span",{className:Et},i?t.createElement(S,{name:"done",className:xt}):null))}):null)))),e&&t.createElement("input",{type:"hidden",name:e,value:j?Qt.map(e=>String(e.value)).join(","):Ne&&!Array.isArray(Ne)?String(Ne.value):""}),P&&t.createElement("p",{id:K,role:"alert",className:le},P))},Checkbox:({options:e,name:n,id:r,label:i,value:l,defaultValue:s,onChange:c,isDisabled:u=!1,isRequired:d=!1,isFluid:m=!1,orientation:p="vertical",variant:f="default",error:h="",className:g="",dataTestId:y})=>{const v=o(),b=r??n??v,w=`${b}-legend`,E=`${b}-error`,x=void 0!==l,[k,M]=a(s??[]),C=x?l:k,D=N(ee,$t,{[te]:m},g),S=N(Bt,"horizontal"===p?zt:Wt,"card"===f?Gt:"");return t.createElement("fieldset",{className:D,disabled:u,"aria-invalid":!!h||void 0,"aria-describedby":h?E:void 0,"data-invalid":h?"true":void 0,"data-variant":f,"data-testid":y},t.createElement("legend",{id:w,className:N(ae,jt)},i,d&&t.createElement(t.Fragment,null," ",t.createElement("span",{"aria-hidden":"true"},"*"))),t.createElement("div",{className:S,role:"group","aria-labelledby":w,"aria-required":d||void 0},e.map((e,a)=>{const r=e.id??`${b}-${o=e.value,null==o?"option":String(o).replace(/\W/g,"-")||"option"}-${a}`;var o;const i=e.description?`${r}-desc`:void 0,l=u||Boolean(e.isDisabled),s=C.some(t=>String(t)===String(e.value));return t.createElement("div",{key:r,className:_t},t.createElement("input",{className:N(xe,Ut),type:"checkbox",name:n,id:r,value:String(e.value),checked:s,disabled:l,"aria-invalid":!!h||void 0,"aria-describedby":[h?E:void 0,i].filter(Boolean).join(" ")||void 0,"aria-label":e.label?void 0:String(e.value),"data-testid":e.dataTestId,onChange:t=>((e,t,n)=>{const a=C,r=t?Array.from(new Set([...a,e])):a.filter(t=>String(t)!==String(e));x||M(r),c?.(r,n)})(e.value,t.target.checked,t)}),t.createElement("label",{htmlFor:r,className:N(ae,re)},t.createElement("span",{className:Xt,"aria-hidden":"true"},t.createElement("span",{className:Kt})),void 0!==e.icon&&null!==e.icon&&t.createElement("span",{className:qt,"aria-hidden":"true"},e.icon),e.label&&t.createElement("span",{className:Yt},t.createElement("span",{className:Ht},e.label),e.description&&t.createElement("span",{id:i,className:Vt},e.description))))})),h&&t.createElement("p",{id:E,role:"alert",className:le},h))},Radio:({options:e,name:n,id:r,label:i,value:l,defaultValue:s,onChange:c,isDisabled:u=!1,isRequired:d=!1,isFluid:m=!1,orientation:p="vertical",variant:f="default",error:h="",className:g="",dataTestId:y})=>{const v=o(),b=r??n??v,w=`${b}-legend`,E=`${b}-error`,x=void 0!==l,[k,M]=a(s),C=x?l:k,D=N(ee,Nt,{[te]:m},g),S=N(Mt,"horizontal"===p?Dt:Ct,"card"===f?Lt:""),P=e.findIndex(e=>!e.isDisabled&&!u);return t.createElement("fieldset",{className:D,disabled:u,"aria-invalid":!!h||void 0,"aria-describedby":h?E:void 0,"data-invalid":h?"true":void 0,"data-variant":f,"data-testid":y},t.createElement("legend",{id:w,className:N(ae,kt)},i,d&&t.createElement(t.Fragment,null," ",t.createElement("span",{"aria-hidden":"true"},"*"))),t.createElement("div",{className:S,role:"radiogroup","aria-labelledby":w,"aria-required":d||void 0},e.map((e,a)=>{const r=e.id??`${b}-${o=e.value,null==o?"option":String(o).replace(/\W/g,"-")||"option"}-${a}`;var o;const i=e.description?`${r}-desc`:void 0,l=u||Boolean(e.isDisabled),s=d&&a===P,m=void 0!==C&&String(C)===String(e.value);return t.createElement("div",{key:r,className:St},t.createElement("input",{className:N(xe,Ft),type:"radio",name:n,id:r,value:String(e.value),checked:m,disabled:l,required:s,"aria-required":s||void 0,"aria-invalid":!!h||void 0,"aria-describedby":[h?E:void 0,i].filter(Boolean).join(" ")||void 0,"aria-label":e.label?void 0:String(e.value),"data-testid":e.dataTestId,onChange:t=>((e,t)=>{x||M(e),c?.(e,t)})(e.value,t)}),t.createElement("label",{htmlFor:r,className:N(ae,re)},t.createElement("span",{className:It,"aria-hidden":"true"},t.createElement("span",{className:At})),void 0!==e.icon&&null!==e.icon&&t.createElement("span",{className:Pt,"aria-hidden":"true"},e.icon),e.label&&t.createElement("span",{className:Tt},t.createElement("span",{className:Ot},e.label),e.description&&t.createElement("span",{id:i,className:Rt},e.description))))})),h&&t.createElement("p",{id:E,role:"alert",className:le},h))},Date:({value:e,defaultValue:i=null,onChange:s,placeholder:c="Select date",dateFormat:u="MMM dd, yyyy",id:d,name:m,minDate:p,maxDate:f,disabledDates:h,disabledDaysOfWeek:y,locale:v=Jo,weekStartsOn:b=0,clearable:w=!0,isDisabled:E=!1,readOnly:x=!1,label:k="",error:M="",isFluid:C=!1,dataTestId:D,isRequired:P=!1,popoverPlacement:T="bottom-start",onOpen:O,onClose:R,className:F=""})=>{const I=o(),A=d??I,L=`${A}-label`,$=`${A}-error`,j=`${A}-trigger`,B=`${A}-date-panel`,W=`${A}-grid-caption`,z=Qi(p),_=Qi(f),q=l(()=>function(e){if(!e?.length)return;const t=[];for(const n of e){const e=Qi(n);e&&t.push(e)}return t.length?t:void 0}(h),[h]),Y=void 0===e?void 0:null===e?null:Qi(e)??null,H=void 0===i?void 0:null===i?null:Qi(i)??null,V=void 0!==e,X=q?.map(e=>Ui(e).getTime()).join("|")??"",K=y?.join(",")??"",U=l(()=>({minDate:z,maxDate:_,disabledDates:q,disabledDaysOfWeek:y}),[z?.getTime(),_?.getTime(),X,K,h,y]),G=cl({value:V?Y:void 0,defaultValue:V?void 0:H,onChange:s,constraints:U}),Q=n(G.isOpen);r(()=>{G.isOpen&&!Q.current&&O?.(),!G.isOpen&&Q.current&&R?.(),Q.current=G.isOpen},[O,R,G.isOpen]);const Z=n(G.cancel);Z.current=G.cancel,r(()=>{(E||x)&&G.isOpen&&Z.current()},[E,x,G.isOpen]);const J=function(e){const[t,n]=a(()=>"undefined"!=typeof window&&"function"==typeof window.matchMedia&&window.matchMedia(e).matches);return r(()=>{if("undefined"==typeof window||"function"!=typeof window.matchMedia)return;const t=window.matchMedia(e),a=()=>{n(t.matches)};return a(),t.addEventListener("change",a),()=>t.removeEventListener("change",a)},[e]),t}("(max-width: 768px)"),re=l(()=>J?[]:[to(4),ao({padding:8}),no({padding:8})],[J]),{refs:oe,floatingStyles:ie,context:se}=Fo({open:G.isOpen&&!E&&!x,placement:J?"bottom":T,strategy:"fixed",transform:!J,middleware:re,whileElementsMounted:J?void 0:Yr,onOpenChange(e){E||x||(e?G.open():G.isOpen&&G.cancel())}});r(()=>{if(!J)return;if(!G.isOpen)return;const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}},[J,G.isOpen]);const ce=Do(se,{enabled:!E&&!x}),ue=Oo(se,{ancestorScroll:!J,bubbles:!1,outsidePressEvent:"pointerdown"}),{getReferenceProps:de,getFloatingProps:me}=Ao([ce,ue]),pe=null!=G.committed?Wi(Ui(G.committed),u,{locale:v}):"",fe=G.isOpen,he=N($e,J&&ze,wn,J?Ge:je,!J&&Be);return t.createElement("div",{className:N(ee,{[te]:C,[ne]:E},F),"data-testid":D},k?t.createElement("label",{id:L,htmlFor:j,className:ae},k," ",P?t.createElement("span",{"aria-hidden":"true"},"*"):null):null,t.createElement("div",{className:ke,"data-invalid":M?"true":void 0},t.createElement("div",g({ref:oe.setReference},de({id:j,className:N(Ae,G.isOpen&&Le),role:"combobox",tabIndex:E||x?-1:0,"aria-expanded":G.isOpen,"aria-controls":G.isOpen?B:void 0,"aria-haspopup":"dialog","aria-labelledby":k?L:void 0,"aria-disabled":E||void 0,"aria-required":P||void 0,"aria-invalid":!!M||void 0,"aria-describedby":M?$:void 0,"aria-readonly":x||void 0,onKeyDown(e){e.defaultPrevented||E||x||("Enter"!==e.key&&" "!==e.key||(e.preventDefault(),G.isOpen||G.open()),!G.isOpen||"Escape"!==e.key&&"Esc"!==e.key||(e.preventDefault(),G.cancel()))}})),t.createElement("div",{className:Me},pe?t.createElement("span",{className:Fe},pe):t.createElement("span",{className:Ie},c)),t.createElement("div",{className:Oe},w&&G.committed&&!E&&!x?t.createElement("button",{type:"button",tabIndex:-1,className:Re,"aria-label":"Clear selection",onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:e=>{e.preventDefault(),e.stopPropagation(),E||G.clearCommitted()}},t.createElement(S,{name:"close",size:"small",color:"gray"})):null,t.createElement(S,{name:"calendar_month",size:"small",color:"gray","aria-hidden":!0}))),fe?t.createElement(No,null,J?t.createElement("div",{className:We,"data-visible":"true","aria-hidden":!0}):null,t.createElement("div",g({ref:oe.setFloating},me({id:B,role:"dialog","aria-modal":J||void 0,"aria-labelledby":k?L:void 0,className:he,style:J?ul:ie,onPointerDown:e=>{const t=e.target;t?.closest("button, input, textarea, select, a")||e.preventDefault()}})),t.createElement(ll,{panelId:B,gridLabelId:W,locale:v,weekStartsOn:b,constraints:U,picker:G}))):null),m?t.createElement("input",{type:"hidden",name:m,value:G.committed?(ge=G.committed,Wi(Ui(ge),"yyyy-MM-dd")):""}):null,M?t.createElement("p",{id:$,role:"alert",className:le},M):null);var ge},Stepper:({name:e,id:r,onChange:i,defaultValue:l,value:s,label:c="",isDisabled:u=!1,isRequired:d=!1,isFluid:m=!1,type:p="number",className:f="",placeholder:h="",error:y="",dataTestId:v,min:b,max:w,step:E=1})=>{const x=o(),k=r??e??x,M=`${k}-error`,C=n(null),D="number"===p,P=D?"text":p,T=D?"numeric":void 0,O=D?"[0-9]*":void 0,R=void 0!==s,[F,I]=a(()=>l??""),A=R?s??"":F,L=Number(E),$=Number.isFinite(L)&&L>0?L:1,j=void 0!==b?Number(b):-1/0,B=void 0!==w?Number(w):1/0,W=e=>{if(""===e||void 0===e)return null;const t=parseInt(e,10);return Number.isNaN(t)?null:t},z=N(ee,{[te]:m},f),_=y?ie:"",q=N(oe,ve,_,u?fe:""),Y=N(be,_),H=e=>{if(!D||u)return;const t=C.current;if(!t)return;let n=W(t.value);null===n&&(n=Number.isFinite(j)?j:0);const a=(r=n+e*$,Math.min(B,Math.max(j,r)));var r;a!==n?((e=>{const t=C.current;if(!t)return;const n=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value")?.set;n?.call(t,e),t.dispatchEvent(new Event("input",{bubbles:!0}))})(String(a)),t.focus()):t.focus()},V=W(A),X=void 0!==b&&null!==V&&V<=j&&Number.isFinite(j),K=void 0!==w&&null!==V&&V>=B&&Number.isFinite(B),U=y?M:void 0,G=t.createElement("input",{ref:C,className:Y,type:P,inputMode:T,pattern:O,disabled:u,required:d,"aria-required":d||void 0,"aria-invalid":!!y||void 0,"aria-describedby":U,name:e,id:k,placeholder:h,value:A,onChange:e=>{const t=e.target;if(D&&/\D/.test(t.value)){const e=t.value.replace(/\D/g,""),n=t.value.length-e.length,a=(t.selectionStart??e.length)-n;t.value=e;const r=Math.max(0,Math.min(a,e.length));((e,t,n)=>{if(dl.has(e.type))try{e.setSelectionRange(t,n)}catch{}})(t,r,r)}R||I(t.value),i?.(e)},onBeforeInput:D?e=>{if(!D)return;const t=e.nativeEvent.data;t&&/\D/.test(t)&&e.preventDefault()}:void 0,"data-testid":v});return t.createElement("div",{className:z},c&&t.createElement("label",{className:ae,htmlFor:k},c," ",d&&t.createElement("span",{"aria-hidden":"true"},"*")),D?t.createElement("div",{className:q},G,t.createElement("span",{className:we,"aria-hidden":!0}),t.createElement("button",{type:"button",className:Ee,disabled:u||X,"aria-label":"Decrease value",onClick:()=>H(-1),"data-testid":v?`${v}-decrement`:void 0},t.createElement(S,{name:"remove",size:"medium",color:"gray","aria-hidden":!0})),t.createElement("span",{className:we,"aria-hidden":!0}),t.createElement("button",{type:"button",className:Ee,disabled:u||K,"aria-label":"Increase value",onClick:()=>H(1),"data-testid":v?`${v}-increment`:void 0},t.createElement(S,{name:"add",size:"medium",color:"gray","aria-hidden":!0}))):t.createElement("input",g({className:N(oe,_),type:p,disabled:u,required:d,"aria-required":d||void 0,"aria-invalid":!!y||void 0,"aria-describedby":U,name:e,id:k,placeholder:h},void 0!==s?{value:s??""}:void 0!==l?{defaultValue:l}:{},{onChange:e=>i?.(e),"data-testid":v})),y&&t.createElement("p",{id:M,role:"alert",className:le},y))},Toggle:({name:e,id:n,onChange:r,defaultChecked:i=!1,checked:l,label:s="",isDisabled:c=!1,isRequired:u=!1,className:d="",isFluid:m=!1,error:p="",dataTestId:f})=>{const h=o(),y=n??e??h,v=`${y}-error`,b=void 0!==l,[w,E]=a(i),x=b?Boolean(l):w,k=N(ee,Qt,{[te]:m},d);return t.createElement("div",{className:k,"data-invalid":p?"true":void 0},t.createElement("div",{className:Zt},t.createElement("input",g({className:N(xe,nn),type:"checkbox",role:"switch",disabled:c,required:u,"aria-required":u||void 0,"aria-invalid":!!p||void 0,"aria-describedby":p?v:void 0,"aria-label":s?void 0:e,name:e,id:y,onChange:e=>{const t=e.target.checked;b||E(t),r?.(t)},"data-testid":f},b?{checked:x}:{defaultChecked:i})),t.createElement("label",{htmlFor:y,className:Jt},t.createElement("span",{className:en,"aria-hidden":"true"},t.createElement("span",{className:tn})),s&&t.createElement("span",null,s,u&&t.createElement(t.Fragment,null," ",t.createElement("span",{"aria-hidden":"true"},"*"))))),p&&t.createElement("p",{id:v,role:"alert",className:le},p))}},pl="dropdown-wrapper-L38Fh",fl="dropdown-trigger-Dy532",hl="active-pBlCN",gl="dropdown-floating-grA69",yl="dropdown-bottom-end-ppCny",vl="dropdown-content-7NtCD",bl="dropdown-opening-PSBid",wl="dropdown-closing-P1g7e";const El={top:"dropdown-top--mr9A","top-start":"dropdown-top-start-rPvbp","top-end":"dropdown-top-end-45Q-B",bottom:"dropdown-bottom-AicwP","bottom-start":"dropdown-bottom-start-VQQjR","bottom-end":yl,left:"dropdown-left-4iIk-","left-start":"dropdown-left-start-ytM0o","left-end":"dropdown-left-end-ouy21",right:"dropdown-right-p19EW","right-start":"dropdown-right-start-aYDFP","right-end":"dropdown-right-end-4nWiV"},xl={top:"bottom","top-start":"bottom-start","top-end":"bottom-end",bottom:"top","bottom-start":"top-start","bottom-end":"top-end",left:"right","left-start":"right-start","left-end":"right-end",right:"left","right-start":"left-start","right-end":"left-end"},Nl=({trigger:e,content:o,placement:i="bottom-end",offset:l=4,shift:s=!0,flip:u=!0,closeOnClickOutside:d=!0,closeOnEscape:m=!0,className:p="",contentClassName:f="",renderTrigger:h,triggerLabel:g})=>{const[y,v]=a(!1),[b,w]=a(!1),[E,x]=a(i),N=n(null),k=n(null),M=()=>{y?C():(v(!0),w(!0))},C=()=>{w(!1),setTimeout(()=>{v(!1),x(i)},150)};r(()=>{const e=e=>{d&&y&&k.current&&!k.current.contains(e.target)&&N.current&&!N.current.contains(e.target)&&v(!1)},t=e=>{m&&"Escape"===e.key&&y&&v(!1)};return y&&(document.addEventListener("mousedown",e),document.addEventListener("keydown",t)),()=>{document.removeEventListener("mousedown",e),document.removeEventListener("keydown",t)}},[y,d,m]),r(()=>{y&&k.current&&requestAnimationFrame(()=>{const e=(()=>{if(!N.current||!k.current)return i;N.current.getBoundingClientRect();const e=k.current.getBoundingClientRect(),t=window.innerWidth,n=window.innerHeight;let a=i;k.current&&k.current.style.setProperty("--offset",`${l}px`),u&&(e.left<8||e.right>t-8||e.top<8||e.bottom>n-8)&&(a=xl[i]??i);if(s){let a=0,r=0;e.left<8?a=8-e.left:e.right>t-8&&(a=t-8-e.right),e.top<8?r=8-e.top:e.bottom>n-8&&(r=n-8-e.bottom),k.current&&(k.current.style.setProperty("--shift-x",`${a}px`),k.current.style.setProperty("--shift-y",`${r}px`))}return a})();x(e)})},[y,i,u,s]);if(!e&&!h&&!g)throw new Error("Dropdown requires either a 'trigger' element, 'renderTrigger' function, or 'triggerLabel' string");const D=(()=>{const n={ref:N,onClick:M,className:`${fl} ${y?hl:""}`.trim(),role:"button","aria-expanded":y,"aria-haspopup":"true"};return h?h({isOpen:y,isAnimating:b,placement:E,toggle:M,close:C,triggerProps:n}):g?t.createElement("span",{ref:N,style:{display:"inline-flex"}},t.createElement(F,{variant:"outline",onClick:M,style:{display:"flex",alignItems:"center",gap:"var(--space-1)"},className:n.className,"aria-expanded":y,"aria-haspopup":"true"},g,t.createElement(S,{name:y?"keyboard_arrow_up":"keyboard_arrow_down",style:{fontSize:"16px"}}))):e?c(e,{...n,className:`${e.props.className??""} ${n.className}`.trim()}):null})(),P=c(o,{onClose:C,className:`${o.props.className??""} ${vl} ${f}`.trim()});return t.createElement("div",{className:`${pl} ${p}`},D,y&&t.createElement("div",{ref:k,className:`${gl} ${El[E]??yl} ${b?bl:wl}`,role:"menu","aria-orientation":"vertical"},P))};var kl={avatar:"avatar-9PMbK",small:"small-G0ZqH",medium:"medium-2yDpn",image:"image-Ex-Xp",icon:"icon-Fhtoo"};const Ml=({size:e="medium",margin:n="m-0",onClick:a,name:r="",image:o="",icon:i,className:l="",...s})=>{const c=((e="")=>e.split(" ").map(e=>e[0]).join("").toUpperCase().substring(0,2))(r),u=b(n,v,"m"),d=N(kl.avatar,kl[e],u,l,{[kl.image]:!!o,[kl.icon]:!!i}),m=((e="")=>`#${e.split("").reduce((e,t)=>e+t.charCodeAt(0),0).toString(16).substring(0,6)}`)(r);return t.createElement("div",g({className:d,onClick:e=>{"function"==typeof a&&a(e)},title:r,style:{backgroundColor:m}},s),!i&&o&&t.createElement("img",{src:o,alt:r}),!o&&i&&t.createElement(S,{size:"medium",name:i}),!o&&!i&&c)};var Cl="cp-media-object-PE7e4",Dl="cp-media-object-content-RoCmF",Sl="cp-media-object-media-yP5fy";const Pl=({mediaIcon:e="",mediaImage:n="",mediaAvatar:a="",title:r,description:o,margin:i="0",padding:l="0",className:s="media-object",onClick:c,...u})=>{const d=b(i,v,"m"),m=b(l,v,"p"),p=N(Cl,d,m,s),f=e=>{"function"==typeof c&&c(e)};return t.createElement("div",g({className:p,onClick:f},u),t.createElement("div",{className:Sl},t.createElement(Ml,{name:a,image:n,icon:e||void 0,onClick:c?f:void 0})),t.createElement("div",{className:Dl},t.createElement(C,{isBold:!0},r),o&&t.createElement(C,{variant:"small"},o)))};var Tl={stepper:"stepper-hM2qw","stepper-item":"stepper-item--nZ-a","stepper-link":"stepper-link-1VIxA","stepper-count":"stepper-count-L8O8v","stepper-count-icon":"stepper-count-icon-FDKjZ",separator:"separator-rMT-l",active:"active-qamu2"};const Ol=({step:e,order:n,onClick:a})=>{const r=N(Tl["stepper-item"],{[Tl.active]:e.isActive,[Tl.completed]:e.isCompleted});return t.createElement("div",{className:r},t.createElement("span",{className:Tl["stepper-count"],onClick:a},e.isCompleted?t.createElement(S,{name:"done",className:Tl["stepper-count-icon"]}):n),t.createElement("span",{className:Tl.separator}),t.createElement("a",{className:Tl["stepper-link"],onClick:a,href:e.key},e.label))},Rl=({variant:e,margin:n="0",className:a="",config:r,onClick:o})=>{const i=b(n,v,"m"),l=N(Tl.stepper,{[Tl[e??""]]:!!e},i,a);return t.createElement("div",{className:l},r.map((e,n)=>t.createElement(Ol,{key:e.key,step:e,order:n+1,onClick:t=>((e,t)=>{e.preventDefault(),"function"==typeof o&&o(t)})(t,e)})))};var Fl={"toast-container":"toast-container-auY7R",toast:"toast-nizUg",fadeIn:"fadeIn-Y8XmX",success:"success-axGeX",warning:"warning-ZmYvy",error:"error-35Ubu",info:"info-aF2Fp",icon:"icon-jNo3c"};const Il=({mode:e,onClose:n,message:a})=>{const r=l(()=>[Fl.toast,Fl[e]].join(" "),[e]),o=E(e);return t.createElement("div",{onClick:n,className:r,role:"button",tabIndex:0,onKeyDown:e=>"Enter"===e.key&&n()},t.createElement(S,{className:Fl.icon,name:o,size:"medium"}),t.createElement("div",{className:Fl.message},a))},Al=u(({autoClose:e=!1,autoCloseTime:o=5e3},i)=>{const[l,s]=a([]),c=n(l);c.current=l;const{loaded:u,portalId:m}=(()=>{const[e,t]=a(!1),[n]=a(`toast-portal-${w()}`);return r(()=>{const e=document.createElement("div");e.id=n,e.style.cssText="position: fixed; top: 16px; right: 16px";const a=document.getElementsByTagName("body")[0];if(a)return a.prepend(e),t(!0),()=>{a.removeChild(e)}},[n]),{loaded:e,portalId:n}})();(({toasts:e,setToasts:t,autoClose:n,autoCloseTime:o})=>{const[i,l]=a("");r(()=>{i&&t(e=>e.filter(e=>e.id!==i))},[i,t]),r(()=>{if(n&&e.length){const t=e[e.length-1].id,n=setTimeout(()=>l(t),o);return()=>clearTimeout(n)}},[e,n,o])})({toasts:l,setToasts:s,autoClose:e,autoCloseTime:o});if(d(i,()=>({addMessage(e){s([...c.current,{...e,id:w()}])}}),[]),!u)return null;const p=document.getElementById(m);return p?h.createPortal(t.createElement("div",{className:Fl["toast-container"]},l.map(e=>t.createElement(Il,{key:e.id,mode:e.mode,message:e.message,onClose:()=>{return t=e.id,void s(e=>e.filter(e=>e.id!==t));var t}}))),p):null});Al.displayName="Toast";var Ll="cp-page-header-uXFX0",$l="cp-page-header__row-ZULep",jl="cp-page-header__left-h21VP",Bl="cp-page-header__title-FZ9-0",Wl="cp-page-header__subtitle-v5qVs",zl="cp-page-header__right-OtOV7",_l="cp-page-header__cta-mMff6",ql="cp-page-header__more-wDsIy",Yl="cp-page-header__more-trigger--NnJT",Hl="cp-page-header__more-list-JaQ10",Vl="cp-page-header__more-item-827wH";const Xl=({items:e,onClose:n,className:a})=>t.createElement("ul",{className:a,role:"menu"},e.map((e,a)=>t.createElement("li",{key:a,role:"none"},t.createElement("button",{type:"button",role:"menuitem",className:Vl,onClick:()=>{e.onClick?.(),n?.()}},e.label)))),Kl=({title:e,subtitle:n,primaryCta:a,moreMenuItems:r,moreMenuContent:o,className:i=""})=>{const l=(r?.length??0)>0||null!=o,s=N(Ll,i),c=({triggerProps:e})=>t.createElement("span",{ref:e.ref,style:{display:"inline-flex"}},t.createElement(F,{variant:"icon",size:"small",className:N(Yl,e.className),onClick:e.onClick},t.createElement(S,{name:"more_vert",size:"small"})));return t.createElement("header",{className:s},t.createElement("div",{className:$l},t.createElement("div",{className:jl},"string"==typeof e?t.createElement(C,{variant:"h4",className:Bl},e):t.createElement("div",{className:Bl},e),null!=n&&t.createElement(t.Fragment,null,"string"==typeof n?t.createElement(C,{variant:"p",className:Wl},n):t.createElement("div",{className:Wl},n))),t.createElement("div",{className:zl},null!=a&&t.createElement("div",{className:_l},a),l&&t.createElement("div",{className:ql},null!=r&&r.length>0?t.createElement(Nl,{placement:"bottom-end",content:t.createElement(Xl,{items:r,className:Hl}),renderTrigger:c}):null!=o?t.createElement(Nl,{placement:"bottom-end",content:t.createElement("div",{className:Hl},o),renderTrigger:c}):null))))};Kl.displayName="PageHeader";var Ul="cp-breadcrumb-n7jGG",Gl="cp-breadcrumb__list-IN6yA",Ql="cp-breadcrumb__item-RiJzG",Zl="cp-breadcrumb__link-5w7RA",Jl="cp-breadcrumb__current-JduVv",es="cp-breadcrumb__label-ofOpE",ts="cp-breadcrumb__separator-KvPMy",ns="cp-breadcrumb__separator-icon-ey1xq",as="cp-breadcrumb_separator-slash-kqkp0";const rs=({items:e,separator:n="chevron",ariaLabel:a="Breadcrumb",margin:r,className:o=""})=>{const i=r?b(r,v,"m"):void 0,l=N(Ul,"slash"===n&&as,i,o);return t.createElement("nav",{className:l,"aria-label":a},t.createElement("ol",{className:Gl,itemScope:!0,itemType:"https://schema.org/BreadcrumbList"},e.map((a,r)=>{const o=r===e.length-1&&null==a.href;return t.createElement("li",{key:r,className:Ql,itemProp:"itemListElement",itemScope:!0,itemType:"https://schema.org/ListItem"},r>0&&t.createElement("span",{className:ts,"aria-hidden":"true"},"chevron"===n?t.createElement(S,{name:"chevron_right",size:"small",className:ns}):"/"),o?t.createElement("span",{className:Jl,"aria-current":"page",itemProp:"name"},a.label):a.href?t.createElement("a",{href:a.href,className:Zl,itemProp:"item"},t.createElement("span",{itemProp:"name"},a.label)):t.createElement("span",{className:es,itemProp:"name"},a.label),t.createElement("meta",{itemProp:"position",content:String(r+1)}))})))};function os(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}rs.displayName="BreadCrumb";var is,ls={exports:{}},ss={exports:{}},cs={};var us,ds,ms,ps,fs,hs,gs,ys,vs,bs,ws,Es,xs,Ns,ks={};
|
|
5
|
+
*/var Va=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"].join(","),Xa="undefined"==typeof Element,Ka=Xa?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Ua=!Xa&&Element.prototype.getRootNode?function(e){var t;return null==e||null===(t=e.getRootNode)||void 0===t?void 0:t.call(e)}:function(e){return null==e?void 0:e.ownerDocument},Ga=function e(t,n){var a;void 0===n&&(n=!0);var r=null==t||null===(a=t.getAttribute)||void 0===a?void 0:a.call(t,"inert");return""===r||"true"===r||n&&t&&e(t.parentNode)},Qa=function e(t,n,a){for(var r=[],o=Array.from(t);o.length;){var i=o.shift();if(!Ga(i,!1))if("SLOT"===i.tagName){var l=i.assignedElements(),s=e(l.length?l:i.children,!0,a);a.flatten?r.push.apply(r,s):r.push({scopeParent:i,candidates:s})}else{Ka.call(i,Va)&&a.filter(i)&&(n||!t.includes(i))&&r.push(i);var c=i.shadowRoot||"function"==typeof a.getShadowRoot&&a.getShadowRoot(i),u=!Ga(c,!1)&&(!a.shadowRootFilter||a.shadowRootFilter(i));if(c&&u){var d=e(!0===c?i.children:c.children,!0,a);a.flatten?r.push.apply(r,d):r.push({scopeParent:i,candidates:d})}else o.unshift.apply(o,i.children)}}return r},Za=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},Ja=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||function(e){var t,n=null==e||null===(t=e.getAttribute)||void 0===t?void 0:t.call(e,"contenteditable");return""===n||"true"===n}(e))&&!Za(e)?0:e.tabIndex},er=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},tr=function(e){return"INPUT"===e.tagName},nr=function(e){return function(e){return tr(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t,n=e.form||Ua(e),a=function(e){return n.querySelectorAll('input[type="radio"][name="'+e+'"]')};if("undefined"!=typeof window&&void 0!==window.CSS&&"function"==typeof window.CSS.escape)t=a(window.CSS.escape(e.name));else try{t=a(e.name)}catch(e){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",e.message),!1}var r=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]}(t,e.form);return!r||r===e}(e)},ar=function(e){var t=e.getBoundingClientRect(),n=t.width,a=t.height;return 0===n&&0===a},rr=function(e,t){var n=t.displayCheck,a=t.getShadowRoot;if("hidden"===getComputedStyle(e).visibility)return!0;var r=Ka.call(e,"details>summary:first-of-type")?e.parentElement:e;if(Ka.call(r,"details:not([open]) *"))return!0;if(n&&"full"!==n&&"legacy-full"!==n){if("non-zero-area"===n)return ar(e)}else{if("function"==typeof a){for(var o=e;e;){var i=e.parentElement,l=Ua(e);if(i&&!i.shadowRoot&&!0===a(i))return ar(e);e=e.assignedSlot?e.assignedSlot:i||l===e.ownerDocument?i:l.host}e=o}if(function(e){var t,n,a,r,o=e&&Ua(e),i=null===(t=o)||void 0===t?void 0:t.host,l=!1;if(o&&o!==e)for(l=!!(null!==(n=i)&&void 0!==n&&null!==(a=n.ownerDocument)&&void 0!==a&&a.contains(i)||null!=e&&null!==(r=e.ownerDocument)&&void 0!==r&&r.contains(e));!l&&i;){var s,c,u;l=!(null===(c=i=null===(s=o=Ua(i))||void 0===s?void 0:s.host)||void 0===c||null===(u=c.ownerDocument)||void 0===u||!u.contains(i))}return l}(e))return!e.getClientRects().length;if("legacy-full"!==n)return!0}return!1},or=function(e,t){return!(t.disabled||Ga(t)||function(e){return tr(e)&&"hidden"===e.type}(t)||rr(t,e)||function(e){return"DETAILS"===e.tagName&&Array.prototype.slice.apply(e.children).some(function(e){return"SUMMARY"===e.tagName})}(t)||function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if("FIELDSET"===t.tagName&&t.disabled){for(var n=0;n<t.children.length;n++){var a=t.children.item(n);if("LEGEND"===a.tagName)return!!Ka.call(t,"fieldset[disabled] *")||!a.contains(e)}return!0}t=t.parentElement}return!1}(t))},ir=function(e,t){return!(nr(t)||Ja(t)<0||!or(e,t))},lr=function(e){var t=parseInt(e.getAttribute("tabindex"),10);return!!(isNaN(t)||t>=0)},sr=function e(t){var n=[],a=[];return t.forEach(function(t,r){var o=!!t.scopeParent,i=o?t.scopeParent:t,l=function(e,t){var n=Ja(e);return n<0&&t&&!Za(e)?0:n}(i,o),s=o?e(t.candidates):i;0===l?o?n.push.apply(n,s):n.push(i):a.push({documentOrder:r,tabIndex:l,item:t,isScope:o,content:s})}),a.sort(er).reduce(function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e},[]).concat(n)},cr=function(e,t){var n;return n=(t=t||{}).getShadowRoot?Qa([e],t.includeContainer,{filter:ir.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:lr}):function(e,t,n){if(Ga(e))return[];var a=Array.prototype.slice.apply(e.querySelectorAll(Va));return t&&Ka.call(e,Va)&&a.unshift(e),a.filter(n)}(e,t.includeContainer,ir.bind(null,t)),sr(n)};function ur(e,t){if(!e||!t)return!1;const n=null==t.getRootNode?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&na(n)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function dr(e){return"composedPath"in e?e.composedPath()[0]:e.target}function mr(e,t){if(null==t)return!1;if("composedPath"in e)return e.composedPath().includes(t);const n=e;return null!=n.target&&t.contains(n.target)}function pr(e){return(null==e?void 0:e.ownerDocument)||document}function fr(e,t,n){void 0===n&&(n=!0);return e.filter(e=>{var a;return e.parentId===t&&(!n||(null==(a=e.context)?void 0:a.open))}).flatMap(t=>[t,...fr(e,t.id,n)])}function hr(e,t){return["mouse","pen"].includes(e)}var gr="undefined"!=typeof document?i:function(){};const yr={...e}.useInsertionEffect||(e=>e());function vr(t){const n=e.useRef(()=>{if("production"!==process.env.NODE_ENV)throw new Error("Cannot call an event handler while rendering.")});return yr(()=>{n.current=t}),e.useCallback(function(){for(var e=arguments.length,t=new Array(e),a=0;a<e;a++)t[a]=arguments[a];return null==n.current?void 0:n.current(...t)},[])}const br=()=>({getShadowRoot:!0,displayCheck:"function"==typeof ResizeObserver&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function wr(e,t){const n=cr(e,br()),a=n.length;if(0===a)return;const r=function(e){let t=e.activeElement;for(;null!=(null==(n=t)||null==(n=n.shadowRoot)?void 0:n.activeElement);){var n;t=t.shadowRoot.activeElement}return t}(pr(e)),o=n.indexOf(r);return n[-1===o?1===t?0:a-1:o+t]}function Er(e,t){const n=t||e.currentTarget,a=e.relatedTarget;return!a||!ur(n,a)}function xr(e){cr(e,br()).forEach(e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")})}function Nr(e){e.querySelectorAll("[data-tabindex]").forEach(e=>{const t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")})}function kr(e,t,n){let{reference:a,floating:r}=e;const o=La(t),i=$a(t),l=Ia(i),s=Oa(t),c="y"===o,u=a.x+a.width/2-r.width/2,d=a.y+a.height/2-r.height/2,m=a[l]/2-r[l]/2;let p;switch(s){case"top":p={x:u,y:a.y-r.height};break;case"bottom":p={x:u,y:a.y+a.height};break;case"right":p={x:a.x+a.width,y:d};break;case"left":p={x:a.x-r.width,y:d};break;default:p={x:a.x,y:a.y}}switch(Ra(t)){case"start":p[i]-=m*(n&&c?-1:1);break;case"end":p[i]+=m*(n&&c?-1:1)}return p}async function Mr(e,t){var n;void 0===t&&(t={});const{x:a,y:r,platform:o,rects:i,elements:l,strategy:s}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:m=!1,padding:p=0}=Ta(t,e),f=function(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}(p),h=l[m?"floating"===d?"reference":"floating":d],g=Ha(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(h)))||n?h:h.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(l.floating)),boundary:c,rootBoundary:u,strategy:s})),y="floating"===d?{x:a,y:r,width:i.floating.width,height:i.floating.height}:i.reference,v=await(null==o.getOffsetParent?void 0:o.getOffsetParent(l.floating)),b=await(null==o.isElement?void 0:o.isElement(v))&&await(null==o.getScale?void 0:o.getScale(v))||{x:1,y:1},w=Ha(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:y,offsetParent:v,strategy:s}):y);return{top:(g.top-w.top+f.top)/b.y,bottom:(w.bottom-g.bottom+f.bottom)/b.y,left:(g.left-w.left+f.left)/b.x,right:(w.right-g.right+f.right)/b.x}}const Cr=new Set(["left","top"]);function Dr(e){const t=ga(e);let n=parseFloat(t.width)||0,a=parseFloat(t.height)||0;const r=ta(e),o=r?e.offsetWidth:n,i=r?e.offsetHeight:a,l=ka(n)!==o||ka(a)!==i;return l&&(n=o,a=i),{width:n,height:a,$:l}}function Sr(e){return ea(e)?e:e.contextElement}function Pr(e){const t=Sr(e);if(!ta(t))return Ca(1);const n=t.getBoundingClientRect(),{width:a,height:r,$:o}=Dr(t);let i=(o?ka(n.width):n.width)/a,l=(o?ka(n.height):n.height)/r;return i&&Number.isFinite(i)||(i=1),l&&Number.isFinite(l)||(l=1),{x:i,y:l}}const Tr=Ca(0);function Or(e){const t=Qn(e);return pa()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Tr}function Rr(e,t,n,a){void 0===t&&(t=!1),void 0===n&&(n=!1);const r=e.getBoundingClientRect(),o=Sr(e);let i=Ca(1);t&&(a?ea(a)&&(i=Pr(a)):i=Pr(e));const l=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==Qn(e))&&t}(o,n,a)?Or(o):Ca(0);let s=(r.left+l.x)/i.x,c=(r.top+l.y)/i.y,u=r.width/i.x,d=r.height/i.y;if(o){const e=Qn(o),t=a&&ea(a)?Qn(a):a;let n=e,r=Ea(n);for(;r&&a&&t!==n;){const e=Pr(r),t=r.getBoundingClientRect(),a=ga(r),o=t.left+(r.clientLeft+parseFloat(a.paddingLeft))*e.x,i=t.top+(r.clientTop+parseFloat(a.paddingTop))*e.y;s*=e.x,c*=e.y,u*=e.x,d*=e.y,s+=o,c+=i,n=Qn(r),r=Ea(n)}}return Ha({width:u,height:d,x:s,y:c})}function Fr(e,t){const n=ya(e).scrollLeft;return t?t.left+n:Rr(Zn(e)).left+n}function Ir(e,t){const n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Fr(e,n),y:n.top+t.scrollTop}}const Ar=new Set(["absolute","fixed"]);function Lr(e,t,n){let a;if("viewport"===t)a=function(e,t){const n=Qn(e),a=Zn(e),r=n.visualViewport;let o=a.clientWidth,i=a.clientHeight,l=0,s=0;if(r){o=r.width,i=r.height;const e=pa();(!e||e&&"fixed"===t)&&(l=r.offsetLeft,s=r.offsetTop)}const c=Fr(a);if(c<=0){const e=a.ownerDocument,t=e.body,n=getComputedStyle(t),r="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(a.clientWidth-t.clientWidth-r);i<=25&&(o-=i)}else c<=25&&(o+=c);return{width:o,height:i,x:l,y:s}}(e,n);else if("document"===t)a=function(e){const t=Zn(e),n=ya(e),a=e.ownerDocument.body,r=Na(t.scrollWidth,t.clientWidth,a.scrollWidth,a.clientWidth),o=Na(t.scrollHeight,t.clientHeight,a.scrollHeight,a.clientHeight);let i=-n.scrollLeft+Fr(e);const l=-n.scrollTop;return"rtl"===ga(a).direction&&(i+=Na(t.clientWidth,a.clientWidth)-r),{width:r,height:o,x:i,y:l}}(Zn(e));else if(ea(t))a=function(e,t){const n=Rr(e,!0,"fixed"===t),a=n.top+e.clientTop,r=n.left+e.clientLeft,o=ta(e)?Pr(e):Ca(1);return{width:e.clientWidth*o.x,height:e.clientHeight*o.y,x:r*o.x,y:a*o.y}}(t,n);else{const n=Or(e);a={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Ha(a)}function $r(e,t){const n=va(e);return!(n===t||!ea(n)||ha(n))&&("fixed"===ga(n).position||$r(n,t))}function jr(e,t,n){const a=ta(t),r=Zn(t),o="fixed"===n,i=Rr(e,!0,o,t);let l={scrollLeft:0,scrollTop:0};const s=Ca(0);function c(){s.x=Fr(r)}if(a||!a&&!o)if(("body"!==Gn(t)||ra(r))&&(l=ya(t)),a){const e=Rr(t,!0,o,t);s.x=e.x+t.clientLeft,s.y=e.y+t.clientTop}else r&&c();o&&!a&&r&&c();const u=!r||a||o?Ca(0):Ir(r,l);return{x:i.left+l.scrollLeft-s.x-u.x,y:i.top+l.scrollTop-s.y-u.y,width:i.width,height:i.height}}function Br(e){return"static"===ga(e).position}function Wr(e,t){if(!ta(e)||"fixed"===ga(e).position)return null;if(t)return t(e);let n=e.offsetParent;return Zn(e)===n&&(n=n.ownerDocument.body),n}function zr(e,t){const n=Qn(e);if(sa(e))return n;if(!ta(e)){let t=va(e);for(;t&&!ha(t);){if(ea(t)&&!Br(t))return t;t=va(t)}return n}let a=Wr(e,t);for(;a&&ia(a)&&Br(a);)a=Wr(a,t);return a&&ha(a)&&Br(a)&&!ma(a)?n:a||function(e){let t=va(e);for(;ta(t)&&!ha(t);){if(ma(t))return t;if(sa(t))return null;t=va(t)}return null}(e)||n}const _r={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:a,strategy:r}=e;const o="fixed"===r,i=Zn(a),l=!!t&&sa(t.floating);if(a===i||l&&o)return n;let s={scrollLeft:0,scrollTop:0},c=Ca(1);const u=Ca(0),d=ta(a);if((d||!d&&!o)&&(("body"!==Gn(a)||ra(i))&&(s=ya(a)),ta(a))){const e=Rr(a);c=Pr(a),u.x=e.x+a.clientLeft,u.y=e.y+a.clientTop}const m=!i||d||o?Ca(0):Ir(i,s);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-s.scrollLeft*c.x+u.x+m.x,y:n.y*c.y-s.scrollTop*c.y+u.y+m.y}},getDocumentElement:Zn,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:a,strategy:r}=e;const o=[..."clippingAncestors"===n?sa(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let a=wa(e,[],!1).filter(e=>ea(e)&&"body"!==Gn(e)),r=null;const o="fixed"===ga(e).position;let i=o?va(e):e;for(;ea(i)&&!ha(i);){const t=ga(i),n=ma(i);n||"fixed"!==t.position||(r=null),(o?!n&&!r:!n&&"static"===t.position&&r&&Ar.has(r.position)||ra(i)&&!n&&$r(e,i))?a=a.filter(e=>e!==i):r=t,i=va(i)}return t.set(e,a),a}(t,this._c):[].concat(n),a],i=o[0],l=o.reduce((e,n)=>{const a=Lr(t,n,r);return e.top=Na(a.top,e.top),e.right=xa(a.right,e.right),e.bottom=xa(a.bottom,e.bottom),e.left=Na(a.left,e.left),e},Lr(t,i,r));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},getOffsetParent:zr,getElementRects:async function(e){const t=this.getOffsetParent||zr,n=this.getDimensions,a=await n(e.floating);return{reference:jr(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:a.width,height:a.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=Dr(e);return{width:t,height:n}},getScale:Pr,isElement:ea,isRTL:function(e){return"rtl"===ga(e).direction}};function qr(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Yr(e,t,n,a){void 0===a&&(a={});const{ancestorScroll:r=!0,ancestorResize:o=!0,elementResize:i="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:s=!1}=a,c=Sr(e),u=r||o?[...c?wa(c):[],...wa(t)]:[];u.forEach(e=>{r&&e.addEventListener("scroll",n,{passive:!0}),o&&e.addEventListener("resize",n)});const d=c&&l?function(e,t){let n,a=null;const r=Zn(e);function o(){var e;clearTimeout(n),null==(e=a)||e.disconnect(),a=null}return function i(l,s){void 0===l&&(l=!1),void 0===s&&(s=1),o();const c=e.getBoundingClientRect(),{left:u,top:d,width:m,height:p}=c;if(l||t(),!m||!p)return;const f={rootMargin:-Ma(d)+"px "+-Ma(r.clientWidth-(u+m))+"px "+-Ma(r.clientHeight-(d+p))+"px "+-Ma(u)+"px",threshold:Na(0,xa(1,s))||1};let h=!0;function g(t){const a=t[0].intersectionRatio;if(a!==s){if(!h)return i();a?i(!1,a):n=setTimeout(()=>{i(!1,1e-7)},1e3)}1!==a||qr(c,e.getBoundingClientRect())||i(),h=!1}try{a=new IntersectionObserver(g,{...f,root:r.ownerDocument})}catch(e){a=new IntersectionObserver(g,f)}a.observe(e)}(!0),o}(c,n):null;let m,p=-1,f=null;i&&(f=new ResizeObserver(e=>{let[a]=e;a&&a.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var e;null==(e=f)||e.observe(t)})),n()}),c&&!s&&f.observe(c),f.observe(t));let h=s?Rr(e):null;return s&&function t(){const a=Rr(e);h&&!qr(h,a)&&n();h=a,m=requestAnimationFrame(t)}(),n(),()=>{var e;u.forEach(e=>{r&&e.removeEventListener("scroll",n),o&&e.removeEventListener("resize",n)}),null==d||d(),null==(e=f)||e.disconnect(),f=null,s&&cancelAnimationFrame(m)}}const Hr=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,a;const{x:r,y:o,placement:i,middlewareData:l}=t,s=await async function(e,t){const{placement:n,platform:a,elements:r}=e,o=await(null==a.isRTL?void 0:a.isRTL(r.floating)),i=Oa(n),l=Ra(n),s="y"===La(n),c=Cr.has(i)?-1:1,u=o&&s?-1:1,d=Ta(t,e);let{mainAxis:m,crossAxis:p,alignmentAxis:f}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return l&&"number"==typeof f&&(p="end"===l?-1*f:f),s?{x:p*u,y:m*c}:{x:m*c,y:p*u}}(t,e);return i===(null==(n=l.offset)?void 0:n.placement)&&null!=(a=l.arrow)&&a.alignmentOffset?{}:{x:r+s.x,y:o+s.y,data:{...s,placement:i}}}}},Vr=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:a,placement:r}=t,{mainAxis:o=!0,crossAxis:i=!1,limiter:l={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...s}=Ta(e,t),c={x:n,y:a},u=await Mr(t,s),d=La(Oa(r)),m=Fa(d);let p=c[m],f=c[d];if(o){const e="y"===m?"bottom":"right";p=Pa(p+u["y"===m?"top":"left"],p,p-u[e])}if(i){const e="y"===d?"bottom":"right";f=Pa(f+u["y"===d?"top":"left"],f,f-u[e])}const h=l.fn({...t,[m]:p,[d]:f});return{...h,data:{x:h.x-n,y:h.y-a,enabled:{[m]:o,[d]:i}}}}}},Xr=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,a;const{placement:r,middlewareData:o,rects:i,initialPlacement:l,platform:s,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:m,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:h=!0,...g}=Ta(e,t);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const y=Oa(r),v=La(l),b=Oa(l)===l,w=await(null==s.isRTL?void 0:s.isRTL(c.floating)),E=m||(b||!h?[Ya(l)]:function(e){const t=Ya(e);return[ja(e),t,ja(t)]}(l)),x="none"!==f;!m&&x&&E.push(...qa(l,h,f,w));const N=[l,...E],k=await Mr(t,g),M=[];let C=(null==(a=o.flip)?void 0:a.overflows)||[];if(u&&M.push(k[y]),d){const e=function(e,t,n){void 0===n&&(n=!1);const a=Ra(e),r=$a(e),o=Ia(r);let i="x"===r?a===(n?"end":"start")?"right":"left":"start"===a?"bottom":"top";return t.reference[o]>t.floating[o]&&(i=Ya(i)),[i,Ya(i)]}(r,i,w);M.push(k[e[0]],k[e[1]])}if(C=[...C,{placement:r,overflows:M}],!M.every(e=>e<=0)){var D,S;const e=((null==(D=o.flip)?void 0:D.index)||0)+1,t=N[e];if(t){if(!("alignment"===d&&v!==La(t))||C.every(e=>La(e.placement)!==v||e.overflows[0]>0))return{data:{index:e,overflows:C},reset:{placement:t}}}let n=null==(S=C.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:S.placement;if(!n)switch(p){case"bestFit":{var P;const e=null==(P=C.filter(e=>{if(x){const t=La(e.placement);return t===v||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:P[0];e&&(n=e);break}case"initialPlacement":n=l}if(r!==n)return{reset:{placement:n}}}return{}}}},Kr=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,a;const{placement:r,rects:o,platform:i,elements:l}=t,{apply:s=()=>{},...c}=Ta(e,t),u=await Mr(t,c),d=Oa(r),m=Ra(r),p="y"===La(r),{width:f,height:h}=o.floating;let g,y;"top"===d||"bottom"===d?(g=d,y=m===(await(null==i.isRTL?void 0:i.isRTL(l.floating))?"start":"end")?"left":"right"):(y=d,g="end"===m?"top":"bottom");const v=h-u.top-u.bottom,b=f-u.left-u.right,w=xa(h-u[g],v),E=xa(f-u[y],b),x=!t.middlewareData.shift;let N=w,k=E;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(k=b),null!=(a=t.middlewareData.shift)&&a.enabled.y&&(N=v),x&&!m){const e=Na(u.left,0),t=Na(u.right,0),n=Na(u.top,0),a=Na(u.bottom,0);p?k=f-2*(0!==e||0!==t?e+t:Na(u.left,u.right)):N=h-2*(0!==n||0!==a?n+a:Na(u.top,u.bottom))}await s({...t,availableWidth:k,availableHeight:N});const M=await i.getDimensions(l.floating);return f!==M.width||h!==M.height?{reset:{rects:!0}}:{}}}},Ur=(e,t,n)=>{const a=new Map,r={platform:_r,...n},o={...r.platform,_c:a};return(async(e,t,n)=>{const{placement:a="bottom",strategy:r="absolute",middleware:o=[],platform:i}=n,l=o.filter(Boolean),s=await(null==i.isRTL?void 0:i.isRTL(t));let c=await i.getElementRects({reference:e,floating:t,strategy:r}),{x:u,y:d}=kr(c,a,s),m=a,p={},f=0;for(let n=0;n<l.length;n++){const{name:o,fn:h}=l[n],{x:g,y:y,data:v,reset:b}=await h({x:u,y:d,initialPlacement:a,placement:m,strategy:r,middlewareData:p,rects:c,platform:i,elements:{reference:e,floating:t}});u=null!=g?g:u,d=null!=y?y:d,p={...p,[o]:{...p[o],...v}},b&&f<=50&&(f++,"object"==typeof b&&(b.placement&&(m=b.placement),b.rects&&(c=!0===b.rects?await i.getElementRects({reference:e,floating:t,strategy:r}):b.rects),({x:u,y:d}=kr(c,m,s))),n=-1)}return{x:u,y:d,placement:m,strategy:r,middlewareData:p}})(e,t,{...r,platform:o})};var Gr="undefined"!=typeof document?i:function(){};function Qr(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,a,r;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(a=n;0!==a--;)if(!Qr(e[a],t[a]))return!1;return!0}if(r=Object.keys(e),n=r.length,n!==Object.keys(t).length)return!1;for(a=n;0!==a--;)if(!{}.hasOwnProperty.call(t,r[a]))return!1;for(a=n;0!==a--;){const n=r[a];if(("_owner"!==n||!e.$$typeof)&&!Qr(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function Zr(e){if("undefined"==typeof window)return 1;return(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Jr(e,t){const n=Zr(e);return Math.round(t*n)/n}function eo(t){const n=e.useRef(t);return Gr(()=>{n.current=t}),n}const to=(e,t)=>({...Hr(e),options:[e,t]}),no=(e,t)=>({...Vr(e),options:[e,t]}),ao=(e,t)=>({...Xr(e),options:[e,t]}),ro=(e,t)=>({...Kr(e),options:[e,t]}),oo="data-floating-ui-focusable",io="active",lo="selected",so={...e};let co=!1,uo=0;const mo=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+uo++;const po=so.useId||function(){const[t,n]=e.useState(()=>co?mo():void 0);return gr(()=>{null==t&&n(mo())},[]),e.useEffect(()=>{co=!0},[]),t};let fo;"production"!==process.env.NODE_ENV&&(fo=new Set);const ho=e.createContext(null),go=e.createContext(null),yo=()=>e.useContext(go);function vo(e){return"data-floating-ui-"+e}const bo={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0},wo=e.forwardRef(function(t,n){const[a,r]=e.useState();gr(()=>{/apple/i.test(navigator.vendor)&&r("button")},[]);const o={ref:n,tabIndex:0,role:a,"aria-hidden":!a||void 0,[vo("focus-guard")]:"",style:bo};return p("span",{...t,...o})}),Eo=e.createContext(null),xo=vo("portal");function No(t){const{children:n,id:a,root:r,preserveTabOrder:o=!0}=t,i=function(t){void 0===t&&(t={});const{id:n,root:a}=t,r=po(),o=ko(),[i,l]=e.useState(null),s=e.useRef(null);return gr(()=>()=>{null==i||i.remove(),queueMicrotask(()=>{s.current=null})},[i]),gr(()=>{if(!r)return;if(s.current)return;const e=n?document.getElementById(n):null;if(!e)return;const t=document.createElement("div");t.id=r,t.setAttribute(xo,""),e.appendChild(t),s.current=t,l(t)},[n,r]),gr(()=>{if(null===a)return;if(!r)return;if(s.current)return;let e=a||(null==o?void 0:o.portalNode);e&&!Jn(e)&&(e=e.current),e=e||document.body;let t=null;n&&(t=document.createElement("div"),t.id=n,e.appendChild(t));const i=document.createElement("div");i.id=r,i.setAttribute(xo,""),e=t||e,e.appendChild(i),s.current=i,l(i)},[n,a,r,o]),i}({id:a,root:r}),[l,s]=e.useState(null),c=e.useRef(null),u=e.useRef(null),d=e.useRef(null),h=e.useRef(null),g=null==l?void 0:l.modal,y=null==l?void 0:l.open,v=!!l&&!l.modal&&l.open&&o&&!(!r&&!i);return e.useEffect(()=>{if(i&&o&&!g)return i.addEventListener("focusin",e,!0),i.addEventListener("focusout",e,!0),()=>{i.removeEventListener("focusin",e,!0),i.removeEventListener("focusout",e,!0)};function e(e){if(i&&Er(e)){("focusin"===e.type?Nr:xr)(i)}}},[i,o,g]),e.useEffect(()=>{i&&(y||Nr(i))},[y,i]),m(Eo.Provider,{value:e.useMemo(()=>({preserveTabOrder:o,beforeOutsideRef:c,afterOutsideRef:u,beforeInsideRef:d,afterInsideRef:h,portalNode:i,setFocusManagerState:s}),[o,i]),children:[v&&i&&p(wo,{"data-type":"outside",ref:c,onFocus:e=>{if(Er(e,i)){var t;null==(t=d.current)||t.focus()}else{const e=l?l.domReference:null,t=wr(pr(n=e).body,-1)||n;null==t||t.focus()}var n}}),v&&i&&p("span",{"aria-owns":i.id,style:bo}),i&&f.createPortal(n,i),v&&i&&p(wo,{"data-type":"outside",ref:u,onFocus:e=>{if(Er(e,i)){var t;null==(t=h.current)||t.focus()}else{const t=l?l.domReference:null,a=wr(pr(n=t).body,1)||n;null==a||a.focus(),(null==l?void 0:l.closeOnFocusOut)&&(null==l||l.onOpenChange(!1,e.nativeEvent,"focus-out"))}var n}})]})}const ko=()=>e.useContext(Eo);function Mo(e){return ta(e.target)&&"BUTTON"===e.target.tagName}function Co(e){return function(e){return ta(e)&&e.matches("input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])")}(e)}function Do(t,n){void 0===n&&(n={});const{open:a,onOpenChange:r,dataRef:o,elements:{domReference:i}}=t,{enabled:l=!0,event:s="click",toggle:c=!0,ignoreMouse:u=!1,keyboardHandlers:d=!0,stickIfOpen:m=!0}=n,p=e.useRef(),f=e.useRef(!1),h=e.useMemo(()=>({onPointerDown(e){p.current=e.pointerType},onMouseDown(e){const t=p.current;0===e.button&&"click"!==s&&(hr(t)&&u||(!a||!c||o.current.openEvent&&m&&"mousedown"!==o.current.openEvent.type?(e.preventDefault(),r(!0,e.nativeEvent,"click")):r(!1,e.nativeEvent,"click")))},onClick(e){const t=p.current;"mousedown"===s&&p.current?p.current=void 0:hr(t)&&u||(!a||!c||o.current.openEvent&&m&&"click"!==o.current.openEvent.type?r(!0,e.nativeEvent,"click"):r(!1,e.nativeEvent,"click"))},onKeyDown(e){p.current=void 0,e.defaultPrevented||!d||Mo(e)||(" "!==e.key||Co(i)||(e.preventDefault(),f.current=!0),function(e){return ta(e.target)&&"A"===e.target.tagName}(e)||"Enter"===e.key&&r(!a||!c,e.nativeEvent,"click"))},onKeyUp(e){e.defaultPrevented||!d||Mo(e)||Co(i)||" "===e.key&&f.current&&(f.current=!1,r(!a||!c,e.nativeEvent,"click"))}}),[o,i,s,u,d,r,a,m,c]);return e.useMemo(()=>l?{reference:h}:{},[l,h])}const So={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},Po={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},To=e=>{var t,n;return{escapeKey:"boolean"==typeof e?e:null!=(t=null==e?void 0:e.escapeKey)&&t,outsidePress:"boolean"==typeof e?e:null==(n=null==e?void 0:e.outsidePress)||n}};function Oo(t,n){void 0===n&&(n={});const{open:a,onOpenChange:r,elements:o,dataRef:i}=t,{enabled:l=!0,escapeKey:s=!0,outsidePress:c=!0,outsidePressEvent:u="pointerdown",referencePress:d=!1,referencePressEvent:m="pointerdown",ancestorScroll:p=!1,bubbles:f,capture:h}=n,g=yo(),y=vr("function"==typeof c?c:()=>!1),v="function"==typeof c?y:c,b=e.useRef(!1),{escapeKey:w,outsidePress:E}=To(f),{escapeKey:x,outsidePress:N}=To(h),k=e.useRef(!1),M=vr(e=>{var t;if(!a||!l||!s||"Escape"!==e.key)return;if(k.current)return;const n=null==(t=i.current.floatingContext)?void 0:t.nodeId,o=g?fr(g.nodesRef.current,n):[];if(!w&&(e.stopPropagation(),o.length>0)){let e=!0;if(o.forEach(t=>{var n;null==(n=t.context)||!n.open||t.context.dataRef.current.__escapeKeyBubbles||(e=!1)}),!e)return}r(!1,function(e){return"nativeEvent"in e}(e)?e.nativeEvent:e,"escape-key")}),C=vr(e=>{var t;const n=()=>{var t;M(e),null==(t=dr(e))||t.removeEventListener("keydown",n)};null==(t=dr(e))||t.addEventListener("keydown",n)}),D=vr(e=>{var t;const n=i.current.insideReactTree;i.current.insideReactTree=!1;const a=b.current;if(b.current=!1,"click"===u&&a)return;if(n)return;if("function"==typeof v&&!v(e))return;const l=dr(e),s="["+vo("inert")+"]",c=pr(o.floating).querySelectorAll(s);let d=ea(l)?l:null;for(;d&&!ha(d);){const e=va(d);if(ha(e)||!ea(e))break;d=e}if(c.length&&ea(l)&&!l.matches("html,body")&&!ur(l,o.floating)&&Array.from(c).every(e=>!ur(d,e)))return;if(ta(l)&&T){const t=ha(l),n=ga(l),a=/auto|scroll/,r=t||a.test(n.overflowX),o=t||a.test(n.overflowY),i=r&&l.clientWidth>0&&l.scrollWidth>l.clientWidth,s=o&&l.clientHeight>0&&l.scrollHeight>l.clientHeight,c="rtl"===n.direction,u=s&&(c?e.offsetX<=l.offsetWidth-l.clientWidth:e.offsetX>l.clientWidth),d=i&&e.offsetY>l.clientHeight;if(u||d)return}const m=null==(t=i.current.floatingContext)?void 0:t.nodeId,p=g&&fr(g.nodesRef.current,m).some(t=>{var n;return mr(e,null==(n=t.context)?void 0:n.elements.floating)});if(mr(e,o.floating)||mr(e,o.domReference)||p)return;const f=g?fr(g.nodesRef.current,m):[];if(f.length>0){let e=!0;if(f.forEach(t=>{var n;null==(n=t.context)||!n.open||t.context.dataRef.current.__outsidePressBubbles||(e=!1)}),!e)return}r(!1,e,"outside-press")}),S=vr(e=>{var t;const n=()=>{var t;D(e),null==(t=dr(e))||t.removeEventListener(u,n)};null==(t=dr(e))||t.addEventListener(u,n)});e.useEffect(()=>{if(!a||!l)return;i.current.__escapeKeyBubbles=w,i.current.__outsidePressBubbles=E;let e=-1;function t(e){r(!1,e,"ancestor-scroll")}function n(){window.clearTimeout(e),k.current=!0}function c(){e=window.setTimeout(()=>{k.current=!1},pa()?5:0)}const d=pr(o.floating);s&&(d.addEventListener("keydown",x?C:M,x),d.addEventListener("compositionstart",n),d.addEventListener("compositionend",c)),v&&d.addEventListener(u,N?S:D,N);let m=[];return p&&(ea(o.domReference)&&(m=wa(o.domReference)),ea(o.floating)&&(m=m.concat(wa(o.floating))),!ea(o.reference)&&o.reference&&o.reference.contextElement&&(m=m.concat(wa(o.reference.contextElement)))),m=m.filter(e=>{var t;return e!==(null==(t=d.defaultView)?void 0:t.visualViewport)}),m.forEach(e=>{e.addEventListener("scroll",t,{passive:!0})}),()=>{s&&(d.removeEventListener("keydown",x?C:M,x),d.removeEventListener("compositionstart",n),d.removeEventListener("compositionend",c)),v&&d.removeEventListener(u,N?S:D,N),m.forEach(e=>{e.removeEventListener("scroll",t)}),window.clearTimeout(e)}},[i,o,s,v,u,a,r,p,l,w,E,M,x,C,D,N,S]),e.useEffect(()=>{i.current.insideReactTree=!1},[i,v,u]);const P=e.useMemo(()=>({onKeyDown:M,...d&&{[So[m]]:e=>{r(!1,e.nativeEvent,"reference-press")},..."click"!==m&&{onClick(e){r(!1,e.nativeEvent,"reference-press")}}}}),[M,r,d,m]),T=e.useMemo(()=>({onKeyDown:M,onMouseDown(){b.current=!0},onMouseUp(){b.current=!0},[Po[u]]:()=>{i.current.insideReactTree=!0}}),[M,u,i]);return e.useMemo(()=>l?{reference:P,floating:T}:{},[l,P,T])}function Ro(t){const{open:n=!1,onOpenChange:a,elements:r}=t,o=po(),i=e.useRef({}),[l]=e.useState(()=>function(){const e=new Map;return{emit(t,n){var a;null==(a=e.get(t))||a.forEach(e=>e(n))},on(t,n){e.has(t)||e.set(t,new Set),e.get(t).add(n)},off(t,n){var a;null==(a=e.get(t))||a.delete(n)}}}()),s=null!=((null==(c=e.useContext(ho))?void 0:c.id)||null);var c;if("production"!==process.env.NODE_ENV){const e=r.reference;e&&!ea(e)&&function(){for(var e,t=arguments.length,n=new Array(t),a=0;a<t;a++)n[a]=arguments[a];const r="Floating UI: "+n.join(" ");var o;null!=(e=fo)&&e.has(r)||(null==(o=fo)||o.add(r),console.error(r))}("Cannot pass a virtual element to the `elements.reference` option,","as it must be a real DOM element. Use `refs.setPositionReference()`","instead.")}const[u,d]=e.useState(r.reference),m=vr((e,t,n)=>{i.current.openEvent=e?t:void 0,l.emit("openchange",{open:e,event:t,reason:n,nested:s}),null==a||a(e,t,n)}),p=e.useMemo(()=>({setPositionReference:d}),[]),f=e.useMemo(()=>({reference:u||r.reference||null,floating:r.floating||null,domReference:r.reference}),[u,r.reference,r.floating]);return e.useMemo(()=>({dataRef:i,open:n,onOpenChange:m,elements:f,events:l,floatingId:o,refs:p}),[n,m,f,l,o,p])}function Fo(t){void 0===t&&(t={});const{nodeId:n}=t,a=Ro({...t,elements:{reference:null,floating:null,...t.elements}}),r=t.rootContext||a,o=r.elements,[i,l]=e.useState(null),[s,c]=e.useState(null),u=(null==o?void 0:o.domReference)||i,d=e.useRef(null),m=yo();gr(()=>{u&&(d.current=u)},[u]);const p=function(t){void 0===t&&(t={});const{placement:n="bottom",strategy:a="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:l}={},transform:s=!0,whileElementsMounted:c,open:u}=t,[d,m]=e.useState({x:0,y:0,strategy:a,placement:n,middlewareData:{},isPositioned:!1}),[p,h]=e.useState(r);Qr(p,r)||h(r);const[g,y]=e.useState(null),[v,b]=e.useState(null),w=e.useCallback(e=>{e!==k.current&&(k.current=e,y(e))},[]),E=e.useCallback(e=>{e!==M.current&&(M.current=e,b(e))},[]),x=i||g,N=l||v,k=e.useRef(null),M=e.useRef(null),C=e.useRef(d),D=null!=c,S=eo(c),P=eo(o),T=eo(u),O=e.useCallback(()=>{if(!k.current||!M.current)return;const e={placement:n,strategy:a,middleware:p};P.current&&(e.platform=P.current),Ur(k.current,M.current,e).then(e=>{const t={...e,isPositioned:!1!==T.current};R.current&&!Qr(C.current,t)&&(C.current=t,f.flushSync(()=>{m(t)}))})},[p,n,a,P,T]);Gr(()=>{!1===u&&C.current.isPositioned&&(C.current.isPositioned=!1,m(e=>({...e,isPositioned:!1})))},[u]);const R=e.useRef(!1);Gr(()=>(R.current=!0,()=>{R.current=!1}),[]),Gr(()=>{if(x&&(k.current=x),N&&(M.current=N),x&&N){if(S.current)return S.current(x,N,O);O()}},[x,N,O,S,D]);const F=e.useMemo(()=>({reference:k,floating:M,setReference:w,setFloating:E}),[w,E]),I=e.useMemo(()=>({reference:x,floating:N}),[x,N]),A=e.useMemo(()=>{const e={position:a,left:0,top:0};if(!I.floating)return e;const t=Jr(I.floating,d.x),n=Jr(I.floating,d.y);return s?{...e,transform:"translate("+t+"px, "+n+"px)",...Zr(I.floating)>=1.5&&{willChange:"transform"}}:{position:a,left:t,top:n}},[a,s,I.floating,d.x,d.y]);return e.useMemo(()=>({...d,update:O,refs:F,elements:I,floatingStyles:A}),[d,O,F,I,A])}({...t,elements:{...o,...s&&{reference:s}}}),h=e.useCallback(e=>{const t=ea(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),getClientRects:()=>e.getClientRects(),contextElement:e}:e;c(t),p.refs.setReference(t)},[p.refs]),g=e.useCallback(e=>{(ea(e)||null===e)&&(d.current=e,l(e)),(ea(p.refs.reference.current)||null===p.refs.reference.current||null!==e&&!ea(e))&&p.refs.setReference(e)},[p.refs]),y=e.useMemo(()=>({...p.refs,setReference:g,setPositionReference:h,domReference:d}),[p.refs,g,h]),v=e.useMemo(()=>({...p.elements,domReference:u}),[p.elements,u]),b=e.useMemo(()=>({...p,...r,refs:y,elements:v,nodeId:n}),[p,y,v,n,r]);return gr(()=>{r.dataRef.current.floatingContext=b;const e=null==m?void 0:m.nodesRef.current.find(e=>e.id===n);e&&(e.context=b)}),e.useMemo(()=>({...p,context:b,refs:y,elements:v}),[p,y,v,b])}function Io(e,t,n){const a=new Map,r="item"===n;let o=e;if(r&&e){const{[io]:t,[lo]:n,...a}=e;o=a}return{..."floating"===n&&{tabIndex:-1,[oo]:""},...o,...t.map(t=>{const a=t?t[n]:null;return"function"==typeof a?e?a(e):null:a}).concat(e).reduce((e,t)=>t?(Object.entries(t).forEach(t=>{let[n,o]=t;var i;r&&[io,lo].includes(n)||(0===n.indexOf("on")?(a.has(n)||a.set(n,[]),"function"==typeof o&&(null==(i=a.get(n))||i.push(o),e[n]=function(){for(var e,t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return null==(e=a.get(n))?void 0:e.map(e=>e(...r)).find(e=>void 0!==e)})):e[n]=o)}),e):e,{})}}function Ao(t){void 0===t&&(t=[]);const n=t.map(e=>null==e?void 0:e.reference),a=t.map(e=>null==e?void 0:e.floating),r=t.map(e=>null==e?void 0:e.item),o=e.useCallback(e=>Io(e,t,"reference"),n),i=e.useCallback(e=>Io(e,t,"floating"),a),l=e.useCallback(e=>Io(e,t,"item"),r);return e.useMemo(()=>({getReferenceProps:o,getFloatingProps:i,getItemProps:l}),[o,i,l])}var Lo={container:"container-Ob3K8",border:"border-3ph1E","width-small":"width-small-IGEqx","width-medium":"width-medium-H3mey","width-large":"width-large-tlvBC","width-extra-large":"width-extra-large-kn4EU","width-quarter":"width-quarter-G91IH","width-one-third":"width-one-third-tBfDm","width-half":"width-half-jWSsK","width-three-quarters":"width-three-quarters-VZ7gZ","width-full":"width-full-JBbog","display-block":"display-block-umdz7","display-inline-block":"display-inline-block-tIWBf","display-flex":"display-flex-7Pivg","align-start":"align-start-WFirh","align-center":"align-center-m-T8U","align-end":"align-end-cxB31","justify-space-between":"justify-space-between-dNWWI","justify-center":"justify-center-ASu5z","justify-space-around":"justify-space-around-tHFSj","justify-space-evenly":"justify-space-evenly-Nk5K4","justify-flex-end":"justify-flex-end-W-NWe","justify-flex-start":"justify-flex-start---fCj"};const $o=["0","1","2","3","4","5","6","7","8","9","auto","x-0","x-1","x-2","x-3","x-4","x-5","x-6","x-7","x-8","x-9","x-auto","y-0","y-1","y-2","y-3","y-4","y-5","y-6","y-7","y-8","y-9","y-auto","t-0","t-1","t-2","t-3","t-4","t-5","t-6","t-7","t-8","t-9","t-auto","r-0","r-1","r-2","r-3","r-4","r-5","r-6","r-7","r-8","r-9","r-auto","b-0","b-1","b-2","b-3","b-4","b-5","b-6","b-7","b-8","b-9","b-auto","l-0","l-1","l-2","l-3","l-4","l-5","l-6","l-7","l-8","l-9","l-auto"];Array.from({length:101},(e,t)=>{const n=1924+t;return{label:String(n),value:String(n)}}).reverse(),$o.slice(0,10);const jo=({children:e,margin:n="m-0",padding:a="p-4",display:r="",align:o="",justify:i="",width:l="",showBorder:s=!1,className:c="",onClick:u,style:d,gap:m="4",...p})=>{const f=`display-${r}`,h=`justify-${i}`,y=`align-${o}`,w=`width-${l}`,E=b(n,v,"m"),x=b(a,v,"p"),k=b(m,v,"g"),M=N(Lo.container,x,E,{[Lo.border]:s,[Lo[w]]:l,[Lo[f]]:r,[Lo[h]]:i,[Lo[y]]:o},k,c);return t.createElement("div",g({className:M,onClick:e=>{"function"==typeof u&&u(e)},style:d},p),e)};var Bo={"cp-spinner-icon":"cp-spinner-icon-Ogl8J","spin-animation":"spin-animation-0bUOu","cp-spinner":"cp-spinner-j9RsW",small:"small-K-thx",medium:"medium-MFF6v",large:"large-p--mL",dark:"dark-ZBmrh"};const Wo=({size:e="medium",variant:n="light",icon:a="progress_activity",margin:r="0",className:o=""})=>{const i=b(r,v,"m"),l=N(Bo[e],Bo[n],i,o);return t.createElement(jo,{className:N(Bo["cp-spinner"],l)},t.createElement(S,{name:a,className:Bo["cp-spinner-icon"]}))},zo={position:"fixed",left:0,right:0,bottom:0,top:"auto",width:"100%",maxWidth:"100vw",margin:0,zIndex:1100};function _o(e,t){return`${e}-list-row-${t}`}const qo=e=>{const t=e.type||"";return t.startsWith("image/")?"image":"application/pdf"===t?"picture_as_pdf":t.startsWith("video/")?"movie":t.startsWith("audio/")?"music_note":t.includes("zip")||t.includes("compressed")?"folder_zip":"description"},Yo={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function Ho(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const Vo={date:Ho({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:Ho({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:Ho({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},Xo={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function Ko(e){return(t,n)=>{let a;if("formatting"===(n?.context?String(n.context):"standalone")&&e.formattingValues){const t=e.defaultFormattingWidth||e.defaultWidth,r=n?.width?String(n.width):t;a=e.formattingValues[r]||e.formattingValues[t]}else{const t=e.defaultWidth,r=n?.width?String(n.width):e.defaultWidth;a=e.values[r]||e.values[t]}return a[e.argumentCallback?e.argumentCallback(t):t]}}const Uo={ordinalNumber:(e,t)=>{const n=Number(e),a=n%100;if(a>20||a<10)switch(a%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:Ko({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:Ko({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:e=>e-1}),month:Ko({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:Ko({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:Ko({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})};function Go(e){return(t,n={})=>{const a=n.width,r=a&&e.matchPatterns[a]||e.matchPatterns[e.defaultMatchWidth],o=t.match(r);if(!o)return null;const i=o[0],l=a&&e.parsePatterns[a]||e.parsePatterns[e.defaultParseWidth],s=Array.isArray(l)?function(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n;return}(l,e=>e.test(i)):function(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n;return}(l,e=>e.test(i));let c;c=e.valueCallback?e.valueCallback(s):s,c=n.valueCallback?n.valueCallback(c):c;return{value:c,rest:t.slice(i.length)}}}const Qo={ordinalNumber:(Zo={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:e=>parseInt(e,10)},(e,t={})=>{const n=e.match(Zo.matchPattern);if(!n)return null;const a=n[0],r=e.match(Zo.parsePattern);if(!r)return null;let o=Zo.valueCallback?Zo.valueCallback(r[0]):r[0];return o=t.valueCallback?t.valueCallback(o):o,{value:o,rest:e.slice(a.length)}}),era:Go({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:Go({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:e=>e+1}),month:Go({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:Go({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:Go({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})};var Zo;const Jo={code:"en-US",formatDistance:(e,t,n)=>{let a;const r=Yo[e];return a="string"==typeof r?r:1===t?r.one:r.other.replace("{{count}}",t.toString()),n?.addSuffix?n.comparison&&n.comparison>0?"in "+a:a+" ago":a},formatLong:Vo,formatRelative:(e,t,n,a)=>Xo[e],localize:Uo,match:Qo,options:{weekStartsOn:0,firstWeekContainsDate:1}};let ei={};function ti(){return ei}const ni=6048e5,ai=Symbol.for("constructDateFrom");function ri(e,t){return"function"==typeof e?e(t):e&&"object"==typeof e&&ai in e?e[ai](t):e instanceof Date?new e.constructor(t):new Date(t)}function oi(e,t){return ri(t||e,e)}function ii(e){const t=oi(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function li(e,...t){const n=ri.bind(null,t.find(e=>"object"==typeof e));return t.map(n)}function si(e,t){const n=oi(e,t?.in);return n.setHours(0,0,0,0),n}function ci(e,t){const n=oi(e,t?.in),a=function(e,t){const[n,a]=li(0,e,t),r=si(n),o=si(a),i=+r-ii(r),l=+o-ii(o);return Math.round((i-l)/864e5)}(n,function(e,t){const n=oi(e,t?.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}(n));return a+1}function ui(e,t){const n=ti(),a=t?.weekStartsOn??t?.locale?.options?.weekStartsOn??n.weekStartsOn??n.locale?.options?.weekStartsOn??0,r=oi(e,t?.in),o=r.getDay(),i=(o<a?7:0)+o-a;return r.setDate(r.getDate()-i),r.setHours(0,0,0,0),r}function di(e,t){return ui(e,{...t,weekStartsOn:1})}function mi(e,t){const n=oi(e,t?.in),a=n.getFullYear(),r=ri(n,0);r.setFullYear(a+1,0,4),r.setHours(0,0,0,0);const o=di(r),i=ri(n,0);i.setFullYear(a,0,4),i.setHours(0,0,0,0);const l=di(i);return n.getTime()>=o.getTime()?a+1:n.getTime()>=l.getTime()?a:a-1}function pi(e,t){const n=oi(e,t?.in),a=+di(n)-+function(e,t){const n=mi(e,t),a=ri(e,0);return a.setFullYear(n,0,4),a.setHours(0,0,0,0),di(a)}(n);return Math.round(a/ni)+1}function fi(e,t){const n=oi(e,t?.in),a=n.getFullYear(),r=ti(),o=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??r.firstWeekContainsDate??r.locale?.options?.firstWeekContainsDate??1,i=ri(t?.in||e,0);i.setFullYear(a+1,0,o),i.setHours(0,0,0,0);const l=ui(i,t),s=ri(t?.in||e,0);s.setFullYear(a,0,o),s.setHours(0,0,0,0);const c=ui(s,t);return+n>=+l?a+1:+n>=+c?a:a-1}function hi(e,t){const n=oi(e,t?.in),a=+ui(n,t)-+function(e,t){const n=ti(),a=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??n.firstWeekContainsDate??n.locale?.options?.firstWeekContainsDate??1,r=fi(e,t),o=ri(t?.in||e,0);return o.setFullYear(r,0,a),o.setHours(0,0,0,0),ui(o,t)}(n,t);return Math.round(a/ni)+1}function gi(e,t){return(e<0?"-":"")+Math.abs(e).toString().padStart(t,"0")}const yi={y(e,t){const n=e.getFullYear(),a=n>0?n:1-n;return gi("yy"===t?a%100:a,t.length)},M(e,t){const n=e.getMonth();return"M"===t?String(n+1):gi(n+1,2)},d:(e,t)=>gi(e.getDate(),t.length),a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];default:return"am"===n?"a.m.":"p.m."}},h:(e,t)=>gi(e.getHours()%12||12,t.length),H:(e,t)=>gi(e.getHours(),t.length),m:(e,t)=>gi(e.getMinutes(),t.length),s:(e,t)=>gi(e.getSeconds(),t.length),S(e,t){const n=t.length,a=e.getMilliseconds();return gi(Math.trunc(a*Math.pow(10,n-3)),t.length)}},vi="midnight",bi="noon",wi="morning",Ei="afternoon",xi="evening",Ni="night",ki={G:function(e,t,n){const a=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(a,{width:"abbreviated"});case"GGGGG":return n.era(a,{width:"narrow"});default:return n.era(a,{width:"wide"})}},y:function(e,t,n){if("yo"===t){const t=e.getFullYear(),a=t>0?t:1-t;return n.ordinalNumber(a,{unit:"year"})}return yi.y(e,t)},Y:function(e,t,n,a){const r=fi(e,a),o=r>0?r:1-r;if("YY"===t){return gi(o%100,2)}return"Yo"===t?n.ordinalNumber(o,{unit:"year"}):gi(o,t.length)},R:function(e,t){return gi(mi(e),t.length)},u:function(e,t){return gi(e.getFullYear(),t.length)},Q:function(e,t,n){const a=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(a);case"QQ":return gi(a,2);case"Qo":return n.ordinalNumber(a,{unit:"quarter"});case"QQQ":return n.quarter(a,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(a,{width:"narrow",context:"formatting"});default:return n.quarter(a,{width:"wide",context:"formatting"})}},q:function(e,t,n){const a=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(a);case"qq":return gi(a,2);case"qo":return n.ordinalNumber(a,{unit:"quarter"});case"qqq":return n.quarter(a,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(a,{width:"narrow",context:"standalone"});default:return n.quarter(a,{width:"wide",context:"standalone"})}},M:function(e,t,n){const a=e.getMonth();switch(t){case"M":case"MM":return yi.M(e,t);case"Mo":return n.ordinalNumber(a+1,{unit:"month"});case"MMM":return n.month(a,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(a,{width:"narrow",context:"formatting"});default:return n.month(a,{width:"wide",context:"formatting"})}},L:function(e,t,n){const a=e.getMonth();switch(t){case"L":return String(a+1);case"LL":return gi(a+1,2);case"Lo":return n.ordinalNumber(a+1,{unit:"month"});case"LLL":return n.month(a,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(a,{width:"narrow",context:"standalone"});default:return n.month(a,{width:"wide",context:"standalone"})}},w:function(e,t,n,a){const r=hi(e,a);return"wo"===t?n.ordinalNumber(r,{unit:"week"}):gi(r,t.length)},I:function(e,t,n){const a=pi(e);return"Io"===t?n.ordinalNumber(a,{unit:"week"}):gi(a,t.length)},d:function(e,t,n){return"do"===t?n.ordinalNumber(e.getDate(),{unit:"date"}):yi.d(e,t)},D:function(e,t,n){const a=ci(e);return"Do"===t?n.ordinalNumber(a,{unit:"dayOfYear"}):gi(a,t.length)},E:function(e,t,n){const a=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(a,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(a,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(a,{width:"short",context:"formatting"});default:return n.day(a,{width:"wide",context:"formatting"})}},e:function(e,t,n,a){const r=e.getDay(),o=(r-a.weekStartsOn+8)%7||7;switch(t){case"e":return String(o);case"ee":return gi(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(r,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},c:function(e,t,n,a){const r=e.getDay(),o=(r-a.weekStartsOn+8)%7||7;switch(t){case"c":return String(o);case"cc":return gi(o,t.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(r,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(r,{width:"narrow",context:"standalone"});case"cccccc":return n.day(r,{width:"short",context:"standalone"});default:return n.day(r,{width:"wide",context:"standalone"})}},i:function(e,t,n){const a=e.getDay(),r=0===a?7:a;switch(t){case"i":return String(r);case"ii":return gi(r,t.length);case"io":return n.ordinalNumber(r,{unit:"day"});case"iii":return n.day(a,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(a,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(a,{width:"short",context:"formatting"});default:return n.day(a,{width:"wide",context:"formatting"})}},a:function(e,t,n){const a=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(a,{width:"narrow",context:"formatting"});default:return n.dayPeriod(a,{width:"wide",context:"formatting"})}},b:function(e,t,n){const a=e.getHours();let r;switch(r=12===a?bi:0===a?vi:a/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(e,t,n){const a=e.getHours();let r;switch(r=a>=17?xi:a>=12?Ei:a>=4?wi:Ni,t){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(e,t,n){if("ho"===t){let t=e.getHours()%12;return 0===t&&(t=12),n.ordinalNumber(t,{unit:"hour"})}return yi.h(e,t)},H:function(e,t,n){return"Ho"===t?n.ordinalNumber(e.getHours(),{unit:"hour"}):yi.H(e,t)},K:function(e,t,n){const a=e.getHours()%12;return"Ko"===t?n.ordinalNumber(a,{unit:"hour"}):gi(a,t.length)},k:function(e,t,n){let a=e.getHours();return 0===a&&(a=24),"ko"===t?n.ordinalNumber(a,{unit:"hour"}):gi(a,t.length)},m:function(e,t,n){return"mo"===t?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):yi.m(e,t)},s:function(e,t,n){return"so"===t?n.ordinalNumber(e.getSeconds(),{unit:"second"}):yi.s(e,t)},S:function(e,t){return yi.S(e,t)},X:function(e,t,n){const a=e.getTimezoneOffset();if(0===a)return"Z";switch(t){case"X":return Ci(a);case"XXXX":case"XX":return Di(a);default:return Di(a,":")}},x:function(e,t,n){const a=e.getTimezoneOffset();switch(t){case"x":return Ci(a);case"xxxx":case"xx":return Di(a);default:return Di(a,":")}},O:function(e,t,n){const a=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Mi(a,":");default:return"GMT"+Di(a,":")}},z:function(e,t,n){const a=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Mi(a,":");default:return"GMT"+Di(a,":")}},t:function(e,t,n){return gi(Math.trunc(+e/1e3),t.length)},T:function(e,t,n){return gi(+e,t.length)}};function Mi(e,t=""){const n=e>0?"-":"+",a=Math.abs(e),r=Math.trunc(a/60),o=a%60;return 0===o?n+String(r):n+String(r)+t+gi(o,2)}function Ci(e,t){if(e%60==0){return(e>0?"-":"+")+gi(Math.abs(e)/60,2)}return Di(e,t)}function Di(e,t=""){const n=e>0?"-":"+",a=Math.abs(e);return n+gi(Math.trunc(a/60),2)+t+gi(a%60,2)}const Si=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});default:return t.date({width:"full"})}},Pi=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});default:return t.time({width:"full"})}},Ti={p:Pi,P:(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],a=n[1],r=n[2];if(!r)return Si(e,t);let o;switch(a){case"P":o=t.dateTime({width:"short"});break;case"PP":o=t.dateTime({width:"medium"});break;case"PPP":o=t.dateTime({width:"long"});break;default:o=t.dateTime({width:"full"})}return o.replace("{{date}}",Si(a,t)).replace("{{time}}",Pi(r,t))}},Oi=/^D+$/,Ri=/^Y+$/,Fi=["D","DD","YY","YYYY"];function Ii(e){return!(!((t=e)instanceof Date||"object"==typeof t&&"[object Date]"===Object.prototype.toString.call(t))&&"number"!=typeof e||isNaN(+oi(e)));var t}const Ai=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Li=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,$i=/^'([^]*?)'?$/,ji=/''/g,Bi=/[a-zA-Z]/;function Wi(e,t,n){const a=ti(),r=n?.locale??a.locale??Jo,o=n?.firstWeekContainsDate??n?.locale?.options?.firstWeekContainsDate??a.firstWeekContainsDate??a.locale?.options?.firstWeekContainsDate??1,i=n?.weekStartsOn??n?.locale?.options?.weekStartsOn??a.weekStartsOn??a.locale?.options?.weekStartsOn??0,l=oi(e,n?.in);if(!Ii(l))throw new RangeError("Invalid time value");let s=t.match(Li).map(e=>{const t=e[0];if("p"===t||"P"===t){return(0,Ti[t])(e,r.formatLong)}return e}).join("").match(Ai).map(e=>{if("''"===e)return{isToken:!1,value:"'"};const t=e[0];if("'"===t)return{isToken:!1,value:zi(e)};if(ki[t])return{isToken:!0,value:e};if(t.match(Bi))throw new RangeError("Format string contains an unescaped latin alphabet character `"+t+"`");return{isToken:!1,value:e}});r.localize.preprocessor&&(s=r.localize.preprocessor(l,s));const c={firstWeekContainsDate:o,weekStartsOn:i,locale:r};return s.map(a=>{if(!a.isToken)return a.value;const o=a.value;(!n?.useAdditionalWeekYearTokens&&function(e){return Ri.test(e)}(o)||!n?.useAdditionalDayOfYearTokens&&function(e){return Oi.test(e)}(o))&&function(e,t,n){const a=function(e,t,n){const a="Y"===e[0]?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${a} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}(e,t,n);if(console.warn(a),Fi.includes(e))throw new RangeError(a)}(o,t,String(e));return(0,ki[o[0]])(l,o,r.localize,c)}).join("")}function zi(e){const t=e.match($i);return t?t[1].replace(ji,"'"):e}function _i(e,t,n){const a=oi(e,n?.in);return isNaN(t)?ri(e,NaN):t?(a.setDate(a.getDate()+t),a):a}function qi(e,t,n){const a=oi(e,n?.in);if(isNaN(t))return ri(e,NaN);if(!t)return a;const r=a.getDate(),o=ri(e,a.getTime());o.setMonth(a.getMonth()+t+1,0);return r>=o.getDate()?o:(a.setFullYear(o.getFullYear(),o.getMonth(),r),a)}function Yi(e,t,n){return qi(e,12*t,n)}function Hi(e,t){const n=oi(e,t?.in);return n.setDate(1),n.setHours(0,0,0,0),n}function Vi(e,t){const n=oi(e,t?.in),a=n.getMonth();return n.setFullYear(n.getFullYear(),a+1,0),n.setHours(23,59,59,999),n}function Xi(e,t,n){const[a,r]=li(0,e,t);return a.getFullYear()===r.getFullYear()&&a.getMonth()===r.getMonth()}const Ki=({onCancel:e,onOk:n})=>t.createElement("div",{className:An},t.createElement("button",{type:"button",className:Ln,onClick:t=>{t.stopPropagation(),e()}},"Cancel"),t.createElement("button",{type:"button",className:`${Ln} ${$n}`,onClick:e=>{e.stopPropagation(),n()}},"OK"));function Ui(e){return si(e)}function Gi(e,t){if(null==e||null==t)return e===t;return Ui(e).getTime()===Ui(t).getTime()}function Qi(e){if(null!=e&&""!==e){if(e instanceof Date){const t=e.getTime();return Number.isNaN(t)?void 0:Ui(e)}if("number"==typeof e&&Number.isFinite(e)){const t=new Date(e);return Number.isNaN(t.getTime())?void 0:Ui(t)}if("string"==typeof e&&""!==e.trim()){const t=e.trim();if(/^-?\d+$/.test(t)){const e=Number(t);if(Number.isFinite(e)){const t=new Date(e);return Number.isNaN(t.getTime())?void 0:Ui(t)}}const n=new Date(t);return Number.isNaN(n.getTime())?void 0:Ui(n)}}}const Zi=({weeks:e,weekLabels:n,locale:a,staged:o,today:i,isDayUnavailable:c,onSelectDay:u,onRequestPrevMonth:d,onRequestNextMonth:m,gridLabelId:p})=>{const f=l(()=>function(e){return e.flat()}(e),[e]),h=l(()=>{const e=[];return f.forEach((t,n)=>{c(t.date)||e.push(n)}),e},[f,c]),[g,y]=t.useState(null);r(()=>{if(o){const e=Ui(o).getTime(),t=f.findIndex(t=>Ui(t.date).getTime()===e);t>=0&&y(t)}},[f,o]);const v=s(e=>{if(0===h.length)return;const t=null!=g?h.indexOf(g):null,n=null==t?e>0?-1:h.length:t,a=Math.min(h.length-1,Math.max(0,n+e));y(h[a])},[g,h]),b=s(t=>{if(null==g)return void(null!=h[0]&&y(h[0]));const n=Math.floor(g/7),a=g%7,r=n+t;if(r<0)return void d?.();if(r>=e.length)return void m?.();const o=7*r+a;if(!(o>=f.length)){if(c(f[o].date)){const e=t<0?-1:1;let n=o;for(;n>=0&&n<f.length;){if(!c(f[n].date))return void y(n);n+=e}return}y(o)}},[f,g,c,h,m,d,e.length]),w=s(e=>{const t=f.map((e,t)=>({cell:e,idx:t})).filter(({cell:e})=>e.inCurrentMonth&&!c(e.date));0!==t.length&&y(e?t[t.length-1].idx:t[0].idx)},[f,c]);return t.createElement("div",{role:"grid","aria-labelledby":p,className:Cn,tabIndex:-1,onKeyDown:e=>{switch(e.key){case"ArrowRight":return e.preventDefault(),void v(1);case"ArrowLeft":return e.preventDefault(),void v(-1);case"ArrowDown":return e.preventDefault(),void b(1);case"ArrowUp":return e.preventDefault(),void b(-1);case"PageUp":return e.preventDefault(),void d?.();case"PageDown":return e.preventDefault(),void m?.();case"Home":return e.preventDefault(),void w(!1);case"End":return e.preventDefault(),void w(!0);default:return}}},t.createElement("div",{role:"row",className:Dn},n.map((e,n)=>t.createElement("span",{key:`dow-${String(n)}-${e}`,role:"columnheader","aria-label":e,className:Sn},e))),e.map((e,n)=>t.createElement("div",{role:"row",key:`w-${String(n)}`,className:Pn},e.map((r,l)=>{const s=n*e.length+l,d=c(r.date),m=null!=o&&Gi(r.date,o),p=Gi(r.date,i),f=g===s;return t.createElement("div",{key:String(r.date.getTime()),role:"gridcell",className:Tn},t.createElement("button",{type:"button","aria-label":Wi(r.date,"PPP",{locale:a}),"aria-selected":Boolean(m),"aria-disabled":d||void 0,tabIndex:f&&!d?0:-1,disabled:d,className:N(On,!r.inCurrentMonth&&Fn,p&&In,m&&Rn),"data-flat-index":s,onClick:e=>{e.preventDefault(),e.stopPropagation(),d||u(r.date)},onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),d||u(r.date))},onFocus:()=>{d||y(s)}},r.date.getDate()))}))))},Ji=({displayedMonth:e,locale:n,monthLabelShort:a,yearLabel:r,prevMonthDisabled:o,nextMonthDisabled:i,prevYearDisabled:l,nextYearDisabled:s,onPrevMonth:c,onNextMonth:u,onPrevYear:d,onNextYear:m,onOpenMonth:p,onOpenYear:f})=>t.createElement("div",{className:xn},t.createElement("div",{className:Nn},t.createElement("button",{type:"button",className:kn,"aria-label":"Previous month",disabled:o,onClick:e=>{e.stopPropagation(),o||c()}},t.createElement(S,{name:"keyboard_arrow_left","aria-hidden":!0})),t.createElement("button",{type:"button",className:Mn,"aria-label":`Choose month, ${Wi(e,"MMMM yyyy",{locale:n})}`,onClick:e=>{e.stopPropagation(),p()}},t.createElement("span",null,a),t.createElement(S,{name:"arrow_drop_down",size:"small","aria-hidden":!0})),t.createElement("button",{type:"button",className:kn,"aria-label":"Next month",disabled:i,onClick:e=>{e.stopPropagation(),i||u()}},t.createElement(S,{name:"keyboard_arrow_right","aria-hidden":!0}))),t.createElement("div",{className:Nn},t.createElement("button",{type:"button",className:kn,"aria-label":"Previous year",disabled:l,onClick:e=>{e.stopPropagation(),l||d()}},t.createElement(S,{name:"keyboard_arrow_left","aria-hidden":!0})),t.createElement("button",{type:"button",className:Mn,"aria-label":`Choose year, ${r}`,onClick:e=>{e.stopPropagation(),f()}},t.createElement("span",null,r),t.createElement(S,{name:"arrow_drop_down",size:"small","aria-hidden":!0})),t.createElement("button",{type:"button",className:kn,"aria-label":"Next year",disabled:s,onClick:e=>{e.stopPropagation(),s||m()}},t.createElement(S,{name:"keyboard_arrow_right","aria-hidden":!0})))),el=({items:e,onPick:n,activePredicate:a,ariaLabelledBy:r})=>t.createElement("ul",{className:jn,role:"listbox","aria-labelledby":r,"aria-label":r?void 0:"Choose option"},e.map((e,r)=>{const o=Boolean(a?.(e.value));return t.createElement("li",{key:`${String(e.value)}-${String(r)}`},t.createElement("button",{type:"button",role:"option","aria-selected":o,"aria-disabled":e.disabled||void 0,tabIndex:-1,disabled:e.disabled,className:N(Bn,o&&Wn),"data-row":r,onClick:t=>{t.stopPropagation(),e.disabled||n(e.value)}},e.label))}));function tl(e){return null!=e}function nl(e){return null!=e}function al(e,t){const n=Ui(e).getTime();if(tl(t.minDate)&&n<Ui(t.minDate).getTime())return!0;if(nl(t.maxDate)&&n>Ui(t.maxDate).getTime())return!0;const a=oi(Ui(e),r?.in).getDay();var r;return!!t.disabledDaysOfWeek?.includes(a)||!!t.disabledDates?.some(t=>Gi(Ui(t),Ui(e)))}function rl(e,t){let n=Ui(e);return tl(t.minDate)&&n.getTime()<Ui(t.minDate).getTime()&&(n=Ui(t.minDate)),nl(t.maxDate)&&n.getTime()>Ui(t.maxDate).getTime()&&(n=Ui(t.maxDate)),n}function ol(e,t){if(!tl(t))return!1;return Vi(e).getTime()<Ui(t).getTime()}function il(e,t){if(!nl(t))return!1;return Hi(e).getTime()>Ui(t).getTime()}const ll=({panelId:e,gridLabelId:n,locale:a=Jo,weekStartsOn:r,constraints:o,picker:i,onRequestCancel:s,onRequestConfirm:c})=>{const u=a,d=l(()=>function(e,t){const n=Hi(e),a=ui(n,{weekStartsOn:t}),r=Vi(e),o=[];let i=a;for(;o.length<42&&(o.push({date:i,inCurrentMonth:Xi(i,n)}),i=_i(i,1),!(o.length>=35&&i.getTime()>r.getTime()))&&42!==o.length;);for(;o.length%7!=0;)o.push({date:i,inCurrentMonth:Xi(i,n)}),i=_i(i,1);const l=[];for(let e=0;e<o.length;e+=7)l.push(o.slice(e,e+7));return l}(i.displayedMonth,r),[i.displayedMonth,r]),m=l(()=>{const e=ui(Hi(i.displayedMonth),{weekStartsOn:r});return Array.from({length:7},(t,n)=>Wi(_i(e,n),"EEEEE",{locale:u}))},[u,i.displayedMonth,r]),p=Wi(i.displayedMonth,"MMM",{locale:u}),f=Wi(i.displayedMonth,"yyyy",{locale:u}),h=l(()=>Ui(new Date),[]),g=Hi(qi(i.displayedMonth,-1)),y=Hi(qi(i.displayedMonth,1)),v=ol(g,o.minDate),b=il(y,o.maxDate),w=Hi(Yi(i.displayedMonth,-1)),E=Hi(Yi(i.displayedMonth,1)),x=ol(w,o.minDate),N=il(E,o.maxDate),k=l(()=>{const e=o.minDate?.getFullYear()??i.displayedMonth.getFullYear()-100,t=o.maxDate?.getFullYear()??i.displayedMonth.getFullYear()+100,n=[];for(let a=e;a<=t;a+=1){const e=Hi(new Date(a,i.displayedMonth.getMonth(),1)),t=ol(e,o.minDate)||il(e,o.maxDate);n.push({value:a,label:String(a),disabled:t})}return n},[o.maxDate,o.minDate,i.displayedMonth]),M=l(()=>{const e=i.displayedMonth.getFullYear();return Array.from({length:12},(t,n)=>{const a=Hi(new Date(e,n,1)),r=ol(a,o.minDate)||il(a,o.maxDate);return{value:n,label:Wi(new Date(2e3,n,1),"MMM",{locale:u}),disabled:r}})},[o.maxDate,o.minDate,u,i.displayedMonth]),C=`${e}-subview-month-title`,D=`${e}-subview-year-title`,P=Wi(i.displayedMonth,"yyyy",{locale:u}),T=Wi(i.displayedMonth,"MMMM",{locale:u});return t.createElement("div",{id:e,className:En},"calendar"===i.panelView?t.createElement(t.Fragment,null,t.createElement("span",{id:n,className:bn},Wi(i.displayedMonth,"MMMM yyyy",{locale:u})),t.createElement(Ji,{displayedMonth:i.displayedMonth,locale:u,monthLabelShort:p,yearLabel:f,prevMonthDisabled:v,nextMonthDisabled:b,prevYearDisabled:x,nextYearDisabled:N,onPrevMonth:i.goPrevMonth,onNextMonth:i.goNextMonth,onPrevYear:()=>{i.setDisplayedMonthFromYearMonth(i.displayedMonth.getFullYear()-1,i.displayedMonth.getMonth())},onNextYear:()=>{i.setDisplayedMonthFromYearMonth(i.displayedMonth.getFullYear()+1,i.displayedMonth.getMonth())},onOpenMonth:()=>i.setPanelView("month"),onOpenYear:()=>i.setPanelView("year")}),t.createElement(Zi,{weeks:d,weekLabels:m,locale:u,staged:i.staged,today:h,isDayUnavailable:e=>al(e,o),onSelectDay:e=>i.selectDay(e),gridLabelId:n,onRequestPrevMonth:i.goPrevMonth,onRequestNextMonth:i.goNextMonth}),t.createElement(Ki,{onCancel:s??i.cancel,onOk:c??i.confirm})):null,"month"===i.panelView?t.createElement("div",{className:zn},t.createElement("div",{className:_n},t.createElement("button",{type:"button",className:qn,"aria-label":"Back to calendar",onClick:e=>{e.stopPropagation(),i.setPanelView("calendar")}},t.createElement(S,{name:"arrow_back","aria-hidden":!0})),t.createElement("span",{id:C,className:Yn},t.createElement("span",{className:Hn},"Select a month of ",P))),t.createElement(el,{ariaLabelledBy:C,items:M,activePredicate:e=>e===i.displayedMonth.getMonth(),onPick:e=>{i.setDisplayedMonthFromYearMonth(i.displayedMonth.getFullYear(),e),i.setPanelView("calendar")}})):null,"year"===i.panelView?t.createElement("div",{className:zn},t.createElement("div",{className:_n},t.createElement("button",{type:"button",className:qn,"aria-label":"Back to calendar",onClick:e=>{e.stopPropagation(),i.setPanelView("calendar")}},t.createElement(S,{name:"arrow_back","aria-hidden":!0})),t.createElement("span",{id:D,className:Yn},t.createElement("span",{className:Hn},"Select a year for ",T))),t.createElement(el,{ariaLabelledBy:D,items:k,activePredicate:e=>e===i.displayedMonth.getFullYear(),onPick:e=>{i.setDisplayedMonthFromYearMonth(e,i.displayedMonth.getMonth()),i.setPanelView("calendar")}})):null)};function sl(e,t){return ol(e,t.minDate)&&null!=t.minDate?Hi(t.minDate):il(e,t.maxDate)&&null!=t.maxDate?Hi(t.maxDate):e}function cl(e){const t=void 0!==e.value,[n,o]=a(()=>t?null:e.defaultValue??null),i=t?e.value??null:n,[l,c]=a(!1),[u,d]=a("calendar"),[m,p]=a(null),[f,h]=a(()=>sl(Hi(i??new Date),e.constraints)),g=i?.getTime()??null,y=e.constraints.minDate?.getTime(),v=e.constraints.maxDate?.getTime(),b=e.constraints.disabledDaysOfWeek?.join(",")??"",w=e.constraints.disabledDates?.map(e=>Ui(e).getTime()).join("|")??"";r(()=>{if(l)return;const t=i??new Date,n=e.constraints;h(sl(Hi(t),n))},[l,i,g,t,y,v,b,w]);const E=s(n=>{t||o(n),e.onChange?.(n)},[e,t]),x=s(()=>{c(!1),d("calendar")},[]),N=s(()=>{if(null!=i){const t=Ui(i);p(t),h(sl(Hi(t),e.constraints))}else{const t=function(e,t){let n=rl(e,t);for(let e=0;e<120;e+=1){if(!al(n,t))return n;n=rl(_i(n,1),t)}return n}(new Date,e.constraints);p(t),h(sl(Hi(t),e.constraints))}d("calendar"),c(!0)},[e.constraints,i]),k=s(()=>{p(null==i?null:Ui(i)),x()},[x,i]),M=s(()=>{if(null==m)E(null);else{const t=rl(m,e.constraints);if(al(t,e.constraints))return void x();E(t)}x()},[e.constraints,x,E,m]),C=s(t=>{const n=rl(Ui(t),e.constraints);p(n),h(sl(Hi(n),e.constraints))},[e.constraints]),D=s(()=>{E(null),p(null),x()},[x,E]),S=s(()=>{h(t=>sl(qi(t,-1),e.constraints))},[e.constraints]),P=s(()=>{h(t=>sl(qi(t,1),e.constraints))},[e.constraints]),T=s((t,n)=>{h(sl(Hi(new Date(t,n,1)),e.constraints))},[e.constraints]);return{isOpen:l,panelView:u,setPanelView:d,committed:i,staged:m,displayedMonth:f,open:N,close:x,cancel:k,confirm:M,selectDay:C,clearCommitted:D,goPrevMonth:S,goNextMonth:P,setDisplayedMonthFromYearMonth:T}}const ul={position:"fixed",left:0,right:0,bottom:0,top:"auto",width:"100%",maxWidth:"100vw",margin:0,zIndex:1100},dl=new Set(["text","search","url","tel","password"]);var ml={Input:({name:e,id:r,onChange:l,onKeyDown:s,onBlur:c,defaultValue:u,value:d,label:m="",isDisabled:p=!1,isRequired:f=!1,isFluid:h=!1,type:y="text",className:v="",placeholder:b="",error:w="",dataTestId:E,autoComplete:x,maxLength:k,min:M,max:C,prefix:D,suffix:P,prefixA11yLabel:T,suffixA11yLabel:O})=>{const R=o(),F=r??e??R,I=`${F}-error`,A=n(null),L=n(null),$="number"===y,j="search"===y,B=$?"text":y,W=$?"numeric":void 0,z=$?"[0-9]*":void 0,_=Xn.has(B),q=void 0!==d,[Y,H]=a(u??""),V=j&&!p&&(q?d??"":Y).length>0;i(()=>{if(!q||!_)return;const e=A.current,t=L.current;if(L.current=null,!e||!t||document.activeElement!==e)return;const n=e.value.length,a=Math.max(0,Math.min(t.start,n)),r=Math.max(0,Math.min(t.end,n));Kn(e,a,r)},[d,q,_]);const X=e=>{const t=A.current;if(!t)return;const n=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value")?.set;n?.call(t,e),t.dispatchEvent(new Event("input",{bubbles:!0}))},K=Vn(D),U=Vn(P),G=!j&&Boolean(K||U),Q=N(ee,{[te]:h},v),Z=w?ie:"",J=N(oe,Z,j?ue:"",j&&V?de:"",G?ye:""),ne=N(oe,pe,Z,p?fe:""),re=K?`${F}-prefix`:void 0,ve=U?`${F}-suffix`:void 0,be=[w?I:void 0,re,ve].filter(Boolean).join(" ")||void 0,we=t.createElement("input",g({ref:A,className:J,type:B,inputMode:W,pattern:z,disabled:p,required:f,"aria-required":f||void 0,"aria-invalid":!!w||void 0,"aria-describedby":be,name:e,id:F,placeholder:b,autoComplete:x||void 0,maxLength:k,min:M,max:C},q?{value:d??""}:void 0!==u?{defaultValue:u}:{},{onChange:e=>{const t=e.target;if($&&/\D/.test(t.value)){const e=t.value.replace(/\D/g,""),n=t.value.length-e.length,a=(t.selectionStart??e.length)-n;t.value=e;const r=Math.max(0,Math.min(a,e.length));Kn(t,r,r)}q&&_&&(L.current={start:t.selectionStart??t.value.length,end:t.selectionEnd??t.value.length}),q||H(t.value),l?.(e)},onKeyDown:e=>s?.(e),onBlur:e=>{if($&&""!==e.target.value&&(void 0!==M||void 0!==C)){const t=Number(e.target.value);if(!Number.isNaN(t)){const e=void 0!==M?Number(M):-1/0,n=void 0!==C?Number(C):1/0,a=Math.min(n,Math.max(e,t));a!==t&&X(String(a))}}c?.(e)},onBeforeInput:$?e=>{if(!$)return;const t=e.nativeEvent.data;t&&/\D/.test(t)&&e.preventDefault()}:void 0,"data-testid":E}));return t.createElement("div",{className:Q},m&&t.createElement("label",{className:ae,htmlFor:F},m," ",f&&t.createElement("span",{"aria-hidden":"true"},"*")),j?t.createElement("div",{className:se},t.createElement(S,{name:"search",size:"medium","aria-hidden":!0,className:ce}),we,V&&t.createElement("button",{type:"button",onClick:()=>{X(""),A.current?.focus()},className:me,"aria-label":"Clear search","data-testid":E?`${E}-clear`:void 0},t.createElement(S,{name:"close",size:"small","aria-hidden":!0}))):G?t.createElement("div",{className:ne},K&&t.createElement("span",{id:re,className:he,"aria-label":T,"data-testid":E?`${E}-prefix`:void 0},K),we,U&&t.createElement("span",{id:ve,className:ge,"aria-label":O,"data-testid":E?`${E}-suffix`:void 0},U)):we,w&&t.createElement("p",{id:I,role:"alert",className:le},w))},TextArea:({name:e,id:n,onChange:a,defaultValue:r,value:i,label:l="",isDisabled:s=!1,isRequired:c=!1,isFluid:u=!1,className:d="",placeholder:m="",error:p="",dataTestId:f})=>{const h=o(),g=n??e??h,y=`${g}-error`,v=N(ee,{[te]:u},d),b=N(oe,Ne,p?ie:"");return t.createElement("div",{className:v},l&&t.createElement("label",{className:ae,htmlFor:g},l," ",c&&t.createElement("span",{"aria-hidden":"true"},"*")),t.createElement("textarea",{className:b,disabled:s,required:c,"aria-required":c||void 0,"aria-invalid":!!p||void 0,"aria-describedby":p?y:void 0,name:e,id:g,defaultValue:r,placeholder:m,value:i,onChange:e=>a?.(e),"data-testid":f}),p&&t.createElement("p",{id:y,role:"alert",className:le},p))},File:({name:e,id:r,onChange:i,value:l,defaultValue:s,multiple:c=!1,accept:u,variant:d="button",buttonLabel:m="Browse file",dropZoneText:p="Drag files to upload",label:f="",isDisabled:h=!1,isRequired:g=!1,isFluid:y=!1,className:v="",error:b="",dataTestId:w})=>{const E=o(),x=r??e??E,k=`${x}-error`,M=n(null),C=void 0!==l,[D,P]=a(s??[]),T=C?l:D,[O,R]=a(!1),F=N(ee,an,{[te]:y},v),I=N(rn,"card"===d?ln:on,O?dn:""),A=(e,t)=>{C||P(e),i?.(e,t)},L=e=>{h||(e.preventDefault(),e.stopPropagation(),O||R(!0))};return t.createElement("div",{className:F,"data-invalid":b?"true":void 0,"data-variant":d},f&&t.createElement("label",{className:ae,htmlFor:x},f,g&&t.createElement(t.Fragment,null," ",t.createElement("span",{"aria-hidden":"true"},"*"))),t.createElement("input",{ref:M,className:xe,type:"file",disabled:h,required:g&&0===T.length,"aria-required":g||void 0,"aria-invalid":!!b||void 0,"aria-describedby":b?k:void 0,name:e,id:x,multiple:c,accept:u,onChange:e=>{const t=e.target.files?Array.from(e.target.files):[],n=c?[...T,...t]:t;A(n,e)},"data-testid":w}),"card"===d?t.createElement("label",{htmlFor:x,className:I,onDragEnter:L,onDragOver:L,onDragLeave:e=>{e.preventDefault(),e.stopPropagation(),R(!1)},onDrop:e=>{if(e.preventDefault(),e.stopPropagation(),R(!1),h)return;const t=Array.from(e.dataTransfer?.files??[]);if(0===t.length)return;const n=c?[...T,...t]:t.slice(0,1);A(n)}},t.createElement(S,{name:"cloud_upload",size:"large","aria-hidden":!0}),t.createElement("span",{className:sn},p),t.createElement("span",{className:cn,"aria-hidden":"true"},"or"),t.createElement("span",{className:un},m)):t.createElement("label",{htmlFor:x,className:I},t.createElement(S,{name:"upload",size:"medium","aria-hidden":!0}),t.createElement("span",null,m)),T.length>0&&t.createElement("ul",{className:mn,"aria-label":"Selected "+(1===T.length?"file":"files")},T.map((e,n)=>t.createElement("li",{key:`${e.name}-${n}`,className:pn},t.createElement("span",{className:fn,"aria-hidden":"true"},t.createElement(S,{name:qo(e),size:"medium"})),t.createElement("span",{className:hn},t.createElement("span",{className:gn,title:e.name},e.name),t.createElement("span",{className:yn},(e=>{if(!Number.isFinite(e)||e<=0)return"0 B";const t=["B","KB","MB","GB","TB"],n=Math.min(Math.floor(Math.log(e)/Math.log(1024)),t.length-1),a=e/Math.pow(1024,n),r=0===n?0:a<10?1:0;return`${a.toFixed(r)} ${t[n]}`})(e.size))),t.createElement("button",{type:"button",className:vn,onClick:()=>(e=>{const t=T.filter((t,n)=>n!==e);M.current&&(M.current.value=""),A(t)})(n),disabled:h,"aria-label":`Remove ${e.name}`,"data-testid":w?`${w}-remove-${n}`:void 0},t.createElement(S,{name:"close",size:"small","aria-hidden":!0}))))),b&&t.createElement("p",{id:k,role:"alert",className:le},b))},Select:({name:e,id:c,onChange:u,value:d,label:m="",isDisabled:p=!1,className:f="",triggerClassName:h="",triggerActiveClassName:y="",contentsClassName:v="",options:b,onSearch:w,searchDebounce:E=300,searchPlaceholder:x="Search",onAddOption:k,closeOnAddOption:M=!0,isRequired:C=!1,placeholder:D="Select an option",error:P="",isFluid:T=!1,mode:O,isMulti:R=!1,triggerMaxItems:F=2,clearable:I=!0,groups:A=!1,maxSelect:L,dataTestId:$})=>{const j="multi"===(void 0!==O?O:R?"multi":"single"),B=j&&"number"==typeof L&&Number.isFinite(L)&&L>=1?Math.floor(L):null,W=null===b,z=W?[]:b??[];r(()=>{W&&!w&&console.warn("CleanPlate Select: `options={null}` requires an `onSearch` callback.")},[W,w]);const _=o(),q=c??e??_,Y=`${q}-label`,H=`${q}-trigger`,V=`${q}-listbox`,X=`${q}-search`,K=`${q}-error`,U=n(null),G=n(null),Q=n(0),[Z,J]=a(""),[re,oe]=a([]),[ie,se]=a("idle"),[ce,ue]=a(0),[de,me]=a(!1),[pe,fe]=a(null),he=n(null),ge=function(e){const[t,n]=a(()=>"undefined"!=typeof window&&"function"==typeof window.matchMedia&&window.matchMedia(e).matches);return r(()=>{if("undefined"==typeof window||"function"!=typeof window.matchMedia)return;const t=window.matchMedia(e),a=()=>{n(t.matches)};return a(),t.addEventListener("change",a),()=>t.removeEventListener("change",a)},[e]),t}("(max-width: 768px)"),ye=n(ge);ye.current=ge;const[ve,be]=a(!1),[we,Ee]=a(!1),xe=n(!1);xe.current=we;const[Ne,Nt]=a(d),kt=l(()=>ge?[]:[to(4),ao({padding:8}),no({padding:8}),ro({apply({availableHeight:e,rects:t,elements:n}){Object.assign(n.floating.style,{maxHeight:`${Math.max(96,Math.floor(e)-12)}px`,width:`${t.reference.width}px`})}})],[ge]),{refs:Mt,floatingStyles:Ct,context:Dt}=Fo({open:de,placement:ge?"bottom":"bottom-start",strategy:"fixed",transform:!ge,middleware:kt,whileElementsMounted:ge?void 0:Yr,onOpenChange(e){if(!p){if(e)return Ee(!1),void me(!0);if(de)return Ee(!0),be(!1),void me(!1);Ee(!1),me(!1)}}}),St=de||we,Pt=s(e=>{if(e.target!==e.currentTarget)return;if(!xe.current)return;const t=ye.current;t&&"transform"!==e.propertyName||(t||"opacity"===e.propertyName)&&Ee(!1)},[]),Tt=Do(Dt,{enabled:!p}),Ot=Oo(Dt,{ancestorScroll:!ge,bubbles:!1,outsidePressEvent:"pointerdown"}),{getReferenceProps:Rt,getFloatingProps:Ft}=Ao([Tt,Ot]),It=s(()=>{if(de)return Ee(!0),be(!1),void me(!1);Ee(!1),me(!1)},[de]);i(()=>{if(!de)return void(we||be(!1));const e=window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>be(!0))});return()=>window.cancelAnimationFrame(e)},[de,we]);const At=l(()=>{const e=Z.trim().toLowerCase();return e?z.filter(t=>String(t.label).toLowerCase().includes(e)||String(t.value).toLowerCase().includes(e)):z},[z,Z]),Lt=W?re:At,$t=!W&&St&&0===At.length,jt=W&&St&&("loading"===ie||"idle"===ie),Bt=W&&St&&"error"===ie,Wt=W&&St&&"success"===ie&&0===re.length,zt=St&&!$t&&!jt&&!Bt&&!Wt&&Lt.length>0,_t=0===z.length?"No options available":"No matching results",qt=Z.trim(),Yt=qt.toLowerCase(),Ht=qt.length>0&&Lt.some(e=>String(e.label).trim().toLowerCase()===Yt||String(e.value).toLowerCase()===Yt),Vt=St&&!jt&&!Bt&&0===Lt.length&&($t&&qt.length>0||Wt),Xt=Boolean(k)&&!p&&Vt&&!Ht,Kt=$t||Wt,Ut=l(()=>{if(!zt||0===Lt.length)return[];if(!A)return Lt.map(e=>({kind:"option",option:e}));let e;const t=[];return Lt.forEach((n,a)=>{const r=n.group?.trim()??"";r!==e&&(r&&t.push({kind:"header",id:`select-group-${r}-${a}`,label:r}),e=r),t.push({kind:"option",option:n})}),t},[Lt,A,zt]),Gt=l(()=>Lt.filter(e=>!e.disabled),[Lt]),Qt=Array.isArray(Ne)?Ne:[],Zt=l(()=>new Set(Qt.map(e=>e.value)),[Qt]),Jt=null!=B&&Qt.length>=B,{navigableFlat:en,presentationNavFlatIndex:tn,navigableSourceRowIndexes:nn}=l(()=>{const e=[],t=[],n=new Array(Ut.length).fill(null);return Ut.forEach((a,r)=>{if("header"===a.kind)return;const o=a.option,i=j?Qt.some(e=>e.value===o.value):Boolean(Ne&&!Array.isArray(Ne)&&Ne.value===o.value),l=j&&Jt&&!o.disabled&&!i;!o.disabled&&!l&&(n[r]=e.length,e.push(o),t.push(r))}),{navigableFlat:e,presentationNavFlatIndex:n,navigableSourceRowIndexes:t}},[Jt,j,Ut,Qt,Ne]),an=Gt.length>0&&Gt.every(e=>Zt.has(e.value)),rn=Gt.some(e=>Zt.has(e.value))&&!an,on=zt&&j&&Gt.length>0,ln=null!=Ne&&!Array.isArray(Ne),sn=j&&Qt.length>0,cn=sn||ln,un="number"==typeof F&&Number.isFinite(F)&&F>=0?Math.floor(F):2,dn=sn?Qt.slice(0,un):[],mn=sn&&un<Qt.length?Qt.length-un:0,pn=ln&&"object"==typeof Ne&&"label"in Ne?Ne.label:"",fn=`${Ae} ${de?`${Le} ${y}`:""} ${h}`,hn=()=>{const e=document.getElementById(H);e instanceof HTMLElement&&e.focus()},gn=e=>{if(!e.disabled&&!p){if(j){const t=Array.isArray(Ne)?Ne:[],n=t.map(e=>e.value).includes(e.value);if(!n&&Jt)return;if(n){const n=t.filter(t=>t.value!==e.value);Nt(n),u?.(n)}else{const n=[...t,e];Nt(n),u?.(n)}}else Nt(e),u?.(e);It()}},yn=null!=pe&&zt&&en[pe]&&void 0!==nn[pe]?_o(q,nn[pe]):void 0;return r(()=>{de||(he.current=null,fe(null))},[de]),r(()=>{fe(null)},[Z]),r(()=>{if(!de||!he.current)return;if(!zt||0===en.length)return;const e=he.current;he.current=null,fe("first"===e?0:en.length-1)},[de,zt,en]),r(()=>{null!=pe&&zt&&(0!==en.length?pe>=en.length&&fe(en.length-1):fe(null))},[pe,en,zt]),i(()=>{if(null==pe||!zt||null==en[pe]||void 0===nn[pe])return;const e=_o(q,nn[pe]);document.getElementById(e)?.scrollIntoView({block:"nearest",inline:"nearest"})},[pe,en,nn,zt,q]),r(()=>{p&&It()},[p,It]),r(()=>{if(!(ge&&(de||we)))return;const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}},[ge,de,we]),r(()=>{ge||Ee(!1)},[ge]),r(()=>{if(!we)return;const e=80+(ge?300:200),t=window.setTimeout(()=>{Ee(!1)},e);return()=>window.clearTimeout(t)},[we,ge]),r(()=>{Nt(d)},[d]),r(()=>{const e=G.current;e&&(e.indeterminate=rn)},[rn]),r(()=>{if(!St)return Q.current+=1,J(""),oe([]),void se("idle");if(!de)return;if(ge)return;const e=window.requestAnimationFrame(()=>{U.current?.focus()});return()=>window.cancelAnimationFrame(e)},[St,de,ge]),r(()=>{if(!de||!W||!w)return;let e=!1;const t=""===Z.trim()?0:Math.max(0,Number(E)||0),n=window.setTimeout(()=>{const t=Q.current+1;Q.current=t,se("loading");const n=Z.trim();w(n).then(n=>{e||Q.current===t&&(se("success"),oe(Array.isArray(n)?n:[]))}).catch(()=>{e||Q.current===t&&(se("error"),oe([]))})},t);return()=>{e=!0,window.clearTimeout(n)}},[de,W,w,E,Z,ce]),t.createElement("div",{className:N(ee,{[te]:T,[ne]:p},f),"data-testid":$},m&&t.createElement("label",{id:Y,htmlFor:H,className:ae},m," ",C&&t.createElement("span",{"aria-hidden":"true"},"*")),t.createElement("div",{className:ke,"data-invalid":P?"true":void 0},t.createElement("div",g({ref:Mt.setReference},Rt({id:H,role:"combobox",tabIndex:p?-1:0,"aria-haspopup":"listbox","aria-expanded":de,"aria-controls":de?V:void 0,"aria-labelledby":m?Y:void 0,"aria-disabled":p||void 0,"aria-required":C||void 0,"aria-invalid":!!P||void 0,"aria-describedby":P?K:void 0,className:fn,onKeyDown(e){"ArrowDown"!==e.key&&"ArrowUp"!==e.key||de||p||(e.preventDefault(),he.current="ArrowDown"===e.key?"first":"last",me(!0))}})),t.createElement("div",{className:Me},sn?t.createElement("div",{className:Ce},dn.map(e=>{return t.createElement("span",{key:String(e.value),className:De},t.createElement("span",{className:Se},e.label),t.createElement("button",{type:"button",tabIndex:-1,className:Pe,"aria-label":`Remove ${e.label}`,disabled:p,onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:(n=e,e=>{if(e.preventDefault(),e.stopPropagation(),p||!j)return;const t=(Array.isArray(Ne)?Ne:[]).filter(e=>e.value!==n.value);Nt(t),u?.(t)})},t.createElement(S,{name:"close",size:"small",color:"gray"})));var n}),mn>0&&t.createElement("span",{className:Te,"aria-label":`${mn} more selected`},"+",mn)):ln?t.createElement("span",{className:Fe},pn):t.createElement("span",{className:Ie},D)),t.createElement("div",{className:Oe},I&&cn&&!p&&t.createElement("button",{type:"button",tabIndex:-1,className:Re,"aria-label":"Clear selection",onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:e=>{e.preventDefault(),e.stopPropagation(),p||(j?(Nt([]),u?.([])):(Nt(null),u?.(null)),It())}},t.createElement(S,{name:"close",size:"small",color:"gray"})),t.createElement(S,{name:de?"arrow_drop_up":"arrow_drop_down",className:"arrow "+(de?"up":"down"),"aria-hidden":!0}))),St&&t.createElement(No,null,ge?t.createElement("div",{className:We,"data-visible":ge&&ve?"true":void 0,"aria-hidden":!0}):null,t.createElement("div",g({ref:Mt.setFloating},Ft({style:ge?zo:Ct,className:N($e,ge&&ze,ge&&ve&&Ge,!ge&&je,!ge&&ve&&Be,v),onKeyDownCapture:e=>{if(!de||p)return;const t=Mt.floating.current;if(!t?.contains(e.target))return;if("Tab"===e.key)return e.preventDefault(),It(),void queueMicrotask(hn);const n=e.target;if(!!n?.closest("button")&&!n?.closest('[role="option"]')&&"Enter"===e.key)return;if(!zt||0===en.length)return;if(!e.nativeEvent.isComposing){if("ArrowDown"===e.key)return e.preventDefault(),void fe(e=>null==e?0:Math.min(e+1,en.length-1));if("ArrowUp"===e.key)return e.preventDefault(),void fe(e=>null==e?en.length-1:Math.max(e-1,0));if("Home"===e.key)return e.preventDefault(),void fe(0);if("End"===e.key)return e.preventDefault(),void fe(en.length-1);if("Enter"===e.key){e.preventDefault();const t=null!=pe?pe:en.length>0?0:null;null!=t&&t>=0&&t<en.length&&gn(en[t])}}},onTransitionEnd:Pt,...ge?{id:`${q}-select-panel`,role:"dialog","aria-modal":!0,"aria-labelledby":m?Y:void 0}:{}})),t.createElement("div",{className:_e,role:"presentation",onPointerDown:e=>{const t=e.target;t?.closest("input, button, textarea, label")||e.preventDefault()}},t.createElement("div",{className:et},t.createElement(S,{name:"search",className:tt,"aria-hidden":!0}),t.createElement("input",{ref:U,id:X,type:"search",className:N(Ye,Z&&nt),placeholder:x,autoComplete:"off","aria-label":m?`Search ${m}`:"Search options","aria-autocomplete":"list","aria-controls":de?V:void 0,"aria-activedescendant":yn,"aria-invalid":!!P||void 0,value:Z,onChange:e=>J(e.target.value)}),Z?t.createElement("button",{type:"button",className:at,"aria-label":"Clear search",onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:e=>{e.stopPropagation(),J(""),U.current?.focus()}},t.createElement(S,{name:"close",size:"small",color:"gray"})):null)),on?t.createElement("div",{className:qe,role:"presentation",onPointerDown:e=>{const t=e.target;t?.closest("input, button, textarea, label")||e.preventDefault()}},t.createElement("label",{className:Qe},t.createElement("input",{ref:G,type:"checkbox",className:Ze,checked:an,disabled:p,tabIndex:-1,"aria-label":m?`Select all matching ${m} options`:"Select all matching options",onChange:e=>{if(e.stopPropagation(),p||!j)return;const t=Gt;if(0===t.length)return;const n=new Set(t.map(e=>e.value));if(an){const e=Qt.filter(e=>!n.has(e.value));return Nt(e),void u?.(e)}let a=[...Qt];const r=B??Number.MAX_SAFE_INTEGER,o=new Set(a.map(e=>e.value));for(const e of t){if(a.length>=r)break;o.has(e.value)||(a.push(e),o.add(e.value))}Nt(a),u?.(a)},onClick:e=>e.stopPropagation()}),t.createElement("span",null,"Select all")),t.createElement("button",{type:"button",className:Je,disabled:p||0===Qt.length,onMouseDown:e=>{e.preventDefault()},onClick:e=>{e.preventDefault(),e.stopPropagation(),!p&&j&&0!==Qt.length&&(Nt([]),u?.([]))}},"Clear all")):null,t.createElement("div",{id:V,role:zt?"listbox":"group","aria-label":zt?m?void 0:"Options":m?`${m} options panel`:"Options panel","aria-multiselectable":!(!zt||!j)||void 0,"aria-labelledby":zt&&m?Y:void 0,"aria-busy":jt||void 0,"aria-invalid":!!P||void 0,className:Ue},jt?t.createElement("div",{className:Ke,"aria-live":"polite"},t.createElement(Wo,{size:"small",margin:"0"}),t.createElement("span",{className:rt},"Loading…")):null,Bt?t.createElement("div",{className:Ke,role:"alert"},t.createElement("span",{className:ot},"Couldn’t load options. Check your connection and try again."),t.createElement("button",{type:"button",className:ct,onMouseDown:e=>{e.preventDefault()},onClick:e=>{e.stopPropagation(),ue(e=>e+1),U.current?.focus()}},"Retry")):null,Kt?t.createElement("div",{className:N(Xe,Xt&&it)},t.createElement("div",{className:Ke,"aria-live":"polite"},t.createElement("span",{className:ot},$t?_t:"No results")),Xt?t.createElement("button",{type:"button",className:st,onMouseDown:e=>{e.preventDefault()},onClick:e=>{e.preventDefault(),e.stopPropagation();const t=Z.trim();!t||p||Ht||(k?.(t),J(""),M?It():U.current?.focus())}},t.createElement(S,{name:"add_circle",size:"small",className:lt,"aria-hidden":!0}),t.createElement("span",null,'Add "',qt,'"')):null):null,zt?Ut.map((e,n)=>{if("header"===e.kind)return t.createElement("div",{key:e.id,className:Ve,role:"presentation"},e.label);const{option:a}=e,r=tn[n],o=null!=r&&r===pe,i=j?Qt.some(e=>e.value===a.value):Ne&&!Array.isArray(Ne)&&a.value===Ne.value,l=j&&Jt&&!a.disabled&&!i,s=Boolean(a.avatar||a.icon),c=_o(q,n);return t.createElement("div",{key:`${c}-${e.kind}`,id:c,role:"option","aria-selected":Boolean(i),"aria-disabled":!(!a.disabled&&!l)||void 0,className:N(He,s&&ut,a.disabled&&dt,l&&mt,i&&pt,o&>),onMouseEnter:()=>{null==r||a.disabled||p||l||fe(r)},onMouseDown:e=>{a.disabled||p||l||e.preventDefault()},onClick:e=>{return t=e,void((n=a).disabled||p||(t.stopPropagation(),t.preventDefault(),gn(n)));var t,n}},s?t.createElement("span",{className:yt,"aria-hidden":!0},a.avatar?t.createElement("img",{src:a.avatar,alt:"",className:vt,draggable:!1}):a.icon?t.createElement(S,{name:a.icon,size:"medium",className:ht}):null):null,t.createElement("div",{className:bt},t.createElement("span",{className:wt},a.label),a.meta?t.createElement("span",{className:ft},a.meta):null),t.createElement("span",{className:Et},i?t.createElement(S,{name:"done",className:xt}):null))}):null)))),e&&t.createElement("input",{type:"hidden",name:e,value:j?Qt.map(e=>String(e.value)).join(","):Ne&&!Array.isArray(Ne)?String(Ne.value):""}),P&&t.createElement("p",{id:K,role:"alert",className:le},P))},Checkbox:({options:e,name:n,id:r,label:i,value:l,defaultValue:s,onChange:c,isDisabled:u=!1,isRequired:d=!1,isFluid:m=!1,orientation:p="vertical",variant:f="default",error:h="",className:g="",dataTestId:y})=>{const v=o(),b=r??n??v,w=`${b}-legend`,E=`${b}-error`,x=void 0!==l,[k,M]=a(s??[]),C=x?l:k,D=N(ee,$t,{[te]:m},g),S=N(Bt,"horizontal"===p?zt:Wt,"card"===f?Gt:"");return t.createElement("fieldset",{className:D,disabled:u,"aria-invalid":!!h||void 0,"aria-describedby":h?E:void 0,"data-invalid":h?"true":void 0,"data-variant":f,"data-testid":y},t.createElement("legend",{id:w,className:N(ae,jt)},i,d&&t.createElement(t.Fragment,null," ",t.createElement("span",{"aria-hidden":"true"},"*"))),t.createElement("div",{className:S,role:"group","aria-labelledby":w,"aria-required":d||void 0},e.map((e,a)=>{const r=e.id??`${b}-${o=e.value,null==o?"option":String(o).replace(/\W/g,"-")||"option"}-${a}`;var o;const i=e.description?`${r}-desc`:void 0,l=u||Boolean(e.isDisabled),s=C.some(t=>String(t)===String(e.value));return t.createElement("div",{key:r,className:_t},t.createElement("input",{className:N(xe,Ut),type:"checkbox",name:n,id:r,value:String(e.value),checked:s,disabled:l,"aria-invalid":!!h||void 0,"aria-describedby":[h?E:void 0,i].filter(Boolean).join(" ")||void 0,"aria-label":e.label?void 0:String(e.value),"data-testid":e.dataTestId,onChange:t=>((e,t,n)=>{const a=C,r=t?Array.from(new Set([...a,e])):a.filter(t=>String(t)!==String(e));x||M(r),c?.(r,n)})(e.value,t.target.checked,t)}),t.createElement("label",{htmlFor:r,className:N(ae,re)},t.createElement("span",{className:Xt,"aria-hidden":"true"},t.createElement("span",{className:Kt})),void 0!==e.icon&&null!==e.icon&&t.createElement("span",{className:qt,"aria-hidden":"true"},e.icon),e.label&&t.createElement("span",{className:Yt},t.createElement("span",{className:Ht},e.label),e.description&&t.createElement("span",{id:i,className:Vt},e.description))))})),h&&t.createElement("p",{id:E,role:"alert",className:le},h))},Radio:({options:e,name:n,id:r,label:i,value:l,defaultValue:s,onChange:c,isDisabled:u=!1,isRequired:d=!1,isFluid:m=!1,orientation:p="vertical",variant:f="default",error:h="",className:g="",dataTestId:y})=>{const v=o(),b=r??n??v,w=`${b}-legend`,E=`${b}-error`,x=void 0!==l,[k,M]=a(s),C=x?l:k,D=N(ee,Nt,{[te]:m},g),S=N(Mt,"horizontal"===p?Dt:Ct,"card"===f?Lt:""),P=e.findIndex(e=>!e.isDisabled&&!u);return t.createElement("fieldset",{className:D,disabled:u,"aria-invalid":!!h||void 0,"aria-describedby":h?E:void 0,"data-invalid":h?"true":void 0,"data-variant":f,"data-testid":y},t.createElement("legend",{id:w,className:N(ae,kt)},i,d&&t.createElement(t.Fragment,null," ",t.createElement("span",{"aria-hidden":"true"},"*"))),t.createElement("div",{className:S,role:"radiogroup","aria-labelledby":w,"aria-required":d||void 0},e.map((e,a)=>{const r=e.id??`${b}-${o=e.value,null==o?"option":String(o).replace(/\W/g,"-")||"option"}-${a}`;var o;const i=e.description?`${r}-desc`:void 0,l=u||Boolean(e.isDisabled),s=d&&a===P,m=void 0!==C&&String(C)===String(e.value);return t.createElement("div",{key:r,className:St},t.createElement("input",{className:N(xe,Ft),type:"radio",name:n,id:r,value:String(e.value),checked:m,disabled:l,required:s,"aria-required":s||void 0,"aria-invalid":!!h||void 0,"aria-describedby":[h?E:void 0,i].filter(Boolean).join(" ")||void 0,"aria-label":e.label?void 0:String(e.value),"data-testid":e.dataTestId,onChange:t=>((e,t)=>{x||M(e),c?.(e,t)})(e.value,t)}),t.createElement("label",{htmlFor:r,className:N(ae,re)},t.createElement("span",{className:It,"aria-hidden":"true"},t.createElement("span",{className:At})),void 0!==e.icon&&null!==e.icon&&t.createElement("span",{className:Pt,"aria-hidden":"true"},e.icon),e.label&&t.createElement("span",{className:Tt},t.createElement("span",{className:Ot},e.label),e.description&&t.createElement("span",{id:i,className:Rt},e.description))))})),h&&t.createElement("p",{id:E,role:"alert",className:le},h))},Date:({value:e,defaultValue:c=null,onChange:u,placeholder:d="Select date",dateFormat:m="MMM dd, yyyy",id:p,name:f,minDate:h,maxDate:y,disabledDates:v,disabledDaysOfWeek:b,locale:w=Jo,weekStartsOn:E=0,clearable:x=!0,isDisabled:k=!1,readOnly:M=!1,label:C="",error:D="",isFluid:P=!1,dataTestId:T,isRequired:O=!1,popoverPlacement:R="bottom-start",onOpen:F,onClose:I,className:A=""})=>{const L=o(),$=p??L,j=`${$}-label`,B=`${$}-error`,W=`${$}-trigger`,z=`${$}-date-panel`,_=`${$}-grid-caption`,q=Qi(h),Y=Qi(y),H=l(()=>function(e){if(!e?.length)return;const t=[];for(const n of e){const e=Qi(n);e&&t.push(e)}return t.length?t:void 0}(v),[v]),V=void 0===e?void 0:null===e?null:Qi(e)??null,X=void 0===c?void 0:null===c?null:Qi(c)??null,K=void 0!==e,U=H?.map(e=>Ui(e).getTime()).join("|")??"",G=b?.join(",")??"",Q=l(()=>({minDate:q,maxDate:Y,disabledDates:H,disabledDaysOfWeek:b}),[q?.getTime(),Y?.getTime(),U,G,v,b]),Z=cl({value:K?V:void 0,defaultValue:K?void 0:X,onChange:u,constraints:Q}),J=n(Z.isOpen);r(()=>{Z.isOpen&&!J.current&&F?.(),!Z.isOpen&&J.current&&I?.(),J.current=Z.isOpen},[F,I,Z.isOpen]);const re=function(e){const[t,n]=a(()=>"undefined"!=typeof window&&"function"==typeof window.matchMedia&&window.matchMedia(e).matches);return r(()=>{if("undefined"==typeof window||"function"!=typeof window.matchMedia)return;const t=window.matchMedia(e),a=()=>{n(t.matches)};return a(),t.addEventListener("change",a),()=>t.removeEventListener("change",a)},[e]),t}("(max-width: 768px)"),oe=n(re);oe.current=re;const[ie,se]=a(!1),[ce,ue]=a(!1),de=n(!1);de.current=ce;const me=s(e=>{ue(!0),se(!1),e()},[]),pe=l(()=>re?[]:[to(4),ao({padding:8}),no({padding:8})],[re]),{refs:fe,floatingStyles:he,context:ge}=Fo({open:Z.isOpen&&!k&&!M,placement:re?"bottom":R,strategy:"fixed",transform:!re,middleware:pe,whileElementsMounted:re?void 0:Yr,onOpenChange(e){if(!k&&!M)return e?(ue(!1),void Z.open()):void(Z.isOpen?me(()=>Z.cancel()):ue(!1))}}),ye=Z.isOpen||ce,ve=s(e=>{if(e.target!==e.currentTarget)return;if(!de.current)return;const t=oe.current;t&&"transform"!==e.propertyName||(t||"opacity"===e.propertyName)&&ue(!1)},[]);i(()=>{if(!Z.isOpen)return void(ce||se(!1));const e=window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>se(!0))});return()=>window.cancelAnimationFrame(e)},[Z.isOpen,ce]),r(()=>{if(!re)return;if(!Z.isOpen&&!ce)return;const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}},[re,Z.isOpen,ce]),r(()=>{re||ue(!1)},[re]),r(()=>{if(!ce)return;const e=80+(re?300:200),t=window.setTimeout(()=>{ue(!1)},e);return()=>window.clearTimeout(t)},[ce,re]);const be=Do(ge,{enabled:!k&&!M}),we=Oo(ge,{ancestorScroll:!re,bubbles:!1,outsidePressEvent:"pointerdown"}),{getReferenceProps:Ee,getFloatingProps:xe}=Ao([be,we]);r(()=>{(k||M)&&Z.isOpen&&me(()=>Z.cancel())},[me,k,M,Z.isOpen,Z.cancel]);const Ne=null!=Z.committed?Wi(Ui(Z.committed),m,{locale:w}):"",Ce=N($e,re&&ze,wn,re&&ie&&Ge,!re&&je,!re&&ie&&Be);return t.createElement("div",{className:N(ee,{[te]:P,[ne]:k},A),"data-testid":T},C?t.createElement("label",{id:j,htmlFor:W,className:ae},C," ",O?t.createElement("span",{"aria-hidden":"true"},"*"):null):null,t.createElement("div",{className:ke,"data-invalid":D?"true":void 0},t.createElement("div",g({ref:fe.setReference},Ee({id:W,className:N(Ae,Z.isOpen&&Le),role:"combobox",tabIndex:k||M?-1:0,"aria-expanded":Z.isOpen,"aria-controls":Z.isOpen?z:void 0,"aria-haspopup":"dialog","aria-labelledby":C?j:void 0,"aria-disabled":k||void 0,"aria-required":O||void 0,"aria-invalid":!!D||void 0,"aria-describedby":D?B:void 0,"aria-readonly":M||void 0,onKeyDown(e){e.defaultPrevented||k||M||("Enter"!==e.key&&" "!==e.key||(e.preventDefault(),Z.isOpen||Z.open()),!Z.isOpen||"Escape"!==e.key&&"Esc"!==e.key||(e.preventDefault(),me(()=>Z.cancel())))}})),t.createElement("div",{className:Me},Ne?t.createElement("span",{className:Fe},Ne):t.createElement("span",{className:Ie},d)),t.createElement("div",{className:Oe},x&&Z.committed&&!k&&!M?t.createElement("button",{type:"button",tabIndex:-1,className:Re,"aria-label":"Clear selection",onMouseDown:e=>{e.preventDefault(),e.stopPropagation()},onClick:e=>{e.preventDefault(),e.stopPropagation(),k||(Z.isOpen?me(()=>Z.clearCommitted()):Z.clearCommitted())}},t.createElement(S,{name:"close",size:"small",color:"gray"})):null,t.createElement(S,{name:"calendar_month",size:"small",color:"gray","aria-hidden":!0}))),ye?t.createElement(No,null,re?t.createElement("div",{className:We,"data-visible":re&&ie?"true":void 0,"aria-hidden":!0}):null,t.createElement("div",g({ref:fe.setFloating},xe({id:z,role:"dialog","aria-modal":re||void 0,"aria-labelledby":C?j:void 0,className:Ce,style:re?ul:he,onPointerDown:e=>{const t=e.target;t?.closest("button, input, textarea, select, a")||e.preventDefault()},onTransitionEnd:ve})),t.createElement(ll,{panelId:z,gridLabelId:_,locale:w,weekStartsOn:E,constraints:Q,picker:Z,onRequestCancel:()=>me(()=>Z.cancel()),onRequestConfirm:()=>me(()=>Z.confirm())}))):null),f?t.createElement("input",{type:"hidden",name:f,value:Z.committed?(De=Z.committed,Wi(Ui(De),"yyyy-MM-dd")):""}):null,D?t.createElement("p",{id:B,role:"alert",className:le},D):null);var De},Stepper:({name:e,id:r,onChange:i,defaultValue:l,value:s,label:c="",isDisabled:u=!1,isRequired:d=!1,isFluid:m=!1,type:p="number",className:f="",placeholder:h="",error:y="",dataTestId:v,min:b,max:w,step:E=1})=>{const x=o(),k=r??e??x,M=`${k}-error`,C=n(null),D="number"===p,P=D?"text":p,T=D?"numeric":void 0,O=D?"[0-9]*":void 0,R=void 0!==s,[F,I]=a(()=>l??""),A=R?s??"":F,L=Number(E),$=Number.isFinite(L)&&L>0?L:1,j=void 0!==b?Number(b):-1/0,B=void 0!==w?Number(w):1/0,W=e=>{if(""===e||void 0===e)return null;const t=parseInt(e,10);return Number.isNaN(t)?null:t},z=N(ee,{[te]:m},f),_=y?ie:"",q=N(oe,ve,_,u?fe:""),Y=N(be,_),H=e=>{if(!D||u)return;const t=C.current;if(!t)return;let n=W(t.value);null===n&&(n=Number.isFinite(j)?j:0);const a=(r=n+e*$,Math.min(B,Math.max(j,r)));var r;a!==n?((e=>{const t=C.current;if(!t)return;const n=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value")?.set;n?.call(t,e),t.dispatchEvent(new Event("input",{bubbles:!0}))})(String(a)),t.focus()):t.focus()},V=W(A),X=void 0!==b&&null!==V&&V<=j&&Number.isFinite(j),K=void 0!==w&&null!==V&&V>=B&&Number.isFinite(B),U=y?M:void 0,G=t.createElement("input",{ref:C,className:Y,type:P,inputMode:T,pattern:O,disabled:u,required:d,"aria-required":d||void 0,"aria-invalid":!!y||void 0,"aria-describedby":U,name:e,id:k,placeholder:h,value:A,onChange:e=>{const t=e.target;if(D&&/\D/.test(t.value)){const e=t.value.replace(/\D/g,""),n=t.value.length-e.length,a=(t.selectionStart??e.length)-n;t.value=e;const r=Math.max(0,Math.min(a,e.length));((e,t,n)=>{if(dl.has(e.type))try{e.setSelectionRange(t,n)}catch{}})(t,r,r)}R||I(t.value),i?.(e)},onBeforeInput:D?e=>{if(!D)return;const t=e.nativeEvent.data;t&&/\D/.test(t)&&e.preventDefault()}:void 0,"data-testid":v});return t.createElement("div",{className:z},c&&t.createElement("label",{className:ae,htmlFor:k},c," ",d&&t.createElement("span",{"aria-hidden":"true"},"*")),D?t.createElement("div",{className:q},G,t.createElement("span",{className:we,"aria-hidden":!0}),t.createElement("button",{type:"button",className:Ee,disabled:u||X,"aria-label":"Decrease value",onClick:()=>H(-1),"data-testid":v?`${v}-decrement`:void 0},t.createElement(S,{name:"remove",size:"medium",color:"gray","aria-hidden":!0})),t.createElement("span",{className:we,"aria-hidden":!0}),t.createElement("button",{type:"button",className:Ee,disabled:u||K,"aria-label":"Increase value",onClick:()=>H(1),"data-testid":v?`${v}-increment`:void 0},t.createElement(S,{name:"add",size:"medium",color:"gray","aria-hidden":!0}))):t.createElement("input",g({className:N(oe,_),type:p,disabled:u,required:d,"aria-required":d||void 0,"aria-invalid":!!y||void 0,"aria-describedby":U,name:e,id:k,placeholder:h},void 0!==s?{value:s??""}:void 0!==l?{defaultValue:l}:{},{onChange:e=>i?.(e),"data-testid":v})),y&&t.createElement("p",{id:M,role:"alert",className:le},y))},Toggle:({name:e,id:n,onChange:r,defaultChecked:i=!1,checked:l,label:s="",isDisabled:c=!1,isRequired:u=!1,className:d="",isFluid:m=!1,error:p="",dataTestId:f})=>{const h=o(),y=n??e??h,v=`${y}-error`,b=void 0!==l,[w,E]=a(i),x=b?Boolean(l):w,k=N(ee,Qt,{[te]:m},d);return t.createElement("div",{className:k,"data-invalid":p?"true":void 0},t.createElement("div",{className:Zt},t.createElement("input",g({className:N(xe,nn),type:"checkbox",role:"switch",disabled:c,required:u,"aria-required":u||void 0,"aria-invalid":!!p||void 0,"aria-describedby":p?v:void 0,"aria-label":s?void 0:e,name:e,id:y,onChange:e=>{const t=e.target.checked;b||E(t),r?.(t)},"data-testid":f},b?{checked:x}:{defaultChecked:i})),t.createElement("label",{htmlFor:y,className:Jt},t.createElement("span",{className:en,"aria-hidden":"true"},t.createElement("span",{className:tn})),s&&t.createElement("span",null,s,u&&t.createElement(t.Fragment,null," ",t.createElement("span",{"aria-hidden":"true"},"*"))))),p&&t.createElement("p",{id:v,role:"alert",className:le},p))}},pl="dropdown-wrapper-L38Fh",fl="dropdown-trigger-Dy532",hl="active-pBlCN",gl="dropdown-floating-grA69",yl="dropdown-bottom-end-ppCny",vl="dropdown-content-7NtCD",bl="dropdown-opening-PSBid",wl="dropdown-closing-P1g7e";const El={top:"dropdown-top--mr9A","top-start":"dropdown-top-start-rPvbp","top-end":"dropdown-top-end-45Q-B",bottom:"dropdown-bottom-AicwP","bottom-start":"dropdown-bottom-start-VQQjR","bottom-end":yl,left:"dropdown-left-4iIk-","left-start":"dropdown-left-start-ytM0o","left-end":"dropdown-left-end-ouy21",right:"dropdown-right-p19EW","right-start":"dropdown-right-start-aYDFP","right-end":"dropdown-right-end-4nWiV"},xl={top:"bottom","top-start":"bottom-start","top-end":"bottom-end",bottom:"top","bottom-start":"top-start","bottom-end":"top-end",left:"right","left-start":"right-start","left-end":"right-end",right:"left","right-start":"left-start","right-end":"left-end"},Nl=({trigger:e,content:o,placement:i="bottom-end",offset:l=4,shift:s=!0,flip:u=!0,closeOnClickOutside:d=!0,closeOnEscape:m=!0,className:p="",contentClassName:f="",renderTrigger:h,triggerLabel:g})=>{const[y,v]=a(!1),[b,w]=a(!1),[E,x]=a(i),N=n(null),k=n(null),M=()=>{y?C():(v(!0),w(!0))},C=()=>{w(!1),setTimeout(()=>{v(!1),x(i)},150)};r(()=>{const e=e=>{d&&y&&k.current&&!k.current.contains(e.target)&&N.current&&!N.current.contains(e.target)&&v(!1)},t=e=>{m&&"Escape"===e.key&&y&&v(!1)};return y&&(document.addEventListener("mousedown",e),document.addEventListener("keydown",t)),()=>{document.removeEventListener("mousedown",e),document.removeEventListener("keydown",t)}},[y,d,m]),r(()=>{y&&k.current&&requestAnimationFrame(()=>{const e=(()=>{if(!N.current||!k.current)return i;N.current.getBoundingClientRect();const e=k.current.getBoundingClientRect(),t=window.innerWidth,n=window.innerHeight;let a=i;k.current&&k.current.style.setProperty("--offset",`${l}px`),u&&(e.left<8||e.right>t-8||e.top<8||e.bottom>n-8)&&(a=xl[i]??i);if(s){let a=0,r=0;e.left<8?a=8-e.left:e.right>t-8&&(a=t-8-e.right),e.top<8?r=8-e.top:e.bottom>n-8&&(r=n-8-e.bottom),k.current&&(k.current.style.setProperty("--shift-x",`${a}px`),k.current.style.setProperty("--shift-y",`${r}px`))}return a})();x(e)})},[y,i,u,s]);if(!e&&!h&&!g)throw new Error("Dropdown requires either a 'trigger' element, 'renderTrigger' function, or 'triggerLabel' string");const D=(()=>{const n={ref:N,onClick:M,className:`${fl} ${y?hl:""}`.trim(),role:"button","aria-expanded":y,"aria-haspopup":"true"};return h?h({isOpen:y,isAnimating:b,placement:E,toggle:M,close:C,triggerProps:n}):g?t.createElement("span",{ref:N,style:{display:"inline-flex"}},t.createElement(F,{variant:"outline",onClick:M,style:{display:"flex",alignItems:"center",gap:"var(--space-1)"},className:n.className,"aria-expanded":y,"aria-haspopup":"true"},g,t.createElement(S,{name:y?"keyboard_arrow_up":"keyboard_arrow_down",style:{fontSize:"16px"}}))):e?c(e,{...n,className:`${e.props.className??""} ${n.className}`.trim()}):null})(),P=c(o,{onClose:C,className:`${o.props.className??""} ${vl} ${f}`.trim()});return t.createElement("div",{className:`${pl} ${p}`},D,y&&t.createElement("div",{ref:k,className:`${gl} ${El[E]??yl} ${b?bl:wl}`,role:"menu","aria-orientation":"vertical"},P))};var kl={avatar:"avatar-9PMbK",small:"small-G0ZqH",medium:"medium-2yDpn",image:"image-Ex-Xp",icon:"icon-Fhtoo"};const Ml=({size:e="medium",margin:n="m-0",onClick:a,name:r="",image:o="",icon:i,className:l="",...s})=>{const c=((e="")=>e.split(" ").map(e=>e[0]).join("").toUpperCase().substring(0,2))(r),u=b(n,v,"m"),d=N(kl.avatar,kl[e],u,l,{[kl.image]:!!o,[kl.icon]:!!i}),m=((e="")=>`#${e.split("").reduce((e,t)=>e+t.charCodeAt(0),0).toString(16).substring(0,6)}`)(r);return t.createElement("div",g({className:d,onClick:e=>{"function"==typeof a&&a(e)},title:r,style:{backgroundColor:m}},s),!i&&o&&t.createElement("img",{src:o,alt:r}),!o&&i&&t.createElement(S,{size:"medium",name:i}),!o&&!i&&c)};var Cl="cp-media-object-PE7e4",Dl="cp-media-object-content-RoCmF",Sl="cp-media-object-media-yP5fy";const Pl=({mediaIcon:e="",mediaImage:n="",mediaAvatar:a="",title:r,description:o,margin:i="0",padding:l="0",className:s="media-object",onClick:c,...u})=>{const d=b(i,v,"m"),m=b(l,v,"p"),p=N(Cl,d,m,s),f=e=>{"function"==typeof c&&c(e)};return t.createElement("div",g({className:p,onClick:f},u),t.createElement("div",{className:Sl},t.createElement(Ml,{name:a,image:n,icon:e||void 0,onClick:c?f:void 0})),t.createElement("div",{className:Dl},t.createElement(C,{isBold:!0},r),o&&t.createElement(C,{variant:"small"},o)))};var Tl={stepper:"stepper-hM2qw","stepper-item":"stepper-item--nZ-a","stepper-link":"stepper-link-1VIxA","stepper-count":"stepper-count-L8O8v","stepper-count-icon":"stepper-count-icon-FDKjZ",separator:"separator-rMT-l",active:"active-qamu2"};const Ol=({step:e,order:n,onClick:a})=>{const r=N(Tl["stepper-item"],{[Tl.active]:e.isActive,[Tl.completed]:e.isCompleted});return t.createElement("div",{className:r},t.createElement("span",{className:Tl["stepper-count"],onClick:a},e.isCompleted?t.createElement(S,{name:"done",className:Tl["stepper-count-icon"]}):n),t.createElement("span",{className:Tl.separator}),t.createElement("a",{className:Tl["stepper-link"],onClick:a,href:e.key},e.label))},Rl=({variant:e,margin:n="0",className:a="",config:r,onClick:o})=>{const i=b(n,v,"m"),l=N(Tl.stepper,{[Tl[e??""]]:!!e},i,a);return t.createElement("div",{className:l},r.map((e,n)=>t.createElement(Ol,{key:e.key,step:e,order:n+1,onClick:t=>((e,t)=>{e.preventDefault(),"function"==typeof o&&o(t)})(t,e)})))};var Fl={"toast-container":"toast-container-auY7R",toast:"toast-nizUg",fadeIn:"fadeIn-Y8XmX",success:"success-axGeX",warning:"warning-ZmYvy",error:"error-35Ubu",info:"info-aF2Fp",icon:"icon-jNo3c"};const Il=({mode:e,onClose:n,message:a})=>{const r=l(()=>[Fl.toast,Fl[e]].join(" "),[e]),o=E(e);return t.createElement("div",{onClick:n,className:r,role:"button",tabIndex:0,onKeyDown:e=>"Enter"===e.key&&n()},t.createElement(S,{className:Fl.icon,name:o,size:"medium"}),t.createElement("div",{className:Fl.message},a))},Al=u(({autoClose:e=!1,autoCloseTime:o=5e3},i)=>{const[l,s]=a([]),c=n(l);c.current=l;const{loaded:u,portalId:m}=(()=>{const[e,t]=a(!1),[n]=a(`toast-portal-${w()}`);return r(()=>{const e=document.createElement("div");e.id=n,e.style.cssText="position: fixed; top: 16px; right: 16px";const a=document.getElementsByTagName("body")[0];if(a)return a.prepend(e),t(!0),()=>{a.removeChild(e)}},[n]),{loaded:e,portalId:n}})();(({toasts:e,setToasts:t,autoClose:n,autoCloseTime:o})=>{const[i,l]=a("");r(()=>{i&&t(e=>e.filter(e=>e.id!==i))},[i,t]),r(()=>{if(n&&e.length){const t=e[e.length-1].id,n=setTimeout(()=>l(t),o);return()=>clearTimeout(n)}},[e,n,o])})({toasts:l,setToasts:s,autoClose:e,autoCloseTime:o});if(d(i,()=>({addMessage(e){s([...c.current,{...e,id:w()}])}}),[]),!u)return null;const p=document.getElementById(m);return p?h.createPortal(t.createElement("div",{className:Fl["toast-container"]},l.map(e=>t.createElement(Il,{key:e.id,mode:e.mode,message:e.message,onClose:()=>{return t=e.id,void s(e=>e.filter(e=>e.id!==t));var t}}))),p):null});Al.displayName="Toast";var Ll="cp-page-header-uXFX0",$l="cp-page-header__row-ZULep",jl="cp-page-header__left-h21VP",Bl="cp-page-header__title-FZ9-0",Wl="cp-page-header__subtitle-v5qVs",zl="cp-page-header__right-OtOV7",_l="cp-page-header__cta-mMff6",ql="cp-page-header__more-wDsIy",Yl="cp-page-header__more-trigger--NnJT",Hl="cp-page-header__more-list-JaQ10",Vl="cp-page-header__more-item-827wH";const Xl=({items:e,onClose:n,className:a})=>t.createElement("ul",{className:a,role:"menu"},e.map((e,a)=>t.createElement("li",{key:a,role:"none"},t.createElement("button",{type:"button",role:"menuitem",className:Vl,onClick:()=>{e.onClick?.(),n?.()}},e.label)))),Kl=({title:e,subtitle:n,primaryCta:a,moreMenuItems:r,moreMenuContent:o,className:i=""})=>{const l=(r?.length??0)>0||null!=o,s=N(Ll,i),c=({triggerProps:e})=>t.createElement("span",{ref:e.ref,style:{display:"inline-flex"}},t.createElement(F,{variant:"icon",size:"small",className:N(Yl,e.className),onClick:e.onClick},t.createElement(S,{name:"more_vert",size:"small"})));return t.createElement("header",{className:s},t.createElement("div",{className:$l},t.createElement("div",{className:jl},"string"==typeof e?t.createElement(C,{variant:"h4",className:Bl},e):t.createElement("div",{className:Bl},e),null!=n&&t.createElement(t.Fragment,null,"string"==typeof n?t.createElement(C,{variant:"p",className:Wl},n):t.createElement("div",{className:Wl},n))),t.createElement("div",{className:zl},null!=a&&t.createElement("div",{className:_l},a),l&&t.createElement("div",{className:ql},null!=r&&r.length>0?t.createElement(Nl,{placement:"bottom-end",content:t.createElement(Xl,{items:r,className:Hl}),renderTrigger:c}):null!=o?t.createElement(Nl,{placement:"bottom-end",content:t.createElement("div",{className:Hl},o),renderTrigger:c}):null))))};Kl.displayName="PageHeader";var Ul="cp-breadcrumb-n7jGG",Gl="cp-breadcrumb__list-IN6yA",Ql="cp-breadcrumb__item-RiJzG",Zl="cp-breadcrumb__link-5w7RA",Jl="cp-breadcrumb__current-JduVv",es="cp-breadcrumb__label-ofOpE",ts="cp-breadcrumb__separator-KvPMy",ns="cp-breadcrumb__separator-icon-ey1xq",as="cp-breadcrumb_separator-slash-kqkp0";const rs=({items:e,separator:n="chevron",ariaLabel:a="Breadcrumb",margin:r,className:o=""})=>{const i=r?b(r,v,"m"):void 0,l=N(Ul,"slash"===n&&as,i,o);return t.createElement("nav",{className:l,"aria-label":a},t.createElement("ol",{className:Gl,itemScope:!0,itemType:"https://schema.org/BreadcrumbList"},e.map((a,r)=>{const o=r===e.length-1&&null==a.href;return t.createElement("li",{key:r,className:Ql,itemProp:"itemListElement",itemScope:!0,itemType:"https://schema.org/ListItem"},r>0&&t.createElement("span",{className:ts,"aria-hidden":"true"},"chevron"===n?t.createElement(S,{name:"chevron_right",size:"small",className:ns}):"/"),o?t.createElement("span",{className:Jl,"aria-current":"page",itemProp:"name"},a.label):a.href?t.createElement("a",{href:a.href,className:Zl,itemProp:"item"},t.createElement("span",{itemProp:"name"},a.label)):t.createElement("span",{className:es,itemProp:"name"},a.label),t.createElement("meta",{itemProp:"position",content:String(r+1)}))})))};function os(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}rs.displayName="BreadCrumb";var is,ls={exports:{}},ss={exports:{}},cs={};var us,ds,ms,ps,fs,hs,gs,ys,vs,bs,ws,Es,xs,Ns,ks={};
|
|
6
6
|
/** @license React v16.13.1
|
|
7
7
|
* react-is.development.js
|
|
8
8
|
*
|