@genesislcap/design-system-configurator 14.406.0-workspaces.3 → 14.406.0-workspaces.6

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.
@@ -1,6 +1,6 @@
1
- "use strict";(self.webpackChunk_genesislcap_design_system_configurator=self.webpackChunk_genesislcap_design_system_configurator||[]).push([[6],{14609(e,t,i){i.d(t,{b:()=>s});const o=(0,i(19867).createLogger)("foundation-criteria");var n=i(86636);const a="default";class s{constructor(){this.expressions={},this.And=(e,t={})=>this.withExpression(e,t,n.r.And()),this.Or=(e,t={})=>this.withExpression(e,t,n.r.Or()),this.Not=(e,t={})=>this.withExpression(e,t,n.r.Not())}withExpression(e,t={},i=n.r.And()){const{condition:s,join:r,groupName:l}=t,d=(e,t=a)=>{var o;const n=null!==(o=this.expressions[t])&&void 0!==o?o:[];this.expressions[t]=[...n,{join:i||r,condition:s,expression:e}]};if(Array.isArray(e))if(r){const t=e.filter(e=>{const t=e instanceof n.r;return t&&o.warn("Inline joins will be discarded when join is defined in ExpressionOptions"),!t});if(l)t.forEach(e=>{d(e,l)});else{const e=(c=r,t.flat().flatMap((e,t,i)=>i.length-1!==t?[e,c]:e));d(e,a)}}else d(e,a);else d(e,"string"==typeof e?a:e.group);var c;return this}build(e){const t=Object.entries(this.expressions).reduce((e,[t,i])=>Object.assign(Object.assign({},e),{[t]:`(${i.filter(({condition:e})=>!e||e()).map(({expression:e,join:t},i,o)=>this.parseExpression(e,o[i-1],t)).join("")})`}),{});return e?e(t):`(${Object.values(t).join(" && ")})`}reset(){this.expressions={}}parseExpression(e,t,i){const o=[];return i&&t&&o.push(` ${i.operator} `),"string"==typeof e?o.push(e):Array.isArray(e)?(e.forEach((e,t,i)=>{if(e instanceof n.r){if(i[t-1]instanceof n.r)throw new Error("Adjacent Join operations detected")}}),o.push(`(${e.map(e=>this.parseExpression(e,void 0)).join("")})`)):e instanceof n.r?o.push(` ${e.operator} `):e&&o.push(e.serialiser(e)),o.join("")}}},58749(e,t,i){i.d(t,{K:()=>n});var o=i(95553);class n{constructor(e){this.serialiser=o.n.EQ,this.build=()=>{if(!this.field)throw new Error("Missing required param 'field'");if(void 0===this.value)throw new Error("Missing required param 'value'");if(!this.serialiser)throw new Error("Missing required param 'serialise'");return{field:this.field,value:this.value,serialiser:this.serialiser,params:this.params,valueGetter:this.valueGetter,group:this.group}},e&&(this.field=e.field,this.value=e.value,this.serialiser=e.serialiser,this.params=e.params,this.valueGetter=e.valueGetter,this.group=e.group)}withField(e){return this.field=e,this}withValue(e){return this.value=e,this}withSerialiser(e){return this.serialiser=e,this}withParams(e){return this.params=e,this}withValueGetter(e){return this.valueGetter=e,this}withGroup(e){return this.group=e,this}}},95553(e,t,i){i.d(t,{n:()=>s});var o=i(86636);const n=e=>{const{value:t}=e;return e.valueGetter?e.valueGetter(t):"function"==typeof t?t(e):Array.isArray(t)?t.join(","):"string"==typeof t?`"${t}"`:t},a=e=>t=>`${t.field} ${e} ${n(t)}`,s={AND:e=>a(o.X.AND)(e),OR:e=>a(o.X.OR)(e),NOT:e=>a(o.X.NOT)(e),GT:e=>a(o.X.GT)(e),GE:e=>a(o.X.GE)(e),LT:e=>a(o.X.LT)(e),LE:e=>a(o.X.LE)(e),NE:e=>a(o.X.NE)(e),EQ:e=>a(o.X.EQ)(e),equals:e=>`${e.field}.equals(${n(e)})`,equalsIgnoreCase:e=>`${e.field}.equalsIgnoreCase(${n(e)})`,contains:e=>`Expr.contains(${e.field}, ${n(e)})`,fieldContains:e=>`${e.field}.contains(${n(e)})`,containsIgnoreCase:e=>`Expr.containsIgnoreCase(${e.field}, ${n(e)})`,startsWith:e=>`${e.field}.startsWith(${n(e)})`,endsWith:e=>`${e.field}.endsWith(${n(e)})`,dateIsToday:e=>`Expr.dateIsToday(${e.field})`,dateIsEqual:e=>`Expr.dateIsEqual(${e.field}, ${n(e)})`,dateIsGreaterEqual:e=>`Expr.dateIsGreaterEqual(${e.field}, ${n(e)})`,dateIsLessEqual:e=>`Expr.dateIsLessEqual(${e.field}, ${n(e)})`,dateTimeIsGreaterEqual:e=>`Expr.dateTimeIsGreaterEqual(${e.field}, ${n(e)})`,dateTimeIsLessEqual:e=>`Expr.dateTimeIsLessEqual(${e.field}, ${n(e)})`}},86636(e,t,i){var o;i.d(t,{X:()=>o,r:()=>n}),function(e){e.AND="&&",e.OR="||",e.NOT="!",e.GT=">",e.GE=">=",e.LT="<",e.LE="<=",e.NE="!=",e.EQ="=="}(o||(o={}));class n{constructor(e){this.$$operator=e}static And(){return new n(o.AND)}static Or(){return new n(o.OR)}static Not(){return new n(o.NOT)}static GreaterThan(){return new n(o.GT)}static GreaterThanOrEqual(){return new n(o.GE)}static LessThan(){return new n(o.LT)}static LessThanOrEqual(){return new n(o.LE)}static NotEqual(){return new n(o.NE)}static Equal(){return new n(o.EQ)}get operator(){return this.$$operator}}},96999(e,t,i){i.d(t,{L:()=>a});var o=i(19867),n=i(31274);const a=(e,t,i)=>{if(!e.title)throw new Error("Title is required");if(!e.body)throw new Error("Missing required param 'body'");let a={title:e.title,body:e.body},s={};e.logLevel in o.LogLevel&&(a=Object.assign({logLevel:e.logLevel},a)),e.dialog&&(s=Object.assign({dialog:e.dialog},s),a=Object.assign({config:s},a)),(0,n.u)(a,t,i)}},31274(e,t,i){i.d(t,{u:()=>n});var o=i(60416);const n=(e,t,i)=>{(0,o.u_)(e);const n=t.split("-")[0],a=document.createElement(`${n}-dialog`),s=i?(e=>{let t=e.querySelector("#dialog-container");return t||(t=document.createElement("div"),t.setAttribute("id","dialog-container"),t.style.position="relative",e.appendChild(t)),t})(i):(0,o.jE)("dialog-container",t);s.appendChild(a),a.notification=e,a.show()}},60416(e,t,i){i.d(t,{cL:()=>h,jE:()=>u,uP:()=>d,u_:()=>c});var o=i(19867),n=i(52945),a=i(68424);const s=(0,o.createLogger)("foundation-notifications");let r=null;const l=new Map,d=e=>{var t,i;return`${null!==(t=null==e?void 0:e.title)&&void 0!==t?t:"Error"}: ${null!==(i=null==e?void 0:e.body)&&void 0!==i?i:"Something went wrong"}`},c=e=>{var t,i;s.log({message:d(e),level:(t=e,(null==t?void 0:t.logLevel)||(null===(i=null==t?void 0:t.config)||void 0===i?void 0:i.logLevel)||o.LogLevel.Debug)})},u=(e,t)=>{let i=document.querySelector(`#${e}`);if(!i)if(l.has(e))i=l.get(e);else{const t=(0,n.fI)(document).find(t=>t.id===e);t&&(i=t,l.set(e,t))}if(!i){i=document.createElement("div"),i.setAttribute("id",e),i.style.zIndex="9999";const{element:t,prefix:o}=(0,a.DW)(document.body,"rapid");if(t)t.appendChild(i),r=t;else if(r)r.appendChild(i);else{const e=document.createElement(`${o}-design-system-provider`);e.appendChild(i),document.body.appendChild(e),r=e}}return i},h=e=>{for(var t,i;e&&!(e instanceof ShadowRoot);){const o=null===(t=null==e?void 0:e.getRootNode())||void 0===t?void 0:t.getElementById("banner-anchor");if(o)return o.style.position="relative",o;e=null===(i=null==e?void 0:e.getRootNode())||void 0===i?void 0:i.host}return p()},p=()=>{const e=document.createElement("div");return e.setAttribute("id","banner-anchor"),e.style.position="relative",document.body.insertBefore(e,document.body.firstChild),e}},83006(e,t,i){i.r(t),i.d(t,{Accordion:()=>u,AccordionItem:()=>f,ActionsMenu:()=>R,AiCriteriaSearch:()=>ge,AiIndicator:()=>xe,Anchor:()=>ke,AnchoredRegion:()=>Ae,Avatar:()=>Pe,Badge:()=>je,Banner:()=>tt,BaseDatasource:()=>si,BaseFileComponent:()=>xa,Breadcrumb:()=>at,BreadcrumbItem:()=>ut,Button:()=>ft,COMBO_INPUT_MIN_LENGTH:()=>Hc,CSSVarsTokenMapper:()=>jp,Calendar:()=>$t,Card:()=>It,CategorizedMultiselect:()=>zt,Checkbox:()=>Gt,Combobox:()=>mi,ConnectionIndicator:()=>Ci,DATETIME_OPERATORS:()=>J,DATE_OPERATORS:()=>Q,DEFUALT_FILTER_BAR_COLUMNS:()=>ls,DataGrid:()=>Ei,DataGridCell:()=>Di,DataGridDatasource:()=>Vp,DataGridRow:()=>Fi,DatePicker:()=>ro,DefaultRouter:()=>Jv,DesignTokensObservable:()=>No,Dialog:()=>gn,DialogElement:()=>vn,Disclosure:()=>wn,Divider:()=>kn,DropdownMenu:()=>Fn,EnvironmentIndicator:()=>Kn,ErrorBanner:()=>ea,ErrorBoundary:()=>ma,ErrorBoundaryEvent:()=>ia,ErrorDialog:()=>wa,ExpressionBuilderConfig:()=>a,ExpressionBuilderCore:()=>cv,FaPrefixFromStyle:()=>cr,FileReader:()=>Oa,FileUpload:()=>Ua,Filter:()=>es,FilterBar:()=>ds,FilterEvents:()=>Za,FilterRegistry:()=>Eg,FlexLayout:()=>fs,FlexMediaQueriesEnum:()=>us,Flipper:()=>Cs,Flyout:()=>Is,FoundationDesignSystemProvider:()=>an,FoundationExpressionBuilder:()=>Km,FoundationRouteCollection:()=>ug,FoundationRouteNav:()=>rg,FoundationRouter:()=>vg,FoundationRouterConfiguration:()=>hg,FoundationRuleExpressionBuilder:()=>kv,FoundationValueExpressionBuilder:()=>Av,GenerateNavigationPathEventType:()=>mg,GridLayout:()=>zs,GridLayoutItem:()=>js,GridMediaQueriesEnum:()=>Ns,GridRegistry:()=>Sg,HorizontalScroll:()=>Ks,INPUT_MIN_LENGTH:()=>_c,Icon:()=>pr,LayoutRegistry:()=>$g,Listbox:()=>fr,ListboxOption:()=>$r,Menu:()=>Ir,MenuItem:()=>Fr,Modal:()=>Wr,Multiselect:()=>Jr,MultiselectDatasource:()=>Yr,NUMERIC_OPERATORS:()=>X,NavigateToEventType:()=>pg,NotificationListener:()=>Mv,NumberField:()=>hl,Optgroup:()=>bl,OptionsDatasource:()=>di,Popper:()=>nd,Position:()=>Nt,Progress:()=>Bl,ProgressRing:()=>cd,Radio:()=>gd,RadioGroup:()=>xd,Router:()=>Qv,RuleExpression:()=>uv,SCROLL_TIMEOUT:()=>Mc,SECTION_NAVIGATOR_EVENTS:()=>eu,SNACKBAR_CLOSE_TIMEOUT:()=>Yu,SNACKBAR_EVENTS_NAMES:()=>qu,SNACKBAR_TYPES:()=>Vu,SNACKBAR_TYPE_DEFAULT:()=>ju,STRING_OPERATORS:()=>K,Scheduler:()=>Id,SchedulerCronBuilder:()=>wc,SchedulerTimezone:()=>Oc,SearchBar:()=>zc,SearchBarCombobox:()=>Vc,SectionNavigator:()=>ou,SegmentedControl:()=>du,SegmentedItem:()=>vu,Select:()=>Cu,Skeleton:()=>Ou,Slider:()=>Fu,SliderLabel:()=>Uu,Snackbar:()=>Zu,StackingIcons:()=>oh,StatusPill:()=>lh,Stepper:()=>yg,StepperTab:()=>ph,StepperTabPanel:()=>bh,Switch:()=>Sh,SystemHealthOverlay:()=>Xl,Tab:()=>Dh,TabPanel:()=>Mh,Tabs:()=>Bh,TextArea:()=>qh,TextField:()=>ip,Toast:()=>up,Toolbar:()=>vp,Tooltip:()=>Cp,TreeItem:()=>Op,TreeView:()=>Np,UrlInput:()=>Bp,WorkspaceManager:()=>Rg,WorkspaceState:()=>kg,accentFillActive:()=>r.accentFillActive,accentFillActiveDelta:()=>r.accentFillActiveDelta,accentFillFocus:()=>r.accentFillFocus,accentFillFocusDelta:()=>r.accentFillFocusDelta,accentFillHover:()=>r.accentFillHover,accentFillHoverDelta:()=>r.accentFillHoverDelta,accentFillRest:()=>r.accentFillRest,accentFillRestDelta:()=>r.accentFillRestDelta,accentForegroundActive:()=>r.accentForegroundActive,accentForegroundActiveDelta:()=>r.accentForegroundActiveDelta,accentForegroundFocus:()=>r.accentForegroundFocus,accentForegroundFocusDelta:()=>r.accentForegroundFocusDelta,accentForegroundHover:()=>r.accentForegroundHover,accentForegroundHoverDelta:()=>r.accentForegroundHoverDelta,accentForegroundRest:()=>r.accentForegroundRest,accentForegroundRestDelta:()=>r.accentForegroundRestDelta,accentPalette:()=>r.accentPalette,accentPaletteValue:()=>Yo,actionsMenuBaseStyles:()=>$,applyCustomTokens:()=>Po,baseComponents:()=>Gp,baseHeightMultiplier:()=>r.baseHeightMultiplier,baseLayerLuminance:()=>r.baseLayerLuminance,baseLayerLuminanceValue:()=>Ko,black:()=>ho,bodyFont:()=>r.bodyFont,categorizedMultiselectStyles:()=>Ft,categorizedMultiselectTemplate:()=>_t,clientOperators:()=>pv,closeIcon:()=>Va,configureDesignSystem:()=>Vo,configureEnvironmentIndicator:()=>Yn,controlCornerRadius:()=>r.controlCornerRadius,controlCornerRadiusValue:()=>Qo,createDesignSystemProxy:()=>Vl,createFormData:()=>La,crossIcon:()=>Ac,defaultAccordionConfig:()=>p,defaultAccordionItemConfig:()=>y,defaultAiCriteriaSearchConfig:()=>be,defaultAnchorConfig:()=>Te,defaultAnchoredRegionConfig:()=>Le,defaultAvatarConfig:()=>Ue,defaultBadgeConfig:()=>Ye,defaultBreadcrumbConfig:()=>rt,defaultBreadcrumbItemConfig:()=>pt,defaultButtonConfig:()=>yt,defaultCalendarConfig:()=>Et,defaultCardConfig:()=>Rt,defaultCategorizedMultiselectConfig:()=>Pt,defaultCheckboxConfig:()=>Vt,defaultComboboxConfig:()=>gi,defaultConfig:()=>Rd,defaultCronBuilderConfig:()=>xc,defaultDataGridCellConfig:()=>Ai,defaultDataGridConfig:()=>Oi,defaultDataGridRowConfig:()=>_i,defaultDatePickerConfig:()=>so,defaultDialogConfig:()=>mn,defaultDisclosureConfig:()=>xn,defaultDividerConfig:()=>Tn,defaultFileUploadConfig:()=>Wa,defaultFillColor:()=>mo,defaultFlexLayoutConfig:()=>gs,defaultFlipperConfig:()=>$s,defaultFlyoutConfig:()=>Rs,defaultGridLayoutConfig:()=>Hs,defaultGridLayoutItemConfig:()=>Gs,defaultHorizontalScrollConfig:()=>Qs,defaultIconConfig:()=>dr,defaultListboxConfig:()=>yr,defaultListboxOptionConfig:()=>Er,defaultMenuConfig:()=>Rr,defaultMenuItemConfig:()=>_r,defaultModalConfig:()=>Br,defaultMultiselectConfig:()=>Qr,defaultNavItemPredicate:()=>lg,defaultNeutralForegroundContrast:()=>Oo,defaultNumberFieldConfig:()=>ml,defaultPlacementIndexPadding:()=>dg,defaultProgressConfig:()=>Gl,defaultProgressRingConfig:()=>hd,defaultRadioConfig:()=>bd,defaultRadioGroupConfig:()=>Sd,defaultSearchBarComboboxConfig:()=>qc,defaultSearchBarConfig:()=>Bc,defaultSectionNavigatorConfig:()=>au,defaultSegmentedControlConfig:()=>uu,defaultSegmentedItemConfig:()=>fu,defaultSelectConfig:()=>$u,defaultSkeletonConfig:()=>Iu,defaultSliderConfig:()=>_u,defaultSliderLabelConfig:()=>Wu,defaultStepperConfig:()=>Cg,defaultStepperTabConfig:()=>vh,defaultStepperTabPanelConfig:()=>wh,defaultSwitchConfig:()=>kh,defaultSystemHealthOverlayConfig:()=>ed,defaultTabConfig:()=>Ah,defaultTabPanelConfig:()=>Hh,defaultTabsConfig:()=>Gh,defaultTextAreaConfig:()=>Xh,defaultTextFieldConfig:()=>np,defaultTimezoneConfig:()=>Ic,defaultToastConfig:()=>cp,defaultToolbarConfig:()=>fp,defaultTooltipConfig:()=>$p,defaultTreeItemConfig:()=>Ip,defaultTreeViewConfig:()=>Fp,defaultUrlInputConfig:()=>Up,defineFactory:()=>Hv,density:()=>r.density,designToken:()=>Mo,designTokensMap:()=>Go,designUnit:()=>r.designUnit,designUnitValue:()=>Jo,direction:()=>r.direction,directionValue:()=>Xo,disabledOpacity:()=>r.disabledOpacity,downloadFile:()=>Ma,dropdownMenuBaseStyles:()=>Dn,environmentIndicatorStyles:()=>Hn,errorDialogTemplate:()=>ba,extractMenuItems:()=>An,faSizeValueDefault:()=>ur,faSizeValues:()=>hr,fileReaderStyles:()=>$a,fileReaderTemplate:()=>ka,fillColor:()=>r.fillColor,filterBarTemplate:()=>ss,findParentRouter:()=>ig,findRouter:()=>tg,findTopLevelRouter:()=>og,flyoutAnimationTime:()=>Es,focusStrokeInner:()=>r.focusStrokeInner,focusStrokeOuter:()=>r.focusStrokeOuter,focusStrokeWidth:()=>r.focusStrokeWidth,foregroundOnAccentActive:()=>r.foregroundOnAccentActive,foregroundOnAccentActiveLarge:()=>r.foregroundOnAccentActiveLarge,foregroundOnAccentFocus:()=>r.foregroundOnAccentFocus,foregroundOnAccentFocusLarge:()=>r.foregroundOnAccentFocusLarge,foregroundOnAccentHover:()=>r.foregroundOnAccentHover,foregroundOnAccentHoverLarge:()=>r.foregroundOnAccentHoverLarge,foregroundOnAccentRest:()=>r.foregroundOnAccentRest,foregroundOnAccentRestLarge:()=>r.foregroundOnAccentRestLarge,formatTimeForCountDown:()=>rh,foundationAccordion:()=>m,foundationAccordionItem:()=>w,foundationAccordionItemShadowOptions:()=>b,foundationAccordionItemStyles:()=>v,foundationAccordionItemTemplate:()=>g,foundationAccordionShadowOptions:()=>h,foundationAccordionStyles:()=>d,foundationAccordionTemplate:()=>c,foundationActionsMenu:()=>A,foundationActionsMenuStyles:()=>S,foundationActionsMenuTemplate:()=>D,foundationAiCriteriaSearch:()=>ye,foundationAiCriteriaSearchShadowOptions:()=>fe,foundationAiCriteriaSearchStyles:()=>M,foundationAiCriteriaSearchTemplate:()=>z,foundationAiIndicator:()=>$e,foundationAiIndicatorStyles:()=>we,foundationAiIndicatorTemplate:()=>Ce,foundationAnchor:()=>Ie,foundationAnchorShadowOptions:()=>Oe,foundationAnchorStyles:()=>Se,foundationAnchorTemplate:()=>Ee,foundationAnchoredRegion:()=>Fe,foundationAnchoredRegionShadowOptions:()=>Ne,foundationAnchoredRegionStyles:()=>Re,foundationAnchoredRegionTemplate:()=>De,foundationAvatar:()=>Be,foundationAvatarShadowOptions:()=>ze,foundationAvatarStyles:()=>Me,foundationAvatarTemplate:()=>_e,foundationBadge:()=>qe,foundationBadgeShadowOptions:()=>Ve,foundationBadgeStyles:()=>We,foundationBadgeTemplate:()=>Ge,foundationBanner:()=>it,foundationBannerShadowOptions:()=>et,foundationBannerStyles:()=>Qe,foundationBannerTemplate:()=>Ze,foundationBreadcrumb:()=>lt,foundationBreadcrumbItem:()=>mt,foundationBreadcrumbItemShadowOptions:()=>ht,foundationBreadcrumbItemStyles:()=>dt,foundationBreadcrumbItemTemplate:()=>ct,foundationBreadcrumbShadowOptions:()=>st,foundationBreadcrumbStyles:()=>ot,foundationBreadcrumbTemplate:()=>nt,foundationButton:()=>wt,foundationButtonShadowOptions:()=>bt,foundationButtonStyles:()=>vt,foundationButtonTemplate:()=>gt,foundationCalendar:()=>kt,foundationCalendarShadowOptions:()=>St,foundationCalendarStyles:()=>Ct,foundationCalendarTemplate:()=>xt,foundationCard:()=>At,foundationCardShadowOptions:()=>Dt,foundationCardStyles:()=>Ot,foundationCardTemplate:()=>Tt,foundationCategorizedMultiselect:()=>Ut,foundationCategorizedMultiselectShadowOptions:()=>Ht,foundationCheckbox:()=>Yt,foundationCheckboxShadowOptions:()=>jt,foundationCheckboxStyles:()=>Bt,foundationCheckboxTemplate:()=>Wt,foundationCombobox:()=>fi,foundationComboboxShadowOptions:()=>vi,foundationComboboxStyles:()=>ci,foundationComboboxTemplate:()=>ui,foundationConnectionIndicator:()=>xi,foundationConnectionIndicatorStyles:()=>yi,foundationConnectionIndicatorTemplate:()=>wi,foundationDataGrid:()=>Ti,foundationDataGridCell:()=>Ni,foundationDataGridCellShadowOptions:()=>Ri,foundationDataGridCellStyles:()=>Ii,foundationDataGridCellTemplate:()=>s.dataGridCellTemplate,foundationDataGridRow:()=>Hi,foundationDataGridRowShadowOptions:()=>Mi,foundationDataGridRowStyles:()=>Li,foundationDataGridRowTemplate:()=>s.dataGridRowTemplate,foundationDataGridShadowOptions:()=>ki,foundationDataGridStyles:()=>$i,foundationDataGridTemplate:()=>Si,foundationDatePicker:()=>lo,foundationDatePickerShadowOptions:()=>ao,foundationDatePickerStyles:()=>Ji,foundationDatePickerTemplate:()=>to,foundationDesignSystemProvider:()=>sn,foundationDialog:()=>fn,foundationDialogShadowOptions:()=>pn,foundationDialogStyles:()=>ln,foundationDialogTemplate:()=>hn,foundationDisclosure:()=>$n,foundationDisclosureShadowOptions:()=>Cn,foundationDisclosureStyles:()=>bn,foundationDisclosureTemplate:()=>yn,foundationDivider:()=>In,foundationDividerShadowOptions:()=>On,foundationDividerStyles:()=>Sn,foundationDividerTemplate:()=>En,foundationDropdownMenu:()=>Mn,foundationDropdownMenuStyles:()=>Rn,foundationDropdownMenuTemplate:()=>Ln,foundationEnvironmentIndicator:()=>Xn,foundationEnvironmentIndicatorTemplate:()=>Pn,foundationErrorBanner:()=>ta,foundationErrorBannerShadowOptions:()=>Zn,foundationErrorBannerTemplate:()=>Jn,foundationErrorBoundary:()=>va,foundationErrorBoundaryShadowOptions:()=>pa,foundationErrorBoundaryTemplate:()=>ha,foundationErrorDialog:()=>Ca,foundationErrorDialogShadowOptions:()=>ya,foundationErrorDialogStyles:()=>ga,foundationFileReader:()=>Ta,foundationFileReaderStyles:()=>Sa,foundationFileUpload:()=>Ga,foundationFileUploadShadowOptions:()=>Ba,foundationFileUploadStyles:()=>Ra,foundationFileUploadTemplate:()=>Na,foundationFilter:()=>ts,foundationFilterBar:()=>cs,foundationFilterBarStyles:()=>os,foundationFilterBarTemplate:()=>rs,foundationFilterStyles:()=>ja,foundationFilterTemplate:()=>Ja,foundationFlexLayout:()=>bs,foundationFlexLayoutShadowOptions:()=>vs,foundationFlexLayoutStyles:()=>ps,foundationFlexLayoutTemplate:()=>ms,foundationFlipper:()=>Ss,foundationFlipperShadowOptions:()=>xs,foundationFlipperStyles:()=>ys,foundationFlipperTemplate:()=>ws,foundationFlyout:()=>As,foundationFlyoutShadowOptions:()=>Ds,foundationFlyoutStyles:()=>ks,foundationFlyoutTemplate:()=>Ts,foundationGridLayout:()=>Us,foundationGridLayoutItem:()=>Vs,foundationGridLayoutItemShadowOptions:()=>Ws,foundationGridLayoutItemTemplate:()=>Bs,foundationGridLayoutShadowOptions:()=>_s,foundationGridLayoutStyles:()=>Fs,foundationGridLayoutTemplate:()=>Ms,foundationHorizontalScroll:()=>Js,foundationHorizontalScrollShadowOptions:()=>Xs,foundationHorizontalScrollStyles:()=>Ys,foundationHorizontalScrollTemplate:()=>qs,foundationIcon:()=>mr,foundationIconShadowOptions:()=>lr,foundationIconStyles:()=>ar,foundationIconTemplate:()=>rr,foundationListbox:()=>wr,foundationListboxOption:()=>kr,foundationListboxOptionShadowOptions:()=>Sr,foundationListboxOptionStyles:()=>Cr,foundationListboxOptionTemplate:()=>xr,foundationListboxShadowOptions:()=>br,foundationListboxStyles:()=>vr,foundationListboxTemplate:()=>gr,foundationMenu:()=>Ar,foundationMenuItem:()=>Hr,foundationMenuItemShadowOptions:()=>Mr,foundationMenuItemStyles:()=>Nr,foundationMenuItemTemplate:()=>Lr,foundationMenuShadowOptions:()=>Dr,foundationMenuStyles:()=>Or,foundationMenuTemplate:()=>Tr,foundationModal:()=>Gr,foundationModalShadowOptions:()=>Ur,foundationModalStyles:()=>Pr,foundationModalTemplate:()=>zr,foundationMultiselect:()=>Zr,foundationMultiselectShadowOptions:()=>Xr,foundationNotificationListener:()=>_v,foundationNotificationListenerShadowOptions:()=>Fv,foundationNotificationListenerTemplate:()=>Nv,foundationNumberField:()=>vl,foundationNumberFieldShadowOptions:()=>pl,foundationNumberFieldStyles:()=>tl,foundationNumberFieldTemplate:()=>il,foundationOptgroup:()=>yl,foundationOptgroupStyles:()=>gl,foundationOptgroupTemplate:()=>fl,foundationPopper:()=>rd,foundationProgress:()=>jl,foundationProgressRing:()=>pd,foundationProgressRingShadowOptions:()=>ud,foundationProgressRingStyles:()=>ld,foundationProgressRingTemplate:()=>dd,foundationProgressShadowOptions:()=>Wl,foundationProgressStyles:()=>zl,foundationProgressTemplate:()=>Ul,foundationRadio:()=>yd,foundationRadioGroup:()=>Ed,foundationRadioGroupShadowOptions:()=>$d,foundationRadioGroupStyles:()=>wd,foundationRadioGroupTemplate:()=>Cd,foundationRadioShadowOptions:()=>fd,foundationRadioStyles:()=>md,foundationRadioTemplate:()=>vd,foundationScheduler:()=>Ad,foundationSchedulerCronBuilder:()=>$c,foundationSchedulerCronBuilderShadowOptions:()=>Cc,foundationSchedulerCronBuilderTemplate:()=>yc,foundationSchedulerShadowOptions:()=>Dd,foundationSchedulerTemplate:()=>Td,foundationSchedulerTimezone:()=>Dc,foundationSchedulerTimezoneShadowOptions:()=>Tc,foundationSchedulerTimezoneTemplate:()=>kc,foundationSearchBar:()=>Wc,foundationSearchBarCombobox:()=>Kc,foundationSearchBarComboboxShadowOptions:()=>Yc,foundationSearchBarComboboxStyles:()=>Gc,foundationSearchBarComboboxTemplate:()=>jc,foundationSearchBarShadowOptions:()=>Uc,foundationSearchBarStyles:()=>Rc,foundationSearchBarTemplate:()=>Fc,foundationSectionNavigator:()=>su,foundationSectionNavigatorShadowOptions:()=>nu,foundationSectionNavigatorStyles:()=>Xc,foundationSectionNavigatorTemplate:()=>Qc,foundationSegmentedControl:()=>hu,foundationSegmentedControlShadowOptions:()=>cu,foundationSegmentedControlStyles:()=>ru,foundationSegmentedControlTemplate:()=>lu,foundationSegmentedItem:()=>bu,foundationSegmentedItemShadowOptions:()=>gu,foundationSegmentedItemStyles:()=>pu,foundationSegmentedItemTemplate:()=>mu,foundationSelect:()=>Su,foundationSelectShadowOptions:()=>xu,foundationSelectStyles:()=>yu,foundationSelectTemplate:()=>wu,foundationSkeleton:()=>Du,foundationSkeletonShadowOptions:()=>Tu,foundationSkeletonStyles:()=>Eu,foundationSkeletonTemplate:()=>ku,foundationSlider:()=>Hu,foundationSliderLabel:()=>Gu,foundationSliderLabelShadowOptions:()=>Bu,foundationSliderLabelStyles:()=>Pu,foundationSliderLabelTemplate:()=>zu,foundationSliderShadowOptions:()=>Mu,foundationSliderStyles:()=>Ru,foundationSliderTemplate:()=>Lu,foundationSnackbar:()=>eh,foundationSnackbarShadowOptions:()=>Ju,foundationSnackbarStyles:()=>Ku,foundationSnackbarTemplate:()=>Qu,foundationStackingIcons:()=>nh,foundationStackingIconsStyles:()=>th,foundationStackingIconsTemplate:()=>ih,foundationStatusPill:()=>dh,foundationStatusPillTemplate:()=>sh,foundationStepper:()=>xg,foundationStepperShadowOptions:()=>wg,foundationStepperStyles:()=>bg,foundationStepperTab:()=>gh,foundationStepperTabPanel:()=>Ch,foundationStepperTabPanelShadowOptions:()=>yh,foundationStepperTabPanelTemplate:()=>fh,foundationStepperTabShadowOptions:()=>mh,foundationStepperTabStyles:()=>ch,foundationStepperTabTemplate:()=>hh,foundationStepperTemplate:()=>fg,foundationSwitch:()=>Oh,foundationSwitchShadowOptions:()=>Eh,foundationSwitchStyles:()=>xh,foundationSwitchTemplate:()=>$h,foundationSystemHealthOverlay:()=>td,foundationSystemHealthOverlayShadowOptions:()=>Zl,foundationSystemHealthOverlayStyles:()=>Jl,foundationSystemHealthOverlayTemplate:()=>Ql,foundationTab:()=>Nh,foundationTabPanel:()=>Ph,foundationTabPanelShadowOptions:()=>_h,foundationTabPanelStyles:()=>Lh,foundationTabPanelTemplate:()=>Fh,foundationTabShadowOptions:()=>Rh,foundationTabStyles:()=>Th,foundationTabTemplate:()=>Ih,foundationTabs:()=>jh,foundationTabsShadowOptions:()=>Wh,foundationTabsStyles:()=>zh,foundationTabsTemplate:()=>Uh,foundationTextArea:()=>Qh,foundationTextAreaShadowOptions:()=>Kh,foundationTextAreaStyles:()=>Vh,foundationTextAreaTemplate:()=>Yh,foundationTextField:()=>ap,foundationTextFieldShadowOptions:()=>op,foundationTextFieldStyles:()=>ep,foundationTextFieldTemplate:()=>tp,foundationToast:()=>hp,foundationToastShadowOptions:()=>dp,foundationToastStyles:()=>sp,foundationToastTemplate:()=>lp,foundationToolbar:()=>bp,foundationToolbarShadowOptions:()=>gp,foundationToolbarStyles:()=>pp,foundationToolbarTemplate:()=>mp,foundationTooltip:()=>Sp,foundationTooltipShadowOptions:()=>xp,foundationTooltipStyles:()=>yp,foundationTooltipTemplate:()=>wp,foundationTreeItem:()=>Dp,foundationTreeItemShadowOptions:()=>Tp,foundationTreeItemStyles:()=>Ep,foundationTreeItemTemplate:()=>kp,foundationTreeView:()=>Mp,foundationTreeViewShadowOptions:()=>Lp,foundationTreeViewStyles:()=>Rp,foundationTreeViewTemplate:()=>Ap,foundationUrlInput:()=>Wp,foundationUrlInputShadowOptions:()=>zp,foundationUrlInputStyles:()=>_p,foundationUrlInputTemplate:()=>Pp,fromBinaryExpression:()=>$v,fromMethodExpression:()=>Sv,fuiAccentPalette:()=>$o,fuiAccentSwatch:()=>xo,fuiCardFillColor:()=>ko,fuiCardForegroundColor:()=>Io,fuiDefaultCardFillColor:()=>go,fuiDefaultCardPalette:()=>fo,fuiFillColor:()=>Eo,fuiNeutralPalette:()=>wo,fuiNeutralSwatch:()=>yo,getBannerTemplate:()=>Je,getCriteriaBuilder:()=>Pc,getDefaultConfig:()=>Uo,getDesignSystemPrefix:()=>O,getDialogTemplate:()=>un,getDropdownMenuTemplate:()=>Nn,getErrorDialogTemplate:()=>fa,getExports:()=>Bo,getFontawesomeIconsCss:()=>nr,getNavItems:()=>cg,getPrefixedCategorizedMultiselect:()=>Mt,getPrefixedCronBuilder:()=>bc,getPrefixedDatePicker:()=>eo,getPrefixedErrorBanner:()=>Qn,getPrefixedFileReader:()=>Ea,getPrefixedFileUpload:()=>Aa,getPrefixedFilterTemplate:()=>Qa,getPrefixedFlyout:()=>Os,getPrefixedIcon:()=>sr,getPrefixedMultiselect:()=>qr,getPrefixedScheduler:()=>Od,getPrefixedSchedulerTimezone:()=>Ec,getPrefixedSearchBar:()=>Lc,getPrefixedSnackbar:()=>Xu,getPrefixedStepper:()=>gg,getPrefixedStepperTab:()=>uh,getPrefixedToast:()=>rp,getPrefixedUrlInput:()=>Hp,getTypeRampValue:()=>Wo,groupsToCriteria:()=>q,inputControls:()=>Qd,isAbsoluteUrl:()=>eg,jsonConverter:()=>od,mapType:()=>ns,maxheight:()=>jr,media:()=>He,menuTemplate:()=>T,mixinFoundationFontFamily:()=>en,multiselectStyles:()=>Vr,multiselectTemplate:()=>Kr,neutralFillActive:()=>r.neutralFillActive,neutralFillActiveDelta:()=>r.neutralFillActiveDelta,neutralFillFocus:()=>r.neutralFillFocus,neutralFillFocusDelta:()=>r.neutralFillFocusDelta,neutralFillHover:()=>r.neutralFillHover,neutralFillHoverDelta:()=>r.neutralFillHoverDelta,neutralFillInputActive:()=>r.neutralFillInputActive,neutralFillInputActiveDelta:()=>r.neutralFillInputActiveDelta,neutralFillInputFocus:()=>r.neutralFillInputFocus,neutralFillInputFocusDelta:()=>r.neutralFillInputFocusDelta,neutralFillInputHover:()=>r.neutralFillInputHover,neutralFillInputHoverDelta:()=>r.neutralFillInputHoverDelta,neutralFillInputRest:()=>r.neutralFillInputRest,neutralFillInputRestDelta:()=>r.neutralFillInputRestDelta,neutralFillLayerRest:()=>r.neutralFillLayerRest,neutralFillLayerRestDelta:()=>r.neutralFillLayerRestDelta,neutralFillRest:()=>r.neutralFillRest,neutralFillRestDelta:()=>r.neutralFillRestDelta,neutralFillStealthActive:()=>r.neutralFillStealthActive,neutralFillStealthActiveDelta:()=>r.neutralFillStealthActiveDelta,neutralFillStealthFocus:()=>r.neutralFillStealthFocus,neutralFillStealthFocusDelta:()=>r.neutralFillStealthFocusDelta,neutralFillStealthHover:()=>r.neutralFillStealthHover,neutralFillStealthHoverDelta:()=>r.neutralFillStealthHoverDelta,neutralFillStealthRest:()=>r.neutralFillStealthRest,neutralFillStealthRestDelta:()=>r.neutralFillStealthRestDelta,neutralFillStrongActive:()=>r.neutralFillStrongActive,neutralFillStrongActiveDelta:()=>r.neutralFillStrongActiveDelta,neutralFillStrongFocus:()=>r.neutralFillStrongFocus,neutralFillStrongFocusDelta:()=>r.neutralFillStrongFocusDelta,neutralFillStrongHover:()=>r.neutralFillStrongHover,neutralFillStrongHoverDelta:()=>r.neutralFillStrongHoverDelta,neutralFillStrongRest:()=>r.neutralFillStrongRest,neutralFillStrongRestDelta:()=>r.neutralFillStrongRestDelta,neutralForeground:()=>To,neutralForegroundHint:()=>r.neutralForegroundHint,neutralForegroundRest:()=>r.neutralForegroundRest,neutralLayer1:()=>r.neutralLayer1,neutralLayer2:()=>r.neutralLayer2,neutralLayer3:()=>r.neutralLayer3,neutralLayer4:()=>r.neutralLayer4,neutralLayerCardContainer:()=>r.neutralLayerCardContainer,neutralLayerFloating:()=>r.neutralLayerFloating,neutralPalette:()=>r.neutralPalette,neutralPaletteValue:()=>qo,neutralStrokeActive:()=>r.neutralStrokeActive,neutralStrokeActiveDelta:()=>r.neutralStrokeActiveDelta,neutralStrokeDividerRest:()=>r.neutralStrokeDividerRest,neutralStrokeDividerRestDelta:()=>r.neutralStrokeDividerRestDelta,neutralStrokeFocus:()=>r.neutralStrokeFocus,neutralStrokeFocusDelta:()=>r.neutralStrokeFocusDelta,neutralStrokeHover:()=>r.neutralStrokeHover,neutralStrokeHoverDelta:()=>r.neutralStrokeHoverDelta,neutralStrokeRest:()=>r.neutralStrokeRest,neutralStrokeRestDelta:()=>r.neutralStrokeRestDelta,optionsMaxheight:()=>Lt,paletteFromHex:()=>Ho,pathJoin:()=>ng,plusIcon:()=>Nc,provideDesignSystem:()=>Yl,provideTokens:()=>Fo,rebuildOperator:()=>xv,registerFoundationDesignSystem:()=>Ag,removeChildRouteParameter:()=>sg,removeLastPathSegment:()=>ag,routerLogger:()=>Vv,routerProperty:()=>Xv,ruleExpressionToGroup:()=>Ev,ruleToRuleExpression:()=>wv,ruleToRuleMethodExpression:()=>yv,schedulerCronBuilderStyles:()=>Jd,schedulerStyles:()=>kd,schedulerTimezoneStyles:()=>Sc,selectCustomToken:()=>jo,singleOptionTemplate:()=>I,statusPillStyles:()=>ah,strokeWidth:()=>r.strokeWidth,swatchConverter:()=>_o,tagFor:()=>Pv,transformOperatorNameToServerName:()=>bv,transformServerNameToOperatorName:()=>Cv,typeRampBaseFontSize:()=>r.typeRampBaseFontSize,typeRampBaseLineHeight:()=>r.typeRampBaseLineHeight,typeRampMinus1FontSize:()=>r.typeRampMinus1FontSize,typeRampMinus1LineHeight:()=>r.typeRampMinus1LineHeight,typeRampMinus2FontSize:()=>r.typeRampMinus2FontSize,typeRampMinus2LineHeight:()=>r.typeRampMinus2LineHeight,typeRampPlus1FontSize:()=>r.typeRampPlus1FontSize,typeRampPlus1LineHeight:()=>r.typeRampPlus1LineHeight,typeRampPlus2FontSize:()=>r.typeRampPlus2FontSize,typeRampPlus2LineHeight:()=>r.typeRampPlus2LineHeight,typeRampPlus3FontSize:()=>r.typeRampPlus3FontSize,typeRampPlus3LineHeight:()=>r.typeRampPlus3LineHeight,typeRampPlus4FontSize:()=>r.typeRampPlus4FontSize,typeRampPlus4LineHeight:()=>r.typeRampPlus4LineHeight,typeRampPlus5FontSize:()=>r.typeRampPlus5FontSize,typeRampPlus5LineHeight:()=>r.typeRampPlus5LineHeight,typeRampPlus6FontSize:()=>r.typeRampPlus6FontSize,typeRampPlus6LineHeight:()=>r.typeRampPlus6LineHeight,uploadFiles:()=>Fa,validateClauses:()=>re,validateGroups:()=>le,white:()=>uo});var o={};i.r(o),i.d(o,{accentFillActive:()=>r.accentFillActive,accentFillActiveDelta:()=>r.accentFillActiveDelta,accentFillFocus:()=>r.accentFillFocus,accentFillFocusDelta:()=>r.accentFillFocusDelta,accentFillHover:()=>r.accentFillHover,accentFillHoverDelta:()=>r.accentFillHoverDelta,accentFillRest:()=>r.accentFillRest,accentFillRestDelta:()=>r.accentFillRestDelta,accentForegroundActive:()=>r.accentForegroundActive,accentForegroundActiveDelta:()=>r.accentForegroundActiveDelta,accentForegroundFocus:()=>r.accentForegroundFocus,accentForegroundFocusDelta:()=>r.accentForegroundFocusDelta,accentForegroundHover:()=>r.accentForegroundHover,accentForegroundHoverDelta:()=>r.accentForegroundHoverDelta,accentForegroundRest:()=>r.accentForegroundRest,accentForegroundRestDelta:()=>r.accentForegroundRestDelta,accentPalette:()=>r.accentPalette,baseHeightMultiplier:()=>r.baseHeightMultiplier,baseLayerLuminance:()=>r.baseLayerLuminance,bodyFont:()=>r.bodyFont,controlCornerRadius:()=>r.controlCornerRadius,defaultNeutralForegroundContrast:()=>Oo,density:()=>r.density,designUnit:()=>r.designUnit,direction:()=>r.direction,disabledOpacity:()=>r.disabledOpacity,fillColor:()=>r.fillColor,focusStrokeInner:()=>r.focusStrokeInner,focusStrokeOuter:()=>r.focusStrokeOuter,focusStrokeWidth:()=>r.focusStrokeWidth,foregroundOnAccentActive:()=>r.foregroundOnAccentActive,foregroundOnAccentActiveLarge:()=>r.foregroundOnAccentActiveLarge,foregroundOnAccentFocus:()=>r.foregroundOnAccentFocus,foregroundOnAccentFocusLarge:()=>r.foregroundOnAccentFocusLarge,foregroundOnAccentHover:()=>r.foregroundOnAccentHover,foregroundOnAccentHoverLarge:()=>r.foregroundOnAccentHoverLarge,foregroundOnAccentRest:()=>r.foregroundOnAccentRest,foregroundOnAccentRestLarge:()=>r.foregroundOnAccentRestLarge,fuiCardFillColor:()=>ko,fuiCardForegroundColor:()=>Io,fuiFillColor:()=>Eo,neutralFillActive:()=>r.neutralFillActive,neutralFillActiveDelta:()=>r.neutralFillActiveDelta,neutralFillFocus:()=>r.neutralFillFocus,neutralFillFocusDelta:()=>r.neutralFillFocusDelta,neutralFillHover:()=>r.neutralFillHover,neutralFillHoverDelta:()=>r.neutralFillHoverDelta,neutralFillInputActive:()=>r.neutralFillInputActive,neutralFillInputActiveDelta:()=>r.neutralFillInputActiveDelta,neutralFillInputFocus:()=>r.neutralFillInputFocus,neutralFillInputFocusDelta:()=>r.neutralFillInputFocusDelta,neutralFillInputHover:()=>r.neutralFillInputHover,neutralFillInputHoverDelta:()=>r.neutralFillInputHoverDelta,neutralFillInputRest:()=>r.neutralFillInputRest,neutralFillInputRestDelta:()=>r.neutralFillInputRestDelta,neutralFillLayerRest:()=>r.neutralFillLayerRest,neutralFillLayerRestDelta:()=>r.neutralFillLayerRestDelta,neutralFillRest:()=>r.neutralFillRest,neutralFillRestDelta:()=>r.neutralFillRestDelta,neutralFillStealthActive:()=>r.neutralFillStealthActive,neutralFillStealthActiveDelta:()=>r.neutralFillStealthActiveDelta,neutralFillStealthFocus:()=>r.neutralFillStealthFocus,neutralFillStealthFocusDelta:()=>r.neutralFillStealthFocusDelta,neutralFillStealthHover:()=>r.neutralFillStealthHover,neutralFillStealthHoverDelta:()=>r.neutralFillStealthHoverDelta,neutralFillStealthRest:()=>r.neutralFillStealthRest,neutralFillStealthRestDelta:()=>r.neutralFillStealthRestDelta,neutralFillStrongActive:()=>r.neutralFillStrongActive,neutralFillStrongActiveDelta:()=>r.neutralFillStrongActiveDelta,neutralFillStrongFocus:()=>r.neutralFillStrongFocus,neutralFillStrongFocusDelta:()=>r.neutralFillStrongFocusDelta,neutralFillStrongHover:()=>r.neutralFillStrongHover,neutralFillStrongHoverDelta:()=>r.neutralFillStrongHoverDelta,neutralFillStrongRest:()=>r.neutralFillStrongRest,neutralFillStrongRestDelta:()=>r.neutralFillStrongRestDelta,neutralForeground:()=>To,neutralForegroundHint:()=>r.neutralForegroundHint,neutralForegroundRest:()=>r.neutralForegroundRest,neutralLayer1:()=>r.neutralLayer1,neutralLayer2:()=>r.neutralLayer2,neutralLayer3:()=>r.neutralLayer3,neutralLayer4:()=>r.neutralLayer4,neutralLayerCardContainer:()=>r.neutralLayerCardContainer,neutralLayerFloating:()=>r.neutralLayerFloating,neutralPalette:()=>r.neutralPalette,neutralStrokeActive:()=>r.neutralStrokeActive,neutralStrokeActiveDelta:()=>r.neutralStrokeActiveDelta,neutralStrokeDividerRest:()=>r.neutralStrokeDividerRest,neutralStrokeDividerRestDelta:()=>r.neutralStrokeDividerRestDelta,neutralStrokeFocus:()=>r.neutralStrokeFocus,neutralStrokeFocusDelta:()=>r.neutralStrokeFocusDelta,neutralStrokeHover:()=>r.neutralStrokeHover,neutralStrokeHoverDelta:()=>r.neutralStrokeHoverDelta,neutralStrokeRest:()=>r.neutralStrokeRest,neutralStrokeRestDelta:()=>r.neutralStrokeRestDelta,strokeWidth:()=>r.strokeWidth,typeRampBaseFontSize:()=>r.typeRampBaseFontSize,typeRampBaseLineHeight:()=>r.typeRampBaseLineHeight,typeRampMinus1FontSize:()=>r.typeRampMinus1FontSize,typeRampMinus1LineHeight:()=>r.typeRampMinus1LineHeight,typeRampMinus2FontSize:()=>r.typeRampMinus2FontSize,typeRampMinus2LineHeight:()=>r.typeRampMinus2LineHeight,typeRampPlus1FontSize:()=>r.typeRampPlus1FontSize,typeRampPlus1LineHeight:()=>r.typeRampPlus1LineHeight,typeRampPlus2FontSize:()=>r.typeRampPlus2FontSize,typeRampPlus2LineHeight:()=>r.typeRampPlus2LineHeight,typeRampPlus3FontSize:()=>r.typeRampPlus3FontSize,typeRampPlus3LineHeight:()=>r.typeRampPlus3LineHeight,typeRampPlus4FontSize:()=>r.typeRampPlus4FontSize,typeRampPlus4LineHeight:()=>r.typeRampPlus4LineHeight,typeRampPlus5FontSize:()=>r.typeRampPlus5FontSize,typeRampPlus5LineHeight:()=>r.typeRampPlus5LineHeight,typeRampPlus6FontSize:()=>r.typeRampPlus6FontSize,typeRampPlus6LineHeight:()=>r.typeRampPlus6LineHeight});var n={};i.r(n),i.d(n,{accentPaletteValue:()=>Yo,baseLayerLuminanceValue:()=>Ko,controlCornerRadiusValue:()=>Qo,designUnitValue:()=>Jo,directionValue:()=>Xo,neutralPaletteValue:()=>qo});var a={};i.r(a),i.d(a,{BASE_LOGICAL_COMBINATORS:()=>Yp,BASE_OPERATORS:()=>Zp,LOGICAL_COMBINATORS:()=>qp,NULL_COMBINATOR:()=>Kp});var s=i(38370),r=i(54634),l=i(33681);const d=(e,t)=>l.css`
1
+ "use strict";(self.webpackChunk_genesislcap_design_system_configurator=self.webpackChunk_genesislcap_design_system_configurator||[]).push([[105],{83039(e,t,i){i.d(t,{P9:()=>g});var o=i(55823),n=i(92277);const s=/^(?:[A-Za-z0-9+/]{4})*?(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/,a=e=>{const t=e.split(":");let i,o;2===t.length?[i,o]=t:o=e;const n=(e=>{if(s.test(e)){const t=atob(e),i=new Uint8Array(t.length);return[...t].forEach((e,o)=>{i[o]=t.charCodeAt(o)}),i.buffer}return e})(o);if("str"===i){return new TextDecoder("utf-8").decode(n)}return n},r=e=>{const t=(e=>{if("string"==typeof e)return btoa(e);if(e instanceof ArrayBuffer){const t=new Uint8Array(e).reduce((e,t)=>e+String.fromCharCode(t),"");return btoa(t)}return""})(e);return"string"==typeof e?`str:${t}`:e instanceof ArrayBuffer?`bin:${t}`:""};var l=i(38370),d=i(26347);const c={account:"genesis",namespace:"default",authKey:"kv-default",authEmail:void 0},u=l.DI.createInterface();var h,p;!function(e){e.REQ_KEY_VALUE_LIST="REQ_KEY_VALUE_LIST",e.REQ_KEY_VALUE_READ="REQ_KEY_VALUE_READ"}(h||(h={})),function(e){e.EVENT_KEY_VALUE_PUT="EVENT_KEY_VALUE_PUT",e.EVENT_KEY_VALUE_DELETE="EVENT_KEY_VALUE_DELETE"}(p||(p={}));let m=class{constructor(e,t,i=c){this.connect=e,this.user=t,this.kvStorageConfig=i}delete(e){return(0,o.sH)(this,void 0,void 0,function*(){const t={DETAILS:{KEYS:e}},i=yield this.connect.commitEvent(p.EVENT_KEY_VALUE_DELETE,t);return!(!i||"EVENT_ACK"!==i.MESSAGE_TYPE)||{ERROR:i.ERROR,WARNING:i.WARNING}})}get(e){return(0,o.sH)(this,void 0,void 0,function*(){var t;const i={REQUEST:{USER_NAME:null!==(t=this.kvStorageConfig.authEmail)&&void 0!==t?t:this.user.userName,KEY:e}},o=yield this.connect.request(h.REQ_KEY_VALUE_READ,i);if(o&&o.REPLY&&o.REPLY.length>0){const t=o.REPLY.map(e=>{const t=this.getDecodedValue(e.VALUE);return{kv:{key:e.KEY,value:t}}});return e?t[0]:t}return e?void 0:[]})}getDecodedValue(e){e.startsWith("str:")||e.startsWith("bin:")||(e=`str:${e}`);let t=a(e);return"string"==typeof t&&t.startsWith("str:")&&(t=a(t)),"string"==typeof t&&t.startsWith("bin:")&&(t=a(t)),t}list(){return(0,o.sH)(this,void 0,void 0,function*(){var e;const t={REQUEST:{USER_NAME:null!==(e=this.kvStorageConfig.authEmail)&&void 0!==e?e:this.user.userName}},i=yield this.connect.request(h.REQ_KEY_VALUE_LIST,t);if(i&&i.REPLY&&i.REPLY.length>0){return i.REPLY.map(e=>e.KEY)}return[]})}put(e){return(0,o.sH)(this,void 0,void 0,function*(){const t={DETAILS:{RECORDS:e.map(e=>({KEY:e.key,VALUE:e.base64?r(e.value):e.value}))}},i=yield this.connect.commitEvent(p.EVENT_KEY_VALUE_PUT,t);return!(!i||"EVENT_ACK"!==i.MESSAGE_TYPE)||{ERROR:i.ERROR,WARNING:i.WARNING}})}};m=(0,o.Cg)([(0,o.Qj)(0,d.dm),(0,o.Qj)(1,n.KJ),(0,o.Qj)(2,(0,l.optional)(u))],m);const g=l.DI.createInterface(e=>e.singleton(m))},14609(e,t,i){i.d(t,{b:()=>a});const o=(0,i(19867).createLogger)("foundation-criteria");var n=i(86636);const s="default";class a{constructor(){this.expressions={},this.And=(e,t={})=>this.withExpression(e,t,n.r.And()),this.Or=(e,t={})=>this.withExpression(e,t,n.r.Or()),this.Not=(e,t={})=>this.withExpression(e,t,n.r.Not())}withExpression(e,t={},i=n.r.And()){const{condition:a,join:r,groupName:l}=t,d=(e,t=s)=>{var o;const n=null!==(o=this.expressions[t])&&void 0!==o?o:[];this.expressions[t]=[...n,{join:i||r,condition:a,expression:e}]};if(Array.isArray(e))if(r){const t=e.filter(e=>{const t=e instanceof n.r;return t&&o.warn("Inline joins will be discarded when join is defined in ExpressionOptions"),!t});if(l)t.forEach(e=>{d(e,l)});else{const e=(c=r,t.flat().flatMap((e,t,i)=>i.length-1!==t?[e,c]:e));d(e,s)}}else d(e,s);else d(e,"string"==typeof e?s:e.group);var c;return this}build(e){const t=Object.entries(this.expressions).reduce((e,[t,i])=>Object.assign(Object.assign({},e),{[t]:`(${i.filter(({condition:e})=>!e||e()).map(({expression:e,join:t},i,o)=>this.parseExpression(e,o[i-1],t)).join("")})`}),{});return e?e(t):`(${Object.values(t).join(" && ")})`}reset(){this.expressions={}}parseExpression(e,t,i){const o=[];return i&&t&&o.push(` ${i.operator} `),"string"==typeof e?o.push(e):Array.isArray(e)?(e.forEach((e,t,i)=>{if(e instanceof n.r){if(i[t-1]instanceof n.r)throw new Error("Adjacent Join operations detected")}}),o.push(`(${e.map(e=>this.parseExpression(e,void 0)).join("")})`)):e instanceof n.r?o.push(` ${e.operator} `):e&&o.push(e.serialiser(e)),o.join("")}}},58749(e,t,i){i.d(t,{K:()=>n});var o=i(95553);class n{constructor(e){this.serialiser=o.n.EQ,this.build=()=>{if(!this.field)throw new Error("Missing required param 'field'");if(void 0===this.value)throw new Error("Missing required param 'value'");if(!this.serialiser)throw new Error("Missing required param 'serialise'");return{field:this.field,value:this.value,serialiser:this.serialiser,params:this.params,valueGetter:this.valueGetter,group:this.group}},e&&(this.field=e.field,this.value=e.value,this.serialiser=e.serialiser,this.params=e.params,this.valueGetter=e.valueGetter,this.group=e.group)}withField(e){return this.field=e,this}withValue(e){return this.value=e,this}withSerialiser(e){return this.serialiser=e,this}withParams(e){return this.params=e,this}withValueGetter(e){return this.valueGetter=e,this}withGroup(e){return this.group=e,this}}},95553(e,t,i){i.d(t,{n:()=>a});var o=i(86636);const n=e=>{const{value:t}=e;return e.valueGetter?e.valueGetter(t):"function"==typeof t?t(e):Array.isArray(t)?t.join(","):"string"==typeof t?`"${t}"`:t},s=e=>t=>`${t.field} ${e} ${n(t)}`,a={AND:e=>s(o.X.AND)(e),OR:e=>s(o.X.OR)(e),NOT:e=>s(o.X.NOT)(e),GT:e=>s(o.X.GT)(e),GE:e=>s(o.X.GE)(e),LT:e=>s(o.X.LT)(e),LE:e=>s(o.X.LE)(e),NE:e=>s(o.X.NE)(e),EQ:e=>s(o.X.EQ)(e),equals:e=>`${e.field}.equals(${n(e)})`,equalsIgnoreCase:e=>`${e.field}.equalsIgnoreCase(${n(e)})`,contains:e=>`Expr.contains(${e.field}, ${n(e)})`,fieldContains:e=>`${e.field}.contains(${n(e)})`,containsIgnoreCase:e=>`Expr.containsIgnoreCase(${e.field}, ${n(e)})`,startsWith:e=>`${e.field}.startsWith(${n(e)})`,endsWith:e=>`${e.field}.endsWith(${n(e)})`,dateIsToday:e=>`Expr.dateIsToday(${e.field})`,dateIsEqual:e=>`Expr.dateIsEqual(${e.field}, ${n(e)})`,dateIsGreaterEqual:e=>`Expr.dateIsGreaterEqual(${e.field}, ${n(e)})`,dateIsLessEqual:e=>`Expr.dateIsLessEqual(${e.field}, ${n(e)})`,dateTimeIsGreaterEqual:e=>`Expr.dateTimeIsGreaterEqual(${e.field}, ${n(e)})`,dateTimeIsLessEqual:e=>`Expr.dateTimeIsLessEqual(${e.field}, ${n(e)})`}},86636(e,t,i){var o;i.d(t,{X:()=>o,r:()=>n}),function(e){e.AND="&&",e.OR="||",e.NOT="!",e.GT=">",e.GE=">=",e.LT="<",e.LE="<=",e.NE="!=",e.EQ="=="}(o||(o={}));class n{constructor(e){this.$$operator=e}static And(){return new n(o.AND)}static Or(){return new n(o.OR)}static Not(){return new n(o.NOT)}static GreaterThan(){return new n(o.GT)}static GreaterThanOrEqual(){return new n(o.GE)}static LessThan(){return new n(o.LT)}static LessThanOrEqual(){return new n(o.LE)}static NotEqual(){return new n(o.NE)}static Equal(){return new n(o.EQ)}get operator(){return this.$$operator}}},96999(e,t,i){i.d(t,{L:()=>s});var o=i(19867),n=i(31274);const s=(e,t,i)=>{if(!e.title)throw new Error("Title is required");if(!e.body)throw new Error("Missing required param 'body'");let s={title:e.title,body:e.body},a={};e.logLevel in o.LogLevel&&(s=Object.assign({logLevel:e.logLevel},s)),e.dialog&&(a=Object.assign({dialog:e.dialog},a),s=Object.assign({config:a},s)),(0,n.u)(s,t,i)}},31274(e,t,i){i.d(t,{u:()=>n});var o=i(60416);const n=(e,t,i)=>{(0,o.u_)(e);const n=t.split("-")[0],s=document.createElement(`${n}-dialog`),a=i?(e=>{let t=e.querySelector("#dialog-container");return t||(t=document.createElement("div"),t.setAttribute("id","dialog-container"),t.style.position="relative",e.appendChild(t)),t})(i):(0,o.jE)("dialog-container",t);a.appendChild(s),s.notification=e,s.show()}},60416(e,t,i){i.d(t,{cL:()=>h,jE:()=>u,uP:()=>d,u_:()=>c});var o=i(19867),n=i(52945),s=i(68424);const a=(0,o.createLogger)("foundation-notifications");let r=null;const l=new Map,d=e=>{var t,i;return`${null!==(t=null==e?void 0:e.title)&&void 0!==t?t:"Error"}: ${null!==(i=null==e?void 0:e.body)&&void 0!==i?i:"Something went wrong"}`},c=e=>{var t,i;a.log({message:d(e),level:(t=e,(null==t?void 0:t.logLevel)||(null===(i=null==t?void 0:t.config)||void 0===i?void 0:i.logLevel)||o.LogLevel.Debug)})},u=(e,t)=>{let i=document.querySelector(`#${e}`);if(!i)if(l.has(e))i=l.get(e);else{const t=(0,n.fI)(document).find(t=>t.id===e);t&&(i=t,l.set(e,t))}if(!i){i=document.createElement("div"),i.setAttribute("id",e),i.style.zIndex="9999";const{element:t,prefix:o}=(0,s.DW)(document.body,"rapid");if(t)t.appendChild(i),r=t;else if(r)r.appendChild(i);else{const e=document.createElement(`${o}-design-system-provider`);e.appendChild(i),document.body.appendChild(e),r=e}}return i},h=e=>{for(var t,i;e&&!(e instanceof ShadowRoot);){const o=null===(t=null==e?void 0:e.getRootNode())||void 0===t?void 0:t.getElementById("banner-anchor");if(o)return o.style.position="relative",o;e=null===(i=null==e?void 0:e.getRootNode())||void 0===i?void 0:i.host}return p()},p=()=>{const e=document.createElement("div");return e.setAttribute("id","banner-anchor"),e.style.position="relative",document.body.insertBefore(e,document.body.firstChild),e}},71105(e,t,i){i.r(t),i.d(t,{Accordion:()=>u,AccordionItem:()=>f,ActionsMenu:()=>A,AiCriteriaSearch:()=>ve,AiIndicator:()=>xe,Anchor:()=>ke,AnchoredRegion:()=>De,Avatar:()=>Pe,Badge:()=>Ve,Banner:()=>tt,BaseDatasource:()=>ai,BaseFileComponent:()=>xs,Breadcrumb:()=>st,BreadcrumbItem:()=>ut,Button:()=>ft,COMBO_INPUT_MIN_LENGTH:()=>Hc,CSSVarsTokenMapper:()=>Vp,Calendar:()=>$t,Card:()=>It,CategorizedMultiselect:()=>zt,Checkbox:()=>Bt,Combobox:()=>mi,ConnectionIndicator:()=>Ci,DATETIME_OPERATORS:()=>J,DATE_OPERATORS:()=>Q,DEFUALT_FILTER_BAR_COLUMNS:()=>la,DataGrid:()=>Ei,DataGridCell:()=>Ri,DataGridDatasource:()=>jp,DataGridRow:()=>Fi,DatePicker:()=>ro,DefaultFilterRegistry:()=>Av,DefaultGridRegistry:()=>Iv,DefaultLayoutRegistry:()=>Ov,DefaultRouter:()=>Jg,DefaultWorkspaceState:()=>Ev,DesignTokensObservable:()=>No,Dialog:()=>vn,DialogElement:()=>gn,Disclosure:()=>wn,Divider:()=>kn,DropdownMenu:()=>Fn,EnvironmentIndicator:()=>Kn,ErrorBanner:()=>es,ErrorBoundary:()=>ms,ErrorBoundaryEvent:()=>is,ErrorDialog:()=>ws,ExpressionBuilderConfig:()=>s,ExpressionBuilderCore:()=>cg,FaPrefixFromStyle:()=>cr,FileReader:()=>Os,FileUpload:()=>Us,Filter:()=>ea,FilterBar:()=>da,FilterEvents:()=>Zs,FilterRegistry:()=>Dv,FlexLayout:()=>fa,FlexMediaQueriesEnum:()=>ua,Flipper:()=>Ca,Flyout:()=>Ia,FoundationDesignSystemProvider:()=>sn,FoundationExpressionBuilder:()=>Km,FoundationRouteCollection:()=>uv,FoundationRouteNav:()=>rv,FoundationRouter:()=>gv,FoundationRouterConfiguration:()=>hv,FoundationRuleExpressionBuilder:()=>kg,FoundationValueExpressionBuilder:()=>Dg,GenerateNavigationPathEventType:()=>mv,GridLayout:()=>za,GridLayoutItem:()=>Va,GridMediaQueriesEnum:()=>Na,GridRegister:()=>Lv,GridRegistry:()=>Rv,HorizontalScroll:()=>Ka,INPUT_MIN_LENGTH:()=>_c,Icon:()=>pr,LayoutRegistry:()=>Tv,LayoutWrapper:()=>Mv,Listbox:()=>fr,ListboxOption:()=>$r,Menu:()=>Ir,MenuItem:()=>Fr,Modal:()=>Gr,Multiselect:()=>Jr,MultiselectDatasource:()=>Yr,NUMERIC_OPERATORS:()=>X,NavigateToEventType:()=>pv,NotificationListener:()=>Mg,NumberField:()=>hl,Optgroup:()=>bl,OptionsDatasource:()=>di,Popper:()=>nd,Position:()=>Nt,Progress:()=>Wl,ProgressRing:()=>cd,Radio:()=>vd,RadioGroup:()=>xd,Router:()=>Qg,RuleExpression:()=>ug,SCROLL_TIMEOUT:()=>Mc,SECTION_NAVIGATOR_EVENTS:()=>eu,SNACKBAR_CLOSE_TIMEOUT:()=>Yu,SNACKBAR_EVENTS_NAMES:()=>qu,SNACKBAR_TYPES:()=>ju,SNACKBAR_TYPE_DEFAULT:()=>Vu,STRING_OPERATORS:()=>K,Scheduler:()=>Id,SchedulerCronBuilder:()=>wc,SchedulerTimezone:()=>Oc,SearchBar:()=>zc,SearchBarCombobox:()=>jc,SectionNavigator:()=>ou,SegmentedControl:()=>du,SegmentedItem:()=>gu,Select:()=>Cu,Skeleton:()=>Ou,Slider:()=>Fu,SliderLabel:()=>Uu,Snackbar:()=>Zu,StackingIcons:()=>oh,StatusPill:()=>lh,Stepper:()=>yv,StepperTab:()=>ph,StepperTabPanel:()=>bh,Switch:()=>Sh,SystemHealthOverlay:()=>Xl,Tab:()=>Rh,TabPanel:()=>Mh,Tabs:()=>Wh,TextArea:()=>qh,TextField:()=>ip,Toast:()=>up,Toolbar:()=>gp,Tooltip:()=>Cp,TreeItem:()=>Op,TreeView:()=>Np,UrlInput:()=>Wp,WorkspaceManager:()=>zv,WorkspaceState:()=>kv,accentFillActive:()=>r.accentFillActive,accentFillActiveDelta:()=>r.accentFillActiveDelta,accentFillFocus:()=>r.accentFillFocus,accentFillFocusDelta:()=>r.accentFillFocusDelta,accentFillHover:()=>r.accentFillHover,accentFillHoverDelta:()=>r.accentFillHoverDelta,accentFillRest:()=>r.accentFillRest,accentFillRestDelta:()=>r.accentFillRestDelta,accentForegroundActive:()=>r.accentForegroundActive,accentForegroundActiveDelta:()=>r.accentForegroundActiveDelta,accentForegroundFocus:()=>r.accentForegroundFocus,accentForegroundFocusDelta:()=>r.accentForegroundFocusDelta,accentForegroundHover:()=>r.accentForegroundHover,accentForegroundHoverDelta:()=>r.accentForegroundHoverDelta,accentForegroundRest:()=>r.accentForegroundRest,accentForegroundRestDelta:()=>r.accentForegroundRestDelta,accentPalette:()=>r.accentPalette,accentPaletteValue:()=>Yo,actionsMenuBaseStyles:()=>$,applyCustomTokens:()=>Po,baseComponents:()=>Bp,baseHeightMultiplier:()=>r.baseHeightMultiplier,baseLayerLuminance:()=>r.baseLayerLuminance,baseLayerLuminanceValue:()=>Ko,black:()=>ho,bodyFont:()=>r.bodyFont,categorizedMultiselectStyles:()=>Ft,categorizedMultiselectTemplate:()=>_t,clientOperators:()=>pg,closeIcon:()=>js,configureDesignSystem:()=>jo,configureEnvironmentIndicator:()=>Yn,controlCornerRadius:()=>r.controlCornerRadius,controlCornerRadiusValue:()=>Qo,createDesignSystemProxy:()=>jl,createFormData:()=>Ls,crossIcon:()=>Dc,defaultAccordionConfig:()=>p,defaultAccordionItemConfig:()=>y,defaultAiCriteriaSearchConfig:()=>be,defaultAnchorConfig:()=>Te,defaultAnchoredRegionConfig:()=>Le,defaultAvatarConfig:()=>Ue,defaultBadgeConfig:()=>Ye,defaultBreadcrumbConfig:()=>rt,defaultBreadcrumbItemConfig:()=>pt,defaultButtonConfig:()=>yt,defaultCalendarConfig:()=>Et,defaultCardConfig:()=>At,defaultCategorizedMultiselectConfig:()=>Pt,defaultCheckboxConfig:()=>jt,defaultComboboxConfig:()=>vi,defaultConfig:()=>Ad,defaultCronBuilderConfig:()=>xc,defaultDataGridCellConfig:()=>Di,defaultDataGridConfig:()=>Oi,defaultDataGridRowConfig:()=>_i,defaultDatePickerConfig:()=>ao,defaultDialogConfig:()=>mn,defaultDisclosureConfig:()=>xn,defaultDividerConfig:()=>Tn,defaultFileUploadConfig:()=>Gs,defaultFillColor:()=>mo,defaultFlexLayoutConfig:()=>va,defaultFlipperConfig:()=>$a,defaultFlyoutConfig:()=>Aa,defaultGridLayoutConfig:()=>Ha,defaultGridLayoutItemConfig:()=>Ba,defaultHorizontalScrollConfig:()=>Qa,defaultIconConfig:()=>dr,defaultListboxConfig:()=>yr,defaultListboxOptionConfig:()=>Er,defaultMenuConfig:()=>Ar,defaultMenuItemConfig:()=>_r,defaultModalConfig:()=>Wr,defaultMultiselectConfig:()=>Qr,defaultNavItemPredicate:()=>lv,defaultNeutralForegroundContrast:()=>Oo,defaultNumberFieldConfig:()=>ml,defaultPlacementIndexPadding:()=>dv,defaultProgressConfig:()=>Bl,defaultProgressRingConfig:()=>hd,defaultRadioConfig:()=>bd,defaultRadioGroupConfig:()=>Sd,defaultSearchBarComboboxConfig:()=>qc,defaultSearchBarConfig:()=>Wc,defaultSectionNavigatorConfig:()=>su,defaultSegmentedControlConfig:()=>uu,defaultSegmentedItemConfig:()=>fu,defaultSelectConfig:()=>$u,defaultSkeletonConfig:()=>Iu,defaultSliderConfig:()=>_u,defaultSliderLabelConfig:()=>Gu,defaultStepperConfig:()=>Cv,defaultStepperTabConfig:()=>gh,defaultStepperTabPanelConfig:()=>wh,defaultSwitchConfig:()=>kh,defaultSystemHealthOverlayConfig:()=>ed,defaultTabConfig:()=>Dh,defaultTabPanelConfig:()=>Hh,defaultTabsConfig:()=>Bh,defaultTextAreaConfig:()=>Xh,defaultTextFieldConfig:()=>np,defaultTimezoneConfig:()=>Ic,defaultToastConfig:()=>cp,defaultToolbarConfig:()=>fp,defaultTooltipConfig:()=>$p,defaultTreeItemConfig:()=>Ip,defaultTreeViewConfig:()=>Fp,defaultUrlInputConfig:()=>Up,defineFactory:()=>Hg,density:()=>r.density,designToken:()=>Mo,designTokensMap:()=>Bo,designUnit:()=>r.designUnit,designUnitValue:()=>Jo,direction:()=>r.direction,directionValue:()=>Xo,disabledOpacity:()=>r.disabledOpacity,downloadFile:()=>Ms,dropdownMenuBaseStyles:()=>Rn,environmentIndicatorStyles:()=>Hn,errorDialogTemplate:()=>bs,extractMenuItems:()=>Dn,faSizeValueDefault:()=>ur,faSizeValues:()=>hr,fileReaderStyles:()=>$s,fileReaderTemplate:()=>ks,fillColor:()=>r.fillColor,filterBarTemplate:()=>aa,findParentRouter:()=>iv,findRouter:()=>tv,findTopLevelRouter:()=>ov,flyoutAnimationTime:()=>Ea,focusStrokeInner:()=>r.focusStrokeInner,focusStrokeOuter:()=>r.focusStrokeOuter,focusStrokeWidth:()=>r.focusStrokeWidth,foregroundOnAccentActive:()=>r.foregroundOnAccentActive,foregroundOnAccentActiveLarge:()=>r.foregroundOnAccentActiveLarge,foregroundOnAccentFocus:()=>r.foregroundOnAccentFocus,foregroundOnAccentFocusLarge:()=>r.foregroundOnAccentFocusLarge,foregroundOnAccentHover:()=>r.foregroundOnAccentHover,foregroundOnAccentHoverLarge:()=>r.foregroundOnAccentHoverLarge,foregroundOnAccentRest:()=>r.foregroundOnAccentRest,foregroundOnAccentRestLarge:()=>r.foregroundOnAccentRestLarge,formatTimeForCountDown:()=>rh,foundationAccordion:()=>m,foundationAccordionItem:()=>w,foundationAccordionItemShadowOptions:()=>b,foundationAccordionItemStyles:()=>g,foundationAccordionItemTemplate:()=>v,foundationAccordionShadowOptions:()=>h,foundationAccordionStyles:()=>d,foundationAccordionTemplate:()=>c,foundationActionsMenu:()=>D,foundationActionsMenuStyles:()=>S,foundationActionsMenuTemplate:()=>R,foundationAiCriteriaSearch:()=>ye,foundationAiCriteriaSearchShadowOptions:()=>fe,foundationAiCriteriaSearchStyles:()=>M,foundationAiCriteriaSearchTemplate:()=>z,foundationAiIndicator:()=>$e,foundationAiIndicatorStyles:()=>we,foundationAiIndicatorTemplate:()=>Ce,foundationAnchor:()=>Ie,foundationAnchorShadowOptions:()=>Oe,foundationAnchorStyles:()=>Se,foundationAnchorTemplate:()=>Ee,foundationAnchoredRegion:()=>Fe,foundationAnchoredRegionShadowOptions:()=>Ne,foundationAnchoredRegionStyles:()=>Ae,foundationAnchoredRegionTemplate:()=>Re,foundationAvatar:()=>We,foundationAvatarShadowOptions:()=>ze,foundationAvatarStyles:()=>Me,foundationAvatarTemplate:()=>_e,foundationBadge:()=>qe,foundationBadgeShadowOptions:()=>je,foundationBadgeStyles:()=>Ge,foundationBadgeTemplate:()=>Be,foundationBanner:()=>it,foundationBannerShadowOptions:()=>et,foundationBannerStyles:()=>Qe,foundationBannerTemplate:()=>Ze,foundationBreadcrumb:()=>lt,foundationBreadcrumbItem:()=>mt,foundationBreadcrumbItemShadowOptions:()=>ht,foundationBreadcrumbItemStyles:()=>dt,foundationBreadcrumbItemTemplate:()=>ct,foundationBreadcrumbShadowOptions:()=>at,foundationBreadcrumbStyles:()=>ot,foundationBreadcrumbTemplate:()=>nt,foundationButton:()=>wt,foundationButtonShadowOptions:()=>bt,foundationButtonStyles:()=>gt,foundationButtonTemplate:()=>vt,foundationCalendar:()=>kt,foundationCalendarShadowOptions:()=>St,foundationCalendarStyles:()=>Ct,foundationCalendarTemplate:()=>xt,foundationCard:()=>Dt,foundationCardShadowOptions:()=>Rt,foundationCardStyles:()=>Ot,foundationCardTemplate:()=>Tt,foundationCategorizedMultiselect:()=>Ut,foundationCategorizedMultiselectShadowOptions:()=>Ht,foundationCheckbox:()=>Yt,foundationCheckboxShadowOptions:()=>Vt,foundationCheckboxStyles:()=>Wt,foundationCheckboxTemplate:()=>Gt,foundationCombobox:()=>fi,foundationComboboxShadowOptions:()=>gi,foundationComboboxStyles:()=>ci,foundationComboboxTemplate:()=>ui,foundationConnectionIndicator:()=>xi,foundationConnectionIndicatorStyles:()=>yi,foundationConnectionIndicatorTemplate:()=>wi,foundationDataGrid:()=>Ti,foundationDataGridCell:()=>Ni,foundationDataGridCellShadowOptions:()=>Ai,foundationDataGridCellStyles:()=>Ii,foundationDataGridCellTemplate:()=>a.dataGridCellTemplate,foundationDataGridRow:()=>Hi,foundationDataGridRowShadowOptions:()=>Mi,foundationDataGridRowStyles:()=>Li,foundationDataGridRowTemplate:()=>a.dataGridRowTemplate,foundationDataGridShadowOptions:()=>ki,foundationDataGridStyles:()=>$i,foundationDataGridTemplate:()=>Si,foundationDatePicker:()=>lo,foundationDatePickerShadowOptions:()=>so,foundationDatePickerStyles:()=>Ji,foundationDatePickerTemplate:()=>to,foundationDesignSystemProvider:()=>an,foundationDialog:()=>fn,foundationDialogShadowOptions:()=>pn,foundationDialogStyles:()=>ln,foundationDialogTemplate:()=>hn,foundationDisclosure:()=>$n,foundationDisclosureShadowOptions:()=>Cn,foundationDisclosureStyles:()=>bn,foundationDisclosureTemplate:()=>yn,foundationDivider:()=>In,foundationDividerShadowOptions:()=>On,foundationDividerStyles:()=>Sn,foundationDividerTemplate:()=>En,foundationDropdownMenu:()=>Mn,foundationDropdownMenuStyles:()=>An,foundationDropdownMenuTemplate:()=>Ln,foundationEnvironmentIndicator:()=>Xn,foundationEnvironmentIndicatorTemplate:()=>Pn,foundationErrorBanner:()=>ts,foundationErrorBannerShadowOptions:()=>Zn,foundationErrorBannerTemplate:()=>Jn,foundationErrorBoundary:()=>gs,foundationErrorBoundaryShadowOptions:()=>ps,foundationErrorBoundaryTemplate:()=>hs,foundationErrorDialog:()=>Cs,foundationErrorDialogShadowOptions:()=>ys,foundationErrorDialogStyles:()=>vs,foundationFileReader:()=>Ts,foundationFileReaderStyles:()=>Ss,foundationFileUpload:()=>Bs,foundationFileUploadShadowOptions:()=>Ws,foundationFileUploadStyles:()=>As,foundationFileUploadTemplate:()=>Ns,foundationFilter:()=>ta,foundationFilterBar:()=>ca,foundationFilterBarStyles:()=>oa,foundationFilterBarTemplate:()=>ra,foundationFilterStyles:()=>Vs,foundationFilterTemplate:()=>Js,foundationFlexLayout:()=>ba,foundationFlexLayoutShadowOptions:()=>ga,foundationFlexLayoutStyles:()=>pa,foundationFlexLayoutTemplate:()=>ma,foundationFlipper:()=>Sa,foundationFlipperShadowOptions:()=>xa,foundationFlipperStyles:()=>ya,foundationFlipperTemplate:()=>wa,foundationFlyout:()=>Da,foundationFlyoutShadowOptions:()=>Ra,foundationFlyoutStyles:()=>ka,foundationFlyoutTemplate:()=>Ta,foundationGridLayout:()=>Ua,foundationGridLayoutItem:()=>ja,foundationGridLayoutItemShadowOptions:()=>Ga,foundationGridLayoutItemTemplate:()=>Wa,foundationGridLayoutShadowOptions:()=>_a,foundationGridLayoutStyles:()=>Fa,foundationGridLayoutTemplate:()=>Ma,foundationHorizontalScroll:()=>Ja,foundationHorizontalScrollShadowOptions:()=>Xa,foundationHorizontalScrollStyles:()=>Ya,foundationHorizontalScrollTemplate:()=>qa,foundationIcon:()=>mr,foundationIconShadowOptions:()=>lr,foundationIconStyles:()=>sr,foundationIconTemplate:()=>rr,foundationListbox:()=>wr,foundationListboxOption:()=>kr,foundationListboxOptionShadowOptions:()=>Sr,foundationListboxOptionStyles:()=>Cr,foundationListboxOptionTemplate:()=>xr,foundationListboxShadowOptions:()=>br,foundationListboxStyles:()=>gr,foundationListboxTemplate:()=>vr,foundationMenu:()=>Dr,foundationMenuItem:()=>Hr,foundationMenuItemShadowOptions:()=>Mr,foundationMenuItemStyles:()=>Nr,foundationMenuItemTemplate:()=>Lr,foundationMenuShadowOptions:()=>Rr,foundationMenuStyles:()=>Or,foundationMenuTemplate:()=>Tr,foundationModal:()=>Br,foundationModalShadowOptions:()=>Ur,foundationModalStyles:()=>Pr,foundationModalTemplate:()=>zr,foundationMultiselect:()=>Zr,foundationMultiselectShadowOptions:()=>Xr,foundationNotificationListener:()=>_g,foundationNotificationListenerShadowOptions:()=>Fg,foundationNotificationListenerTemplate:()=>Ng,foundationNumberField:()=>gl,foundationNumberFieldShadowOptions:()=>pl,foundationNumberFieldStyles:()=>tl,foundationNumberFieldTemplate:()=>il,foundationOptgroup:()=>yl,foundationOptgroupStyles:()=>vl,foundationOptgroupTemplate:()=>fl,foundationPopper:()=>rd,foundationProgress:()=>Vl,foundationProgressRing:()=>pd,foundationProgressRingShadowOptions:()=>ud,foundationProgressRingStyles:()=>ld,foundationProgressRingTemplate:()=>dd,foundationProgressShadowOptions:()=>Gl,foundationProgressStyles:()=>zl,foundationProgressTemplate:()=>Ul,foundationRadio:()=>yd,foundationRadioGroup:()=>Ed,foundationRadioGroupShadowOptions:()=>$d,foundationRadioGroupStyles:()=>wd,foundationRadioGroupTemplate:()=>Cd,foundationRadioShadowOptions:()=>fd,foundationRadioStyles:()=>md,foundationRadioTemplate:()=>gd,foundationScheduler:()=>Dd,foundationSchedulerCronBuilder:()=>$c,foundationSchedulerCronBuilderShadowOptions:()=>Cc,foundationSchedulerCronBuilderTemplate:()=>yc,foundationSchedulerShadowOptions:()=>Rd,foundationSchedulerTemplate:()=>Td,foundationSchedulerTimezone:()=>Rc,foundationSchedulerTimezoneShadowOptions:()=>Tc,foundationSchedulerTimezoneTemplate:()=>kc,foundationSearchBar:()=>Gc,foundationSearchBarCombobox:()=>Kc,foundationSearchBarComboboxShadowOptions:()=>Yc,foundationSearchBarComboboxStyles:()=>Bc,foundationSearchBarComboboxTemplate:()=>Vc,foundationSearchBarShadowOptions:()=>Uc,foundationSearchBarStyles:()=>Ac,foundationSearchBarTemplate:()=>Fc,foundationSectionNavigator:()=>au,foundationSectionNavigatorShadowOptions:()=>nu,foundationSectionNavigatorStyles:()=>Xc,foundationSectionNavigatorTemplate:()=>Qc,foundationSegmentedControl:()=>hu,foundationSegmentedControlShadowOptions:()=>cu,foundationSegmentedControlStyles:()=>ru,foundationSegmentedControlTemplate:()=>lu,foundationSegmentedItem:()=>bu,foundationSegmentedItemShadowOptions:()=>vu,foundationSegmentedItemStyles:()=>pu,foundationSegmentedItemTemplate:()=>mu,foundationSelect:()=>Su,foundationSelectShadowOptions:()=>xu,foundationSelectStyles:()=>yu,foundationSelectTemplate:()=>wu,foundationSkeleton:()=>Ru,foundationSkeletonShadowOptions:()=>Tu,foundationSkeletonStyles:()=>Eu,foundationSkeletonTemplate:()=>ku,foundationSlider:()=>Hu,foundationSliderLabel:()=>Bu,foundationSliderLabelShadowOptions:()=>Wu,foundationSliderLabelStyles:()=>Pu,foundationSliderLabelTemplate:()=>zu,foundationSliderShadowOptions:()=>Mu,foundationSliderStyles:()=>Au,foundationSliderTemplate:()=>Lu,foundationSnackbar:()=>eh,foundationSnackbarShadowOptions:()=>Ju,foundationSnackbarStyles:()=>Ku,foundationSnackbarTemplate:()=>Qu,foundationStackingIcons:()=>nh,foundationStackingIconsStyles:()=>th,foundationStackingIconsTemplate:()=>ih,foundationStatusPill:()=>dh,foundationStatusPillTemplate:()=>ah,foundationStepper:()=>xv,foundationStepperShadowOptions:()=>wv,foundationStepperStyles:()=>bv,foundationStepperTab:()=>vh,foundationStepperTabPanel:()=>Ch,foundationStepperTabPanelShadowOptions:()=>yh,foundationStepperTabPanelTemplate:()=>fh,foundationStepperTabShadowOptions:()=>mh,foundationStepperTabStyles:()=>ch,foundationStepperTabTemplate:()=>hh,foundationStepperTemplate:()=>fv,foundationSwitch:()=>Oh,foundationSwitchShadowOptions:()=>Eh,foundationSwitchStyles:()=>xh,foundationSwitchTemplate:()=>$h,foundationSystemHealthOverlay:()=>td,foundationSystemHealthOverlayShadowOptions:()=>Zl,foundationSystemHealthOverlayStyles:()=>Jl,foundationSystemHealthOverlayTemplate:()=>Ql,foundationTab:()=>Nh,foundationTabPanel:()=>Ph,foundationTabPanelShadowOptions:()=>_h,foundationTabPanelStyles:()=>Lh,foundationTabPanelTemplate:()=>Fh,foundationTabShadowOptions:()=>Ah,foundationTabStyles:()=>Th,foundationTabTemplate:()=>Ih,foundationTabs:()=>Vh,foundationTabsShadowOptions:()=>Gh,foundationTabsStyles:()=>zh,foundationTabsTemplate:()=>Uh,foundationTextArea:()=>Qh,foundationTextAreaShadowOptions:()=>Kh,foundationTextAreaStyles:()=>jh,foundationTextAreaTemplate:()=>Yh,foundationTextField:()=>sp,foundationTextFieldShadowOptions:()=>op,foundationTextFieldStyles:()=>ep,foundationTextFieldTemplate:()=>tp,foundationToast:()=>hp,foundationToastShadowOptions:()=>dp,foundationToastStyles:()=>ap,foundationToastTemplate:()=>lp,foundationToolbar:()=>bp,foundationToolbarShadowOptions:()=>vp,foundationToolbarStyles:()=>pp,foundationToolbarTemplate:()=>mp,foundationTooltip:()=>Sp,foundationTooltipShadowOptions:()=>xp,foundationTooltipStyles:()=>yp,foundationTooltipTemplate:()=>wp,foundationTreeItem:()=>Rp,foundationTreeItemShadowOptions:()=>Tp,foundationTreeItemStyles:()=>Ep,foundationTreeItemTemplate:()=>kp,foundationTreeView:()=>Mp,foundationTreeViewShadowOptions:()=>Lp,foundationTreeViewStyles:()=>Ap,foundationTreeViewTemplate:()=>Dp,foundationUrlInput:()=>Gp,foundationUrlInputShadowOptions:()=>zp,foundationUrlInputStyles:()=>_p,foundationUrlInputTemplate:()=>Pp,fromBinaryExpression:()=>$g,fromMethodExpression:()=>Sg,fuiAccentPalette:()=>$o,fuiAccentSwatch:()=>xo,fuiCardFillColor:()=>ko,fuiCardForegroundColor:()=>Io,fuiDefaultCardFillColor:()=>vo,fuiDefaultCardPalette:()=>fo,fuiFillColor:()=>Eo,fuiNeutralPalette:()=>wo,fuiNeutralSwatch:()=>yo,getBannerTemplate:()=>Je,getCriteriaBuilder:()=>Pc,getDefaultConfig:()=>Uo,getDesignSystemPrefix:()=>O,getDialogTemplate:()=>un,getDropdownMenuTemplate:()=>Nn,getErrorDialogTemplate:()=>fs,getExports:()=>Wo,getFontawesomeIconsCss:()=>nr,getNavItems:()=>cv,getPrefixedCategorizedMultiselect:()=>Mt,getPrefixedCronBuilder:()=>bc,getPrefixedDatePicker:()=>eo,getPrefixedErrorBanner:()=>Qn,getPrefixedFileReader:()=>Es,getPrefixedFileUpload:()=>Ds,getPrefixedFilterTemplate:()=>Qs,getPrefixedFlyout:()=>Oa,getPrefixedIcon:()=>ar,getPrefixedMultiselect:()=>qr,getPrefixedScheduler:()=>Od,getPrefixedSchedulerTimezone:()=>Ec,getPrefixedSearchBar:()=>Lc,getPrefixedSnackbar:()=>Xu,getPrefixedStepper:()=>vv,getPrefixedStepperTab:()=>uh,getPrefixedToast:()=>rp,getPrefixedUrlInput:()=>Hp,getTypeRampValue:()=>Go,groupsToCriteria:()=>q,inputControls:()=>Qd,isAbsoluteUrl:()=>ev,jsonConverter:()=>od,mapType:()=>na,maxheight:()=>Vr,media:()=>He,menuTemplate:()=>T,mixinFoundationFontFamily:()=>en,multiselectStyles:()=>jr,multiselectTemplate:()=>Kr,neutralFillActive:()=>r.neutralFillActive,neutralFillActiveDelta:()=>r.neutralFillActiveDelta,neutralFillFocus:()=>r.neutralFillFocus,neutralFillFocusDelta:()=>r.neutralFillFocusDelta,neutralFillHover:()=>r.neutralFillHover,neutralFillHoverDelta:()=>r.neutralFillHoverDelta,neutralFillInputActive:()=>r.neutralFillInputActive,neutralFillInputActiveDelta:()=>r.neutralFillInputActiveDelta,neutralFillInputFocus:()=>r.neutralFillInputFocus,neutralFillInputFocusDelta:()=>r.neutralFillInputFocusDelta,neutralFillInputHover:()=>r.neutralFillInputHover,neutralFillInputHoverDelta:()=>r.neutralFillInputHoverDelta,neutralFillInputRest:()=>r.neutralFillInputRest,neutralFillInputRestDelta:()=>r.neutralFillInputRestDelta,neutralFillLayerRest:()=>r.neutralFillLayerRest,neutralFillLayerRestDelta:()=>r.neutralFillLayerRestDelta,neutralFillRest:()=>r.neutralFillRest,neutralFillRestDelta:()=>r.neutralFillRestDelta,neutralFillStealthActive:()=>r.neutralFillStealthActive,neutralFillStealthActiveDelta:()=>r.neutralFillStealthActiveDelta,neutralFillStealthFocus:()=>r.neutralFillStealthFocus,neutralFillStealthFocusDelta:()=>r.neutralFillStealthFocusDelta,neutralFillStealthHover:()=>r.neutralFillStealthHover,neutralFillStealthHoverDelta:()=>r.neutralFillStealthHoverDelta,neutralFillStealthRest:()=>r.neutralFillStealthRest,neutralFillStealthRestDelta:()=>r.neutralFillStealthRestDelta,neutralFillStrongActive:()=>r.neutralFillStrongActive,neutralFillStrongActiveDelta:()=>r.neutralFillStrongActiveDelta,neutralFillStrongFocus:()=>r.neutralFillStrongFocus,neutralFillStrongFocusDelta:()=>r.neutralFillStrongFocusDelta,neutralFillStrongHover:()=>r.neutralFillStrongHover,neutralFillStrongHoverDelta:()=>r.neutralFillStrongHoverDelta,neutralFillStrongRest:()=>r.neutralFillStrongRest,neutralFillStrongRestDelta:()=>r.neutralFillStrongRestDelta,neutralForeground:()=>To,neutralForegroundHint:()=>r.neutralForegroundHint,neutralForegroundRest:()=>r.neutralForegroundRest,neutralLayer1:()=>r.neutralLayer1,neutralLayer2:()=>r.neutralLayer2,neutralLayer3:()=>r.neutralLayer3,neutralLayer4:()=>r.neutralLayer4,neutralLayerCardContainer:()=>r.neutralLayerCardContainer,neutralLayerFloating:()=>r.neutralLayerFloating,neutralPalette:()=>r.neutralPalette,neutralPaletteValue:()=>qo,neutralStrokeActive:()=>r.neutralStrokeActive,neutralStrokeActiveDelta:()=>r.neutralStrokeActiveDelta,neutralStrokeDividerRest:()=>r.neutralStrokeDividerRest,neutralStrokeDividerRestDelta:()=>r.neutralStrokeDividerRestDelta,neutralStrokeFocus:()=>r.neutralStrokeFocus,neutralStrokeFocusDelta:()=>r.neutralStrokeFocusDelta,neutralStrokeHover:()=>r.neutralStrokeHover,neutralStrokeHoverDelta:()=>r.neutralStrokeHoverDelta,neutralStrokeRest:()=>r.neutralStrokeRest,neutralStrokeRestDelta:()=>r.neutralStrokeRestDelta,optionsMaxheight:()=>Lt,paletteFromHex:()=>Ho,pathJoin:()=>nv,plusIcon:()=>Nc,provideDesignSystem:()=>Yl,provideTokens:()=>Fo,rebuildOperator:()=>xg,registerFoundationDesignSystem:()=>Uv,removeChildRouteParameter:()=>av,removeLastPathSegment:()=>sv,routerLogger:()=>jg,routerProperty:()=>Xg,ruleExpressionToGroup:()=>Eg,ruleToRuleExpression:()=>wg,ruleToRuleMethodExpression:()=>yg,schedulerCronBuilderStyles:()=>Jd,schedulerStyles:()=>kd,schedulerTimezoneStyles:()=>Sc,selectCustomToken:()=>Vo,singleOptionTemplate:()=>I,statusPillStyles:()=>sh,strokeWidth:()=>r.strokeWidth,swatchConverter:()=>_o,tagFor:()=>Pg,transformOperatorNameToServerName:()=>bg,transformServerNameToOperatorName:()=>Cg,typeRampBaseFontSize:()=>r.typeRampBaseFontSize,typeRampBaseLineHeight:()=>r.typeRampBaseLineHeight,typeRampMinus1FontSize:()=>r.typeRampMinus1FontSize,typeRampMinus1LineHeight:()=>r.typeRampMinus1LineHeight,typeRampMinus2FontSize:()=>r.typeRampMinus2FontSize,typeRampMinus2LineHeight:()=>r.typeRampMinus2LineHeight,typeRampPlus1FontSize:()=>r.typeRampPlus1FontSize,typeRampPlus1LineHeight:()=>r.typeRampPlus1LineHeight,typeRampPlus2FontSize:()=>r.typeRampPlus2FontSize,typeRampPlus2LineHeight:()=>r.typeRampPlus2LineHeight,typeRampPlus3FontSize:()=>r.typeRampPlus3FontSize,typeRampPlus3LineHeight:()=>r.typeRampPlus3LineHeight,typeRampPlus4FontSize:()=>r.typeRampPlus4FontSize,typeRampPlus4LineHeight:()=>r.typeRampPlus4LineHeight,typeRampPlus5FontSize:()=>r.typeRampPlus5FontSize,typeRampPlus5LineHeight:()=>r.typeRampPlus5LineHeight,typeRampPlus6FontSize:()=>r.typeRampPlus6FontSize,typeRampPlus6LineHeight:()=>r.typeRampPlus6LineHeight,uploadFiles:()=>Fs,validateClauses:()=>re,validateGroups:()=>le,white:()=>uo});var o={};i.r(o),i.d(o,{accentFillActive:()=>r.accentFillActive,accentFillActiveDelta:()=>r.accentFillActiveDelta,accentFillFocus:()=>r.accentFillFocus,accentFillFocusDelta:()=>r.accentFillFocusDelta,accentFillHover:()=>r.accentFillHover,accentFillHoverDelta:()=>r.accentFillHoverDelta,accentFillRest:()=>r.accentFillRest,accentFillRestDelta:()=>r.accentFillRestDelta,accentForegroundActive:()=>r.accentForegroundActive,accentForegroundActiveDelta:()=>r.accentForegroundActiveDelta,accentForegroundFocus:()=>r.accentForegroundFocus,accentForegroundFocusDelta:()=>r.accentForegroundFocusDelta,accentForegroundHover:()=>r.accentForegroundHover,accentForegroundHoverDelta:()=>r.accentForegroundHoverDelta,accentForegroundRest:()=>r.accentForegroundRest,accentForegroundRestDelta:()=>r.accentForegroundRestDelta,accentPalette:()=>r.accentPalette,baseHeightMultiplier:()=>r.baseHeightMultiplier,baseLayerLuminance:()=>r.baseLayerLuminance,bodyFont:()=>r.bodyFont,controlCornerRadius:()=>r.controlCornerRadius,defaultNeutralForegroundContrast:()=>Oo,density:()=>r.density,designUnit:()=>r.designUnit,direction:()=>r.direction,disabledOpacity:()=>r.disabledOpacity,fillColor:()=>r.fillColor,focusStrokeInner:()=>r.focusStrokeInner,focusStrokeOuter:()=>r.focusStrokeOuter,focusStrokeWidth:()=>r.focusStrokeWidth,foregroundOnAccentActive:()=>r.foregroundOnAccentActive,foregroundOnAccentActiveLarge:()=>r.foregroundOnAccentActiveLarge,foregroundOnAccentFocus:()=>r.foregroundOnAccentFocus,foregroundOnAccentFocusLarge:()=>r.foregroundOnAccentFocusLarge,foregroundOnAccentHover:()=>r.foregroundOnAccentHover,foregroundOnAccentHoverLarge:()=>r.foregroundOnAccentHoverLarge,foregroundOnAccentRest:()=>r.foregroundOnAccentRest,foregroundOnAccentRestLarge:()=>r.foregroundOnAccentRestLarge,fuiCardFillColor:()=>ko,fuiCardForegroundColor:()=>Io,fuiFillColor:()=>Eo,neutralFillActive:()=>r.neutralFillActive,neutralFillActiveDelta:()=>r.neutralFillActiveDelta,neutralFillFocus:()=>r.neutralFillFocus,neutralFillFocusDelta:()=>r.neutralFillFocusDelta,neutralFillHover:()=>r.neutralFillHover,neutralFillHoverDelta:()=>r.neutralFillHoverDelta,neutralFillInputActive:()=>r.neutralFillInputActive,neutralFillInputActiveDelta:()=>r.neutralFillInputActiveDelta,neutralFillInputFocus:()=>r.neutralFillInputFocus,neutralFillInputFocusDelta:()=>r.neutralFillInputFocusDelta,neutralFillInputHover:()=>r.neutralFillInputHover,neutralFillInputHoverDelta:()=>r.neutralFillInputHoverDelta,neutralFillInputRest:()=>r.neutralFillInputRest,neutralFillInputRestDelta:()=>r.neutralFillInputRestDelta,neutralFillLayerRest:()=>r.neutralFillLayerRest,neutralFillLayerRestDelta:()=>r.neutralFillLayerRestDelta,neutralFillRest:()=>r.neutralFillRest,neutralFillRestDelta:()=>r.neutralFillRestDelta,neutralFillStealthActive:()=>r.neutralFillStealthActive,neutralFillStealthActiveDelta:()=>r.neutralFillStealthActiveDelta,neutralFillStealthFocus:()=>r.neutralFillStealthFocus,neutralFillStealthFocusDelta:()=>r.neutralFillStealthFocusDelta,neutralFillStealthHover:()=>r.neutralFillStealthHover,neutralFillStealthHoverDelta:()=>r.neutralFillStealthHoverDelta,neutralFillStealthRest:()=>r.neutralFillStealthRest,neutralFillStealthRestDelta:()=>r.neutralFillStealthRestDelta,neutralFillStrongActive:()=>r.neutralFillStrongActive,neutralFillStrongActiveDelta:()=>r.neutralFillStrongActiveDelta,neutralFillStrongFocus:()=>r.neutralFillStrongFocus,neutralFillStrongFocusDelta:()=>r.neutralFillStrongFocusDelta,neutralFillStrongHover:()=>r.neutralFillStrongHover,neutralFillStrongHoverDelta:()=>r.neutralFillStrongHoverDelta,neutralFillStrongRest:()=>r.neutralFillStrongRest,neutralFillStrongRestDelta:()=>r.neutralFillStrongRestDelta,neutralForeground:()=>To,neutralForegroundHint:()=>r.neutralForegroundHint,neutralForegroundRest:()=>r.neutralForegroundRest,neutralLayer1:()=>r.neutralLayer1,neutralLayer2:()=>r.neutralLayer2,neutralLayer3:()=>r.neutralLayer3,neutralLayer4:()=>r.neutralLayer4,neutralLayerCardContainer:()=>r.neutralLayerCardContainer,neutralLayerFloating:()=>r.neutralLayerFloating,neutralPalette:()=>r.neutralPalette,neutralStrokeActive:()=>r.neutralStrokeActive,neutralStrokeActiveDelta:()=>r.neutralStrokeActiveDelta,neutralStrokeDividerRest:()=>r.neutralStrokeDividerRest,neutralStrokeDividerRestDelta:()=>r.neutralStrokeDividerRestDelta,neutralStrokeFocus:()=>r.neutralStrokeFocus,neutralStrokeFocusDelta:()=>r.neutralStrokeFocusDelta,neutralStrokeHover:()=>r.neutralStrokeHover,neutralStrokeHoverDelta:()=>r.neutralStrokeHoverDelta,neutralStrokeRest:()=>r.neutralStrokeRest,neutralStrokeRestDelta:()=>r.neutralStrokeRestDelta,strokeWidth:()=>r.strokeWidth,typeRampBaseFontSize:()=>r.typeRampBaseFontSize,typeRampBaseLineHeight:()=>r.typeRampBaseLineHeight,typeRampMinus1FontSize:()=>r.typeRampMinus1FontSize,typeRampMinus1LineHeight:()=>r.typeRampMinus1LineHeight,typeRampMinus2FontSize:()=>r.typeRampMinus2FontSize,typeRampMinus2LineHeight:()=>r.typeRampMinus2LineHeight,typeRampPlus1FontSize:()=>r.typeRampPlus1FontSize,typeRampPlus1LineHeight:()=>r.typeRampPlus1LineHeight,typeRampPlus2FontSize:()=>r.typeRampPlus2FontSize,typeRampPlus2LineHeight:()=>r.typeRampPlus2LineHeight,typeRampPlus3FontSize:()=>r.typeRampPlus3FontSize,typeRampPlus3LineHeight:()=>r.typeRampPlus3LineHeight,typeRampPlus4FontSize:()=>r.typeRampPlus4FontSize,typeRampPlus4LineHeight:()=>r.typeRampPlus4LineHeight,typeRampPlus5FontSize:()=>r.typeRampPlus5FontSize,typeRampPlus5LineHeight:()=>r.typeRampPlus5LineHeight,typeRampPlus6FontSize:()=>r.typeRampPlus6FontSize,typeRampPlus6LineHeight:()=>r.typeRampPlus6LineHeight});var n={};i.r(n),i.d(n,{accentPaletteValue:()=>Yo,baseLayerLuminanceValue:()=>Ko,controlCornerRadiusValue:()=>Qo,designUnitValue:()=>Jo,directionValue:()=>Xo,neutralPaletteValue:()=>qo});var s={};i.r(s),i.d(s,{BASE_LOGICAL_COMBINATORS:()=>Yp,BASE_OPERATORS:()=>Zp,LOGICAL_COMBINATORS:()=>qp,NULL_COMBINATOR:()=>Kp});var a=i(38370),r=i(54634),l=i(33681);const d=(e,t)=>l.css`
2
2
  ${(0,r.accordionStyles)(e,t)}
3
- `,c=(e,t)=>(0,s.accordionTemplate)(e,t);class u extends s.Accordion{}const h={delegatesFocus:!0,mode:"open"},p={},m=u.compose(Object.assign({baseName:"accordion",template:c,styles:d,shadowOptions:h},p)),v=(e,t)=>l.css`
3
+ `,c=(e,t)=>(0,a.accordionTemplate)(e,t);class u extends a.Accordion{}const h={delegatesFocus:!0,mode:"open"},p={},m=u.compose(Object.assign({baseName:"accordion",template:c,styles:d,shadowOptions:h},p)),g=(e,t)=>l.css`
4
4
  ${(0,r.accordionItemStyles)(e,t)}
5
5
 
6
6
  slot[name='collapsed-icon'] {
@@ -14,7 +14,7 @@
14
14
  stroke: var(--accent-foreground-rest);
15
15
  fill: none;
16
16
  }
17
- `,g=(e,t)=>(0,s.accordionItemTemplate)(e,t);class f extends r.AccordionItem{}const b={delegatesFocus:!0,mode:"open"},y={collapsedIcon:'<svg width="16" height="16" viewBox="0 0 18 18" xmlns="http://www.w3.org/2000/svg" slot="collapsed-icon">\n <path d="M15.2222 1H2.77778C1.79594 1 1 1.79594 1 2.77778V15.2222C1 16.2041 1.79594 17 2.77778 17H15.2222C16.2041 17 17 16.2041 17 15.2222V2.77778C17 1.79594 16.2041 1 15.2222 1Z" stroke-linecap="round" stroke-linejoin="round"></path>\n <path class="plus-sign" d="M9 5.44446V12.5556" stroke-linecap="round" stroke-linejoin="round"></path>\n <path class="plus-sign" d="M5.44446 9H12.5556" stroke-linecap="round" stroke-linejoin="round"></path>\n </svg>',expandedIcon:'<svg width="16" height="16" viewBox="0 0 18 18" xmlns="http://www.w3.org/2000/svg" slot="expanded-icon">\n <path d="M15.2222 1H2.77778C1.79594 1 1 1.79594 1 2.77778V15.2222C1 16.2041 1.79594 17 2.77778 17H15.2222C16.2041 17 17 16.2041 17 15.2222V2.77778C17 1.79594 16.2041 1 15.2222 1Z" stroke-linecap="round" stroke-linejoin="round"></path>\n <path class="minus-sign" d="M5.44446 9H12.5556" stroke-linecap="round" stroke-linejoin="round"></path>\n </svg>'},w=f.compose(Object.assign({baseName:"accordion-item",template:g,styles:v,shadowOptions:b},y));var C=i(55823),x=i(31679);const $=(e,t)=>l.css`
17
+ `,v=(e,t)=>(0,a.accordionItemTemplate)(e,t);class f extends r.AccordionItem{}const b={delegatesFocus:!0,mode:"open"},y={collapsedIcon:'<svg width="16" height="16" viewBox="0 0 18 18" xmlns="http://www.w3.org/2000/svg" slot="collapsed-icon">\n <path d="M15.2222 1H2.77778C1.79594 1 1 1.79594 1 2.77778V15.2222C1 16.2041 1.79594 17 2.77778 17H15.2222C16.2041 17 17 16.2041 17 15.2222V2.77778C17 1.79594 16.2041 1 15.2222 1Z" stroke-linecap="round" stroke-linejoin="round"></path>\n <path class="plus-sign" d="M9 5.44446V12.5556" stroke-linecap="round" stroke-linejoin="round"></path>\n <path class="plus-sign" d="M5.44446 9H12.5556" stroke-linecap="round" stroke-linejoin="round"></path>\n </svg>',expandedIcon:'<svg width="16" height="16" viewBox="0 0 18 18" xmlns="http://www.w3.org/2000/svg" slot="expanded-icon">\n <path d="M15.2222 1H2.77778C1.79594 1 1 1.79594 1 2.77778V15.2222C1 16.2041 1.79594 17 2.77778 17H15.2222C16.2041 17 17 16.2041 17 15.2222V2.77778C17 1.79594 16.2041 1 15.2222 1Z" stroke-linecap="round" stroke-linejoin="round"></path>\n <path class="minus-sign" d="M5.44446 9H12.5556" stroke-linecap="round" stroke-linejoin="round"></path>\n </svg>'},w=f.compose(Object.assign({baseName:"accordion-item",template:v,styles:g,shadowOptions:b},y));var C=i(55823),x=i(31679);const $=(e,t)=>l.css`
18
18
  :host {
19
19
  --actions-opener-height-multiplier: 0.7px;
20
20
  --actions-opener-bg-color: 249 254 255;
@@ -153,14 +153,14 @@
153
153
  >
154
154
  ${e=>e.getLabel(null==e?void 0:e.singleOption.name)}
155
155
  </${e}-button>
156
- `,D=l.html`
156
+ `,R=l.html`
157
157
  <div
158
158
  class="actions-container${e=>e.isVertical?" actions-vertical":""}"
159
159
  part="actions-container"
160
160
  >
161
161
  ${e=>e.getTemplate(O(e))}
162
162
  </div>
163
- `;class R extends s.FoundationElement{constructor(){super(...arguments),this.isVertical=!1,this.addDefaultActions=!0,this.autoCloseOnAction=!0,this.name="Actions",this.open=!1,this.hideDisabled=!1,this.hideMenuSingleOption=!1}definitionChanged(e,t){var i;this.actions=null!==(i=null==t?void 0:t.actions)&&void 0!==i?i:[],delete this.definition.actions,t.buttonText&&(this.name=t.buttonText,delete this.definition.customButtonText),t.isVertical&&(this.isVertical=t.isVertical,delete this.definition.isVertical),t.buttonAppearance&&(this.buttonAppearance=t.buttonAppearance,delete this.definition.buttonAppearance),t.hideMenuSingleOption&&(this.hideMenuSingleOption=t.hideMenuSingleOption,delete this.definition.hideMenuSingleOption)}openChanged(){this.classNames=(0,x.x)(["visible",this.open],["hidden",!this.open])}toggleActionsMenuVisibility(){this.open=!this.open}onActionMenuItemClick(e){this.autoCloseOnAction&&(this.open=!1),e(this.rowData)}get allActions(){var e;const t=[{name:"✖",callback:()=>this.open=!1}];return this.addDefaultActions?[...null!==(e=this.actions)&&void 0!==e?e:[],...t]:this.actions}get rowData(){if(!this.definition)return;const{node:e,data:t}=this.definition;return(null==e?void 0:e.data)||t}getLabel(e){return"function"==typeof e?e(this.rowData):e}getTemplate(e){if(!this.hideMenuSingleOption)return T(e);const t=this.actions.filter(e=>!e.isDisabled||!e.isDisabled(this.rowData));return this.singleOption=null,0!==t.length?1===t.length?(this.singleOption=t[0],I(e)):T(e):void 0}}(0,C.Cg)([l.observable],R.prototype,"actions",void 0),(0,C.Cg)([(0,l.attr)({attribute:"is-vertical",mode:"boolean"})],R.prototype,"isVertical",void 0),(0,C.Cg)([(0,l.attr)({attribute:"add-default-actions",mode:"boolean"})],R.prototype,"addDefaultActions",void 0),(0,C.Cg)([(0,l.attr)({attribute:"auto-close-on-action",mode:"boolean"})],R.prototype,"autoCloseOnAction",void 0),(0,C.Cg)([l.observable],R.prototype,"classNames",void 0),(0,C.Cg)([l.observable],R.prototype,"definition",void 0),(0,C.Cg)([l.attr],R.prototype,"name",void 0),(0,C.Cg)([(0,l.attr)({attribute:"open",mode:"boolean"})],R.prototype,"open",void 0),(0,C.Cg)([l.attr],R.prototype,"buttonAppearance",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-disabled",mode:"boolean"})],R.prototype,"hideDisabled",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-menu-single-option",mode:"boolean"})],R.prototype,"hideMenuSingleOption",void 0),(0,C.Cg)([l.observable],R.prototype,"singleOption",void 0);const A=R.compose({baseName:"actions-menu",styles:S,template:D});function N(){return"undefined"!=typeof window&&("SpeechRecognition"in window||"webkitSpeechRecognition"in window)}class L{getStatus(){return(0,C.sH)(this,void 0,void 0,function*(){return{provider:"none",model:""}})}interpretCriteria(e,t){return(0,C.sH)(this,void 0,void 0,function*(){return null})}}const F=s.DI.createInterface(e=>e.singleton(L));const M=l.css`
163
+ `;class A extends a.FoundationElement{constructor(){super(...arguments),this.isVertical=!1,this.addDefaultActions=!0,this.autoCloseOnAction=!0,this.name="Actions",this.open=!1,this.hideDisabled=!1,this.hideMenuSingleOption=!1}definitionChanged(e,t){var i;this.actions=null!==(i=null==t?void 0:t.actions)&&void 0!==i?i:[],delete this.definition.actions,t.buttonText&&(this.name=t.buttonText,delete this.definition.customButtonText),t.isVertical&&(this.isVertical=t.isVertical,delete this.definition.isVertical),t.buttonAppearance&&(this.buttonAppearance=t.buttonAppearance,delete this.definition.buttonAppearance),t.hideMenuSingleOption&&(this.hideMenuSingleOption=t.hideMenuSingleOption,delete this.definition.hideMenuSingleOption)}openChanged(){this.classNames=(0,x.x)(["visible",this.open],["hidden",!this.open])}toggleActionsMenuVisibility(){this.open=!this.open}onActionMenuItemClick(e){this.autoCloseOnAction&&(this.open=!1),e(this.rowData)}get allActions(){var e;const t=[{name:"✖",callback:()=>this.open=!1}];return this.addDefaultActions?[...null!==(e=this.actions)&&void 0!==e?e:[],...t]:this.actions}get rowData(){if(!this.definition)return;const{node:e,data:t}=this.definition;return(null==e?void 0:e.data)||t}getLabel(e){return"function"==typeof e?e(this.rowData):e}getTemplate(e){if(!this.hideMenuSingleOption)return T(e);const t=this.actions.filter(e=>!e.isDisabled||!e.isDisabled(this.rowData));return this.singleOption=null,0!==t.length?1===t.length?(this.singleOption=t[0],I(e)):T(e):void 0}}(0,C.Cg)([l.observable],A.prototype,"actions",void 0),(0,C.Cg)([(0,l.attr)({attribute:"is-vertical",mode:"boolean"})],A.prototype,"isVertical",void 0),(0,C.Cg)([(0,l.attr)({attribute:"add-default-actions",mode:"boolean"})],A.prototype,"addDefaultActions",void 0),(0,C.Cg)([(0,l.attr)({attribute:"auto-close-on-action",mode:"boolean"})],A.prototype,"autoCloseOnAction",void 0),(0,C.Cg)([l.observable],A.prototype,"classNames",void 0),(0,C.Cg)([l.observable],A.prototype,"definition",void 0),(0,C.Cg)([l.attr],A.prototype,"name",void 0),(0,C.Cg)([(0,l.attr)({attribute:"open",mode:"boolean"})],A.prototype,"open",void 0),(0,C.Cg)([l.attr],A.prototype,"buttonAppearance",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-disabled",mode:"boolean"})],A.prototype,"hideDisabled",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-menu-single-option",mode:"boolean"})],A.prototype,"hideMenuSingleOption",void 0),(0,C.Cg)([l.observable],A.prototype,"singleOption",void 0);const D=A.compose({baseName:"actions-menu",styles:S,template:R});function N(){return"undefined"!=typeof window&&("SpeechRecognition"in window||"webkitSpeechRecognition"in window)}class L{getStatus(){return(0,C.sH)(this,void 0,void 0,function*(){return{provider:"none",model:""}})}interpretCriteria(e,t){return(0,C.sH)(this,void 0,void 0,function*(){return null})}}const F=a.DI.createInterface(e=>e.singleton(L));const M=l.css`
164
164
  :host {
165
165
  display: block;
166
166
  width: 800px;
@@ -231,7 +231,7 @@
231
231
  </div>
232
232
  `)}
233
233
  `;var t}}
234
- `;var U=i(95553),B=i(58749),W=i(14609),G=i(86636);const j={contains:U.n.containsIgnoreCase,equals:U.n.EQ,startsWith:U.n.startsWith,endsWith:U.n.endsWith,greaterThan:U.n.GT,lessThan:U.n.LT,greaterThanOrEqual:U.n.GE,lessThanOrEqual:U.n.LE,notEqual:U.n.NE,dateIsToday:U.n.dateIsToday,dateIsAfter:U.n.dateIsGreaterEqual,dateIsGreaterEqual:U.n.dateIsGreaterEqual,dateIsBefore:U.n.dateIsLessEqual,dateIsLessEqual:U.n.dateIsLessEqual,dateIsEqual:U.n.dateIsEqual,dateTimeIsAfter:U.n.dateTimeIsGreaterEqual,dateTimeIsGreaterEqual:U.n.dateTimeIsGreaterEqual,dateTimeIsBefore:U.n.dateTimeIsLessEqual,dateTimeIsLessEqual:U.n.dateTimeIsLessEqual};function V(e){var t,i;const o=null!==(t=j[e.operator])&&void 0!==t?t:U.n.containsIgnoreCase;return(new B.K).withField(e.field).withValue(null!==(i=e.value)&&void 0!==i?i:null).withSerialiser(o).withGroup("default").build()}function Y(e,t){return 1===e.length?e[0]:e.reduce((e,i,o)=>0===o?[i]:[...e,t,i],[])}function q(e){var t;const i=new W.b;let o=!1;for(const n of e){if(!(null===(t=n.clauses)||void 0===t?void 0:t.length))continue;const e=n.clauses.map(V),a="or"===n.logic?G.r.Or():G.r.And(),s=Y(e,a),r=e.length>1?{join:a}:{};n.negated?i.And([G.r.Not(),s]):i.And(1===e.length?e[0]:e,r),o=!0}return o?i.build():""}const K=["contains","equals","startsWith","endsWith","notEqual"],X=["equals","greaterThan","lessThan","greaterThanOrEqual","lessThanOrEqual","notEqual"],Q=["dateIsToday","dateIsAfter","dateIsBefore","dateIsEqual","dateIsGreaterEqual","dateIsLessEqual"],J=["dateTimeIsAfter","dateTimeIsBefore","dateTimeIsGreaterEqual","dateTimeIsLessEqual"],Z=new Set(["DATE","LOCALDATE"]),ee=new Set(["DATETIME","NANO_TIMESTAMP","LOCALDATETIME","TIMESTAMP"]),te=new Set(["INT","INTEGER","LONG","SHORT","DOUBLE","BIGDECIMAL","DECIMAL"]);function ie(e){return(e||"").toUpperCase().trim().split("(")[0].trim()}function oe(e){const t=ie(e);return Z.has(t)?Q:ee.has(t)?J:te.has(t)?X:K}function ne(e){return te.has(ie(e))}function ae(e){return null!=e&&("number"==typeof e?!Number.isNaN(e)&&e>0:"string"==typeof e&&(/^\d{8}$/.test(e)||/^\d{4}-\d{2}-\d{2}$/.test(e)||/^\d{8}-\d{2}:\d{2}(:\d{2})?$/.test(e)))}function se(e){return null!=e&&("number"==typeof e?!Number.isNaN(e):"string"==typeof e&&!Number.isNaN(Number(e)))}function re(e,t){const i=[],o=[],n=new Map;if(Array.isArray(t)&&t.length>0){"string"==typeof t[0]?t.forEach(e=>n.set(e,void 0)):t.forEach(e=>n.set(e.NAME,e))}for(const t of e){const{field:e,operator:a,value:s}=t;if(!e||"string"!=typeof e){o.push({field:String(e),message:"Field name is required"});continue}const r=n.get(e),l=r&&"TYPE"in r?r.TYPE:"STRING";oe(l).includes(a)?!Q.includes(a)&&!J.includes(a)||"dateIsToday"===a||ae(s)?ne(l)&&X.includes(a)&&!se(s)?o.push({field:e,operator:a,value:s,message:"Invalid numeric value"}):n.size>0&&!n.has(e)?o.push({field:e,operator:a,value:s,message:`Unknown field '${e}'`}):i.push(t):o.push({field:e,operator:a,value:s,message:"Invalid date/datetime value; use yyyyMMdd, yyyy-MM-dd, or epoch"}):o.push({field:e,operator:a,value:s,message:`Operator '${a}' is not allowed for field type ${l}`})}return{valid:i,invalid:o}}function le(e,t){var i;const o=[],n=[];for(const a of e){if(!(null==a?void 0:a.clauses)||!Array.isArray(a.clauses)){n.push({field:"",message:"Group must have a clauses array"});continue}const{valid:e,invalid:s}=re(a.clauses,t);n.push(...s),e.length>0&&o.push({logic:null!==(i=a.logic)&&void 0!==i?i:"and",negated:a.negated,clauses:e})}return{valid:o,invalid:n}}var de=i(60416);var ce=i(31274);var ue=i(52945);const he=(e,t,i)=>{var o,n,a,s,r,l,d,c,u,h,p,m,v,g,f,b,y,w,C;(0,de.u_)(e);const x=t.split("-")[0],$=(null===(n=null===(o=null==e?void 0:e.config)||void 0===o?void 0:o.toast)||void 0===n?void 0:n.position)||"top-right",S=null!==(a=null!=i?i:(e=>(0,ue.fI)(document.body).find(t=>"notify-container"===t.tagName.toLowerCase()&&t.position===e))($))&&void 0!==a?a:(0,de.jE)("notify-container",t);S&&"notify-container"!==S.tagName.toLowerCase()&&function(e,t){var i,o;switch(t.style.position="fixed",null===(o=null===(i=null==e?void 0:e.config)||void 0===i?void 0:i.toast)||void 0===o?void 0:o.position){case"top-left":t.style.top="var(--nav-height, 0)",t.style.left="0";break;case"bottom-left":t.style.bottom="0",t.style.left="0";break;case"bottom-right":t.style.bottom="0",t.style.right="0";break;default:t.style.top="var(--nav-height, 0)",t.style.right="0"}}(e,S);const E=document.createElement(`${x}-toast`),k=document.createElement("div");k.setAttribute("slot","top"),k.textContent=e.title;const O=document.createElement("div");O.setAttribute("slot","content"),O.textContent=(null==e?void 0:e.body)||"";const T=document.createElement("div");let I;T.setAttribute("slot","date"),T.textContent=(null===(s=null==e?void 0:e.createdAt)||void 0===s?void 0:s.toLocaleTimeString())||"",(null===(l=null===(r=null==e?void 0:e.config)||void 0===r?void 0:r.toast)||void 0===l?void 0:l.buttons)&&(null===(u=null===(c=null===(d=null==e?void 0:e.config)||void 0===d?void 0:d.toast)||void 0===c?void 0:c.buttons)||void 0===u?void 0:u.length)&&(I=document.createElement("div"),I.setAttribute("slot","bottom"),e.config.toast.buttons.forEach(t=>{const i=document.createElement(`${x}-button`);i.textContent=t.placeholder||"example placeholder",i.addEventListener("click",()=>{const{details:o}=e.config.toast;if(t.action)return t.action({details:o,buttonElement:i,toastElement:E})}),t.appearance&&i.setAttribute("appearance",t.appearance),I.appendChild(i)})),E.setAttribute("notify",(null===(p=null===(h=null==e?void 0:e.config)||void 0===h?void 0:h.toast)||void 0===p?void 0:p.type)||""),e.iconName&&E.setAttribute("notification-icon",e.iconName),(null===(v=null===(m=null==e?void 0:e.config)||void 0===m?void 0:m.toast)||void 0===v?void 0:v.autoClose)&&E.setAttribute("auto-close",`${null===(f=null===(g=null==e?void 0:e.config)||void 0===g?void 0:g.toast)||void 0===f?void 0:f.autoClose}`),(null===(y=null===(b=null==e?void 0:e.config)||void 0===b?void 0:b.toast)||void 0===y?void 0:y.closeTimeout)&&E.setAttribute("close-timeout",`${null===(C=null===(w=null==e?void 0:e.config)||void 0===w?void 0:w.toast)||void 0===C?void 0:C.closeTimeout}`),E.appendChild(k),E.appendChild(O),E.appendChild(T),I&&E.appendChild(I),S.prepend(E)},pe={alert:e=>{(0,de.u_)(e),alert((0,de.uP)(e))},toast:he,dialog:ce.u,snackbar:(e,t)=>{(0,de.u_)(e);const i=t.split("-")[0],o=document.createElement(`${i}-snackbar`),n=(0,de.jE)("snack-container",t);n&&(n.style.position="fixed",n.style.bottom="0",n.style.left="0"),n.appendChild(o),o.notification=e},banner:(e,t,i)=>{var o;(0,de.u_)(e);const n=t.split("-")[0],a=document.createElement(`${n}-banner`),s=(0,de.cL)(i);(null===(o=null==s?void 0:s.children)||void 0===o?void 0:o.length)>0&&(a.style.position="absolute",a.style.top="0",a.style.left="0",a.style.width="100%"),s.appendChild(a),a.notification=e}},me=(e,t,i)=>{Object.keys((null==e?void 0:e.config)||{}).forEach(o=>{pe[o]&&pe[o](e,t,i)})};function ve(e,t,i){(null==t?void 0:t.trim())&&me({title:e,body:t,config:{toast:{autoClose:!0,closeTimeout:4e3,type:"error"}}},i)}class ge extends s.FoundationElement{constructor(){super(...arguments),this.placeholder="Describe your search criteria in natural language...",this.mode="replace",this.inputValue="",this.isInterpreting=!1,this.lastValidCriteria=null,this.fieldMetadata=[],this.isRecording=!1,this.stopRecording=null,this.speechApplyDebounceTimer=null,this.baseInputForAppend=""}get speechAvailable(){return N()}handleSubmit(){return(0,C.sH)(this,void 0,void 0,function*(){var e,t,i;const o=null===(e=this.inputValue)||void 0===e?void 0:e.trim();if(o&&!this.isInterpreting)if(null===(t=this.aiProvider)||void 0===t?void 0:t.interpretCriteria){this.isInterpreting=!0;try{const e=Array.isArray(this.fieldMetadata)?this.fieldMetadata:[],t=yield this.aiProvider.interpretCriteria(o,{fields:e});if(!(null===(i=null==t?void 0:t.groups)||void 0===i?void 0:i.some(e=>{var t;return null===(t=e.clauses)||void 0===t?void 0:t.length})))return ve("AI criteria search","AI could not interpret the criteria",O(this)),void(this.isInterpreting=!1);const{valid:a,invalid:s}=le(t.groups,this.fieldMetadata);if(s.length>0&&(ve("Criteria validation error",0===(n=s).length?"":1===n.length?n[0].message:n.map(e=>e.message).join("; "),O(this)),this.$emit("validation-errors",s)),a.length>0){const e=q(a);this.lastValidCriteria=e,this.$emit("criteria-changed",e)}}catch(e){ve("AI criteria search",e instanceof Error?e.message:"Interpretation failed",O(this))}finally{this.isInterpreting=!1}var n}else ve("AI criteria search","AI provider not configured",O(this))})}handleBlur(){var e;if(this.isRecording)return;(null===(e=this.inputValue)||void 0===e?void 0:e.trim())?this.handleSubmit():this.clear()}clear(){this.inputValue="",this.lastValidCriteria=null,this.$emit("criteria-changed",null)}toggleSpeechInput(){var e,t;if(this.isRecording&&this.stopRecording)return this.clearSpeechApplyDebounce(),this.stopRecording(),this.stopRecording=null,this.isRecording=!1,void(this.baseInputForAppend="");this.baseInputForAppend="append"===this.mode&&null!==(t=null===(e=this.inputValue)||void 0===e?void 0:e.trim())&&void 0!==t?t:"",this.stopRecording=function(e,t){if(!N())return null;const i=new(window.SpeechRecognition||window.webkitSpeechRecognition);i.continuous=!0,i.interimResults=!0,i.lang="en-US";let o="";return i.onresult=t=>{let i="",n="";for(let e=t.resultIndex;e<t.results.length;e+=1){const o=t.results[e][0].transcript;t.results[e].isFinal?n+=o:i+=o}n?(o+=n,e(o,!0)):i&&e(o+i,!1)},i.onerror=e=>{"aborted"!==e.error&&(null==t||t(e.error||"Speech recognition error"))},i.start(),()=>{try{i.stop()}catch(e){}}}((e,t)=>{"append"===this.mode?this.inputValue=this.baseInputForAppend?`${this.baseInputForAppend} ${e}`.trim():e:this.inputValue=e,t&&(null==e?void 0:e.trim())&&(this.clearSpeechApplyDebounce(),this.stopRecording&&(this.stopRecording(),this.stopRecording=null,this.isRecording=!1,this.baseInputForAppend=""),this.speechApplyDebounceTimer=setTimeout(()=>{this.speechApplyDebounceTimer=null,this.handleSubmit()},700))},()=>{this.clearSpeechApplyDebounce(),this.isRecording=!1,this.stopRecording=null,this.baseInputForAppend=""}),this.stopRecording&&(this.isRecording=!0)}clearSpeechApplyDebounce(){this.speechApplyDebounceTimer&&(clearTimeout(this.speechApplyDebounceTimer),this.speechApplyDebounceTimer=null)}}(0,C.Cg)([F],ge.prototype,"aiProvider",void 0),(0,C.Cg)([l.attr],ge.prototype,"placeholder",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ge.prototype,"disabled",void 0),(0,C.Cg)([l.attr],ge.prototype,"mode",void 0),(0,C.Cg)([l.observable],ge.prototype,"inputValue",void 0),(0,C.Cg)([l.observable],ge.prototype,"isInterpreting",void 0),(0,C.Cg)([l.observable],ge.prototype,"lastValidCriteria",void 0),(0,C.Cg)([l.observable],ge.prototype,"fieldMetadata",void 0),(0,C.Cg)([l.observable],ge.prototype,"isRecording",void 0),(0,C.Cg)([l.volatile],ge.prototype,"speechAvailable",null);const fe=void 0,be={},ye=ge.compose(Object.assign({baseName:"ai-criteria-search",template:z,styles:M,shadowOptions:fe},be)),we=(e,t)=>l.css`
234
+ `;var U=i(95553),W=i(58749),G=i(14609),B=i(86636);const V={contains:U.n.containsIgnoreCase,equals:U.n.EQ,startsWith:U.n.startsWith,endsWith:U.n.endsWith,greaterThan:U.n.GT,lessThan:U.n.LT,greaterThanOrEqual:U.n.GE,lessThanOrEqual:U.n.LE,notEqual:U.n.NE,dateIsToday:U.n.dateIsToday,dateIsAfter:U.n.dateIsGreaterEqual,dateIsGreaterEqual:U.n.dateIsGreaterEqual,dateIsBefore:U.n.dateIsLessEqual,dateIsLessEqual:U.n.dateIsLessEqual,dateIsEqual:U.n.dateIsEqual,dateTimeIsAfter:U.n.dateTimeIsGreaterEqual,dateTimeIsGreaterEqual:U.n.dateTimeIsGreaterEqual,dateTimeIsBefore:U.n.dateTimeIsLessEqual,dateTimeIsLessEqual:U.n.dateTimeIsLessEqual};function j(e){var t,i;const o=null!==(t=V[e.operator])&&void 0!==t?t:U.n.containsIgnoreCase;return(new W.K).withField(e.field).withValue(null!==(i=e.value)&&void 0!==i?i:null).withSerialiser(o).withGroup("default").build()}function Y(e,t){return 1===e.length?e[0]:e.reduce((e,i,o)=>0===o?[i]:[...e,t,i],[])}function q(e){var t;const i=new G.b;let o=!1;for(const n of e){if(!(null===(t=n.clauses)||void 0===t?void 0:t.length))continue;const e=n.clauses.map(j),s="or"===n.logic?B.r.Or():B.r.And(),a=Y(e,s),r=e.length>1?{join:s}:{};n.negated?i.And([B.r.Not(),a]):i.And(1===e.length?e[0]:e,r),o=!0}return o?i.build():""}const K=["contains","equals","startsWith","endsWith","notEqual"],X=["equals","greaterThan","lessThan","greaterThanOrEqual","lessThanOrEqual","notEqual"],Q=["dateIsToday","dateIsAfter","dateIsBefore","dateIsEqual","dateIsGreaterEqual","dateIsLessEqual"],J=["dateTimeIsAfter","dateTimeIsBefore","dateTimeIsGreaterEqual","dateTimeIsLessEqual"],Z=new Set(["DATE","LOCALDATE"]),ee=new Set(["DATETIME","NANO_TIMESTAMP","LOCALDATETIME","TIMESTAMP"]),te=new Set(["INT","INTEGER","LONG","SHORT","DOUBLE","BIGDECIMAL","DECIMAL"]);function ie(e){return(e||"").toUpperCase().trim().split("(")[0].trim()}function oe(e){const t=ie(e);return Z.has(t)?Q:ee.has(t)?J:te.has(t)?X:K}function ne(e){return te.has(ie(e))}function se(e){return null!=e&&("number"==typeof e?!Number.isNaN(e)&&e>0:"string"==typeof e&&(/^\d{8}$/.test(e)||/^\d{4}-\d{2}-\d{2}$/.test(e)||/^\d{8}-\d{2}:\d{2}(:\d{2})?$/.test(e)))}function ae(e){return null!=e&&("number"==typeof e?!Number.isNaN(e):"string"==typeof e&&!Number.isNaN(Number(e)))}function re(e,t){const i=[],o=[],n=new Map;if(Array.isArray(t)&&t.length>0){"string"==typeof t[0]?t.forEach(e=>n.set(e,void 0)):t.forEach(e=>n.set(e.NAME,e))}for(const t of e){const{field:e,operator:s,value:a}=t;if(!e||"string"!=typeof e){o.push({field:String(e),message:"Field name is required"});continue}const r=n.get(e),l=r&&"TYPE"in r?r.TYPE:"STRING";oe(l).includes(s)?!Q.includes(s)&&!J.includes(s)||"dateIsToday"===s||se(a)?ne(l)&&X.includes(s)&&!ae(a)?o.push({field:e,operator:s,value:a,message:"Invalid numeric value"}):n.size>0&&!n.has(e)?o.push({field:e,operator:s,value:a,message:`Unknown field '${e}'`}):i.push(t):o.push({field:e,operator:s,value:a,message:"Invalid date/datetime value; use yyyyMMdd, yyyy-MM-dd, or epoch"}):o.push({field:e,operator:s,value:a,message:`Operator '${s}' is not allowed for field type ${l}`})}return{valid:i,invalid:o}}function le(e,t){var i;const o=[],n=[];for(const s of e){if(!(null==s?void 0:s.clauses)||!Array.isArray(s.clauses)){n.push({field:"",message:"Group must have a clauses array"});continue}const{valid:e,invalid:a}=re(s.clauses,t);n.push(...a),e.length>0&&o.push({logic:null!==(i=s.logic)&&void 0!==i?i:"and",negated:s.negated,clauses:e})}return{valid:o,invalid:n}}var de=i(60416);var ce=i(31274);var ue=i(52945);const he=(e,t,i)=>{var o,n,s,a,r,l,d,c,u,h,p,m,g,v,f,b,y,w,C;(0,de.u_)(e);const x=t.split("-")[0],$=(null===(n=null===(o=null==e?void 0:e.config)||void 0===o?void 0:o.toast)||void 0===n?void 0:n.position)||"top-right",S=null!==(s=null!=i?i:(e=>(0,ue.fI)(document.body).find(t=>"notify-container"===t.tagName.toLowerCase()&&t.position===e))($))&&void 0!==s?s:(0,de.jE)("notify-container",t);S&&"notify-container"!==S.tagName.toLowerCase()&&function(e,t){var i,o;switch(t.style.position="fixed",null===(o=null===(i=null==e?void 0:e.config)||void 0===i?void 0:i.toast)||void 0===o?void 0:o.position){case"top-left":t.style.top="var(--nav-height, 0)",t.style.left="0";break;case"bottom-left":t.style.bottom="0",t.style.left="0";break;case"bottom-right":t.style.bottom="0",t.style.right="0";break;default:t.style.top="var(--nav-height, 0)",t.style.right="0"}}(e,S);const E=document.createElement(`${x}-toast`),k=document.createElement("div");k.setAttribute("slot","top"),k.textContent=e.title;const O=document.createElement("div");O.setAttribute("slot","content"),O.textContent=(null==e?void 0:e.body)||"";const T=document.createElement("div");let I;T.setAttribute("slot","date"),T.textContent=(null===(a=null==e?void 0:e.createdAt)||void 0===a?void 0:a.toLocaleTimeString())||"",(null===(l=null===(r=null==e?void 0:e.config)||void 0===r?void 0:r.toast)||void 0===l?void 0:l.buttons)&&(null===(u=null===(c=null===(d=null==e?void 0:e.config)||void 0===d?void 0:d.toast)||void 0===c?void 0:c.buttons)||void 0===u?void 0:u.length)&&(I=document.createElement("div"),I.setAttribute("slot","bottom"),e.config.toast.buttons.forEach(t=>{const i=document.createElement(`${x}-button`);i.textContent=t.placeholder||"example placeholder",i.addEventListener("click",()=>{const{details:o}=e.config.toast;if(t.action)return t.action({details:o,buttonElement:i,toastElement:E})}),t.appearance&&i.setAttribute("appearance",t.appearance),I.appendChild(i)})),E.setAttribute("notify",(null===(p=null===(h=null==e?void 0:e.config)||void 0===h?void 0:h.toast)||void 0===p?void 0:p.type)||""),e.iconName&&E.setAttribute("notification-icon",e.iconName),(null===(g=null===(m=null==e?void 0:e.config)||void 0===m?void 0:m.toast)||void 0===g?void 0:g.autoClose)&&E.setAttribute("auto-close",`${null===(f=null===(v=null==e?void 0:e.config)||void 0===v?void 0:v.toast)||void 0===f?void 0:f.autoClose}`),(null===(y=null===(b=null==e?void 0:e.config)||void 0===b?void 0:b.toast)||void 0===y?void 0:y.closeTimeout)&&E.setAttribute("close-timeout",`${null===(C=null===(w=null==e?void 0:e.config)||void 0===w?void 0:w.toast)||void 0===C?void 0:C.closeTimeout}`),E.appendChild(k),E.appendChild(O),E.appendChild(T),I&&E.appendChild(I),S.prepend(E)},pe={alert:e=>{(0,de.u_)(e),alert((0,de.uP)(e))},toast:he,dialog:ce.u,snackbar:(e,t)=>{(0,de.u_)(e);const i=t.split("-")[0],o=document.createElement(`${i}-snackbar`),n=(0,de.jE)("snack-container",t);n&&(n.style.position="fixed",n.style.bottom="0",n.style.left="0"),n.appendChild(o),o.notification=e},banner:(e,t,i)=>{var o;(0,de.u_)(e);const n=t.split("-")[0],s=document.createElement(`${n}-banner`),a=(0,de.cL)(i);(null===(o=null==a?void 0:a.children)||void 0===o?void 0:o.length)>0&&(s.style.position="absolute",s.style.top="0",s.style.left="0",s.style.width="100%"),a.appendChild(s),s.notification=e}},me=(e,t,i)=>{Object.keys((null==e?void 0:e.config)||{}).forEach(o=>{pe[o]&&pe[o](e,t,i)})};function ge(e,t,i){(null==t?void 0:t.trim())&&me({title:e,body:t,config:{toast:{autoClose:!0,closeTimeout:4e3,type:"error"}}},i)}class ve extends a.FoundationElement{constructor(){super(...arguments),this.placeholder="Describe your search criteria in natural language...",this.mode="replace",this.inputValue="",this.isInterpreting=!1,this.lastValidCriteria=null,this.fieldMetadata=[],this.isRecording=!1,this.stopRecording=null,this.speechApplyDebounceTimer=null,this.baseInputForAppend=""}get speechAvailable(){return N()}handleSubmit(){return(0,C.sH)(this,void 0,void 0,function*(){var e,t,i;const o=null===(e=this.inputValue)||void 0===e?void 0:e.trim();if(o&&!this.isInterpreting)if(null===(t=this.aiProvider)||void 0===t?void 0:t.interpretCriteria){this.isInterpreting=!0;try{const e=Array.isArray(this.fieldMetadata)?this.fieldMetadata:[],t=yield this.aiProvider.interpretCriteria(o,{fields:e});if(!(null===(i=null==t?void 0:t.groups)||void 0===i?void 0:i.some(e=>{var t;return null===(t=e.clauses)||void 0===t?void 0:t.length})))return ge("AI criteria search","AI could not interpret the criteria",O(this)),void(this.isInterpreting=!1);const{valid:s,invalid:a}=le(t.groups,this.fieldMetadata);if(a.length>0&&(ge("Criteria validation error",0===(n=a).length?"":1===n.length?n[0].message:n.map(e=>e.message).join("; "),O(this)),this.$emit("validation-errors",a)),s.length>0){const e=q(s);this.lastValidCriteria=e,this.$emit("criteria-changed",e)}}catch(e){ge("AI criteria search",e instanceof Error?e.message:"Interpretation failed",O(this))}finally{this.isInterpreting=!1}var n}else ge("AI criteria search","AI provider not configured",O(this))})}handleBlur(){var e;if(this.isRecording)return;(null===(e=this.inputValue)||void 0===e?void 0:e.trim())?this.handleSubmit():this.clear()}clear(){this.inputValue="",this.lastValidCriteria=null,this.$emit("criteria-changed",null)}toggleSpeechInput(){var e,t;if(this.isRecording&&this.stopRecording)return this.clearSpeechApplyDebounce(),this.stopRecording(),this.stopRecording=null,this.isRecording=!1,void(this.baseInputForAppend="");this.baseInputForAppend="append"===this.mode&&null!==(t=null===(e=this.inputValue)||void 0===e?void 0:e.trim())&&void 0!==t?t:"",this.stopRecording=function(e,t){if(!N())return null;const i=new(window.SpeechRecognition||window.webkitSpeechRecognition);i.continuous=!0,i.interimResults=!0,i.lang="en-US";let o="";return i.onresult=t=>{let i="",n="";for(let e=t.resultIndex;e<t.results.length;e+=1){const o=t.results[e][0].transcript;t.results[e].isFinal?n+=o:i+=o}n?(o+=n,e(o,!0)):i&&e(o+i,!1)},i.onerror=e=>{"aborted"!==e.error&&(null==t||t(e.error||"Speech recognition error"))},i.start(),()=>{try{i.stop()}catch(e){}}}((e,t)=>{"append"===this.mode?this.inputValue=this.baseInputForAppend?`${this.baseInputForAppend} ${e}`.trim():e:this.inputValue=e,t&&(null==e?void 0:e.trim())&&(this.clearSpeechApplyDebounce(),this.stopRecording&&(this.stopRecording(),this.stopRecording=null,this.isRecording=!1,this.baseInputForAppend=""),this.speechApplyDebounceTimer=setTimeout(()=>{this.speechApplyDebounceTimer=null,this.handleSubmit()},700))},()=>{this.clearSpeechApplyDebounce(),this.isRecording=!1,this.stopRecording=null,this.baseInputForAppend=""}),this.stopRecording&&(this.isRecording=!0)}clearSpeechApplyDebounce(){this.speechApplyDebounceTimer&&(clearTimeout(this.speechApplyDebounceTimer),this.speechApplyDebounceTimer=null)}}(0,C.Cg)([F],ve.prototype,"aiProvider",void 0),(0,C.Cg)([l.attr],ve.prototype,"placeholder",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ve.prototype,"disabled",void 0),(0,C.Cg)([l.attr],ve.prototype,"mode",void 0),(0,C.Cg)([l.observable],ve.prototype,"inputValue",void 0),(0,C.Cg)([l.observable],ve.prototype,"isInterpreting",void 0),(0,C.Cg)([l.observable],ve.prototype,"lastValidCriteria",void 0),(0,C.Cg)([l.observable],ve.prototype,"fieldMetadata",void 0),(0,C.Cg)([l.observable],ve.prototype,"isRecording",void 0),(0,C.Cg)([l.volatile],ve.prototype,"speechAvailable",null);const fe=void 0,be={},ye=ve.compose(Object.assign({baseName:"ai-criteria-search",template:z,styles:M,shadowOptions:fe},be)),we=(e,t)=>l.css`
235
235
  :host {
236
236
  display: flex;
237
237
  justify-content: center;
@@ -418,19 +418,19 @@
418
418
  </div>
419
419
  `)}
420
420
  `;var t}}
421
- `;class xe extends s.FoundationElement{constructor(){super(...arguments),this.status=null,this.open=!1,this.state="none",this.isInstalling=!1,this.pollTimer=null,this.clickOutside=e=>this.handleClickOutside(e)}get chromeStatusLabel(){var e,t;if("chrome"!==(null===(e=this.status)||void 0===e?void 0:e.provider))return null;const i=null===(t=this.status)||void 0===t?void 0:t.chromeAvailability;return"available"===i?"Installed":"downloading"===i||this.isInstalling?"Downloading…":"downloadable"===i?"Downloadable":"unavailable"===i?"Unavailable":null}get canInstall(){var e,t,i;return!!(null===(e=this.aiProvider)||void 0===e?void 0:e.triggerDownload)&&"chrome"===(null===(t=this.status)||void 0===t?void 0:t.provider)&&"downloadable"===(null===(i=this.status)||void 0===i?void 0:i.chromeAvailability)&&!this.isInstalling}get isDownloading(){var e;return"downloading"===(null===(e=this.status)||void 0===e?void 0:e.chromeAvailability)||this.isInstalling}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){e.connectedCallback.call(this),yield this.refreshStatus(),this.maybeStartPolling()})}disconnectedCallback(){this.stopPolling(),document.removeEventListener("mousedown",this.clickOutside)}openChanged(){this.open?(document.addEventListener("mousedown",this.clickOutside),this.refreshStatus()):document.removeEventListener("mousedown",this.clickOutside)}handleClickOutside(e){E(e,this)&&(this.open=!1)}toggleDropdown(){this.open=!this.open}refreshStatus(){return(0,C.sH)(this,void 0,void 0,function*(){var e;if(!(null===(e=this.aiProvider)||void 0===e?void 0:e.getStatus))return this.status=null,void(this.state="none");try{const e=yield this.aiProvider.getStatus();this.status=e,this.state=this.deriveState(e),"available"===this.state&&(this.isInstalling=!1)}catch(e){this.status=null,this.state="none",this.isInstalling=!1}})}deriveState(e){if(!e||"none"===e.provider)return"none";if("chrome"===e.provider){const t=e.chromeAvailability;return"available"===t?"available":"downloading"===t?"downloading":"downloadable"===t?"downloadable":"unavailable"}return"server"}maybeStartPolling(){var e;"downloading"===(null===(e=this.status)||void 0===e?void 0:e.chromeAvailability)||this.isInstalling?this.startPolling():this.stopPolling()}startPolling(){this.pollTimer||(this.pollTimer=setInterval(()=>{this.refreshStatus().then(()=>{this.maybeStartPolling()})},2500))}stopPolling(){this.pollTimer&&(clearInterval(this.pollTimer),this.pollTimer=null)}onInstall(){return(0,C.sH)(this,void 0,void 0,function*(){var e;if(this.canInstall&&(null===(e=this.aiProvider)||void 0===e?void 0:e.triggerDownload)){this.isInstalling=!0;try{yield this.aiProvider.triggerDownload(),this.startPolling()}catch(e){this.isInstalling=!1}finally{yield this.refreshStatus()}}})}}(0,C.Cg)([F],xe.prototype,"aiProvider",void 0),(0,C.Cg)([l.observable],xe.prototype,"status",void 0),(0,C.Cg)([l.observable],xe.prototype,"open",void 0),(0,C.Cg)([l.observable],xe.prototype,"state",void 0),(0,C.Cg)([l.observable],xe.prototype,"isInstalling",void 0),(0,C.Cg)([l.volatile],xe.prototype,"chromeStatusLabel",null),(0,C.Cg)([l.volatile],xe.prototype,"canInstall",null),(0,C.Cg)([l.volatile],xe.prototype,"isDownloading",null);const $e=xe.compose({baseName:"ai-indicator",template:Ce,styles:we}),Se=(e,t)=>l.css`
421
+ `;class xe extends a.FoundationElement{constructor(){super(...arguments),this.status=null,this.open=!1,this.state="none",this.isInstalling=!1,this.pollTimer=null,this.clickOutside=e=>this.handleClickOutside(e)}get chromeStatusLabel(){var e,t;if("chrome"!==(null===(e=this.status)||void 0===e?void 0:e.provider))return null;const i=null===(t=this.status)||void 0===t?void 0:t.chromeAvailability;return"available"===i?"Installed":"downloading"===i||this.isInstalling?"Downloading…":"downloadable"===i?"Downloadable":"unavailable"===i?"Unavailable":null}get canInstall(){var e,t,i;return!!(null===(e=this.aiProvider)||void 0===e?void 0:e.triggerDownload)&&"chrome"===(null===(t=this.status)||void 0===t?void 0:t.provider)&&"downloadable"===(null===(i=this.status)||void 0===i?void 0:i.chromeAvailability)&&!this.isInstalling}get isDownloading(){var e;return"downloading"===(null===(e=this.status)||void 0===e?void 0:e.chromeAvailability)||this.isInstalling}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){e.connectedCallback.call(this),yield this.refreshStatus(),this.maybeStartPolling()})}disconnectedCallback(){this.stopPolling(),document.removeEventListener("mousedown",this.clickOutside)}openChanged(){this.open?(document.addEventListener("mousedown",this.clickOutside),this.refreshStatus()):document.removeEventListener("mousedown",this.clickOutside)}handleClickOutside(e){E(e,this)&&(this.open=!1)}toggleDropdown(){this.open=!this.open}refreshStatus(){return(0,C.sH)(this,void 0,void 0,function*(){var e;if(!(null===(e=this.aiProvider)||void 0===e?void 0:e.getStatus))return this.status=null,void(this.state="none");try{const e=yield this.aiProvider.getStatus();this.status=e,this.state=this.deriveState(e),"available"===this.state&&(this.isInstalling=!1)}catch(e){this.status=null,this.state="none",this.isInstalling=!1}})}deriveState(e){if(!e||"none"===e.provider)return"none";if("chrome"===e.provider){const t=e.chromeAvailability;return"available"===t?"available":"downloading"===t?"downloading":"downloadable"===t?"downloadable":"unavailable"}return"server"}maybeStartPolling(){var e;"downloading"===(null===(e=this.status)||void 0===e?void 0:e.chromeAvailability)||this.isInstalling?this.startPolling():this.stopPolling()}startPolling(){this.pollTimer||(this.pollTimer=setInterval(()=>{this.refreshStatus().then(()=>{this.maybeStartPolling()})},2500))}stopPolling(){this.pollTimer&&(clearInterval(this.pollTimer),this.pollTimer=null)}onInstall(){return(0,C.sH)(this,void 0,void 0,function*(){var e;if(this.canInstall&&(null===(e=this.aiProvider)||void 0===e?void 0:e.triggerDownload)){this.isInstalling=!0;try{yield this.aiProvider.triggerDownload(),this.startPolling()}catch(e){this.isInstalling=!1}finally{yield this.refreshStatus()}}})}}(0,C.Cg)([F],xe.prototype,"aiProvider",void 0),(0,C.Cg)([l.observable],xe.prototype,"status",void 0),(0,C.Cg)([l.observable],xe.prototype,"open",void 0),(0,C.Cg)([l.observable],xe.prototype,"state",void 0),(0,C.Cg)([l.observable],xe.prototype,"isInstalling",void 0),(0,C.Cg)([l.volatile],xe.prototype,"chromeStatusLabel",null),(0,C.Cg)([l.volatile],xe.prototype,"canInstall",null),(0,C.Cg)([l.volatile],xe.prototype,"isDownloading",null);const $e=xe.compose({baseName:"ai-indicator",template:Ce,styles:we}),Se=(e,t)=>l.css`
422
422
  ${(0,r.anchorStyles)(e,t)}
423
- `,Ee=(e,t)=>(0,s.anchorTemplate)(e,t);class ke extends r.Anchor{}const Oe={delegatesFocus:!0,mode:"open"},Te={},Ie=ke.compose(Object.assign({baseName:"anchor",template:Ee,styles:Se,shadowOptions:Oe},Te)),De=(e,t)=>(0,s.anchoredRegionTemplate)(e,t),Re=(e,t)=>l.css`
423
+ `,Ee=(e,t)=>(0,a.anchorTemplate)(e,t);class ke extends r.Anchor{}const Oe={delegatesFocus:!0,mode:"open"},Te={},Ie=ke.compose(Object.assign({baseName:"anchor",template:Ee,styles:Se,shadowOptions:Oe},Te)),Re=(e,t)=>(0,a.anchoredRegionTemplate)(e,t),Ae=(e,t)=>l.css`
424
424
  ${(0,r.anchoredRegionStyles)(e,t)}
425
- `;class Ae extends r.AnchoredRegion{}const Ne={delegatesFocus:!0,mode:"open"},Le={},Fe=Ae.compose(Object.assign({baseName:"anchored-region",template:De,styles:Re,shadowOptions:Ne},Le)),Me=(e,t)=>l.css`
425
+ `;class De extends r.AnchoredRegion{}const Ne={delegatesFocus:!0,mode:"open"},Le={},Fe=De.compose(Object.assign({baseName:"anchored-region",template:Re,styles:Ae,shadowOptions:Ne},Le)),Me=(e,t)=>l.css`
426
426
  ${(0,r.avatarStyles)(e,t)}
427
- `,_e=(e,t)=>(0,s.avatarTemplate)(e,t),He=l.html`
427
+ `,_e=(e,t)=>(0,a.avatarTemplate)(e,t),He=l.html`
428
428
  ${(0,l.when)(e=>e.imgSrc,l.html`
429
429
  <img src="${e=>e.imgSrc}" alt="${e=>e.alt}" slot="media" class="media" part="media" />
430
430
  `)}
431
- `;class Pe extends r.Avatar{}const ze={delegatesFocus:!0,mode:"open"},Ue={media:He},Be=Pe.compose(Object.assign({baseName:"avatar",template:_e,styles:Me,shadowOptions:ze},Ue)),We=(e,t)=>l.css`
431
+ `;class Pe extends r.Avatar{}const ze={delegatesFocus:!0,mode:"open"},Ue={media:He},We=Pe.compose(Object.assign({baseName:"avatar",template:_e,styles:Me,shadowOptions:ze},Ue)),Ge=(e,t)=>l.css`
432
432
  ${(0,r.badgeStyles)(e,t)}
433
- `,Ge=(e,t)=>(0,s.badgeTemplate)(e,t);class je extends r.Badge{}const Ve=void 0,Ye={},qe=je.compose(Object.assign({baseName:"badge",template:Ge,styles:We,shadowOptions:Ve},Ye));var Ke=i(19867);const Xe=(0,Ke.createLogger)("foundation-ui"),Qe=l.css`
433
+ `,Be=(e,t)=>(0,a.badgeTemplate)(e,t);class Ve extends r.Badge{}const je=void 0,Ye={},qe=Ve.compose(Object.assign({baseName:"badge",template:Be,styles:Ge,shadowOptions:je},Ye));var Ke=i(19867);const Xe=(0,Ke.createLogger)("foundation-ui"),Qe=l.css`
434
434
  @keyframes delete-animate {
435
435
  from {
436
436
  height: 100px;
@@ -533,21 +533,21 @@
533
533
  </div>
534
534
  `,Ze=l.html`
535
535
  ${e=>Je(O(e))}
536
- `,et={mode:"open",delegatesFocus:!0};class tt extends s.FoundationElement{constructor(){super(...arguments),this.dismissAnimation=""}connectedCallback(){super.connectedCallback()}dismiss(){return this.dismissAnimation="banner-delete",new Promise(e=>{this.banner.onanimationend=()=>{this.remove(),e()}})}dismissNotification(){return(0,C.sH)(this,void 0,void 0,function*(){try{yield this.dismiss(),this.remove()}catch(e){Xe.error(e)}})}}(0,C.Cg)([l.observable],tt.prototype,"dismissAnimation",void 0),(0,C.Cg)([l.observable],tt.prototype,"notification",void 0);const it=tt.compose({baseName:"banner",styles:Qe,template:Ze,shadowOptions:et}),ot=(e,t)=>l.css`
536
+ `,et={mode:"open",delegatesFocus:!0};class tt extends a.FoundationElement{constructor(){super(...arguments),this.dismissAnimation=""}connectedCallback(){super.connectedCallback()}dismiss(){return this.dismissAnimation="banner-delete",new Promise(e=>{this.banner.onanimationend=()=>{this.remove(),e()}})}dismissNotification(){return(0,C.sH)(this,void 0,void 0,function*(){try{yield this.dismiss(),this.remove()}catch(e){Xe.error(e)}})}}(0,C.Cg)([l.observable],tt.prototype,"dismissAnimation",void 0),(0,C.Cg)([l.observable],tt.prototype,"notification",void 0);const it=tt.compose({baseName:"banner",styles:Qe,template:Ze,shadowOptions:et}),ot=(e,t)=>l.css`
537
537
  ${(0,r.breadcrumbStyles)(e,t)}
538
- `,nt=(e,t)=>(0,s.breadcrumbTemplate)(e,t);class at extends r.Breadcrumb{}const st=void 0,rt={},lt=at.compose(Object.assign({baseName:"breadcrumb",template:nt,styles:ot,shadowOptions:st},rt)),dt=(e,t)=>l.css`
538
+ `,nt=(e,t)=>(0,a.breadcrumbTemplate)(e,t);class st extends r.Breadcrumb{}const at=void 0,rt={},lt=st.compose(Object.assign({baseName:"breadcrumb",template:nt,styles:ot,shadowOptions:at},rt)),dt=(e,t)=>l.css`
539
539
  ${(0,r.breadcrumbItemStyles)(e,t)}
540
- `,ct=(e,t)=>(0,s.breadcrumbItemTemplate)(e,t);class ut extends r.BreadcrumbItem{}const ht=void 0,pt={separator:"/"},mt=ut.compose(Object.assign({baseName:"breadcrumb-item",template:ct,styles:dt,shadowOptions:ht},pt)),vt=(e,t)=>l.css`
540
+ `,ct=(e,t)=>(0,a.breadcrumbItemTemplate)(e,t);class ut extends r.BreadcrumbItem{}const ht=void 0,pt={separator:"/"},mt=ut.compose(Object.assign({baseName:"breadcrumb-item",template:ct,styles:dt,shadowOptions:ht},pt)),gt=(e,t)=>l.css`
541
541
  ${(0,r.buttonStyles)(e,t)}
542
- `,gt=(e,t)=>(0,s.buttonTemplate)(e,t);class ft extends r.Button{}const bt={delegatesFocus:!0,mode:"open"},yt={},wt=ft.compose(Object.assign({baseName:"button",template:gt,styles:vt,shadowOptions:bt},yt)),Ct=()=>l.css`
542
+ `,vt=(e,t)=>(0,a.buttonTemplate)(e,t);class ft extends r.Button{}const bt={delegatesFocus:!0,mode:"open"},yt={},wt=ft.compose(Object.assign({baseName:"button",template:vt,styles:gt,shadowOptions:bt},yt)),Ct=()=>l.css`
543
543
  ${r.CalendarStyles}
544
- `,xt=(e,t)=>(0,s.calendarTemplate)(e,t);class $t extends r.Calendar{}const St={delegatesFocus:!0,mode:"open"},Et={},kt=$t.compose(Object.assign({baseName:"calendar",template:xt,styles:Ct,shadowOptions:St},Et)),Ot=(e,t)=>l.css`
544
+ `,xt=(e,t)=>(0,a.calendarTemplate)(e,t);class $t extends r.Calendar{}const St={delegatesFocus:!0,mode:"open"},Et={},kt=$t.compose(Object.assign({baseName:"calendar",template:xt,styles:Ct,shadowOptions:St},Et)),Ot=(e,t)=>l.css`
545
545
  ${(0,r.cardStyles)(e,t)}
546
546
  :host {
547
547
  background-color: var(--fui-card-fill-color);
548
548
  color: var(--fui-card-foreground-color);
549
549
  }
550
- `,Tt=(e,t)=>(0,s.cardTemplate)(e,t);class It extends r.Card{}const Dt=void 0,Rt={},At=It.compose(Object.assign({baseName:"card",template:Tt,styles:Ot,shadowOptions:Dt},Rt));var Nt;!function(e){e.BELOW="below",e.ABOVE="above"}(Nt||(Nt={}));const Lt=450,Ft=l.css`
550
+ `,Tt=(e,t)=>(0,a.cardTemplate)(e,t);class It extends r.Card{}const Rt=void 0,At={},Dt=It.compose(Object.assign({baseName:"card",template:Tt,styles:Ot,shadowOptions:Rt},At));var Nt;!function(e){e.BELOW="below",e.ABOVE="above"}(Nt||(Nt={}));const Lt=450,Ft=l.css`
551
551
  .root {
552
552
  position: relative;
553
553
  width: 100%;
@@ -746,7 +746,7 @@
746
746
  class=${e=>{var t;return(0,x.x)("label",["label-hidden",!(null===(t=e.defaultSlottedNodes)||void 0===t?void 0:t.length)])}}
747
747
  >
748
748
  <slot
749
- ${(0,l.slotted)({property:"defaultSlottedNodes",filter:s.whitespaceFilter})}
749
+ ${(0,l.slotted)({property:"defaultSlottedNodes",filter:a.whitespaceFilter})}
750
750
  ></slot>
751
751
  </label>
752
752
  <${e}-button class="control-button" part="control-button">
@@ -808,9 +808,9 @@
808
808
  </div>
809
809
  `,_t=l.html`
810
810
  ${Mt()}
811
- `,Ht=void 0,Pt={};class zt extends s.FoundationElement{constructor(){super(...arguments),this.name="",this.autoPosition=!0,this.search=!0,this.disabled=!1,this.clickOutside=e=>this.handleClickOutside(e),this.open=!1,this.options=[],this.selectedOptions=[],this.position=Nt.BELOW}openChanged(e,t){var i,o;t?(document.addEventListener("mousedown",this.clickOutside),null===(i=this.optionsElement)||void 0===i||i.classList.add("visible")):(document.removeEventListener("mousedown",this.clickOutside),null===(o=this.optionsElement)||void 0===o||o.classList.remove("visible"))}connectedCallback(){var e;super.connectedCallback(),this.position===Nt.ABOVE&&(null===(e=this.optionsElement)||void 0===e||e.classList.add("position-above"))}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("mousedown",this.clickOutside)}toggle(){this.open||this.setDropdownPosition(),this.open=!this.open}sortFilteredOptions(e){const t=(null!=e?e:this.options).reduce((e,t)=>{const i=t.type||"Other";return e[i]?e[i].options.push(t):e[i]={type:i,options:[t]},e},{});return Object.values(t)}optionsChanged(){this.filteredAvailableOptions=this.sortFilteredOptions()}setDropdownPosition(){let e=this.position;if(this.autoPosition){let t=this.assignedSlot?this.assignedSlot.parentElement:this.parentElement;for(;t&&!t.classList.contains("content-wrapper");)t=t.parentElement;if(t){const i=t.getBoundingClientRect(),o=this.getBoundingClientRect(),n=i.top+i.height/2;e=o.top<n?Nt.BELOW:Nt.ABOVE}else{const t=this.getBoundingClientRect(),i=window.innerHeight,o=t.top,n=i-t.bottom;e=n<t.height&&o>n?Nt.ABOVE:Nt.BELOW}}e===Nt.ABOVE?(this.optionsElement.classList.add("position-above"),this.optionsElement.classList.remove("position-below")):e===Nt.BELOW&&(this.optionsElement.classList.add("position-below"),this.optionsElement.classList.remove("position-above"))}optionGetter(e){return e.value}getItemLabel(e){let t;return e?(t=e.label||e.value||"",this.valueFormatter?this.valueFormatter(t):t):""}isOptionDisabled(e){return e&&"string"!=typeof e&&e.disabled||!1}get getPlaceholder(){return`Search ${this.name}`.trim().concat("...")}isOptionSelected(e){return this.selectedOptions.includes(this.optionGetter(e))}selectCheckboxOne(e){const t=this.optionGetter(e);this.selectedOptions.includes(t)?(this.selectedOptions=[...this.selectedOptions],this.selectedOptions.splice(this.selectedOptions.indexOf(t),1)):this.selectedOptions=[...this.selectedOptions,t],this.$emit("selectionChange",this.selectedOptions)}setFilter(){const e=this.options.filter(e=>{var t;const i=e.description,o=null!==(t=e.label)&&void 0!==t?t:e.value;return(null==i?void 0:i.toLowerCase().includes(this.filterSearchValue.toLowerCase()))||o.toLowerCase().includes(this.filterSearchValue.toLowerCase())?e:void 0});this.filteredAvailableOptions=this.sortFilteredOptions(e)}changeHandler(e){e.preventDefault(),e.stopImmediatePropagation()}handleClickOutside(e){E(e,this)&&(this.open=!1)}}(0,C.Cg)([l.attr],zt.prototype,"name",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"auto-position"})],zt.prototype,"autoPosition",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],zt.prototype,"search",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],zt.prototype,"disabled",void 0),(0,C.Cg)([l.observable],zt.prototype,"defaultSlottedNodes",void 0),(0,C.Cg)([l.observable],zt.prototype,"valueFormatter",void 0),(0,C.Cg)([l.observable],zt.prototype,"filterSearchValue",void 0),(0,C.Cg)([l.observable],zt.prototype,"open",void 0),(0,C.Cg)([l.observable],zt.prototype,"options",void 0),(0,C.Cg)([l.observable],zt.prototype,"selectedOptions",void 0),(0,C.Cg)([l.observable],zt.prototype,"filteredAvailableOptions",void 0),(0,C.Cg)([l.observable],zt.prototype,"position",void 0),(0,C.Cg)([l.volatile],zt.prototype,"getPlaceholder",null);const Ut=zt.compose(Object.assign({baseName:"categorized-multiselect",template:_t,styles:Ft,shadowOptions:Ht},Pt)),Bt=(e,t)=>l.css`
811
+ `,Ht=void 0,Pt={};class zt extends a.FoundationElement{constructor(){super(...arguments),this.name="",this.autoPosition=!0,this.search=!0,this.disabled=!1,this.clickOutside=e=>this.handleClickOutside(e),this.open=!1,this.options=[],this.selectedOptions=[],this.position=Nt.BELOW}openChanged(e,t){var i,o;t?(document.addEventListener("mousedown",this.clickOutside),null===(i=this.optionsElement)||void 0===i||i.classList.add("visible")):(document.removeEventListener("mousedown",this.clickOutside),null===(o=this.optionsElement)||void 0===o||o.classList.remove("visible"))}connectedCallback(){var e;super.connectedCallback(),this.position===Nt.ABOVE&&(null===(e=this.optionsElement)||void 0===e||e.classList.add("position-above"))}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("mousedown",this.clickOutside)}toggle(){this.open||this.setDropdownPosition(),this.open=!this.open}sortFilteredOptions(e){const t=(null!=e?e:this.options).reduce((e,t)=>{const i=t.type||"Other";return e[i]?e[i].options.push(t):e[i]={type:i,options:[t]},e},{});return Object.values(t)}optionsChanged(){this.filteredAvailableOptions=this.sortFilteredOptions()}setDropdownPosition(){let e=this.position;if(this.autoPosition){let t=this.assignedSlot?this.assignedSlot.parentElement:this.parentElement;for(;t&&!t.classList.contains("content-wrapper");)t=t.parentElement;if(t){const i=t.getBoundingClientRect(),o=this.getBoundingClientRect(),n=i.top+i.height/2;e=o.top<n?Nt.BELOW:Nt.ABOVE}else{const t=this.getBoundingClientRect(),i=window.innerHeight,o=t.top,n=i-t.bottom;e=n<t.height&&o>n?Nt.ABOVE:Nt.BELOW}}e===Nt.ABOVE?(this.optionsElement.classList.add("position-above"),this.optionsElement.classList.remove("position-below")):e===Nt.BELOW&&(this.optionsElement.classList.add("position-below"),this.optionsElement.classList.remove("position-above"))}optionGetter(e){return e.value}getItemLabel(e){let t;return e?(t=e.label||e.value||"",this.valueFormatter?this.valueFormatter(t):t):""}isOptionDisabled(e){return e&&"string"!=typeof e&&e.disabled||!1}get getPlaceholder(){return`Search ${this.name}`.trim().concat("...")}isOptionSelected(e){return this.selectedOptions.includes(this.optionGetter(e))}selectCheckboxOne(e){const t=this.optionGetter(e);this.selectedOptions.includes(t)?(this.selectedOptions=[...this.selectedOptions],this.selectedOptions.splice(this.selectedOptions.indexOf(t),1)):this.selectedOptions=[...this.selectedOptions,t],this.$emit("selectionChange",this.selectedOptions)}setFilter(){const e=this.options.filter(e=>{var t;const i=e.description,o=null!==(t=e.label)&&void 0!==t?t:e.value;return(null==i?void 0:i.toLowerCase().includes(this.filterSearchValue.toLowerCase()))||o.toLowerCase().includes(this.filterSearchValue.toLowerCase())?e:void 0});this.filteredAvailableOptions=this.sortFilteredOptions(e)}changeHandler(e){e.preventDefault(),e.stopImmediatePropagation()}handleClickOutside(e){E(e,this)&&(this.open=!1)}}(0,C.Cg)([l.attr],zt.prototype,"name",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"auto-position"})],zt.prototype,"autoPosition",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],zt.prototype,"search",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],zt.prototype,"disabled",void 0),(0,C.Cg)([l.observable],zt.prototype,"defaultSlottedNodes",void 0),(0,C.Cg)([l.observable],zt.prototype,"valueFormatter",void 0),(0,C.Cg)([l.observable],zt.prototype,"filterSearchValue",void 0),(0,C.Cg)([l.observable],zt.prototype,"open",void 0),(0,C.Cg)([l.observable],zt.prototype,"options",void 0),(0,C.Cg)([l.observable],zt.prototype,"selectedOptions",void 0),(0,C.Cg)([l.observable],zt.prototype,"filteredAvailableOptions",void 0),(0,C.Cg)([l.observable],zt.prototype,"position",void 0),(0,C.Cg)([l.volatile],zt.prototype,"getPlaceholder",null);const Ut=zt.compose(Object.assign({baseName:"categorized-multiselect",template:_t,styles:Ft,shadowOptions:Ht},Pt)),Wt=(e,t)=>l.css`
812
812
  ${(0,r.checkboxStyles)(e,t)}
813
- `,Wt=(e,t)=>(0,s.checkboxTemplate)(e,t);class Gt extends r.Checkbox{}const jt=void 0,Vt={checkedIndicator:'\n <svg\n aria-hidden="true"\n part="checked-indicator"\n class="checked-indicator"\n viewBox="0 0 20 20"\n xmlns="http://www.w3.org/2000/svg"\n >\n <path\n fill-rule="evenodd"\n clip-rule="evenodd"\n d="M8.143 12.6697L15.235 4.5L16.8 5.90363L8.23812 15.7667L3.80005 11.2556L5.27591 9.7555L8.143 12.6697Z"\n />\n </svg>\n ',indeterminateIndicator:'\n <div part="indeterminate-indicator" class="indeterminate-indicator"></div>\n '},Yt=Gt.compose(Object.assign({baseName:"checkbox",template:Wt,styles:Bt,shadowOptions:jt},Vt));var qt=i(62051),Kt=i.n(qt),Xt=i(40370),Qt=i(6884),Jt=i(96730),Zt=i(21281),ei=i(34193),ti=i(41119),ii=i(26347),oi=i(9033),ni=i(12066),ai=i(97156);class si extends((0,Xt.C)(s.FoundationElement)){constructor(){super(...arguments),this.withGridInit=!0,this.isSnapshot=!1,this.maxRows=Qt.OD.MAX_ROWS_250,this.maxView=Qt.OD.MAX_VIEW_1000,this.resourceName="",this.reverse=!1,this.rowId="ROW_REF",this.withTimestampFormatting=!0,this.requiresFullDataRefresh=!0,this.rowsSyncedWithStream=new Map,this.dataSubWasLoggedOff=!1,this.criteriaFromFilters=new Map,this.update=new ai.t(new Map)}criteriaChanged(e,t){const i=e!==(0,Jt.Q)(t,";");this.refetchIfInitializedAndChanged(i)}dataChanged(e){e&&(this.clearData(),this.reset())}requestChanged(e,t){const i=JSON.stringify(e)!==JSON.stringify(t);this.refetchIfInitializedAndChanged(i)}refetchIfInitializedAndChanged(e){this.datasource.initialized&&e&&(this.dataSub&&(this.dataSub.unsubscribe(),this.dataSub=void 0),this.fetchGenesisData(null))}set datasourceConfig(e){e&&Object.keys(e).forEach(t=>{void 0!==e[t]&&(this[t]=e[t])})}disconnectedCallback(){var e,t;super.disconnectedCallback(),this.clearData(),null===(e=this.dataSub)||void 0===e||e.unsubscribe(),null===(t=this.update)||void 0===t||t.unsubscribe(),delete this.dataSub,delete this.update,this.datasource.destroy(),delete this.datasource}reset(){this.requiresFullDataRefresh=!0,this.fetchGenesisData()}fetchGenesisData(){return(0,C.sH)(this,arguments,void 0,function*(e=!0){if(this.data)return void this.syncComponentData(this.data);const t=e||!this.datasource.initialized;t||(this.connect.dataLogoff(this.sourceRef),this.clearData());if(yield this.datasource.init(this.datasourceOptions(),t)){if(this.isSnapshot){const e=yield this.datasource.snapshotFiltered();return void this.syncComponentData(e)}Xe.debug(`requesting stream for ${this.resourceName}`),this.dataSub=this.datasource.stream.subscribe(e=>{e.DISCONNECTED&&this.handleError({message:`Genesis Datasource disconnected for ${this.resourceName}`,loggerType:"error"}),this.sourceRef=e.SOURCE_REF;const t=e.MESSAGE_TYPE;if(t&&t===Zt.Go.LOGOFF_ACK)this.dataSubWasLoggedOff=!0;else if(this.dataSubWasLoggedOff=!1,e.ROW){const t=(0,ei.d)(e);this.handleStreamUpdate(t)}else this.handleStreamUpdate(e)})}else this.handleError({message:`Genesis Datasource init failed for ${this.resourceName}`,loggerType:"error"})})}initDatasource(){return(0,C.sH)(this,void 0,void 0,function*(){yield this.datasource.init(this.datasourceOptions(),!0)})}datasourceOptions(){return{criteria:this.buildCriteria(),fields:this.fields,isSnapshot:this.isSnapshot,orderBy:this.orderBy,resourceName:this.resourceName,request:this.request,reverse:this.reverse,maxRows:this.maxRows,maxView:this.maxView}}handleStreamUpdate(e){if(!e)return;e.hasOwnProperty("REPLY")?this.applyRequestServerData(e):this.applyDataserverData(e)}applyRequestServerData(e){var t,i;if(!Array.isArray(e.REPLY)||!(null===(t=e.MESSAGE_TYPE)||void 0===t?void 0:t.startsWith("REP_")))return void this.handleError({message:"received invalid RequestServerResult",loggerType:"error",loggerArgs:[e]});if(this.requiresFullDataRefresh){"ROW_REF"!==this.rowId&&(null===(i=e.REPLY)||void 0===i||i.forEach(e=>{this.rowsSyncedWithStream.set(e[this.rowId],e)}));const t=this.rowsSyncedWithStream.size>0?Array.from(this.rowsSyncedWithStream.values()):e.REPLY;return void this.syncComponentData(t)}this.handleStreamInserts(e.REPLY);const o=Array.from(this.rowsSyncedWithStream.values()).filter(t=>!e.REPLY.includes(t));this.handleStreamDeletes(o)}applyDataserverData(e){var t,i,o,n;if(this.requiresFullDataRefresh){null===(t=e.inserts)||void 0===t||t.forEach(e=>{this.rowsSyncedWithStream.set(e[this.rowId],e)});const i=Array.from(this.rowsSyncedWithStream.values());return void this.syncComponentData(i)}(null===(i=e.inserts)||void 0===i?void 0:i.length)>0&&this.handleStreamInserts(e.inserts),(null===(o=e.deletes)||void 0===o?void 0:o.length)>0&&this.handleStreamDeletes(e.deletes),(null===(n=e.updates)||void 0===n?void 0:n.length)>0&&this.handleStreamUpdates(e.updates)}buildCriteria(){var e;const t=(null===(e=this.criteria)||void 0===e?void 0:e.split(";"))||[];return(0,Jt.Q)(t.join(" && "),";")}setFilter(e,t){this.criteriaFromFilters.set(e,t),this.update.next(this.criteriaFromFilters)}removeFilter(e){this.criteriaFromFilters.delete(e),this.update.next(this.criteriaFromFilters)}handleError(e={}){const{message:t,loggerType:i,loggerArgs:o=[]}=e;t&&Xe[i](t,...o)}getFieldMetadata(e){var t;return null===(t=this.datasource.fieldMetadata)||void 0===t?void 0:t.find(t=>t.name===e)}getDefaultLabelFormat(e,t){return t===ti.w.DATE||t===ti.w.DATETIME?(0,ni.Ey)(e,t===ti.w.DATETIME):e}}function ri(e,t){var i;const o=new W.b;o.withExpression((new B.K).withField(null!==(i=e.labelField)&&void 0!==i?i:e.valueField).withValue(t).withSerialiser(U.n.containsIgnoreCase).build()),e.baseCriteria?e.criteria=`${e.baseCriteria} && ${o.build()}`:e.criteria=o.build()}var li;(0,C.Cg)([ii.dm],si.prototype,"connect",void 0),(0,C.Cg)([oi.yW],si.prototype,"datasource",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],si.prototype,"withGridInit",void 0),(0,C.Cg)([l.attr],si.prototype,"criteria",void 0),(0,C.Cg)([l.observable],si.prototype,"data",void 0),(0,C.Cg)([l.attr],si.prototype,"fields",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],si.prototype,"isSnapshot",void 0),(0,C.Cg)([l.attr],si.prototype,"maxRows",void 0),(0,C.Cg)([l.attr],si.prototype,"maxView",void 0),(0,C.Cg)([l.attr],si.prototype,"orderBy",void 0),(0,C.Cg)([l.attr],si.prototype,"request",void 0),(0,C.Cg)([l.attr],si.prototype,"resourceName",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],si.prototype,"reverse",void 0),(0,C.Cg)([l.attr],si.prototype,"rowId",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"with-timestamp-formatting"})],si.prototype,"withTimestampFormatting",void 0);let di=li=class extends si{constructor(){super(...arguments),this.emptyDataLabel="No matching records",this.allowCustomOptions=!1,this.initalSelectedValueInitialized=!1,this.isSnapshot=!0,this.baseCriteria="",this.resizeObserverCallback=e=>{e.forEach(e=>{this.checkOverflow(e.target)})},this.selectChangeHandler=e=>{var t;const i=e.target.value,o=null===(t=this.options)||void 0===t?void 0:t.find(e=>String(e.label)===i);!o&&this.allowCustomOptions&&this.select instanceof r.Combobox?this.select.$emit("value-change",{label:i,value:i}):this.select.$emit("value-change",o)}}initialSelectedValueChanged(e,t){t&&t!==e&&(this.select&&this.getDisplayForValue(t)===String(this.select.value||"")||(this.initalSelectedValueInitialized=!1,this.clearData(),this.fetchData()))}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){var t,i;e.connectedCallback.call(this),this.baseCriteria=this.criteria,this.fields=this.labelField?null===(t=this.valueField)||void 0===t?void 0:t.concat(" ",this.labelField):this.valueField,this.select=this.parentElement,this.optionElement=null!==(i=this.optionElement)&&void 0!==i?i:`${O(this.select)}-option`,this.select.addEventListener("change",this.selectChangeHandler),this.resizeObserver=new ResizeObserver(this.resizeObserverCallback),this.fetchData(),this.valueField||Xe.warn('Specify field for values in options (e.g value-field="VALUE") and optionally field for label (e.g label-field="NAME")')})}disconnectedCallback(){super.disconnectedCallback(),this.resizeObserver.disconnect(),this.select.removeEventListener("change",this.selectChangeHandler)}fetchData(){this.select&&this.valueField&&(this.resourceName&&this.connect.isConnected||this.data)&&(this.select instanceof r.Combobox&&this.select.async&&this.initialSelectedValue?this.asyncModeIntialization():this.fetchGenesisData())}asyncModeIntialization(){return(0,C.sH)(this,void 0,void 0,function*(){(yield this.datasource.init(this.datasourceOptions(),!0))?ri(this,this.initialSelectedValue):this.handleError({message:`Genesis Datasource async mode initialization failed for ${this.resourceName}`,loggerType:"error"})})}clearData(){this.select&&(Array.from(this.select.children).forEach(e=>{e instanceof li||this.select.removeChild(e)}),this.select.value="",this.select.initialValue="")}checkOverflow(e){const t=e.shadowRoot.querySelector(".content");t&&(t.scrollWidth>t.clientWidth?e.setAttribute("title",e.textContent):e.removeAttribute("title"))}syncComponentData(e){const t=null!=e?e:Array.from(this.rowsSyncedWithStream.values());if(t.length>0){this.options=t.map(e=>{var t;return{value:e[this.valueField],label:this.labelRowFormatter?this.labelRowFormatter(e):this.labelFormatter?this.labelFormatter(e[this.labelField]):this.getDefaultLabelFormat(e[this.labelField],null===(t=this.getFieldMetadata(this.labelField))||void 0===t?void 0:t.type)}});if(this.options.map(({value:e,label:t})=>{const i=document.createElement(this.optionElement);return i.textContent=t||e,i.value=e,i}).forEach(e=>{this.select.appendChild(e),this.resizeObserver.observe(e)}),!this.initalSelectedValueInitialized||this.select instanceof r.Combobox&&!this.select.async){this.resetCombobox();const e=this.getInitialLabel();l.DOM.queueUpdate(()=>{this.select.value=String(e),this.select instanceof r.Combobox&&this.select.async&&this.selectChangeHandler({target:{value:e}})}),this.initalSelectedValueInitialized=!0}}else{this.allowCustomOptions&&this.initialSelectedValue&&(!this.initalSelectedValueInitialized||this.select instanceof r.Combobox&&!this.select.async)&&(this.resetCombobox(),l.DOM.queueUpdate(()=>{this.select.value=String(this.initialSelectedValue)}),this.initalSelectedValueInitialized=!0);const e=document.createElement(this.optionElement);e.textContent=this.emptyDataLabel,e.value="",e.disabled=!0,this.select.appendChild(e)}}getInitialLabel(){return this.getDisplayForValue(this.initialSelectedValue)}getDisplayForValue(e){var t;if(null==e||0!==e&&!e)return"";const i=null===(t=this.options)||void 0===t?void 0:t.find(t=>t.value===e);return this.allowCustomOptions&&this.select instanceof r.Combobox?String(i?i.label:e):i?String(i.label):""}resetCombobox(){this.select&&this.select instanceof r.Combobox&&this.select.resetCombobox()}handleStreamInserts(e){Xe.debug("handleStreamInserts - Method not implemented.")}handleStreamDeletes(e){Xe.debug("handleStreamDeletes - Method not implemented.")}handleStreamUpdates(e){Xe.debug("handleStreamUpdates - Method not implemented.")}};(0,C.Cg)([(0,l.attr)({attribute:"label-field"})],di.prototype,"labelField",void 0),(0,C.Cg)([(0,l.attr)({attribute:"option-element"})],di.prototype,"optionElement",void 0),(0,C.Cg)([(0,l.attr)({attribute:"value-field"})],di.prototype,"valueField",void 0),(0,C.Cg)([(0,l.attr)({attribute:"empty-data-label"})],di.prototype,"emptyDataLabel",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"allow-custom-options"})],di.prototype,"allowCustomOptions",void 0),(0,C.Cg)([l.observable],di.prototype,"labelFormatter",void 0),(0,C.Cg)([l.observable],di.prototype,"labelRowFormatter",void 0),(0,C.Cg)([l.observable],di.prototype,"initialSelectedValue",void 0),di=li=(0,C.Cg)([(0,l.customElement)({name:"options-datasource"})],di);const ci=(e,t)=>l.css`
813
+ `,Gt=(e,t)=>(0,a.checkboxTemplate)(e,t);class Bt extends r.Checkbox{}const Vt=void 0,jt={checkedIndicator:'\n <svg\n aria-hidden="true"\n part="checked-indicator"\n class="checked-indicator"\n viewBox="0 0 20 20"\n xmlns="http://www.w3.org/2000/svg"\n >\n <path\n fill-rule="evenodd"\n clip-rule="evenodd"\n d="M8.143 12.6697L15.235 4.5L16.8 5.90363L8.23812 15.7667L3.80005 11.2556L5.27591 9.7555L8.143 12.6697Z"\n />\n </svg>\n ',indeterminateIndicator:'\n <div part="indeterminate-indicator" class="indeterminate-indicator"></div>\n '},Yt=Bt.compose(Object.assign({baseName:"checkbox",template:Gt,styles:Wt,shadowOptions:Vt},jt));var qt=i(62051),Kt=i.n(qt),Xt=i(40370),Qt=i(6884),Jt=i(96730),Zt=i(21281),ei=i(34193),ti=i(41119),ii=i(26347),oi=i(9033),ni=i(12066),si=i(97156);class ai extends((0,Xt.C)(a.FoundationElement)){constructor(){super(...arguments),this.withGridInit=!0,this.isSnapshot=!1,this.maxRows=Qt.OD.MAX_ROWS_250,this.maxView=Qt.OD.MAX_VIEW_1000,this.resourceName="",this.reverse=!1,this.rowId="ROW_REF",this.withTimestampFormatting=!0,this.requiresFullDataRefresh=!0,this.rowsSyncedWithStream=new Map,this.dataSubWasLoggedOff=!1,this.criteriaFromFilters=new Map,this.update=new si.t(new Map)}criteriaChanged(e,t){const i=e!==(0,Jt.Q)(t,";");this.refetchIfInitializedAndChanged(i)}dataChanged(e){e&&(this.clearData(),this.reset())}requestChanged(e,t){const i=JSON.stringify(e)!==JSON.stringify(t);this.refetchIfInitializedAndChanged(i)}refetchIfInitializedAndChanged(e){this.datasource.initialized&&e&&(this.dataSub&&(this.dataSub.unsubscribe(),this.dataSub=void 0),this.fetchGenesisData(null))}set datasourceConfig(e){e&&Object.keys(e).forEach(t=>{void 0!==e[t]&&(this[t]=e[t])})}disconnectedCallback(){var e,t;super.disconnectedCallback(),this.clearData(),null===(e=this.dataSub)||void 0===e||e.unsubscribe(),null===(t=this.update)||void 0===t||t.unsubscribe(),delete this.dataSub,delete this.update,this.datasource.destroy(),delete this.datasource}reset(){this.requiresFullDataRefresh=!0,this.fetchGenesisData()}fetchGenesisData(){return(0,C.sH)(this,arguments,void 0,function*(e=!0){if(this.data)return void this.syncComponentData(this.data);const t=e||!this.datasource.initialized;t||(this.connect.dataLogoff(this.sourceRef),this.clearData());if(yield this.datasource.init(this.datasourceOptions(),t)){if(this.isSnapshot){const e=yield this.datasource.snapshotFiltered();return void this.syncComponentData(e)}Xe.debug(`requesting stream for ${this.resourceName}`),this.dataSub=this.datasource.stream.subscribe(e=>{e.DISCONNECTED&&this.handleError({message:`Genesis Datasource disconnected for ${this.resourceName}`,loggerType:"error"}),this.sourceRef=e.SOURCE_REF;const t=e.MESSAGE_TYPE;if(t&&t===Zt.Go.LOGOFF_ACK)this.dataSubWasLoggedOff=!0;else if(this.dataSubWasLoggedOff=!1,e.ROW){const t=(0,ei.d)(e);this.handleStreamUpdate(t)}else this.handleStreamUpdate(e)})}else this.handleError({message:`Genesis Datasource init failed for ${this.resourceName}`,loggerType:"error"})})}initDatasource(){return(0,C.sH)(this,void 0,void 0,function*(){yield this.datasource.init(this.datasourceOptions(),!0)})}datasourceOptions(){return{criteria:this.buildCriteria(),fields:this.fields,isSnapshot:this.isSnapshot,orderBy:this.orderBy,resourceName:this.resourceName,request:this.request,reverse:this.reverse,maxRows:this.maxRows,maxView:this.maxView}}handleStreamUpdate(e){if(!e)return;e.hasOwnProperty("REPLY")?this.applyRequestServerData(e):this.applyDataserverData(e)}applyRequestServerData(e){var t,i;if(!Array.isArray(e.REPLY)||!(null===(t=e.MESSAGE_TYPE)||void 0===t?void 0:t.startsWith("REP_")))return void this.handleError({message:"received invalid RequestServerResult",loggerType:"error",loggerArgs:[e]});if(this.requiresFullDataRefresh){"ROW_REF"!==this.rowId&&(null===(i=e.REPLY)||void 0===i||i.forEach(e=>{this.rowsSyncedWithStream.set(e[this.rowId],e)}));const t=this.rowsSyncedWithStream.size>0?Array.from(this.rowsSyncedWithStream.values()):e.REPLY;return void this.syncComponentData(t)}this.handleStreamInserts(e.REPLY);const o=Array.from(this.rowsSyncedWithStream.values()).filter(t=>!e.REPLY.includes(t));this.handleStreamDeletes(o)}applyDataserverData(e){var t,i,o,n;if(this.requiresFullDataRefresh){null===(t=e.inserts)||void 0===t||t.forEach(e=>{this.rowsSyncedWithStream.set(e[this.rowId],e)});const i=Array.from(this.rowsSyncedWithStream.values());return void this.syncComponentData(i)}(null===(i=e.inserts)||void 0===i?void 0:i.length)>0&&this.handleStreamInserts(e.inserts),(null===(o=e.deletes)||void 0===o?void 0:o.length)>0&&this.handleStreamDeletes(e.deletes),(null===(n=e.updates)||void 0===n?void 0:n.length)>0&&this.handleStreamUpdates(e.updates)}buildCriteria(){var e;const t=(null===(e=this.criteria)||void 0===e?void 0:e.split(";"))||[];return(0,Jt.Q)(t.join(" && "),";")}setFilter(e,t){this.criteriaFromFilters.set(e,t),this.update.next(this.criteriaFromFilters)}removeFilter(e){this.criteriaFromFilters.delete(e),this.update.next(this.criteriaFromFilters)}handleError(e={}){const{message:t,loggerType:i,loggerArgs:o=[]}=e;t&&Xe[i](t,...o)}getFieldMetadata(e){var t;return null===(t=this.datasource.fieldMetadata)||void 0===t?void 0:t.find(t=>t.name===e)}getDefaultLabelFormat(e,t){return t===ti.w.DATE||t===ti.w.DATETIME?(0,ni.Ey)(e,t===ti.w.DATETIME):e}}function ri(e,t){var i;const o=new G.b;o.withExpression((new W.K).withField(null!==(i=e.labelField)&&void 0!==i?i:e.valueField).withValue(t).withSerialiser(U.n.containsIgnoreCase).build()),e.baseCriteria?e.criteria=`${e.baseCriteria} && ${o.build()}`:e.criteria=o.build()}var li;(0,C.Cg)([ii.dm],ai.prototype,"connect",void 0),(0,C.Cg)([oi.yW],ai.prototype,"datasource",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ai.prototype,"withGridInit",void 0),(0,C.Cg)([l.attr],ai.prototype,"criteria",void 0),(0,C.Cg)([l.observable],ai.prototype,"data",void 0),(0,C.Cg)([l.attr],ai.prototype,"fields",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ai.prototype,"isSnapshot",void 0),(0,C.Cg)([l.attr],ai.prototype,"maxRows",void 0),(0,C.Cg)([l.attr],ai.prototype,"maxView",void 0),(0,C.Cg)([l.attr],ai.prototype,"orderBy",void 0),(0,C.Cg)([l.attr],ai.prototype,"request",void 0),(0,C.Cg)([l.attr],ai.prototype,"resourceName",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ai.prototype,"reverse",void 0),(0,C.Cg)([l.attr],ai.prototype,"rowId",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"with-timestamp-formatting"})],ai.prototype,"withTimestampFormatting",void 0);let di=li=class extends ai{constructor(){super(...arguments),this.emptyDataLabel="No matching records",this.allowCustomOptions=!1,this.initalSelectedValueInitialized=!1,this.isSnapshot=!0,this.baseCriteria="",this.resizeObserverCallback=e=>{e.forEach(e=>{this.checkOverflow(e.target)})},this.selectChangeHandler=e=>{var t;const i=e.target.value,o=null===(t=this.options)||void 0===t?void 0:t.find(e=>String(e.label)===i);!o&&this.allowCustomOptions&&this.select instanceof r.Combobox?this.select.$emit("value-change",{label:i,value:i}):this.select.$emit("value-change",o)}}initialSelectedValueChanged(e,t){t&&t!==e&&(this.select&&this.getDisplayForValue(t)===String(this.select.value||"")||(this.initalSelectedValueInitialized=!1,this.clearData(),this.fetchData()))}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){var t,i;e.connectedCallback.call(this),this.baseCriteria=this.criteria,this.fields=this.labelField?null===(t=this.valueField)||void 0===t?void 0:t.concat(" ",this.labelField):this.valueField,this.select=this.parentElement,this.optionElement=null!==(i=this.optionElement)&&void 0!==i?i:`${O(this.select)}-option`,this.select.addEventListener("change",this.selectChangeHandler),this.resizeObserver=new ResizeObserver(this.resizeObserverCallback),this.fetchData(),this.valueField||Xe.warn('Specify field for values in options (e.g value-field="VALUE") and optionally field for label (e.g label-field="NAME")')})}disconnectedCallback(){super.disconnectedCallback(),this.resizeObserver.disconnect(),this.select.removeEventListener("change",this.selectChangeHandler)}fetchData(){this.select&&this.valueField&&(this.resourceName&&this.connect.isConnected||this.data)&&(this.select instanceof r.Combobox&&this.select.async&&this.initialSelectedValue?this.asyncModeIntialization():this.fetchGenesisData())}asyncModeIntialization(){return(0,C.sH)(this,void 0,void 0,function*(){(yield this.datasource.init(this.datasourceOptions(),!0))?ri(this,this.initialSelectedValue):this.handleError({message:`Genesis Datasource async mode initialization failed for ${this.resourceName}`,loggerType:"error"})})}clearData(){this.select&&(Array.from(this.select.children).forEach(e=>{e instanceof li||this.select.removeChild(e)}),this.select.value="",this.select.initialValue="")}checkOverflow(e){const t=e.shadowRoot.querySelector(".content");t&&(t.scrollWidth>t.clientWidth?e.setAttribute("title",e.textContent):e.removeAttribute("title"))}syncComponentData(e){const t=null!=e?e:Array.from(this.rowsSyncedWithStream.values());if(t.length>0){this.options=t.map(e=>{var t;return{value:e[this.valueField],label:this.labelRowFormatter?this.labelRowFormatter(e):this.labelFormatter?this.labelFormatter(e[this.labelField]):this.getDefaultLabelFormat(e[this.labelField],null===(t=this.getFieldMetadata(this.labelField))||void 0===t?void 0:t.type)}});if(this.options.map(({value:e,label:t})=>{const i=document.createElement(this.optionElement);return i.textContent=t||e,i.value=e,i}).forEach(e=>{this.select.appendChild(e),this.resizeObserver.observe(e)}),!this.initalSelectedValueInitialized||this.select instanceof r.Combobox&&!this.select.async){this.resetCombobox();const e=this.getInitialLabel();l.DOM.queueUpdate(()=>{this.select.value=String(e),this.select instanceof r.Combobox&&this.select.async&&this.selectChangeHandler({target:{value:e}})}),this.initalSelectedValueInitialized=!0}}else{this.allowCustomOptions&&this.initialSelectedValue&&(!this.initalSelectedValueInitialized||this.select instanceof r.Combobox&&!this.select.async)&&(this.resetCombobox(),l.DOM.queueUpdate(()=>{this.select.value=String(this.initialSelectedValue)}),this.initalSelectedValueInitialized=!0);const e=document.createElement(this.optionElement);e.textContent=this.emptyDataLabel,e.value="",e.disabled=!0,this.select.appendChild(e)}}getInitialLabel(){return this.getDisplayForValue(this.initialSelectedValue)}getDisplayForValue(e){var t;if(null==e||0!==e&&!e)return"";const i=null===(t=this.options)||void 0===t?void 0:t.find(t=>t.value===e);return this.allowCustomOptions&&this.select instanceof r.Combobox?String(i?i.label:e):i?String(i.label):""}resetCombobox(){this.select&&this.select instanceof r.Combobox&&this.select.resetCombobox()}handleStreamInserts(e){Xe.debug("handleStreamInserts - Method not implemented.")}handleStreamDeletes(e){Xe.debug("handleStreamDeletes - Method not implemented.")}handleStreamUpdates(e){Xe.debug("handleStreamUpdates - Method not implemented.")}};(0,C.Cg)([(0,l.attr)({attribute:"label-field"})],di.prototype,"labelField",void 0),(0,C.Cg)([(0,l.attr)({attribute:"option-element"})],di.prototype,"optionElement",void 0),(0,C.Cg)([(0,l.attr)({attribute:"value-field"})],di.prototype,"valueField",void 0),(0,C.Cg)([(0,l.attr)({attribute:"empty-data-label"})],di.prototype,"emptyDataLabel",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"allow-custom-options"})],di.prototype,"allowCustomOptions",void 0),(0,C.Cg)([l.observable],di.prototype,"labelFormatter",void 0),(0,C.Cg)([l.observable],di.prototype,"labelRowFormatter",void 0),(0,C.Cg)([l.observable],di.prototype,"initialSelectedValue",void 0),di=li=(0,C.Cg)([(0,l.customElement)({name:"options-datasource"})],di);const ci=(e,t)=>l.css`
814
814
  .combo-box-indicator {
815
815
  transition-property: transform;
816
816
  transition-duration: 0.2s;
@@ -832,7 +832,7 @@
832
832
  @keydown="${(e,t)=>e.keydownHandler(t.event)}"
833
833
  >
834
834
  <div class="control" part="control">
835
- ${(0,s.startSlotTemplate)(e,t)}
835
+ ${(0,a.startSlotTemplate)(e,t)}
836
836
  <slot name="control">
837
837
  <input
838
838
  aria-activedescendant="${e=>e.activeDescendant}"
@@ -859,7 +859,7 @@
859
859
  <slot name="indicator">${t.indicator||""}</slot>
860
860
  </div>
861
861
  </slot>
862
- ${(0,s.endSlotTemplate)(e,t)}
862
+ ${(0,a.endSlotTemplate)(e,t)}
863
863
  </div>
864
864
  <div
865
865
  class="listbox"
@@ -872,11 +872,11 @@
872
872
  >
873
873
  <slot
874
874
  ${(0,l.ref)("slottedDatasource")}
875
- ${(0,l.slotted)({filter:s.Listbox.slottedOptionFilter,flatten:!0,property:"slottedOptions"})}
875
+ ${(0,l.slotted)({filter:a.Listbox.slottedOptionFilter,flatten:!0,property:"slottedOptions"})}
876
876
  ></slot>
877
877
  </div>
878
878
  </template>
879
- `;var hi,pi;class mi extends r.Combobox{constructor(){super(...arguments),hi.set(this,void 0),pi.set(this,!1),this.needManualChangeEventDispatch=!1,this.async=!1,this.debounce=500,this.caseSensitive=!1,this.ignoreInputClick=!1,this.filterMode="startsWith",this.scrollToSelectedWhenOpening=!1,this.scrollToSelectedWhenOpeningOptions={behavior:"auto",block:"nearest"},this.scrollWhenSelectionChanges=!1,this.scrollWhenSelectionChangesOptions={behavior:"auto",block:"center"},this.resetCombobox=()=>{this.selectedOptions=[],this.selectedIndex=-1,this.value="",this.control.value="",this.filter="",this.filterOptions()}}get activeDescendant(){var e,t;if(this.selectedOptions&&0!==this.selectedOptions.length)return this.ariaActiveDescendant=null===(e=this.selectedOptions[0])||void 0===e?void 0:e.id,null===(t=this.selectedOptions[0])||void 0===t?void 0:t.id}debounceChanged(e,t){this.debouncedInputHandler=Kt()(this.asyncSetFilter,t)}openChanged(){super.openChanged(),this.open?this.scrollToSelectedWhenOpening&&setTimeout(()=>{const e=this.options[this.selectedIndex];null==e||e.scrollIntoView(this.scrollToSelectedWhenOpeningOptions)},500):(this.manuallyDispatchChangeEvent(),this.filter="",this.filterOptions())}get value(){return l.Observable.track(this,"value"),this._ourValue}set value(e){var t,i,o;if(void 0===e)return;const n=`${this._ourValue}`;if(this.$fastController.isConnected&&this.options){const n=this.caseSensitive?t=>t.text===e:t=>t.text.toLowerCase()===String(e).toLowerCase(),a=this.options?this.options.findIndex(n):-1,s=null===(t=this.options[this.selectedIndex])||void 0===t?void 0:t.text,r=null===(i=this.options[a])||void 0===i?void 0:i.text;this.selectedIndex=r&&r!==s?a:this.selectedIndex,e&&""!==e.trim()&&-1===a&&(e=(null===(o=this.firstSelectedOption)||void 0===o?void 0:o.text)||e)}n!==e&&(this._ourValue=e,super.valueChanged(n,e),l.Observable.notify(this,"value"))}slottedOptionsChanged(e,t){const i=!!this.async;super.slottedOptionsChanged(e,t),this.updateValue(i)}filterOptions(){this.autocomplete&&this.autocomplete!==s.ComboboxAutocomplete.none||(this.filter="");const e=this.filter,t=this.caseSensitive?e:e.toLowerCase();this.filteredOptions=this._options.filter(e=>{const i=this.caseSensitive?e.text:e.text.toLowerCase();return"contains"===this.filterMode?i.includes(t):i.startsWith(t)}),this.isAutocompleteList&&(this.filteredOptions.length||t||(this.filteredOptions=this._options),this._options.forEach(e=>e.hidden=!this.filteredOptions.includes(e)))}clickHandler(e){if(!this.disabled)if(E(e,this))this.open=!1;else{if(k(e,this.indicator))return this.open=!this.open,void(this.open&&this.control.focus());if(!this.ignoreInputClick||!k(e,this.control))return super.clickHandler(e)}}keydownHandler(e){const t=e.key;if(e.ctrlKey||e.shiftKey)return!0;switch(t){case"Enter":if((0,C.GG)(this,pi,this.open,"f"),!this.open)return this.open=!0,!0;break;case"ArrowDown":case"ArrowUp":if(!this.open)return this.open=!0,!0;if(this.scrollWhenSelectionChanges){const e=this.options[this.selectedIndex];null==e||e.scrollIntoView(this.scrollWhenSelectionChangesOptions)}break;case"Escape":if(this.control.value!==this.currentValue)return this.filter="",this.filterOptions(),this.control.value=this.currentValue,this.selectItemByValue(this.currentValue),void(this.open=!1);if(!this.open)return!0}const i=super.keydownHandler(e);return"Enter"!==t?i:void 0}keyupHandler(e){var t;const i=e.key;if(e.ctrlKey||e.shiftKey)return!0;switch(i){case"Enter":return!(0,C.gn)(this,pi,"f");case"ArrowDown":case"ArrowUp":this.open&&this.firstSelectedOption&&this.autocomplete===s.ComboboxAutocomplete.both&&(this.needManualChangeEventDispatch=!0,this.currentValue=null===(t=this.firstSelectedOption)||void 0===t?void 0:t.value);break;case"Home":case"End":return;case"Backspace":case"Delete":const i=super.keyupHandler(e);return this.selectItemByValue(this.control.value),i}return super.keyupHandler(e)}get indicator(){return(0,C.gn)(this,hi,"f")||(0,C.GG)(this,hi,this.shadowRoot.querySelector('[part="indicator"]'),"f"),(0,C.gn)(this,hi,"f")}selectItemByValue(e){var t,i,o;this.selectedIndex=null!==(i=null===(t=this.options)||void 0===t?void 0:t.findIndex(t=>t.text===e))&&void 0!==i?i:-1,null===(o=this.options)||void 0===o||o.forEach((e,t)=>e.selected=t===this.selectedIndex)}inputHandler(e){this.async?this.debouncedInputHandler():super.inputHandler(e)}asyncSetFilter(){const e=this.control.value,t=this.slottedDatasource.assignedNodes().filter(e=>e instanceof di);t.length>0?(ri(t[0],this.control.value),l.DOM.queueUpdate(()=>{this.control.value=e})):Xe.warn("Options-datasource is not connected. Please add a datasource to use this functionality.")}manuallyDispatchChangeEvent(){this.needManualChangeEventDispatch&&this.firstSelectedOption&&this.autocomplete===s.ComboboxAutocomplete.both&&(this.dispatchEvent(new Event("change",{bubbles:!0})),this.needManualChangeEventDispatch=!1)}}hi=new WeakMap,pi=new WeakMap,(0,C.Cg)([l.observable],mi.prototype,"activeDescendant",null),(0,C.Cg)([l.observable],mi.prototype,"slottedDatasource",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],mi.prototype,"async",void 0),(0,C.Cg)([l.attr],mi.prototype,"debounce",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"case-sensitive"})],mi.prototype,"caseSensitive",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"ignore-input-click"})],mi.prototype,"ignoreInputClick",void 0),(0,C.Cg)([(0,l.attr)({attribute:"filter-mode"})],mi.prototype,"filterMode",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"scroll-to-selected-when-opening"})],mi.prototype,"scrollToSelectedWhenOpening",void 0),(0,C.Cg)([l.observable],mi.prototype,"scrollToSelectedWhenOpeningOptions",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"scroll-when-selection-changes"})],mi.prototype,"scrollWhenSelectionChanges",void 0),(0,C.Cg)([l.observable],mi.prototype,"scrollWhenSelectionChangesOptions",void 0);const vi={delegatesFocus:!0,mode:"open"},gi={indicator:'\n <svg\n class="combo-box-indicator"\n part="combo-box-indicator"\n viewBox="0 0 12 7"\n xmlns="http://www.w3.org/2000/svg"\n >\n <path\n d="M11.85.65c.2.2.2.5 0 .7L6.4 6.84a.55.55 0 01-.78 0L.14 1.35a.5.5 0 11.71-.7L6 5.8 11.15.65c.2-.2.5-.2.7 0z"\n />\n </svg>\n '},fi=mi.compose(Object.assign({baseName:"combobox",template:ui,styles:ci,shadowOptions:vi},gi));var bi=i(98316);const yi=(e,t)=>l.css`
879
+ `;var hi,pi;class mi extends r.Combobox{constructor(){super(...arguments),hi.set(this,void 0),pi.set(this,!1),this.needManualChangeEventDispatch=!1,this.async=!1,this.debounce=500,this.caseSensitive=!1,this.ignoreInputClick=!1,this.filterMode="startsWith",this.scrollToSelectedWhenOpening=!1,this.scrollToSelectedWhenOpeningOptions={behavior:"auto",block:"nearest"},this.scrollWhenSelectionChanges=!1,this.scrollWhenSelectionChangesOptions={behavior:"auto",block:"center"},this.resetCombobox=()=>{this.selectedOptions=[],this.selectedIndex=-1,this.value="",this.control.value="",this.filter="",this.filterOptions()}}get activeDescendant(){var e,t;if(this.selectedOptions&&0!==this.selectedOptions.length)return this.ariaActiveDescendant=null===(e=this.selectedOptions[0])||void 0===e?void 0:e.id,null===(t=this.selectedOptions[0])||void 0===t?void 0:t.id}debounceChanged(e,t){this.debouncedInputHandler=Kt()(this.asyncSetFilter,t)}openChanged(){super.openChanged(),this.open?this.scrollToSelectedWhenOpening&&setTimeout(()=>{const e=this.options[this.selectedIndex];null==e||e.scrollIntoView(this.scrollToSelectedWhenOpeningOptions)},500):(this.manuallyDispatchChangeEvent(),this.filter="",this.filterOptions())}get value(){return l.Observable.track(this,"value"),this._ourValue}set value(e){var t,i,o;if(void 0===e)return;const n=`${this._ourValue}`;if(this.$fastController.isConnected&&this.options){const n=this.caseSensitive?t=>t.text===e:t=>t.text.toLowerCase()===String(e).toLowerCase(),s=this.options?this.options.findIndex(n):-1,a=null===(t=this.options[this.selectedIndex])||void 0===t?void 0:t.text,r=null===(i=this.options[s])||void 0===i?void 0:i.text;this.selectedIndex=r&&r!==a?s:this.selectedIndex,e&&""!==e.trim()&&-1===s&&(e=(null===(o=this.firstSelectedOption)||void 0===o?void 0:o.text)||e)}n!==e&&(this._ourValue=e,super.valueChanged(n,e),l.Observable.notify(this,"value"))}slottedOptionsChanged(e,t){const i=!!this.async;super.slottedOptionsChanged(e,t),this.updateValue(i)}filterOptions(){this.autocomplete&&this.autocomplete!==a.ComboboxAutocomplete.none||(this.filter="");const e=this.filter,t=this.caseSensitive?e:e.toLowerCase();this.filteredOptions=this._options.filter(e=>{const i=this.caseSensitive?e.text:e.text.toLowerCase();return"contains"===this.filterMode?i.includes(t):i.startsWith(t)}),this.isAutocompleteList&&(this.filteredOptions.length||t||(this.filteredOptions=this._options),this._options.forEach(e=>e.hidden=!this.filteredOptions.includes(e)))}clickHandler(e){if(!this.disabled)if(E(e,this))this.open=!1;else{if(k(e,this.indicator))return this.open=!this.open,void(this.open&&this.control.focus());if(!this.ignoreInputClick||!k(e,this.control))return super.clickHandler(e)}}keydownHandler(e){const t=e.key;if(e.ctrlKey||e.shiftKey)return!0;switch(t){case"Enter":if((0,C.GG)(this,pi,this.open,"f"),!this.open)return this.open=!0,!0;break;case"ArrowDown":case"ArrowUp":if(!this.open)return this.open=!0,!0;if(this.scrollWhenSelectionChanges){const e=this.options[this.selectedIndex];null==e||e.scrollIntoView(this.scrollWhenSelectionChangesOptions)}break;case"Escape":if(this.control.value!==this.currentValue)return this.filter="",this.filterOptions(),this.control.value=this.currentValue,this.selectItemByValue(this.currentValue),void(this.open=!1);if(!this.open)return!0}const i=super.keydownHandler(e);return"Enter"!==t?i:void 0}keyupHandler(e){var t;const i=e.key;if(e.ctrlKey||e.shiftKey)return!0;switch(i){case"Enter":return!(0,C.gn)(this,pi,"f");case"ArrowDown":case"ArrowUp":this.open&&this.firstSelectedOption&&this.autocomplete===a.ComboboxAutocomplete.both&&(this.needManualChangeEventDispatch=!0,this.currentValue=null===(t=this.firstSelectedOption)||void 0===t?void 0:t.value);break;case"Home":case"End":return;case"Backspace":case"Delete":const i=super.keyupHandler(e);return this.selectItemByValue(this.control.value),i}return super.keyupHandler(e)}get indicator(){return(0,C.gn)(this,hi,"f")||(0,C.GG)(this,hi,this.shadowRoot.querySelector('[part="indicator"]'),"f"),(0,C.gn)(this,hi,"f")}selectItemByValue(e){var t,i,o;this.selectedIndex=null!==(i=null===(t=this.options)||void 0===t?void 0:t.findIndex(t=>t.text===e))&&void 0!==i?i:-1,null===(o=this.options)||void 0===o||o.forEach((e,t)=>e.selected=t===this.selectedIndex)}inputHandler(e){this.async?this.debouncedInputHandler():super.inputHandler(e)}asyncSetFilter(){const e=this.control.value,t=this.slottedDatasource.assignedNodes().filter(e=>e instanceof di);t.length>0?(ri(t[0],this.control.value),l.DOM.queueUpdate(()=>{this.control.value=e})):Xe.warn("Options-datasource is not connected. Please add a datasource to use this functionality.")}manuallyDispatchChangeEvent(){this.needManualChangeEventDispatch&&this.firstSelectedOption&&this.autocomplete===a.ComboboxAutocomplete.both&&(this.dispatchEvent(new Event("change",{bubbles:!0})),this.needManualChangeEventDispatch=!1)}}hi=new WeakMap,pi=new WeakMap,(0,C.Cg)([l.observable],mi.prototype,"activeDescendant",null),(0,C.Cg)([l.observable],mi.prototype,"slottedDatasource",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],mi.prototype,"async",void 0),(0,C.Cg)([l.attr],mi.prototype,"debounce",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"case-sensitive"})],mi.prototype,"caseSensitive",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"ignore-input-click"})],mi.prototype,"ignoreInputClick",void 0),(0,C.Cg)([(0,l.attr)({attribute:"filter-mode"})],mi.prototype,"filterMode",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"scroll-to-selected-when-opening"})],mi.prototype,"scrollToSelectedWhenOpening",void 0),(0,C.Cg)([l.observable],mi.prototype,"scrollToSelectedWhenOpeningOptions",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"scroll-when-selection-changes"})],mi.prototype,"scrollWhenSelectionChanges",void 0),(0,C.Cg)([l.observable],mi.prototype,"scrollWhenSelectionChangesOptions",void 0);const gi={delegatesFocus:!0,mode:"open"},vi={indicator:'\n <svg\n class="combo-box-indicator"\n part="combo-box-indicator"\n viewBox="0 0 12 7"\n xmlns="http://www.w3.org/2000/svg"\n >\n <path\n d="M11.85.65c.2.2.2.5 0 .7L6.4 6.84a.55.55 0 01-.78 0L.14 1.35a.5.5 0 11.71-.7L6 5.8 11.15.65c.2-.2.5-.2.7 0z"\n />\n </svg>\n '},fi=mi.compose(Object.assign({baseName:"combobox",template:ui,styles:ci,shadowOptions:gi},vi));var bi=i(98316);const yi=(e,t)=>l.css`
880
880
  :host {
881
881
  --light-size: 12px;
882
882
  --height: calc(var(--design-unit) * 2px + var(--light-size));
@@ -932,13 +932,13 @@
932
932
  ${(0,l.when)(e=>e.showLabel,l.html`
933
933
  <div class="label">${e=>e.label}</div>
934
934
  `)}
935
- `;class Ci extends s.FoundationElement{constructor(){super(...arguments),this.showLabel=!1,this.label="disconnected",this.colour="red"}connectedCallback(){super.connectedCallback(),this.subscription=this.connect.isConnectedSubject.subscribe(e=>{this.label=this.getLabel(e),this.colour=e?"green":"red"})}disconnectedCallback(){var e;null===(e=this.subscription)||void 0===e||e.unsubscribe()}getLabel(e){if(!e)return"disconnected";return`${this.session.getSessionStorageItem("hostUrl")} ✔`}}(0,C.Cg)([ii.dm],Ci.prototype,"connect",void 0),(0,C.Cg)([bi.N],Ci.prototype,"session",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"show-label"})],Ci.prototype,"showLabel",void 0),(0,C.Cg)([l.observable],Ci.prototype,"label",void 0),(0,C.Cg)([l.observable],Ci.prototype,"colour",void 0);const xi=Ci.compose({baseName:"connection-indicator",template:wi,styles:yi}),$i=(e,t)=>l.css`
935
+ `;class Ci extends a.FoundationElement{constructor(){super(...arguments),this.showLabel=!1,this.label="disconnected",this.colour="red"}connectedCallback(){super.connectedCallback(),this.subscription=this.connect.isConnectedSubject.subscribe(e=>{this.label=this.getLabel(e),this.colour=e?"green":"red"})}disconnectedCallback(){var e;null===(e=this.subscription)||void 0===e||e.unsubscribe()}getLabel(e){if(!e)return"disconnected";return`${this.session.getSessionStorageItem("hostUrl")} ✔`}}(0,C.Cg)([ii.dm],Ci.prototype,"connect",void 0),(0,C.Cg)([bi.N],Ci.prototype,"session",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"show-label"})],Ci.prototype,"showLabel",void 0),(0,C.Cg)([l.observable],Ci.prototype,"label",void 0),(0,C.Cg)([l.observable],Ci.prototype,"colour",void 0);const xi=Ci.compose({baseName:"connection-indicator",template:wi,styles:yi}),$i=(e,t)=>l.css`
936
936
  ${(0,r.dataGridStyles)(e,t)}
937
- `,Si=(e,t)=>(0,s.dataGridTemplate)(e,t);class Ei extends r.DataGrid{}const ki=void 0,Oi={},Ti=Ei.compose(Object.assign({baseName:"data-grid",template:Si,styles:$i,shadowOptions:ki},Oi)),Ii=(e,t)=>l.css`
937
+ `,Si=(e,t)=>(0,a.dataGridTemplate)(e,t);class Ei extends r.DataGrid{}const ki=void 0,Oi={},Ti=Ei.compose(Object.assign({baseName:"data-grid",template:Si,styles:$i,shadowOptions:ki},Oi)),Ii=(e,t)=>l.css`
938
938
  ${(0,r.dataGridCellStyles)(e,t)}
939
- `;class Di extends r.DataGridCell{}const Ri=void 0,Ai={},Ni=Di.compose(Object.assign({baseName:"data-grid-cell",template:s.dataGridCellTemplate,styles:Ii,shadowOptions:Ri},Ai)),Li=(e,t)=>l.css`
939
+ `;class Ri extends r.DataGridCell{}const Ai=void 0,Di={},Ni=Ri.compose(Object.assign({baseName:"data-grid-cell",template:a.dataGridCellTemplate,styles:Ii,shadowOptions:Ai},Di)),Li=(e,t)=>l.css`
940
940
  ${(0,r.dataGridRowStyles)(e,t)}
941
- `;class Fi extends r.DataGridRow{}const Mi=void 0,_i={},Hi=Fi.compose(Object.assign({baseName:"data-grid-row",template:s.dataGridRowTemplate,styles:Li,shadowOptions:Mi},_i));var Pi=i(94343),zi=i.n(Pi),Ui=i(58915),Bi=i.n(Ui),Wi=i(7554),Gi=i.n(Wi),ji=i(49916),Vi=i.n(ji),Yi=i(33839),qi=i.n(Yi);class Ki{constructor(e,t="default"){e=null!=e?e:new Date,this.Date=e,this.date=e.getDate(),this.day=e.toLocaleString(t,{weekday:"long"}),this.dayNumber=e.getDay()+1,this.dayShort=e.toLocaleString(t,{weekday:"short"}),this.year=e.getFullYear(),this.yearShort=Number(e.toLocaleString(t,{year:"2-digit"})),this.month=e.toLocaleString(t,{month:"long"}),this.monthShort=e.toLocaleString(t,{month:"short"}),this.monthNumber=e.getMonth()+1,this.timestamp=e.getTime()}}zi().extend(qi());class Xi{constructor(e=null,t="default"){const i=new Ki(e,t);this.lang=t,this.name=i.month,this.number=i.monthNumber,this.year=i.year,this.numberOfDays=[31,28,31,30,31,30,31,31,30,31,30,31][this.number-1],2===this.number&&(this.numberOfDays+=zi()(i.date).isLeapYear()?1:0)}getDay(e){return new Ki(new Date(this.year,this.number-1,e),this.lang)}}zi().extend(qi());class Qi{constructor(e=null,t=null,i="default"){this.weekDays=Array.from({length:7}),this.today=new Ki(null,i),this.year=null!=e?e:this.today.year,this.month=new Xi(new Date(this.year,(t||this.today.monthNumber)-1),i),this.lang=i,this.weekDays.forEach((e,t)=>{const i=this.month.getDay(t);this.weekDays[i.dayNumber-1]=i.day})}getMonth(e){return new Xi(new Date(this.year,e-1),this.lang)}getPreviousMonth(){return 1===this.month.number?new Xi(new Date(this.year-1,11),this.lang):new Xi(new Date(this.year,this.month.number-2),this.lang)}getNextMonth(){return 1===this.month.number?new Xi(new Date(this.year+1,0),this.lang):new Xi(new Date(this.year,this.month.number+2),this.lang)}goToDate(e,t){this.month=new Xi(new Date(t,e-1),this.lang),this.year=t}goToNextYear(){this.year+=1,this.month=new Xi(new Date(this.year,0),this.lang)}goToPreviousYear(){this.year-=1,this.month=new Xi(new Date(this.year,11),this.lang)}goToNextMonth(){if(12===this.month.number)return this.goToNextYear();this.month=new Xi(new Date(this.year,this.month.number+1-1),this.lang)}goToPreviousMonth(){if(1===this.month.number)return this.goToPreviousYear();this.month=new Xi(new Date(this.year,this.month.number-1-1),this.lang)}}const Ji=l.css`
941
+ `;class Fi extends r.DataGridRow{}const Mi=void 0,_i={},Hi=Fi.compose(Object.assign({baseName:"data-grid-row",template:a.dataGridRowTemplate,styles:Li,shadowOptions:Mi},_i));var Pi=i(94343),zi=i.n(Pi),Ui=i(58915),Wi=i.n(Ui),Gi=i(7554),Bi=i.n(Gi),Vi=i(49916),ji=i.n(Vi),Yi=i(33839),qi=i.n(Yi);class Ki{constructor(e,t="default"){e=null!=e?e:new Date,this.Date=e,this.date=e.getDate(),this.day=e.toLocaleString(t,{weekday:"long"}),this.dayNumber=e.getDay()+1,this.dayShort=e.toLocaleString(t,{weekday:"short"}),this.year=e.getFullYear(),this.yearShort=Number(e.toLocaleString(t,{year:"2-digit"})),this.month=e.toLocaleString(t,{month:"long"}),this.monthShort=e.toLocaleString(t,{month:"short"}),this.monthNumber=e.getMonth()+1,this.timestamp=e.getTime()}}zi().extend(qi());class Xi{constructor(e=null,t="default"){const i=new Ki(e,t);this.lang=t,this.name=i.month,this.number=i.monthNumber,this.year=i.year,this.numberOfDays=[31,28,31,30,31,30,31,31,30,31,30,31][this.number-1],2===this.number&&(this.numberOfDays+=zi()(i.date).isLeapYear()?1:0)}getDay(e){return new Ki(new Date(this.year,this.number-1,e),this.lang)}}zi().extend(qi());class Qi{constructor(e=null,t=null,i="default"){this.weekDays=Array.from({length:7}),this.today=new Ki(null,i),this.year=null!=e?e:this.today.year,this.month=new Xi(new Date(this.year,(t||this.today.monthNumber)-1),i),this.lang=i,this.weekDays.forEach((e,t)=>{const i=this.month.getDay(t);this.weekDays[i.dayNumber-1]=i.day})}getMonth(e){return new Xi(new Date(this.year,e-1),this.lang)}getPreviousMonth(){return 1===this.month.number?new Xi(new Date(this.year-1,11),this.lang):new Xi(new Date(this.year,this.month.number-2),this.lang)}getNextMonth(){return 1===this.month.number?new Xi(new Date(this.year+1,0),this.lang):new Xi(new Date(this.year,this.month.number+2),this.lang)}goToDate(e,t){this.month=new Xi(new Date(t,e-1),this.lang),this.year=t}goToNextYear(){this.year+=1,this.month=new Xi(new Date(this.year,0),this.lang)}goToPreviousYear(){this.year-=1,this.month=new Xi(new Date(this.year,11),this.lang)}goToNextMonth(){if(12===this.month.number)return this.goToNextYear();this.month=new Xi(new Date(this.year,this.month.number+1-1),this.lang)}goToPreviousMonth(){if(1===this.month.number)return this.goToPreviousYear();this.month=new Xi(new Date(this.year,this.month.number-1-1),this.lang)}}const Ji=l.css`
942
942
  :host {
943
943
  position: relative;
944
944
  }
@@ -1141,8 +1141,8 @@
1141
1141
  </div>
1142
1142
  `,to=l.html`
1143
1143
  ${e=>eo(O(e))}
1144
- `;var io=i(28745);const oo=[1,2,3,4,5,6,7],no=(e,t,i)=>{if(o=t,-1===e.indexOf(o.dayNumber))return t;var o;const n=oo.filter(t=>-1===e.indexOf(t));let a=n.find(e=>e>t.dayNumber);a||(a=Math.min(...n));const s=t.dayNumber<a?a-t.dayNumber:a-t.dayNumber+7;return n.length?new Ki(((e,t=1)=>{const i=new Date(e);return i.setDate(e.getDate()+t),i})(t.Date,s),i):(io.v.warn("Date picker disabled days - all days of week have been disabled"),t)},ao=void 0,so={};class ro extends s.FoundationElement{constructor(){super(...arguments),this.format="MM-DD-YYYY",this.lang="en-US",this.visible=!1,this.position="bottom",this.disabledDaysOfWeek=[]}formatChanged(e,t){t&&this.calendar&&(this.formatDate=zi()(this.currentDate.Date).format(t))}inlineCalendarChanged(){this.toggleVisibility()}hideWeekendsCalendarChanged(){this.toggleVisibility()}valueChanged(e,t){if(t&&this.calendar){const e=zi()().localeData().longDateFormat("L");this.currentDate=new Ki(zi()(t,e).toDate(),this.lang),this.calendar.goToDate(this.currentDate.monthNumber,this.currentDate.year),this.formatDate=zi()(this.currentDate.Date).format(this.format),this.updateHeaderText(),this.monthList=this.getMonthDaysGrid()}}connectedCallback(){var e;super.connectedCallback(),zi().extend(Bi()),zi().extend(Vi()),zi().extend(Gi()),this.substringNumber=3;const t=this.value,i=t?zi()(t,"MM-DD-YYYY"):zi()();let o=new Ki(i.toDate(),this.lang);(null===(e=this.disabledDaysOfWeek)||void 0===e?void 0:e.length)&&(o=no(this.disabledDaysOfWeek,o,this.lang)),this.currentDate=o,this.calendar=new Qi(this.currentDate.year,this.currentDate.monthNumber,this.lang),this.value=zi()(this.currentDate.Date).format("MM-DD-YYYY"),this.currentMonth=this.calendar.month.name,this.currentYear=this.calendar.year,this.formatDate=zi()(this.currentDate.Date).format(this.format),this.monthList=this.getMonthDaysGrid()}updateHeaderText(){this.currentMonth=this.calendar.month.name,this.currentYear=this.calendar.year}toggleCalendar(){this.visible=!this.visible,this.toggleVisibility(),this.isCurrentCalendarMonth()||(this.calendar.goToDate(this.currentDate.monthNumber,this.currentDate.year),this.updateHeaderText())}toggleVisibility(){this.calendarDropdownClasses=(0,x.x)(["visible",this.visible],this.position,["inline",this.inlineCalendar],["hide-weekends",this.hideWeekends])}isSelectedDate(e){return zi()(e.Date).isSame(this.currentDate.Date,"day")}isCurrentCalendarMonth(){return this.currentMonth===this.currentDate.monthNumber&&this.currentYear===this.currentDate.year}prevMonth(){this.calendar.goToPreviousMonth(),this.updateHeaderText(),this.monthList=this.getMonthDaysGrid()}nextMonth(){this.calendar.goToNextMonth(),this.updateHeaderText(),this.monthList=this.getMonthDaysGrid()}selectDay(e){zi()(e.Date).isSame(this.currentDate.Date)||(this.currentDate=e,e.monthNumber!==this.calendar.month.number&&this.prevMonth(),this.formatDate=zi()(this.currentDate.Date).format(this.format),this.value=zi()(e.Date).format("MM-DD-YYYY"),this.$emit("value-changed",this.value),this.toggleCalendar())}getMonthDaysGrid(){const e=this.calendar.month.getDay(1),t=this.calendar.getPreviousMonth(),i=e.dayNumber-1,o=this.calendar.month.numberOfDays+i,n=Array.from({length:o});for(let e=i;e<o;e+=1)n[e]=this.calendar.month.getDay(e+1-i);for(let e=0;e<i;e+=1){const o=i-(e+1);n[e]=t.getDay(t.numberOfDays-o)}return n}}(0,C.Cg)([l.attr],ro.prototype,"format",void 0),(0,C.Cg)([l.attr],ro.prototype,"lang",void 0),(0,C.Cg)([l.attr],ro.prototype,"visible",void 0),(0,C.Cg)([(0,l.attr)({attribute:"inline-calendar",mode:"boolean"})],ro.prototype,"inlineCalendar",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-weekends",mode:"boolean"})],ro.prototype,"hideWeekends",void 0),(0,C.Cg)([l.attr],ro.prototype,"position",void 0),(0,C.Cg)([l.attr],ro.prototype,"label",void 0),(0,C.Cg)([l.attr],ro.prototype,"value",void 0),(0,C.Cg)([l.observable],ro.prototype,"currentDate",void 0),(0,C.Cg)([l.observable],ro.prototype,"currentMonth",void 0),(0,C.Cg)([l.observable],ro.prototype,"currentYear",void 0),(0,C.Cg)([l.observable],ro.prototype,"calendarDropdownClasses",void 0),(0,C.Cg)([l.observable],ro.prototype,"formatDate",void 0),(0,C.Cg)([l.observable],ro.prototype,"monthList",void 0),(0,C.Cg)([l.observable],ro.prototype,"disabledDaysOfWeek",void 0),(0,C.Cg)([l.observable],ro.prototype,"calendar",void 0);const lo=ro.compose(Object.assign({baseName:"date-picker",styles:Ji,template:to,shadowOptions:ao},so));var co=i(83912);const uo=r.SwatchRGB.create(1,1,1),ho=r.SwatchRGB.create(0,0,0),po=(0,co.parseColorHexRGB)("#585858"),mo=r.SwatchRGB.create(po.r,po.g,po.b),vo=(0,co.parseColorHexRGB)("#ffffff"),go=r.SwatchRGB.create(vo.r,vo.g,vo.b),fo=r.PaletteRGB.from(go),bo=(0,co.parseColorHexRGB)("#eeeeee"),yo=r.SwatchRGB.create(bo.r,bo.g,bo.b),wo=r.PaletteRGB.from(yo),Co=(0,co.parseColorHexRGB)("#08c3a5"),xo=r.SwatchRGB.create(Co.r,Co.g,Co.b),$o=r.PaletteRGB.from(xo),{create:So}=s.DesignToken,Eo=So("fui-fill-color").withDefault(mo),ko=So({name:"card-fill-color",cssCustomPropertyName:"fui-card-fill-color"}).withDefault(go),Oo=14;function To(e,t){return e.colorContrast(t,Oo)}const Io=So({name:"card-foreground-color",cssCustomPropertyName:"fui-card-foreground-color"}).withDefault(e=>To(So("fui-card-palette").withDefault(fo).getValueFor(e),ko.getValueFor(e))),Do=(e,t)=>{const i=structuredClone(e);return!t||"object"!=typeof t||Array.isArray(t)?void 0!==t?t:i:(Object.keys(t).forEach(e=>{const o=t[e],n=i[e];if(null==o)return;const a=e=>e instanceof Date;!o||"object"!=typeof o||Array.isArray(o)||a(o)||!n||"object"!=typeof n||Array.isArray(n)||a(n)?i[e]=o:i[e]=Do(n,o)}),i)};var Ro=i(80273);const Ao={design_tokens:{color:{accent:{$value:"#0EAFE2",$type:"color"},neutral:{$value:"#7C909B",$type:"color"}},fontFamily:{bodyFont:{$value:'Roboto, "Segoe UI", Arial, Helvetica, sans-serif',$type:"fontFamily"}},typography:{baseFontSize:{$value:"14px",$type:"dimension"},baseLineHeight:{$value:"20px",$type:"dimension"}},mode:{luminance:{$value:.23,$type:"number"}},style:{density:{$value:0,$type:"number"},baseHeightMultiplier:{$value:10,$type:"number"},borderRadius:{$value:4,$type:"number"},strokeWidth:{$value:1,$type:"number"}},space:{designUnit:{$value:4,$type:"number"}}}};class No{constructor(){this.value=null}}(0,C.Cg)([l.observable],No.prototype,"value",void 0);const Lo=new No,Fo=(e,t,i)=>{const o=i?(e,t)=>e.setValueFor(i,t):(e,t)=>e.withDefault(t);Object.keys(e).forEach(i=>{const n=`${i}Value`;t[n]&&o(e[i],t[n])})};function Mo(e){return(t,i)=>{t[i+"Changed"]=function(t,i){null!=i?e.setValueFor(this,i):e.deleteValueFor(this)}}}const _o={toView:e=>null==e?null:null==e?void 0:e.toColorString(),fromView(e){if(null==e)return null;const t=(0,co.parseColorHexRGB)(e);return t?r.SwatchRGB.create(t.r,t.g,t.b):null}},Ho=e=>r.PaletteRGB.from(r.SwatchRGB.from((0,co.parseColorHexRGB)(e))),Po=(e,t,i="")=>{Object.entries(t).forEach(([t,o])=>{const n=i?`${i}-${t}`:t;o&&"object"==typeof o&&("$value"in o?e.style.setProperty(`--${n}`,String(o.$value)):Po(e,o,n))})},zo=["baseClass","baseName","shadowOptions","styles","template"],Uo=(e,t=zo)=>Object.keys(e).filter(e=>!t.includes(e)).reduce((t,i)=>(t[i]=e[i],t),{}),Bo=e=>{const{definition:t}=e(),{shadowOptions:i,styles:o,template:n}=t;return{shadowOptions:i,styles:o,template:n,defaultConfig:Uo(t)}},Wo=(e,t)=>{const i=e.match(/^(\d+)([a-z]+)/i),o=i[1],n=i[2];return Number(o)+t+n},Go=()=>Lo,jo=(...e)=>{const t=Lo.value;if(!(null==t?void 0:t.customTokens)||0===e.length)return null;return function e(t,i){const[o,...n]=t;if(0===n.length){const e=i[o];return e&&e.$value?e:null}const a=i[o];return a?e(n,a):null}(e,t.customTokens)},Vo=(e,t)=>{const i=Do(Ao,t);const o=i.design_tokens;r.accentPalette.setValueFor(e,Ho(o.color.accent.$value)),r.neutralPalette.setValueFor(e,Ho(o.color.neutral.$value)),r.bodyFont.setValueFor(e,o.fontFamily.bodyFont.$value),r.baseLayerLuminance.setValueFor(e,o.mode.luminance.$value),r.density.setValueFor(e,o.style.density.$value),r.baseHeightMultiplier.setValueFor(e,o.style.baseHeightMultiplier.$value),r.controlCornerRadius.setValueFor(e,o.style.borderRadius.$value),r.strokeWidth.setValueFor(e,o.style.strokeWidth.$value),r.designUnit.setValueFor(e,o.space.designUnit.$value),r.typeRampBaseFontSize.setValueFor(e,o.typography.baseFontSize.$value),r.typeRampBaseLineHeight.setValueFor(e,o.typography.baseLineHeight.$value);const n=r.typeRampBaseFontSize.getValueFor(e),a=r.typeRampBaseLineHeight.getValueFor(e);r.typeRampMinus1FontSize.setValueFor(e,Wo(n,Ro.Du.minusOne)),r.typeRampMinus1LineHeight.setValueFor(e,Wo(a,Ro.Du.minusOne)),r.typeRampMinus2FontSize.setValueFor(e,Wo(n,Ro.Du.minusTwo)),r.typeRampMinus2LineHeight.setValueFor(e,Wo(a,Ro.Du.minusTwo)),r.typeRampPlus1FontSize.setValueFor(e,Wo(n,Ro.Du.plusOne)),r.typeRampPlus1LineHeight.setValueFor(e,Wo(a,Ro.Du.plusOne)),r.typeRampPlus2FontSize.setValueFor(e,Wo(n,Ro.Du.plusTwo)),r.typeRampPlus2LineHeight.setValueFor(e,Wo(a,Ro.Du.plusTwo)),r.typeRampPlus3FontSize.setValueFor(e,Wo(n,Ro.Du.plusThree)),r.typeRampPlus3LineHeight.setValueFor(e,Wo(a,Ro.Du.plusThree)),r.typeRampPlus4FontSize.setValueFor(e,Wo(n,Ro.Du.plusFour)),r.typeRampPlus4LineHeight.setValueFor(e,Wo(a,Ro.Du.plusFour)),r.typeRampPlus5FontSize.setValueFor(e,Wo(n,Ro.Du.plusFive)),r.typeRampPlus5LineHeight.setValueFor(e,Wo(a,Ro.Du.plusFive)),r.typeRampPlus6FontSize.setValueFor(e,Wo(n,Ro.Du.plusSix)),r.typeRampPlus6LineHeight.setValueFor(e,Wo(a,Ro.Du.plusSix)),i.customTokens&&Po(e,i.customTokens),Lo.value=structuredClone(i)},Yo=Ho("#08c3a5"),qo=Ho("#eeeeee"),Ko=r.StandardLuminance.DarkMode;const Xo=i(85109).O.ltr,Qo=4,Jo=4;var Zo=i(85090);const en=(e="normal",t="normal")=>`\n font-family: ${r.bodyFont};\n font-style: ${e};\n font-weight: ${t};\n`,tn=l.css`
1145
- ${(0,s.display)("flex")}
1144
+ `;var io=i(28745);const oo=[1,2,3,4,5,6,7],no=(e,t,i)=>{if(o=t,-1===e.indexOf(o.dayNumber))return t;var o;const n=oo.filter(t=>-1===e.indexOf(t));let s=n.find(e=>e>t.dayNumber);s||(s=Math.min(...n));const a=t.dayNumber<s?s-t.dayNumber:s-t.dayNumber+7;return n.length?new Ki(((e,t=1)=>{const i=new Date(e);return i.setDate(e.getDate()+t),i})(t.Date,a),i):(io.v.warn("Date picker disabled days - all days of week have been disabled"),t)},so=void 0,ao={};class ro extends a.FoundationElement{constructor(){super(...arguments),this.format="MM-DD-YYYY",this.lang="en-US",this.visible=!1,this.position="bottom",this.disabledDaysOfWeek=[]}formatChanged(e,t){t&&this.calendar&&(this.formatDate=zi()(this.currentDate.Date).format(t))}inlineCalendarChanged(){this.toggleVisibility()}hideWeekendsCalendarChanged(){this.toggleVisibility()}valueChanged(e,t){if(t&&this.calendar){const e=zi()().localeData().longDateFormat("L");this.currentDate=new Ki(zi()(t,e).toDate(),this.lang),this.calendar.goToDate(this.currentDate.monthNumber,this.currentDate.year),this.formatDate=zi()(this.currentDate.Date).format(this.format),this.updateHeaderText(),this.monthList=this.getMonthDaysGrid()}}connectedCallback(){var e;super.connectedCallback(),zi().extend(Wi()),zi().extend(ji()),zi().extend(Bi()),this.substringNumber=3;const t=this.value,i=t?zi()(t,"MM-DD-YYYY"):zi()();let o=new Ki(i.toDate(),this.lang);(null===(e=this.disabledDaysOfWeek)||void 0===e?void 0:e.length)&&(o=no(this.disabledDaysOfWeek,o,this.lang)),this.currentDate=o,this.calendar=new Qi(this.currentDate.year,this.currentDate.monthNumber,this.lang),this.value=zi()(this.currentDate.Date).format("MM-DD-YYYY"),this.currentMonth=this.calendar.month.name,this.currentYear=this.calendar.year,this.formatDate=zi()(this.currentDate.Date).format(this.format),this.monthList=this.getMonthDaysGrid()}updateHeaderText(){this.currentMonth=this.calendar.month.name,this.currentYear=this.calendar.year}toggleCalendar(){this.visible=!this.visible,this.toggleVisibility(),this.isCurrentCalendarMonth()||(this.calendar.goToDate(this.currentDate.monthNumber,this.currentDate.year),this.updateHeaderText())}toggleVisibility(){this.calendarDropdownClasses=(0,x.x)(["visible",this.visible],this.position,["inline",this.inlineCalendar],["hide-weekends",this.hideWeekends])}isSelectedDate(e){return zi()(e.Date).isSame(this.currentDate.Date,"day")}isCurrentCalendarMonth(){return this.currentMonth===this.currentDate.monthNumber&&this.currentYear===this.currentDate.year}prevMonth(){this.calendar.goToPreviousMonth(),this.updateHeaderText(),this.monthList=this.getMonthDaysGrid()}nextMonth(){this.calendar.goToNextMonth(),this.updateHeaderText(),this.monthList=this.getMonthDaysGrid()}selectDay(e){zi()(e.Date).isSame(this.currentDate.Date)||(this.currentDate=e,e.monthNumber!==this.calendar.month.number&&this.prevMonth(),this.formatDate=zi()(this.currentDate.Date).format(this.format),this.value=zi()(e.Date).format("MM-DD-YYYY"),this.$emit("value-changed",this.value),this.toggleCalendar())}getMonthDaysGrid(){const e=this.calendar.month.getDay(1),t=this.calendar.getPreviousMonth(),i=e.dayNumber-1,o=this.calendar.month.numberOfDays+i,n=Array.from({length:o});for(let e=i;e<o;e+=1)n[e]=this.calendar.month.getDay(e+1-i);for(let e=0;e<i;e+=1){const o=i-(e+1);n[e]=t.getDay(t.numberOfDays-o)}return n}}(0,C.Cg)([l.attr],ro.prototype,"format",void 0),(0,C.Cg)([l.attr],ro.prototype,"lang",void 0),(0,C.Cg)([l.attr],ro.prototype,"visible",void 0),(0,C.Cg)([(0,l.attr)({attribute:"inline-calendar",mode:"boolean"})],ro.prototype,"inlineCalendar",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-weekends",mode:"boolean"})],ro.prototype,"hideWeekends",void 0),(0,C.Cg)([l.attr],ro.prototype,"position",void 0),(0,C.Cg)([l.attr],ro.prototype,"label",void 0),(0,C.Cg)([l.attr],ro.prototype,"value",void 0),(0,C.Cg)([l.observable],ro.prototype,"currentDate",void 0),(0,C.Cg)([l.observable],ro.prototype,"currentMonth",void 0),(0,C.Cg)([l.observable],ro.prototype,"currentYear",void 0),(0,C.Cg)([l.observable],ro.prototype,"calendarDropdownClasses",void 0),(0,C.Cg)([l.observable],ro.prototype,"formatDate",void 0),(0,C.Cg)([l.observable],ro.prototype,"monthList",void 0),(0,C.Cg)([l.observable],ro.prototype,"disabledDaysOfWeek",void 0),(0,C.Cg)([l.observable],ro.prototype,"calendar",void 0);const lo=ro.compose(Object.assign({baseName:"date-picker",styles:Ji,template:to,shadowOptions:so},ao));var co=i(83912);const uo=r.SwatchRGB.create(1,1,1),ho=r.SwatchRGB.create(0,0,0),po=(0,co.parseColorHexRGB)("#585858"),mo=r.SwatchRGB.create(po.r,po.g,po.b),go=(0,co.parseColorHexRGB)("#ffffff"),vo=r.SwatchRGB.create(go.r,go.g,go.b),fo=r.PaletteRGB.from(vo),bo=(0,co.parseColorHexRGB)("#eeeeee"),yo=r.SwatchRGB.create(bo.r,bo.g,bo.b),wo=r.PaletteRGB.from(yo),Co=(0,co.parseColorHexRGB)("#08c3a5"),xo=r.SwatchRGB.create(Co.r,Co.g,Co.b),$o=r.PaletteRGB.from(xo),{create:So}=a.DesignToken,Eo=So("fui-fill-color").withDefault(mo),ko=So({name:"card-fill-color",cssCustomPropertyName:"fui-card-fill-color"}).withDefault(vo),Oo=14;function To(e,t){return e.colorContrast(t,Oo)}const Io=So({name:"card-foreground-color",cssCustomPropertyName:"fui-card-foreground-color"}).withDefault(e=>To(So("fui-card-palette").withDefault(fo).getValueFor(e),ko.getValueFor(e))),Ro=(e,t)=>{const i=structuredClone(e);return!t||"object"!=typeof t||Array.isArray(t)?void 0!==t?t:i:(Object.keys(t).forEach(e=>{const o=t[e],n=i[e];if(null==o)return;const s=e=>e instanceof Date;!o||"object"!=typeof o||Array.isArray(o)||s(o)||!n||"object"!=typeof n||Array.isArray(n)||s(n)?i[e]=o:i[e]=Ro(n,o)}),i)};var Ao=i(80273);const Do={design_tokens:{color:{accent:{$value:"#0EAFE2",$type:"color"},neutral:{$value:"#7C909B",$type:"color"}},fontFamily:{bodyFont:{$value:'Roboto, "Segoe UI", Arial, Helvetica, sans-serif',$type:"fontFamily"}},typography:{baseFontSize:{$value:"14px",$type:"dimension"},baseLineHeight:{$value:"20px",$type:"dimension"}},mode:{luminance:{$value:.23,$type:"number"}},style:{density:{$value:0,$type:"number"},baseHeightMultiplier:{$value:10,$type:"number"},borderRadius:{$value:4,$type:"number"},strokeWidth:{$value:1,$type:"number"}},space:{designUnit:{$value:4,$type:"number"}}}};class No{constructor(){this.value=null}}(0,C.Cg)([l.observable],No.prototype,"value",void 0);const Lo=new No,Fo=(e,t,i)=>{const o=i?(e,t)=>e.setValueFor(i,t):(e,t)=>e.withDefault(t);Object.keys(e).forEach(i=>{const n=`${i}Value`;t[n]&&o(e[i],t[n])})};function Mo(e){return(t,i)=>{t[i+"Changed"]=function(t,i){null!=i?e.setValueFor(this,i):e.deleteValueFor(this)}}}const _o={toView:e=>null==e?null:null==e?void 0:e.toColorString(),fromView(e){if(null==e)return null;const t=(0,co.parseColorHexRGB)(e);return t?r.SwatchRGB.create(t.r,t.g,t.b):null}},Ho=e=>r.PaletteRGB.from(r.SwatchRGB.from((0,co.parseColorHexRGB)(e))),Po=(e,t,i="")=>{Object.entries(t).forEach(([t,o])=>{const n=i?`${i}-${t}`:t;o&&"object"==typeof o&&("$value"in o?e.style.setProperty(`--${n}`,String(o.$value)):Po(e,o,n))})},zo=["baseClass","baseName","shadowOptions","styles","template"],Uo=(e,t=zo)=>Object.keys(e).filter(e=>!t.includes(e)).reduce((t,i)=>(t[i]=e[i],t),{}),Wo=e=>{const{definition:t}=e(),{shadowOptions:i,styles:o,template:n}=t;return{shadowOptions:i,styles:o,template:n,defaultConfig:Uo(t)}},Go=(e,t)=>{const i=e.match(/^(\d+)([a-z]+)/i),o=i[1],n=i[2];return Number(o)+t+n},Bo=()=>Lo,Vo=(...e)=>{const t=Lo.value;if(!(null==t?void 0:t.customTokens)||0===e.length)return null;return function e(t,i){const[o,...n]=t;if(0===n.length){const e=i[o];return e&&e.$value?e:null}const s=i[o];return s?e(n,s):null}(e,t.customTokens)},jo=(e,t)=>{const i=Ro(Do,t);const o=i.design_tokens;r.accentPalette.setValueFor(e,Ho(o.color.accent.$value)),r.neutralPalette.setValueFor(e,Ho(o.color.neutral.$value)),r.bodyFont.setValueFor(e,o.fontFamily.bodyFont.$value),r.baseLayerLuminance.setValueFor(e,o.mode.luminance.$value),r.density.setValueFor(e,o.style.density.$value),r.baseHeightMultiplier.setValueFor(e,o.style.baseHeightMultiplier.$value),r.controlCornerRadius.setValueFor(e,o.style.borderRadius.$value),r.strokeWidth.setValueFor(e,o.style.strokeWidth.$value),r.designUnit.setValueFor(e,o.space.designUnit.$value),r.typeRampBaseFontSize.setValueFor(e,o.typography.baseFontSize.$value),r.typeRampBaseLineHeight.setValueFor(e,o.typography.baseLineHeight.$value);const n=r.typeRampBaseFontSize.getValueFor(e),s=r.typeRampBaseLineHeight.getValueFor(e);r.typeRampMinus1FontSize.setValueFor(e,Go(n,Ao.Du.minusOne)),r.typeRampMinus1LineHeight.setValueFor(e,Go(s,Ao.Du.minusOne)),r.typeRampMinus2FontSize.setValueFor(e,Go(n,Ao.Du.minusTwo)),r.typeRampMinus2LineHeight.setValueFor(e,Go(s,Ao.Du.minusTwo)),r.typeRampPlus1FontSize.setValueFor(e,Go(n,Ao.Du.plusOne)),r.typeRampPlus1LineHeight.setValueFor(e,Go(s,Ao.Du.plusOne)),r.typeRampPlus2FontSize.setValueFor(e,Go(n,Ao.Du.plusTwo)),r.typeRampPlus2LineHeight.setValueFor(e,Go(s,Ao.Du.plusTwo)),r.typeRampPlus3FontSize.setValueFor(e,Go(n,Ao.Du.plusThree)),r.typeRampPlus3LineHeight.setValueFor(e,Go(s,Ao.Du.plusThree)),r.typeRampPlus4FontSize.setValueFor(e,Go(n,Ao.Du.plusFour)),r.typeRampPlus4LineHeight.setValueFor(e,Go(s,Ao.Du.plusFour)),r.typeRampPlus5FontSize.setValueFor(e,Go(n,Ao.Du.plusFive)),r.typeRampPlus5LineHeight.setValueFor(e,Go(s,Ao.Du.plusFive)),r.typeRampPlus6FontSize.setValueFor(e,Go(n,Ao.Du.plusSix)),r.typeRampPlus6LineHeight.setValueFor(e,Go(s,Ao.Du.plusSix)),i.customTokens&&Po(e,i.customTokens),Lo.value=structuredClone(i)},Yo=Ho("#08c3a5"),qo=Ho("#eeeeee"),Ko=r.StandardLuminance.DarkMode;const Xo=i(85109).O.ltr,Qo=4,Jo=4;var Zo=i(85090);const en=(e="normal",t="normal")=>`\n font-family: ${r.bodyFont};\n font-style: ${e};\n font-weight: ${t};\n`,tn=l.css`
1145
+ ${(0,a.display)("flex")}
1146
1146
  :host {
1147
1147
  flex: 1;
1148
1148
  }
@@ -1150,7 +1150,7 @@
1150
1150
  :host {
1151
1151
  background-color: ${Eo};
1152
1152
  }
1153
- `.withBehaviors((0,s.forcedColorsStylesheetBehavior)(l.css`
1153
+ `.withBehaviors((0,a.forcedColorsStylesheetBehavior)(l.css`
1154
1154
  :host {
1155
1155
  background-color: ${Zo.A.ButtonFace};
1156
1156
  box-shadow: 0 0 0 1px ${Zo.A.CanvasText};
@@ -1160,7 +1160,7 @@
1160
1160
  ${e.name} ${"h"+t} {
1161
1161
  margin: 0;
1162
1162
  }
1163
- `;class an extends r.DesignSystemProvider{constructor(){super(),Fo(o,n,this)}}(0,C.Cg)([(0,l.attr)({attribute:"card-fill-color",converter:_o}),Mo(ko)],an.prototype,"cardFillColor",void 0),(0,C.Cg)([(0,l.attr)({attribute:"card-foreground-color",converter:_o}),Mo(Io)],an.prototype,"cardForegroundColor",void 0);const sn=an.compose({baseName:"design-system-provider",template:l.html`
1163
+ `;class sn extends r.DesignSystemProvider{constructor(){super(),Fo(o,n,this)}}(0,C.Cg)([(0,l.attr)({attribute:"card-fill-color",converter:_o}),Mo(ko)],sn.prototype,"cardFillColor",void 0),(0,C.Cg)([(0,l.attr)({attribute:"card-foreground-color",converter:_o}),Mo(Io)],sn.prototype,"cardForegroundColor",void 0);const an=sn.compose({baseName:"design-system-provider",template:l.html`
1164
1164
  <slot></slot>
1165
1165
  `,styles:e=>{const t=(e=>l.css`
1166
1166
  ${nn(e,"1")}
@@ -1507,11 +1507,11 @@
1507
1507
  </dialog>
1508
1508
  `,hn=l.html`
1509
1509
  ${e=>un(O(e))}
1510
- `,pn={mode:"open",delegatesFocus:!0},mn={};class vn extends s.FoundationElement{constructor(){super(...arguments),this.type="default",this.position="center",this.showCloseIcon=!0,this.resizable=!1,this.minWidth=300,this.minHeight=200,this.isResizing=!1,this.currentResizeHandle=null,this.startX=0,this.startY=0,this.startWidth=0,this.startHeight=0,this.startLeft=0,this.startTop=0,this.resizeOffsetX=0,this.resizeOffsetY=0,this.originalWidth="",this.originalHeight="",this.originalPosition="",this.originalLeft="",this.originalTop="",this.originalMargin="",this.isMaximized=!1,this.hasBeenResized=!1}notificationChanged(){this.notification&&(this.showCloseIcon=!1)}connectedCallback(){super.connectedCallback(),window.HTMLDialogElement||rn.A.registerDialog(this.mainElement),this.mainElement.addEventListener("close",()=>{this.onCloseCallback&&this.onCloseCallback(),this.$emit("close")}),this.hasAttribute("open")&&this.shadowRoot.querySelector("dialog").setAttribute("open",""),this.setupResizeHandlers()}disconnectedCallback(){super.disconnectedCallback(),this.removeResizeHandlers()}setupResizeHandlers(){if(!this.resizable)return;const e=window.innerWidth,t=window.innerHeight;let i=this.minWidth,o=this.minHeight;void 0!==this.initialWidth&&(i=Math.max(this.minWidth,Math.min(this.initialWidth,e))),void 0!==this.initialHeight&&(o=Math.max(this.minHeight,Math.min(this.initialHeight,t))),this.originalWidth=this.mainElement.style.width||`${i}px`,this.originalHeight=this.mainElement.style.height||`${o}px`,this.originalPosition=this.mainElement.style.position||"",this.originalLeft=this.mainElement.style.left||"",this.originalTop=this.mainElement.style.top||"",this.originalMargin=this.mainElement.style.margin||"",this.mainElement.style.height=`${o}px`,this.mainElement.style.minHeight=`${this.minHeight}px`,this.mainElement.style.width=`${i}px`,this.mainElement.style.minWidth=`${this.minWidth}px`,this.originalWidth=this.mainElement.style.width,this.originalHeight=this.mainElement.style.height;this.shadowRoot.querySelectorAll(".resize-handle").forEach(e=>{e.addEventListener("mousedown",this.handleResizeStart.bind(this)),e.addEventListener("dblclick",this.handleEdgeDoubleClick.bind(this))})}removeResizeHandlers(){var e;document.removeEventListener("mousemove",this.handleResizeMove.bind(this)),document.removeEventListener("mouseup",this.handleResizeEnd.bind(this));const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelectorAll(".resize-handle");null==t||t.forEach(e=>{e.removeEventListener("dblclick",this.handleEdgeDoubleClick.bind(this))})}handleEdgeDoubleClick(e){if(!this.resizable)return;e.preventDefault(),e.stopPropagation();const t=e.target.dataset.direction;if(!["n","s","e","w"].includes(t))return;const i=this.mainElement.getBoundingClientRect(),o=window.innerWidth,n=window.innerHeight;switch(this.mainElement.style.position="fixed",this.mainElement.style.margin="0",t){case"n":this.mainElement.style.height=`${i.bottom}px`,this.mainElement.style.top="0px";break;case"s":this.mainElement.style.height=n-i.top+"px";break;case"e":this.mainElement.style.width=o-i.left+"px";break;case"w":this.mainElement.style.width=`${i.right}px`,this.mainElement.style.left="0px"}this.hasBeenResized=!0,this.$emit("resize",{width:this.mainElement.offsetWidth,height:this.mainElement.offsetHeight})}handleResizeStart(e){if(!this.resizable)return;e.preventDefault(),e.stopPropagation(),this.isResizing=!0;const t=e.target;this.currentResizeHandle=t.dataset.direction,this.startX=e.clientX,this.startY=e.clientY;const i=this.mainElement.getBoundingClientRect();switch(this.startWidth=i.width,this.startHeight=i.height,this.startLeft=i.left,this.startTop=i.top,this.resizeOffsetX=0,this.resizeOffsetY=0,this.currentResizeHandle){case"n":this.resizeOffsetY=e.clientY-i.top;break;case"s":this.resizeOffsetY=e.clientY-i.bottom;break;case"e":this.resizeOffsetX=e.clientX-i.right;break;case"w":this.resizeOffsetX=e.clientX-i.left;break;case"ne":this.resizeOffsetX=e.clientX-i.right,this.resizeOffsetY=e.clientY-i.top;break;case"nw":this.resizeOffsetX=e.clientX-i.left,this.resizeOffsetY=e.clientY-i.top;break;case"se":this.resizeOffsetX=e.clientX-i.right,this.resizeOffsetY=e.clientY-i.bottom;break;case"sw":this.resizeOffsetX=e.clientX-i.left,this.resizeOffsetY=e.clientY-i.bottom}this.mainElement.style.position="fixed",this.mainElement.style.left=`${i.left}px`,this.mainElement.style.top=`${i.top}px`,this.mainElement.style.margin="0",document.addEventListener("mousemove",this.handleResizeMove.bind(this)),document.addEventListener("mouseup",this.handleResizeEnd.bind(this)),this.mainElement.classList.add("resizing")}handleResizeMove(e){if(!this.isResizing||!this.currentResizeHandle)return;e.preventDefault();const t=e.clientX-this.startX-this.resizeOffsetX,i=e.clientY-this.startY-this.resizeOffsetY;let o=this.startWidth,n=this.startHeight,a=this.startLeft,s=this.startTop,r=!1;switch(this.currentResizeHandle){case"se":o=this.startWidth+t,n=this.startHeight+i;break;case"sw":o=this.startWidth-t,n=this.startHeight+i,a=this.startLeft+t,r=!0;break;case"ne":o=this.startWidth+t,n=this.startHeight-i,s=this.startTop+i,r=!0;break;case"nw":o=this.startWidth-t,n=this.startHeight-i,a=this.startLeft+t,s=this.startTop+i,r=!0;break;case"e":o=this.startWidth+t;break;case"w":o=this.startWidth-t,a=this.startLeft+t,r=!0;break;case"s":n=this.startHeight+i;break;case"n":n=this.startHeight-i,s=this.startTop+i,r=!0}const l=window.innerWidth,d=window.innerHeight;if(this.resizable){if(o<this.minWidth){const e=this.minWidth-o;o=this.minWidth,this.currentResizeHandle.includes("w")&&(a-=e)}if(n<this.minHeight){const e=this.minHeight-n;n=this.minHeight,this.currentResizeHandle.includes("n")&&(s-=e)}if(this.currentResizeHandle.includes("e")){const e=l-this.startLeft;o>e&&(o=e)}if(this.currentResizeHandle.includes("s")){const e=d-this.startTop;n>e&&(n=e)}if(this.currentResizeHandle.includes("w")){a<0&&(o+=a,a=0);const e=l-a;o>e&&(o=e)}if(this.currentResizeHandle.includes("n")){s<0&&(n+=s,s=0);const e=d-s;n>e&&(n=e)}}this.mainElement.style.width=`${o}px`,this.mainElement.style.height=`${n}px`,r&&(this.mainElement.style.left=`${a}px`,this.mainElement.style.top=`${s}px`)}handleResizeEnd(e){if(!this.isResizing)return;e.preventDefault(),this.isResizing=!1,this.currentResizeHandle=null,this.resizeOffsetX=0,this.resizeOffsetY=0,document.removeEventListener("mousemove",this.handleResizeMove.bind(this)),document.removeEventListener("mouseup",this.handleResizeEnd.bind(this)),this.mainElement.classList.remove("resizing");const t=this.mainElement.style.width,i=this.mainElement.style.height;t===this.originalWidth&&i===this.originalHeight||(this.hasBeenResized=!0),this.$emit("resize",{width:this.mainElement.offsetWidth,height:this.mainElement.offsetHeight})}get open(){return this.mainElement.hasAttribute("open")}get resizeIconName(){return this.hasBeenResized||this.isMaximized?"compress":"expand"}close(){this.mainElement.close()}dismiss(){var e,t,i,o;(null===(o=null===(i=null===(t=null===(e=this.notification)||void 0===e?void 0:e.config)||void 0===t?void 0:t.dialog)||void 0===i?void 0:i.dismissingAction)||void 0===o?void 0:o.action)&&this.notification.config.dialog.dismissingAction.action(),this.closeDialog()}closeDialog(){try{this.mainElement.close(),this.remove()}catch(e){Xe.error(e)}}maximize(){this.resizable&&this.mainElement&&(this.mainElement.style.position="fixed",this.mainElement.style.left="0px",this.mainElement.style.top="0px",this.mainElement.style.margin="0",this.mainElement.style.width="100vw",this.mainElement.style.height="100vh",this.isMaximized=!0,this.hasBeenResized=!0,this.$emit("resize",{width:this.mainElement.offsetWidth,height:this.mainElement.offsetHeight}))}resetSize(){this.resizable&&this.mainElement&&(this.hasBeenResized||this.isMaximized?(this.mainElement.style.width=this.originalWidth,this.mainElement.style.height=this.originalHeight,this.mainElement.style.position=this.originalPosition,this.mainElement.style.left=this.originalLeft,this.mainElement.style.top=this.originalTop,this.mainElement.style.margin=this.originalMargin,this.isMaximized=!1,this.hasBeenResized=!1,this.$emit("resize",{width:this.mainElement.offsetWidth,height:this.mainElement.offsetHeight})):this.maximize())}}(0,C.Cg)([l.observable],vn.prototype,"notification",void 0),(0,C.Cg)([(0,l.attr)({attribute:"type"})],vn.prototype,"type",void 0),(0,C.Cg)([l.attr],vn.prototype,"position",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"show-close-icon"})],vn.prototype,"showCloseIcon",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"resizable"})],vn.prototype,"resizable",void 0),(0,C.Cg)([(0,l.attr)({attribute:"min-width"})],vn.prototype,"minWidth",void 0),(0,C.Cg)([(0,l.attr)({attribute:"min-height"})],vn.prototype,"minHeight",void 0),(0,C.Cg)([(0,l.attr)({attribute:"initial-width"})],vn.prototype,"initialWidth",void 0),(0,C.Cg)([(0,l.attr)({attribute:"initial-height"})],vn.prototype,"initialHeight",void 0),(0,C.Cg)([l.observable],vn.prototype,"onShowCallback",void 0),(0,C.Cg)([l.observable],vn.prototype,"onCloseCallback",void 0),(0,C.Cg)([l.observable],vn.prototype,"isMaximized",void 0),(0,C.Cg)([l.observable],vn.prototype,"hasBeenResized",void 0),(0,C.Cg)([l.volatile],vn.prototype,"open",null),(0,C.Cg)([l.volatile],vn.prototype,"resizeIconName",null);class gn extends vn{show(){this.onShowCallback&&this.onShowCallback(),this.mainElement.show()}}const fn=gn.compose(Object.assign({baseName:"dialog",styles:ln,template:hn,shadowOptions:pn},mn)),bn=(e,t)=>l.css`
1510
+ `,pn={mode:"open",delegatesFocus:!0},mn={};class gn extends a.FoundationElement{constructor(){super(...arguments),this.type="default",this.position="center",this.showCloseIcon=!0,this.resizable=!1,this.minWidth=300,this.minHeight=200,this.isResizing=!1,this.currentResizeHandle=null,this.startX=0,this.startY=0,this.startWidth=0,this.startHeight=0,this.startLeft=0,this.startTop=0,this.resizeOffsetX=0,this.resizeOffsetY=0,this.originalWidth="",this.originalHeight="",this.originalPosition="",this.originalLeft="",this.originalTop="",this.originalMargin="",this.isMaximized=!1,this.hasBeenResized=!1}notificationChanged(){this.notification&&(this.showCloseIcon=!1)}connectedCallback(){super.connectedCallback(),window.HTMLDialogElement||rn.A.registerDialog(this.mainElement),this.mainElement.addEventListener("close",()=>{this.onCloseCallback&&this.onCloseCallback(),this.$emit("close")}),this.hasAttribute("open")&&this.shadowRoot.querySelector("dialog").setAttribute("open",""),this.setupResizeHandlers()}disconnectedCallback(){super.disconnectedCallback(),this.removeResizeHandlers()}setupResizeHandlers(){if(!this.resizable)return;const e=window.innerWidth,t=window.innerHeight;let i=this.minWidth,o=this.minHeight;void 0!==this.initialWidth&&(i=Math.max(this.minWidth,Math.min(this.initialWidth,e))),void 0!==this.initialHeight&&(o=Math.max(this.minHeight,Math.min(this.initialHeight,t))),this.originalWidth=this.mainElement.style.width||`${i}px`,this.originalHeight=this.mainElement.style.height||`${o}px`,this.originalPosition=this.mainElement.style.position||"",this.originalLeft=this.mainElement.style.left||"",this.originalTop=this.mainElement.style.top||"",this.originalMargin=this.mainElement.style.margin||"",this.mainElement.style.height=`${o}px`,this.mainElement.style.minHeight=`${this.minHeight}px`,this.mainElement.style.width=`${i}px`,this.mainElement.style.minWidth=`${this.minWidth}px`,this.originalWidth=this.mainElement.style.width,this.originalHeight=this.mainElement.style.height;this.shadowRoot.querySelectorAll(".resize-handle").forEach(e=>{e.addEventListener("mousedown",this.handleResizeStart.bind(this)),e.addEventListener("dblclick",this.handleEdgeDoubleClick.bind(this))})}removeResizeHandlers(){var e;document.removeEventListener("mousemove",this.handleResizeMove.bind(this)),document.removeEventListener("mouseup",this.handleResizeEnd.bind(this));const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelectorAll(".resize-handle");null==t||t.forEach(e=>{e.removeEventListener("dblclick",this.handleEdgeDoubleClick.bind(this))})}handleEdgeDoubleClick(e){if(!this.resizable)return;e.preventDefault(),e.stopPropagation();const t=e.target.dataset.direction;if(!["n","s","e","w"].includes(t))return;const i=this.mainElement.getBoundingClientRect(),o=window.innerWidth,n=window.innerHeight;switch(this.mainElement.style.position="fixed",this.mainElement.style.margin="0",t){case"n":this.mainElement.style.height=`${i.bottom}px`,this.mainElement.style.top="0px";break;case"s":this.mainElement.style.height=n-i.top+"px";break;case"e":this.mainElement.style.width=o-i.left+"px";break;case"w":this.mainElement.style.width=`${i.right}px`,this.mainElement.style.left="0px"}this.hasBeenResized=!0,this.$emit("resize",{width:this.mainElement.offsetWidth,height:this.mainElement.offsetHeight})}handleResizeStart(e){if(!this.resizable)return;e.preventDefault(),e.stopPropagation(),this.isResizing=!0;const t=e.target;this.currentResizeHandle=t.dataset.direction,this.startX=e.clientX,this.startY=e.clientY;const i=this.mainElement.getBoundingClientRect();switch(this.startWidth=i.width,this.startHeight=i.height,this.startLeft=i.left,this.startTop=i.top,this.resizeOffsetX=0,this.resizeOffsetY=0,this.currentResizeHandle){case"n":this.resizeOffsetY=e.clientY-i.top;break;case"s":this.resizeOffsetY=e.clientY-i.bottom;break;case"e":this.resizeOffsetX=e.clientX-i.right;break;case"w":this.resizeOffsetX=e.clientX-i.left;break;case"ne":this.resizeOffsetX=e.clientX-i.right,this.resizeOffsetY=e.clientY-i.top;break;case"nw":this.resizeOffsetX=e.clientX-i.left,this.resizeOffsetY=e.clientY-i.top;break;case"se":this.resizeOffsetX=e.clientX-i.right,this.resizeOffsetY=e.clientY-i.bottom;break;case"sw":this.resizeOffsetX=e.clientX-i.left,this.resizeOffsetY=e.clientY-i.bottom}this.mainElement.style.position="fixed",this.mainElement.style.left=`${i.left}px`,this.mainElement.style.top=`${i.top}px`,this.mainElement.style.margin="0",document.addEventListener("mousemove",this.handleResizeMove.bind(this)),document.addEventListener("mouseup",this.handleResizeEnd.bind(this)),this.mainElement.classList.add("resizing")}handleResizeMove(e){if(!this.isResizing||!this.currentResizeHandle)return;e.preventDefault();const t=e.clientX-this.startX-this.resizeOffsetX,i=e.clientY-this.startY-this.resizeOffsetY;let o=this.startWidth,n=this.startHeight,s=this.startLeft,a=this.startTop,r=!1;switch(this.currentResizeHandle){case"se":o=this.startWidth+t,n=this.startHeight+i;break;case"sw":o=this.startWidth-t,n=this.startHeight+i,s=this.startLeft+t,r=!0;break;case"ne":o=this.startWidth+t,n=this.startHeight-i,a=this.startTop+i,r=!0;break;case"nw":o=this.startWidth-t,n=this.startHeight-i,s=this.startLeft+t,a=this.startTop+i,r=!0;break;case"e":o=this.startWidth+t;break;case"w":o=this.startWidth-t,s=this.startLeft+t,r=!0;break;case"s":n=this.startHeight+i;break;case"n":n=this.startHeight-i,a=this.startTop+i,r=!0}const l=window.innerWidth,d=window.innerHeight;if(this.resizable){if(o<this.minWidth){const e=this.minWidth-o;o=this.minWidth,this.currentResizeHandle.includes("w")&&(s-=e)}if(n<this.minHeight){const e=this.minHeight-n;n=this.minHeight,this.currentResizeHandle.includes("n")&&(a-=e)}if(this.currentResizeHandle.includes("e")){const e=l-this.startLeft;o>e&&(o=e)}if(this.currentResizeHandle.includes("s")){const e=d-this.startTop;n>e&&(n=e)}if(this.currentResizeHandle.includes("w")){s<0&&(o+=s,s=0);const e=l-s;o>e&&(o=e)}if(this.currentResizeHandle.includes("n")){a<0&&(n+=a,a=0);const e=d-a;n>e&&(n=e)}}this.mainElement.style.width=`${o}px`,this.mainElement.style.height=`${n}px`,r&&(this.mainElement.style.left=`${s}px`,this.mainElement.style.top=`${a}px`)}handleResizeEnd(e){if(!this.isResizing)return;e.preventDefault(),this.isResizing=!1,this.currentResizeHandle=null,this.resizeOffsetX=0,this.resizeOffsetY=0,document.removeEventListener("mousemove",this.handleResizeMove.bind(this)),document.removeEventListener("mouseup",this.handleResizeEnd.bind(this)),this.mainElement.classList.remove("resizing");const t=this.mainElement.style.width,i=this.mainElement.style.height;t===this.originalWidth&&i===this.originalHeight||(this.hasBeenResized=!0),this.$emit("resize",{width:this.mainElement.offsetWidth,height:this.mainElement.offsetHeight})}get open(){return this.mainElement.hasAttribute("open")}get resizeIconName(){return this.hasBeenResized||this.isMaximized?"compress":"expand"}close(){this.mainElement.close()}dismiss(){var e,t,i,o;(null===(o=null===(i=null===(t=null===(e=this.notification)||void 0===e?void 0:e.config)||void 0===t?void 0:t.dialog)||void 0===i?void 0:i.dismissingAction)||void 0===o?void 0:o.action)&&this.notification.config.dialog.dismissingAction.action(),this.closeDialog()}closeDialog(){try{this.mainElement.close(),this.remove()}catch(e){Xe.error(e)}}maximize(){this.resizable&&this.mainElement&&(this.mainElement.style.position="fixed",this.mainElement.style.left="0px",this.mainElement.style.top="0px",this.mainElement.style.margin="0",this.mainElement.style.width="100vw",this.mainElement.style.height="100vh",this.isMaximized=!0,this.hasBeenResized=!0,this.$emit("resize",{width:this.mainElement.offsetWidth,height:this.mainElement.offsetHeight}))}resetSize(){this.resizable&&this.mainElement&&(this.hasBeenResized||this.isMaximized?(this.mainElement.style.width=this.originalWidth,this.mainElement.style.height=this.originalHeight,this.mainElement.style.position=this.originalPosition,this.mainElement.style.left=this.originalLeft,this.mainElement.style.top=this.originalTop,this.mainElement.style.margin=this.originalMargin,this.isMaximized=!1,this.hasBeenResized=!1,this.$emit("resize",{width:this.mainElement.offsetWidth,height:this.mainElement.offsetHeight})):this.maximize())}}(0,C.Cg)([l.observable],gn.prototype,"notification",void 0),(0,C.Cg)([(0,l.attr)({attribute:"type"})],gn.prototype,"type",void 0),(0,C.Cg)([l.attr],gn.prototype,"position",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"show-close-icon"})],gn.prototype,"showCloseIcon",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"resizable"})],gn.prototype,"resizable",void 0),(0,C.Cg)([(0,l.attr)({attribute:"min-width"})],gn.prototype,"minWidth",void 0),(0,C.Cg)([(0,l.attr)({attribute:"min-height"})],gn.prototype,"minHeight",void 0),(0,C.Cg)([(0,l.attr)({attribute:"initial-width"})],gn.prototype,"initialWidth",void 0),(0,C.Cg)([(0,l.attr)({attribute:"initial-height"})],gn.prototype,"initialHeight",void 0),(0,C.Cg)([l.observable],gn.prototype,"onShowCallback",void 0),(0,C.Cg)([l.observable],gn.prototype,"onCloseCallback",void 0),(0,C.Cg)([l.observable],gn.prototype,"isMaximized",void 0),(0,C.Cg)([l.observable],gn.prototype,"hasBeenResized",void 0),(0,C.Cg)([l.volatile],gn.prototype,"open",null),(0,C.Cg)([l.volatile],gn.prototype,"resizeIconName",null);class vn extends gn{show(){this.onShowCallback&&this.onShowCallback(),this.mainElement.show()}}const fn=vn.compose(Object.assign({baseName:"dialog",styles:ln,template:hn,shadowOptions:pn},mn)),bn=(e,t)=>l.css`
1511
1511
  ${(0,r.disclosureStyles)(e,t)}
1512
- `,yn=(e,t)=>(0,s.disclosureTemplate)(e,t);class wn extends s.Disclosure{}const Cn=void 0,xn={},$n=wn.compose(Object.assign({baseName:"disclosure",template:yn,styles:bn,shadowOptions:Cn},xn)),Sn=(e,t)=>l.css`
1512
+ `,yn=(e,t)=>(0,a.disclosureTemplate)(e,t);class wn extends a.Disclosure{}const Cn=void 0,xn={},$n=wn.compose(Object.assign({baseName:"disclosure",template:yn,styles:bn,shadowOptions:Cn},xn)),Sn=(e,t)=>l.css`
1513
1513
  ${(0,r.dividerStyles)(e,t)}
1514
- `,En=(e,t)=>(0,s.dividerTemplate)(e,t);class kn extends s.Divider{}const On=void 0,Tn={},In=kn.compose(Object.assign({baseName:"divider",template:En,styles:Sn,shadowOptions:On},Tn)),Dn=(e,t,i)=>l.css`
1514
+ `,En=(e,t)=>(0,a.dividerTemplate)(e,t);class kn extends a.Divider{}const On=void 0,Tn={},In=kn.compose(Object.assign({baseName:"divider",template:En,styles:Sn,shadowOptions:On},Tn)),Rn=(e,t,i)=>l.css`
1515
1515
  :host {
1516
1516
  --dropdown-opener-height-multiplier: 0.7px;
1517
1517
  --menu-item-height-multiplier: 0.7px;
@@ -1574,9 +1574,9 @@
1574
1574
  var(--menu-item-height-multiplier)
1575
1575
  );
1576
1576
  }
1577
- `,Rn=(e,t)=>l.css`
1578
- ${Dn("foundation",e,t)}
1579
- `,An=(e,t)=>l.html`
1577
+ `,An=(e,t)=>l.css`
1578
+ ${Rn("foundation",e,t)}
1579
+ `,Dn=(e,t)=>l.html`
1580
1580
  ${(0,l.repeat)(()=>e,l.html`
1581
1581
  ${(0,l.when)(e=>e.isDisabled&&e.isDisabled(),l.html`
1582
1582
  <${t}-menu-item class="menu-item" disabled>${e=>e.name}</${t}-menu-item>
@@ -1597,7 +1597,7 @@
1597
1597
  `)}
1598
1598
  ${e=>e.name}
1599
1599
  ${(0,l.when)(e=>e.submenu,l.html`
1600
- <${t}-menu>${e=>An(e.submenu,t)}</${t}-menu>
1600
+ <${t}-menu>${e=>Dn(e.submenu,t)}</${t}-menu>
1601
1601
  `)}
1602
1602
  </${t}-menu-item>
1603
1603
  `)}
@@ -1619,12 +1619,12 @@
1619
1619
  class="actions-menu ${e=>e.classNames}"
1620
1620
  part="actions-menu"
1621
1621
  >
1622
- ${t=>An(t.allItems,e)}
1622
+ ${t=>Dn(t.allItems,e)}
1623
1623
  </${e}-menu>
1624
1624
  </div>
1625
1625
  `,Ln=l.html`
1626
1626
  ${e=>Nn(O(e))}
1627
- `;class Fn extends s.FoundationElement{constructor(){super(...arguments),this.autoClose=!0,this.disabled=!1,this.name="Dropdown Menu",this.open=!1,this.clickOutside=e=>this.handleClickOutside(e)}connectedCallback(){super.connectedCallback(),this.addEventListener("onMenuClick",this.onDropdownMenuItemClick)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("mousedown",this.clickOutside)}handleClickOutside(e){E(e,this)&&(this.open=!1)}openChanged(){this.classNames=(0,x.x)(["hidden",!this.open]),this.open?document.addEventListener("mousedown",this.clickOutside):document.removeEventListener("mousedown",this.clickOutside)}toggleDropdownMenuVisibility(){this.open=!this.open}onDropdownMenuItemClick(){this.autoClose&&(this.open=!1)}get allItems(){return this.items}}(0,C.Cg)([l.observable],Fn.prototype,"items",void 0),(0,C.Cg)([(0,l.attr)({attribute:"auto-close",mode:"boolean"})],Fn.prototype,"autoClose",void 0),(0,C.Cg)([(0,l.attr)({attribute:"disable-button",mode:"boolean"})],Fn.prototype,"disabled",void 0),(0,C.Cg)([l.observable],Fn.prototype,"classNames",void 0),(0,C.Cg)([l.attr],Fn.prototype,"name",void 0),(0,C.Cg)([(0,l.attr)({attribute:"open",mode:"boolean"})],Fn.prototype,"open",void 0),(0,C.Cg)([l.attr],Fn.prototype,"buttonAppearance",void 0);const Mn=Fn.compose({baseName:"dropdown-menu",styles:Rn,template:Ln});var _n=i(84686);const Hn=l.css`
1627
+ `;class Fn extends a.FoundationElement{constructor(){super(...arguments),this.autoClose=!0,this.disabled=!1,this.name="Dropdown Menu",this.open=!1,this.clickOutside=e=>this.handleClickOutside(e)}connectedCallback(){super.connectedCallback(),this.addEventListener("onMenuClick",this.onDropdownMenuItemClick)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("mousedown",this.clickOutside)}handleClickOutside(e){E(e,this)&&(this.open=!1)}openChanged(){this.classNames=(0,x.x)(["hidden",!this.open]),this.open?document.addEventListener("mousedown",this.clickOutside):document.removeEventListener("mousedown",this.clickOutside)}toggleDropdownMenuVisibility(){this.open=!this.open}onDropdownMenuItemClick(){this.autoClose&&(this.open=!1)}get allItems(){return this.items}}(0,C.Cg)([l.observable],Fn.prototype,"items",void 0),(0,C.Cg)([(0,l.attr)({attribute:"auto-close",mode:"boolean"})],Fn.prototype,"autoClose",void 0),(0,C.Cg)([(0,l.attr)({attribute:"disable-button",mode:"boolean"})],Fn.prototype,"disabled",void 0),(0,C.Cg)([l.observable],Fn.prototype,"classNames",void 0),(0,C.Cg)([l.attr],Fn.prototype,"name",void 0),(0,C.Cg)([(0,l.attr)({attribute:"open",mode:"boolean"})],Fn.prototype,"open",void 0),(0,C.Cg)([l.attr],Fn.prototype,"buttonAppearance",void 0);const Mn=Fn.compose({baseName:"dropdown-menu",styles:An,template:Ln});var _n=i(84686);const Hn=l.css`
1628
1628
  .environment-indicator {
1629
1629
  font-size: 12px;
1630
1630
  display: inline-flex;
@@ -1676,7 +1676,7 @@
1676
1676
  </div>
1677
1677
  `)}
1678
1678
  `;var t}}
1679
- `;var zn=i(17190);const Un="default",Bn={level:Un,showIcon:!1,iconSize:"sm",backgroundColor:"#2222ff",textColor:"#ffffff",label:"DEFAULT"},Wn=[Bn,{level:"dev",showIcon:!1,icon:"code",backgroundColor:"#ff6b35",label:"DEV"},{level:"prod",showIcon:!1,icon:"check-circle",backgroundColor:"#28a745",label:"PROD"}],Gn=(0,zn.r)(),jn=s.DI.createInterface(e=>e.instance(Gn),e=>e.instance(Gn)),Vn=s.DI.createInterface("EnvironmentIndicatorConfig");function Yn(){return(0,C.sH)(this,arguments,void 0,function*(e={configs:[]}){const{configs:t,currentLevel:i}=e,o={currentLevel:i,configs:t&&t.length>0?t:[Bn]};s.DI.getOrCreateDOMContainer().register(s.Registration.instance(jn,Gn),s.Registration.instance(Vn,o)),Gn.publish(o)})}const qn=(0,Ke.createLogger)("EnvironmentIndicator");class Kn extends s.FoundationElement{constructor(){super(...arguments),this.size="sm",this.textColor="#ffffff",this.icon="check-circle",this.iconSize="sm",this.useDefaultConfig=!1,this.config=Bn,this.envConfigs=Wn}envConfigsChanged(){this.config=this.getEnvConfigByLevel()}diConfigChanged(){this.config=this.getEnvConfigByLevel()}subscribeToDiConfig(){const e=s.DI.getOrCreateDOMContainer().get(jn);e&&"function"==typeof e.subscribe?this.unsubscribeConfig=e.subscribe(e=>{this.diConfig=e}):qn.error("Observer not found or invalid in DI container")}connectedCallback(){super.connectedCallback(),this.diConfig=function(){try{const e=s.DI.getOrCreateDOMContainer().get(Vn);if(e)return e}catch(e){return}}(),this.subscribeToDiConfig(),this.config=this.getEnvConfigByLevel()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeConfig&&(this.unsubscribeConfig(),this.unsubscribeConfig=void 0)}getAttributesConfig(){const e={};return["label","size","showIcon","icon","iconSize","backgroundColor","textColor"].filter(e=>!!this[e]).forEach(t=>{e[t]=this[t]}),e||{}}getCurrentEnvironmentLevel(){if(this.level)return this.level;if(this.diConfig)try{const{currentLevel:e}=this.diConfig;if(e)return e}catch(e){qn.error(e)}return _n.H6!==Un?_n.H6:this.useDefaultConfig?Un:void 0}getEnvConfigByLevel(){const e=this.getAttributesConfig(),t=this.getCurrentEnvironmentLevel();if(!t)return this.useDefaultConfig?Bn:void 0;if(this.label)return Object.assign(Object.assign(Object.assign({},Bn),{level:t}),e);if(this.diConfig){const{configs:i}=this.diConfig;if(i&&i.length>0){const o=i.find(({level:e})=>e===t);if(o)return Object.assign(Object.assign({},o),e)}}const i=this.envConfigs.find(({level:e})=>e===t);return i?Object.assign(Object.assign({},i),e):void 0}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i);["level","label","show-icon","icon-size","size","background-color","text-color","icon"].includes(e)&&t!==i&&(this.config=this.getEnvConfigByLevel())}setEnvConfigs(e){this.envConfigs=e}}(0,C.Cg)([l.attr],Kn.prototype,"level",void 0),(0,C.Cg)([l.attr],Kn.prototype,"label",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"show-icon"})],Kn.prototype,"showIcon",void 0),(0,C.Cg)([l.attr],Kn.prototype,"size",void 0),(0,C.Cg)([(0,l.attr)({attribute:"background-color"})],Kn.prototype,"backgroundColor",void 0),(0,C.Cg)([(0,l.attr)({attribute:"text-color"})],Kn.prototype,"textColor",void 0),(0,C.Cg)([l.attr],Kn.prototype,"icon",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-size"})],Kn.prototype,"iconSize",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"use-default-config"})],Kn.prototype,"useDefaultConfig",void 0),(0,C.Cg)([l.observable],Kn.prototype,"config",void 0),(0,C.Cg)([l.observable],Kn.prototype,"envConfigs",void 0),(0,C.Cg)([l.observable],Kn.prototype,"diConfig",void 0);const Xn=Kn.compose({baseName:"environment-indicator",template:Pn,styles:Hn}),Qn=e=>l.html`
1679
+ `;var zn=i(17190);const Un="default",Wn={level:Un,showIcon:!1,iconSize:"sm",backgroundColor:"#2222ff",textColor:"#ffffff",label:"DEFAULT"},Gn=[Wn,{level:"dev",showIcon:!1,icon:"code",backgroundColor:"#ff6b35",label:"DEV"},{level:"prod",showIcon:!1,icon:"check-circle",backgroundColor:"#28a745",label:"PROD"}],Bn=(0,zn.r)(),Vn=a.DI.createInterface(e=>e.instance(Bn),e=>e.instance(Bn)),jn=a.DI.createInterface("EnvironmentIndicatorConfig");function Yn(){return(0,C.sH)(this,arguments,void 0,function*(e={configs:[]}){const{configs:t,currentLevel:i}=e,o={currentLevel:i,configs:t&&t.length>0?t:[Wn]};a.DI.getOrCreateDOMContainer().register(a.Registration.instance(Vn,Bn),a.Registration.instance(jn,o)),Bn.publish(o)})}const qn=(0,Ke.createLogger)("EnvironmentIndicator");class Kn extends a.FoundationElement{constructor(){super(...arguments),this.size="sm",this.textColor="#ffffff",this.icon="check-circle",this.iconSize="sm",this.useDefaultConfig=!1,this.config=Wn,this.envConfigs=Gn}envConfigsChanged(){this.config=this.getEnvConfigByLevel()}diConfigChanged(){this.config=this.getEnvConfigByLevel()}subscribeToDiConfig(){const e=a.DI.getOrCreateDOMContainer().get(Vn);e&&"function"==typeof e.subscribe?this.unsubscribeConfig=e.subscribe(e=>{this.diConfig=e}):qn.error("Observer not found or invalid in DI container")}connectedCallback(){super.connectedCallback(),this.diConfig=function(){try{const e=a.DI.getOrCreateDOMContainer().get(jn);if(e)return e}catch(e){return}}(),this.subscribeToDiConfig(),this.config=this.getEnvConfigByLevel()}disconnectedCallback(){super.disconnectedCallback(),this.unsubscribeConfig&&(this.unsubscribeConfig(),this.unsubscribeConfig=void 0)}getAttributesConfig(){const e={};return["label","size","showIcon","icon","iconSize","backgroundColor","textColor"].filter(e=>!!this[e]).forEach(t=>{e[t]=this[t]}),e||{}}getCurrentEnvironmentLevel(){if(this.level)return this.level;if(this.diConfig)try{const{currentLevel:e}=this.diConfig;if(e)return e}catch(e){qn.error(e)}return _n.H6!==Un?_n.H6:this.useDefaultConfig?Un:void 0}getEnvConfigByLevel(){const e=this.getAttributesConfig(),t=this.getCurrentEnvironmentLevel();if(!t)return this.useDefaultConfig?Wn:void 0;if(this.label)return Object.assign(Object.assign(Object.assign({},Wn),{level:t}),e);if(this.diConfig){const{configs:i}=this.diConfig;if(i&&i.length>0){const o=i.find(({level:e})=>e===t);if(o)return Object.assign(Object.assign({},o),e)}}const i=this.envConfigs.find(({level:e})=>e===t);return i?Object.assign(Object.assign({},i),e):void 0}attributeChangedCallback(e,t,i){super.attributeChangedCallback(e,t,i);["level","label","show-icon","icon-size","size","background-color","text-color","icon"].includes(e)&&t!==i&&(this.config=this.getEnvConfigByLevel())}setEnvConfigs(e){this.envConfigs=e}}(0,C.Cg)([l.attr],Kn.prototype,"level",void 0),(0,C.Cg)([l.attr],Kn.prototype,"label",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"show-icon"})],Kn.prototype,"showIcon",void 0),(0,C.Cg)([l.attr],Kn.prototype,"size",void 0),(0,C.Cg)([(0,l.attr)({attribute:"background-color"})],Kn.prototype,"backgroundColor",void 0),(0,C.Cg)([(0,l.attr)({attribute:"text-color"})],Kn.prototype,"textColor",void 0),(0,C.Cg)([l.attr],Kn.prototype,"icon",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-size"})],Kn.prototype,"iconSize",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"use-default-config"})],Kn.prototype,"useDefaultConfig",void 0),(0,C.Cg)([l.observable],Kn.prototype,"config",void 0),(0,C.Cg)([l.observable],Kn.prototype,"envConfigs",void 0),(0,C.Cg)([l.observable],Kn.prototype,"diConfig",void 0);const Xn=Kn.compose({baseName:"environment-indicator",template:Pn,styles:Hn}),Qn=e=>l.html`
1680
1680
  <${e}-banner ${(0,l.ref)("banner")}>
1681
1681
  <div slot="content">
1682
1682
  <div>
@@ -1685,7 +1685,7 @@
1685
1685
  </div>
1686
1686
 
1687
1687
  <${e}-button slot="action" appearance="lightweight" @click=${e=>e.dismiss()}>
1688
- ${e=>{var t,i,o,n,a,s,r,l;return(null===(n=null===(o=null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.banner)||void 0===o?void 0:o.dismissingAction)||void 0===n?void 0:n.label)||(null===(l=null===(r=null===(s=null===(a=e.notification)||void 0===a?void 0:a.config)||void 0===s?void 0:s.banner)||void 0===r?void 0:r.dismissingAction)||void 0===l?void 0:l.label)||"Ignore"}}
1688
+ ${e=>{var t,i,o,n,s,a,r,l;return(null===(n=null===(o=null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.banner)||void 0===o?void 0:o.dismissingAction)||void 0===n?void 0:n.label)||(null===(l=null===(r=null===(a=null===(s=e.notification)||void 0===s?void 0:s.config)||void 0===a?void 0:a.banner)||void 0===r?void 0:r.dismissingAction)||void 0===l?void 0:l.label)||"Ignore"}}
1689
1689
  </${e}-button>
1690
1690
  ${(0,l.repeat)(e=>{var t,i,o,n;return(null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.banner.confirmingActions)||(null===(n=null===(o=e.notification)||void 0===o?void 0:o.config)||void 0===n?void 0:n.banner.confirmingActions)},l.html`
1691
1691
  <${e}-button
@@ -1699,11 +1699,11 @@
1699
1699
  </${e}-banner>
1700
1700
  `,Jn=l.html`
1701
1701
  ${e=>Qn(O(e))}
1702
- `,Zn={mode:"open",delegatesFocus:!0};class ea extends s.FoundationElement{connectedCallback(){super.connectedCallback(),Xe.deprecated("ErrorBanner","Use `${prefix}-banner` instead.")}dismiss(){return(0,C.sH)(this,void 0,void 0,function*(){try{yield this.banner.dismiss(),this.remove()}catch(e){Xe.error(e)}})}}(0,C.Cg)([l.observable],ea.prototype,"error",void 0),(0,C.Cg)([l.observable],ea.prototype,"notification",void 0);const ta=ea.compose({baseName:"error-banner",template:Jn,shadowOptions:Zn});var ia;!function(e){e.ERROR_BOUNDARY_EVENT="error-boundary-event"}(ia||(ia={}));const oa=e=>{var t,i;return`${null!==(t=null==e?void 0:e.title)&&void 0!==t?t:"Error"}: ${null!==(i=null==e?void 0:e.errorDetails)&&void 0!==i?i:"Something went wrong"}`},na=e=>{var t;return(null==e?void 0:e.logLevel)||(null===(t=null==e?void 0:e.config)||void 0===t?void 0:t.logLevel)||Ke.LogLevel.Error},aa=(e,t)=>{const i=t.split("-")[0];let o=document.querySelector(`#${e}`);if(!o){o=document.createElement("div"),o.setAttribute("id",e);const t=document.createElement(`${i}-design-system-provider`);t.appendChild(o),document.body.appendChild(t)}return o},sa=()=>{const e=document.createElement("div");return e.setAttribute("id","error-banner-anchor"),e.style.position="relative",document.body.insertBefore(e,document.body.firstChild),e},ra=(0,Ke.createLogger)("foundation-error"),la={alert:e=>{alert(oa(e))},notification:(e,t)=>{var i,o,n,a,s,r,l,d,c,u,h,p,m;const v=t.split("-")[0],g=aa("notify-container",t);if(g)switch(g.style.position="fixed",null===(o=null===(i=null==e?void 0:e.config)||void 0===i?void 0:i.notification)||void 0===o?void 0:o.position){case"top-left":g.style.top="0",g.style.left="0";break;case"bottom-left":g.style.bottom="0",g.style.left="0";break;case"bottom-right":g.style.bottom="0",g.style.right="0";break;default:g.style.top="0",g.style.right="0"}const f=document.createElement(`${v}-toast`),b=document.createElement("div");b.setAttribute("slot","top"),b.textContent=null!==(n=e.title)&&void 0!==n?n:"Error";const y=document.createElement("div");y.setAttribute("slot","content"),y.textContent=(null==e?void 0:e.errorDetails)||"";const w=document.createElement("div");w.setAttribute("slot","date"),w.textContent=(new Date).toLocaleTimeString(),f.setAttribute("notify",(null===(s=null===(a=null==e?void 0:e.config)||void 0===a?void 0:a.notification)||void 0===s?void 0:s.type)||""),(null===(l=null===(r=null==e?void 0:e.config)||void 0===r?void 0:r.notification)||void 0===l?void 0:l.autoClose)&&f.setAttribute("auto-close",`${null===(c=null===(d=null==e?void 0:e.config)||void 0===d?void 0:d.notification)||void 0===c?void 0:c.autoClose}`),(null===(h=null===(u=null==e?void 0:e.config)||void 0===u?void 0:u.notification)||void 0===h?void 0:h.closeTimeout)&&f.setAttribute("close-timeout",`${null===(m=null===(p=null==e?void 0:e.config)||void 0===p?void 0:p.notification)||void 0===m?void 0:m.closeTimeout}`),f.appendChild(b),f.appendChild(y),f.appendChild(w),g.appendChild(f)},dialog:(e,t)=>{const i=t.split("-")[0],o=document.createElement(`${i}-error-dialog`);aa("dialog-container",t).appendChild(o),o.error=e,o.show()},snackbar:(e,t)=>{const i=t.split("-")[0],o=document.createElement(`${i}-snackbar`);aa("snack-container",t).appendChild(o),o.error=e},banner:(e,t,i)=>{var o;const n=t.split("-")[0],a=document.createElement(`${n}-error-banner`),s=(e=>{for(var t,i;e&&!(e instanceof ShadowRoot);){const o=null===(t=null==e?void 0:e.getRootNode())||void 0===t?void 0:t.getElementById("error-banner-anchor");if(o)return o.style.position="relative",o;e=null===(i=null==e?void 0:e.getRootNode())||void 0===i?void 0:i.host}return sa()})(i);(null===(o=null==s?void 0:s.children)||void 0===o?void 0:o.length)>0&&(a.style.position="absolute",a.style.top="0",a.style.left="0",a.style.width="100%"),s.appendChild(a),a.error=e}},da=(e,t,i)=>{ra.log({message:oa(e),level:na(e)});Object.keys((null==e?void 0:e.config)||{}).forEach(o=>{la[o]&&la[o](e,t,i)})};class ca{withTitle(e){return this.title=e,this}withErrorDetails(e){return this.errorDetails=e,this}withLogLevel(e){return this.logLevel=e,this}withAlert(e){return this.alert=e,this}withNotification(e){return this.notification=e,this}withBanner(e){return this.banner=e,this}withSnackbar(e){return this.snackbar=e,this}withDialog(e){return this.dialog=e,this}build(){if(!this.title)throw new Error("Title is required");if(!this.errorDetails)throw new Error("Missing required param 'errorDetails'");let e={title:this.title,errorDetails:this.errorDetails},t={};return this.logLevel in Ke.LogLevel&&(e=Object.assign({logLevel:this.logLevel},e)),this.alert&&(t=Object.assign({alert:this.alert},t),e=Object.assign({config:t},e)),this.notification&&(t=Object.assign({notification:this.notification},t),e=Object.assign({config:t},e)),this.banner&&(t=Object.assign({banner:this.banner},t),e=Object.assign({config:t},e)),this.snackbar&&(t=Object.assign({snackbar:this.snackbar},t),e=Object.assign({config:t},e)),this.dialog&&(t=Object.assign({dialog:this.dialog},t),e=Object.assign({config:t},e)),e}}class ua{withPosition(e){return this.position=e,this}withAutoClose(e){return this.autoClose=e,this}withCloseTimeout(e){return this.closeTimeout=e,this}withType(e){return this.type=e,this}build(){let e={};return this.position&&(e=Object.assign({position:this.position},e)),this.autoClose&&(e=Object.assign({autoClose:this.autoClose},e)),this.closeTimeout&&(e=Object.assign({closeTimeout:this.closeTimeout},e)),this.type&&(e=Object.assign({type:this.type},e)),e}}const ha=l.html`
1702
+ `,Zn={mode:"open",delegatesFocus:!0};class es extends a.FoundationElement{connectedCallback(){super.connectedCallback(),Xe.deprecated("ErrorBanner","Use `${prefix}-banner` instead.")}dismiss(){return(0,C.sH)(this,void 0,void 0,function*(){try{yield this.banner.dismiss(),this.remove()}catch(e){Xe.error(e)}})}}(0,C.Cg)([l.observable],es.prototype,"error",void 0),(0,C.Cg)([l.observable],es.prototype,"notification",void 0);const ts=es.compose({baseName:"error-banner",template:Jn,shadowOptions:Zn});var is;!function(e){e.ERROR_BOUNDARY_EVENT="error-boundary-event"}(is||(is={}));const os=e=>{var t,i;return`${null!==(t=null==e?void 0:e.title)&&void 0!==t?t:"Error"}: ${null!==(i=null==e?void 0:e.errorDetails)&&void 0!==i?i:"Something went wrong"}`},ns=e=>{var t;return(null==e?void 0:e.logLevel)||(null===(t=null==e?void 0:e.config)||void 0===t?void 0:t.logLevel)||Ke.LogLevel.Error},ss=(e,t)=>{const i=t.split("-")[0];let o=document.querySelector(`#${e}`);if(!o){o=document.createElement("div"),o.setAttribute("id",e);const t=document.createElement(`${i}-design-system-provider`);t.appendChild(o),document.body.appendChild(t)}return o},as=()=>{const e=document.createElement("div");return e.setAttribute("id","error-banner-anchor"),e.style.position="relative",document.body.insertBefore(e,document.body.firstChild),e},rs=(0,Ke.createLogger)("foundation-error"),ls={alert:e=>{alert(os(e))},notification:(e,t)=>{var i,o,n,s,a,r,l,d,c,u,h,p,m;const g=t.split("-")[0],v=ss("notify-container",t);if(v)switch(v.style.position="fixed",null===(o=null===(i=null==e?void 0:e.config)||void 0===i?void 0:i.notification)||void 0===o?void 0:o.position){case"top-left":v.style.top="0",v.style.left="0";break;case"bottom-left":v.style.bottom="0",v.style.left="0";break;case"bottom-right":v.style.bottom="0",v.style.right="0";break;default:v.style.top="0",v.style.right="0"}const f=document.createElement(`${g}-toast`),b=document.createElement("div");b.setAttribute("slot","top"),b.textContent=null!==(n=e.title)&&void 0!==n?n:"Error";const y=document.createElement("div");y.setAttribute("slot","content"),y.textContent=(null==e?void 0:e.errorDetails)||"";const w=document.createElement("div");w.setAttribute("slot","date"),w.textContent=(new Date).toLocaleTimeString(),f.setAttribute("notify",(null===(a=null===(s=null==e?void 0:e.config)||void 0===s?void 0:s.notification)||void 0===a?void 0:a.type)||""),(null===(l=null===(r=null==e?void 0:e.config)||void 0===r?void 0:r.notification)||void 0===l?void 0:l.autoClose)&&f.setAttribute("auto-close",`${null===(c=null===(d=null==e?void 0:e.config)||void 0===d?void 0:d.notification)||void 0===c?void 0:c.autoClose}`),(null===(h=null===(u=null==e?void 0:e.config)||void 0===u?void 0:u.notification)||void 0===h?void 0:h.closeTimeout)&&f.setAttribute("close-timeout",`${null===(m=null===(p=null==e?void 0:e.config)||void 0===p?void 0:p.notification)||void 0===m?void 0:m.closeTimeout}`),f.appendChild(b),f.appendChild(y),f.appendChild(w),v.appendChild(f)},dialog:(e,t)=>{const i=t.split("-")[0],o=document.createElement(`${i}-error-dialog`);ss("dialog-container",t).appendChild(o),o.error=e,o.show()},snackbar:(e,t)=>{const i=t.split("-")[0],o=document.createElement(`${i}-snackbar`);ss("snack-container",t).appendChild(o),o.error=e},banner:(e,t,i)=>{var o;const n=t.split("-")[0],s=document.createElement(`${n}-error-banner`),a=(e=>{for(var t,i;e&&!(e instanceof ShadowRoot);){const o=null===(t=null==e?void 0:e.getRootNode())||void 0===t?void 0:t.getElementById("error-banner-anchor");if(o)return o.style.position="relative",o;e=null===(i=null==e?void 0:e.getRootNode())||void 0===i?void 0:i.host}return as()})(i);(null===(o=null==a?void 0:a.children)||void 0===o?void 0:o.length)>0&&(s.style.position="absolute",s.style.top="0",s.style.left="0",s.style.width="100%"),a.appendChild(s),s.error=e}},ds=(e,t,i)=>{rs.log({message:os(e),level:ns(e)});Object.keys((null==e?void 0:e.config)||{}).forEach(o=>{ls[o]&&ls[o](e,t,i)})};class cs{withTitle(e){return this.title=e,this}withErrorDetails(e){return this.errorDetails=e,this}withLogLevel(e){return this.logLevel=e,this}withAlert(e){return this.alert=e,this}withNotification(e){return this.notification=e,this}withBanner(e){return this.banner=e,this}withSnackbar(e){return this.snackbar=e,this}withDialog(e){return this.dialog=e,this}build(){if(!this.title)throw new Error("Title is required");if(!this.errorDetails)throw new Error("Missing required param 'errorDetails'");let e={title:this.title,errorDetails:this.errorDetails},t={};return this.logLevel in Ke.LogLevel&&(e=Object.assign({logLevel:this.logLevel},e)),this.alert&&(t=Object.assign({alert:this.alert},t),e=Object.assign({config:t},e)),this.notification&&(t=Object.assign({notification:this.notification},t),e=Object.assign({config:t},e)),this.banner&&(t=Object.assign({banner:this.banner},t),e=Object.assign({config:t},e)),this.snackbar&&(t=Object.assign({snackbar:this.snackbar},t),e=Object.assign({config:t},e)),this.dialog&&(t=Object.assign({dialog:this.dialog},t),e=Object.assign({config:t},e)),e}}class us{withPosition(e){return this.position=e,this}withAutoClose(e){return this.autoClose=e,this}withCloseTimeout(e){return this.closeTimeout=e,this}withType(e){return this.type=e,this}build(){let e={};return this.position&&(e=Object.assign({position:this.position},e)),this.autoClose&&(e=Object.assign({autoClose:this.autoClose},e)),this.closeTimeout&&(e=Object.assign({closeTimeout:this.closeTimeout},e)),this.type&&(e=Object.assign({type:this.type},e)),e}}const hs=l.html`
1703
1703
  <template ${(0,l.ref)("errorBoundary")}>
1704
1704
  <slot></slot>
1705
1705
  </template>
1706
- `,pa={mode:"open",delegatesFocus:!0};class ma extends s.FoundationElement{constructor(){super(...arguments),this.logger=(0,Ke.createLogger)("error-boundary"),this.closeTimeout=0}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){var t;if(e.connectedCallback.call(this),this.addEventListener(ia.ERROR_BOUNDARY_EVENT,e=>{e.stopImmediatePropagation(),da(e.detail,this.tagName,this.errorBoundary)}),this.resourceName){if(!(yield this.datasource.init({resourceName:this.resourceName},!0)))return void Xe.debug(`Genesis Datasource init failed for ${this.resourceName}`);this.dataSub=null===(t=this.datasource.stream)||void 0===t?void 0:t.subscribe(e=>{if(!e.ROW)return;const t=null==e?void 0:e.ROW[0];if(e.SEQUENCE_ID>1){const e=t.HEADER,i=null==t?void 0:t.BODY,o=t.NOTIFY_SEVERITY;da((new ca).withTitle(e).withErrorDetails(i).withNotification((new ua).withType(o).withAutoClose(!!this.closeTimeout).withCloseTimeout(this.closeTimeout).build()).build(),this.tagName,this.errorBoundary)}})}})}disconnectedCallback(){var e,t;super.disconnectedCallback(),null===(e=this.dataSub)||void 0===e||e.unsubscribe(),delete this.dataSub,null===(t=this.datasource)||void 0===t||t.destroy(),delete this.datasource}}(0,C.Cg)([l.observable],ma.prototype,"errorBoundary",void 0),(0,C.Cg)([(0,l.attr)({attribute:"resource-name"})],ma.prototype,"resourceName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"close-timeout",converter:l.nullableNumberConverter})],ma.prototype,"closeTimeout",void 0),(0,C.Cg)([oi.yW],ma.prototype,"datasource",void 0);const va=ma.compose({baseName:"error-boundary",template:ha,shadowOptions:pa}),ga=l.css`
1706
+ `,ps={mode:"open",delegatesFocus:!0};class ms extends a.FoundationElement{constructor(){super(...arguments),this.logger=(0,Ke.createLogger)("error-boundary"),this.closeTimeout=0}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){var t;if(e.connectedCallback.call(this),this.addEventListener(is.ERROR_BOUNDARY_EVENT,e=>{e.stopImmediatePropagation(),ds(e.detail,this.tagName,this.errorBoundary)}),this.resourceName){if(!(yield this.datasource.init({resourceName:this.resourceName},!0)))return void Xe.debug(`Genesis Datasource init failed for ${this.resourceName}`);this.dataSub=null===(t=this.datasource.stream)||void 0===t?void 0:t.subscribe(e=>{if(!e.ROW)return;const t=null==e?void 0:e.ROW[0];if(e.SEQUENCE_ID>1){const e=t.HEADER,i=null==t?void 0:t.BODY,o=t.NOTIFY_SEVERITY;ds((new cs).withTitle(e).withErrorDetails(i).withNotification((new us).withType(o).withAutoClose(!!this.closeTimeout).withCloseTimeout(this.closeTimeout).build()).build(),this.tagName,this.errorBoundary)}})}})}disconnectedCallback(){var e,t;super.disconnectedCallback(),null===(e=this.dataSub)||void 0===e||e.unsubscribe(),delete this.dataSub,null===(t=this.datasource)||void 0===t||t.destroy(),delete this.datasource}}(0,C.Cg)([l.observable],ms.prototype,"errorBoundary",void 0),(0,C.Cg)([(0,l.attr)({attribute:"resource-name"})],ms.prototype,"resourceName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"close-timeout",converter:l.nullableNumberConverter})],ms.prototype,"closeTimeout",void 0),(0,C.Cg)([oi.yW],ms.prototype,"datasource",void 0);const gs=ms.compose({baseName:"error-boundary",template:hs,shadowOptions:ps}),vs=l.css`
1707
1707
  :host {
1708
1708
  --design-unit: 3;
1709
1709
  --dialog-max-width: 358px;
@@ -1722,12 +1722,12 @@
1722
1722
  overflow: hidden;
1723
1723
  min-height: var(--error-details-min-height);
1724
1724
  }
1725
- `,fa=e=>l.html`
1725
+ `,fs=e=>l.html`
1726
1726
  <${e}-dialog show-close-icon="false" ${(0,l.ref)("dialog")}>
1727
1727
  <h2 slot="top" class="title">${e=>{var t;return null===(t=e.error)||void 0===t?void 0:t.title}}</h2>
1728
1728
  <div class="details">${e=>{var t,i;return(null===(t=e.error)||void 0===t?void 0:t.errorDetails)||(null===(i=e.notification)||void 0===i?void 0:i.body)||"Place holder for error message"}}</div>
1729
1729
  <${e}-button slot="bottom" appearance="lightweight" @click=${e=>{e.dismiss()}}>
1730
- ${e=>{var t,i,o,n,a,s,r,l;return(null===(n=null===(o=null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.dialog)||void 0===o?void 0:o.dismissingAction)||void 0===n?void 0:n.label)||(null===(l=null===(r=null===(s=null===(a=e.notification)||void 0===a?void 0:a.config)||void 0===s?void 0:s.dialog)||void 0===r?void 0:r.dismissingAction)||void 0===l?void 0:l.label)||"Ignore"}}
1730
+ ${e=>{var t,i,o,n,s,a,r,l;return(null===(n=null===(o=null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.dialog)||void 0===o?void 0:o.dismissingAction)||void 0===n?void 0:n.label)||(null===(l=null===(r=null===(a=null===(s=e.notification)||void 0===s?void 0:s.config)||void 0===a?void 0:a.dialog)||void 0===r?void 0:r.dismissingAction)||void 0===l?void 0:l.label)||"Ignore"}}
1731
1731
  </${e}-button>
1732
1732
  ${(0,l.repeat)(e=>{var t,i,o,n;return(null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.dialog.confirmingActions)||(null===(n=null===(o=e.notification)||void 0===o?void 0:o.config)||void 0===n?void 0:n.dialog.confirmingActions)},l.html`
1733
1733
  <${e}-button
@@ -1739,9 +1739,9 @@
1739
1739
  </${e}-button>
1740
1740
  `)}
1741
1741
  </${e}-dialog>
1742
- `,ba=l.html`
1743
- ${e=>fa(O(e))}
1744
- `,ya={mode:"open",delegatesFocus:!0};class wa extends s.FoundationElement{connectedCallback(){super.connectedCallback(),Xe.deprecated("ErrorDialog","Use `${prefix}-dialog` instead.")}show(){this.dialog.show()}dismiss(){var e,t,i,o,n,a,s,r;(null===(o=null===(i=null===(t=null===(e=this.error)||void 0===e?void 0:e.config)||void 0===t?void 0:t.dialog)||void 0===i?void 0:i.dismissingAction)||void 0===o?void 0:o.action)&&this.error.config.dialog.dismissingAction.action(),(null===(r=null===(s=null===(a=null===(n=this.notification)||void 0===n?void 0:n.config)||void 0===a?void 0:a.dialog)||void 0===s?void 0:s.dismissingAction)||void 0===r?void 0:r.action)&&this.notification.config.dialog.dismissingAction.action(),this.closeDialog()}closeDialog(){try{this.dialog.close(),this.remove()}catch(e){Xe.error(e)}}}(0,C.Cg)([l.observable],wa.prototype,"error",void 0),(0,C.Cg)([l.observable],wa.prototype,"notification",void 0);const Ca=wa.compose({baseName:"error-dialog",template:ba,styles:ga,shadowOptions:ya});class xa extends s.FoundationElement{constructor(){super(...arguments),this.selectedFile=null,this.accept="",this.fileSizeLimitBytes=10485760,this.fileName="",this.isProcessing=!1}handleClick(){this.fileInput.value=null,this.fileInput.click()}onInputChange(e){var t;const i=null==e?void 0:e.target,o=Array.from(null!==(t=null==i?void 0:i.files)&&void 0!==t?t:[]),n=o.find(e=>e.size>this.fileSizeLimitBytes);if(n){const e=`File "${n.name}" exceeds size limit of ${this.fileSizeLimitBytes} bytes`;return this.showError("File Size Error",e),void this.$emit("error",new Error(e))}this.onFileSelected(o)}clearSelection(){this.fileName="",this.selectedFile=null,this.isProcessing=!1,this.fileInput&&(this.fileInput.value=""),this.onFileCleared(),this.$emit("clear")}getSelectedFile(){return this.selectedFile}showError(e,t){me({title:e,body:t,config:{toast:{type:"warning",autoClose:!0,closeTimeout:5e3}}},this.tagName)}}(0,C.Cg)([l.attr],xa.prototype,"label",void 0),(0,C.Cg)([l.attr],xa.prototype,"accept",void 0),(0,C.Cg)([(0,l.attr)({attribute:"file-size-limit-bytes"})],xa.prototype,"fileSizeLimitBytes",void 0),(0,C.Cg)([l.observable],xa.prototype,"fileName",void 0),(0,C.Cg)([l.observable],xa.prototype,"isProcessing",void 0);const $a=(e,t,i)=>l.css`
1742
+ `,bs=l.html`
1743
+ ${e=>fs(O(e))}
1744
+ `,ys={mode:"open",delegatesFocus:!0};class ws extends a.FoundationElement{connectedCallback(){super.connectedCallback(),Xe.deprecated("ErrorDialog","Use `${prefix}-dialog` instead.")}show(){this.dialog.show()}dismiss(){var e,t,i,o,n,s,a,r;(null===(o=null===(i=null===(t=null===(e=this.error)||void 0===e?void 0:e.config)||void 0===t?void 0:t.dialog)||void 0===i?void 0:i.dismissingAction)||void 0===o?void 0:o.action)&&this.error.config.dialog.dismissingAction.action(),(null===(r=null===(a=null===(s=null===(n=this.notification)||void 0===n?void 0:n.config)||void 0===s?void 0:s.dialog)||void 0===a?void 0:a.dismissingAction)||void 0===r?void 0:r.action)&&this.notification.config.dialog.dismissingAction.action(),this.closeDialog()}closeDialog(){try{this.dialog.close(),this.remove()}catch(e){Xe.error(e)}}}(0,C.Cg)([l.observable],ws.prototype,"error",void 0),(0,C.Cg)([l.observable],ws.prototype,"notification",void 0);const Cs=ws.compose({baseName:"error-dialog",template:bs,styles:vs,shadowOptions:ys});class xs extends a.FoundationElement{constructor(){super(...arguments),this.selectedFile=null,this.accept="",this.fileSizeLimitBytes=10485760,this.fileName="",this.isProcessing=!1}handleClick(){this.fileInput.value=null,this.fileInput.click()}onInputChange(e){var t;const i=null==e?void 0:e.target,o=Array.from(null!==(t=null==i?void 0:i.files)&&void 0!==t?t:[]),n=o.find(e=>e.size>this.fileSizeLimitBytes);if(n){const e=`File "${n.name}" exceeds size limit of ${this.fileSizeLimitBytes} bytes`;return this.showError("File Size Error",e),void this.$emit("error",new Error(e))}this.onFileSelected(o)}clearSelection(){this.fileName="",this.selectedFile=null,this.isProcessing=!1,this.fileInput&&(this.fileInput.value=""),this.onFileCleared(),this.$emit("clear")}getSelectedFile(){return this.selectedFile}showError(e,t){me({title:e,body:t,config:{toast:{type:"warning",autoClose:!0,closeTimeout:5e3}}},this.tagName)}}(0,C.Cg)([l.attr],xs.prototype,"label",void 0),(0,C.Cg)([l.attr],xs.prototype,"accept",void 0),(0,C.Cg)([(0,l.attr)({attribute:"file-size-limit-bytes"})],xs.prototype,"fileSizeLimitBytes",void 0),(0,C.Cg)([l.observable],xs.prototype,"fileName",void 0),(0,C.Cg)([l.observable],xs.prototype,"isProcessing",void 0);const $s=(e,t,i)=>l.css`
1745
1745
  /* Host */
1746
1746
  :host {
1747
1747
  display: flex;
@@ -1791,9 +1791,9 @@
1791
1791
  justify-content: center;
1792
1792
  z-index: 2;
1793
1793
  }
1794
- `,Sa=(e,t)=>l.css`
1795
- ${$a("foundation",e,t)}
1796
- `,Ea=e=>l.html`
1794
+ `,Ss=(e,t)=>l.css`
1795
+ ${$s("foundation",e,t)}
1796
+ `,Es=e=>l.html`
1797
1797
  <template>
1798
1798
  <div class="file-reader">
1799
1799
  ${(0,l.when)(e=>e.isProcessing,l.html`
@@ -1829,9 +1829,9 @@
1829
1829
  `)}
1830
1830
  </div>
1831
1831
  </template>
1832
- `,ka=l.html`
1833
- ${e=>Ea(O(e))}
1834
- `;class Oa extends xa{constructor(){super(),this.processingTimeout=null,this.autoProcess=!1,this.processingDelayMs=1e3,this.fileContent=null,this.accept=".json,application/json"}onFileSelected(e){var t,i;const o=e[0];if(o&&this.accept.includes("json")&&!(null===(i=null===(t=null==o?void 0:o.name)||void 0===t?void 0:t.toLowerCase())||void 0===i?void 0:i.endsWith(".json"))){const e="Selected file is not a JSON file";return this.showError("File Type Error",e),void this.$emit("error",new Error(e))}this.selectedFile=o,this.fileName=o.name,this.autoProcess&&this.handleFileProcessing()}onFileCleared(){this.fileContent=null,this.processingTimeout&&(clearTimeout(this.processingTimeout),this.processingTimeout=null)}handleFileProcessing(){return(0,C.sH)(this,void 0,void 0,function*(){var e;if(this.getSelectedFile()){this.processingTimeout&&clearTimeout(this.processingTimeout),this.isProcessing=!0;try{const t=yield this.getSelectedFile().text();let i;try{i=JSON.parse(t)}catch(e){return this.showError("Invalid JSON Format","The selected file contains invalid JSON"),void this.$emit("error",e)}this.fileContent=i,this.$emit("file-read",{fileName:this.fileName,content:this.fileContent,file:this.getSelectedFile()}),null===(e=this.onFileRead)||void 0===e||e.call(this,this.fileContent)}catch(e){this.showError("File Processing Error","An error occurred while processing the file"),this.$emit("error",e)}finally{this.processingTimeout=window.setTimeout(()=>{this.isProcessing=!1,this.processingTimeout=null},this.processingDelayMs)}}else this.showError("No File Selected","Please select a file to process")})}getFileContent(){return this.fileContent}disconnectedCallback(){super.disconnectedCallback(),this.processingTimeout&&(clearTimeout(this.processingTimeout),this.processingTimeout=null)}}(0,C.Cg)([(0,l.attr)({attribute:"auto-process",mode:"boolean"})],Oa.prototype,"autoProcess",void 0),(0,C.Cg)([(0,l.attr)({attribute:"processing-delay-ms"})],Oa.prototype,"processingDelayMs",void 0),(0,C.Cg)([l.observable],Oa.prototype,"fileContent",void 0),(0,C.Cg)([l.observable],Oa.prototype,"onFileRead",void 0);const Ta=Oa.compose({baseName:"file-reader",styles:Sa,template:ka});var Ia=i(17465),Da=i(32748);const Ra=l.css`
1832
+ `,ks=l.html`
1833
+ ${e=>Es(O(e))}
1834
+ `;class Os extends xs{constructor(){super(),this.processingTimeout=null,this.autoProcess=!1,this.processingDelayMs=1e3,this.fileContent=null,this.accept=".json,application/json"}onFileSelected(e){var t,i;const o=e[0];if(o&&this.accept.includes("json")&&!(null===(i=null===(t=null==o?void 0:o.name)||void 0===t?void 0:t.toLowerCase())||void 0===i?void 0:i.endsWith(".json"))){const e="Selected file is not a JSON file";return this.showError("File Type Error",e),void this.$emit("error",new Error(e))}this.selectedFile=o,this.fileName=o.name,this.autoProcess&&this.handleFileProcessing()}onFileCleared(){this.fileContent=null,this.processingTimeout&&(clearTimeout(this.processingTimeout),this.processingTimeout=null)}handleFileProcessing(){return(0,C.sH)(this,void 0,void 0,function*(){var e;if(this.getSelectedFile()){this.processingTimeout&&clearTimeout(this.processingTimeout),this.isProcessing=!0;try{const t=yield this.getSelectedFile().text();let i;try{i=JSON.parse(t)}catch(e){return this.showError("Invalid JSON Format","The selected file contains invalid JSON"),void this.$emit("error",e)}this.fileContent=i,this.$emit("file-read",{fileName:this.fileName,content:this.fileContent,file:this.getSelectedFile()}),null===(e=this.onFileRead)||void 0===e||e.call(this,this.fileContent)}catch(e){this.showError("File Processing Error","An error occurred while processing the file"),this.$emit("error",e)}finally{this.processingTimeout=window.setTimeout(()=>{this.isProcessing=!1,this.processingTimeout=null},this.processingDelayMs)}}else this.showError("No File Selected","Please select a file to process")})}getFileContent(){return this.fileContent}disconnectedCallback(){super.disconnectedCallback(),this.processingTimeout&&(clearTimeout(this.processingTimeout),this.processingTimeout=null)}}(0,C.Cg)([(0,l.attr)({attribute:"auto-process",mode:"boolean"})],Os.prototype,"autoProcess",void 0),(0,C.Cg)([(0,l.attr)({attribute:"processing-delay-ms"})],Os.prototype,"processingDelayMs",void 0),(0,C.Cg)([l.observable],Os.prototype,"fileContent",void 0),(0,C.Cg)([l.observable],Os.prototype,"onFileRead",void 0);const Ts=Os.compose({baseName:"file-reader",styles:Ss,template:ks});var Is=i(17465),Rs=i(32748);const As=l.css`
1835
1835
  /* Host */
1836
1836
  :host {
1837
1837
  display: flex;
@@ -1879,7 +1879,7 @@
1879
1879
  fast-data-grid-row {
1880
1880
  align-items: center;
1881
1881
  }
1882
- `,Aa=e=>l.html`
1882
+ `,Ds=e=>l.html`
1883
1883
  <template>
1884
1884
  <div class="file-selection">
1885
1885
  <input type="file" multiple ${(0,l.ref)("fileInput")}
@@ -1905,13 +1905,13 @@
1905
1905
  </${e}-data-grid>
1906
1906
  </div>
1907
1907
  </template>
1908
- `,Na=l.html`
1909
- ${e=>Aa(O(e))}
1910
- `,La=e=>{const t=new FormData;return e.forEach(e=>{t.append(e.name,e)}),t},Fa=(e,t,i,o)=>{const n=new Headers;return n.append("SESSION_AUTH_TOKEN",i),o.post(e,{body:t,headers:n})},Ma=(e,t,i,o="GET",n,a,s="zero")=>{const r=new Headers;r.append("SESSION_AUTH_TOKEN",i),fetch(e,{method:o,body:a,headers:r,credentials:"include"}).then(e=>(0,C.sH)(void 0,void 0,void 0,function*(){var t;if(e.ok)return e.blob();{const i=yield e.json();n&&me({title:null==i?void 0:i.MESSAGE_TYPE,body:null===(t=null==i?void 0:i.DETAILS)||void 0===t?void 0:t.ERROR,config:{toast:{autoClose:!0,closeTimeout:5e3,type:"warning"}}},s),Xe.error(i||"An error occurred while downloading the file.")}})).then(e=>{if(e){const i=window.URL.createObjectURL(e),o=document.createElement("a");o.href=i,o.download=t,document.body.appendChild(o),o.click(),o.remove(),n&&me({title:"Success",body:"File downloaded successfully",config:{toast:{autoClose:!0,closeTimeout:5e3,type:"success"}}},s),Xe.info("File downloaded successfully")}}).catch(e=>{Xe.error(e)})},_a=["image/png","image/bmp","image/gif","image/jpeg","image/jpg"],Ha=["text/plain","text/csv"],Pa=["application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.ms-powerpoint","application/vnd.openxmlformats-officedocument.presentationml.presentation","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/pdf"],za=l.html`
1908
+ `,Ns=l.html`
1909
+ ${e=>Ds(O(e))}
1910
+ `,Ls=e=>{const t=new FormData;return e.forEach(e=>{t.append(e.name,e)}),t},Fs=(e,t,i,o)=>{const n=new Headers;return n.append("SESSION_AUTH_TOKEN",i),o.post(e,{body:t,headers:n})},Ms=(e,t,i,o="GET",n,s,a="zero")=>{const r=new Headers;r.append("SESSION_AUTH_TOKEN",i),fetch(e,{method:o,body:s,headers:r,credentials:"include"}).then(e=>(0,C.sH)(void 0,void 0,void 0,function*(){var t;if(e.ok)return e.blob();{const i=yield e.json();n&&me({title:null==i?void 0:i.MESSAGE_TYPE,body:null===(t=null==i?void 0:i.DETAILS)||void 0===t?void 0:t.ERROR,config:{toast:{autoClose:!0,closeTimeout:5e3,type:"warning"}}},a),Xe.error(i||"An error occurred while downloading the file.")}})).then(e=>{if(e){const i=window.URL.createObjectURL(e),o=document.createElement("a");o.href=i,o.download=t,document.body.appendChild(o),o.click(),o.remove(),n&&me({title:"Success",body:"File downloaded successfully",config:{toast:{autoClose:!0,closeTimeout:5e3,type:"success"}}},a),Xe.info("File downloaded successfully")}}).catch(e=>{Xe.error(e)})},_s=["image/png","image/bmp","image/gif","image/jpeg","image/jpg"],Hs=["text/plain","text/csv"],Ps=["application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.ms-powerpoint","application/vnd.openxmlformats-officedocument.presentationml.presentation","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/pdf"],zs=l.html`
1911
1911
  ${(0,l.when)(e=>e.rowData,l.html`
1912
1912
  ${e=>"DATETIME"===e.columnDefinition.type?(0,ni.zT)(e.rowData[e.columnDefinition.columnDataKey]):e.rowData[e.columnDefinition.columnDataKey]}
1913
1913
  `)}
1914
- `;class Ua extends xa{constructor(){super(...arguments),this.acceptedFormats=[],this.selectedFiles=[],this.uploadedFilesResourceName="ALL_FILE_ATTACHMENTS",this.uploadEventName="gwf/attachment-handler/upload",this.gridFields="",this.fileName="",this.uploadedFilesList=[],this.filesGridColumnDefinitions=[]}acceptChanged(){let e=[];this.accept.length>0&&this.accept.split(",").forEach(t=>{"image/*"===t?e=[...e,..._a]:"office/*"===t?e=[...e,...Pa]:"text/*"===t?e=[...e,...Ha]:e.push(t)}),this.acceptedFormats=e}fieldNameChanged(){this.setupGrid()}entityIdChanged(){this.setupGrid()}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){var t;e.connectedCallback.call(this),(null===(t=this.filesGridColumnDefinitions)||void 0===t?void 0:t.length)||this.setColumnDefs()})}setupGrid(){void 0!==this.entityId&&void 0!==this.fieldName&&(this.gridCriteria=(new W.b).withExpression((new B.K).withField(this.fieldName).withValue(this.entityId).build()).build(),this.setRowData())}handleStreamRowOperation(e){let t;for(const i of e.ROW)if(i.DETAILS)switch(i.DETAILS.OPERATION){case"INSERT":this.uploadedFilesList.unshift(i);break;case"MODIFY":t=this.uploadedFilesList.findIndex(e=>e.FILE_ATTACHMENT_ID===i.FILE_ATTACHMENT_ID),this.uploadedFilesList.splice(t,1,i);break;case"DELETE":t=this.uploadedFilesList.findIndex(e=>e.FILE_ATTACHMENT_ID===i.FILE_ATTACHMENT_ID),this.uploadedFilesList.splice(t,1);break;default:Ia.v.error(`Unsupported operation type: ${i.DETAILS.OPERATION}`)}}setRowData(){return(0,C.sH)(this,void 0,void 0,function*(){yield this.connect.stream(this.uploadedFilesResourceName,e=>{var t;1===e.SEQUENCE_ID?this.uploadedFilesList=null!==(t=e.ROW)&&void 0!==t?t:[]:this.handleStreamRowOperation(e)},e=>{Ia.v.error(e)},{CRITERIA_MATCH:this.gridCriteria})})}setColumnDefs(){return(0,C.sH)(this,void 0,void 0,function*(){var e;const t=yield this.connect.getMetadata(this.uploadedFilesResourceName),i=[];this.gridFields.length>0?this.gridFields.split(" ").forEach(e=>{var o;const n=null===(o=t.FIELD)||void 0===o?void 0:o.find(t=>t.NAME===e);n?i.push(this.getColumnObject(n)):"DOWNLOAD"===e&&this.downloadEventName&&i.push(this.getDownloadColumn())}):(null===(e=t.FIELD)||void 0===e||e.forEach(e=>{i.push(this.getColumnObject(e))}),this.downloadEventName&&i.push(this.getDownloadColumn())),this.filesGridColumnDefinitions=i})}getDownloadColumn(){const e=this.tagName.toLowerCase().split("-")[0];return{columnDataKey:"FILE_NAME",title:"File",cellTemplate:l.html`
1914
+ `;class Us extends xs{constructor(){super(...arguments),this.acceptedFormats=[],this.selectedFiles=[],this.uploadedFilesResourceName="ALL_FILE_ATTACHMENTS",this.uploadEventName="gwf/attachment-handler/upload",this.gridFields="",this.fileName="",this.uploadedFilesList=[],this.filesGridColumnDefinitions=[]}acceptChanged(){let e=[];this.accept.length>0&&this.accept.split(",").forEach(t=>{"image/*"===t?e=[...e,..._s]:"office/*"===t?e=[...e,...Ps]:"text/*"===t?e=[...e,...Hs]:e.push(t)}),this.acceptedFormats=e}fieldNameChanged(){this.setupGrid()}entityIdChanged(){this.setupGrid()}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){var t;e.connectedCallback.call(this),(null===(t=this.filesGridColumnDefinitions)||void 0===t?void 0:t.length)||this.setColumnDefs()})}setupGrid(){void 0!==this.entityId&&void 0!==this.fieldName&&(this.gridCriteria=(new G.b).withExpression((new W.K).withField(this.fieldName).withValue(this.entityId).build()).build(),this.setRowData())}handleStreamRowOperation(e){let t;for(const i of e.ROW)if(i.DETAILS)switch(i.DETAILS.OPERATION){case"INSERT":this.uploadedFilesList.unshift(i);break;case"MODIFY":t=this.uploadedFilesList.findIndex(e=>e.FILE_ATTACHMENT_ID===i.FILE_ATTACHMENT_ID),this.uploadedFilesList.splice(t,1,i);break;case"DELETE":t=this.uploadedFilesList.findIndex(e=>e.FILE_ATTACHMENT_ID===i.FILE_ATTACHMENT_ID),this.uploadedFilesList.splice(t,1);break;default:Is.v.error(`Unsupported operation type: ${i.DETAILS.OPERATION}`)}}setRowData(){return(0,C.sH)(this,void 0,void 0,function*(){yield this.connect.stream(this.uploadedFilesResourceName,e=>{var t;1===e.SEQUENCE_ID?this.uploadedFilesList=null!==(t=e.ROW)&&void 0!==t?t:[]:this.handleStreamRowOperation(e)},e=>{Is.v.error(e)},{CRITERIA_MATCH:this.gridCriteria})})}setColumnDefs(){return(0,C.sH)(this,void 0,void 0,function*(){var e;const t=yield this.connect.getMetadata(this.uploadedFilesResourceName),i=[];this.gridFields.length>0?this.gridFields.split(" ").forEach(e=>{var o;const n=null===(o=t.FIELD)||void 0===o?void 0:o.find(t=>t.NAME===e);n?i.push(this.getColumnObject(n)):"DOWNLOAD"===e&&this.downloadEventName&&i.push(this.getDownloadColumn())}):(null===(e=t.FIELD)||void 0===e||e.forEach(e=>{i.push(this.getColumnObject(e))}),this.downloadEventName&&i.push(this.getDownloadColumn())),this.filesGridColumnDefinitions=i})}getDownloadColumn(){const e=this.tagName.toLowerCase().split("-")[0];return{columnDataKey:"FILE_NAME",title:"File",cellTemplate:l.html`
1915
1915
  <template>
1916
1916
  <div class="download-button-container">
1917
1917
  <${e}-button
@@ -1922,7 +1922,7 @@
1922
1922
  </${e}-button>
1923
1923
  </div>
1924
1924
  </template>
1925
- `}}getColumnObject(e){return{columnDataKey:e.NAME,title:e.NAME.toLowerCase().split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),type:e.TYPE,cellTemplate:za}}handleClick(){this.fileInput.value=null,this.fileInput.click()}onFileSelected(e){const t=Array.isArray(e)?e:[e];if(t.length>0&&this.acceptedFormats.length>0)for(const e of t)if(!(this.accept.split(",").includes(".msg")&&e.name&&e.name.endsWith("msg")||this.acceptedFormats.includes(e.type)))return void this.showError("File Type Error",`Not a valid file type. Accepted Formats are ${this.accept}`);this.selectedFiles=t,this.fileName=this.selectedFiles.map(e=>e.name.trim()).join(),this.$emit("file-selected",{files:this.selectedFiles})}onFileCleared(){this.fileName="",this.selectedFiles=[]}handleFileUpload(){return(0,C.sH)(this,void 0,void 0,function*(){try{const e=La(this.selectedFiles);e.append(this.uploadKey,this.entityId);const t=yield Fa(this.uploadEventName,e,this.session.getItem("authToken","session"),this.http);if(t.ERROR)return Ia.v.error(t.ERROR),void this.$emit("errorOut",t.ERROR);Ia.v.info(t),this.$emit("success",t),this.clearSelection()}catch(e){this.$emit("errorOut",e),Ia.v.error(e)}})}handleFileDownload(e){const t=this.tagName.toLowerCase().split("-")[0];Ma(this.downloadEventName(e),e.FILE_NAME,this.session.getItem("authToken","session"),"GET",!0,void 0,t)}}(0,C.Cg)([l.observable],Ua.prototype,"gridCriteria",void 0),(0,C.Cg)([ii.dm],Ua.prototype,"connect",void 0),(0,C.Cg)([Da.l],Ua.prototype,"http",void 0),(0,C.Cg)([bi.N],Ua.prototype,"session",void 0),(0,C.Cg)([(0,l.attr)({attribute:"uploaded-files-resource-name"})],Ua.prototype,"uploadedFilesResourceName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"upload-event-name"})],Ua.prototype,"uploadEventName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"field-name"})],Ua.prototype,"fieldName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"entity-id"})],Ua.prototype,"entityId",void 0),(0,C.Cg)([(0,l.attr)({attribute:"upload-key"})],Ua.prototype,"uploadKey",void 0),(0,C.Cg)([(0,l.attr)({attribute:"grid-fields"})],Ua.prototype,"gridFields",void 0),(0,C.Cg)([l.observable],Ua.prototype,"fileName",void 0),(0,C.Cg)([l.observable],Ua.prototype,"uploadedFilesList",void 0),(0,C.Cg)([l.observable],Ua.prototype,"filesGridColumnDefinitions",void 0);const Ba=void 0,Wa={},Ga=Ua.compose(Object.assign({baseName:"file-upload",styles:Ra,template:Na,shadowOptions:Ba},Wa)),ja=l.css`
1925
+ `}}getColumnObject(e){return{columnDataKey:e.NAME,title:e.NAME.toLowerCase().split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),type:e.TYPE,cellTemplate:zs}}handleClick(){this.fileInput.value=null,this.fileInput.click()}onFileSelected(e){const t=Array.isArray(e)?e:[e];if(t.length>0&&this.acceptedFormats.length>0)for(const e of t)if(!(this.accept.split(",").includes(".msg")&&e.name&&e.name.endsWith("msg")||this.acceptedFormats.includes(e.type)))return void this.showError("File Type Error",`Not a valid file type. Accepted Formats are ${this.accept}`);this.selectedFiles=t,this.fileName=this.selectedFiles.map(e=>e.name.trim()).join(),this.$emit("file-selected",{files:this.selectedFiles})}onFileCleared(){this.fileName="",this.selectedFiles=[]}handleFileUpload(){return(0,C.sH)(this,void 0,void 0,function*(){try{const e=Ls(this.selectedFiles);e.append(this.uploadKey,this.entityId);const t=yield Fs(this.uploadEventName,e,this.session.getItem("authToken","session"),this.http);if(t.ERROR)return Is.v.error(t.ERROR),void this.$emit("errorOut",t.ERROR);Is.v.info(t),this.$emit("success",t),this.clearSelection()}catch(e){this.$emit("errorOut",e),Is.v.error(e)}})}handleFileDownload(e){const t=this.tagName.toLowerCase().split("-")[0];Ms(this.downloadEventName(e),e.FILE_NAME,this.session.getItem("authToken","session"),"GET",!0,void 0,t)}}(0,C.Cg)([l.observable],Us.prototype,"gridCriteria",void 0),(0,C.Cg)([ii.dm],Us.prototype,"connect",void 0),(0,C.Cg)([Rs.l],Us.prototype,"http",void 0),(0,C.Cg)([bi.N],Us.prototype,"session",void 0),(0,C.Cg)([(0,l.attr)({attribute:"uploaded-files-resource-name"})],Us.prototype,"uploadedFilesResourceName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"upload-event-name"})],Us.prototype,"uploadEventName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"field-name"})],Us.prototype,"fieldName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"entity-id"})],Us.prototype,"entityId",void 0),(0,C.Cg)([(0,l.attr)({attribute:"upload-key"})],Us.prototype,"uploadKey",void 0),(0,C.Cg)([(0,l.attr)({attribute:"grid-fields"})],Us.prototype,"gridFields",void 0),(0,C.Cg)([l.observable],Us.prototype,"fileName",void 0),(0,C.Cg)([l.observable],Us.prototype,"uploadedFilesList",void 0),(0,C.Cg)([l.observable],Us.prototype,"filesGridColumnDefinitions",void 0);const Ws=void 0,Gs={},Bs=Us.compose(Object.assign({baseName:"file-upload",styles:As,template:Ns,shadowOptions:Ws},Gs)),Vs=l.css`
1926
1926
  .filter-wrapper {
1927
1927
  border: 1px solid gray;
1928
1928
  border-radius: calc(var(--design-unit) * 2px);
@@ -1973,12 +1973,12 @@
1973
1973
  .flex-row foundation-select {
1974
1974
  flex: 1;
1975
1975
  }
1976
- `,Va=(e="start",t="#879ba6")=>`\n <svg class="svg-icon" slot="${e}" width="16px" height="16px">\n <g transform="matrix(1 0 0 1 -1865 -3576 )">\n <path d="M 15.8825 14.185499999999998 L 9.697000000000001 8 L 14.825000000000001 2.872 L 15.8825 1.814499999999999 C 16.0385 1.6584999999999992 16.0385 1.4049999999999994 15.8825 1.2489999999999988 L 14.751 0.11749999999999972 C 14.594999999999999 -0.03850000000000087 14.3415 -0.03850000000000087 14.1855 0.11749999999999972 L 8 6.303000000000001 L 1.8145 0.11699999999999999 C 1.6585 -0.03900000000000059 1.4050000000000002 -0.03900000000000059 1.2489999999999999 0.11699999999999999 L 0.11699999999999999 1.2485 C -0.039000000000000014 1.4044999999999996 -0.039000000000000014 1.6579999999999995 0.11699999999999999 1.814 L 6.303000000000001 8 L 0.11699999999999999 14.185499999999998 C -0.039000000000000014 14.3415 -0.039000000000000014 14.594999999999999 0.11699999999999999 14.751000000000001 L 1.2485 15.8825 C 1.4045 16.0385 1.658 16.0385 1.814 15.8825 L 8 9.697 L 13.128 14.825 L 14.1855 15.8825 C 14.3415 16.0385 14.594999999999999 16.0385 14.751 15.8825 L 15.8825 14.751000000000001 C 16.0385 14.594999999999999 16.0385 14.3415 15.8825 14.185499999999998 Z " fill-rule="nonzero" fill="${t}" stroke="none" transform="matrix(1 0 0 1 1865 3576 )" />\n </g>\n </svg>\n`,Ya=l.html`
1977
- <div class="close-icon" @click=${e=>e.clear()}>${Va()}</div>
1978
- `;function qa(e){var t,i,o;return null!==(o=null===(i=null===(t=null==e?void 0:e.event)||void 0===t?void 0:t.target)||void 0===i?void 0:i.value)&&void 0!==o?o:"all"}const Ka=[{name:"All",value:"all",selected:!0},{name:"True",value:"true"},{name:"False",value:"false"},{name:"N/A",value:"null"}],Xa=(e,t)=>{switch(e.type){case"number":return(e=>l.html`
1976
+ `,js=(e="start",t="#879ba6")=>`\n <svg class="svg-icon" slot="${e}" width="16px" height="16px">\n <g transform="matrix(1 0 0 1 -1865 -3576 )">\n <path d="M 15.8825 14.185499999999998 L 9.697000000000001 8 L 14.825000000000001 2.872 L 15.8825 1.814499999999999 C 16.0385 1.6584999999999992 16.0385 1.4049999999999994 15.8825 1.2489999999999988 L 14.751 0.11749999999999972 C 14.594999999999999 -0.03850000000000087 14.3415 -0.03850000000000087 14.1855 0.11749999999999972 L 8 6.303000000000001 L 1.8145 0.11699999999999999 C 1.6585 -0.03900000000000059 1.4050000000000002 -0.03900000000000059 1.2489999999999999 0.11699999999999999 L 0.11699999999999999 1.2485 C -0.039000000000000014 1.4044999999999996 -0.039000000000000014 1.6579999999999995 0.11699999999999999 1.814 L 6.303000000000001 8 L 0.11699999999999999 14.185499999999998 C -0.039000000000000014 14.3415 -0.039000000000000014 14.594999999999999 0.11699999999999999 14.751000000000001 L 1.2485 15.8825 C 1.4045 16.0385 1.658 16.0385 1.814 15.8825 L 8 9.697 L 13.128 14.825 L 14.1855 15.8825 C 14.3415 16.0385 14.594999999999999 16.0385 14.751 15.8825 L 15.8825 14.751000000000001 C 16.0385 14.594999999999999 16.0385 14.3415 15.8825 14.185499999999998 Z " fill-rule="nonzero" fill="${t}" stroke="none" transform="matrix(1 0 0 1 1865 3576 )" />\n </g>\n </svg>\n`,Ys=l.html`
1977
+ <div class="close-icon" @click=${e=>e.clear()}>${js()}</div>
1978
+ `;function qs(e){var t,i,o;return null!==(o=null===(i=null===(t=null==e?void 0:e.event)||void 0===t?void 0:t.target)||void 0===i?void 0:i.value)&&void 0!==o?o:"all"}const Ks=[{name:"All",value:"all",selected:!0},{name:"True",value:"true"},{name:"False",value:"false"},{name:"N/A",value:"null"}],Xs=(e,t)=>{switch(e.type){case"number":return(e=>l.html`
1979
1979
  <div class="flex-row">
1980
1980
  <div>${e=>e.label}</div>
1981
- ${Ya}
1981
+ ${Ys}
1982
1982
  </div>
1983
1983
  <div class="flex-row">
1984
1984
  <${e}-text-field
@@ -1997,7 +1997,7 @@
1997
1997
  `)(t);case"date":return(e=>l.html`
1998
1998
  <div class="flex-row">
1999
1999
  <div>${e=>e.label}</div>
2000
- ${Ya}
2000
+ ${Ys}
2001
2001
  </div>
2002
2002
  <div class="flex-row">
2003
2003
  <${e}-text-field
@@ -2014,11 +2014,11 @@
2014
2014
  `)(t);case"boolean":return(e=>l.html`
2015
2015
  <div class="flex-row">
2016
2016
  <div>${e=>e.label}</div>
2017
- ${Ya}
2017
+ ${Ys}
2018
2018
  </div>
2019
2019
  <div class="flex-row">
2020
- <${e}-select @change="${(e,t)=>e.onBooleanFilterSelection(qa(t))}}">
2021
- ${(0,l.repeat)(()=>Ka,l.html`
2020
+ <${e}-select @change="${(e,t)=>e.onBooleanFilterSelection(qs(t))}}">
2021
+ ${(0,l.repeat)(()=>Ks,l.html`
2022
2022
  <${e}-option value="${e=>e.value}" selected="${e=>e.selected}">
2023
2023
  ${e=>e.name}
2024
2024
  </${e}-option>
@@ -2028,10 +2028,10 @@
2028
2028
  `)(t);case"enum":return(e=>l.html`
2029
2029
  <div class="flex-row">
2030
2030
  <div>${e=>e.label}</div>
2031
- ${Ya}
2031
+ ${Ys}
2032
2032
  </div>
2033
2033
  <div class="flex-row">
2034
- <${e}-select @change="${(e,t)=>e.onEnumFilterSelection(qa(t))}}">
2034
+ <${e}-select @change="${(e,t)=>e.onEnumFilterSelection(qs(t))}}">
2035
2035
  ${(0,l.repeat)(e=>e.enumFilterOptions,l.html`
2036
2036
  <${e}-option value="${e=>e.value}" selected="${e=>e.selected}">
2037
2037
  ${e=>e.name}
@@ -2042,7 +2042,7 @@
2042
2042
  `)(t);default:return(e=>l.html`
2043
2043
  <div class="flex-row">
2044
2044
  <div>${e=>e.label}</div>
2045
- ${Ya}
2045
+ ${Ys}
2046
2046
  </div>
2047
2047
  <div class="flex-row">
2048
2048
  <${e}-text-field
@@ -2051,11 +2051,11 @@
2051
2051
  :value=${(0,P.O)(e=>e.textFilter)}
2052
2052
  />
2053
2053
  </div>
2054
- `)(t)}},Qa=e=>l.html`
2055
- <div class="filter-wrapper">${t=>Xa(t,e)}</div>
2056
- `,Ja=l.html`
2057
- ${e=>Qa(O(e))}</div>
2058
- `;var Za;!function(e){e.change="filter-changed",e.clear="filter-cleared"}(Za||(Za={}));class es extends s.FoundationElement{constructor(){super(...arguments),this.type="text",this.textFilter="",this.enumFilterOptions=[{name:"All",value:"all",selected:!0}]}textFilterChanged(e,t){if(!(null==t?void 0:t.length))return void this.$emit(Za.clear,{fieldName:this.fieldName,target:this.target});const i=`Expr.containsIgnoreCase(${this.fieldName},'${t}')`;this.$emit(Za.change,{fieldName:this.fieldName,filter:i,target:this.target})}numFilterMinChanged(e,t){this.numFilterMin=Number.isFinite(Number(t))?Number(t):void 0,this.handleNumericFilter(this.numFilterMin,this.numFilterMax)}numFilterMaxChanged(e,t){this.numFilterMax=Number.isFinite(Number(t))?Number(t):void 0,this.handleNumericFilter(this.numFilterMin,this.numFilterMax)}handleNumericFilter(e,t){if(!Number.isFinite(e)&&!Number.isFinite(t))return void this.$emit(Za.clear,{fieldName:this.fieldName,target:this.target});const i=`${this.fieldName} >= ${e}`,o=`${this.fieldName} <= ${t}`,n=Number.isFinite(e)?Number.isFinite(t)?`(${i} && ${o})`:i:o;this.$emit(Za.change,{fieldName:this.fieldName,filter:n,target:this.target})}formatDate(e){if(Number.isFinite(e))return new Date(e).toISOString().slice(0,19).replace(/-/g,"").replace("T","-")}dateFilterMinChanged(e,t){this.dateMinMS=Date.parse(t),this.handleDateFilter(this.dateMinMS,this.dateMaxMS)}dateFilterMaxChanged(e,t){this.dateMaxMS=Date.parse(t),this.handleDateFilter(this.dateMinMS,this.dateMaxMS)}handleDateFilter(e,t){if(!Number.isFinite(e)&&!Number.isFinite(t))return void this.$emit(Za.clear,{fieldName:this.fieldName});const i=`Expr.dateTimeIsAfter(${this.fieldName}, '${this.formatDate(e)}')`,o=`Expr.dateTimeIsBefore(${this.fieldName}, '${this.formatDate(t)}')`,n=Number.isFinite(e)?Number.isFinite(t)?`(${i} && ${o})`:i:o;this.$emit(Za.change,{fieldName:this.fieldName,filter:n,target:this.target})}connectedCallback(){var e;if(super.connectedCallback(),null===(e=this.enumOptions)||void 0===e?void 0:e.length){const e=this.enumOptions.includes("|")?"|":",",t=this.enumOptions.split(e).map(e=>({name:e,value:e}));this.enumFilterOptions=[{name:"All",value:"all",selected:!0},...t]}}clear(){switch(this.type){case"number":this.numFilterFieldMin.value=void 0,this.numFilterFieldMax.value=void 0,this.numFilterMin=void 0,this.numFilterMax=void 0;break;case"date":this.dateFilterFieldMin.value="",this.dateFilterFieldMax.value="",this.dateMinMS=NaN,this.dateMaxMS=NaN;break;case"text":this.textFilterField.value=""}this.$emit(Za.clear,{fieldName:this.fieldName,target:this.target})}onBooleanFilterSelection(e){e&&"all"!==e?this.$emit(Za.change,{fieldName:this.fieldName,filter:`${this.fieldName} == ${e}`,target:this.target}):this.$emit(Za.clear,{fieldName:this.fieldName,target:this.target})}onEnumFilterSelection(e){e&&"all"!==e?this.$emit(Za.change,{fieldName:this.fieldName,filter:`${this.fieldName} == "${e}"`,target:this.target}):this.$emit(Za.clear,{fieldName:this.fieldName,target:this.target})}}(0,C.Cg)([l.attr],es.prototype,"fieldName",void 0),(0,C.Cg)([l.attr],es.prototype,"type",void 0),(0,C.Cg)([l.attr],es.prototype,"label",void 0),(0,C.Cg)([l.attr],es.prototype,"target",void 0),(0,C.Cg)([l.observable],es.prototype,"textFilter",void 0),(0,C.Cg)([l.observable],es.prototype,"numFilterMin",void 0),(0,C.Cg)([l.observable],es.prototype,"numFilterMax",void 0),(0,C.Cg)([l.observable],es.prototype,"dateFilterMin",void 0),(0,C.Cg)([l.observable],es.prototype,"dateFilterMax",void 0),(0,C.Cg)([l.attr],es.prototype,"enumOptions",void 0),(0,C.Cg)([l.observable],es.prototype,"enumFilterOptions",void 0);const ts=es.compose({baseName:"filter",template:Ja,styles:ja});var is=i(64324);const os=(e,t)=>l.css`
2054
+ `)(t)}},Qs=e=>l.html`
2055
+ <div class="filter-wrapper">${t=>Xs(t,e)}</div>
2056
+ `,Js=l.html`
2057
+ ${e=>Qs(O(e))}</div>
2058
+ `;var Zs;!function(e){e.change="filter-changed",e.clear="filter-cleared"}(Zs||(Zs={}));class ea extends a.FoundationElement{constructor(){super(...arguments),this.type="text",this.textFilter="",this.enumFilterOptions=[{name:"All",value:"all",selected:!0}]}textFilterChanged(e,t){if(!(null==t?void 0:t.length))return void this.$emit(Zs.clear,{fieldName:this.fieldName,target:this.target});const i=`Expr.containsIgnoreCase(${this.fieldName},'${t}')`;this.$emit(Zs.change,{fieldName:this.fieldName,filter:i,target:this.target})}numFilterMinChanged(e,t){this.numFilterMin=Number.isFinite(Number(t))?Number(t):void 0,this.handleNumericFilter(this.numFilterMin,this.numFilterMax)}numFilterMaxChanged(e,t){this.numFilterMax=Number.isFinite(Number(t))?Number(t):void 0,this.handleNumericFilter(this.numFilterMin,this.numFilterMax)}handleNumericFilter(e,t){if(!Number.isFinite(e)&&!Number.isFinite(t))return void this.$emit(Zs.clear,{fieldName:this.fieldName,target:this.target});const i=`${this.fieldName} >= ${e}`,o=`${this.fieldName} <= ${t}`,n=Number.isFinite(e)?Number.isFinite(t)?`(${i} && ${o})`:i:o;this.$emit(Zs.change,{fieldName:this.fieldName,filter:n,target:this.target})}formatDate(e){if(Number.isFinite(e))return new Date(e).toISOString().slice(0,19).replace(/-/g,"").replace("T","-")}dateFilterMinChanged(e,t){this.dateMinMS=Date.parse(t),this.handleDateFilter(this.dateMinMS,this.dateMaxMS)}dateFilterMaxChanged(e,t){this.dateMaxMS=Date.parse(t),this.handleDateFilter(this.dateMinMS,this.dateMaxMS)}handleDateFilter(e,t){if(!Number.isFinite(e)&&!Number.isFinite(t))return void this.$emit(Zs.clear,{fieldName:this.fieldName});const i=`Expr.dateTimeIsAfter(${this.fieldName}, '${this.formatDate(e)}')`,o=`Expr.dateTimeIsBefore(${this.fieldName}, '${this.formatDate(t)}')`,n=Number.isFinite(e)?Number.isFinite(t)?`(${i} && ${o})`:i:o;this.$emit(Zs.change,{fieldName:this.fieldName,filter:n,target:this.target})}connectedCallback(){var e;if(super.connectedCallback(),null===(e=this.enumOptions)||void 0===e?void 0:e.length){const e=this.enumOptions.includes("|")?"|":",",t=this.enumOptions.split(e).map(e=>({name:e,value:e}));this.enumFilterOptions=[{name:"All",value:"all",selected:!0},...t]}}clear(){switch(this.type){case"number":this.numFilterFieldMin.value=void 0,this.numFilterFieldMax.value=void 0,this.numFilterMin=void 0,this.numFilterMax=void 0;break;case"date":this.dateFilterFieldMin.value="",this.dateFilterFieldMax.value="",this.dateMinMS=NaN,this.dateMaxMS=NaN;break;case"text":this.textFilterField.value=""}this.$emit(Zs.clear,{fieldName:this.fieldName,target:this.target})}onBooleanFilterSelection(e){e&&"all"!==e?this.$emit(Zs.change,{fieldName:this.fieldName,filter:`${this.fieldName} == ${e}`,target:this.target}):this.$emit(Zs.clear,{fieldName:this.fieldName,target:this.target})}onEnumFilterSelection(e){e&&"all"!==e?this.$emit(Zs.change,{fieldName:this.fieldName,filter:`${this.fieldName} == "${e}"`,target:this.target}):this.$emit(Zs.clear,{fieldName:this.fieldName,target:this.target})}}(0,C.Cg)([l.attr],ea.prototype,"fieldName",void 0),(0,C.Cg)([l.attr],ea.prototype,"type",void 0),(0,C.Cg)([l.attr],ea.prototype,"label",void 0),(0,C.Cg)([l.attr],ea.prototype,"target",void 0),(0,C.Cg)([l.observable],ea.prototype,"textFilter",void 0),(0,C.Cg)([l.observable],ea.prototype,"numFilterMin",void 0),(0,C.Cg)([l.observable],ea.prototype,"numFilterMax",void 0),(0,C.Cg)([l.observable],ea.prototype,"dateFilterMin",void 0),(0,C.Cg)([l.observable],ea.prototype,"dateFilterMax",void 0),(0,C.Cg)([l.attr],ea.prototype,"enumOptions",void 0),(0,C.Cg)([l.observable],ea.prototype,"enumFilterOptions",void 0);const ta=ea.compose({baseName:"filter",template:Js,styles:Vs});var ia=i(64324);const oa=(e,t)=>l.css`
2059
2059
  .filter-bar {
2060
2060
  background-color: #2c2f33;
2061
2061
  padding: calc(var(--design-unit) * 2px);
@@ -2091,9 +2091,9 @@
2091
2091
  .toggle-collapsed {
2092
2092
  color: #48ed9c;
2093
2093
  }
2094
- `,ns=e=>{switch(e){case"INT":case"DOUBLE":case"LONG":return"number";case"DATETIME":return"date";case"BOOLEAN":return"boolean";case"ENUM":return"enum";default:return"text"}},as=l.html`
2094
+ `,na=e=>{switch(e){case"INT":case"DOUBLE":case"LONG":return"number";case"DATETIME":return"date";case"BOOLEAN":return"boolean";case"ENUM":return"enum";default:return"text"}},sa=l.html`
2095
2095
  <p>Fetching metadata for ${e=>e.resource}...</p>
2096
- `,ss=e=>l.html`
2096
+ `,aa=e=>l.html`
2097
2097
  <div
2098
2098
  class=${e=>(0,x.x)(["toggle",!0],["toggle-collapsed",e.collapsed])}
2099
2099
  @click="${e=>e.toggle()}"
@@ -2113,17 +2113,17 @@
2113
2113
  <${e}-filter
2114
2114
  label="${e=>e.UI_LABEL}"
2115
2115
  target="${(e,t)=>{var i;return null===(i=t.parent)||void 0===i?void 0:i.target}}"
2116
- type="${e=>ns(e.TYPE)}"
2116
+ type="${e=>na(e.TYPE)}"
2117
2117
  fieldName="${e=>e.NAME}"
2118
2118
  enumOptions="${e=>e.VALID_VALUES}"
2119
2119
  ></${e}-filter>
2120
2120
  `)}
2121
2121
  </div>
2122
2122
  </div>
2123
- `,rs=l.html`
2124
- ${e=>e.ready?ss(O(e)):as}
2125
- `,ls=5;class ds extends s.FoundationElement{constructor(){super(...arguments),this.columns=ls,this.ready=!1,this.collapsed=!0}connectedCallback(){super.connectedCallback(),this.init()}initLabels(){var e,t,i,o;let n=!1,a=[];(null===(e=null==this?void 0:this.labels)||void 0===e?void 0:e.length)&&(a=null===(t=this.labels.split(","))||void 0===t?void 0:t.map(e=>e.trim()),n=(null===(i=this.fields)||void 0===i?void 0:i.length)===(null==a?void 0:a.length));for(let e=0;e<((null===(o=this.fields)||void 0===o?void 0:o.length)||0);e+=1){const t=n?a[e]:this.camelCasePreserveWhitespace(this.fields[e].NAME.replace(/_/g," "));this.fields[e].UI_LABEL=t}}camelCasePreserveWhitespace(e){return e.split(" ").map(e=>(0,is.fL)(e)).join(" ")}resourceChanged(e,t){e!==t&&(null==e?void 0:e.length)&&this.init()}init(){this.ready=!1,this.connect.getMetadata(this.resource).then(e=>{var t,i;if(this.fields=e.FIELD,null===(t=this.only)||void 0===t?void 0:t.length){const e=this.only.split(",").map(e=>e.trim()),t=(t,i)=>e.indexOf(t.NAME)>e.indexOf(i.NAME)?1:-1;this.fields=null===(i=this.fields)||void 0===i?void 0:i.filter(t=>e.includes(t.NAME)).sort(t)}this.ready=!0}).then(()=>this.initLabels()).then(()=>window.requestAnimationFrame(()=>{this.adjustColumnStyles()})).catch(e=>Xe.error(e))}adjustColumnStyles(){this.filterGrid&&(this.filterGrid.style["grid-template-columns"]=`repeat(${this.columns}, 1fr)`)}toggle(){this.ready&&(this.collapsed=!this.collapsed)}}(0,C.Cg)([l.attr],ds.prototype,"resource",void 0),(0,C.Cg)([l.attr],ds.prototype,"only",void 0),(0,C.Cg)([l.attr],ds.prototype,"labels",void 0),(0,C.Cg)([l.attr],ds.prototype,"target",void 0),(0,C.Cg)([l.attr],ds.prototype,"columns",void 0),(0,C.Cg)([l.observable],ds.prototype,"ready",void 0),(0,C.Cg)([l.observable],ds.prototype,"fields",void 0),(0,C.Cg)([ii.dm],ds.prototype,"connect",void 0),(0,C.Cg)([l.observable],ds.prototype,"collapsed",void 0);const cs=ds.compose({baseName:"filter-bar",template:rs,styles:os});var us;!function(e){e.sm="(max-width: 640px)",e.md="(min-width: 641px) and (max-width: 1023px)",e.lg="(min-width: 1024px)"}(us||(us={}));const hs=e=>{const t=e?`-${e}`:"";return l.css`
2126
- ${t&&`@media only screen and ${us[e]} {`}
2123
+ `,ra=l.html`
2124
+ ${e=>e.ready?aa(O(e)):sa}
2125
+ `,la=5;class da extends a.FoundationElement{constructor(){super(...arguments),this.columns=la,this.ready=!1,this.collapsed=!0}connectedCallback(){super.connectedCallback(),this.init()}initLabels(){var e,t,i,o;let n=!1,s=[];(null===(e=null==this?void 0:this.labels)||void 0===e?void 0:e.length)&&(s=null===(t=this.labels.split(","))||void 0===t?void 0:t.map(e=>e.trim()),n=(null===(i=this.fields)||void 0===i?void 0:i.length)===(null==s?void 0:s.length));for(let e=0;e<((null===(o=this.fields)||void 0===o?void 0:o.length)||0);e+=1){const t=n?s[e]:this.camelCasePreserveWhitespace(this.fields[e].NAME.replace(/_/g," "));this.fields[e].UI_LABEL=t}}camelCasePreserveWhitespace(e){return e.split(" ").map(e=>(0,ia.fL)(e)).join(" ")}resourceChanged(e,t){e!==t&&(null==e?void 0:e.length)&&this.init()}init(){this.ready=!1,this.connect.getMetadata(this.resource).then(e=>{var t,i;if(this.fields=e.FIELD,null===(t=this.only)||void 0===t?void 0:t.length){const e=this.only.split(",").map(e=>e.trim()),t=(t,i)=>e.indexOf(t.NAME)>e.indexOf(i.NAME)?1:-1;this.fields=null===(i=this.fields)||void 0===i?void 0:i.filter(t=>e.includes(t.NAME)).sort(t)}this.ready=!0}).then(()=>this.initLabels()).then(()=>window.requestAnimationFrame(()=>{this.adjustColumnStyles()})).catch(e=>Xe.error(e))}adjustColumnStyles(){this.filterGrid&&(this.filterGrid.style["grid-template-columns"]=`repeat(${this.columns}, 1fr)`)}toggle(){this.ready&&(this.collapsed=!this.collapsed)}}(0,C.Cg)([l.attr],da.prototype,"resource",void 0),(0,C.Cg)([l.attr],da.prototype,"only",void 0),(0,C.Cg)([l.attr],da.prototype,"labels",void 0),(0,C.Cg)([l.attr],da.prototype,"target",void 0),(0,C.Cg)([l.attr],da.prototype,"columns",void 0),(0,C.Cg)([l.observable],da.prototype,"ready",void 0),(0,C.Cg)([l.observable],da.prototype,"fields",void 0),(0,C.Cg)([ii.dm],da.prototype,"connect",void 0),(0,C.Cg)([l.observable],da.prototype,"collapsed",void 0);const ca=da.compose({baseName:"filter-bar",template:ra,styles:oa});var ua;!function(e){e.sm="(max-width: 640px)",e.md="(min-width: 641px) and (max-width: 1023px)",e.lg="(min-width: 1024px)"}(ua||(ua={}));const ha=e=>{const t=e?`-${e}`:"";return l.css`
2126
+ ${t&&`@media only screen and ${ua[e]} {`}
2127
2127
  :host(.spacing${t}-1x) slot {
2128
2128
  gap: calc(var(--design-unit) * 2px);
2129
2129
  }
@@ -2240,7 +2240,7 @@
2240
2240
  align-content: space-evenly;
2241
2241
  }
2242
2242
  ${t&&"}"}
2243
- `},ps=l.css`
2243
+ `},pa=l.css`
2244
2244
  :host {
2245
2245
  width: 100%;
2246
2246
  height: 100%;
@@ -2252,17 +2252,17 @@
2252
2252
  display: flex;
2253
2253
  }
2254
2254
 
2255
- ${hs()}
2256
- ${hs("lg")}
2257
- ${hs("md")}
2258
- ${hs("sm")}
2259
- `,ms=l.html`
2255
+ ${ha()}
2256
+ ${ha("lg")}
2257
+ ${ha("md")}
2258
+ ${ha("sm")}
2259
+ `,ma=l.html`
2260
2260
  <template>
2261
2261
  <slot></slot>
2262
2262
  </template>
2263
- `,vs=void 0,gs={};class fs extends s.FoundationElement{}const bs=fs.compose(Object.assign({baseName:"flex-layout",styles:ps,template:ms,shadowOptions:vs},gs)),ys=(e,t)=>l.css`
2263
+ `,ga=void 0,va={};class fa extends a.FoundationElement{}const ba=fa.compose(Object.assign({baseName:"flex-layout",styles:pa,template:ma,shadowOptions:ga},va)),ya=(e,t)=>l.css`
2264
2264
  ${(0,r.flipperStyles)(e,t)}
2265
- `,ws=(e,t)=>(0,s.flipperTemplate)(e,t);class Cs extends r.Flipper{}const xs=void 0,$s={next:'\n <svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">\n <path\n d="M4.023 15.273L11.29 8 4.023.727l.704-.704L12.71 8l-7.984 7.977-.704-.704z"\n />\n </svg>\n ',previous:'\n <svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">\n <path\n d="M11.273 15.977L3.29 8 11.273.023l.704.704L4.71 8l7.266 7.273-.704.704z"\n />\n </svg>\n '},Ss=Cs.compose(Object.assign({baseName:"flipper",template:ws,styles:ys,shadowOptions:xs},$s)),Es=225,ks=l.css`
2265
+ `,wa=(e,t)=>(0,a.flipperTemplate)(e,t);class Ca extends r.Flipper{}const xa=void 0,$a={next:'\n <svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">\n <path\n d="M4.023 15.273L11.29 8 4.023.727l.704-.704L12.71 8l-7.984 7.977-.704-.704z"\n />\n </svg>\n ',previous:'\n <svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">\n <path\n d="M11.273 15.977L3.29 8 11.273.023l.704.704L4.71 8l7.266 7.273-.704.704z"\n />\n </svg>\n '},Sa=Ca.compose(Object.assign({baseName:"flipper",template:wa,styles:ya,shadowOptions:xa},$a)),Ea=225,ka=l.css`
2266
2266
  /* Host */
2267
2267
  :host {
2268
2268
  display: inline-block;
@@ -2287,7 +2287,7 @@
2287
2287
  height: 100%;
2288
2288
  position: absolute;
2289
2289
  /* stylelint-disable-next-line function-name-case */
2290
- transition: transform ${Es.toString()}ms ease-in;
2290
+ transition: transform ${Ea.toString()}ms ease-in;
2291
2291
  width: 20%;
2292
2292
  z-index: 2001;
2293
2293
  }
@@ -2346,7 +2346,7 @@
2346
2346
  opacity: 50%;
2347
2347
  position: absolute;
2348
2348
  /* stylelint-disable-next-line function-name-case */
2349
- transition: opacity ${Es.toString()}ms linear;
2349
+ transition: opacity ${Ea.toString()}ms linear;
2350
2350
  width: 100%;
2351
2351
  z-index: 2000;
2352
2352
  }
@@ -2354,7 +2354,7 @@
2354
2354
  :host([visuallyhidden]) div.background {
2355
2355
  opacity: 0%;
2356
2356
  }
2357
- `,Os=e=>l.html`
2357
+ `,Oa=e=>l.html`
2358
2358
  <div ?closed=${e=>e.closed} ?visuallyhidden=${e=>e.visuallyhidden}>
2359
2359
  <div class="container">
2360
2360
  <div class="background" part="background" @click=${e=>e.closeFlyout()}></div>
@@ -2378,10 +2378,10 @@
2378
2378
  </div>
2379
2379
  </div>
2380
2380
  </div>
2381
- `,Ts=l.html`
2382
- ${e=>Os(O(e))}
2383
- `;class Is extends s.FoundationElement{constructor(){super(...arguments),this.position="right",this.displayHeader=!0,this.closed=!0,this.visuallyhidden=!0}closedChanged(){this.closed||(setTimeout(()=>this.visuallyhidden=!1,1),this.focusExit())}closeFlyout(){this.visuallyhidden=!0}closingFinished(){this.visuallyhidden&&(this.closed=!0,this.$emit("closed"))}focusExit(){this.exit.focus()}}(0,C.Cg)([l.attr],Is.prototype,"position",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Is.prototype,"displayHeader",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Is.prototype,"closed",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Is.prototype,"visuallyhidden",void 0);const Ds=void 0,Rs={},As=Is.compose(Object.assign({baseName:"flyout",styles:ks,template:Ts,shadowOptions:Ds},Rs));var Ns;!function(e){e.sm="(max-width: 640px)",e.md="(min-width: 641px) and (max-width: 1023px)",e.lg="(min-width: 1024px)"}(Ns||(Ns={}));const Ls=e=>{const t=e?`-${e}`:"";return l.css`
2384
- ${t&&`@media only screen and ${Ns[e]} {`}
2381
+ `,Ta=l.html`
2382
+ ${e=>Oa(O(e))}
2383
+ `;class Ia extends a.FoundationElement{constructor(){super(...arguments),this.position="right",this.displayHeader=!0,this.closed=!0,this.visuallyhidden=!0}closedChanged(){this.closed||(setTimeout(()=>this.visuallyhidden=!1,1),this.focusExit())}closeFlyout(){this.visuallyhidden=!0}closingFinished(){this.visuallyhidden&&(this.closed=!0,this.$emit("closed"))}focusExit(){this.exit.focus()}}(0,C.Cg)([l.attr],Ia.prototype,"position",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Ia.prototype,"displayHeader",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Ia.prototype,"closed",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Ia.prototype,"visuallyhidden",void 0);const Ra=void 0,Aa={},Da=Ia.compose(Object.assign({baseName:"flyout",styles:ka,template:Ta,shadowOptions:Ra},Aa));var Na;!function(e){e.sm="(max-width: 640px)",e.md="(min-width: 641px) and (max-width: 1023px)",e.lg="(min-width: 1024px)"}(Na||(Na={}));const La=e=>{const t=e?`-${e}`:"";return l.css`
2384
+ ${t&&`@media only screen and ${Na[e]} {`}
2385
2385
  :host(.spacing${t}-1x) slot {
2386
2386
  gap: calc(var(--design-unit) * 2px);
2387
2387
  }
@@ -2466,32 +2466,32 @@
2466
2466
  place-items: stretch;
2467
2467
  }
2468
2468
  ${t&&"}"}
2469
- `},Fs=l.css`
2469
+ `},Fa=l.css`
2470
2470
  slot {
2471
2471
  width: 100%;
2472
2472
  height: 100%;
2473
2473
  display: grid;
2474
2474
  }
2475
2475
 
2476
- ${Ls()}
2477
- ${Ls("lg")}
2478
- ${Ls("md")}
2479
- ${Ls("sm")}
2480
- `,Ms=l.html`
2476
+ ${La()}
2477
+ ${La("lg")}
2478
+ ${La("md")}
2479
+ ${La("sm")}
2480
+ `,Ma=l.html`
2481
2481
  <template>
2482
2482
  <slot></slot>
2483
2483
  </template>
2484
- `,_s=void 0,Hs={};class Ps{constructor(e,t,i,o="1fr",n="1fr"){this.listenerCache=new WeakMap,this.query=window.matchMedia(e);const a=t&&l.cssPartial`grid-template-columns: repeat(${t}, ${o});`,s=i&&l.cssPartial`grid-template-rows: repeat(${i}, ${n});`;this.styles=l.css`
2484
+ `,_a=void 0,Ha={};class Pa{constructor(e,t,i,o="1fr",n="1fr"){this.listenerCache=new WeakMap,this.query=window.matchMedia(e);const s=t&&l.cssPartial`grid-template-columns: repeat(${t}, ${o});`,a=i&&l.cssPartial`grid-template-rows: repeat(${i}, ${n});`;this.styles=l.css`
2485
2485
  slot {
2486
- ${s||""}
2487
2486
  ${a||""}
2487
+ ${s||""}
2488
2488
  }
2489
- `}bind(e){let t=!1;const i=i=>{const{matches:o}=i;o&&!t?(e.$fastController.addStyles(this.styles),t=!0):!o&&t&&(this.styles&&e.$fastController.removeStyles(this.styles),t=!1)};i({matches:this.query.matches}),this.query.addEventListener("change",i),this.listenerCache.set(e,i)}unbind(e){const t=this.listenerCache.get(e);t&&(this.query.removeEventListener("change",t),this.listenerCache.delete(e)),this.styles&&e.$fastController.removeStyles(this.styles)}}class zs extends s.FoundationElement{constructor(){super(...arguments),this.behaviors=[]}connectedCallback(){super.connectedCallback(),this.behaviors=Object.keys(Ns).map(e=>{if(this[`col-${e}-count`]||this[`row-${e}-count`])return new Ps(Ns[e],this[`col-${e}-count`],this[`row-${e}-count`],this[`col-${e}-width`],this[`row-${e}-height`])}).filter(e=>!!e);const e=this["row-count"]&&l.cssPartial`grid-template-rows: repeat(${this["row-count"]}, ${this["row-height"]||"1fr"});`,t=this["col-count"]&&l.cssPartial`grid-template-columns: repeat(${this["col-count"]}, ${this["col-width"]||"1fr"});`;this.baseStyles=l.css`
2489
+ `}bind(e){let t=!1;const i=i=>{const{matches:o}=i;o&&!t?(e.$fastController.addStyles(this.styles),t=!0):!o&&t&&(this.styles&&e.$fastController.removeStyles(this.styles),t=!1)};i({matches:this.query.matches}),this.query.addEventListener("change",i),this.listenerCache.set(e,i)}unbind(e){const t=this.listenerCache.get(e);t&&(this.query.removeEventListener("change",t),this.listenerCache.delete(e)),this.styles&&e.$fastController.removeStyles(this.styles)}}class za extends a.FoundationElement{constructor(){super(...arguments),this.behaviors=[]}connectedCallback(){super.connectedCallback(),this.behaviors=Object.keys(Na).map(e=>{if(this[`col-${e}-count`]||this[`row-${e}-count`])return new Pa(Na[e],this[`col-${e}-count`],this[`row-${e}-count`],this[`col-${e}-width`],this[`row-${e}-height`])}).filter(e=>!!e);const e=this["row-count"]&&l.cssPartial`grid-template-rows: repeat(${this["row-count"]}, ${this["row-height"]||"1fr"});`,t=this["col-count"]&&l.cssPartial`grid-template-columns: repeat(${this["col-count"]}, ${this["col-width"]||"1fr"});`;this.baseStyles=l.css`
2490
2490
  slot {
2491
2491
  ${e||""}
2492
2492
  ${t||""}
2493
2493
  }
2494
- `,this.$fastController.addStyles(this.baseStyles),this.$fastController.addBehaviors(this.behaviors)}disconnectedCallback(){super.disconnectedCallback(),this.$fastController.removeBehaviors(this.behaviors),this.baseStyles&&this.$fastController.removeStyles(this.baseStyles)}}(0,C.Cg)([l.attr],zs.prototype,"col-count",void 0),(0,C.Cg)([l.attr],zs.prototype,"col-width",void 0),(0,C.Cg)([l.attr],zs.prototype,"col-lg-count",void 0),(0,C.Cg)([l.attr],zs.prototype,"col-lg-width",void 0),(0,C.Cg)([l.attr],zs.prototype,"col-md-count",void 0),(0,C.Cg)([l.attr],zs.prototype,"col-md-width",void 0),(0,C.Cg)([l.attr],zs.prototype,"col-sm-count",void 0),(0,C.Cg)([l.attr],zs.prototype,"col-sm-width",void 0),(0,C.Cg)([l.attr],zs.prototype,"row-count",void 0),(0,C.Cg)([l.attr],zs.prototype,"row-height",void 0),(0,C.Cg)([l.attr],zs.prototype,"row-lg-count",void 0),(0,C.Cg)([l.attr],zs.prototype,"row-lg-height",void 0),(0,C.Cg)([l.attr],zs.prototype,"row-md-count",void 0),(0,C.Cg)([l.attr],zs.prototype,"row-md-height",void 0),(0,C.Cg)([l.attr],zs.prototype,"row-sm-count",void 0),(0,C.Cg)([l.attr],zs.prototype,"row-sm-height",void 0);const Us=zs.compose(Object.assign({baseName:"grid-layout",styles:Fs,template:Ms,shadowOptions:_s},Hs)),Bs=l.html`
2494
+ `,this.$fastController.addStyles(this.baseStyles),this.$fastController.addBehaviors(this.behaviors)}disconnectedCallback(){super.disconnectedCallback(),this.$fastController.removeBehaviors(this.behaviors),this.baseStyles&&this.$fastController.removeStyles(this.baseStyles)}}(0,C.Cg)([l.attr],za.prototype,"col-count",void 0),(0,C.Cg)([l.attr],za.prototype,"col-width",void 0),(0,C.Cg)([l.attr],za.prototype,"col-lg-count",void 0),(0,C.Cg)([l.attr],za.prototype,"col-lg-width",void 0),(0,C.Cg)([l.attr],za.prototype,"col-md-count",void 0),(0,C.Cg)([l.attr],za.prototype,"col-md-width",void 0),(0,C.Cg)([l.attr],za.prototype,"col-sm-count",void 0),(0,C.Cg)([l.attr],za.prototype,"col-sm-width",void 0),(0,C.Cg)([l.attr],za.prototype,"row-count",void 0),(0,C.Cg)([l.attr],za.prototype,"row-height",void 0),(0,C.Cg)([l.attr],za.prototype,"row-lg-count",void 0),(0,C.Cg)([l.attr],za.prototype,"row-lg-height",void 0),(0,C.Cg)([l.attr],za.prototype,"row-md-count",void 0),(0,C.Cg)([l.attr],za.prototype,"row-md-height",void 0),(0,C.Cg)([l.attr],za.prototype,"row-sm-count",void 0),(0,C.Cg)([l.attr],za.prototype,"row-sm-height",void 0);const Ua=za.compose(Object.assign({baseName:"grid-layout",styles:Fa,template:Ma,shadowOptions:_a},Ha)),Wa=l.html`
2495
2495
  <template>
2496
2496
  <style>
2497
2497
  :host {
@@ -2520,9 +2520,9 @@
2520
2520
  </style>
2521
2521
  <slot></slot>
2522
2522
  </template>
2523
- `,Ws=void 0,Gs={};class js extends s.FoundationElement{setGridItemProperties(e,t,i,o){if(t&&e&&i&&o){return`grid-row: ${0===t||0===o?"auto":`${t} / ${Number(t)+Number(o)}`}; grid-column: ${0===e||0===i?"auto":`${e} / ${Number(e)+Number(i)}`}`}}}(0,C.Cg)([(0,l.attr)({attribute:"col-number"})],js.prototype,"colNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"col-sm-number"})],js.prototype,"colSmNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"col-md-number"})],js.prototype,"colMdNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"col-lg-number"})],js.prototype,"colLgNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"row-number"})],js.prototype,"rowNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"row-sm-number"})],js.prototype,"rowSmNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"row-md-number"})],js.prototype,"rowMdNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"row-lg-number"})],js.prototype,"rowLgNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"width"})],js.prototype,"width",void 0),(0,C.Cg)([(0,l.attr)({attribute:"width-sm"})],js.prototype,"widthSm",void 0),(0,C.Cg)([(0,l.attr)({attribute:"width-md"})],js.prototype,"widthMd",void 0),(0,C.Cg)([(0,l.attr)({attribute:"width-lg"})],js.prototype,"widthLg",void 0),(0,C.Cg)([(0,l.attr)({attribute:"height"})],js.prototype,"height",void 0),(0,C.Cg)([(0,l.attr)({attribute:"height-sm"})],js.prototype,"heightSm",void 0),(0,C.Cg)([(0,l.attr)({attribute:"height-md"})],js.prototype,"heightMd",void 0),(0,C.Cg)([(0,l.attr)({attribute:"height-lg"})],js.prototype,"heightLg",void 0);const Vs=js.compose(Object.assign({baseName:"grid-layout-item",template:Bs,shadowOptions:Ws},Gs)),Ys=(e,t)=>l.css`
2523
+ `,Ga=void 0,Ba={};class Va extends a.FoundationElement{setGridItemProperties(e,t,i,o){if(t&&e&&i&&o){return`grid-row: ${0===t||0===o?"auto":`${t} / ${Number(t)+Number(o)}`}; grid-column: ${0===e||0===i?"auto":`${e} / ${Number(e)+Number(i)}`}`}}}(0,C.Cg)([(0,l.attr)({attribute:"col-number"})],Va.prototype,"colNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"col-sm-number"})],Va.prototype,"colSmNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"col-md-number"})],Va.prototype,"colMdNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"col-lg-number"})],Va.prototype,"colLgNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"row-number"})],Va.prototype,"rowNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"row-sm-number"})],Va.prototype,"rowSmNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"row-md-number"})],Va.prototype,"rowMdNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"row-lg-number"})],Va.prototype,"rowLgNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"width"})],Va.prototype,"width",void 0),(0,C.Cg)([(0,l.attr)({attribute:"width-sm"})],Va.prototype,"widthSm",void 0),(0,C.Cg)([(0,l.attr)({attribute:"width-md"})],Va.prototype,"widthMd",void 0),(0,C.Cg)([(0,l.attr)({attribute:"width-lg"})],Va.prototype,"widthLg",void 0),(0,C.Cg)([(0,l.attr)({attribute:"height"})],Va.prototype,"height",void 0),(0,C.Cg)([(0,l.attr)({attribute:"height-sm"})],Va.prototype,"heightSm",void 0),(0,C.Cg)([(0,l.attr)({attribute:"height-md"})],Va.prototype,"heightMd",void 0),(0,C.Cg)([(0,l.attr)({attribute:"height-lg"})],Va.prototype,"heightLg",void 0);const ja=Va.compose(Object.assign({baseName:"grid-layout-item",template:Wa,shadowOptions:Ga},Ba)),Ya=(e,t)=>l.css`
2524
2524
  ${(0,r.horizontalScrollStyles)(e,t)}
2525
- `,qs=(e,t)=>(0,s.horizontalScrollTemplate)(e,t);class Ks extends r.HorizontalScroll{}const Xs={delegatesFocus:!0,mode:"open"},Qs={nextFlipper:l.html`
2525
+ `,qa=(e,t)=>(0,a.horizontalScrollTemplate)(e,t);class Ka extends r.HorizontalScroll{}const Xa={delegatesFocus:!0,mode:"open"},Qa={nextFlipper:l.html`
2526
2526
  <foundation-flipper
2527
2527
  @click="${e=>e.scrollToNext()}"
2528
2528
  aria-hidden="${e=>e.flippersHiddenFromAT}"
@@ -2533,7 +2533,7 @@
2533
2533
  direction="previous"
2534
2534
  aria-hidden="${e=>e.flippersHiddenFromAT}"
2535
2535
  ></foundation-flipper>
2536
- `},Js=Ks.compose(Object.assign({baseName:"horizontal-scroll",template:qs,styles:Ys,shadowOptions:Xs},Qs));var Zs=i(70623),er=i(32808),tr=i(10463),ir=i(19037),or=i(22984);const nr=()=>(Zs.Yv.add(or.X7I,ir.C91,tr.Cvc),Zs.tT.css()),ar=(e,t)=>l.css`
2536
+ `},Ja=Ka.compose(Object.assign({baseName:"horizontal-scroll",template:qa,styles:Ya,shadowOptions:Xa},Qa));var Za=i(70623),er=i(32808),tr=i(10463),ir=i(19037),or=i(22984);const nr=()=>(Za.Yv.add(or.X7I,ir.C91,tr.Cvc),Za.tT.css()),sr=(e,t)=>l.css`
2537
2537
  ${nr()}
2538
2538
 
2539
2539
  .fa-stack-1x {
@@ -2608,7 +2608,7 @@
2608
2608
  height: auto;
2609
2609
  box-sizing: border-box;
2610
2610
  }
2611
- `,sr=e=>l.html`
2611
+ `,ar=e=>l.html`
2612
2612
  <template>
2613
2613
  <i
2614
2614
  ${(0,l.ref)("iElement")}
@@ -2627,8 +2627,8 @@
2627
2627
  `)}
2628
2628
  </template>
2629
2629
  `,rr=l.html`
2630
- ${e=>sr(O(e))}
2631
- `,lr={mode:"open",delegatesFocus:!0},dr={};var cr;!function(e){e.solid="fas",e.regular="far",e.brand="fab"}(cr||(cr={}));const ur="1x",hr=["2xs","xs","sm","lg","xl","2xl",ur,"2x","3x","4x","5x","6x","7x","8x","9x","10x","stack-1x","stack-2x"];class pr extends s.FoundationElement{constructor(){super(...arguments),this.isError=!1,this.size="sm",this.variant="solid"}nameChanged(e,t){t&&this.loadIcon()}sizeChanged(e,t){t&&this.loadIcon()}variantChanged(e,t){t&&this.loadIcon()}connectedCallback(){super.connectedCallback(),this.loadIcon()}disconnectedCallback(){super.disconnectedCallback(),this.iElement.replaceChildren()}getDefaultTooltipConfig(){this.name||(this.name="question-circle",this.size="1x",this.variant="regular")}loadIcon(){if(!this.iElement)return;this.tooltip&&(this.tooltipId||(this.tooltipId=this.uuid.createId()),this.getDefaultTooltipConfig());const e=(0,Zs.wu)({prefix:cr[this.variant],iconName:this.name}),t=(0,Zs.Kk)(e);t&&t.node&&(this.iElement.innerHTML="",Array.from(t.node).map(e=>this.iElement.appendChild(e)))}}(0,C.Cg)([l.observable],pr.prototype,"iElement",void 0),(0,C.Cg)([er.k],pr.prototype,"uuid",void 0),(0,C.Cg)([(0,l.attr)({attribute:"tooltip-id"})],pr.prototype,"tooltipId",void 0),(0,C.Cg)([l.attr],pr.prototype,"tooltip",void 0),(0,C.Cg)([(0,l.attr)({attribute:"error",mode:"boolean"})],pr.prototype,"isError",void 0),(0,C.Cg)([l.attr],pr.prototype,"name",void 0),(0,C.Cg)([l.attr],pr.prototype,"size",void 0),(0,C.Cg)([l.attr],pr.prototype,"variant",void 0);const mr=pr.compose(Object.assign({baseName:"icon",template:rr,styles:ar,shadowOptions:lr},dr)),vr=(e,t)=>l.css`
2630
+ ${e=>ar(O(e))}
2631
+ `,lr={mode:"open",delegatesFocus:!0},dr={};var cr;!function(e){e.solid="fas",e.regular="far",e.brand="fab"}(cr||(cr={}));const ur="1x",hr=["2xs","xs","sm","lg","xl","2xl",ur,"2x","3x","4x","5x","6x","7x","8x","9x","10x","stack-1x","stack-2x"];class pr extends a.FoundationElement{constructor(){super(...arguments),this.isError=!1,this.size="sm",this.variant="solid"}nameChanged(e,t){t&&this.loadIcon()}sizeChanged(e,t){t&&this.loadIcon()}variantChanged(e,t){t&&this.loadIcon()}connectedCallback(){super.connectedCallback(),this.loadIcon()}disconnectedCallback(){super.disconnectedCallback(),this.iElement.replaceChildren()}getDefaultTooltipConfig(){this.name||(this.name="question-circle",this.size="1x",this.variant="regular")}loadIcon(){if(!this.iElement)return;this.tooltip&&(this.tooltipId||(this.tooltipId=this.uuid.createId()),this.getDefaultTooltipConfig());const e=(0,Za.wu)({prefix:cr[this.variant],iconName:this.name}),t=(0,Za.Kk)(e);t&&t.node&&(this.iElement.innerHTML="",Array.from(t.node).map(e=>this.iElement.appendChild(e)))}}(0,C.Cg)([l.observable],pr.prototype,"iElement",void 0),(0,C.Cg)([er.k],pr.prototype,"uuid",void 0),(0,C.Cg)([(0,l.attr)({attribute:"tooltip-id"})],pr.prototype,"tooltipId",void 0),(0,C.Cg)([l.attr],pr.prototype,"tooltip",void 0),(0,C.Cg)([(0,l.attr)({attribute:"error",mode:"boolean"})],pr.prototype,"isError",void 0),(0,C.Cg)([l.attr],pr.prototype,"name",void 0),(0,C.Cg)([l.attr],pr.prototype,"size",void 0),(0,C.Cg)([l.attr],pr.prototype,"variant",void 0);const mr=pr.compose(Object.assign({baseName:"icon",template:rr,styles:sr,shadowOptions:lr},dr)),gr=(e,t)=>l.css`
2632
2632
  ${(0,r.listboxStyles)(e,t)}
2633
2633
 
2634
2634
  :host {
@@ -2639,11 +2639,11 @@
2639
2639
  border: calc(var(--stroke-width) * 1px) solid var(--neutral-stroke-rest);
2640
2640
  border-radius: calc(var(--control-corner-radius) * 1px);
2641
2641
  }
2642
- `,gr=(e,t)=>(0,s.listboxTemplate)(e,t);class fr extends r.Listbox{}const br=void 0,yr={},wr=fr.compose(Object.assign({baseName:"listbox",template:gr,styles:vr,shadowOptions:br},yr)),Cr=(e,t)=>l.css`
2642
+ `,vr=(e,t)=>(0,a.listboxTemplate)(e,t);class fr extends r.Listbox{}const br=void 0,yr={},wr=fr.compose(Object.assign({baseName:"listbox",template:vr,styles:gr,shadowOptions:br},yr)),Cr=(e,t)=>l.css`
2643
2643
  ${(0,r.optionStyles)(e,t)}
2644
- `,xr=(e,t)=>(0,s.listboxOptionTemplate)(e,t);class $r extends r.ListboxOption{}const Sr=void 0,Er={},kr=$r.compose(Object.assign({baseName:"option",template:xr,styles:Cr,shadowOptions:Sr},Er)),Or=(e,t)=>l.css`
2644
+ `,xr=(e,t)=>(0,a.listboxOptionTemplate)(e,t);class $r extends r.ListboxOption{}const Sr=void 0,Er={},kr=$r.compose(Object.assign({baseName:"option",template:xr,styles:Cr,shadowOptions:Sr},Er)),Or=(e,t)=>l.css`
2645
2645
  ${(0,r.menuStyles)(e,t)}
2646
- `,Tr=(e,t)=>(0,s.menuTemplate)(e,t);class Ir extends r.Menu{}const Dr=void 0,Rr={},Ar=Ir.compose(Object.assign({baseName:"menu",template:Tr,styles:Or,shadowOptions:Dr},Rr)),Nr=(e,t)=>l.css`
2646
+ `,Tr=(e,t)=>(0,a.menuTemplate)(e,t);class Ir extends r.Menu{}const Rr=void 0,Ar={},Dr=Ir.compose(Object.assign({baseName:"menu",template:Tr,styles:Or,shadowOptions:Rr},Ar)),Nr=(e,t)=>l.css`
2647
2647
  ${(0,r.menuItemStyles)(e,t)}
2648
2648
 
2649
2649
  :host, :host(.indent-0[aria-haspopup='menu']) {
@@ -2657,7 +2657,7 @@
2657
2657
  height: auto;
2658
2658
  width: auto;
2659
2659
  }
2660
- `,Lr=(e,t)=>(0,s.menuItemTemplate)(e,t);class Fr extends r.MenuItem{connectedCallback(){super.connectedCallback(),this.addEventListener("click",()=>this.$emit("onMenuClick"))}}const Mr=void 0,_r={expandCollapseGlyph:'\n <svg\n class="expand-collapse-glyph"\n part="expand-collapse-glyph"\n viewBox="0 0 16 16"\n xmlns="http://www.w3.org/2000/svg">\n <path\n d="M4.023 15.273L11.29 8 4.023.727l.704-.704L12.71 8l-7.984 7.977-.704-.704z"\n />\n </svg>\n '},Hr=Fr.compose(Object.assign({baseName:"menu-item",template:Lr,styles:Nr,shadowOptions:Mr},_r)),Pr=l.css`
2660
+ `,Lr=(e,t)=>(0,a.menuItemTemplate)(e,t);class Fr extends r.MenuItem{connectedCallback(){super.connectedCallback(),this.addEventListener("click",()=>this.$emit("onMenuClick"))}}const Mr=void 0,_r={expandCollapseGlyph:'\n <svg\n class="expand-collapse-glyph"\n part="expand-collapse-glyph"\n viewBox="0 0 16 16"\n xmlns="http://www.w3.org/2000/svg">\n <path\n d="M4.023 15.273L11.29 8 4.023.727l.704-.704L12.71 8l-7.984 7.977-.704-.704z"\n />\n </svg>\n '},Hr=Fr.compose(Object.assign({baseName:"menu-item",template:Lr,styles:Nr,shadowOptions:Mr},_r)),Pr=l.css`
2661
2661
  ${ln}
2662
2662
 
2663
2663
  :host([draggable])::part(top) {
@@ -2665,7 +2665,7 @@
2665
2665
  }
2666
2666
  `,zr=l.html`
2667
2667
  ${hn}
2668
- `,Ur={mode:"open",delegatesFocus:!0},Br={};class Wr extends vn{constructor(){super(...arguments),this.isDragging=!1,this.offsetX=0,this.offsetY=0,this.modalWidth=0,this.modalHeight=0,this.onMouseDownBound=null,this.onMouseMoveBound=null,this.onMouseUpBound=null,this.draggable=!1,this.onCloseCallback=()=>{this.draggable&&this.mainElement instanceof HTMLElement&&Object.assign(this.mainElement.style,{position:"",left:"",top:"",margin:""})}}draggableChanged(e,t){var i,o;t?(this.onMouseDownBound=this.onMouseDown.bind(this),null===(i=this.mainElement)||void 0===i||i.addEventListener("mousedown",this.onMouseDownBound)):(this.onMouseDownBound&&(null===(o=this.mainElement)||void 0===o||o.removeEventListener("mousedown",this.onMouseDownBound),this.onMouseDownBound=null),this.removeDraggableEventListeners())}show(){var e,t;null===(e=this.onShowCallback)||void 0===e||e.call(this),null===(t=this.mainElement)||void 0===t||t.showModal()}connectedCallback(){var e;super.connectedCallback(),this.draggable&&(this.onMouseDownBound=this.onMouseDown.bind(this),null===(e=this.mainElement)||void 0===e||e.addEventListener("mousedown",this.onMouseDownBound))}disconnectedCallback(){var e;super.disconnectedCallback(),this.removeDraggableEventListeners(),this.onMouseDownBound&&(null===(e=this.mainElement)||void 0===e||e.removeEventListener("mousedown",this.onMouseDownBound),this.onMouseDownBound=null)}isEventTargetInDraggableTarget(e){var t;return(null===(t=this.topElement)||void 0===t?void 0:t.contains(e.target))||this.isInsideTopSlot(e.target)}isInsideTopSlot(e){if(!this.topElementSlot)return!1;return this.topElementSlot.assignedNodes().some(t=>t===e||t.contains(e))}onMouseDown(e){if(!this.topElement||!this.isEventTargetInDraggableTarget(e)||this.isDragging)return;this.isDragging=!0;const t=this.mainElement.getBoundingClientRect();this.offsetX=e.clientX-t.left,this.offsetY=e.clientY-t.top,this.modalWidth=t.width,this.modalHeight=t.height,this.onMouseMoveBound=this.onMouseMove.bind(this),this.onMouseUpBound=this.onMouseUp.bind(this),document.addEventListener("mousemove",this.onMouseMoveBound),document.addEventListener("mouseup",this.onMouseUpBound)}onMouseMove(e){if(!this.isDragging||!this.mainElement)return;const t=window.innerWidth,i=window.innerHeight;let o=e.clientX-this.offsetX,n=e.clientY-this.offsetY;o=Math.max(0,Math.min(t-this.modalWidth,o)),n=Math.max(0,Math.min(i-this.modalHeight,n)),requestAnimationFrame(()=>{Object.assign(this.mainElement.style,{position:"absolute",left:`${o}px`,top:`${n}px`,margin:"0"})})}onMouseUp(){this.isDragging=!1,this.removeDraggableEventListeners()}removeDraggableEventListeners(){this.onMouseMoveBound&&(document.removeEventListener("mousemove",this.onMouseMoveBound),this.onMouseMoveBound=null),this.onMouseUpBound&&(document.removeEventListener("mouseup",this.onMouseUpBound),this.onMouseUpBound=null)}}(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Wr.prototype,"draggable",void 0);const Gr=Wr.compose(Object.assign({baseName:"modal",template:zr,styles:Pr,shadowOptions:Ur},Br)),jr=230,Vr=l.css`
2668
+ `,Ur={mode:"open",delegatesFocus:!0},Wr={};class Gr extends gn{constructor(){super(...arguments),this.isDragging=!1,this.offsetX=0,this.offsetY=0,this.modalWidth=0,this.modalHeight=0,this.onMouseDownBound=null,this.onMouseMoveBound=null,this.onMouseUpBound=null,this.draggable=!1,this.onCloseCallback=()=>{this.draggable&&this.mainElement instanceof HTMLElement&&Object.assign(this.mainElement.style,{position:"",left:"",top:"",margin:""})}}draggableChanged(e,t){var i,o;t?(this.onMouseDownBound=this.onMouseDown.bind(this),null===(i=this.mainElement)||void 0===i||i.addEventListener("mousedown",this.onMouseDownBound)):(this.onMouseDownBound&&(null===(o=this.mainElement)||void 0===o||o.removeEventListener("mousedown",this.onMouseDownBound),this.onMouseDownBound=null),this.removeDraggableEventListeners())}show(){var e,t;null===(e=this.onShowCallback)||void 0===e||e.call(this),null===(t=this.mainElement)||void 0===t||t.showModal()}connectedCallback(){var e;super.connectedCallback(),this.draggable&&(this.onMouseDownBound=this.onMouseDown.bind(this),null===(e=this.mainElement)||void 0===e||e.addEventListener("mousedown",this.onMouseDownBound))}disconnectedCallback(){var e;super.disconnectedCallback(),this.removeDraggableEventListeners(),this.onMouseDownBound&&(null===(e=this.mainElement)||void 0===e||e.removeEventListener("mousedown",this.onMouseDownBound),this.onMouseDownBound=null)}isEventTargetInDraggableTarget(e){var t;return(null===(t=this.topElement)||void 0===t?void 0:t.contains(e.target))||this.isInsideTopSlot(e.target)}isInsideTopSlot(e){if(!this.topElementSlot)return!1;return this.topElementSlot.assignedNodes().some(t=>t===e||t.contains(e))}onMouseDown(e){if(!this.topElement||!this.isEventTargetInDraggableTarget(e)||this.isDragging)return;this.isDragging=!0;const t=this.mainElement.getBoundingClientRect();this.offsetX=e.clientX-t.left,this.offsetY=e.clientY-t.top,this.modalWidth=t.width,this.modalHeight=t.height,this.onMouseMoveBound=this.onMouseMove.bind(this),this.onMouseUpBound=this.onMouseUp.bind(this),document.addEventListener("mousemove",this.onMouseMoveBound),document.addEventListener("mouseup",this.onMouseUpBound)}onMouseMove(e){if(!this.isDragging||!this.mainElement)return;const t=window.innerWidth,i=window.innerHeight;let o=e.clientX-this.offsetX,n=e.clientY-this.offsetY;o=Math.max(0,Math.min(t-this.modalWidth,o)),n=Math.max(0,Math.min(i-this.modalHeight,n)),requestAnimationFrame(()=>{Object.assign(this.mainElement.style,{position:"absolute",left:`${o}px`,top:`${n}px`,margin:"0"})})}onMouseUp(){this.isDragging=!1,this.removeDraggableEventListeners()}removeDraggableEventListeners(){this.onMouseMoveBound&&(document.removeEventListener("mousemove",this.onMouseMoveBound),this.onMouseMoveBound=null),this.onMouseUpBound&&(document.removeEventListener("mouseup",this.onMouseUpBound),this.onMouseUpBound=null)}}(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Gr.prototype,"draggable",void 0);const Br=Gr.compose(Object.assign({baseName:"modal",template:zr,styles:Pr,shadowOptions:Ur},Wr)),Vr=230,jr=l.css`
2669
2669
  :host {
2670
2670
  --scrollbar-width: 12px;
2671
2671
  --scrollbar-thumb-width: 8px;
@@ -2809,7 +2809,7 @@
2809
2809
 
2810
2810
  .visible {
2811
2811
  visibility: visible;
2812
- max-height: var(--custom-max-height, ${jr.toString()}px);
2812
+ max-height: var(--custom-max-height, ${Vr.toString()}px);
2813
2813
  overflow: hidden;
2814
2814
  }
2815
2815
 
@@ -2906,7 +2906,7 @@
2906
2906
  resize: none;
2907
2907
  overflow: hidden;
2908
2908
  }
2909
- `;let Yr=class extends si{constructor(){super(...arguments),this.isSnapshot=!0,this.baseCriteria=""}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){var t;e.connectedCallback.call(this),this.baseCriteria=this.criteria,this.fields=this.labelField?null===(t=this.valueField)||void 0===t?void 0:t.concat(" ",this.labelField):this.valueField,this.select=this.parentElement,this.select&&this.valueField&&(this.resourceName&&this.connect.isConnected||this.data)&&this.fetchGenesisData(),this.valueField||Xe.warn('Specify field for values in options (e.g value-field="VALUE") and optionally field for label which is supported only in select and combobox (e.g label-field="NAME")')})}clearData(){this.select.options=[]}syncComponentData(e){var t;const i=(null!=e?e:Array.from(this.rowsSyncedWithStream.values())).map(e=>{var t;return{value:e[this.valueField],label:this.getDefaultLabelFormat(e[this.labelField],null===(t=this.getFieldMetadata(this.labelField))||void 0===t?void 0:t.type)}});(null===(t=this.select)||void 0===t?void 0:t.async)&&(this.select.loading=!1),this.select.options=i}handleStreamInserts(e){Xe.debug("handleStreamInserts - Method not implemented.")}handleStreamDeletes(e){Xe.debug("handleStreamDeletes - Method not implemented.")}handleStreamUpdates(e){Xe.debug("handleStreamUpdates - Method not implemented.")}};(0,C.Cg)([(0,l.attr)({attribute:"value-field"})],Yr.prototype,"valueField",void 0),(0,C.Cg)([(0,l.attr)({attribute:"label-field"})],Yr.prototype,"labelField",void 0),Yr=(0,C.Cg)([(0,l.customElement)({name:"multiselect-datasource"})],Yr);const qr=(e="foundation")=>l.html`
2909
+ `;let Yr=class extends ai{constructor(){super(...arguments),this.isSnapshot=!0,this.baseCriteria=""}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){var t;e.connectedCallback.call(this),this.baseCriteria=this.criteria,this.fields=this.labelField?null===(t=this.valueField)||void 0===t?void 0:t.concat(" ",this.labelField):this.valueField,this.select=this.parentElement,this.select&&this.valueField&&(this.resourceName&&this.connect.isConnected||this.data)&&this.fetchGenesisData(),this.valueField||Xe.warn('Specify field for values in options (e.g value-field="VALUE") and optionally field for label which is supported only in select and combobox (e.g label-field="NAME")')})}clearData(){this.select.options=[]}syncComponentData(e){var t;const i=(null!=e?e:Array.from(this.rowsSyncedWithStream.values())).map(e=>{var t;return{value:e[this.valueField],label:this.getDefaultLabelFormat(e[this.labelField],null===(t=this.getFieldMetadata(this.labelField))||void 0===t?void 0:t.type)}});(null===(t=this.select)||void 0===t?void 0:t.async)&&(this.select.loading=!1),this.select.options=i}handleStreamInserts(e){Xe.debug("handleStreamInserts - Method not implemented.")}handleStreamDeletes(e){Xe.debug("handleStreamDeletes - Method not implemented.")}handleStreamUpdates(e){Xe.debug("handleStreamUpdates - Method not implemented.")}};(0,C.Cg)([(0,l.attr)({attribute:"value-field"})],Yr.prototype,"valueField",void 0),(0,C.Cg)([(0,l.attr)({attribute:"label-field"})],Yr.prototype,"labelField",void 0),Yr=(0,C.Cg)([(0,l.customElement)({name:"multiselect-datasource"})],Yr);const qr=(e="foundation")=>l.html`
2910
2910
  <label
2911
2911
  part="label"
2912
2912
  for="display-field"
@@ -2914,7 +2914,7 @@
2914
2914
  >
2915
2915
  <slot
2916
2916
  name="label"
2917
- ${(0,l.slotted)({property:"defaultSlottedNodes",filter:s.whitespaceFilter})}
2917
+ ${(0,l.slotted)({property:"defaultSlottedNodes",filter:a.whitespaceFilter})}
2918
2918
  ></slot>
2919
2919
  </label>
2920
2920
  <div class="root" part="root" @keydown="${(e,t)=>e.keydownHandler(t.event)}">
@@ -2987,7 +2987,7 @@
2987
2987
  >
2988
2988
  <slot
2989
2989
  name="options-header"
2990
- ${(0,l.slotted)({property:"optionsHeaderSlottedNodes",filter:s.whitespaceFilter})}
2990
+ ${(0,l.slotted)({property:"optionsHeaderSlottedNodes",filter:a.whitespaceFilter})}
2991
2991
  ></slot>
2992
2992
  </li>
2993
2993
  ${(0,l.repeat)(e=>e.filteredAvailableOptions,l.html`
@@ -3017,7 +3017,7 @@
3017
3017
  ></slot>
3018
3018
  `,Kr=l.html`
3019
3019
  ${qr()}
3020
- `,Xr=void 0,Qr={};class Jr extends s.FoundationElement{constructor(){super(...arguments),this.name="",this.autoPosition=!0,this.all=!0,this.allSelected=!1,this.search=!0,this.disabled=!1,this.creatable=!1,this.async=!1,this.debounce=500,this.resizable=!1,this.filterByContains=!1,this.filterSearchValue="",this.clickOutside=e=>this.handleClickOutside(e),this.open=!1,this.options=[],this.selectedOptions=[],this.filteredAvailableOptions=[...this.options],this.position=Nt.BELOW,this.itemRenderer=this.defaultItemRenderer,this.initialisedOptions=!1,this.isResizing=!1,this.startX=0,this.startY=0,this.startWidth=0,this.startHeight=0,this.handleResizeStart=e=>{this.resizable&&this.multiselectDropdown&&(e.preventDefault(),e.stopPropagation(),this.isResizing=!0,this.startX=e.clientX,this.startY=e.clientY,this.startWidth=this.multiselectDropdown.offsetWidth,this.startHeight=this.multiselectDropdown.offsetHeight,this.multiselectDropdown.classList.add("is-resizing"),document.addEventListener("mousemove",this.handleResizeMove),document.addEventListener("mouseup",this.handleResizeEnd))},this.handleResizeMove=e=>{if(!this.isResizing||!this.multiselectDropdown)return;e.preventDefault();const t=e.clientX-this.startX,i=e.clientY-this.startY,o=Math.max(250,this.startWidth+t),n=Math.max(100,this.startHeight+i);this.multiselectDropdown&&(this.multiselectDropdown.style.width=`${o}px`,this.multiselectDropdown.style.maxHeight=`${n}px`)},this.handleResizeEnd=()=>{this.isResizing=!1,document.removeEventListener("mousemove",this.handleResizeMove),document.removeEventListener("mouseup",this.handleResizeEnd),this.multiselectDropdown&&(this.multiselectDropdown.classList.remove("is-resizing"),this.multiselectDropdown.style.setProperty("--custom-max-height",this.multiselectDropdown.style.maxHeight),this.multiselectDropdown.style.removeProperty("max-height"))}}debounceChanged(e,t){this.debouncedInputHandler=Kt()(this.asyncSetFilter,t)}openChanged(e,t){var i,o,n,a;t?(document.addEventListener("mousedown",this.clickOutside),null===(i=this.arrowIcon)||void 0===i||i.classList.add("flipped"),null===(o=this.multiselectDropdown)||void 0===o||o.classList.add("visible")):(document.removeEventListener("mousedown",this.clickOutside),null===(n=this.arrowIcon)||void 0===n||n.classList.remove("flipped"),null===(a=this.multiselectDropdown)||void 0===a||a.classList.remove("visible"))}connectedCallback(){var e;super.connectedCallback(),this.position===Nt.ABOVE&&(null===(e=this.multiselectDropdown)||void 0===e||e.classList.add("position-above"))}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("mousedown",this.clickOutside),document.removeEventListener("mousemove",this.handleResizeMove),document.removeEventListener("mouseup",this.handleResizeEnd)}defaultItemRenderer(e,t){return l.html`
3020
+ `,Xr=void 0,Qr={};class Jr extends a.FoundationElement{constructor(){super(...arguments),this.name="",this.autoPosition=!0,this.all=!0,this.allSelected=!1,this.search=!0,this.disabled=!1,this.creatable=!1,this.async=!1,this.debounce=500,this.resizable=!1,this.filterByContains=!1,this.filterSearchValue="",this.clickOutside=e=>this.handleClickOutside(e),this.open=!1,this.options=[],this.selectedOptions=[],this.filteredAvailableOptions=[...this.options],this.position=Nt.BELOW,this.itemRenderer=this.defaultItemRenderer,this.initialisedOptions=!1,this.isResizing=!1,this.startX=0,this.startY=0,this.startWidth=0,this.startHeight=0,this.handleResizeStart=e=>{this.resizable&&this.multiselectDropdown&&(e.preventDefault(),e.stopPropagation(),this.isResizing=!0,this.startX=e.clientX,this.startY=e.clientY,this.startWidth=this.multiselectDropdown.offsetWidth,this.startHeight=this.multiselectDropdown.offsetHeight,this.multiselectDropdown.classList.add("is-resizing"),document.addEventListener("mousemove",this.handleResizeMove),document.addEventListener("mouseup",this.handleResizeEnd))},this.handleResizeMove=e=>{if(!this.isResizing||!this.multiselectDropdown)return;e.preventDefault();const t=e.clientX-this.startX,i=e.clientY-this.startY,o=Math.max(250,this.startWidth+t),n=Math.max(100,this.startHeight+i);this.multiselectDropdown&&(this.multiselectDropdown.style.width=`${o}px`,this.multiselectDropdown.style.maxHeight=`${n}px`)},this.handleResizeEnd=()=>{this.isResizing=!1,document.removeEventListener("mousemove",this.handleResizeMove),document.removeEventListener("mouseup",this.handleResizeEnd),this.multiselectDropdown&&(this.multiselectDropdown.classList.remove("is-resizing"),this.multiselectDropdown.style.setProperty("--custom-max-height",this.multiselectDropdown.style.maxHeight),this.multiselectDropdown.style.removeProperty("max-height"))}}debounceChanged(e,t){this.debouncedInputHandler=Kt()(this.asyncSetFilter,t)}openChanged(e,t){var i,o,n,s;t?(document.addEventListener("mousedown",this.clickOutside),null===(i=this.arrowIcon)||void 0===i||i.classList.add("flipped"),null===(o=this.multiselectDropdown)||void 0===o||o.classList.add("visible")):(document.removeEventListener("mousedown",this.clickOutside),null===(n=this.arrowIcon)||void 0===n||n.classList.remove("flipped"),null===(s=this.multiselectDropdown)||void 0===s||s.classList.remove("visible"))}connectedCallback(){var e;super.connectedCallback(),this.position===Nt.ABOVE&&(null===(e=this.multiselectDropdown)||void 0===e||e.classList.add("position-above"))}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("mousedown",this.clickOutside),document.removeEventListener("mousemove",this.handleResizeMove),document.removeEventListener("mouseup",this.handleResizeEnd)}defaultItemRenderer(e,t){return l.html`
3021
3021
  ${"string"==typeof e?l.html`
3022
3022
  <span part="option-label">${()=>t.getItemLabel(e)}</span>
3023
3023
  `:l.html`
@@ -3029,7 +3029,7 @@
3029
3029
  ${()=>t.getItemLabel(e)}
3030
3030
  </span>
3031
3031
  `}
3032
- `}toggle(){this.open||this.setDropdownPosition(),this.open=!this.open}optionsChanged(){this.allSelected&&!this.initialisedOptions&&(this.selectedOptions=this.options.map(e=>this.optionValueGetter(e))),this.filteredAvailableOptions=[...this.options]}selectedOptionsChanged(){this.$fastController.isConnected&&(this.initialisedOptions=!0)}setDropdownPosition(){let e=this.position;if(this.autoPosition){const t=this.getBoundingClientRect(),i=window.innerHeight,o=t.top,n=i-t.bottom;e=n<jr&&o>n?Nt.ABOVE:Nt.BELOW}this.multiselectDropdown.classList.toggle("position-above",e===Nt.ABOVE),this.multiselectDropdown.classList.toggle("position-below",e===Nt.BELOW)}optionValueGetter(e){return"string"==typeof e?e:e.value}optionLabelGetter(e){return"string"==typeof e?e:e.label}getItemLabel(e){let t;return e?(t="string"==typeof e?e:this.optionLabelGetter(e)||this.optionValueGetter(e)||"",this.valueFormatter?this.valueFormatter(t):t):""}isOptionDisabled(e){return e&&"string"!=typeof e&&e.disabled||!1}get getDisplayValue(){let e="";switch(this.selectedOptions.length){case 0:e=this.getPlaceholder;break;case 1:{const t=this.options.find(e=>this.optionValueGetter(e)===this.selectedOptions[0]);e=this.getItemLabel(t);break}case this.options.length:e=`All ${this.name}`.trim();break;default:e=`${this.selectedOptions.length} Selected`}return e}get getPlaceholder(){return`Search ${this.name}`.trim().concat("...")}get isAllOptionsDisabled(){return this.options.length===this.options.filter(this.isOptionDisabled).length}get showCreatable(){return this.creatable&&this.filterSearchValue.length>0&&0===this.findExactMatchOptions().length}isOptionSelected(e){const t=this.optionValueGetter(e);return this.selectedOptions.some(i=>{if("object"==typeof e&&"object"==typeof e.value)try{return JSON.stringify(i)===JSON.stringify(t)}catch(e){return i===t}return i===t})}selectCheckboxOne(e){const t=this.optionValueGetter(e),i=this.selectedOptions.includes(t);this.selectedOptions=i?this.selectedOptions.filter(e=>e!==t):[...this.selectedOptions,t],this.$emit("selectionChange",this.selectedOptions)}checkboxKeyDown(e,t){return" "===t.key&&(t.preventDefault(),this.selectCheckboxOne(e)),!0}getEnabledOptionsCount(){return this.options.length-this.options.filter(this.isOptionDisabled).length}selectCheckboxAll(){const e=this.selectedOptions.length===this.getEnabledOptionsCount();this.selectedOptions=e?[]:this.options.filter(e=>!this.isOptionDisabled(e)).map(e=>this.optionValueGetter(e)),this.onAllSelectedCallback&&this.onAllSelectedCallback(!e),this.$emit("selectionChange",this.selectedOptions)}inputHandler(){this.open||(this.open=!0),this.async?(this.loading=!0,this.filteredAvailableOptions=[],this.debouncedInputHandler()):this.setFilter()}findExactMatchOptions(){const e=this.filterSearchValue.toLowerCase();return this.filteredAvailableOptions.filter(t=>{var i,o;const n="string"==typeof t?t:null!==(i=this.optionLabelGetter(t))&&void 0!==i?i:this.optionValueGetter(t);return(null!==(o=null==n?void 0:n.toLowerCase())&&void 0!==o?o:"")===e})}setFilter(){const e=this.filterSearchValue.toLowerCase();this.filteredAvailableOptions=this.options.filter(t=>{if(!e)return!0;if("string"==typeof t)return t.toLowerCase().includes(e);const i=t.label.toLowerCase(),o="object"==typeof t.value?(n=t.value,Object.values(n).some(t=>t.toLowerCase().includes(e))):String(t.value).toLowerCase().includes(e);var n;return i.includes(e)||o})}addOption(){this.options=[{value:this.filterSearchValue,label:this.filterSearchValue},...this.options],this.setFilter(),this.selectedOptions=[...this.selectedOptions,this.filterSearchValue]}asyncSetFilter(){this.slottedDatasource.length>0?ri(this.slottedDatasource[0],this.filterSearchValue):(this.loading=!1,Xe.warn("Multiselect-datasource is not connected. Please add a datasource to use this functionality."))}changeHandler(e){e.preventDefault(),e.stopImmediatePropagation()}handleClickOutside(e){E(e,this)&&(this.open=!1)}keydownHandler(e){const t=e.key;if(e.ctrlKey||e.shiftKey)return!0;switch(t){case"Escape":if(this.open){this.open=!1;break}break;case"ArrowUp":case"ArrowDown":if(!this.open){this.open=!0;break}break;default:return!0}}clear(e={}){const{clearSelectedValues:t=!0,clearFilterText:i=!0}=e;t&&(this.selectedOptions=[],this.$emit("selectionChange",this.selectedOptions)),i&&(this.filterSearchValue="",this.setFilter(),this.filterSearchInput&&(this.filterSearchInput.value="")),this.$emit("clear",{clearSelectedValues:t,clearFilterText:i})}}(0,C.Cg)([l.attr],Jr.prototype,"name",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"auto-position"})],Jr.prototype,"autoPosition",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"all",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"allSelected",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"search",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"disabled",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"creatable",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"async",void 0),(0,C.Cg)([l.attr],Jr.prototype,"debounce",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"resizable",void 0),(0,C.Cg)([l.attr],Jr.prototype,"tabindex",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"filter-by-contains"})],Jr.prototype,"filterByContains",void 0),(0,C.Cg)([l.observable],Jr.prototype,"defaultSlottedNodes",void 0),(0,C.Cg)([l.observable],Jr.prototype,"slottedDatasource",void 0),(0,C.Cg)([l.observable],Jr.prototype,"valueFormatter",void 0),(0,C.Cg)([l.observable],Jr.prototype,"loading",void 0),(0,C.Cg)([l.observable],Jr.prototype,"filterSearchValue",void 0),(0,C.Cg)([l.observable],Jr.prototype,"open",void 0),(0,C.Cg)([l.observable],Jr.prototype,"options",void 0),(0,C.Cg)([l.observable],Jr.prototype,"selectedOptions",void 0),(0,C.Cg)([l.observable],Jr.prototype,"filteredAvailableOptions",void 0),(0,C.Cg)([l.observable],Jr.prototype,"scrollContainer",void 0),(0,C.Cg)([l.attr],Jr.prototype,"position",void 0),(0,C.Cg)([l.observable],Jr.prototype,"onAllSelectedCallback",void 0),(0,C.Cg)([l.observable],Jr.prototype,"itemRenderer",void 0),(0,C.Cg)([l.volatile],Jr.prototype,"getDisplayValue",null),(0,C.Cg)([l.volatile],Jr.prototype,"getPlaceholder",null),(0,C.Cg)([l.volatile],Jr.prototype,"isAllOptionsDisabled",null),(0,C.Cg)([l.volatile],Jr.prototype,"showCreatable",null),(0,C.Cg)([l.observable],Jr.prototype,"optionsHeaderSlottedNodes",void 0);const Zr=Jr.compose(Object.assign({baseName:"multiselect",template:Kr,styles:Vr,shadowOptions:Xr},Qr));class el{constructor(e){const t=new Intl.NumberFormat(e).formatToParts(12345.6),i=[...new Intl.NumberFormat(e,{useGrouping:!1}).format(9876543210)].reverse(),o=new Map(i.map((e,t)=>[e,t]));this._group=new RegExp(`[${t.find(e=>"group"===e.type).value}]`,"g"),this._decimal=new RegExp(`[${t.find(e=>"decimal"===e.type).value}]`),this._separator=new RegExp(`[$${t.find(e=>"decimal"===e.type).value}](?:0*$|[^0]0+$)`),this._numeral=new RegExp(`[${i.join("")}]`,"g"),this._index=e=>o.get(e)}parse(e){return(e=e.trim().replace(this._group,"").replace(this._decimal,".").replace(this._numeral,this._index))?+e:NaN}hasSeparator(e){return this._separator.test(e)}}const tl=(e,t)=>l.css`
3032
+ `}toggle(){this.open||this.setDropdownPosition(),this.open=!this.open}optionsChanged(){this.allSelected&&!this.initialisedOptions&&(this.selectedOptions=this.options.map(e=>this.optionValueGetter(e))),this.filteredAvailableOptions=[...this.options]}selectedOptionsChanged(){this.$fastController.isConnected&&(this.initialisedOptions=!0)}setDropdownPosition(){let e=this.position;if(this.autoPosition){const t=this.getBoundingClientRect(),i=window.innerHeight,o=t.top,n=i-t.bottom;e=n<Vr&&o>n?Nt.ABOVE:Nt.BELOW}this.multiselectDropdown.classList.toggle("position-above",e===Nt.ABOVE),this.multiselectDropdown.classList.toggle("position-below",e===Nt.BELOW)}optionValueGetter(e){return"string"==typeof e?e:e.value}optionLabelGetter(e){return"string"==typeof e?e:e.label}getItemLabel(e){let t;return e?(t="string"==typeof e?e:this.optionLabelGetter(e)||this.optionValueGetter(e)||"",this.valueFormatter?this.valueFormatter(t):t):""}isOptionDisabled(e){return e&&"string"!=typeof e&&e.disabled||!1}get getDisplayValue(){let e="";switch(this.selectedOptions.length){case 0:e=this.getPlaceholder;break;case 1:{const t=this.options.find(e=>this.optionValueGetter(e)===this.selectedOptions[0]);e=this.getItemLabel(t);break}case this.options.length:e=`All ${this.name}`.trim();break;default:e=`${this.selectedOptions.length} Selected`}return e}get getPlaceholder(){return`Search ${this.name}`.trim().concat("...")}get isAllOptionsDisabled(){return this.options.length===this.options.filter(this.isOptionDisabled).length}get showCreatable(){return this.creatable&&this.filterSearchValue.length>0&&0===this.findExactMatchOptions().length}isOptionSelected(e){const t=this.optionValueGetter(e);return this.selectedOptions.some(i=>{if("object"==typeof e&&"object"==typeof e.value)try{return JSON.stringify(i)===JSON.stringify(t)}catch(e){return i===t}return i===t})}selectCheckboxOne(e){const t=this.optionValueGetter(e),i=this.selectedOptions.includes(t);this.selectedOptions=i?this.selectedOptions.filter(e=>e!==t):[...this.selectedOptions,t],this.$emit("selectionChange",this.selectedOptions)}checkboxKeyDown(e,t){return" "===t.key&&(t.preventDefault(),this.selectCheckboxOne(e)),!0}getEnabledOptionsCount(){return this.options.length-this.options.filter(this.isOptionDisabled).length}selectCheckboxAll(){const e=this.selectedOptions.length===this.getEnabledOptionsCount();this.selectedOptions=e?[]:this.options.filter(e=>!this.isOptionDisabled(e)).map(e=>this.optionValueGetter(e)),this.onAllSelectedCallback&&this.onAllSelectedCallback(!e),this.$emit("selectionChange",this.selectedOptions)}inputHandler(){this.open||(this.open=!0),this.async?(this.loading=!0,this.filteredAvailableOptions=[],this.debouncedInputHandler()):this.setFilter()}findExactMatchOptions(){const e=this.filterSearchValue.toLowerCase();return this.filteredAvailableOptions.filter(t=>{var i,o;const n="string"==typeof t?t:null!==(i=this.optionLabelGetter(t))&&void 0!==i?i:this.optionValueGetter(t);return(null!==(o=null==n?void 0:n.toLowerCase())&&void 0!==o?o:"")===e})}setFilter(){const e=this.filterSearchValue.toLowerCase();this.filteredAvailableOptions=this.options.filter(t=>{if(!e)return!0;if("string"==typeof t)return t.toLowerCase().includes(e);const i=t.label.toLowerCase(),o="object"==typeof t.value?(n=t.value,Object.values(n).some(t=>t.toLowerCase().includes(e))):String(t.value).toLowerCase().includes(e);var n;return i.includes(e)||o})}addOption(){this.options=[{value:this.filterSearchValue,label:this.filterSearchValue},...this.options],this.setFilter(),this.selectedOptions=[...this.selectedOptions,this.filterSearchValue]}asyncSetFilter(){this.slottedDatasource.length>0?ri(this.slottedDatasource[0],this.filterSearchValue):(this.loading=!1,Xe.warn("Multiselect-datasource is not connected. Please add a datasource to use this functionality."))}changeHandler(e){e.preventDefault(),e.stopImmediatePropagation()}handleClickOutside(e){E(e,this)&&(this.open=!1)}keydownHandler(e){const t=e.key;if(e.ctrlKey||e.shiftKey)return!0;switch(t){case"Escape":if(this.open){this.open=!1;break}break;case"ArrowUp":case"ArrowDown":if(!this.open){this.open=!0;break}break;default:return!0}}clear(e={}){const{clearSelectedValues:t=!0,clearFilterText:i=!0}=e;t&&(this.selectedOptions=[],this.$emit("selectionChange",this.selectedOptions)),i&&(this.filterSearchValue="",this.setFilter(),this.filterSearchInput&&(this.filterSearchInput.value="")),this.$emit("clear",{clearSelectedValues:t,clearFilterText:i})}}(0,C.Cg)([l.attr],Jr.prototype,"name",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"auto-position"})],Jr.prototype,"autoPosition",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"all",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"allSelected",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"search",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"disabled",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"creatable",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"async",void 0),(0,C.Cg)([l.attr],Jr.prototype,"debounce",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Jr.prototype,"resizable",void 0),(0,C.Cg)([l.attr],Jr.prototype,"tabindex",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"filter-by-contains"})],Jr.prototype,"filterByContains",void 0),(0,C.Cg)([l.observable],Jr.prototype,"defaultSlottedNodes",void 0),(0,C.Cg)([l.observable],Jr.prototype,"slottedDatasource",void 0),(0,C.Cg)([l.observable],Jr.prototype,"valueFormatter",void 0),(0,C.Cg)([l.observable],Jr.prototype,"loading",void 0),(0,C.Cg)([l.observable],Jr.prototype,"filterSearchValue",void 0),(0,C.Cg)([l.observable],Jr.prototype,"open",void 0),(0,C.Cg)([l.observable],Jr.prototype,"options",void 0),(0,C.Cg)([l.observable],Jr.prototype,"selectedOptions",void 0),(0,C.Cg)([l.observable],Jr.prototype,"filteredAvailableOptions",void 0),(0,C.Cg)([l.observable],Jr.prototype,"scrollContainer",void 0),(0,C.Cg)([l.attr],Jr.prototype,"position",void 0),(0,C.Cg)([l.observable],Jr.prototype,"onAllSelectedCallback",void 0),(0,C.Cg)([l.observable],Jr.prototype,"itemRenderer",void 0),(0,C.Cg)([l.volatile],Jr.prototype,"getDisplayValue",null),(0,C.Cg)([l.volatile],Jr.prototype,"getPlaceholder",null),(0,C.Cg)([l.volatile],Jr.prototype,"isAllOptionsDisabled",null),(0,C.Cg)([l.volatile],Jr.prototype,"showCreatable",null),(0,C.Cg)([l.observable],Jr.prototype,"optionsHeaderSlottedNodes",void 0);const Zr=Jr.compose(Object.assign({baseName:"multiselect",template:Kr,styles:jr,shadowOptions:Xr},Qr));class el{constructor(e){const t=new Intl.NumberFormat(e).formatToParts(12345.6),i=[...new Intl.NumberFormat(e,{useGrouping:!1}).format(9876543210)].reverse(),o=new Map(i.map((e,t)=>[e,t]));this._group=new RegExp(`[${t.find(e=>"group"===e.type).value}]`,"g"),this._decimal=new RegExp(`[${t.find(e=>"decimal"===e.type).value}]`),this._separator=new RegExp(`[$${t.find(e=>"decimal"===e.type).value}](?:0*$|[^0]0+$)`),this._numeral=new RegExp(`[${i.join("")}]`,"g"),this._index=e=>o.get(e)}parse(e){return(e=e.trim().replace(this._group,"").replace(this._decimal,".").replace(this._numeral,this._index))?+e:NaN}hasSeparator(e){return this._separator.test(e)}}const tl=(e,t)=>l.css`
3033
3033
  ${(0,r.numberFieldStyles)(e,t)}
3034
3034
  ::part(label) {
3035
3035
  color: var(--neutral-foreground-rest);
@@ -3073,7 +3073,7 @@
3073
3073
  <slot ${(0,l.slotted)("defaultSlottedNodes")}></slot>
3074
3074
  </label>
3075
3075
  <div class="root" part="root">
3076
- ${(0,s.startSlotTemplate)(e,t)}
3076
+ ${(0,a.startSlotTemplate)(e,t)}
3077
3077
  <input
3078
3078
  class="control"
3079
3079
  part="control"
@@ -3129,10 +3129,10 @@
3129
3129
  </div>
3130
3130
  </div>
3131
3131
  `)}
3132
- ${(0,s.endSlotTemplate)(e,t)}
3132
+ ${(0,a.endSlotTemplate)(e,t)}
3133
3133
  </div>
3134
3134
  </template>
3135
- `,ol=9,nl=(e,t)=>{var i;return{decimalSeparator:(null===(i=new Intl.NumberFormat(t).formatToParts(12345.6).find(e=>"decimal"===e.type))||void 0===i?void 0:i.value)||"."}},al=(e,t)=>{const{decimalSeparator:i}=nl(0,t);return"."===i?e:e.replace(/\./g,i)},sl=(e,t,i)=>Intl.NumberFormat(t,i).format(Number(e)),rl=(e,t)=>{if(!e||""===e)return e;const i=Number(e);if(isNaN(i))return e;const o=e.indexOf("."),n=-1!==o,a=n?e.length-o-1:0,s=t.minimumFractionDigits,r=t.maximumFractionDigits;if(a>=s&&a<=r)return e;let l=e;if(a<s){n||(l=e+".");l+="0".repeat(s-a)}if(a>r){const t=n?e.substring(0,o):e,i=(n?e.substring(o+1):"").substring(0,r);l=0===r?t:`${t}.${i}`}return l},ll=(e,t,i=!0,o)=>{if(null==e||""===e)return"";const n="number"==typeof e?e.toString():e,a=null!=o?o:12;let s;if(i)s=((e,t)=>String(new el(t).parse(String(e))))(n,t);else{const{decimalSeparator:e}=nl(0,t);if("."!==e){s=n.replace(new RegExp(`\\${e}`,"g"),".");const t=s.indexOf(".");-1!==t&&(s=s.substring(0,t))}else s=n}s=String(s);if(!/^-?\d*\.?\d+$/.test(s))return"";if(void 0!==a){if(s.replace(".","").replace(/^0+/,"").length>a){const e=s.indexOf(".");if(-1!==e){const t=s.substring(0,e),i=t.length;if(i>=a)return s.substring(0,a);{const o=a-i;return`${t}.${s.substring(e+1).substring(0,o)}`}}return s.substring(0,a)}}return s},dl=(e,t,i)=>((e,t,i)=>{const{decimalSeparator:o}=nl(0,i),n=o.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),a=new RegExp(`${n}(\\d*?)(0+)$`),s=e.match(a);if(s){const e=s[1],i=s[2],o=String(t);if(!isNaN(Number(t))){if(o.includes(".")){const t=o.split(".")[1],n=Math.max(0,i.length-(t.length-e.length));return o+"0".repeat(n)}return o+"."+e+i}}return String(t)})(e,ll(e,t,void 0,i),t),cl=(e,t,i=!0,o,n,a)=>{let s=parseFloat(ll(e,t,i,a));return isNaN(s)?s="":(s=Math.min(s,null!=n?n:s),s=Math.max(s,null!=o?o:s)),String(s)},ul=e=>{try{const t="string"==typeof e?e:e.toString(),i=t.indexOf(".");if(-1===i)return 1;const o=t.substring(i+1).length;if(0===o)return 1;const n=Math.pow(10,-o);return parseFloat(n.toFixed(o))}catch(t){const i="string"==typeof e?e:e.toString(),o=i.indexOf(".");if(-1===o)return 1;const n=i.substring(o+1).length;if(0===n)return 1;const a=Math.pow(10,-n);return parseFloat(a.toFixed(n))}};class hl extends r.NumberField{constructor(){super(...arguments),this.autocomplete="off",this.hideStep=!1,this.value="",this.withFormatting=!1,this.locale="en-US",this.autoStepPrecision=!1,this.maximumInputPrecision=12,this.options={maximumFractionDigits:3,minimumFractionDigits:0}}autocompleteChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.autocomplete=this.autocomplete)}stepUp(){if(/^-?\d*\.?\d+$/.test(this.value)&&""!==this.value){let e;e=this.autoStepPrecision?ul(this.value):this.step;const t=((e,t)=>{try{const i="string"==typeof e?e:e.toString(),o=i.indexOf(".");if(-1===o)return(parseInt(i)+t).toString();const n=i.substring(o+1),a=n.length-1,s=parseInt(n.charAt(a))+1;if(s<=ol){const e=n.substring(0,a)+s;return i.substring(0,o+1)+e}{let e="",t=1;for(let i=a;i>=0;i-=1){const o=parseInt(n.charAt(i))+t;o<=ol?(e=o+e,t=0):(e="0"+e,t=1)}return 1===t?parseInt(i.substring(0,o))+1+"."+e:i.substring(0,o+1)+e}}catch(i){return(("string"==typeof e?parseFloat(e):e)+t).toString()}})(this.value,e);this.value=t.toString()}else{const e=this.min>0?this.min:this.max<0?this.max:this.min?0:this.step;this.value=e.toString()}this.control&&(void 0!==this.min||void 0!==this.max?this.control.value=cl(this.value,this.locale,this.withFormatting,this.min,this.max,this.maximumInputPrecision):this.control.value=this.value),this.handleTextInput()}stepDown(){if(/^-?\d*\.?\d+$/.test(this.value)&&""!==this.value){let e;e=this.autoStepPrecision?ul(this.value):this.step;const t=((e,t)=>{try{const i="string"==typeof e?e:e.toString(),o=i.indexOf(".");if(-1===o)return(parseInt(i)-t).toString();const n=i.substring(o+1),a=n.length-1,s=parseInt(n.charAt(a))-1;if(s>=0){const e=n.substring(0,a)+s;return i.substring(0,o+1)+e}{let e="",t=1;for(let i=a;i>=0;i-=1){const o=parseInt(n.charAt(i))-t;o>=0?(e=o+e,t=0):(e=ol.toString()+e,t=1)}return 1===t?parseInt(i.substring(0,o))-1+"."+e:i.substring(0,o+1)+e}}catch(i){return(("string"==typeof e?parseFloat(e):e)-t).toString()}})(this.value,e);this.value=t.toString()}else{const e=this.min>0?this.min:this.max<0?this.max:this.min?0:0-this.step;this.value=e.toString()}this.control&&(void 0!==this.min||void 0!==this.max?this.control.value=cl(this.value,this.locale,this.withFormatting,this.min,this.max,this.maximumInputPrecision):this.control.value=this.value),this.handleTextInput()}hasSeparatorWithoutDecimals(){return new RegExp("[.]$")}handleTextInput(){this.control&&"-"!==this.control.value&&"-0"!==this.control.value&&(this.isUserInput=!0,this.withFormatting&&!new el(this.locale).hasSeparator(this.control.value)?l.DOM.queueUpdate(()=>{const e=dl(this.control.value,this.locale,this.maximumInputPrecision);this.value=rl(e,this.options),this.control&&(this.control.value=rl(al(e,this.locale),this.options)),this.$emit("input")}):this.withFormatting||this.hasSeparatorWithoutDecimals().test(this.control.value)||l.DOM.queueUpdate(()=>{var e;this.control&&(this.control.value=this.control.value.replace(/[^0-9\-+e.]/g,"")),this.value=(null===(e=this.control)||void 0===e?void 0:e.value)||"",this.$emit("input")}))}valueChanged(e,t){if(null==t&&this.control)this.control.value="";else if(null!=t&&t!==e){if(!this.isUserInput)return this.value=cl(this.value,this.locale,!1,this.min,this.max,this.maximumInputPrecision),void l.DOM.queueUpdate(()=>{this.control&&(this.control.value=this.withFormatting&&this.value?sl(this.value,this.locale,this.options):this.value)});const e=t;l.DOM.queueUpdate(()=>{this.control&&(""!==this.control.value&&""!==this.value?(this.control.value=al(String(e),this.locale),this.value=this.withFormatting?dl(this.control.value,this.locale,this.maximumInputPrecision):this.control.value):this.control.value=e)})}}handleBlur(){if(!this.control)return;this.isUserInput=!1;const e=cl(this.control.value,this.locale,this.withFormatting,this.min,this.max,this.maximumInputPrecision);e&&/^-?\d*\.?\d+$/.test(e)&&(this.value=this.withFormatting?rl(e,this.options):e),this.control.value=this.withFormatting&&this.value?sl(this.value,this.locale,this.options):e,this.$emit("input")}}(0,C.Cg)([l.attr],hl.prototype,"autocomplete",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],hl.prototype,"hideStep",void 0),(0,C.Cg)([l.attr],hl.prototype,"value",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],hl.prototype,"withFormatting",void 0),(0,C.Cg)([l.attr],hl.prototype,"locale",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],hl.prototype,"autoStepPrecision",void 0),(0,C.Cg)([l.attr],hl.prototype,"maximumInputPrecision",void 0);const pl={delegatesFocus:!0,mode:"open"},ml={stepDownGlyph:'\n <svg class="step-down-glyph" viewBox="0 0 24 24" width="1rem" height="1rem" xmlns="http://www.w3.org/2000/svg">\n <path d="M6.1018 8C5.02785 8 4.45387 9.2649 5.16108 10.0731L10.6829 16.3838C11.3801 17.1806 12.6197 17.1806 13.3169 16.3838L18.8388 10.0731C19.5459 9.2649 18.972 8 17.898 8H6.1018Z"/>\n </svg>\n ',stepUpGlyph:'\n <svg class="step-up-glyph" viewBox="0 0 24 24" width="1rem" height="1rem" xmlns="http://www.w3.org/2000/svg">\n <path d="M6.1018 16.9814C5.02785 16.9814 4.45387 15.7165 5.16108 14.9083L10.6829 8.59762C11.3801 7.80079 12.6197 7.80079 13.3169 8.59762L18.8388 14.9083C19.5459 15.7165 18.972 16.9814 17.898 16.9814H6.1018Z"/>\n </svg>\n '},vl=hl.compose(Object.assign({baseName:"number-field",template:il,styles:tl,shadowOptions:pl},ml)),gl=(e,t)=>l.css`
3135
+ `,ol=9,nl=(e,t)=>{var i;return{decimalSeparator:(null===(i=new Intl.NumberFormat(t).formatToParts(12345.6).find(e=>"decimal"===e.type))||void 0===i?void 0:i.value)||"."}},sl=(e,t)=>{const{decimalSeparator:i}=nl(0,t);return"."===i?e:e.replace(/\./g,i)},al=(e,t,i)=>Intl.NumberFormat(t,i).format(Number(e)),rl=(e,t)=>{if(!e||""===e)return e;const i=Number(e);if(isNaN(i))return e;const o=e.indexOf("."),n=-1!==o,s=n?e.length-o-1:0,a=t.minimumFractionDigits,r=t.maximumFractionDigits;if(s>=a&&s<=r)return e;let l=e;if(s<a){n||(l=e+".");l+="0".repeat(a-s)}if(s>r){const t=n?e.substring(0,o):e,i=(n?e.substring(o+1):"").substring(0,r);l=0===r?t:`${t}.${i}`}return l},ll=(e,t,i=!0,o)=>{if(null==e||""===e)return"";const n="number"==typeof e?e.toString():e,s=null!=o?o:12;let a;if(i)a=((e,t)=>String(new el(t).parse(String(e))))(n,t);else{const{decimalSeparator:e}=nl(0,t);if("."!==e){a=n.replace(new RegExp(`\\${e}`,"g"),".");const t=a.indexOf(".");-1!==t&&(a=a.substring(0,t))}else a=n}a=String(a);if(!/^-?\d*\.?\d+$/.test(a))return"";if(void 0!==s){if(a.replace(".","").replace(/^0+/,"").length>s){const e=a.indexOf(".");if(-1!==e){const t=a.substring(0,e),i=t.length;if(i>=s)return a.substring(0,s);{const o=s-i;return`${t}.${a.substring(e+1).substring(0,o)}`}}return a.substring(0,s)}}return a},dl=(e,t,i)=>((e,t,i)=>{const{decimalSeparator:o}=nl(0,i),n=o.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),s=new RegExp(`${n}(\\d*?)(0+)$`),a=e.match(s);if(a){const e=a[1],i=a[2],o=String(t);if(!isNaN(Number(t))){if(o.includes(".")){const t=o.split(".")[1],n=Math.max(0,i.length-(t.length-e.length));return o+"0".repeat(n)}return o+"."+e+i}}return String(t)})(e,ll(e,t,void 0,i),t),cl=(e,t,i=!0,o,n,s)=>{let a=parseFloat(ll(e,t,i,s));return isNaN(a)?a="":(a=Math.min(a,null!=n?n:a),a=Math.max(a,null!=o?o:a)),String(a)},ul=e=>{try{const t="string"==typeof e?e:e.toString(),i=t.indexOf(".");if(-1===i)return 1;const o=t.substring(i+1).length;if(0===o)return 1;const n=Math.pow(10,-o);return parseFloat(n.toFixed(o))}catch(t){const i="string"==typeof e?e:e.toString(),o=i.indexOf(".");if(-1===o)return 1;const n=i.substring(o+1).length;if(0===n)return 1;const s=Math.pow(10,-n);return parseFloat(s.toFixed(n))}};class hl extends r.NumberField{constructor(){super(...arguments),this.autocomplete="off",this.hideStep=!1,this.value="",this.withFormatting=!1,this.locale="en-US",this.autoStepPrecision=!1,this.maximumInputPrecision=12,this.options={maximumFractionDigits:3,minimumFractionDigits:0}}autocompleteChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.autocomplete=this.autocomplete)}stepUp(){if(/^-?\d*\.?\d+$/.test(this.value)&&""!==this.value){let e;e=this.autoStepPrecision?ul(this.value):this.step;const t=((e,t)=>{try{const i="string"==typeof e?e:e.toString(),o=i.indexOf(".");if(-1===o)return(parseInt(i)+t).toString();const n=i.substring(o+1),s=n.length-1,a=parseInt(n.charAt(s))+1;if(a<=ol){const e=n.substring(0,s)+a;return i.substring(0,o+1)+e}{let e="",t=1;for(let i=s;i>=0;i-=1){const o=parseInt(n.charAt(i))+t;o<=ol?(e=o+e,t=0):(e="0"+e,t=1)}return 1===t?parseInt(i.substring(0,o))+1+"."+e:i.substring(0,o+1)+e}}catch(i){return(("string"==typeof e?parseFloat(e):e)+t).toString()}})(this.value,e);this.value=t.toString()}else{const e=this.min>0?this.min:this.max<0?this.max:this.min?0:this.step;this.value=e.toString()}this.control&&(void 0!==this.min||void 0!==this.max?this.control.value=cl(this.value,this.locale,this.withFormatting,this.min,this.max,this.maximumInputPrecision):this.control.value=this.value),this.handleTextInput()}stepDown(){if(/^-?\d*\.?\d+$/.test(this.value)&&""!==this.value){let e;e=this.autoStepPrecision?ul(this.value):this.step;const t=((e,t)=>{try{const i="string"==typeof e?e:e.toString(),o=i.indexOf(".");if(-1===o)return(parseInt(i)-t).toString();const n=i.substring(o+1),s=n.length-1,a=parseInt(n.charAt(s))-1;if(a>=0){const e=n.substring(0,s)+a;return i.substring(0,o+1)+e}{let e="",t=1;for(let i=s;i>=0;i-=1){const o=parseInt(n.charAt(i))-t;o>=0?(e=o+e,t=0):(e=ol.toString()+e,t=1)}return 1===t?parseInt(i.substring(0,o))-1+"."+e:i.substring(0,o+1)+e}}catch(i){return(("string"==typeof e?parseFloat(e):e)-t).toString()}})(this.value,e);this.value=t.toString()}else{const e=this.min>0?this.min:this.max<0?this.max:this.min?0:0-this.step;this.value=e.toString()}this.control&&(void 0!==this.min||void 0!==this.max?this.control.value=cl(this.value,this.locale,this.withFormatting,this.min,this.max,this.maximumInputPrecision):this.control.value=this.value),this.handleTextInput()}hasSeparatorWithoutDecimals(){return new RegExp("[.]$")}handleTextInput(){this.control&&"-"!==this.control.value&&"-0"!==this.control.value&&(this.isUserInput=!0,this.withFormatting&&!new el(this.locale).hasSeparator(this.control.value)?l.DOM.queueUpdate(()=>{const e=dl(this.control.value,this.locale,this.maximumInputPrecision);this.value=rl(e,this.options),this.control&&(this.control.value=rl(sl(e,this.locale),this.options)),this.$emit("input")}):this.withFormatting||this.hasSeparatorWithoutDecimals().test(this.control.value)||l.DOM.queueUpdate(()=>{var e;this.control&&(this.control.value=this.control.value.replace(/[^0-9\-+e.]/g,"")),this.value=(null===(e=this.control)||void 0===e?void 0:e.value)||"",this.$emit("input")}))}valueChanged(e,t){if(null==t&&this.control)this.control.value="";else if(null!=t&&t!==e){if(!this.isUserInput)return this.value=cl(this.value,this.locale,!1,this.min,this.max,this.maximumInputPrecision),void l.DOM.queueUpdate(()=>{this.control&&(this.control.value=this.withFormatting&&this.value?al(this.value,this.locale,this.options):this.value)});const e=t;l.DOM.queueUpdate(()=>{this.control&&(""!==this.control.value&&""!==this.value?(this.control.value=sl(String(e),this.locale),this.value=this.withFormatting?dl(this.control.value,this.locale,this.maximumInputPrecision):this.control.value):this.control.value=e)})}}handleBlur(){if(!this.control)return;this.isUserInput=!1;const e=cl(this.control.value,this.locale,this.withFormatting,this.min,this.max,this.maximumInputPrecision);e&&/^-?\d*\.?\d+$/.test(e)&&(this.value=this.withFormatting?rl(e,this.options):e),this.control.value=this.withFormatting&&this.value?al(this.value,this.locale,this.options):e,this.$emit("input")}}(0,C.Cg)([l.attr],hl.prototype,"autocomplete",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],hl.prototype,"hideStep",void 0),(0,C.Cg)([l.attr],hl.prototype,"value",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],hl.prototype,"withFormatting",void 0),(0,C.Cg)([l.attr],hl.prototype,"locale",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],hl.prototype,"autoStepPrecision",void 0),(0,C.Cg)([l.attr],hl.prototype,"maximumInputPrecision",void 0);const pl={delegatesFocus:!0,mode:"open"},ml={stepDownGlyph:'\n <svg class="step-down-glyph" viewBox="0 0 24 24" width="1rem" height="1rem" xmlns="http://www.w3.org/2000/svg">\n <path d="M6.1018 8C5.02785 8 4.45387 9.2649 5.16108 10.0731L10.6829 16.3838C11.3801 17.1806 12.6197 17.1806 13.3169 16.3838L18.8388 10.0731C19.5459 9.2649 18.972 8 17.898 8H6.1018Z"/>\n </svg>\n ',stepUpGlyph:'\n <svg class="step-up-glyph" viewBox="0 0 24 24" width="1rem" height="1rem" xmlns="http://www.w3.org/2000/svg">\n <path d="M6.1018 16.9814C5.02785 16.9814 4.45387 15.7165 5.16108 14.9083L10.6829 8.59762C11.3801 7.80079 12.6197 7.80079 13.3169 8.59762L18.8388 14.9083C19.5459 15.7165 18.972 16.9814 17.898 16.9814H6.1018Z"/>\n </svg>\n '},gl=hl.compose(Object.assign({baseName:"number-field",template:il,styles:tl,shadowOptions:pl},ml)),vl=(e,t)=>l.css`
3136
3136
  :host {
3137
3137
  display: block;
3138
3138
  }
@@ -3163,19 +3163,19 @@
3163
3163
  <slot></slot>
3164
3164
  </div>
3165
3165
  </template>
3166
- `;class bl extends s.ListboxOption{connectedCallback(){super.connectedCallback(),this.disabled=!0}}(0,C.Cg)([(0,l.attr)({attribute:"label"})],bl.prototype,"groupLabel",void 0);const yl=bl.compose({baseName:"optgroup",template:fl,styles:gl});var wl=i(92277);var Cl=i(72154),xl=i.n(Cl),$l=i(57565),Sl=i.n($l),El=i(13160),kl=i(24669),Ol=i(5709),Tl=i(45230);const Il={windowEvents:["online","offline","pageshow"],documentEvents:["visibilitychange"],genesisConnectEvents:["stream","commit"],ignoredGenesisResources:[],startDelay:5e3,checkInterval:1e4,checkTimeout:3e3,resourceChecks:e=>(0,C.sH)(void 0,void 0,void 0,function*(){const t=(0,ii.tn)(),i=yield t.getMoreColumns(e),o=Date.now(),n=i;return{isConnected:i.MESSAGE_TYPE===Zt.Go.MORE_COLUMNS_ACK,lastUpdated:o,lastMessage:n}}),resourceDataLogon:({message:e,functions:t})=>{const{onMessage:i,onError:o}=t;(0,Tl.Ol)().sendForStream(e,i,o)}},Dl=s.DI.createInterface(e=>e.instance(Il)),Rl="system-health-changed";var Al;const Nl=(0,Ke.createLogger)("network-monitor",{level:Ke.LogLevel.Info}),Ll=Date.now(),Fl=(null===(Al=window.navigator)||void 0===Al?void 0:Al.userAgent)?xl().parse(window.navigator.userAgent):void 0,Ml=(e,t={depthLimit:10,edgesLimit:10})=>e instanceof Event?`'${e.type}' Event`:"string"==typeof e?e:Sl()(e,void 0,2,t);class _l{constructor(){this.unsubscribableObservers=[],this.runAllChecks=(e,t)=>(0,C.sH)(this,void 0,void 0,function*(){if(!this.isReady||this.isRunningChecks&&!t)return;Nl.info("Run health checks, triggered by",Ml(e),"| Active resources",this.resources.size),this.isRunningChecks=!0,this.synchroniseCheckInterval();let i=this.getFormattedTimestamp(this.getNowTimestamp());const o=yield this.isOnlineCheck();o?Nl.debug(`Network connected at ${i}`):Nl.warn(`Network disconnected at ${i}`);const n=this.normaliseSerializedSocketStatus(this.socketStatus.serialize(),o),a=this.preFlightSocketChecks(n);if(a||Nl.debug("Socket pre-flight checks failed"),!o||!a){Nl.debug("Aborting remaining health checks");const e=[...this.resources].reduce((e,[t,i])=>{const n=e[i.resourceName];return n?(n.sourceRef=[...n.sourceRef,i.message.SOURCE_REF],e):Object.assign(Object.assign({},e),{[i.resourceName]:this.normaliseResourceHealth({name:i.resourceName,sourceRef:[i.message.SOURCE_REF],isConnected:i.isConnected,lastUpdated:i.lastUpdated},o)})},{});return this.reportSystemHealth({isAuthenticated:this.user.isAuthenticated,isOnline:o,resources:e,resourcesAllConnected:!1,socket:n}),void(this.isRunningChecks=!1)}let s=!0;const r=[];this.resources.forEach((e,t)=>{const{resourceName:o,message:n,functions:a}=e,{resourceChecks:l=this.config.resourceChecks,resourceDataLogon:d=this.config.resourceDataLogon}=a,{SOURCE_REF:c}=n;let u,h,p,m,v,g=!1;r.push((()=>(0,C.sH)(this,void 0,void 0,function*(){var n,a,r;try{Nl.debug(`Running health check against ${o}`);const e=yield Promise.race([l(c,t),(a=this.config.checkTimeout,r=()=>({isConnected:!1,lastUpdated:this.getNowTimestamp(),timeout:!0}),new Promise(e=>{setTimeout(()=>{e(r())},a)}))]);g=e.isConnected,u=e.lastUpdated,h=e.lastMessage,m=e.timeout}catch(e){g=!1,u=this.getNowTimestamp(),p=e,h=null!==(n=null==e?void 0:e.receivedMessage)&&void 0!==n?n:e}return v=(null==h?void 0:h.MESSAGE_TYPE)===Zt.Go.MSG_NACK||(0,Zt.z2)(h,El.v.NOT_FOUND),i=this.getFormattedTimestamp(null!=u?u:this.getNowTimestamp()),g?Nl.debug(`${o} is healthy at ${i}`):Nl.warn(`${o} is not healthy at ${i}`),h&&Nl.debug(`${o} messaged at ${i}`,Ml(h)),p&&Nl.error(`${o} errored at ${i}`,Ml(p)),m&&Nl.warn(`${o} timed out at ${i}`),v&&(Nl.error(`${o} issue, re-attempting data logon at ${i}`),d(e)),s&&(s=g),{name:o,sourceRef:[c],isConnected:g,lastUpdated:u,lastError:p}}))())});const l=(yield Promise.allSettled(r)).reduce((e,t)=>{if("fulfilled"===t.status){const i=e[t.value.name];return i?(i.sourceRef=[...i.sourceRef,...t.value.sourceRef],e):Object.assign(Object.assign({},e),{[t.value.name]:this.normaliseResourceHealth(t.value)})}return Nl.warn("Unexpected promise rejection occurred. Please check any custom resourceChecks return MonitoredResourceChecksResult."),e},{});Nl.debug("Health checks complete"),this.reportSystemHealth({isAuthenticated:this.user.isAuthenticated,isOnline:o,resources:l,resourcesAllConnected:s,socket:n}),this.isRunningChecks=!1}),void 0!==this.config.logLevel&&(Nl.level=this.config.logLevel)}create(){this.resources?Nl.warn("NetworkMonitor already created. If this is intentional, please call NetworkMonitor.destroy first."):(this.addListeners(),this.resources=new Map,setTimeout(()=>{this.isReady=!0,this.synchroniseCheckInterval(),this.runAllChecks("NetworkMonitor.create()")},this.config.startDelay))}destroy(){this.removeListeners(),clearInterval(this.internalId),this.resources.clear(),this.resources=void 0,this.status=void 0,this.isReady=void 0}isOnlineCheck(){return Promise.resolve(navigator.onLine)}addResource(e,t){this.resources||this.create(),this.resources.set(e,t)}removeResource(e){this.resources.delete(e)}addListeners(){var e,t;null===(e=this.config.windowEvents)||void 0===e||e.forEach(e=>window.addEventListener(e,this.runAllChecks)),null===(t=this.config.documentEvents)||void 0===t||t.forEach(e=>document.addEventListener(e,this.runAllChecks)),this.config.genesisConnectEvents.includes("stream")&&this.unsubscribableObservers.push(this.connectEvents.addStreamListener(({detail:e})=>{const{functions:t,message:i,resourceName:o,stream:n}=e;this.config.ignoredGenesisResources.includes(o)||this.addResource(n,{functions:t,message:i,resourceName:o})},({detail:e})=>{const{resourceName:t,stream:i}=e;this.config.ignoredGenesisResources.includes(t)||this.removeResource(i)},({detail:e})=>{var t;const{resourceName:i,stream:o,error:n}=e,a=null!==(t=n.receivedMessage)&&void 0!==t?t:n;let s="";(0,Zt.z2)(a,El.v.NOT_FOUND)?s="Please check the resource is running.":(0,Zt.z2)(a,El.v.FORBIDDEN)&&(s="You are not authorised to access this resource, removing it from monitoring.",this.removeResource(o)),Nl.error(`${i} errored at ${this.getFormattedTimestamp(this.getNowTimestamp())}.`,s,n)})),this.config.genesisConnectEvents.includes("commit")&&this.unsubscribableObservers.push(this.connectEvents.addCommitListener(e=>{this.config.ignoredGenesisResources.includes(e.detail.eventName)||this.runAllChecks(e)})),this.unsubscribableObservers.push(this.connectEvents.addMetadataListener(({detail:e})=>{const{resourceName:t,error:i}=e;i&&Nl.error(`${t} had an unrecoverable error at ${this.getFormattedTimestamp(this.getNowTimestamp())}.`,"Please check the resource is running.",i)}))}removeListeners(){var e,t;null===(e=this.config.windowEvents)||void 0===e||e.forEach(e=>window.removeEventListener(e,this.runAllChecks)),null===(t=this.config.documentEvents)||void 0===t||t.forEach(e=>document.removeEventListener(e,this.runAllChecks)),this.unsubscribableObservers.forEach(e=>e()),this.unsubscribableObservers.length=0}reportSystemHealth(e){var t;const i=null!==(t=this.config.eventEmitter)&&void 0!==t?t:document;this.status=this.normaliseEventDetail(e);(this.status.isHealthy?Nl.debug:Nl.warn)("Emitting 'system-health-changed' event",Ml(this.status)),null==i||i.dispatchEvent(new CustomEvent(Rl,{detail:this.status,bubbles:i!==document,composed:!0})),this.status.socket.reconnectionLimitReached&&(Nl.debug("Network monitoring no longer required. Please check your network and reload your application."),this.destroy())}reportStabilityToGenesis(e){return(0,C.sH)(this,void 0,void 0,function*(){return Nl.debug("User requested report stability to Genesis."),Nl.info("Please attach this data to your Genesis Support request: \n",JSON.stringify(e,null,2)),!0})}normaliseResourceHealth(e,t=!0){var i;const o=!!t&&e.isConnected,n=null!==(i=e.lastUpdated)&&void 0!==i?i:this.getNowTimestamp();return Object.assign(Object.assign({},e),{isConnected:o,lastUpdated:n})}normaliseSerializedSocketStatus(e,t=!0){const i=!!t&&e.isConnected,o=!i;return Object.assign(Object.assign({},e),{isConnected:i,isDisconnected:o})}normaliseEventDetail(e){var t,i,o,n;const a=!!((null===(t=e.socket)||void 0===t?void 0:t.isConfigured)?e.isOnline&&(null===(i=e.socket)||void 0===i?void 0:i.isConnected)&&e.resourcesAllConnected:e.isOnline),s=null!==(o=e.lastUpdated)&&void 0!==o?o:this.getNowTimestamp(),r=null!==(n=e.nextUpdate)&&void 0!==n?n:this.getNextTimestamp(),l=e.isAuthenticated&&this.user?this.user.username:void 0,d=Object.assign(Object.assign({},e),{browserInformation:Fl,username:l,isHealthy:a,lastUpdated:s,nextUpdate:r,firstUpdated:Ll,runAllChecks:()=>{Nl.debug("User activated run checks command starting."),this.runAllChecks("user requested")},reportStabilityToGenesis:()=>this.reportStabilityToGenesis(d)});return d}preFlightSocketChecks(e){if(!e.isConfigured)return Nl.debug("Socket not configured"),!1;if(e.isReconnecting)return Nl.debug("Socket reconnecting"),!1;if(e.isConnecting)return Nl.debug("Socket connecting"),!1;if(e.isDisconnected){const t=e.isDisconnectedByServer?`by the server, code: ${e.closedCode}, reason: ${e.closedReason}`:"";return Nl.debug(`Socket disconnected ${t}`),e.reconnectionLimitReached&&Nl.debug("Socket reconnection limit reached"),!1}const t=this.user.isAuthenticated?"with":"without";return Nl.debug(`Socket connected ${t} valid session`),!0}getFormattedTimestamp(e){return(0,ni.zT)(e)}getNowTimestamp(){return Date.now()}getNextTimestamp(){return new Date(Date.now()+this.config.checkInterval).getTime()}synchroniseCheckInterval(){clearInterval(this.internalId),this.internalId=setInterval(()=>this.runAllChecks("check interval"),this.config.checkInterval)}}(0,C.Cg)([Dl],_l.prototype,"config",void 0),(0,C.Cg)([Ol.S5],_l.prototype,"socketStatus",void 0),(0,C.Cg)([kl.a4],_l.prototype,"connectEvents",void 0),(0,C.Cg)([wl.KJ],_l.prototype,"user",void 0),(0,C.Cg)([l.observable],_l.prototype,"status",void 0);const Hl=s.DI.createInterface(e=>e.singleton(_l));var Pl=i(6526);const zl=(e,t)=>l.css`
3166
+ `;class bl extends a.ListboxOption{connectedCallback(){super.connectedCallback(),this.disabled=!0}}(0,C.Cg)([(0,l.attr)({attribute:"label"})],bl.prototype,"groupLabel",void 0);const yl=bl.compose({baseName:"optgroup",template:fl,styles:vl});var wl=i(92277);var Cl=i(72154),xl=i.n(Cl),$l=i(57565),Sl=i.n($l),El=i(13160),kl=i(24669),Ol=i(5709),Tl=i(45230);const Il={windowEvents:["online","offline","pageshow"],documentEvents:["visibilitychange"],genesisConnectEvents:["stream","commit"],ignoredGenesisResources:[],startDelay:5e3,checkInterval:1e4,checkTimeout:3e3,resourceChecks:e=>(0,C.sH)(void 0,void 0,void 0,function*(){const t=(0,ii.tn)(),i=yield t.getMoreColumns(e),o=Date.now(),n=i;return{isConnected:i.MESSAGE_TYPE===Zt.Go.MORE_COLUMNS_ACK,lastUpdated:o,lastMessage:n}}),resourceDataLogon:({message:e,functions:t})=>{const{onMessage:i,onError:o}=t;(0,Tl.Ol)().sendForStream(e,i,o)}},Rl=a.DI.createInterface(e=>e.instance(Il)),Al="system-health-changed";var Dl;const Nl=(0,Ke.createLogger)("network-monitor",{level:Ke.LogLevel.Info}),Ll=Date.now(),Fl=(null===(Dl=window.navigator)||void 0===Dl?void 0:Dl.userAgent)?xl().parse(window.navigator.userAgent):void 0,Ml=(e,t={depthLimit:10,edgesLimit:10})=>e instanceof Event?`'${e.type}' Event`:"string"==typeof e?e:Sl()(e,void 0,2,t);class _l{constructor(){this.unsubscribableObservers=[],this.runAllChecks=(e,t)=>(0,C.sH)(this,void 0,void 0,function*(){if(!this.isReady||this.isRunningChecks&&!t)return;Nl.info("Run health checks, triggered by",Ml(e),"| Active resources",this.resources.size),this.isRunningChecks=!0,this.synchroniseCheckInterval();let i=this.getFormattedTimestamp(this.getNowTimestamp());const o=yield this.isOnlineCheck();o?Nl.debug(`Network connected at ${i}`):Nl.warn(`Network disconnected at ${i}`);const n=this.normaliseSerializedSocketStatus(this.socketStatus.serialize(),o),s=this.preFlightSocketChecks(n);if(s||Nl.debug("Socket pre-flight checks failed"),!o||!s){Nl.debug("Aborting remaining health checks");const e=[...this.resources].reduce((e,[t,i])=>{const n=e[i.resourceName];return n?(n.sourceRef=[...n.sourceRef,i.message.SOURCE_REF],e):Object.assign(Object.assign({},e),{[i.resourceName]:this.normaliseResourceHealth({name:i.resourceName,sourceRef:[i.message.SOURCE_REF],isConnected:i.isConnected,lastUpdated:i.lastUpdated},o)})},{});return this.reportSystemHealth({isAuthenticated:this.user.isAuthenticated,isOnline:o,resources:e,resourcesAllConnected:!1,socket:n}),void(this.isRunningChecks=!1)}let a=!0;const r=[];this.resources.forEach((e,t)=>{const{resourceName:o,message:n,functions:s}=e,{resourceChecks:l=this.config.resourceChecks,resourceDataLogon:d=this.config.resourceDataLogon}=s,{SOURCE_REF:c}=n;let u,h,p,m,g,v=!1;r.push((()=>(0,C.sH)(this,void 0,void 0,function*(){var n,s,r;try{Nl.debug(`Running health check against ${o}`);const e=yield Promise.race([l(c,t),(s=this.config.checkTimeout,r=()=>({isConnected:!1,lastUpdated:this.getNowTimestamp(),timeout:!0}),new Promise(e=>{setTimeout(()=>{e(r())},s)}))]);v=e.isConnected,u=e.lastUpdated,h=e.lastMessage,m=e.timeout}catch(e){v=!1,u=this.getNowTimestamp(),p=e,h=null!==(n=null==e?void 0:e.receivedMessage)&&void 0!==n?n:e}return g=(null==h?void 0:h.MESSAGE_TYPE)===Zt.Go.MSG_NACK||(0,Zt.z2)(h,El.v.NOT_FOUND),i=this.getFormattedTimestamp(null!=u?u:this.getNowTimestamp()),v?Nl.debug(`${o} is healthy at ${i}`):Nl.warn(`${o} is not healthy at ${i}`),h&&Nl.debug(`${o} messaged at ${i}`,Ml(h)),p&&Nl.error(`${o} errored at ${i}`,Ml(p)),m&&Nl.warn(`${o} timed out at ${i}`),g&&(Nl.error(`${o} issue, re-attempting data logon at ${i}`),d(e)),a&&(a=v),{name:o,sourceRef:[c],isConnected:v,lastUpdated:u,lastError:p}}))())});const l=(yield Promise.allSettled(r)).reduce((e,t)=>{if("fulfilled"===t.status){const i=e[t.value.name];return i?(i.sourceRef=[...i.sourceRef,...t.value.sourceRef],e):Object.assign(Object.assign({},e),{[t.value.name]:this.normaliseResourceHealth(t.value)})}return Nl.warn("Unexpected promise rejection occurred. Please check any custom resourceChecks return MonitoredResourceChecksResult."),e},{});Nl.debug("Health checks complete"),this.reportSystemHealth({isAuthenticated:this.user.isAuthenticated,isOnline:o,resources:l,resourcesAllConnected:a,socket:n}),this.isRunningChecks=!1}),void 0!==this.config.logLevel&&(Nl.level=this.config.logLevel)}create(){this.resources?Nl.warn("NetworkMonitor already created. If this is intentional, please call NetworkMonitor.destroy first."):(this.addListeners(),this.resources=new Map,setTimeout(()=>{this.isReady=!0,this.synchroniseCheckInterval(),this.runAllChecks("NetworkMonitor.create()")},this.config.startDelay))}destroy(){this.removeListeners(),clearInterval(this.internalId),this.resources.clear(),this.resources=void 0,this.status=void 0,this.isReady=void 0}isOnlineCheck(){return Promise.resolve(navigator.onLine)}addResource(e,t){this.resources||this.create(),this.resources.set(e,t)}removeResource(e){this.resources.delete(e)}addListeners(){var e,t;null===(e=this.config.windowEvents)||void 0===e||e.forEach(e=>window.addEventListener(e,this.runAllChecks)),null===(t=this.config.documentEvents)||void 0===t||t.forEach(e=>document.addEventListener(e,this.runAllChecks)),this.config.genesisConnectEvents.includes("stream")&&this.unsubscribableObservers.push(this.connectEvents.addStreamListener(({detail:e})=>{const{functions:t,message:i,resourceName:o,stream:n}=e;this.config.ignoredGenesisResources.includes(o)||this.addResource(n,{functions:t,message:i,resourceName:o})},({detail:e})=>{const{resourceName:t,stream:i}=e;this.config.ignoredGenesisResources.includes(t)||this.removeResource(i)},({detail:e})=>{var t;const{resourceName:i,stream:o,error:n}=e,s=null!==(t=n.receivedMessage)&&void 0!==t?t:n;let a="";(0,Zt.z2)(s,El.v.NOT_FOUND)?a="Please check the resource is running.":(0,Zt.z2)(s,El.v.FORBIDDEN)&&(a="You are not authorised to access this resource, removing it from monitoring.",this.removeResource(o)),Nl.error(`${i} errored at ${this.getFormattedTimestamp(this.getNowTimestamp())}.`,a,n)})),this.config.genesisConnectEvents.includes("commit")&&this.unsubscribableObservers.push(this.connectEvents.addCommitListener(e=>{this.config.ignoredGenesisResources.includes(e.detail.eventName)||this.runAllChecks(e)})),this.unsubscribableObservers.push(this.connectEvents.addMetadataListener(({detail:e})=>{const{resourceName:t,error:i}=e;i&&Nl.error(`${t} had an unrecoverable error at ${this.getFormattedTimestamp(this.getNowTimestamp())}.`,"Please check the resource is running.",i)}))}removeListeners(){var e,t;null===(e=this.config.windowEvents)||void 0===e||e.forEach(e=>window.removeEventListener(e,this.runAllChecks)),null===(t=this.config.documentEvents)||void 0===t||t.forEach(e=>document.removeEventListener(e,this.runAllChecks)),this.unsubscribableObservers.forEach(e=>e()),this.unsubscribableObservers.length=0}reportSystemHealth(e){var t;const i=null!==(t=this.config.eventEmitter)&&void 0!==t?t:document;this.status=this.normaliseEventDetail(e);(this.status.isHealthy?Nl.debug:Nl.warn)("Emitting 'system-health-changed' event",Ml(this.status)),null==i||i.dispatchEvent(new CustomEvent(Al,{detail:this.status,bubbles:i!==document,composed:!0})),this.status.socket.reconnectionLimitReached&&(Nl.debug("Network monitoring no longer required. Please check your network and reload your application."),this.destroy())}reportStabilityToGenesis(e){return(0,C.sH)(this,void 0,void 0,function*(){return Nl.debug("User requested report stability to Genesis."),Nl.info("Please attach this data to your Genesis Support request: \n",JSON.stringify(e,null,2)),!0})}normaliseResourceHealth(e,t=!0){var i;const o=!!t&&e.isConnected,n=null!==(i=e.lastUpdated)&&void 0!==i?i:this.getNowTimestamp();return Object.assign(Object.assign({},e),{isConnected:o,lastUpdated:n})}normaliseSerializedSocketStatus(e,t=!0){const i=!!t&&e.isConnected,o=!i;return Object.assign(Object.assign({},e),{isConnected:i,isDisconnected:o})}normaliseEventDetail(e){var t,i,o,n;const s=!!((null===(t=e.socket)||void 0===t?void 0:t.isConfigured)?e.isOnline&&(null===(i=e.socket)||void 0===i?void 0:i.isConnected)&&e.resourcesAllConnected:e.isOnline),a=null!==(o=e.lastUpdated)&&void 0!==o?o:this.getNowTimestamp(),r=null!==(n=e.nextUpdate)&&void 0!==n?n:this.getNextTimestamp(),l=e.isAuthenticated&&this.user?this.user.username:void 0,d=Object.assign(Object.assign({},e),{browserInformation:Fl,username:l,isHealthy:s,lastUpdated:a,nextUpdate:r,firstUpdated:Ll,runAllChecks:()=>{Nl.debug("User activated run checks command starting."),this.runAllChecks("user requested")},reportStabilityToGenesis:()=>this.reportStabilityToGenesis(d)});return d}preFlightSocketChecks(e){if(!e.isConfigured)return Nl.debug("Socket not configured"),!1;if(e.isReconnecting)return Nl.debug("Socket reconnecting"),!1;if(e.isConnecting)return Nl.debug("Socket connecting"),!1;if(e.isDisconnected){const t=e.isDisconnectedByServer?`by the server, code: ${e.closedCode}, reason: ${e.closedReason}`:"";return Nl.debug(`Socket disconnected ${t}`),e.reconnectionLimitReached&&Nl.debug("Socket reconnection limit reached"),!1}const t=this.user.isAuthenticated?"with":"without";return Nl.debug(`Socket connected ${t} valid session`),!0}getFormattedTimestamp(e){return(0,ni.zT)(e)}getNowTimestamp(){return Date.now()}getNextTimestamp(){return new Date(Date.now()+this.config.checkInterval).getTime()}synchroniseCheckInterval(){clearInterval(this.internalId),this.internalId=setInterval(()=>this.runAllChecks("check interval"),this.config.checkInterval)}}(0,C.Cg)([Rl],_l.prototype,"config",void 0),(0,C.Cg)([Ol.S5],_l.prototype,"socketStatus",void 0),(0,C.Cg)([kl.a4],_l.prototype,"connectEvents",void 0),(0,C.Cg)([wl.KJ],_l.prototype,"user",void 0),(0,C.Cg)([l.observable],_l.prototype,"status",void 0);const Hl=a.DI.createInterface(e=>e.singleton(_l));var Pl=i(6526);const zl=(e,t)=>l.css`
3167
3167
  ${(0,r.progressStyles)(e,t)}
3168
3168
  :host {
3169
3169
  height: calc(var(--design-unit) * 2px);
3170
3170
  }
3171
- `,Ul=(e,t)=>(0,s.progressTemplate)(e,t);class Bl extends r.Progress{}const Wl=void 0,Gl={indeterminateIndicator1:'<span class="indeterminate-indicator-1" part="indeterminate-indicator-1"></span>',indeterminateIndicator2:'<span class="indeterminate-indicator-1" part="indeterminate-indicator-1"></span>'},jl=Bl.compose(Object.assign({baseName:"progress",template:Ul,styles:zl,shadowOptions:Wl},Gl));function Vl(e){return new Proxy(e,{get:(e,t,...i)=>{if(["withPrefix","withShadowRootMode","withElementDisambiguation"].includes(t))throw new Error("Modification of the Design System is not allowed.");return Reflect.get(e,t,...i)}})}const Yl=(e,t="foundation",i,a)=>{e&&Fo(null!=i?i:o,null!=a?a:n,e);return Vl(s.DesignSystem.getOrCreate(e).withPrefix(t))},ql="app",Kl="component";Yl().register(jl({prefix:"next-update"}));class Xl extends s.FoundationElement{constructor(){super(...arguments),this.timeTillNextUpdate={totalMs:1e4,remainMs:1e4,remainPercent:100},this.mode=ql,this.status={isOnline:!0,isHealthy:!0,browserInformation:{},socket:{},resources:{}},this.onSystemHealthChanged=e=>{this.status=e.detail,this.resourceList=Object.values(this.status.resources).sort((e,t)=>Number(t.isConnected)-Number(e.isConnected))},this.onOpen=(e=!1)=>{this.isOpen=!0,this.wasOpenedByUser=e,this.isDismissed=!1},this.onClose=()=>{this.isOpen=!1,this.wasOpenedByUser=!1,this.isDismissed=!1},this.onDismiss=()=>{this.isDismissed||this.status.isHealthy?this.onClose():this.isDismissed=!0},this.onUpdateStatus=()=>{this.status.runAllChecks()},this.onReportStatus=()=>{this.status.reportStabilityToGenesis()},this.onReloadWindow=()=>{location.reload()},this.onDocumentKeydown=e=>{if(!e.defaultPrevented)switch(e.key){case Pl.Is.ArrowUp:e.ctrlKey&&e.altKey&&!this.isOpen&&(this.onOpen(!0),e.preventDefault());break;case Pl.Is.ArrowDown:e.ctrlKey&&e.altKey&&this.isOpen&&(this.onClose(),e.preventDefault());break;case Pl.F9:this.isOpen&&(this.onDismiss(),e.preventDefault())}}}isOpenChanged(){this.updateTemplateClassNames()}isDismissedChanged(){this.updateTemplateClassNames()}modeChanged(){this.$fastController.isConnected&&this.mode===Kl&&Xe.warn("SystemHealthOverlay has support for app overlays only right now.")}logLevelChanged(){Nl.level=this.logLevel}statusChanged(e,t){this.updateClassNames(),this.$fastController.isConnected&&(!1!==(null==t?void 0:t.isHealthy)||this.isOpen||this.onOpen(),!0===(null==t?void 0:t.isHealthy)&&this.isOpen&&!this.wasOpenedByUser&&this.onClose(),this.startTimeTillNextUpdateCountdown())}updateClassNames(){this.isOnlineClassNames=(0,x.x)(["healthy",this.status.isOnline],["unhealthy",!this.status.isOnline]),this.isHealthyClassNames=(0,x.x)(["healthy",this.status.isHealthy],["unhealthy",!this.status.isHealthy]),this.isSocketHealthyClassNames=(0,x.x)(["healthy",this.isSocketHealthy],["unhealthy",!this.isSocketHealthy]),this.resourcesAllConnectedClassNames=(0,x.x)(["healthy",this.status.resourcesAllConnected],["unhealthy",!this.status.resourcesAllConnected],["hidden",!this.validResourceList]),this.updateTemplateClassNames()}updateTemplateClassNames(){this.templateClassNames=(0,x.x)(["open",this.isOpen],["dismissed",this.isDismissed]),this.containerClassNames=(0,x.x)(this.isHealthyClassNames,["open",this.isOpen],["dismissed",this.isDismissed])}startTimeTillNextUpdateCountdown(){const e=this.status.nextUpdate-Date.now();let t=e,i=100;clearInterval(this.timeTillNextUpdateInterval),this.timeTillNextUpdate={totalMs:e,remainMs:t,remainPercent:i},this.timeTillNextUpdateInterval=setInterval(()=>{t-=1e3,i=Math.floor(t/e*100),this.timeTillNextUpdate={totalMs:e,remainMs:t,remainPercent:i},t<0&&clearInterval(this.timeTillNextUpdateInterval)},1e3)}connectedCallback(){super.connectedCallback(),this.networkMonitor.create(),this.addEventListeners()}disconnectedCallback(){super.disconnectedCallback(),this.networkMonitor.destroy(),this.removeEventListeners()}get isSocketHealthy(){return this.status.isOnline&&(!this.status.socket.isConfigured||this.status.socket.isConfigured&&this.status.socket.isConnected)}get validResourceList(){var e;return(null===(e=this.resourceList)||void 0===e?void 0:e.length)>0}eventBridge(){var e;return null!==(e=this.config.eventEmitter)&&void 0!==e?e:document}addEventListeners(){this.eventBridge().addEventListener(Rl,this.onSystemHealthChanged,!0),document.addEventListener("keydown",this.onDocumentKeydown)}removeEventListeners(){this.eventBridge().removeEventListener(Rl,this.onSystemHealthChanged,!0),document.removeEventListener("keydown",this.onDocumentKeydown)}static getCheckmarkTemplate(e){return e?l.html`
3171
+ `,Ul=(e,t)=>(0,a.progressTemplate)(e,t);class Wl extends r.Progress{}const Gl=void 0,Bl={indeterminateIndicator1:'<span class="indeterminate-indicator-1" part="indeterminate-indicator-1"></span>',indeterminateIndicator2:'<span class="indeterminate-indicator-1" part="indeterminate-indicator-1"></span>'},Vl=Wl.compose(Object.assign({baseName:"progress",template:Ul,styles:zl,shadowOptions:Gl},Bl));function jl(e){return new Proxy(e,{get:(e,t,...i)=>{if(["withPrefix","withShadowRootMode","withElementDisambiguation"].includes(t))throw new Error("Modification of the Design System is not allowed.");return Reflect.get(e,t,...i)}})}const Yl=(e,t="foundation",i,s)=>{e&&Fo(null!=i?i:o,null!=s?s:n,e);return jl(a.DesignSystem.getOrCreate(e).withPrefix(t))},ql="app",Kl="component";Yl().register(Vl({prefix:"next-update"}));class Xl extends a.FoundationElement{constructor(){super(...arguments),this.timeTillNextUpdate={totalMs:1e4,remainMs:1e4,remainPercent:100},this.mode=ql,this.status={isOnline:!0,isHealthy:!0,browserInformation:{},socket:{},resources:{}},this.onSystemHealthChanged=e=>{this.status=e.detail,this.resourceList=Object.values(this.status.resources).sort((e,t)=>Number(t.isConnected)-Number(e.isConnected))},this.onOpen=(e=!1)=>{this.isOpen=!0,this.wasOpenedByUser=e,this.isDismissed=!1},this.onClose=()=>{this.isOpen=!1,this.wasOpenedByUser=!1,this.isDismissed=!1},this.onDismiss=()=>{this.isDismissed||this.status.isHealthy?this.onClose():this.isDismissed=!0},this.onUpdateStatus=()=>{this.status.runAllChecks()},this.onReportStatus=()=>{this.status.reportStabilityToGenesis()},this.onReloadWindow=()=>{location.reload()},this.onDocumentKeydown=e=>{if(!e.defaultPrevented)switch(e.key){case Pl.Is.ArrowUp:e.ctrlKey&&e.altKey&&!this.isOpen&&(this.onOpen(!0),e.preventDefault());break;case Pl.Is.ArrowDown:e.ctrlKey&&e.altKey&&this.isOpen&&(this.onClose(),e.preventDefault());break;case Pl.F9:this.isOpen&&(this.onDismiss(),e.preventDefault())}}}isOpenChanged(){this.updateTemplateClassNames()}isDismissedChanged(){this.updateTemplateClassNames()}modeChanged(){this.$fastController.isConnected&&this.mode===Kl&&Xe.warn("SystemHealthOverlay has support for app overlays only right now.")}logLevelChanged(){Nl.level=this.logLevel}statusChanged(e,t){this.updateClassNames(),this.$fastController.isConnected&&(!1!==(null==t?void 0:t.isHealthy)||this.isOpen||this.onOpen(),!0===(null==t?void 0:t.isHealthy)&&this.isOpen&&!this.wasOpenedByUser&&this.onClose(),this.startTimeTillNextUpdateCountdown())}updateClassNames(){this.isOnlineClassNames=(0,x.x)(["healthy",this.status.isOnline],["unhealthy",!this.status.isOnline]),this.isHealthyClassNames=(0,x.x)(["healthy",this.status.isHealthy],["unhealthy",!this.status.isHealthy]),this.isSocketHealthyClassNames=(0,x.x)(["healthy",this.isSocketHealthy],["unhealthy",!this.isSocketHealthy]),this.resourcesAllConnectedClassNames=(0,x.x)(["healthy",this.status.resourcesAllConnected],["unhealthy",!this.status.resourcesAllConnected],["hidden",!this.validResourceList]),this.updateTemplateClassNames()}updateTemplateClassNames(){this.templateClassNames=(0,x.x)(["open",this.isOpen],["dismissed",this.isDismissed]),this.containerClassNames=(0,x.x)(this.isHealthyClassNames,["open",this.isOpen],["dismissed",this.isDismissed])}startTimeTillNextUpdateCountdown(){const e=this.status.nextUpdate-Date.now();let t=e,i=100;clearInterval(this.timeTillNextUpdateInterval),this.timeTillNextUpdate={totalMs:e,remainMs:t,remainPercent:i},this.timeTillNextUpdateInterval=setInterval(()=>{t-=1e3,i=Math.floor(t/e*100),this.timeTillNextUpdate={totalMs:e,remainMs:t,remainPercent:i},t<0&&clearInterval(this.timeTillNextUpdateInterval)},1e3)}connectedCallback(){super.connectedCallback(),this.networkMonitor.create(),this.addEventListeners()}disconnectedCallback(){super.disconnectedCallback(),this.networkMonitor.destroy(),this.removeEventListeners()}get isSocketHealthy(){return this.status.isOnline&&(!this.status.socket.isConfigured||this.status.socket.isConfigured&&this.status.socket.isConnected)}get validResourceList(){var e;return(null===(e=this.resourceList)||void 0===e?void 0:e.length)>0}eventBridge(){var e;return null!==(e=this.config.eventEmitter)&&void 0!==e?e:document}addEventListeners(){this.eventBridge().addEventListener(Al,this.onSystemHealthChanged,!0),document.addEventListener("keydown",this.onDocumentKeydown)}removeEventListeners(){this.eventBridge().removeEventListener(Al,this.onSystemHealthChanged,!0),document.removeEventListener("keydown",this.onDocumentKeydown)}static getCheckmarkTemplate(e){return e?l.html`
3172
3172
  <span class="checkmark">&#x2714;</span>
3173
3173
  `:l.html`
3174
3174
  <span class="checkmark">&#10008;</span>
3175
- `}}(0,C.Cg)([Dl],Xl.prototype,"config",void 0),(0,C.Cg)([Hl],Xl.prototype,"networkMonitor",void 0),(0,C.Cg)([l.observable],Xl.prototype,"resourceList",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isOpen",void 0),(0,C.Cg)([l.observable],Xl.prototype,"wasOpenedByUser",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isDismissed",void 0),(0,C.Cg)([l.observable],Xl.prototype,"templateClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"containerClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isOnlineClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isHealthyClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isSocketHealthyClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"resourcesAllConnectedClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"timeTillNextUpdate",void 0),(0,C.Cg)([l.observable],Xl.prototype,"saveDataCallback",void 0),(0,C.Cg)([l.attr],Xl.prototype,"mode",void 0),(0,C.Cg)([(0,l.attr)({attribute:"log-level",converter:l.nullableNumberConverter})],Xl.prototype,"logLevel",void 0),(0,C.Cg)([l.observable],Xl.prototype,"status",void 0);const Ql=(e,t)=>l.html`
3175
+ `}}(0,C.Cg)([Rl],Xl.prototype,"config",void 0),(0,C.Cg)([Hl],Xl.prototype,"networkMonitor",void 0),(0,C.Cg)([l.observable],Xl.prototype,"resourceList",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isOpen",void 0),(0,C.Cg)([l.observable],Xl.prototype,"wasOpenedByUser",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isDismissed",void 0),(0,C.Cg)([l.observable],Xl.prototype,"templateClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"containerClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isOnlineClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isHealthyClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"isSocketHealthyClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"resourcesAllConnectedClassNames",void 0),(0,C.Cg)([l.observable],Xl.prototype,"timeTillNextUpdate",void 0),(0,C.Cg)([l.observable],Xl.prototype,"saveDataCallback",void 0),(0,C.Cg)([l.attr],Xl.prototype,"mode",void 0),(0,C.Cg)([(0,l.attr)({attribute:"log-level",converter:l.nullableNumberConverter})],Xl.prototype,"logLevel",void 0),(0,C.Cg)([l.observable],Xl.prototype,"status",void 0);const Ql=(e,t)=>l.html`
3176
3176
  <template class="${e=>e.templateClassNames}">
3177
3177
  <header class="${e=>e.isHealthyClassNames}" part="header">
3178
- <h1>System ${e=>(0,is.fL)(e.isHealthyClassNames)}</h1>
3178
+ <h1>System ${e=>(0,ia.fL)(e.isHealthyClassNames)}</h1>
3179
3179
  ${(0,l.when)(e=>!e.status.isHealthy,l.html`
3180
3180
  <span class="data-warning">Data Validity Unknown</span>
3181
3181
  `)}
@@ -3204,7 +3204,7 @@
3204
3204
  </header>
3205
3205
  <div class="container ${e=>e.containerClassNames}" part="container">
3206
3206
  <section class="network-section ${e=>e.isOnlineClassNames}" part="network-section">
3207
- <h2>Network ${e=>(0,is.fL)(e.status.isOnline?"online":"offline")}</h2>
3207
+ <h2>Network ${e=>(0,ia.fL)(e.status.isOnline?"online":"offline")}</h2>
3208
3208
  <dl class="resource-list">
3209
3209
  <div class="resource ${e=>e.isOnlineClassNames}">
3210
3210
  <div class="attributes">
@@ -3224,11 +3224,11 @@
3224
3224
  `)}
3225
3225
  <div class="platform-type">
3226
3226
  <dt>Platform Type</dt>
3227
- <dd>${e=>{var t;return(0,is.fL)(null===(t=e.status.browserInformation.platform)||void 0===t?void 0:t.type)}}</dd>
3227
+ <dd>${e=>{var t;return(0,ia.fL)(null===(t=e.status.browserInformation.platform)||void 0===t?void 0:t.type)}}</dd>
3228
3228
  </div>
3229
3229
  <div class="os-name">
3230
3230
  <dt>OS Name</dt>
3231
- <dd>${e=>{var t;return(0,is.fL)(null===(t=e.status.browserInformation.os)||void 0===t?void 0:t.name)}}</dd>
3231
+ <dd>${e=>{var t;return(0,ia.fL)(null===(t=e.status.browserInformation.os)||void 0===t?void 0:t.name)}}</dd>
3232
3232
  </div>
3233
3233
  <div class="os-version">
3234
3234
  <dt>OS Version</dt>
@@ -3238,7 +3238,7 @@
3238
3238
  <div class="attributes">
3239
3239
  <div class="browser-name">
3240
3240
  <dt>Browser Name</dt>
3241
- <dd>${e=>{var t;return(0,is.fL)(null===(t=e.status.browserInformation.browser)||void 0===t?void 0:t.name)}}</dd>
3241
+ <dd>${e=>{var t;return(0,ia.fL)(null===(t=e.status.browserInformation.browser)||void 0===t?void 0:t.name)}}</dd>
3242
3242
  </div>
3243
3243
  <div class="browser-version">
3244
3244
  <dt>Browser Version</dt>
@@ -3274,7 +3274,7 @@
3274
3274
  </dl>
3275
3275
  </section>
3276
3276
  <section class="socket-section ${e=>e.isSocketHealthyClassNames}" part="socket-section">
3277
- <h2>WebSocket ${e=>(0,is.fL)(e.isSocketHealthyClassNames)}</h2>
3277
+ <h2>WebSocket ${e=>(0,ia.fL)(e.isSocketHealthyClassNames)}</h2>
3278
3278
  <dl class="resource-list">
3279
3279
  <div class="resource ${e=>e.isSocketHealthyClassNames}">
3280
3280
  <div class="attributes">
@@ -3323,7 +3323,7 @@
3323
3323
  class="resource-section ${e=>e.resourcesAllConnectedClassNames}"
3324
3324
  part="resource-section"
3325
3325
  >
3326
- <h2>Resources ${e=>(0,is.fL)(e.resourcesAllConnectedClassNames)}</h2>
3326
+ <h2>Resources ${e=>(0,ia.fL)(e.resourcesAllConnectedClassNames)}</h2>
3327
3327
  <dl class="resource-list">
3328
3328
  ${(0,l.repeat)(e=>e.resourceList,l.html`
3329
3329
  <div class="resource ${e=>e.isConnected?"healthy":"unhealthy"}">
@@ -3629,7 +3629,7 @@
3629
3629
  padding: 0.2em 0.5em;
3630
3630
  background-color: var(--color-unhealthy-opacity-20);
3631
3631
  }
3632
- `,Zl=void 0,ed={},td=Xl.compose(Object.assign({baseName:"system-health-overlay",template:Ql,styles:Jl,shadowOptions:Zl},ed));var id=i(4934);const od={toView:e=>JSON.stringify(e),fromView:e=>null==e?e:JSON.parse(e)};class nd extends s.FoundationElement{constructor(){super(...arguments),this.show=!1,this.event="click",this.placement="bottom",this.flip=!1}selectorChanged(e,t){t!==e&&(this.popper&&this.popper.destroy(),this.target&&this.target.removeEventListener(this.event,this.toggle.bind(this)),this.target=this.getRootNode().querySelector(this.selector),this.target.addEventListener(this.event,this.toggle.bind(this)),this.popper=(0,id.n4)(this.target,this,this.buildOptions()))}placementChanged(){this.popper&&this.popper.setOptions(this.buildOptions())}offsetChanged(){this.popper&&this.popper.setOptions(this.buildOptions())}flipChanged(){this.popper&&this.popper.setOptions(this.buildOptions())}buildOptions(){return{placement:this.placement,modifiers:[{name:"offset",options:{offset:this.offset||[0,0]}},{name:"flip",enabled:this.flip}]}}toggle(){this.show=!this.show}disconnectedCallback(){super.disconnectedCallback(),this.popper&&(this.popper.destroy(),this.popper=null)}}(0,C.Cg)([l.attr],nd.prototype,"selector",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],nd.prototype,"show",void 0),(0,C.Cg)([l.attr],nd.prototype,"event",void 0),(0,C.Cg)([l.attr],nd.prototype,"placement",void 0),(0,C.Cg)([(0,l.attr)({converter:od})],nd.prototype,"offset",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],nd.prototype,"flip",void 0);const ad=l.css`
3632
+ `,Zl=void 0,ed={},td=Xl.compose(Object.assign({baseName:"system-health-overlay",template:Ql,styles:Jl,shadowOptions:Zl},ed));var id=i(4934);const od={toView:e=>JSON.stringify(e),fromView:e=>null==e?e:JSON.parse(e)};class nd extends a.FoundationElement{constructor(){super(...arguments),this.show=!1,this.event="click",this.placement="bottom",this.flip=!1}selectorChanged(e,t){t!==e&&(this.popper&&this.popper.destroy(),this.target&&this.target.removeEventListener(this.event,this.toggle.bind(this)),this.target=this.getRootNode().querySelector(this.selector),this.target.addEventListener(this.event,this.toggle.bind(this)),this.popper=(0,id.n4)(this.target,this,this.buildOptions()))}placementChanged(){this.popper&&this.popper.setOptions(this.buildOptions())}offsetChanged(){this.popper&&this.popper.setOptions(this.buildOptions())}flipChanged(){this.popper&&this.popper.setOptions(this.buildOptions())}buildOptions(){return{placement:this.placement,modifiers:[{name:"offset",options:{offset:this.offset||[0,0]}},{name:"flip",enabled:this.flip}]}}toggle(){this.show=!this.show}disconnectedCallback(){super.disconnectedCallback(),this.popper&&(this.popper.destroy(),this.popper=null)}}(0,C.Cg)([l.attr],nd.prototype,"selector",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],nd.prototype,"show",void 0),(0,C.Cg)([l.attr],nd.prototype,"event",void 0),(0,C.Cg)([l.attr],nd.prototype,"placement",void 0),(0,C.Cg)([(0,l.attr)({converter:od})],nd.prototype,"offset",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],nd.prototype,"flip",void 0);const sd=l.css`
3633
3633
  :host {
3634
3634
  display: none;
3635
3635
  inset: unset !important;
@@ -3639,17 +3639,17 @@
3639
3639
  :host([show]) {
3640
3640
  display: block;
3641
3641
  }
3642
- `,sd=l.html`
3642
+ `,ad=l.html`
3643
3643
  <template>
3644
3644
  <slot></slot>
3645
3645
  </template>
3646
- `,rd=nd.compose({baseName:"popper",styles:ad,template:sd}),ld=(e,t)=>l.css`
3646
+ `,rd=nd.compose({baseName:"popper",styles:sd,template:ad}),ld=(e,t)=>l.css`
3647
3647
  ${(0,r.progressRingStyles)(e,t)}
3648
- `,dd=(e,t)=>(0,s.progressRingTemplate)(e,t);class cd extends r.Progress{}const ud=void 0,hd={indeterminateIndicator:'\n <svg class="progress" part="progress" viewBox="0 0 16 16">\n <circle class="background" part="background" cx="8px" cy="8px" r="7px"></circle>\n <circle class="indeterminate-indicator-1" part="indeterminate-indicator-1" cx="8px" cy="8px" r="7px"></circle>\n </svg>\n '},pd=cd.compose(Object.assign({baseName:"progress-ring",template:dd,styles:ld,shadowOptions:ud},hd)),md=(e,t)=>l.css`
3648
+ `,dd=(e,t)=>(0,a.progressRingTemplate)(e,t);class cd extends r.Progress{}const ud=void 0,hd={indeterminateIndicator:'\n <svg class="progress" part="progress" viewBox="0 0 16 16">\n <circle class="background" part="background" cx="8px" cy="8px" r="7px"></circle>\n <circle class="indeterminate-indicator-1" part="indeterminate-indicator-1" cx="8px" cy="8px" r="7px"></circle>\n </svg>\n '},pd=cd.compose(Object.assign({baseName:"progress-ring",template:dd,styles:ld,shadowOptions:ud},hd)),md=(e,t)=>l.css`
3649
3649
  ${(0,r.radioStyles)(e,t)}
3650
- `,vd=(e,t)=>(0,s.radioTemplate)(e,t);class gd extends r.Radio{}const fd=void 0,bd={checkedIndicator:'\n <div part="checked-indicator" class="checked-indicator"></div>\n '},yd=gd.compose(Object.assign({baseName:"radio",template:vd,styles:md,shadowOptions:fd},bd)),wd=(e,t)=>l.css`
3650
+ `,gd=(e,t)=>(0,a.radioTemplate)(e,t);class vd extends r.Radio{}const fd=void 0,bd={checkedIndicator:'\n <div part="checked-indicator" class="checked-indicator"></div>\n '},yd=vd.compose(Object.assign({baseName:"radio",template:gd,styles:md,shadowOptions:fd},bd)),wd=(e,t)=>l.css`
3651
3651
  ${(0,r.radioGroupStyles)(e,t)}
3652
- `,Cd=(e,t)=>(0,s.radioGroupTemplate)(e,t);class xd extends r.RadioGroup{}const $d=void 0,Sd={},Ed=xd.compose(Object.assign({baseName:"radio-group",template:Cd,styles:wd,shadowOptions:$d},Sd)),kd=l.css`
3652
+ `,Cd=(e,t)=>(0,a.radioGroupTemplate)(e,t);class xd extends r.RadioGroup{}const $d=void 0,Sd={},Ed=xd.compose(Object.assign({baseName:"radio-group",template:Cd,styles:wd,shadowOptions:$d},Sd)),kd=l.css`
3653
3653
  /* Host */
3654
3654
  :host {
3655
3655
  display: flex;
@@ -3671,7 +3671,7 @@
3671
3671
  </template>
3672
3672
  `,Td=l.html`
3673
3673
  ${e=>Od(O(e))}
3674
- `;class Id extends s.FoundationElement{constructor(){super(...arguments),this.disableTooltips=!1,this.timezone="",this.cron=""}cronConfigChanged(){var e,t;this.timezone=(null===(e=this.cronConfig)||void 0===e?void 0:e.timezone)||"",this.cron=(null===(t=this.cronConfig)||void 0===t?void 0:t.cronExpression)||""}handleChange(e,t){e.stopPropagation();const{value:i}=e.target;this.cronConfig=Object.assign(Object.assign({},this.cronConfig),{[t]:i}),this.$emit("change",this.cronConfig)}}(0,C.Cg)([(0,l.attr)({attribute:"min-minute-interval"})],Id.prototype,"minMinuteInterval",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"disable-tooltips"})],Id.prototype,"disableTooltips",void 0),(0,C.Cg)([l.observable],Id.prototype,"timezone",void 0),(0,C.Cg)([l.observable],Id.prototype,"cron",void 0),(0,C.Cg)([l.observable],Id.prototype,"cronConfig",void 0);const Dd=void 0,Rd={},Ad=Id.compose(Object.assign({baseName:"scheduler",styles:kd,template:Td,shadowOptions:Dd},Rd)),Nd=(e,t,i)=>{if(!e.title)throw new Error("Title is required");if(!e.body)throw new Error("Missing required param 'body'");let o={title:e.title,body:e.body,iconName:e.iconName},n={};e.createdAt&&(o=Object.assign({createdAt:e.createdAt},o)),e.logLevel in Ke.LogLevel&&(o=Object.assign({logLevel:e.logLevel},o)),e.toast&&(n=Object.assign({toast:e.toast},n),o=Object.assign({config:n},o)),he(o,t,i)};var Ld,Fd,Md;!function(e){e.MINUTES="Minutes",e.HOURLY="Hourly",e.DAILY="Daily",e.WEEKLY="Weekly",e.MONTHLY="Monthly",e.YEARLY="Yearly"}(Ld||(Ld={})),function(e){e.WEEK="Week",e.WORK_WEEK="Work week"}(Fd||(Fd={})),function(e){e.DATE="Date",e.DAY_OF_MONTH="Day of month"}(Md||(Md={}));const _d=[{value:"2",label:"Monday"},{value:"3",label:"Tuesday"},{value:"4",label:"Wednesday"},{value:"5",label:"Thursday"},{value:"6",label:"Friday"},{value:"7",label:"Saturday"},{value:"1",label:"Sunday"}],Hd=[{value:"1",label:"First"},{value:"2",label:"Second"},{value:"3",label:"Third"},{value:"4",label:"Fourth"},{value:"-1",label:"Last"}],Pd=[{value:"1",label:"January"},{value:"2",label:"February"},{value:"3",label:"March"},{value:"4",label:"April"},{value:"5",label:"May"},{value:"6",label:"June"},{value:"7",label:"July"},{value:"8",label:"August"},{value:"9",label:"September"},{value:"10",label:"October"},{value:"11",label:"November"},{value:"12",label:"December"}];var zd;!function(e){e.updateCronConfig="update-cron-config"}(zd||(zd={}));const Ud=e=>Number(e)>1?`/${e}`:"";const Bd=(e,t,i)=>{const o=Number(e);return!isNaN(o)&&o<=i&&o>=t};function Wd(e,t,i,o=!1,n=Bd){if("*"===e)return!0;if(o&&("?"===e||"L"===e))return!0;if(o&&e.endsWith("L"))return n(e.slice(0,-1),t,i);if(e.startsWith("*/"))return n(e.substring(2),1,i);if(e.startsWith("0/"))return n(e.substring(2),1,i);if(o&&e.includes("#")){const[o,a]=e.split("#");return n(o,t,i)&&n(a,1,4)}if(n(e,t,i))return!0;if(e.includes("-")){const[o,a]=e.split("-");return n(o,t,i)&&n(a,t,i)}return!!e.includes(",")&&e.split(",").every(e=>Wd(e,t,i,o,n))}function Gd(e,t){return{type:Ld.DAILY,frequency:e.startsWith("*/")?e.split("*/")[1]:"1",weekType:"?"===t?Fd.WEEK:Fd.WORK_WEEK}}function jd(e){const t=e.includes("/");return{type:Ld.HOURLY,frequency:t?e.split("/")[1]:"1",during:t?"every_hour":"specific_hours",hours:t?void 0:e}}function Vd(e,t="*"){const i="*"!==t&&"0/1"!==t;return{type:Ld.MINUTES,frequency:e.includes("/")?e.split("/")[1]:"1",during:i?"specific_hours":"every_hour",hours:i?t:void 0}}function Yd(e){return{type:Ld.WEEKLY,selectedDays:"*"!==e?new Set(e.split(",")):new Set}}const qd=(e,t,i,o)=>{let n;return n="?"===t?{type:Md.DAY_OF_MONTH,day:o.split(/[L#]/)[0],weekNumber:o.includes("#")?o.split("#")[1]:"-1"}:{type:Md.DATE,dayDate:t},e===Ld.YEARLY&&(n.month=i),n};function Kd(e,t,i,o=qd){return{type:Ld.YEARLY,frequency:2===i.split("/").length?i.split("/")[1]:"1",dateOrDay:o(Ld.YEARLY,e,t,i.split("/")[0])}}function Xd(e,t,i,o=qd){return{type:Ld.MONTHLY,frequency:t.startsWith("*/")?t.split("*/")[1]:"1",dateOrDay:o(Ld.MONTHLY,e,t,i.split("/")[0])}}const Qd=l.css`
3674
+ `;class Id extends a.FoundationElement{constructor(){super(...arguments),this.disableTooltips=!1,this.timezone="",this.cron=""}cronConfigChanged(){var e,t;this.timezone=(null===(e=this.cronConfig)||void 0===e?void 0:e.timezone)||"",this.cron=(null===(t=this.cronConfig)||void 0===t?void 0:t.cronExpression)||""}handleChange(e,t){e.stopPropagation();const{value:i}=e.target;this.cronConfig=Object.assign(Object.assign({},this.cronConfig),{[t]:i}),this.$emit("change",this.cronConfig)}}(0,C.Cg)([(0,l.attr)({attribute:"min-minute-interval"})],Id.prototype,"minMinuteInterval",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"disable-tooltips"})],Id.prototype,"disableTooltips",void 0),(0,C.Cg)([l.observable],Id.prototype,"timezone",void 0),(0,C.Cg)([l.observable],Id.prototype,"cron",void 0),(0,C.Cg)([l.observable],Id.prototype,"cronConfig",void 0);const Rd=void 0,Ad={},Dd=Id.compose(Object.assign({baseName:"scheduler",styles:kd,template:Td,shadowOptions:Rd},Ad)),Nd=(e,t,i)=>{if(!e.title)throw new Error("Title is required");if(!e.body)throw new Error("Missing required param 'body'");let o={title:e.title,body:e.body,iconName:e.iconName},n={};e.createdAt&&(o=Object.assign({createdAt:e.createdAt},o)),e.logLevel in Ke.LogLevel&&(o=Object.assign({logLevel:e.logLevel},o)),e.toast&&(n=Object.assign({toast:e.toast},n),o=Object.assign({config:n},o)),he(o,t,i)};var Ld,Fd,Md;!function(e){e.MINUTES="Minutes",e.HOURLY="Hourly",e.DAILY="Daily",e.WEEKLY="Weekly",e.MONTHLY="Monthly",e.YEARLY="Yearly"}(Ld||(Ld={})),function(e){e.WEEK="Week",e.WORK_WEEK="Work week"}(Fd||(Fd={})),function(e){e.DATE="Date",e.DAY_OF_MONTH="Day of month"}(Md||(Md={}));const _d=[{value:"2",label:"Monday"},{value:"3",label:"Tuesday"},{value:"4",label:"Wednesday"},{value:"5",label:"Thursday"},{value:"6",label:"Friday"},{value:"7",label:"Saturday"},{value:"1",label:"Sunday"}],Hd=[{value:"1",label:"First"},{value:"2",label:"Second"},{value:"3",label:"Third"},{value:"4",label:"Fourth"},{value:"-1",label:"Last"}],Pd=[{value:"1",label:"January"},{value:"2",label:"February"},{value:"3",label:"March"},{value:"4",label:"April"},{value:"5",label:"May"},{value:"6",label:"June"},{value:"7",label:"July"},{value:"8",label:"August"},{value:"9",label:"September"},{value:"10",label:"October"},{value:"11",label:"November"},{value:"12",label:"December"}];var zd;!function(e){e.updateCronConfig="update-cron-config"}(zd||(zd={}));const Ud=e=>Number(e)>1?`/${e}`:"";const Wd=(e,t,i)=>{const o=Number(e);return!isNaN(o)&&o<=i&&o>=t};function Gd(e,t,i,o=!1,n=Wd){if("*"===e)return!0;if(o&&("?"===e||"L"===e))return!0;if(o&&e.endsWith("L"))return n(e.slice(0,-1),t,i);if(e.startsWith("*/"))return n(e.substring(2),1,i);if(e.startsWith("0/"))return n(e.substring(2),1,i);if(o&&e.includes("#")){const[o,s]=e.split("#");return n(o,t,i)&&n(s,1,4)}if(n(e,t,i))return!0;if(e.includes("-")){const[o,s]=e.split("-");return n(o,t,i)&&n(s,t,i)}return!!e.includes(",")&&e.split(",").every(e=>Gd(e,t,i,o,n))}function Bd(e,t){return{type:Ld.DAILY,frequency:e.startsWith("*/")?e.split("*/")[1]:"1",weekType:"?"===t?Fd.WEEK:Fd.WORK_WEEK}}function Vd(e){const t=e.includes("/");return{type:Ld.HOURLY,frequency:t?e.split("/")[1]:"1",during:t?"every_hour":"specific_hours",hours:t?void 0:e}}function jd(e,t="*"){const i="*"!==t&&"0/1"!==t;return{type:Ld.MINUTES,frequency:e.includes("/")?e.split("/")[1]:"1",during:i?"specific_hours":"every_hour",hours:i?t:void 0}}function Yd(e){return{type:Ld.WEEKLY,selectedDays:"*"!==e?new Set(e.split(",")):new Set}}const qd=(e,t,i,o)=>{let n;return n="?"===t?{type:Md.DAY_OF_MONTH,day:o.split(/[L#]/)[0],weekNumber:o.includes("#")?o.split("#")[1]:"-1"}:{type:Md.DATE,dayDate:t},e===Ld.YEARLY&&(n.month=i),n};function Kd(e,t,i,o=qd){return{type:Ld.YEARLY,frequency:2===i.split("/").length?i.split("/")[1]:"1",dateOrDay:o(Ld.YEARLY,e,t,i.split("/")[0])}}function Xd(e,t,i,o=qd){return{type:Ld.MONTHLY,frequency:t.startsWith("*/")?t.split("*/")[1]:"1",dateOrDay:o(Ld.MONTHLY,e,t,i.split("/")[0])}}const Qd=l.css`
3675
3675
  .input-container {
3676
3676
  display: flex;
3677
3677
  flex-direction: column;
@@ -3770,7 +3770,7 @@
3770
3770
  }
3771
3771
  `;var Zd=i(20633);const ec=(e,t,i)=>l.html`
3772
3772
  <${t}-icon tooltip="${()=>e}" name="${()=>i}"></${t}-icon>
3773
- `,tc=e=>class extends e{$emit(...e){const[t,i,o]=((...e)=>{let[t,i,o]=e,n=i;var a;if(((null==(a=i)?void 0:a.hasOwnProperty("bubbles"))||(null==a?void 0:a.hasOwnProperty("cancelable"))||(null==a?void 0:a.hasOwnProperty("composed"))||(null==a?void 0:a.hasOwnProperty("broadcast")))&&(o=i,n=void 0),"string"!=typeof t)throw new Error("$emit event types must be typeof string.");return[t,n,o]})(...e);if(null==o?void 0:o.broadcast){const e=new CustomEvent(t,Object.assign({detail:i,bubbles:!0,composed:!0,cancelable:!0},o));return e.broadcast=!0,this.dispatchEvent(e)}return super.$emit(t,i,o)}},ic=l.css`
3773
+ `,tc=e=>class extends e{$emit(...e){const[t,i,o]=((...e)=>{let[t,i,o]=e,n=i;var s;if(((null==(s=i)?void 0:s.hasOwnProperty("bubbles"))||(null==s?void 0:s.hasOwnProperty("cancelable"))||(null==s?void 0:s.hasOwnProperty("composed"))||(null==s?void 0:s.hasOwnProperty("broadcast")))&&(o=i,n=void 0),"string"!=typeof t)throw new Error("$emit event types must be typeof string.");return[t,n,o]})(...e);if(null==o?void 0:o.broadcast){const e=new CustomEvent(t,Object.assign({detail:i,bubbles:!0,composed:!0,cancelable:!0},o));return e.broadcast=!0,this.dispatchEvent(e)}return super.$emit(t,i,o)}},ic=l.css`
3774
3774
  ${Qd}
3775
3775
  `,oc="\n <p>Select one or more hours.</p>\n",nc=l.html`
3776
3776
  ${e=>{return t=e.prefix,l.html`
@@ -3792,7 +3792,7 @@
3792
3792
  </div>
3793
3793
  </template>
3794
3794
  `;var t}}
3795
- `;let ac=class extends(tc(s.FoundationElement)){constructor(){super(...arguments),this.disableTooltips=!1,this.prefix=""}configChanged(){var e;this.weekType=(null===(e=this.config)||void 0===e?void 0:e.weekType)||Fd.WORK_WEEK}updateCronConfig(){this.config=Object.assign(Object.assign({},this.config),{weekType:this.weekType}),this.$emit(zd.updateCronConfig,this.config)}};(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"disable-tooltips"})],ac.prototype,"disableTooltips",void 0),(0,C.Cg)([l.observable],ac.prototype,"prefix",void 0),(0,C.Cg)([l.observable],ac.prototype,"config",void 0),(0,C.Cg)([l.observable],ac.prototype,"weekType",void 0),ac=(0,C.Cg)([(0,l.customElement)({name:"daily-recurrence",template:nc,styles:ic})],ac);const sc=l.css`
3795
+ `;let sc=class extends(tc(a.FoundationElement)){constructor(){super(...arguments),this.disableTooltips=!1,this.prefix=""}configChanged(){var e;this.weekType=(null===(e=this.config)||void 0===e?void 0:e.weekType)||Fd.WORK_WEEK}updateCronConfig(){this.config=Object.assign(Object.assign({},this.config),{weekType:this.weekType}),this.$emit(zd.updateCronConfig,this.config)}};(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"disable-tooltips"})],sc.prototype,"disableTooltips",void 0),(0,C.Cg)([l.observable],sc.prototype,"prefix",void 0),(0,C.Cg)([l.observable],sc.prototype,"config",void 0),(0,C.Cg)([l.observable],sc.prototype,"weekType",void 0),sc=(0,C.Cg)([(0,l.customElement)({name:"daily-recurrence",template:nc,styles:ic})],sc);const ac=l.css`
3796
3796
  ${Qd}
3797
3797
  :host {
3798
3798
  display: flex;
@@ -3897,7 +3897,7 @@
3897
3897
  `)(e))}
3898
3898
  `,dc=l.html`
3899
3899
  ${e=>lc(e.prefix)}
3900
- `;let cc=class extends(tc(s.FoundationElement)){constructor(){super(...arguments),this.prefix="",this.dayOrDate=Md.DATE,this.weekNumber="1",this.day="1",this.selectedMonth="1"}configChanged(){this.config.type!==Ld.YEARLY&&this.config.type!==Ld.MONTHLY||(this.dayOrDate=this.config.dateOrDay.type||Md.DATE,this.setFieldsFromConfig())}setFieldsFromConfig(){this.config.type===Ld.YEARLY&&(this.selectedMonth=this.config.dateOrDay.month),this.config.dateOrDay.type===Md.DAY_OF_MONTH?(this.weekNumber=this.config.dateOrDay.weekNumber||"1",this.day=this.config.dateOrDay.day||"1"):this.dayDate=this.config.dateOrDay.dayDate||"1"}getDayOrDateConfig(){let e;return e=this.dayOrDate===Md.DATE?{type:Md.DATE,dayDate:this.dayDate||"1"}:{type:Md.DAY_OF_MONTH,day:this.day||"1",weekNumber:this.weekNumber||"1"},e}updateCronConfig(){this.config.type===Ld.MONTHLY?this.config=Object.assign(Object.assign({},this.config),{dateOrDay:this.getDayOrDateConfig()}):this.config=Object.assign(Object.assign({},this.config),{dateOrDay:Object.assign(Object.assign({},this.getDayOrDateConfig()),{month:this.selectedMonth||"1"})}),this.$emit(zd.updateCronConfig,this.config)}};(0,C.Cg)([l.observable],cc.prototype,"prefix",void 0),(0,C.Cg)([l.observable],cc.prototype,"config",void 0),(0,C.Cg)([l.observable],cc.prototype,"dayOrDate",void 0),(0,C.Cg)([l.observable],cc.prototype,"dayDate",void 0),(0,C.Cg)([l.observable],cc.prototype,"weekNumber",void 0),(0,C.Cg)([l.observable],cc.prototype,"day",void 0),(0,C.Cg)([l.observable],cc.prototype,"selectedMonth",void 0),cc=(0,C.Cg)([(0,l.customElement)({name:"monthly-yearly-recurrence",template:dc,styles:sc})],cc);const uc=l.css`
3900
+ `;let cc=class extends(tc(a.FoundationElement)){constructor(){super(...arguments),this.prefix="",this.dayOrDate=Md.DATE,this.weekNumber="1",this.day="1",this.selectedMonth="1"}configChanged(){this.config.type!==Ld.YEARLY&&this.config.type!==Ld.MONTHLY||(this.dayOrDate=this.config.dateOrDay.type||Md.DATE,this.setFieldsFromConfig())}setFieldsFromConfig(){this.config.type===Ld.YEARLY&&(this.selectedMonth=this.config.dateOrDay.month),this.config.dateOrDay.type===Md.DAY_OF_MONTH?(this.weekNumber=this.config.dateOrDay.weekNumber||"1",this.day=this.config.dateOrDay.day||"1"):this.dayDate=this.config.dateOrDay.dayDate||"1"}getDayOrDateConfig(){let e;return e=this.dayOrDate===Md.DATE?{type:Md.DATE,dayDate:this.dayDate||"1"}:{type:Md.DAY_OF_MONTH,day:this.day||"1",weekNumber:this.weekNumber||"1"},e}updateCronConfig(){this.config.type===Ld.MONTHLY?this.config=Object.assign(Object.assign({},this.config),{dateOrDay:this.getDayOrDateConfig()}):this.config=Object.assign(Object.assign({},this.config),{dateOrDay:Object.assign(Object.assign({},this.getDayOrDateConfig()),{month:this.selectedMonth||"1"})}),this.$emit(zd.updateCronConfig,this.config)}};(0,C.Cg)([l.observable],cc.prototype,"prefix",void 0),(0,C.Cg)([l.observable],cc.prototype,"config",void 0),(0,C.Cg)([l.observable],cc.prototype,"dayOrDate",void 0),(0,C.Cg)([l.observable],cc.prototype,"dayDate",void 0),(0,C.Cg)([l.observable],cc.prototype,"weekNumber",void 0),(0,C.Cg)([l.observable],cc.prototype,"day",void 0),(0,C.Cg)([l.observable],cc.prototype,"selectedMonth",void 0),cc=(0,C.Cg)([(0,l.customElement)({name:"monthly-yearly-recurrence",template:dc,styles:ac})],cc);const uc=l.css`
3901
3901
  ${Qd}
3902
3902
  .weekdays-row {
3903
3903
  display: flex;
@@ -3928,12 +3928,12 @@
3928
3928
  </div>
3929
3929
  </template>
3930
3930
  `;var t}}
3931
- `;let pc=class extends(tc(s.FoundationElement)){constructor(){super(...arguments),this.disableTooltips=!1,this.prefix="",this.selectedDays=new Set}configChanged(){var e;this.selectedDays=(null===(e=this.config)||void 0===e?void 0:e.selectedDays)?new Set([...this.config.selectedDays]):new Set}isDisabled(e){return 1===this.selectedDays.size&&this.selectedDays.has(e)}checkboxChangeHandler(e){const{checked:t,value:i}=e.target;t?this.selectedDays.add(i):this.selectedDays.size>1&&this.selectedDays.delete(i),this.updateCronConfig()}updateCronConfig(){this.config=Object.assign(Object.assign({},this.config),{selectedDays:this.selectedDays}),this.$emit(zd.updateCronConfig,this.config)}};(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"disable-tooltips"})],pc.prototype,"disableTooltips",void 0),(0,C.Cg)([l.observable],pc.prototype,"prefix",void 0),(0,C.Cg)([l.observable],pc.prototype,"config",void 0),(0,C.Cg)([l.observable],pc.prototype,"selectedDays",void 0),pc=(0,C.Cg)([(0,l.customElement)({name:"weekly-recurrence",template:hc,styles:uc})],pc),(0,Zd.N)(ac,pc,cc);const mc=(e,t)=>l.html`
3931
+ `;let pc=class extends(tc(a.FoundationElement)){constructor(){super(...arguments),this.disableTooltips=!1,this.prefix="",this.selectedDays=new Set}configChanged(){var e;this.selectedDays=(null===(e=this.config)||void 0===e?void 0:e.selectedDays)?new Set([...this.config.selectedDays]):new Set}isDisabled(e){return 1===this.selectedDays.size&&this.selectedDays.has(e)}checkboxChangeHandler(e){const{checked:t,value:i}=e.target;t?this.selectedDays.add(i):this.selectedDays.size>1&&this.selectedDays.delete(i),this.updateCronConfig()}updateCronConfig(){this.config=Object.assign(Object.assign({},this.config),{selectedDays:this.selectedDays}),this.$emit(zd.updateCronConfig,this.config)}};(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"disable-tooltips"})],pc.prototype,"disableTooltips",void 0),(0,C.Cg)([l.observable],pc.prototype,"prefix",void 0),(0,C.Cg)([l.observable],pc.prototype,"config",void 0),(0,C.Cg)([l.observable],pc.prototype,"selectedDays",void 0),pc=(0,C.Cg)([(0,l.customElement)({name:"weekly-recurrence",template:hc,styles:uc})],pc),(0,Zd.N)(sc,pc,cc);const mc=(e,t)=>l.html`
3932
3932
  <monthly-yearly-recurrence
3933
3933
  :prefix=${()=>e}
3934
3934
  :config=${()=>t.cronConfig}
3935
3935
  ></monthly-yearly-recurrence>
3936
- `,vc=(e,t,i)=>l.html`
3936
+ `,gc=(e,t,i)=>l.html`
3937
3937
  <div class="input-container">
3938
3938
  ${(0,l.when)(()=>i,l.html`
3939
3939
  <label class="label">${i}</label>
@@ -3951,7 +3951,7 @@
3951
3951
  <div slot="end" class="suffix-label">${()=>t.frequencySuffix}</div>
3952
3952
  </${e}-select>
3953
3953
  </div>
3954
- `,gc=(e,t,i,o)=>l.html`
3954
+ `,vc=(e,t,i,o)=>l.html`
3955
3955
  <div class="input-container">
3956
3956
  <label class="label">Time </label>
3957
3957
  <div class="flex-row">
@@ -4017,8 +4017,8 @@
4017
4017
  `)}
4018
4018
  </div>
4019
4019
  <div class="row">
4020
- ${vc(t,i,"Every")}
4021
- ${gc(t,i,!1,!1)}
4020
+ ${gc(t,i,"Every")}
4021
+ ${vc(t,i,!1,!1)}
4022
4022
  </div>
4023
4023
  `;case Ld.HOURLY:return l.html`
4024
4024
  <div class="row">
@@ -4036,7 +4036,7 @@
4036
4036
  <${t}-option value="specific_hours">Selected Hours</${t}-option>
4037
4037
  </${t}-select>
4038
4038
  </div>
4039
- ${(0,l.when)(()=>"every_hour"===i.during,vc(t,i,"Every"))}
4039
+ ${(0,l.when)(()=>"every_hour"===i.during,gc(t,i,"Every"))}
4040
4040
  ${(0,l.when)(()=>i.isSpecificHours,l.html`
4041
4041
  <div class="break"></div>
4042
4042
  <div class="input-container">
@@ -4053,7 +4053,7 @@
4053
4053
  ></${t}-multiselect>
4054
4054
  </div>
4055
4055
  `)}
4056
- ${gc(t,i,!1,!0)}
4056
+ ${vc(t,i,!1,!0)}
4057
4057
  </div>
4058
4058
  `;case Ld.DAILY:return l.html`
4059
4059
  ${((e,t)=>l.html`
@@ -4064,8 +4064,8 @@
4064
4064
  ></daily-recurrence>
4065
4065
  `)(t,i)}
4066
4066
  <div class="row">
4067
- ${vc(t,i,"Every")}
4068
- ${gc(t,i,!0,!0)}
4067
+ ${gc(t,i,"Every")}
4068
+ ${vc(t,i,!0,!0)}
4069
4069
  </div>
4070
4070
  `;case Ld.WEEKLY:return l.html`
4071
4071
  <div class="row">
@@ -4075,16 +4075,16 @@
4075
4075
  :config=${()=>t.cronConfig}
4076
4076
  ?disable-tooltips=${()=>t.disableTooltips}
4077
4077
  ></weekly-recurrence>
4078
- `)(t,i)} ${gc(t,i,!0,!0)}
4078
+ `)(t,i)} ${vc(t,i,!0,!0)}
4079
4079
  </div>
4080
4080
  `;case Ld.MONTHLY:return l.html`
4081
4081
  <div class="row">
4082
- ${vc(t,i,"Every")}
4083
- ${gc(t,i,!0,!0)}
4082
+ ${gc(t,i,"Every")}
4083
+ ${vc(t,i,!0,!0)}
4084
4084
  </div>
4085
4085
  ${mc(t,i)}
4086
4086
  `;case Ld.YEARLY:return l.html`
4087
- <div class="row">${gc(t,i,!0,!0)}</div>
4087
+ <div class="row">${vc(t,i,!0,!0)}</div>
4088
4088
  ${mc(t,i)}
4089
4089
  `;default:return l.html``}},bc=e=>l.html`
4090
4090
  <template>
@@ -4131,7 +4131,7 @@
4131
4131
  </template>
4132
4132
  `,yc=l.html`
4133
4133
  ${e=>bc(O(e))}
4134
- `;class wc extends s.FoundationElement{constructor(){super(...arguments),this.getConfigs={buildConfigForMinutesRecurrence:Vd,buildConfigForHourlyRecurrence:jd,buildConfigForDailyRecurrence:Gd,buildConfigForWeeklyRecurrence:Yd,buildConfigForMonthlyRecurrence:Xd,buildConfigForYearlyRecurrence:Kd},this.recurrence=Ld.DAILY,this.cron="",this.value=this.cron,this.cronConfig={type:Ld.DAILY,weekType:Fd.WEEK,hours:"0",minutes:"0",seconds:"0"},this.frequency="1",this.during="every_hour",this.hours="0",this.minutes="0",this.seconds="0",this.disableTooltips=!1,this.timezone=""}cronChanged(){if(this.cron)try{if(!((e,t=Wd)=>{const i=e.trim().split(" ");if(6!=i.length)return!1;const[o,n,a,s,r,l]=i;return t(o,0,59)&&t(n,0,59)&&t(a,0,23)&&t(s,1,31,!0)&&t(r,1,12)&&t(l,0,7,!0)})(this.cron))return void Nd({title:"Cron Scheduler",body:"Invalid Cron Expression",toast:{type:"critical"}},O(this));this.setsFieldsFromCronEx()}catch(e){return console.error("Error:",e),void Nd({title:"Cron Scheduler",body:e,toast:{type:"critical"}},O(this))}}get duringOptions(){return[{label:"Every hour",value:"every_hour"},{label:"Specific hours",value:"specific_hours"}]}get frequencySuffix(){switch(this.cronConfig.type){case Ld.MINUTES:return"Minute(s)";case Ld.HOURLY:return"Hour(s)";case Ld.DAILY:return"Day(s)";case Ld.MONTHLY:return"Month(s)";default:return""}}get frequencyList(){switch(this.cronConfig.type){case Ld.MINUTES:const e=[1,2,3,4,5,6,10,12,15,20,30],t=this.minMinuteInterval?Number(this.minMinuteInterval):1;return e.filter(e=>e>=t);case Ld.HOURLY:return Array.from({length:23},(e,t)=>t+1);case Ld.DAILY:return Array.from({length:31},(e,t)=>t+1);case Ld.MONTHLY:case Ld.YEARLY:return Array.from({length:12},(e,t)=>t+1);case Ld.WEEKLY:return[1];default:return[]}}get hourOptions(){return Array.from({length:24},(e,t)=>({label:t.toString(),value:t.toString()}))}get selectedHours(){return this.hours&&"*"!==this.hours&&"0"!==this.hours?this.hours.split(","):"*"===this.hours?this.hourOptions.map(e=>e.value):[this.hours]}handleHoursChange(e){const t=e.detail;24===t.length?(this.hours="*",this.frequency="1",this.cronConfig.frequency="1"):t&&0!==t.length?this.hours=t.sort((e,t)=>Number(e)-Number(t)).join(","):this.hours="0",this.handleChange("hours")}get isMinutesRecurrenceEnabled(){return!this.minMinuteInterval||Number(this.minMinuteInterval)<=30}get isSpecificHours(){return"specific_hours"===this.during}get isDailyFrequencyDisabled(){return this.cronConfig.type===Ld.DAILY&&this.cronConfig.weekType===Fd.WORK_WEEK}minMinuteIntervalChanged(){this.minMinuteInterval>=60&&console.warn("Minimum minute interval has no effect on schedules with an hourly or longer recurrance")}connectedCallback(){super.connectedCallback(),this.addEventListener(zd.updateCronConfig,this.handleCronConfigUpdate)}disconnectedCallback(){this.removeEventListener(zd.updateCronConfig,this.handleCronConfigUpdate)}getBaseConfigFields(){return{frequency:this.frequency,hours:this.hours,minutes:this.minutes,seconds:this.seconds}}handleRecurrenceChange(){switch(this.recurrence){case Ld.MINUTES:const e=this.getBaseConfigFields(),{minutes:t}=e,i=(0,C.Tt)(e,["minutes"]);this.during="every_hour",this.hours="*";const o=[1,2,3,4,5,6,10,12,15,20,30],n=this.minMinuteInterval?Number(this.minMinuteInterval):1,a=o.find(e=>e>=n)||1;this.cronConfig=Object.assign(Object.assign({type:Ld.MINUTES},i),{frequency:a.toString(),during:"every_hour",hours:"*"}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.HOURLY:const s=this.getBaseConfigFields(),{hours:r}=s,l=(0,C.Tt)(s,["hours"]);this.during="every_hour",this.hours="0",this.cronConfig=Object.assign(Object.assign({type:Ld.HOURLY},l),{frequency:"1",during:"every_hour",hours:"0"}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.DAILY:("*"===this.hours||this.hours.includes(","))&&(this.hours="0"),this.cronConfig=Object.assign(Object.assign({type:Ld.DAILY},this.getBaseConfigFields()),{frequency:"1",weekType:Fd.WEEK}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.WEEKLY:("*"===this.hours||this.hours.includes(","))&&(this.hours="0"),this.cronConfig=Object.assign(Object.assign({type:Ld.WEEKLY},this.getBaseConfigFields()),{frequency:"1",selectedDays:new Set(["2"])}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.MONTHLY:("*"===this.hours||this.hours.includes(","))&&(this.hours="0"),this.cronConfig=Object.assign(Object.assign({type:Ld.MONTHLY},this.getBaseConfigFields()),{frequency:"1",dateOrDay:{type:Md.DATE,dayDate:"1"}}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.YEARLY:("*"===this.hours||this.hours.includes(","))&&(this.hours="0"),this.cronConfig=Object.assign(Object.assign({type:Ld.YEARLY},this.getBaseConfigFields()),{frequency:"1",dateOrDay:{type:Md.DATE,dayDate:"1",month:"1"}}),this.generateCronExpressionFromConfig(this.cronConfig);break;default:Nd({title:"Cron Scheduler",body:"Recurrence type should be one of the known types: Daily, Weekly,Monthly or Yearly",toast:{type:"critical"}},O(this))}}handleChange(e){if("frequency"===e&&0===Number(this.frequency))throw new Error("Frequency must be greater than 0");this.cronConfig[e]=this[e],this.generateCronExpressionFromConfig(this.cronConfig)}handleDuringChange(){"every_hour"===this.during?this.hours="*":"*"===this.hours&&(this.hours="0"),this.cronConfig.type!==Ld.MINUTES&&this.cronConfig.type!==Ld.HOURLY||(this.cronConfig.during=this.during,this.cronConfig.hours=this.hours),this.generateCronExpressionFromConfig(this.cronConfig)}handleCronConfigUpdate({detail:e}){this.cronConfig=Object.assign(Object.assign({},this.getBaseConfigFields()),e),this.generateCronExpressionFromConfig(this.cronConfig)}generateCronExpressionFromConfig(e){switch(e.type){case Ld.MINUTES:this.cron=function(e){const t="specific_hours"===e.during&&e.hours?e.hours:"*";return`${e.seconds} 0/${e.frequency} ${t} ? * *`}(e);break;case Ld.HOURLY:this.cron=function(e){return"specific_hours"===e.during&&e.hours&&"*"!==e.hours?`${e.seconds} ${e.minutes} ${e.hours} ? * *`:`${e.seconds} ${e.minutes} 0/${e.frequency} ? * *`}(e);break;case Ld.DAILY:this.cron=function(e,t=Ud){const i=e.weekType===Fd.WORK_WEEK?"?":`*${t(e.frequency)}`;return`${e.seconds} ${e.minutes} ${e.hours} ${i} * ${e.weekType===Fd.WORK_WEEK?"2-6":"?"}`}(e,Ud);break;case Ld.WEEKLY:this.cron=function(e){const t=[...e.selectedDays].join(",")||"*";return`${e.seconds} ${e.minutes} ${e.hours} ? * ${t}`}(e);break;case Ld.MONTHLY:this.cron=function(e,t=Ud){const{dateOrDay:i,minutes:o,hours:n,seconds:a,frequency:s}=e,r=t(s);return i.type===Md.DATE?`${a} ${o} ${n} ${i.dayDate} *${r} ?`:"-1"===i.weekNumber?`${a} ${o} ${n} ? *${r} ${i.day}L`:`${e.seconds} ${o} ${n} ? *${r} ${i.day}#${i.weekNumber}`}(e,Ud);break;case Ld.YEARLY:this.cron=function(e){const{dateOrDay:t,minutes:i,seconds:o,hours:n}=e;return t.type===Md.DATE?`${o} ${i} ${n} ${t.dayDate} ${t.month} ?`:"-1"===t.weekNumber?`${o} ${i} ${n} ? ${t.month} ${t.day}L`:`${o} ${i} ${n} ? ${t.month} ${t.day}#${t.weekNumber}`}(e);break;default:Nd({title:"Cron Scheduler",body:"Recurrence type should be one of the known types: Daily, Weekly,Monthly or Yearly",toast:{type:"critical"}},O(this))}this.value=this.cron,this.$emit("change")}setsFieldsFromCronEx(){this.cronConfig=function(e,t){if(!e)return;const i=e.split(" "),[o,n,a,s,r,l]=i;if("?"!==l&&"?"!==s)throw new Error("Support for specifying both a day-of-week AND a day-of-month parameter is not implemented");if(/^(0|\*)\/\d+$/.test(n))return Object.assign({seconds:o},t.buildConfigForMinutesRecurrence(n,a));if(/^(0|\*)\/\d+$/.test(a))return Object.assign({minutes:n,seconds:o},t.buildConfigForHourlyRecurrence(a));if("?"===s&&"*"===l)return Object.assign({minutes:n,seconds:o},t.buildConfigForHourlyRecurrence(a));if("2-6"===l||"?"===l&&("*"===s||s.startsWith("*")))return Object.assign({hours:a,minutes:n,seconds:o},t.buildConfigForDailyRecurrence(s,l));if(/^([1-7](,[1-7])*)$/.test(l)||"*"===l)return Object.assign({hours:a,minutes:n,seconds:o},t.buildConfigForWeeklyRecurrence(l));if(l.includes("L")||l.includes("#")||/^([1-9]|[12]\d|3[01])$/.test(s)&&"?"===l)return"*"==r||r.startsWith("*/")?Object.assign({hours:a,minutes:n,seconds:o},t.buildConfigForMonthlyRecurrence(s,r,l)):Object.assign({hours:a,minutes:n,seconds:o},t.buildConfigForYearlyRecurrence(s,r,l));throw new Error("Invalid Cron Expression")}(this.cron,this.getConfigs),this.recurrence=this.cronConfig.type,this.frequency=this.cronConfig.frequency;const e=this.cronConfig;"minutes"in e&&(this.minutes=e.minutes),e.type!==Ld.MINUTES&&e.type!==Ld.HOURLY||(this.during=e.during||"every_hour",e.hours&&(this.hours=e.hours)),this.seconds=e.seconds,e.type!==Ld.HOURLY&&e.type!==Ld.MINUTES&&(this.hours=e.hours)}}(0,C.Cg)([l.observable],wc.prototype,"recurrence",void 0),(0,C.Cg)([l.observable],wc.prototype,"cron",void 0),(0,C.Cg)([l.observable],wc.prototype,"cronConfig",void 0),(0,C.Cg)([l.observable],wc.prototype,"frequency",void 0),(0,C.Cg)([l.observable],wc.prototype,"during",void 0),(0,C.Cg)([l.volatile],wc.prototype,"duringOptions",null),(0,C.Cg)([l.observable],wc.prototype,"hours",void 0),(0,C.Cg)([l.observable],wc.prototype,"minutes",void 0),(0,C.Cg)([l.observable],wc.prototype,"seconds",void 0),(0,C.Cg)([l.volatile],wc.prototype,"frequencySuffix",null),(0,C.Cg)([l.volatile],wc.prototype,"frequencyList",null),(0,C.Cg)([l.volatile],wc.prototype,"hourOptions",null),(0,C.Cg)([l.volatile],wc.prototype,"selectedHours",null),(0,C.Cg)([(0,l.attr)({attribute:"min-minute-interval"})],wc.prototype,"minMinuteInterval",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"disable-tooltips"})],wc.prototype,"disableTooltips",void 0),(0,C.Cg)([l.volatile],wc.prototype,"isMinutesRecurrenceEnabled",null),(0,C.Cg)([l.volatile],wc.prototype,"isSpecificHours",null),(0,C.Cg)([l.volatile],wc.prototype,"isDailyFrequencyDisabled",null),(0,C.Cg)([l.attr],wc.prototype,"timezone",void 0);const Cc=void 0,xc={},$c=wc.compose(Object.assign({baseName:"scheduler-cron-builder",styles:Jd,template:yc,shadowOptions:Cc},xc)),Sc=l.css`
4134
+ `;class wc extends a.FoundationElement{constructor(){super(...arguments),this.getConfigs={buildConfigForMinutesRecurrence:jd,buildConfigForHourlyRecurrence:Vd,buildConfigForDailyRecurrence:Bd,buildConfigForWeeklyRecurrence:Yd,buildConfigForMonthlyRecurrence:Xd,buildConfigForYearlyRecurrence:Kd},this.recurrence=Ld.DAILY,this.cron="",this.value=this.cron,this.cronConfig={type:Ld.DAILY,weekType:Fd.WEEK,hours:"0",minutes:"0",seconds:"0"},this.frequency="1",this.during="every_hour",this.hours="0",this.minutes="0",this.seconds="0",this.disableTooltips=!1,this.timezone=""}cronChanged(){if(this.cron)try{if(!((e,t=Gd)=>{const i=e.trim().split(" ");if(6!=i.length)return!1;const[o,n,s,a,r,l]=i;return t(o,0,59)&&t(n,0,59)&&t(s,0,23)&&t(a,1,31,!0)&&t(r,1,12)&&t(l,0,7,!0)})(this.cron))return void Nd({title:"Cron Scheduler",body:"Invalid Cron Expression",toast:{type:"critical"}},O(this));this.setsFieldsFromCronEx()}catch(e){return console.error("Error:",e),void Nd({title:"Cron Scheduler",body:e,toast:{type:"critical"}},O(this))}}get duringOptions(){return[{label:"Every hour",value:"every_hour"},{label:"Specific hours",value:"specific_hours"}]}get frequencySuffix(){switch(this.cronConfig.type){case Ld.MINUTES:return"Minute(s)";case Ld.HOURLY:return"Hour(s)";case Ld.DAILY:return"Day(s)";case Ld.MONTHLY:return"Month(s)";default:return""}}get frequencyList(){switch(this.cronConfig.type){case Ld.MINUTES:const e=[1,2,3,4,5,6,10,12,15,20,30],t=this.minMinuteInterval?Number(this.minMinuteInterval):1;return e.filter(e=>e>=t);case Ld.HOURLY:return Array.from({length:23},(e,t)=>t+1);case Ld.DAILY:return Array.from({length:31},(e,t)=>t+1);case Ld.MONTHLY:case Ld.YEARLY:return Array.from({length:12},(e,t)=>t+1);case Ld.WEEKLY:return[1];default:return[]}}get hourOptions(){return Array.from({length:24},(e,t)=>({label:t.toString(),value:t.toString()}))}get selectedHours(){return this.hours&&"*"!==this.hours&&"0"!==this.hours?this.hours.split(","):"*"===this.hours?this.hourOptions.map(e=>e.value):[this.hours]}handleHoursChange(e){const t=e.detail;24===t.length?(this.hours="*",this.frequency="1",this.cronConfig.frequency="1"):t&&0!==t.length?this.hours=t.sort((e,t)=>Number(e)-Number(t)).join(","):this.hours="0",this.handleChange("hours")}get isMinutesRecurrenceEnabled(){return!this.minMinuteInterval||Number(this.minMinuteInterval)<=30}get isSpecificHours(){return"specific_hours"===this.during}get isDailyFrequencyDisabled(){return this.cronConfig.type===Ld.DAILY&&this.cronConfig.weekType===Fd.WORK_WEEK}minMinuteIntervalChanged(){this.minMinuteInterval>=60&&console.warn("Minimum minute interval has no effect on schedules with an hourly or longer recurrance")}connectedCallback(){super.connectedCallback(),this.addEventListener(zd.updateCronConfig,this.handleCronConfigUpdate)}disconnectedCallback(){this.removeEventListener(zd.updateCronConfig,this.handleCronConfigUpdate)}getBaseConfigFields(){return{frequency:this.frequency,hours:this.hours,minutes:this.minutes,seconds:this.seconds}}handleRecurrenceChange(){switch(this.recurrence){case Ld.MINUTES:const e=this.getBaseConfigFields(),{minutes:t}=e,i=(0,C.Tt)(e,["minutes"]);this.during="every_hour",this.hours="*";const o=[1,2,3,4,5,6,10,12,15,20,30],n=this.minMinuteInterval?Number(this.minMinuteInterval):1,s=o.find(e=>e>=n)||1;this.cronConfig=Object.assign(Object.assign({type:Ld.MINUTES},i),{frequency:s.toString(),during:"every_hour",hours:"*"}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.HOURLY:const a=this.getBaseConfigFields(),{hours:r}=a,l=(0,C.Tt)(a,["hours"]);this.during="every_hour",this.hours="0",this.cronConfig=Object.assign(Object.assign({type:Ld.HOURLY},l),{frequency:"1",during:"every_hour",hours:"0"}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.DAILY:("*"===this.hours||this.hours.includes(","))&&(this.hours="0"),this.cronConfig=Object.assign(Object.assign({type:Ld.DAILY},this.getBaseConfigFields()),{frequency:"1",weekType:Fd.WEEK}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.WEEKLY:("*"===this.hours||this.hours.includes(","))&&(this.hours="0"),this.cronConfig=Object.assign(Object.assign({type:Ld.WEEKLY},this.getBaseConfigFields()),{frequency:"1",selectedDays:new Set(["2"])}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.MONTHLY:("*"===this.hours||this.hours.includes(","))&&(this.hours="0"),this.cronConfig=Object.assign(Object.assign({type:Ld.MONTHLY},this.getBaseConfigFields()),{frequency:"1",dateOrDay:{type:Md.DATE,dayDate:"1"}}),this.generateCronExpressionFromConfig(this.cronConfig);break;case Ld.YEARLY:("*"===this.hours||this.hours.includes(","))&&(this.hours="0"),this.cronConfig=Object.assign(Object.assign({type:Ld.YEARLY},this.getBaseConfigFields()),{frequency:"1",dateOrDay:{type:Md.DATE,dayDate:"1",month:"1"}}),this.generateCronExpressionFromConfig(this.cronConfig);break;default:Nd({title:"Cron Scheduler",body:"Recurrence type should be one of the known types: Daily, Weekly,Monthly or Yearly",toast:{type:"critical"}},O(this))}}handleChange(e){if("frequency"===e&&0===Number(this.frequency))throw new Error("Frequency must be greater than 0");this.cronConfig[e]=this[e],this.generateCronExpressionFromConfig(this.cronConfig)}handleDuringChange(){"every_hour"===this.during?this.hours="*":"*"===this.hours&&(this.hours="0"),this.cronConfig.type!==Ld.MINUTES&&this.cronConfig.type!==Ld.HOURLY||(this.cronConfig.during=this.during,this.cronConfig.hours=this.hours),this.generateCronExpressionFromConfig(this.cronConfig)}handleCronConfigUpdate({detail:e}){this.cronConfig=Object.assign(Object.assign({},this.getBaseConfigFields()),e),this.generateCronExpressionFromConfig(this.cronConfig)}generateCronExpressionFromConfig(e){switch(e.type){case Ld.MINUTES:this.cron=function(e){const t="specific_hours"===e.during&&e.hours?e.hours:"*";return`${e.seconds} 0/${e.frequency} ${t} ? * *`}(e);break;case Ld.HOURLY:this.cron=function(e){return"specific_hours"===e.during&&e.hours&&"*"!==e.hours?`${e.seconds} ${e.minutes} ${e.hours} ? * *`:`${e.seconds} ${e.minutes} 0/${e.frequency} ? * *`}(e);break;case Ld.DAILY:this.cron=function(e,t=Ud){const i=e.weekType===Fd.WORK_WEEK?"?":`*${t(e.frequency)}`;return`${e.seconds} ${e.minutes} ${e.hours} ${i} * ${e.weekType===Fd.WORK_WEEK?"2-6":"?"}`}(e,Ud);break;case Ld.WEEKLY:this.cron=function(e){const t=[...e.selectedDays].join(",")||"*";return`${e.seconds} ${e.minutes} ${e.hours} ? * ${t}`}(e);break;case Ld.MONTHLY:this.cron=function(e,t=Ud){const{dateOrDay:i,minutes:o,hours:n,seconds:s,frequency:a}=e,r=t(a);return i.type===Md.DATE?`${s} ${o} ${n} ${i.dayDate} *${r} ?`:"-1"===i.weekNumber?`${s} ${o} ${n} ? *${r} ${i.day}L`:`${e.seconds} ${o} ${n} ? *${r} ${i.day}#${i.weekNumber}`}(e,Ud);break;case Ld.YEARLY:this.cron=function(e){const{dateOrDay:t,minutes:i,seconds:o,hours:n}=e;return t.type===Md.DATE?`${o} ${i} ${n} ${t.dayDate} ${t.month} ?`:"-1"===t.weekNumber?`${o} ${i} ${n} ? ${t.month} ${t.day}L`:`${o} ${i} ${n} ? ${t.month} ${t.day}#${t.weekNumber}`}(e);break;default:Nd({title:"Cron Scheduler",body:"Recurrence type should be one of the known types: Daily, Weekly,Monthly or Yearly",toast:{type:"critical"}},O(this))}this.value=this.cron,this.$emit("change")}setsFieldsFromCronEx(){this.cronConfig=function(e,t){if(!e)return;const i=e.split(" "),[o,n,s,a,r,l]=i;if("?"!==l&&"?"!==a)throw new Error("Support for specifying both a day-of-week AND a day-of-month parameter is not implemented");if(/^(0|\*)\/\d+$/.test(n))return Object.assign({seconds:o},t.buildConfigForMinutesRecurrence(n,s));if(/^(0|\*)\/\d+$/.test(s))return Object.assign({minutes:n,seconds:o},t.buildConfigForHourlyRecurrence(s));if("?"===a&&"*"===l)return Object.assign({minutes:n,seconds:o},t.buildConfigForHourlyRecurrence(s));if("2-6"===l||"?"===l&&("*"===a||a.startsWith("*")))return Object.assign({hours:s,minutes:n,seconds:o},t.buildConfigForDailyRecurrence(a,l));if(/^([1-7](,[1-7])*)$/.test(l)||"*"===l)return Object.assign({hours:s,minutes:n,seconds:o},t.buildConfigForWeeklyRecurrence(l));if(l.includes("L")||l.includes("#")||/^([1-9]|[12]\d|3[01])$/.test(a)&&"?"===l)return"*"==r||r.startsWith("*/")?Object.assign({hours:s,minutes:n,seconds:o},t.buildConfigForMonthlyRecurrence(a,r,l)):Object.assign({hours:s,minutes:n,seconds:o},t.buildConfigForYearlyRecurrence(a,r,l));throw new Error("Invalid Cron Expression")}(this.cron,this.getConfigs),this.recurrence=this.cronConfig.type,this.frequency=this.cronConfig.frequency;const e=this.cronConfig;"minutes"in e&&(this.minutes=e.minutes),e.type!==Ld.MINUTES&&e.type!==Ld.HOURLY||(this.during=e.during||"every_hour",e.hours&&(this.hours=e.hours)),this.seconds=e.seconds,e.type!==Ld.HOURLY&&e.type!==Ld.MINUTES&&(this.hours=e.hours)}}(0,C.Cg)([l.observable],wc.prototype,"recurrence",void 0),(0,C.Cg)([l.observable],wc.prototype,"cron",void 0),(0,C.Cg)([l.observable],wc.prototype,"cronConfig",void 0),(0,C.Cg)([l.observable],wc.prototype,"frequency",void 0),(0,C.Cg)([l.observable],wc.prototype,"during",void 0),(0,C.Cg)([l.volatile],wc.prototype,"duringOptions",null),(0,C.Cg)([l.observable],wc.prototype,"hours",void 0),(0,C.Cg)([l.observable],wc.prototype,"minutes",void 0),(0,C.Cg)([l.observable],wc.prototype,"seconds",void 0),(0,C.Cg)([l.volatile],wc.prototype,"frequencySuffix",null),(0,C.Cg)([l.volatile],wc.prototype,"frequencyList",null),(0,C.Cg)([l.volatile],wc.prototype,"hourOptions",null),(0,C.Cg)([l.volatile],wc.prototype,"selectedHours",null),(0,C.Cg)([(0,l.attr)({attribute:"min-minute-interval"})],wc.prototype,"minMinuteInterval",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"disable-tooltips"})],wc.prototype,"disableTooltips",void 0),(0,C.Cg)([l.volatile],wc.prototype,"isMinutesRecurrenceEnabled",null),(0,C.Cg)([l.volatile],wc.prototype,"isSpecificHours",null),(0,C.Cg)([l.volatile],wc.prototype,"isDailyFrequencyDisabled",null),(0,C.Cg)([l.attr],wc.prototype,"timezone",void 0);const Cc=void 0,xc={},$c=wc.compose(Object.assign({baseName:"scheduler-cron-builder",styles:Jd,template:yc,shadowOptions:Cc},xc)),Sc=l.css`
4135
4135
  /* Host */
4136
4136
  :host {
4137
4137
  display: flex;
@@ -4176,7 +4176,7 @@
4176
4176
  </template>
4177
4177
  `,kc=l.html`
4178
4178
  ${e=>Ec(O(e))}
4179
- `;class Oc extends s.FoundationElement{constructor(){super(...arguments),this.timezone="",this.value=this.timezone}timezoneChanged(){this.value=this.timezone,this.$emit("change")}connectedCallback(){super.connectedCallback(),this.getTimeZones()}getTimeZones(){return(0,C.sH)(this,void 0,void 0,function*(){const e=["Europe/London","America/New_York"];try{const t=yield this.connect.request("VALID_TIME_ZONE",{REQUEST:{}});if(!t.REPLY||!Array.isArray(t.REPLY))throw new Error("Invalid data returned for Timezones");this.timeZones=t.REPLY.map(e=>e.ZONE_ID).sort((t,i)=>e.includes(t)&&!e.includes(i)?-1:!e.includes(t)&&e.includes(i)?1:t.localeCompare(i))}catch(e){Nd({title:"Cron Scheduler",body:"Unable to fetch timezones data.",toast:{type:"critical"}},"rapid"),Ia.v.error(e)}})}}(0,C.Cg)([l.observable],Oc.prototype,"timezone",void 0),(0,C.Cg)([ii.dm],Oc.prototype,"connect",void 0),(0,C.Cg)([l.observable],Oc.prototype,"timeZones",void 0);const Tc=void 0,Ic={},Dc=Oc.compose(Object.assign({baseName:"scheduler-timezone",styles:Sc,template:kc,shadowOptions:Tc},Ic)),Rc=l.css`
4179
+ `;class Oc extends a.FoundationElement{constructor(){super(...arguments),this.timezone="",this.value=this.timezone}timezoneChanged(){this.value=this.timezone,this.$emit("change")}connectedCallback(){super.connectedCallback(),this.getTimeZones()}getTimeZones(){return(0,C.sH)(this,void 0,void 0,function*(){const e=["Europe/London","America/New_York"];try{const t=yield this.connect.request("VALID_TIME_ZONE",{REQUEST:{}});if(!t.REPLY||!Array.isArray(t.REPLY))throw new Error("Invalid data returned for Timezones");this.timeZones=t.REPLY.map(e=>e.ZONE_ID).sort((t,i)=>e.includes(t)&&!e.includes(i)?-1:!e.includes(t)&&e.includes(i)?1:t.localeCompare(i))}catch(e){Nd({title:"Cron Scheduler",body:"Unable to fetch timezones data.",toast:{type:"critical"}},"rapid"),Is.v.error(e)}})}}(0,C.Cg)([l.observable],Oc.prototype,"timezone",void 0),(0,C.Cg)([ii.dm],Oc.prototype,"connect",void 0),(0,C.Cg)([l.observable],Oc.prototype,"timeZones",void 0);const Tc=void 0,Ic={},Rc=Oc.compose(Object.assign({baseName:"scheduler-timezone",styles:Sc,template:kc,shadowOptions:Tc},Ic)),Ac=l.css`
4180
4180
  .search-bar-combobox {
4181
4181
  width: 100%;
4182
4182
  min-width: auto;
@@ -4269,12 +4269,12 @@
4269
4269
  .close-icon {
4270
4270
  color: var(--accent-fill-rest);
4271
4271
  }
4272
- `,Ac=(e="start")=>'\n<svg xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="http://www.w3.org/2000/svg" version="1.1" width="10px" height="10px">\n <g transform="matrix(1 0 0 1 -256 -14 )">\n <path class="cross-icon" fill="white" d="M 9.9265625 8.865937499999998 L 6.060625000000001 5 L 9.265625 1.795 L 9.9265625 1.1340624999999993 C 10.0240625 1.0365624999999996 10.0240625 0.8781249999999996 9.9265625 0.7806249999999992 L 9.219375 0.07343749999999982 C 9.121875 -0.024062500000000542 8.9634375 -0.024062500000000542 8.8659375 0.07343749999999982 L 5 3.9393750000000005 L 1.1340625 0.073125 C 1.0365625 -0.02437500000000037 0.8781250000000002 -0.02437500000000037 0.7806249999999999 0.073125 L 0.073125 0.7803125 C -0.024375000000000008 0.8778124999999998 -0.024375000000000008 1.0362499999999997 0.073125 1.13375 L 3.9393750000000005 5 L 0.073125 8.865937499999998 C -0.024375000000000008 8.9634375 -0.024375000000000008 9.121875 0.073125 9.219375000000001 L 0.7803125 9.9265625 C 0.8778125000000001 10.0240625 1.03625 10.0240625 1.13375 9.9265625 L 5 6.060625 L 8.205 9.265625 L 8.8659375 9.9265625 C 8.9634375 10.0240625 9.121875 10.0240625 9.219375 9.9265625 L 9.9265625 9.219375000000001 C 10.0240625 9.121875 10.0240625 8.9634375 9.9265625 8.865937499999998 Z " fill-rule="nonzero" fill="#c9c9c9" stroke="none" fill-opacity="0.8" transform="matrix(1 0 0 1 256 14 )"/>\n </g>\n</svg>\n',Nc=()=>'\n<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" width="30px" height="30px" class="bi bi-plus" viewBox="0 0 16 16">\n <path d="M8 4a.5.5 0 0 1 .5.5v3h3a.5.5 0 0 1 0 1h-3v3a.5.5 0 0 1-1 0v-3h-3a.5.5 0 0 1 0-1h3v-3A.5.5 0 0 1 8 4z"/>\n</svg>',Lc=e=>l.html`
4272
+ `,Dc=(e="start")=>'\n<svg xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="http://www.w3.org/2000/svg" version="1.1" width="10px" height="10px">\n <g transform="matrix(1 0 0 1 -256 -14 )">\n <path class="cross-icon" fill="white" d="M 9.9265625 8.865937499999998 L 6.060625000000001 5 L 9.265625 1.795 L 9.9265625 1.1340624999999993 C 10.0240625 1.0365624999999996 10.0240625 0.8781249999999996 9.9265625 0.7806249999999992 L 9.219375 0.07343749999999982 C 9.121875 -0.024062500000000542 8.9634375 -0.024062500000000542 8.8659375 0.07343749999999982 L 5 3.9393750000000005 L 1.1340625 0.073125 C 1.0365625 -0.02437500000000037 0.8781250000000002 -0.02437500000000037 0.7806249999999999 0.073125 L 0.073125 0.7803125 C -0.024375000000000008 0.8778124999999998 -0.024375000000000008 1.0362499999999997 0.073125 1.13375 L 3.9393750000000005 5 L 0.073125 8.865937499999998 C -0.024375000000000008 8.9634375 -0.024375000000000008 9.121875 0.073125 9.219375000000001 L 0.7803125 9.9265625 C 0.8778125000000001 10.0240625 1.03625 10.0240625 1.13375 9.9265625 L 5 6.060625 L 8.205 9.265625 L 8.8659375 9.9265625 C 8.9634375 10.0240625 9.121875 10.0240625 9.219375 9.9265625 L 9.9265625 9.219375000000001 C 10.0240625 9.121875 10.0240625 8.9634375 9.9265625 8.865937499999998 Z " fill-rule="nonzero" fill="#c9c9c9" stroke="none" fill-opacity="0.8" transform="matrix(1 0 0 1 256 14 )"/>\n </g>\n</svg>\n',Nc=()=>'\n<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" width="30px" height="30px" class="bi bi-plus" viewBox="0 0 16 16">\n <path d="M8 4a.5.5 0 0 1 .5.5v3h3a.5.5 0 0 1 0 1h-3v3a.5.5 0 0 1-1 0v-3h-3a.5.5 0 0 1 0-1h3v-3A.5.5 0 0 1 8 4z"/>\n</svg>',Lc=e=>l.html`
4273
4273
 
4274
4274
  <label part="label" for="control" data-test-id="label" class=${e=>{var t;return(0,x.x)("label",["label-hidden",!(null===(t=e.defaultSlottedNodes)||void 0===t?void 0:t.length)])}}
4275
4275
  >
4276
4276
  <slot
4277
- ${(0,l.slotted)({property:"defaultSlottedNodes",filter:s.whitespaceFilter})}
4277
+ ${(0,l.slotted)({property:"defaultSlottedNodes",filter:a.whitespaceFilter})}
4278
4278
  ></slot>
4279
4279
  </label>
4280
4280
 
@@ -4350,7 +4350,7 @@
4350
4350
  </${e}-tooltip>
4351
4351
  `,Fc=l.html`
4352
4352
  ${e=>Lc(O(e))}
4353
- `,Mc=10,_c=3,Hc=1,Pc=(e,t)=>(new W.b).withExpression((new B.K).withField(e).withValue(t).withSerialiser(U.n.containsIgnoreCase).build()).build();class zc extends s.FoundationElement{constructor(){super(...arguments),this.searchTerm="",this.appearance="neutral",this.minlength=_c,this.position=Nt.BELOW,this.placeholder="Start typing to search",this.selectedOptions=[],this.normalizeDelimiter=e=>e.trim().replace(/\t|\r\n|\n|\r|,/g," "),this.addOrReplaceSelectedText=(e,t,i)=>(null==t?void 0:t.length)>0?e.replace(t,i):e.concat(i)}clear(){this.selectedOptions=[],this.combobox.currentValue="",this.$emit("selectionChange",[])}clearSearch(){this.clear()}inputdeleted(){this.selectedOptions.length>0&&this.unselectOption(this.selectedOptions[this.selectedOptions.length-1])}changeHandler(){const e=[];this.combobox.selectedOptions.forEach(t=>{var i,o,n;const a=t.value,s=this.searchTerm.trim();e.push({field:a,term:s,label:(null===(i=this.options.find(e=>e.field===a))||void 0===i?void 0:i.label(s))||t.text,createCriteria:null===(o=this.options.find(e=>e.field===a))||void 0===o?void 0:o.createCriteria,resourceType:null===(n=this.options.find(e=>e.field===a))||void 0===n?void 0:n.resourceType})}),this.selectedOptions=[...this.selectedOptions,...e],this.selectedOptions=this.selectedOptions.filter((e,t,i)=>t===i.findIndex(t=>e.field===t.field&&e.term===t.term)),this.combobox.value="",this.combobox.open=!1,this.$emit("selectionChange",this.selectedOptions),l.DOM.queueUpdate(()=>{setTimeout(()=>{this.selectedOptionsDiv.scrollTo(this.selectedOptionsDiv.scrollWidth,0)},Mc)})}pasteHandler(e){var t;this.loading=!0;const i=e.clipboardData.getData("text/plain"),o=this.normalizeDelimiter(i),n=null===(t=window.getSelection())||void 0===t?void 0:t.toString(),a=this.addOrReplaceSelectedText(this.combobox.value,n,o);(null==a?void 0:a.length)>=this.minlength&&(this.combobox.value=a,this.searchTerm=a,this.combobox.open=!0),this.loading=!1}hasSelectedOption(e,t){return this.selectedOptions.some(i=>i.term===e&&i.field===t)}unselectOption(e){this.selectedOptions=this.selectedOptions.filter(t=>t!==e),this.$emit("selectionChange",this.selectedOptions)}inputHandler(){return(0,C.sH)(this,void 0,void 0,function*(){this.loading=!0,this.searchTerm=this.combobox.value,this.combobox.value.length>=this.minlength&&this.filterSelectedOptions(this.combobox.value),this.loading=!1})}filterSelectedOptions(e){this.filteredOptions=this.options.filter(t=>!this.selectedOptions.find(i=>i.field===t.field&&i.term.trim()===e.trim()))}}(0,C.Cg)([l.observable],zc.prototype,"defaultSlottedNodes",void 0),(0,C.Cg)([l.observable],zc.prototype,"options",void 0),(0,C.Cg)([l.observable],zc.prototype,"searchTerm",void 0),(0,C.Cg)([l.attr],zc.prototype,"appearance",void 0),(0,C.Cg)([l.attr],zc.prototype,"minlength",void 0),(0,C.Cg)([l.attr],zc.prototype,"position",void 0),(0,C.Cg)([l.attr],zc.prototype,"placeholder",void 0),(0,C.Cg)([l.attr],zc.prototype,"disabled",void 0),(0,C.Cg)([l.observable],zc.prototype,"loading",void 0),(0,C.Cg)([l.observable],zc.prototype,"selectedOptions",void 0),(0,C.Cg)([l.observable],zc.prototype,"filteredOptions",void 0);const Uc=void 0,Bc={},Wc=zc.compose(Object.assign({baseName:"search-bar",template:Fc,styles:Rc,shadowOptions:Uc},Bc)),Gc=(e,t)=>l.css`
4353
+ `,Mc=10,_c=3,Hc=1,Pc=(e,t)=>(new G.b).withExpression((new W.K).withField(e).withValue(t).withSerialiser(U.n.containsIgnoreCase).build()).build();class zc extends a.FoundationElement{constructor(){super(...arguments),this.searchTerm="",this.appearance="neutral",this.minlength=_c,this.position=Nt.BELOW,this.placeholder="Start typing to search",this.selectedOptions=[],this.normalizeDelimiter=e=>e.trim().replace(/\t|\r\n|\n|\r|,/g," "),this.addOrReplaceSelectedText=(e,t,i)=>(null==t?void 0:t.length)>0?e.replace(t,i):e.concat(i)}clear(){this.selectedOptions=[],this.combobox.currentValue="",this.$emit("selectionChange",[])}clearSearch(){this.clear()}inputdeleted(){this.selectedOptions.length>0&&this.unselectOption(this.selectedOptions[this.selectedOptions.length-1])}changeHandler(){const e=[];this.combobox.selectedOptions.forEach(t=>{var i,o,n;const s=t.value,a=this.searchTerm.trim();e.push({field:s,term:a,label:(null===(i=this.options.find(e=>e.field===s))||void 0===i?void 0:i.label(a))||t.text,createCriteria:null===(o=this.options.find(e=>e.field===s))||void 0===o?void 0:o.createCriteria,resourceType:null===(n=this.options.find(e=>e.field===s))||void 0===n?void 0:n.resourceType})}),this.selectedOptions=[...this.selectedOptions,...e],this.selectedOptions=this.selectedOptions.filter((e,t,i)=>t===i.findIndex(t=>e.field===t.field&&e.term===t.term)),this.combobox.value="",this.combobox.open=!1,this.$emit("selectionChange",this.selectedOptions),l.DOM.queueUpdate(()=>{setTimeout(()=>{this.selectedOptionsDiv.scrollTo(this.selectedOptionsDiv.scrollWidth,0)},Mc)})}pasteHandler(e){var t;this.loading=!0;const i=e.clipboardData.getData("text/plain"),o=this.normalizeDelimiter(i),n=null===(t=window.getSelection())||void 0===t?void 0:t.toString(),s=this.addOrReplaceSelectedText(this.combobox.value,n,o);(null==s?void 0:s.length)>=this.minlength&&(this.combobox.value=s,this.searchTerm=s,this.combobox.open=!0),this.loading=!1}hasSelectedOption(e,t){return this.selectedOptions.some(i=>i.term===e&&i.field===t)}unselectOption(e){this.selectedOptions=this.selectedOptions.filter(t=>t!==e),this.$emit("selectionChange",this.selectedOptions)}inputHandler(){return(0,C.sH)(this,void 0,void 0,function*(){this.loading=!0,this.searchTerm=this.combobox.value,this.combobox.value.length>=this.minlength&&this.filterSelectedOptions(this.combobox.value),this.loading=!1})}filterSelectedOptions(e){this.filteredOptions=this.options.filter(t=>!this.selectedOptions.find(i=>i.field===t.field&&i.term.trim()===e.trim()))}}(0,C.Cg)([l.observable],zc.prototype,"defaultSlottedNodes",void 0),(0,C.Cg)([l.observable],zc.prototype,"options",void 0),(0,C.Cg)([l.observable],zc.prototype,"searchTerm",void 0),(0,C.Cg)([l.attr],zc.prototype,"appearance",void 0),(0,C.Cg)([l.attr],zc.prototype,"minlength",void 0),(0,C.Cg)([l.attr],zc.prototype,"position",void 0),(0,C.Cg)([l.attr],zc.prototype,"placeholder",void 0),(0,C.Cg)([l.attr],zc.prototype,"disabled",void 0),(0,C.Cg)([l.observable],zc.prototype,"loading",void 0),(0,C.Cg)([l.observable],zc.prototype,"selectedOptions",void 0),(0,C.Cg)([l.observable],zc.prototype,"filteredOptions",void 0);const Uc=void 0,Wc={},Gc=zc.compose(Object.assign({baseName:"search-bar",template:Fc,styles:Ac,shadowOptions:Uc},Wc)),Bc=(e,t)=>l.css`
4354
4354
  ${ci(e,t)}
4355
4355
  .control {
4356
4356
  width: auto;
@@ -4372,7 +4372,7 @@
4372
4372
  min-width: 150px;
4373
4373
  max-width: 169px;
4374
4374
  }
4375
- `,jc=(e,t)=>l.html`
4375
+ `,Vc=(e,t)=>l.html`
4376
4376
  <template
4377
4377
  aria-disabled="${e=>e.ariaDisabled}"
4378
4378
  autocomplete="${e=>e.autocomplete}"
@@ -4408,7 +4408,7 @@
4408
4408
  />
4409
4409
  </slot>
4410
4410
  </div>
4411
- ${(0,s.endSlotTemplate)(e,t)}
4411
+ ${(0,a.endSlotTemplate)(e,t)}
4412
4412
  <div
4413
4413
  class="listbox"
4414
4414
  id="${e=>e.listboxId}"
@@ -4420,11 +4420,11 @@
4420
4420
  data-test-id="listbox"
4421
4421
  >
4422
4422
  <slot
4423
- ${(0,l.slotted)({filter:s.Listbox.slottedOptionFilter,flatten:!0,property:"slottedOptions"})}
4423
+ ${(0,l.slotted)({filter:a.Listbox.slottedOptionFilter,flatten:!0,property:"slottedOptions"})}
4424
4424
  ></slot>
4425
4425
  </div>
4426
4426
  </template>
4427
- `;class Vc extends r.Combobox{constructor(){super(...arguments),this.minlength=Hc,this.previousLength=-1,this.changeListener=e=>{this.previousLength=0}}connectedCallback(){super.connectedCallback(),this.addEventListener("change",this.changeListener)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("change",this.changeListener)}clickHandler(e){if(!this.disabled){if(this.open){const t=e.target.closest("option,[role=option]");if(!t||t.disabled)return;this.selectedOptions=[t],this.control.value=t.text,this.value=this.control.value,this.$emit("change")}this.control.focus()}}keyupHandler(e){switch(e.key){case"Backspace":case"Delete":this.previousLength<0?this.$emit("inputdeleted"):this.previousLength=this.previousLength-1;break;case"Enter":if(this.open&&-1!==this.selectedIndex){const e=this.slottedOptions[0];this.selectedOptions=[e],this.control.value=e.text,this.value=this.control.value,this.$emit("change")}}super.keyupHandler(e)}keydownHandler(e){switch(e.key){case"ArrowUp":case"ArrowDown":return this.control.value.length<this.minlength?void 0:super.keydownHandler(e);case"Enter":return-1!==this.selectedIndex&&super.keydownHandler(e);case"Tab":if(!this.open)return!0;e.shiftKey?this.selectPreviousOption():this.selectNextOption();break;default:return super.keydownHandler(e)}}inputHandler(e){this.control.value.length>=this.minlength?this.open=!0:(e.stopImmediatePropagation(),this.open=!1),this.value=this.control.value,this.previousLength=this.control.value.length}openChanged(){if(this.open)return this.ariaControls=this.listboxId,this.ariaExpanded="true",this.setPositioning(),void this.focusAndScrollOptionIntoView();this.ariaControls="",this.ariaExpanded="false"}}(0,C.Cg)([l.attr],Vc.prototype,"minlength",void 0);const Yc={delegatesFocus:!0,mode:"open"},qc={},Kc=Vc.compose(Object.assign({baseName:"search-bar-combobox",template:jc,styles:Gc,shadowOptions:Yc},qc)),Xc=l.css`
4427
+ `;class jc extends r.Combobox{constructor(){super(...arguments),this.minlength=Hc,this.previousLength=-1,this.changeListener=e=>{this.previousLength=0}}connectedCallback(){super.connectedCallback(),this.addEventListener("change",this.changeListener)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("change",this.changeListener)}clickHandler(e){if(!this.disabled){if(this.open){const t=e.target.closest("option,[role=option]");if(!t||t.disabled)return;this.selectedOptions=[t],this.control.value=t.text,this.value=this.control.value,this.$emit("change")}this.control.focus()}}keyupHandler(e){switch(e.key){case"Backspace":case"Delete":this.previousLength<0?this.$emit("inputdeleted"):this.previousLength=this.previousLength-1;break;case"Enter":if(this.open&&-1!==this.selectedIndex){const e=this.slottedOptions[0];this.selectedOptions=[e],this.control.value=e.text,this.value=this.control.value,this.$emit("change")}}super.keyupHandler(e)}keydownHandler(e){switch(e.key){case"ArrowUp":case"ArrowDown":return this.control.value.length<this.minlength?void 0:super.keydownHandler(e);case"Enter":return-1!==this.selectedIndex&&super.keydownHandler(e);case"Tab":if(!this.open)return!0;e.shiftKey?this.selectPreviousOption():this.selectNextOption();break;default:return super.keydownHandler(e)}}inputHandler(e){this.control.value.length>=this.minlength?this.open=!0:(e.stopImmediatePropagation(),this.open=!1),this.value=this.control.value,this.previousLength=this.control.value.length}openChanged(){if(this.open)return this.ariaControls=this.listboxId,this.ariaExpanded="true",this.setPositioning(),void this.focusAndScrollOptionIntoView();this.ariaControls="",this.ariaExpanded="false"}}(0,C.Cg)([l.attr],jc.prototype,"minlength",void 0);const Yc={delegatesFocus:!0,mode:"open"},qc={},Kc=jc.compose(Object.assign({baseName:"search-bar-combobox",template:Vc,styles:Bc,shadowOptions:Yc},qc)),Xc=l.css`
4428
4428
  :host {
4429
4429
  display: block;
4430
4430
  width: 100%;
@@ -4662,7 +4662,7 @@
4662
4662
  </div>
4663
4663
  </template>
4664
4664
  `;var t}}
4665
- `,Jc=(0,Ke.createLogger)("SectionNavigator"),Zc="section-navigator",eu={setState:`${Zc}-set-state`,setStates:`${Zc}-set-states`,clearState:`${Zc}-clear-state`,clearAllStates:`${Zc}-clear-all-states`},tu={active:"Active",inactive:"Inactive",pending:"Pending",disabled:"Disabled",error:"Error",completed:"Completed"},iu={active:{name:"circle-dot",variant:"solid"},inactive:{name:"times-circle",variant:"regular"},pending:{name:"clock",variant:"solid"},disabled:{name:"ban",variant:"solid"},error:{name:"times",variant:"solid"},completed:{name:"check",variant:"solid"}};class ou extends s.FoundationElement{constructor(){super(...arguments),this.sections=[],this.scrollBehavior="top",this.stateTooltips=tu,this.stateIcons=iu,this.disableAutoScrollDetection=!1,this.userClickedSection=!1,this.isUserScrolling=!1,this.sectionItems=[],this.activeSection=""}sectionsChanged(){this.setSectionItems(),this.setActiveSection(),this.updateScrollDetection()}disableAutoScrollDetectionChanged(){this.updateScrollDetection()}scrollBehaviorChanged(){this.updateSpacer()}connectedCallback(){super.connectedCallback(),this.setSectionItems(),this.setActiveSection(),this.updateSpacer(),this.setupStateEventListeners(),this.updateScrollDetection()}setSectionItems(){if(!Array.isArray(this.sections))return Jc.warn("Sections must be an array"),void(this.sectionItems=[]);this.sectionItems=this.sections}setActiveSection(){this.sectionItems.length>0&&!this.activeSection&&(this.activeSection=this.sectionItems[0].name)}handleSectionClick(e){this.activeSection=e,this.userClickedSection=!0,this.scrollToSection(e)}updateSpacer(){var e;if(this.sectionContent){if(null===(e=this.spacerElement)||void 0===e||e.remove(),this.spacerElement=void 0,"top"===this.scrollBehavior)try{const e=this.sectionContent.clientHeight,t=this.sectionContent.querySelector(".content-section:last-child");if(t){const i=t.offsetHeight,o=20,n=Math.max(0,e-i-o);this.spacerElement=document.createElement("div"),this.spacerElement.className="scroll-spacer",this.spacerElement.style.height=`${n}px`,this.spacerElement.style.pointerEvents="none",this.sectionContent.appendChild(this.spacerElement)}}catch(e){Jc.error("Error updating spacer:",e)}}else Jc.warn("Section content element not found")}scrollToSection(e){if(this.sectionContent)try{const t=this.sectionContent.querySelector(`[data-section="${e}"]`);if(!t)return void Jc.warn(`Section "${e}" not found`);const i=t.offsetTop-this.sectionContent.offsetTop;this.sectionContent.scrollTo({top:i,behavior:"smooth"}),this.setupScrollEndDetection()}catch(e){Jc.error("Error scrolling to section:",e)}else Jc.warn("Section content not available")}updateScrollDetection(){this.cleanupScrollDetection(),!this.disableAutoScrollDetection&&this.sectionContent&&this.setupScrollDetection()}setupScrollDetection(){if(this.sectionContent)try{this.scrollCheckHandler=()=>{this.isUserScrolling&&!this.userClickedSection&&(this.scrollDebounceTimeout&&clearTimeout(this.scrollDebounceTimeout),this.scrollDebounceTimeout=window.setTimeout(()=>{this.updateActiveSectionBasedOnScrollPosition()},ou.SCROLL_DEBOUNCE_TIMEOUT))},this.sectionContent.addEventListener("scroll",this.scrollCheckHandler,{passive:!0});const e=()=>{this.isUserScrolling=!0},t=()=>{this.isUserScrolling=!1,this.userClickedSection=!1};let i;this.sectionContent.addEventListener("wheel",e,{passive:!0}),this.sectionContent.addEventListener("touchstart",e,{passive:!0}),this.sectionContent.addEventListener("mousedown",e,{passive:!0}),this.sectionContent.addEventListener("scrollend",t,{passive:!0}),this.sectionContent.addEventListener("scroll",()=>{clearTimeout(i),i=window.setTimeout(t,ou.SCROLL_END_TIMEOUT)},{passive:!0})}catch(e){Jc.error("Error setting up scroll detection:",e)}else Jc.warn("Section content not available for scroll detection")}updateActiveSectionBasedOnScrollPosition(){if(!this.sectionContent)return;const e=this.sectionContent.scrollTop+this.sectionContent.clientHeight/2;let t=null,i=1/0;this.sectionItems.forEach(o=>{const n=this.sectionContent.querySelector(`[data-section="${o.name}"]`);if(n){const a=n.offsetTop+n.clientHeight/2,s=Math.abs(a-e);s<i&&(i=s,t=o.name)}}),t&&t!==this.activeSection&&(this.activeSection=t)}setupScrollEndDetection(){this.sectionContent&&(this.cleanupScrollEndDetection(),this.scrollEndHandler=()=>{this.userClickedSection=!1,this.cleanupScrollEndDetection()},this.sectionContent.addEventListener("scroll",this.scrollEndHandler,{passive:!0}))}cleanupScrollEndDetection(){this.scrollEndHandler&&this.sectionContent&&(this.sectionContent.removeEventListener("scroll",this.scrollEndHandler),this.scrollEndHandler=void 0)}cleanupScrollDetection(){this.scrollCheckHandler&&this.sectionContent&&(this.sectionContent.removeEventListener("scroll",this.scrollCheckHandler),this.scrollCheckHandler=void 0),this.scrollDebounceTimeout&&(clearTimeout(this.scrollDebounceTimeout),this.scrollDebounceTimeout=void 0),this.cleanupScrollEndDetection()}setupStateEventListeners(){this.sectionContent?(this.handleSetStateRef=e=>{try{const{sectionName:t,stateName:i}=e.detail;this.addState(t,i)}catch(e){Jc.error("Error handling set-state event:",e)}},this.handleSetStatesRef=e=>{try{const{sectionName:t,stateNames:i}=e.detail;this.addStates(t,i)}catch(e){Jc.error("Error handling set-states event:",e)}},this.handleClearStateRef=e=>{try{const{sectionName:t,stateName:i}=e.detail;this.clearState(t,i)}catch(e){Jc.error("Error handling clear-state event:",e)}},this.handleClearAllStatesRef=e=>{try{const{sectionName:t}=e.detail;t?this.clearAllStates(t):this.clearAllStatesInAllSections()}catch(e){Jc.error("Error handling clear-all-states event:",e)}},this.handleGenericStateEventRef=e=>{try{const t=e.type,i=e.detail;if(null==i?void 0:i.sectionName)return;const o=e.target.closest("[data-section]");let n=null==o?void 0:o.getAttribute("data-section");if(!n){const t=e.target.closest("[slot]");n=(null==t?void 0:t.getAttribute("slot"))||this.activeSection}n||(n=this.activeSection),e.stopPropagation(),e.preventDefault();const a=Object.assign(Object.assign({},i),{sectionName:n}),s=new CustomEvent(t,{detail:a,bubbles:!0,cancelable:!0});this.dispatchEvent(s)}catch(e){Jc.error("Error handling generic state event:",e)}},this.addEventListener(eu.setState,this.handleSetStateRef),this.addEventListener(eu.setStates,this.handleSetStatesRef),this.addEventListener(eu.clearState,this.handleClearStateRef),this.addEventListener(eu.clearAllStates,this.handleClearAllStatesRef),this.sectionContent.addEventListener(eu.setState,this.handleGenericStateEventRef,!0),this.sectionContent.addEventListener(eu.setStates,this.handleGenericStateEventRef,!0),this.sectionContent.addEventListener(eu.clearState,this.handleGenericStateEventRef,!0),this.sectionContent.addEventListener(eu.clearAllStates,this.handleGenericStateEventRef,!0)):Jc.warn("Section content not available for event listeners")}updateSectionStates(e,t){const i=this.sectionItems.findIndex(t=>t.name===e);if(-1!==i){const e=Object.assign(Object.assign({},this.sectionItems[i]),{states:t});this.sectionItems=[...this.sectionItems.slice(0,i),e,...this.sectionItems.slice(i+1)]}}addState(e,t){if(!e||!t)return void Jc.warn("Section name and state name are required");const i=this.sectionItems.findIndex(t=>t.name===e);if(-1===i)return void Jc.warn(`Section "${e}" not found`);const o=this.sectionItems[i].states||[];if(!o.includes(t)){const i=[...o,t];this.updateSectionStates(e,i)}}addStates(e,t){if(!e||!Array.isArray(t))return void Jc.warn("Section name and state names array are required");const i=this.sectionItems.findIndex(t=>t.name===e);if(-1===i)return void Jc.warn(`Section "${e}" not found`);const o=[...this.sectionItems[i].states||[]];t.forEach(e=>{o.includes(e)||o.push(e)}),this.updateSectionStates(e,o)}clearState(e,t){if(!e||!t)return void Jc.warn("Section name and state name are required");const i=this.sectionItems.findIndex(t=>t.name===e);if(-1===i)return void Jc.warn(`Section "${e}" not found`);const o=this.sectionItems[i].states||[],n=o.indexOf(t);if(n>-1){const t=o.filter((e,t)=>t!==n);this.updateSectionStates(e,t)}}clearAllStates(e){if(!e)return void Jc.warn("Section name is required");-1!==this.sectionItems.findIndex(t=>t.name===e)?this.updateSectionStates(e,[]):Jc.warn(`Section "${e}" not found`)}clearAllStatesInAllSections(){this.sectionItems=this.sectionItems.map(e=>Object.assign(Object.assign({},e),{states:[]}))}getStateTooltip(e){return e?this.stateTooltips[e]||"":(Jc.warn("State name is required"),"")}getSectionStateClass(e){if(!e)return Jc.warn("Section is required"),"state-none";const t=e.states||[];if(0===t.length)return"state-none";if(t.length>1)return"state-multiple";return`state-${t[0]}`}getStateIcon(e){return e?this.stateIcons[e]||iu[e]:(Jc.warn("State name is required"),iu.active)}disconnectedCallback(){var e;super.disconnectedCallback(),this.handleSetStateRef&&this.removeEventListener(eu.setState,this.handleSetStateRef),this.handleSetStatesRef&&this.removeEventListener(eu.setStates,this.handleSetStatesRef),this.handleClearStateRef&&this.removeEventListener(eu.clearState,this.handleClearStateRef),this.handleClearAllStatesRef&&this.removeEventListener(eu.clearAllStates,this.handleClearAllStatesRef),this.handleGenericStateEventRef&&this.sectionContent&&(this.sectionContent.removeEventListener(eu.setState,this.handleGenericStateEventRef,!0),this.sectionContent.removeEventListener(eu.setStates,this.handleGenericStateEventRef,!0),this.sectionContent.removeEventListener(eu.clearState,this.handleGenericStateEventRef,!0),this.sectionContent.removeEventListener(eu.clearAllStates,this.handleGenericStateEventRef,!0)),this.cleanupScrollDetection(),null===(e=this.spacerElement)||void 0===e||e.remove(),this.spacerElement=void 0}}ou.SCROLL_END_TIMEOUT=150,ou.SCROLL_DEBOUNCE_TIMEOUT=100,(0,C.Cg)([l.observable],ou.prototype,"sections",void 0),(0,C.Cg)([(0,l.attr)({attribute:"scroll-behavior"})],ou.prototype,"scrollBehavior",void 0),(0,C.Cg)([(0,l.attr)({attribute:"state-tooltips"})],ou.prototype,"stateTooltips",void 0),(0,C.Cg)([(0,l.attr)({attribute:"state-icons"})],ou.prototype,"stateIcons",void 0),(0,C.Cg)([(0,l.attr)({attribute:"disable-auto-scroll-detection",mode:"boolean"})],ou.prototype,"disableAutoScrollDetection",void 0),(0,C.Cg)([l.observable],ou.prototype,"sectionItems",void 0),(0,C.Cg)([l.observable],ou.prototype,"activeSection",void 0);const nu={mode:"open"},au={},su=ou.compose(Object.assign({baseName:"foundation-section-navigator",template:Qc,styles:Xc,shadowOptions:nu},au)),ru=(e,t)=>l.css`
4665
+ `,Jc=(0,Ke.createLogger)("SectionNavigator"),Zc="section-navigator",eu={setState:`${Zc}-set-state`,setStates:`${Zc}-set-states`,clearState:`${Zc}-clear-state`,clearAllStates:`${Zc}-clear-all-states`},tu={active:"Active",inactive:"Inactive",pending:"Pending",disabled:"Disabled",error:"Error",completed:"Completed"},iu={active:{name:"circle-dot",variant:"solid"},inactive:{name:"times-circle",variant:"regular"},pending:{name:"clock",variant:"solid"},disabled:{name:"ban",variant:"solid"},error:{name:"times",variant:"solid"},completed:{name:"check",variant:"solid"}};class ou extends a.FoundationElement{constructor(){super(...arguments),this.sections=[],this.scrollBehavior="top",this.stateTooltips=tu,this.stateIcons=iu,this.disableAutoScrollDetection=!1,this.userClickedSection=!1,this.isUserScrolling=!1,this.sectionItems=[],this.activeSection=""}sectionsChanged(){this.setSectionItems(),this.setActiveSection(),this.updateScrollDetection()}disableAutoScrollDetectionChanged(){this.updateScrollDetection()}scrollBehaviorChanged(){this.updateSpacer()}connectedCallback(){super.connectedCallback(),this.setSectionItems(),this.setActiveSection(),this.updateSpacer(),this.setupStateEventListeners(),this.updateScrollDetection()}setSectionItems(){if(!Array.isArray(this.sections))return Jc.warn("Sections must be an array"),void(this.sectionItems=[]);this.sectionItems=this.sections}setActiveSection(){this.sectionItems.length>0&&!this.activeSection&&(this.activeSection=this.sectionItems[0].name)}handleSectionClick(e){this.activeSection=e,this.userClickedSection=!0,this.scrollToSection(e)}updateSpacer(){var e;if(this.sectionContent){if(null===(e=this.spacerElement)||void 0===e||e.remove(),this.spacerElement=void 0,"top"===this.scrollBehavior)try{const e=this.sectionContent.clientHeight,t=this.sectionContent.querySelector(".content-section:last-child");if(t){const i=t.offsetHeight,o=20,n=Math.max(0,e-i-o);this.spacerElement=document.createElement("div"),this.spacerElement.className="scroll-spacer",this.spacerElement.style.height=`${n}px`,this.spacerElement.style.pointerEvents="none",this.sectionContent.appendChild(this.spacerElement)}}catch(e){Jc.error("Error updating spacer:",e)}}else Jc.warn("Section content element not found")}scrollToSection(e){if(this.sectionContent)try{const t=this.sectionContent.querySelector(`[data-section="${e}"]`);if(!t)return void Jc.warn(`Section "${e}" not found`);const i=t.offsetTop-this.sectionContent.offsetTop;this.sectionContent.scrollTo({top:i,behavior:"smooth"}),this.setupScrollEndDetection()}catch(e){Jc.error("Error scrolling to section:",e)}else Jc.warn("Section content not available")}updateScrollDetection(){this.cleanupScrollDetection(),!this.disableAutoScrollDetection&&this.sectionContent&&this.setupScrollDetection()}setupScrollDetection(){if(this.sectionContent)try{this.scrollCheckHandler=()=>{this.isUserScrolling&&!this.userClickedSection&&(this.scrollDebounceTimeout&&clearTimeout(this.scrollDebounceTimeout),this.scrollDebounceTimeout=window.setTimeout(()=>{this.updateActiveSectionBasedOnScrollPosition()},ou.SCROLL_DEBOUNCE_TIMEOUT))},this.sectionContent.addEventListener("scroll",this.scrollCheckHandler,{passive:!0});const e=()=>{this.isUserScrolling=!0},t=()=>{this.isUserScrolling=!1,this.userClickedSection=!1};let i;this.sectionContent.addEventListener("wheel",e,{passive:!0}),this.sectionContent.addEventListener("touchstart",e,{passive:!0}),this.sectionContent.addEventListener("mousedown",e,{passive:!0}),this.sectionContent.addEventListener("scrollend",t,{passive:!0}),this.sectionContent.addEventListener("scroll",()=>{clearTimeout(i),i=window.setTimeout(t,ou.SCROLL_END_TIMEOUT)},{passive:!0})}catch(e){Jc.error("Error setting up scroll detection:",e)}else Jc.warn("Section content not available for scroll detection")}updateActiveSectionBasedOnScrollPosition(){if(!this.sectionContent)return;const e=this.sectionContent.scrollTop+this.sectionContent.clientHeight/2;let t=null,i=1/0;this.sectionItems.forEach(o=>{const n=this.sectionContent.querySelector(`[data-section="${o.name}"]`);if(n){const s=n.offsetTop+n.clientHeight/2,a=Math.abs(s-e);a<i&&(i=a,t=o.name)}}),t&&t!==this.activeSection&&(this.activeSection=t)}setupScrollEndDetection(){this.sectionContent&&(this.cleanupScrollEndDetection(),this.scrollEndHandler=()=>{this.userClickedSection=!1,this.cleanupScrollEndDetection()},this.sectionContent.addEventListener("scroll",this.scrollEndHandler,{passive:!0}))}cleanupScrollEndDetection(){this.scrollEndHandler&&this.sectionContent&&(this.sectionContent.removeEventListener("scroll",this.scrollEndHandler),this.scrollEndHandler=void 0)}cleanupScrollDetection(){this.scrollCheckHandler&&this.sectionContent&&(this.sectionContent.removeEventListener("scroll",this.scrollCheckHandler),this.scrollCheckHandler=void 0),this.scrollDebounceTimeout&&(clearTimeout(this.scrollDebounceTimeout),this.scrollDebounceTimeout=void 0),this.cleanupScrollEndDetection()}setupStateEventListeners(){this.sectionContent?(this.handleSetStateRef=e=>{try{const{sectionName:t,stateName:i}=e.detail;this.addState(t,i)}catch(e){Jc.error("Error handling set-state event:",e)}},this.handleSetStatesRef=e=>{try{const{sectionName:t,stateNames:i}=e.detail;this.addStates(t,i)}catch(e){Jc.error("Error handling set-states event:",e)}},this.handleClearStateRef=e=>{try{const{sectionName:t,stateName:i}=e.detail;this.clearState(t,i)}catch(e){Jc.error("Error handling clear-state event:",e)}},this.handleClearAllStatesRef=e=>{try{const{sectionName:t}=e.detail;t?this.clearAllStates(t):this.clearAllStatesInAllSections()}catch(e){Jc.error("Error handling clear-all-states event:",e)}},this.handleGenericStateEventRef=e=>{try{const t=e.type,i=e.detail;if(null==i?void 0:i.sectionName)return;const o=e.target.closest("[data-section]");let n=null==o?void 0:o.getAttribute("data-section");if(!n){const t=e.target.closest("[slot]");n=(null==t?void 0:t.getAttribute("slot"))||this.activeSection}n||(n=this.activeSection),e.stopPropagation(),e.preventDefault();const s=Object.assign(Object.assign({},i),{sectionName:n}),a=new CustomEvent(t,{detail:s,bubbles:!0,cancelable:!0});this.dispatchEvent(a)}catch(e){Jc.error("Error handling generic state event:",e)}},this.addEventListener(eu.setState,this.handleSetStateRef),this.addEventListener(eu.setStates,this.handleSetStatesRef),this.addEventListener(eu.clearState,this.handleClearStateRef),this.addEventListener(eu.clearAllStates,this.handleClearAllStatesRef),this.sectionContent.addEventListener(eu.setState,this.handleGenericStateEventRef,!0),this.sectionContent.addEventListener(eu.setStates,this.handleGenericStateEventRef,!0),this.sectionContent.addEventListener(eu.clearState,this.handleGenericStateEventRef,!0),this.sectionContent.addEventListener(eu.clearAllStates,this.handleGenericStateEventRef,!0)):Jc.warn("Section content not available for event listeners")}updateSectionStates(e,t){const i=this.sectionItems.findIndex(t=>t.name===e);if(-1!==i){const e=Object.assign(Object.assign({},this.sectionItems[i]),{states:t});this.sectionItems=[...this.sectionItems.slice(0,i),e,...this.sectionItems.slice(i+1)]}}addState(e,t){if(!e||!t)return void Jc.warn("Section name and state name are required");const i=this.sectionItems.findIndex(t=>t.name===e);if(-1===i)return void Jc.warn(`Section "${e}" not found`);const o=this.sectionItems[i].states||[];if(!o.includes(t)){const i=[...o,t];this.updateSectionStates(e,i)}}addStates(e,t){if(!e||!Array.isArray(t))return void Jc.warn("Section name and state names array are required");const i=this.sectionItems.findIndex(t=>t.name===e);if(-1===i)return void Jc.warn(`Section "${e}" not found`);const o=[...this.sectionItems[i].states||[]];t.forEach(e=>{o.includes(e)||o.push(e)}),this.updateSectionStates(e,o)}clearState(e,t){if(!e||!t)return void Jc.warn("Section name and state name are required");const i=this.sectionItems.findIndex(t=>t.name===e);if(-1===i)return void Jc.warn(`Section "${e}" not found`);const o=this.sectionItems[i].states||[],n=o.indexOf(t);if(n>-1){const t=o.filter((e,t)=>t!==n);this.updateSectionStates(e,t)}}clearAllStates(e){if(!e)return void Jc.warn("Section name is required");-1!==this.sectionItems.findIndex(t=>t.name===e)?this.updateSectionStates(e,[]):Jc.warn(`Section "${e}" not found`)}clearAllStatesInAllSections(){this.sectionItems=this.sectionItems.map(e=>Object.assign(Object.assign({},e),{states:[]}))}getStateTooltip(e){return e?this.stateTooltips[e]||"":(Jc.warn("State name is required"),"")}getSectionStateClass(e){if(!e)return Jc.warn("Section is required"),"state-none";const t=e.states||[];if(0===t.length)return"state-none";if(t.length>1)return"state-multiple";return`state-${t[0]}`}getStateIcon(e){return e?this.stateIcons[e]||iu[e]:(Jc.warn("State name is required"),iu.active)}disconnectedCallback(){var e;super.disconnectedCallback(),this.handleSetStateRef&&this.removeEventListener(eu.setState,this.handleSetStateRef),this.handleSetStatesRef&&this.removeEventListener(eu.setStates,this.handleSetStatesRef),this.handleClearStateRef&&this.removeEventListener(eu.clearState,this.handleClearStateRef),this.handleClearAllStatesRef&&this.removeEventListener(eu.clearAllStates,this.handleClearAllStatesRef),this.handleGenericStateEventRef&&this.sectionContent&&(this.sectionContent.removeEventListener(eu.setState,this.handleGenericStateEventRef,!0),this.sectionContent.removeEventListener(eu.setStates,this.handleGenericStateEventRef,!0),this.sectionContent.removeEventListener(eu.clearState,this.handleGenericStateEventRef,!0),this.sectionContent.removeEventListener(eu.clearAllStates,this.handleGenericStateEventRef,!0)),this.cleanupScrollDetection(),null===(e=this.spacerElement)||void 0===e||e.remove(),this.spacerElement=void 0}}ou.SCROLL_END_TIMEOUT=150,ou.SCROLL_DEBOUNCE_TIMEOUT=100,(0,C.Cg)([l.observable],ou.prototype,"sections",void 0),(0,C.Cg)([(0,l.attr)({attribute:"scroll-behavior"})],ou.prototype,"scrollBehavior",void 0),(0,C.Cg)([(0,l.attr)({attribute:"state-tooltips"})],ou.prototype,"stateTooltips",void 0),(0,C.Cg)([(0,l.attr)({attribute:"state-icons"})],ou.prototype,"stateIcons",void 0),(0,C.Cg)([(0,l.attr)({attribute:"disable-auto-scroll-detection",mode:"boolean"})],ou.prototype,"disableAutoScrollDetection",void 0),(0,C.Cg)([l.observable],ou.prototype,"sectionItems",void 0),(0,C.Cg)([l.observable],ou.prototype,"activeSection",void 0);const nu={mode:"open"},su={},au=ou.compose(Object.assign({baseName:"foundation-section-navigator",template:Qc,styles:Xc,shadowOptions:nu},su)),ru=(e,t)=>l.css`
4666
4666
  ${(0,r.radioGroupStyles)(e,t)}
4667
4667
  ::slotted(foundation-segmented-item:first-of-type) {
4668
4668
  border-radius: calc(var(--control-corner-radius) * 1px) 0 0
@@ -4675,7 +4675,7 @@
4675
4675
  calc(var(--control-corner-radius) * 1px) 0;
4676
4676
  border-left-width: 0;
4677
4677
  }
4678
- `,lu=(e,t)=>(0,s.radioGroupTemplate)(e,t);class du extends s.RadioGroup{valueChanged(){void 0===this.value&&this.slottedRadioButtons&&this.slottedRadioButtons.forEach(e=>{e.checked=!1}),super.valueChanged()}}const cu=void 0,uu={},hu=du.compose(Object.assign({baseName:"segmented-control",template:lu,styles:ru,shadowOptions:cu},uu)),pu=(e,t)=>l.css`
4678
+ `,lu=(e,t)=>(0,a.radioGroupTemplate)(e,t);class du extends a.RadioGroup{valueChanged(){void 0===this.value&&this.slottedRadioButtons&&this.slottedRadioButtons.forEach(e=>{e.checked=!1}),super.valueChanged()}}const cu=void 0,uu={},hu=du.compose(Object.assign({baseName:"segmented-control",template:lu,styles:ru,shadowOptions:cu},uu)),pu=(e,t)=>l.css`
4679
4679
  ${(0,r.radioStyles)(e,t)}
4680
4680
  :host {
4681
4681
  padding: calc(var(--design-unit) * 2px) calc(var(--design-unit) * 4px);
@@ -4700,7 +4700,7 @@
4700
4700
  <slot></slot>
4701
4701
  </span>
4702
4702
  </template>
4703
- `;class vu extends r.Radio{}const gu=void 0,fu={},bu=vu.compose(Object.assign({baseName:"segmented-item",template:mu,styles:pu,shadowOptions:gu},fu)),yu=(e,t)=>l.css`
4703
+ `;class gu extends r.Radio{}const vu=void 0,fu={},bu=gu.compose(Object.assign({baseName:"segmented-item",template:mu,styles:pu,shadowOptions:vu},fu)),yu=(e,t)=>l.css`
4704
4704
  ${(0,r.selectStyles)(e,t)}
4705
4705
 
4706
4706
  :host(:not([size]):not([multiple]):not([open]):focus-visible), :host([multiple]:focus-visible), :host([size]:focus-visible),
@@ -4708,19 +4708,19 @@
4708
4708
  box-shadow: none;
4709
4709
  outline: none;
4710
4710
  }
4711
- `,wu=(e,t)=>(0,s.selectTemplate)(e,t);class Cu extends r.Select{slottedOptionsChanged(e,t){const i=this.value;super.slottedOptionsChanged(e,t),this.selectedIndex=-1;const o=[];this.slottedOptions&&this.slottedOptions.forEach(e=>{const t=e.nodeName.toLowerCase();if(t.endsWith("-optgroup")){const t=Array.from(e.children).filter(e=>{const t=e.nodeName.toLowerCase();return"option"===e.getAttribute("role")||t.endsWith("-option")});o.push(...t)}else("option"===e.getAttribute("role")||t.endsWith("-option"))&&o.push(e)}),this.options=o,i&&(this.value=i),-1===this.selectedIndex&&this.options.length>0&&(this.selectedIndex=0)}focusAndScrollOptionIntoView(e=this.firstSelectedOption){this.contains(function(e){const t=e.getRootNode();return t instanceof ShadowRoot?t.activeElement:document.activeElement}(this))&&null!==e&&(e.focus(),requestAnimationFrame(()=>{e.scrollIntoView({block:"nearest"})}))}openChanged(e,t){if(this.collapsible){if(this.open)return this.ariaControls=this.listboxId,this.ariaExpanded="true",this.setPositioning(),this.focusAndScrollOptionIntoView(),this.indexWhenOpened=this.selectedIndex,void l.DOM.queueUpdate(()=>this.focus());this.ariaControls="",this.ariaExpanded="false"}}keydownHandler(e){switch(e.key){case"ArrowDown":case"ArrowUp":if(this.open){const e=this.options[this.selectedIndex];null==e||e.scrollIntoView({block:"center",behavior:"auto"})}else this.open=!0}return super.keydownHandler(e)}}const xu=void 0,$u={indicator:'\n <svg\n class="select-indicator"\n part="select-indicator"\n viewBox="0 0 12 7"\n xmlns="http://www.w3.org/2000/svg"\n >\n <path\n d="M11.85.65c.2.2.2.5 0 .7L6.4 6.84a.55.55 0 01-.78 0L.14 1.35a.5.5 0 11.71-.7L6 5.8 11.15.65c.2-.2.5-.2.7 0z"\n />\n </svg>\n '},Su=Cu.compose(Object.assign({baseName:"select",template:wu,styles:yu,shadowOptions:xu},$u)),Eu=(e,t)=>l.css`
4711
+ `,wu=(e,t)=>(0,a.selectTemplate)(e,t);class Cu extends r.Select{slottedOptionsChanged(e,t){const i=this.value;super.slottedOptionsChanged(e,t),this.selectedIndex=-1;const o=[];this.slottedOptions&&this.slottedOptions.forEach(e=>{const t=e.nodeName.toLowerCase();if(t.endsWith("-optgroup")){const t=Array.from(e.children).filter(e=>{const t=e.nodeName.toLowerCase();return"option"===e.getAttribute("role")||t.endsWith("-option")});o.push(...t)}else("option"===e.getAttribute("role")||t.endsWith("-option"))&&o.push(e)}),this.options=o,i&&(this.value=i),-1===this.selectedIndex&&this.options.length>0&&(this.selectedIndex=0)}focusAndScrollOptionIntoView(e=this.firstSelectedOption){this.contains(function(e){const t=e.getRootNode();return t instanceof ShadowRoot?t.activeElement:document.activeElement}(this))&&null!==e&&(e.focus(),requestAnimationFrame(()=>{e.scrollIntoView({block:"nearest"})}))}openChanged(e,t){if(this.collapsible){if(this.open)return this.ariaControls=this.listboxId,this.ariaExpanded="true",this.setPositioning(),this.focusAndScrollOptionIntoView(),this.indexWhenOpened=this.selectedIndex,void l.DOM.queueUpdate(()=>this.focus());this.ariaControls="",this.ariaExpanded="false"}}keydownHandler(e){switch(e.key){case"ArrowDown":case"ArrowUp":if(this.open){const e=this.options[this.selectedIndex];null==e||e.scrollIntoView({block:"center",behavior:"auto"})}else this.open=!0}return super.keydownHandler(e)}}const xu=void 0,$u={indicator:'\n <svg\n class="select-indicator"\n part="select-indicator"\n viewBox="0 0 12 7"\n xmlns="http://www.w3.org/2000/svg"\n >\n <path\n d="M11.85.65c.2.2.2.5 0 .7L6.4 6.84a.55.55 0 01-.78 0L.14 1.35a.5.5 0 11.71-.7L6 5.8 11.15.65c.2-.2.5-.2.7 0z"\n />\n </svg>\n '},Su=Cu.compose(Object.assign({baseName:"select",template:wu,styles:yu,shadowOptions:xu},$u)),Eu=(e,t)=>l.css`
4712
4712
  ${(0,r.skeletonStyles)(e,t)}
4713
- `,ku=(e,t)=>(0,s.skeletonTemplate)(e,t);class Ou extends r.Skeleton{}const Tu=void 0,Iu={},Du=Ou.compose(Object.assign({baseName:"skeleton",template:ku,styles:Eu,shadowOptions:Tu},Iu)),Ru=(e,t)=>l.css`
4713
+ `,ku=(e,t)=>(0,a.skeletonTemplate)(e,t);class Ou extends r.Skeleton{}const Tu=void 0,Iu={},Ru=Ou.compose(Object.assign({baseName:"skeleton",template:ku,styles:Eu,shadowOptions:Tu},Iu)),Au=(e,t)=>l.css`
4714
4714
  ${(0,r.sliderStyles)(e,t)}
4715
4715
  .track-progress {
4716
4716
  background-color: var(--accent-fill-rest);
4717
4717
  border-radius: calc(var(--control-corner-radius) * 1px);
4718
4718
  }
4719
- `;var Au=i(17733),Nu=i(54120);const Lu=(e,t)=>l.html`
4719
+ `;var Du=i(17733),Nu=i(54120);const Lu=(e,t)=>l.html`
4720
4720
  <template
4721
4721
  role="slider"
4722
4722
  class="${e=>e.readOnly?"readonly":""}
4723
- ${e=>e.orientation||Au.t.horizontal}"
4723
+ ${e=>e.orientation||Du.t.horizontal}"
4724
4724
  tabindex="${e=>e.disabled?null:0}"
4725
4725
  aria-valuetext="${e=>e.valueTextFormatter(e.value)}"
4726
4726
  aria-valuenow="${e=>e.value}"
@@ -4749,9 +4749,9 @@
4749
4749
  </div>
4750
4750
  </div>
4751
4751
  </template>
4752
- `;class Fu extends r.Slider{}const Mu=void 0,_u={thumb:'\n <div class="thumb-cursor"></div>\n '},Hu=Fu.compose(Object.assign({baseName:"slider",template:Lu,styles:Ru,shadowOptions:Mu},_u)),Pu=(e,t)=>l.css`
4752
+ `;class Fu extends r.Slider{}const Mu=void 0,_u={thumb:'\n <div class="thumb-cursor"></div>\n '},Hu=Fu.compose(Object.assign({baseName:"slider",template:Lu,styles:Au,shadowOptions:Mu},_u)),Pu=(e,t)=>l.css`
4753
4753
  ${(0,r.sliderLabelStyles)(e,t)}
4754
- `,zu=(e,t)=>(0,s.sliderLabelTemplate)(e,t);class Uu extends r.SliderLabel{}const Bu=void 0,Wu={},Gu=Uu.compose(Object.assign({baseName:"slider-label",template:zu,styles:Pu,shadowOptions:Bu},Wu)),ju="default",Vu={DEFAULT:ju,ERROR:"error",SUCCESS:"success"},Yu=1e4,qu={DISMISS:"dismiss",AUTO_DISMISS:"autoDismiss"},Ku=l.css`
4754
+ `,zu=(e,t)=>(0,a.sliderLabelTemplate)(e,t);class Uu extends r.SliderLabel{}const Wu=void 0,Gu={},Bu=Uu.compose(Object.assign({baseName:"slider-label",template:zu,styles:Pu,shadowOptions:Wu},Gu)),Vu="default",ju={DEFAULT:Vu,ERROR:"error",SUCCESS:"success"},Yu=1e4,qu={DISMISS:"dismiss",AUTO_DISMISS:"autoDismiss"},Ku=l.css`
4755
4755
  @keyframes append-from-left-animate {
4756
4756
  from {
4757
4757
  transform: translateX(100%);
@@ -4885,10 +4885,10 @@
4885
4885
  ${e=>{var t,i;return(null===(t=e.error)||void 0===t?void 0:t.errorDetails)||(null===(i=e.notification)||void 0===i?void 0:i.body)||"Place holder for error message"}}
4886
4886
  </slot>
4887
4887
  </div>
4888
- ${(0,l.when)(e=>{var t,i,o,n,a,s,r,l;return(null===(n=null===(o=null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.snackbar)||void 0===o?void 0:o.confirmingActions)||void 0===n?void 0:n.length)||(null===(l=null===(r=null===(s=null===(a=e.notification)||void 0===a?void 0:a.config)||void 0===s?void 0:s.snackbar)||void 0===r?void 0:r.confirmingActions)||void 0===l?void 0:l.length)},l.html`
4888
+ ${(0,l.when)(e=>{var t,i,o,n,s,a,r,l;return(null===(n=null===(o=null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.snackbar)||void 0===o?void 0:o.confirmingActions)||void 0===n?void 0:n.length)||(null===(l=null===(r=null===(a=null===(s=e.notification)||void 0===s?void 0:s.config)||void 0===a?void 0:a.snackbar)||void 0===r?void 0:r.confirmingActions)||void 0===l?void 0:l.length)},l.html`
4889
4889
  <div part="action" class="action">
4890
4890
  <slot name="action">
4891
- ${(0,l.repeat)(e=>{var t,i,o,n,a,s;return(null===(o=null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.snackbar)||void 0===o?void 0:o.confirmingActions)||(null===(s=null===(a=null===(n=e.notification)||void 0===n?void 0:n.config)||void 0===a?void 0:a.snackbar)||void 0===s?void 0:s.confirmingActions)},l.html`
4891
+ ${(0,l.repeat)(e=>{var t,i,o,n,s,a;return(null===(o=null===(i=null===(t=e.error)||void 0===t?void 0:t.config)||void 0===i?void 0:i.snackbar)||void 0===o?void 0:o.confirmingActions)||(null===(a=null===(s=null===(n=e.notification)||void 0===n?void 0:n.config)||void 0===s?void 0:s.snackbar)||void 0===a?void 0:a.confirmingActions)},l.html`
4892
4892
  <${e}-button
4893
4893
  slot="action"
4894
4894
  appearance="lightweight"
@@ -4903,7 +4903,7 @@
4903
4903
  </div>
4904
4904
  `,Qu=l.html`
4905
4905
  ${e=>Xu(O(e))}
4906
- `,Ju={mode:"open",delegatesFocus:!0};class Zu extends s.FoundationElement{constructor(){super(...arguments),this.deleteAnimation="",this.closeTimeout=Yu,this.autoClose=!0,this.type=ju,this.dismissEventListener=this.handleDissmis.bind(this)}autoCloseChanged(){this.autoClose&&(this.timeoutRef=setTimeout(()=>{this.handleDissmis(!0)},this.closeTimeout)),!this.autoClose&&this.timeoutRef&&clearTimeout(this.timeoutRef)}connectedCallback(){super.connectedCallback(),this.addEventListener(qu.DISMISS,this.dismissEventListener)}errorChanged(e,t){var i,o,n;this.type=null!==(n=null===(o=null===(i=null==t?void 0:t.config)||void 0===i?void 0:i.snackbar)||void 0===o?void 0:o.type)&&void 0!==n?n:ju}notificationChanged(e,t){var i,o,n,a,s,r,l,d,c;this.type=null!==(n=null===(o=null===(i=null==t?void 0:t.config)||void 0===i?void 0:i.snackbar)||void 0===o?void 0:o.type)&&void 0!==n?n:ju,this.autoClose=null===(r=null===(s=null===(a=null==t?void 0:t.config)||void 0===a?void 0:a.snackbar)||void 0===s?void 0:s.autoClose)||void 0===r||r,this.closeTimeout=null!==(c=null===(d=null===(l=null==t?void 0:t.config)||void 0===l?void 0:l.snackbar)||void 0===d?void 0:d.closeTimeout)&&void 0!==c?c:Yu}handleDissmis(e=!1){this.deleteAnimation="snackbar-delete",this.snackbar.onanimationend=()=>{this.dismiss(),e&&this.dispatchEvent(new CustomEvent(qu.AUTO_DISMISS,{bubbles:!0,composed:!0,detail:this.identifier}))}}dismiss(){this.remove(),this.timeoutRef&&clearTimeout(this.timeoutRef)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(qu.DISMISS,this.dismissEventListener),this.timeoutRef&&clearTimeout(this.timeoutRef)}}(0,C.Cg)([l.observable],Zu.prototype,"error",void 0),(0,C.Cg)([l.observable],Zu.prototype,"notification",void 0),(0,C.Cg)([l.observable],Zu.prototype,"deleteAnimation",void 0),(0,C.Cg)([(0,l.attr)({attribute:"identifier"})],Zu.prototype,"identifier",void 0),(0,C.Cg)([(0,l.attr)({attribute:"close-timeout"})],Zu.prototype,"closeTimeout",void 0),(0,C.Cg)([(0,l.attr)({attribute:"auto-close",mode:"boolean"})],Zu.prototype,"autoClose",void 0),(0,C.Cg)([(0,l.attr)({attribute:"type"})],Zu.prototype,"type",void 0);const eh=Zu.compose({baseName:"snackbar",styles:Ku,template:Qu,shadowOptions:Ju}),th=(e,t)=>l.css`
4906
+ `,Ju={mode:"open",delegatesFocus:!0};class Zu extends a.FoundationElement{constructor(){super(...arguments),this.deleteAnimation="",this.closeTimeout=Yu,this.autoClose=!0,this.type=Vu,this.dismissEventListener=this.handleDissmis.bind(this)}autoCloseChanged(){this.autoClose&&(this.timeoutRef=setTimeout(()=>{this.handleDissmis(!0)},this.closeTimeout)),!this.autoClose&&this.timeoutRef&&clearTimeout(this.timeoutRef)}connectedCallback(){super.connectedCallback(),this.addEventListener(qu.DISMISS,this.dismissEventListener)}errorChanged(e,t){var i,o,n;this.type=null!==(n=null===(o=null===(i=null==t?void 0:t.config)||void 0===i?void 0:i.snackbar)||void 0===o?void 0:o.type)&&void 0!==n?n:Vu}notificationChanged(e,t){var i,o,n,s,a,r,l,d,c;this.type=null!==(n=null===(o=null===(i=null==t?void 0:t.config)||void 0===i?void 0:i.snackbar)||void 0===o?void 0:o.type)&&void 0!==n?n:Vu,this.autoClose=null===(r=null===(a=null===(s=null==t?void 0:t.config)||void 0===s?void 0:s.snackbar)||void 0===a?void 0:a.autoClose)||void 0===r||r,this.closeTimeout=null!==(c=null===(d=null===(l=null==t?void 0:t.config)||void 0===l?void 0:l.snackbar)||void 0===d?void 0:d.closeTimeout)&&void 0!==c?c:Yu}handleDissmis(e=!1){this.deleteAnimation="snackbar-delete",this.snackbar.onanimationend=()=>{this.dismiss(),e&&this.dispatchEvent(new CustomEvent(qu.AUTO_DISMISS,{bubbles:!0,composed:!0,detail:this.identifier}))}}dismiss(){this.remove(),this.timeoutRef&&clearTimeout(this.timeoutRef)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(qu.DISMISS,this.dismissEventListener),this.timeoutRef&&clearTimeout(this.timeoutRef)}}(0,C.Cg)([l.observable],Zu.prototype,"error",void 0),(0,C.Cg)([l.observable],Zu.prototype,"notification",void 0),(0,C.Cg)([l.observable],Zu.prototype,"deleteAnimation",void 0),(0,C.Cg)([(0,l.attr)({attribute:"identifier"})],Zu.prototype,"identifier",void 0),(0,C.Cg)([(0,l.attr)({attribute:"close-timeout"})],Zu.prototype,"closeTimeout",void 0),(0,C.Cg)([(0,l.attr)({attribute:"auto-close",mode:"boolean"})],Zu.prototype,"autoClose",void 0),(0,C.Cg)([(0,l.attr)({attribute:"type"})],Zu.prototype,"type",void 0);const eh=Zu.compose({baseName:"snackbar",styles:Ku,template:Qu,shadowOptions:Ju}),th=(e,t)=>l.css`
4907
4907
  ${nr()}
4908
4908
 
4909
4909
  .fa-stack {
@@ -4936,7 +4936,7 @@
4936
4936
  >
4937
4937
  <slot></slot>
4938
4938
  </span>
4939
- `;class oh extends s.FoundationElement{constructor(){super(...arguments),this.size=ur,this["vertical-align"]="baseline"}}(0,C.Cg)([l.attr],oh.prototype,"size",void 0),(0,C.Cg)([l.attr],oh.prototype,"vertical-align",void 0);const nh=oh.compose({baseName:"stacking-icons",template:ih,styles:th}),ah=l.css`
4939
+ `;class oh extends a.FoundationElement{constructor(){super(...arguments),this.size=ur,this["vertical-align"]="baseline"}}(0,C.Cg)([l.attr],oh.prototype,"size",void 0),(0,C.Cg)([l.attr],oh.prototype,"vertical-align",void 0);const nh=oh.compose({baseName:"stacking-icons",template:ih,styles:th}),sh=l.css`
4940
4940
  .status-pill {
4941
4941
  font-size: 12px;
4942
4942
  display: inline-flex;
@@ -4970,7 +4970,7 @@
4970
4970
  .status-pill-image {
4971
4971
  height: 14px;
4972
4972
  }
4973
- `,sh=l.html`
4973
+ `,ah=l.html`
4974
4974
  ${e=>{return t=O(e),l.html`
4975
4975
  ${(0,l.when)(e=>e.isCountdownVisible&&!(e.hideWhenCountdownCompleted&&e.isCountdownExpired),l.html`
4976
4976
  <div
@@ -5001,7 +5001,7 @@
5001
5001
  </div>
5002
5002
  `)}
5003
5003
  `;var t}}
5004
- `,rh=(e,t="second")=>{let i=e/1e3;const o=Math.floor(i/86400);i%=86400;const n=Math.floor(i/3600);i%=3600;const a=Math.floor(i/60),s=Math.floor(i%60),r=[];switch(o&&r.push(`${o}d`),t){case"minute":n&&r.push(`${n}h`),a&&r.push(`${a}m`),!a&&s&&r.push("< 1m");break;case"hour":n&&r.push(`${n}h`),n||!a&&!s||r.push("< 1h");break;default:n&&r.push(`${n}h`),a&&r.push(`${a}m`),s&&r.push(`${s}s`)}return r.length?r.join(" "):"0s"};class lh extends s.FoundationElement{constructor(){super(...arguments),this.iconSize="sm",this.dateCountdownCompletedMessage="Expired",this.dateCountdownUnit="second",this.hideWhenCountdownCompleted=!1,this.isCountdownExpired=!1,this.isCountdownVisible=!0}dateCountdownChanged(e,t){if(e!==t){if(!t)return void this.clearCountdownTimer();this.isCountdownExpired=!1,this.setUpDateCountdown(t)}}dateCountdownVisibleAfterChanged(e,t){e!==t&&this.updateVisibilityFromStartTime()}connectedCallback(){this.updateVisibilityFromStartTime(),super.connectedCallback()}disconnectedCallback(){this.clearCountdownTimer(),super.disconnectedCallback()}setUpDateCountdown(e){if(this.clearCountdownTimer(),isNaN(parseInt(e)))Xe.warn("invalid date-countdown value passed. Must be a number");else{e=parseInt(e);const t=new Date(e);this.updateCountdown(t),this.dateInterval=setInterval(()=>this.updateCountdown(t),1e3)}}updateCountdown(e){const t=(new Date).getTime(),i=Math.floor(e.getTime()-t),o=void 0!==this.dateCountdownVisibleAfter&&null!==this.dateCountdownVisibleAfter?Number(this.dateCountdownVisibleAfter):void 0;if(void 0!==o&&!isNaN(o)&&t<o)return this.isCountdownVisible=!1,this.countdown=null,void(this.isCountdownExpired=!1);this.isCountdownVisible=!0,i<=0?this.hideWhenCountdownCompleted?(this.isCountdownExpired=!0,this.clearCountdownTimer()):(this.countdown=this.dateCountdownCompletedMessage,clearInterval(this.dateInterval)):this.countdown=rh(i,this.dateCountdownUnit)}updateVisibilityFromStartTime(){const e=void 0!==this.dateCountdownVisibleAfter&&null!==this.dateCountdownVisibleAfter?Number(this.dateCountdownVisibleAfter):void 0;if(void 0===e||isNaN(e))this.isCountdownVisible=!0;else{const t=Date.now();this.isCountdownVisible=t>=e}}clearCountdownTimer(){this.dateInterval&&(clearInterval(this.dateInterval),this.dateInterval=null),this.countdown=null}}(0,C.Cg)([(0,l.attr)({attribute:"background-color"})],lh.prototype,"backgroundColor",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-name"})],lh.prototype,"iconName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-src"})],lh.prototype,"iconSrc",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-initial"})],lh.prototype,"iconInitial",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-initial-background-color"})],lh.prototype,"iconInitialBackgroundColor",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-size"})],lh.prototype,"iconSize",void 0),(0,C.Cg)([(0,l.attr)({attribute:"text-color"})],lh.prototype,"textColor",void 0),(0,C.Cg)([l.attr],lh.prototype,"text",void 0),(0,C.Cg)([(0,l.attr)({attribute:"date-countdown"})],lh.prototype,"dateCountdown",void 0),(0,C.Cg)([(0,l.attr)({attribute:"date-countdown-completed-message"})],lh.prototype,"dateCountdownCompletedMessage",void 0),(0,C.Cg)([(0,l.attr)({attribute:"date-countdown-unit"})],lh.prototype,"dateCountdownUnit",void 0),(0,C.Cg)([(0,l.attr)({attribute:"date-countdown-visible-after"})],lh.prototype,"dateCountdownVisibleAfter",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"hide-when-countdown-completed"})],lh.prototype,"hideWhenCountdownCompleted",void 0),(0,C.Cg)([l.observable],lh.prototype,"countdown",void 0),(0,C.Cg)([l.observable],lh.prototype,"isCountdownExpired",void 0),(0,C.Cg)([l.observable],lh.prototype,"isCountdownVisible",void 0);const dh=lh.compose({baseName:"status-pill",styles:ah,template:sh}),ch=(e,t)=>l.css`
5004
+ `,rh=(e,t="second")=>{let i=e/1e3;const o=Math.floor(i/86400);i%=86400;const n=Math.floor(i/3600);i%=3600;const s=Math.floor(i/60),a=Math.floor(i%60),r=[];switch(o&&r.push(`${o}d`),t){case"minute":n&&r.push(`${n}h`),s&&r.push(`${s}m`),!s&&a&&r.push("< 1m");break;case"hour":n&&r.push(`${n}h`),n||!s&&!a||r.push("< 1h");break;default:n&&r.push(`${n}h`),s&&r.push(`${s}m`),a&&r.push(`${a}s`)}return r.length?r.join(" "):"0s"};class lh extends a.FoundationElement{constructor(){super(...arguments),this.iconSize="sm",this.dateCountdownCompletedMessage="Expired",this.dateCountdownUnit="second",this.hideWhenCountdownCompleted=!1,this.isCountdownExpired=!1,this.isCountdownVisible=!0}dateCountdownChanged(e,t){if(e!==t){if(!t)return void this.clearCountdownTimer();this.isCountdownExpired=!1,this.setUpDateCountdown(t)}}dateCountdownVisibleAfterChanged(e,t){e!==t&&this.updateVisibilityFromStartTime()}connectedCallback(){this.updateVisibilityFromStartTime(),super.connectedCallback()}disconnectedCallback(){this.clearCountdownTimer(),super.disconnectedCallback()}setUpDateCountdown(e){if(this.clearCountdownTimer(),isNaN(parseInt(e)))Xe.warn("invalid date-countdown value passed. Must be a number");else{e=parseInt(e);const t=new Date(e);this.updateCountdown(t),this.dateInterval=setInterval(()=>this.updateCountdown(t),1e3)}}updateCountdown(e){const t=(new Date).getTime(),i=Math.floor(e.getTime()-t),o=void 0!==this.dateCountdownVisibleAfter&&null!==this.dateCountdownVisibleAfter?Number(this.dateCountdownVisibleAfter):void 0;if(void 0!==o&&!isNaN(o)&&t<o)return this.isCountdownVisible=!1,this.countdown=null,void(this.isCountdownExpired=!1);this.isCountdownVisible=!0,i<=0?this.hideWhenCountdownCompleted?(this.isCountdownExpired=!0,this.clearCountdownTimer()):(this.countdown=this.dateCountdownCompletedMessage,clearInterval(this.dateInterval)):this.countdown=rh(i,this.dateCountdownUnit)}updateVisibilityFromStartTime(){const e=void 0!==this.dateCountdownVisibleAfter&&null!==this.dateCountdownVisibleAfter?Number(this.dateCountdownVisibleAfter):void 0;if(void 0===e||isNaN(e))this.isCountdownVisible=!0;else{const t=Date.now();this.isCountdownVisible=t>=e}}clearCountdownTimer(){this.dateInterval&&(clearInterval(this.dateInterval),this.dateInterval=null),this.countdown=null}}(0,C.Cg)([(0,l.attr)({attribute:"background-color"})],lh.prototype,"backgroundColor",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-name"})],lh.prototype,"iconName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-src"})],lh.prototype,"iconSrc",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-initial"})],lh.prototype,"iconInitial",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-initial-background-color"})],lh.prototype,"iconInitialBackgroundColor",void 0),(0,C.Cg)([(0,l.attr)({attribute:"icon-size"})],lh.prototype,"iconSize",void 0),(0,C.Cg)([(0,l.attr)({attribute:"text-color"})],lh.prototype,"textColor",void 0),(0,C.Cg)([l.attr],lh.prototype,"text",void 0),(0,C.Cg)([(0,l.attr)({attribute:"date-countdown"})],lh.prototype,"dateCountdown",void 0),(0,C.Cg)([(0,l.attr)({attribute:"date-countdown-completed-message"})],lh.prototype,"dateCountdownCompletedMessage",void 0),(0,C.Cg)([(0,l.attr)({attribute:"date-countdown-unit"})],lh.prototype,"dateCountdownUnit",void 0),(0,C.Cg)([(0,l.attr)({attribute:"date-countdown-visible-after"})],lh.prototype,"dateCountdownVisibleAfter",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"hide-when-countdown-completed"})],lh.prototype,"hideWhenCountdownCompleted",void 0),(0,C.Cg)([l.observable],lh.prototype,"countdown",void 0),(0,C.Cg)([l.observable],lh.prototype,"isCountdownExpired",void 0),(0,C.Cg)([l.observable],lh.prototype,"isCountdownVisible",void 0);const dh=lh.compose({baseName:"status-pill",styles:sh,template:ah}),ch=(e,t)=>l.css`
5005
5005
  .tree-item {
5006
5006
  cursor: default;
5007
5007
  }
@@ -5112,7 +5112,7 @@
5112
5112
  background-color: var(--accent-fill-rest); /* Choose a color */
5113
5113
  }
5114
5114
  `,uh=e=>l.html`
5115
- ${(0,dn.q)(e=>e.orientation===s.TabsOrientation.vertical,l.html`
5115
+ ${(0,dn.q)(e=>e.orientation===a.TabsOrientation.vertical,l.html`
5116
5116
  <${e}-tree-item ${(0,l.ref)("treeItem")}
5117
5117
  class=${e=>(0,x.x)("tree-item",["cursor-pointer",e.showCursorPointer])}
5118
5118
  @click="${(e,t)=>e.$emit("tab-clicked",e.tabPosition-1)}">
@@ -5157,11 +5157,11 @@
5157
5157
  `)}
5158
5158
  `,hh=l.html`
5159
5159
  ${e=>uh(O(e))}
5160
- `;class ph extends s.FoundationElement{constructor(){super(...arguments),this.slot="tab",this.orientation=s.TabsOrientation.vertical}isCompleted(){return this.completed}selectedChanged(){this.treeItem&&(this.treeItem.selected=this.selected)}disconnectedCallback(){super.disconnectedCallback(),this.completed=void 0,this.error=void 0,this.selected=void 0}}(0,C.Cg)([l.attr],ph.prototype,"slot",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"selected",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"completed",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"error",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"isLast",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"hideStepNumber",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"showCursorPointer",void 0),(0,C.Cg)([(0,l.attr)({attribute:"tab-position"})],ph.prototype,"tabPosition",void 0),(0,C.Cg)([l.attr],ph.prototype,"orientation",void 0);const mh=void 0,vh={},gh=ph.compose(Object.assign({baseName:"stepper-tab",template:hh,styles:ch,shadowOptions:mh},vh)),fh=()=>l.html`
5160
+ `;class ph extends a.FoundationElement{constructor(){super(...arguments),this.slot="tab",this.orientation=a.TabsOrientation.vertical}isCompleted(){return this.completed}selectedChanged(){this.treeItem&&(this.treeItem.selected=this.selected)}disconnectedCallback(){super.disconnectedCallback(),this.completed=void 0,this.error=void 0,this.selected=void 0}}(0,C.Cg)([l.attr],ph.prototype,"slot",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"selected",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"completed",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"error",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"isLast",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"hideStepNumber",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],ph.prototype,"showCursorPointer",void 0),(0,C.Cg)([(0,l.attr)({attribute:"tab-position"})],ph.prototype,"tabPosition",void 0),(0,C.Cg)([l.attr],ph.prototype,"orientation",void 0);const mh=void 0,gh={},vh=ph.compose(Object.assign({baseName:"stepper-tab",template:hh,styles:ch,shadowOptions:mh},gh)),fh=()=>l.html`
5161
5161
  <template slot="tab-panel" role="stepper-tab-panel">
5162
5162
  <slot></slot>
5163
5163
  </template>
5164
- `;class bh extends s.FoundationElement{}const yh=void 0,wh={},Ch=bh.compose(Object.assign({baseName:"stepper-tab-panel",template:fh,shadowOptions:yh},wh)),xh=(e,t)=>l.css`
5164
+ `;class bh extends a.FoundationElement{}const yh=void 0,wh={},Ch=bh.compose(Object.assign({baseName:"stepper-tab-panel",template:fh,shadowOptions:yh},wh)),xh=(e,t)=>l.css`
5165
5165
  ${(0,r.switchStyles)(e,t)}
5166
5166
  .checked-indicator {
5167
5167
  transform: scale(1.3);
@@ -5174,20 +5174,20 @@
5174
5174
  .checked-indicator {
5175
5175
  border-radius: calc(var(--control-corner-radius) * 2px);
5176
5176
  }
5177
- `,$h=(e,t)=>(0,s.switchTemplate)(e,t);class Sh extends r.Switch{}const Eh=void 0,kh={switch:'<div class="checked-indicator" part="checked-indicator"></div>'},Oh=Sh.compose(Object.assign({baseName:"switch",template:$h,styles:xh,shadowOptions:Eh},kh)),Th=(e,t)=>l.css`
5177
+ `,$h=(e,t)=>(0,a.switchTemplate)(e,t);class Sh extends r.Switch{}const Eh=void 0,kh={switch:'<div class="checked-indicator" part="checked-indicator"></div>'},Oh=Sh.compose(Object.assign({baseName:"switch",template:$h,styles:xh,shadowOptions:Eh},kh)),Th=(e,t)=>l.css`
5178
5178
  ${(0,r.tabStyles)(e,t)}
5179
5179
 
5180
5180
  :host {
5181
5181
  user-select: none;
5182
5182
  }
5183
- `,Ih=(e,t)=>(0,s.tabTemplate)(e,t);class Dh extends r.Tab{}const Rh=void 0,Ah={},Nh=Dh.compose(Object.assign({baseName:"tab",template:Ih,styles:Th,shadowOptions:Rh},Ah)),Lh=(e,t)=>l.css`
5183
+ `,Ih=(e,t)=>(0,a.tabTemplate)(e,t);class Rh extends r.Tab{}const Ah=void 0,Dh={},Nh=Rh.compose(Object.assign({baseName:"tab",template:Ih,styles:Th,shadowOptions:Ah},Dh)),Lh=(e,t)=>l.css`
5184
5184
  ${(0,r.tabPanelStyles)(e,t)}
5185
5185
 
5186
5186
  :host {
5187
5187
  height: 100%;
5188
5188
  padding: 0;
5189
5189
  }
5190
- `,Fh=(e,t)=>(0,s.tabPanelTemplate)(e,t);class Mh extends r.TabPanel{}const _h=void 0,Hh={},Ph=Mh.compose(Object.assign({baseName:"tab-panel",template:Fh,styles:Lh,shadowOptions:_h},Hh)),zh=(e,t)=>l.css`
5190
+ `,Fh=(e,t)=>(0,a.tabPanelTemplate)(e,t);class Mh extends r.TabPanel{}const _h=void 0,Hh={},Ph=Mh.compose(Object.assign({baseName:"tab-panel",template:Fh,styles:Lh,shadowOptions:_h},Hh)),zh=(e,t)=>l.css`
5191
5191
  ${(0,r.tabsStyles)(e,t)}
5192
5192
 
5193
5193
  :host {
@@ -5204,12 +5204,12 @@
5204
5204
  :host([scrollable]) ::slotted([role='tab']) {
5205
5205
  flex: 0 0 auto;
5206
5206
  }
5207
- `,Uh=(e,t)=>(0,s.tabsTemplate)(e,t);class Bh extends r.Tabs{constructor(){super(...arguments),this.scrollable=!1}get currentTabIndex(){return this.activeTabIndex}}(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Bh.prototype,"scrollable",void 0);const Wh=void 0,Gh={},jh=Bh.compose(Object.assign({baseName:"tabs",template:Uh,styles:zh,shadowOptions:Wh},Gh)),Vh=(e,t)=>l.css`
5207
+ `,Uh=(e,t)=>(0,a.tabsTemplate)(e,t);class Wh extends r.Tabs{constructor(){super(...arguments),this.scrollable=!1}get currentTabIndex(){return this.activeTabIndex}}(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Wh.prototype,"scrollable",void 0);const Gh=void 0,Bh={},Vh=Wh.compose(Object.assign({baseName:"tabs",template:Uh,styles:zh,shadowOptions:Gh},Bh)),jh=(e,t)=>l.css`
5208
5208
  ${(0,r.textAreaStyles)(e,t)}
5209
5209
  :host .control {
5210
5210
  padding: calc(var(--design-unit) * 3px);
5211
5211
  }
5212
- `,Yh=(e,t)=>(0,s.textAreaTemplate)(e,t);class qh extends r.TextArea{}const Kh=void 0,Xh={},Qh=qh.compose(Object.assign({baseName:"text-area",template:Yh,styles:Vh,shadowOptions:Kh},Xh)),{create:Jh}=s.DesignToken,Zh=Jh("active-color-scheme").withDefault(e=>r.baseLayerLuminance.getValueFor(e)===r.StandardLuminance.LightMode?"light":"dark"),ep=(e,t)=>l.css`
5212
+ `,Yh=(e,t)=>(0,a.textAreaTemplate)(e,t);class qh extends r.TextArea{}const Kh=void 0,Xh={},Qh=qh.compose(Object.assign({baseName:"text-area",template:Yh,styles:jh,shadowOptions:Kh},Xh)),{create:Jh}=a.DesignToken,Zh=Jh("active-color-scheme").withDefault(e=>r.baseLayerLuminance.getValueFor(e)===r.StandardLuminance.LightMode?"light":"dark"),ep=(e,t)=>l.css`
5213
5213
  ${(0,r.textFieldStyles)(e,t)}
5214
5214
 
5215
5215
  input {
@@ -5230,10 +5230,10 @@
5230
5230
  for="${e=>e.id?e.id:"control"}"
5231
5231
  class="${e=>e.defaultSlottedNodes&&e.defaultSlottedNodes.length?"label":"label label-hidden"}"
5232
5232
  >
5233
- <slot ${(0,l.slotted)({property:"defaultSlottedNodes",filter:s.whitespaceFilter})}></slot>
5233
+ <slot ${(0,l.slotted)({property:"defaultSlottedNodes",filter:a.whitespaceFilter})}></slot>
5234
5234
  </label>
5235
5235
  <div class="root" part="root">
5236
- ${(0,s.startSlotTemplate)(e,t)}
5236
+ ${(0,a.startSlotTemplate)(e,t)}
5237
5237
  <input
5238
5238
  name="${e=>e.name}"
5239
5239
  autocomplete="${e=>e.autocomplete}"
@@ -5278,10 +5278,10 @@
5278
5278
  aria-roledescription="${e=>e.ariaRoledescription}"
5279
5279
  ${(0,l.ref)("control")}
5280
5280
  />
5281
- ${(0,s.endSlotTemplate)(e,t)}
5281
+ ${(0,a.endSlotTemplate)(e,t)}
5282
5282
  </div>
5283
5283
  </template>
5284
- `;class ip extends r.TextField{constructor(){super(...arguments),this.autocomplete="off",this.autocapitalize="off"}autocompleteChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.autocomplete=this.autocomplete)}autocapitalizeChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.autocapitalize=this.autocapitalize)}}(0,C.Cg)([l.attr],ip.prototype,"autocomplete",void 0),(0,C.Cg)([l.attr],ip.prototype,"autocapitalize",void 0),(0,C.Cg)([l.attr],ip.prototype,"step",void 0);const op={mode:"open",delegatesFocus:!0},np={},ap=ip.compose(Object.assign({baseName:"text-field",template:tp,styles:ep,shadowOptions:op},np)),sp=l.css`
5284
+ `;class ip extends r.TextField{constructor(){super(...arguments),this.autocomplete="off",this.autocapitalize="off"}autocompleteChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.autocomplete=this.autocomplete)}autocapitalizeChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.autocapitalize=this.autocapitalize)}}(0,C.Cg)([l.attr],ip.prototype,"autocomplete",void 0),(0,C.Cg)([l.attr],ip.prototype,"autocapitalize",void 0),(0,C.Cg)([l.attr],ip.prototype,"step",void 0);const op={mode:"open",delegatesFocus:!0},np={},sp=ip.compose(Object.assign({baseName:"text-field",template:tp,styles:ep,shadowOptions:op},np)),ap=l.css`
5285
5285
  @keyframes append-animate {
5286
5286
  from {
5287
5287
  transform: translateX(100%);
@@ -5421,11 +5421,11 @@
5421
5421
  </div>
5422
5422
  `,lp=l.html`
5423
5423
  ${e=>rp(O(e))}
5424
- `,dp={mode:"open",delegatesFocus:!0},cp={};class up extends s.FoundationElement{constructor(){super(...arguments),this.deleteAnimation="",this.closeTimeout=1e4,this.autoClose=!1,this.closeTimer=null}connectedCallback(){super.connectedCallback(),this.autoClose&&(this.closeTimer=setTimeout(()=>{this.deleteAnimation="toast-delete",this.toast.onanimationend=()=>{this.remove()}},this.closeTimeout))}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this.closeTimer),this.closeTimer=null}close(){this.remove()}}(0,C.Cg)([l.observable],up.prototype,"deleteAnimation",void 0),(0,C.Cg)([(0,l.attr)({attribute:"close-timeout"})],up.prototype,"closeTimeout",void 0),(0,C.Cg)([(0,l.attr)({attribute:"auto-close"})],up.prototype,"autoClose",void 0),(0,C.Cg)([(0,l.attr)({attribute:"notification-icon"})],up.prototype,"notificationIcon",void 0);const hp=up.compose(Object.assign({baseName:"toast",styles:sp,template:lp,shadowOptions:dp},cp)),pp=(e,t)=>l.css`
5424
+ `,dp={mode:"open",delegatesFocus:!0},cp={};class up extends a.FoundationElement{constructor(){super(...arguments),this.deleteAnimation="",this.closeTimeout=1e4,this.autoClose=!1,this.closeTimer=null}connectedCallback(){super.connectedCallback(),this.autoClose&&(this.closeTimer=setTimeout(()=>{this.deleteAnimation="toast-delete",this.toast.onanimationend=()=>{this.remove()}},this.closeTimeout))}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this.closeTimer),this.closeTimer=null}close(){this.remove()}}(0,C.Cg)([l.observable],up.prototype,"deleteAnimation",void 0),(0,C.Cg)([(0,l.attr)({attribute:"close-timeout"})],up.prototype,"closeTimeout",void 0),(0,C.Cg)([(0,l.attr)({attribute:"auto-close"})],up.prototype,"autoClose",void 0),(0,C.Cg)([(0,l.attr)({attribute:"notification-icon"})],up.prototype,"notificationIcon",void 0);const hp=up.compose(Object.assign({baseName:"toast",styles:ap,template:lp,shadowOptions:dp},cp)),pp=(e,t)=>l.css`
5425
5425
  ${(0,r.toolbarStyles)(e,t)}
5426
- `,mp=(e,t)=>(0,s.toolbarTemplate)(e,t);class vp extends r.Toolbar{}const gp=void 0,fp={},bp=vp.compose(Object.assign({baseName:"toolbar",template:mp,styles:pp,shadowOptions:gp},fp)),yp=(e,t)=>l.css`
5426
+ `,mp=(e,t)=>(0,a.toolbarTemplate)(e,t);class gp extends r.Toolbar{}const vp=void 0,fp={},bp=gp.compose(Object.assign({baseName:"toolbar",template:mp,styles:pp,shadowOptions:vp},fp)),yp=(e,t)=>l.css`
5427
5427
  ${(0,r.tooltipStyles)(e,t)}
5428
- `,wp=(e,t)=>(0,s.tooltipTemplate)(e,t);class Cp extends r.Tooltip{}const xp=void 0,$p={},Sp=Cp.compose(Object.assign({baseName:"tooltip",template:wp,styles:yp,shadowOptions:xp},$p)),Ep=(e,t)=>l.css`
5428
+ `,wp=(e,t)=>(0,a.tooltipTemplate)(e,t);class Cp extends r.Tooltip{}const xp=void 0,$p={},Sp=Cp.compose(Object.assign({baseName:"tooltip",template:wp,styles:yp,shadowOptions:xp},$p)),Ep=(e,t)=>l.css`
5429
5429
  ${(0,r.treeItemStyles)(e,t)}
5430
5430
  :host {
5431
5431
  --focus-stroke-width: 0;
@@ -5442,9 +5442,9 @@
5442
5442
  .positioning-region {
5443
5443
  height: calc(((var(--base-height-multiplier) + var(--density)) * var(--design-unit)) * 1px);
5444
5444
  }
5445
- `,kp=(e,t)=>(0,s.treeItemTemplate)(e,t);class Op extends r.TreeItem{}const Tp=void 0,Ip={expandCollapseGlyph:'\n <svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg" class="expand-collapse-glyph">\n <path d="M5.00001 12.3263C5.00124 12.5147 5.05566 12.699 5.15699 12.8578C5.25831 13.0167 5.40243 13.1437 5.57273 13.2242C5.74304 13.3047 5.9326 13.3354 6.11959 13.3128C6.30659 13.2902 6.4834 13.2152 6.62967 13.0965L10.8988 8.83532C11.0739 8.69473 11.2153 8.51658 11.3124 8.31402C11.4096 8.11146 11.46 7.88966 11.46 7.66499C11.46 7.44033 11.4096 7.21853 11.3124 7.01597C11.2153 6.81341 11.0739 6.63526 10.8988 6.49467L6.62967 2.22347C6.48274 2.10422 6.30501 2.02912 6.11712 2.00691C5.92923 1.9847 5.73889 2.01628 5.56823 2.09799C5.39757 2.17969 5.25358 2.30817 5.153 2.46849C5.05241 2.62882 4.99936 2.8144 5.00001 3.00369V12.3263Z"></path>\n </svg>'},Dp=Op.compose(Object.assign({baseName:"tree-item",template:kp,styles:Ep,shadowOptions:Tp},Ip)),Rp=(e,t)=>l.css`
5445
+ `,kp=(e,t)=>(0,a.treeItemTemplate)(e,t);class Op extends r.TreeItem{}const Tp=void 0,Ip={expandCollapseGlyph:'\n <svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg" class="expand-collapse-glyph">\n <path d="M5.00001 12.3263C5.00124 12.5147 5.05566 12.699 5.15699 12.8578C5.25831 13.0167 5.40243 13.1437 5.57273 13.2242C5.74304 13.3047 5.9326 13.3354 6.11959 13.3128C6.30659 13.2902 6.4834 13.2152 6.62967 13.0965L10.8988 8.83532C11.0739 8.69473 11.2153 8.51658 11.3124 8.31402C11.4096 8.11146 11.46 7.88966 11.46 7.66499C11.46 7.44033 11.4096 7.21853 11.3124 7.01597C11.2153 6.81341 11.0739 6.63526 10.8988 6.49467L6.62967 2.22347C6.48274 2.10422 6.30501 2.02912 6.11712 2.00691C5.92923 1.9847 5.73889 2.01628 5.56823 2.09799C5.39757 2.17969 5.25358 2.30817 5.153 2.46849C5.05241 2.62882 4.99936 2.8144 5.00001 3.00369V12.3263Z"></path>\n </svg>'},Rp=Op.compose(Object.assign({baseName:"tree-item",template:kp,styles:Ep,shadowOptions:Tp},Ip)),Ap=(e,t)=>l.css`
5446
5446
  ${(0,r.treeViewStyles)(e,t)}
5447
- `,Ap=(e,t)=>(0,s.treeViewTemplate)(e,t);class Np extends s.TreeView{}const Lp=void 0,Fp={},Mp=Np.compose(Object.assign({baseName:"tree-view",template:Ap,styles:Rp,shadowOptions:Lp},Fp)),_p=(e,t)=>l.css`
5447
+ `,Dp=(e,t)=>(0,a.treeViewTemplate)(e,t);class Np extends a.TreeView{}const Lp=void 0,Fp={},Mp=Np.compose(Object.assign({baseName:"tree-view",template:Dp,styles:Ap,shadowOptions:Lp},Fp)),_p=(e,t)=>l.css`
5448
5448
  .container {
5449
5449
  position: relative;
5450
5450
  width: 100%;
@@ -5481,7 +5481,7 @@
5481
5481
  </div>
5482
5482
  `,Pp=l.html`
5483
5483
  ${e=>Hp(O(e))}
5484
- `,zp=void 0,Up={};class Bp extends r.TextField{constructor(){super(...arguments),this.value=""}saveUrl(e){this.value=e.startsWith("http")?e:"https://"+e,this.focused=!1}focus(){this.focused=!0}}(0,C.Cg)([l.observable],Bp.prototype,"value",void 0),(0,C.Cg)([l.observable],Bp.prototype,"focused",void 0);const Wp=Bp.compose(Object.assign({baseName:"url-input",template:Pp,styles:_p,shadowOptions:zp},Up)),Gp={foundationAccordion:m,foundationAiCriteriaSearch:ye,foundationAiIndicator:$e,foundationAccordionItem:w,foundationActionsMenu:A,foundationAnchor:Ie,foundationAnchoredRegion:Fe,foundationAvatar:Be,foundationBadge:qe,foundationBanner:it,foundationBreadcrumb:lt,foundationBreadcrumbItem:mt,foundationButton:wt,foundationCalendar:kt,foundationCard:At,foundationCategorizedMultiselect:Ut,foundationCheckbox:Yt,foundationCombobox:fi,foundationConnectionIndicator:xi,foundationDataGrid:Ti,foundationDataGridCell:Ni,foundationDataGridRow:Hi,foundationDatePicker:lo,foundationDesignSystemProvider:sn,foundationDialog:fn,foundationDisclosure:$n,foundationDivider:In,foundationDropdownMenu:Mn,foundationErrorBanner:ta,foundationErrorBoundary:va,foundationErrorDialog:Ca,foundationFileReader:Ta,foundationFileUpload:Ga,foundationFilter:ts,foundationFilterBar:cs,foundationFlexLayout:bs,foundationFlipper:Ss,foundationFlyout:As,foundationGridLayout:Us,foundationGridLayoutItem:Vs,foundationHorizontalScroll:Js,foundationIcon:mr,foundationListbox:wr,foundationListboxOption:kr,foundationMenu:Ar,foundationMenuItem:Hr,foundationModal:Gr,foundationMultiselect:Zr,foundationNumberField:vl,foundationOptgroup:yl,foundationPopper:rd,foundationProgress:jl,foundationProgressRing:pd,foundationRadio:yd,foundationRadioGroup:Ed,foundationScheduler:Ad,foundationSchedulerCronBuilder:$c,foundationSchedulerTimezone:Dc,foundationSearchBar:Wc,foundationSearchBarCombobox:Kc,foundationSegmentedControl:hu,foundationSegmentedItem:bu,foundationSelect:Su,foundationSkeleton:Du,foundationSlider:Hu,foundationSliderLabel:Gu,foundationSnackbar:eh,foundationStackingIcons:nh,foundationStatusPill:dh,foundationEnvironmentIndicator:Xn,foundationStepperTab:gh,foundationStepperTabPanel:Ch,foundationSwitch:Oh,foundationSystemHealthOverlay:td,foundationTab:Nh,foundationTabPanel:Ph,foundationTabs:jh,foundationTextArea:Qh,foundationTextField:ap,foundationToast:hp,foundationToolbar:bp,foundationTooltip:Sp,foundationTreeItem:Dp,foundationTreeView:Mp,foundationUrlInput:Wp,foundationSectionNavigator:su,register(e,...t){if(e)for(const i in this)"register"!==i&&this[i]().register(e,...t)}};class jp extends l.CSSDirective{constructor(e){super(),this.tokenMap=e}createTokenPartial(e,t){return l.cssPartial`${e}: ${t}`}createTokensCSS(){const e=[];for(const[t,i]of Object.entries(this.tokenMap))e.push(this.createTokenPartial(t,i).createCSS());return e}createCSS(){return this.createTokensCSS().join(";")}}let Vp=class extends si{constructor(){super(...arguments),this.isSnapshot=!0}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){e.connectedCallback.call(this),this.dataGrid=this.parentElement,this.dataGrid&&this.resourceName&&this.connect.isConnected&&this.fetchGenesisData()})}getColumnDefs(e){return null==e?void 0:e.flatMap(e=>this.fields&&!this.fields.includes(e.name)?[]:{columnDataKey:e.name})}clearData(){Xe.debug("clearData - Method not implemented.")}syncComponentData(e){const t=null!=e?e:Array.from(this.rowsSyncedWithStream.values()),i=this.getColumnDefs(this.datasource.fieldMetadata);this.dataGrid.columnDefinitions=i,this.dataGrid.rowsData=t}handleStreamInserts(e){Xe.debug("handleStreamInserts - Method not implemented.")}handleStreamDeletes(e){Xe.debug("handleStreamDeletes - Method not implemented.")}handleStreamUpdates(e){Xe.debug("handleStreamUpdates - Method not implemented.")}};Vp=(0,C.Cg)([(0,l.customElement)({name:"data-grid-datasource"})],Vp);const Yp=[{type:"AND",maxRules:"many"},{type:"OR",maxRules:"many"}],qp=[...Yp,{type:"NOT",maxRules:2},{type:"NAND",maxRules:"many"},{type:"NOR",maxRules:"many"},{type:"XOR",maxRules:2}],Kp={type:"NULL",maxRules:1,invisible:!0},Xp=["int","short","long","bigdecimal","double"],Qp=["date","date-time"],Jp=["enum",...Xp,"string",...Qp,"boolean"],Zp=[{type:"equal",nbInputs:1,applyTo:Jp,optgroup:"Equality"},{type:"not_equal",nbInputs:1,applyTo:Jp,optgroup:"Equality"},{type:"greater",nbInputs:1,applyTo:[...Xp,...Qp],optgroup:"Comparison"},{type:"less",nbInputs:1,applyTo:[...Xp,...Qp],optgroup:"Comparison"},{type:"contains",nbInputs:1,applyTo:["string"],optgroup:"String"},{type:"starts_with",nbInputs:1,applyTo:["string"],optgroup:"String"},{type:"ends_with",nbInputs:1,applyTo:["string"],optgroup:"String"},{type:"one_of",nbInputs:"many",applyTo:[...Jp].filter(e=>"boolean"!==e)},{type:"not_any_of",nbInputs:"many",applyTo:[...Jp].filter(e=>"boolean"!==e)},{type:"within_inclusive",nbInputs:2,applyTo:[...Xp,...Qp],optgroup:"Range"},{type:"within_exclusive",nbInputs:2,applyTo:[...Xp,...Qp],optgroup:"Range"},{type:"is_null",nbInputs:0,applyTo:[...Jp],optgroup:"Null"},{type:"not_null",nbInputs:0,applyTo:[...Jp],optgroup:"Null"}];var em=i(93678);const tm=i.n(em)()();function im(e,t,i){const o=function e(o){const n=tm(o);if(n.groupId===t)return n.children=i(n.children),n;const a=[];let s=!1;for(const t of n.children)if("children"in t){const i=e(t);i?(a.push(i),s=!0):a.push(t)}else a.push(t);return n.children=a,s?n:null}(e);if(!o)throw new Error(`Unable to find group with groupId ${t}`);return o}function om(e,t,i){return function e(o){for(const n of o.children){if(i(n,t))return o;if("children"in n){const t=e(n);if(t)return t}}return null}(e)}function nm(e,t){const i=om(e,t,(e,t)=>"children"in e&&e.groupId===t);if(!i)throw new Error(`No parent group found for group with ID ${t}`);return i}function am(e,t){const i=om(e,t,(e,t)=>"ruleId"in e&&e.ruleId===t);if(!i)throw new Error(`No parent group found for rule with ID ${t}`);return i}function sm(e,t,i){return im(e,t,e=>[...e,i])}const rm="group-root";function lm(e,t){const i=(e,o)=>{return"children"in e?function(e,o){return Object.assign(Object.assign({},e),{level:o,config:t.getConfig(),groupId:t.getGroupId(),children:e.children.map(e=>i(e,o+1))})}(e,o):(n=e,Object.assign(Object.assign({},n),{ruleId:t.getRuleId(),config:t.getConfig()}));var n};return Object.assign(Object.assign({},e),{config:t.getConfig(),level:1,groupId:rm,children:e.children.map(e=>i(e,2))})}function dm(e){const t=e.children.map(e=>"children"in e?dm(e):function(e){const{operator:t,field:i,value:o}=e;return{operator:t,field:i,value:o}}(e));return{combinator:e.combinator,children:t}}const cm=e=>`${e.getUTCFullYear()}-${String(e.getUTCMonth()+1).padStart(2,"0")}-${String(e.getUTCDate()).padStart(2,"0")}`,um=e=>`${cm(e)}T${String(e.getUTCHours()).padStart(2,"0")}:${String(e.getUTCMinutes()).padStart(2,"0")}:${String(e.getUTCSeconds()).padStart(2,"0")}`,hm=e=>{var t,i,o;return null!==(o=null===(i=null===(t=e.operator)||void 0===t?void 0:t.valueType)||void 0===i?void 0:i.input)&&void 0!==o?o:e.field.input},pm=e=>{var t,i,o;return null!==(o=null===(i=null===(t=e.operator)||void 0===t?void 0:t.valueType)||void 0===i?void 0:i.type)&&void 0!==o?o:e.field.type},mm=e=>{const t={},i=[],o=e=>[...e].sort((e,t)=>"fieldId"in e&&"fieldId"in t?e.fieldId.localeCompare(t.fieldId):"type"in e&&"type"in t?e.type.localeCompare(t.type):0);e.forEach(e=>{if(e.optgroup){const i=e.optgroup;t[i]||(t[i]=[]),t[i].push(e)}else i.push(e)});const n=[];return Object.keys(t).sort().forEach(e=>{n.push({optgroup:e,xs:o(t[e])})}),[...n,...o(i)]};function vm(e,t,i){if(!e.shadowRoot||!(null==t?void 0:t.customStyles))return;const o=t.customStyles[i];if(o){const t=document.createElement("style");t.textContent=o,e.shadowRoot.firstChild?e.shadowRoot.insertBefore(t,e.shadowRoot.firstChild):e.shadowRoot.appendChild(t)}}var gm;!function(e){e.AddGroup="add-group",e.DelGroup="del-group",e.AddRule="add-rule",e.DelRule="del-rule",e.UpdateGroup="update-group",e.UpdateRule="update-rule",e.FieldSelected="field-selected",e.OperatorSelected="operator-selected",e.ValueUpdated="value-updated",e.RemoveVarArg="remove-variadic-operand"}(gm||(gm={}));const fm=l.css`
5484
+ `,zp=void 0,Up={};class Wp extends r.TextField{constructor(){super(...arguments),this.value=""}saveUrl(e){this.value=e.startsWith("http")?e:"https://"+e,this.focused=!1}focus(){this.focused=!0}}(0,C.Cg)([l.observable],Wp.prototype,"value",void 0),(0,C.Cg)([l.observable],Wp.prototype,"focused",void 0);const Gp=Wp.compose(Object.assign({baseName:"url-input",template:Pp,styles:_p,shadowOptions:zp},Up)),Bp={foundationAccordion:m,foundationAiCriteriaSearch:ye,foundationAiIndicator:$e,foundationAccordionItem:w,foundationActionsMenu:D,foundationAnchor:Ie,foundationAnchoredRegion:Fe,foundationAvatar:We,foundationBadge:qe,foundationBanner:it,foundationBreadcrumb:lt,foundationBreadcrumbItem:mt,foundationButton:wt,foundationCalendar:kt,foundationCard:Dt,foundationCategorizedMultiselect:Ut,foundationCheckbox:Yt,foundationCombobox:fi,foundationConnectionIndicator:xi,foundationDataGrid:Ti,foundationDataGridCell:Ni,foundationDataGridRow:Hi,foundationDatePicker:lo,foundationDesignSystemProvider:an,foundationDialog:fn,foundationDisclosure:$n,foundationDivider:In,foundationDropdownMenu:Mn,foundationErrorBanner:ts,foundationErrorBoundary:gs,foundationErrorDialog:Cs,foundationFileReader:Ts,foundationFileUpload:Bs,foundationFilter:ta,foundationFilterBar:ca,foundationFlexLayout:ba,foundationFlipper:Sa,foundationFlyout:Da,foundationGridLayout:Ua,foundationGridLayoutItem:ja,foundationHorizontalScroll:Ja,foundationIcon:mr,foundationListbox:wr,foundationListboxOption:kr,foundationMenu:Dr,foundationMenuItem:Hr,foundationModal:Br,foundationMultiselect:Zr,foundationNumberField:gl,foundationOptgroup:yl,foundationPopper:rd,foundationProgress:Vl,foundationProgressRing:pd,foundationRadio:yd,foundationRadioGroup:Ed,foundationScheduler:Dd,foundationSchedulerCronBuilder:$c,foundationSchedulerTimezone:Rc,foundationSearchBar:Gc,foundationSearchBarCombobox:Kc,foundationSegmentedControl:hu,foundationSegmentedItem:bu,foundationSelect:Su,foundationSkeleton:Ru,foundationSlider:Hu,foundationSliderLabel:Bu,foundationSnackbar:eh,foundationStackingIcons:nh,foundationStatusPill:dh,foundationEnvironmentIndicator:Xn,foundationStepperTab:vh,foundationStepperTabPanel:Ch,foundationSwitch:Oh,foundationSystemHealthOverlay:td,foundationTab:Nh,foundationTabPanel:Ph,foundationTabs:Vh,foundationTextArea:Qh,foundationTextField:sp,foundationToast:hp,foundationToolbar:bp,foundationTooltip:Sp,foundationTreeItem:Rp,foundationTreeView:Mp,foundationUrlInput:Gp,foundationSectionNavigator:au,register(e,...t){if(e)for(const i in this)"register"!==i&&this[i]().register(e,...t)}};class Vp extends l.CSSDirective{constructor(e){super(),this.tokenMap=e}createTokenPartial(e,t){return l.cssPartial`${e}: ${t}`}createTokensCSS(){const e=[];for(const[t,i]of Object.entries(this.tokenMap))e.push(this.createTokenPartial(t,i).createCSS());return e}createCSS(){return this.createTokensCSS().join(";")}}let jp=class extends ai{constructor(){super(...arguments),this.isSnapshot=!0}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){e.connectedCallback.call(this),this.dataGrid=this.parentElement,this.dataGrid&&this.resourceName&&this.connect.isConnected&&this.fetchGenesisData()})}getColumnDefs(e){return null==e?void 0:e.flatMap(e=>this.fields&&!this.fields.includes(e.name)?[]:{columnDataKey:e.name})}clearData(){Xe.debug("clearData - Method not implemented.")}syncComponentData(e){const t=null!=e?e:Array.from(this.rowsSyncedWithStream.values()),i=this.getColumnDefs(this.datasource.fieldMetadata);this.dataGrid.columnDefinitions=i,this.dataGrid.rowsData=t}handleStreamInserts(e){Xe.debug("handleStreamInserts - Method not implemented.")}handleStreamDeletes(e){Xe.debug("handleStreamDeletes - Method not implemented.")}handleStreamUpdates(e){Xe.debug("handleStreamUpdates - Method not implemented.")}};jp=(0,C.Cg)([(0,l.customElement)({name:"data-grid-datasource"})],jp);const Yp=[{type:"AND",maxRules:"many"},{type:"OR",maxRules:"many"}],qp=[...Yp,{type:"NOT",maxRules:2},{type:"NAND",maxRules:"many"},{type:"NOR",maxRules:"many"},{type:"XOR",maxRules:2}],Kp={type:"NULL",maxRules:1,invisible:!0},Xp=["int","short","long","bigdecimal","double"],Qp=["date","date-time"],Jp=["enum",...Xp,"string",...Qp,"boolean"],Zp=[{type:"equal",nbInputs:1,applyTo:Jp,optgroup:"Equality"},{type:"not_equal",nbInputs:1,applyTo:Jp,optgroup:"Equality"},{type:"greater",nbInputs:1,applyTo:[...Xp,...Qp],optgroup:"Comparison"},{type:"less",nbInputs:1,applyTo:[...Xp,...Qp],optgroup:"Comparison"},{type:"contains",nbInputs:1,applyTo:["string"],optgroup:"String"},{type:"starts_with",nbInputs:1,applyTo:["string"],optgroup:"String"},{type:"ends_with",nbInputs:1,applyTo:["string"],optgroup:"String"},{type:"one_of",nbInputs:"many",applyTo:[...Jp].filter(e=>"boolean"!==e)},{type:"not_any_of",nbInputs:"many",applyTo:[...Jp].filter(e=>"boolean"!==e)},{type:"within_inclusive",nbInputs:2,applyTo:[...Xp,...Qp],optgroup:"Range"},{type:"within_exclusive",nbInputs:2,applyTo:[...Xp,...Qp],optgroup:"Range"},{type:"is_null",nbInputs:0,applyTo:[...Jp],optgroup:"Null"},{type:"not_null",nbInputs:0,applyTo:[...Jp],optgroup:"Null"}];var em=i(93678);const tm=i.n(em)()();function im(e,t,i){const o=function e(o){const n=tm(o);if(n.groupId===t)return n.children=i(n.children),n;const s=[];let a=!1;for(const t of n.children)if("children"in t){const i=e(t);i?(s.push(i),a=!0):s.push(t)}else s.push(t);return n.children=s,a?n:null}(e);if(!o)throw new Error(`Unable to find group with groupId ${t}`);return o}function om(e,t,i){return function e(o){for(const n of o.children){if(i(n,t))return o;if("children"in n){const t=e(n);if(t)return t}}return null}(e)}function nm(e,t){const i=om(e,t,(e,t)=>"children"in e&&e.groupId===t);if(!i)throw new Error(`No parent group found for group with ID ${t}`);return i}function sm(e,t){const i=om(e,t,(e,t)=>"ruleId"in e&&e.ruleId===t);if(!i)throw new Error(`No parent group found for rule with ID ${t}`);return i}function am(e,t,i){return im(e,t,e=>[...e,i])}const rm="group-root";function lm(e,t){const i=(e,o)=>{return"children"in e?function(e,o){return Object.assign(Object.assign({},e),{level:o,config:t.getConfig(),groupId:t.getGroupId(),children:e.children.map(e=>i(e,o+1))})}(e,o):(n=e,Object.assign(Object.assign({},n),{ruleId:t.getRuleId(),config:t.getConfig()}));var n};return Object.assign(Object.assign({},e),{config:t.getConfig(),level:1,groupId:rm,children:e.children.map(e=>i(e,2))})}function dm(e){const t=e.children.map(e=>"children"in e?dm(e):function(e){const{operator:t,field:i,value:o}=e;return{operator:t,field:i,value:o}}(e));return{combinator:e.combinator,children:t}}const cm=e=>`${e.getUTCFullYear()}-${String(e.getUTCMonth()+1).padStart(2,"0")}-${String(e.getUTCDate()).padStart(2,"0")}`,um=e=>`${cm(e)}T${String(e.getUTCHours()).padStart(2,"0")}:${String(e.getUTCMinutes()).padStart(2,"0")}:${String(e.getUTCSeconds()).padStart(2,"0")}`,hm=e=>{var t,i,o;return null!==(o=null===(i=null===(t=e.operator)||void 0===t?void 0:t.valueType)||void 0===i?void 0:i.input)&&void 0!==o?o:e.field.input},pm=e=>{var t,i,o;return null!==(o=null===(i=null===(t=e.operator)||void 0===t?void 0:t.valueType)||void 0===i?void 0:i.type)&&void 0!==o?o:e.field.type},mm=e=>{const t={},i=[],o=e=>[...e].sort((e,t)=>"fieldId"in e&&"fieldId"in t?e.fieldId.localeCompare(t.fieldId):"type"in e&&"type"in t?e.type.localeCompare(t.type):0);e.forEach(e=>{if(e.optgroup){const i=e.optgroup;t[i]||(t[i]=[]),t[i].push(e)}else i.push(e)});const n=[];return Object.keys(t).sort().forEach(e=>{n.push({optgroup:e,xs:o(t[e])})}),[...n,...o(i)]};function gm(e,t,i){if(!e.shadowRoot||!(null==t?void 0:t.customStyles))return;const o=t.customStyles[i];if(o){const t=document.createElement("style");t.textContent=o,e.shadowRoot.firstChild?e.shadowRoot.insertBefore(t,e.shadowRoot.firstChild):e.shadowRoot.appendChild(t)}}var vm;!function(e){e.AddGroup="add-group",e.DelGroup="del-group",e.AddRule="add-rule",e.DelRule="del-rule",e.UpdateGroup="update-group",e.UpdateRule="update-rule",e.FieldSelected="field-selected",e.OperatorSelected="operator-selected",e.ValueUpdated="value-updated",e.RemoveVarArg="remove-variadic-operand"}(vm||(vm={}));const fm=l.css`
5485
5485
  :host {
5486
5486
  --item-vertical-spacing: 4px;
5487
5487
  --item-border-radius: 5px;
@@ -5698,11 +5698,11 @@
5698
5698
  list-style: none;
5699
5699
  padding-left: 0;
5700
5700
  }
5701
- `;function ym(e,t,i){const o=e=>"function"==typeof e?e:()=>e,n=o(t),a=o(i);return(t,i)=>e(t,i)?n(t,i):a(t,i)}const wm=l.html`
5702
- ${e=>{var t,i;const o=null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.radio,{radioTag:n,radioGroupTag:a}=o?{radioTag:o.input,radioGroupTag:o.group}:{radioTag:"input",radioGroupTag:"div"};return l.html`
5701
+ `;function ym(e,t,i){const o=e=>"function"==typeof e?e:()=>e,n=o(t),s=o(i);return(t,i)=>e(t,i)?n(t,i):s(t,i)}const wm=l.html`
5702
+ ${e=>{var t,i;const o=null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.radio,{radioTag:n,radioGroupTag:s}=o?{radioTag:o.input,radioGroupTag:o.group}:{radioTag:"input",radioGroupTag:"div"};return l.html`
5703
5703
  <div class="btn-group group-conditions">
5704
5704
  ${ym(e=>"input"!==n,l.html`
5705
- <${a}
5705
+ <${s}
5706
5706
  class="radio-group-container"
5707
5707
  name="combinator"
5708
5708
  @change="${(e,t)=>e.handleCombinatorChange(t.event)}"
@@ -5718,7 +5718,7 @@
5718
5718
  </${n}>
5719
5719
  `)}
5720
5720
  `)}
5721
- </${a}>
5721
+ </${s}>
5722
5722
  `,l.html`
5723
5723
  <div class="radio-group-container">
5724
5724
  ${(0,l.repeat)(e=>e.config.combinators,l.html`
@@ -5740,7 +5740,7 @@
5740
5740
  </div>
5741
5741
  `}}
5742
5742
  `,Cm=l.html`
5743
- ${e=>{var t,i,o,n,a,s,r,d;const c=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.button)||"button",u=`Add a new condition with field (e.g. CURRENCY), operator (e.g. EQUALS), and value (e.g. GBP) that will be combined with other conditions in this group using the selected logic (e.g. ${null===(a=null===(n=null===(o=e.config)||void 0===o?void 0:o.combinators)||void 0===n?void 0:n[0])||void 0===a?void 0:a.type})`,h=`Add a new nested sub-group to create more complex expressions, joined by combinatorial logic (e.g. ${null===(d=null===(r=null===(s=e.config)||void 0===s?void 0:s.combinators)||void 0===r?void 0:r[0])||void 0===d?void 0:d.type})`;return l.html`
5743
+ ${e=>{var t,i,o,n,s,a,r,d;const c=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.button)||"button",u=`Add a new condition with field (e.g. CURRENCY), operator (e.g. EQUALS), and value (e.g. GBP) that will be combined with other conditions in this group using the selected logic (e.g. ${null===(s=null===(n=null===(o=e.config)||void 0===o?void 0:o.combinators)||void 0===n?void 0:n[0])||void 0===s?void 0:s.type})`,h=`Add a new nested sub-group to create more complex expressions, joined by combinatorial logic (e.g. ${null===(d=null===(r=null===(a=e.config)||void 0===a?void 0:a.combinators)||void 0===r?void 0:r[0])||void 0===d?void 0:d.type})`;return l.html`
5744
5744
  <div class="btn-group float-end group-actions">
5745
5745
  ${(0,l.when)(e=>e.allowAddRule,l.html`
5746
5746
  <${c}
@@ -5806,7 +5806,7 @@
5806
5806
  </div>
5807
5807
  </div>
5808
5808
  </div>
5809
- `;let $m=class extends l.FASTElement{connectedCallback(){super.connectedCallback(),vm(this,this.styles,"group")}get allowAddRule(){return!!this.model&&("many"===this.model.combinator.maxRules||this.model.children.length<this.model.combinator.maxRules)}get allowAddGroup(){var e,t;return!!this.model&&(1!==this.model.combinator.maxRules&&(!(2===this.model.combinator.maxRules&&this.model.children.length>=2)&&(!(null===(e=this.config)||void 0===e?void 0:e.maxNesting)||(null===(t=this.config)||void 0===t?void 0:t.maxNesting)<1||this.config.maxNesting>this.model.level)))}dispatchAddRule(e){if(e.stopPropagation(),!this.allowAddRule)throw new Error("Cannot add extra rules to group");const t={parentGroupId:this.model.groupId};this.dispatchEvent(new CustomEvent(gm.AddRule,{detail:t,bubbles:!0,composed:!0}))}dispatchAddGroup(e){if(e.stopPropagation(),!this.allowAddGroup)throw new Error("Cannot add further nested groups");const t={parentGroupId:this.model.groupId,newGroup:{level:this.model.level+1}};this.dispatchEvent(new CustomEvent(gm.AddGroup,{detail:t,bubbles:!0,composed:!0}))}dispatchDeleteGroup(e){e.stopPropagation();const t={groupId:this.model.groupId};this.dispatchEvent(new CustomEvent(gm.DelGroup,{detail:t,bubbles:!0,composed:!0}))}handleCombinatorChange(e){e.stopPropagation();const t=e.target.value;this.updateCombinator(t)}handleCustomCombinatorChange(e){var t;if(e.stopPropagation(),!(null===(t=this.model)||void 0===t?void 0:t.groupId)||!e.target)return;const i=e.target.getAttribute("value");if(!i)throw new Error("No value found in the custom radio group event target");this.updateCombinator(i)}updateCombinator(e){var t,i;const o=this.config.combinators.find(({type:t})=>t===e);if(!o)throw new Error(`Cannot find selected combinator ${e}`);(null===(i=null===(t=this.model)||void 0===t?void 0:t.combinator)||void 0===i?void 0:i.type)!==o.type&&this.dispatchGroupDataUpdated(o)}dispatchGroupDataUpdated(e){const t={groupId:this.model.groupId,newData:{combinator:e}};this.dispatchEvent(new CustomEvent(gm.UpdateGroup,{detail:t,bubbles:!0,composed:!0}))}};(0,C.Cg)([l.observable],$m.prototype,"config",void 0),(0,C.Cg)([l.observable],$m.prototype,"styles",void 0),(0,C.Cg)([l.observable],$m.prototype,"model",void 0),(0,C.Cg)([l.observable],$m.prototype,"index",void 0),(0,C.Cg)([l.volatile],$m.prototype,"allowAddRule",null),(0,C.Cg)([l.volatile],$m.prototype,"allowAddGroup",null),$m=(0,C.Cg)([(0,l.customElement)({name:"expression-group",template:xm,styles:bm,shadowOptions:{delegatesFocus:!0}})],$m);const Sm=l.html`
5809
+ `;let $m=class extends l.FASTElement{connectedCallback(){super.connectedCallback(),gm(this,this.styles,"group")}get allowAddRule(){return!!this.model&&("many"===this.model.combinator.maxRules||this.model.children.length<this.model.combinator.maxRules)}get allowAddGroup(){var e,t;return!!this.model&&(1!==this.model.combinator.maxRules&&(!(2===this.model.combinator.maxRules&&this.model.children.length>=2)&&(!(null===(e=this.config)||void 0===e?void 0:e.maxNesting)||(null===(t=this.config)||void 0===t?void 0:t.maxNesting)<1||this.config.maxNesting>this.model.level)))}dispatchAddRule(e){if(e.stopPropagation(),!this.allowAddRule)throw new Error("Cannot add extra rules to group");const t={parentGroupId:this.model.groupId};this.dispatchEvent(new CustomEvent(vm.AddRule,{detail:t,bubbles:!0,composed:!0}))}dispatchAddGroup(e){if(e.stopPropagation(),!this.allowAddGroup)throw new Error("Cannot add further nested groups");const t={parentGroupId:this.model.groupId,newGroup:{level:this.model.level+1}};this.dispatchEvent(new CustomEvent(vm.AddGroup,{detail:t,bubbles:!0,composed:!0}))}dispatchDeleteGroup(e){e.stopPropagation();const t={groupId:this.model.groupId};this.dispatchEvent(new CustomEvent(vm.DelGroup,{detail:t,bubbles:!0,composed:!0}))}handleCombinatorChange(e){e.stopPropagation();const t=e.target.value;this.updateCombinator(t)}handleCustomCombinatorChange(e){var t;if(e.stopPropagation(),!(null===(t=this.model)||void 0===t?void 0:t.groupId)||!e.target)return;const i=e.target.getAttribute("value");if(!i)throw new Error("No value found in the custom radio group event target");this.updateCombinator(i)}updateCombinator(e){var t,i;const o=this.config.combinators.find(({type:t})=>t===e);if(!o)throw new Error(`Cannot find selected combinator ${e}`);(null===(i=null===(t=this.model)||void 0===t?void 0:t.combinator)||void 0===i?void 0:i.type)!==o.type&&this.dispatchGroupDataUpdated(o)}dispatchGroupDataUpdated(e){const t={groupId:this.model.groupId,newData:{combinator:e}};this.dispatchEvent(new CustomEvent(vm.UpdateGroup,{detail:t,bubbles:!0,composed:!0}))}};(0,C.Cg)([l.observable],$m.prototype,"config",void 0),(0,C.Cg)([l.observable],$m.prototype,"styles",void 0),(0,C.Cg)([l.observable],$m.prototype,"model",void 0),(0,C.Cg)([l.observable],$m.prototype,"index",void 0),(0,C.Cg)([l.volatile],$m.prototype,"allowAddRule",null),(0,C.Cg)([l.volatile],$m.prototype,"allowAddGroup",null),$m=(0,C.Cg)([(0,l.customElement)({name:"expression-group",template:xm,styles:bm,shadowOptions:{delegatesFocus:!0}})],$m);const Sm=l.html`
5810
5810
  <div class="query-builder">
5811
5811
  ${(0,l.when)(e=>null!==e.model,l.html`
5812
5812
  <expression-group
@@ -5817,7 +5817,7 @@
5817
5817
  `)}
5818
5818
  </div>
5819
5819
  `,Em=l.html`
5820
- ${e=>{var t,i,o,n,a,s;const r=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.select)||"select",d=(null===(n=null===(o=e.styles)||void 0===o?void 0:o.customElements)||void 0===n?void 0:n.option)||"option",c=(null===(s=null===(a=e.styles)||void 0===a?void 0:a.customElements)||void 0===s?void 0:s.optgroup)||"optgroup";return l.html`
5820
+ ${e=>{var t,i,o,n,s,a;const r=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.select)||"select",d=(null===(n=null===(o=e.styles)||void 0===o?void 0:o.customElements)||void 0===n?void 0:n.option)||"option",c=(null===(a=null===(s=e.styles)||void 0===s?void 0:s.customElements)||void 0===a?void 0:a.optgroup)||"optgroup";return l.html`
5821
5821
  <${r}
5822
5822
  class="form-select"
5823
5823
  @change=${(e,t)=>e.dispatchFieldsChanged(t.event)}
@@ -5847,8 +5847,8 @@
5847
5847
  `)}
5848
5848
  </${r}>
5849
5849
  `}}
5850
- `;let km=class extends l.FASTElement{constructor(){super(...arguments),this.fields=[]}connectedCallback(){super.connectedCallback(),vm(this,this.styles,"field")}get groupedFieldss(){return mm(this.fields)}dispatchFieldsChanged(e){e.stopPropagation();const t={fieldId:e.target.value};this.dispatchEvent(new CustomEvent(gm.FieldSelected,{detail:t,bubbles:!0,composed:!0}))}};(0,C.Cg)([l.observable],km.prototype,"fields",void 0),(0,C.Cg)([l.observable],km.prototype,"field",void 0),(0,C.Cg)([l.observable],km.prototype,"config",void 0),(0,C.Cg)([l.observable],km.prototype,"styles",void 0),(0,C.Cg)([l.volatile],km.prototype,"groupedFieldss",null),km=(0,C.Cg)([(0,l.customElement)({name:"expression-rule-field",template:Em})],km);const Om=l.html`
5851
- ${e=>{var t,i,o,n,a,s;const r=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.select)||"select",d=(null===(n=null===(o=e.styles)||void 0===o?void 0:o.customElements)||void 0===n?void 0:n.option)||"option",c=(null===(s=null===(a=e.styles)||void 0===a?void 0:a.customElements)||void 0===s?void 0:s.optgroup)||"optgroup";return l.html`
5850
+ `;let km=class extends l.FASTElement{constructor(){super(...arguments),this.fields=[]}connectedCallback(){super.connectedCallback(),gm(this,this.styles,"field")}get groupedFieldss(){return mm(this.fields)}dispatchFieldsChanged(e){e.stopPropagation();const t={fieldId:e.target.value};this.dispatchEvent(new CustomEvent(vm.FieldSelected,{detail:t,bubbles:!0,composed:!0}))}};(0,C.Cg)([l.observable],km.prototype,"fields",void 0),(0,C.Cg)([l.observable],km.prototype,"field",void 0),(0,C.Cg)([l.observable],km.prototype,"config",void 0),(0,C.Cg)([l.observable],km.prototype,"styles",void 0),(0,C.Cg)([l.volatile],km.prototype,"groupedFieldss",null),km=(0,C.Cg)([(0,l.customElement)({name:"expression-rule-field",template:Em})],km);const Om=l.html`
5851
+ ${e=>{var t,i,o,n,s,a;const r=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.select)||"select",d=(null===(n=null===(o=e.styles)||void 0===o?void 0:o.customElements)||void 0===n?void 0:n.option)||"option",c=(null===(a=null===(s=e.styles)||void 0===s?void 0:s.customElements)||void 0===a?void 0:a.optgroup)||"optgroup";return l.html`
5852
5852
  <${r}
5853
5853
  class="form-select"
5854
5854
  @change=${(e,t)=>e.handleOperatorChange(t.event)}
@@ -5880,7 +5880,7 @@
5880
5880
  `)}
5881
5881
  </${r}>
5882
5882
  `}}
5883
- `;let Tm=class extends l.FASTElement{constructor(){super(...arguments),this.operators=[],this.field=null}connectedCallback(){super.connectedCallback(),vm(this,this.styles,"operator")}get allowedOperators(){const e=e=>{var t,i,o;return null===(o=null===(i=null===(t=this.field)||void 0===t?void 0:t.operators)||void 0===i?void 0:i.includes(e.type))||void 0===o||o},t=e=>{var t,i,o,n;return null===(n=null===(i=null===(t=null==e?void 0:e.applyTo)||void 0===t?void 0:t.includes)||void 0===i?void 0:i.call(t,null===(o=this.field)||void 0===o?void 0:o.type))||void 0===n||n};return this.operators.filter(i=>e(i)&&t(i))}get groupedOperators(){return mm(this.allowedOperators)}handleOperatorChange(e){e.stopPropagation();const t={operatorId:e.target.value};this.dispatchEvent(new CustomEvent(gm.OperatorSelected,{detail:t,bubbles:!0,composed:!0}))}};(0,C.Cg)([l.observable],Tm.prototype,"operators",void 0),(0,C.Cg)([l.observable],Tm.prototype,"operator",void 0),(0,C.Cg)([l.observable],Tm.prototype,"field",void 0),(0,C.Cg)([l.observable],Tm.prototype,"config",void 0),(0,C.Cg)([l.observable],Tm.prototype,"styles",void 0),(0,C.Cg)([l.volatile],Tm.prototype,"allowedOperators",null),(0,C.Cg)([l.volatile],Tm.prototype,"groupedOperators",null),Tm=(0,C.Cg)([(0,l.customElement)({name:"expression-rule-operator",template:Om})],Tm);const Im=e=>["short","int","long"].includes(e),Dm=e=>["double","bigdecimal"].includes(e),Rm=(e,t)=>{var i,o;return null===(o=null===(i=(e=>Im(e)?/^[+-]?[0-9]+$/:Dm(e)?/[+-]?([0-9]*[.])?[0-9]+/:null)(e))||void 0===i?void 0:i.test(t))||void 0===o||o?null:"Invalid number format"},Am=l.css`
5883
+ `;let Tm=class extends l.FASTElement{constructor(){super(...arguments),this.operators=[],this.field=null}connectedCallback(){super.connectedCallback(),gm(this,this.styles,"operator")}get allowedOperators(){const e=e=>{var t,i,o;return null===(o=null===(i=null===(t=this.field)||void 0===t?void 0:t.operators)||void 0===i?void 0:i.includes(e.type))||void 0===o||o},t=e=>{var t,i,o,n;return null===(n=null===(i=null===(t=null==e?void 0:e.applyTo)||void 0===t?void 0:t.includes)||void 0===i?void 0:i.call(t,null===(o=this.field)||void 0===o?void 0:o.type))||void 0===n||n};return this.operators.filter(i=>e(i)&&t(i))}get groupedOperators(){return mm(this.allowedOperators)}handleOperatorChange(e){e.stopPropagation();const t={operatorId:e.target.value};this.dispatchEvent(new CustomEvent(vm.OperatorSelected,{detail:t,bubbles:!0,composed:!0}))}};(0,C.Cg)([l.observable],Tm.prototype,"operators",void 0),(0,C.Cg)([l.observable],Tm.prototype,"operator",void 0),(0,C.Cg)([l.observable],Tm.prototype,"field",void 0),(0,C.Cg)([l.observable],Tm.prototype,"config",void 0),(0,C.Cg)([l.observable],Tm.prototype,"styles",void 0),(0,C.Cg)([l.volatile],Tm.prototype,"allowedOperators",null),(0,C.Cg)([l.volatile],Tm.prototype,"groupedOperators",null),Tm=(0,C.Cg)([(0,l.customElement)({name:"expression-rule-operator",template:Om})],Tm);const Im=e=>["short","int","long"].includes(e),Rm=e=>["double","bigdecimal"].includes(e),Am=(e,t)=>{var i,o;return null===(o=null===(i=(e=>Im(e)?/^[+-]?[0-9]+$/:Rm(e)?/[+-]?([0-9]*[.])?[0-9]+/:null)(e))||void 0===i?void 0:i.test(t))||void 0===o||o?null:"Invalid number format"},Dm=l.css`
5884
5884
  .text-input.error {
5885
5885
  color: red;
5886
5886
  }
@@ -5890,8 +5890,8 @@
5890
5890
  align-items: center;
5891
5891
  }
5892
5892
  `,Nm=l.html`
5893
- ${e=>{var t,i;const o=hm(e),n="datetime-local"===o?"datetimeLocal":o,a=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i[n])||"input";return l.html`
5894
- <${a}
5893
+ ${e=>{var t,i;const o=hm(e),n="datetime-local"===o?"datetimeLocal":o,s=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i[n])||"input";return l.html`
5894
+ <${s}
5895
5895
  type="${o}"
5896
5896
  class="text-input ${e=>(0,x.x)(["error",e.validationError])}"
5897
5897
  value=${e=>e.value}
@@ -5899,22 +5899,22 @@
5899
5899
  />
5900
5900
  `}}
5901
5901
  `,Lm=l.html`
5902
- ${e=>{var t,i,o,n;const a=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.select)||"select",s=(null===(n=null===(o=e.styles)||void 0===o?void 0:o.customElements)||void 0===n?void 0:n.option)||"option";return l.html`
5903
- <${a}
5902
+ ${e=>{var t,i,o,n;const s=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.select)||"select",a=(null===(n=null===(o=e.styles)||void 0===o?void 0:o.customElements)||void 0===n?void 0:n.option)||"option";return l.html`
5903
+ <${s}
5904
5904
  class="form-select"
5905
5905
  @change=${(e,t)=>e.handleInputChange(t.event)}
5906
5906
  value=${e=>e.value}
5907
5907
  >
5908
- ${(0,l.repeat)(e=>{var t,i,o,n;const a="enum"===(null===(i=null===(t=e.operator)||void 0===t?void 0:t.valueType)||void 0===i?void 0:i.type)&&(null===(n=null===(o=null==e?void 0:e.operator)||void 0===o?void 0:o.valueType)||void 0===n?void 0:n.values)?e.operator.valueType.values:"enum"===e.field.type&&e.field.values?e.field.values:{};return Object.entries(a)},()=>l.html`
5909
- <${s}
5908
+ ${(0,l.repeat)(e=>{var t,i,o,n;const s="enum"===(null===(i=null===(t=e.operator)||void 0===t?void 0:t.valueType)||void 0===i?void 0:i.type)&&(null===(n=null===(o=null==e?void 0:e.operator)||void 0===o?void 0:o.valueType)||void 0===n?void 0:n.values)?e.operator.valueType.values:"enum"===e.field.type&&e.field.values?e.field.values:{};return Object.entries(s)},()=>l.html`
5909
+ <${a}
5910
5910
  value="${e=>e[0]}"
5911
5911
  ?selected=${(e,t)=>e[0]===t.parent.value}
5912
5912
  title="${e=>"object"==typeof e[1]?e[1].tooltip:""}"
5913
5913
  >
5914
5914
  ${e=>"object"==typeof e[1]?e[1].label:e[1]}
5915
- </${s}>
5915
+ </${a}>
5916
5916
  `)}
5917
- </${a}>
5917
+ </${s}>
5918
5918
  `}}
5919
5919
  `,Fm=l.html`
5920
5920
  ${e=>{var t,i;const o=null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.checkbox,n=o||"input";return l.html`
@@ -5957,7 +5957,7 @@
5957
5957
  ${ym(e=>e.field,_m,l.html`
5958
5958
  <div>Select a field to set value</div>
5959
5959
  `)}
5960
- `;let Pm=class extends l.FASTElement{constructor(){super(...arguments),this.variadic=!1,this.validationError=!1,this.field=null,this.operator=null}connectedCallback(){super.connectedCallback(),vm(this,this.styles,"value")}validateInput(e){if(!this.field)return null;return["validation"in this.field?this.field.validation(e):null,Rm(pm(this),e)].filter(e=>!!e).join(", ")||null}handleInputChange(e){e.stopPropagation();const t=e.target;if("checkbox"!==t.type&&"select-one"!==t.type){const e=this.validateInput(t.value);if(e)return this.validationError=!0,void(this.validationMsg=e);this.validationError=!1,this.validationMsg=null}let i;i="checkbox"===t.getAttribute("role")?t.checked:"select-one"===t.type?e.target.value:this.field&&Im(pm(this))?parseInt(t.value):this.field&&Dm(pm(this))?parseFloat(t.value):t.value,this.value=i;const o={value:i,index:parseInt(this.valueIndex)};this.dispatchEvent(new CustomEvent(gm.ValueUpdated,{detail:o,bubbles:!0,composed:!0}))}handleRemoveVariadicOperand(){if(!this.variadic)throw new Error("Cannot remove inputs for non-variadic operator");const e={index:parseInt(this.valueIndex)};this.dispatchEvent(new CustomEvent(gm.RemoveVarArg,{detail:e,bubbles:!0,composed:!0}))}};(0,C.Cg)([(0,l.attr)({attribute:"value-index"})],Pm.prototype,"valueIndex",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Pm.prototype,"variadic",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"validation-error"})],Pm.prototype,"validationError",void 0),(0,C.Cg)([(0,l.attr)({attribute:"validation-msg"})],Pm.prototype,"validationMsg",void 0),(0,C.Cg)([l.observable],Pm.prototype,"field",void 0),(0,C.Cg)([l.observable],Pm.prototype,"operator",void 0),(0,C.Cg)([l.observable],Pm.prototype,"value",void 0),(0,C.Cg)([l.observable],Pm.prototype,"config",void 0),(0,C.Cg)([l.observable],Pm.prototype,"styles",void 0),Pm=(0,C.Cg)([(0,l.customElement)({name:"expression-rule-value",template:Hm,styles:Am,shadowOptions:{delegatesFocus:!0}})],Pm);const zm=(e,t)=>void 0!==t.field.defaultValue?t.field.defaultValue:Um(e,t),Um=(e,t)=>{var i,o;switch(pm(Object.assign(Object.assign({},t),{operator:e}))){case"string":return"";case"boolean":return!1;case"date":return cm(new Date);case"date-time":return um(new Date);case"double":case"int":case"bigdecimal":case"short":case"long":return 0;case"enum":{const n="enum"===(null===(i=null==e?void 0:e.valueType)||void 0===i?void 0:i.type)?null===(o=null==e?void 0:e.valueType)||void 0===o?void 0:o.values:"enum"===t.field.type?t.field.values:{};if(0===Object.keys(n).length)throw new Error("Enums require configured values");return Object.keys(n)[0]}}},Bm=(e,t)=>{var i,o,n,a;const s=(r=e,l=t,e=>{var t,i,o;if((null===(t=null==r?void 0:r.valueType)||void 0===t?void 0:t.type)!==(null===(o=null===(i=l.operator)||void 0===i?void 0:i.valueType)||void 0===o?void 0:o.type))return null;if(!("value"in l)||!l.value||!l.operator)return null;const n=1===l.operator.nbInputs?[l.value]:l.value;return e>=n.length?null:n[e]});var r,l;switch(e.nbInputs){case 0:return{field:t.field,operator:e,value:void 0};case 1:return{field:t.field,operator:e,value:null!==(i=s(0))&&void 0!==i?i:zm(e,t)};case 2:return{field:t.field,operator:e,value:[null!==(o=s(0))&&void 0!==o?o:zm(e,t),null!==(n=s(1))&&void 0!==n?n:zm(e,t)]};case"many":return{field:t.field,operator:e,value:[null!==(a=s(0))&&void 0!==a?a:zm(e,t)]}}},Wm=(e,t,i)=>{switch(e.operator.nbInputs){case 0:throw new Error("Cannot set the value for a UniraryOperator");case 1:return{field:e.field,operator:e.operator,value:t};case 2:case"many":if(!("value"in e)||!Array.isArray(e.value))throw new Error("Invalid value shape for rule");return{field:e.field,operator:e.operator,value:e.value.map((e,o)=>o===i?t:e)}}},Gm=e=>!e&&0!==e,jm=l.css`
5960
+ `;let Pm=class extends l.FASTElement{constructor(){super(...arguments),this.variadic=!1,this.validationError=!1,this.field=null,this.operator=null}connectedCallback(){super.connectedCallback(),gm(this,this.styles,"value")}validateInput(e){if(!this.field)return null;return["validation"in this.field?this.field.validation(e):null,Am(pm(this),e)].filter(e=>!!e).join(", ")||null}handleInputChange(e){e.stopPropagation();const t=e.target;if("checkbox"!==t.type&&"select-one"!==t.type){const e=this.validateInput(t.value);if(e)return this.validationError=!0,void(this.validationMsg=e);this.validationError=!1,this.validationMsg=null}let i;i="checkbox"===t.getAttribute("role")?t.checked:"select-one"===t.type?e.target.value:this.field&&Im(pm(this))?parseInt(t.value):this.field&&Rm(pm(this))?parseFloat(t.value):t.value,this.value=i;const o={value:i,index:parseInt(this.valueIndex)};this.dispatchEvent(new CustomEvent(vm.ValueUpdated,{detail:o,bubbles:!0,composed:!0}))}handleRemoveVariadicOperand(){if(!this.variadic)throw new Error("Cannot remove inputs for non-variadic operator");const e={index:parseInt(this.valueIndex)};this.dispatchEvent(new CustomEvent(vm.RemoveVarArg,{detail:e,bubbles:!0,composed:!0}))}};(0,C.Cg)([(0,l.attr)({attribute:"value-index"})],Pm.prototype,"valueIndex",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Pm.prototype,"variadic",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean",attribute:"validation-error"})],Pm.prototype,"validationError",void 0),(0,C.Cg)([(0,l.attr)({attribute:"validation-msg"})],Pm.prototype,"validationMsg",void 0),(0,C.Cg)([l.observable],Pm.prototype,"field",void 0),(0,C.Cg)([l.observable],Pm.prototype,"operator",void 0),(0,C.Cg)([l.observable],Pm.prototype,"value",void 0),(0,C.Cg)([l.observable],Pm.prototype,"config",void 0),(0,C.Cg)([l.observable],Pm.prototype,"styles",void 0),Pm=(0,C.Cg)([(0,l.customElement)({name:"expression-rule-value",template:Hm,styles:Dm,shadowOptions:{delegatesFocus:!0}})],Pm);const zm=(e,t)=>void 0!==t.field.defaultValue?t.field.defaultValue:Um(e,t),Um=(e,t)=>{var i,o;switch(pm(Object.assign(Object.assign({},t),{operator:e}))){case"string":return"";case"boolean":return!1;case"date":return cm(new Date);case"date-time":return um(new Date);case"double":case"int":case"bigdecimal":case"short":case"long":return 0;case"enum":{const n="enum"===(null===(i=null==e?void 0:e.valueType)||void 0===i?void 0:i.type)?null===(o=null==e?void 0:e.valueType)||void 0===o?void 0:o.values:"enum"===t.field.type?t.field.values:{};if(0===Object.keys(n).length)throw new Error("Enums require configured values");return Object.keys(n)[0]}}},Wm=(e,t)=>{var i,o,n,s;const a=(r=e,l=t,e=>{var t,i,o;if((null===(t=null==r?void 0:r.valueType)||void 0===t?void 0:t.type)!==(null===(o=null===(i=l.operator)||void 0===i?void 0:i.valueType)||void 0===o?void 0:o.type))return null;if(!("value"in l)||!l.value||!l.operator)return null;const n=1===l.operator.nbInputs?[l.value]:l.value;return e>=n.length?null:n[e]});var r,l;switch(e.nbInputs){case 0:return{field:t.field,operator:e,value:void 0};case 1:return{field:t.field,operator:e,value:null!==(i=a(0))&&void 0!==i?i:zm(e,t)};case 2:return{field:t.field,operator:e,value:[null!==(o=a(0))&&void 0!==o?o:zm(e,t),null!==(n=a(1))&&void 0!==n?n:zm(e,t)]};case"many":return{field:t.field,operator:e,value:[null!==(s=a(0))&&void 0!==s?s:zm(e,t)]}}},Gm=(e,t,i)=>{switch(e.operator.nbInputs){case 0:throw new Error("Cannot set the value for a UniraryOperator");case 1:return{field:e.field,operator:e.operator,value:t};case 2:case"many":if(!("value"in e)||!Array.isArray(e.value))throw new Error("Invalid value shape for rule");return{field:e.field,operator:e.operator,value:e.value.map((e,o)=>o===i?t:e)}}},Bm=e=>!e&&0!==e,Vm=l.css`
5961
5961
  .rule-container {
5962
5962
  border: 1px solid #eee;
5963
5963
  margin-bottom: 5px;
@@ -6016,7 +6016,7 @@
6016
6016
  expression-rule-value {
6017
6017
  display: flex;
6018
6018
  }
6019
- `,Vm=l.html`
6019
+ `,jm=l.html`
6020
6020
  ${e=>{var t,i;const o=(null===(i=null===(t=e.styles)||void 0===t?void 0:t.customElements)||void 0===i?void 0:i.button)||"button";return l.html`
6021
6021
  <div class="rule-container ${e=>(0,x.x)(["error",e.error])}">
6022
6022
  <div class="rule-content">
@@ -6076,17 +6076,17 @@ class="margin"
6076
6076
  </div>
6077
6077
  </div>
6078
6078
  `}}
6079
- `;let Ym=class extends l.FASTElement{constructor(){super(...arguments),this.error=!1}connectedCallback(){super.connectedCallback(),vm(this,this.styles,"rule"),this.config.partialRuleValidationWarning&&(this.error=(e=>{if(!e.field||!e.operator)return!0;if(0===e.operator.nbInputs)return!1;if(!("value"in e))throw new Error("No value set as required for operator");return"boolean"!==pm(e)&&!!(Array.isArray(e.value)?e.value:[e.value]).some(Gm)})(this.model))}variadicRule(e){return"many"===e.operator.nbInputs&&"value"in e&&Array.isArray(e.value)}get operandIterator(){var e,t,i;if("many"===(null===(e=this.model.operator)||void 0===e?void 0:e.nbInputs)){if(!this.variadicRule(this.model))throw new Error("Varargs disabled for many nbInputs");return Array(this.model.value.length).fill(!0)}return Array(null!==(i=null===(t=this.model.operator)||void 0===t?void 0:t.nbInputs)&&void 0!==i?i:0).fill(!0)}operandValue(e){if(this.model.operator){if(1===this.model.operator.nbInputs&&"value"in this.model)return this.model.value;if((2===this.model.operator.nbInputs||"many"===this.model.operator.nbInputs)&&"value"in this.model&&Array.isArray(this.model.value))return this.model.value[e];throw new Error("Invalid operand lookup")}}dispatchAddVarArg(){if(!this.variadicRule(this.model))throw new Error("Cannot add inputs for non-variadic operator, or invalid format");const e={ruleId:this.model.ruleId,newData:{operator:this.model.operator,field:this.model.field,value:[...this.model.value,zm(this.model.operator,this.model)]}};this.dispatchEvent(new CustomEvent(gm.UpdateRule,{detail:e,bubbles:!0,composed:!0}))}handleRemoveVarArg(e){const{index:t}=e.detail;if(!this.variadicRule(this.model))throw new Error("Cannot remove inputs for non-variadic operator, or invalid format");const i={ruleId:this.model.ruleId,newData:{operator:this.model.operator,field:this.model.field,value:this.model.value.filter((e,i)=>i!==t)}};this.dispatchEvent(new CustomEvent(gm.UpdateRule,{detail:i,bubbles:!0,composed:!0}))}dispatchDeleteRule(e){e.stopPropagation();const t={ruleId:this.model.ruleId};this.dispatchEvent(new CustomEvent(gm.DelRule,{detail:t,bubbles:!0,composed:!0}))}handleFieldSelected(e){var t;e.stopPropagation();const{fieldId:i}=e.detail,o=null!==(t=this.config.fields.find(e=>e.fieldId===i))&&void 0!==t?t:null,n={ruleId:this.model.ruleId,newData:{field:o,value:null,operator:null}};this.dispatchEvent(new CustomEvent(gm.UpdateRule,{detail:n,bubbles:!0,composed:!0}))}handleValueChanged(e){e.stopPropagation();const{value:t,index:i}=e.detail,o={ruleId:this.model.ruleId,newData:Wm(this.model,t,i)};this.dispatchEvent(new CustomEvent(gm.UpdateRule,{detail:o,bubbles:!0,composed:!0}))}handleOperatorSelected(e){var t;e.stopPropagation();const{operatorId:i}=e.detail;if(!i)return;const o=null!==(t=this.config.operators.find(e=>e.type===i))&&void 0!==t?t:null;if(!o)throw new Error(`Unable to find operator of type ${i}`);this.dispatchEvent(new CustomEvent(gm.UpdateRule,{detail:{ruleId:this.model.ruleId,newData:Bm(o,this.model)},bubbles:!0,composed:!0}))}};(0,C.Cg)([l.observable],Ym.prototype,"config",void 0),(0,C.Cg)([l.observable],Ym.prototype,"styles",void 0),(0,C.Cg)([l.observable],Ym.prototype,"model",void 0),(0,C.Cg)([l.observable],Ym.prototype,"index",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Ym.prototype,"error",void 0),(0,C.Cg)([l.volatile],Ym.prototype,"operandIterator",null),Ym=(0,C.Cg)([(0,l.customElement)({name:"expression-rule",template:Vm,styles:jm,shadowOptions:{delegatesFocus:!0}})],Ym);let qm=class extends l.FASTElement{constructor(){super(...arguments),this.model=null,this.ruleCount=0,this.groupCount=0,this.userUpdatingModel=!1,this.handleAddGroup=this._handleAddGroup.bind(this),this.handleAddRule=this._handleAddRule.bind(this),this.handleDeleteGroup=this._handleDeleteGroup.bind(this),this.handleDeleteRule=this._handleDeleteRule.bind(this),this.handleUpdateGroupData=this._handleUpdateGroupData.bind(this),this.handleUpdateRuleData=this._handleUpdateRuleData.bind(this)}configChanged(e,t){this.isValidConfig(t)?t.model?(this.ruleCount=0,this.groupCount=0,this.userUpdatingModel=!0,this.model=lm(t.model,this),this.userUpdatingModel=!1):null===this.model&&this.initBaseModel():console.warn("Invalid config passed to ExpressionBuilder. Verify you've defined operators, fields, and combinators.")}modelChanged(e,t){if(!t||this.userUpdatingModel)return;const i=dm(t);this.dispatchChangeEvent(i)}dispatchChangeEvent(e){this.dispatchEvent(new CustomEvent("change",{detail:e,bubbles:!0,cancelable:!0,composed:!0}))}getConfig(){return this.config}getGroupId(){return this.groupCount+=1,`group-${this.groupCount}`}getRuleId(){return this.ruleCount+=1,`rule-${this.ruleCount}`}connectedCallback(){if(super.connectedCallback(),this.addEventListener(gm.AddGroup,this.handleAddGroup),this.addEventListener(gm.DelGroup,this.handleDeleteGroup),this.addEventListener(gm.AddRule,this.handleAddRule),this.addEventListener(gm.DelRule,this.handleDeleteRule),this.addEventListener(gm.UpdateGroup,this.handleUpdateGroupData),this.addEventListener(gm.UpdateRule,this.handleUpdateRuleData),!this.isValidConfig(this.config))return this.config&&console.warn("Config detected during connectedCallback but it isn't valid"),void(this.config=null);this.config.model||this.initBaseModel()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(gm.AddGroup,this.handleAddGroup),this.removeEventListener(gm.DelGroup,this.handleDeleteGroup),this.removeEventListener(gm.AddRule,this.handleAddRule),this.removeEventListener(gm.DelRule,this.handleDeleteRule),this.removeEventListener(gm.UpdateGroup,this.handleUpdateGroupData),this.removeEventListener(gm.UpdateRule,this.handleUpdateRuleData)}isValidConfig(e){var t,i,o;return Boolean(e&&(null===(t=e.combinators)||void 0===t?void 0:t.length)&&(null===(i=e.operators)||void 0===i?void 0:i.length)&&(null===(o=e.fields)||void 0===o?void 0:o.length))}initBaseModel(){if(!this.isValidConfig(this.config))throw new Error("Invalid config set on ExpressionBuilder. Verify you've defined operators, fields, and combinators.");this.model={children:[],level:1,groupId:rm,config:this.config,combinator:this.config.combinators[0]}}_handleAddGroup(e){const{parentGroupId:t,newGroup:i}=e.detail,o={groupId:this.getGroupId(),level:i.level,children:[],config:this.config,combinator:this.config.combinators[0]};this.model=sm(this.model,t,o)}_handleAddRule(e){const{parentGroupId:t}=e.detail,i={ruleId:this.getRuleId(),config:this.config,field:null,operator:null,value:null};this.model=sm(this.model,t,i)}_handleDeleteGroup(e){const{groupId:t}=e.detail;var i,o;this.model=im(i=this.model,nm(i,o=t).groupId,e=>e.filter(e=>!("groupId"in e)||e.groupId!==o))}_handleDeleteRule(e){const{ruleId:t}=e.detail;var i,o;this.model=im(i=this.model,am(i,o=t).groupId,e=>e.filter(e=>!("ruleId"in e)||e.ruleId!==o))}_handleUpdateGroupData(e){const{groupId:t,newData:i}=e.detail;this.model=function(e,t,i){return t===rm?Object.assign(Object.assign({},e),i):im(e,nm(e,t).groupId,e=>e.map(e=>"groupId"in e&&e.groupId===t?Object.assign(Object.assign({},e),i):e))}(this.model,t,i)}_handleUpdateRuleData(e){const{ruleId:t,newData:i}=e.detail;this.model=function(e,t,i){return im(e,am(e,t).groupId,e=>e.map(e=>"ruleId"in e&&e.ruleId===t?Object.assign(Object.assign({},e),i):e))}(this.model,t,i)}};(0,C.Cg)([l.observable],qm.prototype,"config",void 0),(0,C.Cg)([l.observable],qm.prototype,"styles",void 0),(0,C.Cg)([l.observable],qm.prototype,"model",void 0),qm=(0,C.Cg)([(0,l.customElement)({name:"expression-builder",template:Sm,styles:fm})],qm);let Km=class extends qm{};Km=(0,C.Cg)([(0,l.customElement)({name:"foundation-expression-builder",styles:fm,template:Sm})],Km);const Xm=["int","short","long"],Qm=["double","bigdecimal"],Jm=[...Xm,...Qm],Zm=["date","date-time"],ev=["string","enum"],tv=["boolean"],iv=e=>{var t,i,o;return null!==(o=null===(i=null===(t=e.operator)||void 0===t?void 0:t.valueType)||void 0===i?void 0:i.type)&&void 0!==o?o:e.field.type};function ov(e){switch(iv(e)){case"int":case"long":case"double":case"bigdecimal":case"date":case"date-time":case"short":return"NUMBER";case"string":case"enum":return"STRING";case"boolean":return"BOOLEAN"}}function nv(e,t,i){return"value"in e?{TYPE:"BINARY_EXPRESSION",LEFT:{TYPE:"FIELD",NAME:e.field.fieldId},OPERATION:t,RIGHT:{TYPE:i,VALUE:e.value}}:null}function av(e,t,i){return{TYPE:"BINARY_EXPRESSION",LEFT:{TYPE:"FIELD",NAME:e.field.fieldId},OPERATION:t,RIGHT:i}}function sv(e,t,i=[]){return"value"in e?{TYPE:"METHOD_EXPRESSION",PARAMETERS:[{TYPE:"FIELD",NAME:e.field.fieldId},...i],METHOD:t}:null}function rv(e){const t=!(!("value"in e)||void 0===e.value||null===e.value);return Object.assign(Object.assign({},e),t?{value:(t=>{const i=iv(e);if(ev.includes(i))return t;if(Jm.includes(i))return t.toString();if(tv.includes(i))return t;if(Array.isArray(t))throw new Error("Not implemented TernararyOperator or VariadicOperator args in rule value transformer");if(Zm.includes(i))return new Date(t).getTime().toString();throw new Error("Unhandled transformRuleValue case")})(e.value)}:{})}function lv(e,t){return{TYPE:"PREDICATE_EXPRESSION",OPERATION:e.combinator.type,EXPRESSIONS:e.children.map(e=>"children"in e?lv(e,t):t(e)).filter(Boolean)}}function dv(e,t){const i=e.operator.nbInputs;if("many"===i||2===i)throw new Error("Not implemented TernararyOperator or VariadicOperator args in rebuildRuleValue");return Object.assign(Object.assign({},e),0===i?{}:{value:(t=>{const i=iv(e);if(ev.includes(i))return t;if(Xm.includes(i))return parseInt(t);if(Qm.includes(i))return parseFloat(t);if(tv.includes(i))return t;if(Zm.includes(i)){const e=new Date(parseInt(t));return"date"===i?cm(e):um(e)}throw new Error("Unhandled rebuildRuleValue case")})(t.VALUE)})}const cv={template:Sm,styles:fm};var uv;!function(e){e.methodCall={CONTAINS_IGNORE_CASE:"CONTAINS_IGNORE_CASE",CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE:"CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE",IS_NULL_OR_BLANK:"IS_NULL_OR_BLANK",NOT_NULL_OR_BLANK:"NOT_NULL_OR_BLANK",TRIM:"TRIM",LONG_TO_DATE:"LONG_TO_DATE",LONG_TO_DATE_TIME:"LONG_TO_DATE_TIME",DATE_TIME_IS_IN_RANGE:"DATE_TIME_IS_IN_RANGE"},e.logicalOperations={AND:"AND",OR:"OR"},e.operations=Object.assign(Object.assign({},e.logicalOperations),{GREATER_THAN:"GREATER_THAN",LESS_THAN:"LESS_THAN",GREATER_THAN_OR_EQUAL:"GREATER_THAN_OR_EQUAL",LESS_THAN_OR_EQUAL:"LESS_THAN_OR_EQUAL",EQUALS:"EQUALS",NOT_EQUALS:"NOT_EQUALS",PLUS:"PLUS",MINUS:"MINUS",MULTIPLY:"MULTIPLY",DIVIDE:"DIVIDE",BITWISE_AND:"BITWISE_AND",BITWISE_OR:"BITWISE_OR",ASSIGNMENT:"ASSIGNMENT",IS_CURRENT:"IS_CURRENT",IS_PREVIOUS:"IS_PREVIOUS"})}(uv||(uv={}));const hv=[{type:uv.logicalOperations.AND,maxRules:"many"},{type:uv.logicalOperations.OR,maxRules:"many"}],pv={EQUALS:uv.operations.EQUALS,NOT_EQUALS:uv.operations.NOT_EQUALS,IS_NULL:"IS_NULL",NOT_NULL:"NOT_NULL",IS_NULL_OR_BLANK:"IS_NULL_OR_BLANK",NOT_NULL_OR_BLANK:"NOT_NULL_OR_BLANK",CONTAINS:"CONTAINS",CONTAINS_WORDS_STARTING_WITH:"CONTAINS_WORDS_STARTING_WITH",CONTAINS_WORDS_STARTING_SPLIT_DELIMITER:"CONTAINS_WORDS_STARTING_SPLIT_DELIMITER",GREATER_THAN:uv.operations.GREATER_THAN,GREATER_THAN_OR_EQUAL:uv.operations.GREATER_THAN_OR_EQUAL,LESS_THAN:uv.operations.LESS_THAN,LESS_THAN_OR_EQUAL:uv.operations.LESS_THAN_OR_EQUAL,IS_BEFORE:"IS_BEFORE",IS_AFTER:"IS_AFTER",ON_OR_BEFORE:"ON_OR_BEFORE",ON_OR_AFTER:"ON_OR_AFTER",IS_CURRENT:uv.operations.IS_CURRENT,IS_PREVIOUS:uv.operations.IS_PREVIOUS},mv=e=>({type:"enum",input:"select",values:e}),vv=mv({HOUR:{label:"Hour",tooltip:"Beginning of the hour immediately preceding the current one to the current hour."},DAY:{label:"Day",tooltip:"Midnight on the day before today to midnight of the current day."},WEEK_DAY:{label:"Week day",tooltip:"Midnight on the day before today to midnight of the current day. If the current day is Monday then the previous day is Friday."},WEEK:{label:"Week",tooltip:"Midnight on the Monday of the previous week to midnight on the Monday of the current week."},MONTH:{label:"Month",tooltip:"Midnight on the 1st of the previous month to midnight on the 1st of the current month."},YEAR:{label:"Year",tooltip:"Midnight on Jan 1st of the previous year to midnight on the 1st Jan of the current year."}}),gv=mv({HOUR:{label:"Hour",tooltip:"Beginning of the current hour to beginning of the next hour."},DAY:{label:"Day",tooltip:"Midnight on the current day day to midnight of the next day."},WEEK_DAY:{label:"Week day",tooltip:"Midnight on the current day day to midnight of the next day. This filter will never match Sat or Sun, always returning false on the weekends."},WEEK:{label:"Week",tooltip:"Midnight on the Monday of the current week to midnight on the Monday of the next week."},MONTH:{label:"Month",tooltip:"Midnight on the 1st of the current month to midnight on the 1st of the next month."},YEAR:{label:"Year",tooltip:"Midnight on Jan 1st of the current year to midnight on the 1st Jan of the next year."}}),fv=[{type:pv.EQUALS,label:"Equals",nbInputs:1,applyTo:[...ev,...tv,...Jm,...Zm],tooltip:"Check the equality of the field compared to a set value"},{type:pv.NOT_EQUALS,label:"Not equals",nbInputs:1,applyTo:[...ev,...tv,...Jm,...Zm],tooltip:"Check that the field is different from a set value"},{type:pv.IS_NULL,label:"Is null",nbInputs:0,applyTo:["enum",...tv,...Jm,...Zm],tooltip:"Check if the field value is null"},{type:pv.NOT_NULL,label:"Not null",nbInputs:0,applyTo:["enum",...tv,...Jm,...Zm],tooltip:"Check if the field value is not null"},{type:pv.IS_NULL_OR_BLANK,label:"Is null or blank",nbInputs:0,applyTo:["string"],tooltip:"Check if the field value is null or an empty string"},{type:pv.NOT_NULL_OR_BLANK,label:"Not null or blank",nbInputs:0,applyTo:["string"],tooltip:"Check if the field value is not null and not an empty string"},{type:pv.CONTAINS,label:"Contains",nbInputs:1,applyTo:["string"],tooltip:"Check if the field contains the specified text (case insensitive)"},{type:pv.CONTAINS_WORDS_STARTING_WITH,label:"Contains words starting with",nbInputs:1,applyTo:["string"],tooltip:"Check if the field contains words that start with the specified text, split by whitespace (case insensitive)"},{type:pv.CONTAINS_WORDS_STARTING_SPLIT_DELIMITER,label:"Contains words starting with (split)",nbInputs:2,applyTo:["string"],tooltip:"Check if field contains words starting with text, split by a delimiter (case insensitive)"},{type:pv.GREATER_THAN,label:"Greater than",nbInputs:1,applyTo:[...Jm],tooltip:"Check if the field value is greater than a specified number"},{type:pv.GREATER_THAN_OR_EQUAL,label:"Greater than or equal to",nbInputs:1,applyTo:[...Jm],tooltip:"Check if the field value is greater than or equal to a specified number"},{type:pv.LESS_THAN,label:"Less than",nbInputs:1,applyTo:[...Jm],tooltip:"Check if the field value is less than a specified number"},{type:pv.LESS_THAN_OR_EQUAL,label:"Less than or equal to",nbInputs:1,applyTo:[...Jm],tooltip:"Check if the field value is less than or equal to a specified number"},{type:pv.IS_BEFORE,label:"Is before",nbInputs:1,applyTo:[...Zm],tooltip:"Check if the field is before a specified date/time"},{type:pv.IS_AFTER,label:"Is after",nbInputs:1,applyTo:[...Zm],tooltip:"Check if the field is after a specified date/time"},{type:pv.ON_OR_BEFORE,label:"On or before",nbInputs:1,applyTo:[...Zm],tooltip:"Check if the field is on or before a specified date/time"},{type:pv.ON_OR_AFTER,label:"On or after",nbInputs:1,applyTo:[...Zm],tooltip:"Check if the field is on or after a specified date/time"},{type:pv.IS_CURRENT,label:"Is current",nbInputs:1,applyTo:[...Zm],tooltip:"Check whether the current date/time matches the current hour/day/work day/week/month/year.",valueType:gv,optgroup:"Relative Period"},{type:pv.IS_PREVIOUS,label:"Is previous",nbInputs:1,applyTo:[...Zm],tooltip:"Check whether the current date/time matches the previous hour/day/work day/week/month/year",valueType:vv,optgroup:"Relative Period"}];function bv(e){switch(e){case"IS_BEFORE":return"LESS_THAN";case"IS_AFTER":return"GREATER_THAN";case"ON_OR_BEFORE":return"LESS_THAN_OR_EQUAL";case"ON_OR_AFTER":return"GREATER_THAN_OR_EQUAL";default:return e}}function yv(e,t){switch(t){case pv.IS_NULL_OR_BLANK:return sv(e,uv.methodCall.IS_NULL_OR_BLANK,[]);case pv.NOT_NULL_OR_BLANK:return sv(e,uv.methodCall.NOT_NULL_OR_BLANK,[]);case pv.CONTAINS:if(!("value"in e))throw new Error("Invalid shape for operator CONTAINS");return sv(e,uv.methodCall.CONTAINS_IGNORE_CASE,[{TYPE:"STRING",VALUE:e.value}]);case pv.CONTAINS_WORDS_STARTING_WITH:if(!("value"in e))throw new Error("Invalid shape for operator CONTAINS_WORDS_STARTING_WITH");return sv(e,uv.methodCall.CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE,[{TYPE:"STRING",VALUE:e.value}]);case pv.CONTAINS_WORDS_STARTING_SPLIT_DELIMITER:if(!("value"in e)||!Array.isArray(e.value)||2!==e.value.length)throw new Error("Invalid shape for CONTAINS_WORDS_STARTING_SPLIT_DELIMITER");return sv(e,uv.methodCall.CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE,e.value.map(e=>({TYPE:"STRING",VALUE:e})));case pv.IS_CURRENT:case pv.IS_PREVIOUS:if(!("value"in e))throw new Error("Invalid shape for operator IS_CURRENT | IS_PREVIOUS");return sv(e,uv.methodCall.DATE_TIME_IS_IN_RANGE,[{TYPE:"STRING",VALUE:e.value},{TYPE:"STRING",VALUE:t===pv.IS_CURRENT?"CURRENT":"PREVIOUS"}]);default:throw new Error("Unreachable default case")}}function wv(e){var t,i;if(!(null===(t=e.operator)||void 0===t?void 0:t.type)||!(null===(i=e.field)||void 0===i?void 0:i.fieldId))return null;const o=rv(e),n=ov(o),a=bv(o.operator.type);switch(a){case pv.EQUALS:case pv.NOT_EQUALS:case pv.GREATER_THAN:case pv.GREATER_THAN_OR_EQUAL:case pv.LESS_THAN:case pv.LESS_THAN_OR_EQUAL:return nv(o,a,n);case pv.IS_NULL:return av(o,uv.operations.EQUALS,{TYPE:"NULL"});case pv.NOT_NULL:return av(o,uv.operations.NOT_EQUALS,{TYPE:"NULL"});case pv.IS_NULL_OR_BLANK:case pv.NOT_NULL_OR_BLANK:case pv.CONTAINS:case pv.CONTAINS_WORDS_STARTING_WITH:case pv.CONTAINS_WORDS_STARTING_SPLIT_DELIMITER:case pv.IS_CURRENT:case pv.IS_PREVIOUS:return yv(o,a);default:throw new Error(`Unmatched case for operator name: ${a}`)}}function Cv(e,t){if(!("date"===t.field.type||"date-time"===t.field.type))return e;switch(e){case"LESS_THAN":return"IS_BEFORE";case"GREATER_THAN":return"IS_AFTER";case"LESS_THAN_OR_EQUAL":return"ON_OR_BEFORE";case"GREATER_THAN_OR_EQUAL":return"ON_OR_AFTER";default:return e}}function xv(e,t){const i=(()=>{if("NULL"===t.RIGHT.TYPE){const e="EQUALS"===t.OPERATION?pv[pv.IS_NULL]:pv[pv.NOT_NULL];return fv.find(t=>t.type===e)}const i=Cv(t.OPERATION,e);return fv.find(e=>e.type===i)})();return Object.assign(Object.assign({},e),{operator:i})}function $v(e,t){if("FIELD"!==t.LEFT.TYPE)throw new Error("BinaryExpression LHS must be TYPE === FIELD");if(!["STRING","NUMBER","BOOLEAN","NULL"].includes(t.RIGHT.TYPE))throw new Error("BinaryExpression RHS must be TYPE === NUMBER | STRING | BOOLEAN | NULL");return dv(xv({field:e.find(e=>e.fieldId===t.LEFT.NAME)},t),t.RIGHT)}function Sv(e,t){const[i,o]=(()=>{switch(!0){case"IS_NULL_OR_BLANK"===t.METHOD:return[pv[pv.IS_NULL_OR_BLANK],void 0];case"NOT_NULL_OR_BLANK"===t.METHOD:return[pv[pv.NOT_NULL_OR_BLANK],void 0];case"CONTAINS_IGNORE_CASE"===t.METHOD:return[pv[pv.CONTAINS],t.PARAMETERS[1].VALUE];case"CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE"===t.METHOD&&2===t.PARAMETERS.length:return[pv[pv.CONTAINS_WORDS_STARTING_WITH],t.PARAMETERS[1].VALUE];case"CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE"===t.METHOD&&3===t.PARAMETERS.length:return[pv[pv.CONTAINS_WORDS_STARTING_SPLIT_DELIMITER],t.PARAMETERS.slice(1).map(e=>e.VALUE)];case t.METHOD===uv.methodCall.DATE_TIME_IS_IN_RANGE&&3===t.PARAMETERS.length&&"STRING"===t.PARAMETERS[2].TYPE&&("CURRENT"===t.PARAMETERS[2].VALUE||"PREVIOUS"===t.PARAMETERS[2].VALUE):return[pv["CURRENT"===t.PARAMETERS[2].VALUE?pv.IS_CURRENT:pv.IS_PREVIOUS],t.PARAMETERS[1].VALUE];default:throw new Error("Unhandled fromMethodExpression case")}})();return{field:e.find(e=>e.fieldId===t.PARAMETERS[0].NAME),operator:fv.find(e=>e.type===i),value:o}}function Ev(e,t){return{combinator:hv.find(e=>e.type===t.OPERATION),children:t.EXPRESSIONS.map(t=>{if(!("TYPE"in t))throw new Error("RuleExpression format not yet supported - no TYPE");if("PREDICATE_EXPRESSION"===t.TYPE)return Ev(e,t);if("BINARY_EXPRESSION"===t.TYPE)return $v(e,t);if("METHOD_EXPRESSION"===t.TYPE)return Sv(e,t);throw new Error("RuleExpression format not yet supported - unsupported TYPE")})}}let kv=class extends qm{ruleConfigChanged(e,t){this.config=Object.assign({combinators:hv,operators:fv,fields:t.fields,maxNesting:t.maxNesting,partialRuleValidationWarning:t.partialRuleValidationWarning},(null==t?void 0:t.model)?{model:Ev(t.fields,t.model)}:{})}configChanged(e,t){if(null!==t){if(!t.operators||!t.combinators)throw new Error("Unable to detect operators or combinators. Did you set the config on the rule builder via the config property? Use the ruleConfig property instead");super.configChanged(e,t)}}dispatchChangeEvent(e){const t=lv(e,wv);this.dispatchEvent(new CustomEvent("change",{detail:t,bubbles:!0,cancelable:!0,composed:!0}))}};(0,C.Cg)([l.observable],kv.prototype,"ruleConfig",void 0),kv=(0,C.Cg)([(0,l.customElement)({name:"foundation-rule-expression-builder",styles:fm,template:Sm})],kv);const Ov={TRIM:"TRIM",PLUS:"PLUS",MINUS:"MINUS",MULTIPLY:"MULTIPLY",DIVIDE:"DIVIDE",CONVERT_TO_DATE:"CONVERT_TO_DATE",CONVERT_TO_DATE_TIME:"CONVERT_TO_DATE_TIME"},Tv=[{type:Ov.PLUS,label:"Add (+)",applyTo:[...Jm],nbInputs:1,tooltip:"Returns the result of the field value mathematically added to the specified rule value. FIELD + VALUE"},{type:Ov.MINUS,label:"Subtract (-)",applyTo:[...Jm],nbInputs:1,tooltip:"Returns the result of the field value mathematically subtracted by the specified rule value. FIELD - VALUE"},{type:Ov.MULTIPLY,label:"Multiply (*)",applyTo:[...Jm],nbInputs:1,tooltip:"Returns the result of the field value mathematically multiplied by the specified rule value. FIELD * VALUE"},{type:Ov.DIVIDE,label:"Divide (/)",applyTo:[...Jm],nbInputs:1,tooltip:"Returns the result of the field value mathematically divided by the specified rule value. FIELD / VALUE"},{type:Ov.CONVERT_TO_DATE,label:"Convert to date",applyTo:["date"],nbInputs:0,tooltip:"Returns the date, which is stored as the epoch time, as a formatted date YYYY/dd/mm"},{type:Ov.CONVERT_TO_DATE_TIME,label:"Convert to date time",applyTo:["date-time"],nbInputs:0,tooltip:"Returns the date-time, which is stored as the epoch time, as a formatted date YYYY/dd/mm HH:mm:ss"}];function Iv(e){var t,i;if(!(null===(t=e.operator)||void 0===t?void 0:t.type)||!(null===(i=e.field)||void 0===i?void 0:i.fieldId))return null;const o=rv(e),n=ov(o),a=o.operator.type;switch(a){case Ov.TRIM:case Ov.CONVERT_TO_DATE:case Ov.CONVERT_TO_DATE_TIME:return function(e,t){switch(t){case Ov.TRIM:return sv(e,uv.methodCall.TRIM,[]);case Ov.CONVERT_TO_DATE:return sv(e,uv.methodCall.LONG_TO_DATE,[]);case Ov.CONVERT_TO_DATE_TIME:return sv(e,uv.methodCall.LONG_TO_DATE_TIME,[])}}(o,a);case Ov.PLUS:case Ov.MINUS:case Ov.DIVIDE:case Ov.MULTIPLY:return nv(o,a,n);default:throw new Error(`Unmatched case for operator name: ${a}`)}}function Dv(e,t){if("FIELD"!==t.LEFT.TYPE)throw new Error("BinaryExpression LHS must be TYPE === FIELD");if(!["STRING","NUMBER","BOOLEAN","NULL"].includes(t.RIGHT.TYPE))throw new Error("BinaryExpression RHS must be TYPE === NUMBER | STRING | BOOLEAN | NULL");return dv(function(e,t){const i=(()=>{const i=function(e,t){return"date"===t.field.type||t.field.type,e}(t.OPERATION,e);return Tv.find(e=>e.type===i)})();return Object.assign(Object.assign({},e),{operator:i})}({field:e.find(e=>e.fieldId===t.LEFT.NAME)},t),t.RIGHT)}function Rv(e,t){return{combinator:Kp,children:t.EXPRESSIONS.map(t=>{if(!("TYPE"in t))throw new Error("RuleExpression format not yet supported - no TYPE");if("PREDICATE_EXPRESSION"===t.TYPE)return Rv(e,t);if("BINARY_EXPRESSION"===t.TYPE)return Dv(e,t);if("METHOD_EXPRESSION"===t.TYPE)return function(e,t){const[i,o]=(()=>{switch(!0){case"TRIM"===t.METHOD:return[Ov[Ov.TRIM],void 0];case"LONG_TO_DATE"===t.METHOD:return[Ov[Ov.CONVERT_TO_DATE],void 0];case"LONG_TO_DATE_TIME"===t.METHOD:return[Ov[Ov.CONVERT_TO_DATE_TIME],void 0];default:throw new Error("Unhandled fromMethodExpression case")}})();return{field:e.find(e=>e.fieldId===t.PARAMETERS[0].NAME),operator:Tv.find(e=>e.type===i),value:o}}(e,t);throw new Error("RuleExpression format not yet supported - unsupported TYPE")})}}let Av=class extends qm{valueConfigChanged(e,t){const i={TYPE:"PREDICATE_EXPRESSION",OPERATION:"NULL",EXPRESSIONS:t.model?[t.model]:[]},o=Rv(t.fields,i);this.config={combinators:[Kp],operators:Tv,fields:t.fields,model:o,maxNesting:t.maxNesting,partialRuleValidationWarning:t.partialRuleValidationWarning}}configChanged(e,t){if(null!==t){if(!t.operators||!t.combinators)throw new Error("Unable to detect operators or combinators. Did you set the config on the rule builder via the config property? Use the valueConfig property instead");super.configChanged(e,t)}}dispatchChangeEvent(e){if(!("children"in e))throw new Error("Invalid top level group hierarchy");if(e.children.length>1)throw new Error("Value expressions should not have multiple rules");if(e.children[0]&&"children"in e.children[0])throw new Error("Trying to convert group to rule");const t=0===e.children.length?void 0:Iv(e.children[0]);this.dispatchEvent(new CustomEvent("change",{detail:t,bubbles:!0,cancelable:!0,composed:!0}))}};(0,C.Cg)([l.observable],Av.prototype,"valueConfig",void 0),Av=(0,C.Cg)([(0,l.customElement)({name:"foundation-value-expression-builder",styles:fm,template:Sm})],Av);const Nv=l.html`
6079
+ `;let Ym=class extends l.FASTElement{constructor(){super(...arguments),this.error=!1}connectedCallback(){super.connectedCallback(),gm(this,this.styles,"rule"),this.config.partialRuleValidationWarning&&(this.error=(e=>{if(!e.field||!e.operator)return!0;if(0===e.operator.nbInputs)return!1;if(!("value"in e))throw new Error("No value set as required for operator");return"boolean"!==pm(e)&&!!(Array.isArray(e.value)?e.value:[e.value]).some(Bm)})(this.model))}variadicRule(e){return"many"===e.operator.nbInputs&&"value"in e&&Array.isArray(e.value)}get operandIterator(){var e,t,i;if("many"===(null===(e=this.model.operator)||void 0===e?void 0:e.nbInputs)){if(!this.variadicRule(this.model))throw new Error("Varargs disabled for many nbInputs");return Array(this.model.value.length).fill(!0)}return Array(null!==(i=null===(t=this.model.operator)||void 0===t?void 0:t.nbInputs)&&void 0!==i?i:0).fill(!0)}operandValue(e){if(this.model.operator){if(1===this.model.operator.nbInputs&&"value"in this.model)return this.model.value;if((2===this.model.operator.nbInputs||"many"===this.model.operator.nbInputs)&&"value"in this.model&&Array.isArray(this.model.value))return this.model.value[e];throw new Error("Invalid operand lookup")}}dispatchAddVarArg(){if(!this.variadicRule(this.model))throw new Error("Cannot add inputs for non-variadic operator, or invalid format");const e={ruleId:this.model.ruleId,newData:{operator:this.model.operator,field:this.model.field,value:[...this.model.value,zm(this.model.operator,this.model)]}};this.dispatchEvent(new CustomEvent(vm.UpdateRule,{detail:e,bubbles:!0,composed:!0}))}handleRemoveVarArg(e){const{index:t}=e.detail;if(!this.variadicRule(this.model))throw new Error("Cannot remove inputs for non-variadic operator, or invalid format");const i={ruleId:this.model.ruleId,newData:{operator:this.model.operator,field:this.model.field,value:this.model.value.filter((e,i)=>i!==t)}};this.dispatchEvent(new CustomEvent(vm.UpdateRule,{detail:i,bubbles:!0,composed:!0}))}dispatchDeleteRule(e){e.stopPropagation();const t={ruleId:this.model.ruleId};this.dispatchEvent(new CustomEvent(vm.DelRule,{detail:t,bubbles:!0,composed:!0}))}handleFieldSelected(e){var t;e.stopPropagation();const{fieldId:i}=e.detail,o=null!==(t=this.config.fields.find(e=>e.fieldId===i))&&void 0!==t?t:null,n={ruleId:this.model.ruleId,newData:{field:o,value:null,operator:null}};this.dispatchEvent(new CustomEvent(vm.UpdateRule,{detail:n,bubbles:!0,composed:!0}))}handleValueChanged(e){e.stopPropagation();const{value:t,index:i}=e.detail,o={ruleId:this.model.ruleId,newData:Gm(this.model,t,i)};this.dispatchEvent(new CustomEvent(vm.UpdateRule,{detail:o,bubbles:!0,composed:!0}))}handleOperatorSelected(e){var t;e.stopPropagation();const{operatorId:i}=e.detail;if(!i)return;const o=null!==(t=this.config.operators.find(e=>e.type===i))&&void 0!==t?t:null;if(!o)throw new Error(`Unable to find operator of type ${i}`);this.dispatchEvent(new CustomEvent(vm.UpdateRule,{detail:{ruleId:this.model.ruleId,newData:Wm(o,this.model)},bubbles:!0,composed:!0}))}};(0,C.Cg)([l.observable],Ym.prototype,"config",void 0),(0,C.Cg)([l.observable],Ym.prototype,"styles",void 0),(0,C.Cg)([l.observable],Ym.prototype,"model",void 0),(0,C.Cg)([l.observable],Ym.prototype,"index",void 0),(0,C.Cg)([(0,l.attr)({mode:"boolean"})],Ym.prototype,"error",void 0),(0,C.Cg)([l.volatile],Ym.prototype,"operandIterator",null),Ym=(0,C.Cg)([(0,l.customElement)({name:"expression-rule",template:jm,styles:Vm,shadowOptions:{delegatesFocus:!0}})],Ym);let qm=class extends l.FASTElement{constructor(){super(...arguments),this.model=null,this.ruleCount=0,this.groupCount=0,this.userUpdatingModel=!1,this.handleAddGroup=this._handleAddGroup.bind(this),this.handleAddRule=this._handleAddRule.bind(this),this.handleDeleteGroup=this._handleDeleteGroup.bind(this),this.handleDeleteRule=this._handleDeleteRule.bind(this),this.handleUpdateGroupData=this._handleUpdateGroupData.bind(this),this.handleUpdateRuleData=this._handleUpdateRuleData.bind(this)}configChanged(e,t){this.isValidConfig(t)?t.model?(this.ruleCount=0,this.groupCount=0,this.userUpdatingModel=!0,this.model=lm(t.model,this),this.userUpdatingModel=!1):null===this.model&&this.initBaseModel():console.warn("Invalid config passed to ExpressionBuilder. Verify you've defined operators, fields, and combinators.")}modelChanged(e,t){if(!t||this.userUpdatingModel)return;const i=dm(t);this.dispatchChangeEvent(i)}dispatchChangeEvent(e){this.dispatchEvent(new CustomEvent("change",{detail:e,bubbles:!0,cancelable:!0,composed:!0}))}getConfig(){return this.config}getGroupId(){return this.groupCount+=1,`group-${this.groupCount}`}getRuleId(){return this.ruleCount+=1,`rule-${this.ruleCount}`}connectedCallback(){if(super.connectedCallback(),this.addEventListener(vm.AddGroup,this.handleAddGroup),this.addEventListener(vm.DelGroup,this.handleDeleteGroup),this.addEventListener(vm.AddRule,this.handleAddRule),this.addEventListener(vm.DelRule,this.handleDeleteRule),this.addEventListener(vm.UpdateGroup,this.handleUpdateGroupData),this.addEventListener(vm.UpdateRule,this.handleUpdateRuleData),!this.isValidConfig(this.config))return this.config&&console.warn("Config detected during connectedCallback but it isn't valid"),void(this.config=null);this.config.model||this.initBaseModel()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(vm.AddGroup,this.handleAddGroup),this.removeEventListener(vm.DelGroup,this.handleDeleteGroup),this.removeEventListener(vm.AddRule,this.handleAddRule),this.removeEventListener(vm.DelRule,this.handleDeleteRule),this.removeEventListener(vm.UpdateGroup,this.handleUpdateGroupData),this.removeEventListener(vm.UpdateRule,this.handleUpdateRuleData)}isValidConfig(e){var t,i,o;return Boolean(e&&(null===(t=e.combinators)||void 0===t?void 0:t.length)&&(null===(i=e.operators)||void 0===i?void 0:i.length)&&(null===(o=e.fields)||void 0===o?void 0:o.length))}initBaseModel(){if(!this.isValidConfig(this.config))throw new Error("Invalid config set on ExpressionBuilder. Verify you've defined operators, fields, and combinators.");this.model={children:[],level:1,groupId:rm,config:this.config,combinator:this.config.combinators[0]}}_handleAddGroup(e){const{parentGroupId:t,newGroup:i}=e.detail,o={groupId:this.getGroupId(),level:i.level,children:[],config:this.config,combinator:this.config.combinators[0]};this.model=am(this.model,t,o)}_handleAddRule(e){const{parentGroupId:t}=e.detail,i={ruleId:this.getRuleId(),config:this.config,field:null,operator:null,value:null};this.model=am(this.model,t,i)}_handleDeleteGroup(e){const{groupId:t}=e.detail;var i,o;this.model=im(i=this.model,nm(i,o=t).groupId,e=>e.filter(e=>!("groupId"in e)||e.groupId!==o))}_handleDeleteRule(e){const{ruleId:t}=e.detail;var i,o;this.model=im(i=this.model,sm(i,o=t).groupId,e=>e.filter(e=>!("ruleId"in e)||e.ruleId!==o))}_handleUpdateGroupData(e){const{groupId:t,newData:i}=e.detail;this.model=function(e,t,i){return t===rm?Object.assign(Object.assign({},e),i):im(e,nm(e,t).groupId,e=>e.map(e=>"groupId"in e&&e.groupId===t?Object.assign(Object.assign({},e),i):e))}(this.model,t,i)}_handleUpdateRuleData(e){const{ruleId:t,newData:i}=e.detail;this.model=function(e,t,i){return im(e,sm(e,t).groupId,e=>e.map(e=>"ruleId"in e&&e.ruleId===t?Object.assign(Object.assign({},e),i):e))}(this.model,t,i)}};(0,C.Cg)([l.observable],qm.prototype,"config",void 0),(0,C.Cg)([l.observable],qm.prototype,"styles",void 0),(0,C.Cg)([l.observable],qm.prototype,"model",void 0),qm=(0,C.Cg)([(0,l.customElement)({name:"expression-builder",template:Sm,styles:fm})],qm);let Km=class extends qm{};Km=(0,C.Cg)([(0,l.customElement)({name:"foundation-expression-builder",styles:fm,template:Sm})],Km);const Xm=["int","short","long"],Qm=["double","bigdecimal"],Jm=[...Xm,...Qm],Zm=["date","date-time"],eg=["string","enum"],tg=["boolean"],ig=e=>{var t,i,o;return null!==(o=null===(i=null===(t=e.operator)||void 0===t?void 0:t.valueType)||void 0===i?void 0:i.type)&&void 0!==o?o:e.field.type};function og(e){switch(ig(e)){case"int":case"long":case"double":case"bigdecimal":case"date":case"date-time":case"short":return"NUMBER";case"string":case"enum":return"STRING";case"boolean":return"BOOLEAN"}}function ng(e,t,i){return"value"in e?{TYPE:"BINARY_EXPRESSION",LEFT:{TYPE:"FIELD",NAME:e.field.fieldId},OPERATION:t,RIGHT:{TYPE:i,VALUE:e.value}}:null}function sg(e,t,i){return{TYPE:"BINARY_EXPRESSION",LEFT:{TYPE:"FIELD",NAME:e.field.fieldId},OPERATION:t,RIGHT:i}}function ag(e,t,i=[]){return"value"in e?{TYPE:"METHOD_EXPRESSION",PARAMETERS:[{TYPE:"FIELD",NAME:e.field.fieldId},...i],METHOD:t}:null}function rg(e){const t=!(!("value"in e)||void 0===e.value||null===e.value);return Object.assign(Object.assign({},e),t?{value:(t=>{const i=ig(e);if(eg.includes(i))return t;if(Jm.includes(i))return t.toString();if(tg.includes(i))return t;if(Array.isArray(t))throw new Error("Not implemented TernararyOperator or VariadicOperator args in rule value transformer");if(Zm.includes(i))return new Date(t).getTime().toString();throw new Error("Unhandled transformRuleValue case")})(e.value)}:{})}function lg(e,t){return{TYPE:"PREDICATE_EXPRESSION",OPERATION:e.combinator.type,EXPRESSIONS:e.children.map(e=>"children"in e?lg(e,t):t(e)).filter(Boolean)}}function dg(e,t){const i=e.operator.nbInputs;if("many"===i||2===i)throw new Error("Not implemented TernararyOperator or VariadicOperator args in rebuildRuleValue");return Object.assign(Object.assign({},e),0===i?{}:{value:(t=>{const i=ig(e);if(eg.includes(i))return t;if(Xm.includes(i))return parseInt(t);if(Qm.includes(i))return parseFloat(t);if(tg.includes(i))return t;if(Zm.includes(i)){const e=new Date(parseInt(t));return"date"===i?cm(e):um(e)}throw new Error("Unhandled rebuildRuleValue case")})(t.VALUE)})}const cg={template:Sm,styles:fm};var ug;!function(e){e.methodCall={CONTAINS_IGNORE_CASE:"CONTAINS_IGNORE_CASE",CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE:"CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE",IS_NULL_OR_BLANK:"IS_NULL_OR_BLANK",NOT_NULL_OR_BLANK:"NOT_NULL_OR_BLANK",TRIM:"TRIM",LONG_TO_DATE:"LONG_TO_DATE",LONG_TO_DATE_TIME:"LONG_TO_DATE_TIME",DATE_TIME_IS_IN_RANGE:"DATE_TIME_IS_IN_RANGE"},e.logicalOperations={AND:"AND",OR:"OR"},e.operations=Object.assign(Object.assign({},e.logicalOperations),{GREATER_THAN:"GREATER_THAN",LESS_THAN:"LESS_THAN",GREATER_THAN_OR_EQUAL:"GREATER_THAN_OR_EQUAL",LESS_THAN_OR_EQUAL:"LESS_THAN_OR_EQUAL",EQUALS:"EQUALS",NOT_EQUALS:"NOT_EQUALS",PLUS:"PLUS",MINUS:"MINUS",MULTIPLY:"MULTIPLY",DIVIDE:"DIVIDE",BITWISE_AND:"BITWISE_AND",BITWISE_OR:"BITWISE_OR",ASSIGNMENT:"ASSIGNMENT",IS_CURRENT:"IS_CURRENT",IS_PREVIOUS:"IS_PREVIOUS"})}(ug||(ug={}));const hg=[{type:ug.logicalOperations.AND,maxRules:"many"},{type:ug.logicalOperations.OR,maxRules:"many"}],pg={EQUALS:ug.operations.EQUALS,NOT_EQUALS:ug.operations.NOT_EQUALS,IS_NULL:"IS_NULL",NOT_NULL:"NOT_NULL",IS_NULL_OR_BLANK:"IS_NULL_OR_BLANK",NOT_NULL_OR_BLANK:"NOT_NULL_OR_BLANK",CONTAINS:"CONTAINS",CONTAINS_WORDS_STARTING_WITH:"CONTAINS_WORDS_STARTING_WITH",CONTAINS_WORDS_STARTING_SPLIT_DELIMITER:"CONTAINS_WORDS_STARTING_SPLIT_DELIMITER",GREATER_THAN:ug.operations.GREATER_THAN,GREATER_THAN_OR_EQUAL:ug.operations.GREATER_THAN_OR_EQUAL,LESS_THAN:ug.operations.LESS_THAN,LESS_THAN_OR_EQUAL:ug.operations.LESS_THAN_OR_EQUAL,IS_BEFORE:"IS_BEFORE",IS_AFTER:"IS_AFTER",ON_OR_BEFORE:"ON_OR_BEFORE",ON_OR_AFTER:"ON_OR_AFTER",IS_CURRENT:ug.operations.IS_CURRENT,IS_PREVIOUS:ug.operations.IS_PREVIOUS},mg=e=>({type:"enum",input:"select",values:e}),gg=mg({HOUR:{label:"Hour",tooltip:"Beginning of the hour immediately preceding the current one to the current hour."},DAY:{label:"Day",tooltip:"Midnight on the day before today to midnight of the current day."},WEEK_DAY:{label:"Week day",tooltip:"Midnight on the day before today to midnight of the current day. If the current day is Monday then the previous day is Friday."},WEEK:{label:"Week",tooltip:"Midnight on the Monday of the previous week to midnight on the Monday of the current week."},MONTH:{label:"Month",tooltip:"Midnight on the 1st of the previous month to midnight on the 1st of the current month."},YEAR:{label:"Year",tooltip:"Midnight on Jan 1st of the previous year to midnight on the 1st Jan of the current year."}}),vg=mg({HOUR:{label:"Hour",tooltip:"Beginning of the current hour to beginning of the next hour."},DAY:{label:"Day",tooltip:"Midnight on the current day day to midnight of the next day."},WEEK_DAY:{label:"Week day",tooltip:"Midnight on the current day day to midnight of the next day. This filter will never match Sat or Sun, always returning false on the weekends."},WEEK:{label:"Week",tooltip:"Midnight on the Monday of the current week to midnight on the Monday of the next week."},MONTH:{label:"Month",tooltip:"Midnight on the 1st of the current month to midnight on the 1st of the next month."},YEAR:{label:"Year",tooltip:"Midnight on Jan 1st of the current year to midnight on the 1st Jan of the next year."}}),fg=[{type:pg.EQUALS,label:"Equals",nbInputs:1,applyTo:[...eg,...tg,...Jm,...Zm],tooltip:"Check the equality of the field compared to a set value"},{type:pg.NOT_EQUALS,label:"Not equals",nbInputs:1,applyTo:[...eg,...tg,...Jm,...Zm],tooltip:"Check that the field is different from a set value"},{type:pg.IS_NULL,label:"Is null",nbInputs:0,applyTo:["enum",...tg,...Jm,...Zm],tooltip:"Check if the field value is null"},{type:pg.NOT_NULL,label:"Not null",nbInputs:0,applyTo:["enum",...tg,...Jm,...Zm],tooltip:"Check if the field value is not null"},{type:pg.IS_NULL_OR_BLANK,label:"Is null or blank",nbInputs:0,applyTo:["string"],tooltip:"Check if the field value is null or an empty string"},{type:pg.NOT_NULL_OR_BLANK,label:"Not null or blank",nbInputs:0,applyTo:["string"],tooltip:"Check if the field value is not null and not an empty string"},{type:pg.CONTAINS,label:"Contains",nbInputs:1,applyTo:["string"],tooltip:"Check if the field contains the specified text (case insensitive)"},{type:pg.CONTAINS_WORDS_STARTING_WITH,label:"Contains words starting with",nbInputs:1,applyTo:["string"],tooltip:"Check if the field contains words that start with the specified text, split by whitespace (case insensitive)"},{type:pg.CONTAINS_WORDS_STARTING_SPLIT_DELIMITER,label:"Contains words starting with (split)",nbInputs:2,applyTo:["string"],tooltip:"Check if field contains words starting with text, split by a delimiter (case insensitive)"},{type:pg.GREATER_THAN,label:"Greater than",nbInputs:1,applyTo:[...Jm],tooltip:"Check if the field value is greater than a specified number"},{type:pg.GREATER_THAN_OR_EQUAL,label:"Greater than or equal to",nbInputs:1,applyTo:[...Jm],tooltip:"Check if the field value is greater than or equal to a specified number"},{type:pg.LESS_THAN,label:"Less than",nbInputs:1,applyTo:[...Jm],tooltip:"Check if the field value is less than a specified number"},{type:pg.LESS_THAN_OR_EQUAL,label:"Less than or equal to",nbInputs:1,applyTo:[...Jm],tooltip:"Check if the field value is less than or equal to a specified number"},{type:pg.IS_BEFORE,label:"Is before",nbInputs:1,applyTo:[...Zm],tooltip:"Check if the field is before a specified date/time"},{type:pg.IS_AFTER,label:"Is after",nbInputs:1,applyTo:[...Zm],tooltip:"Check if the field is after a specified date/time"},{type:pg.ON_OR_BEFORE,label:"On or before",nbInputs:1,applyTo:[...Zm],tooltip:"Check if the field is on or before a specified date/time"},{type:pg.ON_OR_AFTER,label:"On or after",nbInputs:1,applyTo:[...Zm],tooltip:"Check if the field is on or after a specified date/time"},{type:pg.IS_CURRENT,label:"Is current",nbInputs:1,applyTo:[...Zm],tooltip:"Check whether the current date/time matches the current hour/day/work day/week/month/year.",valueType:vg,optgroup:"Relative Period"},{type:pg.IS_PREVIOUS,label:"Is previous",nbInputs:1,applyTo:[...Zm],tooltip:"Check whether the current date/time matches the previous hour/day/work day/week/month/year",valueType:gg,optgroup:"Relative Period"}];function bg(e){switch(e){case"IS_BEFORE":return"LESS_THAN";case"IS_AFTER":return"GREATER_THAN";case"ON_OR_BEFORE":return"LESS_THAN_OR_EQUAL";case"ON_OR_AFTER":return"GREATER_THAN_OR_EQUAL";default:return e}}function yg(e,t){switch(t){case pg.IS_NULL_OR_BLANK:return ag(e,ug.methodCall.IS_NULL_OR_BLANK,[]);case pg.NOT_NULL_OR_BLANK:return ag(e,ug.methodCall.NOT_NULL_OR_BLANK,[]);case pg.CONTAINS:if(!("value"in e))throw new Error("Invalid shape for operator CONTAINS");return ag(e,ug.methodCall.CONTAINS_IGNORE_CASE,[{TYPE:"STRING",VALUE:e.value}]);case pg.CONTAINS_WORDS_STARTING_WITH:if(!("value"in e))throw new Error("Invalid shape for operator CONTAINS_WORDS_STARTING_WITH");return ag(e,ug.methodCall.CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE,[{TYPE:"STRING",VALUE:e.value}]);case pg.CONTAINS_WORDS_STARTING_SPLIT_DELIMITER:if(!("value"in e)||!Array.isArray(e.value)||2!==e.value.length)throw new Error("Invalid shape for CONTAINS_WORDS_STARTING_SPLIT_DELIMITER");return ag(e,ug.methodCall.CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE,e.value.map(e=>({TYPE:"STRING",VALUE:e})));case pg.IS_CURRENT:case pg.IS_PREVIOUS:if(!("value"in e))throw new Error("Invalid shape for operator IS_CURRENT | IS_PREVIOUS");return ag(e,ug.methodCall.DATE_TIME_IS_IN_RANGE,[{TYPE:"STRING",VALUE:e.value},{TYPE:"STRING",VALUE:t===pg.IS_CURRENT?"CURRENT":"PREVIOUS"}]);default:throw new Error("Unreachable default case")}}function wg(e){var t,i;if(!(null===(t=e.operator)||void 0===t?void 0:t.type)||!(null===(i=e.field)||void 0===i?void 0:i.fieldId))return null;const o=rg(e),n=og(o),s=bg(o.operator.type);switch(s){case pg.EQUALS:case pg.NOT_EQUALS:case pg.GREATER_THAN:case pg.GREATER_THAN_OR_EQUAL:case pg.LESS_THAN:case pg.LESS_THAN_OR_EQUAL:return ng(o,s,n);case pg.IS_NULL:return sg(o,ug.operations.EQUALS,{TYPE:"NULL"});case pg.NOT_NULL:return sg(o,ug.operations.NOT_EQUALS,{TYPE:"NULL"});case pg.IS_NULL_OR_BLANK:case pg.NOT_NULL_OR_BLANK:case pg.CONTAINS:case pg.CONTAINS_WORDS_STARTING_WITH:case pg.CONTAINS_WORDS_STARTING_SPLIT_DELIMITER:case pg.IS_CURRENT:case pg.IS_PREVIOUS:return yg(o,s);default:throw new Error(`Unmatched case for operator name: ${s}`)}}function Cg(e,t){if(!("date"===t.field.type||"date-time"===t.field.type))return e;switch(e){case"LESS_THAN":return"IS_BEFORE";case"GREATER_THAN":return"IS_AFTER";case"LESS_THAN_OR_EQUAL":return"ON_OR_BEFORE";case"GREATER_THAN_OR_EQUAL":return"ON_OR_AFTER";default:return e}}function xg(e,t){const i=(()=>{if("NULL"===t.RIGHT.TYPE){const e="EQUALS"===t.OPERATION?pg[pg.IS_NULL]:pg[pg.NOT_NULL];return fg.find(t=>t.type===e)}const i=Cg(t.OPERATION,e);return fg.find(e=>e.type===i)})();return Object.assign(Object.assign({},e),{operator:i})}function $g(e,t){if("FIELD"!==t.LEFT.TYPE)throw new Error("BinaryExpression LHS must be TYPE === FIELD");if(!["STRING","NUMBER","BOOLEAN","NULL"].includes(t.RIGHT.TYPE))throw new Error("BinaryExpression RHS must be TYPE === NUMBER | STRING | BOOLEAN | NULL");return dg(xg({field:e.find(e=>e.fieldId===t.LEFT.NAME)},t),t.RIGHT)}function Sg(e,t){const[i,o]=(()=>{switch(!0){case"IS_NULL_OR_BLANK"===t.METHOD:return[pg[pg.IS_NULL_OR_BLANK],void 0];case"NOT_NULL_OR_BLANK"===t.METHOD:return[pg[pg.NOT_NULL_OR_BLANK],void 0];case"CONTAINS_IGNORE_CASE"===t.METHOD:return[pg[pg.CONTAINS],t.PARAMETERS[1].VALUE];case"CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE"===t.METHOD&&2===t.PARAMETERS.length:return[pg[pg.CONTAINS_WORDS_STARTING_WITH],t.PARAMETERS[1].VALUE];case"CONTAINS_WORDS_STARTING_WITH_IGNORE_CASE"===t.METHOD&&3===t.PARAMETERS.length:return[pg[pg.CONTAINS_WORDS_STARTING_SPLIT_DELIMITER],t.PARAMETERS.slice(1).map(e=>e.VALUE)];case t.METHOD===ug.methodCall.DATE_TIME_IS_IN_RANGE&&3===t.PARAMETERS.length&&"STRING"===t.PARAMETERS[2].TYPE&&("CURRENT"===t.PARAMETERS[2].VALUE||"PREVIOUS"===t.PARAMETERS[2].VALUE):return[pg["CURRENT"===t.PARAMETERS[2].VALUE?pg.IS_CURRENT:pg.IS_PREVIOUS],t.PARAMETERS[1].VALUE];default:throw new Error("Unhandled fromMethodExpression case")}})();return{field:e.find(e=>e.fieldId===t.PARAMETERS[0].NAME),operator:fg.find(e=>e.type===i),value:o}}function Eg(e,t){return{combinator:hg.find(e=>e.type===t.OPERATION),children:t.EXPRESSIONS.map(t=>{if(!("TYPE"in t))throw new Error("RuleExpression format not yet supported - no TYPE");if("PREDICATE_EXPRESSION"===t.TYPE)return Eg(e,t);if("BINARY_EXPRESSION"===t.TYPE)return $g(e,t);if("METHOD_EXPRESSION"===t.TYPE)return Sg(e,t);throw new Error("RuleExpression format not yet supported - unsupported TYPE")})}}let kg=class extends qm{ruleConfigChanged(e,t){this.config=Object.assign({combinators:hg,operators:fg,fields:t.fields,maxNesting:t.maxNesting,partialRuleValidationWarning:t.partialRuleValidationWarning},(null==t?void 0:t.model)?{model:Eg(t.fields,t.model)}:{})}configChanged(e,t){if(null!==t){if(!t.operators||!t.combinators)throw new Error("Unable to detect operators or combinators. Did you set the config on the rule builder via the config property? Use the ruleConfig property instead");super.configChanged(e,t)}}dispatchChangeEvent(e){const t=lg(e,wg);this.dispatchEvent(new CustomEvent("change",{detail:t,bubbles:!0,cancelable:!0,composed:!0}))}};(0,C.Cg)([l.observable],kg.prototype,"ruleConfig",void 0),kg=(0,C.Cg)([(0,l.customElement)({name:"foundation-rule-expression-builder",styles:fm,template:Sm})],kg);const Og={TRIM:"TRIM",PLUS:"PLUS",MINUS:"MINUS",MULTIPLY:"MULTIPLY",DIVIDE:"DIVIDE",CONVERT_TO_DATE:"CONVERT_TO_DATE",CONVERT_TO_DATE_TIME:"CONVERT_TO_DATE_TIME"},Tg=[{type:Og.PLUS,label:"Add (+)",applyTo:[...Jm],nbInputs:1,tooltip:"Returns the result of the field value mathematically added to the specified rule value. FIELD + VALUE"},{type:Og.MINUS,label:"Subtract (-)",applyTo:[...Jm],nbInputs:1,tooltip:"Returns the result of the field value mathematically subtracted by the specified rule value. FIELD - VALUE"},{type:Og.MULTIPLY,label:"Multiply (*)",applyTo:[...Jm],nbInputs:1,tooltip:"Returns the result of the field value mathematically multiplied by the specified rule value. FIELD * VALUE"},{type:Og.DIVIDE,label:"Divide (/)",applyTo:[...Jm],nbInputs:1,tooltip:"Returns the result of the field value mathematically divided by the specified rule value. FIELD / VALUE"},{type:Og.CONVERT_TO_DATE,label:"Convert to date",applyTo:["date"],nbInputs:0,tooltip:"Returns the date, which is stored as the epoch time, as a formatted date YYYY/dd/mm"},{type:Og.CONVERT_TO_DATE_TIME,label:"Convert to date time",applyTo:["date-time"],nbInputs:0,tooltip:"Returns the date-time, which is stored as the epoch time, as a formatted date YYYY/dd/mm HH:mm:ss"}];function Ig(e){var t,i;if(!(null===(t=e.operator)||void 0===t?void 0:t.type)||!(null===(i=e.field)||void 0===i?void 0:i.fieldId))return null;const o=rg(e),n=og(o),s=o.operator.type;switch(s){case Og.TRIM:case Og.CONVERT_TO_DATE:case Og.CONVERT_TO_DATE_TIME:return function(e,t){switch(t){case Og.TRIM:return ag(e,ug.methodCall.TRIM,[]);case Og.CONVERT_TO_DATE:return ag(e,ug.methodCall.LONG_TO_DATE,[]);case Og.CONVERT_TO_DATE_TIME:return ag(e,ug.methodCall.LONG_TO_DATE_TIME,[])}}(o,s);case Og.PLUS:case Og.MINUS:case Og.DIVIDE:case Og.MULTIPLY:return ng(o,s,n);default:throw new Error(`Unmatched case for operator name: ${s}`)}}function Rg(e,t){if("FIELD"!==t.LEFT.TYPE)throw new Error("BinaryExpression LHS must be TYPE === FIELD");if(!["STRING","NUMBER","BOOLEAN","NULL"].includes(t.RIGHT.TYPE))throw new Error("BinaryExpression RHS must be TYPE === NUMBER | STRING | BOOLEAN | NULL");return dg(function(e,t){const i=(()=>{const i=function(e,t){return"date"===t.field.type||t.field.type,e}(t.OPERATION,e);return Tg.find(e=>e.type===i)})();return Object.assign(Object.assign({},e),{operator:i})}({field:e.find(e=>e.fieldId===t.LEFT.NAME)},t),t.RIGHT)}function Ag(e,t){return{combinator:Kp,children:t.EXPRESSIONS.map(t=>{if(!("TYPE"in t))throw new Error("RuleExpression format not yet supported - no TYPE");if("PREDICATE_EXPRESSION"===t.TYPE)return Ag(e,t);if("BINARY_EXPRESSION"===t.TYPE)return Rg(e,t);if("METHOD_EXPRESSION"===t.TYPE)return function(e,t){const[i,o]=(()=>{switch(!0){case"TRIM"===t.METHOD:return[Og[Og.TRIM],void 0];case"LONG_TO_DATE"===t.METHOD:return[Og[Og.CONVERT_TO_DATE],void 0];case"LONG_TO_DATE_TIME"===t.METHOD:return[Og[Og.CONVERT_TO_DATE_TIME],void 0];default:throw new Error("Unhandled fromMethodExpression case")}})();return{field:e.find(e=>e.fieldId===t.PARAMETERS[0].NAME),operator:Tg.find(e=>e.type===i),value:o}}(e,t);throw new Error("RuleExpression format not yet supported - unsupported TYPE")})}}let Dg=class extends qm{valueConfigChanged(e,t){const i={TYPE:"PREDICATE_EXPRESSION",OPERATION:"NULL",EXPRESSIONS:t.model?[t.model]:[]},o=Ag(t.fields,i);this.config={combinators:[Kp],operators:Tg,fields:t.fields,model:o,maxNesting:t.maxNesting,partialRuleValidationWarning:t.partialRuleValidationWarning}}configChanged(e,t){if(null!==t){if(!t.operators||!t.combinators)throw new Error("Unable to detect operators or combinators. Did you set the config on the rule builder via the config property? Use the valueConfig property instead");super.configChanged(e,t)}}dispatchChangeEvent(e){if(!("children"in e))throw new Error("Invalid top level group hierarchy");if(e.children.length>1)throw new Error("Value expressions should not have multiple rules");if(e.children[0]&&"children"in e.children[0])throw new Error("Trying to convert group to rule");const t=0===e.children.length?void 0:Ig(e.children[0]);this.dispatchEvent(new CustomEvent("change",{detail:t,bubbles:!0,cancelable:!0,composed:!0}))}};(0,C.Cg)([l.observable],Dg.prototype,"valueConfig",void 0),Dg=(0,C.Cg)([(0,l.customElement)({name:"foundation-value-expression-builder",styles:fm,template:Sm})],Dg);const Ng=l.html`
6080
6080
  <template ${(0,l.ref)("notificationListener")}>
6081
6081
  <slot></slot>
6082
6082
  </template>
6083
- `;var Lv;!function(e){e.NOTIFICATION_EVENT="notification-event"}(Lv||(Lv={}));const Fv={mode:"open",delegatesFocus:!0};class Mv extends s.FoundationElement{constructor(){super(...arguments),this.closeTimeout=0,this.toastButtons=[]}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){e.connectedCallback.call(this),this.addEventListener(Lv.NOTIFICATION_EVENT,e=>{e.stopImmediatePropagation(),me(e.detail,this.tagName,this.notificationListener)}),this.connectionSub=this.connect.isConnected$.subscribe(e=>(0,C.sH)(this,void 0,void 0,function*(){e&&(yield this.handleReconnection())}))})}handleReconnection(){return(0,C.sH)(this,void 0,void 0,function*(){this.resourceName&&(yield this.initializeDatasource(),this.setupDataSubscription())})}initializeDatasource(){return(0,C.sH)(this,void 0,void 0,function*(){var e;(null===(e=this.datasource)||void 0===e?void 0:e.initialized)&&this.datasource.destroy();if(!(yield this.datasource.init({resourceName:this.resourceName},!0)))throw new Error(`Failed to initialize datasource for ${this.resourceName}`)})}setupDataSubscription(){this.datasource.stream?this.dataSub=this.datasource.stream.subscribe(e=>{e.ROW&&e.SEQUENCE_ID>1&&this.handleStreamUpdate((0,ei.d)(e))}):Xe.warn(`No stream available for ${this.resourceName}`)}disconnectedCallback(){var e,t,i;super.disconnectedCallback(),null===(e=this.dataSub)||void 0===e||e.unsubscribe(),delete this.dataSub,null===(t=this.connectionSub)||void 0===t||t.unsubscribe(),delete this.connectionSub,null===(i=this.datasource)||void 0===i||i.destroy(),delete this.datasource}handleStreamUpdate(e){const t=e.inserts;t.length>0&&t.forEach(e=>{this.showNotificationToast(e)})}showNotificationToast(e){const{HEADER:t,MESSAGE:i,NOTIFY_SEVERITY:o}=e,n=e.CREATED_AT?new Date(e.CREATED_AT):void 0,a=e.EXPIRY?e.EXPIRY-e.CREATED_AT:void 0;let s=[];this.toastButtons&&this.toastButtons.length>0&&(s=this.toastButtons.filter(({condition:t})=>!t||t({details:e})));const r={title:t,body:i,createdAt:n,toast:{details:e,type:null==o?void 0:o.toLowerCase(),buttons:s,autoClose:void 0!==a?!!a:!!this.closeTimeout,closeTimeout:null!=a?a:this.closeTimeout,position:this.toastPosition}};Nd(r,this.tagName)}}(0,C.Cg)([l.observable],Mv.prototype,"notificationListener",void 0),(0,C.Cg)([ii.dm],Mv.prototype,"connect",void 0),(0,C.Cg)([(0,l.attr)({attribute:"resource-name"})],Mv.prototype,"resourceName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"close-timeout",converter:l.nullableNumberConverter})],Mv.prototype,"closeTimeout",void 0),(0,C.Cg)([l.observable],Mv.prototype,"toastButtons",void 0),(0,C.Cg)([(0,l.attr)({attribute:"toast-position"})],Mv.prototype,"toastPosition",void 0),(0,C.Cg)([oi.yW],Mv.prototype,"datasource",void 0);const _v=Mv.compose({baseName:"notification-listener",template:Nv,shadowOptions:Fv}),Hv=(e,t)=>i=>{const o="function"==typeof t?t:(n=t,e=>Object.assign(Object.assign({},n),e));var n;return l.FASTElement.define(class extends e{},o(i))};function Pv(e){if("string"==typeof e)return e;if("function"==typeof e&&!(e=l.FASTElementDefinition.forType(e)))throw new Error("Missing FASTElement definition.");return e.name}var zv,Uv=i(16171);!function(e){e.controlClicked="controlClicked",e.routeChanged="routeChanged"}(zv||(zv={}));class Bv{constructor(e){this.analytics=(0,Uv.Ay)(e)}trackEvent(e,t){Ia.v.debug(`FoundationAnalytics.trackEvent ${e} : ${JSON.stringify(t)}`),this.analytics.track(e,t)}}const Wv=s.DI.createInterface(e=>e.singleton(Bv));var Gv=i(98647),jv=i(35044);const Vv=(0,Ke.createLogger)("foundation-router");var Yv=i(36132),qv=i(80751),Kv=i(3479);const Xv="$router",Qv=Object.freeze({getOrCreateFor:e=>{const t=e[Xv];return void 0!==t?t:e[Xv]=new Jv(e)},find:e=>Kv.Ix.find(e),from:e=>Kv.Ix.from(e)});class Jv extends Kv.LK{}const Zv=/^([a-z][a-z0-9+\-.]*:)?\/\//i;function eg(e){return Zv.test(e)}function tg(e){return e.config instanceof Gv.Y?e:Qv.find(e)}function ig(e){return tg(e).parent}function og(e){let t=tg(e);for(;t&&t.level>0;)t=t.parent;return t}function ng(e,t="/",i=!1){const o=e.join(t).replace(new RegExp(t+"{1,}","g"),t);return!i&&o.endsWith(t)?o.slice(0,-1):o}function ag(e,t="/"){const i=e.split(t);return 2===i.length&&""===i[0]&&""!==i[1]?e:(i.length>1&&i.pop(),i.join(t))}function sg(e){return e.replace(`/*${qv.N}`,"")}const rg=Object.freeze({path:Object.freeze({get current(){return Yv.qh.path.current},generateRoute:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={}){let o=tg(e);for(;null!==o;){const e=yield o.config.generateRouteFromPath(t,i);if(null!==e)return e;o=o.parent}return null}),push:(e,t=!0)=>{e&&eg(e)?location.href=e:(history.pushState({},document.title,e),t&&rg.path.trigger(e))},replace:(e,t=!0)=>{e&&eg(e)?location.href=e:(history.replaceState({},document.title,e),t&&rg.path.trigger(e))},trigger:e=>{Yv.qh.path.trigger(e)}}),name:Object.freeze({generateRoute:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={}){let o=tg(e);for(;null!==o;){const e=yield o.config.generateRouteFromName(t,i);if(null!==e)return e;o=o.parent}return null}),push:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={},o=!0){const n=yield rg.name.generateRoute(e,t,i);null!==n&&rg.path.push(n,o)}),replace:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={},o=!0){const n=yield rg.name.generateRoute(e,t,i);null!==n&&rg.path.replace(n,o)}),trigger:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={}){const o=yield rg.name.generateRoute(e,t,i);null!==o&&rg.path.trigger(o)})})}),lg=e=>!e.navId||"header"===e.navId||"side-nav"===e.navId,dg=10;function cg(e,t=lg,i=dg){const o=[];return e.filter(e=>e.navItems&&e.navItems.some(t)).forEach((e,n)=>{e.navItems.filter(t).map((t,o)=>{var a,s,r,l;const d=null!==(a=t.placementIndex)&&void 0!==a?a:n*i+o;return Object.assign(Object.assign({},t),{navId:null!==(s=t.navId)&&void 0!==s?s:"header",placementIndex:d,routePath:null!==(r=t.routePath)&&void 0!==r?r:e.path,routeName:null!==(l=t.routeName)&&void 0!==l?l:e.name})}).forEach(e=>o.push(e))}),o.sort((e,t)=>e.placementIndex-t.placementIndex)}class ug extends qv.s{constructor(){super(...arguments),this.definitions=[]}map(...e){const t=this.owner,i=!t.parent,o=t.basename;i&&(""!==o&&"/"!==o)&&(Vv.debug("Route paths remap required due to detected sub-path deployment"),e=e.map(e=>{if(!e.path)return e;if(e.path.startsWith(o))return Vv.debug(`'${e.path}' path okay as is`),e;const t="/"!==e.path.charAt(0)?"/":"",i=`${o}${t}${e.path}`;return Vv.debug(`'${e.path}' path modified to '${i}'`),Object.assign(Object.assign({},e),{path:i})})),this.definitions=[...e,...this.definitions],super.map(...e)}}(0,C.Cg)([l.observable],ug.prototype,"definitions",void 0);class hg extends Gv.Y{constructor(){super(),this.logger=Vv,this.loginPath="login",this.notFoundPath="not-found",this.notPermittedPath="not-permitted",this.routes=new ug(this),this.basename=_n.OB,this.routes=new ug(this)}getNavItems(e=lg){return cg(this.routes.definitions,e)}configureAnalytics(){this.contributors.push({navigate:e=>(0,C.sH)(this,void 0,void 0,function*(){this.analytics.trackEvent(zv.routeChanged,{path:e.route.endpoint.path})})})}configureRoutePermittedChecks(){this.contributors.push({navigate:e=>(0,C.sH)(this,void 0,void 0,function*(){var t;const{settings:i}=e.route;!1===(null===(t=null==i?void 0:i.isPermitted)||void 0===t?void 0:t.call(i))&&e.cancel(()=>{var t,o;if(this.user.isAuthenticated){const n=null!==(o=null===(t=i.notPermittedPath)||void 0===t?void 0:t.call(i))&&void 0!==o?o:this.notPermittedPath;this.logger.debug(`User not permitted to access route. Re-routing to ${n}.`),rg.name.replace(e.router,n)}else this.user.trackPath(),rg.name.replace(e.router,this.loginPath)})})})}configureFallbackRouteDefinition(){this.routes.fallback(()=>{let e={redirect:this.notFoundPath};return this.user.isAuthenticated||(this.user.trackPath(),this._session.captureReturnUrl(),e={redirect:this.loginPath}),this.logger.debug(`Route unresolved. Re-routing to ${e.redirect}.`),e})}navigationPhaseLoginRedirect(e){e.cancel(()=>{this.user.trackPath(),this._session.captureReturnUrl(),rg.name.replace(e.router,this.loginPath)})}generateRouteFromName(e,t){const i=Object.create(null,{generateRouteFromName:{get:()=>super.generateRouteFromName}});return(0,C.sH)(this,void 0,void 0,function*(){const o=yield i.generateRouteFromName.call(this,e,t);return o?this.generateNavigationPath(o):null})}navigateTo(e){return(0,C.sH)(this,void 0,void 0,function*(){if(e.name)return this.relativeTo||this.logger.error("unable to navigate by name as the relativeTo router is not set"),void(yield rg.name.push(this.relativeTo,e.name,e.params,e.trigger));e.path&&rg.path.push(this.generateNavigationPath(e.path,e.params),e.trigger)})}generateNavigationPath(e,t){const i=this.getNavigationPathBasename(),o=jv.C.build(t);let n=i&&!e.startsWith(i)?ng([i,e]):e;return n=o?`${n}?${o}`:n,n}getNavigationPathBasename(){var e,t;const i=this.parent,o=null===(t=null===(e=null==i?void 0:i.relativeTo)||void 0===e?void 0:e.route)||void 0===t?void 0:t.endpoint.route.path;return o?sg(o):this.basename?this.basename:""}construct(e){return this.container.get(e)}}(0,C.Cg)([s.Container],hg.prototype,"container",void 0),(0,C.Cg)([Wv],hg.prototype,"analytics",void 0),(0,C.Cg)([wl.KJ],hg.prototype,"user",void 0),(0,C.Cg)([bi.N],hg.prototype,"_session",void 0);const pg="navigate-to",mg="generate-navigation-path";let vg=class extends(Qv.from(l.FASTElement)){constructor(){super(...arguments),this.logger=Vv,this.onNavigateTo=e=>{e.stopImmediatePropagation(),this.config.navigateTo(e.detail)},this.onGenerateNavigationPath=e=>{e.stopImmediatePropagation();const{path:t,params:i,callback:o}=e.detail;if(!o)return;o(this.config.generateNavigationPath(t,i))}}get router(){return this[Xv]}connectedCallback(){var e,t;super.connectedCallback(),this.config.isConfigured||(null!==(e=(t=this.config).relativeTo)&&void 0!==e||(t.relativeTo=this.router),l.DOM.queueUpdate(()=>(0,C.sH)(this,void 0,void 0,function*(){this.router.config?this.router.connect():this.router.config=this.config})),this.addEventListeners())}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListeners()}addEventListeners(){this.addEventListener(pg,this.onNavigateTo),this.addEventListener(mg,this.onGenerateNavigationPath)}removeEventListeners(){this.removeEventListener(pg,this.onNavigateTo),this.removeEventListener(mg,this.onGenerateNavigationPath)}};vg=(0,C.Cg)([(0,l.customElement)({name:"foundation-router"})],vg);const gg=e=>l.html`
6083
+ `;var Lg;!function(e){e.NOTIFICATION_EVENT="notification-event"}(Lg||(Lg={}));const Fg={mode:"open",delegatesFocus:!0};class Mg extends a.FoundationElement{constructor(){super(...arguments),this.closeTimeout=0,this.toastButtons=[]}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){e.connectedCallback.call(this),this.addEventListener(Lg.NOTIFICATION_EVENT,e=>{e.stopImmediatePropagation(),me(e.detail,this.tagName,this.notificationListener)}),this.connectionSub=this.connect.isConnected$.subscribe(e=>(0,C.sH)(this,void 0,void 0,function*(){e&&(yield this.handleReconnection())}))})}handleReconnection(){return(0,C.sH)(this,void 0,void 0,function*(){this.resourceName&&(yield this.initializeDatasource(),this.setupDataSubscription())})}initializeDatasource(){return(0,C.sH)(this,void 0,void 0,function*(){var e;(null===(e=this.datasource)||void 0===e?void 0:e.initialized)&&this.datasource.destroy();if(!(yield this.datasource.init({resourceName:this.resourceName},!0)))throw new Error(`Failed to initialize datasource for ${this.resourceName}`)})}setupDataSubscription(){this.datasource.stream?this.dataSub=this.datasource.stream.subscribe(e=>{e.ROW&&e.SEQUENCE_ID>1&&this.handleStreamUpdate((0,ei.d)(e))}):Xe.warn(`No stream available for ${this.resourceName}`)}disconnectedCallback(){var e,t,i;super.disconnectedCallback(),null===(e=this.dataSub)||void 0===e||e.unsubscribe(),delete this.dataSub,null===(t=this.connectionSub)||void 0===t||t.unsubscribe(),delete this.connectionSub,null===(i=this.datasource)||void 0===i||i.destroy(),delete this.datasource}handleStreamUpdate(e){const t=e.inserts;t.length>0&&t.forEach(e=>{this.showNotificationToast(e)})}showNotificationToast(e){const{HEADER:t,MESSAGE:i,NOTIFY_SEVERITY:o}=e,n=e.CREATED_AT?new Date(e.CREATED_AT):void 0,s=e.EXPIRY?e.EXPIRY-e.CREATED_AT:void 0;let a=[];this.toastButtons&&this.toastButtons.length>0&&(a=this.toastButtons.filter(({condition:t})=>!t||t({details:e})));const r={title:t,body:i,createdAt:n,toast:{details:e,type:null==o?void 0:o.toLowerCase(),buttons:a,autoClose:void 0!==s?!!s:!!this.closeTimeout,closeTimeout:null!=s?s:this.closeTimeout,position:this.toastPosition}};Nd(r,this.tagName)}}(0,C.Cg)([l.observable],Mg.prototype,"notificationListener",void 0),(0,C.Cg)([ii.dm],Mg.prototype,"connect",void 0),(0,C.Cg)([(0,l.attr)({attribute:"resource-name"})],Mg.prototype,"resourceName",void 0),(0,C.Cg)([(0,l.attr)({attribute:"close-timeout",converter:l.nullableNumberConverter})],Mg.prototype,"closeTimeout",void 0),(0,C.Cg)([l.observable],Mg.prototype,"toastButtons",void 0),(0,C.Cg)([(0,l.attr)({attribute:"toast-position"})],Mg.prototype,"toastPosition",void 0),(0,C.Cg)([oi.yW],Mg.prototype,"datasource",void 0);const _g=Mg.compose({baseName:"notification-listener",template:Ng,shadowOptions:Fg}),Hg=(e,t)=>i=>{const o="function"==typeof t?t:(n=t,e=>Object.assign(Object.assign({},n),e));var n;return l.FASTElement.define(class extends e{},o(i))};function Pg(e){if("string"==typeof e)return e;if("function"==typeof e&&!(e=l.FASTElementDefinition.forType(e)))throw new Error("Missing FASTElement definition.");return e.name}var zg,Ug=i(16171);!function(e){e.controlClicked="controlClicked",e.routeChanged="routeChanged"}(zg||(zg={}));class Wg{constructor(e){this.analytics=(0,Ug.Ay)(e)}trackEvent(e,t){Is.v.debug(`FoundationAnalytics.trackEvent ${e} : ${JSON.stringify(t)}`),this.analytics.track(e,t)}}const Gg=a.DI.createInterface(e=>e.singleton(Wg));var Bg=i(98647),Vg=i(35044);const jg=(0,Ke.createLogger)("foundation-router");var Yg=i(36132),qg=i(80751),Kg=i(3479);const Xg="$router",Qg=Object.freeze({getOrCreateFor:e=>{const t=e[Xg];return void 0!==t?t:e[Xg]=new Jg(e)},find:e=>Kg.Ix.find(e),from:e=>Kg.Ix.from(e)});class Jg extends Kg.LK{}const Zg=/^([a-z][a-z0-9+\-.]*:)?\/\//i;function ev(e){return Zg.test(e)}function tv(e){return e.config instanceof Bg.Y?e:Qg.find(e)}function iv(e){return tv(e).parent}function ov(e){let t=tv(e);for(;t&&t.level>0;)t=t.parent;return t}function nv(e,t="/",i=!1){const o=e.join(t).replace(new RegExp(t+"{1,}","g"),t);return!i&&o.endsWith(t)?o.slice(0,-1):o}function sv(e,t="/"){const i=e.split(t);return 2===i.length&&""===i[0]&&""!==i[1]?e:(i.length>1&&i.pop(),i.join(t))}function av(e){return e.replace(`/*${qg.N}`,"")}const rv=Object.freeze({path:Object.freeze({get current(){return Yg.qh.path.current},generateRoute:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={}){let o=tv(e);for(;null!==o;){const e=yield o.config.generateRouteFromPath(t,i);if(null!==e)return e;o=o.parent}return null}),push:(e,t=!0)=>{e&&ev(e)?location.href=e:(history.pushState({},document.title,e),t&&rv.path.trigger(e))},replace:(e,t=!0)=>{e&&ev(e)?location.href=e:(history.replaceState({},document.title,e),t&&rv.path.trigger(e))},trigger:e=>{Yg.qh.path.trigger(e)}}),name:Object.freeze({generateRoute:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={}){let o=tv(e);for(;null!==o;){const e=yield o.config.generateRouteFromName(t,i);if(null!==e)return e;o=o.parent}return null}),push:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={},o=!0){const n=yield rv.name.generateRoute(e,t,i);null!==n&&rv.path.push(n,o)}),replace:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={},o=!0){const n=yield rv.name.generateRoute(e,t,i);null!==n&&rv.path.replace(n,o)}),trigger:(e,t,...i)=>(0,C.sH)(void 0,[e,t,...i],void 0,function*(e,t,i={}){const o=yield rv.name.generateRoute(e,t,i);null!==o&&rv.path.trigger(o)})})}),lv=e=>!e.navId||"header"===e.navId||"side-nav"===e.navId,dv=10;function cv(e,t=lv,i=dv){const o=[];return e.filter(e=>e.navItems&&e.navItems.some(t)).forEach((e,n)=>{e.navItems.filter(t).map((t,o)=>{var s,a,r,l;const d=null!==(s=t.placementIndex)&&void 0!==s?s:n*i+o;return Object.assign(Object.assign({},t),{navId:null!==(a=t.navId)&&void 0!==a?a:"header",placementIndex:d,routePath:null!==(r=t.routePath)&&void 0!==r?r:e.path,routeName:null!==(l=t.routeName)&&void 0!==l?l:e.name})}).forEach(e=>o.push(e))}),o.sort((e,t)=>e.placementIndex-t.placementIndex)}class uv extends qg.s{constructor(){super(...arguments),this.definitions=[]}map(...e){const t=this.owner,i=!t.parent,o=t.basename;i&&(""!==o&&"/"!==o)&&(jg.debug("Route paths remap required due to detected sub-path deployment"),e=e.map(e=>{if(!e.path)return e;if(e.path.startsWith(o))return jg.debug(`'${e.path}' path okay as is`),e;const t="/"!==e.path.charAt(0)?"/":"",i=`${o}${t}${e.path}`;return jg.debug(`'${e.path}' path modified to '${i}'`),Object.assign(Object.assign({},e),{path:i})})),this.definitions=[...e,...this.definitions],super.map(...e)}}(0,C.Cg)([l.observable],uv.prototype,"definitions",void 0);class hv extends Bg.Y{constructor(){super(),this.logger=jg,this.loginPath="login",this.notFoundPath="not-found",this.notPermittedPath="not-permitted",this.routes=new uv(this),this.basename=_n.OB,this.routes=new uv(this)}getNavItems(e=lv){return cv(this.routes.definitions,e)}configureAnalytics(){this.contributors.push({navigate:e=>(0,C.sH)(this,void 0,void 0,function*(){this.analytics.trackEvent(zg.routeChanged,{path:e.route.endpoint.path})})})}configureRoutePermittedChecks(){this.contributors.push({navigate:e=>(0,C.sH)(this,void 0,void 0,function*(){var t;const{settings:i}=e.route;!1===(null===(t=null==i?void 0:i.isPermitted)||void 0===t?void 0:t.call(i))&&e.cancel(()=>{var t,o;if(this.user.isAuthenticated){const n=null!==(o=null===(t=i.notPermittedPath)||void 0===t?void 0:t.call(i))&&void 0!==o?o:this.notPermittedPath;this.logger.debug(`User not permitted to access route. Re-routing to ${n}.`),rv.name.replace(e.router,n)}else this.user.trackPath(),rv.name.replace(e.router,this.loginPath)})})})}configureFallbackRouteDefinition(){this.routes.fallback(()=>{let e={redirect:this.notFoundPath};return this.user.isAuthenticated||(this.user.trackPath(),this._session.captureReturnUrl(),e={redirect:this.loginPath}),this.logger.debug(`Route unresolved. Re-routing to ${e.redirect}.`),e})}navigationPhaseLoginRedirect(e){e.cancel(()=>{this.user.trackPath(),this._session.captureReturnUrl(),rv.name.replace(e.router,this.loginPath)})}generateRouteFromName(e,t){const i=Object.create(null,{generateRouteFromName:{get:()=>super.generateRouteFromName}});return(0,C.sH)(this,void 0,void 0,function*(){const o=yield i.generateRouteFromName.call(this,e,t);return o?this.generateNavigationPath(o):null})}navigateTo(e){return(0,C.sH)(this,void 0,void 0,function*(){if(e.name)return this.relativeTo||this.logger.error("unable to navigate by name as the relativeTo router is not set"),void(yield rv.name.push(this.relativeTo,e.name,e.params,e.trigger));e.path&&rv.path.push(this.generateNavigationPath(e.path,e.params),e.trigger)})}generateNavigationPath(e,t){const i=this.getNavigationPathBasename(),o=Vg.C.build(t);let n=i&&!e.startsWith(i)?nv([i,e]):e;return n=o?`${n}?${o}`:n,n}getNavigationPathBasename(){var e,t;const i=this.parent,o=null===(t=null===(e=null==i?void 0:i.relativeTo)||void 0===e?void 0:e.route)||void 0===t?void 0:t.endpoint.route.path;return o?av(o):this.basename?this.basename:""}construct(e){return this.container.get(e)}}(0,C.Cg)([a.Container],hv.prototype,"container",void 0),(0,C.Cg)([Gg],hv.prototype,"analytics",void 0),(0,C.Cg)([wl.KJ],hv.prototype,"user",void 0),(0,C.Cg)([bi.N],hv.prototype,"_session",void 0);const pv="navigate-to",mv="generate-navigation-path";let gv=class extends(Qg.from(l.FASTElement)){constructor(){super(...arguments),this.logger=jg,this.onNavigateTo=e=>{e.stopImmediatePropagation(),this.config.navigateTo(e.detail)},this.onGenerateNavigationPath=e=>{e.stopImmediatePropagation();const{path:t,params:i,callback:o}=e.detail;if(!o)return;o(this.config.generateNavigationPath(t,i))}}get router(){return this[Xg]}connectedCallback(){var e,t;super.connectedCallback(),this.config.isConfigured||(null!==(e=(t=this.config).relativeTo)&&void 0!==e||(t.relativeTo=this.router),l.DOM.queueUpdate(()=>(0,C.sH)(this,void 0,void 0,function*(){this.router.config?this.router.connect():this.router.config=this.config})),this.addEventListeners())}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListeners()}addEventListeners(){this.addEventListener(pv,this.onNavigateTo),this.addEventListener(mv,this.onGenerateNavigationPath)}removeEventListeners(){this.removeEventListener(pv,this.onNavigateTo),this.removeEventListener(mv,this.onGenerateNavigationPath)}};gv=(0,C.Cg)([(0,l.customElement)({name:"foundation-router"})],gv);const vv=e=>l.html`
6084
6084
 
6085
6085
  <${e}-card class=${e=>(0,x.x)("stepper-tab",["stepper-tab-hidden",e.hideTabs])} part="stepper-tab" @tab-clicked="${(e,t)=>e.handleStepClick(t.event.detail)}" role="stepper-tab" data-test-id="stepper-tab">
6086
6086
  <div class=${e=>(0,x.x)("stepper-tab-menu",["stepper-tab-menu-hidden",e.hideTabs])} part="stepper-tab-menu">
6087
6087
  <slot name="tab" ${(0,l.slotted)("tabs")} ></slot>
6088
6088
  </div>
6089
- ${(0,l.when)(e=>e.orientation===s.TabsOrientation.vertical,l.html`
6089
+ ${(0,l.when)(e=>e.orientation===a.TabsOrientation.vertical,l.html`
6090
6090
  <div class="stepper-tab-progress" part="stepper-tab-progress">
6091
6091
  <${e}-progress-ring class="progress-ring" part="progress-ring" value=${e=>e.progressValue}></${e}-progress-ring>
6092
6092
  <label>You have completed ${e=>e.progressValue}% of the fields required to create a project</label>
@@ -6111,9 +6111,9 @@ class="margin"
6111
6111
  </div>
6112
6112
  `)}
6113
6113
  </${e}-card>
6114
- `,fg=l.html`
6115
- ${e=>gg(O(e))}
6116
- `,bg=l.css`
6114
+ `,fv=l.html`
6115
+ ${e=>vv(O(e))}
6116
+ `,bv=l.css`
6117
6117
  :host {
6118
6118
  display: flex;
6119
6119
  height: 100%;
@@ -6212,7 +6212,11 @@ class="margin"
6212
6212
  max-height: 70px;
6213
6213
  height: 70px;
6214
6214
  }
6215
- `;class yg extends s.FoundationElement{constructor(){super(...arguments),this.allowBackwardJumps=!1,this.allowForwardJumps=!1,this.hideAllButtons=!1,this.hideTabs=!1,this.orientation=s.TabsOrientation.vertical,this.progressValue=0,this.activeTabIndex=0,this.pendingNextStep=!1,this.slotsInitialized=!1,this.setTabs=()=>{this.activeTabIndex=this.getActiveIndex(),this.tabs.forEach((e,t)=>{if("tab"===e.slot){const i=this.activeTabIndex===t,o=t+1===this.tabIds.length,n=this.tabIds[t],a=this.tabpanelIds[t];e.setAttribute("id",n),e.setAttribute("aria-selected",i?"true":"false"),e.setAttribute("aria-disabled",i?"false":"true"),e.setAttribute("selected",i?"true":"false"),e.setAttribute("orientation",this.orientation),e.setAttribute("aria-controls",a),e.setAttribute("aria-controls",a),e.setAttribute("tab-position",String(t+1)),e.setAttribute("isLast",String(o)),e.setAttribute("hideStepNumber",String(!0===this.hideStepNumber)),e.setAttribute("tabindex",i?"0":"-1"),e.setAttribute("showCursorPointer",String(t<=this.activeTabIndex&&this.allowBackwardJumps||t>this.activeTabIndex&&this.allowForwardJumps)),i&&(this.activetab=e,this.activeid=n)}}),0===this.activeTabIndex&&this.resetCompletedState()},this.getCompletedTabs=()=>{let e=0;this.tabs.forEach(t=>{t.isCompleted()&&(e+=1)}),this.progressValue=Math.round(e/this.tabpanels.length*100)},this.setTabPanels=()=>{this.tabpanels.forEach((e,t)=>{const i=this.tabIds[t],o=this.tabpanelIds[t];e.setAttribute("id",o),e.setAttribute("aria-labelledby",i),this.activeTabIndex!==t?e.setAttribute("hidden",""):e.removeAttribute("hidden")})}}orientationChanged(){this.$fastController.isConnected&&(this.setTabs(),this.setTabPanels())}activeidChanged(e,t){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.setTabs(),this.setTabPanels(),this.getCompletedTabs())}tabsChanged(){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.setTabsAndTabPanels(),this.checkAndExecutePendingNextStep())}tabpanelsChanged(){this.$fastController.isConnected&&this.tabpanels.length<=this.tabs.length&&(this.setTabsAndTabPanels(),this.checkAndExecutePendingNextStep())}connectedCallback(){super.connectedCallback(),this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.activeTabIndex=this.getActiveIndex()}setTabsAndTabPanels(){this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.setTabs(),this.setTabPanels(),this.getCompletedTabs(),this.slotsInitialized=this.tabs.length>0&&this.tabpanels.length>0}checkAndExecutePendingNextStep(){this.pendingNextStep&&this.slotsInitialized&&(this.pendingNextStep=!1,this.nextStep())}getActiveIndex(){return void 0!==this.activeid?-1===this.tabIds.indexOf(this.activeid)?0:this.tabIds.indexOf(this.activeid):0}goToStep(e,t=!1){const i=e-1;if(e<1||e>this.tabs.length)return Xe.warn(`[Stepper] Invalid step number: ${e}. Must be between 1 and ${this.tabs.length}`),!1;if(i===this.activeTabIndex)return!1;if(t){if(i<this.activeTabIndex)return this.handleBackwardJump(i);if(i>this.activeTabIndex)return this.handleForwardJump(i)}if(i<this.activeTabIndex&&this.allowBackwardJumps){return this.handleBackwardJump(i)}if(i>this.activeTabIndex&&this.allowForwardJumps){return this.handleForwardJump(i)}return i===this.activeTabIndex+1?(this.nextStep(),!0):(Xe.warn(`[Stepper] Cannot jump to step ${e}. Jumps are not allowed or step is not adjacent.`),!1)}goToFirstStep(){return this.goToStep(1,!0)}goToLastStep(){return this.goToStep(this.tabs.length,!0)}handleStepClick(e){e<this.activeTabIndex&&this.allowBackwardJumps?this.handleBackwardJump(e):e>this.activeTabIndex&&this.allowForwardJumps&&this.handleForwardJump(e)}handleBackwardJump(e){for(let t=e+1;t<=this.activeTabIndex;t+=1)this.tabs[t].completed=!1;return this.activeTabIndex=e,this.activetab=this.tabs[e],this.activeid=this.tabIds[e],this.$emit("step-click",{activetab:this.activetab,activeid:this.activeid}),!0}handleForwardJump(e){for(let t=this.activeTabIndex;t<e;t+=1)if(this.validation&&this.validation[t]){if(!this.validation[t].isValid())return this.tabs[t].completed=!1,this.tabs[t].error=!0,this.getCompletedTabs(),this.$emit("validation-failure",{stepIndex:t,stepId:this.tabIds[t],message:`Validation failed for step ${t+1}`}),!1;this.tabs[t].error=!1}for(let t=this.activeTabIndex;t<e;t+=1)this.tabs[t].completed=!0,this.tabs[t].error=!1;return this.tabs[e].completed=!1,this.tabs[e].error=!1,this.activeTabIndex=e,this.activetab=this.tabs[e],this.activeid=this.tabIds[e],this.getCompletedTabs(),this.$emit("step-click",{activetab:this.activetab,activeid:this.activeid}),!0}get disabledPreviousStep(){return 0===this.activeTabIndex}get isLastStep(){return this.activeTabIndex+1===this.tabs.length}get islastStepValid(){var e;const t=this.tabs.length-1;return this.activeTabIndex===t&&(this.validation&&(null===(e=this.validation[t])||void 0===e?void 0:e.isValid())||!this.validation||!this.validation[t])?(this.tabs[t].completed=!0,this.getCompletedTabs(),!1):(this.tabs[t].completed=!1,this.getCompletedTabs(),!0)}_submit(){this.$emit("submit")}nextStep(){var e;if(!this.slotsInitialized)return void(this.pendingNextStep=!0);if(this.validation&&this.validation[this.activeTabIndex]){if(!this.validation[this.activeTabIndex].isValid())return this.tabs[this.activeTabIndex].completed=!1,this.tabs[this.activeTabIndex].error=!0,void this.getCompletedTabs();this.tabs[this.activeTabIndex].error=!1}this.activeTabIndex+2<=this.tabIds.length&&(this.tabs[this.activeTabIndex].completed=!0,this.activeTabIndex=this.activeTabIndex+1,this.activeid=this.tabIds[this.activeTabIndex],this.$emit("next-step"),this.$emit("validation-success"));const t=this.tabs.length-1,i=this.activeTabIndex===t;this.hideSubmitButton&&i&&(this.validation&&(null===(e=this.validation[t])||void 0===e?void 0:e.isValid())||!this.validation||!this.validation[t])?(this.tabs[t].completed=!0,this.getCompletedTabs()):(this.tabs[t].completed=!1,this.getCompletedTabs())}previousStep(){0!==this.activeTabIndex&&(this.tabs[this.activeTabIndex].completed=!1,this.activeTabIndex=this.activeTabIndex-1,this.activeid=this.tabIds[this.activeTabIndex])}getTabIds(){return this.tabs.map(e=>{var t;return null!==(t=e.getAttribute("id"))&&void 0!==t?t:`tab-${(0,is.NF)()}`})}getTabPanelIds(){return this.tabpanels.map(e=>{var t;return null!==(t=e.getAttribute("id"))&&void 0!==t?t:`panel-${(0,is.NF)()}`})}resetCompletedState(){this.tabs.forEach(e=>e.completed=!1)}}(0,C.Cg)([(0,l.attr)({attribute:"hide-submit-button",mode:"boolean"})],yg.prototype,"hideSubmitButton",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-step-number",mode:"boolean"})],yg.prototype,"hideStepNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"allow-backward-jumps",mode:"boolean"})],yg.prototype,"allowBackwardJumps",void 0),(0,C.Cg)([(0,l.attr)({attribute:"allow-forward-jumps",mode:"boolean"})],yg.prototype,"allowForwardJumps",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-all-buttons",mode:"boolean"})],yg.prototype,"hideAllButtons",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-tabs",mode:"boolean"})],yg.prototype,"hideTabs",void 0),(0,C.Cg)([l.attr],yg.prototype,"orientation",void 0),(0,C.Cg)([l.attr],yg.prototype,"activeid",void 0),(0,C.Cg)([l.observable],yg.prototype,"tabs",void 0),(0,C.Cg)([l.observable],yg.prototype,"tabpanels",void 0),(0,C.Cg)([l.observable],yg.prototype,"validation",void 0),(0,C.Cg)([l.observable],yg.prototype,"progressValue",void 0),(0,C.Cg)([l.observable],yg.prototype,"activeTabIndex",void 0),(0,C.Cg)([l.volatile],yg.prototype,"disabledPreviousStep",null),(0,C.Cg)([l.volatile],yg.prototype,"isLastStep",null),(0,C.Cg)([l.volatile],yg.prototype,"islastStepValid",null);const wg=void 0,Cg={},xg=yg.compose(Object.assign({baseName:"stepper",template:fg,styles:bg,shadowOptions:wg},Cg)),$g=s.DI.createInterface("LayoutRegistry"),Sg=s.DI.createInterface("GridRegistry"),Eg=s.DI.createInterface("FilterRegistry"),kg=s.DI.createInterface("WorkspaceState");var Og=i(40113),Tg=i(96999);const Ig=l.css`
6215
+ `;class yv extends a.FoundationElement{constructor(){super(...arguments),this.allowBackwardJumps=!1,this.allowForwardJumps=!1,this.hideAllButtons=!1,this.hideTabs=!1,this.orientation=a.TabsOrientation.vertical,this.progressValue=0,this.activeTabIndex=0,this.pendingNextStep=!1,this.slotsInitialized=!1,this.setTabs=()=>{this.activeTabIndex=this.getActiveIndex(),this.tabs.forEach((e,t)=>{if("tab"===e.slot){const i=this.activeTabIndex===t,o=t+1===this.tabIds.length,n=this.tabIds[t],s=this.tabpanelIds[t];e.setAttribute("id",n),e.setAttribute("aria-selected",i?"true":"false"),e.setAttribute("aria-disabled",i?"false":"true"),e.setAttribute("selected",i?"true":"false"),e.setAttribute("orientation",this.orientation),e.setAttribute("aria-controls",s),e.setAttribute("aria-controls",s),e.setAttribute("tab-position",String(t+1)),e.setAttribute("isLast",String(o)),e.setAttribute("hideStepNumber",String(!0===this.hideStepNumber)),e.setAttribute("tabindex",i?"0":"-1"),e.setAttribute("showCursorPointer",String(t<=this.activeTabIndex&&this.allowBackwardJumps||t>this.activeTabIndex&&this.allowForwardJumps)),i&&(this.activetab=e,this.activeid=n)}}),0===this.activeTabIndex&&this.resetCompletedState()},this.getCompletedTabs=()=>{let e=0;this.tabs.forEach(t=>{t.isCompleted()&&(e+=1)}),this.progressValue=Math.round(e/this.tabpanels.length*100)},this.setTabPanels=()=>{this.tabpanels.forEach((e,t)=>{const i=this.tabIds[t],o=this.tabpanelIds[t];e.setAttribute("id",o),e.setAttribute("aria-labelledby",i),this.activeTabIndex!==t?e.setAttribute("hidden",""):e.removeAttribute("hidden")})}}orientationChanged(){this.$fastController.isConnected&&(this.setTabs(),this.setTabPanels())}activeidChanged(e,t){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.setTabs(),this.setTabPanels(),this.getCompletedTabs())}tabsChanged(){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.setTabsAndTabPanels(),this.checkAndExecutePendingNextStep())}tabpanelsChanged(){this.$fastController.isConnected&&this.tabpanels.length<=this.tabs.length&&(this.setTabsAndTabPanels(),this.checkAndExecutePendingNextStep())}connectedCallback(){super.connectedCallback(),this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.activeTabIndex=this.getActiveIndex()}setTabsAndTabPanels(){this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.setTabs(),this.setTabPanels(),this.getCompletedTabs(),this.slotsInitialized=this.tabs.length>0&&this.tabpanels.length>0}checkAndExecutePendingNextStep(){this.pendingNextStep&&this.slotsInitialized&&(this.pendingNextStep=!1,this.nextStep())}getActiveIndex(){return void 0!==this.activeid?-1===this.tabIds.indexOf(this.activeid)?0:this.tabIds.indexOf(this.activeid):0}goToStep(e,t=!1){const i=e-1;if(e<1||e>this.tabs.length)return Xe.warn(`[Stepper] Invalid step number: ${e}. Must be between 1 and ${this.tabs.length}`),!1;if(i===this.activeTabIndex)return!1;if(t){if(i<this.activeTabIndex)return this.handleBackwardJump(i);if(i>this.activeTabIndex)return this.handleForwardJump(i)}if(i<this.activeTabIndex&&this.allowBackwardJumps){return this.handleBackwardJump(i)}if(i>this.activeTabIndex&&this.allowForwardJumps){return this.handleForwardJump(i)}return i===this.activeTabIndex+1?(this.nextStep(),!0):(Xe.warn(`[Stepper] Cannot jump to step ${e}. Jumps are not allowed or step is not adjacent.`),!1)}goToFirstStep(){return this.goToStep(1,!0)}goToLastStep(){return this.goToStep(this.tabs.length,!0)}handleStepClick(e){e<this.activeTabIndex&&this.allowBackwardJumps?this.handleBackwardJump(e):e>this.activeTabIndex&&this.allowForwardJumps&&this.handleForwardJump(e)}handleBackwardJump(e){for(let t=e+1;t<=this.activeTabIndex;t+=1)this.tabs[t].completed=!1;return this.activeTabIndex=e,this.activetab=this.tabs[e],this.activeid=this.tabIds[e],this.$emit("step-click",{activetab:this.activetab,activeid:this.activeid}),!0}handleForwardJump(e){for(let t=this.activeTabIndex;t<e;t+=1)if(this.validation&&this.validation[t]){if(!this.validation[t].isValid())return this.tabs[t].completed=!1,this.tabs[t].error=!0,this.getCompletedTabs(),this.$emit("validation-failure",{stepIndex:t,stepId:this.tabIds[t],message:`Validation failed for step ${t+1}`}),!1;this.tabs[t].error=!1}for(let t=this.activeTabIndex;t<e;t+=1)this.tabs[t].completed=!0,this.tabs[t].error=!1;return this.tabs[e].completed=!1,this.tabs[e].error=!1,this.activeTabIndex=e,this.activetab=this.tabs[e],this.activeid=this.tabIds[e],this.getCompletedTabs(),this.$emit("step-click",{activetab:this.activetab,activeid:this.activeid}),!0}get disabledPreviousStep(){return 0===this.activeTabIndex}get isLastStep(){return this.activeTabIndex+1===this.tabs.length}get islastStepValid(){var e;const t=this.tabs.length-1;return this.activeTabIndex===t&&(this.validation&&(null===(e=this.validation[t])||void 0===e?void 0:e.isValid())||!this.validation||!this.validation[t])?(this.tabs[t].completed=!0,this.getCompletedTabs(),!1):(this.tabs[t].completed=!1,this.getCompletedTabs(),!0)}_submit(){this.$emit("submit")}nextStep(){var e;if(!this.slotsInitialized)return void(this.pendingNextStep=!0);if(this.validation&&this.validation[this.activeTabIndex]){if(!this.validation[this.activeTabIndex].isValid())return this.tabs[this.activeTabIndex].completed=!1,this.tabs[this.activeTabIndex].error=!0,void this.getCompletedTabs();this.tabs[this.activeTabIndex].error=!1}this.activeTabIndex+2<=this.tabIds.length&&(this.tabs[this.activeTabIndex].completed=!0,this.activeTabIndex=this.activeTabIndex+1,this.activeid=this.tabIds[this.activeTabIndex],this.$emit("next-step"),this.$emit("validation-success"));const t=this.tabs.length-1,i=this.activeTabIndex===t;this.hideSubmitButton&&i&&(this.validation&&(null===(e=this.validation[t])||void 0===e?void 0:e.isValid())||!this.validation||!this.validation[t])?(this.tabs[t].completed=!0,this.getCompletedTabs()):(this.tabs[t].completed=!1,this.getCompletedTabs())}previousStep(){0!==this.activeTabIndex&&(this.tabs[this.activeTabIndex].completed=!1,this.activeTabIndex=this.activeTabIndex-1,this.activeid=this.tabIds[this.activeTabIndex])}getTabIds(){return this.tabs.map(e=>{var t;return null!==(t=e.getAttribute("id"))&&void 0!==t?t:`tab-${(0,ia.NF)()}`})}getTabPanelIds(){return this.tabpanels.map(e=>{var t;return null!==(t=e.getAttribute("id"))&&void 0!==t?t:`panel-${(0,ia.NF)()}`})}resetCompletedState(){this.tabs.forEach(e=>e.completed=!1)}}(0,C.Cg)([(0,l.attr)({attribute:"hide-submit-button",mode:"boolean"})],yv.prototype,"hideSubmitButton",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-step-number",mode:"boolean"})],yv.prototype,"hideStepNumber",void 0),(0,C.Cg)([(0,l.attr)({attribute:"allow-backward-jumps",mode:"boolean"})],yv.prototype,"allowBackwardJumps",void 0),(0,C.Cg)([(0,l.attr)({attribute:"allow-forward-jumps",mode:"boolean"})],yv.prototype,"allowForwardJumps",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-all-buttons",mode:"boolean"})],yv.prototype,"hideAllButtons",void 0),(0,C.Cg)([(0,l.attr)({attribute:"hide-tabs",mode:"boolean"})],yv.prototype,"hideTabs",void 0),(0,C.Cg)([l.attr],yv.prototype,"orientation",void 0),(0,C.Cg)([l.attr],yv.prototype,"activeid",void 0),(0,C.Cg)([l.observable],yv.prototype,"tabs",void 0),(0,C.Cg)([l.observable],yv.prototype,"tabpanels",void 0),(0,C.Cg)([l.observable],yv.prototype,"validation",void 0),(0,C.Cg)([l.observable],yv.prototype,"progressValue",void 0),(0,C.Cg)([l.observable],yv.prototype,"activeTabIndex",void 0),(0,C.Cg)([l.volatile],yv.prototype,"disabledPreviousStep",null),(0,C.Cg)([l.volatile],yv.prototype,"isLastStep",null),(0,C.Cg)([l.volatile],yv.prototype,"islastStepValid",null);const wv=void 0,Cv={},xv=yv.compose(Object.assign({baseName:"stepper",template:fv,styles:bv,shadowOptions:wv},Cv));var $v=i(83039),Sv=i(40113);let Ev=class{constructor(e,t){this.kvStorage=e,this.auth=t,this.STORAGE_PREFIX="workspace_",this.WORKSPACES_LIST_KEY="workspaces_list",this.currentWorkspace=null}getCurrentUsername(){var e,t;return(null===(t=null===(e=this.auth)||void 0===e?void 0:e.loggedUserResult)||void 0===t?void 0:t.username)||"anonymous"}getWorkspaceStorageKey(e){const t=this.getCurrentUsername();return`${this.STORAGE_PREFIX}${t}_${e}`}getWorkspacesListKey(){const e=this.getCurrentUsername();return`${this.STORAGE_PREFIX}${e}_${this.WORKSPACES_LIST_KEY}`}saveWorkspace(e,t,i,o,n){return(0,C.sH)(this,void 0,void 0,function*(){const s=this.getWorkspaceStorageKey(e),a=this.getCurrentUsername(),r={name:e,username:a,description:(null==n?void 0:n.trim())||void 0,layouts:t,grids:i,filters:o,savedAt:(new Date).toISOString()};yield this.kvStorage.put([{key:s,value:JSON.stringify(r)}]),yield this.updateWorkspacesList(e)})}loadWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){const t=yield this.getWorkspace(e);return this.currentWorkspace=null!=t?t:null,this.currentWorkspace})}getWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){var t;const i=this.getWorkspaceStorageKey(e),o=yield this.kvStorage.get(i);if(!(null===(t=null==o?void 0:o.kv)||void 0===t?void 0:t.value))return null;try{const t="string"==typeof o.kv.value?JSON.parse(o.kv.value):o.kv.value,i=this.getCurrentUsername();return t.username&&t.username!==i?(console.warn(`Workspace ${e} does not belong to current user`),null):(t.username||(t.username=i),t||null)}catch(e){return console.warn("Failed to parse saved workspace",e),null}})}getCurrentWorkspace(){return this.currentWorkspace}setCurrentWorkspace(e){this.currentWorkspace=e}getSavedWorkspaces(){return(0,C.sH)(this,void 0,void 0,function*(){var e;const t=this.getWorkspaceStorageKey(this.WORKSPACES_LIST_KEY),i=yield this.kvStorage.get(t);if(!(null===(e=null==i?void 0:i.kv)||void 0===e?void 0:e.value))return[];try{const e="string"==typeof i.kv.value?JSON.parse(i.kv.value):i.kv.value;if(!Array.isArray(e))return[];const t=[],o=this.getCurrentUsername();for(const i of e){const e=yield this.getWorkspace(i);!e||e.username&&e.username!==o||t.push(e)}return t}catch(e){return console.warn("Failed to parse saved workspaces list",e),[]}})}deleteWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){const t=this.getWorkspaceStorageKey(e);yield this.kvStorage.delete([t]),yield this.removeFromWorkspacesList(e)})}updateWorkspacesList(e){return(0,C.sH)(this,void 0,void 0,function*(){var t;const i=this.getWorkspacesListKey(),o=yield this.kvStorage.get(i);let n=[];if(null===(t=null==o?void 0:o.kv)||void 0===t?void 0:t.value)try{n="string"==typeof o.kv.value?JSON.parse(o.kv.value):o.kv.value}catch(e){console.warn("Failed to parse workspaces list",e)}n=n.filter(t=>t!==e),n.push(e),yield this.kvStorage.put([{key:i,value:JSON.stringify(n)}])})}removeFromWorkspacesList(e){return(0,C.sH)(this,void 0,void 0,function*(){var t;const i=this.getWorkspacesListKey(),o=yield this.kvStorage.get(i);if(!(null===(t=null==o?void 0:o.kv)||void 0===t?void 0:t.value))return;let n=[];try{n="string"==typeof o.kv.value?JSON.parse(o.kv.value):o.kv.value}catch(e){return void console.warn("Failed to parse workspaces list for deletion",e)}n=n.filter(t=>t!==e),0===n.length?yield this.kvStorage.delete([i]):yield this.kvStorage.put([{key:i,value:JSON.stringify(n)}])})}};Ev=(0,C.Cg)([(0,C.Qj)(0,$v.P9),(0,C.Qj)(1,Sv.N)],Ev);const kv=a.DI.createInterface(e=>e.singleton(Ev));class Ov{constructor(){this.layouts=new Map}registerLayout(e,t){e&&this.layouts.set(e,t)}unregisterLayout(e){this.layouts.delete(e)}getLayoutsConfigs(){return Array.from(this.layouts).map(([e,t])=>({layoutKey:e,layout:t.getLayout()}))}applySavedLayouts(e){return(0,C.sH)(this,void 0,void 0,function*(){e.forEach(e=>{const t=this.layouts.get(e.layoutKey);t?t.loadLayout(e.layout,"placeholder",!0):console.warn(`layout for ${e.layoutKey} not found`)})})}}const Tv=a.DI.createInterface(e=>e.singleton(Ov));class Iv{constructor(){this.grids=new Map,this.cachedSettings=new Map}registerGrid(e,t,i){this.grids.set(e,{gridKey:e,gridApi:t,columnApi:i})}getGrid(e){return this.grids.get(e)||null}unregisterGrid(e){const t=this.grids.get(e);if(t){const i=this.getGridSettings(e,t);i&&this.cachedSettings.set(e,i)}this.grids.delete(e)}getAllGridsSettings(){return Array.from(this.grids).forEach(([e,t])=>{const i=this.getGridSettings(e,t);i&&this.cachedSettings.set(e,i)}),Array.from(this.cachedSettings.values()).filter(e=>!!e)}applyGridSettings(e,t){return(0,C.sH)(this,void 0,void 0,function*(){const i=this.grids.get(e.gridKey);if(!i||!i.columnApi||!i.gridApi)return!1;const o=e.columnState&&e.columnState.length>0,n=(!t||!1!==t.applyColumns)&&!!o;if(!n)return!1;try{return n&&i.columnApi.applyColumnState({state:e.columnState,applyOrder:!0}),!0}catch(t){return console.warn(`Failed to apply settings for grid ${e.gridKey}:`,t),!1}})}applyAllGridsSettings(e){return(0,C.sH)(this,arguments,void 0,function*(e,t=3,i=200){for(let i=0;i<t;i++){const o=[];for(const t of e){(yield this.applyGridSettings(t))||o.push(t)}if(0===o.length||i>=t-1)break;e=o}})}getGridSettings(e,t){var i;if(t){const o=null===(i=t.columnApi)||void 0===i?void 0:i.getColumnState(),n=(null==o?void 0:o.length)||0;return console.log(`Saved grid settings for ${e}: ${n} columns`),{gridKey:t.gridKey,columnState:o||[],savedAt:(new Date).toISOString()}}return console.warn(`No grid found for ${e}`),null}}const Rv=a.DI.createInterface(e=>e.singleton(Iv));class Av{constructor(){this.filters=new Map}registerFilter(e,t,i){this.filters.set(e,{filterKey:e,getFilterValue:t,setFilterValue:i})}unregisterFilter(e){this.filters.delete(e)}getAllFiltersValues(){return Array.from(this.filters).map(([e,t])=>{const i=t.getFilterValue();return null==i?{filterKey:e,value:""}:i}).filter(e=>null!==e)}applyFiltersValues(e){e.forEach(e=>{const t=this.filters.get(e.filterKey);t?t.setFilterValue(e.value):console.warn(`layout for ${e.filterKey} not found`)})}}const Dv=a.DI.createInterface(e=>e.singleton(Av)),Nv=l.html`
6216
+ <slot></slot>
6217
+ `;let Lv=class extends HTMLElement{constructor(){super(...arguments),this.gridElement=null,this.gridApi=null,this.columnApi=null,this.workspaceSettingsApplied=!1,this.handleGridReady=()=>{this.attachToGridApis()}}connectedCallback(){this.findAndRegisterGrid()}disconnectedCallback(){this.gridKey&&this.gridRegistry.unregisterGrid(this.gridKey),this.detachFromGridApis()}findAndRegisterGrid(){this.gridElement=this.querySelector("rapid-grid-pro"),this.gridElement?(this.gridElement.addEventListener("gridReady",this.handleGridReady),this.attachToGridApis()):setTimeout(()=>{this.gridElement=this.querySelector("rapid-grid-pro"),this.gridElement?(this.gridElement.addEventListener("gridReady",this.handleGridReady),this.attachToGridApis()):console.warn("grid-register: rapid-grid-pro element not found")},100)}attachToGridApis(){var e;if(!this.gridElement)return;const t=this.gridElement,i=t.gridApi||null,o=t.columnApi||null,n=(null===(e=null==t?void 0:t.getAttribute)||void 0===e?void 0:e.call(t,"persist-column-state-key"))||this.gridKey;if(!i||this.gridApi===i)return;this.gridApi=i,this.columnApi=o;const s=n;s?(this.gridRegistry.registerGrid(s,i,o),this.gridKey=s):console.warn("grid-register: missing persist-column-state-key; grid state will not be saved"),!this.workspaceSettingsApplied&&this.gridApi&&this.loadWorkspaceColumnState().catch(e=>{console.warn(`Failed to apply column state for ${this.gridKey} on gridReady:`,e)})}detachFromGridApis(){this.gridElement&&this.handleGridReady&&this.gridElement.removeEventListener("gridReady",this.handleGridReady),this.gridElement=null,this.gridApi=null,this.columnApi=null}loadWorkspaceSettings(e){return(0,C.sH)(this,void 0,void 0,function*(){if(this.gridKey&&this.columnApi&&this.gridApi)try{const t=this.workspaceState.getCurrentWorkspace();if(t&&t.grids){const i=t.grids.find(e=>e.gridKey===this.gridKey);if(i){const t=this.columnApi.getColumnState()||[],o=i.columnState||[],n=JSON.stringify(t)===JSON.stringify(o),s=!e||!1!==e.applyColumns;if(!s||n)return;(yield this.gridRegistry.applyGridSettings(i,e))||console.warn(`Failed to apply grid settings for ${this.gridKey}`)}}}catch(e){console.warn(`Failed to load workspace settings for grid ${this.gridKey}:`,e)}})}loadWorkspaceColumnState(){return(0,C.sH)(this,void 0,void 0,function*(){return this.loadWorkspaceSettings({applyColumns:!0})})}};(0,C.Cg)([(0,l.attr)({attribute:"grid-key"})],Lv.prototype,"gridKey",void 0),(0,C.Cg)([Rv],Lv.prototype,"gridRegistry",void 0),(0,C.Cg)([kv],Lv.prototype,"workspaceState",void 0),Lv=(0,C.Cg)([(0,l.customElement)({name:"grid-register",template:Nv})],Lv);const Fv=l.html`
6218
+ <slot></slot>
6219
+ `;let Mv=class extends HTMLElement{constructor(){super(...arguments),this.layoutElement=null}connectedCallback(){this.findAndRegisterLayout()}disconnectedCallback(){var e,t,i,o,n;const s=null!==(n=null!==(t=null===(e=this.layoutElement)||void 0===e?void 0:e.autoSaveKey)&&void 0!==t?t:null===(o=null===(i=this.layoutElement)||void 0===i?void 0:i.getAttribute)||void 0===o?void 0:o.call(i,"auto-save-key"))&&void 0!==n?n:this.layoutKey;s&&this.layoutRegistry.unregisterLayout(s)}findAndRegisterLayout(){let e=this.querySelector("rapid-layout");const t=e=>{var t,i,o;if(!e)return void console.warn("layout-register: rapid-layout element not found");this.layoutElement=e;const n=null!==(o=null!==(t=e.autoSaveKey)&&void 0!==t?t:null===(i=e.getAttribute)||void 0===i?void 0:i.call(e,"auto-save-key"))&&void 0!==o?o:this.layoutKey;n?this.layoutRegistry.registerLayout(n,e):console.warn("layout-register: missing layout key (auto-save-key/layout-key)")};e?t(e):setTimeout(()=>{e=this.querySelector("rapid-layout"),t(e)},100)}};(0,C.Cg)([(0,l.attr)({attribute:"layout-key"})],Mv.prototype,"layoutKey",void 0),(0,C.Cg)([Tv],Mv.prototype,"layoutRegistry",void 0),Mv=(0,C.Cg)([(0,l.customElement)({name:"layout-register",template:Fv})],Mv);var _v=i(96999);const Hv=l.css`
6216
6220
  .workspace-manager {
6217
6221
  display: flex;
6218
6222
  gap: 10px;
@@ -6348,7 +6352,7 @@ class="margin"
6348
6352
  .save-field {
6349
6353
  margin-bottom: 20px;
6350
6354
  }
6351
- `,Dg=l.html`
6355
+ `,Pv=l.html`
6352
6356
  <div class="workspace-manager">
6353
6357
  <rapid-button @click=${e=>e.openSaveDialog()}>
6354
6358
  <rapid-icon name="download"></rapid-icon>
@@ -6599,5 +6603,5 @@ class="margin"
6599
6603
  </div>
6600
6604
  <div class="workspace-dialog-boundary" ${(0,l.ref)("dialogBoundary")}></div>
6601
6605
  </rapid-modal>
6602
- `;let Rg=class extends s.FoundationElement{constructor(){super(...arguments),this.workspaceName="",this.workspaceDescription="",this.savedWorkspaces=[],this.sharedWorkspaces=[],this.isLoading=!1,this.applyingWorkspace=!1,this.loadMode="MY",this.saveMode="create",this.selectedWorkspaceToOverwrite="",this.workspaceToShare=""}sanitizeDescription(e){return(null!=e?e:"").replace(/[^a-zA-Z0-9\s]/g,"").replace(/\s+/g," ").trim().slice(0,200)}updateWorkspaceDescription(e){this.workspaceDescription=this.sanitizeDescription(e)}setDescriptionFromSelectedWorkspace(){var e,t;const i=null===(e=this.selectedWorkspaceToOverwrite)||void 0===e?void 0:e.trim();if(!i)return void(this.workspaceDescription="");const o=this.savedWorkspaces.find(e=>e.name===i);this.workspaceDescription=this.sanitizeDescription(null!==(t=null==o?void 0:o.description)&&void 0!==t?t:"")}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){e.connectedCallback.call(this),yield this.refreshSavedWorkspaces(),yield this.refreshSharedWorkspaces(),this.canShareWorkspace=this.auth.currentUser.hasPermission("SHARE_WORKSPACE")})}refreshSavedWorkspaces(){return(0,C.sH)(this,void 0,void 0,function*(){this.isLoading=!0;try{this.savedWorkspaces=yield this.workspaceState.getSavedWorkspaces()}catch(e){console.error("Failed to load saved workspaces",e),this.savedWorkspaces=[]}finally{this.isLoading=!1}})}refreshSharedWorkspaces(){return(0,C.sH)(this,void 0,void 0,function*(){try{const e=yield this.connect.request("REQ_SHARED_WORKSPACES"),t=(null==e?void 0:e.REPLY)||[];this.sharedWorkspaces=t.map(e=>{var t;return{id:e.SHARED_WORKSPACE_ID,name:e.WORKSPACE_NAME,userName:e.USER_NAME,description:null!==(t=e.DESCRIPTION)&&void 0!==t?t:void 0,createdOn:e.CREATED_ON,modifiedOn:e.MODIFIED_ON,data:e.WORKSPACE_DATA}})}catch(e){this.notifyError(`REQ_SHARED_WORKSPACES ${JSON.stringify(e)}`),console.error("Failed to load shared workspaces",e),this.sharedWorkspaces=[]}})}notifyError(e="Error"){Nd({title:"Error",body:e,iconName:"bell",toast:{type:"error",autoClose:!1}},"rapid")}saveWorkspace(){return(0,C.sH)(this,void 0,void 0,function*(){const e="overwrite"===this.saveMode?this.selectedWorkspaceToOverwrite.trim():this.workspaceName.trim();if(e)try{const t=this.layoutRegistry.getLayoutsConfigs(),i=this.gridRegistry.getAllGridsSettings(),o=this.filterRegistry.getAllFiltersValues();yield this.workspaceState.saveWorkspace(e,t,i,o,this.workspaceDescription.trim()||void 0),this.workspaceName="",this.workspaceDescription="",this.closeSaveDialog(),yield this.refreshSavedWorkspaces(),console.log("Workspace saved successfully")}catch(e){console.error("Failed to save workspace",e)}else console.error("workspace-manager: workspace name is required")})}applyWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){e.filters&&e.filters.length>0&&this.filterRegistry.applyFiltersValues(e.filters),e.layouts&&e.layouts.length>0&&(yield this.layoutRegistry.applySavedLayouts(e.layouts)),e.grids&&e.grids.length>0&&(yield this.gridRegistry.applyAllGridsSettings(e.grids))})}loadWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{this.applyingWorkspace=!0;const t=yield this.workspaceState.loadWorkspace(e);t?(yield this.applyWorkspace(t),this.closeLoadDialog(),console.log("Workspace loaded successfully")):console.warn("Workspace not found:",e)}catch(e){this.applyingWorkspace=!1,console.error("Failed to load workspace",e)}this.applyingWorkspace=!1})}requestSharedWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{return(yield this.connect.request("REQ_LOAD_SHARED_WORKSPACE",{REQUEST:{SHARED_WORKSPACE_ID:e}})).REPLY||[]}catch(e){console.error(e)}})}loadSharedWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{this.applyingWorkspace=!0;const t=yield this.requestSharedWorkspace(e.id);if(!(null==t?void 0:t.length))return void console.warn("workspace has no data");const i=t.map(e=>e.WORKSPACE_DATA).join(""),o=JSON.parse(i);yield this.applyWorkspace(o),this.closeLoadDialog(),console.log("Shared workspace loaded successfully")}catch(e){console.error("Failed to load shared workspace",e)}this.applyingWorkspace=!1})}deleteWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{yield this.workspaceState.deleteWorkspace(e),yield this.refreshSavedWorkspaces(),console.log("Workspace deleted successfully")}catch(e){console.error("Failed to delete workspace",e)}})}showDeleteConfirmation(e,t,i,o){(0,Tg.L)({title:e,body:t,dialog:{confirmingActions:[{label:"Delete",action:i}],dismissingAction:{label:"Cancel"}}},"rapid",o)}confirmDeleteWorkspace(e){const t=null==e?void 0:e.trim();t&&this.showDeleteConfirmation("Delete workspace",`Are you sure you want to delete the workspace "${t}"? This action cannot be undone.`,()=>this.deleteWorkspace(t),this.dialogBoundary)}modifySharedWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){var t,i;try{const o=this.layoutRegistry.getLayoutsConfigs(),n=this.gridRegistry.getAllGridsSettings(),a=this.filterRegistry.getAllFiltersValues(),s=yield this.workspaceState.loadWorkspace(e.name),r=this.sanitizeDescription(null!==(i=null!==(t=null==s?void 0:s.description)&&void 0!==t?t:e.description)&&void 0!==i?i:"")||void 0,l={name:e.name,username:e.userName,description:r,layouts:o,grids:n,filters:a,savedAt:(new Date).toISOString()};"EVENT_ACK"==(yield this.connect.commitEvent("EVENT_SHARED_WORKSPACE_MODIFY",{VALIDATE:!1,DETAILS:{WORKSPACE_NAME:e.name,WORKSPACE_DATA:JSON.stringify(l),WORKSPACE_DESCRIPTION:null!=r?r:null}})).MESSAGE_TYPE&&this.closeSaveDialog()}catch(e){this.notifyError(`EVENT_SHARED_WORKSPACE_MODIFY ${JSON.stringify(e)}`),console.error(e)}})}deleteSharedWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{"EVENT_ACK"==(yield this.connect.commitEvent("EVENT_SHARED_WORKSPACE_DELETE",{VALIDATE:!1,DETAILS:{WORKSPACE_NAME:e.name}})).MESSAGE_TYPE&&(this.closeSaveDialog(),yield this.refreshSharedWorkspaces())}catch(e){this.notifyError(`EVENT_SHARED_WORKSPACE_DELETE ${JSON.stringify(e)}`),console.error(e)}})}confirmDeleteSharedWorkspace(e){(null==e?void 0:e.name)&&this.showDeleteConfirmation("Delete shared workspace",`Are you sure you want to delete the shared workspace "${e.name}"? This action cannot be undone.`,()=>this.deleteSharedWorkspace(e),this.sharedWorkspaceDialogBoundary)}shareExistingWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){var t;const i=null==e?void 0:e.trim();if(i)try{const e=yield this.workspaceState.loadWorkspace(i);if(!e)return void console.warn("Workspace not found for sharing:",i);const o=yield this.connect.commitEvent("EVENT_SHARED_WORKSPACE_INSERT",{VALIDATE:!1,DETAILS:{WORKSPACE_NAME:e.name,WORKSPACE_DATA:JSON.stringify(e),WORKSPACE_DESCRIPTION:null!==(t=e.description)&&void 0!==t?t:null}});"EVENT_ACK"==o.MESSAGE_TYPE?(console.log("Workspace shared successfully"),this.closeSaveDialog(),yield this.refreshSharedWorkspaces()):"EVENT_NACK"==o.MESSAGE_TYPE&&(console.warn("Failed to share workspace",o),this.closeSaveDialog())}catch(e){console.error("Failed to share workspace",e)}})}openSaveDialog(){return(0,C.sH)(this,void 0,void 0,function*(){yield this.refreshSavedWorkspaces(),this.saveModal.show(),this.workspaceName="",this.workspaceDescription="",this.saveMode="create",this.selectedWorkspaceToOverwrite="",this.workspaceToShare=""})}isWorkspaceExisting(e){return this.savedWorkspaces.some(t=>t.name.toLowerCase()===e.toLowerCase())}saveModeChanged(e,t){"create"===t?(this.selectedWorkspaceToOverwrite="",this.workspaceDescription=""):"overwrite"===t?(this.workspaceName="",this.setDescriptionFromSelectedWorkspace()):"shared"===t&&(this.workspaceName="",this.selectedWorkspaceToOverwrite="",this.workspaceDescription="")}selectedWorkspaceToOverwriteChanged(e,t){"overwrite"===this.saveMode&&this.setDescriptionFromSelectedWorkspace()}openLoadDialog(){this.refreshSharedWorkspaces(),this.loadModal.show()}closeSaveDialog(){this.saveModal.close(),this.workspaceName="",this.workspaceDescription=""}closeLoadDialog(){this.loadModal.close()}};(0,C.Cg)([l.observable],Rg.prototype,"workspaceName",void 0),(0,C.Cg)([l.observable],Rg.prototype,"workspaceDescription",void 0),(0,C.Cg)([l.observable],Rg.prototype,"savedWorkspaces",void 0),(0,C.Cg)([l.observable],Rg.prototype,"sharedWorkspaces",void 0),(0,C.Cg)([l.observable],Rg.prototype,"isLoading",void 0),(0,C.Cg)([l.observable],Rg.prototype,"applyingWorkspace",void 0),(0,C.Cg)([l.observable],Rg.prototype,"loadMode",void 0),(0,C.Cg)([l.observable],Rg.prototype,"saveModal",void 0),(0,C.Cg)([l.observable],Rg.prototype,"loadModal",void 0),(0,C.Cg)([l.observable],Rg.prototype,"saveMode",void 0),(0,C.Cg)([l.observable],Rg.prototype,"selectedWorkspaceToOverwrite",void 0),(0,C.Cg)([l.observable],Rg.prototype,"workspaceToShare",void 0),(0,C.Cg)([l.observable],Rg.prototype,"dialogBoundary",void 0),(0,C.Cg)([l.observable],Rg.prototype,"sharedWorkspaceDialogBoundary",void 0),(0,C.Cg)([$g],Rg.prototype,"layoutRegistry",void 0),(0,C.Cg)([Sg],Rg.prototype,"gridRegistry",void 0),(0,C.Cg)([Eg],Rg.prototype,"filterRegistry",void 0),(0,C.Cg)([kg],Rg.prototype,"workspaceState",void 0),(0,C.Cg)([ii.dm],Rg.prototype,"connect",void 0),(0,C.Cg)([Og.N],Rg.prototype,"auth",void 0),(0,C.Cg)([l.observable],Rg.prototype,"canShareWorkspace",void 0),Rg=(0,C.Cg)([(0,l.customElement)({name:"workspace-manager",template:Dg,styles:Ig})],Rg);const Ag=()=>Yl().register(Gp)},70997(e,t,i){function o(e,t,i){const o=e=>"function"==typeof e?e:()=>e,n=o(t),a=o(i);return(t,i)=>e(t,i)?n(t,i):a(t,i)}i.d(t,{q:()=>o})},80273(e,t,i){i.d(t,{Du:()=>l,IT:()=>s,WP:()=>n,f4:()=>r,zz:()=>a});var o=i(52945);const n=(e,t)=>{(0,o.O5)(e,t)};var a,s;!function(e){e.Italic="italic",e.Normal="normal"}(a||(a={})),function(e){e[e.Thin=100]="Thin",e[e.Light=300]="Light",e[e.Regular=400]="Regular",e[e.Medium=500]="Medium",e[e.Bold=700]="Bold",e[e.Black=900]="Black"}(s||(s={}));const r=(e,t=a.Normal,i=s.Regular)=>`\n font-family: ${e};\n font-style: ${t};\n font-weight: ${i};\n`,l={minusOne:-1,minusTwo:-2,plusOne:1,plusTwo:2,plusThree:3,plusFour:4,plusFive:5,plusSix:6}}}]);
6603
- //# sourceMappingURL=6.3285440de602fd13ef3276807b36170f.js.map
6606
+ `;let zv=class extends a.FoundationElement{constructor(){super(...arguments),this.workspaceName="",this.workspaceDescription="",this.savedWorkspaces=[],this.sharedWorkspaces=[],this.isLoading=!1,this.applyingWorkspace=!1,this.loadMode="MY",this.saveMode="create",this.selectedWorkspaceToOverwrite="",this.workspaceToShare=""}sanitizeDescription(e){return(null!=e?e:"").replace(/[^a-zA-Z0-9\s]/g,"").replace(/\s+/g," ").trim().slice(0,200)}updateWorkspaceDescription(e){this.workspaceDescription=this.sanitizeDescription(e)}setDescriptionFromSelectedWorkspace(){var e,t;const i=null===(e=this.selectedWorkspaceToOverwrite)||void 0===e?void 0:e.trim();if(!i)return void(this.workspaceDescription="");const o=this.savedWorkspaces.find(e=>e.name===i);this.workspaceDescription=this.sanitizeDescription(null!==(t=null==o?void 0:o.description)&&void 0!==t?t:"")}connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,C.sH)(this,void 0,void 0,function*(){e.connectedCallback.call(this),yield this.refreshSavedWorkspaces(),yield this.refreshSharedWorkspaces(),this.canShareWorkspace=this.auth.currentUser.hasPermission("SHARE_WORKSPACE")})}refreshSavedWorkspaces(){return(0,C.sH)(this,void 0,void 0,function*(){this.isLoading=!0;try{this.savedWorkspaces=yield this.workspaceState.getSavedWorkspaces()}catch(e){console.error("Failed to load saved workspaces",e),this.savedWorkspaces=[]}finally{this.isLoading=!1}})}refreshSharedWorkspaces(){return(0,C.sH)(this,void 0,void 0,function*(){try{const e=yield this.connect.request("REQ_SHARED_WORKSPACES"),t=(null==e?void 0:e.REPLY)||[];this.sharedWorkspaces=t.map(e=>{var t;return{id:e.SHARED_WORKSPACE_ID,name:e.WORKSPACE_NAME,userName:e.USER_NAME,description:null!==(t=e.DESCRIPTION)&&void 0!==t?t:void 0,createdOn:e.CREATED_ON,modifiedOn:e.MODIFIED_ON,data:e.WORKSPACE_DATA}})}catch(e){this.notifyError(`REQ_SHARED_WORKSPACES ${JSON.stringify(e)}`),console.error("Failed to load shared workspaces",e),this.sharedWorkspaces=[]}})}notifyError(e="Error"){Nd({title:"Error",body:e,iconName:"bell",toast:{type:"error",autoClose:!1}},"rapid")}saveWorkspace(){return(0,C.sH)(this,void 0,void 0,function*(){const e="overwrite"===this.saveMode?this.selectedWorkspaceToOverwrite.trim():this.workspaceName.trim();if(e)try{const t=this.layoutRegistry.getLayoutsConfigs(),i=this.gridRegistry.getAllGridsSettings(),o=this.filterRegistry.getAllFiltersValues();yield this.workspaceState.saveWorkspace(e,t,i,o,this.workspaceDescription.trim()||void 0),this.workspaceName="",this.workspaceDescription="",this.closeSaveDialog(),yield this.refreshSavedWorkspaces(),console.log("Workspace saved successfully")}catch(e){console.error("Failed to save workspace",e)}else console.error("workspace-manager: workspace name is required")})}applyWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){e.filters&&e.filters.length>0&&this.filterRegistry.applyFiltersValues(e.filters),e.layouts&&e.layouts.length>0&&(yield this.layoutRegistry.applySavedLayouts(e.layouts)),e.grids&&e.grids.length>0&&(yield this.gridRegistry.applyAllGridsSettings(e.grids))})}loadWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{this.applyingWorkspace=!0;const t=yield this.workspaceState.loadWorkspace(e);t?(yield this.applyWorkspace(t),this.closeLoadDialog(),console.log("Workspace loaded successfully")):console.warn("Workspace not found:",e)}catch(e){this.applyingWorkspace=!1,console.error("Failed to load workspace",e)}this.applyingWorkspace=!1})}requestSharedWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{return(yield this.connect.request("REQ_LOAD_SHARED_WORKSPACE",{REQUEST:{SHARED_WORKSPACE_ID:e}})).REPLY||[]}catch(e){console.error(e)}})}loadSharedWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{this.applyingWorkspace=!0;const t=yield this.requestSharedWorkspace(e.id);if(!(null==t?void 0:t.length))return void console.warn("workspace has no data");const i=t.map(e=>e.WORKSPACE_DATA).join(""),o=JSON.parse(i);yield this.applyWorkspace(o),this.closeLoadDialog(),console.log("Shared workspace loaded successfully")}catch(e){console.error("Failed to load shared workspace",e)}this.applyingWorkspace=!1})}deleteWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{yield this.workspaceState.deleteWorkspace(e),yield this.refreshSavedWorkspaces(),console.log("Workspace deleted successfully")}catch(e){console.error("Failed to delete workspace",e)}})}showDeleteConfirmation(e,t,i,o){(0,_v.L)({title:e,body:t,dialog:{confirmingActions:[{label:"Delete",action:i}],dismissingAction:{label:"Cancel"}}},"rapid",o)}confirmDeleteWorkspace(e){const t=null==e?void 0:e.trim();t&&this.showDeleteConfirmation("Delete workspace",`Are you sure you want to delete the workspace "${t}"? This action cannot be undone.`,()=>this.deleteWorkspace(t),this.dialogBoundary)}modifySharedWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){var t,i;try{const o=this.layoutRegistry.getLayoutsConfigs(),n=this.gridRegistry.getAllGridsSettings(),s=this.filterRegistry.getAllFiltersValues(),a=yield this.workspaceState.loadWorkspace(e.name),r=this.sanitizeDescription(null!==(i=null!==(t=null==a?void 0:a.description)&&void 0!==t?t:e.description)&&void 0!==i?i:"")||void 0,l={name:e.name,username:e.userName,description:r,layouts:o,grids:n,filters:s,savedAt:(new Date).toISOString()};"EVENT_ACK"==(yield this.connect.commitEvent("EVENT_SHARED_WORKSPACE_MODIFY",{VALIDATE:!1,DETAILS:{WORKSPACE_NAME:e.name,WORKSPACE_DATA:JSON.stringify(l),WORKSPACE_DESCRIPTION:null!=r?r:null}})).MESSAGE_TYPE&&this.closeSaveDialog()}catch(e){this.notifyError(`EVENT_SHARED_WORKSPACE_MODIFY ${JSON.stringify(e)}`),console.error(e)}})}deleteSharedWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){try{"EVENT_ACK"==(yield this.connect.commitEvent("EVENT_SHARED_WORKSPACE_DELETE",{VALIDATE:!1,DETAILS:{WORKSPACE_NAME:e.name}})).MESSAGE_TYPE&&(this.closeSaveDialog(),yield this.refreshSharedWorkspaces())}catch(e){this.notifyError(`EVENT_SHARED_WORKSPACE_DELETE ${JSON.stringify(e)}`),console.error(e)}})}confirmDeleteSharedWorkspace(e){(null==e?void 0:e.name)&&this.showDeleteConfirmation("Delete shared workspace",`Are you sure you want to delete the shared workspace "${e.name}"? This action cannot be undone.`,()=>this.deleteSharedWorkspace(e),this.sharedWorkspaceDialogBoundary)}shareExistingWorkspace(e){return(0,C.sH)(this,void 0,void 0,function*(){var t;const i=null==e?void 0:e.trim();if(i)try{const e=yield this.workspaceState.loadWorkspace(i);if(!e)return void console.warn("Workspace not found for sharing:",i);const o=yield this.connect.commitEvent("EVENT_SHARED_WORKSPACE_INSERT",{VALIDATE:!1,DETAILS:{WORKSPACE_NAME:e.name,WORKSPACE_DATA:JSON.stringify(e),WORKSPACE_DESCRIPTION:null!==(t=e.description)&&void 0!==t?t:null}});"EVENT_ACK"==o.MESSAGE_TYPE?(console.log("Workspace shared successfully"),this.closeSaveDialog(),yield this.refreshSharedWorkspaces()):"EVENT_NACK"==o.MESSAGE_TYPE&&(console.warn("Failed to share workspace",o),this.closeSaveDialog())}catch(e){console.error("Failed to share workspace",e)}})}openSaveDialog(){return(0,C.sH)(this,void 0,void 0,function*(){yield this.refreshSavedWorkspaces(),this.saveModal.show(),this.workspaceName="",this.workspaceDescription="",this.saveMode="create",this.selectedWorkspaceToOverwrite="",this.workspaceToShare=""})}isWorkspaceExisting(e){return this.savedWorkspaces.some(t=>t.name.toLowerCase()===e.toLowerCase())}saveModeChanged(e,t){"create"===t?(this.selectedWorkspaceToOverwrite="",this.workspaceDescription=""):"overwrite"===t?(this.workspaceName="",this.setDescriptionFromSelectedWorkspace()):"shared"===t&&(this.workspaceName="",this.selectedWorkspaceToOverwrite="",this.workspaceDescription="")}selectedWorkspaceToOverwriteChanged(e,t){"overwrite"===this.saveMode&&this.setDescriptionFromSelectedWorkspace()}openLoadDialog(){this.refreshSharedWorkspaces(),this.loadModal.show()}closeSaveDialog(){this.saveModal.close(),this.workspaceName="",this.workspaceDescription=""}closeLoadDialog(){this.loadModal.close()}};(0,C.Cg)([l.observable],zv.prototype,"workspaceName",void 0),(0,C.Cg)([l.observable],zv.prototype,"workspaceDescription",void 0),(0,C.Cg)([l.observable],zv.prototype,"savedWorkspaces",void 0),(0,C.Cg)([l.observable],zv.prototype,"sharedWorkspaces",void 0),(0,C.Cg)([l.observable],zv.prototype,"isLoading",void 0),(0,C.Cg)([l.observable],zv.prototype,"applyingWorkspace",void 0),(0,C.Cg)([l.observable],zv.prototype,"loadMode",void 0),(0,C.Cg)([l.observable],zv.prototype,"saveModal",void 0),(0,C.Cg)([l.observable],zv.prototype,"loadModal",void 0),(0,C.Cg)([l.observable],zv.prototype,"saveMode",void 0),(0,C.Cg)([l.observable],zv.prototype,"selectedWorkspaceToOverwrite",void 0),(0,C.Cg)([l.observable],zv.prototype,"workspaceToShare",void 0),(0,C.Cg)([l.observable],zv.prototype,"dialogBoundary",void 0),(0,C.Cg)([l.observable],zv.prototype,"sharedWorkspaceDialogBoundary",void 0),(0,C.Cg)([Tv],zv.prototype,"layoutRegistry",void 0),(0,C.Cg)([Rv],zv.prototype,"gridRegistry",void 0),(0,C.Cg)([Dv],zv.prototype,"filterRegistry",void 0),(0,C.Cg)([kv],zv.prototype,"workspaceState",void 0),(0,C.Cg)([ii.dm],zv.prototype,"connect",void 0),(0,C.Cg)([Sv.N],zv.prototype,"auth",void 0),(0,C.Cg)([l.observable],zv.prototype,"canShareWorkspace",void 0),zv=(0,C.Cg)([(0,l.customElement)({name:"workspace-manager",template:Pv,styles:Hv})],zv);const Uv=()=>Yl().register(Bp)},70997(e,t,i){function o(e,t,i){const o=e=>"function"==typeof e?e:()=>e,n=o(t),s=o(i);return(t,i)=>e(t,i)?n(t,i):s(t,i)}i.d(t,{q:()=>o})},80273(e,t,i){i.d(t,{Du:()=>l,IT:()=>a,WP:()=>n,f4:()=>r,zz:()=>s});var o=i(52945);const n=(e,t)=>{(0,o.O5)(e,t)};var s,a;!function(e){e.Italic="italic",e.Normal="normal"}(s||(s={})),function(e){e[e.Thin=100]="Thin",e[e.Light=300]="Light",e[e.Regular=400]="Regular",e[e.Medium=500]="Medium",e[e.Bold=700]="Bold",e[e.Black=900]="Black"}(a||(a={}));const r=(e,t=s.Normal,i=a.Regular)=>`\n font-family: ${e};\n font-style: ${t};\n font-weight: ${i};\n`,l={minusOne:-1,minusTwo:-2,plusOne:1,plusTwo:2,plusThree:3,plusFour:4,plusFive:5,plusSix:6}}}]);
6607
+ //# sourceMappingURL=105.735470a6c5391ef87f2da01a7cc5fe98.js.map