@bluealba/pae-ui-react-core 4.6.0-integration-css.403 → 4.6.0-integration-css.408
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 +42 -42
- package/dist/index.esm.js +2253 -2233
- package/dist/index.systemjs.js +40 -40
- package/dist/index.umd.js +40 -40
- package/dist/src/styles/moduleStyleLifecycle.d.ts +34 -0
- package/dist/src/utils/initializeMicroFrontend.d.ts +5 -0
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
globalThis.__PAE_UI_CORE_CSS__ = ".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)}@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{box-sizing:border-box;margin:0;font-family:inherit;line-height:inherit;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{box-sizing:border-box;width:100%;position:relative}.Select__giqpe select{box-sizing:border-box;margin:0;font-family:inherit;line-height:inherit;text-transform:none;-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{box-sizing:border-box;margin:0;font-family:inherit;line-height:inherit;text-transform:none;text-align:left;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{box-sizing:border-box;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{box-sizing:border-box;margin:0;font-family:inherit;font-size:1em;line-height:inherit;resize:vertical;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{box-sizing:border-box;margin:0;font-family:inherit;text-transform:none;-moz-appearance:none;appearance:none;-webkit-appearance:none;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{box-sizing:border-box;margin:0;-moz-appearance:none;appearance:none;-webkit-appearance:none;font-family:inherit;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{box-sizing:border-box;margin:0;font-family:inherit;text-transform:none;-moz-appearance:none;appearance:none;-webkit-appearance:none;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;text-indent:0;border-color:inherit;width:100%;min-width:max-content}.Table__2cIs3 td,.Table__2cIs3 th{box-sizing:border-box;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__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)}\n";
|
|
2
|
-
"use strict";var
|
|
2
|
+
"use strict";var Vi=e=>{throw TypeError(e)};var Do=(e,t,n)=>t.has(e)||Vi("Cannot "+n);var C=(e,t,n)=>(Do(e,t,"read from private field"),n?n.call(e):t.get(e)),M=(e,t,n)=>t.has(e)?Vi("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),O=(e,t,n,r)=>(Do(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),H=(e,t,n)=>(Do(e,t,"access private method"),n);var fr=(e,t,n,r)=>({set _(o){O(e,t,o,n)},get _(){return C(e,t,r)}});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E=require("react"),Nr=require("single-spa"),mc=require("react-dom");function gc(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=gc(E),io=gc(mc),qi=()=>typeof document<"u"&&"adoptedStyleSheets"in Document.prototype&&typeof CSSStyleSheet<"u"&&"replaceSync"in CSSStyleSheet.prototype;class xf{constructor(){this.styles=[],this.shadowRoots=new Set}register(t){const n={cssText:t,styleElements:new Map};if(this.styles.push(n),typeof document>"u")return()=>this.unregister(n);if(qi()){const r=new CSSStyleSheet;r.replaceSync(t),n.sheet=r,document.adoptedStyleSheets=[...document.adoptedStyleSheets,r],this.shadowRoots.forEach(o=>{o.adoptedStyleSheets=[...o.adoptedStyleSheets,r]})}else this.appendStyleElement(n,document),this.shadowRoots.forEach(r=>this.appendStyleElement(n,r));return()=>this.unregister(n)}adoptInto(t){if(!this.shadowRoots.has(t))if(this.shadowRoots.add(t),qi()){const n=this.styles.map(r=>r.sheet).filter(r=>!!r);t.adoptedStyleSheets=[...t.adoptedStyleSheets,...n]}else this.styles.forEach(n=>this.appendStyleElement(n,t))}releaseRoot(t){this.shadowRoots.delete(t)&&this.styles.forEach(n=>{var r;n.sheet&&(t.adoptedStyleSheets=t.adoptedStyleSheets.filter(o=>o!==n.sheet)),(r=n.styleElements.get(t))==null||r.remove(),n.styleElements.delete(t)})}unregister(t){const n=this.styles.indexOf(t);n!==-1&&(this.styles.splice(n,1),t.sheet&&(document.adoptedStyleSheets=document.adoptedStyleSheets.filter(r=>r!==t.sheet),this.shadowRoots.forEach(r=>{r.adoptedStyleSheets=r.adoptedStyleSheets.filter(o=>o!==t.sheet)})),t.styleElements.forEach(r=>r.remove()),t.styleElements.clear())}appendStyleElement(t,n){const r=document.createElement("style");r.setAttribute("data-pae-style-registry",""),r.textContent=t.cssText,(n instanceof Document?n.head:n).appendChild(r),t.styleElements.set(n,r)}}const ks=new xf,Sf=()=>{const e=globalThis.__PAE_UI_CORE_CSS__;e&&(ks.register(e),delete globalThis.__PAE_UI_CORE_CSS__)},Ef={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"}},Kn="__PAE_GLOBAL_STATE__",yc="__PAE_REACTIVE_GLOBAL_STATE__",vc="__PAE_EXTENSIONS_POINTS_REGISTRY__",Yo="__PAE_CUSTOMIZATIONS_LOADING_STATE_KEY__",_f="/auth/logout",Rf=(e,t)=>{const[n,r]=E.useState(t);return E.useEffect(()=>{const o=e.subscribe(s=>{r(s)});return()=>{o.unsubscribe()}},[r]),n},Tf=(e,t,n)=>n.map((r,o)=>o===e?t(r):r),Pf=(e,t,n)=>Tf(n.findIndex(e),t,n),Zo=(e,t)=>typeof e=="function"?e(t):e,bc=(e,t)=>{const n=Rf(e,t),r=E.useCallback(o=>{e.next(Zo(o,n))},[n]);return[n,r]},In=()=>bc(window[yc],window[Kn]),Nn=()=>In()[0].catalog,Af=()=>{const e=Nn(),t=E.useCallback(r=>{window[yc].next({...window[Kn],catalog:Zo(r,e)})},[e]),n=E.useCallback((r,o)=>{t(s=>Pf(i=>i.name===r,i=>{var a;return{...i,ui:{...i.ui,customProps:Zo(o,((a=i.ui)==null?void 0:a.customProps)??{})}}},s))},[t]);return[e,t,n]},wc=()=>{const[e,t]=E.useState(document.location.pathname);return E.useEffect(()=>{const n=()=>{t(window.location.pathname)};return window.addEventListener("popstate",n),()=>{window.removeEventListener("popstate",n)}},[t]),e};var Of=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function jf(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Cc={exports:{}},Bn={},zi;function If(){if(zi)return Bn;zi=1;/**
|
|
3
3
|
* @license React
|
|
4
4
|
* react-jsx-runtime.development.js
|
|
5
5
|
*
|
|
@@ -7,32 +7,32 @@ globalThis.__PAE_UI_CORE_CSS__ = ".container__zBqbk{display:flex;align-items:cen
|
|
|
7
7
|
*
|
|
8
8
|
* This source code is licensed under the MIT license found in the
|
|
9
9
|
* LICENSE file in the root directory of this source tree.
|
|
10
|
-
*/return function(){var e=E,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),g=Symbol.for("react.offscreen"),x=Symbol.iterator,p="@@iterator";function
|
|
11
|
-
`+k+b}}var de=!1,Y;{var ee=typeof WeakMap=="function"?WeakMap:Map;Y=new ee}function Z(b,A){if(!b||de)return"";{var j=Y.get(b);if(j!==void 0)return j}var F;de=!0;var te=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var se;se=De.current,De.current=null,Ve();try{if(A){var K=function(){throw Error()};if(Object.defineProperty(K.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(K,[])}catch(Se){F=Se}Reflect.construct(b,[],K)}else{try{K.call()}catch(Se){F=Se}b.call(K.prototype)}}else{try{throw Error()}catch(Se){F=Se}b()}}catch(Se){if(Se&&F&&typeof Se.stack=="string"){for(var
|
|
10
|
+
*/return function(){var e=E,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),g=Symbol.for("react.offscreen"),x=Symbol.iterator,p="@@iterator";function y(b){if(b===null||typeof b!="object")return null;var A=x&&b[x]||b[p];return typeof A=="function"?A:null}var v=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function w(b){{for(var A=arguments.length,j=new Array(A>1?A-1:0),F=1;F<A;F++)j[F-1]=arguments[F];S("error",b,j)}}function S(b,A,j){{var F=v.ReactDebugCurrentFrame,te=F.getStackAddendum();te!==""&&(A+="%s",j=j.concat([te]));var se=j.map(function(K){return String(K)});se.unshift("Warning: "+A),Function.prototype.apply.call(console[b],console,se)}}var _=!1,R=!1,T=!1,P=!1,D=!1,I;I=Symbol.for("react.module.reference");function L(b){return!!(typeof b=="string"||typeof b=="function"||b===r||b===s||D||b===o||b===l||b===f||P||b===g||_||R||T||typeof b=="object"&&b!==null&&(b.$$typeof===m||b.$$typeof===h||b.$$typeof===i||b.$$typeof===a||b.$$typeof===c||b.$$typeof===I||b.getModuleId!==void 0))}function B(b,A,j){var F=b.displayName;if(F)return F;var te=A.displayName||A.name||"";return te!==""?j+"("+te+")":j}function U(b){return b.displayName||"Context"}function W(b){if(b==null)return null;if(typeof b.tag=="number"&&w("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof b=="function")return b.displayName||b.name||null;if(typeof b=="string")return b;switch(b){case r:return"Fragment";case n:return"Portal";case s:return"Profiler";case o:return"StrictMode";case l:return"Suspense";case f:return"SuspenseList"}if(typeof b=="object")switch(b.$$typeof){case a:var A=b;return U(A)+".Consumer";case i:var j=b;return U(j._context)+".Provider";case c:return B(b,b.render,"ForwardRef");case h:var F=b.displayName||null;return F!==null?F:W(b.type)||"Memo";case m:{var te=b,se=te._payload,K=te._init;try{return W(K(se))}catch{return null}}}return null}var V=Object.assign,re=0,q,Q,$,oe,pe,Oe,pt;function mt(){}mt.__reactDisabledLog=!0;function Ve(){{if(re===0){q=console.log,Q=console.info,$=console.warn,oe=console.error,pe=console.group,Oe=console.groupCollapsed,pt=console.groupEnd;var b={configurable:!0,enumerable:!0,value:mt,writable:!0};Object.defineProperties(console,{info:b,log:b,warn:b,error:b,group:b,groupCollapsed:b,groupEnd:b})}re++}}function gt(){{if(re--,re===0){var b={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:V({},b,{value:q}),info:V({},b,{value:Q}),warn:V({},b,{value:$}),error:V({},b,{value:oe}),group:V({},b,{value:pe}),groupCollapsed:V({},b,{value:Oe}),groupEnd:V({},b,{value:pt})})}re<0&&w("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var De=v.ReactCurrentDispatcher,k;function J(b,A,j){{if(k===void 0)try{throw Error()}catch(te){var F=te.stack.trim().match(/\n( *(at )?)/);k=F&&F[1]||""}return`
|
|
11
|
+
`+k+b}}var de=!1,Y;{var ee=typeof WeakMap=="function"?WeakMap:Map;Y=new ee}function Z(b,A){if(!b||de)return"";{var j=Y.get(b);if(j!==void 0)return j}var F;de=!0;var te=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var se;se=De.current,De.current=null,Ve();try{if(A){var K=function(){throw Error()};if(Object.defineProperty(K.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(K,[])}catch(Se){F=Se}Reflect.construct(b,[],K)}else{try{K.call()}catch(Se){F=Se}b.call(K.prototype)}}else{try{throw Error()}catch(Se){F=Se}b()}}catch(Se){if(Se&&F&&typeof Se.stack=="string"){for(var z=Se.stack.split(`
|
|
12
12
|
`),be=F.stack.split(`
|
|
13
|
-
`),ue=
|
|
14
|
-
`+
|
|
13
|
+
`),ue=z.length-1,fe=be.length-1;ue>=1&&fe>=0&&z[ue]!==be[fe];)fe--;for(;ue>=1&&fe>=0;ue--,fe--)if(z[ue]!==be[fe]){if(ue!==1||fe!==1)do if(ue--,fe--,fe<0||z[ue]!==be[fe]){var Ie=`
|
|
14
|
+
`+z[ue].replace(" at new "," at ");return b.displayName&&Ie.includes("<anonymous>")&&(Ie=Ie.replace("<anonymous>",b.displayName)),typeof b=="function"&&Y.set(b,Ie),Ie}while(ue>=1&&fe>=0);break}}}finally{de=!1,De.current=se,gt(),Error.prepareStackTrace=te}var un=b?b.displayName||b.name:"",Bt=un?J(un):"";return typeof b=="function"&&Y.set(b,Bt),Bt}function ve(b,A,j){return Z(b,!1)}function je(b){var A=b.prototype;return!!(A&&A.isReactComponent)}function qe(b,A,j){if(b==null)return"";if(typeof b=="function")return Z(b,je(b));if(typeof b=="string")return J(b);switch(b){case l:return J("Suspense");case f:return J("SuspenseList")}if(typeof b=="object")switch(b.$$typeof){case c:return ve(b.render);case h:return qe(b.type,A,j);case m:{var F=b,te=F._payload,se=F._init;try{return qe(se(te),A,j)}catch{}}}return""}var Le=Object.prototype.hasOwnProperty,yt={},dr=v.ReactDebugCurrentFrame;function rt(b){if(b){var A=b._owner,j=qe(b.type,b._source,A?A.type:null);dr.setExtraStackFrame(j)}else dr.setExtraStackFrame(null)}function Jd(b,A,j,F,te){{var se=Function.call.bind(Le);for(var K in b)if(se(b,K)){var z=void 0;try{if(typeof b[K]!="function"){var be=Error((F||"React class")+": "+j+" type `"+K+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof b[K]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw be.name="Invariant Violation",be}z=b[K](A,K,F,j,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(ue){z=ue}z&&!(z instanceof Error)&&(rt(te),w("%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).",F||"React class",j,K,typeof z),rt(null)),z instanceof Error&&!(z.message in yt)&&(yt[z.message]=!0,rt(te),w("Failed %s type: %s",j,z.message),rt(null))}}}var ef=Array.isArray;function Ao(b){return ef(b)}function tf(b){{var A=typeof Symbol=="function"&&Symbol.toStringTag,j=A&&b[Symbol.toStringTag]||b.constructor.name||"Object";return j}}function nf(b){try{return Ii(b),!1}catch{return!0}}function Ii(b){return""+b}function Ni(b){if(nf(b))return w("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",tf(b)),Ii(b)}var Di=v.ReactCurrentOwner,rf={key:!0,ref:!0,__self:!0,__source:!0},Li,Mi;function of(b){if(Le.call(b,"ref")){var A=Object.getOwnPropertyDescriptor(b,"ref").get;if(A&&A.isReactWarning)return!1}return b.ref!==void 0}function sf(b){if(Le.call(b,"key")){var A=Object.getOwnPropertyDescriptor(b,"key").get;if(A&&A.isReactWarning)return!1}return b.key!==void 0}function af(b,A){typeof b.ref=="string"&&Di.current}function cf(b,A){{var j=function(){Li||(Li=!0,w("%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)",A))};j.isReactWarning=!0,Object.defineProperty(b,"key",{get:j,configurable:!0})}}function lf(b,A){{var j=function(){Mi||(Mi=!0,w("%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)",A))};j.isReactWarning=!0,Object.defineProperty(b,"ref",{get:j,configurable:!0})}}var uf=function(b,A,j,F,te,se,K){var z={$$typeof:t,type:b,key:A,ref:j,props:K,_owner:se};return z._store={},Object.defineProperty(z._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(z,"_self",{configurable:!1,enumerable:!1,writable:!1,value:F}),Object.defineProperty(z,"_source",{configurable:!1,enumerable:!1,writable:!1,value:te}),Object.freeze&&(Object.freeze(z.props),Object.freeze(z)),z};function df(b,A,j,F,te){{var se,K={},z=null,be=null;j!==void 0&&(Ni(j),z=""+j),sf(A)&&(Ni(A.key),z=""+A.key),of(A)&&(be=A.ref,af(A,te));for(se in A)Le.call(A,se)&&!rf.hasOwnProperty(se)&&(K[se]=A[se]);if(b&&b.defaultProps){var ue=b.defaultProps;for(se in ue)K[se]===void 0&&(K[se]=ue[se])}if(z||be){var fe=typeof b=="function"?b.displayName||b.name||"Unknown":b;z&&cf(K,fe),be&&lf(K,fe)}return uf(b,z,be,te,F,Di.current,K)}}var Oo=v.ReactCurrentOwner,ki=v.ReactDebugCurrentFrame;function ln(b){if(b){var A=b._owner,j=qe(b.type,b._source,A?A.type:null);ki.setExtraStackFrame(j)}else ki.setExtraStackFrame(null)}var jo;jo=!1;function Io(b){return typeof b=="object"&&b!==null&&b.$$typeof===t}function $i(){{if(Oo.current){var b=W(Oo.current.type);if(b)return`
|
|
15
15
|
|
|
16
|
-
Check the render method of \``+b+"`."}return""}}function
|
|
16
|
+
Check the render method of \``+b+"`."}return""}}function ff(b){return""}var Fi={};function hf(b){{var A=$i();if(!A){var j=typeof b=="string"?b:b.displayName||b.name;j&&(A=`
|
|
17
17
|
|
|
18
|
-
Check the top-level render call using <`+j+">.")}return A}}function
|
|
18
|
+
Check the top-level render call using <`+j+">.")}return A}}function Bi(b,A){{if(!b._store||b._store.validated||b.key!=null)return;b._store.validated=!0;var j=hf(A);if(Fi[j])return;Fi[j]=!0;var F="";b&&b._owner&&b._owner!==Oo.current&&(F=" It was passed a child from "+W(b._owner.type)+"."),ln(b),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,F),ln(null)}}function Ui(b,A){{if(typeof b!="object")return;if(Ao(b))for(var j=0;j<b.length;j++){var F=b[j];Io(F)&&Bi(F,A)}else if(Io(b))b._store&&(b._store.validated=!0);else if(b){var te=y(b);if(typeof te=="function"&&te!==b.entries)for(var se=te.call(b),K;!(K=se.next()).done;)Io(K.value)&&Bi(K.value,A)}}}function pf(b){{var A=b.type;if(A==null||typeof A=="string")return;var j;if(typeof A=="function")j=A.propTypes;else if(typeof A=="object"&&(A.$$typeof===c||A.$$typeof===h))j=A.propTypes;else return;if(j){var F=W(A);Jd(j,b.props,"prop",F,b)}else if(A.PropTypes!==void 0&&!jo){jo=!0;var te=W(A);w("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",te||"Unknown")}typeof A.getDefaultProps=="function"&&!A.getDefaultProps.isReactClassApproved&&w("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function mf(b){{for(var A=Object.keys(b.props),j=0;j<A.length;j++){var F=A[j];if(F!=="children"&&F!=="key"){ln(b),w("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",F),ln(null);break}}b.ref!==null&&(ln(b),w("Invalid attribute `ref` supplied to `React.Fragment`."),ln(null))}}var Wi={};function Hi(b,A,j,F,te,se){{var K=L(b);if(!K){var z="";(b===void 0||typeof b=="object"&&b!==null&&Object.keys(b).length===0)&&(z+=" 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 be=ff();be?z+=be:z+=$i();var ue;b===null?ue="null":Ao(b)?ue="array":b!==void 0&&b.$$typeof===t?(ue="<"+(W(b.type)||"Unknown")+" />",z=" Did you accidentally export a JSX literal instead of a component?"):ue=typeof b,w("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",ue,z)}var fe=df(b,A,j,te,se);if(fe==null)return fe;if(K){var Ie=A.children;if(Ie!==void 0)if(F)if(Ao(Ie)){for(var un=0;un<Ie.length;un++)Ui(Ie[un],b);Object.freeze&&Object.freeze(Ie)}else w("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 Ui(Ie,b)}if(Le.call(A,"key")){var Bt=W(b),Se=Object.keys(A).filter(function(Cf){return Cf!=="key"}),No=Se.length>0?"{key: someKey, "+Se.join(": ..., ")+": ...}":"{key: someKey}";if(!Wi[Bt+No]){var wf=Se.length>0?"{"+Se.join(": ..., ")+": ...}":"{}";w(`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} />`,
|
|
23
|
+
<%s key={someKey} {...props} />`,No,Bt,wf,Bt),Wi[Bt+No]=!0}}return b===r?mf(fe):pf(fe),fe}}function gf(b,A,j){return Hi(b,A,j,!0)}function yf(b,A,j){return Hi(b,A,j,!1)}var vf=yf,bf=gf;Bn.Fragment=r,Bn.jsx=vf,Bn.jsxs=bf}(),Bn}Cc.exports=If();var u=Cc.exports;const xc=E.createContext(null),Sc=({module:e,children:t})=>u.jsx(xc.Provider,{value:e,children:t});Sc.displayName="PAEModule";const rr=()=>{const e=E.useContext(xc);if(!e)throw new Error("Module metadata was not setup yet !!");return e};function $s(){if(!window[Kn])throw new Error("PAE Global state not found.");return window[Kn]}const Fs=()=>{const{authUser:{applications:e}}=$s();return e||[]},Ec=e=>Fs().filter(t=>t.name===e).flatMap(t=>t.operations),_c=()=>{const{application:e}=rr();return E.useMemo(()=>Ec(e),[e])},Rc=e=>(...t)=>t.every(n=>e.some(r=>r.name===n)),or=()=>{const[{authUser:e}]=In(),t=_c();return{authUser:e,hasAccess:E.useMemo(()=>Rc(t),[t])}},Nf=()=>{const{authUser:e}=or();return!e||e.id==="anon"},Tc=()=>{var e;return((e=rr().ui)==null?void 0:e.customProps)??{}},Bs=e=>{const t=Nn();return E.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])},Pc=e=>{var t,n;return((n=(t=Bs(e))==null?void 0:t.ui)==null?void 0:n.customProps)??{}},Df=e=>e.replace(/\/+/g,"/"),Lf=(e,t="only-base-path")=>{const{apiDocs:n,health:r,version:o,changelog:s}=(e==null?void 0:e.commonPaths)||{},i=(a,c="")=>{if(a===void 0&&!c)return;const l=a??c;if(t==="only-base-path")return l;const f=Df(`${e.baseUrl}/${l}`);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 Mf(){window.open(_f,"_self")}const kf=e=>Nr.navigateToUrl(e),$f=/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9-]+(\.[a-zA-Z0-9-]+)*\.[a-zA-Z]{2,}$/,Ff=e=>$f.test(e),Bf=(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)},Ac=e=>e.type==="app"||e.type==="tool",Uf=e=>e.modules.some(Ac)&&e.route&&e.route!=="/",Oc=e=>{const{catalog:t}=$s();return ao(t.filter(n=>n.application===e))},ao=(e=[])=>e.find(t=>{var n;return Ac(t)&&((n=t.ui)==null?void 0:n.route)!=="/"}),jc=()=>{const e=Nn();return E.useMemo(()=>Fs().map(n=>{var s,i,a;const r=Wf(e,n.name),o=ao(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])},Wf=(e,t)=>e.filter(n=>n.application===t)||[],Ic=()=>{const e=jc();return E.useMemo(()=>e.filter(Uf),[e])},Nc=e=>E.useMemo(()=>e?Oc(e.name):void 0,[e]),Nt=new Map,Hf=e=>{try{const{catalog:t}=$s(),n=t.find(r=>r.name===e);return n!=null&&n.version?`${e}@${n.version}`:e}catch{return e}},co=e=>{const[t,n]=E.useState(null);return E.useEffect(()=>{(async()=>{if(!e){n(null);return}try{const o=Hf(e);if(Nt.has(o)){const i=Nt.get(o);n(i);return}const s=await System.import(e);Nt.set(o,s),n(s)}catch(o){console.error(`Error importing module ${e}: ${o.message}`),n(null)}})()},[e,n]),t},Vf=e=>{e?(Array.from(Nt.keys()).filter(n=>n.startsWith(e)).forEach(n=>Nt.delete(n)),console.log(`[useApplicationJSModule] Cleared cache for module: ${e}`)):(Nt.clear(),console.log("[useApplicationJSModule] Cleared all module cache"))};typeof window<"u"&&(window.PAE={...window.PAE,clearModuleCache:Vf,getModuleCacheSize:()=>Nt.size,getModuleCacheKeys:()=>Array.from(Nt.keys())});const Dc=e=>{const t=typeof e=="string"?Oc(e):ao(e==null?void 0:e.modules),n=co(t==null?void 0:t.name);return n==null?void 0:n.icon},Lc=e=>{const t=ao(e==null?void 0:e.modules),n=co(t==null?void 0:t.name),[r,o]=E.useState(!1),[s,i]=E.useState({}),a=async()=>(typeof(n==null?void 0:n.menu)=="function"?await n.menu():n==null?void 0:n.menu)||[],c=async()=>{if(!(n!=null&&n.menu))return[];o(!0);const h=qf((e==null?void 0:e.operations)||[]),m=(await a()).map(g=>{const{operations:x,items:p,path:y}=g;if(x!=null&&x.length&&!h(x))return null;const v=(p||[]).filter(w=>{var S;return!((S=w==null?void 0:w.operations)!=null&&S.length)||h(w.operations)});return!v.length&&!y?null:{...g,items:v}}).filter(Boolean);return o(!1),m},l=async()=>{const h=await c();e&&i(m=>({...m,[e.name]:h}))};E.useEffect(()=>{l()},[n==null?void 0:n.menu]);const f=E.useMemo(()=>e?s[e.name]||[]:[],[s,e]);return{loading:r,menu:f}},qf=e=>t=>t.every(n=>e.some(r=>r.name===n)),zf=e=>Lc(e);function ae(e){return e!=null&&typeof e=="object"&&e["@@functional/placeholder"]===!0}function Ut(e){return function t(n){return arguments.length===0||ae(n)?t:e.apply(this,arguments)}}function wt(e){return function t(n,r){switch(arguments.length){case 0:return t;case 1:return ae(n)?t:Ut(function(o){return e(n,o)});default:return ae(n)&&ae(r)?t:ae(n)?Ut(function(o){return e(o,r)}):ae(r)?Ut(function(o){return e(n,o)}):e(n,r)}}}function Us(e){return function t(n,r,o){switch(arguments.length){case 0:return t;case 1:return ae(n)?t:wt(function(s,i){return e(n,s,i)});case 2:return ae(n)&&ae(r)?t:ae(n)?wt(function(s,i){return e(s,r,i)}):ae(r)?wt(function(s,i){return e(n,s,i)}):Ut(function(s){return e(n,r,s)});default:return ae(n)&&ae(r)&&ae(o)?t:ae(n)&&ae(r)?wt(function(s,i){return e(s,i,o)}):ae(n)&&ae(o)?wt(function(s,i){return e(s,r,i)}):ae(r)&&ae(o)?wt(function(s,i){return e(n,s,i)}):ae(n)?Ut(function(s){return e(s,r,o)}):ae(r)?Ut(function(s){return e(n,s,o)}):ae(o)?Ut(function(s){return e(n,r,s)}):e(n,r,o)}}}function hr(e,t){return Object.prototype.hasOwnProperty.call(t,e)}function Gi(e){return Object.prototype.toString.call(e)==="[object Object]"}var Gf=Us(function(t,n,r){var o=t(n),s=t(r);return o>s?-1:o<s?1:0}),Kf=Us(function(t,n,r){var o={},s;n=n||{},r=r||{};for(s in n)hr(s,n)&&(o[s]=hr(s,r)?t(s,n[s],r[s]):n[s]);for(s in r)hr(s,r)&&!hr(s,o)&&(o[s]=r[s]);return o}),Qf=Us(function e(t,n,r){return Kf(function(o,s,i){return Gi(s)&&Gi(i)?e(t,s,i):t(o,s,i)},n,r)}),Yf=wt(function(t,n){return Qf(function(r,o,s){return s},t,n)}),Zf=wt(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 Ws=()=>{const e=wc(),t=Ic();return E.useMemo(()=>Xf(e,t),[e,t])},Xf=(e,t)=>Zf([Gf(Jf)],t).find(n=>n.route&&e.startsWith(n.route)),Jf=e=>{var t;return((t=e==null?void 0:e.route)==null?void 0:t.length)||-1},Mc=()=>{var e;return(e=Ws())==null?void 0:e.name},eh=()=>{const e=Ws(),t=Nc(e);return co(t==null?void 0:t.name)},Hs=(e,t)=>{const r=Nn().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},Vs=(e,t)=>{const n=Hs(e,!!t)??t;return E.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(th(`${n}${r}`),{...o,headers:i})},[n])},th=e=>e.replace(/\/+/g,"/"),nh=["impersonate","impersonate-display-name","tenant"],kc=(e,t)=>{const n=Hs(e,t);return E.useMemo(()=>{if(!n)return null;try{const r=new URL(window.location.href),o=new URL(n,window.location.origin);return nh.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])},rh=(e,t)=>n=>({timestamp:new Date(new Date().toUTCString()).toISOString(),module:t.name,moduleVersion:t.version,application:t.application,user:e.username,...n}),oh=(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(rh(t,n)))});if(!o.ok)throw new Error(`Error publishing habits event ${o.statusText}`)},sh="@bluealba/pae-habits-service",$c=()=>{const{authUser:e}=or(),t=rr(),n=Vs(sh);return E.useCallback(oh(n,e,t),[n,e,t])},ih=()=>{const e=$c();return E.useCallback((t,n)=>e([{name:t,data:n}]),[e])},Fc=e=>{const t=rr(),n=window[vc],[r,o]=E.useState(null);return E.useEffect(()=>n.defineExtensionPoint(t,e,s=>{o(()=>s)}),[o]),r},Bc=(e,t,n)=>{E.useEffect(()=>window[vc].setExtensionPoint(e,t,n),[])},Uc=(e,t)=>{E.useEffect(()=>(window.addEventListener(e,t),()=>window.removeEventListener(e,t)),[e,t])},Wc=e=>{E.useEffect(()=>{if(!e)return;const t=e.includes("@layer")?e:`@layer pae.customization {
|
|
24
24
|
${e}
|
|
25
|
-
}`;return
|
|
25
|
+
}`;return ks.register(t)},[e])},ah=e=>{var t;return(t=e.split(/[#?]/)[0].split(".").pop())==null?void 0:t.trim()},ch={woff2:"woff2",woff:"woff",ttf:"truetype",otf:"opentype",eot:"embedded-opentype",svg:"svg"},lh=e=>{const t=ah(e);return t?ch[t]:void 0},uh=(e,t)=>{const n=t??lh(e);return n?`format(${n})`:""};function Hc(e){const[t,n]=E.useState(!1);return E.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:c,fontWeight:l,format:f})=>`
|
|
26
26
|
@font-face {
|
|
27
27
|
font-family: "${i}";
|
|
28
|
-
src: url("${c}") ${
|
|
28
|
+
src: url("${c}") ${uh(c,f)};
|
|
29
29
|
font-weight: ${l};
|
|
30
30
|
font-style: normal;
|
|
31
31
|
}
|
|
32
32
|
`)).join(`
|
|
33
|
-
`);return r.innerHTML=o,document.head.appendChild(r),(async()=>{try{await Promise.all(e.flatMap(({fontFamily:i,variants:a})=>a.map(({fontWeight:c})=>document.fonts.load(`normal ${c} 1em "${i}"`))))}finally{n(!0)}})(),()=>{document.head.removeChild(r)}},[e]),E.useEffect(()=>{!t&&!(e!=null&&e.length)&&n(!0)},[e,t]),{fontsLoaded:t}}var
|
|
33
|
+
`);return r.innerHTML=o,document.head.appendChild(r),(async()=>{try{await Promise.all(e.flatMap(({fontFamily:i,variants:a})=>a.map(({fontWeight:c})=>document.fonts.load(`normal ${c} 1em "${i}"`))))}finally{n(!0)}})(),()=>{document.head.removeChild(r)}},[e]),E.useEffect(()=>{!t&&!(e!=null&&e.length)&&n(!0)},[e,t]),{fontsLoaded:t}}var Xo=function(e,t){return Xo=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])},Xo(e,t)};function sr(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Xo(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 Vc(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 Jo(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 es(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 Hr(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))}function ct(e){return typeof e=="function"}function qc(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 Lo=qc(function(e){return function(n){e(this),this.message=n?n.length+` errors occurred during unsubscription:
|
|
34
34
|
`+n.map(function(r,o){return o+1+") "+r.toString()}).join(`
|
|
35
|
-
`):"",this.name="UnsubscriptionError",this.errors=n}});function es(e,t){if(e){var n=e.indexOf(t);0<=n&&e.splice(n,1)}}var co=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=Xo(i),c=a.next();!c.done;c=a.next()){var l=c.value;l.remove(this)}}catch(p){t={error:p}}finally{try{c&&!c.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}else i.remove(this);var f=this.initialTeardown;if(ct(f))try{f()}catch(p){s=p instanceof Do?p.errors:[p]}var h=this._finalizers;if(h){this._finalizers=null;try{for(var m=Xo(h),g=m.next();!g.done;g=m.next()){var x=g.value;try{Gi(x)}catch(p){s=s??[],p instanceof Do?s=Hr(Hr([],Jo(s)),Jo(p.errors)):s.push(p)}}}catch(p){r={error:p}}finally{try{g&&!g.done&&(o=m.return)&&o.call(m)}finally{if(r)throw r.error}}}if(s)throw new Do(s)}},e.prototype.add=function(t){var n;if(t&&t!==this)if(this.closed)Gi(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)&&es(n,t)},e.prototype.remove=function(t){var n=this._finalizers;n&&es(n,t),t instanceof e&&t._removeParent(this)},e.EMPTY=function(){var t=new e;return t.closed=!0,t}(),e}(),zc=co.EMPTY;function qc(e){return e instanceof co||e&&"closed"in e&&ct(e.remove)&&ct(e.add)&&ct(e.unsubscribe)}function Gi(e){ct(e)?e():e.unsubscribe()}var uh={Promise:void 0},dh={setTimeout:function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];return setTimeout.apply(void 0,Hr([e,t],Jo(n)))},clearTimeout:function(e){return clearTimeout(e)},delegate:void 0};function fh(e){dh.setTimeout(function(){throw e})}function Ki(){}function Dr(e){e()}var Gc=function(e){sr(t,e);function t(n){var r=e.call(this)||this;return r.isStopped=!1,n?(r.destination=n,qc(n)&&n.add(r)):r.destination=mh,r}return t.create=function(n,r,o){return new ts(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}(co),hh=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){pr(r)}},e.prototype.error=function(t){var n=this.partialObserver;if(n.error)try{n.error(t)}catch(r){pr(r)}else pr(t)},e.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(n){pr(n)}},e}(),ts=function(e){sr(t,e);function t(n,r,o){var s=e.call(this)||this,i;return ct(n)||!n?i={next:n??void 0,error:r??void 0,complete:o??void 0}:i=n,s.destination=new hh(i),s}return t}(Gc);function pr(e){fh(e)}function ph(e){throw e}var mh={closed:!0,next:Ki,error:ph,complete:Ki},gh=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function vh(e){return e}function yh(e){return e.length===0?vh:e.length===1?e[0]:function(n){return e.reduce(function(r,o){return o(r)},n)}}var Qi=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=wh(t)?t:new ts(t,n,r);return Dr(function(){var i=o,a=i.operator,c=i.source;s.add(a?a.call(s,c):c?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=Yi(n),new n(function(o,s){var i=new ts({next:function(a){try{t(a)}catch(c){s(c),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[gh]=function(){return this},e.prototype.pipe=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return yh(t)(this)},e.prototype.toPromise=function(t){var n=this;return t=Yi(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 Yi(e){var t;return(t=e??uh.Promise)!==null&&t!==void 0?t:Promise}function bh(e){return e&&ct(e.next)&&ct(e.error)&&ct(e.complete)}function wh(e){return e&&e instanceof Gc||bh(e)&&qc(e)}var Ch=Vc(function(e){return function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),Kc=function(e){sr(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 Zi(this,this);return r.operator=n,r},t.prototype._throwIfClosed=function(){if(this.closed)throw new Ch},t.prototype.next=function(n){var r=this;Dr(function(){var o,s;if(r._throwIfClosed(),!r.isStopped){r.currentObservers||(r.currentObservers=Array.from(r.observers));try{for(var i=Xo(r.currentObservers),a=i.next();!a.done;a=i.next()){var c=a.value;c.next(n)}}catch(l){o={error:l}}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;Dr(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;Dr(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?zc:(this.currentObservers=null,a.push(n),new co(function(){r.currentObservers=null,es(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 Qi;return n.source=this,n},t.create=function(n,r){return new Zi(n,r)},t}(Qi),Zi=function(e){sr(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:zc},t}(Kc),xh=function(e){sr(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}(Kc);const Sh=e=>{const{fontsLoaded:t}=Wc(e.fonts);Uc(e.styleSheet);const n=()=>{const r=new xh(!0);window[Qo]=r};E.useEffect(()=>{t&&window[Qo].next(!1)},[t]),E.useEffect(()=>{n()},[])},Eh=()=>{const e=window[Qo];return yc(e,e.getValue()??void 0)},ns="theme",Xi=()=>document.documentElement.dataset[ns]==="dark"?"dark":"light",_h=()=>{const[e,t]=E.useState(Xi());return E.useEffect(()=>{const n=document.documentElement,r=()=>t(Xi),o=new MutationObserver(s=>{for(const i of s)i.type==="attributes"&&i.attributeName===`data-${ns}`&&r()});return o.observe(n,{attributes:!0,attributeFilter:[`data-${ns}`]}),r(),()=>{o.disconnect()}},[]),e},Rh=e=>e!==void 0,Th=e=>e!==!0;let Ph={data:""},Ah=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||Ph},Oh=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,jh=/\/\*[^]*?\*\/| +/g,Ji=/\n+/g,Ct=(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"?Ct(i,s):s+"{"+Ct(i,s[1]=="k"?"":t)+"}":typeof i=="object"?r+=Ct(i,t?t.replace(/([^,])+/g,a=>s.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,c=>/&/.test(c)?c.replace(/&/g,a):a?a+" "+c:c)):s):i!=null&&(s=/^--/.test(s)?s:s.replace(/[A-Z]/g,"-$&").toLowerCase(),o+=Ct.p?Ct.p(s,i):s+":"+i+";")}return n+(t&&o?t+"{"+o+"}":o)+r},ot={},Qc=e=>{if(typeof e=="object"){let t="";for(let n in e)t+=n+Qc(e[n]);return t}return e},Ih=(e,t,n,r,o)=>{let s=Qc(e),i=ot[s]||(ot[s]=(c=>{let l=0,f=11;for(;l<c.length;)f=101*f+c.charCodeAt(l++)>>>0;return"go"+f})(s));if(!ot[i]){let c=s!==e?e:(l=>{let f,h,m=[{}];for(;f=Oh.exec(l.replace(jh,""));)f[4]?m.shift():f[3]?(h=f[3].replace(Ji," ").trim(),m.unshift(m[0][h]=m[0][h]||{})):m[0][f[1]]=f[2].replace(Ji," ").trim();return m[0]})(e);ot[i]=Ct(o?{["@keyframes "+i]:c}:c,n?"":"."+i)}let a=n&&ot.g?ot.g:null;return n&&(ot.g=ot[i]),((c,l,f,h)=>{h?l.data=l.data.replace(h,c):l.data.indexOf(c)===-1&&(l.data=f?c+l.data:l.data+c)})(ot[i],t,r,a),i},Nh=(e,t,n)=>e.reduce((r,o,s)=>{let i=t[s];if(i&&i.call){let a=i(n),c=a&&a.props&&a.props.className||/^go/.test(a)&&a;i=c?"."+c:a&&typeof a=="object"?a.props?"":Ct(a,""):a===!1?"":a}return r+o+(i??"")},"");function lo(e){let t=this||{},n=e.call?e(t.p):e;return Ih(n.unshift?n.raw?Nh(n,[].slice.call(arguments,1),t.p):n.reduce((r,o)=>Object.assign(r,o&&o.call?o(t.p):o),{}):n,Ah(t.target),t.g,t.o,t.k)}let Yc,rs,os;lo.bind({g:1});let ut=lo.bind({k:1});function Dh(e,t,n,r){Ct.p=t,Yc=e,rs=n,os=r}function kt(e,t){let n=this||{};return function(){let r=arguments;function o(s,i){let a=Object.assign({},s),c=a.className||o.className;n.p=Object.assign({theme:rs&&rs()},a),n.o=/ *go\d+/.test(c),a.className=lo.apply(n,r)+(c?" "+c:"");let l=e;return e[0]&&(l=a.as||e,delete a.as),os&&l[0]&&os(a),Yc(l,a)}return o}}var Lh=e=>typeof e=="function",Vr=(e,t)=>Lh(e)?e(t):e,Mh=(()=>{let e=0;return()=>(++e).toString()})(),Zc=(()=>{let e;return()=>{if(e===void 0&&typeof window<"u"){let t=matchMedia("(prefers-reduced-motion: reduce)");e=!t||t.matches}return e}})(),kh=20,Lr=new Map,$h=1e3,ea=e=>{if(Lr.has(e))return;let t=setTimeout(()=>{Lr.delete(e),an({type:4,toastId:e})},$h);Lr.set(e,t)},Fh=e=>{let t=Lr.get(e);t&&clearTimeout(t)},ss=(e,t)=>{switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,kh)};case 1:return t.toast.id&&Fh(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)?ss(e,{type:1,toast:n}):ss(e,{type:0,toast:n});case 3:let{toastId:r}=t;return r?ea(r):e.toasts.forEach(s=>{ea(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}))}}},Mr=[],kr={toasts:[],pausedAt:void 0},an=e=>{kr=ss(kr,e),Mr.forEach(t=>{t(kr)})},Bh={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},Uh=(e={})=>{let[t,n]=E.useState(kr);E.useEffect(()=>(Mr.push(n),()=>{let o=Mr.indexOf(n);o>-1&&Mr.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)||Bh[o.type],style:{...e.style,...(i=e[o.type])==null?void 0:i.style,...o.style}}});return{...t,toasts:r}},Wh=(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)||Mh()}),ir=e=>(t,n)=>{let r=Wh(t,e,n);return an({type:2,toast:r}),r.id},Pe=(e,t)=>ir("blank")(e,t);Pe.error=ir("error");Pe.success=ir("success");Pe.loading=ir("loading");Pe.custom=ir("custom");Pe.dismiss=e=>{an({type:3,toastId:e})};Pe.remove=e=>an({type:4,toastId:e});Pe.promise=(e,t,n)=>{let r=Pe.loading(t.loading,{...n,...n==null?void 0:n.loading});return e.then(o=>(Pe.success(Vr(t.success,o),{id:r,...n,...n==null?void 0:n.success}),o)).catch(o=>{Pe.error(Vr(t.error,o),{id:r,...n,...n==null?void 0:n.error})}),e};var Hh=(e,t)=>{an({type:1,toast:{id:e,height:t}})},Vh=()=>{an({type:5,time:Date.now()})},zh=e=>{let{toasts:t,pausedAt:n}=Uh(e);E.useEffect(()=>{if(n)return;let s=Date.now(),i=t.map(a=>{if(a.duration===1/0)return;let c=(a.duration||0)+a.pauseDuration-(s-a.createdAt);if(c<0){a.visible&&Pe.dismiss(a.id);return}return setTimeout(()=>Pe.dismiss(a.id),c)});return()=>{i.forEach(a=>a&&clearTimeout(a))}},[t,n]);let r=E.useCallback(()=>{n&&an({type:6,time:Date.now()})},[n]),o=E.useCallback((s,i)=>{let{reverseOrder:a=!1,gutter:c=8,defaultPosition:l}=i||{},f=t.filter(g=>(g.position||l)===(s.position||l)&&g.height),h=f.findIndex(g=>g.id===s.id),m=f.filter((g,x)=>x<h&&g.visible).length;return f.filter(g=>g.visible).slice(...a?[m+1]:[0,m]).reduce((g,x)=>g+(x.height||0)+c,0)},[t]);return{toasts:t,handlers:{updateHeight:Hh,startPause:Vh,endPause:r,calculateOffset:o}}},qh=ut`
|
|
35
|
+
`):"",this.name="UnsubscriptionError",this.errors=n}});function ts(e,t){if(e){var n=e.indexOf(t);0<=n&&e.splice(n,1)}}var lo=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=Jo(i),c=a.next();!c.done;c=a.next()){var l=c.value;l.remove(this)}}catch(p){t={error:p}}finally{try{c&&!c.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}else i.remove(this);var f=this.initialTeardown;if(ct(f))try{f()}catch(p){s=p instanceof Lo?p.errors:[p]}var h=this._finalizers;if(h){this._finalizers=null;try{for(var m=Jo(h),g=m.next();!g.done;g=m.next()){var x=g.value;try{Ki(x)}catch(p){s=s??[],p instanceof Lo?s=Hr(Hr([],es(s)),es(p.errors)):s.push(p)}}}catch(p){r={error:p}}finally{try{g&&!g.done&&(o=m.return)&&o.call(m)}finally{if(r)throw r.error}}}if(s)throw new Lo(s)}},e.prototype.add=function(t){var n;if(t&&t!==this)if(this.closed)Ki(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)&&ts(n,t)},e.prototype.remove=function(t){var n=this._finalizers;n&&ts(n,t),t instanceof e&&t._removeParent(this)},e.EMPTY=function(){var t=new e;return t.closed=!0,t}(),e}(),zc=lo.EMPTY;function Gc(e){return e instanceof lo||e&&"closed"in e&&ct(e.remove)&&ct(e.add)&&ct(e.unsubscribe)}function Ki(e){ct(e)?e():e.unsubscribe()}var dh={Promise:void 0},fh={setTimeout:function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];return setTimeout.apply(void 0,Hr([e,t],es(n)))},clearTimeout:function(e){return clearTimeout(e)},delegate:void 0};function hh(e){fh.setTimeout(function(){throw e})}function Qi(){}function Dr(e){e()}var Kc=function(e){sr(t,e);function t(n){var r=e.call(this)||this;return r.isStopped=!1,n?(r.destination=n,Gc(n)&&n.add(r)):r.destination=gh,r}return t.create=function(n,r,o){return new ns(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}(lo),ph=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){pr(r)}},e.prototype.error=function(t){var n=this.partialObserver;if(n.error)try{n.error(t)}catch(r){pr(r)}else pr(t)},e.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(n){pr(n)}},e}(),ns=function(e){sr(t,e);function t(n,r,o){var s=e.call(this)||this,i;return ct(n)||!n?i={next:n??void 0,error:r??void 0,complete:o??void 0}:i=n,s.destination=new ph(i),s}return t}(Kc);function pr(e){hh(e)}function mh(e){throw e}var gh={closed:!0,next:Qi,error:mh,complete:Qi},yh=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function vh(e){return e}function bh(e){return e.length===0?vh:e.length===1?e[0]:function(n){return e.reduce(function(r,o){return o(r)},n)}}var Yi=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=Ch(t)?t:new ns(t,n,r);return Dr(function(){var i=o,a=i.operator,c=i.source;s.add(a?a.call(s,c):c?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=Zi(n),new n(function(o,s){var i=new ns({next:function(a){try{t(a)}catch(c){s(c),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[yh]=function(){return this},e.prototype.pipe=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return bh(t)(this)},e.prototype.toPromise=function(t){var n=this;return t=Zi(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 Zi(e){var t;return(t=e??dh.Promise)!==null&&t!==void 0?t:Promise}function wh(e){return e&&ct(e.next)&&ct(e.error)&&ct(e.complete)}function Ch(e){return e&&e instanceof Kc||wh(e)&&Gc(e)}var xh=qc(function(e){return function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),Qc=function(e){sr(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 Xi(this,this);return r.operator=n,r},t.prototype._throwIfClosed=function(){if(this.closed)throw new xh},t.prototype.next=function(n){var r=this;Dr(function(){var o,s;if(r._throwIfClosed(),!r.isStopped){r.currentObservers||(r.currentObservers=Array.from(r.observers));try{for(var i=Jo(r.currentObservers),a=i.next();!a.done;a=i.next()){var c=a.value;c.next(n)}}catch(l){o={error:l}}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;Dr(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;Dr(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?zc:(this.currentObservers=null,a.push(n),new lo(function(){r.currentObservers=null,ts(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 Yi;return n.source=this,n},t.create=function(n,r){return new Xi(n,r)},t}(Yi),Xi=function(e){sr(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:zc},t}(Qc),Sh=function(e){sr(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}(Qc);const Eh=e=>{const{fontsLoaded:t}=Hc(e.fonts);Wc(e.styleSheet);const n=()=>{const r=new Sh(!0);window[Yo]=r};E.useEffect(()=>{t&&window[Yo].next(!1)},[t]),E.useEffect(()=>{n()},[])},_h=()=>{const e=window[Yo];return bc(e,e.getValue()??void 0)},rs="theme",Ji=()=>document.documentElement.dataset[rs]==="dark"?"dark":"light",Rh=()=>{const[e,t]=E.useState(Ji());return E.useEffect(()=>{const n=document.documentElement,r=()=>t(Ji),o=new MutationObserver(s=>{for(const i of s)i.type==="attributes"&&i.attributeName===`data-${rs}`&&r()});return o.observe(n,{attributes:!0,attributeFilter:[`data-${rs}`]}),r(),()=>{o.disconnect()}},[]),e},Th=e=>e!==void 0,Ph=e=>e!==!0;let Ah={data:""},Oh=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||Ah},jh=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,Ih=/\/\*[^]*?\*\/| +/g,ea=/\n+/g,Ct=(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"?Ct(i,s):s+"{"+Ct(i,s[1]=="k"?"":t)+"}":typeof i=="object"?r+=Ct(i,t?t.replace(/([^,])+/g,a=>s.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,c=>/&/.test(c)?c.replace(/&/g,a):a?a+" "+c:c)):s):i!=null&&(s=/^--/.test(s)?s:s.replace(/[A-Z]/g,"-$&").toLowerCase(),o+=Ct.p?Ct.p(s,i):s+":"+i+";")}return n+(t&&o?t+"{"+o+"}":o)+r},ot={},Yc=e=>{if(typeof e=="object"){let t="";for(let n in e)t+=n+Yc(e[n]);return t}return e},Nh=(e,t,n,r,o)=>{let s=Yc(e),i=ot[s]||(ot[s]=(c=>{let l=0,f=11;for(;l<c.length;)f=101*f+c.charCodeAt(l++)>>>0;return"go"+f})(s));if(!ot[i]){let c=s!==e?e:(l=>{let f,h,m=[{}];for(;f=jh.exec(l.replace(Ih,""));)f[4]?m.shift():f[3]?(h=f[3].replace(ea," ").trim(),m.unshift(m[0][h]=m[0][h]||{})):m[0][f[1]]=f[2].replace(ea," ").trim();return m[0]})(e);ot[i]=Ct(o?{["@keyframes "+i]:c}:c,n?"":"."+i)}let a=n&&ot.g?ot.g:null;return n&&(ot.g=ot[i]),((c,l,f,h)=>{h?l.data=l.data.replace(h,c):l.data.indexOf(c)===-1&&(l.data=f?c+l.data:l.data+c)})(ot[i],t,r,a),i},Dh=(e,t,n)=>e.reduce((r,o,s)=>{let i=t[s];if(i&&i.call){let a=i(n),c=a&&a.props&&a.props.className||/^go/.test(a)&&a;i=c?"."+c:a&&typeof a=="object"?a.props?"":Ct(a,""):a===!1?"":a}return r+o+(i??"")},"");function uo(e){let t=this||{},n=e.call?e(t.p):e;return Nh(n.unshift?n.raw?Dh(n,[].slice.call(arguments,1),t.p):n.reduce((r,o)=>Object.assign(r,o&&o.call?o(t.p):o),{}):n,Oh(t.target),t.g,t.o,t.k)}let Zc,os,ss;uo.bind({g:1});let ut=uo.bind({k:1});function Lh(e,t,n,r){Ct.p=t,Zc=e,os=n,ss=r}function kt(e,t){let n=this||{};return function(){let r=arguments;function o(s,i){let a=Object.assign({},s),c=a.className||o.className;n.p=Object.assign({theme:os&&os()},a),n.o=/ *go\d+/.test(c),a.className=uo.apply(n,r)+(c?" "+c:"");let l=e;return e[0]&&(l=a.as||e,delete a.as),ss&&l[0]&&ss(a),Zc(l,a)}return o}}var Mh=e=>typeof e=="function",Vr=(e,t)=>Mh(e)?e(t):e,kh=(()=>{let e=0;return()=>(++e).toString()})(),Xc=(()=>{let e;return()=>{if(e===void 0&&typeof window<"u"){let t=matchMedia("(prefers-reduced-motion: reduce)");e=!t||t.matches}return e}})(),$h=20,Lr=new Map,Fh=1e3,ta=e=>{if(Lr.has(e))return;let t=setTimeout(()=>{Lr.delete(e),an({type:4,toastId:e})},Fh);Lr.set(e,t)},Bh=e=>{let t=Lr.get(e);t&&clearTimeout(t)},is=(e,t)=>{switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,$h)};case 1:return t.toast.id&&Bh(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)?is(e,{type:1,toast:n}):is(e,{type:0,toast:n});case 3:let{toastId:r}=t;return r?ta(r):e.toasts.forEach(s=>{ta(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}))}}},Mr=[],kr={toasts:[],pausedAt:void 0},an=e=>{kr=is(kr,e),Mr.forEach(t=>{t(kr)})},Uh={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},Wh=(e={})=>{let[t,n]=E.useState(kr);E.useEffect(()=>(Mr.push(n),()=>{let o=Mr.indexOf(n);o>-1&&Mr.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)||Uh[o.type],style:{...e.style,...(i=e[o.type])==null?void 0:i.style,...o.style}}});return{...t,toasts:r}},Hh=(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)||kh()}),ir=e=>(t,n)=>{let r=Hh(t,e,n);return an({type:2,toast:r}),r.id},Pe=(e,t)=>ir("blank")(e,t);Pe.error=ir("error");Pe.success=ir("success");Pe.loading=ir("loading");Pe.custom=ir("custom");Pe.dismiss=e=>{an({type:3,toastId:e})};Pe.remove=e=>an({type:4,toastId:e});Pe.promise=(e,t,n)=>{let r=Pe.loading(t.loading,{...n,...n==null?void 0:n.loading});return e.then(o=>(Pe.success(Vr(t.success,o),{id:r,...n,...n==null?void 0:n.success}),o)).catch(o=>{Pe.error(Vr(t.error,o),{id:r,...n,...n==null?void 0:n.error})}),e};var Vh=(e,t)=>{an({type:1,toast:{id:e,height:t}})},qh=()=>{an({type:5,time:Date.now()})},zh=e=>{let{toasts:t,pausedAt:n}=Wh(e);E.useEffect(()=>{if(n)return;let s=Date.now(),i=t.map(a=>{if(a.duration===1/0)return;let c=(a.duration||0)+a.pauseDuration-(s-a.createdAt);if(c<0){a.visible&&Pe.dismiss(a.id);return}return setTimeout(()=>Pe.dismiss(a.id),c)});return()=>{i.forEach(a=>a&&clearTimeout(a))}},[t,n]);let r=E.useCallback(()=>{n&&an({type:6,time:Date.now()})},[n]),o=E.useCallback((s,i)=>{let{reverseOrder:a=!1,gutter:c=8,defaultPosition:l}=i||{},f=t.filter(g=>(g.position||l)===(s.position||l)&&g.height),h=f.findIndex(g=>g.id===s.id),m=f.filter((g,x)=>x<h&&g.visible).length;return f.filter(g=>g.visible).slice(...a?[m+1]:[0,m]).reduce((g,x)=>g+(x.height||0)+c,0)},[t]);return{toasts:t,handlers:{updateHeight:Vh,startPause:qh,endPause:r,calculateOffset:o}}},Gh=ut`
|
|
36
36
|
from {
|
|
37
37
|
transform: scale(0) rotate(45deg);
|
|
38
38
|
opacity: 0;
|
|
@@ -40,7 +40,7 @@ from {
|
|
|
40
40
|
to {
|
|
41
41
|
transform: scale(1) rotate(45deg);
|
|
42
42
|
opacity: 1;
|
|
43
|
-
}`,
|
|
43
|
+
}`,Kh=ut`
|
|
44
44
|
from {
|
|
45
45
|
transform: scale(0);
|
|
46
46
|
opacity: 0;
|
|
@@ -48,7 +48,7 @@ from {
|
|
|
48
48
|
to {
|
|
49
49
|
transform: scale(1);
|
|
50
50
|
opacity: 1;
|
|
51
|
-
}`,
|
|
51
|
+
}`,Qh=ut`
|
|
52
52
|
from {
|
|
53
53
|
transform: scale(0) rotate(90deg);
|
|
54
54
|
opacity: 0;
|
|
@@ -56,7 +56,7 @@ from {
|
|
|
56
56
|
to {
|
|
57
57
|
transform: scale(1) rotate(90deg);
|
|
58
58
|
opacity: 1;
|
|
59
|
-
}`,
|
|
59
|
+
}`,Yh=kt("div")`
|
|
60
60
|
width: 20px;
|
|
61
61
|
opacity: 0;
|
|
62
62
|
height: 20px;
|
|
@@ -65,14 +65,14 @@ to {
|
|
|
65
65
|
position: relative;
|
|
66
66
|
transform: rotate(45deg);
|
|
67
67
|
|
|
68
|
-
animation: ${
|
|
68
|
+
animation: ${Gh} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
|
|
69
69
|
forwards;
|
|
70
70
|
animation-delay: 100ms;
|
|
71
71
|
|
|
72
72
|
&:after,
|
|
73
73
|
&:before {
|
|
74
74
|
content: '';
|
|
75
|
-
animation: ${
|
|
75
|
+
animation: ${Kh} 0.15s ease-out forwards;
|
|
76
76
|
animation-delay: 150ms;
|
|
77
77
|
position: absolute;
|
|
78
78
|
border-radius: 3px;
|
|
@@ -85,18 +85,18 @@ to {
|
|
|
85
85
|
}
|
|
86
86
|
|
|
87
87
|
&:before {
|
|
88
|
-
animation: ${
|
|
88
|
+
animation: ${Qh} 0.15s ease-out forwards;
|
|
89
89
|
animation-delay: 180ms;
|
|
90
90
|
transform: rotate(90deg);
|
|
91
91
|
}
|
|
92
|
-
`,
|
|
92
|
+
`,Zh=ut`
|
|
93
93
|
from {
|
|
94
94
|
transform: rotate(0deg);
|
|
95
95
|
}
|
|
96
96
|
to {
|
|
97
97
|
transform: rotate(360deg);
|
|
98
98
|
}
|
|
99
|
-
`,
|
|
99
|
+
`,Xh=kt("div")`
|
|
100
100
|
width: 12px;
|
|
101
101
|
height: 12px;
|
|
102
102
|
box-sizing: border-box;
|
|
@@ -104,8 +104,8 @@ to {
|
|
|
104
104
|
border-radius: 100%;
|
|
105
105
|
border-color: ${e=>e.secondary||"#e0e0e0"};
|
|
106
106
|
border-right-color: ${e=>e.primary||"#616161"};
|
|
107
|
-
animation: ${
|
|
108
|
-
`,
|
|
107
|
+
animation: ${Zh} 1s linear infinite;
|
|
108
|
+
`,Jh=ut`
|
|
109
109
|
from {
|
|
110
110
|
transform: scale(0) rotate(45deg);
|
|
111
111
|
opacity: 0;
|
|
@@ -113,7 +113,7 @@ from {
|
|
|
113
113
|
to {
|
|
114
114
|
transform: scale(1) rotate(45deg);
|
|
115
115
|
opacity: 1;
|
|
116
|
-
}`,
|
|
116
|
+
}`,ep=ut`
|
|
117
117
|
0% {
|
|
118
118
|
height: 0;
|
|
119
119
|
width: 0;
|
|
@@ -127,7 +127,7 @@ to {
|
|
|
127
127
|
100% {
|
|
128
128
|
opacity: 1;
|
|
129
129
|
height: 10px;
|
|
130
|
-
}`,
|
|
130
|
+
}`,tp=kt("div")`
|
|
131
131
|
width: 20px;
|
|
132
132
|
opacity: 0;
|
|
133
133
|
height: 20px;
|
|
@@ -136,13 +136,13 @@ to {
|
|
|
136
136
|
position: relative;
|
|
137
137
|
transform: rotate(45deg);
|
|
138
138
|
|
|
139
|
-
animation: ${
|
|
139
|
+
animation: ${Jh} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
|
|
140
140
|
forwards;
|
|
141
141
|
animation-delay: 100ms;
|
|
142
142
|
&:after {
|
|
143
143
|
content: '';
|
|
144
144
|
box-sizing: border-box;
|
|
145
|
-
animation: ${
|
|
145
|
+
animation: ${ep} 0.2s ease-out forwards;
|
|
146
146
|
opacity: 0;
|
|
147
147
|
animation-delay: 200ms;
|
|
148
148
|
position: absolute;
|
|
@@ -154,16 +154,16 @@ to {
|
|
|
154
154
|
height: 10px;
|
|
155
155
|
width: 6px;
|
|
156
156
|
}
|
|
157
|
-
`,tp=kt("div")`
|
|
158
|
-
position: absolute;
|
|
159
157
|
`,np=kt("div")`
|
|
158
|
+
position: absolute;
|
|
159
|
+
`,rp=kt("div")`
|
|
160
160
|
position: relative;
|
|
161
161
|
display: flex;
|
|
162
162
|
justify-content: center;
|
|
163
163
|
align-items: center;
|
|
164
164
|
min-width: 20px;
|
|
165
165
|
min-height: 20px;
|
|
166
|
-
`,
|
|
166
|
+
`,op=ut`
|
|
167
167
|
from {
|
|
168
168
|
transform: scale(0.6);
|
|
169
169
|
opacity: 0.4;
|
|
@@ -171,20 +171,20 @@ from {
|
|
|
171
171
|
to {
|
|
172
172
|
transform: scale(1);
|
|
173
173
|
opacity: 1;
|
|
174
|
-
}`,
|
|
174
|
+
}`,sp=kt("div")`
|
|
175
175
|
position: relative;
|
|
176
176
|
transform: scale(0.6);
|
|
177
177
|
opacity: 0.4;
|
|
178
178
|
min-width: 20px;
|
|
179
|
-
animation: ${
|
|
179
|
+
animation: ${op} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275)
|
|
180
180
|
forwards;
|
|
181
|
-
`,
|
|
181
|
+
`,ip=({toast:e})=>{let{icon:t,type:n,iconTheme:r}=e;return t!==void 0?typeof t=="string"?d.createElement(sp,null,t):t:n==="blank"?null:d.createElement(rp,null,d.createElement(Xh,{...r}),n!=="loading"&&d.createElement(np,null,n==="error"?d.createElement(Yh,{...r}):d.createElement(tp,{...r})))},ap=e=>`
|
|
182
182
|
0% {transform: translate3d(0,${e*-200}%,0) scale(.6); opacity:.5;}
|
|
183
183
|
100% {transform: translate3d(0,0,0) scale(1); opacity:1;}
|
|
184
|
-
`,
|
|
184
|
+
`,cp=e=>`
|
|
185
185
|
0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}
|
|
186
186
|
100% {transform: translate3d(0,${e*-150}%,-1px) scale(.6); opacity:0;}
|
|
187
|
-
`,
|
|
187
|
+
`,lp="0%{opacity:0;} 100%{opacity:1;}",up="0%{opacity:1;} 100%{opacity:0;}",dp=kt("div")`
|
|
188
188
|
display: flex;
|
|
189
189
|
align-items: center;
|
|
190
190
|
background: #fff;
|
|
@@ -196,20 +196,20 @@ to {
|
|
|
196
196
|
pointer-events: auto;
|
|
197
197
|
padding: 8px 10px;
|
|
198
198
|
border-radius: 8px;
|
|
199
|
-
`,
|
|
199
|
+
`,fp=kt("div")`
|
|
200
200
|
display: flex;
|
|
201
201
|
justify-content: center;
|
|
202
202
|
margin: 4px 10px;
|
|
203
203
|
color: inherit;
|
|
204
204
|
flex: 1 1 auto;
|
|
205
205
|
white-space: pre-line;
|
|
206
|
-
`,
|
|
206
|
+
`,hp=(e,t)=>{let n=e.includes("top")?1:-1,[r,o]=Xc()?[lp,up]:[ap(n),cp(n)];return{animation:t?`${ut(r)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${ut(o)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}},pp=d.memo(({toast:e,position:t,style:n,children:r})=>{let o=e.height?hp(e.position||t||"top-center",e.visible):{opacity:0},s=d.createElement(ip,{toast:e}),i=d.createElement(fp,{...e.ariaProps},Vr(e.message,e));return d.createElement(dp,{className:e.className,style:{...o,...n,...e.style}},typeof r=="function"?r({icon:s,message:i}):d.createElement(d.Fragment,null,s,i))});Lh(d.createElement);var mp=({id:e,className:t,style:n,onHeightUpdate:r,children:o})=>{let s=d.useCallback(i=>{if(i){let a=()=>{let c=i.getBoundingClientRect().height;r(e,c)};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)},gp=(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:Xc()?void 0:"all 230ms cubic-bezier(.21,1.02,.73,1)",transform:`translateY(${t*(n?1:-1)}px)`,...r,...o}},yp=uo`
|
|
207
207
|
z-index: 9999;
|
|
208
208
|
> * {
|
|
209
209
|
pointer-events: auto;
|
|
210
210
|
}
|
|
211
|
-
`,mr=16,vp=({reverseOrder:e,position:t="top-center",toastOptions:n,gutter:r,children:o,containerStyle:s,containerClassName:i})=>{let{toasts:a,handlers:c}=zh(n);return d.createElement("div",{style:{position:"fixed",zIndex:9999,top:mr,left:mr,right:mr,bottom:mr,pointerEvents:"none",...s},className:i,onMouseEnter:c.startPause,onMouseLeave:c.endPause},a.map(l=>{let f=l.position||t,h=c.calculateOffset(l,{reverseOrder:e,gutter:r,defaultPosition:t}),m=mp(f,h);return d.createElement(pp,{id:l.id,key:l.id,onHeightUpdate:c.updateHeight,className:l.visible?gp:"",style:m},l.type==="custom"?Vr(l.message,l):o?o(l):d.createElement(hp,{toast:l,position:f}))}))},ta=Pe;const Vs=()=>({notify:E.useCallback((t,n,r)=>{const o={style:{background:"var(--platform-background-primary-color)",color:"var(--platform-text-primary-color)"}};n==="warning"||n==="info"?ta(t,{...o,icon:n==="warning"?"⚠️":"ℹ️"}):ta[n](t,o),r&&console.error(r)},[])});var Dn=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(){}},Jt=typeof window>"u"||"Deno"in globalThis;function xe(){}function yp(e,t){return typeof e=="function"?e(t):e}function is(e){return typeof e=="number"&&e>=0&&e!==1/0}function Xc(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Dt(e,t){return typeof e=="function"?e(t):e}function Fe(e,t){return typeof e=="function"?e(t):e}function na(e,t){const{type:n="all",exact:r,fetchStatus:o,predicate:s,queryKey:i,stale:a}=e;if(i){if(r){if(t.queryHash!==zs(i,t.options))return!1}else if(!Qn(t.queryKey,i))return!1}if(n!=="all"){const c=t.isActive();if(n==="active"&&!c||n==="inactive"&&c)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||o&&o!==t.state.fetchStatus||s&&!s(t))}function ra(e,t){const{exact:n,status:r,predicate:o,mutationKey:s}=e;if(s){if(!t.options.mutationKey)return!1;if(n){if(en(t.options.mutationKey)!==en(s))return!1}else if(!Qn(t.options.mutationKey,s))return!1}return!(r&&t.state.status!==r||o&&!o(t))}function zs(e,t){return((t==null?void 0:t.queryKeyHashFn)||en)(e)}function en(e){return JSON.stringify(e,(t,n)=>cs(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 as(e,t){if(e===t)return e;const n=oa(e)&&oa(t);if(n||cs(e)&&cs(t)){const r=n?e:Object.keys(e),o=r.length,s=n?t:Object.keys(t),i=s.length,a=n?[]:{};let c=0;for(let l=0;l<i;l++){const f=n?l:s[l];(!n&&r.includes(f)||n)&&e[f]===void 0&&t[f]===void 0?(a[f]=void 0,c++):(a[f]=as(e[f],t[f]),a[f]===e[f]&&e[f]!==void 0&&c++)}return o===i&&c===o?e:a}return t}function zr(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 oa(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function cs(e){if(!sa(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!sa(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function sa(e){return Object.prototype.toString.call(e)==="[object Object]"}function bp(e){return new Promise(t=>{setTimeout(t,e)})}function ls(e,t,n){if(typeof n.structuralSharing=="function")return n.structuralSharing(e,t);if(n.structuralSharing!==!1){try{return as(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 as(e,t)}return t}function wp(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function Cp(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var qr=Symbol();function Jc(e,t){return e.queryFn===qr&&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===qr?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function el(e,t){return typeof e=="function"?e(...t):!!e}var Ht,xt,gn,oc,xp=(oc=class extends Dn{constructor(){super();M(this,Ht);M(this,xt);M(this,gn);O(this,gn,t=>{if(!Jt&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){C(this,xt)||this.setEventListener(C(this,gn))}onUnsubscribe(){var t;this.hasListeners()||((t=C(this,xt))==null||t.call(this),O(this,xt,void 0))}setEventListener(t){var n;O(this,gn,t),(n=C(this,xt))==null||n.call(this),O(this,xt,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){C(this,Ht)!==t&&(O(this,Ht,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof C(this,Ht)=="boolean"?C(this,Ht):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},Ht=new WeakMap,xt=new WeakMap,gn=new WeakMap,oc),qs=new xp,vn,St,yn,sc,Sp=(sc=class extends Dn{constructor(){super();M(this,vn,!0);M(this,St);M(this,yn);O(this,yn,t=>{if(!Jt&&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(){C(this,St)||this.setEventListener(C(this,yn))}onUnsubscribe(){var t;this.hasListeners()||((t=C(this,St))==null||t.call(this),O(this,St,void 0))}setEventListener(t){var n;O(this,yn,t),(n=C(this,St))==null||n.call(this),O(this,St,t(this.setOnline.bind(this)))}setOnline(t){C(this,vn)!==t&&(O(this,vn,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return C(this,vn)}},vn=new WeakMap,St=new WeakMap,yn=new WeakMap,sc),Gr=new Sp;function us(){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 Ep(e){return Math.min(1e3*2**e,3e4)}function tl(e){return(e??"online")==="online"?Gr.isOnline():!0}var nl=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Lo(e){return e instanceof nl}function rl(e){let t=!1,n=0,r=!1,o;const s=us(),i=p=>{var v;r||(m(new nl(p)),(v=e.abort)==null||v.call(e))},a=()=>{t=!0},c=()=>{t=!1},l=()=>qs.isFocused()&&(e.networkMode==="always"||Gr.isOnline())&&e.canRun(),f=()=>tl(e.networkMode)&&e.canRun(),h=p=>{var v;r||(r=!0,(v=e.onSuccess)==null||v.call(e,p),o==null||o(),s.resolve(p))},m=p=>{var v;r||(r=!0,(v=e.onError)==null||v.call(e,p),o==null||o(),s.reject(p))},g=()=>new Promise(p=>{var v;o=y=>{(r||l())&&p(y)},(v=e.onPause)==null||v.call(e)}).then(()=>{var p;o=void 0,r||(p=e.onContinue)==null||p.call(e)}),x=()=>{if(r)return;let p;const v=n===0?e.initialPromise:void 0;try{p=v??e.fn()}catch(y){p=Promise.reject(y)}Promise.resolve(p).then(h).catch(y=>{var T;if(r)return;const w=e.retry??(Jt?0:3),S=e.retryDelay??Ep,_=typeof S=="function"?S(n,y):S,R=w===!0||typeof w=="number"&&n<w||typeof w=="function"&&w(n,y);if(t||!R){m(y);return}n++,(T=e.onFail)==null||T.call(e,n,y),bp(_).then(()=>l()?void 0:g()).then(()=>{t?m(y):x()})})};return{promise:s,cancel:i,continue:()=>(o==null||o(),s),cancelRetry:a,continueRetry:c,canStart:f,start:()=>(f()?x():g().then(x),s)}}var _p=e=>setTimeout(e,0);function Rp(){let e=[],t=0,n=a=>{a()},r=a=>{a()},o=_p;const s=a=>{t?e.push(a):o(()=>{n(a)})},i=()=>{const a=e;e=[],a.length&&o(()=>{r(()=>{a.forEach(c=>{n(c)})})})};return{batch:a=>{let c;t++;try{c=a()}finally{t--,t||i()}return c},batchCalls:a=>(...c)=>{s(()=>{a(...c)})},schedule:s,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{o=a}}}var he=Rp(),Vt,ic,ol=(ic=class{constructor(){M(this,Vt)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),is(this.gcTime)&&O(this,Vt,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Jt?1/0:5*60*1e3))}clearGcTimeout(){C(this,Vt)&&(clearTimeout(C(this,Vt)),O(this,Vt,void 0))}},Vt=new WeakMap,ic),bn,wn,Ne,zt,me,Jn,qt,ke,st,ac,Tp=(ac=class extends ol{constructor(t){super();M(this,ke);M(this,bn);M(this,wn);M(this,Ne);M(this,zt);M(this,me);M(this,Jn);M(this,qt);O(this,qt,!1),O(this,Jn,t.defaultOptions),this.setOptions(t.options),this.observers=[],O(this,zt,t.client),O(this,Ne,C(this,zt).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,O(this,bn,Pp(this.options)),this.state=t.state??C(this,bn),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=C(this,me))==null?void 0:t.promise}setOptions(t){this.options={...C(this,Jn),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&C(this,Ne).remove(this)}setData(t,n){const r=ls(this.state.data,t,this.options);return H(this,ke,st).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){H(this,ke,st).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,o;const n=(r=C(this,me))==null?void 0:r.promise;return(o=C(this,me))==null||o.cancel(t),n?n.then(xe).catch(xe):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(C(this,bn))}isActive(){return this.observers.some(t=>Fe(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===qr||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Dt(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:!Xc(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=C(this,me))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=C(this,me))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),C(this,Ne).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(C(this,me)&&(C(this,qt)?C(this,me).cancel({revert:!0}):C(this,me).cancelRetry()),this.scheduleGc()),C(this,Ne).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||H(this,ke,st).call(this,{type:"invalidate"})}fetch(t,n){var l,f,h;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(C(this,me))return C(this,me).continueRetry(),C(this,me).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:()=>(O(this,qt,!0),r.signal)})},s=()=>{const m=Jc(this.options,n),x=(()=>{const p={client:C(this,zt),queryKey:this.queryKey,meta:this.meta};return o(p),p})();return O(this,qt,!1),this.options.persister?this.options.persister(m,x,this):m(x)},a=(()=>{const m={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:C(this,zt),state:this.state,fetchFn:s};return o(m),m})();(l=this.options.behavior)==null||l.onFetch(a,this),O(this,wn,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((f=a.fetchOptions)==null?void 0:f.meta))&&H(this,ke,st).call(this,{type:"fetch",meta:(h=a.fetchOptions)==null?void 0:h.meta});const c=m=>{var g,x,p,v;Lo(m)&&m.silent||H(this,ke,st).call(this,{type:"error",error:m}),Lo(m)||((x=(g=C(this,Ne).config).onError)==null||x.call(g,m,this),(v=(p=C(this,Ne).config).onSettled)==null||v.call(p,this.state.data,m,this)),this.scheduleGc()};return O(this,me,rl({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,abort:r.abort.bind(r),onSuccess:m=>{var g,x,p,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}`),c(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(m)}catch(y){c(y);return}(x=(g=C(this,Ne).config).onSuccess)==null||x.call(g,m,this),(v=(p=C(this,Ne).config).onSettled)==null||v.call(p,m,this.state.error,this),this.scheduleGc()},onError:c,onFail:(m,g)=>{H(this,ke,st).call(this,{type:"failed",failureCount:m,error:g})},onPause:()=>{H(this,ke,st).call(this,{type:"pause"})},onContinue:()=>{H(this,ke,st).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),C(this,me).start()}},bn=new WeakMap,wn=new WeakMap,Ne=new WeakMap,zt=new WeakMap,me=new WeakMap,Jn=new WeakMap,qt=new WeakMap,ke=new WeakSet,st=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,...sl(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 Lo(o)&&o.revert&&C(this,wn)?{...C(this,wn),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),he.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),C(this,Ne).notify({query:this,type:"updated",action:t})})},ac);function sl(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:tl(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function Pp(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 Ge,cc,Ap=(cc=class extends Dn{constructor(t={}){super();M(this,Ge);this.config=t,O(this,Ge,new Map)}build(t,n,r){const o=n.queryKey,s=n.queryHash??zs(o,n);let i=this.get(s);return i||(i=new Tp({client:t,queryKey:o,queryHash:s,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(o)}),this.add(i)),i}add(t){C(this,Ge).has(t.queryHash)||(C(this,Ge).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=C(this,Ge).get(t.queryHash);n&&(t.destroy(),n===t&&C(this,Ge).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){he.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return C(this,Ge).get(t)}getAll(){return[...C(this,Ge).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>na(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>na(t,r)):n}notify(t){he.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){he.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){he.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},Ge=new WeakMap,cc),Ke,we,Gt,Qe,yt,lc,Op=(lc=class extends ol{constructor(t){super();M(this,Qe);M(this,Ke);M(this,we);M(this,Gt);this.mutationId=t.mutationId,O(this,we,t.mutationCache),O(this,Ke,[]),this.state=t.state||il(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){C(this,Ke).includes(t)||(C(this,Ke).push(t),this.clearGcTimeout(),C(this,we).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){O(this,Ke,C(this,Ke).filter(n=>n!==t)),this.scheduleGc(),C(this,we).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){C(this,Ke).length||(this.state.status==="pending"?this.scheduleGc():C(this,we).remove(this))}continue(){var t;return((t=C(this,Gt))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var s,i,a,c,l,f,h,m,g,x,p,v,y,w,S,_,R,T,P,D;const n=()=>{H(this,Qe,yt).call(this,{type:"continue"})};O(this,Gt,rl({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(I,L)=>{H(this,Qe,yt).call(this,{type:"failed",failureCount:I,error:L})},onPause:()=>{H(this,Qe,yt).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>C(this,we).canRun(this)}));const r=this.state.status==="pending",o=!C(this,Gt).canStart();try{if(r)n();else{H(this,Qe,yt).call(this,{type:"pending",variables:t,isPaused:o}),await((i=(s=C(this,we).config).onMutate)==null?void 0:i.call(s,t,this));const L=await((c=(a=this.options).onMutate)==null?void 0:c.call(a,t));L!==this.state.context&&H(this,Qe,yt).call(this,{type:"pending",context:L,variables:t,isPaused:o})}const I=await C(this,Gt).start();return await((f=(l=C(this,we).config).onSuccess)==null?void 0:f.call(l,I,t,this.state.context,this)),await((m=(h=this.options).onSuccess)==null?void 0:m.call(h,I,t,this.state.context)),await((x=(g=C(this,we).config).onSettled)==null?void 0:x.call(g,I,null,this.state.variables,this.state.context,this)),await((v=(p=this.options).onSettled)==null?void 0:v.call(p,I,null,t,this.state.context)),H(this,Qe,yt).call(this,{type:"success",data:I}),I}catch(I){try{throw await((w=(y=C(this,we).config).onError)==null?void 0:w.call(y,I,t,this.state.context,this)),await((_=(S=this.options).onError)==null?void 0:_.call(S,I,t,this.state.context)),await((T=(R=C(this,we).config).onSettled)==null?void 0:T.call(R,void 0,I,this.state.variables,this.state.context,this)),await((D=(P=this.options).onSettled)==null?void 0:D.call(P,void 0,I,t,this.state.context)),I}finally{H(this,Qe,yt).call(this,{type:"error",error:I})}}finally{C(this,we).runNext(this)}}},Ke=new WeakMap,we=new WeakMap,Gt=new WeakMap,Qe=new WeakSet,yt=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),he.batch(()=>{C(this,Ke).forEach(r=>{r.onMutationUpdate(t)}),C(this,we).notify({mutation:this,type:"updated",action:t})})},lc);function il(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var it,$e,er,uc,jp=(uc=class extends Dn{constructor(t={}){super();M(this,it);M(this,$e);M(this,er);this.config=t,O(this,it,new Set),O(this,$e,new Map),O(this,er,0)}build(t,n,r){const o=new Op({mutationCache:this,mutationId:++fr(this,er)._,options:t.defaultMutationOptions(n),state:r});return this.add(o),o}add(t){C(this,it).add(t);const n=gr(t);if(typeof n=="string"){const r=C(this,$e).get(n);r?r.push(t):C(this,$e).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(C(this,it).delete(t)){const n=gr(t);if(typeof n=="string"){const r=C(this,$e).get(n);if(r)if(r.length>1){const o=r.indexOf(t);o!==-1&&r.splice(o,1)}else r[0]===t&&C(this,$e).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=gr(t);if(typeof n=="string"){const r=C(this,$e).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=gr(t);if(typeof n=="string"){const o=(r=C(this,$e).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(){he.batch(()=>{C(this,it).forEach(t=>{this.notify({type:"removed",mutation:t})}),C(this,it).clear(),C(this,$e).clear()})}getAll(){return Array.from(C(this,it))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>ra(n,r))}findAll(t={}){return this.getAll().filter(n=>ra(t,n))}notify(t){he.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return he.batch(()=>Promise.all(t.map(n=>n.continue().catch(xe))))}},it=new WeakMap,$e=new WeakMap,er=new WeakMap,uc);function gr(e){var t;return(t=e.options.scope)==null?void 0:t.id}function ia(e){return{onFetch:(t,n)=>{var f,h,m,g,x;const r=t.options,o=(m=(h=(f=t.fetchOptions)==null?void 0:f.meta)==null?void 0:h.fetchMore)==null?void 0:m.direction,s=((g=t.state.data)==null?void 0:g.pages)||[],i=((x=t.state.data)==null?void 0:x.pageParams)||[];let a={pages:[],pageParams:[]},c=0;const l=async()=>{let p=!1;const v=S=>{Object.defineProperty(S,"signal",{enumerable:!0,get:()=>(t.signal.aborted?p=!0:t.signal.addEventListener("abort",()=>{p=!0}),t.signal)})},y=Jc(t.options,t.fetchOptions),w=async(S,_,R)=>{if(p)return Promise.reject();if(_==null&&S.pages.length)return Promise.resolve(S);const P=(()=>{const B={client:t.client,queryKey:t.queryKey,pageParam:_,direction:R?"backward":"forward",meta:t.options.meta};return v(B),B})(),D=await y(P),{maxPages:I}=t.options,L=R?Cp:wp;return{pages:L(S.pages,D,I),pageParams:L(S.pageParams,_,I)}};if(o&&s.length){const S=o==="backward",_=S?Ip:aa,R={pages:s,pageParams:i},T=_(r,R);a=await w(R,T,S)}else{const S=e??s.length;do{const _=c===0?i[0]??r.initialPageParam:aa(r,a);if(c>0&&_==null)break;a=await w(a,_),c++}while(c<S)}return a};t.options.persister?t.fetchFn=()=>{var p,v;return(v=(p=t.options).persister)==null?void 0:v.call(p,l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=l}}}function aa(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 Ip(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 le,Et,_t,Cn,xn,Rt,Sn,En,dc,Np=(dc=class{constructor(e={}){M(this,le);M(this,Et);M(this,_t);M(this,Cn);M(this,xn);M(this,Rt);M(this,Sn);M(this,En);O(this,le,e.queryCache||new Ap),O(this,Et,e.mutationCache||new jp),O(this,_t,e.defaultOptions||{}),O(this,Cn,new Map),O(this,xn,new Map),O(this,Rt,0)}mount(){fr(this,Rt)._++,C(this,Rt)===1&&(O(this,Sn,qs.subscribe(async e=>{e&&(await this.resumePausedMutations(),C(this,le).onFocus())})),O(this,En,Gr.subscribe(async e=>{e&&(await this.resumePausedMutations(),C(this,le).onOnline())})))}unmount(){var e,t;fr(this,Rt)._--,C(this,Rt)===0&&((e=C(this,Sn))==null||e.call(this),O(this,Sn,void 0),(t=C(this,En))==null||t.call(this),O(this,En,void 0))}isFetching(e){return C(this,le).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return C(this,Et).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=C(this,le).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=C(this,le).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(Dt(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return C(this,le).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=C(this,le).get(r.queryHash),s=o==null?void 0:o.state.data,i=yp(t,s);if(i!==void 0)return C(this,le).build(this,r).setData(i,{...n,manual:!0})}setQueriesData(e,t,n){return he.batch(()=>C(this,le).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=C(this,le).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=C(this,le);he.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=C(this,le);return he.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=he.batch(()=>C(this,le).findAll(e).map(o=>o.cancel(n)));return Promise.all(r).then(xe).catch(xe)}invalidateQueries(e,t={}){return he.batch(()=>(C(this,le).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=he.batch(()=>C(this,le).findAll(e).filter(o=>!o.isDisabled()&&!o.isStatic()).map(o=>{let s=o.fetch(void 0,n);return n.throwOnError||(s=s.catch(xe)),o.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(r).then(xe)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=C(this,le).build(this,t);return n.isStaleByTime(Dt(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(xe).catch(xe)}fetchInfiniteQuery(e){return e.behavior=ia(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(xe).catch(xe)}ensureInfiniteQueryData(e){return e.behavior=ia(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Gr.isOnline()?C(this,Et).resumePausedMutations():Promise.resolve()}getQueryCache(){return C(this,le)}getMutationCache(){return C(this,Et)}getDefaultOptions(){return C(this,_t)}setDefaultOptions(e){O(this,_t,e)}setQueryDefaults(e,t){C(this,Cn).set(en(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...C(this,Cn).values()],n={};return t.forEach(r=>{Qn(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){C(this,xn).set(en(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...C(this,xn).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={...C(this,_t).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=zs(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===qr&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...C(this,_t).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){C(this,le).clear(),C(this,Et).clear()}},le=new WeakMap,Et=new WeakMap,_t=new WeakMap,Cn=new WeakMap,xn=new WeakMap,Rt=new WeakMap,Sn=new WeakMap,En=new WeakMap,dc),_e,G,tr,Ce,Kt,_n,Tt,Pt,nr,Rn,Tn,Qt,Yt,At,Pn,ne,Vn,ds,fs,hs,ps,ms,gs,vs,al,fc,Dp=(fc=class extends Dn{constructor(t,n){super();M(this,ne);M(this,_e);M(this,G);M(this,tr);M(this,Ce);M(this,Kt);M(this,_n);M(this,Tt);M(this,Pt);M(this,nr);M(this,Rn);M(this,Tn);M(this,Qt);M(this,Yt);M(this,At);M(this,Pn,new Set);this.options=n,O(this,_e,t),O(this,Pt,null),O(this,Tt,us()),this.options.experimental_prefetchInRender||C(this,Tt).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&&(C(this,G).addObserver(this),ca(C(this,G),this.options)?H(this,ne,Vn).call(this):this.updateResult(),H(this,ne,ps).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return ys(C(this,G),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return ys(C(this,G),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,H(this,ne,ms).call(this),H(this,ne,gs).call(this),C(this,G).removeObserver(this)}setOptions(t){const n=this.options,r=C(this,G);if(this.options=C(this,_e).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Fe(this.options.enabled,C(this,G))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");H(this,ne,vs).call(this),C(this,G).setOptions(this.options),n._defaulted&&!zr(this.options,n)&&C(this,_e).getQueryCache().notify({type:"observerOptionsUpdated",query:C(this,G),observer:this});const o=this.hasListeners();o&&la(C(this,G),r,this.options,n)&&H(this,ne,Vn).call(this),this.updateResult(),o&&(C(this,G)!==r||Fe(this.options.enabled,C(this,G))!==Fe(n.enabled,C(this,G))||Dt(this.options.staleTime,C(this,G))!==Dt(n.staleTime,C(this,G)))&&H(this,ne,ds).call(this);const s=H(this,ne,fs).call(this);o&&(C(this,G)!==r||Fe(this.options.enabled,C(this,G))!==Fe(n.enabled,C(this,G))||s!==C(this,At))&&H(this,ne,hs).call(this,s)}getOptimisticResult(t){const n=C(this,_e).getQueryCache().build(C(this,_e),t),r=this.createResult(n,t);return Mp(this,r)&&(O(this,Ce,r),O(this,_n,this.options),O(this,Kt,C(this,G).state)),r}getCurrentResult(){return C(this,Ce)}trackResult(t,n){return new Proxy(t,{get:(r,o)=>(this.trackProp(o),n==null||n(o),Reflect.get(r,o))})}trackProp(t){C(this,Pn).add(t)}getCurrentQuery(){return C(this,G)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=C(this,_e).defaultQueryOptions(t),r=C(this,_e).getQueryCache().build(C(this,_e),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return H(this,ne,Vn).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),C(this,Ce)))}createResult(t,n){var I;const r=C(this,G),o=this.options,s=C(this,Ce),i=C(this,Kt),a=C(this,_n),l=t!==r?t.state:C(this,tr),{state:f}=t;let h={...f},m=!1,g;if(n._optimisticResults){const L=this.hasListeners(),B=!L&&ca(t,n),U=L&&la(t,r,n,o);(B||U)&&(h={...h,...sl(f.data,t.options)}),n._optimisticResults==="isRestoring"&&(h.fetchStatus="idle")}let{error:x,errorUpdatedAt:p,status:v}=h;g=h.data;let y=!1;if(n.placeholderData!==void 0&&g===void 0&&v==="pending"){let L;s!=null&&s.isPlaceholderData&&n.placeholderData===(a==null?void 0:a.placeholderData)?(L=s.data,y=!0):L=typeof n.placeholderData=="function"?n.placeholderData((I=C(this,Tn))==null?void 0:I.state.data,C(this,Tn)):n.placeholderData,L!==void 0&&(v="success",g=ls(s==null?void 0:s.data,L,n),m=!0)}if(n.select&&g!==void 0&&!y)if(s&&g===(i==null?void 0:i.data)&&n.select===C(this,nr))g=C(this,Rn);else try{O(this,nr,n.select),g=n.select(g),g=ls(s==null?void 0:s.data,g,n),O(this,Rn,g),O(this,Pt,null)}catch(L){O(this,Pt,L)}C(this,Pt)&&(x=C(this,Pt),g=C(this,Rn),p=Date.now(),v="error");const w=h.fetchStatus==="fetching",S=v==="pending",_=v==="error",R=S&&w,T=g!==void 0,D={status:v,fetchStatus:h.fetchStatus,isPending:S,isSuccess:v==="success",isError:_,isInitialLoading:R,isLoading:R,data:g,dataUpdatedAt:h.dataUpdatedAt,error:x,errorUpdatedAt:p,failureCount:h.fetchFailureCount,failureReason:h.fetchFailureReason,errorUpdateCount:h.errorUpdateCount,isFetched:h.dataUpdateCount>0||h.errorUpdateCount>0,isFetchedAfterMount:h.dataUpdateCount>l.dataUpdateCount||h.errorUpdateCount>l.errorUpdateCount,isFetching:w,isRefetching:w&&!S,isLoadingError:_&&!T,isPaused:h.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:_&&T,isStale:Gs(t,n),refetch:this.refetch,promise:C(this,Tt)};if(this.options.experimental_prefetchInRender){const L=W=>{D.status==="error"?W.reject(D.error):D.data!==void 0&&W.resolve(D.data)},B=()=>{const W=O(this,Tt,D.promise=us());L(W)},U=C(this,Tt);switch(U.status){case"pending":t.queryHash===r.queryHash&&L(U);break;case"fulfilled":(D.status==="error"||D.data!==U.value)&&B();break;case"rejected":(D.status!=="error"||D.error!==U.reason)&&B();break}}return D}updateResult(){const t=C(this,Ce),n=this.createResult(C(this,G),this.options);if(O(this,Kt,C(this,G).state),O(this,_n,this.options),C(this,Kt).data!==void 0&&O(this,Tn,C(this,G)),zr(n,t))return;O(this,Ce,n);const r=()=>{if(!t)return!0;const{notifyOnChangeProps:o}=this.options,s=typeof o=="function"?o():o;if(s==="all"||!s&&!C(this,Pn).size)return!0;const i=new Set(s??C(this,Pn));return this.options.throwOnError&&i.add("error"),Object.keys(C(this,Ce)).some(a=>{const c=a;return C(this,Ce)[c]!==t[c]&&i.has(c)})};H(this,ne,al).call(this,{listeners:r()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&H(this,ne,ps).call(this)}},_e=new WeakMap,G=new WeakMap,tr=new WeakMap,Ce=new WeakMap,Kt=new WeakMap,_n=new WeakMap,Tt=new WeakMap,Pt=new WeakMap,nr=new WeakMap,Rn=new WeakMap,Tn=new WeakMap,Qt=new WeakMap,Yt=new WeakMap,At=new WeakMap,Pn=new WeakMap,ne=new WeakSet,Vn=function(t){H(this,ne,vs).call(this);let n=C(this,G).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(xe)),n},ds=function(){H(this,ne,ms).call(this);const t=Dt(this.options.staleTime,C(this,G));if(Jt||C(this,Ce).isStale||!is(t))return;const r=Xc(C(this,Ce).dataUpdatedAt,t)+1;O(this,Qt,setTimeout(()=>{C(this,Ce).isStale||this.updateResult()},r))},fs=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(C(this,G)):this.options.refetchInterval)??!1},hs=function(t){H(this,ne,gs).call(this),O(this,At,t),!(Jt||Fe(this.options.enabled,C(this,G))===!1||!is(C(this,At))||C(this,At)===0)&&O(this,Yt,setInterval(()=>{(this.options.refetchIntervalInBackground||qs.isFocused())&&H(this,ne,Vn).call(this)},C(this,At)))},ps=function(){H(this,ne,ds).call(this),H(this,ne,hs).call(this,H(this,ne,fs).call(this))},ms=function(){C(this,Qt)&&(clearTimeout(C(this,Qt)),O(this,Qt,void 0))},gs=function(){C(this,Yt)&&(clearInterval(C(this,Yt)),O(this,Yt,void 0))},vs=function(){const t=C(this,_e).getQueryCache().build(C(this,_e),this.options);if(t===C(this,G))return;const n=C(this,G);O(this,G,t),O(this,tr,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},al=function(t){he.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(C(this,Ce))}),C(this,_e).getQueryCache().notify({query:C(this,G),type:"observerResultsUpdated"})})},fc);function Lp(e,t){return Fe(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function ca(e,t){return Lp(e,t)||e.state.data!==void 0&&ys(e,t,t.refetchOnMount)}function ys(e,t,n){if(Fe(t.enabled,e)!==!1&&Dt(t.staleTime,e)!=="static"){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&Gs(e,t)}return!1}function la(e,t,n,r){return(e!==t||Fe(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&Gs(e,n)}function Gs(e,t){return Fe(t.enabled,e)!==!1&&e.isStaleByTime(Dt(t.staleTime,e))}function Mp(e,t){return!zr(e.getCurrentResult(),t)}var Ot,jt,Re,at,lt,$r,bs,hc,kp=(hc=class extends Dn{constructor(n,r){super();M(this,lt);M(this,Ot);M(this,jt);M(this,Re);M(this,at);O(this,Ot,n),this.setOptions(r),this.bindMethods(),H(this,lt,$r).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=C(this,Ot).defaultMutationOptions(n),zr(this.options,r)||C(this,Ot).getMutationCache().notify({type:"observerOptionsUpdated",mutation:C(this,Re),observer:this}),r!=null&&r.mutationKey&&this.options.mutationKey&&en(r.mutationKey)!==en(this.options.mutationKey)?this.reset():((o=C(this,Re))==null?void 0:o.state.status)==="pending"&&C(this,Re).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=C(this,Re))==null||n.removeObserver(this)}onMutationUpdate(n){H(this,lt,$r).call(this),H(this,lt,bs).call(this,n)}getCurrentResult(){return C(this,jt)}reset(){var n;(n=C(this,Re))==null||n.removeObserver(this),O(this,Re,void 0),H(this,lt,$r).call(this),H(this,lt,bs).call(this)}mutate(n,r){var o;return O(this,at,r),(o=C(this,Re))==null||o.removeObserver(this),O(this,Re,C(this,Ot).getMutationCache().build(C(this,Ot),this.options)),C(this,Re).addObserver(this),C(this,Re).execute(n)}},Ot=new WeakMap,jt=new WeakMap,Re=new WeakMap,at=new WeakMap,lt=new WeakSet,$r=function(){var r;const n=((r=C(this,Re))==null?void 0:r.state)??il();O(this,jt,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},bs=function(n){he.batch(()=>{var r,o,s,i,a,c,l,f;if(C(this,at)&&this.hasListeners()){const h=C(this,jt).variables,m=C(this,jt).context;(n==null?void 0:n.type)==="success"?((o=(r=C(this,at)).onSuccess)==null||o.call(r,n.data,h,m),(i=(s=C(this,at)).onSettled)==null||i.call(s,n.data,null,h,m)):(n==null?void 0:n.type)==="error"&&((c=(a=C(this,at)).onError)==null||c.call(a,n.error,h,m),(f=(l=C(this,at)).onSettled)==null||f.call(l,void 0,n.error,h,m))}this.listeners.forEach(h=>{h(C(this,jt))})})},hc),cl=d.createContext(void 0),Ks=e=>{const t=d.useContext(cl);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},$p=({client:e,children:t})=>(d.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),u.jsx(cl.Provider,{value:e,children:t})),ll=d.createContext(!1),Fp=()=>d.useContext(ll);ll.Provider;function Bp(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var Up=d.createContext(Bp()),Wp=()=>d.useContext(Up),Hp=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},Vp=e=>{d.useEffect(()=>{e.clearReset()},[e])},zp=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:o})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(o&&e.data===void 0||el(n,[e.error,r])),qp=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))}},Gp=(e,t)=>e.isLoading&&e.isFetching&&!t,Kp=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,ua=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function Qp(e,t,n){var h,m,g,x,p;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=Fp(),o=Wp(),s=Ks(),i=s.defaultQueryOptions(e);(m=(h=s.getDefaultOptions().queries)==null?void 0:h._experimental_beforeQuery)==null||m.call(h,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",qp(i),Hp(i,o),Vp(o);const a=!s.getQueryCache().get(i.queryHash),[c]=d.useState(()=>new t(s,i)),l=c.getOptimisticResult(i),f=!r&&e.subscribed!==!1;if(d.useSyncExternalStore(d.useCallback(v=>{const y=f?c.subscribe(he.batchCalls(v)):xe;return c.updateResult(),y},[c,f]),()=>c.getCurrentResult(),()=>c.getCurrentResult()),d.useEffect(()=>{c.setOptions(i)},[i,c]),Kp(i,l))throw ua(i,c,o);if(zp({result:l,errorResetBoundary:o,throwOnError:i.throwOnError,query:s.getQueryCache().get(i.queryHash),suspense:i.suspense}))throw l.error;if((x=(g=s.getDefaultOptions().queries)==null?void 0:g._experimental_afterQuery)==null||x.call(g,i,l),i.experimental_prefetchInRender&&!Jt&&Gp(l,r)){const v=a?ua(i,c,o):(p=s.getQueryCache().get(i.queryHash))==null?void 0:p.promise;v==null||v.catch(xe).finally(()=>{c.updateResult()})}return i.notifyOnChangeProps?l:c.trackResult(l)}function da(e,t){return Qp(e,Dp)}function vr(e,t){const n=Ks(),[r]=d.useState(()=>new kp(n,e));d.useEffect(()=>{r.setOptions(e)},[r,e]);const o=d.useSyncExternalStore(d.useCallback(i=>r.subscribe(he.batchCalls(i)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),s=d.useCallback((i,a)=>{r.mutate(i,a).catch(xe)},[r]);if(o.error&&el(r.options.throwOnError,[o.error]))throw o.error;return{...o,mutate:s,mutateAsync:o.mutate}}const yr={STALE_TIME:1e3*60*5,GC_TIME:1e3*60*10,RETRY_COUNT:1,RETRY_DELAY:1e3},fa={refetchOnWindowFocus:!1,refetchOnReconnect:!1,refetchOnMount:!1,staleTime:yr.STALE_TIME,gcTime:yr.GC_TIME,retry:yr.RETRY_COUNT,retryDelay:yr.RETRY_DELAY,enable:!0},br=e=>e instanceof Error?e.message:String(e),ul=(e,t,n)=>{const r=Ks(),{notify:o}=Vs(),{createFn:s,readFn:i,readByIdFn:a,updateFn:c,deleteFn:l,partialUpdateFn:f}=n,h=()=>{r.invalidateQueries({queryKey:[e]})},m=(_,R,T,P)=>o(P!=null&&P.overrideSuccessMessage?P==null?void 0:P.overrideSuccessMessage(_,R):T,"success"),g=(_,R,T,P)=>o(P!=null&&P.overrideErrorMessage?P==null?void 0:P.overrideErrorMessage(_,R):T,"error");return{useCreate:_=>vr({mutationFn:R=>s(R),onSuccess:R=>{h(),m(t,R,`${t} created successfully`,_)},onError:R=>{g(t,R,`Error creating ${t}: ${br(R)}`,_)}}),useReadQuery:_=>da({queryKey:[e],queryFn:i,...fa,..._}),useReadByIdQuery:(_,R)=>da({queryKey:[e,_],queryFn:()=>a(_),...fa,enabled:!!_,...R}),useUpdate:_=>vr({mutationFn:({id:R,data:T})=>c(R,T),onSuccess:R=>{h(),m(t,R,`${t} updated successfully`,_)},onError:R=>{g(t,R,`Error updating ${t}: ${br(R)}`,_)}}),usePartialUpdate:_=>f&&vr({mutationFn:({id:R,data:T})=>f(R,T),onSuccess:R=>{h(),m(t,R,`${t} updated successfully`,_)},onError:R=>{g(t,R,`Error updating ${t}: ${br(R)}`,_)}}),useDelete:_=>vr({mutationFn:R=>l(R),onSuccess:()=>{h(),m(t,null,`${t} deleted successfully`,_)},onError:R=>{g(t,R,`Error deleting ${t}: ${br(R)}`,_)}}),invalidateQueries:h}},Yp=(e,t)=>ul(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())}),Zp={SINGLE_TENANT:"single-tenant"},Xp={COOKIE:"cookie"},Mo="tenant",ha="tenant",pa="tenant",Jp=Zp.SINGLE_TENANT,e1=Xp.COOKIE,t1={mode:Jp,clientSideMode:e1,tenantIDPProvisioningStrategy:"none"};class n1{setTenant(t,n){const r=new URL(window.location.href);r.searchParams.set(ha,t.name),window.location.href=r.toString()}getCurrentTenantName(){const t=new URL(window.location.href);return new URLSearchParams(t.search).get(ha)}}class r1{setTenant(t,n){sessionStorage.setItem(pa,t.name),window.location.reload()}getCurrentTenantName(){return sessionStorage.getItem(pa)}}/*! js-cookie v3.0.5 | MIT */function wr(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 o1={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 ws(e,t){function n(o,s,i){if(!(typeof document>"u")){i=wr({},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 c in i)i[c]&&(a+="; "+c,i[c]!==!0&&(a+="="+i[c].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 c=s[a].split("="),l=c.slice(1).join("=");try{var f=decodeURIComponent(c[0]);if(i[f]=e.read(l,f),o===f)break}catch{}}return o?i[o]:i}}return Object.create({set:n,get:r,remove:function(o,s){n(o,"",wr({},s,{expires:-1}))},withAttributes:function(o){return ws(this.converter,wr({},this.attributes,o))},withConverter:function(o){return ws(wr({},this.converter,o),this.attributes)}},{attributes:{value:Object.freeze(t)},converter:{value:Object.freeze(e)}})}var ko=ws(o1,{path:"/"});class s1{setTenant(t,n){t?ko.set(Mo,t.name):ko.remove(Mo),window.location.reload()}getCurrentTenantName(){return ko.get(Mo)}}class i1{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 l;const r=(l=n.urlPatterns)==null?void 0:l.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),c=s?`${s}.${a}`:a;o.hostname=c,window.location.href=o.toString()}getCurrentTenantName(){const t=window.location.hostname;return this.extractSubdomain(t)||null}}const ma={queryParams:new n1,sessionStorage:new r1,cookie:new s1,subdomain:new i1},a1=e=>{const t=ma[e.clientSideMode];if(!t)throw new Error(`Client side tenant mode '${e.clientSideMode}' is not supported ${JSON.stringify({strategies:ma},null,2)}`);return t},c1=(e,t,n)=>{const r=t.find(s=>s.name===n);if(!r)throw Error("No tenant permission");return a1(e).setTenant(r,e),r},l1=()=>{const[e,t]=In(),{tenants:n=[],currentTenant:r,tenantConfig:o=t1}=e,s=E.useCallback(i=>{const a=c1(o,n,i);t({...e,currentTenant:a})},[o,e]);return{tenants:n,currentTenant:r,tenantConfig:o,selectTenant:s}};function u1(e){if(!e.ok)throw console.error(e),new Error(e.statusText)}async function Cr(e,t,n,r){const o=await e(`/user-states/${encodeURIComponent(t)}/${encodeURIComponent(n)}`,r);return u1(o),o}class xr{static async get(t,n,r){const s=await Cr(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 Cr(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 Cr(t,n,r,s)).json()}static async delete(t,n,r){return await Cr(t,n,r,{method:"DELETE",headers:{"Content-Type":"application/json"}}),null}}const d1=e=>{const t=Hs("@bluealba/pae-nestjs-gateway-service"),n=Lc();if(!n)throw new Error("You must call the useUserState hook within a PAE application.");const[r,o]=E.useState(null),[s,i]=E.useState(!1),[a,c]=E.useState(!1),[l,f]=E.useState(null),h=(w,S)=>E.useCallback(async({newValue:_,shouldThrowError:R}={})=>{try{c(!0),f(null);const T=await w(t,n,e,_);return o(T),T?T.value:null}catch(T){if(f(T==null?void 0:T.message),console.error(`Failed to ${S} ${e}:`,T),R)throw T;return null}finally{c(!1)}},[t,n,e]),m=h(xr.get,"fetch"),g=h(xr.create,"create"),x=h(xr.update,"update"),p=h(xr.delete,"delete"),v=E.useCallback(async()=>{try{await m()}finally{i(!0)}},[m]);E.useEffect(()=>{v()},[v]);const y=E.useCallback(async(w,S=!1)=>r==null?await g({newValue:w,shouldThrowError:S}):await x({newValue:w,shouldThrowError:S}),[r,g,x]);return{value:r?r.value:null,hasFetched:s,loading:a,error:l,setValue:y,createValue:g,updateValue:x,deleteValue:p}},ga="single-spa:app-change";function f1(){const[e,t]=E.useState(va());return E.useEffect(()=>{const n=()=>{t(va())};return window.addEventListener(ga,n),()=>{window.removeEventListener(ga,n)}},[]),e}function va(){return Nr.getAppNames().reduce((t,n)=>(Nr.getAppStatus(n)?t[n]=Nr.getAppStatus(n):t[n]="NOT_LOADED",t),{})}function Qs(e){const n=f1()[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 h1(e){const{url:t,method:n,formData:r,onProgress:o,signal:s}=e;return new Promise((i,a)=>{const c=new XMLHttpRequest;c.withCredentials=!0,c.upload.onprogress=l=>{l.lengthComputable&&o&&o(Math.round(l.loaded/l.total*100))},c.onload=()=>{if(c.status>=400){let l="Upload failed";try{l=JSON.parse(c.responseText).message??l}catch{}const f=new Error(l);f.status=c.status,a(f);return}try{const l=JSON.parse(c.responseText);i(l)}catch{a(new Error("Failed to parse response JSON"))}},c.onerror=()=>{a(new Error("Upload failed due to a network error"))},s&&s.addEventListener("abort",()=>c.abort()),c.open(n,t),c.send(r)})}const Un="File storage is disabled on this platform";async function Sr(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 p1(){const[{fileStorageEnabled:e}]=In(),t=E.useCallback((i,a)=>{if(!e)return Promise.reject(new Error(Un));const c=new FormData;return c.append("file",i),(a==null?void 0:a.isPublic)!==void 0&&c.append("isPublic",String(a.isPublic)),(a==null?void 0:a.description)!==void 0&&c.append("description",a.description),(a==null?void 0:a.metadata)!==void 0&&c.append("metadata",JSON.stringify(a.metadata)),h1({url:"/files",method:"POST",formData:c,onProgress:a==null?void 0:a.onProgress,signal:a==null?void 0:a.signal})},[e]),n=E.useCallback(async(i,a)=>{if(!e)return Promise.reject(new Error(Un));const c=new FormData;a.originalName!==void 0&&c.append("originalName",a.originalName),a.isPublic!==void 0&&c.append("isPublic",String(a.isPublic)),a.description!==void 0&&c.append("description",a.description),a.metadata!==void 0&&c.append("metadata",JSON.stringify(a.metadata));const l=await fetch(`/files/${i}`,{method:"PATCH",headers:{Accept:"application/json"},body:c});return l.ok||await Sr(l),l.json()},[e]),r=E.useCallback(async i=>{if(!e)return Promise.reject(new Error(Un));const a=await fetch(`/files/${i}`,{method:"DELETE",headers:{Accept:"application/json"}});a.ok||await Sr(a)},[e]),o=E.useCallback(async i=>{if(!e)return Promise.reject(new Error(Un));const a=await fetch(`/files/${i}/download`);a.ok||await Sr(a);const c=await a.blob(),l=URL.createObjectURL(c);let f=`file-${i}`;const h=a.headers.get("Content-Disposition");if(h){const g=h.match(/attachment;\s*filename="([^"]+)"/);g&&(f=g[1])}const m=document.createElement("a");m.href=l,m.download=f,document.body.appendChild(m),m.click(),document.body.removeChild(m),URL.revokeObjectURL(l)},[e]),s=E.useCallback(async i=>{if(!e)return Promise.reject(new Error(Un));const a=await fetch(`/files/${i}/download`);a.ok||await Sr(a);const c=await a.blob();return URL.createObjectURL(c)},[e]);return{isEnabled:e,upload:t,updateMetadata:n,remove:r,download:o,getPreviewUrl:s}}const dl="__PAE_EXTENSION_POINT_REACT_CONTENT_EMPTY__",m1=({module:e,point:t,children:n})=>(Fc(e,t,n??dl),null),fl=({name:e,children:t,...n})=>{const r=$c(e);if(r===dl)return null;if(!r)return u.jsx(u.Fragment,{children:t??null});if(g1(r)){const o=r;return u.jsx(o,{...n})}else return r},g1=e=>typeof e=="function",v1=(e,t)=>{const n=r=>(t=t||e.displayName||e.name||"?",u.jsx(fl,{name:t,...r,children:u.jsx(e,{...r})}));return n.displayName=`extensionPoint(${t})`,n},hl=({appName:e})=>u.jsx("div",{children:u.jsxs("p",{children:["Loading ",e,"..."]})});hl.displayName="BaseLoading";const pl=({appName:e})=>u.jsxs("div",{children:[u.jsx("p",{children:"Something went wrong..."}),u.jsxs("p",{children:["Failed to load ",e]})]});pl.displayName="BaseError";const y1={display:"flex",flexDirection:"column",flex:1},ml=E.forwardRef((e,t)=>u.jsx("div",{ref:t,style:y1,...e}));ml.displayName="BaseContainer";const b1="pae-app:",gl=E.forwardRef(({appName:e,LoadingComponent:t=hl,ErrorComponent:n=pl,ContainerComponent:r=ml,...o},s)=>{const i=Qs(e);return u.jsxs(r,{ref:s,...o,id:`${b1}${e}`,children:[i.isLoading&&u.jsx(t,{appName:e}),i.isBroken&&u.jsx(n,{appName:e})]})});gl.displayName="ModulePlaceHolder";const Ys=({operations:e,children:t,forbiddenContent:n})=>{var o;const{hasAccess:r}=or();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 u.jsx(s,{operations:e})}else return n({operations:e});return E.isValidElement(n)?n:null}return t};Ys.displayName="Authorized";const w1=({eventName:e,listener:t})=>(Bc(e,t),null),C1=()=>u.jsx("svg",{"aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24",children:u.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"})}),vl=({applicationName:e})=>{const t=Nc(e);if(t)if(typeof t=="function"){const n=t;return u.jsx(n,{})}else return t;return u.jsx(C1,{})};vl.displayName="ApplicationIcon";const yl=()=>u.jsx("svg",{width:"28",height:"28",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.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"})});yl.displayName="DarkModeIcon";const bl=()=>u.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:u.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"})});bl.displayName="LightModeIcon";const x1="container__zBqbk",S1="expanded__EbsIr",E1="label__cdMnm",$o={container:x1,expanded:S1,label:E1};function wl(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=wl(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function N(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=wl(e))&&(r&&(r+=" "),r+=t);return r}const _1=e=>e.toLowerCase().trim().split(" ").join("-"),R1=e=>`${_1(e)}-theme`,Cl=()=>{const{platformName:e="Platform"}=Rc(),t=R1(e),[n,r]=E.useState(()=>{const s=localStorage.getItem(t);return s==="light"||s==="dark"?s:"light"}),o=s=>{localStorage.setItem(t,s),r(s)};return E.useEffect(()=>{document.documentElement.setAttribute("data-theme",n)},[n]),{theme:n,setTheme:o}},T1="spinner__fakUN",P1="spinner-rotation__wUmPV",A1="button__8FA9H",O1="button--contained-primary__stkTx",j1="button--outlined-primary__KZ1ww",I1="button--text-primary__GLTfm",N1="button--contained-danger__L9ehT",D1="button--outlined-danger__eoYLd",L1="button--text-danger__Sw-ha",M1="icon__--umH",Er={spinner:T1,"spinner-rotation":"spinner-rotation__wUmPV",spinnerRotation:P1,button:A1,"button--contained-primary":"button--contained-primary__stkTx",buttonContainedPrimary:O1,"button--outlined-primary":"button--outlined-primary__KZ1ww",buttonOutlinedPrimary:j1,"button--text-primary":"button--text-primary__GLTfm",buttonTextPrimary:I1,"button--contained-danger":"button--contained-danger__L9ehT",buttonContainedDanger:N1,"button--outlined-danger":"button--outlined-danger__eoYLd",buttonOutlinedDanger:D1,"button--text-danger":"button--text-danger__Sw-ha",buttonTextDanger:L1,icon:M1},Kr=E.forwardRef(({variant:e="contained",colorScheme:t="primary",loading:n=!1,IconComponent:r,className:o,children:s,...i},a)=>{const c=N(Er.button,Er[`button--${e}-${t}`],o);return u.jsxs("button",{ref:a,className:c,...i,children:[n?u.jsx("div",{className:Er.spinner}):r&&u.jsx(r,{className:Er.icon}),s]})});Kr.displayName="Button";const k1="Badges__5jpum",$1="Badges__5jpum",F1="Badge__95MWM",B1="Badge__95MWM",U1="Badge--primary__Rx-bS",W1="Badge--secondary__d92bT",H1="Badge--success__Kdo98",V1="Badge--warning__bf-Nn",z1="Badge--danger__HTj39",q1="Badge--small__y93Pj",G1="Badge--regular__aT5AL",K1="Badge--large__wORCH",Fr={Badges:k1,badges:$1,Badge:F1,badge:B1,"Badge--primary":"Badge--primary__Rx-bS",badgePrimary:U1,"Badge--secondary":"Badge--secondary__d92bT",badgeSecondary:W1,"Badge--success":"Badge--success__Kdo98",badgeSuccess:H1,"Badge--warning":"Badge--warning__bf-Nn",badgeWarning:V1,"Badge--danger":"Badge--danger__HTj39",badgeDanger:z1,"Badge--small":"Badge--small__y93Pj",badgeSmall:q1,"Badge--regular":"Badge--regular__aT5AL",badgeRegular:G1,"Badge--large":"Badge--large__wORCH",badgeLarge:K1},Cs={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 Cs)Object.freeze(Cs[e]);const ya=Object.freeze(Cs);var ba={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};function Q1(e){var f,h;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(),ya[e])n=ya[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 c=t[1];o=c.replace(/a$/,"");var l=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(ba[m]!==void 0)return ba[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>l?n.pop():1}else/[0-9](?:\s|\/|,)/.test(e)&&(n=e.match(/([0-9]+)/g).map(function(m){return parseFloat(m)}),o=((h=(f=e.match(/([a-z])/ig))==null?void 0:f.join(""))==null?void 0:h.toLowerCase())||"rgb");return{space:o,values:n,alpha:r}}const Y1=(e,t)=>{const{space:n,values:r}=Q1(e);return n[0]==="h"?`${n}a(${r[0]}, ${r[1]}%, ${r[2]}%, ${t})`:`${n}a(${r}, ${t})`},Zs=E.forwardRef(({children:e,color:t,className:n,customColor:r,size:o="small",style:s,...i},a)=>{const c=r?{color:r,background:Y1(r,.1)}:{},l=N(Fr.Badge,Fr[`Badge--${o}`],{[Fr[`Badge--${t}`]]:!!t},n);return u.jsx("span",{ref:a,className:l,style:{...s,...c},...i,children:e})});Zs.displayName="Badge";const Xs=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Fr.Badges,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Xs.displayName="Badges";const xl=({size:e=24,color:t="currentColor",strokeWidth:n=2,className:r,style:o,...s})=>u.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:[u.jsx("rect",{x:"8",y:"2",width:"8",height:"4",rx:"1",ry:"1"}),u.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"})]}),Sl=({size:e=24,color:t="currentColor",strokeWidth:n=2,className:r,style:o,...s})=>u.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:[u.jsx("rect",{x:"8",y:"2",width:"8",height:"4",rx:"1",ry:"1"}),u.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"}),u.jsx("path",{d:"m9 12 2 2 4-4"})]}),Z1="CopyToClipboardButton__2Nd2m",X1={CopyToClipboardButton:Z1},J1=({content:e})=>{const[t,n]=em(),{notify:r}=Vs(),o=t?Sl:xl,s=E.useCallback(async()=>{await n(e)&&r("Copied to the Clipboard !","success")},[e,r]);return u.jsx(o,{className:X1.CopyToClipboardButton,size:18,onClick:s})},em=()=>{const[e,t]=E.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}}]},tm="FieldGroup__Q2JCV",nm="FieldGroup__Q2JCV",rm="FieldGroup--horizontal__kpfL1",om="FieldGroup--vertical__FLo-Q",wa={FieldGroup:tm,fieldGroup:nm,"FieldGroup--horizontal":"FieldGroup--horizontal__kpfL1",fieldGroupHorizontal:rm,"FieldGroup--vertical":"FieldGroup--vertical__FLo-Q",fieldGroupVertical:om},El=E.forwardRef(({children:e,className:t,orientation:n="vertical",...r},o)=>{const s=N(wa.FieldGroup,wa[`FieldGroup--${n}`],t);return u.jsx("div",{ref:o,className:s,...r,children:e})});El.displayName="FieldGroup";const sm="Input__uS0sb",Ca={Input:sm,Error:"Error__-DQpw"},uo=E.forwardRef(({className:e,error:t,...n},r)=>{const o=N(Ca.Input,t&&Ca.Error,e);return u.jsx("input",{ref:r,className:o,...n})});uo.displayName="Input";const im={Error:"Error__N4OP5"},_l=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(im.Error,t);return u.jsx("span",{ref:r,className:o,...n,children:e})});_l.displayName="InputError";const am="Label__VYUvW",xa={Label:am,Error:"Error__Eu6DI"},Rl=E.forwardRef(({children:e,className:t,error:n,...r},o)=>{const s=N(xa.Label,n&&xa.Error,t);return u.jsx("label",{ref:o,className:s,...r,children:e})});Rl.displayName="Label";const cm="Select__giqpe",lm="Chevron__YvhBd",xs={Select:cm,Chevron:lm},Tl=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(xs.Option,t);return u.jsx("option",{ref:r,className:o,...n,children:e})});Tl.displayName="Option";const Js=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(xs.Select,t);return u.jsxs("div",{className:o,children:[u.jsx("select",{ref:r,...n,children:e}),u.jsx("div",{className:xs.Chevron,children:u.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"M4 6L8 10L12 6",stroke:"#818181",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})})})]})});Js.displayName="Select";Js.Option=Tl;function Sa(e,[t,n]){return Math.min(n,Math.max(t,e))}function X(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 um(e,t){const n=d.createContext(t),r=s=>{const{children:i,...a}=s,c=d.useMemo(()=>a,Object.values(a));return u.jsx(n.Provider,{value:c,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 ar(e,t=[]){let n=[];function r(s,i){const a=d.createContext(i),c=n.length;n=[...n,i];const l=h=>{var y;const{scope:m,children:g,...x}=h,p=((y=m==null?void 0:m[e])==null?void 0:y[c])||a,v=d.useMemo(()=>x,Object.values(x));return u.jsx(p.Provider,{value:v,children:g})};l.displayName=s+"Provider";function f(h,m){var p;const g=((p=m==null?void 0:m[e])==null?void 0:p[c])||a,x=d.useContext(g);if(x)return x;if(i!==void 0)return i;throw new Error(`\`${h}\` must be used within \`${s}\``)}return[l,f]}const o=()=>{const s=n.map(i=>d.createContext(i));return function(a){const c=(a==null?void 0:a[e])||s;return d.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return o.scopeName=e,[r,dm(o,...t)]}function dm(...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:c,scopeName:l})=>{const h=c(s)[`__scope${l}`];return{...a,...h}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function Ea(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Ln(...e){return t=>{let n=!1;const r=e.map(o=>{const s=Ea(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():Ea(e[o],null)}}}}function ce(...e){return d.useCallback(Ln(...e),e)}function _a(e){const t=fm(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),c=a.find(pm);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function fm(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=gm(o),a=mm(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 hm=Symbol("radix.slottable");function pm(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===hm}function mm(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function gm(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 vm(e){const t=e+"CollectionProvider",[n,r]=ar(t),[o,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=p=>{const{scope:v,children:y}=p,w=E.useRef(null),S=E.useRef(new Map).current;return u.jsx(o,{scope:v,itemMap:S,collectionRef:w,children:y})};i.displayName=t;const a=e+"CollectionSlot",c=_a(a),l=E.forwardRef((p,v)=>{const{scope:y,children:w}=p,S=s(a,y),_=ce(v,S.collectionRef);return u.jsx(c,{ref:_,children:w})});l.displayName=a;const f=e+"CollectionItemSlot",h="data-radix-collection-item",m=_a(f),g=E.forwardRef((p,v)=>{const{scope:y,children:w,...S}=p,_=E.useRef(null),R=ce(v,_),T=s(f,y);return E.useEffect(()=>(T.itemMap.set(_,{ref:_,...S}),()=>void T.itemMap.delete(_))),u.jsx(m,{[h]:"",ref:R,children:w})});g.displayName=f;function x(p){const v=s(e+"CollectionConsumer",p);return E.useCallback(()=>{const w=v.collectionRef.current;if(!w)return[];const S=Array.from(w.querySelectorAll(`[${h}]`));return Array.from(v.itemMap.values()).sort((T,P)=>S.indexOf(T.ref.current)-S.indexOf(P.ref.current))},[v.collectionRef,v.itemMap])}return[{Provider:i,Slot:l,ItemSlot:g},x,r]}var ym=d.createContext(void 0);function bm(e){const t=d.useContext(ym);return e||t||"ltr"}function wm(e){const t=Cm(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),c=a.find(Sm);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function Cm(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=_m(o),a=Em(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 xm=Symbol("radix.slottable");function Sm(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===xm}function Em(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function _m(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 Rm=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ie=Rm.reduce((e,t)=>{const n=wm(`Primitive.${t}`),r=d.forwardRef((o,s)=>{const{asChild:i,...a}=o,c=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(c,{...a,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Tm(e,t){e&&so.flushSync(()=>e.dispatchEvent(t))}function tn(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 Pm(e,t=globalThis==null?void 0:globalThis.document){const n=tn(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 Am="DismissableLayer",Ss="dismissableLayer.update",Om="dismissableLayer.pointerDownOutside",jm="dismissableLayer.focusOutside",Ra,Pl=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),fo=d.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:i,onDismiss:a,...c}=e,l=d.useContext(Pl),[f,h]=d.useState(null),m=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,g]=d.useState({}),x=ce(t,P=>h(P)),p=Array.from(l.layers),[v]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),y=p.indexOf(v),w=f?p.indexOf(f):-1,S=l.layersWithOutsidePointerEventsDisabled.size>0,_=w>=y,R=Dm(P=>{const D=P.target,I=[...l.branches].some(L=>L.contains(D));!_||I||(o==null||o(P),i==null||i(P),P.defaultPrevented||a==null||a())},m),T=Lm(P=>{const D=P.target;[...l.branches].some(L=>L.contains(D))||(s==null||s(P),i==null||i(P),P.defaultPrevented||a==null||a())},m);return Pm(P=>{w===l.layers.size-1&&(r==null||r(P),!P.defaultPrevented&&a&&(P.preventDefault(),a()))},m),d.useEffect(()=>{if(f)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(Ra=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(f)),l.layers.add(f),Ta(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=Ra)}},[f,m,n,l]),d.useEffect(()=>()=>{f&&(l.layers.delete(f),l.layersWithOutsidePointerEventsDisabled.delete(f),Ta())},[f,l]),d.useEffect(()=>{const P=()=>g({});return document.addEventListener(Ss,P),()=>document.removeEventListener(Ss,P)},[]),u.jsx(ie.div,{...c,ref:x,style:{pointerEvents:S?_?"auto":"none":void 0,...e.style},onFocusCapture:X(e.onFocusCapture,T.onFocusCapture),onBlurCapture:X(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:X(e.onPointerDownCapture,R.onPointerDownCapture)})});fo.displayName=Am;var Im="DismissableLayerBranch",Nm=d.forwardRef((e,t)=>{const n=d.useContext(Pl),r=d.useRef(null),o=ce(t,r);return d.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),u.jsx(ie.div,{...e,ref:o})});Nm.displayName=Im;function Dm(e,t=globalThis==null?void 0:globalThis.document){const n=tn(e),r=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const s=a=>{if(a.target&&!r.current){let c=function(){Al(Om,n,l,{discrete:!0})};const l={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}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 Lm(e,t=globalThis==null?void 0:globalThis.document){const n=tn(e),r=d.useRef(!1);return d.useEffect(()=>{const o=s=>{s.target&&!r.current&&Al(jm,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 Ta(){const e=new CustomEvent(Ss);document.dispatchEvent(e)}function Al(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?Tm(o,s):o.dispatchEvent(s)}var Fo=0;function Ol(){d.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Pa()),document.body.insertAdjacentElement("beforeend",e[1]??Pa()),Fo++,()=>{Fo===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Fo--}},[])}function Pa(){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 Bo="focusScope.autoFocusOnMount",Uo="focusScope.autoFocusOnUnmount",Aa={bubbles:!1,cancelable:!0},Mm="FocusScope",ei=d.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...i}=e,[a,c]=d.useState(null),l=tn(o),f=tn(s),h=d.useRef(null),m=ce(t,p=>c(p)),g=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let p=function(S){if(g.paused||!a)return;const _=S.target;a.contains(_)?h.current=_:bt(h.current,{select:!0})},v=function(S){if(g.paused||!a)return;const _=S.relatedTarget;_!==null&&(a.contains(_)||bt(h.current,{select:!0}))},y=function(S){if(document.activeElement===document.body)for(const R of S)R.removedNodes.length>0&&bt(a)};document.addEventListener("focusin",p),document.addEventListener("focusout",v);const w=new MutationObserver(y);return a&&w.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",p),document.removeEventListener("focusout",v),w.disconnect()}}},[r,a,g.paused]),d.useEffect(()=>{if(a){ja.add(g);const p=document.activeElement;if(!a.contains(p)){const y=new CustomEvent(Bo,Aa);a.addEventListener(Bo,l),a.dispatchEvent(y),y.defaultPrevented||(km(Wm(jl(a)),{select:!0}),document.activeElement===p&&bt(a))}return()=>{a.removeEventListener(Bo,l),setTimeout(()=>{const y=new CustomEvent(Uo,Aa);a.addEventListener(Uo,f),a.dispatchEvent(y),y.defaultPrevented||bt(p??document.body,{select:!0}),a.removeEventListener(Uo,f),ja.remove(g)},0)}}},[a,l,f,g]);const x=d.useCallback(p=>{if(!n&&!r||g.paused)return;const v=p.key==="Tab"&&!p.altKey&&!p.ctrlKey&&!p.metaKey,y=document.activeElement;if(v&&y){const w=p.currentTarget,[S,_]=$m(w);S&&_?!p.shiftKey&&y===_?(p.preventDefault(),n&&bt(S,{select:!0})):p.shiftKey&&y===S&&(p.preventDefault(),n&&bt(_,{select:!0})):y===w&&p.preventDefault()}},[n,r,g.paused]);return u.jsx(ie.div,{tabIndex:-1,...i,ref:m,onKeyDown:x})});ei.displayName=Mm;function km(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(bt(r,{select:t}),document.activeElement!==n)return}function $m(e){const t=jl(e),n=Oa(t,e),r=Oa(t.reverse(),e);return[n,r]}function jl(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 Oa(e,t){for(const n of e)if(!Fm(n,{upTo:t}))return n}function Fm(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 Bm(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&&Bm(e)&&t&&e.select()}}var ja=Um();function Um(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Ia(e,t),e.unshift(t)},remove(t){var n;e=Ia(e,t),(n=e[0])==null||n.resume()}}}function Ia(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Wm(e){return e.filter(t=>t.tagName!=="A")}var ve=globalThis!=null&&globalThis.document?d.useLayoutEffect:()=>{},Hm=d[" useId ".trim().toString()]||(()=>{}),Vm=0;function Zt(e){const[t,n]=d.useState(Hm());return ve(()=>{n(r=>r??String(Vm++))},[e]),e||(t?`radix-${t}`:"")}const zm=["top","right","bottom","left"],Lt=Math.min,Te=Math.max,Qr=Math.round,_r=Math.floor,Je=e=>({x:e,y:e}),qm={left:"right",right:"left",bottom:"top",top:"bottom"},Gm={start:"end",end:"start"};function Es(e,t,n){return Te(e,Lt(t,n))}function dt(e,t){return typeof e=="function"?e(t):e}function ft(e){return e.split("-")[0]}function Mn(e){return e.split("-")[1]}function ti(e){return e==="x"?"y":"x"}function ni(e){return e==="y"?"height":"width"}const Km=new Set(["top","bottom"]);function Xe(e){return Km.has(ft(e))?"y":"x"}function ri(e){return ti(Xe(e))}function Qm(e,t,n){n===void 0&&(n=!1);const r=Mn(e),o=ri(e),s=ni(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Yr(i)),[i,Yr(i)]}function Ym(e){const t=Yr(e);return[_s(e),t,_s(t)]}function _s(e){return e.replace(/start|end/g,t=>Gm[t])}const Na=["left","right"],Da=["right","left"],Zm=["top","bottom"],Xm=["bottom","top"];function Jm(e,t,n){switch(e){case"top":case"bottom":return n?t?Da:Na:t?Na:Da;case"left":case"right":return t?Zm:Xm;default:return[]}}function eg(e,t,n,r){const o=Mn(e);let s=Jm(ft(e),n==="start",r);return o&&(s=s.map(i=>i+"-"+o),t&&(s=s.concat(s.map(_s)))),s}function Yr(e){return e.replace(/left|right|bottom|top/g,t=>qm[t])}function tg(e){return{top:0,right:0,bottom:0,left:0,...e}}function Il(e){return typeof e!="number"?tg(e):{top:e,right:e,bottom:e,left:e}}function Zr(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 La(e,t,n){let{reference:r,floating:o}=e;const s=Xe(t),i=ri(t),a=ni(i),c=ft(t),l=s==="y",f=r.x+r.width/2-o.width/2,h=r.y+r.height/2-o.height/2,m=r[a]/2-o[a]/2;let g;switch(c){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:h};break;case"left":g={x:r.x-o.width,y:h};break;default:g={x:r.x,y:r.y}}switch(Mn(t)){case"start":g[i]-=m*(n&&l?-1:1);break;case"end":g[i]+=m*(n&&l?-1:1);break}return g}async function ng(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:s,rects:i,elements:a,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:f="viewport",elementContext:h="floating",altBoundary:m=!1,padding:g=0}=dt(t,e),x=Il(g),v=a[m?h==="floating"?"reference":"floating":h],y=Zr(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:l,rootBoundary:f,strategy:c})),w=h==="floating"?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,S=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),_=await(s.isElement==null?void 0:s.isElement(S))?await(s.getScale==null?void 0:s.getScale(S))||{x:1,y:1}:{x:1,y:1},R=Zr(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:w,offsetParent:S,strategy:c}):w);return{top:(y.top-R.top+x.top)/_.y,bottom:(R.bottom-y.bottom+x.bottom)/_.y,left:(y.left-R.left+x.left)/_.x,right:(R.right-y.right+x.right)/_.x}}const rg=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:i}=n,a=s.filter(Boolean),c=await(i.isRTL==null?void 0:i.isRTL(t));let l=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:h}=La(l,r,c),m=r,g={},x=0;for(let v=0;v<a.length;v++){var p;const{name:y,fn:w}=a[v],{x:S,y:_,data:R,reset:T}=await w({x:f,y:h,initialPlacement:r,placement:m,strategy:o,middlewareData:g,rects:l,platform:{...i,detectOverflow:(p=i.detectOverflow)!=null?p:ng},elements:{reference:e,floating:t}});f=S??f,h=_??h,g={...g,[y]:{...g[y],...R}},T&&x<=50&&(x++,typeof T=="object"&&(T.placement&&(m=T.placement),T.rects&&(l=T.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):T.rects),{x:f,y:h}=La(l,m,c)),v=-1)}return{x:f,y:h,placement:m,strategy:o,middlewareData:g}},og=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:i,elements:a,middlewareData:c}=t,{element:l,padding:f=0}=dt(e,t)||{};if(l==null)return{};const h=Il(f),m={x:n,y:r},g=ri(o),x=ni(g),p=await i.getDimensions(l),v=g==="y",y=v?"top":"left",w=v?"bottom":"right",S=v?"clientHeight":"clientWidth",_=s.reference[x]+s.reference[g]-m[g]-s.floating[x],R=m[g]-s.reference[g],T=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l));let P=T?T[S]:0;(!P||!await(i.isElement==null?void 0:i.isElement(T)))&&(P=a.floating[S]||s.floating[x]);const D=_/2-R/2,I=P/2-p[x]/2-1,L=Lt(h[y],I),B=Lt(h[w],I),U=L,W=P-p[x]-B,V=P/2-p[x]/2+D,re=Es(U,V,W),z=!c.arrow&&Mn(o)!=null&&V!==re&&s.reference[x]/2-(V<U?L:B)-p[x]/2<0,Q=z?V<U?V-U:V-W:0;return{[g]:m[g]+Q,data:{[g]:re,centerOffset:V-re-Q,...z&&{alignmentOffset:Q}},reset:z}}}),sg=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:c,elements:l}=t,{mainAxis:f=!0,crossAxis:h=!0,fallbackPlacements:m,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:x="none",flipAlignment:p=!0,...v}=dt(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const y=ft(o),w=Xe(a),S=ft(a)===a,_=await(c.isRTL==null?void 0:c.isRTL(l.floating)),R=m||(S||!p?[Yr(a)]:Ym(a)),T=x!=="none";!m&&T&&R.push(...eg(a,p,x,_));const P=[a,...R],D=await c.detectOverflow(t,v),I=[];let L=((r=s.flip)==null?void 0:r.overflows)||[];if(f&&I.push(D[y]),h){const V=Qm(o,i,_);I.push(D[V[0]],D[V[1]])}if(L=[...L,{placement:o,overflows:I}],!I.every(V=>V<=0)){var B,U;const V=(((B=s.flip)==null?void 0:B.index)||0)+1,re=P[V];if(re&&(!(h==="alignment"?w!==Xe(re):!1)||L.every($=>Xe($.placement)===w?$.overflows[0]>0:!0)))return{data:{index:V,overflows:L},reset:{placement:re}};let z=(U=L.filter(Q=>Q.overflows[0]<=0).sort((Q,$)=>Q.overflows[1]-$.overflows[1])[0])==null?void 0:U.placement;if(!z)switch(g){case"bestFit":{var W;const Q=(W=L.filter($=>{if(T){const oe=Xe($.placement);return oe===w||oe==="y"}return!0}).map($=>[$.placement,$.overflows.filter(oe=>oe>0).reduce((oe,pe)=>oe+pe,0)]).sort(($,oe)=>$[1]-oe[1])[0])==null?void 0:W[0];Q&&(z=Q);break}case"initialPlacement":z=a;break}if(o!==z)return{reset:{placement:z}}}return{}}}};function Ma(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ka(e){return zm.some(t=>e[t]>=0)}const ig=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n,platform:r}=t,{strategy:o="referenceHidden",...s}=dt(e,t);switch(o){case"referenceHidden":{const i=await r.detectOverflow(t,{...s,elementContext:"reference"}),a=Ma(i,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:ka(a)}}}case"escaped":{const i=await r.detectOverflow(t,{...s,altBoundary:!0}),a=Ma(i,n.floating);return{data:{escapedOffsets:a,escaped:ka(a)}}}default:return{}}}}},Nl=new Set(["left","top"]);async function ag(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=ft(n),a=Mn(n),c=Xe(n)==="y",l=Nl.has(i)?-1:1,f=s&&c?-1:1,h=dt(t,e);let{mainAxis:m,crossAxis:g,alignmentAxis:x}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:h.mainAxis||0,crossAxis:h.crossAxis||0,alignmentAxis:h.alignmentAxis};return a&&typeof x=="number"&&(g=a==="end"?x*-1:x),c?{x:g*f,y:m*l}:{x:m*l,y:g*f}}const cg=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,c=await ag(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:o+c.x,y:s+c.y,data:{...c,placement:i}}}}},lg=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:c={fn:y=>{let{x:w,y:S}=y;return{x:w,y:S}}},...l}=dt(e,t),f={x:n,y:r},h=await s.detectOverflow(t,l),m=Xe(ft(o)),g=ti(m);let x=f[g],p=f[m];if(i){const y=g==="y"?"top":"left",w=g==="y"?"bottom":"right",S=x+h[y],_=x-h[w];x=Es(S,x,_)}if(a){const y=m==="y"?"top":"left",w=m==="y"?"bottom":"right",S=p+h[y],_=p-h[w];p=Es(S,p,_)}const v=c.fn({...t,[g]:x,[m]:p});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[g]:i,[m]:a}}}}}},ug=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:c=!0,crossAxis:l=!0}=dt(e,t),f={x:n,y:r},h=Xe(o),m=ti(h);let g=f[m],x=f[h];const p=dt(a,t),v=typeof p=="number"?{mainAxis:p,crossAxis:0}:{mainAxis:0,crossAxis:0,...p};if(c){const S=m==="y"?"height":"width",_=s.reference[m]-s.floating[S]+v.mainAxis,R=s.reference[m]+s.reference[S]-v.mainAxis;g<_?g=_:g>R&&(g=R)}if(l){var y,w;const S=m==="y"?"width":"height",_=Nl.has(ft(o)),R=s.reference[h]-s.floating[S]+(_&&((y=i.offset)==null?void 0:y[h])||0)+(_?0:v.crossAxis),T=s.reference[h]+s.reference[S]+(_?0:((w=i.offset)==null?void 0:w[h])||0)-(_?v.crossAxis:0);x<R?x=R:x>T&&(x=T)}return{[m]:g,[h]:x}}}},dg=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:c=()=>{},...l}=dt(e,t),f=await i.detectOverflow(t,l),h=ft(o),m=Mn(o),g=Xe(o)==="y",{width:x,height:p}=s.floating;let v,y;h==="top"||h==="bottom"?(v=h,y=m===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(y=h,v=m==="end"?"top":"bottom");const w=p-f.top-f.bottom,S=x-f.left-f.right,_=Lt(p-f[v],w),R=Lt(x-f[y],S),T=!t.middlewareData.shift;let P=_,D=R;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=S),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(P=w),T&&!m){const L=Te(f.left,0),B=Te(f.right,0),U=Te(f.top,0),W=Te(f.bottom,0);g?D=x-2*(L!==0||B!==0?L+B:Te(f.left,f.right)):P=p-2*(U!==0||W!==0?U+W:Te(f.top,f.bottom))}await c({...t,availableWidth:D,availableHeight:P});const I=await i.getDimensions(a.floating);return x!==I.width||p!==I.height?{reset:{rects:!0}}:{}}}};function ho(){return typeof window<"u"}function kn(e){return Dl(e)?(e.nodeName||"").toLowerCase():"#document"}function Ae(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function tt(e){var t;return(t=(Dl(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Dl(e){return ho()?e instanceof Node||e instanceof Ae(e).Node:!1}function Ue(e){return ho()?e instanceof Element||e instanceof Ae(e).Element:!1}function et(e){return ho()?e instanceof HTMLElement||e instanceof Ae(e).HTMLElement:!1}function $a(e){return!ho()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ae(e).ShadowRoot}const fg=new Set(["inline","contents"]);function cr(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=We(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!fg.has(o)}const hg=new Set(["table","td","th"]);function pg(e){return hg.has(kn(e))}const mg=[":popover-open",":modal"];function po(e){return mg.some(t=>{try{return e.matches(t)}catch{return!1}})}const gg=["transform","translate","scale","rotate","perspective"],vg=["transform","translate","scale","rotate","perspective","filter"],yg=["paint","layout","strict","content"];function oi(e){const t=si(),n=Ue(e)?We(e):e;return gg.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)||vg.some(r=>(n.willChange||"").includes(r))||yg.some(r=>(n.contain||"").includes(r))}function bg(e){let t=Mt(e);for(;et(t)&&!An(t);){if(oi(t))return t;if(po(t))return null;t=Mt(t)}return null}function si(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const wg=new Set(["html","body","#document"]);function An(e){return wg.has(kn(e))}function We(e){return Ae(e).getComputedStyle(e)}function mo(e){return Ue(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Mt(e){if(kn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||$a(e)&&e.host||tt(e);return $a(t)?t.host:t}function Ll(e){const t=Mt(e);return An(t)?e.ownerDocument?e.ownerDocument.body:e.body:et(t)&&cr(t)?t:Ll(t)}function Yn(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=Ll(e),s=o===((r=e.ownerDocument)==null?void 0:r.body),i=Ae(o);if(s){const a=Rs(i);return t.concat(i,i.visualViewport||[],cr(o)?o:[],a&&n?Yn(a):[])}return t.concat(o,Yn(o,[],n))}function Rs(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Ml(e){const t=We(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=et(e),s=o?e.offsetWidth:n,i=o?e.offsetHeight:r,a=Qr(n)!==s||Qr(r)!==i;return a&&(n=s,r=i),{width:n,height:r,$:a}}function ii(e){return Ue(e)?e:e.contextElement}function pn(e){const t=ii(e);if(!et(t))return Je(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=Ml(t);let i=(s?Qr(n.width):n.width)/r,a=(s?Qr(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const Cg=Je(0);function kl(e){const t=Ae(e);return!si()||!t.visualViewport?Cg:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function xg(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ae(e)?!1:t}function nn(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=ii(e);let i=Je(1);t&&(r?Ue(r)&&(i=pn(r)):i=pn(e));const a=xg(s,n,r)?kl(s):Je(0);let c=(o.left+a.x)/i.x,l=(o.top+a.y)/i.y,f=o.width/i.x,h=o.height/i.y;if(s){const m=Ae(s),g=r&&Ue(r)?Ae(r):r;let x=m,p=Rs(x);for(;p&&r&&g!==x;){const v=pn(p),y=p.getBoundingClientRect(),w=We(p),S=y.left+(p.clientLeft+parseFloat(w.paddingLeft))*v.x,_=y.top+(p.clientTop+parseFloat(w.paddingTop))*v.y;c*=v.x,l*=v.y,f*=v.x,h*=v.y,c+=S,l+=_,x=Ae(p),p=Rs(x)}}return Zr({width:f,height:h,x:c,y:l})}function go(e,t){const n=mo(e).scrollLeft;return t?t.left+n:nn(tt(e)).left+n}function $l(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-go(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function Sg(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",i=tt(r),a=t?po(t.floating):!1;if(r===i||a&&s)return n;let c={scrollLeft:0,scrollTop:0},l=Je(1);const f=Je(0),h=et(r);if((h||!h&&!s)&&((kn(r)!=="body"||cr(i))&&(c=mo(r)),et(r))){const g=nn(r);l=pn(r),f.x=g.x+r.clientLeft,f.y=g.y+r.clientTop}const m=i&&!h&&!s?$l(i,c):Je(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+f.x+m.x,y:n.y*l.y-c.scrollTop*l.y+f.y+m.y}}function Eg(e){return Array.from(e.getClientRects())}function _g(e){const t=tt(e),n=mo(e),r=e.ownerDocument.body,o=Te(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=Te(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+go(e);const a=-n.scrollTop;return We(r).direction==="rtl"&&(i+=Te(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:i,y:a}}const Fa=25;function Rg(e,t){const n=Ae(e),r=tt(e),o=n.visualViewport;let s=r.clientWidth,i=r.clientHeight,a=0,c=0;if(o){s=o.width,i=o.height;const f=si();(!f||f&&t==="fixed")&&(a=o.offsetLeft,c=o.offsetTop)}const l=go(r);if(l<=0){const f=r.ownerDocument,h=f.body,m=getComputedStyle(h),g=f.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,x=Math.abs(r.clientWidth-h.clientWidth-g);x<=Fa&&(s-=x)}else l<=Fa&&(s+=l);return{width:s,height:i,x:a,y:c}}const Tg=new Set(["absolute","fixed"]);function Pg(e,t){const n=nn(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=et(e)?pn(e):Je(1),i=e.clientWidth*s.x,a=e.clientHeight*s.y,c=o*s.x,l=r*s.y;return{width:i,height:a,x:c,y:l}}function Ba(e,t,n){let r;if(t==="viewport")r=Rg(e,n);else if(t==="document")r=_g(tt(e));else if(Ue(t))r=Pg(t,n);else{const o=kl(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return Zr(r)}function Fl(e,t){const n=Mt(e);return n===t||!Ue(n)||An(n)?!1:We(n).position==="fixed"||Fl(n,t)}function Ag(e,t){const n=t.get(e);if(n)return n;let r=Yn(e,[],!1).filter(a=>Ue(a)&&kn(a)!=="body"),o=null;const s=We(e).position==="fixed";let i=s?Mt(e):e;for(;Ue(i)&&!An(i);){const a=We(i),c=oi(i);!c&&a.position==="fixed"&&(o=null),(s?!c&&!o:!c&&a.position==="static"&&!!o&&Tg.has(o.position)||cr(i)&&!c&&Fl(e,i))?r=r.filter(f=>f!==i):o=a,i=Mt(i)}return t.set(e,r),r}function Og(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?po(t)?[]:Ag(t,this._c):[].concat(n),r],a=i[0],c=i.reduce((l,f)=>{const h=Ba(t,f,o);return l.top=Te(h.top,l.top),l.right=Lt(h.right,l.right),l.bottom=Lt(h.bottom,l.bottom),l.left=Te(h.left,l.left),l},Ba(t,a,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function jg(e){const{width:t,height:n}=Ml(e);return{width:t,height:n}}function Ig(e,t,n){const r=et(t),o=tt(t),s=n==="fixed",i=nn(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const c=Je(0);function l(){c.x=go(o)}if(r||!r&&!s)if((kn(t)!=="body"||cr(o))&&(a=mo(t)),r){const g=nn(t,!0,s,t);c.x=g.x+t.clientLeft,c.y=g.y+t.clientTop}else o&&l();s&&!r&&o&&l();const f=o&&!r&&!s?$l(o,a):Je(0),h=i.left+a.scrollLeft-c.x-f.x,m=i.top+a.scrollTop-c.y-f.y;return{x:h,y:m,width:i.width,height:i.height}}function Wo(e){return We(e).position==="static"}function Ua(e,t){if(!et(e)||We(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return tt(e)===n&&(n=n.ownerDocument.body),n}function Bl(e,t){const n=Ae(e);if(po(e))return n;if(!et(e)){let o=Mt(e);for(;o&&!An(o);){if(Ue(o)&&!Wo(o))return o;o=Mt(o)}return n}let r=Ua(e,t);for(;r&&pg(r)&&Wo(r);)r=Ua(r,t);return r&&An(r)&&Wo(r)&&!oi(r)?n:r||bg(e)||n}const Ng=async function(e){const t=this.getOffsetParent||Bl,n=this.getDimensions,r=await n(e.floating);return{reference:Ig(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Dg(e){return We(e).direction==="rtl"}const Lg={convertOffsetParentRelativeRectToViewportRelativeRect:Sg,getDocumentElement:tt,getClippingRect:Og,getOffsetParent:Bl,getElementRects:Ng,getClientRects:Eg,getDimensions:jg,getScale:pn,isElement:Ue,isRTL:Dg};function Ul(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Mg(e,t){let n=null,r;const o=tt(e);function s(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function i(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),s();const l=e.getBoundingClientRect(),{left:f,top:h,width:m,height:g}=l;if(a||t(),!m||!g)return;const x=_r(h),p=_r(o.clientWidth-(f+m)),v=_r(o.clientHeight-(h+g)),y=_r(f),S={rootMargin:-x+"px "+-p+"px "+-v+"px "+-y+"px",threshold:Te(0,Lt(1,c))||1};let _=!0;function R(T){const P=T[0].intersectionRatio;if(P!==c){if(!_)return i();P?i(!1,P):r=setTimeout(()=>{i(!1,1e-7)},1e3)}P===1&&!Ul(l,e.getBoundingClientRect())&&i(),_=!1}try{n=new IntersectionObserver(R,{...S,root:o.ownerDocument})}catch{n=new IntersectionObserver(R,S)}n.observe(e)}return i(!0),s}function kg(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:c=!1}=r,l=ii(e),f=o||s?[...l?Yn(l):[],...Yn(t)]:[];f.forEach(y=>{o&&y.addEventListener("scroll",n,{passive:!0}),s&&y.addEventListener("resize",n)});const h=l&&a?Mg(l,n):null;let m=-1,g=null;i&&(g=new ResizeObserver(y=>{let[w]=y;w&&w.target===l&&g&&(g.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var S;(S=g)==null||S.observe(t)})),n()}),l&&!c&&g.observe(l),g.observe(t));let x,p=c?nn(e):null;c&&v();function v(){const y=nn(e);p&&!Ul(p,y)&&n(),p=y,x=requestAnimationFrame(v)}return n(),()=>{var y;f.forEach(w=>{o&&w.removeEventListener("scroll",n),s&&w.removeEventListener("resize",n)}),h==null||h(),(y=g)==null||y.disconnect(),g=null,c&&cancelAnimationFrame(x)}}const $g=cg,Fg=lg,Bg=sg,Ug=dg,Wg=ig,Wa=og,Hg=ug,Vg=(e,t,n)=>{const r=new Map,o={platform:Lg,...n},s={...o.platform,_c:r};return rg(e,t,{...o,platform:s})};var zg=typeof document<"u",qg=function(){},Br=zg?E.useLayoutEffect:qg;function Xr(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(!Xr(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)&&!Xr(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function Wl(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Ha(e,t){const n=Wl(e);return Math.round(t*n)/n}function Ho(e){const t=d.useRef(e);return Br(()=>{t.current=e}),t}function Gg(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:c,open:l}=e,[f,h]=d.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,g]=d.useState(r);Xr(m,r)||g(r);const[x,p]=d.useState(null),[v,y]=d.useState(null),w=d.useCallback($=>{$!==T.current&&(T.current=$,p($))},[]),S=d.useCallback($=>{$!==P.current&&(P.current=$,y($))},[]),_=s||x,R=i||v,T=d.useRef(null),P=d.useRef(null),D=d.useRef(f),I=c!=null,L=Ho(c),B=Ho(o),U=Ho(l),W=d.useCallback(()=>{if(!T.current||!P.current)return;const $={placement:t,strategy:n,middleware:m};B.current&&($.platform=B.current),Vg(T.current,P.current,$).then(oe=>{const pe={...oe,isPositioned:U.current!==!1};V.current&&!Xr(D.current,pe)&&(D.current=pe,so.flushSync(()=>{h(pe)}))})},[m,t,n,B,U]);Br(()=>{l===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,h($=>({...$,isPositioned:!1})))},[l]);const V=d.useRef(!1);Br(()=>(V.current=!0,()=>{V.current=!1}),[]),Br(()=>{if(_&&(T.current=_),R&&(P.current=R),_&&R){if(L.current)return L.current(_,R,W);W()}},[_,R,W,L,I]);const re=d.useMemo(()=>({reference:T,floating:P,setReference:w,setFloating:S}),[w,S]),z=d.useMemo(()=>({reference:_,floating:R}),[_,R]),Q=d.useMemo(()=>{const $={position:n,left:0,top:0};if(!z.floating)return $;const oe=Ha(z.floating,f.x),pe=Ha(z.floating,f.y);return a?{...$,transform:"translate("+oe+"px, "+pe+"px)",...Wl(z.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:oe,top:pe}},[n,a,z.floating,f.x,f.y]);return d.useMemo(()=>({...f,update:W,refs:re,elements:z,floatingStyles:Q}),[f,W,re,z,Q])}const Kg=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?Wa({element:r.current,padding:o}).fn(n):{}:r?Wa({element:r,padding:o}).fn(n):{}}}},Qg=(e,t)=>({...$g(e),options:[e,t]}),Yg=(e,t)=>({...Fg(e),options:[e,t]}),Zg=(e,t)=>({...Hg(e),options:[e,t]}),Xg=(e,t)=>({...Bg(e),options:[e,t]}),Jg=(e,t)=>({...Ug(e),options:[e,t]}),ev=(e,t)=>({...Wg(e),options:[e,t]}),tv=(e,t)=>({...Kg(e),options:[e,t]});var nv="Arrow",Hl=d.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...s}=e;return u.jsx(ie.svg,{...s,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:u.jsx("polygon",{points:"0,0 30,0 15,10"})})});Hl.displayName=nv;var rv=Hl;function ov(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 c=s.borderBoxSize,l=Array.isArray(c)?c[0]:c;i=l.inlineSize,a=l.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 ai="Popper",[Vl,vo]=ar(ai),[sv,zl]=Vl(ai),ql=e=>{const{__scopePopper:t,children:n}=e,[r,o]=d.useState(null);return u.jsx(sv,{scope:t,anchor:r,onAnchorChange:o,children:n})};ql.displayName=ai;var Gl="PopperAnchor",Kl=d.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,s=zl(Gl,n),i=d.useRef(null),a=ce(t,i),c=d.useRef(null);return d.useEffect(()=>{const l=c.current;c.current=(r==null?void 0:r.current)||i.current,l!==c.current&&s.onAnchorChange(c.current)}),r?null:u.jsx(ie.div,{...o,ref:a})});Kl.displayName=Gl;var ci="PopperContent",[iv,av]=Vl(ci),Ql=d.forwardRef((e,t)=>{var k,J,de,Y,ee,Z;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:s="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:c=!0,collisionBoundary:l=[],collisionPadding:f=0,sticky:h="partial",hideWhenDetached:m=!1,updatePositionStrategy:g="optimized",onPlaced:x,...p}=e,v=zl(ci,n),[y,w]=d.useState(null),S=ce(t,ye=>w(ye)),[_,R]=d.useState(null),T=ov(_),P=(T==null?void 0:T.width)??0,D=(T==null?void 0:T.height)??0,I=r+(s!=="center"?"-"+s:""),L=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},B=Array.isArray(l)?l:[l],U=B.length>0,W={padding:L,boundary:B.filter(lv),altBoundary:U},{refs:V,floatingStyles:re,placement:z,isPositioned:Q,middlewareData:$}=Gg({strategy:"fixed",placement:I,whileElementsMounted:(...ye)=>kg(...ye,{animationFrame:g==="always"}),elements:{reference:v.anchor},middleware:[Qg({mainAxis:o+D,alignmentAxis:i}),c&&Yg({mainAxis:!0,crossAxis:!1,limiter:h==="partial"?Zg():void 0,...W}),c&&Xg({...W}),Jg({...W,apply:({elements:ye,rects:je,availableWidth:ze,availableHeight:Le})=>{const{width:vt,height:dr}=je.reference,rt=ye.floating.style;rt.setProperty("--radix-popper-available-width",`${ze}px`),rt.setProperty("--radix-popper-available-height",`${Le}px`),rt.setProperty("--radix-popper-anchor-width",`${vt}px`),rt.setProperty("--radix-popper-anchor-height",`${dr}px`)}}),_&&tv({element:_,padding:a}),uv({arrowWidth:P,arrowHeight:D}),m&&ev({strategy:"referenceHidden",...W})]}),[oe,pe]=Xl(z),Oe=tn(x);ve(()=>{Q&&(Oe==null||Oe())},[Q,Oe]);const pt=(k=$.arrow)==null?void 0:k.x,mt=(J=$.arrow)==null?void 0:J.y,Ve=((de=$.arrow)==null?void 0:de.centerOffset)!==0,[gt,De]=d.useState();return ve(()=>{y&&De(window.getComputedStyle(y).zIndex)},[y]),u.jsx("div",{ref:V.setFloating,"data-radix-popper-content-wrapper":"",style:{...re,transform:Q?re.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:gt,"--radix-popper-transform-origin":[(Y=$.transformOrigin)==null?void 0:Y.x,(ee=$.transformOrigin)==null?void 0:ee.y].join(" "),...((Z=$.hide)==null?void 0:Z.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:u.jsx(iv,{scope:n,placedSide:oe,onArrowChange:R,arrowX:pt,arrowY:mt,shouldHideArrow:Ve,children:u.jsx(ie.div,{"data-side":oe,"data-align":pe,...p,ref:S,style:{...p.style,animation:Q?void 0:"none"}})})})});Ql.displayName=ci;var Yl="PopperArrow",cv={top:"bottom",right:"left",bottom:"top",left:"right"},Zl=d.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,s=av(Yl,r),i=cv[s.placedSide];return u.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:u.jsx(rv,{...o,ref:n,style:{...o.style,display:"block"}})})});Zl.displayName=Yl;function lv(e){return e!==null}var uv=e=>({name:"transformOrigin",options:e,fn(t){var v,y,w;const{placement:n,rects:r,middlewareData:o}=t,i=((v=o.arrow)==null?void 0:v.centerOffset)!==0,a=i?0:e.arrowWidth,c=i?0:e.arrowHeight,[l,f]=Xl(n),h={start:"0%",center:"50%",end:"100%"}[f],m=(((y=o.arrow)==null?void 0:y.x)??0)+a/2,g=(((w=o.arrow)==null?void 0:w.y)??0)+c/2;let x="",p="";return l==="bottom"?(x=i?h:`${m}px`,p=`${-c}px`):l==="top"?(x=i?h:`${m}px`,p=`${r.floating.height+c}px`):l==="right"?(x=`${-c}px`,p=i?h:`${g}px`):l==="left"&&(x=`${r.floating.width+c}px`,p=i?h:`${g}px`),{data:{x,y:p}}}});function Xl(e){const[t,n="center"]=e.split("-");return[t,n]}var Jl=ql,eu=Kl,tu=Ql,nu=Zl,dv="Portal",li=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?pc.createPortal(u.jsx(ie.div,{...r,ref:t}),i):null});li.displayName=dv;function fv(e){const t=hv(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),c=a.find(mv);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function hv(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=vv(o),a=gv(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 pv=Symbol("radix.slottable");function mv(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===pv}function gv(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function vv(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 yv=d[" useInsertionEffect ".trim().toString()]||ve;function Jr({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,s,i]=bv({defaultProp:t,onChange:n}),a=e!==void 0,c=a?e:o;{const f=d.useRef(e!==void 0);d.useEffect(()=>{const h=f.current;h!==a&&console.warn(`${r} is changing from ${h?"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 l=d.useCallback(f=>{var h;if(a){const m=wv(f)?f(e):f;m!==e&&((h=i.current)==null||h.call(i,m))}else s(f)},[a,e,s,i]);return[c,l]}function bv({defaultProp:e,onChange:t}){const[n,r]=d.useState(e),o=d.useRef(n),s=d.useRef(t);return yv(()=>{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 wv(e){return typeof e=="function"}function Cv(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 ru=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"}),xv="VisuallyHidden",ou=d.forwardRef((e,t)=>u.jsx(ie.span,{...e,ref:t,style:{...ru,...e.style}}));ou.displayName=xv;var Sv=ou,Ev=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},dn=new WeakMap,Rr=new WeakMap,Tr={},Vo=0,su=function(e){return e&&(e.host||su(e.parentNode))},_v=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=su(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})},Rv=function(e,t,n,r){var o=_v(t,Array.isArray(e)?e:[e]);Tr[n]||(Tr[n]=new WeakMap);var s=Tr[n],i=[],a=new Set,c=new Set(o),l=function(h){!h||a.has(h)||(a.add(h),l(h.parentNode))};o.forEach(l);var f=function(h){!h||c.has(h)||Array.prototype.forEach.call(h.children,function(m){if(a.has(m))f(m);else try{var g=m.getAttribute(r),x=g!==null&&g!=="false",p=(dn.get(m)||0)+1,v=(s.get(m)||0)+1;dn.set(m,p),s.set(m,v),i.push(m),p===1&&x&&Rr.set(m,!0),v===1&&m.setAttribute(n,"true"),x||m.setAttribute(r,"true")}catch(y){console.error("aria-hidden: cannot operate on ",m,y)}})};return f(t),a.clear(),Vo++,function(){i.forEach(function(h){var m=dn.get(h)-1,g=s.get(h)-1;dn.set(h,m),s.set(h,g),m||(Rr.has(h)||h.removeAttribute(r),Rr.delete(h)),g||h.removeAttribute(n)}),Vo--,Vo||(dn=new WeakMap,dn=new WeakMap,Rr=new WeakMap,Tr={})}},iu=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=Ev(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),Rv(r,o,n,"aria-hidden")):function(){return null}},Ur="right-scroll-bar-position",Wr="width-before-scroll-bar",Tv="with-scroll-bars-hidden",Pv="--removed-body-scroll-bar-size";function zo(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Av(e,t){var n=E.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 Ov=typeof window<"u"?d.useLayoutEffect:d.useEffect,Va=new WeakMap;function jv(e,t){var n=Av(null,function(r){return e.forEach(function(o){return zo(o,r)})});return Ov(function(){var r=Va.get(n);if(r){var o=new Set(r),s=new Set(e),i=n.current;o.forEach(function(a){s.has(a)||zo(a,null)}),s.forEach(function(a){o.has(a)||zo(a,i)})}Va.set(n,e)},[e]),n}function Iv(e){return e}function Nv(e,t){t===void 0&&(t=Iv);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 c=function(){var f=i;i=[],f.forEach(s)},l=function(){return Promise.resolve().then(c)};l(),n={push:function(f){i.push(f),l()},filter:function(f){return i=i.filter(f),n}}}};return o}function Dv(e){e===void 0&&(e={});var t=Nv(null);return t.options=Ye({async:!0,ssr:!1},e),t}var au=function(e){var t=e.sideCar,n=Hc(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))};au.isSideCarExport=!0;function Lv(e,t){return e.useMedium(t),au}var cu=Dv(),qo=function(){},yo=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:qo,onWheelCapture:qo,onTouchMoveCapture:qo}),o=r[0],s=r[1],i=e.forwardProps,a=e.children,c=e.className,l=e.removeScrollBar,f=e.enabled,h=e.shards,m=e.sideCar,g=e.noRelative,x=e.noIsolation,p=e.inert,v=e.allowPinchZoom,y=e.as,w=y===void 0?"div":y,S=e.gapMode,_=Hc(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),R=m,T=jv([n,t]),P=Ye(Ye({},_),o);return d.createElement(d.Fragment,null,f&&d.createElement(R,{sideCar:cu,removeScrollBar:l,shards:h,noRelative:g,noIsolation:x,inert:p,setCallbacks:s,allowPinchZoom:!!v,lockRef:n,gapMode:S}),i?d.cloneElement(d.Children.only(a),Ye(Ye({},P),{ref:T})):d.createElement(w,Ye({},P,{className:c,ref:T}),a))});yo.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};yo.classNames={fullWidth:Wr,zeroRight:Ur};var Mv=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function kv(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Mv();return t&&e.setAttribute("nonce",t),e}function $v(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Fv(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Bv=function(){var e=0,t=null;return{add:function(n){e==0&&(t=kv())&&($v(t,n),Fv(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Uv=function(){var e=Bv();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},lu=function(){var e=Uv(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},Wv={left:0,top:0,right:0,gap:0},Go=function(e){return parseInt(e||"",10)||0},Hv=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[Go(n),Go(r),Go(o)]},Vv=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Wv;var t=Hv(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])}},zv=lu(),mn="data-scroll-locked",qv=function(e,t,n,r){var o=e.left,s=e.top,i=e.right,a=e.gap;return n===void 0&&(n="margin"),`
|
|
212
|
-
.`.concat(
|
|
211
|
+
`,mr=16,vp=({reverseOrder:e,position:t="top-center",toastOptions:n,gutter:r,children:o,containerStyle:s,containerClassName:i})=>{let{toasts:a,handlers:c}=zh(n);return d.createElement("div",{style:{position:"fixed",zIndex:9999,top:mr,left:mr,right:mr,bottom:mr,pointerEvents:"none",...s},className:i,onMouseEnter:c.startPause,onMouseLeave:c.endPause},a.map(l=>{let f=l.position||t,h=c.calculateOffset(l,{reverseOrder:e,gutter:r,defaultPosition:t}),m=gp(f,h);return d.createElement(mp,{id:l.id,key:l.id,onHeightUpdate:c.updateHeight,className:l.visible?yp:"",style:m},l.type==="custom"?Vr(l.message,l):o?o(l):d.createElement(pp,{toast:l,position:f}))}))},na=Pe;const qs=()=>({notify:E.useCallback((t,n,r)=>{const o={style:{background:"var(--platform-background-primary-color)",color:"var(--platform-text-primary-color)"}};n==="warning"||n==="info"?na(t,{...o,icon:n==="warning"?"⚠️":"ℹ️"}):na[n](t,o),r&&console.error(r)},[])});var Dn=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(){}},Jt=typeof window>"u"||"Deno"in globalThis;function xe(){}function bp(e,t){return typeof e=="function"?e(t):e}function as(e){return typeof e=="number"&&e>=0&&e!==1/0}function Jc(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Dt(e,t){return typeof e=="function"?e(t):e}function Fe(e,t){return typeof e=="function"?e(t):e}function ra(e,t){const{type:n="all",exact:r,fetchStatus:o,predicate:s,queryKey:i,stale:a}=e;if(i){if(r){if(t.queryHash!==zs(i,t.options))return!1}else if(!Qn(t.queryKey,i))return!1}if(n!=="all"){const c=t.isActive();if(n==="active"&&!c||n==="inactive"&&c)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||o&&o!==t.state.fetchStatus||s&&!s(t))}function oa(e,t){const{exact:n,status:r,predicate:o,mutationKey:s}=e;if(s){if(!t.options.mutationKey)return!1;if(n){if(en(t.options.mutationKey)!==en(s))return!1}else if(!Qn(t.options.mutationKey,s))return!1}return!(r&&t.state.status!==r||o&&!o(t))}function zs(e,t){return((t==null?void 0:t.queryKeyHashFn)||en)(e)}function en(e){return JSON.stringify(e,(t,n)=>ls(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 cs(e,t){if(e===t)return e;const n=sa(e)&&sa(t);if(n||ls(e)&&ls(t)){const r=n?e:Object.keys(e),o=r.length,s=n?t:Object.keys(t),i=s.length,a=n?[]:{};let c=0;for(let l=0;l<i;l++){const f=n?l:s[l];(!n&&r.includes(f)||n)&&e[f]===void 0&&t[f]===void 0?(a[f]=void 0,c++):(a[f]=cs(e[f],t[f]),a[f]===e[f]&&e[f]!==void 0&&c++)}return o===i&&c===o?e:a}return t}function qr(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 sa(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function ls(e){if(!ia(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!ia(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function ia(e){return Object.prototype.toString.call(e)==="[object Object]"}function wp(e){return new Promise(t=>{setTimeout(t,e)})}function us(e,t,n){if(typeof n.structuralSharing=="function")return n.structuralSharing(e,t);if(n.structuralSharing!==!1){try{return cs(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 cs(e,t)}return t}function Cp(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function xp(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var zr=Symbol();function el(e,t){return e.queryFn===zr&&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===zr?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function tl(e,t){return typeof e=="function"?e(...t):!!e}var Ht,xt,gn,sc,Sp=(sc=class extends Dn{constructor(){super();M(this,Ht);M(this,xt);M(this,gn);O(this,gn,t=>{if(!Jt&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){C(this,xt)||this.setEventListener(C(this,gn))}onUnsubscribe(){var t;this.hasListeners()||((t=C(this,xt))==null||t.call(this),O(this,xt,void 0))}setEventListener(t){var n;O(this,gn,t),(n=C(this,xt))==null||n.call(this),O(this,xt,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){C(this,Ht)!==t&&(O(this,Ht,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof C(this,Ht)=="boolean"?C(this,Ht):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},Ht=new WeakMap,xt=new WeakMap,gn=new WeakMap,sc),Gs=new Sp,yn,St,vn,ic,Ep=(ic=class extends Dn{constructor(){super();M(this,yn,!0);M(this,St);M(this,vn);O(this,vn,t=>{if(!Jt&&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(){C(this,St)||this.setEventListener(C(this,vn))}onUnsubscribe(){var t;this.hasListeners()||((t=C(this,St))==null||t.call(this),O(this,St,void 0))}setEventListener(t){var n;O(this,vn,t),(n=C(this,St))==null||n.call(this),O(this,St,t(this.setOnline.bind(this)))}setOnline(t){C(this,yn)!==t&&(O(this,yn,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return C(this,yn)}},yn=new WeakMap,St=new WeakMap,vn=new WeakMap,ic),Gr=new Ep;function ds(){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 _p(e){return Math.min(1e3*2**e,3e4)}function nl(e){return(e??"online")==="online"?Gr.isOnline():!0}var rl=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Mo(e){return e instanceof rl}function ol(e){let t=!1,n=0,r=!1,o;const s=ds(),i=p=>{var y;r||(m(new rl(p)),(y=e.abort)==null||y.call(e))},a=()=>{t=!0},c=()=>{t=!1},l=()=>Gs.isFocused()&&(e.networkMode==="always"||Gr.isOnline())&&e.canRun(),f=()=>nl(e.networkMode)&&e.canRun(),h=p=>{var y;r||(r=!0,(y=e.onSuccess)==null||y.call(e,p),o==null||o(),s.resolve(p))},m=p=>{var y;r||(r=!0,(y=e.onError)==null||y.call(e,p),o==null||o(),s.reject(p))},g=()=>new Promise(p=>{var y;o=v=>{(r||l())&&p(v)},(y=e.onPause)==null||y.call(e)}).then(()=>{var p;o=void 0,r||(p=e.onContinue)==null||p.call(e)}),x=()=>{if(r)return;let p;const y=n===0?e.initialPromise:void 0;try{p=y??e.fn()}catch(v){p=Promise.reject(v)}Promise.resolve(p).then(h).catch(v=>{var T;if(r)return;const w=e.retry??(Jt?0:3),S=e.retryDelay??_p,_=typeof S=="function"?S(n,v):S,R=w===!0||typeof w=="number"&&n<w||typeof w=="function"&&w(n,v);if(t||!R){m(v);return}n++,(T=e.onFail)==null||T.call(e,n,v),wp(_).then(()=>l()?void 0:g()).then(()=>{t?m(v):x()})})};return{promise:s,cancel:i,continue:()=>(o==null||o(),s),cancelRetry:a,continueRetry:c,canStart:f,start:()=>(f()?x():g().then(x),s)}}var Rp=e=>setTimeout(e,0);function Tp(){let e=[],t=0,n=a=>{a()},r=a=>{a()},o=Rp;const s=a=>{t?e.push(a):o(()=>{n(a)})},i=()=>{const a=e;e=[],a.length&&o(()=>{r(()=>{a.forEach(c=>{n(c)})})})};return{batch:a=>{let c;t++;try{c=a()}finally{t--,t||i()}return c},batchCalls:a=>(...c)=>{s(()=>{a(...c)})},schedule:s,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{o=a}}}var he=Tp(),Vt,ac,sl=(ac=class{constructor(){M(this,Vt)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),as(this.gcTime)&&O(this,Vt,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Jt?1/0:5*60*1e3))}clearGcTimeout(){C(this,Vt)&&(clearTimeout(C(this,Vt)),O(this,Vt,void 0))}},Vt=new WeakMap,ac),bn,wn,Ne,qt,me,Jn,zt,ke,st,cc,Pp=(cc=class extends sl{constructor(t){super();M(this,ke);M(this,bn);M(this,wn);M(this,Ne);M(this,qt);M(this,me);M(this,Jn);M(this,zt);O(this,zt,!1),O(this,Jn,t.defaultOptions),this.setOptions(t.options),this.observers=[],O(this,qt,t.client),O(this,Ne,C(this,qt).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,O(this,bn,Ap(this.options)),this.state=t.state??C(this,bn),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=C(this,me))==null?void 0:t.promise}setOptions(t){this.options={...C(this,Jn),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&C(this,Ne).remove(this)}setData(t,n){const r=us(this.state.data,t,this.options);return H(this,ke,st).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){H(this,ke,st).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,o;const n=(r=C(this,me))==null?void 0:r.promise;return(o=C(this,me))==null||o.cancel(t),n?n.then(xe).catch(xe):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(C(this,bn))}isActive(){return this.observers.some(t=>Fe(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===zr||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Dt(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:!Jc(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=C(this,me))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=C(this,me))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),C(this,Ne).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(C(this,me)&&(C(this,zt)?C(this,me).cancel({revert:!0}):C(this,me).cancelRetry()),this.scheduleGc()),C(this,Ne).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||H(this,ke,st).call(this,{type:"invalidate"})}fetch(t,n){var l,f,h;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(C(this,me))return C(this,me).continueRetry(),C(this,me).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:()=>(O(this,zt,!0),r.signal)})},s=()=>{const m=el(this.options,n),x=(()=>{const p={client:C(this,qt),queryKey:this.queryKey,meta:this.meta};return o(p),p})();return O(this,zt,!1),this.options.persister?this.options.persister(m,x,this):m(x)},a=(()=>{const m={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:C(this,qt),state:this.state,fetchFn:s};return o(m),m})();(l=this.options.behavior)==null||l.onFetch(a,this),O(this,wn,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((f=a.fetchOptions)==null?void 0:f.meta))&&H(this,ke,st).call(this,{type:"fetch",meta:(h=a.fetchOptions)==null?void 0:h.meta});const c=m=>{var g,x,p,y;Mo(m)&&m.silent||H(this,ke,st).call(this,{type:"error",error:m}),Mo(m)||((x=(g=C(this,Ne).config).onError)==null||x.call(g,m,this),(y=(p=C(this,Ne).config).onSettled)==null||y.call(p,this.state.data,m,this)),this.scheduleGc()};return O(this,me,ol({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,abort:r.abort.bind(r),onSuccess:m=>{var g,x,p,y;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}`),c(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(m)}catch(v){c(v);return}(x=(g=C(this,Ne).config).onSuccess)==null||x.call(g,m,this),(y=(p=C(this,Ne).config).onSettled)==null||y.call(p,m,this.state.error,this),this.scheduleGc()},onError:c,onFail:(m,g)=>{H(this,ke,st).call(this,{type:"failed",failureCount:m,error:g})},onPause:()=>{H(this,ke,st).call(this,{type:"pause"})},onContinue:()=>{H(this,ke,st).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),C(this,me).start()}},bn=new WeakMap,wn=new WeakMap,Ne=new WeakMap,qt=new WeakMap,me=new WeakMap,Jn=new WeakMap,zt=new WeakMap,ke=new WeakSet,st=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,...il(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 Mo(o)&&o.revert&&C(this,wn)?{...C(this,wn),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),he.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),C(this,Ne).notify({query:this,type:"updated",action:t})})},cc);function il(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:nl(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function Ap(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 Ge,lc,Op=(lc=class extends Dn{constructor(t={}){super();M(this,Ge);this.config=t,O(this,Ge,new Map)}build(t,n,r){const o=n.queryKey,s=n.queryHash??zs(o,n);let i=this.get(s);return i||(i=new Pp({client:t,queryKey:o,queryHash:s,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(o)}),this.add(i)),i}add(t){C(this,Ge).has(t.queryHash)||(C(this,Ge).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=C(this,Ge).get(t.queryHash);n&&(t.destroy(),n===t&&C(this,Ge).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){he.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return C(this,Ge).get(t)}getAll(){return[...C(this,Ge).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>ra(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>ra(t,r)):n}notify(t){he.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){he.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){he.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},Ge=new WeakMap,lc),Ke,we,Gt,Qe,vt,uc,jp=(uc=class extends sl{constructor(t){super();M(this,Qe);M(this,Ke);M(this,we);M(this,Gt);this.mutationId=t.mutationId,O(this,we,t.mutationCache),O(this,Ke,[]),this.state=t.state||al(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){C(this,Ke).includes(t)||(C(this,Ke).push(t),this.clearGcTimeout(),C(this,we).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){O(this,Ke,C(this,Ke).filter(n=>n!==t)),this.scheduleGc(),C(this,we).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){C(this,Ke).length||(this.state.status==="pending"?this.scheduleGc():C(this,we).remove(this))}continue(){var t;return((t=C(this,Gt))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var s,i,a,c,l,f,h,m,g,x,p,y,v,w,S,_,R,T,P,D;const n=()=>{H(this,Qe,vt).call(this,{type:"continue"})};O(this,Gt,ol({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(I,L)=>{H(this,Qe,vt).call(this,{type:"failed",failureCount:I,error:L})},onPause:()=>{H(this,Qe,vt).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>C(this,we).canRun(this)}));const r=this.state.status==="pending",o=!C(this,Gt).canStart();try{if(r)n();else{H(this,Qe,vt).call(this,{type:"pending",variables:t,isPaused:o}),await((i=(s=C(this,we).config).onMutate)==null?void 0:i.call(s,t,this));const L=await((c=(a=this.options).onMutate)==null?void 0:c.call(a,t));L!==this.state.context&&H(this,Qe,vt).call(this,{type:"pending",context:L,variables:t,isPaused:o})}const I=await C(this,Gt).start();return await((f=(l=C(this,we).config).onSuccess)==null?void 0:f.call(l,I,t,this.state.context,this)),await((m=(h=this.options).onSuccess)==null?void 0:m.call(h,I,t,this.state.context)),await((x=(g=C(this,we).config).onSettled)==null?void 0:x.call(g,I,null,this.state.variables,this.state.context,this)),await((y=(p=this.options).onSettled)==null?void 0:y.call(p,I,null,t,this.state.context)),H(this,Qe,vt).call(this,{type:"success",data:I}),I}catch(I){try{throw await((w=(v=C(this,we).config).onError)==null?void 0:w.call(v,I,t,this.state.context,this)),await((_=(S=this.options).onError)==null?void 0:_.call(S,I,t,this.state.context)),await((T=(R=C(this,we).config).onSettled)==null?void 0:T.call(R,void 0,I,this.state.variables,this.state.context,this)),await((D=(P=this.options).onSettled)==null?void 0:D.call(P,void 0,I,t,this.state.context)),I}finally{H(this,Qe,vt).call(this,{type:"error",error:I})}}finally{C(this,we).runNext(this)}}},Ke=new WeakMap,we=new WeakMap,Gt=new WeakMap,Qe=new WeakSet,vt=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),he.batch(()=>{C(this,Ke).forEach(r=>{r.onMutationUpdate(t)}),C(this,we).notify({mutation:this,type:"updated",action:t})})},uc);function al(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var it,$e,er,dc,Ip=(dc=class extends Dn{constructor(t={}){super();M(this,it);M(this,$e);M(this,er);this.config=t,O(this,it,new Set),O(this,$e,new Map),O(this,er,0)}build(t,n,r){const o=new jp({mutationCache:this,mutationId:++fr(this,er)._,options:t.defaultMutationOptions(n),state:r});return this.add(o),o}add(t){C(this,it).add(t);const n=gr(t);if(typeof n=="string"){const r=C(this,$e).get(n);r?r.push(t):C(this,$e).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(C(this,it).delete(t)){const n=gr(t);if(typeof n=="string"){const r=C(this,$e).get(n);if(r)if(r.length>1){const o=r.indexOf(t);o!==-1&&r.splice(o,1)}else r[0]===t&&C(this,$e).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=gr(t);if(typeof n=="string"){const r=C(this,$e).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=gr(t);if(typeof n=="string"){const o=(r=C(this,$e).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(){he.batch(()=>{C(this,it).forEach(t=>{this.notify({type:"removed",mutation:t})}),C(this,it).clear(),C(this,$e).clear()})}getAll(){return Array.from(C(this,it))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>oa(n,r))}findAll(t={}){return this.getAll().filter(n=>oa(t,n))}notify(t){he.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return he.batch(()=>Promise.all(t.map(n=>n.continue().catch(xe))))}},it=new WeakMap,$e=new WeakMap,er=new WeakMap,dc);function gr(e){var t;return(t=e.options.scope)==null?void 0:t.id}function aa(e){return{onFetch:(t,n)=>{var f,h,m,g,x;const r=t.options,o=(m=(h=(f=t.fetchOptions)==null?void 0:f.meta)==null?void 0:h.fetchMore)==null?void 0:m.direction,s=((g=t.state.data)==null?void 0:g.pages)||[],i=((x=t.state.data)==null?void 0:x.pageParams)||[];let a={pages:[],pageParams:[]},c=0;const l=async()=>{let p=!1;const y=S=>{Object.defineProperty(S,"signal",{enumerable:!0,get:()=>(t.signal.aborted?p=!0:t.signal.addEventListener("abort",()=>{p=!0}),t.signal)})},v=el(t.options,t.fetchOptions),w=async(S,_,R)=>{if(p)return Promise.reject();if(_==null&&S.pages.length)return Promise.resolve(S);const P=(()=>{const B={client:t.client,queryKey:t.queryKey,pageParam:_,direction:R?"backward":"forward",meta:t.options.meta};return y(B),B})(),D=await v(P),{maxPages:I}=t.options,L=R?xp:Cp;return{pages:L(S.pages,D,I),pageParams:L(S.pageParams,_,I)}};if(o&&s.length){const S=o==="backward",_=S?Np:ca,R={pages:s,pageParams:i},T=_(r,R);a=await w(R,T,S)}else{const S=e??s.length;do{const _=c===0?i[0]??r.initialPageParam:ca(r,a);if(c>0&&_==null)break;a=await w(a,_),c++}while(c<S)}return a};t.options.persister?t.fetchFn=()=>{var p,y;return(y=(p=t.options).persister)==null?void 0:y.call(p,l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=l}}}function ca(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 Np(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 le,Et,_t,Cn,xn,Rt,Sn,En,fc,Dp=(fc=class{constructor(e={}){M(this,le);M(this,Et);M(this,_t);M(this,Cn);M(this,xn);M(this,Rt);M(this,Sn);M(this,En);O(this,le,e.queryCache||new Op),O(this,Et,e.mutationCache||new Ip),O(this,_t,e.defaultOptions||{}),O(this,Cn,new Map),O(this,xn,new Map),O(this,Rt,0)}mount(){fr(this,Rt)._++,C(this,Rt)===1&&(O(this,Sn,Gs.subscribe(async e=>{e&&(await this.resumePausedMutations(),C(this,le).onFocus())})),O(this,En,Gr.subscribe(async e=>{e&&(await this.resumePausedMutations(),C(this,le).onOnline())})))}unmount(){var e,t;fr(this,Rt)._--,C(this,Rt)===0&&((e=C(this,Sn))==null||e.call(this),O(this,Sn,void 0),(t=C(this,En))==null||t.call(this),O(this,En,void 0))}isFetching(e){return C(this,le).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return C(this,Et).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=C(this,le).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=C(this,le).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(Dt(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return C(this,le).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=C(this,le).get(r.queryHash),s=o==null?void 0:o.state.data,i=bp(t,s);if(i!==void 0)return C(this,le).build(this,r).setData(i,{...n,manual:!0})}setQueriesData(e,t,n){return he.batch(()=>C(this,le).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=C(this,le).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=C(this,le);he.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=C(this,le);return he.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=he.batch(()=>C(this,le).findAll(e).map(o=>o.cancel(n)));return Promise.all(r).then(xe).catch(xe)}invalidateQueries(e,t={}){return he.batch(()=>(C(this,le).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=he.batch(()=>C(this,le).findAll(e).filter(o=>!o.isDisabled()&&!o.isStatic()).map(o=>{let s=o.fetch(void 0,n);return n.throwOnError||(s=s.catch(xe)),o.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(r).then(xe)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=C(this,le).build(this,t);return n.isStaleByTime(Dt(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(xe).catch(xe)}fetchInfiniteQuery(e){return e.behavior=aa(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(xe).catch(xe)}ensureInfiniteQueryData(e){return e.behavior=aa(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Gr.isOnline()?C(this,Et).resumePausedMutations():Promise.resolve()}getQueryCache(){return C(this,le)}getMutationCache(){return C(this,Et)}getDefaultOptions(){return C(this,_t)}setDefaultOptions(e){O(this,_t,e)}setQueryDefaults(e,t){C(this,Cn).set(en(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...C(this,Cn).values()],n={};return t.forEach(r=>{Qn(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){C(this,xn).set(en(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...C(this,xn).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={...C(this,_t).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=zs(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===zr&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...C(this,_t).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){C(this,le).clear(),C(this,Et).clear()}},le=new WeakMap,Et=new WeakMap,_t=new WeakMap,Cn=new WeakMap,xn=new WeakMap,Rt=new WeakMap,Sn=new WeakMap,En=new WeakMap,fc),_e,G,tr,Ce,Kt,_n,Tt,Pt,nr,Rn,Tn,Qt,Yt,At,Pn,ne,Vn,fs,hs,ps,ms,gs,ys,vs,cl,hc,Lp=(hc=class extends Dn{constructor(t,n){super();M(this,ne);M(this,_e);M(this,G);M(this,tr);M(this,Ce);M(this,Kt);M(this,_n);M(this,Tt);M(this,Pt);M(this,nr);M(this,Rn);M(this,Tn);M(this,Qt);M(this,Yt);M(this,At);M(this,Pn,new Set);this.options=n,O(this,_e,t),O(this,Pt,null),O(this,Tt,ds()),this.options.experimental_prefetchInRender||C(this,Tt).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&&(C(this,G).addObserver(this),la(C(this,G),this.options)?H(this,ne,Vn).call(this):this.updateResult(),H(this,ne,ms).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return bs(C(this,G),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return bs(C(this,G),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,H(this,ne,gs).call(this),H(this,ne,ys).call(this),C(this,G).removeObserver(this)}setOptions(t){const n=this.options,r=C(this,G);if(this.options=C(this,_e).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Fe(this.options.enabled,C(this,G))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");H(this,ne,vs).call(this),C(this,G).setOptions(this.options),n._defaulted&&!qr(this.options,n)&&C(this,_e).getQueryCache().notify({type:"observerOptionsUpdated",query:C(this,G),observer:this});const o=this.hasListeners();o&&ua(C(this,G),r,this.options,n)&&H(this,ne,Vn).call(this),this.updateResult(),o&&(C(this,G)!==r||Fe(this.options.enabled,C(this,G))!==Fe(n.enabled,C(this,G))||Dt(this.options.staleTime,C(this,G))!==Dt(n.staleTime,C(this,G)))&&H(this,ne,fs).call(this);const s=H(this,ne,hs).call(this);o&&(C(this,G)!==r||Fe(this.options.enabled,C(this,G))!==Fe(n.enabled,C(this,G))||s!==C(this,At))&&H(this,ne,ps).call(this,s)}getOptimisticResult(t){const n=C(this,_e).getQueryCache().build(C(this,_e),t),r=this.createResult(n,t);return kp(this,r)&&(O(this,Ce,r),O(this,_n,this.options),O(this,Kt,C(this,G).state)),r}getCurrentResult(){return C(this,Ce)}trackResult(t,n){return new Proxy(t,{get:(r,o)=>(this.trackProp(o),n==null||n(o),Reflect.get(r,o))})}trackProp(t){C(this,Pn).add(t)}getCurrentQuery(){return C(this,G)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=C(this,_e).defaultQueryOptions(t),r=C(this,_e).getQueryCache().build(C(this,_e),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return H(this,ne,Vn).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),C(this,Ce)))}createResult(t,n){var I;const r=C(this,G),o=this.options,s=C(this,Ce),i=C(this,Kt),a=C(this,_n),l=t!==r?t.state:C(this,tr),{state:f}=t;let h={...f},m=!1,g;if(n._optimisticResults){const L=this.hasListeners(),B=!L&&la(t,n),U=L&&ua(t,r,n,o);(B||U)&&(h={...h,...il(f.data,t.options)}),n._optimisticResults==="isRestoring"&&(h.fetchStatus="idle")}let{error:x,errorUpdatedAt:p,status:y}=h;g=h.data;let v=!1;if(n.placeholderData!==void 0&&g===void 0&&y==="pending"){let L;s!=null&&s.isPlaceholderData&&n.placeholderData===(a==null?void 0:a.placeholderData)?(L=s.data,v=!0):L=typeof n.placeholderData=="function"?n.placeholderData((I=C(this,Tn))==null?void 0:I.state.data,C(this,Tn)):n.placeholderData,L!==void 0&&(y="success",g=us(s==null?void 0:s.data,L,n),m=!0)}if(n.select&&g!==void 0&&!v)if(s&&g===(i==null?void 0:i.data)&&n.select===C(this,nr))g=C(this,Rn);else try{O(this,nr,n.select),g=n.select(g),g=us(s==null?void 0:s.data,g,n),O(this,Rn,g),O(this,Pt,null)}catch(L){O(this,Pt,L)}C(this,Pt)&&(x=C(this,Pt),g=C(this,Rn),p=Date.now(),y="error");const w=h.fetchStatus==="fetching",S=y==="pending",_=y==="error",R=S&&w,T=g!==void 0,D={status:y,fetchStatus:h.fetchStatus,isPending:S,isSuccess:y==="success",isError:_,isInitialLoading:R,isLoading:R,data:g,dataUpdatedAt:h.dataUpdatedAt,error:x,errorUpdatedAt:p,failureCount:h.fetchFailureCount,failureReason:h.fetchFailureReason,errorUpdateCount:h.errorUpdateCount,isFetched:h.dataUpdateCount>0||h.errorUpdateCount>0,isFetchedAfterMount:h.dataUpdateCount>l.dataUpdateCount||h.errorUpdateCount>l.errorUpdateCount,isFetching:w,isRefetching:w&&!S,isLoadingError:_&&!T,isPaused:h.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:_&&T,isStale:Ks(t,n),refetch:this.refetch,promise:C(this,Tt)};if(this.options.experimental_prefetchInRender){const L=W=>{D.status==="error"?W.reject(D.error):D.data!==void 0&&W.resolve(D.data)},B=()=>{const W=O(this,Tt,D.promise=ds());L(W)},U=C(this,Tt);switch(U.status){case"pending":t.queryHash===r.queryHash&&L(U);break;case"fulfilled":(D.status==="error"||D.data!==U.value)&&B();break;case"rejected":(D.status!=="error"||D.error!==U.reason)&&B();break}}return D}updateResult(){const t=C(this,Ce),n=this.createResult(C(this,G),this.options);if(O(this,Kt,C(this,G).state),O(this,_n,this.options),C(this,Kt).data!==void 0&&O(this,Tn,C(this,G)),qr(n,t))return;O(this,Ce,n);const r=()=>{if(!t)return!0;const{notifyOnChangeProps:o}=this.options,s=typeof o=="function"?o():o;if(s==="all"||!s&&!C(this,Pn).size)return!0;const i=new Set(s??C(this,Pn));return this.options.throwOnError&&i.add("error"),Object.keys(C(this,Ce)).some(a=>{const c=a;return C(this,Ce)[c]!==t[c]&&i.has(c)})};H(this,ne,cl).call(this,{listeners:r()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&H(this,ne,ms).call(this)}},_e=new WeakMap,G=new WeakMap,tr=new WeakMap,Ce=new WeakMap,Kt=new WeakMap,_n=new WeakMap,Tt=new WeakMap,Pt=new WeakMap,nr=new WeakMap,Rn=new WeakMap,Tn=new WeakMap,Qt=new WeakMap,Yt=new WeakMap,At=new WeakMap,Pn=new WeakMap,ne=new WeakSet,Vn=function(t){H(this,ne,vs).call(this);let n=C(this,G).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(xe)),n},fs=function(){H(this,ne,gs).call(this);const t=Dt(this.options.staleTime,C(this,G));if(Jt||C(this,Ce).isStale||!as(t))return;const r=Jc(C(this,Ce).dataUpdatedAt,t)+1;O(this,Qt,setTimeout(()=>{C(this,Ce).isStale||this.updateResult()},r))},hs=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(C(this,G)):this.options.refetchInterval)??!1},ps=function(t){H(this,ne,ys).call(this),O(this,At,t),!(Jt||Fe(this.options.enabled,C(this,G))===!1||!as(C(this,At))||C(this,At)===0)&&O(this,Yt,setInterval(()=>{(this.options.refetchIntervalInBackground||Gs.isFocused())&&H(this,ne,Vn).call(this)},C(this,At)))},ms=function(){H(this,ne,fs).call(this),H(this,ne,ps).call(this,H(this,ne,hs).call(this))},gs=function(){C(this,Qt)&&(clearTimeout(C(this,Qt)),O(this,Qt,void 0))},ys=function(){C(this,Yt)&&(clearInterval(C(this,Yt)),O(this,Yt,void 0))},vs=function(){const t=C(this,_e).getQueryCache().build(C(this,_e),this.options);if(t===C(this,G))return;const n=C(this,G);O(this,G,t),O(this,tr,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},cl=function(t){he.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(C(this,Ce))}),C(this,_e).getQueryCache().notify({query:C(this,G),type:"observerResultsUpdated"})})},hc);function Mp(e,t){return Fe(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function la(e,t){return Mp(e,t)||e.state.data!==void 0&&bs(e,t,t.refetchOnMount)}function bs(e,t,n){if(Fe(t.enabled,e)!==!1&&Dt(t.staleTime,e)!=="static"){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&Ks(e,t)}return!1}function ua(e,t,n,r){return(e!==t||Fe(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&Ks(e,n)}function Ks(e,t){return Fe(t.enabled,e)!==!1&&e.isStaleByTime(Dt(t.staleTime,e))}function kp(e,t){return!qr(e.getCurrentResult(),t)}var Ot,jt,Re,at,lt,$r,ws,pc,$p=(pc=class extends Dn{constructor(n,r){super();M(this,lt);M(this,Ot);M(this,jt);M(this,Re);M(this,at);O(this,Ot,n),this.setOptions(r),this.bindMethods(),H(this,lt,$r).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=C(this,Ot).defaultMutationOptions(n),qr(this.options,r)||C(this,Ot).getMutationCache().notify({type:"observerOptionsUpdated",mutation:C(this,Re),observer:this}),r!=null&&r.mutationKey&&this.options.mutationKey&&en(r.mutationKey)!==en(this.options.mutationKey)?this.reset():((o=C(this,Re))==null?void 0:o.state.status)==="pending"&&C(this,Re).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=C(this,Re))==null||n.removeObserver(this)}onMutationUpdate(n){H(this,lt,$r).call(this),H(this,lt,ws).call(this,n)}getCurrentResult(){return C(this,jt)}reset(){var n;(n=C(this,Re))==null||n.removeObserver(this),O(this,Re,void 0),H(this,lt,$r).call(this),H(this,lt,ws).call(this)}mutate(n,r){var o;return O(this,at,r),(o=C(this,Re))==null||o.removeObserver(this),O(this,Re,C(this,Ot).getMutationCache().build(C(this,Ot),this.options)),C(this,Re).addObserver(this),C(this,Re).execute(n)}},Ot=new WeakMap,jt=new WeakMap,Re=new WeakMap,at=new WeakMap,lt=new WeakSet,$r=function(){var r;const n=((r=C(this,Re))==null?void 0:r.state)??al();O(this,jt,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},ws=function(n){he.batch(()=>{var r,o,s,i,a,c,l,f;if(C(this,at)&&this.hasListeners()){const h=C(this,jt).variables,m=C(this,jt).context;(n==null?void 0:n.type)==="success"?((o=(r=C(this,at)).onSuccess)==null||o.call(r,n.data,h,m),(i=(s=C(this,at)).onSettled)==null||i.call(s,n.data,null,h,m)):(n==null?void 0:n.type)==="error"&&((c=(a=C(this,at)).onError)==null||c.call(a,n.error,h,m),(f=(l=C(this,at)).onSettled)==null||f.call(l,void 0,n.error,h,m))}this.listeners.forEach(h=>{h(C(this,jt))})})},pc),ll=d.createContext(void 0),Qs=e=>{const t=d.useContext(ll);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Fp=({client:e,children:t})=>(d.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),u.jsx(ll.Provider,{value:e,children:t})),ul=d.createContext(!1),Bp=()=>d.useContext(ul);ul.Provider;function Up(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var Wp=d.createContext(Up()),Hp=()=>d.useContext(Wp),Vp=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},qp=e=>{d.useEffect(()=>{e.clearReset()},[e])},zp=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:o})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(o&&e.data===void 0||tl(n,[e.error,r])),Gp=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))}},Kp=(e,t)=>e.isLoading&&e.isFetching&&!t,Qp=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,da=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function Yp(e,t,n){var h,m,g,x,p;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=Bp(),o=Hp(),s=Qs(),i=s.defaultQueryOptions(e);(m=(h=s.getDefaultOptions().queries)==null?void 0:h._experimental_beforeQuery)==null||m.call(h,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",Gp(i),Vp(i,o),qp(o);const a=!s.getQueryCache().get(i.queryHash),[c]=d.useState(()=>new t(s,i)),l=c.getOptimisticResult(i),f=!r&&e.subscribed!==!1;if(d.useSyncExternalStore(d.useCallback(y=>{const v=f?c.subscribe(he.batchCalls(y)):xe;return c.updateResult(),v},[c,f]),()=>c.getCurrentResult(),()=>c.getCurrentResult()),d.useEffect(()=>{c.setOptions(i)},[i,c]),Qp(i,l))throw da(i,c,o);if(zp({result:l,errorResetBoundary:o,throwOnError:i.throwOnError,query:s.getQueryCache().get(i.queryHash),suspense:i.suspense}))throw l.error;if((x=(g=s.getDefaultOptions().queries)==null?void 0:g._experimental_afterQuery)==null||x.call(g,i,l),i.experimental_prefetchInRender&&!Jt&&Kp(l,r)){const y=a?da(i,c,o):(p=s.getQueryCache().get(i.queryHash))==null?void 0:p.promise;y==null||y.catch(xe).finally(()=>{c.updateResult()})}return i.notifyOnChangeProps?l:c.trackResult(l)}function fa(e,t){return Yp(e,Lp)}function yr(e,t){const n=Qs(),[r]=d.useState(()=>new $p(n,e));d.useEffect(()=>{r.setOptions(e)},[r,e]);const o=d.useSyncExternalStore(d.useCallback(i=>r.subscribe(he.batchCalls(i)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),s=d.useCallback((i,a)=>{r.mutate(i,a).catch(xe)},[r]);if(o.error&&tl(r.options.throwOnError,[o.error]))throw o.error;return{...o,mutate:s,mutateAsync:o.mutate}}const vr={STALE_TIME:1e3*60*5,GC_TIME:1e3*60*10,RETRY_COUNT:1,RETRY_DELAY:1e3},ha={refetchOnWindowFocus:!1,refetchOnReconnect:!1,refetchOnMount:!1,staleTime:vr.STALE_TIME,gcTime:vr.GC_TIME,retry:vr.RETRY_COUNT,retryDelay:vr.RETRY_DELAY,enable:!0},br=e=>e instanceof Error?e.message:String(e),dl=(e,t,n)=>{const r=Qs(),{notify:o}=qs(),{createFn:s,readFn:i,readByIdFn:a,updateFn:c,deleteFn:l,partialUpdateFn:f}=n,h=()=>{r.invalidateQueries({queryKey:[e]})},m=(_,R,T,P)=>o(P!=null&&P.overrideSuccessMessage?P==null?void 0:P.overrideSuccessMessage(_,R):T,"success"),g=(_,R,T,P)=>o(P!=null&&P.overrideErrorMessage?P==null?void 0:P.overrideErrorMessage(_,R):T,"error");return{useCreate:_=>yr({mutationFn:R=>s(R),onSuccess:R=>{h(),m(t,R,`${t} created successfully`,_)},onError:R=>{g(t,R,`Error creating ${t}: ${br(R)}`,_)}}),useReadQuery:_=>fa({queryKey:[e],queryFn:i,...ha,..._}),useReadByIdQuery:(_,R)=>fa({queryKey:[e,_],queryFn:()=>a(_),...ha,enabled:!!_,...R}),useUpdate:_=>yr({mutationFn:({id:R,data:T})=>c(R,T),onSuccess:R=>{h(),m(t,R,`${t} updated successfully`,_)},onError:R=>{g(t,R,`Error updating ${t}: ${br(R)}`,_)}}),usePartialUpdate:_=>f&&yr({mutationFn:({id:R,data:T})=>f(R,T),onSuccess:R=>{h(),m(t,R,`${t} updated successfully`,_)},onError:R=>{g(t,R,`Error updating ${t}: ${br(R)}`,_)}}),useDelete:_=>yr({mutationFn:R=>l(R),onSuccess:()=>{h(),m(t,null,`${t} deleted successfully`,_)},onError:R=>{g(t,R,`Error deleting ${t}: ${br(R)}`,_)}}),invalidateQueries:h}},Zp=(e,t)=>dl(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())}),Xp={SINGLE_TENANT:"single-tenant"},Jp={COOKIE:"cookie"},ko="tenant",pa="tenant",ma="tenant",e1=Xp.SINGLE_TENANT,t1=Jp.COOKIE,n1={mode:e1,clientSideMode:t1,tenantIDPProvisioningStrategy:"none"};class r1{setTenant(t,n){const r=new URL(window.location.href);r.searchParams.set(pa,t.name),window.location.href=r.toString()}getCurrentTenantName(){const t=new URL(window.location.href);return new URLSearchParams(t.search).get(pa)}}class o1{setTenant(t,n){sessionStorage.setItem(ma,t.name),window.location.reload()}getCurrentTenantName(){return sessionStorage.getItem(ma)}}/*! js-cookie v3.0.5 | MIT */function wr(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 s1={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 Cs(e,t){function n(o,s,i){if(!(typeof document>"u")){i=wr({},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 c in i)i[c]&&(a+="; "+c,i[c]!==!0&&(a+="="+i[c].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 c=s[a].split("="),l=c.slice(1).join("=");try{var f=decodeURIComponent(c[0]);if(i[f]=e.read(l,f),o===f)break}catch{}}return o?i[o]:i}}return Object.create({set:n,get:r,remove:function(o,s){n(o,"",wr({},s,{expires:-1}))},withAttributes:function(o){return Cs(this.converter,wr({},this.attributes,o))},withConverter:function(o){return Cs(wr({},this.converter,o),this.attributes)}},{attributes:{value:Object.freeze(t)},converter:{value:Object.freeze(e)}})}var $o=Cs(s1,{path:"/"});class i1{setTenant(t,n){t?$o.set(ko,t.name):$o.remove(ko),window.location.reload()}getCurrentTenantName(){return $o.get(ko)}}class a1{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 l;const r=(l=n.urlPatterns)==null?void 0:l.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),c=s?`${s}.${a}`:a;o.hostname=c,window.location.href=o.toString()}getCurrentTenantName(){const t=window.location.hostname;return this.extractSubdomain(t)||null}}const ga={queryParams:new r1,sessionStorage:new o1,cookie:new i1,subdomain:new a1},c1=e=>{const t=ga[e.clientSideMode];if(!t)throw new Error(`Client side tenant mode '${e.clientSideMode}' is not supported ${JSON.stringify({strategies:ga},null,2)}`);return t},l1=(e,t,n)=>{const r=t.find(s=>s.name===n);if(!r)throw Error("No tenant permission");return c1(e).setTenant(r,e),r},u1=()=>{const[e,t]=In(),{tenants:n=[],currentTenant:r,tenantConfig:o=n1}=e,s=E.useCallback(i=>{const a=l1(o,n,i);t({...e,currentTenant:a})},[o,e]);return{tenants:n,currentTenant:r,tenantConfig:o,selectTenant:s}};function d1(e){if(!e.ok)throw console.error(e),new Error(e.statusText)}async function Cr(e,t,n,r){const o=await e(`/user-states/${encodeURIComponent(t)}/${encodeURIComponent(n)}`,r);return d1(o),o}class xr{static async get(t,n,r){const s=await Cr(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 Cr(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 Cr(t,n,r,s)).json()}static async delete(t,n,r){return await Cr(t,n,r,{method:"DELETE",headers:{"Content-Type":"application/json"}}),null}}const f1=e=>{const t=Vs("@bluealba/pae-nestjs-gateway-service"),n=Mc();if(!n)throw new Error("You must call the useUserState hook within a PAE application.");const[r,o]=E.useState(null),[s,i]=E.useState(!1),[a,c]=E.useState(!1),[l,f]=E.useState(null),h=(w,S)=>E.useCallback(async({newValue:_,shouldThrowError:R}={})=>{try{c(!0),f(null);const T=await w(t,n,e,_);return o(T),T?T.value:null}catch(T){if(f(T==null?void 0:T.message),console.error(`Failed to ${S} ${e}:`,T),R)throw T;return null}finally{c(!1)}},[t,n,e]),m=h(xr.get,"fetch"),g=h(xr.create,"create"),x=h(xr.update,"update"),p=h(xr.delete,"delete"),y=E.useCallback(async()=>{try{await m()}finally{i(!0)}},[m]);E.useEffect(()=>{y()},[y]);const v=E.useCallback(async(w,S=!1)=>r==null?await g({newValue:w,shouldThrowError:S}):await x({newValue:w,shouldThrowError:S}),[r,g,x]);return{value:r?r.value:null,hasFetched:s,loading:a,error:l,setValue:v,createValue:g,updateValue:x,deleteValue:p}},ya="single-spa:app-change";function h1(){const[e,t]=E.useState(va());return E.useEffect(()=>{const n=()=>{t(va())};return window.addEventListener(ya,n),()=>{window.removeEventListener(ya,n)}},[]),e}function va(){return Nr.getAppNames().reduce((t,n)=>(Nr.getAppStatus(n)?t[n]=Nr.getAppStatus(n):t[n]="NOT_LOADED",t),{})}function Ys(e){const n=h1()[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 p1(e){const{url:t,method:n,formData:r,onProgress:o,signal:s}=e;return new Promise((i,a)=>{const c=new XMLHttpRequest;c.withCredentials=!0,c.upload.onprogress=l=>{l.lengthComputable&&o&&o(Math.round(l.loaded/l.total*100))},c.onload=()=>{if(c.status>=400){let l="Upload failed";try{l=JSON.parse(c.responseText).message??l}catch{}const f=new Error(l);f.status=c.status,a(f);return}try{const l=JSON.parse(c.responseText);i(l)}catch{a(new Error("Failed to parse response JSON"))}},c.onerror=()=>{a(new Error("Upload failed due to a network error"))},s&&s.addEventListener("abort",()=>c.abort()),c.open(n,t),c.send(r)})}const Un="File storage is disabled on this platform";async function Sr(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 m1(){const[{fileStorageEnabled:e}]=In(),t=E.useCallback((i,a)=>{if(!e)return Promise.reject(new Error(Un));const c=new FormData;return c.append("file",i),(a==null?void 0:a.isPublic)!==void 0&&c.append("isPublic",String(a.isPublic)),(a==null?void 0:a.description)!==void 0&&c.append("description",a.description),(a==null?void 0:a.metadata)!==void 0&&c.append("metadata",JSON.stringify(a.metadata)),p1({url:"/files",method:"POST",formData:c,onProgress:a==null?void 0:a.onProgress,signal:a==null?void 0:a.signal})},[e]),n=E.useCallback(async(i,a)=>{if(!e)return Promise.reject(new Error(Un));const c=new FormData;a.originalName!==void 0&&c.append("originalName",a.originalName),a.isPublic!==void 0&&c.append("isPublic",String(a.isPublic)),a.description!==void 0&&c.append("description",a.description),a.metadata!==void 0&&c.append("metadata",JSON.stringify(a.metadata));const l=await fetch(`/files/${i}`,{method:"PATCH",headers:{Accept:"application/json"},body:c});return l.ok||await Sr(l),l.json()},[e]),r=E.useCallback(async i=>{if(!e)return Promise.reject(new Error(Un));const a=await fetch(`/files/${i}`,{method:"DELETE",headers:{Accept:"application/json"}});a.ok||await Sr(a)},[e]),o=E.useCallback(async i=>{if(!e)return Promise.reject(new Error(Un));const a=await fetch(`/files/${i}/download`);a.ok||await Sr(a);const c=await a.blob(),l=URL.createObjectURL(c);let f=`file-${i}`;const h=a.headers.get("Content-Disposition");if(h){const g=h.match(/attachment;\s*filename="([^"]+)"/);g&&(f=g[1])}const m=document.createElement("a");m.href=l,m.download=f,document.body.appendChild(m),m.click(),document.body.removeChild(m),URL.revokeObjectURL(l)},[e]),s=E.useCallback(async i=>{if(!e)return Promise.reject(new Error(Un));const a=await fetch(`/files/${i}/download`);a.ok||await Sr(a);const c=await a.blob();return URL.createObjectURL(c)},[e]);return{isEnabled:e,upload:t,updateMetadata:n,remove:r,download:o,getPreviewUrl:s}}const fl="__PAE_EXTENSION_POINT_REACT_CONTENT_EMPTY__",g1=({module:e,point:t,children:n})=>(Bc(e,t,n??fl),null),hl=({name:e,children:t,...n})=>{const r=Fc(e);if(r===fl)return null;if(!r)return u.jsx(u.Fragment,{children:t??null});if(y1(r)){const o=r;return u.jsx(o,{...n})}else return r},y1=e=>typeof e=="function",v1=(e,t)=>{const n=r=>(t=t||e.displayName||e.name||"?",u.jsx(hl,{name:t,...r,children:u.jsx(e,{...r})}));return n.displayName=`extensionPoint(${t})`,n},pl=({appName:e})=>u.jsx("div",{children:u.jsxs("p",{children:["Loading ",e,"..."]})});pl.displayName="BaseLoading";const ml=({appName:e})=>u.jsxs("div",{children:[u.jsx("p",{children:"Something went wrong..."}),u.jsxs("p",{children:["Failed to load ",e]})]});ml.displayName="BaseError";const b1={display:"flex",flexDirection:"column",flex:1},gl=E.forwardRef((e,t)=>u.jsx("div",{ref:t,style:b1,...e}));gl.displayName="BaseContainer";const w1="pae-app:",yl=E.forwardRef(({appName:e,LoadingComponent:t=pl,ErrorComponent:n=ml,ContainerComponent:r=gl,...o},s)=>{const i=Ys(e);return u.jsxs(r,{ref:s,...o,id:`${w1}${e}`,children:[i.isLoading&&u.jsx(t,{appName:e}),i.isBroken&&u.jsx(n,{appName:e})]})});yl.displayName="ModulePlaceHolder";const Zs=({operations:e,children:t,forbiddenContent:n})=>{var o;const{hasAccess:r}=or();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 u.jsx(s,{operations:e})}else return n({operations:e});return E.isValidElement(n)?n:null}return t};Zs.displayName="Authorized";const C1=({eventName:e,listener:t})=>(Uc(e,t),null),x1=()=>u.jsx("svg",{"aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24",children:u.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"})}),vl=({applicationName:e})=>{const t=Dc(e);if(t)if(typeof t=="function"){const n=t;return u.jsx(n,{})}else return t;return u.jsx(x1,{})};vl.displayName="ApplicationIcon";const bl=()=>u.jsx("svg",{width:"28",height:"28",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.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"})});bl.displayName="DarkModeIcon";const wl=()=>u.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:u.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"})});wl.displayName="LightModeIcon";const S1="container__zBqbk",E1="expanded__EbsIr",_1="label__cdMnm",Fo={container:S1,expanded:E1,label:_1};function Cl(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=Cl(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function N(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=Cl(e))&&(r&&(r+=" "),r+=t);return r}const R1=e=>e.toLowerCase().trim().split(" ").join("-"),T1=e=>`${R1(e)}-theme`,xl=()=>{const{platformName:e="Platform"}=Tc(),t=T1(e),[n,r]=E.useState(()=>{const s=localStorage.getItem(t);return s==="light"||s==="dark"?s:"light"}),o=s=>{localStorage.setItem(t,s),r(s)};return E.useEffect(()=>{document.documentElement.setAttribute("data-theme",n)},[n]),{theme:n,setTheme:o}},P1="spinner__fakUN",A1="spinner-rotation__wUmPV",O1="button__8FA9H",j1="button--contained-primary__stkTx",I1="button--outlined-primary__KZ1ww",N1="button--text-primary__GLTfm",D1="button--contained-danger__L9ehT",L1="button--outlined-danger__eoYLd",M1="button--text-danger__Sw-ha",k1="icon__--umH",Er={spinner:P1,"spinner-rotation":"spinner-rotation__wUmPV",spinnerRotation:A1,button:O1,"button--contained-primary":"button--contained-primary__stkTx",buttonContainedPrimary:j1,"button--outlined-primary":"button--outlined-primary__KZ1ww",buttonOutlinedPrimary:I1,"button--text-primary":"button--text-primary__GLTfm",buttonTextPrimary:N1,"button--contained-danger":"button--contained-danger__L9ehT",buttonContainedDanger:D1,"button--outlined-danger":"button--outlined-danger__eoYLd",buttonOutlinedDanger:L1,"button--text-danger":"button--text-danger__Sw-ha",buttonTextDanger:M1,icon:k1},Kr=E.forwardRef(({variant:e="contained",colorScheme:t="primary",loading:n=!1,IconComponent:r,className:o,children:s,...i},a)=>{const c=N(Er.button,Er[`button--${e}-${t}`],o);return u.jsxs("button",{ref:a,className:c,...i,children:[n?u.jsx("div",{className:Er.spinner}):r&&u.jsx(r,{className:Er.icon}),s]})});Kr.displayName="Button";const $1="Badges__5jpum",F1="Badges__5jpum",B1="Badge__95MWM",U1="Badge__95MWM",W1="Badge--primary__Rx-bS",H1="Badge--secondary__d92bT",V1="Badge--success__Kdo98",q1="Badge--warning__bf-Nn",z1="Badge--danger__HTj39",G1="Badge--small__y93Pj",K1="Badge--regular__aT5AL",Q1="Badge--large__wORCH",Fr={Badges:$1,badges:F1,Badge:B1,badge:U1,"Badge--primary":"Badge--primary__Rx-bS",badgePrimary:W1,"Badge--secondary":"Badge--secondary__d92bT",badgeSecondary:H1,"Badge--success":"Badge--success__Kdo98",badgeSuccess:V1,"Badge--warning":"Badge--warning__bf-Nn",badgeWarning:q1,"Badge--danger":"Badge--danger__HTj39",badgeDanger:z1,"Badge--small":"Badge--small__y93Pj",badgeSmall:G1,"Badge--regular":"Badge--regular__aT5AL",badgeRegular:K1,"Badge--large":"Badge--large__wORCH",badgeLarge:Q1},xs={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 xs)Object.freeze(xs[e]);const ba=Object.freeze(xs);var wa={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};function Y1(e){var f,h;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(),ba[e])n=ba[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 c=t[1];o=c.replace(/a$/,"");var l=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(wa[m]!==void 0)return wa[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>l?n.pop():1}else/[0-9](?:\s|\/|,)/.test(e)&&(n=e.match(/([0-9]+)/g).map(function(m){return parseFloat(m)}),o=((h=(f=e.match(/([a-z])/ig))==null?void 0:f.join(""))==null?void 0:h.toLowerCase())||"rgb");return{space:o,values:n,alpha:r}}const Z1=(e,t)=>{const{space:n,values:r}=Y1(e);return n[0]==="h"?`${n}a(${r[0]}, ${r[1]}%, ${r[2]}%, ${t})`:`${n}a(${r}, ${t})`},Xs=E.forwardRef(({children:e,color:t,className:n,customColor:r,size:o="small",style:s,...i},a)=>{const c=r?{color:r,background:Z1(r,.1)}:{},l=N(Fr.Badge,Fr[`Badge--${o}`],{[Fr[`Badge--${t}`]]:!!t},n);return u.jsx("span",{ref:a,className:l,style:{...s,...c},...i,children:e})});Xs.displayName="Badge";const Js=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Fr.Badges,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Js.displayName="Badges";const Sl=({size:e=24,color:t="currentColor",strokeWidth:n=2,className:r,style:o,...s})=>u.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:[u.jsx("rect",{x:"8",y:"2",width:"8",height:"4",rx:"1",ry:"1"}),u.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"})]}),El=({size:e=24,color:t="currentColor",strokeWidth:n=2,className:r,style:o,...s})=>u.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:[u.jsx("rect",{x:"8",y:"2",width:"8",height:"4",rx:"1",ry:"1"}),u.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"}),u.jsx("path",{d:"m9 12 2 2 4-4"})]}),X1="CopyToClipboardButton__2Nd2m",J1={CopyToClipboardButton:X1},em=({content:e})=>{const[t,n]=tm(),{notify:r}=qs(),o=t?El:Sl,s=E.useCallback(async()=>{await n(e)&&r("Copied to the Clipboard !","success")},[e,r]);return u.jsx(o,{className:J1.CopyToClipboardButton,size:18,onClick:s})},tm=()=>{const[e,t]=E.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}}]},nm="FieldGroup__Q2JCV",rm="FieldGroup__Q2JCV",om="FieldGroup--horizontal__kpfL1",sm="FieldGroup--vertical__FLo-Q",Ca={FieldGroup:nm,fieldGroup:rm,"FieldGroup--horizontal":"FieldGroup--horizontal__kpfL1",fieldGroupHorizontal:om,"FieldGroup--vertical":"FieldGroup--vertical__FLo-Q",fieldGroupVertical:sm},_l=E.forwardRef(({children:e,className:t,orientation:n="vertical",...r},o)=>{const s=N(Ca.FieldGroup,Ca[`FieldGroup--${n}`],t);return u.jsx("div",{ref:o,className:s,...r,children:e})});_l.displayName="FieldGroup";const im="Input__uS0sb",xa={Input:im,Error:"Error__-DQpw"},fo=E.forwardRef(({className:e,error:t,...n},r)=>{const o=N(xa.Input,t&&xa.Error,e);return u.jsx("input",{ref:r,className:o,...n})});fo.displayName="Input";const am={Error:"Error__N4OP5"},Rl=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(am.Error,t);return u.jsx("span",{ref:r,className:o,...n,children:e})});Rl.displayName="InputError";const cm="Label__VYUvW",Sa={Label:cm,Error:"Error__Eu6DI"},Tl=E.forwardRef(({children:e,className:t,error:n,...r},o)=>{const s=N(Sa.Label,n&&Sa.Error,t);return u.jsx("label",{ref:o,className:s,...r,children:e})});Tl.displayName="Label";const lm="Select__giqpe",um="Chevron__YvhBd",Ss={Select:lm,Chevron:um},Pl=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Ss.Option,t);return u.jsx("option",{ref:r,className:o,...n,children:e})});Pl.displayName="Option";const ei=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Ss.Select,t);return u.jsxs("div",{className:o,children:[u.jsx("select",{ref:r,...n,children:e}),u.jsx("div",{className:Ss.Chevron,children:u.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"M4 6L8 10L12 6",stroke:"#818181",strokeWidth:"1.33333",strokeLinecap:"round",strokeLinejoin:"round"})})})]})});ei.displayName="Select";ei.Option=Pl;function Ea(e,[t,n]){return Math.min(n,Math.max(t,e))}function X(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 dm(e,t){const n=d.createContext(t),r=s=>{const{children:i,...a}=s,c=d.useMemo(()=>a,Object.values(a));return u.jsx(n.Provider,{value:c,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 ar(e,t=[]){let n=[];function r(s,i){const a=d.createContext(i),c=n.length;n=[...n,i];const l=h=>{var v;const{scope:m,children:g,...x}=h,p=((v=m==null?void 0:m[e])==null?void 0:v[c])||a,y=d.useMemo(()=>x,Object.values(x));return u.jsx(p.Provider,{value:y,children:g})};l.displayName=s+"Provider";function f(h,m){var p;const g=((p=m==null?void 0:m[e])==null?void 0:p[c])||a,x=d.useContext(g);if(x)return x;if(i!==void 0)return i;throw new Error(`\`${h}\` must be used within \`${s}\``)}return[l,f]}const o=()=>{const s=n.map(i=>d.createContext(i));return function(a){const c=(a==null?void 0:a[e])||s;return d.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return o.scopeName=e,[r,fm(o,...t)]}function fm(...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:c,scopeName:l})=>{const h=c(s)[`__scope${l}`];return{...a,...h}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function _a(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Ln(...e){return t=>{let n=!1;const r=e.map(o=>{const s=_a(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():_a(e[o],null)}}}}function ce(...e){return d.useCallback(Ln(...e),e)}function Ra(e){const t=hm(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),c=a.find(mm);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function hm(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=ym(o),a=gm(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 pm=Symbol("radix.slottable");function mm(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===pm}function gm(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function ym(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 vm(e){const t=e+"CollectionProvider",[n,r]=ar(t),[o,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=p=>{const{scope:y,children:v}=p,w=E.useRef(null),S=E.useRef(new Map).current;return u.jsx(o,{scope:y,itemMap:S,collectionRef:w,children:v})};i.displayName=t;const a=e+"CollectionSlot",c=Ra(a),l=E.forwardRef((p,y)=>{const{scope:v,children:w}=p,S=s(a,v),_=ce(y,S.collectionRef);return u.jsx(c,{ref:_,children:w})});l.displayName=a;const f=e+"CollectionItemSlot",h="data-radix-collection-item",m=Ra(f),g=E.forwardRef((p,y)=>{const{scope:v,children:w,...S}=p,_=E.useRef(null),R=ce(y,_),T=s(f,v);return E.useEffect(()=>(T.itemMap.set(_,{ref:_,...S}),()=>void T.itemMap.delete(_))),u.jsx(m,{[h]:"",ref:R,children:w})});g.displayName=f;function x(p){const y=s(e+"CollectionConsumer",p);return E.useCallback(()=>{const w=y.collectionRef.current;if(!w)return[];const S=Array.from(w.querySelectorAll(`[${h}]`));return Array.from(y.itemMap.values()).sort((T,P)=>S.indexOf(T.ref.current)-S.indexOf(P.ref.current))},[y.collectionRef,y.itemMap])}return[{Provider:i,Slot:l,ItemSlot:g},x,r]}var bm=d.createContext(void 0);function wm(e){const t=d.useContext(bm);return e||t||"ltr"}function Cm(e){const t=xm(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),c=a.find(Em);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function xm(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=Rm(o),a=_m(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 Sm=Symbol("radix.slottable");function Em(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Sm}function _m(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Rm(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 Tm=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ie=Tm.reduce((e,t)=>{const n=Cm(`Primitive.${t}`),r=d.forwardRef((o,s)=>{const{asChild:i,...a}=o,c=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(c,{...a,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Pm(e,t){e&&io.flushSync(()=>e.dispatchEvent(t))}function tn(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 Am(e,t=globalThis==null?void 0:globalThis.document){const n=tn(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 Om="DismissableLayer",Es="dismissableLayer.update",jm="dismissableLayer.pointerDownOutside",Im="dismissableLayer.focusOutside",Ta,Al=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),ho=d.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:i,onDismiss:a,...c}=e,l=d.useContext(Al),[f,h]=d.useState(null),m=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,g]=d.useState({}),x=ce(t,P=>h(P)),p=Array.from(l.layers),[y]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),v=p.indexOf(y),w=f?p.indexOf(f):-1,S=l.layersWithOutsidePointerEventsDisabled.size>0,_=w>=v,R=Lm(P=>{const D=P.target,I=[...l.branches].some(L=>L.contains(D));!_||I||(o==null||o(P),i==null||i(P),P.defaultPrevented||a==null||a())},m),T=Mm(P=>{const D=P.target;[...l.branches].some(L=>L.contains(D))||(s==null||s(P),i==null||i(P),P.defaultPrevented||a==null||a())},m);return Am(P=>{w===l.layers.size-1&&(r==null||r(P),!P.defaultPrevented&&a&&(P.preventDefault(),a()))},m),d.useEffect(()=>{if(f)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(Ta=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(f)),l.layers.add(f),Pa(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=Ta)}},[f,m,n,l]),d.useEffect(()=>()=>{f&&(l.layers.delete(f),l.layersWithOutsidePointerEventsDisabled.delete(f),Pa())},[f,l]),d.useEffect(()=>{const P=()=>g({});return document.addEventListener(Es,P),()=>document.removeEventListener(Es,P)},[]),u.jsx(ie.div,{...c,ref:x,style:{pointerEvents:S?_?"auto":"none":void 0,...e.style},onFocusCapture:X(e.onFocusCapture,T.onFocusCapture),onBlurCapture:X(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:X(e.onPointerDownCapture,R.onPointerDownCapture)})});ho.displayName=Om;var Nm="DismissableLayerBranch",Dm=d.forwardRef((e,t)=>{const n=d.useContext(Al),r=d.useRef(null),o=ce(t,r);return d.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),u.jsx(ie.div,{...e,ref:o})});Dm.displayName=Nm;function Lm(e,t=globalThis==null?void 0:globalThis.document){const n=tn(e),r=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const s=a=>{if(a.target&&!r.current){let c=function(){Ol(jm,n,l,{discrete:!0})};const l={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}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 Mm(e,t=globalThis==null?void 0:globalThis.document){const n=tn(e),r=d.useRef(!1);return d.useEffect(()=>{const o=s=>{s.target&&!r.current&&Ol(Im,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 Pa(){const e=new CustomEvent(Es);document.dispatchEvent(e)}function Ol(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?Pm(o,s):o.dispatchEvent(s)}var Bo=0;function jl(){d.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Aa()),document.body.insertAdjacentElement("beforeend",e[1]??Aa()),Bo++,()=>{Bo===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Bo--}},[])}function Aa(){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 Uo="focusScope.autoFocusOnMount",Wo="focusScope.autoFocusOnUnmount",Oa={bubbles:!1,cancelable:!0},km="FocusScope",ti=d.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...i}=e,[a,c]=d.useState(null),l=tn(o),f=tn(s),h=d.useRef(null),m=ce(t,p=>c(p)),g=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(r){let p=function(S){if(g.paused||!a)return;const _=S.target;a.contains(_)?h.current=_:bt(h.current,{select:!0})},y=function(S){if(g.paused||!a)return;const _=S.relatedTarget;_!==null&&(a.contains(_)||bt(h.current,{select:!0}))},v=function(S){if(document.activeElement===document.body)for(const R of S)R.removedNodes.length>0&&bt(a)};document.addEventListener("focusin",p),document.addEventListener("focusout",y);const w=new MutationObserver(v);return a&&w.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",p),document.removeEventListener("focusout",y),w.disconnect()}}},[r,a,g.paused]),d.useEffect(()=>{if(a){Ia.add(g);const p=document.activeElement;if(!a.contains(p)){const v=new CustomEvent(Uo,Oa);a.addEventListener(Uo,l),a.dispatchEvent(v),v.defaultPrevented||($m(Hm(Il(a)),{select:!0}),document.activeElement===p&&bt(a))}return()=>{a.removeEventListener(Uo,l),setTimeout(()=>{const v=new CustomEvent(Wo,Oa);a.addEventListener(Wo,f),a.dispatchEvent(v),v.defaultPrevented||bt(p??document.body,{select:!0}),a.removeEventListener(Wo,f),Ia.remove(g)},0)}}},[a,l,f,g]);const x=d.useCallback(p=>{if(!n&&!r||g.paused)return;const y=p.key==="Tab"&&!p.altKey&&!p.ctrlKey&&!p.metaKey,v=document.activeElement;if(y&&v){const w=p.currentTarget,[S,_]=Fm(w);S&&_?!p.shiftKey&&v===_?(p.preventDefault(),n&&bt(S,{select:!0})):p.shiftKey&&v===S&&(p.preventDefault(),n&&bt(_,{select:!0})):v===w&&p.preventDefault()}},[n,r,g.paused]);return u.jsx(ie.div,{tabIndex:-1,...i,ref:m,onKeyDown:x})});ti.displayName=km;function $m(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(bt(r,{select:t}),document.activeElement!==n)return}function Fm(e){const t=Il(e),n=ja(t,e),r=ja(t.reverse(),e);return[n,r]}function Il(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 ja(e,t){for(const n of e)if(!Bm(n,{upTo:t}))return n}function Bm(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 Um(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&&Um(e)&&t&&e.select()}}var Ia=Wm();function Wm(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Na(e,t),e.unshift(t)},remove(t){var n;e=Na(e,t),(n=e[0])==null||n.resume()}}}function Na(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Hm(e){return e.filter(t=>t.tagName!=="A")}var ye=globalThis!=null&&globalThis.document?d.useLayoutEffect:()=>{},Vm=d[" useId ".trim().toString()]||(()=>{}),qm=0;function Zt(e){const[t,n]=d.useState(Vm());return ye(()=>{n(r=>r??String(qm++))},[e]),e||(t?`radix-${t}`:"")}const zm=["top","right","bottom","left"],Lt=Math.min,Te=Math.max,Qr=Math.round,_r=Math.floor,Je=e=>({x:e,y:e}),Gm={left:"right",right:"left",bottom:"top",top:"bottom"},Km={start:"end",end:"start"};function _s(e,t,n){return Te(e,Lt(t,n))}function dt(e,t){return typeof e=="function"?e(t):e}function ft(e){return e.split("-")[0]}function Mn(e){return e.split("-")[1]}function ni(e){return e==="x"?"y":"x"}function ri(e){return e==="y"?"height":"width"}const Qm=new Set(["top","bottom"]);function Xe(e){return Qm.has(ft(e))?"y":"x"}function oi(e){return ni(Xe(e))}function Ym(e,t,n){n===void 0&&(n=!1);const r=Mn(e),o=oi(e),s=ri(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Yr(i)),[i,Yr(i)]}function Zm(e){const t=Yr(e);return[Rs(e),t,Rs(t)]}function Rs(e){return e.replace(/start|end/g,t=>Km[t])}const Da=["left","right"],La=["right","left"],Xm=["top","bottom"],Jm=["bottom","top"];function eg(e,t,n){switch(e){case"top":case"bottom":return n?t?La:Da:t?Da:La;case"left":case"right":return t?Xm:Jm;default:return[]}}function tg(e,t,n,r){const o=Mn(e);let s=eg(ft(e),n==="start",r);return o&&(s=s.map(i=>i+"-"+o),t&&(s=s.concat(s.map(Rs)))),s}function Yr(e){return e.replace(/left|right|bottom|top/g,t=>Gm[t])}function ng(e){return{top:0,right:0,bottom:0,left:0,...e}}function Nl(e){return typeof e!="number"?ng(e):{top:e,right:e,bottom:e,left:e}}function Zr(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 Ma(e,t,n){let{reference:r,floating:o}=e;const s=Xe(t),i=oi(t),a=ri(i),c=ft(t),l=s==="y",f=r.x+r.width/2-o.width/2,h=r.y+r.height/2-o.height/2,m=r[a]/2-o[a]/2;let g;switch(c){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:h};break;case"left":g={x:r.x-o.width,y:h};break;default:g={x:r.x,y:r.y}}switch(Mn(t)){case"start":g[i]-=m*(n&&l?-1:1);break;case"end":g[i]+=m*(n&&l?-1:1);break}return g}async function rg(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:s,rects:i,elements:a,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:f="viewport",elementContext:h="floating",altBoundary:m=!1,padding:g=0}=dt(t,e),x=Nl(g),y=a[m?h==="floating"?"reference":"floating":h],v=Zr(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(y)))==null||n?y:y.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:l,rootBoundary:f,strategy:c})),w=h==="floating"?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,S=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),_=await(s.isElement==null?void 0:s.isElement(S))?await(s.getScale==null?void 0:s.getScale(S))||{x:1,y:1}:{x:1,y:1},R=Zr(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:w,offsetParent:S,strategy:c}):w);return{top:(v.top-R.top+x.top)/_.y,bottom:(R.bottom-v.bottom+x.bottom)/_.y,left:(v.left-R.left+x.left)/_.x,right:(R.right-v.right+x.right)/_.x}}const og=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:i}=n,a=s.filter(Boolean),c=await(i.isRTL==null?void 0:i.isRTL(t));let l=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:h}=Ma(l,r,c),m=r,g={},x=0;for(let y=0;y<a.length;y++){var p;const{name:v,fn:w}=a[y],{x:S,y:_,data:R,reset:T}=await w({x:f,y:h,initialPlacement:r,placement:m,strategy:o,middlewareData:g,rects:l,platform:{...i,detectOverflow:(p=i.detectOverflow)!=null?p:rg},elements:{reference:e,floating:t}});f=S??f,h=_??h,g={...g,[v]:{...g[v],...R}},T&&x<=50&&(x++,typeof T=="object"&&(T.placement&&(m=T.placement),T.rects&&(l=T.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):T.rects),{x:f,y:h}=Ma(l,m,c)),y=-1)}return{x:f,y:h,placement:m,strategy:o,middlewareData:g}},sg=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:i,elements:a,middlewareData:c}=t,{element:l,padding:f=0}=dt(e,t)||{};if(l==null)return{};const h=Nl(f),m={x:n,y:r},g=oi(o),x=ri(g),p=await i.getDimensions(l),y=g==="y",v=y?"top":"left",w=y?"bottom":"right",S=y?"clientHeight":"clientWidth",_=s.reference[x]+s.reference[g]-m[g]-s.floating[x],R=m[g]-s.reference[g],T=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l));let P=T?T[S]:0;(!P||!await(i.isElement==null?void 0:i.isElement(T)))&&(P=a.floating[S]||s.floating[x]);const D=_/2-R/2,I=P/2-p[x]/2-1,L=Lt(h[v],I),B=Lt(h[w],I),U=L,W=P-p[x]-B,V=P/2-p[x]/2+D,re=_s(U,V,W),q=!c.arrow&&Mn(o)!=null&&V!==re&&s.reference[x]/2-(V<U?L:B)-p[x]/2<0,Q=q?V<U?V-U:V-W:0;return{[g]:m[g]+Q,data:{[g]:re,centerOffset:V-re-Q,...q&&{alignmentOffset:Q}},reset:q}}}),ig=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:c,elements:l}=t,{mainAxis:f=!0,crossAxis:h=!0,fallbackPlacements:m,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:x="none",flipAlignment:p=!0,...y}=dt(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const v=ft(o),w=Xe(a),S=ft(a)===a,_=await(c.isRTL==null?void 0:c.isRTL(l.floating)),R=m||(S||!p?[Yr(a)]:Zm(a)),T=x!=="none";!m&&T&&R.push(...tg(a,p,x,_));const P=[a,...R],D=await c.detectOverflow(t,y),I=[];let L=((r=s.flip)==null?void 0:r.overflows)||[];if(f&&I.push(D[v]),h){const V=Ym(o,i,_);I.push(D[V[0]],D[V[1]])}if(L=[...L,{placement:o,overflows:I}],!I.every(V=>V<=0)){var B,U;const V=(((B=s.flip)==null?void 0:B.index)||0)+1,re=P[V];if(re&&(!(h==="alignment"?w!==Xe(re):!1)||L.every($=>Xe($.placement)===w?$.overflows[0]>0:!0)))return{data:{index:V,overflows:L},reset:{placement:re}};let q=(U=L.filter(Q=>Q.overflows[0]<=0).sort((Q,$)=>Q.overflows[1]-$.overflows[1])[0])==null?void 0:U.placement;if(!q)switch(g){case"bestFit":{var W;const Q=(W=L.filter($=>{if(T){const oe=Xe($.placement);return oe===w||oe==="y"}return!0}).map($=>[$.placement,$.overflows.filter(oe=>oe>0).reduce((oe,pe)=>oe+pe,0)]).sort(($,oe)=>$[1]-oe[1])[0])==null?void 0:W[0];Q&&(q=Q);break}case"initialPlacement":q=a;break}if(o!==q)return{reset:{placement:q}}}return{}}}};function ka(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function $a(e){return zm.some(t=>e[t]>=0)}const ag=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n,platform:r}=t,{strategy:o="referenceHidden",...s}=dt(e,t);switch(o){case"referenceHidden":{const i=await r.detectOverflow(t,{...s,elementContext:"reference"}),a=ka(i,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:$a(a)}}}case"escaped":{const i=await r.detectOverflow(t,{...s,altBoundary:!0}),a=ka(i,n.floating);return{data:{escapedOffsets:a,escaped:$a(a)}}}default:return{}}}}},Dl=new Set(["left","top"]);async function cg(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=ft(n),a=Mn(n),c=Xe(n)==="y",l=Dl.has(i)?-1:1,f=s&&c?-1:1,h=dt(t,e);let{mainAxis:m,crossAxis:g,alignmentAxis:x}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:h.mainAxis||0,crossAxis:h.crossAxis||0,alignmentAxis:h.alignmentAxis};return a&&typeof x=="number"&&(g=a==="end"?x*-1:x),c?{x:g*f,y:m*l}:{x:m*l,y:g*f}}const lg=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,c=await cg(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:o+c.x,y:s+c.y,data:{...c,placement:i}}}}},ug=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:c={fn:v=>{let{x:w,y:S}=v;return{x:w,y:S}}},...l}=dt(e,t),f={x:n,y:r},h=await s.detectOverflow(t,l),m=Xe(ft(o)),g=ni(m);let x=f[g],p=f[m];if(i){const v=g==="y"?"top":"left",w=g==="y"?"bottom":"right",S=x+h[v],_=x-h[w];x=_s(S,x,_)}if(a){const v=m==="y"?"top":"left",w=m==="y"?"bottom":"right",S=p+h[v],_=p-h[w];p=_s(S,p,_)}const y=c.fn({...t,[g]:x,[m]:p});return{...y,data:{x:y.x-n,y:y.y-r,enabled:{[g]:i,[m]:a}}}}}},dg=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:c=!0,crossAxis:l=!0}=dt(e,t),f={x:n,y:r},h=Xe(o),m=ni(h);let g=f[m],x=f[h];const p=dt(a,t),y=typeof p=="number"?{mainAxis:p,crossAxis:0}:{mainAxis:0,crossAxis:0,...p};if(c){const S=m==="y"?"height":"width",_=s.reference[m]-s.floating[S]+y.mainAxis,R=s.reference[m]+s.reference[S]-y.mainAxis;g<_?g=_:g>R&&(g=R)}if(l){var v,w;const S=m==="y"?"width":"height",_=Dl.has(ft(o)),R=s.reference[h]-s.floating[S]+(_&&((v=i.offset)==null?void 0:v[h])||0)+(_?0:y.crossAxis),T=s.reference[h]+s.reference[S]+(_?0:((w=i.offset)==null?void 0:w[h])||0)-(_?y.crossAxis:0);x<R?x=R:x>T&&(x=T)}return{[m]:g,[h]:x}}}},fg=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:c=()=>{},...l}=dt(e,t),f=await i.detectOverflow(t,l),h=ft(o),m=Mn(o),g=Xe(o)==="y",{width:x,height:p}=s.floating;let y,v;h==="top"||h==="bottom"?(y=h,v=m===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(v=h,y=m==="end"?"top":"bottom");const w=p-f.top-f.bottom,S=x-f.left-f.right,_=Lt(p-f[y],w),R=Lt(x-f[v],S),T=!t.middlewareData.shift;let P=_,D=R;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=S),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(P=w),T&&!m){const L=Te(f.left,0),B=Te(f.right,0),U=Te(f.top,0),W=Te(f.bottom,0);g?D=x-2*(L!==0||B!==0?L+B:Te(f.left,f.right)):P=p-2*(U!==0||W!==0?U+W:Te(f.top,f.bottom))}await c({...t,availableWidth:D,availableHeight:P});const I=await i.getDimensions(a.floating);return x!==I.width||p!==I.height?{reset:{rects:!0}}:{}}}};function po(){return typeof window<"u"}function kn(e){return Ll(e)?(e.nodeName||"").toLowerCase():"#document"}function Ae(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function tt(e){var t;return(t=(Ll(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ll(e){return po()?e instanceof Node||e instanceof Ae(e).Node:!1}function Ue(e){return po()?e instanceof Element||e instanceof Ae(e).Element:!1}function et(e){return po()?e instanceof HTMLElement||e instanceof Ae(e).HTMLElement:!1}function Fa(e){return!po()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ae(e).ShadowRoot}const hg=new Set(["inline","contents"]);function cr(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=We(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!hg.has(o)}const pg=new Set(["table","td","th"]);function mg(e){return pg.has(kn(e))}const gg=[":popover-open",":modal"];function mo(e){return gg.some(t=>{try{return e.matches(t)}catch{return!1}})}const yg=["transform","translate","scale","rotate","perspective"],vg=["transform","translate","scale","rotate","perspective","filter"],bg=["paint","layout","strict","content"];function si(e){const t=ii(),n=Ue(e)?We(e):e;return yg.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)||vg.some(r=>(n.willChange||"").includes(r))||bg.some(r=>(n.contain||"").includes(r))}function wg(e){let t=Mt(e);for(;et(t)&&!An(t);){if(si(t))return t;if(mo(t))return null;t=Mt(t)}return null}function ii(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Cg=new Set(["html","body","#document"]);function An(e){return Cg.has(kn(e))}function We(e){return Ae(e).getComputedStyle(e)}function go(e){return Ue(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Mt(e){if(kn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Fa(e)&&e.host||tt(e);return Fa(t)?t.host:t}function Ml(e){const t=Mt(e);return An(t)?e.ownerDocument?e.ownerDocument.body:e.body:et(t)&&cr(t)?t:Ml(t)}function Yn(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=Ml(e),s=o===((r=e.ownerDocument)==null?void 0:r.body),i=Ae(o);if(s){const a=Ts(i);return t.concat(i,i.visualViewport||[],cr(o)?o:[],a&&n?Yn(a):[])}return t.concat(o,Yn(o,[],n))}function Ts(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function kl(e){const t=We(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=et(e),s=o?e.offsetWidth:n,i=o?e.offsetHeight:r,a=Qr(n)!==s||Qr(r)!==i;return a&&(n=s,r=i),{width:n,height:r,$:a}}function ai(e){return Ue(e)?e:e.contextElement}function pn(e){const t=ai(e);if(!et(t))return Je(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=kl(t);let i=(s?Qr(n.width):n.width)/r,a=(s?Qr(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const xg=Je(0);function $l(e){const t=Ae(e);return!ii()||!t.visualViewport?xg:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Sg(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ae(e)?!1:t}function nn(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=ai(e);let i=Je(1);t&&(r?Ue(r)&&(i=pn(r)):i=pn(e));const a=Sg(s,n,r)?$l(s):Je(0);let c=(o.left+a.x)/i.x,l=(o.top+a.y)/i.y,f=o.width/i.x,h=o.height/i.y;if(s){const m=Ae(s),g=r&&Ue(r)?Ae(r):r;let x=m,p=Ts(x);for(;p&&r&&g!==x;){const y=pn(p),v=p.getBoundingClientRect(),w=We(p),S=v.left+(p.clientLeft+parseFloat(w.paddingLeft))*y.x,_=v.top+(p.clientTop+parseFloat(w.paddingTop))*y.y;c*=y.x,l*=y.y,f*=y.x,h*=y.y,c+=S,l+=_,x=Ae(p),p=Ts(x)}}return Zr({width:f,height:h,x:c,y:l})}function yo(e,t){const n=go(e).scrollLeft;return t?t.left+n:nn(tt(e)).left+n}function Fl(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-yo(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function Eg(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",i=tt(r),a=t?mo(t.floating):!1;if(r===i||a&&s)return n;let c={scrollLeft:0,scrollTop:0},l=Je(1);const f=Je(0),h=et(r);if((h||!h&&!s)&&((kn(r)!=="body"||cr(i))&&(c=go(r)),et(r))){const g=nn(r);l=pn(r),f.x=g.x+r.clientLeft,f.y=g.y+r.clientTop}const m=i&&!h&&!s?Fl(i,c):Je(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+f.x+m.x,y:n.y*l.y-c.scrollTop*l.y+f.y+m.y}}function _g(e){return Array.from(e.getClientRects())}function Rg(e){const t=tt(e),n=go(e),r=e.ownerDocument.body,o=Te(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=Te(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+yo(e);const a=-n.scrollTop;return We(r).direction==="rtl"&&(i+=Te(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:i,y:a}}const Ba=25;function Tg(e,t){const n=Ae(e),r=tt(e),o=n.visualViewport;let s=r.clientWidth,i=r.clientHeight,a=0,c=0;if(o){s=o.width,i=o.height;const f=ii();(!f||f&&t==="fixed")&&(a=o.offsetLeft,c=o.offsetTop)}const l=yo(r);if(l<=0){const f=r.ownerDocument,h=f.body,m=getComputedStyle(h),g=f.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,x=Math.abs(r.clientWidth-h.clientWidth-g);x<=Ba&&(s-=x)}else l<=Ba&&(s+=l);return{width:s,height:i,x:a,y:c}}const Pg=new Set(["absolute","fixed"]);function Ag(e,t){const n=nn(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=et(e)?pn(e):Je(1),i=e.clientWidth*s.x,a=e.clientHeight*s.y,c=o*s.x,l=r*s.y;return{width:i,height:a,x:c,y:l}}function Ua(e,t,n){let r;if(t==="viewport")r=Tg(e,n);else if(t==="document")r=Rg(tt(e));else if(Ue(t))r=Ag(t,n);else{const o=$l(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return Zr(r)}function Bl(e,t){const n=Mt(e);return n===t||!Ue(n)||An(n)?!1:We(n).position==="fixed"||Bl(n,t)}function Og(e,t){const n=t.get(e);if(n)return n;let r=Yn(e,[],!1).filter(a=>Ue(a)&&kn(a)!=="body"),o=null;const s=We(e).position==="fixed";let i=s?Mt(e):e;for(;Ue(i)&&!An(i);){const a=We(i),c=si(i);!c&&a.position==="fixed"&&(o=null),(s?!c&&!o:!c&&a.position==="static"&&!!o&&Pg.has(o.position)||cr(i)&&!c&&Bl(e,i))?r=r.filter(f=>f!==i):o=a,i=Mt(i)}return t.set(e,r),r}function jg(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?mo(t)?[]:Og(t,this._c):[].concat(n),r],a=i[0],c=i.reduce((l,f)=>{const h=Ua(t,f,o);return l.top=Te(h.top,l.top),l.right=Lt(h.right,l.right),l.bottom=Lt(h.bottom,l.bottom),l.left=Te(h.left,l.left),l},Ua(t,a,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function Ig(e){const{width:t,height:n}=kl(e);return{width:t,height:n}}function Ng(e,t,n){const r=et(t),o=tt(t),s=n==="fixed",i=nn(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const c=Je(0);function l(){c.x=yo(o)}if(r||!r&&!s)if((kn(t)!=="body"||cr(o))&&(a=go(t)),r){const g=nn(t,!0,s,t);c.x=g.x+t.clientLeft,c.y=g.y+t.clientTop}else o&&l();s&&!r&&o&&l();const f=o&&!r&&!s?Fl(o,a):Je(0),h=i.left+a.scrollLeft-c.x-f.x,m=i.top+a.scrollTop-c.y-f.y;return{x:h,y:m,width:i.width,height:i.height}}function Ho(e){return We(e).position==="static"}function Wa(e,t){if(!et(e)||We(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return tt(e)===n&&(n=n.ownerDocument.body),n}function Ul(e,t){const n=Ae(e);if(mo(e))return n;if(!et(e)){let o=Mt(e);for(;o&&!An(o);){if(Ue(o)&&!Ho(o))return o;o=Mt(o)}return n}let r=Wa(e,t);for(;r&&mg(r)&&Ho(r);)r=Wa(r,t);return r&&An(r)&&Ho(r)&&!si(r)?n:r||wg(e)||n}const Dg=async function(e){const t=this.getOffsetParent||Ul,n=this.getDimensions,r=await n(e.floating);return{reference:Ng(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Lg(e){return We(e).direction==="rtl"}const Mg={convertOffsetParentRelativeRectToViewportRelativeRect:Eg,getDocumentElement:tt,getClippingRect:jg,getOffsetParent:Ul,getElementRects:Dg,getClientRects:_g,getDimensions:Ig,getScale:pn,isElement:Ue,isRTL:Lg};function Wl(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function kg(e,t){let n=null,r;const o=tt(e);function s(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function i(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),s();const l=e.getBoundingClientRect(),{left:f,top:h,width:m,height:g}=l;if(a||t(),!m||!g)return;const x=_r(h),p=_r(o.clientWidth-(f+m)),y=_r(o.clientHeight-(h+g)),v=_r(f),S={rootMargin:-x+"px "+-p+"px "+-y+"px "+-v+"px",threshold:Te(0,Lt(1,c))||1};let _=!0;function R(T){const P=T[0].intersectionRatio;if(P!==c){if(!_)return i();P?i(!1,P):r=setTimeout(()=>{i(!1,1e-7)},1e3)}P===1&&!Wl(l,e.getBoundingClientRect())&&i(),_=!1}try{n=new IntersectionObserver(R,{...S,root:o.ownerDocument})}catch{n=new IntersectionObserver(R,S)}n.observe(e)}return i(!0),s}function $g(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:c=!1}=r,l=ai(e),f=o||s?[...l?Yn(l):[],...Yn(t)]:[];f.forEach(v=>{o&&v.addEventListener("scroll",n,{passive:!0}),s&&v.addEventListener("resize",n)});const h=l&&a?kg(l,n):null;let m=-1,g=null;i&&(g=new ResizeObserver(v=>{let[w]=v;w&&w.target===l&&g&&(g.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var S;(S=g)==null||S.observe(t)})),n()}),l&&!c&&g.observe(l),g.observe(t));let x,p=c?nn(e):null;c&&y();function y(){const v=nn(e);p&&!Wl(p,v)&&n(),p=v,x=requestAnimationFrame(y)}return n(),()=>{var v;f.forEach(w=>{o&&w.removeEventListener("scroll",n),s&&w.removeEventListener("resize",n)}),h==null||h(),(v=g)==null||v.disconnect(),g=null,c&&cancelAnimationFrame(x)}}const Fg=lg,Bg=ug,Ug=ig,Wg=fg,Hg=ag,Ha=sg,Vg=dg,qg=(e,t,n)=>{const r=new Map,o={platform:Mg,...n},s={...o.platform,_c:r};return og(e,t,{...o,platform:s})};var zg=typeof document<"u",Gg=function(){},Br=zg?E.useLayoutEffect:Gg;function Xr(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(!Xr(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)&&!Xr(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function Hl(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Va(e,t){const n=Hl(e);return Math.round(t*n)/n}function Vo(e){const t=d.useRef(e);return Br(()=>{t.current=e}),t}function Kg(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:c,open:l}=e,[f,h]=d.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,g]=d.useState(r);Xr(m,r)||g(r);const[x,p]=d.useState(null),[y,v]=d.useState(null),w=d.useCallback($=>{$!==T.current&&(T.current=$,p($))},[]),S=d.useCallback($=>{$!==P.current&&(P.current=$,v($))},[]),_=s||x,R=i||y,T=d.useRef(null),P=d.useRef(null),D=d.useRef(f),I=c!=null,L=Vo(c),B=Vo(o),U=Vo(l),W=d.useCallback(()=>{if(!T.current||!P.current)return;const $={placement:t,strategy:n,middleware:m};B.current&&($.platform=B.current),qg(T.current,P.current,$).then(oe=>{const pe={...oe,isPositioned:U.current!==!1};V.current&&!Xr(D.current,pe)&&(D.current=pe,io.flushSync(()=>{h(pe)}))})},[m,t,n,B,U]);Br(()=>{l===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,h($=>({...$,isPositioned:!1})))},[l]);const V=d.useRef(!1);Br(()=>(V.current=!0,()=>{V.current=!1}),[]),Br(()=>{if(_&&(T.current=_),R&&(P.current=R),_&&R){if(L.current)return L.current(_,R,W);W()}},[_,R,W,L,I]);const re=d.useMemo(()=>({reference:T,floating:P,setReference:w,setFloating:S}),[w,S]),q=d.useMemo(()=>({reference:_,floating:R}),[_,R]),Q=d.useMemo(()=>{const $={position:n,left:0,top:0};if(!q.floating)return $;const oe=Va(q.floating,f.x),pe=Va(q.floating,f.y);return a?{...$,transform:"translate("+oe+"px, "+pe+"px)",...Hl(q.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:oe,top:pe}},[n,a,q.floating,f.x,f.y]);return d.useMemo(()=>({...f,update:W,refs:re,elements:q,floatingStyles:Q}),[f,W,re,q,Q])}const Qg=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?Ha({element:r.current,padding:o}).fn(n):{}:r?Ha({element:r,padding:o}).fn(n):{}}}},Yg=(e,t)=>({...Fg(e),options:[e,t]}),Zg=(e,t)=>({...Bg(e),options:[e,t]}),Xg=(e,t)=>({...Vg(e),options:[e,t]}),Jg=(e,t)=>({...Ug(e),options:[e,t]}),ey=(e,t)=>({...Wg(e),options:[e,t]}),ty=(e,t)=>({...Hg(e),options:[e,t]}),ny=(e,t)=>({...Qg(e),options:[e,t]});var ry="Arrow",Vl=d.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...s}=e;return u.jsx(ie.svg,{...s,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:u.jsx("polygon",{points:"0,0 30,0 15,10"})})});Vl.displayName=ry;var oy=Vl;function sy(e){const[t,n]=d.useState(void 0);return ye(()=>{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 c=s.borderBoxSize,l=Array.isArray(c)?c[0]:c;i=l.inlineSize,a=l.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 ci="Popper",[ql,vo]=ar(ci),[iy,zl]=ql(ci),Gl=e=>{const{__scopePopper:t,children:n}=e,[r,o]=d.useState(null);return u.jsx(iy,{scope:t,anchor:r,onAnchorChange:o,children:n})};Gl.displayName=ci;var Kl="PopperAnchor",Ql=d.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,s=zl(Kl,n),i=d.useRef(null),a=ce(t,i),c=d.useRef(null);return d.useEffect(()=>{const l=c.current;c.current=(r==null?void 0:r.current)||i.current,l!==c.current&&s.onAnchorChange(c.current)}),r?null:u.jsx(ie.div,{...o,ref:a})});Ql.displayName=Kl;var li="PopperContent",[ay,cy]=ql(li),Yl=d.forwardRef((e,t)=>{var k,J,de,Y,ee,Z;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:s="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:c=!0,collisionBoundary:l=[],collisionPadding:f=0,sticky:h="partial",hideWhenDetached:m=!1,updatePositionStrategy:g="optimized",onPlaced:x,...p}=e,y=zl(li,n),[v,w]=d.useState(null),S=ce(t,ve=>w(ve)),[_,R]=d.useState(null),T=sy(_),P=(T==null?void 0:T.width)??0,D=(T==null?void 0:T.height)??0,I=r+(s!=="center"?"-"+s:""),L=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},B=Array.isArray(l)?l:[l],U=B.length>0,W={padding:L,boundary:B.filter(uy),altBoundary:U},{refs:V,floatingStyles:re,placement:q,isPositioned:Q,middlewareData:$}=Kg({strategy:"fixed",placement:I,whileElementsMounted:(...ve)=>$g(...ve,{animationFrame:g==="always"}),elements:{reference:y.anchor},middleware:[Yg({mainAxis:o+D,alignmentAxis:i}),c&&Zg({mainAxis:!0,crossAxis:!1,limiter:h==="partial"?Xg():void 0,...W}),c&&Jg({...W}),ey({...W,apply:({elements:ve,rects:je,availableWidth:qe,availableHeight:Le})=>{const{width:yt,height:dr}=je.reference,rt=ve.floating.style;rt.setProperty("--radix-popper-available-width",`${qe}px`),rt.setProperty("--radix-popper-available-height",`${Le}px`),rt.setProperty("--radix-popper-anchor-width",`${yt}px`),rt.setProperty("--radix-popper-anchor-height",`${dr}px`)}}),_&&ny({element:_,padding:a}),dy({arrowWidth:P,arrowHeight:D}),m&&ty({strategy:"referenceHidden",...W})]}),[oe,pe]=Jl(q),Oe=tn(x);ye(()=>{Q&&(Oe==null||Oe())},[Q,Oe]);const pt=(k=$.arrow)==null?void 0:k.x,mt=(J=$.arrow)==null?void 0:J.y,Ve=((de=$.arrow)==null?void 0:de.centerOffset)!==0,[gt,De]=d.useState();return ye(()=>{v&&De(window.getComputedStyle(v).zIndex)},[v]),u.jsx("div",{ref:V.setFloating,"data-radix-popper-content-wrapper":"",style:{...re,transform:Q?re.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:gt,"--radix-popper-transform-origin":[(Y=$.transformOrigin)==null?void 0:Y.x,(ee=$.transformOrigin)==null?void 0:ee.y].join(" "),...((Z=$.hide)==null?void 0:Z.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:u.jsx(ay,{scope:n,placedSide:oe,onArrowChange:R,arrowX:pt,arrowY:mt,shouldHideArrow:Ve,children:u.jsx(ie.div,{"data-side":oe,"data-align":pe,...p,ref:S,style:{...p.style,animation:Q?void 0:"none"}})})})});Yl.displayName=li;var Zl="PopperArrow",ly={top:"bottom",right:"left",bottom:"top",left:"right"},Xl=d.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,s=cy(Zl,r),i=ly[s.placedSide];return u.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:u.jsx(oy,{...o,ref:n,style:{...o.style,display:"block"}})})});Xl.displayName=Zl;function uy(e){return e!==null}var dy=e=>({name:"transformOrigin",options:e,fn(t){var y,v,w;const{placement:n,rects:r,middlewareData:o}=t,i=((y=o.arrow)==null?void 0:y.centerOffset)!==0,a=i?0:e.arrowWidth,c=i?0:e.arrowHeight,[l,f]=Jl(n),h={start:"0%",center:"50%",end:"100%"}[f],m=(((v=o.arrow)==null?void 0:v.x)??0)+a/2,g=(((w=o.arrow)==null?void 0:w.y)??0)+c/2;let x="",p="";return l==="bottom"?(x=i?h:`${m}px`,p=`${-c}px`):l==="top"?(x=i?h:`${m}px`,p=`${r.floating.height+c}px`):l==="right"?(x=`${-c}px`,p=i?h:`${g}px`):l==="left"&&(x=`${r.floating.width+c}px`,p=i?h:`${g}px`),{data:{x,y:p}}}});function Jl(e){const[t,n="center"]=e.split("-");return[t,n]}var eu=Gl,tu=Ql,nu=Yl,ru=Xl,fy="Portal",ui=d.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[o,s]=d.useState(!1);ye(()=>s(!0),[]);const i=n||o&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?mc.createPortal(u.jsx(ie.div,{...r,ref:t}),i):null});ui.displayName=fy;function hy(e){const t=py(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),c=a.find(gy);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function py(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=vy(o),a=yy(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 my=Symbol("radix.slottable");function gy(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===my}function yy(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function vy(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 by=d[" useInsertionEffect ".trim().toString()]||ye;function Jr({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,s,i]=wy({defaultProp:t,onChange:n}),a=e!==void 0,c=a?e:o;{const f=d.useRef(e!==void 0);d.useEffect(()=>{const h=f.current;h!==a&&console.warn(`${r} is changing from ${h?"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 l=d.useCallback(f=>{var h;if(a){const m=Cy(f)?f(e):f;m!==e&&((h=i.current)==null||h.call(i,m))}else s(f)},[a,e,s,i]);return[c,l]}function wy({defaultProp:e,onChange:t}){const[n,r]=d.useState(e),o=d.useRef(n),s=d.useRef(t);return by(()=>{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 Cy(e){return typeof e=="function"}function xy(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 ou=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"}),Sy="VisuallyHidden",su=d.forwardRef((e,t)=>u.jsx(ie.span,{...e,ref:t,style:{...ou,...e.style}}));su.displayName=Sy;var Ey=su,_y=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},dn=new WeakMap,Rr=new WeakMap,Tr={},qo=0,iu=function(e){return e&&(e.host||iu(e.parentNode))},Ry=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=iu(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})},Ty=function(e,t,n,r){var o=Ry(t,Array.isArray(e)?e:[e]);Tr[n]||(Tr[n]=new WeakMap);var s=Tr[n],i=[],a=new Set,c=new Set(o),l=function(h){!h||a.has(h)||(a.add(h),l(h.parentNode))};o.forEach(l);var f=function(h){!h||c.has(h)||Array.prototype.forEach.call(h.children,function(m){if(a.has(m))f(m);else try{var g=m.getAttribute(r),x=g!==null&&g!=="false",p=(dn.get(m)||0)+1,y=(s.get(m)||0)+1;dn.set(m,p),s.set(m,y),i.push(m),p===1&&x&&Rr.set(m,!0),y===1&&m.setAttribute(n,"true"),x||m.setAttribute(r,"true")}catch(v){console.error("aria-hidden: cannot operate on ",m,v)}})};return f(t),a.clear(),qo++,function(){i.forEach(function(h){var m=dn.get(h)-1,g=s.get(h)-1;dn.set(h,m),s.set(h,g),m||(Rr.has(h)||h.removeAttribute(r),Rr.delete(h)),g||h.removeAttribute(n)}),qo--,qo||(dn=new WeakMap,dn=new WeakMap,Rr=new WeakMap,Tr={})}},au=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=_y(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),Ty(r,o,n,"aria-hidden")):function(){return null}},Ur="right-scroll-bar-position",Wr="width-before-scroll-bar",Py="with-scroll-bars-hidden",Ay="--removed-body-scroll-bar-size";function zo(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Oy(e,t){var n=E.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 jy=typeof window<"u"?d.useLayoutEffect:d.useEffect,qa=new WeakMap;function Iy(e,t){var n=Oy(null,function(r){return e.forEach(function(o){return zo(o,r)})});return jy(function(){var r=qa.get(n);if(r){var o=new Set(r),s=new Set(e),i=n.current;o.forEach(function(a){s.has(a)||zo(a,null)}),s.forEach(function(a){o.has(a)||zo(a,i)})}qa.set(n,e)},[e]),n}function Ny(e){return e}function Dy(e,t){t===void 0&&(t=Ny);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 c=function(){var f=i;i=[],f.forEach(s)},l=function(){return Promise.resolve().then(c)};l(),n={push:function(f){i.push(f),l()},filter:function(f){return i=i.filter(f),n}}}};return o}function Ly(e){e===void 0&&(e={});var t=Dy(null);return t.options=Ye({async:!0,ssr:!1},e),t}var cu=function(e){var t=e.sideCar,n=Vc(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))};cu.isSideCarExport=!0;function My(e,t){return e.useMedium(t),cu}var lu=Ly(),Go=function(){},bo=d.forwardRef(function(e,t){var n=d.useRef(null),r=d.useState({onScrollCapture:Go,onWheelCapture:Go,onTouchMoveCapture:Go}),o=r[0],s=r[1],i=e.forwardProps,a=e.children,c=e.className,l=e.removeScrollBar,f=e.enabled,h=e.shards,m=e.sideCar,g=e.noRelative,x=e.noIsolation,p=e.inert,y=e.allowPinchZoom,v=e.as,w=v===void 0?"div":v,S=e.gapMode,_=Vc(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),R=m,T=Iy([n,t]),P=Ye(Ye({},_),o);return d.createElement(d.Fragment,null,f&&d.createElement(R,{sideCar:lu,removeScrollBar:l,shards:h,noRelative:g,noIsolation:x,inert:p,setCallbacks:s,allowPinchZoom:!!y,lockRef:n,gapMode:S}),i?d.cloneElement(d.Children.only(a),Ye(Ye({},P),{ref:T})):d.createElement(w,Ye({},P,{className:c,ref:T}),a))});bo.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};bo.classNames={fullWidth:Wr,zeroRight:Ur};var ky=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function $y(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=ky();return t&&e.setAttribute("nonce",t),e}function Fy(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function By(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Uy=function(){var e=0,t=null;return{add:function(n){e==0&&(t=$y())&&(Fy(t,n),By(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Wy=function(){var e=Uy();return function(t,n){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},uu=function(){var e=Wy(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},Hy={left:0,top:0,right:0,gap:0},Ko=function(e){return parseInt(e||"",10)||0},Vy=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[Ko(n),Ko(r),Ko(o)]},qy=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Hy;var t=Vy(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])}},zy=uu(),mn="data-scroll-locked",Gy=function(e,t,n,r){var o=e.left,s=e.top,i=e.right,a=e.gap;return n===void 0&&(n="margin"),`
|
|
212
|
+
.`.concat(Py,` {
|
|
213
213
|
overflow: hidden `).concat(r,`;
|
|
214
214
|
padding-right: `).concat(a,"px ").concat(r,`;
|
|
215
215
|
}
|
|
@@ -243,13 +243,13 @@ to {
|
|
|
243
243
|
}
|
|
244
244
|
|
|
245
245
|
body[`).concat(mn,`] {
|
|
246
|
-
`).concat(
|
|
246
|
+
`).concat(Ay,": ").concat(a,`px;
|
|
247
247
|
}
|
|
248
|
-
`)},za=function(){var e=parseInt(document.body.getAttribute(mn)||"0",10);return isFinite(e)?e:0},
|
|
248
|
+
`)},za=function(){var e=parseInt(document.body.getAttribute(mn)||"0",10);return isFinite(e)?e:0},Ky=function(){d.useEffect(function(){return document.body.setAttribute(mn,(za()+1).toString()),function(){var e=za()-1;e<=0?document.body.removeAttribute(mn):document.body.setAttribute(mn,e.toString())}},[])},Qy=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;Ky();var s=d.useMemo(function(){return qy(o)},[o]);return d.createElement(zy,{styles:Gy(s,!t,o,n?"":"!important")})},Ps=!1;if(typeof window<"u")try{var Pr=Object.defineProperty({},"passive",{get:function(){return Ps=!0,!0}});window.addEventListener("test",Pr,Pr),window.removeEventListener("test",Pr,Pr)}catch{Ps=!1}var fn=Ps?{passive:!1}:!1,Yy=function(e){return e.tagName==="TEXTAREA"},du=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!Yy(e)&&n[t]==="visible")},Zy=function(e){return du(e,"overflowY")},Xy=function(e){return du(e,"overflowX")},Ga=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=fu(e,r);if(o){var s=hu(e,r),i=s[1],a=s[2];if(i>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},Jy=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},ev=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},fu=function(e,t){return e==="v"?Zy(t):Xy(t)},hu=function(e,t){return e==="v"?Jy(t):ev(t)},tv=function(e,t){return e==="h"&&t==="rtl"?-1:1},nv=function(e,t,n,r,o){var s=tv(e,window.getComputedStyle(t).direction),i=s*r,a=n.target,c=t.contains(a),l=!1,f=i>0,h=0,m=0;do{if(!a)break;var g=hu(e,a),x=g[0],p=g[1],y=g[2],v=p-y-s*x;(x||v)&&fu(e,a)&&(h+=v,m+=x);var w=a.parentNode;a=w&&w.nodeType===Node.DOCUMENT_FRAGMENT_NODE?w.host:w}while(!c&&a!==document.body||c&&(t.contains(a)||t===a));return(f&&Math.abs(h)<1||!f&&Math.abs(m)<1)&&(l=!0),l},Ar=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Ka=function(e){return[e.deltaX,e.deltaY]},Qa=function(e){return e&&"current"in e?e.current:e},rv=function(e,t){return e[0]===t[0]&&e[1]===t[1]},ov=function(e){return`
|
|
249
249
|
.block-interactivity-`.concat(e,` {pointer-events: none;}
|
|
250
250
|
.allow-interactivity-`).concat(e,` {pointer-events: all;}
|
|
251
|
-
`)},oy=0,hn=[];function sy(e){var t=d.useRef([]),n=d.useRef([0,0]),r=d.useRef(),o=d.useState(oy++)[0],s=d.useState(lu)[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 p=Hr([e.lockRef.current],(e.shards||[]).map(Ka),!0).filter(Boolean);return p.forEach(function(v){return v.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),p.forEach(function(v){return v.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var a=d.useCallback(function(p,v){if("touches"in p&&p.touches.length===2||p.type==="wheel"&&p.ctrlKey)return!i.current.allowPinchZoom;var y=Ar(p),w=n.current,S="deltaX"in p?p.deltaX:w[0]-y[0],_="deltaY"in p?p.deltaY:w[1]-y[1],R,T=p.target,P=Math.abs(S)>Math.abs(_)?"h":"v";if("touches"in p&&P==="h"&&T.type==="range")return!1;var D=window.getSelection(),I=D&&D.anchorNode,L=I?I===T||I.contains(T):!1;if(L)return!1;var B=qa(P,T);if(!B)return!0;if(B?R=P:(R=P==="v"?"h":"v",B=qa(P,T)),!B)return!1;if(!r.current&&"changedTouches"in p&&(S||_)&&(r.current=R),!R)return!0;var U=r.current||R;return ty(U,v,p,U==="h"?S:_)},[]),c=d.useCallback(function(p){var v=p;if(!(!hn.length||hn[hn.length-1]!==s)){var y="deltaY"in v?Ga(v):Ar(v),w=t.current.filter(function(R){return R.name===v.type&&(R.target===v.target||v.target===R.shadowParent)&&ny(R.delta,y)})[0];if(w&&w.should){v.cancelable&&v.preventDefault();return}if(!w){var S=(i.current.shards||[]).map(Ka).filter(Boolean).filter(function(R){return R.contains(v.target)}),_=S.length>0?a(v,S[0]):!i.current.noIsolation;_&&v.cancelable&&v.preventDefault()}}},[]),l=d.useCallback(function(p,v,y,w){var S={name:p,delta:v,target:y,should:w,shadowParent:iy(y)};t.current.push(S),setTimeout(function(){t.current=t.current.filter(function(_){return _!==S})},1)},[]),f=d.useCallback(function(p){n.current=Ar(p),r.current=void 0},[]),h=d.useCallback(function(p){l(p.type,Ga(p),p.target,a(p,e.lockRef.current))},[]),m=d.useCallback(function(p){l(p.type,Ar(p),p.target,a(p,e.lockRef.current))},[]);d.useEffect(function(){return hn.push(s),e.setCallbacks({onScrollCapture:h,onWheelCapture:h,onTouchMoveCapture:m}),document.addEventListener("wheel",c,fn),document.addEventListener("touchmove",c,fn),document.addEventListener("touchstart",f,fn),function(){hn=hn.filter(function(p){return p!==s}),document.removeEventListener("wheel",c,fn),document.removeEventListener("touchmove",c,fn),document.removeEventListener("touchstart",f,fn)}},[]);var g=e.removeScrollBar,x=e.inert;return d.createElement(d.Fragment,null,x?d.createElement(s,{styles:ry(o)}):null,g?d.createElement(Kv,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function iy(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const ay=Lv(cu,sy);var ui=d.forwardRef(function(e,t){return d.createElement(yo,Ye({},e,{ref:t,sideCar:ay}))});ui.classNames=yo.classNames;var cy=[" ","Enter","ArrowUp","ArrowDown"],ly=[" ","Enter"],rn="Select",[bo,wo,uy]=vm(rn),[$n]=ar(rn,[uy,vo]),Co=vo(),[dy,$t]=$n(rn),[fy,hy]=$n(rn),hu=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:s,value:i,defaultValue:a,onValueChange:c,dir:l,name:f,autoComplete:h,disabled:m,required:g,form:x}=e,p=Co(t),[v,y]=d.useState(null),[w,S]=d.useState(null),[_,R]=d.useState(!1),T=bm(l),[P,D]=Jr({prop:r,defaultProp:o??!1,onChange:s,caller:rn}),[I,L]=Jr({prop:i,defaultProp:a,onChange:c,caller:rn}),B=d.useRef(null),U=v?x||!!v.closest("form"):!0,[W,V]=d.useState(new Set),re=Array.from(W).map(z=>z.props.value).join(";");return u.jsx(Jl,{...p,children:u.jsxs(dy,{required:g,scope:t,trigger:v,onTriggerChange:y,valueNode:w,onValueNodeChange:S,valueNodeHasChildren:_,onValueNodeHasChildrenChange:R,contentId:Zt(),value:I,onValueChange:L,open:P,onOpenChange:D,dir:T,triggerPointerDownPosRef:B,disabled:m,children:[u.jsx(bo.Provider,{scope:t,children:u.jsx(fy,{scope:e.__scopeSelect,onNativeOptionAdd:d.useCallback(z=>{V(Q=>new Set(Q).add(z))},[]),onNativeOptionRemove:d.useCallback(z=>{V(Q=>{const $=new Set(Q);return $.delete(z),$})},[]),children:n})}),U?u.jsxs(Nu,{"aria-hidden":!0,required:g,tabIndex:-1,name:f,autoComplete:h,value:I,onChange:z=>L(z.target.value),disabled:m,form:x,children:[I===void 0?u.jsx("option",{value:""}):null,Array.from(W)]},re):null]})})};hu.displayName=rn;var pu="SelectTrigger",mu=d.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,s=Co(n),i=$t(pu,n),a=i.disabled||r,c=ce(t,i.onTriggerChange),l=wo(n),f=d.useRef("touch"),[h,m,g]=Lu(p=>{const v=l().filter(S=>!S.disabled),y=v.find(S=>S.value===i.value),w=Mu(v,p,y);w!==void 0&&i.onValueChange(w.value)}),x=p=>{a||(i.onOpenChange(!0),g()),p&&(i.triggerPointerDownPosRef.current={x:Math.round(p.pageX),y:Math.round(p.pageY)})};return u.jsx(eu,{asChild:!0,...s,children:u.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":Du(i.value)?"":void 0,...o,ref:c,onClick:X(o.onClick,p=>{p.currentTarget.focus(),f.current!=="mouse"&&x(p)}),onPointerDown:X(o.onPointerDown,p=>{f.current=p.pointerType;const v=p.target;v.hasPointerCapture(p.pointerId)&&v.releasePointerCapture(p.pointerId),p.button===0&&p.ctrlKey===!1&&p.pointerType==="mouse"&&(x(p),p.preventDefault())}),onKeyDown:X(o.onKeyDown,p=>{const v=h.current!=="";!(p.ctrlKey||p.altKey||p.metaKey)&&p.key.length===1&&m(p.key),!(v&&p.key===" ")&&cy.includes(p.key)&&(x(),p.preventDefault())})})})});mu.displayName=pu;var gu="SelectValue",vu=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:s,placeholder:i="",...a}=e,c=$t(gu,n),{onValueNodeHasChildrenChange:l}=c,f=s!==void 0,h=ce(t,c.onValueNodeChange);return ve(()=>{l(f)},[l,f]),u.jsx(ie.span,{...a,ref:h,style:{pointerEvents:"none"},children:Du(c.value)?u.jsx(u.Fragment,{children:i}):s})});vu.displayName=gu;var py="SelectIcon",yu=d.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return u.jsx(ie.span,{"aria-hidden":!0,...o,ref:t,children:r||"▼"})});yu.displayName=py;var on="SelectContent",bu=d.forwardRef((e,t)=>{const n=$t(on,e.__scopeSelect),[r,o]=d.useState();if(ve(()=>{o(new DocumentFragment)},[]),!n.open){const s=r;return s?so.createPortal(u.jsx(wu,{scope:e.__scopeSelect,children:u.jsx(bo.Slot,{scope:e.__scopeSelect,children:u.jsx("div",{children:e.children})})}),s):null}return u.jsx(Cu,{...e,ref:t})});bu.displayName=on;var Me=10,[wu,Ft]=$n(on),my="SelectContentImpl",gy=fv("SelectContent.RemoveScroll"),Cu=d.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:s,onPointerDownOutside:i,side:a,sideOffset:c,align:l,alignOffset:f,arrowPadding:h,collisionBoundary:m,collisionPadding:g,sticky:x,hideWhenDetached:p,avoidCollisions:v,...y}=e,w=$t(on,n),[S,_]=d.useState(null),[R,T]=d.useState(null),P=ce(t,k=>_(k)),[D,I]=d.useState(null),[L,B]=d.useState(null),U=wo(n),[W,V]=d.useState(!1),re=d.useRef(!1);d.useEffect(()=>{if(S)return iu(S)},[S]),Ol();const z=d.useCallback(k=>{const[J,...de]=U().map(Z=>Z.ref.current),[Y]=de.slice(-1),ee=document.activeElement;for(const Z of k)if(Z===ee||(Z==null||Z.scrollIntoView({block:"nearest"}),Z===J&&R&&(R.scrollTop=0),Z===Y&&R&&(R.scrollTop=R.scrollHeight),Z==null||Z.focus(),document.activeElement!==ee))return},[U,R]),Q=d.useCallback(()=>z([D,S]),[z,D,S]);d.useEffect(()=>{W&&Q()},[W,Q]);const{onOpenChange:$,triggerPointerDownPosRef:oe}=w;d.useEffect(()=>{if(S){let k={x:0,y:0};const J=Y=>{var ee,Z;k={x:Math.abs(Math.round(Y.pageX)-(((ee=oe.current)==null?void 0:ee.x)??0)),y:Math.abs(Math.round(Y.pageY)-(((Z=oe.current)==null?void 0:Z.y)??0))}},de=Y=>{k.x<=10&&k.y<=10?Y.preventDefault():S.contains(Y.target)||$(!1),document.removeEventListener("pointermove",J),oe.current=null};return oe.current!==null&&(document.addEventListener("pointermove",J),document.addEventListener("pointerup",de,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",J),document.removeEventListener("pointerup",de,{capture:!0})}}},[S,$,oe]),d.useEffect(()=>{const k=()=>$(!1);return window.addEventListener("blur",k),window.addEventListener("resize",k),()=>{window.removeEventListener("blur",k),window.removeEventListener("resize",k)}},[$]);const[pe,Oe]=Lu(k=>{const J=U().filter(ee=>!ee.disabled),de=J.find(ee=>ee.ref.current===document.activeElement),Y=Mu(J,k,de);Y&&setTimeout(()=>Y.ref.current.focus())}),pt=d.useCallback((k,J,de)=>{const Y=!re.current&&!de;(w.value!==void 0&&w.value===J||Y)&&(I(k),Y&&(re.current=!0))},[w.value]),mt=d.useCallback(()=>S==null?void 0:S.focus(),[S]),Ve=d.useCallback((k,J,de)=>{const Y=!re.current&&!de;(w.value!==void 0&&w.value===J||Y)&&B(k)},[w.value]),gt=r==="popper"?Ps:xu,De=gt===Ps?{side:a,sideOffset:c,align:l,alignOffset:f,arrowPadding:h,collisionBoundary:m,collisionPadding:g,sticky:x,hideWhenDetached:p,avoidCollisions:v}:{};return u.jsx(wu,{scope:n,content:S,viewport:R,onViewportChange:T,itemRefCallback:pt,selectedItem:D,onItemLeave:mt,itemTextRefCallback:Ve,focusSelectedItem:Q,selectedItemText:L,position:r,isPositioned:W,searchRef:pe,children:u.jsx(ui,{as:gy,allowPinchZoom:!0,children:u.jsx(ei,{asChild:!0,trapped:w.open,onMountAutoFocus:k=>{k.preventDefault()},onUnmountAutoFocus:X(o,k=>{var J;(J=w.trigger)==null||J.focus({preventScroll:!0}),k.preventDefault()}),children:u.jsx(fo,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:k=>k.preventDefault(),onDismiss:()=>w.onOpenChange(!1),children:u.jsx(gt,{role:"listbox",id:w.contentId,"data-state":w.open?"open":"closed",dir:w.dir,onContextMenu:k=>k.preventDefault(),...y,...De,onPlaced:()=>V(!0),ref:P,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:X(y.onKeyDown,k=>{const J=k.ctrlKey||k.altKey||k.metaKey;if(k.key==="Tab"&&k.preventDefault(),!J&&k.key.length===1&&Oe(k.key),["ArrowUp","ArrowDown","Home","End"].includes(k.key)){let Y=U().filter(ee=>!ee.disabled).map(ee=>ee.ref.current);if(["ArrowUp","End"].includes(k.key)&&(Y=Y.slice().reverse()),["ArrowUp","ArrowDown"].includes(k.key)){const ee=k.target,Z=Y.indexOf(ee);Y=Y.slice(Z+1)}setTimeout(()=>z(Y)),k.preventDefault()}})})})})})})});Cu.displayName=my;var vy="SelectItemAlignedPosition",xu=d.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,s=$t(on,n),i=Ft(on,n),[a,c]=d.useState(null),[l,f]=d.useState(null),h=ce(t,P=>f(P)),m=wo(n),g=d.useRef(!1),x=d.useRef(!0),{viewport:p,selectedItem:v,selectedItemText:y,focusSelectedItem:w}=i,S=d.useCallback(()=>{if(s.trigger&&s.valueNode&&a&&l&&p&&v&&y){const P=s.trigger.getBoundingClientRect(),D=l.getBoundingClientRect(),I=s.valueNode.getBoundingClientRect(),L=y.getBoundingClientRect();if(s.dir!=="rtl"){const ee=L.left-D.left,Z=I.left-ee,ye=P.left-Z,je=P.width+ye,ze=Math.max(je,D.width),Le=window.innerWidth-Me,vt=Sa(Z,[Me,Math.max(Me,Le-ze)]);a.style.minWidth=je+"px",a.style.left=vt+"px"}else{const ee=D.right-L.right,Z=window.innerWidth-I.right-ee,ye=window.innerWidth-P.right-Z,je=P.width+ye,ze=Math.max(je,D.width),Le=window.innerWidth-Me,vt=Sa(Z,[Me,Math.max(Me,Le-ze)]);a.style.minWidth=je+"px",a.style.right=vt+"px"}const B=m(),U=window.innerHeight-Me*2,W=p.scrollHeight,V=window.getComputedStyle(l),re=parseInt(V.borderTopWidth,10),z=parseInt(V.paddingTop,10),Q=parseInt(V.borderBottomWidth,10),$=parseInt(V.paddingBottom,10),oe=re+z+W+$+Q,pe=Math.min(v.offsetHeight*5,oe),Oe=window.getComputedStyle(p),pt=parseInt(Oe.paddingTop,10),mt=parseInt(Oe.paddingBottom,10),Ve=P.top+P.height/2-Me,gt=U-Ve,De=v.offsetHeight/2,k=v.offsetTop+De,J=re+z+k,de=oe-J;if(J<=Ve){const ee=B.length>0&&v===B[B.length-1].ref.current;a.style.bottom="0px";const Z=l.clientHeight-p.offsetTop-p.offsetHeight,ye=Math.max(gt,De+(ee?mt:0)+Z+Q),je=J+ye;a.style.height=je+"px"}else{const ee=B.length>0&&v===B[0].ref.current;a.style.top="0px";const ye=Math.max(Ve,re+p.offsetTop+(ee?pt:0)+De)+de;a.style.height=ye+"px",p.scrollTop=J-Ve+p.offsetTop}a.style.margin=`${Me}px 0`,a.style.minHeight=pe+"px",a.style.maxHeight=U+"px",r==null||r(),requestAnimationFrame(()=>g.current=!0)}},[m,s.trigger,s.valueNode,a,l,p,v,y,s.dir,r]);ve(()=>S(),[S]);const[_,R]=d.useState();ve(()=>{l&&R(window.getComputedStyle(l).zIndex)},[l]);const T=d.useCallback(P=>{P&&x.current===!0&&(S(),w==null||w(),x.current=!1)},[S,w]);return u.jsx(by,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:g,onScrollButtonChange:T,children:u.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:_},children:u.jsx(ie.div,{...o,ref:h,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});xu.displayName=vy;var yy="SelectPopperPosition",Ps=d.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=Me,...s}=e,i=Co(n);return u.jsx(tu,{...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)"}})});Ps.displayName=yy;var[by,di]=$n(on,{}),As="SelectViewport",Su=d.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...o}=e,s=Ft(As,n),i=di(As,n),a=ce(t,s.onViewportChange),c=d.useRef(0);return u.jsxs(u.Fragment,{children:[u.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}),u.jsx(bo.Slot,{scope:n,children:u.jsx(ie.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:X(o.onScroll,l=>{const f=l.currentTarget,{contentWrapper:h,shouldExpandOnScrollRef:m}=i;if(m!=null&&m.current&&h){const g=Math.abs(c.current-f.scrollTop);if(g>0){const x=window.innerHeight-Me*2,p=parseFloat(h.style.minHeight),v=parseFloat(h.style.height),y=Math.max(p,v);if(y<x){const w=y+g,S=Math.min(x,w),_=w-S;h.style.height=S+"px",h.style.bottom==="0px"&&(f.scrollTop=_>0?_:0,h.style.justifyContent="flex-end")}}}c.current=f.scrollTop})})})]})});Su.displayName=As;var Eu="SelectGroup",[wy,Cy]=$n(Eu),_u=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Zt();return u.jsx(wy,{scope:n,id:o,children:u.jsx(ie.div,{role:"group","aria-labelledby":o,...r,ref:t})})});_u.displayName=Eu;var Ru="SelectLabel",xy=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Cy(Ru,n);return u.jsx(ie.div,{id:o.id,...r,ref:t})});xy.displayName=Ru;var eo="SelectItem",[Sy,Tu]=$n(eo),Pu=d.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:s,...i}=e,a=$t(eo,n),c=Ft(eo,n),l=a.value===r,[f,h]=d.useState(s??""),[m,g]=d.useState(!1),x=ce(t,w=>{var S;return(S=c.itemRefCallback)==null?void 0:S.call(c,w,r,o)}),p=Zt(),v=d.useRef("touch"),y=()=>{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 u.jsx(Sy,{scope:n,value:r,disabled:o,textId:p,isSelected:l,onItemTextChange:d.useCallback(w=>{h(S=>S||((w==null?void 0:w.textContent)??"").trim())},[]),children:u.jsx(bo.ItemSlot,{scope:n,value:r,disabled:o,textValue:f,children:u.jsx(ie.div,{role:"option","aria-labelledby":p,"data-highlighted":m?"":void 0,"aria-selected":l&&m,"data-state":l?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...i,ref:x,onFocus:X(i.onFocus,()=>g(!0)),onBlur:X(i.onBlur,()=>g(!1)),onClick:X(i.onClick,()=>{v.current!=="mouse"&&y()}),onPointerUp:X(i.onPointerUp,()=>{v.current==="mouse"&&y()}),onPointerDown:X(i.onPointerDown,w=>{v.current=w.pointerType}),onPointerMove:X(i.onPointerMove,w=>{var S;v.current=w.pointerType,o?(S=c.onItemLeave)==null||S.call(c):v.current==="mouse"&&w.currentTarget.focus({preventScroll:!0})}),onPointerLeave:X(i.onPointerLeave,w=>{var S;w.currentTarget===document.activeElement&&((S=c.onItemLeave)==null||S.call(c))}),onKeyDown:X(i.onKeyDown,w=>{var _;((_=c.searchRef)==null?void 0:_.current)!==""&&w.key===" "||(ly.includes(w.key)&&y(),w.key===" "&&w.preventDefault())})})})})});Pu.displayName=eo;var zn="SelectItemText",Au=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...s}=e,i=$t(zn,n),a=Ft(zn,n),c=Tu(zn,n),l=hy(zn,n),[f,h]=d.useState(null),m=ce(t,y=>h(y),c.onItemTextChange,y=>{var w;return(w=a.itemTextRefCallback)==null?void 0:w.call(a,y,c.value,c.disabled)}),g=f==null?void 0:f.textContent,x=d.useMemo(()=>u.jsx("option",{value:c.value,disabled:c.disabled,children:g},c.value),[c.disabled,c.value,g]),{onNativeOptionAdd:p,onNativeOptionRemove:v}=l;return ve(()=>(p(x),()=>v(x)),[p,v,x]),u.jsxs(u.Fragment,{children:[u.jsx(ie.span,{id:c.textId,...s,ref:m}),c.isSelected&&i.valueNode&&!i.valueNodeHasChildren?so.createPortal(s.children,i.valueNode):null]})});Au.displayName=zn;var Ou="SelectItemIndicator",ju=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return Tu(Ou,n).isSelected?u.jsx(ie.span,{"aria-hidden":!0,...r,ref:t}):null});ju.displayName=Ou;var Os="SelectScrollUpButton",Ey=d.forwardRef((e,t)=>{const n=Ft(Os,e.__scopeSelect),r=di(Os,e.__scopeSelect),[o,s]=d.useState(!1),i=ce(t,r.onScrollButtonChange);return ve(()=>{if(n.viewport&&n.isPositioned){let a=function(){const l=c.scrollTop>0;s(l)};const c=n.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?u.jsx(Iu,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop-c.offsetHeight)}}):null});Ey.displayName=Os;var js="SelectScrollDownButton",_y=d.forwardRef((e,t)=>{const n=Ft(js,e.__scopeSelect),r=di(js,e.__scopeSelect),[o,s]=d.useState(!1),i=ce(t,r.onScrollButtonChange);return ve(()=>{if(n.viewport&&n.isPositioned){let a=function(){const l=c.scrollHeight-c.clientHeight,f=Math.ceil(c.scrollTop)<l;s(f)};const c=n.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?u.jsx(Iu,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop+c.offsetHeight)}}):null});_y.displayName=js;var Iu=d.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,s=Ft("SelectScrollButton",n),i=d.useRef(null),a=wo(n),c=d.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return d.useEffect(()=>()=>c(),[c]),ve(()=>{var f;const l=a().find(h=>h.ref.current===document.activeElement);(f=l==null?void 0:l.ref.current)==null||f.scrollIntoView({block:"nearest"})},[a]),u.jsx(ie.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:X(o.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(r,50))}),onPointerMove:X(o.onPointerMove,()=>{var l;(l=s.onItemLeave)==null||l.call(s),i.current===null&&(i.current=window.setInterval(r,50))}),onPointerLeave:X(o.onPointerLeave,()=>{c()})})}),Ry="SelectSeparator",Ty=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return u.jsx(ie.div,{"aria-hidden":!0,...r,ref:t})});Ty.displayName=Ry;var Is="SelectArrow",Py=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Co(n),s=$t(Is,n),i=Ft(Is,n);return s.open&&i.position==="popper"?u.jsx(nu,{...o,...r,ref:t}):null});Py.displayName=Is;var Ay="SelectBubbleInput",Nu=d.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const o=d.useRef(null),s=ce(r,o),i=Cv(t);return d.useEffect(()=>{const a=o.current;if(!a)return;const c=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(c,"value").set;if(i!==t&&f){const h=new Event("change",{bubbles:!0});f.call(a,t),a.dispatchEvent(h)}},[i,t]),u.jsx(ie.select,{...n,style:{...ru,...n.style},ref:s,defaultValue:t})});Nu.displayName=Ay;function Du(e){return e===""||e===void 0}function Lu(e){const t=tn(e),n=d.useRef(""),r=d.useRef(0),o=d.useCallback(i=>{const a=n.current+i;t(a),function c(l){n.current=l,window.clearTimeout(r.current),l!==""&&(r.current=window.setTimeout(()=>c(""),1e3))}(a)},[t]),s=d.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return d.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,s]}function Mu(e,t,n){const o=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let i=Oy(e,Math.max(s,0));o.length===1&&(i=i.filter(l=>l!==n));const c=i.find(l=>l.textValue.toLowerCase().startsWith(o.toLowerCase()));return c!==n?c:void 0}function Oy(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var jy=hu,Iy=mu,Ny=vu,Dy=yu,Ly=bu,My=Su,ky=_u,$y=Pu,Fy=Au,By=ju;const Uy="Container__xcHXp",Wy="Label__0cZB9",Hy="HelperText__m1nA9",Vy="Trigger__AyFUd",zy="TriggerIcon__aygFG",qy="Content__llztG",Gy="Viewport__COtSL",Ky="Item__XN1-2",Qy="ItemIndicatorContainer__EQH-X",Yy="ItemIndicator__bySSc",qe={Container:Uy,Label:Wy,HelperText:Hy,Trigger:Vy,TriggerIcon:zy,Content:qy,Viewport:Gy,Item:Ky,ItemIndicatorContainer:Qy,ItemIndicator:Yy},ku=E.forwardRef(({label:e,helperText:t,value:n,onValueChange:r,options:o,placeholder:s="Select",disabled:i=!1,className:a,name:c},l)=>u.jsxs("div",{className:N(qe.Container,a),children:[e&&u.jsx("label",{className:qe.Label,children:e}),u.jsxs(jy,{value:n,onValueChange:r,disabled:i,name:c,children:[u.jsxs(Iy,{ref:l,className:qe.Trigger,children:[u.jsx(Ny,{placeholder:s}),u.jsx(Dy,{className:qe.TriggerIcon,children:u.jsx(Zy,{})})]}),u.jsx(Ly,{className:qe.Content,position:"popper",sideOffset:4,children:u.jsx(My,{className:qe.Viewport,children:u.jsx(ky,{children:o.map(f=>u.jsxs($y,{value:f.value,disabled:f.disabled,className:qe.Item,children:[u.jsx("div",{className:qe.ItemIndicatorContainer,children:u.jsx(By,{className:qe.ItemIndicator,children:u.jsx(Xy,{})})}),u.jsx(Fy,{children:f.label})]},f.value))})})})]}),t&&u.jsx("div",{className:qe.HelperText,children:t})]}));ku.displayName="Select";const Zy=()=>u.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[u.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"}),u.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"})]}),Xy=()=>u.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"M13.3333 4L6 11.3333L2.66667 8",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Jy="TextArea__pa-A0",e0={TextArea:Jy},$u=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(e0.TextArea,t);return u.jsx("textarea",{ref:r,className:o,...n,children:e})});$u.displayName="TextArea";function t0(e,t){return d.useReducer((n,r)=>t[n][r]??n,e)}var Fn=e=>{const{present:t,children:n}=e,r=n0(t),o=typeof n=="function"?n({present:r.isPresent}):d.Children.only(n),s=ce(r.ref,r0(o));return typeof n=="function"||r.isPresent?d.cloneElement(o,{ref:s}):null};Fn.displayName="Presence";function n0(e){const[t,n]=d.useState(),r=d.useRef(null),o=d.useRef(e),s=d.useRef("none"),i=e?"mounted":"unmounted",[a,c]=t0(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const l=Or(r.current);s.current=a==="mounted"?l:"none"},[a]),ve(()=>{const l=r.current,f=o.current;if(f!==e){const m=s.current,g=Or(l);e?c("MOUNT"):g==="none"||(l==null?void 0:l.display)==="none"?c("UNMOUNT"):c(f&&m!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),ve(()=>{if(t){let l;const f=t.ownerDocument.defaultView??window,h=g=>{const p=Or(r.current).includes(CSS.escape(g.animationName));if(g.target===t&&p&&(c("ANIMATION_END"),!o.current)){const v=t.style.animationFillMode;t.style.animationFillMode="forwards",l=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=v)})}},m=g=>{g.target===t&&(s.current=Or(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",h),t.addEventListener("animationend",h),()=>{f.clearTimeout(l),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",h),t.removeEventListener("animationend",h)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:d.useCallback(l=>{r.current=l?getComputedStyle(l):null,n(l)},[])}}function Or(e){return(e==null?void 0:e.animationName)||"none"}function r0(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 o0=Symbol("radix.slottable");function s0(e){const t=({children:n})=>u.jsx(u.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=o0,t}var[xo]=ar("Tooltip",[vo]),So=vo(),Fu="TooltipProvider",i0=700,Ns="tooltip.open",[a0,fi]=xo(Fu),Bu=e=>{const{__scopeTooltip:t,delayDuration:n=i0,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:s}=e,i=d.useRef(!0),a=d.useRef(!1),c=d.useRef(0);return d.useEffect(()=>{const l=c.current;return()=>window.clearTimeout(l)},[]),u.jsx(a0,{scope:t,isOpenDelayedRef:i,delayDuration:n,onOpen:d.useCallback(()=>{window.clearTimeout(c.current),i.current=!1},[]),onClose:d.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>i.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:d.useCallback(l=>{a.current=l},[]),disableHoverableContent:o,children:s})};Bu.displayName=Fu;var Zn="Tooltip",[c0,lr]=xo(Zn),Uu=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o,onOpenChange:s,disableHoverableContent:i,delayDuration:a}=e,c=fi(Zn,e.__scopeTooltip),l=So(t),[f,h]=d.useState(null),m=Zt(),g=d.useRef(0),x=i??c.disableHoverableContent,p=a??c.delayDuration,v=d.useRef(!1),[y,w]=Jr({prop:r,defaultProp:o??!1,onChange:P=>{P?(c.onOpen(),document.dispatchEvent(new CustomEvent(Ns))):c.onClose(),s==null||s(P)},caller:Zn}),S=d.useMemo(()=>y?v.current?"delayed-open":"instant-open":"closed",[y]),_=d.useCallback(()=>{window.clearTimeout(g.current),g.current=0,v.current=!1,w(!0)},[w]),R=d.useCallback(()=>{window.clearTimeout(g.current),g.current=0,w(!1)},[w]),T=d.useCallback(()=>{window.clearTimeout(g.current),g.current=window.setTimeout(()=>{v.current=!0,w(!0),g.current=0},p)},[p,w]);return d.useEffect(()=>()=>{g.current&&(window.clearTimeout(g.current),g.current=0)},[]),u.jsx(Jl,{...l,children:u.jsx(c0,{scope:t,contentId:m,open:y,stateAttribute:S,trigger:f,onTriggerChange:h,onTriggerEnter:d.useCallback(()=>{c.isOpenDelayedRef.current?T():_()},[c.isOpenDelayedRef,T,_]),onTriggerLeave:d.useCallback(()=>{x?R():(window.clearTimeout(g.current),g.current=0)},[R,x]),onOpen:_,onClose:R,disableHoverableContent:x,children:n})})};Uu.displayName=Zn;var Ds="TooltipTrigger",Wu=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=lr(Ds,n),s=fi(Ds,n),i=So(n),a=d.useRef(null),c=ce(t,a,o.onTriggerChange),l=d.useRef(!1),f=d.useRef(!1),h=d.useCallback(()=>l.current=!1,[]);return d.useEffect(()=>()=>document.removeEventListener("pointerup",h),[h]),u.jsx(eu,{asChild:!0,...i,children:u.jsx(ie.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:c,onPointerMove:X(e.onPointerMove,m=>{m.pointerType!=="touch"&&!f.current&&!s.isPointerInTransitRef.current&&(o.onTriggerEnter(),f.current=!0)}),onPointerLeave:X(e.onPointerLeave,()=>{o.onTriggerLeave(),f.current=!1}),onPointerDown:X(e.onPointerDown,()=>{o.open&&o.onClose(),l.current=!0,document.addEventListener("pointerup",h,{once:!0})}),onFocus:X(e.onFocus,()=>{l.current||o.onOpen()}),onBlur:X(e.onBlur,o.onClose),onClick:X(e.onClick,o.onClose)})})});Wu.displayName=Ds;var hi="TooltipPortal",[l0,u0]=xo(hi,{forceMount:void 0}),Hu=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,s=lr(hi,t);return u.jsx(l0,{scope:t,forceMount:n,children:u.jsx(Fn,{present:n||s.open,children:u.jsx(li,{asChild:!0,container:o,children:r})})})};Hu.displayName=hi;var On="TooltipContent",Vu=d.forwardRef((e,t)=>{const n=u0(On,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...s}=e,i=lr(On,e.__scopeTooltip);return u.jsx(Fn,{present:r||i.open,children:i.disableHoverableContent?u.jsx(zu,{side:o,...s,ref:t}):u.jsx(d0,{side:o,...s,ref:t})})}),d0=d.forwardRef((e,t)=>{const n=lr(On,e.__scopeTooltip),r=fi(On,e.__scopeTooltip),o=d.useRef(null),s=ce(t,o),[i,a]=d.useState(null),{trigger:c,onClose:l}=n,f=o.current,{onPointerInTransitChange:h}=r,m=d.useCallback(()=>{a(null),h(!1)},[h]),g=d.useCallback((x,p)=>{const v=x.currentTarget,y={x:x.clientX,y:x.clientY},w=m0(y,v.getBoundingClientRect()),S=g0(y,w),_=v0(p.getBoundingClientRect()),R=b0([...S,..._]);a(R),h(!0)},[h]);return d.useEffect(()=>()=>m(),[m]),d.useEffect(()=>{if(c&&f){const x=v=>g(v,f),p=v=>g(v,c);return c.addEventListener("pointerleave",x),f.addEventListener("pointerleave",p),()=>{c.removeEventListener("pointerleave",x),f.removeEventListener("pointerleave",p)}}},[c,f,g,m]),d.useEffect(()=>{if(i){const x=p=>{const v=p.target,y={x:p.clientX,y:p.clientY},w=(c==null?void 0:c.contains(v))||(f==null?void 0:f.contains(v)),S=!y0(y,i);w?m():S&&(m(),l())};return document.addEventListener("pointermove",x),()=>document.removeEventListener("pointermove",x)}},[c,f,i,l,m]),u.jsx(zu,{...e,ref:s})}),[f0,h0]=xo(Zn,{isInside:!1}),p0=s0("TooltipContent"),zu=d.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:s,onPointerDownOutside:i,...a}=e,c=lr(On,n),l=So(n),{onClose:f}=c;return d.useEffect(()=>(document.addEventListener(Ns,f),()=>document.removeEventListener(Ns,f)),[f]),d.useEffect(()=>{if(c.trigger){const h=m=>{const g=m.target;g!=null&&g.contains(c.trigger)&&f()};return window.addEventListener("scroll",h,{capture:!0}),()=>window.removeEventListener("scroll",h,{capture:!0})}},[c.trigger,f]),u.jsx(fo,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:h=>h.preventDefault(),onDismiss:f,children:u.jsxs(tu,{"data-state":c.stateAttribute,...l,...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:[u.jsx(p0,{children:r}),u.jsx(f0,{scope:n,isInside:!0,children:u.jsx(Sv,{id:c.contentId,role:"tooltip",children:o||r})})]})})});Vu.displayName=On;var qu="TooltipArrow",Gu=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=So(n);return h0(qu,n).isInside?null:u.jsx(nu,{...o,...r,ref:t})});Gu.displayName=qu;function m0(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 g0(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 v0(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 y0(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],c=t[i],l=a.x,f=a.y,h=c.x,m=c.y;f>r!=m>r&&n<(h-l)*(r-f)/(m-f)+l&&(o=!o)}return o}function b0(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),w0(t)}function w0(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 C0=Bu,x0=Uu,S0=Wu,E0=Hu,_0=Vu,R0=Gu;const T0="tooltip__nUuSh",P0="tooltipArrow__W2w-f",Qa={tooltip:T0,tooltipArrow:P0},Ku=E.createContext(null),A0=({container:e,children:t})=>u.jsx(Ku.Provider,{value:e,children:t}),pi=()=>E.useContext(Ku)??void 0,jn=({children:e,open:t,displayName:n,tooltipContent:r,className:o,disabled:s,delayDuration:i=300,side:a="right",sideOffset:c=0})=>{const[l,f]=E.useState(!1),h=pi(),m=t!==void 0,x=s?!1:m?t:l,p=v=>{s||m||f(v)};return u.jsx(C0,{delayDuration:i,children:u.jsxs(x0,{open:x,onOpenChange:p,children:[u.jsx(S0,{asChild:!0,children:e}),u.jsx(E0,{container:h,children:u.jsxs(_0,{className:N(Qa.tooltip,o),side:a,sideOffset:c,children:[n,r,u.jsx(R0,{className:Qa.tooltipArrow})]})})]})})};jn.displayName="Tooltip";const O0="truncatedText__Y-jSd",j0="overflowing__o8TC-",Ya={truncatedText:O0,overflowing:j0},Qu=({children:e,className:t,tooltipSide:n="top",tooltipClassName:r})=>{const o=E.useRef(null),[s,i]=E.useState(!1);E.useEffect(()=>{const c=()=>{if(o.current){const l=o.current.scrollWidth>o.current.clientWidth;i(l)}};return c(),window.addEventListener("resize",c),()=>{window.removeEventListener("resize",c)}},[e]);const a=u.jsx("span",{ref:o,className:N(Ya.truncatedText,s?Ya.overflowing:"",t||""),children:e});return s?u.jsx(jn,{tooltipContent:e,side:n,className:r,children:a}):a};Qu.displayName="TextWithTooltip";const I0="SearchInput__4OFyE",N0="SearchIcon__YgnQy",D0="ClearIcon__ukRVr",L0="SearchInput__ClearIcon__uzVoc",M0="SearchInput__SearchIcon__zoDG4",Wn={SearchInput:I0,SearchIcon:N0,ClearIcon:D0,SearchInput__ClearIcon:L0,SearchInput__SearchIcon:M0},mi=E.forwardRef(({className:e,placeholder:t="Type to search...",showClearButton:n=!1,showSearchIcon:r=!0,onClear:o,...s},i)=>{const a=N(Wn.SearchInput,n&&Wn.SearchInput__ClearIcon,r&&Wn.SearchInput__SearchIcon,e),c=N(Wn.SearchIcon),l=N(Wn.ClearIcon);return u.jsxs("div",{className:a,children:[u.jsx(uo,{ref:i,type:"text",placeholder:t,...s}),r&&u.jsx("svg",{className:c,width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.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&&u.jsx("svg",{className:l,width:"8",height:"8",viewBox:"0 0 8 8",fill:"none",xmlns:"http://www.w3.org/2000/svg",onClick:o,children:u.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"})})]})});mi.displayName="SearchInput";const k0="SearchAutocomplete__vR9Hk",$0="AutocompleteItem__YIm7R",F0="AutocompleteHighlighter__LAFTV",B0="AutocompleteHighlighter__match__Wy1o2",U0="DropdownList__-fHIk",W0="AutocompleteItemDescription__4QYN5",Xt={SearchAutocomplete:k0,AutocompleteItem:$0,"AutocompleteItem--canBeSelected":"AutocompleteItem--canBeSelected__jxk4z",AutocompleteHighlighter:F0,AutocompleteHighlighter__match:B0,DropdownList:U0,AutocompleteItemDescription:W0},H0="DropdownList__QTXXX",V0="DropdownList__QTXXX",z0="DropdownList--closed__pdL1Z",q0="DropdownList--open__opzc9",G0="DropdownList--left__xSwXR",Wt={DropdownList:H0,dropdownList:V0,"DropdownList--closed":"DropdownList--closed__pdL1Z",dropdownListClosed:z0,"DropdownList--open":"DropdownList--open__opzc9",dropdownListOpen:q0,"DropdownList--left":"DropdownList--left__xSwXR",dropdownListLeft:G0},Eo=E.forwardRef(({children:e,className:t,open:n,align:r="right",...o},s)=>{const i=N(Wt.DropdownList,{[Wt["DropdownList--open"]]:n,[Wt["DropdownList--closed"]]:!n,[Wt["DropdownList--left"]]:r==="left"},t);return u.jsx("div",{ref:s,className:i,...o,children:e})});Eo.displayName="DropdownList";const qn=E.forwardRef(({children:e,className:t,canBeSelected:n=!1,...r},o)=>{const s=N(Xt.AutocompleteItem,{[Xt["AutocompleteItem--canBeSelected"]]:n},t);return u.jsx("div",{ref:o,className:s,role:n?"option":void 0,...r,children:e})});qn.displayName="AutocompleteItem";const K0=300,Q0={query:"",suggestions:[],loading:!1,error:null},Y0=({suggestionFetcher:e,canAdd:t})=>{const[n,r]=E.useState(Q0);return E.useEffect(()=>{r(a=>({...a,loading:!0}));const s=async()=>{try{const a=await e(n.query);t&&!a.some(c=>c.value.toLowerCase()===n.query.toLowerCase())&&a.push({label:`Add "${n.query}"`,value:n.query,isNew:!0}),r(c=>({...c,suggestions:a,loading:!1}))}catch(a){r(c=>({...c,suggestions:[],error:a,loading:!1}))}},i=setTimeout(()=>{s()},K0);return()=>{clearTimeout(i)}},[n.query]),{...n,setQuery:s=>{r(i=>({...i,query:s}))}}},Yu=E.forwardRef(({text:e,query:t,className:n,...r},o)=>{const s=N(Xt.AutocompleteHighlighter,n),i=(a,c)=>{const l=a.toLowerCase().indexOf(c.toLowerCase());if(l===-1||c.length===0)return a;const f=a.slice(0,l),h=a.slice(l,l+c.length),m=a.slice(l+c.length);return u.jsxs(u.Fragment,{children:[f,u.jsx("span",{className:Xt.AutocompleteHighlighter__match,children:h}),i(m,c)]})};return u.jsx("div",{ref:o,className:s,...r,children:i(e,t)})});Yu.displayName="AutocompleteHighlighter";const Z0=5,Zu=E.forwardRef(({children:e,className:t,canAdd:n,maxSuggestionsShown:r=Z0,searchInputProps:o,keepSelectedOption:s,suggestionFetcher:i,onAccept:a,...c},l)=>{const{query:f,setQuery:h,suggestions:m,loading:g}=Y0({suggestionFetcher:i,canAdd:n}),[x,p]=E.useState(null),v=f.length>0,y=P=>{h(P.target.value)},w=P=>{a==null||a(P),s?(p(P),h(P.value)):h("")},S=()=>{a==null||a(null),p(null),h("")},_=N(Xt.SearchAutocomplete,t),R=m.slice(0,r),T=m.slice(r);return u.jsxs("div",{ref:l,className:_,...c,children:[u.jsx(mi,{...o,value:f,onChange:y,showClearButton:!!x,onClear:S}),e,u.jsxs(Eo,{className:Xt.DropdownList,open:v&&!x,role:"listbox","aria-label":"Suggestions",children:[g?u.jsx(qn,{children:"Loading..."}):R.map(P=>u.jsxs(qn,{canBeSelected:!0,onClick:w.bind(null,P),children:[u.jsx(Yu,{text:P.label,query:f}),P.description&&u.jsx("span",{className:Xt.AutocompleteItemDescription,children:P.description})]},P.value)),!g&&T.length>0&&u.jsxs(qn,{children:[T.length," more results"]}),v&&m.length===0&&!g&&u.jsx(qn,{children:"No results found"})]})]})});Zu.displayName="SearchAutocomplete";const It=e=>{let t=null,n=null;return E.Children.forEach(e.children,r=>{const o=r.props.condition;o===void 0?n=r:!t&&o===!0&&(t=r)}),u.jsx(u.Fragment,{children:t||n})};It.displayName="Show";It.When=({condition:e,children:t})=>u.jsx(u.Fragment,{children:e&&t});It.Else=({render:e,children:t})=>u.jsx(u.Fragment,{children:e||t});var X0=Symbol.for("react.lazy"),to=d[" use ".trim().toString()];function J0(e){return typeof e=="object"&&e!==null&&"then"in e}function Xu(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===X0&&"_payload"in e&&J0(e._payload)}function e2(e){const t=n2(e),n=d.forwardRef((r,o)=>{let{children:s,...i}=r;Xu(s)&&typeof to=="function"&&(s=to(s._payload));const a=d.Children.toArray(s),c=a.find(o2);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}var t2=e2("Slot");function n2(e){const t=d.forwardRef((n,r)=>{let{children:o,...s}=n;if(Xu(o)&&typeof to=="function"&&(o=to(o._payload)),d.isValidElement(o)){const i=i2(o),a=s2(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 r2=Symbol("radix.slottable");function o2(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===r2}function s2(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function i2(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 a2="SkeletonListContainer__MKJhE",c2="Skeleton__Ovpiw",Ju={SkeletonListContainer:a2,Skeleton:c2},_o=E.forwardRef((e,t)=>{const{children:n,className:r,loading:o,height:s=48,width:i,borderRadius:a,style:c,...l}=e;if(!o&&n)return n;const f=E.isValidElement(n)?t2:"span";return u.jsx(f,{ref:t,"aria-hidden":!0,className:N(Ju.Skeleton,r),style:{...c,width:i,minWidth:i,height:s,borderRadius:a},"data-inline-skeleton":E.isValidElement(n)?void 0:!0,tabIndex:-1,...l,children:n})});_o.displayName="Skeleton";const ed=e=>{const{numberOfItems:t,itemsGap:n=2,itemProps:r}=e,o=Array.from({length:t},(s,i)=>i+1);return u.jsx("div",{className:N(Ju.SkeletonListContainer),style:{gap:n},children:o.map(s=>u.jsx(_o,{loading:!0,...r},s))})};ed.displayName="SkeletonList";const l2="spinner__qa7F6",u2="rotate__EqlXe",d2="spinner-dark__9A9-q",f2="spinner-white__gRbtI",h2="spinner-success__otWGm",p2="spinner-danger__Bq5DM",m2="spinner-warning__U900K",Za={spinner:l2,rotate:u2,"spinner-dark":"spinner-dark__9A9-q",spinnerDark:d2,"spinner-white":"spinner-white__gRbtI",spinnerWhite:f2,"spinner-success":"spinner-success__otWGm",spinnerSuccess:h2,"spinner-danger":"spinner-danger__Bq5DM",spinnerDanger:p2,"spinner-warning":"spinner-warning__U900K",spinnerWarning:m2},td=({className:e,color:t="white",size:n=80,thickness:r})=>{const o=N(Za.spinner,Za[`spinner-${t}`],e),s=r??Math.max(n/12,2);return u.jsx("span",{style:{width:n,height:n,borderWidth:s},className:o})};td.displayName="Spinner";const g2="disabled__KpauE",v2="checked__2-JV-",y2="thumb__fEuKD",jr={switch:"switch__0b2av",disabled:g2,checked:v2,thumb:y2},nd=E.forwardRef(({checked:e,defaultChecked:t=!1,onCheckedChange:n,disabled:r=!1,id:o,className:s,name:i,"aria-label":a,"aria-labelledby":c,"aria-describedby":l,...f},h)=>{const[m,g]=E.useState(t),x=e!==void 0,p=x?!!e:m,v=()=>{if(r)return;const w=!p;x||g(w),n==null||n(w)},y=w=>{(w.key===" "||w.key==="Enter")&&(w.preventDefault(),v())};return u.jsx("button",{ref:h,type:"button",role:"switch","aria-checked":p,"aria-label":a,"aria-labelledby":c,"aria-describedby":l,disabled:r,id:o,name:i,className:N(jr.switch,{[jr.checked]:p,[jr.disabled]:r}),onClick:v,onKeyDown:y,...f,children:u.jsx("span",{className:jr.thumb,"aria-hidden":"true"})})});nd.displayName="Switch";const b2="tabs-root__ELmdj",w2="tabs-list__rc10N",C2="tabs-list--horizontal__e1YW4",x2="tabs-list--vertical__huK05",S2="tabs-trigger__D8R4R",E2="tabs-trigger--disabled__ezDWc",_2="tabs-trigger--horizontal__4jBFV",R2="tabs-trigger--active__S-Z-S",T2="tabs-trigger--vertical__dNVIZ",P2="tabs-content__1d77o",Ze={tabsRoot:b2,tabsList:w2,tabsListHorizontal:C2,tabsListVertical:x2,tabsTrigger:S2,tabsTriggerDisabled:E2,tabsTriggerHorizontal:_2,tabsTriggerActive:R2,tabsTriggerVertical:T2,tabsContent:P2},rd=E.createContext(null),gi=()=>{const e=E.useContext(rd);if(!e)throw new Error("Tabs components must be used within a Tabs provider");return e},A2=({defaultValue:e,value:t,onValueChange:n,orientation:r="horizontal",className:o="",children:s})=>{const[i,a]=E.useState(e||""),c=t!==void 0,l=c?t:i,f=h=>{c||a(h),n==null||n(h)};return u.jsx(rd.Provider,{value:{value:l,onValueChange:f,orientation:r},children:u.jsx("div",{className:N(Ze.tabsRoot,o),children:s})})},O2=({className:e="",children:t})=>{const{orientation:n}=gi(),r=E.useRef(null),o=s=>{var l;const i=(l=r.current)==null?void 0:l.querySelectorAll('[role="tab"]:not([disabled])');if(!i)return;const a=Array.from(i).findIndex(f=>f===document.activeElement);let c=a;switch(s.key){case"ArrowLeft":n==="horizontal"&&(s.preventDefault(),c=a>0?a-1:i.length-1);break;case"ArrowRight":n==="horizontal"&&(s.preventDefault(),c=a<i.length-1?a+1:0);break;case"ArrowUp":n==="vertical"&&(s.preventDefault(),c=a>0?a-1:i.length-1);break;case"ArrowDown":n==="vertical"&&(s.preventDefault(),c=a<i.length-1?a+1:0);break;case"Home":s.preventDefault(),c=0;break;case"End":s.preventDefault(),c=i.length-1;break}if(c!==a){const f=i[c];f.focus(),f.click()}};return u.jsx("div",{ref:r,role:"tablist","aria-orientation":n,onKeyDown:o,className:N(Ze.tabsList,n==="horizontal"?Ze.tabsListHorizontal:Ze.tabsListVertical,e),children:t})},j2=({value:e,disabled:t=!1,className:n="",children:r})=>{const{value:o,onValueChange:s,orientation:i}=gi(),a=o===e,c=()=>{t||s(e)};return u.jsx("button",{role:"tab","aria-selected":a,"aria-controls":`content-${e}`,tabIndex:a?0:-1,disabled:t,onClick:c,className:N(Ze.tabsTrigger,i==="horizontal"?Ze.tabsTriggerHorizontal:Ze.tabsTriggerVertical,a&&Ze.tabsTriggerActive,t&&Ze.tabsTriggerDisabled,n),children:r})},I2=({value:e,className:t="",children:n})=>{const{value:r}=gi();return r===e?u.jsx("div",{role:"tabpanel",id:`content-${e}`,"aria-labelledby":`trigger-${e}`,tabIndex:0,className:N(Ze.tabsContent,t),children:n}):null},od=({className:e,state:t="open",onClick:n})=>t==="open"?u.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:[u.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"}),u.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"})]}):u.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:u.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"})}),N2="PasswordInput__GDJDN",D2="eyeIcon__kDExG",Xa={PasswordInput:N2,eyeIcon:D2},L2=E.forwardRef((e,t)=>{const[n,r]=E.useState("password"),o=E.useCallback(()=>{r(s=>s==="password"?"text":"password")},[r]);return u.jsxs("div",{className:N(Xa.PasswordInput,e.className),children:[u.jsx(uo,{type:n,...e,ref:t}),u.jsx(od,{className:Xa.eyeIcon,onClick:o,state:n==="password"?"open":"closed"})]})});function M2(e){const t=k2(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),c=a.find(F2);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function k2(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=U2(o),a=B2(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 $2=Symbol("radix.slottable");function F2(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===$2}function B2(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function U2(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 Ro="Dialog",[sd]=ar(Ro),[W2,He]=sd(Ro),id=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:s,modal:i=!0}=e,a=d.useRef(null),c=d.useRef(null),[l,f]=Jr({prop:r,defaultProp:o??!1,onChange:s,caller:Ro});return u.jsx(W2,{scope:t,triggerRef:a,contentRef:c,contentId:Zt(),titleId:Zt(),descriptionId:Zt(),open:l,onOpenChange:f,onOpenToggle:d.useCallback(()=>f(h=>!h),[f]),modal:i,children:n})};id.displayName=Ro;var ad="DialogTrigger",H2=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(ad,n),s=ce(t,o.triggerRef);return u.jsx(ie.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":bi(o.open),...r,ref:s,onClick:X(e.onClick,o.onOpenToggle)})});H2.displayName=ad;var vi="DialogPortal",[V2,cd]=sd(vi,{forceMount:void 0}),ld=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,s=He(vi,t);return u.jsx(V2,{scope:t,forceMount:n,children:d.Children.map(r,i=>u.jsx(Fn,{present:n||s.open,children:u.jsx(li,{asChild:!0,container:o,children:i})}))})};ld.displayName=vi;var no="DialogOverlay",ud=d.forwardRef((e,t)=>{const n=cd(no,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=He(no,e.__scopeDialog);return s.modal?u.jsx(Fn,{present:r||s.open,children:u.jsx(q2,{...o,ref:t})}):null});ud.displayName=no;var z2=M2("DialogOverlay.RemoveScroll"),q2=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(no,n);return u.jsx(ui,{as:z2,allowPinchZoom:!0,shards:[o.contentRef],children:u.jsx(ie.div,{"data-state":bi(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),sn="DialogContent",dd=d.forwardRef((e,t)=>{const n=cd(sn,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=He(sn,e.__scopeDialog);return u.jsx(Fn,{present:r||s.open,children:s.modal?u.jsx(G2,{...o,ref:t}):u.jsx(K2,{...o,ref:t})})});dd.displayName=sn;var G2=d.forwardRef((e,t)=>{const n=He(sn,e.__scopeDialog),r=d.useRef(null),o=ce(t,n.contentRef,r);return d.useEffect(()=>{const s=r.current;if(s)return iu(s)},[]),u.jsx(fd,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:X(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:X(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&s.preventDefault()}),onFocusOutside:X(e.onFocusOutside,s=>s.preventDefault())})}),K2=d.forwardRef((e,t)=>{const n=He(sn,e.__scopeDialog),r=d.useRef(!1),o=d.useRef(!1);return u.jsx(fd,{...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 c,l;(c=e.onInteractOutside)==null||c.call(e,s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=s.target;((l=n.triggerRef.current)==null?void 0:l.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),fd=d.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:s,...i}=e,a=He(sn,n),c=d.useRef(null),l=ce(t,c);return Ol(),u.jsxs(u.Fragment,{children:[u.jsx(ei,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:s,children:u.jsx(fo,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":bi(a.open),...i,ref:l,onDismiss:()=>a.onOpenChange(!1)})}),u.jsxs(u.Fragment,{children:[u.jsx(Q2,{titleId:a.titleId}),u.jsx(Z2,{contentRef:c,descriptionId:a.descriptionId})]})]})}),yi="DialogTitle",hd=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(yi,n);return u.jsx(ie.h2,{id:o.titleId,...r,ref:t})});hd.displayName=yi;var pd="DialogDescription",md=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(pd,n);return u.jsx(ie.p,{id:o.descriptionId,...r,ref:t})});md.displayName=pd;var gd="DialogClose",vd=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(gd,n);return u.jsx(ie.button,{type:"button",...r,ref:t,onClick:X(e.onClick,()=>o.onOpenChange(!1))})});vd.displayName=gd;function bi(e){return e?"open":"closed"}var yd="DialogTitleWarning",[Zb,bd]=um(yd,{contentName:sn,titleName:yi,docsSlug:"dialog"}),Q2=({titleId:e})=>{const t=bd(yd),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
251
|
+
`)},sv=0,hn=[];function iv(e){var t=d.useRef([]),n=d.useRef([0,0]),r=d.useRef(),o=d.useState(sv++)[0],s=d.useState(uu)[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 p=Hr([e.lockRef.current],(e.shards||[]).map(Qa),!0).filter(Boolean);return p.forEach(function(y){return y.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),p.forEach(function(y){return y.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var a=d.useCallback(function(p,y){if("touches"in p&&p.touches.length===2||p.type==="wheel"&&p.ctrlKey)return!i.current.allowPinchZoom;var v=Ar(p),w=n.current,S="deltaX"in p?p.deltaX:w[0]-v[0],_="deltaY"in p?p.deltaY:w[1]-v[1],R,T=p.target,P=Math.abs(S)>Math.abs(_)?"h":"v";if("touches"in p&&P==="h"&&T.type==="range")return!1;var D=window.getSelection(),I=D&&D.anchorNode,L=I?I===T||I.contains(T):!1;if(L)return!1;var B=Ga(P,T);if(!B)return!0;if(B?R=P:(R=P==="v"?"h":"v",B=Ga(P,T)),!B)return!1;if(!r.current&&"changedTouches"in p&&(S||_)&&(r.current=R),!R)return!0;var U=r.current||R;return nv(U,y,p,U==="h"?S:_)},[]),c=d.useCallback(function(p){var y=p;if(!(!hn.length||hn[hn.length-1]!==s)){var v="deltaY"in y?Ka(y):Ar(y),w=t.current.filter(function(R){return R.name===y.type&&(R.target===y.target||y.target===R.shadowParent)&&rv(R.delta,v)})[0];if(w&&w.should){y.cancelable&&y.preventDefault();return}if(!w){var S=(i.current.shards||[]).map(Qa).filter(Boolean).filter(function(R){return R.contains(y.target)}),_=S.length>0?a(y,S[0]):!i.current.noIsolation;_&&y.cancelable&&y.preventDefault()}}},[]),l=d.useCallback(function(p,y,v,w){var S={name:p,delta:y,target:v,should:w,shadowParent:av(v)};t.current.push(S),setTimeout(function(){t.current=t.current.filter(function(_){return _!==S})},1)},[]),f=d.useCallback(function(p){n.current=Ar(p),r.current=void 0},[]),h=d.useCallback(function(p){l(p.type,Ka(p),p.target,a(p,e.lockRef.current))},[]),m=d.useCallback(function(p){l(p.type,Ar(p),p.target,a(p,e.lockRef.current))},[]);d.useEffect(function(){return hn.push(s),e.setCallbacks({onScrollCapture:h,onWheelCapture:h,onTouchMoveCapture:m}),document.addEventListener("wheel",c,fn),document.addEventListener("touchmove",c,fn),document.addEventListener("touchstart",f,fn),function(){hn=hn.filter(function(p){return p!==s}),document.removeEventListener("wheel",c,fn),document.removeEventListener("touchmove",c,fn),document.removeEventListener("touchstart",f,fn)}},[]);var g=e.removeScrollBar,x=e.inert;return d.createElement(d.Fragment,null,x?d.createElement(s,{styles:ov(o)}):null,g?d.createElement(Qy,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function av(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const cv=My(lu,iv);var di=d.forwardRef(function(e,t){return d.createElement(bo,Ye({},e,{ref:t,sideCar:cv}))});di.classNames=bo.classNames;var lv=[" ","Enter","ArrowUp","ArrowDown"],uv=[" ","Enter"],rn="Select",[wo,Co,dv]=vm(rn),[$n]=ar(rn,[dv,vo]),xo=vo(),[fv,$t]=$n(rn),[hv,pv]=$n(rn),pu=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:s,value:i,defaultValue:a,onValueChange:c,dir:l,name:f,autoComplete:h,disabled:m,required:g,form:x}=e,p=xo(t),[y,v]=d.useState(null),[w,S]=d.useState(null),[_,R]=d.useState(!1),T=wm(l),[P,D]=Jr({prop:r,defaultProp:o??!1,onChange:s,caller:rn}),[I,L]=Jr({prop:i,defaultProp:a,onChange:c,caller:rn}),B=d.useRef(null),U=y?x||!!y.closest("form"):!0,[W,V]=d.useState(new Set),re=Array.from(W).map(q=>q.props.value).join(";");return u.jsx(eu,{...p,children:u.jsxs(fv,{required:g,scope:t,trigger:y,onTriggerChange:v,valueNode:w,onValueNodeChange:S,valueNodeHasChildren:_,onValueNodeHasChildrenChange:R,contentId:Zt(),value:I,onValueChange:L,open:P,onOpenChange:D,dir:T,triggerPointerDownPosRef:B,disabled:m,children:[u.jsx(wo.Provider,{scope:t,children:u.jsx(hv,{scope:e.__scopeSelect,onNativeOptionAdd:d.useCallback(q=>{V(Q=>new Set(Q).add(q))},[]),onNativeOptionRemove:d.useCallback(q=>{V(Q=>{const $=new Set(Q);return $.delete(q),$})},[]),children:n})}),U?u.jsxs(Du,{"aria-hidden":!0,required:g,tabIndex:-1,name:f,autoComplete:h,value:I,onChange:q=>L(q.target.value),disabled:m,form:x,children:[I===void 0?u.jsx("option",{value:""}):null,Array.from(W)]},re):null]})})};pu.displayName=rn;var mu="SelectTrigger",gu=d.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,s=xo(n),i=$t(mu,n),a=i.disabled||r,c=ce(t,i.onTriggerChange),l=Co(n),f=d.useRef("touch"),[h,m,g]=Mu(p=>{const y=l().filter(S=>!S.disabled),v=y.find(S=>S.value===i.value),w=ku(y,p,v);w!==void 0&&i.onValueChange(w.value)}),x=p=>{a||(i.onOpenChange(!0),g()),p&&(i.triggerPointerDownPosRef.current={x:Math.round(p.pageX),y:Math.round(p.pageY)})};return u.jsx(tu,{asChild:!0,...s,children:u.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":Lu(i.value)?"":void 0,...o,ref:c,onClick:X(o.onClick,p=>{p.currentTarget.focus(),f.current!=="mouse"&&x(p)}),onPointerDown:X(o.onPointerDown,p=>{f.current=p.pointerType;const y=p.target;y.hasPointerCapture(p.pointerId)&&y.releasePointerCapture(p.pointerId),p.button===0&&p.ctrlKey===!1&&p.pointerType==="mouse"&&(x(p),p.preventDefault())}),onKeyDown:X(o.onKeyDown,p=>{const y=h.current!=="";!(p.ctrlKey||p.altKey||p.metaKey)&&p.key.length===1&&m(p.key),!(y&&p.key===" ")&&lv.includes(p.key)&&(x(),p.preventDefault())})})})});gu.displayName=mu;var yu="SelectValue",vu=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:s,placeholder:i="",...a}=e,c=$t(yu,n),{onValueNodeHasChildrenChange:l}=c,f=s!==void 0,h=ce(t,c.onValueNodeChange);return ye(()=>{l(f)},[l,f]),u.jsx(ie.span,{...a,ref:h,style:{pointerEvents:"none"},children:Lu(c.value)?u.jsx(u.Fragment,{children:i}):s})});vu.displayName=yu;var mv="SelectIcon",bu=d.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return u.jsx(ie.span,{"aria-hidden":!0,...o,ref:t,children:r||"▼"})});bu.displayName=mv;var on="SelectContent",wu=d.forwardRef((e,t)=>{const n=$t(on,e.__scopeSelect),[r,o]=d.useState();if(ye(()=>{o(new DocumentFragment)},[]),!n.open){const s=r;return s?io.createPortal(u.jsx(Cu,{scope:e.__scopeSelect,children:u.jsx(wo.Slot,{scope:e.__scopeSelect,children:u.jsx("div",{children:e.children})})}),s):null}return u.jsx(xu,{...e,ref:t})});wu.displayName=on;var Me=10,[Cu,Ft]=$n(on),gv="SelectContentImpl",yv=hy("SelectContent.RemoveScroll"),xu=d.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:s,onPointerDownOutside:i,side:a,sideOffset:c,align:l,alignOffset:f,arrowPadding:h,collisionBoundary:m,collisionPadding:g,sticky:x,hideWhenDetached:p,avoidCollisions:y,...v}=e,w=$t(on,n),[S,_]=d.useState(null),[R,T]=d.useState(null),P=ce(t,k=>_(k)),[D,I]=d.useState(null),[L,B]=d.useState(null),U=Co(n),[W,V]=d.useState(!1),re=d.useRef(!1);d.useEffect(()=>{if(S)return au(S)},[S]),jl();const q=d.useCallback(k=>{const[J,...de]=U().map(Z=>Z.ref.current),[Y]=de.slice(-1),ee=document.activeElement;for(const Z of k)if(Z===ee||(Z==null||Z.scrollIntoView({block:"nearest"}),Z===J&&R&&(R.scrollTop=0),Z===Y&&R&&(R.scrollTop=R.scrollHeight),Z==null||Z.focus(),document.activeElement!==ee))return},[U,R]),Q=d.useCallback(()=>q([D,S]),[q,D,S]);d.useEffect(()=>{W&&Q()},[W,Q]);const{onOpenChange:$,triggerPointerDownPosRef:oe}=w;d.useEffect(()=>{if(S){let k={x:0,y:0};const J=Y=>{var ee,Z;k={x:Math.abs(Math.round(Y.pageX)-(((ee=oe.current)==null?void 0:ee.x)??0)),y:Math.abs(Math.round(Y.pageY)-(((Z=oe.current)==null?void 0:Z.y)??0))}},de=Y=>{k.x<=10&&k.y<=10?Y.preventDefault():S.contains(Y.target)||$(!1),document.removeEventListener("pointermove",J),oe.current=null};return oe.current!==null&&(document.addEventListener("pointermove",J),document.addEventListener("pointerup",de,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",J),document.removeEventListener("pointerup",de,{capture:!0})}}},[S,$,oe]),d.useEffect(()=>{const k=()=>$(!1);return window.addEventListener("blur",k),window.addEventListener("resize",k),()=>{window.removeEventListener("blur",k),window.removeEventListener("resize",k)}},[$]);const[pe,Oe]=Mu(k=>{const J=U().filter(ee=>!ee.disabled),de=J.find(ee=>ee.ref.current===document.activeElement),Y=ku(J,k,de);Y&&setTimeout(()=>Y.ref.current.focus())}),pt=d.useCallback((k,J,de)=>{const Y=!re.current&&!de;(w.value!==void 0&&w.value===J||Y)&&(I(k),Y&&(re.current=!0))},[w.value]),mt=d.useCallback(()=>S==null?void 0:S.focus(),[S]),Ve=d.useCallback((k,J,de)=>{const Y=!re.current&&!de;(w.value!==void 0&&w.value===J||Y)&&B(k)},[w.value]),gt=r==="popper"?As:Su,De=gt===As?{side:a,sideOffset:c,align:l,alignOffset:f,arrowPadding:h,collisionBoundary:m,collisionPadding:g,sticky:x,hideWhenDetached:p,avoidCollisions:y}:{};return u.jsx(Cu,{scope:n,content:S,viewport:R,onViewportChange:T,itemRefCallback:pt,selectedItem:D,onItemLeave:mt,itemTextRefCallback:Ve,focusSelectedItem:Q,selectedItemText:L,position:r,isPositioned:W,searchRef:pe,children:u.jsx(di,{as:yv,allowPinchZoom:!0,children:u.jsx(ti,{asChild:!0,trapped:w.open,onMountAutoFocus:k=>{k.preventDefault()},onUnmountAutoFocus:X(o,k=>{var J;(J=w.trigger)==null||J.focus({preventScroll:!0}),k.preventDefault()}),children:u.jsx(ho,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:k=>k.preventDefault(),onDismiss:()=>w.onOpenChange(!1),children:u.jsx(gt,{role:"listbox",id:w.contentId,"data-state":w.open?"open":"closed",dir:w.dir,onContextMenu:k=>k.preventDefault(),...v,...De,onPlaced:()=>V(!0),ref:P,style:{display:"flex",flexDirection:"column",outline:"none",...v.style},onKeyDown:X(v.onKeyDown,k=>{const J=k.ctrlKey||k.altKey||k.metaKey;if(k.key==="Tab"&&k.preventDefault(),!J&&k.key.length===1&&Oe(k.key),["ArrowUp","ArrowDown","Home","End"].includes(k.key)){let Y=U().filter(ee=>!ee.disabled).map(ee=>ee.ref.current);if(["ArrowUp","End"].includes(k.key)&&(Y=Y.slice().reverse()),["ArrowUp","ArrowDown"].includes(k.key)){const ee=k.target,Z=Y.indexOf(ee);Y=Y.slice(Z+1)}setTimeout(()=>q(Y)),k.preventDefault()}})})})})})})});xu.displayName=gv;var vv="SelectItemAlignedPosition",Su=d.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,s=$t(on,n),i=Ft(on,n),[a,c]=d.useState(null),[l,f]=d.useState(null),h=ce(t,P=>f(P)),m=Co(n),g=d.useRef(!1),x=d.useRef(!0),{viewport:p,selectedItem:y,selectedItemText:v,focusSelectedItem:w}=i,S=d.useCallback(()=>{if(s.trigger&&s.valueNode&&a&&l&&p&&y&&v){const P=s.trigger.getBoundingClientRect(),D=l.getBoundingClientRect(),I=s.valueNode.getBoundingClientRect(),L=v.getBoundingClientRect();if(s.dir!=="rtl"){const ee=L.left-D.left,Z=I.left-ee,ve=P.left-Z,je=P.width+ve,qe=Math.max(je,D.width),Le=window.innerWidth-Me,yt=Ea(Z,[Me,Math.max(Me,Le-qe)]);a.style.minWidth=je+"px",a.style.left=yt+"px"}else{const ee=D.right-L.right,Z=window.innerWidth-I.right-ee,ve=window.innerWidth-P.right-Z,je=P.width+ve,qe=Math.max(je,D.width),Le=window.innerWidth-Me,yt=Ea(Z,[Me,Math.max(Me,Le-qe)]);a.style.minWidth=je+"px",a.style.right=yt+"px"}const B=m(),U=window.innerHeight-Me*2,W=p.scrollHeight,V=window.getComputedStyle(l),re=parseInt(V.borderTopWidth,10),q=parseInt(V.paddingTop,10),Q=parseInt(V.borderBottomWidth,10),$=parseInt(V.paddingBottom,10),oe=re+q+W+$+Q,pe=Math.min(y.offsetHeight*5,oe),Oe=window.getComputedStyle(p),pt=parseInt(Oe.paddingTop,10),mt=parseInt(Oe.paddingBottom,10),Ve=P.top+P.height/2-Me,gt=U-Ve,De=y.offsetHeight/2,k=y.offsetTop+De,J=re+q+k,de=oe-J;if(J<=Ve){const ee=B.length>0&&y===B[B.length-1].ref.current;a.style.bottom="0px";const Z=l.clientHeight-p.offsetTop-p.offsetHeight,ve=Math.max(gt,De+(ee?mt:0)+Z+Q),je=J+ve;a.style.height=je+"px"}else{const ee=B.length>0&&y===B[0].ref.current;a.style.top="0px";const ve=Math.max(Ve,re+p.offsetTop+(ee?pt:0)+De)+de;a.style.height=ve+"px",p.scrollTop=J-Ve+p.offsetTop}a.style.margin=`${Me}px 0`,a.style.minHeight=pe+"px",a.style.maxHeight=U+"px",r==null||r(),requestAnimationFrame(()=>g.current=!0)}},[m,s.trigger,s.valueNode,a,l,p,y,v,s.dir,r]);ye(()=>S(),[S]);const[_,R]=d.useState();ye(()=>{l&&R(window.getComputedStyle(l).zIndex)},[l]);const T=d.useCallback(P=>{P&&x.current===!0&&(S(),w==null||w(),x.current=!1)},[S,w]);return u.jsx(wv,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:g,onScrollButtonChange:T,children:u.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:_},children:u.jsx(ie.div,{...o,ref:h,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});Su.displayName=vv;var bv="SelectPopperPosition",As=d.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=Me,...s}=e,i=xo(n);return u.jsx(nu,{...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)"}})});As.displayName=bv;var[wv,fi]=$n(on,{}),Os="SelectViewport",Eu=d.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...o}=e,s=Ft(Os,n),i=fi(Os,n),a=ce(t,s.onViewportChange),c=d.useRef(0);return u.jsxs(u.Fragment,{children:[u.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}),u.jsx(wo.Slot,{scope:n,children:u.jsx(ie.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:X(o.onScroll,l=>{const f=l.currentTarget,{contentWrapper:h,shouldExpandOnScrollRef:m}=i;if(m!=null&&m.current&&h){const g=Math.abs(c.current-f.scrollTop);if(g>0){const x=window.innerHeight-Me*2,p=parseFloat(h.style.minHeight),y=parseFloat(h.style.height),v=Math.max(p,y);if(v<x){const w=v+g,S=Math.min(x,w),_=w-S;h.style.height=S+"px",h.style.bottom==="0px"&&(f.scrollTop=_>0?_:0,h.style.justifyContent="flex-end")}}}c.current=f.scrollTop})})})]})});Eu.displayName=Os;var _u="SelectGroup",[Cv,xv]=$n(_u),Ru=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Zt();return u.jsx(Cv,{scope:n,id:o,children:u.jsx(ie.div,{role:"group","aria-labelledby":o,...r,ref:t})})});Ru.displayName=_u;var Tu="SelectLabel",Sv=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=xv(Tu,n);return u.jsx(ie.div,{id:o.id,...r,ref:t})});Sv.displayName=Tu;var eo="SelectItem",[Ev,Pu]=$n(eo),Au=d.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:s,...i}=e,a=$t(eo,n),c=Ft(eo,n),l=a.value===r,[f,h]=d.useState(s??""),[m,g]=d.useState(!1),x=ce(t,w=>{var S;return(S=c.itemRefCallback)==null?void 0:S.call(c,w,r,o)}),p=Zt(),y=d.useRef("touch"),v=()=>{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 u.jsx(Ev,{scope:n,value:r,disabled:o,textId:p,isSelected:l,onItemTextChange:d.useCallback(w=>{h(S=>S||((w==null?void 0:w.textContent)??"").trim())},[]),children:u.jsx(wo.ItemSlot,{scope:n,value:r,disabled:o,textValue:f,children:u.jsx(ie.div,{role:"option","aria-labelledby":p,"data-highlighted":m?"":void 0,"aria-selected":l&&m,"data-state":l?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...i,ref:x,onFocus:X(i.onFocus,()=>g(!0)),onBlur:X(i.onBlur,()=>g(!1)),onClick:X(i.onClick,()=>{y.current!=="mouse"&&v()}),onPointerUp:X(i.onPointerUp,()=>{y.current==="mouse"&&v()}),onPointerDown:X(i.onPointerDown,w=>{y.current=w.pointerType}),onPointerMove:X(i.onPointerMove,w=>{var S;y.current=w.pointerType,o?(S=c.onItemLeave)==null||S.call(c):y.current==="mouse"&&w.currentTarget.focus({preventScroll:!0})}),onPointerLeave:X(i.onPointerLeave,w=>{var S;w.currentTarget===document.activeElement&&((S=c.onItemLeave)==null||S.call(c))}),onKeyDown:X(i.onKeyDown,w=>{var _;((_=c.searchRef)==null?void 0:_.current)!==""&&w.key===" "||(uv.includes(w.key)&&v(),w.key===" "&&w.preventDefault())})})})})});Au.displayName=eo;var qn="SelectItemText",Ou=d.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...s}=e,i=$t(qn,n),a=Ft(qn,n),c=Pu(qn,n),l=pv(qn,n),[f,h]=d.useState(null),m=ce(t,v=>h(v),c.onItemTextChange,v=>{var w;return(w=a.itemTextRefCallback)==null?void 0:w.call(a,v,c.value,c.disabled)}),g=f==null?void 0:f.textContent,x=d.useMemo(()=>u.jsx("option",{value:c.value,disabled:c.disabled,children:g},c.value),[c.disabled,c.value,g]),{onNativeOptionAdd:p,onNativeOptionRemove:y}=l;return ye(()=>(p(x),()=>y(x)),[p,y,x]),u.jsxs(u.Fragment,{children:[u.jsx(ie.span,{id:c.textId,...s,ref:m}),c.isSelected&&i.valueNode&&!i.valueNodeHasChildren?io.createPortal(s.children,i.valueNode):null]})});Ou.displayName=qn;var ju="SelectItemIndicator",Iu=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return Pu(ju,n).isSelected?u.jsx(ie.span,{"aria-hidden":!0,...r,ref:t}):null});Iu.displayName=ju;var js="SelectScrollUpButton",_v=d.forwardRef((e,t)=>{const n=Ft(js,e.__scopeSelect),r=fi(js,e.__scopeSelect),[o,s]=d.useState(!1),i=ce(t,r.onScrollButtonChange);return ye(()=>{if(n.viewport&&n.isPositioned){let a=function(){const l=c.scrollTop>0;s(l)};const c=n.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?u.jsx(Nu,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop-c.offsetHeight)}}):null});_v.displayName=js;var Is="SelectScrollDownButton",Rv=d.forwardRef((e,t)=>{const n=Ft(Is,e.__scopeSelect),r=fi(Is,e.__scopeSelect),[o,s]=d.useState(!1),i=ce(t,r.onScrollButtonChange);return ye(()=>{if(n.viewport&&n.isPositioned){let a=function(){const l=c.scrollHeight-c.clientHeight,f=Math.ceil(c.scrollTop)<l;s(f)};const c=n.viewport;return a(),c.addEventListener("scroll",a),()=>c.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),o?u.jsx(Nu,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop+c.offsetHeight)}}):null});Rv.displayName=Is;var Nu=d.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,s=Ft("SelectScrollButton",n),i=d.useRef(null),a=Co(n),c=d.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return d.useEffect(()=>()=>c(),[c]),ye(()=>{var f;const l=a().find(h=>h.ref.current===document.activeElement);(f=l==null?void 0:l.ref.current)==null||f.scrollIntoView({block:"nearest"})},[a]),u.jsx(ie.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:X(o.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(r,50))}),onPointerMove:X(o.onPointerMove,()=>{var l;(l=s.onItemLeave)==null||l.call(s),i.current===null&&(i.current=window.setInterval(r,50))}),onPointerLeave:X(o.onPointerLeave,()=>{c()})})}),Tv="SelectSeparator",Pv=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return u.jsx(ie.div,{"aria-hidden":!0,...r,ref:t})});Pv.displayName=Tv;var Ns="SelectArrow",Av=d.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=xo(n),s=$t(Ns,n),i=Ft(Ns,n);return s.open&&i.position==="popper"?u.jsx(ru,{...o,...r,ref:t}):null});Av.displayName=Ns;var Ov="SelectBubbleInput",Du=d.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const o=d.useRef(null),s=ce(r,o),i=xy(t);return d.useEffect(()=>{const a=o.current;if(!a)return;const c=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(c,"value").set;if(i!==t&&f){const h=new Event("change",{bubbles:!0});f.call(a,t),a.dispatchEvent(h)}},[i,t]),u.jsx(ie.select,{...n,style:{...ou,...n.style},ref:s,defaultValue:t})});Du.displayName=Ov;function Lu(e){return e===""||e===void 0}function Mu(e){const t=tn(e),n=d.useRef(""),r=d.useRef(0),o=d.useCallback(i=>{const a=n.current+i;t(a),function c(l){n.current=l,window.clearTimeout(r.current),l!==""&&(r.current=window.setTimeout(()=>c(""),1e3))}(a)},[t]),s=d.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return d.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,s]}function ku(e,t,n){const o=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let i=jv(e,Math.max(s,0));o.length===1&&(i=i.filter(l=>l!==n));const c=i.find(l=>l.textValue.toLowerCase().startsWith(o.toLowerCase()));return c!==n?c:void 0}function jv(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Iv=pu,Nv=gu,Dv=vu,Lv=bu,Mv=wu,kv=Eu,$v=Ru,Fv=Au,Bv=Ou,Uv=Iu;const Wv="Container__xcHXp",Hv="Label__0cZB9",Vv="HelperText__m1nA9",qv="Trigger__AyFUd",zv="TriggerIcon__aygFG",Gv="Content__llztG",Kv="Viewport__COtSL",Qv="Item__XN1-2",Yv="ItemIndicatorContainer__EQH-X",Zv="ItemIndicator__bySSc",ze={Container:Wv,Label:Hv,HelperText:Vv,Trigger:qv,TriggerIcon:zv,Content:Gv,Viewport:Kv,Item:Qv,ItemIndicatorContainer:Yv,ItemIndicator:Zv},$u=E.forwardRef(({label:e,helperText:t,value:n,onValueChange:r,options:o,placeholder:s="Select",disabled:i=!1,className:a,name:c},l)=>u.jsxs("div",{className:N(ze.Container,a),children:[e&&u.jsx("label",{className:ze.Label,children:e}),u.jsxs(Iv,{value:n,onValueChange:r,disabled:i,name:c,children:[u.jsxs(Nv,{ref:l,className:ze.Trigger,children:[u.jsx(Dv,{placeholder:s}),u.jsx(Lv,{className:ze.TriggerIcon,children:u.jsx(Xv,{})})]}),u.jsx(Mv,{className:ze.Content,position:"popper",sideOffset:4,children:u.jsx(kv,{className:ze.Viewport,children:u.jsx($v,{children:o.map(f=>u.jsxs(Fv,{value:f.value,disabled:f.disabled,className:ze.Item,children:[u.jsx("div",{className:ze.ItemIndicatorContainer,children:u.jsx(Uv,{className:ze.ItemIndicator,children:u.jsx(Jv,{})})}),u.jsx(Bv,{children:f.label})]},f.value))})})})]}),t&&u.jsx("div",{className:ze.HelperText,children:t})]}));$u.displayName="Select";const Xv=()=>u.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[u.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"}),u.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"})]}),Jv=()=>u.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"M13.3333 4L6 11.3333L2.66667 8",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),e0="TextArea__pa-A0",t0={TextArea:e0},Fu=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(t0.TextArea,t);return u.jsx("textarea",{ref:r,className:o,...n,children:e})});Fu.displayName="TextArea";function n0(e,t){return d.useReducer((n,r)=>t[n][r]??n,e)}var Fn=e=>{const{present:t,children:n}=e,r=r0(t),o=typeof n=="function"?n({present:r.isPresent}):d.Children.only(n),s=ce(r.ref,o0(o));return typeof n=="function"||r.isPresent?d.cloneElement(o,{ref:s}):null};Fn.displayName="Presence";function r0(e){const[t,n]=d.useState(),r=d.useRef(null),o=d.useRef(e),s=d.useRef("none"),i=e?"mounted":"unmounted",[a,c]=n0(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const l=Or(r.current);s.current=a==="mounted"?l:"none"},[a]),ye(()=>{const l=r.current,f=o.current;if(f!==e){const m=s.current,g=Or(l);e?c("MOUNT"):g==="none"||(l==null?void 0:l.display)==="none"?c("UNMOUNT"):c(f&&m!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),ye(()=>{if(t){let l;const f=t.ownerDocument.defaultView??window,h=g=>{const p=Or(r.current).includes(CSS.escape(g.animationName));if(g.target===t&&p&&(c("ANIMATION_END"),!o.current)){const y=t.style.animationFillMode;t.style.animationFillMode="forwards",l=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=y)})}},m=g=>{g.target===t&&(s.current=Or(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",h),t.addEventListener("animationend",h),()=>{f.clearTimeout(l),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",h),t.removeEventListener("animationend",h)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:d.useCallback(l=>{r.current=l?getComputedStyle(l):null,n(l)},[])}}function Or(e){return(e==null?void 0:e.animationName)||"none"}function o0(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 s0=Symbol("radix.slottable");function i0(e){const t=({children:n})=>u.jsx(u.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=s0,t}var[So]=ar("Tooltip",[vo]),Eo=vo(),Bu="TooltipProvider",a0=700,Ds="tooltip.open",[c0,hi]=So(Bu),Uu=e=>{const{__scopeTooltip:t,delayDuration:n=a0,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:s}=e,i=d.useRef(!0),a=d.useRef(!1),c=d.useRef(0);return d.useEffect(()=>{const l=c.current;return()=>window.clearTimeout(l)},[]),u.jsx(c0,{scope:t,isOpenDelayedRef:i,delayDuration:n,onOpen:d.useCallback(()=>{window.clearTimeout(c.current),i.current=!1},[]),onClose:d.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>i.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:d.useCallback(l=>{a.current=l},[]),disableHoverableContent:o,children:s})};Uu.displayName=Bu;var Zn="Tooltip",[l0,lr]=So(Zn),Wu=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o,onOpenChange:s,disableHoverableContent:i,delayDuration:a}=e,c=hi(Zn,e.__scopeTooltip),l=Eo(t),[f,h]=d.useState(null),m=Zt(),g=d.useRef(0),x=i??c.disableHoverableContent,p=a??c.delayDuration,y=d.useRef(!1),[v,w]=Jr({prop:r,defaultProp:o??!1,onChange:P=>{P?(c.onOpen(),document.dispatchEvent(new CustomEvent(Ds))):c.onClose(),s==null||s(P)},caller:Zn}),S=d.useMemo(()=>v?y.current?"delayed-open":"instant-open":"closed",[v]),_=d.useCallback(()=>{window.clearTimeout(g.current),g.current=0,y.current=!1,w(!0)},[w]),R=d.useCallback(()=>{window.clearTimeout(g.current),g.current=0,w(!1)},[w]),T=d.useCallback(()=>{window.clearTimeout(g.current),g.current=window.setTimeout(()=>{y.current=!0,w(!0),g.current=0},p)},[p,w]);return d.useEffect(()=>()=>{g.current&&(window.clearTimeout(g.current),g.current=0)},[]),u.jsx(eu,{...l,children:u.jsx(l0,{scope:t,contentId:m,open:v,stateAttribute:S,trigger:f,onTriggerChange:h,onTriggerEnter:d.useCallback(()=>{c.isOpenDelayedRef.current?T():_()},[c.isOpenDelayedRef,T,_]),onTriggerLeave:d.useCallback(()=>{x?R():(window.clearTimeout(g.current),g.current=0)},[R,x]),onOpen:_,onClose:R,disableHoverableContent:x,children:n})})};Wu.displayName=Zn;var Ls="TooltipTrigger",Hu=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=lr(Ls,n),s=hi(Ls,n),i=Eo(n),a=d.useRef(null),c=ce(t,a,o.onTriggerChange),l=d.useRef(!1),f=d.useRef(!1),h=d.useCallback(()=>l.current=!1,[]);return d.useEffect(()=>()=>document.removeEventListener("pointerup",h),[h]),u.jsx(tu,{asChild:!0,...i,children:u.jsx(ie.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:c,onPointerMove:X(e.onPointerMove,m=>{m.pointerType!=="touch"&&!f.current&&!s.isPointerInTransitRef.current&&(o.onTriggerEnter(),f.current=!0)}),onPointerLeave:X(e.onPointerLeave,()=>{o.onTriggerLeave(),f.current=!1}),onPointerDown:X(e.onPointerDown,()=>{o.open&&o.onClose(),l.current=!0,document.addEventListener("pointerup",h,{once:!0})}),onFocus:X(e.onFocus,()=>{l.current||o.onOpen()}),onBlur:X(e.onBlur,o.onClose),onClick:X(e.onClick,o.onClose)})})});Hu.displayName=Ls;var pi="TooltipPortal",[u0,d0]=So(pi,{forceMount:void 0}),Vu=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,s=lr(pi,t);return u.jsx(u0,{scope:t,forceMount:n,children:u.jsx(Fn,{present:n||s.open,children:u.jsx(ui,{asChild:!0,container:o,children:r})})})};Vu.displayName=pi;var On="TooltipContent",qu=d.forwardRef((e,t)=>{const n=d0(On,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...s}=e,i=lr(On,e.__scopeTooltip);return u.jsx(Fn,{present:r||i.open,children:i.disableHoverableContent?u.jsx(zu,{side:o,...s,ref:t}):u.jsx(f0,{side:o,...s,ref:t})})}),f0=d.forwardRef((e,t)=>{const n=lr(On,e.__scopeTooltip),r=hi(On,e.__scopeTooltip),o=d.useRef(null),s=ce(t,o),[i,a]=d.useState(null),{trigger:c,onClose:l}=n,f=o.current,{onPointerInTransitChange:h}=r,m=d.useCallback(()=>{a(null),h(!1)},[h]),g=d.useCallback((x,p)=>{const y=x.currentTarget,v={x:x.clientX,y:x.clientY},w=g0(v,y.getBoundingClientRect()),S=y0(v,w),_=v0(p.getBoundingClientRect()),R=w0([...S,..._]);a(R),h(!0)},[h]);return d.useEffect(()=>()=>m(),[m]),d.useEffect(()=>{if(c&&f){const x=y=>g(y,f),p=y=>g(y,c);return c.addEventListener("pointerleave",x),f.addEventListener("pointerleave",p),()=>{c.removeEventListener("pointerleave",x),f.removeEventListener("pointerleave",p)}}},[c,f,g,m]),d.useEffect(()=>{if(i){const x=p=>{const y=p.target,v={x:p.clientX,y:p.clientY},w=(c==null?void 0:c.contains(y))||(f==null?void 0:f.contains(y)),S=!b0(v,i);w?m():S&&(m(),l())};return document.addEventListener("pointermove",x),()=>document.removeEventListener("pointermove",x)}},[c,f,i,l,m]),u.jsx(zu,{...e,ref:s})}),[h0,p0]=So(Zn,{isInside:!1}),m0=i0("TooltipContent"),zu=d.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:s,onPointerDownOutside:i,...a}=e,c=lr(On,n),l=Eo(n),{onClose:f}=c;return d.useEffect(()=>(document.addEventListener(Ds,f),()=>document.removeEventListener(Ds,f)),[f]),d.useEffect(()=>{if(c.trigger){const h=m=>{const g=m.target;g!=null&&g.contains(c.trigger)&&f()};return window.addEventListener("scroll",h,{capture:!0}),()=>window.removeEventListener("scroll",h,{capture:!0})}},[c.trigger,f]),u.jsx(ho,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:h=>h.preventDefault(),onDismiss:f,children:u.jsxs(nu,{"data-state":c.stateAttribute,...l,...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:[u.jsx(m0,{children:r}),u.jsx(h0,{scope:n,isInside:!0,children:u.jsx(Ey,{id:c.contentId,role:"tooltip",children:o||r})})]})})});qu.displayName=On;var Gu="TooltipArrow",Ku=d.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=Eo(n);return p0(Gu,n).isInside?null:u.jsx(ru,{...o,...r,ref:t})});Ku.displayName=Gu;function g0(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 y0(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 v0(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 b0(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],c=t[i],l=a.x,f=a.y,h=c.x,m=c.y;f>r!=m>r&&n<(h-l)*(r-f)/(m-f)+l&&(o=!o)}return o}function w0(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),C0(t)}function C0(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 x0=Uu,S0=Wu,E0=Hu,_0=Vu,R0=qu,T0=Ku;const P0="tooltip__nUuSh",A0="tooltipArrow__W2w-f",Ya={tooltip:P0,tooltipArrow:A0},Qu=E.createContext(null),O0=({container:e,children:t})=>u.jsx(Qu.Provider,{value:e,children:t}),mi=()=>E.useContext(Qu)??void 0,jn=({children:e,open:t,displayName:n,tooltipContent:r,className:o,disabled:s,delayDuration:i=300,side:a="right",sideOffset:c=0})=>{const[l,f]=E.useState(!1),h=mi(),m=t!==void 0,x=s?!1:m?t:l,p=y=>{s||m||f(y)};return u.jsx(x0,{delayDuration:i,children:u.jsxs(S0,{open:x,onOpenChange:p,children:[u.jsx(E0,{asChild:!0,children:e}),u.jsx(_0,{container:h,children:u.jsxs(R0,{className:N(Ya.tooltip,o),side:a,sideOffset:c,children:[n,r,u.jsx(T0,{className:Ya.tooltipArrow})]})})]})})};jn.displayName="Tooltip";const j0="truncatedText__Y-jSd",I0="overflowing__o8TC-",Za={truncatedText:j0,overflowing:I0},Yu=({children:e,className:t,tooltipSide:n="top",tooltipClassName:r})=>{const o=E.useRef(null),[s,i]=E.useState(!1);E.useEffect(()=>{const c=()=>{if(o.current){const l=o.current.scrollWidth>o.current.clientWidth;i(l)}};return c(),window.addEventListener("resize",c),()=>{window.removeEventListener("resize",c)}},[e]);const a=u.jsx("span",{ref:o,className:N(Za.truncatedText,s?Za.overflowing:"",t||""),children:e});return s?u.jsx(jn,{tooltipContent:e,side:n,className:r,children:a}):a};Yu.displayName="TextWithTooltip";const N0="SearchInput__4OFyE",D0="SearchIcon__YgnQy",L0="ClearIcon__ukRVr",M0="SearchInput__ClearIcon__uzVoc",k0="SearchInput__SearchIcon__zoDG4",Wn={SearchInput:N0,SearchIcon:D0,ClearIcon:L0,SearchInput__ClearIcon:M0,SearchInput__SearchIcon:k0},gi=E.forwardRef(({className:e,placeholder:t="Type to search...",showClearButton:n=!1,showSearchIcon:r=!0,onClear:o,...s},i)=>{const a=N(Wn.SearchInput,n&&Wn.SearchInput__ClearIcon,r&&Wn.SearchInput__SearchIcon,e),c=N(Wn.SearchIcon),l=N(Wn.ClearIcon);return u.jsxs("div",{className:a,children:[u.jsx(fo,{ref:i,type:"text",placeholder:t,...s}),r&&u.jsx("svg",{className:c,width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.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&&u.jsx("svg",{className:l,width:"8",height:"8",viewBox:"0 0 8 8",fill:"none",xmlns:"http://www.w3.org/2000/svg",onClick:o,children:u.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"})})]})});gi.displayName="SearchInput";const $0="SearchAutocomplete__vR9Hk",F0="AutocompleteItem__YIm7R",B0="AutocompleteHighlighter__LAFTV",U0="AutocompleteHighlighter__match__Wy1o2",W0="DropdownList__-fHIk",H0="AutocompleteItemDescription__4QYN5",Xt={SearchAutocomplete:$0,AutocompleteItem:F0,"AutocompleteItem--canBeSelected":"AutocompleteItem--canBeSelected__jxk4z",AutocompleteHighlighter:B0,AutocompleteHighlighter__match:U0,DropdownList:W0,AutocompleteItemDescription:H0},V0="DropdownList__QTXXX",q0="DropdownList__QTXXX",z0="DropdownList--closed__pdL1Z",G0="DropdownList--open__opzc9",K0="DropdownList--left__xSwXR",Wt={DropdownList:V0,dropdownList:q0,"DropdownList--closed":"DropdownList--closed__pdL1Z",dropdownListClosed:z0,"DropdownList--open":"DropdownList--open__opzc9",dropdownListOpen:G0,"DropdownList--left":"DropdownList--left__xSwXR",dropdownListLeft:K0},_o=E.forwardRef(({children:e,className:t,open:n,align:r="right",...o},s)=>{const i=N(Wt.DropdownList,{[Wt["DropdownList--open"]]:n,[Wt["DropdownList--closed"]]:!n,[Wt["DropdownList--left"]]:r==="left"},t);return u.jsx("div",{ref:s,className:i,...o,children:e})});_o.displayName="DropdownList";const zn=E.forwardRef(({children:e,className:t,canBeSelected:n=!1,...r},o)=>{const s=N(Xt.AutocompleteItem,{[Xt["AutocompleteItem--canBeSelected"]]:n},t);return u.jsx("div",{ref:o,className:s,role:n?"option":void 0,...r,children:e})});zn.displayName="AutocompleteItem";const Q0=300,Y0={query:"",suggestions:[],loading:!1,error:null},Z0=({suggestionFetcher:e,canAdd:t})=>{const[n,r]=E.useState(Y0);return E.useEffect(()=>{r(a=>({...a,loading:!0}));const s=async()=>{try{const a=await e(n.query);t&&!a.some(c=>c.value.toLowerCase()===n.query.toLowerCase())&&a.push({label:`Add "${n.query}"`,value:n.query,isNew:!0}),r(c=>({...c,suggestions:a,loading:!1}))}catch(a){r(c=>({...c,suggestions:[],error:a,loading:!1}))}},i=setTimeout(()=>{s()},Q0);return()=>{clearTimeout(i)}},[n.query]),{...n,setQuery:s=>{r(i=>({...i,query:s}))}}},Zu=E.forwardRef(({text:e,query:t,className:n,...r},o)=>{const s=N(Xt.AutocompleteHighlighter,n),i=(a,c)=>{const l=a.toLowerCase().indexOf(c.toLowerCase());if(l===-1||c.length===0)return a;const f=a.slice(0,l),h=a.slice(l,l+c.length),m=a.slice(l+c.length);return u.jsxs(u.Fragment,{children:[f,u.jsx("span",{className:Xt.AutocompleteHighlighter__match,children:h}),i(m,c)]})};return u.jsx("div",{ref:o,className:s,...r,children:i(e,t)})});Zu.displayName="AutocompleteHighlighter";const X0=5,Xu=E.forwardRef(({children:e,className:t,canAdd:n,maxSuggestionsShown:r=X0,searchInputProps:o,keepSelectedOption:s,suggestionFetcher:i,onAccept:a,...c},l)=>{const{query:f,setQuery:h,suggestions:m,loading:g}=Z0({suggestionFetcher:i,canAdd:n}),[x,p]=E.useState(null),y=f.length>0,v=P=>{h(P.target.value)},w=P=>{a==null||a(P),s?(p(P),h(P.value)):h("")},S=()=>{a==null||a(null),p(null),h("")},_=N(Xt.SearchAutocomplete,t),R=m.slice(0,r),T=m.slice(r);return u.jsxs("div",{ref:l,className:_,...c,children:[u.jsx(gi,{...o,value:f,onChange:v,showClearButton:!!x,onClear:S}),e,u.jsxs(_o,{className:Xt.DropdownList,open:y&&!x,role:"listbox","aria-label":"Suggestions",children:[g?u.jsx(zn,{children:"Loading..."}):R.map(P=>u.jsxs(zn,{canBeSelected:!0,onClick:w.bind(null,P),children:[u.jsx(Zu,{text:P.label,query:f}),P.description&&u.jsx("span",{className:Xt.AutocompleteItemDescription,children:P.description})]},P.value)),!g&&T.length>0&&u.jsxs(zn,{children:[T.length," more results"]}),y&&m.length===0&&!g&&u.jsx(zn,{children:"No results found"})]})]})});Xu.displayName="SearchAutocomplete";const It=e=>{let t=null,n=null;return E.Children.forEach(e.children,r=>{const o=r.props.condition;o===void 0?n=r:!t&&o===!0&&(t=r)}),u.jsx(u.Fragment,{children:t||n})};It.displayName="Show";It.When=({condition:e,children:t})=>u.jsx(u.Fragment,{children:e&&t});It.Else=({render:e,children:t})=>u.jsx(u.Fragment,{children:e||t});var J0=Symbol.for("react.lazy"),to=d[" use ".trim().toString()];function e2(e){return typeof e=="object"&&e!==null&&"then"in e}function Ju(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===J0&&"_payload"in e&&e2(e._payload)}function t2(e){const t=r2(e),n=d.forwardRef((r,o)=>{let{children:s,...i}=r;Ju(s)&&typeof to=="function"&&(s=to(s._payload));const a=d.Children.toArray(s),c=a.find(s2);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}var n2=t2("Slot");function r2(e){const t=d.forwardRef((n,r)=>{let{children:o,...s}=n;if(Ju(o)&&typeof to=="function"&&(o=to(o._payload)),d.isValidElement(o)){const i=a2(o),a=i2(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 o2=Symbol("radix.slottable");function s2(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===o2}function i2(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function a2(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 c2="SkeletonListContainer__MKJhE",l2="Skeleton__Ovpiw",ed={SkeletonListContainer:c2,Skeleton:l2},Ro=E.forwardRef((e,t)=>{const{children:n,className:r,loading:o,height:s=48,width:i,borderRadius:a,style:c,...l}=e;if(!o&&n)return n;const f=E.isValidElement(n)?n2:"span";return u.jsx(f,{ref:t,"aria-hidden":!0,className:N(ed.Skeleton,r),style:{...c,width:i,minWidth:i,height:s,borderRadius:a},"data-inline-skeleton":E.isValidElement(n)?void 0:!0,tabIndex:-1,...l,children:n})});Ro.displayName="Skeleton";const td=e=>{const{numberOfItems:t,itemsGap:n=2,itemProps:r}=e,o=Array.from({length:t},(s,i)=>i+1);return u.jsx("div",{className:N(ed.SkeletonListContainer),style:{gap:n},children:o.map(s=>u.jsx(Ro,{loading:!0,...r},s))})};td.displayName="SkeletonList";const u2="spinner__qa7F6",d2="rotate__EqlXe",f2="spinner-dark__9A9-q",h2="spinner-white__gRbtI",p2="spinner-success__otWGm",m2="spinner-danger__Bq5DM",g2="spinner-warning__U900K",Xa={spinner:u2,rotate:d2,"spinner-dark":"spinner-dark__9A9-q",spinnerDark:f2,"spinner-white":"spinner-white__gRbtI",spinnerWhite:h2,"spinner-success":"spinner-success__otWGm",spinnerSuccess:p2,"spinner-danger":"spinner-danger__Bq5DM",spinnerDanger:m2,"spinner-warning":"spinner-warning__U900K",spinnerWarning:g2},nd=({className:e,color:t="white",size:n=80,thickness:r})=>{const o=N(Xa.spinner,Xa[`spinner-${t}`],e),s=r??Math.max(n/12,2);return u.jsx("span",{style:{width:n,height:n,borderWidth:s},className:o})};nd.displayName="Spinner";const y2="disabled__KpauE",v2="checked__2-JV-",b2="thumb__fEuKD",jr={switch:"switch__0b2av",disabled:y2,checked:v2,thumb:b2},rd=E.forwardRef(({checked:e,defaultChecked:t=!1,onCheckedChange:n,disabled:r=!1,id:o,className:s,name:i,"aria-label":a,"aria-labelledby":c,"aria-describedby":l,...f},h)=>{const[m,g]=E.useState(t),x=e!==void 0,p=x?!!e:m,y=()=>{if(r)return;const w=!p;x||g(w),n==null||n(w)},v=w=>{(w.key===" "||w.key==="Enter")&&(w.preventDefault(),y())};return u.jsx("button",{ref:h,type:"button",role:"switch","aria-checked":p,"aria-label":a,"aria-labelledby":c,"aria-describedby":l,disabled:r,id:o,name:i,className:N(jr.switch,{[jr.checked]:p,[jr.disabled]:r}),onClick:y,onKeyDown:v,...f,children:u.jsx("span",{className:jr.thumb,"aria-hidden":"true"})})});rd.displayName="Switch";const w2="tabs-root__ELmdj",C2="tabs-list__rc10N",x2="tabs-list--horizontal__e1YW4",S2="tabs-list--vertical__huK05",E2="tabs-trigger__D8R4R",_2="tabs-trigger--disabled__ezDWc",R2="tabs-trigger--horizontal__4jBFV",T2="tabs-trigger--active__S-Z-S",P2="tabs-trigger--vertical__dNVIZ",A2="tabs-content__1d77o",Ze={tabsRoot:w2,tabsList:C2,tabsListHorizontal:x2,tabsListVertical:S2,tabsTrigger:E2,tabsTriggerDisabled:_2,tabsTriggerHorizontal:R2,tabsTriggerActive:T2,tabsTriggerVertical:P2,tabsContent:A2},od=E.createContext(null),yi=()=>{const e=E.useContext(od);if(!e)throw new Error("Tabs components must be used within a Tabs provider");return e},O2=({defaultValue:e,value:t,onValueChange:n,orientation:r="horizontal",className:o="",children:s})=>{const[i,a]=E.useState(e||""),c=t!==void 0,l=c?t:i,f=h=>{c||a(h),n==null||n(h)};return u.jsx(od.Provider,{value:{value:l,onValueChange:f,orientation:r},children:u.jsx("div",{className:N(Ze.tabsRoot,o),children:s})})},j2=({className:e="",children:t})=>{const{orientation:n}=yi(),r=E.useRef(null),o=s=>{var l;const i=(l=r.current)==null?void 0:l.querySelectorAll('[role="tab"]:not([disabled])');if(!i)return;const a=Array.from(i).findIndex(f=>f===document.activeElement);let c=a;switch(s.key){case"ArrowLeft":n==="horizontal"&&(s.preventDefault(),c=a>0?a-1:i.length-1);break;case"ArrowRight":n==="horizontal"&&(s.preventDefault(),c=a<i.length-1?a+1:0);break;case"ArrowUp":n==="vertical"&&(s.preventDefault(),c=a>0?a-1:i.length-1);break;case"ArrowDown":n==="vertical"&&(s.preventDefault(),c=a<i.length-1?a+1:0);break;case"Home":s.preventDefault(),c=0;break;case"End":s.preventDefault(),c=i.length-1;break}if(c!==a){const f=i[c];f.focus(),f.click()}};return u.jsx("div",{ref:r,role:"tablist","aria-orientation":n,onKeyDown:o,className:N(Ze.tabsList,n==="horizontal"?Ze.tabsListHorizontal:Ze.tabsListVertical,e),children:t})},I2=({value:e,disabled:t=!1,className:n="",children:r})=>{const{value:o,onValueChange:s,orientation:i}=yi(),a=o===e,c=()=>{t||s(e)};return u.jsx("button",{role:"tab","aria-selected":a,"aria-controls":`content-${e}`,tabIndex:a?0:-1,disabled:t,onClick:c,className:N(Ze.tabsTrigger,i==="horizontal"?Ze.tabsTriggerHorizontal:Ze.tabsTriggerVertical,a&&Ze.tabsTriggerActive,t&&Ze.tabsTriggerDisabled,n),children:r})},N2=({value:e,className:t="",children:n})=>{const{value:r}=yi();return r===e?u.jsx("div",{role:"tabpanel",id:`content-${e}`,"aria-labelledby":`trigger-${e}`,tabIndex:0,className:N(Ze.tabsContent,t),children:n}):null},sd=({className:e,state:t="open",onClick:n})=>t==="open"?u.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:[u.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"}),u.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"})]}):u.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:u.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"})}),D2="PasswordInput__GDJDN",L2="eyeIcon__kDExG",Ja={PasswordInput:D2,eyeIcon:L2},M2=E.forwardRef((e,t)=>{const[n,r]=E.useState("password"),o=E.useCallback(()=>{r(s=>s==="password"?"text":"password")},[r]);return u.jsxs("div",{className:N(Ja.PasswordInput,e.className),children:[u.jsx(fo,{type:n,...e,ref:t}),u.jsx(sd,{className:Ja.eyeIcon,onClick:o,state:n==="password"?"open":"closed"})]})});function k2(e){const t=$2(e),n=d.forwardRef((r,o)=>{const{children:s,...i}=r,a=d.Children.toArray(s),c=a.find(B2);if(c){const l=c.props.children,f=a.map(h=>h===c?d.Children.count(l)>1?d.Children.only(null):d.isValidElement(l)?l.props.children:null:h);return u.jsx(t,{...i,ref:o,children:d.isValidElement(l)?d.cloneElement(l,void 0,f):null})}return u.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function $2(e){const t=d.forwardRef((n,r)=>{const{children:o,...s}=n;if(d.isValidElement(o)){const i=W2(o),a=U2(s,o.props);return o.type!==d.Fragment&&(a.ref=r?Ln(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 F2=Symbol("radix.slottable");function B2(e){return d.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===F2}function U2(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 c=s(...a);return o(...a),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function W2(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 To="Dialog",[id]=ar(To),[H2,He]=id(To),ad=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:s,modal:i=!0}=e,a=d.useRef(null),c=d.useRef(null),[l,f]=Jr({prop:r,defaultProp:o??!1,onChange:s,caller:To});return u.jsx(H2,{scope:t,triggerRef:a,contentRef:c,contentId:Zt(),titleId:Zt(),descriptionId:Zt(),open:l,onOpenChange:f,onOpenToggle:d.useCallback(()=>f(h=>!h),[f]),modal:i,children:n})};ad.displayName=To;var cd="DialogTrigger",V2=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(cd,n),s=ce(t,o.triggerRef);return u.jsx(ie.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":wi(o.open),...r,ref:s,onClick:X(e.onClick,o.onOpenToggle)})});V2.displayName=cd;var vi="DialogPortal",[q2,ld]=id(vi,{forceMount:void 0}),ud=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,s=He(vi,t);return u.jsx(q2,{scope:t,forceMount:n,children:d.Children.map(r,i=>u.jsx(Fn,{present:n||s.open,children:u.jsx(ui,{asChild:!0,container:o,children:i})}))})};ud.displayName=vi;var no="DialogOverlay",dd=d.forwardRef((e,t)=>{const n=ld(no,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=He(no,e.__scopeDialog);return s.modal?u.jsx(Fn,{present:r||s.open,children:u.jsx(G2,{...o,ref:t})}):null});dd.displayName=no;var z2=k2("DialogOverlay.RemoveScroll"),G2=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(no,n);return u.jsx(di,{as:z2,allowPinchZoom:!0,shards:[o.contentRef],children:u.jsx(ie.div,{"data-state":wi(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),sn="DialogContent",fd=d.forwardRef((e,t)=>{const n=ld(sn,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=He(sn,e.__scopeDialog);return u.jsx(Fn,{present:r||s.open,children:s.modal?u.jsx(K2,{...o,ref:t}):u.jsx(Q2,{...o,ref:t})})});fd.displayName=sn;var K2=d.forwardRef((e,t)=>{const n=He(sn,e.__scopeDialog),r=d.useRef(null),o=ce(t,n.contentRef,r);return d.useEffect(()=>{const s=r.current;if(s)return au(s)},[]),u.jsx(hd,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:X(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:X(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&s.preventDefault()}),onFocusOutside:X(e.onFocusOutside,s=>s.preventDefault())})}),Q2=d.forwardRef((e,t)=>{const n=He(sn,e.__scopeDialog),r=d.useRef(!1),o=d.useRef(!1);return u.jsx(hd,{...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 c,l;(c=e.onInteractOutside)==null||c.call(e,s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=s.target;((l=n.triggerRef.current)==null?void 0:l.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),hd=d.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:s,...i}=e,a=He(sn,n),c=d.useRef(null),l=ce(t,c);return jl(),u.jsxs(u.Fragment,{children:[u.jsx(ti,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:s,children:u.jsx(ho,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":wi(a.open),...i,ref:l,onDismiss:()=>a.onOpenChange(!1)})}),u.jsxs(u.Fragment,{children:[u.jsx(Y2,{titleId:a.titleId}),u.jsx(X2,{contentRef:c,descriptionId:a.descriptionId})]})]})}),bi="DialogTitle",pd=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(bi,n);return u.jsx(ie.h2,{id:o.titleId,...r,ref:t})});pd.displayName=bi;var md="DialogDescription",gd=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(md,n);return u.jsx(ie.p,{id:o.descriptionId,...r,ref:t})});gd.displayName=md;var yd="DialogClose",vd=d.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=He(yd,n);return u.jsx(ie.button,{type:"button",...r,ref:t,onClick:X(e.onClick,()=>o.onOpenChange(!1))})});vd.displayName=yd;function wi(e){return e?"open":"closed"}var bd="DialogTitleWarning",[tw,wd]=dm(bd,{contentName:sn,titleName:bi,docsSlug:"dialog"}),Y2=({titleId:e})=>{const t=wd(bd),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
252
252
|
|
|
253
253
|
If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
254
254
|
|
|
255
|
-
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},Y2="DialogDescriptionWarning",Z2=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${bd(Y2).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},X2=id,J2=ld,e3=ud,t3=dd,n3=hd,r3=md,o3=vd;const s3="Overlay__M5Z83",i3="Content__wAkP4",Ja={Overlay:s3,Content:i3},a3="Header__VHxNf",c3="Content__I04qM",l3="Close__xSN-7",u3="Title__Dznh6",d3="Description__ALT2w",f3="Footer__-8gzQ",h3="Actions__kKF2Q",cn={Header:a3,Content:c3,Close:l3,Title:u3,Description:d3,Footer:f3,Actions:h3},wd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Header,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});wd.displayName="Header";const Cd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Content,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Cd.displayName="Content";const xd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Footer,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});xd.displayName="Footer";const Sd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Title,t);return u.jsx(n3,{ref:r,className:o,...n,children:e})});Sd.displayName="Title";const Ed=E.forwardRef(({className:e,...t},n)=>{const r=N(cn.Close,e);return u.jsx(o3,{ref:n,asChild:!0,className:r,...t,children:u.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"M11 1L1 11M1 1L11 11",stroke:"#A9A9A9",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})});Ed.displayName="Close";const _d=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Actions,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});_d.displayName="Actions";const Rd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Description,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Rd.displayName="Description";const ge=({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})`},c=pi();return u.jsx(X2,{onOpenChange:s,open:n,children:u.jsxs(J2,{container:c,children:[u.jsx(e3,{className:Ja.Overlay,style:i}),u.jsxs(t3,{children:[u.jsx(r3,{}),u.jsx("div",{className:N(Ja.Content,r),style:a,children:e})]})]})})};ge.displayName="Dialog";ge.Header=wd;ge.Content=Cd;ge.Footer=xd;ge.Actions=_d;ge.Title=Sd;ge.Description=Rd;ge.Close=Ed;const p3="pill__vtGwB",m3="pill--solid__F-mR4",g3="pill--outline__gC-mh",ec={pill:p3,"pill--solid":"pill--solid__F-mR4",pillSolid:m3,"pill--outline":"pill--outline__gC-mh",pillOutline:g3},v3=({children:e,variant:t="solid",className:n})=>{const r=N(ec.pill,ec[`pill--${t}`],n);return u.jsx("div",{className:r,children:e})},y3="DialogContent__-WjG9",b3="Message__AUgVP",tc={DialogContent:y3,Message:b3},Td=({loading:e,title:t,children:n,className:r,onClose:o,onConfirm:s,zIndexLevel:i=1,...a})=>u.jsxs(ge,{...a,zIndexLevel:i,className:N(tc.DialogContent,r),children:[u.jsxs(ge.Header,{children:[u.jsx(ge.Title,{children:t}),u.jsx(ge.Close,{onClick:o})]}),u.jsx(ge.Content,{children:typeof n=="string"?u.jsx("p",{className:tc.Message,children:n}):n}),u.jsx(ge.Footer,{children:u.jsxs(ge.Actions,{children:[u.jsx(Kr,{onClick:o,disabled:e,variant:"outlined",children:"Cancel"}),u.jsx(Kr,{onClick:s,disabled:e,loading:e,variant:"contained",children:"Confirm"})]})})]});Td.displayName="ConfirmDialog";const w3="container__AjtYJ",C3="title__A2vCu",x3="description__bP6Ig",S3="mailToText__SdlsE",Ir={container:w3,title:C3,description:x3,mailToText:S3},Pd=()=>u.jsxs("svg",{width:"200",height:"200",viewBox:"0 0 200 200",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"})]});Pd.displayName="WarningIcon";const E3="support@bluealba.com",_3="@bluealba/pae-shell-ui",wi=()=>{const{supportEmail:e=E3}=Tc(_3),t=`mailto:${e}?Subject=Support`;return u.jsxs("div",{className:Ir.container,children:[u.jsx(Pd,{}),u.jsx("div",{className:Ir.title,children:"Oops! Something went wrong"}),u.jsxs("div",{className:Ir.description,children:["If the error persists, ",u.jsx("a",{className:Ir.mailToText,href:t,children:"contact the administrator."})]})]})};wi.displayName="ErrorState";const R3="List__h09XG",T3="List__h09XG",P3="Item__YMy2i",A3="Item__YMy2i",O3="List--primary__J2pbx",j3="List--secondary__gi1ao",I3="Item--selected__yRWow",N3="Title__RJmEW",D3="Title__RJmEW",L3="Description__DGyX2",M3="Description__DGyX2",k3="Actions__UHP5l",$3="Actions__UHP5l",F3="Action__q-R1I",B3="Action__q-R1I",U3="Item--disabled__Ke1u-",W3="List--small__ijoSR",H3="List--medium__E1FEY",V3="List--large__T8tfz",z3="Icon__dFr-L",q3="Icon__dFr-L",Be={List:R3,list:T3,Item:P3,item:A3,"List--primary":"List--primary__J2pbx",listPrimary:O3,"List--secondary":"List--secondary__gi1ao",listSecondary:j3,"Item--selected":"Item--selected__yRWow",itemSelected:I3,Title:N3,title:D3,Description:L3,description:M3,Actions:k3,actions:$3,Action:F3,action:B3,"Item--disabled":"Item--disabled__Ke1u-",itemDisabled:U3,"List--small":"List--small__ijoSR",listSmall:W3,"List--medium":"List--medium__E1FEY",listMedium:H3,"List--large":"List--large__T8tfz",listLarge:V3,Icon:z3,icon:q3},Ad=E.forwardRef(({children:e,className:t,selected:n,disabled:r=!1,...o},s)=>{const i=N(Be.Item,{[Be["Item--selected"]]:n,[Be["Item--disabled"]]:r},t);return u.jsx("li",{ref:s,className:i,role:"listitem","aria-disabled":r,...o,children:e})});Ad.displayName="Item";const Od=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Be.Title,t);return u.jsx("h3",{ref:r,className:o,...n,children:e})});Od.displayName="Title";const jd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Be.Description,t);return u.jsx("p",{ref:r,className:o,...n,children:e})});jd.displayName="Description";const Ci=({className:e,...t})=>u.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:e,...t,children:[u.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"}),u.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"}),u.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"})]});Ci.displayName="HorizontalDots";const Id=E.forwardRef(({children:e,className:t,onClick:n,...r},o)=>{const s=E.useRef(null),[i,a]=E.useState(!1),c=N(Be.Actions,t),l=()=>{const x=Wt["DropdownList--open"],p=Wt["DropdownList--closed"];document.querySelectorAll(`.${x}`).forEach(y=>{y!==s.current&&(y.classList.remove(x),y.classList.add(p))})},f=x=>{x.stopPropagation(),i?h():(a(!0),n==null||n(x))},h=()=>{a(!1)},m=x=>{x.key==="Escape"&&h()},g=x=>{s.current&&!s.current.contains(x.target)&&h()};return E.useEffect(()=>(i?(l(),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]),u.jsxs("div",{ref:o,className:c,onClick:f,role:"button",tabIndex:0,"data-testid":"actions",...r,children:[u.jsx(Ci,{}),u.jsx(Eo,{align:"left",ref:s,open:i,"data-testid":"actions-dropdown",role:"menu","aria-label":"Actions",children:e})]})});Id.displayName="Actions";const Nd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Be.Action,t);return u.jsx("button",{ref:r,className:o,...n,children:e})});Nd.displayName="Action";const Dd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Be.Icon,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Dd.displayName="Icon";const nt=E.forwardRef(({children:e,className:t,size:n="medium",variant:r,...o},s)=>{const i=N(Be.List,{[Be[`List--${n}`]]:n,[Be[`List--${r}`]]:r},t);return u.jsx("ul",{ref:s,className:i,role:"list",...o,children:e})});nt.displayName="List";nt.Item=Ad;nt.Badges=Xs;nt.Badge=Zs;nt.Title=Od;nt.Description=jd;nt.Actions=Id;nt.Action=Nd;nt.Icon=Dd;const G3="Navigation__uylxk",K3="PaginationContent__UpLw0",Q3="PaginationEllipsis__perWk",Y3="PaginationLink__GVUZj",Z3="Active__u1Ahy",X3="Disabled__8WM0y",J3="Prev__wp4hc",eb="Next__eVyL5",ht={Navigation:G3,PaginationContent:K3,PaginationEllipsis:Q3,PaginationLink:Y3,Active:Z3,Disabled:X3,Prev:J3,Next:eb},Ld=({className:e,...t})=>u.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:[u.jsx("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),u.jsx("path",{d:"M9 6l6 6l-6 6"})]});Ld.displayName="ChevronRight";const Md=({className:e,...t})=>u.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:[u.jsx("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),u.jsx("path",{d:"M15 6l-6 6l6 6"})]});Md.displayName="ChevronLeft";const xi=({className:e,...t})=>u.jsx("nav",{role:"navigation","aria-label":"pagination",className:N(ht.Navigation,e),...t});xi.displayName="Pagination";const Si=d.forwardRef(({className:e,...t},n)=>u.jsx("ul",{ref:n,className:N(ht.PaginationContent,e),...t}));Si.displayName="PaginationContent";const Gn=d.forwardRef(({className:e,...t},n)=>u.jsx("li",{ref:n,className:e,...t}));Gn.displayName="PaginationItem";const ur=({className:e,isActive:t,...n})=>u.jsx("a",{"aria-current":t?"page":void 0,className:N(ht.PaginationLink,t&&ht.Active,e),...n});ur.displayName="PaginationLink";const Ei=({className:e,disabled:t,...n})=>u.jsxs(ur,{"aria-label":"Go to previous page",className:N(t&&ht.Disabled,ht.Prev,e),...n,children:[u.jsx(Md,{}),u.jsx("span",{children:"Previous"})]});Ei.displayName="PaginationPrevious";const _i=({className:e,disabled:t,...n})=>u.jsxs(ur,{"aria-label":"Go to next page",className:N(t&&ht.Disabled,ht.Next,e),...n,children:[u.jsx("span",{children:"Next"}),u.jsx(Ld,{})]});_i.displayName="PaginationNext";const Ri=({className:e,...t})=>u.jsx("span",{"aria-hidden":!0,className:N(ht.PaginationEllipsis,e),...t,children:u.jsx(Ci,{})});Ri.displayName="PaginationEllipsis";function tb(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 kd={exports:{}};(function(e,t){(function(n,r){typeof tb=="function"?e.exports=r():n.pluralize=r()})(Af,function(){var n=[],r=[],o={},s={},i={};function a(p){return typeof p=="string"?new RegExp("^"+p+"$","i"):p}function c(p,v){return p===v?v:p===p.toLowerCase()?v.toLowerCase():p===p.toUpperCase()?v.toUpperCase():p[0]===p[0].toUpperCase()?v.charAt(0).toUpperCase()+v.substr(1).toLowerCase():v.toLowerCase()}function l(p,v){return p.replace(/\$(\d{1,2})/g,function(y,w){return v[w]||""})}function f(p,v){return p.replace(v[0],function(y,w){var S=l(v[1],arguments);return c(y===""?p[w-1]:y,S)})}function h(p,v,y){if(!p.length||o.hasOwnProperty(p))return v;for(var w=y.length;w--;){var S=y[w];if(S[0].test(v))return f(v,S)}return v}function m(p,v,y){return function(w){var S=w.toLowerCase();return v.hasOwnProperty(S)?c(w,S):p.hasOwnProperty(S)?c(w,p[S]):h(S,w,y)}}function g(p,v,y,w){return function(S){var _=S.toLowerCase();return v.hasOwnProperty(_)?!0:p.hasOwnProperty(_)?!1:h(_,_,y)===_}}function x(p,v,y){var w=v===1?x.singular(p):x.plural(p);return(y?v+" ":"")+w}return x.plural=m(i,s,n),x.isPlural=g(i,s,n),x.singular=m(s,i,r),x.isSingular=g(s,i,r),x.addPluralRule=function(p,v){n.push([a(p),v])},x.addSingularRule=function(p,v){r.push([a(p),v])},x.addUncountableRule=function(p){if(typeof p=="string"){o[p.toLowerCase()]=!0;return}x.addPluralRule(p,"$0"),x.addSingularRule(p,"$0")},x.addIrregularRule=function(p,v){v=v.toLowerCase(),p=p.toLowerCase(),i[p]=v,s[v]=p},[["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(p){return x.addIrregularRule(p[0],p[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(p){return x.addPluralRule(p[0],p[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(p){return x.addSingularRule(p[0],p[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(x.addUncountableRule),x})})(kd);var nb=kd.exports;const rb=Of(nb),Ti=({count:e,singularText:t,children:n=(r,o)=>`${r} ${o}`})=>u.jsx(u.Fragment,{children:n(e,rb(t,e))});Ti.displayName="PluralizeCounter";const ob="TableContainer__osh6Z",sb="TableHeader__sYa-8",ib="Table__2cIs3",ab="selectable__WsGg1",cb="Cell__ZEv-K",lb="Right__YoM1V",ub="Center__CF3tr",db="Sortable__JIV1V",fb="SortIcon__f0bBy",hb="Active__rJjxB",pb="Rotate__7cwTK",mb="Pagination__sbqMP",gb="PointerNone__kQdQS",Ee={TableContainer:ob,TableHeader:sb,Table:ib,selectable:ab,Cell:cb,Right:lb,Center:ub,Sortable:db,SortIcon:fb,Active:hb,Rotate:pb,Pagination:mb,PointerNone:gb},vb="EmptyStateContainer__Q9FEb",yb="Message__IHK6M",nc={EmptyStateContainer:vb,Message:yb},$d=({size:e=64})=>u.jsxs("svg",{width:e,height:e,viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[u.jsxs("g",{clipPath:"url(#clip-path)",children:[u.jsx("mask",{id:"mask0_1070_8032",style:{maskType:"luminance"},maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"64",height:"64",children:u.jsx("path",{d:"M64 0H0V64H64V0Z",fill:"white"})}),u.jsx("g",{mask:"url(#mask0_1070_8032)",children:u.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"})})]}),u.jsx("defs",{children:u.jsx("clipPath",{id:"clip-path",children:u.jsx("rect",{width:"64",height:"64",fill:"white"})})})]});$d.displayName="EmptyStateIcon";const Pi=({message:e="No results found"})=>u.jsxs("div",{className:N(nc.EmptyStateContainer),children:[u.jsx($d,{}),u.jsx("p",{className:nc.Message,children:e})]});Pi.displayName="EmptyState";const bb=(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)},Fd=({page:e,totalPages:t,onPageChange:n})=>{const r=e===1,o=e===t;return u.jsx(xi,{className:Ee.Pagination,children:u.jsxs(Si,{children:[u.jsx(Gn,{children:u.jsx(Ei,{className:N({[Ee.PointerNone]:r}),onClick:()=>!r&&n(e-1)})}),bb(t,e).map((s,i)=>u.jsxs(Gn,{children:[s==="..."&&u.jsx(Ri,{}),s!=="..."&&u.jsx(ur,{isActive:+s===e,onClick:()=>+s!==e&&n(+s),children:s})]},i)),u.jsx(Gn,{children:u.jsx(_i,{className:N({[Ee.PointerNone]:o}),onClick:()=>!o&&n(e+1)})})]})})};Fd.displayName="TablePagination";const Bd=({className:e,...t})=>u.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:e,...t,children:u.jsx("path",{d:"M6 2.5V9.5M6 9.5L9.5 6M6 9.5L2.5 6",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});Bd.displayName="ArrowDown";const Ud=({columns:e,data:t,isLoading:n,totalCount:r=0,headerLabel:o,sort:s,loadingConfig:i,pagination:a,onRowClick:c})=>{const{count:l=5,height:f=40}=i||{},h=y=>y.sortName??y.name,m=({width:y,maxWidth:w})=>!y&&!w?{}:{...y?{width:y,minWidth:y}:{},...w?{maxWidth:w}:{},overflow:"hidden"},g=y=>N({[Ee.Cell]:!0,[Ee.Center]:y.align==="center",[Ee.Right]:y.align==="right",[Ee.Sortable]:y.isSortable}),x=y=>{if(!s)return"";const w=h(y);return N({[Ee.SortIcon]:!0,[Ee.Active]:y.isSortable&&s.field===w,[Ee.Rotate]:s.field===w&&s.direction==="asc"})},p=y=>()=>c==null?void 0:c(y),v=y=>()=>{if(!s||!y.isSortable)return;const{field:w,direction:S,onSort:_}=s,R=h(y);w===R?_(R,S==="asc"?"desc":"asc"):_(R,"asc")};return u.jsxs(u.Fragment,{children:[u.jsxs("div",{className:Ee.TableContainer,children:[o&&u.jsx("div",{className:Ee.TableHeader,children:u.jsx(Ti,{count:r,singularText:o,children:(y,w)=>`${y} ${w}`})}),u.jsx("div",{className:Ee.Table,children:u.jsxs("table",{children:[u.jsx("thead",{children:u.jsx("tr",{children:e.map(y=>u.jsx("th",{children:u.jsxs("div",{className:g(y),onClick:v(y),children:[u.jsx("span",{children:y.displayName}),y.isSortable&&u.jsx(Bd,{className:x(y)})]})},y.name))})}),u.jsx("tbody",{children:u.jsxs(It,{children:[u.jsx(It.When,{condition:n,children:[...Array(l).keys()].map(y=>u.jsx("tr",{children:u.jsx("td",{colSpan:e.length,style:{padding:4},children:u.jsx(_o,{height:f})})},y))}),u.jsx(It.When,{condition:!t.length,children:u.jsx("tr",{children:u.jsx("td",{colSpan:e.length,children:u.jsx(Pi,{})})})}),u.jsx(It.Else,{children:t.map((y,w)=>u.jsx("tr",{className:c&&Ee.selectable,onClick:p(y),children:e.map(S=>u.jsx("td",{style:m(S),children:u.jsx("div",{className:g(S),children:S.cellRenderer?S.cellRenderer(y):S.valueGetter?S.valueGetter(y):y[S.name]})},`${S.name}-${w}`))},w))})]})})]})})]}),a&&u.jsx(Fd,{...a})]})};Ud.displayName="Table";const wb="alert__LblpE",Cb="destructive__bLNSM",xb="alertTitle__gblKf",Sb="alertDescription__BuVHV",ro={alert:wb,default:"default__mgO6A",destructive:Cb,alertTitle:xb,alertDescription:Sb},To=({className:e,variant:t="default",children:n,...r})=>u.jsx("div",{"data-slot":"alert",role:"alert",className:N(ro.alert,ro[t],e),...r,children:n}),Eb=d.forwardRef(({children:e,className:t,...n},r)=>u.jsx("div",{ref:r,"data-slot":"alert-title",className:N(ro.alertTitle,t),...n,children:e})),_b=d.forwardRef(({children:e,className:t,...n},r)=>u.jsx("div",{ref:r,"data-slot":"alert-description",className:N(ro.alertDescription,t),...n,children:e}));To.displayName="Alert";To.Title=Eb;To.Description=_b;const Wd=({isNavbarExpanded:e})=>{const{theme:t,setTheme:n}=Cl(),r=()=>n(t==="dark"?"light":"dark"),o=u.jsxs("div",{className:N($o.container,e&&$o.expanded),onClick:r,children:[t==="light"?u.jsx(yl,{}):u.jsx(bl,{}),e&&u.jsx("p",{className:$o.label,children:t==="light"?"Dark Mode":"Light Mode"})]});return e?o:u.jsx(jn,{displayName:t==="light"?"Switch to dark mode":"Switch to light mode",sideOffset:-16,children:o})};Wd.displayName="ToggleTheme";const Hd=({moduleName:e,className:t,style:n,LoadingComponent:r,ErrorComponent:o,IdleComponent:s})=>{var p;const i=Nn(),{statusName:a,isLoading:c,isMounted:l,isBroken:f}=Qs(e),h=E.useMemo(()=>i.find(v=>v.name===e),[i,e]),m=(h==null?void 0:h.type)==="fragment"?(p=h.ui)==null?void 0:p.mountAtSelector:void 0,g=m!=null&&m.startsWith("#")?m.slice(1):null;if(E.useEffect(()=>{h?h.type!=="fragment"?console.warn(`[FragmentSlot] Module "${e}" has type "${h.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.`)},[h,e,m]),!h||h.type!=="fragment"||!g)return null;const x=!c&&!l&&!f;return u.jsxs(u.Fragment,{children:[u.jsx("div",{id:g,className:t,style:n}),c&&r&&u.jsx(r,{moduleName:e}),f&&o&&u.jsx(o,{moduleName:e}),x&&s&&u.jsx(s,{moduleName:e,status:a})]})};Hd.displayName="FragmentSlot";const Rb=(e,t)=>{const n=r=>u.jsx(Ys,{operations:t,children:u.jsx(e,{...r})});return n.displayName="Authorized",n};function rc(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 oo(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?rc(Object(n),!0).forEach(function(r){Tb(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rc(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Vd(e){return(Vd=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 Tb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ls(e){return(Ls=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 zd(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(Ls(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(Ls(r)));return r}}var Xn=null;try{Xn=require("react").createContext()}catch{}var Pb={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 Ab(e){if(Vd(e)!=="object")throw new Error("single-spa-react requires a configuration object");var t,n=oo(oo({},Pb),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");!Xn&&n.React.createContext&&(Xn=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:Ob.bind(null,n),mount:jb.bind(null,n),unmount:Ib.bind(null,n)};return n.parcelCanUpdate&&(r.update=Nb.bind(null,n)),r}function Ob(e,t){return e.rootComponent?Promise.resolve():e.loadRootComponent(t).then(function(n){e.rootComponent=n})}function jb(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 c=a.version.slice(0,a.version.indexOf("."));try{return Number(c)>=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=qd(e,t,function(){n(this)}),s=zd(e,t)(),i=function(a){var c=a.reactDom,l=a.renderType,f=a.elementToRender,h=a.domElement,m=c[l];if(typeof m!="function")throw new Error('renderType "'.concat(l,'" did not return a function.'));switch(l){case"createRoot":case"unstable_createRoot":case"createBlockingRoot":case"unstable_createBlockingRoot":var g=m(h);return g.render(f),g;case"hydrateRoot":return m(h,f);case"hydrate":default:return m(f,h),null}}({elementToRender:o,domElement:s,reactDom:Ai(e),renderType:Db(e)});e.domElements[t.name]=s,e.renderResults[t.name]=i})}function Ib(e,t){return new Promise(function(n){e.unmountResolves[t.name]=n;var r=e.renderResults[t.name];r&&r.unmount?r.unmount():Ai(e).unmountComponentAtNode(e.domElements[t.name]),delete e.domElements[t.name],delete e.renderResults[t.name]})}function Nb(e,t){return new Promise(function(n){e.updateResolves[t.name]||(e.updateResolves[t.name]=[]),e.updateResolves[t.name].push(n);var r=qd(e,t,null),o=e.renderResults[t.name];if(o&&o.render)o.render(r);else{var s=zd(e,t)();Ai(e).render(r,s)}})}function Ai(e){return e.ReactDOMClient||e.ReactDOM}function Db(e){return typeof e.renderType=="function"?e.renderType():e.renderType}function qd(e,t,n){var r=e.React.createElement(e.rootComponent,t),o=Xn?e.React.createElement(Xn.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(c){s.React.Component.apply(this,arguments),this.state={caughtError:null,caughtErrorInfo:null},a.displayName="SingleSpaReactErrorBoundary(".concat(c.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(c,l){this.setState({caughtError:c,caughtErrorInfo:l})},a}(e,t),o=e.React.createElement(e.errorBoundaryClass,t,o)),o=e.React.createElement(e.SingleSpaRoot,oo(oo({},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)}const Lb=e=>{const t=new Np;return function(r){if(!r)throw new Error("Microfrontend did not receive any properties !!");const o=Fs(r.module.name),s=r.domElement;return E.useEffect(()=>{s==null||s.setAttribute("data-pae-ui","")},[s]),u.jsx(xc,{module:o,children:u.jsxs($p,{client:t,children:[u.jsx(e,{...r}),u.jsx(vp,{position:"top-right",reverseOrder:!0})]})})}},Mb=({rootComponent:e,...t})=>Ab({errorBoundary(n){return console.error(n),u.jsx(wi,{})},...t,rootComponent:Lb(e)}),kb=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,Kn,{value:e?Qf(t,e):t})},Oi=()=>{const[e]=In();return e.featureFlags},$b=e=>Oi()[e],Gd=({flag:e,children:t,fallback:n=null,invert:r=!1})=>{const s=Oi()[e]===!0;return(r?!s:s)?u.jsx(u.Fragment,{children:t}):u.jsx(u.Fragment,{children:n})};Gd.displayName="FeatureFlagGuard";const Kd=E.createContext(null);function Qd(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 Ko={JOIN_ROOM:"join_room",LEAVE_ROOM:"leave_room",USER_LIST:"user_list"},Yd=[1e3,2e3,4e3,8e3,16e3],Fb=Yd.length,Bb=({children:e})=>{const t=Mc("@bluealba/pae-rooms-service"),[n,r]=E.useState([]),[o,s]=E.useState("loading"),i=E.useRef(null),a=E.useRef(!1),c=E.useRef(0),l=E.useRef(null),f=E.useRef(!0),h=E.useRef(()=>{}),m=E.useCallback(T=>new Promise((P,D)=>{const I=new WebSocket(T);let L=!1;I.onopen=()=>{L=!0,c.current=0,f.current&&s("connected"),P(I)},I.addEventListener("message",async B=>{try{const U=await p(B);U.event===Ko.USER_LIST&&S(U.data)}catch(U){console.error("Error parsing WebSocket message:",U)}}),I.onerror=B=>{console.error("Rooms WebSocket error",B)},I.onclose=()=>{if(i.current!==I){L||D(new Error("WebSocket connection replaced"));return}a.current?f.current&&s("closed"):h.current(),L||D(new Error("WebSocket connection failed"))},i.current=I}),[]),g=E.useCallback(()=>{if(!t||!f.current)return;if(c.current>=Fb){s("error");return}const T=Yd[c.current];c.current++,s("reconnecting"),l.current=setTimeout(()=>{f.current&&t&&m(t).catch(()=>{})},T)},[t,m]);h.current=g;const x=E.useCallback(()=>{if(!t)return;l.current&&(clearTimeout(l.current),l.current=null);const T=i.current;T&&T.readyState!==WebSocket.CLOSED&&(a.current=!0,T.close()),c.current=0,a.current=!1,s("loading"),m(t)},[t,m]);E.useEffect(()=>{if(f.current=!0,a.current=!1,t)return m(t),()=>{var T;f.current=!1,l.current&&(clearTimeout(l.current),l.current=null),a.current=!0,(T=i.current)==null||T.close()}},[t,m]),E.useEffect(()=>{const T=()=>{if(document.visibilityState!=="visible")return;const P=i.current;P&&P.readyState===WebSocket.OPEN||(l.current&&(clearTimeout(l.current),l.current=null),c.current=0,x())};return document.addEventListener("visibilitychange",T),()=>{document.removeEventListener("visibilitychange",T)}},[x]);const p=async T=>{if(T.data instanceof Blob){const P=await T.data.text();return JSON.parse(P)}else return JSON.parse(T.data)},v=(T,P)=>{const D=i.current;!D||D.readyState!==WebSocket.OPEN||setTimeout(()=>{D.send(JSON.stringify({event:T,data:P}))},100)},y=T=>{v(Ko.JOIN_ROOM,{roomId:T})},w=T=>{v(Ko.LEAVE_ROOM,{roomId:T})},S=T=>{r(T.map(P=>({...P,username:P.username.toLowerCase(),color:Qd(P.username)})))},_=E.useCallback(T=>n.filter(P=>P.rooms.includes(T)),[n]),R={status:o,getRoomUsers:_,joinRoom:y,leaveRoom:w,reconnect:x};return u.jsx(Kd.Provider,{value:R,children:e})},Zd={autoJoin:!0,autoLeave:!0};function Ub(e,t=Zd){const{autoJoin:n,autoLeave:r}=t,o=E.useContext(Kd),{authUser:s}=or();if(!o)throw new Error("useRoom must be used within RoomsProvider");const i=E.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)},c=()=>{if(r){console.warn("[useRoom] Ignoring manual leaveRoom call because autoLeave is enabled.",{roomId:e});return}return i.current=!1,o.leaveRoom(e)};E.useEffect(()=>{if(!(!e||o.status!=="connected"))return(n||i.current)&&o.joinRoom(e),()=>{r&&o.status==="connected"&&o.leaveRoom(e)}},[o.status,e]);const l=o.getRoomUsers(e),f=l.findIndex(h=>h.username===(s==null?void 0:s.username))!==-1;return{users:l,roomId:e,hasJoined:f,joinRoom:a,leaveRoom:c,reconnect:o.reconnect}}const Wb="container__LbyGQ",Hb="avatarWrapper__HCQIZ",Vb="avatar__E453a",zb="overflowWrapper__ETnPO",qb="overflowBadge__igBKT",Hn={container:Wb,avatarWrapper:Hb,avatar:Vb,overflowWrapper:zb,overflowBadge:qb},Gb={sm:24,md:32,lg:40},Kb=({users:e,maxVisible:t=5,size:n="md",overlap:r=!0,className:o="",onUserClick:s})=>{const i=Gb[n],a=E.useMemo(()=>e.slice(0,t),[e,t]),c=E.useMemo(()=>e.slice(t),[e,t]),l=Math.max(0,e.length-t),f=h=>h.split(" ").map(m=>m[0]).join("").toUpperCase().slice(0,2);return u.jsxs("div",{className:N(Hn.container,o),children:[a.map((h,m)=>u.jsx(jn,{tooltipContent:h.displayName,side:"bottom",children:u.jsx("div",{className:Hn.avatarWrapper,style:{marginLeft:m>0&&r?`-${i*.25}px`:void 0},onClick:()=>s==null?void 0:s(h),children:u.jsx("div",{className:Hn.avatar,style:{width:i,height:i,backgroundColor:h.color,fontSize:n==="sm"?"10px":n==="md"?"12px":"14px",cursor:s?"pointer":"default"},children:f(h.displayName)})})},h.username)),l>0&&u.jsx(jn,{side:"bottom",tooltipContent:u.jsx("div",{children:c.map(h=>u.jsx("p",{children:h.displayName},h.username))}),children:u.jsx("div",{className:Hn.overflowWrapper,style:{marginLeft:r?`-${i*.25}px`:void 0},children:u.jsxs("div",{className:Hn.overflowBadge,style:{width:i,height:i,fontSize:n==="sm"?"10px":n==="md"?"12px":"14px"},children:["+",l]})})})]})};xf();exports.Alert=To;exports.ApplicationIcon=vl;exports.Authorized=Ys;exports.Badge=Zs;exports.Badges=Xs;exports.Button=Kr;exports.ClipboardCheckIcon=Sl;exports.ClipboardIcon=xl;exports.ConfirmDialog=Td;exports.CopyToClipboardButton=J1;exports.DEFAULT_OPTIONS=Zd;exports.Dialog=ge;exports.DropdownList=Eo;exports.EmptyState=Pi;exports.ErrorState=wi;exports.ExtendExtensionPoint=m1;exports.ExtensionPoint=fl;exports.EyeIcon=od;exports.FeatureFlagGuard=Gd;exports.FieldGroup=El;exports.FragmentSlot=Hd;exports.Input=uo;exports.InputError=_l;exports.Label=Rl;exports.List=nt;exports.ModulePlaceHolder=gl;exports.Pagination=xi;exports.PaginationContent=Si;exports.PaginationEllipsis=Ri;exports.PaginationItem=Gn;exports.PaginationLink=ur;exports.PaginationNext=_i;exports.PaginationPrevious=Ei;exports.PasswordInput=L2;exports.Pill=v3;exports.PlatformEventListener=w1;exports.PlatformEvents=Sf;exports.PluralizeCounter=Ti;exports.PortalContainerProvider=A0;exports.RoomAvatars=Kb;exports.RoomsProvider=Bb;exports.SearchAutocomplete=Zu;exports.SearchInput=mi;exports.Select=Js;exports.Select2=ku;exports.Show=It;exports.Skeleton=_o;exports.SkeletonList=ed;exports.Spinner=td;exports.StyleRegistry=Ms;exports.Switch=nd;exports.Table=Ud;exports.Tabs=A2;exports.TabsContent=I2;exports.TabsList=O2;exports.TabsTrigger=j2;exports.TextArea=$u;exports.TextWithTooltip=Qu;exports.ThemeToggle=Wd;exports.Tooltip=jn;exports.authorized=Rb;exports.dropdownListStyles=Wt;exports.extensionPoint=v1;exports.generateUserColor=Qd;exports.getApplications=$s;exports.getInitials=Ff;exports.getOperations=Sc;exports.hasAccess=_c;exports.initializeMicroFrontend=Mb;exports.isPlatformCustomizationCompleted=Th;exports.isValidEmail=$f;exports.logout=Lf;exports.navigateTo=Mf;exports.platformHaveAnyCustomization=Rh;exports.setupTestEnvironment=kb;exports.useAppStatus=Qs;exports.useApplicationIcon=Nc;exports.useApplicationJSModule=ao;exports.useApplicationMenu=zf;exports.useApplicationUIModule=Ic;exports.useApplications=Oc;exports.useAuth=or;exports.useCatalog=Nn;exports.useCurrentApplication=Us;exports.useCurrentApplicationName=Lc;exports.useCurrentJSModule=Jf;exports.useDynamicFonts=Wc;exports.useDynamicStyleSheet=Uc;exports.useExtendExtensionPoint=Fc;exports.useExtensionPoint=$c;exports.useFeatureFlag=$b;exports.useFeatureFlags=Oi;exports.useFileStorage=p1;exports.useGetPlatformTheme=_h;exports.useHasNoSession=If;exports.useLocation=bc;exports.useModule=Fs;exports.useModuleCommonPaths=Df;exports.useModuleConfig=Rc;exports.useModuleConfigByName=Tc;exports.useModuleMenu=Dc;exports.useModuleMetadata=rr;exports.useMutableCatalog=Pf;exports.useNotifications=Vs;exports.useOperations=Ec;exports.usePAECustomizationsLoadingState=Eh;exports.usePAEState=In;exports.usePlatformCustomization=Sh;exports.usePlatformEventListener=Bc;exports.usePortalContainer=pi;exports.useResource=Yp;exports.useResourceActions=ul;exports.useRoom=Ub;exports.useServiceBaseURL=Ws;exports.useServiceInvoker=Hs;exports.useServiceWebSocketURL=Mc;exports.useTenants=l1;exports.useTheme=Cl;exports.useTrackEvent=sh;exports.useTrackEvents=kc;exports.useUIApplications=jc;exports.useUserState=d1;
|
|
255
|
+
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},Z2="DialogDescriptionWarning",X2=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${wd(Z2).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},J2=ad,e3=ud,t3=dd,n3=fd,r3=pd,o3=gd,s3=vd;const i3="Overlay__M5Z83",a3="Content__wAkP4",ec={Overlay:i3,Content:a3},c3="Header__VHxNf",l3="Content__I04qM",u3="Close__xSN-7",d3="Title__Dznh6",f3="Description__ALT2w",h3="Footer__-8gzQ",p3="Actions__kKF2Q",cn={Header:c3,Content:l3,Close:u3,Title:d3,Description:f3,Footer:h3,Actions:p3},Cd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Header,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Cd.displayName="Header";const xd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Content,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});xd.displayName="Content";const Sd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Footer,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Sd.displayName="Footer";const Ed=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Title,t);return u.jsx(r3,{ref:r,className:o,...n,children:e})});Ed.displayName="Title";const _d=E.forwardRef(({className:e,...t},n)=>{const r=N(cn.Close,e);return u.jsx(s3,{ref:n,asChild:!0,className:r,...t,children:u.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:u.jsx("path",{d:"M11 1L1 11M1 1L11 11",stroke:"#A9A9A9",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})});_d.displayName="Close";const Rd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Actions,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Rd.displayName="Actions";const Td=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(cn.Description,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Td.displayName="Description";const ge=({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})`},c=mi();return u.jsx(J2,{onOpenChange:s,open:n,children:u.jsxs(e3,{container:c,children:[u.jsx(t3,{className:ec.Overlay,style:i}),u.jsxs(n3,{children:[u.jsx(o3,{}),u.jsx("div",{className:N(ec.Content,r),style:a,children:e})]})]})})};ge.displayName="Dialog";ge.Header=Cd;ge.Content=xd;ge.Footer=Sd;ge.Actions=Rd;ge.Title=Ed;ge.Description=Td;ge.Close=_d;const m3="pill__vtGwB",g3="pill--solid__F-mR4",y3="pill--outline__gC-mh",tc={pill:m3,"pill--solid":"pill--solid__F-mR4",pillSolid:g3,"pill--outline":"pill--outline__gC-mh",pillOutline:y3},v3=({children:e,variant:t="solid",className:n})=>{const r=N(tc.pill,tc[`pill--${t}`],n);return u.jsx("div",{className:r,children:e})},b3="DialogContent__-WjG9",w3="Message__AUgVP",nc={DialogContent:b3,Message:w3},Pd=({loading:e,title:t,children:n,className:r,onClose:o,onConfirm:s,zIndexLevel:i=1,...a})=>u.jsxs(ge,{...a,zIndexLevel:i,className:N(nc.DialogContent,r),children:[u.jsxs(ge.Header,{children:[u.jsx(ge.Title,{children:t}),u.jsx(ge.Close,{onClick:o})]}),u.jsx(ge.Content,{children:typeof n=="string"?u.jsx("p",{className:nc.Message,children:n}):n}),u.jsx(ge.Footer,{children:u.jsxs(ge.Actions,{children:[u.jsx(Kr,{onClick:o,disabled:e,variant:"outlined",children:"Cancel"}),u.jsx(Kr,{onClick:s,disabled:e,loading:e,variant:"contained",children:"Confirm"})]})})]});Pd.displayName="ConfirmDialog";const C3="container__AjtYJ",x3="title__A2vCu",S3="description__bP6Ig",E3="mailToText__SdlsE",Ir={container:C3,title:x3,description:S3,mailToText:E3},Ad=()=>u.jsxs("svg",{width:"200",height:"200",viewBox:"0 0 200 200",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"}),u.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)"})]});Ad.displayName="WarningIcon";const _3="support@bluealba.com",R3="@bluealba/pae-shell-ui",Ci=()=>{const{supportEmail:e=_3}=Pc(R3),t=`mailto:${e}?Subject=Support`;return u.jsxs("div",{className:Ir.container,children:[u.jsx(Ad,{}),u.jsx("div",{className:Ir.title,children:"Oops! Something went wrong"}),u.jsxs("div",{className:Ir.description,children:["If the error persists, ",u.jsx("a",{className:Ir.mailToText,href:t,children:"contact the administrator."})]})]})};Ci.displayName="ErrorState";const T3="List__h09XG",P3="List__h09XG",A3="Item__YMy2i",O3="Item__YMy2i",j3="List--primary__J2pbx",I3="List--secondary__gi1ao",N3="Item--selected__yRWow",D3="Title__RJmEW",L3="Title__RJmEW",M3="Description__DGyX2",k3="Description__DGyX2",$3="Actions__UHP5l",F3="Actions__UHP5l",B3="Action__q-R1I",U3="Action__q-R1I",W3="Item--disabled__Ke1u-",H3="List--small__ijoSR",V3="List--medium__E1FEY",q3="List--large__T8tfz",z3="Icon__dFr-L",G3="Icon__dFr-L",Be={List:T3,list:P3,Item:A3,item:O3,"List--primary":"List--primary__J2pbx",listPrimary:j3,"List--secondary":"List--secondary__gi1ao",listSecondary:I3,"Item--selected":"Item--selected__yRWow",itemSelected:N3,Title:D3,title:L3,Description:M3,description:k3,Actions:$3,actions:F3,Action:B3,action:U3,"Item--disabled":"Item--disabled__Ke1u-",itemDisabled:W3,"List--small":"List--small__ijoSR",listSmall:H3,"List--medium":"List--medium__E1FEY",listMedium:V3,"List--large":"List--large__T8tfz",listLarge:q3,Icon:z3,icon:G3},Od=E.forwardRef(({children:e,className:t,selected:n,disabled:r=!1,...o},s)=>{const i=N(Be.Item,{[Be["Item--selected"]]:n,[Be["Item--disabled"]]:r},t);return u.jsx("li",{ref:s,className:i,role:"listitem","aria-disabled":r,...o,children:e})});Od.displayName="Item";const jd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Be.Title,t);return u.jsx("h3",{ref:r,className:o,...n,children:e})});jd.displayName="Title";const Id=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Be.Description,t);return u.jsx("p",{ref:r,className:o,...n,children:e})});Id.displayName="Description";const xi=({className:e,...t})=>u.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:e,...t,children:[u.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"}),u.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"}),u.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"})]});xi.displayName="HorizontalDots";const Nd=E.forwardRef(({children:e,className:t,onClick:n,...r},o)=>{const s=E.useRef(null),[i,a]=E.useState(!1),c=N(Be.Actions,t),l=()=>{const x=Wt["DropdownList--open"],p=Wt["DropdownList--closed"];document.querySelectorAll(`.${x}`).forEach(v=>{v!==s.current&&(v.classList.remove(x),v.classList.add(p))})},f=x=>{x.stopPropagation(),i?h():(a(!0),n==null||n(x))},h=()=>{a(!1)},m=x=>{x.key==="Escape"&&h()},g=x=>{s.current&&!s.current.contains(x.target)&&h()};return E.useEffect(()=>(i?(l(),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]),u.jsxs("div",{ref:o,className:c,onClick:f,role:"button",tabIndex:0,"data-testid":"actions",...r,children:[u.jsx(xi,{}),u.jsx(_o,{align:"left",ref:s,open:i,"data-testid":"actions-dropdown",role:"menu","aria-label":"Actions",children:e})]})});Nd.displayName="Actions";const Dd=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Be.Action,t);return u.jsx("button",{ref:r,className:o,...n,children:e})});Dd.displayName="Action";const Ld=E.forwardRef(({children:e,className:t,...n},r)=>{const o=N(Be.Icon,t);return u.jsx("div",{ref:r,className:o,...n,children:e})});Ld.displayName="Icon";const nt=E.forwardRef(({children:e,className:t,size:n="medium",variant:r,...o},s)=>{const i=N(Be.List,{[Be[`List--${n}`]]:n,[Be[`List--${r}`]]:r},t);return u.jsx("ul",{ref:s,className:i,role:"list",...o,children:e})});nt.displayName="List";nt.Item=Od;nt.Badges=Js;nt.Badge=Xs;nt.Title=jd;nt.Description=Id;nt.Actions=Nd;nt.Action=Dd;nt.Icon=Ld;const K3="Navigation__uylxk",Q3="PaginationContent__UpLw0",Y3="PaginationEllipsis__perWk",Z3="PaginationLink__GVUZj",X3="Active__u1Ahy",J3="Disabled__8WM0y",eb="Prev__wp4hc",tb="Next__eVyL5",ht={Navigation:K3,PaginationContent:Q3,PaginationEllipsis:Y3,PaginationLink:Z3,Active:X3,Disabled:J3,Prev:eb,Next:tb},Md=({className:e,...t})=>u.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:[u.jsx("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),u.jsx("path",{d:"M9 6l6 6l-6 6"})]});Md.displayName="ChevronRight";const kd=({className:e,...t})=>u.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:[u.jsx("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}),u.jsx("path",{d:"M15 6l-6 6l6 6"})]});kd.displayName="ChevronLeft";const Si=({className:e,...t})=>u.jsx("nav",{role:"navigation","aria-label":"pagination",className:N(ht.Navigation,e),...t});Si.displayName="Pagination";const Ei=d.forwardRef(({className:e,...t},n)=>u.jsx("ul",{ref:n,className:N(ht.PaginationContent,e),...t}));Ei.displayName="PaginationContent";const Gn=d.forwardRef(({className:e,...t},n)=>u.jsx("li",{ref:n,className:e,...t}));Gn.displayName="PaginationItem";const ur=({className:e,isActive:t,...n})=>u.jsx("a",{"aria-current":t?"page":void 0,className:N(ht.PaginationLink,t&&ht.Active,e),...n});ur.displayName="PaginationLink";const _i=({className:e,disabled:t,...n})=>u.jsxs(ur,{"aria-label":"Go to previous page",className:N(t&&ht.Disabled,ht.Prev,e),...n,children:[u.jsx(kd,{}),u.jsx("span",{children:"Previous"})]});_i.displayName="PaginationPrevious";const Ri=({className:e,disabled:t,...n})=>u.jsxs(ur,{"aria-label":"Go to next page",className:N(t&&ht.Disabled,ht.Next,e),...n,children:[u.jsx("span",{children:"Next"}),u.jsx(Md,{})]});Ri.displayName="PaginationNext";const Ti=({className:e,...t})=>u.jsx("span",{"aria-hidden":!0,className:N(ht.PaginationEllipsis,e),...t,children:u.jsx(xi,{})});Ti.displayName="PaginationEllipsis";function nb(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 $d={exports:{}};(function(e,t){(function(n,r){typeof nb=="function"?e.exports=r():n.pluralize=r()})(Of,function(){var n=[],r=[],o={},s={},i={};function a(p){return typeof p=="string"?new RegExp("^"+p+"$","i"):p}function c(p,y){return p===y?y:p===p.toLowerCase()?y.toLowerCase():p===p.toUpperCase()?y.toUpperCase():p[0]===p[0].toUpperCase()?y.charAt(0).toUpperCase()+y.substr(1).toLowerCase():y.toLowerCase()}function l(p,y){return p.replace(/\$(\d{1,2})/g,function(v,w){return y[w]||""})}function f(p,y){return p.replace(y[0],function(v,w){var S=l(y[1],arguments);return c(v===""?p[w-1]:v,S)})}function h(p,y,v){if(!p.length||o.hasOwnProperty(p))return y;for(var w=v.length;w--;){var S=v[w];if(S[0].test(y))return f(y,S)}return y}function m(p,y,v){return function(w){var S=w.toLowerCase();return y.hasOwnProperty(S)?c(w,S):p.hasOwnProperty(S)?c(w,p[S]):h(S,w,v)}}function g(p,y,v,w){return function(S){var _=S.toLowerCase();return y.hasOwnProperty(_)?!0:p.hasOwnProperty(_)?!1:h(_,_,v)===_}}function x(p,y,v){var w=y===1?x.singular(p):x.plural(p);return(v?y+" ":"")+w}return x.plural=m(i,s,n),x.isPlural=g(i,s,n),x.singular=m(s,i,r),x.isSingular=g(s,i,r),x.addPluralRule=function(p,y){n.push([a(p),y])},x.addSingularRule=function(p,y){r.push([a(p),y])},x.addUncountableRule=function(p){if(typeof p=="string"){o[p.toLowerCase()]=!0;return}x.addPluralRule(p,"$0"),x.addSingularRule(p,"$0")},x.addIrregularRule=function(p,y){y=y.toLowerCase(),p=p.toLowerCase(),i[p]=y,s[y]=p},[["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(p){return x.addIrregularRule(p[0],p[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(p){return x.addPluralRule(p[0],p[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(p){return x.addSingularRule(p[0],p[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(x.addUncountableRule),x})})($d);var rb=$d.exports;const ob=jf(rb),Pi=({count:e,singularText:t,children:n=(r,o)=>`${r} ${o}`})=>u.jsx(u.Fragment,{children:n(e,ob(t,e))});Pi.displayName="PluralizeCounter";const sb="TableContainer__osh6Z",ib="TableHeader__sYa-8",ab="Table__2cIs3",cb="selectable__WsGg1",lb="Cell__ZEv-K",ub="Right__YoM1V",db="Center__CF3tr",fb="Sortable__JIV1V",hb="SortIcon__f0bBy",pb="Active__rJjxB",mb="Rotate__7cwTK",gb="Pagination__sbqMP",yb="PointerNone__kQdQS",Ee={TableContainer:sb,TableHeader:ib,Table:ab,selectable:cb,Cell:lb,Right:ub,Center:db,Sortable:fb,SortIcon:hb,Active:pb,Rotate:mb,Pagination:gb,PointerNone:yb},vb="EmptyStateContainer__Q9FEb",bb="Message__IHK6M",rc={EmptyStateContainer:vb,Message:bb},Fd=({size:e=64})=>u.jsxs("svg",{width:e,height:e,viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[u.jsxs("g",{clipPath:"url(#clip-path)",children:[u.jsx("mask",{id:"mask0_1070_8032",style:{maskType:"luminance"},maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"64",height:"64",children:u.jsx("path",{d:"M64 0H0V64H64V0Z",fill:"white"})}),u.jsx("g",{mask:"url(#mask0_1070_8032)",children:u.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"})})]}),u.jsx("defs",{children:u.jsx("clipPath",{id:"clip-path",children:u.jsx("rect",{width:"64",height:"64",fill:"white"})})})]});Fd.displayName="EmptyStateIcon";const Ai=({message:e="No results found"})=>u.jsxs("div",{className:N(rc.EmptyStateContainer),children:[u.jsx(Fd,{}),u.jsx("p",{className:rc.Message,children:e})]});Ai.displayName="EmptyState";const wb=(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)},Bd=({page:e,totalPages:t,onPageChange:n})=>{const r=e===1,o=e===t;return u.jsx(Si,{className:Ee.Pagination,children:u.jsxs(Ei,{children:[u.jsx(Gn,{children:u.jsx(_i,{className:N({[Ee.PointerNone]:r}),onClick:()=>!r&&n(e-1)})}),wb(t,e).map((s,i)=>u.jsxs(Gn,{children:[s==="..."&&u.jsx(Ti,{}),s!=="..."&&u.jsx(ur,{isActive:+s===e,onClick:()=>+s!==e&&n(+s),children:s})]},i)),u.jsx(Gn,{children:u.jsx(Ri,{className:N({[Ee.PointerNone]:o}),onClick:()=>!o&&n(e+1)})})]})})};Bd.displayName="TablePagination";const Ud=({className:e,...t})=>u.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:e,...t,children:u.jsx("path",{d:"M6 2.5V9.5M6 9.5L9.5 6M6 9.5L2.5 6",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})});Ud.displayName="ArrowDown";const Wd=({columns:e,data:t,isLoading:n,totalCount:r=0,headerLabel:o,sort:s,loadingConfig:i,pagination:a,onRowClick:c})=>{const{count:l=5,height:f=40}=i||{},h=v=>v.sortName??v.name,m=({width:v,maxWidth:w})=>!v&&!w?{}:{...v?{width:v,minWidth:v}:{},...w?{maxWidth:w}:{},overflow:"hidden"},g=v=>N({[Ee.Cell]:!0,[Ee.Center]:v.align==="center",[Ee.Right]:v.align==="right",[Ee.Sortable]:v.isSortable}),x=v=>{if(!s)return"";const w=h(v);return N({[Ee.SortIcon]:!0,[Ee.Active]:v.isSortable&&s.field===w,[Ee.Rotate]:s.field===w&&s.direction==="asc"})},p=v=>()=>c==null?void 0:c(v),y=v=>()=>{if(!s||!v.isSortable)return;const{field:w,direction:S,onSort:_}=s,R=h(v);w===R?_(R,S==="asc"?"desc":"asc"):_(R,"asc")};return u.jsxs(u.Fragment,{children:[u.jsxs("div",{className:Ee.TableContainer,children:[o&&u.jsx("div",{className:Ee.TableHeader,children:u.jsx(Pi,{count:r,singularText:o,children:(v,w)=>`${v} ${w}`})}),u.jsx("div",{className:Ee.Table,children:u.jsxs("table",{children:[u.jsx("thead",{children:u.jsx("tr",{children:e.map(v=>u.jsx("th",{children:u.jsxs("div",{className:g(v),onClick:y(v),children:[u.jsx("span",{children:v.displayName}),v.isSortable&&u.jsx(Ud,{className:x(v)})]})},v.name))})}),u.jsx("tbody",{children:u.jsxs(It,{children:[u.jsx(It.When,{condition:n,children:[...Array(l).keys()].map(v=>u.jsx("tr",{children:u.jsx("td",{colSpan:e.length,style:{padding:4},children:u.jsx(Ro,{height:f})})},v))}),u.jsx(It.When,{condition:!t.length,children:u.jsx("tr",{children:u.jsx("td",{colSpan:e.length,children:u.jsx(Ai,{})})})}),u.jsx(It.Else,{children:t.map((v,w)=>u.jsx("tr",{className:c&&Ee.selectable,onClick:p(v),children:e.map(S=>u.jsx("td",{style:m(S),children:u.jsx("div",{className:g(S),children:S.cellRenderer?S.cellRenderer(v):S.valueGetter?S.valueGetter(v):v[S.name]})},`${S.name}-${w}`))},w))})]})})]})})]}),a&&u.jsx(Bd,{...a})]})};Wd.displayName="Table";const Cb="alert__LblpE",xb="destructive__bLNSM",Sb="alertTitle__gblKf",Eb="alertDescription__BuVHV",ro={alert:Cb,default:"default__mgO6A",destructive:xb,alertTitle:Sb,alertDescription:Eb},Po=({className:e,variant:t="default",children:n,...r})=>u.jsx("div",{"data-slot":"alert",role:"alert",className:N(ro.alert,ro[t],e),...r,children:n}),_b=d.forwardRef(({children:e,className:t,...n},r)=>u.jsx("div",{ref:r,"data-slot":"alert-title",className:N(ro.alertTitle,t),...n,children:e})),Rb=d.forwardRef(({children:e,className:t,...n},r)=>u.jsx("div",{ref:r,"data-slot":"alert-description",className:N(ro.alertDescription,t),...n,children:e}));Po.displayName="Alert";Po.Title=_b;Po.Description=Rb;const Hd=({isNavbarExpanded:e})=>{const{theme:t,setTheme:n}=xl(),r=()=>n(t==="dark"?"light":"dark"),o=u.jsxs("div",{className:N(Fo.container,e&&Fo.expanded),onClick:r,children:[t==="light"?u.jsx(bl,{}):u.jsx(wl,{}),e&&u.jsx("p",{className:Fo.label,children:t==="light"?"Dark Mode":"Light Mode"})]});return e?o:u.jsx(jn,{displayName:t==="light"?"Switch to dark mode":"Switch to light mode",sideOffset:-16,children:o})};Hd.displayName="ToggleTheme";const Vd=({moduleName:e,className:t,style:n,LoadingComponent:r,ErrorComponent:o,IdleComponent:s})=>{var p;const i=Nn(),{statusName:a,isLoading:c,isMounted:l,isBroken:f}=Ys(e),h=E.useMemo(()=>i.find(y=>y.name===e),[i,e]),m=(h==null?void 0:h.type)==="fragment"?(p=h.ui)==null?void 0:p.mountAtSelector:void 0,g=m!=null&&m.startsWith("#")?m.slice(1):null;if(E.useEffect(()=>{h?h.type!=="fragment"?console.warn(`[FragmentSlot] Module "${e}" has type "${h.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.`)},[h,e,m]),!h||h.type!=="fragment"||!g)return null;const x=!c&&!l&&!f;return u.jsxs(u.Fragment,{children:[u.jsx("div",{id:g,className:t,style:n}),c&&r&&u.jsx(r,{moduleName:e}),f&&o&&u.jsx(o,{moduleName:e}),x&&s&&u.jsx(s,{moduleName:e,status:a})]})};Vd.displayName="FragmentSlot";const Tb=(e,t)=>{const n=r=>u.jsx(Zs,{operations:t,children:u.jsx(e,{...r})});return n.displayName="Authorized",n};function oc(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 oo(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?oc(Object(n),!0).forEach(function(r){Pb(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oc(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qd(e){return(qd=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 Pb(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ms(e){return(Ms=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 zd(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(Ms(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(Ms(r)));return r}}var Xn=null;try{Xn=require("react").createContext()}catch{}var Ab={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 Ob(e){if(qd(e)!=="object")throw new Error("single-spa-react requires a configuration object");var t,n=oo(oo({},Ab),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");!Xn&&n.React.createContext&&(Xn=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:jb.bind(null,n),mount:Ib.bind(null,n),unmount:Nb.bind(null,n)};return n.parcelCanUpdate&&(r.update=Db.bind(null,n)),r}function jb(e,t){return e.rootComponent?Promise.resolve():e.loadRootComponent(t).then(function(n){e.rootComponent=n})}function Ib(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 c=a.version.slice(0,a.version.indexOf("."));try{return Number(c)>=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=Gd(e,t,function(){n(this)}),s=zd(e,t)(),i=function(a){var c=a.reactDom,l=a.renderType,f=a.elementToRender,h=a.domElement,m=c[l];if(typeof m!="function")throw new Error('renderType "'.concat(l,'" did not return a function.'));switch(l){case"createRoot":case"unstable_createRoot":case"createBlockingRoot":case"unstable_createBlockingRoot":var g=m(h);return g.render(f),g;case"hydrateRoot":return m(h,f);case"hydrate":default:return m(f,h),null}}({elementToRender:o,domElement:s,reactDom:Oi(e),renderType:Lb(e)});e.domElements[t.name]=s,e.renderResults[t.name]=i})}function Nb(e,t){return new Promise(function(n){e.unmountResolves[t.name]=n;var r=e.renderResults[t.name];r&&r.unmount?r.unmount():Oi(e).unmountComponentAtNode(e.domElements[t.name]),delete e.domElements[t.name],delete e.renderResults[t.name]})}function Db(e,t){return new Promise(function(n){e.updateResolves[t.name]||(e.updateResolves[t.name]=[]),e.updateResolves[t.name].push(n);var r=Gd(e,t,null),o=e.renderResults[t.name];if(o&&o.render)o.render(r);else{var s=zd(e,t)();Oi(e).render(r,s)}})}function Oi(e){return e.ReactDOMClient||e.ReactDOM}function Lb(e){return typeof e.renderType=="function"?e.renderType():e.renderType}function Gd(e,t,n){var r=e.React.createElement(e.rootComponent,t),o=Xn?e.React.createElement(Xn.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(c){s.React.Component.apply(this,arguments),this.state={caughtError:null,caughtErrorInfo:null},a.displayName="SingleSpaReactErrorBoundary(".concat(c.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(c,l){this.setState({caughtError:c,caughtErrorInfo:l})},a}(e,t),o=e.React.createElement(e.errorBoundaryClass,t,o)),o=e.React.createElement(e.SingleSpaRoot,oo(oo({},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)}const Mb=e=>{const t=new Dp;return function(r){if(!r)throw new Error("Microfrontend did not receive any properties !!");const o=Bs(r.module.name),s=r.domElement;return E.useEffect(()=>{s==null||s.setAttribute("data-pae-ui","")},[s]),u.jsx(Sc,{module:o,children:u.jsxs(Fp,{client:t,children:[u.jsx(e,{...r}),u.jsx(vp,{position:"top-right",reverseOrder:!0})]})})}},so=new Map,kb=e=>`style[data-pae-module="${CSS.escape(e)}"]`,$b=e=>{if(typeof document>"u")return;const t=Array.from(document.querySelectorAll(kb(e)));t.length!==0&&(t.forEach(n=>n.remove()),so.set(e,[...so.get(e)??[],...t]))},Fb=e=>{if(typeof document>"u")return;const t=so.get(e);!t||t.length===0||(so.delete(e),t.forEach(n=>document.head.appendChild(n)))},Bb=({rootComponent:e,...t})=>{const n=Ob({errorBoundary(r){return console.error(r),u.jsx(Ci,{})},...t,rootComponent:Mb(e)});return{...n,mount:async r=>(r!=null&&r.name&&Fb(r.name),n.mount(r)),unmount:async r=>{const o=await n.unmount(r);return r!=null&&r.name&&$b(r.name),o}}},Ub=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,Kn,{value:e?Yf(t,e):t})},ji=()=>{const[e]=In();return e.featureFlags},Wb=e=>ji()[e],Kd=({flag:e,children:t,fallback:n=null,invert:r=!1})=>{const s=ji()[e]===!0;return(r?!s:s)?u.jsx(u.Fragment,{children:t}):u.jsx(u.Fragment,{children:n})};Kd.displayName="FeatureFlagGuard";const Qd=E.createContext(null);function Yd(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 Qo={JOIN_ROOM:"join_room",LEAVE_ROOM:"leave_room",USER_LIST:"user_list"},Zd=[1e3,2e3,4e3,8e3,16e3],Hb=Zd.length,Vb=({children:e})=>{const t=kc("@bluealba/pae-rooms-service"),[n,r]=E.useState([]),[o,s]=E.useState("loading"),i=E.useRef(null),a=E.useRef(!1),c=E.useRef(0),l=E.useRef(null),f=E.useRef(!0),h=E.useRef(()=>{}),m=E.useCallback(T=>new Promise((P,D)=>{const I=new WebSocket(T);let L=!1;I.onopen=()=>{L=!0,c.current=0,f.current&&s("connected"),P(I)},I.addEventListener("message",async B=>{try{const U=await p(B);U.event===Qo.USER_LIST&&S(U.data)}catch(U){console.error("Error parsing WebSocket message:",U)}}),I.onerror=B=>{console.error("Rooms WebSocket error",B)},I.onclose=()=>{if(i.current!==I){L||D(new Error("WebSocket connection replaced"));return}a.current?f.current&&s("closed"):h.current(),L||D(new Error("WebSocket connection failed"))},i.current=I}),[]),g=E.useCallback(()=>{if(!t||!f.current)return;if(c.current>=Hb){s("error");return}const T=Zd[c.current];c.current++,s("reconnecting"),l.current=setTimeout(()=>{f.current&&t&&m(t).catch(()=>{})},T)},[t,m]);h.current=g;const x=E.useCallback(()=>{if(!t)return;l.current&&(clearTimeout(l.current),l.current=null);const T=i.current;T&&T.readyState!==WebSocket.CLOSED&&(a.current=!0,T.close()),c.current=0,a.current=!1,s("loading"),m(t)},[t,m]);E.useEffect(()=>{if(f.current=!0,a.current=!1,t)return m(t),()=>{var T;f.current=!1,l.current&&(clearTimeout(l.current),l.current=null),a.current=!0,(T=i.current)==null||T.close()}},[t,m]),E.useEffect(()=>{const T=()=>{if(document.visibilityState!=="visible")return;const P=i.current;P&&P.readyState===WebSocket.OPEN||(l.current&&(clearTimeout(l.current),l.current=null),c.current=0,x())};return document.addEventListener("visibilitychange",T),()=>{document.removeEventListener("visibilitychange",T)}},[x]);const p=async T=>{if(T.data instanceof Blob){const P=await T.data.text();return JSON.parse(P)}else return JSON.parse(T.data)},y=(T,P)=>{const D=i.current;!D||D.readyState!==WebSocket.OPEN||setTimeout(()=>{D.send(JSON.stringify({event:T,data:P}))},100)},v=T=>{y(Qo.JOIN_ROOM,{roomId:T})},w=T=>{y(Qo.LEAVE_ROOM,{roomId:T})},S=T=>{r(T.map(P=>({...P,username:P.username.toLowerCase(),color:Yd(P.username)})))},_=E.useCallback(T=>n.filter(P=>P.rooms.includes(T)),[n]),R={status:o,getRoomUsers:_,joinRoom:v,leaveRoom:w,reconnect:x};return u.jsx(Qd.Provider,{value:R,children:e})},Xd={autoJoin:!0,autoLeave:!0};function qb(e,t=Xd){const{autoJoin:n,autoLeave:r}=t,o=E.useContext(Qd),{authUser:s}=or();if(!o)throw new Error("useRoom must be used within RoomsProvider");const i=E.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)},c=()=>{if(r){console.warn("[useRoom] Ignoring manual leaveRoom call because autoLeave is enabled.",{roomId:e});return}return i.current=!1,o.leaveRoom(e)};E.useEffect(()=>{if(!(!e||o.status!=="connected"))return(n||i.current)&&o.joinRoom(e),()=>{r&&o.status==="connected"&&o.leaveRoom(e)}},[o.status,e]);const l=o.getRoomUsers(e),f=l.findIndex(h=>h.username===(s==null?void 0:s.username))!==-1;return{users:l,roomId:e,hasJoined:f,joinRoom:a,leaveRoom:c,reconnect:o.reconnect}}const zb="container__LbyGQ",Gb="avatarWrapper__HCQIZ",Kb="avatar__E453a",Qb="overflowWrapper__ETnPO",Yb="overflowBadge__igBKT",Hn={container:zb,avatarWrapper:Gb,avatar:Kb,overflowWrapper:Qb,overflowBadge:Yb},Zb={sm:24,md:32,lg:40},Xb=({users:e,maxVisible:t=5,size:n="md",overlap:r=!0,className:o="",onUserClick:s})=>{const i=Zb[n],a=E.useMemo(()=>e.slice(0,t),[e,t]),c=E.useMemo(()=>e.slice(t),[e,t]),l=Math.max(0,e.length-t),f=h=>h.split(" ").map(m=>m[0]).join("").toUpperCase().slice(0,2);return u.jsxs("div",{className:N(Hn.container,o),children:[a.map((h,m)=>u.jsx(jn,{tooltipContent:h.displayName,side:"bottom",children:u.jsx("div",{className:Hn.avatarWrapper,style:{marginLeft:m>0&&r?`-${i*.25}px`:void 0},onClick:()=>s==null?void 0:s(h),children:u.jsx("div",{className:Hn.avatar,style:{width:i,height:i,backgroundColor:h.color,fontSize:n==="sm"?"10px":n==="md"?"12px":"14px",cursor:s?"pointer":"default"},children:f(h.displayName)})})},h.username)),l>0&&u.jsx(jn,{side:"bottom",tooltipContent:u.jsx("div",{children:c.map(h=>u.jsx("p",{children:h.displayName},h.username))}),children:u.jsx("div",{className:Hn.overflowWrapper,style:{marginLeft:r?`-${i*.25}px`:void 0},children:u.jsxs("div",{className:Hn.overflowBadge,style:{width:i,height:i,fontSize:n==="sm"?"10px":n==="md"?"12px":"14px"},children:["+",l]})})})]})};Sf();exports.Alert=Po;exports.ApplicationIcon=vl;exports.Authorized=Zs;exports.Badge=Xs;exports.Badges=Js;exports.Button=Kr;exports.ClipboardCheckIcon=El;exports.ClipboardIcon=Sl;exports.ConfirmDialog=Pd;exports.CopyToClipboardButton=em;exports.DEFAULT_OPTIONS=Xd;exports.Dialog=ge;exports.DropdownList=_o;exports.EmptyState=Ai;exports.ErrorState=Ci;exports.ExtendExtensionPoint=g1;exports.ExtensionPoint=hl;exports.EyeIcon=sd;exports.FeatureFlagGuard=Kd;exports.FieldGroup=_l;exports.FragmentSlot=Vd;exports.Input=fo;exports.InputError=Rl;exports.Label=Tl;exports.List=nt;exports.ModulePlaceHolder=yl;exports.Pagination=Si;exports.PaginationContent=Ei;exports.PaginationEllipsis=Ti;exports.PaginationItem=Gn;exports.PaginationLink=ur;exports.PaginationNext=Ri;exports.PaginationPrevious=_i;exports.PasswordInput=M2;exports.Pill=v3;exports.PlatformEventListener=C1;exports.PlatformEvents=Ef;exports.PluralizeCounter=Pi;exports.PortalContainerProvider=O0;exports.RoomAvatars=Xb;exports.RoomsProvider=Vb;exports.SearchAutocomplete=Xu;exports.SearchInput=gi;exports.Select=ei;exports.Select2=$u;exports.Show=It;exports.Skeleton=Ro;exports.SkeletonList=td;exports.Spinner=nd;exports.StyleRegistry=ks;exports.Switch=rd;exports.Table=Wd;exports.Tabs=O2;exports.TabsContent=N2;exports.TabsList=j2;exports.TabsTrigger=I2;exports.TextArea=Fu;exports.TextWithTooltip=Yu;exports.ThemeToggle=Hd;exports.Tooltip=jn;exports.authorized=Tb;exports.dropdownListStyles=Wt;exports.extensionPoint=v1;exports.generateUserColor=Yd;exports.getApplications=Fs;exports.getInitials=Bf;exports.getOperations=Ec;exports.hasAccess=Rc;exports.initializeMicroFrontend=Bb;exports.isPlatformCustomizationCompleted=Ph;exports.isValidEmail=Ff;exports.logout=Mf;exports.navigateTo=kf;exports.platformHaveAnyCustomization=Th;exports.setupTestEnvironment=Ub;exports.useAppStatus=Ys;exports.useApplicationIcon=Dc;exports.useApplicationJSModule=co;exports.useApplicationMenu=zf;exports.useApplicationUIModule=Nc;exports.useApplications=jc;exports.useAuth=or;exports.useCatalog=Nn;exports.useCurrentApplication=Ws;exports.useCurrentApplicationName=Mc;exports.useCurrentJSModule=eh;exports.useDynamicFonts=Hc;exports.useDynamicStyleSheet=Wc;exports.useExtendExtensionPoint=Bc;exports.useExtensionPoint=Fc;exports.useFeatureFlag=Wb;exports.useFeatureFlags=ji;exports.useFileStorage=m1;exports.useGetPlatformTheme=Rh;exports.useHasNoSession=Nf;exports.useLocation=wc;exports.useModule=Bs;exports.useModuleCommonPaths=Lf;exports.useModuleConfig=Tc;exports.useModuleConfigByName=Pc;exports.useModuleMenu=Lc;exports.useModuleMetadata=rr;exports.useMutableCatalog=Af;exports.useNotifications=qs;exports.useOperations=_c;exports.usePAECustomizationsLoadingState=_h;exports.usePAEState=In;exports.usePlatformCustomization=Eh;exports.usePlatformEventListener=Uc;exports.usePortalContainer=mi;exports.useResource=Zp;exports.useResourceActions=dl;exports.useRoom=qb;exports.useServiceBaseURL=Hs;exports.useServiceInvoker=Vs;exports.useServiceWebSocketURL=kc;exports.useTenants=u1;exports.useTheme=xl;exports.useTrackEvent=ih;exports.useTrackEvents=$c;exports.useUIApplications=Ic;exports.useUserState=f1;
|