@bluealba/pae-ui-react-core 4.8.0-develop-448 → 4.8.0-develop-451
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +39 -38
- package/dist/index.esm.js +1805 -1783
- package/dist/index.systemjs.js +40 -39
- package/dist/index.umd.js +40 -39
- package/package.json +1 -1
package/dist/index.umd.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
(function(E,S){typeof exports=="object"&&typeof module<"u"?S(exports,require("react"),require("single-spa"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","single-spa","react-dom"],S):(E=typeof globalThis<"u"?globalThis:E||self,S(E["@bluealba/pae-ui-react-core"]={},E.React,E.singleSpa,E.ReactDOM))})(this,function(E,S,he,Wt){"use strict";var nf=E=>{throw TypeError(E)};var Ti=(E,S,he)=>S.has(E)||nf("Cannot "+he);var x=(E,S,he)=>(Ti(E,S,"read from private field"),he?he.call(E):S.get(E)),M=(E,S,he)=>S.has(E)?nf("Cannot add the same private member more than once"):S instanceof WeakSet?S.add(E):S.set(E,he),I=(E,S,he,Wt)=>(Ti(E,S,"write to private field"),Wt?Wt.call(E,he):S.set(E,he),he),V=(E,S,he)=>(Ti(E,S,"access private method"),he);var Ro=(E,S,he,Wt)=>({set _(hr){I(E,S,hr,he)},get _(){return x(E,S,Wt)}});var nn,Pt,An,Ld,Rn,At,On,Dd,rn,Nd,In,jn,je,on,be,cr,sn,We,mt,Md,et,$d,tt,_e,an,nt,Ut,Fd,dt,He,ur,Bd,ue,Rt,Ot,kn,Ln,It,Dn,Nn,Ud,Te,K,dr,xe,ln,Mn,jt,kt,fr,$n,Fn,cn,un,Lt,Bn,ee,pr,Pi,Ai,Ri,Oi,Ii,ji,ki,rf,Wd,Dt,Nt,Pe,ft,pt,Oo,Li,Hd;var hr=document.createElement("style");hr.textContent=`:root{--platform-label-color: var(--platform-text-secondary-color);--platform-input-border-color: var(--platform-lines);--platform-input-background-color: var(--platform-background-secondary-color);--platform-input-color: var(--platform-text-primary-color);--platform-input-focus-border-color: var(--platform-color-primary);--platform-button-base-padding: 4px 16px;--platform-button-base-border-radius: 6px;--platform-button-base-box-shadow: 0 1px 2px 0 rgba(0, 0, 0, .05);--platform-button-base-font-size: 1em;--platform-button-base-line-height: 16px;--platform-button-base-height: calc(2 * var(--platform-button-base-font-size));--platform-button-contained-primary-background-color: var(--platform-color-primary);--platform-button-contained-primary-color: #ffffff;--platform-button-outlined-primary-color: var(--platform-color-primary);--platform-button-text-primary-color: var(--platform-text-primary-color);--platform-button-contained-danger-background-color: var(--platform-color-danger);--platform-button-contained-danger-color: #ffffff;--platform-button-outlined-danger-color: var(--platform-color-danger);--platform-button-text-danger-color: var(--platform-color-danger)}@keyframes spinner-rotation__wUmPV{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.spinner__fakUN{position:relative;display:flex;transition:.3s;width:var(--icon-size);height:var(--icon-size)}.spinner__fakUN:before{content:"";position:absolute;top:50%;left:50%;width:var(--icon-size);height:var(--icon-size);margin-top:calc(var(--icon-size) / -2);margin-left:calc(var(--icon-size) / -2);border:2px solid transparent;box-sizing:border-box;border-radius:50%;animation:spinner-rotation__wUmPV .6s linear infinite;display:block}.button__8FA9H{all:unset;padding:var(--platform-button-base-padding);border-radius:var(--platform-button-base-border-radius);box-shadow:var(--platform-button-base-box-shadow);font-size:var(--platform-button-base-font-size);line-height:var(--platform-button-base-line-height);height:var(--platform-button-base-height);font-weight:600;outline:none;border:none;cursor:pointer;transition:width .2s ease-in;display:flex;align-items:center;gap:8px;--icon-size: 12px}.button__8FA9H:disabled{cursor:not-allowed;opacity:.5}.button--contained-primary__stkTx{background-color:var(--platform-button-contained-primary-background-color);color:var(--platform-button-contained-primary-color)}.button--contained-primary__stkTx .spinner__fakUN:before{border-top-color:var(--platform-button-contained-primary-color);border-right-color:var(--platform-button-contained-primary-color)}.button--outlined-primary__KZ1ww{background-color:transparent;color:var(--platform-button-outlined-primary-color);border:1px solid var(--platform-button-outlined-primary-color);height:calc(var(--platform-button-base-height) - 2px)}.button--outlined-primary__KZ1ww .spinner__fakUN:before{border-top-color:var(--platform-button-outlined-primary-color);border-right-color:var(--platform-button-outlined-primary-color)}.button--text-primary__GLTfm{background-color:transparent;color:var(--platform-button-text-primary-color);box-shadow:none}.button--text-primary__GLTfm .spinner__fakUN:before{border-top-color:var(--platform-button-text-primary-color);border-right-color:var(--platform-button-text-primary-color)}.button--contained-danger__L9ehT{background-color:var(--platform-button-contained-danger-background-color);color:var(--platform-button-contained-danger-color)}.button--contained-danger__L9ehT .spinner__fakUN:before{border-top-color:var(--platform-button-contained-danger-color);border-right-color:var(--platform-button-contained-danger-color)}.button--outlined-danger__eoYLd{background-color:transparent;color:var(--platform-button-outlined-danger-color);border:1px solid var(--platform-button-outlined-danger-color);height:calc(var(--platform-button-base-height) - 2px)}.button--outlined-danger__eoYLd .spinner__fakUN:before{border-top-color:var(--platform-button-outlined-danger-color);border-right-color:var(--platform-button-outlined-danger-color)}.button--text-danger__Sw-ha{background-color:transparent;color:var(--platform-button-text-danger-color);box-shadow:none}.button--text-danger__Sw-ha .spinner__fakUN:before{border-top-color:var(--platform-button-text-danger-color);border-right-color:var(--platform-button-text-danger-color)}.icon__--umH{width:var(--icon-size);height:var(--icon-size)}.Badges__5jpum{display:flex;gap:10px;margin-top:8px}.Badge__95MWM{display:flex;flex-direction:row;justify-content:center;align-items:center;text-align:center;color:var(--admin-ui-badge-color);padding:var(--admin-ui-badge-padding);background:var(--admin-ui-badge-background-color);border:1px solid var(--admin-ui-badge-color);border-radius:var(--admin-ui-badge-border-radius)}.Badge--primary__Rx-bS{--admin-ui-badge-background-color: var(--admin-ui-primary-color);--admin-ui-badge-color: #ffffff}.Badge--secondary__d92bT{--admin-ui-badge-background-color: var(--admin-ui-background-color-light);--admin-ui-badge-color: var(--admin-ui-secondary-text-color)}.Badge--success__Kdo98{--admin-ui-badge-background-color: var(--admin-ui-success-color-light);--admin-ui-badge-color: var(--admin-ui-success-color)}.Badge--warning__bf-Nn{--admin-ui-badge-background-color: var(--admin-ui-warning-color-light);--admin-ui-badge-color: var(--admin-ui-warning-color)}.Badge--danger__HTj39{--admin-ui-badge-background-color: var(--admin-ui-danger-color-light);--admin-ui-badge-color: var(--admin-ui-danger-color)}.Badge--small__y93Pj{font-size:var(--admin-ui-badge-font-size);line-height:var(--admin-ui-badge-line-height)}.Badge--regular__aT5AL{font-size:calc(1.25 * var(--admin-ui-badge-font-size));line-height:calc(1.25 * var(--admin-ui-badge-line-height))}.Badge--large__wORCH{font-size:calc(1.5 * var(--admin-ui-badge-font-size));line-height:calc(1.5 * var(--admin-ui-badge-line-height))}.CopyToClipboardButton__2Nd2m:hover{cursor:pointer}.FieldGroup__Q2JCV{margin-bottom:1em}.FieldGroup--horizontal__kpfL1{display:grid;grid-template-columns:max-content 1fr;grid-gap:1em;align-items:center;height:100%}.FieldGroup--vertical__FLo-Q{display:grid;grid-template-columns:1fr;grid-gap:4px}.Input__uS0sb{width:100%;padding:10px;border:1px solid var(--platform-input-border-color);background-color:var(--platform-input-background-color);color:var(--platform-input-color);border-radius:8px;font-size:1em}.Input__uS0sb:focus{outline:1px solid var(--platform-input-focus-border-color)}.Input__uS0sb.Error__-DQpw{border-color:var(--platform-color-danger)}.Error__N4OP5{width:100%;min-height:15px;color:var(--platform-color-danger);font-size:1em}.Label__VYUvW{font-size:1em;font-weight:400;color:var(--platform-label-color)}.Label__VYUvW.Error__Eu6DI{color:var(--platform-color-danger)}.Select__giqpe{width:100%;position:relative}.Select__giqpe select{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:100%;color:var(--platform-input-color);font-size:14px;background-color:var(--platform-input-background-color);border:1px solid var(--platform-input-border-color);border-radius:8px;cursor:pointer;padding:10px}.Select__giqpe select:focus{outline:1px solid var(--platform-input-focus-border-color)}.Chevron__YvhBd{position:absolute;right:1em;top:50%;transform:translateY(-50%);pointer-events:none}.Container__xcHXp{display:flex;flex-direction:column;gap:8px}.Label__0cZB9{font-size:1em;font-weight:600;color:var(--platform-input-color)}.HelperText__m1nA9{font-size:.875em;color:var(--platform-text-secondary-color);margin-top:-4px}.Trigger__AyFUd{display:flex;align-items:center;justify-content:space-between;width:100%;padding:10px;background-color:var(--platform-input-background-color);border:1px solid var(--platform-input-border-color);border-radius:8px;font-size:1em;color:var(--platform-input-color);cursor:pointer;transition:all .2s}.Trigger__AyFUd:hover{border-color:var(--platform-input-focus-border-color)}.Trigger__AyFUd:focus{outline:none;border-color:var(--platform-input-focus-border-color)}.Trigger__AyFUd[data-disabled]{opacity:.5;cursor:not-allowed}.Trigger__AyFUd[data-disabled]:hover{border-color:var(--platform-input-border-color)}.Trigger__AyFUd[data-placeholder]{color:var(--platform-text-secondary-color)}.TriggerIcon__aygFG{display:flex;align-items:center;color:var(--platform-text-primary-color)}.Content__llztG{overflow:hidden;background-color:var(--platform-input-background-color);border:1px solid var(--platform-input-border-color);border-radius:8px;box-shadow:0 4px 16px #0000001a;z-index:99999;min-width:var(--radix-select-trigger-width)}.Viewport__COtSL{padding:4px}.Item__XN1-2{display:flex;align-items:center;justify-content:flex-start;gap:8px;padding:10px 12px;font-size:1em;border-radius:4px;cursor:pointer;-webkit-user-select:none;user-select:none;outline:none;position:relative;color:var(--platform-input-color)}.Item__XN1-2[data-highlighted]{background-color:#0000000d}.Item__XN1-2[data-disabled]{opacity:.5;pointer-events:none}.Item__XN1-2[data-state=checked]{font-weight:500}.ItemIndicatorContainer__EQH-X{display:flex;align-items:center;justify-content:center;width:16px;height:16px;flex-shrink:0}.ItemIndicator__bySSc{display:flex;align-items:center;justify-content:center;color:var(--platform-input-color)}.TextArea__pa-A0{width:100%;height:100%;background-clip:padding-box;padding:10px;border:1px solid var(--platform-input-border-color);background-color:var(--platform-input-background-color);color:var(--platform-input-color);border-radius:8px;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}.TextArea__pa-A0:focus{outline:1px solid var(--platform-input-focus-border-color)}.tooltip__nUuSh{border-radius:8px;padding:8px 12px;font-size:12px;font-weight:var(--platform-tooltip-font-weight);line-height:18px;color:var(--platform-tooltip-color);background-color:var(--platform-tooltip-background-color);box-shadow:0 4px 10px 0 var(--platform-shadow-color);-webkit-user-select:none;user-select:none;pointer-events:none;animation-duration:.4s;animation-timing-function:cubic-bezier(.16,1,.3,1);will-change:transform,opacity}.tooltip__nUuSh[data-side=right]{animation-name:slideLeftAndFade__DYdE5}.tooltip__nUuSh[data-side=bottom]{animation-name:slideUpAndFade__itahf}.tooltipArrow__W2w-f{fill:var(--platform-tooltip-background-color)}@keyframes slideLeftAndFade__DYdE5{0%{opacity:0;transform:translate(-8px)}to{opacity:1;transform:translate(0)}}@keyframes slideUpAndFade__itahf{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translate(0)}}.truncatedText__Y-jSd{display:inline-block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom}.overflowing__o8TC-{cursor:default}.SearchInput__4OFyE{position:relative}.SearchInput__4OFyE .SearchIcon__YgnQy{position:absolute;top:50%;transform:translateY(-50%);left:10px;color:#000}.SearchInput__4OFyE .ClearIcon__ukRVr{position:absolute;top:50%;transform:translateY(-50%);right:15px;color:#000;cursor:pointer}.SearchInput__4OFyE input{font-size:1em}.SearchInput__ClearIcon__uzVoc input{padding-right:30px}.SearchInput__SearchIcon__zoDG4 input{padding-left:30px}.SearchAutocomplete__vR9Hk{position:relative}.AutocompleteItem__YIm7R{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;padding:4px 16px;min-height:36px;width:100%;text-align:left;border:none;background-color:transparent;line-height:14px;font-size:12px;font-weight:400;color:var(--platform-text-primary-color);pointer-events:none}.AutocompleteItem--canBeSelected__jxk4z{cursor:pointer;pointer-events:auto}.AutocompleteItem--canBeSelected__jxk4z:hover{background-color:#0000001a}.AutocompleteHighlighter__LAFTV{overflow:hidden;display:-webkit-box;-webkit-line-clamp:1;line-clamp:1;-webkit-box-orient:vertical;word-break:break-all}.AutocompleteHighlighter__match__Wy1o2{font-weight:700}.DropdownList__-fHIk{width:100%;padding-bottom:8px;padding-top:8px;min-height:0;border:1px solid var(--platform-lines)}.AutocompleteItemDescription__4QYN5{font-size:.8em;line-height:1em;font-weight:500;color:var(--platform-text-secondary-color);margin-top:2px}.DropdownList__QTXXX{position:absolute;z-index:1;background-color:var(--platform-background-primary-color);border-radius:8px;box-shadow:0 1px 5px #1018281a;min-width:105px;padding:4px 0;transition:all .2s ease-in-out}.DropdownList--closed__pdL1Z{opacity:0;pointer-events:none;transform:translateY(-10px);visibility:hidden}.DropdownList--open__opzc9{display:flex;flex-direction:column;opacity:1;pointer-events:all;transform:translateY(0)}.DropdownList--left__xSwXR{right:0}.SkeletonListContainer__MKJhE{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch}.Skeleton__Ovpiw{animation:skeleton-pulse__ZqB1e 1s infinite alternate-reverse;background-image:none;background-clip:border-box;border:none;box-shadow:none;-webkit-box-decoration-break:clone;box-decoration-break:clone;color:transparent;outline:none;pointer-events:none;-webkit-user-select:none;user-select:none;cursor:default;display:block}@keyframes skeleton-pulse__ZqB1e{0%{background-color:var(--platform-skeleton-color-1)}to{background-color:var(--platform-skeleton-color-2)}}@keyframes rotate__EqlXe{to{transform:rotate(360deg)}}.spinner__qa7F6{width:80px;height:80px;border:6px solid var(--platform-color-white);border-bottom-color:#ffffff1a;border-radius:50%;display:inline-block;box-sizing:border-box;animation:rotate__EqlXe 2s linear infinite}.spinner-dark__9A9-q{border-color:var(--platform-color-dark);border-bottom-color:#ffffff1a}.spinner-white__gRbtI{border-color:var(--platform-color-white);border-bottom-color:#ffffff1a}.spinner-success__otWGm{border-color:var(--platform-color-success);border-bottom-color:#ffffff1a}.spinner-danger__Bq5DM{border-color:var(--platform-color-danger);border-bottom-color:#ffffff1a}.spinner-warning__U900K{border-color:var(--platform-color-warning);border-bottom-color:#ffffff1a}.switch__0b2av{position:relative;display:inline-flex;align-items:center;width:44px;min-width:44px;height:24px;padding:0;border:none;border-radius:12px;background-color:#ccc;cursor:pointer;transition:background-color .2s ease;outline:none;font-size:0}.switch__0b2av:disabled{opacity:.5}.switch__0b2av:focus-visible{box-shadow:0 0 0 2px var(--platform-color-primary)}.switch__0b2av:hover:not(.disabled__KpauE){background-color:#bbb}.switch__0b2av.checked__2-JV-{background-color:var(--platform-color-primary)}.switch__0b2av.checked__2-JV-:hover:not(.disabled__KpauE){background-color:var(--platform-color-secondary)}.switch__0b2av.disabled__KpauE{opacity:.5;cursor:not-allowed;pointer-events:none}.thumb__fEuKD{position:absolute;top:2px;left:2px;width:20px;height:20px;background-color:#fff;border-radius:50%;transition:transform .2s ease;box-shadow:0 1px 3px #0000001a}.switch__0b2av.checked__2-JV- .thumb__fEuKD{transform:translate(20px)}[data-theme=dark] .switch__0b2av{background-color:#555}[data-theme=dark] .switch__0b2av:hover:not(.disabled__KpauE){background-color:#666}[data-theme=dark] .switch__0b2av.checked__2-JV-{background-color:var(--platform-color-primary)}[data-theme=dark] .switch__0b2av.checked__2-JV-:hover:not(.disabled__KpauE){background-color:var(--platform-color-secondary)}.tabs-list__rc10N{display:flex;position:relative}.tabs-list--horizontal__e1YW4{flex-direction:row;border-bottom:1px solid var(--platform-lines)}.tabs-list--vertical__huK05{flex-direction:column;border-right:none;width:200px}.tabs-trigger__D8R4R{position:relative;background:transparent;border:none;padding:12px 16px;font-size:14px;font-weight:500;color:var(--platform-text-secondary-color);cursor:pointer;transition:all .15s ease-in-out;white-space:nowrap;outline:none}.tabs-trigger__D8R4R:hover:not(.tabs-trigger--disabled__ezDWc){color:var(--platform-text-primary-color)}.tabs-trigger__D8R4R:focus-visible{outline:2px solid var(--platform-color-primary);outline-offset:2px;border-radius:4px}.tabs-trigger--horizontal__4jBFV{border-bottom:2px solid transparent;margin-bottom:-1px}.tabs-trigger--horizontal__4jBFV.tabs-trigger--active__S-Z-S{color:var(--platform-text-primary-color);border-bottom-color:var(--platform-text-primary-color)}.tabs-trigger--vertical__dNVIZ{border-left:none;border-right:3px solid transparent;margin-right:-8px;text-align:left;justify-content:flex-start;display:flex;width:calc(100% + 8px);border-radius:6px 0 0 6px;padding-right:19px}.tabs-trigger--vertical__dNVIZ:hover:not(.tabs-trigger--disabled__ezDWc):not(.tabs-trigger--active__S-Z-S){background-color:#0000000a}.tabs-trigger--vertical__dNVIZ.tabs-trigger--active__S-Z-S{color:var(--platform-text-primary-color);border-right-color:var(--platform-text-primary-color);background-color:var(--platform-background-primary-color);font-weight:600}.tabs-trigger--disabled__ezDWc{color:#9ca3af;cursor:not-allowed}.tabs-content__1d77o{padding:16px 0;outline:none}.tabs-content__1d77o:focus-visible{outline:2px solid var(--platform-color-primary);outline-offset:2px;border-radius:4px}.PasswordInput__GDJDN{position:relative}.PasswordInput__GDJDN input{padding-right:40px;box-sizing:border-box}.PasswordInput__GDJDN .eyeIcon__kDExG{position:absolute;top:50%;right:1em;transform:translateY(-50%)}.PasswordInput__GDJDN .eyeIcon__kDExG:hover{cursor:pointer}.Overlay__M5Z83{background-color:#0e12167f;position:fixed;top:0;right:0;bottom:0;left:0;animation:overlayShow__seU5M .15s cubic-bezier(.16,1,.3,1);z-index:var(--platform-modal-layer)}.Content__wAkP4{display:flex;position:relative;flex-direction:column;justify-content:flex-start;align-items:stretch;font-size:var(--admin-ui-base-font-size);z-index:calc(var(--platform-modal-layer) + 1);background-color:var(--platform-background-primary-color);border-radius:8px;overflow:hidden;box-shadow:#0e121659 0 10px 38px -10px,#0e121633 0 10px 20px -15px;position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);animation:contentShow__rxphL .15s cubic-bezier(.16,1,.3,1)}.Content__wAkP4:focus{outline:none}@keyframes overlayShow__seU5M{0%{opacity:0}to{opacity:1}}@keyframes contentShow__rxphL{0%{opacity:0;transform:translate(-50%,-48%) scale(.96)}to{opacity:1;transform:translate(-50%,-50%) scale(1)}}.ExampleDialog__llNIZ{max-width:500px}.Header__VHxNf{display:flex;justify-content:space-between;align-items:center;background-color:var(--admin-ui-background-color-light);padding:16px 24px}.Content__I04qM{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;padding:24px;width:90vw;max-height:85vh;max-width:100%;margin-bottom:64px;overflow:auto}.Close__xSN-7{cursor:pointer}.Title__Dznh6{line-height:24px;font-size:20px;font-weight:700;color:var(--admin-ui-primary-text-color)}.Description__ALT2w{font-size:12px;color:var(--platform-text-primary-color)}.Footer__-8gzQ{position:absolute;bottom:0;left:0;right:0;background-color:var(--admin-ui-background-color-light);display:flex;justify-content:flex-end;padding:16px 24px;gap:16px;box-shadow:0 -1px 6px #78787826}.Actions__kKF2Q{display:flex;gap:16px}.pill__vtGwB{border-radius:300px;min-width:4em;text-align:center;padding:3px 12px;font-size:.8em;font-weight:700;border:1px solid}.pill--solid__F-mR4{border-color:var(--pae-shell-color-secondary, #ED8525);background:var(--pae-shell-color-secondary, #ED8525);color:var(--pae-shell-color-white)}.pill--outline__gC-mh{border-color:var(--pae-shell-color-secondary, #ED8525);color:var(--pae-shell-color-secondary, #ED8525);background-color:var(--pae-shell-color-white)}.DialogContent__-WjG9{max-width:450px}.Message__AUgVP{color:var(--platform-text-primary-color);font-size:1.15em}.container__AjtYJ{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:8px;height:100vh}.title__A2vCu{font-size:24px;font-weight:600;line-height:36px;color:var(--text-primary-color);padding-top:24px}.description__bP6Ig{font-size:16px;font-weight:400;line-height:24px;color:var(--text-secondary-color)}a.mailToText__SdlsE{color:var(--pae-shell-color-secondary);font-weight:500}.List__h09XG{display:flex;flex-direction:column;position:relative;overflow-y:auto}.Item__YMy2i{display:flex;flex-direction:column;padding:12px 16px;cursor:pointer;color:var(--admin-ui-primary-text-color)}.List--primary__J2pbx{gap:16px}.List--primary__J2pbx .Item__YMy2i{border:1px solid var(--admin-ui-border-color);border-radius:8px}.List--secondary__gi1ao .Item__YMy2i{border-top:1px solid var(--admin-ui-border-color);border-bottom:1px solid transparent}.List--secondary__gi1ao .Item--selected__yRWow{background:#a0a0a01a;border-top:1px solid var(--admin-ui-primary-color);border-bottom:1px solid var(--admin-ui-primary-color)}.List__h09XG .Title__RJmEW{display:flex;align-items:center;gap:8px;padding-right:16px;font-size:1em;line-height:1.15em;color:var(--admin-ui-primary-text-color);margin-bottom:4px}.List__h09XG .Description__DGyX2{font-size:.8em;line-height:1em;font-weight:500;color:var(--admin-ui-secondary-text-color)}.List__h09XG .Actions__UHP5l{position:absolute;right:16px}.List__h09XG .Action__q-R1I{box-sizing:border-box;display:flex;flex-direction:row;align-items:center;padding:8px 16px;gap:12px;width:100%}.List__h09XG .Action__q-R1I:hover{background:var(--admin-ui-background-color-light)}.List__h09XG .Item--disabled__Ke1u-{background:var(--admin-ui-background-color-light);cursor:not-allowed;opacity:.5}.List--small__ijoSR .Item__YMy2i{padding:8px 12px;height:auto;font-size:1em}.List--medium__E1FEY .Item__YMy2i{padding:12px 16px;height:auto;font-size:1.1em}.List--large__T8tfz .Item__YMy2i{padding:16px 24px;height:auto;font-size:1.25em}.List__h09XG .Icon__dFr-L{display:flex;align-items:center;justify-content:center;width:1.4em;height:1.4em}.Navigation__uylxk{margin:0 auto;display:flex;justify-content:flex-end;width:100%;color:var(--platform-text-primary-color)}.PaginationContent__UpLw0{display:flex;align-items:center;gap:4px}.PaginationEllipsis__perWk{display:flex;width:2.5em;height:2.5em;justify-content:center;align-items:center}.PaginationEllipsis__perWk svg{width:1em;height:1em}.PaginationLink__GVUZj{display:inline-flex;align-items:center;justify-content:center;gap:.6em;padding:.5em;min-width:32px;border-radius:4px;font-size:1em;font-weight:500;border:1px solid transparent;cursor:pointer}.PaginationLink__GVUZj:focus{outline:none}.PaginationLink__GVUZj:hover{background-color:var(--platform-background-secondary-color)}.PaginationLink__GVUZj.Active__u1Ahy{border-color:var(--platform-lines)}.PaginationLink__GVUZj.Disabled__8WM0y{opacity:.8;pointer-events:none;cursor:default}.PaginationLink__GVUZj svg{width:1em;height:1em}.Prev__wp4hc{padding-right:12px}.Next__eVyL5{padding-left:12px}.TableContainer__osh6Z{border:1px solid var(--platform-lines);border-radius:1em;overflow:hidden}.TableHeader__sYa-8{padding:.6em .8em;font-size:1.4em;font-weight:600;width:100%;border-bottom:1px solid var(--platform-lines);color:var(--platform-text-primary-color)}.Table__2cIs3{overflow-x:auto;overflow-y:hidden}.Table__2cIs3 table{border-collapse:collapse;width:100%;min-width:max-content}.Table__2cIs3 td,.Table__2cIs3 th{border-bottom:1px solid var(--platform-lines);padding:1em;font-weight:400;font-size:var(--platform-text-base-font-size);color:var(--platform-text-secondary-color)}.Table__2cIs3 td{color:var(--platform-text-primary-color)}.Table__2cIs3 tr:last-child td{border-bottom:none}.Table__2cIs3 thead th{font-weight:500;background-color:var(--platform-background-secondary-color)}.Table__2cIs3 tr{transition:background-color .2s ease-in-out;background-color:var(--platform-background-primary-color)}.Table__2cIs3 tr.selectable__WsGg1:hover{cursor:pointer;background-color:var(--platform-background-secondary-color)}.Table__2cIs3 .Cell__ZEv-K{display:flex;align-items:center;gap:4px;justify-content:flex-start}.Table__2cIs3 .Right__YoM1V{justify-content:flex-end}.Table__2cIs3 .Center__CF3tr{justify-content:center}.Table__2cIs3 .Sortable__JIV1V{cursor:pointer}.Table__2cIs3 .SortIcon__f0bBy{opacity:0;visibility:hidden;transition:opacity .2s ease-in-out,transform .2s ease-in-out}.Table__2cIs3 .SortIcon__f0bBy.Active__rJjxB{opacity:1;visibility:visible}.Table__2cIs3 .SortIcon__f0bBy.Rotate__7cwTK{transform:rotate(-180deg)}.Table__2cIs3 .Cell__ZEv-K:hover .SortIcon__f0bBy{opacity:1;visibility:visible}.Pagination__sbqMP{display:flex;justify-content:flex-end;margin-top:1em!important}.PointerNone__kQdQS{pointer-events:none}.EmptyStateContainer__Q9FEb{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:1em;padding:2em 0}.EmptyStateContainer__Q9FEb .Message__IHK6M{font-size:1.15em;color:var(--platform-text-secondary-color)}.EmptyStateContainer__Q9FEb svg{color:var(--platform-text-secondary-color)}.alert__LblpE{position:relative;width:100%;border-radius:.8em;border:1px solid var(--platform-lines);padding:1em 1.2em;font-size:1em;display:grid;grid-template-columns:0 1fr;gap:.5em}.alert__LblpE:has(>svg){grid-template-columns:16px 1fr;gap:12px}.alert__LblpE>svg{margin-top:2px;width:16px;height:16px;color:inherit}.default__mgO6A{background-color:var(--platform-background-primary-color, #fff);color:var(--platform-text-primary-color, #111)}.destructive__bLNSM{background-color:var(--platform-background-primary-color, #fff);color:var(--platform-color-danger, #dc2626);border-color:var(--platform-color-danger, #dc2626)}.destructive__bLNSM>svg{color:inherit}.destructive__bLNSM [data-slot=alert-description]{color:var(--platform-color-danger, #dc2626)}.alertTitle__gblKf{grid-column-start:2;min-height:1em;font-weight:500;line-clamp:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.alertDescription__BuVHV{grid-column-start:2;display:grid;justify-items:start;gap:4px;font-size:1em;color:var(--platform-text-secondary-color)}.alertDescription__BuVHV p{line-height:1.5}.container__zBqbk{display:flex;align-items:center;justify-content:center;gap:16px;width:100%;cursor:pointer;height:var(--pae-shell-apps-menu-item-size);padding:8px calc((var(--pae-shell-navbar--width) - var(--pae-shell-apps-menu-icon-size)) / 2)}.container__zBqbk.expanded__EbsIr{justify-content:flex-start}.container__zBqbk .label__cdMnm{flex:1;text-align:left;font-size:var(--pae-shell-apps-menu-item-font-size);font-weight:var(--pae-shell-apps-menu-item-font-weight);line-height:21px;color:var(--pae-shell-apps-menu-selected-item-text-color)}.container__LbyGQ{display:flex;align-items:center}.avatarWrapper__HCQIZ{position:relative;display:inline-block}.avatar__E453a{border-radius:9999px;display:flex;align-items:center;justify-content:center;font-weight:600;border-width:1px;color:var(--platform-color-white);border-color:var(--platform-lines)}.overflowWrapper__ETnPO{position:relative;display:inline-block;cursor:default}.overflowBadge__igBKT{border-radius:9999px;display:flex;align-items:center;justify-content:center;color:var(--platform-color-white);font-weight:600;border-width:1px;border-color:var(--platform-lines);background-color:var(--platform-color-primary)}
|
|
2
|
-
`,document.head.appendChild(hr);function
|
|
1
|
+
(function(E,S){typeof exports=="object"&&typeof module<"u"?S(exports,require("react"),require("single-spa"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","single-spa","react-dom"],S):(E=typeof globalThis<"u"?globalThis:E||self,S(E["@bluealba/pae-ui-react-core"]={},E.React,E.singleSpa,E.ReactDOM))})(this,function(E,S,he,Wt){"use strict";var sf=E=>{throw TypeError(E)};var Pi=(E,S,he)=>S.has(E)||sf("Cannot "+he);var x=(E,S,he)=>(Pi(E,S,"read from private field"),he?he.call(E):S.get(E)),M=(E,S,he)=>S.has(E)?sf("Cannot add the same private member more than once"):S instanceof WeakSet?S.add(E):S.set(E,he),I=(E,S,he,Wt)=>(Pi(E,S,"write to private field"),Wt?Wt.call(E,he):S.set(E,he),he),V=(E,S,he)=>(Pi(E,S,"access private method"),he);var Ro=(E,S,he,Wt)=>({set _(hr){I(E,S,hr,he)},get _(){return x(E,S,Wt)}});var nn,Pt,An,Md,Rn,At,On,$d,rn,Fd,In,jn,je,on,be,cr,sn,We,mt,Bd,et,Ud,tt,_e,an,nt,Ut,Wd,dt,He,ur,Hd,ue,Rt,Ot,kn,Ln,It,Dn,Nn,Vd,Te,K,dr,xe,ln,Mn,jt,kt,fr,$n,Fn,cn,un,Lt,Bn,ee,pr,Ai,Ri,Oi,Ii,ji,ki,Li,af,zd,Dt,Nt,Pe,ft,pt,Oo,Di,Gd;var hr=document.createElement("style");hr.textContent=`:root{--platform-label-color: var(--platform-text-secondary-color);--platform-input-border-color: var(--platform-lines);--platform-input-background-color: var(--platform-background-secondary-color);--platform-input-color: var(--platform-text-primary-color);--platform-input-focus-border-color: var(--platform-color-primary);--platform-button-base-padding: 4px 16px;--platform-button-base-border-radius: 6px;--platform-button-base-box-shadow: 0 1px 2px 0 rgba(0, 0, 0, .05);--platform-button-base-font-size: 1em;--platform-button-base-line-height: 16px;--platform-button-base-height: calc(2 * var(--platform-button-base-font-size));--platform-button-contained-primary-background-color: var(--platform-color-primary);--platform-button-contained-primary-color: #ffffff;--platform-button-outlined-primary-color: var(--platform-color-primary);--platform-button-text-primary-color: var(--platform-text-primary-color);--platform-button-contained-danger-background-color: var(--platform-color-danger);--platform-button-contained-danger-color: #ffffff;--platform-button-outlined-danger-color: var(--platform-color-danger);--platform-button-text-danger-color: var(--platform-color-danger)}@keyframes spinner-rotation__wUmPV{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.spinner__fakUN{position:relative;display:flex;transition:.3s;width:var(--icon-size);height:var(--icon-size)}.spinner__fakUN:before{content:"";position:absolute;top:50%;left:50%;width:var(--icon-size);height:var(--icon-size);margin-top:calc(var(--icon-size) / -2);margin-left:calc(var(--icon-size) / -2);border:2px solid transparent;box-sizing:border-box;border-radius:50%;animation:spinner-rotation__wUmPV .6s linear infinite;display:block}.button__8FA9H{all:unset;padding:var(--platform-button-base-padding);border-radius:var(--platform-button-base-border-radius);box-shadow:var(--platform-button-base-box-shadow);font-size:var(--platform-button-base-font-size);line-height:var(--platform-button-base-line-height);height:var(--platform-button-base-height);font-weight:600;outline:none;border:none;cursor:pointer;transition:width .2s ease-in;display:flex;align-items:center;gap:8px;--icon-size: 12px}.button__8FA9H:disabled{cursor:not-allowed;opacity:.5}.button--contained-primary__stkTx{background-color:var(--platform-button-contained-primary-background-color);color:var(--platform-button-contained-primary-color)}.button--contained-primary__stkTx .spinner__fakUN:before{border-top-color:var(--platform-button-contained-primary-color);border-right-color:var(--platform-button-contained-primary-color)}.button--outlined-primary__KZ1ww{background-color:transparent;color:var(--platform-button-outlined-primary-color);border:1px solid var(--platform-button-outlined-primary-color);height:calc(var(--platform-button-base-height) - 2px)}.button--outlined-primary__KZ1ww .spinner__fakUN:before{border-top-color:var(--platform-button-outlined-primary-color);border-right-color:var(--platform-button-outlined-primary-color)}.button--text-primary__GLTfm{background-color:transparent;color:var(--platform-button-text-primary-color);box-shadow:none}.button--text-primary__GLTfm .spinner__fakUN:before{border-top-color:var(--platform-button-text-primary-color);border-right-color:var(--platform-button-text-primary-color)}.button--contained-danger__L9ehT{background-color:var(--platform-button-contained-danger-background-color);color:var(--platform-button-contained-danger-color)}.button--contained-danger__L9ehT .spinner__fakUN:before{border-top-color:var(--platform-button-contained-danger-color);border-right-color:var(--platform-button-contained-danger-color)}.button--outlined-danger__eoYLd{background-color:transparent;color:var(--platform-button-outlined-danger-color);border:1px solid var(--platform-button-outlined-danger-color);height:calc(var(--platform-button-base-height) - 2px)}.button--outlined-danger__eoYLd .spinner__fakUN:before{border-top-color:var(--platform-button-outlined-danger-color);border-right-color:var(--platform-button-outlined-danger-color)}.button--text-danger__Sw-ha{background-color:transparent;color:var(--platform-button-text-danger-color);box-shadow:none}.button--text-danger__Sw-ha .spinner__fakUN:before{border-top-color:var(--platform-button-text-danger-color);border-right-color:var(--platform-button-text-danger-color)}.icon__--umH{width:var(--icon-size);height:var(--icon-size)}.Badges__5jpum{display:flex;gap:10px;margin-top:8px}.Badge__95MWM{display:flex;flex-direction:row;justify-content:center;align-items:center;text-align:center;color:var(--admin-ui-badge-color);padding:var(--admin-ui-badge-padding);background:var(--admin-ui-badge-background-color);border:1px solid var(--admin-ui-badge-color);border-radius:var(--admin-ui-badge-border-radius)}.Badge--primary__Rx-bS{--admin-ui-badge-background-color: var(--admin-ui-primary-color);--admin-ui-badge-color: #ffffff}.Badge--secondary__d92bT{--admin-ui-badge-background-color: var(--admin-ui-background-color-light);--admin-ui-badge-color: var(--admin-ui-secondary-text-color)}.Badge--success__Kdo98{--admin-ui-badge-background-color: var(--admin-ui-success-color-light);--admin-ui-badge-color: var(--admin-ui-success-color)}.Badge--warning__bf-Nn{--admin-ui-badge-background-color: var(--admin-ui-warning-color-light);--admin-ui-badge-color: var(--admin-ui-warning-color)}.Badge--danger__HTj39{--admin-ui-badge-background-color: var(--admin-ui-danger-color-light);--admin-ui-badge-color: var(--admin-ui-danger-color)}.Badge--small__y93Pj{font-size:var(--admin-ui-badge-font-size);line-height:var(--admin-ui-badge-line-height)}.Badge--regular__aT5AL{font-size:calc(1.25 * var(--admin-ui-badge-font-size));line-height:calc(1.25 * var(--admin-ui-badge-line-height))}.Badge--large__wORCH{font-size:calc(1.5 * var(--admin-ui-badge-font-size));line-height:calc(1.5 * var(--admin-ui-badge-line-height))}.CopyToClipboardButton__2Nd2m:hover{cursor:pointer}.FieldGroup__Q2JCV{margin-bottom:1em}.FieldGroup--horizontal__kpfL1{display:grid;grid-template-columns:max-content 1fr;grid-gap:1em;align-items:center;height:100%}.FieldGroup--vertical__FLo-Q{display:grid;grid-template-columns:1fr;grid-gap:4px}.Input__uS0sb{width:100%;padding:10px;border:1px solid var(--platform-input-border-color);background-color:var(--platform-input-background-color);color:var(--platform-input-color);border-radius:8px;font-size:1em}.Input__uS0sb:focus{outline:1px solid var(--platform-input-focus-border-color)}.Input__uS0sb.Error__-DQpw{border-color:var(--platform-color-danger)}.Error__N4OP5{width:100%;min-height:15px;color:var(--platform-color-danger);font-size:1em}.Label__VYUvW{font-size:1em;font-weight:400;color:var(--platform-label-color)}.Label__VYUvW.Error__Eu6DI{color:var(--platform-color-danger)}.Select__giqpe{width:100%;position:relative}.Select__giqpe select{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:100%;color:var(--platform-input-color);font-size:14px;background-color:var(--platform-input-background-color);border:1px solid var(--platform-input-border-color);border-radius:8px;cursor:pointer;padding:10px}.Select__giqpe select:focus{outline:1px solid var(--platform-input-focus-border-color)}.Chevron__YvhBd{position:absolute;right:1em;top:50%;transform:translateY(-50%);pointer-events:none}.Container__xcHXp{display:flex;flex-direction:column;gap:8px}.Label__0cZB9{font-size:1em;font-weight:600;color:var(--platform-input-color)}.HelperText__m1nA9{font-size:.875em;color:var(--platform-text-secondary-color);margin-top:-4px}.Trigger__AyFUd{display:flex;align-items:center;justify-content:space-between;width:100%;padding:10px;background-color:var(--platform-input-background-color);border:1px solid var(--platform-input-border-color);border-radius:8px;font-size:1em;color:var(--platform-input-color);cursor:pointer;transition:all .2s}.Trigger__AyFUd:hover{border-color:var(--platform-input-focus-border-color)}.Trigger__AyFUd:focus{outline:none;border-color:var(--platform-input-focus-border-color)}.Trigger__AyFUd[data-disabled]{opacity:.5;cursor:not-allowed}.Trigger__AyFUd[data-disabled]:hover{border-color:var(--platform-input-border-color)}.Trigger__AyFUd[data-placeholder]{color:var(--platform-text-secondary-color)}.TriggerIcon__aygFG{display:flex;align-items:center;color:var(--platform-text-primary-color)}.Content__llztG{overflow:hidden;background-color:var(--platform-input-background-color);border:1px solid var(--platform-input-border-color);border-radius:8px;box-shadow:0 4px 16px #0000001a;z-index:99999;min-width:var(--radix-select-trigger-width)}.Viewport__COtSL{padding:4px}.Item__XN1-2{display:flex;align-items:center;justify-content:flex-start;gap:8px;padding:10px 12px;font-size:1em;border-radius:4px;cursor:pointer;-webkit-user-select:none;user-select:none;outline:none;position:relative;color:var(--platform-input-color)}.Item__XN1-2[data-highlighted]{background-color:#0000000d}.Item__XN1-2[data-disabled]{opacity:.5;pointer-events:none}.Item__XN1-2[data-state=checked]{font-weight:500}.ItemIndicatorContainer__EQH-X{display:flex;align-items:center;justify-content:center;width:16px;height:16px;flex-shrink:0}.ItemIndicator__bySSc{display:flex;align-items:center;justify-content:center;color:var(--platform-input-color)}.TextArea__pa-A0{width:100%;height:100%;background-clip:padding-box;padding:10px;border:1px solid var(--platform-input-border-color);background-color:var(--platform-input-background-color);color:var(--platform-input-color);border-radius:8px;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}.TextArea__pa-A0:focus{outline:1px solid var(--platform-input-focus-border-color)}.tooltip__nUuSh{border-radius:8px;padding:8px 12px;font-size:12px;font-weight:var(--platform-tooltip-font-weight);line-height:18px;color:var(--platform-tooltip-color);background-color:var(--platform-tooltip-background-color);box-shadow:0 4px 10px 0 var(--platform-shadow-color);-webkit-user-select:none;user-select:none;pointer-events:none;animation-duration:.4s;animation-timing-function:cubic-bezier(.16,1,.3,1);will-change:transform,opacity}.tooltip__nUuSh[data-side=right]{animation-name:slideLeftAndFade__DYdE5}.tooltip__nUuSh[data-side=bottom]{animation-name:slideUpAndFade__itahf}.tooltipArrow__W2w-f{fill:var(--platform-tooltip-background-color)}@keyframes slideLeftAndFade__DYdE5{0%{opacity:0;transform:translate(-8px)}to{opacity:1;transform:translate(0)}}@keyframes slideUpAndFade__itahf{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translate(0)}}.truncatedText__Y-jSd{display:inline-block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom}.overflowing__o8TC-{cursor:default}.SearchInput__4OFyE{position:relative}.SearchInput__4OFyE .SearchIcon__YgnQy{position:absolute;top:50%;transform:translateY(-50%);left:10px;color:#000}.SearchInput__4OFyE .ClearIcon__ukRVr{position:absolute;top:50%;transform:translateY(-50%);right:15px;color:#000;cursor:pointer}.SearchInput__4OFyE input{font-size:1em}.SearchInput__ClearIcon__uzVoc input{padding-right:30px}.SearchInput__SearchIcon__zoDG4 input{padding-left:30px}.SearchAutocomplete__vR9Hk{position:relative}.AutocompleteItem__YIm7R{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;padding:4px 16px;min-height:36px;width:100%;text-align:left;border:none;background-color:transparent;line-height:14px;font-size:12px;font-weight:400;color:var(--platform-text-primary-color);pointer-events:none}.AutocompleteItem--canBeSelected__jxk4z{cursor:pointer;pointer-events:auto}.AutocompleteItem--canBeSelected__jxk4z:hover{background-color:#0000001a}.AutocompleteHighlighter__LAFTV{overflow:hidden;display:-webkit-box;-webkit-line-clamp:1;line-clamp:1;-webkit-box-orient:vertical;word-break:break-all}.AutocompleteHighlighter__match__Wy1o2{font-weight:700}.DropdownList__-fHIk{width:100%;padding-bottom:8px;padding-top:8px;min-height:0;border:1px solid var(--platform-lines)}.AutocompleteItemDescription__4QYN5{font-size:.8em;line-height:1em;font-weight:500;color:var(--platform-text-secondary-color);margin-top:2px}.DropdownList__QTXXX{position:absolute;z-index:1;background-color:var(--platform-background-primary-color);border-radius:8px;box-shadow:0 1px 5px #1018281a;min-width:105px;padding:4px 0;transition:all .2s ease-in-out}.DropdownList--closed__pdL1Z{opacity:0;pointer-events:none;transform:translateY(-10px);visibility:hidden}.DropdownList--open__opzc9{display:flex;flex-direction:column;opacity:1;pointer-events:all;transform:translateY(0)}.DropdownList--left__xSwXR{right:0}.SkeletonListContainer__MKJhE{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch}.Skeleton__Ovpiw{animation:skeleton-pulse__ZqB1e 1s infinite alternate-reverse;background-image:none;background-clip:border-box;border:none;box-shadow:none;-webkit-box-decoration-break:clone;box-decoration-break:clone;color:transparent;outline:none;pointer-events:none;-webkit-user-select:none;user-select:none;cursor:default;display:block}@keyframes skeleton-pulse__ZqB1e{0%{background-color:var(--platform-skeleton-color-1)}to{background-color:var(--platform-skeleton-color-2)}}@keyframes rotate__EqlXe{to{transform:rotate(360deg)}}.spinner__qa7F6{width:80px;height:80px;border:6px solid var(--platform-color-white);border-bottom-color:#ffffff1a;border-radius:50%;display:inline-block;box-sizing:border-box;animation:rotate__EqlXe 2s linear infinite}.spinner-dark__9A9-q{border-color:var(--platform-color-dark);border-bottom-color:#ffffff1a}.spinner-white__gRbtI{border-color:var(--platform-color-white);border-bottom-color:#ffffff1a}.spinner-success__otWGm{border-color:var(--platform-color-success);border-bottom-color:#ffffff1a}.spinner-danger__Bq5DM{border-color:var(--platform-color-danger);border-bottom-color:#ffffff1a}.spinner-warning__U900K{border-color:var(--platform-color-warning);border-bottom-color:#ffffff1a}.switch__0b2av{position:relative;display:inline-flex;align-items:center;width:44px;min-width:44px;height:24px;padding:0;border:none;border-radius:12px;background-color:#ccc;cursor:pointer;transition:background-color .2s ease;outline:none;font-size:0}.switch__0b2av:disabled{opacity:.5}.switch__0b2av:focus-visible{box-shadow:0 0 0 2px var(--platform-color-primary)}.switch__0b2av:hover:not(.disabled__KpauE){background-color:#bbb}.switch__0b2av.checked__2-JV-{background-color:var(--platform-color-primary)}.switch__0b2av.checked__2-JV-:hover:not(.disabled__KpauE){background-color:var(--platform-color-secondary)}.switch__0b2av.disabled__KpauE{opacity:.5;cursor:not-allowed;pointer-events:none}.thumb__fEuKD{position:absolute;top:2px;left:2px;width:20px;height:20px;background-color:#fff;border-radius:50%;transition:transform .2s ease;box-shadow:0 1px 3px #0000001a}.switch__0b2av.checked__2-JV- .thumb__fEuKD{transform:translate(20px)}[data-theme=dark] .switch__0b2av{background-color:#555}[data-theme=dark] .switch__0b2av:hover:not(.disabled__KpauE){background-color:#666}[data-theme=dark] .switch__0b2av.checked__2-JV-{background-color:var(--platform-color-primary)}[data-theme=dark] .switch__0b2av.checked__2-JV-:hover:not(.disabled__KpauE){background-color:var(--platform-color-secondary)}.tabs-list__rc10N{display:flex;position:relative}.tabs-list--horizontal__e1YW4{flex-direction:row;border-bottom:1px solid var(--platform-lines)}.tabs-list--vertical__huK05{flex-direction:column;border-right:none;width:200px}.tabs-trigger__D8R4R{position:relative;background:transparent;border:none;padding:12px 16px;font-size:14px;font-weight:500;color:var(--platform-text-secondary-color);cursor:pointer;transition:all .15s ease-in-out;white-space:nowrap;outline:none}.tabs-trigger__D8R4R:hover:not(.tabs-trigger--disabled__ezDWc){color:var(--platform-text-primary-color)}.tabs-trigger__D8R4R:focus-visible{outline:2px solid var(--platform-color-primary);outline-offset:2px;border-radius:4px}.tabs-trigger--horizontal__4jBFV{border-bottom:2px solid transparent;margin-bottom:-1px}.tabs-trigger--horizontal__4jBFV.tabs-trigger--active__S-Z-S{color:var(--platform-text-primary-color);border-bottom-color:var(--platform-text-primary-color)}.tabs-trigger--vertical__dNVIZ{border-left:none;border-right:3px solid transparent;margin-right:-8px;text-align:left;justify-content:flex-start;display:flex;width:calc(100% + 8px);border-radius:6px 0 0 6px;padding-right:19px}.tabs-trigger--vertical__dNVIZ:hover:not(.tabs-trigger--disabled__ezDWc):not(.tabs-trigger--active__S-Z-S){background-color:#0000000a}.tabs-trigger--vertical__dNVIZ.tabs-trigger--active__S-Z-S{color:var(--platform-text-primary-color);border-right-color:var(--platform-text-primary-color);background-color:var(--platform-background-primary-color);font-weight:600}.tabs-trigger--disabled__ezDWc{color:#9ca3af;cursor:not-allowed}.tabs-content__1d77o{padding:16px 0;outline:none}.tabs-content__1d77o:focus-visible{outline:2px solid var(--platform-color-primary);outline-offset:2px;border-radius:4px}.PasswordInput__GDJDN{position:relative}.PasswordInput__GDJDN input{padding-right:40px;box-sizing:border-box}.PasswordInput__GDJDN .eyeIcon__kDExG{position:absolute;top:50%;right:1em;transform:translateY(-50%)}.PasswordInput__GDJDN .eyeIcon__kDExG:hover{cursor:pointer}.Overlay__M5Z83{background-color:#0e12167f;position:fixed;top:0;right:0;bottom:0;left:0;animation:overlayShow__seU5M .15s cubic-bezier(.16,1,.3,1);z-index:var(--platform-modal-layer)}.Content__wAkP4{display:flex;position:relative;flex-direction:column;justify-content:flex-start;align-items:stretch;font-size:var(--admin-ui-base-font-size);z-index:calc(var(--platform-modal-layer) + 1);background-color:var(--platform-background-primary-color);border-radius:8px;overflow:hidden;box-shadow:#0e121659 0 10px 38px -10px,#0e121633 0 10px 20px -15px;position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);animation:contentShow__rxphL .15s cubic-bezier(.16,1,.3,1)}.Content__wAkP4:focus{outline:none}@keyframes overlayShow__seU5M{0%{opacity:0}to{opacity:1}}@keyframes contentShow__rxphL{0%{opacity:0;transform:translate(-50%,-48%) scale(.96)}to{opacity:1;transform:translate(-50%,-50%) scale(1)}}.ExampleDialog__llNIZ{max-width:500px}.Header__VHxNf{display:flex;justify-content:space-between;align-items:center;background-color:var(--admin-ui-background-color-light);padding:16px 24px}.Content__I04qM{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;padding:24px;width:90vw;max-height:85vh;max-width:100%;margin-bottom:64px;overflow:auto}.Close__xSN-7{cursor:pointer}.Title__Dznh6{line-height:24px;font-size:20px;font-weight:700;color:var(--admin-ui-primary-text-color)}.Description__ALT2w{font-size:12px;color:var(--platform-text-primary-color)}.Footer__-8gzQ{position:absolute;bottom:0;left:0;right:0;background-color:var(--admin-ui-background-color-light);display:flex;justify-content:flex-end;padding:16px 24px;gap:16px;box-shadow:0 -1px 6px #78787826}.Actions__kKF2Q{display:flex;gap:16px}.pill__vtGwB{border-radius:300px;min-width:4em;text-align:center;padding:3px 12px;font-size:.8em;font-weight:700;border:1px solid}.pill--solid__F-mR4{border-color:var(--pae-shell-color-secondary, #ED8525);background:var(--pae-shell-color-secondary, #ED8525);color:var(--pae-shell-color-white)}.pill--outline__gC-mh{border-color:var(--pae-shell-color-secondary, #ED8525);color:var(--pae-shell-color-secondary, #ED8525);background-color:var(--pae-shell-color-white)}.DialogContent__-WjG9{max-width:450px}.Message__AUgVP{color:var(--platform-text-primary-color);font-size:1.15em}.container__AjtYJ{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:8px;height:100vh}.title__A2vCu{font-size:24px;font-weight:600;line-height:36px;color:var(--text-primary-color);padding-top:24px}.description__bP6Ig{font-size:16px;font-weight:400;line-height:24px;color:var(--text-secondary-color)}a.mailToText__SdlsE{color:var(--pae-shell-color-secondary);font-weight:500}.List__h09XG{display:flex;flex-direction:column;position:relative;overflow-y:auto}.Item__YMy2i{display:flex;flex-direction:column;padding:12px 16px;cursor:pointer;color:var(--admin-ui-primary-text-color)}.List--primary__J2pbx{gap:16px}.List--primary__J2pbx .Item__YMy2i{border:1px solid var(--admin-ui-border-color);border-radius:8px}.List--secondary__gi1ao .Item__YMy2i{border-top:1px solid var(--admin-ui-border-color);border-bottom:1px solid transparent}.List--secondary__gi1ao .Item--selected__yRWow{background:#a0a0a01a;border-top:1px solid var(--admin-ui-primary-color);border-bottom:1px solid var(--admin-ui-primary-color)}.List__h09XG .Title__RJmEW{display:flex;align-items:center;gap:8px;padding-right:16px;font-size:1em;line-height:1.15em;color:var(--admin-ui-primary-text-color);margin-bottom:4px}.List__h09XG .Description__DGyX2{font-size:.8em;line-height:1em;font-weight:500;color:var(--admin-ui-secondary-text-color)}.List__h09XG .Actions__UHP5l{position:absolute;right:16px}.List__h09XG .Action__q-R1I{box-sizing:border-box;display:flex;flex-direction:row;align-items:center;padding:8px 16px;gap:12px;width:100%}.List__h09XG .Action__q-R1I:hover{background:var(--admin-ui-background-color-light)}.List__h09XG .Item--disabled__Ke1u-{background:var(--admin-ui-background-color-light);cursor:not-allowed;opacity:.5}.List--small__ijoSR .Item__YMy2i{padding:8px 12px;height:auto;font-size:1em}.List--medium__E1FEY .Item__YMy2i{padding:12px 16px;height:auto;font-size:1.1em}.List--large__T8tfz .Item__YMy2i{padding:16px 24px;height:auto;font-size:1.25em}.List__h09XG .Icon__dFr-L{display:flex;align-items:center;justify-content:center;width:1.4em;height:1.4em}.Navigation__uylxk{margin:0 auto;display:flex;justify-content:flex-end;width:100%;color:var(--platform-text-primary-color)}.PaginationContent__UpLw0{display:flex;align-items:center;gap:4px}.PaginationEllipsis__perWk{display:flex;width:2.5em;height:2.5em;justify-content:center;align-items:center}.PaginationEllipsis__perWk svg{width:1em;height:1em}.PaginationLink__GVUZj{display:inline-flex;align-items:center;justify-content:center;gap:.6em;padding:.5em;min-width:32px;border-radius:4px;font-size:1em;font-weight:500;border:1px solid transparent;cursor:pointer}.PaginationLink__GVUZj:focus{outline:none}.PaginationLink__GVUZj:hover{background-color:var(--platform-background-secondary-color)}.PaginationLink__GVUZj.Active__u1Ahy{border-color:var(--platform-lines)}.PaginationLink__GVUZj.Disabled__8WM0y{opacity:.8;pointer-events:none;cursor:default}.PaginationLink__GVUZj svg{width:1em;height:1em}.Prev__wp4hc{padding-right:12px}.Next__eVyL5{padding-left:12px}.TableContainer__osh6Z{border:1px solid var(--platform-lines);border-radius:1em;overflow:hidden}.TableHeader__sYa-8{padding:.6em .8em;font-size:1.4em;font-weight:600;width:100%;border-bottom:1px solid var(--platform-lines);color:var(--platform-text-primary-color)}.Table__2cIs3{overflow-x:auto;overflow-y:hidden}.Table__2cIs3 table{border-collapse:collapse;width:100%;min-width:max-content}.Table__2cIs3 td,.Table__2cIs3 th{border-bottom:1px solid var(--platform-lines);padding:1em;font-weight:400;font-size:var(--platform-text-base-font-size);color:var(--platform-text-secondary-color)}.Table__2cIs3 td{color:var(--platform-text-primary-color)}.Table__2cIs3 tr:last-child td{border-bottom:none}.Table__2cIs3 thead th{font-weight:500;background-color:var(--platform-background-secondary-color)}.Table__2cIs3 tr{transition:background-color .2s ease-in-out;background-color:var(--platform-background-primary-color)}.Table__2cIs3 tr.selectable__WsGg1:hover{cursor:pointer;background-color:var(--platform-background-secondary-color)}.Table__2cIs3 .Cell__ZEv-K{display:flex;align-items:center;gap:4px;justify-content:flex-start}.Table__2cIs3 .Right__YoM1V{justify-content:flex-end}.Table__2cIs3 .Center__CF3tr{justify-content:center}.Table__2cIs3 .Sortable__JIV1V{cursor:pointer}.Table__2cIs3 .SortIcon__f0bBy{opacity:0;visibility:hidden;transition:opacity .2s ease-in-out,transform .2s ease-in-out}.Table__2cIs3 .SortIcon__f0bBy.Active__rJjxB{opacity:1;visibility:visible}.Table__2cIs3 .SortIcon__f0bBy.Rotate__7cwTK{transform:rotate(-180deg)}.Table__2cIs3 .Cell__ZEv-K:hover .SortIcon__f0bBy{opacity:1;visibility:visible}.Pagination__sbqMP{display:flex;justify-content:flex-end;margin-top:1em!important}.PointerNone__kQdQS{pointer-events:none}.EmptyStateContainer__Q9FEb{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:1em;padding:2em 0}.EmptyStateContainer__Q9FEb .Message__IHK6M{font-size:1.15em;color:var(--platform-text-secondary-color)}.EmptyStateContainer__Q9FEb svg{color:var(--platform-text-secondary-color)}.alert__LblpE{position:relative;width:100%;border-radius:.8em;border:1px solid var(--platform-lines);padding:1em 1.2em;font-size:1em;display:grid;grid-template-columns:0 1fr;gap:.5em}.alert__LblpE:has(>svg){grid-template-columns:16px 1fr;gap:12px}.alert__LblpE>svg{margin-top:2px;width:16px;height:16px;color:inherit}.default__mgO6A{background-color:var(--platform-background-primary-color, #fff);color:var(--platform-text-primary-color, #111)}.destructive__bLNSM{background-color:var(--platform-background-primary-color, #fff);color:var(--platform-color-danger, #dc2626);border-color:var(--platform-color-danger, #dc2626)}.destructive__bLNSM>svg{color:inherit}.destructive__bLNSM [data-slot=alert-description]{color:var(--platform-color-danger, #dc2626)}.alertTitle__gblKf{grid-column-start:2;min-height:1em;font-weight:500;line-clamp:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.alertDescription__BuVHV{grid-column-start:2;display:grid;justify-items:start;gap:4px;font-size:1em;color:var(--platform-text-secondary-color)}.alertDescription__BuVHV p{line-height:1.5}.container__zBqbk{display:flex;align-items:center;justify-content:center;gap:16px;width:100%;cursor:pointer;height:var(--pae-shell-apps-menu-item-size);padding:8px calc((var(--pae-shell-navbar--width) - var(--pae-shell-apps-menu-icon-size)) / 2)}.container__zBqbk.expanded__EbsIr{justify-content:flex-start}.container__zBqbk .label__cdMnm{flex:1;text-align:left;font-size:var(--pae-shell-apps-menu-item-font-size);font-weight:var(--pae-shell-apps-menu-item-font-weight);line-height:21px;color:var(--pae-shell-apps-menu-selected-item-text-color)}.container__LbyGQ{display:flex;align-items:center}.avatarWrapper__HCQIZ{position:relative;display:inline-block}.avatar__E453a{border-radius:9999px;display:flex;align-items:center;justify-content:center;font-weight:600;border-width:1px;color:var(--platform-color-white);border-color:var(--platform-lines)}.overflowWrapper__ETnPO{position:relative;display:inline-block;cursor:default}.overflowBadge__igBKT{border-radius:9999px;display:flex;align-items:center;justify-content:center;color:var(--platform-color-white);font-weight:600;border-width:1px;border-color:var(--platform-lines);background-color:var(--platform-color-primary)}
|
|
2
|
+
`,document.head.appendChild(hr);function Ni(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const d=Ni(S),mr=Ni(Wt),lf={auth:{SESSION_EXPIRED:"platform:auth:session-expired"},apps:{APP_CLICKED:"platform:apps:app-clicked"},shell:{NAVBAR_STATE_CHANGED:"platform:shell:navbar-state-changed",MENU_STATE_CHANGED:"platform:shell:menu-state-changed"}},Hn="__PAE_GLOBAL_STATE__",Mi="__PAE_REACTIVE_GLOBAL_STATE__",$i="__PAE_EXTENSIONS_POINTS_REGISTRY__",Io="__PAE_CUSTOMIZATIONS_LOADING_STATE_KEY__",cf="/auth/logout",uf=(e,t)=>{const[n,r]=S.useState(t);return S.useEffect(()=>{const o=e.subscribe(s=>{r(s)});return()=>{o.unsubscribe()}},[r]),n},df=(e,t,n)=>n.map((r,o)=>o===e?t(r):r),ff=(e,t,n)=>df(n.findIndex(e),t,n),jo=(e,t)=>typeof e=="function"?e(t):e,Fi=(e,t)=>{const n=uf(e,t),r=S.useCallback(o=>{e.next(jo(o,n))},[n]);return[n,r]},fn=()=>Fi(window[Mi],window[Hn]),pn=()=>fn()[0].catalog,pf=()=>{const e=pn(),t=S.useCallback(r=>{window[Mi].next({...window[Hn],catalog:jo(r,e)})},[e]),n=S.useCallback((r,o)=>{t(s=>ff(i=>i.name===r,i=>{var a;return{...i,ui:{...i.ui,customProps:jo(o,((a=i.ui)==null?void 0:a.customProps)??{})}}},s))},[t]);return[e,t,n]},Bi=()=>{const[e,t]=S.useState(document.location.pathname);return S.useEffect(()=>{const n=()=>{t(window.location.pathname)};return window.addEventListener("popstate",n),()=>{window.removeEventListener("popstate",n)}},[t]),e};var hf=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function mf(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Ui={exports:{}},Vn={},Wi;function gf(){if(Wi)return Vn;Wi=1;/**
|
|
3
3
|
* @license React
|
|
4
4
|
* react-jsx-runtime.development.js
|
|
5
5
|
*
|
|
@@ -11,16 +11,16 @@
|
|
|
11
11
|
`+$+w}}var fe=!1,X;{var ne=typeof WeakMap=="function"?WeakMap:Map;X=new ne}function J(w,O){if(!w||fe)return"";{var j=X.get(w);if(j!==void 0)return j}var B;fe=!0;var re=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var ae;ae=Ve.current,Ve.current=null,rt();try{if(O){var Q=function(){throw Error()};if(Object.defineProperty(Q.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Q,[])}catch(Ae){B=Ae}Reflect.construct(w,[],Q)}else{try{Q.call()}catch(Ae){B=Ae}w.call(Q.prototype)}}else{try{throw Error()}catch(Ae){B=Ae}w()}}catch(Ae){if(Ae&&B&&typeof Ae.stack=="string"){for(var q=Ae.stack.split(`
|
|
12
12
|
`),Se=B.stack.split(`
|
|
13
13
|
`),de=q.length-1,pe=Se.length-1;de>=1&&pe>=0&&q[de]!==Se[pe];)pe--;for(;de>=1&&pe>=0;de--,pe--)if(q[de]!==Se[pe]){if(de!==1||pe!==1)do if(de--,pe--,pe<0||q[de]!==Se[pe]){var De=`
|
|
14
|
-
`+q[de].replace(" at new "," at ");return w.displayName&&De.includes("<anonymous>")&&(De=De.replace("<anonymous>",w.displayName)),typeof w=="function"&&X.set(w,De),De}while(de>=1&&pe>=0);break}}}finally{fe=!1,Ve.current=ae,Ft(),Error.prepareStackTrace=re}var Wn=w?w.displayName||w.name:"",dn=Wn?te(Wn):"";return typeof w=="function"&&X.set(w,dn),dn}function Ce(w,O,j){return J(w,!1)}function Le(w){var O=w.prototype;return!!(O&&O.isReactComponent)}function ot(w,O,j){if(w==null)return"";if(typeof w=="function")return J(w,Le(w));if(typeof w=="string")return te(w);switch(w){case u:return te("Suspense");case f:return te("SuspenseList")}if(typeof w=="object")switch(w.$$typeof){case l:return Ce(w.render);case p:return ot(w.type,O,j);case m:{var B=w,re=B._payload,ae=B._init;try{return ot(ae(re),O,j)}catch{}}}return""}var ze=Object.prototype.hasOwnProperty,Bt={},Ao=b.ReactDebugCurrentFrame;function ht(w){if(w){var O=w._owner,j=ot(w.type,w._source,O?O.type:null);Ao.setExtraStackFrame(j)}else Ao.setExtraStackFrame(null)}function
|
|
14
|
+
`+q[de].replace(" at new "," at ");return w.displayName&&De.includes("<anonymous>")&&(De=De.replace("<anonymous>",w.displayName)),typeof w=="function"&&X.set(w,De),De}while(de>=1&&pe>=0);break}}}finally{fe=!1,Ve.current=ae,Ft(),Error.prepareStackTrace=re}var Wn=w?w.displayName||w.name:"",dn=Wn?te(Wn):"";return typeof w=="function"&&X.set(w,dn),dn}function Ce(w,O,j){return J(w,!1)}function Le(w){var O=w.prototype;return!!(O&&O.isReactComponent)}function ot(w,O,j){if(w==null)return"";if(typeof w=="function")return J(w,Le(w));if(typeof w=="string")return te(w);switch(w){case u:return te("Suspense");case f:return te("SuspenseList")}if(typeof w=="object")switch(w.$$typeof){case l:return Ce(w.render);case p:return ot(w.type,O,j);case m:{var B=w,re=B._payload,ae=B._init;try{return ot(ae(re),O,j)}catch{}}}return""}var ze=Object.prototype.hasOwnProperty,Bt={},Ao=b.ReactDebugCurrentFrame;function ht(w){if(w){var O=w._owner,j=ot(w.type,w._source,O?O.type:null);Ao.setExtraStackFrame(j)}else Ao.setExtraStackFrame(null)}function W0(w,O,j,B,re){{var ae=Function.call.bind(ze);for(var Q in w)if(ae(w,Q)){var q=void 0;try{if(typeof w[Q]!="function"){var Se=Error((B||"React class")+": "+j+" type `"+Q+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof w[Q]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw Se.name="Invariant Violation",Se}q=w[Q](O,Q,B,j,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(de){q=de}q&&!(q instanceof Error)&&(ht(re),_("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",B||"React class",j,Q,typeof q),ht(null)),q instanceof Error&&!(q.message in Bt)&&(Bt[q.message]=!0,ht(re),_("Failed %s type: %s",j,q.message),ht(null))}}}var H0=Array.isArray;function xi(w){return H0(w)}function V0(w){{var O=typeof Symbol=="function"&&Symbol.toStringTag,j=O&&w[Symbol.toStringTag]||w.constructor.name||"Object";return j}}function z0(w){try{return qd(w),!1}catch{return!0}}function qd(w){return""+w}function Kd(w){if(z0(w))return _("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",V0(w)),qd(w)}var Qd=b.ReactCurrentOwner,G0={key:!0,ref:!0,__self:!0,__source:!0},Yd,Zd;function q0(w){if(ze.call(w,"ref")){var O=Object.getOwnPropertyDescriptor(w,"ref").get;if(O&&O.isReactWarning)return!1}return w.ref!==void 0}function K0(w){if(ze.call(w,"key")){var O=Object.getOwnPropertyDescriptor(w,"key").get;if(O&&O.isReactWarning)return!1}return w.key!==void 0}function Q0(w,O){typeof w.ref=="string"&&Qd.current}function Y0(w,O){{var j=function(){Yd||(Yd=!0,_("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",O))};j.isReactWarning=!0,Object.defineProperty(w,"key",{get:j,configurable:!0})}}function Z0(w,O){{var j=function(){Zd||(Zd=!0,_("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",O))};j.isReactWarning=!0,Object.defineProperty(w,"ref",{get:j,configurable:!0})}}var X0=function(w,O,j,B,re,ae,Q){var q={$$typeof:t,type:w,key:O,ref:j,props:Q,_owner:ae};return q._store={},Object.defineProperty(q._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(q,"_self",{configurable:!1,enumerable:!1,writable:!1,value:B}),Object.defineProperty(q,"_source",{configurable:!1,enumerable:!1,writable:!1,value:re}),Object.freeze&&(Object.freeze(q.props),Object.freeze(q)),q};function J0(w,O,j,B,re){{var ae,Q={},q=null,Se=null;j!==void 0&&(Kd(j),q=""+j),K0(O)&&(Kd(O.key),q=""+O.key),q0(O)&&(Se=O.ref,Q0(O,re));for(ae in O)ze.call(O,ae)&&!G0.hasOwnProperty(ae)&&(Q[ae]=O[ae]);if(w&&w.defaultProps){var de=w.defaultProps;for(ae in de)Q[ae]===void 0&&(Q[ae]=de[ae])}if(q||Se){var pe=typeof w=="function"?w.displayName||w.name||"Unknown":w;q&&Y0(Q,pe),Se&&Z0(Q,pe)}return X0(w,q,Se,re,B,Qd.current,Q)}}var Ci=b.ReactCurrentOwner,Xd=b.ReactDebugCurrentFrame;function Un(w){if(w){var O=w._owner,j=ot(w.type,w._source,O?O.type:null);Xd.setExtraStackFrame(j)}else Xd.setExtraStackFrame(null)}var Si;Si=!1;function Ei(w){return typeof w=="object"&&w!==null&&w.$$typeof===t}function Jd(){{if(Ci.current){var w=H(Ci.current.type);if(w)return`
|
|
15
15
|
|
|
16
|
-
Check the render method of \``+w+"`."}return""}}function
|
|
16
|
+
Check the render method of \``+w+"`."}return""}}function eb(w){return""}var ef={};function tb(w){{var O=Jd();if(!O){var j=typeof w=="string"?w:w.displayName||w.name;j&&(O=`
|
|
17
17
|
|
|
18
|
-
Check the top-level render call using <`+j+">.")}return O}}function
|
|
18
|
+
Check the top-level render call using <`+j+">.")}return O}}function tf(w,O){{if(!w._store||w._store.validated||w.key!=null)return;w._store.validated=!0;var j=tb(O);if(ef[j])return;ef[j]=!0;var B="";w&&w._owner&&w._owner!==Ci.current&&(B=" It was passed a child from "+H(w._owner.type)+"."),Un(w),_('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',j,B),Un(null)}}function nf(w,O){{if(typeof w!="object")return;if(xi(w))for(var j=0;j<w.length;j++){var B=w[j];Ei(B)&&tf(B,O)}else if(Ei(w))w._store&&(w._store.validated=!0);else if(w){var re=v(w);if(typeof re=="function"&&re!==w.entries)for(var ae=re.call(w),Q;!(Q=ae.next()).done;)Ei(Q.value)&&tf(Q.value,O)}}}function nb(w){{var O=w.type;if(O==null||typeof O=="string")return;var j;if(typeof O=="function")j=O.propTypes;else if(typeof O=="object"&&(O.$$typeof===l||O.$$typeof===p))j=O.propTypes;else return;if(j){var B=H(O);W0(j,w.props,"prop",B,w)}else if(O.PropTypes!==void 0&&!Si){Si=!0;var re=H(O);_("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",re||"Unknown")}typeof O.getDefaultProps=="function"&&!O.getDefaultProps.isReactClassApproved&&_("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function rb(w){{for(var O=Object.keys(w.props),j=0;j<O.length;j++){var B=O[j];if(B!=="children"&&B!=="key"){Un(w),_("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",B),Un(null);break}}w.ref!==null&&(Un(w),_("Invalid attribute `ref` supplied to `React.Fragment`."),Un(null))}}var rf={};function of(w,O,j,B,re,ae){{var Q=N(w);if(!Q){var q="";(w===void 0||typeof w=="object"&&w!==null&&Object.keys(w).length===0)&&(q+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var Se=eb();Se?q+=Se:q+=Jd();var de;w===null?de="null":xi(w)?de="array":w!==void 0&&w.$$typeof===t?(de="<"+(H(w.type)||"Unknown")+" />",q=" Did you accidentally export a JSX literal instead of a component?"):de=typeof w,_("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",de,q)}var pe=J0(w,O,j,re,ae);if(pe==null)return pe;if(Q){var De=O.children;if(De!==void 0)if(B)if(xi(De)){for(var Wn=0;Wn<De.length;Wn++)nf(De[Wn],w);Object.freeze&&Object.freeze(De)}else _("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else nf(De,w)}if(ze.call(O,"key")){var dn=H(w),Ae=Object.keys(O).filter(function(cb){return cb!=="key"}),Ti=Ae.length>0?"{key: someKey, "+Ae.join(": ..., ")+": ...}":"{key: someKey}";if(!rf[dn+Ti]){var lb=Ae.length>0?"{"+Ae.join(": ..., ")+": ...}":"{}";_(`A props object containing a "key" prop is being spread into JSX:
|
|
19
19
|
let props = %s;
|
|
20
20
|
<%s {...props} />
|
|
21
21
|
React keys must be passed directly to JSX without using spread:
|
|
22
22
|
let props = %s;
|
|
23
|
-
<%s key={someKey} {...props} />`,Ei,dn,ob,dn),ef[dn+Ei]=!0}}return w===r?J0(pe):X0(pe),pe}}function eb(w,O,j){return tf(w,O,j,!0)}function tb(w,O,j){return tf(w,O,j,!1)}var nb=tb,rb=eb;Vn.Fragment=r,Vn.jsx=nb,Vn.jsxs=rb}(),Vn}Bi.exports=pf();var c=Bi.exports;const Wi=S.createContext(null),Hi=({module:e,children:t})=>c.jsx(Wi.Provider,{value:e,children:t});Hi.displayName="PAEModule";const zn=()=>{const e=S.useContext(Wi);if(!e)throw new Error("Module metadata was not setup yet !!");return e};function ko(){if(!window[Hn])throw new Error("PAE Global state not found.");return window[Hn]}const Lo=()=>{const{authUser:{applications:e}}=ko();return e||[]},Vi=e=>Lo().filter(t=>t.name===e).flatMap(t=>t.operations),zi=()=>{const{application:e}=zn();return S.useMemo(()=>Vi(e),[e])},Gi=e=>(...t)=>t.every(n=>e.some(r=>r.name===n)),Gn=()=>{const[{authUser:e}]=fn(),t=zi();return{authUser:e,hasAccess:S.useMemo(()=>Gi(t),[t])}},hf=()=>{const{authUser:e}=Gn();return!e||e.id==="anon"},Do=()=>{var e;return((e=zn().ui)==null?void 0:e.customProps)??{}},No=e=>{const t=pn();return S.useMemo(()=>{const n=t.find(r=>r.name===e);if(!n)throw new Error(`Could not find the module [${e}] in the local catalog !`);return n},[t,e])},qi=e=>{var t,n;return((n=(t=No(e))==null?void 0:t.ui)==null?void 0:n.customProps)??{}},mf=e=>e.replace(/\/+/g,"/"),gf=(e,t="only-base-path")=>{const{apiDocs:n,health:r,version:o,changelog:s}=(e==null?void 0:e.commonPaths)||{},i=(a,l="")=>{if(a===void 0&&!l)return;const u=a??l;if(t==="only-base-path")return u;const f=mf(`${e.baseUrl}/${u}`);return t==="with-module-base"?f:`${document.location.origin}${f}`};return{apiDocsPath:i(n,"/api-docs-json"),healthPath:i(r,"/health"),versionPath:i(o,"/version"),changelogPath:i(s,"/changelog")}};function vf(){window.open(sf,"_self")}const yf=e=>he.navigateToUrl(e),bf=/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9-]+(\.[a-zA-Z0-9-]+)*\.[a-zA-Z]{2,}$/,wf=e=>bf.test(e),_f=(e,t=2)=>{if(!e)return"";const n=e.split(" ");return n.length===1?n.join("").slice(0,t):n.map(r=>r[0]).join("").slice(0,t)},Ki=e=>e.type==="app"||e.type==="tool",xf=e=>e.modules.some(Ki)&&e.route&&e.route!=="/",Qi=e=>{const{catalog:t}=ko();return gr(t.filter(n=>n.application===e))},gr=(e=[])=>e.find(t=>{var n;return Ki(t)&&((n=t.ui)==null?void 0:n.route)!=="/"}),Yi=()=>{const e=pn();return S.useMemo(()=>Lo().map(n=>{var s,i,a;const r=Cf(e,n.name),o=gr(r);return{name:n.name,displayName:((i=(s=o==null?void 0:o.ui)==null?void 0:s.customProps)==null?void 0:i.overrideApplicationDisplayName)??n.displayName,modules:r,route:(a=o==null?void 0:o.ui)==null?void 0:a.route,roles:[],operations:n.operations}}),[e])},Cf=(e,t)=>e.filter(n=>n.application===t)||[],Zi=()=>{const e=Yi();return S.useMemo(()=>e.filter(xf),[e])},Xi=e=>S.useMemo(()=>e?Qi(e.name):void 0,[e]),Mo="__PAE_STYLE_TARGETS__",Sf=()=>{const e=window;return e[Mo]??(e[Mo]={})},Ef=e=>{const t=Sf();let n=t[e];if(!n){const r=document.createElement("div");r.setAttribute("data-pae-style-holder",e),n=t[e]={name:e,target:r,holder:r,mode:"detached"}}return n},$o=(e,t,n)=>{e.querySelectorAll("style[data-pae-module], link[data-pae-module]").forEach(r=>{r.getAttribute("data-pae-module")===n&&t.appendChild(r)})},Ji=e=>{const t=Ef(e);return $o(document.head,t.holder,t.name),t.mode!=="shadow"&&(t.target=t.holder,t.mode="detached"),t};function ea(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function vr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ea(Object(n),!0).forEach(function(r){Tf(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ea(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ta(e){return(ta=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}function Tf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Fo(e){return(Fo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}function na(e,t){var n;if(typeof(n=t.domElement?function(){return t.domElement}:t.domElementGetter?t.domElementGetter:e.domElementGetter?e.domElementGetter:function(r){var o=r.appName||r.name;if(!o)throw Error("single-spa's dom-element-getter-helpers was not given an application name as a prop, so it can't make a unique dom element container for the react application");var s="single-spa-application:".concat(o);return function(){var i=document.getElementById(s);return i||((i=document.createElement("div")).id=s,document.body.appendChild(i)),i}}(t))!="function")throw Error("single-spa's dom-element-getter-helpers was given an invalid domElementGetter for application or parcel '".concat(t.name,"'. Expected a function, received ").concat(Fo(n)));return function(){var r=n(t);if(!(r instanceof HTMLElement))throw Error("single-spa's dom-element-getter-helpers: domElementGetter returned an invalid dom element for application or parcel '".concat(t.name,"'. Expected HTMLElement, received ").concat(Fo(r)));return r}}var qn=null;try{qn=require("react").createContext()}catch{}var Pf={React:null,ReactDOM:null,ReactDOMClient:null,rootComponent:null,loadRootComponent:null,errorBoundary:null,errorBoundaryClass:null,domElementGetter:null,parcelCanUpdate:!0,suppressComponentDidCatchWarning:!1,domElements:{},renderResults:{},updateResolves:{},unmountResolves:{}};function ra(e){if(ta(e)!=="object")throw new Error("single-spa-react requires a configuration object");var t,n=vr(vr({},Pf),e);if(!n.React)throw new Error("single-spa-react must be passed opts.React");if(!n.ReactDOM&&!n.ReactDOMClient)throw new Error("single-spa-react must be passed opts.ReactDOM or opts.ReactDOMClient");if(n.renderType||((t=n.ReactDOMClient)!==null&&t!==void 0&&t.createRoot?n.renderType="createRoot":n.renderType="render"),!n.rootComponent&&!n.loadRootComponent)throw new Error("single-spa-react must be passed opts.rootComponent or opts.loadRootComponent");if(n.errorBoundary&&typeof n.errorBoundary!="function")throw Error("The errorBoundary opt for single-spa-react must either be omitted or be a function that returns React elements");!qn&&n.React.createContext&&(qn=n.React.createContext()),n.SingleSpaRoot=function(o){function s(i){s.displayName="SingleSpaRoot(".concat(i.name,")")}return s.prototype=Object.create(o.React.Component.prototype),s.prototype.componentDidMount=function(){setTimeout(this.props.mountFinished)},s.prototype.componentWillUnmount=function(){setTimeout(this.props.unmountFinished)},s.prototype.render=function(){return setTimeout(this.props.updateFinished),this.props.children},s}(n);var r={bootstrap:Af.bind(null,n),mount:Rf.bind(null,n),unmount:Of.bind(null,n)};return n.parcelCanUpdate&&(r.update=If.bind(null,n)),r}function Af(e,t){return e.rootComponent?Promise.resolve():e.loadRootComponent(t).then(function(n){e.rootComponent=n})}function Rf(e,t){return new Promise(function(n,r){e.suppressComponentDidCatchWarning||!function(a){if(!(a&&typeof a.version=="string"&&a.version.indexOf(".")>=0))return!1;var l=a.version.slice(0,a.version.indexOf("."));try{return Number(l)>=16}catch{return!1}}(e.React)||e.errorBoundary||e.errorBoundaryClass||(e.rootComponent.prototype?e.rootComponent.prototype.componentDidCatch||console.warn("single-spa-react: ".concat(t.name||t.appName||t.childAppName,"'s rootComponent should implement componentDidCatch to avoid accidentally unmounting the entire single-spa application.")):console.warn("single-spa-react: ".concat(t.name||t.appName||t.childAppName,"'s rootComponent does not implement an error boundary. If using a functional component, consider providing an opts.errorBoundary to singleSpaReact(opts).")));var o=oa(e,t,function(){n(this)}),s=na(e,t)(),i=function(a){var l=a.reactDom,u=a.renderType,f=a.elementToRender,p=a.domElement,m=l[u];if(typeof m!="function")throw new Error('renderType "'.concat(u,'" did not return a function.'));switch(u){case"createRoot":case"unstable_createRoot":case"createBlockingRoot":case"unstable_createBlockingRoot":var g=m(p);return g.render(f),g;case"hydrateRoot":return m(p,f);case"hydrate":default:return m(f,p),null}}({elementToRender:o,domElement:s,reactDom:Bo(e),renderType:jf(e)});e.domElements[t.name]=s,e.renderResults[t.name]=i})}function Of(e,t){return new Promise(function(n){e.unmountResolves[t.name]=n;var r=e.renderResults[t.name];r&&r.unmount?r.unmount():Bo(e).unmountComponentAtNode(e.domElements[t.name]),delete e.domElements[t.name],delete e.renderResults[t.name]})}function If(e,t){return new Promise(function(n){e.updateResolves[t.name]||(e.updateResolves[t.name]=[]),e.updateResolves[t.name].push(n);var r=oa(e,t,null),o=e.renderResults[t.name];if(o&&o.render)o.render(r);else{var s=na(e,t)();Bo(e).render(r,s)}})}function Bo(e){return e.ReactDOMClient||e.ReactDOM}function jf(e){return typeof e.renderType=="function"?e.renderType():e.renderType}function oa(e,t,n){var r=e.React.createElement(e.rootComponent,t),o=qn?e.React.createElement(qn.Provider,{value:t},r):r;return(e.errorBoundary||t.errorBoundary||e.errorBoundaryClass||t.errorBoundaryClass)&&(e.errorBoundaryClass=e.errorBoundaryClass||t.errorBoundaryClass||function(s,i){function a(l){s.React.Component.apply(this,arguments),this.state={caughtError:null,caughtErrorInfo:null},a.displayName="SingleSpaReactErrorBoundary(".concat(l.name,")")}return a.prototype=Object.create(s.React.Component.prototype),a.prototype.render=function(){return this.state.caughtError?(s.errorBoundary||i.errorBoundary)(this.state.caughtError,this.state.caughtErrorInfo,this.props):this.props.children},a.prototype.componentDidCatch=function(l,u){this.setState({caughtError:l,caughtErrorInfo:u})},a}(e,t),o=e.React.createElement(e.errorBoundaryClass,t,o)),o=e.React.createElement(e.SingleSpaRoot,vr(vr({},t),{},{mountFinished:n,updateFinished:function(){e.updateResolves[t.name]&&(e.updateResolves[t.name].forEach(function(s){return s()}),delete e.updateResolves[t.name])},unmountFinished:function(){e.unmountResolves[t.name]&&(e.unmountResolves[t.name](),delete e.unmountResolves[t.name])}}),o)}let kf={data:""},Lf=e=>{if(typeof window=="object"){let t=(e?e.querySelector("#_goober"):window._goober)||Object.assign(document.createElement("style"),{innerHTML:" ",id:"_goober"});return t.nonce=window.__nonce__,t.parentNode||(e||document.head).appendChild(t),t.firstChild}return e||kf},Df=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,Nf=/\/\*[^]*?\*\/| +/g,sa=/\n+/g,gt=(e,t)=>{let n="",r="",o="";for(let s in e){let i=e[s];s[0]=="@"?s[1]=="i"?n=s+" "+i+";":r+=s[1]=="f"?gt(i,s):s+"{"+gt(i,s[1]=="k"?"":t)+"}":typeof i=="object"?r+=gt(i,t?t.replace(/([^,])+/g,a=>s.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,l=>/&/.test(l)?l.replace(/&/g,a):a?a+" "+l:l)):s):i!=null&&(s=/^--/.test(s)?s:s.replace(/[A-Z]/g,"-$&").toLowerCase(),o+=gt.p?gt.p(s,i):s+":"+i+";")}return n+(t&&o?t+"{"+o+"}":o)+r},st={},ia=e=>{if(typeof e=="object"){let t="";for(let n in e)t+=n+ia(e[n]);return t}return e},Mf=(e,t,n,r,o)=>{let s=ia(e),i=st[s]||(st[s]=(l=>{let u=0,f=11;for(;u<l.length;)f=101*f+l.charCodeAt(u++)>>>0;return"go"+f})(s));if(!st[i]){let l=s!==e?e:(u=>{let f,p,m=[{}];for(;f=Df.exec(u.replace(Nf,""));)f[4]?m.shift():f[3]?(p=f[3].replace(sa," ").trim(),m.unshift(m[0][p]=m[0][p]||{})):m[0][f[1]]=f[2].replace(sa," ").trim();return m[0]})(e);st[i]=gt(o?{["@keyframes "+i]:l}:l,n?"":"."+i)}let a=n&&st.g?st.g:null;return n&&(st.g=st[i]),((l,u,f,p)=>{p?u.data=u.data.replace(p,l):u.data.indexOf(l)===-1&&(u.data=f?l+u.data:u.data+l)})(st[i],t,r,a),i},$f=(e,t,n)=>e.reduce((r,o,s)=>{let i=t[s];if(i&&i.call){let a=i(n),l=a&&a.props&&a.props.className||/^go/.test(a)&&a;i=l?"."+l:a&&typeof a=="object"?a.props?"":gt(a,""):a===!1?"":a}return r+o+(i??"")},"");function yr(e){let t=this||{},n=e.call?e(t.p):e;return Mf(n.unshift?n.raw?$f(n,[].slice.call(arguments,1),t.p):n.reduce((r,o)=>Object.assign(r,o&&o.call?o(t.p):o),{}):n,Lf(t.target),t.g,t.o,t.k)}let aa,Uo,Wo;yr.bind({g:1});let it=yr.bind({k:1});function Ff(e,t,n,r){gt.p=t,aa=e,Uo=n,Wo=r}function vt(e,t){let n=this||{};return function(){let r=arguments;function o(s,i){let a=Object.assign({},s),l=a.className||o.className;n.p=Object.assign({theme:Uo&&Uo()},a),n.o=/ *go\d+/.test(l),a.className=yr.apply(n,r)+(l?" "+l:"");let u=e;return e[0]&&(u=a.as||e,delete a.as),Wo&&u[0]&&Wo(a),aa(u,a)}return o}}var Bf=e=>typeof e=="function",br=(e,t)=>Bf(e)?e(t):e,Uf=(()=>{let e=0;return()=>(++e).toString()})(),la=(()=>{let e;return()=>{if(e===void 0&&typeof window<"u"){let t=matchMedia("(prefers-reduced-motion: reduce)");e=!t||t.matches}return e}})(),Wf=20,wr=new Map,Hf=1e3,ca=e=>{if(wr.has(e))return;let t=setTimeout(()=>{wr.delete(e),Ht({type:4,toastId:e})},Hf);wr.set(e,t)},Vf=e=>{let t=wr.get(e);t&&clearTimeout(t)},Ho=(e,t)=>{switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,Wf)};case 1:return t.toast.id&&Vf(t.toast.id),{...e,toasts:e.toasts.map(s=>s.id===t.toast.id?{...s,...t.toast}:s)};case 2:let{toast:n}=t;return e.toasts.find(s=>s.id===n.id)?Ho(e,{type:1,toast:n}):Ho(e,{type:0,toast:n});case 3:let{toastId:r}=t;return r?ca(r):e.toasts.forEach(s=>{ca(s.id)}),{...e,toasts:e.toasts.map(s=>s.id===r||r===void 0?{...s,visible:!1}:s)};case 4:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(s=>s.id!==t.toastId)};case 5:return{...e,pausedAt:t.time};case 6:let o=t.time-(e.pausedAt||0);return{...e,pausedAt:void 0,toasts:e.toasts.map(s=>({...s,pauseDuration:s.pauseDuration+o}))}}},_r=[],xr={toasts:[],pausedAt:void 0},Ht=e=>{xr=Ho(xr,e),_r.forEach(t=>{t(xr)})},zf={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},Gf=(e={})=>{let[t,n]=S.useState(xr);S.useEffect(()=>(_r.push(n),()=>{let o=_r.indexOf(n);o>-1&&_r.splice(o,1)}),[t]);let r=t.toasts.map(o=>{var s,i;return{...e,...e[o.type],...o,duration:o.duration||((s=e[o.type])==null?void 0:s.duration)||(e==null?void 0:e.duration)||zf[o.type],style:{...e.style,...(i=e[o.type])==null?void 0:i.style,...o.style}}});return{...t,toasts:r}},qf=(e,t="blank",n)=>({createdAt:Date.now(),visible:!0,type:t,ariaProps:{role:"status","aria-live":"polite"},message:e,pauseDuration:0,...n,id:(n==null?void 0:n.id)||Uf()}),Kn=e=>(t,n)=>{let r=qf(t,e,n);return Ht({type:2,toast:r}),r.id},Re=(e,t)=>Kn("blank")(e,t);Re.error=Kn("error"),Re.success=Kn("success"),Re.loading=Kn("loading"),Re.custom=Kn("custom"),Re.dismiss=e=>{Ht({type:3,toastId:e})},Re.remove=e=>Ht({type:4,toastId:e}),Re.promise=(e,t,n)=>{let r=Re.loading(t.loading,{...n,...n==null?void 0:n.loading});return e.then(o=>(Re.success(br(t.success,o),{id:r,...n,...n==null?void 0:n.success}),o)).catch(o=>{Re.error(br(t.error,o),{id:r,...n,...n==null?void 0:n.error})}),e};var Kf=(e,t)=>{Ht({type:1,toast:{id:e,height:t}})},Qf=()=>{Ht({type:5,time:Date.now()})},Yf=e=>{let{toasts:t,pausedAt:n}=Gf(e);S.useEffect(()=>{if(n)return;let s=Date.now(),i=t.map(a=>{if(a.duration===1/0)return;let l=(a.duration||0)+a.pauseDuration-(s-a.createdAt);if(l<0){a.visible&&Re.dismiss(a.id);return}return setTimeout(()=>Re.dismiss(a.id),l)});return()=>{i.forEach(a=>a&&clearTimeout(a))}},[t,n]);let r=S.useCallback(()=>{n&&Ht({type:6,time:Date.now()})},[n]),o=S.useCallback((s,i)=>{let{reverseOrder:a=!1,gutter:l=8,defaultPosition:u}=i||{},f=t.filter(g=>(g.position||u)===(s.position||u)&&g.height),p=f.findIndex(g=>g.id===s.id),m=f.filter((g,y)=>y<p&&g.visible).length;return f.filter(g=>g.visible).slice(...a?[m+1]:[0,m]).reduce((g,y)=>g+(y.height||0)+l,0)},[t]);return{toasts:t,handlers:{updateHeight:Kf,startPause:Qf,endPause:r,calculateOffset:o}}},Zf=it`
|
|
23
|
+
<%s key={someKey} {...props} />`,Ti,dn,lb,dn),rf[dn+Ti]=!0}}return w===r?rb(pe):nb(pe),pe}}function ob(w,O,j){return of(w,O,j,!0)}function sb(w,O,j){return of(w,O,j,!1)}var ib=sb,ab=ob;Vn.Fragment=r,Vn.jsx=ib,Vn.jsxs=ab}(),Vn}Ui.exports=gf();var c=Ui.exports;const Hi=S.createContext(null),Vi=({module:e,children:t})=>c.jsx(Hi.Provider,{value:e,children:t});Vi.displayName="PAEModule";const zn=()=>{const e=S.useContext(Hi);if(!e)throw new Error("Module metadata was not setup yet !!");return e};function ko(){if(!window[Hn])throw new Error("PAE Global state not found.");return window[Hn]}const Lo=()=>{const{authUser:{applications:e}}=ko();return e||[]},zi=e=>Lo().filter(t=>t.name===e).flatMap(t=>t.operations),Gi=()=>{const{application:e}=zn();return S.useMemo(()=>zi(e),[e])},qi=e=>(...t)=>t.every(n=>e.some(r=>r.name===n)),Gn=()=>{const[{authUser:e}]=fn(),t=Gi();return{authUser:e,hasAccess:S.useMemo(()=>qi(t),[t])}},vf=()=>{const{authUser:e}=Gn();return!e||e.id==="anon"},Do=()=>{var e;return((e=zn().ui)==null?void 0:e.customProps)??{}},No=e=>{const t=pn();return S.useMemo(()=>{const n=t.find(r=>r.name===e);if(!n)throw new Error(`Could not find the module [${e}] in the local catalog !`);return n},[t,e])},Ki=e=>{var t,n;return((n=(t=No(e))==null?void 0:t.ui)==null?void 0:n.customProps)??{}},yf=e=>e.replace(/\/+/g,"/"),bf=(e,t="only-base-path")=>{const{apiDocs:n,health:r,version:o,changelog:s}=(e==null?void 0:e.commonPaths)||{},i=(a,l="")=>{if(a===void 0&&!l)return;const u=a??l;if(t==="only-base-path")return u;const f=yf(`${e.baseUrl}/${u}`);return t==="with-module-base"?f:`${document.location.origin}${f}`};return{apiDocsPath:i(n,"/api-docs-json"),healthPath:i(r,"/health"),versionPath:i(o,"/version"),changelogPath:i(s,"/changelog")}};function wf(){window.open(cf,"_self")}const _f=e=>he.navigateToUrl(e),xf=/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9-]+(\.[a-zA-Z0-9-]+)*\.[a-zA-Z]{2,}$/,Cf=e=>xf.test(e),Sf=(e,t=2)=>{if(!e)return"";const n=e.split(" ");return n.length===1?n.join("").slice(0,t):n.map(r=>r[0]).join("").slice(0,t)},Qi=e=>e.type==="app"||e.type==="tool",Ef=e=>e.modules.some(Qi)&&e.route&&e.route!=="/",Yi=e=>{const{catalog:t}=ko();return gr(t.filter(n=>n.application===e))},gr=(e=[])=>e.find(t=>{var n;return Qi(t)&&((n=t.ui)==null?void 0:n.route)!=="/"}),Zi=()=>{const e=pn();return S.useMemo(()=>Lo().map(n=>{var s,i,a;const r=Tf(e,n.name),o=gr(r);return{name:n.name,displayName:((i=(s=o==null?void 0:o.ui)==null?void 0:s.customProps)==null?void 0:i.overrideApplicationDisplayName)??n.displayName,modules:r,route:(a=o==null?void 0:o.ui)==null?void 0:a.route,roles:[],operations:n.operations}}),[e])},Tf=(e,t)=>e.filter(n=>n.application===t)||[],Xi=()=>{const e=Zi();return S.useMemo(()=>e.filter(Ef),[e])},Ji=e=>S.useMemo(()=>e?Yi(e.name):void 0,[e]),Mo="__PAE_STYLE_TARGETS__",Pf=()=>{const e=window;return e[Mo]??(e[Mo]={})},Af=e=>{const t=Pf();let n=t[e];if(!n){const r=document.createElement("div");r.setAttribute("data-pae-style-holder",e),n=t[e]={name:e,target:r,holder:r,mode:"detached"}}return n},$o=(e,t,n)=>{e.querySelectorAll("style[data-pae-module], link[data-pae-module]").forEach(r=>{r.getAttribute("data-pae-module")===n&&t.appendChild(r)})},ea=e=>{const t=Af(e);return $o(document.head,t.holder,t.name),t.mode!=="shadow"&&(t.target=t.holder,t.mode="detached"),t};function ta(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function vr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ta(Object(n),!0).forEach(function(r){Rf(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ta(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function na(e){return(na=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}function Rf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Fo(e){return(Fo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}function ra(e,t){var n;if(typeof(n=t.domElement?function(){return t.domElement}:t.domElementGetter?t.domElementGetter:e.domElementGetter?e.domElementGetter:function(r){var o=r.appName||r.name;if(!o)throw Error("single-spa's dom-element-getter-helpers was not given an application name as a prop, so it can't make a unique dom element container for the react application");var s="single-spa-application:".concat(o);return function(){var i=document.getElementById(s);return i||((i=document.createElement("div")).id=s,document.body.appendChild(i)),i}}(t))!="function")throw Error("single-spa's dom-element-getter-helpers was given an invalid domElementGetter for application or parcel '".concat(t.name,"'. Expected a function, received ").concat(Fo(n)));return function(){var r=n(t);if(!(r instanceof HTMLElement))throw Error("single-spa's dom-element-getter-helpers: domElementGetter returned an invalid dom element for application or parcel '".concat(t.name,"'. Expected HTMLElement, received ").concat(Fo(r)));return r}}var qn=null;try{qn=require("react").createContext()}catch{}var Of={React:null,ReactDOM:null,ReactDOMClient:null,rootComponent:null,loadRootComponent:null,errorBoundary:null,errorBoundaryClass:null,domElementGetter:null,parcelCanUpdate:!0,suppressComponentDidCatchWarning:!1,domElements:{},renderResults:{},updateResolves:{},unmountResolves:{}};function oa(e){if(na(e)!=="object")throw new Error("single-spa-react requires a configuration object");var t,n=vr(vr({},Of),e);if(!n.React)throw new Error("single-spa-react must be passed opts.React");if(!n.ReactDOM&&!n.ReactDOMClient)throw new Error("single-spa-react must be passed opts.ReactDOM or opts.ReactDOMClient");if(n.renderType||((t=n.ReactDOMClient)!==null&&t!==void 0&&t.createRoot?n.renderType="createRoot":n.renderType="render"),!n.rootComponent&&!n.loadRootComponent)throw new Error("single-spa-react must be passed opts.rootComponent or opts.loadRootComponent");if(n.errorBoundary&&typeof n.errorBoundary!="function")throw Error("The errorBoundary opt for single-spa-react must either be omitted or be a function that returns React elements");!qn&&n.React.createContext&&(qn=n.React.createContext()),n.SingleSpaRoot=function(o){function s(i){s.displayName="SingleSpaRoot(".concat(i.name,")")}return s.prototype=Object.create(o.React.Component.prototype),s.prototype.componentDidMount=function(){setTimeout(this.props.mountFinished)},s.prototype.componentWillUnmount=function(){setTimeout(this.props.unmountFinished)},s.prototype.render=function(){return setTimeout(this.props.updateFinished),this.props.children},s}(n);var r={bootstrap:If.bind(null,n),mount:jf.bind(null,n),unmount:kf.bind(null,n)};return n.parcelCanUpdate&&(r.update=Lf.bind(null,n)),r}function If(e,t){return e.rootComponent?Promise.resolve():e.loadRootComponent(t).then(function(n){e.rootComponent=n})}function jf(e,t){return new Promise(function(n,r){e.suppressComponentDidCatchWarning||!function(a){if(!(a&&typeof a.version=="string"&&a.version.indexOf(".")>=0))return!1;var l=a.version.slice(0,a.version.indexOf("."));try{return Number(l)>=16}catch{return!1}}(e.React)||e.errorBoundary||e.errorBoundaryClass||(e.rootComponent.prototype?e.rootComponent.prototype.componentDidCatch||console.warn("single-spa-react: ".concat(t.name||t.appName||t.childAppName,"'s rootComponent should implement componentDidCatch to avoid accidentally unmounting the entire single-spa application.")):console.warn("single-spa-react: ".concat(t.name||t.appName||t.childAppName,"'s rootComponent does not implement an error boundary. If using a functional component, consider providing an opts.errorBoundary to singleSpaReact(opts).")));var o=sa(e,t,function(){n(this)}),s=ra(e,t)(),i=function(a){var l=a.reactDom,u=a.renderType,f=a.elementToRender,p=a.domElement,m=l[u];if(typeof m!="function")throw new Error('renderType "'.concat(u,'" did not return a function.'));switch(u){case"createRoot":case"unstable_createRoot":case"createBlockingRoot":case"unstable_createBlockingRoot":var g=m(p);return g.render(f),g;case"hydrateRoot":return m(p,f);case"hydrate":default:return m(f,p),null}}({elementToRender:o,domElement:s,reactDom:Bo(e),renderType:Df(e)});e.domElements[t.name]=s,e.renderResults[t.name]=i})}function kf(e,t){return new Promise(function(n){e.unmountResolves[t.name]=n;var r=e.renderResults[t.name];r&&r.unmount?r.unmount():Bo(e).unmountComponentAtNode(e.domElements[t.name]),delete e.domElements[t.name],delete e.renderResults[t.name]})}function Lf(e,t){return new Promise(function(n){e.updateResolves[t.name]||(e.updateResolves[t.name]=[]),e.updateResolves[t.name].push(n);var r=sa(e,t,null),o=e.renderResults[t.name];if(o&&o.render)o.render(r);else{var s=ra(e,t)();Bo(e).render(r,s)}})}function Bo(e){return e.ReactDOMClient||e.ReactDOM}function Df(e){return typeof e.renderType=="function"?e.renderType():e.renderType}function sa(e,t,n){var r=e.React.createElement(e.rootComponent,t),o=qn?e.React.createElement(qn.Provider,{value:t},r):r;return(e.errorBoundary||t.errorBoundary||e.errorBoundaryClass||t.errorBoundaryClass)&&(e.errorBoundaryClass=e.errorBoundaryClass||t.errorBoundaryClass||function(s,i){function a(l){s.React.Component.apply(this,arguments),this.state={caughtError:null,caughtErrorInfo:null},a.displayName="SingleSpaReactErrorBoundary(".concat(l.name,")")}return a.prototype=Object.create(s.React.Component.prototype),a.prototype.render=function(){return this.state.caughtError?(s.errorBoundary||i.errorBoundary)(this.state.caughtError,this.state.caughtErrorInfo,this.props):this.props.children},a.prototype.componentDidCatch=function(l,u){this.setState({caughtError:l,caughtErrorInfo:u})},a}(e,t),o=e.React.createElement(e.errorBoundaryClass,t,o)),o=e.React.createElement(e.SingleSpaRoot,vr(vr({},t),{},{mountFinished:n,updateFinished:function(){e.updateResolves[t.name]&&(e.updateResolves[t.name].forEach(function(s){return s()}),delete e.updateResolves[t.name])},unmountFinished:function(){e.unmountResolves[t.name]&&(e.unmountResolves[t.name](),delete e.unmountResolves[t.name])}}),o)}let Nf={data:""},Mf=e=>{if(typeof window=="object"){let t=(e?e.querySelector("#_goober"):window._goober)||Object.assign(document.createElement("style"),{innerHTML:" ",id:"_goober"});return t.nonce=window.__nonce__,t.parentNode||(e||document.head).appendChild(t),t.firstChild}return e||Nf},$f=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,Ff=/\/\*[^]*?\*\/| +/g,ia=/\n+/g,gt=(e,t)=>{let n="",r="",o="";for(let s in e){let i=e[s];s[0]=="@"?s[1]=="i"?n=s+" "+i+";":r+=s[1]=="f"?gt(i,s):s+"{"+gt(i,s[1]=="k"?"":t)+"}":typeof i=="object"?r+=gt(i,t?t.replace(/([^,])+/g,a=>s.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,l=>/&/.test(l)?l.replace(/&/g,a):a?a+" "+l:l)):s):i!=null&&(s=/^--/.test(s)?s:s.replace(/[A-Z]/g,"-$&").toLowerCase(),o+=gt.p?gt.p(s,i):s+":"+i+";")}return n+(t&&o?t+"{"+o+"}":o)+r},st={},aa=e=>{if(typeof e=="object"){let t="";for(let n in e)t+=n+aa(e[n]);return t}return e},Bf=(e,t,n,r,o)=>{let s=aa(e),i=st[s]||(st[s]=(l=>{let u=0,f=11;for(;u<l.length;)f=101*f+l.charCodeAt(u++)>>>0;return"go"+f})(s));if(!st[i]){let l=s!==e?e:(u=>{let f,p,m=[{}];for(;f=$f.exec(u.replace(Ff,""));)f[4]?m.shift():f[3]?(p=f[3].replace(ia," ").trim(),m.unshift(m[0][p]=m[0][p]||{})):m[0][f[1]]=f[2].replace(ia," ").trim();return m[0]})(e);st[i]=gt(o?{["@keyframes "+i]:l}:l,n?"":"."+i)}let a=n&&st.g?st.g:null;return n&&(st.g=st[i]),((l,u,f,p)=>{p?u.data=u.data.replace(p,l):u.data.indexOf(l)===-1&&(u.data=f?l+u.data:u.data+l)})(st[i],t,r,a),i},Uf=(e,t,n)=>e.reduce((r,o,s)=>{let i=t[s];if(i&&i.call){let a=i(n),l=a&&a.props&&a.props.className||/^go/.test(a)&&a;i=l?"."+l:a&&typeof a=="object"?a.props?"":gt(a,""):a===!1?"":a}return r+o+(i??"")},"");function yr(e){let t=this||{},n=e.call?e(t.p):e;return Bf(n.unshift?n.raw?Uf(n,[].slice.call(arguments,1),t.p):n.reduce((r,o)=>Object.assign(r,o&&o.call?o(t.p):o),{}):n,Mf(t.target),t.g,t.o,t.k)}let la,Uo,Wo;yr.bind({g:1});let it=yr.bind({k:1});function Wf(e,t,n,r){gt.p=t,la=e,Uo=n,Wo=r}function vt(e,t){let n=this||{};return function(){let r=arguments;function o(s,i){let a=Object.assign({},s),l=a.className||o.className;n.p=Object.assign({theme:Uo&&Uo()},a),n.o=/ *go\d+/.test(l),a.className=yr.apply(n,r)+(l?" "+l:"");let u=e;return e[0]&&(u=a.as||e,delete a.as),Wo&&u[0]&&Wo(a),la(u,a)}return o}}var Hf=e=>typeof e=="function",br=(e,t)=>Hf(e)?e(t):e,Vf=(()=>{let e=0;return()=>(++e).toString()})(),ca=(()=>{let e;return()=>{if(e===void 0&&typeof window<"u"){let t=matchMedia("(prefers-reduced-motion: reduce)");e=!t||t.matches}return e}})(),zf=20,wr=new Map,Gf=1e3,ua=e=>{if(wr.has(e))return;let t=setTimeout(()=>{wr.delete(e),Ht({type:4,toastId:e})},Gf);wr.set(e,t)},qf=e=>{let t=wr.get(e);t&&clearTimeout(t)},Ho=(e,t)=>{switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,zf)};case 1:return t.toast.id&&qf(t.toast.id),{...e,toasts:e.toasts.map(s=>s.id===t.toast.id?{...s,...t.toast}:s)};case 2:let{toast:n}=t;return e.toasts.find(s=>s.id===n.id)?Ho(e,{type:1,toast:n}):Ho(e,{type:0,toast:n});case 3:let{toastId:r}=t;return r?ua(r):e.toasts.forEach(s=>{ua(s.id)}),{...e,toasts:e.toasts.map(s=>s.id===r||r===void 0?{...s,visible:!1}:s)};case 4:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(s=>s.id!==t.toastId)};case 5:return{...e,pausedAt:t.time};case 6:let o=t.time-(e.pausedAt||0);return{...e,pausedAt:void 0,toasts:e.toasts.map(s=>({...s,pauseDuration:s.pauseDuration+o}))}}},_r=[],xr={toasts:[],pausedAt:void 0},Ht=e=>{xr=Ho(xr,e),_r.forEach(t=>{t(xr)})},Kf={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},Qf=(e={})=>{let[t,n]=S.useState(xr);S.useEffect(()=>(_r.push(n),()=>{let o=_r.indexOf(n);o>-1&&_r.splice(o,1)}),[t]);let r=t.toasts.map(o=>{var s,i;return{...e,...e[o.type],...o,duration:o.duration||((s=e[o.type])==null?void 0:s.duration)||(e==null?void 0:e.duration)||Kf[o.type],style:{...e.style,...(i=e[o.type])==null?void 0:i.style,...o.style}}});return{...t,toasts:r}},Yf=(e,t="blank",n)=>({createdAt:Date.now(),visible:!0,type:t,ariaProps:{role:"status","aria-live":"polite"},message:e,pauseDuration:0,...n,id:(n==null?void 0:n.id)||Vf()}),Kn=e=>(t,n)=>{let r=Yf(t,e,n);return Ht({type:2,toast:r}),r.id},Re=(e,t)=>Kn("blank")(e,t);Re.error=Kn("error"),Re.success=Kn("success"),Re.loading=Kn("loading"),Re.custom=Kn("custom"),Re.dismiss=e=>{Ht({type:3,toastId:e})},Re.remove=e=>Ht({type:4,toastId:e}),Re.promise=(e,t,n)=>{let r=Re.loading(t.loading,{...n,...n==null?void 0:n.loading});return e.then(o=>(Re.success(br(t.success,o),{id:r,...n,...n==null?void 0:n.success}),o)).catch(o=>{Re.error(br(t.error,o),{id:r,...n,...n==null?void 0:n.error})}),e};var Zf=(e,t)=>{Ht({type:1,toast:{id:e,height:t}})},Xf=()=>{Ht({type:5,time:Date.now()})},Jf=e=>{let{toasts:t,pausedAt:n}=Qf(e);S.useEffect(()=>{if(n)return;let s=Date.now(),i=t.map(a=>{if(a.duration===1/0)return;let l=(a.duration||0)+a.pauseDuration-(s-a.createdAt);if(l<0){a.visible&&Re.dismiss(a.id);return}return setTimeout(()=>Re.dismiss(a.id),l)});return()=>{i.forEach(a=>a&&clearTimeout(a))}},[t,n]);let r=S.useCallback(()=>{n&&Ht({type:6,time:Date.now()})},[n]),o=S.useCallback((s,i)=>{let{reverseOrder:a=!1,gutter:l=8,defaultPosition:u}=i||{},f=t.filter(g=>(g.position||u)===(s.position||u)&&g.height),p=f.findIndex(g=>g.id===s.id),m=f.filter((g,y)=>y<p&&g.visible).length;return f.filter(g=>g.visible).slice(...a?[m+1]:[0,m]).reduce((g,y)=>g+(y.height||0)+l,0)},[t]);return{toasts:t,handlers:{updateHeight:Zf,startPause:Xf,endPause:r,calculateOffset:o}}},ep=it`
|
|
24
24
|
from {
|
|
25
25
|
transform: scale(0) rotate(45deg);
|
|
26
26
|
opacity: 0;
|
|
@@ -28,7 +28,7 @@ from {
|
|
|
28
28
|
to {
|
|
29
29
|
transform: scale(1) rotate(45deg);
|
|
30
30
|
opacity: 1;
|
|
31
|
-
}`,
|
|
31
|
+
}`,tp=it`
|
|
32
32
|
from {
|
|
33
33
|
transform: scale(0);
|
|
34
34
|
opacity: 0;
|
|
@@ -36,7 +36,7 @@ from {
|
|
|
36
36
|
to {
|
|
37
37
|
transform: scale(1);
|
|
38
38
|
opacity: 1;
|
|
39
|
-
}`,
|
|
39
|
+
}`,np=it`
|
|
40
40
|
from {
|
|
41
41
|
transform: scale(0) rotate(90deg);
|
|
42
42
|
opacity: 0;
|
|
@@ -44,7 +44,7 @@ from {
|
|
|
44
44
|
to {
|
|
45
45
|
transform: scale(1) rotate(90deg);
|
|
46
46
|
opacity: 1;
|
|
47
|
-
}`,
|
|
47
|
+
}`,rp=vt("div")`
|
|
48
48
|
width: 20px;
|
|
49
49
|
opacity: 0;
|
|
50
50
|
height: 20px;
|
|
@@ -53,14 +53,14 @@ to {
|
|
|
53
53
|
position: relative;
|
|
54
54
|
transform: rotate(45deg);
|
|
55
55
|
|
|
56
|
-
animation: ${
|
|
56
|
+
animation: ${ep} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
|
|
57
57
|
forwards;
|
|
58
58
|
animation-delay: 100ms;
|
|
59
59
|
|
|
60
60
|
&:after,
|
|
61
61
|
&:before {
|
|
62
62
|
content: '';
|
|
63
|
-
animation: ${
|
|
63
|
+
animation: ${tp} 0.15s ease-out forwards;
|
|
64
64
|
animation-delay: 150ms;
|
|
65
65
|
position: absolute;
|
|
66
66
|
border-radius: 3px;
|
|
@@ -73,18 +73,18 @@ to {
|
|
|
73
73
|
}
|
|
74
74
|
|
|
75
75
|
&:before {
|
|
76
|
-
animation: ${
|
|
76
|
+
animation: ${np} 0.15s ease-out forwards;
|
|
77
77
|
animation-delay: 180ms;
|
|
78
78
|
transform: rotate(90deg);
|
|
79
79
|
}
|
|
80
|
-
`,
|
|
80
|
+
`,op=it`
|
|
81
81
|
from {
|
|
82
82
|
transform: rotate(0deg);
|
|
83
83
|
}
|
|
84
84
|
to {
|
|
85
85
|
transform: rotate(360deg);
|
|
86
86
|
}
|
|
87
|
-
`,
|
|
87
|
+
`,sp=vt("div")`
|
|
88
88
|
width: 12px;
|
|
89
89
|
height: 12px;
|
|
90
90
|
box-sizing: border-box;
|
|
@@ -92,8 +92,8 @@ to {
|
|
|
92
92
|
border-radius: 100%;
|
|
93
93
|
border-color: ${e=>e.secondary||"#e0e0e0"};
|
|
94
94
|
border-right-color: ${e=>e.primary||"#616161"};
|
|
95
|
-
animation: ${
|
|
96
|
-
`,
|
|
95
|
+
animation: ${op} 1s linear infinite;
|
|
96
|
+
`,ip=it`
|
|
97
97
|
from {
|
|
98
98
|
transform: scale(0) rotate(45deg);
|
|
99
99
|
opacity: 0;
|
|
@@ -101,7 +101,7 @@ from {
|
|
|
101
101
|
to {
|
|
102
102
|
transform: scale(1) rotate(45deg);
|
|
103
103
|
opacity: 1;
|
|
104
|
-
}`,
|
|
104
|
+
}`,ap=it`
|
|
105
105
|
0% {
|
|
106
106
|
height: 0;
|
|
107
107
|
width: 0;
|
|
@@ -115,7 +115,7 @@ to {
|
|
|
115
115
|
100% {
|
|
116
116
|
opacity: 1;
|
|
117
117
|
height: 10px;
|
|
118
|
-
}`,
|
|
118
|
+
}`,lp=vt("div")`
|
|
119
119
|
width: 20px;
|
|
120
120
|
opacity: 0;
|
|
121
121
|
height: 20px;
|
|
@@ -124,13 +124,13 @@ to {
|
|
|
124
124
|
position: relative;
|
|
125
125
|
transform: rotate(45deg);
|
|
126
126
|
|
|
127
|
-
animation: ${
|
|
127
|
+
animation: ${ip} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
|
|
128
128
|
forwards;
|
|
129
129
|
animation-delay: 100ms;
|
|
130
130
|
&:after {
|
|
131
131
|
content: '';
|
|
132
132
|
box-sizing: border-box;
|
|
133
|
-
animation: ${
|
|
133
|
+
animation: ${ap} 0.2s ease-out forwards;
|
|
134
134
|
opacity: 0;
|
|
135
135
|
animation-delay: 200ms;
|
|
136
136
|
position: absolute;
|
|
@@ -142,16 +142,16 @@ to {
|
|
|
142
142
|
height: 10px;
|
|
143
143
|
width: 6px;
|
|
144
144
|
}
|
|
145
|
-
`,
|
|
145
|
+
`,cp=vt("div")`
|
|
146
146
|
position: absolute;
|
|
147
|
-
`,
|
|
147
|
+
`,up=vt("div")`
|
|
148
148
|
position: relative;
|
|
149
149
|
display: flex;
|
|
150
150
|
justify-content: center;
|
|
151
151
|
align-items: center;
|
|
152
152
|
min-width: 20px;
|
|
153
153
|
min-height: 20px;
|
|
154
|
-
`,
|
|
154
|
+
`,dp=it`
|
|
155
155
|
from {
|
|
156
156
|
transform: scale(0.6);
|
|
157
157
|
opacity: 0.4;
|
|
@@ -159,20 +159,20 @@ from {
|
|
|
159
159
|
to {
|
|
160
160
|
transform: scale(1);
|
|
161
161
|
opacity: 1;
|
|
162
|
-
}`,
|
|
162
|
+
}`,fp=vt("div")`
|
|
163
163
|
position: relative;
|
|
164
164
|
transform: scale(0.6);
|
|
165
165
|
opacity: 0.4;
|
|
166
166
|
min-width: 20px;
|
|
167
|
-
animation: ${
|
|
167
|
+
animation: ${dp} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275)
|
|
168
168
|
forwards;
|
|
169
|
-
`,
|
|
169
|
+
`,pp=({toast:e})=>{let{icon:t,type:n,iconTheme:r}=e;return t!==void 0?typeof t=="string"?d.createElement(fp,null,t):t:n==="blank"?null:d.createElement(up,null,d.createElement(sp,{...r}),n!=="loading"&&d.createElement(cp,null,n==="error"?d.createElement(rp,{...r}):d.createElement(lp,{...r})))},hp=e=>`
|
|
170
170
|
0% {transform: translate3d(0,${e*-200}%,0) scale(.6); opacity:.5;}
|
|
171
171
|
100% {transform: translate3d(0,0,0) scale(1); opacity:1;}
|
|
172
|
-
`,
|
|
172
|
+
`,mp=e=>`
|
|
173
173
|
0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}
|
|
174
174
|
100% {transform: translate3d(0,${e*-150}%,-1px) scale(.6); opacity:0;}
|
|
175
|
-
`,
|
|
175
|
+
`,gp="0%{opacity:0;} 100%{opacity:1;}",vp="0%{opacity:1;} 100%{opacity:0;}",yp=vt("div")`
|
|
176
176
|
display: flex;
|
|
177
177
|
align-items: center;
|
|
178
178
|
background: #fff;
|
|
@@ -184,20 +184,20 @@ to {
|
|
|
184
184
|
pointer-events: auto;
|
|
185
185
|
padding: 8px 10px;
|
|
186
186
|
border-radius: 8px;
|
|
187
|
-
`,
|
|
187
|
+
`,bp=vt("div")`
|
|
188
188
|
display: flex;
|
|
189
189
|
justify-content: center;
|
|
190
190
|
margin: 4px 10px;
|
|
191
191
|
color: inherit;
|
|
192
192
|
flex: 1 1 auto;
|
|
193
193
|
white-space: pre-line;
|
|
194
|
-
`,
|
|
194
|
+
`,wp=(e,t)=>{let n=e.includes("top")?1:-1,[r,o]=ca()?[gp,vp]:[hp(n),mp(n)];return{animation:t?`${it(r)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${it(o)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}},_p=d.memo(({toast:e,position:t,style:n,children:r})=>{let o=e.height?wp(e.position||t||"top-center",e.visible):{opacity:0},s=d.createElement(pp,{toast:e}),i=d.createElement(bp,{...e.ariaProps},br(e.message,e));return d.createElement(yp,{className:e.className,style:{...o,...n,...e.style}},typeof r=="function"?r({icon:s,message:i}):d.createElement(d.Fragment,null,s,i))});Wf(d.createElement);var xp=({id:e,className:t,style:n,onHeightUpdate:r,children:o})=>{let s=d.useCallback(i=>{if(i){let a=()=>{let l=i.getBoundingClientRect().height;r(e,l)};a(),new MutationObserver(a).observe(i,{subtree:!0,childList:!0,characterData:!0})}},[e,r]);return d.createElement("div",{ref:s,className:t,style:n},o)},Cp=(e,t)=>{let n=e.includes("top"),r=n?{top:0}:{bottom:0},o=e.includes("center")?{justifyContent:"center"}:e.includes("right")?{justifyContent:"flex-end"}:{};return{left:0,right:0,display:"flex",position:"absolute",transition:ca()?void 0:"all 230ms cubic-bezier(.21,1.02,.73,1)",transform:`translateY(${t*(n?1:-1)}px)`,...r,...o}},Sp=yr`
|
|
195
195
|
z-index: 9999;
|
|
196
196
|
> * {
|
|
197
197
|
pointer-events: auto;
|
|
198
198
|
}
|
|
199
|
-
`,Cr=16,xp=({reverseOrder:e,position:t="top-center",toastOptions:n,gutter:r,children:o,containerStyle:s,containerClassName:i})=>{let{toasts:a,handlers:l}=Yf(n);return d.createElement("div",{style:{position:"fixed",zIndex:9999,top:Cr,left:Cr,right:Cr,bottom:Cr,pointerEvents:"none",...s},className:i,onMouseEnter:l.startPause,onMouseLeave:l.endPause},a.map(u=>{let f=u.position||t,p=l.calculateOffset(u,{reverseOrder:e,gutter:r,defaultPosition:t}),m=wp(f,p);return d.createElement(bp,{id:u.id,key:u.id,onHeightUpdate:l.updateHeight,className:u.visible?_p:"",style:m},u.type==="custom"?br(u.message,u):o?o(u):d.createElement(yp,{toast:u,position:f}))}))},ua=Re,hn=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Vt=typeof window>"u"||"Deno"in globalThis;function we(){}function Cp(e,t){return typeof e=="function"?e(t):e}function Vo(e){return typeof e=="number"&&e>=0&&e!==1/0}function da(e,t){return Math.max(e+(t||0)-Date.now(),0)}function yt(e,t){return typeof e=="function"?e(t):e}function Ne(e,t){return typeof e=="function"?e(t):e}function fa(e,t){const{type:n="all",exact:r,fetchStatus:o,predicate:s,queryKey:i,stale:a}=e;if(i){if(r){if(t.queryHash!==zo(i,t.options))return!1}else if(!Qn(t.queryKey,i))return!1}if(n!=="all"){const l=t.isActive();if(n==="active"&&!l||n==="inactive"&&l)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||o&&o!==t.state.fetchStatus||s&&!s(t))}function pa(e,t){const{exact:n,status:r,predicate:o,mutationKey:s}=e;if(s){if(!t.options.mutationKey)return!1;if(n){if(zt(t.options.mutationKey)!==zt(s))return!1}else if(!Qn(t.options.mutationKey,s))return!1}return!(r&&t.state.status!==r||o&&!o(t))}function zo(e,t){return((t==null?void 0:t.queryKeyHashFn)||zt)(e)}function zt(e){return JSON.stringify(e,(t,n)=>qo(n)?Object.keys(n).sort().reduce((r,o)=>(r[o]=n[o],r),{}):n)}function Qn(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>Qn(e[n],t[n])):!1}function Go(e,t){if(e===t)return e;const n=ha(e)&&ha(t);if(n||qo(e)&&qo(t)){const r=n?e:Object.keys(e),o=r.length,s=n?t:Object.keys(t),i=s.length,a=n?[]:{};let l=0;for(let u=0;u<i;u++){const f=n?u:s[u];(!n&&r.includes(f)||n)&&e[f]===void 0&&t[f]===void 0?(a[f]=void 0,l++):(a[f]=Go(e[f],t[f]),a[f]===e[f]&&e[f]!==void 0&&l++)}return o===i&&l===o?e:a}return t}function Sr(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function ha(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function qo(e){if(!ma(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!ma(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function ma(e){return Object.prototype.toString.call(e)==="[object Object]"}function Sp(e){return new Promise(t=>{setTimeout(t,e)})}function Ko(e,t,n){if(typeof n.structuralSharing=="function")return n.structuralSharing(e,t);if(n.structuralSharing!==!1){try{return Go(e,t)}catch(r){throw console.error(`Structural sharing requires data to be JSON serializable. To fix this, turn off structuralSharing or return JSON-serializable data from your queryFn. [${n.queryHash}]: ${r}`),r}return Go(e,t)}return t}function Ep(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function Tp(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var Er=Symbol();function ga(e,t){return e.queryFn===Er&&console.error(`Attempted to invoke queryFn when set to skipToken. This is likely a configuration error. Query hash: '${e.queryHash}'`),!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Er?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function va(e,t){return typeof e=="function"?e(...t):!!e}var Pp=(Ld=class extends hn{constructor(){super();M(this,nn);M(this,Pt);M(this,An);I(this,An,t=>{if(!Vt&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){x(this,Pt)||this.setEventListener(x(this,An))}onUnsubscribe(){var t;this.hasListeners()||((t=x(this,Pt))==null||t.call(this),I(this,Pt,void 0))}setEventListener(t){var n;I(this,An,t),(n=x(this,Pt))==null||n.call(this),I(this,Pt,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){x(this,nn)!==t&&(I(this,nn,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof x(this,nn)=="boolean"?x(this,nn):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},nn=new WeakMap,Pt=new WeakMap,An=new WeakMap,Ld),Qo=new Pp,Ap=(Dd=class extends hn{constructor(){super();M(this,Rn,!0);M(this,At);M(this,On);I(this,On,t=>{if(!Vt&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){x(this,At)||this.setEventListener(x(this,On))}onUnsubscribe(){var t;this.hasListeners()||((t=x(this,At))==null||t.call(this),I(this,At,void 0))}setEventListener(t){var n;I(this,On,t),(n=x(this,At))==null||n.call(this),I(this,At,t(this.setOnline.bind(this)))}setOnline(t){x(this,Rn)!==t&&(I(this,Rn,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return x(this,Rn)}},Rn=new WeakMap,At=new WeakMap,On=new WeakMap,Dd),Tr=new Ap;function Yo(){let e,t;const n=new Promise((o,s)=>{e=o,t=s});n.status="pending",n.catch(()=>{});function r(o){Object.assign(n,o),delete n.resolve,delete n.reject}return n.resolve=o=>{r({status:"fulfilled",value:o}),e(o)},n.reject=o=>{r({status:"rejected",reason:o}),t(o)},n}function Rp(e){return Math.min(1e3*2**e,3e4)}function ya(e){return(e??"online")==="online"?Tr.isOnline():!0}var ba=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Zo(e){return e instanceof ba}function wa(e){let t=!1,n=0,r=!1,o;const s=Yo(),i=h=>{var v;r||(m(new ba(h)),(v=e.abort)==null||v.call(e))},a=()=>{t=!0},l=()=>{t=!1},u=()=>Qo.isFocused()&&(e.networkMode==="always"||Tr.isOnline())&&e.canRun(),f=()=>ya(e.networkMode)&&e.canRun(),p=h=>{var v;r||(r=!0,(v=e.onSuccess)==null||v.call(e,h),o==null||o(),s.resolve(h))},m=h=>{var v;r||(r=!0,(v=e.onError)==null||v.call(e,h),o==null||o(),s.reject(h))},g=()=>new Promise(h=>{var v;o=b=>{(r||u())&&h(b)},(v=e.onPause)==null||v.call(e)}).then(()=>{var h;o=void 0,r||(h=e.onContinue)==null||h.call(e)}),y=()=>{if(r)return;let h;const v=n===0?e.initialPromise:void 0;try{h=v??e.fn()}catch(b){h=Promise.reject(b)}Promise.resolve(h).then(p).catch(b=>{var A;if(r)return;const _=e.retry??(Vt?0:3),C=e.retryDelay??Rp,T=typeof C=="function"?C(n,b):C,P=_===!0||typeof _=="number"&&n<_||typeof _=="function"&&_(n,b);if(t||!P){m(b);return}n++,(A=e.onFail)==null||A.call(e,n,b),Sp(T).then(()=>u()?void 0:g()).then(()=>{t?m(b):y()})})};return{promise:s,cancel:i,continue:()=>(o==null||o(),s),cancelRetry:a,continueRetry:l,canStart:f,start:()=>(f()?y():g().then(y),s)}}var Op=e=>setTimeout(e,0);function Ip(){let e=[],t=0,n=a=>{a()},r=a=>{a()},o=Op;const s=a=>{t?e.push(a):o(()=>{n(a)})},i=()=>{const a=e;e=[],a.length&&o(()=>{r(()=>{a.forEach(l=>{n(l)})})})};return{batch:a=>{let l;t++;try{l=a()}finally{t--,t||i()}return l},batchCalls:a=>(...l)=>{s(()=>{a(...l)})},schedule:s,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{o=a}}}var me=Ip(),_a=(Nd=class{constructor(){M(this,rn)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Vo(this.gcTime)&&I(this,rn,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Vt?1/0:5*60*1e3))}clearGcTimeout(){x(this,rn)&&(clearTimeout(x(this,rn)),I(this,rn,void 0))}},rn=new WeakMap,Nd),jp=(Md=class extends _a{constructor(t){super();M(this,We);M(this,In);M(this,jn);M(this,je);M(this,on);M(this,be);M(this,cr);M(this,sn);I(this,sn,!1),I(this,cr,t.defaultOptions),this.setOptions(t.options),this.observers=[],I(this,on,t.client),I(this,je,x(this,on).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,I(this,In,kp(this.options)),this.state=t.state??x(this,In),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=x(this,be))==null?void 0:t.promise}setOptions(t){this.options={...x(this,cr),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&x(this,je).remove(this)}setData(t,n){const r=Ko(this.state.data,t,this.options);return V(this,We,mt).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){V(this,We,mt).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,o;const n=(r=x(this,be))==null?void 0:r.promise;return(o=x(this,be))==null||o.cancel(t),n?n.then(we).catch(we):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(x(this,In))}isActive(){return this.observers.some(t=>Ne(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Er||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>yt(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!da(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=x(this,be))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=x(this,be))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),x(this,je).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(x(this,be)&&(x(this,sn)?x(this,be).cancel({revert:!0}):x(this,be).cancelRetry()),this.scheduleGc()),x(this,je).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||V(this,We,mt).call(this,{type:"invalidate"})}fetch(t,n){var u,f,p;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(x(this,be))return x(this,be).continueRetry(),x(this,be).promise}if(t&&this.setOptions(t),!this.options.queryFn){const m=this.observers.find(g=>g.options.queryFn);m&&this.setOptions(m.options)}Array.isArray(this.options.queryKey)||console.error("As of v4, queryKey needs to be an Array. If you are using a string like 'repoData', please change it to an Array, e.g. ['repoData']");const r=new AbortController,o=m=>{Object.defineProperty(m,"signal",{enumerable:!0,get:()=>(I(this,sn,!0),r.signal)})},s=()=>{const m=ga(this.options,n),y=(()=>{const h={client:x(this,on),queryKey:this.queryKey,meta:this.meta};return o(h),h})();return I(this,sn,!1),this.options.persister?this.options.persister(m,y,this):m(y)},a=(()=>{const m={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:x(this,on),state:this.state,fetchFn:s};return o(m),m})();(u=this.options.behavior)==null||u.onFetch(a,this),I(this,jn,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((f=a.fetchOptions)==null?void 0:f.meta))&&V(this,We,mt).call(this,{type:"fetch",meta:(p=a.fetchOptions)==null?void 0:p.meta});const l=m=>{var g,y,h,v;Zo(m)&&m.silent||V(this,We,mt).call(this,{type:"error",error:m}),Zo(m)||((y=(g=x(this,je).config).onError)==null||y.call(g,m,this),(v=(h=x(this,je).config).onSettled)==null||v.call(h,this.state.data,m,this)),this.scheduleGc()};return I(this,be,wa({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,abort:r.abort.bind(r),onSuccess:m=>{var g,y,h,v;if(m===void 0){console.error(`Query data cannot be undefined. Please make sure to return a value other than undefined from your query function. Affected query key: ${this.queryHash}`),l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(m)}catch(b){l(b);return}(y=(g=x(this,je).config).onSuccess)==null||y.call(g,m,this),(v=(h=x(this,je).config).onSettled)==null||v.call(h,m,this.state.error,this),this.scheduleGc()},onError:l,onFail:(m,g)=>{V(this,We,mt).call(this,{type:"failed",failureCount:m,error:g})},onPause:()=>{V(this,We,mt).call(this,{type:"pause"})},onContinue:()=>{V(this,We,mt).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),x(this,be).start()}},In=new WeakMap,jn=new WeakMap,je=new WeakMap,on=new WeakMap,be=new WeakMap,cr=new WeakMap,sn=new WeakMap,We=new WeakSet,mt=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...xa(r.data,this.options),fetchMeta:t.meta??null};case"success":return{...r,data:t.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const o=t.error;return Zo(o)&&o.revert&&x(this,jn)?{...x(this,jn),fetchStatus:"idle"}:{...r,error:o,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:o,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),me.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),x(this,je).notify({query:this,type:"updated",action:t})})},Md);function xa(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:ya(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function kp(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var Lp=($d=class extends hn{constructor(t={}){super();M(this,et);this.config=t,I(this,et,new Map)}build(t,n,r){const o=n.queryKey,s=n.queryHash??zo(o,n);let i=this.get(s);return i||(i=new jp({client:t,queryKey:o,queryHash:s,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(o)}),this.add(i)),i}add(t){x(this,et).has(t.queryHash)||(x(this,et).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=x(this,et).get(t.queryHash);n&&(t.destroy(),n===t&&x(this,et).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){me.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return x(this,et).get(t)}getAll(){return[...x(this,et).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>fa(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>fa(t,r)):n}notify(t){me.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){me.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){me.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},et=new WeakMap,$d),Dp=(Fd=class extends _a{constructor(t){super();M(this,nt);M(this,tt);M(this,_e);M(this,an);this.mutationId=t.mutationId,I(this,_e,t.mutationCache),I(this,tt,[]),this.state=t.state||Ca(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){x(this,tt).includes(t)||(x(this,tt).push(t),this.clearGcTimeout(),x(this,_e).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){I(this,tt,x(this,tt).filter(n=>n!==t)),this.scheduleGc(),x(this,_e).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){x(this,tt).length||(this.state.status==="pending"?this.scheduleGc():x(this,_e).remove(this))}continue(){var t;return((t=x(this,an))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var s,i,a,l,u,f,p,m,g,y,h,v,b,_,C,T,P,A,R,D;const n=()=>{V(this,nt,Ut).call(this,{type:"continue"})};I(this,an,wa({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(k,N)=>{V(this,nt,Ut).call(this,{type:"failed",failureCount:k,error:N})},onPause:()=>{V(this,nt,Ut).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>x(this,_e).canRun(this)}));const r=this.state.status==="pending",o=!x(this,an).canStart();try{if(r)n();else{V(this,nt,Ut).call(this,{type:"pending",variables:t,isPaused:o}),await((i=(s=x(this,_e).config).onMutate)==null?void 0:i.call(s,t,this));const N=await((l=(a=this.options).onMutate)==null?void 0:l.call(a,t));N!==this.state.context&&V(this,nt,Ut).call(this,{type:"pending",context:N,variables:t,isPaused:o})}const k=await x(this,an).start();return await((f=(u=x(this,_e).config).onSuccess)==null?void 0:f.call(u,k,t,this.state.context,this)),await((m=(p=this.options).onSuccess)==null?void 0:m.call(p,k,t,this.state.context)),await((y=(g=x(this,_e).config).onSettled)==null?void 0:y.call(g,k,null,this.state.variables,this.state.context,this)),await((v=(h=this.options).onSettled)==null?void 0:v.call(h,k,null,t,this.state.context)),V(this,nt,Ut).call(this,{type:"success",data:k}),k}catch(k){try{throw await((_=(b=x(this,_e).config).onError)==null?void 0:_.call(b,k,t,this.state.context,this)),await((T=(C=this.options).onError)==null?void 0:T.call(C,k,t,this.state.context)),await((A=(P=x(this,_e).config).onSettled)==null?void 0:A.call(P,void 0,k,this.state.variables,this.state.context,this)),await((D=(R=this.options).onSettled)==null?void 0:D.call(R,void 0,k,t,this.state.context)),k}finally{V(this,nt,Ut).call(this,{type:"error",error:k})}}finally{x(this,_e).runNext(this)}}},tt=new WeakMap,_e=new WeakMap,an=new WeakMap,nt=new WeakSet,Ut=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),me.batch(()=>{x(this,tt).forEach(r=>{r.onMutationUpdate(t)}),x(this,_e).notify({mutation:this,type:"updated",action:t})})},Fd);function Ca(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Np=(Bd=class extends hn{constructor(t={}){super();M(this,dt);M(this,He);M(this,ur);this.config=t,I(this,dt,new Set),I(this,He,new Map),I(this,ur,0)}build(t,n,r){const o=new Dp({mutationCache:this,mutationId:++Ro(this,ur)._,options:t.defaultMutationOptions(n),state:r});return this.add(o),o}add(t){x(this,dt).add(t);const n=Pr(t);if(typeof n=="string"){const r=x(this,He).get(n);r?r.push(t):x(this,He).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(x(this,dt).delete(t)){const n=Pr(t);if(typeof n=="string"){const r=x(this,He).get(n);if(r)if(r.length>1){const o=r.indexOf(t);o!==-1&&r.splice(o,1)}else r[0]===t&&x(this,He).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=Pr(t);if(typeof n=="string"){const r=x(this,He).get(n),o=r==null?void 0:r.find(s=>s.state.status==="pending");return!o||o===t}else return!0}runNext(t){var r;const n=Pr(t);if(typeof n=="string"){const o=(r=x(this,He).get(n))==null?void 0:r.find(s=>s!==t&&s.state.isPaused);return(o==null?void 0:o.continue())??Promise.resolve()}else return Promise.resolve()}clear(){me.batch(()=>{x(this,dt).forEach(t=>{this.notify({type:"removed",mutation:t})}),x(this,dt).clear(),x(this,He).clear()})}getAll(){return Array.from(x(this,dt))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>pa(n,r))}findAll(t={}){return this.getAll().filter(n=>pa(t,n))}notify(t){me.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return me.batch(()=>Promise.all(t.map(n=>n.continue().catch(we))))}},dt=new WeakMap,He=new WeakMap,ur=new WeakMap,Bd);function Pr(e){var t;return(t=e.options.scope)==null?void 0:t.id}function Sa(e){return{onFetch:(t,n)=>{var f,p,m,g,y;const r=t.options,o=(m=(p=(f=t.fetchOptions)==null?void 0:f.meta)==null?void 0:p.fetchMore)==null?void 0:m.direction,s=((g=t.state.data)==null?void 0:g.pages)||[],i=((y=t.state.data)==null?void 0:y.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const u=async()=>{let h=!1;const v=C=>{Object.defineProperty(C,"signal",{enumerable:!0,get:()=>(t.signal.aborted?h=!0:t.signal.addEventListener("abort",()=>{h=!0}),t.signal)})},b=ga(t.options,t.fetchOptions),_=async(C,T,P)=>{if(h)return Promise.reject();if(T==null&&C.pages.length)return Promise.resolve(C);const R=(()=>{const U={client:t.client,queryKey:t.queryKey,pageParam:T,direction:P?"backward":"forward",meta:t.options.meta};return v(U),U})(),D=await b(R),{maxPages:k}=t.options,N=P?Tp:Ep;return{pages:N(C.pages,D,k),pageParams:N(C.pageParams,T,k)}};if(o&&s.length){const C=o==="backward",T=C?Mp:Ea,P={pages:s,pageParams:i},A=T(r,P);a=await _(P,A,C)}else{const C=e??s.length;do{const T=l===0?i[0]??r.initialPageParam:Ea(r,a);if(l>0&&T==null)break;a=await _(a,T),l++}while(l<C)}return a};t.options.persister?t.fetchFn=()=>{var h,v;return(v=(h=t.options).persister)==null?void 0:v.call(h,u,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=u}}}function Ea(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function Mp(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var $p=(Ud=class{constructor(e={}){M(this,ue);M(this,Rt);M(this,Ot);M(this,kn);M(this,Ln);M(this,It);M(this,Dn);M(this,Nn);I(this,ue,e.queryCache||new Lp),I(this,Rt,e.mutationCache||new Np),I(this,Ot,e.defaultOptions||{}),I(this,kn,new Map),I(this,Ln,new Map),I(this,It,0)}mount(){Ro(this,It)._++,x(this,It)===1&&(I(this,Dn,Qo.subscribe(async e=>{e&&(await this.resumePausedMutations(),x(this,ue).onFocus())})),I(this,Nn,Tr.subscribe(async e=>{e&&(await this.resumePausedMutations(),x(this,ue).onOnline())})))}unmount(){var e,t;Ro(this,It)._--,x(this,It)===0&&((e=x(this,Dn))==null||e.call(this),I(this,Dn,void 0),(t=x(this,Nn))==null||t.call(this),I(this,Nn,void 0))}isFetching(e){return x(this,ue).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return x(this,Rt).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=x(this,ue).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=x(this,ue).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(yt(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return x(this,ue).findAll(e).map(({queryKey:t,state:n})=>{const r=n.data;return[t,r]})}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),o=x(this,ue).get(r.queryHash),s=o==null?void 0:o.state.data,i=Cp(t,s);if(i!==void 0)return x(this,ue).build(this,r).setData(i,{...n,manual:!0})}setQueriesData(e,t,n){return me.batch(()=>x(this,ue).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=x(this,ue).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=x(this,ue);me.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=x(this,ue);return me.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=me.batch(()=>x(this,ue).findAll(e).map(o=>o.cancel(n)));return Promise.all(r).then(we).catch(we)}invalidateQueries(e,t={}){return me.batch(()=>(x(this,ue).findAll(e).forEach(n=>{n.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=me.batch(()=>x(this,ue).findAll(e).filter(o=>!o.isDisabled()&&!o.isStatic()).map(o=>{let s=o.fetch(void 0,n);return n.throwOnError||(s=s.catch(we)),o.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(r).then(we)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=x(this,ue).build(this,t);return n.isStaleByTime(yt(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(we).catch(we)}fetchInfiniteQuery(e){return e.behavior=Sa(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(we).catch(we)}ensureInfiniteQueryData(e){return e.behavior=Sa(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Tr.isOnline()?x(this,Rt).resumePausedMutations():Promise.resolve()}getQueryCache(){return x(this,ue)}getMutationCache(){return x(this,Rt)}getDefaultOptions(){return x(this,Ot)}setDefaultOptions(e){I(this,Ot,e)}setQueryDefaults(e,t){x(this,kn).set(zt(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...x(this,kn).values()],n={};return t.forEach(r=>{Qn(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){x(this,Ln).set(zt(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...x(this,Ln).values()],n={};return t.forEach(r=>{Qn(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...x(this,Ot).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=zo(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===Er&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...x(this,Ot).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){x(this,ue).clear(),x(this,Rt).clear()}},ue=new WeakMap,Rt=new WeakMap,Ot=new WeakMap,kn=new WeakMap,Ln=new WeakMap,It=new WeakMap,Dn=new WeakMap,Nn=new WeakMap,Ud),Fp=(Wd=class extends hn{constructor(t,n){super();M(this,ee);M(this,Te);M(this,K);M(this,dr);M(this,xe);M(this,ln);M(this,Mn);M(this,jt);M(this,kt);M(this,fr);M(this,$n);M(this,Fn);M(this,cn);M(this,un);M(this,Lt);M(this,Bn,new Set);this.options=n,I(this,Te,t),I(this,kt,null),I(this,jt,Yo()),this.options.experimental_prefetchInRender||x(this,jt).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(x(this,K).addObserver(this),Ta(x(this,K),this.options)?V(this,ee,pr).call(this):this.updateResult(),V(this,ee,Oi).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Xo(x(this,K),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Xo(x(this,K),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,V(this,ee,Ii).call(this),V(this,ee,ji).call(this),x(this,K).removeObserver(this)}setOptions(t){const n=this.options,r=x(this,K);if(this.options=x(this,Te).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Ne(this.options.enabled,x(this,K))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");V(this,ee,ki).call(this),x(this,K).setOptions(this.options),n._defaulted&&!Sr(this.options,n)&&x(this,Te).getQueryCache().notify({type:"observerOptionsUpdated",query:x(this,K),observer:this});const o=this.hasListeners();o&&Pa(x(this,K),r,this.options,n)&&V(this,ee,pr).call(this),this.updateResult(),o&&(x(this,K)!==r||Ne(this.options.enabled,x(this,K))!==Ne(n.enabled,x(this,K))||yt(this.options.staleTime,x(this,K))!==yt(n.staleTime,x(this,K)))&&V(this,ee,Pi).call(this);const s=V(this,ee,Ai).call(this);o&&(x(this,K)!==r||Ne(this.options.enabled,x(this,K))!==Ne(n.enabled,x(this,K))||s!==x(this,Lt))&&V(this,ee,Ri).call(this,s)}getOptimisticResult(t){const n=x(this,Te).getQueryCache().build(x(this,Te),t),r=this.createResult(n,t);return Up(this,r)&&(I(this,xe,r),I(this,Mn,this.options),I(this,ln,x(this,K).state)),r}getCurrentResult(){return x(this,xe)}trackResult(t,n){return new Proxy(t,{get:(r,o)=>(this.trackProp(o),n==null||n(o),Reflect.get(r,o))})}trackProp(t){x(this,Bn).add(t)}getCurrentQuery(){return x(this,K)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=x(this,Te).defaultQueryOptions(t),r=x(this,Te).getQueryCache().build(x(this,Te),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return V(this,ee,pr).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),x(this,xe)))}createResult(t,n){var k;const r=x(this,K),o=this.options,s=x(this,xe),i=x(this,ln),a=x(this,Mn),u=t!==r?t.state:x(this,dr),{state:f}=t;let p={...f},m=!1,g;if(n._optimisticResults){const N=this.hasListeners(),U=!N&&Ta(t,n),W=N&&Pa(t,r,n,o);(U||W)&&(p={...p,...xa(f.data,t.options)}),n._optimisticResults==="isRestoring"&&(p.fetchStatus="idle")}let{error:y,errorUpdatedAt:h,status:v}=p;g=p.data;let b=!1;if(n.placeholderData!==void 0&&g===void 0&&v==="pending"){let N;s!=null&&s.isPlaceholderData&&n.placeholderData===(a==null?void 0:a.placeholderData)?(N=s.data,b=!0):N=typeof n.placeholderData=="function"?n.placeholderData((k=x(this,Fn))==null?void 0:k.state.data,x(this,Fn)):n.placeholderData,N!==void 0&&(v="success",g=Ko(s==null?void 0:s.data,N,n),m=!0)}if(n.select&&g!==void 0&&!b)if(s&&g===(i==null?void 0:i.data)&&n.select===x(this,fr))g=x(this,$n);else try{I(this,fr,n.select),g=n.select(g),g=Ko(s==null?void 0:s.data,g,n),I(this,$n,g),I(this,kt,null)}catch(N){I(this,kt,N)}x(this,kt)&&(y=x(this,kt),g=x(this,$n),h=Date.now(),v="error");const _=p.fetchStatus==="fetching",C=v==="pending",T=v==="error",P=C&&_,A=g!==void 0,D={status:v,fetchStatus:p.fetchStatus,isPending:C,isSuccess:v==="success",isError:T,isInitialLoading:P,isLoading:P,data:g,dataUpdatedAt:p.dataUpdatedAt,error:y,errorUpdatedAt:h,failureCount:p.fetchFailureCount,failureReason:p.fetchFailureReason,errorUpdateCount:p.errorUpdateCount,isFetched:p.dataUpdateCount>0||p.errorUpdateCount>0,isFetchedAfterMount:p.dataUpdateCount>u.dataUpdateCount||p.errorUpdateCount>u.errorUpdateCount,isFetching:_,isRefetching:_&&!C,isLoadingError:T&&!A,isPaused:p.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:T&&A,isStale:Jo(t,n),refetch:this.refetch,promise:x(this,jt)};if(this.options.experimental_prefetchInRender){const N=H=>{D.status==="error"?H.reject(D.error):D.data!==void 0&&H.resolve(D.data)},U=()=>{const H=I(this,jt,D.promise=Yo());N(H)},W=x(this,jt);switch(W.status){case"pending":t.queryHash===r.queryHash&&N(W);break;case"fulfilled":(D.status==="error"||D.data!==W.value)&&U();break;case"rejected":(D.status!=="error"||D.error!==W.reason)&&U();break}}return D}updateResult(){const t=x(this,xe),n=this.createResult(x(this,K),this.options);if(I(this,ln,x(this,K).state),I(this,Mn,this.options),x(this,ln).data!==void 0&&I(this,Fn,x(this,K)),Sr(n,t))return;I(this,xe,n);const r=()=>{if(!t)return!0;const{notifyOnChangeProps:o}=this.options,s=typeof o=="function"?o():o;if(s==="all"||!s&&!x(this,Bn).size)return!0;const i=new Set(s??x(this,Bn));return this.options.throwOnError&&i.add("error"),Object.keys(x(this,xe)).some(a=>{const l=a;return x(this,xe)[l]!==t[l]&&i.has(l)})};V(this,ee,rf).call(this,{listeners:r()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&V(this,ee,Oi).call(this)}},Te=new WeakMap,K=new WeakMap,dr=new WeakMap,xe=new WeakMap,ln=new WeakMap,Mn=new WeakMap,jt=new WeakMap,kt=new WeakMap,fr=new WeakMap,$n=new WeakMap,Fn=new WeakMap,cn=new WeakMap,un=new WeakMap,Lt=new WeakMap,Bn=new WeakMap,ee=new WeakSet,pr=function(t){V(this,ee,ki).call(this);let n=x(this,K).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(we)),n},Pi=function(){V(this,ee,Ii).call(this);const t=yt(this.options.staleTime,x(this,K));if(Vt||x(this,xe).isStale||!Vo(t))return;const r=da(x(this,xe).dataUpdatedAt,t)+1;I(this,cn,setTimeout(()=>{x(this,xe).isStale||this.updateResult()},r))},Ai=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(x(this,K)):this.options.refetchInterval)??!1},Ri=function(t){V(this,ee,ji).call(this),I(this,Lt,t),!(Vt||Ne(this.options.enabled,x(this,K))===!1||!Vo(x(this,Lt))||x(this,Lt)===0)&&I(this,un,setInterval(()=>{(this.options.refetchIntervalInBackground||Qo.isFocused())&&V(this,ee,pr).call(this)},x(this,Lt)))},Oi=function(){V(this,ee,Pi).call(this),V(this,ee,Ri).call(this,V(this,ee,Ai).call(this))},Ii=function(){x(this,cn)&&(clearTimeout(x(this,cn)),I(this,cn,void 0))},ji=function(){x(this,un)&&(clearInterval(x(this,un)),I(this,un,void 0))},ki=function(){const t=x(this,Te).getQueryCache().build(x(this,Te),this.options);if(t===x(this,K))return;const n=x(this,K);I(this,K,t),I(this,dr,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},rf=function(t){me.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(x(this,xe))}),x(this,Te).getQueryCache().notify({query:x(this,K),type:"observerResultsUpdated"})})},Wd);function Bp(e,t){return Ne(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function Ta(e,t){return Bp(e,t)||e.state.data!==void 0&&Xo(e,t,t.refetchOnMount)}function Xo(e,t,n){if(Ne(t.enabled,e)!==!1&&yt(t.staleTime,e)!=="static"){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&Jo(e,t)}return!1}function Pa(e,t,n,r){return(e!==t||Ne(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&Jo(e,n)}function Jo(e,t){return Ne(t.enabled,e)!==!1&&e.isStaleByTime(yt(t.staleTime,e))}function Up(e,t){return!Sr(e.getCurrentResult(),t)}var Wp=(Hd=class extends hn{constructor(n,r){super();M(this,pt);M(this,Dt);M(this,Nt);M(this,Pe);M(this,ft);I(this,Dt,n),this.setOptions(r),this.bindMethods(),V(this,pt,Oo).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(n){var o;const r=this.options;this.options=x(this,Dt).defaultMutationOptions(n),Sr(this.options,r)||x(this,Dt).getMutationCache().notify({type:"observerOptionsUpdated",mutation:x(this,Pe),observer:this}),r!=null&&r.mutationKey&&this.options.mutationKey&&zt(r.mutationKey)!==zt(this.options.mutationKey)?this.reset():((o=x(this,Pe))==null?void 0:o.state.status)==="pending"&&x(this,Pe).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=x(this,Pe))==null||n.removeObserver(this)}onMutationUpdate(n){V(this,pt,Oo).call(this),V(this,pt,Li).call(this,n)}getCurrentResult(){return x(this,Nt)}reset(){var n;(n=x(this,Pe))==null||n.removeObserver(this),I(this,Pe,void 0),V(this,pt,Oo).call(this),V(this,pt,Li).call(this)}mutate(n,r){var o;return I(this,ft,r),(o=x(this,Pe))==null||o.removeObserver(this),I(this,Pe,x(this,Dt).getMutationCache().build(x(this,Dt),this.options)),x(this,Pe).addObserver(this),x(this,Pe).execute(n)}},Dt=new WeakMap,Nt=new WeakMap,Pe=new WeakMap,ft=new WeakMap,pt=new WeakSet,Oo=function(){var r;const n=((r=x(this,Pe))==null?void 0:r.state)??Ca();I(this,Nt,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},Li=function(n){me.batch(()=>{var r,o,s,i,a,l,u,f;if(x(this,ft)&&this.hasListeners()){const p=x(this,Nt).variables,m=x(this,Nt).context;(n==null?void 0:n.type)==="success"?((o=(r=x(this,ft)).onSuccess)==null||o.call(r,n.data,p,m),(i=(s=x(this,ft)).onSettled)==null||i.call(s,n.data,null,p,m)):(n==null?void 0:n.type)==="error"&&((l=(a=x(this,ft)).onError)==null||l.call(a,n.error,p,m),(f=(u=x(this,ft)).onSettled)==null||f.call(u,void 0,n.error,p,m))}this.listeners.forEach(p=>{p(x(this,Nt))})})},Hd),Aa=d.createContext(void 0),es=e=>{const t=d.useContext(Aa);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Hp=({client:e,children:t})=>(d.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),c.jsx(Aa.Provider,{value:e,children:t})),Ra=d.createContext(!1),Vp=()=>d.useContext(Ra);Ra.Provider;function zp(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var Gp=d.createContext(zp()),qp=()=>d.useContext(Gp),Kp=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},Qp=e=>{d.useEffect(()=>{e.clearReset()},[e])},Yp=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:o})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(o&&e.data===void 0||va(n,[e.error,r])),Zp=e=>{if(e.suspense){const t=r=>r==="static"?r:Math.max(r??1e3,1e3),n=e.staleTime;e.staleTime=typeof n=="function"?(...r)=>t(n(...r)):t(n),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},Xp=(e,t)=>e.isLoading&&e.isFetching&&!t,Jp=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,Oa=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function eh(e,t,n){var p,m,g,y,h;if(typeof e!="object"||Array.isArray(e))throw new Error('Bad argument type. Starting with v5, only the "Object" form is allowed when calling query related functions. Please use the error stack to find the culprit call. More info here: https://tanstack.com/query/latest/docs/react/guides/migrating-to-v5#supports-a-single-signature-one-object');const r=Vp(),o=qp(),s=es(),i=s.defaultQueryOptions(e);(m=(p=s.getDefaultOptions().queries)==null?void 0:p._experimental_beforeQuery)==null||m.call(p,i),i.queryFn||console.error(`[${i.queryHash}]: No queryFn was passed as an option, and no default queryFn was found. The queryFn parameter is only optional when using a default queryFn. More info here: https://tanstack.com/query/latest/docs/framework/react/guides/default-query-function`),i._optimisticResults=r?"isRestoring":"optimistic",Zp(i),Kp(i,o),Qp(o);const a=!s.getQueryCache().get(i.queryHash),[l]=d.useState(()=>new t(s,i)),u=l.getOptimisticResult(i),f=!r&&e.subscribed!==!1;if(d.useSyncExternalStore(d.useCallback(v=>{const b=f?l.subscribe(me.batchCalls(v)):we;return l.updateResult(),b},[l,f]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),d.useEffect(()=>{l.setOptions(i)},[i,l]),Jp(i,u))throw Oa(i,l,o);if(Yp({result:u,errorResetBoundary:o,throwOnError:i.throwOnError,query:s.getQueryCache().get(i.queryHash),suspense:i.suspense}))throw u.error;if((y=(g=s.getDefaultOptions().queries)==null?void 0:g._experimental_afterQuery)==null||y.call(g,i,u),i.experimental_prefetchInRender&&!Vt&&Xp(u,r)){const v=a?Oa(i,l,o):(h=s.getQueryCache().get(i.queryHash))==null?void 0:h.promise;v==null||v.catch(we).finally(()=>{l.updateResult()})}return i.notifyOnChangeProps?u:l.trackResult(u)}function Ia(e,t){return eh(e,Fp)}function Ar(e,t){const n=es(),[r]=d.useState(()=>new Wp(n,e));d.useEffect(()=>{r.setOptions(e)},[r,e]);const o=d.useSyncExternalStore(d.useCallback(i=>r.subscribe(me.batchCalls(i)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),s=d.useCallback((i,a)=>{r.mutate(i,a).catch(we)},[r]);if(o.error&&va(r.options.throwOnError,[o.error]))throw o.error;return{...o,mutate:s,mutateAsync:o.mutate}}const th=e=>{const t=new $p;return function(r){if(!r)throw new Error("Microfrontend did not receive any properties !!");const o=No(r.module.name);return c.jsx(Hi,{module:o,children:c.jsxs(Hp,{client:t,children:[c.jsx(e,{...r}),c.jsx(xp,{position:"top-right",reverseOrder:!0})]})})}};function ja(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=ja(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function L(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=ja(e))&&(r&&(r+=" "),r+=t);return r}const Rr={spinner:"spinner__fakUN","spinner-rotation":"spinner-rotation__wUmPV",spinnerRotation:"spinner-rotation__wUmPV",button:"button__8FA9H","button--contained-primary":"button--contained-primary__stkTx",buttonContainedPrimary:"button--contained-primary__stkTx","button--outlined-primary":"button--outlined-primary__KZ1ww",buttonOutlinedPrimary:"button--outlined-primary__KZ1ww","button--text-primary":"button--text-primary__GLTfm",buttonTextPrimary:"button--text-primary__GLTfm","button--contained-danger":"button--contained-danger__L9ehT",buttonContainedDanger:"button--contained-danger__L9ehT","button--outlined-danger":"button--outlined-danger__eoYLd",buttonOutlinedDanger:"button--outlined-danger__eoYLd","button--text-danger":"button--text-danger__Sw-ha",buttonTextDanger:"button--text-danger__Sw-ha",icon:"icon__--umH"},Or=S.forwardRef(({variant:e="contained",colorScheme:t="primary",loading:n=!1,IconComponent:r,className:o,children:s,...i},a)=>{const l=L(Rr.button,Rr[`button--${e}-${t}`],o);return c.jsxs("button",{ref:a,className:l,...i,children:[n?c.jsx("div",{className:Rr.spinner}):r&&c.jsx(r,{className:Rr.icon}),s]})});Or.displayName="Button";const Ir={Badges:"Badges__5jpum",badges:"Badges__5jpum",Badge:"Badge__95MWM",badge:"Badge__95MWM","Badge--primary":"Badge--primary__Rx-bS",badgePrimary:"Badge--primary__Rx-bS","Badge--secondary":"Badge--secondary__d92bT",badgeSecondary:"Badge--secondary__d92bT","Badge--success":"Badge--success__Kdo98",badgeSuccess:"Badge--success__Kdo98","Badge--warning":"Badge--warning__bf-Nn",badgeWarning:"Badge--warning__bf-Nn","Badge--danger":"Badge--danger__HTj39",badgeDanger:"Badge--danger__HTj39","Badge--small":"Badge--small__y93Pj",badgeSmall:"Badge--small__y93Pj","Badge--regular":"Badge--regular__aT5AL",badgeRegular:"Badge--regular__aT5AL","Badge--large":"Badge--large__wORCH",badgeLarge:"Badge--large__wORCH"},ts={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};for(const e in ts)Object.freeze(ts[e]);const ka=Object.freeze(ts);var La={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};function nh(e){var f,p;var t,n=[],r=1,o;if(typeof e=="number")return{space:"rgb",values:[e>>>16,(e&65280)>>>8,e&255],alpha:1};if(typeof e=="number")return{space:"rgb",values:[e>>>16,(e&65280)>>>8,e&255],alpha:1};if(e=String(e).toLowerCase(),ka[e])n=ka[e].slice(),o="rgb";else if(e==="transparent")r=0,o="rgb",n=[0,0,0];else if(e[0]==="#"){var s=e.slice(1),i=s.length,a=i<=4;r=1,a?(n=[parseInt(s[0]+s[0],16),parseInt(s[1]+s[1],16),parseInt(s[2]+s[2],16)],i===4&&(r=parseInt(s[3]+s[3],16)/255)):(n=[parseInt(s[0]+s[1],16),parseInt(s[2]+s[3],16),parseInt(s[4]+s[5],16)],i===8&&(r=parseInt(s[6]+s[7],16)/255)),n[0]||(n[0]=0),n[1]||(n[1]=0),n[2]||(n[2]=0),o="rgb"}else if(t=/^((?:rgba?|hs[lvb]a?|hwba?|cmyk?|xy[zy]|gray|lab|lchu?v?|[ly]uv|lms|oklch|oklab|color))\s*\(([^\)]*)\)/.exec(e)){var l=t[1];o=l.replace(/a$/,"");var u=o==="cmyk"?4:o==="gray"?1:3;n=t[2].trim().split(/\s*[,\/]\s*|\s+/),o==="color"&&(o=n.shift()),n=n.map(function(m,g){if(m[m.length-1]==="%")return m=parseFloat(m)/100,g===3?m:o==="rgb"?m*255:o[0]==="h"||o[0]==="l"&&!g?m*100:o==="lab"?m*125:o==="lch"?g<2?m*150:m*360:o[0]==="o"&&!g?m:o==="oklab"?m*.4:o==="oklch"?g<2?m*.4:m*360:m;if(o[g]==="h"||g===2&&o[o.length-1]==="h"){if(La[m]!==void 0)return La[m];if(m.endsWith("deg"))return parseFloat(m);if(m.endsWith("turn"))return parseFloat(m)*360;if(m.endsWith("grad"))return parseFloat(m)*360/400;if(m.endsWith("rad"))return parseFloat(m)*180/Math.PI}return m==="none"?0:parseFloat(m)}),r=n.length>u?n.pop():1}else/[0-9](?:\s|\/|,)/.test(e)&&(n=e.match(/([0-9]+)/g).map(function(m){return parseFloat(m)}),o=((p=(f=e.match(/([a-z])/ig))==null?void 0:f.join(""))==null?void 0:p.toLowerCase())||"rgb");return{space:o,values:n,alpha:r}}const rh=(e,t)=>{const{space:n,values:r}=nh(e);return n[0]==="h"?`${n}a(${r[0]}, ${r[1]}%, ${r[2]}%, ${t})`:`${n}a(${r}, ${t})`},ns=S.forwardRef(({children:e,color:t,className:n,customColor:r,size:o="small",style:s,...i},a)=>{const l=r?{color:r,background:rh(r,.1)}:{},u=L(Ir.Badge,Ir[`Badge--${o}`],{[Ir[`Badge--${t}`]]:!!t},n);return c.jsx("span",{ref:a,className:u,style:{...s,...l},...i,children:e})});ns.displayName="Badge";const rs=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ir.Badges,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});rs.displayName="Badges";const Da=({size:e=24,color:t="currentColor",strokeWidth:n=2,className:r,style:o,...s})=>c.jsxs("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"none",stroke:t,strokeWidth:n,strokeLinecap:"round",strokeLinejoin:"round",className:r,style:o,...s,children:[c.jsx("rect",{x:"8",y:"2",width:"8",height:"4",rx:"1",ry:"1"}),c.jsx("path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2"})]}),Na=({size:e=24,color:t="currentColor",strokeWidth:n=2,className:r,style:o,...s})=>c.jsxs("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"none",stroke:t,strokeWidth:n,strokeLinecap:"round",strokeLinejoin:"round",className:r,style:o,...s,children:[c.jsx("rect",{x:"8",y:"2",width:"8",height:"4",rx:"1",ry:"1"}),c.jsx("path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2"}),c.jsx("path",{d:"m9 12 2 2 4-4"})]}),oh={CopyToClipboardButton:"CopyToClipboardButton__2Nd2m"},sh=({content:e})=>{const[t,n]=ih(),{notify:r}=fi(),o=t?Na:Da,s=S.useCallback(async()=>{await n(e)&&r("Copied to the Clipboard !","success")},[e,r]);return c.jsx(o,{className:oh.CopyToClipboardButton,size:18,onClick:s})},ih=()=>{const[e,t]=S.useState(!1);return[e,async r=>{var o;try{return await((o=navigator==null?void 0:navigator.clipboard)==null?void 0:o.writeText(r)),t(!0),setTimeout(()=>t(!1),2e3),!0}catch(s){return console.error("Failed to copy text: ",s),!1}}]},Ma={FieldGroup:"FieldGroup__Q2JCV",fieldGroup:"FieldGroup__Q2JCV","FieldGroup--horizontal":"FieldGroup--horizontal__kpfL1",fieldGroupHorizontal:"FieldGroup--horizontal__kpfL1","FieldGroup--vertical":"FieldGroup--vertical__FLo-Q",fieldGroupVertical:"FieldGroup--vertical__FLo-Q"},$a=S.forwardRef(({children:e,className:t,orientation:n="vertical",...r},o)=>{const s=L(Ma.FieldGroup,Ma[`FieldGroup--${n}`],t);return c.jsx("div",{ref:o,className:s,...r,children:e})});$a.displayName="FieldGroup";const Fa={Input:"Input__uS0sb",Error:"Error__-DQpw"},jr=S.forwardRef(({className:e,error:t,...n},r)=>{const o=L(Fa.Input,t&&Fa.Error,e);return c.jsx("input",{ref:r,className:o,...n})});jr.displayName="Input";const ah={Error:"Error__N4OP5"},Ba=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(ah.Error,t);return c.jsx("span",{ref:r,className:o,...n,children:e})});Ba.displayName="InputError";const Ua={Label:"Label__VYUvW",Error:"Error__Eu6DI"},Wa=S.forwardRef(({children:e,className:t,error:n,...r},o)=>{const s=L(Ua.Label,n&&Ua.Error,t);return c.jsx("label",{ref:o,className:s,...r,children:e})});Wa.displayName="Label";const os={Select:"Select__giqpe",Chevron:"Chevron__YvhBd"},Ha=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(os.Option,t);return c.jsx("option",{ref:r,className:o,...n,children:e})});Ha.displayName="Option";const ss=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(os.Select,t);return c.jsxs("div",{className:o,children:[c.jsx("select",{ref:r,...n,children:e}),c.jsx("div",{className:os.Chevron,children:c.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M4 6L8 10L12 6",stroke:"#818181",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})})})]})});ss.displayName="Select",ss.Option=Ha;function Va(e,[t,n]){return Math.min(n,Math.max(t,e))}function Z(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function lh(e,t){const n=d.createContext(t),r=s=>{const{children:i,...a}=s,l=d.useMemo(()=>a,Object.values(a));return c.jsx(n.Provider,{value:l,children:i})};r.displayName=e+"Provider";function o(s){const i=d.useContext(n);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[r,o]}function Yn(e,t=[]){let n=[];function r(s,i){const a=d.createContext(i),l=n.length;n=[...n,i];const u=p=>{var b;const{scope:m,children:g,...y}=p,h=((b=m==null?void 0:m[e])==null?void 0:b[l])||a,v=d.useMemo(()=>y,Object.values(y));return c.jsx(h.Provider,{value:v,children:g})};u.displayName=s+"Provider";function f(p,m){var h;const g=((h=m==null?void 0:m[e])==null?void 0:h[l])||a,y=d.useContext(g);if(y)return y;if(i!==void 0)return i;throw new Error(`\`${p}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(i=>d.createContext(i));return function(a){const l=(a==null?void 0:a[e])||s;return d.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return o.scopeName=e,[r,ch(o,...t)]}function ch(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const i=r.reduce((a,{useScope:l,scopeName:u})=>{const p=l(s)[`__scope${u}`];return{...a,...p}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function za(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function mn(...e){return t=>{let n=!1;const r=e.map(o=>{const s=za(o,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let o=0;o<r.length;o++){const s=r[o];typeof s=="function"?s():za(e[o],null)}}}}function le(...e){return d.useCallback(mn(...e),e)}function Ga(e){const t=uh(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),l=a.find(fh);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function uh(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=hh(o),a=ph(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var dh=Symbol("radix.slottable");function fh(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===dh}function ph(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function hh(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function mh(e){const t=e+"CollectionProvider",[n,r]=Yn(t),[o,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=h=>{const{scope:v,children:b}=h,_=S.useRef(null),C=S.useRef(new Map).current;return c.jsx(o,{scope:v,itemMap:C,collectionRef:_,children:b})};i.displayName=t;const a=e+"CollectionSlot",l=Ga(a),u=S.forwardRef((h,v)=>{const{scope:b,children:_}=h,C=s(a,b),T=le(v,C.collectionRef);return c.jsx(l,{ref:T,children:_})});u.displayName=a;const f=e+"CollectionItemSlot",p="data-radix-collection-item",m=Ga(f),g=S.forwardRef((h,v)=>{const{scope:b,children:_,...C}=h,T=S.useRef(null),P=le(v,T),A=s(f,b);return S.useEffect(()=>(A.itemMap.set(T,{ref:T,...C}),()=>void A.itemMap.delete(T))),c.jsx(m,{[p]:"",ref:P,children:_})});g.displayName=f;function y(h){const v=s(e+"CollectionConsumer",h);return S.useCallback(()=>{const _=v.collectionRef.current;if(!_)return[];const C=Array.from(_.querySelectorAll(`[${p}]`));return Array.from(v.itemMap.values()).sort((A,R)=>C.indexOf(A.ref.current)-C.indexOf(R.ref.current))},[v.collectionRef,v.itemMap])}return[{Provider:i,Slot:u,ItemSlot:g},y,r]}var gh=d.createContext(void 0);function vh(e){const t=d.useContext(gh);return e||t||"ltr"}function yh(e){const t=bh(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),l=a.find(_h);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function bh(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=Ch(o),a=xh(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var wh=Symbol("radix.slottable");function _h(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===wh}function xh(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Ch(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Sh=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ie=Sh.reduce((e,t)=>{const n=yh(`Primitive.${t}`),r=d.forwardRef((o,s)=>{const{asChild:i,...a}=o,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),c.jsx(l,{...a,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Eh(e,t){e&&mr.flushSync(()=>e.dispatchEvent(t))}function Gt(e){const t=d.useRef(e);return d.useEffect(()=>{t.current=e}),d.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function Th(e,t=globalThis==null?void 0:globalThis.document){const n=Gt(e);d.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var Ph="DismissableLayer",is="dismissableLayer.update",Ah="dismissableLayer.pointerDownOutside",Rh="dismissableLayer.focusOutside",qa,Ka=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),kr=d.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:i,onDismiss:a,...l}=e,u=d.useContext(Ka),[f,p]=d.useState(null),m=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,g]=d.useState({}),y=le(t,R=>p(R)),h=Array.from(u.layers),[v]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),b=h.indexOf(v),_=f?h.indexOf(f):-1,C=u.layersWithOutsidePointerEventsDisabled.size>0,T=_>=b,P=jh(R=>{const D=R.target,k=[...u.branches].some(N=>N.contains(D));!T||k||(o==null||o(R),i==null||i(R),R.defaultPrevented||a==null||a())},m),A=kh(R=>{const D=R.target;[...u.branches].some(N=>N.contains(D))||(s==null||s(R),i==null||i(R),R.defaultPrevented||a==null||a())},m);return Th(R=>{_===u.layers.size-1&&(r==null||r(R),!R.defaultPrevented&&a&&(R.preventDefault(),a()))},m),d.useEffect(()=>{if(f)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(qa=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(f)),u.layers.add(f),Qa(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=qa)}},[f,m,n,u]),d.useEffect(()=>()=>{f&&(u.layers.delete(f),u.layersWithOutsidePointerEventsDisabled.delete(f),Qa())},[f,u]),d.useEffect(()=>{const R=()=>g({});return document.addEventListener(is,R),()=>document.removeEventListener(is,R)},[]),c.jsx(ie.div,{...l,ref:y,style:{pointerEvents:C?T?"auto":"none":void 0,...e.style},onFocusCapture:Z(e.onFocusCapture,A.onFocusCapture),onBlurCapture:Z(e.onBlurCapture,A.onBlurCapture),onPointerDownCapture:Z(e.onPointerDownCapture,P.onPointerDownCapture)})});kr.displayName=Ph;var Oh="DismissableLayerBranch",Ih=d.forwardRef((e,t)=>{const n=d.useContext(Ka),r=d.useRef(null),o=le(t,r);return d.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),c.jsx(ie.div,{...e,ref:o})});Ih.displayName=Oh;function jh(e,t=globalThis==null?void 0:globalThis.document){const n=Gt(e),r=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const s=a=>{if(a.target&&!r.current){let l=function(){Ya(Ah,n,u,{discrete:!0})};const u={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=l,t.addEventListener("click",o.current,{once:!0})):l()}else t.removeEventListener("click",o.current);r.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",s),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function kh(e,t=globalThis==null?void 0:globalThis.document){const n=Gt(e),r=d.useRef(!1);return d.useEffect(()=>{const o=s=>{s.target&&!r.current&&Ya(Rh,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Qa(){const e=new CustomEvent(is);document.dispatchEvent(e)}function Ya(e,t,n,{discrete:r}){const o=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Eh(o,s):o.dispatchEvent(s)}var as=0;function Za(){d.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Xa()),document.body.insertAdjacentElement("beforeend",e[1]??Xa()),as++,()=>{as===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),as--}},[])}function Xa(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var ls="focusScope.autoFocusOnMount",cs="focusScope.autoFocusOnUnmount",Ja={bubbles:!1,cancelable:!0},Lh="FocusScope",us=d.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...i}=e,[a,l]=d.useState(null),u=Gt(o),f=Gt(s),p=d.useRef(null),m=le(t,h=>l(h)),g=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let h=function(C){if(g.paused||!a)return;const T=C.target;a.contains(T)?p.current=T:bt(p.current,{select:!0})},v=function(C){if(g.paused||!a)return;const T=C.relatedTarget;T!==null&&(a.contains(T)||bt(p.current,{select:!0}))},b=function(C){if(document.activeElement===document.body)for(const P of C)P.removedNodes.length>0&&bt(a)};document.addEventListener("focusin",h),document.addEventListener("focusout",v);const _=new MutationObserver(b);return a&&_.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",h),document.removeEventListener("focusout",v),_.disconnect()}}},[r,a,g.paused]),d.useEffect(()=>{if(a){nl.add(g);const h=document.activeElement;if(!a.contains(h)){const b=new CustomEvent(ls,Ja);a.addEventListener(ls,u),a.dispatchEvent(b),b.defaultPrevented||(Dh(Bh(el(a)),{select:!0}),document.activeElement===h&&bt(a))}return()=>{a.removeEventListener(ls,u),setTimeout(()=>{const b=new CustomEvent(cs,Ja);a.addEventListener(cs,f),a.dispatchEvent(b),b.defaultPrevented||bt(h??document.body,{select:!0}),a.removeEventListener(cs,f),nl.remove(g)},0)}}},[a,u,f,g]);const y=d.useCallback(h=>{if(!n&&!r||g.paused)return;const v=h.key==="Tab"&&!h.altKey&&!h.ctrlKey&&!h.metaKey,b=document.activeElement;if(v&&b){const _=h.currentTarget,[C,T]=Nh(_);C&&T?!h.shiftKey&&b===T?(h.preventDefault(),n&&bt(C,{select:!0})):h.shiftKey&&b===C&&(h.preventDefault(),n&&bt(T,{select:!0})):b===_&&h.preventDefault()}},[n,r,g.paused]);return c.jsx(ie.div,{tabIndex:-1,...i,ref:m,onKeyDown:y})});us.displayName=Lh;function Dh(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(bt(r,{select:t}),document.activeElement!==n)return}function Nh(e){const t=el(e),n=tl(t,e),r=tl(t.reverse(),e);return[n,r]}function el(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function tl(e,t){for(const n of e)if(!Mh(n,{upTo:t}))return n}function Mh(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function $h(e){return e instanceof HTMLInputElement&&"select"in e}function bt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&$h(e)&&t&&e.select()}}var nl=Fh();function Fh(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=rl(e,t),e.unshift(t)},remove(t){var n;e=rl(e,t),(n=e[0])==null||n.resume()}}}function rl(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Bh(e){return e.filter(t=>t.tagName!=="A")}var ve=globalThis!=null&&globalThis.document?d.useLayoutEffect:()=>{},Uh=d[" useId ".trim().toString()]||(()=>{}),Wh=0;function qt(e){const[t,n]=d.useState(Uh());return ve(()=>{n(r=>r??String(Wh++))},[e]),e||(t?`radix-${t}`:"")}const Hh=["top","right","bottom","left"],wt=Math.min,Oe=Math.max,Lr=Math.round,Dr=Math.floor,Ge=e=>({x:e,y:e}),Vh={left:"right",right:"left",bottom:"top",top:"bottom"},zh={start:"end",end:"start"};function ds(e,t,n){return Oe(e,wt(t,n))}function at(e,t){return typeof e=="function"?e(t):e}function lt(e){return e.split("-")[0]}function gn(e){return e.split("-")[1]}function fs(e){return e==="x"?"y":"x"}function ps(e){return e==="y"?"height":"width"}const Gh=new Set(["top","bottom"]);function qe(e){return Gh.has(lt(e))?"y":"x"}function hs(e){return fs(qe(e))}function qh(e,t,n){n===void 0&&(n=!1);const r=gn(e),o=hs(e),s=ps(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Nr(i)),[i,Nr(i)]}function Kh(e){const t=Nr(e);return[ms(e),t,ms(t)]}function ms(e){return e.replace(/start|end/g,t=>zh[t])}const ol=["left","right"],sl=["right","left"],Qh=["top","bottom"],Yh=["bottom","top"];function Zh(e,t,n){switch(e){case"top":case"bottom":return n?t?sl:ol:t?ol:sl;case"left":case"right":return t?Qh:Yh;default:return[]}}function Xh(e,t,n,r){const o=gn(e);let s=Zh(lt(e),n==="start",r);return o&&(s=s.map(i=>i+"-"+o),t&&(s=s.concat(s.map(ms)))),s}function Nr(e){return e.replace(/left|right|bottom|top/g,t=>Vh[t])}function Jh(e){return{top:0,right:0,bottom:0,left:0,...e}}function il(e){return typeof e!="number"?Jh(e):{top:e,right:e,bottom:e,left:e}}function Mr(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function al(e,t,n){let{reference:r,floating:o}=e;const s=qe(t),i=hs(t),a=ps(i),l=lt(t),u=s==="y",f=r.x+r.width/2-o.width/2,p=r.y+r.height/2-o.height/2,m=r[a]/2-o[a]/2;let g;switch(l){case"top":g={x:f,y:r.y-o.height};break;case"bottom":g={x:f,y:r.y+r.height};break;case"right":g={x:r.x+r.width,y:p};break;case"left":g={x:r.x-o.width,y:p};break;default:g={x:r.x,y:r.y}}switch(gn(t)){case"start":g[i]-=m*(n&&u?-1:1);break;case"end":g[i]+=m*(n&&u?-1:1);break}return g}async function em(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:s,rects:i,elements:a,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:f="viewport",elementContext:p="floating",altBoundary:m=!1,padding:g=0}=at(t,e),y=il(g),v=a[m?p==="floating"?"reference":"floating":p],b=Mr(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(v)))==null||n?v:v.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:u,rootBoundary:f,strategy:l})),_=p==="floating"?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,C=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),T=await(s.isElement==null?void 0:s.isElement(C))?await(s.getScale==null?void 0:s.getScale(C))||{x:1,y:1}:{x:1,y:1},P=Mr(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:_,offsetParent:C,strategy:l}):_);return{top:(b.top-P.top+y.top)/T.y,bottom:(P.bottom-b.bottom+y.bottom)/T.y,left:(b.left-P.left+y.left)/T.x,right:(P.right-b.right+y.right)/T.x}}const tm=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:i}=n,a=s.filter(Boolean),l=await(i.isRTL==null?void 0:i.isRTL(t));let u=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:p}=al(u,r,l),m=r,g={},y=0;for(let v=0;v<a.length;v++){var h;const{name:b,fn:_}=a[v],{x:C,y:T,data:P,reset:A}=await _({x:f,y:p,initialPlacement:r,placement:m,strategy:o,middlewareData:g,rects:u,platform:{...i,detectOverflow:(h=i.detectOverflow)!=null?h:em},elements:{reference:e,floating:t}});f=C??f,p=T??p,g={...g,[b]:{...g[b],...P}},A&&y<=50&&(y++,typeof A=="object"&&(A.placement&&(m=A.placement),A.rects&&(u=A.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):A.rects),{x:f,y:p}=al(u,m,l)),v=-1)}return{x:f,y:p,placement:m,strategy:o,middlewareData:g}},nm=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:i,elements:a,middlewareData:l}=t,{element:u,padding:f=0}=at(e,t)||{};if(u==null)return{};const p=il(f),m={x:n,y:r},g=hs(o),y=ps(g),h=await i.getDimensions(u),v=g==="y",b=v?"top":"left",_=v?"bottom":"right",C=v?"clientHeight":"clientWidth",T=s.reference[y]+s.reference[g]-m[g]-s.floating[y],P=m[g]-s.reference[g],A=await(i.getOffsetParent==null?void 0:i.getOffsetParent(u));let R=A?A[C]:0;(!R||!await(i.isElement==null?void 0:i.isElement(A)))&&(R=a.floating[C]||s.floating[y]);const D=T/2-P/2,k=R/2-h[y]/2-1,N=wt(p[b],k),U=wt(p[_],k),W=N,H=R-h[y]-U,z=R/2-h[y]/2+D,oe=ds(W,z,H),G=!l.arrow&&gn(o)!=null&&z!==oe&&s.reference[y]/2-(z<W?N:U)-h[y]/2<0,Y=G?z<W?z-W:z-H:0;return{[g]:m[g]+Y,data:{[g]:oe,centerOffset:z-oe-Y,...G&&{alignmentOffset:Y}},reset:G}}}),rm=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:s,rects:i,initialPlacement:a,platform:l,elements:u}=t,{mainAxis:f=!0,crossAxis:p=!0,fallbackPlacements:m,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:h=!0,...v}=at(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const b=lt(o),_=qe(a),C=lt(a)===a,T=await(l.isRTL==null?void 0:l.isRTL(u.floating)),P=m||(C||!h?[Nr(a)]:Kh(a)),A=y!=="none";!m&&A&&P.push(...Xh(a,h,y,T));const R=[a,...P],D=await l.detectOverflow(t,v),k=[];let N=((r=s.flip)==null?void 0:r.overflows)||[];if(f&&k.push(D[b]),p){const z=qh(o,i,T);k.push(D[z[0]],D[z[1]])}if(N=[...N,{placement:o,overflows:k}],!k.every(z=>z<=0)){var U,W;const z=(((U=s.flip)==null?void 0:U.index)||0)+1,oe=R[z];if(oe&&(!(p==="alignment"?_!==qe(oe):!1)||N.every(F=>qe(F.placement)===_?F.overflows[0]>0:!0)))return{data:{index:z,overflows:N},reset:{placement:oe}};let G=(W=N.filter(Y=>Y.overflows[0]<=0).sort((Y,F)=>Y.overflows[1]-F.overflows[1])[0])==null?void 0:W.placement;if(!G)switch(g){case"bestFit":{var H;const Y=(H=N.filter(F=>{if(A){const se=qe(F.placement);return se===_||se==="y"}return!0}).map(F=>[F.placement,F.overflows.filter(se=>se>0).reduce((se,ge)=>se+ge,0)]).sort((F,se)=>F[1]-se[1])[0])==null?void 0:H[0];Y&&(G=Y);break}case"initialPlacement":G=a;break}if(o!==G)return{reset:{placement:G}}}return{}}}};function ll(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function cl(e){return Hh.some(t=>e[t]>=0)}const om=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n,platform:r}=t,{strategy:o="referenceHidden",...s}=at(e,t);switch(o){case"referenceHidden":{const i=await r.detectOverflow(t,{...s,elementContext:"reference"}),a=ll(i,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:cl(a)}}}case"escaped":{const i=await r.detectOverflow(t,{...s,altBoundary:!0}),a=ll(i,n.floating);return{data:{escapedOffsets:a,escaped:cl(a)}}}default:return{}}}}},ul=new Set(["left","top"]);async function sm(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=lt(n),a=gn(n),l=qe(n)==="y",u=ul.has(i)?-1:1,f=s&&l?-1:1,p=at(t,e);let{mainAxis:m,crossAxis:g,alignmentAxis:y}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return a&&typeof y=="number"&&(g=a==="end"?y*-1:y),l?{x:g*f,y:m*u}:{x:m*u,y:g*f}}const im=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:s,placement:i,middlewareData:a}=t,l=await sm(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:o+l.x,y:s+l.y,data:{...l,placement:i}}}}},am=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o,platform:s}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:l={fn:b=>{let{x:_,y:C}=b;return{x:_,y:C}}},...u}=at(e,t),f={x:n,y:r},p=await s.detectOverflow(t,u),m=qe(lt(o)),g=fs(m);let y=f[g],h=f[m];if(i){const b=g==="y"?"top":"left",_=g==="y"?"bottom":"right",C=y+p[b],T=y-p[_];y=ds(C,y,T)}if(a){const b=m==="y"?"top":"left",_=m==="y"?"bottom":"right",C=h+p[b],T=h-p[_];h=ds(C,h,T)}const v=l.fn({...t,[g]:y,[m]:h});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[g]:i,[m]:a}}}}}},lm=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:s,middlewareData:i}=t,{offset:a=0,mainAxis:l=!0,crossAxis:u=!0}=at(e,t),f={x:n,y:r},p=qe(o),m=fs(p);let g=f[m],y=f[p];const h=at(a,t),v=typeof h=="number"?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(l){const C=m==="y"?"height":"width",T=s.reference[m]-s.floating[C]+v.mainAxis,P=s.reference[m]+s.reference[C]-v.mainAxis;g<T?g=T:g>P&&(g=P)}if(u){var b,_;const C=m==="y"?"width":"height",T=ul.has(lt(o)),P=s.reference[p]-s.floating[C]+(T&&((b=i.offset)==null?void 0:b[p])||0)+(T?0:v.crossAxis),A=s.reference[p]+s.reference[C]+(T?0:((_=i.offset)==null?void 0:_[p])||0)-(T?v.crossAxis:0);y<P?y=P:y>A&&(y=A)}return{[m]:g,[p]:y}}}},cm=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:s,platform:i,elements:a}=t,{apply:l=()=>{},...u}=at(e,t),f=await i.detectOverflow(t,u),p=lt(o),m=gn(o),g=qe(o)==="y",{width:y,height:h}=s.floating;let v,b;p==="top"||p==="bottom"?(v=p,b=m===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(b=p,v=m==="end"?"top":"bottom");const _=h-f.top-f.bottom,C=y-f.left-f.right,T=wt(h-f[v],_),P=wt(y-f[b],C),A=!t.middlewareData.shift;let R=T,D=P;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=C),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(R=_),A&&!m){const N=Oe(f.left,0),U=Oe(f.right,0),W=Oe(f.top,0),H=Oe(f.bottom,0);g?D=y-2*(N!==0||U!==0?N+U:Oe(f.left,f.right)):R=h-2*(W!==0||H!==0?W+H:Oe(f.top,f.bottom))}await l({...t,availableWidth:D,availableHeight:R});const k=await i.getDimensions(a.floating);return y!==k.width||h!==k.height?{reset:{rects:!0}}:{}}}};function $r(){return typeof window<"u"}function vn(e){return dl(e)?(e.nodeName||"").toLowerCase():"#document"}function Ie(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ke(e){var t;return(t=(dl(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function dl(e){return $r()?e instanceof Node||e instanceof Ie(e).Node:!1}function Me(e){return $r()?e instanceof Element||e instanceof Ie(e).Element:!1}function Qe(e){return $r()?e instanceof HTMLElement||e instanceof Ie(e).HTMLElement:!1}function fl(e){return!$r()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ie(e).ShadowRoot}const um=new Set(["inline","contents"]);function Zn(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=$e(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!um.has(o)}const dm=new Set(["table","td","th"]);function fm(e){return dm.has(vn(e))}const pm=[":popover-open",":modal"];function Fr(e){return pm.some(t=>{try{return e.matches(t)}catch{return!1}})}const hm=["transform","translate","scale","rotate","perspective"],mm=["transform","translate","scale","rotate","perspective","filter"],gm=["paint","layout","strict","content"];function gs(e){const t=vs(),n=Me(e)?$e(e):e;return hm.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||mm.some(r=>(n.willChange||"").includes(r))||gm.some(r=>(n.contain||"").includes(r))}function vm(e){let t=_t(e);for(;Qe(t)&&!yn(t);){if(gs(t))return t;if(Fr(t))return null;t=_t(t)}return null}function vs(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const ym=new Set(["html","body","#document"]);function yn(e){return ym.has(vn(e))}function $e(e){return Ie(e).getComputedStyle(e)}function Br(e){return Me(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function _t(e){if(vn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||fl(e)&&e.host||Ke(e);return fl(t)?t.host:t}function pl(e){const t=_t(e);return yn(t)?e.ownerDocument?e.ownerDocument.body:e.body:Qe(t)&&Zn(t)?t:pl(t)}function Xn(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=pl(e),s=o===((r=e.ownerDocument)==null?void 0:r.body),i=Ie(o);if(s){const a=ys(i);return t.concat(i,i.visualViewport||[],Zn(o)?o:[],a&&n?Xn(a):[])}return t.concat(o,Xn(o,[],n))}function ys(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function hl(e){const t=$e(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Qe(e),s=o?e.offsetWidth:n,i=o?e.offsetHeight:r,a=Lr(n)!==s||Lr(r)!==i;return a&&(n=s,r=i),{width:n,height:r,$:a}}function bs(e){return Me(e)?e:e.contextElement}function bn(e){const t=bs(e);if(!Qe(t))return Ge(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=hl(t);let i=(s?Lr(n.width):n.width)/r,a=(s?Lr(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const bm=Ge(0);function ml(e){const t=Ie(e);return!vs()||!t.visualViewport?bm:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function wm(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ie(e)?!1:t}function Kt(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=bs(e);let i=Ge(1);t&&(r?Me(r)&&(i=bn(r)):i=bn(e));const a=wm(s,n,r)?ml(s):Ge(0);let l=(o.left+a.x)/i.x,u=(o.top+a.y)/i.y,f=o.width/i.x,p=o.height/i.y;if(s){const m=Ie(s),g=r&&Me(r)?Ie(r):r;let y=m,h=ys(y);for(;h&&r&&g!==y;){const v=bn(h),b=h.getBoundingClientRect(),_=$e(h),C=b.left+(h.clientLeft+parseFloat(_.paddingLeft))*v.x,T=b.top+(h.clientTop+parseFloat(_.paddingTop))*v.y;l*=v.x,u*=v.y,f*=v.x,p*=v.y,l+=C,u+=T,y=Ie(h),h=ys(y)}}return Mr({width:f,height:p,x:l,y:u})}function Ur(e,t){const n=Br(e).scrollLeft;return t?t.left+n:Kt(Ke(e)).left+n}function gl(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-Ur(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function _m(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",i=Ke(r),a=t?Fr(t.floating):!1;if(r===i||a&&s)return n;let l={scrollLeft:0,scrollTop:0},u=Ge(1);const f=Ge(0),p=Qe(r);if((p||!p&&!s)&&((vn(r)!=="body"||Zn(i))&&(l=Br(r)),Qe(r))){const g=Kt(r);u=bn(r),f.x=g.x+r.clientLeft,f.y=g.y+r.clientTop}const m=i&&!p&&!s?gl(i,l):Ge(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+f.x+m.x,y:n.y*u.y-l.scrollTop*u.y+f.y+m.y}}function xm(e){return Array.from(e.getClientRects())}function Cm(e){const t=Ke(e),n=Br(e),r=e.ownerDocument.body,o=Oe(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=Oe(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+Ur(e);const a=-n.scrollTop;return $e(r).direction==="rtl"&&(i+=Oe(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:i,y:a}}const vl=25;function Sm(e,t){const n=Ie(e),r=Ke(e),o=n.visualViewport;let s=r.clientWidth,i=r.clientHeight,a=0,l=0;if(o){s=o.width,i=o.height;const f=vs();(!f||f&&t==="fixed")&&(a=o.offsetLeft,l=o.offsetTop)}const u=Ur(r);if(u<=0){const f=r.ownerDocument,p=f.body,m=getComputedStyle(p),g=f.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,y=Math.abs(r.clientWidth-p.clientWidth-g);y<=vl&&(s-=y)}else u<=vl&&(s+=u);return{width:s,height:i,x:a,y:l}}const Em=new Set(["absolute","fixed"]);function Tm(e,t){const n=Kt(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=Qe(e)?bn(e):Ge(1),i=e.clientWidth*s.x,a=e.clientHeight*s.y,l=o*s.x,u=r*s.y;return{width:i,height:a,x:l,y:u}}function yl(e,t,n){let r;if(t==="viewport")r=Sm(e,n);else if(t==="document")r=Cm(Ke(e));else if(Me(t))r=Tm(t,n);else{const o=ml(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return Mr(r)}function bl(e,t){const n=_t(e);return n===t||!Me(n)||yn(n)?!1:$e(n).position==="fixed"||bl(n,t)}function Pm(e,t){const n=t.get(e);if(n)return n;let r=Xn(e,[],!1).filter(a=>Me(a)&&vn(a)!=="body"),o=null;const s=$e(e).position==="fixed";let i=s?_t(e):e;for(;Me(i)&&!yn(i);){const a=$e(i),l=gs(i);!l&&a.position==="fixed"&&(o=null),(s?!l&&!o:!l&&a.position==="static"&&!!o&&Em.has(o.position)||Zn(i)&&!l&&bl(e,i))?r=r.filter(f=>f!==i):o=a,i=_t(i)}return t.set(e,r),r}function Am(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?Fr(t)?[]:Pm(t,this._c):[].concat(n),r],a=i[0],l=i.reduce((u,f)=>{const p=yl(t,f,o);return u.top=Oe(p.top,u.top),u.right=wt(p.right,u.right),u.bottom=wt(p.bottom,u.bottom),u.left=Oe(p.left,u.left),u},yl(t,a,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Rm(e){const{width:t,height:n}=hl(e);return{width:t,height:n}}function Om(e,t,n){const r=Qe(t),o=Ke(t),s=n==="fixed",i=Kt(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const l=Ge(0);function u(){l.x=Ur(o)}if(r||!r&&!s)if((vn(t)!=="body"||Zn(o))&&(a=Br(t)),r){const g=Kt(t,!0,s,t);l.x=g.x+t.clientLeft,l.y=g.y+t.clientTop}else o&&u();s&&!r&&o&&u();const f=o&&!r&&!s?gl(o,a):Ge(0),p=i.left+a.scrollLeft-l.x-f.x,m=i.top+a.scrollTop-l.y-f.y;return{x:p,y:m,width:i.width,height:i.height}}function ws(e){return $e(e).position==="static"}function wl(e,t){if(!Qe(e)||$e(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Ke(e)===n&&(n=n.ownerDocument.body),n}function _l(e,t){const n=Ie(e);if(Fr(e))return n;if(!Qe(e)){let o=_t(e);for(;o&&!yn(o);){if(Me(o)&&!ws(o))return o;o=_t(o)}return n}let r=wl(e,t);for(;r&&fm(r)&&ws(r);)r=wl(r,t);return r&&yn(r)&&ws(r)&&!gs(r)?n:r||vm(e)||n}const Im=async function(e){const t=this.getOffsetParent||_l,n=this.getDimensions,r=await n(e.floating);return{reference:Om(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function jm(e){return $e(e).direction==="rtl"}const km={convertOffsetParentRelativeRectToViewportRelativeRect:_m,getDocumentElement:Ke,getClippingRect:Am,getOffsetParent:_l,getElementRects:Im,getClientRects:xm,getDimensions:Rm,getScale:bn,isElement:Me,isRTL:jm};function xl(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Lm(e,t){let n=null,r;const o=Ke(e);function s(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function i(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),s();const u=e.getBoundingClientRect(),{left:f,top:p,width:m,height:g}=u;if(a||t(),!m||!g)return;const y=Dr(p),h=Dr(o.clientWidth-(f+m)),v=Dr(o.clientHeight-(p+g)),b=Dr(f),C={rootMargin:-y+"px "+-h+"px "+-v+"px "+-b+"px",threshold:Oe(0,wt(1,l))||1};let T=!0;function P(A){const R=A[0].intersectionRatio;if(R!==l){if(!T)return i();R?i(!1,R):r=setTimeout(()=>{i(!1,1e-7)},1e3)}R===1&&!xl(u,e.getBoundingClientRect())&&i(),T=!1}try{n=new IntersectionObserver(P,{...C,root:o.ownerDocument})}catch{n=new IntersectionObserver(P,C)}n.observe(e)}return i(!0),s}function Dm(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,u=bs(e),f=o||s?[...u?Xn(u):[],...Xn(t)]:[];f.forEach(b=>{o&&b.addEventListener("scroll",n,{passive:!0}),s&&b.addEventListener("resize",n)});const p=u&&a?Lm(u,n):null;let m=-1,g=null;i&&(g=new ResizeObserver(b=>{let[_]=b;_&&_.target===u&&g&&(g.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var C;(C=g)==null||C.observe(t)})),n()}),u&&!l&&g.observe(u),g.observe(t));let y,h=l?Kt(e):null;l&&v();function v(){const b=Kt(e);h&&!xl(h,b)&&n(),h=b,y=requestAnimationFrame(v)}return n(),()=>{var b;f.forEach(_=>{o&&_.removeEventListener("scroll",n),s&&_.removeEventListener("resize",n)}),p==null||p(),(b=g)==null||b.disconnect(),g=null,l&&cancelAnimationFrame(y)}}const Nm=im,Mm=am,$m=rm,Fm=cm,Bm=om,Cl=nm,Um=lm,Wm=(e,t,n)=>{const r=new Map,o={platform:km,...n},s={...o.platform,_c:r};return tm(e,t,{...o,platform:s})};var Hm=typeof document<"u",Vm=function(){},Wr=Hm?S.useLayoutEffect:Vm;function Hr(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Hr(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const s=o[r];if(!(s==="_owner"&&e.$$typeof)&&!Hr(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function Sl(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function El(e,t){const n=Sl(e);return Math.round(t*n)/n}function _s(e){const t=d.useRef(e);return Wr(()=>{t.current=e}),t}function zm(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:s,floating:i}={},transform:a=!0,whileElementsMounted:l,open:u}=e,[f,p]=d.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,g]=d.useState(r);Hr(m,r)||g(r);const[y,h]=d.useState(null),[v,b]=d.useState(null),_=d.useCallback(F=>{F!==A.current&&(A.current=F,h(F))},[]),C=d.useCallback(F=>{F!==R.current&&(R.current=F,b(F))},[]),T=s||y,P=i||v,A=d.useRef(null),R=d.useRef(null),D=d.useRef(f),k=l!=null,N=_s(l),U=_s(o),W=_s(u),H=d.useCallback(()=>{if(!A.current||!R.current)return;const F={placement:t,strategy:n,middleware:m};U.current&&(F.platform=U.current),Wm(A.current,R.current,F).then(se=>{const ge={...se,isPositioned:W.current!==!1};z.current&&!Hr(D.current,ge)&&(D.current=ge,mr.flushSync(()=>{p(ge)}))})},[m,t,n,U,W]);Wr(()=>{u===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,p(F=>({...F,isPositioned:!1})))},[u]);const z=d.useRef(!1);Wr(()=>(z.current=!0,()=>{z.current=!1}),[]),Wr(()=>{if(T&&(A.current=T),P&&(R.current=P),T&&P){if(N.current)return N.current(T,P,H);H()}},[T,P,H,N,k]);const oe=d.useMemo(()=>({reference:A,floating:R,setReference:_,setFloating:C}),[_,C]),G=d.useMemo(()=>({reference:T,floating:P}),[T,P]),Y=d.useMemo(()=>{const F={position:n,left:0,top:0};if(!G.floating)return F;const se=El(G.floating,f.x),ge=El(G.floating,f.y);return a?{...F,transform:"translate("+se+"px, "+ge+"px)",...Sl(G.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:se,top:ge}},[n,a,G.floating,f.x,f.y]);return d.useMemo(()=>({...f,update:H,refs:oe,elements:G,floatingStyles:Y}),[f,H,oe,G,Y])}const Gm=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Cl({element:r.current,padding:o}).fn(n):{}:r?Cl({element:r,padding:o}).fn(n):{}}}},qm=(e,t)=>({...Nm(e),options:[e,t]}),Km=(e,t)=>({...Mm(e),options:[e,t]}),Qm=(e,t)=>({...Um(e),options:[e,t]}),Ym=(e,t)=>({...$m(e),options:[e,t]}),Zm=(e,t)=>({...Fm(e),options:[e,t]}),Xm=(e,t)=>({...Bm(e),options:[e,t]}),Jm=(e,t)=>({...Gm(e),options:[e,t]});var e1="Arrow",Tl=d.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...s}=e;return c.jsx(ie.svg,{...s,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:c.jsx("polygon",{points:"0,0 30,0 15,10"})})});Tl.displayName=e1;var t1=Tl;function n1(e){const[t,n]=d.useState(void 0);return ve(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const s=o[0];let i,a;if("borderBoxSize"in s){const l=s.borderBoxSize,u=Array.isArray(l)?l[0]:l;i=u.inlineSize,a=u.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var xs="Popper",[Pl,Vr]=Yn(xs),[r1,Al]=Pl(xs),Rl=e=>{const{__scopePopper:t,children:n}=e,[r,o]=d.useState(null);return c.jsx(r1,{scope:t,anchor:r,onAnchorChange:o,children:n})};Rl.displayName=xs;var Ol="PopperAnchor",Il=d.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,s=Al(Ol,n),i=d.useRef(null),a=le(t,i),l=d.useRef(null);return d.useEffect(()=>{const u=l.current;l.current=(r==null?void 0:r.current)||i.current,u!==l.current&&s.onAnchorChange(l.current)}),r?null:c.jsx(ie.div,{...o,ref:a})});Il.displayName=Ol;var Cs="PopperContent",[o1,s1]=Pl(Cs),jl=d.forwardRef((e,t)=>{var $,te,fe,X,ne,J;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:s="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:f=0,sticky:p="partial",hideWhenDetached:m=!1,updatePositionStrategy:g="optimized",onPlaced:y,...h}=e,v=Al(Cs,n),[b,_]=d.useState(null),C=le(t,Ce=>_(Ce)),[T,P]=d.useState(null),A=n1(T),R=(A==null?void 0:A.width)??0,D=(A==null?void 0:A.height)??0,k=r+(s!=="center"?"-"+s:""),N=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},U=Array.isArray(u)?u:[u],W=U.length>0,H={padding:N,boundary:U.filter(a1),altBoundary:W},{refs:z,floatingStyles:oe,placement:G,isPositioned:Y,middlewareData:F}=zm({strategy:"fixed",placement:k,whileElementsMounted:(...Ce)=>Dm(...Ce,{animationFrame:g==="always"}),elements:{reference:v.anchor},middleware:[qm({mainAxis:o+D,alignmentAxis:i}),l&&Km({mainAxis:!0,crossAxis:!1,limiter:p==="partial"?Qm():void 0,...H}),l&&Ym({...H}),Zm({...H,apply:({elements:Ce,rects:Le,availableWidth:ot,availableHeight:ze})=>{const{width:Bt,height:Ao}=Le.reference,ht=Ce.floating.style;ht.setProperty("--radix-popper-available-width",`${ot}px`),ht.setProperty("--radix-popper-available-height",`${ze}px`),ht.setProperty("--radix-popper-anchor-width",`${Bt}px`),ht.setProperty("--radix-popper-anchor-height",`${Ao}px`)}}),T&&Jm({element:T,padding:a}),l1({arrowWidth:R,arrowHeight:D}),m&&Xm({strategy:"referenceHidden",...H})]}),[se,ge]=Dl(G),ke=Gt(y);ve(()=>{Y&&(ke==null||ke())},[Y,ke]);const Mt=($=F.arrow)==null?void 0:$.x,$t=(te=F.arrow)==null?void 0:te.y,rt=((fe=F.arrow)==null?void 0:fe.centerOffset)!==0,[Ft,Ve]=d.useState();return ve(()=>{b&&Ve(window.getComputedStyle(b).zIndex)},[b]),c.jsx("div",{ref:z.setFloating,"data-radix-popper-content-wrapper":"",style:{...oe,transform:Y?oe.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Ft,"--radix-popper-transform-origin":[(X=F.transformOrigin)==null?void 0:X.x,(ne=F.transformOrigin)==null?void 0:ne.y].join(" "),...((J=F.hide)==null?void 0:J.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:c.jsx(o1,{scope:n,placedSide:se,onArrowChange:P,arrowX:Mt,arrowY:$t,shouldHideArrow:rt,children:c.jsx(ie.div,{"data-side":se,"data-align":ge,...h,ref:C,style:{...h.style,animation:Y?void 0:"none"}})})})});jl.displayName=Cs;var kl="PopperArrow",i1={top:"bottom",right:"left",bottom:"top",left:"right"},Ll=d.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,s=s1(kl,r),i=i1[s.placedSide];return c.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:c.jsx(t1,{...o,ref:n,style:{...o.style,display:"block"}})})});Ll.displayName=kl;function a1(e){return e!==null}var l1=e=>({name:"transformOrigin",options:e,fn(t){var v,b,_;const{placement:n,rects:r,middlewareData:o}=t,i=((v=o.arrow)==null?void 0:v.centerOffset)!==0,a=i?0:e.arrowWidth,l=i?0:e.arrowHeight,[u,f]=Dl(n),p={start:"0%",center:"50%",end:"100%"}[f],m=(((b=o.arrow)==null?void 0:b.x)??0)+a/2,g=(((_=o.arrow)==null?void 0:_.y)??0)+l/2;let y="",h="";return u==="bottom"?(y=i?p:`${m}px`,h=`${-l}px`):u==="top"?(y=i?p:`${m}px`,h=`${r.floating.height+l}px`):u==="right"?(y=`${-l}px`,h=i?p:`${g}px`):u==="left"&&(y=`${r.floating.width+l}px`,h=i?p:`${g}px`),{data:{x:y,y:h}}}});function Dl(e){const[t,n="center"]=e.split("-");return[t,n]}var Nl=Rl,Ml=Il,$l=jl,Fl=Ll,c1="Portal",Ss=d.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[o,s]=d.useState(!1);ve(()=>s(!0),[]);const i=n||o&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?Wt.createPortal(c.jsx(ie.div,{...r,ref:t}),i):null});Ss.displayName=c1;function u1(e){const t=d1(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),l=a.find(p1);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function d1(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=m1(o),a=h1(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var f1=Symbol("radix.slottable");function p1(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===f1}function h1(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function m1(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var g1=d[" useInsertionEffect ".trim().toString()]||ve;function zr({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,s,i]=v1({defaultProp:t,onChange:n}),a=e!==void 0,l=a?e:o;{const f=d.useRef(e!==void 0);d.useEffect(()=>{const p=f.current;p!==a&&console.warn(`${r} is changing from ${p?"controlled":"uncontrolled"} to ${a?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),f.current=a},[a,r])}const u=d.useCallback(f=>{var p;if(a){const m=y1(f)?f(e):f;m!==e&&((p=i.current)==null||p.call(i,m))}else s(f)},[a,e,s,i]);return[l,u]}function v1({defaultProp:e,onChange:t}){const[n,r]=d.useState(e),o=d.useRef(n),s=d.useRef(t);return g1(()=>{s.current=t},[t]),d.useEffect(()=>{var i;o.current!==n&&((i=s.current)==null||i.call(s,n),o.current=n)},[n,o]),[n,r,s]}function y1(e){return typeof e=="function"}function b1(e){const t=d.useRef({value:e,previous:e});return d.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var Bl=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),w1="VisuallyHidden",Ul=d.forwardRef((e,t)=>c.jsx(ie.span,{...e,ref:t,style:{...Bl,...e.style}}));Ul.displayName=w1;var _1=Ul,x1=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},wn=new WeakMap,Gr=new WeakMap,qr={},Es=0,Wl=function(e){return e&&(e.host||Wl(e.parentNode))},C1=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=Wl(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},S1=function(e,t,n,r){var o=C1(t,Array.isArray(e)?e:[e]);qr[n]||(qr[n]=new WeakMap);var s=qr[n],i=[],a=new Set,l=new Set(o),u=function(p){!p||a.has(p)||(a.add(p),u(p.parentNode))};o.forEach(u);var f=function(p){!p||l.has(p)||Array.prototype.forEach.call(p.children,function(m){if(a.has(m))f(m);else try{var g=m.getAttribute(r),y=g!==null&&g!=="false",h=(wn.get(m)||0)+1,v=(s.get(m)||0)+1;wn.set(m,h),s.set(m,v),i.push(m),h===1&&y&&Gr.set(m,!0),v===1&&m.setAttribute(n,"true"),y||m.setAttribute(r,"true")}catch(b){console.error("aria-hidden: cannot operate on ",m,b)}})};return f(t),a.clear(),Es++,function(){i.forEach(function(p){var m=wn.get(p)-1,g=s.get(p)-1;wn.set(p,m),s.set(p,g),m||(Gr.has(p)||p.removeAttribute(r),Gr.delete(p)),g||p.removeAttribute(n)}),Es--,Es||(wn=new WeakMap,wn=new WeakMap,Gr=new WeakMap,qr={})}},Hl=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=x1(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),S1(r,o,n,"aria-hidden")):function(){return null}},Ts=function(e,t){return Ts=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(n[o]=r[o])},Ts(e,t)};function Jn(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Ts(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var Ye=function(){return Ye=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},Ye.apply(this,arguments)};function Vl(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Ps(e){var t=typeof Symbol=="function"&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function As(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),o,s=[],i;try{for(;(t===void 0||t-- >0)&&!(o=r.next()).done;)s.push(o.value)}catch(a){i={error:a}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(i)throw i.error}}return s}function Kr(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,s;r<o;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var Qr="right-scroll-bar-position",Yr="width-before-scroll-bar",E1="with-scroll-bars-hidden",T1="--removed-body-scroll-bar-size";function Rs(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function P1(e,t){var n=S.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var A1=typeof window<"u"?d.useLayoutEffect:d.useEffect,zl=new WeakMap;function R1(e,t){var n=P1(null,function(r){return e.forEach(function(o){return Rs(o,r)})});return A1(function(){var r=zl.get(n);if(r){var o=new Set(r),s=new Set(e),i=n.current;o.forEach(function(a){s.has(a)||Rs(a,null)}),s.forEach(function(a){o.has(a)||Rs(a,i)})}zl.set(n,e)},[e]),n}function O1(e){return e}function I1(e,t){t===void 0&&(t=O1);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var i=t(s,r);return n.push(i),function(){n=n.filter(function(a){return a!==i})}},assignSyncMedium:function(s){for(r=!0;n.length;){var i=n;n=[],i.forEach(s)}n={push:function(a){return s(a)},filter:function(){return n}}},assignMedium:function(s){r=!0;var i=[];if(n.length){var a=n;n=[],a.forEach(s),i=n}var l=function(){var f=i;i=[],f.forEach(s)},u=function(){return Promise.resolve().then(l)};u(),n={push:function(f){i.push(f),u()},filter:function(f){return i=i.filter(f),n}}}};return o}function j1(e){e===void 0&&(e={});var t=I1(null);return t.options=Ye({async:!0,ssr:!1},e),t}var Gl=function(e){var t=e.sideCar,n=Vl(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return d.createElement(r,Ye({},n))};Gl.isSideCarExport=!0;function k1(e,t){return e.useMedium(t),Gl}var ql=j1(),Os=function(){},Zr=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:Os,onWheelCapture:Os,onTouchMoveCapture:Os}),o=r[0],s=r[1],i=e.forwardProps,a=e.children,l=e.className,u=e.removeScrollBar,f=e.enabled,p=e.shards,m=e.sideCar,g=e.noRelative,y=e.noIsolation,h=e.inert,v=e.allowPinchZoom,b=e.as,_=b===void 0?"div":b,C=e.gapMode,T=Vl(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),P=m,A=R1([n,t]),R=Ye(Ye({},T),o);return d.createElement(d.Fragment,null,f&&d.createElement(P,{sideCar:ql,removeScrollBar:u,shards:p,noRelative:g,noIsolation:y,inert:h,setCallbacks:s,allowPinchZoom:!!v,lockRef:n,gapMode:C}),i?d.cloneElement(d.Children.only(a),Ye(Ye({},R),{ref:A})):d.createElement(_,Ye({},R,{className:l,ref:A}),a))});Zr.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Zr.classNames={fullWidth:Yr,zeroRight:Qr};var L1=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function D1(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=L1();return t&&e.setAttribute("nonce",t),e}function N1(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function M1(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var $1=function(){var e=0,t=null;return{add:function(n){e==0&&(t=D1())&&(N1(t,n),M1(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},F1=function(){var e=$1();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Kl=function(){var e=F1(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},B1={left:0,top:0,right:0,gap:0},Is=function(e){return parseInt(e||"",10)||0},U1=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Is(n),Is(r),Is(o)]},W1=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return B1;var t=U1(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},H1=Kl(),_n="data-scroll-locked",V1=function(e,t,n,r){var o=e.left,s=e.top,i=e.right,a=e.gap;return n===void 0&&(n="margin"),`
|
|
200
|
-
.`.concat(
|
|
199
|
+
`,Cr=16,Ep=({reverseOrder:e,position:t="top-center",toastOptions:n,gutter:r,children:o,containerStyle:s,containerClassName:i})=>{let{toasts:a,handlers:l}=Jf(n);return d.createElement("div",{style:{position:"fixed",zIndex:9999,top:Cr,left:Cr,right:Cr,bottom:Cr,pointerEvents:"none",...s},className:i,onMouseEnter:l.startPause,onMouseLeave:l.endPause},a.map(u=>{let f=u.position||t,p=l.calculateOffset(u,{reverseOrder:e,gutter:r,defaultPosition:t}),m=Cp(f,p);return d.createElement(xp,{id:u.id,key:u.id,onHeightUpdate:l.updateHeight,className:u.visible?Sp:"",style:m},u.type==="custom"?br(u.message,u):o?o(u):d.createElement(_p,{toast:u,position:f}))}))},da=Re,hn=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Vt=typeof window>"u"||"Deno"in globalThis;function we(){}function Tp(e,t){return typeof e=="function"?e(t):e}function Vo(e){return typeof e=="number"&&e>=0&&e!==1/0}function fa(e,t){return Math.max(e+(t||0)-Date.now(),0)}function yt(e,t){return typeof e=="function"?e(t):e}function Ne(e,t){return typeof e=="function"?e(t):e}function pa(e,t){const{type:n="all",exact:r,fetchStatus:o,predicate:s,queryKey:i,stale:a}=e;if(i){if(r){if(t.queryHash!==zo(i,t.options))return!1}else if(!Qn(t.queryKey,i))return!1}if(n!=="all"){const l=t.isActive();if(n==="active"&&!l||n==="inactive"&&l)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||o&&o!==t.state.fetchStatus||s&&!s(t))}function ha(e,t){const{exact:n,status:r,predicate:o,mutationKey:s}=e;if(s){if(!t.options.mutationKey)return!1;if(n){if(zt(t.options.mutationKey)!==zt(s))return!1}else if(!Qn(t.options.mutationKey,s))return!1}return!(r&&t.state.status!==r||o&&!o(t))}function zo(e,t){return((t==null?void 0:t.queryKeyHashFn)||zt)(e)}function zt(e){return JSON.stringify(e,(t,n)=>qo(n)?Object.keys(n).sort().reduce((r,o)=>(r[o]=n[o],r),{}):n)}function Qn(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>Qn(e[n],t[n])):!1}function Go(e,t){if(e===t)return e;const n=ma(e)&&ma(t);if(n||qo(e)&&qo(t)){const r=n?e:Object.keys(e),o=r.length,s=n?t:Object.keys(t),i=s.length,a=n?[]:{};let l=0;for(let u=0;u<i;u++){const f=n?u:s[u];(!n&&r.includes(f)||n)&&e[f]===void 0&&t[f]===void 0?(a[f]=void 0,l++):(a[f]=Go(e[f],t[f]),a[f]===e[f]&&e[f]!==void 0&&l++)}return o===i&&l===o?e:a}return t}function Sr(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function ma(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function qo(e){if(!ga(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!ga(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function ga(e){return Object.prototype.toString.call(e)==="[object Object]"}function Pp(e){return new Promise(t=>{setTimeout(t,e)})}function Ko(e,t,n){if(typeof n.structuralSharing=="function")return n.structuralSharing(e,t);if(n.structuralSharing!==!1){try{return Go(e,t)}catch(r){throw console.error(`Structural sharing requires data to be JSON serializable. To fix this, turn off structuralSharing or return JSON-serializable data from your queryFn. [${n.queryHash}]: ${r}`),r}return Go(e,t)}return t}function Ap(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function Rp(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var Er=Symbol();function va(e,t){return e.queryFn===Er&&console.error(`Attempted to invoke queryFn when set to skipToken. This is likely a configuration error. Query hash: '${e.queryHash}'`),!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Er?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function ya(e,t){return typeof e=="function"?e(...t):!!e}var Op=(Md=class extends hn{constructor(){super();M(this,nn);M(this,Pt);M(this,An);I(this,An,t=>{if(!Vt&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){x(this,Pt)||this.setEventListener(x(this,An))}onUnsubscribe(){var t;this.hasListeners()||((t=x(this,Pt))==null||t.call(this),I(this,Pt,void 0))}setEventListener(t){var n;I(this,An,t),(n=x(this,Pt))==null||n.call(this),I(this,Pt,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){x(this,nn)!==t&&(I(this,nn,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof x(this,nn)=="boolean"?x(this,nn):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},nn=new WeakMap,Pt=new WeakMap,An=new WeakMap,Md),Qo=new Op,Ip=($d=class extends hn{constructor(){super();M(this,Rn,!0);M(this,At);M(this,On);I(this,On,t=>{if(!Vt&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){x(this,At)||this.setEventListener(x(this,On))}onUnsubscribe(){var t;this.hasListeners()||((t=x(this,At))==null||t.call(this),I(this,At,void 0))}setEventListener(t){var n;I(this,On,t),(n=x(this,At))==null||n.call(this),I(this,At,t(this.setOnline.bind(this)))}setOnline(t){x(this,Rn)!==t&&(I(this,Rn,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return x(this,Rn)}},Rn=new WeakMap,At=new WeakMap,On=new WeakMap,$d),Tr=new Ip;function Yo(){let e,t;const n=new Promise((o,s)=>{e=o,t=s});n.status="pending",n.catch(()=>{});function r(o){Object.assign(n,o),delete n.resolve,delete n.reject}return n.resolve=o=>{r({status:"fulfilled",value:o}),e(o)},n.reject=o=>{r({status:"rejected",reason:o}),t(o)},n}function jp(e){return Math.min(1e3*2**e,3e4)}function ba(e){return(e??"online")==="online"?Tr.isOnline():!0}var wa=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Zo(e){return e instanceof wa}function _a(e){let t=!1,n=0,r=!1,o;const s=Yo(),i=h=>{var v;r||(m(new wa(h)),(v=e.abort)==null||v.call(e))},a=()=>{t=!0},l=()=>{t=!1},u=()=>Qo.isFocused()&&(e.networkMode==="always"||Tr.isOnline())&&e.canRun(),f=()=>ba(e.networkMode)&&e.canRun(),p=h=>{var v;r||(r=!0,(v=e.onSuccess)==null||v.call(e,h),o==null||o(),s.resolve(h))},m=h=>{var v;r||(r=!0,(v=e.onError)==null||v.call(e,h),o==null||o(),s.reject(h))},g=()=>new Promise(h=>{var v;o=b=>{(r||u())&&h(b)},(v=e.onPause)==null||v.call(e)}).then(()=>{var h;o=void 0,r||(h=e.onContinue)==null||h.call(e)}),y=()=>{if(r)return;let h;const v=n===0?e.initialPromise:void 0;try{h=v??e.fn()}catch(b){h=Promise.reject(b)}Promise.resolve(h).then(p).catch(b=>{var A;if(r)return;const _=e.retry??(Vt?0:3),C=e.retryDelay??jp,T=typeof C=="function"?C(n,b):C,P=_===!0||typeof _=="number"&&n<_||typeof _=="function"&&_(n,b);if(t||!P){m(b);return}n++,(A=e.onFail)==null||A.call(e,n,b),Pp(T).then(()=>u()?void 0:g()).then(()=>{t?m(b):y()})})};return{promise:s,cancel:i,continue:()=>(o==null||o(),s),cancelRetry:a,continueRetry:l,canStart:f,start:()=>(f()?y():g().then(y),s)}}var kp=e=>setTimeout(e,0);function Lp(){let e=[],t=0,n=a=>{a()},r=a=>{a()},o=kp;const s=a=>{t?e.push(a):o(()=>{n(a)})},i=()=>{const a=e;e=[],a.length&&o(()=>{r(()=>{a.forEach(l=>{n(l)})})})};return{batch:a=>{let l;t++;try{l=a()}finally{t--,t||i()}return l},batchCalls:a=>(...l)=>{s(()=>{a(...l)})},schedule:s,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{o=a}}}var me=Lp(),xa=(Fd=class{constructor(){M(this,rn)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Vo(this.gcTime)&&I(this,rn,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Vt?1/0:5*60*1e3))}clearGcTimeout(){x(this,rn)&&(clearTimeout(x(this,rn)),I(this,rn,void 0))}},rn=new WeakMap,Fd),Dp=(Bd=class extends xa{constructor(t){super();M(this,We);M(this,In);M(this,jn);M(this,je);M(this,on);M(this,be);M(this,cr);M(this,sn);I(this,sn,!1),I(this,cr,t.defaultOptions),this.setOptions(t.options),this.observers=[],I(this,on,t.client),I(this,je,x(this,on).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,I(this,In,Np(this.options)),this.state=t.state??x(this,In),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=x(this,be))==null?void 0:t.promise}setOptions(t){this.options={...x(this,cr),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&x(this,je).remove(this)}setData(t,n){const r=Ko(this.state.data,t,this.options);return V(this,We,mt).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){V(this,We,mt).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,o;const n=(r=x(this,be))==null?void 0:r.promise;return(o=x(this,be))==null||o.cancel(t),n?n.then(we).catch(we):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(x(this,In))}isActive(){return this.observers.some(t=>Ne(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Er||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>yt(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!fa(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=x(this,be))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=x(this,be))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),x(this,je).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(x(this,be)&&(x(this,sn)?x(this,be).cancel({revert:!0}):x(this,be).cancelRetry()),this.scheduleGc()),x(this,je).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||V(this,We,mt).call(this,{type:"invalidate"})}fetch(t,n){var u,f,p;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(x(this,be))return x(this,be).continueRetry(),x(this,be).promise}if(t&&this.setOptions(t),!this.options.queryFn){const m=this.observers.find(g=>g.options.queryFn);m&&this.setOptions(m.options)}Array.isArray(this.options.queryKey)||console.error("As of v4, queryKey needs to be an Array. If you are using a string like 'repoData', please change it to an Array, e.g. ['repoData']");const r=new AbortController,o=m=>{Object.defineProperty(m,"signal",{enumerable:!0,get:()=>(I(this,sn,!0),r.signal)})},s=()=>{const m=va(this.options,n),y=(()=>{const h={client:x(this,on),queryKey:this.queryKey,meta:this.meta};return o(h),h})();return I(this,sn,!1),this.options.persister?this.options.persister(m,y,this):m(y)},a=(()=>{const m={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:x(this,on),state:this.state,fetchFn:s};return o(m),m})();(u=this.options.behavior)==null||u.onFetch(a,this),I(this,jn,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((f=a.fetchOptions)==null?void 0:f.meta))&&V(this,We,mt).call(this,{type:"fetch",meta:(p=a.fetchOptions)==null?void 0:p.meta});const l=m=>{var g,y,h,v;Zo(m)&&m.silent||V(this,We,mt).call(this,{type:"error",error:m}),Zo(m)||((y=(g=x(this,je).config).onError)==null||y.call(g,m,this),(v=(h=x(this,je).config).onSettled)==null||v.call(h,this.state.data,m,this)),this.scheduleGc()};return I(this,be,_a({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,abort:r.abort.bind(r),onSuccess:m=>{var g,y,h,v;if(m===void 0){console.error(`Query data cannot be undefined. Please make sure to return a value other than undefined from your query function. Affected query key: ${this.queryHash}`),l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(m)}catch(b){l(b);return}(y=(g=x(this,je).config).onSuccess)==null||y.call(g,m,this),(v=(h=x(this,je).config).onSettled)==null||v.call(h,m,this.state.error,this),this.scheduleGc()},onError:l,onFail:(m,g)=>{V(this,We,mt).call(this,{type:"failed",failureCount:m,error:g})},onPause:()=>{V(this,We,mt).call(this,{type:"pause"})},onContinue:()=>{V(this,We,mt).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),x(this,be).start()}},In=new WeakMap,jn=new WeakMap,je=new WeakMap,on=new WeakMap,be=new WeakMap,cr=new WeakMap,sn=new WeakMap,We=new WeakSet,mt=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...Ca(r.data,this.options),fetchMeta:t.meta??null};case"success":return{...r,data:t.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const o=t.error;return Zo(o)&&o.revert&&x(this,jn)?{...x(this,jn),fetchStatus:"idle"}:{...r,error:o,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:o,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),me.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),x(this,je).notify({query:this,type:"updated",action:t})})},Bd);function Ca(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:ba(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function Np(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var Mp=(Ud=class extends hn{constructor(t={}){super();M(this,et);this.config=t,I(this,et,new Map)}build(t,n,r){const o=n.queryKey,s=n.queryHash??zo(o,n);let i=this.get(s);return i||(i=new Dp({client:t,queryKey:o,queryHash:s,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(o)}),this.add(i)),i}add(t){x(this,et).has(t.queryHash)||(x(this,et).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=x(this,et).get(t.queryHash);n&&(t.destroy(),n===t&&x(this,et).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){me.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return x(this,et).get(t)}getAll(){return[...x(this,et).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>pa(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>pa(t,r)):n}notify(t){me.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){me.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){me.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},et=new WeakMap,Ud),$p=(Wd=class extends xa{constructor(t){super();M(this,nt);M(this,tt);M(this,_e);M(this,an);this.mutationId=t.mutationId,I(this,_e,t.mutationCache),I(this,tt,[]),this.state=t.state||Sa(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){x(this,tt).includes(t)||(x(this,tt).push(t),this.clearGcTimeout(),x(this,_e).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){I(this,tt,x(this,tt).filter(n=>n!==t)),this.scheduleGc(),x(this,_e).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){x(this,tt).length||(this.state.status==="pending"?this.scheduleGc():x(this,_e).remove(this))}continue(){var t;return((t=x(this,an))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var s,i,a,l,u,f,p,m,g,y,h,v,b,_,C,T,P,A,R,D;const n=()=>{V(this,nt,Ut).call(this,{type:"continue"})};I(this,an,_a({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(k,N)=>{V(this,nt,Ut).call(this,{type:"failed",failureCount:k,error:N})},onPause:()=>{V(this,nt,Ut).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>x(this,_e).canRun(this)}));const r=this.state.status==="pending",o=!x(this,an).canStart();try{if(r)n();else{V(this,nt,Ut).call(this,{type:"pending",variables:t,isPaused:o}),await((i=(s=x(this,_e).config).onMutate)==null?void 0:i.call(s,t,this));const N=await((l=(a=this.options).onMutate)==null?void 0:l.call(a,t));N!==this.state.context&&V(this,nt,Ut).call(this,{type:"pending",context:N,variables:t,isPaused:o})}const k=await x(this,an).start();return await((f=(u=x(this,_e).config).onSuccess)==null?void 0:f.call(u,k,t,this.state.context,this)),await((m=(p=this.options).onSuccess)==null?void 0:m.call(p,k,t,this.state.context)),await((y=(g=x(this,_e).config).onSettled)==null?void 0:y.call(g,k,null,this.state.variables,this.state.context,this)),await((v=(h=this.options).onSettled)==null?void 0:v.call(h,k,null,t,this.state.context)),V(this,nt,Ut).call(this,{type:"success",data:k}),k}catch(k){try{throw await((_=(b=x(this,_e).config).onError)==null?void 0:_.call(b,k,t,this.state.context,this)),await((T=(C=this.options).onError)==null?void 0:T.call(C,k,t,this.state.context)),await((A=(P=x(this,_e).config).onSettled)==null?void 0:A.call(P,void 0,k,this.state.variables,this.state.context,this)),await((D=(R=this.options).onSettled)==null?void 0:D.call(R,void 0,k,t,this.state.context)),k}finally{V(this,nt,Ut).call(this,{type:"error",error:k})}}finally{x(this,_e).runNext(this)}}},tt=new WeakMap,_e=new WeakMap,an=new WeakMap,nt=new WeakSet,Ut=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),me.batch(()=>{x(this,tt).forEach(r=>{r.onMutationUpdate(t)}),x(this,_e).notify({mutation:this,type:"updated",action:t})})},Wd);function Sa(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Fp=(Hd=class extends hn{constructor(t={}){super();M(this,dt);M(this,He);M(this,ur);this.config=t,I(this,dt,new Set),I(this,He,new Map),I(this,ur,0)}build(t,n,r){const o=new $p({mutationCache:this,mutationId:++Ro(this,ur)._,options:t.defaultMutationOptions(n),state:r});return this.add(o),o}add(t){x(this,dt).add(t);const n=Pr(t);if(typeof n=="string"){const r=x(this,He).get(n);r?r.push(t):x(this,He).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(x(this,dt).delete(t)){const n=Pr(t);if(typeof n=="string"){const r=x(this,He).get(n);if(r)if(r.length>1){const o=r.indexOf(t);o!==-1&&r.splice(o,1)}else r[0]===t&&x(this,He).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=Pr(t);if(typeof n=="string"){const r=x(this,He).get(n),o=r==null?void 0:r.find(s=>s.state.status==="pending");return!o||o===t}else return!0}runNext(t){var r;const n=Pr(t);if(typeof n=="string"){const o=(r=x(this,He).get(n))==null?void 0:r.find(s=>s!==t&&s.state.isPaused);return(o==null?void 0:o.continue())??Promise.resolve()}else return Promise.resolve()}clear(){me.batch(()=>{x(this,dt).forEach(t=>{this.notify({type:"removed",mutation:t})}),x(this,dt).clear(),x(this,He).clear()})}getAll(){return Array.from(x(this,dt))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>ha(n,r))}findAll(t={}){return this.getAll().filter(n=>ha(t,n))}notify(t){me.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return me.batch(()=>Promise.all(t.map(n=>n.continue().catch(we))))}},dt=new WeakMap,He=new WeakMap,ur=new WeakMap,Hd);function Pr(e){var t;return(t=e.options.scope)==null?void 0:t.id}function Ea(e){return{onFetch:(t,n)=>{var f,p,m,g,y;const r=t.options,o=(m=(p=(f=t.fetchOptions)==null?void 0:f.meta)==null?void 0:p.fetchMore)==null?void 0:m.direction,s=((g=t.state.data)==null?void 0:g.pages)||[],i=((y=t.state.data)==null?void 0:y.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const u=async()=>{let h=!1;const v=C=>{Object.defineProperty(C,"signal",{enumerable:!0,get:()=>(t.signal.aborted?h=!0:t.signal.addEventListener("abort",()=>{h=!0}),t.signal)})},b=va(t.options,t.fetchOptions),_=async(C,T,P)=>{if(h)return Promise.reject();if(T==null&&C.pages.length)return Promise.resolve(C);const R=(()=>{const U={client:t.client,queryKey:t.queryKey,pageParam:T,direction:P?"backward":"forward",meta:t.options.meta};return v(U),U})(),D=await b(R),{maxPages:k}=t.options,N=P?Rp:Ap;return{pages:N(C.pages,D,k),pageParams:N(C.pageParams,T,k)}};if(o&&s.length){const C=o==="backward",T=C?Bp:Ta,P={pages:s,pageParams:i},A=T(r,P);a=await _(P,A,C)}else{const C=e??s.length;do{const T=l===0?i[0]??r.initialPageParam:Ta(r,a);if(l>0&&T==null)break;a=await _(a,T),l++}while(l<C)}return a};t.options.persister?t.fetchFn=()=>{var h,v;return(v=(h=t.options).persister)==null?void 0:v.call(h,u,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=u}}}function Ta(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function Bp(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var Up=(Vd=class{constructor(e={}){M(this,ue);M(this,Rt);M(this,Ot);M(this,kn);M(this,Ln);M(this,It);M(this,Dn);M(this,Nn);I(this,ue,e.queryCache||new Mp),I(this,Rt,e.mutationCache||new Fp),I(this,Ot,e.defaultOptions||{}),I(this,kn,new Map),I(this,Ln,new Map),I(this,It,0)}mount(){Ro(this,It)._++,x(this,It)===1&&(I(this,Dn,Qo.subscribe(async e=>{e&&(await this.resumePausedMutations(),x(this,ue).onFocus())})),I(this,Nn,Tr.subscribe(async e=>{e&&(await this.resumePausedMutations(),x(this,ue).onOnline())})))}unmount(){var e,t;Ro(this,It)._--,x(this,It)===0&&((e=x(this,Dn))==null||e.call(this),I(this,Dn,void 0),(t=x(this,Nn))==null||t.call(this),I(this,Nn,void 0))}isFetching(e){return x(this,ue).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return x(this,Rt).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=x(this,ue).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=x(this,ue).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(yt(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return x(this,ue).findAll(e).map(({queryKey:t,state:n})=>{const r=n.data;return[t,r]})}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),o=x(this,ue).get(r.queryHash),s=o==null?void 0:o.state.data,i=Tp(t,s);if(i!==void 0)return x(this,ue).build(this,r).setData(i,{...n,manual:!0})}setQueriesData(e,t,n){return me.batch(()=>x(this,ue).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=x(this,ue).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=x(this,ue);me.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=x(this,ue);return me.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=me.batch(()=>x(this,ue).findAll(e).map(o=>o.cancel(n)));return Promise.all(r).then(we).catch(we)}invalidateQueries(e,t={}){return me.batch(()=>(x(this,ue).findAll(e).forEach(n=>{n.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=me.batch(()=>x(this,ue).findAll(e).filter(o=>!o.isDisabled()&&!o.isStatic()).map(o=>{let s=o.fetch(void 0,n);return n.throwOnError||(s=s.catch(we)),o.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(r).then(we)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=x(this,ue).build(this,t);return n.isStaleByTime(yt(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(we).catch(we)}fetchInfiniteQuery(e){return e.behavior=Ea(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(we).catch(we)}ensureInfiniteQueryData(e){return e.behavior=Ea(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Tr.isOnline()?x(this,Rt).resumePausedMutations():Promise.resolve()}getQueryCache(){return x(this,ue)}getMutationCache(){return x(this,Rt)}getDefaultOptions(){return x(this,Ot)}setDefaultOptions(e){I(this,Ot,e)}setQueryDefaults(e,t){x(this,kn).set(zt(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...x(this,kn).values()],n={};return t.forEach(r=>{Qn(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){x(this,Ln).set(zt(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...x(this,Ln).values()],n={};return t.forEach(r=>{Qn(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...x(this,Ot).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=zo(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===Er&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...x(this,Ot).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){x(this,ue).clear(),x(this,Rt).clear()}},ue=new WeakMap,Rt=new WeakMap,Ot=new WeakMap,kn=new WeakMap,Ln=new WeakMap,It=new WeakMap,Dn=new WeakMap,Nn=new WeakMap,Vd),Wp=(zd=class extends hn{constructor(t,n){super();M(this,ee);M(this,Te);M(this,K);M(this,dr);M(this,xe);M(this,ln);M(this,Mn);M(this,jt);M(this,kt);M(this,fr);M(this,$n);M(this,Fn);M(this,cn);M(this,un);M(this,Lt);M(this,Bn,new Set);this.options=n,I(this,Te,t),I(this,kt,null),I(this,jt,Yo()),this.options.experimental_prefetchInRender||x(this,jt).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(x(this,K).addObserver(this),Pa(x(this,K),this.options)?V(this,ee,pr).call(this):this.updateResult(),V(this,ee,Ii).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Xo(x(this,K),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Xo(x(this,K),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,V(this,ee,ji).call(this),V(this,ee,ki).call(this),x(this,K).removeObserver(this)}setOptions(t){const n=this.options,r=x(this,K);if(this.options=x(this,Te).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Ne(this.options.enabled,x(this,K))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");V(this,ee,Li).call(this),x(this,K).setOptions(this.options),n._defaulted&&!Sr(this.options,n)&&x(this,Te).getQueryCache().notify({type:"observerOptionsUpdated",query:x(this,K),observer:this});const o=this.hasListeners();o&&Aa(x(this,K),r,this.options,n)&&V(this,ee,pr).call(this),this.updateResult(),o&&(x(this,K)!==r||Ne(this.options.enabled,x(this,K))!==Ne(n.enabled,x(this,K))||yt(this.options.staleTime,x(this,K))!==yt(n.staleTime,x(this,K)))&&V(this,ee,Ai).call(this);const s=V(this,ee,Ri).call(this);o&&(x(this,K)!==r||Ne(this.options.enabled,x(this,K))!==Ne(n.enabled,x(this,K))||s!==x(this,Lt))&&V(this,ee,Oi).call(this,s)}getOptimisticResult(t){const n=x(this,Te).getQueryCache().build(x(this,Te),t),r=this.createResult(n,t);return Vp(this,r)&&(I(this,xe,r),I(this,Mn,this.options),I(this,ln,x(this,K).state)),r}getCurrentResult(){return x(this,xe)}trackResult(t,n){return new Proxy(t,{get:(r,o)=>(this.trackProp(o),n==null||n(o),Reflect.get(r,o))})}trackProp(t){x(this,Bn).add(t)}getCurrentQuery(){return x(this,K)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=x(this,Te).defaultQueryOptions(t),r=x(this,Te).getQueryCache().build(x(this,Te),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return V(this,ee,pr).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),x(this,xe)))}createResult(t,n){var k;const r=x(this,K),o=this.options,s=x(this,xe),i=x(this,ln),a=x(this,Mn),u=t!==r?t.state:x(this,dr),{state:f}=t;let p={...f},m=!1,g;if(n._optimisticResults){const N=this.hasListeners(),U=!N&&Pa(t,n),W=N&&Aa(t,r,n,o);(U||W)&&(p={...p,...Ca(f.data,t.options)}),n._optimisticResults==="isRestoring"&&(p.fetchStatus="idle")}let{error:y,errorUpdatedAt:h,status:v}=p;g=p.data;let b=!1;if(n.placeholderData!==void 0&&g===void 0&&v==="pending"){let N;s!=null&&s.isPlaceholderData&&n.placeholderData===(a==null?void 0:a.placeholderData)?(N=s.data,b=!0):N=typeof n.placeholderData=="function"?n.placeholderData((k=x(this,Fn))==null?void 0:k.state.data,x(this,Fn)):n.placeholderData,N!==void 0&&(v="success",g=Ko(s==null?void 0:s.data,N,n),m=!0)}if(n.select&&g!==void 0&&!b)if(s&&g===(i==null?void 0:i.data)&&n.select===x(this,fr))g=x(this,$n);else try{I(this,fr,n.select),g=n.select(g),g=Ko(s==null?void 0:s.data,g,n),I(this,$n,g),I(this,kt,null)}catch(N){I(this,kt,N)}x(this,kt)&&(y=x(this,kt),g=x(this,$n),h=Date.now(),v="error");const _=p.fetchStatus==="fetching",C=v==="pending",T=v==="error",P=C&&_,A=g!==void 0,D={status:v,fetchStatus:p.fetchStatus,isPending:C,isSuccess:v==="success",isError:T,isInitialLoading:P,isLoading:P,data:g,dataUpdatedAt:p.dataUpdatedAt,error:y,errorUpdatedAt:h,failureCount:p.fetchFailureCount,failureReason:p.fetchFailureReason,errorUpdateCount:p.errorUpdateCount,isFetched:p.dataUpdateCount>0||p.errorUpdateCount>0,isFetchedAfterMount:p.dataUpdateCount>u.dataUpdateCount||p.errorUpdateCount>u.errorUpdateCount,isFetching:_,isRefetching:_&&!C,isLoadingError:T&&!A,isPaused:p.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:T&&A,isStale:Jo(t,n),refetch:this.refetch,promise:x(this,jt)};if(this.options.experimental_prefetchInRender){const N=H=>{D.status==="error"?H.reject(D.error):D.data!==void 0&&H.resolve(D.data)},U=()=>{const H=I(this,jt,D.promise=Yo());N(H)},W=x(this,jt);switch(W.status){case"pending":t.queryHash===r.queryHash&&N(W);break;case"fulfilled":(D.status==="error"||D.data!==W.value)&&U();break;case"rejected":(D.status!=="error"||D.error!==W.reason)&&U();break}}return D}updateResult(){const t=x(this,xe),n=this.createResult(x(this,K),this.options);if(I(this,ln,x(this,K).state),I(this,Mn,this.options),x(this,ln).data!==void 0&&I(this,Fn,x(this,K)),Sr(n,t))return;I(this,xe,n);const r=()=>{if(!t)return!0;const{notifyOnChangeProps:o}=this.options,s=typeof o=="function"?o():o;if(s==="all"||!s&&!x(this,Bn).size)return!0;const i=new Set(s??x(this,Bn));return this.options.throwOnError&&i.add("error"),Object.keys(x(this,xe)).some(a=>{const l=a;return x(this,xe)[l]!==t[l]&&i.has(l)})};V(this,ee,af).call(this,{listeners:r()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&V(this,ee,Ii).call(this)}},Te=new WeakMap,K=new WeakMap,dr=new WeakMap,xe=new WeakMap,ln=new WeakMap,Mn=new WeakMap,jt=new WeakMap,kt=new WeakMap,fr=new WeakMap,$n=new WeakMap,Fn=new WeakMap,cn=new WeakMap,un=new WeakMap,Lt=new WeakMap,Bn=new WeakMap,ee=new WeakSet,pr=function(t){V(this,ee,Li).call(this);let n=x(this,K).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(we)),n},Ai=function(){V(this,ee,ji).call(this);const t=yt(this.options.staleTime,x(this,K));if(Vt||x(this,xe).isStale||!Vo(t))return;const r=fa(x(this,xe).dataUpdatedAt,t)+1;I(this,cn,setTimeout(()=>{x(this,xe).isStale||this.updateResult()},r))},Ri=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(x(this,K)):this.options.refetchInterval)??!1},Oi=function(t){V(this,ee,ki).call(this),I(this,Lt,t),!(Vt||Ne(this.options.enabled,x(this,K))===!1||!Vo(x(this,Lt))||x(this,Lt)===0)&&I(this,un,setInterval(()=>{(this.options.refetchIntervalInBackground||Qo.isFocused())&&V(this,ee,pr).call(this)},x(this,Lt)))},Ii=function(){V(this,ee,Ai).call(this),V(this,ee,Oi).call(this,V(this,ee,Ri).call(this))},ji=function(){x(this,cn)&&(clearTimeout(x(this,cn)),I(this,cn,void 0))},ki=function(){x(this,un)&&(clearInterval(x(this,un)),I(this,un,void 0))},Li=function(){const t=x(this,Te).getQueryCache().build(x(this,Te),this.options);if(t===x(this,K))return;const n=x(this,K);I(this,K,t),I(this,dr,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},af=function(t){me.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(x(this,xe))}),x(this,Te).getQueryCache().notify({query:x(this,K),type:"observerResultsUpdated"})})},zd);function Hp(e,t){return Ne(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function Pa(e,t){return Hp(e,t)||e.state.data!==void 0&&Xo(e,t,t.refetchOnMount)}function Xo(e,t,n){if(Ne(t.enabled,e)!==!1&&yt(t.staleTime,e)!=="static"){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&Jo(e,t)}return!1}function Aa(e,t,n,r){return(e!==t||Ne(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&Jo(e,n)}function Jo(e,t){return Ne(t.enabled,e)!==!1&&e.isStaleByTime(yt(t.staleTime,e))}function Vp(e,t){return!Sr(e.getCurrentResult(),t)}var zp=(Gd=class extends hn{constructor(n,r){super();M(this,pt);M(this,Dt);M(this,Nt);M(this,Pe);M(this,ft);I(this,Dt,n),this.setOptions(r),this.bindMethods(),V(this,pt,Oo).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(n){var o;const r=this.options;this.options=x(this,Dt).defaultMutationOptions(n),Sr(this.options,r)||x(this,Dt).getMutationCache().notify({type:"observerOptionsUpdated",mutation:x(this,Pe),observer:this}),r!=null&&r.mutationKey&&this.options.mutationKey&&zt(r.mutationKey)!==zt(this.options.mutationKey)?this.reset():((o=x(this,Pe))==null?void 0:o.state.status)==="pending"&&x(this,Pe).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=x(this,Pe))==null||n.removeObserver(this)}onMutationUpdate(n){V(this,pt,Oo).call(this),V(this,pt,Di).call(this,n)}getCurrentResult(){return x(this,Nt)}reset(){var n;(n=x(this,Pe))==null||n.removeObserver(this),I(this,Pe,void 0),V(this,pt,Oo).call(this),V(this,pt,Di).call(this)}mutate(n,r){var o;return I(this,ft,r),(o=x(this,Pe))==null||o.removeObserver(this),I(this,Pe,x(this,Dt).getMutationCache().build(x(this,Dt),this.options)),x(this,Pe).addObserver(this),x(this,Pe).execute(n)}},Dt=new WeakMap,Nt=new WeakMap,Pe=new WeakMap,ft=new WeakMap,pt=new WeakSet,Oo=function(){var r;const n=((r=x(this,Pe))==null?void 0:r.state)??Sa();I(this,Nt,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},Di=function(n){me.batch(()=>{var r,o,s,i,a,l,u,f;if(x(this,ft)&&this.hasListeners()){const p=x(this,Nt).variables,m=x(this,Nt).context;(n==null?void 0:n.type)==="success"?((o=(r=x(this,ft)).onSuccess)==null||o.call(r,n.data,p,m),(i=(s=x(this,ft)).onSettled)==null||i.call(s,n.data,null,p,m)):(n==null?void 0:n.type)==="error"&&((l=(a=x(this,ft)).onError)==null||l.call(a,n.error,p,m),(f=(u=x(this,ft)).onSettled)==null||f.call(u,void 0,n.error,p,m))}this.listeners.forEach(p=>{p(x(this,Nt))})})},Gd),Ra=d.createContext(void 0),es=e=>{const t=d.useContext(Ra);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Gp=({client:e,children:t})=>(d.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),c.jsx(Ra.Provider,{value:e,children:t})),Oa=d.createContext(!1),qp=()=>d.useContext(Oa);Oa.Provider;function Kp(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var Qp=d.createContext(Kp()),Yp=()=>d.useContext(Qp),Zp=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},Xp=e=>{d.useEffect(()=>{e.clearReset()},[e])},Jp=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:o})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(o&&e.data===void 0||ya(n,[e.error,r])),eh=e=>{if(e.suspense){const t=r=>r==="static"?r:Math.max(r??1e3,1e3),n=e.staleTime;e.staleTime=typeof n=="function"?(...r)=>t(n(...r)):t(n),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},th=(e,t)=>e.isLoading&&e.isFetching&&!t,nh=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,Ia=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function rh(e,t,n){var p,m,g,y,h;if(typeof e!="object"||Array.isArray(e))throw new Error('Bad argument type. Starting with v5, only the "Object" form is allowed when calling query related functions. Please use the error stack to find the culprit call. More info here: https://tanstack.com/query/latest/docs/react/guides/migrating-to-v5#supports-a-single-signature-one-object');const r=qp(),o=Yp(),s=es(),i=s.defaultQueryOptions(e);(m=(p=s.getDefaultOptions().queries)==null?void 0:p._experimental_beforeQuery)==null||m.call(p,i),i.queryFn||console.error(`[${i.queryHash}]: No queryFn was passed as an option, and no default queryFn was found. The queryFn parameter is only optional when using a default queryFn. More info here: https://tanstack.com/query/latest/docs/framework/react/guides/default-query-function`),i._optimisticResults=r?"isRestoring":"optimistic",eh(i),Zp(i,o),Xp(o);const a=!s.getQueryCache().get(i.queryHash),[l]=d.useState(()=>new t(s,i)),u=l.getOptimisticResult(i),f=!r&&e.subscribed!==!1;if(d.useSyncExternalStore(d.useCallback(v=>{const b=f?l.subscribe(me.batchCalls(v)):we;return l.updateResult(),b},[l,f]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),d.useEffect(()=>{l.setOptions(i)},[i,l]),nh(i,u))throw Ia(i,l,o);if(Jp({result:u,errorResetBoundary:o,throwOnError:i.throwOnError,query:s.getQueryCache().get(i.queryHash),suspense:i.suspense}))throw u.error;if((y=(g=s.getDefaultOptions().queries)==null?void 0:g._experimental_afterQuery)==null||y.call(g,i,u),i.experimental_prefetchInRender&&!Vt&&th(u,r)){const v=a?Ia(i,l,o):(h=s.getQueryCache().get(i.queryHash))==null?void 0:h.promise;v==null||v.catch(we).finally(()=>{l.updateResult()})}return i.notifyOnChangeProps?u:l.trackResult(u)}function ja(e,t){return rh(e,Wp)}function Ar(e,t){const n=es(),[r]=d.useState(()=>new zp(n,e));d.useEffect(()=>{r.setOptions(e)},[r,e]);const o=d.useSyncExternalStore(d.useCallback(i=>r.subscribe(me.batchCalls(i)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),s=d.useCallback((i,a)=>{r.mutate(i,a).catch(we)},[r]);if(o.error&&ya(r.options.throwOnError,[o.error]))throw o.error;return{...o,mutate:s,mutateAsync:o.mutate}}const oh=e=>{const t=new Up;return function(r){if(!r)throw new Error("Microfrontend did not receive any properties !!");const o=No(r.module.name);return c.jsx(Vi,{module:o,children:c.jsxs(Gp,{client:t,children:[c.jsx(e,{...r}),c.jsx(Ep,{position:"top-right",reverseOrder:!0})]})})}};function ka(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=ka(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function L(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=ka(e))&&(r&&(r+=" "),r+=t);return r}const Rr={spinner:"spinner__fakUN","spinner-rotation":"spinner-rotation__wUmPV",spinnerRotation:"spinner-rotation__wUmPV",button:"button__8FA9H","button--contained-primary":"button--contained-primary__stkTx",buttonContainedPrimary:"button--contained-primary__stkTx","button--outlined-primary":"button--outlined-primary__KZ1ww",buttonOutlinedPrimary:"button--outlined-primary__KZ1ww","button--text-primary":"button--text-primary__GLTfm",buttonTextPrimary:"button--text-primary__GLTfm","button--contained-danger":"button--contained-danger__L9ehT",buttonContainedDanger:"button--contained-danger__L9ehT","button--outlined-danger":"button--outlined-danger__eoYLd",buttonOutlinedDanger:"button--outlined-danger__eoYLd","button--text-danger":"button--text-danger__Sw-ha",buttonTextDanger:"button--text-danger__Sw-ha",icon:"icon__--umH"},Or=S.forwardRef(({variant:e="contained",colorScheme:t="primary",loading:n=!1,IconComponent:r,className:o,children:s,...i},a)=>{const l=L(Rr.button,Rr[`button--${e}-${t}`],o);return c.jsxs("button",{ref:a,className:l,...i,children:[n?c.jsx("div",{className:Rr.spinner}):r&&c.jsx(r,{className:Rr.icon}),s]})});Or.displayName="Button";const Ir={Badges:"Badges__5jpum",badges:"Badges__5jpum",Badge:"Badge__95MWM",badge:"Badge__95MWM","Badge--primary":"Badge--primary__Rx-bS",badgePrimary:"Badge--primary__Rx-bS","Badge--secondary":"Badge--secondary__d92bT",badgeSecondary:"Badge--secondary__d92bT","Badge--success":"Badge--success__Kdo98",badgeSuccess:"Badge--success__Kdo98","Badge--warning":"Badge--warning__bf-Nn",badgeWarning:"Badge--warning__bf-Nn","Badge--danger":"Badge--danger__HTj39",badgeDanger:"Badge--danger__HTj39","Badge--small":"Badge--small__y93Pj",badgeSmall:"Badge--small__y93Pj","Badge--regular":"Badge--regular__aT5AL",badgeRegular:"Badge--regular__aT5AL","Badge--large":"Badge--large__wORCH",badgeLarge:"Badge--large__wORCH"},ts={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};for(const e in ts)Object.freeze(ts[e]);const La=Object.freeze(ts);var Da={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};function sh(e){var f,p;var t,n=[],r=1,o;if(typeof e=="number")return{space:"rgb",values:[e>>>16,(e&65280)>>>8,e&255],alpha:1};if(typeof e=="number")return{space:"rgb",values:[e>>>16,(e&65280)>>>8,e&255],alpha:1};if(e=String(e).toLowerCase(),La[e])n=La[e].slice(),o="rgb";else if(e==="transparent")r=0,o="rgb",n=[0,0,0];else if(e[0]==="#"){var s=e.slice(1),i=s.length,a=i<=4;r=1,a?(n=[parseInt(s[0]+s[0],16),parseInt(s[1]+s[1],16),parseInt(s[2]+s[2],16)],i===4&&(r=parseInt(s[3]+s[3],16)/255)):(n=[parseInt(s[0]+s[1],16),parseInt(s[2]+s[3],16),parseInt(s[4]+s[5],16)],i===8&&(r=parseInt(s[6]+s[7],16)/255)),n[0]||(n[0]=0),n[1]||(n[1]=0),n[2]||(n[2]=0),o="rgb"}else if(t=/^((?:rgba?|hs[lvb]a?|hwba?|cmyk?|xy[zy]|gray|lab|lchu?v?|[ly]uv|lms|oklch|oklab|color))\s*\(([^\)]*)\)/.exec(e)){var l=t[1];o=l.replace(/a$/,"");var u=o==="cmyk"?4:o==="gray"?1:3;n=t[2].trim().split(/\s*[,\/]\s*|\s+/),o==="color"&&(o=n.shift()),n=n.map(function(m,g){if(m[m.length-1]==="%")return m=parseFloat(m)/100,g===3?m:o==="rgb"?m*255:o[0]==="h"||o[0]==="l"&&!g?m*100:o==="lab"?m*125:o==="lch"?g<2?m*150:m*360:o[0]==="o"&&!g?m:o==="oklab"?m*.4:o==="oklch"?g<2?m*.4:m*360:m;if(o[g]==="h"||g===2&&o[o.length-1]==="h"){if(Da[m]!==void 0)return Da[m];if(m.endsWith("deg"))return parseFloat(m);if(m.endsWith("turn"))return parseFloat(m)*360;if(m.endsWith("grad"))return parseFloat(m)*360/400;if(m.endsWith("rad"))return parseFloat(m)*180/Math.PI}return m==="none"?0:parseFloat(m)}),r=n.length>u?n.pop():1}else/[0-9](?:\s|\/|,)/.test(e)&&(n=e.match(/([0-9]+)/g).map(function(m){return parseFloat(m)}),o=((p=(f=e.match(/([a-z])/ig))==null?void 0:f.join(""))==null?void 0:p.toLowerCase())||"rgb");return{space:o,values:n,alpha:r}}const ih=(e,t)=>{const{space:n,values:r}=sh(e);return n[0]==="h"?`${n}a(${r[0]}, ${r[1]}%, ${r[2]}%, ${t})`:`${n}a(${r}, ${t})`},ns=S.forwardRef(({children:e,color:t,className:n,customColor:r,size:o="small",style:s,...i},a)=>{const l=r?{color:r,background:ih(r,.1)}:{},u=L(Ir.Badge,Ir[`Badge--${o}`],{[Ir[`Badge--${t}`]]:!!t},n);return c.jsx("span",{ref:a,className:u,style:{...s,...l},...i,children:e})});ns.displayName="Badge";const rs=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ir.Badges,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});rs.displayName="Badges";const Na=({size:e=24,color:t="currentColor",strokeWidth:n=2,className:r,style:o,...s})=>c.jsxs("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"none",stroke:t,strokeWidth:n,strokeLinecap:"round",strokeLinejoin:"round",className:r,style:o,...s,children:[c.jsx("rect",{x:"8",y:"2",width:"8",height:"4",rx:"1",ry:"1"}),c.jsx("path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2"})]}),Ma=({size:e=24,color:t="currentColor",strokeWidth:n=2,className:r,style:o,...s})=>c.jsxs("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"none",stroke:t,strokeWidth:n,strokeLinecap:"round",strokeLinejoin:"round",className:r,style:o,...s,children:[c.jsx("rect",{x:"8",y:"2",width:"8",height:"4",rx:"1",ry:"1"}),c.jsx("path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2"}),c.jsx("path",{d:"m9 12 2 2 4-4"})]}),ah={CopyToClipboardButton:"CopyToClipboardButton__2Nd2m"},lh=({content:e})=>{const[t,n]=ch(),{notify:r}=pi(),o=t?Ma:Na,s=S.useCallback(async()=>{await n(e)&&r("Copied to the Clipboard !","success")},[e,r]);return c.jsx(o,{className:ah.CopyToClipboardButton,size:18,onClick:s})},ch=()=>{const[e,t]=S.useState(!1);return[e,async r=>{var o;try{return await((o=navigator==null?void 0:navigator.clipboard)==null?void 0:o.writeText(r)),t(!0),setTimeout(()=>t(!1),2e3),!0}catch(s){return console.error("Failed to copy text: ",s),!1}}]},$a={FieldGroup:"FieldGroup__Q2JCV",fieldGroup:"FieldGroup__Q2JCV","FieldGroup--horizontal":"FieldGroup--horizontal__kpfL1",fieldGroupHorizontal:"FieldGroup--horizontal__kpfL1","FieldGroup--vertical":"FieldGroup--vertical__FLo-Q",fieldGroupVertical:"FieldGroup--vertical__FLo-Q"},Fa=S.forwardRef(({children:e,className:t,orientation:n="vertical",...r},o)=>{const s=L($a.FieldGroup,$a[`FieldGroup--${n}`],t);return c.jsx("div",{ref:o,className:s,...r,children:e})});Fa.displayName="FieldGroup";const Ba={Input:"Input__uS0sb",Error:"Error__-DQpw"},jr=S.forwardRef(({className:e,error:t,...n},r)=>{const o=L(Ba.Input,t&&Ba.Error,e);return c.jsx("input",{ref:r,className:o,...n})});jr.displayName="Input";const uh={Error:"Error__N4OP5"},Ua=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(uh.Error,t);return c.jsx("span",{ref:r,className:o,...n,children:e})});Ua.displayName="InputError";const Wa={Label:"Label__VYUvW",Error:"Error__Eu6DI"},Ha=S.forwardRef(({children:e,className:t,error:n,...r},o)=>{const s=L(Wa.Label,n&&Wa.Error,t);return c.jsx("label",{ref:o,className:s,...r,children:e})});Ha.displayName="Label";const os={Select:"Select__giqpe",Chevron:"Chevron__YvhBd"},Va=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(os.Option,t);return c.jsx("option",{ref:r,className:o,...n,children:e})});Va.displayName="Option";const ss=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(os.Select,t);return c.jsxs("div",{className:o,children:[c.jsx("select",{ref:r,...n,children:e}),c.jsx("div",{className:os.Chevron,children:c.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M4 6L8 10L12 6",stroke:"#818181",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})})})]})});ss.displayName="Select",ss.Option=Va;function za(e,[t,n]){return Math.min(n,Math.max(t,e))}function Z(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function dh(e,t){const n=d.createContext(t),r=s=>{const{children:i,...a}=s,l=d.useMemo(()=>a,Object.values(a));return c.jsx(n.Provider,{value:l,children:i})};r.displayName=e+"Provider";function o(s){const i=d.useContext(n);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[r,o]}function Yn(e,t=[]){let n=[];function r(s,i){const a=d.createContext(i),l=n.length;n=[...n,i];const u=p=>{var b;const{scope:m,children:g,...y}=p,h=((b=m==null?void 0:m[e])==null?void 0:b[l])||a,v=d.useMemo(()=>y,Object.values(y));return c.jsx(h.Provider,{value:v,children:g})};u.displayName=s+"Provider";function f(p,m){var h;const g=((h=m==null?void 0:m[e])==null?void 0:h[l])||a,y=d.useContext(g);if(y)return y;if(i!==void 0)return i;throw new Error(`\`${p}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(i=>d.createContext(i));return function(a){const l=(a==null?void 0:a[e])||s;return d.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return o.scopeName=e,[r,fh(o,...t)]}function fh(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const i=r.reduce((a,{useScope:l,scopeName:u})=>{const p=l(s)[`__scope${u}`];return{...a,...p}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function Ga(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function mn(...e){return t=>{let n=!1;const r=e.map(o=>{const s=Ga(o,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let o=0;o<r.length;o++){const s=r[o];typeof s=="function"?s():Ga(e[o],null)}}}}function le(...e){return d.useCallback(mn(...e),e)}function qa(e){const t=ph(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),l=a.find(mh);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function ph(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=vh(o),a=gh(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var hh=Symbol("radix.slottable");function mh(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===hh}function gh(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function vh(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function yh(e){const t=e+"CollectionProvider",[n,r]=Yn(t),[o,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=h=>{const{scope:v,children:b}=h,_=S.useRef(null),C=S.useRef(new Map).current;return c.jsx(o,{scope:v,itemMap:C,collectionRef:_,children:b})};i.displayName=t;const a=e+"CollectionSlot",l=qa(a),u=S.forwardRef((h,v)=>{const{scope:b,children:_}=h,C=s(a,b),T=le(v,C.collectionRef);return c.jsx(l,{ref:T,children:_})});u.displayName=a;const f=e+"CollectionItemSlot",p="data-radix-collection-item",m=qa(f),g=S.forwardRef((h,v)=>{const{scope:b,children:_,...C}=h,T=S.useRef(null),P=le(v,T),A=s(f,b);return S.useEffect(()=>(A.itemMap.set(T,{ref:T,...C}),()=>void A.itemMap.delete(T))),c.jsx(m,{[p]:"",ref:P,children:_})});g.displayName=f;function y(h){const v=s(e+"CollectionConsumer",h);return S.useCallback(()=>{const _=v.collectionRef.current;if(!_)return[];const C=Array.from(_.querySelectorAll(`[${p}]`));return Array.from(v.itemMap.values()).sort((A,R)=>C.indexOf(A.ref.current)-C.indexOf(R.ref.current))},[v.collectionRef,v.itemMap])}return[{Provider:i,Slot:u,ItemSlot:g},y,r]}var bh=d.createContext(void 0);function wh(e){const t=d.useContext(bh);return e||t||"ltr"}function _h(e){const t=xh(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),l=a.find(Sh);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function xh(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=Th(o),a=Eh(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Ch=Symbol("radix.slottable");function Sh(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Ch}function Eh(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Th(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Ph=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ie=Ph.reduce((e,t)=>{const n=_h(`Primitive.${t}`),r=d.forwardRef((o,s)=>{const{asChild:i,...a}=o,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),c.jsx(l,{...a,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Ah(e,t){e&&mr.flushSync(()=>e.dispatchEvent(t))}function Gt(e){const t=d.useRef(e);return d.useEffect(()=>{t.current=e}),d.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function Rh(e,t=globalThis==null?void 0:globalThis.document){const n=Gt(e);d.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var Oh="DismissableLayer",is="dismissableLayer.update",Ih="dismissableLayer.pointerDownOutside",jh="dismissableLayer.focusOutside",Ka,Qa=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),kr=d.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:i,onDismiss:a,...l}=e,u=d.useContext(Qa),[f,p]=d.useState(null),m=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,g]=d.useState({}),y=le(t,R=>p(R)),h=Array.from(u.layers),[v]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),b=h.indexOf(v),_=f?h.indexOf(f):-1,C=u.layersWithOutsidePointerEventsDisabled.size>0,T=_>=b,P=Dh(R=>{const D=R.target,k=[...u.branches].some(N=>N.contains(D));!T||k||(o==null||o(R),i==null||i(R),R.defaultPrevented||a==null||a())},m),A=Nh(R=>{const D=R.target;[...u.branches].some(N=>N.contains(D))||(s==null||s(R),i==null||i(R),R.defaultPrevented||a==null||a())},m);return Rh(R=>{_===u.layers.size-1&&(r==null||r(R),!R.defaultPrevented&&a&&(R.preventDefault(),a()))},m),d.useEffect(()=>{if(f)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Ka=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(f)),u.layers.add(f),Ya(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=Ka)}},[f,m,n,u]),d.useEffect(()=>()=>{f&&(u.layers.delete(f),u.layersWithOutsidePointerEventsDisabled.delete(f),Ya())},[f,u]),d.useEffect(()=>{const R=()=>g({});return document.addEventListener(is,R),()=>document.removeEventListener(is,R)},[]),c.jsx(ie.div,{...l,ref:y,style:{pointerEvents:C?T?"auto":"none":void 0,...e.style},onFocusCapture:Z(e.onFocusCapture,A.onFocusCapture),onBlurCapture:Z(e.onBlurCapture,A.onBlurCapture),onPointerDownCapture:Z(e.onPointerDownCapture,P.onPointerDownCapture)})});kr.displayName=Oh;var kh="DismissableLayerBranch",Lh=d.forwardRef((e,t)=>{const n=d.useContext(Qa),r=d.useRef(null),o=le(t,r);return d.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),c.jsx(ie.div,{...e,ref:o})});Lh.displayName=kh;function Dh(e,t=globalThis==null?void 0:globalThis.document){const n=Gt(e),r=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const s=a=>{if(a.target&&!r.current){let l=function(){Za(Ih,n,u,{discrete:!0})};const u={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=l,t.addEventListener("click",o.current,{once:!0})):l()}else t.removeEventListener("click",o.current);r.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",s),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function Nh(e,t=globalThis==null?void 0:globalThis.document){const n=Gt(e),r=d.useRef(!1);return d.useEffect(()=>{const o=s=>{s.target&&!r.current&&Za(jh,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Ya(){const e=new CustomEvent(is);document.dispatchEvent(e)}function Za(e,t,n,{discrete:r}){const o=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Ah(o,s):o.dispatchEvent(s)}var as=0;function Xa(){d.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Ja()),document.body.insertAdjacentElement("beforeend",e[1]??Ja()),as++,()=>{as===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),as--}},[])}function Ja(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var ls="focusScope.autoFocusOnMount",cs="focusScope.autoFocusOnUnmount",el={bubbles:!1,cancelable:!0},Mh="FocusScope",us=d.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...i}=e,[a,l]=d.useState(null),u=Gt(o),f=Gt(s),p=d.useRef(null),m=le(t,h=>l(h)),g=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let h=function(C){if(g.paused||!a)return;const T=C.target;a.contains(T)?p.current=T:bt(p.current,{select:!0})},v=function(C){if(g.paused||!a)return;const T=C.relatedTarget;T!==null&&(a.contains(T)||bt(p.current,{select:!0}))},b=function(C){if(document.activeElement===document.body)for(const P of C)P.removedNodes.length>0&&bt(a)};document.addEventListener("focusin",h),document.addEventListener("focusout",v);const _=new MutationObserver(b);return a&&_.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",h),document.removeEventListener("focusout",v),_.disconnect()}}},[r,a,g.paused]),d.useEffect(()=>{if(a){rl.add(g);const h=document.activeElement;if(!a.contains(h)){const b=new CustomEvent(ls,el);a.addEventListener(ls,u),a.dispatchEvent(b),b.defaultPrevented||($h(Hh(tl(a)),{select:!0}),document.activeElement===h&&bt(a))}return()=>{a.removeEventListener(ls,u),setTimeout(()=>{const b=new CustomEvent(cs,el);a.addEventListener(cs,f),a.dispatchEvent(b),b.defaultPrevented||bt(h??document.body,{select:!0}),a.removeEventListener(cs,f),rl.remove(g)},0)}}},[a,u,f,g]);const y=d.useCallback(h=>{if(!n&&!r||g.paused)return;const v=h.key==="Tab"&&!h.altKey&&!h.ctrlKey&&!h.metaKey,b=document.activeElement;if(v&&b){const _=h.currentTarget,[C,T]=Fh(_);C&&T?!h.shiftKey&&b===T?(h.preventDefault(),n&&bt(C,{select:!0})):h.shiftKey&&b===C&&(h.preventDefault(),n&&bt(T,{select:!0})):b===_&&h.preventDefault()}},[n,r,g.paused]);return c.jsx(ie.div,{tabIndex:-1,...i,ref:m,onKeyDown:y})});us.displayName=Mh;function $h(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(bt(r,{select:t}),document.activeElement!==n)return}function Fh(e){const t=tl(e),n=nl(t,e),r=nl(t.reverse(),e);return[n,r]}function tl(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function nl(e,t){for(const n of e)if(!Bh(n,{upTo:t}))return n}function Bh(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function Uh(e){return e instanceof HTMLInputElement&&"select"in e}function bt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Uh(e)&&t&&e.select()}}var rl=Wh();function Wh(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=ol(e,t),e.unshift(t)},remove(t){var n;e=ol(e,t),(n=e[0])==null||n.resume()}}}function ol(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Hh(e){return e.filter(t=>t.tagName!=="A")}var ve=globalThis!=null&&globalThis.document?d.useLayoutEffect:()=>{},Vh=d[" useId ".trim().toString()]||(()=>{}),zh=0;function qt(e){const[t,n]=d.useState(Vh());return ve(()=>{n(r=>r??String(zh++))},[e]),e||(t?`radix-${t}`:"")}const Gh=["top","right","bottom","left"],wt=Math.min,Oe=Math.max,Lr=Math.round,Dr=Math.floor,Ge=e=>({x:e,y:e}),qh={left:"right",right:"left",bottom:"top",top:"bottom"},Kh={start:"end",end:"start"};function ds(e,t,n){return Oe(e,wt(t,n))}function at(e,t){return typeof e=="function"?e(t):e}function lt(e){return e.split("-")[0]}function gn(e){return e.split("-")[1]}function fs(e){return e==="x"?"y":"x"}function ps(e){return e==="y"?"height":"width"}const Qh=new Set(["top","bottom"]);function qe(e){return Qh.has(lt(e))?"y":"x"}function hs(e){return fs(qe(e))}function Yh(e,t,n){n===void 0&&(n=!1);const r=gn(e),o=hs(e),s=ps(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Nr(i)),[i,Nr(i)]}function Zh(e){const t=Nr(e);return[ms(e),t,ms(t)]}function ms(e){return e.replace(/start|end/g,t=>Kh[t])}const sl=["left","right"],il=["right","left"],Xh=["top","bottom"],Jh=["bottom","top"];function em(e,t,n){switch(e){case"top":case"bottom":return n?t?il:sl:t?sl:il;case"left":case"right":return t?Xh:Jh;default:return[]}}function tm(e,t,n,r){const o=gn(e);let s=em(lt(e),n==="start",r);return o&&(s=s.map(i=>i+"-"+o),t&&(s=s.concat(s.map(ms)))),s}function Nr(e){return e.replace(/left|right|bottom|top/g,t=>qh[t])}function nm(e){return{top:0,right:0,bottom:0,left:0,...e}}function al(e){return typeof e!="number"?nm(e):{top:e,right:e,bottom:e,left:e}}function Mr(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function ll(e,t,n){let{reference:r,floating:o}=e;const s=qe(t),i=hs(t),a=ps(i),l=lt(t),u=s==="y",f=r.x+r.width/2-o.width/2,p=r.y+r.height/2-o.height/2,m=r[a]/2-o[a]/2;let g;switch(l){case"top":g={x:f,y:r.y-o.height};break;case"bottom":g={x:f,y:r.y+r.height};break;case"right":g={x:r.x+r.width,y:p};break;case"left":g={x:r.x-o.width,y:p};break;default:g={x:r.x,y:r.y}}switch(gn(t)){case"start":g[i]-=m*(n&&u?-1:1);break;case"end":g[i]+=m*(n&&u?-1:1);break}return g}async function rm(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:s,rects:i,elements:a,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:f="viewport",elementContext:p="floating",altBoundary:m=!1,padding:g=0}=at(t,e),y=al(g),v=a[m?p==="floating"?"reference":"floating":p],b=Mr(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(v)))==null||n?v:v.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:u,rootBoundary:f,strategy:l})),_=p==="floating"?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,C=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),T=await(s.isElement==null?void 0:s.isElement(C))?await(s.getScale==null?void 0:s.getScale(C))||{x:1,y:1}:{x:1,y:1},P=Mr(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:_,offsetParent:C,strategy:l}):_);return{top:(b.top-P.top+y.top)/T.y,bottom:(P.bottom-b.bottom+y.bottom)/T.y,left:(b.left-P.left+y.left)/T.x,right:(P.right-b.right+y.right)/T.x}}const om=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:i}=n,a=s.filter(Boolean),l=await(i.isRTL==null?void 0:i.isRTL(t));let u=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:p}=ll(u,r,l),m=r,g={},y=0;for(let v=0;v<a.length;v++){var h;const{name:b,fn:_}=a[v],{x:C,y:T,data:P,reset:A}=await _({x:f,y:p,initialPlacement:r,placement:m,strategy:o,middlewareData:g,rects:u,platform:{...i,detectOverflow:(h=i.detectOverflow)!=null?h:rm},elements:{reference:e,floating:t}});f=C??f,p=T??p,g={...g,[b]:{...g[b],...P}},A&&y<=50&&(y++,typeof A=="object"&&(A.placement&&(m=A.placement),A.rects&&(u=A.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):A.rects),{x:f,y:p}=ll(u,m,l)),v=-1)}return{x:f,y:p,placement:m,strategy:o,middlewareData:g}},sm=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:i,elements:a,middlewareData:l}=t,{element:u,padding:f=0}=at(e,t)||{};if(u==null)return{};const p=al(f),m={x:n,y:r},g=hs(o),y=ps(g),h=await i.getDimensions(u),v=g==="y",b=v?"top":"left",_=v?"bottom":"right",C=v?"clientHeight":"clientWidth",T=s.reference[y]+s.reference[g]-m[g]-s.floating[y],P=m[g]-s.reference[g],A=await(i.getOffsetParent==null?void 0:i.getOffsetParent(u));let R=A?A[C]:0;(!R||!await(i.isElement==null?void 0:i.isElement(A)))&&(R=a.floating[C]||s.floating[y]);const D=T/2-P/2,k=R/2-h[y]/2-1,N=wt(p[b],k),U=wt(p[_],k),W=N,H=R-h[y]-U,z=R/2-h[y]/2+D,oe=ds(W,z,H),G=!l.arrow&&gn(o)!=null&&z!==oe&&s.reference[y]/2-(z<W?N:U)-h[y]/2<0,Y=G?z<W?z-W:z-H:0;return{[g]:m[g]+Y,data:{[g]:oe,centerOffset:z-oe-Y,...G&&{alignmentOffset:Y}},reset:G}}}),im=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:s,rects:i,initialPlacement:a,platform:l,elements:u}=t,{mainAxis:f=!0,crossAxis:p=!0,fallbackPlacements:m,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:h=!0,...v}=at(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const b=lt(o),_=qe(a),C=lt(a)===a,T=await(l.isRTL==null?void 0:l.isRTL(u.floating)),P=m||(C||!h?[Nr(a)]:Zh(a)),A=y!=="none";!m&&A&&P.push(...tm(a,h,y,T));const R=[a,...P],D=await l.detectOverflow(t,v),k=[];let N=((r=s.flip)==null?void 0:r.overflows)||[];if(f&&k.push(D[b]),p){const z=Yh(o,i,T);k.push(D[z[0]],D[z[1]])}if(N=[...N,{placement:o,overflows:k}],!k.every(z=>z<=0)){var U,W;const z=(((U=s.flip)==null?void 0:U.index)||0)+1,oe=R[z];if(oe&&(!(p==="alignment"?_!==qe(oe):!1)||N.every(F=>qe(F.placement)===_?F.overflows[0]>0:!0)))return{data:{index:z,overflows:N},reset:{placement:oe}};let G=(W=N.filter(Y=>Y.overflows[0]<=0).sort((Y,F)=>Y.overflows[1]-F.overflows[1])[0])==null?void 0:W.placement;if(!G)switch(g){case"bestFit":{var H;const Y=(H=N.filter(F=>{if(A){const se=qe(F.placement);return se===_||se==="y"}return!0}).map(F=>[F.placement,F.overflows.filter(se=>se>0).reduce((se,ge)=>se+ge,0)]).sort((F,se)=>F[1]-se[1])[0])==null?void 0:H[0];Y&&(G=Y);break}case"initialPlacement":G=a;break}if(o!==G)return{reset:{placement:G}}}return{}}}};function cl(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ul(e){return Gh.some(t=>e[t]>=0)}const am=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n,platform:r}=t,{strategy:o="referenceHidden",...s}=at(e,t);switch(o){case"referenceHidden":{const i=await r.detectOverflow(t,{...s,elementContext:"reference"}),a=cl(i,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:ul(a)}}}case"escaped":{const i=await r.detectOverflow(t,{...s,altBoundary:!0}),a=cl(i,n.floating);return{data:{escapedOffsets:a,escaped:ul(a)}}}default:return{}}}}},dl=new Set(["left","top"]);async function lm(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=lt(n),a=gn(n),l=qe(n)==="y",u=dl.has(i)?-1:1,f=s&&l?-1:1,p=at(t,e);let{mainAxis:m,crossAxis:g,alignmentAxis:y}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return a&&typeof y=="number"&&(g=a==="end"?y*-1:y),l?{x:g*f,y:m*u}:{x:m*u,y:g*f}}const cm=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:s,placement:i,middlewareData:a}=t,l=await lm(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:o+l.x,y:s+l.y,data:{...l,placement:i}}}}},um=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o,platform:s}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:l={fn:b=>{let{x:_,y:C}=b;return{x:_,y:C}}},...u}=at(e,t),f={x:n,y:r},p=await s.detectOverflow(t,u),m=qe(lt(o)),g=fs(m);let y=f[g],h=f[m];if(i){const b=g==="y"?"top":"left",_=g==="y"?"bottom":"right",C=y+p[b],T=y-p[_];y=ds(C,y,T)}if(a){const b=m==="y"?"top":"left",_=m==="y"?"bottom":"right",C=h+p[b],T=h-p[_];h=ds(C,h,T)}const v=l.fn({...t,[g]:y,[m]:h});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[g]:i,[m]:a}}}}}},dm=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:s,middlewareData:i}=t,{offset:a=0,mainAxis:l=!0,crossAxis:u=!0}=at(e,t),f={x:n,y:r},p=qe(o),m=fs(p);let g=f[m],y=f[p];const h=at(a,t),v=typeof h=="number"?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(l){const C=m==="y"?"height":"width",T=s.reference[m]-s.floating[C]+v.mainAxis,P=s.reference[m]+s.reference[C]-v.mainAxis;g<T?g=T:g>P&&(g=P)}if(u){var b,_;const C=m==="y"?"width":"height",T=dl.has(lt(o)),P=s.reference[p]-s.floating[C]+(T&&((b=i.offset)==null?void 0:b[p])||0)+(T?0:v.crossAxis),A=s.reference[p]+s.reference[C]+(T?0:((_=i.offset)==null?void 0:_[p])||0)-(T?v.crossAxis:0);y<P?y=P:y>A&&(y=A)}return{[m]:g,[p]:y}}}},fm=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:s,platform:i,elements:a}=t,{apply:l=()=>{},...u}=at(e,t),f=await i.detectOverflow(t,u),p=lt(o),m=gn(o),g=qe(o)==="y",{width:y,height:h}=s.floating;let v,b;p==="top"||p==="bottom"?(v=p,b=m===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(b=p,v=m==="end"?"top":"bottom");const _=h-f.top-f.bottom,C=y-f.left-f.right,T=wt(h-f[v],_),P=wt(y-f[b],C),A=!t.middlewareData.shift;let R=T,D=P;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=C),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(R=_),A&&!m){const N=Oe(f.left,0),U=Oe(f.right,0),W=Oe(f.top,0),H=Oe(f.bottom,0);g?D=y-2*(N!==0||U!==0?N+U:Oe(f.left,f.right)):R=h-2*(W!==0||H!==0?W+H:Oe(f.top,f.bottom))}await l({...t,availableWidth:D,availableHeight:R});const k=await i.getDimensions(a.floating);return y!==k.width||h!==k.height?{reset:{rects:!0}}:{}}}};function $r(){return typeof window<"u"}function vn(e){return fl(e)?(e.nodeName||"").toLowerCase():"#document"}function Ie(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ke(e){var t;return(t=(fl(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function fl(e){return $r()?e instanceof Node||e instanceof Ie(e).Node:!1}function Me(e){return $r()?e instanceof Element||e instanceof Ie(e).Element:!1}function Qe(e){return $r()?e instanceof HTMLElement||e instanceof Ie(e).HTMLElement:!1}function pl(e){return!$r()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ie(e).ShadowRoot}const pm=new Set(["inline","contents"]);function Zn(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=$e(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!pm.has(o)}const hm=new Set(["table","td","th"]);function mm(e){return hm.has(vn(e))}const gm=[":popover-open",":modal"];function Fr(e){return gm.some(t=>{try{return e.matches(t)}catch{return!1}})}const vm=["transform","translate","scale","rotate","perspective"],ym=["transform","translate","scale","rotate","perspective","filter"],bm=["paint","layout","strict","content"];function gs(e){const t=vs(),n=Me(e)?$e(e):e;return vm.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||ym.some(r=>(n.willChange||"").includes(r))||bm.some(r=>(n.contain||"").includes(r))}function wm(e){let t=_t(e);for(;Qe(t)&&!yn(t);){if(gs(t))return t;if(Fr(t))return null;t=_t(t)}return null}function vs(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const _m=new Set(["html","body","#document"]);function yn(e){return _m.has(vn(e))}function $e(e){return Ie(e).getComputedStyle(e)}function Br(e){return Me(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function _t(e){if(vn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||pl(e)&&e.host||Ke(e);return pl(t)?t.host:t}function hl(e){const t=_t(e);return yn(t)?e.ownerDocument?e.ownerDocument.body:e.body:Qe(t)&&Zn(t)?t:hl(t)}function Xn(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=hl(e),s=o===((r=e.ownerDocument)==null?void 0:r.body),i=Ie(o);if(s){const a=ys(i);return t.concat(i,i.visualViewport||[],Zn(o)?o:[],a&&n?Xn(a):[])}return t.concat(o,Xn(o,[],n))}function ys(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ml(e){const t=$e(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Qe(e),s=o?e.offsetWidth:n,i=o?e.offsetHeight:r,a=Lr(n)!==s||Lr(r)!==i;return a&&(n=s,r=i),{width:n,height:r,$:a}}function bs(e){return Me(e)?e:e.contextElement}function bn(e){const t=bs(e);if(!Qe(t))return Ge(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=ml(t);let i=(s?Lr(n.width):n.width)/r,a=(s?Lr(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const xm=Ge(0);function gl(e){const t=Ie(e);return!vs()||!t.visualViewport?xm:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Cm(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ie(e)?!1:t}function Kt(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=bs(e);let i=Ge(1);t&&(r?Me(r)&&(i=bn(r)):i=bn(e));const a=Cm(s,n,r)?gl(s):Ge(0);let l=(o.left+a.x)/i.x,u=(o.top+a.y)/i.y,f=o.width/i.x,p=o.height/i.y;if(s){const m=Ie(s),g=r&&Me(r)?Ie(r):r;let y=m,h=ys(y);for(;h&&r&&g!==y;){const v=bn(h),b=h.getBoundingClientRect(),_=$e(h),C=b.left+(h.clientLeft+parseFloat(_.paddingLeft))*v.x,T=b.top+(h.clientTop+parseFloat(_.paddingTop))*v.y;l*=v.x,u*=v.y,f*=v.x,p*=v.y,l+=C,u+=T,y=Ie(h),h=ys(y)}}return Mr({width:f,height:p,x:l,y:u})}function Ur(e,t){const n=Br(e).scrollLeft;return t?t.left+n:Kt(Ke(e)).left+n}function vl(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-Ur(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function Sm(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",i=Ke(r),a=t?Fr(t.floating):!1;if(r===i||a&&s)return n;let l={scrollLeft:0,scrollTop:0},u=Ge(1);const f=Ge(0),p=Qe(r);if((p||!p&&!s)&&((vn(r)!=="body"||Zn(i))&&(l=Br(r)),Qe(r))){const g=Kt(r);u=bn(r),f.x=g.x+r.clientLeft,f.y=g.y+r.clientTop}const m=i&&!p&&!s?vl(i,l):Ge(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+f.x+m.x,y:n.y*u.y-l.scrollTop*u.y+f.y+m.y}}function Em(e){return Array.from(e.getClientRects())}function Tm(e){const t=Ke(e),n=Br(e),r=e.ownerDocument.body,o=Oe(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=Oe(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+Ur(e);const a=-n.scrollTop;return $e(r).direction==="rtl"&&(i+=Oe(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:i,y:a}}const yl=25;function Pm(e,t){const n=Ie(e),r=Ke(e),o=n.visualViewport;let s=r.clientWidth,i=r.clientHeight,a=0,l=0;if(o){s=o.width,i=o.height;const f=vs();(!f||f&&t==="fixed")&&(a=o.offsetLeft,l=o.offsetTop)}const u=Ur(r);if(u<=0){const f=r.ownerDocument,p=f.body,m=getComputedStyle(p),g=f.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,y=Math.abs(r.clientWidth-p.clientWidth-g);y<=yl&&(s-=y)}else u<=yl&&(s+=u);return{width:s,height:i,x:a,y:l}}const Am=new Set(["absolute","fixed"]);function Rm(e,t){const n=Kt(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=Qe(e)?bn(e):Ge(1),i=e.clientWidth*s.x,a=e.clientHeight*s.y,l=o*s.x,u=r*s.y;return{width:i,height:a,x:l,y:u}}function bl(e,t,n){let r;if(t==="viewport")r=Pm(e,n);else if(t==="document")r=Tm(Ke(e));else if(Me(t))r=Rm(t,n);else{const o=gl(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return Mr(r)}function wl(e,t){const n=_t(e);return n===t||!Me(n)||yn(n)?!1:$e(n).position==="fixed"||wl(n,t)}function Om(e,t){const n=t.get(e);if(n)return n;let r=Xn(e,[],!1).filter(a=>Me(a)&&vn(a)!=="body"),o=null;const s=$e(e).position==="fixed";let i=s?_t(e):e;for(;Me(i)&&!yn(i);){const a=$e(i),l=gs(i);!l&&a.position==="fixed"&&(o=null),(s?!l&&!o:!l&&a.position==="static"&&!!o&&Am.has(o.position)||Zn(i)&&!l&&wl(e,i))?r=r.filter(f=>f!==i):o=a,i=_t(i)}return t.set(e,r),r}function Im(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?Fr(t)?[]:Om(t,this._c):[].concat(n),r],a=i[0],l=i.reduce((u,f)=>{const p=bl(t,f,o);return u.top=Oe(p.top,u.top),u.right=wt(p.right,u.right),u.bottom=wt(p.bottom,u.bottom),u.left=Oe(p.left,u.left),u},bl(t,a,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function jm(e){const{width:t,height:n}=ml(e);return{width:t,height:n}}function km(e,t,n){const r=Qe(t),o=Ke(t),s=n==="fixed",i=Kt(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const l=Ge(0);function u(){l.x=Ur(o)}if(r||!r&&!s)if((vn(t)!=="body"||Zn(o))&&(a=Br(t)),r){const g=Kt(t,!0,s,t);l.x=g.x+t.clientLeft,l.y=g.y+t.clientTop}else o&&u();s&&!r&&o&&u();const f=o&&!r&&!s?vl(o,a):Ge(0),p=i.left+a.scrollLeft-l.x-f.x,m=i.top+a.scrollTop-l.y-f.y;return{x:p,y:m,width:i.width,height:i.height}}function ws(e){return $e(e).position==="static"}function _l(e,t){if(!Qe(e)||$e(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Ke(e)===n&&(n=n.ownerDocument.body),n}function xl(e,t){const n=Ie(e);if(Fr(e))return n;if(!Qe(e)){let o=_t(e);for(;o&&!yn(o);){if(Me(o)&&!ws(o))return o;o=_t(o)}return n}let r=_l(e,t);for(;r&&mm(r)&&ws(r);)r=_l(r,t);return r&&yn(r)&&ws(r)&&!gs(r)?n:r||wm(e)||n}const Lm=async function(e){const t=this.getOffsetParent||xl,n=this.getDimensions,r=await n(e.floating);return{reference:km(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Dm(e){return $e(e).direction==="rtl"}const Nm={convertOffsetParentRelativeRectToViewportRelativeRect:Sm,getDocumentElement:Ke,getClippingRect:Im,getOffsetParent:xl,getElementRects:Lm,getClientRects:Em,getDimensions:jm,getScale:bn,isElement:Me,isRTL:Dm};function Cl(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Mm(e,t){let n=null,r;const o=Ke(e);function s(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function i(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),s();const u=e.getBoundingClientRect(),{left:f,top:p,width:m,height:g}=u;if(a||t(),!m||!g)return;const y=Dr(p),h=Dr(o.clientWidth-(f+m)),v=Dr(o.clientHeight-(p+g)),b=Dr(f),C={rootMargin:-y+"px "+-h+"px "+-v+"px "+-b+"px",threshold:Oe(0,wt(1,l))||1};let T=!0;function P(A){const R=A[0].intersectionRatio;if(R!==l){if(!T)return i();R?i(!1,R):r=setTimeout(()=>{i(!1,1e-7)},1e3)}R===1&&!Cl(u,e.getBoundingClientRect())&&i(),T=!1}try{n=new IntersectionObserver(P,{...C,root:o.ownerDocument})}catch{n=new IntersectionObserver(P,C)}n.observe(e)}return i(!0),s}function $m(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,u=bs(e),f=o||s?[...u?Xn(u):[],...Xn(t)]:[];f.forEach(b=>{o&&b.addEventListener("scroll",n,{passive:!0}),s&&b.addEventListener("resize",n)});const p=u&&a?Mm(u,n):null;let m=-1,g=null;i&&(g=new ResizeObserver(b=>{let[_]=b;_&&_.target===u&&g&&(g.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var C;(C=g)==null||C.observe(t)})),n()}),u&&!l&&g.observe(u),g.observe(t));let y,h=l?Kt(e):null;l&&v();function v(){const b=Kt(e);h&&!Cl(h,b)&&n(),h=b,y=requestAnimationFrame(v)}return n(),()=>{var b;f.forEach(_=>{o&&_.removeEventListener("scroll",n),s&&_.removeEventListener("resize",n)}),p==null||p(),(b=g)==null||b.disconnect(),g=null,l&&cancelAnimationFrame(y)}}const Fm=cm,Bm=um,Um=im,Wm=fm,Hm=am,Sl=sm,Vm=dm,zm=(e,t,n)=>{const r=new Map,o={platform:Nm,...n},s={...o.platform,_c:r};return om(e,t,{...o,platform:s})};var Gm=typeof document<"u",qm=function(){},Wr=Gm?S.useLayoutEffect:qm;function Hr(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Hr(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const s=o[r];if(!(s==="_owner"&&e.$$typeof)&&!Hr(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function El(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Tl(e,t){const n=El(e);return Math.round(t*n)/n}function _s(e){const t=d.useRef(e);return Wr(()=>{t.current=e}),t}function Km(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:s,floating:i}={},transform:a=!0,whileElementsMounted:l,open:u}=e,[f,p]=d.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,g]=d.useState(r);Hr(m,r)||g(r);const[y,h]=d.useState(null),[v,b]=d.useState(null),_=d.useCallback(F=>{F!==A.current&&(A.current=F,h(F))},[]),C=d.useCallback(F=>{F!==R.current&&(R.current=F,b(F))},[]),T=s||y,P=i||v,A=d.useRef(null),R=d.useRef(null),D=d.useRef(f),k=l!=null,N=_s(l),U=_s(o),W=_s(u),H=d.useCallback(()=>{if(!A.current||!R.current)return;const F={placement:t,strategy:n,middleware:m};U.current&&(F.platform=U.current),zm(A.current,R.current,F).then(se=>{const ge={...se,isPositioned:W.current!==!1};z.current&&!Hr(D.current,ge)&&(D.current=ge,mr.flushSync(()=>{p(ge)}))})},[m,t,n,U,W]);Wr(()=>{u===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,p(F=>({...F,isPositioned:!1})))},[u]);const z=d.useRef(!1);Wr(()=>(z.current=!0,()=>{z.current=!1}),[]),Wr(()=>{if(T&&(A.current=T),P&&(R.current=P),T&&P){if(N.current)return N.current(T,P,H);H()}},[T,P,H,N,k]);const oe=d.useMemo(()=>({reference:A,floating:R,setReference:_,setFloating:C}),[_,C]),G=d.useMemo(()=>({reference:T,floating:P}),[T,P]),Y=d.useMemo(()=>{const F={position:n,left:0,top:0};if(!G.floating)return F;const se=Tl(G.floating,f.x),ge=Tl(G.floating,f.y);return a?{...F,transform:"translate("+se+"px, "+ge+"px)",...El(G.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:se,top:ge}},[n,a,G.floating,f.x,f.y]);return d.useMemo(()=>({...f,update:H,refs:oe,elements:G,floatingStyles:Y}),[f,H,oe,G,Y])}const Qm=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Sl({element:r.current,padding:o}).fn(n):{}:r?Sl({element:r,padding:o}).fn(n):{}}}},Ym=(e,t)=>({...Fm(e),options:[e,t]}),Zm=(e,t)=>({...Bm(e),options:[e,t]}),Xm=(e,t)=>({...Vm(e),options:[e,t]}),Jm=(e,t)=>({...Um(e),options:[e,t]}),e1=(e,t)=>({...Wm(e),options:[e,t]}),t1=(e,t)=>({...Hm(e),options:[e,t]}),n1=(e,t)=>({...Qm(e),options:[e,t]});var r1="Arrow",Pl=d.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...s}=e;return c.jsx(ie.svg,{...s,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:c.jsx("polygon",{points:"0,0 30,0 15,10"})})});Pl.displayName=r1;var o1=Pl;function s1(e){const[t,n]=d.useState(void 0);return ve(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const s=o[0];let i,a;if("borderBoxSize"in s){const l=s.borderBoxSize,u=Array.isArray(l)?l[0]:l;i=u.inlineSize,a=u.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var xs="Popper",[Al,Vr]=Yn(xs),[i1,Rl]=Al(xs),Ol=e=>{const{__scopePopper:t,children:n}=e,[r,o]=d.useState(null);return c.jsx(i1,{scope:t,anchor:r,onAnchorChange:o,children:n})};Ol.displayName=xs;var Il="PopperAnchor",jl=d.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,s=Rl(Il,n),i=d.useRef(null),a=le(t,i),l=d.useRef(null);return d.useEffect(()=>{const u=l.current;l.current=(r==null?void 0:r.current)||i.current,u!==l.current&&s.onAnchorChange(l.current)}),r?null:c.jsx(ie.div,{...o,ref:a})});jl.displayName=Il;var Cs="PopperContent",[a1,l1]=Al(Cs),kl=d.forwardRef((e,t)=>{var $,te,fe,X,ne,J;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:s="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:f=0,sticky:p="partial",hideWhenDetached:m=!1,updatePositionStrategy:g="optimized",onPlaced:y,...h}=e,v=Rl(Cs,n),[b,_]=d.useState(null),C=le(t,Ce=>_(Ce)),[T,P]=d.useState(null),A=s1(T),R=(A==null?void 0:A.width)??0,D=(A==null?void 0:A.height)??0,k=r+(s!=="center"?"-"+s:""),N=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},U=Array.isArray(u)?u:[u],W=U.length>0,H={padding:N,boundary:U.filter(u1),altBoundary:W},{refs:z,floatingStyles:oe,placement:G,isPositioned:Y,middlewareData:F}=Km({strategy:"fixed",placement:k,whileElementsMounted:(...Ce)=>$m(...Ce,{animationFrame:g==="always"}),elements:{reference:v.anchor},middleware:[Ym({mainAxis:o+D,alignmentAxis:i}),l&&Zm({mainAxis:!0,crossAxis:!1,limiter:p==="partial"?Xm():void 0,...H}),l&&Jm({...H}),e1({...H,apply:({elements:Ce,rects:Le,availableWidth:ot,availableHeight:ze})=>{const{width:Bt,height:Ao}=Le.reference,ht=Ce.floating.style;ht.setProperty("--radix-popper-available-width",`${ot}px`),ht.setProperty("--radix-popper-available-height",`${ze}px`),ht.setProperty("--radix-popper-anchor-width",`${Bt}px`),ht.setProperty("--radix-popper-anchor-height",`${Ao}px`)}}),T&&n1({element:T,padding:a}),d1({arrowWidth:R,arrowHeight:D}),m&&t1({strategy:"referenceHidden",...H})]}),[se,ge]=Nl(G),ke=Gt(y);ve(()=>{Y&&(ke==null||ke())},[Y,ke]);const Mt=($=F.arrow)==null?void 0:$.x,$t=(te=F.arrow)==null?void 0:te.y,rt=((fe=F.arrow)==null?void 0:fe.centerOffset)!==0,[Ft,Ve]=d.useState();return ve(()=>{b&&Ve(window.getComputedStyle(b).zIndex)},[b]),c.jsx("div",{ref:z.setFloating,"data-radix-popper-content-wrapper":"",style:{...oe,transform:Y?oe.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Ft,"--radix-popper-transform-origin":[(X=F.transformOrigin)==null?void 0:X.x,(ne=F.transformOrigin)==null?void 0:ne.y].join(" "),...((J=F.hide)==null?void 0:J.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:c.jsx(a1,{scope:n,placedSide:se,onArrowChange:P,arrowX:Mt,arrowY:$t,shouldHideArrow:rt,children:c.jsx(ie.div,{"data-side":se,"data-align":ge,...h,ref:C,style:{...h.style,animation:Y?void 0:"none"}})})})});kl.displayName=Cs;var Ll="PopperArrow",c1={top:"bottom",right:"left",bottom:"top",left:"right"},Dl=d.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,s=l1(Ll,r),i=c1[s.placedSide];return c.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:c.jsx(o1,{...o,ref:n,style:{...o.style,display:"block"}})})});Dl.displayName=Ll;function u1(e){return e!==null}var d1=e=>({name:"transformOrigin",options:e,fn(t){var v,b,_;const{placement:n,rects:r,middlewareData:o}=t,i=((v=o.arrow)==null?void 0:v.centerOffset)!==0,a=i?0:e.arrowWidth,l=i?0:e.arrowHeight,[u,f]=Nl(n),p={start:"0%",center:"50%",end:"100%"}[f],m=(((b=o.arrow)==null?void 0:b.x)??0)+a/2,g=(((_=o.arrow)==null?void 0:_.y)??0)+l/2;let y="",h="";return u==="bottom"?(y=i?p:`${m}px`,h=`${-l}px`):u==="top"?(y=i?p:`${m}px`,h=`${r.floating.height+l}px`):u==="right"?(y=`${-l}px`,h=i?p:`${g}px`):u==="left"&&(y=`${r.floating.width+l}px`,h=i?p:`${g}px`),{data:{x:y,y:h}}}});function Nl(e){const[t,n="center"]=e.split("-");return[t,n]}var Ml=Ol,$l=jl,Fl=kl,Bl=Dl,f1="Portal",Ss=d.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[o,s]=d.useState(!1);ve(()=>s(!0),[]);const i=n||o&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?Wt.createPortal(c.jsx(ie.div,{...r,ref:t}),i):null});Ss.displayName=f1;function p1(e){const t=h1(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),l=a.find(g1);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function h1(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=y1(o),a=v1(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var m1=Symbol("radix.slottable");function g1(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===m1}function v1(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function y1(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var b1=d[" useInsertionEffect ".trim().toString()]||ve;function zr({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,s,i]=w1({defaultProp:t,onChange:n}),a=e!==void 0,l=a?e:o;{const f=d.useRef(e!==void 0);d.useEffect(()=>{const p=f.current;p!==a&&console.warn(`${r} is changing from ${p?"controlled":"uncontrolled"} to ${a?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),f.current=a},[a,r])}const u=d.useCallback(f=>{var p;if(a){const m=_1(f)?f(e):f;m!==e&&((p=i.current)==null||p.call(i,m))}else s(f)},[a,e,s,i]);return[l,u]}function w1({defaultProp:e,onChange:t}){const[n,r]=d.useState(e),o=d.useRef(n),s=d.useRef(t);return b1(()=>{s.current=t},[t]),d.useEffect(()=>{var i;o.current!==n&&((i=s.current)==null||i.call(s,n),o.current=n)},[n,o]),[n,r,s]}function _1(e){return typeof e=="function"}function x1(e){const t=d.useRef({value:e,previous:e});return d.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var Ul=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),C1="VisuallyHidden",Wl=d.forwardRef((e,t)=>c.jsx(ie.span,{...e,ref:t,style:{...Ul,...e.style}}));Wl.displayName=C1;var S1=Wl,E1=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},wn=new WeakMap,Gr=new WeakMap,qr={},Es=0,Hl=function(e){return e&&(e.host||Hl(e.parentNode))},T1=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=Hl(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},P1=function(e,t,n,r){var o=T1(t,Array.isArray(e)?e:[e]);qr[n]||(qr[n]=new WeakMap);var s=qr[n],i=[],a=new Set,l=new Set(o),u=function(p){!p||a.has(p)||(a.add(p),u(p.parentNode))};o.forEach(u);var f=function(p){!p||l.has(p)||Array.prototype.forEach.call(p.children,function(m){if(a.has(m))f(m);else try{var g=m.getAttribute(r),y=g!==null&&g!=="false",h=(wn.get(m)||0)+1,v=(s.get(m)||0)+1;wn.set(m,h),s.set(m,v),i.push(m),h===1&&y&&Gr.set(m,!0),v===1&&m.setAttribute(n,"true"),y||m.setAttribute(r,"true")}catch(b){console.error("aria-hidden: cannot operate on ",m,b)}})};return f(t),a.clear(),Es++,function(){i.forEach(function(p){var m=wn.get(p)-1,g=s.get(p)-1;wn.set(p,m),s.set(p,g),m||(Gr.has(p)||p.removeAttribute(r),Gr.delete(p)),g||p.removeAttribute(n)}),Es--,Es||(wn=new WeakMap,wn=new WeakMap,Gr=new WeakMap,qr={})}},Vl=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=E1(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),P1(r,o,n,"aria-hidden")):function(){return null}},Ts=function(e,t){return Ts=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(n[o]=r[o])},Ts(e,t)};function Jn(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Ts(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var Ye=function(){return Ye=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},Ye.apply(this,arguments)};function zl(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Ps(e){var t=typeof Symbol=="function"&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function As(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),o,s=[],i;try{for(;(t===void 0||t-- >0)&&!(o=r.next()).done;)s.push(o.value)}catch(a){i={error:a}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(i)throw i.error}}return s}function Kr(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,s;r<o;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var Qr="right-scroll-bar-position",Yr="width-before-scroll-bar",A1="with-scroll-bars-hidden",R1="--removed-body-scroll-bar-size";function Rs(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function O1(e,t){var n=S.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var I1=typeof window<"u"?d.useLayoutEffect:d.useEffect,Gl=new WeakMap;function j1(e,t){var n=O1(null,function(r){return e.forEach(function(o){return Rs(o,r)})});return I1(function(){var r=Gl.get(n);if(r){var o=new Set(r),s=new Set(e),i=n.current;o.forEach(function(a){s.has(a)||Rs(a,null)}),s.forEach(function(a){o.has(a)||Rs(a,i)})}Gl.set(n,e)},[e]),n}function k1(e){return e}function L1(e,t){t===void 0&&(t=k1);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var i=t(s,r);return n.push(i),function(){n=n.filter(function(a){return a!==i})}},assignSyncMedium:function(s){for(r=!0;n.length;){var i=n;n=[],i.forEach(s)}n={push:function(a){return s(a)},filter:function(){return n}}},assignMedium:function(s){r=!0;var i=[];if(n.length){var a=n;n=[],a.forEach(s),i=n}var l=function(){var f=i;i=[],f.forEach(s)},u=function(){return Promise.resolve().then(l)};u(),n={push:function(f){i.push(f),u()},filter:function(f){return i=i.filter(f),n}}}};return o}function D1(e){e===void 0&&(e={});var t=L1(null);return t.options=Ye({async:!0,ssr:!1},e),t}var ql=function(e){var t=e.sideCar,n=zl(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return d.createElement(r,Ye({},n))};ql.isSideCarExport=!0;function N1(e,t){return e.useMedium(t),ql}var Kl=D1(),Os=function(){},Zr=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:Os,onWheelCapture:Os,onTouchMoveCapture:Os}),o=r[0],s=r[1],i=e.forwardProps,a=e.children,l=e.className,u=e.removeScrollBar,f=e.enabled,p=e.shards,m=e.sideCar,g=e.noRelative,y=e.noIsolation,h=e.inert,v=e.allowPinchZoom,b=e.as,_=b===void 0?"div":b,C=e.gapMode,T=zl(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),P=m,A=j1([n,t]),R=Ye(Ye({},T),o);return d.createElement(d.Fragment,null,f&&d.createElement(P,{sideCar:Kl,removeScrollBar:u,shards:p,noRelative:g,noIsolation:y,inert:h,setCallbacks:s,allowPinchZoom:!!v,lockRef:n,gapMode:C}),i?d.cloneElement(d.Children.only(a),Ye(Ye({},R),{ref:A})):d.createElement(_,Ye({},R,{className:l,ref:A}),a))});Zr.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Zr.classNames={fullWidth:Yr,zeroRight:Qr};var M1=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function $1(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=M1();return t&&e.setAttribute("nonce",t),e}function F1(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function B1(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var U1=function(){var e=0,t=null;return{add:function(n){e==0&&(t=$1())&&(F1(t,n),B1(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},W1=function(){var e=U1();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ql=function(){var e=W1(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},H1={left:0,top:0,right:0,gap:0},Is=function(e){return parseInt(e||"",10)||0},V1=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Is(n),Is(r),Is(o)]},z1=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return H1;var t=V1(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},G1=Ql(),_n="data-scroll-locked",q1=function(e,t,n,r){var o=e.left,s=e.top,i=e.right,a=e.gap;return n===void 0&&(n="margin"),`
|
|
200
|
+
.`.concat(A1,` {
|
|
201
201
|
overflow: hidden `).concat(r,`;
|
|
202
202
|
padding-right: `).concat(a,"px ").concat(r,`;
|
|
203
203
|
}
|
|
@@ -231,23 +231,24 @@ to {
|
|
|
231
231
|
}
|
|
232
232
|
|
|
233
233
|
body[`).concat(_n,`] {
|
|
234
|
-
`).concat(
|
|
234
|
+
`).concat(R1,": ").concat(a,`px;
|
|
235
235
|
}
|
|
236
|
-
`)},
|
|
236
|
+
`)},Yl=function(){var e=parseInt(document.body.getAttribute(_n)||"0",10);return isFinite(e)?e:0},K1=function(){d.useEffect(function(){return document.body.setAttribute(_n,(Yl()+1).toString()),function(){var e=Yl()-1;e<=0?document.body.removeAttribute(_n):document.body.setAttribute(_n,e.toString())}},[])},Q1=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;K1();var s=d.useMemo(function(){return z1(o)},[o]);return d.createElement(G1,{styles:q1(s,!t,o,n?"":"!important")})},js=!1;if(typeof window<"u")try{var Xr=Object.defineProperty({},"passive",{get:function(){return js=!0,!0}});window.addEventListener("test",Xr,Xr),window.removeEventListener("test",Xr,Xr)}catch{js=!1}var xn=js?{passive:!1}:!1,Y1=function(e){return e.tagName==="TEXTAREA"},Zl=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!Y1(e)&&n[t]==="visible")},Z1=function(e){return Zl(e,"overflowY")},X1=function(e){return Zl(e,"overflowX")},Xl=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=Jl(e,r);if(o){var s=ec(e,r),i=s[1],a=s[2];if(i>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},J1=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},eg=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},Jl=function(e,t){return e==="v"?Z1(t):X1(t)},ec=function(e,t){return e==="v"?J1(t):eg(t)},tg=function(e,t){return e==="h"&&t==="rtl"?-1:1},ng=function(e,t,n,r,o){var s=tg(e,window.getComputedStyle(t).direction),i=s*r,a=n.target,l=t.contains(a),u=!1,f=i>0,p=0,m=0;do{if(!a)break;var g=ec(e,a),y=g[0],h=g[1],v=g[2],b=h-v-s*y;(y||b)&&Jl(e,a)&&(p+=b,m+=y);var _=a.parentNode;a=_&&_.nodeType===Node.DOCUMENT_FRAGMENT_NODE?_.host:_}while(!l&&a!==document.body||l&&(t.contains(a)||t===a));return(f&&Math.abs(p)<1||!f&&Math.abs(m)<1)&&(u=!0),u},Jr=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},tc=function(e){return[e.deltaX,e.deltaY]},nc=function(e){return e&&"current"in e?e.current:e},rg=function(e,t){return e[0]===t[0]&&e[1]===t[1]},og=function(e){return`
|
|
237
237
|
.block-interactivity-`.concat(e,` {pointer-events: none;}
|
|
238
238
|
.allow-interactivity-`).concat(e,` {pointer-events: all;}
|
|
239
|
-
`)},ng=0,Cn=[];function rg(e){var t=d.useRef([]),n=d.useRef([0,0]),r=d.useRef(),o=d.useState(ng++)[0],s=d.useState(Kl)[0],i=d.useRef(e);d.useEffect(function(){i.current=e},[e]),d.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var h=Kr([e.lockRef.current],(e.shards||[]).map(tc),!0).filter(Boolean);return h.forEach(function(v){return v.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),h.forEach(function(v){return v.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var a=d.useCallback(function(h,v){if("touches"in h&&h.touches.length===2||h.type==="wheel"&&h.ctrlKey)return!i.current.allowPinchZoom;var b=Jr(h),_=n.current,C="deltaX"in h?h.deltaX:_[0]-b[0],T="deltaY"in h?h.deltaY:_[1]-b[1],P,A=h.target,R=Math.abs(C)>Math.abs(T)?"h":"v";if("touches"in h&&R==="h"&&A.type==="range")return!1;var D=window.getSelection(),k=D&&D.anchorNode,N=k?k===A||k.contains(A):!1;if(N)return!1;var U=Zl(R,A);if(!U)return!0;if(U?P=R:(P=R==="v"?"h":"v",U=Zl(R,A)),!U)return!1;if(!r.current&&"changedTouches"in h&&(C||T)&&(r.current=P),!P)return!0;var W=r.current||P;return J1(W,v,h,W==="h"?C:T)},[]),l=d.useCallback(function(h){var v=h;if(!(!Cn.length||Cn[Cn.length-1]!==s)){var b="deltaY"in v?ec(v):Jr(v),_=t.current.filter(function(P){return P.name===v.type&&(P.target===v.target||v.target===P.shadowParent)&&eg(P.delta,b)})[0];if(_&&_.should){v.cancelable&&v.preventDefault();return}if(!_){var C=(i.current.shards||[]).map(tc).filter(Boolean).filter(function(P){return P.contains(v.target)}),T=C.length>0?a(v,C[0]):!i.current.noIsolation;T&&v.cancelable&&v.preventDefault()}}},[]),u=d.useCallback(function(h,v,b,_){var C={name:h,delta:v,target:b,should:_,shadowParent:og(b)};t.current.push(C),setTimeout(function(){t.current=t.current.filter(function(T){return T!==C})},1)},[]),f=d.useCallback(function(h){n.current=Jr(h),r.current=void 0},[]),p=d.useCallback(function(h){u(h.type,ec(h),h.target,a(h,e.lockRef.current))},[]),m=d.useCallback(function(h){u(h.type,Jr(h),h.target,a(h,e.lockRef.current))},[]);d.useEffect(function(){return Cn.push(s),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:m}),document.addEventListener("wheel",l,xn),document.addEventListener("touchmove",l,xn),document.addEventListener("touchstart",f,xn),function(){Cn=Cn.filter(function(h){return h!==s}),document.removeEventListener("wheel",l,xn),document.removeEventListener("touchmove",l,xn),document.removeEventListener("touchstart",f,xn)}},[]);var g=e.removeScrollBar,y=e.inert;return d.createElement(d.Fragment,null,y?d.createElement(s,{styles:tg(o)}):null,g?d.createElement(G1,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function og(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const sg=k1(ql,rg);var ks=d.forwardRef(function(e,t){return d.createElement(Zr,Ye({},e,{ref:t,sideCar:sg}))});ks.classNames=Zr.classNames;var ig=[" ","Enter","ArrowUp","ArrowDown"],ag=[" ","Enter"],Qt="Select",[eo,to,lg]=mh(Qt),[Sn]=Yn(Qt,[lg,Vr]),no=Vr(),[cg,xt]=Sn(Qt),[ug,dg]=Sn(Qt),nc=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:s,value:i,defaultValue:a,onValueChange:l,dir:u,name:f,autoComplete:p,disabled:m,required:g,form:y}=e,h=no(t),[v,b]=d.useState(null),[_,C]=d.useState(null),[T,P]=d.useState(!1),A=vh(u),[R,D]=zr({prop:r,defaultProp:o??!1,onChange:s,caller:Qt}),[k,N]=zr({prop:i,defaultProp:a,onChange:l,caller:Qt}),U=d.useRef(null),W=v?y||!!v.closest("form"):!0,[H,z]=d.useState(new Set),oe=Array.from(H).map(G=>G.props.value).join(";");return c.jsx(Nl,{...h,children:c.jsxs(cg,{required:g,scope:t,trigger:v,onTriggerChange:b,valueNode:_,onValueNodeChange:C,valueNodeHasChildren:T,onValueNodeHasChildrenChange:P,contentId:qt(),value:k,onValueChange:N,open:R,onOpenChange:D,dir:A,triggerPointerDownPosRef:U,disabled:m,children:[c.jsx(eo.Provider,{scope:t,children:c.jsx(ug,{scope:e.__scopeSelect,onNativeOptionAdd:d.useCallback(G=>{z(Y=>new Set(Y).add(G))},[]),onNativeOptionRemove:d.useCallback(G=>{z(Y=>{const F=new Set(Y);return F.delete(G),F})},[]),children:n})}),W?c.jsxs(xc,{"aria-hidden":!0,required:g,tabIndex:-1,name:f,autoComplete:p,value:k,onChange:G=>N(G.target.value),disabled:m,form:y,children:[k===void 0?c.jsx("option",{value:""}):null,Array.from(H)]},oe):null]})})};nc.displayName=Qt;var rc="SelectTrigger",oc=d.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,s=no(n),i=xt(rc,n),a=i.disabled||r,l=le(t,i.onTriggerChange),u=to(n),f=d.useRef("touch"),[p,m,g]=Sc(h=>{const v=u().filter(C=>!C.disabled),b=v.find(C=>C.value===i.value),_=Ec(v,h,b);_!==void 0&&i.onValueChange(_.value)}),y=h=>{a||(i.onOpenChange(!0),g()),h&&(i.triggerPointerDownPosRef.current={x:Math.round(h.pageX),y:Math.round(h.pageY)})};return c.jsx(Ml,{asChild:!0,...s,children:c.jsx(ie.button,{type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:a,"data-disabled":a?"":void 0,"data-placeholder":Cc(i.value)?"":void 0,...o,ref:l,onClick:Z(o.onClick,h=>{h.currentTarget.focus(),f.current!=="mouse"&&y(h)}),onPointerDown:Z(o.onPointerDown,h=>{f.current=h.pointerType;const v=h.target;v.hasPointerCapture(h.pointerId)&&v.releasePointerCapture(h.pointerId),h.button===0&&h.ctrlKey===!1&&h.pointerType==="mouse"&&(y(h),h.preventDefault())}),onKeyDown:Z(o.onKeyDown,h=>{const v=p.current!=="";!(h.ctrlKey||h.altKey||h.metaKey)&&h.key.length===1&&m(h.key),!(v&&h.key===" ")&&ig.includes(h.key)&&(y(),h.preventDefault())})})})});oc.displayName=rc;var sc="SelectValue",ic=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:s,placeholder:i="",...a}=e,l=xt(sc,n),{onValueNodeHasChildrenChange:u}=l,f=s!==void 0,p=le(t,l.onValueNodeChange);return ve(()=>{u(f)},[u,f]),c.jsx(ie.span,{...a,ref:p,style:{pointerEvents:"none"},children:Cc(l.value)?c.jsx(c.Fragment,{children:i}):s})});ic.displayName=sc;var fg="SelectIcon",ac=d.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return c.jsx(ie.span,{"aria-hidden":!0,...o,ref:t,children:r||"▼"})});ac.displayName=fg;var Yt="SelectContent",lc=d.forwardRef((e,t)=>{const n=xt(Yt,e.__scopeSelect),[r,o]=d.useState();if(ve(()=>{o(new DocumentFragment)},[]),!n.open){const s=r;return s?mr.createPortal(c.jsx(cc,{scope:e.__scopeSelect,children:c.jsx(eo.Slot,{scope:e.__scopeSelect,children:c.jsx("div",{children:e.children})})}),s):null}return c.jsx(uc,{...e,ref:t})});lc.displayName=Yt;var Fe=10,[cc,Ct]=Sn(Yt),pg="SelectContentImpl",hg=u1("SelectContent.RemoveScroll"),uc=d.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:s,onPointerDownOutside:i,side:a,sideOffset:l,align:u,alignOffset:f,arrowPadding:p,collisionBoundary:m,collisionPadding:g,sticky:y,hideWhenDetached:h,avoidCollisions:v,...b}=e,_=xt(Yt,n),[C,T]=d.useState(null),[P,A]=d.useState(null),R=le(t,$=>T($)),[D,k]=d.useState(null),[N,U]=d.useState(null),W=to(n),[H,z]=d.useState(!1),oe=d.useRef(!1);d.useEffect(()=>{if(C)return Hl(C)},[C]),Za();const G=d.useCallback($=>{const[te,...fe]=W().map(J=>J.ref.current),[X]=fe.slice(-1),ne=document.activeElement;for(const J of $)if(J===ne||(J==null||J.scrollIntoView({block:"nearest"}),J===te&&P&&(P.scrollTop=0),J===X&&P&&(P.scrollTop=P.scrollHeight),J==null||J.focus(),document.activeElement!==ne))return},[W,P]),Y=d.useCallback(()=>G([D,C]),[G,D,C]);d.useEffect(()=>{H&&Y()},[H,Y]);const{onOpenChange:F,triggerPointerDownPosRef:se}=_;d.useEffect(()=>{if(C){let $={x:0,y:0};const te=X=>{var ne,J;$={x:Math.abs(Math.round(X.pageX)-(((ne=se.current)==null?void 0:ne.x)??0)),y:Math.abs(Math.round(X.pageY)-(((J=se.current)==null?void 0:J.y)??0))}},fe=X=>{$.x<=10&&$.y<=10?X.preventDefault():C.contains(X.target)||F(!1),document.removeEventListener("pointermove",te),se.current=null};return se.current!==null&&(document.addEventListener("pointermove",te),document.addEventListener("pointerup",fe,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",te),document.removeEventListener("pointerup",fe,{capture:!0})}}},[C,F,se]),d.useEffect(()=>{const $=()=>F(!1);return window.addEventListener("blur",$),window.addEventListener("resize",$),()=>{window.removeEventListener("blur",$),window.removeEventListener("resize",$)}},[F]);const[ge,ke]=Sc($=>{const te=W().filter(ne=>!ne.disabled),fe=te.find(ne=>ne.ref.current===document.activeElement),X=Ec(te,$,fe);X&&setTimeout(()=>X.ref.current.focus())}),Mt=d.useCallback(($,te,fe)=>{const X=!oe.current&&!fe;(_.value!==void 0&&_.value===te||X)&&(k($),X&&(oe.current=!0))},[_.value]),$t=d.useCallback(()=>C==null?void 0:C.focus(),[C]),rt=d.useCallback(($,te,fe)=>{const X=!oe.current&&!fe;(_.value!==void 0&&_.value===te||X)&&U($)},[_.value]),Ft=r==="popper"?Ls:dc,Ve=Ft===Ls?{side:a,sideOffset:l,align:u,alignOffset:f,arrowPadding:p,collisionBoundary:m,collisionPadding:g,sticky:y,hideWhenDetached:h,avoidCollisions:v}:{};return c.jsx(cc,{scope:n,content:C,viewport:P,onViewportChange:A,itemRefCallback:Mt,selectedItem:D,onItemLeave:$t,itemTextRefCallback:rt,focusSelectedItem:Y,selectedItemText:N,position:r,isPositioned:H,searchRef:ge,children:c.jsx(ks,{as:hg,allowPinchZoom:!0,children:c.jsx(us,{asChild:!0,trapped:_.open,onMountAutoFocus:$=>{$.preventDefault()},onUnmountAutoFocus:Z(o,$=>{var te;(te=_.trigger)==null||te.focus({preventScroll:!0}),$.preventDefault()}),children:c.jsx(kr,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:$=>$.preventDefault(),onDismiss:()=>_.onOpenChange(!1),children:c.jsx(Ft,{role:"listbox",id:_.contentId,"data-state":_.open?"open":"closed",dir:_.dir,onContextMenu:$=>$.preventDefault(),...b,...Ve,onPlaced:()=>z(!0),ref:R,style:{display:"flex",flexDirection:"column",outline:"none",...b.style},onKeyDown:Z(b.onKeyDown,$=>{const te=$.ctrlKey||$.altKey||$.metaKey;if($.key==="Tab"&&$.preventDefault(),!te&&$.key.length===1&&ke($.key),["ArrowUp","ArrowDown","Home","End"].includes($.key)){let X=W().filter(ne=>!ne.disabled).map(ne=>ne.ref.current);if(["ArrowUp","End"].includes($.key)&&(X=X.slice().reverse()),["ArrowUp","ArrowDown"].includes($.key)){const ne=$.target,J=X.indexOf(ne);X=X.slice(J+1)}setTimeout(()=>G(X)),$.preventDefault()}})})})})})})});uc.displayName=pg;var mg="SelectItemAlignedPosition",dc=d.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,s=xt(Yt,n),i=Ct(Yt,n),[a,l]=d.useState(null),[u,f]=d.useState(null),p=le(t,R=>f(R)),m=to(n),g=d.useRef(!1),y=d.useRef(!0),{viewport:h,selectedItem:v,selectedItemText:b,focusSelectedItem:_}=i,C=d.useCallback(()=>{if(s.trigger&&s.valueNode&&a&&u&&h&&v&&b){const R=s.trigger.getBoundingClientRect(),D=u.getBoundingClientRect(),k=s.valueNode.getBoundingClientRect(),N=b.getBoundingClientRect();if(s.dir!=="rtl"){const ne=N.left-D.left,J=k.left-ne,Ce=R.left-J,Le=R.width+Ce,ot=Math.max(Le,D.width),ze=window.innerWidth-Fe,Bt=Va(J,[Fe,Math.max(Fe,ze-ot)]);a.style.minWidth=Le+"px",a.style.left=Bt+"px"}else{const ne=D.right-N.right,J=window.innerWidth-k.right-ne,Ce=window.innerWidth-R.right-J,Le=R.width+Ce,ot=Math.max(Le,D.width),ze=window.innerWidth-Fe,Bt=Va(J,[Fe,Math.max(Fe,ze-ot)]);a.style.minWidth=Le+"px",a.style.right=Bt+"px"}const U=m(),W=window.innerHeight-Fe*2,H=h.scrollHeight,z=window.getComputedStyle(u),oe=parseInt(z.borderTopWidth,10),G=parseInt(z.paddingTop,10),Y=parseInt(z.borderBottomWidth,10),F=parseInt(z.paddingBottom,10),se=oe+G+H+F+Y,ge=Math.min(v.offsetHeight*5,se),ke=window.getComputedStyle(h),Mt=parseInt(ke.paddingTop,10),$t=parseInt(ke.paddingBottom,10),rt=R.top+R.height/2-Fe,Ft=W-rt,Ve=v.offsetHeight/2,$=v.offsetTop+Ve,te=oe+G+$,fe=se-te;if(te<=rt){const ne=U.length>0&&v===U[U.length-1].ref.current;a.style.bottom="0px";const J=u.clientHeight-h.offsetTop-h.offsetHeight,Ce=Math.max(Ft,Ve+(ne?$t:0)+J+Y),Le=te+Ce;a.style.height=Le+"px"}else{const ne=U.length>0&&v===U[0].ref.current;a.style.top="0px";const Ce=Math.max(rt,oe+h.offsetTop+(ne?Mt:0)+Ve)+fe;a.style.height=Ce+"px",h.scrollTop=te-rt+h.offsetTop}a.style.margin=`${Fe}px 0`,a.style.minHeight=ge+"px",a.style.maxHeight=W+"px",r==null||r(),requestAnimationFrame(()=>g.current=!0)}},[m,s.trigger,s.valueNode,a,u,h,v,b,s.dir,r]);ve(()=>C(),[C]);const[T,P]=d.useState();ve(()=>{u&&P(window.getComputedStyle(u).zIndex)},[u]);const A=d.useCallback(R=>{R&&y.current===!0&&(C(),_==null||_(),y.current=!1)},[C,_]);return c.jsx(vg,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:g,onScrollButtonChange:A,children:c.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:T},children:c.jsx(ie.div,{...o,ref:p,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});dc.displayName=mg;var gg="SelectPopperPosition",Ls=d.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=Fe,...s}=e,i=no(n);return c.jsx($l,{...i,...s,ref:t,align:r,collisionPadding:o,style:{boxSizing:"border-box",...s.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Ls.displayName=gg;var[vg,Ds]=Sn(Yt,{}),Ns="SelectViewport",fc=d.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...o}=e,s=Ct(Ns,n),i=Ds(Ns,n),a=le(t,s.onViewportChange),l=d.useRef(0);return c.jsxs(c.Fragment,{children:[c.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),c.jsx(eo.Slot,{scope:n,children:c.jsx(ie.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:Z(o.onScroll,u=>{const f=u.currentTarget,{contentWrapper:p,shouldExpandOnScrollRef:m}=i;if(m!=null&&m.current&&p){const g=Math.abs(l.current-f.scrollTop);if(g>0){const y=window.innerHeight-Fe*2,h=parseFloat(p.style.minHeight),v=parseFloat(p.style.height),b=Math.max(h,v);if(b<y){const _=b+g,C=Math.min(y,_),T=_-C;p.style.height=C+"px",p.style.bottom==="0px"&&(f.scrollTop=T>0?T:0,p.style.justifyContent="flex-end")}}}l.current=f.scrollTop})})})]})});fc.displayName=Ns;var pc="SelectGroup",[yg,bg]=Sn(pc),hc=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=qt();return c.jsx(yg,{scope:n,id:o,children:c.jsx(ie.div,{role:"group","aria-labelledby":o,...r,ref:t})})});hc.displayName=pc;var mc="SelectLabel",wg=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=bg(mc,n);return c.jsx(ie.div,{id:o.id,...r,ref:t})});wg.displayName=mc;var ro="SelectItem",[_g,gc]=Sn(ro),vc=d.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:s,...i}=e,a=xt(ro,n),l=Ct(ro,n),u=a.value===r,[f,p]=d.useState(s??""),[m,g]=d.useState(!1),y=le(t,_=>{var C;return(C=l.itemRefCallback)==null?void 0:C.call(l,_,r,o)}),h=qt(),v=d.useRef("touch"),b=()=>{o||(a.onValueChange(r),a.onOpenChange(!1))};if(r==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return c.jsx(_g,{scope:n,value:r,disabled:o,textId:h,isSelected:u,onItemTextChange:d.useCallback(_=>{p(C=>C||((_==null?void 0:_.textContent)??"").trim())},[]),children:c.jsx(eo.ItemSlot,{scope:n,value:r,disabled:o,textValue:f,children:c.jsx(ie.div,{role:"option","aria-labelledby":h,"data-highlighted":m?"":void 0,"aria-selected":u&&m,"data-state":u?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...i,ref:y,onFocus:Z(i.onFocus,()=>g(!0)),onBlur:Z(i.onBlur,()=>g(!1)),onClick:Z(i.onClick,()=>{v.current!=="mouse"&&b()}),onPointerUp:Z(i.onPointerUp,()=>{v.current==="mouse"&&b()}),onPointerDown:Z(i.onPointerDown,_=>{v.current=_.pointerType}),onPointerMove:Z(i.onPointerMove,_=>{var C;v.current=_.pointerType,o?(C=l.onItemLeave)==null||C.call(l):v.current==="mouse"&&_.currentTarget.focus({preventScroll:!0})}),onPointerLeave:Z(i.onPointerLeave,_=>{var C;_.currentTarget===document.activeElement&&((C=l.onItemLeave)==null||C.call(l))}),onKeyDown:Z(i.onKeyDown,_=>{var T;((T=l.searchRef)==null?void 0:T.current)!==""&&_.key===" "||(ag.includes(_.key)&&b(),_.key===" "&&_.preventDefault())})})})})});vc.displayName=ro;var er="SelectItemText",yc=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...s}=e,i=xt(er,n),a=Ct(er,n),l=gc(er,n),u=dg(er,n),[f,p]=d.useState(null),m=le(t,b=>p(b),l.onItemTextChange,b=>{var _;return(_=a.itemTextRefCallback)==null?void 0:_.call(a,b,l.value,l.disabled)}),g=f==null?void 0:f.textContent,y=d.useMemo(()=>c.jsx("option",{value:l.value,disabled:l.disabled,children:g},l.value),[l.disabled,l.value,g]),{onNativeOptionAdd:h,onNativeOptionRemove:v}=u;return ve(()=>(h(y),()=>v(y)),[h,v,y]),c.jsxs(c.Fragment,{children:[c.jsx(ie.span,{id:l.textId,...s,ref:m}),l.isSelected&&i.valueNode&&!i.valueNodeHasChildren?mr.createPortal(s.children,i.valueNode):null]})});yc.displayName=er;var bc="SelectItemIndicator",wc=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return gc(bc,n).isSelected?c.jsx(ie.span,{"aria-hidden":!0,...r,ref:t}):null});wc.displayName=bc;var Ms="SelectScrollUpButton",xg=d.forwardRef((e,t)=>{const n=Ct(Ms,e.__scopeSelect),r=Ds(Ms,e.__scopeSelect),[o,s]=d.useState(!1),i=le(t,r.onScrollButtonChange);return ve(()=>{if(n.viewport&&n.isPositioned){let a=function(){const u=l.scrollTop>0;s(u)};const l=n.viewport;return a(),l.addEventListener("scroll",a),()=>l.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?c.jsx(_c,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:l}=n;a&&l&&(a.scrollTop=a.scrollTop-l.offsetHeight)}}):null});xg.displayName=Ms;var $s="SelectScrollDownButton",Cg=d.forwardRef((e,t)=>{const n=Ct($s,e.__scopeSelect),r=Ds($s,e.__scopeSelect),[o,s]=d.useState(!1),i=le(t,r.onScrollButtonChange);return ve(()=>{if(n.viewport&&n.isPositioned){let a=function(){const u=l.scrollHeight-l.clientHeight,f=Math.ceil(l.scrollTop)<u;s(f)};const l=n.viewport;return a(),l.addEventListener("scroll",a),()=>l.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?c.jsx(_c,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:l}=n;a&&l&&(a.scrollTop=a.scrollTop+l.offsetHeight)}}):null});Cg.displayName=$s;var _c=d.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,s=Ct("SelectScrollButton",n),i=d.useRef(null),a=to(n),l=d.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return d.useEffect(()=>()=>l(),[l]),ve(()=>{var f;const u=a().find(p=>p.ref.current===document.activeElement);(f=u==null?void 0:u.ref.current)==null||f.scrollIntoView({block:"nearest"})},[a]),c.jsx(ie.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:Z(o.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(r,50))}),onPointerMove:Z(o.onPointerMove,()=>{var u;(u=s.onItemLeave)==null||u.call(s),i.current===null&&(i.current=window.setInterval(r,50))}),onPointerLeave:Z(o.onPointerLeave,()=>{l()})})}),Sg="SelectSeparator",Eg=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return c.jsx(ie.div,{"aria-hidden":!0,...r,ref:t})});Eg.displayName=Sg;var Fs="SelectArrow",Tg=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=no(n),s=xt(Fs,n),i=Ct(Fs,n);return s.open&&i.position==="popper"?c.jsx(Fl,{...o,...r,ref:t}):null});Tg.displayName=Fs;var Pg="SelectBubbleInput",xc=d.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const o=d.useRef(null),s=le(r,o),i=b1(t);return d.useEffect(()=>{const a=o.current;if(!a)return;const l=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(l,"value").set;if(i!==t&&f){const p=new Event("change",{bubbles:!0});f.call(a,t),a.dispatchEvent(p)}},[i,t]),c.jsx(ie.select,{...n,style:{...Bl,...n.style},ref:s,defaultValue:t})});xc.displayName=Pg;function Cc(e){return e===""||e===void 0}function Sc(e){const t=Gt(e),n=d.useRef(""),r=d.useRef(0),o=d.useCallback(i=>{const a=n.current+i;t(a),function l(u){n.current=u,window.clearTimeout(r.current),u!==""&&(r.current=window.setTimeout(()=>l(""),1e3))}(a)},[t]),s=d.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return d.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,s]}function Ec(e,t,n){const o=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let i=Ag(e,Math.max(s,0));o.length===1&&(i=i.filter(u=>u!==n));const l=i.find(u=>u.textValue.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function Ag(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Rg=nc,Og=oc,Ig=ic,jg=ac,kg=lc,Lg=fc,Dg=hc,Ng=vc,Mg=yc,$g=wc;const Ze={Container:"Container__xcHXp",Label:"Label__0cZB9",HelperText:"HelperText__m1nA9",Trigger:"Trigger__AyFUd",TriggerIcon:"TriggerIcon__aygFG",Content:"Content__llztG",Viewport:"Viewport__COtSL",Item:"Item__XN1-2",ItemIndicatorContainer:"ItemIndicatorContainer__EQH-X",ItemIndicator:"ItemIndicator__bySSc"},Tc=S.forwardRef(({label:e,helperText:t,value:n,onValueChange:r,options:o,placeholder:s="Select",disabled:i=!1,className:a,name:l},u)=>c.jsxs("div",{className:L(Ze.Container,a),children:[e&&c.jsx("label",{className:Ze.Label,children:e}),c.jsxs(Rg,{value:n,onValueChange:r,disabled:i,name:l,children:[c.jsxs(Og,{ref:u,className:Ze.Trigger,children:[c.jsx(Ig,{placeholder:s}),c.jsx(jg,{className:Ze.TriggerIcon,children:c.jsx(Fg,{})})]}),c.jsx(kg,{className:Ze.Content,position:"popper",sideOffset:4,children:c.jsx(Lg,{className:Ze.Viewport,children:c.jsx(Dg,{children:o.map(f=>c.jsxs(Ng,{value:f.value,disabled:f.disabled,className:Ze.Item,children:[c.jsx("div",{className:Ze.ItemIndicatorContainer,children:c.jsx($g,{className:Ze.ItemIndicator,children:c.jsx(Bg,{})})}),c.jsx(Mg,{children:f.label})]},f.value))})})})]}),t&&c.jsx("div",{className:Ze.HelperText,children:t})]}));Tc.displayName="Select";const Fg=()=>c.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[c.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.52459 12.7746C6.8907 12.4085 7.4843 12.4085 7.85041 12.7746L10 14.9242L12.1496 12.7746C12.5157 12.4085 13.1093 12.4085 13.4754 12.7746C13.8415 13.1407 13.8415 13.7343 13.4754 14.1004L10.6629 16.9129C10.2968 17.279 9.7032 17.279 9.33709 16.9129L6.52459 14.1004C6.15847 13.7343 6.15847 13.1407 6.52459 12.7746Z",fill:"currentColor"}),c.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M13.4754 7.22541C13.1093 7.59153 12.5157 7.59153 12.1496 7.22541L10 5.07583L7.85041 7.22541C7.4843 7.59153 6.8907 7.59153 6.52459 7.22541C6.15847 6.8593 6.15847 6.2657 6.52459 5.89959L9.33709 3.08709C9.7032 2.72097 10.2968 2.72097 10.6629 3.08709L13.4754 5.89959C13.8415 6.2657 13.8415 6.8593 13.4754 7.22541Z",fill:"currentColor"})]}),Bg=()=>c.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M13.3333 4L6 11.3333L2.66667 8",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Ug={TextArea:"TextArea__pa-A0"},Pc=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ug.TextArea,t);return c.jsx("textarea",{ref:r,className:o,...n,children:e})});Pc.displayName="TextArea";function Wg(e,t){return d.useReducer((n,r)=>t[n][r]??n,e)}var En=e=>{const{present:t,children:n}=e,r=Hg(t),o=typeof n=="function"?n({present:r.isPresent}):d.Children.only(n),s=le(r.ref,Vg(o));return typeof n=="function"||r.isPresent?d.cloneElement(o,{ref:s}):null};En.displayName="Presence";function Hg(e){const[t,n]=d.useState(),r=d.useRef(null),o=d.useRef(e),s=d.useRef("none"),i=e?"mounted":"unmounted",[a,l]=Wg(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const u=oo(r.current);s.current=a==="mounted"?u:"none"},[a]),ve(()=>{const u=r.current,f=o.current;if(f!==e){const m=s.current,g=oo(u);e?l("MOUNT"):g==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(f&&m!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),ve(()=>{if(t){let u;const f=t.ownerDocument.defaultView??window,p=g=>{const h=oo(r.current).includes(CSS.escape(g.animationName));if(g.target===t&&h&&(l("ANIMATION_END"),!o.current)){const v=t.style.animationFillMode;t.style.animationFillMode="forwards",u=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=v)})}},m=g=>{g.target===t&&(s.current=oo(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{f.clearTimeout(u),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:d.useCallback(u=>{r.current=u?getComputedStyle(u):null,n(u)},[])}}function oo(e){return(e==null?void 0:e.animationName)||"none"}function Vg(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var zg=Symbol("radix.slottable");function Gg(e){const t=({children:n})=>c.jsx(c.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=zg,t}var[so]=Yn("Tooltip",[Vr]),io=Vr(),Ac="TooltipProvider",qg=700,Bs="tooltip.open",[Kg,Us]=so(Ac),Rc=e=>{const{__scopeTooltip:t,delayDuration:n=qg,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:s}=e,i=d.useRef(!0),a=d.useRef(!1),l=d.useRef(0);return d.useEffect(()=>{const u=l.current;return()=>window.clearTimeout(u)},[]),c.jsx(Kg,{scope:t,isOpenDelayedRef:i,delayDuration:n,onOpen:d.useCallback(()=>{window.clearTimeout(l.current),i.current=!1},[]),onClose:d.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>i.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:d.useCallback(u=>{a.current=u},[]),disableHoverableContent:o,children:s})};Rc.displayName=Ac;var tr="Tooltip",[Qg,nr]=so(tr),Oc=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o,onOpenChange:s,disableHoverableContent:i,delayDuration:a}=e,l=Us(tr,e.__scopeTooltip),u=io(t),[f,p]=d.useState(null),m=qt(),g=d.useRef(0),y=i??l.disableHoverableContent,h=a??l.delayDuration,v=d.useRef(!1),[b,_]=zr({prop:r,defaultProp:o??!1,onChange:R=>{R?(l.onOpen(),document.dispatchEvent(new CustomEvent(Bs))):l.onClose(),s==null||s(R)},caller:tr}),C=d.useMemo(()=>b?v.current?"delayed-open":"instant-open":"closed",[b]),T=d.useCallback(()=>{window.clearTimeout(g.current),g.current=0,v.current=!1,_(!0)},[_]),P=d.useCallback(()=>{window.clearTimeout(g.current),g.current=0,_(!1)},[_]),A=d.useCallback(()=>{window.clearTimeout(g.current),g.current=window.setTimeout(()=>{v.current=!0,_(!0),g.current=0},h)},[h,_]);return d.useEffect(()=>()=>{g.current&&(window.clearTimeout(g.current),g.current=0)},[]),c.jsx(Nl,{...u,children:c.jsx(Qg,{scope:t,contentId:m,open:b,stateAttribute:C,trigger:f,onTriggerChange:p,onTriggerEnter:d.useCallback(()=>{l.isOpenDelayedRef.current?A():T()},[l.isOpenDelayedRef,A,T]),onTriggerLeave:d.useCallback(()=>{y?P():(window.clearTimeout(g.current),g.current=0)},[P,y]),onOpen:T,onClose:P,disableHoverableContent:y,children:n})})};Oc.displayName=tr;var Ws="TooltipTrigger",Ic=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=nr(Ws,n),s=Us(Ws,n),i=io(n),a=d.useRef(null),l=le(t,a,o.onTriggerChange),u=d.useRef(!1),f=d.useRef(!1),p=d.useCallback(()=>u.current=!1,[]);return d.useEffect(()=>()=>document.removeEventListener("pointerup",p),[p]),c.jsx(Ml,{asChild:!0,...i,children:c.jsx(ie.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:l,onPointerMove:Z(e.onPointerMove,m=>{m.pointerType!=="touch"&&!f.current&&!s.isPointerInTransitRef.current&&(o.onTriggerEnter(),f.current=!0)}),onPointerLeave:Z(e.onPointerLeave,()=>{o.onTriggerLeave(),f.current=!1}),onPointerDown:Z(e.onPointerDown,()=>{o.open&&o.onClose(),u.current=!0,document.addEventListener("pointerup",p,{once:!0})}),onFocus:Z(e.onFocus,()=>{u.current||o.onOpen()}),onBlur:Z(e.onBlur,o.onClose),onClick:Z(e.onClick,o.onClose)})})});Ic.displayName=Ws;var Hs="TooltipPortal",[Yg,Zg]=so(Hs,{forceMount:void 0}),jc=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,s=nr(Hs,t);return c.jsx(Yg,{scope:t,forceMount:n,children:c.jsx(En,{present:n||s.open,children:c.jsx(Ss,{asChild:!0,container:o,children:r})})})};jc.displayName=Hs;var Tn="TooltipContent",kc=d.forwardRef((e,t)=>{const n=Zg(Tn,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...s}=e,i=nr(Tn,e.__scopeTooltip);return c.jsx(En,{present:r||i.open,children:i.disableHoverableContent?c.jsx(Lc,{side:o,...s,ref:t}):c.jsx(Xg,{side:o,...s,ref:t})})}),Xg=d.forwardRef((e,t)=>{const n=nr(Tn,e.__scopeTooltip),r=Us(Tn,e.__scopeTooltip),o=d.useRef(null),s=le(t,o),[i,a]=d.useState(null),{trigger:l,onClose:u}=n,f=o.current,{onPointerInTransitChange:p}=r,m=d.useCallback(()=>{a(null),p(!1)},[p]),g=d.useCallback((y,h)=>{const v=y.currentTarget,b={x:y.clientX,y:y.clientY},_=nv(b,v.getBoundingClientRect()),C=rv(b,_),T=ov(h.getBoundingClientRect()),P=iv([...C,...T]);a(P),p(!0)},[p]);return d.useEffect(()=>()=>m(),[m]),d.useEffect(()=>{if(l&&f){const y=v=>g(v,f),h=v=>g(v,l);return l.addEventListener("pointerleave",y),f.addEventListener("pointerleave",h),()=>{l.removeEventListener("pointerleave",y),f.removeEventListener("pointerleave",h)}}},[l,f,g,m]),d.useEffect(()=>{if(i){const y=h=>{const v=h.target,b={x:h.clientX,y:h.clientY},_=(l==null?void 0:l.contains(v))||(f==null?void 0:f.contains(v)),C=!sv(b,i);_?m():C&&(m(),u())};return document.addEventListener("pointermove",y),()=>document.removeEventListener("pointermove",y)}},[l,f,i,u,m]),c.jsx(Lc,{...e,ref:s})}),[Jg,ev]=so(tr,{isInside:!1}),tv=Gg("TooltipContent"),Lc=d.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:s,onPointerDownOutside:i,...a}=e,l=nr(Tn,n),u=io(n),{onClose:f}=l;return d.useEffect(()=>(document.addEventListener(Bs,f),()=>document.removeEventListener(Bs,f)),[f]),d.useEffect(()=>{if(l.trigger){const p=m=>{const g=m.target;g!=null&&g.contains(l.trigger)&&f()};return window.addEventListener("scroll",p,{capture:!0}),()=>window.removeEventListener("scroll",p,{capture:!0})}},[l.trigger,f]),c.jsx(kr,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:p=>p.preventDefault(),onDismiss:f,children:c.jsxs($l,{"data-state":l.stateAttribute,...u,...a,ref:t,style:{...a.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[c.jsx(tv,{children:r}),c.jsx(Jg,{scope:n,isInside:!0,children:c.jsx(_1,{id:l.contentId,role:"tooltip",children:o||r})})]})})});kc.displayName=Tn;var Dc="TooltipArrow",Nc=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=io(n);return ev(Dc,n).isInside?null:c.jsx(Fl,{...o,...r,ref:t})});Nc.displayName=Dc;function nv(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),s=Math.abs(t.left-e.x);switch(Math.min(n,r,o,s)){case s:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function rv(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function ov(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function sv(e,t){const{x:n,y:r}=e;let o=!1;for(let s=0,i=t.length-1;s<t.length;i=s++){const a=t[s],l=t[i],u=a.x,f=a.y,p=l.x,m=l.y;f>r!=m>r&&n<(p-u)*(r-f)/(m-f)+u&&(o=!o)}return o}function iv(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),av(t)}function av(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const o=e[r];for(;t.length>=2;){const s=t[t.length-1],i=t[t.length-2];if((s.x-i.x)*(o.y-i.y)>=(s.y-i.y)*(o.x-i.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const s=n[n.length-1],i=n[n.length-2];if((s.x-i.x)*(o.y-i.y)>=(s.y-i.y)*(o.x-i.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var lv=Rc,cv=Oc,uv=Ic,dv=jc,fv=kc,pv=Nc;const Mc={tooltip:"tooltip__nUuSh",tooltipArrow:"tooltipArrow__W2w-f"},Pn=({children:e,open:t,displayName:n,tooltipContent:r,className:o,disabled:s,delayDuration:i=300,side:a="right",sideOffset:l=0})=>{const[u,f]=S.useState(!1),p=t!==void 0,g=s?!1:p?t:u,y=h=>{s||p||f(h)};return c.jsx(lv,{delayDuration:i,children:c.jsxs(cv,{open:g,onOpenChange:y,children:[c.jsx(uv,{asChild:!0,children:e}),c.jsx(dv,{children:c.jsxs(fv,{className:L(Mc.tooltip,o),side:a,sideOffset:l,children:[n,r,c.jsx(pv,{className:Mc.tooltipArrow})]})})]})})};Pn.displayName="Tooltip";const $c={truncatedText:"truncatedText__Y-jSd",overflowing:"overflowing__o8TC-"},Fc=({children:e,className:t,tooltipSide:n="top",tooltipClassName:r})=>{const o=S.useRef(null),[s,i]=S.useState(!1);S.useEffect(()=>{const l=()=>{if(o.current){const u=o.current.scrollWidth>o.current.clientWidth;i(u)}};return l(),window.addEventListener("resize",l),()=>{window.removeEventListener("resize",l)}},[e]);const a=c.jsx("span",{ref:o,className:L($c.truncatedText,s?$c.overflowing:"",t||""),children:e});return s?c.jsx(Pn,{tooltipContent:e,side:n,className:r,children:a}):a};Fc.displayName="TextWithTooltip";const rr={SearchInput:"SearchInput__4OFyE",SearchIcon:"SearchIcon__YgnQy",ClearIcon:"ClearIcon__ukRVr",SearchInput__ClearIcon:"SearchInput__ClearIcon__uzVoc",SearchInput__SearchIcon:"SearchInput__SearchIcon__zoDG4"},Vs=S.forwardRef(({className:e,placeholder:t="Type to search...",showClearButton:n=!1,showSearchIcon:r=!0,onClear:o,...s},i)=>{const a=L(rr.SearchInput,n&&rr.SearchInput__ClearIcon,r&&rr.SearchInput__SearchIcon,e),l=L(rr.SearchIcon),u=L(rr.ClearIcon);return c.jsxs("div",{className:a,children:[c.jsx(jr,{ref:i,type:"text",placeholder:t,...s}),r&&c.jsx("svg",{className:l,width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M13 13L10.6667 10.6667M12.3333 6.66667C12.3333 9.79628 9.79628 12.3333 6.66667 12.3333C3.53705 12.3333 1 9.79628 1 6.66667C1 3.53705 3.53705 1 6.66667 1C9.79628 1 12.3333 3.53705 12.3333 6.66667Z",stroke:"#A4A4A4",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})}),n&&c.jsx("svg",{className:u,width:"8",height:"8",viewBox:"0 0 8 8",fill:"none",xmlns:"http://www.w3.org/2000/svg",onClick:o,children:c.jsx("path",{d:"M7.33334 0.666748L0.666672 7.33341M0.666672 0.666748L7.33334 7.33341",stroke:"#818181",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})})]})});Vs.displayName="SearchInput";const Zt={SearchAutocomplete:"SearchAutocomplete__vR9Hk",AutocompleteItem:"AutocompleteItem__YIm7R","AutocompleteItem--canBeSelected":"AutocompleteItem--canBeSelected__jxk4z",AutocompleteHighlighter:"AutocompleteHighlighter__LAFTV",AutocompleteHighlighter__match:"AutocompleteHighlighter__match__Wy1o2",DropdownList:"DropdownList__-fHIk",AutocompleteItemDescription:"AutocompleteItemDescription__4QYN5"},Xt={DropdownList:"DropdownList__QTXXX",dropdownList:"DropdownList__QTXXX","DropdownList--closed":"DropdownList--closed__pdL1Z",dropdownListClosed:"DropdownList--closed__pdL1Z","DropdownList--open":"DropdownList--open__opzc9",dropdownListOpen:"DropdownList--open__opzc9","DropdownList--left":"DropdownList--left__xSwXR",dropdownListLeft:"DropdownList--left__xSwXR"},ao=S.forwardRef(({children:e,className:t,open:n,align:r="right",...o},s)=>{const i=L(Xt.DropdownList,{[Xt["DropdownList--open"]]:n,[Xt["DropdownList--closed"]]:!n,[Xt["DropdownList--left"]]:r==="left"},t);return c.jsx("div",{ref:s,className:i,...o,children:e})});ao.displayName="DropdownList";const or=S.forwardRef(({children:e,className:t,canBeSelected:n=!1,...r},o)=>{const s=L(Zt.AutocompleteItem,{[Zt["AutocompleteItem--canBeSelected"]]:n},t);return c.jsx("div",{ref:o,className:s,role:n?"option":void 0,...r,children:e})});or.displayName="AutocompleteItem";const hv=300,mv={query:"",suggestions:[],loading:!1,error:null},gv=({suggestionFetcher:e,canAdd:t})=>{const[n,r]=S.useState(mv);return S.useEffect(()=>{r(a=>({...a,loading:!0}));const s=async()=>{try{const a=await e(n.query);t&&!a.some(l=>l.value.toLowerCase()===n.query.toLowerCase())&&a.push({label:`Add "${n.query}"`,value:n.query,isNew:!0}),r(l=>({...l,suggestions:a,loading:!1}))}catch(a){r(l=>({...l,suggestions:[],error:a,loading:!1}))}},i=setTimeout(()=>{s()},hv);return()=>{clearTimeout(i)}},[n.query]),{...n,setQuery:s=>{r(i=>({...i,query:s}))}}},Bc=S.forwardRef(({text:e,query:t,className:n,...r},o)=>{const s=L(Zt.AutocompleteHighlighter,n),i=(a,l)=>{const u=a.toLowerCase().indexOf(l.toLowerCase());if(u===-1||l.length===0)return a;const f=a.slice(0,u),p=a.slice(u,u+l.length),m=a.slice(u+l.length);return c.jsxs(c.Fragment,{children:[f,c.jsx("span",{className:Zt.AutocompleteHighlighter__match,children:p}),i(m,l)]})};return c.jsx("div",{ref:o,className:s,...r,children:i(e,t)})});Bc.displayName="AutocompleteHighlighter";const vv=5,Uc=S.forwardRef(({children:e,className:t,canAdd:n,maxSuggestionsShown:r=vv,searchInputProps:o,keepSelectedOption:s,suggestionFetcher:i,onAccept:a,...l},u)=>{const{query:f,setQuery:p,suggestions:m,loading:g}=gv({suggestionFetcher:i,canAdd:n}),[y,h]=S.useState(null),v=f.length>0,b=R=>{p(R.target.value)},_=R=>{a==null||a(R),s?(h(R),p(R.value)):p("")},C=()=>{a==null||a(null),h(null),p("")},T=L(Zt.SearchAutocomplete,t),P=m.slice(0,r),A=m.slice(r);return c.jsxs("div",{ref:u,className:T,...l,children:[c.jsx(Vs,{...o,value:f,onChange:b,showClearButton:!!y,onClear:C}),e,c.jsxs(ao,{className:Zt.DropdownList,open:v&&!y,role:"listbox","aria-label":"Suggestions",children:[g?c.jsx(or,{children:"Loading..."}):P.map(R=>c.jsxs(or,{canBeSelected:!0,onClick:_.bind(null,R),children:[c.jsx(Bc,{text:R.label,query:f}),R.description&&c.jsx("span",{className:Zt.AutocompleteItemDescription,children:R.description})]},R.value)),!g&&A.length>0&&c.jsxs(or,{children:[A.length," more results"]}),v&&m.length===0&&!g&&c.jsx(or,{children:"No results found"})]})]})});Uc.displayName="SearchAutocomplete";const St=e=>{let t=null,n=null;return S.Children.forEach(e.children,r=>{const o=r.props.condition;o===void 0?n=r:!t&&o===!0&&(t=r)}),c.jsx(c.Fragment,{children:t||n})};St.displayName="Show",St.When=({condition:e,children:t})=>c.jsx(c.Fragment,{children:e&&t}),St.Else=({render:e,children:t})=>c.jsx(c.Fragment,{children:e||t});var yv=Symbol.for("react.lazy"),lo=d[" use ".trim().toString()];function bv(e){return typeof e=="object"&&e!==null&&"then"in e}function Wc(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===yv&&"_payload"in e&&bv(e._payload)}function wv(e){const t=xv(e),n=d.forwardRef((r,o)=>{let{children:s,...i}=r;Wc(s)&&typeof lo=="function"&&(s=lo(s._payload));const a=d.Children.toArray(s),l=a.find(Sv);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}var _v=wv("Slot");function xv(e){const t=d.forwardRef((n,r)=>{let{children:o,...s}=n;if(Wc(o)&&typeof lo=="function"&&(o=lo(o._payload)),d.isValidElement(o)){const i=Tv(o),a=Ev(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Cv=Symbol("radix.slottable");function Sv(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Cv}function Ev(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Tv(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const Hc={SkeletonListContainer:"SkeletonListContainer__MKJhE",Skeleton:"Skeleton__Ovpiw"},co=S.forwardRef((e,t)=>{const{children:n,className:r,loading:o,height:s=48,width:i,borderRadius:a,style:l,...u}=e;if(!o&&n)return n;const f=S.isValidElement(n)?_v:"span";return c.jsx(f,{ref:t,"aria-hidden":!0,className:L(Hc.Skeleton,r),style:{...l,width:i,minWidth:i,height:s,borderRadius:a},"data-inline-skeleton":S.isValidElement(n)?void 0:!0,tabIndex:-1,...u,children:n})});co.displayName="Skeleton";const Vc=e=>{const{numberOfItems:t,itemsGap:n=2,itemProps:r}=e,o=Array.from({length:t},(s,i)=>i+1);return c.jsx("div",{className:L(Hc.SkeletonListContainer),style:{gap:n},children:o.map(s=>c.jsx(co,{loading:!0,...r},s))})};Vc.displayName="SkeletonList";const zc={spinner:"spinner__qa7F6",rotate:"rotate__EqlXe","spinner-dark":"spinner-dark__9A9-q",spinnerDark:"spinner-dark__9A9-q","spinner-white":"spinner-white__gRbtI",spinnerWhite:"spinner-white__gRbtI","spinner-success":"spinner-success__otWGm",spinnerSuccess:"spinner-success__otWGm","spinner-danger":"spinner-danger__Bq5DM",spinnerDanger:"spinner-danger__Bq5DM","spinner-warning":"spinner-warning__U900K",spinnerWarning:"spinner-warning__U900K"},Gc=({className:e,color:t="white",size:n=80,thickness:r})=>{const o=L(zc.spinner,zc[`spinner-${t}`],e),s=r??Math.max(n/12,2);return c.jsx("span",{style:{width:n,height:n,borderWidth:s},className:o})};Gc.displayName="Spinner";const uo={switch:"switch__0b2av",disabled:"disabled__KpauE",checked:"checked__2-JV-",thumb:"thumb__fEuKD"},qc=S.forwardRef(({checked:e,defaultChecked:t=!1,onCheckedChange:n,disabled:r=!1,id:o,className:s,name:i,"aria-label":a,"aria-labelledby":l,"aria-describedby":u,...f},p)=>{const[m,g]=S.useState(t),y=e!==void 0,h=y?!!e:m,v=()=>{if(r)return;const _=!h;y||g(_),n==null||n(_)},b=_=>{(_.key===" "||_.key==="Enter")&&(_.preventDefault(),v())};return c.jsx("button",{ref:p,type:"button",role:"switch","aria-checked":h,"aria-label":a,"aria-labelledby":l,"aria-describedby":u,disabled:r,id:o,name:i,className:L(uo.switch,{[uo.checked]:h,[uo.disabled]:r}),onClick:v,onKeyDown:b,...f,children:c.jsx("span",{className:uo.thumb,"aria-hidden":"true"})})});qc.displayName="Switch";const Xe={tabsRoot:"tabs-root__ELmdj",tabsList:"tabs-list__rc10N",tabsListHorizontal:"tabs-list--horizontal__e1YW4",tabsListVertical:"tabs-list--vertical__huK05",tabsTrigger:"tabs-trigger__D8R4R",tabsTriggerDisabled:"tabs-trigger--disabled__ezDWc",tabsTriggerHorizontal:"tabs-trigger--horizontal__4jBFV",tabsTriggerActive:"tabs-trigger--active__S-Z-S",tabsTriggerVertical:"tabs-trigger--vertical__dNVIZ",tabsContent:"tabs-content__1d77o"},Kc=S.createContext(null),zs=()=>{const e=S.useContext(Kc);if(!e)throw new Error("Tabs components must be used within a Tabs provider");return e},Pv=({defaultValue:e,value:t,onValueChange:n,orientation:r="horizontal",className:o="",children:s})=>{const[i,a]=S.useState(e||""),l=t!==void 0,u=l?t:i,f=p=>{l||a(p),n==null||n(p)};return c.jsx(Kc.Provider,{value:{value:u,onValueChange:f,orientation:r},children:c.jsx("div",{className:L(Xe.tabsRoot,o),children:s})})},Av=({className:e="",children:t})=>{const{orientation:n}=zs(),r=S.useRef(null),o=s=>{var u;const i=(u=r.current)==null?void 0:u.querySelectorAll('[role="tab"]:not([disabled])');if(!i)return;const a=Array.from(i).findIndex(f=>f===document.activeElement);let l=a;switch(s.key){case"ArrowLeft":n==="horizontal"&&(s.preventDefault(),l=a>0?a-1:i.length-1);break;case"ArrowRight":n==="horizontal"&&(s.preventDefault(),l=a<i.length-1?a+1:0);break;case"ArrowUp":n==="vertical"&&(s.preventDefault(),l=a>0?a-1:i.length-1);break;case"ArrowDown":n==="vertical"&&(s.preventDefault(),l=a<i.length-1?a+1:0);break;case"Home":s.preventDefault(),l=0;break;case"End":s.preventDefault(),l=i.length-1;break}if(l!==a){const f=i[l];f.focus(),f.click()}};return c.jsx("div",{ref:r,role:"tablist","aria-orientation":n,onKeyDown:o,className:L(Xe.tabsList,n==="horizontal"?Xe.tabsListHorizontal:Xe.tabsListVertical,e),children:t})},Rv=({value:e,disabled:t=!1,className:n="",children:r})=>{const{value:o,onValueChange:s,orientation:i}=zs(),a=o===e,l=()=>{t||s(e)};return c.jsx("button",{role:"tab","aria-selected":a,"aria-controls":`content-${e}`,tabIndex:a?0:-1,disabled:t,onClick:l,className:L(Xe.tabsTrigger,i==="horizontal"?Xe.tabsTriggerHorizontal:Xe.tabsTriggerVertical,a&&Xe.tabsTriggerActive,t&&Xe.tabsTriggerDisabled,n),children:r})},Ov=({value:e,className:t="",children:n})=>{const{value:r}=zs();return r===e?c.jsx("div",{role:"tabpanel",id:`content-${e}`,"aria-labelledby":`trigger-${e}`,tabIndex:0,className:L(Xe.tabsContent,t),children:n}):null},Qc=({className:e,state:t="open",onClick:n})=>t==="open"?c.jsxs("svg",{className:e,onClick:n,xmlns:"http://www.w3.org/2000/svg",width:"1.5em",height:"1.5em",viewBox:"0 0 14 14",fill:"none",children:[c.jsx("path",{d:"M1.41174 7.41635C1.3323 7.29056 1.29257 7.22766 1.27034 7.13065C1.25364 7.05778 1.25364 6.94287 1.27034 6.87C1.29257 6.77299 1.3323 6.71009 1.41174 6.58431C2.06823 5.54482 4.02232 2.91699 7.00024 2.91699C9.97815 2.91699 11.9322 5.54482 12.5887 6.5843C12.6682 6.71009 12.7079 6.77299 12.7301 6.87C12.7468 6.94287 12.7468 7.05778 12.7301 7.13065C12.7079 7.22766 12.6682 7.29056 12.5887 7.41635C11.9322 8.45584 9.97815 11.0837 7.00024 11.0837C4.02232 11.0837 2.06823 8.45584 1.41174 7.41635Z",stroke:"#818181",strokeWidth:"1.16667",strokeLinecap:"round",strokeLinejoin:"round"}),c.jsx("path",{d:"M7.00024 8.75033C7.96673 8.75033 8.75024 7.96682 8.75024 7.00033C8.75024 6.03383 7.96673 5.25033 7.00024 5.25033C6.03374 5.25033 5.25024 6.03383 5.25024 7.00033C5.25024 7.96682 6.03374 8.75033 7.00024 8.75033Z",stroke:"#818181",strokeWidth:"1.16667",strokeLinecap:"round",strokeLinejoin:"round"})]}):c.jsx("svg",{className:e,onClick:n,xmlns:"http://www.w3.org/2000/svg",width:"1.5em",height:"1.5em",viewBox:"0 0 14 14",fill:"none",children:c.jsx("path",{d:"M6.26672 2.97052C6.50379 2.93547 6.74835 2.91667 7.00024 2.91667C9.97816 2.91667 11.9323 5.54449 12.5887 6.58398C12.6682 6.70979 12.7079 6.7727 12.7302 6.86973C12.7469 6.94259 12.7468 7.05755 12.7301 7.13042C12.7079 7.22744 12.6679 7.29077 12.5879 7.41741C12.413 7.69425 12.1463 8.08331 11.793 8.50527M3.92252 3.9171C2.66131 4.77266 1.8051 5.9613 1.41231 6.58308C1.3325 6.70942 1.29259 6.7726 1.27035 6.86961C1.25364 6.94248 1.25363 7.05742 1.27033 7.13029C1.29257 7.22731 1.33229 7.29022 1.41174 7.41602C2.06823 8.45551 4.02232 11.0833 7.00024 11.0833C8.20098 11.0833 9.23526 10.6561 10.0851 10.078M1.75024 1.75L12.2502 12.25M5.76281 5.76256C5.44612 6.07925 5.25024 6.51675 5.25024 7C5.25024 7.9665 6.03374 8.75 7.00024 8.75C7.48349 8.75 7.92099 8.55413 8.23768 8.23744",stroke:"#818181",strokeWidth:"1.16667",strokeLinecap:"round",strokeLinejoin:"round"})}),Yc={PasswordInput:"PasswordInput__GDJDN",eyeIcon:"eyeIcon__kDExG"},Iv=S.forwardRef((e,t)=>{const[n,r]=S.useState("password"),o=S.useCallback(()=>{r(s=>s==="password"?"text":"password")},[r]);return c.jsxs("div",{className:L(Yc.PasswordInput,e.className),children:[c.jsx(jr,{type:n,...e,ref:t}),c.jsx(Qc,{className:Yc.eyeIcon,onClick:o,state:n==="password"?"open":"closed"})]})});function jv(e){const t=kv(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),l=a.find(Dv);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function kv(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=Mv(o),a=Nv(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Lv=Symbol("radix.slottable");function Dv(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Lv}function Nv(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Mv(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var fo="Dialog",[Zc]=Yn(fo),[$v,Be]=Zc(fo),Xc=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:s,modal:i=!0}=e,a=d.useRef(null),l=d.useRef(null),[u,f]=zr({prop:r,defaultProp:o??!1,onChange:s,caller:fo});return c.jsx($v,{scope:t,triggerRef:a,contentRef:l,contentId:qt(),titleId:qt(),descriptionId:qt(),open:u,onOpenChange:f,onOpenToggle:d.useCallback(()=>f(p=>!p),[f]),modal:i,children:n})};Xc.displayName=fo;var Jc="DialogTrigger",Fv=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(Jc,n),s=le(t,o.triggerRef);return c.jsx(ie.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Ks(o.open),...r,ref:s,onClick:Z(e.onClick,o.onOpenToggle)})});Fv.displayName=Jc;var Gs="DialogPortal",[Bv,eu]=Zc(Gs,{forceMount:void 0}),tu=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,s=Be(Gs,t);return c.jsx(Bv,{scope:t,forceMount:n,children:d.Children.map(r,i=>c.jsx(En,{present:n||s.open,children:c.jsx(Ss,{asChild:!0,container:o,children:i})}))})};tu.displayName=Gs;var po="DialogOverlay",nu=d.forwardRef((e,t)=>{const n=eu(po,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=Be(po,e.__scopeDialog);return s.modal?c.jsx(En,{present:r||s.open,children:c.jsx(Wv,{...o,ref:t})}):null});nu.displayName=po;var Uv=jv("DialogOverlay.RemoveScroll"),Wv=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(po,n);return c.jsx(ks,{as:Uv,allowPinchZoom:!0,shards:[o.contentRef],children:c.jsx(ie.div,{"data-state":Ks(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Jt="DialogContent",ru=d.forwardRef((e,t)=>{const n=eu(Jt,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=Be(Jt,e.__scopeDialog);return c.jsx(En,{present:r||s.open,children:s.modal?c.jsx(Hv,{...o,ref:t}):c.jsx(Vv,{...o,ref:t})})});ru.displayName=Jt;var Hv=d.forwardRef((e,t)=>{const n=Be(Jt,e.__scopeDialog),r=d.useRef(null),o=le(t,n.contentRef,r);return d.useEffect(()=>{const s=r.current;if(s)return Hl(s)},[]),c.jsx(ou,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Z(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:Z(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&s.preventDefault()}),onFocusOutside:Z(e.onFocusOutside,s=>s.preventDefault())})}),Vv=d.forwardRef((e,t)=>{const n=Be(Jt,e.__scopeDialog),r=d.useRef(!1),o=d.useRef(!1);return c.jsx(ou,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(r.current||(a=n.triggerRef.current)==null||a.focus(),s.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:s=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=s.target;((u=n.triggerRef.current)==null?void 0:u.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),ou=d.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:s,...i}=e,a=Be(Jt,n),l=d.useRef(null),u=le(t,l);return Za(),c.jsxs(c.Fragment,{children:[c.jsx(us,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:s,children:c.jsx(kr,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":Ks(a.open),...i,ref:u,onDismiss:()=>a.onOpenChange(!1)})}),c.jsxs(c.Fragment,{children:[c.jsx(zv,{titleId:a.titleId}),c.jsx(qv,{contentRef:l,descriptionId:a.descriptionId})]})]})}),qs="DialogTitle",su=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(qs,n);return c.jsx(ie.h2,{id:o.titleId,...r,ref:t})});su.displayName=qs;var iu="DialogDescription",au=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(iu,n);return c.jsx(ie.p,{id:o.descriptionId,...r,ref:t})});au.displayName=iu;var lu="DialogClose",cu=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(lu,n);return c.jsx(ie.button,{type:"button",...r,ref:t,onClick:Z(e.onClick,()=>o.onOpenChange(!1))})});cu.displayName=lu;function Ks(e){return e?"open":"closed"}var uu="DialogTitleWarning",[$2,du]=lh(uu,{contentName:Jt,titleName:qs,docsSlug:"dialog"}),zv=({titleId:e})=>{const t=du(uu),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
239
|
+
`)},sg=0,Cn=[];function ig(e){var t=d.useRef([]),n=d.useRef([0,0]),r=d.useRef(),o=d.useState(sg++)[0],s=d.useState(Ql)[0],i=d.useRef(e);d.useEffect(function(){i.current=e},[e]),d.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var h=Kr([e.lockRef.current],(e.shards||[]).map(nc),!0).filter(Boolean);return h.forEach(function(v){return v.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),h.forEach(function(v){return v.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var a=d.useCallback(function(h,v){if("touches"in h&&h.touches.length===2||h.type==="wheel"&&h.ctrlKey)return!i.current.allowPinchZoom;var b=Jr(h),_=n.current,C="deltaX"in h?h.deltaX:_[0]-b[0],T="deltaY"in h?h.deltaY:_[1]-b[1],P,A=h.target,R=Math.abs(C)>Math.abs(T)?"h":"v";if("touches"in h&&R==="h"&&A.type==="range")return!1;var D=window.getSelection(),k=D&&D.anchorNode,N=k?k===A||k.contains(A):!1;if(N)return!1;var U=Xl(R,A);if(!U)return!0;if(U?P=R:(P=R==="v"?"h":"v",U=Xl(R,A)),!U)return!1;if(!r.current&&"changedTouches"in h&&(C||T)&&(r.current=P),!P)return!0;var W=r.current||P;return ng(W,v,h,W==="h"?C:T)},[]),l=d.useCallback(function(h){var v=h;if(!(!Cn.length||Cn[Cn.length-1]!==s)){var b="deltaY"in v?tc(v):Jr(v),_=t.current.filter(function(P){return P.name===v.type&&(P.target===v.target||v.target===P.shadowParent)&&rg(P.delta,b)})[0];if(_&&_.should){v.cancelable&&v.preventDefault();return}if(!_){var C=(i.current.shards||[]).map(nc).filter(Boolean).filter(function(P){return P.contains(v.target)}),T=C.length>0?a(v,C[0]):!i.current.noIsolation;T&&v.cancelable&&v.preventDefault()}}},[]),u=d.useCallback(function(h,v,b,_){var C={name:h,delta:v,target:b,should:_,shadowParent:ag(b)};t.current.push(C),setTimeout(function(){t.current=t.current.filter(function(T){return T!==C})},1)},[]),f=d.useCallback(function(h){n.current=Jr(h),r.current=void 0},[]),p=d.useCallback(function(h){u(h.type,tc(h),h.target,a(h,e.lockRef.current))},[]),m=d.useCallback(function(h){u(h.type,Jr(h),h.target,a(h,e.lockRef.current))},[]);d.useEffect(function(){return Cn.push(s),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:m}),document.addEventListener("wheel",l,xn),document.addEventListener("touchmove",l,xn),document.addEventListener("touchstart",f,xn),function(){Cn=Cn.filter(function(h){return h!==s}),document.removeEventListener("wheel",l,xn),document.removeEventListener("touchmove",l,xn),document.removeEventListener("touchstart",f,xn)}},[]);var g=e.removeScrollBar,y=e.inert;return d.createElement(d.Fragment,null,y?d.createElement(s,{styles:og(o)}):null,g?d.createElement(Q1,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function ag(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const lg=N1(Kl,ig);var ks=d.forwardRef(function(e,t){return d.createElement(Zr,Ye({},e,{ref:t,sideCar:lg}))});ks.classNames=Zr.classNames;var cg=[" ","Enter","ArrowUp","ArrowDown"],ug=[" ","Enter"],Qt="Select",[eo,to,dg]=yh(Qt),[Sn]=Yn(Qt,[dg,Vr]),no=Vr(),[fg,xt]=Sn(Qt),[pg,hg]=Sn(Qt),rc=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:s,value:i,defaultValue:a,onValueChange:l,dir:u,name:f,autoComplete:p,disabled:m,required:g,form:y}=e,h=no(t),[v,b]=d.useState(null),[_,C]=d.useState(null),[T,P]=d.useState(!1),A=wh(u),[R,D]=zr({prop:r,defaultProp:o??!1,onChange:s,caller:Qt}),[k,N]=zr({prop:i,defaultProp:a,onChange:l,caller:Qt}),U=d.useRef(null),W=v?y||!!v.closest("form"):!0,[H,z]=d.useState(new Set),oe=Array.from(H).map(G=>G.props.value).join(";");return c.jsx(Ml,{...h,children:c.jsxs(fg,{required:g,scope:t,trigger:v,onTriggerChange:b,valueNode:_,onValueNodeChange:C,valueNodeHasChildren:T,onValueNodeHasChildrenChange:P,contentId:qt(),value:k,onValueChange:N,open:R,onOpenChange:D,dir:A,triggerPointerDownPosRef:U,disabled:m,children:[c.jsx(eo.Provider,{scope:t,children:c.jsx(pg,{scope:e.__scopeSelect,onNativeOptionAdd:d.useCallback(G=>{z(Y=>new Set(Y).add(G))},[]),onNativeOptionRemove:d.useCallback(G=>{z(Y=>{const F=new Set(Y);return F.delete(G),F})},[]),children:n})}),W?c.jsxs(Cc,{"aria-hidden":!0,required:g,tabIndex:-1,name:f,autoComplete:p,value:k,onChange:G=>N(G.target.value),disabled:m,form:y,children:[k===void 0?c.jsx("option",{value:""}):null,Array.from(H)]},oe):null]})})};rc.displayName=Qt;var oc="SelectTrigger",sc=d.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,s=no(n),i=xt(oc,n),a=i.disabled||r,l=le(t,i.onTriggerChange),u=to(n),f=d.useRef("touch"),[p,m,g]=Ec(h=>{const v=u().filter(C=>!C.disabled),b=v.find(C=>C.value===i.value),_=Tc(v,h,b);_!==void 0&&i.onValueChange(_.value)}),y=h=>{a||(i.onOpenChange(!0),g()),h&&(i.triggerPointerDownPosRef.current={x:Math.round(h.pageX),y:Math.round(h.pageY)})};return c.jsx($l,{asChild:!0,...s,children:c.jsx(ie.button,{type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:a,"data-disabled":a?"":void 0,"data-placeholder":Sc(i.value)?"":void 0,...o,ref:l,onClick:Z(o.onClick,h=>{h.currentTarget.focus(),f.current!=="mouse"&&y(h)}),onPointerDown:Z(o.onPointerDown,h=>{f.current=h.pointerType;const v=h.target;v.hasPointerCapture(h.pointerId)&&v.releasePointerCapture(h.pointerId),h.button===0&&h.ctrlKey===!1&&h.pointerType==="mouse"&&(y(h),h.preventDefault())}),onKeyDown:Z(o.onKeyDown,h=>{const v=p.current!=="";!(h.ctrlKey||h.altKey||h.metaKey)&&h.key.length===1&&m(h.key),!(v&&h.key===" ")&&cg.includes(h.key)&&(y(),h.preventDefault())})})})});sc.displayName=oc;var ic="SelectValue",ac=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:s,placeholder:i="",...a}=e,l=xt(ic,n),{onValueNodeHasChildrenChange:u}=l,f=s!==void 0,p=le(t,l.onValueNodeChange);return ve(()=>{u(f)},[u,f]),c.jsx(ie.span,{...a,ref:p,style:{pointerEvents:"none"},children:Sc(l.value)?c.jsx(c.Fragment,{children:i}):s})});ac.displayName=ic;var mg="SelectIcon",lc=d.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return c.jsx(ie.span,{"aria-hidden":!0,...o,ref:t,children:r||"▼"})});lc.displayName=mg;var Yt="SelectContent",cc=d.forwardRef((e,t)=>{const n=xt(Yt,e.__scopeSelect),[r,o]=d.useState();if(ve(()=>{o(new DocumentFragment)},[]),!n.open){const s=r;return s?mr.createPortal(c.jsx(uc,{scope:e.__scopeSelect,children:c.jsx(eo.Slot,{scope:e.__scopeSelect,children:c.jsx("div",{children:e.children})})}),s):null}return c.jsx(dc,{...e,ref:t})});cc.displayName=Yt;var Fe=10,[uc,Ct]=Sn(Yt),gg="SelectContentImpl",vg=p1("SelectContent.RemoveScroll"),dc=d.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:s,onPointerDownOutside:i,side:a,sideOffset:l,align:u,alignOffset:f,arrowPadding:p,collisionBoundary:m,collisionPadding:g,sticky:y,hideWhenDetached:h,avoidCollisions:v,...b}=e,_=xt(Yt,n),[C,T]=d.useState(null),[P,A]=d.useState(null),R=le(t,$=>T($)),[D,k]=d.useState(null),[N,U]=d.useState(null),W=to(n),[H,z]=d.useState(!1),oe=d.useRef(!1);d.useEffect(()=>{if(C)return Vl(C)},[C]),Xa();const G=d.useCallback($=>{const[te,...fe]=W().map(J=>J.ref.current),[X]=fe.slice(-1),ne=document.activeElement;for(const J of $)if(J===ne||(J==null||J.scrollIntoView({block:"nearest"}),J===te&&P&&(P.scrollTop=0),J===X&&P&&(P.scrollTop=P.scrollHeight),J==null||J.focus(),document.activeElement!==ne))return},[W,P]),Y=d.useCallback(()=>G([D,C]),[G,D,C]);d.useEffect(()=>{H&&Y()},[H,Y]);const{onOpenChange:F,triggerPointerDownPosRef:se}=_;d.useEffect(()=>{if(C){let $={x:0,y:0};const te=X=>{var ne,J;$={x:Math.abs(Math.round(X.pageX)-(((ne=se.current)==null?void 0:ne.x)??0)),y:Math.abs(Math.round(X.pageY)-(((J=se.current)==null?void 0:J.y)??0))}},fe=X=>{$.x<=10&&$.y<=10?X.preventDefault():C.contains(X.target)||F(!1),document.removeEventListener("pointermove",te),se.current=null};return se.current!==null&&(document.addEventListener("pointermove",te),document.addEventListener("pointerup",fe,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",te),document.removeEventListener("pointerup",fe,{capture:!0})}}},[C,F,se]),d.useEffect(()=>{const $=()=>F(!1);return window.addEventListener("blur",$),window.addEventListener("resize",$),()=>{window.removeEventListener("blur",$),window.removeEventListener("resize",$)}},[F]);const[ge,ke]=Ec($=>{const te=W().filter(ne=>!ne.disabled),fe=te.find(ne=>ne.ref.current===document.activeElement),X=Tc(te,$,fe);X&&setTimeout(()=>X.ref.current.focus())}),Mt=d.useCallback(($,te,fe)=>{const X=!oe.current&&!fe;(_.value!==void 0&&_.value===te||X)&&(k($),X&&(oe.current=!0))},[_.value]),$t=d.useCallback(()=>C==null?void 0:C.focus(),[C]),rt=d.useCallback(($,te,fe)=>{const X=!oe.current&&!fe;(_.value!==void 0&&_.value===te||X)&&U($)},[_.value]),Ft=r==="popper"?Ls:fc,Ve=Ft===Ls?{side:a,sideOffset:l,align:u,alignOffset:f,arrowPadding:p,collisionBoundary:m,collisionPadding:g,sticky:y,hideWhenDetached:h,avoidCollisions:v}:{};return c.jsx(uc,{scope:n,content:C,viewport:P,onViewportChange:A,itemRefCallback:Mt,selectedItem:D,onItemLeave:$t,itemTextRefCallback:rt,focusSelectedItem:Y,selectedItemText:N,position:r,isPositioned:H,searchRef:ge,children:c.jsx(ks,{as:vg,allowPinchZoom:!0,children:c.jsx(us,{asChild:!0,trapped:_.open,onMountAutoFocus:$=>{$.preventDefault()},onUnmountAutoFocus:Z(o,$=>{var te;(te=_.trigger)==null||te.focus({preventScroll:!0}),$.preventDefault()}),children:c.jsx(kr,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:$=>$.preventDefault(),onDismiss:()=>_.onOpenChange(!1),children:c.jsx(Ft,{role:"listbox",id:_.contentId,"data-state":_.open?"open":"closed",dir:_.dir,onContextMenu:$=>$.preventDefault(),...b,...Ve,onPlaced:()=>z(!0),ref:R,style:{display:"flex",flexDirection:"column",outline:"none",...b.style},onKeyDown:Z(b.onKeyDown,$=>{const te=$.ctrlKey||$.altKey||$.metaKey;if($.key==="Tab"&&$.preventDefault(),!te&&$.key.length===1&&ke($.key),["ArrowUp","ArrowDown","Home","End"].includes($.key)){let X=W().filter(ne=>!ne.disabled).map(ne=>ne.ref.current);if(["ArrowUp","End"].includes($.key)&&(X=X.slice().reverse()),["ArrowUp","ArrowDown"].includes($.key)){const ne=$.target,J=X.indexOf(ne);X=X.slice(J+1)}setTimeout(()=>G(X)),$.preventDefault()}})})})})})})});dc.displayName=gg;var yg="SelectItemAlignedPosition",fc=d.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,s=xt(Yt,n),i=Ct(Yt,n),[a,l]=d.useState(null),[u,f]=d.useState(null),p=le(t,R=>f(R)),m=to(n),g=d.useRef(!1),y=d.useRef(!0),{viewport:h,selectedItem:v,selectedItemText:b,focusSelectedItem:_}=i,C=d.useCallback(()=>{if(s.trigger&&s.valueNode&&a&&u&&h&&v&&b){const R=s.trigger.getBoundingClientRect(),D=u.getBoundingClientRect(),k=s.valueNode.getBoundingClientRect(),N=b.getBoundingClientRect();if(s.dir!=="rtl"){const ne=N.left-D.left,J=k.left-ne,Ce=R.left-J,Le=R.width+Ce,ot=Math.max(Le,D.width),ze=window.innerWidth-Fe,Bt=za(J,[Fe,Math.max(Fe,ze-ot)]);a.style.minWidth=Le+"px",a.style.left=Bt+"px"}else{const ne=D.right-N.right,J=window.innerWidth-k.right-ne,Ce=window.innerWidth-R.right-J,Le=R.width+Ce,ot=Math.max(Le,D.width),ze=window.innerWidth-Fe,Bt=za(J,[Fe,Math.max(Fe,ze-ot)]);a.style.minWidth=Le+"px",a.style.right=Bt+"px"}const U=m(),W=window.innerHeight-Fe*2,H=h.scrollHeight,z=window.getComputedStyle(u),oe=parseInt(z.borderTopWidth,10),G=parseInt(z.paddingTop,10),Y=parseInt(z.borderBottomWidth,10),F=parseInt(z.paddingBottom,10),se=oe+G+H+F+Y,ge=Math.min(v.offsetHeight*5,se),ke=window.getComputedStyle(h),Mt=parseInt(ke.paddingTop,10),$t=parseInt(ke.paddingBottom,10),rt=R.top+R.height/2-Fe,Ft=W-rt,Ve=v.offsetHeight/2,$=v.offsetTop+Ve,te=oe+G+$,fe=se-te;if(te<=rt){const ne=U.length>0&&v===U[U.length-1].ref.current;a.style.bottom="0px";const J=u.clientHeight-h.offsetTop-h.offsetHeight,Ce=Math.max(Ft,Ve+(ne?$t:0)+J+Y),Le=te+Ce;a.style.height=Le+"px"}else{const ne=U.length>0&&v===U[0].ref.current;a.style.top="0px";const Ce=Math.max(rt,oe+h.offsetTop+(ne?Mt:0)+Ve)+fe;a.style.height=Ce+"px",h.scrollTop=te-rt+h.offsetTop}a.style.margin=`${Fe}px 0`,a.style.minHeight=ge+"px",a.style.maxHeight=W+"px",r==null||r(),requestAnimationFrame(()=>g.current=!0)}},[m,s.trigger,s.valueNode,a,u,h,v,b,s.dir,r]);ve(()=>C(),[C]);const[T,P]=d.useState();ve(()=>{u&&P(window.getComputedStyle(u).zIndex)},[u]);const A=d.useCallback(R=>{R&&y.current===!0&&(C(),_==null||_(),y.current=!1)},[C,_]);return c.jsx(wg,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:g,onScrollButtonChange:A,children:c.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:T},children:c.jsx(ie.div,{...o,ref:p,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});fc.displayName=yg;var bg="SelectPopperPosition",Ls=d.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=Fe,...s}=e,i=no(n);return c.jsx(Fl,{...i,...s,ref:t,align:r,collisionPadding:o,style:{boxSizing:"border-box",...s.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Ls.displayName=bg;var[wg,Ds]=Sn(Yt,{}),Ns="SelectViewport",pc=d.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...o}=e,s=Ct(Ns,n),i=Ds(Ns,n),a=le(t,s.onViewportChange),l=d.useRef(0);return c.jsxs(c.Fragment,{children:[c.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),c.jsx(eo.Slot,{scope:n,children:c.jsx(ie.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:Z(o.onScroll,u=>{const f=u.currentTarget,{contentWrapper:p,shouldExpandOnScrollRef:m}=i;if(m!=null&&m.current&&p){const g=Math.abs(l.current-f.scrollTop);if(g>0){const y=window.innerHeight-Fe*2,h=parseFloat(p.style.minHeight),v=parseFloat(p.style.height),b=Math.max(h,v);if(b<y){const _=b+g,C=Math.min(y,_),T=_-C;p.style.height=C+"px",p.style.bottom==="0px"&&(f.scrollTop=T>0?T:0,p.style.justifyContent="flex-end")}}}l.current=f.scrollTop})})})]})});pc.displayName=Ns;var hc="SelectGroup",[_g,xg]=Sn(hc),mc=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=qt();return c.jsx(_g,{scope:n,id:o,children:c.jsx(ie.div,{role:"group","aria-labelledby":o,...r,ref:t})})});mc.displayName=hc;var gc="SelectLabel",Cg=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=xg(gc,n);return c.jsx(ie.div,{id:o.id,...r,ref:t})});Cg.displayName=gc;var ro="SelectItem",[Sg,vc]=Sn(ro),yc=d.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:s,...i}=e,a=xt(ro,n),l=Ct(ro,n),u=a.value===r,[f,p]=d.useState(s??""),[m,g]=d.useState(!1),y=le(t,_=>{var C;return(C=l.itemRefCallback)==null?void 0:C.call(l,_,r,o)}),h=qt(),v=d.useRef("touch"),b=()=>{o||(a.onValueChange(r),a.onOpenChange(!1))};if(r==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return c.jsx(Sg,{scope:n,value:r,disabled:o,textId:h,isSelected:u,onItemTextChange:d.useCallback(_=>{p(C=>C||((_==null?void 0:_.textContent)??"").trim())},[]),children:c.jsx(eo.ItemSlot,{scope:n,value:r,disabled:o,textValue:f,children:c.jsx(ie.div,{role:"option","aria-labelledby":h,"data-highlighted":m?"":void 0,"aria-selected":u&&m,"data-state":u?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...i,ref:y,onFocus:Z(i.onFocus,()=>g(!0)),onBlur:Z(i.onBlur,()=>g(!1)),onClick:Z(i.onClick,()=>{v.current!=="mouse"&&b()}),onPointerUp:Z(i.onPointerUp,()=>{v.current==="mouse"&&b()}),onPointerDown:Z(i.onPointerDown,_=>{v.current=_.pointerType}),onPointerMove:Z(i.onPointerMove,_=>{var C;v.current=_.pointerType,o?(C=l.onItemLeave)==null||C.call(l):v.current==="mouse"&&_.currentTarget.focus({preventScroll:!0})}),onPointerLeave:Z(i.onPointerLeave,_=>{var C;_.currentTarget===document.activeElement&&((C=l.onItemLeave)==null||C.call(l))}),onKeyDown:Z(i.onKeyDown,_=>{var T;((T=l.searchRef)==null?void 0:T.current)!==""&&_.key===" "||(ug.includes(_.key)&&b(),_.key===" "&&_.preventDefault())})})})})});yc.displayName=ro;var er="SelectItemText",bc=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...s}=e,i=xt(er,n),a=Ct(er,n),l=vc(er,n),u=hg(er,n),[f,p]=d.useState(null),m=le(t,b=>p(b),l.onItemTextChange,b=>{var _;return(_=a.itemTextRefCallback)==null?void 0:_.call(a,b,l.value,l.disabled)}),g=f==null?void 0:f.textContent,y=d.useMemo(()=>c.jsx("option",{value:l.value,disabled:l.disabled,children:g},l.value),[l.disabled,l.value,g]),{onNativeOptionAdd:h,onNativeOptionRemove:v}=u;return ve(()=>(h(y),()=>v(y)),[h,v,y]),c.jsxs(c.Fragment,{children:[c.jsx(ie.span,{id:l.textId,...s,ref:m}),l.isSelected&&i.valueNode&&!i.valueNodeHasChildren?mr.createPortal(s.children,i.valueNode):null]})});bc.displayName=er;var wc="SelectItemIndicator",_c=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return vc(wc,n).isSelected?c.jsx(ie.span,{"aria-hidden":!0,...r,ref:t}):null});_c.displayName=wc;var Ms="SelectScrollUpButton",Eg=d.forwardRef((e,t)=>{const n=Ct(Ms,e.__scopeSelect),r=Ds(Ms,e.__scopeSelect),[o,s]=d.useState(!1),i=le(t,r.onScrollButtonChange);return ve(()=>{if(n.viewport&&n.isPositioned){let a=function(){const u=l.scrollTop>0;s(u)};const l=n.viewport;return a(),l.addEventListener("scroll",a),()=>l.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?c.jsx(xc,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:l}=n;a&&l&&(a.scrollTop=a.scrollTop-l.offsetHeight)}}):null});Eg.displayName=Ms;var $s="SelectScrollDownButton",Tg=d.forwardRef((e,t)=>{const n=Ct($s,e.__scopeSelect),r=Ds($s,e.__scopeSelect),[o,s]=d.useState(!1),i=le(t,r.onScrollButtonChange);return ve(()=>{if(n.viewport&&n.isPositioned){let a=function(){const u=l.scrollHeight-l.clientHeight,f=Math.ceil(l.scrollTop)<u;s(f)};const l=n.viewport;return a(),l.addEventListener("scroll",a),()=>l.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?c.jsx(xc,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:l}=n;a&&l&&(a.scrollTop=a.scrollTop+l.offsetHeight)}}):null});Tg.displayName=$s;var xc=d.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,s=Ct("SelectScrollButton",n),i=d.useRef(null),a=to(n),l=d.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return d.useEffect(()=>()=>l(),[l]),ve(()=>{var f;const u=a().find(p=>p.ref.current===document.activeElement);(f=u==null?void 0:u.ref.current)==null||f.scrollIntoView({block:"nearest"})},[a]),c.jsx(ie.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:Z(o.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(r,50))}),onPointerMove:Z(o.onPointerMove,()=>{var u;(u=s.onItemLeave)==null||u.call(s),i.current===null&&(i.current=window.setInterval(r,50))}),onPointerLeave:Z(o.onPointerLeave,()=>{l()})})}),Pg="SelectSeparator",Ag=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return c.jsx(ie.div,{"aria-hidden":!0,...r,ref:t})});Ag.displayName=Pg;var Fs="SelectArrow",Rg=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=no(n),s=xt(Fs,n),i=Ct(Fs,n);return s.open&&i.position==="popper"?c.jsx(Bl,{...o,...r,ref:t}):null});Rg.displayName=Fs;var Og="SelectBubbleInput",Cc=d.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const o=d.useRef(null),s=le(r,o),i=x1(t);return d.useEffect(()=>{const a=o.current;if(!a)return;const l=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(l,"value").set;if(i!==t&&f){const p=new Event("change",{bubbles:!0});f.call(a,t),a.dispatchEvent(p)}},[i,t]),c.jsx(ie.select,{...n,style:{...Ul,...n.style},ref:s,defaultValue:t})});Cc.displayName=Og;function Sc(e){return e===""||e===void 0}function Ec(e){const t=Gt(e),n=d.useRef(""),r=d.useRef(0),o=d.useCallback(i=>{const a=n.current+i;t(a),function l(u){n.current=u,window.clearTimeout(r.current),u!==""&&(r.current=window.setTimeout(()=>l(""),1e3))}(a)},[t]),s=d.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return d.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,s]}function Tc(e,t,n){const o=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let i=Ig(e,Math.max(s,0));o.length===1&&(i=i.filter(u=>u!==n));const l=i.find(u=>u.textValue.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function Ig(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var jg=rc,kg=sc,Lg=ac,Dg=lc,Ng=cc,Mg=pc,$g=mc,Fg=yc,Bg=bc,Ug=_c;const Ze={Container:"Container__xcHXp",Label:"Label__0cZB9",HelperText:"HelperText__m1nA9",Trigger:"Trigger__AyFUd",TriggerIcon:"TriggerIcon__aygFG",Content:"Content__llztG",Viewport:"Viewport__COtSL",Item:"Item__XN1-2",ItemIndicatorContainer:"ItemIndicatorContainer__EQH-X",ItemIndicator:"ItemIndicator__bySSc"},Pc=S.forwardRef(({label:e,helperText:t,value:n,onValueChange:r,options:o,placeholder:s="Select",disabled:i=!1,className:a,name:l},u)=>c.jsxs("div",{className:L(Ze.Container,a),children:[e&&c.jsx("label",{className:Ze.Label,children:e}),c.jsxs(jg,{value:n,onValueChange:r,disabled:i,name:l,children:[c.jsxs(kg,{ref:u,className:Ze.Trigger,children:[c.jsx(Lg,{placeholder:s}),c.jsx(Dg,{className:Ze.TriggerIcon,children:c.jsx(Wg,{})})]}),c.jsx(Ng,{className:Ze.Content,position:"popper",sideOffset:4,children:c.jsx(Mg,{className:Ze.Viewport,children:c.jsx($g,{children:o.map(f=>c.jsxs(Fg,{value:f.value,disabled:f.disabled,className:Ze.Item,children:[c.jsx("div",{className:Ze.ItemIndicatorContainer,children:c.jsx(Ug,{className:Ze.ItemIndicator,children:c.jsx(Hg,{})})}),c.jsx(Bg,{children:f.label})]},f.value))})})})]}),t&&c.jsx("div",{className:Ze.HelperText,children:t})]}));Pc.displayName="Select";const Wg=()=>c.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[c.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.52459 12.7746C6.8907 12.4085 7.4843 12.4085 7.85041 12.7746L10 14.9242L12.1496 12.7746C12.5157 12.4085 13.1093 12.4085 13.4754 12.7746C13.8415 13.1407 13.8415 13.7343 13.4754 14.1004L10.6629 16.9129C10.2968 17.279 9.7032 17.279 9.33709 16.9129L6.52459 14.1004C6.15847 13.7343 6.15847 13.1407 6.52459 12.7746Z",fill:"currentColor"}),c.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M13.4754 7.22541C13.1093 7.59153 12.5157 7.59153 12.1496 7.22541L10 5.07583L7.85041 7.22541C7.4843 7.59153 6.8907 7.59153 6.52459 7.22541C6.15847 6.8593 6.15847 6.2657 6.52459 5.89959L9.33709 3.08709C9.7032 2.72097 10.2968 2.72097 10.6629 3.08709L13.4754 5.89959C13.8415 6.2657 13.8415 6.8593 13.4754 7.22541Z",fill:"currentColor"})]}),Hg=()=>c.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M13.3333 4L6 11.3333L2.66667 8",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Vg={TextArea:"TextArea__pa-A0"},Ac=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Vg.TextArea,t);return c.jsx("textarea",{ref:r,className:o,...n,children:e})});Ac.displayName="TextArea";function zg(e,t){return d.useReducer((n,r)=>t[n][r]??n,e)}var En=e=>{const{present:t,children:n}=e,r=Gg(t),o=typeof n=="function"?n({present:r.isPresent}):d.Children.only(n),s=le(r.ref,qg(o));return typeof n=="function"||r.isPresent?d.cloneElement(o,{ref:s}):null};En.displayName="Presence";function Gg(e){const[t,n]=d.useState(),r=d.useRef(null),o=d.useRef(e),s=d.useRef("none"),i=e?"mounted":"unmounted",[a,l]=zg(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const u=oo(r.current);s.current=a==="mounted"?u:"none"},[a]),ve(()=>{const u=r.current,f=o.current;if(f!==e){const m=s.current,g=oo(u);e?l("MOUNT"):g==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(f&&m!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),ve(()=>{if(t){let u;const f=t.ownerDocument.defaultView??window,p=g=>{const h=oo(r.current).includes(CSS.escape(g.animationName));if(g.target===t&&h&&(l("ANIMATION_END"),!o.current)){const v=t.style.animationFillMode;t.style.animationFillMode="forwards",u=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=v)})}},m=g=>{g.target===t&&(s.current=oo(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{f.clearTimeout(u),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:d.useCallback(u=>{r.current=u?getComputedStyle(u):null,n(u)},[])}}function oo(e){return(e==null?void 0:e.animationName)||"none"}function qg(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Kg=Symbol("radix.slottable");function Qg(e){const t=({children:n})=>c.jsx(c.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=Kg,t}var[so]=Yn("Tooltip",[Vr]),io=Vr(),Rc="TooltipProvider",Yg=700,Bs="tooltip.open",[Zg,Us]=so(Rc),Oc=e=>{const{__scopeTooltip:t,delayDuration:n=Yg,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:s}=e,i=d.useRef(!0),a=d.useRef(!1),l=d.useRef(0);return d.useEffect(()=>{const u=l.current;return()=>window.clearTimeout(u)},[]),c.jsx(Zg,{scope:t,isOpenDelayedRef:i,delayDuration:n,onOpen:d.useCallback(()=>{window.clearTimeout(l.current),i.current=!1},[]),onClose:d.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>i.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:d.useCallback(u=>{a.current=u},[]),disableHoverableContent:o,children:s})};Oc.displayName=Rc;var tr="Tooltip",[Xg,nr]=so(tr),Ic=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o,onOpenChange:s,disableHoverableContent:i,delayDuration:a}=e,l=Us(tr,e.__scopeTooltip),u=io(t),[f,p]=d.useState(null),m=qt(),g=d.useRef(0),y=i??l.disableHoverableContent,h=a??l.delayDuration,v=d.useRef(!1),[b,_]=zr({prop:r,defaultProp:o??!1,onChange:R=>{R?(l.onOpen(),document.dispatchEvent(new CustomEvent(Bs))):l.onClose(),s==null||s(R)},caller:tr}),C=d.useMemo(()=>b?v.current?"delayed-open":"instant-open":"closed",[b]),T=d.useCallback(()=>{window.clearTimeout(g.current),g.current=0,v.current=!1,_(!0)},[_]),P=d.useCallback(()=>{window.clearTimeout(g.current),g.current=0,_(!1)},[_]),A=d.useCallback(()=>{window.clearTimeout(g.current),g.current=window.setTimeout(()=>{v.current=!0,_(!0),g.current=0},h)},[h,_]);return d.useEffect(()=>()=>{g.current&&(window.clearTimeout(g.current),g.current=0)},[]),c.jsx(Ml,{...u,children:c.jsx(Xg,{scope:t,contentId:m,open:b,stateAttribute:C,trigger:f,onTriggerChange:p,onTriggerEnter:d.useCallback(()=>{l.isOpenDelayedRef.current?A():T()},[l.isOpenDelayedRef,A,T]),onTriggerLeave:d.useCallback(()=>{y?P():(window.clearTimeout(g.current),g.current=0)},[P,y]),onOpen:T,onClose:P,disableHoverableContent:y,children:n})})};Ic.displayName=tr;var Ws="TooltipTrigger",jc=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=nr(Ws,n),s=Us(Ws,n),i=io(n),a=d.useRef(null),l=le(t,a,o.onTriggerChange),u=d.useRef(!1),f=d.useRef(!1),p=d.useCallback(()=>u.current=!1,[]);return d.useEffect(()=>()=>document.removeEventListener("pointerup",p),[p]),c.jsx($l,{asChild:!0,...i,children:c.jsx(ie.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:l,onPointerMove:Z(e.onPointerMove,m=>{m.pointerType!=="touch"&&!f.current&&!s.isPointerInTransitRef.current&&(o.onTriggerEnter(),f.current=!0)}),onPointerLeave:Z(e.onPointerLeave,()=>{o.onTriggerLeave(),f.current=!1}),onPointerDown:Z(e.onPointerDown,()=>{o.open&&o.onClose(),u.current=!0,document.addEventListener("pointerup",p,{once:!0})}),onFocus:Z(e.onFocus,()=>{u.current||o.onOpen()}),onBlur:Z(e.onBlur,o.onClose),onClick:Z(e.onClick,o.onClose)})})});jc.displayName=Ws;var Hs="TooltipPortal",[Jg,ev]=so(Hs,{forceMount:void 0}),kc=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,s=nr(Hs,t);return c.jsx(Jg,{scope:t,forceMount:n,children:c.jsx(En,{present:n||s.open,children:c.jsx(Ss,{asChild:!0,container:o,children:r})})})};kc.displayName=Hs;var Tn="TooltipContent",Lc=d.forwardRef((e,t)=>{const n=ev(Tn,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...s}=e,i=nr(Tn,e.__scopeTooltip);return c.jsx(En,{present:r||i.open,children:i.disableHoverableContent?c.jsx(Dc,{side:o,...s,ref:t}):c.jsx(tv,{side:o,...s,ref:t})})}),tv=d.forwardRef((e,t)=>{const n=nr(Tn,e.__scopeTooltip),r=Us(Tn,e.__scopeTooltip),o=d.useRef(null),s=le(t,o),[i,a]=d.useState(null),{trigger:l,onClose:u}=n,f=o.current,{onPointerInTransitChange:p}=r,m=d.useCallback(()=>{a(null),p(!1)},[p]),g=d.useCallback((y,h)=>{const v=y.currentTarget,b={x:y.clientX,y:y.clientY},_=sv(b,v.getBoundingClientRect()),C=iv(b,_),T=av(h.getBoundingClientRect()),P=cv([...C,...T]);a(P),p(!0)},[p]);return d.useEffect(()=>()=>m(),[m]),d.useEffect(()=>{if(l&&f){const y=v=>g(v,f),h=v=>g(v,l);return l.addEventListener("pointerleave",y),f.addEventListener("pointerleave",h),()=>{l.removeEventListener("pointerleave",y),f.removeEventListener("pointerleave",h)}}},[l,f,g,m]),d.useEffect(()=>{if(i){const y=h=>{const v=h.target,b={x:h.clientX,y:h.clientY},_=(l==null?void 0:l.contains(v))||(f==null?void 0:f.contains(v)),C=!lv(b,i);_?m():C&&(m(),u())};return document.addEventListener("pointermove",y),()=>document.removeEventListener("pointermove",y)}},[l,f,i,u,m]),c.jsx(Dc,{...e,ref:s})}),[nv,rv]=so(tr,{isInside:!1}),ov=Qg("TooltipContent"),Dc=d.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:s,onPointerDownOutside:i,...a}=e,l=nr(Tn,n),u=io(n),{onClose:f}=l;return d.useEffect(()=>(document.addEventListener(Bs,f),()=>document.removeEventListener(Bs,f)),[f]),d.useEffect(()=>{if(l.trigger){const p=m=>{const g=m.target;g!=null&&g.contains(l.trigger)&&f()};return window.addEventListener("scroll",p,{capture:!0}),()=>window.removeEventListener("scroll",p,{capture:!0})}},[l.trigger,f]),c.jsx(kr,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:p=>p.preventDefault(),onDismiss:f,children:c.jsxs(Fl,{"data-state":l.stateAttribute,...u,...a,ref:t,style:{...a.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[c.jsx(ov,{children:r}),c.jsx(nv,{scope:n,isInside:!0,children:c.jsx(S1,{id:l.contentId,role:"tooltip",children:o||r})})]})})});Lc.displayName=Tn;var Nc="TooltipArrow",Mc=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=io(n);return rv(Nc,n).isInside?null:c.jsx(Bl,{...o,...r,ref:t})});Mc.displayName=Nc;function sv(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),s=Math.abs(t.left-e.x);switch(Math.min(n,r,o,s)){case s:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function iv(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function av(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function lv(e,t){const{x:n,y:r}=e;let o=!1;for(let s=0,i=t.length-1;s<t.length;i=s++){const a=t[s],l=t[i],u=a.x,f=a.y,p=l.x,m=l.y;f>r!=m>r&&n<(p-u)*(r-f)/(m-f)+u&&(o=!o)}return o}function cv(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),uv(t)}function uv(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const o=e[r];for(;t.length>=2;){const s=t[t.length-1],i=t[t.length-2];if((s.x-i.x)*(o.y-i.y)>=(s.y-i.y)*(o.x-i.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const s=n[n.length-1],i=n[n.length-2];if((s.x-i.x)*(o.y-i.y)>=(s.y-i.y)*(o.x-i.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var dv=Oc,fv=Ic,pv=jc,hv=kc,mv=Lc,gv=Mc;const $c={tooltip:"tooltip__nUuSh",tooltipArrow:"tooltipArrow__W2w-f"},Pn=({children:e,open:t,displayName:n,tooltipContent:r,className:o,disabled:s,delayDuration:i=300,side:a="right",sideOffset:l=0})=>{const[u,f]=S.useState(!1),p=t!==void 0,g=s?!1:p?t:u,y=h=>{s||p||f(h)};return c.jsx(dv,{delayDuration:i,children:c.jsxs(fv,{open:g,onOpenChange:y,children:[c.jsx(pv,{asChild:!0,children:e}),c.jsx(hv,{children:c.jsxs(mv,{className:L($c.tooltip,o),side:a,sideOffset:l,children:[n,r,c.jsx(gv,{className:$c.tooltipArrow})]})})]})})};Pn.displayName="Tooltip";const Fc={truncatedText:"truncatedText__Y-jSd",overflowing:"overflowing__o8TC-"},Bc=({children:e,className:t,tooltipSide:n="top",tooltipClassName:r})=>{const o=S.useRef(null),[s,i]=S.useState(!1);S.useEffect(()=>{const l=()=>{if(o.current){const u=o.current.scrollWidth>o.current.clientWidth;i(u)}};return l(),window.addEventListener("resize",l),()=>{window.removeEventListener("resize",l)}},[e]);const a=c.jsx("span",{ref:o,className:L(Fc.truncatedText,s?Fc.overflowing:"",t||""),children:e});return s?c.jsx(Pn,{tooltipContent:e,side:n,className:r,children:a}):a};Bc.displayName="TextWithTooltip";const rr={SearchInput:"SearchInput__4OFyE",SearchIcon:"SearchIcon__YgnQy",ClearIcon:"ClearIcon__ukRVr",SearchInput__ClearIcon:"SearchInput__ClearIcon__uzVoc",SearchInput__SearchIcon:"SearchInput__SearchIcon__zoDG4"},Vs=S.forwardRef(({className:e,placeholder:t="Type to search...",showClearButton:n=!1,showSearchIcon:r=!0,onClear:o,...s},i)=>{const a=L(rr.SearchInput,n&&rr.SearchInput__ClearIcon,r&&rr.SearchInput__SearchIcon,e),l=L(rr.SearchIcon),u=L(rr.ClearIcon);return c.jsxs("div",{className:a,children:[c.jsx(jr,{ref:i,type:"text",placeholder:t,...s}),r&&c.jsx("svg",{className:l,width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M13 13L10.6667 10.6667M12.3333 6.66667C12.3333 9.79628 9.79628 12.3333 6.66667 12.3333C3.53705 12.3333 1 9.79628 1 6.66667C1 3.53705 3.53705 1 6.66667 1C9.79628 1 12.3333 3.53705 12.3333 6.66667Z",stroke:"#A4A4A4",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})}),n&&c.jsx("svg",{className:u,width:"8",height:"8",viewBox:"0 0 8 8",fill:"none",xmlns:"http://www.w3.org/2000/svg",onClick:o,children:c.jsx("path",{d:"M7.33334 0.666748L0.666672 7.33341M0.666672 0.666748L7.33334 7.33341",stroke:"#818181",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})})]})});Vs.displayName="SearchInput";const Zt={SearchAutocomplete:"SearchAutocomplete__vR9Hk",AutocompleteItem:"AutocompleteItem__YIm7R","AutocompleteItem--canBeSelected":"AutocompleteItem--canBeSelected__jxk4z",AutocompleteHighlighter:"AutocompleteHighlighter__LAFTV",AutocompleteHighlighter__match:"AutocompleteHighlighter__match__Wy1o2",DropdownList:"DropdownList__-fHIk",AutocompleteItemDescription:"AutocompleteItemDescription__4QYN5"},Xt={DropdownList:"DropdownList__QTXXX",dropdownList:"DropdownList__QTXXX","DropdownList--closed":"DropdownList--closed__pdL1Z",dropdownListClosed:"DropdownList--closed__pdL1Z","DropdownList--open":"DropdownList--open__opzc9",dropdownListOpen:"DropdownList--open__opzc9","DropdownList--left":"DropdownList--left__xSwXR",dropdownListLeft:"DropdownList--left__xSwXR"},ao=S.forwardRef(({children:e,className:t,open:n,align:r="right",...o},s)=>{const i=L(Xt.DropdownList,{[Xt["DropdownList--open"]]:n,[Xt["DropdownList--closed"]]:!n,[Xt["DropdownList--left"]]:r==="left"},t);return c.jsx("div",{ref:s,className:i,...o,children:e})});ao.displayName="DropdownList";const or=S.forwardRef(({children:e,className:t,canBeSelected:n=!1,...r},o)=>{const s=L(Zt.AutocompleteItem,{[Zt["AutocompleteItem--canBeSelected"]]:n},t);return c.jsx("div",{ref:o,className:s,role:n?"option":void 0,...r,children:e})});or.displayName="AutocompleteItem";const vv=300,yv={query:"",suggestions:[],loading:!1,error:null},bv=({suggestionFetcher:e,canAdd:t})=>{const[n,r]=S.useState(yv);return S.useEffect(()=>{r(a=>({...a,loading:!0}));const s=async()=>{try{const a=await e(n.query);t&&!a.some(l=>l.value.toLowerCase()===n.query.toLowerCase())&&a.push({label:`Add "${n.query}"`,value:n.query,isNew:!0}),r(l=>({...l,suggestions:a,loading:!1}))}catch(a){r(l=>({...l,suggestions:[],error:a,loading:!1}))}},i=setTimeout(()=>{s()},vv);return()=>{clearTimeout(i)}},[n.query]),{...n,setQuery:s=>{r(i=>({...i,query:s}))}}},Uc=S.forwardRef(({text:e,query:t,className:n,...r},o)=>{const s=L(Zt.AutocompleteHighlighter,n),i=(a,l)=>{const u=a.toLowerCase().indexOf(l.toLowerCase());if(u===-1||l.length===0)return a;const f=a.slice(0,u),p=a.slice(u,u+l.length),m=a.slice(u+l.length);return c.jsxs(c.Fragment,{children:[f,c.jsx("span",{className:Zt.AutocompleteHighlighter__match,children:p}),i(m,l)]})};return c.jsx("div",{ref:o,className:s,...r,children:i(e,t)})});Uc.displayName="AutocompleteHighlighter";const wv=5,Wc=S.forwardRef(({children:e,className:t,canAdd:n,maxSuggestionsShown:r=wv,searchInputProps:o,keepSelectedOption:s,suggestionFetcher:i,onAccept:a,...l},u)=>{const{query:f,setQuery:p,suggestions:m,loading:g}=bv({suggestionFetcher:i,canAdd:n}),[y,h]=S.useState(null),v=f.length>0,b=R=>{p(R.target.value)},_=R=>{a==null||a(R),s?(h(R),p(R.value)):p("")},C=()=>{a==null||a(null),h(null),p("")},T=L(Zt.SearchAutocomplete,t),P=m.slice(0,r),A=m.slice(r);return c.jsxs("div",{ref:u,className:T,...l,children:[c.jsx(Vs,{...o,value:f,onChange:b,showClearButton:!!y,onClear:C}),e,c.jsxs(ao,{className:Zt.DropdownList,open:v&&!y,role:"listbox","aria-label":"Suggestions",children:[g?c.jsx(or,{children:"Loading..."}):P.map(R=>c.jsxs(or,{canBeSelected:!0,onClick:_.bind(null,R),children:[c.jsx(Uc,{text:R.label,query:f}),R.description&&c.jsx("span",{className:Zt.AutocompleteItemDescription,children:R.description})]},R.value)),!g&&A.length>0&&c.jsxs(or,{children:[A.length," more results"]}),v&&m.length===0&&!g&&c.jsx(or,{children:"No results found"})]})]})});Wc.displayName="SearchAutocomplete";const St=e=>{let t=null,n=null;return S.Children.forEach(e.children,r=>{const o=r.props.condition;o===void 0?n=r:!t&&o===!0&&(t=r)}),c.jsx(c.Fragment,{children:t||n})};St.displayName="Show",St.When=({condition:e,children:t})=>c.jsx(c.Fragment,{children:e&&t}),St.Else=({render:e,children:t})=>c.jsx(c.Fragment,{children:e||t});var _v=Symbol.for("react.lazy"),lo=d[" use ".trim().toString()];function xv(e){return typeof e=="object"&&e!==null&&"then"in e}function Hc(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===_v&&"_payload"in e&&xv(e._payload)}function Cv(e){const t=Ev(e),n=d.forwardRef((r,o)=>{let{children:s,...i}=r;Hc(s)&&typeof lo=="function"&&(s=lo(s._payload));const a=d.Children.toArray(s),l=a.find(Pv);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}var Sv=Cv("Slot");function Ev(e){const t=d.forwardRef((n,r)=>{let{children:o,...s}=n;if(Hc(o)&&typeof lo=="function"&&(o=lo(o._payload)),d.isValidElement(o)){const i=Rv(o),a=Av(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Tv=Symbol("radix.slottable");function Pv(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Tv}function Av(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Rv(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const Vc={SkeletonListContainer:"SkeletonListContainer__MKJhE",Skeleton:"Skeleton__Ovpiw"},co=S.forwardRef((e,t)=>{const{children:n,className:r,loading:o,height:s=48,width:i,borderRadius:a,style:l,...u}=e;if(!o&&n)return n;const f=S.isValidElement(n)?Sv:"span";return c.jsx(f,{ref:t,"aria-hidden":!0,className:L(Vc.Skeleton,r),style:{...l,width:i,minWidth:i,height:s,borderRadius:a},"data-inline-skeleton":S.isValidElement(n)?void 0:!0,tabIndex:-1,...u,children:n})});co.displayName="Skeleton";const zc=e=>{const{numberOfItems:t,itemsGap:n=2,itemProps:r}=e,o=Array.from({length:t},(s,i)=>i+1);return c.jsx("div",{className:L(Vc.SkeletonListContainer),style:{gap:n},children:o.map(s=>c.jsx(co,{loading:!0,...r},s))})};zc.displayName="SkeletonList";const Gc={spinner:"spinner__qa7F6",rotate:"rotate__EqlXe","spinner-dark":"spinner-dark__9A9-q",spinnerDark:"spinner-dark__9A9-q","spinner-white":"spinner-white__gRbtI",spinnerWhite:"spinner-white__gRbtI","spinner-success":"spinner-success__otWGm",spinnerSuccess:"spinner-success__otWGm","spinner-danger":"spinner-danger__Bq5DM",spinnerDanger:"spinner-danger__Bq5DM","spinner-warning":"spinner-warning__U900K",spinnerWarning:"spinner-warning__U900K"},qc=({className:e,color:t="white",size:n=80,thickness:r})=>{const o=L(Gc.spinner,Gc[`spinner-${t}`],e),s=r??Math.max(n/12,2);return c.jsx("span",{style:{width:n,height:n,borderWidth:s},className:o})};qc.displayName="Spinner";const uo={switch:"switch__0b2av",disabled:"disabled__KpauE",checked:"checked__2-JV-",thumb:"thumb__fEuKD"},Kc=S.forwardRef(({checked:e,defaultChecked:t=!1,onCheckedChange:n,disabled:r=!1,id:o,className:s,name:i,"aria-label":a,"aria-labelledby":l,"aria-describedby":u,...f},p)=>{const[m,g]=S.useState(t),y=e!==void 0,h=y?!!e:m,v=()=>{if(r)return;const _=!h;y||g(_),n==null||n(_)},b=_=>{(_.key===" "||_.key==="Enter")&&(_.preventDefault(),v())};return c.jsx("button",{ref:p,type:"button",role:"switch","aria-checked":h,"aria-label":a,"aria-labelledby":l,"aria-describedby":u,disabled:r,id:o,name:i,className:L(uo.switch,{[uo.checked]:h,[uo.disabled]:r}),onClick:v,onKeyDown:b,...f,children:c.jsx("span",{className:uo.thumb,"aria-hidden":"true"})})});Kc.displayName="Switch";const Xe={tabsRoot:"tabs-root__ELmdj",tabsList:"tabs-list__rc10N",tabsListHorizontal:"tabs-list--horizontal__e1YW4",tabsListVertical:"tabs-list--vertical__huK05",tabsTrigger:"tabs-trigger__D8R4R",tabsTriggerDisabled:"tabs-trigger--disabled__ezDWc",tabsTriggerHorizontal:"tabs-trigger--horizontal__4jBFV",tabsTriggerActive:"tabs-trigger--active__S-Z-S",tabsTriggerVertical:"tabs-trigger--vertical__dNVIZ",tabsContent:"tabs-content__1d77o"},Qc=S.createContext(null),zs=()=>{const e=S.useContext(Qc);if(!e)throw new Error("Tabs components must be used within a Tabs provider");return e},Ov=({defaultValue:e,value:t,onValueChange:n,orientation:r="horizontal",className:o="",children:s})=>{const[i,a]=S.useState(e||""),l=t!==void 0,u=l?t:i,f=p=>{l||a(p),n==null||n(p)};return c.jsx(Qc.Provider,{value:{value:u,onValueChange:f,orientation:r},children:c.jsx("div",{className:L(Xe.tabsRoot,o),children:s})})},Iv=({className:e="",children:t})=>{const{orientation:n}=zs(),r=S.useRef(null),o=s=>{var u;const i=(u=r.current)==null?void 0:u.querySelectorAll('[role="tab"]:not([disabled])');if(!i)return;const a=Array.from(i).findIndex(f=>f===document.activeElement);let l=a;switch(s.key){case"ArrowLeft":n==="horizontal"&&(s.preventDefault(),l=a>0?a-1:i.length-1);break;case"ArrowRight":n==="horizontal"&&(s.preventDefault(),l=a<i.length-1?a+1:0);break;case"ArrowUp":n==="vertical"&&(s.preventDefault(),l=a>0?a-1:i.length-1);break;case"ArrowDown":n==="vertical"&&(s.preventDefault(),l=a<i.length-1?a+1:0);break;case"Home":s.preventDefault(),l=0;break;case"End":s.preventDefault(),l=i.length-1;break}if(l!==a){const f=i[l];f.focus(),f.click()}};return c.jsx("div",{ref:r,role:"tablist","aria-orientation":n,onKeyDown:o,className:L(Xe.tabsList,n==="horizontal"?Xe.tabsListHorizontal:Xe.tabsListVertical,e),children:t})},jv=({value:e,disabled:t=!1,className:n="",children:r})=>{const{value:o,onValueChange:s,orientation:i}=zs(),a=o===e,l=()=>{t||s(e)};return c.jsx("button",{role:"tab","aria-selected":a,"aria-controls":`content-${e}`,tabIndex:a?0:-1,disabled:t,onClick:l,className:L(Xe.tabsTrigger,i==="horizontal"?Xe.tabsTriggerHorizontal:Xe.tabsTriggerVertical,a&&Xe.tabsTriggerActive,t&&Xe.tabsTriggerDisabled,n),children:r})},kv=({value:e,className:t="",children:n})=>{const{value:r}=zs();return r===e?c.jsx("div",{role:"tabpanel",id:`content-${e}`,"aria-labelledby":`trigger-${e}`,tabIndex:0,className:L(Xe.tabsContent,t),children:n}):null},Yc=({className:e,state:t="open",onClick:n})=>t==="open"?c.jsxs("svg",{className:e,onClick:n,xmlns:"http://www.w3.org/2000/svg",width:"1.5em",height:"1.5em",viewBox:"0 0 14 14",fill:"none",children:[c.jsx("path",{d:"M1.41174 7.41635C1.3323 7.29056 1.29257 7.22766 1.27034 7.13065C1.25364 7.05778 1.25364 6.94287 1.27034 6.87C1.29257 6.77299 1.3323 6.71009 1.41174 6.58431C2.06823 5.54482 4.02232 2.91699 7.00024 2.91699C9.97815 2.91699 11.9322 5.54482 12.5887 6.5843C12.6682 6.71009 12.7079 6.77299 12.7301 6.87C12.7468 6.94287 12.7468 7.05778 12.7301 7.13065C12.7079 7.22766 12.6682 7.29056 12.5887 7.41635C11.9322 8.45584 9.97815 11.0837 7.00024 11.0837C4.02232 11.0837 2.06823 8.45584 1.41174 7.41635Z",stroke:"#818181",strokeWidth:"1.16667",strokeLinecap:"round",strokeLinejoin:"round"}),c.jsx("path",{d:"M7.00024 8.75033C7.96673 8.75033 8.75024 7.96682 8.75024 7.00033C8.75024 6.03383 7.96673 5.25033 7.00024 5.25033C6.03374 5.25033 5.25024 6.03383 5.25024 7.00033C5.25024 7.96682 6.03374 8.75033 7.00024 8.75033Z",stroke:"#818181",strokeWidth:"1.16667",strokeLinecap:"round",strokeLinejoin:"round"})]}):c.jsx("svg",{className:e,onClick:n,xmlns:"http://www.w3.org/2000/svg",width:"1.5em",height:"1.5em",viewBox:"0 0 14 14",fill:"none",children:c.jsx("path",{d:"M6.26672 2.97052C6.50379 2.93547 6.74835 2.91667 7.00024 2.91667C9.97816 2.91667 11.9323 5.54449 12.5887 6.58398C12.6682 6.70979 12.7079 6.7727 12.7302 6.86973C12.7469 6.94259 12.7468 7.05755 12.7301 7.13042C12.7079 7.22744 12.6679 7.29077 12.5879 7.41741C12.413 7.69425 12.1463 8.08331 11.793 8.50527M3.92252 3.9171C2.66131 4.77266 1.8051 5.9613 1.41231 6.58308C1.3325 6.70942 1.29259 6.7726 1.27035 6.86961C1.25364 6.94248 1.25363 7.05742 1.27033 7.13029C1.29257 7.22731 1.33229 7.29022 1.41174 7.41602C2.06823 8.45551 4.02232 11.0833 7.00024 11.0833C8.20098 11.0833 9.23526 10.6561 10.0851 10.078M1.75024 1.75L12.2502 12.25M5.76281 5.76256C5.44612 6.07925 5.25024 6.51675 5.25024 7C5.25024 7.9665 6.03374 8.75 7.00024 8.75C7.48349 8.75 7.92099 8.55413 8.23768 8.23744",stroke:"#818181",strokeWidth:"1.16667",strokeLinecap:"round",strokeLinejoin:"round"})}),Zc={PasswordInput:"PasswordInput__GDJDN",eyeIcon:"eyeIcon__kDExG"},Lv=S.forwardRef((e,t)=>{const[n,r]=S.useState("password"),o=S.useCallback(()=>{r(s=>s==="password"?"text":"password")},[r]);return c.jsxs("div",{className:L(Zc.PasswordInput,e.className),children:[c.jsx(jr,{type:n,...e,ref:t}),c.jsx(Yc,{className:Zc.eyeIcon,onClick:o,state:n==="password"?"open":"closed"})]})});function Dv(e){const t=Nv(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),l=a.find($v);if(l){const u=l.props.children,f=a.map(p=>p===l?d.Children.count(u)>1?d.Children.only(null):d.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:d.isValidElement(u)?d.cloneElement(u,void 0,f):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function Nv(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=Bv(o),a=Fv(s,o.props);return o.type!==d.Fragment&&(a.ref=r?mn(r,i):i),d.cloneElement(o,a)}return d.Children.count(o)>1?d.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Mv=Symbol("radix.slottable");function $v(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Mv}function Fv(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Bv(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var fo="Dialog",[Xc]=Yn(fo),[Uv,Be]=Xc(fo),Jc=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:s,modal:i=!0}=e,a=d.useRef(null),l=d.useRef(null),[u,f]=zr({prop:r,defaultProp:o??!1,onChange:s,caller:fo});return c.jsx(Uv,{scope:t,triggerRef:a,contentRef:l,contentId:qt(),titleId:qt(),descriptionId:qt(),open:u,onOpenChange:f,onOpenToggle:d.useCallback(()=>f(p=>!p),[f]),modal:i,children:n})};Jc.displayName=fo;var eu="DialogTrigger",Wv=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(eu,n),s=le(t,o.triggerRef);return c.jsx(ie.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Ks(o.open),...r,ref:s,onClick:Z(e.onClick,o.onOpenToggle)})});Wv.displayName=eu;var Gs="DialogPortal",[Hv,tu]=Xc(Gs,{forceMount:void 0}),nu=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,s=Be(Gs,t);return c.jsx(Hv,{scope:t,forceMount:n,children:d.Children.map(r,i=>c.jsx(En,{present:n||s.open,children:c.jsx(Ss,{asChild:!0,container:o,children:i})}))})};nu.displayName=Gs;var po="DialogOverlay",ru=d.forwardRef((e,t)=>{const n=tu(po,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=Be(po,e.__scopeDialog);return s.modal?c.jsx(En,{present:r||s.open,children:c.jsx(zv,{...o,ref:t})}):null});ru.displayName=po;var Vv=Dv("DialogOverlay.RemoveScroll"),zv=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(po,n);return c.jsx(ks,{as:Vv,allowPinchZoom:!0,shards:[o.contentRef],children:c.jsx(ie.div,{"data-state":Ks(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Jt="DialogContent",ou=d.forwardRef((e,t)=>{const n=tu(Jt,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=Be(Jt,e.__scopeDialog);return c.jsx(En,{present:r||s.open,children:s.modal?c.jsx(Gv,{...o,ref:t}):c.jsx(qv,{...o,ref:t})})});ou.displayName=Jt;var Gv=d.forwardRef((e,t)=>{const n=Be(Jt,e.__scopeDialog),r=d.useRef(null),o=le(t,n.contentRef,r);return d.useEffect(()=>{const s=r.current;if(s)return Vl(s)},[]),c.jsx(su,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Z(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:Z(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&s.preventDefault()}),onFocusOutside:Z(e.onFocusOutside,s=>s.preventDefault())})}),qv=d.forwardRef((e,t)=>{const n=Be(Jt,e.__scopeDialog),r=d.useRef(!1),o=d.useRef(!1);return c.jsx(su,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(r.current||(a=n.triggerRef.current)==null||a.focus(),s.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:s=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=s.target;((u=n.triggerRef.current)==null?void 0:u.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),su=d.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:s,...i}=e,a=Be(Jt,n),l=d.useRef(null),u=le(t,l);return Xa(),c.jsxs(c.Fragment,{children:[c.jsx(us,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:s,children:c.jsx(kr,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":Ks(a.open),...i,ref:u,onDismiss:()=>a.onOpenChange(!1)})}),c.jsxs(c.Fragment,{children:[c.jsx(Kv,{titleId:a.titleId}),c.jsx(Yv,{contentRef:l,descriptionId:a.descriptionId})]})]})}),qs="DialogTitle",iu=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(qs,n);return c.jsx(ie.h2,{id:o.titleId,...r,ref:t})});iu.displayName=qs;var au="DialogDescription",lu=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(au,n);return c.jsx(ie.p,{id:o.descriptionId,...r,ref:t})});lu.displayName=au;var cu="DialogClose",uu=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Be(cu,n);return c.jsx(ie.button,{type:"button",...r,ref:t,onClick:Z(e.onClick,()=>o.onOpenChange(!1))})});uu.displayName=cu;function Ks(e){return e?"open":"closed"}var du="DialogTitleWarning",[W2,fu]=dh(du,{contentName:Jt,titleName:qs,docsSlug:"dialog"}),Kv=({titleId:e})=>{const t=fu(du),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
240
240
|
|
|
241
241
|
If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
242
242
|
|
|
243
|
-
For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return d.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},Gv="DialogDescriptionWarning",qv=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${du(Gv).contentName}}.`;return d.useEffect(()=>{var s;const o=(s=e.current)==null?void 0:s.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},Kv=Xc,Qv=tu,Yv=nu,Zv=ru,Xv=su,Jv=au,ey=cu;const fu={Overlay:"Overlay__M5Z83",Content:"Content__wAkP4"},en={Header:"Header__VHxNf",Content:"Content__I04qM",Close:"Close__xSN-7",Title:"Title__Dznh6",Description:"Description__ALT2w",Footer:"Footer__-8gzQ",Actions:"Actions__kKF2Q"},pu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Header,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});pu.displayName="Header";const hu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Content,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});hu.displayName="Content";const mu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Footer,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});mu.displayName="Footer";const gu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Title,t);return c.jsx(Xv,{ref:r,className:o,...n,children:e})});gu.displayName="Title";const vu=S.forwardRef(({className:e,...t},n)=>{const r=L(en.Close,e);return c.jsx(ey,{ref:n,asChild:!0,className:r,...t,children:c.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M11 1L1 11M1 1L11 11",stroke:"#A9A9A9",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})});vu.displayName="Close";const yu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Actions,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});yu.displayName="Actions";const bu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Description,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});bu.displayName="Description";const ye=({children:e,onClose:t,open:n=!1,className:r,zIndexLevel:o=0})=>{const s=()=>{t==null||t()},i={zIndex:`calc(var(--platform-modal-layer) + ${o*2})`},a={zIndex:`calc(var(--platform-modal-layer) + ${o*2+1})`};return c.jsx(Kv,{onOpenChange:s,open:n,children:c.jsxs(Qv,{children:[c.jsx(Yv,{className:fu.Overlay,style:i}),c.jsxs(Zv,{children:[c.jsx(Jv,{}),c.jsx("div",{className:L(fu.Content,r),style:a,children:e})]})]})})};ye.displayName="Dialog",ye.Header=pu,ye.Content=hu,ye.Footer=mu,ye.Actions=yu,ye.Title=gu,ye.Description=bu,ye.Close=vu;const wu={pill:"pill__vtGwB","pill--solid":"pill--solid__F-mR4",pillSolid:"pill--solid__F-mR4","pill--outline":"pill--outline__gC-mh",pillOutline:"pill--outline__gC-mh"},ty=({children:e,variant:t="solid",className:n})=>{const r=L(wu.pill,wu[`pill--${t}`],n);return c.jsx("div",{className:r,children:e})},_u={DialogContent:"DialogContent__-WjG9",Message:"Message__AUgVP"},xu=({loading:e,title:t,children:n,className:r,onClose:o,onConfirm:s,zIndexLevel:i=1,...a})=>c.jsxs(ye,{...a,zIndexLevel:i,className:L(_u.DialogContent,r),children:[c.jsxs(ye.Header,{children:[c.jsx(ye.Title,{children:t}),c.jsx(ye.Close,{onClick:o})]}),c.jsx(ye.Content,{children:typeof n=="string"?c.jsx("p",{className:_u.Message,children:n}):n}),c.jsx(ye.Footer,{children:c.jsxs(ye.Actions,{children:[c.jsx(Or,{onClick:o,disabled:e,variant:"outlined",children:"Cancel"}),c.jsx(Or,{onClick:s,disabled:e,loading:e,variant:"contained",children:"Confirm"})]})})]});xu.displayName="ConfirmDialog";const ho={container:"container__AjtYJ",title:"title__A2vCu",description:"description__bP6Ig",mailToText:"mailToText__SdlsE"},Cu=()=>c.jsxs("svg",{width:"200",height:"200",viewBox:"0 0 200 200",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[c.jsx("path",{d:"M184.415 152.221C183.936 151.406 183.401 150.621 182.892 149.824C181.61 147.817 180.327 145.809 179.045 143.801C177.102 140.759 175.159 137.717 173.215 134.676C170.766 130.841 168.316 127.006 165.866 123.171C163.068 118.79 160.27 114.41 157.472 110.03C154.484 105.352 151.496 100.674 148.508 95.9965C145.474 91.2464 142.439 86.4963 139.405 81.7463C136.513 77.2189 133.621 72.6915 130.729 68.1641C128.123 64.084 125.517 60.0039 122.91 55.9238C120.748 52.5389 118.586 49.1541 116.424 45.7692C114.864 43.3273 113.304 40.8854 111.744 38.4436C110.943 37.1899 110.142 35.9362 109.342 34.6825C108.765 33.7802 108.096 32.9744 107.292 32.2572C104.604 29.8584 100.572 29.2302 97.2301 30.5252C94.5951 31.5463 92.6177 33.3853 91.0923 35.7373C90.8768 36.0696 90.6658 36.405 90.4526 36.7387C89.3951 38.3941 88.3378 40.0494 87.2803 41.7049C85.5124 44.4725 83.7444 47.2402 81.9765 50.0079C79.644 53.6594 77.3114 57.3111 74.9788 60.9626C72.2632 65.2138 69.5477 69.465 66.8321 73.7162C63.8817 78.3349 60.9313 82.9536 57.9811 87.5722C54.9542 92.3106 51.9274 97.0491 48.9006 101.787C45.9557 106.398 43.0107 111.008 40.0658 115.618C37.3487 119.872 34.6316 124.125 31.9145 128.379C29.6106 131.986 27.3067 135.592 25.0028 139.199C23.2565 141.933 21.5101 144.667 19.7639 147.4C18.7335 149.013 17.7031 150.626 16.6728 152.239C14.8665 155.067 13.7231 158.171 14.23 161.595C14.9672 166.576 19.2366 170.131 24.2215 170.137C25.559 170.139 26.8963 170.137 28.2338 170.137C30.9198 170.137 33.6058 170.137 36.2918 170.137C40.0725 170.137 43.8533 170.137 47.6341 170.137C52.2557 170.137 56.8772 170.137 61.4989 170.137C66.7339 170.137 71.969 170.137 77.204 170.137C82.7467 170.137 88.2894 170.137 93.8322 170.137C99.4529 170.137 105.074 170.137 110.694 170.137C116.139 170.137 121.584 170.137 127.029 170.137C132.044 170.137 137.06 170.137 142.075 170.137C146.425 170.137 150.776 170.137 155.127 170.137C158.516 170.137 161.904 170.137 165.293 170.137C167.49 170.137 169.686 170.137 171.883 170.137C172.633 170.137 173.384 170.137 174.135 170.137C178.404 170.087 182.136 167.627 184.212 163.932C186.248 160.307 186.562 155.866 184.415 152.221ZM94.0937 37.3471C94.0897 37.3539 94.0862 37.3597 94.0824 37.3661C94.0826 37.3652 94.0831 37.3642 94.0833 37.3632C94.0844 37.3581 94.0909 37.3518 94.0937 37.3471ZM178.584 164.489C178.476 164.538 178.524 164.516 178.584 164.489V164.489ZM180.937 162.79C180.979 162.72 181.118 162.485 181.127 162.498C181.145 162.528 181.058 162.647 180.937 162.79ZM181.821 160.333C181.806 160.446 181.782 160.646 181.773 160.697C181.736 160.919 181.686 161.139 181.637 161.359C181.637 161.359 181.637 161.359 181.637 161.359C181.629 161.377 181.621 161.399 181.61 161.426C181.54 161.604 181.472 161.785 181.406 161.965C181.402 161.977 181.398 161.988 181.394 161.999C181.304 162.16 181.219 162.323 181.123 162.481C181.074 162.562 181.016 162.641 180.97 162.724C180.949 162.762 180.936 162.785 180.93 162.798C180.727 163.035 180.436 163.332 180.388 163.385C180.696 163.049 180.535 163.229 180.318 163.42C180.172 163.548 180.018 163.666 179.869 163.79C179.848 163.807 179.831 163.822 179.816 163.835C179.797 163.845 179.775 163.857 179.747 163.873C179.576 163.97 179.411 164.078 179.238 164.171C179.043 164.277 178.844 164.373 178.642 164.463C178.556 164.494 178.471 164.526 178.384 164.553C177.532 164.819 176.835 164.945 176.084 164.954C175.296 164.954 174.508 164.954 173.719 164.954C171.519 164.954 169.318 164.954 167.118 164.954C163.751 164.954 160.385 164.954 157.019 164.954C152.756 164.954 148.493 164.954 144.231 164.954C139.275 164.954 134.319 164.954 129.364 164.954C123.981 164.954 118.598 164.954 113.215 164.954C107.651 164.954 102.086 164.954 96.5224 164.954C91.024 164.954 85.5255 164.954 80.0271 164.954C74.8407 164.954 69.6543 164.954 64.4679 164.954C59.8401 164.954 55.2123 164.954 50.5846 164.954C46.7784 164.954 42.9721 164.954 39.166 164.954C36.3891 164.954 33.6122 164.954 30.8354 164.954C29.3555 164.954 27.8756 164.954 26.3957 164.954C25.9641 164.954 25.534 164.958 25.1029 164.922C23.4511 164.785 22.11 164.207 20.7626 163.127C20.3445 162.792 19.7301 162.074 19.3142 161.434C19.2096 161.273 19.1102 161.109 19.0161 160.942C18.9707 160.861 18.8013 160.534 18.8105 160.558C18.7451 160.414 18.5329 159.846 18.4422 159.537C18.3467 159.211 18.2692 158.879 18.2129 158.544C18.2174 158.545 18.1876 158.285 18.1815 158.192C18.1669 157.964 18.1617 157.736 18.1651 157.508C18.166 157.455 18.1793 157.245 18.185 157.131C18.2055 157.005 18.2441 156.74 18.2591 156.662C18.2913 156.493 18.3319 156.326 18.3726 156.16C18.2821 156.539 18.4099 156.072 18.4891 155.866C18.518 155.79 18.6652 155.487 18.6846 155.432C18.7383 155.339 18.7932 155.243 18.8125 155.21C18.8692 155.114 18.9282 155.019 18.9875 154.924C19.0003 154.904 19.0137 154.884 19.0265 154.863C19.2211 154.554 19.4201 154.247 19.617 153.939C20.6335 152.348 21.6501 150.756 22.6667 149.165C24.3869 146.472 26.107 143.779 27.8271 141.086C30.0848 137.552 32.3425 134.017 34.6001 130.483C37.2646 126.312 39.9291 122.141 42.5935 117.97C45.5011 113.418 48.4086 108.866 51.3161 104.315C54.3131 99.6229 57.31 94.9312 60.3069 90.2397C63.2394 85.6489 66.172 81.058 69.1045 76.4672C71.819 72.2178 74.5334 67.9683 77.2479 63.719C79.5904 60.0517 81.9331 56.3844 84.2756 52.7172C86.0852 49.8842 87.8948 47.0513 89.7044 44.2184C90.8459 42.4315 91.9873 40.6446 93.1287 38.8578C93.3976 38.4368 93.6701 38.0178 93.9356 37.5945C93.9507 37.5705 93.9737 37.5416 93.9972 37.511C93.8744 37.7231 94.1597 37.2638 94.301 37.0921C94.4017 36.9695 94.5483 36.8114 94.5423 36.8113C94.6372 36.721 94.7333 36.6319 94.8323 36.546C94.9866 36.4121 95.1478 36.2876 95.3084 36.1615C94.9392 36.4513 95.3917 36.1121 95.5441 36.0212C96.7591 35.2961 98.1095 34.9498 99.7068 35.0725C101.356 35.1993 102.702 35.7434 104.07 36.8307C104.685 37.3192 105.311 38.1542 105.817 38.9457C106.592 40.1592 107.367 41.3727 108.142 42.5862C109.667 44.9733 111.192 47.3605 112.717 49.7476C114.838 53.0679 116.959 56.3881 119.08 59.7083C121.629 63.6999 124.179 67.6913 126.729 71.6829C129.579 76.1455 132.43 80.6082 135.281 85.0709C138.267 89.7458 141.253 94.4206 144.239 99.0955C147.207 103.742 150.176 108.388 153.144 113.035C155.94 117.412 158.736 121.789 161.532 126.167C164.002 130.034 166.473 133.902 168.943 137.769C170.935 140.886 172.926 144.003 174.917 147.12C176.27 149.239 177.623 151.357 178.976 153.475C179.551 154.376 180.134 155.272 180.702 156.177C181.138 156.872 181.311 157.219 181.54 157.972C181.6 158.167 181.652 158.363 181.697 158.561C181.711 158.623 181.759 158.873 181.78 158.97C181.787 159.063 181.815 159.319 181.819 159.383C181.831 159.579 181.836 159.775 181.834 159.972C181.834 160.022 181.825 160.217 181.821 160.333Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M98.5821 122.507C99.019 122.759 99.6307 122.629 100.038 122.389C101.205 121.703 101.925 120.275 102.041 118.92C103.115 106.361 106.514 75.1051 106.514 68.3062C106.514 59.902 92.8134 60.6835 92.0664 71.3279C91.6887 76.7103 97.5083 119.581 97.8266 121.187C97.9188 121.652 98.1423 122.253 98.5821 122.507Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M101.841 133.945C101.826 133.94 101.812 133.934 101.797 133.929C98.2767 132.6 94.4012 134.976 93.9964 138.717C93.9765 138.901 93.9636 139.086 93.958 139.272C93.8552 142.712 96.4467 146.126 99.8464 146.664C103.245 147.201 106.896 144.494 107.099 141.059C107.285 137.909 104.789 135.072 101.841 133.945Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M161.729 131.662C161.873 131.367 162.082 130.81 161.71 130.584C161.365 130.375 160.901 130.836 160.768 131.107C156.804 139.201 152.84 147.295 148.877 155.389C147.759 157.67 146.642 159.952 145.525 162.233C145.38 162.528 145.171 163.085 145.543 163.311C145.888 163.52 146.352 163.059 146.485 162.788C150.449 154.694 154.413 146.6 158.377 138.506C159.494 136.225 160.611 133.943 161.729 131.662Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M144.786 152.64C144.441 152.43 143.977 152.891 143.844 153.163C142.363 156.187 140.882 159.21 139.402 162.234C139.257 162.528 139.048 163.085 139.42 163.311C139.765 163.521 140.229 163.06 140.362 162.788C141.843 159.764 143.323 156.741 144.804 153.717C144.948 153.423 145.158 152.866 144.786 152.64Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M136.792 156.459C136.447 156.25 135.983 156.711 135.85 156.982C134.993 158.733 134.136 160.483 133.279 162.233C133.134 162.528 132.925 163.085 133.297 163.311C133.642 163.52 134.106 163.06 134.239 162.788C135.096 161.037 135.953 159.287 136.81 157.537C136.955 157.242 137.164 156.685 136.792 156.459Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M129.1 159.663C128.755 159.454 128.291 159.915 128.158 160.186C127.824 160.869 127.49 161.551 127.155 162.234C127.011 162.528 126.802 163.086 127.174 163.311C127.519 163.521 127.983 163.06 128.116 162.788C128.45 162.106 128.784 161.423 129.118 160.741C129.263 160.447 129.472 159.889 129.1 159.663Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M165.835 137.946C165.979 137.652 166.188 137.094 165.816 136.868C165.471 136.659 165.007 137.12 164.874 137.392C161.72 143.832 158.566 150.273 155.412 156.713C154.511 158.553 153.609 160.393 152.708 162.233C152.564 162.528 152.355 163.085 152.726 163.311C153.071 163.52 153.535 163.06 153.669 162.788C156.823 156.347 159.977 149.907 163.131 143.466C164.032 141.626 164.933 139.786 165.835 137.946Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M169.923 143.153C169.578 142.943 169.114 143.404 168.98 143.676C165.951 149.862 162.921 156.048 159.892 162.234C159.748 162.528 159.538 163.086 159.91 163.311C160.255 163.521 160.719 163.06 160.852 162.788C163.882 156.602 166.911 150.416 169.941 144.23C170.085 143.936 170.294 143.378 169.923 143.153Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M174.332 148.821C173.987 148.611 173.523 149.072 173.39 149.344C171.286 153.64 169.182 157.937 167.077 162.234C166.933 162.528 166.724 163.086 167.095 163.311C167.44 163.521 167.905 163.06 168.038 162.788C170.142 158.492 172.246 154.195 174.351 149.898C174.495 149.604 174.704 149.046 174.332 148.821Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M178.197 155.597C177.852 155.387 177.388 155.848 177.255 156.12C176.257 158.158 175.259 160.196 174.261 162.233C174.117 162.528 173.907 163.085 174.279 163.311C174.624 163.52 175.088 163.06 175.221 162.788C176.219 160.75 177.217 158.712 178.215 156.674C178.36 156.38 178.569 155.823 178.197 155.597Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M97.1962 40.2135C97.3477 39.9803 97.4773 39.477 97.1807 39.2971C96.8678 39.1072 96.5194 39.5265 96.3794 39.7419C94.7034 42.3205 93.0556 44.9176 91.4179 47.5205C88.1743 52.6759 84.976 57.8633 81.9271 63.1367C80.4155 65.7509 78.9283 68.3855 77.5879 71.0925C77.4642 71.3423 77.2879 71.8174 77.6034 72.0088C77.8975 72.1874 78.2905 71.7947 78.4047 71.564C80.9657 66.3919 83.9726 61.4308 86.9671 56.5018C89.7369 51.9427 92.5713 47.4226 95.4474 42.9297C96.0279 42.0228 96.6094 41.1164 97.1962 40.2135Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M75.3224 76.1247C75.0193 75.9408 74.6477 76.3459 74.521 76.5695C74.1645 77.1991 73.808 77.8286 73.4515 78.4581C73.3144 78.7003 73.1605 79.1884 73.467 79.3744C73.77 79.5583 74.1416 79.1532 74.2684 78.9296C74.6248 78.3001 74.9814 77.6705 75.3378 77.0411C75.475 76.7988 75.6288 76.3107 75.3224 76.1247Z",fill:"var(--pae-shell-color-secondary)"})]});Cu.displayName="WarningIcon";const ny="support@bluealba.com",ry="@bluealba/pae-shell-ui",Qs=()=>{const{supportEmail:e=ny}=qi(ry),t=`mailto:${e}?Subject=Support`;return c.jsxs("div",{className:ho.container,children:[c.jsx(Cu,{}),c.jsx("div",{className:ho.title,children:"Oops! Something went wrong"}),c.jsxs("div",{className:ho.description,children:["If the error persists, ",c.jsx("a",{className:ho.mailToText,href:t,children:"contact the administrator."})]})]})};Qs.displayName="ErrorState";const Ue={List:"List__h09XG",list:"List__h09XG",Item:"Item__YMy2i",item:"Item__YMy2i","List--primary":"List--primary__J2pbx",listPrimary:"List--primary__J2pbx","List--secondary":"List--secondary__gi1ao",listSecondary:"List--secondary__gi1ao","Item--selected":"Item--selected__yRWow",itemSelected:"Item--selected__yRWow",Title:"Title__RJmEW",title:"Title__RJmEW",Description:"Description__DGyX2",description:"Description__DGyX2",Actions:"Actions__UHP5l",actions:"Actions__UHP5l",Action:"Action__q-R1I",action:"Action__q-R1I","Item--disabled":"Item--disabled__Ke1u-",itemDisabled:"Item--disabled__Ke1u-","List--small":"List--small__ijoSR",listSmall:"List--small__ijoSR","List--medium":"List--medium__E1FEY",listMedium:"List--medium__E1FEY","List--large":"List--large__T8tfz",listLarge:"List--large__T8tfz",Icon:"Icon__dFr-L",icon:"Icon__dFr-L"},Su=S.forwardRef(({children:e,className:t,selected:n,disabled:r=!1,...o},s)=>{const i=L(Ue.Item,{[Ue["Item--selected"]]:n,[Ue["Item--disabled"]]:r},t);return c.jsx("li",{ref:s,className:i,role:"listitem","aria-disabled":r,...o,children:e})});Su.displayName="Item";const Eu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ue.Title,t);return c.jsx("h3",{ref:r,className:o,...n,children:e})});Eu.displayName="Title";const Tu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ue.Description,t);return c.jsx("p",{ref:r,className:o,...n,children:e})});Tu.displayName="Description";const Ys=({className:e,...t})=>c.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:e,...t,children:[c.jsx("path",{d:"M6 6.5C6.27614 6.5 6.5 6.27614 6.5 6C6.5 5.72386 6.27614 5.5 6 5.5C5.72386 5.5 5.5 5.72386 5.5 6C5.5 6.27614 5.72386 6.5 6 6.5Z",stroke:"#A9A9A9",strokeLinecap:"round",strokeLinejoin:"round"}),c.jsx("path",{d:"M9.5 6.5C9.77614 6.5 10 6.27614 10 6C10 5.72386 9.77614 5.5 9.5 5.5C9.22386 5.5 9 5.72386 9 6C9 6.27614 9.22386 6.5 9.5 6.5Z",stroke:"#A9A9A9",strokeLinecap:"round",strokeLinejoin:"round"}),c.jsx("path",{d:"M2.5 6.5C2.77614 6.5 3 6.27614 3 6C3 5.72386 2.77614 5.5 2.5 5.5C2.22386 5.5 2 5.72386 2 6C2 6.27614 2.22386 6.5 2.5 6.5Z",stroke:"#A9A9A9",strokeLinecap:"round",strokeLinejoin:"round"})]});Ys.displayName="HorizontalDots";const Pu=S.forwardRef(({children:e,className:t,onClick:n,...r},o)=>{const s=S.useRef(null),[i,a]=S.useState(!1),l=L(Ue.Actions,t),u=()=>{const y=Xt["DropdownList--open"],h=Xt["DropdownList--closed"];document.querySelectorAll(`.${y}`).forEach(b=>{b!==s.current&&(b.classList.remove(y),b.classList.add(h))})},f=y=>{y.stopPropagation(),i?p():(a(!0),n==null||n(y))},p=()=>{a(!1)},m=y=>{y.key==="Escape"&&p()},g=y=>{s.current&&!s.current.contains(y.target)&&p()};return S.useEffect(()=>(i?(u(),document.addEventListener("keydown",m),document.addEventListener("click",g)):(document.removeEventListener("keydown",m),document.removeEventListener("click",g)),()=>{document.removeEventListener("keydown",m),document.removeEventListener("click",g)}),[i]),c.jsxs("div",{ref:o,className:l,onClick:f,role:"button",tabIndex:0,"data-testid":"actions",...r,children:[c.jsx(Ys,{}),c.jsx(ao,{align:"left",ref:s,open:i,"data-testid":"actions-dropdown",role:"menu","aria-label":"Actions",children:e})]})});Pu.displayName="Actions";const Au=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ue.Action,t);return c.jsx("button",{ref:r,className:o,...n,children:e})});Au.displayName="Action";const Ru=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ue.Icon,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});Ru.displayName="Icon";const Je=S.forwardRef(({children:e,className:t,size:n="medium",variant:r,...o},s)=>{const i=L(Ue.List,{[Ue[`List--${n}`]]:n,[Ue[`List--${r}`]]:r},t);return c.jsx("ul",{ref:s,className:i,role:"list",...o,children:e})});Je.displayName="List",Je.Item=Su,Je.Badges=rs,Je.Badge=ns,Je.Title=Eu,Je.Description=Tu,Je.Actions=Pu,Je.Action=Au,Je.Icon=Ru;const ct={Navigation:"Navigation__uylxk",PaginationContent:"PaginationContent__UpLw0",PaginationEllipsis:"PaginationEllipsis__perWk",PaginationLink:"PaginationLink__GVUZj",Active:"Active__u1Ahy",Disabled:"Disabled__8WM0y",Prev:"Prev__wp4hc",Next:"Next__eVyL5"},Ou=({className:e,...t})=>c.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:e,...t,children:[c.jsx("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c.jsx("path",{d:"M9 6l6 6l-6 6"})]});Ou.displayName="ChevronRight";const Iu=({className:e,...t})=>c.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:e,...t,children:[c.jsx("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c.jsx("path",{d:"M15 6l-6 6l6 6"})]});Iu.displayName="ChevronLeft";const Zs=({className:e,...t})=>c.jsx("nav",{role:"navigation","aria-label":"pagination",className:L(ct.Navigation,e),...t});Zs.displayName="Pagination";const Xs=d.forwardRef(({className:e,...t},n)=>c.jsx("ul",{ref:n,className:L(ct.PaginationContent,e),...t}));Xs.displayName="PaginationContent";const sr=d.forwardRef(({className:e,...t},n)=>c.jsx("li",{ref:n,className:e,...t}));sr.displayName="PaginationItem";const ir=({className:e,isActive:t,...n})=>c.jsx("a",{"aria-current":t?"page":void 0,className:L(ct.PaginationLink,t&&ct.Active,e),...n});ir.displayName="PaginationLink";const Js=({className:e,disabled:t,...n})=>c.jsxs(ir,{"aria-label":"Go to previous page",className:L(t&&ct.Disabled,ct.Prev,e),...n,children:[c.jsx(Iu,{}),c.jsx("span",{children:"Previous"})]});Js.displayName="PaginationPrevious";const ei=({className:e,disabled:t,...n})=>c.jsxs(ir,{"aria-label":"Go to next page",className:L(t&&ct.Disabled,ct.Next,e),...n,children:[c.jsx("span",{children:"Next"}),c.jsx(Ou,{})]});ei.displayName="PaginationNext";const ti=({className:e,...t})=>c.jsx("span",{"aria-hidden":!0,className:L(ct.PaginationEllipsis,e),...t,children:c.jsx(Ys,{})});ti.displayName="PaginationEllipsis";function oy(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var ju={exports:{}};(function(e,t){(function(n,r){typeof oy=="function"?e.exports=r():n.pluralize=r()})(df,function(){var n=[],r=[],o={},s={},i={};function a(h){return typeof h=="string"?new RegExp("^"+h+"$","i"):h}function l(h,v){return h===v?v:h===h.toLowerCase()?v.toLowerCase():h===h.toUpperCase()?v.toUpperCase():h[0]===h[0].toUpperCase()?v.charAt(0).toUpperCase()+v.substr(1).toLowerCase():v.toLowerCase()}function u(h,v){return h.replace(/\$(\d{1,2})/g,function(b,_){return v[_]||""})}function f(h,v){return h.replace(v[0],function(b,_){var C=u(v[1],arguments);return l(b===""?h[_-1]:b,C)})}function p(h,v,b){if(!h.length||o.hasOwnProperty(h))return v;for(var _=b.length;_--;){var C=b[_];if(C[0].test(v))return f(v,C)}return v}function m(h,v,b){return function(_){var C=_.toLowerCase();return v.hasOwnProperty(C)?l(_,C):h.hasOwnProperty(C)?l(_,h[C]):p(C,_,b)}}function g(h,v,b,_){return function(C){var T=C.toLowerCase();return v.hasOwnProperty(T)?!0:h.hasOwnProperty(T)?!1:p(T,T,b)===T}}function y(h,v,b){var _=v===1?y.singular(h):y.plural(h);return(b?v+" ":"")+_}return y.plural=m(i,s,n),y.isPlural=g(i,s,n),y.singular=m(s,i,r),y.isSingular=g(s,i,r),y.addPluralRule=function(h,v){n.push([a(h),v])},y.addSingularRule=function(h,v){r.push([a(h),v])},y.addUncountableRule=function(h){if(typeof h=="string"){o[h.toLowerCase()]=!0;return}y.addPluralRule(h,"$0"),y.addSingularRule(h,"$0")},y.addIrregularRule=function(h,v){v=v.toLowerCase(),h=h.toLowerCase(),i[h]=v,s[v]=h},[["I","we"],["me","us"],["he","they"],["she","they"],["them","them"],["myself","ourselves"],["yourself","yourselves"],["itself","themselves"],["herself","themselves"],["himself","themselves"],["themself","themselves"],["is","are"],["was","were"],["has","have"],["this","these"],["that","those"],["echo","echoes"],["dingo","dingoes"],["volcano","volcanoes"],["tornado","tornadoes"],["torpedo","torpedoes"],["genus","genera"],["viscus","viscera"],["stigma","stigmata"],["stoma","stomata"],["dogma","dogmata"],["lemma","lemmata"],["schema","schemata"],["anathema","anathemata"],["ox","oxen"],["axe","axes"],["die","dice"],["yes","yeses"],["foot","feet"],["eave","eaves"],["goose","geese"],["tooth","teeth"],["quiz","quizzes"],["human","humans"],["proof","proofs"],["carve","carves"],["valve","valves"],["looey","looies"],["thief","thieves"],["groove","grooves"],["pickaxe","pickaxes"],["passerby","passersby"]].forEach(function(h){return y.addIrregularRule(h[0],h[1])}),[[/s?$/i,"s"],[/[^\u0000-\u007F]$/i,"$0"],[/([^aeiou]ese)$/i,"$1"],[/(ax|test)is$/i,"$1es"],[/(alias|[^aou]us|t[lm]as|gas|ris)$/i,"$1es"],[/(e[mn]u)s?$/i,"$1s"],[/([^l]ias|[aeiou]las|[ejzr]as|[iu]am)$/i,"$1"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1i"],[/(alumn|alg|vertebr)(?:a|ae)$/i,"$1ae"],[/(seraph|cherub)(?:im)?$/i,"$1im"],[/(her|at|gr)o$/i,"$1oes"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|automat|quor)(?:a|um)$/i,"$1a"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)(?:a|on)$/i,"$1a"],[/sis$/i,"ses"],[/(?:(kni|wi|li)fe|(ar|l|ea|eo|oa|hoo)f)$/i,"$1$2ves"],[/([^aeiouy]|qu)y$/i,"$1ies"],[/([^ch][ieo][ln])ey$/i,"$1ies"],[/(x|ch|ss|sh|zz)$/i,"$1es"],[/(matr|cod|mur|sil|vert|ind|append)(?:ix|ex)$/i,"$1ices"],[/\b((?:tit)?m|l)(?:ice|ouse)$/i,"$1ice"],[/(pe)(?:rson|ople)$/i,"$1ople"],[/(child)(?:ren)?$/i,"$1ren"],[/eaux$/i,"$0"],[/m[ae]n$/i,"men"],["thou","you"]].forEach(function(h){return y.addPluralRule(h[0],h[1])}),[[/s$/i,""],[/(ss)$/i,"$1"],[/(wi|kni|(?:after|half|high|low|mid|non|night|[^\w]|^)li)ves$/i,"$1fe"],[/(ar|(?:wo|[ae])l|[eo][ao])ves$/i,"$1f"],[/ies$/i,"y"],[/\b([pl]|zomb|(?:neck|cross)?t|coll|faer|food|gen|goon|group|lass|talk|goal|cut)ies$/i,"$1ie"],[/\b(mon|smil)ies$/i,"$1ey"],[/\b((?:tit)?m|l)ice$/i,"$1ouse"],[/(seraph|cherub)im$/i,"$1"],[/(x|ch|ss|sh|zz|tto|go|cho|alias|[^aou]us|t[lm]as|gas|(?:her|at|gr)o|[aeiou]ris)(?:es)?$/i,"$1"],[/(analy|diagno|parenthe|progno|synop|the|empha|cri|ne)(?:sis|ses)$/i,"$1sis"],[/(movie|twelve|abuse|e[mn]u)s$/i,"$1"],[/(test)(?:is|es)$/i,"$1is"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1us"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|quor)a$/i,"$1um"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)a$/i,"$1on"],[/(alumn|alg|vertebr)ae$/i,"$1a"],[/(cod|mur|sil|vert|ind)ices$/i,"$1ex"],[/(matr|append)ices$/i,"$1ix"],[/(pe)(rson|ople)$/i,"$1rson"],[/(child)ren$/i,"$1"],[/(eau)x?$/i,"$1"],[/men$/i,"man"]].forEach(function(h){return y.addSingularRule(h[0],h[1])}),["adulthood","advice","agenda","aid","aircraft","alcohol","ammo","analytics","anime","athletics","audio","bison","blood","bream","buffalo","butter","carp","cash","chassis","chess","clothing","cod","commerce","cooperation","corps","debris","diabetes","digestion","elk","energy","equipment","excretion","expertise","firmware","flounder","fun","gallows","garbage","graffiti","hardware","headquarters","health","herpes","highjinks","homework","housework","information","jeans","justice","kudos","labour","literature","machinery","mackerel","mail","media","mews","moose","music","mud","manga","news","only","personnel","pike","plankton","pliers","police","pollution","premises","rain","research","rice","salmon","scissors","series","sewage","shambles","shrimp","software","species","staff","swine","tennis","traffic","transportation","trout","tuna","wealth","welfare","whiting","wildebeest","wildlife","you",/pok[eé]mon$/i,/[^aeiou]ese$/i,/deer$/i,/fish$/i,/measles$/i,/o[iu]s$/i,/pox$/i,/sheep$/i].forEach(y.addUncountableRule),y})})(ju);var sy=ju.exports;const iy=ff(sy),ni=({count:e,singularText:t,children:n=(r,o)=>`${r} ${o}`})=>c.jsx(c.Fragment,{children:n(e,iy(t,e))});ni.displayName="PluralizeCounter";const Ee={TableContainer:"TableContainer__osh6Z",TableHeader:"TableHeader__sYa-8",Table:"Table__2cIs3",selectable:"selectable__WsGg1",Cell:"Cell__ZEv-K",Right:"Right__YoM1V",Center:"Center__CF3tr",Sortable:"Sortable__JIV1V",SortIcon:"SortIcon__f0bBy",Active:"Active__rJjxB",Rotate:"Rotate__7cwTK",Pagination:"Pagination__sbqMP",PointerNone:"PointerNone__kQdQS"},ku={EmptyStateContainer:"EmptyStateContainer__Q9FEb",Message:"Message__IHK6M"},Lu=({size:e=64})=>c.jsxs("svg",{width:e,height:e,viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[c.jsxs("g",{clipPath:"url(#clip-path)",children:[c.jsx("mask",{id:"mask0_1070_8032",style:{maskType:"luminance"},maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"64",height:"64",children:c.jsx("path",{d:"M64 0H0V64H64V0Z",fill:"white"})}),c.jsx("g",{mask:"url(#mask0_1070_8032)",children:c.jsx("path",{d:"M40 10.6673H13.3333V53.334H50.6667V21.334H40V10.6673ZM8 7.97932C8 6.51798 9.192 5.33398 10.664 5.33398H42.6667L56 18.6673V55.982C56.0024 56.3321 55.936 56.6793 55.8043 57.0039C55.6725 57.3284 55.4781 57.6239 55.2323 57.8732C54.9864 58.1225 54.6936 58.3209 54.3712 58.4572C54.0485 58.5935 53.7021 58.6649 53.352 58.6673H10.648C9.94768 58.6625 9.27739 58.3823 8.78192 57.8873C8.28645 57.3924 8.00557 56.7223 8 56.022V7.97932ZM36.0773 38.5233C33.8408 39.83 31.2056 40.2788 28.6627 39.786C26.1197 39.2929 23.8428 37.8921 22.2566 35.8444C20.6704 33.7966 19.883 31.2417 20.0414 28.6564C20.1998 26.071 21.293 23.6315 23.1173 21.7927C24.9532 19.9571 27.3955 18.8541 29.9864 18.6904C32.5773 18.5267 35.1389 19.3134 37.1912 20.9032C39.2435 22.493 40.6456 24.7767 41.1347 27.3263C41.6237 29.8759 41.1664 32.5164 39.848 34.7527L45.7413 40.646L41.9707 44.4193L36.0773 38.5233ZM34.4293 33.1047C34.9387 32.6126 35.3451 32.0241 35.6245 31.3735C35.904 30.7228 36.0512 30.0231 36.0573 29.3148C36.0635 28.6065 35.9285 27.9044 35.6603 27.2489C35.3923 26.5935 34.9963 25.998 34.4955 25.4972C33.9947 24.9964 33.3992 24.6004 32.7437 24.3323C32.0883 24.0641 31.3861 23.9292 30.6779 23.9353C29.9696 23.9415 29.2699 24.0886 28.6192 24.3681C27.9685 24.6476 27.38 25.0539 26.888 25.5633C25.9165 26.5692 25.3789 27.9164 25.3911 29.3148C25.4032 30.7132 25.9641 32.0508 26.9531 33.0396C27.9419 34.0287 29.2795 34.5895 30.6779 34.6015C32.0763 34.6137 33.4235 34.0761 34.4293 33.1047Z",fill:"currentColor"})})]}),c.jsx("defs",{children:c.jsx("clipPath",{id:"clip-path",children:c.jsx("rect",{width:"64",height:"64",fill:"white"})})})]});Lu.displayName="EmptyStateIcon";const ri=({message:e="No results found"})=>c.jsxs("div",{className:L(ku.EmptyStateContainer),children:[c.jsx(Lu,{}),c.jsx("p",{className:ku.Message,children:e})]});ri.displayName="EmptyState";const ay=(e,t,n=1)=>{if(e<=1)return["1"];const r=[],o=s=>{(r.length===0||r[r.length-1]!==s)&&r.push(s)};o(1),t-n>2&&o("...");for(let s=Math.max(2,t-n);s<=Math.min(e-1,t+n);s++)o(s);return t+n<e-1&&o("..."),o(e),r.map(String)},Du=({page:e,totalPages:t,onPageChange:n})=>{const r=e===1,o=e===t;return c.jsx(Zs,{className:Ee.Pagination,children:c.jsxs(Xs,{children:[c.jsx(sr,{children:c.jsx(Js,{className:L({[Ee.PointerNone]:r}),onClick:()=>!r&&n(e-1)})}),ay(t,e).map((s,i)=>c.jsxs(sr,{children:[s==="..."&&c.jsx(ti,{}),s!=="..."&&c.jsx(ir,{isActive:+s===e,onClick:()=>+s!==e&&n(+s),children:s})]},i)),c.jsx(sr,{children:c.jsx(ei,{className:L({[Ee.PointerNone]:o}),onClick:()=>!o&&n(e+1)})})]})})};Du.displayName="TablePagination";const Nu=({className:e,...t})=>c.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:e,...t,children:c.jsx("path",{d:"M6 2.5V9.5M6 9.5L9.5 6M6 9.5L2.5 6",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});Nu.displayName="ArrowDown";const Mu=({columns:e,data:t,isLoading:n,totalCount:r=0,headerLabel:o,sort:s,loadingConfig:i,pagination:a,onRowClick:l})=>{const{count:u=5,height:f=40}=i||{},p=b=>b.sortName??b.name,m=({width:b,maxWidth:_})=>!b&&!_?{}:{...b?{width:b,minWidth:b}:{},..._?{maxWidth:_}:{},overflow:"hidden"},g=b=>L({[Ee.Cell]:!0,[Ee.Center]:b.align==="center",[Ee.Right]:b.align==="right",[Ee.Sortable]:b.isSortable}),y=b=>{if(!s)return"";const _=p(b);return L({[Ee.SortIcon]:!0,[Ee.Active]:b.isSortable&&s.field===_,[Ee.Rotate]:s.field===_&&s.direction==="asc"})},h=b=>()=>l==null?void 0:l(b),v=b=>()=>{if(!s||!b.isSortable)return;const{field:_,direction:C,onSort:T}=s,P=p(b);_===P?T(P,C==="asc"?"desc":"asc"):T(P,"asc")};return c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:Ee.TableContainer,children:[o&&c.jsx("div",{className:Ee.TableHeader,children:c.jsx(ni,{count:r,singularText:o,children:(b,_)=>`${b} ${_}`})}),c.jsx("div",{className:Ee.Table,children:c.jsxs("table",{children:[c.jsx("thead",{children:c.jsx("tr",{children:e.map(b=>c.jsx("th",{children:c.jsxs("div",{className:g(b),onClick:v(b),children:[c.jsx("span",{children:b.displayName}),b.isSortable&&c.jsx(Nu,{className:y(b)})]})},b.name))})}),c.jsx("tbody",{children:c.jsxs(St,{children:[c.jsx(St.When,{condition:n,children:[...Array(u).keys()].map(b=>c.jsx("tr",{children:c.jsx("td",{colSpan:e.length,style:{padding:4},children:c.jsx(co,{height:f})})},b))}),c.jsx(St.When,{condition:!t.length,children:c.jsx("tr",{children:c.jsx("td",{colSpan:e.length,children:c.jsx(ri,{})})})}),c.jsx(St.Else,{children:t.map((b,_)=>c.jsx("tr",{className:l&&Ee.selectable,onClick:h(b),children:e.map(C=>c.jsx("td",{style:m(C),children:c.jsx("div",{className:g(C),children:C.cellRenderer?C.cellRenderer(b):C.valueGetter?C.valueGetter(b):b[C.name]})},`${C.name}-${_}`))},_))})]})})]})})]}),a&&c.jsx(Du,{...a})]})};Mu.displayName="Table";const mo={alert:"alert__LblpE",default:"default__mgO6A",destructive:"destructive__bLNSM",alertTitle:"alertTitle__gblKf",alertDescription:"alertDescription__BuVHV"},go=({className:e,variant:t="default",children:n,...r})=>c.jsx("div",{"data-slot":"alert",role:"alert",className:L(mo.alert,mo[t],e),...r,children:n}),ly=d.forwardRef(({children:e,className:t,...n},r)=>c.jsx("div",{ref:r,"data-slot":"alert-title",className:L(mo.alertTitle,t),...n,children:e})),cy=d.forwardRef(({children:e,className:t,...n},r)=>c.jsx("div",{ref:r,"data-slot":"alert-description",className:L(mo.alertDescription,t),...n,children:e}));go.displayName="Alert",go.Title=ly,go.Description=cy;const $u=S.createContext(null),Fu=({container:e,children:t})=>c.jsx($u.Provider,{value:e,children:t}),uy=()=>S.useContext($u)??void 0,Bu="__paeShadowDom",dy=e=>typeof e=="function"&&e[Bu]===!0,Uu=e=>e==null?void 0:e.moduleName,fy=e=>{const t=new MutationObserver(n=>{n.forEach(({addedNodes:r})=>{r.forEach(o=>{o instanceof HTMLElement&&(o.tagName==="STYLE"||o.tagName==="LINK")&&o.getAttribute("data-pae-module")===e.name&&e.target.appendChild(o)})})});return t.observe(document.head,{childList:!0}),t},py=e=>{const t={shadowHost:null,shadowRoot:null,container:null,portalContainer:null,observer:null,styleEntry:null},n=e.rootComponent,o=ra({...e,rootComponent:f=>c.jsx(Fu,{container:t.portalContainer,children:c.jsx(n,{...f})})}),s=f=>{const p=Ji(f);return t.styleEntry=p,t.observer||(t.observer=fy(p)),p},i=f=>{let p=t.shadowHost;(!p||p.parentNode!==f)&&(p=document.createElement("div"),p.setAttribute("data-pae-module-shadow-host",""),f.appendChild(p));const m=p.shadowRoot??p.attachShadow({mode:"open"}),g=t.styleEntry;if(g){for(;g.holder.firstChild;)m.appendChild(g.holder.firstChild);$o(document.head,m,g.name),g.target=m,g.mode="shadow"}let y=m.querySelector(":scope > [data-pae-module-root]");y||(y=document.createElement("div"),y.setAttribute("data-pae-module-root",""),m.appendChild(y));let h=m.querySelector(":scope > [data-pae-module-portal]");return h||(h=document.createElement("div"),h.setAttribute("data-pae-module-portal",""),m.appendChild(h)),t.shadowHost=p,t.shadowRoot=m,t.container=y,t.portalContainer=h,y},a=async f=>{const p=Uu(f);return p&&s(p),o.bootstrap(f)},l=async f=>{const p=f==null?void 0:f.domElement;if(!p||typeof p.attachShadow!="function")return o.mount(f);const m=Uu(f);m&&!t.styleEntry&&s(m);const g=i(p);return o.mount({...f,domElement:g})};return l[Bu]=!0,{...o,bootstrap:a,mount:l,unmount:async f=>{var y;const p=t.container,m=await o.unmount(p?{...f,domElement:p}:f),g=t.styleEntry;return g&&t.shadowRoot&&($o(t.shadowRoot,g.holder,g.name),g.target=g.holder,g.mode="detached"),(y=t.shadowHost)==null||y.remove(),t.shadowHost=null,t.shadowRoot=null,t.container=null,t.portalContainer=null,m}}},hy=({rootComponent:e,shadowDom:t,...n})=>{const r={errorBoundary(o){return console.error(o),c.jsx(Qs,{})},...n,rootComponent:th(e)};return t?py(r):ra(r)},Et=new Map,my=(e,t)=>{const n=t.mount;dy(n)&&Ji(e)},gy=e=>{try{const{catalog:t}=ko(),n=t.find(r=>r.name===e);return n!=null&&n.version?`${e}@${n.version}`:e}catch{return e}},vo=e=>{const[t,n]=S.useState(null);return S.useEffect(()=>{(async()=>{if(!e){n(null);return}try{const o=gy(e);if(Et.has(o)){const i=Et.get(o);n(i);return}const s=await System.import(e);Et.set(o,s),my(e,s),n(s)}catch(o){console.error(`Error importing module ${e}: ${o.message}`),n(null)}})()},[e,n]),t},vy=e=>{e?(Array.from(Et.keys()).filter(n=>n.startsWith(e)).forEach(n=>Et.delete(n)),console.log(`[useApplicationJSModule] Cleared cache for module: ${e}`)):(Et.clear(),console.log("[useApplicationJSModule] Cleared all module cache"))};typeof window<"u"&&(window.PAE={...window.PAE,clearModuleCache:vy,getModuleCacheSize:()=>Et.size,getModuleCacheKeys:()=>Array.from(Et.keys())});const Wu=e=>{const t=typeof e=="string"?Qi(e):gr(e==null?void 0:e.modules),n=vo(t==null?void 0:t.name);return n==null?void 0:n.icon},Hu=e=>{const t=gr(e==null?void 0:e.modules),n=vo(t==null?void 0:t.name),[r,o]=S.useState(!1),[s,i]=S.useState({}),a=async()=>(typeof(n==null?void 0:n.menu)=="function"?await n.menu():n==null?void 0:n.menu)||[],l=async()=>{if(!(n!=null&&n.menu))return[];o(!0);const p=yy((e==null?void 0:e.operations)||[]),m=(await a()).map(g=>{const{operations:y,items:h,path:v}=g;if(y!=null&&y.length&&!p(y))return null;const b=(h||[]).filter(_=>{var C;return!((C=_==null?void 0:_.operations)!=null&&C.length)||p(_.operations)});return!b.length&&!v?null:{...g,items:b}}).filter(Boolean);return o(!1),m},u=async()=>{const p=await l();e&&i(m=>({...m,[e.name]:p}))};S.useEffect(()=>{u()},[n==null?void 0:n.menu]);const f=S.useMemo(()=>e?s[e.name]||[]:[],[s,e]);return{loading:r,menu:f}},yy=e=>t=>t.every(n=>e.some(r=>r.name===n)),by=e=>Hu(e);function ce(e){return e!=null&&typeof e=="object"&&e["@@functional/placeholder"]===!0}function tn(e){return function t(n){return arguments.length===0||ce(n)?t:e.apply(this,arguments)}}function Tt(e){return function t(n,r){switch(arguments.length){case 0:return t;case 1:return ce(n)?t:tn(function(o){return e(n,o)});default:return ce(n)&&ce(r)?t:ce(n)?tn(function(o){return e(o,r)}):ce(r)?tn(function(o){return e(n,o)}):e(n,r)}}}function oi(e){return function t(n,r,o){switch(arguments.length){case 0:return t;case 1:return ce(n)?t:Tt(function(s,i){return e(n,s,i)});case 2:return ce(n)&&ce(r)?t:ce(n)?Tt(function(s,i){return e(s,r,i)}):ce(r)?Tt(function(s,i){return e(n,s,i)}):tn(function(s){return e(n,r,s)});default:return ce(n)&&ce(r)&&ce(o)?t:ce(n)&&ce(r)?Tt(function(s,i){return e(s,i,o)}):ce(n)&&ce(o)?Tt(function(s,i){return e(s,r,i)}):ce(r)&&ce(o)?Tt(function(s,i){return e(n,s,i)}):ce(n)?tn(function(s){return e(s,r,o)}):ce(r)?tn(function(s){return e(n,s,o)}):ce(o)?tn(function(s){return e(n,r,s)}):e(n,r,o)}}}function yo(e,t){return Object.prototype.hasOwnProperty.call(t,e)}function Vu(e){return Object.prototype.toString.call(e)==="[object Object]"}var wy=oi(function(t,n,r){var o=t(n),s=t(r);return o>s?-1:o<s?1:0}),_y=oi(function(t,n,r){var o={},s;n=n||{},r=r||{};for(s in n)yo(s,n)&&(o[s]=yo(s,r)?t(s,n[s],r[s]):n[s]);for(s in r)yo(s,r)&&!yo(s,o)&&(o[s]=r[s]);return o}),xy=oi(function e(t,n,r){return _y(function(o,s,i){return Vu(s)&&Vu(i)?e(t,s,i):t(o,s,i)},n,r)}),Cy=Tt(function(t,n){return xy(function(r,o,s){return s},t,n)}),Sy=Tt(function(t,n){return Array.prototype.slice.call(n,0).sort(function(r,o){for(var s=0,i=0;s===0&&i<t.length;)s=t[i](r,o),i+=1;return s})});const si=()=>{const e=Fi(),t=Zi();return S.useMemo(()=>Ey(e,t),[e,t])},Ey=(e,t)=>Sy([wy(Ty)],t).find(n=>n.route&&e.startsWith(n.route)),Ty=e=>{var t;return((t=e==null?void 0:e.route)==null?void 0:t.length)||-1},zu=()=>{var e;return(e=si())==null?void 0:e.name},Py=()=>{const e=si(),t=Xi(e);return vo(t==null?void 0:t.name)},ii=(e,t)=>{const r=pn().find(o=>o.name===e);if(!r){if(t)return null;throw new Error(`Service with name [${e}] not available in the catalog`)}return r.baseUrl},ai=(e,t)=>{const n=ii(e,!!t)??t;return S.useCallback((r,o)=>{const i={Accept:"application/json",...(o==null?void 0:o.body)instanceof FormData?{}:{"Content-Type":"application/json"},...o==null?void 0:o.headers};return fetch(Ay(`${n}${r}`),{...o,headers:i})},[n])},Ay=e=>e.replace(/\/+/g,"/"),Ry=["impersonate","impersonate-display-name","tenant"],Gu=(e,t)=>{const n=ii(e,t);return S.useMemo(()=>{if(!n)return null;try{const r=new URL(window.location.href),o=new URL(n,window.location.origin);return Ry.forEach(s=>{const i=r.searchParams.get(s);i&&o.searchParams.set(s,i)}),o.toString()}catch(r){return console.error("Error building WebSocket URL:",r),n}},[n])},Oy=(e,t)=>n=>({timestamp:new Date(new Date().toUTCString()).toISOString(),module:t.name,moduleVersion:t.version,application:t.application,user:e.username,...n}),Iy=(e,t,n)=>async r=>{if(r.length===0)throw new Error("Invalid call to trackEvents with an empty array of events!");const o=await e("/event",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(r.map(Oy(t,n)))});if(!o.ok)throw new Error(`Error publishing habits event ${o.statusText}`)},jy="@bluealba/pae-habits-service",qu=()=>{const{authUser:e}=Gn(),t=zn(),n=ai(jy);return S.useCallback(Iy(n,e,t),[n,e,t])},ky=()=>{const e=qu();return S.useCallback((t,n)=>e([{name:t,data:n}]),[e])},Ku=e=>{const t=zn(),n=window[Mi],[r,o]=S.useState(null);return S.useEffect(()=>n.defineExtensionPoint(t,e,s=>{o(()=>s)}),[o]),r},Qu=(e,t,n)=>{S.useEffect(()=>window[Mi].setExtensionPoint(e,t,n),[])},Yu=(e,t)=>{S.useEffect(()=>(window.addEventListener(e,t),()=>window.removeEventListener(e,t)),[e,t])},Zu=e=>{const{cssCustomizationLoadingDelay:t=1e3}=Do();S.useEffect(()=>{if(!e)return;const n=document.createElement("style");return setTimeout(()=>{n.innerHTML=e,document.head.append(n)},t),()=>n&&n.remove()},[e])},Ly=e=>{var t;return(t=e.split(/[#?]/)[0].split(".").pop())==null?void 0:t.trim()},Dy={woff2:"woff2",woff:"woff",ttf:"truetype",otf:"opentype",eot:"embedded-opentype",svg:"svg"},Ny=e=>{const t=Ly(e);return t?Dy[t]:void 0},My=(e,t)=>{const n=t??Ny(e);return n?`format(${n})`:""};function Xu(e){const[t,n]=S.useState(!1);return S.useEffect(()=>{if(!(e!=null&&e.length))return;const r=document.createElement("style");r.setAttribute("data-generated-fonts","true");const o=e.flatMap(({fontFamily:i,variants:a})=>a.map(({path:l,fontWeight:u,format:f})=>`
|
|
243
|
+
For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return d.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},Qv="DialogDescriptionWarning",Yv=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${fu(Qv).contentName}}.`;return d.useEffect(()=>{var s;const o=(s=e.current)==null?void 0:s.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},Zv=Jc,Xv=nu,Jv=ru,ey=ou,ty=iu,ny=lu,ry=uu;const pu={Overlay:"Overlay__M5Z83",Content:"Content__wAkP4"},en={Header:"Header__VHxNf",Content:"Content__I04qM",Close:"Close__xSN-7",Title:"Title__Dznh6",Description:"Description__ALT2w",Footer:"Footer__-8gzQ",Actions:"Actions__kKF2Q"},hu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Header,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});hu.displayName="Header";const mu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Content,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});mu.displayName="Content";const gu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Footer,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});gu.displayName="Footer";const vu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Title,t);return c.jsx(ty,{ref:r,className:o,...n,children:e})});vu.displayName="Title";const yu=S.forwardRef(({className:e,...t},n)=>{const r=L(en.Close,e);return c.jsx(ry,{ref:n,asChild:!0,className:r,...t,children:c.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M11 1L1 11M1 1L11 11",stroke:"#A9A9A9",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})});yu.displayName="Close";const bu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Actions,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});bu.displayName="Actions";const wu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(en.Description,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});wu.displayName="Description";const ye=({children:e,onClose:t,open:n=!1,className:r,zIndexLevel:o=0})=>{const s=()=>{t==null||t()},i={zIndex:`calc(var(--platform-modal-layer) + ${o*2})`},a={zIndex:`calc(var(--platform-modal-layer) + ${o*2+1})`};return c.jsx(Zv,{onOpenChange:s,open:n,children:c.jsxs(Xv,{children:[c.jsx(Jv,{className:pu.Overlay,style:i}),c.jsxs(ey,{children:[c.jsx(ny,{}),c.jsx("div",{className:L(pu.Content,r),style:a,children:e})]})]})})};ye.displayName="Dialog",ye.Header=hu,ye.Content=mu,ye.Footer=gu,ye.Actions=bu,ye.Title=vu,ye.Description=wu,ye.Close=yu;const _u={pill:"pill__vtGwB","pill--solid":"pill--solid__F-mR4",pillSolid:"pill--solid__F-mR4","pill--outline":"pill--outline__gC-mh",pillOutline:"pill--outline__gC-mh"},oy=({children:e,variant:t="solid",className:n})=>{const r=L(_u.pill,_u[`pill--${t}`],n);return c.jsx("div",{className:r,children:e})},xu={DialogContent:"DialogContent__-WjG9",Message:"Message__AUgVP"},Cu=({loading:e,title:t,children:n,className:r,onClose:o,onConfirm:s,zIndexLevel:i=1,...a})=>c.jsxs(ye,{...a,zIndexLevel:i,className:L(xu.DialogContent,r),children:[c.jsxs(ye.Header,{children:[c.jsx(ye.Title,{children:t}),c.jsx(ye.Close,{onClick:o})]}),c.jsx(ye.Content,{children:typeof n=="string"?c.jsx("p",{className:xu.Message,children:n}):n}),c.jsx(ye.Footer,{children:c.jsxs(ye.Actions,{children:[c.jsx(Or,{onClick:o,disabled:e,variant:"outlined",children:"Cancel"}),c.jsx(Or,{onClick:s,disabled:e,loading:e,variant:"contained",children:"Confirm"})]})})]});Cu.displayName="ConfirmDialog";const ho={container:"container__AjtYJ",title:"title__A2vCu",description:"description__bP6Ig",mailToText:"mailToText__SdlsE"},Su=()=>c.jsxs("svg",{width:"200",height:"200",viewBox:"0 0 200 200",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[c.jsx("path",{d:"M184.415 152.221C183.936 151.406 183.401 150.621 182.892 149.824C181.61 147.817 180.327 145.809 179.045 143.801C177.102 140.759 175.159 137.717 173.215 134.676C170.766 130.841 168.316 127.006 165.866 123.171C163.068 118.79 160.27 114.41 157.472 110.03C154.484 105.352 151.496 100.674 148.508 95.9965C145.474 91.2464 142.439 86.4963 139.405 81.7463C136.513 77.2189 133.621 72.6915 130.729 68.1641C128.123 64.084 125.517 60.0039 122.91 55.9238C120.748 52.5389 118.586 49.1541 116.424 45.7692C114.864 43.3273 113.304 40.8854 111.744 38.4436C110.943 37.1899 110.142 35.9362 109.342 34.6825C108.765 33.7802 108.096 32.9744 107.292 32.2572C104.604 29.8584 100.572 29.2302 97.2301 30.5252C94.5951 31.5463 92.6177 33.3853 91.0923 35.7373C90.8768 36.0696 90.6658 36.405 90.4526 36.7387C89.3951 38.3941 88.3378 40.0494 87.2803 41.7049C85.5124 44.4725 83.7444 47.2402 81.9765 50.0079C79.644 53.6594 77.3114 57.3111 74.9788 60.9626C72.2632 65.2138 69.5477 69.465 66.8321 73.7162C63.8817 78.3349 60.9313 82.9536 57.9811 87.5722C54.9542 92.3106 51.9274 97.0491 48.9006 101.787C45.9557 106.398 43.0107 111.008 40.0658 115.618C37.3487 119.872 34.6316 124.125 31.9145 128.379C29.6106 131.986 27.3067 135.592 25.0028 139.199C23.2565 141.933 21.5101 144.667 19.7639 147.4C18.7335 149.013 17.7031 150.626 16.6728 152.239C14.8665 155.067 13.7231 158.171 14.23 161.595C14.9672 166.576 19.2366 170.131 24.2215 170.137C25.559 170.139 26.8963 170.137 28.2338 170.137C30.9198 170.137 33.6058 170.137 36.2918 170.137C40.0725 170.137 43.8533 170.137 47.6341 170.137C52.2557 170.137 56.8772 170.137 61.4989 170.137C66.7339 170.137 71.969 170.137 77.204 170.137C82.7467 170.137 88.2894 170.137 93.8322 170.137C99.4529 170.137 105.074 170.137 110.694 170.137C116.139 170.137 121.584 170.137 127.029 170.137C132.044 170.137 137.06 170.137 142.075 170.137C146.425 170.137 150.776 170.137 155.127 170.137C158.516 170.137 161.904 170.137 165.293 170.137C167.49 170.137 169.686 170.137 171.883 170.137C172.633 170.137 173.384 170.137 174.135 170.137C178.404 170.087 182.136 167.627 184.212 163.932C186.248 160.307 186.562 155.866 184.415 152.221ZM94.0937 37.3471C94.0897 37.3539 94.0862 37.3597 94.0824 37.3661C94.0826 37.3652 94.0831 37.3642 94.0833 37.3632C94.0844 37.3581 94.0909 37.3518 94.0937 37.3471ZM178.584 164.489C178.476 164.538 178.524 164.516 178.584 164.489V164.489ZM180.937 162.79C180.979 162.72 181.118 162.485 181.127 162.498C181.145 162.528 181.058 162.647 180.937 162.79ZM181.821 160.333C181.806 160.446 181.782 160.646 181.773 160.697C181.736 160.919 181.686 161.139 181.637 161.359C181.637 161.359 181.637 161.359 181.637 161.359C181.629 161.377 181.621 161.399 181.61 161.426C181.54 161.604 181.472 161.785 181.406 161.965C181.402 161.977 181.398 161.988 181.394 161.999C181.304 162.16 181.219 162.323 181.123 162.481C181.074 162.562 181.016 162.641 180.97 162.724C180.949 162.762 180.936 162.785 180.93 162.798C180.727 163.035 180.436 163.332 180.388 163.385C180.696 163.049 180.535 163.229 180.318 163.42C180.172 163.548 180.018 163.666 179.869 163.79C179.848 163.807 179.831 163.822 179.816 163.835C179.797 163.845 179.775 163.857 179.747 163.873C179.576 163.97 179.411 164.078 179.238 164.171C179.043 164.277 178.844 164.373 178.642 164.463C178.556 164.494 178.471 164.526 178.384 164.553C177.532 164.819 176.835 164.945 176.084 164.954C175.296 164.954 174.508 164.954 173.719 164.954C171.519 164.954 169.318 164.954 167.118 164.954C163.751 164.954 160.385 164.954 157.019 164.954C152.756 164.954 148.493 164.954 144.231 164.954C139.275 164.954 134.319 164.954 129.364 164.954C123.981 164.954 118.598 164.954 113.215 164.954C107.651 164.954 102.086 164.954 96.5224 164.954C91.024 164.954 85.5255 164.954 80.0271 164.954C74.8407 164.954 69.6543 164.954 64.4679 164.954C59.8401 164.954 55.2123 164.954 50.5846 164.954C46.7784 164.954 42.9721 164.954 39.166 164.954C36.3891 164.954 33.6122 164.954 30.8354 164.954C29.3555 164.954 27.8756 164.954 26.3957 164.954C25.9641 164.954 25.534 164.958 25.1029 164.922C23.4511 164.785 22.11 164.207 20.7626 163.127C20.3445 162.792 19.7301 162.074 19.3142 161.434C19.2096 161.273 19.1102 161.109 19.0161 160.942C18.9707 160.861 18.8013 160.534 18.8105 160.558C18.7451 160.414 18.5329 159.846 18.4422 159.537C18.3467 159.211 18.2692 158.879 18.2129 158.544C18.2174 158.545 18.1876 158.285 18.1815 158.192C18.1669 157.964 18.1617 157.736 18.1651 157.508C18.166 157.455 18.1793 157.245 18.185 157.131C18.2055 157.005 18.2441 156.74 18.2591 156.662C18.2913 156.493 18.3319 156.326 18.3726 156.16C18.2821 156.539 18.4099 156.072 18.4891 155.866C18.518 155.79 18.6652 155.487 18.6846 155.432C18.7383 155.339 18.7932 155.243 18.8125 155.21C18.8692 155.114 18.9282 155.019 18.9875 154.924C19.0003 154.904 19.0137 154.884 19.0265 154.863C19.2211 154.554 19.4201 154.247 19.617 153.939C20.6335 152.348 21.6501 150.756 22.6667 149.165C24.3869 146.472 26.107 143.779 27.8271 141.086C30.0848 137.552 32.3425 134.017 34.6001 130.483C37.2646 126.312 39.9291 122.141 42.5935 117.97C45.5011 113.418 48.4086 108.866 51.3161 104.315C54.3131 99.6229 57.31 94.9312 60.3069 90.2397C63.2394 85.6489 66.172 81.058 69.1045 76.4672C71.819 72.2178 74.5334 67.9683 77.2479 63.719C79.5904 60.0517 81.9331 56.3844 84.2756 52.7172C86.0852 49.8842 87.8948 47.0513 89.7044 44.2184C90.8459 42.4315 91.9873 40.6446 93.1287 38.8578C93.3976 38.4368 93.6701 38.0178 93.9356 37.5945C93.9507 37.5705 93.9737 37.5416 93.9972 37.511C93.8744 37.7231 94.1597 37.2638 94.301 37.0921C94.4017 36.9695 94.5483 36.8114 94.5423 36.8113C94.6372 36.721 94.7333 36.6319 94.8323 36.546C94.9866 36.4121 95.1478 36.2876 95.3084 36.1615C94.9392 36.4513 95.3917 36.1121 95.5441 36.0212C96.7591 35.2961 98.1095 34.9498 99.7068 35.0725C101.356 35.1993 102.702 35.7434 104.07 36.8307C104.685 37.3192 105.311 38.1542 105.817 38.9457C106.592 40.1592 107.367 41.3727 108.142 42.5862C109.667 44.9733 111.192 47.3605 112.717 49.7476C114.838 53.0679 116.959 56.3881 119.08 59.7083C121.629 63.6999 124.179 67.6913 126.729 71.6829C129.579 76.1455 132.43 80.6082 135.281 85.0709C138.267 89.7458 141.253 94.4206 144.239 99.0955C147.207 103.742 150.176 108.388 153.144 113.035C155.94 117.412 158.736 121.789 161.532 126.167C164.002 130.034 166.473 133.902 168.943 137.769C170.935 140.886 172.926 144.003 174.917 147.12C176.27 149.239 177.623 151.357 178.976 153.475C179.551 154.376 180.134 155.272 180.702 156.177C181.138 156.872 181.311 157.219 181.54 157.972C181.6 158.167 181.652 158.363 181.697 158.561C181.711 158.623 181.759 158.873 181.78 158.97C181.787 159.063 181.815 159.319 181.819 159.383C181.831 159.579 181.836 159.775 181.834 159.972C181.834 160.022 181.825 160.217 181.821 160.333Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M98.5821 122.507C99.019 122.759 99.6307 122.629 100.038 122.389C101.205 121.703 101.925 120.275 102.041 118.92C103.115 106.361 106.514 75.1051 106.514 68.3062C106.514 59.902 92.8134 60.6835 92.0664 71.3279C91.6887 76.7103 97.5083 119.581 97.8266 121.187C97.9188 121.652 98.1423 122.253 98.5821 122.507Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M101.841 133.945C101.826 133.94 101.812 133.934 101.797 133.929C98.2767 132.6 94.4012 134.976 93.9964 138.717C93.9765 138.901 93.9636 139.086 93.958 139.272C93.8552 142.712 96.4467 146.126 99.8464 146.664C103.245 147.201 106.896 144.494 107.099 141.059C107.285 137.909 104.789 135.072 101.841 133.945Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M161.729 131.662C161.873 131.367 162.082 130.81 161.71 130.584C161.365 130.375 160.901 130.836 160.768 131.107C156.804 139.201 152.84 147.295 148.877 155.389C147.759 157.67 146.642 159.952 145.525 162.233C145.38 162.528 145.171 163.085 145.543 163.311C145.888 163.52 146.352 163.059 146.485 162.788C150.449 154.694 154.413 146.6 158.377 138.506C159.494 136.225 160.611 133.943 161.729 131.662Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M144.786 152.64C144.441 152.43 143.977 152.891 143.844 153.163C142.363 156.187 140.882 159.21 139.402 162.234C139.257 162.528 139.048 163.085 139.42 163.311C139.765 163.521 140.229 163.06 140.362 162.788C141.843 159.764 143.323 156.741 144.804 153.717C144.948 153.423 145.158 152.866 144.786 152.64Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M136.792 156.459C136.447 156.25 135.983 156.711 135.85 156.982C134.993 158.733 134.136 160.483 133.279 162.233C133.134 162.528 132.925 163.085 133.297 163.311C133.642 163.52 134.106 163.06 134.239 162.788C135.096 161.037 135.953 159.287 136.81 157.537C136.955 157.242 137.164 156.685 136.792 156.459Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M129.1 159.663C128.755 159.454 128.291 159.915 128.158 160.186C127.824 160.869 127.49 161.551 127.155 162.234C127.011 162.528 126.802 163.086 127.174 163.311C127.519 163.521 127.983 163.06 128.116 162.788C128.45 162.106 128.784 161.423 129.118 160.741C129.263 160.447 129.472 159.889 129.1 159.663Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M165.835 137.946C165.979 137.652 166.188 137.094 165.816 136.868C165.471 136.659 165.007 137.12 164.874 137.392C161.72 143.832 158.566 150.273 155.412 156.713C154.511 158.553 153.609 160.393 152.708 162.233C152.564 162.528 152.355 163.085 152.726 163.311C153.071 163.52 153.535 163.06 153.669 162.788C156.823 156.347 159.977 149.907 163.131 143.466C164.032 141.626 164.933 139.786 165.835 137.946Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M169.923 143.153C169.578 142.943 169.114 143.404 168.98 143.676C165.951 149.862 162.921 156.048 159.892 162.234C159.748 162.528 159.538 163.086 159.91 163.311C160.255 163.521 160.719 163.06 160.852 162.788C163.882 156.602 166.911 150.416 169.941 144.23C170.085 143.936 170.294 143.378 169.923 143.153Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M174.332 148.821C173.987 148.611 173.523 149.072 173.39 149.344C171.286 153.64 169.182 157.937 167.077 162.234C166.933 162.528 166.724 163.086 167.095 163.311C167.44 163.521 167.905 163.06 168.038 162.788C170.142 158.492 172.246 154.195 174.351 149.898C174.495 149.604 174.704 149.046 174.332 148.821Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M178.197 155.597C177.852 155.387 177.388 155.848 177.255 156.12C176.257 158.158 175.259 160.196 174.261 162.233C174.117 162.528 173.907 163.085 174.279 163.311C174.624 163.52 175.088 163.06 175.221 162.788C176.219 160.75 177.217 158.712 178.215 156.674C178.36 156.38 178.569 155.823 178.197 155.597Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M97.1962 40.2135C97.3477 39.9803 97.4773 39.477 97.1807 39.2971C96.8678 39.1072 96.5194 39.5265 96.3794 39.7419C94.7034 42.3205 93.0556 44.9176 91.4179 47.5205C88.1743 52.6759 84.976 57.8633 81.9271 63.1367C80.4155 65.7509 78.9283 68.3855 77.5879 71.0925C77.4642 71.3423 77.2879 71.8174 77.6034 72.0088C77.8975 72.1874 78.2905 71.7947 78.4047 71.564C80.9657 66.3919 83.9726 61.4308 86.9671 56.5018C89.7369 51.9427 92.5713 47.4226 95.4474 42.9297C96.0279 42.0228 96.6094 41.1164 97.1962 40.2135Z",fill:"var(--pae-shell-color-secondary)"}),c.jsx("path",{d:"M75.3224 76.1247C75.0193 75.9408 74.6477 76.3459 74.521 76.5695C74.1645 77.1991 73.808 77.8286 73.4515 78.4581C73.3144 78.7003 73.1605 79.1884 73.467 79.3744C73.77 79.5583 74.1416 79.1532 74.2684 78.9296C74.6248 78.3001 74.9814 77.6705 75.3378 77.0411C75.475 76.7988 75.6288 76.3107 75.3224 76.1247Z",fill:"var(--pae-shell-color-secondary)"})]});Su.displayName="WarningIcon";const sy="support@bluealba.com",iy="@bluealba/pae-shell-ui",Qs=()=>{const{supportEmail:e=sy}=Ki(iy),t=`mailto:${e}?Subject=Support`;return c.jsxs("div",{className:ho.container,children:[c.jsx(Su,{}),c.jsx("div",{className:ho.title,children:"Oops! Something went wrong"}),c.jsxs("div",{className:ho.description,children:["If the error persists, ",c.jsx("a",{className:ho.mailToText,href:t,children:"contact the administrator."})]})]})};Qs.displayName="ErrorState";const Ue={List:"List__h09XG",list:"List__h09XG",Item:"Item__YMy2i",item:"Item__YMy2i","List--primary":"List--primary__J2pbx",listPrimary:"List--primary__J2pbx","List--secondary":"List--secondary__gi1ao",listSecondary:"List--secondary__gi1ao","Item--selected":"Item--selected__yRWow",itemSelected:"Item--selected__yRWow",Title:"Title__RJmEW",title:"Title__RJmEW",Description:"Description__DGyX2",description:"Description__DGyX2",Actions:"Actions__UHP5l",actions:"Actions__UHP5l",Action:"Action__q-R1I",action:"Action__q-R1I","Item--disabled":"Item--disabled__Ke1u-",itemDisabled:"Item--disabled__Ke1u-","List--small":"List--small__ijoSR",listSmall:"List--small__ijoSR","List--medium":"List--medium__E1FEY",listMedium:"List--medium__E1FEY","List--large":"List--large__T8tfz",listLarge:"List--large__T8tfz",Icon:"Icon__dFr-L",icon:"Icon__dFr-L"},Eu=S.forwardRef(({children:e,className:t,selected:n,disabled:r=!1,...o},s)=>{const i=L(Ue.Item,{[Ue["Item--selected"]]:n,[Ue["Item--disabled"]]:r},t);return c.jsx("li",{ref:s,className:i,role:"listitem","aria-disabled":r,...o,children:e})});Eu.displayName="Item";const Tu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ue.Title,t);return c.jsx("h3",{ref:r,className:o,...n,children:e})});Tu.displayName="Title";const Pu=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ue.Description,t);return c.jsx("p",{ref:r,className:o,...n,children:e})});Pu.displayName="Description";const Ys=({className:e,...t})=>c.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:e,...t,children:[c.jsx("path",{d:"M6 6.5C6.27614 6.5 6.5 6.27614 6.5 6C6.5 5.72386 6.27614 5.5 6 5.5C5.72386 5.5 5.5 5.72386 5.5 6C5.5 6.27614 5.72386 6.5 6 6.5Z",stroke:"#A9A9A9",strokeLinecap:"round",strokeLinejoin:"round"}),c.jsx("path",{d:"M9.5 6.5C9.77614 6.5 10 6.27614 10 6C10 5.72386 9.77614 5.5 9.5 5.5C9.22386 5.5 9 5.72386 9 6C9 6.27614 9.22386 6.5 9.5 6.5Z",stroke:"#A9A9A9",strokeLinecap:"round",strokeLinejoin:"round"}),c.jsx("path",{d:"M2.5 6.5C2.77614 6.5 3 6.27614 3 6C3 5.72386 2.77614 5.5 2.5 5.5C2.22386 5.5 2 5.72386 2 6C2 6.27614 2.22386 6.5 2.5 6.5Z",stroke:"#A9A9A9",strokeLinecap:"round",strokeLinejoin:"round"})]});Ys.displayName="HorizontalDots";const Au=S.forwardRef(({children:e,className:t,onClick:n,...r},o)=>{const s=S.useRef(null),[i,a]=S.useState(!1),l=L(Ue.Actions,t),u=()=>{const y=Xt["DropdownList--open"],h=Xt["DropdownList--closed"];document.querySelectorAll(`.${y}`).forEach(b=>{b!==s.current&&(b.classList.remove(y),b.classList.add(h))})},f=y=>{y.stopPropagation(),i?p():(a(!0),n==null||n(y))},p=()=>{a(!1)},m=y=>{y.key==="Escape"&&p()},g=y=>{s.current&&!s.current.contains(y.target)&&p()};return S.useEffect(()=>(i?(u(),document.addEventListener("keydown",m),document.addEventListener("click",g)):(document.removeEventListener("keydown",m),document.removeEventListener("click",g)),()=>{document.removeEventListener("keydown",m),document.removeEventListener("click",g)}),[i]),c.jsxs("div",{ref:o,className:l,onClick:f,role:"button",tabIndex:0,"data-testid":"actions",...r,children:[c.jsx(Ys,{}),c.jsx(ao,{align:"left",ref:s,open:i,"data-testid":"actions-dropdown",role:"menu","aria-label":"Actions",children:e})]})});Au.displayName="Actions";const Ru=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ue.Action,t);return c.jsx("button",{ref:r,className:o,...n,children:e})});Ru.displayName="Action";const Ou=S.forwardRef(({children:e,className:t,...n},r)=>{const o=L(Ue.Icon,t);return c.jsx("div",{ref:r,className:o,...n,children:e})});Ou.displayName="Icon";const Je=S.forwardRef(({children:e,className:t,size:n="medium",variant:r,...o},s)=>{const i=L(Ue.List,{[Ue[`List--${n}`]]:n,[Ue[`List--${r}`]]:r},t);return c.jsx("ul",{ref:s,className:i,role:"list",...o,children:e})});Je.displayName="List",Je.Item=Eu,Je.Badges=rs,Je.Badge=ns,Je.Title=Tu,Je.Description=Pu,Je.Actions=Au,Je.Action=Ru,Je.Icon=Ou;const ct={Navigation:"Navigation__uylxk",PaginationContent:"PaginationContent__UpLw0",PaginationEllipsis:"PaginationEllipsis__perWk",PaginationLink:"PaginationLink__GVUZj",Active:"Active__u1Ahy",Disabled:"Disabled__8WM0y",Prev:"Prev__wp4hc",Next:"Next__eVyL5"},Iu=({className:e,...t})=>c.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:e,...t,children:[c.jsx("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c.jsx("path",{d:"M9 6l6 6l-6 6"})]});Iu.displayName="ChevronRight";const ju=({className:e,...t})=>c.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:e,...t,children:[c.jsx("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),c.jsx("path",{d:"M15 6l-6 6l6 6"})]});ju.displayName="ChevronLeft";const Zs=({className:e,...t})=>c.jsx("nav",{role:"navigation","aria-label":"pagination",className:L(ct.Navigation,e),...t});Zs.displayName="Pagination";const Xs=d.forwardRef(({className:e,...t},n)=>c.jsx("ul",{ref:n,className:L(ct.PaginationContent,e),...t}));Xs.displayName="PaginationContent";const sr=d.forwardRef(({className:e,...t},n)=>c.jsx("li",{ref:n,className:e,...t}));sr.displayName="PaginationItem";const ir=({className:e,isActive:t,...n})=>c.jsx("a",{"aria-current":t?"page":void 0,className:L(ct.PaginationLink,t&&ct.Active,e),...n});ir.displayName="PaginationLink";const Js=({className:e,disabled:t,...n})=>c.jsxs(ir,{"aria-label":"Go to previous page",className:L(t&&ct.Disabled,ct.Prev,e),...n,children:[c.jsx(ju,{}),c.jsx("span",{children:"Previous"})]});Js.displayName="PaginationPrevious";const ei=({className:e,disabled:t,...n})=>c.jsxs(ir,{"aria-label":"Go to next page",className:L(t&&ct.Disabled,ct.Next,e),...n,children:[c.jsx("span",{children:"Next"}),c.jsx(Iu,{})]});ei.displayName="PaginationNext";const ti=({className:e,...t})=>c.jsx("span",{"aria-hidden":!0,className:L(ct.PaginationEllipsis,e),...t,children:c.jsx(Ys,{})});ti.displayName="PaginationEllipsis";function ay(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var ku={exports:{}};(function(e,t){(function(n,r){typeof ay=="function"?e.exports=r():n.pluralize=r()})(hf,function(){var n=[],r=[],o={},s={},i={};function a(h){return typeof h=="string"?new RegExp("^"+h+"$","i"):h}function l(h,v){return h===v?v:h===h.toLowerCase()?v.toLowerCase():h===h.toUpperCase()?v.toUpperCase():h[0]===h[0].toUpperCase()?v.charAt(0).toUpperCase()+v.substr(1).toLowerCase():v.toLowerCase()}function u(h,v){return h.replace(/\$(\d{1,2})/g,function(b,_){return v[_]||""})}function f(h,v){return h.replace(v[0],function(b,_){var C=u(v[1],arguments);return l(b===""?h[_-1]:b,C)})}function p(h,v,b){if(!h.length||o.hasOwnProperty(h))return v;for(var _=b.length;_--;){var C=b[_];if(C[0].test(v))return f(v,C)}return v}function m(h,v,b){return function(_){var C=_.toLowerCase();return v.hasOwnProperty(C)?l(_,C):h.hasOwnProperty(C)?l(_,h[C]):p(C,_,b)}}function g(h,v,b,_){return function(C){var T=C.toLowerCase();return v.hasOwnProperty(T)?!0:h.hasOwnProperty(T)?!1:p(T,T,b)===T}}function y(h,v,b){var _=v===1?y.singular(h):y.plural(h);return(b?v+" ":"")+_}return y.plural=m(i,s,n),y.isPlural=g(i,s,n),y.singular=m(s,i,r),y.isSingular=g(s,i,r),y.addPluralRule=function(h,v){n.push([a(h),v])},y.addSingularRule=function(h,v){r.push([a(h),v])},y.addUncountableRule=function(h){if(typeof h=="string"){o[h.toLowerCase()]=!0;return}y.addPluralRule(h,"$0"),y.addSingularRule(h,"$0")},y.addIrregularRule=function(h,v){v=v.toLowerCase(),h=h.toLowerCase(),i[h]=v,s[v]=h},[["I","we"],["me","us"],["he","they"],["she","they"],["them","them"],["myself","ourselves"],["yourself","yourselves"],["itself","themselves"],["herself","themselves"],["himself","themselves"],["themself","themselves"],["is","are"],["was","were"],["has","have"],["this","these"],["that","those"],["echo","echoes"],["dingo","dingoes"],["volcano","volcanoes"],["tornado","tornadoes"],["torpedo","torpedoes"],["genus","genera"],["viscus","viscera"],["stigma","stigmata"],["stoma","stomata"],["dogma","dogmata"],["lemma","lemmata"],["schema","schemata"],["anathema","anathemata"],["ox","oxen"],["axe","axes"],["die","dice"],["yes","yeses"],["foot","feet"],["eave","eaves"],["goose","geese"],["tooth","teeth"],["quiz","quizzes"],["human","humans"],["proof","proofs"],["carve","carves"],["valve","valves"],["looey","looies"],["thief","thieves"],["groove","grooves"],["pickaxe","pickaxes"],["passerby","passersby"]].forEach(function(h){return y.addIrregularRule(h[0],h[1])}),[[/s?$/i,"s"],[/[^\u0000-\u007F]$/i,"$0"],[/([^aeiou]ese)$/i,"$1"],[/(ax|test)is$/i,"$1es"],[/(alias|[^aou]us|t[lm]as|gas|ris)$/i,"$1es"],[/(e[mn]u)s?$/i,"$1s"],[/([^l]ias|[aeiou]las|[ejzr]as|[iu]am)$/i,"$1"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1i"],[/(alumn|alg|vertebr)(?:a|ae)$/i,"$1ae"],[/(seraph|cherub)(?:im)?$/i,"$1im"],[/(her|at|gr)o$/i,"$1oes"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|automat|quor)(?:a|um)$/i,"$1a"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)(?:a|on)$/i,"$1a"],[/sis$/i,"ses"],[/(?:(kni|wi|li)fe|(ar|l|ea|eo|oa|hoo)f)$/i,"$1$2ves"],[/([^aeiouy]|qu)y$/i,"$1ies"],[/([^ch][ieo][ln])ey$/i,"$1ies"],[/(x|ch|ss|sh|zz)$/i,"$1es"],[/(matr|cod|mur|sil|vert|ind|append)(?:ix|ex)$/i,"$1ices"],[/\b((?:tit)?m|l)(?:ice|ouse)$/i,"$1ice"],[/(pe)(?:rson|ople)$/i,"$1ople"],[/(child)(?:ren)?$/i,"$1ren"],[/eaux$/i,"$0"],[/m[ae]n$/i,"men"],["thou","you"]].forEach(function(h){return y.addPluralRule(h[0],h[1])}),[[/s$/i,""],[/(ss)$/i,"$1"],[/(wi|kni|(?:after|half|high|low|mid|non|night|[^\w]|^)li)ves$/i,"$1fe"],[/(ar|(?:wo|[ae])l|[eo][ao])ves$/i,"$1f"],[/ies$/i,"y"],[/\b([pl]|zomb|(?:neck|cross)?t|coll|faer|food|gen|goon|group|lass|talk|goal|cut)ies$/i,"$1ie"],[/\b(mon|smil)ies$/i,"$1ey"],[/\b((?:tit)?m|l)ice$/i,"$1ouse"],[/(seraph|cherub)im$/i,"$1"],[/(x|ch|ss|sh|zz|tto|go|cho|alias|[^aou]us|t[lm]as|gas|(?:her|at|gr)o|[aeiou]ris)(?:es)?$/i,"$1"],[/(analy|diagno|parenthe|progno|synop|the|empha|cri|ne)(?:sis|ses)$/i,"$1sis"],[/(movie|twelve|abuse|e[mn]u)s$/i,"$1"],[/(test)(?:is|es)$/i,"$1is"],[/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i,"$1us"],[/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|quor)a$/i,"$1um"],[/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)a$/i,"$1on"],[/(alumn|alg|vertebr)ae$/i,"$1a"],[/(cod|mur|sil|vert|ind)ices$/i,"$1ex"],[/(matr|append)ices$/i,"$1ix"],[/(pe)(rson|ople)$/i,"$1rson"],[/(child)ren$/i,"$1"],[/(eau)x?$/i,"$1"],[/men$/i,"man"]].forEach(function(h){return y.addSingularRule(h[0],h[1])}),["adulthood","advice","agenda","aid","aircraft","alcohol","ammo","analytics","anime","athletics","audio","bison","blood","bream","buffalo","butter","carp","cash","chassis","chess","clothing","cod","commerce","cooperation","corps","debris","diabetes","digestion","elk","energy","equipment","excretion","expertise","firmware","flounder","fun","gallows","garbage","graffiti","hardware","headquarters","health","herpes","highjinks","homework","housework","information","jeans","justice","kudos","labour","literature","machinery","mackerel","mail","media","mews","moose","music","mud","manga","news","only","personnel","pike","plankton","pliers","police","pollution","premises","rain","research","rice","salmon","scissors","series","sewage","shambles","shrimp","software","species","staff","swine","tennis","traffic","transportation","trout","tuna","wealth","welfare","whiting","wildebeest","wildlife","you",/pok[eé]mon$/i,/[^aeiou]ese$/i,/deer$/i,/fish$/i,/measles$/i,/o[iu]s$/i,/pox$/i,/sheep$/i].forEach(y.addUncountableRule),y})})(ku);var ly=ku.exports;const cy=mf(ly),ni=({count:e,singularText:t,children:n=(r,o)=>`${r} ${o}`})=>c.jsx(c.Fragment,{children:n(e,cy(t,e))});ni.displayName="PluralizeCounter";const Ee={TableContainer:"TableContainer__osh6Z",TableHeader:"TableHeader__sYa-8",Table:"Table__2cIs3",selectable:"selectable__WsGg1",Cell:"Cell__ZEv-K",Right:"Right__YoM1V",Center:"Center__CF3tr",Sortable:"Sortable__JIV1V",SortIcon:"SortIcon__f0bBy",Active:"Active__rJjxB",Rotate:"Rotate__7cwTK",Pagination:"Pagination__sbqMP",PointerNone:"PointerNone__kQdQS"},Lu={EmptyStateContainer:"EmptyStateContainer__Q9FEb",Message:"Message__IHK6M"},Du=({size:e=64})=>c.jsxs("svg",{width:e,height:e,viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[c.jsxs("g",{clipPath:"url(#clip-path)",children:[c.jsx("mask",{id:"mask0_1070_8032",style:{maskType:"luminance"},maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"64",height:"64",children:c.jsx("path",{d:"M64 0H0V64H64V0Z",fill:"white"})}),c.jsx("g",{mask:"url(#mask0_1070_8032)",children:c.jsx("path",{d:"M40 10.6673H13.3333V53.334H50.6667V21.334H40V10.6673ZM8 7.97932C8 6.51798 9.192 5.33398 10.664 5.33398H42.6667L56 18.6673V55.982C56.0024 56.3321 55.936 56.6793 55.8043 57.0039C55.6725 57.3284 55.4781 57.6239 55.2323 57.8732C54.9864 58.1225 54.6936 58.3209 54.3712 58.4572C54.0485 58.5935 53.7021 58.6649 53.352 58.6673H10.648C9.94768 58.6625 9.27739 58.3823 8.78192 57.8873C8.28645 57.3924 8.00557 56.7223 8 56.022V7.97932ZM36.0773 38.5233C33.8408 39.83 31.2056 40.2788 28.6627 39.786C26.1197 39.2929 23.8428 37.8921 22.2566 35.8444C20.6704 33.7966 19.883 31.2417 20.0414 28.6564C20.1998 26.071 21.293 23.6315 23.1173 21.7927C24.9532 19.9571 27.3955 18.8541 29.9864 18.6904C32.5773 18.5267 35.1389 19.3134 37.1912 20.9032C39.2435 22.493 40.6456 24.7767 41.1347 27.3263C41.6237 29.8759 41.1664 32.5164 39.848 34.7527L45.7413 40.646L41.9707 44.4193L36.0773 38.5233ZM34.4293 33.1047C34.9387 32.6126 35.3451 32.0241 35.6245 31.3735C35.904 30.7228 36.0512 30.0231 36.0573 29.3148C36.0635 28.6065 35.9285 27.9044 35.6603 27.2489C35.3923 26.5935 34.9963 25.998 34.4955 25.4972C33.9947 24.9964 33.3992 24.6004 32.7437 24.3323C32.0883 24.0641 31.3861 23.9292 30.6779 23.9353C29.9696 23.9415 29.2699 24.0886 28.6192 24.3681C27.9685 24.6476 27.38 25.0539 26.888 25.5633C25.9165 26.5692 25.3789 27.9164 25.3911 29.3148C25.4032 30.7132 25.9641 32.0508 26.9531 33.0396C27.9419 34.0287 29.2795 34.5895 30.6779 34.6015C32.0763 34.6137 33.4235 34.0761 34.4293 33.1047Z",fill:"currentColor"})})]}),c.jsx("defs",{children:c.jsx("clipPath",{id:"clip-path",children:c.jsx("rect",{width:"64",height:"64",fill:"white"})})})]});Du.displayName="EmptyStateIcon";const ri=({message:e="No results found"})=>c.jsxs("div",{className:L(Lu.EmptyStateContainer),children:[c.jsx(Du,{}),c.jsx("p",{className:Lu.Message,children:e})]});ri.displayName="EmptyState";const uy=(e,t,n=1)=>{if(e<=1)return["1"];const r=[],o=s=>{(r.length===0||r[r.length-1]!==s)&&r.push(s)};o(1),t-n>2&&o("...");for(let s=Math.max(2,t-n);s<=Math.min(e-1,t+n);s++)o(s);return t+n<e-1&&o("..."),o(e),r.map(String)},Nu=({page:e,totalPages:t,onPageChange:n})=>{const r=e===1,o=e===t;return c.jsx(Zs,{className:Ee.Pagination,children:c.jsxs(Xs,{children:[c.jsx(sr,{children:c.jsx(Js,{className:L({[Ee.PointerNone]:r}),onClick:()=>!r&&n(e-1)})}),uy(t,e).map((s,i)=>c.jsxs(sr,{children:[s==="..."&&c.jsx(ti,{}),s!=="..."&&c.jsx(ir,{isActive:+s===e,onClick:()=>+s!==e&&n(+s),children:s})]},i)),c.jsx(sr,{children:c.jsx(ei,{className:L({[Ee.PointerNone]:o}),onClick:()=>!o&&n(e+1)})})]})})};Nu.displayName="TablePagination";const Mu=({className:e,...t})=>c.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:e,...t,children:c.jsx("path",{d:"M6 2.5V9.5M6 9.5L9.5 6M6 9.5L2.5 6",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});Mu.displayName="ArrowDown";const $u=({columns:e,data:t,isLoading:n,totalCount:r=0,headerLabel:o,sort:s,loadingConfig:i,pagination:a,onRowClick:l})=>{const{count:u=5,height:f=40}=i||{},p=b=>b.sortName??b.name,m=({width:b,maxWidth:_})=>!b&&!_?{}:{...b?{width:b,minWidth:b}:{},..._?{maxWidth:_}:{},overflow:"hidden"},g=b=>L({[Ee.Cell]:!0,[Ee.Center]:b.align==="center",[Ee.Right]:b.align==="right",[Ee.Sortable]:b.isSortable}),y=b=>{if(!s)return"";const _=p(b);return L({[Ee.SortIcon]:!0,[Ee.Active]:b.isSortable&&s.field===_,[Ee.Rotate]:s.field===_&&s.direction==="asc"})},h=b=>()=>l==null?void 0:l(b),v=b=>()=>{if(!s||!b.isSortable)return;const{field:_,direction:C,onSort:T}=s,P=p(b);_===P?T(P,C==="asc"?"desc":"asc"):T(P,"asc")};return c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:Ee.TableContainer,children:[o&&c.jsx("div",{className:Ee.TableHeader,children:c.jsx(ni,{count:r,singularText:o,children:(b,_)=>`${b} ${_}`})}),c.jsx("div",{className:Ee.Table,children:c.jsxs("table",{children:[c.jsx("thead",{children:c.jsx("tr",{children:e.map(b=>c.jsx("th",{children:c.jsxs("div",{className:g(b),onClick:v(b),children:[c.jsx("span",{children:b.displayName}),b.isSortable&&c.jsx(Mu,{className:y(b)})]})},b.name))})}),c.jsx("tbody",{children:c.jsxs(St,{children:[c.jsx(St.When,{condition:n,children:[...Array(u).keys()].map(b=>c.jsx("tr",{children:c.jsx("td",{colSpan:e.length,style:{padding:4},children:c.jsx(co,{height:f})})},b))}),c.jsx(St.When,{condition:!t.length,children:c.jsx("tr",{children:c.jsx("td",{colSpan:e.length,children:c.jsx(ri,{})})})}),c.jsx(St.Else,{children:t.map((b,_)=>c.jsx("tr",{className:l&&Ee.selectable,onClick:h(b),children:e.map(C=>c.jsx("td",{style:m(C),children:c.jsx("div",{className:g(C),children:C.cellRenderer?C.cellRenderer(b):C.valueGetter?C.valueGetter(b):b[C.name]})},`${C.name}-${_}`))},_))})]})})]})})]}),a&&c.jsx(Nu,{...a})]})};$u.displayName="Table";const mo={alert:"alert__LblpE",default:"default__mgO6A",destructive:"destructive__bLNSM",alertTitle:"alertTitle__gblKf",alertDescription:"alertDescription__BuVHV"},go=({className:e,variant:t="default",children:n,...r})=>c.jsx("div",{"data-slot":"alert",role:"alert",className:L(mo.alert,mo[t],e),...r,children:n}),dy=d.forwardRef(({children:e,className:t,...n},r)=>c.jsx("div",{ref:r,"data-slot":"alert-title",className:L(mo.alertTitle,t),...n,children:e})),fy=d.forwardRef(({children:e,className:t,...n},r)=>c.jsx("div",{ref:r,"data-slot":"alert-description",className:L(mo.alertDescription,t),...n,children:e}));go.displayName="Alert",go.Title=dy,go.Description=fy;const Fu=S.createContext(null),Bu=({container:e,children:t})=>c.jsx(Fu.Provider,{value:e,children:t}),py=()=>S.useContext(Fu)??void 0,Uu="__paeShadowDom",hy=e=>typeof e=="function"&&e[Uu]===!0,Wu=e=>e==null?void 0:e.moduleName,my=e=>{const t=new MutationObserver(n=>{n.forEach(({addedNodes:r})=>{r.forEach(o=>{o instanceof HTMLElement&&(o.tagName==="STYLE"||o.tagName==="LINK")&&o.getAttribute("data-pae-module")===e.name&&(e.target.appendChild(o),e.mode==="shadow"&&e.target instanceof ShadowRoot&&Vu(e.target,e.name))})})});return t.observe(document.head,{childList:!0}),t},oi="data-pae-property-shim",Hu=(e,t)=>{var n;for(const r of Array.from(e))((n=r.constructor)==null?void 0:n.name)==="CSSPropertyRule"||/^\s*@property\b/.test(r.cssText)?t.push(r.cssText):"cssRules"in r&&r.cssRules&&Hu(r.cssRules,t)},Vu=(e,t)=>{const n=[];if(e.querySelectorAll("style").forEach(i=>{const a=i.sheet;if(a)try{Hu(a.cssRules,n)}catch{}}),!n.length)return;const r=`style[${oi}="${CSS.escape(t)}"]`;let o=document.head.querySelector(r);o||(o=document.createElement("style"),o.setAttribute(oi,t),document.head.appendChild(o));const s=n.join(`
|
|
244
|
+
`);o.textContent!==s&&(o.textContent=s)},gy=e=>{document.head.querySelectorAll(`style[${oi}="${CSS.escape(e)}"]`).forEach(t=>t.remove())},vy=e=>{const t={shadowHost:null,shadowRoot:null,container:null,portalContainer:null,observer:null,styleEntry:null},n=e.rootComponent,o=oa({...e,rootComponent:f=>c.jsx(Bu,{container:t.portalContainer,children:c.jsx(n,{...f})})}),s=f=>{const p=ea(f);return t.styleEntry=p,t.observer||(t.observer=my(p)),p},i=f=>{let p=t.shadowHost;(!p||p.parentNode!==f)&&(p=document.createElement("div"),p.setAttribute("data-pae-module-shadow-host",""),f.appendChild(p));const m=p.shadowRoot??p.attachShadow({mode:"open"}),g=t.styleEntry;if(g){for(;g.holder.firstChild;)m.appendChild(g.holder.firstChild);$o(document.head,m,g.name),g.target=m,g.mode="shadow",Vu(m,g.name)}let y=m.querySelector(":scope > [data-pae-module-root]");y||(y=document.createElement("div"),y.setAttribute("data-pae-module-root",""),m.appendChild(y));let h=m.querySelector(":scope > [data-pae-module-portal]");return h||(h=document.createElement("div"),h.setAttribute("data-pae-module-portal",""),m.appendChild(h)),t.shadowHost=p,t.shadowRoot=m,t.container=y,t.portalContainer=h,y},a=async f=>{const p=Wu(f);return p&&s(p),o.bootstrap(f)},l=async f=>{const p=f==null?void 0:f.domElement;if(!p||typeof p.attachShadow!="function")return o.mount(f);const m=Wu(f);m&&!t.styleEntry&&s(m);const g=i(p);return o.mount({...f,domElement:g})};return l[Uu]=!0,{...o,bootstrap:a,mount:l,unmount:async f=>{var y;const p=t.container,m=await o.unmount(p?{...f,domElement:p}:f),g=t.styleEntry;return g&&t.shadowRoot&&($o(t.shadowRoot,g.holder,g.name),g.target=g.holder,g.mode="detached",gy(g.name)),(y=t.shadowHost)==null||y.remove(),t.shadowHost=null,t.shadowRoot=null,t.container=null,t.portalContainer=null,m}}},yy=({rootComponent:e,shadowDom:t,...n})=>{const r={errorBoundary(o){return console.error(o),c.jsx(Qs,{})},...n,rootComponent:oh(e)};return t?vy(r):oa(r)},Et=new Map,by=(e,t)=>{const n=t.mount;hy(n)&&ea(e)},wy=e=>{try{const{catalog:t}=ko(),n=t.find(r=>r.name===e);return n!=null&&n.version?`${e}@${n.version}`:e}catch{return e}},vo=e=>{const[t,n]=S.useState(null);return S.useEffect(()=>{(async()=>{if(!e){n(null);return}try{const o=wy(e);if(Et.has(o)){const i=Et.get(o);n(i);return}const s=await System.import(e);Et.set(o,s),by(e,s),n(s)}catch(o){console.error(`Error importing module ${e}: ${o.message}`),n(null)}})()},[e,n]),t},_y=e=>{e?(Array.from(Et.keys()).filter(n=>n.startsWith(e)).forEach(n=>Et.delete(n)),console.log(`[useApplicationJSModule] Cleared cache for module: ${e}`)):(Et.clear(),console.log("[useApplicationJSModule] Cleared all module cache"))};typeof window<"u"&&(window.PAE={...window.PAE,clearModuleCache:_y,getModuleCacheSize:()=>Et.size,getModuleCacheKeys:()=>Array.from(Et.keys())});const zu=e=>{const t=typeof e=="string"?Yi(e):gr(e==null?void 0:e.modules),n=vo(t==null?void 0:t.name);return n==null?void 0:n.icon},Gu=e=>{const t=gr(e==null?void 0:e.modules),n=vo(t==null?void 0:t.name),[r,o]=S.useState(!1),[s,i]=S.useState({}),a=async()=>(typeof(n==null?void 0:n.menu)=="function"?await n.menu():n==null?void 0:n.menu)||[],l=async()=>{if(!(n!=null&&n.menu))return[];o(!0);const p=xy((e==null?void 0:e.operations)||[]),m=(await a()).map(g=>{const{operations:y,items:h,path:v}=g;if(y!=null&&y.length&&!p(y))return null;const b=(h||[]).filter(_=>{var C;return!((C=_==null?void 0:_.operations)!=null&&C.length)||p(_.operations)});return!b.length&&!v?null:{...g,items:b}}).filter(Boolean);return o(!1),m},u=async()=>{const p=await l();e&&i(m=>({...m,[e.name]:p}))};S.useEffect(()=>{u()},[n==null?void 0:n.menu]);const f=S.useMemo(()=>e?s[e.name]||[]:[],[s,e]);return{loading:r,menu:f}},xy=e=>t=>t.every(n=>e.some(r=>r.name===n)),Cy=e=>Gu(e);function ce(e){return e!=null&&typeof e=="object"&&e["@@functional/placeholder"]===!0}function tn(e){return function t(n){return arguments.length===0||ce(n)?t:e.apply(this,arguments)}}function Tt(e){return function t(n,r){switch(arguments.length){case 0:return t;case 1:return ce(n)?t:tn(function(o){return e(n,o)});default:return ce(n)&&ce(r)?t:ce(n)?tn(function(o){return e(o,r)}):ce(r)?tn(function(o){return e(n,o)}):e(n,r)}}}function si(e){return function t(n,r,o){switch(arguments.length){case 0:return t;case 1:return ce(n)?t:Tt(function(s,i){return e(n,s,i)});case 2:return ce(n)&&ce(r)?t:ce(n)?Tt(function(s,i){return e(s,r,i)}):ce(r)?Tt(function(s,i){return e(n,s,i)}):tn(function(s){return e(n,r,s)});default:return ce(n)&&ce(r)&&ce(o)?t:ce(n)&&ce(r)?Tt(function(s,i){return e(s,i,o)}):ce(n)&&ce(o)?Tt(function(s,i){return e(s,r,i)}):ce(r)&&ce(o)?Tt(function(s,i){return e(n,s,i)}):ce(n)?tn(function(s){return e(s,r,o)}):ce(r)?tn(function(s){return e(n,s,o)}):ce(o)?tn(function(s){return e(n,r,s)}):e(n,r,o)}}}function yo(e,t){return Object.prototype.hasOwnProperty.call(t,e)}function qu(e){return Object.prototype.toString.call(e)==="[object Object]"}var Sy=si(function(t,n,r){var o=t(n),s=t(r);return o>s?-1:o<s?1:0}),Ey=si(function(t,n,r){var o={},s;n=n||{},r=r||{};for(s in n)yo(s,n)&&(o[s]=yo(s,r)?t(s,n[s],r[s]):n[s]);for(s in r)yo(s,r)&&!yo(s,o)&&(o[s]=r[s]);return o}),Ty=si(function e(t,n,r){return Ey(function(o,s,i){return qu(s)&&qu(i)?e(t,s,i):t(o,s,i)},n,r)}),Py=Tt(function(t,n){return Ty(function(r,o,s){return s},t,n)}),Ay=Tt(function(t,n){return Array.prototype.slice.call(n,0).sort(function(r,o){for(var s=0,i=0;s===0&&i<t.length;)s=t[i](r,o),i+=1;return s})});const ii=()=>{const e=Bi(),t=Xi();return S.useMemo(()=>Ry(e,t),[e,t])},Ry=(e,t)=>Ay([Sy(Oy)],t).find(n=>n.route&&e.startsWith(n.route)),Oy=e=>{var t;return((t=e==null?void 0:e.route)==null?void 0:t.length)||-1},Ku=()=>{var e;return(e=ii())==null?void 0:e.name},Iy=()=>{const e=ii(),t=Ji(e);return vo(t==null?void 0:t.name)},ai=(e,t)=>{const r=pn().find(o=>o.name===e);if(!r){if(t)return null;throw new Error(`Service with name [${e}] not available in the catalog`)}return r.baseUrl},li=(e,t)=>{const n=ai(e,!!t)??t;return S.useCallback((r,o)=>{const i={Accept:"application/json",...(o==null?void 0:o.body)instanceof FormData?{}:{"Content-Type":"application/json"},...o==null?void 0:o.headers};return fetch(jy(`${n}${r}`),{...o,headers:i})},[n])},jy=e=>e.replace(/\/+/g,"/"),ky=["impersonate","impersonate-display-name","tenant"],Qu=(e,t)=>{const n=ai(e,t);return S.useMemo(()=>{if(!n)return null;try{const r=new URL(window.location.href),o=new URL(n,window.location.origin);return ky.forEach(s=>{const i=r.searchParams.get(s);i&&o.searchParams.set(s,i)}),o.toString()}catch(r){return console.error("Error building WebSocket URL:",r),n}},[n])},Ly=(e,t)=>n=>({timestamp:new Date(new Date().toUTCString()).toISOString(),module:t.name,moduleVersion:t.version,application:t.application,user:e.username,...n}),Dy=(e,t,n)=>async r=>{if(r.length===0)throw new Error("Invalid call to trackEvents with an empty array of events!");const o=await e("/event",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(r.map(Ly(t,n)))});if(!o.ok)throw new Error(`Error publishing habits event ${o.statusText}`)},Ny="@bluealba/pae-habits-service",Yu=()=>{const{authUser:e}=Gn(),t=zn(),n=li(Ny);return S.useCallback(Dy(n,e,t),[n,e,t])},My=()=>{const e=Yu();return S.useCallback((t,n)=>e([{name:t,data:n}]),[e])},Zu=e=>{const t=zn(),n=window[$i],[r,o]=S.useState(null);return S.useEffect(()=>n.defineExtensionPoint(t,e,s=>{o(()=>s)}),[o]),r},Xu=(e,t,n)=>{S.useEffect(()=>window[$i].setExtensionPoint(e,t,n),[])},Ju=(e,t)=>{S.useEffect(()=>(window.addEventListener(e,t),()=>window.removeEventListener(e,t)),[e,t])},ed=e=>{const{cssCustomizationLoadingDelay:t=1e3}=Do();S.useEffect(()=>{if(!e)return;const n=document.createElement("style");return setTimeout(()=>{n.innerHTML=e,document.head.append(n)},t),()=>n&&n.remove()},[e])},$y=e=>{var t;return(t=e.split(/[#?]/)[0].split(".").pop())==null?void 0:t.trim()},Fy={woff2:"woff2",woff:"woff",ttf:"truetype",otf:"opentype",eot:"embedded-opentype",svg:"svg"},By=e=>{const t=$y(e);return t?Fy[t]:void 0},Uy=(e,t)=>{const n=t??By(e);return n?`format(${n})`:""};function td(e){const[t,n]=S.useState(!1);return S.useEffect(()=>{if(!(e!=null&&e.length))return;const r=document.createElement("style");r.setAttribute("data-generated-fonts","true");const o=e.flatMap(({fontFamily:i,variants:a})=>a.map(({path:l,fontWeight:u,format:f})=>`
|
|
244
245
|
@font-face {
|
|
245
246
|
font-family: "${i}";
|
|
246
|
-
src: url("${l}") ${
|
|
247
|
+
src: url("${l}") ${Uy(l,f)};
|
|
247
248
|
font-weight: ${u};
|
|
248
249
|
font-style: normal;
|
|
249
250
|
}
|
|
250
251
|
`)).join(`
|
|
251
|
-
`);return r.innerHTML=o,document.head.appendChild(r),(async()=>{try{await Promise.all(e.flatMap(({fontFamily:i,variants:a})=>a.map(({fontWeight:l})=>document.fonts.load(`normal ${l} 1em "${i}"`))))}finally{n(!0)}})(),()=>{document.head.removeChild(r)}},[e]),S.useEffect(()=>{!t&&!(e!=null&&e.length)&&n(!0)},[e,t]),{fontsLoaded:t}}function ut(e){return typeof e=="function"}function
|
|
252
|
+
`);return r.innerHTML=o,document.head.appendChild(r),(async()=>{try{await Promise.all(e.flatMap(({fontFamily:i,variants:a})=>a.map(({fontWeight:l})=>document.fonts.load(`normal ${l} 1em "${i}"`))))}finally{n(!0)}})(),()=>{document.head.removeChild(r)}},[e]),S.useEffect(()=>{!t&&!(e!=null&&e.length)&&n(!0)},[e,t]),{fontsLoaded:t}}function ut(e){return typeof e=="function"}function nd(e){var t=function(r){Error.call(r),r.stack=new Error().stack},n=e(t);return n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n}var ci=nd(function(e){return function(n){e(this),this.message=n?n.length+` errors occurred during unsubscription:
|
|
252
253
|
`+n.map(function(r,o){return o+1+") "+r.toString()}).join(`
|
|
253
|
-
`):"",this.name="UnsubscriptionError",this.errors=n}});function ci(e,t){if(e){var n=e.indexOf(t);0<=n&&e.splice(n,1)}}var bo=function(){function e(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}return e.prototype.unsubscribe=function(){var t,n,r,o,s;if(!this.closed){this.closed=!0;var i=this._parentage;if(i)if(this._parentage=null,Array.isArray(i))try{for(var a=Ps(i),l=a.next();!l.done;l=a.next()){var u=l.value;u.remove(this)}}catch(h){t={error:h}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}else i.remove(this);var f=this.initialTeardown;if(ut(f))try{f()}catch(h){s=h instanceof li?h.errors:[h]}var p=this._finalizers;if(p){this._finalizers=null;try{for(var m=Ps(p),g=m.next();!g.done;g=m.next()){var y=g.value;try{nd(y)}catch(h){s=s??[],h instanceof li?s=Kr(Kr([],As(s)),As(h.errors)):s.push(h)}}}catch(h){r={error:h}}finally{try{g&&!g.done&&(o=m.return)&&o.call(m)}finally{if(r)throw r.error}}}if(s)throw new li(s)}},e.prototype.add=function(t){var n;if(t&&t!==this)if(this.closed)nd(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=(n=this._finalizers)!==null&&n!==void 0?n:[]).push(t)}},e.prototype._hasParent=function(t){var n=this._parentage;return n===t||Array.isArray(n)&&n.includes(t)},e.prototype._addParent=function(t){var n=this._parentage;this._parentage=Array.isArray(n)?(n.push(t),n):n?[n,t]:t},e.prototype._removeParent=function(t){var n=this._parentage;n===t?this._parentage=null:Array.isArray(n)&&ci(n,t)},e.prototype.remove=function(t){var n=this._finalizers;n&&ci(n,t),t instanceof e&&t._removeParent(this)},e.EMPTY=function(){var t=new e;return t.closed=!0,t}(),e}(),ed=bo.EMPTY;function td(e){return e instanceof bo||e&&"closed"in e&&ut(e.remove)&&ut(e.add)&&ut(e.unsubscribe)}function nd(e){ut(e)?e():e.unsubscribe()}var $y={Promise:void 0},Fy={setTimeout:function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];return setTimeout.apply(void 0,Kr([e,t],As(n)))},clearTimeout:function(e){return clearTimeout(e)},delegate:void 0};function By(e){Fy.setTimeout(function(){throw e})}function rd(){}function wo(e){e()}var od=function(e){Jn(t,e);function t(n){var r=e.call(this)||this;return r.isStopped=!1,n?(r.destination=n,td(n)&&n.add(r)):r.destination=Hy,r}return t.create=function(n,r,o){return new ui(n,r,o)},t.prototype.next=function(n){this.isStopped||this._next(n)},t.prototype.error=function(n){this.isStopped||(this.isStopped=!0,this._error(n))},t.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,e.prototype.unsubscribe.call(this),this.destination=null)},t.prototype._next=function(n){this.destination.next(n)},t.prototype._error=function(n){try{this.destination.error(n)}finally{this.unsubscribe()}},t.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},t}(bo),Uy=function(){function e(t){this.partialObserver=t}return e.prototype.next=function(t){var n=this.partialObserver;if(n.next)try{n.next(t)}catch(r){_o(r)}},e.prototype.error=function(t){var n=this.partialObserver;if(n.error)try{n.error(t)}catch(r){_o(r)}else _o(t)},e.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(n){_o(n)}},e}(),ui=function(e){Jn(t,e);function t(n,r,o){var s=e.call(this)||this,i;return ut(n)||!n?i={next:n??void 0,error:r??void 0,complete:o??void 0}:i=n,s.destination=new Uy(i),s}return t}(od);function _o(e){By(e)}function Wy(e){throw e}var Hy={closed:!0,next:rd,error:Wy,complete:rd},Vy=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function zy(e){return e}function Gy(e){return e.length===0?zy:e.length===1?e[0]:function(n){return e.reduce(function(r,o){return o(r)},n)}}var sd=function(){function e(t){t&&(this._subscribe=t)}return e.prototype.lift=function(t){var n=new e;return n.source=this,n.operator=t,n},e.prototype.subscribe=function(t,n,r){var o=this,s=Ky(t)?t:new ui(t,n,r);return wo(function(){var i=o,a=i.operator,l=i.source;s.add(a?a.call(s,l):l?o._subscribe(s):o._trySubscribe(s))}),s},e.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(n){t.error(n)}},e.prototype.forEach=function(t,n){var r=this;return n=id(n),new n(function(o,s){var i=new ui({next:function(a){try{t(a)}catch(l){s(l),i.unsubscribe()}},error:s,complete:o});r.subscribe(i)})},e.prototype._subscribe=function(t){var n;return(n=this.source)===null||n===void 0?void 0:n.subscribe(t)},e.prototype[Vy]=function(){return this},e.prototype.pipe=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return Gy(t)(this)},e.prototype.toPromise=function(t){var n=this;return t=id(t),new t(function(r,o){var s;n.subscribe(function(i){return s=i},function(i){return o(i)},function(){return r(s)})})},e.create=function(t){return new e(t)},e}();function id(e){var t;return(t=e??$y.Promise)!==null&&t!==void 0?t:Promise}function qy(e){return e&&ut(e.next)&&ut(e.error)&&ut(e.complete)}function Ky(e){return e&&e instanceof od||qy(e)&&td(e)}var Qy=Ju(function(e){return function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),ad=function(e){Jn(t,e);function t(){var n=e.call(this)||this;return n.closed=!1,n.currentObservers=null,n.observers=[],n.isStopped=!1,n.hasError=!1,n.thrownError=null,n}return t.prototype.lift=function(n){var r=new ld(this,this);return r.operator=n,r},t.prototype._throwIfClosed=function(){if(this.closed)throw new Qy},t.prototype.next=function(n){var r=this;wo(function(){var o,s;if(r._throwIfClosed(),!r.isStopped){r.currentObservers||(r.currentObservers=Array.from(r.observers));try{for(var i=Ps(r.currentObservers),a=i.next();!a.done;a=i.next()){var l=a.value;l.next(n)}}catch(u){o={error:u}}finally{try{a&&!a.done&&(s=i.return)&&s.call(i)}finally{if(o)throw o.error}}}})},t.prototype.error=function(n){var r=this;wo(function(){if(r._throwIfClosed(),!r.isStopped){r.hasError=r.isStopped=!0,r.thrownError=n;for(var o=r.observers;o.length;)o.shift().error(n)}})},t.prototype.complete=function(){var n=this;wo(function(){if(n._throwIfClosed(),!n.isStopped){n.isStopped=!0;for(var r=n.observers;r.length;)r.shift().complete()}})},t.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(t.prototype,"observed",{get:function(){var n;return((n=this.observers)===null||n===void 0?void 0:n.length)>0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(n){return this._throwIfClosed(),e.prototype._trySubscribe.call(this,n)},t.prototype._subscribe=function(n){return this._throwIfClosed(),this._checkFinalizedStatuses(n),this._innerSubscribe(n)},t.prototype._innerSubscribe=function(n){var r=this,o=this,s=o.hasError,i=o.isStopped,a=o.observers;return s||i?ed:(this.currentObservers=null,a.push(n),new bo(function(){r.currentObservers=null,ci(a,n)}))},t.prototype._checkFinalizedStatuses=function(n){var r=this,o=r.hasError,s=r.thrownError,i=r.isStopped;o?n.error(s):i&&n.complete()},t.prototype.asObservable=function(){var n=new sd;return n.source=this,n},t.create=function(n,r){return new ld(n,r)},t}(sd),ld=function(e){Jn(t,e);function t(n,r){var o=e.call(this)||this;return o.destination=n,o.source=r,o}return t.prototype.next=function(n){var r,o;(o=(r=this.destination)===null||r===void 0?void 0:r.next)===null||o===void 0||o.call(r,n)},t.prototype.error=function(n){var r,o;(o=(r=this.destination)===null||r===void 0?void 0:r.error)===null||o===void 0||o.call(r,n)},t.prototype.complete=function(){var n,r;(r=(n=this.destination)===null||n===void 0?void 0:n.complete)===null||r===void 0||r.call(n)},t.prototype._subscribe=function(n){var r,o;return(o=(r=this.source)===null||r===void 0?void 0:r.subscribe(n))!==null&&o!==void 0?o:ed},t}(ad),Yy=function(e){Jn(t,e);function t(n){var r=e.call(this)||this;return r._value=n,r}return Object.defineProperty(t.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),t.prototype._subscribe=function(n){var r=e.prototype._subscribe.call(this,n);return!r.closed&&n.next(this._value),r},t.prototype.getValue=function(){var n=this,r=n.hasError,o=n.thrownError,s=n._value;if(r)throw o;return this._throwIfClosed(),s},t.prototype.next=function(n){e.prototype.next.call(this,this._value=n)},t}(ad);const Zy=e=>{const{fontsLoaded:t}=Xu(e.fonts);Zu(e.styleSheet);const n=()=>{const r=new Yy(!0);window[Io]=r};S.useEffect(()=>{t&&window[Io].next(!1)},[t]),S.useEffect(()=>{n()},[])},Xy=()=>{const e=window[Io];return $i(e,e.getValue()??void 0)},di="theme",cd=()=>document.documentElement.dataset[di]==="dark"?"dark":"light",Jy=()=>{const[e,t]=S.useState(cd());return S.useEffect(()=>{const n=document.documentElement,r=()=>t(cd),o=new MutationObserver(s=>{for(const i of s)i.type==="attributes"&&i.attributeName===`data-${di}`&&r()});return o.observe(n,{attributes:!0,attributeFilter:[`data-${di}`]}),r(),()=>{o.disconnect()}},[]),e},e0=e=>e!==void 0,t0=e=>e!==!0,fi=()=>({notify:S.useCallback((t,n,r)=>{const o={style:{background:"var(--platform-background-primary-color)",color:"var(--platform-text-primary-color)"}};n==="warning"||n==="info"?ua(t,{...o,icon:n==="warning"?"⚠️":"ℹ️"}):ua[n](t,o),r&&console.error(r)},[])}),xo={STALE_TIME:1e3*60*5,GC_TIME:1e3*60*10,RETRY_COUNT:1,RETRY_DELAY:1e3},ud={refetchOnWindowFocus:!1,refetchOnReconnect:!1,refetchOnMount:!1,staleTime:xo.STALE_TIME,gcTime:xo.GC_TIME,retry:xo.RETRY_COUNT,retryDelay:xo.RETRY_DELAY,enable:!0},Co=e=>e instanceof Error?e.message:String(e),dd=(e,t,n)=>{const r=es(),{notify:o}=fi(),{createFn:s,readFn:i,readByIdFn:a,updateFn:l,deleteFn:u,partialUpdateFn:f}=n,p=()=>{r.invalidateQueries({queryKey:[e]})},m=(T,P,A,R)=>o(R!=null&&R.overrideSuccessMessage?R==null?void 0:R.overrideSuccessMessage(T,P):A,"success"),g=(T,P,A,R)=>o(R!=null&&R.overrideErrorMessage?R==null?void 0:R.overrideErrorMessage(T,P):A,"error");return{useCreate:T=>Ar({mutationFn:P=>s(P),onSuccess:P=>{p(),m(t,P,`${t} created successfully`,T)},onError:P=>{g(t,P,`Error creating ${t}: ${Co(P)}`,T)}}),useReadQuery:T=>Ia({queryKey:[e],queryFn:i,...ud,...T}),useReadByIdQuery:(T,P)=>Ia({queryKey:[e,T],queryFn:()=>a(T),...ud,enabled:!!T,...P}),useUpdate:T=>Ar({mutationFn:({id:P,data:A})=>l(P,A),onSuccess:P=>{p(),m(t,P,`${t} updated successfully`,T)},onError:P=>{g(t,P,`Error updating ${t}: ${Co(P)}`,T)}}),usePartialUpdate:T=>f&&Ar({mutationFn:({id:P,data:A})=>f(P,A),onSuccess:P=>{p(),m(t,P,`${t} updated successfully`,T)},onError:P=>{g(t,P,`Error updating ${t}: ${Co(P)}`,T)}}),useDelete:T=>Ar({mutationFn:P=>u(P),onSuccess:()=>{p(),m(t,null,`${t} deleted successfully`,T)},onError:P=>{g(t,P,`Error deleting ${t}: ${Co(P)}`,T)}}),invalidateQueries:p}},n0=(e,t)=>dd(e,t,{createFn:n=>fetch(e,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(n)}).then(r=>r.json()),deleteFn:n=>fetch(`${e}/${n}`,{method:"DELETE"}).then(r=>{if(!r.ok)throw new Error(`Error deleting: ${r.status}`)}),readByIdFn:n=>fetch(`${e}/${n}`).then(r=>r.json()),readFn:()=>fetch(e).then(n=>n.json()),updateFn:(n,r)=>fetch(`${e}/${n}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(r)}).then(o=>o.json()),partialUpdateFn:(n,r)=>fetch(`${e}/${n}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify(r)}).then(o=>o.json())}),r0={SINGLE_TENANT:"single-tenant"},o0={COOKIE:"cookie"},pi="tenant",fd="tenant",pd="tenant",s0=r0.SINGLE_TENANT,i0=o0.COOKIE,a0={mode:s0,clientSideMode:i0,tenantIDPProvisioningStrategy:"none"};class l0{setTenant(t,n){const r=new URL(window.location.href);r.searchParams.set(fd,t.name),window.location.href=r.toString()}getCurrentTenantName(){const t=new URL(window.location.href);return new URLSearchParams(t.search).get(fd)}}class c0{setTenant(t,n){sessionStorage.setItem(pd,t.name),window.location.reload()}getCurrentTenantName(){return sessionStorage.getItem(pd)}}/*! js-cookie v3.0.5 | MIT */function So(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)e[r]=n[r]}return e}var u0={read:function(e){return e[0]==='"'&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function hi(e,t){function n(o,s,i){if(!(typeof document>"u")){i=So({},t,i),typeof i.expires=="number"&&(i.expires=new Date(Date.now()+i.expires*864e5)),i.expires&&(i.expires=i.expires.toUTCString()),o=encodeURIComponent(o).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var a="";for(var l in i)i[l]&&(a+="; "+l,i[l]!==!0&&(a+="="+i[l].split(";")[0]));return document.cookie=o+"="+e.write(s,o)+a}}function r(o){if(!(typeof document>"u"||arguments.length&&!o)){for(var s=document.cookie?document.cookie.split("; "):[],i={},a=0;a<s.length;a++){var l=s[a].split("="),u=l.slice(1).join("=");try{var f=decodeURIComponent(l[0]);if(i[f]=e.read(u,f),o===f)break}catch{}}return o?i[o]:i}}return Object.create({set:n,get:r,remove:function(o,s){n(o,"",So({},s,{expires:-1}))},withAttributes:function(o){return hi(this.converter,So({},this.attributes,o))},withConverter:function(o){return hi(So({},this.converter,o),this.attributes)}},{attributes:{value:Object.freeze(t)},converter:{value:Object.freeze(e)}})}var mi=hi(u0,{path:"/"});class d0{setTenant(t,n){t?mi.set(pi,t.name):mi.remove(pi),window.location.reload()}getCurrentTenantName(){return mi.get(pi)}}class f0{extractSubdomain(t){if(t==="localhost"||/^\d+\.\d+\.\d+\.\d+$/.test(t))return"";const n=t.split(".");if(n.length<2||n.length===2||n[0]==="www"&&n.length===3)return"";const o=(n[0]==="www"?n.slice(1):n).slice(0,-2);return o.length>0?o.join("."):""}getBaseDomain(t){const n=t.split(".");return t==="localhost"||/^\d+\.\d+\.\d+\.\d+$/.test(t)||n.length<=2?t:n.slice(-2).join(".")}setTenant(t,n){var u;const r=(u=n.urlPatterns)==null?void 0:u.find(f=>f.patternType==="subdomain"&&f.tenantId===t.id&&f.isActive);if(!r)throw new Error(`No active subdomain pattern found for tenant '${t.name}'`);const o=new URL(window.location.href),s=r.patternValue,i=o.hostname,a=this.getBaseDomain(i),l=s?`${s}.${a}`:a;o.hostname=l,window.location.href=o.toString()}getCurrentTenantName(){const t=window.location.hostname;return this.extractSubdomain(t)||null}}const hd={queryParams:new l0,sessionStorage:new c0,cookie:new d0,subdomain:new f0},p0=e=>{const t=hd[e.clientSideMode];if(!t)throw new Error(`Client side tenant mode '${e.clientSideMode}' is not supported ${JSON.stringify({strategies:hd},null,2)}`);return t},h0=(e,t,n)=>{const r=t.find(s=>s.name===n);if(!r)throw Error("No tenant permission");return p0(e).setTenant(r,e),r},m0=()=>{const[e,t]=fn(),{tenants:n=[],currentTenant:r,tenantConfig:o=a0}=e,s=S.useCallback(i=>{const a=h0(o,n,i);t({...e,currentTenant:a})},[o,e]);return{tenants:n,currentTenant:r,tenantConfig:o,selectTenant:s}};function g0(e){if(!e.ok)throw console.error(e),new Error(e.statusText)}async function Eo(e,t,n,r){const o=await e(`/user-states/${encodeURIComponent(t)}/${encodeURIComponent(n)}`,r);return g0(o),o}class To{static async get(t,n,r){const s=await Eo(t,n,r,{method:"GET",headers:{"Content-Type":"application/json"}});return s.status===204?null:await s.json()}static async create(t,n,r,o){const s={method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({value:o})};return await(await Eo(t,n,r,s)).json()}static async update(t,n,r,o){const s={method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({value:o})};return await(await Eo(t,n,r,s)).json()}static async delete(t,n,r){return await Eo(t,n,r,{method:"DELETE",headers:{"Content-Type":"application/json"}}),null}}const v0=e=>{const t=ai("@bluealba/pae-nestjs-gateway-service"),n=zu();if(!n)throw new Error("You must call the useUserState hook within a PAE application.");const[r,o]=S.useState(null),[s,i]=S.useState(!1),[a,l]=S.useState(!1),[u,f]=S.useState(null),p=(_,C)=>S.useCallback(async({newValue:T,shouldThrowError:P}={})=>{try{l(!0),f(null);const A=await _(t,n,e,T);return o(A),A?A.value:null}catch(A){if(f(A==null?void 0:A.message),console.error(`Failed to ${C} ${e}:`,A),P)throw A;return null}finally{l(!1)}},[t,n,e]),m=p(To.get,"fetch"),g=p(To.create,"create"),y=p(To.update,"update"),h=p(To.delete,"delete"),v=S.useCallback(async()=>{try{await m()}finally{i(!0)}},[m]);S.useEffect(()=>{v()},[v]);const b=S.useCallback(async(_,C=!1)=>r==null?await g({newValue:_,shouldThrowError:C}):await y({newValue:_,shouldThrowError:C}),[r,g,y]);return{value:r?r.value:null,hasFetched:s,loading:a,error:u,setValue:b,createValue:g,updateValue:y,deleteValue:h}},md="single-spa:app-change";function y0(){const[e,t]=S.useState(gd());return S.useEffect(()=>{const n=()=>{t(gd())};return window.addEventListener(md,n),()=>{window.removeEventListener(md,n)}},[]),e}function gd(){return he.getAppNames().reduce((t,n)=>(he.getAppStatus(n)?t[n]=he.getAppStatus(n):t[n]="NOT_LOADED",t),{})}function gi(e){const n=y0()[e]??"LOAD_ERROR";return{statusName:n,isLoading:n==="LOADING_SOURCE_CODE"||n==="BOOTSTRAPPING"||n==="MOUNTING",isMounted:n==="MOUNTED",isBroken:n==="SKIP_BECAUSE_BROKEN"||n==="LOAD_ERROR"}}function b0(e){const{url:t,method:n,formData:r,onProgress:o,signal:s}=e;return new Promise((i,a)=>{const l=new XMLHttpRequest;l.withCredentials=!0,l.upload.onprogress=u=>{u.lengthComputable&&o&&o(Math.round(u.loaded/u.total*100))},l.onload=()=>{if(l.status>=400){let u="Upload failed";try{u=JSON.parse(l.responseText).message??u}catch{}const f=new Error(u);f.status=l.status,a(f);return}try{const u=JSON.parse(l.responseText);i(u)}catch{a(new Error("Failed to parse response JSON"))}},l.onerror=()=>{a(new Error("Upload failed due to a network error"))},s&&s.addEventListener("abort",()=>l.abort()),l.open(n,t),l.send(r)})}const ar="File storage is disabled on this platform";async function Po(e){let t=`Request failed with status ${e.status}`;try{const n=await e.json();n!=null&&n.message&&(t=n.message)}catch{}throw new Error(t)}function w0(){const[{fileStorageEnabled:e}]=fn(),t=S.useCallback((i,a)=>{if(!e)return Promise.reject(new Error(ar));const l=new FormData;return l.append("file",i),(a==null?void 0:a.isPublic)!==void 0&&l.append("isPublic",String(a.isPublic)),(a==null?void 0:a.description)!==void 0&&l.append("description",a.description),(a==null?void 0:a.metadata)!==void 0&&l.append("metadata",JSON.stringify(a.metadata)),b0({url:"/files",method:"POST",formData:l,onProgress:a==null?void 0:a.onProgress,signal:a==null?void 0:a.signal})},[e]),n=S.useCallback(async(i,a)=>{if(!e)return Promise.reject(new Error(ar));const l=new FormData;a.originalName!==void 0&&l.append("originalName",a.originalName),a.isPublic!==void 0&&l.append("isPublic",String(a.isPublic)),a.description!==void 0&&l.append("description",a.description),a.metadata!==void 0&&l.append("metadata",JSON.stringify(a.metadata));const u=await fetch(`/files/${i}`,{method:"PATCH",headers:{Accept:"application/json"},body:l});return u.ok||await Po(u),u.json()},[e]),r=S.useCallback(async i=>{if(!e)return Promise.reject(new Error(ar));const a=await fetch(`/files/${i}`,{method:"DELETE",headers:{Accept:"application/json"}});a.ok||await Po(a)},[e]),o=S.useCallback(async i=>{if(!e)return Promise.reject(new Error(ar));const a=await fetch(`/files/${i}/download`);a.ok||await Po(a);const l=await a.blob(),u=URL.createObjectURL(l);let f=`file-${i}`;const p=a.headers.get("Content-Disposition");if(p){const g=p.match(/attachment;\s*filename="([^"]+)"/);g&&(f=g[1])}const m=document.createElement("a");m.href=u,m.download=f,document.body.appendChild(m),m.click(),document.body.removeChild(m),URL.revokeObjectURL(u)},[e]),s=S.useCallback(async i=>{if(!e)return Promise.reject(new Error(ar));const a=await fetch(`/files/${i}/download`);a.ok||await Po(a);const l=await a.blob();return URL.createObjectURL(l)},[e]);return{isEnabled:e,upload:t,updateMetadata:n,remove:r,download:o,getPreviewUrl:s}}const vd="__PAE_EXTENSION_POINT_REACT_CONTENT_EMPTY__",_0=({module:e,point:t,children:n})=>(Qu(e,t,n??vd),null),yd=({name:e,children:t,...n})=>{const r=Ku(e);if(r===vd)return null;if(!r)return c.jsx(c.Fragment,{children:t??null});if(x0(r)){const o=r;return c.jsx(o,{...n})}else return r},x0=e=>typeof e=="function",C0=(e,t)=>{const n=r=>(t=t||e.displayName||e.name||"?",c.jsx(yd,{name:t,...r,children:c.jsx(e,{...r})}));return n.displayName=`extensionPoint(${t})`,n},bd=({appName:e})=>c.jsx("div",{children:c.jsxs("p",{children:["Loading ",e,"..."]})});bd.displayName="BaseLoading";const wd=({appName:e})=>c.jsxs("div",{children:[c.jsx("p",{children:"Something went wrong..."}),c.jsxs("p",{children:["Failed to load ",e]})]});wd.displayName="BaseError";const S0={display:"flex",flexDirection:"column",flex:1},_d=S.forwardRef((e,t)=>c.jsx("div",{ref:t,style:S0,...e}));_d.displayName="BaseContainer";const E0="pae-app:",xd=S.forwardRef(({appName:e,LoadingComponent:t=bd,ErrorComponent:n=wd,ContainerComponent:r=_d,...o},s)=>{const i=gi(e);return c.jsxs(r,{ref:s,...o,id:`${E0}${e}`,children:[i.isLoading&&c.jsx(t,{appName:e}),i.isBroken&&c.jsx(n,{appName:e})]})});xd.displayName="ModulePlaceHolder";const vi=({operations:e,children:t,forbiddenContent:n})=>{var o;const{hasAccess:r}=Gn();if(!r(...e)){if(!n)return null;if(typeof n=="function")if((o=n==null?void 0:n.prototype)!=null&&o.isReactComponent){const s=n;return c.jsx(s,{operations:e})}else return n({operations:e});return S.isValidElement(n)?n:null}return t};vi.displayName="Authorized";const T0=({eventName:e,listener:t})=>(Yu(e,t),null),P0=()=>c.jsx("svg",{"aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24",children:c.jsx("path",{stroke:"currentColor",strokeLinecap:"round",strokeWidth:"2",d:"M8.737 8.737a21.49 21.49 0 0 1 3.308-2.724m0 0c3.063-2.026 5.99-2.641 7.331-1.3 1.827 1.828.026 6.591-4.023 10.64-4.049 4.049-8.812 5.85-10.64 4.023-1.33-1.33-.736-4.218 1.249-7.253m6.083-6.11c-3.063-2.026-5.99-2.641-7.331-1.3-1.827 1.828-.026 6.591 4.023 10.64m3.308-9.34a21.497 21.497 0 0 1 3.308 2.724m2.775 3.386c1.985 3.035 2.579 5.923 1.248 7.253-1.336 1.337-4.245.732-7.295-1.275M14 12a2 2 0 1 1-4 0 2 2 0 0 1 4 0Z"})}),Cd=({applicationName:e})=>{const t=Wu(e);if(t)if(typeof t=="function"){const n=t;return c.jsx(n,{})}else return t;return c.jsx(P0,{})};Cd.displayName="ApplicationIcon";const Sd=()=>c.jsx("svg",{width:"28",height:"28",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M15.9998 29.3337C8.63584 29.3337 2.6665 23.3643 2.6665 16.0003C2.6665 8.63633 8.63584 2.66699 15.9998 2.66699C23.3638 2.66699 29.3332 8.63633 29.3332 16.0003C29.3332 23.3643 23.3638 29.3337 15.9998 29.3337ZM15.9998 26.667C18.8288 26.667 21.5419 25.5432 23.5423 23.5428C25.5427 21.5424 26.6665 18.8293 26.6665 16.0003C26.6665 13.1713 25.5427 10.4582 23.5423 8.45785C21.5419 6.45747 18.8288 5.33366 15.9998 5.33366C13.1709 5.33366 10.4578 6.45747 8.45736 8.45785C6.45698 10.4582 5.33317 13.1713 5.33317 16.0003C5.33317 18.8293 6.45698 21.5424 8.45736 23.5428C10.4578 25.5432 13.1709 26.667 15.9998 26.667ZM9.33317 20.427C12.2066 20.2205 14.9088 18.9833 16.9425 16.943C18.9828 14.9092 20.2201 12.2071 20.4265 9.33366C21.4117 9.99003 22.2389 10.8569 22.8486 11.8716C23.4582 12.8864 23.835 14.0239 23.9519 15.2019C24.0687 16.3799 23.9226 17.5692 23.5242 18.684C23.1257 19.7987 22.4849 20.8112 21.6478 21.6483C20.8107 22.4853 19.7982 23.1262 18.6835 23.5247C17.5687 23.9231 16.3795 24.0692 15.2014 23.9523C14.0234 23.8355 12.8859 23.4587 11.8712 22.8491C10.8564 22.2394 9.98954 21.4122 9.33317 20.427Z",fill:"currentColor"})});Sd.displayName="DarkModeIcon";const Ed=()=>c.jsx("svg",{width:"28",height:"28",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",transform:"matrix(-1,1.2246467991473532e-16,-1.2246467991473532e-16,-1,0,0)",children:c.jsx("path",{d:"M15.9998 29.3337C8.63584 29.3337 2.6665 23.3643 2.6665 16.0003C2.6665 8.63633 8.63584 2.66699 15.9998 2.66699C23.3638 2.66699 29.3332 8.63633 29.3332 16.0003C29.3332 23.3643 23.3638 29.3337 15.9998 29.3337ZM15.9998 26.667C18.8288 26.667 21.5419 25.5432 23.5423 23.5428C25.5427 21.5424 26.6665 18.8293 26.6665 16.0003C26.6665 13.1713 25.5427 10.4582 23.5423 8.45785C21.5419 6.45747 18.8288 5.33366 15.9998 5.33366C13.1709 5.33366 10.4578 6.45747 8.45736 8.45785C6.45698 10.4582 5.33317 13.1713 5.33317 16.0003C5.33317 18.8293 6.45698 21.5424 8.45736 23.5428C10.4578 25.5432 13.1709 26.667 15.9998 26.667ZM9.33317 20.427C12.2066 20.2205 14.9088 18.9833 16.9425 16.943C18.9828 14.9092 20.2201 12.2071 20.4265 9.33366C21.4117 9.99003 22.2389 10.8569 22.8486 11.8716C23.4582 12.8864 23.835 14.0239 23.9519 15.2019C24.0687 16.3799 23.9226 17.5692 23.5242 18.684C23.1257 19.7987 22.4849 20.8112 21.6478 21.6483C20.8107 22.4853 19.7982 23.1262 18.6835 23.5247C17.5687 23.9231 16.3795 24.0692 15.2014 23.9523C14.0234 23.8355 12.8859 23.4587 11.8712 22.8491C10.8564 22.2394 9.98954 21.4122 9.33317 20.427Z",fill:"currentColor"})});Ed.displayName="LightModeIcon";const yi={container:"container__zBqbk",expanded:"expanded__EbsIr",label:"label__cdMnm"},A0=e=>e.toLowerCase().trim().split(" ").join("-"),R0=e=>`${A0(e)}-theme`,Td=()=>{const{platformName:e="Platform"}=Do(),t=R0(e),[n,r]=S.useState(()=>{const s=localStorage.getItem(t);return s==="light"||s==="dark"?s:"light"}),o=s=>{localStorage.setItem(t,s),r(s)};return S.useEffect(()=>{document.documentElement.setAttribute("data-theme",n)},[n]),{theme:n,setTheme:o}},Pd=({isNavbarExpanded:e})=>{const{theme:t,setTheme:n}=Td(),r=()=>n(t==="dark"?"light":"dark"),o=c.jsxs("div",{className:L(yi.container,e&&yi.expanded),onClick:r,children:[t==="light"?c.jsx(Sd,{}):c.jsx(Ed,{}),e&&c.jsx("p",{className:yi.label,children:t==="light"?"Dark Mode":"Light Mode"})]});return e?o:c.jsx(Pn,{displayName:t==="light"?"Switch to dark mode":"Switch to light mode",sideOffset:-16,children:o})};Pd.displayName="ToggleTheme";const Ad=({moduleName:e,className:t,style:n,LoadingComponent:r,ErrorComponent:o,IdleComponent:s})=>{var h;const i=pn(),{statusName:a,isLoading:l,isMounted:u,isBroken:f}=gi(e),p=S.useMemo(()=>i.find(v=>v.name===e),[i,e]),m=(p==null?void 0:p.type)==="fragment"?(h=p.ui)==null?void 0:h.mountAtSelector:void 0,g=m!=null&&m.startsWith("#")?m.slice(1):null;if(S.useEffect(()=>{p?p.type!=="fragment"?console.warn(`[FragmentSlot] Module "${e}" has type "${p.type}" but expected "fragment". Only modules of type "fragment" can be rendered with the <FragmentSlot> component.`):m?m.startsWith("#")||console.warn(`[FragmentSlot] Module "${e}" has "ui.mountAtSelector" = "${m}" which is not an id selector. Only "#id" selectors are supported — the value must start with "#".`):console.warn(`[FragmentSlot] Module "${e}" does not have a "ui.mountAtSelector" configured. A fragment module must declare the DOM selector where it will be mounted.`):console.warn(`[FragmentSlot] Module "${e}" was not found in the platform catalog.`)},[p,e,m]),!p||p.type!=="fragment"||!g)return null;const y=!l&&!u&&!f;return c.jsxs(c.Fragment,{children:[c.jsx("div",{id:g,className:t,style:n}),l&&r&&c.jsx(r,{moduleName:e}),f&&o&&c.jsx(o,{moduleName:e}),y&&s&&c.jsx(s,{moduleName:e,status:a})]})};Ad.displayName="FragmentSlot";const O0=(e,t)=>{const n=r=>c.jsx(vi,{operations:t,children:c.jsx(e,{...r})});return n.displayName="Authorized",n},I0=e=>{const t={authUser:{id:"testuser",username:"testuser",displayName:"Test User",applications:[]},catalog:[],authentication:{passwordMethodEnabled:!0,registerEnabled:!0,invitationsEnabled:!0,resetPasswordExpiration:3e4,passwordConstraints:{lowerCaseRequired:!1,upperCaseRequired:!1,symbolRequired:!1,digitRequired:!1,minLength:0,maxLength:8},sessionExpiration:864e5,jwtSecret:"",sessionIncludeOrigUser:!1,impersonationMode:"cookie",canImpersonateNonExistentUsers:!1,providers:[]},platformVersion:"0.0.0",featureFlags:{},fileStorageEnabled:!1};Object.defineProperty(window,Hn,{value:e?Cy(t,e):t})},bi=()=>{const[e]=fn();return e.featureFlags},j0=e=>bi()[e],Rd=({flag:e,children:t,fallback:n=null,invert:r=!1})=>{const s=bi()[e]===!0;return(r?!s:s)?c.jsx(c.Fragment,{children:t}):c.jsx(c.Fragment,{children:n})};Rd.displayName="FeatureFlagGuard";const Od=S.createContext(null);function Id(e){const t=["#FF6B6B","#4ECDC4","#45B7D1","#FFA07A","#98D8C8","#F7DC6F","#BB8FCE","#85C1E2","#F8B739","#52B788","#E74C3C","#3498DB","#9B59B6","#1ABC9C","#F39C12","#E67E22","#95A5A6","#34495E","#16A085","#27AE60"];let n=0;for(let o=0;o<e.length;o++)n=e.charCodeAt(o)+((n<<5)-n),n=n&n;const r=Math.abs(n)%t.length;return t[r]}const wi={JOIN_ROOM:"join_room",LEAVE_ROOM:"leave_room",USER_LIST:"user_list"},jd=[1e3,2e3,4e3,8e3,16e3],k0=jd.length,L0=({children:e})=>{const t=Gu("@bluealba/pae-rooms-service"),[n,r]=S.useState([]),[o,s]=S.useState("loading"),i=S.useRef(null),a=S.useRef(!1),l=S.useRef(0),u=S.useRef(null),f=S.useRef(!0),p=S.useRef(()=>{}),m=S.useCallback(A=>new Promise((R,D)=>{const k=new WebSocket(A);let N=!1;k.onopen=()=>{N=!0,l.current=0,f.current&&s("connected"),R(k)},k.addEventListener("message",async U=>{try{const W=await h(U);W.event===wi.USER_LIST&&C(W.data)}catch(W){console.error("Error parsing WebSocket message:",W)}}),k.onerror=U=>{console.error("Rooms WebSocket error",U)},k.onclose=()=>{if(i.current!==k){N||D(new Error("WebSocket connection replaced"));return}a.current?f.current&&s("closed"):p.current(),N||D(new Error("WebSocket connection failed"))},i.current=k}),[]),g=S.useCallback(()=>{if(!t||!f.current)return;if(l.current>=k0){s("error");return}const A=jd[l.current];l.current++,s("reconnecting"),u.current=setTimeout(()=>{f.current&&t&&m(t).catch(()=>{})},A)},[t,m]);p.current=g;const y=S.useCallback(()=>{if(!t)return;u.current&&(clearTimeout(u.current),u.current=null);const A=i.current;A&&A.readyState!==WebSocket.CLOSED&&(a.current=!0,A.close()),l.current=0,a.current=!1,s("loading"),m(t)},[t,m]);S.useEffect(()=>{if(f.current=!0,a.current=!1,t)return m(t),()=>{var A;f.current=!1,u.current&&(clearTimeout(u.current),u.current=null),a.current=!0,(A=i.current)==null||A.close()}},[t,m]),S.useEffect(()=>{const A=()=>{if(document.visibilityState!=="visible")return;const R=i.current;R&&R.readyState===WebSocket.OPEN||(u.current&&(clearTimeout(u.current),u.current=null),l.current=0,y())};return document.addEventListener("visibilitychange",A),()=>{document.removeEventListener("visibilitychange",A)}},[y]);const h=async A=>{if(A.data instanceof Blob){const R=await A.data.text();return JSON.parse(R)}else return JSON.parse(A.data)},v=(A,R)=>{const D=i.current;!D||D.readyState!==WebSocket.OPEN||setTimeout(()=>{D.send(JSON.stringify({event:A,data:R}))},100)},b=A=>{v(wi.JOIN_ROOM,{roomId:A})},_=A=>{v(wi.LEAVE_ROOM,{roomId:A})},C=A=>{r(A.map(R=>({...R,username:R.username.toLowerCase(),color:Id(R.username)})))},T=S.useCallback(A=>n.filter(R=>R.rooms.includes(A)),[n]),P={status:o,getRoomUsers:T,joinRoom:b,leaveRoom:_,reconnect:y};return c.jsx(Od.Provider,{value:P,children:e})},kd={autoJoin:!0,autoLeave:!0};function D0(e,t=kd){const{autoJoin:n,autoLeave:r}=t,o=S.useContext(Od),{authUser:s}=Gn();if(!o)throw new Error("useRoom must be used within RoomsProvider");const i=S.useRef(!1),a=()=>{if(n){console.warn("[useRoom] Ignoring manual joinRoom call because autoJoin is enabled.",{roomId:e});return}return i.current=!0,o.joinRoom(e)},l=()=>{if(r){console.warn("[useRoom] Ignoring manual leaveRoom call because autoLeave is enabled.",{roomId:e});return}return i.current=!1,o.leaveRoom(e)};S.useEffect(()=>{if(!(!e||o.status!=="connected"))return(n||i.current)&&o.joinRoom(e),()=>{r&&o.status==="connected"&&o.leaveRoom(e)}},[o.status,e]);const u=o.getRoomUsers(e),f=u.findIndex(p=>p.username===(s==null?void 0:s.username))!==-1;return{users:u,roomId:e,hasJoined:f,joinRoom:a,leaveRoom:l,reconnect:o.reconnect}}const lr={container:"container__LbyGQ",avatarWrapper:"avatarWrapper__HCQIZ",avatar:"avatar__E453a",overflowWrapper:"overflowWrapper__ETnPO",overflowBadge:"overflowBadge__igBKT"},N0={sm:24,md:32,lg:40},M0=({users:e,maxVisible:t=5,size:n="md",overlap:r=!0,className:o="",onUserClick:s})=>{const i=N0[n],a=S.useMemo(()=>e.slice(0,t),[e,t]),l=S.useMemo(()=>e.slice(t),[e,t]),u=Math.max(0,e.length-t),f=p=>p.split(" ").map(m=>m[0]).join("").toUpperCase().slice(0,2);return c.jsxs("div",{className:L(lr.container,o),children:[a.map((p,m)=>c.jsx(Pn,{tooltipContent:p.displayName,side:"bottom",children:c.jsx("div",{className:lr.avatarWrapper,style:{marginLeft:m>0&&r?`-${i*.25}px`:void 0},onClick:()=>s==null?void 0:s(p),children:c.jsx("div",{className:lr.avatar,style:{width:i,height:i,backgroundColor:p.color,fontSize:n==="sm"?"10px":n==="md"?"12px":"14px",cursor:s?"pointer":"default"},children:f(p.displayName)})})},p.username)),u>0&&c.jsx(Pn,{side:"bottom",tooltipContent:c.jsx("div",{children:l.map(p=>c.jsx("p",{children:p.displayName},p.username))}),children:c.jsx("div",{className:lr.overflowWrapper,style:{marginLeft:r?`-${i*.25}px`:void 0},children:c.jsxs("div",{className:lr.overflowBadge,style:{width:i,height:i,fontSize:n==="sm"?"10px":n==="md"?"12px":"14px"},children:["+",u]})})})]})};E.Alert=go,E.ApplicationIcon=Cd,E.Authorized=vi,E.Badge=ns,E.Badges=rs,E.Button=Or,E.ClipboardCheckIcon=Na,E.ClipboardIcon=Da,E.ConfirmDialog=xu,E.CopyToClipboardButton=sh,E.DEFAULT_OPTIONS=kd,E.Dialog=ye,E.DropdownList=ao,E.EmptyState=ri,E.ErrorState=Qs,E.ExtendExtensionPoint=_0,E.ExtensionPoint=yd,E.EyeIcon=Qc,E.FeatureFlagGuard=Rd,E.FieldGroup=$a,E.FragmentSlot=Ad,E.Input=jr,E.InputError=Ba,E.Label=Wa,E.List=Je,E.ModulePlaceHolder=xd,E.Pagination=Zs,E.PaginationContent=Xs,E.PaginationEllipsis=ti,E.PaginationItem=sr,E.PaginationLink=ir,E.PaginationNext=ei,E.PaginationPrevious=Js,E.PasswordInput=Iv,E.Pill=ty,E.PlatformEventListener=T0,E.PlatformEvents=of,E.PluralizeCounter=ni,E.PortalContainerProvider=Fu,E.RoomAvatars=M0,E.RoomsProvider=L0,E.SearchAutocomplete=Uc,E.SearchInput=Vs,E.Select=ss,E.Select2=Tc,E.Show=St,E.Skeleton=co,E.SkeletonList=Vc,E.Spinner=Gc,E.Switch=qc,E.Table=Mu,E.Tabs=Pv,E.TabsContent=Ov,E.TabsList=Av,E.TabsTrigger=Rv,E.TextArea=Pc,E.TextWithTooltip=Fc,E.ThemeToggle=Pd,E.Tooltip=Pn,E.authorized=O0,E.dropdownListStyles=Xt,E.extensionPoint=C0,E.generateUserColor=Id,E.getApplications=Lo,E.getInitials=_f,E.getOperations=Vi,E.hasAccess=Gi,E.initializeMicroFrontend=hy,E.isPlatformCustomizationCompleted=t0,E.isValidEmail=wf,E.logout=vf,E.navigateTo=yf,E.platformHaveAnyCustomization=e0,E.setupTestEnvironment=I0,E.useAppStatus=gi,E.useApplicationIcon=Wu,E.useApplicationJSModule=vo,E.useApplicationMenu=by,E.useApplicationUIModule=Xi,E.useApplications=Yi,E.useAuth=Gn,E.useCatalog=pn,E.useCurrentApplication=si,E.useCurrentApplicationName=zu,E.useCurrentJSModule=Py,E.useDynamicFonts=Xu,E.useDynamicStyleSheet=Zu,E.useExtendExtensionPoint=Qu,E.useExtensionPoint=Ku,E.useFeatureFlag=j0,E.useFeatureFlags=bi,E.useFileStorage=w0,E.useGetPlatformTheme=Jy,E.useHasNoSession=hf,E.useLocation=Fi,E.useModule=No,E.useModuleCommonPaths=gf,E.useModuleConfig=Do,E.useModuleConfigByName=qi,E.useModuleMenu=Hu,E.useModuleMetadata=zn,E.useMutableCatalog=uf,E.useNotifications=fi,E.useOperations=zi,E.usePAECustomizationsLoadingState=Xy,E.usePAEState=fn,E.usePlatformCustomization=Zy,E.usePlatformEventListener=Yu,E.usePortalContainer=uy,E.useResource=n0,E.useResourceActions=dd,E.useRoom=D0,E.useServiceBaseURL=ii,E.useServiceInvoker=ai,E.useServiceWebSocketURL=Gu,E.useTenants=m0,E.useTheme=Td,E.useTrackEvent=ky,E.useTrackEvents=qu,E.useUIApplications=Zi,E.useUserState=v0,Object.defineProperty(E,Symbol.toStringTag,{value:"Module"})});
|
|
254
|
+
`):"",this.name="UnsubscriptionError",this.errors=n}});function ui(e,t){if(e){var n=e.indexOf(t);0<=n&&e.splice(n,1)}}var bo=function(){function e(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}return e.prototype.unsubscribe=function(){var t,n,r,o,s;if(!this.closed){this.closed=!0;var i=this._parentage;if(i)if(this._parentage=null,Array.isArray(i))try{for(var a=Ps(i),l=a.next();!l.done;l=a.next()){var u=l.value;u.remove(this)}}catch(h){t={error:h}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}else i.remove(this);var f=this.initialTeardown;if(ut(f))try{f()}catch(h){s=h instanceof ci?h.errors:[h]}var p=this._finalizers;if(p){this._finalizers=null;try{for(var m=Ps(p),g=m.next();!g.done;g=m.next()){var y=g.value;try{sd(y)}catch(h){s=s??[],h instanceof ci?s=Kr(Kr([],As(s)),As(h.errors)):s.push(h)}}}catch(h){r={error:h}}finally{try{g&&!g.done&&(o=m.return)&&o.call(m)}finally{if(r)throw r.error}}}if(s)throw new ci(s)}},e.prototype.add=function(t){var n;if(t&&t!==this)if(this.closed)sd(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=(n=this._finalizers)!==null&&n!==void 0?n:[]).push(t)}},e.prototype._hasParent=function(t){var n=this._parentage;return n===t||Array.isArray(n)&&n.includes(t)},e.prototype._addParent=function(t){var n=this._parentage;this._parentage=Array.isArray(n)?(n.push(t),n):n?[n,t]:t},e.prototype._removeParent=function(t){var n=this._parentage;n===t?this._parentage=null:Array.isArray(n)&&ui(n,t)},e.prototype.remove=function(t){var n=this._finalizers;n&&ui(n,t),t instanceof e&&t._removeParent(this)},e.EMPTY=function(){var t=new e;return t.closed=!0,t}(),e}(),rd=bo.EMPTY;function od(e){return e instanceof bo||e&&"closed"in e&&ut(e.remove)&&ut(e.add)&&ut(e.unsubscribe)}function sd(e){ut(e)?e():e.unsubscribe()}var Wy={Promise:void 0},Hy={setTimeout:function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];return setTimeout.apply(void 0,Kr([e,t],As(n)))},clearTimeout:function(e){return clearTimeout(e)},delegate:void 0};function Vy(e){Hy.setTimeout(function(){throw e})}function id(){}function wo(e){e()}var ad=function(e){Jn(t,e);function t(n){var r=e.call(this)||this;return r.isStopped=!1,n?(r.destination=n,od(n)&&n.add(r)):r.destination=qy,r}return t.create=function(n,r,o){return new di(n,r,o)},t.prototype.next=function(n){this.isStopped||this._next(n)},t.prototype.error=function(n){this.isStopped||(this.isStopped=!0,this._error(n))},t.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,e.prototype.unsubscribe.call(this),this.destination=null)},t.prototype._next=function(n){this.destination.next(n)},t.prototype._error=function(n){try{this.destination.error(n)}finally{this.unsubscribe()}},t.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},t}(bo),zy=function(){function e(t){this.partialObserver=t}return e.prototype.next=function(t){var n=this.partialObserver;if(n.next)try{n.next(t)}catch(r){_o(r)}},e.prototype.error=function(t){var n=this.partialObserver;if(n.error)try{n.error(t)}catch(r){_o(r)}else _o(t)},e.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(n){_o(n)}},e}(),di=function(e){Jn(t,e);function t(n,r,o){var s=e.call(this)||this,i;return ut(n)||!n?i={next:n??void 0,error:r??void 0,complete:o??void 0}:i=n,s.destination=new zy(i),s}return t}(ad);function _o(e){Vy(e)}function Gy(e){throw e}var qy={closed:!0,next:id,error:Gy,complete:id},Ky=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function Qy(e){return e}function Yy(e){return e.length===0?Qy:e.length===1?e[0]:function(n){return e.reduce(function(r,o){return o(r)},n)}}var ld=function(){function e(t){t&&(this._subscribe=t)}return e.prototype.lift=function(t){var n=new e;return n.source=this,n.operator=t,n},e.prototype.subscribe=function(t,n,r){var o=this,s=Xy(t)?t:new di(t,n,r);return wo(function(){var i=o,a=i.operator,l=i.source;s.add(a?a.call(s,l):l?o._subscribe(s):o._trySubscribe(s))}),s},e.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(n){t.error(n)}},e.prototype.forEach=function(t,n){var r=this;return n=cd(n),new n(function(o,s){var i=new di({next:function(a){try{t(a)}catch(l){s(l),i.unsubscribe()}},error:s,complete:o});r.subscribe(i)})},e.prototype._subscribe=function(t){var n;return(n=this.source)===null||n===void 0?void 0:n.subscribe(t)},e.prototype[Ky]=function(){return this},e.prototype.pipe=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return Yy(t)(this)},e.prototype.toPromise=function(t){var n=this;return t=cd(t),new t(function(r,o){var s;n.subscribe(function(i){return s=i},function(i){return o(i)},function(){return r(s)})})},e.create=function(t){return new e(t)},e}();function cd(e){var t;return(t=e??Wy.Promise)!==null&&t!==void 0?t:Promise}function Zy(e){return e&&ut(e.next)&&ut(e.error)&&ut(e.complete)}function Xy(e){return e&&e instanceof ad||Zy(e)&&od(e)}var Jy=nd(function(e){return function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),ud=function(e){Jn(t,e);function t(){var n=e.call(this)||this;return n.closed=!1,n.currentObservers=null,n.observers=[],n.isStopped=!1,n.hasError=!1,n.thrownError=null,n}return t.prototype.lift=function(n){var r=new dd(this,this);return r.operator=n,r},t.prototype._throwIfClosed=function(){if(this.closed)throw new Jy},t.prototype.next=function(n){var r=this;wo(function(){var o,s;if(r._throwIfClosed(),!r.isStopped){r.currentObservers||(r.currentObservers=Array.from(r.observers));try{for(var i=Ps(r.currentObservers),a=i.next();!a.done;a=i.next()){var l=a.value;l.next(n)}}catch(u){o={error:u}}finally{try{a&&!a.done&&(s=i.return)&&s.call(i)}finally{if(o)throw o.error}}}})},t.prototype.error=function(n){var r=this;wo(function(){if(r._throwIfClosed(),!r.isStopped){r.hasError=r.isStopped=!0,r.thrownError=n;for(var o=r.observers;o.length;)o.shift().error(n)}})},t.prototype.complete=function(){var n=this;wo(function(){if(n._throwIfClosed(),!n.isStopped){n.isStopped=!0;for(var r=n.observers;r.length;)r.shift().complete()}})},t.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(t.prototype,"observed",{get:function(){var n;return((n=this.observers)===null||n===void 0?void 0:n.length)>0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(n){return this._throwIfClosed(),e.prototype._trySubscribe.call(this,n)},t.prototype._subscribe=function(n){return this._throwIfClosed(),this._checkFinalizedStatuses(n),this._innerSubscribe(n)},t.prototype._innerSubscribe=function(n){var r=this,o=this,s=o.hasError,i=o.isStopped,a=o.observers;return s||i?rd:(this.currentObservers=null,a.push(n),new bo(function(){r.currentObservers=null,ui(a,n)}))},t.prototype._checkFinalizedStatuses=function(n){var r=this,o=r.hasError,s=r.thrownError,i=r.isStopped;o?n.error(s):i&&n.complete()},t.prototype.asObservable=function(){var n=new ld;return n.source=this,n},t.create=function(n,r){return new dd(n,r)},t}(ld),dd=function(e){Jn(t,e);function t(n,r){var o=e.call(this)||this;return o.destination=n,o.source=r,o}return t.prototype.next=function(n){var r,o;(o=(r=this.destination)===null||r===void 0?void 0:r.next)===null||o===void 0||o.call(r,n)},t.prototype.error=function(n){var r,o;(o=(r=this.destination)===null||r===void 0?void 0:r.error)===null||o===void 0||o.call(r,n)},t.prototype.complete=function(){var n,r;(r=(n=this.destination)===null||n===void 0?void 0:n.complete)===null||r===void 0||r.call(n)},t.prototype._subscribe=function(n){var r,o;return(o=(r=this.source)===null||r===void 0?void 0:r.subscribe(n))!==null&&o!==void 0?o:rd},t}(ud),e0=function(e){Jn(t,e);function t(n){var r=e.call(this)||this;return r._value=n,r}return Object.defineProperty(t.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),t.prototype._subscribe=function(n){var r=e.prototype._subscribe.call(this,n);return!r.closed&&n.next(this._value),r},t.prototype.getValue=function(){var n=this,r=n.hasError,o=n.thrownError,s=n._value;if(r)throw o;return this._throwIfClosed(),s},t.prototype.next=function(n){e.prototype.next.call(this,this._value=n)},t}(ud);const t0=e=>{const{fontsLoaded:t}=td(e.fonts);ed(e.styleSheet);const n=()=>{const r=new e0(!0);window[Io]=r};S.useEffect(()=>{t&&window[Io].next(!1)},[t]),S.useEffect(()=>{n()},[])},n0=()=>{const e=window[Io];return Fi(e,e.getValue()??void 0)},fi="theme",fd=()=>document.documentElement.dataset[fi]==="dark"?"dark":"light",r0=()=>{const[e,t]=S.useState(fd());return S.useEffect(()=>{const n=document.documentElement,r=()=>t(fd),o=new MutationObserver(s=>{for(const i of s)i.type==="attributes"&&i.attributeName===`data-${fi}`&&r()});return o.observe(n,{attributes:!0,attributeFilter:[`data-${fi}`]}),r(),()=>{o.disconnect()}},[]),e},o0=e=>e!==void 0,s0=e=>e!==!0,pi=()=>({notify:S.useCallback((t,n,r)=>{const o={style:{background:"var(--platform-background-primary-color)",color:"var(--platform-text-primary-color)"}};n==="warning"||n==="info"?da(t,{...o,icon:n==="warning"?"⚠️":"ℹ️"}):da[n](t,o),r&&console.error(r)},[])}),xo={STALE_TIME:1e3*60*5,GC_TIME:1e3*60*10,RETRY_COUNT:1,RETRY_DELAY:1e3},pd={refetchOnWindowFocus:!1,refetchOnReconnect:!1,refetchOnMount:!1,staleTime:xo.STALE_TIME,gcTime:xo.GC_TIME,retry:xo.RETRY_COUNT,retryDelay:xo.RETRY_DELAY,enable:!0},Co=e=>e instanceof Error?e.message:String(e),hd=(e,t,n)=>{const r=es(),{notify:o}=pi(),{createFn:s,readFn:i,readByIdFn:a,updateFn:l,deleteFn:u,partialUpdateFn:f}=n,p=()=>{r.invalidateQueries({queryKey:[e]})},m=(T,P,A,R)=>o(R!=null&&R.overrideSuccessMessage?R==null?void 0:R.overrideSuccessMessage(T,P):A,"success"),g=(T,P,A,R)=>o(R!=null&&R.overrideErrorMessage?R==null?void 0:R.overrideErrorMessage(T,P):A,"error");return{useCreate:T=>Ar({mutationFn:P=>s(P),onSuccess:P=>{p(),m(t,P,`${t} created successfully`,T)},onError:P=>{g(t,P,`Error creating ${t}: ${Co(P)}`,T)}}),useReadQuery:T=>ja({queryKey:[e],queryFn:i,...pd,...T}),useReadByIdQuery:(T,P)=>ja({queryKey:[e,T],queryFn:()=>a(T),...pd,enabled:!!T,...P}),useUpdate:T=>Ar({mutationFn:({id:P,data:A})=>l(P,A),onSuccess:P=>{p(),m(t,P,`${t} updated successfully`,T)},onError:P=>{g(t,P,`Error updating ${t}: ${Co(P)}`,T)}}),usePartialUpdate:T=>f&&Ar({mutationFn:({id:P,data:A})=>f(P,A),onSuccess:P=>{p(),m(t,P,`${t} updated successfully`,T)},onError:P=>{g(t,P,`Error updating ${t}: ${Co(P)}`,T)}}),useDelete:T=>Ar({mutationFn:P=>u(P),onSuccess:()=>{p(),m(t,null,`${t} deleted successfully`,T)},onError:P=>{g(t,P,`Error deleting ${t}: ${Co(P)}`,T)}}),invalidateQueries:p}},i0=(e,t)=>hd(e,t,{createFn:n=>fetch(e,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(n)}).then(r=>r.json()),deleteFn:n=>fetch(`${e}/${n}`,{method:"DELETE"}).then(r=>{if(!r.ok)throw new Error(`Error deleting: ${r.status}`)}),readByIdFn:n=>fetch(`${e}/${n}`).then(r=>r.json()),readFn:()=>fetch(e).then(n=>n.json()),updateFn:(n,r)=>fetch(`${e}/${n}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(r)}).then(o=>o.json()),partialUpdateFn:(n,r)=>fetch(`${e}/${n}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify(r)}).then(o=>o.json())}),a0={SINGLE_TENANT:"single-tenant"},l0={COOKIE:"cookie"},hi="tenant",md="tenant",gd="tenant",c0=a0.SINGLE_TENANT,u0=l0.COOKIE,d0={mode:c0,clientSideMode:u0,tenantIDPProvisioningStrategy:"none"};class f0{setTenant(t,n){const r=new URL(window.location.href);r.searchParams.set(md,t.name),window.location.href=r.toString()}getCurrentTenantName(){const t=new URL(window.location.href);return new URLSearchParams(t.search).get(md)}}class p0{setTenant(t,n){sessionStorage.setItem(gd,t.name),window.location.reload()}getCurrentTenantName(){return sessionStorage.getItem(gd)}}/*! js-cookie v3.0.5 | MIT */function So(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)e[r]=n[r]}return e}var h0={read:function(e){return e[0]==='"'&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function mi(e,t){function n(o,s,i){if(!(typeof document>"u")){i=So({},t,i),typeof i.expires=="number"&&(i.expires=new Date(Date.now()+i.expires*864e5)),i.expires&&(i.expires=i.expires.toUTCString()),o=encodeURIComponent(o).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var a="";for(var l in i)i[l]&&(a+="; "+l,i[l]!==!0&&(a+="="+i[l].split(";")[0]));return document.cookie=o+"="+e.write(s,o)+a}}function r(o){if(!(typeof document>"u"||arguments.length&&!o)){for(var s=document.cookie?document.cookie.split("; "):[],i={},a=0;a<s.length;a++){var l=s[a].split("="),u=l.slice(1).join("=");try{var f=decodeURIComponent(l[0]);if(i[f]=e.read(u,f),o===f)break}catch{}}return o?i[o]:i}}return Object.create({set:n,get:r,remove:function(o,s){n(o,"",So({},s,{expires:-1}))},withAttributes:function(o){return mi(this.converter,So({},this.attributes,o))},withConverter:function(o){return mi(So({},this.converter,o),this.attributes)}},{attributes:{value:Object.freeze(t)},converter:{value:Object.freeze(e)}})}var gi=mi(h0,{path:"/"});class m0{setTenant(t,n){t?gi.set(hi,t.name):gi.remove(hi),window.location.reload()}getCurrentTenantName(){return gi.get(hi)}}class g0{extractSubdomain(t){if(t==="localhost"||/^\d+\.\d+\.\d+\.\d+$/.test(t))return"";const n=t.split(".");if(n.length<2||n.length===2||n[0]==="www"&&n.length===3)return"";const o=(n[0]==="www"?n.slice(1):n).slice(0,-2);return o.length>0?o.join("."):""}getBaseDomain(t){const n=t.split(".");return t==="localhost"||/^\d+\.\d+\.\d+\.\d+$/.test(t)||n.length<=2?t:n.slice(-2).join(".")}setTenant(t,n){var u;const r=(u=n.urlPatterns)==null?void 0:u.find(f=>f.patternType==="subdomain"&&f.tenantId===t.id&&f.isActive);if(!r)throw new Error(`No active subdomain pattern found for tenant '${t.name}'`);const o=new URL(window.location.href),s=r.patternValue,i=o.hostname,a=this.getBaseDomain(i),l=s?`${s}.${a}`:a;o.hostname=l,window.location.href=o.toString()}getCurrentTenantName(){const t=window.location.hostname;return this.extractSubdomain(t)||null}}const vd={queryParams:new f0,sessionStorage:new p0,cookie:new m0,subdomain:new g0},v0=e=>{const t=vd[e.clientSideMode];if(!t)throw new Error(`Client side tenant mode '${e.clientSideMode}' is not supported ${JSON.stringify({strategies:vd},null,2)}`);return t},y0=(e,t,n)=>{const r=t.find(s=>s.name===n);if(!r)throw Error("No tenant permission");return v0(e).setTenant(r,e),r},b0=()=>{const[e,t]=fn(),{tenants:n=[],currentTenant:r,tenantConfig:o=d0}=e,s=S.useCallback(i=>{const a=y0(o,n,i);t({...e,currentTenant:a})},[o,e]);return{tenants:n,currentTenant:r,tenantConfig:o,selectTenant:s}};function w0(e){if(!e.ok)throw console.error(e),new Error(e.statusText)}async function Eo(e,t,n,r){const o=await e(`/user-states/${encodeURIComponent(t)}/${encodeURIComponent(n)}`,r);return w0(o),o}class To{static async get(t,n,r){const s=await Eo(t,n,r,{method:"GET",headers:{"Content-Type":"application/json"}});return s.status===204?null:await s.json()}static async create(t,n,r,o){const s={method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({value:o})};return await(await Eo(t,n,r,s)).json()}static async update(t,n,r,o){const s={method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({value:o})};return await(await Eo(t,n,r,s)).json()}static async delete(t,n,r){return await Eo(t,n,r,{method:"DELETE",headers:{"Content-Type":"application/json"}}),null}}const _0=e=>{const t=li("@bluealba/pae-nestjs-gateway-service"),n=Ku();if(!n)throw new Error("You must call the useUserState hook within a PAE application.");const[r,o]=S.useState(null),[s,i]=S.useState(!1),[a,l]=S.useState(!1),[u,f]=S.useState(null),p=(_,C)=>S.useCallback(async({newValue:T,shouldThrowError:P}={})=>{try{l(!0),f(null);const A=await _(t,n,e,T);return o(A),A?A.value:null}catch(A){if(f(A==null?void 0:A.message),console.error(`Failed to ${C} ${e}:`,A),P)throw A;return null}finally{l(!1)}},[t,n,e]),m=p(To.get,"fetch"),g=p(To.create,"create"),y=p(To.update,"update"),h=p(To.delete,"delete"),v=S.useCallback(async()=>{try{await m()}finally{i(!0)}},[m]);S.useEffect(()=>{v()},[v]);const b=S.useCallback(async(_,C=!1)=>r==null?await g({newValue:_,shouldThrowError:C}):await y({newValue:_,shouldThrowError:C}),[r,g,y]);return{value:r?r.value:null,hasFetched:s,loading:a,error:u,setValue:b,createValue:g,updateValue:y,deleteValue:h}},yd="single-spa:app-change";function x0(){const[e,t]=S.useState(bd());return S.useEffect(()=>{const n=()=>{t(bd())};return window.addEventListener(yd,n),()=>{window.removeEventListener(yd,n)}},[]),e}function bd(){return he.getAppNames().reduce((t,n)=>(he.getAppStatus(n)?t[n]=he.getAppStatus(n):t[n]="NOT_LOADED",t),{})}function vi(e){const n=x0()[e]??"LOAD_ERROR";return{statusName:n,isLoading:n==="LOADING_SOURCE_CODE"||n==="BOOTSTRAPPING"||n==="MOUNTING",isMounted:n==="MOUNTED",isBroken:n==="SKIP_BECAUSE_BROKEN"||n==="LOAD_ERROR"}}function C0(e){const{url:t,method:n,formData:r,onProgress:o,signal:s}=e;return new Promise((i,a)=>{const l=new XMLHttpRequest;l.withCredentials=!0,l.upload.onprogress=u=>{u.lengthComputable&&o&&o(Math.round(u.loaded/u.total*100))},l.onload=()=>{if(l.status>=400){let u="Upload failed";try{u=JSON.parse(l.responseText).message??u}catch{}const f=new Error(u);f.status=l.status,a(f);return}try{const u=JSON.parse(l.responseText);i(u)}catch{a(new Error("Failed to parse response JSON"))}},l.onerror=()=>{a(new Error("Upload failed due to a network error"))},s&&s.addEventListener("abort",()=>l.abort()),l.open(n,t),l.send(r)})}const ar="File storage is disabled on this platform";async function Po(e){let t=`Request failed with status ${e.status}`;try{const n=await e.json();n!=null&&n.message&&(t=n.message)}catch{}throw new Error(t)}function S0(){const[{fileStorageEnabled:e}]=fn(),t=S.useCallback((i,a)=>{if(!e)return Promise.reject(new Error(ar));const l=new FormData;return l.append("file",i),(a==null?void 0:a.isPublic)!==void 0&&l.append("isPublic",String(a.isPublic)),(a==null?void 0:a.description)!==void 0&&l.append("description",a.description),(a==null?void 0:a.metadata)!==void 0&&l.append("metadata",JSON.stringify(a.metadata)),C0({url:"/files",method:"POST",formData:l,onProgress:a==null?void 0:a.onProgress,signal:a==null?void 0:a.signal})},[e]),n=S.useCallback(async(i,a)=>{if(!e)return Promise.reject(new Error(ar));const l=new FormData;a.originalName!==void 0&&l.append("originalName",a.originalName),a.isPublic!==void 0&&l.append("isPublic",String(a.isPublic)),a.description!==void 0&&l.append("description",a.description),a.metadata!==void 0&&l.append("metadata",JSON.stringify(a.metadata));const u=await fetch(`/files/${i}`,{method:"PATCH",headers:{Accept:"application/json"},body:l});return u.ok||await Po(u),u.json()},[e]),r=S.useCallback(async i=>{if(!e)return Promise.reject(new Error(ar));const a=await fetch(`/files/${i}`,{method:"DELETE",headers:{Accept:"application/json"}});a.ok||await Po(a)},[e]),o=S.useCallback(async i=>{if(!e)return Promise.reject(new Error(ar));const a=await fetch(`/files/${i}/download`);a.ok||await Po(a);const l=await a.blob(),u=URL.createObjectURL(l);let f=`file-${i}`;const p=a.headers.get("Content-Disposition");if(p){const g=p.match(/attachment;\s*filename="([^"]+)"/);g&&(f=g[1])}const m=document.createElement("a");m.href=u,m.download=f,document.body.appendChild(m),m.click(),document.body.removeChild(m),URL.revokeObjectURL(u)},[e]),s=S.useCallback(async i=>{if(!e)return Promise.reject(new Error(ar));const a=await fetch(`/files/${i}/download`);a.ok||await Po(a);const l=await a.blob();return URL.createObjectURL(l)},[e]);return{isEnabled:e,upload:t,updateMetadata:n,remove:r,download:o,getPreviewUrl:s}}const wd="__PAE_EXTENSION_POINT_REACT_CONTENT_EMPTY__",E0=({module:e,point:t,children:n})=>(Xu(e,t,n??wd),null),_d=({name:e,children:t,...n})=>{const r=Zu(e);if(r===wd)return null;if(!r)return c.jsx(c.Fragment,{children:t??null});if(T0(r)){const o=r;return c.jsx(o,{...n})}else return r},T0=e=>typeof e=="function",P0=(e,t)=>{const n=r=>(t=t||e.displayName||e.name||"?",c.jsx(_d,{name:t,...r,children:c.jsx(e,{...r})}));return n.displayName=`extensionPoint(${t})`,n},xd=({appName:e})=>c.jsx("div",{children:c.jsxs("p",{children:["Loading ",e,"..."]})});xd.displayName="BaseLoading";const Cd=({appName:e})=>c.jsxs("div",{children:[c.jsx("p",{children:"Something went wrong..."}),c.jsxs("p",{children:["Failed to load ",e]})]});Cd.displayName="BaseError";const A0={display:"flex",flexDirection:"column",flex:1},Sd=S.forwardRef((e,t)=>c.jsx("div",{ref:t,style:A0,...e}));Sd.displayName="BaseContainer";const R0="pae-app:",Ed=S.forwardRef(({appName:e,LoadingComponent:t=xd,ErrorComponent:n=Cd,ContainerComponent:r=Sd,...o},s)=>{const i=vi(e);return c.jsxs(r,{ref:s,...o,id:`${R0}${e}`,children:[i.isLoading&&c.jsx(t,{appName:e}),i.isBroken&&c.jsx(n,{appName:e})]})});Ed.displayName="ModulePlaceHolder";const yi=({operations:e,children:t,forbiddenContent:n})=>{var o;const{hasAccess:r}=Gn();if(!r(...e)){if(!n)return null;if(typeof n=="function")if((o=n==null?void 0:n.prototype)!=null&&o.isReactComponent){const s=n;return c.jsx(s,{operations:e})}else return n({operations:e});return S.isValidElement(n)?n:null}return t};yi.displayName="Authorized";const O0=({eventName:e,listener:t})=>(Ju(e,t),null),I0=()=>c.jsx("svg",{"aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24",children:c.jsx("path",{stroke:"currentColor",strokeLinecap:"round",strokeWidth:"2",d:"M8.737 8.737a21.49 21.49 0 0 1 3.308-2.724m0 0c3.063-2.026 5.99-2.641 7.331-1.3 1.827 1.828.026 6.591-4.023 10.64-4.049 4.049-8.812 5.85-10.64 4.023-1.33-1.33-.736-4.218 1.249-7.253m6.083-6.11c-3.063-2.026-5.99-2.641-7.331-1.3-1.827 1.828-.026 6.591 4.023 10.64m3.308-9.34a21.497 21.497 0 0 1 3.308 2.724m2.775 3.386c1.985 3.035 2.579 5.923 1.248 7.253-1.336 1.337-4.245.732-7.295-1.275M14 12a2 2 0 1 1-4 0 2 2 0 0 1 4 0Z"})}),Td=({applicationName:e})=>{const t=zu(e);if(t)if(typeof t=="function"){const n=t;return c.jsx(n,{})}else return t;return c.jsx(I0,{})};Td.displayName="ApplicationIcon";const Pd=()=>c.jsx("svg",{width:"28",height:"28",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:c.jsx("path",{d:"M15.9998 29.3337C8.63584 29.3337 2.6665 23.3643 2.6665 16.0003C2.6665 8.63633 8.63584 2.66699 15.9998 2.66699C23.3638 2.66699 29.3332 8.63633 29.3332 16.0003C29.3332 23.3643 23.3638 29.3337 15.9998 29.3337ZM15.9998 26.667C18.8288 26.667 21.5419 25.5432 23.5423 23.5428C25.5427 21.5424 26.6665 18.8293 26.6665 16.0003C26.6665 13.1713 25.5427 10.4582 23.5423 8.45785C21.5419 6.45747 18.8288 5.33366 15.9998 5.33366C13.1709 5.33366 10.4578 6.45747 8.45736 8.45785C6.45698 10.4582 5.33317 13.1713 5.33317 16.0003C5.33317 18.8293 6.45698 21.5424 8.45736 23.5428C10.4578 25.5432 13.1709 26.667 15.9998 26.667ZM9.33317 20.427C12.2066 20.2205 14.9088 18.9833 16.9425 16.943C18.9828 14.9092 20.2201 12.2071 20.4265 9.33366C21.4117 9.99003 22.2389 10.8569 22.8486 11.8716C23.4582 12.8864 23.835 14.0239 23.9519 15.2019C24.0687 16.3799 23.9226 17.5692 23.5242 18.684C23.1257 19.7987 22.4849 20.8112 21.6478 21.6483C20.8107 22.4853 19.7982 23.1262 18.6835 23.5247C17.5687 23.9231 16.3795 24.0692 15.2014 23.9523C14.0234 23.8355 12.8859 23.4587 11.8712 22.8491C10.8564 22.2394 9.98954 21.4122 9.33317 20.427Z",fill:"currentColor"})});Pd.displayName="DarkModeIcon";const Ad=()=>c.jsx("svg",{width:"28",height:"28",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",transform:"matrix(-1,1.2246467991473532e-16,-1.2246467991473532e-16,-1,0,0)",children:c.jsx("path",{d:"M15.9998 29.3337C8.63584 29.3337 2.6665 23.3643 2.6665 16.0003C2.6665 8.63633 8.63584 2.66699 15.9998 2.66699C23.3638 2.66699 29.3332 8.63633 29.3332 16.0003C29.3332 23.3643 23.3638 29.3337 15.9998 29.3337ZM15.9998 26.667C18.8288 26.667 21.5419 25.5432 23.5423 23.5428C25.5427 21.5424 26.6665 18.8293 26.6665 16.0003C26.6665 13.1713 25.5427 10.4582 23.5423 8.45785C21.5419 6.45747 18.8288 5.33366 15.9998 5.33366C13.1709 5.33366 10.4578 6.45747 8.45736 8.45785C6.45698 10.4582 5.33317 13.1713 5.33317 16.0003C5.33317 18.8293 6.45698 21.5424 8.45736 23.5428C10.4578 25.5432 13.1709 26.667 15.9998 26.667ZM9.33317 20.427C12.2066 20.2205 14.9088 18.9833 16.9425 16.943C18.9828 14.9092 20.2201 12.2071 20.4265 9.33366C21.4117 9.99003 22.2389 10.8569 22.8486 11.8716C23.4582 12.8864 23.835 14.0239 23.9519 15.2019C24.0687 16.3799 23.9226 17.5692 23.5242 18.684C23.1257 19.7987 22.4849 20.8112 21.6478 21.6483C20.8107 22.4853 19.7982 23.1262 18.6835 23.5247C17.5687 23.9231 16.3795 24.0692 15.2014 23.9523C14.0234 23.8355 12.8859 23.4587 11.8712 22.8491C10.8564 22.2394 9.98954 21.4122 9.33317 20.427Z",fill:"currentColor"})});Ad.displayName="LightModeIcon";const bi={container:"container__zBqbk",expanded:"expanded__EbsIr",label:"label__cdMnm"},j0=e=>e.toLowerCase().trim().split(" ").join("-"),k0=e=>`${j0(e)}-theme`,Rd=()=>{const{platformName:e="Platform"}=Do(),t=k0(e),[n,r]=S.useState(()=>{const s=localStorage.getItem(t);return s==="light"||s==="dark"?s:"light"}),o=s=>{localStorage.setItem(t,s),r(s)};return S.useEffect(()=>{document.documentElement.setAttribute("data-theme",n)},[n]),{theme:n,setTheme:o}},Od=({isNavbarExpanded:e})=>{const{theme:t,setTheme:n}=Rd(),r=()=>n(t==="dark"?"light":"dark"),o=c.jsxs("div",{className:L(bi.container,e&&bi.expanded),onClick:r,children:[t==="light"?c.jsx(Pd,{}):c.jsx(Ad,{}),e&&c.jsx("p",{className:bi.label,children:t==="light"?"Dark Mode":"Light Mode"})]});return e?o:c.jsx(Pn,{displayName:t==="light"?"Switch to dark mode":"Switch to light mode",sideOffset:-16,children:o})};Od.displayName="ToggleTheme";const Id=({moduleName:e,className:t,style:n,LoadingComponent:r,ErrorComponent:o,IdleComponent:s})=>{var h;const i=pn(),{statusName:a,isLoading:l,isMounted:u,isBroken:f}=vi(e),p=S.useMemo(()=>i.find(v=>v.name===e),[i,e]),m=(p==null?void 0:p.type)==="fragment"?(h=p.ui)==null?void 0:h.mountAtSelector:void 0,g=m!=null&&m.startsWith("#")?m.slice(1):null;if(S.useEffect(()=>{p?p.type!=="fragment"?console.warn(`[FragmentSlot] Module "${e}" has type "${p.type}" but expected "fragment". Only modules of type "fragment" can be rendered with the <FragmentSlot> component.`):m?m.startsWith("#")||console.warn(`[FragmentSlot] Module "${e}" has "ui.mountAtSelector" = "${m}" which is not an id selector. Only "#id" selectors are supported — the value must start with "#".`):console.warn(`[FragmentSlot] Module "${e}" does not have a "ui.mountAtSelector" configured. A fragment module must declare the DOM selector where it will be mounted.`):console.warn(`[FragmentSlot] Module "${e}" was not found in the platform catalog.`)},[p,e,m]),!p||p.type!=="fragment"||!g)return null;const y=!l&&!u&&!f;return c.jsxs(c.Fragment,{children:[c.jsx("div",{id:g,className:t,style:n}),l&&r&&c.jsx(r,{moduleName:e}),f&&o&&c.jsx(o,{moduleName:e}),y&&s&&c.jsx(s,{moduleName:e,status:a})]})};Id.displayName="FragmentSlot";const L0=(e,t)=>{const n=r=>c.jsx(yi,{operations:t,children:c.jsx(e,{...r})});return n.displayName="Authorized",n},D0=e=>{const t={authUser:{id:"testuser",username:"testuser",displayName:"Test User",applications:[]},catalog:[],authentication:{passwordMethodEnabled:!0,registerEnabled:!0,invitationsEnabled:!0,resetPasswordExpiration:3e4,passwordConstraints:{lowerCaseRequired:!1,upperCaseRequired:!1,symbolRequired:!1,digitRequired:!1,minLength:0,maxLength:8},sessionExpiration:864e5,jwtSecret:"",sessionIncludeOrigUser:!1,impersonationMode:"cookie",canImpersonateNonExistentUsers:!1,providers:[]},platformVersion:"0.0.0",featureFlags:{},fileStorageEnabled:!1};Object.defineProperty(window,Hn,{value:e?Py(t,e):t})},wi=()=>{const[e]=fn();return e.featureFlags},N0=e=>wi()[e],jd=({flag:e,children:t,fallback:n=null,invert:r=!1})=>{const s=wi()[e]===!0;return(r?!s:s)?c.jsx(c.Fragment,{children:t}):c.jsx(c.Fragment,{children:n})};jd.displayName="FeatureFlagGuard";const kd=S.createContext(null);function Ld(e){const t=["#FF6B6B","#4ECDC4","#45B7D1","#FFA07A","#98D8C8","#F7DC6F","#BB8FCE","#85C1E2","#F8B739","#52B788","#E74C3C","#3498DB","#9B59B6","#1ABC9C","#F39C12","#E67E22","#95A5A6","#34495E","#16A085","#27AE60"];let n=0;for(let o=0;o<e.length;o++)n=e.charCodeAt(o)+((n<<5)-n),n=n&n;const r=Math.abs(n)%t.length;return t[r]}const _i={JOIN_ROOM:"join_room",LEAVE_ROOM:"leave_room",USER_LIST:"user_list"},Dd=[1e3,2e3,4e3,8e3,16e3],M0=Dd.length,$0=({children:e})=>{const t=Qu("@bluealba/pae-rooms-service"),[n,r]=S.useState([]),[o,s]=S.useState("loading"),i=S.useRef(null),a=S.useRef(!1),l=S.useRef(0),u=S.useRef(null),f=S.useRef(!0),p=S.useRef(()=>{}),m=S.useCallback(A=>new Promise((R,D)=>{const k=new WebSocket(A);let N=!1;k.onopen=()=>{N=!0,l.current=0,f.current&&s("connected"),R(k)},k.addEventListener("message",async U=>{try{const W=await h(U);W.event===_i.USER_LIST&&C(W.data)}catch(W){console.error("Error parsing WebSocket message:",W)}}),k.onerror=U=>{console.error("Rooms WebSocket error",U)},k.onclose=()=>{if(i.current!==k){N||D(new Error("WebSocket connection replaced"));return}a.current?f.current&&s("closed"):p.current(),N||D(new Error("WebSocket connection failed"))},i.current=k}),[]),g=S.useCallback(()=>{if(!t||!f.current)return;if(l.current>=M0){s("error");return}const A=Dd[l.current];l.current++,s("reconnecting"),u.current=setTimeout(()=>{f.current&&t&&m(t).catch(()=>{})},A)},[t,m]);p.current=g;const y=S.useCallback(()=>{if(!t)return;u.current&&(clearTimeout(u.current),u.current=null);const A=i.current;A&&A.readyState!==WebSocket.CLOSED&&(a.current=!0,A.close()),l.current=0,a.current=!1,s("loading"),m(t)},[t,m]);S.useEffect(()=>{if(f.current=!0,a.current=!1,t)return m(t),()=>{var A;f.current=!1,u.current&&(clearTimeout(u.current),u.current=null),a.current=!0,(A=i.current)==null||A.close()}},[t,m]),S.useEffect(()=>{const A=()=>{if(document.visibilityState!=="visible")return;const R=i.current;R&&R.readyState===WebSocket.OPEN||(u.current&&(clearTimeout(u.current),u.current=null),l.current=0,y())};return document.addEventListener("visibilitychange",A),()=>{document.removeEventListener("visibilitychange",A)}},[y]);const h=async A=>{if(A.data instanceof Blob){const R=await A.data.text();return JSON.parse(R)}else return JSON.parse(A.data)},v=(A,R)=>{const D=i.current;!D||D.readyState!==WebSocket.OPEN||setTimeout(()=>{D.send(JSON.stringify({event:A,data:R}))},100)},b=A=>{v(_i.JOIN_ROOM,{roomId:A})},_=A=>{v(_i.LEAVE_ROOM,{roomId:A})},C=A=>{r(A.map(R=>({...R,username:R.username.toLowerCase(),color:Ld(R.username)})))},T=S.useCallback(A=>n.filter(R=>R.rooms.includes(A)),[n]),P={status:o,getRoomUsers:T,joinRoom:b,leaveRoom:_,reconnect:y};return c.jsx(kd.Provider,{value:P,children:e})},Nd={autoJoin:!0,autoLeave:!0};function F0(e,t=Nd){const{autoJoin:n,autoLeave:r}=t,o=S.useContext(kd),{authUser:s}=Gn();if(!o)throw new Error("useRoom must be used within RoomsProvider");const i=S.useRef(!1),a=()=>{if(n){console.warn("[useRoom] Ignoring manual joinRoom call because autoJoin is enabled.",{roomId:e});return}return i.current=!0,o.joinRoom(e)},l=()=>{if(r){console.warn("[useRoom] Ignoring manual leaveRoom call because autoLeave is enabled.",{roomId:e});return}return i.current=!1,o.leaveRoom(e)};S.useEffect(()=>{if(!(!e||o.status!=="connected"))return(n||i.current)&&o.joinRoom(e),()=>{r&&o.status==="connected"&&o.leaveRoom(e)}},[o.status,e]);const u=o.getRoomUsers(e),f=u.findIndex(p=>p.username===(s==null?void 0:s.username))!==-1;return{users:u,roomId:e,hasJoined:f,joinRoom:a,leaveRoom:l,reconnect:o.reconnect}}const lr={container:"container__LbyGQ",avatarWrapper:"avatarWrapper__HCQIZ",avatar:"avatar__E453a",overflowWrapper:"overflowWrapper__ETnPO",overflowBadge:"overflowBadge__igBKT"},B0={sm:24,md:32,lg:40},U0=({users:e,maxVisible:t=5,size:n="md",overlap:r=!0,className:o="",onUserClick:s})=>{const i=B0[n],a=S.useMemo(()=>e.slice(0,t),[e,t]),l=S.useMemo(()=>e.slice(t),[e,t]),u=Math.max(0,e.length-t),f=p=>p.split(" ").map(m=>m[0]).join("").toUpperCase().slice(0,2);return c.jsxs("div",{className:L(lr.container,o),children:[a.map((p,m)=>c.jsx(Pn,{tooltipContent:p.displayName,side:"bottom",children:c.jsx("div",{className:lr.avatarWrapper,style:{marginLeft:m>0&&r?`-${i*.25}px`:void 0},onClick:()=>s==null?void 0:s(p),children:c.jsx("div",{className:lr.avatar,style:{width:i,height:i,backgroundColor:p.color,fontSize:n==="sm"?"10px":n==="md"?"12px":"14px",cursor:s?"pointer":"default"},children:f(p.displayName)})})},p.username)),u>0&&c.jsx(Pn,{side:"bottom",tooltipContent:c.jsx("div",{children:l.map(p=>c.jsx("p",{children:p.displayName},p.username))}),children:c.jsx("div",{className:lr.overflowWrapper,style:{marginLeft:r?`-${i*.25}px`:void 0},children:c.jsxs("div",{className:lr.overflowBadge,style:{width:i,height:i,fontSize:n==="sm"?"10px":n==="md"?"12px":"14px"},children:["+",u]})})})]})};E.Alert=go,E.ApplicationIcon=Td,E.Authorized=yi,E.Badge=ns,E.Badges=rs,E.Button=Or,E.ClipboardCheckIcon=Ma,E.ClipboardIcon=Na,E.ConfirmDialog=Cu,E.CopyToClipboardButton=lh,E.DEFAULT_OPTIONS=Nd,E.Dialog=ye,E.DropdownList=ao,E.EmptyState=ri,E.ErrorState=Qs,E.ExtendExtensionPoint=E0,E.ExtensionPoint=_d,E.EyeIcon=Yc,E.FeatureFlagGuard=jd,E.FieldGroup=Fa,E.FragmentSlot=Id,E.Input=jr,E.InputError=Ua,E.Label=Ha,E.List=Je,E.ModulePlaceHolder=Ed,E.Pagination=Zs,E.PaginationContent=Xs,E.PaginationEllipsis=ti,E.PaginationItem=sr,E.PaginationLink=ir,E.PaginationNext=ei,E.PaginationPrevious=Js,E.PasswordInput=Lv,E.Pill=oy,E.PlatformEventListener=O0,E.PlatformEvents=lf,E.PluralizeCounter=ni,E.PortalContainerProvider=Bu,E.RoomAvatars=U0,E.RoomsProvider=$0,E.SearchAutocomplete=Wc,E.SearchInput=Vs,E.Select=ss,E.Select2=Pc,E.Show=St,E.Skeleton=co,E.SkeletonList=zc,E.Spinner=qc,E.Switch=Kc,E.Table=$u,E.Tabs=Ov,E.TabsContent=kv,E.TabsList=Iv,E.TabsTrigger=jv,E.TextArea=Ac,E.TextWithTooltip=Bc,E.ThemeToggle=Od,E.Tooltip=Pn,E.authorized=L0,E.dropdownListStyles=Xt,E.extensionPoint=P0,E.generateUserColor=Ld,E.getApplications=Lo,E.getInitials=Sf,E.getOperations=zi,E.hasAccess=qi,E.initializeMicroFrontend=yy,E.isPlatformCustomizationCompleted=s0,E.isValidEmail=Cf,E.logout=wf,E.navigateTo=_f,E.platformHaveAnyCustomization=o0,E.setupTestEnvironment=D0,E.useAppStatus=vi,E.useApplicationIcon=zu,E.useApplicationJSModule=vo,E.useApplicationMenu=Cy,E.useApplicationUIModule=Ji,E.useApplications=Zi,E.useAuth=Gn,E.useCatalog=pn,E.useCurrentApplication=ii,E.useCurrentApplicationName=Ku,E.useCurrentJSModule=Iy,E.useDynamicFonts=td,E.useDynamicStyleSheet=ed,E.useExtendExtensionPoint=Xu,E.useExtensionPoint=Zu,E.useFeatureFlag=N0,E.useFeatureFlags=wi,E.useFileStorage=S0,E.useGetPlatformTheme=r0,E.useHasNoSession=vf,E.useLocation=Bi,E.useModule=No,E.useModuleCommonPaths=bf,E.useModuleConfig=Do,E.useModuleConfigByName=Ki,E.useModuleMenu=Gu,E.useModuleMetadata=zn,E.useMutableCatalog=pf,E.useNotifications=pi,E.useOperations=Gi,E.usePAECustomizationsLoadingState=n0,E.usePAEState=fn,E.usePlatformCustomization=t0,E.usePlatformEventListener=Ju,E.usePortalContainer=py,E.useResource=i0,E.useResourceActions=hd,E.useRoom=F0,E.useServiceBaseURL=ai,E.useServiceInvoker=li,E.useServiceWebSocketURL=Qu,E.useTenants=b0,E.useTheme=Rd,E.useTrackEvent=My,E.useTrackEvents=Yu,E.useUIApplications=Xi,E.useUserState=_0,Object.defineProperty(E,Symbol.toStringTag,{value:"Module"})});
|