@kosdev-code/base-ui-components 0.1.0-dev.5625 → 0.1.0-dev.5633

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/index.cjs CHANGED
@@ -1,4 +1,4 @@
1
- "use strict";var Fa=Object.defineProperty;var Aa=(e,t,o)=>t in e?Fa(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o;var T=(e,t,o)=>(Aa(e,typeof t!="symbol"?t+"":t,o),o);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("@emotion/react/jsx-runtime"),d=require("react"),g=require("@emotion/styled"),z=require("@emotion/react"),Vr=require("react-dom"),O=require("@floating-ui/react"),La=require("@use-gesture/react"),q=require("react-hook-form"),W=require("@kosdev-code/kos-ui-sdk"),St=require("mobx-react-lite"),_=require("mobx"),ke=require("@tanstack/react-table"),Y=require("date-fns");function Ba(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const o in e)if(o!=="default"){const n=Object.getOwnPropertyDescriptor(e,o);Object.defineProperty(t,o,n.get?n:{enumerable:!0,get:()=>e[o]})}}return t.default=e,Object.freeze(t)}const co=Ba(d),Wa=e=>{const t=/[\\^$.*+?()[\]{}|]/g;return RegExp(t.source).test(e)?e.replace(t,"\\$&"):e},Pa=e=>e instanceof RegExp,Va=e=>typeof e=="string",Ha=e=>{let t=[];return e.forEach(o=>{Array.isArray(o)?t=t.concat(o):o&&t.push(o)}),t},Ua=(e,t,o)=>{if(e===""||t==="")return e;let n=t;Pa(n)||(n=new RegExp("("+Wa(n)+")","gi"));const r=e.split(n);for(let s=1,l=r.length;s<l;s+=2){if(r[s]===void 0||r[s-1]===void 0){console.warn("Encountered undefined value during string replacement. Your RegExp may not be working the way you expect.");continue}r[s]=o(r[s],s)}return r},Hr=(e,t,o)=>{let n=e;return Array.isArray(n)||(n=[n]),Ha(n.map(r=>Va(r)?Ua(r,t,o):r))},jt=(e,t)=>t?e:`var(${e})`,F=(e,t)=>jt(`--studio-g-${e}`,t),c=(e,t)=>jt(`--studio-s-${e}`,t),Ga={"actionable-blurb":{"row-gap":c("spacing-4"),"icon-column-width":c("spacing-20")}},Ka={"app-shell":{"bg-default":c("color-grey80"),"bg-offline":c("color-grey70"),"bg-locked":c("color-grey60"),color:c("color-white")}},Ya={"artifact-drawer":{"background-color":c("color-grey10"),"border-color":c("color-grey20"),"border-width":c("border-sm"),"padding-x":c("spacing-16"),"branch-padding-x":c("spacing-8"),"artifact-list-y-padding":c("spacing-10"),"artifact-items-gap":c("spacing-10"),"version-items-gap":c("spacing-8"),"version-list-padding":c("spacing-8")}},qa={checkbox:{"background-color":c("color-white"),"border-color":c("color-grey30"),"background-color-disabled":c("color-grey15"),"background-color-checked":c("color-primary"),"border-color-checked":c("color-primary"),"background-color-checked-disabled":c("color-additional3"),"border-color-checked-disabled":c("color-additional3"),size:"14px","border-radius":c("spacing-2"),"border-width":c("border-sm")}},Za={"collapsible-artifact":{"background-color":c("color-white"),"border-color":c("color-grey20"),"border-radius":c("spacing-6"),"border-width":c("border-xsm"),"button-left-or-right":c("spacing-4"),"button-top":"3px","name-and-desc-spacing":c("spacing-2"),"name-and-selected-spacing":c("spacing-8"),padding:`${c("spacing-6")} ${c("spacing-8")}`},"collapsible-artifact-version":{"background-color-hover":c("color-grey20"),"background-color-inherited":"#9747FF12","background-color-selected":c("color-additional3"),"background-color":c("color-grey10"),"border-color-hover":c("color-grey30"),"border-color-inherited":"#9747FF33","border-color-selected":c("color-primary"),"border-color":c("color-grey20"),"border-radius":c("spacing-2"),"border-width":c("border-sm"),padding:`${c("spacing-6")} ${c("spacing-8")}`}},Xa={"collapsible-list-container":{"border-radius":c("spacing-2"),"border-width":"0.5px","border-color":c("color-grey20")},"collapsible-list-header-container":{"background-color":c("color-grey10"),gap:c("spacing-8"),padding:"7px 8px"},"collapsible-list-toggled-container":{"background-color":c("color-white"),gap:c("spacing-8"),padding:c("spacing-8")}},Ja={drawer:{"header-height":c("spacing-30"),"header-bg":c("color-grey10"),"header-border-size":"1px","header-border-color":c("color-grey20"),"header-x-padding":c("spacing-10"),"border-width":"1px","border-color":c("color-grey20"),"left-drop-shadow":"4px 0px 8px -1px rgba(0,0,0,0.2)","right-drop-shadow":"-4px 0px 8px -1px rgba(0,0,0,0.2)"}},Qa={form:{"access-toggle-gap":c("spacing-16"),"access-toggle-height":c("spacing-36"),"error-message-top-margin":c("spacing-4"),"label-column-gap":c("spacing-16"),"label-error-color":c("color-red"),"label-font-family":c("font-family-default"),"label-font-size":c("font-size-med"),"label-font-weight":c("font-weight-normal"),"label-height":"14px","label-line-height":c("line-height-default"),"label-star-padding":c("spacing-4"),"label-width":"112px","label-area-padding":`${c("spacing-7")} 0`}},el={"horizontal-rule":{"border-width":"0.5px","border-color":c("color-grey20")}},tl={"icon-button":{padding:"0","border-radius":c("spacing-2"),"background-color":"transparent","border-color":"transparent",cursor:"pointer","disabled-cursor":"not-allowed","badge-fill-black":c("color-black"),"badge-fill-blue":c("color-primary"),"badge-fill-green":c("color-green"),"badge-fill-grey":c("color-grey50"),"badge-fill-orange":c("color-orange"),"badge-fill-purple":c("color-purple"),"badge-fill-red":c("color-red"),"badge-fill-white":c("color-white"),"badge-fill-yellow":c("color-yellow"),"badge-right":"1px","badge-top":"1px","active-background-color":"rgba(255, 255, 255, 0.1)"}},ol={icon:{"fill-black":c("color-black"),"fill-blue":c("color-primary"),"fill-green":c("color-green"),"fill-grey":c("color-grey50"),"fill-orange":c("color-orange"),"fill-purple":c("color-purple"),"fill-red":c("color-red"),"fill-white":c("color-white"),"fill-yellow":c("color-yellow"),"size-lrg":c("spacing-18"),"size-med":c("spacing-16"),"size-sm":c("spacing-14"),"size-xlrg":c("spacing-20"),"size-xsm":c("spacing-12"),"size-xxlrg":c("spacing-22"),"size-xxxlrg":c("spacing-32"),"size-xxsm":c("spacing-10")}},nl={"image-config-page-header":{gap:c("spacing-16"),"padding-bottom":c("spacing-12"),"title-gap":c("spacing-8"),bg:c("color-white")}},rl={input:{"background-color-disabled":c("color-grey10"),"background-color":c("color-white"),"border-color-active":c("color-black"),"border-color-invalid":c("color-red"),"border-color":c("color-grey30"),"border-radius":c("spacing-2"),"border-width":c("border-sm"),"color-disabled":c("color-grey30"),"font-family":c("font-family-default"),"font-size-small":c("font-size-sm"),"font-size":c("font-size-med"),"font-weight":c("font-weight-normal"),"icon-left":c("spacing-8"),"line-height":c("line-height-default"),"padding-left-icon":c("spacing-28"),"padding-right-icon":c("spacing-28"),"padding-x":c("spacing-8"),"padding-y-small":"2px","padding-y":c("spacing-7"),color:c("color-black"),height:"28px"}},sl={link:{"font-size-med":c("font-size-med"),"font-size-sm":c("font-size-sm"),"font-size-lrg":c("font-size-lrg"),"font-size-xlrg":c("font-size-xlrg"),"font-family":c("font-family-default"),"font-weight":c("font-weight-bold"),"line-height":c("line-height-default"),color:c("color-primary"),"color-hover":c("color-additional1"),"color-active":c("color-additional2"),"color-disabled":c("color-grey30")}},il={modal:{"overlay-background":"rgba(0, 0, 0, 0.8)","background-color":c("color-white"),headerPadding:c("spacing-10"),headerGap:c("spacing-8"),contentYPadding:c("spacing-10"),contentXPadding:c("spacing-12"),footerYPadding:c("spacing-10"),footerXPadding:c("spacing-12"),footerGap:c("spacing-8"),"border-width":c("border-sm"),"border-color":c("color-grey20"),"base-content-width":"400xp"}},al={"named-section":{"border-radius":"2px","border-width":"0.5px","selected-border-width":"2px","hover-border-width":c("border-sm"),"border-color":c("color-grey20"),"selected-border-color":c("color-primary")},"named-section-header":{bg:c("color-grey10"),"border-width":"0.5px","border-color":c("color-grey20"),"border-radius":"2px",padding:"8px 10px",gap:c("spacing-8"),"row-gap":c("spacing-4")}},ll={segmented:{"border-width":c("border-sm"),"border-radius":c("spacing-2"),padding:c("spacing-2"),"background-color":c("color-grey15"),"border-color":c("color-grey20"),"button-color":c("color-grey60"),"button-color-disabled":c("color-grey40"),"button-background-color":c("color-grey15"),"button-background-color-hover":c("color-grey20"),"button-background-color-active":c("color-grey40"),"button-padding-y":"5px","button-padding-x":"11px","button-border-width":c("border-sm"),"button-border-color":"transparent","button-font-size":c("font-size-med"),"button-font-weight":c("font-weight-normal"),"button-font-family":c("font-family-default"),"button-gap":c("spacing-4"),"indicator-background-color":c("color-white"),"indicator-color":c("color-black")}},cl={select:{"font-size":c("font-size-med"),"border-size":c("border-sm"),"border-color":c("color-grey20")},option:{"column-gap":c("spacing-8"),"font-family":c("font-family-default"),"font-size":c("font-size-med"),"bg-color-active":c("color-grey20"),"bg-color":c("color-white"),"font-weight-selected":c("font-weight-bold"),color:c("color-black"),"color-disabled":c("color-grey40"),padding:"2px 4px"}},dl={button:{xpadding:c("spacing-16"),ypadding:c("spacing-6"),br:c("spacing-2"),cursor:"pointer","line-height":c("line-height-default"),"font-size":c("font-size-med"),"ypadding-small":c("spacing-2"),"border-width":"1px","font-weight":c("font-weight-bold"),"icon-margin":`0px ${c("spacing-4")} 0px 0px`,"flex-direction":"row",bg:c("color-primary"),"bg-hover":c("color-additional1"),"bg-active":c("color-additional2"),"bg-disabled":c("color-grey30"),border:c("color-primary"),"border-hover":c("color-additional1"),"border-active":c("color-additional2"),"border-disabled":c("color-grey30"),color:c("color-white"),"color-hover":c("color-white"),"color-active":c("color-white"),"color-disabled":c("color-white"),"bg-secondary":c("color-white"),"bg-hover-secondary":c("color-white"),"bg-active-secondary":c("color-white"),"bg-disabled-secondary":c("color-grey10"),"border-secondary":c("color-primary"),"border-hover-secondary":c("color-additional1"),"border-active-secondary":c("color-additional2"),"border-disabled-secondary":c("color-grey30"),"color-secondary":c("color-primary"),"color-hover-secondary":c("color-additional1"),"color-active-secondary":c("color-additional2"),"color-disabled-secondary":c("color-grey30"),"bg-borderless":c("color-white"),"bg-hover-borderless":c("color-white"),"bg-active-borderless":c("color-white"),"bg-disabled-borderless":c("color-white"),"border-borderless":c("color-white"),"border-hover-borderless":c("color-white"),"border-active-borderless":c("color-white"),"border-disabled-borderless":c("color-white"),"color-borderless":c("color-primary"),"color-hover-borderless":c("color-additional1"),"color-active-borderless":c("color-additional2"),"color-disabled-borderless":c("color-grey30")}},ul={label:{gap:c("spacing-4")},"label-with-action":{gap:c("spacing-8")},"label-with-content-link":{color:c("color-primary")}},pl={text:{"font-family":c("font-family-default"),"line-height":c("line-height-default"),"h1-size":c("font-size-xlrg"),"h2-size":c("font-size-lrg"),"body-size":c("font-size-med"),"small-size":c("font-size-sm"),"font-weight-bold":c("font-weight-bold"),"font-weight-normal":c("font-weight-normal"),"color-dark":c("color-black"),"color-light":c("color-white"),"color-green":c("color-green"),"color-purple":c("color-purple"),"color-red":c("color-red"),"color-blue":c("color-primary"),"color-grey":c("color-grey60"),"color-disabled":c("color-grey40"),"color-yellow":c("color-yellow"),"color-orange":c("color-orange")}},hl={tab:{"trigger-padding-y":c("spacing-8"),"trigger-padding-x":"0","column-gap":c("spacing-8"),"indicator-height":c("border-lrg"),"indicator-color":c("color-grey60"),"trigger-list-underline-color":c("color-grey20"),"trigger-list-underline-height":c("border-sm"),"standard-active-color":c("color-grey80"),"standard-active-bg":"transparent","standard-inactive-color":c("color-grey50"),"standard-inactive-bg":c("color-grey10"),"standard-separator-color":c("color-grey20"),"badge-min-width":"18px","badge-height":"18px","badge-padding":`0 ${c("spacing-4")}`,"badge-border-radius":"9px","badge-bg":c("color-primary"),"badge-color":c("color-white"),"badge-font-size":"11px","close-size":"18px","close-border-radius":c("spacing-4"),"close-hover-bg":c("color-grey20"),"close-color":c("color-grey50")}},fl={tag:{"font-family":c("font-family-default"),"bg-color-orange":c("color-orange"),"bg-color-light":c("color-white"),"bg-color-green":c("color-green"),"bg-color-red":c("color-red"),"bg-color-purple":c("color-purple"),"bg-color-blue":c("color-blue"),"bg-color-disabled":c("color-white"),"color-light":c("color-white"),"color-dark":c("color-black"),"color-disabled":c("color-grey40"),"border-radius":c("border-sm"),"border-color":c("color-grey20"),height:c("spacing-18"),padding:"0px 4px"}},gl={textarea:{padding:c("spacing-8"),"background-color":c("color-white"),"font-size":c("font-size-med"),"font-family":c("font-family-default"),"font-weight":c("font-weight-normal"),color:c("color-black"),"border-width":c("border-sm"),"border-color":c("color-grey30"),"min-height":"60px","border-color-active":c("color-black"),"border-radius":c("spacing-2"),"border-color-invalid":c("color-red"),"background-color-disabled":c("color-grey10"),"color-disabled":c("color-grey30")}},ml={"toggle-container":{gap:"4px"},"toggle-track":{"background-color-checked-disabled":c("color-additional3"),"background-color-checked-enabled":c("color-primary"),"background-color-unchecked-disabled":c("color-grey20"),"background-color-unchecked-enabled":c("color-grey50"),"border-radius":c("spacing-20"),"padding-horizontal":"3px","padding-vertical":"2px","transition-duration":"150ms"},"toggle-thumb":{"background-color-checked-enabled":c("color-white"),"background-color-checked-disabled":c("color-white"),"background-color-unchecked-enabled":c("color-white"),"background-color-unchecked-disabled":c("color-grey15"),"border-radius":"15px","box-shadow":"0px 1px 3px 0px rgba(16, 24, 40, 0.1), 0px 1px 2px -1px rgba(16, 24, 40, 0.1)",height:"8px",width:"8px","transition-duration":"150ms"}},bl={"version-list-container":{gap:c("spacing-16")},"version-list-header":{gap:c("spacing-8"),itemBorderBottom:c("color-grey20"),itemBgColor:c("color-grey10")}},xl={combobox:{"background-color-active":c("color-grey15"),"background-color-selected":c("color-additional3"),"background-color":c("color-white"),"border-radius":"4px","box-shadow":"0px 0px 4px 0px rgba(0, 0, 0, 0.25)","input-border-radius":"6px","option-column-gap":c("spacing-4"),"row-gap":c("spacing-6"),"selection-border-radius":"4px",height:"22px",padding:c("spacing-8")}},yl={"radio-button":{size:c("spacing-14"),"check-size":c("spacing-8"),"border-color":c("color-grey20"),"background-color":c("color-white"),"border-width":c("border-sm"),"border-radius":"50%","border-color-checked":c("color-primary"),"background-color-disabled":c("color-grey10")}},vl={"select-view-list":{"item-height":c("spacing-36"),"padding-left":c("spacing-16"),"padding-right":c("spacing-8"),"border-width":c("border-sm"),"border-color":c("color-grey20"),"background-color":c("color-white"),"background-color-viewing":c("color-grey15"),gap:c("spacing-4")}},kl={"shell-menu":{"padding-x":c("spacing-20"),"link-gap":c("spacing-12"),"section-gap":c("spacing-8"),"link-padding-y":c("spacing-2"),"link-padding-x":c("spacing-4")}},wl={"named-list-item":{"column-gap":c("spacing-6"),"row-gap":c("spacing-4"),"color-selected":c("color-white"),"background-color-selected":c("color-primary"),"padding-y":c("spacing-4"),"padding-right":c("spacing-12"),"padding-left":c("spacing-20"),"subtext-padding-with-icon":c("spacing-20")}},Cl={"error-list-item":{"row-gap":c("spacing-4"),"icon-column-width":c("spacing-26"),"padding-x":c("spacing-4"),"padding-y":c("spacing-12"),"background-color":c("color-white"),"background-color-overview":c("color-grey10"),"background-color-hover":c("color-grey10"),"background-color-overview-hover":c("color-white"),"border-color":c("color-grey20"),"border-radius":c("spacing-2")}},$l={"ingredient-card":{border:c("border-sm"),"border-color":c("color-grey20"),"border-color-selected":c("color-primary"),padding:c("spacing-12"),"padding-small":c("spacing-8"),"border-radius":c("spacing-2"),"row-gap":c("spacing-4"),"column-gap":c("spacing-4")}},Sl={"branded-header":{"startColor-settings":"#048FEC","startColor-devices":"#9747FF","startColor-tools":"#01528A","startColor-performance":"#B4DEFA","endColor-viewBrowse":"#1C00D8","endColor-configure":"#4CC9F0","endColor-manage":"#9A99F2","endColor-troubleshoot":"#53D7C7","endColor-store":"#193C60","endColor-main":"#048FEC","border-bottom-size":c("border-sm"),"border-bottom-color":c("color-grey20"),"background-color":c("color-white"),"column-gap":c("spacing-16"),padding:"12px 20px","badge-size":"52px","badge-radius":"0","line-height":c("spacing-6"),"info-column-gap":c("spacing-10"),"text-wrapper-gap":c("spacing-4")}},jl={"artifact-store-settings":{"row-columns-published":"minmax(96px, 1fr) 64px minmax(244px, 2fr) 96px 60px","row-columns-market":"minmax(96px, 1fr) 64px minmax(244px, 2fr)","row-divider-color":c("color-grey20"),"row-gap":c("spacing-4"),"header-padding":"0px 8px 0px 4px","cell-padding":"12px 8px 12px 4px","name-column-gap":c("spacing-4")}},Il={table:{"row-border-bottom-size":c("border-xsm"),"border-color":c("color-grey20"),"header-background-color-hover":c("color-grey20"),"header-background-color":c("color-grey15"),"cell-padding-x":c("spacing-4"),"cell-padding-y":"11px","cell-padding-right-sortable":c("spacing-8"),"cell-padding-left-first-in-row":c("spacing-8"),"head-gap-sortable":c("spacing-4"),"background-color":c("color-white"),"head-font-size":c("font-size-med"),"head-color":c("color-black"),"head-font-weight":c("font-weight-bold"),"cell-font-size":c("font-size-med"),"cell-color":c("color-black"),"cell-font-weight":c("font-weight-normal"),"font-family":c("font-family-default")}},Dl={"resizable-panels":{"border-color":c("color-grey20"),"border-color-hover":c("color-grey30"),"border-color-drag":c("color-grey40"),"handle-width":c("border-sm")}},_l={"file-picker":{"background-color":c("color-grey10"),"background-color-accent":c("color-white"),"selected-background":c("color-primary"),"header-x-padding":c("spacing-20"),"header-y-padding":c("spacing-12"),"header-border-size":c("border-sm"),"header-gap":c("spacing-8"),"header-border-color":c("color-grey20"),"footer-padding-x":c("spacing-12"),"footer-padding-y":c("spacing-10"),"footer-controls-gap":c("spacing-4"),"footer-border-size":c("border-xsm"),"footer-border-color":c("color-grey20"),"search-bar-height":c("spacing-36"),"search-bar-border-size":c("border-sm"),"search-bar-border-color":c("color-grey30"),"search-bar-nav-buttons-gap":c("spacing-12"),"search-bar-padding-x":c("spacing-20"),"search-bar-padding-y":"6.5px","search-bar-radius":c("spacing-2"),"search-bar-edit-button-width":c("spacing-22"),"search-bar-breadcrumb-padding-x":c("spacing-4"),"search-bar-breadcrumb-hover-border":c("color-grey50"),"search-bar-export-button-radius":c("spacing-2"),"search-bar-export-button-background":c("color-primary"),"search-bar-export-button-background-disabled":c("color-grey30"),"nav-panel-y-padding":c("spacing-20"),"nav-panel-x-padding":c("spacing-20"),"nav-panel-gap":c("spacing-40"),"nav-panel-header-bottom-margin":c("spacing-4"),"nav-panel-section-gap":c("spacing-4"),"nav-panel-item-gap":c("spacing-4"),"nav-panel-item-y-padding":c("spacing-2"),"explorer-panel-right-gutter-size":c("spacing-12"),"explorer-panel-padding-y":c("spacing-4"),"explorer-panel-padding-x":c("spacing-10"),"explorer-panel-gap":c("spacing-4"),"explorer-panel-item-padding-x":c("spacing-4"),"explorer-panel-item-padding-y":c("spacing-2"),"explorer-panel-item-icon-gap-left":c("spacing-4"),"explorer-panel-item-icon-gap-right":c("spacing-4"),"explorer-panel-kab-background":c("color-grey10"),"preview-details-gap":c("spacing-10"),"preview-details-gap-small":c("spacing-8"),"preview-icon-size":c("spacing-40"),"preview-icon-y-padding":c("spacing-40"),"preview-icon-y-padding-small":c("spacing-12"),"preview-details-x-padding":c("spacing-20"),"preview-details-x-padding-small":c("spacing-8"),"preview-details-y-padding":c("spacing-10"),"preview-details-item-gap":c("spacing-8"),"preview-details-collapsible-bg":c("color-grey10"),"preview-details-collapsible-gap":c("spacing-4"),"preview-details-collapsible-y-padding":c("spacing-4"),"preview-details-collapsible-border-color":c("color-grey20")}},Tl={"shell-icon-button":{padding:"5px"}},El={"multi-select":{"list-padding":c("spacing-4"),"padding-x":c("spacing-12"),"padding-y":c("spacing-4"),"border-radius":c("spacing-6"),border:c("border-sm"),"border-color":c("color-grey20"),"select-all-border-color":c("color-grey10"),"hover-border-color":c("color-grey40"),gap:c("spacing-4"),background:c("color-white"),"item-padding-x":c("spacing-12"),"item-padding-y":c("spacing-4"),"item-gap":c("spacing-8"),"item-hover-bg":c("color-grey10"),"selected-item-padding-y":c("spacing-2"),"selected-item-padding-x":c("spacing-4"),"selected-item-gap":c("spacing-4"),"selected-item-background":c("color-grey10"),"selected-item-background-hover":c("color-grey20"),"selected-item-radius":c("spacing-4")}},zl={badge:{"color-blue":c("color-blue"),"color-blue-border":"rgba(4, 143, 236, 0.5)","color-red":c("color-red"),"color-red-border":"rgba(244, 0, 0, 0.5)","color-white":c("color-white"),"color-white-border":"rgba(255, 255, 255, 0.5)","color-black":c("color-black"),"color-black-border":"rgba(0, 0, 0, 0.5)","color-orange":c("color-orange"),"color-orange-border":"rgba(255, 133, 0, 0.5)","color-green":c("color-green"),"color-green-border":"rgba(82, 196, 26, 0.5)"}},Ml={"button-group":{gap:c("spacing-2"),"background-color":"transparent","border-radius":c("spacing-4"),"border-width":"0","border-color":"transparent",padding:"0","item-padding":c("spacing-4"),"item-border-radius":c("spacing-4"),"item-background-color":"transparent","item-background-color-hover":"rgba(0, 0, 0, 0.08)","item-background-color-active":"rgba(0, 0, 0, 0.15)","item-color":c("color-grey50"),"item-color-active":c("color-black")}},Ol={"named-collapsible-branch":{"column-gap":c("spacing-6"),"row-gap":c("spacing-4"),"color-selected":c("color-white"),"background-color-selected":c("color-primary"),"padding-y":c("spacing-4"),"padding-right":c("spacing-12"),"padding-left":c("spacing-12"),"subtext-padding-with-icon":c("spacing-12")}},Rl={notification:{"bg-success":c("color-white"),"bg-error":c("color-white"),"bg-warning":c("color-white"),"bg-info":c("color-white"),"border-success":c("color-green"),"border-error":c("color-red"),"border-warning":c("color-orange"),"border-info":c("color-blue"),"icon-success":c("color-green"),"icon-error":c("color-red"),"icon-warning":c("color-orange"),"icon-info":c("color-blue"),"border-outer":c("color-grey20"),"border-outer-dark":c("color-grey70"),"color-title":c("color-black"),"color-message":c("color-grey60"),"color-close":c("color-grey50"),"color-action":c("color-blue"),"bg-action-hover":c("color-grey10"),"bg-close-hover":c("color-grey10"),"bg-success-dark":c("color-grey80"),"bg-error-dark":c("color-grey80"),"bg-warning-dark":c("color-grey80"),"bg-info-dark":c("color-grey80"),"bg-action-hover-dark":c("color-grey70"),"bg-close-hover-dark":c("color-grey70"),"color-title-dark":c("color-grey10"),"color-message-dark":c("color-grey40")}},Nl={"studio-list-item":{"column-gap":c("spacing-6"),"row-gap":c("spacing-4"),"color-selected":c("color-white"),"background-color-selected":c("color-primary"),"padding-y":c("spacing-4"),"padding-right":c("spacing-12"),"padding-left":c("spacing-12"),"subtext-padding-with-icon":c("spacing-12")}},Fl={view:{"background-color":c("color-white"),"border-color":c("color-grey20"),"border-width":"1px","border-radius":c("spacing-4"),"content-padding":"0"},"view-header":{"background-color":c("color-grey10"),"border-color":c("color-grey20"),"border-bottom-width":"1px",padding:`${c("spacing-8")} ${c("spacing-12")}`,gap:c("spacing-8"),"left-gap":c("spacing-8"),"text-gap":c("spacing-2"),"actions-gap":c("spacing-4"),"content-min-height":"22px","subtitle-font-size":c("font-size-sm")}},Al={"view-container":{"vertical-gap":"0","horizontal-gap":c("spacing-16"),padding:"0","background-color":"transparent"}},Ll={...Ga,...Ka,...Ya,...qa,...Za,...Xa,...Ja,...Qa,...el,...tl,...ol,...nl,...rl,...sl,...il,...al,...ll,...cl,...dl,...ul,...pl,...hl,...fl,...gl,...ml,...bl,...xl,...yl,...zl,...Ml,...vl,...kl,...wl,...Cl,...$l,...Sl,...jl,...Il,...Dl,..._l,...Tl,...El,...Ol,...Rl,...Nl,...Fl,...Al},Bl={color:{grey0:"#FFFFFF",grey10:"#F6F6F6",grey15:"#F1F1F1",grey20:"#DFDFDF",grey30:"#D9D9D9",grey40:"#C4C4C4",grey50:"#ABABAB",grey60:"#868686",grey65:"#676767",grey70:"#484848",grey80:"#2F2F2F",grey100:"#262626",blue0:"#E6F7FF",blue10:"#C8E8FF",blue20:"#40A9FF",blue30:"#048FEC",blue40:"#096DD9",green0:"#52C41A",red0:"#F40000",orange0:"#FF8500",purple0:"#9747FF",yellow0:"#fffd87",yellow1:"#FFD600"}},Wl={"font-size":{"10px":"10px","12px":"12px","14px":"14px","16px":"16px"},"font-weight":{400:"400",700:"700"},"font-family":{Arial:"Arial, sans-serif"},"line-height":{120:"1.2"}},Pl={spacing:{"0-5px":"0.5px","1px":"1px","2px":"2px","3px":"3px","4px":"4px","6px":"6px","7px":"7px","8px":"8px","10px":"10px","12px":"12px","14px":"14px","16px":"16px","18px":"18px","20px":"20px","22px":"22px","24px":"24px","26px":"26px","28px":"28px","30px":"30px","32px":"32px","34px":"34px","36px":"36px","40px":"40px"}},Vl={...Bl,...Wl,...Pl},Hl={color:{white:F("color-grey0"),grey10:F("color-grey10"),grey15:F("color-grey15"),grey20:F("color-grey20"),grey30:F("color-grey30"),grey40:F("color-grey40"),grey50:F("color-grey50"),grey60:F("color-grey60"),grey65:F("color-grey65"),grey70:F("color-grey70"),grey80:F("color-grey80"),black:F("color-grey100"),primary:F("color-blue30"),primaryLight:F("color-blue0"),additional1:F("color-blue20"),additional2:F("color-blue40"),additional3:F("color-blue10"),green:F("color-green0"),orange:F("color-orange0"),red:F("color-red0"),purple:F("color-purple0"),blue:F("color-blue30"),yellow:F("color-yellow0")}},Ul={"font-size":{sm:F("font-size-10px"),med:F("font-size-12px"),lrg:F("font-size-14px"),xlrg:F("font-size-16px")},"font-weight":{normal:F("font-weight-400"),bold:F("font-weight-700")},"font-family":{default:F("font-family-Arial")},"line-height":{default:F("line-height-120")}},Gl={spacing:{2:F("spacing-2px"),4:F("spacing-4px"),6:F("spacing-6px"),7:F("spacing-7px"),8:F("spacing-8px"),10:F("spacing-10px"),12:F("spacing-12px"),14:F("spacing-14px"),16:F("spacing-16px"),18:F("spacing-18px"),20:F("spacing-20px"),22:F("spacing-22px"),24:F("spacing-24px"),26:F("spacing-26px"),28:F("spacing-28px"),30:F("spacing-30px"),32:F("spacing-32px"),34:F("spacing-34px"),36:F("spacing-36px"),40:F("spacing-40px")},border:{xsm:F("spacing-0-5px"),sm:F("spacing-1px"),med:F("spacing-2px"),lrg:F("spacing-3px")}},Kl={...Hl,...Ul,...Gl},un=(e,t="studio-c")=>Object.keys(e).flatMap(o=>Object.keys(e[o]).map(n=>`--${t}-${o}-${n}: ${e[o][n]}`)),Yl=(e,t={})=>{const{prefix:o="studio-c",cssRootSelector:n=":root"}=t,r=l=>l.map(a=>(u,p)=>jt(`--${o}-${String(a)}-${u}`,p)),s=z.css`
1
+ "use strict";var Fa=Object.defineProperty;var Aa=(e,t,o)=>t in e?Fa(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o;var T=(e,t,o)=>(Aa(e,typeof t!="symbol"?t+"":t,o),o);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("@emotion/react/jsx-runtime"),d=require("react"),g=require("@emotion/styled"),z=require("@emotion/react"),Vr=require("react-dom"),O=require("@floating-ui/react"),La=require("@use-gesture/react"),G=require("react-hook-form"),W=require("@kosdev-code/kos-ui-sdk"),St=require("mobx-react-lite"),_=require("mobx"),we=require("@tanstack/react-table"),q=require("date-fns");function Ba(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const o in e)if(o!=="default"){const n=Object.getOwnPropertyDescriptor(e,o);Object.defineProperty(t,o,n.get?n:{enumerable:!0,get:()=>e[o]})}}return t.default=e,Object.freeze(t)}const co=Ba(d),Wa=e=>{const t=/[\\^$.*+?()[\]{}|]/g;return RegExp(t.source).test(e)?e.replace(t,"\\$&"):e},Pa=e=>e instanceof RegExp,Va=e=>typeof e=="string",Ha=e=>{let t=[];return e.forEach(o=>{Array.isArray(o)?t=t.concat(o):o&&t.push(o)}),t},Ua=(e,t,o)=>{if(e===""||t==="")return e;let n=t;Pa(n)||(n=new RegExp("("+Wa(n)+")","gi"));const r=e.split(n);for(let s=1,l=r.length;s<l;s+=2){if(r[s]===void 0||r[s-1]===void 0){console.warn("Encountered undefined value during string replacement. Your RegExp may not be working the way you expect.");continue}r[s]=o(r[s],s)}return r},Hr=(e,t,o)=>{let n=e;return Array.isArray(n)||(n=[n]),Ha(n.map(r=>Va(r)?Ua(r,t,o):r))},jt=(e,t)=>t?e:`var(${e})`,F=(e,t)=>jt(`--studio-g-${e}`,t),c=(e,t)=>jt(`--studio-s-${e}`,t),Ga={"actionable-blurb":{"row-gap":c("spacing-4"),"icon-column-width":c("spacing-20")}},Ka={"app-shell":{"bg-default":c("color-grey80"),"bg-offline":c("color-grey70"),"bg-locked":c("color-grey60"),color:c("color-white")}},Ya={"artifact-drawer":{"background-color":c("color-grey10"),"border-color":c("color-grey20"),"border-width":c("border-sm"),"padding-x":c("spacing-16"),"branch-padding-x":c("spacing-8"),"artifact-list-y-padding":c("spacing-10"),"artifact-items-gap":c("spacing-10"),"version-items-gap":c("spacing-8"),"version-list-padding":c("spacing-8")}},qa={checkbox:{"background-color":c("color-white"),"border-color":c("color-grey30"),"background-color-disabled":c("color-grey15"),"background-color-checked":c("color-primary"),"border-color-checked":c("color-primary"),"background-color-checked-disabled":c("color-additional3"),"border-color-checked-disabled":c("color-additional3"),size:"14px","border-radius":c("spacing-2"),"border-width":c("border-sm")}},Za={"collapsible-artifact":{"background-color":c("color-white"),"border-color":c("color-grey20"),"border-radius":c("spacing-6"),"border-width":c("border-xsm"),"button-left-or-right":c("spacing-4"),"button-top":"3px","name-and-desc-spacing":c("spacing-2"),"name-and-selected-spacing":c("spacing-8"),padding:`${c("spacing-6")} ${c("spacing-8")}`},"collapsible-artifact-version":{"background-color-hover":c("color-grey20"),"background-color-inherited":"#9747FF12","background-color-selected":c("color-additional3"),"background-color":c("color-grey10"),"border-color-hover":c("color-grey30"),"border-color-inherited":"#9747FF33","border-color-selected":c("color-primary"),"border-color":c("color-grey20"),"border-radius":c("spacing-2"),"border-width":c("border-sm"),padding:`${c("spacing-6")} ${c("spacing-8")}`}},Xa={"collapsible-list-container":{"border-radius":c("spacing-2"),"border-width":"0.5px","border-color":c("color-grey20")},"collapsible-list-header-container":{"background-color":c("color-grey10"),gap:c("spacing-8"),padding:"7px 8px"},"collapsible-list-toggled-container":{"background-color":c("color-white"),gap:c("spacing-8"),padding:c("spacing-8")}},Ja={drawer:{"header-height":c("spacing-30"),"header-bg":c("color-grey10"),"header-border-size":"1px","header-border-color":c("color-grey20"),"header-x-padding":c("spacing-10"),"border-width":"1px","border-color":c("color-grey20"),"left-drop-shadow":"4px 0px 8px -1px rgba(0,0,0,0.2)","right-drop-shadow":"-4px 0px 8px -1px rgba(0,0,0,0.2)"}},Qa={form:{"access-toggle-gap":c("spacing-16"),"access-toggle-height":c("spacing-36"),"error-message-top-margin":c("spacing-4"),"label-column-gap":c("spacing-16"),"label-error-color":c("color-red"),"label-font-family":c("font-family-default"),"label-font-size":c("font-size-med"),"label-font-weight":c("font-weight-normal"),"label-height":"14px","label-line-height":c("line-height-default"),"label-star-padding":c("spacing-4"),"label-width":"112px","label-area-padding":`${c("spacing-7")} 0`}},el={"horizontal-rule":{"border-width":"0.5px","border-color":c("color-grey20")}},tl={"icon-button":{padding:"0","border-radius":c("spacing-2"),"background-color":"transparent","border-color":"transparent",cursor:"pointer","disabled-cursor":"not-allowed","badge-fill-black":c("color-black"),"badge-fill-blue":c("color-primary"),"badge-fill-green":c("color-green"),"badge-fill-grey":c("color-grey50"),"badge-fill-orange":c("color-orange"),"badge-fill-purple":c("color-purple"),"badge-fill-red":c("color-red"),"badge-fill-white":c("color-white"),"badge-fill-yellow":c("color-yellow"),"badge-right":"1px","badge-top":"1px","active-background-color":"rgba(255, 255, 255, 0.1)"}},ol={icon:{"fill-black":c("color-black"),"fill-blue":c("color-primary"),"fill-green":c("color-green"),"fill-grey":c("color-grey50"),"fill-orange":c("color-orange"),"fill-purple":c("color-purple"),"fill-red":c("color-red"),"fill-white":c("color-white"),"fill-yellow":c("color-yellow"),"size-lrg":c("spacing-18"),"size-med":c("spacing-16"),"size-sm":c("spacing-14"),"size-xlrg":c("spacing-20"),"size-xsm":c("spacing-12"),"size-xxlrg":c("spacing-22"),"size-xxxlrg":c("spacing-32"),"size-xxsm":c("spacing-10")}},nl={"image-config-page-header":{gap:c("spacing-16"),"padding-bottom":c("spacing-12"),"title-gap":c("spacing-8"),bg:c("color-white")}},rl={input:{"background-color-disabled":c("color-grey10"),"background-color":c("color-white"),"border-color-active":c("color-black"),"border-color-invalid":c("color-red"),"border-color":c("color-grey30"),"border-radius":c("spacing-2"),"border-width":c("border-sm"),"color-disabled":c("color-grey30"),"font-family":c("font-family-default"),"font-size-small":c("font-size-sm"),"font-size":c("font-size-med"),"font-weight":c("font-weight-normal"),"icon-left":c("spacing-8"),"line-height":c("line-height-default"),"padding-left-icon":c("spacing-28"),"padding-right-icon":c("spacing-28"),"padding-x":c("spacing-8"),"padding-y-small":"2px","padding-y":c("spacing-7"),color:c("color-black"),height:"28px"}},sl={link:{"font-size-med":c("font-size-med"),"font-size-sm":c("font-size-sm"),"font-size-lrg":c("font-size-lrg"),"font-size-xlrg":c("font-size-xlrg"),"font-family":c("font-family-default"),"font-weight":c("font-weight-bold"),"line-height":c("line-height-default"),color:c("color-primary"),"color-hover":c("color-additional1"),"color-active":c("color-additional2"),"color-disabled":c("color-grey30")}},il={modal:{"overlay-background":"rgba(0, 0, 0, 0.8)","background-color":c("color-white"),headerPadding:c("spacing-10"),headerGap:c("spacing-8"),contentYPadding:c("spacing-10"),contentXPadding:c("spacing-12"),footerYPadding:c("spacing-10"),footerXPadding:c("spacing-12"),footerGap:c("spacing-8"),"border-width":c("border-sm"),"border-color":c("color-grey20"),"base-content-width":"400xp"}},al={"named-section":{"border-radius":"2px","border-width":"0.5px","selected-border-width":"2px","hover-border-width":c("border-sm"),"border-color":c("color-grey20"),"selected-border-color":c("color-primary")},"named-section-header":{bg:c("color-grey10"),"border-width":"0.5px","border-color":c("color-grey20"),"border-radius":"2px",padding:"8px 10px",gap:c("spacing-8"),"row-gap":c("spacing-4")}},ll={segmented:{"border-width":c("border-sm"),"border-radius":c("spacing-2"),padding:c("spacing-2"),"background-color":c("color-grey15"),"border-color":c("color-grey20"),"button-color":c("color-grey60"),"button-color-disabled":c("color-grey40"),"button-background-color":c("color-grey15"),"button-background-color-hover":c("color-grey20"),"button-background-color-active":c("color-grey40"),"button-padding-y":"5px","button-padding-x":"11px","button-border-width":c("border-sm"),"button-border-color":"transparent","button-font-size":c("font-size-med"),"button-font-weight":c("font-weight-normal"),"button-font-family":c("font-family-default"),"button-gap":c("spacing-4"),"indicator-background-color":c("color-white"),"indicator-color":c("color-black")}},cl={select:{"font-size":c("font-size-med"),"border-size":c("border-sm"),"border-color":c("color-grey20")},option:{"column-gap":c("spacing-8"),"font-family":c("font-family-default"),"font-size":c("font-size-med"),"bg-color-active":c("color-grey20"),"bg-color":c("color-white"),"font-weight-selected":c("font-weight-bold"),color:c("color-black"),"color-disabled":c("color-grey40"),padding:"2px 4px"}},dl={button:{xpadding:c("spacing-16"),ypadding:c("spacing-6"),br:c("spacing-2"),cursor:"pointer","line-height":c("line-height-default"),"font-size":c("font-size-med"),"ypadding-small":c("spacing-2"),"border-width":"1px","font-weight":c("font-weight-bold"),"icon-margin":`0px ${c("spacing-4")} 0px 0px`,"flex-direction":"row",bg:c("color-primary"),"bg-hover":c("color-additional1"),"bg-active":c("color-additional2"),"bg-disabled":c("color-grey30"),border:c("color-primary"),"border-hover":c("color-additional1"),"border-active":c("color-additional2"),"border-disabled":c("color-grey30"),color:c("color-white"),"color-hover":c("color-white"),"color-active":c("color-white"),"color-disabled":c("color-white"),"bg-secondary":c("color-white"),"bg-hover-secondary":c("color-white"),"bg-active-secondary":c("color-white"),"bg-disabled-secondary":c("color-grey10"),"border-secondary":c("color-primary"),"border-hover-secondary":c("color-additional1"),"border-active-secondary":c("color-additional2"),"border-disabled-secondary":c("color-grey30"),"color-secondary":c("color-primary"),"color-hover-secondary":c("color-additional1"),"color-active-secondary":c("color-additional2"),"color-disabled-secondary":c("color-grey30"),"bg-borderless":c("color-white"),"bg-hover-borderless":c("color-white"),"bg-active-borderless":c("color-white"),"bg-disabled-borderless":c("color-white"),"border-borderless":c("color-white"),"border-hover-borderless":c("color-white"),"border-active-borderless":c("color-white"),"border-disabled-borderless":c("color-white"),"color-borderless":c("color-primary"),"color-hover-borderless":c("color-additional1"),"color-active-borderless":c("color-additional2"),"color-disabled-borderless":c("color-grey30")}},ul={label:{gap:c("spacing-4")},"label-with-action":{gap:c("spacing-8")},"label-with-content-link":{color:c("color-primary")}},hl={text:{"font-family":c("font-family-default"),"line-height":c("line-height-default"),"h1-size":c("font-size-xlrg"),"h2-size":c("font-size-lrg"),"body-size":c("font-size-med"),"small-size":c("font-size-sm"),"font-weight-bold":c("font-weight-bold"),"font-weight-normal":c("font-weight-normal"),"color-dark":c("color-black"),"color-light":c("color-white"),"color-green":c("color-green"),"color-purple":c("color-purple"),"color-red":c("color-red"),"color-blue":c("color-primary"),"color-grey":c("color-grey60"),"color-disabled":c("color-grey40"),"color-yellow":c("color-yellow"),"color-orange":c("color-orange")}},pl={tab:{"trigger-padding-y":c("spacing-8"),"trigger-padding-x":"0","column-gap":c("spacing-8"),"indicator-height":c("border-lrg"),"indicator-color":c("color-grey60"),"trigger-list-underline-color":c("color-grey20"),"trigger-list-underline-height":c("border-sm"),"standard-active-color":c("color-grey80"),"standard-active-bg":"transparent","standard-inactive-color":c("color-grey50"),"standard-inactive-bg":c("color-grey10"),"standard-separator-color":c("color-grey20"),"badge-min-width":"18px","badge-height":"18px","badge-padding":`0 ${c("spacing-4")}`,"badge-border-radius":"9px","badge-bg":c("color-primary"),"badge-color":c("color-white"),"badge-font-size":"11px","close-size":"18px","close-border-radius":c("spacing-4"),"close-hover-bg":c("color-grey20"),"close-color":c("color-grey50")}},fl={tag:{"font-family":c("font-family-default"),"bg-color-orange":c("color-orange"),"bg-color-light":c("color-white"),"bg-color-green":c("color-green"),"bg-color-red":c("color-red"),"bg-color-purple":c("color-purple"),"bg-color-blue":c("color-blue"),"bg-color-disabled":c("color-white"),"color-light":c("color-white"),"color-dark":c("color-black"),"color-disabled":c("color-grey40"),"border-radius":c("border-sm"),"border-color":c("color-grey20"),height:c("spacing-18"),padding:"0px 4px"}},gl={textarea:{padding:c("spacing-8"),"background-color":c("color-white"),"font-size":c("font-size-med"),"font-family":c("font-family-default"),"font-weight":c("font-weight-normal"),color:c("color-black"),"border-width":c("border-sm"),"border-color":c("color-grey30"),"min-height":"60px","border-color-active":c("color-black"),"border-radius":c("spacing-2"),"border-color-invalid":c("color-red"),"background-color-disabled":c("color-grey10"),"color-disabled":c("color-grey30")}},ml={"toggle-container":{gap:"4px"},"toggle-track":{"background-color-checked-disabled":c("color-additional3"),"background-color-checked-enabled":c("color-primary"),"background-color-unchecked-disabled":c("color-grey20"),"background-color-unchecked-enabled":c("color-grey50"),"border-radius":c("spacing-20"),"padding-horizontal":"3px","padding-vertical":"2px","transition-duration":"150ms"},"toggle-thumb":{"background-color-checked-enabled":c("color-white"),"background-color-checked-disabled":c("color-white"),"background-color-unchecked-enabled":c("color-white"),"background-color-unchecked-disabled":c("color-grey15"),"border-radius":"15px","box-shadow":"0px 1px 3px 0px rgba(16, 24, 40, 0.1), 0px 1px 2px -1px rgba(16, 24, 40, 0.1)",height:"8px",width:"8px","transition-duration":"150ms"}},bl={"version-list-container":{gap:c("spacing-16")},"version-list-header":{gap:c("spacing-8"),itemBorderBottom:c("color-grey20"),itemBgColor:c("color-grey10")}},xl={combobox:{"background-color-active":c("color-grey15"),"background-color-selected":c("color-additional3"),"background-color":c("color-white"),"border-radius":"4px","box-shadow":"0px 0px 4px 0px rgba(0, 0, 0, 0.25)","input-border-radius":"6px","option-column-gap":c("spacing-4"),"row-gap":c("spacing-6"),"selection-border-radius":"4px",height:"22px",padding:c("spacing-8")}},yl={"radio-button":{size:c("spacing-14"),"check-size":c("spacing-8"),"border-color":c("color-grey20"),"background-color":c("color-white"),"border-width":c("border-sm"),"border-radius":"50%","border-color-checked":c("color-primary"),"background-color-disabled":c("color-grey10")}},vl={"select-view-list":{"item-height":c("spacing-36"),"padding-left":c("spacing-16"),"padding-right":c("spacing-8"),"border-width":c("border-sm"),"border-color":c("color-grey20"),"background-color":c("color-white"),"background-color-viewing":c("color-grey15"),gap:c("spacing-4")}},kl={"shell-menu":{"padding-x":c("spacing-20"),"link-gap":c("spacing-12"),"section-gap":c("spacing-8"),"link-padding-y":c("spacing-2"),"link-padding-x":c("spacing-4")}},wl={"named-list-item":{"column-gap":c("spacing-6"),"row-gap":c("spacing-4"),"color-selected":c("color-white"),"background-color-selected":c("color-primary"),"padding-y":c("spacing-4"),"padding-right":c("spacing-12"),"padding-left":c("spacing-20"),"subtext-padding-with-icon":c("spacing-20")}},Cl={"error-list-item":{"row-gap":c("spacing-4"),"icon-column-width":c("spacing-26"),"padding-x":c("spacing-4"),"padding-y":c("spacing-12"),"background-color":c("color-white"),"background-color-overview":c("color-grey10"),"background-color-hover":c("color-grey10"),"background-color-overview-hover":c("color-white"),"border-color":c("color-grey20"),"border-radius":c("spacing-2")}},$l={"ingredient-card":{border:c("border-sm"),"border-color":c("color-grey20"),"border-color-selected":c("color-primary"),padding:c("spacing-12"),"padding-small":c("spacing-8"),"border-radius":c("spacing-2"),"row-gap":c("spacing-4"),"column-gap":c("spacing-4")}},Sl={"branded-header":{"startColor-settings":"#048FEC","startColor-devices":"#9747FF","startColor-tools":"#01528A","startColor-performance":"#B4DEFA","endColor-viewBrowse":"#1C00D8","endColor-configure":"#4CC9F0","endColor-manage":"#9A99F2","endColor-troubleshoot":"#53D7C7","endColor-store":"#193C60","endColor-main":"#048FEC","border-bottom-size":c("border-sm"),"border-bottom-color":c("color-grey20"),"background-color":c("color-white"),"column-gap":c("spacing-16"),padding:"12px 20px","badge-size":"52px","badge-radius":"0","line-height":c("spacing-6"),"info-column-gap":c("spacing-10"),"text-wrapper-gap":c("spacing-4")}},jl={"artifact-store-settings":{"row-columns-published":"minmax(96px, 1fr) 64px minmax(244px, 2fr) 96px 60px","row-columns-market":"minmax(96px, 1fr) 64px minmax(244px, 2fr)","row-divider-color":c("color-grey20"),"row-gap":c("spacing-4"),"header-padding":"0px 8px 0px 4px","cell-padding":"12px 8px 12px 4px","name-column-gap":c("spacing-4")}},Il={table:{"row-border-bottom-size":c("border-xsm"),"border-color":c("color-grey20"),"header-background-color-hover":c("color-grey20"),"header-background-color":c("color-grey15"),"cell-padding-x":c("spacing-4"),"cell-padding-y":"11px","cell-padding-right-sortable":c("spacing-8"),"cell-padding-left-first-in-row":c("spacing-8"),"head-gap-sortable":c("spacing-4"),"background-color":c("color-white"),"head-font-size":c("font-size-med"),"head-color":c("color-black"),"head-font-weight":c("font-weight-bold"),"cell-font-size":c("font-size-med"),"cell-color":c("color-black"),"cell-font-weight":c("font-weight-normal"),"font-family":c("font-family-default")}},Dl={"resizable-panels":{"border-color":c("color-grey20"),"border-color-hover":c("color-grey30"),"border-color-drag":c("color-grey40"),"handle-width":c("border-sm")}},_l={"file-picker":{"background-color":c("color-grey10"),"background-color-accent":c("color-white"),"selected-background":c("color-primary"),"header-x-padding":c("spacing-20"),"header-y-padding":c("spacing-12"),"header-border-size":c("border-sm"),"header-gap":c("spacing-8"),"header-border-color":c("color-grey20"),"footer-padding-x":c("spacing-12"),"footer-padding-y":c("spacing-10"),"footer-controls-gap":c("spacing-4"),"footer-border-size":c("border-xsm"),"footer-border-color":c("color-grey20"),"search-bar-height":c("spacing-36"),"search-bar-border-size":c("border-sm"),"search-bar-border-color":c("color-grey30"),"search-bar-nav-buttons-gap":c("spacing-12"),"search-bar-padding-x":c("spacing-20"),"search-bar-padding-y":"6.5px","search-bar-radius":c("spacing-2"),"search-bar-edit-button-width":c("spacing-22"),"search-bar-breadcrumb-padding-x":c("spacing-4"),"search-bar-breadcrumb-hover-border":c("color-grey50"),"search-bar-export-button-radius":c("spacing-2"),"search-bar-export-button-background":c("color-primary"),"search-bar-export-button-background-disabled":c("color-grey30"),"nav-panel-y-padding":c("spacing-20"),"nav-panel-x-padding":c("spacing-20"),"nav-panel-gap":c("spacing-40"),"nav-panel-header-bottom-margin":c("spacing-4"),"nav-panel-section-gap":c("spacing-4"),"nav-panel-item-gap":c("spacing-4"),"nav-panel-item-y-padding":c("spacing-2"),"explorer-panel-right-gutter-size":c("spacing-12"),"explorer-panel-padding-y":c("spacing-4"),"explorer-panel-padding-x":c("spacing-10"),"explorer-panel-gap":c("spacing-4"),"explorer-panel-item-padding-x":c("spacing-4"),"explorer-panel-item-padding-y":c("spacing-2"),"explorer-panel-item-icon-gap-left":c("spacing-4"),"explorer-panel-item-icon-gap-right":c("spacing-4"),"explorer-panel-kab-background":c("color-grey10"),"preview-details-gap":c("spacing-10"),"preview-details-gap-small":c("spacing-8"),"preview-icon-size":c("spacing-40"),"preview-icon-y-padding":c("spacing-40"),"preview-icon-y-padding-small":c("spacing-12"),"preview-details-x-padding":c("spacing-20"),"preview-details-x-padding-small":c("spacing-8"),"preview-details-y-padding":c("spacing-10"),"preview-details-item-gap":c("spacing-8"),"preview-details-collapsible-bg":c("color-grey10"),"preview-details-collapsible-gap":c("spacing-4"),"preview-details-collapsible-y-padding":c("spacing-4"),"preview-details-collapsible-border-color":c("color-grey20")}},Tl={"shell-icon-button":{padding:"5px"}},El={"multi-select":{"list-padding":c("spacing-4"),"padding-x":c("spacing-12"),"padding-y":c("spacing-4"),"border-radius":c("spacing-6"),border:c("border-sm"),"border-color":c("color-grey20"),"select-all-border-color":c("color-grey10"),"hover-border-color":c("color-grey40"),gap:c("spacing-4"),background:c("color-white"),"item-padding-x":c("spacing-12"),"item-padding-y":c("spacing-4"),"item-gap":c("spacing-8"),"item-hover-bg":c("color-grey10"),"selected-item-padding-y":c("spacing-2"),"selected-item-padding-x":c("spacing-4"),"selected-item-gap":c("spacing-4"),"selected-item-background":c("color-grey10"),"selected-item-background-hover":c("color-grey20"),"selected-item-radius":c("spacing-4")}},zl={badge:{"color-blue":c("color-blue"),"color-blue-border":"rgba(4, 143, 236, 0.5)","color-red":c("color-red"),"color-red-border":"rgba(244, 0, 0, 0.5)","color-white":c("color-white"),"color-white-border":"rgba(255, 255, 255, 0.5)","color-black":c("color-black"),"color-black-border":"rgba(0, 0, 0, 0.5)","color-orange":c("color-orange"),"color-orange-border":"rgba(255, 133, 0, 0.5)","color-green":c("color-green"),"color-green-border":"rgba(82, 196, 26, 0.5)"}},Ml={"button-group":{gap:c("spacing-2"),"background-color":"transparent","border-radius":c("spacing-4"),"border-width":"0","border-color":"transparent",padding:"0","item-padding":c("spacing-4"),"item-border-radius":c("spacing-4"),"item-background-color":"transparent","item-background-color-hover":"rgba(0, 0, 0, 0.08)","item-background-color-active":"rgba(0, 0, 0, 0.15)","item-color":c("color-grey50"),"item-color-active":c("color-black")}},Ol={"named-collapsible-branch":{"column-gap":c("spacing-6"),"row-gap":c("spacing-4"),"color-selected":c("color-white"),"background-color-selected":c("color-primary"),"padding-y":c("spacing-4"),"padding-right":c("spacing-12"),"padding-left":c("spacing-12"),"subtext-padding-with-icon":c("spacing-12")}},Rl={notification:{"bg-success":c("color-white"),"bg-error":c("color-white"),"bg-warning":c("color-white"),"bg-info":c("color-white"),"border-success":c("color-green"),"border-error":c("color-red"),"border-warning":c("color-orange"),"border-info":c("color-blue"),"icon-success":c("color-green"),"icon-error":c("color-red"),"icon-warning":c("color-orange"),"icon-info":c("color-blue"),"border-outer":c("color-grey20"),"border-outer-dark":c("color-grey70"),"color-title":c("color-black"),"color-message":c("color-grey60"),"color-close":c("color-grey50"),"color-action":c("color-blue"),"bg-action-hover":c("color-grey10"),"bg-close-hover":c("color-grey10"),"bg-success-dark":c("color-grey80"),"bg-error-dark":c("color-grey80"),"bg-warning-dark":c("color-grey80"),"bg-info-dark":c("color-grey80"),"bg-action-hover-dark":c("color-grey70"),"bg-close-hover-dark":c("color-grey70"),"color-title-dark":c("color-grey10"),"color-message-dark":c("color-grey40")}},Nl={"studio-list-item":{"column-gap":c("spacing-6"),"row-gap":c("spacing-4"),"color-selected":c("color-white"),"background-color-selected":c("color-primary"),"padding-y":c("spacing-4"),"padding-right":c("spacing-12"),"padding-left":c("spacing-12"),"subtext-padding-with-icon":c("spacing-12")}},Fl={view:{"background-color":c("color-white"),"border-color":c("color-grey20"),"border-width":"1px","border-radius":c("spacing-4"),"content-padding":"0"},"view-header":{"background-color":c("color-grey10"),"border-color":c("color-grey20"),"border-bottom-width":"1px",padding:`${c("spacing-8")} ${c("spacing-12")}`,gap:c("spacing-8"),"left-gap":c("spacing-8"),"text-gap":c("spacing-2"),"actions-gap":c("spacing-4"),"content-min-height":"22px","subtitle-font-size":c("font-size-sm")}},Al={"view-container":{"vertical-gap":"0","horizontal-gap":c("spacing-16"),padding:"0","background-color":"transparent"}},Ll={...Ga,...Ka,...Ya,...qa,...Za,...Xa,...Ja,...Qa,...el,...tl,...ol,...nl,...rl,...sl,...il,...al,...ll,...cl,...dl,...ul,...hl,...pl,...fl,...gl,...ml,...bl,...xl,...yl,...zl,...Ml,...vl,...kl,...wl,...Cl,...$l,...Sl,...jl,...Il,...Dl,..._l,...Tl,...El,...Ol,...Rl,...Nl,...Fl,...Al},Bl={color:{grey0:"#FFFFFF",grey10:"#F6F6F6",grey15:"#F1F1F1",grey20:"#DFDFDF",grey30:"#D9D9D9",grey40:"#C4C4C4",grey50:"#ABABAB",grey60:"#868686",grey65:"#676767",grey70:"#484848",grey80:"#2F2F2F",grey100:"#262626",blue0:"#E6F7FF",blue10:"#C8E8FF",blue20:"#40A9FF",blue30:"#048FEC",blue40:"#096DD9",green0:"#52C41A",red0:"#F40000",orange0:"#FF8500",purple0:"#9747FF",yellow0:"#fffd87",yellow1:"#FFD600"}},Wl={"font-size":{"10px":"10px","12px":"12px","14px":"14px","16px":"16px"},"font-weight":{400:"400",700:"700"},"font-family":{Arial:"Arial, sans-serif"},"line-height":{120:"1.2"}},Pl={spacing:{"0-5px":"0.5px","1px":"1px","2px":"2px","3px":"3px","4px":"4px","6px":"6px","7px":"7px","8px":"8px","10px":"10px","12px":"12px","14px":"14px","16px":"16px","18px":"18px","20px":"20px","22px":"22px","24px":"24px","26px":"26px","28px":"28px","30px":"30px","32px":"32px","34px":"34px","36px":"36px","40px":"40px"}},Vl={...Bl,...Wl,...Pl},Hl={color:{white:F("color-grey0"),grey10:F("color-grey10"),grey15:F("color-grey15"),grey20:F("color-grey20"),grey30:F("color-grey30"),grey40:F("color-grey40"),grey50:F("color-grey50"),grey60:F("color-grey60"),grey65:F("color-grey65"),grey70:F("color-grey70"),grey80:F("color-grey80"),black:F("color-grey100"),primary:F("color-blue30"),primaryLight:F("color-blue0"),additional1:F("color-blue20"),additional2:F("color-blue40"),additional3:F("color-blue10"),green:F("color-green0"),orange:F("color-orange0"),red:F("color-red0"),purple:F("color-purple0"),blue:F("color-blue30"),yellow:F("color-yellow0")}},Ul={"font-size":{sm:F("font-size-10px"),med:F("font-size-12px"),lrg:F("font-size-14px"),xlrg:F("font-size-16px")},"font-weight":{normal:F("font-weight-400"),bold:F("font-weight-700")},"font-family":{default:F("font-family-Arial")},"line-height":{default:F("line-height-120")}},Gl={spacing:{2:F("spacing-2px"),4:F("spacing-4px"),6:F("spacing-6px"),7:F("spacing-7px"),8:F("spacing-8px"),10:F("spacing-10px"),12:F("spacing-12px"),14:F("spacing-14px"),16:F("spacing-16px"),18:F("spacing-18px"),20:F("spacing-20px"),22:F("spacing-22px"),24:F("spacing-24px"),26:F("spacing-26px"),28:F("spacing-28px"),30:F("spacing-30px"),32:F("spacing-32px"),34:F("spacing-34px"),36:F("spacing-36px"),40:F("spacing-40px")},border:{xsm:F("spacing-0-5px"),sm:F("spacing-1px"),med:F("spacing-2px"),lrg:F("spacing-3px")}},Kl={...Hl,...Ul,...Gl},un=(e,t="studio-c")=>Object.keys(e).flatMap(o=>Object.keys(e[o]).map(n=>`--${t}-${o}-${n}: ${e[o][n]}`)),Yl=(e,t={})=>{const{prefix:o="studio-c",cssRootSelector:n=":root"}=t,r=l=>l.map(a=>(u,h)=>jt(`--${o}-${String(a)}-${u}`,h)),s=z.css`
2
2
  ${n} {
3
3
  ${un(e,o).join(`;
4
4
  `)};
@@ -6,9 +6,9 @@
6
6
  `;return{getLocalComponentTokenHelpers:r,localComponentTokenCss:s}},ql=(e,t="studio-c")=>(o,n)=>jt(`--${t}-${e}-${o}`,n),Zl=(e,t={})=>{const{prefix:o="studio-c"}=t;return z.css`
7
7
  ${un(e,o).join(`;
8
8
  `)};
9
- `},M=e=>e.map(t=>(o,n)=>jt(`--studio-c-${t}-${o}`,n)),pn=(e,t)=>Object.keys(e).flatMap(o=>Object.keys(e[o]).map(n=>`${t(`${o}-${n}`,!0)}: ${e[o][n]}`)),Xl=z.css`
9
+ `},M=e=>e.map(t=>(o,n)=>jt(`--studio-c-${t}-${o}`,n)),hn=(e,t)=>Object.keys(e).flatMap(o=>Object.keys(e[o]).map(n=>`${t(`${o}-${n}`,!0)}: ${e[o][n]}`)),Xl=z.css`
10
10
  :root {
11
- ${pn(Kl,c)}
11
+ ${hn(Kl,c)}
12
12
  }
13
13
  `,Jl=z.css`
14
14
  :root {
@@ -16,11 +16,11 @@
16
16
  --rdp-accent-color: ${c("color-primary")};
17
17
  }
18
18
 
19
- ${pn(Vl,F)}
19
+ ${hn(Vl,F)}
20
20
  }
21
21
  `,Ql=z.css`
22
22
  :root {
23
- ${pn(Ll,(e,t)=>jt(`--studio-c-${e}`,t))}
23
+ ${hn(Ll,(e,t)=>jt(`--studio-c-${e}`,t))}
24
24
  }
25
25
  `,ec=z.css`
26
26
  :root {
@@ -671,7 +671,7 @@
671
671
  --ant-font-size-base: var(--kos-font-size-base);
672
672
  }
673
673
  }
674
- `;function It(e){return d.forwardRef(e)}const[Ie]=M(["text"]),Zr=["blue","dark","disabled","green","grey","light","purple","red","yellow","orange"],dc=({bold:e,children:t,color:o,ellipsis:n,lineClamp:r,textAlign:s,underline:l,variant:a,...u},p)=>i.jsx(z.ClassNames,{children:({cx:h})=>i.jsx(pc,{"data-variant":a,"data-alignment":s,"data-color":o,ref:p,...u,className:h(u.className,{isBold:e,isUnderlined:l,isEllipsized:n,isLineClamped:r}),children:t})}),E=It(dc),uc=["left","right","center","justify"],pc=g.span`
674
+ `;function It(e){return d.forwardRef(e)}const[Ie]=M(["text"]),Zr=["blue","dark","disabled","green","grey","light","purple","red","yellow","orange"],dc=({bold:e,children:t,color:o,ellipsis:n,lineClamp:r,textAlign:s,underline:l,variant:a,...u},h)=>i.jsx(z.ClassNames,{children:({cx:p})=>i.jsx(hc,{"data-variant":a,"data-alignment":s,"data-color":o,ref:h,...u,className:p(u.className,{isBold:e,isUnderlined:l,isEllipsized:n,isLineClamped:r}),children:t})}),E=It(dc),uc=["left","right","center","justify"],hc=g.span`
675
675
  font-family: ${Ie("font-family")};
676
676
  line-height: ${Ie("line-height")};
677
677
  vertical-align: bottom;
@@ -719,10 +719,10 @@
719
719
  color: ${Ie(`color-${e}`)};
720
720
  }`).join(`
721
721
  `)}
722
- `,[lt]=M(["link"]),hn=d.forwardRef(({children:e,onClick:t,size:o="med",isDisabled:n,...r},s)=>i.jsx("span",{ref:s,css:z.css`
723
- ${hc}
722
+ `,[lt]=M(["link"]),pn=d.forwardRef(({children:e,onClick:t,size:o="med",isDisabled:n,...r},s)=>i.jsx("span",{ref:s,css:z.css`
723
+ ${pc}
724
724
  font-size: ${lt(`font-size-${o}`)};
725
- `,onClick:t,className:n?"isDisabled":void 0,...r,children:e})),hc=z.css`
725
+ `,onClick:t,className:n?"isDisabled":void 0,...r,children:e})),pc=z.css`
726
726
  font-weight: ${lt("font-weight")};
727
727
  font-family: ${lt("font-family")};
728
728
  line-height: ${lt("line-height")};
@@ -755,7 +755,7 @@
755
755
  min-height: ${zt(`size-${e}`)};
756
756
  min-width: ${zt(`size-${e}`)};
757
757
  }`).join("")}
758
- `,[Qr]=M(["actionable-blurb"]),xc=d.memo(({text:e,actions:t,icon:o,title:n,iconColor:r,iconSize:s,className:l})=>{const a=d.useMemo(()=>{if(!t)return e;let u=e;return t.forEach(({action:p,actionText:h})=>{u=Hr(u,h,f=>i.jsx(hn,{onClick:p,children:f},f))}),u},[t,e]);return i.jsxs(yc,{className:l,children:[i.jsx(vc,{children:i.jsx(R,{iconId:o,size:s??"xsm",color:r??"black"})}),i.jsxs(kc,{className:"blurb-wrapper",children:[i.jsx(E,{color:"dark",variant:"body",bold:!0,children:n}),i.jsx(E,{color:"dark",variant:"body",children:a})]})]})}),yc=g.div`
758
+ `,[Qr]=M(["actionable-blurb"]),xc=d.memo(({text:e,actions:t,icon:o,title:n,iconColor:r,iconSize:s,className:l})=>{const a=d.useMemo(()=>{if(!t)return e;let u=e;return t.forEach(({action:h,actionText:p})=>{u=Hr(u,p,f=>i.jsx(pn,{onClick:h,children:f},f))}),u},[t,e]);return i.jsxs(yc,{className:l,children:[i.jsx(vc,{children:i.jsx(R,{iconId:o,size:s??"xsm",color:r??"black"})}),i.jsxs(kc,{className:"blurb-wrapper",children:[i.jsx(E,{color:"dark",variant:"body",bold:!0,children:n}),i.jsx(E,{color:"dark",variant:"body",children:a})]})]})}),yc=g.div`
759
759
  width: 100%;
760
760
  display: grid;
761
761
  grid-template-columns: ${Qr("icon-column-width")} 1fr;
@@ -774,7 +774,7 @@
774
774
  Copyright (c) 2018 Jed Watson.
775
775
  Licensed under the MIT License (MIT), see
776
776
  http://jedwatson.github.io/classnames
777
- */(function(e){(function(){var t={}.hasOwnProperty;function o(){for(var s="",l=0;l<arguments.length;l++){var a=arguments[l];a&&(s=r(s,n(a)))}return s}function n(s){if(typeof s=="string"||typeof s=="number")return s;if(typeof s!="object")return"";if(Array.isArray(s))return o.apply(null,s);if(s.toString!==Object.prototype.toString&&!s.toString.toString().includes("[native code]"))return s.toString();var l="";for(var a in s)t.call(s,a)&&s[a]&&(l=r(l,a));return l}function r(s,l){return l?s?s+" "+l:s+l:s}e.exports?(o.default=o,e.exports=o):window.classNames=o})()})(os);var Cc=os.exports;const Dt=ts(Cc),[Oe]=M(["icon-button"]),ae=d.forwardRef(({iconId:e,badgeOffset:t,badgeBorderColor:o="white",color:n,className:r,size:s,type:l,isActive:a,badgeColor:u,hasBadge:p,...h},f)=>i.jsxs($c,{className:Dt({isActive:a},r),type:l??"button",ref:f,...h,children:[p&&i.jsx(Sc,{"data-size":s,"data-border-color":o??n,"data-color":u??n,style:t?{right:t.x,top:t.y}:void 0}),i.jsx(R,{size:s,color:h.disabled?"grey":n??"white",iconId:e,className:"icon-button-icon"})]})),$c=g.button`
777
+ */(function(e){(function(){var t={}.hasOwnProperty;function o(){for(var s="",l=0;l<arguments.length;l++){var a=arguments[l];a&&(s=r(s,n(a)))}return s}function n(s){if(typeof s=="string"||typeof s=="number")return s;if(typeof s!="object")return"";if(Array.isArray(s))return o.apply(null,s);if(s.toString!==Object.prototype.toString&&!s.toString.toString().includes("[native code]"))return s.toString();var l="";for(var a in s)t.call(s,a)&&s[a]&&(l=r(l,a));return l}function r(s,l){return l?s?s+" "+l:s+l:s}e.exports?(o.default=o,e.exports=o):window.classNames=o})()})(os);var Cc=os.exports;const Dt=ts(Cc),[Oe]=M(["icon-button"]),ae=d.forwardRef(({iconId:e,badgeOffset:t,badgeBorderColor:o="white",color:n,className:r,size:s,type:l,isActive:a,badgeColor:u,hasBadge:h,...p},f)=>i.jsxs($c,{className:Dt({isActive:a},r),type:l??"button",ref:f,...p,children:[h&&i.jsx(Sc,{"data-size":s,"data-border-color":o??n,"data-color":u??n,style:t?{right:t.x,top:t.y}:void 0}),i.jsx(R,{size:s,color:p.disabled?"grey":n??"white",iconId:e,className:"icon-button-icon"})]})),$c=g.button`
778
778
  box-sizing: border-box;
779
779
  align-items: center;
780
780
  justify-content: center;
@@ -832,13 +832,13 @@
832
832
  white-space: normal;
833
833
  word-break: break-word;
834
834
  }
835
- `,[Ve]=M(["collapsible-artifact"]),_c=d.memo(({onExternalClick:e,id:t,name:o,isSelected:n,description:r,VersionList:s,className:l})=>{const a=d.useCallback(()=>{e&&e(t)},[t,e]);return i.jsx(go,{children:i.jsxs(Tc,{className:l,children:[i.jsxs(zc,{children:[i.jsx(fn,{children:i.jsx(Mc,{color:"black",size:"xxsm",iconId:"CaretRight"})}),i.jsxs(Oc,{children:[i.jsxs(Rc,{children:[i.jsx(E,{css:z.css`
835
+ `,[He]=M(["collapsible-artifact"]),_c=d.memo(({onExternalClick:e,id:t,name:o,isSelected:n,description:r,VersionList:s,className:l})=>{const a=d.useCallback(()=>{e&&e(t)},[t,e]);return i.jsx(go,{children:i.jsxs(Tc,{className:l,children:[i.jsxs(zc,{children:[i.jsx(fn,{children:i.jsx(Mc,{color:"black",size:"xxsm",iconId:"CaretRight"})}),i.jsxs(Oc,{children:[i.jsxs(Rc,{children:[i.jsx(E,{css:z.css`
836
836
  word-break: break-all;
837
837
  `,variant:"small",bold:!0,children:o}),!!n&&i.jsx(E,{variant:"small",color:"blue",children:"Selected"})]}),r&&i.jsx(Ic,{description:r})]}),!!e&&i.jsx(Ec,{color:"blue",iconId:"Export",onClick:a,size:"xsm"})]}),i.jsx(mo,{children:i.jsx(Nc,{children:i.jsx(Fc,{children:s})})})]})})}),Tc=g.div`
838
838
  align-items: flex-start;
839
- background-color: ${Ve("background-color")};
840
- border-radius: ${Ve("border-radius")};
841
- border: ${Ve("border-width")} solid ${Ve("border-color")};
839
+ background-color: ${He("background-color")};
840
+ border-radius: ${He("border-radius")};
841
+ border: ${He("border-width")} solid ${He("border-color")};
842
842
  display: flex;
843
843
  flex-direction: column;
844
844
  justify-content: flex-start;
@@ -849,8 +849,8 @@
849
849
  `,zc=g.div`
850
850
  align-items: flex-start;
851
851
  display: flex;
852
- gap: ${Ve("name-and-selected-spacing")};
853
- padding: ${Ve("padding")};
852
+ gap: ${He("name-and-selected-spacing")};
853
+ padding: ${He("padding")};
854
854
  width: 100%;
855
855
  `,Mc=g(ae)`
856
856
  z-index: 1;
@@ -862,23 +862,23 @@
862
862
  display: flex;
863
863
  flex-direction: column;
864
864
  flex: 1;
865
- gap: ${Ve("name-and-desc-spacing")};
865
+ gap: ${He("name-and-desc-spacing")};
866
866
  overflow: hidden;
867
867
  `,Rc=g.div`
868
868
  align-items: center;
869
869
  display: flex;
870
870
  flex-wrap: wrap;
871
871
  flex: 1;
872
- gap: ${Ve("name-and-selected-spacing")};
872
+ gap: ${He("name-and-selected-spacing")};
873
873
  justify-content: flex-start;
874
874
  width: 100%;
875
875
  `,Nc=g.div`
876
- border-top: 1px solid ${Ve("border-color")};
876
+ border-top: 1px solid ${He("border-color")};
877
877
  width: 100%;
878
878
  `,Fc=g.div`
879
- padding: ${Ve("name-and-selected-spacing")};
879
+ padding: ${He("name-and-selected-spacing")};
880
880
  width: 100%;
881
- `,$e=()=>{},Ac=e=>(t,o)=>e[t][o]??t,Lc=(e,t)=>d.useReducer(Ac(t),e),ro=e=>(e==null?void 0:e.animationName)||"none",Bc=(e,t)=>{const[o,n]=d.useState(),r=d.useRef(),s=d.useRef(e),l=d.useRef("none"),a=d.useRef(t);d.useLayoutEffect(()=>{a.current=t},[t]);const[u,p]=Lc(e?"mounted":"unmounted",{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmounting"},unmounted:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounting:{MOUNT:"mounted",ANIMATION_END:"unmounted"}});d.useEffect(()=>{const m=ro(r.current);l.current=u==="mounted"?m:"none"},[u]),d.useLayoutEffect(()=>{const m=r.current,b=s.current;if(b!==e){const y=l.current,k=ro(m);e?p("MOUNT"):k==="none"||(m==null?void 0:m.display)==="none"?p("UNMOUNT"):p(b&&y!==k?"ANIMATION_OUT":"UNMOUNT"),s.current=e}},[e,p]),d.useLayoutEffect(()=>{if(o){const m=x=>{const k=ro(r.current).includes(x.animationName);x.target===o&&k&&Vr.flushSync(()=>p("ANIMATION_END"))},b=x=>{x.target===o&&(l.current=ro(r.current))};return o.addEventListener("animationstart",b),o.addEventListener("animationcancel",m),o.addEventListener("animationend",m),()=>{o.removeEventListener("animationstart",b),o.removeEventListener("animationcancel",m),o.removeEventListener("animationend",m)}}else return p("ANIMATION_END"),$e},[o,p]);const h=d.useCallback(m=>{m&&(r.current=getComputedStyle(m)),n(m)},[]),f=["mounted","unmounting"].includes(u);return d.useEffect(()=>{a.current&&a.current(f)},[f]),{isPresent:f,ref:h}},ns=d.memo(({present:e,children:t,onPresenceChange:o})=>{const n=Bc(e,o);return n.isPresent?d.cloneElement(t,{ref:n.ref,present:e}):null});ns.displayName="AnimatePresence";const Wc=({offlineContent:e,onlineContent:t})=>t?e?i.jsx(Pc,{children:i.jsxs(Vc,{children:[i.jsx(sr,{$front:!0,children:e}),i.jsx(sr,{$back:!0,children:t})]})}):t:e,Pc=g.div`
881
+ `,Se=()=>{},Ac=e=>(t,o)=>e[t][o]??t,Lc=(e,t)=>d.useReducer(Ac(t),e),ro=e=>(e==null?void 0:e.animationName)||"none",Bc=(e,t)=>{const[o,n]=d.useState(),r=d.useRef(),s=d.useRef(e),l=d.useRef("none"),a=d.useRef(t);d.useLayoutEffect(()=>{a.current=t},[t]);const[u,h]=Lc(e?"mounted":"unmounted",{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmounting"},unmounted:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounting:{MOUNT:"mounted",ANIMATION_END:"unmounted"}});d.useEffect(()=>{const m=ro(r.current);l.current=u==="mounted"?m:"none"},[u]),d.useLayoutEffect(()=>{const m=r.current,b=s.current;if(b!==e){const y=l.current,k=ro(m);e?h("MOUNT"):k==="none"||(m==null?void 0:m.display)==="none"?h("UNMOUNT"):h(b&&y!==k?"ANIMATION_OUT":"UNMOUNT"),s.current=e}},[e,h]),d.useLayoutEffect(()=>{if(o){const m=x=>{const k=ro(r.current).includes(x.animationName);x.target===o&&k&&Vr.flushSync(()=>h("ANIMATION_END"))},b=x=>{x.target===o&&(l.current=ro(r.current))};return o.addEventListener("animationstart",b),o.addEventListener("animationcancel",m),o.addEventListener("animationend",m),()=>{o.removeEventListener("animationstart",b),o.removeEventListener("animationcancel",m),o.removeEventListener("animationend",m)}}else return h("ANIMATION_END"),Se},[o,h]);const p=d.useCallback(m=>{m&&(r.current=getComputedStyle(m)),n(m)},[]),f=["mounted","unmounting"].includes(u);return d.useEffect(()=>{a.current&&a.current(f)},[f]),{isPresent:f,ref:p}},ns=d.memo(({present:e,children:t,onPresenceChange:o})=>{const n=Bc(e,o);return n.isPresent?d.cloneElement(t,{ref:n.ref,present:e}):null});ns.displayName="AnimatePresence";const Wc=({offlineContent:e,onlineContent:t})=>t?e?i.jsx(Pc,{children:i.jsxs(Vc,{children:[i.jsx(sr,{$front:!0,children:e}),i.jsx(sr,{$back:!0,children:t})]})}):t:e,Pc=g.div`
882
882
  flex: 1;
883
883
  min-width: 0px;
884
884
  height: 100%;
@@ -920,7 +920,7 @@
920
920
  ${({$back:e})=>e&&`
921
921
  transform: rotateX(180deg) translateZ(20px);
922
922
  `}
923
- `,[N,be]=M(["button","icon"]),Hc=d.forwardRef(({variant:e,text:t,disabled:o,className:n,icon:r,...s},l)=>i.jsx(z.ClassNames,{children:({cx:a})=>i.jsxs(Uc,{disabled:o,className:a(e,n),ref:l,...s,children:[r&&i.jsx(Gc,{children:i.jsx(R,{iconId:r,size:"sm",color:"white"})}),t]})})),Ge=d.memo(Hc);Ge.displayName="StudioButton";const Uc=g.button`
923
+ `,[N,xe]=M(["button","icon"]),Hc=d.forwardRef(({variant:e,text:t,disabled:o,className:n,icon:r,...s},l)=>i.jsx(z.ClassNames,{children:({cx:a})=>i.jsxs(Uc,{disabled:o,className:a(e,n),ref:l,...s,children:[r&&i.jsx(Gc,{children:i.jsx(R,{iconId:r,size:"sm",color:"white"})}),t]})})),Ke=d.memo(Hc);Ke.displayName="StudioButton";const Uc=g.button`
924
924
  font-weight: ${N("font-weight")};
925
925
  font-size: ${N("font-size")};
926
926
  line-height: ${N("line-height")};
@@ -942,7 +942,7 @@
942
942
  // This token will let us flip the icon and text if we want to
943
943
  flex-direction: ${N("flex-direction")};
944
944
 
945
- ${`${be("fill-white",!0)}: ${N("color")}`};
945
+ ${`${xe("fill-white",!0)}: ${N("color")}`};
946
946
 
947
947
  &.primary-small,
948
948
  &.secondary-small,
@@ -955,14 +955,14 @@
955
955
  border-color: ${N("border-hover")};
956
956
  color: ${N("color-hover")};
957
957
  background-color: ${N("bg-hover")};
958
- ${`${be("fill-white",!0)}: ${N("color-hover")}`};
958
+ ${`${xe("fill-white",!0)}: ${N("color-hover")}`};
959
959
  }
960
960
 
961
961
  &:active {
962
962
  border-color: ${N("border-active")};
963
963
  color: ${N("color-active")};
964
964
  background-color: ${N("bg-active")};
965
- ${`${be("fill-white",!0)}: ${N("color-active")}`};
965
+ ${`${xe("fill-white",!0)}: ${N("color-active")}`};
966
966
  }
967
967
 
968
968
  &:disabled {
@@ -970,7 +970,7 @@
970
970
  border-color: ${N("border-disabled")};
971
971
  color: ${N("color-disabled")};
972
972
  background-color: ${N("bg-disabled")};
973
- ${`${be("fill-white",!0)}: ${N("color-disabled")}`};
973
+ ${`${xe("fill-white",!0)}: ${N("color-disabled")}`};
974
974
  }
975
975
 
976
976
  // Re-assign bg and color vars for secondary buttons.
@@ -979,26 +979,26 @@
979
979
  background-color: ${N("bg-secondary")};
980
980
  color: ${N("color-secondary")};
981
981
  border-color: ${N("border-secondary")};
982
- ${`${be("fill-white",!0)}: ${N("color-secondary")}`};
982
+ ${`${xe("fill-white",!0)}: ${N("color-secondary")}`};
983
983
  &:hover {
984
984
  border-color: ${N("border-hover-secondary")};
985
985
  color: ${N("color-hover-secondary")};
986
986
  background-color: ${N("bg-hover-secondary")};
987
- ${`${be("fill-white",!0)}: ${N("color-hover-secondary")}`};
987
+ ${`${xe("fill-white",!0)}: ${N("color-hover-secondary")}`};
988
988
  }
989
989
 
990
990
  &:active {
991
991
  border-color: ${N("border-active-secondary")};
992
992
  color: ${N("color-active-secondary")};
993
993
  background-color: ${N("bg-active-secondary")};
994
- ${`${be("fill-white",!0)}: ${N("color-active-secondary")}`};
994
+ ${`${xe("fill-white",!0)}: ${N("color-active-secondary")}`};
995
995
  }
996
996
 
997
997
  &:disabled {
998
998
  border-color: ${N("border-disabled-secondary")};
999
999
  color: ${N("color-disabled-secondary")};
1000
1000
  background-color: ${N("bg-disabled-secondary")};
1001
- ${`${be("fill-white",!0)}: ${N("color-disabled-secondary")}`};
1001
+ ${`${xe("fill-white",!0)}: ${N("color-disabled-secondary")}`};
1002
1002
  }
1003
1003
  }
1004
1004
 
@@ -1008,19 +1008,19 @@
1008
1008
  background-color: ${N("bg-borderless")};
1009
1009
  color: ${N("color-borderless")};
1010
1010
  border-color: ${N("border-borderless")};
1011
- ${`${be("fill-white",!0)}: ${N("color-borderless")}`};
1011
+ ${`${xe("fill-white",!0)}: ${N("color-borderless")}`};
1012
1012
  &:hover {
1013
1013
  border-color: ${N("border-hover-borderless")};
1014
1014
  color: ${N("color-hover-borderless")};
1015
1015
  background-color: ${N("bg-hover-borderless")};
1016
- ${`${be("fill-white",!0)}: ${N("color-hover-borderless")}`};
1016
+ ${`${xe("fill-white",!0)}: ${N("color-hover-borderless")}`};
1017
1017
  }
1018
1018
 
1019
1019
  &:active {
1020
1020
  border-color: ${N("border-active-borderless")};
1021
1021
  color: ${N("color-active-borderless")};
1022
1022
  background-color: ${N("bg-active-borderless")};
1023
- ${`${be("fill-white",!0)}: ${N("color-active-borderless")}`};
1023
+ ${`${xe("fill-white",!0)}: ${N("color-active-borderless")}`};
1024
1024
  }
1025
1025
 
1026
1026
  &:disabled {
@@ -1028,13 +1028,13 @@
1028
1028
  border-color: ${N("border-disabled-borderless")};
1029
1029
  color: ${N("color-disabled-borderless")};
1030
1030
  background-color: ${N("bg-disabled-borderless")};
1031
- ${`${be("fill-white",!0)}: ${N("color-disabled-borderless")}`};
1031
+ ${`${xe("fill-white",!0)}: ${N("color-disabled-borderless")}`};
1032
1032
  }
1033
1033
  }
1034
1034
  `,Gc=g.span`
1035
1035
  display: flex;
1036
1036
  margin: ${N("icon-margin")};
1037
- `,rs=d.createContext(void 0);function ss(){const e=d.useContext(rs);if(!e)throw new Error("useButtonGroupContext must be used within a ButtonGroup component");return e}const[bt]=M(["button-group"]),Kc=({value:e,defaultValue:t,onValueChange:o,children:n,className:r})=>{const[s,l]=d.useState(t),a=e??s,u=o??l,p=d.useMemo(()=>({value:a,setValue:u}),[a,u]);return i.jsx(rs.Provider,{value:p,children:i.jsx(Yc,{className:r,children:n})})},Yc=g.div`
1037
+ `,rs=d.createContext(void 0);function ss(){const e=d.useContext(rs);if(!e)throw new Error("useButtonGroupContext must be used within a ButtonGroup component");return e}const[bt]=M(["button-group"]),Kc=({value:e,defaultValue:t,onValueChange:o,children:n,className:r})=>{const[s,l]=d.useState(t),a=e??s,u=o??l,h=d.useMemo(()=>({value:a,setValue:u}),[a,u]);return i.jsx(rs.Provider,{value:h,children:i.jsx(Yc,{className:r,children:n})})},Yc=g.div`
1038
1038
  display: inline-flex;
1039
1039
  align-items: center;
1040
1040
  gap: ${bt("gap")};
@@ -1146,15 +1146,15 @@
1146
1146
  opacity: 1;
1147
1147
  }
1148
1148
  }
1149
- `;var Qc=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,o=[],n=0;n<e.rangeCount;n++)o.push(e.getRangeAt(n));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null;break}return e.removeAllRanges(),function(){e.type==="Caret"&&e.removeAllRanges(),e.rangeCount||o.forEach(function(r){e.addRange(r)}),t&&t.focus()}},ed=Qc,ar={"text/plain":"Text","text/html":"Url",default:"Text"},td="Copy to clipboard: #{key}, Enter";function od(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}function nd(e,t){var o,n,r,s,l,a,u=!1;t||(t={}),o=t.debug||!1;try{r=ed(),s=document.createRange(),l=document.getSelection(),a=document.createElement("span"),a.textContent=e,a.ariaHidden="true",a.style.all="unset",a.style.position="fixed",a.style.top=0,a.style.clip="rect(0, 0, 0, 0)",a.style.whiteSpace="pre",a.style.webkitUserSelect="text",a.style.MozUserSelect="text",a.style.msUserSelect="text",a.style.userSelect="text",a.addEventListener("copy",function(h){if(h.stopPropagation(),t.format)if(h.preventDefault(),typeof h.clipboardData>"u"){o&&console.warn("unable to use e.clipboardData"),o&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var f=ar[t.format]||ar.default;window.clipboardData.setData(f,e)}else h.clipboardData.clearData(),h.clipboardData.setData(t.format,e);t.onCopy&&(h.preventDefault(),t.onCopy(h.clipboardData))}),document.body.appendChild(a),s.selectNodeContents(a),l.addRange(s);var p=document.execCommand("copy");if(!p)throw new Error("copy command was unsuccessful");u=!0}catch(h){o&&console.error("unable to copy using execCommand: ",h),o&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),u=!0}catch(f){o&&console.error("unable to copy using clipboardData: ",f),o&&console.error("falling back to prompt"),n=od("message"in t?t.message:td),window.prompt(n,e)}}finally{l&&(typeof l.removeRange=="function"?l.removeRange(s):l.removeAllRanges()),a&&document.body.removeChild(a),r()}return u}var rd=nd;const sd=ts(rd),id=250,ad=500,ld=({children:e,color:t,copyable:o=!0,copyText:n,onClick:r,onMouseMove:s,onMouseOut:l,onMouseOver:a,style:u,...p})=>{const h=d.useRef(),f=d.useRef(),m=d.useRef(null),b=d.useRef(null),[x,y]=d.useState(!1),[k,v]=d.useState(!1),$=d.useCallback(I=>{let j=n;j||(j=typeof e=="string"?String(e):""),y(!0),sd(j);const D=()=>{y(!1)};clearTimeout(h.current),h.current=setTimeout(D,ad),r==null||r(I)},[e,n,r]),C=d.useCallback(I=>{if(!m.current||!b.current){s==null||s(I);return}const j=b.current.getBoundingClientRect(),D=I.clientX-j.left+9,L=I.clientY-j.top+9;m.current.style.transform=`translate(${D}px, ${L}px)`,s==null||s(I)},[s]),S=d.useCallback(I=>{y(!1),v(!1),clearTimeout(f.current),l==null||l(I)},[l]),w=d.useCallback(I=>{const j=()=>{v(!0)};return clearTimeout(f.current),f.current=setTimeout(j,id),a==null||a(I),()=>{clearTimeout(f.current)}},[a]);return i.jsxs("div",{style:{position:"relative"},children:[i.jsx(cd,{ref:b,children:e,onClick:o?$:r,onMouseMove:o?C:s,onMouseOut:o?S:l,onMouseOver:o?w:a,style:o?x?{...u,opacity:.5,cursor:"default",userSelect:"none"}:{...u,cursor:"default",userSelect:"none"}:{...u,cursor:"default",userSelect:"none"},...p}),o&&i.jsx(R,{ref:m,iconId:"CopyFilled",style:{position:"absolute",transition:"opacity 150ms ease-in-out",top:"0px",left:"0px",opacity:k&&!x?"1":"0"}})]})},cd=g(E)`
1149
+ `;var Qc=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,o=[],n=0;n<e.rangeCount;n++)o.push(e.getRangeAt(n));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null;break}return e.removeAllRanges(),function(){e.type==="Caret"&&e.removeAllRanges(),e.rangeCount||o.forEach(function(r){e.addRange(r)}),t&&t.focus()}},ed=Qc,ar={"text/plain":"Text","text/html":"Url",default:"Text"},td="Copy to clipboard: #{key}, Enter";function od(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}function nd(e,t){var o,n,r,s,l,a,u=!1;t||(t={}),o=t.debug||!1;try{r=ed(),s=document.createRange(),l=document.getSelection(),a=document.createElement("span"),a.textContent=e,a.ariaHidden="true",a.style.all="unset",a.style.position="fixed",a.style.top=0,a.style.clip="rect(0, 0, 0, 0)",a.style.whiteSpace="pre",a.style.webkitUserSelect="text",a.style.MozUserSelect="text",a.style.msUserSelect="text",a.style.userSelect="text",a.addEventListener("copy",function(p){if(p.stopPropagation(),t.format)if(p.preventDefault(),typeof p.clipboardData>"u"){o&&console.warn("unable to use e.clipboardData"),o&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var f=ar[t.format]||ar.default;window.clipboardData.setData(f,e)}else p.clipboardData.clearData(),p.clipboardData.setData(t.format,e);t.onCopy&&(p.preventDefault(),t.onCopy(p.clipboardData))}),document.body.appendChild(a),s.selectNodeContents(a),l.addRange(s);var h=document.execCommand("copy");if(!h)throw new Error("copy command was unsuccessful");u=!0}catch(p){o&&console.error("unable to copy using execCommand: ",p),o&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),u=!0}catch(f){o&&console.error("unable to copy using clipboardData: ",f),o&&console.error("falling back to prompt"),n=od("message"in t?t.message:td),window.prompt(n,e)}}finally{l&&(typeof l.removeRange=="function"?l.removeRange(s):l.removeAllRanges()),a&&document.body.removeChild(a),r()}return u}var rd=nd;const sd=ts(rd),id=250,ad=500,ld=({children:e,color:t,copyable:o=!0,copyText:n,onClick:r,onMouseMove:s,onMouseOut:l,onMouseOver:a,style:u,...h})=>{const p=d.useRef(),f=d.useRef(),m=d.useRef(null),b=d.useRef(null),[x,y]=d.useState(!1),[k,v]=d.useState(!1),$=d.useCallback(I=>{let j=n;j||(j=typeof e=="string"?String(e):""),y(!0),sd(j);const D=()=>{y(!1)};clearTimeout(p.current),p.current=setTimeout(D,ad),r==null||r(I)},[e,n,r]),C=d.useCallback(I=>{if(!m.current||!b.current){s==null||s(I);return}const j=b.current.getBoundingClientRect(),D=I.clientX-j.left+9,L=I.clientY-j.top+9;m.current.style.transform=`translate(${D}px, ${L}px)`,s==null||s(I)},[s]),S=d.useCallback(I=>{y(!1),v(!1),clearTimeout(f.current),l==null||l(I)},[l]),w=d.useCallback(I=>{const j=()=>{v(!0)};return clearTimeout(f.current),f.current=setTimeout(j,id),a==null||a(I),()=>{clearTimeout(f.current)}},[a]);return i.jsxs("div",{style:{position:"relative"},children:[i.jsx(cd,{ref:b,children:e,onClick:o?$:r,onMouseMove:o?C:s,onMouseOut:o?S:l,onMouseOver:o?w:a,style:o?x?{...u,opacity:.5,cursor:"default",userSelect:"none"}:{...u,cursor:"default",userSelect:"none"}:{...u,cursor:"default",userSelect:"none"},...h}),o&&i.jsx(R,{ref:m,iconId:"CopyFilled",style:{position:"absolute",transition:"opacity 150ms ease-in-out",top:"0px",left:"0px",opacity:k&&!x?"1":"0"}})]})},cd=g(E)`
1150
1150
  position: relative;
1151
1151
  transition: opacity 150ms ease-in-out;
1152
- `,dd=({children:e,forwardedRef:t,setFloatingReference:o,getReferenceProps:n,open:r})=>{const s=e.ref,l=O.useMergeRefs([o,t,s]);if(d.isValidElement(e))return d.cloneElement(e,n({ref:l,...e.props,"data-state":r?"open":"closed"}));throw new Error("Passed useDecoratedFloatingUITrigger an invalid child element")};function as({defaultOpen:e=!1,open:t,onOpenChange:o,dismissOptions:n}={}){const[r,s]=d.useState(e),l=t??r,a=d.useCallback(b=>{t===void 0&&s(b),o==null||o(b)},[t,o]),u=O.useFloating({open:l,onOpenChange:a}),p=u.context,h=O.useClick(p),f=O.useDismiss(p,n?{outsidePressEvent:"mousedown",...n}:{outsidePressEvent:"mousedown"}),m=O.useInteractions([h,f]);return d.useMemo(()=>({open:l,setOpen:a,...m,...u}),[l,a,m,u])}const ud=z.css`
1152
+ `,dd=({children:e,forwardedRef:t,setFloatingReference:o,getReferenceProps:n,open:r})=>{const s=e.ref,l=O.useMergeRefs([o,t,s]);if(d.isValidElement(e))return d.cloneElement(e,n({ref:l,...e.props,"data-state":r?"open":"closed"}));throw new Error("Passed useDecoratedFloatingUITrigger an invalid child element")};function as({defaultOpen:e=!1,open:t,onOpenChange:o,dismissOptions:n}={}){const[r,s]=d.useState(e),l=t??r,a=d.useCallback(b=>{t===void 0&&s(b),o==null||o(b)},[t,o]),u=O.useFloating({open:l,onOpenChange:a}),h=u.context,p=O.useClick(h),f=O.useDismiss(h,n?{outsidePressEvent:"mousedown",...n}:{outsidePressEvent:"mousedown"}),m=O.useInteractions([p,f]);return d.useMemo(()=>({open:l,setOpen:a,...m,...u}),[l,a,m,u])}const ud=z.css`
1153
1153
  background: rgba(0, 0, 0, 0.8);
1154
1154
  display: grid;
1155
1155
  place-items: center;
1156
1156
  z-index: 1;
1157
- `,ls=d.createContext(null),nt=()=>{const e=d.useContext(ls);if(e==null)throw new Error("Dialog components must be wrapped in <Dialog />");return e},gn=d.memo(({children:e,...t})=>{const o=as(t);return i.jsx(ls.Provider,{value:o,children:e})}),mn=d.forwardRef(({children:e},t)=>{const o=nt();return dd({children:e,forwardedRef:t,setFloatingReference:o.refs.setReference,getReferenceProps:o.getReferenceProps,open:o.open})}),bn=d.forwardRef(({disableScrollLock:e,modal:t,portalRoot:o,portalId:n,trapFocus:r,transitionDuration:s,OverlayStyles:l,disableFocusManagement:a,children:u,initialFocus:p,...h},f)=>{const{context:m,...b}=nt(),x=O.useMergeRefs([b.refs.setFloating,f]),{isMounted:y,status:k}=O.useTransitionStatus(m,{duration:s||0});if(!d.isValidElement(u))throw new Error("Passed an invalid child element to Dialog.");if(!y)return null;const v=t?ud:l;return i.jsx(O.FloatingPortal,{id:n,root:o,children:i.jsx(O.FloatingFocusManager,{context:m,modal:r,returnFocus:!1,initialFocus:p,disabled:a,children:i.jsx(O.FloatingOverlay,{css:v,"data-status":k,lockScroll:!e,children:d.cloneElement(u,{...u.props,ref:x,"data-status":k==="initial"?"open":k,...b.getFloatingProps(h)})})})})}),xn=300;function yn(){const e=d.useRef(null),[t,o]=d.useState();return d.useEffect(()=>{const n=new ResizeObserver(([r])=>{r&&o(r.contentRect.width)});return e.current&&n.observe(e.current),()=>n.disconnect()},[]),[e,t]}const pd=g.div`
1157
+ `,ls=d.createContext(null),rt=()=>{const e=d.useContext(ls);if(e==null)throw new Error("Dialog components must be wrapped in <Dialog />");return e},gn=d.memo(({children:e,...t})=>{const o=as(t);return i.jsx(ls.Provider,{value:o,children:e})}),mn=d.forwardRef(({children:e},t)=>{const o=rt();return dd({children:e,forwardedRef:t,setFloatingReference:o.refs.setReference,getReferenceProps:o.getReferenceProps,open:o.open})}),bn=d.forwardRef(({disableScrollLock:e,modal:t,portalRoot:o,portalId:n,trapFocus:r,transitionDuration:s,OverlayStyles:l,disableFocusManagement:a,children:u,initialFocus:h,...p},f)=>{const{context:m,...b}=rt(),x=O.useMergeRefs([b.refs.setFloating,f]),{isMounted:y,status:k}=O.useTransitionStatus(m,{duration:s||0});if(!d.isValidElement(u))throw new Error("Passed an invalid child element to Dialog.");if(!y)return null;const v=t?ud:l;return i.jsx(O.FloatingPortal,{id:n,root:o,children:i.jsx(O.FloatingFocusManager,{context:m,modal:r,returnFocus:!1,initialFocus:h,disabled:a,children:i.jsx(O.FloatingOverlay,{css:v,"data-status":k,lockScroll:!e,children:d.cloneElement(u,{...u.props,ref:x,"data-status":k==="initial"?"open":k,...b.getFloatingProps(p)})})})})}),xn=300;function yn(){const e=d.useRef(null),[t,o]=d.useState();return d.useEffect(()=>{const n=new ResizeObserver(([r])=>{r&&o(r.contentRect.width)});return e.current&&n.observe(e.current),()=>n.disconnect()},[]),[e,t]}const hd=g.div`
1158
1158
  background-color: transparent;
1159
1159
  box-sizing: border-box;
1160
1160
  cursor: ew-resize;
@@ -1174,7 +1174,7 @@
1174
1174
  right: -4px;
1175
1175
  top: 0;
1176
1176
  }
1177
- `,Zt=({inverse:e=!1,maxSize:t,minSize:o=200,onChange:n,size:r,...s})=>{const l=d.useRef(0),a=La.useDrag(({down:u,movement:[p],first:h})=>{if(!u)return;h&&(l.current=r);let f=l.current-p*(e?-1:1);f<o&&(f=o),t!==void 0&&f>t&&(f=t),n(f)});return i.jsx(pd,{...s,...a()})},hd=({defaultOpen:e=!1,minSize:t,mode:o,onOpenChange:n,open:r,size:s=440})=>{const[l,a]=d.useState(e),[u,p]=d.useState(s),h=r??l,f=n??a;return d.useMemo(()=>({mode:o,open:h,setOpen:f,setSize:p,size:u,minSize:t}),[t,o,h,f,u])},en=d.createContext(null),ut=()=>{const e=d.useContext(en);if(e==null)throw new Error("Drawer components must be wrapped in <Drawer />");return e},[ue]=M(["drawer"]),fd=g.div`
1177
+ `,Zt=({inverse:e=!1,maxSize:t,minSize:o=200,onChange:n,size:r,...s})=>{const l=d.useRef(0),a=La.useDrag(({down:u,movement:[h],first:p})=>{if(!u)return;p&&(l.current=r);let f=l.current-h*(e?-1:1);f<o&&(f=o),t!==void 0&&f>t&&(f=t),n(f)});return i.jsx(hd,{...s,...a()})},pd=({defaultOpen:e=!1,minSize:t,mode:o,onOpenChange:n,open:r,size:s=440})=>{const[l,a]=d.useState(e),[u,h]=d.useState(s),p=r??l,f=n??a;return d.useMemo(()=>({mode:o,open:p,setOpen:f,setSize:h,size:u,minSize:t}),[t,o,p,f,u])},en=d.createContext(null),ut=()=>{const e=d.useContext(en);if(e==null)throw new Error("Drawer components must be wrapped in <Drawer />");return e},[ue]=M(["drawer"]),fd=g.div`
1178
1178
  display: flex;
1179
1179
  height: 100%;
1180
1180
  position: absolute;
@@ -1212,11 +1212,11 @@
1212
1212
  display: flex;
1213
1213
  height: 100%;
1214
1214
  width: 100%;
1215
- `,ps=g.div`
1215
+ `,hs=g.div`
1216
1216
  flex: 1;
1217
1217
  width: 100%;
1218
1218
  height: 100%;
1219
- `,bd=d.forwardRef(({children:e,className:t,...o},n)=>{const{minSize:r,size:s,setSize:l}=ut(),[a,u]=yn(),p=u!==void 0,h=s/(u||1);return i.jsx(us,{ref:a,children:p&&i.jsxs(i.Fragment,{children:[i.jsx(ds,{ref:n,className:t,style:{flexGrow:h},...o,children:e}),i.jsx(Zt,{inverse:!0,size:s,minSize:r,onChange:l}),i.jsx(ps,{style:{flexGrow:1-h}})]})})}),xd=d.forwardRef(({children:e,className:t,...o},n)=>{const{minSize:r,size:s,setSize:l}=ut(),[a,u]=yn(),p=u!==void 0,h=s/(u||1);return i.jsx(us,{ref:a,children:p&&i.jsxs(i.Fragment,{children:[i.jsx(ps,{style:{flexGrow:1-h}}),i.jsx(Zt,{size:s,minSize:r,onChange:l}),i.jsx(ds,{ref:n,className:t,style:{flexGrow:h},...o,children:e})]})})}),yd=z.keyframes({"0%":{transform:"translateX(-100%)"},"100%":{transform:"translateX(0%)"}}),vd=z.keyframes({"0%":{transform:"translateX(0%)"},"100%":{transform:"translateX(-100%)"}}),kd=g(bd)`
1219
+ `,bd=d.forwardRef(({children:e,className:t,...o},n)=>{const{minSize:r,size:s,setSize:l}=ut(),[a,u]=yn(),h=u!==void 0,p=s/(u||1);return i.jsx(us,{ref:a,children:h&&i.jsxs(i.Fragment,{children:[i.jsx(ds,{ref:n,className:t,style:{flexGrow:p},...o,children:e}),i.jsx(Zt,{inverse:!0,size:s,minSize:r,onChange:l}),i.jsx(hs,{style:{flexGrow:1-p}})]})})}),xd=d.forwardRef(({children:e,className:t,...o},n)=>{const{minSize:r,size:s,setSize:l}=ut(),[a,u]=yn(),h=u!==void 0,p=s/(u||1);return i.jsx(us,{ref:a,children:h&&i.jsxs(i.Fragment,{children:[i.jsx(hs,{style:{flexGrow:1-p}}),i.jsx(Zt,{size:s,minSize:r,onChange:l}),i.jsx(ds,{ref:n,className:t,style:{flexGrow:p},...o,children:e})]})})}),yd=z.keyframes({"0%":{transform:"translateX(-100%)"},"100%":{transform:"translateX(0%)"}}),vd=z.keyframes({"0%":{transform:"translateX(0%)"},"100%":{transform:"translateX(-100%)"}}),kd=g(bd)`
1220
1220
  border-right-width: ${ue("border-width")};
1221
1221
  box-shadow: ${ue("left-drop-shadow")};
1222
1222
  &[data-status="open"] {
@@ -1234,7 +1234,7 @@
1234
1234
  &[data-status="close"] {
1235
1235
  animation-name: ${Cd};
1236
1236
  }
1237
- `,hs=g.div`
1237
+ `,ps=g.div`
1238
1238
  width: 100%;
1239
1239
  pointer-events: all;
1240
1240
  height: fit-content;
@@ -1245,7 +1245,7 @@
1245
1245
  // We add 50ms here to hedge against a race condition between
1246
1246
  // the css animation finishing and the floating-ui transition helper hiding the content.
1247
1247
  animation-duration: ${xn+10}ms;
1248
- `,Sd=z.keyframes({from:{transform:"translateY(-30px)",opacity:0},to:{transform:"translateY(0)",opacity:1}}),jd=z.keyframes({from:{transform:"translateY(0)",opacity:1},to:{transform:"translateY(-30px)",opacity:0}}),Id=g(hs)`
1248
+ `,Sd=z.keyframes({from:{transform:"translateY(-30px)",opacity:0},to:{transform:"translateY(0)",opacity:1}}),jd=z.keyframes({from:{transform:"translateY(0)",opacity:1},to:{transform:"translateY(-30px)",opacity:0}}),Id=g(ps)`
1249
1249
  border-bottom-width: ${ue("border-width")};
1250
1250
  &[data-status="open"] {
1251
1251
  animation-name: ${Sd};
@@ -1253,7 +1253,7 @@
1253
1253
  &[data-status="close"] {
1254
1254
  animation-name: ${jd};
1255
1255
  }
1256
- `,fs=z.keyframes({from:{transform:"translateY(30px)",opacity:0},to:{transform:"translateY(0)",opacity:1}}),gs=z.keyframes({from:{transform:"translateY(0)",opacity:1},to:{transform:"translateY(30px)",opacity:0}}),Dd=g(hs)`
1256
+ `,fs=z.keyframes({from:{transform:"translateY(30px)",opacity:0},to:{transform:"translateY(0)",opacity:1}}),gs=z.keyframes({from:{transform:"translateY(0)",opacity:1},to:{transform:"translateY(30px)",opacity:0}}),Dd=g(ps)`
1257
1257
  border-top-width: ${ue("border-width")};
1258
1258
  &[data-status="open"] {
1259
1259
  animation-name: ${fs};
@@ -1295,7 +1295,7 @@
1295
1295
  &[data-status="close"] {
1296
1296
  animation-name: ${gs};
1297
1297
  }
1298
- `,Rd={escapeKey:!0,outsidePress:!1},Nd=d.memo(({children:e,...t})=>{const o=hd(t);return t.mode==="dialog"?i.jsx(en.Provider,{value:o,children:i.jsx(gn,{onOpenChange:o.setOpen,open:o.open,defaultOpen:t.defaultOpen??!1,dismissOptions:Rd,children:e})}):i.jsx(en.Provider,{value:o,children:e})}),Fd=d.memo(({children:e})=>{const{mode:t,open:o,setOpen:n}=ut(),r=d.useCallback(()=>{n(!o)},[o,n]);if(t==="dialog")return i.jsx(mn,{children:e});if(d.isValidElement(e))return d.cloneElement(e,{...e.props,onClick:r,"data-state":o?"open":"closed"});throw new Error("Passed DialogTrigger an invalid element")}),Ad=d.memo(({children:e,OverlayStyles:t,...o})=>{const{mode:n,open:r}=ut();if(n==="dialog")return i.jsx(bn,{disableScrollLock:!0,disableFocusManagement:!0,OverlayStyles:t,transitionDuration:xn,...o,children:e});if(t)throw new Error("OverlayStyles are not used in inline drawers.");return r?n==="inline-float"?i.jsx(fd,{children:e}):e:null}),[Mt]=M(["drawer"]),Ld=d.memo(({children:e,className:t,closeIcon:o,showCloseButton:n=!0,title:r,textVariant:s="h2",textBold:l=!1,inheritTextColor:a=!1})=>{const{setOpen:u}=ut(),p=d.useCallback(()=>{u(!1)},[u]);return i.jsxs(Bd,{className:t,children:[i.jsx(E,{bold:l,color:a?void 0:"dark",variant:s,children:r}),e,n&&i.jsx(ae,{onClick:p,iconId:o||"Close",size:"sm",color:a?void 0:"blue"})]})}),Bd=g.div`
1298
+ `,Rd={escapeKey:!0,outsidePress:!1},Nd=d.memo(({children:e,...t})=>{const o=pd(t);return t.mode==="dialog"?i.jsx(en.Provider,{value:o,children:i.jsx(gn,{onOpenChange:o.setOpen,open:o.open,defaultOpen:t.defaultOpen??!1,dismissOptions:Rd,children:e})}):i.jsx(en.Provider,{value:o,children:e})}),Fd=d.memo(({children:e})=>{const{mode:t,open:o,setOpen:n}=ut(),r=d.useCallback(()=>{n(!o)},[o,n]);if(t==="dialog")return i.jsx(mn,{children:e});if(d.isValidElement(e))return d.cloneElement(e,{...e.props,onClick:r,"data-state":o?"open":"closed"});throw new Error("Passed DialogTrigger an invalid element")}),Ad=d.memo(({children:e,OverlayStyles:t,...o})=>{const{mode:n,open:r}=ut();if(n==="dialog")return i.jsx(bn,{disableScrollLock:!0,disableFocusManagement:!0,OverlayStyles:t,transitionDuration:xn,...o,children:e});if(t)throw new Error("OverlayStyles are not used in inline drawers.");return r?n==="inline-float"?i.jsx(fd,{children:e}):e:null}),[Mt]=M(["drawer"]),Ld=d.memo(({children:e,className:t,closeIcon:o,showCloseButton:n=!0,title:r,textVariant:s="h2",textBold:l=!1,inheritTextColor:a=!1})=>{const{setOpen:u}=ut(),h=d.useCallback(()=>{u(!1)},[u]);return i.jsxs(Bd,{className:t,children:[i.jsx(E,{bold:l,color:a?void 0:"dark",variant:s,children:r}),e,n&&i.jsx(ae,{onClick:h,iconId:o||"Close",size:"sm",color:a?void 0:"blue"})]})}),Bd=g.div`
1299
1299
  width: 100%;
1300
1300
  display: flex;
1301
1301
  align-items: center;
@@ -1308,7 +1308,7 @@
1308
1308
  width: 100%;
1309
1309
  border-bottom: ${lr("border-width")} solid
1310
1310
  ${lr("border-color")};
1311
- `,[ne]=M(["input"]),Tt=d.forwardRef(({className:e,type:t,prefixIconId:o,prefixIconColor:n,prefixSize:r,isSmall:s,autoCapitalize:l="off",autoComplete:a="off",autoCorrect:u="off",suffixIconColor:p,suffixIcon:h,suffixIconId:f,suffixSize:m,onSuffixIconClick:b,onEnter:x,onKeyDown:y,onClear:k,...v},$)=>{const C=t==="password",[S,w]=d.useState(!1),[I,j]=d.useState(t),D=d.useCallback(()=>{j(S?"password":"text"),w(!S)},[S]),L=U=>{U.key==="Enter"&&(x==null||x()),y==null||y(U)};if(d.useEffect(()=>{j(t)},[t]),k&&C)throw new Error("Password inputs cannot have an onClear handler.");if(h&&C)throw new Error("Password inputs cannot have a suffix icon.");if(k&&h)throw new Error("Inputs with an onClear handler cannot have a suffix icon.");return i.jsx(z.ClassNames,{children:({cx:U})=>i.jsxs(Pd,{children:[i.jsx(Vd,{type:I,className:U(e,{isSmall:s,hasLeftIcon:!!o,hasRightIcon:!!C||!!f||!!h}),ref:$,autoCapitalize:C?"off":l,autoComplete:C?"current-password":a,autoCorrect:C?"off":u,onKeyDown:L,...v}),o&&i.jsx(Hd,{iconId:o,color:n||"black",size:r||"sm"}),(C||!!f||!!h||k&&!!v.value)&&i.jsx(Ud,{children:h||(f?i.jsx(R,{iconId:f,color:p??"black",size:m||"sm",onClick:b}):k?i.jsx(ae,{iconId:"Close",size:"sm",color:"black",onClick:k}):i.jsx(ae,{onClick:D,iconId:S?"Eye":"EyeInvisible",size:"sm",color:n??"black"}))})]})})}),Pd=g.div`
1311
+ `,[ne]=M(["input"]),Tt=d.forwardRef(({className:e,type:t,prefixIconId:o,prefixIconColor:n,prefixSize:r,isSmall:s,autoCapitalize:l="off",autoComplete:a="off",autoCorrect:u="off",suffixIconColor:h,suffixIcon:p,suffixIconId:f,suffixSize:m,onSuffixIconClick:b,onEnter:x,onKeyDown:y,onClear:k,...v},$)=>{const C=t==="password",[S,w]=d.useState(!1),[I,j]=d.useState(t),D=d.useCallback(()=>{j(S?"password":"text"),w(!S)},[S]),L=U=>{U.key==="Enter"&&(x==null||x()),y==null||y(U)};if(d.useEffect(()=>{j(t)},[t]),k&&C)throw new Error("Password inputs cannot have an onClear handler.");if(p&&C)throw new Error("Password inputs cannot have a suffix icon.");if(k&&p)throw new Error("Inputs with an onClear handler cannot have a suffix icon.");return i.jsx(z.ClassNames,{children:({cx:U})=>i.jsxs(Pd,{children:[i.jsx(Vd,{type:I,className:U(e,{isSmall:s,hasLeftIcon:!!o,hasRightIcon:!!C||!!f||!!p}),ref:$,autoCapitalize:C?"off":l,autoComplete:C?"current-password":a,autoCorrect:C?"off":u,onKeyDown:L,...v}),o&&i.jsx(Hd,{iconId:o,color:n||"black",size:r||"sm"}),(C||!!f||!!p||k&&!!v.value)&&i.jsx(Ud,{children:p||(f?i.jsx(R,{iconId:f,color:h??"black",size:m||"sm",onClick:b}):k?i.jsx(ae,{iconId:"Close",size:"sm",color:"black",onClick:k}):i.jsx(ae,{onClick:D,iconId:S?"Eye":"EyeInvisible",size:"sm",color:n??"black"}))})]})})}),Pd=g.div`
1312
1312
  width: 100%;
1313
1313
  height: fit-content;
1314
1314
  position: relative;
@@ -1377,7 +1377,7 @@
1377
1377
  gap: ${Kd("gap")};
1378
1378
  `,ys=({variant:e="body",...t})=>i.jsx(E,{css:xs,variant:e,...t}),vn=({children:e,prefix:t,suffix:o,...n})=>i.jsxs(ys,{...n,children:[t,e,o]}),[Yd]=M(["label-with-action"]),qd=z.css([xs,{gap:Yd("gap")}]),Zd=({action:e,variant:t="h2",...o})=>i.jsx(vn,{css:qd,suffix:e,variant:t,...o}),[Xd]=M(["label-with-content-link"]),Jd=z.css`
1379
1379
  color: ${Xd("color")};
1380
- `,Qd=e=>i.jsx(vn,{css:Jd,...e}),eu=new RegExp(/^[a-zA-Z0-9 _.-]*$/),vs=new RegExp(/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/),tu=new RegExp(/^\d+$/),ou=new RegExp(/^\S*$/),nu=new RegExp(/^[a-zA-Z].*/),ks=new RegExp(/^[-a-zA-Z0-9-_'().-]+(\s+[-a-zA-Z0-9-_'().-]+)*$/);var ws=(e=>(e.email="email",e))(ws||{});const ru=()=>({email:e=>vs.test(e)}),su=12;var Wt=(e=>(e.noDigit="noDigit",e.noUpperCase="noUpperCase",e.noSpecialCharacter="noSpecialCharacter",e.tooSimilar="tooSimilar",e))(Wt||{});const iu=(e,t)=>({...e?{tooSimilar:(o,n)=>{const r=n[t??"password_current"];return r?o!==r:!0}}:{tooSimilar:()=>!0},noDigit:o=>new RegExp(/\d/).test(o),noSpecialCharacter:o=>new RegExp(/[!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~]+/).test(o),noUpperCase:o=>new RegExp(/[A-Z]+/).test(o)}),Cs=e=>typeof e=="object"&&e!==null&&"message"in e&&typeof e.message=="string",au=e=>{if(Cs(e))return e.message},lu=()=>{let e=!1,t=[];const o=new Map,n=new window.ResizeObserver((r,s)=>{t=t.concat(r),e||window.requestAnimationFrame(()=>{const l=new Set;t.forEach(a=>{if(!l.has(a.target)){l.add(a.target);const u=o.get(a.target);u&&u.forEach(p=>p(a,s))}}),t=[],e=!1}),e=!0});return{observer:n,subscribe(r,s){n.observe(r);const l=o.get(r)??[];l.push(s),o.set(r,l)},unsubscribe(r,s){const l=o.get(r)??[];if(l.length===1){n.unobserve(r),o.delete(r);return}const a=l.indexOf(s);a!==-1&&l.splice(a,1),o.set(r,l)}}};let Oo;const cu=()=>Oo||(Oo=lu()),$s=(e,t)=>{const o=cu(),n=d.useRef(t);return d.useLayoutEffect(()=>{n.current=t},[t]),d.useLayoutEffect(()=>{let r=!1;const s=e&&"current"in e?e.current:e;if(!s)return $e;const l=(a,u)=>{r||n.current(a,u)};return o.subscribe(s,l),()=>{r=!0,o.unsubscribe(s,l)}},[e,o]),o.observer},bo=e=>{const t=d.useRef(null),o=d.useRef(null),n=d.useCallback(()=>{if(!t.current)return;const l=o.current,a=t.current;if(a!==null&&l!==null){const u=a.getAttribute("data-original");a.textContent!==u&&(a.textContent=u);const h=a.textContent,f=a.offsetWidth,m=l.offsetWidth;if(f>m&&h){const b=h.length,x=f/b,k=Math.ceil((f-m)/x)/2+1.5,v=Math.floor(b/2-k),$=Math.ceil(b/2+k),C=h.substr(0,v),S=h.substr($);a.textContent=`${C.trim()}...${S.trim()}`}}},[]),r=d.useCallback(l=>{n()},[n]);$s(o,r),d.useEffect(()=>n(),[e.children,n]);const s=d.useCallback(l=>{t.current=l,o.current=(l==null?void 0:l.parentElement)??null},[]);return i.jsx(du,{"data-original":e.children,ref:s,...e})},du=g(E)`
1380
+ `,Qd=e=>i.jsx(vn,{css:Jd,...e}),eu=new RegExp(/^[a-zA-Z0-9 _.-]*$/),vs=new RegExp(/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/),tu=new RegExp(/^\d+$/),ou=new RegExp(/^\S*$/),nu=new RegExp(/^[a-zA-Z].*/),ks=new RegExp(/^[-a-zA-Z0-9-_'().-]+(\s+[-a-zA-Z0-9-_'().-]+)*$/);var ws=(e=>(e.email="email",e))(ws||{});const ru=()=>({email:e=>vs.test(e)}),su=12;var Wt=(e=>(e.noDigit="noDigit",e.noUpperCase="noUpperCase",e.noSpecialCharacter="noSpecialCharacter",e.tooSimilar="tooSimilar",e))(Wt||{});const iu=(e,t)=>({...e?{tooSimilar:(o,n)=>{const r=n[t??"password_current"];return r?o!==r:!0}}:{tooSimilar:()=>!0},noDigit:o=>new RegExp(/\d/).test(o),noSpecialCharacter:o=>new RegExp(/[!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~]+/).test(o),noUpperCase:o=>new RegExp(/[A-Z]+/).test(o)}),Cs=e=>typeof e=="object"&&e!==null&&"message"in e&&typeof e.message=="string",au=e=>{if(Cs(e))return e.message},lu=()=>{let e=!1,t=[];const o=new Map,n=new window.ResizeObserver((r,s)=>{t=t.concat(r),e||window.requestAnimationFrame(()=>{const l=new Set;t.forEach(a=>{if(!l.has(a.target)){l.add(a.target);const u=o.get(a.target);u&&u.forEach(h=>h(a,s))}}),t=[],e=!1}),e=!0});return{observer:n,subscribe(r,s){n.observe(r);const l=o.get(r)??[];l.push(s),o.set(r,l)},unsubscribe(r,s){const l=o.get(r)??[];if(l.length===1){n.unobserve(r),o.delete(r);return}const a=l.indexOf(s);a!==-1&&l.splice(a,1),o.set(r,l)}}};let Oo;const cu=()=>Oo||(Oo=lu()),$s=(e,t)=>{const o=cu(),n=d.useRef(t);return d.useLayoutEffect(()=>{n.current=t},[t]),d.useLayoutEffect(()=>{let r=!1;const s=e&&"current"in e?e.current:e;if(!s)return Se;const l=(a,u)=>{r||n.current(a,u)};return o.subscribe(s,l),()=>{r=!0,o.unsubscribe(s,l)}},[e,o]),o.observer},bo=e=>{const t=d.useRef(null),o=d.useRef(null),n=d.useCallback(()=>{if(!t.current)return;const l=o.current,a=t.current;if(a!==null&&l!==null){const u=a.getAttribute("data-original");a.textContent!==u&&(a.textContent=u);const p=a.textContent,f=a.offsetWidth,m=l.offsetWidth;if(f>m&&p){const b=p.length,x=f/b,k=Math.ceil((f-m)/x)/2+1.5,v=Math.floor(b/2-k),$=Math.ceil(b/2+k),C=p.substr(0,v),S=p.substr($);a.textContent=`${C.trim()}...${S.trim()}`}}},[]),r=d.useCallback(l=>{n()},[n]);$s(o,r),d.useEffect(()=>n(),[e.children,n]);const s=d.useCallback(l=>{t.current=l,o.current=(l==null?void 0:l.parentElement)??null},[]);return i.jsx(du,{"data-original":e.children,ref:s,...e})},du=g(E)`
1381
1381
  white-space: nowrap;
1382
1382
  word-break: keep-all;
1383
1383
  overflow: visible;
@@ -1390,7 +1390,7 @@
1390
1390
  ${({orientation:e})=>e==="horizontal"?"grid-template-columns: auto 2px auto;":"grid-template-rows: auto 2px auto;"}
1391
1391
  `,Ss=g.div`
1392
1392
  overflow: auto;
1393
- `,pu=g(Ss)``,hu=g(Ss)``,fu=g.div`
1393
+ `,hu=g(Ss)``,pu=g(Ss)``,fu=g.div`
1394
1394
  ${({orientation:e})=>e==="horizontal"?"width: 1px; cursor: col-resize;":"height: 1px; cursor: row-resize;"}
1395
1395
 
1396
1396
  background-color: ${c("color-grey20")};
@@ -1404,7 +1404,7 @@
1404
1404
  ${({orientation:e})=>e==="horizontal"?"top: 0; bottom: 0; left: -4px; right: -4px;":"left: 0; right: 0; top: -4px; bottom: -4px;"}
1405
1405
  cursor: inherit;
1406
1406
  }
1407
- `;function gu(e,t){let o,n;return function(...r){const s=this;n?(clearTimeout(o),o=setTimeout(function(){Date.now()-n>=t&&(e.apply(s,r),n=Date.now())},t-(Date.now()-n))):(e.apply(s,r),n=Date.now())}}const mu=({initialStartSizePct:e=50,startClampSizePx:t=210,minStartSizePct:o=10,minEndSizePct:n=10,startContent:r,endContent:s,orientation:l="horizontal"})=>{const a=d.useRef(null),[u,p]=d.useState(null);d.useEffect(()=>{if(a.current&&u===null){const y=a.current.getBoundingClientRect(),k=l==="horizontal"?y.width:y.height,v=e/100*k,$=Math.max(t,v),C=$/k*100;p($);const S=C,w=100-C;l==="horizontal"?a.current.style.gridTemplateColumns=`${S}% 2px ${w}%`:a.current.style.gridTemplateRows=`${S}% 2px ${w}%`}},[e,t,u,l]);const h=d.useCallback(()=>{if(!a.current||u===null)return;const y=a.current.getBoundingClientRect(),k=l==="horizontal"?y.width:y.height;let v=Math.round(u/k*100),$=100-v;if($<n){$=n,v=100-$;const C=Math.round(v/100*k);p(C)}if(v<o){v=o,$=100-v;const C=Math.round(v/100*k);p(C)}l==="horizontal"?a.current.style.gridTemplateColumns=`${u}px 2px auto`:a.current.style.gridTemplateRows=`${u}px 2px auto`},[u,o,n,l]),f=d.useCallback(gu(h,50),[h]);d.useEffect(()=>(window.addEventListener("resize",f),()=>window.removeEventListener("resize",f)),[f]);const m=y=>{y.preventDefault(),document.addEventListener("mousemove",b),document.addEventListener("mouseup",x)},b=y=>{if(!a.current)return;const k=a.current.getBoundingClientRect(),v=l==="horizontal"?k.width:k.height,$=l==="horizontal"?y.clientX-k.left:y.clientY-k.top,C=Math.max(t,$),S=Math.round(C/v*100),w=100-S;S>=o&&w>=n&&(p($),l==="horizontal"?a.current.style.gridTemplateColumns=`${S}% 2px ${w}%`:a.current.style.gridTemplateRows=`${S}% 2px ${w}%`)},x=()=>{document.removeEventListener("mousemove",b),document.removeEventListener("mouseup",x)};return i.jsxs(uu,{ref:a,orientation:l,children:[i.jsx(pu,{children:r}),i.jsx(fu,{onMouseDown:m,orientation:l}),i.jsx(hu,{children:s})]})},[_e]=M(["radio-button"]),kn=d.forwardRef(({checked:e,onChange:t,...o},n)=>i.jsx(bu,{onClick:t,ref:n,readOnly:!0,type:"radio",checked:!!e,...o})),bu=g.input`
1407
+ `;function gu(e,t){let o,n;return function(...r){const s=this;n?(clearTimeout(o),o=setTimeout(function(){Date.now()-n>=t&&(e.apply(s,r),n=Date.now())},t-(Date.now()-n))):(e.apply(s,r),n=Date.now())}}const mu=({initialStartSizePct:e=50,startClampSizePx:t=210,minStartSizePct:o=10,minEndSizePct:n=10,startContent:r,endContent:s,orientation:l="horizontal"})=>{const a=d.useRef(null),[u,h]=d.useState(null);d.useEffect(()=>{if(a.current&&u===null){const y=a.current.getBoundingClientRect(),k=l==="horizontal"?y.width:y.height,v=e/100*k,$=Math.max(t,v),C=$/k*100;h($);const S=C,w=100-C;l==="horizontal"?a.current.style.gridTemplateColumns=`${S}% 2px ${w}%`:a.current.style.gridTemplateRows=`${S}% 2px ${w}%`}},[e,t,u,l]);const p=d.useCallback(()=>{if(!a.current||u===null)return;const y=a.current.getBoundingClientRect(),k=l==="horizontal"?y.width:y.height;let v=Math.round(u/k*100),$=100-v;if($<n){$=n,v=100-$;const C=Math.round(v/100*k);h(C)}if(v<o){v=o,$=100-v;const C=Math.round(v/100*k);h(C)}l==="horizontal"?a.current.style.gridTemplateColumns=`${u}px 2px auto`:a.current.style.gridTemplateRows=`${u}px 2px auto`},[u,o,n,l]),f=d.useCallback(gu(p,50),[p]);d.useEffect(()=>(window.addEventListener("resize",f),()=>window.removeEventListener("resize",f)),[f]);const m=y=>{y.preventDefault(),document.addEventListener("mousemove",b),document.addEventListener("mouseup",x)},b=y=>{if(!a.current)return;const k=a.current.getBoundingClientRect(),v=l==="horizontal"?k.width:k.height,$=l==="horizontal"?y.clientX-k.left:y.clientY-k.top,C=Math.max(t,$),S=Math.round(C/v*100),w=100-S;S>=o&&w>=n&&(h($),l==="horizontal"?a.current.style.gridTemplateColumns=`${S}% 2px ${w}%`:a.current.style.gridTemplateRows=`${S}% 2px ${w}%`)},x=()=>{document.removeEventListener("mousemove",b),document.removeEventListener("mouseup",x)};return i.jsxs(uu,{ref:a,orientation:l,children:[i.jsx(hu,{children:r}),i.jsx(fu,{onMouseDown:m,orientation:l}),i.jsx(pu,{children:s})]})},[_e]=M(["radio-button"]),kn=d.forwardRef(({checked:e,onChange:t,...o},n)=>i.jsx(bu,{onClick:t,ref:n,readOnly:!0,type:"radio",checked:!!e,...o})),bu=g.input`
1408
1408
  appearance: none;
1409
1409
  -webkit-appearance: none;
1410
1410
  margin: 0;
@@ -1438,7 +1438,7 @@
1438
1438
  }
1439
1439
  background-color: ${_e("background-color-disabled")};
1440
1440
  }
1441
- `;function ot(e,t){if(!e)throw console.error(t),Error(t)}function xu(e,t=document){var n;if(t instanceof HTMLElement&&((n=t==null?void 0:t.dataset)==null?void 0:n.resizablePanelGroupId)===e)return t;const o=t.querySelector(`[data-resizable-panel-group][data-resizable-panel-group-id="${e}"]`);return o||null}const yu=e=>e.type.startsWith("mouse"),vu=e=>e.type.startsWith("pointer"),xo=e=>{if(vu(e)){if(e.isPrimary)return{x:e.clientX,y:e.clientY}}else if(yu(e))return{x:e.clientX,y:e.clientY};return{x:1/0,y:1/0}},js=(e,t)=>{const o=e==="horizontal",{x:n,y:r}=xo(t);return o?n:r},Is=(e,t=document)=>{const o=t.querySelector(`[data-resizable-panel-group-handle-id="${e}"]`);return o||null},ku=(e,t,o,n,r)=>{const s=Is(t,r);ot(s,`No resize handle element found for id "${t}"`);const l=s.getAttribute("data-resizable-panel-group-id");ot(l,"Resize handle element has no group id attribute");const{initialCursorPosition:a}=n,u=js(o,e),p=xu(l,r);return ot(p,`No group element found for id "${l}"`),u-a},wu=(e,t,o,n,r)=>n==null?0:ku(e,t,o,n,r),cr=e=>{if(!e||e.dataset.resizablePanelGroupPanel===void 0)return!1;const t=window.getComputedStyle(e);return t.flex!=="1"&&t.flexGrow!=="1"},dr=(e,t,o=document)=>{const n=Array.from(o.querySelectorAll(`[data-resizable-panel-group-element][data-resizable-panel-group-id="${t}"]`)),r=n.findIndex(s=>!!(s.dataset&&s.dataset.resizablePanelGroupHandleId===e));if(r>=0){const s=n[r-1];if(cr(s))return{element:s,panelPosition:"left"};const l=n[r+1];if(cr(l))return{element:l,panelPosition:"right"}}return null},Ro=(e,t=document)=>Array.from(t.querySelectorAll(`[data-resizable-panel-group-element][data-resizable-panel-group-id="${e}"]`)).filter(n=>n.dataset&&n.dataset.resizablePanelGroupPanel!==void 0),Pt=(e,t,o)=>{const n=e.dataset[t];let r;if(n)if(n.includes("px"))r=Number(n.replace("px",""));else if(n.includes("%")){if(o){const s=Number(n.replace("%",""));r=o*(s/100)}}else r=Number(n);return r},Cu=(e,t,o,n,r,s)=>{t==="vertical"?(e.style.height=`${o}px`,r&&(e.style.minHeight=`${r}px`),s&&(e.style.maxHeight=`${s}px`)):(e.style.width=`${o}px`,r&&(e.style.minWidth=`${r}px`),s&&(e.style.maxWidth=`${s}px`)),e.setAttribute("data-collapsed",`${n}`)},No=(e,t,o,n)=>{const r=t==="horizontal"?e.getBoundingClientRect().width:e.getBoundingClientRect().height,s=e.parentElement,l=t==="horizontal"?s==null?void 0:s.getBoundingClientRect().width:s==null?void 0:s.getBoundingClientRect().height,a=Pt(e,"resizablePanelMinSize",l),u=Pt(e,"resizablePanelMaxSize",l),p=Pt(e,"resizablePanelCollapsedSize",l);let h=o??r;const f=a?a*.33:50;a&&r===a?n&&h<a&&p&&a-h>f?h=p:h<a&&(h=a):u&&r===u?h>u&&(h=u):p&&r===p&&(!n&&h>p&&a&&h-p>f?h=a:h=p);const m=h===p;h===r||!l||Cu(e,t,h,m,m?p:a,u)},Ds=d.createContext(null),_s=({children:e,direction:t,onResizeEnd:o})=>{const n=d.useId(),r=d.useRef(null),[s,l]=d.useState(null),a=d.useRef({dragState:s,id:n,initialResizePanelSize:null,direction:t,lastResizedPanelId:null,panelPosition:"left"});d.useLayoutEffect(()=>{a.current.direction=t,a.current.dragState=s,a.current.id=n});const u=d.useCallback((b,x)=>{const{direction:y}=a.current;if(!r.current)return;const k=Is(b,r.current);ot(k,`Drag handle element not found for id "${b}"`);const v=js(y,x);l({dragHandleId:b,dragHandleRect:k.getBoundingClientRect(),initialCursorPosition:v});const $=dr(b,a.current.id,r.current);if($){const{element:C,panelPosition:S}=$,w=C.getBoundingClientRect();a.current.initialResizePanelSize=y==="vertical"?w.height:w.width,a.current.lastResizedPanelId=C.dataset.resizablePanelId??null,a.current.panelPosition=S}},[]),p=d.useCallback(()=>{const{direction:b,lastResizedPanelId:x}=a.current;if(o&&x&&r.current){const k=Ro(a.current.id,r.current).find(v=>v.dataset.resizablePanelId===x);if(k){const v=k.getBoundingClientRect(),$=b==="vertical"?v.height:v.width;o(x,$)}}l(null),a.current.initialResizePanelSize=null,a.current.lastResizedPanelId=null,a.current.panelPosition="left"},[o]),h=d.useCallback(b=>{const{direction:x}=a.current,k=Ro(a.current.id,r.current??void 0).find(v=>v.dataset.resizablePanelId===b);if(k){const v=k.parentElement,$=x==="horizontal"?v==null?void 0:v.getBoundingClientRect().width:v==null?void 0:v.getBoundingClientRect().height,C=k.dataset.collapsed==="true",S=Pt(k,"resizablePanelMinSize",$),w=Pt(k,"resizablePanelCollapsedSize",$);No(k,x,C?S:w,!C)}},[]);d.useEffect(()=>{const b=()=>{Ro(a.current.id,r.current??void 0).forEach(y=>{No(y,a.current.direction)})};return window.addEventListener("resize",b),()=>{window.removeEventListener("resize",b)}},[]);const f=d.useCallback(b=>x=>{x.preventDefault();const y=r.current;if(!y)return()=>null;const{direction:k,dragState:v,panelPosition:$}=a.current;let C=wu(x,b,k,v,y);if($==="right"&&(C=-C),C!==0&&r.current){const S=dr(b,a.current.id,r.current);if(S&&a.current.initialResizePanelSize!==null){const{element:w}=S,I=a.current.initialResizePanelSize;let j=I+C;j=j<0?0:j,No(w,k,j,I>j)}}},[]),m=d.useMemo(()=>({id:n,startDragging:u,stopDragging:p,direction:t,registerResizeHandle:f,togglePanelCollapse:h}),[n,u,p,t,f,h]);return i.jsx(Ds.Provider,{value:m,children:e(r,n)})},wn=()=>{const e=d.useContext(Ds);if(!e)throw new Error("Unable to use ResizablePanelGroupContext outside of a ResizablePanelGroupContextProvider");return e},Ts=({children:e,direction:t,className:o,onResizeEnd:n})=>i.jsx(_s,{direction:t,onResizeEnd:n,children:(r,s)=>i.jsx($u,{"data-resizable-panel-group":"","data-resizable-panel-group-id":s,className:Dt(o,{isVertical:t==="vertical"}),ref:r,children:e})}),$u=g.div`
1441
+ `;function nt(e,t){if(!e)throw console.error(t),Error(t)}function xu(e,t=document){var n;if(t instanceof HTMLElement&&((n=t==null?void 0:t.dataset)==null?void 0:n.resizablePanelGroupId)===e)return t;const o=t.querySelector(`[data-resizable-panel-group][data-resizable-panel-group-id="${e}"]`);return o||null}const yu=e=>e.type.startsWith("mouse"),vu=e=>e.type.startsWith("pointer"),xo=e=>{if(vu(e)){if(e.isPrimary)return{x:e.clientX,y:e.clientY}}else if(yu(e))return{x:e.clientX,y:e.clientY};return{x:1/0,y:1/0}},js=(e,t)=>{const o=e==="horizontal",{x:n,y:r}=xo(t);return o?n:r},Is=(e,t=document)=>{const o=t.querySelector(`[data-resizable-panel-group-handle-id="${e}"]`);return o||null},ku=(e,t,o,n,r)=>{const s=Is(t,r);nt(s,`No resize handle element found for id "${t}"`);const l=s.getAttribute("data-resizable-panel-group-id");nt(l,"Resize handle element has no group id attribute");const{initialCursorPosition:a}=n,u=js(o,e),h=xu(l,r);return nt(h,`No group element found for id "${l}"`),u-a},wu=(e,t,o,n,r)=>n==null?0:ku(e,t,o,n,r),cr=e=>{if(!e||e.dataset.resizablePanelGroupPanel===void 0)return!1;const t=window.getComputedStyle(e);return t.flex!=="1"&&t.flexGrow!=="1"},dr=(e,t,o=document)=>{const n=Array.from(o.querySelectorAll(`[data-resizable-panel-group-element][data-resizable-panel-group-id="${t}"]`)),r=n.findIndex(s=>!!(s.dataset&&s.dataset.resizablePanelGroupHandleId===e));if(r>=0){const s=n[r-1];if(cr(s))return{element:s,panelPosition:"left"};const l=n[r+1];if(cr(l))return{element:l,panelPosition:"right"}}return null},Ro=(e,t=document)=>Array.from(t.querySelectorAll(`[data-resizable-panel-group-element][data-resizable-panel-group-id="${e}"]`)).filter(n=>n.dataset&&n.dataset.resizablePanelGroupPanel!==void 0),Pt=(e,t,o)=>{const n=e.dataset[t];let r;if(n)if(n.includes("px"))r=Number(n.replace("px",""));else if(n.includes("%")){if(o){const s=Number(n.replace("%",""));r=o*(s/100)}}else r=Number(n);return r},Cu=(e,t,o,n,r,s)=>{t==="vertical"?(e.style.height=`${o}px`,r&&(e.style.minHeight=`${r}px`),s&&(e.style.maxHeight=`${s}px`)):(e.style.width=`${o}px`,r&&(e.style.minWidth=`${r}px`),s&&(e.style.maxWidth=`${s}px`)),e.setAttribute("data-collapsed",`${n}`)},No=(e,t,o,n)=>{const r=t==="horizontal"?e.getBoundingClientRect().width:e.getBoundingClientRect().height,s=e.parentElement,l=t==="horizontal"?s==null?void 0:s.getBoundingClientRect().width:s==null?void 0:s.getBoundingClientRect().height,a=Pt(e,"resizablePanelMinSize",l),u=Pt(e,"resizablePanelMaxSize",l),h=Pt(e,"resizablePanelCollapsedSize",l);let p=o??r;const f=a?a*.33:50;a&&r===a?n&&p<a&&h&&a-p>f?p=h:p<a&&(p=a):u&&r===u?p>u&&(p=u):h&&r===h&&(!n&&p>h&&a&&p-h>f?p=a:p=h);const m=p===h;p===r||!l||Cu(e,t,p,m,m?h:a,u)},Ds=d.createContext(null),_s=({children:e,direction:t,onResizeEnd:o})=>{const n=d.useId(),r=d.useRef(null),[s,l]=d.useState(null),a=d.useRef({dragState:s,id:n,initialResizePanelSize:null,direction:t,lastResizedPanelId:null,panelPosition:"left"});d.useLayoutEffect(()=>{a.current.direction=t,a.current.dragState=s,a.current.id=n});const u=d.useCallback((b,x)=>{const{direction:y}=a.current;if(!r.current)return;const k=Is(b,r.current);nt(k,`Drag handle element not found for id "${b}"`);const v=js(y,x);l({dragHandleId:b,dragHandleRect:k.getBoundingClientRect(),initialCursorPosition:v});const $=dr(b,a.current.id,r.current);if($){const{element:C,panelPosition:S}=$,w=C.getBoundingClientRect();a.current.initialResizePanelSize=y==="vertical"?w.height:w.width,a.current.lastResizedPanelId=C.dataset.resizablePanelId??null,a.current.panelPosition=S}},[]),h=d.useCallback(()=>{const{direction:b,lastResizedPanelId:x}=a.current;if(o&&x&&r.current){const k=Ro(a.current.id,r.current).find(v=>v.dataset.resizablePanelId===x);if(k){const v=k.getBoundingClientRect(),$=b==="vertical"?v.height:v.width;o(x,$)}}l(null),a.current.initialResizePanelSize=null,a.current.lastResizedPanelId=null,a.current.panelPosition="left"},[o]),p=d.useCallback(b=>{const{direction:x}=a.current,k=Ro(a.current.id,r.current??void 0).find(v=>v.dataset.resizablePanelId===b);if(k){const v=k.parentElement,$=x==="horizontal"?v==null?void 0:v.getBoundingClientRect().width:v==null?void 0:v.getBoundingClientRect().height,C=k.dataset.collapsed==="true",S=Pt(k,"resizablePanelMinSize",$),w=Pt(k,"resizablePanelCollapsedSize",$);No(k,x,C?S:w,!C)}},[]);d.useEffect(()=>{const b=()=>{Ro(a.current.id,r.current??void 0).forEach(y=>{No(y,a.current.direction)})};return window.addEventListener("resize",b),()=>{window.removeEventListener("resize",b)}},[]);const f=d.useCallback(b=>x=>{x.preventDefault();const y=r.current;if(!y)return()=>null;const{direction:k,dragState:v,panelPosition:$}=a.current;let C=wu(x,b,k,v,y);if($==="right"&&(C=-C),C!==0&&r.current){const S=dr(b,a.current.id,r.current);if(S&&a.current.initialResizePanelSize!==null){const{element:w}=S,I=a.current.initialResizePanelSize;let j=I+C;j=j<0?0:j,No(w,k,j,I>j)}}},[]),m=d.useMemo(()=>({id:n,startDragging:u,stopDragging:h,direction:t,registerResizeHandle:f,togglePanelCollapse:p}),[n,u,h,t,f,p]);return i.jsx(Ds.Provider,{value:m,children:e(r,n)})},wn=()=>{const e=d.useContext(Ds);if(!e)throw new Error("Unable to use ResizablePanelGroupContext outside of a ResizablePanelGroupContextProvider");return e},Ts=({children:e,direction:t,className:o,onResizeEnd:n})=>i.jsx(_s,{direction:t,onResizeEnd:n,children:(r,s)=>i.jsx($u,{"data-resizable-panel-group":"","data-resizable-panel-group-id":s,className:Dt(o,{isVertical:t==="vertical"}),ref:r,children:e})}),$u=g.div`
1442
1442
  width: 100%;
1443
1443
  height: 100%;
1444
1444
  overflow: auto;
@@ -1448,12 +1448,12 @@
1448
1448
  &.isVertical {
1449
1449
  flex-direction: column;
1450
1450
  }
1451
- `,Cn=({children:e,maxSize:t,minSize:o,defaultSize:n,collapsedSize:r,className:s,panelId:l})=>{const{id:a,direction:u}=wn(),p=typeof t=="string"?t:t?`${t}px`:void 0,h=typeof o=="string"?o:o?`${o}px`:void 0,f=typeof n=="string"?n:n?`${n}px`:void 0;return i.jsx(Su,{className:s,style:u==="horizontal"?{maxWidth:p,minWidth:h,width:f??"auto",height:"100%"}:{maxHeight:p,minHeight:h,height:f??"auto",width:"100%"},"data-resizable-panel-group-element":"","data-resizable-panel-group-panel":"","data-resizable-panel-max-size":t,"data-resizable-panel-min-size":o,"data-resizable-panel-collapsed-size":r,"data-resizable-panel-id":l,"data-resizable-panel-group-id":a,"data-collapsed":!1,children:e})},Su=g.div`
1451
+ `,Cn=({children:e,maxSize:t,minSize:o,defaultSize:n,collapsedSize:r,className:s,panelId:l})=>{const{id:a,direction:u}=wn(),h=typeof t=="string"?t:t?`${t}px`:void 0,p=typeof o=="string"?o:o?`${o}px`:void 0,f=typeof n=="string"?n:n?`${n}px`:void 0;return i.jsx(Su,{className:s,style:u==="horizontal"?{maxWidth:h,minWidth:p,width:f??"auto",height:"100%"}:{maxHeight:h,minHeight:p,height:f??"auto",width:"100%"},"data-resizable-panel-group-element":"","data-resizable-panel-group-panel":"","data-resizable-panel-max-size":t,"data-resizable-panel-min-size":o,"data-resizable-panel-collapsed-size":r,"data-resizable-panel-id":l,"data-resizable-panel-group-id":a,"data-collapsed":!1,children:e})},Su=g.div`
1452
1452
  flex-shrink: 0;
1453
1453
  overflow: clip;
1454
1454
  `,Es=g(Cn)`
1455
1455
  flex: 1;
1456
- `;let tn=null,ft=null;function ju(e){switch(e){case"horizontal":return"ew-resize";case"intersection":return"move";case"vertical":return"ns-resize";default:return"auto"}}function Iu(){ft!==null&&(document.head.removeChild(ft),tn=null,ft=null)}function Fo(e){const t=ju(e);tn!==t&&(tn=t,ft===null&&(ft=document.createElement("style"),document.head.appendChild(ft)),ft.innerHTML=`*{cursor: ${t}!important;}`)}const Du=(e,t,o)=>e.x<t.x+t.width&&e.x+e.width>t.x&&e.y<t.y+t.height&&e.y+e.height>t.y;function _u(e,t){if(e===t)throw new Error("Cannot compare node with itself");const o={a:hr(e),b:hr(t)};let n;for(;o.a.at(-1)===o.b.at(-1);)e=o.a.pop(),t=o.b.pop(),n=e;ot(n,"Stacking order can only be calculated for elements with a common ancestor");const r={a:pr(ur(o.a)),b:pr(ur(o.b))};if(r.a===r.b){const s=n.childNodes,l={a:o.a.at(-1),b:o.b.at(-1)};let a=s.length;for(;a--;){const u=s[a];if(u===l.a)return 1;if(u===l.b)return-1}}return Math.sign(r.a-r.b)}const Tu=/\b(?:position|zIndex|opacity|transform|webkitTransform|mixBlendMode|filter|webkitFilter|isolation)\b/;function Eu(e){const t=getComputedStyle(zs(e)??e).display;return t==="flex"||t==="inline-flex"}function zu(e){const t=getComputedStyle(e);return!!(t.position==="fixed"||t.zIndex!=="auto"&&(t.position!=="static"||Eu(e))||+t.opacity<1||"transform"in t&&t.transform!=="none"||"webkitTransform"in t&&t.webkitTransform!=="none"||"mixBlendMode"in t&&t.mixBlendMode!=="normal"||"filter"in t&&t.filter!=="none"||"webkitFilter"in t&&t.webkitFilter!=="none"||"isolation"in t&&t.isolation==="isolate"||Tu.test(t.willChange)||t.webkitOverflowScrolling==="touch")}function ur(e){let t=e.length;for(;t--;){const o=e[t];if(ot(o,"Missing node"),zu(o))return o}return null}function pr(e){return e&&Number(getComputedStyle(e).zIndex)||0}function hr(e){const t=[];for(;e;)t.push(e),e=zs(e);return t}function zs(e){const{parentNode:t}=e;return t&&t instanceof ShadowRoot?t.host:t}let wt=!1;const Mu=()=>{if(typeof matchMedia=="function")return matchMedia("(pointer:coarse)").matches?"coarse":"fine"},Fe=[],Ut=new Set,Ou=Mu()==="coarse",ct=new Map,Ru=(e,t,o,n)=>{const{ownerDocument:r}=e,s={direction:t,element:e,hitAreaMargins:o,setResizeHandlerState:n},l=ct.get(r)??0;return ct.set(r,l+1),Ut.add(s),uo(),function(){Ut.delete(s);const u=ct.get(r)??1;if(ct.set(r,u-1),uo(),u===1&&ct.delete(r),Fe.includes(s)){const p=Fe.indexOf(s);p>=0&&Fe.splice(p,1),Sn(),n("up",!0,null)}}},$n=({target:e,x:t,y:o})=>{Fe.splice(0);let n=null;e instanceof HTMLElement&&(n=e),Ut.forEach(r=>{const{element:s,hitAreaMargins:l}=r,a=s.getBoundingClientRect(),{bottom:u,left:p,right:h,top:f}=a,m=Ou?l.coarse:l.fine;if(t>=p-m&&t<=h+m&&o>=f-m&&o<=u+m){if(n!==null&&document.contains(n)&&s!==n&&!s.contains(n)&&!n.contains(s)&&_u(n,s)>0){let x=n,y=!1;for(;x&&!x.contains(s);){if(Du(x.getBoundingClientRect(),a)){y=!0;break}x=x.parentElement}if(y)return}Fe.push(r)}})},fr=e=>{const{target:t}=e,{x:o,y:n}=xo(e);wt=!0,$n({target:t,x:o,y:n}),uo(),Fe.length>0&&(po("down",e),e.preventDefault(),e.stopPropagation())},Ot=e=>{const{x:t,y:o}=xo(e);if(wt&&e.buttons===0&&(wt=!1,po("up",e)),!wt){const{target:n}=e;$n({target:n,x:t,y:o})}po("move",e),Sn(),Fe.length>0&&e.preventDefault()},xt=e=>{const{target:t}=e,{x:o,y:n}=xo(e);wt=!1,Fe.length>0&&e.preventDefault(),po("up",e),$n({target:t,x:o,y:n}),Sn(),uo()},uo=()=>{ct.forEach((e,t)=>{const{body:o}=t;o.removeEventListener("contextmenu",xt),o.removeEventListener("pointerdown",fr),o.removeEventListener("pointerleave",Ot),o.removeEventListener("pointermove",Ot)}),window.removeEventListener("pointerup",xt),window.removeEventListener("pointercancel",xt),Ut.size>0&&(wt?(Fe.length>0&&ct.forEach((e,t)=>{const{body:o}=t;e>0&&(o.addEventListener("contextmenu",xt),o.addEventListener("pointerleave",Ot),o.addEventListener("pointermove",Ot))}),window.addEventListener("pointerup",xt),window.addEventListener("pointercancel",xt)):ct.forEach((e,t)=>{const{body:o}=t;e>0&&(o.addEventListener("pointerdown",fr,{capture:!0}),o.addEventListener("pointermove",Ot))}))},po=(e,t)=>{Ut.forEach(o=>{const{setResizeHandlerState:n}=o,r=Fe.includes(o);n(e,r,t)})},Sn=()=>{let e=!1,t=!1;Fe.forEach(o=>{const{direction:n}=o;n==="horizontal"?e=!0:t=!0}),e&&t?Fo("intersection"):e?Fo("horizontal"):t?Fo("vertical"):Iu()},[Ao]=M(["resizable-panels"]),Ms=d.memo(({className:e,disabled:t})=>{const{id:o,startDragging:n,stopDragging:r,direction:s,registerResizeHandle:l}=wn(),a=d.useId(),[u,p]=d.useState("inactive"),[h,f]=d.useState(null),m=d.useRef(null),b=d.useRef({state:u});return d.useLayoutEffect(()=>{b.current.state=u}),d.useEffect(()=>{if(t)f(null);else{const x=l(a);f(()=>x)}},[t,a,l]),d.useEffect(()=>{if(t||h==null)return;const x=m.current;return ot(x,"Element ref not attached"),Ru(x,s,{coarse:15,fine:5},(k,v,$)=>{if(v)switch(k){case"down":{p("drag"),ot($,'Expected event to be defined for "down" action'),n(a,$);break}case"move":{const{state:C}=b.current;C!=="drag"&&p("hover"),ot($,'Expected event to be defined for "move" action'),h($);break}case"up":{p("hover"),r();break}}else p("inactive")})},[s,t,a,h,n,r]),i.jsx(Nu,{"data-resizable-panel-group-element":"","data-resizable-panel-group-id":o,"data-resizable-panel-group-handle-id":a,className:Dt(e,{isVertical:s==="vertical",isHovered:u==="hover",isDragging:u==="drag"}),ref:m})}),Nu=g.div`
1456
+ `;let tn=null,ft=null;function ju(e){switch(e){case"horizontal":return"ew-resize";case"intersection":return"move";case"vertical":return"ns-resize";default:return"auto"}}function Iu(){ft!==null&&(document.head.removeChild(ft),tn=null,ft=null)}function Fo(e){const t=ju(e);tn!==t&&(tn=t,ft===null&&(ft=document.createElement("style"),document.head.appendChild(ft)),ft.innerHTML=`*{cursor: ${t}!important;}`)}const Du=(e,t,o)=>e.x<t.x+t.width&&e.x+e.width>t.x&&e.y<t.y+t.height&&e.y+e.height>t.y;function _u(e,t){if(e===t)throw new Error("Cannot compare node with itself");const o={a:pr(e),b:pr(t)};let n;for(;o.a.at(-1)===o.b.at(-1);)e=o.a.pop(),t=o.b.pop(),n=e;nt(n,"Stacking order can only be calculated for elements with a common ancestor");const r={a:hr(ur(o.a)),b:hr(ur(o.b))};if(r.a===r.b){const s=n.childNodes,l={a:o.a.at(-1),b:o.b.at(-1)};let a=s.length;for(;a--;){const u=s[a];if(u===l.a)return 1;if(u===l.b)return-1}}return Math.sign(r.a-r.b)}const Tu=/\b(?:position|zIndex|opacity|transform|webkitTransform|mixBlendMode|filter|webkitFilter|isolation)\b/;function Eu(e){const t=getComputedStyle(zs(e)??e).display;return t==="flex"||t==="inline-flex"}function zu(e){const t=getComputedStyle(e);return!!(t.position==="fixed"||t.zIndex!=="auto"&&(t.position!=="static"||Eu(e))||+t.opacity<1||"transform"in t&&t.transform!=="none"||"webkitTransform"in t&&t.webkitTransform!=="none"||"mixBlendMode"in t&&t.mixBlendMode!=="normal"||"filter"in t&&t.filter!=="none"||"webkitFilter"in t&&t.webkitFilter!=="none"||"isolation"in t&&t.isolation==="isolate"||Tu.test(t.willChange)||t.webkitOverflowScrolling==="touch")}function ur(e){let t=e.length;for(;t--;){const o=e[t];if(nt(o,"Missing node"),zu(o))return o}return null}function hr(e){return e&&Number(getComputedStyle(e).zIndex)||0}function pr(e){const t=[];for(;e;)t.push(e),e=zs(e);return t}function zs(e){const{parentNode:t}=e;return t&&t instanceof ShadowRoot?t.host:t}let wt=!1;const Mu=()=>{if(typeof matchMedia=="function")return matchMedia("(pointer:coarse)").matches?"coarse":"fine"},Fe=[],Ut=new Set,Ou=Mu()==="coarse",ct=new Map,Ru=(e,t,o,n)=>{const{ownerDocument:r}=e,s={direction:t,element:e,hitAreaMargins:o,setResizeHandlerState:n},l=ct.get(r)??0;return ct.set(r,l+1),Ut.add(s),uo(),function(){Ut.delete(s);const u=ct.get(r)??1;if(ct.set(r,u-1),uo(),u===1&&ct.delete(r),Fe.includes(s)){const h=Fe.indexOf(s);h>=0&&Fe.splice(h,1),Sn(),n("up",!0,null)}}},$n=({target:e,x:t,y:o})=>{Fe.splice(0);let n=null;e instanceof HTMLElement&&(n=e),Ut.forEach(r=>{const{element:s,hitAreaMargins:l}=r,a=s.getBoundingClientRect(),{bottom:u,left:h,right:p,top:f}=a,m=Ou?l.coarse:l.fine;if(t>=h-m&&t<=p+m&&o>=f-m&&o<=u+m){if(n!==null&&document.contains(n)&&s!==n&&!s.contains(n)&&!n.contains(s)&&_u(n,s)>0){let x=n,y=!1;for(;x&&!x.contains(s);){if(Du(x.getBoundingClientRect(),a)){y=!0;break}x=x.parentElement}if(y)return}Fe.push(r)}})},fr=e=>{const{target:t}=e,{x:o,y:n}=xo(e);wt=!0,$n({target:t,x:o,y:n}),uo(),Fe.length>0&&(ho("down",e),e.preventDefault(),e.stopPropagation())},Ot=e=>{const{x:t,y:o}=xo(e);if(wt&&e.buttons===0&&(wt=!1,ho("up",e)),!wt){const{target:n}=e;$n({target:n,x:t,y:o})}ho("move",e),Sn(),Fe.length>0&&e.preventDefault()},xt=e=>{const{target:t}=e,{x:o,y:n}=xo(e);wt=!1,Fe.length>0&&e.preventDefault(),ho("up",e),$n({target:t,x:o,y:n}),Sn(),uo()},uo=()=>{ct.forEach((e,t)=>{const{body:o}=t;o.removeEventListener("contextmenu",xt),o.removeEventListener("pointerdown",fr),o.removeEventListener("pointerleave",Ot),o.removeEventListener("pointermove",Ot)}),window.removeEventListener("pointerup",xt),window.removeEventListener("pointercancel",xt),Ut.size>0&&(wt?(Fe.length>0&&ct.forEach((e,t)=>{const{body:o}=t;e>0&&(o.addEventListener("contextmenu",xt),o.addEventListener("pointerleave",Ot),o.addEventListener("pointermove",Ot))}),window.addEventListener("pointerup",xt),window.addEventListener("pointercancel",xt)):ct.forEach((e,t)=>{const{body:o}=t;e>0&&(o.addEventListener("pointerdown",fr,{capture:!0}),o.addEventListener("pointermove",Ot))}))},ho=(e,t)=>{Ut.forEach(o=>{const{setResizeHandlerState:n}=o,r=Fe.includes(o);n(e,r,t)})},Sn=()=>{let e=!1,t=!1;Fe.forEach(o=>{const{direction:n}=o;n==="horizontal"?e=!0:t=!0}),e&&t?Fo("intersection"):e?Fo("horizontal"):t?Fo("vertical"):Iu()},[Ao]=M(["resizable-panels"]),Ms=d.memo(({className:e,disabled:t})=>{const{id:o,startDragging:n,stopDragging:r,direction:s,registerResizeHandle:l}=wn(),a=d.useId(),[u,h]=d.useState("inactive"),[p,f]=d.useState(null),m=d.useRef(null),b=d.useRef({state:u});return d.useLayoutEffect(()=>{b.current.state=u}),d.useEffect(()=>{if(t)f(null);else{const x=l(a);f(()=>x)}},[t,a,l]),d.useEffect(()=>{if(t||p==null)return;const x=m.current;return nt(x,"Element ref not attached"),Ru(x,s,{coarse:15,fine:5},(k,v,$)=>{if(v)switch(k){case"down":{h("drag"),nt($,'Expected event to be defined for "down" action'),n(a,$);break}case"move":{const{state:C}=b.current;C!=="drag"&&h("hover"),nt($,'Expected event to be defined for "move" action'),p($);break}case"up":{h("hover"),r();break}}else h("inactive")})},[s,t,a,p,n,r]),i.jsx(Nu,{"data-resizable-panel-group-element":"","data-resizable-panel-group-id":o,"data-resizable-panel-group-handle-id":a,className:Dt(e,{isVertical:s==="vertical",isHovered:u==="hover",isDragging:u==="drag"}),ref:m})}),Nu=g.div`
1457
1457
  height: 100%;
1458
1458
  width: 1px;
1459
1459
  flex-shrink: 0;
@@ -1474,7 +1474,7 @@
1474
1474
  display: grid;
1475
1475
  place-items: center;
1476
1476
  z-index: 1;
1477
- `,Au=[O.flip()],Rs=[O.flip(),O.size({apply({rects:e,elements:t}){Object.assign(t.floating.style,{width:`${e.reference.width}px`})}})],[on]=M(["select"]),jn=d.createContext(null),In=()=>{const e=d.useContext(jn);if(e===null)throw new Error("Select context used outside of the SelectContextProvider");return e},Lu=()=>Promise.resolve(),Et=({children:e,onSelect:t,Reference:o,disabled:n,selectedIndex:r,onSelectedIndexChange:s,className:l,matchReferenceWidth:a,isFocusTrapDisabled:u,menuPlacement:p,onOpenChange:h,onBeforeOpen:f=Lu,showOpenState:m=!1})=>{const[b,x]=d.useState(!1),[y,k]=d.useState(null),[v,$]=d.useState(null),C=r??v,S=s??$,w=d.useCallback(Q=>{Q?f().then(()=>{x(Q),h&&h(Q)}):(x(Q),h&&h(Q))},[f,h]),{refs:I,floatingStyles:j,context:D}=O.useFloating({placement:p||"bottom-end",open:b,onOpenChange:w,whileElementsMounted:O.autoUpdate,middleware:a?Rs:Au}),L=d.useRef([]),U=d.useRef([]),P=d.useCallback(Q=>{var G;S(Q),Q!==null&&t(((G=L.current[Q])==null?void 0:G.dataset.key)||""),x(!1),h&&h(!1)},[h,t,S]),B=O.useListNavigation(D,{listRef:L,activeIndex:y,selectedIndex:C,focusItemOnHover:!u,focusItemOnOpen:!u,onNavigate:k}),Z=O.useClick(D,{enabled:!n}),ie=O.useDismiss(D),J=O.useRole(D,{role:"listbox"}),{getReferenceProps:X,getFloatingProps:je,getItemProps:le}=O.useInteractions([B,Z,ie,J]),pe=d.useMemo(()=>({activeIndex:y,selectedIndex:C,open:b,getItemProps:le,handleSelect:P,setIsOpen:x}),[y,b,C,le,P]);return i.jsxs(jn.Provider,{value:pe,children:[i.jsx(Bu,{ref:I.setReference,tabIndex:0,...X({onClick(Q){Q.stopPropagation()}}),children:m?i.jsxs(Pu,{children:[o??i.jsx(ae,{className:"select-reference",size:"sm",iconId:"Ellipsis",color:"blue"}),i.jsx(R,{size:"xsm",iconId:b?"CaretUp":"CaretDown"})]}):o??i.jsx(ae,{className:"select-reference",size:"sm",iconId:"Ellipsis",color:"blue"})}),b&&i.jsx(O.FloatingPortal,{children:i.jsx(O.FloatingFocusManager,{disabled:u,context:D,modal:!1,children:i.jsx(Wu,{ref:I.setFloating,style:j,className:l,...je(),children:i.jsx(O.FloatingList,{elementsRef:L,labelsRef:U,children:e})})})})]})},Bu=g.div`
1477
+ `,Au=[O.flip()],Rs=[O.flip(),O.size({apply({rects:e,elements:t}){Object.assign(t.floating.style,{width:`${e.reference.width}px`})}})],[on]=M(["select"]),jn=d.createContext(null),In=()=>{const e=d.useContext(jn);if(e===null)throw new Error("Select context used outside of the SelectContextProvider");return e},Lu=()=>Promise.resolve(),Et=({children:e,onSelect:t,Reference:o,disabled:n,selectedIndex:r,onSelectedIndexChange:s,className:l,matchReferenceWidth:a,isFocusTrapDisabled:u,menuPlacement:h,onOpenChange:p,onBeforeOpen:f=Lu,showOpenState:m=!1})=>{const[b,x]=d.useState(!1),[y,k]=d.useState(null),[v,$]=d.useState(null),C=r??v,S=s??$,w=d.useCallback(Q=>{Q?f().then(()=>{x(Q),p&&p(Q)}):(x(Q),p&&p(Q))},[f,p]),{refs:I,floatingStyles:j,context:D}=O.useFloating({placement:h||"bottom-end",open:b,onOpenChange:w,whileElementsMounted:O.autoUpdate,middleware:a?Rs:Au}),L=d.useRef([]),U=d.useRef([]),P=d.useCallback(Q=>{var K;S(Q),Q!==null&&t(((K=L.current[Q])==null?void 0:K.dataset.key)||""),x(!1),p&&p(!1)},[p,t,S]),B=O.useListNavigation(D,{listRef:L,activeIndex:y,selectedIndex:C,focusItemOnHover:!u,focusItemOnOpen:!u,onNavigate:k}),Z=O.useClick(D,{enabled:!n}),ie=O.useDismiss(D),J=O.useRole(D,{role:"listbox"}),{getReferenceProps:X,getFloatingProps:je,getItemProps:le}=O.useInteractions([B,Z,ie,J]),he=d.useMemo(()=>({activeIndex:y,selectedIndex:C,open:b,getItemProps:le,handleSelect:P,setIsOpen:x}),[y,b,C,le,P]);return i.jsxs(jn.Provider,{value:he,children:[i.jsx(Bu,{ref:I.setReference,tabIndex:0,...X({onClick(Q){Q.stopPropagation()}}),children:m?i.jsxs(Pu,{children:[o??i.jsx(ae,{className:"select-reference",size:"sm",iconId:"Ellipsis",color:"blue"}),i.jsx(R,{size:"xsm",iconId:b?"CaretUp":"CaretDown"})]}):o??i.jsx(ae,{className:"select-reference",size:"sm",iconId:"Ellipsis",color:"blue"})}),b&&i.jsx(O.FloatingPortal,{children:i.jsx(O.FloatingFocusManager,{disabled:u,context:D,modal:!1,children:i.jsx(Wu,{ref:I.setFloating,style:j,className:l,...je(),children:i.jsx(O.FloatingList,{elementsRef:L,labelsRef:U,children:e})})})})]})},Bu=g.div`
1478
1478
  align-items: center;
1479
1479
  display: flex;
1480
1480
  font-size: ${on("font-size")};
@@ -1494,14 +1494,14 @@
1494
1494
  align-items: center;
1495
1495
  justify-content: flex-start;
1496
1496
  gap: 2px;
1497
- `,[Be,gr]=M(["option","text"]),dt=d.memo(({label:e,optionKey:t,disabled:o,className:n,prefixIconId:r,prefixIconColor:s,suffixIconId:l,textColor:a,suffixIconColor:u,disableSelectionStyle:p,disableEnterSelection:h})=>{const{activeIndex:f,selectedIndex:m,getItemProps:b,handleSelect:x}=In(),{ref:y,index:k}=O.useListItem({label:t}),v=f!==null&&f!==-1&&f===k,$=!p&&m!==null&&m!==-1&&m===k,C=d.useCallback(S=>{o||(S.stopPropagation(),x(k))},[o,x,k]);return i.jsx(z.ClassNames,{children:({cx:S})=>i.jsxs(Vu,{className:S({isActive:v,isSelected:$,disabled:o},n),ref:y,"data-key":t,role:"option","data-color":a,"aria-selected":v&&$,tabIndex:v?0:-1,...b({onClick:w=>C(w),onKeyDown:!h&&!o?w=>{w.code==="Enter"&&x(k)}:void 0}),children:[!!r&&i.jsx(R,{iconId:r,size:"sm",color:o?"grey":s??"black"}),e,!!l&&i.jsx(Hu,{iconId:l,size:"sm",color:o?"grey":u??"black"})]})})}),Vu=g.div`
1498
- color: ${Be("color")};
1497
+ `,[We,gr]=M(["option","text"]),dt=d.memo(({label:e,optionKey:t,disabled:o,className:n,prefixIconId:r,prefixIconColor:s,suffixIconId:l,textColor:a,suffixIconColor:u,disableSelectionStyle:h,disableEnterSelection:p})=>{const{activeIndex:f,selectedIndex:m,getItemProps:b,handleSelect:x}=In(),{ref:y,index:k}=O.useListItem({label:t}),v=f!==null&&f!==-1&&f===k,$=!h&&m!==null&&m!==-1&&m===k,C=d.useCallback(S=>{o||(S.stopPropagation(),x(k))},[o,x,k]);return i.jsx(z.ClassNames,{children:({cx:S})=>i.jsxs(Vu,{className:S({isActive:v,isSelected:$,disabled:o},n),ref:y,"data-key":t,role:"option","data-color":a,"aria-selected":v&&$,tabIndex:v?0:-1,...b({onClick:w=>C(w),onKeyDown:!p&&!o?w=>{w.code==="Enter"&&x(k)}:void 0}),children:[!!r&&i.jsx(R,{iconId:r,size:"sm",color:o?"grey":s??"black"}),e,!!l&&i.jsx(Hu,{iconId:l,size:"sm",color:o?"grey":u??"black"})]})})}),Vu=g.div`
1498
+ color: ${We("color")};
1499
1499
  cursor: pointer;
1500
1500
  font-size: inherit;
1501
- background-color: ${Be("bg-color")};
1502
- font-family: ${Be("font-family")};
1503
- font-size: ${Be("font-size")};
1504
- padding: ${Be("padding")};
1501
+ background-color: ${We("bg-color")};
1502
+ font-family: ${We("font-family")};
1503
+ font-size: ${We("font-size")};
1504
+ padding: ${We("padding")};
1505
1505
  min-width: 96px;
1506
1506
  line-height: 18px;
1507
1507
  display: flex;
@@ -1511,20 +1511,20 @@
1511
1511
  overflow: hidden;
1512
1512
  outline: 0;
1513
1513
  flex-shrink: 0;
1514
- column-gap: ${Be("column-gap")};
1514
+ column-gap: ${We("column-gap")};
1515
1515
  ${Zr.map(e=>`&[data-color="${e}"] {
1516
1516
  color: ${gr(`color-${e}`)};
1517
1517
  }`).join(`
1518
1518
  `)}
1519
- ${`${gr("body-size",!0)}: ${Be("font-size")}`};
1519
+ ${`${gr("body-size",!0)}: ${We("font-size")}`};
1520
1520
  &.isActive {
1521
- background: ${Be("bg-color-active")};
1521
+ background: ${We("bg-color-active")};
1522
1522
  }
1523
1523
  &.isSelected {
1524
- font-weight: ${Be("font-weight-selected")};
1524
+ font-weight: ${We("font-weight-selected")};
1525
1525
  }
1526
1526
  &.disabled {
1527
- color: ${Be("color-disabled")};
1527
+ color: ${We("color-disabled")};
1528
1528
  cursor: not-allowed;
1529
1529
  }
1530
1530
  `,Hu=g(R)`
@@ -1538,7 +1538,7 @@
1538
1538
 
1539
1539
  --studio-c-icon-button-badge-top: 6px;
1540
1540
  --studio-c-icon-button-badge-right: 6px;
1541
- `,Zu=e=>i.jsx(qu,{badgeBorderColor:"black",...e}),Ns=d.createContext(null),yo=()=>{const e=d.useContext(Ns);if(e===null)throw new Error("Unable to use TabContext outside of a TabProvider");return e},Xu=d.memo(({children:e,activeTab:t,onTabChange:o,defaultActiveTab:n,variant:r="underline"})=>{const[s,l]=d.useState(n),a=o??l,u=t??s,p=d.useMemo(()=>({onTabChange:a,activeTab:u,variant:r}),[u,a,r]);return i.jsx(Ns.Provider,{value:p,children:e})}),[re]=M(["tab"]),Ju=d.memo(({value:e,text:t,disabled:o,iconColor:n,iconId:r,tooltip:s,badge:l,onClose:a,closeable:u,maxWidth:p})=>{const{activeTab:h,onTabChange:f,variant:m}=yo(),b=e===h,x=a!=null&&(u===void 0?!0:u),y=d.useCallback(()=>{b||f(e)},[f,e,b]),k=d.useCallback(v=>{v.stopPropagation(),a==null||a(e)},[a,e]);return i.jsxs(Qu,{"data-value":e,"data-variant":m,"data-active":b,onClick:y,disabled:o,title:s,role:"tab","aria-selected":b,"aria-label":s??t,children:[!!r&&i.jsx(R,{iconId:r,color:n??"black",size:"sm"}),i.jsx(ep,{"data-label":p?t:void 0,style:p?{maxWidth:typeof p=="number"?`${p}px`:p}:void 0,children:i.jsx(E,{color:o||m==="standard"&&!b?"grey":"dark",variant:"body",bold:b,children:t})}),l!==void 0&&i.jsx(tp,{children:l}),x&&i.jsx(op,{onClick:k,"aria-label":`Close ${t}`,title:`Close ${t}`,children:i.jsx(R,{iconId:"Close",size:"xsm"})})]})}),Qu=g.button`
1541
+ `,Zu=e=>i.jsx(qu,{badgeBorderColor:"black",...e}),Ns=d.createContext(null),yo=()=>{const e=d.useContext(Ns);if(e===null)throw new Error("Unable to use TabContext outside of a TabProvider");return e},Xu=d.memo(({children:e,activeTab:t,onTabChange:o,defaultActiveTab:n,variant:r="underline"})=>{const[s,l]=d.useState(n),a=o??l,u=t??s,h=d.useMemo(()=>({onTabChange:a,activeTab:u,variant:r}),[u,a,r]);return i.jsx(Ns.Provider,{value:h,children:e})}),[re]=M(["tab"]),Ju=d.memo(({value:e,text:t,disabled:o,iconColor:n,iconId:r,tooltip:s,badge:l,onClose:a,closeable:u,maxWidth:h})=>{const{activeTab:p,onTabChange:f,variant:m}=yo(),b=e===p,x=a!=null&&(u===void 0?!0:u),y=d.useCallback(()=>{b||f(e)},[f,e,b]),k=d.useCallback(v=>{v.stopPropagation(),a==null||a(e)},[a,e]);return i.jsxs(Qu,{"data-value":e,"data-variant":m,"data-active":b,onClick:y,disabled:o,title:s,role:"tab","aria-selected":b,"aria-label":s??t,children:[!!r&&i.jsx(R,{iconId:r,color:n??"black",size:"sm"}),i.jsx(eh,{"data-label":h?t:void 0,style:h?{maxWidth:typeof h=="number"?`${h}px`:h}:void 0,children:i.jsx(E,{color:o||m==="standard"&&!b?"grey":"dark",variant:"body",bold:b,children:t})}),l!==void 0&&i.jsx(th,{children:l}),x&&i.jsx(oh,{onClick:k,"aria-label":`Close ${t}`,title:`Close ${t}`,children:i.jsx(R,{iconId:"Close",size:"xsm"})})]})}),Qu=g.button`
1542
1542
  cursor: pointer;
1543
1543
  outline: none;
1544
1544
  border: none;
@@ -1580,7 +1580,7 @@
1580
1580
  outline: 2px solid var(--studio-s-color-primary, #0066cc);
1581
1581
  outline-offset: -2px;
1582
1582
  }
1583
- `,ep=g.span`
1583
+ `,eh=g.span`
1584
1584
  overflow: hidden;
1585
1585
  text-overflow: ellipsis;
1586
1586
 
@@ -1593,7 +1593,7 @@
1593
1593
  overflow: hidden;
1594
1594
  visibility: hidden;
1595
1595
  }
1596
- `,tp=g.span`
1596
+ `,th=g.span`
1597
1597
  display: flex;
1598
1598
  align-items: center;
1599
1599
  justify-content: center;
@@ -1605,7 +1605,7 @@
1605
1605
  color: ${re("badge-color")};
1606
1606
  font-size: ${re("badge-font-size")};
1607
1607
  font-weight: 600;
1608
- `,op=g.button`
1608
+ `,oh=g.button`
1609
1609
  display: flex;
1610
1610
  align-items: center;
1611
1611
  justify-content: center;
@@ -1630,7 +1630,7 @@
1630
1630
  outline-offset: -2px;
1631
1631
  opacity: 1;
1632
1632
  }
1633
- `,[Ct]=M(["tab"]),np=({children:e,className:t})=>{const{activeTab:o,variant:n}=yo(),r=d.useRef(null),s=d.useRef(null),l=n==="underline";return d.useEffect(()=>{if(l&&s.current&&r.current){const a=s.current.querySelector(`[data-value=${o}]`);if(a){const u=a.getBoundingClientRect(),p=a.offsetLeft;r.current.style.width=`${u.width}px`,r.current.style.left=`${p}px`}}},[o,e,l]),i.jsxs(rp,{ref:s,className:t,"data-variant":n,role:"tablist",children:[l&&i.jsx(sp,{ref:r}),e]})},rp=g.div`
1633
+ `,[Ct]=M(["tab"]),nh=({children:e,className:t})=>{const{activeTab:o,variant:n}=yo(),r=d.useRef(null),s=d.useRef(null),l=n==="underline";return d.useEffect(()=>{if(l&&s.current&&r.current){const a=s.current.querySelector(`[data-value=${o}]`);if(a){const u=a.getBoundingClientRect(),h=a.offsetLeft;r.current.style.width=`${u.width}px`,r.current.style.left=`${h}px`}}},[o,e,l]),i.jsxs(rh,{ref:s,className:t,"data-variant":n,role:"tablist",children:[l&&i.jsx(sh,{ref:r}),e]})},rh=g.div`
1634
1634
  width: 100%;
1635
1635
  height: fit-content;
1636
1636
  display: flex;
@@ -1660,36 +1660,36 @@
1660
1660
  justify-content: flex-start;
1661
1661
  align-items: stretch;
1662
1662
  }
1663
- `,sp=g.div`
1663
+ `,sh=g.div`
1664
1664
  position: absolute;
1665
1665
  bottom: 0px;
1666
1666
  transform: translateY(${Ct("trigger-list-underline-height")});
1667
1667
  height: ${Ct("indicator-height")};
1668
1668
  background-color: ${Ct("indicator-color")};
1669
1669
  transition: all 0.25s ease-in-out;
1670
- `,ip=({children:e,className:t,style:o,value:n})=>{const{activeTab:r}=yo(),s=n===r;return i.jsx(ap,{className:t,"data-active":s?"true":"false",style:o,children:e})},ap=g.div`
1670
+ `,ih=({children:e,className:t,style:o,value:n})=>{const{activeTab:r}=yo(),s=n===r;return i.jsx(ah,{className:t,"data-active":s?"true":"false",style:o,children:e})},ah=g.div`
1671
1671
  display: none;
1672
1672
  &[data-active="true"] {
1673
1673
  display: block;
1674
1674
  }
1675
- `,[ve]=M(["tag"]),lp={purple:ve("color-light"),orange:ve("color-light"),light:ve("color-dark"),blue:ve("color-dark"),green:ve("color-light"),red:ve("color-light"),disabled:ve("color-disabled")},cp={purple:"light",orange:"light",light:"dark",blue:"dark",green:"light",red:"light",disabled:"disabled"},dp=g.div`
1676
- background-color: ${e=>ve(`bg-color-${e.color}`)};
1677
- border-radius: ${ve("border-radius")};
1678
- border: 1px solid ${ve("border-color")};
1675
+ `,[ke]=M(["tag"]),lh={purple:ke("color-light"),orange:ke("color-light"),light:ke("color-dark"),blue:ke("color-dark"),green:ke("color-light"),red:ke("color-light"),disabled:ke("color-disabled")},ch={purple:"light",orange:"light",light:"dark",blue:"dark",green:"light",red:"light",disabled:"disabled"},dh=g.div`
1676
+ background-color: ${e=>ke(`bg-color-${e.color}`)};
1677
+ border-radius: ${ke("border-radius")};
1678
+ border: 1px solid ${ke("border-color")};
1679
1679
  display: flex;
1680
- color: ${e=>lp[e.color]};
1681
- height: ${ve("height")};
1680
+ color: ${e=>lh[e.color]};
1681
+ height: ${ke("height")};
1682
1682
  max-width: 160px;
1683
1683
  align-items: center;
1684
- padding: ${ve("padding")};
1684
+ padding: ${ke("padding")};
1685
1685
  align-items: center;
1686
1686
  justify-content: center;
1687
1687
  gap: 4px;
1688
- `,ho=e=>{const t=typeof e.children=="string"?i.jsx(E,{color:cp[e.color],variant:"body",children:e.children}):e.children;return i.jsx(dp,{...e,children:t})},up=({tagName:e,onRemove:t,color:o="light"})=>i.jsxs(ho,{color:o,children:[i.jsx(E,{variant:"body",children:e}),i.jsx(R,{size:"xxsm",iconId:"Close",onClick:()=>t(e)})]},`key-tag-${e}`),pp=({search:e,style:t,children:o,highlightColor:n,highlightTextColor:r})=>{const s=n||"yellow",l=d.useMemo(()=>Array.isArray(e)?e:[e].filter(Boolean),[e]);if(!l||l.length===0)return i.jsx(i.Fragment,{children:o});const a=p=>{const h=new RegExp(`(${l.join("|")})`,"gi");return p.split(h).map((m,b)=>l.some(x=>x.toLowerCase()===m.toLowerCase())?i.jsx("span",{style:t||{backgroundColor:s,color:r??void 0},children:m},b):m)},u=p=>typeof p=="string"?a(p):d.isValidElement(p)?d.cloneElement(p,{children:d.Children.map(p.props.children,u)}):p;return i.jsx(i.Fragment,{children:d.Children.map(o,u)})},[xe]=M(["badge"]),hp=({color:e,children:t,position:o,radius:n,hide:r})=>i.jsxs(fp,{children:[!r&&i.jsx(gp,{"data-color":e,"data-position":o??"top-right","data-radius":n??4}),t]}),fp=g.div`
1688
+ `,po=e=>{const t=typeof e.children=="string"?i.jsx(E,{color:ch[e.color],variant:"body",children:e.children}):e.children;return i.jsx(dh,{...e,children:t})},uh=({tagName:e,onRemove:t,color:o="light"})=>i.jsxs(po,{color:o,children:[i.jsx(E,{variant:"body",children:e}),i.jsx(R,{size:"xxsm",iconId:"Close",onClick:()=>t(e)})]},`key-tag-${e}`),hh=({search:e,style:t,children:o,highlightColor:n,highlightTextColor:r})=>{const s=n||"yellow",l=d.useMemo(()=>Array.isArray(e)?e:[e].filter(Boolean),[e]);if(!l||l.length===0)return i.jsx(i.Fragment,{children:o});const a=h=>{const p=new RegExp(`(${l.join("|")})`,"gi");return h.split(p).map((m,b)=>l.some(x=>x.toLowerCase()===m.toLowerCase())?i.jsx("span",{style:t||{backgroundColor:s,color:r??void 0},children:m},b):m)},u=h=>typeof h=="string"?a(h):d.isValidElement(h)?d.cloneElement(h,{children:d.Children.map(h.props.children,u)}):h;return i.jsx(i.Fragment,{children:d.Children.map(o,u)})},[ye]=M(["badge"]),ph=({color:e,children:t,position:o,radius:n,hide:r})=>i.jsxs(fh,{children:[!r&&i.jsx(gh,{"data-color":e,"data-position":o??"top-right","data-radius":n??4}),t]}),fh=g.div`
1689
1689
  width: fit-content;
1690
1690
  height: fit-content;
1691
1691
  position: relative;
1692
- `,gp=g.div`
1692
+ `,gh=g.div`
1693
1693
  position: absolute;
1694
1694
  z-index: 2;
1695
1695
  border-radius: 50%;
@@ -1701,28 +1701,28 @@
1701
1701
  0 8px 8px hsl(0deg 0% 0% / 0.075), 0 16px 16px hsl(0deg 0% 0% / 0.075);
1702
1702
  // Color
1703
1703
  &[data-color="blue"] {
1704
- background-color: ${xe("color-blue")};
1705
- border-color: ${xe("color-blue-border")};
1704
+ background-color: ${ye("color-blue")};
1705
+ border-color: ${ye("color-blue-border")};
1706
1706
  }
1707
1707
  &[data-color="red"] {
1708
- background-color: ${xe("color-red")};
1709
- border-color: ${xe("color-red-border")};
1708
+ background-color: ${ye("color-red")};
1709
+ border-color: ${ye("color-red-border")};
1710
1710
  }
1711
1711
  &[data-color="white"] {
1712
- background-color: ${xe("color-white")};
1713
- border-color: ${xe("color-white-border")};
1712
+ background-color: ${ye("color-white")};
1713
+ border-color: ${ye("color-white-border")};
1714
1714
  }
1715
1715
  &[data-color="black"] {
1716
- background-color: ${xe("color-black")};
1717
- border-color: ${xe("color-black-border")};
1716
+ background-color: ${ye("color-black")};
1717
+ border-color: ${ye("color-black-border")};
1718
1718
  }
1719
1719
  &[data-color="orange"] {
1720
- background-color: ${xe("color-orange")};
1721
- border-color: ${xe("color-orange-border")};
1720
+ background-color: ${ye("color-orange")};
1721
+ border-color: ${ye("color-orange-border")};
1722
1722
  }
1723
1723
  &[data-color="green"] {
1724
- background-color: ${xe("color-green")};
1725
- border-color: ${xe("color-green-border")};
1724
+ background-color: ${ye("color-green")};
1725
+ border-color: ${ye("color-green-border")};
1726
1726
  }
1727
1727
  // Position
1728
1728
  &[data-position="top-right"] {
@@ -1765,7 +1765,7 @@
1765
1765
  height: ${c("spacing-16")};
1766
1766
  --xform-factor: ${c("spacing-8")};
1767
1767
  }
1768
- `,[fe]=M(["textarea"]),Dn=d.forwardRef(({autoCapitalize:e="off",autoComplete:t="off",autoCorrect:o="off",className:n,...r},s)=>i.jsx(mp,{autoCapitalize:e,autoComplete:t,autoCorrect:o,className:n,ref:s,...r})),mp=g.textarea`
1768
+ `,[fe]=M(["textarea"]),Dn=d.forwardRef(({autoCapitalize:e="off",autoComplete:t="off",autoCorrect:o="off",className:n,...r},s)=>i.jsx(mh,{autoCapitalize:e,autoComplete:t,autoCorrect:o,className:n,ref:s,...r})),mh=g.textarea`
1769
1769
  display: flex;
1770
1770
  min-height: ${fe("min-height")};
1771
1771
  padding: ${fe("padding")};
@@ -1791,16 +1791,16 @@
1791
1791
  color: ${fe("color-disabled")};
1792
1792
  background-color: ${fe("background-color-disabled")};
1793
1793
  }
1794
- `;Dn.displayName="Textarea";const[bp,Te,ye]=M(["toggle-container","toggle-track","toggle-thumb"]),mr=g(R)`
1794
+ `;Dn.displayName="Textarea";const[bh,Te,ve]=M(["toggle-container","toggle-track","toggle-thumb"]),mr=g(R)`
1795
1795
  opacity: 0;
1796
1796
  position: absolute;
1797
1797
  transition-duration: 150ms;
1798
1798
  transition-property: opacity;
1799
1799
  transition-timing-function: ease-in-out;
1800
- `,xp=g.div`
1800
+ `,xh=g.div`
1801
1801
  align-items: center;
1802
1802
  display: flex;
1803
- gap: ${bp("gap")};
1803
+ gap: ${bh("gap")};
1804
1804
  justify-content: center;
1805
1805
  position: relative;
1806
1806
  `,Fs=g.div`
@@ -1808,7 +1808,7 @@
1808
1808
  border-radius: ${Te("border-radius")};
1809
1809
  cursor: pointer;
1810
1810
  display: flex;
1811
- height: calc(${Te("padding-vertical")} * 2 + ${ye("height")} + 2px);
1811
+ height: calc(${Te("padding-vertical")} * 2 + ${ve("height")} + 2px);
1812
1812
  padding: ${Te("padding-vertical")} ${Te("padding-horizontal")};
1813
1813
  position: relative;
1814
1814
  transition-duration: ${Te("transition-duration")};
@@ -1832,33 +1832,33 @@
1832
1832
  }
1833
1833
 
1834
1834
  // width...
1835
- width: calc(${Te("padding-horizontal")} * 2 + ${ye("width")} * 2);
1835
+ width: calc(${Te("padding-horizontal")} * 2 + ${ve("width")} * 2);
1836
1836
  &.showIcons {
1837
1837
  width: ${`calc(
1838
- ${Te("padding-horizontal")} * 2 + ${ye("width")} * 2 + 4px
1838
+ ${Te("padding-horizontal")} * 2 + ${ve("width")} * 2 + 4px
1839
1839
  )`};
1840
1840
  }
1841
1841
  `,As=g.div`
1842
- border-radius: ${ye("border-radius")};
1843
- box-shadow: ${ye("box-shadow")};
1844
- height: ${ye("height")};
1845
- transition-duration: ${ye("transition-duration")};
1842
+ border-radius: ${ve("border-radius")};
1843
+ box-shadow: ${ve("box-shadow")};
1844
+ height: ${ve("height")};
1845
+ transition-duration: ${ve("transition-duration")};
1846
1846
  transition-property: transform;
1847
1847
  transition-timing-function: ease-in-out;
1848
- width: ${ye("width")};
1848
+ width: ${ve("width")};
1849
1849
 
1850
1850
  // background-color...
1851
- background-color: ${ye("background-color-unchecked-enabled")};
1851
+ background-color: ${ve("background-color-unchecked-enabled")};
1852
1852
  &.isDisabled,
1853
1853
  &.isReadOnly {
1854
- background-color: ${ye("background-color-unchecked-disabled")};
1854
+ background-color: ${ve("background-color-unchecked-disabled")};
1855
1855
  cursor: not-allowed;
1856
1856
  }
1857
1857
  &.isChecked {
1858
- background-color: ${ye("background-color-checked-enabled")};
1858
+ background-color: ${ve("background-color-checked-enabled")};
1859
1859
  &.isDisabled,
1860
1860
  &.isReadOnly {
1861
- background-color: ${ye("background-color-checked-disabled")};
1861
+ background-color: ${ve("background-color-checked-disabled")};
1862
1862
  cursor: not-allowed;
1863
1863
  }
1864
1864
  }
@@ -1871,12 +1871,12 @@
1871
1871
  transform: translate(calc(100% + 4px), 0px);
1872
1872
  }
1873
1873
  }
1874
- `,vo=({checked:e,disabled:t,label:o,labelVariant:n="small",onChange:r,showIcons:s,readOnly:l,id:a,...u})=>{const[p,h]=d.useState(e??!1);d.useEffect(()=>{h(e??!1)},[e]);const f=d.useCallback(()=>{t||l||(h(!p),r==null||r(!p))},[p,t,l,r]);return i.jsx(z.ClassNames,{children:({cx:m})=>i.jsxs(xp,{children:[o&&i.jsx(E,{color:t?"disabled":"grey",variant:n,children:o}),i.jsxs(Fs,{id:a,className:m({isReadOnly:l},p&&"isChecked",t&&"isDisabled",s&&"showIcons"),...u,onClick:f,children:[s&&i.jsxs(i.Fragment,{children:[i.jsx(mr,{color:"white",iconId:"Close",size:"xxsm",style:{opacity:p?0:1,right:"3px"}}),i.jsx(mr,{color:"white",iconId:"Check",size:"xxsm",style:{opacity:p?1:0}})]}),i.jsx(As,{className:m(p&&"isChecked",s&&"showIcons",{isReadOnly:l}),...u})]})]})})},yp=g.div`
1874
+ `,vo=({checked:e,disabled:t,label:o,labelVariant:n="small",onChange:r,showIcons:s,readOnly:l,id:a,...u})=>{const[h,p]=d.useState(e??!1);d.useEffect(()=>{p(e??!1)},[e]);const f=d.useCallback(()=>{t||l||(p(!h),r==null||r(!h))},[h,t,l,r]);return i.jsx(z.ClassNames,{children:({cx:m})=>i.jsxs(xh,{children:[o&&i.jsx(E,{color:t?"disabled":"grey",variant:n,children:o}),i.jsxs(Fs,{id:a,className:m({isReadOnly:l},h&&"isChecked",t&&"isDisabled",s&&"showIcons"),...u,onClick:f,children:[s&&i.jsxs(i.Fragment,{children:[i.jsx(mr,{color:"white",iconId:"Close",size:"xxsm",style:{opacity:h?0:1,right:"3px"}}),i.jsx(mr,{color:"white",iconId:"Check",size:"xxsm",style:{opacity:h?1:0}})]}),i.jsx(As,{className:m(h&&"isChecked",s&&"showIcons",{isReadOnly:l}),...u})]})]})})},yh=g.div`
1875
1875
  display: inline-block;
1876
1876
  line-height: 0;
1877
- `,vp=g.div`
1877
+ `,vh=g.div`
1878
1878
  z-index: 2;
1879
- `,Ls=({arrow:e,children:t,content:o,open:n,openDelay:r=250,className:s,placement:l,offset:a,disabled:u})=>{const p=d.useRef(null),[h,f]=d.useState(n);d.useEffect(()=>{n!==void 0&&f(n)},[n]);const{refs:m,floatingStyles:b,context:x}=O.useFloating({open:h,onOpenChange:n===void 0?f:void 0,placement:l??"top",whileElementsMounted:O.autoUpdate,middleware:[O.offset(a??12),O.flip({fallbackAxisSideDirection:"start"}),O.shift(),O.arrow({element:p})]}),y=O.useHover(x,{move:!1,restMs:r}),k=O.useFocus(x),v=O.useDismiss(x),$=O.useRole(x,{role:"tooltip"}),{getReferenceProps:C,getFloatingProps:S}=O.useInteractions(u?[]:[y,k,v,$]);return i.jsxs(i.Fragment,{children:[i.jsx(yp,{className:s,ref:m.setReference,...C(),children:t}),i.jsx(O.FloatingPortal,{children:h&&i.jsxs(vp,{ref:m.setFloating,style:b,...S(),children:[i.jsx(O.FloatingArrow,{...e,ref:p,context:x}),o]})})]})},Bs=g.div`
1879
+ `,Ls=({arrow:e,children:t,content:o,open:n,openDelay:r=250,className:s,placement:l,offset:a,disabled:u})=>{const h=d.useRef(null),[p,f]=d.useState(n);d.useEffect(()=>{n!==void 0&&f(n)},[n]);const{refs:m,floatingStyles:b,context:x}=O.useFloating({open:p,onOpenChange:n===void 0?f:void 0,placement:l??"top",whileElementsMounted:O.autoUpdate,middleware:[O.offset(a??12),O.flip({fallbackAxisSideDirection:"start"}),O.shift(),O.arrow({element:h})]}),y=O.useHover(x,{move:!1,restMs:r}),k=O.useFocus(x),v=O.useDismiss(x),$=O.useRole(x,{role:"tooltip"}),{getReferenceProps:C,getFloatingProps:S}=O.useInteractions(u?[]:[y,k,v,$]);return i.jsxs(i.Fragment,{children:[i.jsx(yh,{className:s,ref:m.setReference,...C(),children:t}),i.jsx(O.FloatingPortal,{children:p&&i.jsxs(vh,{ref:m.setFloating,style:b,...S(),children:[i.jsx(O.FloatingArrow,{...e,ref:h,context:x}),o]})})]})},Bs=g.div`
1880
1880
  background-color: #ffffff;
1881
1881
  border-radius: 0px;
1882
1882
  box-shadow: 2px 4px 6px rgba(0, 0, 0, 0.12);
@@ -1884,30 +1884,30 @@
1884
1884
  display: flex;
1885
1885
  align-items: center;
1886
1886
  padding: ${e=>e.contain&&"7px 10px"};
1887
- `,Ws={fill:"#ffffff",height:12,tipRadius:0,width:14},ko=({arrow:e=Ws,children:t,contain:o=!0,content:n,...r})=>i.jsx(Ls,{arrow:e,content:i.jsx(Bs,{contain:o,children:i.jsx(E,{color:"dark",variant:"body",children:n})}),...r,children:t}),kp=g.div`
1887
+ `,Ws={fill:"#ffffff",height:12,tipRadius:0,width:14},ko=({arrow:e=Ws,children:t,contain:o=!0,content:n,...r})=>i.jsx(Ls,{arrow:e,content:i.jsx(Bs,{contain:o,children:i.jsx(E,{color:"dark",variant:"body",children:n})}),...r,children:t}),kh=g.div`
1888
1888
  display: flex;
1889
1889
  flex-direction: column;
1890
1890
  min-width: 160px;
1891
- `,wp=g.div`
1891
+ `,wh=g.div`
1892
1892
  display: flex;
1893
1893
  gap: 8px;
1894
1894
  height: 28px;
1895
1895
  padding: 7px 10px;
1896
- `,Cp=g.div`
1896
+ `,Ch=g.div`
1897
1897
  border-top: 1px solid #dfdfdf;
1898
- `,$p=g.div`
1898
+ `,$h=g.div`
1899
1899
  padding: 7px 12px;
1900
- `,Sp=e=>{switch(e){case"error":return"red";case"info":return"blue";case"success":return"green";case"warning":return"orange";default:return"blue"}},jp=e=>{switch(e){case"error":case"info":return"ExclamationCircle";case"success":return"CheckCircle";case"warning":return"Warning";default:return"ExclamationCircle"}},Ip=({message:e,title:t="Information",type:o="info"})=>i.jsxs(kp,{children:[i.jsxs(wp,{children:[i.jsx(R,{color:Sp(o),iconId:jp(o)}),i.jsx(E,{bold:!0,variant:"body",children:t})]}),i.jsx(Cp,{}),i.jsx($p,{children:i.jsx(E,{variant:"body",children:e})})]}),_n=({children:e,open:t,openDelay:o,className:n,...r})=>i.jsx(ko,{contain:!1,content:i.jsx(Ip,{...r}),open:t,openDelay:o,className:n,children:e}),Ps=g.div`
1900
+ `,Sh=e=>{switch(e){case"error":return"red";case"info":return"blue";case"success":return"green";case"warning":return"orange";default:return"blue"}},jh=e=>{switch(e){case"error":case"info":return"ExclamationCircle";case"success":return"CheckCircle";case"warning":return"Warning";default:return"ExclamationCircle"}},Ih=({message:e,title:t="Information",type:o="info"})=>i.jsxs(kh,{children:[i.jsxs(wh,{children:[i.jsx(R,{color:Sh(o),iconId:jh(o)}),i.jsx(E,{bold:!0,variant:"body",children:t})]}),i.jsx(Ch,{}),i.jsx($h,{children:i.jsx(E,{variant:"body",children:e})})]}),_n=({children:e,open:t,openDelay:o,className:n,...r})=>i.jsx(ko,{contain:!1,content:i.jsx(Ih,{...r}),open:t,openDelay:o,className:n,children:e}),Ps=g.div`
1901
1901
  background-color: #000000;
1902
1902
  border-radius: 4px;
1903
1903
  color: #ffffff;
1904
1904
  display: flex;
1905
1905
  gap: 8px;
1906
1906
  padding: ${e=>e.contain&&"4px 8px"};
1907
- `,Vs={fill:"#000000",height:10,tipRadius:2,width:11},wo=d.forwardRef(({arrow:e=Vs,children:t,contain:o=!0,content:n,...r},s)=>i.jsx(Ls,{arrow:e,content:i.jsx(Ps,{contain:o,children:i.jsx(E,{color:"light",variant:"small",children:n})}),...r,children:d.isValidElement(t)?d.cloneElement(t,{ref:s}):t})),Hs=({title:e,...t})=>i.jsx(_n,{...t,title:e??"Error",type:"error"}),Dp=g.div`
1907
+ `,Vs={fill:"#000000",height:10,tipRadius:2,width:11},wo=d.forwardRef(({arrow:e=Vs,children:t,contain:o=!0,content:n,...r},s)=>i.jsx(Ls,{arrow:e,content:i.jsx(Ps,{contain:o,children:i.jsx(E,{color:"light",variant:"small",children:n})}),...r,children:d.isValidElement(t)?d.cloneElement(t,{ref:s}):t})),Hs=({title:e,...t})=>i.jsx(_n,{...t,title:e??"Error",type:"error"}),Dh=g.div`
1908
1908
  display: flex;
1909
1909
  gap: 4px;
1910
- `,_p=({label:e,value:t})=>i.jsxs(Dp,{children:[i.jsx(R,{iconId:"CheckSquare",size:"sm",color:"purple"}),i.jsxs(E,{bold:!0,variant:"body",children:[e,":"]}),i.jsx(E,{variant:"body",children:t})]}),Us=({children:e,open:t,openDelay:o,...n})=>i.jsx(ko,{content:i.jsx(_p,{...n}),open:t,openDelay:o,children:e}),Gs=d.forwardRef(({variant:e,...t},o)=>{let n;switch(e){case"alert":n=_n;break;case"dark":n=wo;break;case"error":n=Hs;break;case"light":n=ko;break;case"selector":n=Us;break}return i.jsx(n,{...t,ref:o})}),Ks=d.createContext(null),Tp=({children:e,value:t})=>i.jsx(Ks.Provider,{value:t,children:e}),Ys=()=>{const e=d.useContext(Ks);if(!e)throw new Error("Unable to use MultiSelectContext outside of its provider.");return e},[Rt]=M(["multi-select"]),qs=g.div`
1910
+ `,_h=({label:e,value:t})=>i.jsxs(Dh,{children:[i.jsx(R,{iconId:"CheckSquare",size:"sm",color:"purple"}),i.jsxs(E,{bold:!0,variant:"body",children:[e,":"]}),i.jsx(E,{variant:"body",children:t})]}),Us=({children:e,open:t,openDelay:o,...n})=>i.jsx(ko,{content:i.jsx(_h,{...n}),open:t,openDelay:o,children:e}),Gs=d.forwardRef(({variant:e,...t},o)=>{let n;switch(e){case"alert":n=_n;break;case"dark":n=wo;break;case"error":n=Hs;break;case"light":n=ko;break;case"selector":n=Us;break}return i.jsx(n,{...t,ref:o})}),Ks=d.createContext(null),Th=({children:e,value:t})=>i.jsx(Ks.Provider,{value:t,children:e}),Ys=()=>{const e=d.useContext(Ks);if(!e)throw new Error("Unable to use MultiSelectContext outside of its provider.");return e},[Rt]=M(["multi-select"]),qs=g.div`
1911
1911
  width: 100%;
1912
1912
  padding: ${Rt("item-padding-y")} ${Rt("item-padding-x")};
1913
1913
  display: flex;
@@ -1920,14 +1920,14 @@
1920
1920
  &:hover {
1921
1921
  background-color: ${Rt("item-hover-bg")};
1922
1922
  }
1923
- `,[io]=M(["multi-select"]),Ep=d.memo(({SelectAllItemTemplate:e,options:t})=>{const{selected:o,onSetSelected:n,setOpen:r}=Ys(),s=d.useRef(null),{isAllSelected:l,isPartiallySelected:a}=d.useMemo(()=>{const p=t.every(h=>o.some(f=>f.value===h.value));return{isAllSelected:p,isPartiallySelected:!p&&o.length!==0}},[o,t]),u=d.useCallback(()=>{n(l?[]:t),r(!1)},[l,r,n,t]);return d.useEffect(()=>{s.current&&(s.current.indeterminate=a)},[a]),e?i.jsx(e,{onToggleSelectAll:u,isAllSelected:l,isPartiallySelected:a}):i.jsxs(zp,{onClick:u,children:[i.jsx(_t,{ref:s,onChange:$e,checked:l}),i.jsx(E,{variant:"body",color:"dark",children:l?"Deselect All":"Select All"})]})}),zp=g(qs)`
1923
+ `,[io]=M(["multi-select"]),Eh=d.memo(({SelectAllItemTemplate:e,options:t})=>{const{selected:o,onSetSelected:n,setOpen:r}=Ys(),s=d.useRef(null),{isAllSelected:l,isPartiallySelected:a}=d.useMemo(()=>{const h=t.every(p=>o.some(f=>f.value===p.value));return{isAllSelected:h,isPartiallySelected:!h&&o.length!==0}},[o,t]),u=d.useCallback(()=>{n(l?[]:t),r(!1)},[l,r,n,t]);return d.useEffect(()=>{s.current&&(s.current.indeterminate=a)},[a]),e?i.jsx(e,{onToggleSelectAll:u,isAllSelected:l,isPartiallySelected:a}):i.jsxs(zh,{onClick:u,children:[i.jsx(_t,{ref:s,onChange:Se,checked:l}),i.jsx(E,{variant:"body",color:"dark",children:l?"Deselect All":"Select All"})]})}),zh=g(qs)`
1924
1924
  border-bottom: ${io("border")} solid ${io("select-all-border-color")};
1925
1925
  position: sticky;
1926
1926
  top: 0;
1927
1927
  z-index: 2;
1928
1928
  padding-top: calc(${io("item-padding-y")} * 2);
1929
1929
  background-color: ${io("background")};
1930
- `,Mp=d.memo(({value:e,label:t,isSelected:o,ListItemTemplate:n,onToggleSelect:r})=>n?i.jsx(n,{value:e,label:t,isSelected:o}):i.jsxs(qs,{onClick:()=>r({value:e,label:t}),children:[i.jsx(_t,{onChange:$e,checked:o}),i.jsx(E,{variant:"body",color:"dark",children:t})]})),[yt]=M(["multi-select"]),Op=d.memo(({value:e,label:t,onRemove:o,SelectedItemTemplate:n})=>n?i.jsx(n,{value:e,label:t,onRemove:o}):i.jsxs(Rp,{children:[i.jsx(E,{variant:"body",color:"dark",children:t}),i.jsx(ae,{size:"xxsm",color:"black",iconId:"Close",onClick:()=>o({value:e,label:t})})]})),Rp=g.div`
1930
+ `,Mh=d.memo(({value:e,label:t,isSelected:o,ListItemTemplate:n,onToggleSelect:r})=>n?i.jsx(n,{value:e,label:t,isSelected:o}):i.jsxs(qs,{onClick:()=>r({value:e,label:t}),children:[i.jsx(_t,{onChange:Se,checked:o}),i.jsx(E,{variant:"body",color:"dark",children:t})]})),[yt]=M(["multi-select"]),Oh=d.memo(({value:e,label:t,onRemove:o,SelectedItemTemplate:n})=>n?i.jsx(n,{value:e,label:t,onRemove:o}):i.jsxs(Rh,{children:[i.jsx(E,{variant:"body",color:"dark",children:t}),i.jsx(ae,{size:"xxsm",color:"black",iconId:"Close",onClick:()=>o({value:e,label:t})})]})),Rh=g.div`
1931
1931
  padding: ${yt("selected-item-padding-y")} ${yt("selected-item-padding-x")};
1932
1932
  display: flex;
1933
1933
  align-items: center;
@@ -1939,7 +1939,7 @@
1939
1939
  :hover {
1940
1940
  background-color: ${yt("selected-item-background-hover")};
1941
1941
  }
1942
- `,[de]=M(["multi-select"]),Zs=d.memo(({options:e,selected:t,className:o,closeOnSelect:n,onChange:r,disabled:s,selectAllHidden:l,SelectAllItemTemplate:a,ListItemTemplate:u,SelectedItemTemplate:p})=>{const[h,f]=d.useState(!1),m=d.useCallback(j=>{console.log({_open:j}),f(j)},[]),{refs:b,floatingStyles:x,context:y}=O.useFloating({placement:"bottom",open:h,onOpenChange:m,whileElementsMounted:O.autoUpdate,middleware:Rs}),k=O.useClick(y,{enabled:!s,toggle:!!n}),v=O.useDismiss(y),$=O.useRole(y,{role:"listbox"}),{getReferenceProps:C,getFloatingProps:S}=O.useInteractions([k,v,$]),w=d.useCallback(j=>{t.some(D=>D.value===j.value)?r(t.filter(D=>D.value!==j.value)):r([...t,j])},[r,t]),I=d.useMemo(()=>({open:h,setOpen:f,selected:t,onToggleSelect:w,onSetSelected:r}),[w,h,t,r]);return console.log({open:h}),i.jsx(Tp,{value:I,children:i.jsxs(Np,{ref:b.setReference,className:o,...C({onClick(j){j.stopPropagation()}}),children:[t.map(j=>z.createElement(Op,{SelectedItemTemplate:p,...j,key:j.value,onRemove:w})),h&&i.jsx(O.FloatingPortal,{children:i.jsx(O.FloatingFocusManager,{context:y,modal:!1,children:i.jsxs(Fp,{ref:b.setFloating,style:x,className:Dt({selectAllHidden:!!l||!!a}),...S(),children:[!l&&i.jsx(Ep,{SelectAllItemTemplate:a,options:e}),e.map(j=>i.jsx(Mp,{label:j.label,value:j.value,onToggleSelect:w,isSelected:t.some(D=>j.value===D.value),ListItemTemplate:u},j.value))]})})})]})})}),Np=g.div`
1942
+ `,[de]=M(["multi-select"]),Zs=d.memo(({options:e,selected:t,className:o,closeOnSelect:n,onChange:r,disabled:s,selectAllHidden:l,SelectAllItemTemplate:a,ListItemTemplate:u,SelectedItemTemplate:h})=>{const[p,f]=d.useState(!1),m=d.useCallback(j=>{console.log({_open:j}),f(j)},[]),{refs:b,floatingStyles:x,context:y}=O.useFloating({placement:"bottom",open:p,onOpenChange:m,whileElementsMounted:O.autoUpdate,middleware:Rs}),k=O.useClick(y,{enabled:!s,toggle:!!n}),v=O.useDismiss(y),$=O.useRole(y,{role:"listbox"}),{getReferenceProps:C,getFloatingProps:S}=O.useInteractions([k,v,$]),w=d.useCallback(j=>{t.some(D=>D.value===j.value)?r(t.filter(D=>D.value!==j.value)):r([...t,j])},[r,t]),I=d.useMemo(()=>({open:p,setOpen:f,selected:t,onToggleSelect:w,onSetSelected:r}),[w,p,t,r]);return console.log({open:p}),i.jsx(Th,{value:I,children:i.jsxs(Nh,{ref:b.setReference,className:o,...C({onClick(j){j.stopPropagation()}}),children:[t.map(j=>z.createElement(Oh,{SelectedItemTemplate:h,...j,key:j.value,onRemove:w})),p&&i.jsx(O.FloatingPortal,{children:i.jsx(O.FloatingFocusManager,{context:y,modal:!1,children:i.jsxs(Fh,{ref:b.setFloating,style:x,className:Dt({selectAllHidden:!!l||!!a}),...S(),children:[!l&&i.jsx(Eh,{SelectAllItemTemplate:a,options:e}),e.map(j=>i.jsx(Mh,{label:j.label,value:j.value,onToggleSelect:w,isSelected:t.some(D=>j.value===D.value),ListItemTemplate:u},j.value))]})})})]})})}),Nh=g.div`
1943
1943
  width: 100%;
1944
1944
  height: fit-content;
1945
1945
  min-height: 28px;
@@ -1956,7 +1956,7 @@
1956
1956
  &:hover {
1957
1957
  border-color: ${de("hover-border-color")};
1958
1958
  }
1959
- `,Fp=g.div`
1959
+ `,Fh=g.div`
1960
1960
  display: flex;
1961
1961
  flex-direction: column;
1962
1962
  border: ${de("border")} solid ${de("border-color")};
@@ -1973,7 +1973,7 @@
1973
1973
  &.selectAllHidden {
1974
1974
  padding-top: ${de("list-padding")};
1975
1975
  }
1976
- `,Ap=d.memo(({className:e})=>{const t=d.useId();return i.jsxs("svg",{width:"48",height:"48",viewBox:"0 0 48 48",fill:"none",className:e,xmlns:"http://www.w3.org/2000/svg",children:[i.jsxs("g",{clipPath:`url(#${t}-clip-0)`,children:[i.jsx("mask",{id:`${t}-mask-1`,style:{maskType:"luminance"},maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"48",height:"48",children:i.jsx("path",{d:"M47.95 0H0V47.95H47.95V0Z",fill:"white"})}),i.jsxs("g",{mask:`url(#${t}-mask-1)`,children:[i.jsx("path",{d:"M36.9766 0H10.9735C4.913 0 0 4.913 0 10.9735V36.9766C0 43.037 4.913 47.95 10.9735 47.95H36.9766C43.037 47.95 47.95 43.037 47.95 36.9766V10.9735C47.95 4.913 43.037 0 36.9766 0Z",fill:"black"}),i.jsx("path",{d:"M30.8827 24.7424C30.8827 25.7291 30.6646 26.6208 30.2341 27.393C29.8056 28.1617 29.2034 28.7704 28.4449 29.2013C27.6857 29.6323 26.8124 29.8504 25.8494 29.8504C24.8864 29.8504 24.0126 29.6323 23.2536 29.2013C22.495 28.7704 21.8929 28.1623 21.4643 27.393C21.0339 26.6208 20.8157 25.7291 20.8157 24.7424C20.8157 24.0474 20.9643 23.4216 21.258 22.8811C21.5493 22.345 21.9583 21.92 22.4736 21.6186C22.9907 21.3166 23.5864 21.1638 24.245 21.1638C24.9037 21.1638 25.5 21.3166 26.0166 21.6186C26.5319 21.92 26.9409 22.3444 27.2321 22.8811C27.5259 23.4216 27.6744 24.0481 27.6744 24.7424C27.6744 23.7556 27.4563 22.864 27.0259 22.0917C26.5973 21.3226 25.9951 20.7144 25.2366 20.2834C24.4781 19.8524 23.6049 19.6343 22.6407 19.6343C21.6764 19.6343 20.8039 19.8524 20.0453 20.2834C19.2867 20.7144 18.6846 21.3231 18.256 22.0917C17.8256 22.864 17.6074 23.7556 17.6074 24.7424C17.6074 25.9764 17.8951 27.0964 18.4628 28.0707C19.0311 29.0468 19.8288 29.8184 20.833 30.3636C21.8334 30.9068 22.9819 31.182 24.2457 31.182C25.5094 31.182 26.6586 30.9068 27.659 30.3636C28.663 29.8184 29.4607 29.0474 30.029 28.0707C30.5967 27.0964 30.8844 25.9764 30.8844 24.7424H30.8827Z",fill:"white"}),i.jsx("path",{d:"M17.6073 24.7424C17.6073 23.7556 17.8255 22.864 18.2558 22.0917C18.6845 21.3232 19.2866 20.7144 20.0452 20.2834C20.8042 19.8524 21.6775 19.6343 22.6405 19.6343C23.6035 19.6343 24.4773 19.8524 25.2365 20.2834C25.9949 20.7144 26.5972 21.3226 27.0258 22.0917C27.456 22.864 27.6743 23.7556 27.6743 24.7424C27.6743 25.4373 27.5256 26.0633 27.232 26.6036C26.9408 27.1399 26.5318 27.5649 26.0163 27.8663C25.4992 28.1682 24.9036 28.321 24.2449 28.321C23.5862 28.321 22.99 28.1682 22.4735 27.8663C21.958 27.5649 21.549 27.1404 21.2578 26.6036C20.9642 26.0633 20.8155 25.4367 20.8155 24.7424C20.8155 25.7292 21.0338 26.6209 21.464 27.393C21.8926 28.1623 22.4949 28.7704 23.2533 29.2014C24.0119 29.6323 24.8852 29.8506 25.8493 29.8506C26.8135 29.8506 27.6862 29.6323 28.4446 29.2014C29.2032 28.7704 29.8053 28.1617 30.234 27.393C30.6643 26.6209 30.8825 25.7292 30.8825 24.7424C30.8825 23.5083 30.5948 22.3884 30.027 21.4142C29.4588 20.438 28.661 19.6664 27.657 19.1213C26.6566 18.578 25.508 18.3027 24.2443 18.3027C22.9805 18.3027 21.8315 18.578 20.831 19.1213C19.8269 19.6664 19.0292 20.4374 18.4609 21.4142C17.8932 22.3884 17.6055 23.5083 17.6055 24.7424H17.6073Z",fill:"white"}),i.jsx("path",{d:"M17.6072 24.7424C17.6072 23.7556 17.8253 22.864 18.2558 22.0917C18.6843 21.3232 19.2865 20.7144 20.045 20.2834C20.8042 19.8524 21.6775 19.6343 22.6405 19.6343C23.6035 19.6343 24.4773 19.8524 25.2363 20.2834C25.9949 20.7144 26.597 21.3226 27.0256 22.0917C27.456 22.864 27.6742 23.7556 27.6742 24.7424C27.6742 25.4373 27.5256 26.0633 27.2319 26.6036C26.9406 27.1399 26.5316 27.5649 26.0163 27.8663C25.4992 28.1682 24.9035 28.321 24.2449 28.321C23.5862 28.321 22.9899 28.1682 22.4733 27.8663C21.958 27.5649 21.549 27.1404 21.2578 26.6036C20.964 26.0633 20.8155 25.4367 20.8155 24.7424C20.8155 25.7292 21.0336 26.6209 21.464 27.393C21.8926 28.1623 22.4948 28.7704 23.2533 29.2014C24.0118 29.6323 24.885 29.8504 25.8492 29.8504C26.8135 29.8504 27.686 29.6323 28.4446 29.2014C29.2032 28.7704 29.8053 28.1617 30.2339 27.393C30.6643 26.6209 30.8825 25.7292 30.8825 24.7424C30.8825 23.5083 30.5948 22.3884 30.027 21.4142C29.4588 20.438 28.661 19.6664 27.657 19.1213C26.6565 18.578 25.508 18.3027 24.2442 18.3027C22.9805 18.3027 21.8313 18.578 20.8309 19.1213C19.8269 19.6664 19.0292 20.4374 18.4609 21.4142C17.8932 22.3884 17.6055 23.5083 17.6055 24.7424H17.6072Z",fill:`url(#${t}-paint-0)`}),i.jsx("path",{d:"M41.6791 24.6258C41.0531 23.9767 40.1179 23.5308 38.8969 23.3002L36.5435 22.8692C35.7981 22.7276 35.4831 22.5744 35.3499 22.4704C35.1865 22.3431 35.1073 22.2075 35.1073 22.0559C35.1073 21.9627 35.1073 21.6791 35.6429 21.4015C36.0525 21.1892 36.5798 21.0817 37.2099 21.0817C38.3548 21.0817 39.4248 21.4585 40.3902 22.2022C40.4639 22.2592 40.5561 22.2902 40.6488 22.2902C40.7791 22.2902 40.8991 22.2314 40.9793 22.1291L42.2705 20.4789C42.4096 20.3012 42.3841 20.0462 42.2116 19.8981C41.5946 19.3691 40.8641 18.9702 40.0383 18.7128C39.1662 18.4411 38.2425 18.3032 37.2925 18.3032C36.2821 18.3032 35.3618 18.4595 34.5569 18.7675C33.7378 19.0814 33.0875 19.5409 32.6238 20.1329C32.1535 20.7339 31.9152 21.4479 31.9152 22.2539C31.9152 23.1479 32.2159 23.9077 32.8086 24.5122C33.3906 25.1061 34.2698 25.5175 35.4218 25.7362L37.9572 26.2165C38.5236 26.3301 38.9231 26.4757 39.1449 26.6487C39.3392 26.8009 39.4296 26.9691 39.4296 27.1795C39.4296 27.4749 39.2572 27.7247 38.9029 27.9428C38.5142 28.1818 37.9839 28.3036 37.3271 28.3036C35.9058 28.3036 34.6585 27.8589 33.6206 26.9816C33.5452 26.9179 33.4495 26.8829 33.3508 26.8829C33.2242 26.8829 33.1052 26.9388 33.0251 27.0369L31.6275 28.7369C31.4823 28.9135 31.5038 29.1704 31.6756 29.3219C32.2921 29.8652 33.0988 30.2998 34.0736 30.6137C35.1062 30.9465 36.2398 31.1154 37.4435 31.1154C38.4576 31.1154 39.3642 30.9465 40.1388 30.6137C40.9258 30.2754 41.5446 29.7887 41.9798 29.1662C42.4173 28.5397 42.6391 27.8102 42.6391 26.9982C42.6391 26.0834 42.3168 25.2851 41.6808 24.6252L41.6791 24.6258Z",fill:`url(#${t}-paint-1)`}),i.jsx("path",{d:"M12.9952 24.6802L18.8296 19.0464C19.0549 18.8271 19.0123 18.6261 18.9817 18.5529C18.9513 18.4799 18.8477 18.3032 18.5312 18.3032H15.5957C15.3764 18.3032 15.0963 18.4129 14.9319 18.5712L10.0172 23.3951V18.7357C10.0172 18.4981 9.82227 18.3032 9.58476 18.3032H7.26443C7.02692 18.3032 6.83203 18.4981 6.83203 18.7357V30.6249C6.83203 30.8624 7.02692 31.0574 7.26443 31.0574H9.58476C9.82227 31.0574 10.0172 30.8624 10.0172 30.6249V25.9655L14.9319 30.7894C15.0902 30.9417 15.3703 31.0574 15.5896 31.0574H18.525C18.8417 31.0574 18.9453 30.8807 18.9757 30.8077C19.0062 30.7345 19.0487 30.5335 18.8234 30.3142L12.9952 24.6802Z",fill:"white"})]})]}),i.jsxs("defs",{children:[i.jsxs("linearGradient",{id:`${t}-paint-0`,x1:"24.2439",y1:"19.4779",x2:"24.2439",y2:"28.6754",gradientUnits:"userSpaceOnUse",children:[i.jsx("stop",{offset:"0.0358168",stopColor:"#82E1FF"}),i.jsx("stop",{offset:"0.228529",stopColor:"#78E6A0"}),i.jsx("stop",{offset:"0.436866",stopColor:"#FFB400"}),i.jsx("stop",{offset:"0.619161",stopColor:"#FF8700"}),i.jsx("stop",{offset:"0.811872",stopColor:"#FF5A00"}),i.jsx("stop",{offset:"1",stopColor:"#F40000"})]}),i.jsxs("linearGradient",{id:`${t}-paint-1`,x1:"37.0852",y1:"19.6069",x2:"37.0852",y2:"29.8117",gradientUnits:"userSpaceOnUse",children:[i.jsx("stop",{offset:"0.0358168",stopColor:"#82E1FF"}),i.jsx("stop",{offset:"0.228529",stopColor:"#78E6A0"}),i.jsx("stop",{offset:"0.436866",stopColor:"#FFB400"}),i.jsx("stop",{offset:"0.619161",stopColor:"#FF8700"}),i.jsx("stop",{offset:"0.811872",stopColor:"#FF5A00"}),i.jsx("stop",{offset:"1",stopColor:"#F40000"})]}),i.jsx("clipPath",{id:`${t}-clip-0`,children:i.jsx("rect",{width:"48",height:"48",fill:"white"})})]})]})}),[Ee]=M(["collapsible-artifact-version"]),Lp=d.memo(({onListItemAction:e,isSelected:t,isInherited:o,id:n,name:r,createdAt:s,description:l})=>{const a=d.useCallback(()=>{e&&!o&&e(n,t?"deselect":"select")},[n,o,t,e]);return i.jsx(z.ClassNames,{children:({cx:u})=>i.jsxs(Bp,{onClick:a,className:u({isSelected:t,isInherited:o}),children:[i.jsxs(Wp,{children:[i.jsxs(Pp,{children:[i.jsx(E,{variant:"small",color:"dark",bold:!0,children:r}),!!s&&i.jsx(E,{color:"grey",variant:"small",children:s})]}),l&&i.jsx(bo,{color:"grey",variant:"small",children:`${l}${l}`})]}),t?i.jsx(Vp,{size:"xsm",color:"blue",iconId:t?"Check":"InfoCircle"}):o?i.jsx(R,{iconId:"Inherited",color:"purple"}):null]})})}),Bp=g.div`
1976
+ `,Ah=d.memo(({className:e})=>{const t=d.useId();return i.jsxs("svg",{width:"48",height:"48",viewBox:"0 0 48 48",fill:"none",className:e,xmlns:"http://www.w3.org/2000/svg",children:[i.jsxs("g",{clipPath:`url(#${t}-clip-0)`,children:[i.jsx("mask",{id:`${t}-mask-1`,style:{maskType:"luminance"},maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"48",height:"48",children:i.jsx("path",{d:"M47.95 0H0V47.95H47.95V0Z",fill:"white"})}),i.jsxs("g",{mask:`url(#${t}-mask-1)`,children:[i.jsx("path",{d:"M36.9766 0H10.9735C4.913 0 0 4.913 0 10.9735V36.9766C0 43.037 4.913 47.95 10.9735 47.95H36.9766C43.037 47.95 47.95 43.037 47.95 36.9766V10.9735C47.95 4.913 43.037 0 36.9766 0Z",fill:"black"}),i.jsx("path",{d:"M30.8827 24.7424C30.8827 25.7291 30.6646 26.6208 30.2341 27.393C29.8056 28.1617 29.2034 28.7704 28.4449 29.2013C27.6857 29.6323 26.8124 29.8504 25.8494 29.8504C24.8864 29.8504 24.0126 29.6323 23.2536 29.2013C22.495 28.7704 21.8929 28.1623 21.4643 27.393C21.0339 26.6208 20.8157 25.7291 20.8157 24.7424C20.8157 24.0474 20.9643 23.4216 21.258 22.8811C21.5493 22.345 21.9583 21.92 22.4736 21.6186C22.9907 21.3166 23.5864 21.1638 24.245 21.1638C24.9037 21.1638 25.5 21.3166 26.0166 21.6186C26.5319 21.92 26.9409 22.3444 27.2321 22.8811C27.5259 23.4216 27.6744 24.0481 27.6744 24.7424C27.6744 23.7556 27.4563 22.864 27.0259 22.0917C26.5973 21.3226 25.9951 20.7144 25.2366 20.2834C24.4781 19.8524 23.6049 19.6343 22.6407 19.6343C21.6764 19.6343 20.8039 19.8524 20.0453 20.2834C19.2867 20.7144 18.6846 21.3231 18.256 22.0917C17.8256 22.864 17.6074 23.7556 17.6074 24.7424C17.6074 25.9764 17.8951 27.0964 18.4628 28.0707C19.0311 29.0468 19.8288 29.8184 20.833 30.3636C21.8334 30.9068 22.9819 31.182 24.2457 31.182C25.5094 31.182 26.6586 30.9068 27.659 30.3636C28.663 29.8184 29.4607 29.0474 30.029 28.0707C30.5967 27.0964 30.8844 25.9764 30.8844 24.7424H30.8827Z",fill:"white"}),i.jsx("path",{d:"M17.6073 24.7424C17.6073 23.7556 17.8255 22.864 18.2558 22.0917C18.6845 21.3232 19.2866 20.7144 20.0452 20.2834C20.8042 19.8524 21.6775 19.6343 22.6405 19.6343C23.6035 19.6343 24.4773 19.8524 25.2365 20.2834C25.9949 20.7144 26.5972 21.3226 27.0258 22.0917C27.456 22.864 27.6743 23.7556 27.6743 24.7424C27.6743 25.4373 27.5256 26.0633 27.232 26.6036C26.9408 27.1399 26.5318 27.5649 26.0163 27.8663C25.4992 28.1682 24.9036 28.321 24.2449 28.321C23.5862 28.321 22.99 28.1682 22.4735 27.8663C21.958 27.5649 21.549 27.1404 21.2578 26.6036C20.9642 26.0633 20.8155 25.4367 20.8155 24.7424C20.8155 25.7292 21.0338 26.6209 21.464 27.393C21.8926 28.1623 22.4949 28.7704 23.2533 29.2014C24.0119 29.6323 24.8852 29.8506 25.8493 29.8506C26.8135 29.8506 27.6862 29.6323 28.4446 29.2014C29.2032 28.7704 29.8053 28.1617 30.234 27.393C30.6643 26.6209 30.8825 25.7292 30.8825 24.7424C30.8825 23.5083 30.5948 22.3884 30.027 21.4142C29.4588 20.438 28.661 19.6664 27.657 19.1213C26.6566 18.578 25.508 18.3027 24.2443 18.3027C22.9805 18.3027 21.8315 18.578 20.831 19.1213C19.8269 19.6664 19.0292 20.4374 18.4609 21.4142C17.8932 22.3884 17.6055 23.5083 17.6055 24.7424H17.6073Z",fill:"white"}),i.jsx("path",{d:"M17.6072 24.7424C17.6072 23.7556 17.8253 22.864 18.2558 22.0917C18.6843 21.3232 19.2865 20.7144 20.045 20.2834C20.8042 19.8524 21.6775 19.6343 22.6405 19.6343C23.6035 19.6343 24.4773 19.8524 25.2363 20.2834C25.9949 20.7144 26.597 21.3226 27.0256 22.0917C27.456 22.864 27.6742 23.7556 27.6742 24.7424C27.6742 25.4373 27.5256 26.0633 27.2319 26.6036C26.9406 27.1399 26.5316 27.5649 26.0163 27.8663C25.4992 28.1682 24.9035 28.321 24.2449 28.321C23.5862 28.321 22.9899 28.1682 22.4733 27.8663C21.958 27.5649 21.549 27.1404 21.2578 26.6036C20.964 26.0633 20.8155 25.4367 20.8155 24.7424C20.8155 25.7292 21.0336 26.6209 21.464 27.393C21.8926 28.1623 22.4948 28.7704 23.2533 29.2014C24.0118 29.6323 24.885 29.8504 25.8492 29.8504C26.8135 29.8504 27.686 29.6323 28.4446 29.2014C29.2032 28.7704 29.8053 28.1617 30.2339 27.393C30.6643 26.6209 30.8825 25.7292 30.8825 24.7424C30.8825 23.5083 30.5948 22.3884 30.027 21.4142C29.4588 20.438 28.661 19.6664 27.657 19.1213C26.6565 18.578 25.508 18.3027 24.2442 18.3027C22.9805 18.3027 21.8313 18.578 20.8309 19.1213C19.8269 19.6664 19.0292 20.4374 18.4609 21.4142C17.8932 22.3884 17.6055 23.5083 17.6055 24.7424H17.6072Z",fill:`url(#${t}-paint-0)`}),i.jsx("path",{d:"M41.6791 24.6258C41.0531 23.9767 40.1179 23.5308 38.8969 23.3002L36.5435 22.8692C35.7981 22.7276 35.4831 22.5744 35.3499 22.4704C35.1865 22.3431 35.1073 22.2075 35.1073 22.0559C35.1073 21.9627 35.1073 21.6791 35.6429 21.4015C36.0525 21.1892 36.5798 21.0817 37.2099 21.0817C38.3548 21.0817 39.4248 21.4585 40.3902 22.2022C40.4639 22.2592 40.5561 22.2902 40.6488 22.2902C40.7791 22.2902 40.8991 22.2314 40.9793 22.1291L42.2705 20.4789C42.4096 20.3012 42.3841 20.0462 42.2116 19.8981C41.5946 19.3691 40.8641 18.9702 40.0383 18.7128C39.1662 18.4411 38.2425 18.3032 37.2925 18.3032C36.2821 18.3032 35.3618 18.4595 34.5569 18.7675C33.7378 19.0814 33.0875 19.5409 32.6238 20.1329C32.1535 20.7339 31.9152 21.4479 31.9152 22.2539C31.9152 23.1479 32.2159 23.9077 32.8086 24.5122C33.3906 25.1061 34.2698 25.5175 35.4218 25.7362L37.9572 26.2165C38.5236 26.3301 38.9231 26.4757 39.1449 26.6487C39.3392 26.8009 39.4296 26.9691 39.4296 27.1795C39.4296 27.4749 39.2572 27.7247 38.9029 27.9428C38.5142 28.1818 37.9839 28.3036 37.3271 28.3036C35.9058 28.3036 34.6585 27.8589 33.6206 26.9816C33.5452 26.9179 33.4495 26.8829 33.3508 26.8829C33.2242 26.8829 33.1052 26.9388 33.0251 27.0369L31.6275 28.7369C31.4823 28.9135 31.5038 29.1704 31.6756 29.3219C32.2921 29.8652 33.0988 30.2998 34.0736 30.6137C35.1062 30.9465 36.2398 31.1154 37.4435 31.1154C38.4576 31.1154 39.3642 30.9465 40.1388 30.6137C40.9258 30.2754 41.5446 29.7887 41.9798 29.1662C42.4173 28.5397 42.6391 27.8102 42.6391 26.9982C42.6391 26.0834 42.3168 25.2851 41.6808 24.6252L41.6791 24.6258Z",fill:`url(#${t}-paint-1)`}),i.jsx("path",{d:"M12.9952 24.6802L18.8296 19.0464C19.0549 18.8271 19.0123 18.6261 18.9817 18.5529C18.9513 18.4799 18.8477 18.3032 18.5312 18.3032H15.5957C15.3764 18.3032 15.0963 18.4129 14.9319 18.5712L10.0172 23.3951V18.7357C10.0172 18.4981 9.82227 18.3032 9.58476 18.3032H7.26443C7.02692 18.3032 6.83203 18.4981 6.83203 18.7357V30.6249C6.83203 30.8624 7.02692 31.0574 7.26443 31.0574H9.58476C9.82227 31.0574 10.0172 30.8624 10.0172 30.6249V25.9655L14.9319 30.7894C15.0902 30.9417 15.3703 31.0574 15.5896 31.0574H18.525C18.8417 31.0574 18.9453 30.8807 18.9757 30.8077C19.0062 30.7345 19.0487 30.5335 18.8234 30.3142L12.9952 24.6802Z",fill:"white"})]})]}),i.jsxs("defs",{children:[i.jsxs("linearGradient",{id:`${t}-paint-0`,x1:"24.2439",y1:"19.4779",x2:"24.2439",y2:"28.6754",gradientUnits:"userSpaceOnUse",children:[i.jsx("stop",{offset:"0.0358168",stopColor:"#82E1FF"}),i.jsx("stop",{offset:"0.228529",stopColor:"#78E6A0"}),i.jsx("stop",{offset:"0.436866",stopColor:"#FFB400"}),i.jsx("stop",{offset:"0.619161",stopColor:"#FF8700"}),i.jsx("stop",{offset:"0.811872",stopColor:"#FF5A00"}),i.jsx("stop",{offset:"1",stopColor:"#F40000"})]}),i.jsxs("linearGradient",{id:`${t}-paint-1`,x1:"37.0852",y1:"19.6069",x2:"37.0852",y2:"29.8117",gradientUnits:"userSpaceOnUse",children:[i.jsx("stop",{offset:"0.0358168",stopColor:"#82E1FF"}),i.jsx("stop",{offset:"0.228529",stopColor:"#78E6A0"}),i.jsx("stop",{offset:"0.436866",stopColor:"#FFB400"}),i.jsx("stop",{offset:"0.619161",stopColor:"#FF8700"}),i.jsx("stop",{offset:"0.811872",stopColor:"#FF5A00"}),i.jsx("stop",{offset:"1",stopColor:"#F40000"})]}),i.jsx("clipPath",{id:`${t}-clip-0`,children:i.jsx("rect",{width:"48",height:"48",fill:"white"})})]})]})}),[Ee]=M(["collapsible-artifact-version"]),Lh=d.memo(({onListItemAction:e,isSelected:t,isInherited:o,id:n,name:r,createdAt:s,description:l})=>{const a=d.useCallback(()=>{e&&!o&&e(n,t?"deselect":"select")},[n,o,t,e]);return i.jsx(z.ClassNames,{children:({cx:u})=>i.jsxs(Bh,{onClick:a,className:u({isSelected:t,isInherited:o}),children:[i.jsxs(Wh,{children:[i.jsxs(Ph,{children:[i.jsx(E,{variant:"small",color:"dark",bold:!0,children:r}),!!s&&i.jsx(E,{color:"grey",variant:"small",children:s})]}),l&&i.jsx(bo,{color:"grey",variant:"small",children:`${l}${l}`})]}),t?i.jsx(Vh,{size:"xsm",color:"blue",iconId:t?"Check":"InfoCircle"}):o?i.jsx(R,{iconId:"Inherited",color:"purple"}):null]})})}),Bh=g.div`
1977
1977
  width: 100%;
1978
1978
  position: relative;
1979
1979
  display: flex;
@@ -1997,7 +1997,7 @@
1997
1997
  :hover:not(.isSelected):not(.isInherited) {
1998
1998
  border-color: ${Ee("border-color-hover")};
1999
1999
  }
2000
- `,Wp=g.div`
2000
+ `,Wh=g.div`
2001
2001
  width: 100%;
2002
2002
  display: flex;
2003
2003
  align-items: flex-start;
@@ -2005,28 +2005,28 @@
2005
2005
  flex-direction: column;
2006
2006
  row-gap: 1px;
2007
2007
  overflow: hidden;
2008
- `,Pp=g.div`
2008
+ `,Ph=g.div`
2009
2009
  width: 100%;
2010
2010
  display: flex;
2011
2011
  align-items: center;
2012
2012
  justify-content: flex-start;
2013
2013
  gap: 8px;
2014
- `,Vp=g(R)`
2014
+ `,Vh=g(R)`
2015
2015
  position: absolute;
2016
2016
  top: 50%;
2017
2017
  transform: translateY(-50%);
2018
2018
  right: 8px;
2019
- `,[Vt,Lo,Hp]=M(["collapsible-list-container","collapsible-list-header-container","collapsible-list-toggled-container"]),Up=({headerContent:e,toggledContent:t,isOpen:o,onOpenChange:n})=>i.jsx(go,{open:o,onOpenChange:n,children:i.jsxs(Kp,{children:[i.jsx(fn,{children:i.jsxs(Yp,{children:[i.jsx(ae,{className:"caret-button",color:"black",size:"xsm",iconId:"CaretRight"}),e]})}),i.jsx(mo,{children:i.jsx(Gp,{children:t})})]})}),Gp=g.div`
2019
+ `,[Vt,Lo,Hh]=M(["collapsible-list-container","collapsible-list-header-container","collapsible-list-toggled-container"]),Uh=({headerContent:e,toggledContent:t,isOpen:o,onOpenChange:n})=>i.jsx(go,{open:o,onOpenChange:n,children:i.jsxs(Kh,{children:[i.jsx(fn,{children:i.jsxs(Yh,{children:[i.jsx(ae,{className:"caret-button",color:"black",size:"xsm",iconId:"CaretRight"}),e]})}),i.jsx(mo,{children:i.jsx(Gh,{children:t})})]})}),Gh=g.div`
2020
2020
  flex-direction: column;
2021
- gap: ${Hp("gap")};
2022
- `,Kp=g.div`
2021
+ gap: ${Hh("gap")};
2022
+ `,Kh=g.div`
2023
2023
  border-radius: ${Vt("border-radius")};
2024
2024
  border: ${Vt("border-width")} solid ${Vt("border-color")};
2025
2025
  display: flex;
2026
2026
  flex-direction: column;
2027
2027
  overflow: hidden;
2028
2028
  position: relative;
2029
- `,Yp=g.div`
2029
+ `,Yh=g.div`
2030
2030
  align-items: center;
2031
2031
  background-color: ${Lo("background-color")};
2032
2032
  cursor: pointer;
@@ -2042,11 +2042,11 @@
2042
2042
  border-bottom: ${Vt("border-width")} solid
2043
2043
  ${Vt("border-color")};
2044
2044
  }
2045
- `,[br]=M(["combobox"]),qp=d.memo(({isDeletable:e,inputText:t,setInputText:o,onSelectionChange:n,placeholder:r,setIsOpen:s,tooltipText:l,onKeyDown:a})=>{const u=d.useCallback(h=>{o(h.target.value??"")},[o]),p=d.useCallback(()=>{o(""),n("select",void 0),s(!1)},[n,o,s]);return i.jsxs(Zp,{children:[i.jsx(Jp,{value:t,onChange:u,onKeyDown:a,placeholder:r,autoFocus:!0,className:e?"isDeletable":void 0}),e&&i.jsx(Xp,{children:i.jsx(Gs,{variant:"dark",content:l,children:i.jsx(ae,{onClick:p,iconId:"DeleteOutlined",color:"red",size:"sm"})})})]})}),Zp=g.div`
2045
+ `,[br]=M(["combobox"]),qh=d.memo(({isDeletable:e,inputText:t,setInputText:o,onSelectionChange:n,placeholder:r,setIsOpen:s,tooltipText:l,onKeyDown:a})=>{const u=d.useCallback(p=>{o(p.target.value??"")},[o]),h=d.useCallback(()=>{o(""),n("select",void 0),s(!1)},[n,o,s]);return i.jsxs(Zh,{children:[i.jsx(Jh,{value:t,onChange:u,onKeyDown:a,placeholder:r,autoFocus:!0,className:e?"isDeletable":void 0}),e&&i.jsx(Xh,{children:i.jsx(Gs,{variant:"dark",content:l,children:i.jsx(ae,{onClick:h,iconId:"DeleteOutlined",color:"red",size:"sm"})})})]})}),Zh=g.div`
2046
2046
  width: 100%;
2047
2047
  position: relative;
2048
2048
  display: flex;
2049
- `,Xp=g.div`
2049
+ `,Xh=g.div`
2050
2050
  position: absolute;
2051
2051
  right: 8px;
2052
2052
  top: 50%;
@@ -2054,7 +2054,7 @@
2054
2054
  align-items: center;
2055
2055
  justify-content: center;
2056
2056
  transform: translateY(-50%);
2057
- `,Jp=g(Tt)`
2057
+ `,Jh=g(Tt)`
2058
2058
  border-radius: ${br("input-border-radius")};
2059
2059
  height: ${br("height")};
2060
2060
  width: 100%;
@@ -2062,10 +2062,10 @@
2062
2062
  &.isDeletable {
2063
2063
  padding-right: ${c("spacing-32")};
2064
2064
  }
2065
- `,Qp=d.memo(({name:e})=>i.jsxs(i.Fragment,{children:[i.jsx(R,{iconId:"Check",color:"black",className:"option-label-icon",size:"xsm"}),i.jsx(bo,{variant:"body",color:"dark",children:e})]})),[Re,eh]=M(["combobox","option"]),th=({optionsToRender:e,inputText:t,handleSelectionChange:o,handleInputChange:n,isDeletable:r,OptionLabelComponent:s,placeholder:l,createNode:a,createText:u,className:p,onEnter:h,t:f})=>{const{setIsOpen:m,selectedIndex:b}=In(),x=d.useCallback(()=>{o("create",{id:t,name:t}),m(!1)},[t,m,o]),y=d.useMemo(()=>!e.length||!e.some(v=>v.name.toLowerCase()===t.toLowerCase()),[t,e]),k=d.useCallback(v=>{v.code==="Enter"&&t&&h&&h(t,()=>m(!1))},[t,h,m]);return i.jsxs(nh,{className:p,children:[i.jsx(qp,{inputText:t,setIsOpen:m,onSelectionChange:o,setInputText:n,isDeletable:r,onKeyDown:h?k:void 0,placeholder:l??"Enter a name",tooltipText:(f==null?void 0:f("comboBox.tooltipText"))??"Remove?"}),e.map((v,$)=>i.jsx(ih,{label:s?i.jsx(s,{...v,selected:b===$}):i.jsx(Qp,{name:v.name}),optionKey:v.id,disabled:v.isHeader},v.id)),y&&t?a?i.jsx(sh,{onClick:x,children:a}):i.jsx(rh,{size:"med",onClick:x,children:u??"Create?"}):null]})},Xs=({children:e,deletable:t,options:o,selected:n,onInputChange:r,onSelectionChange:s,requiresSelection:l,...a})=>{const u=d.useRef(n==null?void 0:n.id),[p,h]=d.useState(l?"":(n==null?void 0:n.name)??""),f=!!n&&n.name===p,m=t!==void 0?t:f&&!l;d.useLayoutEffect(()=>{u.current!==(n==null?void 0:n.id)&&(h(l?"":(n==null?void 0:n.name)??""),u.current=n==null?void 0:n.id)},[n,l]);const b=d.useCallback($=>{h($),r==null||r($)},[r]),x=d.useCallback(($,C)=>{u.current=C==null?void 0:C.id,h(l?"":(C==null?void 0:C.name)??""),s($,C==null?void 0:C.id)},[s,l]),y=d.useCallback($=>{const C=o.find(S=>S.id===$);C&&x("select",C)},[x,o]),k=d.useMemo(()=>f?o:o.filter($=>$.name.toLowerCase().includes(p.toLowerCase())||$.isHeader),[p,o,f]),v=d.useMemo(()=>k.findIndex($=>$.id===(n==null?void 0:n.id)),[k,n==null?void 0:n.id]);return i.jsx(oh,{selectedIndex:v,isFocusTrapDisabled:!0,onSelect:y,Reference:e,children:i.jsx(th,{...a,handleInputChange:b,handleSelectionChange:x,optionsToRender:k,isDeletable:m,inputText:p})})},oh=g(Et)`
2065
+ `,Qh=d.memo(({name:e})=>i.jsxs(i.Fragment,{children:[i.jsx(R,{iconId:"Check",color:"black",className:"option-label-icon",size:"xsm"}),i.jsx(bo,{variant:"body",color:"dark",children:e})]})),[Re,ep]=M(["combobox","option"]),tp=({optionsToRender:e,inputText:t,handleSelectionChange:o,handleInputChange:n,isDeletable:r,OptionLabelComponent:s,placeholder:l,createNode:a,createText:u,className:h,onEnter:p,t:f})=>{const{setIsOpen:m,selectedIndex:b}=In(),x=d.useCallback(()=>{o("create",{id:t,name:t}),m(!1)},[t,m,o]),y=d.useMemo(()=>!e.length||!e.some(v=>v.name.toLowerCase()===t.toLowerCase()),[t,e]),k=d.useCallback(v=>{v.code==="Enter"&&t&&p&&p(t,()=>m(!1))},[t,p,m]);return i.jsxs(np,{className:h,children:[i.jsx(qh,{inputText:t,setIsOpen:m,onSelectionChange:o,setInputText:n,isDeletable:r,onKeyDown:p?k:void 0,placeholder:l??"Enter a name",tooltipText:(f==null?void 0:f("comboBox.tooltipText"))??"Remove?"}),e.map((v,$)=>i.jsx(ip,{label:s?i.jsx(s,{...v,selected:b===$}):i.jsx(Qh,{name:v.name}),optionKey:v.id,disabled:v.isHeader},v.id)),y&&t?a?i.jsx(sp,{onClick:x,children:a}):i.jsx(rp,{size:"med",onClick:x,children:u??"Create?"}):null]})},Xs=({children:e,deletable:t,options:o,selected:n,onInputChange:r,onSelectionChange:s,requiresSelection:l,...a})=>{const u=d.useRef(n==null?void 0:n.id),[h,p]=d.useState(l?"":(n==null?void 0:n.name)??""),f=!!n&&n.name===h,m=t!==void 0?t:f&&!l;d.useLayoutEffect(()=>{u.current!==(n==null?void 0:n.id)&&(p(l?"":(n==null?void 0:n.name)??""),u.current=n==null?void 0:n.id)},[n,l]);const b=d.useCallback($=>{p($),r==null||r($)},[r]),x=d.useCallback(($,C)=>{u.current=C==null?void 0:C.id,p(l?"":(C==null?void 0:C.name)??""),s($,C==null?void 0:C.id)},[s,l]),y=d.useCallback($=>{const C=o.find(S=>S.id===$);C&&x("select",C)},[x,o]),k=d.useMemo(()=>f?o:o.filter($=>$.name.toLowerCase().includes(h.toLowerCase())||$.isHeader),[h,o,f]),v=d.useMemo(()=>k.findIndex($=>$.id===(n==null?void 0:n.id)),[k,n==null?void 0:n.id]);return i.jsx(op,{selectedIndex:v,isFocusTrapDisabled:!0,onSelect:y,Reference:e,children:i.jsx(tp,{...a,handleInputChange:b,handleSelectionChange:x,optionsToRender:k,isDeletable:m,inputText:h})})},op=g(Et)`
2066
2066
  border-radius: ${Re("border-radius")};
2067
2067
  overflow: hidden;
2068
- `,nh=g.div`
2068
+ `,np=g.div`
2069
2069
  width: 200px;
2070
2070
  height: auto;
2071
2071
  display: flex;
@@ -2077,12 +2077,12 @@
2077
2077
  box-shadow: ${Re("box-shadow")};
2078
2078
  padding: ${Re("padding")};
2079
2079
  row-gap: ${Re("row-gap")};
2080
- `,rh=g(hn)`
2081
- padding: ${eh("padding")};
2082
- `,sh=g.div`
2080
+ `,rp=g(pn)`
2081
+ padding: ${ep("padding")};
2082
+ `,sp=g.div`
2083
2083
  cursor: pointer;
2084
2084
  width: 100%;
2085
- `,ih=g(dt)`
2085
+ `,ip=g(dt)`
2086
2086
  width: 100%;
2087
2087
  display: flex;
2088
2088
  align-items: center;
@@ -2132,60 +2132,60 @@
2132
2132
  pointer-events: none;
2133
2133
  background-color: ${c("color-grey10")};
2134
2134
  }
2135
- `,ah=e=>typeof e=="string"?e.trim().length>0||"Required":!0,lh=e=>{const{register:t}=e,o=d.useCallback((r,s)=>{if(!s||!s.required)return t(r,s);const l=typeof s.validate=="function"?{default:s.validate}:s.validate,a={...s,validate:{...l,whitespaces:ah}};return t(r,a)},[t]),n=d.useMemo(()=>({...e.control,register:o}),[e.control,o]);return{...e,register:o,control:n}};function Qs({children:e,onSubmit:t,onRootErrorChange:o,className:n,defaultValues:r,variant:s="submit",...l}){const a=q.useForm({shouldUnregister:!0,defaultValues:r,...l,mode:s==="blur"?"onBlur":l.mode}),u=lh(a),p=u.formState.errors.root;d.useEffect(()=>{o&&o(p)},[p,o]);const h=d.useCallback(async f=>{await t(f,u.setError)},[u.setError,t]);return i.jsx(q.FormProvider,{...u,children:i.jsx("form",{className:n,onSubmit:s==="blur"?void 0:u.handleSubmit(h),onBlur:s==="blur"?u.handleSubmit(h):void 0,children:e})})}const ch=d.memo(()=>i.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:i.jsx("path",{d:"M5.99961 3.6001C5.35761 3.6001 4.75761 3.8481 4.30361 4.3041C3.84961 4.7581 3.59961 5.3581 3.59961 6.0001C3.59961 6.6421 3.84961 7.2421 4.30361 7.6961C4.75761 8.1481 5.35961 8.4001 5.99961 8.4001C6.63961 8.4001 7.24161 8.1501 7.69561 7.6961C8.14761 7.2421 8.39961 6.6401 8.39961 6.0001C8.39961 5.3601 8.14961 4.7581 7.69561 4.3041C7.24161 3.8481 6.64161 3.6001 5.99961 3.6001Z",fill:"#262626"})})),dh=e=>e===void 0?i.jsx(ch,{}):e?i.jsx(R,{iconId:"Check",color:"green",size:"sm"}):i.jsx(R,{iconId:"Close",color:"red",size:"sm"}),ei=d.memo(({isBlank:e,requirements:t,metRequirements:o,bulletGetter:n,className:r,t:s,title:l})=>i.jsxs(uh,{className:r,children:[!!l&&i.jsx(E,{color:"dark",bold:!0,variant:"body",children:l}),i.jsx(ph,{children:t.map(a=>{const u=e?void 0:o.includes(a.id);return i.jsxs(hh,{children:[n?n(a.id,u):dh(u),i.jsx(fh,{variant:"body",color:"dark",children:s?s(a.textKey):a.id})]},a.id)})})]})),uh=g.div`
2135
+ `,ap=e=>typeof e=="string"?e.trim().length>0||"Required":!0,lp=e=>{const{register:t}=e,o=d.useCallback((r,s)=>{if(!s||!s.required)return t(r,s);const l=typeof s.validate=="function"?{default:s.validate}:s.validate,a={...s,validate:{...l,whitespaces:ap}};return t(r,a)},[t]),n=d.useMemo(()=>({...e.control,register:o}),[e.control,o]);return{...e,register:o,control:n}};function Qs({children:e,onSubmit:t,onRootErrorChange:o,className:n,defaultValues:r,variant:s="submit",...l}){const a=G.useForm({shouldUnregister:!0,defaultValues:r,...l,mode:s==="blur"?"onBlur":l.mode}),u=lp(a),h=u.formState.errors.root;d.useEffect(()=>{o&&o(h)},[h,o]);const p=d.useCallback(async f=>{await t(f,u.setError)},[u.setError,t]);return i.jsx(G.FormProvider,{...u,children:i.jsx("form",{className:n,onSubmit:s==="blur"?void 0:u.handleSubmit(p),onBlur:s==="blur"?u.handleSubmit(p):void 0,children:e})})}const cp=d.memo(()=>i.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:i.jsx("path",{d:"M5.99961 3.6001C5.35761 3.6001 4.75761 3.8481 4.30361 4.3041C3.84961 4.7581 3.59961 5.3581 3.59961 6.0001C3.59961 6.6421 3.84961 7.2421 4.30361 7.6961C4.75761 8.1481 5.35961 8.4001 5.99961 8.4001C6.63961 8.4001 7.24161 8.1501 7.69561 7.6961C8.14761 7.2421 8.39961 6.6401 8.39961 6.0001C8.39961 5.3601 8.14961 4.7581 7.69561 4.3041C7.24161 3.8481 6.64161 3.6001 5.99961 3.6001Z",fill:"#262626"})})),dp=e=>e===void 0?i.jsx(cp,{}):e?i.jsx(R,{iconId:"Check",color:"green",size:"sm"}):i.jsx(R,{iconId:"Close",color:"red",size:"sm"}),ei=d.memo(({isBlank:e,requirements:t,metRequirements:o,bulletGetter:n,className:r,t:s,title:l})=>i.jsxs(up,{className:r,children:[!!l&&i.jsx(E,{color:"dark",bold:!0,variant:"body",children:l}),i.jsx(hp,{children:t.map(a=>{const u=e?void 0:o.includes(a.id);return i.jsxs(pp,{children:[n?n(a.id,u):dp(u),i.jsx(fp,{variant:"body",color:"dark",children:s?s(a.textKey):a.id})]},a.id)})})]})),up=g.div`
2136
2136
  display: flex;
2137
2137
  align-items: flex-start;
2138
2138
  justify-content: flex-start;
2139
2139
  flex-direction: column;
2140
- `,ph=g.ul`
2140
+ `,hp=g.ul`
2141
2141
  margin: 0px;
2142
2142
  padding-left: 0px;
2143
2143
  row-gap: 4px;
2144
2144
  list-style-type: none;
2145
2145
  list-style-position: inside;
2146
- `,hh=g.li`
2146
+ `,pp=g.li`
2147
2147
  margin: 0;
2148
2148
  align-items: center;
2149
2149
  display: flex;
2150
2150
  justify-content: flex-start;
2151
- `,fh=g(E)`
2151
+ `,fp=g(E)`
2152
2152
  margin-left: 4px;
2153
- `,gh=()=>q.useFormContext(),[xr]=M(["form"]),Tn=[{textKey:"passwordRequirements.length",id:"length"},{textKey:"passwordRequirements.uppercaseAndNumber",id:"uppercaseAndNumber"},{textKey:"passwordRequirements.specialCharacter",id:"specialCharacter"}],ti=[{textKey:"passwordRequirements.tooSimilar",id:"tooSimilar"},...Tn],mh=d.memo(({name:e,t,hasLabel:o,includeTooSimilar:n})=>{const{getFieldState:r,formState:s}=gh(),{error:l,isDirty:a}=r(e??"password",s),u=d.useMemo(()=>{const p=(l==null?void 0:l.types)??{},h=[];return!p.minLength&&!p.required&&h.push("length"),!p.tooSimilar&&n&&h.push("tooSimilar"),!p[Wt.noDigit]&&!p[Wt.noUpperCase]&&h.push("uppercaseAndNumber"),p[Wt.noSpecialCharacter]||h.push("specialCharacter"),h},[l==null?void 0:l.types,n]);return i.jsx(z.ClassNames,{children:({cx:p})=>i.jsx(bh,{t,className:p({hasLabel:o}),isBlank:!a&&!l,requirements:n?ti:Tn,title:(t==null?void 0:t("passwordRequirements.title"))??"Password Requirements",metRequirements:u})})}),bh=g(ei)`
2153
+ `,gp=()=>G.useFormContext(),[xr]=M(["form"]),Tn=[{textKey:"passwordRequirements.length",id:"length"},{textKey:"passwordRequirements.uppercaseAndNumber",id:"uppercaseAndNumber"},{textKey:"passwordRequirements.specialCharacter",id:"specialCharacter"}],ti=[{textKey:"passwordRequirements.tooSimilar",id:"tooSimilar"},...Tn],mp=d.memo(({name:e,t,hasLabel:o,includeTooSimilar:n})=>{const{getFieldState:r,formState:s}=gp(),{error:l,isDirty:a}=r(e??"password",s),u=d.useMemo(()=>{const h=(l==null?void 0:l.types)??{},p=[];return!h.minLength&&!h.required&&p.push("length"),!h.tooSimilar&&n&&p.push("tooSimilar"),!h[Wt.noDigit]&&!h[Wt.noUpperCase]&&p.push("uppercaseAndNumber"),h[Wt.noSpecialCharacter]||p.push("specialCharacter"),p},[l==null?void 0:l.types,n]);return i.jsx(z.ClassNames,{children:({cx:h})=>i.jsx(bp,{t,className:h({hasLabel:o}),isBlank:!a&&!l,requirements:n?ti:Tn,title:(t==null?void 0:t("passwordRequirements.title"))??"Password Requirements",metRequirements:u})})}),bp=g(ei)`
2154
2154
  width: 100%;
2155
2155
  align-items: flex-start;
2156
2156
  justify-content: flex-start;
2157
2157
  &.hasLabel {
2158
2158
  padding-left: calc(${xr("label-width")} + ${xr("label-column-gap")});
2159
2159
  }
2160
- `,[pt]=M(["form"]),Se=d.forwardRef(({className:e,required:t,formItemId:o,isValid:n,...r},s)=>i.jsx(z.ClassNames,{children:({cx:l})=>i.jsx(xh,{ref:s,"aria-required":t,"aria-invalid":!n,className:l(e,"form-label"),htmlFor:o,...r})})),xh=g.label`
2161
- font-family: ${pt("label-font-family")};
2162
- font-size: ${pt("label-font-size")};
2163
- font-weight: ${pt("label-font-weight")};
2164
- height: ${pt("label-height")};
2165
- line-height: ${pt("label-line-height")};
2160
+ `,[ht]=M(["form"]),me=d.forwardRef(({className:e,required:t,formItemId:o,isValid:n,...r},s)=>i.jsx(z.ClassNames,{children:({cx:l})=>i.jsx(xp,{ref:s,"aria-required":t,"aria-invalid":!n,className:l(e,"form-label"),htmlFor:o,...r})})),xp=g.label`
2161
+ font-family: ${ht("label-font-family")};
2162
+ font-size: ${ht("label-font-size")};
2163
+ font-weight: ${ht("label-font-weight")};
2164
+ height: ${ht("label-height")};
2165
+ line-height: ${ht("label-line-height")};
2166
2166
  text-align: right;
2167
2167
  width: 100%;
2168
2168
  &[aria-required="true"] {
2169
2169
  ::before {
2170
2170
  content: "*";
2171
- padding-right: ${pt("label-star-padding")};
2172
- color: ${pt("label-error-color")};
2171
+ padding-right: ${ht("label-star-padding")};
2172
+ color: ${ht("label-error-color")};
2173
2173
  }
2174
2174
  }
2175
- `;Se.displayName="FormLabel";const[Bo]=M(["form"]),Ke=d.memo(({handleError:e,name:t,hasLabel:o})=>{const{getFieldState:n,formState:r}=q.useFormContext(),{error:s}=n(t,r);if(!s)return null;const l=e==="message"?s.message:e(s);return l?i.jsx(yh,{className:o?"hasLabel":void 0,variant:"body",color:"red",children:l}):null}),yh=g(E)`
2175
+ `;me.displayName="FormLabel";const[Bo]=M(["form"]),Ye=d.memo(({handleError:e,name:t,hasLabel:o})=>{const{getFieldState:n,formState:r}=G.useFormContext(),{error:s}=n(t,r);if(!s)return null;const l=e==="message"?s.message:e(s);return l?i.jsx(yp,{className:o?"hasLabel":void 0,variant:"body",color:"red",children:l}):null}),yp=g(E)`
2176
2176
  width: 100%;
2177
2177
  margin-top: ${Bo("error-message-top-margin")};
2178
2178
  &.hasLabel {
2179
2179
  padding-left: calc(${Bo("label-width")} + ${Bo("label-column-gap")});
2180
2180
  }
2181
- `,[nn]=M(["form"]),rt=g.div`
2181
+ `,[nn]=M(["form"]),qe=g.div`
2182
2182
  display: flex;
2183
2183
  align-items: center;
2184
2184
  justify-content: flex-start;
2185
2185
  flex-direction: column;
2186
2186
  width: 100%;
2187
2187
  position: relative;
2188
- `,Ye=g.div`
2188
+ `,Ae=g.div`
2189
2189
  display: grid;
2190
2190
  align-items: center;
2191
2191
  grid-template-columns: 1fr;
@@ -2194,7 +2194,7 @@
2194
2194
  &.hasLabel {
2195
2195
  grid-template-columns: ${nn("label-width")} 1fr;
2196
2196
  }
2197
- `,oi=g(Ye)`
2197
+ `,oi=g(Ae)`
2198
2198
  align-items: flex-start;
2199
2199
 
2200
2200
  /*
@@ -2213,25 +2213,25 @@
2213
2213
  right: 0;
2214
2214
  top: 0;
2215
2215
  pointer-events: none;
2216
- `,vh=({name:e,disabled:t,label:o,className:n,handleError:r,showIcons:s,readOnly:l,...a})=>{const{control:u}=q.useFormContext(),{field:{onChange:p,value:h,disabled:f},fieldState:{error:m}}=q.useController({name:e,control:u,rules:a,disabled:t}),b=d.useId();return i.jsx(z.ClassNames,{children:({cx:x})=>i.jsxs(rt,{children:[i.jsxs(Ye,{className:x({hasLabel:!!o}),children:[o&&i.jsx(Se,{formItemId:b,isValid:!m,required:!!a.required,children:o}),i.jsx(kh,{children:i.jsx(vo,{checked:h,disabled:f,readOnly:l,onChange:p,showIcons:s,id:b})})]}),!!r&&i.jsx(Ke,{handleError:r,name:e,hasLabel:!!o})]})})},kh=g.div`
2216
+ `,vp=({name:e,disabled:t,label:o,className:n,handleError:r,showIcons:s,readOnly:l,...a})=>{const{control:u}=G.useFormContext(),{field:{onChange:h,value:p,disabled:f},fieldState:{error:m}}=G.useController({name:e,control:u,rules:a,disabled:t}),b=d.useId();return i.jsx(z.ClassNames,{children:({cx:x})=>i.jsxs(qe,{children:[i.jsxs(Ae,{className:x({hasLabel:!!o}),children:[o&&i.jsx(me,{formItemId:b,isValid:!m,required:!!a.required,children:o}),i.jsx(kp,{children:i.jsx(vo,{checked:p,disabled:f,readOnly:l,onChange:h,showIcons:s,id:b})})]}),!!r&&i.jsx(Ye,{handleError:r,name:e,hasLabel:!!o})]})})},kp=g.div`
2217
2217
  width: 100%;
2218
2218
  display: flex;
2219
2219
  align-items: center;
2220
2220
  justify-content: flex-start;
2221
- `,wh=({name:e,disabled:t,label:o,placeholder:n,className:r,handleError:s,autoFocus:l,wrap:a,readOnly:u,...p},h)=>{const{control:f}=q.useFormContext(),{field:{ref:m,...b},fieldState:{error:x}}=q.useController({name:e,control:f,rules:p,disabled:t}),y=d.useId(),k=O.useMergeRefs([m,h]);return i.jsx(z.ClassNames,{children:({cx:v})=>i.jsxs(rt,{children:[i.jsxs(oi,{className:v({hasLabel:!!o}),children:[o&&i.jsx(Se,{formItemId:y,isValid:!x,required:!!p.required,children:o}),i.jsx(Dn,{...b,id:y,placeholder:n,ref:k,autoComplete:"off",className:v(r,"form-text-area"),"aria-invalid":!!x,autoFocus:l,readOnly:u,wrap:a})]}),!!s&&i.jsx(Ke,{handleError:s,name:e,hasLabel:!!o})]})})},Ch=It(wh),$h=({onSubmit:e,enabledIfClean:t,disabled:o,...n},r)=>{const{handleSubmit:s,setError:l,formState:{isValid:a,isSubmitting:u,dirtyFields:p}}=q.useFormContext(),h=d.useCallback(async b=>{console.log("[FormSubmit] _onSubmit data:",b),console.log("[FormSubmit] _onSubmit data keys:",Object.keys(b)),await e(b,l)},[l,e]),f=Object.keys(p).length>0,m=!a||u||!t&&!f||o;return i.jsx(Ge,{type:"submit",...n,ref:r,disabled:m,onClick:s(h)})},zn=It($h),ni=({disabled:e,isSmall:t,children:o,value:n,id:r,placeholder:s,prefixIcon:l,prefixIconColor:a,className:u,getLabel:p,getIcon:h,onSelect:f,onKeyDown:m})=>{var I,j;const b=d.useRef(n);d.useEffect(()=>{b.current=n},[n]);const x=d.useCallback(D=>{let L=h==null?void 0:h(D),U=p==null?void 0:p(D),P;return D&&d.Children.forEach(o,B=>{d.isValidElement(B)&&B.props.optionKey&&B.props.optionKey===D&&(P=B)}),P!==void 0&&d.isValidElement(P)&&P.props.label&&(U=U??P.props.label,L=L??P.props.prefixIconId),{label:U??"",iconId:L}},[o,h,p]),y=d.useCallback((D,L)=>{let U=null;return d.Children.forEach(D,(P,B)=>{d.isValidElement(P)&&P.props.optionKey&&P.props.optionKey===L&&(U=B)}),U},[]),[k,v]=d.useState(y(o,n));d.useEffect(()=>{v(y(o,b.current))},[o,y]);const[$,C]=d.useState((I=x(n))==null?void 0:I.label),[S,w]=d.useState((j=x(n))==null?void 0:j.iconId);return d.useEffect(()=>{const D=x(n);C(D==null?void 0:D.label),w(D==null?void 0:D.iconId)},[n,x]),i.jsx(z.ClassNames,{children:({cx:D})=>i.jsx(jh,{onSelect:f,disabled:e,matchReferenceWidth:!0,selectedIndex:k,onSelectedIndexChange:v,Reference:i.jsx(Sh,{value:$??"",disabled:e,onChange:$e,id:r,onKeyDown:m,isSmall:t,prefixIconId:l||S,prefixIconColor:a,type:"text",placeholder:s,autoComplete:"off",className:D(u,"form-input"),suffixIconId:"Down",suffixIconColor:e?"grey":"black"}),children:o})})},Sh=g(Tt)`
2221
+ `,wp=({name:e,disabled:t,label:o,placeholder:n,className:r,handleError:s,autoFocus:l,wrap:a,readOnly:u,...h},p)=>{const{control:f}=G.useFormContext(),{field:{ref:m,...b},fieldState:{error:x}}=G.useController({name:e,control:f,rules:h,disabled:t}),y=d.useId(),k=O.useMergeRefs([m,p]);return i.jsx(z.ClassNames,{children:({cx:v})=>i.jsxs(qe,{children:[i.jsxs(oi,{className:v({hasLabel:!!o}),children:[o&&i.jsx(me,{formItemId:y,isValid:!x,required:!!h.required,children:o}),i.jsx(Dn,{...b,id:y,placeholder:n,ref:k,autoComplete:"off",className:v(r,"form-text-area"),"aria-invalid":!!x,autoFocus:l,readOnly:u,wrap:a})]}),!!s&&i.jsx(Ye,{handleError:s,name:e,hasLabel:!!o})]})})},Cp=It(wp),$p=({onSubmit:e,enabledIfClean:t,disabled:o,...n},r)=>{const{handleSubmit:s,setError:l,formState:{isValid:a,isSubmitting:u,dirtyFields:h}}=G.useFormContext(),p=d.useCallback(async b=>{console.log("[FormSubmit] _onSubmit data:",b),console.log("[FormSubmit] _onSubmit data keys:",Object.keys(b)),await e(b,l)},[l,e]),f=Object.keys(h).length>0,m=!a||u||!t&&!f||o;return i.jsx(Ke,{type:"submit",...n,ref:r,disabled:m,onClick:s(p)})},zn=It($p),ni=({disabled:e,isSmall:t,children:o,value:n,id:r,placeholder:s,prefixIcon:l,prefixIconColor:a,className:u,getLabel:h,getIcon:p,onSelect:f,onKeyDown:m})=>{var I,j;const b=d.useRef(n);d.useEffect(()=>{b.current=n},[n]);const x=d.useCallback(D=>{let L=p==null?void 0:p(D),U=h==null?void 0:h(D),P;return D&&d.Children.forEach(o,B=>{d.isValidElement(B)&&B.props.optionKey&&B.props.optionKey===D&&(P=B)}),P!==void 0&&d.isValidElement(P)&&P.props.label&&(U=U??P.props.label,L=L??P.props.prefixIconId),{label:U??"",iconId:L}},[o,p,h]),y=d.useCallback((D,L)=>{let U=null;return d.Children.forEach(D,(P,B)=>{d.isValidElement(P)&&P.props.optionKey&&P.props.optionKey===L&&(U=B)}),U},[]),[k,v]=d.useState(y(o,n));d.useEffect(()=>{v(y(o,b.current))},[o,y]);const[$,C]=d.useState((I=x(n))==null?void 0:I.label),[S,w]=d.useState((j=x(n))==null?void 0:j.iconId);return d.useEffect(()=>{const D=x(n);C(D==null?void 0:D.label),w(D==null?void 0:D.iconId)},[n,x]),i.jsx(z.ClassNames,{children:({cx:D})=>i.jsx(jp,{onSelect:f,disabled:e,matchReferenceWidth:!0,selectedIndex:k,onSelectedIndexChange:v,Reference:i.jsx(Sp,{value:$??"",disabled:e,onChange:Se,id:r,onKeyDown:m,isSmall:t,prefixIconId:l||S,prefixIconColor:a,type:"text",placeholder:s,autoComplete:"off",className:D(u,"form-input"),suffixIconId:"Down",suffixIconColor:e?"grey":"black"}),children:o})})},Sp=g(Tt)`
2222
2222
  caret-color: transparent;
2223
2223
  user-select: none;
2224
2224
  -webkit-user-select: none;
2225
- `,jh=g(Et)`
2225
+ `,jp=g(Et)`
2226
2226
  max-height: 300px;
2227
- `,Ih=({name:e,disabled:t,label:o,handleError:n,children:r,placeholder:s,prefixIcon:l,prefixIconColor:a,className:u,readOnly:p,onSelectionChange:h,...f})=>{const{control:m}=q.useFormContext(),{field:{ref:b,...x},fieldState:{error:y}}=q.useController({name:e,control:m,rules:f,disabled:t}),k=d.useId(),{onChange:v}=x,$=d.useCallback(C=>{v(C),h&&h(C)},[v,h]);return i.jsx(z.ClassNames,{children:({cx:C})=>i.jsxs(rt,{children:[i.jsxs(Ye,{className:C({hasLabel:!!o}),children:[o&&i.jsx(Se,{formItemId:k,isValid:!y,required:!!f.required,children:o}),i.jsx(ni,{disabled:t||p,onSelect:$,className:u,id:k,value:x.value,children:r})]}),!!n&&i.jsx(Ke,{handleError:n,name:e,hasLabel:!!o}),i.jsx(En,{ref:b,...x})]})})},Dh=({name:e,disabled:t,label:o,placeholder:n,type:r,className:s,handleError:l,prefixIconId:a,prefixIconColor:u,suffixIconColor:p,suffixIconId:h,suffixIcon:f,autoFocus:m,readOnly:b,bold:x,...y},k)=>{const{control:v}=q.useFormContext(),{field:{ref:$,...C},fieldState:{error:S}}=q.useController({name:e,control:v,rules:y,disabled:t}),w=d.useId(),I=O.useMergeRefs([$,k]);return i.jsx(z.ClassNames,{children:({cx:j})=>i.jsxs(rt,{children:[i.jsxs(Ye,{className:j({hasLabel:!!o}),children:[o&&i.jsx(Se,{formItemId:w,isValid:!S,required:!!y.required,children:o}),i.jsx(Tt,{...C,onChange:D=>{y.autoTrim?C.onChange(D.target.value.trim()):C.onChange(D.target.value)},id:w,type:r,autoFocus:m,placeholder:n,ref:I,autoComplete:"off",prefixIconColor:u,prefixIconId:a,suffixIconId:h,suffixIconColor:p,suffixIcon:f,className:j(s,"form-input"),"aria-invalid":!!S,readOnly:b})]}),!!l&&i.jsx(Ke,{handleError:l,name:e,hasLabel:!!o})]})})},Mn=It(Dh),_h=({areaField:e,name:t,disabled:o,readOnly:n,label:r,handleError:s,children:l,className:a,...u})=>{const{control:p}=q.useFormContext(),{field:h,fieldState:{error:f,...m}}=q.useController({name:t,control:p,rules:u,disabled:o}),b=d.useId(),x=e?oi:Ye;return i.jsx(z.ClassNames,{children:({cx:y})=>i.jsxs(rt,{className:a,children:[i.jsxs(x,{className:y("form-input-wrapper",{hasLabel:!!r}),children:[r&&i.jsx(Se,{formItemId:b,isValid:!f,required:!!u.required,children:r}),l(h,{error:f,readOnly:n,...m})]}),!!s&&i.jsx(Ke,{handleError:s,name:t,hasLabel:!!r})]})})},Th=({name:e,disabled:t,label:o,className:n,handleError:r,readOnly:s,...l},a)=>{const{control:u}=q.useFormContext(),{field:{ref:p,...h},fieldState:{error:f}}=q.useController({name:e,control:u,rules:l,disabled:t}),m=d.useId(),b=O.useMergeRefs([p,a]),x=d.useCallback(y=>{y.target.blur(),h.onChange(y)},[h]);return i.jsx(z.ClassNames,{children:({cx:y})=>i.jsxs(rt,{children:[i.jsxs(Ye,{className:y({hasLabel:!!o}),children:[o&&i.jsx(Se,{formItemId:m,isValid:!f,required:!!l.required,children:o}),i.jsx(_t,{checked:!!h.value,disabled:h.disabled||s,onChange:x,id:m,ref:b,className:y(n,"form-checkbox"),"aria-invalid":!!f})]}),!!r&&i.jsx(Ke,{handleError:r,name:e,hasLabel:!!o})]})})},Eh=It(Th),[Ht]=M(["form"]),yr=({control:e,name:t,t:o,readOnly:n})=>{const{field:{onChange:r,value:s,disabled:l}}=q.useController({name:t,control:e,rules:{},disabled:!1}),a=d.useId();return i.jsxs(zh,{children:[i.jsx(Mh,{isValid:!0,formItemId:a,children:(o==null?void 0:o(`access.${t==="locked"?"lock":"hide"}Label`))??t==="locked"?"Lock":"Hide"}),i.jsx(vo,{checked:s,readOnly:l||n,onChange:r,id:a})]})},zh=g.div`
2227
+ `,Ip=({name:e,disabled:t,label:o,handleError:n,children:r,placeholder:s,prefixIcon:l,prefixIconColor:a,className:u,readOnly:h,onSelectionChange:p,...f})=>{const{control:m}=G.useFormContext(),{field:{ref:b,...x},fieldState:{error:y}}=G.useController({name:e,control:m,rules:f,disabled:t}),k=d.useId(),{onChange:v}=x,$=d.useCallback(C=>{v(C),p&&p(C)},[v,p]);return i.jsx(z.ClassNames,{children:({cx:C})=>i.jsxs(qe,{children:[i.jsxs(Ae,{className:C({hasLabel:!!o}),children:[o&&i.jsx(me,{formItemId:k,isValid:!y,required:!!f.required,children:o}),i.jsx(ni,{disabled:t||h,onSelect:$,className:u,id:k,value:x.value,children:r})]}),!!n&&i.jsx(Ye,{handleError:n,name:e,hasLabel:!!o}),i.jsx(En,{ref:b,...x})]})})},Dp=({name:e,disabled:t,label:o,placeholder:n,type:r,className:s,handleError:l,prefixIconId:a,prefixIconColor:u,suffixIconColor:h,suffixIconId:p,suffixIcon:f,autoFocus:m,readOnly:b,bold:x,...y},k)=>{const{control:v}=G.useFormContext(),{field:{ref:$,...C},fieldState:{error:S}}=G.useController({name:e,control:v,rules:y,disabled:t}),w=d.useId(),I=O.useMergeRefs([$,k]);return i.jsx(z.ClassNames,{children:({cx:j})=>i.jsxs(qe,{children:[i.jsxs(Ae,{className:j({hasLabel:!!o}),children:[o&&i.jsx(me,{formItemId:w,isValid:!S,required:!!y.required,children:o}),i.jsx(Tt,{...C,onChange:D=>{y.autoTrim?C.onChange(D.target.value.trim()):C.onChange(D.target.value)},id:w,type:r,autoFocus:m,placeholder:n,ref:I,autoComplete:"off",prefixIconColor:u,prefixIconId:a,suffixIconId:p,suffixIconColor:h,suffixIcon:f,className:j(s,"form-input"),"aria-invalid":!!S,readOnly:b})]}),!!l&&i.jsx(Ye,{handleError:l,name:e,hasLabel:!!o})]})})},Mn=It(Dp),_p=({areaField:e,name:t,disabled:o,readOnly:n,label:r,handleError:s,children:l,className:a,...u})=>{const{control:h}=G.useFormContext(),{field:p,fieldState:{error:f,...m}}=G.useController({name:t,control:h,rules:u,disabled:o}),b=d.useId(),x=e?oi:Ae;return i.jsx(z.ClassNames,{children:({cx:y})=>i.jsxs(qe,{className:a,children:[i.jsxs(x,{className:y("form-input-wrapper",{hasLabel:!!r}),children:[r&&i.jsx(me,{formItemId:b,isValid:!f,required:!!u.required,children:r}),l(p,{error:f,readOnly:n,...m})]}),!!s&&i.jsx(Ye,{handleError:s,name:t,hasLabel:!!r})]})})},Tp=({name:e,disabled:t,label:o,className:n,handleError:r,readOnly:s,...l},a)=>{const{control:u}=G.useFormContext(),{field:{ref:h,...p},fieldState:{error:f}}=G.useController({name:e,control:u,rules:l,disabled:t}),m=d.useId(),b=O.useMergeRefs([h,a]),x=d.useCallback(y=>{y.target.blur(),p.onChange(y)},[p]);return i.jsx(z.ClassNames,{children:({cx:y})=>i.jsxs(qe,{children:[i.jsxs(Ae,{className:y({hasLabel:!!o}),children:[o&&i.jsx(me,{formItemId:m,isValid:!f,required:!!l.required,children:o}),i.jsx(_t,{checked:!!p.value,disabled:p.disabled||s,onChange:x,id:m,ref:b,className:y(n,"form-checkbox"),"aria-invalid":!!f})]}),!!r&&i.jsx(Ye,{handleError:r,name:e,hasLabel:!!o})]})})},Ep=It(Tp),[Ht]=M(["form"]),yr=({control:e,name:t,t:o,readOnly:n})=>{const{field:{onChange:r,value:s,disabled:l}}=G.useController({name:t,control:e,rules:{},disabled:!1}),a=d.useId();return i.jsxs(zp,{children:[i.jsx(Mp,{isValid:!0,formItemId:a,children:(o==null?void 0:o(`access.${t==="locked"?"lock":"hide"}Label`))??t==="locked"?"Lock":"Hide"}),i.jsx(vo,{checked:s,readOnly:l||n,onChange:r,id:a})]})},zp=g.div`
2228
2228
  display: flex;
2229
2229
  align-items: center;
2230
2230
  justify-content: flex-start;
2231
2231
  column-gap: ${Ht("access-toggle-gap")};
2232
- `,Mh=g(Se)`
2232
+ `,Mp=g(me)`
2233
2233
  width: auto;
2234
- `,Oh=({className:e,t,isAdmin:o,hideHide:n,hideLock:r})=>{const{control:s}=q.useFormContext(),l=q.useWatch();return o?i.jsxs(Rh,{className:e,children:[i.jsx(E,{textAlign:"right",variant:"body",color:"dark",children:(t==null?void 0:t("access.label"))??"Access:"}),i.jsxs(Nh,{children:[!n&&i.jsx(yr,{name:"hidden",readOnly:!!l.locked,control:s}),!r&&i.jsx(yr,{name:"locked",control:s})]})]}):null},Rh=g.div`
2234
+ `,Op=({className:e,t,isAdmin:o,hideHide:n,hideLock:r})=>{const{control:s}=G.useFormContext(),l=G.useWatch();return o?i.jsxs(Rp,{className:e,children:[i.jsx(E,{textAlign:"right",variant:"body",color:"dark",children:(t==null?void 0:t("access.label"))??"Access:"}),i.jsxs(Np,{children:[!n&&i.jsx(yr,{name:"hidden",readOnly:!!l.locked,control:s}),!r&&i.jsx(yr,{name:"locked",control:s})]})]}):null},Rp=g.div`
2235
2235
  width: 100%;
2236
2236
  display: grid;
2237
2237
  align-items: center;
@@ -2240,30 +2240,30 @@
2240
2240
  grid-template-columns: ${Ht("label-width")} 1fr;
2241
2241
  height: ${Ht("access-toggle-height")};
2242
2242
  column-gap: ${Ht("label-column-gap")};
2243
- `,Nh=g.div`
2243
+ `,Np=g.div`
2244
2244
  width: 100%;
2245
2245
  height: 100%;
2246
2246
  display: flex;
2247
2247
  align-items: center;
2248
2248
  justify-content: flex-start;
2249
2249
  column-gap: ${Ht("label-column-gap")};
2250
- `,Fh=d.memo(({nameBlackList:e,maxLength:t,t:o,...n})=>{const r=d.useCallback(s=>ks.test(s)?t&&s.length>t?(o==null?void 0:o("form.tooLongName"))??`Cannot be longer than ${t}.`:e&&e.includes(s)?(o==null?void 0:o("form.duplicateName"))??"This name is already taken":!0:(o==null?void 0:o("form.noLeadingOrTrailingSpacesName"))??"Cannot have leading or trailing spaces.",[t,e,o]);return i.jsx(Mn,{validate:r,handleError:"message",name:"name",...n})}),Ah=({name:e,disabled:t,label:o,placeholder:n,type:r,className:s,handleError:l,prefixIconId:a,prefixIconColor:u,suffixIconColor:p,suffixIconId:h,autoFocus:f,readOnly:m,options:b,useLabelAsValue:x,...y})=>{const{control:k}=q.useFormContext(),{field:{ref:v,...$},fieldState:{error:C}}=q.useController({name:e,control:k,rules:y,disabled:t}),S=d.useId(),w=d.useCallback((j,D)=>{$.onChange(D??"")},[$]),I=d.useMemo(()=>{if($.value)return{id:$.value,name:$.value}},[$.value]);return i.jsx(z.ClassNames,{children:({cx:j})=>i.jsxs(rt,{children:[i.jsxs(Ye,{className:j({hasLabel:!!o}),children:[o&&i.jsx(Se,{formItemId:S,isValid:!C,required:!!y.required,children:o}),i.jsx(Xs,{options:b,selected:I,onSelectionChange:w,children:i.jsxs(Lh,{children:[i.jsx(bo,{variant:"body",color:"dark",children:$.value}),i.jsx(Bh,{children:i.jsx(R,{iconId:"Down",size:"sm",color:"black"})})]})})]}),!!l&&i.jsx(Ke,{handleError:l,name:e,hasLabel:!!o}),i.jsx(En,{ref:v,...$})]})})},Lh=g(Js)`
2250
+ `,Fp=d.memo(({nameBlackList:e,maxLength:t,t:o,...n})=>{const r=d.useCallback(s=>ks.test(s)?t&&s.length>t?(o==null?void 0:o("form.tooLongName"))??`Cannot be longer than ${t}.`:e&&e.includes(s)?(o==null?void 0:o("form.duplicateName"))??"This name is already taken":!0:(o==null?void 0:o("form.noLeadingOrTrailingSpacesName"))??"Cannot have leading or trailing spaces.",[t,e,o]);return i.jsx(Mn,{validate:r,handleError:"message",name:"name",...n})}),Ap=({name:e,disabled:t,label:o,placeholder:n,type:r,className:s,handleError:l,prefixIconId:a,prefixIconColor:u,suffixIconColor:h,suffixIconId:p,autoFocus:f,readOnly:m,options:b,useLabelAsValue:x,...y})=>{const{control:k}=G.useFormContext(),{field:{ref:v,...$},fieldState:{error:C}}=G.useController({name:e,control:k,rules:y,disabled:t}),S=d.useId(),w=d.useCallback((j,D)=>{$.onChange(D??"")},[$]),I=d.useMemo(()=>{if($.value)return{id:$.value,name:$.value}},[$.value]);return i.jsx(z.ClassNames,{children:({cx:j})=>i.jsxs(qe,{children:[i.jsxs(Ae,{className:j({hasLabel:!!o}),children:[o&&i.jsx(me,{formItemId:S,isValid:!C,required:!!y.required,children:o}),i.jsx(Xs,{options:b,selected:I,onSelectionChange:w,children:i.jsxs(Lp,{children:[i.jsx(bo,{variant:"body",color:"dark",children:$.value}),i.jsx(Bp,{children:i.jsx(R,{iconId:"Down",size:"sm",color:"black"})})]})})]}),!!l&&i.jsx(Ye,{handleError:l,name:e,hasLabel:!!o}),i.jsx(En,{ref:v,...$})]})})},Lp=g(Js)`
2251
2251
  height: 29px;
2252
2252
  width: 100%;
2253
- `,Bh=g.div`
2253
+ `,Bp=g.div`
2254
2254
  width: 100%;
2255
2255
  height: 100%;
2256
2256
  display: flex;
2257
2257
  align-items: center;
2258
2258
  justify-content: center;
2259
- `,Wh=({name:e,disabled:t,label:o,handleError:n,readOnly:r,placeholder:s,...l})=>{const{control:a}=q.useFormContext(),u=d.useRef(null),{field:{ref:p,value:h,onChange:f,...m},fieldState:{error:b}}=q.useController({name:e,control:a,rules:l,disabled:t}),x=d.useId(),y=O.useMergeRefs([p,u]),k=d.useCallback(()=>{u.current&&u.current.click()},[]),v=d.useCallback(S=>{S.preventDefault()},[]),$=d.useCallback(S=>{S.preventDefault();let w=!1;if(S.dataTransfer.items.length)for(let I=0;I<S.dataTransfer.items.length&&!w;I++){const j=S.dataTransfer.items[I];if(j.kind==="file"){const D=j.getAsFile();D&&(w=!0,f(D))}}},[f]),C=d.useCallback(()=>{f(void 0)},[f]);return i.jsx(z.ClassNames,{children:({cx:S})=>i.jsxs(rt,{children:[i.jsxs(Ye,{className:S({hasLabel:!!o}),children:[o&&i.jsx(Se,{formItemId:x,isValid:!b,required:!!l.required,children:o}),h?i.jsxs(Hh,{children:[i.jsx(R,{iconId:"File",size:"sm",color:"black"}),i.jsx(E,{variant:"body",color:"dark",children:h.name}),i.jsx(Uh,{onClick:C,iconId:"Close",size:"sm",color:"black"})]}):i.jsxs(Ph,{onDrop:$,onClick:k,onDragOver:v,children:[i.jsx(R,{iconId:"File",size:"med",color:"black"}),i.jsx(E,{variant:"body",color:"dark",children:s})]}),i.jsx(Vh,{value:h==null?void 0:h.fileName,...m,id:x,onChange:w=>{w.target.files&&f(w.target.files[0])},type:"file",ref:y})]}),!!n&&i.jsx(Ke,{handleError:n,name:e,hasLabel:!!o})]})})},ri=g.div`
2259
+ `,Wp=({name:e,disabled:t,label:o,handleError:n,readOnly:r,placeholder:s,...l})=>{const{control:a}=G.useFormContext(),u=d.useRef(null),{field:{ref:h,value:p,onChange:f,...m},fieldState:{error:b}}=G.useController({name:e,control:a,rules:l,disabled:t}),x=d.useId(),y=O.useMergeRefs([h,u]),k=d.useCallback(()=>{u.current&&u.current.click()},[]),v=d.useCallback(S=>{S.preventDefault()},[]),$=d.useCallback(S=>{S.preventDefault();let w=!1;if(S.dataTransfer.items.length)for(let I=0;I<S.dataTransfer.items.length&&!w;I++){const j=S.dataTransfer.items[I];if(j.kind==="file"){const D=j.getAsFile();D&&(w=!0,f(D))}}},[f]),C=d.useCallback(()=>{f(void 0)},[f]);return i.jsx(z.ClassNames,{children:({cx:S})=>i.jsxs(qe,{children:[i.jsxs(Ae,{className:S({hasLabel:!!o}),children:[o&&i.jsx(me,{formItemId:x,isValid:!b,required:!!l.required,children:o}),p?i.jsxs(Hp,{children:[i.jsx(R,{iconId:"File",size:"sm",color:"black"}),i.jsx(E,{variant:"body",color:"dark",children:p.name}),i.jsx(Up,{onClick:C,iconId:"Close",size:"sm",color:"black"})]}):i.jsxs(Pp,{onDrop:$,onClick:k,onDragOver:v,children:[i.jsx(R,{iconId:"File",size:"med",color:"black"}),i.jsx(E,{variant:"body",color:"dark",children:s})]}),i.jsx(Vp,{value:p==null?void 0:p.fileName,...m,id:x,onChange:w=>{w.target.files&&f(w.target.files[0])},type:"file",ref:y})]}),!!n&&i.jsx(Ye,{handleError:n,name:e,hasLabel:!!o})]})})},ri=g.div`
2260
2260
  width: 100%;
2261
2261
  padding: ${c("spacing-12")};
2262
2262
  display: flex;
2263
2263
  border: 1px solid ${c("color-grey30")};
2264
2264
  background-color: ${c("color-grey10")};
2265
2265
  border-radius: ${c("spacing-6")};
2266
- `,Ph=g(ri)`
2266
+ `,Pp=g(ri)`
2267
2267
  align-items: center;
2268
2268
  justify-content: center;
2269
2269
  flex-direction: column;
@@ -2273,15 +2273,21 @@
2273
2273
  :hover {
2274
2274
  border-color: ${c("color-grey50")};
2275
2275
  }
2276
- `,Vh=g.input`
2276
+ `,Vp=g.input`
2277
2277
  display: none;
2278
- `,Hh=g(ri)`
2278
+ `,Hp=g(ri)`
2279
2279
  align-items: flex-start;
2280
2280
  justify-content: flex-start;
2281
2281
  column-gap: ${c("spacing-4")};
2282
- `,Uh=g(ae)`
2282
+ `,Up=g(ae)`
2283
2283
  margin-left: auto;
2284
- `,Gh=({name:e,disabled:t,label:o,handleError:n,options:r,selectAllHidden:s,SelectAllItemTemplate:l,ListItemTemplate:a,SelectedItemTemplate:u,className:p,readOnly:h,closeOnSelect:f,...m})=>{const{control:b}=q.useFormContext(),{field:{value:x,onChange:y},fieldState:{error:k}}=q.useController({name:e,control:b,rules:m,disabled:t}),v=d.useId(),$=d.useCallback(C=>{y(C)},[y]);return i.jsx(z.ClassNames,{children:({cx:C})=>i.jsxs(rt,{children:[i.jsxs(Ye,{className:C({hasLabel:!!o}),children:[o&&i.jsx(Se,{formItemId:v,isValid:!k,required:!!m.required,children:o}),i.jsx(Zs,{disabled:t||h,options:r,closeOnSelect:f,onChange:$,selected:x,className:p,SelectAllItemTemplate:l,ListItemTemplate:a,SelectedItemTemplate:u})]}),!!n&&i.jsx(Ke,{handleError:n,name:e,hasLabel:!!o})]})})},Xt=(e,t)=>{const[o,n]=d.useState(!1);return d.useEffect(()=>{async function r(){var s;e!=null&&e.init&&(await((s=e.init)==null?void 0:s.call(e)),t==null||t()),n(!0)}return r(),()=>{var s;(s=e==null?void 0:e.dispose)==null||s.call(e)}},[t,e]),o},mt=d.createContext({isSelected:()=>!1,selected:[],toggleSelection:$e,isDisabled:!1}),Ae=()=>{const e=d.useContext(mt);return e||{isSelected:()=>!1,selected:[],toggleSelection:$e,isDisabled:!1}},On=Symbol.for("kos.list.source"),Gt="__kos_source__";function fo(e,t){return{...e,[On]:t}}function Kt(e){return e[On]??e[Gt]}function Kh(e,t){if(t in e)return e[t];const o=Kt(e);if(o&&typeof o=="object"&&t in o)return o[t]}function Yh(e){return typeof e=="object"&&e!==null&&"locked"in e&&typeof e.locked=="boolean"}const Rn=({groupName:e})=>i.jsx(qh,{children:i.jsx(Zh,{variant:"small",bold:!0,children:e})});Rn.displayName="AsyncListGroupHeader";const qh=g.div`
2284
+ `,Gp=({name:e,disabled:t,label:o,handleError:n,options:r,selectAllHidden:s,SelectAllItemTemplate:l,ListItemTemplate:a,SelectedItemTemplate:u,className:h,readOnly:p,closeOnSelect:f,...m})=>{const{control:b}=G.useFormContext(),{field:{value:x,onChange:y},fieldState:{error:k}}=G.useController({name:e,control:b,rules:m,disabled:t}),v=d.useId(),$=d.useCallback(C=>{y(C)},[y]);return i.jsx(z.ClassNames,{children:({cx:C})=>i.jsxs(qe,{children:[i.jsxs(Ae,{className:C({hasLabel:!!o}),children:[o&&i.jsx(me,{formItemId:v,isValid:!k,required:!!m.required,children:o}),i.jsx(Zs,{disabled:t||p,options:r,closeOnSelect:f,onChange:$,selected:x,className:h,SelectAllItemTemplate:l,ListItemTemplate:a,SelectedItemTemplate:u})]}),!!n&&i.jsx(Ye,{handleError:n,name:e,hasLabel:!!o})]})})},Kp=({name:e,disabled:t})=>{const{control:o}=G.useFormContext();return G.useController({name:e,control:o,disabled:t}),null},Yp=({name:e,label:t,disabled:o})=>{const{control:n}=G.useFormContext(),{field:{value:r}}=G.useController({name:e,control:n,disabled:o}),s=d.useId(),l=r==null||r===""?"—":String(r);return i.jsx(z.ClassNames,{children:({cx:a})=>i.jsx(qe,{children:i.jsxs(Ae,{className:a({hasLabel:!!t}),children:[t&&i.jsx(me,{formItemId:s,isValid:!0,required:!1,children:t}),i.jsx(qp,{id:s,children:l})]})})})},qp=g.span`
2285
+ font-size: 13px;
2286
+ color: var(--kos-color-text-primary, #1f2937);
2287
+ padding: 6px 0;
2288
+ line-height: 1.4;
2289
+ user-select: text;
2290
+ `,Xt=(e,t)=>{const[o,n]=d.useState(!1);return d.useEffect(()=>{async function r(){var s;e!=null&&e.init&&(await((s=e.init)==null?void 0:s.call(e)),t==null||t()),n(!0)}return r(),()=>{var s;(s=e==null?void 0:e.dispose)==null||s.call(e)}},[t,e]),o},mt=d.createContext({isSelected:()=>!1,selected:[],toggleSelection:Se,isDisabled:!1}),Le=()=>{const e=d.useContext(mt);return e||{isSelected:()=>!1,selected:[],toggleSelection:Se,isDisabled:!1}},On=Symbol.for("kos.list.source"),Gt="__kos_source__";function fo(e,t){return{...e,[On]:t}}function Kt(e){return e[On]??e[Gt]}function Zp(e,t){if(t in e)return e[t];const o=Kt(e);if(o&&typeof o=="object"&&t in o)return o[t]}function Xp(e){return typeof e=="object"&&e!==null&&"locked"in e&&typeof e.locked=="boolean"}const Rn=({groupName:e})=>i.jsx(Jp,{children:i.jsx(Qp,{variant:"small",bold:!0,children:e})});Rn.displayName="AsyncListGroupHeader";const Jp=g.div`
2285
2291
  display: flex;
2286
2292
  align-items: center;
2287
2293
  padding: 6px 12px 2px 12px;
@@ -2292,25 +2298,25 @@
2292
2298
  border-top: none;
2293
2299
  margin-top: 0;
2294
2300
  }
2295
- `,Zh=g(E)`
2301
+ `,Qp=g(E)`
2296
2302
  text-transform: uppercase;
2297
2303
  font-size: 10px;
2298
2304
  letter-spacing: 0.5px;
2299
2305
  opacity: 0.6;
2300
- `;function si(e){return(e==null?void 0:e.build)!==void 0}const Xh=W.kosComponent(({item:e,provider:t,ItemTemplate:o,itemIconMap:n,itemActions:r,itemDecorators:s,itemContentRenderer:l,disableSelectionStyling:a=!1})=>{var k;const u=d.useContext(mt),p=d.useMemo(()=>{if(!n)return;if(typeof n=="function")return n(e);const v=e.type;return v?n[v]:void 0},[n,e]),h=d.useMemo(()=>{if(!(r!=null&&r.length))return;const v=t.originalItems.get(e.id);if(v)return r.filter($=>!$.visibleFor||$.visibleFor(e)).map($=>({id:$.id,iconId:$.iconId,color:$.color,tooltip:$.tooltip,label:$.label,isPrimary:$.isPrimary,onClick:()=>$.onClick(e.id,v)}))},[r,e,t]),f=(()=>{if(s!=null&&s.length)return s.filter(v=>!v.visibleFor||v.visibleFor(e)).map(v=>({id:v.id,iconId:v.iconId,color:v.color,tooltip:v.tooltip}))})(),m=((k=u==null?void 0:u.selected)==null?void 0:k.includes(e.id))??!1,b=l?l(e,m):void 0,x=si(o)?o.build(e):o,y=Kt(e);return i.jsx(St.Observer,{children:()=>i.jsx(x,{...e,...y!==void 0?{[Gt]:y}:{},iconId:p==null?void 0:p.iconId,iconColor:p==null?void 0:p.color,actions:h,decorators:f,"data-disable-selection-styling":a,children:b},e.id)})}),ii=W.kosComponent(({dataProvider:e,ItemTemplate:t,itemIconMap:o,itemActions:n,itemDecorators:r,itemContentRenderer:s,emptyState:l,loadingState:a,className:u,onInit:p,disableSelectionStyling:h=!1,groupExpression:f})=>{const[m,b]=d.useState(!1);return d.useEffect(()=>e?((async()=>{await e.init(),b(!0),p==null||p()})(),()=>{e.dispose()}):void 0,[e,p]),!m||!e?(typeof l=="function"?null:l)||null:i.jsx(St.Observer,{children:()=>{const x=e.isLoading??!1,y=e.items.length>0,k=typeof a=="function"?a(e):a,v=typeof l=="function"?l(e):l;return i.jsxs("div",{className:u,children:[x&&!y&&k,!x&&!y&&v,(()=>{const $=e.items,C=j=>i.jsx(Xh,{item:j,provider:e,ItemTemplate:t,itemIconMap:o,itemActions:n,itemDecorators:r,itemContentRenderer:s,disableSelectionStyling:h},j.id);if(!f)return $.map(C);const S=[],w=new Map;for(const j of $){const D=f(j);if(D===void 0)S.push(j);else{const L=w.get(D);L?L.push(j):w.set(D,[j])}}const I=Array.from(w.keys()).sort((j,D)=>j.localeCompare(D));return i.jsxs(i.Fragment,{children:[S.map(C),I.map(j=>i.jsxs(d.Fragment,{children:[i.jsx(Rn,{groupName:j}),(w.get(j)??[]).map(C)]},`group-${j}`))]})})()]})}})}),Nn=d.createContext({viewing:void 0,onItemView:$e}),ai=()=>{const e=d.useContext(Nn);return e||{viewing:void 0,onItemView:$e}},Jh=W.kosComponent(({selected:e,onSelect:t,disabled:o,viewAction:n,...r})=>{const s=d.useMemo(()=>({selected:e,isSelected:u=>e.includes(u),toggleSelection:t,isDisabled:!!o}),[e,t,o]),l=d.useMemo(()=>{if(n)return{viewing:n.viewing,onItemView:n.onItemView}},[n]);let a=i.jsx(mt.Provider,{value:s,children:i.jsx(ii,{...r})});return l&&(a=i.jsx(Nn.Provider,{value:l,children:a})),a}),[Wo,Qh]=M(["option","select"]),Fn=({trigger:e,onSelection:t,children:o})=>i.jsx(tf,{Reference:e,onSelect:t,menuPlacement:"bottom-start",children:o}),ef=g(dt)`
2306
+ `;function si(e){return(e==null?void 0:e.build)!==void 0}const ef=W.kosComponent(({item:e,provider:t,ItemTemplate:o,itemIconMap:n,itemActions:r,itemDecorators:s,itemContentRenderer:l,disableSelectionStyling:a=!1})=>{var k;const u=d.useContext(mt),h=d.useMemo(()=>{if(!n)return;if(typeof n=="function")return n(e);const v=e.type;return v?n[v]:void 0},[n,e]),p=d.useMemo(()=>{if(!(r!=null&&r.length))return;const v=t.originalItems.get(e.id);if(v)return r.filter($=>!$.visibleFor||$.visibleFor(e)).map($=>({id:$.id,iconId:$.iconId,color:$.color,tooltip:$.tooltip,label:$.label,isPrimary:$.isPrimary,onClick:()=>$.onClick(e.id,v)}))},[r,e,t]),f=(()=>{if(s!=null&&s.length)return s.filter(v=>!v.visibleFor||v.visibleFor(e)).map(v=>({id:v.id,iconId:v.iconId,color:v.color,tooltip:v.tooltip}))})(),m=((k=u==null?void 0:u.selected)==null?void 0:k.includes(e.id))??!1,b=l?l(e,m):void 0,x=si(o)?o.build(e):o,y=Kt(e);return i.jsx(St.Observer,{children:()=>i.jsx(x,{...e,...y!==void 0?{[Gt]:y}:{},iconId:h==null?void 0:h.iconId,iconColor:h==null?void 0:h.color,actions:p,decorators:f,"data-disable-selection-styling":a,children:b},e.id)})}),ii=W.kosComponent(({dataProvider:e,ItemTemplate:t,itemIconMap:o,itemActions:n,itemDecorators:r,itemContentRenderer:s,emptyState:l,loadingState:a,className:u,onInit:h,disableSelectionStyling:p=!1,groupExpression:f})=>{const[m,b]=d.useState(!1);return d.useEffect(()=>e?((async()=>{await e.init(),b(!0),h==null||h()})(),()=>{e.dispose()}):void 0,[e,h]),!m||!e?(typeof l=="function"?null:l)||null:i.jsx(St.Observer,{children:()=>{const x=e.isLoading??!1,y=e.items.length>0,k=typeof a=="function"?a(e):a,v=typeof l=="function"?l(e):l;return i.jsxs("div",{className:u,children:[x&&!y&&k,!x&&!y&&v,(()=>{const $=e.items,C=j=>i.jsx(ef,{item:j,provider:e,ItemTemplate:t,itemIconMap:o,itemActions:n,itemDecorators:r,itemContentRenderer:s,disableSelectionStyling:p},j.id);if(!f)return $.map(C);const S=[],w=new Map;for(const j of $){const D=f(j);if(D===void 0)S.push(j);else{const L=w.get(D);L?L.push(j):w.set(D,[j])}}const I=Array.from(w.keys()).sort((j,D)=>j.localeCompare(D));return i.jsxs(i.Fragment,{children:[S.map(C),I.map(j=>i.jsxs(d.Fragment,{children:[i.jsx(Rn,{groupName:j}),(w.get(j)??[]).map(C)]},`group-${j}`))]})})()]})}})}),Nn=d.createContext({viewing:void 0,onItemView:Se}),ai=()=>{const e=d.useContext(Nn);return e||{viewing:void 0,onItemView:Se}},tf=W.kosComponent(({selected:e,onSelect:t,disabled:o,viewAction:n,...r})=>{const s=d.useMemo(()=>({selected:e,isSelected:u=>e.includes(u),toggleSelection:t,isDisabled:!!o}),[e,t,o]),l=d.useMemo(()=>{if(n)return{viewing:n.viewing,onItemView:n.onItemView}},[n]);let a=i.jsx(mt.Provider,{value:s,children:i.jsx(ii,{...r})});return l&&(a=i.jsx(Nn.Provider,{value:l,children:a})),a}),[Wo,of]=M(["option","select"]),Fn=({trigger:e,onSelection:t,children:o})=>i.jsx(rf,{Reference:e,onSelect:t,menuPlacement:"bottom-start",children:o}),nf=g(dt)`
2301
2307
  ${`${Wo("bg-color",!0)}: ${c("color-black")}`};
2302
2308
  ${`${Wo("color",!0)}: ${c("color-white")}`};
2303
2309
  ${`${Wo("bg-color-active",!0)}: ${c("color-grey70")}`};
2304
2310
  gap: 0px;
2305
2311
  cursor: pointer;
2306
- `,tf=g(Et)`
2307
- ${`${Qh("border-color",!0)}: ${c("color-black")}`};
2312
+ `,rf=g(Et)`
2313
+ ${`${of("border-color",!0)}: ${c("color-black")}`};
2308
2314
  z-index: 15;
2309
2315
  `,An=g.div`
2310
2316
  cursor: default;
2311
2317
  border-bottom: 0.5px solid ${c("color-grey60")};
2312
2318
  pointer-events: none;
2313
- `,[Po,of]=M(["option","select"]),vr=3,Jt=d.memo(({actions:e,isSelected:t=!1,disableSelectionStyling:o=!1})=>{const{inlinePrimary:n,overflowPrimary:r,secondary:s}=d.useMemo(()=>{const f=e.filter(b=>b.isPrimary),m=e.filter(b=>!b.isPrimary);return{inlinePrimary:f.slice(0,vr),overflowPrimary:f.slice(vr),secondary:m}},[e]),l=r.length>0||s.length>0,a=t&&!o?"white":void 0,u=d.useMemo(()=>{const f=new Map;for(const m of e)f.set(m.id,m);return f},[e]),p=d.useCallback((f,m)=>{f.stopPropagation(),m.disabled||m.onClick()},[]),h=d.useCallback(f=>{const m=u.get(f);m&&!m.disabled&&m.onClick()},[u]);return e.length===0?null:i.jsxs(nf,{onClick:f=>f.stopPropagation(),children:[n.map(f=>i.jsx(wr,{onClick:m=>p(m,f),title:f.tooltip,type:"button",disabled:f.disabled,children:i.jsx(R,{size:"sm",iconId:f.iconId,color:a??f.color})},f.id)),l&&i.jsx(rf,{children:i.jsxs(Fn,{trigger:i.jsx(wr,{title:"More actions",type:"button",children:i.jsx(R,{size:"sm",iconId:"Ellipsis",color:a??"blue"})}),onSelection:h,children:[r.map(f=>i.jsx(kr,{optionKey:f.id,label:i.jsxs(Cr,{children:[i.jsx(R,{iconId:f.iconId,color:f.disabled?"grey":f.color||"blue",size:"sm"}),i.jsx($r,{children:f.label||f.tooltip||f.id})]}),disabled:f.disabled,disableSelectionStyle:!0},f.id)),r.length>0&&s.length>0&&i.jsx(An,{}),s.map(f=>i.jsx(kr,{optionKey:f.id,label:i.jsxs(Cr,{children:[f.iconId?i.jsx(R,{iconId:f.iconId,color:f.disabled?"grey":f.color||"blue",size:"sm"}):i.jsx(sf,{}),i.jsx($r,{children:f.label||f.tooltip||f.id})]}),disabled:f.disabled,disableSelectionStyle:!0},f.id))]})})]})});Jt.displayName="ItemActionBar";const nf=g.div`
2319
+ `,[Po,sf]=M(["option","select"]),vr=3,Jt=d.memo(({actions:e,isSelected:t=!1,disableSelectionStyling:o=!1})=>{const{inlinePrimary:n,overflowPrimary:r,secondary:s}=d.useMemo(()=>{const f=e.filter(b=>b.isPrimary),m=e.filter(b=>!b.isPrimary);return{inlinePrimary:f.slice(0,vr),overflowPrimary:f.slice(vr),secondary:m}},[e]),l=r.length>0||s.length>0,a=t&&!o?"white":void 0,u=d.useMemo(()=>{const f=new Map;for(const m of e)f.set(m.id,m);return f},[e]),h=d.useCallback((f,m)=>{f.stopPropagation(),m.disabled||m.onClick()},[]),p=d.useCallback(f=>{const m=u.get(f);m&&!m.disabled&&m.onClick()},[u]);return e.length===0?null:i.jsxs(af,{onClick:f=>f.stopPropagation(),children:[n.map(f=>i.jsx(wr,{onClick:m=>h(m,f),title:f.tooltip,type:"button",disabled:f.disabled,children:i.jsx(R,{size:"sm",iconId:f.iconId,color:a??f.color})},f.id)),l&&i.jsx(lf,{children:i.jsxs(Fn,{trigger:i.jsx(wr,{title:"More actions",type:"button",children:i.jsx(R,{size:"sm",iconId:"Ellipsis",color:a??"blue"})}),onSelection:p,children:[r.map(f=>i.jsx(kr,{optionKey:f.id,label:i.jsxs(Cr,{children:[i.jsx(R,{iconId:f.iconId,color:f.disabled?"grey":f.color||"blue",size:"sm"}),i.jsx($r,{children:f.label||f.tooltip||f.id})]}),disabled:f.disabled,disableSelectionStyle:!0},f.id)),r.length>0&&s.length>0&&i.jsx(An,{}),s.map(f=>i.jsx(kr,{optionKey:f.id,label:i.jsxs(Cr,{children:[f.iconId?i.jsx(R,{iconId:f.iconId,color:f.disabled?"grey":f.color||"blue",size:"sm"}):i.jsx(cf,{}),i.jsx($r,{children:f.label||f.tooltip||f.id})]}),disabled:f.disabled,disableSelectionStyle:!0},f.id))]})})]})});Jt.displayName="ItemActionBar";const af=g.div`
2314
2320
  display: flex;
2315
2321
  align-items: center;
2316
2322
  gap: 4px;
@@ -2322,8 +2328,8 @@
2322
2328
  ${`${Po("bg-color-active",!0)}: ${c("color-grey20")}`};
2323
2329
  gap: 0px;
2324
2330
  cursor: pointer;
2325
- `,rf=g.div`
2326
- ${`${of("border-color",!0)}: ${c("color-grey40")}`};
2331
+ `,lf=g.div`
2332
+ ${`${sf("border-color",!0)}: ${c("color-grey40")}`};
2327
2333
  `,wr=g.button`
2328
2334
  background: none;
2329
2335
  border: none;
@@ -2356,50 +2362,50 @@
2356
2362
  `,$r=g.span`
2357
2363
  font-size: 13px;
2358
2364
  white-space: nowrap;
2359
- `,sf=g.div`
2365
+ `,cf=g.div`
2360
2366
  width: 16px;
2361
2367
  height: 16px;
2362
- `;function rn(e){return e.context!==void 0}const Ln=d.createContext(null),Bn=({children:e,dataProvider:t,onListItemAction:o})=>{const[n,r]=d.useState(),s=d.useMemo(()=>t?{action:o,data:n}:{data:new Map,action:o},[t,n,o]);return d.useEffect(()=>{var a;const l=u=>{r(u)};if(t&&rn(t)){const u=t.context;(a=t.addContextChangeListener)==null||a.call(t,l),u&&r(u)}return()=>{var u;t&&rn(t)&&((u=t==null?void 0:t.removeContextChangeListener)==null||u.call(t,l))}},[t]),i.jsx(Ln.Provider,{value:s,children:e})},af=()=>{const e=d.useContext(Ln);return e||W.KosLog.info("useListDataContext must be used within a DataProviderContextProvider"),e},[Xe]=M(["studio-list-item"]),lf=20,li=W.kosComponent(({id:e,name:t,subText:o,children:n,iconId:r,iconColor:s,actions:l,decorators:a,className:u,disabled:p=!1,"data-depth":h=0,"data-indent-size":f=lf,"data-disable-selection-styling":m=!1})=>{const{selected:b,toggleSelection:x,isDisabled:y}=Ae(),k=d.useCallback(()=>{!p&&!y&&x(e)},[e,x,p,y]),v=b.includes(e),$=p||y,C=typeof f=="string"?Number(f):f,S=h>0?{marginLeft:`${h*C}px`}:void 0;return i.jsxs(cf,{className:u,onClick:k,$isSelected:v,$isDisabled:$,$disableSelectionStyling:m,"data-depth":h,style:S,children:[r&&i.jsx(R,{size:"sm",iconId:r,color:s}),i.jsx(df,{children:n||i.jsxs(i.Fragment,{children:[i.jsx(E,{variant:"body",bold:v,children:t}),o&&i.jsx(uf,{variant:"small",color:"dark",children:o})]})}),a&&a.length>0&&i.jsx(pf,{children:a.map(w=>i.jsx(hf,{size:"sm",iconId:w.iconId,color:v&&!m?"white":w.color,title:w.tooltip},w.id))}),l&&l.length>0&&i.jsx(Jt,{actions:l,isSelected:v,disableSelectionStyling:m})]})});li.displayName="StudioNamedListItem";const cf=g.div`
2368
+ `;function rn(e){return e.context!==void 0}const Ln=d.createContext(null),Bn=({children:e,dataProvider:t,onListItemAction:o})=>{const[n,r]=d.useState(),s=d.useMemo(()=>t?{action:o,data:n}:{data:new Map,action:o},[t,n,o]);return d.useEffect(()=>{var a;const l=u=>{r(u)};if(t&&rn(t)){const u=t.context;(a=t.addContextChangeListener)==null||a.call(t,l),u&&r(u)}return()=>{var u;t&&rn(t)&&((u=t==null?void 0:t.removeContextChangeListener)==null||u.call(t,l))}},[t]),i.jsx(Ln.Provider,{value:s,children:e})},df=()=>{const e=d.useContext(Ln);return e||W.KosLog.info("useListDataContext must be used within a DataProviderContextProvider"),e},[Je]=M(["studio-list-item"]),uf=20,li=W.kosComponent(({id:e,name:t,subText:o,children:n,iconId:r,iconColor:s,actions:l,decorators:a,className:u,disabled:h=!1,"data-depth":p=0,"data-indent-size":f=uf,"data-disable-selection-styling":m=!1})=>{const{selected:b,toggleSelection:x,isDisabled:y}=Le(),k=d.useCallback(()=>{!h&&!y&&x(e)},[e,x,h,y]),v=b.includes(e),$=h||y,C=typeof f=="string"?Number(f):f,S=p>0?{marginLeft:`${p*C}px`}:void 0;return i.jsxs(hf,{className:u,onClick:k,$isSelected:v,$isDisabled:$,$disableSelectionStyling:m,"data-depth":p,style:S,children:[r&&i.jsx(R,{size:"sm",iconId:r,color:s}),i.jsx(pf,{children:n||i.jsxs(i.Fragment,{children:[i.jsx(E,{variant:"body",bold:v,children:t}),o&&i.jsx(ff,{variant:"small",color:"dark",children:o})]})}),a&&a.length>0&&i.jsx(gf,{children:a.map(w=>i.jsx(mf,{size:"sm",iconId:w.iconId,color:v&&!m?"white":w.color,title:w.tooltip},w.id))}),l&&l.length>0&&i.jsx(Jt,{actions:l,isSelected:v,disableSelectionStyling:m})]})});li.displayName="StudioNamedListItem";const hf=g.div`
2363
2369
  display: flex;
2364
2370
  align-items: center;
2365
- gap: ${Xe("column-gap")};
2366
- padding-left: ${Xe("padding-left")};
2367
- padding-top: ${Xe("padding-y")};
2368
- padding-bottom: ${Xe("padding-y")};
2369
- padding-right: ${Xe("padding-right")};
2371
+ gap: ${Je("column-gap")};
2372
+ padding-left: ${Je("padding-left")};
2373
+ padding-top: ${Je("padding-y")};
2374
+ padding-bottom: ${Je("padding-y")};
2375
+ padding-right: ${Je("padding-right")};
2370
2376
  min-height: 22px;
2371
2377
 
2372
2378
  cursor: ${({$isDisabled:e})=>e?"not-allowed":"pointer"};
2373
- color: ${({$isSelected:e,$disableSelectionStyling:t})=>e&&!t?Xe("color-selected"):"inherit"};
2374
- background-color: ${({$isSelected:e,$disableSelectionStyling:t})=>e&&!t?Xe("background-color-selected"):"transparent"};
2379
+ color: ${({$isSelected:e,$disableSelectionStyling:t})=>e&&!t?Je("color-selected"):"inherit"};
2380
+ background-color: ${({$isSelected:e,$disableSelectionStyling:t})=>e&&!t?Je("background-color-selected"):"transparent"};
2375
2381
  opacity: ${({$isDisabled:e})=>e?.5:1};
2376
2382
  transition: background-color 0.15s ease;
2377
2383
 
2378
2384
  &:hover {
2379
- background-color: ${({$isSelected:e,$isDisabled:t,$disableSelectionStyling:o})=>t?"transparent":o?"rgba(0, 0, 0, 0.05)":e?Xe("background-color-selected"):"rgba(0, 0, 0, 0.05)"};
2385
+ background-color: ${({$isSelected:e,$isDisabled:t,$disableSelectionStyling:o})=>t?"transparent":o?"rgba(0, 0, 0, 0.05)":e?Je("background-color-selected"):"rgba(0, 0, 0, 0.05)"};
2380
2386
  }
2381
2387
 
2382
2388
  &:active {
2383
- background-color: ${({$isDisabled:e,$disableSelectionStyling:t})=>e?"transparent":t?"rgba(0, 0, 0, 0.1)":Xe("background-color-selected")};
2389
+ background-color: ${({$isDisabled:e,$disableSelectionStyling:t})=>e?"transparent":t?"rgba(0, 0, 0, 0.1)":Je("background-color-selected")};
2384
2390
  }
2385
- `,df=g.div`
2391
+ `,pf=g.div`
2386
2392
  display: flex;
2387
2393
  flex-direction: column;
2388
2394
  gap: 2px;
2389
2395
  flex: 1;
2390
2396
  min-width: 0; /* Allow text truncation */
2391
- `,uf=g(E)`
2397
+ `,ff=g(E)`
2392
2398
  overflow: hidden;
2393
2399
  text-overflow: ellipsis;
2394
2400
  white-space: nowrap;
2395
- `,pf=g.div`
2401
+ `,gf=g.div`
2396
2402
  display: flex;
2397
2403
  align-items: center;
2398
2404
  gap: 4px;
2399
2405
  padding-left: 8px;
2400
- `,hf=g(R)`
2406
+ `,mf=g(R)`
2401
2407
  opacity: 0.8;
2402
- `,[Nt]=M(["studio-list-item"]),ff=20,ci=W.kosComponent(({id:e,name:t,subText:o,children:n,iconId:r,iconColor:s,actions:l,decorators:a,className:u,disabled:p=!1,"data-depth":h=0,"data-indent-size":f=ff})=>{const{selected:m,toggleSelection:b,isDisabled:x}=Ae(),{viewing:y,onItemView:k}=ai(),v=d.useRef(null),$=m.includes(e),C=y===e,S=p||x,w=d.useCallback(()=>{S||b(e)},[e,b,S]),I=d.useCallback(L=>{v.current&&v.current.contains(L.target)||S||k(e)},[e,k,S]),j=typeof f=="string"?Number(f):f,D=h>0?{marginLeft:`${h*j}px`}:void 0;return i.jsxs(gf,{className:u,onClick:I,$isSelected:$,$isViewing:C,$isDisabled:S,"data-depth":h,style:D,children:[i.jsx(kn,{ref:v,checked:$,disabled:S,onChange:w}),r&&i.jsx(R,{size:"sm",iconId:r,color:s}),i.jsx(mf,{children:n||i.jsxs(i.Fragment,{children:[i.jsx(E,{variant:"body",bold:$,children:t}),o&&i.jsx(bf,{variant:"small",color:"dark",children:o})]})}),a&&a.length>0&&i.jsx(xf,{children:a.map(L=>i.jsx(yf,{size:"sm",iconId:L.iconId,color:L.color,title:L.tooltip},L.id))}),l&&l.length>0&&i.jsx(Jt,{actions:l,isSelected:$}),i.jsx(vf,{children:i.jsx(R,{iconId:"Right",color:"blue",size:"sm"})})]})});ci.displayName="StudioSelectViewListItem";const gf=g.div`
2408
+ `,[Nt]=M(["studio-list-item"]),bf=20,ci=W.kosComponent(({id:e,name:t,subText:o,children:n,iconId:r,iconColor:s,actions:l,decorators:a,className:u,disabled:h=!1,"data-depth":p=0,"data-indent-size":f=bf})=>{const{selected:m,toggleSelection:b,isDisabled:x}=Le(),{viewing:y,onItemView:k}=ai(),v=d.useRef(null),$=m.includes(e),C=y===e,S=h||x,w=d.useCallback(()=>{S||b(e)},[e,b,S]),I=d.useCallback(L=>{v.current&&v.current.contains(L.target)||S||k(e)},[e,k,S]),j=typeof f=="string"?Number(f):f,D=p>0?{marginLeft:`${p*j}px`}:void 0;return i.jsxs(xf,{className:u,onClick:I,$isSelected:$,$isViewing:C,$isDisabled:S,"data-depth":p,style:D,children:[i.jsx(kn,{ref:v,checked:$,disabled:S,onChange:w}),r&&i.jsx(R,{size:"sm",iconId:r,color:s}),i.jsx(yf,{children:n||i.jsxs(i.Fragment,{children:[i.jsx(E,{variant:"body",bold:$,children:t}),o&&i.jsx(vf,{variant:"small",color:"dark",children:o})]})}),a&&a.length>0&&i.jsx(kf,{children:a.map(L=>i.jsx(wf,{size:"sm",iconId:L.iconId,color:L.color,title:L.tooltip},L.id))}),l&&l.length>0&&i.jsx(Jt,{actions:l,isSelected:$}),i.jsx(Cf,{children:i.jsx(R,{iconId:"Right",color:"blue",size:"sm"})})]})});ci.displayName="StudioSelectViewListItem";const xf=g.div`
2403
2409
  display: flex;
2404
2410
  align-items: center;
2405
2411
  gap: ${Nt("column-gap")};
@@ -2421,44 +2427,44 @@
2421
2427
  &:active {
2422
2428
  background-color: ${({$isDisabled:e})=>e?"transparent":"rgba(0, 0, 0, 0.1)"};
2423
2429
  }
2424
- `,mf=g.div`
2430
+ `,yf=g.div`
2425
2431
  display: flex;
2426
2432
  flex-direction: column;
2427
2433
  gap: 2px;
2428
2434
  flex: 1;
2429
2435
  min-width: 0; /* Allow text truncation */
2430
- `,bf=g(E)`
2436
+ `,vf=g(E)`
2431
2437
  overflow: hidden;
2432
2438
  text-overflow: ellipsis;
2433
2439
  white-space: nowrap;
2434
- `,xf=g.div`
2440
+ `,kf=g.div`
2435
2441
  display: flex;
2436
2442
  align-items: center;
2437
2443
  gap: 4px;
2438
2444
  padding-left: 8px;
2439
- `,yf=g(R)`
2445
+ `,wf=g(R)`
2440
2446
  opacity: 0.8;
2441
- `,vf=g.div`
2447
+ `,Cf=g.div`
2442
2448
  display: flex;
2443
2449
  align-items: center;
2444
2450
  flex-shrink: 0;
2445
- `,kf=e=>t=>o=>()=>o.call(e,t);class Wn{constructor(t,o,n,r){T(this,"parent");T(this,"_itemMap");T(this,"disposer");T(this,"_items");T(this,"listeners",[]);T(this,"context");T(this,"resolvedItems");T(this,"resolver");T(this,"version");T(this,"initialized");this.parent=t,this.context=_.observable.map(new Map(Object.entries(r||{}))),this.version=0,this._itemMap=n,this.initialized=!1,this._items=_.observable.map(new Map),this.resolvedItems=[],this.resolver=o.bind(t),this.listeners=[],_.makeObservable(this,{items:_.computed,initialized:_.observable,version:_.observable,refresh:_.action,resolvedItems:_.observable,context:_.observable})}filterByInputItem(t,o){return!!t}sortByInputItem(t,o){var n;return t.name?(n=t.name)==null?void 0:n.localeCompare(o.name):-1}filterItem(t,o){return!0}sortItem(t,o){return 0}refresh(){this.version=this.version+1}get items(){if(!this.initialized||this.version<0)return[];const t=this.resolvedItems,o=[...new Set(t)],n=p=>this._itemMap(p,this.context),r=p=>this.filterByInputItem(p,this.context),s=o.filter(r.bind(this)).sort(this.sortByInputItem.bind(this)).map(n),l=p=>this.filterItem(p,this.context),a=s.filter(l.bind(this)).sort(this.sortItem.bind(this));return Array.from(this._items.keys()).filter(p=>!a.find(h=>h.id===p)).forEach(p=>{W.kosAction(()=>{this._items.delete(p)})}),a.reduce((p,h)=>{if(!p.has(h.id))W.kosAction(()=>{p.set(h.id,h)});else{const f=p.get(h.id);f&&W.kosAction(()=>{const m=Object.assign(f,h);p.set(h.id,m)})}return p},this._items),a.map(p=>this._items.get(p.id))}async init(){if(!this.initialized){if(W.isKosDataModel(this.parent)&&await W.whenReady(this.parent),this.resolver){const t=kf(this.parent)(this.context)(this.resolver);this.disposer=_.reaction(t,o=>{this.resolvedItems=o,this.refresh()},{fireImmediately:!0})}W.kosAction(()=>{this.initialized=!0})}}whenReady(){return new Promise(t=>{const o=W.kosAutoEffect(()=>{this.initialized&&(t(),o())})})}updateContextValue(t,o){W.kosAction(()=>{this.context.set(t,o),this.refresh()})}removeContextValue(t){this.context.delete(t),this.refresh()}dispose(){this.disposer&&this.disposer(),W.kosAction(()=>{this.initialized=!1})}}const wf=e=>e.data!==void 0,di=e=>t=>()=>{const o=[];return(Array.isArray(t)?t:[t]).forEach(r=>{const s=e[r];wf(s)?o.push(...s.data):Array.isArray(s)&&o.push(...s)}),o};class Pn extends Wn{constructor(o,n,r,s){super(o,di(o)(n),r,s);T(this,"_key");this._key=Array.isArray(n)?n:[n]}}class Cf extends Pn{constructor(t,o,n,r){super(t,o,n,r),_.makeObservable(this,{groups:_.computed,itemsByGroup:_.computed})}get itemsByGroup(){return this.items.reduce((t,o)=>{const n=o.group.groupId;return t[n]||(t[n]=[]),t[n].push(o),t},{})}get groups(){return this.items.map(t=>t.group).sort(this.sortGroup.bind(this))}getGroupItems(t){return this.itemsByGroup[t]||[]}sortGroup(t,o){return t.name.localeCompare(o.name)}}class $f{constructor(t,o=[]){T(this,"items");T(this,"parent");this.parent=t,this.items=o.map(n=>({id:`${this.parent.id}-${n.name.toString()}`,name:n.key||n.name.toString(),data:n,value:this.parent[n.name]}))}}class ui{constructor(t,o,n,r,s){T(this,"parent");T(this,"_itemMap");T(this,"rootResolver");T(this,"childResolver");T(this,"rootDisposer");T(this,"rootTrackingFn");T(this,"childTrackingFn");T(this,"_nodes");T(this,"_rootIds");T(this,"context");T(this,"version");T(this,"initialized");T(this,"_expandingAll",!1);T(this,"_childDisposers",new Map);this.parent=t,this.context=_.observable.map(new Map(Object.entries(s||{}))),this._nodes=_.observable.map(new Map),this._rootIds=_.observable.array([]),this.version=0,this.initialized=!1,this._itemMap=r,this.rootResolver=o.bind(t),this.childResolver=n.bind(t),_.makeObservable(this,{context:_.observable,version:_.observable,initialized:_.observable,tree:_.computed,rootItems:_.computed,loadingStates:_.computed,loadedChildren:_.computed,originalItems:_.computed,expandBranch:_.action,collapseBranch:_.action,clearCache:_.action,refresh:_.action,expandAll:_.action})}filterByInputItem(t,o){return!0}sortByInputItem(t,o){return 0}filterItem(t,o){return!0}sortItem(t,o){return 0}async getRootItems(){return await this.rootResolver.call(this.parent,this.context)}async getChildren(t,o){return await this.childResolver.call(this.parent,t,o)}itemMap(t,o){return this._itemMap(t,o)}refresh(){this.version=this.version+1}updateContextValue(t,o){W.kosAction(()=>{this.context.set(t,o),this.refresh()})}removeContextValue(t){this.context.delete(t),this.refresh()}get tree(){return this.version,this._rootIds.map(t=>this.buildBranch(t)).filter(t=>t!==null)}get rootItems(){return this._rootIds.map(t=>{var o;return(o=this._nodes.get(t))==null?void 0:o.original}).filter(t=>t!==void 0)}get loadingStates(){const t=new Map;return this._nodes.forEach((o,n)=>{t.set(n,{status:o.fetchState,error:o.error,timestamp:o.timestamp})}),t}get loadedChildren(){const t=new Map;return this._nodes.forEach((o,n)=>{if(o.fetchState==="loaded"&&o.childIds.length>0){const r=o.childIds.map(s=>{var l;return(l=this._nodes.get(s))==null?void 0:l.original}).filter(s=>s!==void 0);t.set(n,r)}}),t}get originalItems(){const t=new Map;return this._nodes.forEach((o,n)=>{t.set(n,o.original)}),t}buildBranch(t){const o=this._nodes.get(t);if(!o||!this.filterByInputItem(o.original,this.context)||!this.filterItem(o.transformed,this.context))return null;const n=o.childIds.map(r=>this.buildBranch(r)).filter(r=>r!==null);return n.sort((r,s)=>this.sortItem(r,s)),{...o.transformed,branches:n,loadingState:{status:o.fetchState,error:o.error,timestamp:o.timestamp},hasChildren:o.hasChildren,isLeaf:o.hasChildren===!1}}setNode(t,o,n="idle"){const r=this.getItemId(t),s=this._nodes.get(r);if(s&&s.parentId!==o){const a=s.parentId;if(a){const u=this._nodes.get(a);if(u){const p=u.childIds.indexOf(r);p!==-1&&u.childIds.splice(p,1)}}}const l={original:t,transformed:fo(this._itemMap(t,this.context),t),parentId:o,childIds:(s==null?void 0:s.childIds)??[],hasChildren:this.hasChildren(t),fetchState:(s==null?void 0:s.fetchState)??n,error:s==null?void 0:s.error,timestamp:s==null?void 0:s.timestamp};return this._nodes.set(r,l),r}setChildren(t,o){const n=this._nodes.get(t);if(!n)return;const l=[...o.filter(a=>this.filterByInputItem(a,this.context))].sort(this.sortByInputItem.bind(this)).map(a=>this.setNode(a,t));_.runInAction(()=>{n.childIds=l,n.fetchState="loaded",n.timestamp=Date.now()})}async expandBranch(t,o){const n=this._nodes.get(t);if(!n){console.warn(`expandBranch: Node ${t} not found`);return}if(!(n.fetchState==="loading"||n.fetchState==="loaded")){_.runInAction(()=>{n.fetchState="loading",n.timestamp=Date.now()});try{const r=await this.getChildren(o,this.context);_.runInAction(()=>{this.setChildren(t,r)}),this.setupChildReaction(t,o)}catch(r){_.runInAction(()=>{n.fetchState="error",n.error=r,n.timestamp=Date.now()})}}}setupChildReaction(t,o){const n=this._childDisposers.get(t);n&&n();const r=W.kosAutoEffect(()=>{this.childTrackingFn?this.childTrackingFn(this.parent,o,this.context):this.childResolver.call(this.parent,o,this.context),this.reloadChildren(t,o)});this._childDisposers.set(t,r)}async reloadChildren(t,o){const n=this._nodes.get(t);if(!(!n||n.fetchState!=="loaded"))try{const r=await this.getChildren(o,this.context);_.runInAction(()=>{const s=new Set(n.childIds),u=[...r.filter(h=>this.filterByInputItem(h,this.context))].sort(this.sortByInputItem.bind(this)).map(h=>this.setNode(h,t)),p=new Set(u);for(const h of s)if(!p.has(h)){const f=this._nodes.get(h);f&&(this.disposeChildReaction(h),this.removeChildrenRecursively(f.childIds)),this._nodes.delete(h)}n.childIds=u,n.timestamp=Date.now()})}catch(r){console.error(`Failed to reload children for ${t}:`,r)}}disposeChildReaction(t){const o=this._childDisposers.get(t);o&&(o(),this._childDisposers.delete(t))}async expandAll(){if(!this._expandingAll){this._expandingAll=!0;try{await this.expandNodesRecursively(this._rootIds.slice())}finally{this._expandingAll=!1}}}async expandNodesRecursively(t){const o=t.map(s=>this._nodes.get(s)).filter(s=>s!==void 0&&s.hasChildren!==!1);if(o.length===0)return;const n=o.filter(s=>s.fetchState==="idle");n.length>0&&await Promise.all(n.map(s=>this.expandBranch(this.getItemId(s.original),s.original)));const r=[];for(const s of o)r.push(...s.childIds);r.length>0&&await this.expandNodesRecursively(r)}collapseBranch(t){const o=this._nodes.get(t);o&&(this.disposeChildReaction(t),_.runInAction(()=>{this.disposeDescendantReactions(o.childIds),this.removeChildrenRecursively(o.childIds),o.childIds=[],o.fetchState="idle",o.error=void 0,o.timestamp=Date.now()}))}disposeDescendantReactions(t){for(const o of t){this.disposeChildReaction(o);const n=this._nodes.get(o);n&&this.disposeDescendantReactions(n.childIds)}}removeChildrenRecursively(t){for(const o of t){const n=this._nodes.get(o);n&&(this.removeChildrenRecursively(n.childIds),this._nodes.delete(o))}}clearCache(t){t?this.collapseBranch(t):(this._childDisposers.forEach(o=>o()),this._childDisposers.clear(),_.runInAction(()=>{const o=new Set(this._rootIds),n=[];this._nodes.forEach((r,s)=>{o.has(s)?(r.childIds=[],r.fetchState="idle",r.error=void 0):n.push(s)}),n.forEach(r=>this._nodes.delete(r))}))}async init(){this.initialized&&_.runInAction(()=>{this._nodes.clear(),this._rootIds.clear(),this.initialized=!1}),W.isKosDataModel(this.parent)&&await W.whenReady(this.parent);try{const t=await this.getRootItems();_.runInAction(()=>{const r=[...t.filter(s=>this.filterByInputItem(s,this.context))].sort(this.sortByInputItem.bind(this)).map(s=>this.setNode(s));this._rootIds.replace(r),this.initialized=!0})}catch(t){console.error("Failed to load root items:",t),_.runInAction(()=>{this.initialized=!0})}this.rootDisposer=W.kosAutoEffect(()=>{this.rootTrackingFn?this.rootTrackingFn(this.parent,this.context):this.rootResolver.call(this.parent,this.context),this.reloadRoots()})}async reloadRoots(){if(this.initialized)try{const t=await this.getRootItems();_.runInAction(()=>{const o=new Set(this._rootIds),s=[...t.filter(a=>this.filterByInputItem(a,this.context))].sort(this.sortByInputItem.bind(this)).map(a=>this.setNode(a)),l=new Set(s);for(const a of o)if(!l.has(a)){const u=this._nodes.get(a);u&&this.removeChildrenRecursively(u.childIds),this._nodes.delete(a)}this._rootIds.replace(s)})}catch(t){console.error("Failed to reload root items:",t)}}whenReady(){return new Promise(t=>{const o=W.kosAutoEffect(()=>{this.initialized&&(t(),o())})})}dispose(){this.rootDisposer&&this.rootDisposer(),this._childDisposers.forEach(t=>t()),this._childDisposers.clear(),_.runInAction(()=>{this._nodes.clear(),this._rootIds.clear(),this.initialized=!1})}}function Yt(e){return e.build!==void 0}const Sf=g.div`
2451
+ `,$f=e=>t=>o=>()=>o.call(e,t);class Wn{constructor(t,o,n,r){T(this,"parent");T(this,"_itemMap");T(this,"disposer");T(this,"_items");T(this,"listeners",[]);T(this,"context");T(this,"resolvedItems");T(this,"resolver");T(this,"version");T(this,"initialized");this.parent=t,this.context=_.observable.map(new Map(Object.entries(r||{}))),this.version=0,this._itemMap=n,this.initialized=!1,this._items=_.observable.map(new Map),this.resolvedItems=[],this.resolver=o.bind(t),this.listeners=[],_.makeObservable(this,{items:_.computed,initialized:_.observable,version:_.observable,refresh:_.action,resolvedItems:_.observable,context:_.observable})}filterByInputItem(t,o){return!!t}sortByInputItem(t,o){var n;return t.name?(n=t.name)==null?void 0:n.localeCompare(o.name):-1}filterItem(t,o){return!0}sortItem(t,o){return 0}refresh(){this.version=this.version+1}get items(){if(!this.initialized||this.version<0)return[];const t=this.resolvedItems,o=[...new Set(t)],n=h=>this._itemMap(h,this.context),r=h=>this.filterByInputItem(h,this.context),s=o.filter(r.bind(this)).sort(this.sortByInputItem.bind(this)).map(n),l=h=>this.filterItem(h,this.context),a=s.filter(l.bind(this)).sort(this.sortItem.bind(this));return Array.from(this._items.keys()).filter(h=>!a.find(p=>p.id===h)).forEach(h=>{W.kosAction(()=>{this._items.delete(h)})}),a.reduce((h,p)=>{if(!h.has(p.id))W.kosAction(()=>{h.set(p.id,p)});else{const f=h.get(p.id);f&&W.kosAction(()=>{const m=Object.assign(f,p);h.set(p.id,m)})}return h},this._items),a.map(h=>this._items.get(h.id))}async init(){if(!this.initialized){if(W.isKosDataModel(this.parent)&&await W.whenReady(this.parent),this.resolver){const t=$f(this.parent)(this.context)(this.resolver);this.disposer=_.reaction(t,o=>{this.resolvedItems=o,this.refresh()},{fireImmediately:!0})}W.kosAction(()=>{this.initialized=!0})}}whenReady(){return new Promise(t=>{const o=W.kosAutoEffect(()=>{this.initialized&&(t(),o())})})}updateContextValue(t,o){W.kosAction(()=>{this.context.set(t,o),this.refresh()})}removeContextValue(t){this.context.delete(t),this.refresh()}dispose(){this.disposer&&this.disposer(),W.kosAction(()=>{this.initialized=!1})}}const Sf=e=>e.data!==void 0,di=e=>t=>()=>{const o=[];return(Array.isArray(t)?t:[t]).forEach(r=>{const s=e[r];Sf(s)?o.push(...s.data):Array.isArray(s)&&o.push(...s)}),o};class Pn extends Wn{constructor(o,n,r,s){super(o,di(o)(n),r,s);T(this,"_key");this._key=Array.isArray(n)?n:[n]}}class jf extends Pn{constructor(t,o,n,r){super(t,o,n,r),_.makeObservable(this,{groups:_.computed,itemsByGroup:_.computed})}get itemsByGroup(){return this.items.reduce((t,o)=>{const n=o.group.groupId;return t[n]||(t[n]=[]),t[n].push(o),t},{})}get groups(){return this.items.map(t=>t.group).sort(this.sortGroup.bind(this))}getGroupItems(t){return this.itemsByGroup[t]||[]}sortGroup(t,o){return t.name.localeCompare(o.name)}}class If{constructor(t,o=[]){T(this,"items");T(this,"parent");this.parent=t,this.items=o.map(n=>({id:`${this.parent.id}-${n.name.toString()}`,name:n.key||n.name.toString(),data:n,value:this.parent[n.name]}))}}class ui{constructor(t,o,n,r,s){T(this,"parent");T(this,"_itemMap");T(this,"rootResolver");T(this,"childResolver");T(this,"rootDisposer");T(this,"rootTrackingFn");T(this,"childTrackingFn");T(this,"_nodes");T(this,"_rootIds");T(this,"context");T(this,"version");T(this,"initialized");T(this,"_expandingAll",!1);T(this,"_childDisposers",new Map);this.parent=t,this.context=_.observable.map(new Map(Object.entries(s||{}))),this._nodes=_.observable.map(new Map),this._rootIds=_.observable.array([]),this.version=0,this.initialized=!1,this._itemMap=r,this.rootResolver=o.bind(t),this.childResolver=n.bind(t),_.makeObservable(this,{context:_.observable,version:_.observable,initialized:_.observable,tree:_.computed,rootItems:_.computed,loadingStates:_.computed,loadedChildren:_.computed,originalItems:_.computed,expandBranch:_.action,collapseBranch:_.action,clearCache:_.action,refresh:_.action,expandAll:_.action})}filterByInputItem(t,o){return!0}sortByInputItem(t,o){return 0}filterItem(t,o){return!0}sortItem(t,o){return 0}async getRootItems(){return await this.rootResolver.call(this.parent,this.context)}async getChildren(t,o){return await this.childResolver.call(this.parent,t,o)}itemMap(t,o){return this._itemMap(t,o)}refresh(){this.version=this.version+1}updateContextValue(t,o){W.kosAction(()=>{this.context.set(t,o),this.refresh()})}removeContextValue(t){this.context.delete(t),this.refresh()}get tree(){return this.version,this._rootIds.map(t=>this.buildBranch(t)).filter(t=>t!==null)}get rootItems(){return this._rootIds.map(t=>{var o;return(o=this._nodes.get(t))==null?void 0:o.original}).filter(t=>t!==void 0)}get loadingStates(){const t=new Map;return this._nodes.forEach((o,n)=>{t.set(n,{status:o.fetchState,error:o.error,timestamp:o.timestamp})}),t}get loadedChildren(){const t=new Map;return this._nodes.forEach((o,n)=>{if(o.fetchState==="loaded"&&o.childIds.length>0){const r=o.childIds.map(s=>{var l;return(l=this._nodes.get(s))==null?void 0:l.original}).filter(s=>s!==void 0);t.set(n,r)}}),t}get originalItems(){const t=new Map;return this._nodes.forEach((o,n)=>{t.set(n,o.original)}),t}buildBranch(t){const o=this._nodes.get(t);if(!o||!this.filterByInputItem(o.original,this.context)||!this.filterItem(o.transformed,this.context))return null;const n=o.childIds.map(r=>this.buildBranch(r)).filter(r=>r!==null);return n.sort((r,s)=>this.sortItem(r,s)),{...o.transformed,branches:n,loadingState:{status:o.fetchState,error:o.error,timestamp:o.timestamp},hasChildren:o.hasChildren,isLeaf:o.hasChildren===!1}}setNode(t,o,n="idle"){const r=this.getItemId(t),s=this._nodes.get(r);if(s&&s.parentId!==o){const a=s.parentId;if(a){const u=this._nodes.get(a);if(u){const h=u.childIds.indexOf(r);h!==-1&&u.childIds.splice(h,1)}}}const l={original:t,transformed:fo(this._itemMap(t,this.context),t),parentId:o,childIds:(s==null?void 0:s.childIds)??[],hasChildren:this.hasChildren(t),fetchState:(s==null?void 0:s.fetchState)??n,error:s==null?void 0:s.error,timestamp:s==null?void 0:s.timestamp};return this._nodes.set(r,l),r}setChildren(t,o){const n=this._nodes.get(t);if(!n)return;const l=[...o.filter(a=>this.filterByInputItem(a,this.context))].sort(this.sortByInputItem.bind(this)).map(a=>this.setNode(a,t));_.runInAction(()=>{n.childIds=l,n.fetchState="loaded",n.timestamp=Date.now()})}async expandBranch(t,o){const n=this._nodes.get(t);if(!n){console.warn(`expandBranch: Node ${t} not found`);return}if(!(n.fetchState==="loading"||n.fetchState==="loaded")){_.runInAction(()=>{n.fetchState="loading",n.timestamp=Date.now()});try{const r=await this.getChildren(o,this.context);_.runInAction(()=>{this.setChildren(t,r)}),this.setupChildReaction(t,o)}catch(r){_.runInAction(()=>{n.fetchState="error",n.error=r,n.timestamp=Date.now()})}}}setupChildReaction(t,o){const n=this._childDisposers.get(t);n&&n();const r=W.kosAutoEffect(()=>{this.childTrackingFn?this.childTrackingFn(this.parent,o,this.context):this.childResolver.call(this.parent,o,this.context),this.reloadChildren(t,o)});this._childDisposers.set(t,r)}async reloadChildren(t,o){const n=this._nodes.get(t);if(!(!n||n.fetchState!=="loaded"))try{const r=await this.getChildren(o,this.context);_.runInAction(()=>{const s=new Set(n.childIds),u=[...r.filter(p=>this.filterByInputItem(p,this.context))].sort(this.sortByInputItem.bind(this)).map(p=>this.setNode(p,t)),h=new Set(u);for(const p of s)if(!h.has(p)){const f=this._nodes.get(p);f&&(this.disposeChildReaction(p),this.removeChildrenRecursively(f.childIds)),this._nodes.delete(p)}n.childIds=u,n.timestamp=Date.now()})}catch(r){console.error(`Failed to reload children for ${t}:`,r)}}disposeChildReaction(t){const o=this._childDisposers.get(t);o&&(o(),this._childDisposers.delete(t))}async expandAll(){if(!this._expandingAll){this._expandingAll=!0;try{await this.expandNodesRecursively(this._rootIds.slice())}finally{this._expandingAll=!1}}}async expandNodesRecursively(t){const o=t.map(s=>this._nodes.get(s)).filter(s=>s!==void 0&&s.hasChildren!==!1);if(o.length===0)return;const n=o.filter(s=>s.fetchState==="idle");n.length>0&&await Promise.all(n.map(s=>this.expandBranch(this.getItemId(s.original),s.original)));const r=[];for(const s of o)r.push(...s.childIds);r.length>0&&await this.expandNodesRecursively(r)}collapseBranch(t){const o=this._nodes.get(t);o&&(this.disposeChildReaction(t),_.runInAction(()=>{this.disposeDescendantReactions(o.childIds),this.removeChildrenRecursively(o.childIds),o.childIds=[],o.fetchState="idle",o.error=void 0,o.timestamp=Date.now()}))}disposeDescendantReactions(t){for(const o of t){this.disposeChildReaction(o);const n=this._nodes.get(o);n&&this.disposeDescendantReactions(n.childIds)}}removeChildrenRecursively(t){for(const o of t){const n=this._nodes.get(o);n&&(this.removeChildrenRecursively(n.childIds),this._nodes.delete(o))}}clearCache(t){t?this.collapseBranch(t):(this._childDisposers.forEach(o=>o()),this._childDisposers.clear(),_.runInAction(()=>{const o=new Set(this._rootIds),n=[];this._nodes.forEach((r,s)=>{o.has(s)?(r.childIds=[],r.fetchState="idle",r.error=void 0):n.push(s)}),n.forEach(r=>this._nodes.delete(r))}))}async init(){this.initialized&&_.runInAction(()=>{this._nodes.clear(),this._rootIds.clear(),this.initialized=!1}),W.isKosDataModel(this.parent)&&await W.whenReady(this.parent);try{const t=await this.getRootItems();_.runInAction(()=>{const r=[...t.filter(s=>this.filterByInputItem(s,this.context))].sort(this.sortByInputItem.bind(this)).map(s=>this.setNode(s));this._rootIds.replace(r),this.initialized=!0})}catch(t){console.error("Failed to load root items:",t),_.runInAction(()=>{this.initialized=!0})}this.rootDisposer=W.kosAutoEffect(()=>{this.rootTrackingFn?this.rootTrackingFn(this.parent,this.context):this.rootResolver.call(this.parent,this.context),this.reloadRoots()})}async reloadRoots(){if(this.initialized)try{const t=await this.getRootItems();_.runInAction(()=>{const o=new Set(this._rootIds),s=[...t.filter(a=>this.filterByInputItem(a,this.context))].sort(this.sortByInputItem.bind(this)).map(a=>this.setNode(a)),l=new Set(s);for(const a of o)if(!l.has(a)){const u=this._nodes.get(a);u&&this.removeChildrenRecursively(u.childIds),this._nodes.delete(a)}this._rootIds.replace(s)})}catch(t){console.error("Failed to reload root items:",t)}}whenReady(){return new Promise(t=>{const o=W.kosAutoEffect(()=>{this.initialized&&(t(),o())})})}dispose(){this.rootDisposer&&this.rootDisposer(),this._childDisposers.forEach(t=>t()),this._childDisposers.clear(),_.runInAction(()=>{this._nodes.clear(),this._rootIds.clear(),this.initialized=!1})}}function Yt(e){return e.build!==void 0}const Df=g.div`
2446
2452
  width: 100%;
2447
- `,jf=(e,t,o)=>e.items.map(n=>{const r=Yt(t)?t.build(n):t;return i.jsx(r,{"data-key":n.id,...n,onListItemAction:o},n.id)}),Vn=W.kosComponent(({dataProvider:e,firstChild:t,ItemTemplate:o,lastChild:n,onListItemAction:r,onInit:s,emptyState:l,className:a,itemListRenderer:u=jf})=>{const p=Xt(e,s),h=p&&e?u(e,o,r):[];return i.jsx(Bn,{dataProvider:e||void 0,onListItemAction:r,children:i.jsxs(Sf,{className:a,children:[t,p?h.length===0&&l?l:h:null,n]})})}),Co=W.kosComponent(({isSingleSelect:e=!0,onSelect:t,selected:o,disabled:n,autoSelectFirstItem:r,dataProvider:s,getFirstItem:l,className:a,...u})=>{const[p,h]=d.useState(o??[]),f=d.useRef(p??[]);d.useLayoutEffect(()=>{f.current=p},[p]),d.useEffect(()=>{h(o??[])},[o]);const m=d.useCallback(y=>{t(y,f.current.includes(y)?"unselected":"selected"),h(k=>e?[y]:k.includes(y)?k.filter(v=>v!==y):[...k,y])},[e,t]),b=d.useCallback(y=>f.current.includes(y),[]),x=d.useMemo(()=>({isSelected:b,selected:p,toggleSelection:m,isDisabled:!!n}),[b,p,m,n]);return d.useEffect(()=>{var y,k;if(r&&(s!=null&&s.items)&&f.current.length===0){let v;l?v=(y=l(s.items))==null?void 0:y.id:v=(k=s.items[0])==null?void 0:k.id,v&&m(v)}},[r,s==null?void 0:s.items,l,m]),i.jsx(mt.Provider,{value:x,children:i.jsx(Vn,{dataProvider:s,className:a,...u})})});function pi(e){return e.build!==void 0}const If=e=>(t,o,n)=>t.groups.reduce((s,l)=>s.find(a=>a.groupId===l.groupId)?s:[...s,l],[]).map(s=>{const l=pi(e)?e.build(s):e,u=t.getGroupItems(s.groupId).map(p=>{const h=Yt(o)?o.build(p):o;return i.jsx(h,{"data-key":p.id,...p,onListItemAction:n},p.id)});return i.jsx(l,{groupId:s.groupId,name:s.name,children:u},s.groupId)}),Hn=d.createContext({openedGroups:[],toggleGroup:$e});function Df(e){const t=e.supportMultipleOpen??!0,[o,n]=d.useState(e.openedGroups??[]),r=d.useCallback(l=>{var a;(a=e.onGroupOpen)==null||a.call(e,l,o.includes(l)?"closed":"opened"),n(u=>t?u.includes(l)?u.filter(p=>p!==l):[...u,l]:[l])},[o,e,t]);d.useEffect(()=>{n(e.openedGroups??[])},[e.openedGroups]);const s=d.useMemo(()=>({openedGroups:o,toggleGroup:r}),[o,r]);return i.jsx(Hn.Provider,{value:s,children:i.jsx(Co,{...e,itemListRenderer:If(e.GroupTemplate)})})}const hi=()=>{const e=d.useContext(Hn);return e||{openedGroups:[],toggleGroup:$e}},_f=({children:e,name:t,groupId:o,className:n})=>{const{openedGroups:r,toggleGroup:s}=hi(),l=r.includes(o),a=d.useCallback(()=>{s(o)},[o,s]);return i.jsxs(fi,{className:n,children:[i.jsxs(Ef,{"data-open":l,onClick:a,children:[l?i.jsx(R,{iconId:"CaretDown",size:"xsm"}):i.jsx(R,{iconId:"CaretRight",size:"xsm"}),i.jsx(E,{variant:"body",bold:!0,children:t})]}),i.jsx(zf,{children:l?i.jsx(Mf,{className:"list-container",children:e}):null})]},o)},Tf=({children:e,groupId:t,className:o})=>i.jsx(fi,{className:o,children:e},t),fi=g.div`
2453
+ `,_f=(e,t,o)=>e.items.map(n=>{const r=Yt(t)?t.build(n):t;return i.jsx(r,{"data-key":n.id,...n,onListItemAction:o},n.id)}),Vn=W.kosComponent(({dataProvider:e,firstChild:t,ItemTemplate:o,lastChild:n,onListItemAction:r,onInit:s,emptyState:l,className:a,itemListRenderer:u=_f})=>{const h=Xt(e,s),p=h&&e?u(e,o,r):[];return i.jsx(Bn,{dataProvider:e||void 0,onListItemAction:r,children:i.jsxs(Df,{className:a,children:[t,h?p.length===0&&l?l:p:null,n]})})}),Co=W.kosComponent(({isSingleSelect:e=!0,onSelect:t,selected:o,disabled:n,autoSelectFirstItem:r,dataProvider:s,getFirstItem:l,className:a,...u})=>{const[h,p]=d.useState(o??[]),f=d.useRef(h??[]);d.useLayoutEffect(()=>{f.current=h},[h]),d.useEffect(()=>{p(o??[])},[o]);const m=d.useCallback(y=>{t(y,f.current.includes(y)?"unselected":"selected"),p(k=>e?[y]:k.includes(y)?k.filter(v=>v!==y):[...k,y])},[e,t]),b=d.useCallback(y=>f.current.includes(y),[]),x=d.useMemo(()=>({isSelected:b,selected:h,toggleSelection:m,isDisabled:!!n}),[b,h,m,n]);return d.useEffect(()=>{var y,k;if(r&&(s!=null&&s.items)&&f.current.length===0){let v;l?v=(y=l(s.items))==null?void 0:y.id:v=(k=s.items[0])==null?void 0:k.id,v&&m(v)}},[r,s==null?void 0:s.items,l,m]),i.jsx(mt.Provider,{value:x,children:i.jsx(Vn,{dataProvider:s,className:a,...u})})});function hi(e){return e.build!==void 0}const Tf=e=>(t,o,n)=>t.groups.reduce((s,l)=>s.find(a=>a.groupId===l.groupId)?s:[...s,l],[]).map(s=>{const l=hi(e)?e.build(s):e,u=t.getGroupItems(s.groupId).map(h=>{const p=Yt(o)?o.build(h):o;return i.jsx(p,{"data-key":h.id,...h,onListItemAction:n},h.id)});return i.jsx(l,{groupId:s.groupId,name:s.name,children:u},s.groupId)}),Hn=d.createContext({openedGroups:[],toggleGroup:Se});function Ef(e){const t=e.supportMultipleOpen??!0,[o,n]=d.useState(e.openedGroups??[]),r=d.useCallback(l=>{var a;(a=e.onGroupOpen)==null||a.call(e,l,o.includes(l)?"closed":"opened"),n(u=>t?u.includes(l)?u.filter(h=>h!==l):[...u,l]:[l])},[o,e,t]);d.useEffect(()=>{n(e.openedGroups??[])},[e.openedGroups]);const s=d.useMemo(()=>({openedGroups:o,toggleGroup:r}),[o,r]);return i.jsx(Hn.Provider,{value:s,children:i.jsx(Co,{...e,itemListRenderer:Tf(e.GroupTemplate)})})}const pi=()=>{const e=d.useContext(Hn);return e||{openedGroups:[],toggleGroup:Se}},zf=({children:e,name:t,groupId:o,className:n})=>{const{openedGroups:r,toggleGroup:s}=pi(),l=r.includes(o),a=d.useCallback(()=>{s(o)},[o,s]);return i.jsxs(fi,{className:n,children:[i.jsxs(Of,{"data-open":l,onClick:a,children:[l?i.jsx(R,{iconId:"CaretDown",size:"xsm"}):i.jsx(R,{iconId:"CaretRight",size:"xsm"}),i.jsx(E,{variant:"body",bold:!0,children:t})]}),i.jsx(Rf,{children:l?i.jsx(Nf,{className:"list-container",children:e}):null})]},o)},Mf=({children:e,groupId:t,className:o})=>i.jsx(fi,{className:o,children:e},t),fi=g.div`
2448
2454
  display: flex;
2449
2455
  flex-direction: column;
2450
2456
  padding-bottom: 8px;
2451
- `,Ef=g.div`
2457
+ `,Of=g.div`
2452
2458
  display: flex;
2453
2459
  flex: 0;
2454
2460
  cursor: pointer;
2455
2461
  gap: 4px;
2456
2462
  padding-inline: 12px 12px;
2457
2463
  align-items: center;
2458
- `,zf=g.div`
2464
+ `,Rf=g.div`
2459
2465
  display: flex;
2460
2466
  flex-direction: column;
2461
- `,Mf=g.div`
2467
+ `,Nf=g.div`
2462
2468
  padding-inline-start: 16px;
2463
2469
  align-items: center;
2464
2470
  gap: 6px;
@@ -2497,7 +2503,7 @@
2497
2503
  `,xi=g(So)`
2498
2504
  height: initial;
2499
2505
  padding: 0;
2500
- `,yi=d.memo(({className:e,disabled:t,id:o,label:n,mode:r="standard",name:s,showDivider:l=!0})=>{const{selected:a,toggleSelection:u,isDisabled:p}=Ae(),h=d.useCallback(()=>{u(o)},[o,u]),f=r==="compact"?bi:$o,m=r==="compact"?xi:So,b=l?r==="compact"?mi:gi:r==="compact"?Un:Qt;return i.jsxs(b,{className:e,children:[i.jsx(f,{children:i.jsx(_t,{disabled:p||t,checked:a.includes(o),onChange:h})}),i.jsxs(m,{children:[i.jsx(E,{variant:"body",children:s}),!!n&&i.jsx(E,{color:"grey",variant:"body",children:n})]})]})}),Of=g.div`
2506
+ `,yi=d.memo(({className:e,disabled:t,id:o,label:n,mode:r="standard",name:s,showDivider:l=!0})=>{const{selected:a,toggleSelection:u,isDisabled:h}=Le(),p=d.useCallback(()=>{u(o)},[o,u]),f=r==="compact"?bi:$o,m=r==="compact"?xi:So,b=l?r==="compact"?mi:gi:r==="compact"?Un:Qt;return i.jsxs(b,{className:e,children:[i.jsx(f,{children:i.jsx(_t,{disabled:h||t,checked:a.includes(o),onChange:p})}),i.jsxs(m,{children:[i.jsx(E,{variant:"body",children:s}),!!n&&i.jsx(E,{color:"grey",variant:"body",children:n})]})]})}),Ff=g.div`
2501
2507
  display: flex;
2502
2508
  padding: 4px 12px 4px 4px;
2503
2509
  align-items: center;
@@ -2505,14 +2511,14 @@
2505
2511
  align-self: stretch;
2506
2512
  border-bottom: 0.5px solid var(--Grey-20, #dfdfdf);
2507
2513
  background: var(--Grey-White, #fff);
2508
- `,Rf=g.div`
2514
+ `,Af=g.div`
2509
2515
  display: flex;
2510
2516
  height: 30px;
2511
2517
  padding: 8px;
2512
2518
  justify-content: center;
2513
2519
  align-items: center;
2514
2520
  gap: 16px;
2515
- `,Nf=g.div`
2521
+ `,Lf=g.div`
2516
2522
  flex: 1 1 auto;
2517
2523
  display: flex;
2518
2524
  align-items: center;
@@ -2521,15 +2527,15 @@
2521
2527
  padding: 8px 8px 8px 4px;
2522
2528
  gap: 4px;
2523
2529
  align-self: stretch;
2524
- `,Ff=e=>{const{selected:t,toggleSelection:o,isDisabled:n}=Ae(),r=d.useCallback(()=>{o(e.id)},[e,o]);return i.jsxs(Of,{children:[i.jsx(Rf,{children:i.jsx("input",{onChange:r,type:"checkbox",checked:t.includes(e.id),disabled:n})}),i.jsx(Nf,{children:i.jsx(E,{variant:"body",children:e.name})})]})},[Pe]=M(["named-list-item"]),Af=d.memo(({id:e,iconId:t,iconColor:o,suffixIcons:n,name:r,className:s,subText:l,subTextColor:a})=>{const{selected:u,toggleSelection:p,isDisabled:h}=Ae(),f=d.useCallback(()=>{h||p(e)},[e,p,h]),m=u.includes(e);return i.jsx(z.ClassNames,{children:({cx:b})=>i.jsxs(Lf,{className:b(s,{isSelected:m,isDisabled:h}),onClick:f,children:[i.jsxs(Bf,{children:[t&&i.jsx(R,{size:"sm",iconId:t,color:o}),i.jsx(E,{className:"named-list-item-text",variant:"body",children:r}),!!n&&i.jsx(Pf,{children:n.map(({iconId:x,iconColor:y})=>i.jsx(R,{size:"xsm",iconId:x,color:m?"white":y},x))})]}),!!l&&i.jsx(Wf,{className:b({hasIcon:!!t}),children:i.jsx(Vf,{color:a??"dark",variant:"body",children:l})})]})})}),Lf=g.div`
2530
+ `,Bf=e=>{const{selected:t,toggleSelection:o,isDisabled:n}=Le(),r=d.useCallback(()=>{o(e.id)},[e,o]);return i.jsxs(Ff,{children:[i.jsx(Af,{children:i.jsx("input",{onChange:r,type:"checkbox",checked:t.includes(e.id),disabled:n})}),i.jsx(Lf,{children:i.jsx(E,{variant:"body",children:e.name})})]})},[Ve]=M(["named-list-item"]),Wf=d.memo(({id:e,iconId:t,iconColor:o,suffixIcons:n,name:r,className:s,subText:l,subTextColor:a})=>{const{selected:u,toggleSelection:h,isDisabled:p}=Le(),f=d.useCallback(()=>{p||h(e)},[e,h,p]),m=u.includes(e);return i.jsx(z.ClassNames,{children:({cx:b})=>i.jsxs(Pf,{className:b(s,{isSelected:m,isDisabled:p}),onClick:f,children:[i.jsxs(Vf,{children:[t&&i.jsx(R,{size:"sm",iconId:t,color:o}),i.jsx(E,{className:"named-list-item-text",variant:"body",children:r}),!!n&&i.jsx(Uf,{children:n.map(({iconId:x,iconColor:y})=>i.jsx(R,{size:"xsm",iconId:x,color:m?"white":y},x))})]}),!!l&&i.jsx(Hf,{className:b({hasIcon:!!t}),children:i.jsx(Gf,{color:a??"dark",variant:"body",children:l})})]})})}),Pf=g.div`
2525
2531
  display: flex;
2526
- padding-top: ${Pe("padding-y")};
2527
- padding-right: ${Pe("padding-right")};
2528
- padding-bottom: ${Pe("padding-y")};
2529
- padding-left: ${Pe("padding-left")};
2532
+ padding-top: ${Ve("padding-y")};
2533
+ padding-right: ${Ve("padding-right")};
2534
+ padding-bottom: ${Ve("padding-y")};
2535
+ padding-left: ${Ve("padding-left")};
2530
2536
  align-items: flex-start;
2531
2537
  justify-content: flex-start;
2532
- gap: ${Pe("row-gap")};
2538
+ gap: ${Ve("row-gap")};
2533
2539
  color: inherit;
2534
2540
  background-color: transparent;
2535
2541
  flex-direction: column;
@@ -2538,37 +2544,37 @@
2538
2544
  cursor: unset;
2539
2545
  }
2540
2546
  &.isSelected {
2541
- color: ${Pe("color-selected")};
2542
- background-color: ${Pe("background-color-selected")};
2547
+ color: ${Ve("color-selected")};
2548
+ background-color: ${Ve("background-color-selected")};
2543
2549
  }
2544
- `,Bf=g.div`
2550
+ `,Vf=g.div`
2545
2551
  width: 100%;
2546
2552
  display: flex;
2547
2553
  align-items: center;
2548
2554
  justify-content: flex-start;
2549
- gap: ${Pe("column-gap")};
2550
- `,Wf=g.div`
2555
+ gap: ${Ve("column-gap")};
2556
+ `,Hf=g.div`
2551
2557
  width: 100%;
2552
2558
  display: flex;
2553
2559
  align-items: center;
2554
2560
  justify-content: flex-start;
2555
2561
  &.hasIcon {
2556
- padding-left: ${Pe("subtext-padding-with-icon")};
2562
+ padding-left: ${Ve("subtext-padding-with-icon")};
2557
2563
  }
2558
- `,Pf=g.div`
2564
+ `,Uf=g.div`
2559
2565
  display: flex;
2560
2566
  align-items: center;
2561
2567
  justify-content: flex-end;
2562
2568
  margin-left: auto;
2563
- gap: ${Pe("column-gap")};
2564
- `,Vf=g(E)`
2569
+ gap: ${Ve("column-gap")};
2570
+ `,Gf=g(E)`
2565
2571
  -webkit-box-orient: vertical;
2566
2572
  -webkit-line-clamp: 2;
2567
2573
  display: -webkit-box;
2568
2574
  overflow-wrap: anywhere;
2569
2575
  overflow: hidden;
2570
2576
  text-overflow: ellipsis;
2571
- `,Hf=g.div`
2577
+ `,Kf=g.div`
2572
2578
  display: flex;
2573
2579
  padding: ${c("spacing-8")} ${c("spacing-10")};
2574
2580
  align-items: center;
@@ -2581,11 +2587,11 @@
2581
2587
  color: ${c("color-white")};
2582
2588
  background-color: ${c("color-primary")};
2583
2589
  }
2584
- `,Uf=e=>{const{selected:t,toggleSelection:o}=Ae(),n=d.useCallback(()=>{o(e.id)},[e,o]);return i.jsx(z.ClassNames,{children:({cx:r})=>i.jsxs(Hf,{className:r({isSelected:t.includes(e.id)}),onClick:n,children:[e.iconId&&i.jsx(R,{size:"sm",iconId:e.iconId}),i.jsx(E,{variant:"body",children:e.name})]})})},Gf=e=>{const[t,o]=d.useState(e);return{onGroupOpen:d.useCallback(async(r,s)=>{o((l=[])=>s==="opened"&&!(l!=null&&l.includes(r))?[...l,r]:s==="closed"&&l.includes(r)?l.filter(a=>a!==r):l)},[]),openedGroups:t}},Kf=(e,t={})=>{const[o,n]=d.useState(t),r=d.useCallback((l,a)=>{var f;const u=(f=e==null?void 0:e.items.find(m=>m.id===l))==null?void 0:f.group.groupId;if(!u)return;const p=o[u]||[],h=a==="selected"?{...o,[u]:[...p,l]}:{...o,[u]:p.filter(m=>m!==l)};n(h)},[e==null?void 0:e.items,o]);return{clear:d.useCallback(()=>{n({})},[]),groupSelection:o,onSelect:r}},Yf=(e=[],t=!0)=>{const[o,n]=d.useState(e),r=d.useCallback(l=>{n(a=>t?[l]:a.includes(l)?a.filter(u=>u!==l):[...a,l])},[t]);return{clear:d.useCallback(()=>{n([])},[]),onSelect:r,selected:o}};class qf extends Wn{constructor(o,n,r,s,l){super(o,n,r,l);T(this,"parentIdKey");T(this,"idKey");this.parentIdKey=s.parentIdKey,this.idKey=s.idKey,_.makeObservable(this,{tree:_.computed,childBranchLookup:_.computed,itemsById:_.computed})}sortBranch(o,n){return o.name.localeCompare(n.name)}get itemsById(){return this.items.reduce((o,n)=>({...o,[n[this.idKey]]:n}),{})}get childBranchLookup(){return this.items.reduce((o,n)=>{let r=n[this.parentIdKey];return(!r||this.itemsById[r]===void 0)&&(r="ROOT"),r&&o[r]?(o[r].push(n),o):(o[r]=[n],o)},{ROOT:[]})}get tree(){const o=r=>{const s=[];for(const l in r){let a={...r[l],branches:[]};const u=this.childBranchLookup[a[this.idKey]];a&&(u&&(a={...a,branches:o(u)}),s.push(a))}return s},n=this.childBranchLookup.ROOT;return n?o(n):[]}}const vi=d.createContext(null),Zf=W.kosComponent(({children:e,singleBranchOnly:t,openedBranches:o,setOpenedBranches:n,dataProvider:r})=>{const[s,l]=d.useState([]),a=o??s,u=n??l,p=d.useRef(a);d.useLayoutEffect(()=>{p.current=a},[a]);const h=d.useCallback(m=>{if(!(r!=null&&r.tree))return;const b=m[r.idKey],x=p.current.includes(b),y=v=>v.branches.flatMap($=>{const C=$[r.idKey];return $.branches.length?[C,...y($)]:[]}),k=y(m);if(t){const v=[],$=C=>{const S=C[r.parentIdKey];if(S){const w=r.itemsById[S];w&&(v.push(S),$(w))}};$(m),u(x?v:[...v,b])}else{const v=x?p.current.filter($=>b!==$&&!k.includes($)):[...p.current,b];u(v)}},[r==null?void 0:r.idKey,r==null?void 0:r.itemsById,r==null?void 0:r.parentIdKey,r==null?void 0:r.tree,u,t]),f=d.useMemo(()=>({openedBranches:a,toggleBranch:h}),[a,h]);return i.jsx(vi.Provider,{value:f,children:e})}),ki=()=>{const e=d.useContext(vi);if(e===null)throw new Error("TreeContext can only be used inside children of TreeContextProvider");return e};function wi(e){return e.build!==void 0}const Xf=e=>(t,o,n)=>{const r=(s,l)=>{if(!s.branches.length&&s.isGroup)return null;if(s.branches.length){const a=wi(e)?e.build(s):e,u=s.branches.map(p=>{if(p.branches.length)return r(p,!0);{const h=Yt(o)?o.build(p):o;return i.jsx(h,{"data-key":p.id,...p,onListItemAction:n},p.id)}});return i.jsx(z.ClassNames,{children:({cx:p})=>i.jsx(a,{className:p({isNotRoot:l},s.className),...s,children:u},s.id)},s.id)}else{const a=Yt(o)?o.build(s):o;return i.jsx(a,{"data-key":s.id,...s,onListItemAction:n},s.id)}};return t.tree.map(s=>r(s))},Jf=W.kosComponent(({dataProvider:e,ItemTemplate:t,onSelect:o,BranchTemplate:n,openedBranches:r,setOpenedBranches:s,singleBranchOnly:l,className:a,autoSelectFirstItem:u,selected:p,emptyState:h,getFirstItem:f,onListItemAction:m})=>i.jsx(Zf,{dataProvider:e,openedBranches:r,setOpenedBranches:s,singleBranchOnly:l,children:i.jsx(Co,{onSelect:o,dataProvider:e,ItemTemplate:t,autoSelectFirstItem:u,emptyState:h,className:a,selected:p,onListItemAction:m,getFirstItem:f,itemListRenderer:Xf(n)})}));function Qf(e){return(e==null?void 0:e.build)!==void 0}const Ci=d.createContext(null),eg=()=>{const e=d.useContext(Ci);if(e===null)throw new Error("useAsyncTreeContext can only be used inside AsyncTreeList");return e},$i=W.kosComponent(({branch:e,provider:t,BranchTemplate:o,ItemTemplate:n,onBranchExpand:r,onBranchCollapse:s,onListItemAction:l,onBranchSelect:a,selectedBranchId:u,branchEmptyState:p=i.jsx("div",{style:{paddingLeft:"32px",color:"#999"},children:"No items"}),depth:h=0,nodeIconMap:f,nodeActions:m,nodeDecorators:b,expandedMode:x=!1,indentSize:y,isNodeSelectable:k,branchContentRenderer:v,itemContentRenderer:$,disableSelectionStyling:C=!1})=>{const S=eg();d.useEffect(()=>{const G=S.openedBranches.includes(e.id),ee=e.loadingState.status==="idle",Ze=!e.isLeaf;if(G&&ee&&Ze){const Le=t.originalItems.get(e.id);Le&&t.expandBranch(e.id,Le)}},[S.openedBranches,e.id,e.loadingState.status,e.isLeaf,t]);const w=d.useMemo(()=>{if(!f)return;if(typeof f=="function")return f(e);const G=e.type;return G?f[G]:void 0},[f,e]),I=d.useMemo(()=>{if(!(m!=null&&m.length))return;const G=t.originalItems.get(e.id);if(G)return m.filter(ee=>!ee.visibleFor||ee.visibleFor(e)).map(ee=>({id:ee.id,iconId:ee.iconId,color:ee.color,tooltip:ee.tooltip,label:ee.label,isPrimary:ee.isPrimary,onClick:()=>ee.onClick(e.id,G)}))},[m,e,t]),j=(()=>{if(b!=null&&b.length)return b.filter(G=>!G.visibleFor||G.visibleFor(e)).map(G=>({id:G.id,iconId:G.iconId,color:G.color,tooltip:G.tooltip}))})(),D=async()=>{if(S.openedBranches.includes(e.id))s==null||s(e.id);else if(e.loadingState.status==="idle"){const ee=t.originalItems.get(e.id);ee&&(await(r==null?void 0:r(e.id,ee)),await t.expandBranch(e.id,ee))}S.toggleBranch(e.id)},L=()=>{const G=t.originalItems.get(e.id);G&&(a==null||a(e.id,G))},U=Ae();if(e.isLeaf){const G=Qf(n)?n.build(e):n,ee=U.selected.includes(e.id),Ze=$?$(e,ee):void 0,Le=Kt(e);return i.jsx(G,{"data-key":e.id,...e,...Le!==void 0?{[Gt]:Le}:{},onListItemAction:l,"data-depth":h,"data-indent-size":y,"data-disable-selection-styling":C,iconId:w==null?void 0:w.iconId,iconColor:w==null?void 0:w.color,actions:I,decorators:j,children:Ze},e.id)}const P=wi(o)?o.build(e):o,B=x||S.openedBranches.includes(e.id),Z=e.loadingState.status==="loading",ie=e.loadingState.status==="error",J=e.loadingState.status==="loaded",X=u===e.id,je=B?e.branches.length>0?e.branches.map(G=>i.jsx($i,{branch:G,provider:t,BranchTemplate:o,ItemTemplate:n,onBranchExpand:r,onBranchCollapse:s,onListItemAction:l,onBranchSelect:a,selectedBranchId:u,branchEmptyState:p,depth:h+1,nodeIconMap:f,nodeActions:m,nodeDecorators:b,expandedMode:x,indentSize:y,isNodeSelectable:k,branchContentRenderer:v,itemContentRenderer:$,disableSelectionStyling:C},G.id)):J&&p?[p]:[]:[],le=v?v(e,X):void 0,pe=k?k(e):!0,Q=Kt(e);return i.jsx(St.Observer,{children:()=>i.jsx(P,{className:e.className,...e,...Q!==void 0?{[Gt]:Q}:{},onClick:x?L:D,onSelect:L,"data-loading":Z,"data-error":ie,"data-open":B,"data-selected":X,"data-expanded-mode":x,"data-depth":h,"data-indent-size":y,"data-selectable":pe,"data-disable-selection-styling":C,iconId:w==null?void 0:w.iconId,iconColor:w==null?void 0:w.color,actions:I,decorators:j,content:le,children:je})})}),Si=W.kosComponent(({dataProvider:e,BranchTemplate:t,ItemTemplate:o,onBranchExpand:n,onBranchCollapse:r,onListItemAction:s,onBranchSelect:l,selectedBranchId:a,emptyState:u,branchEmptyState:p,className:h,singleBranchOnly:f,openedBranches:m,setOpenedBranches:b,nodeIconMap:x,nodeActions:y,nodeDecorators:k,expandedMode:v=!1,indentSize:$,isNodeSelectable:C,branchContentRenderer:S,itemContentRenderer:w,disableSelectionStyling:I=!1})=>{const[j,D]=d.useState(!1),[L,U]=d.useState([]),P=m??L,B=b??U;d.useEffect(()=>e?((async()=>{await e.init(),D(!0)})(),()=>{e.dispose()}):void 0,[e]),d.useEffect(()=>{var X;!v||!j||!e||(X=e.expandAll)==null||X.call(e)},[v,j,e]);const Z=d.useCallback(X=>{const je=P.includes(X);B(f?je?[]:[X]:je?P.filter(le=>le!==X):[...P,X])},[P,B,f]),ie=d.useMemo(()=>({openedBranches:P,toggleBranch:Z}),[P,Z]);if(!j||!e)return u||null;const J=m&&m.length>0&&e.tree.some(X=>m.includes(X.id)&&!X.isLeaf&&X.loadingState.status!=="loaded");return i.jsx(Ci.Provider,{value:ie,children:i.jsx(St.Observer,{children:()=>i.jsxs("div",{className:h,style:J?{visibility:"hidden"}:void 0,children:[e.tree.length===0&&u,e.tree.map(X=>i.jsx($i,{branch:X,provider:e,BranchTemplate:t,ItemTemplate:o,onBranchExpand:n,onBranchCollapse:r,onListItemAction:s,onBranchSelect:l,selectedBranchId:a,branchEmptyState:p,nodeIconMap:x,nodeActions:y,nodeDecorators:k,expandedMode:v,indentSize:$,isNodeSelectable:C,branchContentRenderer:S,itemContentRenderer:w,disableSelectionStyling:I},X.id))]})})})}),tg=W.kosComponent(({isSingleSelect:e=!0,onSelect:t,selected:o,disabled:n,autoSelectFirstItem:r,dataProvider:s,...l})=>{const[a,u]=d.useState(o??[]),p=d.useRef(a??[]);d.useLayoutEffect(()=>{p.current=a},[a]),d.useEffect(()=>{u(o??[])},[o]);const h=d.useCallback(b=>{t(b,p.current.includes(b)?"unselected":"selected"),u(x=>e?[b]:x.includes(b)?x.filter(y=>y!==b):[...x,b])},[e,t]),f=d.useCallback(b=>p.current.includes(b),[]),m=d.useMemo(()=>({isSelected:f,selected:a,toggleSelection:h,isDisabled:!!n}),[f,a,h,n]);return d.useEffect(()=>{var b;if(r&&(s!=null&&s.rootItems)&&p.current.length===0){const x=(b=s.rootItems[0])==null?void 0:b.id;x&&h(x)}},[r,s==null?void 0:s.rootItems,h]),i.jsx(mt.Provider,{value:m,children:i.jsx(Si,{dataProvider:s,...l})})}),og=({children:e,id:t,className:o})=>i.jsx(z.ClassNames,{children:({cx:n})=>i.jsx(ng,{className:n("anonymous-branch",o),children:e},t)}),ng=g.div`
2590
+ `,Yf=e=>{const{selected:t,toggleSelection:o}=Le(),n=d.useCallback(()=>{o(e.id)},[e,o]);return i.jsx(z.ClassNames,{children:({cx:r})=>i.jsxs(Kf,{className:r({isSelected:t.includes(e.id)}),onClick:n,children:[e.iconId&&i.jsx(R,{size:"sm",iconId:e.iconId}),i.jsx(E,{variant:"body",children:e.name})]})})},qf=e=>{const[t,o]=d.useState(e);return{onGroupOpen:d.useCallback(async(r,s)=>{o((l=[])=>s==="opened"&&!(l!=null&&l.includes(r))?[...l,r]:s==="closed"&&l.includes(r)?l.filter(a=>a!==r):l)},[]),openedGroups:t}},Zf=(e,t={})=>{const[o,n]=d.useState(t),r=d.useCallback((l,a)=>{var f;const u=(f=e==null?void 0:e.items.find(m=>m.id===l))==null?void 0:f.group.groupId;if(!u)return;const h=o[u]||[],p=a==="selected"?{...o,[u]:[...h,l]}:{...o,[u]:h.filter(m=>m!==l)};n(p)},[e==null?void 0:e.items,o]);return{clear:d.useCallback(()=>{n({})},[]),groupSelection:o,onSelect:r}},Xf=(e=[],t=!0)=>{const[o,n]=d.useState(e),r=d.useCallback(l=>{n(a=>t?[l]:a.includes(l)?a.filter(u=>u!==l):[...a,l])},[t]);return{clear:d.useCallback(()=>{n([])},[]),onSelect:r,selected:o}};class Jf extends Wn{constructor(o,n,r,s,l){super(o,n,r,l);T(this,"parentIdKey");T(this,"idKey");this.parentIdKey=s.parentIdKey,this.idKey=s.idKey,_.makeObservable(this,{tree:_.computed,childBranchLookup:_.computed,itemsById:_.computed})}sortBranch(o,n){return o.name.localeCompare(n.name)}get itemsById(){return this.items.reduce((o,n)=>({...o,[n[this.idKey]]:n}),{})}get childBranchLookup(){return this.items.reduce((o,n)=>{let r=n[this.parentIdKey];return(!r||this.itemsById[r]===void 0)&&(r="ROOT"),r&&o[r]?(o[r].push(n),o):(o[r]=[n],o)},{ROOT:[]})}get tree(){const o=r=>{const s=[];for(const l in r){let a={...r[l],branches:[]};const u=this.childBranchLookup[a[this.idKey]];a&&(u&&(a={...a,branches:o(u)}),s.push(a))}return s},n=this.childBranchLookup.ROOT;return n?o(n):[]}}const vi=d.createContext(null),Qf=W.kosComponent(({children:e,singleBranchOnly:t,openedBranches:o,setOpenedBranches:n,dataProvider:r})=>{const[s,l]=d.useState([]),a=o??s,u=n??l,h=d.useRef(a);d.useLayoutEffect(()=>{h.current=a},[a]);const p=d.useCallback(m=>{if(!(r!=null&&r.tree))return;const b=m[r.idKey],x=h.current.includes(b),y=v=>v.branches.flatMap($=>{const C=$[r.idKey];return $.branches.length?[C,...y($)]:[]}),k=y(m);if(t){const v=[],$=C=>{const S=C[r.parentIdKey];if(S){const w=r.itemsById[S];w&&(v.push(S),$(w))}};$(m),u(x?v:[...v,b])}else{const v=x?h.current.filter($=>b!==$&&!k.includes($)):[...h.current,b];u(v)}},[r==null?void 0:r.idKey,r==null?void 0:r.itemsById,r==null?void 0:r.parentIdKey,r==null?void 0:r.tree,u,t]),f=d.useMemo(()=>({openedBranches:a,toggleBranch:p}),[a,p]);return i.jsx(vi.Provider,{value:f,children:e})}),ki=()=>{const e=d.useContext(vi);if(e===null)throw new Error("TreeContext can only be used inside children of TreeContextProvider");return e};function wi(e){return e.build!==void 0}const eg=e=>(t,o,n)=>{const r=(s,l)=>{if(!s.branches.length&&s.isGroup)return null;if(s.branches.length){const a=wi(e)?e.build(s):e,u=s.branches.map(h=>{if(h.branches.length)return r(h,!0);{const p=Yt(o)?o.build(h):o;return i.jsx(p,{"data-key":h.id,...h,onListItemAction:n},h.id)}});return i.jsx(z.ClassNames,{children:({cx:h})=>i.jsx(a,{className:h({isNotRoot:l},s.className),...s,children:u},s.id)},s.id)}else{const a=Yt(o)?o.build(s):o;return i.jsx(a,{"data-key":s.id,...s,onListItemAction:n},s.id)}};return t.tree.map(s=>r(s))},tg=W.kosComponent(({dataProvider:e,ItemTemplate:t,onSelect:o,BranchTemplate:n,openedBranches:r,setOpenedBranches:s,singleBranchOnly:l,className:a,autoSelectFirstItem:u,selected:h,emptyState:p,getFirstItem:f,onListItemAction:m})=>i.jsx(Qf,{dataProvider:e,openedBranches:r,setOpenedBranches:s,singleBranchOnly:l,children:i.jsx(Co,{onSelect:o,dataProvider:e,ItemTemplate:t,autoSelectFirstItem:u,emptyState:p,className:a,selected:h,onListItemAction:m,getFirstItem:f,itemListRenderer:eg(n)})}));function og(e){return(e==null?void 0:e.build)!==void 0}const Ci=d.createContext(null),ng=()=>{const e=d.useContext(Ci);if(e===null)throw new Error("useAsyncTreeContext can only be used inside AsyncTreeList");return e},$i=W.kosComponent(({branch:e,provider:t,BranchTemplate:o,ItemTemplate:n,onBranchExpand:r,onBranchCollapse:s,onListItemAction:l,onBranchSelect:a,selectedBranchId:u,branchEmptyState:h=i.jsx("div",{style:{paddingLeft:"32px",color:"#999"},children:"No items"}),depth:p=0,nodeIconMap:f,nodeActions:m,nodeDecorators:b,expandedMode:x=!1,indentSize:y,isNodeSelectable:k,branchContentRenderer:v,itemContentRenderer:$,disableSelectionStyling:C=!1})=>{const S=ng();d.useEffect(()=>{const K=S.openedBranches.includes(e.id),ee=e.loadingState.status==="idle",Xe=!e.isLeaf;if((K||x)&&ee&&Xe){const Be=t.originalItems.get(e.id);Be&&t.expandBranch(e.id,Be)}},[S.openedBranches,e.id,e.loadingState.status,e.isLeaf,t,x]);const w=d.useMemo(()=>{if(!f)return;if(typeof f=="function")return f(e);const K=e.type;return K?f[K]:void 0},[f,e]),I=d.useMemo(()=>{if(!(m!=null&&m.length))return;const K=t.originalItems.get(e.id);if(K)return m.filter(ee=>!ee.visibleFor||ee.visibleFor(e)).map(ee=>({id:ee.id,iconId:ee.iconId,color:ee.color,tooltip:ee.tooltip,label:ee.label,isPrimary:ee.isPrimary,onClick:()=>ee.onClick(e.id,K)}))},[m,e,t]),j=(()=>{if(b!=null&&b.length)return b.filter(K=>!K.visibleFor||K.visibleFor(e)).map(K=>({id:K.id,iconId:K.iconId,color:K.color,tooltip:K.tooltip}))})(),D=async()=>{if(S.openedBranches.includes(e.id))s==null||s(e.id);else if(e.loadingState.status==="idle"){const ee=t.originalItems.get(e.id);ee&&(await(r==null?void 0:r(e.id,ee)),await t.expandBranch(e.id,ee))}S.toggleBranch(e.id)},L=()=>{const K=t.originalItems.get(e.id);K&&(a==null||a(e.id,K))},U=Le();if(e.isLeaf){const K=og(n)?n.build(e):n,ee=U.selected.includes(e.id),Xe=$?$(e,ee):void 0,Be=Kt(e);return i.jsx(K,{"data-key":e.id,...e,...Be!==void 0?{[Gt]:Be}:{},onListItemAction:l,"data-depth":p,"data-indent-size":y,"data-disable-selection-styling":C,iconId:w==null?void 0:w.iconId,iconColor:w==null?void 0:w.color,actions:I,decorators:j,children:Xe},e.id)}const P=wi(o)?o.build(e):o,B=x||S.openedBranches.includes(e.id),Z=e.loadingState.status==="loading",ie=e.loadingState.status==="error",J=e.loadingState.status==="loaded",X=u===e.id,je=B?e.branches.length>0?e.branches.map(K=>i.jsx($i,{branch:K,provider:t,BranchTemplate:o,ItemTemplate:n,onBranchExpand:r,onBranchCollapse:s,onListItemAction:l,onBranchSelect:a,selectedBranchId:u,branchEmptyState:h,depth:p+1,nodeIconMap:f,nodeActions:m,nodeDecorators:b,expandedMode:x,indentSize:y,isNodeSelectable:k,branchContentRenderer:v,itemContentRenderer:$,disableSelectionStyling:C},K.id)):J&&h?[h]:[]:[],le=v?v(e,X):void 0,he=k?k(e):!0,Q=Kt(e);return i.jsx(St.Observer,{children:()=>i.jsx(P,{className:e.className,...e,...Q!==void 0?{[Gt]:Q}:{},onClick:x?L:D,onSelect:L,"data-loading":Z,"data-error":ie,"data-open":B,"data-selected":X,"data-expanded-mode":x,"data-depth":p,"data-indent-size":y,"data-selectable":he,"data-disable-selection-styling":C,iconId:w==null?void 0:w.iconId,iconColor:w==null?void 0:w.color,actions:I,decorators:j,content:le,children:je})})}),Si=W.kosComponent(({dataProvider:e,BranchTemplate:t,ItemTemplate:o,onBranchExpand:n,onBranchCollapse:r,onListItemAction:s,onBranchSelect:l,selectedBranchId:a,emptyState:u,branchEmptyState:h,className:p,singleBranchOnly:f,openedBranches:m,setOpenedBranches:b,nodeIconMap:x,nodeActions:y,nodeDecorators:k,expandedMode:v=!1,indentSize:$,isNodeSelectable:C,branchContentRenderer:S,itemContentRenderer:w,disableSelectionStyling:I=!1})=>{const[j,D]=d.useState(!1),[L,U]=d.useState([]),P=m??L,B=b??U;d.useEffect(()=>e?((async()=>{await e.init(),D(!0)})(),()=>{e.dispose()}):void 0,[e]),d.useEffect(()=>{var X;!v||!j||!e||(X=e.expandAll)==null||X.call(e)},[v,j,e]);const Z=d.useCallback(X=>{const je=P.includes(X);B(f?je?[]:[X]:je?P.filter(le=>le!==X):[...P,X])},[P,B,f]),ie=d.useMemo(()=>({openedBranches:P,toggleBranch:Z}),[P,Z]);if(!j||!e)return u||null;const J=m&&m.length>0&&e.tree.some(X=>m.includes(X.id)&&!X.isLeaf&&X.loadingState.status!=="loaded");return i.jsx(Ci.Provider,{value:ie,children:i.jsx(St.Observer,{children:()=>i.jsxs("div",{className:p,style:J?{visibility:"hidden"}:void 0,children:[e.tree.length===0&&u,e.tree.map(X=>i.jsx($i,{branch:X,provider:e,BranchTemplate:t,ItemTemplate:o,onBranchExpand:n,onBranchCollapse:r,onListItemAction:s,onBranchSelect:l,selectedBranchId:a,branchEmptyState:h,nodeIconMap:x,nodeActions:y,nodeDecorators:k,expandedMode:v,indentSize:$,isNodeSelectable:C,branchContentRenderer:S,itemContentRenderer:w,disableSelectionStyling:I},X.id))]})})})}),rg=W.kosComponent(({isSingleSelect:e=!0,onSelect:t,selected:o,disabled:n,autoSelectFirstItem:r,dataProvider:s,...l})=>{const[a,u]=d.useState(o??[]),h=d.useRef(a??[]);d.useLayoutEffect(()=>{h.current=a},[a]),d.useEffect(()=>{u(o??[])},[o]);const p=d.useCallback(b=>{t(b,h.current.includes(b)?"unselected":"selected"),u(x=>e?[b]:x.includes(b)?x.filter(y=>y!==b):[...x,b])},[e,t]),f=d.useCallback(b=>h.current.includes(b),[]),m=d.useMemo(()=>({isSelected:f,selected:a,toggleSelection:p,isDisabled:!!n}),[f,a,p,n]);return d.useEffect(()=>{var b;if(r&&(s!=null&&s.rootItems)&&h.current.length===0){const x=(b=s.rootItems[0])==null?void 0:b.id;x&&p(x)}},[r,s==null?void 0:s.rootItems,p]),i.jsx(mt.Provider,{value:m,children:i.jsx(Si,{dataProvider:s,...l})})}),sg=({children:e,id:t,className:o})=>i.jsx(z.ClassNames,{children:({cx:n})=>i.jsx(ig,{className:n("anonymous-branch",o),children:e},t)}),ig=g.div`
2585
2591
  display: flex;
2586
2592
  flex-direction: column;
2587
2593
  width: 100%;
2588
- `,[Me]=M(["named-collapsible-branch"]),rg=20,sg=W.kosComponent(({children:e,className:t,onClick:o,onSelect:n,"data-loading":r,"data-open":s,"data-expanded-mode":l,"data-depth":a=0,"data-indent-size":u=rg,"data-selectable":p=!0,"data-disable-selection-styling":h=!1,iconId:f,iconColor:m,actions:b,decorators:x,content:y,...k})=>{const{isSelected:v,toggleSelection:$,selected:C}=Ae(),S=p&&C.includes(k.id),w=L=>{L.stopPropagation(),o==null||o()},I=()=>{p?($(k.id),n==null||n()):o==null||o()},j=typeof u=="string"?Number(u):u,D=a>0?{marginLeft:`${a*j}px`}:void 0;return i.jsxs(cg,{className:t,isOpen:s,style:D,children:[i.jsxs(dg,{"data-loading":r,"data-selected":S,onClick:I,$isSelected:S,$disableSelectionStyling:h,children:[!l&&i.jsx(ig,{onClick:w,type:"button",children:i.jsx(ag,{iconId:"CaretRight",size:"xxsm",$isOpen:s})}),f&&i.jsx(R,{size:"sm",iconId:f,color:m}),i.jsxs(lg,{children:[y||i.jsx(E,{variant:"body",bold:!0,children:k.name}),r&&i.jsx(E,{variant:"body",children:"(Loading...)"})]}),x&&x.length>0&&i.jsx(hg,{children:x.map(L=>i.jsx(fg,{size:"sm",iconId:L.iconId,color:S&&!h?"white":L.color,title:L.tooltip},L.id))}),b&&b.length>0&&i.jsx(Jt,{actions:b,isSelected:S,disableSelectionStyling:h})]}),i.jsx(ug,{className:"inner-container",children:i.jsx(pg,{className:"list-container",children:e})})]},k.id)}),ig=g.button`
2594
+ `,[Me]=M(["named-collapsible-branch"]),ag=20,lg=W.kosComponent(({children:e,className:t,onClick:o,onSelect:n,"data-loading":r,"data-open":s,"data-expanded-mode":l,"data-depth":a=0,"data-indent-size":u=ag,"data-selectable":h=!0,"data-disable-selection-styling":p=!1,iconId:f,iconColor:m,actions:b,decorators:x,content:y,...k})=>{const{isSelected:v,toggleSelection:$,selected:C}=Le(),S=h&&C.includes(k.id),w=L=>{L.stopPropagation(),o==null||o()},I=()=>{h?($(k.id),n==null||n()):o==null||o()},j=typeof u=="string"?Number(u):u,D=a>0?{marginLeft:`${a*j}px`}:void 0;return i.jsxs(hg,{className:t,isOpen:s,style:D,children:[i.jsxs(pg,{"data-loading":r,"data-selected":S,onClick:I,$isSelected:S,$disableSelectionStyling:p,children:[!l&&i.jsx(cg,{onClick:w,type:"button",children:i.jsx(dg,{iconId:"CaretRight",size:"xxsm",$isOpen:s})}),f&&i.jsx(R,{size:"sm",iconId:f,color:m}),i.jsxs(ug,{children:[y||i.jsx(E,{variant:"body",bold:!0,children:k.name}),r&&i.jsx(E,{variant:"body",children:"(Loading...)"})]}),x&&x.length>0&&i.jsx(mg,{children:x.map(L=>i.jsx(bg,{size:"sm",iconId:L.iconId,color:S&&!p?"white":L.color,title:L.tooltip},L.id))}),b&&b.length>0&&i.jsx(Jt,{actions:b,isSelected:S,disableSelectionStyling:p})]}),i.jsx(fg,{className:"inner-container",children:i.jsx(gg,{className:"list-container",children:e})})]},k.id)}),cg=g.button`
2589
2595
  background: none;
2590
2596
  border: none;
2591
2597
  padding: 0;
@@ -2604,19 +2610,19 @@
2604
2610
  &:active {
2605
2611
  opacity: 0.5;
2606
2612
  }
2607
- `,ag=g(R)`
2613
+ `,dg=g(R)`
2608
2614
  transition: transform 0.2s ease-in-out;
2609
2615
  transform: ${({$isOpen:e})=>e?"rotate(90deg)":"rotate(0deg)"};
2610
- `,lg=g.div`
2616
+ `,ug=g.div`
2611
2617
  display: flex;
2612
2618
  align-items: center;
2613
2619
  gap: ${Me("column-gap")};
2614
2620
  flex: 1;
2615
- `,cg=g.div`
2621
+ `,hg=g.div`
2616
2622
  display: flex;
2617
2623
  flex-direction: column;
2618
2624
  ${({isOpen:e})=>e?`gap: ${Me("padding-y")}`:""}
2619
- `,dg=g.div`
2625
+ `,pg=g.div`
2620
2626
  align-items: center;
2621
2627
  gap: ${Me("column-gap")};
2622
2628
  display: flex;
@@ -2639,28 +2645,28 @@
2639
2645
  &:active {
2640
2646
  background-color: ${({$disableSelectionStyling:e})=>e?"rgba(0, 0, 0, 0.1)":Me("background-color-selected")};
2641
2647
  }
2642
- `,ug=g.div`
2648
+ `,fg=g.div`
2643
2649
  display: flex;
2644
2650
  flex-direction: column;
2645
- `,pg=g.div`
2651
+ `,gg=g.div`
2646
2652
  display: flex;
2647
2653
  flex-direction: column;
2648
2654
  row-gap: 4px;
2649
- `,hg=g.div`
2655
+ `,mg=g.div`
2650
2656
  display: flex;
2651
2657
  align-items: center;
2652
2658
  gap: 4px;
2653
2659
  padding-left: 8px;
2654
- `,fg=g(R)`
2660
+ `,bg=g(R)`
2655
2661
  opacity: 0.8;
2656
- `,gg=W.kosComponent(({children:e,className:t,...o})=>{const{openedBranches:n,toggleBranch:r}=ki(),s=n.includes(o.id),l=d.useCallback(()=>{r(o)},[o,r]);return i.jsxs(mg,{className:t,children:[i.jsxs(bg,{"data-open":s,onClick:l,children:[s?i.jsx(R,{iconId:"CaretDown",size:"xxsm"}):i.jsx(R,{iconId:"CaretRight",size:"xxsm"}),i.jsx(E,{variant:"body",bold:!0,children:o.name})]}),i.jsx(xg,{className:"inner-container",children:s?i.jsx(yg,{className:"list-container",children:e}):null})]},o.id)}),mg=g.div`
2662
+ `,xg=W.kosComponent(({children:e,className:t,...o})=>{const{openedBranches:n,toggleBranch:r}=ki(),s=n.includes(o.id),l=d.useCallback(()=>{r(o)},[o,r]);return i.jsxs(yg,{className:t,children:[i.jsxs(vg,{"data-open":s,onClick:l,children:[s?i.jsx(R,{iconId:"CaretDown",size:"xxsm"}):i.jsx(R,{iconId:"CaretRight",size:"xxsm"}),i.jsx(E,{variant:"body",bold:!0,children:o.name})]}),i.jsx(kg,{className:"inner-container",children:s?i.jsx(wg,{className:"list-container",children:e}):null})]},o.id)}),yg=g.div`
2657
2663
  display: flex;
2658
2664
  flex-direction: column;
2659
2665
 
2660
2666
  &.isNotRoot {
2661
2667
  padding-left: 12px;
2662
2668
  }
2663
- `,bg=g.div`
2669
+ `,vg=g.div`
2664
2670
  align-items: center;
2665
2671
  column-gap: 4px;
2666
2672
  cursor: pointer;
@@ -2668,90 +2674,90 @@
2668
2674
  flex: 0;
2669
2675
  min-height: 22px;
2670
2676
  padding-right: 12px;
2671
- `,xg=g.div`
2677
+ `,kg=g.div`
2672
2678
  display: flex;
2673
2679
  flex-direction: column;
2674
- `,yg=g.div`
2680
+ `,wg=g.div`
2675
2681
  display: flex;
2676
2682
  flex-direction: column;
2677
2683
  row-gap: 4px;
2678
- `,ji=d.memo(({autoScrollToBottom:e=!1,className:t,itemCount:o,itemHeight:n,onBottom:r,overscanAmount:s,renderRow:l})=>{const[a,u]=d.useState(0),[p,h]=d.useState(0),f=d.useRef(null),m=d.useRef(null),b=o*n,x=Math.ceil(p/n),y=Math.max(Math.floor(a/n-(s??0)),0),k=Math.min(o-1,y+x+(s??0)),v=C=>{u(C.currentTarget.scrollTop)};d.useLayoutEffect(()=>{const C=()=>{f.current&&h(f.current.clientHeight)};return C(),window.addEventListener("resize",C),()=>window.removeEventListener("resize",C)},[]),d.useEffect(()=>{e&&m.current&&(m.current.scrollTop=m.current.scrollHeight)},[o,e]);const $=[];for(let C=y;C<=k;C++)$.push(l(C,{top:C*n,height:n,position:"absolute",width:"100%"}));return d.useEffect(()=>{const C=()=>{const w=m.current;if(!w)return;const I=w.scrollHeight-w.scrollTop<=w.clientHeight+n;!e&&I&&(r==null||r())},S=m.current;return S&&S.addEventListener("scroll",C),()=>{S&&S.removeEventListener("scroll",C)}},[e,n,r]),i.jsx(vg,{ref:f,children:i.jsx(kg,{ref:m,style:{height:p},onScroll:v,className:t,children:i.jsx(wg,{style:{height:b},children:$})})})}),vg=g.div`
2684
+ `,ji=d.memo(({autoScrollToBottom:e=!1,className:t,itemCount:o,itemHeight:n,onBottom:r,overscanAmount:s,renderRow:l})=>{const[a,u]=d.useState(0),[h,p]=d.useState(0),f=d.useRef(null),m=d.useRef(null),b=o*n,x=Math.ceil(h/n),y=Math.max(Math.floor(a/n-(s??0)),0),k=Math.min(o-1,y+x+(s??0)),v=C=>{u(C.currentTarget.scrollTop)};d.useLayoutEffect(()=>{const C=()=>{f.current&&p(f.current.clientHeight)};return C(),window.addEventListener("resize",C),()=>window.removeEventListener("resize",C)},[]),d.useEffect(()=>{e&&m.current&&(m.current.scrollTop=m.current.scrollHeight)},[o,e]);const $=[];for(let C=y;C<=k;C++)$.push(l(C,{top:C*n,height:n,position:"absolute",width:"100%"}));return d.useEffect(()=>{const C=()=>{const w=m.current;if(!w)return;const I=w.scrollHeight-w.scrollTop<=w.clientHeight+n;!e&&I&&(r==null||r())},S=m.current;return S&&S.addEventListener("scroll",C),()=>{S&&S.removeEventListener("scroll",C)}},[e,n,r]),i.jsx(Cg,{ref:f,children:i.jsx($g,{ref:m,style:{height:h},onScroll:v,className:t,children:i.jsx(Sg,{style:{height:b},children:$})})})}),Cg=g.div`
2679
2685
  height: 100%;
2680
2686
  width: 100%;
2681
2687
  overflow-y: hidden;
2682
2688
  position: relative;
2683
- `,kg=g.div`
2689
+ `,$g=g.div`
2684
2690
  overflow-y: auto;
2685
2691
  width: 100%;
2686
2692
  position: relative;
2687
- `,wg=g.div`
2693
+ `,Sg=g.div`
2688
2694
  position: relative;
2689
2695
  width: 100%;
2690
- `,Ii=W.kosComponent(({dataProvider:e,ItemTemplate:t,onListItemAction:o,onInit:n,emptyState:r,...s})=>{const l=Xt(e,n),a=d.useCallback((u,p)=>{const h=e==null?void 0:e.items.find((f,m)=>m===u);if(h){const f=Yt(t)?t.build(h):t;return i.jsx(f,{"data-key":h.id,style:p,...h,onListItemAction:o},h.id)}return null},[t,e==null?void 0:e.items,o]);return i.jsx(Bn,{dataProvider:e||void 0,onListItemAction:o,children:l?(e==null?void 0:e.items.length)===0&&r?r:i.jsx(ji,{itemCount:(e==null?void 0:e.items.length)??0,renderRow:a,...s}):null})}),Cg=W.kosComponent(({isSingleSelect:e=!0,onSelect:t,selected:o,disabled:n,autoSelectFirstItem:r,dataProvider:s,getFirstItem:l,...a})=>{const[u,p]=d.useState(o??[]),h=d.useRef(u??[]);d.useLayoutEffect(()=>{h.current=u},[u]),d.useEffect(()=>{p(o??[])},[o]);const f=d.useCallback(x=>{t(x,h.current.includes(x)?"unselected":"selected"),p(y=>e?[x]:y.includes(x)?y.filter(k=>k!==x):[...y,x])},[e,t]),m=d.useCallback(x=>h.current.includes(x),[]),b=d.useMemo(()=>({isSelected:m,selected:u,toggleSelection:f,isDisabled:!!n}),[m,u,f,n]);return d.useEffect(()=>{var x,y;if(r&&(s!=null&&s.items)&&h.current.length===0){let k;l?k=(x=l(s.items))==null?void 0:x.id:k=(y=s.items[0])==null?void 0:y.id,k&&f(k)}},[r,s==null?void 0:s.items,l,f]),i.jsx(mt.Provider,{value:b,children:i.jsx(Ii,{dataProvider:s,...a})})}),[we]=M(["modal"]),Di=g.div`
2696
+ `,Ii=W.kosComponent(({dataProvider:e,ItemTemplate:t,onListItemAction:o,onInit:n,emptyState:r,...s})=>{const l=Xt(e,n),a=d.useCallback((u,h)=>{const p=e==null?void 0:e.items.find((f,m)=>m===u);if(p){const f=Yt(t)?t.build(p):t;return i.jsx(f,{"data-key":p.id,style:h,...p,onListItemAction:o},p.id)}return null},[t,e==null?void 0:e.items,o]);return i.jsx(Bn,{dataProvider:e||void 0,onListItemAction:o,children:l?(e==null?void 0:e.items.length)===0&&r?r:i.jsx(ji,{itemCount:(e==null?void 0:e.items.length)??0,renderRow:a,...s}):null})}),jg=W.kosComponent(({isSingleSelect:e=!0,onSelect:t,selected:o,disabled:n,autoSelectFirstItem:r,dataProvider:s,getFirstItem:l,...a})=>{const[u,h]=d.useState(o??[]),p=d.useRef(u??[]);d.useLayoutEffect(()=>{p.current=u},[u]),d.useEffect(()=>{h(o??[])},[o]);const f=d.useCallback(x=>{t(x,p.current.includes(x)?"unselected":"selected"),h(y=>e?[x]:y.includes(x)?y.filter(k=>k!==x):[...y,x])},[e,t]),m=d.useCallback(x=>p.current.includes(x),[]),b=d.useMemo(()=>({isSelected:m,selected:u,toggleSelection:f,isDisabled:!!n}),[m,u,f,n]);return d.useEffect(()=>{var x,y;if(r&&(s!=null&&s.items)&&p.current.length===0){let k;l?k=(x=l(s.items))==null?void 0:x.id:k=(y=s.items[0])==null?void 0:y.id,k&&f(k)}},[r,s==null?void 0:s.items,l,f]),i.jsx(mt.Provider,{value:b,children:i.jsx(Ii,{dataProvider:s,...a})})}),[Ce]=M(["modal"]),Di=g.div`
2691
2697
  width: fit-content;
2692
2698
  height: fit-content;
2693
2699
  display: flex;
2694
2700
  align-items: flex-start;
2695
2701
  justify-content: flex-start;
2696
2702
  flex-direction: column;
2697
- background-color: ${we("background-color")};
2703
+ background-color: ${Ce("background-color")};
2698
2704
  `,_i=g.div`
2699
- padding: ${we("headerPadding")};
2700
- column-gap: ${we("headerGap")};
2705
+ padding: ${Ce("headerPadding")};
2706
+ column-gap: ${Ce("headerGap")};
2701
2707
  width: 100%;
2702
2708
  display: flex;
2703
2709
  align-items: center;
2704
2710
  justify-content: flex-start;
2705
- border-bottom: ${we("border-width")} solid ${we("border-color")};
2711
+ border-bottom: ${Ce("border-width")} solid ${Ce("border-color")};
2706
2712
  `,Ti=g.div`
2707
- padding: ${we("contentYPadding")} ${we("contentXPadding")};
2713
+ padding: ${Ce("contentYPadding")} ${Ce("contentXPadding")};
2708
2714
  width: fit-content;
2709
2715
  `,Gn=g.div`
2710
- padding: ${we("footerYPadding")} ${we("footerXPadding")};
2711
- border-top: ${we("border-width")} solid ${we("border-color")};
2716
+ padding: ${Ce("footerYPadding")} ${Ce("footerXPadding")};
2717
+ border-top: ${Ce("border-width")} solid ${Ce("border-color")};
2712
2718
  width: 100%;
2713
2719
  display: flex;
2714
2720
  align-items: center;
2715
2721
  justify-content: flex-end;
2716
- `,$g=g.div`
2717
- width: ${we("base-content-width")};
2722
+ `,Ig=g.div`
2723
+ width: ${Ce("base-content-width")};
2718
2724
  display: flex;
2719
2725
  align-items: flex-start;
2720
2726
  justify-content: flex-start;
2721
2727
  flex-direction: column;
2722
- `,jo=d.forwardRef(({header:e,footer:t,content:o,footerWrapper:n,headerWrapper:r,contentWrapper:s},l)=>{const a=r??_i,u=s??Ti,p=n??Gn;return i.jsxs(Di,{ref:l,children:[i.jsx(a,{children:e}),i.jsx(u,{children:o}),i.jsx(p,{children:t})]})}),Sg=d.forwardRef(({level:e,headerText:t,content:o,acceptButtonVariant:n,acceptButtonText:r,onAccept:s},l)=>{const a=d.useMemo(()=>{if(e==="error")return{iconId:"ExclamationCircle",color:"red"};if(e==="warn")return{iconId:"Warning",color:"orange"};if(e==="success")return{iconId:"CheckCircle",color:"green"};if(e==="info")return{iconId:"InfoCircle",color:"blue"}},[e]),{setOpen:u}=nt(),p=d.useCallback(()=>{s&&s(),u(!1)},[u,s]);return i.jsx(jo,{ref:l,header:i.jsxs(i.Fragment,{children:[!!a&&i.jsx(R,{iconId:a.iconId,color:a.color}),i.jsx(E,{variant:"h2",color:"dark",children:t})]}),content:o,footer:i.jsx(Ge,{onClick:p,variant:n??"primary",text:r??"Okay"})})}),[jg]=M(["modal"]),Ig=d.forwardRef(({onConfirm:e,onCancel:t,headerText:o,confirmText:n,cancelText:r,content:s,confirmButtonVariant:l,cancelButtonVariant:a,confirmDisabled:u,headerIcon:p,headerIconColor:h,contentWrapper:f,cancelDisabled:m},b)=>{const{setOpen:x}=nt(),y=d.useCallback(()=>{e(()=>x(!1))},[e,x]),k=d.useCallback(()=>{t&&t(),x(!1)},[t,x]);return i.jsx(jo,{ref:b,header:i.jsxs(i.Fragment,{children:[!!p&&i.jsx(R,{iconId:p,color:h??"black"}),i.jsx(E,{variant:"h2",color:"dark",children:o})]}),contentWrapper:f,content:s,footerWrapper:Dg,footer:i.jsxs(i.Fragment,{children:[i.jsx(Ge,{text:r??"Cancel",onClick:k,disabled:m,variant:a??"borderless"}),i.jsx(Ge,{onClick:y,variant:l??"primary",text:n??"Confirm",disabled:u})]})})}),Dg=g(Gn)`
2723
- column-gap: ${jg("footerGap")};
2724
- `,_g=d.memo(({headerText:e})=>i.jsxs(i.Fragment,{children:[i.jsx(R,{iconId:"ExclamationCircle",color:"red",size:"lrg"}),i.jsx(E,{variant:"h2",color:"dark",children:e})]})),Tg=d.memo(({contentText:e,compareText:t,errorText:o})=>{const n=d.useCallback(s=>s.message&&s.message!==""?s.message:o??"That does not match.",[o]),r=d.useCallback(s=>s===t,[t]);return i.jsxs(Eg,{children:[i.jsx(E,{variant:"body",color:"dark",children:e}),i.jsx(Mn,{name:"matchText",handleError:n,validate:r})]})}),Eg=g.div`
2728
+ `,jo=d.forwardRef(({header:e,footer:t,content:o,footerWrapper:n,headerWrapper:r,contentWrapper:s},l)=>{const a=r??_i,u=s??Ti,h=n??Gn;return i.jsxs(Di,{ref:l,children:[i.jsx(a,{children:e}),i.jsx(u,{children:o}),i.jsx(h,{children:t})]})}),Dg=d.forwardRef(({level:e,headerText:t,content:o,acceptButtonVariant:n,acceptButtonText:r,onAccept:s},l)=>{const a=d.useMemo(()=>{if(e==="error")return{iconId:"ExclamationCircle",color:"red"};if(e==="warn")return{iconId:"Warning",color:"orange"};if(e==="success")return{iconId:"CheckCircle",color:"green"};if(e==="info")return{iconId:"InfoCircle",color:"blue"}},[e]),{setOpen:u}=rt(),h=d.useCallback(()=>{s&&s(),u(!1)},[u,s]);return i.jsx(jo,{ref:l,header:i.jsxs(i.Fragment,{children:[!!a&&i.jsx(R,{iconId:a.iconId,color:a.color}),i.jsx(E,{variant:"h2",color:"dark",children:t})]}),content:o,footer:i.jsx(Ke,{onClick:h,variant:n??"primary",text:r??"Okay"})})}),[_g]=M(["modal"]),Tg=d.forwardRef(({onConfirm:e,onCancel:t,headerText:o,confirmText:n,cancelText:r,content:s,confirmButtonVariant:l,cancelButtonVariant:a,confirmDisabled:u,headerIcon:h,headerIconColor:p,contentWrapper:f,cancelDisabled:m},b)=>{const{setOpen:x}=rt(),y=d.useCallback(()=>{e(()=>x(!1))},[e,x]),k=d.useCallback(()=>{t&&t(),x(!1)},[t,x]);return i.jsx(jo,{ref:b,header:i.jsxs(i.Fragment,{children:[!!h&&i.jsx(R,{iconId:h,color:p??"black"}),i.jsx(E,{variant:"h2",color:"dark",children:o})]}),contentWrapper:f,content:s,footerWrapper:Eg,footer:i.jsxs(i.Fragment,{children:[i.jsx(Ke,{text:r??"Cancel",onClick:k,disabled:m,variant:a??"borderless"}),i.jsx(Ke,{onClick:y,variant:l??"primary",text:n??"Confirm",disabled:u})]})})}),Eg=g(Gn)`
2729
+ column-gap: ${_g("footerGap")};
2730
+ `,zg=d.memo(({headerText:e})=>i.jsxs(i.Fragment,{children:[i.jsx(R,{iconId:"ExclamationCircle",color:"red",size:"lrg"}),i.jsx(E,{variant:"h2",color:"dark",children:e})]})),Mg=d.memo(({contentText:e,compareText:t,errorText:o})=>{const n=d.useCallback(s=>s.message&&s.message!==""?s.message:o??"That does not match.",[o]),r=d.useCallback(s=>s===t,[t]);return i.jsxs(Og,{children:[i.jsx(E,{variant:"body",color:"dark",children:e}),i.jsx(Mn,{name:"matchText",handleError:n,validate:r})]})}),Og=g.div`
2725
2731
  width: 288px;
2726
2732
  display: flex;
2727
2733
  align-items: flex-start;
2728
2734
  justify-content: flex-start;
2729
2735
  flex-direction: column;
2730
2736
  row-gap: 8px;
2731
- `,zg=d.memo(({onSubmit:e})=>{const{setOpen:t}=nt(),o=d.useCallback(()=>{t(!1)},[t]);return i.jsxs(i.Fragment,{children:[i.jsx(Ge,{type:"button",text:"Cancel",onClick:o,variant:"borderless"}),i.jsx(zn,{onSubmit:e,variant:"primary",text:"Delete"})]})}),Mg={matchText:""},Og=d.forwardRef(({compareText:e,headerText:t,contentText:o,errorText:n,onConfirm:r},s)=>{const{setOpen:l}=nt(),a=d.useCallback((u,p)=>{r(u,()=>l(!1),p)},[r,l]);return i.jsx(Rg,{onSubmit:a,mode:"onChange",delayError:400,defaultValues:Mg,children:i.jsx(jo,{ref:s,header:i.jsx(_g,{headerText:t}),content:i.jsx(Tg,{compareText:e,contentText:o,errorText:n}),footer:i.jsx(zg,{onSubmit:a})})})}),Rg=g(Qs)`
2737
+ `,Rg=d.memo(({onSubmit:e})=>{const{setOpen:t}=rt(),o=d.useCallback(()=>{t(!1)},[t]);return i.jsxs(i.Fragment,{children:[i.jsx(Ke,{type:"button",text:"Cancel",onClick:o,variant:"borderless"}),i.jsx(zn,{onSubmit:e,variant:"primary",text:"Delete"})]})}),Ng={matchText:""},Fg=d.forwardRef(({compareText:e,headerText:t,contentText:o,errorText:n,onConfirm:r},s)=>{const{setOpen:l}=rt(),a=d.useCallback((u,h)=>{r(u,()=>l(!1),h)},[r,l]);return i.jsx(Ag,{onSubmit:a,mode:"onChange",delayError:400,defaultValues:Ng,children:i.jsx(jo,{ref:s,header:i.jsx(zg,{headerText:t}),content:i.jsx(Mg,{compareText:e,contentText:o,errorText:n}),footer:i.jsx(Rg,{onSubmit:a})})})}),Ag=g(Qs)`
2732
2738
  height: fit-content;
2733
2739
  width: fit-content;
2734
- `,Ng=({className:e,defaultValues:t,header:o,submitText:n,cancelText:r,onCancel:s,enabledIfClean:l,onSubmit:a,content:u,submitButtonVariant:p,cancelButtonVariant:h,variant:f="submit",ContentWrapper:m,disabled:b,...x},y)=>{const k=q.useForm({shouldUnregister:!0,defaultValues:t,disabled:b,...x,mode:f==="blur"?"onBlur":x.mode}),{setOpen:v}=nt(),{setError:$,reset:C}=k,S=d.useCallback(D=>{a({data:D,closeModal:()=>v(!1),setError:$,resetForm:C})},[a,C,$,v]),w=d.useCallback(()=>{s==null||s(C),v(!1)},[s,C,v]),I=d.useCallback(D=>S(D),[S]),j=m??Ti;return i.jsx(q.FormProvider,{...k,children:i.jsxs(Di,{ref:y,as:"form",className:e,onSubmit:f==="blur"?void 0:k.handleSubmit(S),onBlur:f==="blur"?k.handleSubmit(S):void 0,children:[i.jsx(_i,{children:o}),i.jsx(j,{children:u}),i.jsxs(Gn,{children:[i.jsx(Ge,{text:r??"Cancel",onClick:w,type:"button",variant:h??"borderless"}),f!=="blur"&&i.jsx(zn,{onSubmit:I,variant:p??"primary",text:n??"Submit",enabledIfClean:l,disabled:b})]})]})})},Fg=It(Ng),[Ag]=M(["modal"]),Lg={escapeKey:!0,outsidePress:!1,bubbles:!1};function Bg(e){const{type:t,open:o,defaultOpen:n,onOpenChange:r,children:s,initialFocus:l,...a}=e,u=t==="confirm"?Ig:t==="status"?Sg:t==="confirm-delete"?Og:t==="form"?Fg:jo;return i.jsxs(gn,{dismissOptions:Lg,open:o,defaultOpen:n,onOpenChange:r,children:[i.jsx(bn,{initialFocus:l,OverlayStyles:Ei,trapFocus:!0,children:i.jsx(u,{...a})}),!!s&&s]})}const Wg=({children:e})=>i.jsx(mn,{children:e}),Ei=z.css`
2735
- background: ${Ag("overlay-background")};
2740
+ `,Lg=({className:e,defaultValues:t,header:o,submitText:n,cancelText:r,onCancel:s,enabledIfClean:l,onSubmit:a,content:u,submitButtonVariant:h,cancelButtonVariant:p,variant:f="submit",ContentWrapper:m,disabled:b,...x},y)=>{const k=G.useForm({shouldUnregister:!0,defaultValues:t,disabled:b,...x,mode:f==="blur"?"onBlur":x.mode}),{setOpen:v}=rt(),{setError:$,reset:C}=k,S=d.useCallback(D=>{a({data:D,closeModal:()=>v(!1),setError:$,resetForm:C})},[a,C,$,v]),w=d.useCallback(()=>{s==null||s(C),v(!1)},[s,C,v]),I=d.useCallback(D=>S(D),[S]),j=m??Ti;return i.jsx(G.FormProvider,{...k,children:i.jsxs(Di,{ref:y,as:"form",className:e,onSubmit:f==="blur"?void 0:k.handleSubmit(S),onBlur:f==="blur"?k.handleSubmit(S):void 0,children:[i.jsx(_i,{children:o}),i.jsx(j,{children:u}),i.jsxs(Gn,{children:[i.jsx(Ke,{text:r??"Cancel",onClick:w,type:"button",variant:p??"borderless"}),f!=="blur"&&i.jsx(zn,{onSubmit:I,variant:h??"primary",text:n??"Submit",enabledIfClean:l,disabled:b})]})]})})},Bg=It(Lg),[Wg]=M(["modal"]),Pg={escapeKey:!0,outsidePress:!1,bubbles:!1};function Vg(e){const{type:t,open:o,defaultOpen:n,onOpenChange:r,children:s,initialFocus:l,...a}=e,u=t==="confirm"?Tg:t==="status"?Dg:t==="confirm-delete"?Fg:t==="form"?Bg:jo;return i.jsxs(gn,{dismissOptions:Pg,open:o,defaultOpen:n,onOpenChange:r,children:[i.jsx(bn,{initialFocus:l,OverlayStyles:Ei,trapFocus:!0,children:i.jsx(u,{...a})}),!!s&&s]})}const Hg=({children:e})=>i.jsx(mn,{children:e}),Ei=z.css`
2741
+ background: ${Wg("overlay-background")};
2736
2742
  display: grid;
2737
2743
  place-items: center;
2738
2744
  z-index: 2;
2739
- `,[ht]=M(["named-section-header"]),zi=g.div`
2745
+ `,[pt]=M(["named-section-header"]),zi=g.div`
2740
2746
  align-items: flex-start;
2741
- background-color: ${ht("bg")};
2742
- border-bottom: ${ht("border-width")} solid ${ht("border-color")};
2743
- border-radius: ${ht("border-radius")} ${ht("border-radius")} 0px 0px;
2747
+ background-color: ${pt("bg")};
2748
+ border-bottom: ${pt("border-width")} solid ${pt("border-color")};
2749
+ border-radius: ${pt("border-radius")} ${pt("border-radius")} 0px 0px;
2744
2750
  display: flex;
2745
- padding: ${ht("padding")};
2746
- column-gap: ${ht("gap")};
2751
+ padding: ${pt("padding")};
2752
+ column-gap: ${pt("gap")};
2747
2753
  &.isCollapsed {
2748
2754
  border-bottom-width: 0px;
2749
2755
  }
2750
- `,Pg=d.memo(({children:e})=>{const{setOpen:t,open:o}=qt(),n=d.useCallback(r=>{r.stopPropagation(),t(!o)},[o,t]);return i.jsxs(zi,{className:Dt("header-wrapper",{isCollapsed:o}),children:[i.jsx(ae,{iconId:o?"CaretDown":"CaretUp",onClick:n,size:"xsm",color:"black"}),e]})}),[Je]=M(["named-section"]),Vg=e=>e.variant==="selectable",Mi=e=>{const{variant:t,className:o,children:n,header:r,isCollapsible:s}=e,l=d.useRef(null),[a,u,p]=Vg(e)?[e.disabled,e.isSelected,e.onClick]:[e.disabled,!1,void 0],h=e.ContentWrapper??Ug,f=d.useCallback(m=>{p&&l.current&&l.current.contains(m.target)&&p()},[p]);return i.jsx(z.ClassNames,{children:({cx:m})=>i.jsx(Hg,{"data-variant":t,className:m(o,{disabled:a,isSelected:u}),onClick:f,ref:l,children:s?i.jsxs(go,{defaultOpen:!0,children:[i.jsx(Pg,{children:r}),i.jsx(mo,{children:i.jsx(h,{children:n})})]}):i.jsxs(i.Fragment,{children:[i.jsx(zi,{className:"header-wrapper",children:r}),i.jsx(h,{children:n})]})})})},Hg=g.div`
2751
- border-color: ${Je("border-color")};
2752
- border-radius: ${Je("border-radius")};
2756
+ `,Ug=d.memo(({children:e})=>{const{setOpen:t,open:o}=qt(),n=d.useCallback(r=>{r.stopPropagation(),t(!o)},[o,t]);return i.jsxs(zi,{className:Dt("header-wrapper",{isCollapsed:o}),children:[i.jsx(ae,{iconId:o?"CaretDown":"CaretUp",onClick:n,size:"xsm",color:"black"}),e]})}),[Qe]=M(["named-section"]),Gg=e=>e.variant==="selectable",Mi=e=>{const{variant:t,className:o,children:n,header:r,isCollapsible:s}=e,l=d.useRef(null),[a,u,h]=Gg(e)?[e.disabled,e.isSelected,e.onClick]:[e.disabled,!1,void 0],p=e.ContentWrapper??Yg,f=d.useCallback(m=>{h&&l.current&&l.current.contains(m.target)&&h()},[h]);return i.jsx(z.ClassNames,{children:({cx:m})=>i.jsx(Kg,{"data-variant":t,className:m(o,{disabled:a,isSelected:u}),onClick:f,ref:l,children:s?i.jsxs(go,{defaultOpen:!0,children:[i.jsx(Ug,{children:r}),i.jsx(mo,{children:i.jsx(p,{children:n})})]}):i.jsxs(i.Fragment,{children:[i.jsx(zi,{className:"header-wrapper",children:r}),i.jsx(p,{children:n})]})})})},Kg=g.div`
2757
+ border-color: ${Qe("border-color")};
2758
+ border-radius: ${Qe("border-radius")};
2753
2759
  border-style: solid;
2754
- border-width: ${Je("border-width")};
2760
+ border-width: ${Qe("border-width")};
2755
2761
  display: flex;
2756
2762
  flex-direction: column;
2757
2763
  width: 100%;
@@ -2761,19 +2767,19 @@
2761
2767
  }
2762
2768
  &[data-variant="selectable"] {
2763
2769
  &.isSelected {
2764
- outline-color: ${Je("selected-border-color")};
2765
- outline-width: ${Je("selected-border-width")};
2766
- outline-offset: calc(-1.5 * ${Je("selected-border-width")});
2770
+ outline-color: ${Qe("selected-border-color")};
2771
+ outline-width: ${Qe("selected-border-width")};
2772
+ outline-offset: calc(-1.5 * ${Qe("selected-border-width")});
2767
2773
  }
2768
2774
  cursor: pointer;
2769
2775
  outline-color: transparent;
2770
- outline-offset: calc(-1.5 * ${Je("hover-border-width")});
2776
+ outline-offset: calc(-1.5 * ${Qe("hover-border-width")});
2771
2777
  outline-style: solid;
2772
- outline-width: ${Je("hover-border-width")};
2778
+ outline-width: ${Qe("hover-border-width")};
2773
2779
 
2774
2780
  &:hover {
2775
2781
  opacity: 1;
2776
- outline-color: ${Je("selected-border-color")};
2782
+ outline-color: ${Qe("selected-border-color")};
2777
2783
  }
2778
2784
  }
2779
2785
  &[data-variant="scrollable"] {
@@ -2783,10 +2789,10 @@
2783
2789
  top: 0;
2784
2790
  }
2785
2791
  }
2786
- `,Ug=g.div`
2792
+ `,Yg=g.div`
2787
2793
  display: flex;
2788
2794
  width: 100%;
2789
- `,[Io]=M(["named-section-header"]),Gg=d.memo(({name:e,description:t,prefix:o,suffix:n,children:r,...s})=>i.jsxs(Kg,{...s,className:t?"hasDesc":void 0,children:[i.jsxs(Yg,{children:[i.jsxs(qg,{children:[o,i.jsx(E,{color:"dark",bold:!0,variant:"body",children:e}),n]}),!!t&&i.jsx(E,{color:"grey",variant:"small",children:t})]}),!!r&&i.jsx(Zg,{children:r})]})),Kg=g.div`
2795
+ `,[Io]=M(["named-section-header"]),qg=d.memo(({name:e,description:t,prefix:o,suffix:n,children:r,...s})=>i.jsxs(Zg,{...s,className:t?"hasDesc":void 0,children:[i.jsxs(Xg,{children:[i.jsxs(Jg,{children:[o,i.jsx(E,{color:"dark",bold:!0,variant:"body",children:e}),n]}),!!t&&i.jsx(E,{color:"grey",variant:"small",children:t})]}),!!r&&i.jsx(Qg,{children:r})]})),Zg=g.div`
2790
2796
  width: 100%;
2791
2797
  display: flex;
2792
2798
  align-items: center;
@@ -2795,55 +2801,55 @@
2795
2801
  &.hasDesc {
2796
2802
  align-items: flex-start;
2797
2803
  }
2798
- `,Yg=g.div`
2804
+ `,Xg=g.div`
2799
2805
  display: flex;
2800
2806
  align-items: flex-start;
2801
2807
  justify-content: center;
2802
2808
  flex-direction: column;
2803
2809
  row-gap: ${Io("row-gap")};
2804
- `,qg=g.div`
2810
+ `,Jg=g.div`
2805
2811
  display: flex;
2806
2812
  align-items: center;
2807
2813
  justify-content: flex-start;
2808
2814
  column-gap: ${Io("row-gap")};
2809
- `,Zg=g.div`
2815
+ `,Qg=g.div`
2810
2816
  display: flex;
2811
2817
  align-items: center;
2812
2818
  justify-content: flex-end;
2813
2819
  row-gap: ${Io("row-gap")};
2814
- `,[lo]=M(["image-config-page-header"]),Xg=e=>e?Array.isArray(e)?e.map(t=>i.jsx(ho,{color:"light",children:t},t)):i.jsx(ho,{color:"light",children:e}):null,Jg=({action:e,description:t,title:o,titleTag:n,subTitle:r,...s})=>i.jsxs(Qg,{...s,children:[i.jsxs(tm,{children:[i.jsxs(em,{children:[i.jsx(E,{variant:"h1",children:o}),Xg(n)]}),t&&i.jsx(E,{variant:"body",color:"grey",children:t}),r&&i.jsx(E,{variant:"body",color:"dark",children:r})]}),e]}),Qg=g.div`
2820
+ `,[lo]=M(["image-config-page-header"]),em=e=>e?Array.isArray(e)?e.map(t=>i.jsx(po,{color:"light",children:t},t)):i.jsx(po,{color:"light",children:e}):null,tm=({action:e,description:t,title:o,titleTag:n,subTitle:r,...s})=>i.jsxs(om,{...s,children:[i.jsxs(rm,{children:[i.jsxs(nm,{children:[i.jsx(E,{variant:"h1",children:o}),em(n)]}),t&&i.jsx(E,{variant:"body",color:"grey",children:t}),r&&i.jsx(E,{variant:"body",color:"dark",children:r})]}),e]}),om=g.div`
2815
2821
  align-items: center;
2816
2822
  background: ${lo("bg")};
2817
2823
  display: flex;
2818
2824
  gap: ${lo("gap")};
2819
2825
  padding: 0 0 ${lo("padding-bottom")} 0;
2820
2826
  width: 100%;
2821
- `,em=g.div`
2827
+ `,nm=g.div`
2822
2828
  width: 100%;
2823
2829
  display: flex;
2824
2830
  align-items: center;
2825
2831
  column-gap: ${c("spacing-8")};
2826
2832
  justify-content: flex-start;
2827
- `,tm=g.div`
2833
+ `,rm=g.div`
2828
2834
  display: flex;
2829
2835
  flex-direction: column;
2830
2836
  flex: 1;
2831
2837
  gap: ${lo("title-gap")};
2832
- `,Oi=d.createContext(null),om=()=>{const e=d.useContext(Oi);if(e===null)throw new Error("Unable to use SelectViewListContext outside of its provider.");return e};function nm(e){if(e=typeof e=="number"?e:parseInt(e),e===0)return"0.00 B";const t=Math.floor(Math.log(e)/Math.log(1024));return(e/Math.pow(1024,t)).toFixed(2)+" "+" KMGTP".charAt(t)+"B"}const sn=new IntersectionObserver(([e])=>{const t=e.boundingClientRect.top-e.intersectionRect.top<0,o=e.boundingClientRect.bottom-e.intersectionRect.bottom>0;e.target.classList.toggle("isStuckTop",t),e.target.classList.toggle("isStuckBottom",o)},{threshold:[1]}),rm=(e,t)=>{if(e==="\\"||e==="/")return"/";if(e.length<=1)return e;const n=e.replace(/\\/g,"/").split(/[/\\]+/);return t!==!1&&n[n.length-1]===""&&n.pop(),n.join("/")},[he]=M(["select-view-list"]),Ri=d.memo(({id:e,name:t,icon:o,onListItemAction:n,isSelectDisabled:r})=>{const{selected:s,viewing:l}=om(),a=d.useRef(null),u=d.useRef(null),p=d.useRef(!1),h=s===e,f=l===e;d.useEffect(()=>{u.current&&(h?(sn.observe(u.current),p.current=!0):p.current&&(p.current=!1,sn.unobserve(u.current)))},[h]);const m=d.useCallback(()=>{n==null||n(e,"select")},[n,e]),b=d.useCallback(x=>{a.current&&a.current.contains(x.target)||n==null||n(e,"view")},[e,n]);return i.jsx(z.ClassNames,{children:({cx:x})=>i.jsx(sm,{ref:u,className:x({isSelected:h}),onClick:b,children:i.jsxs(im,{className:x({isViewing:f}),children:[i.jsx(kn,{ref:a,checked:h,disabled:r,onChange:m}),i.jsxs(am,{color:"dark",bold:h,variant:"body",children:[t,o]}),i.jsx(R,{iconId:"Right",color:"blue",size:"sm"})]})})})}),sm=g.div`
2838
+ `,Oi=d.createContext(null),sm=()=>{const e=d.useContext(Oi);if(e===null)throw new Error("Unable to use SelectViewListContext outside of its provider.");return e};function im(e){if(e=typeof e=="number"?e:parseInt(e),e===0)return"0.00 B";const t=Math.floor(Math.log(e)/Math.log(1024));return(e/Math.pow(1024,t)).toFixed(2)+" "+" KMGTP".charAt(t)+"B"}const sn=new IntersectionObserver(([e])=>{const t=e.boundingClientRect.top-e.intersectionRect.top<0,o=e.boundingClientRect.bottom-e.intersectionRect.bottom>0;e.target.classList.toggle("isStuckTop",t),e.target.classList.toggle("isStuckBottom",o)},{threshold:[1]}),am=(e,t)=>{if(e==="\\"||e==="/")return"/";if(e.length<=1)return e;const n=e.replace(/\\/g,"/").split(/[/\\]+/);return t!==!1&&n[n.length-1]===""&&n.pop(),n.join("/")},[pe]=M(["select-view-list"]),Ri=d.memo(({id:e,name:t,icon:o,onListItemAction:n,isSelectDisabled:r})=>{const{selected:s,viewing:l}=sm(),a=d.useRef(null),u=d.useRef(null),h=d.useRef(!1),p=s===e,f=l===e;d.useEffect(()=>{u.current&&(p?(sn.observe(u.current),h.current=!0):h.current&&(h.current=!1,sn.unobserve(u.current)))},[p]);const m=d.useCallback(()=>{n==null||n(e,"select")},[n,e]),b=d.useCallback(x=>{a.current&&a.current.contains(x.target)||n==null||n(e,"view")},[e,n]);return i.jsx(z.ClassNames,{children:({cx:x})=>i.jsx(lm,{ref:u,className:x({isSelected:p}),onClick:b,children:i.jsxs(cm,{className:x({isViewing:f}),children:[i.jsx(kn,{ref:a,checked:p,disabled:r,onChange:m}),i.jsxs(dm,{color:"dark",bold:p,variant:"body",children:[t,o]}),i.jsx(R,{iconId:"Right",color:"blue",size:"sm"})]})})})}),lm=g.div`
2833
2839
  width: 100%;
2834
2840
  display: flex;
2835
2841
  height: auto;
2836
2842
  flex-shrink: 0;
2837
2843
  align-items: center;
2838
2844
  justify-content: flex-start;
2839
- border-bottom: ${he("border-width")} solid ${he("border-color")};
2845
+ border-bottom: ${pe("border-width")} solid ${pe("border-color")};
2840
2846
 
2841
2847
  &:first-of-type {
2842
- border-top-color: ${he("border-color")};
2848
+ border-top-color: ${pe("border-color")};
2843
2849
  }
2844
2850
 
2845
2851
  :not(:first-of-type):not(.isStuckBottom):has(div.isViewing) {
2846
- border-top-color: ${he("background-color-viewing")};
2852
+ border-top-color: ${pe("background-color-viewing")};
2847
2853
  }
2848
2854
 
2849
2855
  &.isSelected {
@@ -2854,38 +2860,38 @@
2854
2860
 
2855
2861
  &.isStuckBottom {
2856
2862
  box-shadow: 0px -6px 5px 0px rgba(0, 0, 0, 0.04);
2857
- border-top: ${he("border-width")} solid ${he("background-color")};
2858
- border-top-color: ${he("border-color")};
2863
+ border-top: ${pe("border-width")} solid ${pe("background-color")};
2864
+ border-top-color: ${pe("border-color")};
2859
2865
  }
2860
2866
 
2861
2867
  &.isStuckTop {
2862
2868
  box-shadow: 0px 6px 5px 0px rgba(0, 0, 0, 0.04);
2863
2869
  }
2864
- `,im=g.div`
2870
+ `,cm=g.div`
2865
2871
  width: 100%;
2866
2872
  display: flex;
2867
2873
  flex-shrink: 0;
2868
2874
  align-items: center;
2869
2875
  justify-content: flex-start;
2870
- height: ${he("item-height")};
2871
- padding-left: ${he("padding-left")};
2872
- padding-right: ${he("padding-right")};
2873
- background-color: ${he("background-color")};
2876
+ height: ${pe("item-height")};
2877
+ padding-left: ${pe("padding-left")};
2878
+ padding-right: ${pe("padding-right")};
2879
+ background-color: ${pe("background-color")};
2874
2880
  transition: background 0.125s ease-in-out;
2875
2881
  &.isViewing {
2876
- background-color: ${he("background-color-viewing")};
2882
+ background-color: ${pe("background-color-viewing")};
2877
2883
  }
2878
- `,am=g(E)`
2884
+ `,dm=g(E)`
2879
2885
  flex: 1;
2880
2886
  overflow: hidden;
2881
2887
  text-overflow: ellipsis;
2882
2888
  white-space: nowrap;
2883
- padding-left: ${he("padding-left")};
2884
- padding-right: ${he("padding-right")};
2885
- gap: ${he("gap")};
2889
+ padding-left: ${pe("padding-left")};
2890
+ padding-right: ${pe("padding-right")};
2891
+ gap: ${pe("gap")};
2886
2892
  align-items: center;
2887
2893
  display: flex;
2888
- `,lm=({className:e,dp:t,emptyState:o,firstChild:n,lastChild:r,onListItemAction:s,selected:l,viewing:a})=>{const u=d.useMemo(()=>({selected:l,viewing:a}),[l,a]);return i.jsx(Oi.Provider,{value:u,children:i.jsx(cm,{className:e,dataProvider:t,emptyState:o,firstChild:n,ItemTemplate:Ri,lastChild:r,onListItemAction:s})})},cm=g(Vn)`
2894
+ `,um=({className:e,dp:t,emptyState:o,firstChild:n,lastChild:r,onListItemAction:s,selected:l,viewing:a})=>{const u=d.useMemo(()=>({selected:l,viewing:a}),[l,a]);return i.jsx(Oi.Provider,{value:u,children:i.jsx(hm,{className:e,dataProvider:t,emptyState:o,firstChild:n,ItemTemplate:Ri,lastChild:r,onListItemAction:s})})},hm=g(Vn)`
2889
2895
  height: 100%;
2890
2896
  width: 100%;
2891
2897
  align-items: flex-start;
@@ -2901,34 +2907,34 @@
2901
2907
  ::-webkit-scrollbar-thumb {
2902
2908
  border-left: 3px solid transparent;
2903
2909
  }
2904
- `,Ni=d.createContext(!1),dm=()=>d.useContext(Ni),um=d.memo(({title:e,disabled:t,onToggleShowSelected:o,t:n})=>i.jsxs(pm,{children:[i.jsx(E,{variant:"h2",color:"dark",children:e}),i.jsxs(hm,{children:[i.jsx(E,{variant:"small",color:"grey",children:(n==null?void 0:n("selectedOnly"))??"MISSING T FUNC"}),i.jsx(vo,{disabled:t,onChange:o})]})]})),pm=g.div`
2910
+ `,Ni=d.createContext(!1),pm=()=>d.useContext(Ni),fm=d.memo(({title:e,disabled:t,onToggleShowSelected:o,t:n})=>i.jsxs(gm,{children:[i.jsx(E,{variant:"h2",color:"dark",children:e}),i.jsxs(mm,{children:[i.jsx(E,{variant:"small",color:"grey",children:(n==null?void 0:n("selectedOnly"))??"MISSING T FUNC"}),i.jsx(vo,{disabled:t,onChange:o})]})]})),gm=g.div`
2905
2911
  display: flex;
2906
2912
  align-items: center;
2907
2913
  width: 100%;
2908
2914
  justify-content: space-between;
2909
2915
  gap: ${c("spacing-8")};
2910
- `,hm=g.div`
2916
+ `,mm=g.div`
2911
2917
  display: flex;
2912
2918
  align-items: center;
2913
2919
  gap: ${c("spacing-4")};
2914
- `,fm=d.memo(e=>{const{selected:t}=Ae(),o=dm(),n=t.includes(e.id);return o&&!n?null:i.jsx(yi,{...e})}),gm=g(Mi)`
2920
+ `,bm=d.memo(e=>{const{selected:t}=Le(),o=pm(),n=t.includes(e.id);return o&&!n?null:i.jsx(yi,{...e})}),xm=g(Mi)`
2915
2921
  overflow: hidden;
2916
- `,mm=g.div`
2922
+ `,ym=g.div`
2917
2923
  overflow-x: hidden;
2918
2924
  overflow-y: auto;
2919
- `,bm=W.kosComponent(({defaultShowSelected:e,disabled:t,title:o,selected:n,onSelect:r,emptyMessage:s,dataProvider:l,className:a,onSelectAll:u,t:p})=>{const[h,f]=d.useState(e??!1),m=d.useRef(null),b=d.useCallback(y=>{f(y)},[]);d.useEffect(()=>{const y=l;y&&y.updateContextValue&&(y==null||y.updateContextValue("isOnlySelectedVisible",h))},[l,h]),d.useEffect(()=>{const y=l;y&&y.updateContextValue&&(y==null||y.updateContextValue("selected",n))},[l,n]),d.useEffect(()=>{m.current&&n&&(n.length&&n.length!==(l==null?void 0:l.items.length)?m.current.indeterminate!==!0&&(l!=null&&l.items.length)&&(m.current.indeterminate=!0):m.current.indeterminate===!0&&(m.current.indeterminate=!1))},[l==null?void 0:l.items,n]);const x=d.useCallback(()=>{u&&u(n&&n.length>0?"deselect":"select")},[u,n]);return i.jsx(Ni.Provider,{value:h,children:i.jsx(gm,{className:a,variant:"display",header:i.jsx(um,{title:o,disabled:t,t:p,onToggleShowSelected:b}),ContentWrapper:mm,children:i.jsxs(xm,{children:[!!u&&!!(l!=null&&l.items.length)&&i.jsxs(Qt,{children:[i.jsx($o,{children:i.jsx(_t,{ref:m,disabled:t,checked:!!n&&!!n.length&&n.length===l.items.length,onChange:x})}),i.jsx(So,{children:i.jsx(E,{bold:!0,variant:"body",children:(p==null?void 0:p("selectAll"))??"MISSING T FUNC"})})]}),i.jsx(Co,{disabled:t,selected:n,isSingleSelect:!1,onSelect:r,emptyState:s?i.jsx(ym,{children:i.jsx(E,{variant:"body",color:"grey",children:s})}):void 0,ItemTemplate:fm,dataProvider:l})]})})})}),xm=g.div`
2925
+ `,vm=W.kosComponent(({defaultShowSelected:e,disabled:t,title:o,selected:n,onSelect:r,emptyMessage:s,dataProvider:l,className:a,onSelectAll:u,t:h})=>{const[p,f]=d.useState(e??!1),m=d.useRef(null),b=d.useCallback(y=>{f(y)},[]);d.useEffect(()=>{const y=l;y&&y.updateContextValue&&(y==null||y.updateContextValue("isOnlySelectedVisible",p))},[l,p]),d.useEffect(()=>{const y=l;y&&y.updateContextValue&&(y==null||y.updateContextValue("selected",n))},[l,n]),d.useEffect(()=>{m.current&&n&&(n.length&&n.length!==(l==null?void 0:l.items.length)?m.current.indeterminate!==!0&&(l!=null&&l.items.length)&&(m.current.indeterminate=!0):m.current.indeterminate===!0&&(m.current.indeterminate=!1))},[l==null?void 0:l.items,n]);const x=d.useCallback(()=>{u&&u(n&&n.length>0?"deselect":"select")},[u,n]);return i.jsx(Ni.Provider,{value:p,children:i.jsx(xm,{className:a,variant:"display",header:i.jsx(fm,{title:o,disabled:t,t:h,onToggleShowSelected:b}),ContentWrapper:ym,children:i.jsxs(km,{children:[!!u&&!!(l!=null&&l.items.length)&&i.jsxs(Qt,{children:[i.jsx($o,{children:i.jsx(_t,{ref:m,disabled:t,checked:!!n&&!!n.length&&n.length===l.items.length,onChange:x})}),i.jsx(So,{children:i.jsx(E,{bold:!0,variant:"body",children:(h==null?void 0:h("selectAll"))??"MISSING T FUNC"})})]}),i.jsx(Co,{disabled:t,selected:n,isSingleSelect:!1,onSelect:r,emptyState:s?i.jsx(wm,{children:i.jsx(E,{variant:"body",color:"grey",children:s})}):void 0,ItemTemplate:bm,dataProvider:l})]})})})}),km=g.div`
2920
2926
  width: 100%;
2921
2927
  display: flex;
2922
2928
  flex-direction: column;
2923
2929
  align-items: flex-start;
2924
2930
  justify-content: flex-start;
2925
- `,ym=g.div`
2931
+ `,wm=g.div`
2926
2932
  width: 100%;
2927
2933
  display: flex;
2928
2934
  align-items: center;
2929
2935
  justify-content: center;
2930
2936
  padding: ${c("spacing-12")} ${c("spacing-20")};
2931
- `;class vm extends Pn{constructor(o,n,r,s){super(o,n,r,{...s,isOnlySelectedVisible:(s==null?void 0:s.isOnlySelectedVisible)??!1,selected:(s==null?void 0:s.selected)??[]});T(this,"itemMapper");T(this,"observableItems");this.itemMapper=r,this.observableItems=_.observable.map(new Map)}get items(){if(!this.initialized||this.version<0)return[];const o=this.resolvedItems,n=[...new Set(o)],r=u=>this.itemMapper(u,this.context),s=u=>this.filterByInputItem(u,this.context),l=n.filter(s.bind(this)).filter(this.context.get("isOnlySelectedVisible")===!0?u=>(this.context.get("selected")??[]).includes(u.id):()=>!0).sort(this.sortByInputItem.bind(this)).map(r);return Array.from(this.observableItems.keys()).filter(u=>!l.find(p=>p.id===u)).forEach(u=>{W.kosAction(()=>{this.observableItems.delete(u)})}),l.reduce((u,p)=>{if(!u.has(p.id))W.kosAction(()=>{u.set(p.id,p)});else{const h=u.get(p.id);h&&W.kosAction(()=>{const f=Object.assign(h,p);u.set(p.id,f)})}return u},this.observableItems),l.map(u=>this.observableItems.get(u.id))}}const[an]=M(["shell-menu"]),km=({className:e,left:t,right:o})=>i.jsxs(wm,{className:e,children:[i.jsx(Sr,{children:t}),!!o&&i.jsx(Sr,{children:o})]}),wm=g.div`
2937
+ `;class Cm extends Pn{constructor(o,n,r,s){super(o,n,r,{...s,isOnlySelectedVisible:(s==null?void 0:s.isOnlySelectedVisible)??!1,selected:(s==null?void 0:s.selected)??[]});T(this,"itemMapper");T(this,"observableItems");this.itemMapper=r,this.observableItems=_.observable.map(new Map)}get items(){if(!this.initialized||this.version<0)return[];const o=this.resolvedItems,n=[...new Set(o)],r=u=>this.itemMapper(u,this.context),s=u=>this.filterByInputItem(u,this.context),l=n.filter(s.bind(this)).filter(this.context.get("isOnlySelectedVisible")===!0?u=>(this.context.get("selected")??[]).includes(u.id):()=>!0).sort(this.sortByInputItem.bind(this)).map(r);return Array.from(this.observableItems.keys()).filter(u=>!l.find(h=>h.id===u)).forEach(u=>{W.kosAction(()=>{this.observableItems.delete(u)})}),l.reduce((u,h)=>{if(!u.has(h.id))W.kosAction(()=>{u.set(h.id,h)});else{const p=u.get(h.id);p&&W.kosAction(()=>{const f=Object.assign(p,h);u.set(h.id,f)})}return u},this.observableItems),l.map(u=>this.observableItems.get(u.id))}}const[an]=M(["shell-menu"]),$m=({className:e,left:t,right:o})=>i.jsxs(Sm,{className:e,children:[i.jsx(Sr,{children:t}),!!o&&i.jsx(Sr,{children:o})]}),Sm=g.div`
2932
2938
  align-items: center;
2933
2939
  column-gap: ${an("section-gap")};
2934
2940
  display: flex;
@@ -2942,45 +2948,45 @@
2942
2948
  display: flex;
2943
2949
  height: 100%;
2944
2950
  justify-content: flex-start;
2945
- `,[jr]=M(["shell-menu"]),Cm=d.memo(({text:e,onClick:t,isActive:o})=>i.jsx($m,{onClick:t,variant:"body",color:"light",bold:o,children:e})),$m=g(E)`
2951
+ `,[jr]=M(["shell-menu"]),jm=d.memo(({text:e,onClick:t,isActive:o})=>i.jsx(Im,{onClick:t,variant:"body",color:"light",bold:o,children:e})),Im=g(E)`
2946
2952
  padding: ${jr("link-padding-y")} ${jr("link-padding-x")};
2947
2953
  line-height: unset;
2948
2954
  cursor: pointer;
2949
- `,[Qe]=M(["ingredient-card"]),Sm=d.memo(({id:e,name:t,trouble:o,ingredientName:n,assigned:r,onListItemAction:s,blocked:l,isSmall:a})=>{const{selected:u,toggleSelection:p}=Ae(),{t:h}=W.useKosTranslation("dispenser"),f=d.useMemo(()=>u.includes(e),[u,e]),m=d.useCallback(()=>{s&&s(e,"delete")},[e,s]),b=d.useCallback(y=>{s&&s(e,y)},[e,s]),x=d.useCallback(()=>{p(e)},[e,p]);return i.jsx(z.ClassNames,{children:({cx:y})=>i.jsxs(jm,{className:y("holder-list-item",{isSelected:f,isSmall:a}),onClick:x,children:[i.jsxs(Im,{children:[i.jsxs(Dm,{children:[i.jsx(E,{variant:a?"small":"body",color:"dark",children:t}),!!o&&i.jsx(wo,{content:o,children:i.jsx(R,{iconId:"ExclamationCircle",color:"red",size:a?"xsm":"sm"})})]}),!!n&&i.jsxs(_m,{children:[i.jsx(ae,{iconId:"DeleteOutlined",color:"blue",size:a?"xsm":"sm",onClick:m,disabled:!r}),i.jsxs(Et,{Reference:i.jsx(ae,{iconId:"Ellipsis",color:"black",size:a?"xsm":"sm"}),onSelect:b,children:[i.jsx(dt,{optionKey:"remove",label:h("holder.removeOption"),disableSelectionStyle:!0,disabled:!r}),i.jsx(dt,{optionKey:"block",disableSelectionStyle:!0,disabled:!r,label:h(`holder.${l?"unblockOption":"blockOption"}`)})]})]})]}),i.jsx(Tm,{className:y({isIngredientLess:n===void 0}),children:n?i.jsx(E,{color:"dark",variant:a?"small":"body",bold:!0,children:n}):i.jsx(Ge,{variant:a?"borderless-small":"borderless",text:h("holder.assignButton"),icon:"Plus"})})]})})}),jm=g.div`
2955
+ `,[et]=M(["ingredient-card"]),Dm=d.memo(({id:e,name:t,trouble:o,ingredientName:n,assigned:r,onListItemAction:s,blocked:l,isSmall:a})=>{const{selected:u,toggleSelection:h}=Le(),{t:p}=W.useKosTranslation("dispenser"),f=d.useMemo(()=>u.includes(e),[u,e]),m=d.useCallback(()=>{s&&s(e,"delete")},[e,s]),b=d.useCallback(y=>{s&&s(e,y)},[e,s]),x=d.useCallback(()=>{h(e)},[e,h]);return i.jsx(z.ClassNames,{children:({cx:y})=>i.jsxs(_m,{className:y("holder-list-item",{isSelected:f,isSmall:a}),onClick:x,children:[i.jsxs(Tm,{children:[i.jsxs(Em,{children:[i.jsx(E,{variant:a?"small":"body",color:"dark",children:t}),!!o&&i.jsx(wo,{content:o,children:i.jsx(R,{iconId:"ExclamationCircle",color:"red",size:a?"xsm":"sm"})})]}),!!n&&i.jsxs(zm,{children:[i.jsx(ae,{iconId:"DeleteOutlined",color:"blue",size:a?"xsm":"sm",onClick:m,disabled:!r}),i.jsxs(Et,{Reference:i.jsx(ae,{iconId:"Ellipsis",color:"black",size:a?"xsm":"sm"}),onSelect:b,children:[i.jsx(dt,{optionKey:"remove",label:p("holder.removeOption"),disableSelectionStyle:!0,disabled:!r}),i.jsx(dt,{optionKey:"block",disableSelectionStyle:!0,disabled:!r,label:p(`holder.${l?"unblockOption":"blockOption"}`)})]})]})]}),i.jsx(Mm,{className:y({isIngredientLess:n===void 0}),children:n?i.jsx(E,{color:"dark",variant:a?"small":"body",bold:!0,children:n}):i.jsx(Ke,{variant:a?"borderless-small":"borderless",text:p("holder.assignButton"),icon:"Plus"})})]})})}),_m=g.div`
2950
2956
  width: 100%;
2951
2957
  height: 100%;
2952
- border: ${Qe("border")} solid ${Qe("border-color")};
2958
+ border: ${et("border")} solid ${et("border-color")};
2953
2959
  transition: border 0.125s ease-in-out;
2954
- border-radius: ${Qe("border-radius")};
2955
- padding: ${Qe("padding")};
2960
+ border-radius: ${et("border-radius")};
2961
+ padding: ${et("padding")};
2956
2962
  display: flex;
2957
2963
  flex-direction: column;
2958
2964
  align-items: flex-start;
2959
2965
  justify-content: flex-start;
2960
2966
  cursor: pointer;
2961
2967
  &.isSmall {
2962
- padding: ${Qe("padding-small")};
2968
+ padding: ${et("padding-small")};
2963
2969
  }
2964
2970
  &.isSelected {
2965
- border-color: ${Qe("border-color-selected")};
2971
+ border-color: ${et("border-color-selected")};
2966
2972
  }
2967
- `,Im=g.div`
2973
+ `,Tm=g.div`
2968
2974
  width: 100%;
2969
2975
  display: flex;
2970
2976
  align-items: center;
2971
2977
  justify-content: flex-start;
2972
- column-gap: ${Qe("column-gap")};
2973
- `,Dm=g.div`
2978
+ column-gap: ${et("column-gap")};
2979
+ `,Em=g.div`
2974
2980
  flex: 1;
2975
2981
  display: flex;
2976
2982
  align-items: center;
2977
2983
  justify-content: flex-start;
2978
- column-gap: ${Qe("column-gap")};
2979
- `,_m=g.div`
2984
+ column-gap: ${et("column-gap")};
2985
+ `,zm=g.div`
2980
2986
  display: flex;
2981
2987
  align-items: center;
2982
- column-gap: ${Qe("column-gap")};
2983
- `,Tm=g.div`
2988
+ column-gap: ${et("column-gap")};
2989
+ `,Mm=g.div`
2984
2990
  width: 100%;
2985
2991
  display: flex;
2986
2992
  align-items: center;
@@ -2989,25 +2995,25 @@
2989
2995
  &.isIngredientLess {
2990
2996
  justify-content: center;
2991
2997
  }
2992
- `,Em=["settings","devices","tools","performance"],zm=["viewBrowse","manage","configure","troubleshoot","store","main"],Mm=Em.map(e=>zm.map(t=>({start:e,end:t}))).flatMap(e=>e),[Ce,Fi]=M(["branded-header","icon"]),Om=g.div`
2998
+ `,Om=["settings","devices","tools","performance"],Rm=["viewBrowse","manage","configure","troubleshoot","store","main"],Nm=Om.map(e=>Rm.map(t=>({start:e,end:t}))).flatMap(e=>e),[$e,Fi]=M(["branded-header","icon"]),Fm=g.div`
2993
2999
  width: 100%;
2994
3000
  display: flex;
2995
3001
  flex-direction: column;
2996
3002
  align-items: flex-start;
2997
3003
  justify-content: flex-start;
2998
- border-bottom: ${Ce("border-bottom-size")} solid ${Ce("border-bottom-color")};
2999
- `,Rm=g.div`
3004
+ border-bottom: ${$e("border-bottom-size")} solid ${$e("border-bottom-color")};
3005
+ `,Am=g.div`
3000
3006
  width: 100%;
3001
3007
  display: flex;
3002
3008
  align-items: center;
3003
3009
  justify-content: flex-start;
3004
3010
  max-height: 52px;
3005
- `;g.div``;const Nm=g.div`
3011
+ `;g.div``;const Lm=g.div`
3006
3012
  display: flex;
3007
3013
  flex: 1;
3008
3014
  gap: 16px;
3009
3015
  padding: 12px 20px 12px 16px;
3010
- `,Fm=g.div`
3016
+ `,Bm=g.div`
3011
3017
  flex: 1;
3012
3018
  display: flex;
3013
3019
  align-items: center;
@@ -3017,39 +3023,39 @@
3017
3023
  /* &.hasDescription {
3018
3024
  align-items: flex-start;
3019
3025
  } */
3020
- `,Am=g.div`
3026
+ `,Wm=g.div`
3021
3027
  flex: 1;
3022
3028
  overflow: hidden;
3023
3029
  display: flex;
3024
3030
  flex-direction: column;
3025
3031
  align-items: flex-start;
3026
3032
  justify-content: flex-start;
3027
- row-gap: ${Ce("text-wrapper-gap")};
3033
+ row-gap: ${$e("text-wrapper-gap")};
3028
3034
  `;g.img`
3029
3035
  height: 100%;
3030
3036
  `;const Ai=z.css`
3031
- ${Mm.map(({start:e,end:t})=>`&[data-gradient="${e}-${t}"] {
3037
+ ${Nm.map(({start:e,end:t})=>`&[data-gradient="${e}-${t}"] {
3032
3038
  background: linear-gradient(
3033
3039
  90deg,
3034
- ${Ce(`startColor-${e}`)} 0%,
3035
- ${Ce(`endColor-${t}`)} 100%
3040
+ ${$e(`startColor-${e}`)} 0%,
3041
+ ${$e(`endColor-${t}`)} 100%
3036
3042
  );
3037
3043
  }`)}
3038
- `,Lm=g.div`
3044
+ `,Pm=g.div`
3039
3045
  background-color: ${e=>e.color};
3040
- height: ${Ce("badge-size")};
3041
- width: ${Ce("badge-size")};
3042
- border-radius: ${Ce("badge-radius")};
3046
+ height: ${$e("badge-size")};
3047
+ width: ${$e("badge-size")};
3048
+ border-radius: ${$e("badge-radius")};
3043
3049
  position: relative;
3044
3050
  ${`${Fi("size-xxlrg",!0)}: 52px`};
3045
3051
  `;g.div`
3046
- height: ${Ce("badge-size")};
3047
- width: ${Ce("badge-size")};
3048
- border-radius: ${Ce("badge-radius")};
3052
+ height: ${$e("badge-size")};
3053
+ width: ${$e("badge-size")};
3054
+ border-radius: ${$e("badge-radius")};
3049
3055
  position: relative;
3050
3056
  ${`${Fi("size-xxlrg",!0)}: calc(100% - 2px)`};
3051
3057
  ${Ai}
3052
- `;const Bm=g.div`
3058
+ `;const Vm=g.div`
3053
3059
  width: 100%;
3054
3060
  height: 100%;
3055
3061
  position: absolute;
@@ -3065,10 +3071,10 @@
3065
3071
  align-items: center;
3066
3072
  justify-content: center;
3067
3073
  position: relative;
3068
- height: ${Ce("line-height")};
3074
+ height: ${$e("line-height")};
3069
3075
  overflow: hidden;
3070
3076
  ${Ai}
3071
- `;const Wm=g.div`
3077
+ `;const Hm=g.div`
3072
3078
  width: 100%;
3073
3079
  height: 100%;
3074
3080
  position: absolute;
@@ -3077,13 +3083,13 @@
3077
3083
  z-index: 1;
3078
3084
  background-color: ${c("color-grey60")};
3079
3085
  opacity: 0.5;
3080
- `,Pm=g(E)`
3086
+ `,Um=g(E)`
3081
3087
  display: -webkit-box;
3082
3088
  -webkit-line-clamp: 2;
3083
3089
  -webkit-box-orient: vertical;
3084
3090
  overflow: hidden;
3085
3091
  text-overflow: ellipsis;
3086
- `,Vm=e=>i.jsx(Pm,{...e,variant:"body",color:"dark"}),Hm=d.memo(({color:e,title:t,description:o,icon:n,Action:r,isOffline:s})=>i.jsx(z.ClassNames,{children:({cx:l})=>i.jsx(Om,{children:i.jsxs(Rm,{children:[i.jsxs(Lm,{color:e,children:[i.jsx(Bm,{children:n&&i.jsx(R,{iconId:n,size:"xxlrg",color:"white"})}),!!s&&i.jsx(Wm,{})]}),i.jsxs(Nm,{children:[i.jsx(Fm,{className:l({hasDescription:!!o}),children:i.jsxs(Am,{children:[i.jsx(E,{variant:"h1",children:t}),!!o&&i.jsx(Vm,{children:o})]})}),!!r&&i.jsx(r,{})]})]})})})),Li=d.createContext(null),Bi=W.kosComponent(({children:e,t,isSortable:o,onListItemAction:n})=>{const r=d.useMemo(()=>({t,isSortable:!!o,onListItemAction:n}),[o,t,n]);return i.jsx(Li.Provider,{value:r,children:e})}),Kn=()=>{const e=d.useContext(Li);if(e===null)throw new Error("TableContext must be used within a TableContextProvider");return e},[at]=M(["table"]),Do=g.td`
3092
+ `,Gm=e=>i.jsx(Um,{...e,variant:"body",color:"dark"}),Km=d.memo(({color:e,title:t,description:o,icon:n,Action:r,isOffline:s})=>i.jsx(z.ClassNames,{children:({cx:l})=>i.jsx(Fm,{children:i.jsxs(Am,{children:[i.jsxs(Pm,{color:e,children:[i.jsx(Vm,{children:n&&i.jsx(R,{iconId:n,size:"xxlrg",color:"white"})}),!!s&&i.jsx(Hm,{})]}),i.jsxs(Lm,{children:[i.jsx(Bm,{className:l({hasDescription:!!o}),children:i.jsxs(Wm,{children:[i.jsx(E,{variant:"h1",children:t}),!!o&&i.jsx(Gm,{children:o})]})}),!!r&&i.jsx(r,{})]})]})})})),Li=d.createContext(null),Bi=W.kosComponent(({children:e,t,isSortable:o,onListItemAction:n})=>{const r=d.useMemo(()=>({t,isSortable:!!o,onListItemAction:n}),[o,t,n]);return i.jsx(Li.Provider,{value:r,children:e})}),Kn=()=>{const e=d.useContext(Li);if(e===null)throw new Error("TableContext must be used within a TableContextProvider");return e},[at]=M(["table"]),Do=g.td`
3087
3093
  padding: ${at("cell-padding-y")} ${at("cell-padding-x")};
3088
3094
  background-color: ${at("background-color")};
3089
3095
  color: ${at("cell-color")};
@@ -3095,20 +3101,20 @@
3095
3101
  &:first-of-type {
3096
3102
  padding-left: ${at("cell-padding-left-first-in-row")};
3097
3103
  }
3098
- `,Yn=d.memo(({cell:e})=>{const{isSortable:t}=Kn();return i.jsx(Do,{className:t&&e.column.getCanSort()?"isSortable":void 0,children:ke.flexRender(e.column.columnDef.cell,e.getContext())},e.id)}),[Ir]=M(["table"]),$t=g.tr`
3104
+ `,Yn=d.memo(({cell:e})=>{const{isSortable:t}=Kn();return i.jsx(Do,{className:t&&e.column.getCanSort()?"isSortable":void 0,children:we.flexRender(e.column.columnDef.cell,e.getContext())},e.id)}),[Ir]=M(["table"]),$t=g.tr`
3099
3105
  width: 100%;
3100
3106
  border-bottom: ${Ir("row-border-bottom-size")} solid ${Ir("border-color")};
3101
- `,Um=d.memo(({row:e,TdComponent:t})=>{const o=t??Yn;return i.jsx($t,{children:e.getVisibleCells().map(n=>i.jsx(o,{cell:n},n.id))})}),[Gm]=M(["table"]),Km=e=>e.id,Ym=({items:e,columns:t,getRowId:o,emptyState:n,isSortable:r,t:s,TdComponent:l,TrComponent:a,onListItemAction:u,renderEmptyAsStandalone:p,disabled:h,...f})=>{const[m,b]=d.useState([]),x=ke.useReactTable({columns:t,meta:{disabled:h},data:e,getCoreRowModel:ke.getCoreRowModel(),getSortedRowModel:r?ke.getSortedRowModel():void 0,getRowId:o??Km,onSortingChange:r?b:void 0,state:{sorting:m}}),y=a??Um,k=!x.getRowModel().rows.length;return k&&p?n??null:i.jsx(Bi,{onListItemAction:u,isSortable:r,t:s,children:i.jsxs(Xm,{...f,children:[i.jsx(Jm,{children:x.getHeaderGroups().map(v=>i.jsx($t,{children:v.headers.map($=>i.jsx(d.Fragment,{children:ke.flexRender($.column.columnDef.header,$.getContext())},$.id))},v.id))}),i.jsx(Qm,{children:k?i.jsx($t,{children:i.jsx(Do,{colSpan:t.length,children:n??null})}):x.getRowModel().rows.map(v=>i.jsx(y,{row:v,TdComponent:l??Yn},v.id))})]})})},qm=[],Zm=W.kosComponent(({dataProvider:e,columns:t,getRowId:o,emptyState:n,isSortable:r,t:s,TdComponent:l,TrComponent:a,onListItemAction:u,renderEmptyAsStandalone:p,disabled:h,...f})=>(Xt(e),i.jsx(St.Observer,{children:()=>{const m=e?e.items:qm;return i.jsx(Ym,{items:m,columns:t,getRowId:o,emptyState:n,isSortable:r,t:s,TdComponent:l,TrComponent:a,onListItemAction:u,renderEmptyAsStandalone:p,disabled:h,...f})}}))),Xm=g.table`
3107
+ `,Ym=d.memo(({row:e,TdComponent:t})=>{const o=t??Yn;return i.jsx($t,{children:e.getVisibleCells().map(n=>i.jsx(o,{cell:n},n.id))})}),[qm]=M(["table"]),Zm=e=>e.id,Xm=({items:e,columns:t,getRowId:o,emptyState:n,isSortable:r,t:s,TdComponent:l,TrComponent:a,onListItemAction:u,renderEmptyAsStandalone:h,disabled:p,...f})=>{const[m,b]=d.useState([]),x=we.useReactTable({columns:t,meta:{disabled:p},data:e,getCoreRowModel:we.getCoreRowModel(),getSortedRowModel:r?we.getSortedRowModel():void 0,getRowId:o??Zm,onSortingChange:r?b:void 0,state:{sorting:m}}),y=a??Ym,k=!x.getRowModel().rows.length;return k&&h?n??null:i.jsx(Bi,{onListItemAction:u,isSortable:r,t:s,children:i.jsxs(eb,{...f,children:[i.jsx(tb,{children:x.getHeaderGroups().map(v=>i.jsx($t,{children:v.headers.map($=>i.jsx(d.Fragment,{children:we.flexRender($.column.columnDef.header,$.getContext())},$.id))},v.id))}),i.jsx(ob,{children:k?i.jsx($t,{children:i.jsx(Do,{colSpan:t.length,children:n??null})}):x.getRowModel().rows.map(v=>i.jsx(y,{row:v,TdComponent:l??Yn},v.id))})]})})},Jm=[],Qm=W.kosComponent(({dataProvider:e,columns:t,getRowId:o,emptyState:n,isSortable:r,t:s,TdComponent:l,TrComponent:a,onListItemAction:u,renderEmptyAsStandalone:h,disabled:p,...f})=>(Xt(e),i.jsx(St.Observer,{children:()=>{const m=e?e.items:Jm;return i.jsx(Xm,{items:m,columns:t,getRowId:o,emptyState:n,isSortable:r,t:s,TdComponent:l,TrComponent:a,onListItemAction:u,renderEmptyAsStandalone:h,disabled:p,...f})}}))),eb=g.table`
3102
3108
  width: 100%;
3103
3109
  overflow: auto;
3104
3110
  border-collapse: collapse;
3105
- font-family: ${Gm("font-family")};
3111
+ font-family: ${qm("font-family")};
3106
3112
  table-layout: fixed;
3107
- `,Jm=g.thead`
3113
+ `,tb=g.thead`
3108
3114
  width: 100%;
3109
- `,Qm=g.tbody`
3115
+ `,ob=g.tbody`
3110
3116
  width: 100%;
3111
- `,[ze]=M(["table"]),eb=(e,t)=>e?e==="desc"?(t==null?void 0:t("table.sort",{direction:t==null?void 0:t("table.ascending"),defaultValue:"Click to sort ascending"}))??"Click to sort ascending":(t==null?void 0:t("table.cancelSort",{defaultValue:"Cancel sort"}))??"Cancel sort":(t==null?void 0:t("table.sort",{direction:t==null?void 0:t("table.descending"),defaultValue:"Click to sort descending"}))??"Click to sort descending",ln=d.memo(({width:e,isBlank:t,toggleSorting:o,id:n,alignment:r,sortValue:s,canSort:l,isVirtual:a})=>{const{isSortable:u,t:p}=Kn(),h=d.useCallback(()=>{o()},[o]);return i.jsx(tb,{className:Dt({isSortable:u&&l,isSorted:s!==!1}),style:{width:e??"auto",display:a?"flex":"table-cell"},children:i.jsxs(ob,{"data-alignment":r,children:[!t&&((p==null?void 0:p(`table.header.${n}`))??n),u&&l&&i.jsx(wo,{content:eb(s,p),children:i.jsx(ae,{iconId:s?s==="asc"?"SortAscending":"SortDescending":"Sort",size:"sm",onClick:h,color:"grey"})})]})})}),tb=g.th`
3117
+ `,[ze]=M(["table"]),nb=(e,t)=>e?e==="desc"?(t==null?void 0:t("table.sort",{direction:t==null?void 0:t("table.ascending"),defaultValue:"Click to sort ascending"}))??"Click to sort ascending":(t==null?void 0:t("table.cancelSort",{defaultValue:"Cancel sort"}))??"Cancel sort":(t==null?void 0:t("table.sort",{direction:t==null?void 0:t("table.descending"),defaultValue:"Click to sort descending"}))??"Click to sort descending",ln=d.memo(({width:e,isBlank:t,toggleSorting:o,id:n,alignment:r,sortValue:s,canSort:l,isVirtual:a})=>{const{isSortable:u,t:h}=Kn(),p=d.useCallback(()=>{o()},[o]);return i.jsx(rb,{className:Dt({isSortable:u&&l,isSorted:s!==!1}),style:{width:e??"auto",display:a?"flex":"table-cell"},children:i.jsxs(sb,{"data-alignment":r,children:[!t&&((h==null?void 0:h(`table.header.${n}`))??n),u&&l&&i.jsx(wo,{content:nb(s,h),children:i.jsx(ae,{iconId:s?s==="asc"?"SortAscending":"SortDescending":"Sort",size:"sm",onClick:p,color:"grey"})})]})})}),rb=g.th`
3112
3118
  padding: ${ze("cell-padding-y")} ${ze("cell-padding-x")};
3113
3119
  background-color: ${ze("header-background-color")};
3114
3120
  color: ${ze("head-color")};
@@ -3128,7 +3134,7 @@
3128
3134
  &:first-of-type {
3129
3135
  padding-left: ${ze("cell-padding-left-first-in-row")};
3130
3136
  }
3131
- `,ob=g.div`
3137
+ `,sb=g.div`
3132
3138
  display: flex;
3133
3139
  align-items: center;
3134
3140
  justify-content: space-between;
@@ -3142,29 +3148,29 @@
3142
3148
  &[data-alignment="center"] {
3143
3149
  justify-content: center;
3144
3150
  }
3145
- `,nb=()=>{const e=ke.createColumnHelper();return{displayColumn:r=>s=>e.display({header:({column:l,header:a})=>{var u,p,h;return i.jsx(ln,{id:a.id,canSort:l.getCanSort(),width:(u=l.columnDef.meta)==null?void 0:u.width,alignment:(p=l.columnDef.meta)==null?void 0:p.headerAlign,isBlank:(h=l.columnDef.meta)==null?void 0:h.isBlank,toggleSorting:l.toggleSorting,sortValue:l.getIsSorted(),isVirtual:r==null?void 0:r.isVirtual},a.id)},...s,meta:{...s.meta,width:"auto",...r}}),accessorColumn:r=>(s,l)=>e.accessor(s,{header:({column:a,header:u})=>{var p,h,f;return i.jsx(ln,{id:u.id,canSort:a.getCanSort(),width:(p=a.columnDef.meta)==null?void 0:p.width,alignment:(h=a.columnDef.meta)==null?void 0:h.headerAlign,isBlank:(f=a.columnDef.meta)==null?void 0:f.isBlank,toggleSorting:a.toggleSorting,sortValue:a.getIsSorted(),isVirtual:r==null?void 0:r.isVirtual},u.id)},...l,meta:{...l.meta,width:"auto",...r}}),groupColumn:r=>s=>e.group({...s,meta:{...s.meta,width:"auto",...r}})}};function vt(e,t,o){let n=o.initialDeps??[],r;function s(){var l,a,u,p;let h;o.key&&((l=o.debug)!=null&&l.call(o))&&(h=Date.now());const f=e();if(!(f.length!==n.length||f.some((x,y)=>n[y]!==x)))return r;n=f;let b;if(o.key&&((a=o.debug)!=null&&a.call(o))&&(b=Date.now()),r=t(...f),o.key&&((u=o.debug)!=null&&u.call(o))){const x=Math.round((Date.now()-h)*100)/100,y=Math.round((Date.now()-b)*100)/100,k=y/16,v=($,C)=>{for($=String($);$.length<C;)$=" "+$;return $};console.info(`%c⏱ ${v(y,5)} /${v(x,5)} ms`,`
3151
+ `,ib=()=>{const e=we.createColumnHelper();return{displayColumn:r=>s=>e.display({header:({column:l,header:a})=>{var u,h,p;return i.jsx(ln,{id:a.id,canSort:l.getCanSort(),width:(u=l.columnDef.meta)==null?void 0:u.width,alignment:(h=l.columnDef.meta)==null?void 0:h.headerAlign,isBlank:(p=l.columnDef.meta)==null?void 0:p.isBlank,toggleSorting:l.toggleSorting,sortValue:l.getIsSorted(),isVirtual:r==null?void 0:r.isVirtual},a.id)},...s,meta:{...s.meta,width:"auto",...r}}),accessorColumn:r=>(s,l)=>e.accessor(s,{header:({column:a,header:u})=>{var h,p,f;return i.jsx(ln,{id:u.id,canSort:a.getCanSort(),width:(h=a.columnDef.meta)==null?void 0:h.width,alignment:(p=a.columnDef.meta)==null?void 0:p.headerAlign,isBlank:(f=a.columnDef.meta)==null?void 0:f.isBlank,toggleSorting:a.toggleSorting,sortValue:a.getIsSorted(),isVirtual:r==null?void 0:r.isVirtual},u.id)},...l,meta:{...l.meta,width:"auto",...r}}),groupColumn:r=>s=>e.group({...s,meta:{...s.meta,width:"auto",...r}})}};function vt(e,t,o){let n=o.initialDeps??[],r;function s(){var l,a,u,h;let p;o.key&&((l=o.debug)!=null&&l.call(o))&&(p=Date.now());const f=e();if(!(f.length!==n.length||f.some((x,y)=>n[y]!==x)))return r;n=f;let b;if(o.key&&((a=o.debug)!=null&&a.call(o))&&(b=Date.now()),r=t(...f),o.key&&((u=o.debug)!=null&&u.call(o))){const x=Math.round((Date.now()-p)*100)/100,y=Math.round((Date.now()-b)*100)/100,k=y/16,v=($,C)=>{for($=String($);$.length<C;)$=" "+$;return $};console.info(`%c⏱ ${v(y,5)} /${v(x,5)} ms`,`
3146
3152
  font-size: .6rem;
3147
3153
  font-weight: bold;
3148
- color: hsl(${Math.max(0,Math.min(120-120*k,120))}deg 100% 31%);`,o==null?void 0:o.key)}return(p=o==null?void 0:o.onChange)==null||p.call(o,r),r}return s.updateDeps=l=>{n=l},s}function Dr(e,t){if(e===void 0)throw new Error("Unexpected undefined");return e}const rb=(e,t)=>Math.abs(e-t)<1.01,sb=(e,t,o)=>{let n;return function(...r){e.clearTimeout(n),n=e.setTimeout(()=>t.apply(this,r),o)}},_r=e=>{const{offsetWidth:t,offsetHeight:o}=e;return{width:t,height:o}},ib=e=>e,ab=e=>{const t=Math.max(e.startIndex-e.overscan,0),o=Math.min(e.endIndex+e.overscan,e.count-1),n=[];for(let r=t;r<=o;r++)n.push(r);return n},lb=(e,t)=>{const o=e.scrollElement;if(!o)return;const n=e.targetWindow;if(!n)return;const r=l=>{const{width:a,height:u}=l;t({width:Math.round(a),height:Math.round(u)})};if(r(_r(o)),!n.ResizeObserver)return()=>{};const s=new n.ResizeObserver(l=>{const a=()=>{const u=l[0];if(u!=null&&u.borderBoxSize){const p=u.borderBoxSize[0];if(p){r({width:p.inlineSize,height:p.blockSize});return}}r(_r(o))};e.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(a):a()});return s.observe(o,{box:"border-box"}),()=>{s.unobserve(o)}},Tr={passive:!0},Er=typeof window>"u"?!0:"onscrollend"in window,cb=(e,t)=>{const o=e.scrollElement;if(!o)return;const n=e.targetWindow;if(!n)return;let r=0;const s=e.options.useScrollendEvent&&Er?()=>{}:sb(n,()=>{t(r,!1)},e.options.isScrollingResetDelay),l=h=>()=>{const{horizontal:f,isRtl:m}=e.options;r=f?o.scrollLeft*(m&&-1||1):o.scrollTop,s(),t(r,h)},a=l(!0),u=l(!1);u(),o.addEventListener("scroll",a,Tr);const p=e.options.useScrollendEvent&&Er;return p&&o.addEventListener("scrollend",u,Tr),()=>{o.removeEventListener("scroll",a),p&&o.removeEventListener("scrollend",u)}},db=(e,t,o)=>{if(t!=null&&t.borderBoxSize){const n=t.borderBoxSize[0];if(n)return Math.round(n[o.options.horizontal?"inlineSize":"blockSize"])}return e[o.options.horizontal?"offsetWidth":"offsetHeight"]},ub=(e,{adjustments:t=0,behavior:o},n)=>{var r,s;const l=e+t;(s=(r=n.scrollElement)==null?void 0:r.scrollTo)==null||s.call(r,{[n.options.horizontal?"left":"top"]:l,behavior:o})};class pb{constructor(t){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.measurementsCache=[],this.itemSizeCache=new Map,this.pendingMeasuredCacheIndexes=[],this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let o=null;const n=()=>o||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:o=new this.targetWindow.ResizeObserver(r=>{r.forEach(s=>{const l=()=>{this._measureElement(s.target,s)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(l):l()})}));return{disconnect:()=>{var r;(r=n())==null||r.disconnect(),o=null},observe:r=>{var s;return(s=n())==null?void 0:s.observe(r,{box:"border-box"})},unobserve:r=>{var s;return(s=n())==null?void 0:s.unobserve(r)}}})(),this.range=null,this.setOptions=o=>{Object.entries(o).forEach(([n,r])=>{typeof r>"u"&&delete o[n]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:ib,rangeExtractor:ab,onChange:()=>{},measureElement:db,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,...o}},this.notify=o=>{var n,r;(r=(n=this.options).onChange)==null||r.call(n,this,o)},this.maybeNotify=vt(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),o=>{this.notify(o)},{key:!1,debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(o=>o()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var o;const n=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==n){if(this.cleanup(),!n){this.maybeNotify();return}this.scrollElement=n,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=((o=this.scrollElement)==null?void 0:o.window)??null,this.elementsCache.forEach(r=>{this.observer.observe(r)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,r=>{this.scrollRect=r,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(r,s)=>{this.scrollAdjustments=0,this.scrollDirection=s?this.getScrollOffset()<r?"forward":"backward":null,this.scrollOffset=r,this.isScrolling=s,this.maybeNotify()}))}},this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??(typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(o,n)=>{const r=new Map,s=new Map;for(let l=n-1;l>=0;l--){const a=o[l];if(r.has(a.lane))continue;const u=s.get(a.lane);if(u==null||a.end>u.end?s.set(a.lane,a):a.end<u.end&&r.set(a.lane,!0),r.size===this.options.lanes)break}return s.size===this.options.lanes?Array.from(s.values()).sort((l,a)=>l.end===a.end?l.index-a.index:l.end-a.end)[0]:void 0},this.getMeasurementOptions=vt(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(o,n,r,s,l)=>(this.pendingMeasuredCacheIndexes=[],{count:o,paddingStart:n,scrollMargin:r,getItemKey:s,enabled:l}),{key:!1}),this.getMeasurements=vt(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:o,paddingStart:n,scrollMargin:r,getItemKey:s,enabled:l},a)=>{if(!l)return this.measurementsCache=[],this.itemSizeCache.clear(),[];this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(h=>{this.itemSizeCache.set(h.key,h.size)}));const u=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];const p=this.measurementsCache.slice(0,u);for(let h=u;h<o;h++){const f=s(h),m=this.options.lanes===1?p[h-1]:this.getFurthestMeasurement(p,h),b=m?m.end+this.options.gap:n+r,x=a.get(f),y=typeof x=="number"?x:this.options.estimateSize(h),k=b+y,v=m?m.lane:h%this.options.lanes;p[h]={index:h,start:b,size:y,end:k,key:f,lane:v}}return this.measurementsCache=p,p},{key:!1,debug:()=>this.options.debug}),this.calculateRange=vt(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(o,n,r,s)=>this.range=o.length>0&&n>0?hb({measurements:o,outerSize:n,scrollOffset:r,lanes:s}):null,{key:!1,debug:()=>this.options.debug}),this.getVirtualIndexes=vt(()=>{let o=null,n=null;const r=this.calculateRange();return r&&(o=r.startIndex,n=r.endIndex),this.maybeNotify.updateDeps([this.isScrolling,o,n]),[this.options.rangeExtractor,this.options.overscan,this.options.count,o,n]},(o,n,r,s,l)=>s===null||l===null?[]:o({startIndex:s,endIndex:l,overscan:n,count:r}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=o=>{const n=this.options.indexAttribute,r=o.getAttribute(n);return r?parseInt(r,10):(console.warn(`Missing attribute name '${n}={index}' on measured element.`),-1)},this._measureElement=(o,n)=>{const r=this.indexFromElement(o),s=this.measurementsCache[r];if(!s)return;const l=s.key,a=this.elementsCache.get(l);a!==o&&(a&&this.observer.unobserve(a),this.observer.observe(o),this.elementsCache.set(l,o)),o.isConnected&&this.resizeItem(r,this.options.measureElement(o,n,this))},this.resizeItem=(o,n)=>{const r=this.measurementsCache[o];if(!r)return;const s=this.itemSizeCache.get(r.key)??r.size,l=n-s;l!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(r,l,this):r.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=l,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(r.index),this.itemSizeCache=new Map(this.itemSizeCache.set(r.key,n)),this.notify(!1))},this.measureElement=o=>{if(!o){this.elementsCache.forEach((n,r)=>{n.isConnected||(this.observer.unobserve(n),this.elementsCache.delete(r))});return}this._measureElement(o,void 0)},this.getVirtualItems=vt(()=>[this.getVirtualIndexes(),this.getMeasurements()],(o,n)=>{const r=[];for(let s=0,l=o.length;s<l;s++){const a=o[s],u=n[a];r.push(u)}return r},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=o=>{const n=this.getMeasurements();if(n.length!==0)return Dr(n[Wi(0,n.length-1,r=>Dr(n[r]).start,o)])},this.getOffsetForAlignment=(o,n,r=0)=>{const s=this.getSize(),l=this.getScrollOffset();n==="auto"&&(n=o>=l+s?"end":"start"),n==="center"?o+=(r-s)/2:n==="end"&&(o-=s);const a=this.getTotalSize()+this.options.scrollMargin-s;return Math.max(Math.min(a,o),0)},this.getOffsetForIndex=(o,n="auto")=>{o=Math.max(0,Math.min(o,this.options.count-1));const r=this.measurementsCache[o];if(!r)return;const s=this.getSize(),l=this.getScrollOffset();if(n==="auto")if(r.end>=l+s-this.options.scrollPaddingEnd)n="end";else if(r.start<=l+this.options.scrollPaddingStart)n="start";else return[l,n];const a=n==="end"?r.end+this.options.scrollPaddingEnd:r.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(a,n,r.size),n]},this.isDynamicMode=()=>this.elementsCache.size>0,this.scrollToOffset=(o,{align:n="start",behavior:r}={})=>{r==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(o,n),{adjustments:void 0,behavior:r})},this.scrollToIndex=(o,{align:n="auto",behavior:r}={})=>{r==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),o=Math.max(0,Math.min(o,this.options.count-1));let s=0;const l=10,a=p=>{if(!this.targetWindow)return;const h=this.getOffsetForIndex(o,p);if(!h){console.warn("Failed to get offset for index:",o);return}const[f,m]=h;this._scrollToOffset(f,{adjustments:void 0,behavior:r}),this.targetWindow.requestAnimationFrame(()=>{const b=this.getScrollOffset(),x=this.getOffsetForIndex(o,m);if(!x){console.warn("Failed to get offset for index:",o);return}rb(x[0],b)||u(m)})},u=p=>{this.targetWindow&&(s++,s<l?this.targetWindow.requestAnimationFrame(()=>a(p)):console.warn(`Failed to scroll to index ${o} after ${l} attempts.`))};a(n)},this.scrollBy=(o,{behavior:n}={})=>{n==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+o,{adjustments:void 0,behavior:n})},this.getTotalSize=()=>{var o;const n=this.getMeasurements();let r;if(n.length===0)r=this.options.paddingStart;else if(this.options.lanes===1)r=((o=n[n.length-1])==null?void 0:o.end)??0;else{const s=Array(this.options.lanes).fill(null);let l=n.length-1;for(;l>=0&&s.some(a=>a===null);){const a=n[l];s[a.lane]===null&&(s[a.lane]=a.end),l--}r=Math.max(...s.filter(a=>a!==null))}return Math.max(r-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(o,{adjustments:n,behavior:r})=>{this.options.scrollToFn(o,{behavior:r,adjustments:n},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(t)}}const Wi=(e,t,o,n)=>{for(;e<=t;){const r=(e+t)/2|0,s=o(r);if(s<n)e=r+1;else if(s>n)t=r-1;else return r}return e>0?e-1:0};function hb({measurements:e,outerSize:t,scrollOffset:o,lanes:n}){const r=e.length-1,s=u=>e[u].start;if(e.length<=n)return{startIndex:0,endIndex:r};let l=Wi(0,r,s,o),a=l;if(n===1)for(;a<r&&e[a].end<o+t;)a++;else if(n>1){const u=Array(n).fill(0);for(;a<r&&u.some(h=>h<o+t);){const h=e[a];u[h.lane]=h.end,a++}const p=Array(n).fill(o+t);for(;l>=0&&p.some(h=>h>=o);){const h=e[l];p[h.lane]=h.start,l--}l=Math.max(0,l-l%n),a=Math.min(r,a+(n-1-a%n))}return{startIndex:l,endIndex:a}}const zr=typeof document<"u"?co.useLayoutEffect:co.useEffect;function fb(e){const t=co.useReducer(()=>({}),{})[1],o={...e,onChange:(r,s)=>{var l;s?Vr.flushSync(t):t(),(l=e.onChange)==null||l.call(e,r,s)}},[n]=co.useState(()=>new pb(o));return n.setOptions(o),zr(()=>n._didMount(),[]),zr(()=>n._willUpdate()),n}function gb(e){return fb({observeElementRect:lb,observeElementOffset:cb,scrollToFn:ub,...e})}const[Pi]=M(["table"]),mb=e=>e.id,bb=({items:e,columns:t,className:o,getRowId:n,emptyState:r,isSortable:s,t:l,onListItemAction:a,renderEmptyAsStandalone:u,...p})=>{const h=d.useRef(null),[f,m]=d.useState([]),b=ke.useReactTable({columns:t,data:e,getCoreRowModel:ke.getCoreRowModel(),getSortedRowModel:s?ke.getSortedRowModel():void 0,getRowId:n??mb,onSortingChange:s?m:void 0,state:{sorting:f}}),x=!b.getRowModel().rows.length;return x&&u?r??null:i.jsx(Bi,{onListItemAction:a,isSortable:s,t:l,children:i.jsx(wb,{className:o,ref:h,children:i.jsxs(Cb,{...p,children:[i.jsx($b,{children:b.getHeaderGroups().map(y=>i.jsx($t,{style:{display:"flex"},children:y.headers.map(k=>i.jsx(d.Fragment,{children:ke.flexRender(k.column.columnDef.header,k.getContext())},k.id))},y.id))}),i.jsx(vb,{isEmpty:x,numColumns:t.length,emptyState:r,table:b,tableContainerRef:h})]})})})},xb=[],yb=W.kosComponent(({dataProvider:e,columns:t,className:o,getRowId:n,emptyState:r,isSortable:s,t:l,TdComponent:a,TrComponent:u,onListItemAction:p,renderEmptyAsStandalone:h,...f})=>(Xt(e),i.jsx(St.Observer,{children:()=>{const m=e?e.items:xb;return i.jsx(bb,{items:m,columns:t,className:o,getRowId:n,emptyState:r,isSortable:s,t:l,onListItemAction:p,renderEmptyAsStandalone:h,...f})}}))),vb=W.kosComponent(({table:e,tableContainerRef:t,trClassName:o,isEmpty:n,emptyState:r,numColumns:s})=>{const{rows:l}=e.getRowModel(),a=gb({count:l.length,estimateSize:()=>33,getScrollElement:()=>t.current,measureElement:typeof window<"u"&&navigator.userAgent.indexOf("Firefox")===-1?u=>u==null?void 0:u.getBoundingClientRect().height:void 0,overscan:5});return i.jsx(Sb,{style:{position:"relative",height:`${a.getTotalSize()}px`},children:n?i.jsx($t,{children:i.jsx(Do,{colSpan:s,children:r??null})}):a.getVirtualItems().map(u=>{const p=l[u.index];return i.jsx(kb,{trClassName:o,row:p,virtualRow:u,rowVirtualizer:a},p.id)})})}),kb=W.kosComponent(({trClassName:e,row:t,virtualRow:o,rowVirtualizer:n})=>i.jsx($t,{"data-index":o.index,ref:r=>n.measureElement(r),className:e,style:{display:"flex",position:"absolute",transform:`translateY(${o.start}px)`,width:"100%"},children:t.getVisibleCells().map(r=>{var s;return i.jsx(Do,{style:{display:"flex",width:((s=r.column.columnDef.meta)==null?void 0:s.width)??r.column.getSize()},children:ke.flexRender(r.column.columnDef.cell,r.getContext())},r.id)})},t.id)),wb=g.div`
3154
+ color: hsl(${Math.max(0,Math.min(120-120*k,120))}deg 100% 31%);`,o==null?void 0:o.key)}return(h=o==null?void 0:o.onChange)==null||h.call(o,r),r}return s.updateDeps=l=>{n=l},s}function Dr(e,t){if(e===void 0)throw new Error("Unexpected undefined");return e}const ab=(e,t)=>Math.abs(e-t)<1.01,lb=(e,t,o)=>{let n;return function(...r){e.clearTimeout(n),n=e.setTimeout(()=>t.apply(this,r),o)}},_r=e=>{const{offsetWidth:t,offsetHeight:o}=e;return{width:t,height:o}},cb=e=>e,db=e=>{const t=Math.max(e.startIndex-e.overscan,0),o=Math.min(e.endIndex+e.overscan,e.count-1),n=[];for(let r=t;r<=o;r++)n.push(r);return n},ub=(e,t)=>{const o=e.scrollElement;if(!o)return;const n=e.targetWindow;if(!n)return;const r=l=>{const{width:a,height:u}=l;t({width:Math.round(a),height:Math.round(u)})};if(r(_r(o)),!n.ResizeObserver)return()=>{};const s=new n.ResizeObserver(l=>{const a=()=>{const u=l[0];if(u!=null&&u.borderBoxSize){const h=u.borderBoxSize[0];if(h){r({width:h.inlineSize,height:h.blockSize});return}}r(_r(o))};e.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(a):a()});return s.observe(o,{box:"border-box"}),()=>{s.unobserve(o)}},Tr={passive:!0},Er=typeof window>"u"?!0:"onscrollend"in window,hb=(e,t)=>{const o=e.scrollElement;if(!o)return;const n=e.targetWindow;if(!n)return;let r=0;const s=e.options.useScrollendEvent&&Er?()=>{}:lb(n,()=>{t(r,!1)},e.options.isScrollingResetDelay),l=p=>()=>{const{horizontal:f,isRtl:m}=e.options;r=f?o.scrollLeft*(m&&-1||1):o.scrollTop,s(),t(r,p)},a=l(!0),u=l(!1);u(),o.addEventListener("scroll",a,Tr);const h=e.options.useScrollendEvent&&Er;return h&&o.addEventListener("scrollend",u,Tr),()=>{o.removeEventListener("scroll",a),h&&o.removeEventListener("scrollend",u)}},pb=(e,t,o)=>{if(t!=null&&t.borderBoxSize){const n=t.borderBoxSize[0];if(n)return Math.round(n[o.options.horizontal?"inlineSize":"blockSize"])}return e[o.options.horizontal?"offsetWidth":"offsetHeight"]},fb=(e,{adjustments:t=0,behavior:o},n)=>{var r,s;const l=e+t;(s=(r=n.scrollElement)==null?void 0:r.scrollTo)==null||s.call(r,{[n.options.horizontal?"left":"top"]:l,behavior:o})};class gb{constructor(t){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.measurementsCache=[],this.itemSizeCache=new Map,this.pendingMeasuredCacheIndexes=[],this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let o=null;const n=()=>o||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:o=new this.targetWindow.ResizeObserver(r=>{r.forEach(s=>{const l=()=>{this._measureElement(s.target,s)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(l):l()})}));return{disconnect:()=>{var r;(r=n())==null||r.disconnect(),o=null},observe:r=>{var s;return(s=n())==null?void 0:s.observe(r,{box:"border-box"})},unobserve:r=>{var s;return(s=n())==null?void 0:s.unobserve(r)}}})(),this.range=null,this.setOptions=o=>{Object.entries(o).forEach(([n,r])=>{typeof r>"u"&&delete o[n]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:cb,rangeExtractor:db,onChange:()=>{},measureElement:pb,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,...o}},this.notify=o=>{var n,r;(r=(n=this.options).onChange)==null||r.call(n,this,o)},this.maybeNotify=vt(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),o=>{this.notify(o)},{key:!1,debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(o=>o()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var o;const n=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==n){if(this.cleanup(),!n){this.maybeNotify();return}this.scrollElement=n,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=((o=this.scrollElement)==null?void 0:o.window)??null,this.elementsCache.forEach(r=>{this.observer.observe(r)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,r=>{this.scrollRect=r,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(r,s)=>{this.scrollAdjustments=0,this.scrollDirection=s?this.getScrollOffset()<r?"forward":"backward":null,this.scrollOffset=r,this.isScrolling=s,this.maybeNotify()}))}},this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??(typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(o,n)=>{const r=new Map,s=new Map;for(let l=n-1;l>=0;l--){const a=o[l];if(r.has(a.lane))continue;const u=s.get(a.lane);if(u==null||a.end>u.end?s.set(a.lane,a):a.end<u.end&&r.set(a.lane,!0),r.size===this.options.lanes)break}return s.size===this.options.lanes?Array.from(s.values()).sort((l,a)=>l.end===a.end?l.index-a.index:l.end-a.end)[0]:void 0},this.getMeasurementOptions=vt(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(o,n,r,s,l)=>(this.pendingMeasuredCacheIndexes=[],{count:o,paddingStart:n,scrollMargin:r,getItemKey:s,enabled:l}),{key:!1}),this.getMeasurements=vt(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:o,paddingStart:n,scrollMargin:r,getItemKey:s,enabled:l},a)=>{if(!l)return this.measurementsCache=[],this.itemSizeCache.clear(),[];this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(p=>{this.itemSizeCache.set(p.key,p.size)}));const u=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];const h=this.measurementsCache.slice(0,u);for(let p=u;p<o;p++){const f=s(p),m=this.options.lanes===1?h[p-1]:this.getFurthestMeasurement(h,p),b=m?m.end+this.options.gap:n+r,x=a.get(f),y=typeof x=="number"?x:this.options.estimateSize(p),k=b+y,v=m?m.lane:p%this.options.lanes;h[p]={index:p,start:b,size:y,end:k,key:f,lane:v}}return this.measurementsCache=h,h},{key:!1,debug:()=>this.options.debug}),this.calculateRange=vt(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(o,n,r,s)=>this.range=o.length>0&&n>0?mb({measurements:o,outerSize:n,scrollOffset:r,lanes:s}):null,{key:!1,debug:()=>this.options.debug}),this.getVirtualIndexes=vt(()=>{let o=null,n=null;const r=this.calculateRange();return r&&(o=r.startIndex,n=r.endIndex),this.maybeNotify.updateDeps([this.isScrolling,o,n]),[this.options.rangeExtractor,this.options.overscan,this.options.count,o,n]},(o,n,r,s,l)=>s===null||l===null?[]:o({startIndex:s,endIndex:l,overscan:n,count:r}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=o=>{const n=this.options.indexAttribute,r=o.getAttribute(n);return r?parseInt(r,10):(console.warn(`Missing attribute name '${n}={index}' on measured element.`),-1)},this._measureElement=(o,n)=>{const r=this.indexFromElement(o),s=this.measurementsCache[r];if(!s)return;const l=s.key,a=this.elementsCache.get(l);a!==o&&(a&&this.observer.unobserve(a),this.observer.observe(o),this.elementsCache.set(l,o)),o.isConnected&&this.resizeItem(r,this.options.measureElement(o,n,this))},this.resizeItem=(o,n)=>{const r=this.measurementsCache[o];if(!r)return;const s=this.itemSizeCache.get(r.key)??r.size,l=n-s;l!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(r,l,this):r.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=l,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(r.index),this.itemSizeCache=new Map(this.itemSizeCache.set(r.key,n)),this.notify(!1))},this.measureElement=o=>{if(!o){this.elementsCache.forEach((n,r)=>{n.isConnected||(this.observer.unobserve(n),this.elementsCache.delete(r))});return}this._measureElement(o,void 0)},this.getVirtualItems=vt(()=>[this.getVirtualIndexes(),this.getMeasurements()],(o,n)=>{const r=[];for(let s=0,l=o.length;s<l;s++){const a=o[s],u=n[a];r.push(u)}return r},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=o=>{const n=this.getMeasurements();if(n.length!==0)return Dr(n[Wi(0,n.length-1,r=>Dr(n[r]).start,o)])},this.getOffsetForAlignment=(o,n,r=0)=>{const s=this.getSize(),l=this.getScrollOffset();n==="auto"&&(n=o>=l+s?"end":"start"),n==="center"?o+=(r-s)/2:n==="end"&&(o-=s);const a=this.getTotalSize()+this.options.scrollMargin-s;return Math.max(Math.min(a,o),0)},this.getOffsetForIndex=(o,n="auto")=>{o=Math.max(0,Math.min(o,this.options.count-1));const r=this.measurementsCache[o];if(!r)return;const s=this.getSize(),l=this.getScrollOffset();if(n==="auto")if(r.end>=l+s-this.options.scrollPaddingEnd)n="end";else if(r.start<=l+this.options.scrollPaddingStart)n="start";else return[l,n];const a=n==="end"?r.end+this.options.scrollPaddingEnd:r.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(a,n,r.size),n]},this.isDynamicMode=()=>this.elementsCache.size>0,this.scrollToOffset=(o,{align:n="start",behavior:r}={})=>{r==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(o,n),{adjustments:void 0,behavior:r})},this.scrollToIndex=(o,{align:n="auto",behavior:r}={})=>{r==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),o=Math.max(0,Math.min(o,this.options.count-1));let s=0;const l=10,a=h=>{if(!this.targetWindow)return;const p=this.getOffsetForIndex(o,h);if(!p){console.warn("Failed to get offset for index:",o);return}const[f,m]=p;this._scrollToOffset(f,{adjustments:void 0,behavior:r}),this.targetWindow.requestAnimationFrame(()=>{const b=this.getScrollOffset(),x=this.getOffsetForIndex(o,m);if(!x){console.warn("Failed to get offset for index:",o);return}ab(x[0],b)||u(m)})},u=h=>{this.targetWindow&&(s++,s<l?this.targetWindow.requestAnimationFrame(()=>a(h)):console.warn(`Failed to scroll to index ${o} after ${l} attempts.`))};a(n)},this.scrollBy=(o,{behavior:n}={})=>{n==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+o,{adjustments:void 0,behavior:n})},this.getTotalSize=()=>{var o;const n=this.getMeasurements();let r;if(n.length===0)r=this.options.paddingStart;else if(this.options.lanes===1)r=((o=n[n.length-1])==null?void 0:o.end)??0;else{const s=Array(this.options.lanes).fill(null);let l=n.length-1;for(;l>=0&&s.some(a=>a===null);){const a=n[l];s[a.lane]===null&&(s[a.lane]=a.end),l--}r=Math.max(...s.filter(a=>a!==null))}return Math.max(r-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(o,{adjustments:n,behavior:r})=>{this.options.scrollToFn(o,{behavior:r,adjustments:n},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(t)}}const Wi=(e,t,o,n)=>{for(;e<=t;){const r=(e+t)/2|0,s=o(r);if(s<n)e=r+1;else if(s>n)t=r-1;else return r}return e>0?e-1:0};function mb({measurements:e,outerSize:t,scrollOffset:o,lanes:n}){const r=e.length-1,s=u=>e[u].start;if(e.length<=n)return{startIndex:0,endIndex:r};let l=Wi(0,r,s,o),a=l;if(n===1)for(;a<r&&e[a].end<o+t;)a++;else if(n>1){const u=Array(n).fill(0);for(;a<r&&u.some(p=>p<o+t);){const p=e[a];u[p.lane]=p.end,a++}const h=Array(n).fill(o+t);for(;l>=0&&h.some(p=>p>=o);){const p=e[l];h[p.lane]=p.start,l--}l=Math.max(0,l-l%n),a=Math.min(r,a+(n-1-a%n))}return{startIndex:l,endIndex:a}}const zr=typeof document<"u"?co.useLayoutEffect:co.useEffect;function bb(e){const t=co.useReducer(()=>({}),{})[1],o={...e,onChange:(r,s)=>{var l;s?Vr.flushSync(t):t(),(l=e.onChange)==null||l.call(e,r,s)}},[n]=co.useState(()=>new gb(o));return n.setOptions(o),zr(()=>n._didMount(),[]),zr(()=>n._willUpdate()),n}function xb(e){return bb({observeElementRect:ub,observeElementOffset:hb,scrollToFn:fb,...e})}const[Pi]=M(["table"]),yb=e=>e.id,vb=({items:e,columns:t,className:o,getRowId:n,emptyState:r,isSortable:s,t:l,onListItemAction:a,renderEmptyAsStandalone:u,...h})=>{const p=d.useRef(null),[f,m]=d.useState([]),b=we.useReactTable({columns:t,data:e,getCoreRowModel:we.getCoreRowModel(),getSortedRowModel:s?we.getSortedRowModel():void 0,getRowId:n??yb,onSortingChange:s?m:void 0,state:{sorting:f}}),x=!b.getRowModel().rows.length;return x&&u?r??null:i.jsx(Bi,{onListItemAction:a,isSortable:s,t:l,children:i.jsx(Sb,{className:o,ref:p,children:i.jsxs(jb,{...h,children:[i.jsx(Ib,{children:b.getHeaderGroups().map(y=>i.jsx($t,{style:{display:"flex"},children:y.headers.map(k=>i.jsx(d.Fragment,{children:we.flexRender(k.column.columnDef.header,k.getContext())},k.id))},y.id))}),i.jsx(Cb,{isEmpty:x,numColumns:t.length,emptyState:r,table:b,tableContainerRef:p})]})})})},kb=[],wb=W.kosComponent(({dataProvider:e,columns:t,className:o,getRowId:n,emptyState:r,isSortable:s,t:l,TdComponent:a,TrComponent:u,onListItemAction:h,renderEmptyAsStandalone:p,...f})=>(Xt(e),i.jsx(St.Observer,{children:()=>{const m=e?e.items:kb;return i.jsx(vb,{items:m,columns:t,className:o,getRowId:n,emptyState:r,isSortable:s,t:l,onListItemAction:h,renderEmptyAsStandalone:p,...f})}}))),Cb=W.kosComponent(({table:e,tableContainerRef:t,trClassName:o,isEmpty:n,emptyState:r,numColumns:s})=>{const{rows:l}=e.getRowModel(),a=xb({count:l.length,estimateSize:()=>33,getScrollElement:()=>t.current,measureElement:typeof window<"u"&&navigator.userAgent.indexOf("Firefox")===-1?u=>u==null?void 0:u.getBoundingClientRect().height:void 0,overscan:5});return i.jsx(Db,{style:{position:"relative",height:`${a.getTotalSize()}px`},children:n?i.jsx($t,{children:i.jsx(Do,{colSpan:s,children:r??null})}):a.getVirtualItems().map(u=>{const h=l[u.index];return i.jsx($b,{trClassName:o,row:h,virtualRow:u,rowVirtualizer:a},h.id)})})}),$b=W.kosComponent(({trClassName:e,row:t,virtualRow:o,rowVirtualizer:n})=>i.jsx($t,{"data-index":o.index,ref:r=>n.measureElement(r),className:e,style:{display:"flex",position:"absolute",transform:`translateY(${o.start}px)`,width:"100%"},children:t.getVisibleCells().map(r=>{var s;return i.jsx(Do,{style:{display:"flex",width:((s=r.column.columnDef.meta)==null?void 0:s.width)??r.column.getSize()},children:we.flexRender(r.column.columnDef.cell,r.getContext())},r.id)})},t.id)),Sb=g.div`
3149
3155
  width: 100%;
3150
3156
  display: grid;
3151
3157
  overflow: auto;
3152
- `,Cb=g.table`
3158
+ `,jb=g.table`
3153
3159
  width: 100%;
3154
3160
  border-collapse: collapse;
3155
3161
  font-family: ${Pi("font-family")};
3156
3162
  table-layout: fixed;
3157
- `,$b=g.thead`
3163
+ `,Ib=g.thead`
3158
3164
  width: 100%;
3159
3165
  position: sticky;
3160
3166
  background-color: ${Pi("header-background-color")};
3161
3167
  top: 0;
3162
3168
  z-index: 1;
3163
- `,Sb=g.tbody`
3169
+ `,Db=g.tbody`
3164
3170
  width: 100%;
3165
- `,[kt]=M(["button"]),jb=d.memo(({onClick:e,open:t,buttonText:o,text:n})=>i.jsx(Ib,{open:t,children:i.jsxs(Db,{children:[i.jsx(E,{variant:"h2",color:"light",children:n}),i.jsx(Ge,{variant:"borderless",text:o,onClick:e})]})})),Ib=g(Os)`
3171
+ `,[kt]=M(["button"]),_b=d.memo(({onClick:e,open:t,buttonText:o,text:n})=>i.jsx(Tb,{open:t,children:i.jsxs(Eb,{children:[i.jsx(E,{variant:"h2",color:"light",children:n}),i.jsx(Ke,{variant:"borderless",text:o,onClick:e})]})})),Tb=g(Os)`
3166
3172
  z-index: 5;
3167
- `,Db=g.div`
3173
+ `,Eb=g.div`
3168
3174
  display: flex;
3169
3175
  align-items: center;
3170
3176
  justify-content: center;
@@ -3176,9 +3182,9 @@
3176
3182
  ${`${kt("border-hover-borderless",!0)}: ${c("color-white")}`};
3177
3183
  ${`${kt("color-hover-borderless",!0)}: ${c("color-white")}`};
3178
3184
  ${`${kt("bg-hover-borderless",!0)}: transparent`};
3179
- `;function _b(e,t,o="long"){return new Intl.DateTimeFormat("en-US",{hour:"numeric",timeZone:e,timeZoneName:o}).format(t).split(/\s/g).slice(2).join(" ")}const Vo={},Lt={};function gt(e,t){try{const n=(Vo[e]||(Vo[e]=new Intl.DateTimeFormat("en-US",{timeZone:e,timeZoneName:"longOffset"}).format))(t).split("GMT")[1];return n in Lt?Lt[n]:Mr(n,n.split(":"))}catch{if(e in Lt)return Lt[e];const o=e==null?void 0:e.match(Tb);return o?Mr(e,o.slice(1)):NaN}}const Tb=/([+-]\d\d):?(\d\d)?/;function Mr(e,t){const o=+(t[0]||0),n=+(t[1]||0),r=+(t[2]||0)/60;return Lt[e]=o*60+n>0?o*60+n+r:o*60-n-r}class He extends Date{constructor(...t){super(),t.length>1&&typeof t[t.length-1]=="string"&&(this.timeZone=t.pop()),this.internal=new Date,isNaN(gt(this.timeZone,this))?this.setTime(NaN):t.length?typeof t[0]=="number"&&(t.length===1||t.length===2&&typeof t[1]!="number")?this.setTime(t[0]):typeof t[0]=="string"?this.setTime(+new Date(t[0])):t[0]instanceof Date?this.setTime(+t[0]):(this.setTime(+new Date(...t)),Vi(this),cn(this)):this.setTime(Date.now())}static tz(t,...o){return o.length?new He(...o,t):new He(Date.now(),t)}withTimeZone(t){return new He(+this,t)}getTimezoneOffset(){const t=-gt(this.timeZone,this);return t>0?Math.floor(t):Math.ceil(t)}setTime(t){return Date.prototype.setTime.apply(this,arguments),cn(this),+this}[Symbol.for("constructDateFrom")](t){return new He(+new Date(t),this.timeZone)}}const Or=/^(get|set)(?!UTC)/;Object.getOwnPropertyNames(Date.prototype).forEach(e=>{if(!Or.test(e))return;const t=e.replace(Or,"$1UTC");He.prototype[t]&&(e.startsWith("get")?He.prototype[e]=function(){return this.internal[t]()}:(He.prototype[e]=function(){return Date.prototype[t].apply(this.internal,arguments),Eb(this),+this},He.prototype[t]=function(){return Date.prototype[t].apply(this,arguments),cn(this),+this}))});function cn(e){e.internal.setTime(+e),e.internal.setUTCSeconds(e.internal.getUTCSeconds()-Math.round(-gt(e.timeZone,e)*60))}function Eb(e){Date.prototype.setFullYear.call(e,e.internal.getUTCFullYear(),e.internal.getUTCMonth(),e.internal.getUTCDate()),Date.prototype.setHours.call(e,e.internal.getUTCHours(),e.internal.getUTCMinutes(),e.internal.getUTCSeconds(),e.internal.getUTCMilliseconds()),Vi(e)}function Vi(e){const t=gt(e.timeZone,e),o=t>0?Math.floor(t):Math.ceil(t),n=new Date(+e);n.setUTCHours(n.getUTCHours()-1);const r=-new Date(+e).getTimezoneOffset(),s=-new Date(+n).getTimezoneOffset(),l=r-s,a=Date.prototype.getHours.apply(e)!==e.internal.getUTCHours();l&&a&&e.internal.setUTCMinutes(e.internal.getUTCMinutes()+l);const u=r-o;u&&Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+u);const p=new Date(+e);p.setUTCSeconds(0);const h=r>0?p.getSeconds():(p.getSeconds()-60)%60,f=Math.round(-(gt(e.timeZone,e)*60))%60;(f||h)&&(e.internal.setUTCSeconds(e.internal.getUTCSeconds()+f),Date.prototype.setUTCSeconds.call(e,Date.prototype.getUTCSeconds.call(e)+f+h));const m=gt(e.timeZone,e),b=m>0?Math.floor(m):Math.ceil(m),y=-new Date(+e).getTimezoneOffset()-b,k=b!==o,v=y-u;if(k&&v){Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+v);const $=gt(e.timeZone,e),C=$>0?Math.floor($):Math.ceil($),S=b-C;S&&(e.internal.setUTCMinutes(e.internal.getUTCMinutes()+S),Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+S))}}class ce extends He{static tz(t,...o){return o.length?new ce(...o,t):new ce(Date.now(),t)}toISOString(){const[t,o,n]=this.tzComponents(),r=`${t}${o}:${n}`;return this.internal.toISOString().slice(0,-1)+r}toString(){return`${this.toDateString()} ${this.toTimeString()}`}toDateString(){const[t,o,n,r]=this.internal.toUTCString().split(" ");return`${t==null?void 0:t.slice(0,-1)} ${n} ${o} ${r}`}toTimeString(){const t=this.internal.toUTCString().split(" ")[4],[o,n,r]=this.tzComponents();return`${t} GMT${o}${n}${r} (${_b(this.timeZone,this)})`}toLocaleString(t,o){return Date.prototype.toLocaleString.call(this,t,{...o,timeZone:(o==null?void 0:o.timeZone)||this.timeZone})}toLocaleDateString(t,o){return Date.prototype.toLocaleDateString.call(this,t,{...o,timeZone:(o==null?void 0:o.timeZone)||this.timeZone})}toLocaleTimeString(t,o){return Date.prototype.toLocaleTimeString.call(this,t,{...o,timeZone:(o==null?void 0:o.timeZone)||this.timeZone})}tzComponents(){const t=this.getTimezoneOffset(),o=t>0?"-":"+",n=String(Math.floor(Math.abs(t)/60)).padStart(2,"0"),r=String(Math.abs(t)%60).padStart(2,"0");return[o,n,r]}withTimeZone(t){return new ce(+this,t)}[Symbol.for("constructDateFrom")](t){return new ce(+new Date(t),this.timeZone)}}const zb={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Mb=(e,t,o)=>{let n;const r=zb[e];return typeof r=="string"?n=r:t===1?n=r.one:n=r.other.replace("{{count}}",t.toString()),o!=null&&o.addSuffix?o.comparison&&o.comparison>0?"in "+n:n+" ago":n};function Ho(e){return(t={})=>{const o=t.width?String(t.width):e.defaultWidth;return e.formats[o]||e.formats[e.defaultWidth]}}const Ob={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Rb={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Nb={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Fb={date:Ho({formats:Ob,defaultWidth:"full"}),time:Ho({formats:Rb,defaultWidth:"full"}),dateTime:Ho({formats:Nb,defaultWidth:"full"})},Ab={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Lb=(e,t,o,n)=>Ab[e];function Ft(e){return(t,o)=>{const n=o!=null&&o.context?String(o.context):"standalone";let r;if(n==="formatting"&&e.formattingValues){const l=e.defaultFormattingWidth||e.defaultWidth,a=o!=null&&o.width?String(o.width):l;r=e.formattingValues[a]||e.formattingValues[l]}else{const l=e.defaultWidth,a=o!=null&&o.width?String(o.width):e.defaultWidth;r=e.values[a]||e.values[l]}const s=e.argumentCallback?e.argumentCallback(t):t;return r[s]}}const Bb={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Wb={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Pb={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Vb={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Hb={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},Ub={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},Gb=(e,t)=>{const o=Number(e),n=o%100;if(n>20||n<10)switch(n%10){case 1:return o+"st";case 2:return o+"nd";case 3:return o+"rd"}return o+"th"},Kb={ordinalNumber:Gb,era:Ft({values:Bb,defaultWidth:"wide"}),quarter:Ft({values:Wb,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Ft({values:Pb,defaultWidth:"wide"}),day:Ft({values:Vb,defaultWidth:"wide"}),dayPeriod:Ft({values:Hb,defaultWidth:"wide",formattingValues:Ub,defaultFormattingWidth:"wide"})};function At(e){return(t,o={})=>{const n=o.width,r=n&&e.matchPatterns[n]||e.matchPatterns[e.defaultMatchWidth],s=t.match(r);if(!s)return null;const l=s[0],a=n&&e.parsePatterns[n]||e.parsePatterns[e.defaultParseWidth],u=Array.isArray(a)?qb(a,f=>f.test(l)):Yb(a,f=>f.test(l));let p;p=e.valueCallback?e.valueCallback(u):u,p=o.valueCallback?o.valueCallback(p):p;const h=t.slice(l.length);return{value:p,rest:h}}}function Yb(e,t){for(const o in e)if(Object.prototype.hasOwnProperty.call(e,o)&&t(e[o]))return o}function qb(e,t){for(let o=0;o<e.length;o++)if(t(e[o]))return o}function Zb(e){return(t,o={})=>{const n=t.match(e.matchPattern);if(!n)return null;const r=n[0],s=t.match(e.parsePattern);if(!s)return null;let l=e.valueCallback?e.valueCallback(s[0]):s[0];l=o.valueCallback?o.valueCallback(l):l;const a=t.slice(r.length);return{value:l,rest:a}}}const Xb=/^(\d+)(th|st|nd|rd)?/i,Jb=/\d+/i,Qb={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},ex={any:[/^b/i,/^(a|c)/i]},tx={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},ox={any:[/1/i,/2/i,/3/i,/4/i]},nx={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},rx={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},sx={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},ix={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},ax={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},lx={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},cx={ordinalNumber:Zb({matchPattern:Xb,parsePattern:Jb,valueCallback:e=>parseInt(e,10)}),era:At({matchPatterns:Qb,defaultMatchWidth:"wide",parsePatterns:ex,defaultParseWidth:"any"}),quarter:At({matchPatterns:tx,defaultMatchWidth:"wide",parsePatterns:ox,defaultParseWidth:"any",valueCallback:e=>e+1}),month:At({matchPatterns:nx,defaultMatchWidth:"wide",parsePatterns:rx,defaultParseWidth:"any"}),day:At({matchPatterns:sx,defaultMatchWidth:"wide",parsePatterns:ix,defaultParseWidth:"any"}),dayPeriod:At({matchPatterns:ax,defaultMatchWidth:"any",parsePatterns:lx,defaultParseWidth:"any"})},Hi={code:"en-US",formatDistance:Mb,formatLong:Fb,formatRelative:Lb,localize:Kb,match:cx,options:{weekStartsOn:0,firstWeekContainsDate:1}},Rr=5,dx=4;function ux(e,t){const o=t.startOfMonth(e),n=o.getDay()>0?o.getDay():7,r=t.addDays(e,-n+1),s=t.addDays(r,Rr*7-1);return t.getMonth(e)===t.getMonth(s)?Rr:dx}function Ui(e,t){const o=t.startOfMonth(e),n=o.getDay();return n===1?o:n===0?t.addDays(o,-1*6):t.addDays(o,-1*(n-1))}function px(e,t){const o=Ui(e,t),n=ux(e,t);return t.addDays(o,n*7-1)}class st{constructor(t,o){this.Date=Date,this.today=()=>{var n;return(n=this.overrides)!=null&&n.today?this.overrides.today():this.options.timeZone?ce.tz(this.options.timeZone):new this.Date},this.newDate=(n,r,s)=>{var l;return(l=this.overrides)!=null&&l.newDate?this.overrides.newDate(n,r,s):this.options.timeZone?new ce(n,r,s,this.options.timeZone):new Date(n,r,s)},this.addDays=(n,r)=>{var s;return(s=this.overrides)!=null&&s.addDays?this.overrides.addDays(n,r):Y.addDays(n,r)},this.addMonths=(n,r)=>{var s;return(s=this.overrides)!=null&&s.addMonths?this.overrides.addMonths(n,r):Y.addMonths(n,r)},this.addWeeks=(n,r)=>{var s;return(s=this.overrides)!=null&&s.addWeeks?this.overrides.addWeeks(n,r):Y.addWeeks(n,r)},this.addYears=(n,r)=>{var s;return(s=this.overrides)!=null&&s.addYears?this.overrides.addYears(n,r):Y.addYears(n,r)},this.differenceInCalendarDays=(n,r)=>{var s;return(s=this.overrides)!=null&&s.differenceInCalendarDays?this.overrides.differenceInCalendarDays(n,r):Y.differenceInCalendarDays(n,r)},this.differenceInCalendarMonths=(n,r)=>{var s;return(s=this.overrides)!=null&&s.differenceInCalendarMonths?this.overrides.differenceInCalendarMonths(n,r):Y.differenceInCalendarMonths(n,r)},this.eachMonthOfInterval=n=>{var r;return(r=this.overrides)!=null&&r.eachMonthOfInterval?this.overrides.eachMonthOfInterval(n):Y.eachMonthOfInterval(n)},this.endOfBroadcastWeek=n=>{var r;return(r=this.overrides)!=null&&r.endOfBroadcastWeek?this.overrides.endOfBroadcastWeek(n):px(n,this)},this.endOfISOWeek=n=>{var r;return(r=this.overrides)!=null&&r.endOfISOWeek?this.overrides.endOfISOWeek(n):Y.endOfISOWeek(n)},this.endOfMonth=n=>{var r;return(r=this.overrides)!=null&&r.endOfMonth?this.overrides.endOfMonth(n):Y.endOfMonth(n)},this.endOfWeek=(n,r)=>{var s;return(s=this.overrides)!=null&&s.endOfWeek?this.overrides.endOfWeek(n,r):Y.endOfWeek(n,this.options)},this.endOfYear=n=>{var r;return(r=this.overrides)!=null&&r.endOfYear?this.overrides.endOfYear(n):Y.endOfYear(n)},this.format=(n,r,s)=>{var a;const l=(a=this.overrides)!=null&&a.format?this.overrides.format(n,r,this.options):Y.format(n,r,this.options);return this.options.numerals&&this.options.numerals!=="latn"?this.replaceDigits(l):l},this.getISOWeek=n=>{var r;return(r=this.overrides)!=null&&r.getISOWeek?this.overrides.getISOWeek(n):Y.getISOWeek(n)},this.getMonth=(n,r)=>{var s;return(s=this.overrides)!=null&&s.getMonth?this.overrides.getMonth(n,this.options):Y.getMonth(n,this.options)},this.getYear=(n,r)=>{var s;return(s=this.overrides)!=null&&s.getYear?this.overrides.getYear(n,this.options):Y.getYear(n,this.options)},this.getWeek=(n,r)=>{var s;return(s=this.overrides)!=null&&s.getWeek?this.overrides.getWeek(n,this.options):Y.getWeek(n,this.options)},this.isAfter=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isAfter?this.overrides.isAfter(n,r):Y.isAfter(n,r)},this.isBefore=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isBefore?this.overrides.isBefore(n,r):Y.isBefore(n,r)},this.isDate=n=>{var r;return(r=this.overrides)!=null&&r.isDate?this.overrides.isDate(n):Y.isDate(n)},this.isSameDay=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isSameDay?this.overrides.isSameDay(n,r):Y.isSameDay(n,r)},this.isSameMonth=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isSameMonth?this.overrides.isSameMonth(n,r):Y.isSameMonth(n,r)},this.isSameYear=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isSameYear?this.overrides.isSameYear(n,r):Y.isSameYear(n,r)},this.max=n=>{var r;return(r=this.overrides)!=null&&r.max?this.overrides.max(n):Y.max(n)},this.min=n=>{var r;return(r=this.overrides)!=null&&r.min?this.overrides.min(n):Y.min(n)},this.setMonth=(n,r)=>{var s;return(s=this.overrides)!=null&&s.setMonth?this.overrides.setMonth(n,r):Y.setMonth(n,r)},this.setYear=(n,r)=>{var s;return(s=this.overrides)!=null&&s.setYear?this.overrides.setYear(n,r):Y.setYear(n,r)},this.startOfBroadcastWeek=(n,r)=>{var s;return(s=this.overrides)!=null&&s.startOfBroadcastWeek?this.overrides.startOfBroadcastWeek(n,this):Ui(n,this)},this.startOfDay=n=>{var r;return(r=this.overrides)!=null&&r.startOfDay?this.overrides.startOfDay(n):Y.startOfDay(n)},this.startOfISOWeek=n=>{var r;return(r=this.overrides)!=null&&r.startOfISOWeek?this.overrides.startOfISOWeek(n):Y.startOfISOWeek(n)},this.startOfMonth=n=>{var r;return(r=this.overrides)!=null&&r.startOfMonth?this.overrides.startOfMonth(n):Y.startOfMonth(n)},this.startOfWeek=(n,r)=>{var s;return(s=this.overrides)!=null&&s.startOfWeek?this.overrides.startOfWeek(n,this.options):Y.startOfWeek(n,this.options)},this.startOfYear=n=>{var r;return(r=this.overrides)!=null&&r.startOfYear?this.overrides.startOfYear(n):Y.startOfYear(n)},this.options={locale:Hi,...t},this.overrides=o}getDigitMap(){const{numerals:t="latn"}=this.options,o=new Intl.NumberFormat("en-US",{numberingSystem:t}),n={};for(let r=0;r<10;r++)n[r.toString()]=o.format(r);return n}replaceDigits(t){const o=this.getDigitMap();return t.replace(/\d/g,n=>o[n]||n)}formatNumber(t){return this.replaceDigits(t.toString())}}const qe=new st;class Gi{constructor(t,o,n=qe){this.date=t,this.displayMonth=o,this.outside=!!(o&&!n.isSameMonth(t,o)),this.dateLib=n}isEqualTo(t){return this.dateLib.isSameDay(t.date,this.date)&&this.dateLib.isSameMonth(t.displayMonth,this.displayMonth)}}class hx{constructor(t,o){this.date=t,this.weeks=o}}class fx{constructor(t,o){this.days=o,this.weekNumber=t}}function gx(e){return d.createElement("button",{...e})}function mx(e){return d.createElement("span",{...e})}function bx(e){const{size:t=24,orientation:o="left",className:n}=e;return d.createElement("svg",{className:n,width:t,height:t,viewBox:"0 0 24 24"},o==="up"&&d.createElement("polygon",{points:"6.77 17 12.5 11.43 18.24 17 20 15.28 12.5 8 5 15.28"}),o==="down"&&d.createElement("polygon",{points:"6.77 8 12.5 13.57 18.24 8 20 9.72 12.5 17 5 9.72"}),o==="left"&&d.createElement("polygon",{points:"16 18.112 9.81111111 12 16 5.87733333 14.0888889 4 6 12 14.0888889 20"}),o==="right"&&d.createElement("polygon",{points:"8 18.112 14.18888889 12 8 5.87733333 9.91111111 4 18 12 9.91111111 20"}))}function xx(e){const{day:t,modifiers:o,...n}=e;return d.createElement("td",{...n})}function yx(e){const{day:t,modifiers:o,...n}=e,r=d.useRef(null);return d.useEffect(()=>{var s;o.focused&&((s=r.current)==null||s.focus())},[o.focused]),d.createElement("button",{ref:r,...n})}var A;(function(e){e.Root="root",e.Chevron="chevron",e.Day="day",e.DayButton="day_button",e.CaptionLabel="caption_label",e.Dropdowns="dropdowns",e.Dropdown="dropdown",e.DropdownRoot="dropdown_root",e.Footer="footer",e.MonthGrid="month_grid",e.MonthCaption="month_caption",e.MonthsDropdown="months_dropdown",e.Month="month",e.Months="months",e.Nav="nav",e.NextMonthButton="button_next",e.PreviousMonthButton="button_previous",e.Week="week",e.Weeks="weeks",e.Weekday="weekday",e.Weekdays="weekdays",e.WeekNumber="week_number",e.WeekNumberHeader="week_number_header",e.YearsDropdown="years_dropdown"})(A||(A={}));var se;(function(e){e.disabled="disabled",e.hidden="hidden",e.outside="outside",e.focused="focused",e.today="today"})(se||(se={}));var Ne;(function(e){e.range_end="range_end",e.range_middle="range_middle",e.range_start="range_start",e.selected="selected"})(Ne||(Ne={}));var ge;(function(e){e.weeks_before_enter="weeks_before_enter",e.weeks_before_exit="weeks_before_exit",e.weeks_after_enter="weeks_after_enter",e.weeks_after_exit="weeks_after_exit",e.caption_after_enter="caption_after_enter",e.caption_after_exit="caption_after_exit",e.caption_before_enter="caption_before_enter",e.caption_before_exit="caption_before_exit"})(ge||(ge={}));function vx(e){const{options:t,className:o,components:n,classNames:r,...s}=e,l=[r[A.Dropdown],o].join(" "),a=t==null?void 0:t.find(({value:u})=>u===s.value);return d.createElement("span",{"data-disabled":s.disabled,className:r[A.DropdownRoot]},d.createElement(n.Select,{className:l,...s},t==null?void 0:t.map(({value:u,label:p,disabled:h})=>d.createElement(n.Option,{key:u,value:u,disabled:h},p))),d.createElement("span",{className:r[A.CaptionLabel],"aria-hidden":!0},a==null?void 0:a.label,d.createElement(n.Chevron,{orientation:"down",size:18,className:r[A.Chevron]})))}function kx(e){return d.createElement("div",{...e})}function wx(e){return d.createElement("div",{...e})}function Cx(e){const{calendarMonth:t,displayIndex:o,...n}=e;return d.createElement("div",{...n},e.children)}function $x(e){const{calendarMonth:t,displayIndex:o,...n}=e;return d.createElement("div",{...n})}function Sx(e){return d.createElement("table",{...e})}function jx(e){return d.createElement("div",{...e})}const Ki=d.createContext(void 0);function eo(){const e=d.useContext(Ki);if(e===void 0)throw new Error("useDayPicker() must be used within a custom component.");return e}function Ix(e){const{components:t}=eo();return d.createElement(t.Dropdown,{...e})}function Dx(e){const{onPreviousClick:t,onNextClick:o,previousMonth:n,nextMonth:r,...s}=e,{components:l,classNames:a,labels:{labelPrevious:u,labelNext:p}}=eo(),h=d.useCallback(m=>{r&&(o==null||o(m))},[r,o]),f=d.useCallback(m=>{n&&(t==null||t(m))},[n,t]);return d.createElement("nav",{...s},d.createElement(l.PreviousMonthButton,{type:"button",className:a[A.PreviousMonthButton],tabIndex:n?void 0:-1,"aria-disabled":n?void 0:!0,"aria-label":u(n),onClick:f},d.createElement(l.Chevron,{disabled:n?void 0:!0,className:a[A.Chevron],orientation:"left"})),d.createElement(l.NextMonthButton,{type:"button",className:a[A.NextMonthButton],tabIndex:r?void 0:-1,"aria-disabled":r?void 0:!0,"aria-label":p(r),onClick:h},d.createElement(l.Chevron,{disabled:r?void 0:!0,orientation:"right",className:a[A.Chevron]})))}function _x(e){const{components:t}=eo();return d.createElement(t.Button,{...e})}function Tx(e){return d.createElement("option",{...e})}function Ex(e){const{components:t}=eo();return d.createElement(t.Button,{...e})}function zx(e){const{rootRef:t,...o}=e;return d.createElement("div",{...o,ref:t})}function Mx(e){return d.createElement("select",{...e})}function Ox(e){const{week:t,...o}=e;return d.createElement("tr",{...o})}function Rx(e){return d.createElement("th",{...e})}function Nx(e){return d.createElement("thead",{"aria-hidden":!0},d.createElement("tr",{...e}))}function Fx(e){const{week:t,...o}=e;return d.createElement("th",{...o})}function Ax(e){return d.createElement("th",{...e})}function Lx(e){return d.createElement("tbody",{...e})}function Bx(e){const{components:t}=eo();return d.createElement(t.Dropdown,{...e})}const Wx=Object.freeze(Object.defineProperty({__proto__:null,Button:gx,CaptionLabel:mx,Chevron:bx,Day:xx,DayButton:yx,Dropdown:vx,DropdownNav:kx,Footer:wx,Month:Cx,MonthCaption:$x,MonthGrid:Sx,Months:jx,MonthsDropdown:Ix,Nav:Dx,NextMonthButton:_x,Option:Tx,PreviousMonthButton:Ex,Root:zx,Select:Mx,Week:Ox,WeekNumber:Fx,WeekNumberHeader:Ax,Weekday:Rx,Weekdays:Nx,Weeks:Lx,YearsDropdown:Bx},Symbol.toStringTag,{value:"Module"}));function et(e,t,o=!1,n=qe){let{from:r,to:s}=e;const{differenceInCalendarDays:l,isSameDay:a}=n;return r&&s?(l(s,r)<0&&([r,s]=[s,r]),l(t,r)>=(o?1:0)&&l(s,t)>=(o?1:0)):!o&&s?a(s,t):!o&&r?a(r,t):!1}function Yi(e){return!!(e&&typeof e=="object"&&"before"in e&&"after"in e)}function qn(e){return!!(e&&typeof e=="object"&&"from"in e)}function qi(e){return!!(e&&typeof e=="object"&&"after"in e)}function Zi(e){return!!(e&&typeof e=="object"&&"before"in e)}function Xi(e){return!!(e&&typeof e=="object"&&"dayOfWeek"in e)}function Ji(e,t){return Array.isArray(e)&&e.every(t.isDate)}function tt(e,t,o=qe){const n=Array.isArray(t)?t:[t],{isSameDay:r,differenceInCalendarDays:s,isAfter:l}=o;return n.some(a=>{if(typeof a=="boolean")return a;if(o.isDate(a))return r(e,a);if(Ji(a,o))return a.includes(e);if(qn(a))return et(a,e,!1,o);if(Xi(a))return Array.isArray(a.dayOfWeek)?a.dayOfWeek.includes(e.getDay()):a.dayOfWeek===e.getDay();if(Yi(a)){const u=s(a.before,e),p=s(a.after,e),h=u>0,f=p<0;return l(a.before,a.after)?f&&h:h||f}return qi(a)?s(e,a.after)>0:Zi(a)?s(a.before,e)>0:typeof a=="function"?a(e):!1})}function Px(e,t,o,n,r){const{disabled:s,hidden:l,modifiers:a,showOutsideDays:u,broadcastCalendar:p,today:h}=t,{isSameDay:f,isSameMonth:m,startOfMonth:b,isBefore:x,endOfMonth:y,isAfter:k}=r,v=o&&b(o),$=n&&y(n),C={[se.focused]:[],[se.outside]:[],[se.disabled]:[],[se.hidden]:[],[se.today]:[]},S={};for(const w of e){const{date:I,displayMonth:j}=w,D=!!(j&&!m(I,j)),L=!!(v&&x(I,v)),U=!!($&&k(I,$)),P=!!(s&&tt(I,s,r)),B=!!(l&&tt(I,l,r))||L||U||!p&&!u&&D||p&&u===!1&&D,Z=f(I,h??r.today());D&&C.outside.push(w),P&&C.disabled.push(w),B&&C.hidden.push(w),Z&&C.today.push(w),a&&Object.keys(a).forEach(ie=>{const J=a==null?void 0:a[ie];J&&tt(I,J,r)&&(S[ie]?S[ie].push(w):S[ie]=[w])})}return w=>{const I={[se.focused]:!1,[se.disabled]:!1,[se.hidden]:!1,[se.outside]:!1,[se.today]:!1},j={};for(const D in C){const L=C[D];I[D]=L.some(U=>U===w)}for(const D in S)j[D]=S[D].some(L=>L===w);return{...I,...j}}}function Vx(e,t,o={}){return Object.entries(e).filter(([,r])=>r===!0).reduce((r,[s])=>(o[s]?r.push(o[s]):t[se[s]]?r.push(t[se[s]]):t[Ne[s]]&&r.push(t[Ne[s]]),r),[t[A.Day]])}function Hx(e){return{...Wx,...e}}function Ux(e){const t={"data-mode":e.mode??void 0,"data-required":"required"in e?e.required:void 0,"data-multiple-months":e.numberOfMonths&&e.numberOfMonths>1||void 0,"data-week-numbers":e.showWeekNumber||void 0,"data-broadcast-calendar":e.broadcastCalendar||void 0,"data-nav-layout":e.navLayout||void 0};return Object.entries(e).forEach(([o,n])=>{o.startsWith("data-")&&(t[o]=n)}),t}function Gx(){const e={};for(const t in A)e[A[t]]=`rdp-${A[t]}`;for(const t in se)e[se[t]]=`rdp-${se[t]}`;for(const t in Ne)e[Ne[t]]=`rdp-${Ne[t]}`;for(const t in ge)e[ge[t]]=`rdp-${ge[t]}`;return e}function Qi(e,t,o){return(o??new st(t)).format(e,"LLLL y")}const Kx=Qi;function Yx(e,t,o){return(o??new st(t)).format(e,"d")}function qx(e,t=qe){return t.format(e,"LLLL")}function Zx(e,t,o){return(o??new st(t)).format(e,"cccccc")}function Xx(e,t=qe){return e<10?t.formatNumber(`0${e.toLocaleString()}`):t.formatNumber(`${e.toLocaleString()}`)}function Jx(){return""}function ea(e,t=qe){return t.format(e,"yyyy")}const Qx=ea,e0=Object.freeze(Object.defineProperty({__proto__:null,formatCaption:Qi,formatDay:Yx,formatMonthCaption:Kx,formatMonthDropdown:qx,formatWeekNumber:Xx,formatWeekNumberHeader:Jx,formatWeekdayName:Zx,formatYearCaption:Qx,formatYearDropdown:ea},Symbol.toStringTag,{value:"Module"}));function t0(e){return e!=null&&e.formatMonthCaption&&!e.formatCaption&&(e.formatCaption=e.formatMonthCaption),e!=null&&e.formatYearCaption&&!e.formatYearDropdown&&(e.formatYearDropdown=e.formatYearCaption),{...e0,...e}}function o0(e,t,o,n,r){const{startOfMonth:s,startOfYear:l,endOfYear:a,eachMonthOfInterval:u,getMonth:p}=r;return u({start:l(e),end:a(e)}).map(m=>{const b=n.formatMonthDropdown(m,r),x=p(m),y=t&&m<s(t)||o&&m>s(o)||!1;return{value:x,label:b,disabled:y}})}function n0(e,t={},o={}){let n={...t==null?void 0:t[A.Day]};return Object.entries(e).filter(([,r])=>r===!0).forEach(([r])=>{n={...n,...o==null?void 0:o[r]}}),n}function r0(e,t,o){const n=e.today(),r=t?e.startOfISOWeek(n):e.startOfWeek(n),s=[];for(let l=0;l<7;l++){const a=e.addDays(r,l);s.push(a)}return s}function s0(e,t,o,n,r=!1){if(!e||!t)return;const{startOfYear:s,endOfYear:l,addYears:a,getYear:u,isBefore:p,isSameYear:h}=n,f=s(e),m=l(t),b=[];let x=f;for(;p(x,m)||h(x,m);)b.push(x),x=a(x,1);return r&&b.reverse(),b.map(y=>{const k=o.formatYearDropdown(y,n);return{value:u(y),label:k,disabled:!1}})}function ta(e,t,o,n){let r=(n??new st(o)).format(e,"PPPP");return t.today&&(r=`Today, ${r}`),t.selected&&(r=`${r}, selected`),r}const i0=ta;function oa(e,t,o){return(o??new st(t)).format(e,"LLLL y")}const a0=oa;function l0(e,t,o,n){let r=(n??new st(o)).format(e,"PPPP");return t!=null&&t.today&&(r=`Today, ${r}`),r}function c0(e){return"Choose the Month"}function d0(){return""}function u0(e){return"Go to the Next Month"}function p0(e){return"Go to the Previous Month"}function h0(e,t,o){return(o??new st(t)).format(e,"cccc")}function f0(e,t){return`Week ${e}`}function g0(e){return"Week Number"}function m0(e){return"Choose the Year"}const b0=Object.freeze(Object.defineProperty({__proto__:null,labelCaption:a0,labelDay:i0,labelDayButton:ta,labelGrid:oa,labelGridcell:l0,labelMonthDropdown:c0,labelNav:d0,labelNext:u0,labelPrevious:p0,labelWeekNumber:f0,labelWeekNumberHeader:g0,labelWeekday:h0,labelYearDropdown:m0},Symbol.toStringTag,{value:"Module"})),to=e=>e instanceof HTMLElement?e:null,Uo=e=>[...e.querySelectorAll("[data-animated-month]")??[]],x0=e=>to(e.querySelector("[data-animated-month]")),Go=e=>to(e.querySelector("[data-animated-caption]")),Ko=e=>to(e.querySelector("[data-animated-weeks]")),y0=e=>to(e.querySelector("[data-animated-nav]")),v0=e=>to(e.querySelector("[data-animated-weekdays]"));function k0(e,t,{classNames:o,months:n,focused:r,dateLib:s}){const l=d.useRef(null),a=d.useRef(n),u=d.useRef(!1);d.useLayoutEffect(()=>{const p=a.current;if(a.current=n,!t||!e.current||!(e.current instanceof HTMLElement)||n.length===0||p.length===0||n.length!==p.length)return;const h=s.isSameMonth(n[0].date,p[0].date),f=s.isAfter(n[0].date,p[0].date),m=f?o[ge.caption_after_enter]:o[ge.caption_before_enter],b=f?o[ge.weeks_after_enter]:o[ge.weeks_before_enter],x=l.current,y=e.current.cloneNode(!0);if(y instanceof HTMLElement?(Uo(y).forEach(C=>{if(!(C instanceof HTMLElement))return;const S=x0(C);S&&C.contains(S)&&C.removeChild(S);const w=Go(C);w&&w.classList.remove(m);const I=Ko(C);I&&I.classList.remove(b)}),l.current=y):l.current=null,u.current||h||r)return;const k=x instanceof HTMLElement?Uo(x):[],v=Uo(e.current);if(v!=null&&v.every($=>$ instanceof HTMLElement)&&k&&k.every($=>$ instanceof HTMLElement)){u.current=!0,e.current.style.isolation="isolate";const $=y0(e.current);$&&($.style.zIndex="1"),v.forEach((C,S)=>{const w=k[S];if(!w)return;C.style.position="relative",C.style.overflow="hidden";const I=Go(C);I&&I.classList.add(m);const j=Ko(C);j&&j.classList.add(b);const D=()=>{u.current=!1,e.current&&(e.current.style.isolation=""),$&&($.style.zIndex=""),I&&I.classList.remove(m),j&&j.classList.remove(b),C.style.position="",C.style.overflow="",C.contains(w)&&C.removeChild(w)};w.style.pointerEvents="none",w.style.position="absolute",w.style.overflow="hidden",w.setAttribute("aria-hidden","true");const L=v0(w);L&&(L.style.opacity="0");const U=Go(w);U&&(U.classList.add(f?o[ge.caption_before_exit]:o[ge.caption_after_exit]),U.addEventListener("animationend",D));const P=Ko(w);P&&P.classList.add(f?o[ge.weeks_before_exit]:o[ge.weeks_after_exit]),C.insertBefore(w,C.firstChild)})}})}function w0(e,t,o,n){const r=e[0],s=e[e.length-1],{ISOWeek:l,fixedWeeks:a,broadcastCalendar:u}=o??{},{addDays:p,differenceInCalendarDays:h,differenceInCalendarMonths:f,endOfBroadcastWeek:m,endOfISOWeek:b,endOfMonth:x,endOfWeek:y,isAfter:k,startOfBroadcastWeek:v,startOfISOWeek:$,startOfWeek:C}=n,S=u?v(r,n):l?$(r):C(r),w=u?m(s):l?b(x(s)):y(x(s)),I=h(w,S),j=f(s,r)+1,D=[];for(let P=0;P<=I;P++){const B=p(S,P);if(t&&k(B,t))break;D.push(B)}const U=(u?35:42)*j;if(a&&D.length<U){const P=U-D.length;for(let B=0;B<P;B++){const Z=p(D[D.length-1],1);D.push(Z)}}return D}function C0(e){const t=[];return e.reduce((o,n)=>{const r=n.weeks.reduce((s,l)=>s.concat(l.days.slice()),t.slice());return o.concat(r.slice())},t.slice())}function $0(e,t,o,n){const{numberOfMonths:r=1}=o,s=[];for(let l=0;l<r;l++){const a=n.addMonths(e,l);if(t&&a>t)break;s.push(a)}return s}function Nr(e,t,o,n){const{month:r,defaultMonth:s,today:l=n.today(),numberOfMonths:a=1}=e;let u=r||s||l;const{differenceInCalendarMonths:p,addMonths:h,startOfMonth:f}=n;if(o&&p(o,u)<a-1){const m=-1*(a-1);u=h(o,m)}return t&&p(u,t)<0&&(u=t),f(u)}function S0(e,t,o,n){const{addDays:r,endOfBroadcastWeek:s,endOfISOWeek:l,endOfMonth:a,endOfWeek:u,getISOWeek:p,getWeek:h,startOfBroadcastWeek:f,startOfISOWeek:m,startOfWeek:b}=n,x=e.reduce((y,k)=>{const v=o.broadcastCalendar?f(k,n):o.ISOWeek?m(k):b(k),$=o.broadcastCalendar?s(k):o.ISOWeek?l(a(k)):u(a(k)),C=t.filter(j=>j>=v&&j<=$),S=o.broadcastCalendar?35:42;if(o.fixedWeeks&&C.length<S){const j=t.filter(D=>{const L=S-C.length;return D>$&&D<=r($,L)});C.push(...j)}const w=C.reduce((j,D)=>{const L=o.ISOWeek?p(D):h(D),U=j.find(B=>B.weekNumber===L),P=new Gi(D,k,n);return U?U.days.push(P):j.push(new fx(L,[P])),j},[]),I=new hx(k,w);return y.push(I),y},[]);return o.reverseMonths?x.reverse():x}function j0(e,t){let{startMonth:o,endMonth:n}=e;const{startOfYear:r,startOfDay:s,startOfMonth:l,endOfMonth:a,addYears:u,endOfYear:p,newDate:h,today:f}=t,{fromYear:m,toYear:b,fromMonth:x,toMonth:y}=e;!o&&x&&(o=x),!o&&m&&(o=t.newDate(m,0,1)),!n&&y&&(n=y),!n&&b&&(n=h(b,11,31));const k=e.captionLayout==="dropdown"||e.captionLayout==="dropdown-years";return o?o=l(o):m?o=h(m,0,1):!o&&k&&(o=r(u(e.today??f(),-100))),n?n=a(n):b?n=h(b,11,31):!n&&k&&(n=p(e.today??f())),[o&&s(o),n&&s(n)]}function I0(e,t,o,n){if(o.disableNavigation)return;const{pagedNavigation:r,numberOfMonths:s=1}=o,{startOfMonth:l,addMonths:a,differenceInCalendarMonths:u}=n,p=r?s:1,h=l(e);if(!t)return a(h,p);if(!(u(t,e)<s))return a(h,p)}function D0(e,t,o,n){if(o.disableNavigation)return;const{pagedNavigation:r,numberOfMonths:s}=o,{startOfMonth:l,addMonths:a,differenceInCalendarMonths:u}=n,p=r?s??1:1,h=l(e);if(!t)return a(h,-p);if(!(u(h,t)<=0))return a(h,-p)}function _0(e){const t=[];return e.reduce((o,n)=>o.concat(n.weeks.slice()),t.slice())}function _o(e,t){const[o,n]=d.useState(e);return[t===void 0?o:t,n]}function T0(e,t){const[o,n]=j0(e,t),{startOfMonth:r,endOfMonth:s}=t,l=Nr(e,o,n,t),[a,u]=_o(l,e.month?l:void 0);d.useEffect(()=>{const I=Nr(e,o,n,t);u(I)},[e.timeZone]);const p=$0(a,n,e,t),h=w0(p,e.endMonth?s(e.endMonth):void 0,e,t),f=S0(p,h,e,t),m=_0(f),b=C0(f),x=D0(a,o,e,t),y=I0(a,n,e,t),{disableNavigation:k,onMonthChange:v}=e,$=I=>m.some(j=>j.days.some(D=>D.isEqualTo(I))),C=I=>{if(k)return;let j=r(I);o&&j<r(o)&&(j=r(o)),n&&j>r(n)&&(j=r(n)),u(j),v==null||v(j)};return{months:f,weeks:m,days:b,navStart:o,navEnd:n,previousMonth:x,nextMonth:y,goToMonth:C,goToDay:I=>{$(I)||C(I.date)}}}var We;(function(e){e[e.Today=0]="Today",e[e.Selected=1]="Selected",e[e.LastFocused=2]="LastFocused",e[e.FocusedModifier=3]="FocusedModifier"})(We||(We={}));function Fr(e){return!e[se.disabled]&&!e[se.hidden]&&!e[se.outside]}function E0(e,t,o,n){let r,s=-1;for(const l of e){const a=t(l);Fr(a)&&(a[se.focused]&&s<We.FocusedModifier?(r=l,s=We.FocusedModifier):n!=null&&n.isEqualTo(l)&&s<We.LastFocused?(r=l,s=We.LastFocused):o(l.date)&&s<We.Selected?(r=l,s=We.Selected):a[se.today]&&s<We.Today&&(r=l,s=We.Today))}return r||(r=e.find(l=>Fr(t(l)))),r}function z0(e,t,o,n,r,s,l){const{ISOWeek:a,broadcastCalendar:u}=s,{addDays:p,addMonths:h,addWeeks:f,addYears:m,endOfBroadcastWeek:b,endOfISOWeek:x,endOfWeek:y,max:k,min:v,startOfBroadcastWeek:$,startOfISOWeek:C,startOfWeek:S}=l;let I={day:p,week:f,month:h,year:m,startOfWeek:j=>u?$(j,l):a?C(j):S(j),endOfWeek:j=>u?b(j):a?x(j):y(j)}[e](o,t==="after"?1:-1);return t==="before"&&n?I=k([n,I]):t==="after"&&r&&(I=v([r,I])),I}function na(e,t,o,n,r,s,l,a=0){if(a>365)return;const u=z0(e,t,o.date,n,r,s,l),p=!!(s.disabled&&tt(u,s.disabled,l)),h=!!(s.hidden&&tt(u,s.hidden,l)),f=u,m=new Gi(u,f,l);return!p&&!h?m:na(e,t,m,n,r,s,l,a+1)}function M0(e,t,o,n,r){const{autoFocus:s}=e,[l,a]=d.useState(),u=E0(t.days,o,n||(()=>!1),l),[p,h]=d.useState(s?u:void 0);return{isFocusTarget:y=>!!(u!=null&&u.isEqualTo(y)),setFocused:h,focused:p,blur:()=>{a(p),h(void 0)},moveFocus:(y,k)=>{if(!p)return;const v=na(y,k,p,t.navStart,t.navEnd,e,r);v&&(t.goToDay(v),h(v))}}}function O0(e,t){const{selected:o,required:n,onSelect:r}=e,[s,l]=_o(o,r?o:void 0),a=r?o:s,{isSameDay:u}=t,p=b=>(a==null?void 0:a.some(x=>u(x,b)))??!1,{min:h,max:f}=e;return{selected:a,select:(b,x,y)=>{let k=[...a??[]];if(p(b)){if((a==null?void 0:a.length)===h||n&&(a==null?void 0:a.length)===1)return;k=a==null?void 0:a.filter(v=>!u(v,b))}else(a==null?void 0:a.length)===f?k=[b]:k=[...k,b];return r||l(k),r==null||r(k,b,x,y),k},isSelected:p}}function R0(e,t,o=0,n=0,r=!1,s=qe){const{from:l,to:a}=t||{},{isSameDay:u,isAfter:p,isBefore:h}=s;let f;if(!l&&!a)f={from:e,to:o>0?void 0:e};else if(l&&!a)u(l,e)?o===0?f={from:l,to:e}:r?f={from:l,to:void 0}:f=void 0:h(e,l)?f={from:e,to:l}:f={from:l,to:e};else if(l&&a)if(u(l,e)&&u(a,e))r?f={from:l,to:a}:f=void 0;else if(u(l,e))f={from:l,to:o>0?void 0:e};else if(u(a,e))f={from:e,to:o>0?void 0:e};else if(h(e,l))f={from:e,to:a};else if(p(e,l))f={from:l,to:e};else if(p(e,a))f={from:l,to:e};else throw new Error("Invalid range");if(f!=null&&f.from&&(f!=null&&f.to)){const m=s.differenceInCalendarDays(f.to,f.from);n>0&&m>n?f={from:e,to:void 0}:o>1&&m<o&&(f={from:e,to:void 0})}return f}function N0(e,t,o=qe){const n=Array.isArray(t)?t:[t];let r=e.from;const s=o.differenceInCalendarDays(e.to,e.from),l=Math.min(s,6);for(let a=0;a<=l;a++){if(n.includes(r.getDay()))return!0;r=o.addDays(r,1)}return!1}function Ar(e,t,o=qe){return et(e,t.from,!1,o)||et(e,t.to,!1,o)||et(t,e.from,!1,o)||et(t,e.to,!1,o)}function F0(e,t,o=qe){const n=Array.isArray(t)?t:[t];if(n.filter(a=>typeof a!="function").some(a=>typeof a=="boolean"?a:o.isDate(a)?et(e,a,!1,o):Ji(a,o)?a.some(u=>et(e,u,!1,o)):qn(a)?a.from&&a.to?Ar(e,{from:a.from,to:a.to},o):!1:Xi(a)?N0(e,a.dayOfWeek,o):Yi(a)?o.isAfter(a.before,a.after)?Ar(e,{from:o.addDays(a.after,1),to:o.addDays(a.before,-1)},o):tt(e.from,a,o)||tt(e.to,a,o):qi(a)||Zi(a)?tt(e.from,a,o)||tt(e.to,a,o):!1))return!0;const l=n.filter(a=>typeof a=="function");if(l.length){let a=e.from;const u=o.differenceInCalendarDays(e.to,e.from);for(let p=0;p<=u;p++){if(l.some(h=>h(a)))return!0;a=o.addDays(a,1)}}return!1}function A0(e,t){const{disabled:o,excludeDisabled:n,selected:r,required:s,onSelect:l}=e,[a,u]=_o(r,l?r:void 0),p=l?r:a;return{selected:p,select:(m,b,x)=>{const{min:y,max:k}=e,v=m?R0(m,p,y,k,s,t):void 0;return n&&o&&(v!=null&&v.from)&&v.to&&F0({from:v.from,to:v.to},o,t)&&(v.from=m,v.to=void 0),l||u(v),l==null||l(v,m,b,x),v},isSelected:m=>p&&et(p,m,!1,t)}}function L0(e,t){const{selected:o,required:n,onSelect:r}=e,[s,l]=_o(o,r?o:void 0),a=r?o:s,{isSameDay:u}=t;return{selected:a,select:(f,m,b)=>{let x=f;return!n&&a&&a&&u(f,a)&&(x=void 0),r||l(x),r==null||r(x,f,m,b),x},isSelected:f=>a?u(a,f):!1}}function B0(e,t){const o=L0(e,t),n=O0(e,t),r=A0(e,t);switch(e.mode){case"single":return o;case"multiple":return n;case"range":return r;default:return}}function W0(e){var nr;let t=e;t.timeZone&&(t={...e},t.today&&(t.today=new ce(t.today,t.timeZone)),t.month&&(t.month=new ce(t.month,t.timeZone)),t.defaultMonth&&(t.defaultMonth=new ce(t.defaultMonth,t.timeZone)),t.startMonth&&(t.startMonth=new ce(t.startMonth,t.timeZone)),t.endMonth&&(t.endMonth=new ce(t.endMonth,t.timeZone)),t.mode==="single"&&t.selected?t.selected=new ce(t.selected,t.timeZone):t.mode==="multiple"&&t.selected?t.selected=(nr=t.selected)==null?void 0:nr.map(H=>new ce(H,t.timeZone)):t.mode==="range"&&t.selected&&(t.selected={from:t.selected.from?new ce(t.selected.from,t.timeZone):void 0,to:t.selected.to?new ce(t.selected.to,t.timeZone):void 0}));const{components:o,formatters:n,labels:r,dateLib:s,locale:l,classNames:a}=d.useMemo(()=>{const H={...Hi,...t.locale};return{dateLib:new st({locale:H,weekStartsOn:t.broadcastCalendar?1:t.weekStartsOn,firstWeekContainsDate:t.firstWeekContainsDate,useAdditionalWeekYearTokens:t.useAdditionalWeekYearTokens,useAdditionalDayOfYearTokens:t.useAdditionalDayOfYearTokens,timeZone:t.timeZone,numerals:t.numerals},t.dateLib),components:Hx(t.components),formatters:t0(t.formatters),labels:{...b0,...t.labels},locale:H,classNames:{...Gx(),...t.classNames}}},[t.locale,t.broadcastCalendar,t.weekStartsOn,t.firstWeekContainsDate,t.useAdditionalWeekYearTokens,t.useAdditionalDayOfYearTokens,t.timeZone,t.numerals,t.dateLib,t.components,t.formatters,t.labels,t.classNames]),{captionLayout:u,mode:p,navLayout:h,numberOfMonths:f=1,onDayBlur:m,onDayClick:b,onDayFocus:x,onDayKeyDown:y,onDayMouseEnter:k,onDayMouseLeave:v,onNextClick:$,onPrevClick:C,showWeekNumber:S,styles:w}=t,{formatCaption:I,formatDay:j,formatMonthDropdown:D,formatWeekNumber:L,formatWeekNumberHeader:U,formatWeekdayName:P,formatYearDropdown:B}=n,Z=T0(t,s),{days:ie,months:J,navStart:X,navEnd:je,previousMonth:le,nextMonth:pe,goToMonth:Q}=Z,G=Px(ie,t,X,je,s),{isSelected:ee,select:Ze,selected:Le}=B0(t,s)??{},{blur:Jn,focused:oo,isFocusTarget:da,moveFocus:Qn,setFocused:no}=M0(t,Z,G,ee??(()=>!1),s),{labelDayButton:ua,labelGridcell:pa,labelGrid:ha,labelMonthDropdown:fa,labelNav:er,labelPrevious:ga,labelNext:ma,labelWeekday:ba,labelWeekNumber:xa,labelWeekNumberHeader:ya,labelYearDropdown:va}=r,ka=d.useMemo(()=>r0(s,t.ISOWeek),[s,t.ISOWeek]),tr=p!==void 0||b!==void 0,To=d.useCallback(()=>{le&&(Q(le),C==null||C(le))},[le,Q,C]),Eo=d.useCallback(()=>{pe&&(Q(pe),$==null||$(pe))},[Q,pe,$]),wa=d.useCallback((H,te)=>V=>{V.preventDefault(),V.stopPropagation(),no(H),Ze==null||Ze(H.date,te,V),b==null||b(H.date,te,V)},[Ze,b,no]),Ca=d.useCallback((H,te)=>V=>{no(H),x==null||x(H.date,te,V)},[x,no]),$a=d.useCallback((H,te)=>V=>{Jn(),m==null||m(H.date,te,V)},[Jn,m]),Sa=d.useCallback((H,te)=>V=>{const oe={ArrowLeft:[V.shiftKey?"month":"day",t.dir==="rtl"?"after":"before"],ArrowRight:[V.shiftKey?"month":"day",t.dir==="rtl"?"before":"after"],ArrowDown:[V.shiftKey?"year":"week","after"],ArrowUp:[V.shiftKey?"year":"week","before"],PageUp:[V.shiftKey?"year":"month","before"],PageDown:[V.shiftKey?"year":"month","after"],Home:["startOfWeek","before"],End:["endOfWeek","after"]};if(oe[V.key]){V.preventDefault(),V.stopPropagation();const[me,K]=oe[V.key];Qn(me,K)}y==null||y(H.date,te,V)},[Qn,y,t.dir]),ja=d.useCallback((H,te)=>V=>{k==null||k(H.date,te,V)},[k]),Ia=d.useCallback((H,te)=>V=>{v==null||v(H.date,te,V)},[v]),Da=d.useCallback(H=>te=>{const V=Number(te.target.value),oe=s.setMonth(s.startOfMonth(H),V);Q(oe)},[s,Q]),_a=d.useCallback(H=>te=>{const V=Number(te.target.value),oe=s.setYear(s.startOfMonth(H),V);Q(oe)},[s,Q]),{className:Ta,style:Ea}=d.useMemo(()=>({className:[a[A.Root],t.className].filter(Boolean).join(" "),style:{...w==null?void 0:w[A.Root],...t.style}}),[a,t.className,t.style,w]),za=Ux(t),or=d.useRef(null);k0(or,!!t.animate,{classNames:a,months:J,focused:oo,dateLib:s});const Ma={dayPickerProps:t,selected:Le,select:Ze,isSelected:ee,months:J,nextMonth:pe,previousMonth:le,goToMonth:Q,getModifiers:G,components:o,classNames:a,styles:w,labels:r,formatters:n};return d.createElement(Ki.Provider,{value:Ma},d.createElement(o.Root,{rootRef:t.animate?or:void 0,className:Ta,style:Ea,dir:t.dir,id:t.id,lang:t.lang,nonce:t.nonce,title:t.title,role:t.role,"aria-label":t["aria-label"],...za},d.createElement(o.Months,{className:a[A.Months],style:w==null?void 0:w[A.Months]},!t.hideNavigation&&!h&&d.createElement(o.Nav,{"data-animated-nav":t.animate?"true":void 0,className:a[A.Nav],style:w==null?void 0:w[A.Nav],"aria-label":er(),onPreviousClick:To,onNextClick:Eo,previousMonth:le,nextMonth:pe}),J.map((H,te)=>d.createElement(o.Month,{"data-animated-month":t.animate?"true":void 0,className:a[A.Month],style:w==null?void 0:w[A.Month],key:te,displayIndex:te,calendarMonth:H},h==="around"&&!t.hideNavigation&&te===0&&d.createElement(o.PreviousMonthButton,{type:"button",className:a[A.PreviousMonthButton],tabIndex:le?void 0:-1,"aria-disabled":le?void 0:!0,"aria-label":ga(le),onClick:To,"data-animated-button":t.animate?"true":void 0},d.createElement(o.Chevron,{disabled:le?void 0:!0,className:a[A.Chevron],orientation:t.dir==="rtl"?"right":"left"})),d.createElement(o.MonthCaption,{"data-animated-caption":t.animate?"true":void 0,className:a[A.MonthCaption],style:w==null?void 0:w[A.MonthCaption],calendarMonth:H,displayIndex:te},u!=null&&u.startsWith("dropdown")?d.createElement(o.DropdownNav,{className:a[A.Dropdowns],style:w==null?void 0:w[A.Dropdowns]},u==="dropdown"||u==="dropdown-months"?d.createElement(o.MonthsDropdown,{className:a[A.MonthsDropdown],"aria-label":fa(),classNames:a,components:o,disabled:!!t.disableNavigation,onChange:Da(H.date),options:o0(H.date,X,je,n,s),style:w==null?void 0:w[A.Dropdown],value:s.getMonth(H.date)}):d.createElement("span",null,D(H.date,s)),u==="dropdown"||u==="dropdown-years"?d.createElement(o.YearsDropdown,{className:a[A.YearsDropdown],"aria-label":va(s.options),classNames:a,components:o,disabled:!!t.disableNavigation,onChange:_a(H.date),options:s0(X,je,n,s,!!t.reverseYears),style:w==null?void 0:w[A.Dropdown],value:s.getYear(H.date)}):d.createElement("span",null,B(H.date,s)),d.createElement("span",{role:"status","aria-live":"polite",style:{border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap",wordWrap:"normal"}},I(H.date,s.options,s))):d.createElement(o.CaptionLabel,{className:a[A.CaptionLabel],role:"status","aria-live":"polite"},I(H.date,s.options,s))),h==="around"&&!t.hideNavigation&&te===f-1&&d.createElement(o.NextMonthButton,{type:"button",className:a[A.NextMonthButton],tabIndex:pe?void 0:-1,"aria-disabled":pe?void 0:!0,"aria-label":ma(pe),onClick:Eo,"data-animated-button":t.animate?"true":void 0},d.createElement(o.Chevron,{disabled:pe?void 0:!0,className:a[A.Chevron],orientation:t.dir==="rtl"?"left":"right"})),te===f-1&&h==="after"&&!t.hideNavigation&&d.createElement(o.Nav,{"data-animated-nav":t.animate?"true":void 0,className:a[A.Nav],style:w==null?void 0:w[A.Nav],"aria-label":er(),onPreviousClick:To,onNextClick:Eo,previousMonth:le,nextMonth:pe}),d.createElement(o.MonthGrid,{role:"grid","aria-multiselectable":p==="multiple"||p==="range","aria-label":ha(H.date,s.options,s)||void 0,className:a[A.MonthGrid],style:w==null?void 0:w[A.MonthGrid]},!t.hideWeekdays&&d.createElement(o.Weekdays,{"data-animated-weekdays":t.animate?"true":void 0,className:a[A.Weekdays],style:w==null?void 0:w[A.Weekdays]},S&&d.createElement(o.WeekNumberHeader,{"aria-label":ya(s.options),className:a[A.WeekNumberHeader],style:w==null?void 0:w[A.WeekNumberHeader],scope:"col"},U()),ka.map(V=>d.createElement(o.Weekday,{"aria-label":ba(V,s.options,s),className:a[A.Weekday],key:String(V),style:w==null?void 0:w[A.Weekday],scope:"col"},P(V,s.options,s)))),d.createElement(o.Weeks,{"data-animated-weeks":t.animate?"true":void 0,className:a[A.Weeks],style:w==null?void 0:w[A.Weeks]},H.weeks.map(V=>d.createElement(o.Week,{className:a[A.Week],key:V.weekNumber,style:w==null?void 0:w[A.Week],week:V},S&&d.createElement(o.WeekNumber,{week:V,style:w==null?void 0:w[A.WeekNumber],"aria-label":xa(V.weekNumber,{locale:l}),className:a[A.WeekNumber],scope:"row",role:"rowheader"},L(V.weekNumber,s)),V.days.map(oe=>{const{date:me}=oe,K=G(oe);if(K[se.focused]=!K.hidden&&!!(oo!=null&&oo.isEqualTo(oe)),K[Ne.selected]=(ee==null?void 0:ee(me))||K.selected,qn(Le)){const{from:zo,to:Mo}=Le;K[Ne.range_start]=!!(zo&&Mo&&s.isSameDay(me,zo)),K[Ne.range_end]=!!(zo&&Mo&&s.isSameDay(me,Mo)),K[Ne.range_middle]=et(Le,me,!0,s)}const Oa=n0(K,w,t.modifiersStyles),Ra=Vx(K,a,t.modifiersClassNames),Na=!tr&&!K.hidden?pa(me,K,s.options,s):void 0;return d.createElement(o.Day,{key:`${s.format(me,"yyyy-MM-dd")}_${s.format(oe.displayMonth,"yyyy-MM")}`,day:oe,modifiers:K,className:Ra.join(" "),style:Oa,role:"gridcell","aria-selected":K.selected||void 0,"aria-label":Na,"data-day":s.format(me,"yyyy-MM-dd"),"data-month":oe.outside?s.format(me,"yyyy-MM"):void 0,"data-selected":K.selected||void 0,"data-disabled":K.disabled||void 0,"data-hidden":K.hidden||void 0,"data-outside":oe.outside||void 0,"data-focused":K.focused||void 0,"data-today":K.today||void 0},!K.hidden&&tr?d.createElement(o.DayButton,{className:a[A.DayButton],style:w==null?void 0:w[A.DayButton],type:"button",day:oe,modifiers:K,disabled:K.disabled||void 0,tabIndex:da(oe)?0:-1,"aria-label":ua(me,K,s.options,s),onClick:wa(oe,K),onBlur:$a(oe,K),onFocus:Ca(oe,K),onKeyDown:Sa(oe,K),onMouseEnter:ja(oe,K),onMouseLeave:Ia(oe,K)},j(me,s.options,s)):!K.hidden&&j(oe.date,s.options,s))})))))))),t.footer&&d.createElement(o.Footer,{className:a[A.Footer],style:w==null?void 0:w[A.Footer],role:"status","aria-live":"polite"},t.footer)))}const P0=d.memo(({...e})=>i.jsx(V0,{mode:"single",...e})),V0=g(W0)`
3185
+ `;function zb(e,t,o="long"){return new Intl.DateTimeFormat("en-US",{hour:"numeric",timeZone:e,timeZoneName:o}).format(t).split(/\s/g).slice(2).join(" ")}const Vo={},Lt={};function gt(e,t){try{const n=(Vo[e]||(Vo[e]=new Intl.DateTimeFormat("en-US",{timeZone:e,timeZoneName:"longOffset"}).format))(t).split("GMT")[1];return n in Lt?Lt[n]:Mr(n,n.split(":"))}catch{if(e in Lt)return Lt[e];const o=e==null?void 0:e.match(Mb);return o?Mr(e,o.slice(1)):NaN}}const Mb=/([+-]\d\d):?(\d\d)?/;function Mr(e,t){const o=+(t[0]||0),n=+(t[1]||0),r=+(t[2]||0)/60;return Lt[e]=o*60+n>0?o*60+n+r:o*60-n-r}class Ue extends Date{constructor(...t){super(),t.length>1&&typeof t[t.length-1]=="string"&&(this.timeZone=t.pop()),this.internal=new Date,isNaN(gt(this.timeZone,this))?this.setTime(NaN):t.length?typeof t[0]=="number"&&(t.length===1||t.length===2&&typeof t[1]!="number")?this.setTime(t[0]):typeof t[0]=="string"?this.setTime(+new Date(t[0])):t[0]instanceof Date?this.setTime(+t[0]):(this.setTime(+new Date(...t)),Vi(this),cn(this)):this.setTime(Date.now())}static tz(t,...o){return o.length?new Ue(...o,t):new Ue(Date.now(),t)}withTimeZone(t){return new Ue(+this,t)}getTimezoneOffset(){const t=-gt(this.timeZone,this);return t>0?Math.floor(t):Math.ceil(t)}setTime(t){return Date.prototype.setTime.apply(this,arguments),cn(this),+this}[Symbol.for("constructDateFrom")](t){return new Ue(+new Date(t),this.timeZone)}}const Or=/^(get|set)(?!UTC)/;Object.getOwnPropertyNames(Date.prototype).forEach(e=>{if(!Or.test(e))return;const t=e.replace(Or,"$1UTC");Ue.prototype[t]&&(e.startsWith("get")?Ue.prototype[e]=function(){return this.internal[t]()}:(Ue.prototype[e]=function(){return Date.prototype[t].apply(this.internal,arguments),Ob(this),+this},Ue.prototype[t]=function(){return Date.prototype[t].apply(this,arguments),cn(this),+this}))});function cn(e){e.internal.setTime(+e),e.internal.setUTCSeconds(e.internal.getUTCSeconds()-Math.round(-gt(e.timeZone,e)*60))}function Ob(e){Date.prototype.setFullYear.call(e,e.internal.getUTCFullYear(),e.internal.getUTCMonth(),e.internal.getUTCDate()),Date.prototype.setHours.call(e,e.internal.getUTCHours(),e.internal.getUTCMinutes(),e.internal.getUTCSeconds(),e.internal.getUTCMilliseconds()),Vi(e)}function Vi(e){const t=gt(e.timeZone,e),o=t>0?Math.floor(t):Math.ceil(t),n=new Date(+e);n.setUTCHours(n.getUTCHours()-1);const r=-new Date(+e).getTimezoneOffset(),s=-new Date(+n).getTimezoneOffset(),l=r-s,a=Date.prototype.getHours.apply(e)!==e.internal.getUTCHours();l&&a&&e.internal.setUTCMinutes(e.internal.getUTCMinutes()+l);const u=r-o;u&&Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+u);const h=new Date(+e);h.setUTCSeconds(0);const p=r>0?h.getSeconds():(h.getSeconds()-60)%60,f=Math.round(-(gt(e.timeZone,e)*60))%60;(f||p)&&(e.internal.setUTCSeconds(e.internal.getUTCSeconds()+f),Date.prototype.setUTCSeconds.call(e,Date.prototype.getUTCSeconds.call(e)+f+p));const m=gt(e.timeZone,e),b=m>0?Math.floor(m):Math.ceil(m),y=-new Date(+e).getTimezoneOffset()-b,k=b!==o,v=y-u;if(k&&v){Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+v);const $=gt(e.timeZone,e),C=$>0?Math.floor($):Math.ceil($),S=b-C;S&&(e.internal.setUTCMinutes(e.internal.getUTCMinutes()+S),Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+S))}}class ce extends Ue{static tz(t,...o){return o.length?new ce(...o,t):new ce(Date.now(),t)}toISOString(){const[t,o,n]=this.tzComponents(),r=`${t}${o}:${n}`;return this.internal.toISOString().slice(0,-1)+r}toString(){return`${this.toDateString()} ${this.toTimeString()}`}toDateString(){const[t,o,n,r]=this.internal.toUTCString().split(" ");return`${t==null?void 0:t.slice(0,-1)} ${n} ${o} ${r}`}toTimeString(){const t=this.internal.toUTCString().split(" ")[4],[o,n,r]=this.tzComponents();return`${t} GMT${o}${n}${r} (${zb(this.timeZone,this)})`}toLocaleString(t,o){return Date.prototype.toLocaleString.call(this,t,{...o,timeZone:(o==null?void 0:o.timeZone)||this.timeZone})}toLocaleDateString(t,o){return Date.prototype.toLocaleDateString.call(this,t,{...o,timeZone:(o==null?void 0:o.timeZone)||this.timeZone})}toLocaleTimeString(t,o){return Date.prototype.toLocaleTimeString.call(this,t,{...o,timeZone:(o==null?void 0:o.timeZone)||this.timeZone})}tzComponents(){const t=this.getTimezoneOffset(),o=t>0?"-":"+",n=String(Math.floor(Math.abs(t)/60)).padStart(2,"0"),r=String(Math.abs(t)%60).padStart(2,"0");return[o,n,r]}withTimeZone(t){return new ce(+this,t)}[Symbol.for("constructDateFrom")](t){return new ce(+new Date(t),this.timeZone)}}const Rb={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Nb=(e,t,o)=>{let n;const r=Rb[e];return typeof r=="string"?n=r:t===1?n=r.one:n=r.other.replace("{{count}}",t.toString()),o!=null&&o.addSuffix?o.comparison&&o.comparison>0?"in "+n:n+" ago":n};function Ho(e){return(t={})=>{const o=t.width?String(t.width):e.defaultWidth;return e.formats[o]||e.formats[e.defaultWidth]}}const Fb={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Ab={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Lb={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Bb={date:Ho({formats:Fb,defaultWidth:"full"}),time:Ho({formats:Ab,defaultWidth:"full"}),dateTime:Ho({formats:Lb,defaultWidth:"full"})},Wb={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Pb=(e,t,o,n)=>Wb[e];function Ft(e){return(t,o)=>{const n=o!=null&&o.context?String(o.context):"standalone";let r;if(n==="formatting"&&e.formattingValues){const l=e.defaultFormattingWidth||e.defaultWidth,a=o!=null&&o.width?String(o.width):l;r=e.formattingValues[a]||e.formattingValues[l]}else{const l=e.defaultWidth,a=o!=null&&o.width?String(o.width):e.defaultWidth;r=e.values[a]||e.values[l]}const s=e.argumentCallback?e.argumentCallback(t):t;return r[s]}}const Vb={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Hb={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Ub={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Gb={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Kb={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},Yb={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},qb=(e,t)=>{const o=Number(e),n=o%100;if(n>20||n<10)switch(n%10){case 1:return o+"st";case 2:return o+"nd";case 3:return o+"rd"}return o+"th"},Zb={ordinalNumber:qb,era:Ft({values:Vb,defaultWidth:"wide"}),quarter:Ft({values:Hb,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Ft({values:Ub,defaultWidth:"wide"}),day:Ft({values:Gb,defaultWidth:"wide"}),dayPeriod:Ft({values:Kb,defaultWidth:"wide",formattingValues:Yb,defaultFormattingWidth:"wide"})};function At(e){return(t,o={})=>{const n=o.width,r=n&&e.matchPatterns[n]||e.matchPatterns[e.defaultMatchWidth],s=t.match(r);if(!s)return null;const l=s[0],a=n&&e.parsePatterns[n]||e.parsePatterns[e.defaultParseWidth],u=Array.isArray(a)?Jb(a,f=>f.test(l)):Xb(a,f=>f.test(l));let h;h=e.valueCallback?e.valueCallback(u):u,h=o.valueCallback?o.valueCallback(h):h;const p=t.slice(l.length);return{value:h,rest:p}}}function Xb(e,t){for(const o in e)if(Object.prototype.hasOwnProperty.call(e,o)&&t(e[o]))return o}function Jb(e,t){for(let o=0;o<e.length;o++)if(t(e[o]))return o}function Qb(e){return(t,o={})=>{const n=t.match(e.matchPattern);if(!n)return null;const r=n[0],s=t.match(e.parsePattern);if(!s)return null;let l=e.valueCallback?e.valueCallback(s[0]):s[0];l=o.valueCallback?o.valueCallback(l):l;const a=t.slice(r.length);return{value:l,rest:a}}}const ex=/^(\d+)(th|st|nd|rd)?/i,tx=/\d+/i,ox={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},nx={any:[/^b/i,/^(a|c)/i]},rx={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},sx={any:[/1/i,/2/i,/3/i,/4/i]},ix={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},ax={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},lx={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},cx={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},dx={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},ux={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},hx={ordinalNumber:Qb({matchPattern:ex,parsePattern:tx,valueCallback:e=>parseInt(e,10)}),era:At({matchPatterns:ox,defaultMatchWidth:"wide",parsePatterns:nx,defaultParseWidth:"any"}),quarter:At({matchPatterns:rx,defaultMatchWidth:"wide",parsePatterns:sx,defaultParseWidth:"any",valueCallback:e=>e+1}),month:At({matchPatterns:ix,defaultMatchWidth:"wide",parsePatterns:ax,defaultParseWidth:"any"}),day:At({matchPatterns:lx,defaultMatchWidth:"wide",parsePatterns:cx,defaultParseWidth:"any"}),dayPeriod:At({matchPatterns:dx,defaultMatchWidth:"any",parsePatterns:ux,defaultParseWidth:"any"})},Hi={code:"en-US",formatDistance:Nb,formatLong:Bb,formatRelative:Pb,localize:Zb,match:hx,options:{weekStartsOn:0,firstWeekContainsDate:1}},Rr=5,px=4;function fx(e,t){const o=t.startOfMonth(e),n=o.getDay()>0?o.getDay():7,r=t.addDays(e,-n+1),s=t.addDays(r,Rr*7-1);return t.getMonth(e)===t.getMonth(s)?Rr:px}function Ui(e,t){const o=t.startOfMonth(e),n=o.getDay();return n===1?o:n===0?t.addDays(o,-1*6):t.addDays(o,-1*(n-1))}function gx(e,t){const o=Ui(e,t),n=fx(e,t);return t.addDays(o,n*7-1)}class st{constructor(t,o){this.Date=Date,this.today=()=>{var n;return(n=this.overrides)!=null&&n.today?this.overrides.today():this.options.timeZone?ce.tz(this.options.timeZone):new this.Date},this.newDate=(n,r,s)=>{var l;return(l=this.overrides)!=null&&l.newDate?this.overrides.newDate(n,r,s):this.options.timeZone?new ce(n,r,s,this.options.timeZone):new Date(n,r,s)},this.addDays=(n,r)=>{var s;return(s=this.overrides)!=null&&s.addDays?this.overrides.addDays(n,r):q.addDays(n,r)},this.addMonths=(n,r)=>{var s;return(s=this.overrides)!=null&&s.addMonths?this.overrides.addMonths(n,r):q.addMonths(n,r)},this.addWeeks=(n,r)=>{var s;return(s=this.overrides)!=null&&s.addWeeks?this.overrides.addWeeks(n,r):q.addWeeks(n,r)},this.addYears=(n,r)=>{var s;return(s=this.overrides)!=null&&s.addYears?this.overrides.addYears(n,r):q.addYears(n,r)},this.differenceInCalendarDays=(n,r)=>{var s;return(s=this.overrides)!=null&&s.differenceInCalendarDays?this.overrides.differenceInCalendarDays(n,r):q.differenceInCalendarDays(n,r)},this.differenceInCalendarMonths=(n,r)=>{var s;return(s=this.overrides)!=null&&s.differenceInCalendarMonths?this.overrides.differenceInCalendarMonths(n,r):q.differenceInCalendarMonths(n,r)},this.eachMonthOfInterval=n=>{var r;return(r=this.overrides)!=null&&r.eachMonthOfInterval?this.overrides.eachMonthOfInterval(n):q.eachMonthOfInterval(n)},this.endOfBroadcastWeek=n=>{var r;return(r=this.overrides)!=null&&r.endOfBroadcastWeek?this.overrides.endOfBroadcastWeek(n):gx(n,this)},this.endOfISOWeek=n=>{var r;return(r=this.overrides)!=null&&r.endOfISOWeek?this.overrides.endOfISOWeek(n):q.endOfISOWeek(n)},this.endOfMonth=n=>{var r;return(r=this.overrides)!=null&&r.endOfMonth?this.overrides.endOfMonth(n):q.endOfMonth(n)},this.endOfWeek=(n,r)=>{var s;return(s=this.overrides)!=null&&s.endOfWeek?this.overrides.endOfWeek(n,r):q.endOfWeek(n,this.options)},this.endOfYear=n=>{var r;return(r=this.overrides)!=null&&r.endOfYear?this.overrides.endOfYear(n):q.endOfYear(n)},this.format=(n,r,s)=>{var a;const l=(a=this.overrides)!=null&&a.format?this.overrides.format(n,r,this.options):q.format(n,r,this.options);return this.options.numerals&&this.options.numerals!=="latn"?this.replaceDigits(l):l},this.getISOWeek=n=>{var r;return(r=this.overrides)!=null&&r.getISOWeek?this.overrides.getISOWeek(n):q.getISOWeek(n)},this.getMonth=(n,r)=>{var s;return(s=this.overrides)!=null&&s.getMonth?this.overrides.getMonth(n,this.options):q.getMonth(n,this.options)},this.getYear=(n,r)=>{var s;return(s=this.overrides)!=null&&s.getYear?this.overrides.getYear(n,this.options):q.getYear(n,this.options)},this.getWeek=(n,r)=>{var s;return(s=this.overrides)!=null&&s.getWeek?this.overrides.getWeek(n,this.options):q.getWeek(n,this.options)},this.isAfter=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isAfter?this.overrides.isAfter(n,r):q.isAfter(n,r)},this.isBefore=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isBefore?this.overrides.isBefore(n,r):q.isBefore(n,r)},this.isDate=n=>{var r;return(r=this.overrides)!=null&&r.isDate?this.overrides.isDate(n):q.isDate(n)},this.isSameDay=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isSameDay?this.overrides.isSameDay(n,r):q.isSameDay(n,r)},this.isSameMonth=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isSameMonth?this.overrides.isSameMonth(n,r):q.isSameMonth(n,r)},this.isSameYear=(n,r)=>{var s;return(s=this.overrides)!=null&&s.isSameYear?this.overrides.isSameYear(n,r):q.isSameYear(n,r)},this.max=n=>{var r;return(r=this.overrides)!=null&&r.max?this.overrides.max(n):q.max(n)},this.min=n=>{var r;return(r=this.overrides)!=null&&r.min?this.overrides.min(n):q.min(n)},this.setMonth=(n,r)=>{var s;return(s=this.overrides)!=null&&s.setMonth?this.overrides.setMonth(n,r):q.setMonth(n,r)},this.setYear=(n,r)=>{var s;return(s=this.overrides)!=null&&s.setYear?this.overrides.setYear(n,r):q.setYear(n,r)},this.startOfBroadcastWeek=(n,r)=>{var s;return(s=this.overrides)!=null&&s.startOfBroadcastWeek?this.overrides.startOfBroadcastWeek(n,this):Ui(n,this)},this.startOfDay=n=>{var r;return(r=this.overrides)!=null&&r.startOfDay?this.overrides.startOfDay(n):q.startOfDay(n)},this.startOfISOWeek=n=>{var r;return(r=this.overrides)!=null&&r.startOfISOWeek?this.overrides.startOfISOWeek(n):q.startOfISOWeek(n)},this.startOfMonth=n=>{var r;return(r=this.overrides)!=null&&r.startOfMonth?this.overrides.startOfMonth(n):q.startOfMonth(n)},this.startOfWeek=(n,r)=>{var s;return(s=this.overrides)!=null&&s.startOfWeek?this.overrides.startOfWeek(n,this.options):q.startOfWeek(n,this.options)},this.startOfYear=n=>{var r;return(r=this.overrides)!=null&&r.startOfYear?this.overrides.startOfYear(n):q.startOfYear(n)},this.options={locale:Hi,...t},this.overrides=o}getDigitMap(){const{numerals:t="latn"}=this.options,o=new Intl.NumberFormat("en-US",{numberingSystem:t}),n={};for(let r=0;r<10;r++)n[r.toString()]=o.format(r);return n}replaceDigits(t){const o=this.getDigitMap();return t.replace(/\d/g,n=>o[n]||n)}formatNumber(t){return this.replaceDigits(t.toString())}}const Ze=new st;class Gi{constructor(t,o,n=Ze){this.date=t,this.displayMonth=o,this.outside=!!(o&&!n.isSameMonth(t,o)),this.dateLib=n}isEqualTo(t){return this.dateLib.isSameDay(t.date,this.date)&&this.dateLib.isSameMonth(t.displayMonth,this.displayMonth)}}class mx{constructor(t,o){this.date=t,this.weeks=o}}class bx{constructor(t,o){this.days=o,this.weekNumber=t}}function xx(e){return d.createElement("button",{...e})}function yx(e){return d.createElement("span",{...e})}function vx(e){const{size:t=24,orientation:o="left",className:n}=e;return d.createElement("svg",{className:n,width:t,height:t,viewBox:"0 0 24 24"},o==="up"&&d.createElement("polygon",{points:"6.77 17 12.5 11.43 18.24 17 20 15.28 12.5 8 5 15.28"}),o==="down"&&d.createElement("polygon",{points:"6.77 8 12.5 13.57 18.24 8 20 9.72 12.5 17 5 9.72"}),o==="left"&&d.createElement("polygon",{points:"16 18.112 9.81111111 12 16 5.87733333 14.0888889 4 6 12 14.0888889 20"}),o==="right"&&d.createElement("polygon",{points:"8 18.112 14.18888889 12 8 5.87733333 9.91111111 4 18 12 9.91111111 20"}))}function kx(e){const{day:t,modifiers:o,...n}=e;return d.createElement("td",{...n})}function wx(e){const{day:t,modifiers:o,...n}=e,r=d.useRef(null);return d.useEffect(()=>{var s;o.focused&&((s=r.current)==null||s.focus())},[o.focused]),d.createElement("button",{ref:r,...n})}var A;(function(e){e.Root="root",e.Chevron="chevron",e.Day="day",e.DayButton="day_button",e.CaptionLabel="caption_label",e.Dropdowns="dropdowns",e.Dropdown="dropdown",e.DropdownRoot="dropdown_root",e.Footer="footer",e.MonthGrid="month_grid",e.MonthCaption="month_caption",e.MonthsDropdown="months_dropdown",e.Month="month",e.Months="months",e.Nav="nav",e.NextMonthButton="button_next",e.PreviousMonthButton="button_previous",e.Week="week",e.Weeks="weeks",e.Weekday="weekday",e.Weekdays="weekdays",e.WeekNumber="week_number",e.WeekNumberHeader="week_number_header",e.YearsDropdown="years_dropdown"})(A||(A={}));var se;(function(e){e.disabled="disabled",e.hidden="hidden",e.outside="outside",e.focused="focused",e.today="today"})(se||(se={}));var Ne;(function(e){e.range_end="range_end",e.range_middle="range_middle",e.range_start="range_start",e.selected="selected"})(Ne||(Ne={}));var ge;(function(e){e.weeks_before_enter="weeks_before_enter",e.weeks_before_exit="weeks_before_exit",e.weeks_after_enter="weeks_after_enter",e.weeks_after_exit="weeks_after_exit",e.caption_after_enter="caption_after_enter",e.caption_after_exit="caption_after_exit",e.caption_before_enter="caption_before_enter",e.caption_before_exit="caption_before_exit"})(ge||(ge={}));function Cx(e){const{options:t,className:o,components:n,classNames:r,...s}=e,l=[r[A.Dropdown],o].join(" "),a=t==null?void 0:t.find(({value:u})=>u===s.value);return d.createElement("span",{"data-disabled":s.disabled,className:r[A.DropdownRoot]},d.createElement(n.Select,{className:l,...s},t==null?void 0:t.map(({value:u,label:h,disabled:p})=>d.createElement(n.Option,{key:u,value:u,disabled:p},h))),d.createElement("span",{className:r[A.CaptionLabel],"aria-hidden":!0},a==null?void 0:a.label,d.createElement(n.Chevron,{orientation:"down",size:18,className:r[A.Chevron]})))}function $x(e){return d.createElement("div",{...e})}function Sx(e){return d.createElement("div",{...e})}function jx(e){const{calendarMonth:t,displayIndex:o,...n}=e;return d.createElement("div",{...n},e.children)}function Ix(e){const{calendarMonth:t,displayIndex:o,...n}=e;return d.createElement("div",{...n})}function Dx(e){return d.createElement("table",{...e})}function _x(e){return d.createElement("div",{...e})}const Ki=d.createContext(void 0);function eo(){const e=d.useContext(Ki);if(e===void 0)throw new Error("useDayPicker() must be used within a custom component.");return e}function Tx(e){const{components:t}=eo();return d.createElement(t.Dropdown,{...e})}function Ex(e){const{onPreviousClick:t,onNextClick:o,previousMonth:n,nextMonth:r,...s}=e,{components:l,classNames:a,labels:{labelPrevious:u,labelNext:h}}=eo(),p=d.useCallback(m=>{r&&(o==null||o(m))},[r,o]),f=d.useCallback(m=>{n&&(t==null||t(m))},[n,t]);return d.createElement("nav",{...s},d.createElement(l.PreviousMonthButton,{type:"button",className:a[A.PreviousMonthButton],tabIndex:n?void 0:-1,"aria-disabled":n?void 0:!0,"aria-label":u(n),onClick:f},d.createElement(l.Chevron,{disabled:n?void 0:!0,className:a[A.Chevron],orientation:"left"})),d.createElement(l.NextMonthButton,{type:"button",className:a[A.NextMonthButton],tabIndex:r?void 0:-1,"aria-disabled":r?void 0:!0,"aria-label":h(r),onClick:p},d.createElement(l.Chevron,{disabled:r?void 0:!0,orientation:"right",className:a[A.Chevron]})))}function zx(e){const{components:t}=eo();return d.createElement(t.Button,{...e})}function Mx(e){return d.createElement("option",{...e})}function Ox(e){const{components:t}=eo();return d.createElement(t.Button,{...e})}function Rx(e){const{rootRef:t,...o}=e;return d.createElement("div",{...o,ref:t})}function Nx(e){return d.createElement("select",{...e})}function Fx(e){const{week:t,...o}=e;return d.createElement("tr",{...o})}function Ax(e){return d.createElement("th",{...e})}function Lx(e){return d.createElement("thead",{"aria-hidden":!0},d.createElement("tr",{...e}))}function Bx(e){const{week:t,...o}=e;return d.createElement("th",{...o})}function Wx(e){return d.createElement("th",{...e})}function Px(e){return d.createElement("tbody",{...e})}function Vx(e){const{components:t}=eo();return d.createElement(t.Dropdown,{...e})}const Hx=Object.freeze(Object.defineProperty({__proto__:null,Button:xx,CaptionLabel:yx,Chevron:vx,Day:kx,DayButton:wx,Dropdown:Cx,DropdownNav:$x,Footer:Sx,Month:jx,MonthCaption:Ix,MonthGrid:Dx,Months:_x,MonthsDropdown:Tx,Nav:Ex,NextMonthButton:zx,Option:Mx,PreviousMonthButton:Ox,Root:Rx,Select:Nx,Week:Fx,WeekNumber:Bx,WeekNumberHeader:Wx,Weekday:Ax,Weekdays:Lx,Weeks:Px,YearsDropdown:Vx},Symbol.toStringTag,{value:"Module"}));function tt(e,t,o=!1,n=Ze){let{from:r,to:s}=e;const{differenceInCalendarDays:l,isSameDay:a}=n;return r&&s?(l(s,r)<0&&([r,s]=[s,r]),l(t,r)>=(o?1:0)&&l(s,t)>=(o?1:0)):!o&&s?a(s,t):!o&&r?a(r,t):!1}function Yi(e){return!!(e&&typeof e=="object"&&"before"in e&&"after"in e)}function qn(e){return!!(e&&typeof e=="object"&&"from"in e)}function qi(e){return!!(e&&typeof e=="object"&&"after"in e)}function Zi(e){return!!(e&&typeof e=="object"&&"before"in e)}function Xi(e){return!!(e&&typeof e=="object"&&"dayOfWeek"in e)}function Ji(e,t){return Array.isArray(e)&&e.every(t.isDate)}function ot(e,t,o=Ze){const n=Array.isArray(t)?t:[t],{isSameDay:r,differenceInCalendarDays:s,isAfter:l}=o;return n.some(a=>{if(typeof a=="boolean")return a;if(o.isDate(a))return r(e,a);if(Ji(a,o))return a.includes(e);if(qn(a))return tt(a,e,!1,o);if(Xi(a))return Array.isArray(a.dayOfWeek)?a.dayOfWeek.includes(e.getDay()):a.dayOfWeek===e.getDay();if(Yi(a)){const u=s(a.before,e),h=s(a.after,e),p=u>0,f=h<0;return l(a.before,a.after)?f&&p:p||f}return qi(a)?s(e,a.after)>0:Zi(a)?s(a.before,e)>0:typeof a=="function"?a(e):!1})}function Ux(e,t,o,n,r){const{disabled:s,hidden:l,modifiers:a,showOutsideDays:u,broadcastCalendar:h,today:p}=t,{isSameDay:f,isSameMonth:m,startOfMonth:b,isBefore:x,endOfMonth:y,isAfter:k}=r,v=o&&b(o),$=n&&y(n),C={[se.focused]:[],[se.outside]:[],[se.disabled]:[],[se.hidden]:[],[se.today]:[]},S={};for(const w of e){const{date:I,displayMonth:j}=w,D=!!(j&&!m(I,j)),L=!!(v&&x(I,v)),U=!!($&&k(I,$)),P=!!(s&&ot(I,s,r)),B=!!(l&&ot(I,l,r))||L||U||!h&&!u&&D||h&&u===!1&&D,Z=f(I,p??r.today());D&&C.outside.push(w),P&&C.disabled.push(w),B&&C.hidden.push(w),Z&&C.today.push(w),a&&Object.keys(a).forEach(ie=>{const J=a==null?void 0:a[ie];J&&ot(I,J,r)&&(S[ie]?S[ie].push(w):S[ie]=[w])})}return w=>{const I={[se.focused]:!1,[se.disabled]:!1,[se.hidden]:!1,[se.outside]:!1,[se.today]:!1},j={};for(const D in C){const L=C[D];I[D]=L.some(U=>U===w)}for(const D in S)j[D]=S[D].some(L=>L===w);return{...I,...j}}}function Gx(e,t,o={}){return Object.entries(e).filter(([,r])=>r===!0).reduce((r,[s])=>(o[s]?r.push(o[s]):t[se[s]]?r.push(t[se[s]]):t[Ne[s]]&&r.push(t[Ne[s]]),r),[t[A.Day]])}function Kx(e){return{...Hx,...e}}function Yx(e){const t={"data-mode":e.mode??void 0,"data-required":"required"in e?e.required:void 0,"data-multiple-months":e.numberOfMonths&&e.numberOfMonths>1||void 0,"data-week-numbers":e.showWeekNumber||void 0,"data-broadcast-calendar":e.broadcastCalendar||void 0,"data-nav-layout":e.navLayout||void 0};return Object.entries(e).forEach(([o,n])=>{o.startsWith("data-")&&(t[o]=n)}),t}function qx(){const e={};for(const t in A)e[A[t]]=`rdp-${A[t]}`;for(const t in se)e[se[t]]=`rdp-${se[t]}`;for(const t in Ne)e[Ne[t]]=`rdp-${Ne[t]}`;for(const t in ge)e[ge[t]]=`rdp-${ge[t]}`;return e}function Qi(e,t,o){return(o??new st(t)).format(e,"LLLL y")}const Zx=Qi;function Xx(e,t,o){return(o??new st(t)).format(e,"d")}function Jx(e,t=Ze){return t.format(e,"LLLL")}function Qx(e,t,o){return(o??new st(t)).format(e,"cccccc")}function e0(e,t=Ze){return e<10?t.formatNumber(`0${e.toLocaleString()}`):t.formatNumber(`${e.toLocaleString()}`)}function t0(){return""}function ea(e,t=Ze){return t.format(e,"yyyy")}const o0=ea,n0=Object.freeze(Object.defineProperty({__proto__:null,formatCaption:Qi,formatDay:Xx,formatMonthCaption:Zx,formatMonthDropdown:Jx,formatWeekNumber:e0,formatWeekNumberHeader:t0,formatWeekdayName:Qx,formatYearCaption:o0,formatYearDropdown:ea},Symbol.toStringTag,{value:"Module"}));function r0(e){return e!=null&&e.formatMonthCaption&&!e.formatCaption&&(e.formatCaption=e.formatMonthCaption),e!=null&&e.formatYearCaption&&!e.formatYearDropdown&&(e.formatYearDropdown=e.formatYearCaption),{...n0,...e}}function s0(e,t,o,n,r){const{startOfMonth:s,startOfYear:l,endOfYear:a,eachMonthOfInterval:u,getMonth:h}=r;return u({start:l(e),end:a(e)}).map(m=>{const b=n.formatMonthDropdown(m,r),x=h(m),y=t&&m<s(t)||o&&m>s(o)||!1;return{value:x,label:b,disabled:y}})}function i0(e,t={},o={}){let n={...t==null?void 0:t[A.Day]};return Object.entries(e).filter(([,r])=>r===!0).forEach(([r])=>{n={...n,...o==null?void 0:o[r]}}),n}function a0(e,t,o){const n=e.today(),r=t?e.startOfISOWeek(n):e.startOfWeek(n),s=[];for(let l=0;l<7;l++){const a=e.addDays(r,l);s.push(a)}return s}function l0(e,t,o,n,r=!1){if(!e||!t)return;const{startOfYear:s,endOfYear:l,addYears:a,getYear:u,isBefore:h,isSameYear:p}=n,f=s(e),m=l(t),b=[];let x=f;for(;h(x,m)||p(x,m);)b.push(x),x=a(x,1);return r&&b.reverse(),b.map(y=>{const k=o.formatYearDropdown(y,n);return{value:u(y),label:k,disabled:!1}})}function ta(e,t,o,n){let r=(n??new st(o)).format(e,"PPPP");return t.today&&(r=`Today, ${r}`),t.selected&&(r=`${r}, selected`),r}const c0=ta;function oa(e,t,o){return(o??new st(t)).format(e,"LLLL y")}const d0=oa;function u0(e,t,o,n){let r=(n??new st(o)).format(e,"PPPP");return t!=null&&t.today&&(r=`Today, ${r}`),r}function h0(e){return"Choose the Month"}function p0(){return""}function f0(e){return"Go to the Next Month"}function g0(e){return"Go to the Previous Month"}function m0(e,t,o){return(o??new st(t)).format(e,"cccc")}function b0(e,t){return`Week ${e}`}function x0(e){return"Week Number"}function y0(e){return"Choose the Year"}const v0=Object.freeze(Object.defineProperty({__proto__:null,labelCaption:d0,labelDay:c0,labelDayButton:ta,labelGrid:oa,labelGridcell:u0,labelMonthDropdown:h0,labelNav:p0,labelNext:f0,labelPrevious:g0,labelWeekNumber:b0,labelWeekNumberHeader:x0,labelWeekday:m0,labelYearDropdown:y0},Symbol.toStringTag,{value:"Module"})),to=e=>e instanceof HTMLElement?e:null,Uo=e=>[...e.querySelectorAll("[data-animated-month]")??[]],k0=e=>to(e.querySelector("[data-animated-month]")),Go=e=>to(e.querySelector("[data-animated-caption]")),Ko=e=>to(e.querySelector("[data-animated-weeks]")),w0=e=>to(e.querySelector("[data-animated-nav]")),C0=e=>to(e.querySelector("[data-animated-weekdays]"));function $0(e,t,{classNames:o,months:n,focused:r,dateLib:s}){const l=d.useRef(null),a=d.useRef(n),u=d.useRef(!1);d.useLayoutEffect(()=>{const h=a.current;if(a.current=n,!t||!e.current||!(e.current instanceof HTMLElement)||n.length===0||h.length===0||n.length!==h.length)return;const p=s.isSameMonth(n[0].date,h[0].date),f=s.isAfter(n[0].date,h[0].date),m=f?o[ge.caption_after_enter]:o[ge.caption_before_enter],b=f?o[ge.weeks_after_enter]:o[ge.weeks_before_enter],x=l.current,y=e.current.cloneNode(!0);if(y instanceof HTMLElement?(Uo(y).forEach(C=>{if(!(C instanceof HTMLElement))return;const S=k0(C);S&&C.contains(S)&&C.removeChild(S);const w=Go(C);w&&w.classList.remove(m);const I=Ko(C);I&&I.classList.remove(b)}),l.current=y):l.current=null,u.current||p||r)return;const k=x instanceof HTMLElement?Uo(x):[],v=Uo(e.current);if(v!=null&&v.every($=>$ instanceof HTMLElement)&&k&&k.every($=>$ instanceof HTMLElement)){u.current=!0,e.current.style.isolation="isolate";const $=w0(e.current);$&&($.style.zIndex="1"),v.forEach((C,S)=>{const w=k[S];if(!w)return;C.style.position="relative",C.style.overflow="hidden";const I=Go(C);I&&I.classList.add(m);const j=Ko(C);j&&j.classList.add(b);const D=()=>{u.current=!1,e.current&&(e.current.style.isolation=""),$&&($.style.zIndex=""),I&&I.classList.remove(m),j&&j.classList.remove(b),C.style.position="",C.style.overflow="",C.contains(w)&&C.removeChild(w)};w.style.pointerEvents="none",w.style.position="absolute",w.style.overflow="hidden",w.setAttribute("aria-hidden","true");const L=C0(w);L&&(L.style.opacity="0");const U=Go(w);U&&(U.classList.add(f?o[ge.caption_before_exit]:o[ge.caption_after_exit]),U.addEventListener("animationend",D));const P=Ko(w);P&&P.classList.add(f?o[ge.weeks_before_exit]:o[ge.weeks_after_exit]),C.insertBefore(w,C.firstChild)})}})}function S0(e,t,o,n){const r=e[0],s=e[e.length-1],{ISOWeek:l,fixedWeeks:a,broadcastCalendar:u}=o??{},{addDays:h,differenceInCalendarDays:p,differenceInCalendarMonths:f,endOfBroadcastWeek:m,endOfISOWeek:b,endOfMonth:x,endOfWeek:y,isAfter:k,startOfBroadcastWeek:v,startOfISOWeek:$,startOfWeek:C}=n,S=u?v(r,n):l?$(r):C(r),w=u?m(s):l?b(x(s)):y(x(s)),I=p(w,S),j=f(s,r)+1,D=[];for(let P=0;P<=I;P++){const B=h(S,P);if(t&&k(B,t))break;D.push(B)}const U=(u?35:42)*j;if(a&&D.length<U){const P=U-D.length;for(let B=0;B<P;B++){const Z=h(D[D.length-1],1);D.push(Z)}}return D}function j0(e){const t=[];return e.reduce((o,n)=>{const r=n.weeks.reduce((s,l)=>s.concat(l.days.slice()),t.slice());return o.concat(r.slice())},t.slice())}function I0(e,t,o,n){const{numberOfMonths:r=1}=o,s=[];for(let l=0;l<r;l++){const a=n.addMonths(e,l);if(t&&a>t)break;s.push(a)}return s}function Nr(e,t,o,n){const{month:r,defaultMonth:s,today:l=n.today(),numberOfMonths:a=1}=e;let u=r||s||l;const{differenceInCalendarMonths:h,addMonths:p,startOfMonth:f}=n;if(o&&h(o,u)<a-1){const m=-1*(a-1);u=p(o,m)}return t&&h(u,t)<0&&(u=t),f(u)}function D0(e,t,o,n){const{addDays:r,endOfBroadcastWeek:s,endOfISOWeek:l,endOfMonth:a,endOfWeek:u,getISOWeek:h,getWeek:p,startOfBroadcastWeek:f,startOfISOWeek:m,startOfWeek:b}=n,x=e.reduce((y,k)=>{const v=o.broadcastCalendar?f(k,n):o.ISOWeek?m(k):b(k),$=o.broadcastCalendar?s(k):o.ISOWeek?l(a(k)):u(a(k)),C=t.filter(j=>j>=v&&j<=$),S=o.broadcastCalendar?35:42;if(o.fixedWeeks&&C.length<S){const j=t.filter(D=>{const L=S-C.length;return D>$&&D<=r($,L)});C.push(...j)}const w=C.reduce((j,D)=>{const L=o.ISOWeek?h(D):p(D),U=j.find(B=>B.weekNumber===L),P=new Gi(D,k,n);return U?U.days.push(P):j.push(new bx(L,[P])),j},[]),I=new mx(k,w);return y.push(I),y},[]);return o.reverseMonths?x.reverse():x}function _0(e,t){let{startMonth:o,endMonth:n}=e;const{startOfYear:r,startOfDay:s,startOfMonth:l,endOfMonth:a,addYears:u,endOfYear:h,newDate:p,today:f}=t,{fromYear:m,toYear:b,fromMonth:x,toMonth:y}=e;!o&&x&&(o=x),!o&&m&&(o=t.newDate(m,0,1)),!n&&y&&(n=y),!n&&b&&(n=p(b,11,31));const k=e.captionLayout==="dropdown"||e.captionLayout==="dropdown-years";return o?o=l(o):m?o=p(m,0,1):!o&&k&&(o=r(u(e.today??f(),-100))),n?n=a(n):b?n=p(b,11,31):!n&&k&&(n=h(e.today??f())),[o&&s(o),n&&s(n)]}function T0(e,t,o,n){if(o.disableNavigation)return;const{pagedNavigation:r,numberOfMonths:s=1}=o,{startOfMonth:l,addMonths:a,differenceInCalendarMonths:u}=n,h=r?s:1,p=l(e);if(!t)return a(p,h);if(!(u(t,e)<s))return a(p,h)}function E0(e,t,o,n){if(o.disableNavigation)return;const{pagedNavigation:r,numberOfMonths:s}=o,{startOfMonth:l,addMonths:a,differenceInCalendarMonths:u}=n,h=r?s??1:1,p=l(e);if(!t)return a(p,-h);if(!(u(p,t)<=0))return a(p,-h)}function z0(e){const t=[];return e.reduce((o,n)=>o.concat(n.weeks.slice()),t.slice())}function _o(e,t){const[o,n]=d.useState(e);return[t===void 0?o:t,n]}function M0(e,t){const[o,n]=_0(e,t),{startOfMonth:r,endOfMonth:s}=t,l=Nr(e,o,n,t),[a,u]=_o(l,e.month?l:void 0);d.useEffect(()=>{const I=Nr(e,o,n,t);u(I)},[e.timeZone]);const h=I0(a,n,e,t),p=S0(h,e.endMonth?s(e.endMonth):void 0,e,t),f=D0(h,p,e,t),m=z0(f),b=j0(f),x=E0(a,o,e,t),y=T0(a,n,e,t),{disableNavigation:k,onMonthChange:v}=e,$=I=>m.some(j=>j.days.some(D=>D.isEqualTo(I))),C=I=>{if(k)return;let j=r(I);o&&j<r(o)&&(j=r(o)),n&&j>r(n)&&(j=r(n)),u(j),v==null||v(j)};return{months:f,weeks:m,days:b,navStart:o,navEnd:n,previousMonth:x,nextMonth:y,goToMonth:C,goToDay:I=>{$(I)||C(I.date)}}}var Pe;(function(e){e[e.Today=0]="Today",e[e.Selected=1]="Selected",e[e.LastFocused=2]="LastFocused",e[e.FocusedModifier=3]="FocusedModifier"})(Pe||(Pe={}));function Fr(e){return!e[se.disabled]&&!e[se.hidden]&&!e[se.outside]}function O0(e,t,o,n){let r,s=-1;for(const l of e){const a=t(l);Fr(a)&&(a[se.focused]&&s<Pe.FocusedModifier?(r=l,s=Pe.FocusedModifier):n!=null&&n.isEqualTo(l)&&s<Pe.LastFocused?(r=l,s=Pe.LastFocused):o(l.date)&&s<Pe.Selected?(r=l,s=Pe.Selected):a[se.today]&&s<Pe.Today&&(r=l,s=Pe.Today))}return r||(r=e.find(l=>Fr(t(l)))),r}function R0(e,t,o,n,r,s,l){const{ISOWeek:a,broadcastCalendar:u}=s,{addDays:h,addMonths:p,addWeeks:f,addYears:m,endOfBroadcastWeek:b,endOfISOWeek:x,endOfWeek:y,max:k,min:v,startOfBroadcastWeek:$,startOfISOWeek:C,startOfWeek:S}=l;let I={day:h,week:f,month:p,year:m,startOfWeek:j=>u?$(j,l):a?C(j):S(j),endOfWeek:j=>u?b(j):a?x(j):y(j)}[e](o,t==="after"?1:-1);return t==="before"&&n?I=k([n,I]):t==="after"&&r&&(I=v([r,I])),I}function na(e,t,o,n,r,s,l,a=0){if(a>365)return;const u=R0(e,t,o.date,n,r,s,l),h=!!(s.disabled&&ot(u,s.disabled,l)),p=!!(s.hidden&&ot(u,s.hidden,l)),f=u,m=new Gi(u,f,l);return!h&&!p?m:na(e,t,m,n,r,s,l,a+1)}function N0(e,t,o,n,r){const{autoFocus:s}=e,[l,a]=d.useState(),u=O0(t.days,o,n||(()=>!1),l),[h,p]=d.useState(s?u:void 0);return{isFocusTarget:y=>!!(u!=null&&u.isEqualTo(y)),setFocused:p,focused:h,blur:()=>{a(h),p(void 0)},moveFocus:(y,k)=>{if(!h)return;const v=na(y,k,h,t.navStart,t.navEnd,e,r);v&&(t.goToDay(v),p(v))}}}function F0(e,t){const{selected:o,required:n,onSelect:r}=e,[s,l]=_o(o,r?o:void 0),a=r?o:s,{isSameDay:u}=t,h=b=>(a==null?void 0:a.some(x=>u(x,b)))??!1,{min:p,max:f}=e;return{selected:a,select:(b,x,y)=>{let k=[...a??[]];if(h(b)){if((a==null?void 0:a.length)===p||n&&(a==null?void 0:a.length)===1)return;k=a==null?void 0:a.filter(v=>!u(v,b))}else(a==null?void 0:a.length)===f?k=[b]:k=[...k,b];return r||l(k),r==null||r(k,b,x,y),k},isSelected:h}}function A0(e,t,o=0,n=0,r=!1,s=Ze){const{from:l,to:a}=t||{},{isSameDay:u,isAfter:h,isBefore:p}=s;let f;if(!l&&!a)f={from:e,to:o>0?void 0:e};else if(l&&!a)u(l,e)?o===0?f={from:l,to:e}:r?f={from:l,to:void 0}:f=void 0:p(e,l)?f={from:e,to:l}:f={from:l,to:e};else if(l&&a)if(u(l,e)&&u(a,e))r?f={from:l,to:a}:f=void 0;else if(u(l,e))f={from:l,to:o>0?void 0:e};else if(u(a,e))f={from:e,to:o>0?void 0:e};else if(p(e,l))f={from:e,to:a};else if(h(e,l))f={from:l,to:e};else if(h(e,a))f={from:l,to:e};else throw new Error("Invalid range");if(f!=null&&f.from&&(f!=null&&f.to)){const m=s.differenceInCalendarDays(f.to,f.from);n>0&&m>n?f={from:e,to:void 0}:o>1&&m<o&&(f={from:e,to:void 0})}return f}function L0(e,t,o=Ze){const n=Array.isArray(t)?t:[t];let r=e.from;const s=o.differenceInCalendarDays(e.to,e.from),l=Math.min(s,6);for(let a=0;a<=l;a++){if(n.includes(r.getDay()))return!0;r=o.addDays(r,1)}return!1}function Ar(e,t,o=Ze){return tt(e,t.from,!1,o)||tt(e,t.to,!1,o)||tt(t,e.from,!1,o)||tt(t,e.to,!1,o)}function B0(e,t,o=Ze){const n=Array.isArray(t)?t:[t];if(n.filter(a=>typeof a!="function").some(a=>typeof a=="boolean"?a:o.isDate(a)?tt(e,a,!1,o):Ji(a,o)?a.some(u=>tt(e,u,!1,o)):qn(a)?a.from&&a.to?Ar(e,{from:a.from,to:a.to},o):!1:Xi(a)?L0(e,a.dayOfWeek,o):Yi(a)?o.isAfter(a.before,a.after)?Ar(e,{from:o.addDays(a.after,1),to:o.addDays(a.before,-1)},o):ot(e.from,a,o)||ot(e.to,a,o):qi(a)||Zi(a)?ot(e.from,a,o)||ot(e.to,a,o):!1))return!0;const l=n.filter(a=>typeof a=="function");if(l.length){let a=e.from;const u=o.differenceInCalendarDays(e.to,e.from);for(let h=0;h<=u;h++){if(l.some(p=>p(a)))return!0;a=o.addDays(a,1)}}return!1}function W0(e,t){const{disabled:o,excludeDisabled:n,selected:r,required:s,onSelect:l}=e,[a,u]=_o(r,l?r:void 0),h=l?r:a;return{selected:h,select:(m,b,x)=>{const{min:y,max:k}=e,v=m?A0(m,h,y,k,s,t):void 0;return n&&o&&(v!=null&&v.from)&&v.to&&B0({from:v.from,to:v.to},o,t)&&(v.from=m,v.to=void 0),l||u(v),l==null||l(v,m,b,x),v},isSelected:m=>h&&tt(h,m,!1,t)}}function P0(e,t){const{selected:o,required:n,onSelect:r}=e,[s,l]=_o(o,r?o:void 0),a=r?o:s,{isSameDay:u}=t;return{selected:a,select:(f,m,b)=>{let x=f;return!n&&a&&a&&u(f,a)&&(x=void 0),r||l(x),r==null||r(x,f,m,b),x},isSelected:f=>a?u(a,f):!1}}function V0(e,t){const o=P0(e,t),n=F0(e,t),r=W0(e,t);switch(e.mode){case"single":return o;case"multiple":return n;case"range":return r;default:return}}function H0(e){var nr;let t=e;t.timeZone&&(t={...e},t.today&&(t.today=new ce(t.today,t.timeZone)),t.month&&(t.month=new ce(t.month,t.timeZone)),t.defaultMonth&&(t.defaultMonth=new ce(t.defaultMonth,t.timeZone)),t.startMonth&&(t.startMonth=new ce(t.startMonth,t.timeZone)),t.endMonth&&(t.endMonth=new ce(t.endMonth,t.timeZone)),t.mode==="single"&&t.selected?t.selected=new ce(t.selected,t.timeZone):t.mode==="multiple"&&t.selected?t.selected=(nr=t.selected)==null?void 0:nr.map(H=>new ce(H,t.timeZone)):t.mode==="range"&&t.selected&&(t.selected={from:t.selected.from?new ce(t.selected.from,t.timeZone):void 0,to:t.selected.to?new ce(t.selected.to,t.timeZone):void 0}));const{components:o,formatters:n,labels:r,dateLib:s,locale:l,classNames:a}=d.useMemo(()=>{const H={...Hi,...t.locale};return{dateLib:new st({locale:H,weekStartsOn:t.broadcastCalendar?1:t.weekStartsOn,firstWeekContainsDate:t.firstWeekContainsDate,useAdditionalWeekYearTokens:t.useAdditionalWeekYearTokens,useAdditionalDayOfYearTokens:t.useAdditionalDayOfYearTokens,timeZone:t.timeZone,numerals:t.numerals},t.dateLib),components:Kx(t.components),formatters:r0(t.formatters),labels:{...v0,...t.labels},locale:H,classNames:{...qx(),...t.classNames}}},[t.locale,t.broadcastCalendar,t.weekStartsOn,t.firstWeekContainsDate,t.useAdditionalWeekYearTokens,t.useAdditionalDayOfYearTokens,t.timeZone,t.numerals,t.dateLib,t.components,t.formatters,t.labels,t.classNames]),{captionLayout:u,mode:h,navLayout:p,numberOfMonths:f=1,onDayBlur:m,onDayClick:b,onDayFocus:x,onDayKeyDown:y,onDayMouseEnter:k,onDayMouseLeave:v,onNextClick:$,onPrevClick:C,showWeekNumber:S,styles:w}=t,{formatCaption:I,formatDay:j,formatMonthDropdown:D,formatWeekNumber:L,formatWeekNumberHeader:U,formatWeekdayName:P,formatYearDropdown:B}=n,Z=M0(t,s),{days:ie,months:J,navStart:X,navEnd:je,previousMonth:le,nextMonth:he,goToMonth:Q}=Z,K=Ux(ie,t,X,je,s),{isSelected:ee,select:Xe,selected:Be}=V0(t,s)??{},{blur:Jn,focused:oo,isFocusTarget:da,moveFocus:Qn,setFocused:no}=N0(t,Z,K,ee??(()=>!1),s),{labelDayButton:ua,labelGridcell:ha,labelGrid:pa,labelMonthDropdown:fa,labelNav:er,labelPrevious:ga,labelNext:ma,labelWeekday:ba,labelWeekNumber:xa,labelWeekNumberHeader:ya,labelYearDropdown:va}=r,ka=d.useMemo(()=>a0(s,t.ISOWeek),[s,t.ISOWeek]),tr=h!==void 0||b!==void 0,To=d.useCallback(()=>{le&&(Q(le),C==null||C(le))},[le,Q,C]),Eo=d.useCallback(()=>{he&&(Q(he),$==null||$(he))},[Q,he,$]),wa=d.useCallback((H,te)=>V=>{V.preventDefault(),V.stopPropagation(),no(H),Xe==null||Xe(H.date,te,V),b==null||b(H.date,te,V)},[Xe,b,no]),Ca=d.useCallback((H,te)=>V=>{no(H),x==null||x(H.date,te,V)},[x,no]),$a=d.useCallback((H,te)=>V=>{Jn(),m==null||m(H.date,te,V)},[Jn,m]),Sa=d.useCallback((H,te)=>V=>{const oe={ArrowLeft:[V.shiftKey?"month":"day",t.dir==="rtl"?"after":"before"],ArrowRight:[V.shiftKey?"month":"day",t.dir==="rtl"?"before":"after"],ArrowDown:[V.shiftKey?"year":"week","after"],ArrowUp:[V.shiftKey?"year":"week","before"],PageUp:[V.shiftKey?"year":"month","before"],PageDown:[V.shiftKey?"year":"month","after"],Home:["startOfWeek","before"],End:["endOfWeek","after"]};if(oe[V.key]){V.preventDefault(),V.stopPropagation();const[be,Y]=oe[V.key];Qn(be,Y)}y==null||y(H.date,te,V)},[Qn,y,t.dir]),ja=d.useCallback((H,te)=>V=>{k==null||k(H.date,te,V)},[k]),Ia=d.useCallback((H,te)=>V=>{v==null||v(H.date,te,V)},[v]),Da=d.useCallback(H=>te=>{const V=Number(te.target.value),oe=s.setMonth(s.startOfMonth(H),V);Q(oe)},[s,Q]),_a=d.useCallback(H=>te=>{const V=Number(te.target.value),oe=s.setYear(s.startOfMonth(H),V);Q(oe)},[s,Q]),{className:Ta,style:Ea}=d.useMemo(()=>({className:[a[A.Root],t.className].filter(Boolean).join(" "),style:{...w==null?void 0:w[A.Root],...t.style}}),[a,t.className,t.style,w]),za=Yx(t),or=d.useRef(null);$0(or,!!t.animate,{classNames:a,months:J,focused:oo,dateLib:s});const Ma={dayPickerProps:t,selected:Be,select:Xe,isSelected:ee,months:J,nextMonth:he,previousMonth:le,goToMonth:Q,getModifiers:K,components:o,classNames:a,styles:w,labels:r,formatters:n};return d.createElement(Ki.Provider,{value:Ma},d.createElement(o.Root,{rootRef:t.animate?or:void 0,className:Ta,style:Ea,dir:t.dir,id:t.id,lang:t.lang,nonce:t.nonce,title:t.title,role:t.role,"aria-label":t["aria-label"],...za},d.createElement(o.Months,{className:a[A.Months],style:w==null?void 0:w[A.Months]},!t.hideNavigation&&!p&&d.createElement(o.Nav,{"data-animated-nav":t.animate?"true":void 0,className:a[A.Nav],style:w==null?void 0:w[A.Nav],"aria-label":er(),onPreviousClick:To,onNextClick:Eo,previousMonth:le,nextMonth:he}),J.map((H,te)=>d.createElement(o.Month,{"data-animated-month":t.animate?"true":void 0,className:a[A.Month],style:w==null?void 0:w[A.Month],key:te,displayIndex:te,calendarMonth:H},p==="around"&&!t.hideNavigation&&te===0&&d.createElement(o.PreviousMonthButton,{type:"button",className:a[A.PreviousMonthButton],tabIndex:le?void 0:-1,"aria-disabled":le?void 0:!0,"aria-label":ga(le),onClick:To,"data-animated-button":t.animate?"true":void 0},d.createElement(o.Chevron,{disabled:le?void 0:!0,className:a[A.Chevron],orientation:t.dir==="rtl"?"right":"left"})),d.createElement(o.MonthCaption,{"data-animated-caption":t.animate?"true":void 0,className:a[A.MonthCaption],style:w==null?void 0:w[A.MonthCaption],calendarMonth:H,displayIndex:te},u!=null&&u.startsWith("dropdown")?d.createElement(o.DropdownNav,{className:a[A.Dropdowns],style:w==null?void 0:w[A.Dropdowns]},u==="dropdown"||u==="dropdown-months"?d.createElement(o.MonthsDropdown,{className:a[A.MonthsDropdown],"aria-label":fa(),classNames:a,components:o,disabled:!!t.disableNavigation,onChange:Da(H.date),options:s0(H.date,X,je,n,s),style:w==null?void 0:w[A.Dropdown],value:s.getMonth(H.date)}):d.createElement("span",null,D(H.date,s)),u==="dropdown"||u==="dropdown-years"?d.createElement(o.YearsDropdown,{className:a[A.YearsDropdown],"aria-label":va(s.options),classNames:a,components:o,disabled:!!t.disableNavigation,onChange:_a(H.date),options:l0(X,je,n,s,!!t.reverseYears),style:w==null?void 0:w[A.Dropdown],value:s.getYear(H.date)}):d.createElement("span",null,B(H.date,s)),d.createElement("span",{role:"status","aria-live":"polite",style:{border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap",wordWrap:"normal"}},I(H.date,s.options,s))):d.createElement(o.CaptionLabel,{className:a[A.CaptionLabel],role:"status","aria-live":"polite"},I(H.date,s.options,s))),p==="around"&&!t.hideNavigation&&te===f-1&&d.createElement(o.NextMonthButton,{type:"button",className:a[A.NextMonthButton],tabIndex:he?void 0:-1,"aria-disabled":he?void 0:!0,"aria-label":ma(he),onClick:Eo,"data-animated-button":t.animate?"true":void 0},d.createElement(o.Chevron,{disabled:he?void 0:!0,className:a[A.Chevron],orientation:t.dir==="rtl"?"left":"right"})),te===f-1&&p==="after"&&!t.hideNavigation&&d.createElement(o.Nav,{"data-animated-nav":t.animate?"true":void 0,className:a[A.Nav],style:w==null?void 0:w[A.Nav],"aria-label":er(),onPreviousClick:To,onNextClick:Eo,previousMonth:le,nextMonth:he}),d.createElement(o.MonthGrid,{role:"grid","aria-multiselectable":h==="multiple"||h==="range","aria-label":pa(H.date,s.options,s)||void 0,className:a[A.MonthGrid],style:w==null?void 0:w[A.MonthGrid]},!t.hideWeekdays&&d.createElement(o.Weekdays,{"data-animated-weekdays":t.animate?"true":void 0,className:a[A.Weekdays],style:w==null?void 0:w[A.Weekdays]},S&&d.createElement(o.WeekNumberHeader,{"aria-label":ya(s.options),className:a[A.WeekNumberHeader],style:w==null?void 0:w[A.WeekNumberHeader],scope:"col"},U()),ka.map(V=>d.createElement(o.Weekday,{"aria-label":ba(V,s.options,s),className:a[A.Weekday],key:String(V),style:w==null?void 0:w[A.Weekday],scope:"col"},P(V,s.options,s)))),d.createElement(o.Weeks,{"data-animated-weeks":t.animate?"true":void 0,className:a[A.Weeks],style:w==null?void 0:w[A.Weeks]},H.weeks.map(V=>d.createElement(o.Week,{className:a[A.Week],key:V.weekNumber,style:w==null?void 0:w[A.Week],week:V},S&&d.createElement(o.WeekNumber,{week:V,style:w==null?void 0:w[A.WeekNumber],"aria-label":xa(V.weekNumber,{locale:l}),className:a[A.WeekNumber],scope:"row",role:"rowheader"},L(V.weekNumber,s)),V.days.map(oe=>{const{date:be}=oe,Y=K(oe);if(Y[se.focused]=!Y.hidden&&!!(oo!=null&&oo.isEqualTo(oe)),Y[Ne.selected]=(ee==null?void 0:ee(be))||Y.selected,qn(Be)){const{from:zo,to:Mo}=Be;Y[Ne.range_start]=!!(zo&&Mo&&s.isSameDay(be,zo)),Y[Ne.range_end]=!!(zo&&Mo&&s.isSameDay(be,Mo)),Y[Ne.range_middle]=tt(Be,be,!0,s)}const Oa=i0(Y,w,t.modifiersStyles),Ra=Gx(Y,a,t.modifiersClassNames),Na=!tr&&!Y.hidden?ha(be,Y,s.options,s):void 0;return d.createElement(o.Day,{key:`${s.format(be,"yyyy-MM-dd")}_${s.format(oe.displayMonth,"yyyy-MM")}`,day:oe,modifiers:Y,className:Ra.join(" "),style:Oa,role:"gridcell","aria-selected":Y.selected||void 0,"aria-label":Na,"data-day":s.format(be,"yyyy-MM-dd"),"data-month":oe.outside?s.format(be,"yyyy-MM"):void 0,"data-selected":Y.selected||void 0,"data-disabled":Y.disabled||void 0,"data-hidden":Y.hidden||void 0,"data-outside":oe.outside||void 0,"data-focused":Y.focused||void 0,"data-today":Y.today||void 0},!Y.hidden&&tr?d.createElement(o.DayButton,{className:a[A.DayButton],style:w==null?void 0:w[A.DayButton],type:"button",day:oe,modifiers:Y,disabled:Y.disabled||void 0,tabIndex:da(oe)?0:-1,"aria-label":ua(be,Y,s.options,s),onClick:wa(oe,Y),onBlur:$a(oe,Y),onFocus:Ca(oe,Y),onKeyDown:Sa(oe,Y),onMouseEnter:ja(oe,Y),onMouseLeave:Ia(oe,Y)},j(be,s.options,s)):!Y.hidden&&j(oe.date,s.options,s))})))))))),t.footer&&d.createElement(o.Footer,{className:a[A.Footer],style:w==null?void 0:w[A.Footer],role:"status","aria-live":"polite"},t.footer)))}const U0=d.memo(({...e})=>i.jsx(G0,{mode:"single",...e})),G0=g(H0)`
3180
3186
  font-family: ${c("font-family-default")};
3181
- `,H0=({rightMenu:e,leftMenu:t,className:o})=>i.jsxs(U0,{className:o,children:[t,i.jsx(G0,{children:e})]}),U0=g.div`
3187
+ `,K0=({rightMenu:e,leftMenu:t,className:o})=>i.jsxs(Y0,{className:o,children:[t,i.jsx(q0,{children:e})]}),Y0=g.div`
3182
3188
  align-items: center;
3183
3189
  background-color: ${c("color-black")};
3184
3190
  display: flex;
@@ -3187,10 +3193,10 @@
3187
3193
  justify-content: space-between;
3188
3194
  padding: 0px ${c("spacing-20")};
3189
3195
  width: 100%;
3190
- `,G0=g.div`
3196
+ `,q0=g.div`
3191
3197
  display: flex;
3192
3198
  align-items: center;
3193
- `,K0=d.memo(({title:e,message:t})=>i.jsxs(Y0,{children:[i.jsx(E,{variant:"body",bold:!0,children:e}),i.jsx(E,{variant:"body",color:"grey",children:t})]})),Y0=g.div`
3199
+ `,Z0=d.memo(({title:e,message:t})=>i.jsxs(X0,{children:[i.jsx(E,{variant:"body",bold:!0,children:e}),i.jsx(E,{variant:"body",color:"grey",children:t})]})),X0=g.div`
3194
3200
  display: flex;
3195
3201
  padding: ${c("spacing-8")} ${c("spacing-10")}
3196
3202
  ${c("spacing-8")} ${c("spacing-20")};
@@ -3201,7 +3207,7 @@
3201
3207
  max-width: 100%;
3202
3208
  word-wrap: break-word;
3203
3209
  overflow-wrap: break-word;
3204
- `,q0=({groups:e,onSelectionChange:t,value:o,showSelectAll:n=!0,showClearAll:r=!0,placement:s="bottom-end",className:l,buttonContent:a,disabled:u=!1})=>{const[p,h]=d.useState(()=>{const B={};return e.forEach(Z=>{B[Z.id]=new Set}),B}),[f,m]=d.useState(!1),b=o??p,x=o!==void 0,y=d.useCallback(B=>{x||h(B),t(B)},[x,t]),{refs:k,floatingStyles:v,context:$}=O.useFloating({placement:s,open:f,onOpenChange:m,whileElementsMounted:O.autoUpdate,middleware:[O.offset(4),O.flip(),O.shift({padding:8})]}),C=O.useClick($,{enabled:!u}),S=O.useDismiss($),w=O.useRole($),{getReferenceProps:I,getFloatingProps:j}=O.useInteractions([C,S,w]),D=d.useCallback((B,Z)=>{const ie={...b},J=new Set(b[B]);J.has(Z)?J.delete(Z):J.add(Z),ie[B]=J,y(ie)},[b,y]),L=d.useCallback(B=>{const Z=e.find(J=>J.id===B);if(!Z)return;const ie={...b};ie[B]=new Set(Z.options.map(J=>J.value)),y(ie)},[e,b,y]),U=d.useCallback(()=>{const B={};e.forEach(Z=>{B[Z.id]=new Set}),y(B)},[e,y]),P=d.useMemo(()=>Object.values(b).some(B=>B.size>0),[b]);return i.jsxs(i.Fragment,{children:[i.jsx(Z0,{ref:k.setReference,className:l,$isActive:P,$isDisabled:u,...I(),children:a||i.jsxs(i.Fragment,{children:[i.jsx(R,{iconId:"Filter",size:"sm",color:P?"blue":"grey"}),P&&i.jsx(X0,{})]})}),f&&i.jsx(O.FloatingPortal,{children:i.jsx(O.FloatingFocusManager,{context:$,modal:!1,children:i.jsxs(J0,{ref:k.setFloating,style:v,...j(),children:[i.jsxs(Q0,{children:[i.jsx(E,{variant:"body",bold:!0,children:"Filters"}),i.jsxs(ey,{children:[r&&P&&i.jsx(ty,{onClick:U,children:i.jsx(E,{variant:"small",color:"blue",children:"Clear all"})}),i.jsx(oy,{onClick:()=>m(!1),children:i.jsx(R,{iconId:"Close",size:"sm",color:"grey"})})]})]}),i.jsx(ny,{children:e.map(B=>i.jsxs(ry,{children:[i.jsxs(sy,{children:[i.jsx(E,{variant:"small",bold:!0,children:B.label}),n&&i.jsx(iy,{onClick:()=>L(B.id),children:i.jsx(E,{variant:"small",color:"blue",children:"Select all"})})]}),i.jsx(ay,{children:B.options.map(Z=>{var J;const ie=((J=b[B.id])==null?void 0:J.has(Z.value))||!1;return i.jsxs(ly,{$isSelected:ie,onClick:()=>D(B.id,Z.value),children:[i.jsx(cy,{$isChecked:ie,children:ie&&i.jsx(R,{iconId:"Check",size:"xsm",color:"white"})}),i.jsx(E,{variant:"small",children:Z.label})]},Z.value)})})]},B.id))})]})})})]})},Z0=g.button`
3210
+ `,J0=({groups:e,onSelectionChange:t,value:o,showSelectAll:n=!0,showClearAll:r=!0,placement:s="bottom-end",className:l,buttonContent:a,disabled:u=!1})=>{const[h,p]=d.useState(()=>{const B={};return e.forEach(Z=>{B[Z.id]=new Set}),B}),[f,m]=d.useState(!1),b=o??h,x=o!==void 0,y=d.useCallback(B=>{x||p(B),t(B)},[x,t]),{refs:k,floatingStyles:v,context:$}=O.useFloating({placement:s,open:f,onOpenChange:m,whileElementsMounted:O.autoUpdate,middleware:[O.offset(4),O.flip(),O.shift({padding:8})]}),C=O.useClick($,{enabled:!u}),S=O.useDismiss($),w=O.useRole($),{getReferenceProps:I,getFloatingProps:j}=O.useInteractions([C,S,w]),D=d.useCallback((B,Z)=>{const ie={...b},J=new Set(b[B]);J.has(Z)?J.delete(Z):J.add(Z),ie[B]=J,y(ie)},[b,y]),L=d.useCallback(B=>{const Z=e.find(J=>J.id===B);if(!Z)return;const ie={...b};ie[B]=new Set(Z.options.map(J=>J.value)),y(ie)},[e,b,y]),U=d.useCallback(()=>{const B={};e.forEach(Z=>{B[Z.id]=new Set}),y(B)},[e,y]),P=d.useMemo(()=>Object.values(b).some(B=>B.size>0),[b]);return i.jsxs(i.Fragment,{children:[i.jsx(Q0,{ref:k.setReference,className:l,$isActive:P,$isDisabled:u,...I(),children:a||i.jsxs(i.Fragment,{children:[i.jsx(R,{iconId:"Filter",size:"sm",color:P?"blue":"grey"}),P&&i.jsx(ey,{})]})}),f&&i.jsx(O.FloatingPortal,{children:i.jsx(O.FloatingFocusManager,{context:$,modal:!1,children:i.jsxs(ty,{ref:k.setFloating,style:v,...j(),children:[i.jsxs(oy,{children:[i.jsx(E,{variant:"body",bold:!0,children:"Filters"}),i.jsxs(ny,{children:[r&&P&&i.jsx(ry,{onClick:U,children:i.jsx(E,{variant:"small",color:"blue",children:"Clear all"})}),i.jsx(sy,{onClick:()=>m(!1),children:i.jsx(R,{iconId:"Close",size:"sm",color:"grey"})})]})]}),i.jsx(iy,{children:e.map(B=>i.jsxs(ay,{children:[i.jsxs(ly,{children:[i.jsx(E,{variant:"small",bold:!0,children:B.label}),n&&i.jsx(cy,{onClick:()=>L(B.id),children:i.jsx(E,{variant:"small",color:"blue",children:"Select all"})})]}),i.jsx(dy,{children:B.options.map(Z=>{var J;const ie=((J=b[B.id])==null?void 0:J.has(Z.value))||!1;return i.jsxs(uy,{$isSelected:ie,onClick:()=>D(B.id,Z.value),children:[i.jsx(hy,{$isChecked:ie,children:ie&&i.jsx(R,{iconId:"Check",size:"xsm",color:"white"})}),i.jsx(E,{variant:"small",children:Z.label})]},Z.value)})})]},B.id))})]})})})]})},Q0=g.button`
3205
3211
  display: flex;
3206
3212
  align-items: center;
3207
3213
  justify-content: center;
@@ -3220,7 +3226,7 @@
3220
3226
  background-color: ${e=>e.$isActive?c("color-additional1"):c("color-grey10")};
3221
3227
  border-color: ${e=>e.$isActive?c("color-blue"):c("color-grey40")};
3222
3228
  }
3223
- `,X0=g.div`
3229
+ `,ey=g.div`
3224
3230
  position: absolute;
3225
3231
  top: 4px;
3226
3232
  right: 4px;
@@ -3228,7 +3234,7 @@
3228
3234
  height: 6px;
3229
3235
  background-color: ${c("color-blue")};
3230
3236
  border-radius: 50%;
3231
- `,J0=g.div`
3237
+ `,ty=g.div`
3232
3238
  background-color: ${c("color-white")};
3233
3239
  border: 1px solid ${c("color-grey30")};
3234
3240
  border-radius: ${c("spacing-4")};
@@ -3236,17 +3242,17 @@
3236
3242
  min-width: 280px;
3237
3243
  max-width: 320px;
3238
3244
  z-index: 1000;
3239
- `,Q0=g.div`
3245
+ `,oy=g.div`
3240
3246
  display: flex;
3241
3247
  align-items: center;
3242
3248
  justify-content: space-between;
3243
3249
  padding: ${c("spacing-12")} ${c("spacing-16")};
3244
3250
  border-bottom: 1px solid ${c("color-grey20")};
3245
- `,ey=g.div`
3251
+ `,ny=g.div`
3246
3252
  display: flex;
3247
3253
  align-items: center;
3248
3254
  gap: ${c("spacing-8")};
3249
- `,ty=g.button`
3255
+ `,ry=g.button`
3250
3256
  background: none;
3251
3257
  border: none;
3252
3258
  padding: 0;
@@ -3256,7 +3262,7 @@
3256
3262
  &:hover {
3257
3263
  text-decoration: underline;
3258
3264
  }
3259
- `,oy=g.button`
3265
+ `,sy=g.button`
3260
3266
  background: none;
3261
3267
  border: none;
3262
3268
  padding: 0;
@@ -3271,20 +3277,20 @@
3271
3277
  &:hover {
3272
3278
  background-color: ${c("color-grey10")};
3273
3279
  }
3274
- `,ny=g.div`
3280
+ `,iy=g.div`
3275
3281
  padding: ${c("spacing-12")};
3276
3282
  max-height: 400px;
3277
3283
  overflow-y: auto;
3278
- `,ry=g.div`
3284
+ `,ay=g.div`
3279
3285
  &:not(:last-child) {
3280
3286
  margin-bottom: ${c("spacing-16")};
3281
3287
  }
3282
- `,sy=g.div`
3288
+ `,ly=g.div`
3283
3289
  display: flex;
3284
3290
  align-items: center;
3285
3291
  justify-content: space-between;
3286
3292
  margin-bottom: ${c("spacing-8")};
3287
- `,iy=g.button`
3293
+ `,cy=g.button`
3288
3294
  background: none;
3289
3295
  border: none;
3290
3296
  padding: 0;
@@ -3294,11 +3300,11 @@
3294
3300
  &:hover {
3295
3301
  text-decoration: underline;
3296
3302
  }
3297
- `,ay=g.div`
3303
+ `,dy=g.div`
3298
3304
  display: flex;
3299
3305
  flex-direction: column;
3300
3306
  gap: ${c("spacing-4")};
3301
- `,ly=g.div`
3307
+ `,uy=g.div`
3302
3308
  display: flex;
3303
3309
  align-items: center;
3304
3310
  gap: ${c("spacing-8")};
@@ -3310,7 +3316,7 @@
3310
3316
  &:hover {
3311
3317
  background-color: ${e=>e.$isSelected?c("color-additional1"):c("color-grey10")};
3312
3318
  }
3313
- `,cy=g.div`
3319
+ `,hy=g.div`
3314
3320
  width: 16px;
3315
3321
  height: 16px;
3316
3322
  border: 1.5px solid
@@ -3321,10 +3327,10 @@
3321
3327
  align-items: center;
3322
3328
  justify-content: center;
3323
3329
  flex-shrink: 0;
3324
- `,[dy,Yo,uy]=M(["view-header","option","select"]),Lr=3,Zn=d.memo(({actions:e})=>{const{inlinePrimary:t,overflowPrimary:o,secondary:n}=d.useMemo(()=>{const a=e.filter(p=>p.isPrimary),u=e.filter(p=>!p.isPrimary);return{inlinePrimary:a.slice(0,Lr),overflowPrimary:a.slice(Lr),secondary:u}},[e]),r=o.length>0||n.length>0,s=d.useMemo(()=>{const a=new Map;for(const u of e)a.set(u.id,u);return a},[e]),l=d.useCallback(a=>{const u=s.get(a);u&&!u.disabled&&u.onClick()},[s]);return e.length===0?null:i.jsxs(py,{children:[t.map(a=>i.jsx(ae,{iconId:a.iconId,color:a.color||"grey",size:"sm",onClick:a.onClick,disabled:a.disabled,title:a.tooltip,"aria-label":a.tooltip||a.label||a.id},a.id)),r&&i.jsx(hy,{children:i.jsxs(Fn,{trigger:i.jsx(fy,{title:"More actions",type:"button",children:i.jsx(R,{size:"sm",iconId:"Ellipsis",color:"blue"})}),onSelection:l,children:[o.map(a=>i.jsx(Br,{optionKey:a.id,label:i.jsxs(Wr,{children:[i.jsx(R,{iconId:a.iconId,color:a.disabled?"grey":a.color||"blue",size:"sm"}),i.jsx(Pr,{children:a.label||a.tooltip||a.id})]}),disabled:a.disabled,disableSelectionStyle:!0},a.id)),o.length>0&&n.length>0&&i.jsx(An,{}),n.map(a=>i.jsx(Br,{optionKey:a.id,label:i.jsxs(Wr,{children:[a.iconId?i.jsx(R,{iconId:a.iconId,color:a.disabled?"grey":a.color||"blue",size:"sm"}):i.jsx(gy,{}),i.jsx(Pr,{children:a.label||a.tooltip||a.id})]}),disabled:a.disabled,disableSelectionStyle:!0},a.id))]})})]})});Zn.displayName="ActionBar";const py=g.div`
3330
+ `,[py,Yo,fy]=M(["view-header","option","select"]),Lr=3,Zn=d.memo(({actions:e})=>{const{inlinePrimary:t,overflowPrimary:o,secondary:n}=d.useMemo(()=>{const a=e.filter(h=>h.isPrimary),u=e.filter(h=>!h.isPrimary);return{inlinePrimary:a.slice(0,Lr),overflowPrimary:a.slice(Lr),secondary:u}},[e]),r=o.length>0||n.length>0,s=d.useMemo(()=>{const a=new Map;for(const u of e)a.set(u.id,u);return a},[e]),l=d.useCallback(a=>{const u=s.get(a);u&&!u.disabled&&u.onClick()},[s]);return e.length===0?null:i.jsxs(gy,{children:[t.map(a=>i.jsx(ae,{iconId:a.iconId,color:a.color||"grey",size:"sm",onClick:a.onClick,disabled:a.disabled,title:a.tooltip,"aria-label":a.tooltip||a.label||a.id},a.id)),r&&i.jsx(my,{children:i.jsxs(Fn,{trigger:i.jsx(by,{title:"More actions",type:"button",children:i.jsx(R,{size:"sm",iconId:"Ellipsis",color:"blue"})}),onSelection:l,children:[o.map(a=>i.jsx(Br,{optionKey:a.id,label:i.jsxs(Wr,{children:[i.jsx(R,{iconId:a.iconId,color:a.disabled?"grey":a.color||"blue",size:"sm"}),i.jsx(Pr,{children:a.label||a.tooltip||a.id})]}),disabled:a.disabled,disableSelectionStyle:!0},a.id)),o.length>0&&n.length>0&&i.jsx(An,{}),n.map(a=>i.jsx(Br,{optionKey:a.id,label:i.jsxs(Wr,{children:[a.iconId?i.jsx(R,{iconId:a.iconId,color:a.disabled?"grey":a.color||"blue",size:"sm"}):i.jsx(xy,{}),i.jsx(Pr,{children:a.label||a.tooltip||a.id})]}),disabled:a.disabled,disableSelectionStyle:!0},a.id))]})})]})});Zn.displayName="ActionBar";const gy=g.div`
3325
3331
  display: flex;
3326
3332
  align-items: center;
3327
- gap: ${dy("actions-gap")};
3333
+ gap: ${py("actions-gap")};
3328
3334
  flex-shrink: 0;
3329
3335
  `,Br=g(dt)`
3330
3336
  ${`${Yo("bg-color",!0)}: ${c("color-white")}`};
@@ -3332,9 +3338,9 @@
3332
3338
  ${`${Yo("bg-color-active",!0)}: ${c("color-grey20")}`};
3333
3339
  gap: 0px;
3334
3340
  cursor: pointer;
3335
- `,hy=g.div`
3336
- ${`${uy("border-color",!0)}: ${c("color-grey40")}`};
3337
- `,fy=g.button`
3341
+ `,my=g.div`
3342
+ ${`${fy("border-color",!0)}: ${c("color-grey40")}`};
3343
+ `,by=g.button`
3338
3344
  background: none;
3339
3345
  border: none;
3340
3346
  padding: 4px;
@@ -3366,42 +3372,42 @@
3366
3372
  `,Pr=g.span`
3367
3373
  font-size: 13px;
3368
3374
  white-space: nowrap;
3369
- `,gy=g.div`
3375
+ `,xy=g.div`
3370
3376
  width: 16px;
3371
3377
  height: 16px;
3372
- `,[Ue]=M(["view-header"]),Xn=d.memo(({title:e,subtitle:t,icon:o,actions:n,headerContent:r,collapsible:s,collapsed:l,onToggleCollapse:a})=>{const u=d.useMemo(()=>n&&n.length>0,[n]);return i.jsx(my,{children:i.jsxs(by,{children:[i.jsxs(xy,{children:[s&&i.jsx(ae,{iconId:l?"CaretRight":"CaretDown",color:"grey",size:"sm",onClick:a,"aria-label":l?"Expand view":"Collapse view"}),o&&i.jsx(yy,{children:i.jsx(R,{iconId:o.iconId,color:o.color||"blue",size:"sm"})}),i.jsxs(vy,{children:[i.jsx(E,{variant:"h2",children:e}),t&&i.jsx(ky,{variant:"small",color:"grey",children:t})]})]}),(r||n&&n.length>0)&&i.jsxs(wy,{children:[r,u&&n?i.jsx(Zn,{actions:n}):n==null?void 0:n.map(p=>i.jsx(ae,{iconId:p.iconId,color:p.color||"grey",size:"sm",onClick:p.onClick,disabled:p.disabled,title:p.tooltip,"aria-label":p.tooltip||p.id},p.id))]})]})})});Xn.displayName="ViewHeader";const my=g.div`
3373
- background-color: ${Ue("background-color")};
3374
- border-bottom: ${Ue("border-bottom-width")} solid ${Ue("border-color")};
3375
- padding: ${Ue("padding")};
3376
- `,by=g.div`
3378
+ `,[Ge]=M(["view-header"]),Xn=d.memo(({title:e,subtitle:t,icon:o,actions:n,headerContent:r,collapsible:s,collapsed:l,onToggleCollapse:a})=>{const u=d.useMemo(()=>n&&n.length>0,[n]);return i.jsx(yy,{children:i.jsxs(vy,{children:[i.jsxs(ky,{children:[s&&i.jsx(ae,{iconId:l?"CaretRight":"CaretDown",color:"grey",size:"sm",onClick:a,"aria-label":l?"Expand view":"Collapse view"}),o&&i.jsx(wy,{children:i.jsx(R,{iconId:o.iconId,color:o.color||"blue",size:"sm"})}),i.jsxs(Cy,{children:[i.jsx(E,{variant:"h2",children:e}),t&&i.jsx($y,{variant:"small",color:"grey",children:t})]})]}),(r||n&&n.length>0)&&i.jsxs(Sy,{children:[r,u&&n?i.jsx(Zn,{actions:n}):n==null?void 0:n.map(h=>i.jsx(ae,{iconId:h.iconId,color:h.color||"grey",size:"sm",onClick:h.onClick,disabled:h.disabled,title:h.tooltip,"aria-label":h.tooltip||h.id},h.id))]})]})})});Xn.displayName="ViewHeader";const yy=g.div`
3379
+ background-color: ${Ge("background-color")};
3380
+ border-bottom: ${Ge("border-bottom-width")} solid ${Ge("border-color")};
3381
+ padding: ${Ge("padding")};
3382
+ `,vy=g.div`
3377
3383
  display: flex;
3378
3384
  align-items: center;
3379
3385
  justify-content: space-between;
3380
- gap: ${Ue("gap")};
3381
- min-height: ${Ue("content-min-height")};
3382
- `,xy=g.div`
3386
+ gap: ${Ge("gap")};
3387
+ min-height: ${Ge("content-min-height")};
3388
+ `,ky=g.div`
3383
3389
  display: flex;
3384
3390
  align-items: center;
3385
- gap: ${Ue("left-gap")};
3391
+ gap: ${Ge("left-gap")};
3386
3392
  flex: 1;
3387
3393
  min-width: 0; /* Allow text truncation */
3388
- `,yy=g.div`
3394
+ `,wy=g.div`
3389
3395
  display: flex;
3390
3396
  align-items: center;
3391
3397
  flex-shrink: 0;
3392
- `,vy=g.div`
3398
+ `,Cy=g.div`
3393
3399
  display: flex;
3394
3400
  flex-direction: column;
3395
- gap: ${Ue("text-gap")};
3401
+ gap: ${Ge("text-gap")};
3396
3402
  min-width: 0; /* Allow text truncation */
3397
- `,ky=g(E)`
3398
- font-size: ${Ue("subtitle-font-size")};
3399
- `,wy=g.div`
3403
+ `,$y=g(E)`
3404
+ font-size: ${Ge("subtitle-font-size")};
3405
+ `,Sy=g.div`
3400
3406
  display: flex;
3401
3407
  align-items: center;
3402
- gap: ${Ue("actions-gap")};
3408
+ gap: ${Ge("actions-gap")};
3403
3409
  flex-shrink: 0;
3404
- `,[Bt]=M(["view"]),ra=d.memo(({title:e,subtitle:t,icon:o,actions:n,headerContent:r,collapsible:s=!1,defaultCollapsed:l=!1,collapsed:a,onToggleCollapse:u,children:p,className:h,onFocus:f})=>{const[m,b]=d.useState(l),x=a!==void 0?a:m,y=d.useCallback(()=>{u?u():b(k=>!k)},[u]);return i.jsxs(Cy,{className:h,tabIndex:0,onFocus:f,collapsed:x,children:[i.jsx(Xn,{title:e,subtitle:t,icon:o,actions:n,headerContent:r,collapsible:s,collapsed:x,onToggleCollapse:y}),!x&&i.jsx($y,{children:p})]})});ra.displayName="View";const Cy=g.div`
3410
+ `,[Bt]=M(["view"]),ra=d.memo(({title:e,subtitle:t,icon:o,actions:n,headerContent:r,collapsible:s=!1,defaultCollapsed:l=!1,collapsed:a,onToggleCollapse:u,children:h,className:p,onFocus:f})=>{const[m,b]=d.useState(l),x=a!==void 0?a:m,y=d.useCallback(()=>{u?u():b(k=>!k)},[u]);return i.jsxs(jy,{className:p,tabIndex:0,onFocus:f,collapsed:x,children:[i.jsx(Xn,{title:e,subtitle:t,icon:o,actions:n,headerContent:r,collapsible:s,collapsed:x,onToggleCollapse:y}),!x&&i.jsx(Iy,{children:h})]})});ra.displayName="View";const jy=g.div`
3405
3411
  display: flex;
3406
3412
  flex-direction: column;
3407
3413
  width: 100%;
@@ -3414,13 +3420,13 @@
3414
3420
  ${({collapsed:e})=>e&&`
3415
3421
  flex: 0 0 auto !important;
3416
3422
  `}
3417
- `,$y=g.div`
3423
+ `,Iy=g.div`
3418
3424
  display: flex;
3419
3425
  flex-direction: column;
3420
3426
  flex: 1;
3421
3427
  overflow: auto;
3422
3428
  padding: ${Bt("content-padding")};
3423
- `,[ao]=M(["view-container"]),sa=d.memo(({id:e,direction:t="vertical",gap:o,children:n,className:r})=>i.jsx(Sy,{id:e,direction:t,gap:o,className:r,children:n}));sa.displayName="ViewContainer";const Sy=g.div`
3429
+ `,[ao]=M(["view-container"]),sa=d.memo(({id:e,direction:t="vertical",gap:o,children:n,className:r})=>i.jsx(Dy,{id:e,direction:t,gap:o,className:r,children:n}));sa.displayName="ViewContainer";const Dy=g.div`
3424
3430
  display: flex;
3425
3431
  flex-direction: ${({direction:e})=>e==="vertical"?"column":"row"};
3426
3432
  gap: ${({direction:e,gap:t})=>t!==void 0?typeof t=="number"?`${t}px`:t:ao(e==="vertical"?"vertical-gap":"horizontal-gap")};
@@ -3435,7 +3441,7 @@
3435
3441
  min-height: 0;
3436
3442
  min-width: 0;
3437
3443
  }
3438
- `,jy=d.memo(({listMaxSize:e,listMinSize:t,listCollapsedSize:o,disabled:n,List:r,Details:s,ListPanelComponent:l=Cn})=>i.jsx(Iy,{style:{"--studio-c-table-cell-padding-y":c("spacing-8")},children:i.jsxs(Ts,{direction:"horizontal",children:[i.jsx(l,{minSize:t,maxSize:e,collapsedSize:o,children:i.jsx(ia,{children:i.jsx(r,{disabled:n})})}),i.jsx(Ms,{}),i.jsx(Es,{children:i.jsx(Dy,{children:i.jsx(s,{})})})]})})),Iy=g.div`
3444
+ `,_y=d.memo(({listMaxSize:e,listMinSize:t,listCollapsedSize:o,disabled:n,List:r,Details:s,ListPanelComponent:l=Cn})=>i.jsx(Ty,{style:{"--studio-c-table-cell-padding-y":c("spacing-8")},children:i.jsxs(Ts,{direction:"horizontal",children:[i.jsx(l,{minSize:t,maxSize:e,collapsedSize:o,children:i.jsx(ia,{children:i.jsx(r,{disabled:n})})}),i.jsx(Ms,{}),i.jsx(Es,{children:i.jsx(Ey,{children:i.jsx(s,{})})})]})})),Ty=g.div`
3439
3445
  width: 100%;
3440
3446
  height: 100%;
3441
3447
  display: flex;
@@ -3448,7 +3454,7 @@
3448
3454
  align-items: flex-start;
3449
3455
  justify-content: flex-start;
3450
3456
  flex-direction: column;
3451
- `,Dy=g(ia)`
3457
+ `,Ey=g(ia)`
3452
3458
  overflow: auto;
3453
- `;let dn=null;const _y=()=>dn,Ty=({ref:e,data:t,canDrag:o=!0,transformDragData:n=p=>p,onDrop:r,onDragStart:s,onDragEnd:l,onDragOver:a,onDragLeave:u})=>{const[p,h]=d.useState(!1),[f,m]=d.useState(!1),b=C=>{C.preventDefault(),C.stopPropagation()},x=d.useCallback(C=>{b(C),m(!0),C.dataTransfer&&(C.dataTransfer.dropEffect="move"),a==null||a(C)},[a]),y=d.useCallback(C=>{b(C),m(!1),u==null||u(C)},[u]),k=d.useCallback(C=>{b(C),h(!1),m(!1),dn=null,l==null||l(C)},[l]),v=d.useCallback(C=>{var w;b(C),h(!1),m(!1);let S=null;try{S=JSON.parse(((w=C.dataTransfer)==null?void 0:w.getData("application/json"))??"null")}catch(I){console.error("Invalid drag data:",I)}S&&(r==null||r(S,C))},[r]),$=d.useCallback(C=>{var w;if(!o)return;C.stopPropagation(),h(!0),m(!1),C.dataTransfer&&(C.dataTransfer.effectAllowed="move");const S=n(t);dn=S,(w=C.dataTransfer)==null||w.setData("application/json",JSON.stringify(S)),s==null||s(t,C)},[o,t,s,n]);return d.useEffect(()=>{const C=e.current,S={dragover:w=>x(w),dragenter:w=>x(w),dragleave:w=>y(w),drop:w=>v(w),dragstart:w=>$(w),dragend:w=>k(w)};return C&&Object.entries(S).forEach(([w,I])=>C.addEventListener(w,I)),()=>{Object.entries(S).forEach(([w,I])=>{C&&C.removeEventListener(w,I)})}},[e,x,y,v,$,k]),{dragging:p,over:f}};class Ey{constructor(t){T(this,"model");T(this,"itemsExpression");T(this,"transformer");T(this,"autoDispose");T(this,"_itemsById",_.observable.map(new Map));T(this,"originalItems",new Map);T(this,"_isInitialized",!1);T(this,"_isDisposed",!1);T(this,"_reactionDisposer",null);this.model=t.model,this.itemsExpression=t.itemsExpression,this.transformer=t.transformer,this.autoDispose=t.autoDispose??!0,_.makeObservable(this,{items:_.computed})}get items(){return Array.from(this._itemsById.values()).sort((t,o)=>t.name.localeCompare(o.name))}get isInitialized(){return this._isInitialized}get isDisposed(){return this._isDisposed}async init(){if(!this._isInitialized){if(this._isDisposed)throw new Error("Cannot initialize a disposed ObservableListDataProvider");this._reactionDisposer=_.reaction(()=>{try{if(!this.model)return{raw:[],transformed:[]};const t=this.itemsExpression(this.model)||[],o=t.map(n=>fo(this.transformer(n),n));return{raw:t,transformed:o}}catch{return{raw:[],transformed:[]}}},({raw:t,transformed:o})=>{this.updateItemsFromTransformed(t,o)},{fireImmediately:!0}),this._isInitialized=!0}}dispose(){this._isDisposed||(this._reactionDisposer&&(this._reactionDisposer(),this._reactionDisposer=null),this._itemsById.clear(),this.originalItems.clear(),this._isDisposed=!0,this._isInitialized=!1)}async whenReady(){if(!this._isInitialized)throw new Error("ObservableListDataProvider must be initialized before calling whenReady()");return Promise.resolve()}async refresh(){if(!this._isInitialized||this._isDisposed)return;const t=this.itemsExpression(this.model);this.updateItems(t)}updateItemsFromTransformed(t,o){const n=new Map,r=new Map;o.forEach((s,l)=>{n.set(s.id,s),r.set(s.id,t[l])}),_.runInAction(()=>{for(const[s]of this._itemsById)n.has(s)||(this._itemsById.delete(s),this.originalItems.delete(s));for(const[s,l]of n)this._itemsById.set(s,l),this.originalItems.set(s,r.get(s))})}updateItems(t){const o=t.map(n=>fo(this.transformer(n),n));this.updateItemsFromTransformed(t,o)}}function aa(e){return new Ey(e)}const zy="/kos/model/ready/";class la{constructor(t){T(this,"itemsExpression");T(this,"transformer");T(this,"autoDispose",!0);T(this,"_modelId");T(this,"_context");T(this,"_innerProvider",null);T(this,"_isInitialized",!1);T(this,"_isDisposed",!1);T(this,"_isLoading",!1);T(this,"_eventBusUnsubscribe",null);T(this,"_modelIdReactionDisposer",null);T(this,"_currentModelId");T(this,"_modelType");T(this,"_shouldActivate");T(this,"_items",_.observable.array([]));this._modelType=t.modelType,this._modelId=t.modelId,this._context=t.context,this._shouldActivate=t.activate??!1,this.itemsExpression=t.itemsExpression,this.transformer=t.transformer,_.makeObservable(this,{_innerProvider:_.observable.ref,_isLoading:_.observable,items:_.computed,model:_.computed,isLoading:_.computed})}get model(){var t;return(t=this._innerProvider)==null?void 0:t.model}get items(){var t;return((t=this._innerProvider)==null?void 0:t.items)??[]}get isInitialized(){return this._isInitialized}get isDisposed(){return this._isDisposed}get isLoading(){return this._isLoading||!!this._currentModelId&&!this._innerProvider&&this._isInitialized}get originalItems(){var t;return((t=this._innerProvider)==null?void 0:t.originalItems)??new Map}async init(){if(!this._isInitialized){if(this._isDisposed&&(this._isDisposed=!1),typeof this._modelId=="function"){const t=this._modelId;this._modelIdReactionDisposer=_.reaction(()=>{try{return t(this._context)}catch{return}},o=>{o!==this._currentModelId&&this.handleModelIdChange(o)},{fireImmediately:!0,scheduler:o=>queueMicrotask(o)})}else this._currentModelId=this._modelId,this.subscribeToModelLifecycle(this._modelId);this._isInitialized=!0}}handleModelIdChange(t){this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),_.runInAction(()=>{this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null),this._currentModelId=t}),t&&this.subscribeToModelLifecycle(t)}subscribeToModelLifecycle(t){const o=this.getModelFromManager(t);if(o){this.createInnerProvider(o);return}const n=`${zy}${this._modelType}/${t}`,r=W.EventBus.subscribe(n,()=>{const s=this.getModelFromManager(t);s&&this.createInnerProvider(s)});this._eventBusUnsubscribe=r.unsubscribe}async createInnerProvider(t){if(this._innerProvider)return;const o=aa({model:t,itemsExpression:this.itemsExpression,transformer:this.transformer,autoDispose:!1});_.runInAction(()=>{this._isLoading=!1,this._innerProvider=o}),await o.init()}getModelFromManager(t){var o;try{const n=W.getKosModelSync(t);return this._shouldActivate&&((o=n==null?void 0:n.model)!=null&&o.activate)&&(_.runInAction(()=>{this._isLoading=!0}),n.model.activate().finally(()=>{_.runInAction(()=>{this._isLoading=!1})})),n==null?void 0:n.model}catch{return null}}dispose(){this._isDisposed||(this._modelIdReactionDisposer&&(this._modelIdReactionDisposer(),this._modelIdReactionDisposer=null),this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),_.runInAction(()=>{this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null)}),this._isDisposed=!0,this._isInitialized=!1,this._currentModelId=void 0)}async whenReady(){if(!this._isInitialized)throw new Error("LifecycleAwareListProvider must be initialized before calling whenReady()");return this._innerProvider&&this._innerProvider.whenReady?this._innerProvider.whenReady():Promise.resolve()}async refresh(){return this._innerProvider&&this._innerProvider.refresh?this._innerProvider.refresh():Promise.resolve()}}function My(e){return new la(e)}const Oy="/kos/model/ready/";class Ry extends ui{constructor(o,n,r,s,l,a){super(o,async function(){return n(this)},async function(u){return r(this,u)},a);T(this,"_hasChildrenExpr");T(this,"_childrenExpr");T(this,"_getItemIdFn");this._hasChildrenExpr=s,this._childrenExpr=r,this._getItemIdFn=l,this.rootTrackingFn=u=>{n(u)},this.childTrackingFn=(u,p)=>{r(u,p)}}hasChildren(o){return this._hasChildrenExpr(this.parent,o)}getItemId(o){return this._getItemIdFn(o)}}class ca{constructor(t){T(this,"_modelId");T(this,"_context");T(this,"_innerProvider",null);T(this,"_isInitialized",!1);T(this,"_isInitializing",!1);T(this,"_isDisposed",!1);T(this,"_isLoading",!1);T(this,"_eventBusUnsubscribe",null);T(this,"_modelIdReactionDisposer",null);T(this,"_currentModelId");T(this,"_modelType");T(this,"_shouldActivate");T(this,"_rootsExpression");T(this,"_childrenExpression");T(this,"_hasChildrenExpression");T(this,"_getItemIdFn");T(this,"_transformer");this._modelType=t.modelType,this._modelId=t.modelId,this._context=t.context,this._shouldActivate=t.activate??!1,this._rootsExpression=t.rootsExpression,this._childrenExpression=t.childrenExpression,this._hasChildrenExpression=t.hasChildrenExpression,this._getItemIdFn=t.getItemId,this._transformer=t.transformer,_.makeObservable(this,{_innerProvider:_.observable.ref,_isLoading:_.observable,_isInitialized:_.observable,tree:_.computed,originalItems:_.computed,initialized:_.computed,isLoading:_.computed})}get tree(){var t;return((t=this._innerProvider)==null?void 0:t.tree)??[]}get originalItems(){var t;return((t=this._innerProvider)==null?void 0:t.originalItems)??new Map}get initialized(){var t;return this._isInitialized&&!!((t=this._innerProvider)!=null&&t.initialized)}get isLoading(){return this._isLoading||!!this._currentModelId&&!this._innerProvider&&this._isInitialized}hasChildren(t){return this._innerProvider?this._innerProvider.hasChildren(t):"unknown"}getItemId(t){return this._getItemIdFn(t)}async init(){if(!this._isInitializing){if(this._isInitialized&&(this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),this._modelIdReactionDisposer&&(this._modelIdReactionDisposer(),this._modelIdReactionDisposer=null),this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null),this._isInitialized=!1,this._currentModelId=void 0),this._isDisposed&&(this._isDisposed=!1),this._isInitializing=!0,typeof this._modelId=="function"){const t=this._modelId;this._modelIdReactionDisposer=_.reaction(()=>{try{return t(this._context)}catch{return}},o=>{o!==this._currentModelId&&this.handleModelIdChange(o)},{fireImmediately:!0,scheduler:o=>queueMicrotask(o)})}else this._currentModelId=this._modelId,await this.subscribeToModelLifecycle(this._modelId);_.runInAction(()=>{this._isInitialized=!0,this._isInitializing=!1})}}handleModelIdChange(t){this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),_.runInAction(()=>{this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null),this._currentModelId=t}),t&&this.subscribeToModelLifecycle(t)}async subscribeToModelLifecycle(t){if(this._innerProvider)return;const o=this.getModelFromManager(t);if(o){await this.createInnerProvider(o);return}const n=`${Oy}${this._modelType}/${t}`,r=W.EventBus.subscribe(n,()=>{const s=this.getModelFromManager(t);s&&this.createInnerProvider(s)});this._eventBusUnsubscribe=r.unsubscribe}async createInnerProvider(t){if(this._innerProvider)return;const o=new Ry(t,this._rootsExpression,this._childrenExpression,this._hasChildrenExpression,this._getItemIdFn,this._transformer);_.runInAction(()=>{this._isLoading=!1,this._innerProvider=o}),await o.init()}getModelFromManager(t){var o;try{const n=W.getKosModelSync(t);return this._shouldActivate&&((o=n==null?void 0:n.model)!=null&&o.activate)&&(_.runInAction(()=>{this._isLoading=!0}),n.model.activate().finally(()=>{_.runInAction(()=>{this._isLoading=!1})})),n==null?void 0:n.model}catch{return null}}async expandBranch(t,o){return this._innerProvider?this._innerProvider.expandBranch(t,o):Promise.resolve()}async expandAll(){return this._innerProvider?this._innerProvider.expandAll():Promise.resolve()}collapseBranch(t){this._innerProvider&&this._innerProvider.collapseBranch(t)}clearCache(t){this._innerProvider&&this._innerProvider.clearCache(t)}refresh(){this._innerProvider&&this._innerProvider.refresh()}async whenReady(){return this._innerProvider?this._innerProvider.whenReady():Promise.resolve()}dispose(){this._isDisposed||(this._modelIdReactionDisposer&&(this._modelIdReactionDisposer(),this._modelIdReactionDisposer=null),this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),_.runInAction(()=>{this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null)}),this._isDisposed=!0,this._isInitialized=!1,this._isInitializing=!1,this._currentModelId=void 0)}}function Ny(e){return new ca(e)}Object.defineProperty(exports,"useFormContext",{enumerable:!0,get:()=>q.useFormContext});Object.defineProperty(exports,"useFormController",{enumerable:!0,get:()=>q.useController});Object.defineProperty(exports,"useWatchForm",{enumerable:!0,get:()=>q.useWatch});Object.defineProperty(exports,"renderTableContents",{enumerable:!0,get:()=>ke.flexRender});exports.ActionBar=Zn;exports.ActionSelect=Uu;exports.ActionableBlurb=xc;exports.AlertTooltip=_n;exports.AlternatingStatus=Wc;exports.AnimatePresence=ns;exports.AnonymousBranch=og;exports.AnonymousGroup=Tf;exports.ArtifactVersion=Lp;exports.AsyncList=ii;exports.AsyncListGroupHeader=Rn;exports.AsyncNamedCollapsibleBranch=sg;exports.AsyncSelectViewList=Jh;exports.AsyncTreeList=Si;exports.Badge=hp;exports.BaseAsyncTreeDataProvider=ui;exports.BaseModalContent=$g;exports.BaseObservableDataProvider=Wn;exports.BaseUIComponentsContextProvider=gc;exports.BottomDialogDrawer=Dd;exports.BottomInlineDrawer=Od;exports.BrandedHeader=Hm;exports.Button=Ge;exports.ButtonGroup=Kc;exports.ButtonGroupItem=is;exports.CheckBox=_t;exports.CheckListItemCheck=$o;exports.CheckListItemCheckCompact=bi;exports.CheckListItemContainer=Qt;exports.CheckListItemContainerCompact=Un;exports.CheckListItemContainerWithDivider=gi;exports.CheckListItemContainerWithDividerCompact=mi;exports.CheckListItemName=So;exports.CheckListItemNameCompact=xi;exports.CheckListItemTemplate=yi;exports.Collapsible=go;exports.CollapsibleArtifact=_c;exports.CollapsibleContent=mo;exports.CollapsibleList=Up;exports.CollapsibleTrigger=fn;exports.ComboBox=Xs;exports.CopyableText=ld;exports.DarkTooltip=wo;exports.DarkTooltipStyle=Ps;exports.DatePicker=P0;exports.DescriptionListItemTemplate=Ff;exports.Dialog=gn;exports.DialogContent=bn;exports.DialogTrigger=mn;exports.Drawer=Nd;exports.DrawerContent=Ad;exports.DrawerHeader=Ld;exports.DrawerTrigger=Fd;exports.Dropdown=ni;exports.DropdownMenu=Fn;exports.EMAIL_PATTERN=vs;exports.EmailRequirementKeys=ws;exports.EmptyListMessage=K0;exports.EndOverlayStyle=md;exports.ErrorTooltip=Hs;exports.FIRST_CHAR_ALPHA=nu;exports.FakeInputReference=Js;exports.FilterPanel=q0;exports.FlexHandle=Zt;exports.FlexResizablePanel=Es;exports.Form=Qs;exports.FormAccessToggles=Oh;exports.FormCheckbox=Eh;exports.FormComboBox=Ah;exports.FormErrorMessage=Ke;exports.FormField=_h;exports.FormFileInput=Wh;exports.FormInput=Mn;exports.FormInputWrapper=Ye;exports.FormLabel=Se;exports.FormMultiSelect=Gh;exports.FormNameInput=Fh;exports.FormSelect=Ih;exports.FormSubmit=zn;exports.FormTextArea=Ch;exports.FormToggle=vh;exports.GroupContext=Hn;exports.GroupList=Df;exports.GroupedObservableDataProvider=Cf;exports.HiddenFormInput=En;exports.HolderListItemTemplate=Sm;exports.HorizontalRule=Wd;exports.Icon=R;exports.IconButton=ae;exports.Input=Tt;exports.InputSearch=Gd;exports.ItemActionBar=Jt;exports.ItemSelectionList=bm;exports.ItemSelectionListDataProvider=vm;exports.KOSLogo=Ap;exports.Label=ys;exports.LabelWithAction=Zd;exports.LabelWithContent=vn;exports.LabelWithContentLink=Qd;exports.LeftDialogDrawer=kd;exports.LeftInlineDrawer=Ed;exports.LifecycleAwareListProvider=la;exports.LifecycleAwareTreeProvider=ca;exports.LightTooltip=ko;exports.LightTooltipStyle=Bs;exports.Link=hn;exports.List=Vn;exports.ListContext=Ln;exports.ListContextProvider=Bn;exports.ListWithDetailsLayout=jy;exports.LockedButton=jc;exports.MenuWrapper=H0;exports.MiddleTruncateText=bo;exports.Modal=Bg;exports.ModalOverlayStyles=Ei;exports.ModalTrigger=Wg;exports.MultiSelect=Zs;exports.NO_LEADING_OR_TRAILING_SPACES_PATTERN=ks;exports.NO_SPACES_PATTERN=ou;exports.NUMBERS_ONLY_PATTERN=tu;exports.NamedCollapsibleBranch=gg;exports.NamedCollapsibleGroup=_f;exports.NamedListItemTemplate=Af;exports.NamedSection=Mi;exports.NamedSectionHeader=Gg;exports.ObservableDataProvider=Pn;exports.Option=dt;exports.PASSWORD_MIN_LENGTH=su;exports.PASSWORD_REQUIREMENTS=Tn;exports.PASSWORD_REQUIREMENTS_TOO_SIMILAR=ti;exports.PageHeader=Jg;exports.PaneSplitter=mu;exports.PasswordRequirementKeys=Wt;exports.PasswordRequirementsList=mh;exports.PropertyDataProvider=$f;exports.RadioButton=kn;exports.RequirementsList=ei;exports.ResizablePanel=Cn;exports.ResizablePanelGroup=Ts;exports.ResizablePanelGroupContextProvider=_s;exports.ResizablePanelHandle=Ms;exports.RightDialogDrawer=$d;exports.RightInlineDrawer=zd;exports.SOURCE_PROP_KEY=Gt;exports.SOURCE_SYMBOL=On;exports.ScreenOverlay=Os;exports.ScreenOverlayWithAction=jb;exports.Select=Et;exports.SelectAsyncTreeList=tg;exports.SelectContext=jn;exports.SelectList=Co;exports.SelectListContext=mt;exports.SelectSeparator=An;exports.SelectViewList=lm;exports.SelectViewListItem=Ri;exports.SelectorTooltip=Us;exports.ShellIconButton=Zu;exports.ShellMenu=km;exports.ShellMenuLink=Cm;exports.StartOverlayStyle=gd;exports.StickyObserver=sn;exports.StudioNamedListItem=li;exports.StudioSelectViewListItem=ci;exports.StyledSelectOption=ef;exports.Tab=Xu;exports.TabPane=ip;exports.TabTrigger=Ju;exports.TabTriggerList=np;exports.Table=Zm;exports.TableHeader=ln;exports.TableNamedListItemTemplate=Uf;exports.TableTd=Yn;exports.Tag=ho;exports.TagWithRemove=up;exports.Text=E;exports.TextHighlight=pp;exports.Textarea=Dn;exports.Toggle=vo;exports.ToggleThumb=As;exports.ToggleTrack=Fs;exports.Tooltip=Gs;exports.TopDialogDrawer=Id;exports.TopInlineDrawer=Md;exports.TreeDataProvider=qf;exports.TreeList=Jf;exports.USERNAME_PATTERN=eu;exports.View=ra;exports.ViewActionContext=Nn;exports.ViewContainer=sa;exports.ViewHeader=Xn;exports.VirtualList=ji;exports.VirtualTable=yb;exports.VirtualizedList=Ii;exports.VirtualizedSelectList=Cg;exports.attachSource=fo;exports.baseComponentStyles=Ur;exports.baseGenericStyles=Zo;exports.baseSemanticStyles=Xo;exports.componentStudioTokenCss=Ql;exports.componentStyles=qo;exports.createLifecycleAwareProvider=My;exports.createLifecycleAwareTreeProvider=Ny;exports.createLocalComponentHelper=ql;exports.createLocalComponentTokenCss=Zl;exports.createLocalTokenSystem=Yl;exports.createObservableListProvider=aa;exports.createTableColumnHelper=nb;exports.darkTooltipArrow=Vs;exports.getByteString=nm;exports.getComponentTokenHelpers=M;exports.getCurrentDragData=_y;exports.getEmailValidation=ru;exports.getErrorMessage=au;exports.getGlobalToken=F;exports.getPasswordValidation=iu;exports.getPropertyWithFallback=Kh;exports.getSemanticToken=c;exports.getSource=Kt;exports.getStyles=rc;exports.globalStudioTokenCss=Jl;exports.isContextAware=rn;exports.isErrorWithMessage=Cs;exports.isGroupFactory=pi;exports.isItemTemplateFactory=si;exports.isLockedAware=Yh;exports.keyResolver=di;exports.lightTooltipArrow=Ws;exports.noop=$e;exports.normalizePathDisplay=rm;exports.rootStyles=Jo;exports.scrollbarStyle=lc;exports.semanticStudioTokenCss=Xl;exports.stringComponentInsert=Hr;exports.studioColors=Gr;exports.studioDarkColors=Yr;exports.studioGenericColor=qr;exports.studioLightColors=Kr;exports.studioTheme=cc;exports.transformLocalTokenObject=un;exports.useBaseUIComponentsContext=Jr;exports.useButtonGroupContext=ss;exports.useCollapsibleContext=qt;exports.useContainerWidth=yn;exports.useDialogContext=nt;exports.useDialogContextValue=as;exports.useDragDrop=Ty;exports.useDrawerContext=ut;exports.useGroupSelection=Kf;exports.useListContext=af;exports.useListGroupContext=hi;exports.useLoadDataProvider=Xt;exports.useModalContext=nt;exports.useMultiSelectContext=Ys;exports.useOpenedGroups=Gf;exports.useResizablePanelGroupContext=wn;exports.useResizeObserver=$s;exports.useSelectContext=In;exports.useSelectListContext=Ae;exports.useSelection=Yf;exports.useTabContext=yo;exports.useTableContext=Kn;exports.useTreeListContext=ki;exports.useViewActionContext=ai;
3459
+ `;let dn=null;const zy=()=>dn,My=({ref:e,data:t,canDrag:o=!0,transformDragData:n=h=>h,onDrop:r,onDragStart:s,onDragEnd:l,onDragOver:a,onDragLeave:u})=>{const[h,p]=d.useState(!1),[f,m]=d.useState(!1),b=C=>{C.preventDefault(),C.stopPropagation()},x=d.useCallback(C=>{b(C),m(!0),C.dataTransfer&&(C.dataTransfer.dropEffect="move"),a==null||a(C)},[a]),y=d.useCallback(C=>{b(C),m(!1),u==null||u(C)},[u]),k=d.useCallback(C=>{b(C),p(!1),m(!1),dn=null,l==null||l(C)},[l]),v=d.useCallback(C=>{var w;b(C),p(!1),m(!1);let S=null;try{S=JSON.parse(((w=C.dataTransfer)==null?void 0:w.getData("application/json"))??"null")}catch(I){console.error("Invalid drag data:",I)}S&&(r==null||r(S,C))},[r]),$=d.useCallback(C=>{var w;if(!o)return;C.stopPropagation(),p(!0),m(!1),C.dataTransfer&&(C.dataTransfer.effectAllowed="move");const S=n(t);dn=S,(w=C.dataTransfer)==null||w.setData("application/json",JSON.stringify(S)),s==null||s(t,C)},[o,t,s,n]);return d.useEffect(()=>{const C=e.current,S={dragover:w=>x(w),dragenter:w=>x(w),dragleave:w=>y(w),drop:w=>v(w),dragstart:w=>$(w),dragend:w=>k(w)};return C&&Object.entries(S).forEach(([w,I])=>C.addEventListener(w,I)),()=>{Object.entries(S).forEach(([w,I])=>{C&&C.removeEventListener(w,I)})}},[e,x,y,v,$,k]),{dragging:h,over:f}};class Oy{constructor(t){T(this,"model");T(this,"itemsExpression");T(this,"transformer");T(this,"autoDispose");T(this,"_itemsById",_.observable.map(new Map));T(this,"originalItems",new Map);T(this,"_isInitialized",!1);T(this,"_isDisposed",!1);T(this,"_reactionDisposer",null);this.model=t.model,this.itemsExpression=t.itemsExpression,this.transformer=t.transformer,this.autoDispose=t.autoDispose??!0,_.makeObservable(this,{items:_.computed})}get items(){return Array.from(this._itemsById.values()).sort((t,o)=>t.name.localeCompare(o.name))}get isInitialized(){return this._isInitialized}get isDisposed(){return this._isDisposed}async init(){if(!this._isInitialized){if(this._isDisposed)throw new Error("Cannot initialize a disposed ObservableListDataProvider");this._reactionDisposer=_.reaction(()=>{try{if(!this.model)return{raw:[],transformed:[]};const t=this.itemsExpression(this.model)||[],o=t.map(n=>fo(this.transformer(n),n));return{raw:t,transformed:o}}catch{return{raw:[],transformed:[]}}},({raw:t,transformed:o})=>{this.updateItemsFromTransformed(t,o)},{fireImmediately:!0}),this._isInitialized=!0}}dispose(){this._isDisposed||(this._reactionDisposer&&(this._reactionDisposer(),this._reactionDisposer=null),this._itemsById.clear(),this.originalItems.clear(),this._isDisposed=!0,this._isInitialized=!1)}async whenReady(){if(!this._isInitialized)throw new Error("ObservableListDataProvider must be initialized before calling whenReady()");return Promise.resolve()}async refresh(){if(!this._isInitialized||this._isDisposed)return;const t=this.itemsExpression(this.model);this.updateItems(t)}updateItemsFromTransformed(t,o){const n=new Map,r=new Map;o.forEach((s,l)=>{n.set(s.id,s),r.set(s.id,t[l])}),_.runInAction(()=>{for(const[s]of this._itemsById)n.has(s)||(this._itemsById.delete(s),this.originalItems.delete(s));for(const[s,l]of n)this._itemsById.set(s,l),this.originalItems.set(s,r.get(s))})}updateItems(t){const o=t.map(n=>fo(this.transformer(n),n));this.updateItemsFromTransformed(t,o)}}function aa(e){return new Oy(e)}const Ry="/kos/model/ready/";class la{constructor(t){T(this,"itemsExpression");T(this,"transformer");T(this,"autoDispose",!0);T(this,"_modelId");T(this,"_context");T(this,"_innerProvider",null);T(this,"_isInitialized",!1);T(this,"_isDisposed",!1);T(this,"_isLoading",!1);T(this,"_eventBusUnsubscribe",null);T(this,"_modelIdReactionDisposer",null);T(this,"_currentModelId");T(this,"_modelType");T(this,"_shouldActivate");T(this,"_items",_.observable.array([]));this._modelType=t.modelType,this._modelId=t.modelId,this._context=t.context,this._shouldActivate=t.activate??!1,this.itemsExpression=t.itemsExpression,this.transformer=t.transformer,_.makeObservable(this,{_innerProvider:_.observable.ref,_isLoading:_.observable,items:_.computed,model:_.computed,isLoading:_.computed})}get model(){var t;return(t=this._innerProvider)==null?void 0:t.model}get items(){var t;return((t=this._innerProvider)==null?void 0:t.items)??[]}get isInitialized(){return this._isInitialized}get isDisposed(){return this._isDisposed}get isLoading(){return this._isLoading||!!this._currentModelId&&!this._innerProvider&&this._isInitialized}get originalItems(){var t;return((t=this._innerProvider)==null?void 0:t.originalItems)??new Map}async init(){if(!this._isInitialized){if(this._isDisposed&&(this._isDisposed=!1),typeof this._modelId=="function"){const t=this._modelId;this._modelIdReactionDisposer=_.reaction(()=>{try{return t(this._context)}catch{return}},o=>{o!==this._currentModelId&&this.handleModelIdChange(o)},{fireImmediately:!0,scheduler:o=>queueMicrotask(o)})}else this._currentModelId=this._modelId,this.subscribeToModelLifecycle(this._modelId);this._isInitialized=!0}}handleModelIdChange(t){this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),_.runInAction(()=>{this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null),this._currentModelId=t}),t&&this.subscribeToModelLifecycle(t)}subscribeToModelLifecycle(t){const o=this.getModelFromManager(t);if(o){this.createInnerProvider(o);return}const n=`${Ry}${this._modelType}/${t}`,r=W.EventBus.subscribe(n,()=>{const s=this.getModelFromManager(t);s&&this.createInnerProvider(s)});this._eventBusUnsubscribe=r.unsubscribe}async createInnerProvider(t){if(this._innerProvider)return;const o=aa({model:t,itemsExpression:this.itemsExpression,transformer:this.transformer,autoDispose:!1});_.runInAction(()=>{this._isLoading=!1,this._innerProvider=o}),await o.init()}getModelFromManager(t){var o;try{const n=W.getKosModelSync(t);return this._shouldActivate&&((o=n==null?void 0:n.model)!=null&&o.activate)&&(_.runInAction(()=>{this._isLoading=!0}),n.model.activate().finally(()=>{_.runInAction(()=>{this._isLoading=!1})})),n==null?void 0:n.model}catch{return null}}dispose(){this._isDisposed||(this._modelIdReactionDisposer&&(this._modelIdReactionDisposer(),this._modelIdReactionDisposer=null),this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),_.runInAction(()=>{this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null)}),this._isDisposed=!0,this._isInitialized=!1,this._currentModelId=void 0)}async whenReady(){if(!this._isInitialized)throw new Error("LifecycleAwareListProvider must be initialized before calling whenReady()");return this._innerProvider&&this._innerProvider.whenReady?this._innerProvider.whenReady():Promise.resolve()}async refresh(){return this._innerProvider&&this._innerProvider.refresh?this._innerProvider.refresh():Promise.resolve()}}function Ny(e){return new la(e)}const Fy="/kos/model/ready/";class Ay extends ui{constructor(o,n,r,s,l,a){super(o,async function(){return n(this)},async function(u){return r(this,u)},a);T(this,"_hasChildrenExpr");T(this,"_childrenExpr");T(this,"_getItemIdFn");this._hasChildrenExpr=s,this._childrenExpr=r,this._getItemIdFn=l,this.rootTrackingFn=u=>{n(u)},this.childTrackingFn=(u,h)=>{r(u,h)}}hasChildren(o){return this._hasChildrenExpr(this.parent,o)}getItemId(o){return this._getItemIdFn(o)}}class ca{constructor(t){T(this,"_modelId");T(this,"_context");T(this,"_innerProvider",null);T(this,"_isInitialized",!1);T(this,"_isInitializing",!1);T(this,"_isDisposed",!1);T(this,"_isLoading",!1);T(this,"_eventBusUnsubscribe",null);T(this,"_modelIdReactionDisposer",null);T(this,"_currentModelId");T(this,"_modelType");T(this,"_shouldActivate");T(this,"_rootsExpression");T(this,"_childrenExpression");T(this,"_hasChildrenExpression");T(this,"_getItemIdFn");T(this,"_transformer");this._modelType=t.modelType,this._modelId=t.modelId,this._context=t.context,this._shouldActivate=t.activate??!1,this._rootsExpression=t.rootsExpression,this._childrenExpression=t.childrenExpression,this._hasChildrenExpression=t.hasChildrenExpression,this._getItemIdFn=t.getItemId,this._transformer=t.transformer,_.makeObservable(this,{_innerProvider:_.observable.ref,_isLoading:_.observable,_isInitialized:_.observable,tree:_.computed,originalItems:_.computed,initialized:_.computed,isLoading:_.computed})}get tree(){var t;return((t=this._innerProvider)==null?void 0:t.tree)??[]}get originalItems(){var t;return((t=this._innerProvider)==null?void 0:t.originalItems)??new Map}get initialized(){var t;return this._isInitialized&&!!((t=this._innerProvider)!=null&&t.initialized)}get isLoading(){return this._isLoading||!!this._currentModelId&&!this._innerProvider&&this._isInitialized}hasChildren(t){return this._innerProvider?this._innerProvider.hasChildren(t):"unknown"}getItemId(t){return this._getItemIdFn(t)}async init(){if(!this._isInitializing){if(this._isInitialized&&(this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),this._modelIdReactionDisposer&&(this._modelIdReactionDisposer(),this._modelIdReactionDisposer=null),this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null),this._isInitialized=!1,this._currentModelId=void 0),this._isDisposed&&(this._isDisposed=!1),this._isInitializing=!0,typeof this._modelId=="function"){const t=this._modelId;this._modelIdReactionDisposer=_.reaction(()=>{try{return t(this._context)}catch{return}},o=>{o!==this._currentModelId&&this.handleModelIdChange(o)},{fireImmediately:!0,scheduler:o=>queueMicrotask(o)})}else this._currentModelId=this._modelId,await this.subscribeToModelLifecycle(this._modelId);_.runInAction(()=>{this._isInitialized=!0,this._isInitializing=!1})}}handleModelIdChange(t){this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),_.runInAction(()=>{this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null),this._currentModelId=t}),t&&this.subscribeToModelLifecycle(t)}async subscribeToModelLifecycle(t){if(this._innerProvider)return;const o=this.getModelFromManager(t);if(o){await this.createInnerProvider(o);return}const n=`${Fy}${this._modelType}/${t}`,r=W.EventBus.subscribe(n,()=>{const s=this.getModelFromManager(t);s&&this.createInnerProvider(s)});this._eventBusUnsubscribe=r.unsubscribe}async createInnerProvider(t){if(this._innerProvider)return;const o=new Ay(t,this._rootsExpression,this._childrenExpression,this._hasChildrenExpression,this._getItemIdFn,this._transformer);_.runInAction(()=>{this._isLoading=!1,this._innerProvider=o}),await o.init()}getModelFromManager(t){var o;try{const n=W.getKosModelSync(t);return this._shouldActivate&&((o=n==null?void 0:n.model)!=null&&o.activate)&&(_.runInAction(()=>{this._isLoading=!0}),n.model.activate().finally(()=>{_.runInAction(()=>{this._isLoading=!1})})),n==null?void 0:n.model}catch{return null}}async expandBranch(t,o){return this._innerProvider?this._innerProvider.expandBranch(t,o):Promise.resolve()}async expandAll(){return this._innerProvider?this._innerProvider.expandAll():Promise.resolve()}collapseBranch(t){this._innerProvider&&this._innerProvider.collapseBranch(t)}clearCache(t){this._innerProvider&&this._innerProvider.clearCache(t)}refresh(){this._innerProvider&&this._innerProvider.refresh()}async whenReady(){return this._innerProvider?this._innerProvider.whenReady():Promise.resolve()}dispose(){this._isDisposed||(this._modelIdReactionDisposer&&(this._modelIdReactionDisposer(),this._modelIdReactionDisposer=null),this._eventBusUnsubscribe&&(this._eventBusUnsubscribe(),this._eventBusUnsubscribe=null),_.runInAction(()=>{this._innerProvider&&(this._innerProvider.dispose(),this._innerProvider=null)}),this._isDisposed=!0,this._isInitialized=!1,this._isInitializing=!1,this._currentModelId=void 0)}}function Ly(e){return new ca(e)}Object.defineProperty(exports,"useFormContext",{enumerable:!0,get:()=>G.useFormContext});Object.defineProperty(exports,"useFormController",{enumerable:!0,get:()=>G.useController});Object.defineProperty(exports,"useWatchForm",{enumerable:!0,get:()=>G.useWatch});Object.defineProperty(exports,"renderTableContents",{enumerable:!0,get:()=>we.flexRender});exports.ActionBar=Zn;exports.ActionSelect=Uu;exports.ActionableBlurb=xc;exports.AlertTooltip=_n;exports.AlternatingStatus=Wc;exports.AnimatePresence=ns;exports.AnonymousBranch=sg;exports.AnonymousGroup=Mf;exports.ArtifactVersion=Lh;exports.AsyncList=ii;exports.AsyncListGroupHeader=Rn;exports.AsyncNamedCollapsibleBranch=lg;exports.AsyncSelectViewList=tf;exports.AsyncTreeList=Si;exports.Badge=ph;exports.BaseAsyncTreeDataProvider=ui;exports.BaseModalContent=Ig;exports.BaseObservableDataProvider=Wn;exports.BaseUIComponentsContextProvider=gc;exports.BottomDialogDrawer=Dd;exports.BottomInlineDrawer=Od;exports.BrandedHeader=Km;exports.Button=Ke;exports.ButtonGroup=Kc;exports.ButtonGroupItem=is;exports.CheckBox=_t;exports.CheckListItemCheck=$o;exports.CheckListItemCheckCompact=bi;exports.CheckListItemContainer=Qt;exports.CheckListItemContainerCompact=Un;exports.CheckListItemContainerWithDivider=gi;exports.CheckListItemContainerWithDividerCompact=mi;exports.CheckListItemName=So;exports.CheckListItemNameCompact=xi;exports.CheckListItemTemplate=yi;exports.Collapsible=go;exports.CollapsibleArtifact=_c;exports.CollapsibleContent=mo;exports.CollapsibleList=Uh;exports.CollapsibleTrigger=fn;exports.ComboBox=Xs;exports.CopyableText=ld;exports.DarkTooltip=wo;exports.DarkTooltipStyle=Ps;exports.DatePicker=U0;exports.DescriptionListItemTemplate=Bf;exports.Dialog=gn;exports.DialogContent=bn;exports.DialogTrigger=mn;exports.Drawer=Nd;exports.DrawerContent=Ad;exports.DrawerHeader=Ld;exports.DrawerTrigger=Fd;exports.Dropdown=ni;exports.DropdownMenu=Fn;exports.EMAIL_PATTERN=vs;exports.EmailRequirementKeys=ws;exports.EmptyListMessage=Z0;exports.EndOverlayStyle=md;exports.ErrorTooltip=Hs;exports.FIRST_CHAR_ALPHA=nu;exports.FakeInputReference=Js;exports.FilterPanel=J0;exports.FlexHandle=Zt;exports.FlexResizablePanel=Es;exports.Form=Qs;exports.FormAccessToggles=Op;exports.FormCheckbox=Ep;exports.FormComboBox=Ap;exports.FormErrorMessage=Ye;exports.FormField=_p;exports.FormFileInput=Wp;exports.FormHiddenField=Kp;exports.FormInput=Mn;exports.FormInputWrapper=Ae;exports.FormLabel=me;exports.FormMultiSelect=Gp;exports.FormNameInput=Fp;exports.FormSelect=Ip;exports.FormStaticField=Yp;exports.FormSubmit=zn;exports.FormTextArea=Cp;exports.FormToggle=vp;exports.GroupContext=Hn;exports.GroupList=Ef;exports.GroupedObservableDataProvider=jf;exports.HiddenFormInput=En;exports.HolderListItemTemplate=Dm;exports.HorizontalRule=Wd;exports.Icon=R;exports.IconButton=ae;exports.Input=Tt;exports.InputSearch=Gd;exports.ItemActionBar=Jt;exports.ItemSelectionList=vm;exports.ItemSelectionListDataProvider=Cm;exports.KOSLogo=Ah;exports.Label=ys;exports.LabelWithAction=Zd;exports.LabelWithContent=vn;exports.LabelWithContentLink=Qd;exports.LeftDialogDrawer=kd;exports.LeftInlineDrawer=Ed;exports.LifecycleAwareListProvider=la;exports.LifecycleAwareTreeProvider=ca;exports.LightTooltip=ko;exports.LightTooltipStyle=Bs;exports.Link=pn;exports.List=Vn;exports.ListContext=Ln;exports.ListContextProvider=Bn;exports.ListWithDetailsLayout=_y;exports.LockedButton=jc;exports.MenuWrapper=K0;exports.MiddleTruncateText=bo;exports.Modal=Vg;exports.ModalOverlayStyles=Ei;exports.ModalTrigger=Hg;exports.MultiSelect=Zs;exports.NO_LEADING_OR_TRAILING_SPACES_PATTERN=ks;exports.NO_SPACES_PATTERN=ou;exports.NUMBERS_ONLY_PATTERN=tu;exports.NamedCollapsibleBranch=xg;exports.NamedCollapsibleGroup=zf;exports.NamedListItemTemplate=Wf;exports.NamedSection=Mi;exports.NamedSectionHeader=qg;exports.ObservableDataProvider=Pn;exports.Option=dt;exports.PASSWORD_MIN_LENGTH=su;exports.PASSWORD_REQUIREMENTS=Tn;exports.PASSWORD_REQUIREMENTS_TOO_SIMILAR=ti;exports.PageHeader=tm;exports.PaneSplitter=mu;exports.PasswordRequirementKeys=Wt;exports.PasswordRequirementsList=mp;exports.PropertyDataProvider=If;exports.RadioButton=kn;exports.RequirementsList=ei;exports.ResizablePanel=Cn;exports.ResizablePanelGroup=Ts;exports.ResizablePanelGroupContextProvider=_s;exports.ResizablePanelHandle=Ms;exports.RightDialogDrawer=$d;exports.RightInlineDrawer=zd;exports.SOURCE_PROP_KEY=Gt;exports.SOURCE_SYMBOL=On;exports.ScreenOverlay=Os;exports.ScreenOverlayWithAction=_b;exports.Select=Et;exports.SelectAsyncTreeList=rg;exports.SelectContext=jn;exports.SelectList=Co;exports.SelectListContext=mt;exports.SelectSeparator=An;exports.SelectViewList=um;exports.SelectViewListItem=Ri;exports.SelectorTooltip=Us;exports.ShellIconButton=Zu;exports.ShellMenu=$m;exports.ShellMenuLink=jm;exports.StartOverlayStyle=gd;exports.StickyObserver=sn;exports.StudioNamedListItem=li;exports.StudioSelectViewListItem=ci;exports.StyledSelectOption=nf;exports.Tab=Xu;exports.TabPane=ih;exports.TabTrigger=Ju;exports.TabTriggerList=nh;exports.Table=Qm;exports.TableHeader=ln;exports.TableNamedListItemTemplate=Yf;exports.TableTd=Yn;exports.Tag=po;exports.TagWithRemove=uh;exports.Text=E;exports.TextHighlight=hh;exports.Textarea=Dn;exports.Toggle=vo;exports.ToggleThumb=As;exports.ToggleTrack=Fs;exports.Tooltip=Gs;exports.TopDialogDrawer=Id;exports.TopInlineDrawer=Md;exports.TreeDataProvider=Jf;exports.TreeList=tg;exports.USERNAME_PATTERN=eu;exports.View=ra;exports.ViewActionContext=Nn;exports.ViewContainer=sa;exports.ViewHeader=Xn;exports.VirtualList=ji;exports.VirtualTable=wb;exports.VirtualizedList=Ii;exports.VirtualizedSelectList=jg;exports.attachSource=fo;exports.baseComponentStyles=Ur;exports.baseGenericStyles=Zo;exports.baseSemanticStyles=Xo;exports.componentStudioTokenCss=Ql;exports.componentStyles=qo;exports.createLifecycleAwareProvider=Ny;exports.createLifecycleAwareTreeProvider=Ly;exports.createLocalComponentHelper=ql;exports.createLocalComponentTokenCss=Zl;exports.createLocalTokenSystem=Yl;exports.createObservableListProvider=aa;exports.createTableColumnHelper=ib;exports.darkTooltipArrow=Vs;exports.getByteString=im;exports.getComponentTokenHelpers=M;exports.getCurrentDragData=zy;exports.getEmailValidation=ru;exports.getErrorMessage=au;exports.getGlobalToken=F;exports.getPasswordValidation=iu;exports.getPropertyWithFallback=Zp;exports.getSemanticToken=c;exports.getSource=Kt;exports.getStyles=rc;exports.globalStudioTokenCss=Jl;exports.isContextAware=rn;exports.isErrorWithMessage=Cs;exports.isGroupFactory=hi;exports.isItemTemplateFactory=si;exports.isLockedAware=Xp;exports.keyResolver=di;exports.lightTooltipArrow=Ws;exports.noop=Se;exports.normalizePathDisplay=am;exports.rootStyles=Jo;exports.scrollbarStyle=lc;exports.semanticStudioTokenCss=Xl;exports.stringComponentInsert=Hr;exports.studioColors=Gr;exports.studioDarkColors=Yr;exports.studioGenericColor=qr;exports.studioLightColors=Kr;exports.studioTheme=cc;exports.transformLocalTokenObject=un;exports.useBaseUIComponentsContext=Jr;exports.useButtonGroupContext=ss;exports.useCollapsibleContext=qt;exports.useContainerWidth=yn;exports.useDialogContext=rt;exports.useDialogContextValue=as;exports.useDragDrop=My;exports.useDrawerContext=ut;exports.useGroupSelection=Zf;exports.useListContext=df;exports.useListGroupContext=pi;exports.useLoadDataProvider=Xt;exports.useModalContext=rt;exports.useMultiSelectContext=Ys;exports.useOpenedGroups=qf;exports.useResizablePanelGroupContext=wn;exports.useResizeObserver=$s;exports.useSelectContext=In;exports.useSelectListContext=Le;exports.useSelection=Xf;exports.useTabContext=yo;exports.useTableContext=Kn;exports.useTreeListContext=ki;exports.useViewActionContext=ai;
3454
3460
  //# sourceMappingURL=index.cjs.map