@ixon-cdk/simulator 1.22.0 → 1.22.1

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,4 +1,4 @@
1
- import{require_jszip_min}from"./chunk-HG4GZ56Y.js";import{quill_default}from"./chunk-WMR5ZEMM.js";import{A11yModule,ACTIVE_RUNTIME_CHECKS,ANIMATION_MODULE_TYPE,APP_CONFIG,APP_INITIALIZER,AUTO_STYLE,Actions,ActionsSubject,ActivatedRoute,AnimationGroupPlayer,AnimationMetadataType,AnonymousSubject,ApplicationRef,AsyncPipe,BackendComponentCallerService,BackendComponentCallerServiceFactory,BackendComponentClient,BackendComponentClientProxyService,BehaviorSubject,BreakpointObserver,Breakpoints,BrowserModule,CdkDrag,CdkDragPlaceholder,CdkDragPreview,CdkDropList,CdkFixedSizeVirtualScroll,CdkMonitorFocus,CdkPortalOutlet,CdkTextareaAutosize,CdkTrapFocus,CdkVirtualForOf,CdkVirtualScrollViewport,ChangeDetectorRef,CommonModule,ComponentFactoryResolver$1,ComponentPortal,ComponentTemplateValidatorService,DEFAULT_CARD_DIMENSIONS,DEFAULT_CBC_INGRESS_URL,DEFAULT_REPORT_DIMENSIONS,DEFAULT_SHEET_DIMENSIONS,DOCUMENT,DataSource,DateAdapter,DefaultFlexDirective,DefaultLayoutAlignDirective,DefaultLayoutDirective,DefaultLayoutGapDirective,DefaultValueAccessor,DestroyRef,Directionality,DomRendererFactory2,DomSanitizer,DragDropModule,EMPTY,EffectsModule,ElementRef,ErrorHandler,EventEmitter,FlexLayoutModule,FlexModule,FormArray,FormBuilder,FormControl,FormControlDirective,FormControlName,FormGroup,FormGroupDirective,FormGroupName,FormsModule,HTTP_INTERCEPTORS,HostAttributeToken,HttpClient,HttpContext,HttpErrorResponse,HttpHeaders,HttpParams,HttpResponse,INIT,INITIAL_STATE,IXAPI_OPTIONS,InjectionToken,Injector,IterableDiffers,IxApi2RequestErrorMessages,IxApiErrorMessages,IxApiErrors,IxApiHeaderKeys,IxApiModule,IxApiRequestErrorMessages,IxApiRequestErrors,IxApiService,LayoutModule,Location,LowerCasePipe,MAT_BOTTOM_SHEET_DATA,MAT_DATE_FORMATS,MAT_DATE_LOCALE,MAT_DIALOG_DATA,MAT_INPUT_VALUE_ACCESSOR,MatActionList,MatBottomSheet,MatBottomSheetRef,MatButton,MatButtonModule,MatCard,MatCardActions,MatCardHeader,MatCardModule,MatCardSubtitle,MatCardTitle,MatCheckbox,MatCheckboxModule,MatCommonModule,MatDatepicker,MatDatepickerInput,MatDatepickerToggle,MatDialog,MatDialogActions,MatDialogClose,MatDialogContainer,MatDialogContent,MatDialogModule,MatDialogRef,MatDialogTitle,MatDivider,MatDividerModule,MatDrawer,MatDrawerContainer,MatDrawerContent,MatError,MatExpansionPanel,MatFormField,MatFormFieldModule,MatHint,MatIcon,MatIconButton,MatIconModule,MatIconRegistry,MatInput,MatInputModule,MatLabel,MatList,MatListItem,MatListItemIcon,MatListItemLine,MatListItemMeta,MatListItemTitle,MatListModule,MatListOption,MatListSubheaderCssMatStyler,MatMenu,MatMenuItem,MatMenuModule,MatMenuTrigger,MatOptgroup,MatOption,MatOptionModule,MatPaginatorModule,MatPrefix,MatProgressSpinner,MatSelect,MatSelectModule,MatSelectTrigger,MatSelectionList,MatSidenavModule,MatSnackBar,MatSnackBarModule,MatSuffix,MatTab,MatTabGroup,MatTabsModule,MatToolbar,MatToolbarModule,MatTooltip,MatTooltipModule,MediaObserver,Meta,MinValidator,MtxPopoverModule,NG_VALIDATORS,NG_VALUE_ACCESSOR,NavigationCancel,NavigationEnd,NavigationError,NavigationStart,NgControl,NgControlStatus,NgControlStatusGroup,NgForOf,NgForm,NgIf,NgModel,NgSelectOption,NgStyle,NgTemplateOutlet,NgZone,NoopAnimationPlayer,NumberValueAccessor,ONE_WEEK,OTP_SMS_REQUIRED_PATTERN,Observable,Overlay,OverlayConfig,OverlayModule,PAGE_COMPONENT,PLATFORM_ID,PageComponentTemplateManifestModule,PageComponentTemplateModule,PageComponentTemplateService,Platform,PortalModule,REQUIRES_BRANDING,REQUIRES_COMPANY,ReactiveFormsModule,ReducerManagerDispatcher,ReducerObservable,Renderer2,RendererFactory2,ReplaySubject,RequiredValidator,ResourceDataClient,ResourceDataClientProxyService,ResourceDataServiceFactory,Router,RouterLink,RouterModule,RouterOutlet,RoutesRecognized,RuntimeError,SESSION_STORAGE,STORAGE_KEY_CBC_CONFIG_VALUES,STORAGE_KEY_CBC_INGRESS,STORAGE_KEY_CBC_INGRESS_URL,STORAGE_KEY_CBC_PUBLIC_ID,ScannedActionsSubject,ScrollingModule,SecurityContext,SelectControlValueAccessor,SelectionModel,SettingsModule,SharedModule,StateObservable,StorageEventContext,StorageModule,StorageService,Store,StoreModule,Subject,Subscriber,Subscription,TREE_KEY_MANAGER,TemplateRef,Title,TitleCasePipe,TranslateDirective,TranslateLoader,TranslateModule,TranslatePipe,TranslateService,UPDATE,USER_PROVIDED_EFFECTS,Validators,ViewContainerRef,ViewportRuler,WA_WINDOW,WINDOW,_getFocusedElementPierceShadowDom,add,addFailure,addSuccess,afterNextRender,appConfigFactory,booleanAttribute,buffer,buildFields,catchError,coerceBooleanProperty,coerceNumberProperty,coerceObservable,coerceStringArray,combineLatest,compactFields,computed,concat,concatMap,createAction,createEffect,createEntityAdapter,createFeature,createFeatureSelector,createReducer,createResourceAdapter,createResourceSelectorFactory,createSelector,debounceTime,decryptValue,defaultOptions,defer,delay,delayWhen,didAdd,didAddList,didRemove,didRemoveList,didUpdate,didUpdateList,distinctUntilChanged,effect,ensureAll,ensureMany,ensureOne,environment,filter,findAppId,first,firstValueFrom,forkJoin,forwardRef,from,fromEvent,getLinkMap,getLinkUrl,getMissingFields,getPageParams,hasFields,hasModifierKey,hasNonPublicIdFields,haveFields,inject,input,isDataSource,isDevMode,isNgrxMockEnvironment,isObservable,isPlatformBrowser,isPlatformServer,last,lastValueFrom,linkedSignal,loadAllForIntentSuccess,loadAllSuccess,loadAppConfig,loadHost,loadHostFailure,loadHostSuccess,loadManySuccess,makeEnvironmentProviders,map,mapPageComponentTemplateManifestToDefaultInputs,mapPageComponentTemplateToCustomElementName,mapPageComponentTemplateToTemplateBaseUrl,mapPageComponentTemplateToTemplateUrl,mapResourceToSubResourceList,mapTemplateUrlToMainPath,mapTemplateUrlToManifestUrl,mapTemplateUrlToPublicId,merge,mergeFields,mergeLoadedFields,mergeMap,moveItemInArray,mustache_default,naturalSort,normalizePassiveListenerOptions,numberAttribute,observeOn,of,ofStatus,ofType,omitLoadedFields,omitSubresources,on,output,pairwise,parseBody,platformBrowser,props,provideEnvironmentInitializer,provideHttpClient,queueScheduler,reduce,remove,removeFailure,removeSuccess,require_crypto_js,reset,reset2,reset3,resetPendingUpdates,resource,retryBackoff,scan,select,selectAll,selectEntities,selectEntities2,selectEntity,selectEntity2,sequence,share,shareReplay,signal,skip,sortByNameAndPublicIdComparer,startWith,style,switchMap,take,takeUntil,takeUntilDestroyed,tap,throwError,throwNotFoundError,timeout,timer,toObservable,toSignal,update,updateFailure,updateMany,updateManyFailure,updateManySuccess,updateResource,updateSuccess,validateOptions,viewChild,whileMoreAfter,withInterceptorsFromDi,withLatestFrom,ɵNgNoValidate,ɵNgSelectMultipleOption,ɵPRE_STYLE,ɵɵInheritDefinitionFeature,ɵɵNgOnChangesFeature,ɵɵProvidersFeature,ɵɵadvance,ɵɵattribute,ɵɵclassMap,ɵɵclassProp,ɵɵconditional,ɵɵconditionalCreate,ɵɵcontentQuery,ɵɵdeclareLet,ɵɵdefineComponent,ɵɵdefineDirective,ɵɵdefineInjectable,ɵɵdefineInjector,ɵɵdefineNgModule,ɵɵdefinePipe,ɵɵdirectiveInject,ɵɵdomElement,ɵɵdomElementEnd,ɵɵdomElementStart,ɵɵdomListener,ɵɵdomProperty,ɵɵelement,ɵɵelementContainer,ɵɵelementContainerEnd,ɵɵelementContainerStart,ɵɵelementEnd,ɵɵelementStart,ɵɵgetCurrentView,ɵɵgetInheritedFactory,ɵɵinject,ɵɵinterpolate,ɵɵinterpolate1,ɵɵlistener,ɵɵloadQuery,ɵɵnamespaceHTML,ɵɵnamespaceSVG,ɵɵnextContext,ɵɵpipe,ɵɵpipeBind1,ɵɵpipeBind2,ɵɵpipeBind3,ɵɵprojection,ɵɵprojectionDef,ɵɵproperty,ɵɵpureFunction0,ɵɵpureFunction1,ɵɵqueryAdvance,ɵɵqueryRefresh,ɵɵreadContextLet,ɵɵreference,ɵɵrepeater,ɵɵrepeaterCreate,ɵɵrepeaterTrackByIdentity,ɵɵrepeaterTrackByIndex,ɵɵresetView,ɵɵresolveDocument,ɵɵrestoreView,ɵɵsanitizeHtml,ɵɵsanitizeUrl,ɵɵstoreLet,ɵɵstyleMap,ɵɵstyleProp,ɵɵtemplate,ɵɵtemplateRefExtractor,ɵɵtext,ɵɵtextInterpolate,ɵɵtextInterpolate1,ɵɵtextInterpolate2,ɵɵtextInterpolate3,ɵɵtwoWayBindingSet,ɵɵtwoWayListener,ɵɵtwoWayProperty,ɵɵviewQuery,ɵɵviewQuerySignal}from"./chunk-JZ264QUI.js";import{camelCase_default,capitalize_default,cloneDeep_default,compact_default,deburr_default,escape_default,flatMap_default,flatten_default,get_default,groupBy_default,has_default,isArray_default,isEmpty_default,isEqual_default,isNil_default,isObject_default,isString_default,isUndefined_default,kebabCase_default,memoize_default,merge_default,omitBy_default,omit_default,orderBy_default,pick_default,range_default,set_default,snakeCase_default,sortBy_default,startCase_default,template_default,uniqBy_default,uniq_default,upperFirst_default}from"./chunk-W3TLLCWQ.js";import{__async,__commonJS,__esm,__export,__objRest,__require,__spreadProps,__spreadValues,__superGet,__toCommonJS,__toESM,__yieldStar}from"./chunk-EFEL2YQJ.js";var require_FileSaver_min=__commonJS({"node_modules/file-saver/dist/FileSaver.min.js"(exports,module){(function(a,b){typeof define=="function"&&define.amd?define([],b):typeof exports<"u"?b():(b(),a.FileSaver={})})(exports,function(){"use strict";function b(a2,b2){return typeof b2>"u"?b2={autoBom:!1}:typeof b2!="object"&&(console.warn("Deprecated: Expected third argument to be a object"),b2={autoBom:!b2}),b2.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(a2.type)?new Blob(["\uFEFF",a2],{type:a2.type}):a2}function c(a2,b2,c2){var d2=new XMLHttpRequest;d2.open("GET",a2),d2.responseType="blob",d2.onload=function(){g(d2.response,b2,c2)},d2.onerror=function(){console.error("could not download file")},d2.send()}function d(a2){var b2=new XMLHttpRequest;b2.open("HEAD",a2,!1);try{b2.send()}catch{}return 200<=b2.status&&299>=b2.status}function e(a2){try{a2.dispatchEvent(new MouseEvent("click"))}catch{var b2=document.createEvent("MouseEvents");b2.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),a2.dispatchEvent(b2)}}var f=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof global=="object"&&global.global===global?global:void 0,a=f.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),g=f.saveAs||(typeof window!="object"||window!==f?function(){}:"download"in HTMLAnchorElement.prototype&&!a?function(b2,g2,h){var i=f.URL||f.webkitURL,j=document.createElement("a");g2=g2||b2.name||"download",j.download=g2,j.rel="noopener",typeof b2=="string"?(j.href=b2,j.origin===location.origin?e(j):d(j.href)?c(b2,g2,h):e(j,j.target="_blank")):(j.href=i.createObjectURL(b2),setTimeout(function(){i.revokeObjectURL(j.href)},4e4),setTimeout(function(){e(j)},0))}:"msSaveOrOpenBlob"in navigator?function(f2,g2,h){if(g2=g2||f2.name||"download",typeof f2!="string")navigator.msSaveOrOpenBlob(b(f2,h),g2);else if(d(f2))c(f2,g2,h);else{var i=document.createElement("a");i.href=f2,i.target="_blank",setTimeout(function(){e(i)})}}:function(b2,d2,e2,g2){if(g2=g2||open("","_blank"),g2&&(g2.document.title=g2.document.body.innerText="downloading..."),typeof b2=="string")return c(b2,d2,e2);var h=b2.type==="application/octet-stream",i=/constructor/i.test(f.HTMLElement)||f.safari,j=/CriOS\/[\d]+/.test(navigator.userAgent);if((j||h&&i||a)&&typeof FileReader<"u"){var k=new FileReader;k.onloadend=function(){var a2=k.result;a2=j?a2:a2.replace(/^data:[^;]*;/,"data:attachment/file;"),g2?g2.location.href=a2:location=a2,g2=null},k.readAsDataURL(b2)}else{var l2=f.URL||f.webkitURL,m=l2.createObjectURL(b2);g2?g2.location=m:location.href=m,g2=null,setTimeout(function(){l2.revokeObjectURL(m)},4e4)}});f.saveAs=g.saveAs=g,typeof module<"u"&&(module.exports=g)})}});var require_ua_parser=__commonJS({"node_modules/ua-parser-js/src/ua-parser.js"(exports,module){(function(window2,undefined2){"use strict";var LIBVERSION="1.0.37",EMPTY2="",UNKNOWN="?",FUNC_TYPE="function",UNDEF_TYPE="undefined",OBJ_TYPE="object",STR_TYPE="string",MAJOR="major",MODEL="model",NAME="name",TYPE="type",VENDOR="vendor",VERSION2="version",ARCHITECTURE="architecture",CONSOLE="console",MOBILE="mobile",TABLET="tablet",SMARTTV="smarttv",WEARABLE="wearable",EMBEDDED="embedded",UA_MAX_LENGTH=500,AMAZON="Amazon",APPLE="Apple",ASUS="ASUS",BLACKBERRY="BlackBerry",BROWSER="Browser",CHROME="Chrome",EDGE="Edge",FIREFOX="Firefox",GOOGLE="Google",HUAWEI="Huawei",LG="LG",MICROSOFT="Microsoft",MOTOROLA="Motorola",OPERA="Opera",SAMSUNG="Samsung",SHARP="Sharp",SONY="Sony",XIAOMI="Xiaomi",ZEBRA="Zebra",FACEBOOK="Facebook",CHROMIUM_OS="Chromium OS",MAC_OS="Mac OS",extend3=function(regexes2,extensions){var mergedRegexes={};for(var i in regexes2)extensions[i]&&extensions[i].length%2===0?mergedRegexes[i]=extensions[i].concat(regexes2[i]):mergedRegexes[i]=regexes2[i];return mergedRegexes},enumerize=function(arr){for(var enums={},i=0;i<arr.length;i++)enums[arr[i].toUpperCase()]=arr[i];return enums},has=function(str1,str2){return typeof str1===STR_TYPE?lowerize(str2).indexOf(lowerize(str1))!==-1:!1},lowerize=function(str){return str.toLowerCase()},majorize=function(version2){return typeof version2===STR_TYPE?version2.replace(/[^\d\.]/g,EMPTY2).split(".")[0]:undefined2},trim=function(str,len){if(typeof str===STR_TYPE)return str=str.replace(/^\s\s*/,EMPTY2),typeof len===UNDEF_TYPE?str:str.substring(0,UA_MAX_LENGTH)},rgxMapper=function(ua,arrays){for(var i=0,j,k,p,q,matches,match2;i<arrays.length&&!matches;){var regex=arrays[i],props2=arrays[i+1];for(j=k=0;j<regex.length&&!matches&&regex[j];)if(matches=regex[j++].exec(ua),matches)for(p=0;p<props2.length;p++)match2=matches[++k],q=props2[p],typeof q===OBJ_TYPE&&q.length>0?q.length===2?typeof q[1]==FUNC_TYPE?this[q[0]]=q[1].call(this,match2):this[q[0]]=q[1]:q.length===3?typeof q[1]===FUNC_TYPE&&!(q[1].exec&&q[1].test)?this[q[0]]=match2?q[1].call(this,match2,q[2]):undefined2:this[q[0]]=match2?match2.replace(q[1],q[2]):undefined2:q.length===4&&(this[q[0]]=match2?q[3].call(this,match2.replace(q[1],q[2])):undefined2):this[q]=match2||undefined2;i+=2}},strMapper=function(str,map4){for(var i in map4)if(typeof map4[i]===OBJ_TYPE&&map4[i].length>0){for(var j=0;j<map4[i].length;j++)if(has(map4[i][j],str))return i===UNKNOWN?undefined2:i}else if(has(map4[i],str))return i===UNKNOWN?undefined2:i;return str},oldSafariMap={"1.0":"/8","1.2":"/1","1.3":"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"},windowsVersionMap={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2","8.1":"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},regexes={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[VERSION2,[NAME,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[VERSION2,[NAME,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[NAME,VERSION2],[/opios[\/ ]+([\w\.]+)/i],[VERSION2,[NAME,OPERA+" Mini"]],[/\bopr\/([\w\.]+)/i],[VERSION2,[NAME,OPERA]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[VERSION2,[NAME,"Baidu"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim)\s?(?:browser)?[\/ ]?([\w\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|qq|duckduckgo)\/([-\w\.]+)/i,/(heytap|ovi)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[NAME,VERSION2],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[VERSION2,[NAME,"UC"+BROWSER]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[VERSION2,[NAME,"WeChat"]],[/konqueror\/([\w\.]+)/i],[VERSION2,[NAME,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[VERSION2,[NAME,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[VERSION2,[NAME,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[VERSION2,[NAME,"Smart Lenovo "+BROWSER]],[/(avast|avg)\/([\w\.]+)/i],[[NAME,/(.+)/,"$1 Secure "+BROWSER],VERSION2],[/\bfocus\/([\w\.]+)/i],[VERSION2,[NAME,FIREFOX+" Focus"]],[/\bopt\/([\w\.]+)/i],[VERSION2,[NAME,OPERA+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[VERSION2,[NAME,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[VERSION2,[NAME,"Dolphin"]],[/coast\/([\w\.]+)/i],[VERSION2,[NAME,OPERA+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[VERSION2,[NAME,"MIUI "+BROWSER]],[/fxios\/([-\w\.]+)/i],[VERSION2,[NAME,FIREFOX]],[/\bqihu|(qi?ho?o?|360)browser/i],[[NAME,"360 "+BROWSER]],[/(oculus|sailfish|huawei|vivo)browser\/([\w\.]+)/i],[[NAME,/(.+)/,"$1 "+BROWSER],VERSION2],[/samsungbrowser\/([\w\.]+)/i],[VERSION2,[NAME,SAMSUNG+" Internet"]],[/(comodo_dragon)\/([\w\.]+)/i],[[NAME,/_/g," "],VERSION2],[/metasr[\/ ]?([\d\.]+)/i],[VERSION2,[NAME,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[NAME,"Sogou Mobile"],VERSION2],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345Explorer)[\/ ]?([\w\.]+)/i],[NAME,VERSION2],[/(lbbrowser)/i,/\[(linkedin)app\]/i],[NAME],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[NAME,FACEBOOK],VERSION2],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[NAME,VERSION2],[/\bgsa\/([\w\.]+) .*safari\//i],[VERSION2,[NAME,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[VERSION2,[NAME,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[VERSION2,[NAME,CHROME+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[NAME,CHROME+" WebView"],VERSION2],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[VERSION2,[NAME,"Android "+BROWSER]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[NAME,VERSION2],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[VERSION2,[NAME,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[VERSION2,NAME],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[NAME,[VERSION2,strMapper,oldSafariMap]],[/(webkit|khtml)\/([\w\.]+)/i],[NAME,VERSION2],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[NAME,"Netscape"],VERSION2],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[VERSION2,[NAME,FIREFOX+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror|klar)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i,/panasonic;(viera)/i],[NAME,VERSION2],[/(cobalt)\/([\w\.]+)/i],[NAME,[VERSION2,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[ARCHITECTURE,"amd64"]],[/(ia32(?=;))/i],[[ARCHITECTURE,lowerize]],[/((?:i[346]|x)86)[;\)]/i],[[ARCHITECTURE,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[ARCHITECTURE,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[ARCHITECTURE,"armhf"]],[/windows (ce|mobile); ppc;/i],[[ARCHITECTURE,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[ARCHITECTURE,/ower/,EMPTY2,lowerize]],[/(sun4\w)[;\)]/i],[[ARCHITECTURE,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[ARCHITECTURE,lowerize]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[MODEL,[VENDOR,SAMSUNG],[TYPE,TABLET]],[/\b((?:s[cgp]h|gt|sm)-\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]([-\w]+)/i,/sec-(sgh\w+)/i],[MODEL,[VENDOR,SAMSUNG],[TYPE,MOBILE]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[MODEL,[VENDOR,APPLE],[TYPE,MOBILE]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[MODEL,[VENDOR,APPLE],[TYPE,TABLET]],[/(macintosh);/i],[MODEL,[VENDOR,APPLE]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[MODEL,[VENDOR,SHARP],[TYPE,MOBILE]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[MODEL,[VENDOR,HUAWEI],[TYPE,TABLET]],[/(?:huawei|honor)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[MODEL,[VENDOR,HUAWEI],[TYPE,MOBILE]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\))/i],[[MODEL,/_/g," "],[VENDOR,XIAOMI],[TYPE,MOBILE]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[MODEL,/_/g," "],[VENDOR,XIAOMI],[TYPE,TABLET]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[MODEL,[VENDOR,"OPPO"],[TYPE,MOBILE]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[MODEL,[VENDOR,"Vivo"],[TYPE,MOBILE]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[MODEL,[VENDOR,"Realme"],[TYPE,MOBILE]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[MODEL,[VENDOR,MOTOROLA],[TYPE,MOBILE]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[MODEL,[VENDOR,MOTOROLA],[TYPE,TABLET]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[MODEL,[VENDOR,LG],[TYPE,TABLET]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[MODEL,[VENDOR,LG],[TYPE,MOBILE]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[MODEL,[VENDOR,"Lenovo"],[TYPE,TABLET]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[MODEL,/_/g," "],[VENDOR,"Nokia"],[TYPE,MOBILE]],[/(pixel c)\b/i],[MODEL,[VENDOR,GOOGLE],[TYPE,TABLET]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[MODEL,[VENDOR,GOOGLE],[TYPE,MOBILE]],[/droid.+ (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[MODEL,[VENDOR,SONY],[TYPE,MOBILE]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[MODEL,"Xperia Tablet"],[VENDOR,SONY],[TYPE,TABLET]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[MODEL,[VENDOR,"OnePlus"],[TYPE,MOBILE]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[MODEL,[VENDOR,AMAZON],[TYPE,TABLET]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[MODEL,/(.+)/g,"Fire Phone $1"],[VENDOR,AMAZON],[TYPE,MOBILE]],[/(playbook);[-\w\),; ]+(rim)/i],[MODEL,VENDOR,[TYPE,TABLET]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[MODEL,[VENDOR,BLACKBERRY],[TYPE,MOBILE]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[MODEL,[VENDOR,ASUS],[TYPE,TABLET]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[MODEL,[VENDOR,ASUS],[TYPE,MOBILE]],[/(nexus 9)/i],[MODEL,[VENDOR,"HTC"],[TYPE,TABLET]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[VENDOR,[MODEL,/_/g," "],[TYPE,MOBILE]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[MODEL,[VENDOR,"Acer"],[TYPE,TABLET]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[MODEL,[VENDOR,"Meizu"],[TYPE,MOBILE]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[MODEL,[VENDOR,"Ulefone"],[TYPE,MOBILE]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno)[-_ ]?([-\w]*)/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[VENDOR,MODEL,[TYPE,MOBILE]],[/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[VENDOR,MODEL,[TYPE,TABLET]],[/(surface duo)/i],[MODEL,[VENDOR,MICROSOFT],[TYPE,TABLET]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[MODEL,[VENDOR,"Fairphone"],[TYPE,MOBILE]],[/(u304aa)/i],[MODEL,[VENDOR,"AT&T"],[TYPE,MOBILE]],[/\bsie-(\w*)/i],[MODEL,[VENDOR,"Siemens"],[TYPE,MOBILE]],[/\b(rct\w+) b/i],[MODEL,[VENDOR,"RCA"],[TYPE,TABLET]],[/\b(venue[\d ]{2,7}) b/i],[MODEL,[VENDOR,"Dell"],[TYPE,TABLET]],[/\b(q(?:mv|ta)\w+) b/i],[MODEL,[VENDOR,"Verizon"],[TYPE,TABLET]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[MODEL,[VENDOR,"Barnes & Noble"],[TYPE,TABLET]],[/\b(tm\d{3}\w+) b/i],[MODEL,[VENDOR,"NuVision"],[TYPE,TABLET]],[/\b(k88) b/i],[MODEL,[VENDOR,"ZTE"],[TYPE,TABLET]],[/\b(nx\d{3}j) b/i],[MODEL,[VENDOR,"ZTE"],[TYPE,MOBILE]],[/\b(gen\d{3}) b.+49h/i],[MODEL,[VENDOR,"Swiss"],[TYPE,MOBILE]],[/\b(zur\d{3}) b/i],[MODEL,[VENDOR,"Swiss"],[TYPE,TABLET]],[/\b((zeki)?tb.*\b) b/i],[MODEL,[VENDOR,"Zeki"],[TYPE,TABLET]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[VENDOR,"Dragon Touch"],MODEL,[TYPE,TABLET]],[/\b(ns-?\w{0,9}) b/i],[MODEL,[VENDOR,"Insignia"],[TYPE,TABLET]],[/\b((nxa|next)-?\w{0,9}) b/i],[MODEL,[VENDOR,"NextBook"],[TYPE,TABLET]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[VENDOR,"Voice"],MODEL,[TYPE,MOBILE]],[/\b(lvtel\-)?(v1[12]) b/i],[[VENDOR,"LvTel"],MODEL,[TYPE,MOBILE]],[/\b(ph-1) /i],[MODEL,[VENDOR,"Essential"],[TYPE,MOBILE]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[MODEL,[VENDOR,"Envizen"],[TYPE,TABLET]],[/\b(trio[-\w\. ]+) b/i],[MODEL,[VENDOR,"MachSpeed"],[TYPE,TABLET]],[/\btu_(1491) b/i],[MODEL,[VENDOR,"Rotor"],[TYPE,TABLET]],[/(shield[\w ]+) b/i],[MODEL,[VENDOR,"Nvidia"],[TYPE,TABLET]],[/(sprint) (\w+)/i],[VENDOR,MODEL,[TYPE,MOBILE]],[/(kin\.[onetw]{3})/i],[[MODEL,/\./g," "],[VENDOR,MICROSOFT],[TYPE,MOBILE]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[MODEL,[VENDOR,ZEBRA],[TYPE,TABLET]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[MODEL,[VENDOR,ZEBRA],[TYPE,MOBILE]],[/smart-tv.+(samsung)/i],[VENDOR,[TYPE,SMARTTV]],[/hbbtv.+maple;(\d+)/i],[[MODEL,/^/,"SmartTV"],[VENDOR,SAMSUNG],[TYPE,SMARTTV]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[VENDOR,LG],[TYPE,SMARTTV]],[/(apple) ?tv/i],[VENDOR,[MODEL,APPLE+" TV"],[TYPE,SMARTTV]],[/crkey/i],[[MODEL,CHROME+"cast"],[VENDOR,GOOGLE],[TYPE,SMARTTV]],[/droid.+aft(\w+)( bui|\))/i],[MODEL,[VENDOR,AMAZON],[TYPE,SMARTTV]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[MODEL,[VENDOR,SHARP],[TYPE,SMARTTV]],[/(bravia[\w ]+)( bui|\))/i],[MODEL,[VENDOR,SONY],[TYPE,SMARTTV]],[/(mitv-\w{5}) bui/i],[MODEL,[VENDOR,XIAOMI],[TYPE,SMARTTV]],[/Hbbtv.*(technisat) (.*);/i],[VENDOR,MODEL,[TYPE,SMARTTV]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[VENDOR,trim],[MODEL,trim],[TYPE,SMARTTV]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[TYPE,SMARTTV]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[VENDOR,MODEL,[TYPE,CONSOLE]],[/droid.+; (shield) bui/i],[MODEL,[VENDOR,"Nvidia"],[TYPE,CONSOLE]],[/(playstation [345portablevi]+)/i],[MODEL,[VENDOR,SONY],[TYPE,CONSOLE]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[MODEL,[VENDOR,MICROSOFT],[TYPE,CONSOLE]],[/((pebble))app/i],[VENDOR,MODEL,[TYPE,WEARABLE]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[MODEL,[VENDOR,APPLE],[TYPE,WEARABLE]],[/droid.+; (glass) \d/i],[MODEL,[VENDOR,GOOGLE],[TYPE,WEARABLE]],[/droid.+; (wt63?0{2,3})\)/i],[MODEL,[VENDOR,ZEBRA],[TYPE,WEARABLE]],[/(quest( 2| pro)?)/i],[MODEL,[VENDOR,FACEBOOK],[TYPE,WEARABLE]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[VENDOR,[TYPE,EMBEDDED]],[/(aeobc)\b/i],[MODEL,[VENDOR,AMAZON],[TYPE,EMBEDDED]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[MODEL,[TYPE,MOBILE]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[MODEL,[TYPE,TABLET]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[TYPE,TABLET]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[TYPE,MOBILE]],[/(android[-\w\. ]{0,9});.+buil/i],[MODEL,[VENDOR,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[VERSION2,[NAME,EDGE+"HTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[VERSION2,[NAME,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[NAME,VERSION2],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[VERSION2,NAME]],os:[[/microsoft (windows) (vista|xp)/i],[NAME,VERSION2],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[NAME,[VERSION2,strMapper,windowsVersionMap]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[VERSION2,strMapper,windowsVersionMap],[NAME,"Windows"]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[VERSION2,/_/g,"."],[NAME,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[NAME,MAC_OS],[VERSION2,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[VERSION2,NAME],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[NAME,VERSION2],[/\(bb(10);/i],[VERSION2,[NAME,BLACKBERRY]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[VERSION2,[NAME,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[VERSION2,[NAME,FIREFOX+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[VERSION2,[NAME,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[VERSION2,[NAME,"watchOS"]],[/crkey\/([\d\.]+)/i],[VERSION2,[NAME,CHROME+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[NAME,CHROMIUM_OS],VERSION2],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[NAME,VERSION2],[/(sunos) ?([\w\.\d]*)/i],[[NAME,"Solaris"],VERSION2],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[NAME,VERSION2]]},UAParser2=function(ua,extensions){if(typeof ua===OBJ_TYPE&&(extensions=ua,ua=undefined2),!(this instanceof UAParser2))return new UAParser2(ua,extensions).getResult();var _navigator=typeof window2!==UNDEF_TYPE&&window2.navigator?window2.navigator:undefined2,_ua=ua||(_navigator&&_navigator.userAgent?_navigator.userAgent:EMPTY2),_uach=_navigator&&_navigator.userAgentData?_navigator.userAgentData:undefined2,_rgxmap=extensions?extend3(regexes,extensions):regexes,_isSelfNav=_navigator&&_navigator.userAgent==_ua;return this.getBrowser=function(){var _browser={};return _browser[NAME]=undefined2,_browser[VERSION2]=undefined2,rgxMapper.call(_browser,_ua,_rgxmap.browser),_browser[MAJOR]=majorize(_browser[VERSION2]),_isSelfNav&&_navigator&&_navigator.brave&&typeof _navigator.brave.isBrave==FUNC_TYPE&&(_browser[NAME]="Brave"),_browser},this.getCPU=function(){var _cpu={};return _cpu[ARCHITECTURE]=undefined2,rgxMapper.call(_cpu,_ua,_rgxmap.cpu),_cpu},this.getDevice=function(){var _device={};return _device[VENDOR]=undefined2,_device[MODEL]=undefined2,_device[TYPE]=undefined2,rgxMapper.call(_device,_ua,_rgxmap.device),_isSelfNav&&!_device[TYPE]&&_uach&&_uach.mobile&&(_device[TYPE]=MOBILE),_isSelfNav&&_device[MODEL]=="Macintosh"&&_navigator&&typeof _navigator.standalone!==UNDEF_TYPE&&_navigator.maxTouchPoints&&_navigator.maxTouchPoints>2&&(_device[MODEL]="iPad",_device[TYPE]=TABLET),_device},this.getEngine=function(){var _engine={};return _engine[NAME]=undefined2,_engine[VERSION2]=undefined2,rgxMapper.call(_engine,_ua,_rgxmap.engine),_engine},this.getOS=function(){var _os={};return _os[NAME]=undefined2,_os[VERSION2]=undefined2,rgxMapper.call(_os,_ua,_rgxmap.os),_isSelfNav&&!_os[NAME]&&_uach&&_uach.platform!="Unknown"&&(_os[NAME]=_uach.platform.replace(/chrome os/i,CHROMIUM_OS).replace(/macos/i,MAC_OS)),_os},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return _ua},this.setUA=function(ua2){return _ua=typeof ua2===STR_TYPE&&ua2.length>UA_MAX_LENGTH?trim(ua2,UA_MAX_LENGTH):ua2,this},this.setUA(_ua),this};UAParser2.VERSION=LIBVERSION,UAParser2.BROWSER=enumerize([NAME,VERSION2,MAJOR]),UAParser2.CPU=enumerize([ARCHITECTURE]),UAParser2.DEVICE=enumerize([MODEL,VENDOR,TYPE,CONSOLE,MOBILE,SMARTTV,TABLET,WEARABLE,EMBEDDED]),UAParser2.ENGINE=UAParser2.OS=enumerize([NAME,VERSION2]),typeof exports!==UNDEF_TYPE?(typeof module!==UNDEF_TYPE&&module.exports&&(exports=module.exports=UAParser2),exports.UAParser=UAParser2):typeof define===FUNC_TYPE&&define.amd?define(function(){return UAParser2}):typeof window2!==UNDEF_TYPE&&(window2.UAParser=UAParser2);var $=typeof window2!==UNDEF_TYPE&&(window2.jQuery||window2.Zepto);if($&&!$.ua){var parser=new UAParser2;$.ua=parser.getResult(),$.ua.get=function(){return parser.getUA()},$.ua.set=function(ua){parser.setUA(ua);var result=parser.getResult();for(var prop in result)$.ua[prop]=result[prop]}}})(typeof window=="object"?window:exports)}});var require_dayjs_min=__commonJS({"node_modules/dayjs/dayjs.min.js"(exports,module){(function(t,e){typeof exports=="object"&&typeof module<"u"?module.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self).dayjs=e()})(exports,function(){"use strict";var t=1e3,e=6e4,n2=36e5,r="millisecond",i="second",s2="minute",u="hour",a="day",o="week",c="month",f="quarter",h="year",d="date",l2="Invalid Date",$=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t2){var e2=["th","st","nd","rd"],n3=t2%100;return"["+t2+(e2[(n3-20)%10]||e2[n3]||e2[0])+"]"}},m=function(t2,e2,n3){var r2=String(t2);return!r2||r2.length>=e2?t2:""+Array(e2+1-r2.length).join(n3)+t2},v={s:m,z:function(t2){var e2=-t2.utcOffset(),n3=Math.abs(e2),r2=Math.floor(n3/60),i2=n3%60;return(e2<=0?"+":"-")+m(r2,2,"0")+":"+m(i2,2,"0")},m:function t2(e2,n3){if(e2.date()<n3.date())return-t2(n3,e2);var r2=12*(n3.year()-e2.year())+(n3.month()-e2.month()),i2=e2.clone().add(r2,c),s3=n3-i2<0,u2=e2.clone().add(r2+(s3?-1:1),c);return+(-(r2+(n3-i2)/(s3?i2-u2:u2-i2))||0)},a:function(t2){return t2<0?Math.ceil(t2)||0:Math.floor(t2)},p:function(t2){return{M:c,y:h,w:o,d:a,D:d,h:u,m:s2,s:i,ms:r,Q:f}[t2]||String(t2||"").toLowerCase().replace(/s$/,"")},u:function(t2){return t2===void 0}},g="en",D={};D[g]=M;var p="$isDayjsObject",S=function(t2){return t2 instanceof _||!(!t2||!t2[p])},w=function t2(e2,n3,r2){var i2;if(!e2)return g;if(typeof e2=="string"){var s3=e2.toLowerCase();D[s3]&&(i2=s3),n3&&(D[s3]=n3,i2=s3);var u2=e2.split("-");if(!i2&&u2.length>1)return t2(u2[0])}else{var a2=e2.name;D[a2]=e2,i2=a2}return!r2&&i2&&(g=i2),i2||!r2&&g},O=function(t2,e2){if(S(t2))return t2.clone();var n3=typeof e2=="object"?e2:{};return n3.date=t2,n3.args=arguments,new _(n3)},b=v;b.l=w,b.i=S,b.w=function(t2,e2){return O(t2,{locale:e2.$L,utc:e2.$u,x:e2.$x,$offset:e2.$offset})};var _=(function(){function M2(t2){this.$L=w(t2.locale,null,!0),this.parse(t2),this.$x=this.$x||t2.x||{},this[p]=!0}var m2=M2.prototype;return m2.parse=function(t2){this.$d=(function(t3){var e2=t3.date,n3=t3.utc;if(e2===null)return new Date(NaN);if(b.u(e2))return new Date;if(e2 instanceof Date)return new Date(e2);if(typeof e2=="string"&&!/Z$/i.test(e2)){var r2=e2.match($);if(r2){var i2=r2[2]-1||0,s3=(r2[7]||"0").substring(0,3);return n3?new Date(Date.UTC(r2[1],i2,r2[3]||1,r2[4]||0,r2[5]||0,r2[6]||0,s3)):new Date(r2[1],i2,r2[3]||1,r2[4]||0,r2[5]||0,r2[6]||0,s3)}}return new Date(e2)})(t2),this.init()},m2.init=function(){var t2=this.$d;this.$y=t2.getFullYear(),this.$M=t2.getMonth(),this.$D=t2.getDate(),this.$W=t2.getDay(),this.$H=t2.getHours(),this.$m=t2.getMinutes(),this.$s=t2.getSeconds(),this.$ms=t2.getMilliseconds()},m2.$utils=function(){return b},m2.isValid=function(){return this.$d.toString()!==l2},m2.isSame=function(t2,e2){var n3=O(t2);return this.startOf(e2)<=n3&&n3<=this.endOf(e2)},m2.isAfter=function(t2,e2){return O(t2)<this.startOf(e2)},m2.isBefore=function(t2,e2){return this.endOf(e2)<O(t2)},m2.$g=function(t2,e2,n3){return b.u(t2)?this[e2]:this.set(n3,t2)},m2.unix=function(){return Math.floor(this.valueOf()/1e3)},m2.valueOf=function(){return this.$d.getTime()},m2.startOf=function(t2,e2){var n3=this,r2=!!b.u(e2)||e2,f2=b.p(t2),l3=function(t3,e3){var i2=b.w(n3.$u?Date.UTC(n3.$y,e3,t3):new Date(n3.$y,e3,t3),n3);return r2?i2:i2.endOf(a)},$2=function(t3,e3){return b.w(n3.toDate()[t3].apply(n3.toDate("s"),(r2?[0,0,0,0]:[23,59,59,999]).slice(e3)),n3)},y2=this.$W,M3=this.$M,m3=this.$D,v2="set"+(this.$u?"UTC":"");switch(f2){case h:return r2?l3(1,0):l3(31,11);case c:return r2?l3(1,M3):l3(0,M3+1);case o:var g2=this.$locale().weekStart||0,D2=(y2<g2?y2+7:y2)-g2;return l3(r2?m3-D2:m3+(6-D2),M3);case a:case d:return $2(v2+"Hours",0);case u:return $2(v2+"Minutes",1);case s2:return $2(v2+"Seconds",2);case i:return $2(v2+"Milliseconds",3);default:return this.clone()}},m2.endOf=function(t2){return this.startOf(t2,!1)},m2.$set=function(t2,e2){var n3,o2=b.p(t2),f2="set"+(this.$u?"UTC":""),l3=(n3={},n3[a]=f2+"Date",n3[d]=f2+"Date",n3[c]=f2+"Month",n3[h]=f2+"FullYear",n3[u]=f2+"Hours",n3[s2]=f2+"Minutes",n3[i]=f2+"Seconds",n3[r]=f2+"Milliseconds",n3)[o2],$2=o2===a?this.$D+(e2-this.$W):e2;if(o2===c||o2===h){var y2=this.clone().set(d,1);y2.$d[l3]($2),y2.init(),this.$d=y2.set(d,Math.min(this.$D,y2.daysInMonth())).$d}else l3&&this.$d[l3]($2);return this.init(),this},m2.set=function(t2,e2){return this.clone().$set(t2,e2)},m2.get=function(t2){return this[b.p(t2)]()},m2.add=function(r2,f2){var d2,l3=this;r2=Number(r2);var $2=b.p(f2),y2=function(t2){var e2=O(l3);return b.w(e2.date(e2.date()+Math.round(t2*r2)),l3)};if($2===c)return this.set(c,this.$M+r2);if($2===h)return this.set(h,this.$y+r2);if($2===a)return y2(1);if($2===o)return y2(7);var M3=(d2={},d2[s2]=e,d2[u]=n2,d2[i]=t,d2)[$2]||1,m3=this.$d.getTime()+r2*M3;return b.w(m3,this)},m2.subtract=function(t2,e2){return this.add(-1*t2,e2)},m2.format=function(t2){var e2=this,n3=this.$locale();if(!this.isValid())return n3.invalidDate||l2;var r2=t2||"YYYY-MM-DDTHH:mm:ssZ",i2=b.z(this),s3=this.$H,u2=this.$m,a2=this.$M,o2=n3.weekdays,c2=n3.months,f2=n3.meridiem,h2=function(t3,n4,i3,s4){return t3&&(t3[n4]||t3(e2,r2))||i3[n4].slice(0,s4)},d2=function(t3){return b.s(s3%12||12,t3,"0")},$2=f2||function(t3,e3,n4){var r3=t3<12?"AM":"PM";return n4?r3.toLowerCase():r3};return r2.replace(y,function(t3,r3){return r3||(function(t4){switch(t4){case"YY":return String(e2.$y).slice(-2);case"YYYY":return b.s(e2.$y,4,"0");case"M":return a2+1;case"MM":return b.s(a2+1,2,"0");case"MMM":return h2(n3.monthsShort,a2,c2,3);case"MMMM":return h2(c2,a2);case"D":return e2.$D;case"DD":return b.s(e2.$D,2,"0");case"d":return String(e2.$W);case"dd":return h2(n3.weekdaysMin,e2.$W,o2,2);case"ddd":return h2(n3.weekdaysShort,e2.$W,o2,3);case"dddd":return o2[e2.$W];case"H":return String(s3);case"HH":return b.s(s3,2,"0");case"h":return d2(1);case"hh":return d2(2);case"a":return $2(s3,u2,!0);case"A":return $2(s3,u2,!1);case"m":return String(u2);case"mm":return b.s(u2,2,"0");case"s":return String(e2.$s);case"ss":return b.s(e2.$s,2,"0");case"SSS":return b.s(e2.$ms,3,"0");case"Z":return i2}return null})(t3)||i2.replace(":","")})},m2.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m2.diff=function(r2,d2,l3){var $2,y2=this,M3=b.p(d2),m3=O(r2),v2=(m3.utcOffset()-this.utcOffset())*e,g2=this-m3,D2=function(){return b.m(y2,m3)};switch(M3){case h:$2=D2()/12;break;case c:$2=D2();break;case f:$2=D2()/3;break;case o:$2=(g2-v2)/6048e5;break;case a:$2=(g2-v2)/864e5;break;case u:$2=g2/n2;break;case s2:$2=g2/e;break;case i:$2=g2/t;break;default:$2=g2}return l3?$2:b.a($2)},m2.daysInMonth=function(){return this.endOf(c).$D},m2.$locale=function(){return D[this.$L]},m2.locale=function(t2,e2){if(!t2)return this.$L;var n3=this.clone(),r2=w(t2,e2,!0);return r2&&(n3.$L=r2),n3},m2.clone=function(){return b.w(this.$d,this)},m2.toDate=function(){return new Date(this.valueOf())},m2.toJSON=function(){return this.isValid()?this.toISOString():null},m2.toISOString=function(){return this.$d.toISOString()},m2.toString=function(){return this.$d.toUTCString()},M2})(),k=_.prototype;return O.prototype=k,[["$ms",r],["$s",i],["$m",s2],["$H",u],["$W",a],["$M",c],["$y",h],["$D",d]].forEach(function(t2){k[t2[1]]=function(e2){return this.$g(e2,t2[0],t2[1])}}),O.extend=function(t2,e2){return t2.$i||(t2(e2,_,O),t2.$i=!0),O},O.locale=w,O.isDayjs=S,O.unix=function(t2){return O(1e3*t2)},O.en=D[g],O.Ls=D,O.p={},O})}});var require_localeData=__commonJS({"node_modules/dayjs/plugin/localeData.js"(exports,module){(function(n2,e){typeof exports=="object"&&typeof module<"u"?module.exports=e():typeof define=="function"&&define.amd?define(e):(n2=typeof globalThis<"u"?globalThis:n2||self).dayjs_plugin_localeData=e()})(exports,function(){"use strict";return function(n2,e,t){var r=e.prototype,o=function(n3){return n3&&(n3.indexOf?n3:n3.s)},u=function(n3,e2,t2,r2,u2){var i2=n3.name?n3:n3.$locale(),a2=o(i2[e2]),s3=o(i2[t2]),f=a2||s3.map(function(n4){return n4.slice(0,r2)});if(!u2)return f;var d=i2.weekStart;return f.map(function(n4,e3){return f[(e3+(d||0))%7]})},i=function(){return t.Ls[t.locale()]},a=function(n3,e2){return n3.formats[e2]||(function(n4){return n4.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(n5,e3,t2){return e3||t2.slice(1)})})(n3.formats[e2.toUpperCase()])},s2=function(){var n3=this;return{months:function(e2){return e2?e2.format("MMMM"):u(n3,"months")},monthsShort:function(e2){return e2?e2.format("MMM"):u(n3,"monthsShort","months",3)},firstDayOfWeek:function(){return n3.$locale().weekStart||0},weekdays:function(e2){return e2?e2.format("dddd"):u(n3,"weekdays")},weekdaysMin:function(e2){return e2?e2.format("dd"):u(n3,"weekdaysMin","weekdays",2)},weekdaysShort:function(e2){return e2?e2.format("ddd"):u(n3,"weekdaysShort","weekdays",3)},longDateFormat:function(e2){return a(n3.$locale(),e2)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};r.localeData=function(){return s2.bind(this)()},t.localeData=function(){var n3=i();return{firstDayOfWeek:function(){return n3.weekStart||0},weekdays:function(){return t.weekdays()},weekdaysShort:function(){return t.weekdaysShort()},weekdaysMin:function(){return t.weekdaysMin()},months:function(){return t.months()},monthsShort:function(){return t.monthsShort()},longDateFormat:function(e2){return a(n3,e2)},meridiem:n3.meridiem,ordinal:n3.ordinal}},t.months=function(){return u(i(),"months")},t.monthsShort=function(){return u(i(),"monthsShort","months",3)},t.weekdays=function(n3){return u(i(),"weekdays",null,null,n3)},t.weekdaysShort=function(n3){return u(i(),"weekdaysShort","weekdays",3,n3)},t.weekdaysMin=function(n3){return u(i(),"weekdaysMin","weekdays",2,n3)}}})}});var require_localizedFormat=__commonJS({"node_modules/dayjs/plugin/localizedFormat.js"(exports,module){(function(e,t){typeof exports=="object"&&typeof module<"u"?module.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_localizedFormat=t()})(exports,function(){"use strict";var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(t,o,n2){var r=o.prototype,i=r.format;n2.en.formats=e,r.format=function(t2){t2===void 0&&(t2="YYYY-MM-DDTHH:mm:ssZ");var o2=this.$locale().formats,n3=(function(t3,o3){return t3.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(t4,n4,r2){var i2=r2&&r2.toUpperCase();return n4||o3[r2]||e[r2]||o3[i2].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(e2,t5,o4){return t5||o4.slice(1)})})})(t2,o2===void 0?{}:o2);return i.call(this,n3)}}})}});var require_isoWeek=__commonJS({"node_modules/dayjs/plugin/isoWeek.js"(exports,module){(function(e,t){typeof exports=="object"&&typeof module<"u"?module.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_isoWeek=t()})(exports,function(){"use strict";var e="day";return function(t,i,s2){var a=function(t2){return t2.add(4-t2.isoWeekday(),e)},d=i.prototype;d.isoWeekYear=function(){return a(this).year()},d.isoWeek=function(t2){if(!this.$utils().u(t2))return this.add(7*(t2-this.isoWeek()),e);var i2,d2,n3,o,r=a(this),u=(i2=this.isoWeekYear(),d2=this.$u,n3=(d2?s2.utc:s2)().year(i2).startOf("year"),o=4-n3.isoWeekday(),n3.isoWeekday()>4&&(o+=7),n3.add(o,e));return r.diff(u,"week")+1},d.isoWeekday=function(e2){return this.$utils().u(e2)?this.day()||7:this.day(this.day()%7?e2:e2-7)};var n2=d.startOf;d.startOf=function(e2,t2){var i2=this.$utils(),s3=!!i2.u(t2)||t2;return i2.p(e2)==="isoweek"?s3?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):n2.bind(this)(e2,t2)}}})}});var require_weekOfYear=__commonJS({"node_modules/dayjs/plugin/weekOfYear.js"(exports,module){(function(e,t){typeof exports=="object"&&typeof module<"u"?module.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_weekOfYear=t()})(exports,function(){"use strict";var e="week",t="year";return function(i,n2,r){var f=n2.prototype;f.week=function(i2){if(i2===void 0&&(i2=null),i2!==null)return this.add(7*(i2-this.week()),"day");var n3=this.$locale().yearStart||1;if(this.month()===11&&this.date()>25){var f2=r(this).startOf(t).add(1,t).date(n3),s2=r(this).endOf(e);if(f2.isBefore(s2))return 1}var a=r(this).startOf(t).date(n3).startOf(e).subtract(1,"millisecond"),o=this.diff(a,e,!0);return o<0?r(this).startOf("week").week():Math.ceil(o)},f.weeks=function(e2){return e2===void 0&&(e2=null),this.week(e2)}}})}});var require_customParseFormat=__commonJS({"node_modules/dayjs/plugin/customParseFormat.js"(exports,module){(function(e,t){typeof exports=="object"&&typeof module<"u"?module.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_customParseFormat=t()})(exports,function(){"use strict";var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},t=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,n2=/\d/,r=/\d\d/,i=/\d\d?/,o=/\d*[^-_:/,()\s\d]+/,s2={},a=function(e2){return(e2=+e2)+(e2>68?1900:2e3)},f=function(e2){return function(t2){this[e2]=+t2}},h=[/[+-]\d\d:?(\d\d)?|Z/,function(e2){(this.zone||(this.zone={})).offset=(function(e3){if(!e3||e3==="Z")return 0;var t2=e3.match(/([+-]|\d\d)/g),n3=60*t2[1]+(+t2[2]||0);return n3===0?0:t2[0]==="+"?-n3:n3})(e2)}],u=function(e2){var t2=s2[e2];return t2&&(t2.indexOf?t2:t2.s.concat(t2.f))},d=function(e2,t2){var n3,r2=s2.meridiem;if(r2){for(var i2=1;i2<=24;i2+=1)if(e2.indexOf(r2(i2,0,t2))>-1){n3=i2>12;break}}else n3=e2===(t2?"pm":"PM");return n3},c={A:[o,function(e2){this.afternoon=d(e2,!1)}],a:[o,function(e2){this.afternoon=d(e2,!0)}],Q:[n2,function(e2){this.month=3*(e2-1)+1}],S:[n2,function(e2){this.milliseconds=100*+e2}],SS:[r,function(e2){this.milliseconds=10*+e2}],SSS:[/\d{3}/,function(e2){this.milliseconds=+e2}],s:[i,f("seconds")],ss:[i,f("seconds")],m:[i,f("minutes")],mm:[i,f("minutes")],H:[i,f("hours")],h:[i,f("hours")],HH:[i,f("hours")],hh:[i,f("hours")],D:[i,f("day")],DD:[r,f("day")],Do:[o,function(e2){var t2=s2.ordinal,n3=e2.match(/\d+/);if(this.day=n3[0],t2)for(var r2=1;r2<=31;r2+=1)t2(r2).replace(/\[|\]/g,"")===e2&&(this.day=r2)}],w:[i,f("week")],ww:[r,f("week")],M:[i,f("month")],MM:[r,f("month")],MMM:[o,function(e2){var t2=u("months"),n3=(u("monthsShort")||t2.map(function(e3){return e3.slice(0,3)})).indexOf(e2)+1;if(n3<1)throw new Error;this.month=n3%12||n3}],MMMM:[o,function(e2){var t2=u("months").indexOf(e2)+1;if(t2<1)throw new Error;this.month=t2%12||t2}],Y:[/[+-]?\d+/,f("year")],YY:[r,function(e2){this.year=a(e2)}],YYYY:[/\d{4}/,f("year")],Z:h,ZZ:h};function l2(n3){var r2,i2;r2=n3,i2=s2&&s2.formats;for(var o2=(n3=r2.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(t2,n4,r3){var o3=r3&&r3.toUpperCase();return n4||i2[r3]||e[r3]||i2[o3].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(e2,t3,n5){return t3||n5.slice(1)})})).match(t),a2=o2.length,f2=0;f2<a2;f2+=1){var h2=o2[f2],u2=c[h2],d2=u2&&u2[0],l3=u2&&u2[1];o2[f2]=l3?{regex:d2,parser:l3}:h2.replace(/^\[|\]$/g,"")}return function(e2){for(var t2={},n4=0,r3=0;n4<a2;n4+=1){var i3=o2[n4];if(typeof i3=="string")r3+=i3.length;else{var s3=i3.regex,f3=i3.parser,h3=e2.slice(r3),u3=s3.exec(h3)[0];f3.call(t2,u3),e2=e2.replace(u3,"")}}return(function(e3){var t3=e3.afternoon;if(t3!==void 0){var n5=e3.hours;t3?n5<12&&(e3.hours+=12):n5===12&&(e3.hours=0),delete e3.afternoon}})(t2),t2}}return function(e2,t2,n3){n3.p.customParseFormat=!0,e2&&e2.parseTwoDigitYear&&(a=e2.parseTwoDigitYear);var r2=t2.prototype,i2=r2.parse;r2.parse=function(e3){var t3=e3.date,r3=e3.utc,o2=e3.args;this.$u=r3;var a2=o2[1];if(typeof a2=="string"){var f2=o2[2]===!0,h2=o2[3]===!0,u2=f2||h2,d2=o2[2];h2&&(d2=o2[2]),s2=this.$locale(),!f2&&d2&&(s2=n3.Ls[d2]),this.$d=(function(e4,t4,n4,r4){try{if(["x","X"].indexOf(t4)>-1)return new Date((t4==="X"?1e3:1)*e4);var i3=l2(t4)(e4),o3=i3.year,s3=i3.month,a3=i3.day,f3=i3.hours,h3=i3.minutes,u3=i3.seconds,d3=i3.milliseconds,c3=i3.zone,m2=i3.week,M2=new Date,Y=a3||(o3||s3?1:M2.getDate()),p=o3||M2.getFullYear(),v=0;o3&&!s3||(v=s3>0?s3-1:M2.getMonth());var D,w=f3||0,g=h3||0,y=u3||0,L=d3||0;return c3?new Date(Date.UTC(p,v,Y,w,g,y,L+60*c3.offset*1e3)):n4?new Date(Date.UTC(p,v,Y,w,g,y,L)):(D=new Date(p,v,Y,w,g,y,L),m2&&(D=r4(D).week(m2).toDate()),D)}catch{return new Date("")}})(t3,a2,r3,n3),this.init(),d2&&d2!==!0&&(this.$L=this.locale(d2).$L),u2&&t3!=this.format(a2)&&(this.$d=new Date("")),s2={}}else if(a2 instanceof Array)for(var c2=a2.length,m=1;m<=c2;m+=1){o2[1]=a2[m-1];var M=n3.apply(this,o2);if(M.isValid()){this.$d=M.$d,this.$L=M.$L,this.init();break}m===c2&&(this.$d=new Date(""))}else i2.call(this,e3)}}})}});var require_formats=__commonJS({"node_modules/lorem-ipsum/dist/constants/formats.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.FORMAT_PLAIN=exports.FORMAT_HTML=exports.FORMATS=void 0;var FORMAT_HTML="html";exports.FORMAT_HTML=FORMAT_HTML;var FORMAT_PLAIN="plain";exports.FORMAT_PLAIN=FORMAT_PLAIN;var FORMATS=[FORMAT_HTML,FORMAT_PLAIN];exports.FORMATS=FORMATS}});var require_units=__commonJS({"node_modules/lorem-ipsum/dist/constants/units.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.UNIT_WORDS=exports.UNIT_WORD=exports.UNIT_SENTENCES=exports.UNIT_SENTENCE=exports.UNIT_PARAGRAPHS=exports.UNIT_PARAGRAPH=exports.UNITS=void 0;var UNIT_WORDS="words";exports.UNIT_WORDS=UNIT_WORDS;var UNIT_WORD="word";exports.UNIT_WORD=UNIT_WORD;var UNIT_SENTENCES="sentences";exports.UNIT_SENTENCES=UNIT_SENTENCES;var UNIT_SENTENCE="sentence";exports.UNIT_SENTENCE=UNIT_SENTENCE;var UNIT_PARAGRAPHS="paragraphs";exports.UNIT_PARAGRAPHS=UNIT_PARAGRAPHS;var UNIT_PARAGRAPH="paragraph";exports.UNIT_PARAGRAPH=UNIT_PARAGRAPH;var UNITS=[UNIT_WORDS,UNIT_WORD,UNIT_SENTENCES,UNIT_SENTENCE,UNIT_PARAGRAPHS,UNIT_PARAGRAPH];exports.UNITS=UNITS}});var require_words=__commonJS({"node_modules/lorem-ipsum/dist/constants/words.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.WORDS=void 0;var WORDS=["ad","adipisicing","aliqua","aliquip","amet","anim","aute","cillum","commodo","consectetur","consequat","culpa","cupidatat","deserunt","do","dolor","dolore","duis","ea","eiusmod","elit","enim","esse","est","et","eu","ex","excepteur","exercitation","fugiat","id","in","incididunt","ipsum","irure","labore","laboris","laborum","Lorem","magna","minim","mollit","nisi","non","nostrud","nulla","occaecat","officia","pariatur","proident","qui","quis","reprehenderit","sint","sit","sunt","tempor","ullamco","ut","velit","veniam","voluptate"];exports.WORDS=WORDS}});var require_lineEndings=__commonJS({"node_modules/lorem-ipsum/dist/constants/lineEndings.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.LINE_ENDINGS=void 0;var LINE_ENDINGS={POSIX:`
1
+ import{require_jszip_min}from"./chunk-HG4GZ56Y.js";import{quill_default}from"./chunk-WMR5ZEMM.js";import{A11yModule,ACTIVE_RUNTIME_CHECKS,ANIMATION_MODULE_TYPE,APP_CONFIG,APP_INITIALIZER,AUTO_STYLE,Actions,ActionsSubject,ActivatedRoute,AnimationGroupPlayer,AnimationMetadataType,AnonymousSubject,ApplicationRef,AsyncPipe,BackendComponentCallerService,BackendComponentCallerServiceFactory,BackendComponentClient,BackendComponentClientProxyService,BehaviorSubject,BreakpointObserver,Breakpoints,BrowserModule,CdkDrag,CdkDragPlaceholder,CdkDragPreview,CdkDropList,CdkFixedSizeVirtualScroll,CdkMonitorFocus,CdkPortalOutlet,CdkTextareaAutosize,CdkTrapFocus,CdkVirtualForOf,CdkVirtualScrollViewport,ChangeDetectorRef,CommonModule,ComponentFactoryResolver$1,ComponentPortal,ComponentTemplateValidatorService,DEFAULT_CARD_DIMENSIONS,DEFAULT_CBC_INGRESS_URL,DEFAULT_REPORT_DIMENSIONS,DEFAULT_SHEET_DIMENSIONS,DOCUMENT,DataSource,DateAdapter,DefaultFlexDirective,DefaultLayoutAlignDirective,DefaultLayoutDirective,DefaultLayoutGapDirective,DefaultValueAccessor,DestroyRef,Directionality,DomRendererFactory2,DomSanitizer,DragDropModule,EMPTY,EffectsModule,ElementRef,ErrorHandler,EventEmitter,FlexLayoutModule,FlexModule,FormArray,FormBuilder,FormControl,FormControlDirective,FormControlName,FormGroup,FormGroupDirective,FormGroupName,FormsModule,HTTP_INTERCEPTORS,HostAttributeToken,HttpClient,HttpContext,HttpErrorResponse,HttpHeaders,HttpParams,HttpResponse,INIT,INITIAL_STATE,IXAPI_OPTIONS,InjectionToken,Injector,IterableDiffers,IxApi2RequestErrorMessages,IxApiErrorMessages,IxApiErrors,IxApiHeaderKeys,IxApiModule,IxApiRequestErrorMessages,IxApiRequestErrors,IxApiService,LayoutModule,Location,LowerCasePipe,MAT_BOTTOM_SHEET_DATA,MAT_DATE_FORMATS,MAT_DATE_LOCALE,MAT_DIALOG_DATA,MAT_INPUT_VALUE_ACCESSOR,MatActionList,MatBottomSheet,MatBottomSheetRef,MatButton,MatButtonModule,MatCard,MatCardActions,MatCardHeader,MatCardModule,MatCardSubtitle,MatCardTitle,MatCheckbox,MatCheckboxModule,MatCommonModule,MatDatepicker,MatDatepickerInput,MatDatepickerToggle,MatDialog,MatDialogActions,MatDialogClose,MatDialogContainer,MatDialogContent,MatDialogModule,MatDialogRef,MatDialogTitle,MatDivider,MatDividerModule,MatDrawer,MatDrawerContainer,MatDrawerContent,MatError,MatExpansionPanel,MatFormField,MatFormFieldModule,MatHint,MatIcon,MatIconButton,MatIconModule,MatIconRegistry,MatInput,MatInputModule,MatLabel,MatList,MatListItem,MatListItemIcon,MatListItemLine,MatListItemMeta,MatListItemTitle,MatListModule,MatListOption,MatListSubheaderCssMatStyler,MatMenu,MatMenuItem,MatMenuModule,MatMenuTrigger,MatOptgroup,MatOption,MatOptionModule,MatPaginatorModule,MatPrefix,MatProgressSpinner,MatSelect,MatSelectModule,MatSelectTrigger,MatSelectionList,MatSidenavModule,MatSnackBar,MatSnackBarModule,MatSuffix,MatTab,MatTabGroup,MatTabsModule,MatToolbar,MatToolbarModule,MatTooltip,MatTooltipModule,MediaObserver,Meta,MinValidator,MtxPopoverModule,NG_VALIDATORS,NG_VALUE_ACCESSOR,NavigationCancel,NavigationEnd,NavigationError,NavigationStart,NgControl,NgControlStatus,NgControlStatusGroup,NgForOf,NgForm,NgIf,NgModel,NgSelectOption,NgStyle,NgTemplateOutlet,NgZone,NoopAnimationPlayer,NumberValueAccessor,ONE_WEEK,OTP_SMS_REQUIRED_PATTERN,Observable,Overlay,OverlayConfig,OverlayModule,PAGE_COMPONENT,PLATFORM_ID,PageComponentTemplateManifestModule,PageComponentTemplateModule,PageComponentTemplateService,Platform,PortalModule,REQUIRES_BRANDING,REQUIRES_COMPANY,ReactiveFormsModule,ReducerManagerDispatcher,ReducerObservable,Renderer2,RendererFactory2,ReplaySubject,RequiredValidator,ResourceDataClient,ResourceDataClientProxyService,ResourceDataServiceFactory,Router,RouterLink,RouterModule,RouterOutlet,RoutesRecognized,RuntimeError,SESSION_STORAGE,STORAGE_KEY_CBC_CONFIG_VALUES,STORAGE_KEY_CBC_INGRESS,STORAGE_KEY_CBC_INGRESS_URL,STORAGE_KEY_CBC_PUBLIC_ID,ScannedActionsSubject,ScrollingModule,SecurityContext,SelectControlValueAccessor,SelectionModel,SettingsModule,SharedModule,StateObservable,StorageEventContext,StorageModule,StorageService,Store,StoreModule,Subject,Subscriber,Subscription,TREE_KEY_MANAGER,TemplateRef,Title,TitleCasePipe,TranslateDirective,TranslateLoader,TranslateModule,TranslatePipe,TranslateService,UPDATE,USER_PROVIDED_EFFECTS,Validators,ViewContainerRef,ViewportRuler,WA_WINDOW,WINDOW,_getFocusedElementPierceShadowDom,add,addFailure,addSuccess,afterNextRender,appConfigFactory,booleanAttribute,buffer,buildFields,catchError,coerceBooleanProperty,coerceNumberProperty,coerceObservable,coerceStringArray,combineLatest,compactFields,computed,concat,concatMap,createAction,createEffect,createEntityAdapter,createFeature,createFeatureSelector,createReducer,createResourceAdapter,createResourceSelectorFactory,createSelector,debounceTime,decryptValue,defaultOptions,defer,delay,delayWhen,didAdd,didAddList,didRemove,didRemoveList,didUpdate,didUpdateList,distinctUntilChanged,effect,ensureAll,ensureMany,ensureOne,environment,filter,findAppId,first,firstValueFrom,forkJoin,forwardRef,from,fromEvent,getLinkMap,getLinkUrl,getMissingFields,getPageParams,hasFields,hasModifierKey,hasNonPublicIdFields,haveFields,inject,input,isDataSource,isDevMode,isNgrxMockEnvironment,isObservable,isPlatformBrowser,isPlatformServer,last,lastValueFrom,linkedSignal,loadAllForIntentSuccess,loadAllSuccess,loadAppConfig,loadHost,loadHostFailure,loadHostSuccess,loadManySuccess,makeEnvironmentProviders,map,mapPageComponentTemplateManifestToDefaultInputs,mapPageComponentTemplateToCustomElementName,mapPageComponentTemplateToTemplateBaseUrl,mapPageComponentTemplateToTemplateUrl,mapResourceToSubResourceList,mapTemplateUrlToMainPath,mapTemplateUrlToManifestUrl,mapTemplateUrlToPublicId,merge,mergeFields,mergeLoadedFields,mergeMap,moveItemInArray,mustache_default,naturalSort,normalizePassiveListenerOptions,numberAttribute,observeOn,of,ofStatus,ofType,omitLoadedFields,omitSubresources,on,output,pairwise,parseBody,platformBrowser,props,provideEnvironmentInitializer,provideHttpClient,queueScheduler,reduce,remove,removeFailure,removeSuccess,require_crypto_js,reset,reset2,reset3,resetPendingUpdates,resource,retryBackoff,scan,select,selectAll,selectEntities,selectEntities2,selectEntity,selectEntity2,sequence,share,shareReplay,signal,skip,sortByNameAndPublicIdComparer,startWith,style,switchMap,take,takeUntil,takeUntilDestroyed,tap,throwError,throwNotFoundError,timeout,timer,toObservable,toSignal,update,updateFailure,updateMany,updateManyFailure,updateManySuccess,updateResource,updateSuccess,validateOptions,viewChild,whileMoreAfter,withInterceptorsFromDi,withLatestFrom,ɵNgNoValidate,ɵNgSelectMultipleOption,ɵPRE_STYLE,ɵɵInheritDefinitionFeature,ɵɵNgOnChangesFeature,ɵɵProvidersFeature,ɵɵadvance,ɵɵattribute,ɵɵclassMap,ɵɵclassProp,ɵɵconditional,ɵɵconditionalCreate,ɵɵcontentQuery,ɵɵdeclareLet,ɵɵdefineComponent,ɵɵdefineDirective,ɵɵdefineInjectable,ɵɵdefineInjector,ɵɵdefineNgModule,ɵɵdefinePipe,ɵɵdirectiveInject,ɵɵdomElement,ɵɵdomElementEnd,ɵɵdomElementStart,ɵɵdomListener,ɵɵdomProperty,ɵɵelement,ɵɵelementContainer,ɵɵelementContainerEnd,ɵɵelementContainerStart,ɵɵelementEnd,ɵɵelementStart,ɵɵgetCurrentView,ɵɵgetInheritedFactory,ɵɵinject,ɵɵinterpolate,ɵɵinterpolate1,ɵɵlistener,ɵɵloadQuery,ɵɵnamespaceHTML,ɵɵnamespaceSVG,ɵɵnextContext,ɵɵpipe,ɵɵpipeBind1,ɵɵpipeBind2,ɵɵpipeBind3,ɵɵprojection,ɵɵprojectionDef,ɵɵproperty,ɵɵpureFunction0,ɵɵpureFunction1,ɵɵqueryAdvance,ɵɵqueryRefresh,ɵɵreadContextLet,ɵɵreference,ɵɵrepeater,ɵɵrepeaterCreate,ɵɵrepeaterTrackByIdentity,ɵɵrepeaterTrackByIndex,ɵɵresetView,ɵɵresolveDocument,ɵɵrestoreView,ɵɵsanitizeHtml,ɵɵsanitizeUrl,ɵɵstoreLet,ɵɵstyleMap,ɵɵstyleProp,ɵɵtemplate,ɵɵtemplateRefExtractor,ɵɵtext,ɵɵtextInterpolate,ɵɵtextInterpolate1,ɵɵtextInterpolate2,ɵɵtextInterpolate3,ɵɵtwoWayBindingSet,ɵɵtwoWayListener,ɵɵtwoWayProperty,ɵɵviewQuery,ɵɵviewQuerySignal}from"./chunk-BV4VXOFH.js";import{camelCase_default,capitalize_default,cloneDeep_default,compact_default,deburr_default,escape_default,flatMap_default,flatten_default,get_default,groupBy_default,has_default,isArray_default,isEmpty_default,isEqual_default,isNil_default,isObject_default,isString_default,isUndefined_default,kebabCase_default,memoize_default,merge_default,omitBy_default,omit_default,orderBy_default,pick_default,range_default,set_default,snakeCase_default,sortBy_default,startCase_default,template_default,uniqBy_default,uniq_default,upperFirst_default}from"./chunk-W3TLLCWQ.js";import{__async,__commonJS,__esm,__export,__objRest,__require,__spreadProps,__spreadValues,__superGet,__toCommonJS,__toESM,__yieldStar}from"./chunk-EFEL2YQJ.js";var require_FileSaver_min=__commonJS({"node_modules/file-saver/dist/FileSaver.min.js"(exports,module){(function(a,b){typeof define=="function"&&define.amd?define([],b):typeof exports<"u"?b():(b(),a.FileSaver={})})(exports,function(){"use strict";function b(a2,b2){return typeof b2>"u"?b2={autoBom:!1}:typeof b2!="object"&&(console.warn("Deprecated: Expected third argument to be a object"),b2={autoBom:!b2}),b2.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(a2.type)?new Blob(["\uFEFF",a2],{type:a2.type}):a2}function c(a2,b2,c2){var d2=new XMLHttpRequest;d2.open("GET",a2),d2.responseType="blob",d2.onload=function(){g(d2.response,b2,c2)},d2.onerror=function(){console.error("could not download file")},d2.send()}function d(a2){var b2=new XMLHttpRequest;b2.open("HEAD",a2,!1);try{b2.send()}catch{}return 200<=b2.status&&299>=b2.status}function e(a2){try{a2.dispatchEvent(new MouseEvent("click"))}catch{var b2=document.createEvent("MouseEvents");b2.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),a2.dispatchEvent(b2)}}var f=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof global=="object"&&global.global===global?global:void 0,a=f.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),g=f.saveAs||(typeof window!="object"||window!==f?function(){}:"download"in HTMLAnchorElement.prototype&&!a?function(b2,g2,h){var i=f.URL||f.webkitURL,j=document.createElement("a");g2=g2||b2.name||"download",j.download=g2,j.rel="noopener",typeof b2=="string"?(j.href=b2,j.origin===location.origin?e(j):d(j.href)?c(b2,g2,h):e(j,j.target="_blank")):(j.href=i.createObjectURL(b2),setTimeout(function(){i.revokeObjectURL(j.href)},4e4),setTimeout(function(){e(j)},0))}:"msSaveOrOpenBlob"in navigator?function(f2,g2,h){if(g2=g2||f2.name||"download",typeof f2!="string")navigator.msSaveOrOpenBlob(b(f2,h),g2);else if(d(f2))c(f2,g2,h);else{var i=document.createElement("a");i.href=f2,i.target="_blank",setTimeout(function(){e(i)})}}:function(b2,d2,e2,g2){if(g2=g2||open("","_blank"),g2&&(g2.document.title=g2.document.body.innerText="downloading..."),typeof b2=="string")return c(b2,d2,e2);var h=b2.type==="application/octet-stream",i=/constructor/i.test(f.HTMLElement)||f.safari,j=/CriOS\/[\d]+/.test(navigator.userAgent);if((j||h&&i||a)&&typeof FileReader<"u"){var k=new FileReader;k.onloadend=function(){var a2=k.result;a2=j?a2:a2.replace(/^data:[^;]*;/,"data:attachment/file;"),g2?g2.location.href=a2:location=a2,g2=null},k.readAsDataURL(b2)}else{var l2=f.URL||f.webkitURL,m=l2.createObjectURL(b2);g2?g2.location=m:location.href=m,g2=null,setTimeout(function(){l2.revokeObjectURL(m)},4e4)}});f.saveAs=g.saveAs=g,typeof module<"u"&&(module.exports=g)})}});var require_ua_parser=__commonJS({"node_modules/ua-parser-js/src/ua-parser.js"(exports,module){(function(window2,undefined2){"use strict";var LIBVERSION="1.0.37",EMPTY2="",UNKNOWN="?",FUNC_TYPE="function",UNDEF_TYPE="undefined",OBJ_TYPE="object",STR_TYPE="string",MAJOR="major",MODEL="model",NAME="name",TYPE="type",VENDOR="vendor",VERSION2="version",ARCHITECTURE="architecture",CONSOLE="console",MOBILE="mobile",TABLET="tablet",SMARTTV="smarttv",WEARABLE="wearable",EMBEDDED="embedded",UA_MAX_LENGTH=500,AMAZON="Amazon",APPLE="Apple",ASUS="ASUS",BLACKBERRY="BlackBerry",BROWSER="Browser",CHROME="Chrome",EDGE="Edge",FIREFOX="Firefox",GOOGLE="Google",HUAWEI="Huawei",LG="LG",MICROSOFT="Microsoft",MOTOROLA="Motorola",OPERA="Opera",SAMSUNG="Samsung",SHARP="Sharp",SONY="Sony",XIAOMI="Xiaomi",ZEBRA="Zebra",FACEBOOK="Facebook",CHROMIUM_OS="Chromium OS",MAC_OS="Mac OS",extend3=function(regexes2,extensions){var mergedRegexes={};for(var i in regexes2)extensions[i]&&extensions[i].length%2===0?mergedRegexes[i]=extensions[i].concat(regexes2[i]):mergedRegexes[i]=regexes2[i];return mergedRegexes},enumerize=function(arr){for(var enums={},i=0;i<arr.length;i++)enums[arr[i].toUpperCase()]=arr[i];return enums},has=function(str1,str2){return typeof str1===STR_TYPE?lowerize(str2).indexOf(lowerize(str1))!==-1:!1},lowerize=function(str){return str.toLowerCase()},majorize=function(version2){return typeof version2===STR_TYPE?version2.replace(/[^\d\.]/g,EMPTY2).split(".")[0]:undefined2},trim=function(str,len){if(typeof str===STR_TYPE)return str=str.replace(/^\s\s*/,EMPTY2),typeof len===UNDEF_TYPE?str:str.substring(0,UA_MAX_LENGTH)},rgxMapper=function(ua,arrays){for(var i=0,j,k,p,q,matches,match2;i<arrays.length&&!matches;){var regex=arrays[i],props2=arrays[i+1];for(j=k=0;j<regex.length&&!matches&&regex[j];)if(matches=regex[j++].exec(ua),matches)for(p=0;p<props2.length;p++)match2=matches[++k],q=props2[p],typeof q===OBJ_TYPE&&q.length>0?q.length===2?typeof q[1]==FUNC_TYPE?this[q[0]]=q[1].call(this,match2):this[q[0]]=q[1]:q.length===3?typeof q[1]===FUNC_TYPE&&!(q[1].exec&&q[1].test)?this[q[0]]=match2?q[1].call(this,match2,q[2]):undefined2:this[q[0]]=match2?match2.replace(q[1],q[2]):undefined2:q.length===4&&(this[q[0]]=match2?q[3].call(this,match2.replace(q[1],q[2])):undefined2):this[q]=match2||undefined2;i+=2}},strMapper=function(str,map4){for(var i in map4)if(typeof map4[i]===OBJ_TYPE&&map4[i].length>0){for(var j=0;j<map4[i].length;j++)if(has(map4[i][j],str))return i===UNKNOWN?undefined2:i}else if(has(map4[i],str))return i===UNKNOWN?undefined2:i;return str},oldSafariMap={"1.0":"/8","1.2":"/1","1.3":"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"},windowsVersionMap={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2","8.1":"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},regexes={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[VERSION2,[NAME,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[VERSION2,[NAME,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[NAME,VERSION2],[/opios[\/ ]+([\w\.]+)/i],[VERSION2,[NAME,OPERA+" Mini"]],[/\bopr\/([\w\.]+)/i],[VERSION2,[NAME,OPERA]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[VERSION2,[NAME,"Baidu"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim)\s?(?:browser)?[\/ ]?([\w\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|qq|duckduckgo)\/([-\w\.]+)/i,/(heytap|ovi)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[NAME,VERSION2],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[VERSION2,[NAME,"UC"+BROWSER]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[VERSION2,[NAME,"WeChat"]],[/konqueror\/([\w\.]+)/i],[VERSION2,[NAME,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[VERSION2,[NAME,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[VERSION2,[NAME,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[VERSION2,[NAME,"Smart Lenovo "+BROWSER]],[/(avast|avg)\/([\w\.]+)/i],[[NAME,/(.+)/,"$1 Secure "+BROWSER],VERSION2],[/\bfocus\/([\w\.]+)/i],[VERSION2,[NAME,FIREFOX+" Focus"]],[/\bopt\/([\w\.]+)/i],[VERSION2,[NAME,OPERA+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[VERSION2,[NAME,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[VERSION2,[NAME,"Dolphin"]],[/coast\/([\w\.]+)/i],[VERSION2,[NAME,OPERA+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[VERSION2,[NAME,"MIUI "+BROWSER]],[/fxios\/([-\w\.]+)/i],[VERSION2,[NAME,FIREFOX]],[/\bqihu|(qi?ho?o?|360)browser/i],[[NAME,"360 "+BROWSER]],[/(oculus|sailfish|huawei|vivo)browser\/([\w\.]+)/i],[[NAME,/(.+)/,"$1 "+BROWSER],VERSION2],[/samsungbrowser\/([\w\.]+)/i],[VERSION2,[NAME,SAMSUNG+" Internet"]],[/(comodo_dragon)\/([\w\.]+)/i],[[NAME,/_/g," "],VERSION2],[/metasr[\/ ]?([\d\.]+)/i],[VERSION2,[NAME,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[NAME,"Sogou Mobile"],VERSION2],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345Explorer)[\/ ]?([\w\.]+)/i],[NAME,VERSION2],[/(lbbrowser)/i,/\[(linkedin)app\]/i],[NAME],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[NAME,FACEBOOK],VERSION2],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[NAME,VERSION2],[/\bgsa\/([\w\.]+) .*safari\//i],[VERSION2,[NAME,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[VERSION2,[NAME,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[VERSION2,[NAME,CHROME+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[NAME,CHROME+" WebView"],VERSION2],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[VERSION2,[NAME,"Android "+BROWSER]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[NAME,VERSION2],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[VERSION2,[NAME,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[VERSION2,NAME],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[NAME,[VERSION2,strMapper,oldSafariMap]],[/(webkit|khtml)\/([\w\.]+)/i],[NAME,VERSION2],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[NAME,"Netscape"],VERSION2],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[VERSION2,[NAME,FIREFOX+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror|klar)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i,/panasonic;(viera)/i],[NAME,VERSION2],[/(cobalt)\/([\w\.]+)/i],[NAME,[VERSION2,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[ARCHITECTURE,"amd64"]],[/(ia32(?=;))/i],[[ARCHITECTURE,lowerize]],[/((?:i[346]|x)86)[;\)]/i],[[ARCHITECTURE,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[ARCHITECTURE,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[ARCHITECTURE,"armhf"]],[/windows (ce|mobile); ppc;/i],[[ARCHITECTURE,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[ARCHITECTURE,/ower/,EMPTY2,lowerize]],[/(sun4\w)[;\)]/i],[[ARCHITECTURE,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[ARCHITECTURE,lowerize]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[MODEL,[VENDOR,SAMSUNG],[TYPE,TABLET]],[/\b((?:s[cgp]h|gt|sm)-\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]([-\w]+)/i,/sec-(sgh\w+)/i],[MODEL,[VENDOR,SAMSUNG],[TYPE,MOBILE]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[MODEL,[VENDOR,APPLE],[TYPE,MOBILE]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[MODEL,[VENDOR,APPLE],[TYPE,TABLET]],[/(macintosh);/i],[MODEL,[VENDOR,APPLE]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[MODEL,[VENDOR,SHARP],[TYPE,MOBILE]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[MODEL,[VENDOR,HUAWEI],[TYPE,TABLET]],[/(?:huawei|honor)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[MODEL,[VENDOR,HUAWEI],[TYPE,MOBILE]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\))/i],[[MODEL,/_/g," "],[VENDOR,XIAOMI],[TYPE,MOBILE]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[MODEL,/_/g," "],[VENDOR,XIAOMI],[TYPE,TABLET]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[MODEL,[VENDOR,"OPPO"],[TYPE,MOBILE]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[MODEL,[VENDOR,"Vivo"],[TYPE,MOBILE]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[MODEL,[VENDOR,"Realme"],[TYPE,MOBILE]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[MODEL,[VENDOR,MOTOROLA],[TYPE,MOBILE]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[MODEL,[VENDOR,MOTOROLA],[TYPE,TABLET]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[MODEL,[VENDOR,LG],[TYPE,TABLET]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[MODEL,[VENDOR,LG],[TYPE,MOBILE]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[MODEL,[VENDOR,"Lenovo"],[TYPE,TABLET]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[MODEL,/_/g," "],[VENDOR,"Nokia"],[TYPE,MOBILE]],[/(pixel c)\b/i],[MODEL,[VENDOR,GOOGLE],[TYPE,TABLET]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[MODEL,[VENDOR,GOOGLE],[TYPE,MOBILE]],[/droid.+ (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[MODEL,[VENDOR,SONY],[TYPE,MOBILE]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[MODEL,"Xperia Tablet"],[VENDOR,SONY],[TYPE,TABLET]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[MODEL,[VENDOR,"OnePlus"],[TYPE,MOBILE]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[MODEL,[VENDOR,AMAZON],[TYPE,TABLET]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[MODEL,/(.+)/g,"Fire Phone $1"],[VENDOR,AMAZON],[TYPE,MOBILE]],[/(playbook);[-\w\),; ]+(rim)/i],[MODEL,VENDOR,[TYPE,TABLET]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[MODEL,[VENDOR,BLACKBERRY],[TYPE,MOBILE]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[MODEL,[VENDOR,ASUS],[TYPE,TABLET]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[MODEL,[VENDOR,ASUS],[TYPE,MOBILE]],[/(nexus 9)/i],[MODEL,[VENDOR,"HTC"],[TYPE,TABLET]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[VENDOR,[MODEL,/_/g," "],[TYPE,MOBILE]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[MODEL,[VENDOR,"Acer"],[TYPE,TABLET]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[MODEL,[VENDOR,"Meizu"],[TYPE,MOBILE]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[MODEL,[VENDOR,"Ulefone"],[TYPE,MOBILE]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno)[-_ ]?([-\w]*)/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[VENDOR,MODEL,[TYPE,MOBILE]],[/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[VENDOR,MODEL,[TYPE,TABLET]],[/(surface duo)/i],[MODEL,[VENDOR,MICROSOFT],[TYPE,TABLET]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[MODEL,[VENDOR,"Fairphone"],[TYPE,MOBILE]],[/(u304aa)/i],[MODEL,[VENDOR,"AT&T"],[TYPE,MOBILE]],[/\bsie-(\w*)/i],[MODEL,[VENDOR,"Siemens"],[TYPE,MOBILE]],[/\b(rct\w+) b/i],[MODEL,[VENDOR,"RCA"],[TYPE,TABLET]],[/\b(venue[\d ]{2,7}) b/i],[MODEL,[VENDOR,"Dell"],[TYPE,TABLET]],[/\b(q(?:mv|ta)\w+) b/i],[MODEL,[VENDOR,"Verizon"],[TYPE,TABLET]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[MODEL,[VENDOR,"Barnes & Noble"],[TYPE,TABLET]],[/\b(tm\d{3}\w+) b/i],[MODEL,[VENDOR,"NuVision"],[TYPE,TABLET]],[/\b(k88) b/i],[MODEL,[VENDOR,"ZTE"],[TYPE,TABLET]],[/\b(nx\d{3}j) b/i],[MODEL,[VENDOR,"ZTE"],[TYPE,MOBILE]],[/\b(gen\d{3}) b.+49h/i],[MODEL,[VENDOR,"Swiss"],[TYPE,MOBILE]],[/\b(zur\d{3}) b/i],[MODEL,[VENDOR,"Swiss"],[TYPE,TABLET]],[/\b((zeki)?tb.*\b) b/i],[MODEL,[VENDOR,"Zeki"],[TYPE,TABLET]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[VENDOR,"Dragon Touch"],MODEL,[TYPE,TABLET]],[/\b(ns-?\w{0,9}) b/i],[MODEL,[VENDOR,"Insignia"],[TYPE,TABLET]],[/\b((nxa|next)-?\w{0,9}) b/i],[MODEL,[VENDOR,"NextBook"],[TYPE,TABLET]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[VENDOR,"Voice"],MODEL,[TYPE,MOBILE]],[/\b(lvtel\-)?(v1[12]) b/i],[[VENDOR,"LvTel"],MODEL,[TYPE,MOBILE]],[/\b(ph-1) /i],[MODEL,[VENDOR,"Essential"],[TYPE,MOBILE]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[MODEL,[VENDOR,"Envizen"],[TYPE,TABLET]],[/\b(trio[-\w\. ]+) b/i],[MODEL,[VENDOR,"MachSpeed"],[TYPE,TABLET]],[/\btu_(1491) b/i],[MODEL,[VENDOR,"Rotor"],[TYPE,TABLET]],[/(shield[\w ]+) b/i],[MODEL,[VENDOR,"Nvidia"],[TYPE,TABLET]],[/(sprint) (\w+)/i],[VENDOR,MODEL,[TYPE,MOBILE]],[/(kin\.[onetw]{3})/i],[[MODEL,/\./g," "],[VENDOR,MICROSOFT],[TYPE,MOBILE]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[MODEL,[VENDOR,ZEBRA],[TYPE,TABLET]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[MODEL,[VENDOR,ZEBRA],[TYPE,MOBILE]],[/smart-tv.+(samsung)/i],[VENDOR,[TYPE,SMARTTV]],[/hbbtv.+maple;(\d+)/i],[[MODEL,/^/,"SmartTV"],[VENDOR,SAMSUNG],[TYPE,SMARTTV]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[VENDOR,LG],[TYPE,SMARTTV]],[/(apple) ?tv/i],[VENDOR,[MODEL,APPLE+" TV"],[TYPE,SMARTTV]],[/crkey/i],[[MODEL,CHROME+"cast"],[VENDOR,GOOGLE],[TYPE,SMARTTV]],[/droid.+aft(\w+)( bui|\))/i],[MODEL,[VENDOR,AMAZON],[TYPE,SMARTTV]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[MODEL,[VENDOR,SHARP],[TYPE,SMARTTV]],[/(bravia[\w ]+)( bui|\))/i],[MODEL,[VENDOR,SONY],[TYPE,SMARTTV]],[/(mitv-\w{5}) bui/i],[MODEL,[VENDOR,XIAOMI],[TYPE,SMARTTV]],[/Hbbtv.*(technisat) (.*);/i],[VENDOR,MODEL,[TYPE,SMARTTV]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[VENDOR,trim],[MODEL,trim],[TYPE,SMARTTV]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[TYPE,SMARTTV]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[VENDOR,MODEL,[TYPE,CONSOLE]],[/droid.+; (shield) bui/i],[MODEL,[VENDOR,"Nvidia"],[TYPE,CONSOLE]],[/(playstation [345portablevi]+)/i],[MODEL,[VENDOR,SONY],[TYPE,CONSOLE]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[MODEL,[VENDOR,MICROSOFT],[TYPE,CONSOLE]],[/((pebble))app/i],[VENDOR,MODEL,[TYPE,WEARABLE]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[MODEL,[VENDOR,APPLE],[TYPE,WEARABLE]],[/droid.+; (glass) \d/i],[MODEL,[VENDOR,GOOGLE],[TYPE,WEARABLE]],[/droid.+; (wt63?0{2,3})\)/i],[MODEL,[VENDOR,ZEBRA],[TYPE,WEARABLE]],[/(quest( 2| pro)?)/i],[MODEL,[VENDOR,FACEBOOK],[TYPE,WEARABLE]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[VENDOR,[TYPE,EMBEDDED]],[/(aeobc)\b/i],[MODEL,[VENDOR,AMAZON],[TYPE,EMBEDDED]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[MODEL,[TYPE,MOBILE]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[MODEL,[TYPE,TABLET]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[TYPE,TABLET]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[TYPE,MOBILE]],[/(android[-\w\. ]{0,9});.+buil/i],[MODEL,[VENDOR,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[VERSION2,[NAME,EDGE+"HTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[VERSION2,[NAME,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[NAME,VERSION2],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[VERSION2,NAME]],os:[[/microsoft (windows) (vista|xp)/i],[NAME,VERSION2],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[NAME,[VERSION2,strMapper,windowsVersionMap]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[VERSION2,strMapper,windowsVersionMap],[NAME,"Windows"]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[VERSION2,/_/g,"."],[NAME,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[NAME,MAC_OS],[VERSION2,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[VERSION2,NAME],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[NAME,VERSION2],[/\(bb(10);/i],[VERSION2,[NAME,BLACKBERRY]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[VERSION2,[NAME,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[VERSION2,[NAME,FIREFOX+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[VERSION2,[NAME,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[VERSION2,[NAME,"watchOS"]],[/crkey\/([\d\.]+)/i],[VERSION2,[NAME,CHROME+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[NAME,CHROMIUM_OS],VERSION2],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[NAME,VERSION2],[/(sunos) ?([\w\.\d]*)/i],[[NAME,"Solaris"],VERSION2],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[NAME,VERSION2]]},UAParser2=function(ua,extensions){if(typeof ua===OBJ_TYPE&&(extensions=ua,ua=undefined2),!(this instanceof UAParser2))return new UAParser2(ua,extensions).getResult();var _navigator=typeof window2!==UNDEF_TYPE&&window2.navigator?window2.navigator:undefined2,_ua=ua||(_navigator&&_navigator.userAgent?_navigator.userAgent:EMPTY2),_uach=_navigator&&_navigator.userAgentData?_navigator.userAgentData:undefined2,_rgxmap=extensions?extend3(regexes,extensions):regexes,_isSelfNav=_navigator&&_navigator.userAgent==_ua;return this.getBrowser=function(){var _browser={};return _browser[NAME]=undefined2,_browser[VERSION2]=undefined2,rgxMapper.call(_browser,_ua,_rgxmap.browser),_browser[MAJOR]=majorize(_browser[VERSION2]),_isSelfNav&&_navigator&&_navigator.brave&&typeof _navigator.brave.isBrave==FUNC_TYPE&&(_browser[NAME]="Brave"),_browser},this.getCPU=function(){var _cpu={};return _cpu[ARCHITECTURE]=undefined2,rgxMapper.call(_cpu,_ua,_rgxmap.cpu),_cpu},this.getDevice=function(){var _device={};return _device[VENDOR]=undefined2,_device[MODEL]=undefined2,_device[TYPE]=undefined2,rgxMapper.call(_device,_ua,_rgxmap.device),_isSelfNav&&!_device[TYPE]&&_uach&&_uach.mobile&&(_device[TYPE]=MOBILE),_isSelfNav&&_device[MODEL]=="Macintosh"&&_navigator&&typeof _navigator.standalone!==UNDEF_TYPE&&_navigator.maxTouchPoints&&_navigator.maxTouchPoints>2&&(_device[MODEL]="iPad",_device[TYPE]=TABLET),_device},this.getEngine=function(){var _engine={};return _engine[NAME]=undefined2,_engine[VERSION2]=undefined2,rgxMapper.call(_engine,_ua,_rgxmap.engine),_engine},this.getOS=function(){var _os={};return _os[NAME]=undefined2,_os[VERSION2]=undefined2,rgxMapper.call(_os,_ua,_rgxmap.os),_isSelfNav&&!_os[NAME]&&_uach&&_uach.platform!="Unknown"&&(_os[NAME]=_uach.platform.replace(/chrome os/i,CHROMIUM_OS).replace(/macos/i,MAC_OS)),_os},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return _ua},this.setUA=function(ua2){return _ua=typeof ua2===STR_TYPE&&ua2.length>UA_MAX_LENGTH?trim(ua2,UA_MAX_LENGTH):ua2,this},this.setUA(_ua),this};UAParser2.VERSION=LIBVERSION,UAParser2.BROWSER=enumerize([NAME,VERSION2,MAJOR]),UAParser2.CPU=enumerize([ARCHITECTURE]),UAParser2.DEVICE=enumerize([MODEL,VENDOR,TYPE,CONSOLE,MOBILE,SMARTTV,TABLET,WEARABLE,EMBEDDED]),UAParser2.ENGINE=UAParser2.OS=enumerize([NAME,VERSION2]),typeof exports!==UNDEF_TYPE?(typeof module!==UNDEF_TYPE&&module.exports&&(exports=module.exports=UAParser2),exports.UAParser=UAParser2):typeof define===FUNC_TYPE&&define.amd?define(function(){return UAParser2}):typeof window2!==UNDEF_TYPE&&(window2.UAParser=UAParser2);var $=typeof window2!==UNDEF_TYPE&&(window2.jQuery||window2.Zepto);if($&&!$.ua){var parser=new UAParser2;$.ua=parser.getResult(),$.ua.get=function(){return parser.getUA()},$.ua.set=function(ua){parser.setUA(ua);var result=parser.getResult();for(var prop in result)$.ua[prop]=result[prop]}}})(typeof window=="object"?window:exports)}});var require_dayjs_min=__commonJS({"node_modules/dayjs/dayjs.min.js"(exports,module){(function(t,e){typeof exports=="object"&&typeof module<"u"?module.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self).dayjs=e()})(exports,function(){"use strict";var t=1e3,e=6e4,n2=36e5,r="millisecond",i="second",s2="minute",u="hour",a="day",o="week",c="month",f="quarter",h="year",d="date",l2="Invalid Date",$=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t2){var e2=["th","st","nd","rd"],n3=t2%100;return"["+t2+(e2[(n3-20)%10]||e2[n3]||e2[0])+"]"}},m=function(t2,e2,n3){var r2=String(t2);return!r2||r2.length>=e2?t2:""+Array(e2+1-r2.length).join(n3)+t2},v={s:m,z:function(t2){var e2=-t2.utcOffset(),n3=Math.abs(e2),r2=Math.floor(n3/60),i2=n3%60;return(e2<=0?"+":"-")+m(r2,2,"0")+":"+m(i2,2,"0")},m:function t2(e2,n3){if(e2.date()<n3.date())return-t2(n3,e2);var r2=12*(n3.year()-e2.year())+(n3.month()-e2.month()),i2=e2.clone().add(r2,c),s3=n3-i2<0,u2=e2.clone().add(r2+(s3?-1:1),c);return+(-(r2+(n3-i2)/(s3?i2-u2:u2-i2))||0)},a:function(t2){return t2<0?Math.ceil(t2)||0:Math.floor(t2)},p:function(t2){return{M:c,y:h,w:o,d:a,D:d,h:u,m:s2,s:i,ms:r,Q:f}[t2]||String(t2||"").toLowerCase().replace(/s$/,"")},u:function(t2){return t2===void 0}},g="en",D={};D[g]=M;var p="$isDayjsObject",S=function(t2){return t2 instanceof _||!(!t2||!t2[p])},w=function t2(e2,n3,r2){var i2;if(!e2)return g;if(typeof e2=="string"){var s3=e2.toLowerCase();D[s3]&&(i2=s3),n3&&(D[s3]=n3,i2=s3);var u2=e2.split("-");if(!i2&&u2.length>1)return t2(u2[0])}else{var a2=e2.name;D[a2]=e2,i2=a2}return!r2&&i2&&(g=i2),i2||!r2&&g},O=function(t2,e2){if(S(t2))return t2.clone();var n3=typeof e2=="object"?e2:{};return n3.date=t2,n3.args=arguments,new _(n3)},b=v;b.l=w,b.i=S,b.w=function(t2,e2){return O(t2,{locale:e2.$L,utc:e2.$u,x:e2.$x,$offset:e2.$offset})};var _=(function(){function M2(t2){this.$L=w(t2.locale,null,!0),this.parse(t2),this.$x=this.$x||t2.x||{},this[p]=!0}var m2=M2.prototype;return m2.parse=function(t2){this.$d=(function(t3){var e2=t3.date,n3=t3.utc;if(e2===null)return new Date(NaN);if(b.u(e2))return new Date;if(e2 instanceof Date)return new Date(e2);if(typeof e2=="string"&&!/Z$/i.test(e2)){var r2=e2.match($);if(r2){var i2=r2[2]-1||0,s3=(r2[7]||"0").substring(0,3);return n3?new Date(Date.UTC(r2[1],i2,r2[3]||1,r2[4]||0,r2[5]||0,r2[6]||0,s3)):new Date(r2[1],i2,r2[3]||1,r2[4]||0,r2[5]||0,r2[6]||0,s3)}}return new Date(e2)})(t2),this.init()},m2.init=function(){var t2=this.$d;this.$y=t2.getFullYear(),this.$M=t2.getMonth(),this.$D=t2.getDate(),this.$W=t2.getDay(),this.$H=t2.getHours(),this.$m=t2.getMinutes(),this.$s=t2.getSeconds(),this.$ms=t2.getMilliseconds()},m2.$utils=function(){return b},m2.isValid=function(){return this.$d.toString()!==l2},m2.isSame=function(t2,e2){var n3=O(t2);return this.startOf(e2)<=n3&&n3<=this.endOf(e2)},m2.isAfter=function(t2,e2){return O(t2)<this.startOf(e2)},m2.isBefore=function(t2,e2){return this.endOf(e2)<O(t2)},m2.$g=function(t2,e2,n3){return b.u(t2)?this[e2]:this.set(n3,t2)},m2.unix=function(){return Math.floor(this.valueOf()/1e3)},m2.valueOf=function(){return this.$d.getTime()},m2.startOf=function(t2,e2){var n3=this,r2=!!b.u(e2)||e2,f2=b.p(t2),l3=function(t3,e3){var i2=b.w(n3.$u?Date.UTC(n3.$y,e3,t3):new Date(n3.$y,e3,t3),n3);return r2?i2:i2.endOf(a)},$2=function(t3,e3){return b.w(n3.toDate()[t3].apply(n3.toDate("s"),(r2?[0,0,0,0]:[23,59,59,999]).slice(e3)),n3)},y2=this.$W,M3=this.$M,m3=this.$D,v2="set"+(this.$u?"UTC":"");switch(f2){case h:return r2?l3(1,0):l3(31,11);case c:return r2?l3(1,M3):l3(0,M3+1);case o:var g2=this.$locale().weekStart||0,D2=(y2<g2?y2+7:y2)-g2;return l3(r2?m3-D2:m3+(6-D2),M3);case a:case d:return $2(v2+"Hours",0);case u:return $2(v2+"Minutes",1);case s2:return $2(v2+"Seconds",2);case i:return $2(v2+"Milliseconds",3);default:return this.clone()}},m2.endOf=function(t2){return this.startOf(t2,!1)},m2.$set=function(t2,e2){var n3,o2=b.p(t2),f2="set"+(this.$u?"UTC":""),l3=(n3={},n3[a]=f2+"Date",n3[d]=f2+"Date",n3[c]=f2+"Month",n3[h]=f2+"FullYear",n3[u]=f2+"Hours",n3[s2]=f2+"Minutes",n3[i]=f2+"Seconds",n3[r]=f2+"Milliseconds",n3)[o2],$2=o2===a?this.$D+(e2-this.$W):e2;if(o2===c||o2===h){var y2=this.clone().set(d,1);y2.$d[l3]($2),y2.init(),this.$d=y2.set(d,Math.min(this.$D,y2.daysInMonth())).$d}else l3&&this.$d[l3]($2);return this.init(),this},m2.set=function(t2,e2){return this.clone().$set(t2,e2)},m2.get=function(t2){return this[b.p(t2)]()},m2.add=function(r2,f2){var d2,l3=this;r2=Number(r2);var $2=b.p(f2),y2=function(t2){var e2=O(l3);return b.w(e2.date(e2.date()+Math.round(t2*r2)),l3)};if($2===c)return this.set(c,this.$M+r2);if($2===h)return this.set(h,this.$y+r2);if($2===a)return y2(1);if($2===o)return y2(7);var M3=(d2={},d2[s2]=e,d2[u]=n2,d2[i]=t,d2)[$2]||1,m3=this.$d.getTime()+r2*M3;return b.w(m3,this)},m2.subtract=function(t2,e2){return this.add(-1*t2,e2)},m2.format=function(t2){var e2=this,n3=this.$locale();if(!this.isValid())return n3.invalidDate||l2;var r2=t2||"YYYY-MM-DDTHH:mm:ssZ",i2=b.z(this),s3=this.$H,u2=this.$m,a2=this.$M,o2=n3.weekdays,c2=n3.months,f2=n3.meridiem,h2=function(t3,n4,i3,s4){return t3&&(t3[n4]||t3(e2,r2))||i3[n4].slice(0,s4)},d2=function(t3){return b.s(s3%12||12,t3,"0")},$2=f2||function(t3,e3,n4){var r3=t3<12?"AM":"PM";return n4?r3.toLowerCase():r3};return r2.replace(y,function(t3,r3){return r3||(function(t4){switch(t4){case"YY":return String(e2.$y).slice(-2);case"YYYY":return b.s(e2.$y,4,"0");case"M":return a2+1;case"MM":return b.s(a2+1,2,"0");case"MMM":return h2(n3.monthsShort,a2,c2,3);case"MMMM":return h2(c2,a2);case"D":return e2.$D;case"DD":return b.s(e2.$D,2,"0");case"d":return String(e2.$W);case"dd":return h2(n3.weekdaysMin,e2.$W,o2,2);case"ddd":return h2(n3.weekdaysShort,e2.$W,o2,3);case"dddd":return o2[e2.$W];case"H":return String(s3);case"HH":return b.s(s3,2,"0");case"h":return d2(1);case"hh":return d2(2);case"a":return $2(s3,u2,!0);case"A":return $2(s3,u2,!1);case"m":return String(u2);case"mm":return b.s(u2,2,"0");case"s":return String(e2.$s);case"ss":return b.s(e2.$s,2,"0");case"SSS":return b.s(e2.$ms,3,"0");case"Z":return i2}return null})(t3)||i2.replace(":","")})},m2.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m2.diff=function(r2,d2,l3){var $2,y2=this,M3=b.p(d2),m3=O(r2),v2=(m3.utcOffset()-this.utcOffset())*e,g2=this-m3,D2=function(){return b.m(y2,m3)};switch(M3){case h:$2=D2()/12;break;case c:$2=D2();break;case f:$2=D2()/3;break;case o:$2=(g2-v2)/6048e5;break;case a:$2=(g2-v2)/864e5;break;case u:$2=g2/n2;break;case s2:$2=g2/e;break;case i:$2=g2/t;break;default:$2=g2}return l3?$2:b.a($2)},m2.daysInMonth=function(){return this.endOf(c).$D},m2.$locale=function(){return D[this.$L]},m2.locale=function(t2,e2){if(!t2)return this.$L;var n3=this.clone(),r2=w(t2,e2,!0);return r2&&(n3.$L=r2),n3},m2.clone=function(){return b.w(this.$d,this)},m2.toDate=function(){return new Date(this.valueOf())},m2.toJSON=function(){return this.isValid()?this.toISOString():null},m2.toISOString=function(){return this.$d.toISOString()},m2.toString=function(){return this.$d.toUTCString()},M2})(),k=_.prototype;return O.prototype=k,[["$ms",r],["$s",i],["$m",s2],["$H",u],["$W",a],["$M",c],["$y",h],["$D",d]].forEach(function(t2){k[t2[1]]=function(e2){return this.$g(e2,t2[0],t2[1])}}),O.extend=function(t2,e2){return t2.$i||(t2(e2,_,O),t2.$i=!0),O},O.locale=w,O.isDayjs=S,O.unix=function(t2){return O(1e3*t2)},O.en=D[g],O.Ls=D,O.p={},O})}});var require_localeData=__commonJS({"node_modules/dayjs/plugin/localeData.js"(exports,module){(function(n2,e){typeof exports=="object"&&typeof module<"u"?module.exports=e():typeof define=="function"&&define.amd?define(e):(n2=typeof globalThis<"u"?globalThis:n2||self).dayjs_plugin_localeData=e()})(exports,function(){"use strict";return function(n2,e,t){var r=e.prototype,o=function(n3){return n3&&(n3.indexOf?n3:n3.s)},u=function(n3,e2,t2,r2,u2){var i2=n3.name?n3:n3.$locale(),a2=o(i2[e2]),s3=o(i2[t2]),f=a2||s3.map(function(n4){return n4.slice(0,r2)});if(!u2)return f;var d=i2.weekStart;return f.map(function(n4,e3){return f[(e3+(d||0))%7]})},i=function(){return t.Ls[t.locale()]},a=function(n3,e2){return n3.formats[e2]||(function(n4){return n4.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(n5,e3,t2){return e3||t2.slice(1)})})(n3.formats[e2.toUpperCase()])},s2=function(){var n3=this;return{months:function(e2){return e2?e2.format("MMMM"):u(n3,"months")},monthsShort:function(e2){return e2?e2.format("MMM"):u(n3,"monthsShort","months",3)},firstDayOfWeek:function(){return n3.$locale().weekStart||0},weekdays:function(e2){return e2?e2.format("dddd"):u(n3,"weekdays")},weekdaysMin:function(e2){return e2?e2.format("dd"):u(n3,"weekdaysMin","weekdays",2)},weekdaysShort:function(e2){return e2?e2.format("ddd"):u(n3,"weekdaysShort","weekdays",3)},longDateFormat:function(e2){return a(n3.$locale(),e2)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};r.localeData=function(){return s2.bind(this)()},t.localeData=function(){var n3=i();return{firstDayOfWeek:function(){return n3.weekStart||0},weekdays:function(){return t.weekdays()},weekdaysShort:function(){return t.weekdaysShort()},weekdaysMin:function(){return t.weekdaysMin()},months:function(){return t.months()},monthsShort:function(){return t.monthsShort()},longDateFormat:function(e2){return a(n3,e2)},meridiem:n3.meridiem,ordinal:n3.ordinal}},t.months=function(){return u(i(),"months")},t.monthsShort=function(){return u(i(),"monthsShort","months",3)},t.weekdays=function(n3){return u(i(),"weekdays",null,null,n3)},t.weekdaysShort=function(n3){return u(i(),"weekdaysShort","weekdays",3,n3)},t.weekdaysMin=function(n3){return u(i(),"weekdaysMin","weekdays",2,n3)}}})}});var require_localizedFormat=__commonJS({"node_modules/dayjs/plugin/localizedFormat.js"(exports,module){(function(e,t){typeof exports=="object"&&typeof module<"u"?module.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_localizedFormat=t()})(exports,function(){"use strict";var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(t,o,n2){var r=o.prototype,i=r.format;n2.en.formats=e,r.format=function(t2){t2===void 0&&(t2="YYYY-MM-DDTHH:mm:ssZ");var o2=this.$locale().formats,n3=(function(t3,o3){return t3.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(t4,n4,r2){var i2=r2&&r2.toUpperCase();return n4||o3[r2]||e[r2]||o3[i2].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(e2,t5,o4){return t5||o4.slice(1)})})})(t2,o2===void 0?{}:o2);return i.call(this,n3)}}})}});var require_isoWeek=__commonJS({"node_modules/dayjs/plugin/isoWeek.js"(exports,module){(function(e,t){typeof exports=="object"&&typeof module<"u"?module.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_isoWeek=t()})(exports,function(){"use strict";var e="day";return function(t,i,s2){var a=function(t2){return t2.add(4-t2.isoWeekday(),e)},d=i.prototype;d.isoWeekYear=function(){return a(this).year()},d.isoWeek=function(t2){if(!this.$utils().u(t2))return this.add(7*(t2-this.isoWeek()),e);var i2,d2,n3,o,r=a(this),u=(i2=this.isoWeekYear(),d2=this.$u,n3=(d2?s2.utc:s2)().year(i2).startOf("year"),o=4-n3.isoWeekday(),n3.isoWeekday()>4&&(o+=7),n3.add(o,e));return r.diff(u,"week")+1},d.isoWeekday=function(e2){return this.$utils().u(e2)?this.day()||7:this.day(this.day()%7?e2:e2-7)};var n2=d.startOf;d.startOf=function(e2,t2){var i2=this.$utils(),s3=!!i2.u(t2)||t2;return i2.p(e2)==="isoweek"?s3?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):n2.bind(this)(e2,t2)}}})}});var require_weekOfYear=__commonJS({"node_modules/dayjs/plugin/weekOfYear.js"(exports,module){(function(e,t){typeof exports=="object"&&typeof module<"u"?module.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_weekOfYear=t()})(exports,function(){"use strict";var e="week",t="year";return function(i,n2,r){var f=n2.prototype;f.week=function(i2){if(i2===void 0&&(i2=null),i2!==null)return this.add(7*(i2-this.week()),"day");var n3=this.$locale().yearStart||1;if(this.month()===11&&this.date()>25){var f2=r(this).startOf(t).add(1,t).date(n3),s2=r(this).endOf(e);if(f2.isBefore(s2))return 1}var a=r(this).startOf(t).date(n3).startOf(e).subtract(1,"millisecond"),o=this.diff(a,e,!0);return o<0?r(this).startOf("week").week():Math.ceil(o)},f.weeks=function(e2){return e2===void 0&&(e2=null),this.week(e2)}}})}});var require_customParseFormat=__commonJS({"node_modules/dayjs/plugin/customParseFormat.js"(exports,module){(function(e,t){typeof exports=="object"&&typeof module<"u"?module.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self).dayjs_plugin_customParseFormat=t()})(exports,function(){"use strict";var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},t=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,n2=/\d/,r=/\d\d/,i=/\d\d?/,o=/\d*[^-_:/,()\s\d]+/,s2={},a=function(e2){return(e2=+e2)+(e2>68?1900:2e3)},f=function(e2){return function(t2){this[e2]=+t2}},h=[/[+-]\d\d:?(\d\d)?|Z/,function(e2){(this.zone||(this.zone={})).offset=(function(e3){if(!e3||e3==="Z")return 0;var t2=e3.match(/([+-]|\d\d)/g),n3=60*t2[1]+(+t2[2]||0);return n3===0?0:t2[0]==="+"?-n3:n3})(e2)}],u=function(e2){var t2=s2[e2];return t2&&(t2.indexOf?t2:t2.s.concat(t2.f))},d=function(e2,t2){var n3,r2=s2.meridiem;if(r2){for(var i2=1;i2<=24;i2+=1)if(e2.indexOf(r2(i2,0,t2))>-1){n3=i2>12;break}}else n3=e2===(t2?"pm":"PM");return n3},c={A:[o,function(e2){this.afternoon=d(e2,!1)}],a:[o,function(e2){this.afternoon=d(e2,!0)}],Q:[n2,function(e2){this.month=3*(e2-1)+1}],S:[n2,function(e2){this.milliseconds=100*+e2}],SS:[r,function(e2){this.milliseconds=10*+e2}],SSS:[/\d{3}/,function(e2){this.milliseconds=+e2}],s:[i,f("seconds")],ss:[i,f("seconds")],m:[i,f("minutes")],mm:[i,f("minutes")],H:[i,f("hours")],h:[i,f("hours")],HH:[i,f("hours")],hh:[i,f("hours")],D:[i,f("day")],DD:[r,f("day")],Do:[o,function(e2){var t2=s2.ordinal,n3=e2.match(/\d+/);if(this.day=n3[0],t2)for(var r2=1;r2<=31;r2+=1)t2(r2).replace(/\[|\]/g,"")===e2&&(this.day=r2)}],w:[i,f("week")],ww:[r,f("week")],M:[i,f("month")],MM:[r,f("month")],MMM:[o,function(e2){var t2=u("months"),n3=(u("monthsShort")||t2.map(function(e3){return e3.slice(0,3)})).indexOf(e2)+1;if(n3<1)throw new Error;this.month=n3%12||n3}],MMMM:[o,function(e2){var t2=u("months").indexOf(e2)+1;if(t2<1)throw new Error;this.month=t2%12||t2}],Y:[/[+-]?\d+/,f("year")],YY:[r,function(e2){this.year=a(e2)}],YYYY:[/\d{4}/,f("year")],Z:h,ZZ:h};function l2(n3){var r2,i2;r2=n3,i2=s2&&s2.formats;for(var o2=(n3=r2.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(t2,n4,r3){var o3=r3&&r3.toUpperCase();return n4||i2[r3]||e[r3]||i2[o3].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(e2,t3,n5){return t3||n5.slice(1)})})).match(t),a2=o2.length,f2=0;f2<a2;f2+=1){var h2=o2[f2],u2=c[h2],d2=u2&&u2[0],l3=u2&&u2[1];o2[f2]=l3?{regex:d2,parser:l3}:h2.replace(/^\[|\]$/g,"")}return function(e2){for(var t2={},n4=0,r3=0;n4<a2;n4+=1){var i3=o2[n4];if(typeof i3=="string")r3+=i3.length;else{var s3=i3.regex,f3=i3.parser,h3=e2.slice(r3),u3=s3.exec(h3)[0];f3.call(t2,u3),e2=e2.replace(u3,"")}}return(function(e3){var t3=e3.afternoon;if(t3!==void 0){var n5=e3.hours;t3?n5<12&&(e3.hours+=12):n5===12&&(e3.hours=0),delete e3.afternoon}})(t2),t2}}return function(e2,t2,n3){n3.p.customParseFormat=!0,e2&&e2.parseTwoDigitYear&&(a=e2.parseTwoDigitYear);var r2=t2.prototype,i2=r2.parse;r2.parse=function(e3){var t3=e3.date,r3=e3.utc,o2=e3.args;this.$u=r3;var a2=o2[1];if(typeof a2=="string"){var f2=o2[2]===!0,h2=o2[3]===!0,u2=f2||h2,d2=o2[2];h2&&(d2=o2[2]),s2=this.$locale(),!f2&&d2&&(s2=n3.Ls[d2]),this.$d=(function(e4,t4,n4,r4){try{if(["x","X"].indexOf(t4)>-1)return new Date((t4==="X"?1e3:1)*e4);var i3=l2(t4)(e4),o3=i3.year,s3=i3.month,a3=i3.day,f3=i3.hours,h3=i3.minutes,u3=i3.seconds,d3=i3.milliseconds,c3=i3.zone,m2=i3.week,M2=new Date,Y=a3||(o3||s3?1:M2.getDate()),p=o3||M2.getFullYear(),v=0;o3&&!s3||(v=s3>0?s3-1:M2.getMonth());var D,w=f3||0,g=h3||0,y=u3||0,L=d3||0;return c3?new Date(Date.UTC(p,v,Y,w,g,y,L+60*c3.offset*1e3)):n4?new Date(Date.UTC(p,v,Y,w,g,y,L)):(D=new Date(p,v,Y,w,g,y,L),m2&&(D=r4(D).week(m2).toDate()),D)}catch{return new Date("")}})(t3,a2,r3,n3),this.init(),d2&&d2!==!0&&(this.$L=this.locale(d2).$L),u2&&t3!=this.format(a2)&&(this.$d=new Date("")),s2={}}else if(a2 instanceof Array)for(var c2=a2.length,m=1;m<=c2;m+=1){o2[1]=a2[m-1];var M=n3.apply(this,o2);if(M.isValid()){this.$d=M.$d,this.$L=M.$L,this.init();break}m===c2&&(this.$d=new Date(""))}else i2.call(this,e3)}}})}});var require_formats=__commonJS({"node_modules/lorem-ipsum/dist/constants/formats.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.FORMAT_PLAIN=exports.FORMAT_HTML=exports.FORMATS=void 0;var FORMAT_HTML="html";exports.FORMAT_HTML=FORMAT_HTML;var FORMAT_PLAIN="plain";exports.FORMAT_PLAIN=FORMAT_PLAIN;var FORMATS=[FORMAT_HTML,FORMAT_PLAIN];exports.FORMATS=FORMATS}});var require_units=__commonJS({"node_modules/lorem-ipsum/dist/constants/units.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.UNIT_WORDS=exports.UNIT_WORD=exports.UNIT_SENTENCES=exports.UNIT_SENTENCE=exports.UNIT_PARAGRAPHS=exports.UNIT_PARAGRAPH=exports.UNITS=void 0;var UNIT_WORDS="words";exports.UNIT_WORDS=UNIT_WORDS;var UNIT_WORD="word";exports.UNIT_WORD=UNIT_WORD;var UNIT_SENTENCES="sentences";exports.UNIT_SENTENCES=UNIT_SENTENCES;var UNIT_SENTENCE="sentence";exports.UNIT_SENTENCE=UNIT_SENTENCE;var UNIT_PARAGRAPHS="paragraphs";exports.UNIT_PARAGRAPHS=UNIT_PARAGRAPHS;var UNIT_PARAGRAPH="paragraph";exports.UNIT_PARAGRAPH=UNIT_PARAGRAPH;var UNITS=[UNIT_WORDS,UNIT_WORD,UNIT_SENTENCES,UNIT_SENTENCE,UNIT_PARAGRAPHS,UNIT_PARAGRAPH];exports.UNITS=UNITS}});var require_words=__commonJS({"node_modules/lorem-ipsum/dist/constants/words.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.WORDS=void 0;var WORDS=["ad","adipisicing","aliqua","aliquip","amet","anim","aute","cillum","commodo","consectetur","consequat","culpa","cupidatat","deserunt","do","dolor","dolore","duis","ea","eiusmod","elit","enim","esse","est","et","eu","ex","excepteur","exercitation","fugiat","id","in","incididunt","ipsum","irure","labore","laboris","laborum","Lorem","magna","minim","mollit","nisi","non","nostrud","nulla","occaecat","officia","pariatur","proident","qui","quis","reprehenderit","sint","sit","sunt","tempor","ullamco","ut","velit","veniam","voluptate"];exports.WORDS=WORDS}});var require_lineEndings=__commonJS({"node_modules/lorem-ipsum/dist/constants/lineEndings.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.LINE_ENDINGS=void 0;var LINE_ENDINGS={POSIX:`
2
2
  `,WIN32:`\r
3
3
  `};exports.LINE_ENDINGS=LINE_ENDINGS}});var require_capitalize=__commonJS({"node_modules/lorem-ipsum/dist/util/capitalize.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var capitalize=function(str){var trimmed=str.trim();return trimmed.charAt(0).toUpperCase()+trimmed.slice(1)},_default=capitalize;exports.default=_default}});var require_isNode=__commonJS({"node_modules/lorem-ipsum/dist/util/isNode.js"(exports,module){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var isNode2=function(){return typeof module<"u"&&!!module.exports},_default=isNode2;exports.default=_default}});var require_isReactNative=__commonJS({"node_modules/lorem-ipsum/dist/util/isReactNative.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var isReactNative=function(){var isReactNativeResult=!1;try{isReactNativeResult=navigator.product==="ReactNative"}catch{isReactNativeResult=!1}return isReactNativeResult},_default=isReactNative;exports.default=_default}});var require_platforms=__commonJS({"node_modules/lorem-ipsum/dist/constants/platforms.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.SUPPORTED_PLATFORMS=void 0;var SUPPORTED_PLATFORMS={DARWIN:"darwin",LINUX:"linux",WIN32:"win32"};exports.SUPPORTED_PLATFORMS=SUPPORTED_PLATFORMS}});var require_isWindows=__commonJS({"node_modules/lorem-ipsum/dist/util/isWindows.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _platforms=require_platforms(),isWindows=function(){var isWindowsResult=!1;try{isWindowsResult=process.platform===_platforms.SUPPORTED_PLATFORMS.WIN32}catch{isWindowsResult=!1}return isWindowsResult},_default=isWindows;exports.default=_default}});var require_makeArrayOfLength=__commonJS({"node_modules/lorem-ipsum/dist/util/makeArrayOfLength.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var makeArrayOfLength=function(){var length=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;return Array.apply(null,Array(length)).map(function(item,index){return index})},_default=makeArrayOfLength;exports.default=_default}});var require_makeArrayOfStrings=__commonJS({"node_modules/lorem-ipsum/dist/util/makeArrayOfStrings.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _makeArrayOfLength=_interopRequireDefault(require_makeArrayOfLength());function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var makeArrayOfStrings=function(length,makeString){var arr=(0,_makeArrayOfLength.default)(length);return arr.map(function(){return makeString()})},_default=makeArrayOfStrings;exports.default=_default}});var require_util=__commonJS({"node_modules/lorem-ipsum/dist/util/index.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});Object.defineProperty(exports,"capitalize",{enumerable:!0,get:function(){return _capitalize.default}});Object.defineProperty(exports,"isNode",{enumerable:!0,get:function(){return _isNode.default}});Object.defineProperty(exports,"isReactNative",{enumerable:!0,get:function(){return _isReactNative.default}});Object.defineProperty(exports,"isWindows",{enumerable:!0,get:function(){return _isWindows.default}});Object.defineProperty(exports,"makeArrayOfLength",{enumerable:!0,get:function(){return _makeArrayOfLength.default}});Object.defineProperty(exports,"makeArrayOfStrings",{enumerable:!0,get:function(){return _makeArrayOfStrings.default}});var _capitalize=_interopRequireDefault(require_capitalize()),_isNode=_interopRequireDefault(require_isNode()),_isReactNative=_interopRequireDefault(require_isReactNative()),_isWindows=_interopRequireDefault(require_isWindows()),_makeArrayOfLength=_interopRequireDefault(require_makeArrayOfLength()),_makeArrayOfStrings=_interopRequireDefault(require_makeArrayOfStrings());function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}}});var require_generator=__commonJS({"node_modules/lorem-ipsum/dist/lib/generator.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _words=require_words(),_util=require_util();function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props2){for(var i=0;i<props2.length;i++){var descriptor=props2[i];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Object.defineProperty(Constructor,"prototype",{writable:!1}),Constructor}function _defineProperty(obj,key,value){return key in obj?Object.defineProperty(obj,key,{value,enumerable:!0,configurable:!0,writable:!0}):obj[key]=value,obj}var Generator=(function(){function Generator2(){var _ref=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},_ref$sentencesPerPara=_ref.sentencesPerParagraph,sentencesPerParagraph=_ref$sentencesPerPara===void 0?{max:7,min:3}:_ref$sentencesPerPara,_ref$wordsPerSentence=_ref.wordsPerSentence,wordsPerSentence=_ref$wordsPerSentence===void 0?{max:15,min:5}:_ref$wordsPerSentence,random3=_ref.random,seed=_ref.seed,_ref$words=_ref.words,words=_ref$words===void 0?_words.WORDS:_ref$words;if(_classCallCheck(this,Generator2),_defineProperty(this,"sentencesPerParagraph",void 0),_defineProperty(this,"wordsPerSentence",void 0),_defineProperty(this,"random",void 0),_defineProperty(this,"words",void 0),sentencesPerParagraph.min>sentencesPerParagraph.max)throw new Error("Minimum number of sentences per paragraph (".concat(sentencesPerParagraph.min,") cannot exceed maximum (").concat(sentencesPerParagraph.max,")."));if(wordsPerSentence.min>wordsPerSentence.max)throw new Error("Minimum number of words per sentence (".concat(wordsPerSentence.min,") cannot exceed maximum (").concat(wordsPerSentence.max,")."));this.sentencesPerParagraph=sentencesPerParagraph,this.words=words,this.wordsPerSentence=wordsPerSentence,this.random=random3||Math.random}return _createClass(Generator2,[{key:"generateRandomInteger",value:function(min2,max2){return Math.floor(this.random()*(max2-min2+1)+min2)}},{key:"generateRandomWords",value:function(num){var _this=this,_this$wordsPerSentenc=this.wordsPerSentence,min2=_this$wordsPerSentenc.min,max2=_this$wordsPerSentenc.max,length=num||this.generateRandomInteger(min2,max2);return(0,_util.makeArrayOfLength)(length).reduce(function(accumulator,index){return"".concat(_this.pluckRandomWord()," ").concat(accumulator)},"").trim()}},{key:"generateRandomSentence",value:function(num){return"".concat((0,_util.capitalize)(this.generateRandomWords(num)),".")}},{key:"generateRandomParagraph",value:function(num){var _this2=this,_this$sentencesPerPar=this.sentencesPerParagraph,min2=_this$sentencesPerPar.min,max2=_this$sentencesPerPar.max,length=num||this.generateRandomInteger(min2,max2);return(0,_util.makeArrayOfLength)(length).reduce(function(accumulator,index){return"".concat(_this2.generateRandomSentence()," ").concat(accumulator)},"").trim()}},{key:"pluckRandomWord",value:function(){var min2=0,max2=this.words.length-1,index=this.generateRandomInteger(min2,max2);return this.words[index]}}]),Generator2})(),_default=Generator;exports.default=_default}});var require_LoremIpsum=__commonJS({"node_modules/lorem-ipsum/dist/lib/LoremIpsum.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _formats=require_formats(),_lineEndings=require_lineEndings(),_generator=_interopRequireDefault(require_generator()),_util=require_util();function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props2){for(var i=0;i<props2.length;i++){var descriptor=props2[i];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Object.defineProperty(Constructor,"prototype",{writable:!1}),Constructor}function _defineProperty(obj,key,value){return key in obj?Object.defineProperty(obj,key,{value,enumerable:!0,configurable:!0,writable:!0}):obj[key]=value,obj}var LoremIpsum2=(function(){function LoremIpsum3(){var options=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},format2=arguments.length>1&&arguments[1]!==void 0?arguments[1]:_formats.FORMAT_PLAIN,suffix=arguments.length>2?arguments[2]:void 0;if(_classCallCheck(this,LoremIpsum3),this.format=format2,this.suffix=suffix,_defineProperty(this,"generator",void 0),_formats.FORMATS.indexOf(format2.toLowerCase())===-1)throw new Error("".concat(format2," is an invalid format. Please use ").concat(_formats.FORMATS.join(" or "),"."));this.generator=new _generator.default(options)}return _createClass(LoremIpsum3,[{key:"getLineEnding",value:function(){return this.suffix?this.suffix:!(0,_util.isReactNative)()&&(0,_util.isNode)()&&(0,_util.isWindows)()?_lineEndings.LINE_ENDINGS.WIN32:_lineEndings.LINE_ENDINGS.POSIX}},{key:"formatString",value:function(str){return this.format===_formats.FORMAT_HTML?"<p>".concat(str,"</p>"):str}},{key:"formatStrings",value:function(strings){var _this=this;return strings.map(function(str){return _this.formatString(str)})}},{key:"generateWords",value:function(num){return this.formatString(this.generator.generateRandomWords(num))}},{key:"generateSentences",value:function(num){return this.formatString(this.generator.generateRandomParagraph(num))}},{key:"generateParagraphs",value:function(num){var makeString=this.generator.generateRandomParagraph.bind(this.generator);return this.formatStrings((0,_util.makeArrayOfStrings)(num,makeString)).join(this.getLineEnding())}}]),LoremIpsum3})(),_default=LoremIpsum2;exports.default=_default}});var require_dist=__commonJS({"node_modules/lorem-ipsum/dist/index.js"(exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});Object.defineProperty(exports,"LoremIpsum",{enumerable:!0,get:function(){return _LoremIpsum.default}});exports.loremIpsum=void 0;var _formats=require_formats(),_units=require_units(),_words=require_words(),_LoremIpsum=_interopRequireDefault(require_LoremIpsum());function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var loremIpsum=function(){var _ref=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},_ref$count=_ref.count,count=_ref$count===void 0?1:_ref$count,_ref$format=_ref.format,format2=_ref$format===void 0?_formats.FORMAT_PLAIN:_ref$format,_ref$paragraphLowerBo=_ref.paragraphLowerBound,paragraphLowerBound=_ref$paragraphLowerBo===void 0?3:_ref$paragraphLowerBo,_ref$paragraphUpperBo=_ref.paragraphUpperBound,paragraphUpperBound=_ref$paragraphUpperBo===void 0?7:_ref$paragraphUpperBo,random3=_ref.random,_ref$sentenceLowerBou=_ref.sentenceLowerBound,sentenceLowerBound=_ref$sentenceLowerBou===void 0?5:_ref$sentenceLowerBou,_ref$sentenceUpperBou=_ref.sentenceUpperBound,sentenceUpperBound=_ref$sentenceUpperBou===void 0?15:_ref$sentenceUpperBou,_ref$units=_ref.units,units=_ref$units===void 0?_units.UNIT_SENTENCES:_ref$units,_ref$words=_ref.words,words=_ref$words===void 0?_words.WORDS:_ref$words,_ref$suffix=_ref.suffix,suffix=_ref$suffix===void 0?"":_ref$suffix,options={random:random3,sentencesPerParagraph:{max:paragraphUpperBound,min:paragraphLowerBound},words,wordsPerSentence:{max:sentenceUpperBound,min:sentenceLowerBound}},lorem=new _LoremIpsum.default(options,format2,suffix);switch(units){case _units.UNIT_PARAGRAPHS:case _units.UNIT_PARAGRAPH:return lorem.generateParagraphs(count);case _units.UNIT_SENTENCES:case _units.UNIT_SENTENCE:return lorem.generateSentences(count);case _units.UNIT_WORDS:case _units.UNIT_WORD:return lorem.generateWords(count);default:return""}};exports.loremIpsum=loremIpsum}});var require_papaparse_min=__commonJS({"node_modules/papaparse/papaparse.min.js"(exports,module){((e,t)=>{typeof define=="function"&&define.amd?define([],t):typeof module=="object"&&typeof exports<"u"?module.exports=t():e.Papa=t()})(exports,function r(){var n2=typeof self<"u"?self:typeof window<"u"?window:n2!==void 0?n2:{},d,s2=!n2.document&&!!n2.postMessage,a=n2.IS_PAPA_WORKER||!1,o={},h=0,v={};function u(e){this._handle=null,this._finished=!1,this._completed=!1,this._halted=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this.isFirstChunk=!0,this._completeResults={data:[],errors:[],meta:{}},function(e2){var t=b(e2);t.chunkSize=parseInt(t.chunkSize),e2.step||e2.chunk||(t.chunkSize=null),this._handle=new i(t),(this._handle.streamer=this)._config=t}.call(this,e),this.parseChunk=function(t,e2){var i2=parseInt(this._config.skipFirstNLines)||0;if(this.isFirstChunk&&0<i2){let e3=this._config.newline;e3||(r2=this._config.quoteChar||'"',e3=this._handle.guessLineEndings(t,r2)),t=[...t.split(e3).slice(i2)].join(e3)}this.isFirstChunk&&U(this._config.beforeFirstChunk)&&(r2=this._config.beforeFirstChunk(t))!==void 0&&(t=r2),this.isFirstChunk=!1,this._halted=!1;var i2=this._partialLine+t,r2=(this._partialLine="",this._handle.parse(i2,this._baseIndex,!this._finished));if(!this._handle.paused()&&!this._handle.aborted()){if(t=r2.meta.cursor,i2=(this._finished||(this._partialLine=i2.substring(t-this._baseIndex),this._baseIndex=t),r2&&r2.data&&(this._rowCount+=r2.data.length),this._finished||this._config.preview&&this._rowCount>=this._config.preview),a)n2.postMessage({results:r2,workerId:v.WORKER_ID,finished:i2});else if(U(this._config.chunk)&&!e2){if(this._config.chunk(r2,this._handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);this._completeResults=r2=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(r2.data),this._completeResults.errors=this._completeResults.errors.concat(r2.errors),this._completeResults.meta=r2.meta),this._completed||!i2||!U(this._config.complete)||r2&&r2.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=!0),i2||r2&&r2.meta.paused||this._nextChunk(),r2}this._halted=!0},this._sendError=function(e2){U(this._config.error)?this._config.error(e2):a&&this._config.error&&n2.postMessage({workerId:v.WORKER_ID,error:e2,finished:!1})}}function f(e){var r2;(e=e||{}).chunkSize||(e.chunkSize=v.RemoteChunkSize),u.call(this,e),this._nextChunk=s2?function(){this._readChunk(),this._chunkLoaded()}:function(){this._readChunk()},this.stream=function(e2){this._input=e2,this._nextChunk()},this._readChunk=function(){if(this._finished)this._chunkLoaded();else{if(r2=new XMLHttpRequest,this._config.withCredentials&&(r2.withCredentials=this._config.withCredentials),s2||(r2.onload=y(this._chunkLoaded,this),r2.onerror=y(this._chunkError,this)),r2.open(this._config.downloadRequestBody?"POST":"GET",this._input,!s2),this._config.downloadRequestHeaders){var e2,t=this._config.downloadRequestHeaders;for(e2 in t)r2.setRequestHeader(e2,t[e2])}var i2;this._config.chunkSize&&(i2=this._start+this._config.chunkSize-1,r2.setRequestHeader("Range","bytes="+this._start+"-"+i2));try{r2.send(this._config.downloadRequestBody)}catch(e3){this._chunkError(e3.message)}s2&&r2.status===0&&this._chunkError()}},this._chunkLoaded=function(){r2.readyState===4&&(r2.status<200||400<=r2.status?this._chunkError():(this._start+=this._config.chunkSize||r2.responseText.length,this._finished=!this._config.chunkSize||this._start>=(e2=>(e2=e2.getResponseHeader("Content-Range"))!==null?parseInt(e2.substring(e2.lastIndexOf("/")+1)):-1)(r2),this.parseChunk(r2.responseText)))},this._chunkError=function(e2){e2=r2.statusText||e2,this._sendError(new Error(e2))}}function l2(e){(e=e||{}).chunkSize||(e.chunkSize=v.LocalChunkSize),u.call(this,e);var i2,r2,n3=typeof FileReader<"u";this.stream=function(e2){this._input=e2,r2=e2.slice||e2.webkitSlice||e2.mozSlice,n3?((i2=new FileReader).onload=y(this._chunkLoaded,this),i2.onerror=y(this._chunkError,this)):i2=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var e2=this._input,t=(this._config.chunkSize&&(t=Math.min(this._start+this._config.chunkSize,this._input.size),e2=r2.call(e2,this._start,t)),i2.readAsText(e2,this._config.encoding));n3||this._chunkLoaded({target:{result:t}})},this._chunkLoaded=function(e2){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(e2.target.result)},this._chunkError=function(){this._sendError(i2.error)}}function c(e){var i2;u.call(this,e=e||{}),this.stream=function(e2){return i2=e2,this._nextChunk()},this._nextChunk=function(){var e2,t;if(!this._finished)return e2=this._config.chunkSize,i2=e2?(t=i2.substring(0,e2),i2.substring(e2)):(t=i2,""),this._finished=!i2,this.parseChunk(t)}}function p(e){u.call(this,e=e||{});var t=[],i2=!0,r2=!1;this.pause=function(){u.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){u.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(e2){this._input=e2,this._input.on("data",this._streamData),this._input.on("end",this._streamEnd),this._input.on("error",this._streamError)},this._checkIsFinished=function(){r2&&t.length===1&&(this._finished=!0)},this._nextChunk=function(){this._checkIsFinished(),t.length?this.parseChunk(t.shift()):i2=!0},this._streamData=y(function(e2){try{t.push(typeof e2=="string"?e2:e2.toString(this._config.encoding)),i2&&(i2=!1,this._checkIsFinished(),this.parseChunk(t.shift()))}catch(e3){this._streamError(e3)}},this),this._streamError=y(function(e2){this._streamCleanUp(),this._sendError(e2)},this),this._streamEnd=y(function(){this._streamCleanUp(),r2=!0,this._streamData("")},this),this._streamCleanUp=y(function(){this._input.removeListener("data",this._streamData),this._input.removeListener("end",this._streamEnd),this._input.removeListener("error",this._streamError)},this)}function i(m2){var n3,s3,a2,t,o2=Math.pow(2,53),h2=-o2,u2=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,d2=/^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/,i2=this,r2=0,f2=0,l3=!1,e=!1,c2=[],p2={data:[],errors:[],meta:{}};function y2(e2){return m2.skipEmptyLines==="greedy"?e2.join("").trim()==="":e2.length===1&&e2[0].length===0}function g2(){if(p2&&a2&&(k("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+v.DefaultDelimiter+"'"),a2=!1),m2.skipEmptyLines&&(p2.data=p2.data.filter(function(e3){return!y2(e3)})),_2()){let t3=function(e3,t4){U(m2.transformHeader)&&(e3=m2.transformHeader(e3,t4)),c2.push(e3)};var t2=t3;if(p2)if(Array.isArray(p2.data[0])){for(var e2=0;_2()&&e2<p2.data.length;e2++)p2.data[e2].forEach(t3);p2.data.splice(0,1)}else p2.data.forEach(t3)}function i3(e3,t3){for(var i4=m2.header?{}:[],r4=0;r4<e3.length;r4++){var n4=r4,s4=e3[r4],s4=((e4,t4)=>(e5=>(m2.dynamicTypingFunction&&m2.dynamicTyping[e5]===void 0&&(m2.dynamicTyping[e5]=m2.dynamicTypingFunction(e5)),(m2.dynamicTyping[e5]||m2.dynamicTyping)===!0))(e4)?t4==="true"||t4==="TRUE"||t4!=="false"&&t4!=="FALSE"&&((e5=>{if(u2.test(e5)&&(e5=parseFloat(e5),h2<e5&&e5<o2))return 1})(t4)?parseFloat(t4):d2.test(t4)?new Date(t4):t4===""?null:t4):t4)(n4=m2.header?r4>=c2.length?"__parsed_extra":c2[r4]:n4,s4=m2.transform?m2.transform(s4,n4):s4);n4==="__parsed_extra"?(i4[n4]=i4[n4]||[],i4[n4].push(s4)):i4[n4]=s4}return m2.header&&(r4>c2.length?k("FieldMismatch","TooManyFields","Too many fields: expected "+c2.length+" fields but parsed "+r4,f2+t3):r4<c2.length&&k("FieldMismatch","TooFewFields","Too few fields: expected "+c2.length+" fields but parsed "+r4,f2+t3)),i4}var r3;p2&&(m2.header||m2.dynamicTyping||m2.transform)&&(r3=1,!p2.data.length||Array.isArray(p2.data[0])?(p2.data=p2.data.map(i3),r3=p2.data.length):p2.data=i3(p2.data,0),m2.header&&p2.meta&&(p2.meta.fields=c2),f2+=r3)}function _2(){return m2.header&&c2.length===0}function k(e2,t2,i3,r3){e2={type:e2,code:t2,message:i3},r3!==void 0&&(e2.row=r3),p2.errors.push(e2)}U(m2.step)&&(t=m2.step,m2.step=function(e2){p2=e2,_2()?g2():(g2(),p2.data.length!==0&&(r2+=e2.data.length,m2.preview&&r2>m2.preview?s3.abort():(p2.data=p2.data[0],t(p2,i2))))}),this.parse=function(e2,t2,i3){var r3=m2.quoteChar||'"',r3=(m2.newline||(m2.newline=this.guessLineEndings(e2,r3)),a2=!1,m2.delimiter?U(m2.delimiter)&&(m2.delimiter=m2.delimiter(e2),p2.meta.delimiter=m2.delimiter):((r3=((e3,t3,i4,r4,n4)=>{var s4,a3,o3,h3;n4=n4||[","," ","|",";",v.RECORD_SEP,v.UNIT_SEP];for(var u3=0;u3<n4.length;u3++){for(var d3,f3=n4[u3],l4=0,c3=0,p3=0,g3=(o3=void 0,new E({comments:r4,delimiter:f3,newline:t3,preview:10}).parse(e3)),_3=0;_3<g3.data.length;_3++)i4&&y2(g3.data[_3])?p3++:(d3=g3.data[_3].length,c3+=d3,o3===void 0?o3=d3:0<d3&&(l4+=Math.abs(d3-o3),o3=d3));0<g3.data.length&&(c3/=g3.data.length-p3),(a3===void 0||l4<=a3)&&(h3===void 0||h3<c3)&&1.99<c3&&(a3=l4,s4=f3,h3=c3)}return{successful:!!(m2.delimiter=s4),bestDelimiter:s4}})(e2,m2.newline,m2.skipEmptyLines,m2.comments,m2.delimitersToGuess)).successful?m2.delimiter=r3.bestDelimiter:(a2=!0,m2.delimiter=v.DefaultDelimiter),p2.meta.delimiter=m2.delimiter),b(m2));return m2.preview&&m2.header&&r3.preview++,n3=e2,s3=new E(r3),p2=s3.parse(n3,t2,i3),g2(),l3?{meta:{paused:!0}}:p2||{meta:{paused:!1}}},this.paused=function(){return l3},this.pause=function(){l3=!0,s3.abort(),n3=U(m2.chunk)?"":n3.substring(s3.getCharIndex())},this.resume=function(){i2.streamer._halted?(l3=!1,i2.streamer.parseChunk(n3,!0)):setTimeout(i2.resume,3)},this.aborted=function(){return e},this.abort=function(){e=!0,s3.abort(),p2.meta.aborted=!0,U(m2.complete)&&m2.complete(p2),n3=""},this.guessLineEndings=function(e2,t2){e2=e2.substring(0,1048576);var t2=new RegExp(P(t2)+"([^]*?)"+P(t2),"gm"),i3=(e2=e2.replace(t2,"")).split("\r"),t2=e2.split(`
4
4
  `),e2=1<t2.length&&t2[0].length<i3[0].length;if(i3.length===1||e2)return`
@@ -818,7 +818,7 @@ ${end2.comment}`:end2.comment}this.doc.range[2]=end2.offset;break}default:this.e
818
818
  `],encapsulation:2,changeDetection:0})}}return MtxDatetimepickerContent2})(),MtxDatetimepicker=(()=>{class MtxDatetimepicker2{get panelClass(){return this._panelClass}set panelClass(value){this._panelClass=coerceStringArray(value)}get opened(){return this._opened}set opened(value){value?this.open():this.close()}get color(){return this._color||(this.datetimepickerInput?this.datetimepickerInput.getThemePalette():void 0)}set color(value){this._color=value}constructor(){if(this._overlay=inject(Overlay),this._viewContainerRef=inject(ViewContainerRef),this._scrollStrategy=inject(MTX_DATETIMEPICKER_SCROLL_STRATEGY),this._dateAdapter=inject(DatetimeAdapter,{optional:!0}),this._dir=inject(Directionality,{optional:!0}),this._defaultOptions=inject(MTX_DATETIMEPICKER_DEFAULT_OPTIONS,{optional:!0}),this._document=inject(DOCUMENT),this._injector=inject(Injector),this.multiYearSelector=this._defaultOptions?.multiYearSelector??!1,this.twelvehour=this._defaultOptions?.twelvehour??!1,this.showWeekNumbers=this._defaultOptions?.showWeekNumbers??!1,this.startView=this._defaultOptions?.startView??"month",this.mode=this._defaultOptions?.mode??"auto",this.timeInterval=this._defaultOptions?.timeInterval??1,this.preventSameDateTimeSelection=!1,this.calendarHeaderComponent=this._defaultOptions?.calendarHeaderComponent,this.selectedChanged=new EventEmitter,this.openedStream=new EventEmitter,this.closedStream=new EventEmitter,this.viewChanged=new EventEmitter,this._panelClass=coerceStringArray(this._defaultOptions?.panelClass),this._opened=!1,this.id=`mtx-datetimepicker-${datetimepickerUid++}`,this._color=this._defaultOptions?.color,this._disabledChange=new Subject,this._validSelected=null,this._focusedElementBeforeOpen=null,this._backdropHarnessClass=`${this.id}-backdrop`,this._inputStateChanges=Subscription.EMPTY,this._actionsPortal=null,this.oldValue=null,this._type=this._defaultOptions?.type??"datetime",this.touchUi=this._defaultOptions?.touchUi??!1,this.timeInput=this._defaultOptions?.timeInput??!1,this.timeInputAutoFocus=this._defaultOptions?.timeInputAutoFocus??!0,this.xPosition="start",this.yPosition="below",this.restoreFocus=!0,!this._dateAdapter)throw createMissingDateImplError("DateAdapter")}get startAt(){return this._startAt||(this.datetimepickerInput?this.datetimepickerInput.value:null)}set startAt(date){this._startAt=this._dateAdapter.getValidDateOrNull(date)}get type(){return this._type}set type(value){this._type=value||"datetime"}get disabled(){return this._disabled===void 0&&this.datetimepickerInput?this.datetimepickerInput.disabled:!!this._disabled}set disabled(value){value!==this._disabled&&(this._disabled=value,this._disabledChange.next(value))}get _selected(){return this._validSelected}set _selected(value){this._validSelected=value}get _minDate(){return this.datetimepickerInput&&this.datetimepickerInput.min}get _maxDate(){return this.datetimepickerInput&&this.datetimepickerInput.max}get _dateFilter(){return this.datetimepickerInput&&this.datetimepickerInput._dateFilter}_viewChanged(view){this.viewChanged.emit(view)}ngOnDestroy(){this._destroyOverlay(),this.close(),this._inputStateChanges.unsubscribe(),this._disabledChange.complete()}_select(date){this.oldValue=this._selected,this._selected=date,this._actionsPortal||this._dateAdapter.sameDatetime(this.oldValue,this._selected)||this.selectedChanged.emit(date)}_selectManually(){this._selected?this.selectedChanged.emit(this._selected||this.oldValue):(this._selected=this._dateAdapter.today(),this.selectedChanged.emit(this._selected)),this.close()}_clearSelected(){this.oldValue=null,this._selected=null,this.selectedChanged.emit(),this.close()}_registerInput(input2){if(this.datetimepickerInput)throw Error("A MtxDatetimepicker can only be associated with a single input.");this.datetimepickerInput=input2,this._inputStateChanges=this.datetimepickerInput._valueChange.subscribe(value=>this._selected=value)}open(){if(!(this._opened||this.disabled)){if(!this.datetimepickerInput)throw Error("Attempted to open an MtxDatetimepicker with no associated input.");this._focusedElementBeforeOpen=_getFocusedElementPierceShadowDom(),this._openOverlay(),this._opened=!0,this.openedStream.emit()}}close(){if(!this._opened)return;let canRestoreFocus=this.restoreFocus&&this._focusedElementBeforeOpen&&typeof this._focusedElementBeforeOpen.focus=="function",completeClose=()=>{this._opened&&(this._opened=!1,this.closedStream.emit())};if(this._componentRef){let{instance,location:location2}=this._componentRef;instance._animationDone.pipe(take(1)).subscribe(()=>{let activeElement=this._document.activeElement;canRestoreFocus&&(!activeElement||activeElement===this._document.activeElement||location2.nativeElement.contains(activeElement))&&this._focusedElementBeforeOpen.focus(),this._focusedElementBeforeOpen=null,this._destroyOverlay()}),instance._startExitAnimation()}canRestoreFocus?setTimeout(completeClose):completeClose()}_forwardContentValues(instance){instance.datetimepicker=this,instance.color=this.color,instance._dialogLabelId=this.datetimepickerInput.getOverlayLabelId(),instance.type=this.type,instance.view=this.startView,instance._assignActions(this._actionsPortal,!1)}_openOverlay(){this._destroyOverlay();let isDialog=this.touchUi,labelId=this.datetimepickerInput.getOverlayLabelId(),portal=new ComponentPortal(MtxDatetimepickerContent,this._viewContainerRef),overlayRef=this._overlayRef=this._overlay.create(new OverlayConfig({positionStrategy:isDialog?this._getDialogStrategy():this._getDropdownStrategy(),hasBackdrop:!0,backdropClass:[isDialog?"cdk-overlay-dark-backdrop":"mat-overlay-transparent-backdrop",this._backdropHarnessClass],direction:this._dir||void 0,scrollStrategy:isDialog?this._overlay.scrollStrategies.block():this._scrollStrategy(),panelClass:`mtx-datetimepicker-${isDialog?"dialog":"popup"}`})),overlayElement=overlayRef.overlayElement;overlayElement.setAttribute("role","dialog"),labelId&&overlayElement.setAttribute("aria-labelledby",labelId),isDialog&&overlayElement.setAttribute("aria-modal","true"),this._getCloseStream(overlayRef).subscribe(event2=>{event2&&event2.preventDefault(),this.close()}),this._componentRef=overlayRef.attach(portal),this._forwardContentValues(this._componentRef.instance),isDialog||afterNextRender(()=>{overlayRef.updatePosition()},{injector:this._injector})}_destroyOverlay(){this._overlayRef&&(this._overlayRef.dispose(),this._overlayRef=this._componentRef=null)}_getDialogStrategy(){return this._overlay.position().global().centerHorizontally().centerVertically()}_getDropdownStrategy(){let strategy=this._overlay.position().flexibleConnectedTo(this.datetimepickerInput.getConnectedOverlayOrigin()).withTransformOriginOn(".mtx-datetimepicker-content").withFlexibleDimensions(!1).withViewportMargin(8).withLockedPosition();return this._setConnectedPositions(strategy)}_setConnectedPositions(strategy){let primaryX=this.xPosition==="end"?"end":"start",secondaryX=primaryX==="start"?"end":"start",primaryY=this.yPosition==="above"?"bottom":"top",secondaryY=primaryY==="top"?"bottom":"top";return strategy.withPositions([{originX:primaryX,originY:secondaryY,overlayX:primaryX,overlayY:primaryY},{originX:primaryX,originY:primaryY,overlayX:primaryX,overlayY:secondaryY},{originX:secondaryX,originY:secondaryY,overlayX:secondaryX,overlayY:primaryY},{originX:secondaryX,originY:primaryY,overlayX:secondaryX,overlayY:secondaryY}])}_getCloseStream(overlayRef){return merge(overlayRef.backdropClick(),overlayRef.detachments(),overlayRef.keydownEvents().pipe(filter(event2=>event2.keyCode===27&&!hasModifierKey(event2)||this.datetimepickerInput&&hasModifierKey(event2,"altKey")&&event2.keyCode===38)))}registerActions(portal){if(this._actionsPortal)throw Error("A MtxDatetimepicker can only be associated with a single actions row.");this._actionsPortal=portal,this._componentRef?.instance._assignActions(portal,!0)}removeActions(portal){portal===this._actionsPortal&&(this._actionsPortal=null,this._componentRef?.instance._assignActions(null,!0))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||MtxDatetimepicker2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:MtxDatetimepicker2,selectors:[["mtx-datetimepicker"]],inputs:{multiYearSelector:[2,"multiYearSelector","multiYearSelector",booleanAttribute],twelvehour:[2,"twelvehour","twelvehour",booleanAttribute],showWeekNumbers:[2,"showWeekNumbers","showWeekNumbers",booleanAttribute],startView:"startView",mode:"mode",timeInterval:[2,"timeInterval","timeInterval",numberAttribute],preventSameDateTimeSelection:[2,"preventSameDateTimeSelection","preventSameDateTimeSelection",booleanAttribute],calendarHeaderComponent:"calendarHeaderComponent",panelClass:"panelClass",opened:[2,"opened","opened",booleanAttribute],color:"color",startAt:"startAt",type:"type",touchUi:[2,"touchUi","touchUi",booleanAttribute],timeInput:[2,"timeInput","timeInput",booleanAttribute],timeInputAutoFocus:[2,"timeInputAutoFocus","timeInputAutoFocus",booleanAttribute],disabled:[2,"disabled","disabled",booleanAttribute],xPosition:"xPosition",yPosition:"yPosition",restoreFocus:[2,"restoreFocus","restoreFocus",booleanAttribute]},outputs:{selectedChanged:"selectedChanged",openedStream:"opened",closedStream:"closed",viewChanged:"viewChanged"},exportAs:["mtxDatetimepicker"],decls:0,vars:0,template:function(rf,ctx){},encapsulation:2,changeDetection:0})}}return MtxDatetimepicker2})(),MAT_DATETIMEPICKER_VALUE_ACCESSOR={provide:NG_VALUE_ACCESSOR,useExisting:forwardRef(()=>MtxDatetimepickerInput),multi:!0},MAT_DATETIMEPICKER_VALIDATORS={provide:NG_VALIDATORS,useExisting:forwardRef(()=>MtxDatetimepickerInput),multi:!0},MtxDatetimepickerInputEvent=class{constructor(target,targetElement){this.target=target,this.targetElement=targetElement,this.value=this.target.value}},MtxDatetimepickerInput=(()=>{class MtxDatetimepickerInput2{constructor(){this._elementRef=inject(ElementRef),this._dateAdapter=inject(DatetimeAdapter,{optional:!0}),this._dateFormats=inject(MTX_DATETIME_FORMATS,{optional:!0}),this._formField=inject(MatFormField,{optional:!0}),this.dateChange=new EventEmitter,this.dateInput=new EventEmitter,this._valueChange=new EventEmitter,this._disabledChange=new EventEmitter,this._datetimepickerSubscription=Subscription.EMPTY,this._localeSubscription=Subscription.EMPTY,this._lastValueValid=!1,this._onTouched=()=>{},this._cvaOnChange=()=>{},this._validatorOnChange=()=>{},this._parseValidator=()=>this._lastValueValid?null:{mtxDatetimepickerParse:{text:this._elementRef.nativeElement.value}},this._minValidator=control=>{let controlValue=this._dateAdapter.getValidDateOrNull(this._dateAdapter.deserialize(control.value));return!this.min||!controlValue||this._dateAdapter.compareDatetime(this.min,controlValue)<=0?null:{mtxDatetimepickerMin:{min:this.min,actual:controlValue}}},this._maxValidator=control=>{let controlValue=this._dateAdapter.getValidDateOrNull(this._dateAdapter.deserialize(control.value));return!this.max||!controlValue||this._dateAdapter.compareDatetime(this.max,controlValue)>=0?null:{mtxDatetimepickerMax:{max:this.max,actual:controlValue}}},this._filterValidator=control=>{let controlValue=this._dateAdapter.getValidDateOrNull(this._dateAdapter.deserialize(control.value));return!this._dateFilter||!controlValue||this._dateFilter(controlValue,MtxDatetimepickerFilterType.DATE)?null:{mtxDatetimepickerFilter:!0}},this._validator=Validators.compose([this._parseValidator,this._minValidator,this._maxValidator,this._filterValidator]);let _dateAdapter=this._dateAdapter;if(!this._dateAdapter)throw createMissingDateImplError("DatetimeAdapter");if(!this._dateFormats)throw createMissingDateImplError("MTX_DATETIME_FORMATS");this._localeSubscription=_dateAdapter.localeChanges.subscribe(()=>{this.value=this._dateAdapter.deserialize(this.value)})}set mtxDatetimepicker(value){this.registerDatetimepicker(value)}set mtxDatetimepickerFilter(filter2){this._dateFilter=filter2,this._validatorOnChange()}get value(){return this._value}set value(value){value=this._dateAdapter.deserialize(value),this._lastValueValid=!value||this._dateAdapter.isValid(value),value=this._dateAdapter.getValidDateOrNull(value);let oldDate=this.value;this._value=value,this._formatValue(value),setTimeout(()=>{this._dateAdapter.sameDatetime(oldDate,value)||this._valueChange.emit(value)})}get min(){return this._min}set min(value){this._min=this._dateAdapter.getValidDateOrNull(this._dateAdapter.deserialize(value)),this._validatorOnChange()}get max(){return this._max}set max(value){this._max=this._dateAdapter.getValidDateOrNull(this._dateAdapter.deserialize(value)),this._validatorOnChange()}get disabled(){return!!this._disabled}set disabled(value){this._disabled!==value&&(this._disabled=value,this._disabledChange.emit(value))}ngAfterContentInit(){this._datetimepicker&&(this._datetimepickerSubscription=this._datetimepicker.selectedChanged.subscribe(selected=>{this.value=selected,this._cvaOnChange(selected),this._onTouched(),this.dateInput.emit(new MtxDatetimepickerInputEvent(this,this._elementRef.nativeElement)),this.dateChange.emit(new MtxDatetimepickerInputEvent(this,this._elementRef.nativeElement))}))}ngOnDestroy(){this._datetimepickerSubscription.unsubscribe(),this._localeSubscription.unsubscribe(),this._valueChange.complete(),this._disabledChange.complete()}registerOnValidatorChange(fn2){this._validatorOnChange=fn2}validate(c){return this._validator?this._validator(c):null}getConnectedOverlayOrigin(){return this._formField?this._formField.getConnectedOverlayOrigin():this._elementRef}getOverlayLabelId(){return this._formField?this._formField.getLabelId():this._elementRef.nativeElement.getAttribute("aria-labelledby")}writeValue(value){this.value=value}registerOnChange(fn2){this._cvaOnChange=fn2}registerOnTouched(fn2){this._onTouched=fn2}setDisabledState(disabled){this.disabled=disabled}_onKeydown(event2){event2.altKey&&event2.keyCode===40&&(this._datetimepicker.open(),event2.preventDefault())}_onInput(value){let date=this._dateAdapter.parse(value,this.getParseFormat());this._lastValueValid=!date||this._dateAdapter.isValid(date),date=this._dateAdapter.getValidDateOrNull(date),this._value=date,this._cvaOnChange(date),this._valueChange.emit(date),this.dateInput.emit(new MtxDatetimepickerInputEvent(this,this._elementRef.nativeElement))}_onChange(){this.dateChange.emit(new MtxDatetimepickerInputEvent(this,this._elementRef.nativeElement))}_onBlur(){this.value&&this._formatValue(this.value),this._onTouched()}registerDatetimepicker(value){value&&(this._datetimepicker=value,this._datetimepicker._registerInput(this))}getDisplayFormat(){switch(this._datetimepicker.type){case"date":return this._dateFormats.display.dateInput;case"datetime":return this._dateFormats.display.datetimeInput;case"time":return this._dateFormats.display.timeInput;case"month":return this._dateFormats.display.monthInput;case"year":return this._dateFormats.display.yearInput}}getParseFormat(){let parseFormat;switch(this._datetimepicker.type){case"date":parseFormat=this._dateFormats.parse.dateInput;break;case"datetime":parseFormat=this._dateFormats.parse.datetimeInput;break;case"time":parseFormat=this._dateFormats.parse.timeInput;break;case"month":parseFormat=this._dateFormats.parse.monthInput;break;case"year":parseFormat=this._dateFormats.parse.yearInput;break}return parseFormat||(parseFormat=this._dateFormats.parse.dateInput),parseFormat}_formatValue(value){this._elementRef.nativeElement.value=value?this._dateAdapter.format(value,this.getDisplayFormat()):""}getThemePalette(){return this._formField?this._formField.color:void 0}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||MtxDatetimepickerInput2)}}static{this.\u0275dir=\u0275\u0275defineDirective({type:MtxDatetimepickerInput2,selectors:[["input","mtxDatetimepicker",""]],hostVars:5,hostBindings:function(rf,ctx){rf&1&&\u0275\u0275listener("input",function($event){return ctx._onInput($event.target.value)})("change",function(){return ctx._onChange()})("blur",function(){return ctx._onBlur()})("keydown",function($event){return ctx._onKeydown($event)}),rf&2&&(\u0275\u0275domProperty("disabled",ctx.disabled),\u0275\u0275attribute("aria-haspopup",!0)("aria-owns",(ctx._datetimepicker==null?null:ctx._datetimepicker.opened)&&ctx._datetimepicker.id||null)("min",ctx.min?ctx._dateAdapter.toIso8601(ctx.min):null)("max",ctx.max?ctx._dateAdapter.toIso8601(ctx.max):null))},inputs:{mtxDatetimepicker:"mtxDatetimepicker",mtxDatetimepickerFilter:"mtxDatetimepickerFilter",value:"value",min:"min",max:"max",disabled:[2,"disabled","disabled",booleanAttribute]},outputs:{dateChange:"dateChange",dateInput:"dateInput"},exportAs:["mtxDatetimepickerInput"],features:[\u0275\u0275ProvidersFeature([MAT_DATETIMEPICKER_VALUE_ACCESSOR,MAT_DATETIMEPICKER_VALIDATORS,{provide:MAT_INPUT_VALUE_ACCESSOR,useExisting:MtxDatetimepickerInput2}])]})}}return MtxDatetimepickerInput2})(),MtxDatetimepickerToggleIcon=(()=>{class MtxDatetimepickerToggleIcon2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||MtxDatetimepickerToggleIcon2)}}static{this.\u0275dir=\u0275\u0275defineDirective({type:MtxDatetimepickerToggleIcon2,selectors:[["","mtxDatetimepickerToggleIcon",""]]})}}return MtxDatetimepickerToggleIcon2})(),MtxDatetimepickerToggle=(()=>{class MtxDatetimepickerToggle2{get disabled(){return this._disabled===void 0?this.datetimepicker.disabled:!!this._disabled}set disabled(value){this._disabled=value}constructor(){this._intl=inject(MtxDatetimepickerIntl),this._changeDetectorRef=inject(ChangeDetectorRef),this._stateChanges=Subscription.EMPTY;let defaultTabIndex=inject(new HostAttributeToken("tabindex"),{optional:!0}),parsedTabIndex=Number(defaultTabIndex);this.tabIndex=parsedTabIndex||parsedTabIndex===0?parsedTabIndex:null}ngOnChanges(changes){changes.datetimepicker&&this._watchStateChanges()}ngOnDestroy(){this._stateChanges.unsubscribe()}ngAfterContentInit(){this._watchStateChanges()}_open(event2){this.datetimepicker&&!this.disabled&&(this.datetimepicker.open(),event2.stopPropagation())}_watchStateChanges(){let datetimepickerDisabled=this.datetimepicker?this.datetimepicker._disabledChange:of(),inputDisabled=this.datetimepicker&&this.datetimepicker.datetimepickerInput?this.datetimepicker.datetimepickerInput._disabledChange:of(),datetimepickerToggled=this.datetimepicker?merge(this.datetimepicker.openedStream,this.datetimepicker.closedStream):of();this._stateChanges.unsubscribe(),this._stateChanges=merge(this._intl.changes,datetimepickerDisabled,inputDisabled,datetimepickerToggled).subscribe(()=>this._changeDetectorRef.markForCheck())}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||MtxDatetimepickerToggle2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:MtxDatetimepickerToggle2,selectors:[["mtx-datetimepicker-toggle"]],contentQueries:function(rf,ctx,dirIndex){if(rf&1&&\u0275\u0275contentQuery(dirIndex,MtxDatetimepickerToggleIcon,5),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx._customIcon=_t.first)}},viewQuery:function(rf,ctx){if(rf&1&&\u0275\u0275viewQuery(_c32,5),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx._button=_t.first)}},hostAttrs:[1,"mtx-datetimepicker-toggle"],hostVars:8,hostBindings:function(rf,ctx){rf&1&&\u0275\u0275listener("click",function($event){return ctx._open($event)}),rf&2&&(\u0275\u0275attribute("tabindex",null)("data-mtx-calendar",ctx.datetimepicker?ctx.datetimepicker.id:null),\u0275\u0275classProp("mtx-datetimepicker-toggle-active",ctx.datetimepicker&&ctx.datetimepicker.opened)("mat-accent",ctx.datetimepicker&&ctx.datetimepicker.color==="accent")("mat-warn",ctx.datetimepicker&&ctx.datetimepicker.color==="warn"))},inputs:{datetimepicker:[0,"for","datetimepicker"],tabIndex:"tabIndex",ariaLabel:[0,"aria-label","ariaLabel"],disabled:[2,"disabled","disabled",booleanAttribute],disableRipple:[2,"disableRipple","disableRipple",booleanAttribute]},exportAs:["mtxDatetimepickerToggle"],features:[\u0275\u0275NgOnChangesFeature],ngContentSelectors:_c5,decls:4,vars:6,consts:[["button",""],["mat-icon-button","","type","button",3,"disabled","disableRipple"],["viewBox","0 0 24 24","width","24px","height","24px","fill","currentColor","focusable","false",1,"mtx-datetimepicker-toggle-default-icon"],["d","M12,20A8,8 0 0,0 20,12A8,8 0 0,0 12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20M12,2A10,10 0 0,1 22,12A10,10 0 0,1 12,22C6.47,22 2,17.5 2,12A10,10 0 0,1 12,2M12.5,7V12.25L17,14.92L16.25,16.15L11,13V7H12.5Z"],["d","M15,13H16.5V15.82L18.94,17.23L18.19,18.53L15,16.69V13M19,8H5V19H9.67C9.24,18.09 9,17.07 9,16A7,7 0 0,1 16,9C17.07,9 18.09,9.24 19,9.67V8M5,21C3.89,21 3,20.1 3,19V5C3,3.89 3.89,3 5,3H6V1H8V3H16V1H18V3H19A2,2 0 0,1 21,5V11.1C22.24,12.36 23,14.09 23,16A7,7 0 0,1 16,23C14.09,23 12.36,22.24 11.1,21H5M16,11.15A4.85,4.85 0 0,0 11.15,16C11.15,18.68 13.32,20.85 16,20.85A4.85,4.85 0 0,0 20.85,16C20.85,13.32 18.68,11.15 16,11.15Z"],["d","M0 0h24v24H0z","fill","none"],["d","M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zM7 10h5v5H7z"]],template:function(rf,ctx){rf&1&&(\u0275\u0275projectionDef(_c4),\u0275\u0275elementStart(0,"button",1,0),\u0275\u0275conditionalCreate(2,MtxDatetimepickerToggle_Conditional_2_Template,3,1),\u0275\u0275projection(3),\u0275\u0275elementEnd()),rf&2&&(\u0275\u0275property("disabled",ctx.disabled)("disableRipple",ctx.disableRipple),\u0275\u0275attribute("aria-haspopup",ctx.datetimepicker?"dialog":null)("aria-label",ctx.ariaLabel||ctx._intl.openCalendarLabel)("tabindex",ctx.disabled?-1:ctx.tabIndex),\u0275\u0275advance(2),\u0275\u0275conditional(ctx._customIcon?-1:2))},dependencies:[MatIconButton],styles:[`.mtx-datetimepicker-toggle{pointer-events:auto;color:var(--mtx-datetimepicker-toggle-icon-color, var(--mat-sys-on-surface-variant))}.mtx-datetimepicker-toggle-active{color:var(--mtx-datetimepicker-toggle-active-state-icon-color, var(--mat-sys-on-surface-variant))}@media (forced-colors: active){.mtx-datetimepicker-toggle-default-icon{color:CanvasText}}
819
819
  `],encapsulation:2,changeDetection:0})}}return MtxDatetimepickerToggle2})();var MtxDatetimepickerModule=(()=>{class MtxDatetimepickerModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||MtxDatetimepickerModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:MtxDatetimepickerModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({providers:[MTX_DATETIMEPICKER_SCROLL_STRATEGY_FACTORY_PROVIDER],imports:[CommonModule,OverlayModule,A11yModule,PortalModule,MatButtonModule,MtxCalendar,MtxTimeView,MtxDatetimepickerToggle,MtxDatetimepickerContent]})}}return MtxDatetimepickerModule2})();var MAT_LUXON_DATE_ADAPTER_OPTIONS=new InjectionToken("MAT_LUXON_DATE_ADAPTER_OPTIONS",{providedIn:"root",factory:MAT_LUXON_DATE_ADAPTER_OPTIONS_FACTORY});function MAT_LUXON_DATE_ADAPTER_OPTIONS_FACTORY(){return{useUtc:!1,defaultOutputCalendar:"gregory"}}function range2(length,valueFunction){let valuesArray=Array(length);for(let i=0;i<length;i++)valuesArray[i]=valueFunction(i);return valuesArray}var LuxonDateAdapter=(()=>{class LuxonDateAdapter2 extends DateAdapter{_useUTC;_firstDayOfWeek;_defaultOutputCalendar;constructor(){super();let dateLocale=inject(MAT_DATE_LOCALE,{optional:!0}),options=inject(MAT_LUXON_DATE_ADAPTER_OPTIONS,{optional:!0});this._useUTC=!!options?.useUtc,this._firstDayOfWeek=options?.firstDayOfWeek,this._defaultOutputCalendar=options?.defaultOutputCalendar||"gregory",this.setLocale(dateLocale||DateTime.local().locale)}getYear(date){return date.year}getMonth(date){return date.month-1}getDate(date){return date.day}getDayOfWeek(date){return date.weekday}getMonthNames(style2){return Info.months(style2,{locale:this.locale,outputCalendar:this._defaultOutputCalendar})}getDateNames(){let dtf=new Intl.DateTimeFormat(this.locale,{day:"numeric",timeZone:"utc"});return range2(31,i=>dtf.format(DateTime.utc(2017,1,i+1).toJSDate()))}getDayOfWeekNames(style2){let days=Info.weekdays(style2,{locale:this.locale});return days.unshift(days.pop()),days}getYearName(date){return date.toFormat("yyyy",this._getOptions())}getFirstDayOfWeek(){return this._firstDayOfWeek??Info.getStartOfWeek({locale:this.locale})}getNumDaysInMonth(date){return date.daysInMonth}clone(date){return DateTime.fromObject(date.toObject(),this._getOptions())}createDate(year,month,date){let options=this._getOptions();if(month<0||month>11)throw Error(`Invalid month index "${month}". Month index has to be between 0 and 11.`);if(date<1)throw Error(`Invalid date "${date}". Date has to be greater than 0.`);let result=this._useUTC?DateTime.utc(year,month+1,date,options):DateTime.local(year,month+1,date,options);if(!this.isValid(result))throw Error(`Invalid date "${date}". Reason: "${result.invalidReason}".`);return result}today(){let options=this._getOptions();return this._useUTC?DateTime.utc(options):DateTime.local(options)}parse(value,parseFormat){let options=this._getOptions();if(typeof value=="string"&&value.length>0){let iso8601Date=DateTime.fromISO(value,options);if(this.isValid(iso8601Date))return iso8601Date;let formats=Array.isArray(parseFormat)?parseFormat:[parseFormat];if(!parseFormat.length)throw Error("Formats array must not be empty.");for(let format2 of formats){let fromFormat=DateTime.fromFormat(value,format2,options);if(this.isValid(fromFormat))return fromFormat}return this.invalid()}else{if(typeof value=="number")return DateTime.fromMillis(value,options);if(value instanceof Date)return DateTime.fromJSDate(value,options);if(value instanceof DateTime)return DateTime.fromMillis(value.toMillis(),options)}return null}format(date,displayFormat){if(!this.isValid(date))throw Error("LuxonDateAdapter: Cannot format invalid date.");return this._useUTC?date.setLocale(this.locale).setZone("utc").toFormat(displayFormat):date.setLocale(this.locale).toFormat(displayFormat)}addCalendarYears(date,years){return date.reconfigure(this._getOptions()).plus({years})}addCalendarMonths(date,months2){return date.reconfigure(this._getOptions()).plus({months:months2})}addCalendarDays(date,days){return date.reconfigure(this._getOptions()).plus({days})}toIso8601(date){return date.toISO()}deserialize(value){let options=this._getOptions(),date;if(value instanceof Date&&(date=DateTime.fromJSDate(value,options)),typeof value=="string"){if(!value)return null;date=DateTime.fromISO(value,options)}return date&&this.isValid(date)?date:super.deserialize(value)}isDateInstance(obj){return obj instanceof DateTime}isValid(date){return date.isValid}invalid(){return DateTime.invalid("Invalid Luxon DateTime object.")}setTime(target,hours,minutes,seconds){return this.clone(target).set({hour:hours,minute:minutes,second:seconds,millisecond:0})}getHours(date){return date.hour}getMinutes(date){return date.minute}getSeconds(date){return date.second}parseTime(value,parseFormat){let result=this.parse(value,parseFormat);return(!result||!this.isValid(result))&&typeof value=="string"&&this.parse(value.replace(/[^0-9:(AM|PM)]/gi,""),parseFormat)||result}addSeconds(date,amount){return date.reconfigure(this._getOptions()).plus({seconds:amount})}_getOptions(){return{zone:this._useUTC?"utc":void 0,locale:this.locale,outputCalendar:this._defaultOutputCalendar}}static \u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LuxonDateAdapter2)};static \u0275prov=\u0275\u0275defineInjectable({token:LuxonDateAdapter2,factory:LuxonDateAdapter2.\u0275fac})}return LuxonDateAdapter2})(),MAT_LUXON_DATE_FORMATS={parse:{dateInput:"D",timeInput:"t"},display:{dateInput:"D",timeInput:"t",monthYearLabel:"LLL yyyy",dateA11yLabel:"DD",monthYearA11yLabel:"LLLL yyyy",timeOptionLabel:"t"}};var MatLuxonDateModule=(()=>{class MatLuxonDateModule2{static \u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||MatLuxonDateModule2)};static \u0275mod=\u0275\u0275defineNgModule({type:MatLuxonDateModule2});static \u0275inj=\u0275\u0275defineInjector({providers:[provideLuxonDateAdapter()]})}return MatLuxonDateModule2})();function provideLuxonDateAdapter(formats=MAT_LUXON_DATE_FORMATS){return[{provide:DateAdapter,useClass:LuxonDateAdapter,deps:[MAT_DATE_LOCALE,MAT_LUXON_DATE_ADAPTER_OPTIONS]},{provide:MAT_DATE_FORMATS,useValue:formats}]}function range3(length,valueFunction){let valuesArray=Array(length);for(let i=0;i<length;i++)valuesArray[i]=valueFunction(i);return valuesArray}var LuxonDatetimeAdapter=(()=>{class LuxonDatetimeAdapter2 extends DatetimeAdapter{constructor(){super(),this._useUtc=!1;let matDateLocale=inject(MAT_DATE_LOCALE,{optional:!0}),matLuxonAdapterOptions=inject(MAT_LUXON_DATE_ADAPTER_OPTIONS,{optional:!0});this.setLocale(matDateLocale||DateTime.now().locale),this._useUtc=matLuxonAdapterOptions?.useUtc||!1}setLocale(locale){super.setLocale(locale)}getHour(date){return date.hour}getMinute(date){return date.minute}isInNextMonth(startDate,endDate){let nextMonth=this.getDateInNextMonth(startDate);return super.sameMonthAndYear(nextMonth,endDate)}getWeek(date,firstDayOfWeek){return date.localWeekNumber}createDatetime(year,month,day,hour,minute){if(month<0||month>11)throw Error(`Invalid month index "${month}". Month index has to be between 0 and 11.`);if(day<1)throw Error(`Invalid date "${day}". Date has to be greater than 0.`);if(hour<0||hour>23)throw Error(`Invalid hour "${hour}". Hour has to be between 0 and 23.`);if(minute<0||minute>59)throw Error(`Invalid minute "${minute}". Minute has to be between 0 and 59.`);let result;if(this._useUtc?result=DateTime.utc(year,month+1,day,hour,minute):result=DateTime.local(year,month+1,day,hour,minute),!result.isValid)throw Error(`Invalid date "${day}" for month with index "${month}".`);return result.setLocale(this.locale)}getFirstDateOfMonth(date){return super.clone(date).startOf("month")}getHourNames(){return range3(24,i=>i.toLocaleString(this.locale))}getMinuteNames(){return range3(60,i=>i.toLocaleString(this.locale))}addCalendarHours(date,hours){return date.plus({hours})}addCalendarMinutes(date,minutes){return date.plus({minutes})}deserialize(value){return this._delegate.deserialize(value)}getDateInNextMonth(date){return date.plus({month:1})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LuxonDatetimeAdapter2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:LuxonDatetimeAdapter2,factory:LuxonDatetimeAdapter2.\u0275fac})}}return LuxonDatetimeAdapter2})(),MTX_LUXON_DATETIME_FORMATS={parse:{dateInput:"D",monthInput:"LLLL",yearInput:"yyyy",datetimeInput:"f",timeInput:"t"},display:{dateInput:"D",monthInput:"LLLL",yearInput:"yyyy",datetimeInput:"f",timeInput:"t",monthYearLabel:"yyyy",dateA11yLabel:"DDD",monthYearA11yLabel:"LLLL yyyy",popupHeaderDateLabel:"ccc, dd LLL"}};function provideLuxonDatetimeAdapter(formats=MTX_LUXON_DATETIME_FORMATS){return[{provide:DateAdapter,useClass:LuxonDateAdapter,deps:[MAT_DATE_LOCALE,MAT_LUXON_DATE_ADAPTER_OPTIONS]},{provide:DatetimeAdapter,useClass:LuxonDatetimeAdapter},{provide:MTX_DATETIME_FORMATS,useValue:formats}]}var setLocale=createAction("[Localization] Set Locale",props()),setTimeZone=createAction("[Localization] Set Time Zone",props());var LOCALE_STORAGE_KEY="locale";var LANGUAGE_TO_LOCALES=[{code:"nl",locale:"nl-NL"},{code:"de",locale:"de-DE"},{code:"en",locale:"en-US"}],TIME_ZONE_STORAGE_KEY="timezone";function mapLangToLocale(lang){return LANGUAGE_TO_LOCALES.find(map4=>map4.code===lang)?.locale||lang}var LocalizationService=(()=>{class LocalizationService2{constructor(storage){this.storage=storage}getLocale(){if(this.storage.has(LOCALE_STORAGE_KEY)){let locale=this.storage.get(LOCALE_STORAGE_KEY);return locale.includes("_")&&(locale=locale.replace("_","-"),this.setLocale(locale)),locale}return mapLangToLocale(Intl.DateTimeFormat().resolvedOptions().locale)}getTimeZone(){return this.storage.has(TIME_ZONE_STORAGE_KEY)?this.storage.get(TIME_ZONE_STORAGE_KEY):Intl.DateTimeFormat().resolvedOptions().timeZone}setLocale(locale){locale!==null?(this.storage.forever(LOCALE_STORAGE_KEY,locale),Settings.defaultLocale=locale):(this.storage.forget(LOCALE_STORAGE_KEY),Settings.defaultLocale=mapLangToLocale(Intl.DateTimeFormat().resolvedOptions().locale))}setTimeZone(timeZone){timeZone!==null?(this.storage.forever(TIME_ZONE_STORAGE_KEY,timeZone),Settings.defaultZone=timeZone):(this.storage.forget(TIME_ZONE_STORAGE_KEY),Settings.defaultZone=Intl.DateTimeFormat().resolvedOptions().timeZone)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LocalizationService2)(\u0275\u0275inject(StorageService))}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:LocalizationService2,factory:LocalizationService2.\u0275fac,providedIn:"root"})}}return LocalizationService2})();var LocalizationEffects=(()=>{class LocalizationEffects2{constructor(actions$,service){this.actions$=actions$,this.service=service,this.setLocale$=createEffect(()=>this.actions$.pipe(ofType(setLocale),tap(({locale})=>this.service.setLocale(locale))),{dispatch:!1}),this.setTimeZone$=createEffect(()=>this.actions$.pipe(ofType(setTimeZone),tap(({timeZone})=>this.service.setTimeZone(timeZone))),{dispatch:!1}),this.setDefaultUserPreferences$=createEffect(()=>this.actions$.pipe(ofType(logInSuccess,loadMeSuccess3),map(({data})=>({localisation:get_default(data,"localisation",get_default(data,"user.localisation")),timeZone:get_default(data,"timeZone",get_default(data,"user.timeZone"))})),filter(({localisation,timeZone})=>isNil_default(localisation)||isNil_default(timeZone)),map(({localisation,timeZone})=>updateMe2({data:__spreadValues(__spreadValues({},isNil_default(localisation)?{localisation:this.service.getLocale()}:{}),isNil_default(timeZone)?{timeZone:this.service.getTimeZone()}:{})})))),this.localeUserPreference$=createEffect(()=>this.actions$.pipe(ofType(logInSuccess,loadMeSuccess3,updateMeSuccess2,didUpdateMe2),map(({data})=>get_default(data,"localisation",get_default(data,"user.localisation"))),filter(locale=>locale!==void 0),distinctUntilChanged(),map(locale=>setLocale({locale})))),this.timeZoneUserPreference$=createEffect(()=>this.actions$.pipe(ofType(logInSuccess,loadMeSuccess3,updateMeSuccess2,didUpdateMe2),map(({data})=>get_default(data,"timeZone",get_default(data,"user.timeZone"))),filter(timeZone=>timeZone!==void 0),distinctUntilChanged(),map(timeZone=>setTimeZone({timeZone}))))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LocalizationEffects2)(\u0275\u0275inject(Actions),\u0275\u0275inject(LocalizationService))}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:LocalizationEffects2,factory:LocalizationEffects2.\u0275fac})}}return LocalizationEffects2})();var LocalizationModule=(()=>{class LocalizationModule2{constructor(storage){Settings.defaultLocale=storage.get(LOCALE_STORAGE_KEY,mapLangToLocale(Intl.DateTimeFormat().resolvedOptions().locale)),Settings.defaultZone=storage.get(TIME_ZONE_STORAGE_KEY,Intl.DateTimeFormat().resolvedOptions().timeZone)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LocalizationModule2)(\u0275\u0275inject(StorageService))}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:LocalizationModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({providers:[{provide:MAT_DATE_LOCALE,useFactory:service=>service.getLocale(),deps:[LocalizationService]}],imports:[StorageModule,EffectsModule.forFeature([LocalizationEffects])]})}}return LocalizationModule2})();function DateTimeInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",1),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function DateTimeInputComponent_Conditional_8_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",6),\u0275\u0275text(1,"__MESSAGE__.REQUIRED"),\u0275\u0275elementEnd())}var DateTimeInputComponent=(()=>{class DateTimeInputComponent2 extends ComponentInputComponent{constructor(){super(...arguments),this.destroy=inject(DestroyRef),this.formControl=new FormControl(null),this.platform=inject(CAPACITOR_PLATFORM),this.useTwelveHourFormat=/[AP]M$/i.test(DateTime.now().toFormat("t"))}ngOnInit(){this.formControl.valueChanges.pipe(takeUntilDestroyed(this.destroy)).subscribe(datetime=>{this.formControl.valid&&this.control.setValue(datetime?.toUTC().toISO({suppressMilliseconds:!0}))}),this.formControl.setValidators(this.getValidators());let value=this.inputControl?.value||this.field.inputDescription.defaultValue;this.formControl.setValue(value?DateTime.fromISO(value):null),this.field.inputDescription.disabled&&this.formControl.disable()}get control(){return this.componentFormGroup.controls[this.field.inputName]}getValidators(){let validators=[],{required}=this.field.inputDescription;return required&&validators.push(Validators.required),validators}static{this.\u0275fac=(()=>{let \u0275DateTimeInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275DateTimeInputComponent_BaseFactory||(\u0275DateTimeInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(DateTimeInputComponent2)))(__ngFactoryType__||DateTimeInputComponent2)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:DateTimeInputComponent2,selectors:[["ix-date-time-input"]],features:[\u0275\u0275ProvidersFeature([provideLuxonDatetimeAdapter(),{provide:MAT_DATE_LOCALE,useFactory:service=>service.getLocale(),deps:[LocalizationService]}]),\u0275\u0275InheritDefinitionFeature],decls:9,vars:14,consts:[["datetimePicker",""],[1,"description",3,"innerHTML"],[3,"formGroup"],["type","datetime","mode","auto","startView","month",3,"multiYearSelector","showWeekNumbers","timeInterval","timeInput","timeInputAutoFocus","touchUi","twelvehour"],["matInput","",3,"mtxDatetimepicker","formControl"],["matSuffix","",3,"for"],["translate",""]],template:function(rf,ctx){if(rf&1&&(\u0275\u0275conditionalCreate(0,DateTimeInputComponent_Conditional_0_Template,2,3,"p",1),\u0275\u0275elementStart(1,"mat-form-field",2)(2,"mat-label"),\u0275\u0275text(3),\u0275\u0275elementEnd(),\u0275\u0275element(4,"mtx-datetimepicker",3,0)(6,"input",4)(7,"mtx-datetimepicker-toggle",5),\u0275\u0275conditionalCreate(8,DateTimeInputComponent_Conditional_8_Template,2,0,"mat-error",6),\u0275\u0275elementEnd()),rf&2){let datetimePicker_r2=\u0275\u0275reference(5);\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(),\u0275\u0275property("formGroup",ctx.componentFormGroup),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("multiYearSelector",!0)("showWeekNumbers",!1)("timeInterval",1)("timeInput",!0)("timeInputAutoFocus",!0)("touchUi",ctx.platform!=="web")("twelvehour",ctx.useTwelveHourFormat),\u0275\u0275advance(2),\u0275\u0275property("mtxDatetimepicker",datetimePicker_r2)("formControl",ctx.formControl),\u0275\u0275advance(),\u0275\u0275property("for",datetimePicker_r2),\u0275\u0275advance(),\u0275\u0275conditional(ctx.formControl!=null&&ctx.formControl.hasError("required")?8:-1)}},dependencies:[LocalizationModule,MarkdownModule,MatFormFieldModule,MatFormField,MatLabel,MatError,MatSuffix,MatInputModule,MatInput,MtxDatetimepickerModule,MtxDatetimepicker,MtxDatetimepickerToggle,MtxDatetimepickerInput,ReactiveFormsModule,DefaultValueAccessor,NgControlStatus,NgControlStatusGroup,FormControlDirective,FormGroupDirective,TranslateModule,TranslateDirective,RenderMarkdownPipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}[_nghost-%COMP%] .mtx-datetimepicker-toggle[_ngcontent-%COMP%]{margin-right:4px}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{width:100%}"]})}}return DateTimeInputComponent2})();var MAX_FILE_SIZE=1e7;function readFile(file,output2){return new Observable(subscriber=>{let reader=createFileReader();reader.addEventListener("abort",onAbort),reader.addEventListener("error",onError),reader.addEventListener("load",onLoad),reader.addEventListener("progress",onProgress);let method=`readAs${upperFirst_default(output2)}`;return reader[method]&&reader[method](file),()=>{reader.removeEventListener("abort",onAbort),reader.removeEventListener("error",onError),reader.removeEventListener("load",onLoad),reader.removeEventListener("progress",onProgress)};function onAbort(event2){subscriber.next({event:event2}),subscriber.complete()}function onProgress(event2){subscriber.next({event:event2})}function onError(event2){subscriber.error(event2),subscriber.complete()}function onLoad(event2){subscriber.next({event:event2,result:reader.result||void 0}),subscriber.complete()}})}function createFileReader(){let reader=new FileReader;return reader._realReader?reader._realReader:reader}function readFileAsDataURL(file){return readFile(file,"dataURL")}function getFilesFromEvent(event2){let files;return files=get_default(event2,"target.files",[]),files.length||(files=get_default(event2,"dataTransfer.files",[])),files}function mapMimeTypeToIcon(type){if(type.startsWith("image/"))return"image";if(type.startsWith("audio/"))return"audio_file";if(type.startsWith("video/"))return"video_file";switch(type){case"application/x-cdf":return"audio_file";case"application/vnd.rar":case"application/x-7z-compressed":case"application/x-bzip":case"application/x-bzip2":case"application/x-freearc":case"application/x-tar":case"application/zip":case"application/gzip":return"folder_zip";case"application/pdf":return"picture_as_pdf";default:return"insert_drive_file"}}function getHeightAndWidthFromDataUrl(dataURL){return new Promise(resolve=>{let img=new Image;img.onload=()=>{resolve({height:img.height,width:img.width})},img.src=dataURL})}var _c012=["fileInput"],_c14=["*"];function FileUploadButtonComponent_Case_2_ng_container_1_Template(rf,ctx){rf&1&&\u0275\u0275elementContainer(0)}function FileUploadButtonComponent_Case_2_Template(rf,ctx){if(rf&1){let _r2=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",8),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r2),\u0275\u0275nextContext();let fileInput_r3=\u0275\u0275reference(1);return \u0275\u0275resetView(fileInput_r3.click())}),\u0275\u0275template(1,FileUploadButtonComponent_Case_2_ng_container_1_Template,1,0,"ng-container",9),\u0275\u0275elementEnd()}if(rf&2){let ctx_r3=\u0275\u0275nextContext(),innerContent_r5=\u0275\u0275reference(8);\u0275\u0275property("color",ctx_r3.color),\u0275\u0275advance(),\u0275\u0275property("ngTemplateOutlet",innerContent_r5)}}function FileUploadButtonComponent_Case_3_ng_container_1_Template(rf,ctx){rf&1&&\u0275\u0275elementContainer(0)}function FileUploadButtonComponent_Case_3_Template(rf,ctx){if(rf&1){let _r6=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",10),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r6),\u0275\u0275nextContext();let fileInput_r3=\u0275\u0275reference(1);return \u0275\u0275resetView(fileInput_r3.click())}),\u0275\u0275template(1,FileUploadButtonComponent_Case_3_ng_container_1_Template,1,0,"ng-container",9),\u0275\u0275elementEnd()}if(rf&2){let ctx_r3=\u0275\u0275nextContext(),innerContent_r5=\u0275\u0275reference(8);\u0275\u0275property("color",ctx_r3.color),\u0275\u0275advance(),\u0275\u0275property("ngTemplateOutlet",innerContent_r5)}}function FileUploadButtonComponent_Case_4_ng_container_1_Template(rf,ctx){rf&1&&\u0275\u0275elementContainer(0)}function FileUploadButtonComponent_Case_4_Template(rf,ctx){if(rf&1){let _r7=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",11),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r7),\u0275\u0275nextContext();let fileInput_r3=\u0275\u0275reference(1);return \u0275\u0275resetView(fileInput_r3.click())}),\u0275\u0275template(1,FileUploadButtonComponent_Case_4_ng_container_1_Template,1,0,"ng-container",9),\u0275\u0275elementEnd()}if(rf&2){let ctx_r3=\u0275\u0275nextContext(),innerContent_r5=\u0275\u0275reference(8);\u0275\u0275property("color",ctx_r3.color),\u0275\u0275advance(),\u0275\u0275property("ngTemplateOutlet",innerContent_r5)}}function FileUploadButtonComponent_Case_5_ng_container_1_Template(rf,ctx){rf&1&&\u0275\u0275elementContainer(0)}function FileUploadButtonComponent_Case_5_Template(rf,ctx){if(rf&1){let _r8=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",12),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r8),\u0275\u0275nextContext();let fileInput_r3=\u0275\u0275reference(1);return \u0275\u0275resetView(fileInput_r3.click())}),\u0275\u0275template(1,FileUploadButtonComponent_Case_5_ng_container_1_Template,1,0,"ng-container",9),\u0275\u0275elementEnd()}if(rf&2){\u0275\u0275nextContext();let innerContent_r5=\u0275\u0275reference(8);\u0275\u0275advance(),\u0275\u0275property("ngTemplateOutlet",innerContent_r5)}}function FileUploadButtonComponent_Case_6_ng_container_1_Template(rf,ctx){rf&1&&\u0275\u0275elementContainer(0)}function FileUploadButtonComponent_Case_6_Template(rf,ctx){if(rf&1){let _r9=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",13),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r9),\u0275\u0275nextContext();let fileInput_r3=\u0275\u0275reference(1);return \u0275\u0275resetView(fileInput_r3.click())}),\u0275\u0275template(1,FileUploadButtonComponent_Case_6_ng_container_1_Template,1,0,"ng-container",9),\u0275\u0275elementEnd()}if(rf&2){let ctx_r3=\u0275\u0275nextContext(),innerContent_r5=\u0275\u0275reference(8);\u0275\u0275property("color",ctx_r3.color),\u0275\u0275advance(),\u0275\u0275property("ngTemplateOutlet",innerContent_r5)}}function FileUploadButtonComponent_ng_template_7_Template(rf,ctx){rf&1&&\u0275\u0275projection(0)}var FileUploadButtonComponent=(()=>{class FileUploadButtonComponent2{constructor(){this.multiple=!1,this.color="primary",this.fileChange=new EventEmitter,this.fileChanges=new EventEmitter,this.snackBar=inject(MatSnackBar),this.translate=inject(TranslateService)}ngOnChanges(){this.label||(this.label=this.getDefaultLabel())}change(event2){return __async(this,null,function*(){let fileObjects=getFilesFromEvent(event2);if(fileObjects.length){let files=[];for(let file of fileObjects){let{result:previewSrc}=yield firstValueFrom(readFileAsDataURL(file).pipe(filter(data=>data.event.type==="load")));if(file.type&&!this.isAllowedFileType(file.type)){let message=this.translate.instant("__MESSAGE__.INVALID_FILE_TYPE");this.snackBar.open(message,void 0,{duration:3e3}),this.clearFileInput(),files=[];break}else if(file.size!==void 0&&!this.isAllowedFileSize(file.size)){let name=file.name,size=`${this.allowMaxFileSize/1e3/1e3}MB`,message=this.translate.instant("__MESSAGE__.MAX_FILE_SIZE",{name,size});this.snackBar.open(message,void 0,{duration:3e3}),this.clearFileInput(),files=[];break}else if(this.imageSize&&this.isFileTypeImage(file)){let{height,width}=yield getHeightAndWidthFromDataUrl(previewSrc);if(this.isAllowedImageHeightAndWidth(height,width)){let actual=`${width} x ${height}px`,expected=`${this.imageSize?.width} x ${this.imageSize?.height}px`,message=this.translate.instant("__MESSAGE__.INVALID_IMAGE_SIZE",{actual,expected});this.snackBar.open(message,void 0,{duration:3e3}),this.clearFileInput(),files=[];break}else files.push({file,previewSrc})}else files.push({file,previewSrc})}this.multiple?this.fileChanges.emit(files):this.fileChange.emit(files.length?files[0]:null)}else this.multiple?this.fileChanges.emit([]):this.fileChange.emit(null)})}clearFileInput(){this.fileInputRef.nativeElement.value=null}getDefaultLabel(){return"Choose file"}isAllowedFileSize(fileSize){return fileSize<=this.allowMaxFileSize}isAllowedFileType(fileType){return this.allowedMimeTypes!==void 0?this.allowedMimeTypes.includes(fileType):!0}isAllowedImageHeightAndWidth(height,width){return this.imageSize===void 0?!0:!(this.imageSize.height===height&&this.imageSize.width===width)}isFileTypeImage(file){return file.type.includes("image")}get allowMaxFileSize(){return this.maxFileSize??MAX_FILE_SIZE}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||FileUploadButtonComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:FileUploadButtonComponent2,selectors:[["ix-file-upload-button"]],viewQuery:function(rf,ctx){if(rf&1&&\u0275\u0275viewQuery(_c012,7),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.fileInputRef=_t.first)}},inputs:{allowedMimeTypes:"allowedMimeTypes",multiple:"multiple",matButtonType:"matButtonType",color:"color",imageSize:"imageSize",label:"label",maxFileSize:"maxFileSize"},outputs:{fileChange:"fileChange",fileChanges:"fileChanges"},features:[\u0275\u0275NgOnChangesFeature],ngContentSelectors:_c14,decls:9,vars:3,consts:[["fileInput",""],["innerContent",""],["type","file","hidden","","onclick","this.value = null",3,"change","accept","multiple"],["mat-raised-button","","type","button",3,"color"],["mat-stroked-button","","type","button",3,"color"],["mat-flat-button","","type","button",3,"color"],["mat-menu-item","","type","button"],["mat-button","","type","button",3,"color"],["mat-raised-button","","type","button",3,"click","color"],[4,"ngTemplateOutlet"],["mat-stroked-button","","type","button",3,"click","color"],["mat-flat-button","","type","button",3,"click","color"],["mat-menu-item","","type","button",3,"click"],["mat-button","","type","button",3,"click","color"]],template:function(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275projectionDef(),\u0275\u0275elementStart(0,"input",2,0),\u0275\u0275listener("change",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.change($event))}),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(2,FileUploadButtonComponent_Case_2_Template,2,2,"button",3)(3,FileUploadButtonComponent_Case_3_Template,2,2,"button",4)(4,FileUploadButtonComponent_Case_4_Template,2,2,"button",5)(5,FileUploadButtonComponent_Case_5_Template,2,1,"button",6)(6,FileUploadButtonComponent_Case_6_Template,2,2,"button",7),\u0275\u0275template(7,FileUploadButtonComponent_ng_template_7_Template,1,0,"ng-template",null,1,\u0275\u0275templateRefExtractor)}if(rf&2){let tmp_4_0;\u0275\u0275property("accept",ctx.allowedMimeTypes)("multiple",ctx.multiple),\u0275\u0275advance(2),\u0275\u0275conditional((tmp_4_0=ctx.matButtonType)==="raised"?2:tmp_4_0==="stroked"?3:tmp_4_0==="flat"?4:tmp_4_0==="menu"?5:6)}},dependencies:[NgTemplateOutlet,MatButtonModule,MatButton,MatFormFieldModule,MatMenuModule,MatMenuItem,MatSnackBarModule],styles:["[_nghost-%COMP%]{--mat-button-outlined-container-height: 36px}[_nghost-%COMP%] .container[_ngcontent-%COMP%]{position:relative}[_nghost-%COMP%] .content[_ngcontent-%COMP%]{display:inline-block;margin:8px}[_nghost-%COMP%] input[type=file][_ngcontent-%COMP%]{appearance:initial;background-color:initial;cursor:default;align-items:baseline;color:inherit;text-align:start!important;padding:initial;border:initial}"],changeDetection:0})}}return FileUploadButtonComponent2})();function formatBytesValue(value,locale,decimals=2){let chars=["","k","M","G","T","P"],i=0;for(;value>=950&&i<chars.length-1;)value/=1e3,i++;return`${new Intl.NumberFormat(locale,{maximumFractionDigits:decimals}).format(value)} ${chars[i]}B`}var ByteFormatPipe=(()=>{class ByteFormatPipe3{transform(bytes){return formatBytesValue(bytes,Settings.defaultLocale)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ByteFormatPipe3)}}static{this.\u0275pipe=\u0275\u0275definePipe({name:"byteFormat",type:ByteFormatPipe3,pure:!0})}}return ByteFormatPipe3})();var _c013=["*"];function FileUploadDropContainerComponent_Conditional_4_Template(rf,ctx){if(rf&1&&\u0275\u0275element(0,"img",3),rf&2){let ctx_r1=\u0275\u0275nextContext();\u0275\u0275property("src",ctx_r1.filePreviewSrc,\u0275\u0275sanitizeUrl)}}function FileUploadDropContainerComponent_Conditional_17_For_2_Template(rf,ctx){if(rf&1){let _r3=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-list-item",8)(1,"mat-icon",9),\u0275\u0275text(2,"draft"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"div",10),\u0275\u0275text(4),\u0275\u0275elementEnd(),\u0275\u0275elementStart(5,"div",11),\u0275\u0275text(6),\u0275\u0275pipe(7,"byteFormat"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(8,"span",12)(9,"button",13),\u0275\u0275listener("click",function(){let \u0275$index_29_r4=\u0275\u0275restoreView(_r3).$index,ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.removeFileFromList(\u0275$index_29_r4))}),\u0275\u0275elementStart(10,"mat-icon"),\u0275\u0275text(11,"close"),\u0275\u0275elementEnd()()()()}if(rf&2){let f_r5=ctx.$implicit;\u0275\u0275advance(4),\u0275\u0275textInterpolate(f_r5.name),\u0275\u0275advance(2),\u0275\u0275textInterpolate(\u0275\u0275pipeBind1(7,2,f_r5.size))}}function FileUploadDropContainerComponent_Conditional_17_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-list"),\u0275\u0275repeaterCreate(1,FileUploadDropContainerComponent_Conditional_17_For_2_Template,12,4,"mat-list-item",8,\u0275\u0275repeaterTrackByIdentity),\u0275\u0275elementEnd()),rf&2){let ctx_r1=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275repeater(ctx_r1.files)}}var FileUploadDropContainerComponent=(()=>{class FileUploadDropContainerComponent2 extends FileUploadButtonComponent{constructor(){super(...arguments),this.multiple=!1,this.maxFileSize=MAX_FILE_SIZE,this.fileChange=new EventEmitter,this.fileChanges=new EventEmitter,this.fileRemove=new EventEmitter,this.cdRef=inject(ChangeDetectorRef),this.files=[]}change(event2){return __async(this,null,function*(){this.files=getFilesFromEvent(event2),this.cdRef.detectChanges(),yield __superGet(FileUploadDropContainerComponent2.prototype,this,"change").call(this,event2)})}dropHandler(event2){event2.preventDefault(),this.change(event2)}dragOverHandler(event2){event2.stopPropagation(),event2.preventDefault()}fileChangeHandler(event2){this.files=event2?.file?[event2.file]:[],this.cdRef.detectChanges(),this.fileChange.emit(event2)}fileChangesHandler(event2){this.files=[...this.files,...event2.map(event3=>event3.file)],this.cdRef.detectChanges(),this.fileChanges.emit(event2)}removeFileFromList(index){let[file]=this.files.splice(index,1);this.fileRemove.emit({file})}static{this.\u0275fac=(()=>{let \u0275FileUploadDropContainerComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275FileUploadDropContainerComponent_BaseFactory||(\u0275FileUploadDropContainerComponent_BaseFactory=\u0275\u0275getInheritedFactory(FileUploadDropContainerComponent2)))(__ngFactoryType__||FileUploadDropContainerComponent2)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:FileUploadDropContainerComponent2,selectors:[["ix-file-upload-drop-container"]],inputs:{multiple:"multiple",filePreviewSrc:"filePreviewSrc",maxFileSize:"maxFileSize"},outputs:{fileChange:"fileChange",fileChanges:"fileChanges",fileRemove:"fileRemove"},features:[\u0275\u0275InheritDefinitionFeature],ngContentSelectors:_c013,decls:18,vars:20,consts:[["content",""],["fxLayout","column","fxLayoutAlign","center center","data-testid","drop-container",1,"drop-container",3,"drop","dragover"],["fxLayout","column","fxLayoutAlign","center center"],[1,"image",3,"src"],["fxLayout","column","fxLayoutAlign","center center",1,"ix-surface"],[1,"icon"],["translate",""],[3,"fileChange","fileChanges","multiple","allowedMimeTypes","maxFileSize","imageSize","matButtonType","color"],["fxLayoutAlign","start center"],["matListItemIcon",""],["matListItemTitle",""],["matListItemLine",""],["matListItemMeta",""],["type","button","mat-icon-button","",3,"click"]],template:function(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275projectionDef(),\u0275\u0275elementStart(0,"div",1),\u0275\u0275listener("drop",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.dropHandler($event))})("dragover",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.dragOverHandler($event))}),\u0275\u0275elementStart(1,"div",2,0),\u0275\u0275projection(3),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(4,FileUploadDropContainerComponent_Conditional_4_Template,1,1,"img",3),\u0275\u0275elementStart(5,"span",4)(6,"mat-icon",5),\u0275\u0275text(7,"cloud_upload"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(8,"span",6),\u0275\u0275text(9,"DRAG_AND_DROP_TO_UPLOAD"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(10,"span"),\u0275\u0275text(11),\u0275\u0275pipe(12,"translate"),\u0275\u0275pipe(13,"lowercase"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(14,"ix-file-upload-button",7),\u0275\u0275listener("fileChange",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.fileChangeHandler($event))})("fileChanges",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.fileChangesHandler($event))}),\u0275\u0275text(15),\u0275\u0275pipe(16,"translate"),\u0275\u0275elementEnd()()(),\u0275\u0275conditionalCreate(17,FileUploadDropContainerComponent_Conditional_17_Template,3,0,"mat-list")}if(rf&2){let content_r6=\u0275\u0275reference(2);\u0275\u0275classProp("minimize-height",ctx.multiple&&ctx.files.length),\u0275\u0275advance(4),\u0275\u0275conditional(ctx.filePreviewSrc&&!content_r6.children.length?4:-1),\u0275\u0275advance(),\u0275\u0275classProp("invisible",ctx.files.length&&!ctx.multiple),\u0275\u0275advance(6),\u0275\u0275textInterpolate(\u0275\u0275pipeBind1(13,16,\u0275\u0275pipeBind1(12,14,"OR"))),\u0275\u0275advance(3),\u0275\u0275property("multiple",ctx.multiple)("allowedMimeTypes",ctx.allowedMimeTypes)("maxFileSize",ctx.maxFileSize)("imageSize",ctx.imageSize)("matButtonType","stroked")("color",null),\u0275\u0275advance(),\u0275\u0275textInterpolate1(" ",\u0275\u0275pipeBind1(16,18,ctx.multiple?"SELECT_FILES_TO_UPLOAD":"SELECT_FILE_TO_UPLOAD")," "),\u0275\u0275advance(2),\u0275\u0275conditional(ctx.multiple&&ctx.files.length?17:-1)}},dependencies:[MatButtonModule,MatIconButton,MatFormFieldModule,MatIconModule,MatIcon,MatListModule,MatList,MatListItem,MatListItemIcon,MatListItemLine,MatListItemTitle,MatListItemMeta,MatSnackBarModule,FileUploadButtonComponent,FormsModule,TranslateModule,TranslateDirective,FlexModule,DefaultLayoutDirective,DefaultLayoutAlignDirective,ByteFormatPipe,TranslatePipe,LowerCasePipe],styles:["[_nghost-%COMP%] .drop-container[_ngcontent-%COMP%]{position:relative;min-height:300px;overflow:hidden;border-radius:6px;background:var(--mat-sys-outline-variant)}[_nghost-%COMP%] .drop-container.minimize-height[_ngcontent-%COMP%]{min-height:150px}[_nghost-%COMP%] .drop-container[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{width:36px;height:36px;margin:4px 0;font-size:36px;color:var(--body-color)}[_nghost-%COMP%] .drop-container[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{margin-bottom:4px}[_nghost-%COMP%] .drop-container[_ngcontent-%COMP%] .invisible[_ngcontent-%COMP%]{background:color-mix(in srgb,var(--mat-sys-surface-variant) 92%,transparent);opacity:0;transition:opacity .1s ease-out;will-change:opacity}[_nghost-%COMP%] .drop-container[_ngcontent-%COMP%]:hover .invisible[_ngcontent-%COMP%], [_nghost-%COMP%] .drop-container[_ngcontent-%COMP%]:focus .invisible[_ngcontent-%COMP%]{opacity:1;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}[_nghost-%COMP%] .image[_ngcontent-%COMP%]{max-height:200px;max-width:200px}[_nghost-%COMP%] .mat-mdc-list-item[_ngcontent-%COMP%]{--mat-list-list-item-leading-icon-color: var(--mat-list-list-item-label-text-color);--mat-list-list-item-hover-leading-icon-color: var(--mat-list-list-item-hover-label-text-color);--mat-list-list-item-trailing-supporting-text-color: var(--mat-list-list-item-label-text-color);padding:0}[_nghost-%COMP%] .mat-mdc-list-item[_ngcontent-%COMP%] .mdc-list-item__content{margin-right:0!important}[_nghost-%COMP%] .mat-mdc-list-item[_ngcontent-%COMP%] .mdc-list-item__end[_ngcontent-%COMP%]{margin:15px 0 0 16px}[_nghost-%COMP%] .mat-mdc-list-item[_ngcontent-%COMP%] .mdc-list-item__start[_ngcontent-%COMP%]{margin:23px 16px 0 0}[_nghost-%COMP%] .mat-mdc-list-item[_ngcontent-%COMP%] .file-name[_ngcontent-%COMP%]{color:rgba(var(--body-color-rgb),.87);white-space:nowrap;text-overflow:ellipsis;overflow:hidden}[_nghost-%COMP%] .mat-mdc-list-item[_ngcontent-%COMP%] .file-size[_ngcontent-%COMP%]{font-size:12px}"],changeDetection:0})}}return FileUploadDropContainerComponent2})();function FileInputComponent_Conditional_1_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-icon",1),\u0275\u0275text(1),\u0275\u0275elementEnd()),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275textInterpolate(ctx_r0.icon)}}function FileInputComponent_Conditional_2_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"p",2),\u0275\u0275text(1),\u0275\u0275elementStart(2,"strong"),\u0275\u0275text(3),\u0275\u0275pipe(4,"byteFormat"),\u0275\u0275elementEnd(),\u0275\u0275text(5," ) "),\u0275\u0275elementEnd()),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275textInterpolate1(" ",ctx_r0.file.name," ( "),\u0275\u0275advance(2),\u0275\u0275textInterpolate(\u0275\u0275pipeBind1(4,2,ctx_r0.file.size))}}var FileInputComponent=(()=>{class FileInputComponent3 extends ComponentInputComponent{fileChange(changes){changes&&(this.inputControl?.setValue(changes.file),this.inputControl?.markAsDirty())}fileChanges(changes){changes?.length&&(this.inputControl?.setValue([...this.inputControl.value||[],...changes.map(fileEvent=>fileEvent.file)]),this.inputControl?.markAsDirty())}fileRemove(changes){changes.file&&(this.inputControl?.setValue([...(this.inputControl.value||[]).filter(file=>file!==changes.file)]),this.inputControl?.markAsDirty())}get icon(){if(this.inputControl?.value?.type)return mapMimeTypeToIcon(this.inputControl.value.type)}get maxSize(){return this.field.inputDescription.size?.max??MAX_FILE_SIZE}get multiple(){return this.field.inputDescription.multiple??!1}get file(){return Array.isArray(this.inputControl?.value)?null:this.inputControl?.value||null}static{this.\u0275fac=(()=>{let \u0275FileInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275FileInputComponent_BaseFactory||(\u0275FileInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(FileInputComponent3)))(__ngFactoryType__||FileInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:FileInputComponent3,selectors:[["ix-file-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:3,vars:5,consts:[["data-testid","drop-container",3,"fileChange","fileChanges","fileRemove","filePreviewSrc","maxFileSize","multiple"],[1,"icon"],["data-testid","file-info"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"ix-file-upload-drop-container",0),\u0275\u0275listener("fileChange",function($event){return ctx.fileChange($event)})("fileChanges",function($event){return ctx.fileChanges($event)})("fileRemove",function($event){return ctx.fileRemove($event)}),\u0275\u0275conditionalCreate(1,FileInputComponent_Conditional_1_Template,2,1,"mat-icon",1),\u0275\u0275conditionalCreate(2,FileInputComponent_Conditional_2_Template,6,4,"p",2),\u0275\u0275elementEnd()),rf&2&&(\u0275\u0275property("filePreviewSrc",null)("maxFileSize",ctx.maxSize)("multiple",ctx.multiple),\u0275\u0275advance(),\u0275\u0275conditional(ctx.icon?1:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.file?2:-1))},dependencies:[FileUploadDropContainerComponent,MatIcon,ByteFormatPipe],styles:["[_nghost-%COMP%] .icon[_ngcontent-%COMP%]{width:36px;height:36px;margin:4px 0;font-size:36px;color:var(--body-color)}[_nghost-%COMP%] span[_ngcontent-%COMP%]{margin-bottom:4px}"]})}}return FileInputComponent3})();function GroupInputFormComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function GroupInputFormComponent_ng_template_1_Template(rf,ctx){}var GroupInputFormComponent=(()=>{class GroupInputFormComponent3 extends ComponentInputComponent{constructor(cdRef,inputConverter){super(),this.cdRef=cdRef,this.inputConverter=inputConverter}ngAfterViewInit(){this.formDirective.viewContainerRef.clear(),this.inputConverter.loadComponentInputs(this.field.children,this.componentFormGroup.get(this.field.inputDescription.key),this.formDirective.viewContainerRef),this.cdRef.detectChanges()}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||GroupInputFormComponent3)(\u0275\u0275directiveInject(ChangeDetectorRef),\u0275\u0275directiveInject(INPUT_CONVERTER_TOKEN))}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:GroupInputFormComponent3,selectors:[["ix-group-input-form"]],viewQuery:function(rf,ctx){if(rf&1&&\u0275\u0275viewQuery(InputControlFormDirective,5),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.formDirective=_t.first)}},inputs:{field:"field",componentFormGroup:"componentFormGroup"},standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:2,vars:1,consts:[[1,"description",3,"innerHTML"],["ixInputControlForm",""]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,GroupInputFormComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275template(1,GroupInputFormComponent_ng_template_1_Template,0,0,"ng-template",1)),rf&2&&\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1)},dependencies:[InputControlFormDirective,RenderMarkdownPipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] h3[_ngcontent-%COMP%]{font-size:11.5px!important;font-weight:500!important;text-transform:uppercase;letter-spacing:.8px;color:color-mix(in srgb,transparent,currentcolor 67%)}[_nghost-%COMP%] .mat-divider[_ngcontent-%COMP%]{margin:0 -16px 16px}[_nghost-%COMP%] .mat-divider.mat-divider-inset[_ngcontent-%COMP%]{margin-left:0}[_nghost-%COMP%] + *[_ngcontent-%COMP%]{border-top:1px solid var(--mat-sys-outline-variant)}"]})}}return GroupInputFormComponent3})();var GroupInputDialogComponent=(()=>{class GroupInputDialogComponent3{constructor(data){this.data=data}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||GroupInputDialogComponent3)(\u0275\u0275directiveInject(MAT_DIALOG_DATA))}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:GroupInputDialogComponent3,selectors:[["ix-group-input-dialog"]],standalone:!1,decls:11,vars:6,consts:[["mat-dialog-title",""],[3,"field","componentFormGroup"],["align","end"],["mat-button","",3,"mat-dialog-close"],["translate",""],["mat-button","",3,"mat-dialog-close","disabled"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"h1",0),\u0275\u0275text(1),\u0275\u0275elementEnd(),\u0275\u0275elementStart(2,"mat-dialog-content"),\u0275\u0275element(3,"ix-group-input-form",1),\u0275\u0275elementEnd(),\u0275\u0275elementStart(4,"mat-dialog-actions",2)(5,"button",3)(6,"span",4),\u0275\u0275text(7,"CANCEL"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(8,"button",5)(9,"span",4),\u0275\u0275text(10,"OK"),\u0275\u0275elementEnd()()()),rf&2&&(\u0275\u0275advance(),\u0275\u0275textInterpolate(ctx.data.field.inputDescription.label),\u0275\u0275advance(2),\u0275\u0275property("field",ctx.data.field)("componentFormGroup",ctx.data.componentFormGroup),\u0275\u0275advance(2),\u0275\u0275property("mat-dialog-close",!1),\u0275\u0275advance(3),\u0275\u0275property("mat-dialog-close",!0)("disabled",!ctx.data.componentFormGroup.valid))},dependencies:[TranslateDirective,MatButton,MatDialogClose,MatDialogTitle,MatDialogActions,MatDialogContent,GroupInputFormComponent],encapsulation:2})}}return GroupInputDialogComponent3})();var GroupInputSummaryComponent=(()=>{class GroupInputSummaryComponent3 extends ComponentInputComponent{constructor(dialog,cdRef){super(),this.dialog=dialog,this.cdRef=cdRef}get fieldValue(){return this.componentFormGroup.value[this.field.inputDescription.key]}get hasValidationErrors(){let control=this.componentFormGroup.controls[this.field.inputDescription.key];return!this.isGroupValidRecursively(control)}get summary(){let labelTemplate=this.field.inputDescription?.summary?.label;if(labelTemplate)return mustache_default.render(labelTemplate,this.field.transformValue()[this.field.inputDescription.key],void 0,{escape:input2=>input2})}get summaryTooltipDisabled(){return(this.summary?.length||0)<20}get color(){let colorField=this.field.inputDescription?.summary?.colorField;if(colorField)return get_default(this.fieldValue,colorField)}openDialog(){let key=this.field.inputDescription.key,dialogForm=new FormGroup({[key]:this.field.toFormControl()});this.addDialogValuesWithoutNeedingRefreshAfterChange(dialogForm),this.dialog.open(GroupInputDialogComponent,{width:"500px",data:{field:this.field,componentFormGroup:dialogForm}}).afterClosed().subscribe(result=>{result&&(this.field.setValue(dialogForm.value[key]),this.componentFormGroup.markAsDirty(),this.componentFormGroup.setControl(key,dialogForm.controls[key]),this.cdRef.detectChanges())})}calculateStyle(){return{"background-color":this.color||"white"}}addDialogValuesWithoutNeedingRefreshAfterChange(dialogForm){dialogForm.patchValue(this.componentFormGroup.value)}isGroupValidRecursively(group){return group.valid&&Object.keys(group.controls).every(k=>{let subControl=group.controls[k];return subControl instanceof FormArray||subControl instanceof FormGroup?this.isGroupValidRecursively(subControl):subControl.valid})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||GroupInputSummaryComponent3)(\u0275\u0275directiveInject(MatDialog),\u0275\u0275directiveInject(ChangeDetectorRef))}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:GroupInputSummaryComponent3,selectors:[["ix-group-input-summary"]],hostVars:2,hostBindings:function(rf,ctx){rf&2&&\u0275\u0275classProp("has-validation-errors",ctx.hasValidationErrors)},inputs:{field:"field",componentFormGroup:"componentFormGroup"},standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:7,vars:5,consts:[["mat-icon-button","","type","button",3,"click"],[1,"color-patch"],[1,"summary-wrapper"],[1,"summary",3,"matTooltip","matTooltipDisabled"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"button",0),\u0275\u0275listener("click",function(){return ctx.openDialog()}),\u0275\u0275elementStart(1,"mat-icon"),\u0275\u0275text(2,"create"),\u0275\u0275elementEnd()(),\u0275\u0275element(3,"span",1),\u0275\u0275elementStart(4,"span",2)(5,"span",3),\u0275\u0275text(6),\u0275\u0275elementEnd()()),rf&2&&(\u0275\u0275advance(3),\u0275\u0275styleMap(ctx.calculateStyle()),\u0275\u0275advance(2),\u0275\u0275property("matTooltip",ctx.summary||"")("matTooltipDisabled",ctx.summaryTooltipDisabled),\u0275\u0275advance(),\u0275\u0275textInterpolate(ctx.summary))},dependencies:[MatIconButton,MatIcon,MatTooltip],styles:["[_nghost-%COMP%]{display:flex;background-color:rgba(var(--body-color-rgb),.04)}.has-validation-errors[_nghost-%COMP%]{border:thin solid var(--warn);color:var(--warn)}[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}[_nghost-%COMP%] .color-patch[_ngcontent-%COMP%]{display:inline-block;vertical-align:top;height:40px;width:8px}[_nghost-%COMP%] .summary-wrapper[_ngcontent-%COMP%]{display:flex;align-items:center;padding:0 8px;overflow:hidden;flex:1}[_nghost-%COMP%] .summary-wrapper[_ngcontent-%COMP%] .summary[_ngcontent-%COMP%]{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}"]})}}return GroupInputSummaryComponent3})();function GroupInputComponent_Conditional_0_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"h3"),\u0275\u0275text(1),\u0275\u0275elementEnd()),rf&2){let ctx_r0=\u0275\u0275nextContext(2);\u0275\u0275advance(),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.label)}}function GroupInputComponent_Conditional_0_Conditional_1_Template(rf,ctx){if(rf&1&&\u0275\u0275element(0,"ix-group-input-summary",0),rf&2){let ctx_r0=\u0275\u0275nextContext(2);\u0275\u0275property("field",ctx_r0.field)("componentFormGroup",ctx_r0.componentFormGroup)}}function GroupInputComponent_Conditional_0_Conditional_2_Template(rf,ctx){if(rf&1&&\u0275\u0275element(0,"ix-group-input-form",0),rf&2){let ctx_r0=\u0275\u0275nextContext(2);\u0275\u0275property("field",ctx_r0.field)("componentFormGroup",ctx_r0.componentFormGroup)}}function GroupInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275conditionalCreate(0,GroupInputComponent_Conditional_0_Conditional_0_Template,2,1,"h3"),\u0275\u0275conditionalCreate(1,GroupInputComponent_Conditional_0_Conditional_1_Template,1,2,"ix-group-input-summary",0)(2,GroupInputComponent_Conditional_0_Conditional_2_Template,1,2,"ix-group-input-form",0)),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275conditional(ctx_r0.field.level===0||!ctx_r0.isSummary()?0:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.isSummary()?1:2)}}var GroupInputComponent=(()=>{class GroupInputComponent3 extends ComponentInputComponent{isSummary(){return this.field.inputDescription.summary!==void 0}static{this.\u0275fac=(()=>{let \u0275GroupInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275GroupInputComponent_BaseFactory||(\u0275GroupInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(GroupInputComponent3)))(__ngFactoryType__||GroupInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:GroupInputComponent3,selectors:[["ix-group-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,consts:[[3,"field","componentFormGroup"]],template:function(rf,ctx){rf&1&&\u0275\u0275conditionalCreate(0,GroupInputComponent_Conditional_0_Template,3,2),rf&2&&\u0275\u0275conditional(ctx.field.hidden?-1:0)},dependencies:[GroupInputFormComponent,GroupInputSummaryComponent],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] h3[_ngcontent-%COMP%]{font-size:11.5px!important;font-weight:500!important;text-transform:uppercase;letter-spacing:.8px;color:color-mix(in srgb,transparent,currentcolor 67%)}[_nghost-%COMP%] .mat-divider[_ngcontent-%COMP%]{margin:0 -16px 16px}[_nghost-%COMP%] .mat-divider.mat-divider-inset[_ngcontent-%COMP%]{margin-left:0}"]})}}return GroupInputComponent3})();var GroupInput=class extends ComponentPropertiesInput{constructor(input2,value,context3,converter,level){super(input2,value,context3,converter,level),this.converter=converter,this.children=input2.children?.map(child=>converter.convertInput(child,value,context3,level+1))||[],this.hidden=this.children.some(child=>child.inputDescription.required&&child.hidden)}toFormControl(){return new FormGroup(this.converter.getFormControls(this.children))}transformValue(){return{[this.inputDescription.key]:this.children.reduce((obj,child)=>__spreadValues(__spreadValues({},obj),child.transformValue()),{})}}setValue(value){this.children.forEach(child=>child.setValue(value[child.inputDescription.key]))}};function IconInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function IconInputComponent_Conditional_13_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",6),\u0275\u0275text(1,"__MESSAGE__.REQUIRED"),\u0275\u0275elementEnd())}var IconInputComponent=(()=>{class IconInputComponent3 extends ComponentInputComponent{static{this.\u0275fac=(()=>{let \u0275IconInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275IconInputComponent_BaseFactory||(\u0275IconInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(IconInputComponent3)))(__ngFactoryType__||IconInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:IconInputComponent3,selectors:[["ix-icon-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:14,vars:7,consts:[[1,"description",3,"innerHTML"],[3,"formGroup"],[3,"formControlName","placeholder"],["value","warn"],["value","info"],["value","error"],["translate",""]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,IconInputComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275elementStart(1,"mat-form-field",1)(2,"mat-label"),\u0275\u0275text(3),\u0275\u0275elementEnd(),\u0275\u0275elementStart(4,"mat-select",2)(5,"mat-option",3),\u0275\u0275text(6,"Warning"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(7,"mat-option",4),\u0275\u0275text(8,"Info"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(9,"mat-option",5),\u0275\u0275text(10,"Error"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(11,"mat-hint"),\u0275\u0275text(12),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(13,IconInputComponent_Conditional_13_Template,2,0,"mat-error",6),\u0275\u0275elementEnd()),rf&2&&(\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(),\u0275\u0275property("formGroup",ctx.componentFormGroup),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("formControlName",ctx.field.inputName)("placeholder",ctx.field.inputDescription.placeholder||""),\u0275\u0275advance(8),\u0275\u0275textInterpolate(ctx.field.inputDescription.hint),\u0275\u0275advance(),\u0275\u0275conditional(ctx.inputControl!=null&&ctx.inputControl.hasError("required")?13:-1))},dependencies:[NgControlStatus,NgControlStatusGroup,FormGroupDirective,FormControlName,TranslateDirective,MatOption,MatFormField,MatLabel,MatHint,MatError,MatSelect,RenderMarkdownPipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{width:100%}"]})}}return IconInputComponent3})();function ImageInputDialogComponent_Conditional_11_Template(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",12),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.clear())}),\u0275\u0275elementStart(1,"span",10),\u0275\u0275text(2,"CLEAR"),\u0275\u0275elementEnd()()}}var ImageInputDialogComponent=(()=>{class ImageInputDialogComponent3{constructor(){this.data=inject(MAT_DIALOG_DATA),this.dialogRef=inject(MatDialogRef),this.formBuilder=inject(FormBuilder),this.allowedMimeTypes=["image/gif","image/jpeg","image/png","image/webp"]}ngOnInit(){this.form=this.formBuilder.group({image:[this.data.image]})}clear(){this.file=null,this.form.controls.image.reset(),this.form.controls.image.markAsDirty()}fileChange(changes){changes&&(this.file=changes.file,this.form.controls.image.setValue(changes.previewSrc),this.form.controls.image.markAsDirty())}submit(){this.dialogRef.close({image:this.form.controls.image.value,file:this.file})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ImageInputDialogComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ImageInputDialogComponent3,selectors:[["ix-image-input-dialog"]],standalone:!1,decls:19,vars:5,consts:[["autocomplete","off",3,"ngSubmit","formGroup"],[1,"ix-dialog__header"],["fxFlex","","mat-dialog-title",""],["mat-icon-button","","mat-dialog-close",""],["mat-dialog-content",""],[3,"fileChange","filePreviewSrc"],["mat-dialog-actions",""],["type","button","mat-button","","color","warn"],["fxFlex",""],["mat-button","","mat-dialog-close",""],["translate",""],["type","submit","mat-button","",3,"disabled"],["type","button","mat-button","","color","warn",3,"click"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"form",0),\u0275\u0275listener("ngSubmit",function(){return ctx.submit()}),\u0275\u0275elementStart(1,"div",1)(2,"mat-toolbar")(3,"h1",2),\u0275\u0275text(4),\u0275\u0275elementEnd(),\u0275\u0275elementStart(5,"button",3)(6,"mat-icon"),\u0275\u0275text(7,"close"),\u0275\u0275elementEnd()()()(),\u0275\u0275elementStart(8,"div",4)(9,"ix-file-upload-drop-container",5),\u0275\u0275listener("fileChange",function($event){return ctx.fileChange($event)}),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(10,"div",6),\u0275\u0275conditionalCreate(11,ImageInputDialogComponent_Conditional_11_Template,3,0,"button",7),\u0275\u0275element(12,"span",8),\u0275\u0275elementStart(13,"button",9)(14,"span",10),\u0275\u0275text(15,"CANCEL"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(16,"button",11)(17,"span",10),\u0275\u0275text(18,"CONFIRM"),\u0275\u0275elementEnd()()()()),rf&2&&(\u0275\u0275property("formGroup",ctx.form),\u0275\u0275advance(4),\u0275\u0275textInterpolate(ctx.data.title),\u0275\u0275advance(5),\u0275\u0275property("filePreviewSrc",ctx.form.value.image),\u0275\u0275advance(2),\u0275\u0275conditional(ctx.form.value.image?11:-1),\u0275\u0275advance(5),\u0275\u0275property("disabled",ctx.form.pristine||ctx.form.invalid))},dependencies:[FileUploadDropContainerComponent,DefaultFlexDirective,\u0275NgNoValidate,NgControlStatusGroup,FormGroupDirective,TranslateDirective,MatButton,MatIconButton,MatDialogClose,MatDialogTitle,MatDialogActions,MatDialogContent,MatIcon,MatToolbar],styles:["[_nghost-%COMP%]{width:100dvw;height:100dvh;display:flex;flex-direction:column;flex:1}@media (min-width: 960px){[_nghost-%COMP%]{height:auto;width:auto;min-width:528px;max-width:528px}}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%]{padding:calc(env(safe-area-inset-top,0) + 16px) 24px 16px}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] .mat-toolbar{height:48px;padding-left:0;padding-right:0}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] .mat-toolbar .mdc-dialog__title{--mat-dialog-headline-padding: 0;color:inherit}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] .mat-toolbar .mdc-dialog__title:before{display:none}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] + .ix-dialog__content[_ngcontent-%COMP%], [_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] + .mdc-dialog__content[_ngcontent-%COMP%]{padding-top:0}[_nghost-%COMP%] .mdc-dialog__title[_ngcontent-%COMP%]:before{height:calc(env(safe-area-inset-top,0) + 40px)}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%]{padding:20px 24px}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%] > .ix-list[_ngcontent-%COMP%]{margin-left:-24px;margin-right:-24px}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%], [_nghost-%COMP%] .mdc-dialog__content[_ngcontent-%COMP%]{flex-direction:column;box-sizing:border-box;display:flex;place-content:stretch flex-start;align-items:stretch;flex:1 1 auto;max-height:none;overflow:auto;-webkit-overflow-scrolling:touch}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%] > .mat-mdc-subheader[_ngcontent-%COMP%], [_nghost-%COMP%] .mdc-dialog__content[_ngcontent-%COMP%] > .mat-mdc-subheader[_ngcontent-%COMP%]{margin-left:0;margin-right:0}@media (min-width: 960px){[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%], [_nghost-%COMP%] .mdc-dialog__content[_ngcontent-%COMP%]{max-height:calc(90dvh - 140px)}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%]:has(+.mdc-dialog__actions), [_nghost-%COMP%] .mdc-dialog__content[_ngcontent-%COMP%]:has(+.mdc-dialog__actions){padding-bottom:0}}@media (min-width: 960px){[_nghost-%COMP%] .ix-dialog__banner[_ngcontent-%COMP%] + .ix-dialog__content[_ngcontent-%COMP%]{max-height:calc(90dvh - 225px)}}@media (max-width: 959.9px){[_nghost-%COMP%] .mdc-dialog__actions[_ngcontent-%COMP%]{border-top:1px solid rgba(0,0,0,.12);padding-bottom:calc(16px + env(safe-area-inset-bottom,0))}}[_nghost-%COMP%] form[_ngcontent-%COMP%]{flex-direction:column;box-sizing:border-box;display:flex;flex:1 1 auto;height:inherit}[_nghost-%COMP%] form[_ngcontent-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{margin-bottom:1rem}[_nghost-%COMP%] .mdc-dialog__content[_ngcontent-%COMP%]{padding-bottom:24px}"]})}}return ImageInputDialogComponent3})();function ImageInputFormComponent_Conditional_0_Template(rf,ctx){if(rf&1&&\u0275\u0275element(0,"img",0),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("src",ctx_r0.value,\u0275\u0275sanitizeUrl)}}var ImageInputFormComponent=(()=>{class ImageInputFormComponent3{constructor(){this.dialog=inject(MatDialog),this.fileService=inject(FileService),this.onChange=()=>{},this.onTouched=()=>{}}registerOnChange(fn2){this.onChange=fn2}registerOnTouched(fn2){this.onTouched=fn2}writeValue(obj){this.value=obj,this.onChange(this.value)}openDialog(){this.dialog.open(ImageInputDialogComponent,{panelClass:"fullscreen",data:{image:this.value,title:this.dialogTitle}}).afterClosed().pipe(filter(data=>!!data),mergeMap(result=>this.uploadFile(result.file))).subscribe(url=>{this.writeValue(url),this.componentFormGroup.controls[this.field.inputName].setValue(url)})}uploadFile(file){return file?this.fileService.uploadPublic(file).pipe(map(response=>response.data.url)):of(null)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ImageInputFormComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ImageInputFormComponent3,selectors:[["ix-image-input-form"]],inputs:{field:"field",componentFormGroup:"componentFormGroup",dialogTitle:"dialogTitle"},standalone:!1,features:[\u0275\u0275ProvidersFeature([{provide:NG_VALUE_ACCESSOR,useExisting:ImageInputFormComponent3,multi:!0}])],decls:4,vars:1,consts:[["alt","uploaded image",3,"src"],["mat-stroked-button","","color","primary","type","button",3,"click"],["translate",""]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,ImageInputFormComponent_Conditional_0_Template,1,1,"img",0),\u0275\u0275elementStart(1,"button",1),\u0275\u0275listener("click",function(){return ctx.openDialog()}),\u0275\u0275elementStart(2,"span",2),\u0275\u0275text(3,"UPLOAD_FILE"),\u0275\u0275elementEnd()()),rf&2&&\u0275\u0275conditional(ctx.value?0:-1)},dependencies:[TranslateDirective,MatButton],styles:["[_nghost-%COMP%]{display:flex;place-content:center left;margin-bottom:16px}[_nghost-%COMP%] img[_ngcontent-%COMP%]{flex-grow:0;padding-right:8px;width:40px;height:40px;object-fit:contain}[_nghost-%COMP%] button[_ngcontent-%COMP%]{flex-grow:1}.ng-invalid[_nghost-%COMP%] button[_ngcontent-%COMP%]{border-color:var(--warn)}"]})}}return ImageInputFormComponent3})();function ImageInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}var ImageInputComponent=(()=>{class ImageInputComponent3 extends ComponentInputComponent{static{this.\u0275fac=(()=>{let \u0275ImageInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275ImageInputComponent_BaseFactory||(\u0275ImageInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(ImageInputComponent3)))(__ngFactoryType__||ImageInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ImageInputComponent3,selectors:[["ix-image-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:3,vars:6,consts:[[1,"description",3,"innerHTML"],[3,"formGroup"],[3,"field","componentFormGroup","formControlName","dialogTitle"]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,ImageInputComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275elementStart(1,"div",1),\u0275\u0275element(2,"ix-image-input-form",2),\u0275\u0275elementEnd()),rf&2&&(\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(),\u0275\u0275property("formGroup",ctx.componentFormGroup),\u0275\u0275advance(),\u0275\u0275property("field",ctx.field)("componentFormGroup",ctx.componentFormGroup)("formControlName",ctx.field.inputName)("dialogTitle",ctx.field.inputDescription.label||""))},dependencies:[NgControlStatus,NgControlStatusGroup,FormGroupDirective,FormControlName,ImageInputFormComponent,RenderMarkdownPipe],styles:["[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}"]})}}return ImageInputComponent3})();function moveItemInFormArray(array,fromIndex,toIndex){fromIndex=Math.max(0,Math.min(fromIndex,array.length-1)),toIndex=Math.max(0,Math.min(toIndex,array.length-1));let item=array.at(fromIndex);array.removeAt(fromIndex),array.insert(toIndex,item)}function ListItemComponent_ng_template_2_Template(rf,ctx){}var ListItemComponent=(()=>{class ListItemComponent3{constructor(inputConverter,cdRef){this.inputConverter=inputConverter,this.cdRef=cdRef,this.delete=new EventEmitter}ngAfterViewInit(){this.inputConverter.loadComponentInputs([this.item],this.componentFormGroup,this.formDirective.viewContainerRef),this.cdRef.detectChanges()}deleteItem(){this.delete.emit(this.index)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ListItemComponent3)(\u0275\u0275directiveInject(INPUT_CONVERTER_TOKEN),\u0275\u0275directiveInject(ChangeDetectorRef))}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ListItemComponent3,selectors:[["ix-list-item"]],viewQuery:function(rf,ctx){if(rf&1&&\u0275\u0275viewQuery(InputControlFormDirective,5),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.formDirective=_t.first)}},inputs:{item:"item",index:"index",componentFormGroup:"componentFormGroup"},outputs:{delete:"delete"},standalone:!1,decls:9,vars:0,consts:[["fxLayout","row"],["fxFlex","",1,"list-item-content"],["ixInputControlForm",""],["mat-icon-button","","type","button","aria-label","Remove list item",1,"clear-button",3,"click"],["fxLayout","column","fxLayoutAlign","center end"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"div",0)(1,"div",1),\u0275\u0275template(2,ListItemComponent_ng_template_2_Template,0,0,"ng-template",2),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"button",3),\u0275\u0275listener("click",function(){return ctx.deleteItem()}),\u0275\u0275elementStart(4,"mat-icon"),\u0275\u0275text(5,"clear"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(6,"div",4)(7,"mat-icon"),\u0275\u0275text(8,"drag_indicator"),\u0275\u0275elementEnd()()())},dependencies:[InputControlFormDirective,DefaultLayoutDirective,DefaultLayoutAlignDirective,DefaultFlexDirective,MatIconButton,MatIcon],styles:["[_nghost-%COMP%]{display:block;position:relative;font:400 14px/20px Roboto,Helvetica Neue,sans-serif;letter-spacing:normal}[_nghost-%COMP%] .clear-button[_ngcontent-%COMP%]{position:absolute;top:0;right:24px;bottom:0;opacity:0;transition:opacity .2s ease-in-out;will-change:opacity}[_nghost-%COMP%] .clear-button[_ngcontent-%COMP%]:hover{opacity:1!important}[_nghost-%COMP%] .list-item-content[_ngcontent-%COMP%]{overflow:hidden}[_nghost-%COMP%] .list-item-content[_ngcontent-%COMP%]:hover + .clear-button[_ngcontent-%COMP%]{opacity:1!important}.cdk-drag-preview[_nghost-%COMP%]{background-color:#fff}.cdk-drag-preview[_nghost-%COMP%] .clear-button[_ngcontent-%COMP%]{display:none}.cdk-drag-preview[_nghost-%COMP%] .list-item-content[_ngcontent-%COMP%]{box-sizing:border-box;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}"]})}}return ListItemComponent3})();function ListInputComponent_Conditional_0_Conditional_2_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r1.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function ListInputComponent_Conditional_0_For_5_Template(rf,ctx){if(rf&1){let _r3=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-list-item",4),\u0275\u0275listener("delete",function(){let \u0275$index_11_r4=\u0275\u0275restoreView(_r3).$index,ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.deleteItem(\u0275$index_11_r4))}),\u0275\u0275elementEnd()}if(rf&2){let item_r5=ctx.$implicit,\u0275$index_11_r4=ctx.$index,ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275property("item",item_r5)("index",\u0275$index_11_r4)("componentFormGroup",ctx_r1.formGroupAt(\u0275$index_11_r4))}}function ListInputComponent_Conditional_0_Template(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"h3"),\u0275\u0275text(1),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(2,ListInputComponent_Conditional_0_Conditional_2_Template,2,3,"p",0),\u0275\u0275elementStart(3,"div",1),\u0275\u0275listener("cdkDropListDropped",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.drop($event))}),\u0275\u0275repeaterCreate(4,ListInputComponent_Conditional_0_For_5_Template,1,3,"ix-list-item",2,\u0275\u0275repeaterTrackByIdentity),\u0275\u0275elementEnd(),\u0275\u0275elementStart(6,"button",3),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.addItem())}),\u0275\u0275elementStart(7,"mat-icon"),\u0275\u0275text(8,"add"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(9,"span"),\u0275\u0275text(10),\u0275\u0275elementEnd()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275textInterpolate(ctx_r1.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.field.inputDescription.description?2:-1),\u0275\u0275advance(2),\u0275\u0275repeater(ctx_r1.listInput.items),\u0275\u0275advance(6),\u0275\u0275textInterpolate(ctx_r1.addButtonText)}}var ListInputComponent=(()=>{class ListInputComponent3 extends ComponentInputComponent{constructor(inputConverter,translate,cdRef,dialog){super(),this.inputConverter=inputConverter,this.translate=translate,this.cdRef=cdRef,this.dialog=dialog}get listInput(){return this.field}get formArray(){return this.componentFormGroup.get(this.field.inputDescription.key)}get addButtonText(){return this.field.inputDescription.itemType?.label?this.translate.instant("ADD_NAME",{name:this.field.inputDescription.itemType.label}):this.translate.instant("ADD_ANOTHER")}formGroupAt(index){return this.formArray.at(index)}addItem(){let itemType=this.listInput.inputDescription.itemType;if(itemType){let itemInput=this.inputConverter.convertInput(itemType,itemType.defaultValue,this.listInput.context,this.listInput.level+1),itemForm=new FormGroup({[itemType.key]:itemInput.toFormControl()});itemType.type==="Group"&&itemType.summary?this.dialog.open(GroupInputDialogComponent,{width:"500px",data:{field:itemInput,componentFormGroup:itemForm}}).afterClosed().subscribe(result=>{result&&(itemInput.setValue(itemForm.value[itemType.key]),this.listInput.push(itemInput),this.formArray.markAsDirty(),this.formArray.push(itemForm),this.cdRef.detectChanges())}):(this.listInput.push(itemInput),this.formArray.markAsDirty(),this.formArray.push(itemForm))}}deleteItem(index){this.listInput.removeAt(index),this.formArray.removeAt(index)}drop($event){moveItemInArray(this.listInput.items,$event.previousIndex,$event.currentIndex),moveItemInFormArray(this.formArray,$event.previousIndex,$event.currentIndex)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ListInputComponent3)(\u0275\u0275directiveInject(INPUT_CONVERTER_TOKEN),\u0275\u0275directiveInject(TranslateService),\u0275\u0275directiveInject(ChangeDetectorRef),\u0275\u0275directiveInject(MatDialog))}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ListInputComponent3,selectors:[["ix-list-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,consts:[[1,"description",3,"innerHTML"],["cdkDropList","",3,"cdkDropListDropped"],["cdkDrag","",3,"item","index","componentFormGroup"],["type","button","mat-stroked-button","","color","primary",1,"add-button",3,"click"],["cdkDrag","",3,"delete","item","index","componentFormGroup"]],template:function(rf,ctx){rf&1&&\u0275\u0275conditionalCreate(0,ListInputComponent_Conditional_0_Template,11,3),rf&2&&\u0275\u0275conditional(ctx.field.hidden?-1:0)},dependencies:[CdkDropList,CdkDrag,MatButton,MatIcon,ListItemComponent,RenderMarkdownPipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}[_nghost-%COMP%] h3[_ngcontent-%COMP%]{font-size:11.5px!important;font-weight:500!important;text-transform:uppercase;letter-spacing:.8px;color:color-mix(in srgb,transparent,currentcolor 67%)}[_nghost-%COMP%] .add-button[_ngcontent-%COMP%]{--mat-button-outlined-container-height: 32px;margin-top:16px}[_nghost-%COMP%] .cdk-drag-placeholder[_ngcontent-%COMP%]{opacity:0}[_nghost-%COMP%] .cdk-drag-animating[_ngcontent-%COMP%]{transition:transform .25s cubic-bezier(0,0,.2,1)}[_nghost-%COMP%] .cdk-drag[_ngcontent-%COMP%]:last-child{border:none}[_nghost-%COMP%] .cdk-drop-list-dragging[_ngcontent-%COMP%] .cdk-drag[_ngcontent-%COMP%]:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}[_nghost-%COMP%] .cdk-drop-list-dragging[_ngcontent-%COMP%] .cdk-drag-placeholder[_ngcontent-%COMP%]{cursor:grabbing}[_nghost-%COMP%] .cdk-drag[_ngcontent-%COMP%]{cursor:grab}[_nghost-%COMP%] ix-list-item[_ngcontent-%COMP%] + ix-list-item[_ngcontent-%COMP%]{margin-top:8px}"]})}}return ListInputComponent3})();var ListInput=class extends ComponentPropertiesInput{constructor(input2,value,context3,converter,level){if(super(input2,value,context3,converter,level),input2.itemType){let itemType=input2.itemType;this.items=isArray_default(value)?value.map(value2=>converter.convertInput(itemType,value2,context3,level+1)):[],this.hidden=!!itemType.children?.some(item=>{let child=converter.convertInput(item,value,context3,level+1);return child.inputDescription.required&&child.hidden})}}toFormControl(){return new FormArray(this.items.map(item=>new FormGroup({[item.inputDescription.key]:item.toFormControl()})))}transformValue(){return{[this.inputDescription.key]:this.items.map(item=>item.transformValue())}}setValue(value){value.length===this.items.length&&this.items.forEach((item,i)=>item.setValue(value[i][item.inputDescription.key]))}push(item){this.items.push(item)}removeAt(index){this.items.splice(index,1)}};var LiveMetricInputFacade=(()=>{class LiveMetricInputFacade2 extends RawMetricInputFacade{selectorDataIsLoaded(field){return this._selectorDataIsLoaded(field,selectAllLoadedForAgent)}loadAgentDataVariables(agentId){this.store.dispatch(ensureAll27({agentId}))}selectorsForAgent(agentId,target){return this.loadAgentDataVariables(agentId),this._selectorsForAgent(agentId,target,selectAllForAgent(agentId),{name:"variables",slug:"variable"})}static{this.\u0275fac=(()=>{let \u0275LiveMetricInputFacade_BaseFactory;return function(__ngFactoryType__){return(\u0275LiveMetricInputFacade_BaseFactory||(\u0275LiveMetricInputFacade_BaseFactory=\u0275\u0275getInheritedFactory(LiveMetricInputFacade2)))(__ngFactoryType__||LiveMetricInputFacade2)}})()}static{this.\u0275prov=\u0275\u0275defineInjectable({token:LiveMetricInputFacade2,factory:LiveMetricInputFacade2.\u0275fac,providedIn:"root"})}}return LiveMetricInputFacade2})();var _c014=a0=>({min:a0});function LiveMetricInputComponent_Conditional_0_Conditional_3_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",1),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext(2);\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_5_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-error"),\u0275\u0275text(1),\u0275\u0275pipe(2,"translate"),\u0275\u0275elementEnd()),rf&2){let tmp_3_0,ctx_r0=\u0275\u0275nextContext(3);\u0275\u0275advance(),\u0275\u0275textInterpolate1(" ",\u0275\u0275pipeBind2(2,1,"__MESSAGE__.MIN",\u0275\u0275pureFunction1(4,_c014,ctx_r0.decimalsControl==null||(tmp_3_0=ctx_r0.decimalsControl.getError("min"))==null?null:tmp_3_0.min))," ")}}function LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_6_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",6),\u0275\u0275text(1,"__MESSAGE__.INTEGER"),\u0275\u0275elementEnd())}function LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_7_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",6),\u0275\u0275text(1,"__MESSAGE__.INVALID_NUMBER"),\u0275\u0275elementEnd())}function LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_8_Conditional_4_Template(rf,ctx){if(rf&1){let _r2=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-translation-icon-button",11),\u0275\u0275listener("setTranslationKey",function($event){\u0275\u0275restoreView(_r2);let ctx_r0=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r0.setUnitTranslationKey($event))}),\u0275\u0275elementEnd()}if(rf&2){let ctx_r0=\u0275\u0275nextContext(4);\u0275\u0275property("key",ctx_r0.unitTranslationKey)}}function LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_8_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-form-field",5)(1,"mat-label",6),\u0275\u0275text(2,"UNIT"),\u0275\u0275elementEnd(),\u0275\u0275element(3,"input",9),\u0275\u0275conditionalCreate(4,LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_8_Conditional_4_Template,1,1,"ix-translation-icon-button",10),\u0275\u0275elementEnd()),rf&2){let ctx_r0=\u0275\u0275nextContext(3);\u0275\u0275property("formGroupName",ctx_r0.field.inputDescription.key),\u0275\u0275advance(3),\u0275\u0275property("placeholder",ctx_r0.unitPlaceholder),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.translation?4:-1)}}function LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_9_Template(rf,ctx){if(rf&1){let _r3=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-form-field")(1,"mat-label",6),\u0275\u0275text(2,"UNIT"),\u0275\u0275elementEnd(),\u0275\u0275element(3,"input",12),\u0275\u0275pipe(4,"translate"),\u0275\u0275pipe(5,"trimTranslationNamespace"),\u0275\u0275elementStart(6,"ix-translation-icon-button",11),\u0275\u0275listener("setTranslationKey",function($event){\u0275\u0275restoreView(_r3);let ctx_r0=\u0275\u0275nextContext(3);return \u0275\u0275resetView(ctx_r0.setUnitTranslationKey($event))}),\u0275\u0275elementEnd()()}if(rf&2){let ctx_r0=\u0275\u0275nextContext(3);\u0275\u0275advance(3),\u0275\u0275property("value",ctx_r0.unitTranslationKey?\u0275\u0275pipeBind1(5,4,\u0275\u0275pipeBind1(4,2,ctx_r0.unitTranslationKey)):""),\u0275\u0275advance(3),\u0275\u0275property("key",ctx_r0.unitTranslationKey)}}function LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_14_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",6),\u0275\u0275text(1,"__MESSAGE__.INVALID_FACTOR"),\u0275\u0275elementEnd())}function LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_15_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",6),\u0275\u0275text(1,"__MESSAGE__.INVALID_NUMBER"),\u0275\u0275elementEnd())}function LiveMetricInputComponent_Conditional_0_Conditional_6_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",4)(1,"mat-form-field",5)(2,"mat-label",6),\u0275\u0275text(3,"DECIMALS"),\u0275\u0275elementEnd(),\u0275\u0275element(4,"input",7),\u0275\u0275conditionalCreate(5,LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_5_Template,3,6,"mat-error"),\u0275\u0275conditionalCreate(6,LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_6_Template,2,0,"mat-error",6),\u0275\u0275conditionalCreate(7,LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_7_Template,2,0,"mat-error",6),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(8,LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_8_Template,5,3,"mat-form-field",5)(9,LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_9_Template,7,6,"mat-form-field"),\u0275\u0275elementStart(10,"mat-form-field",5)(11,"mat-label",6),\u0275\u0275text(12,"FACTOR"),\u0275\u0275elementEnd(),\u0275\u0275element(13,"input",8),\u0275\u0275conditionalCreate(14,LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_14_Template,2,0,"mat-error",6),\u0275\u0275conditionalCreate(15,LiveMetricInputComponent_Conditional_0_Conditional_6_Conditional_15_Template,2,0,"mat-error",6),\u0275\u0275elementEnd()()),rf&2){let ctx_r0=\u0275\u0275nextContext(2);\u0275\u0275advance(),\u0275\u0275property("formGroupName",ctx_r0.field.inputDescription.key),\u0275\u0275advance(4),\u0275\u0275conditional(ctx_r0.decimalsControl!=null&&ctx_r0.decimalsControl.hasError("min")?5:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.decimalsControl!=null&&ctx_r0.decimalsControl.hasError("integer")?6:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.decimalsControl!=null&&ctx_r0.decimalsControl.hasError("number")?7:-1),\u0275\u0275advance(),\u0275\u0275conditional(!ctx_r0.translation||!ctx_r0.unitTranslationKey?8:9),\u0275\u0275advance(2),\u0275\u0275property("formGroupName",ctx_r0.field.inputDescription.key),\u0275\u0275advance(3),\u0275\u0275property("placeholder",ctx_r0.factorPlaceholder||""),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.factorControl!=null&&ctx_r0.factorControl.hasError("decimals")?14:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.factorControl!=null&&ctx_r0.factorControl.hasError("number")?15:-1)}}function LiveMetricInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",0)(1,"h3"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(3,LiveMetricInputComponent_Conditional_0_Conditional_3_Template,2,3,"p",1),\u0275\u0275elementStart(4,"div",2),\u0275\u0275element(5,"ix-selector-input",3),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(6,LiveMetricInputComponent_Conditional_0_Conditional_6_Template,16,9,"div",4),\u0275\u0275elementEnd()),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("formGroup",ctx_r0.componentFormGroup),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.field.inputDescription.description?3:-1),\u0275\u0275advance(2),\u0275\u0275property("pageVersionId",ctx_r0.field.context.component.pageVersion==null?null:ctx_r0.field.context.component.pageVersion.publicId)("selectorControl",ctx_r0.selectorControl)("selectors",ctx_r0.selectors)("disabled",!ctx_r0.selectorDataIsLoaded)("required",ctx_r0.required)("metricsEnabled",!1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.showDecimalsUnitFactor?6:-1)}}var LiveMetricInputComponent=(()=>{class LiveMetricInputComponent3 extends RawMetricInputComponent{constructor(){super(...arguments),this.facade=inject(LiveMetricInputFacade)}static{this.\u0275fac=(()=>{let \u0275LiveMetricInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275LiveMetricInputComponent_BaseFactory||(\u0275LiveMetricInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(LiveMetricInputComponent3)))(__ngFactoryType__||LiveMetricInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:LiveMetricInputComponent3,selectors:[["ix-live-metric-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,consts:[[3,"formGroup"],[1,"description",3,"innerHTML"],["fxLayout","column"],["fxFlex","","label","VARIABLE",3,"pageVersionId","selectorControl","selectors","disabled","required","metricsEnabled"],["fxLayout","row","fxLayoutGap","8px"],["fxFlex","",3,"formGroupName"],["translate",""],["formControlName","decimals","min","0","type","number","matInput",""],["formControlName","factor","type","number","matInput","",3,"placeholder"],["formControlName","unit","matInput","",3,"placeholder"],[3,"key"],[3,"setTranslationKey","key"],["matInput","","disabled","",3,"value"]],template:function(rf,ctx){rf&1&&\u0275\u0275conditionalCreate(0,LiveMetricInputComponent_Conditional_0_Template,7,10,"div",0),rf&2&&\u0275\u0275conditional(ctx.field.hidden?-1:0)},dependencies:[NumberInputValidatorDirective,SelectorInputComponent,DefaultLayoutDirective,DefaultLayoutGapDirective,DefaultFlexDirective,DefaultValueAccessor,NumberValueAccessor,NgControlStatus,NgControlStatusGroup,MinValidator,FormGroupDirective,FormControlName,FormGroupName,TranslateDirective,MatFormField,MatLabel,MatError,MatInput,TranslationIconButtonComponent,RenderMarkdownPipe,TranslatePipe,TrimTranslationNamespacePipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] h3[_ngcontent-%COMP%]{font-size:11.5px!important;font-weight:500!important;text-transform:uppercase;letter-spacing:.8px;color:color-mix(in srgb,transparent,currentcolor 67%)}[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{display:block}"]})}}return LiveMetricInputComponent3})();var LiveMetricInput=class extends RawMetricInput{constructor(input2,value,context3,converter,level,injector){super(input2,value,context3,converter,level,injector),this.hidden=!injector.get(PlatformFeaturesService).instantCheck([{canInput:"live-data"}])}};var MaterialIconFieldsetFacade=(()=>{class MaterialIconFieldsetFacade2{groups(appearance){return from(import("./chunk-PKI27XVT.js")).pipe(map(({ICONS_METADATA})=>{let groupsDict=ICONS_METADATA.reduce((groups,icon)=>(appearance==="legacy"&&icon.unsupported_families.includes("Material Icons")||appearance==="symbols"&&icon.unsupported_families.includes("Material Symbols Outlined")||icon.categories.forEach(category=>{groups[category]||(groups[category]=[]),groups[category].push(icon)}),groups),{});return Object.keys(groupsDict).map(key=>({name:key,icons:groupsDict[key]}))}),map(groups=>groups.map(group=>__spreadProps(__spreadValues({},group),{popularity:Math.round(group.icons.reduce((acc,curr)=>acc+curr.popularity,0)/group.icons.length),icons:group.icons.sort((a,b)=>b.popularity-a.popularity)})).sort((a,b)=>b.popularity-a.popularity)))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||MaterialIconFieldsetFacade2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:MaterialIconFieldsetFacade2,factory:MaterialIconFieldsetFacade2.\u0275fac,providedIn:"root"})}}return MaterialIconFieldsetFacade2})();var _forTrack06=($index,$item)=>$item.name;function MaterialIconFieldsetComponent_For_7_For_2_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",13)(1,"mat-icon"),\u0275\u0275text(2),\u0275\u0275elementEnd()()),rf&2){let icon_r2=ctx.$implicit;\u0275\u0275property("value",icon_r2.name)("title",icon_r2.name),\u0275\u0275advance(2),\u0275\u0275textInterpolate(icon_r2.name)}}function MaterialIconFieldsetComponent_For_7_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-optgroup",4),\u0275\u0275repeaterCreate(1,MaterialIconFieldsetComponent_For_7_For_2_Template,3,3,"mat-option",13,_forTrack06),\u0275\u0275elementEnd()),rf&2){let group_r3=ctx.$implicit;\u0275\u0275property("label",group_r3.name),\u0275\u0275advance(),\u0275\u0275repeater(group_r3.icons)}}function MaterialIconFieldsetComponent_ng_container_15_Template(rf,ctx){rf&1&&\u0275\u0275elementContainer(0)}function MaterialIconFieldsetComponent_Conditional_16_Template(rf,ctx){if(rf&1){let _r4=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",14),\u0275\u0275pipe(1,"translate"),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r4);let ctx_r4=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r4.clear())}),\u0275\u0275elementStart(2,"mat-icon"),\u0275\u0275text(3,"close"),\u0275\u0275elementEnd()()}rf&2&&\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(1,1,"CLEAR"))}function MaterialIconFieldsetComponent_Conditional_18_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",12),\u0275\u0275text(1,"__MESSAGE__.REQUIRED"),\u0275\u0275elementEnd())}function MaterialIconFieldsetComponent_ng_template_19_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-icon",15),\u0275\u0275text(1),\u0275\u0275elementEnd()),rf&2){let ctx_r4=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275textInterpolate(ctx_r4.value)}}function MaterialIconFieldsetComponent_ng_template_21_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-icon",16),\u0275\u0275text(1),\u0275\u0275elementEnd()),rf&2){let ctx_r4=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275textInterpolate(ctx_r4.placeholderIcon)}}var MaterialIconFieldsetComponent=(()=>{class MaterialIconFieldsetComponent2{constructor(){this.appearance="symbols",this.placeholderIcon="add_reaction",this.filteredIconGroups$=new ReplaySubject(1),this.queryFormControl=new FormControl(""),this.destroy=inject(DestroyRef),this.facade=inject(MaterialIconFieldsetFacade)}get required(){return this.form.hasValidator(Validators.required)}get value(){return this.form.value}ngOnInit(){this.facade.groups(this.appearance).pipe(takeUntilDestroyed(this.destroy)).subscribe(groups=>{this.groups=groups,this.filteredIconGroups$.next(this.copyIconGroups(this.groups))}),this.queryFormControl.valueChanges.pipe(debounceTime(100),takeUntilDestroyed(this.destroy)).subscribe(()=>{this.filterIconGroups()})}ngAfterViewInit(){this.select._calculateOverlayScroll=this._calculateOverlayScroll.bind(this)}clear(){this.form.setValue(null),this.form.markAsDirty()}toggleSelect(){this.select.panelOpen?this.select.close():this.select.open()}filterIconGroups(){if(!this.groups)return;let query=this.queryFormControl.value||"",iconGroupsCopy=this.copyIconGroups(this.groups);if(!query){this.filteredIconGroups$.next(iconGroupsCopy);return}query=query.toLowerCase(),this.filteredIconGroups$.next(iconGroupsCopy.filter(iconGroup=>(iconGroup.name.toLowerCase().includes(query)||(iconGroup.icons=iconGroup.icons.filter(icon=>icon.name.toLowerCase().includes(query)||icon.tags.some(tag=>tag.toLowerCase().includes(query)))),iconGroup.icons.length>0)))}copyIconGroups(iconGroups){let iconGroupsCopy=[];return iconGroups.forEach(iconGroup=>{iconGroupsCopy.push({name:iconGroup.name,popularity:iconGroup.popularity,icons:iconGroup.icons.slice()})}),iconGroupsCopy}_calculateOverlayScroll(selectedIndex,scrollBuffer,maxScroll){let selectedLabel=this.select.selected?this.select.selected.group?.label:null,_selectedGroupIndex=selectedLabel?this.groups.findIndex(group=>group.name===selectedLabel):-1,_selectedIndex=selectedIndex-_selectedGroupIndex-2,itemHeight=40,optionOffsetFromScrollTop=itemHeight*Math.ceil(_selectedIndex/7)+Math.round((_selectedGroupIndex+1)*48),halfOptionHeight=itemHeight/2,optimalScrollPosition=optionOffsetFromScrollTop-scrollBuffer+halfOptionHeight;return Math.min(Math.max(0,optimalScrollPosition),maxScroll)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||MaterialIconFieldsetComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:MaterialIconFieldsetComponent2,selectors:[["ix-material-icon-fieldset"]],viewQuery:function(rf,ctx){if(rf&1&&\u0275\u0275viewQuery(MatSelect,5),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.select=_t.first)}},inputs:{appearance:"appearance",form:"form",label:"label",placeholderIcon:"placeholderIcon"},decls:23,vars:19,consts:[["selectedIcon",""],["defaultIcon",""],["panelClass","material-icon-select-panel",1,"select",3,"formControl"],[3,"formControl","placeholderLabel","noEntriesFoundLabel"],[1,"icon-group",3,"label"],["fxLayout","column"],["data-testid","material-icon-fieldset-label",1,"label"],["fxLayout","row","fxLayoutAlign","start center"],["type","button","mat-icon-button","",1,"select-trigger-button",3,"click","disabled"],[4,"ngTemplateOutlet"],["type","button","mat-icon-button","",1,"clear-button",3,"matTooltip"],[1,"errors"],["translate",""],[1,"icon",3,"value","title"],["type","button","mat-icon-button","",1,"clear-button",3,"click","matTooltip"],["data-testid","material-icon-fieldset-selected-icon"],["data-testid","material-icon-fieldset-placeholder-icon"]],template:function(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-form-field")(1,"mat-select",2)(2,"mat-option"),\u0275\u0275element(3,"ngx-mat-select-search",3),\u0275\u0275pipe(4,"translate"),\u0275\u0275pipe(5,"translate"),\u0275\u0275elementEnd(),\u0275\u0275repeaterCreate(6,MaterialIconFieldsetComponent_For_7_Template,3,1,"mat-optgroup",4,_forTrack06),\u0275\u0275pipe(8,"async"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(9,"div",5)(10,"div",6),\u0275\u0275text(11),\u0275\u0275pipe(12,"translate"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(13,"div",7)(14,"button",8),\u0275\u0275listener("click",function(){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.toggleSelect())}),\u0275\u0275template(15,MaterialIconFieldsetComponent_ng_container_15_Template,1,0,"ng-container",9),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(16,MaterialIconFieldsetComponent_Conditional_16_Template,4,3,"button",10),\u0275\u0275elementEnd(),\u0275\u0275elementStart(17,"div",11),\u0275\u0275conditionalCreate(18,MaterialIconFieldsetComponent_Conditional_18_Template,2,0,"mat-error",12),\u0275\u0275elementEnd()(),\u0275\u0275template(19,MaterialIconFieldsetComponent_ng_template_19_Template,2,1,"ng-template",null,0,\u0275\u0275templateRefExtractor)(21,MaterialIconFieldsetComponent_ng_template_21_Template,2,1,"ng-template",null,1,\u0275\u0275templateRefExtractor)}if(rf&2){let selectedIcon_r6=\u0275\u0275reference(20),defaultIcon_r7=\u0275\u0275reference(22);\u0275\u0275advance(),\u0275\u0275property("formControl",ctx.form),\u0275\u0275advance(2),\u0275\u0275property("formControl",ctx.queryFormControl)("placeholderLabel",\u0275\u0275pipeBind1(4,11,"SEARCH"))("noEntriesFoundLabel",\u0275\u0275pipeBind1(5,13,"NO_RESULTS_FOUND")),\u0275\u0275advance(3),\u0275\u0275repeater(\u0275\u0275pipeBind1(8,15,ctx.filteredIconGroups$)),\u0275\u0275advance(3),\u0275\u0275classProp("with-errors",ctx.form.touched&&ctx.form.invalid),\u0275\u0275advance(2),\u0275\u0275textInterpolate1(" ",(ctx.label||\u0275\u0275pipeBind1(12,17,"ICON"))+(ctx.required?" *":"")," "),\u0275\u0275advance(3),\u0275\u0275property("disabled",ctx.form.disabled),\u0275\u0275advance(),\u0275\u0275property("ngTemplateOutlet",ctx.value?selectedIcon_r6:defaultIcon_r7),\u0275\u0275advance(),\u0275\u0275conditional(ctx.value&&!ctx.form.disabled?16:-1),\u0275\u0275advance(2),\u0275\u0275conditional(ctx.form.touched&&ctx.form.hasError("required")?18:-1)}},dependencies:[NgTemplateOutlet,FormsModule,NgControlStatus,FlexLayoutModule,DefaultLayoutDirective,DefaultLayoutAlignDirective,ReactiveFormsModule,FormControlDirective,MatButtonModule,MatIconButton,MatFormFieldModule,MatFormField,MatError,MatIconModule,MatIcon,MatTooltipModule,MatTooltip,MatSelectModule,MatSelect,MatOption,MatOptgroup,NgxMatSelectSearchModule,MatSelectSearchComponent,TranslateModule,TranslateDirective,AsyncPipe,TranslatePipe],styles:["[_nghost-%COMP%]{display:block;position:relative;padding-bottom:1.25em}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{position:absolute;left:40px;visibility:hidden}[_nghost-%COMP%] .select-trigger-button[_ngcontent-%COMP%]{background-color:rgba(var(--body-color-rgb),.04)}[_nghost-%COMP%] .label[_ngcontent-%COMP%]{margin-bottom:4px;transform-origin:top left;transform:scale(.75) perspective(100px) translateZ(.001px);font-size:14px;color:#0000008a}[_nghost-%COMP%] .with-errors[_ngcontent-%COMP%] .label[_ngcontent-%COMP%], [_nghost-%COMP%] .with-errors[_ngcontent-%COMP%] .select-trigger-button[_ngcontent-%COMP%]{color:var(--warn)}[_nghost-%COMP%] .errors[_ngcontent-%COMP%]{position:absolute;top:66px;left:0;font-size:10.5px}[_nghost-%COMP%] .clear-button[_ngcontent-%COMP%]{--mat-icon-button-state-layer-size: 32px;--mat-icon-button-icon-size: 20px;margin-left:4px}"],changeDetection:0})}}return MaterialIconFieldsetComponent2})();function MaterialIconInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}var MaterialIconInputComponent=(()=>{class MaterialIconInputComponent3 extends ComponentInputComponent{get inputControl(){return super.inputControl}static{this.\u0275fac=(()=>{let \u0275MaterialIconInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275MaterialIconInputComponent_BaseFactory||(\u0275MaterialIconInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(MaterialIconInputComponent3)))(__ngFactoryType__||MaterialIconInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:MaterialIconInputComponent3,selectors:[["ix-material-icon-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:2,vars:3,consts:[[1,"description",3,"innerHTML"],["appearance","legacy",3,"form","label"]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,MaterialIconInputComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275element(1,"ix-material-icon-fieldset",1)),rf&2&&(\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(),\u0275\u0275property("form",ctx.inputControl)("label",ctx.field.inputDescription.label||""))},dependencies:[MaterialIconFieldsetComponent,RenderMarkdownPipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}"]})}}return MaterialIconInputComponent3})();var _c015=a0=>({min:a0}),_c15=a0=>({max:a0});function NumberInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function NumberInputComponent_Conditional_7_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",3),\u0275\u0275text(1,"__MESSAGE__.REQUIRED"),\u0275\u0275elementEnd())}function NumberInputComponent_Conditional_8_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",3),\u0275\u0275text(1,"__MESSAGE__.INVALID_NUMBER"),\u0275\u0275elementEnd())}function NumberInputComponent_Conditional_9_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-error",4),\u0275\u0275text(1,"__MESSAGE__.MIN"),\u0275\u0275elementEnd()),rf&2){let tmp_1_0,ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("translateParams",\u0275\u0275pureFunction1(1,_c015,ctx_r0.inputControl==null||(tmp_1_0=ctx_r0.inputControl.getError("min"))==null?null:tmp_1_0.min))}}function NumberInputComponent_Conditional_10_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-error",4),\u0275\u0275text(1,"__MESSAGE__.MAX"),\u0275\u0275elementEnd()),rf&2){let tmp_1_0,ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("translateParams",\u0275\u0275pureFunction1(1,_c15,ctx_r0.inputControl==null||(tmp_1_0=ctx_r0.inputControl.getError("max"))==null?null:tmp_1_0.max))}}var NumberInputComponent=(()=>{class NumberInputComponent3 extends ComponentInputComponent{enterKeyDownHandler(event2){event2.target.blur()}static{this.\u0275fac=(()=>{let \u0275NumberInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275NumberInputComponent_BaseFactory||(\u0275NumberInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(NumberInputComponent3)))(__ngFactoryType__||NumberInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:NumberInputComponent3,selectors:[["ix-number-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:11,vars:11,consts:[[1,"description",3,"innerHTML"],[3,"formGroup"],["matInput","","type","number","autocomplete","off","data-lpignore","true",3,"keydown.enter","step","formControlName","placeholder"],["translate",""],["translate","",3,"translateParams"]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,NumberInputComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275elementStart(1,"mat-form-field",1)(2,"mat-label"),\u0275\u0275text(3),\u0275\u0275elementEnd(),\u0275\u0275elementStart(4,"input",2),\u0275\u0275listener("keydown.enter",function($event){return ctx.enterKeyDownHandler($event)}),\u0275\u0275elementEnd(),\u0275\u0275elementStart(5,"mat-hint"),\u0275\u0275text(6),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(7,NumberInputComponent_Conditional_7_Template,2,0,"mat-error",3),\u0275\u0275conditionalCreate(8,NumberInputComponent_Conditional_8_Template,2,0,"mat-error",3),\u0275\u0275conditionalCreate(9,NumberInputComponent_Conditional_9_Template,2,3,"mat-error",4),\u0275\u0275conditionalCreate(10,NumberInputComponent_Conditional_10_Template,2,3,"mat-error",4),\u0275\u0275elementEnd()),rf&2&&(\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(),\u0275\u0275property("formGroup",ctx.componentFormGroup),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("step",ctx.field.inputDescription.step)("formControlName",ctx.field.inputName)("placeholder",ctx.field.inputDescription.placeholder||""),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx.field.inputDescription.hint),\u0275\u0275advance(),\u0275\u0275conditional(ctx.inputControl!=null&&ctx.inputControl.hasError("required")?7:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.inputControl!=null&&ctx.inputControl.hasError("number")?8:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.inputControl!=null&&ctx.inputControl.hasError("min")?9:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.inputControl!=null&&ctx.inputControl.hasError("max")?10:-1))},dependencies:[NumberInputValidatorDirective,DefaultValueAccessor,NumberValueAccessor,NgControlStatus,NgControlStatusGroup,FormGroupDirective,FormControlName,TranslateDirective,MatFormField,MatLabel,MatHint,MatError,MatInput,RenderMarkdownPipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{width:100%}"]})}}return NumberInputComponent3})();var NumberInput=class extends ComponentPropertiesInput{toFormControl(){let value=this.value??this.inputDescription.defaultValue,validators=this.getValidators(),formControl=new FormControl(value,validators);return this.inputDescription.disabled&&formControl.disable(),formControl}getValidators(){let validators=[],{min:min2,max:max2,required}=this.inputDescription;return required&&validators.push(Validators.required),min2!==void 0&&validators.push(Validators.min(min2)),max2!==void 0&&validators.push(Validators.max(max2)),validators}};function SelectionInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function SelectionInputComponent_For_6_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",3),\u0275\u0275text(1),\u0275\u0275elementEnd()),rf&2){let option_r2=ctx.$implicit;\u0275\u0275property("value",option_r2.value),\u0275\u0275advance(),\u0275\u0275textInterpolate(option_r2.label)}}function SelectionInputComponent_Conditional_7_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",4),\u0275\u0275text(1,"__MESSAGE__.REQUIRED"),\u0275\u0275elementEnd())}var SelectionInputComponent=(()=>{class SelectionInputComponent3 extends ComponentInputComponent{static{this.\u0275fac=(()=>{let \u0275SelectionInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275SelectionInputComponent_BaseFactory||(\u0275SelectionInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(SelectionInputComponent3)))(__ngFactoryType__||SelectionInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:SelectionInputComponent3,selectors:[["ix-selection-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:8,vars:5,consts:[[1,"description",3,"innerHTML"],[3,"formGroup"],[3,"formControlName"],[3,"value"],["translate",""]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,SelectionInputComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275elementStart(1,"mat-form-field",1)(2,"mat-label"),\u0275\u0275text(3),\u0275\u0275elementEnd(),\u0275\u0275elementStart(4,"mat-select",2),\u0275\u0275repeaterCreate(5,SelectionInputComponent_For_6_Template,2,2,"mat-option",3,\u0275\u0275repeaterTrackByIdentity),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(7,SelectionInputComponent_Conditional_7_Template,2,0,"mat-error",4),\u0275\u0275elementEnd()),rf&2&&(\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(),\u0275\u0275property("formGroup",ctx.componentFormGroup),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("formControlName",ctx.field.inputName),\u0275\u0275advance(),\u0275\u0275repeater(ctx.field.inputDescription.options),\u0275\u0275advance(2),\u0275\u0275conditional(ctx.inputControl!=null&&ctx.inputControl.hasError("required")?7:-1))},dependencies:[NgControlStatus,NgControlStatusGroup,FormGroupDirective,FormControlName,TranslateDirective,MatOption,MatFormField,MatLabel,MatError,MatSelect,RenderMarkdownPipe],styles:["[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{display:block}"]})}}return SelectionInputComponent3})();var SelectionInput=class extends ComponentPropertiesInput{constructor(input2,value,context3,converter,level){super(input2,value,context3,converter,level),this.setValue(value)}setValue(value){super.setValue(value)}transformValue(){let selectedOption=this.inputDescription.options?.find(v=>v.value===this.value);return selectedOption?__spreadProps(__spreadValues({},super.transformValue()),{["$"+this.inputDescription.key]:selectedOption}):super.transformValue()}};var nonWhitespaceValidator=formControl=>typeof formControl.value=="string"&&formControl.value.trim()===""?{nonWhitespace:!0}:null;var StringInput=class extends ComponentPropertiesInput{constructor(input2,value,context3,converter,level,injector){super(input2,value,context3,converter,level),this.translate=injector.get(TranslateService),this.setValue(value)}toFormControl(){let validators=[];this.inputDescription.required&&(validators.push(Validators.required),this.inputDescription.type==="String"&&validators.push(nonWhitespaceValidator));let formControl=new FormControl(this.value??this.inputDescription.defaultValue??"",validators.length?validators:null);return this.inputDescription.disabled&&formControl.disable(),formControl}transformValue(){return isString_default(this.value)&&this.value.startsWith("__TRANSLATION__.")?{[this.inputDescription.key]:trimNamespace(this.translate.instant(this.value))}:super.transformValue()}setValue(value){super.setValue(isNil_default(value)?value:String(value))}};function StringInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function StringInputComponent_Conditional_1_Conditional_4_Template(rf,ctx){if(rf&1){let _r3=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-translation-icon-button",5),\u0275\u0275listener("setTranslationKey",function($event){\u0275\u0275restoreView(_r3);let ctx_r0=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r0.setTranslationKey($event))}),\u0275\u0275elementEnd()}if(rf&2){let ctx_r0=\u0275\u0275nextContext(2);\u0275\u0275property("key",ctx_r0.translationKey)}}function StringInputComponent_Conditional_1_Conditional_7_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",4),\u0275\u0275text(1,"__MESSAGE__.REQUIRED"),\u0275\u0275elementEnd())}function StringInputComponent_Conditional_1_Template(rf,ctx){if(rf&1){let _r2=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-form-field",1)(1,"mat-label"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"input",2),\u0275\u0275listener("keydown.enter",function($event){\u0275\u0275restoreView(_r2);let ctx_r0=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r0.enterKeyDownHandler($event))}),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(4,StringInputComponent_Conditional_1_Conditional_4_Template,1,1,"ix-translation-icon-button",3),\u0275\u0275elementStart(5,"mat-hint"),\u0275\u0275text(6),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(7,StringInputComponent_Conditional_1_Conditional_7_Template,2,0,"mat-error",4),\u0275\u0275elementEnd()}if(rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("formGroup",ctx_r0.componentFormGroup),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("formControlName",ctx_r0.field.inputName)("placeholder",ctx_r0.field.inputDescription.placeholder||""),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.translation?4:-1),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.hint),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.inputControl!=null&&ctx_r0.inputControl.hasError("required")||ctx_r0.inputControl!=null&&ctx_r0.inputControl.hasError("nonWhitespace")?7:-1)}}function StringInputComponent_Conditional_2_Template(rf,ctx){if(rf&1){let _r4=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-form-field")(1,"mat-label"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275element(3,"input",6),\u0275\u0275pipe(4,"translate"),\u0275\u0275pipe(5,"trimTranslationNamespace"),\u0275\u0275elementStart(6,"ix-translation-icon-button",5),\u0275\u0275listener("setTranslationKey",function($event){\u0275\u0275restoreView(_r4);let ctx_r0=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r0.setTranslationKey($event))}),\u0275\u0275elementEnd(),\u0275\u0275elementStart(7,"mat-hint"),\u0275\u0275text(8),\u0275\u0275elementEnd()()}if(rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("value",ctx_r0.translationKey?\u0275\u0275pipeBind1(5,7,\u0275\u0275pipeBind1(4,5,ctx_r0.translationKey)):"")("placeholder",ctx_r0.field.inputDescription.placeholder||""),\u0275\u0275advance(3),\u0275\u0275property("key",ctx_r0.translationKey),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.hint)}}var StringInputComponent=(()=>{class StringInputComponent3 extends ComponentInputComponent{constructor(){super(...arguments),this.translate=inject(TranslateService)}ngOnInit(){this.translation=environment.appName!=="Simulator"&&(this.field?.inputDescription?.translate??!0),this.translationKey=this.inputControl?.value?.startsWith("__TRANSLATION__.")?this.inputControl.value:void 0}setTranslationKey(translationKey){this.translationKey=translationKey,translationKey?this.inputControl?.setValue(this.translationKey):this.inputControl?.setValue(this.field.value?this.translate.instant(this.field.value):"")}enterKeyDownHandler(event2){event2.target.blur()}static{this.\u0275fac=(()=>{let \u0275StringInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275StringInputComponent_BaseFactory||(\u0275StringInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(StringInputComponent3)))(__ngFactoryType__||StringInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:StringInputComponent3,selectors:[["ix-string-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:3,vars:2,consts:[[1,"description",3,"innerHTML"],[3,"formGroup"],["matInput","","autocomplete","off","data-lpignore","true",3,"keydown.enter","formControlName","placeholder"],[3,"key"],["translate",""],[3,"setTranslationKey","key"],["matInput","","disabled","","autocomplete","off","data-lpignore","true",3,"value","placeholder"]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,StringInputComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275conditionalCreate(1,StringInputComponent_Conditional_1_Template,8,7,"mat-form-field",1)(2,StringInputComponent_Conditional_2_Template,9,9,"mat-form-field")),rf&2&&(\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(),\u0275\u0275conditional(!ctx.translation||!ctx.translationKey?1:2))},dependencies:[DefaultValueAccessor,NgControlStatus,NgControlStatusGroup,FormGroupDirective,FormControlName,TranslateDirective,MatFormField,MatLabel,MatHint,MatError,MatInput,TranslationIconButtonComponent,RenderMarkdownPipe,TranslatePipe,TrimTranslationNamespacePipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{width:100%}"]})}}return StringInputComponent3})();var TextInput=class extends StringInput{};function TextInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function TextInputComponent_Conditional_1_Conditional_4_Template(rf,ctx){if(rf&1){let _r3=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-translation-icon-button",5),\u0275\u0275listener("setTranslationKey",function($event){\u0275\u0275restoreView(_r3);let ctx_r0=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r0.setTranslationKey($event))}),\u0275\u0275elementEnd()}if(rf&2){let ctx_r0=\u0275\u0275nextContext(2);\u0275\u0275property("key",ctx_r0.translationKey)}}function TextInputComponent_Conditional_1_Conditional_7_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",4),\u0275\u0275text(1,"__MESSAGE__.REQUIRED"),\u0275\u0275elementEnd())}function TextInputComponent_Conditional_1_Template(rf,ctx){if(rf&1){let _r2=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-form-field",1)(1,"mat-label"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"textarea",2),\u0275\u0275listener("keydown.enter",function($event){return \u0275\u0275restoreView(_r2),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(4,TextInputComponent_Conditional_1_Conditional_4_Template,1,1,"ix-translation-icon-button",3),\u0275\u0275elementStart(5,"mat-hint"),\u0275\u0275text(6),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(7,TextInputComponent_Conditional_1_Conditional_7_Template,2,0,"mat-error",4),\u0275\u0275elementEnd()}if(rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("formGroup",ctx_r0.componentFormGroup),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("formControlName",ctx_r0.field.inputName)("placeholder",ctx_r0.field.inputDescription.placeholder||""),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.translation?4:-1),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.hint),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.inputControl!=null&&ctx_r0.inputControl.hasError("required")?7:-1)}}function TextInputComponent_Conditional_2_Template(rf,ctx){if(rf&1){let _r4=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-form-field")(1,"mat-label"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275element(3,"textarea",6),\u0275\u0275pipe(4,"translate"),\u0275\u0275pipe(5,"trimTranslationNamespace"),\u0275\u0275elementStart(6,"ix-translation-icon-button",5),\u0275\u0275listener("setTranslationKey",function($event){\u0275\u0275restoreView(_r4);let ctx_r0=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r0.setTranslationKey($event))}),\u0275\u0275elementEnd(),\u0275\u0275elementStart(7,"mat-hint"),\u0275\u0275text(8),\u0275\u0275elementEnd()()}if(rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("value",ctx_r0.translationKey?\u0275\u0275pipeBind1(5,7,\u0275\u0275pipeBind1(4,5,ctx_r0.translationKey)):"")("placeholder",ctx_r0.field.inputDescription.placeholder||""),\u0275\u0275advance(3),\u0275\u0275property("key",ctx_r0.translationKey),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.hint)}}var TextInputComponent=(()=>{class TextInputComponent3 extends StringInputComponent{static{this.\u0275fac=(()=>{let \u0275TextInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275TextInputComponent_BaseFactory||(\u0275TextInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(TextInputComponent3)))(__ngFactoryType__||TextInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:TextInputComponent3,selectors:[["ix-text-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:3,vars:2,consts:[[1,"description",3,"innerHTML"],[3,"formGroup"],["matInput","","cdkTextareaAutosize","true","cdkAutosizeMinRows","2","cdkAutosizeMaxRows","15",3,"keydown.enter","formControlName","placeholder"],[3,"key"],["translate",""],[3,"setTranslationKey","key"],["matInput","","cdkTextareaAutosize","true","cdkAutosizeMinRows","2","cdkAutosizeMaxRows","15","disabled","",3,"value","placeholder"]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,TextInputComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275conditionalCreate(1,TextInputComponent_Conditional_1_Template,8,7,"mat-form-field",1)(2,TextInputComponent_Conditional_2_Template,9,9,"mat-form-field")),rf&2&&(\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(),\u0275\u0275conditional(!ctx.translation||!ctx.translationKey?1:2))},dependencies:[DefaultValueAccessor,NgControlStatus,NgControlStatusGroup,FormGroupDirective,FormControlName,TranslateDirective,MatFormField,MatLabel,MatHint,MatError,MatInput,CdkTextareaAutosize,TranslationIconButtonComponent,RenderMarkdownPipe,TranslatePipe,TrimTranslationNamespacePipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .description[_ngcontent-%COMP%]{font-size:11px}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{width:100%}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{width:calc(100% - 40px)}"]})}}return TextInputComponent3})();var RichTextInput=class extends StringInput{};var defaultModules={toolbar:[["bold","italic","underline","strike"],["blockquote","code-block"],[{header:1},{header:2}],[{list:"ordered"},{list:"bullet"}],[{script:"sub"},{script:"super"}],[{indent:"-1"},{indent:"+1"}],[{direction:"rtl"}],[{size:["small",!1,"large","huge"]}],[{header:[1,2,3,4,5,6,!1]}],[{color:[]},{background:[]}],[{font:[]}],[{align:[]}],["clean"],["link","image","video"],["table"]]},QUILL_CONFIG_TOKEN=new InjectionToken("config",{providedIn:"root",factory:()=>({modules:defaultModules})});var _c016=[[["","above-quill-editor-toolbar",""]],[["","quill-editor-toolbar",""]],[["","below-quill-editor-toolbar",""]]],_c16=["[above-quill-editor-toolbar]","[quill-editor-toolbar]","[below-quill-editor-toolbar]"];function QuillEditorComponent_Conditional_0_Template(rf,ctx){rf&1&&\u0275\u0275domElement(0,"div",0)}function QuillEditorComponent_Conditional_4_Template(rf,ctx){rf&1&&\u0275\u0275domElement(0,"div",0)}var getFormat2=(format2,configFormat)=>format2||configFormat||"html",raf$=()=>new Observable(subscriber=>{let rafId=requestAnimationFrame(()=>{subscriber.next(),subscriber.complete()});return()=>cancelAnimationFrame(rafId)}),QuillService=(()=>{class QuillService2{constructor(){this.config=inject(QUILL_CONFIG_TOKEN)||{modules:defaultModules},this.quill$=defer(()=>__async(this,null,function*(){if(!this.Quill){let maybePatchedAddEventListener=document.addEventListener;document.addEventListener=document.__zone_symbol__addEventListener||document.addEventListener;let{Quill}=yield import("./chunk-KSVNMWKX.js");document.addEventListener=maybePatchedAddEventListener,this.Quill=Quill}return this.config.customOptions?.forEach(customOption=>{let newCustomOption=this.Quill.import(customOption.import);newCustomOption.whitelist=customOption.whitelist,this.Quill.register(newCustomOption,!0,this.config.suppressGlobalRegisterWarning)}),new Promise(resolve=>{this.registerCustomModules(this.Quill,this.config.customModules,this.config.suppressGlobalRegisterWarning).subscribe(resolve)})})).pipe(shareReplay({bufferSize:1,refCount:!1})),this.registeredModules=new Set}getQuill(){return this.quill$}beforeRender(Quill,customModules,beforeRender=this.config.beforeRender){let sources=[this.registerCustomModules(Quill,customModules)];return beforeRender&&sources.push(beforeRender()),forkJoin(sources).pipe(map(()=>Quill))}registerCustomModules(Quill,customModules,suppressGlobalRegisterWarning){if(!Array.isArray(customModules))return of(Quill);let sources=[];for(let customModule of customModules){let{path,implementation:maybeImplementation}=customModule;this.registeredModules.has(path)||(this.registeredModules.add(path),isObservable(maybeImplementation)?sources.push(maybeImplementation.pipe(tap(implementation=>{Quill.register(path,implementation,suppressGlobalRegisterWarning)}))):Quill.register(path,maybeImplementation,suppressGlobalRegisterWarning))}return sources.length>0?forkJoin(sources).pipe(map(()=>Quill)):of(Quill)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||QuillService2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:QuillService2,factory:QuillService2.\u0275fac,providedIn:"root"})}}return QuillService2})(),QuillEditorBase=(()=>{class QuillEditorBase2{constructor(){this.format=input(void 0),this.theme=input(void 0),this.modules=input(void 0),this.debug=input(!1),this.readOnly=input(!1),this.placeholder=input(void 0),this.maxLength=input(void 0),this.minLength=input(void 0),this.required=input(!1),this.formats=input(void 0),this.customToolbarPosition=input("top"),this.sanitize=input(void 0),this.beforeRender=input(void 0),this.styles=input(null),this.registry=input(void 0),this.bounds=input(void 0),this.customOptions=input([]),this.customModules=input([]),this.trackChanges=input(void 0),this.classes=input(void 0),this.trimOnValidation=input(!1),this.linkPlaceholder=input(void 0),this.compareValues=input(!1),this.filterNull=input(!1),this.debounceTime=input(void 0),this.defaultEmptyValue=input(null),this.onEditorCreated=new EventEmitter,this.onEditorChanged=new EventEmitter,this.onContentChanged=new EventEmitter,this.onSelectionChanged=new EventEmitter,this.onFocus=new EventEmitter,this.onBlur=new EventEmitter,this.onNativeFocus=new EventEmitter,this.onNativeBlur=new EventEmitter,this.disabled=!1,this.toolbarPosition=signal("top"),this.eventsSubscription=null,this.quillSubscription=null,this.elementRef=inject(ElementRef),this.cd=inject(ChangeDetectorRef),this.domSanitizer=inject(DomSanitizer),this.platformId=inject(PLATFORM_ID),this.renderer=inject(Renderer2),this.zone=inject(NgZone),this.service=inject(QuillService),this.destroyRef=inject(DestroyRef),this.valueGetter=input(quillEditor=>{let html=quillEditor.getSemanticHTML();this.isEmptyValue(html)&&(html=this.defaultEmptyValue());let modelValue=html,format2=getFormat2(this.format(),this.service.config.format);if(format2==="text")modelValue=quillEditor.getText();else if(format2==="object")modelValue=quillEditor.getContents();else if(format2==="json")try{modelValue=JSON.stringify(quillEditor.getContents())}catch{modelValue=quillEditor.getText()}return modelValue}),this.valueSetter=input((quillEditor,value)=>{let format2=getFormat2(this.format(),this.service.config.format);if(format2==="html")return([!0,!1].includes(this.sanitize())?this.sanitize():this.service.config.sanitize||!1)&&(value=this.domSanitizer.sanitize(SecurityContext.HTML,value)),quillEditor.clipboard.convert({html:value});if(format2==="json")try{return JSON.parse(value)}catch{return[{insert:value}]}return value}),this.selectionChangeHandler=(range4,oldRange,source)=>{let trackChanges=this.trackChanges()||this.service.config.trackChanges,shouldTriggerOnModelTouched=!range4&&!!this.onModelTouched&&(source==="user"||trackChanges&&trackChanges==="all");!this.onBlur.observed&&!this.onFocus.observed&&!this.onSelectionChanged.observed&&!shouldTriggerOnModelTouched||this.zone.run(()=>{range4===null?this.onBlur.emit({editor:this.quillEditor,source}):oldRange===null&&this.onFocus.emit({editor:this.quillEditor,source}),this.onSelectionChanged.emit({editor:this.quillEditor,oldRange,range:range4,source}),shouldTriggerOnModelTouched&&this.onModelTouched(),this.cd.markForCheck()})},this.textChangeHandler=(delta,oldDelta,source)=>{let text=this.quillEditor.getText(),content=this.quillEditor.getContents(),html=this.quillEditor.getSemanticHTML();this.isEmptyValue(html)&&(html=this.defaultEmptyValue());let trackChanges=this.trackChanges()||this.service.config.trackChanges,shouldTriggerOnModelChange=(source==="user"||trackChanges&&trackChanges==="all")&&!!this.onModelChange;!this.onContentChanged.observed&&!shouldTriggerOnModelChange||this.zone.run(()=>{if(shouldTriggerOnModelChange){let valueGetter=this.valueGetter();this.onModelChange(valueGetter(this.quillEditor))}this.onContentChanged.emit({content,delta,editor:this.quillEditor,html,oldDelta,source,text}),this.cd.markForCheck()})},this.editorChangeHandler=(event2,current,old,source)=>{if(this.onEditorChanged.observed)if(event2==="text-change"){let text=this.quillEditor.getText(),content=this.quillEditor.getContents(),html=this.quillEditor.getSemanticHTML();this.isEmptyValue(html)&&(html=this.defaultEmptyValue()),this.zone.run(()=>{this.onEditorChanged.emit({content,delta:current,editor:this.quillEditor,event:event2,html,oldDelta:old,source,text}),this.cd.markForCheck()})}else this.zone.run(()=>{this.onEditorChanged.emit({editor:this.quillEditor,event:event2,oldRange:old,range:current,source}),this.cd.markForCheck()})},this.destroyRef.onDestroy(()=>{this.dispose(),this.quillSubscription?.unsubscribe(),this.quillSubscription=null})}static normalizeClassNames(classes){return classes.trim().split(" ").reduce((prev,cur)=>{let trimmed=cur.trim();return trimmed&&prev.push(trimmed),prev},[])}ngOnInit(){this.toolbarPosition.set(this.customToolbarPosition())}ngAfterViewInit(){isPlatformServer(this.platformId)||(this.quillSubscription=this.service.getQuill().pipe(mergeMap(Quill=>this.service.beforeRender(Quill,this.customModules(),this.beforeRender()))).subscribe(Quill=>{this.editorElem=this.elementRef.nativeElement.querySelector("[quill-editor-element]");let toolbarElem=this.elementRef.nativeElement.querySelector("[quill-editor-toolbar]"),modules=Object.assign({},this.modules()||this.service.config.modules);toolbarElem?modules.toolbar=toolbarElem:modules.toolbar===void 0&&(modules.toolbar=defaultModules.toolbar);let placeholder=this.placeholder()!==void 0?this.placeholder():this.service.config.placeholder;placeholder===void 0&&(placeholder="Insert text here ...");let styles=this.styles();styles&&Object.keys(styles).forEach(key=>{this.renderer.setStyle(this.editorElem,key,styles[key])}),this.classes()&&this.addClasses(this.classes()),this.customOptions().forEach(customOption=>{let newCustomOption=Quill.import(customOption.import);newCustomOption.whitelist=customOption.whitelist,Quill.register(newCustomOption,!0)});let bounds=this.bounds()&&this.bounds()==="self"?this.editorElem:this.bounds();bounds||(bounds=this.service.config.bounds?this.service.config.bounds:document.body);let debug2=this.debug();!debug2&&debug2!==!1&&this.service.config.debug&&(debug2=this.service.config.debug);let readOnly=this.readOnly();!readOnly&&this.readOnly()!==!1&&(readOnly=this.service.config.readOnly!==void 0?this.service.config.readOnly:!1);let formats=this.formats();if(!formats&&formats===void 0&&(formats=this.service.config.formats?[...this.service.config.formats]:this.service.config.formats===null?null:void 0),this.zone.runOutsideAngular(()=>{if(this.quillEditor=new Quill(this.editorElem,{bounds,debug:debug2,formats,modules,placeholder,readOnly,registry:this.registry(),theme:this.theme()||(this.service.config.theme?this.service.config.theme:"snow")}),this.onNativeBlur.observed){fromEvent(this.quillEditor.scroll.domNode,"blur").pipe(takeUntilDestroyed(this.destroyRef)).subscribe(()=>this.onNativeBlur.next({editor:this.quillEditor,source:"dom"}));let toolbar=this.quillEditor.getModule("toolbar");toolbar.container&&fromEvent(toolbar.container,"mousedown").pipe(takeUntilDestroyed(this.destroyRef)).subscribe(e=>e.preventDefault())}if(this.onNativeFocus.observed&&fromEvent(this.quillEditor.scroll.domNode,"focus").pipe(takeUntilDestroyed(this.destroyRef)).subscribe(()=>this.onNativeFocus.next({editor:this.quillEditor,source:"dom"})),this.linkPlaceholder()){let input2=this.quillEditor?.theme?.tooltip?.root?.querySelector("input[data-link]");input2?.dataset&&(input2.dataset.link=this.linkPlaceholder())}}),this.content){if(getFormat2(this.format(),this.service.config.format)==="text")this.quillEditor.setText(this.content,"silent");else{let newValue=this.valueSetter()(this.quillEditor,this.content);this.quillEditor.setContents(newValue,"silent")}this.quillEditor.getModule("history").clear()}this.setDisabledState(),this.addQuillEventListeners(),!(!this.onEditorCreated.observed&&!this.onValidatorChanged)&&raf$().pipe(takeUntilDestroyed(this.destroyRef)).subscribe(()=>{this.onValidatorChanged&&this.onValidatorChanged(),this.onEditorCreated.emit(this.quillEditor)})}))}ngOnChanges(changes){if(this.quillEditor){if(changes.readOnly&&this.quillEditor.enable(!changes.readOnly.currentValue),changes.placeholder&&(this.quillEditor.root.dataset.placeholder=changes.placeholder.currentValue),changes.styles){let currentStyling=changes.styles.currentValue,previousStyling=changes.styles.previousValue;previousStyling&&Object.keys(previousStyling).forEach(key=>{this.renderer.removeStyle(this.editorElem,key)}),currentStyling&&Object.keys(currentStyling).forEach(key=>{this.renderer.setStyle(this.editorElem,key,this.styles()[key])})}if(changes.classes){let currentClasses=changes.classes.currentValue,previousClasses=changes.classes.previousValue;previousClasses&&this.removeClasses(previousClasses),currentClasses&&this.addClasses(currentClasses)}changes.debounceTime&&this.addQuillEventListeners()}}addClasses(classList){QuillEditorBase2.normalizeClassNames(classList).forEach(c=>{this.renderer.addClass(this.editorElem,c)})}removeClasses(classList){QuillEditorBase2.normalizeClassNames(classList).forEach(c=>{this.renderer.removeClass(this.editorElem,c)})}writeValue(currentValue){if(this.filterNull()&&currentValue===null||(this.content=currentValue,!this.quillEditor))return;let format2=getFormat2(this.format(),this.service.config.format),newValue=this.valueSetter()(this.quillEditor,currentValue);if(this.compareValues()){let currentEditorValue=this.quillEditor.getContents();if(JSON.stringify(currentEditorValue)===JSON.stringify(newValue))return}if(currentValue){format2==="text"?this.quillEditor.setText(currentValue):this.quillEditor.setContents(newValue);return}this.quillEditor.setText("")}setDisabledState(isDisabled=this.disabled){this.disabled=isDisabled,this.quillEditor&&(isDisabled?(this.quillEditor.disable(),this.renderer.setAttribute(this.elementRef.nativeElement,"disabled","disabled")):(this.readOnly()||this.quillEditor.enable(),this.renderer.removeAttribute(this.elementRef.nativeElement,"disabled")))}registerOnChange(fn2){this.onModelChange=fn2}registerOnTouched(fn2){this.onModelTouched=fn2}registerOnValidatorChange(fn2){this.onValidatorChanged=fn2}validate(){if(!this.quillEditor)return null;let err={},valid=!0,text=this.quillEditor.getText(),textLength=this.trimOnValidation()?text.trim().length:text.length===1&&text.trim().length===0?0:text.length-1,deltaOperations=this.quillEditor.getContents().ops,onlyEmptyOperation=!!deltaOperations&&deltaOperations.length===1&&[`
820
820
  `,""].includes(deltaOperations[0].insert?.toString());return this.minLength()&&textLength&&textLength<this.minLength()&&(err.minLengthError={given:textLength,minLength:this.minLength()},valid=!1),this.maxLength()&&textLength>this.maxLength()&&(err.maxLengthError={given:textLength,maxLength:this.maxLength()},valid=!1),this.required()&&!textLength&&onlyEmptyOperation&&(err.requiredError={empty:!0},valid=!1),valid?null:err}addQuillEventListeners(){this.dispose(),this.zone.runOutsideAngular(()=>{this.eventsSubscription=new Subscription,this.eventsSubscription.add(fromEvent(this.quillEditor,"selection-change").subscribe(([range4,oldRange,source])=>{this.selectionChangeHandler(range4,oldRange,source)}));let textChange$=fromEvent(this.quillEditor,"text-change"),editorChange$=fromEvent(this.quillEditor,"editor-change");typeof this.debounceTime()=="number"&&(textChange$=textChange$.pipe(debounceTime(this.debounceTime())),editorChange$=editorChange$.pipe(debounceTime(this.debounceTime()))),this.eventsSubscription.add(textChange$.subscribe(([delta,oldDelta,source])=>{this.textChangeHandler(delta,oldDelta,source)})),this.eventsSubscription.add(editorChange$.subscribe(([event2,current,old,source])=>{this.editorChangeHandler(event2,current,old,source)}))})}dispose(){this.eventsSubscription?.unsubscribe(),this.eventsSubscription=null}isEmptyValue(html){return html==="<p></p>"||html==="<div></div>"||html==="<p><br></p>"||html==="<div><br></div>"}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||QuillEditorBase2)}}static{this.\u0275dir=\u0275\u0275defineDirective({type:QuillEditorBase2,inputs:{format:[1,"format"],theme:[1,"theme"],modules:[1,"modules"],debug:[1,"debug"],readOnly:[1,"readOnly"],placeholder:[1,"placeholder"],maxLength:[1,"maxLength"],minLength:[1,"minLength"],required:[1,"required"],formats:[1,"formats"],customToolbarPosition:[1,"customToolbarPosition"],sanitize:[1,"sanitize"],beforeRender:[1,"beforeRender"],styles:[1,"styles"],registry:[1,"registry"],bounds:[1,"bounds"],customOptions:[1,"customOptions"],customModules:[1,"customModules"],trackChanges:[1,"trackChanges"],classes:[1,"classes"],trimOnValidation:[1,"trimOnValidation"],linkPlaceholder:[1,"linkPlaceholder"],compareValues:[1,"compareValues"],filterNull:[1,"filterNull"],debounceTime:[1,"debounceTime"],defaultEmptyValue:[1,"defaultEmptyValue"],valueGetter:[1,"valueGetter"],valueSetter:[1,"valueSetter"]},outputs:{onEditorCreated:"onEditorCreated",onEditorChanged:"onEditorChanged",onContentChanged:"onContentChanged",onSelectionChanged:"onSelectionChanged",onFocus:"onFocus",onBlur:"onBlur",onNativeFocus:"onNativeFocus",onNativeBlur:"onNativeBlur"},features:[\u0275\u0275NgOnChangesFeature]})}}return QuillEditorBase2})(),QuillEditorComponent=(()=>{class QuillEditorComponent2 extends QuillEditorBase{static{this.\u0275fac=(()=>{let \u0275QuillEditorComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275QuillEditorComponent_BaseFactory||(\u0275QuillEditorComponent_BaseFactory=\u0275\u0275getInheritedFactory(QuillEditorComponent2)))(__ngFactoryType__||QuillEditorComponent2)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:QuillEditorComponent2,selectors:[["quill-editor"]],features:[\u0275\u0275ProvidersFeature([{multi:!0,provide:NG_VALUE_ACCESSOR,useExisting:forwardRef(()=>QuillEditorComponent2)},{multi:!0,provide:NG_VALIDATORS,useExisting:forwardRef(()=>QuillEditorComponent2)}]),\u0275\u0275InheritDefinitionFeature],ngContentSelectors:_c16,decls:5,vars:2,consts:[["quill-editor-element",""]],template:function(rf,ctx){rf&1&&(\u0275\u0275projectionDef(_c016),\u0275\u0275conditionalCreate(0,QuillEditorComponent_Conditional_0_Template,1,0,"div",0),\u0275\u0275projection(1),\u0275\u0275projection(2,1),\u0275\u0275projection(3,2),\u0275\u0275conditionalCreate(4,QuillEditorComponent_Conditional_4_Template,1,0,"div",0)),rf&2&&(\u0275\u0275conditional(ctx.toolbarPosition()!=="top"?0:-1),\u0275\u0275advance(4),\u0275\u0275conditional(ctx.toolbarPosition()==="top"?4:-1))},styles:["[_nghost-%COMP%]{display:inline-block}"]})}}return QuillEditorComponent2})();var import_markdown_it2=__toESM(require_markdown_it());function renderMarkdownToHtml(markdown){let markdownIt=new import_markdown_it2.default({typographer:!0}),defaultRender=markdownIt.renderer.rules.link_open||function(tokens,idx,options,env,self2){return self2.renderToken(tokens,idx,options)};return markdownIt.renderer.rules.link_open=function(tokens,idx,options,env,self2){return tokens[idx].attrPush(["target","_blank"]),defaultRender(tokens,idx,options,env,self2)},markdownIt.render(markdown)}var indentRegex=/^ql-indent-([0-9]+)/;function addStylingToQuillContent(content){let htmlObject=document.createElement("div");return htmlObject.innerHTML=content,addStylingToHtmlChildNodes(htmlObject.childNodes),htmlObject.innerHTML}function addStylingToHtmlChildNodes(children){children.forEach(child=>{let element=child;setCodeBlockStyling(element),setIndentStyling(element),setListStyling(element),setQuotesStyling(element),child.childNodes.length&&addStylingToHtmlChildNodes(child.childNodes)})}function setCodeBlockStyling(element){element.tagName==="PRE"&&(element.hasAttribute("data-language")||element.classList?.contains("ql-syntax"))&&(element.style.backgroundColor="#f6f8fa",element.style.color="initial",element.style.overflow="visible",element.style.padding="5px 10px")}function setIndentStyling(element){element.classList?.forEach(className=>{let matches=className.match(indentRegex);if(matches?.[1]){let identNumber=parseInt(matches?.[1]);element.style.paddingLeft=3*identNumber+"em"}})}function setListStyling(element){element.tagName==="OL"&&(element.style.paddingLeft="1.5em"),element.tagName==="LI"&&(element.style.listStylePosition="inside")}function setQuotesStyling(element){element.tagName==="BLOCKQUOTE"&&(element.style.borderLeft="4px solid #ccc",element.style.margin="5px 0",element.style.paddingLeft="16px")}function registerQuillModules(){registerAlignStyle(),registerBlock()}function registerAlignStyle(){let alignStyle=quill_default.import("attributors/style/align");quill_default.register(alignStyle,!0)}function registerBlock(){let block=quill_default.import("blots/block");block.tagName="DIV",quill_default.register(block)}var _c017=()=>({height:"400px"});function RichTextFormFieldComponent_Conditional_0_Template(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"form",0)(1,"quill-editor",2),\u0275\u0275listener("onEditorCreated",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.onEditorCreated($event))})("keydown.backspace",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView($event.stopPropagation())})("keydown.delete",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementStart(2,"div",3)(3,"span",4)(4,"select",5),\u0275\u0275element(5,"option",6)(6,"option",7)(7,"option",8)(8,"option",9)(9,"option",10)(10,"option",11),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(11,"span",4),\u0275\u0275element(12,"button",12)(13,"button",13)(14,"button",14)(15,"button",15),\u0275\u0275elementEnd(),\u0275\u0275elementStart(16,"span",4),\u0275\u0275element(17,"button",16)(18,"button",17),\u0275\u0275elementEnd(),\u0275\u0275elementStart(19,"span",4)(20,"select",18),\u0275\u0275element(21,"option",6)(22,"option",19)(23,"option",20)(24,"option",21),\u0275\u0275elementEnd(),\u0275\u0275element(25,"button",22)(26,"button",23),\u0275\u0275elementEnd(),\u0275\u0275elementStart(27,"span",4),\u0275\u0275element(28,"button",24)(29,"button",25),\u0275\u0275elementEnd(),\u0275\u0275elementStart(30,"span",4),\u0275\u0275element(31,"button",26)(32,"button",27)(33,"button",28),\u0275\u0275elementEnd()()()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext();\u0275\u0275property("formGroup",ctx_r1.form),\u0275\u0275advance(),\u0275\u0275property("styles",\u0275\u0275pureFunction0(16,_c017))("placeholder",ctx_r1.field.inputDescription.placeholder||""),\u0275\u0275advance(11),\u0275\u0275property("matTooltip","Bold"),\u0275\u0275advance(),\u0275\u0275property("matTooltip","Italic"),\u0275\u0275advance(),\u0275\u0275property("matTooltip","Underline"),\u0275\u0275advance(),\u0275\u0275property("matTooltip","Strike-through"),\u0275\u0275advance(2),\u0275\u0275property("matTooltip","Text color"),\u0275\u0275advance(),\u0275\u0275property("matTooltip","Highlight color"),\u0275\u0275advance(7),\u0275\u0275property("matTooltip","Decrease indent"),\u0275\u0275advance(),\u0275\u0275property("matTooltip","Increase indent"),\u0275\u0275advance(2),\u0275\u0275property("matTooltip","Bulleted list"),\u0275\u0275advance(),\u0275\u0275property("matTooltip","Numbered list"),\u0275\u0275advance(2),\u0275\u0275property("matTooltip","Blockquote"),\u0275\u0275advance(),\u0275\u0275property("matTooltip","Code Block"),\u0275\u0275advance(),\u0275\u0275property("matTooltip","Insert link")}}function RichTextFormFieldComponent_Conditional_1_Template(rf,ctx){if(rf&1){let _r3=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"div",1)(1,"textarea",29),\u0275\u0275listener("keydown.enter",function($event){return \u0275\u0275restoreView(_r3),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementEnd(),\u0275\u0275elementStart(2,"a",30),\u0275\u0275pipe(3,"translate"),\u0275\u0275elementStart(4,"mat-icon"),\u0275\u0275text(5,"markdown"),\u0275\u0275elementEnd()()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275property("formControl",ctx_r1.form.controls.editor)("placeholder",ctx_r1.field.inputDescription.placeholder||""),\u0275\u0275advance(),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(3,4,"MARKDOWN_IS_SUPPORTED"))("matTooltipPosition","left")}}var RichTextFormFieldComponent=(()=>{class RichTextFormFieldComponent2{constructor(){this.mode="rich-text",this.modeChange=new EventEmitter,this.valueChange=new EventEmitter,this.destroy=inject(DestroyRef),this.dialog=inject(MatDialog),this.doc=inject(DOCUMENT),this.formBuilder=inject(FormBuilder),this.colorPickerPanelService=inject(ColorPickerPanelService),this.ngZone=inject(NgZone),this.translate=inject(TranslateService),this.activeMode="rich-text",this.modules={toolbar:{container:"#toolbar"}},this.form=this.formBuilder.nonNullable.group({editor:[""]})}blockPaste(e){e.stopPropagation()}blockCopy(e){e.stopPropagation()}blockCut(e){e.stopPropagation()}get isDark(){return this.doc.body.classList.contains("dark")}ngOnInit(){registerQuillModules(),typeof this.field.value=="string"&&this.form.setValue({editor:this.field.value}),this.form.controls.editor.valueChanges.pipe(takeUntilDestroyed(this.destroy)).subscribe(value=>this.valueChange.emit(this.mode==="rich-text"?addStylingToQuillContent(value):value))}ngOnChanges(changes){changes.mode.firstChange&&(this.activeMode=this.mode),changes.mode.previousValue==="plain-text"&&changes.mode.currentValue==="rich-text"&&this.switchFromPlainTextToRichText(),changes.mode.previousValue==="rich-text"&&changes.mode.currentValue==="plain-text"&&this.mode!==this.activeMode&&(this.previousFormValue=this.form.value,this.activeMode=this.mode)}onEditorCreated(editor){this.quill=editor;let toolbar=editor.getModule("toolbar"),backgroundButton=toolbar.container?.querySelector(".ql-background"),colorButton=toolbar.container?.querySelector(".ql-color");backgroundButton&&toolbar.addHandler("background",()=>this.openColorPicker(backgroundButton,"background")),colorButton&&toolbar.addHandler("color",()=>this.openColorPicker(colorButton,"color")),editor.on("selection-change",range4=>{range4&&(this.setColorButtonColor(range4),this.setBackgroundButtonColor(range4))})}getColors(colors){return[...colors||[],"#F44336","#2196F3","#4CAF50","#FFC107","#9E9E9E"]}openColorPicker(element,format2){this.ngZone.run(()=>{let range4=this.quill.getSelection();if(range4){let defaultForegroundColor=this.isDark?"#FFFFFF":"#000000",defaultBackgroundColor=this.isDark?"#000000":"#FFFFFF",defaultColor=format2==="color"?defaultForegroundColor:defaultBackgroundColor,item=this.quill.getFormat(range4),colors=this.getColors([defaultColor]),currentColor=(item[format2]??defaultColor).toUpperCase(),colorPickerColor=currentColor==="TRANSPARENT"?defaultColor:currentColor;colors.includes(colorPickerColor)||colors.push(colorPickerColor),this.colorPickerPanelService.show(element,{color:colorPickerColor,colors}).afterClosed().subscribe(color=>{this.quill.format(format2,color===defaultColor?!1:color,quill_default.sources.USER),this[format2==="color"?"updateColorButtonColor":"updateBackgroundButtonColor"]()})}})}updateColorButtonColor(){let range4=this.quill.getSelection();range4&&this.setColorButtonColor(range4)}updateBackgroundButtonColor(){let range4=this.quill.getSelection();range4&&this.setBackgroundButtonColor(range4)}setColorButtonColor(range4){let color=this.quill.getFormat(range4)?.color?.toUpperCase(),colorLabel=this.quill.getModule("toolbar").container?.querySelector(".ql-color .ql-stroke");colorLabel&&(color&&color!=="TRANSPARENT"?colorLabel.style.stroke=color==="#FFFFFF"?"#E1E1E1":color:colorLabel.style.stroke=this.isDark?"#FFFFFF":"#000000")}setBackgroundButtonColor(range4){let color=this.quill.getFormat(range4)?.background?.toUpperCase(),colorLabel=this.quill.getModule("toolbar").container?.querySelector(".ql-background .ql-fill");colorLabel&&(color&&color!=="TRANSPARENT"?colorLabel.style.fill=color:colorLabel.style.fill="#E1E1E1")}switchFromPlainTextToRichText(){let formValue=this.form.value;formValue.editor!==""&&formValue.editor!==this.previousFormValue?.editor?this.dialog.open(ConfirmDialogComponent,{data:{title:this.translate.instant("WARNING"),message:this.translate.instant("__TEXT__.MARKDOWN_FORMATTING_TO_RICH_TEXT")}}).afterClosed().subscribe(confirmed=>{if(confirmed){if(this.activeMode="rich-text",this.modeChange.emit("rich-text"),formValue.editor){let html=renderMarkdownToHtml(formValue.editor),editor=addStylingToQuillContent(html);this.form.patchValue({editor})}}else this.modeChange.emit("plain-text")}):(this.activeMode="rich-text",this.modeChange.emit("rich-text"))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||RichTextFormFieldComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:RichTextFormFieldComponent2,selectors:[["ix-rich-text-form-field"]],hostBindings:function(rf,ctx){rf&1&&\u0275\u0275listener("paste",function($event){return ctx.blockPaste($event)})("copy",function($event){return ctx.blockCopy($event)})("cut",function($event){return ctx.blockCut($event)})},inputs:{field:"field",mode:"mode"},outputs:{modeChange:"modeChange",valueChange:"valueChange"},features:[\u0275\u0275NgOnChangesFeature],decls:2,vars:1,consts:[[3,"formGroup"],[1,"plain-text"],["bounds","self","formControlName","editor",3,"onEditorCreated","keydown.backspace","keydown.delete","styles","placeholder"],["quill-editor-toolbar","","data-testid","rich-text-toolbar"],[1,"ql-formats"],[1,"ql-header"],["selected",""],["value","1"],["value","2"],["value","3"],["value","4"],["value","5"],["matTooltipShowDelay","500",1,"ql-bold",3,"matTooltip"],["matTooltipShowDelay","500",1,"ql-italic",3,"matTooltip"],["matTooltipShowDelay","500",1,"ql-underline",3,"matTooltip"],["matTooltipShowDelay","500",1,"ql-strike",3,"matTooltip"],["matTooltipShowDelay","500","data-testid","rich-text-color-button",1,"ql-color",3,"matTooltip"],["matTooltipShowDelay","500",1,"ql-background",3,"matTooltip"],[1,"ql-align"],["value","center"],["value","right"],["value","justify"],["value","-1","matTooltipShowDelay","500",1,"ql-indent",3,"matTooltip"],["value","+1","matTooltipShowDelay","500",1,"ql-indent",3,"matTooltip"],["value","bullet","matTooltipShowDelay","500",1,"ql-list",3,"matTooltip"],["value","ordered","matTooltipShowDelay","500",1,"ql-list",3,"matTooltip"],["matTooltipShowDelay","500",1,"ql-blockquote",3,"matTooltip"],["matTooltipShowDelay","500",1,"ql-code-block",3,"matTooltip"],["matTooltipShowDelay","500",1,"ql-link",3,"matTooltip"],[3,"keydown.enter","formControl","placeholder"],["href","https://commonmark.org/help/","target","_blank","mat-icon-button","",1,"markdown-info-button",3,"matTooltip","matTooltipPosition"]],template:function(rf,ctx){rf&1&&\u0275\u0275conditionalCreate(0,RichTextFormFieldComponent_Conditional_0_Template,34,17,"form",0)(1,RichTextFormFieldComponent_Conditional_1_Template,6,6,"div",1),rf&2&&\u0275\u0275conditional(ctx.activeMode==="rich-text"?0:1)},dependencies:[ReactiveFormsModule,\u0275NgNoValidate,NgSelectOption,\u0275NgSelectMultipleOption,DefaultValueAccessor,NgControlStatus,NgControlStatusGroup,FormControlDirective,FormGroupDirective,FormControlName,FlexLayoutModule,MatButtonModule,MatIconButton,MatDialogModule,MatFormFieldModule,MatIconModule,MatIcon,MatInputModule,MatTooltipModule,MatTooltip,QuillEditorComponent,TranslateModule,TranslatePipe],styles:['[_nghost-%COMP%]{display:block}[_nghost-%COMP%] quill-editor[_ngcontent-%COMP%]{width:100%;color:var(--mat-sys-on-surface)}[_nghost-%COMP%] form[_ngcontent-%COMP%]{display:flex}[_nghost-%COMP%] .plain-text[_ngcontent-%COMP%]{display:flex;position:relative;width:100%;font-family:Roboto,sans-serif;white-space:pre-wrap;overflow-wrap:break-word}[_nghost-%COMP%] .plain-text[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{width:100%;height:441px;max-height:441px;box-sizing:border-box;padding:12px;border-radius:4px 4px 0 0;background-color:var(--mat-sys-surface-variant);border:none;border-bottom:1px solid rgba(0,0,0,.42);resize:none}[_nghost-%COMP%] .plain-text[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]:focus-visible{outline:none}[_nghost-%COMP%] .plain-text[_ngcontent-%COMP%] .markdown-info-button[_ngcontent-%COMP%]{position:absolute;right:5px;bottom:5px}[_nghost-%COMP%] .ql-toolbar{border-radius:4px 4px 0 0}[_nghost-%COMP%] .ql-toolbar.ql-snow{display:flex;flex-flow:row wrap;row-gap:4px;background-color:var(--mat-sys-surface-variant);border:none;border-bottom:1px solid rgba(0,0,0,.12)}[_nghost-%COMP%] .ql-toolbar.ql-snow button, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-label, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-item{color:var(--mat-sys-on-surface)}[_nghost-%COMP%] .ql-toolbar.ql-snow button .ql-fill, [_nghost-%COMP%] .ql-toolbar.ql-snow button .ql-stroke.ql-fill, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-label .ql-fill, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-label .ql-stroke.ql-fill, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-item .ql-fill, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-item .ql-stroke.ql-fill{fill:var(--mat-sys-on-surface)}[_nghost-%COMP%] .ql-toolbar.ql-snow button .ql-stroke, [_nghost-%COMP%] .ql-toolbar.ql-snow button .ql-stroke-miter, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-label .ql-stroke, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-label .ql-stroke-miter, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-item .ql-stroke, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-item .ql-stroke-miter{stroke:var(--mat-sys-on-surface)}[_nghost-%COMP%] .ql-toolbar.ql-snow button:hover, [_nghost-%COMP%] .ql-toolbar.ql-snow button:focus, [_nghost-%COMP%] .ql-toolbar.ql-snow button.ql-active, [_nghost-%COMP%] .ql-toolbar.ql-snow button.ql-selected, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-label:hover, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-label:focus, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-label.ql-active, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-label.ql-selected, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-item:hover, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-item:focus, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-item.ql-active, [_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker-item.ql-selected{background-color:#00000014;border-radius:4px}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker.ql-expanded .ql-picker-label{border-color:transparent}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker .ql-picker-options{border-radius:8px;border:none}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker.ql-header .ql-picker-label.ql-active:not(:hover,:focus){background-color:inherit}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker.ql-header .ql-picker-label>svg>polygon:nth-child(1){stroke-linejoin:initial;transform:translateY(-2px)}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker.ql-header .ql-picker-label>svg>polygon:nth-child(2){display:none}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker.ql-header .ql-picker-options{padding-left:0;padding-right:0}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker.ql-header .ql-picker-options .ql-picker-item{padding-left:8px;padding-right:8px;border-radius:0}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker.ql-header .ql-picker-options .ql-picker-item[data-value="1"]{padding-top:10px}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-picker.ql-header .ql-picker-options .ql-picker-item[data-value="2"]{padding-top:8px}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-align.ql-picker.ql-expanded .ql-picker-options{display:flex;padding:4px 4px 3px}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-align.ql-picker.ql-expanded .ql-picker-options .ql-picker-item{padding:4px}[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-color .ql-color-label.ql-stroke.ql-transparent{opacity:1;stroke-linecap:square;stroke-width:4}@media (min-resolution: 2dppx){[_nghost-%COMP%] .ql-toolbar.ql-snow .ql-color .ql-color-label.ql-stroke.ql-transparent{stroke-width:3}}[_nghost-%COMP%] .ql-snow{font-family:Roboto,sans-serif}[_nghost-%COMP%] .ql-snow a{color:var(--mat-sys-primary)}[_nghost-%COMP%] .ql-snow .ql-code-block-container{background-color:#f6f8fa!important;border:1px solid rgba(0,0,0,.12);color:initial!important}[_nghost-%COMP%] .ql-container{border-radius:0}[_nghost-%COMP%] .ql-container.ql-snow{background-color:var(--mat-sys-surface-variant);border:none;border-bottom:1px solid color-mix(in srgb,transparent,currentcolor 42%)}[_nghost-%COMP%] .ql-container .ql-editor.ql-blank:before{font-style:normal;color:color-mix(in srgb,transparent,currentcolor 42%)}']})}}return RichTextFormFieldComponent2})();var RichTextDialogComponent=(()=>{class RichTextDialogComponent2{constructor(){this.data=inject(MAT_DIALOG_DATA),this.destroy=inject(DestroyRef),this.dialog=inject(MatDialog),this.dialogRef=inject(MatDialogRef),this.modules={toolbar:{container:"#toolbar"}}}ngOnInit(){this.dialogRef.keydownEvents().pipe(takeUntilDestroyed(this.destroy)).subscribe(event2=>{event2.key==="Escape"&&this.openDiscardChangesWarningDialog()}),this.dialogRef.backdropClick().pipe(takeUntilDestroyed(this.destroy)).subscribe(()=>this.openDiscardChangesWarningDialog())}get activeMode(){return this.formField?.activeMode??this.data.mode}submit(){let formValue=this.formField.form.value,editor=formValue.editor?addStylingToQuillContent(formValue.editor):null;this.dialogRef.close({value:editor})}toggleMode(){this.data.mode=this.data.mode==="rich-text"?"plain-text":"rich-text"}updateMode(mode){this.data.mode=mode}openDiscardChangesWarningDialog(){this.formField.form.dirty?this.dialog.open(DiscardChangesDialogComponent,{panelClass:"fullscreen"}).afterClosed().subscribe(confirmed=>{confirmed&&this.dialogRef.close()}):this.dialogRef.close()}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||RichTextDialogComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:RichTextDialogComponent2,selectors:[["ix-rich-text-dialog"]],viewQuery:function(rf,ctx){if(rf&1&&\u0275\u0275viewQuery(RichTextFormFieldComponent,5),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.formField=_t.first)}},decls:16,vars:8,consts:[["mat-dialog-title","","translate","","data-testid","rich-text-dialog-title"],["mat-dialog-content",""],[3,"modeChange","field","mode"],["type","button","mat-stroked-button","","data-testid","change-mode-button",1,"change-mode-button",3,"click"],["fxFlex",""],["mat-button","","mat-dialog-close",""],["translate",""],["mat-button","","color","primary",3,"click"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"h1",0),\u0275\u0275text(1),\u0275\u0275pipe(2,"titlecase"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"div",1)(4,"ix-rich-text-form-field",2),\u0275\u0275listener("modeChange",function($event){return ctx.updateMode($event)}),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"mat-dialog-actions")(6,"button",3),\u0275\u0275listener("click",function(){return ctx.toggleMode()}),\u0275\u0275text(7),\u0275\u0275pipe(8,"translate"),\u0275\u0275elementEnd(),\u0275\u0275element(9,"span",4),\u0275\u0275elementStart(10,"button",5)(11,"span",6),\u0275\u0275text(12,"CANCEL"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(13,"button",7),\u0275\u0275listener("click",function(){return ctx.submit()}),\u0275\u0275elementStart(14,"span",6),\u0275\u0275text(15,"CONFIRM"),\u0275\u0275elementEnd()()()),rf&2&&(\u0275\u0275advance(),\u0275\u0275textInterpolate(\u0275\u0275pipeBind1(2,4,ctx.data.field.inputName)),\u0275\u0275advance(3),\u0275\u0275property("field",ctx.data.field)("mode",ctx.data.mode),\u0275\u0275advance(3),\u0275\u0275textInterpolate1(" ",\u0275\u0275pipeBind1(8,6,ctx.activeMode==="rich-text"?"SWITCH_TO_PLAIN_TEXT_EDITING":"SWITCH_TO_RICH_TEXT_EDITING")," "))},dependencies:[FlexLayoutModule,DefaultFlexDirective,MatButtonModule,MatButton,MatDialogModule,MatDialogClose,MatDialogTitle,MatDialogActions,MatDialogContent,MatFormFieldModule,MatIconModule,MatInputModule,MatTooltipModule,TranslateModule,TranslateDirective,RichTextFormFieldComponent,TitleCasePipe,TranslatePipe],styles:["[_nghost-%COMP%]{width:100dvw;height:100dvh;display:flex;flex-direction:column;flex:1}@media (min-width: 960px){[_nghost-%COMP%]{height:auto;width:auto;min-width:908px;max-width:908px}}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%]{padding:calc(env(safe-area-inset-top,0) + 16px) 24px 16px}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] .mat-toolbar{height:48px;padding-left:0;padding-right:0}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] .mat-toolbar .mdc-dialog__title{--mat-dialog-headline-padding: 0;color:inherit}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] .mat-toolbar .mdc-dialog__title:before{display:none}[_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] + .ix-dialog__content[_ngcontent-%COMP%], [_nghost-%COMP%] .ix-dialog__header[_ngcontent-%COMP%] + .mdc-dialog__content[_ngcontent-%COMP%]{padding-top:0}[_nghost-%COMP%] .mdc-dialog__title[_ngcontent-%COMP%]:before{height:calc(env(safe-area-inset-top,0) + 40px)}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%]{padding:20px 24px}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%] > .ix-list[_ngcontent-%COMP%]{margin-left:-24px;margin-right:-24px}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%], [_nghost-%COMP%] .mdc-dialog__content[_ngcontent-%COMP%]{flex-direction:column;box-sizing:border-box;display:flex;place-content:stretch flex-start;align-items:stretch;flex:1 1 auto;max-height:none;overflow:auto;-webkit-overflow-scrolling:touch}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%] > .mat-mdc-subheader[_ngcontent-%COMP%], [_nghost-%COMP%] .mdc-dialog__content[_ngcontent-%COMP%] > .mat-mdc-subheader[_ngcontent-%COMP%]{margin-left:0;margin-right:0}@media (min-width: 960px){[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%], [_nghost-%COMP%] .mdc-dialog__content[_ngcontent-%COMP%]{max-height:calc(90dvh - 140px)}[_nghost-%COMP%] .ix-dialog__content[_ngcontent-%COMP%]:has(+.mdc-dialog__actions), [_nghost-%COMP%] .mdc-dialog__content[_ngcontent-%COMP%]:has(+.mdc-dialog__actions){padding-bottom:0}}@media (min-width: 960px){[_nghost-%COMP%] .ix-dialog__banner[_ngcontent-%COMP%] + .ix-dialog__content[_ngcontent-%COMP%]{max-height:calc(90dvh - 225px)}}@media (max-width: 959.9px){[_nghost-%COMP%] .mdc-dialog__actions[_ngcontent-%COMP%]{border-top:1px solid rgba(0,0,0,.12);padding-bottom:calc(16px + env(safe-area-inset-bottom,0))}}[_nghost-%COMP%] form[_ngcontent-%COMP%]{flex-direction:column;box-sizing:border-box;display:flex;flex:1 1 auto;height:inherit}[_nghost-%COMP%] form[_ngcontent-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{margin-bottom:1rem}[_nghost-%COMP%] .mat-mdc-dialog-content[_ngcontent-%COMP%]{padding-bottom:8px}[_nghost-%COMP%] .mat-mdc-dialog-actions[_ngcontent-%COMP%] .change-mode-button[_ngcontent-%COMP%]{--mat-button-outlined-container-height: 30px;--mat-button-outlined-label-text-size: 13px}"]})}}return RichTextDialogComponent2})();function RichTextInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function RichTextInputComponent_Conditional_1_Template(rf,ctx){if(rf&1){let _r2=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-rich-text-form-field",2),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r2);let ctx_r0=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r0.updateValue($event))})("modeChange",function($event){\u0275\u0275restoreView(_r2);let ctx_r0=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r0.updateMode($event))}),\u0275\u0275elementEnd(),\u0275\u0275elementStart(1,"button",3),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r2);let ctx_r0=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r0.toggleMode())}),\u0275\u0275text(2),\u0275\u0275pipe(3,"translate"),\u0275\u0275elementEnd()}if(rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("field",ctx_r0.field)("mode",ctx_r0.mode),\u0275\u0275advance(2),\u0275\u0275textInterpolate1(" ",\u0275\u0275pipeBind1(3,3,ctx_r0.activeMode==="rich-text"?"SWITCH_TO_PLAIN_TEXT_EDITING":"SWITCH_TO_RICH_TEXT_EDITING")," ")}}function RichTextInputComponent_Conditional_2_Conditional_4_Template(rf,ctx){if(rf&1){let _r4=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-translation-icon-button",7),\u0275\u0275listener("setTranslationKey",function($event){\u0275\u0275restoreView(_r4);let ctx_r0=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r0.setTranslationKey($event))}),\u0275\u0275elementEnd()}if(rf&2){let ctx_r0=\u0275\u0275nextContext(2);\u0275\u0275property("key",ctx_r0.translationKey)}}function RichTextInputComponent_Conditional_2_Conditional_7_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",6),\u0275\u0275text(1,"__MESSAGE__.REQUIRED"),\u0275\u0275elementEnd())}function RichTextInputComponent_Conditional_2_Template(rf,ctx){if(rf&1){let _r3=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-form-field",1)(1,"mat-label"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"textarea",4),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r3);let ctx_r0=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r0.openEditRichTextDialog())}),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(4,RichTextInputComponent_Conditional_2_Conditional_4_Template,1,1,"ix-translation-icon-button",5),\u0275\u0275elementStart(5,"mat-hint"),\u0275\u0275text(6),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(7,RichTextInputComponent_Conditional_2_Conditional_7_Template,2,0,"mat-error",6),\u0275\u0275elementEnd()}if(rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("formGroup",ctx_r0.componentFormGroup),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("value",ctx_r0.text)("placeholder",ctx_r0.field.inputDescription.placeholder||""),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.translation?4:-1),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.hint),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r0.inputControl!=null&&ctx_r0.inputControl.hasError("required")?7:-1)}}function RichTextInputComponent_Conditional_3_Template(rf,ctx){if(rf&1){let _r5=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-form-field")(1,"mat-label"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275element(3,"textarea",8),\u0275\u0275pipe(4,"translate"),\u0275\u0275pipe(5,"trimTranslationNamespace"),\u0275\u0275elementStart(6,"ix-translation-icon-button",7),\u0275\u0275listener("setTranslationKey",function($event){\u0275\u0275restoreView(_r5);let ctx_r0=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r0.setTranslationKey($event))}),\u0275\u0275elementEnd(),\u0275\u0275elementStart(7,"mat-hint"),\u0275\u0275text(8),\u0275\u0275elementEnd()()}if(rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("value",ctx_r0.translationKey?\u0275\u0275pipeBind1(5,7,\u0275\u0275pipeBind1(4,5,ctx_r0.translationKey)):"")("placeholder",ctx_r0.field.inputDescription.placeholder||""),\u0275\u0275advance(3),\u0275\u0275property("key",ctx_r0.translationKey),\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r0.field.inputDescription.hint)}}var RichTextInputComponent=(()=>{class RichTextInputComponent2 extends StringInputComponent{constructor(){super(...arguments),this.destroy=inject(DestroyRef),this.dialog=inject(MatDialog),this.dialogContainer=inject(MatDialogContainer,{optional:!0,skipSelf:!0}),this.domParser=new DOMParser,this.mode="rich-text"}get activeMode(){return this.formField?.activeMode??this.mode}get embedded(){return!!this.dialogContainer&&!this.translation}ngOnInit(){super.ngOnInit(),this.inputControl?.valueChanges.pipe(takeUntilDestroyed(this.destroy)).subscribe(value=>this.field.setValue(value));let initialValue=this.inputControl?.value;this.field.setValue(initialValue),initialValue&&!this.isHtml(initialValue)&&(this.mode="plain-text")}openEditRichTextDialog(){this.dialog.open(RichTextDialogComponent,{data:{field:this.field,mode:this.mode},autoFocus:!0,disableClose:!0,panelClass:"fullscreen"}).afterClosed().subscribe(result=>{result&&this.updateValue(result.value)})}get text(){let value=this.field.value;return value?value.replace(/<[^>]+>/g," ").replace(/\s+/g," ").trim():""}toggleMode(){this.mode=this.mode==="rich-text"?"plain-text":"rich-text"}updateMode(mode){this.mode=mode}updateValue(value){this.inputControl?.setValue(value)}isHtml(value){let doc=this.domParser.parseFromString(value,"text/html");return Array.from(doc.body.childNodes).some(node=>node.nodeType===Node.ELEMENT_NODE)}static{this.\u0275fac=(()=>{let \u0275RichTextInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275RichTextInputComponent_BaseFactory||(\u0275RichTextInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(RichTextInputComponent2)))(__ngFactoryType__||RichTextInputComponent2)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:RichTextInputComponent2,selectors:[["ix-rich-text-input"]],viewQuery:function(rf,ctx){if(rf&1&&\u0275\u0275viewQuery(RichTextFormFieldComponent,5),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.formField=_t.first)}},features:[\u0275\u0275InheritDefinitionFeature],decls:4,vars:2,consts:[[1,"description",3,"innerHTML"],[3,"formGroup"],[3,"valueChange","modeChange","field","mode"],["type","button","mat-stroked-button","","data-testid","change-mode-button",1,"change-mode-button",3,"click"],["matInput","","cdkTextareaAutosize","true","cdkAutosizeMinRows","2","cdkAutosizeMaxRows","5","readonly","",3,"click","value","placeholder"],[3,"key"],["translate",""],[3,"setTranslationKey","key"],["matInput","","cdkTextareaAutosize","true","cdkAutosizeMinRows","2","cdkAutosizeMaxRows","15","disabled","",3,"value","placeholder"]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,RichTextInputComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275conditionalCreate(1,RichTextInputComponent_Conditional_1_Template,4,5)(2,RichTextInputComponent_Conditional_2_Template,8,7,"mat-form-field",1)(3,RichTextInputComponent_Conditional_3_Template,9,9,"mat-form-field")),rf&2&&(\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.embedded?1:!ctx.translation||!ctx.translationKey?2:3))},dependencies:[TranslateModule,TranslateDirective,ReactiveFormsModule,NgControlStatusGroup,FormGroupDirective,MatButtonModule,MatButton,MatFormFieldModule,MatFormField,MatLabel,MatHint,MatError,MatInputModule,MatInput,CdkTextareaAutosize,TranslationIconButtonComponent,MarkdownModule,RichTextFormFieldComponent,TranslatePipe,RenderMarkdownPipe,TrimTranslationNamespacePipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{width:100%}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%] .hidden[_ngcontent-%COMP%]{display:none}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{overflow:hidden;width:calc(100% - 40px)}[_nghost-%COMP%] ix-rich-text-form-field[_ngcontent-%COMP%]{margin-bottom:12px}[_nghost-%COMP%] .change-mode-button[_ngcontent-%COMP%]{--mat-button-outlined-container-height: 30px;--mat-button-outlined-label-text-size: 13px;margin-bottom:22px}"]})}}return RichTextInputComponent2})();var ResourceSelectionInputFacade=(()=>{class ResourceSelectionInputFacade2{constructor(){this.store=inject(Store),this.translate=inject(TranslateService)}getAgentOrAssetId(version2,field){return version2?.previewAgent?.publicId?of(version2?.previewAgent?.publicId):version2?.previewAsset?.publicId?this.isGroupedResource(field.inputDescription.resource?.type)?this.store.select(selectEntity8(version2?.previewAsset?.publicId)).pipe(map(asset=>asset?.agent?.publicId)):of(version2?.previewAsset?.publicId):of(void 0)}isGroupedResource(resourceName){return resourceName?["AgentDataTag","AgentDataVariable"].includes(resourceName):!0}options(field,query){return this.store.select(selectEntity6(field.context.component.pageVersion?.publicId||null)).pipe(switchMap(version2=>combineLatest([this.getAgentOrAssetId(version2,field),query.valueChanges.pipe(startWith(query.value)),this.store.select(selectEntity(field?.context?.component?.template?.publicId||null))])),switchMap(([agentId,query2,pageComponent])=>{if(agentId){let resourceName=field.inputDescription.resource?.type,backendComponentId=pageComponent?pageComponent?.backendComponent?.publicId:"";switch(resourceName){case"AgentDataTag":return this.store.dispatch(ensureAll26({agentId,fields:AGENT_DATA_TAG_WITH_VARIABLE_LIST_FIELDS})),this.getGroupedAgentDataTags(agentId,query2);case"AgentDataVariable":return this.store.dispatch(ensureAll27({agentId})),this.getGroupedAgentDataVariables(agentId,query2);case"AssetAppConfigResource":return this.store.dispatch(ensureAllForRoot({rootId:agentId})),this.getAssetAppConfigResources(agentId,backendComponentId,query2);default:return of([])}}return of([])}))}getAssetAppConfigResources(assetId,backendComponentId,query){return combineLatest([this.store.select(selectAllForRoot(assetId)),this.store.select(selectAll25),this.store.select(selectEntities24)]).pipe(map(([assetTree,configs,resources])=>{let filteredConfigs=configs.filter(config3=>config3.app?.publicId===backendComponentId),options=this.findAssetResources(assetTree,filteredConfigs,resources).map(resource2=>({publicId:resource2?.publicId,name:resource2.name?isTranslationKey(resource2.name)?this.translate.instant(resource2.name):resource2.name:void 0}));if(query){let q=deburr_default(query.toLowerCase());options=options.filter(option=>option.name?.toLocaleLowerCase().includes(q))}return options}))}findAssetResources(assetList,configList,resourcesList){let allFoundResources=[],processedResourceIds=new Set,configMap=new Map;return configList.forEach(config3=>{config3.publicId&&configMap.set(config3.publicId,config3)}),assetList.forEach(asset=>{asset.appConfigs&&Array.isArray(asset.appConfigs)&&asset.appConfigs.forEach(appConfig=>{if(appConfig.publicId){let config3=configMap.get(appConfig.publicId);config3&&config3.resources&&Array.isArray(config3.resources)&&config3.resources.forEach(resourceRef=>{if(resourceRef.publicId){let resource2=resourcesList[resourceRef.publicId];resource2&&!processedResourceIds.has(resource2.publicId)&&(allFoundResources.push(resource2),processedResourceIds.add(resource2.publicId))}})}})}),allFoundResources}getGroupedAgentDataTags(agentId,query){return combineLatest([this.store.select(selectEntities27),this.store.select(selectAllForAgent2(agentId)),this.store.select(selectEntities22)]).pipe(map(([sourceEntities,tags,variableEntities])=>{let filteredTags=tags;if(query){let q=deburr_default(query.toLowerCase());filteredTags=tags.filter(tag=>tag.name?.toLocaleLowerCase().includes(q))}let optionGroups={};for(let tag of filteredTags)tag.source?.publicId&&tag.variable?.publicId&&!variableEntities[tag.variable.publicId]?.internalUse&&(optionGroups[tag.source?.publicId]||(optionGroups[tag.source?.publicId]=[]),optionGroups[tag.source?.publicId].push({publicId:tag.publicId,label:tag.name,sublabel:tag.slug}));return Object.keys(optionGroups).map(key=>({label:sourceEntities[key]?.name,options:optionGroups[key]}))}))}getGroupedAgentDataVariables(agentId,query){return combineLatest([this.store.select(selectEntities27),this.store.select(selectAllForAgent(agentId)),this.store.select(selectEntities22)]).pipe(map(([sourceEntities,variables,variableEntities])=>{let filteredVariables=variables;if(query){let q=deburr_default(query.toLowerCase());filteredVariables=variables.filter(variable=>variable.name?.toLocaleLowerCase().includes(q))}let optionGroups={};for(let variable of filteredVariables)variable.source?.publicId&&variable?.publicId&&!variableEntities[variable.publicId]?.internalUse&&(optionGroups[variable.source.publicId]||(optionGroups[variable.source.publicId]=[]),optionGroups[variable.source.publicId].push({publicId:variable.publicId,label:variable.name,sublabel:variable.slug}));return Object.keys(optionGroups).map(key=>({label:sourceEntities[key]?.name,options:optionGroups[key]}))}))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ResourceSelectionInputFacade2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:ResourceSelectionInputFacade2,factory:ResourceSelectionInputFacade2.\u0275fac,providedIn:"root"})}}return ResourceSelectionInputFacade2})();var _forTrack07=($index,$item)=>$item.publicId,_forTrack12=($index,$item)=>$item==null?null:$item.publicId;function ResourceSelectionInputComponent_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"p",0),\u0275\u0275pipe(1,"renderMarkdown")),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind1(1,1,ctx_r0.field.inputDescription.description),\u0275\u0275sanitizeHtml)}}function ResourceSelectionInputComponent_Conditional_11_For_1_Conditional_0_For_2_Conditional_4_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"span",7),\u0275\u0275text(1),\u0275\u0275elementEnd()),rf&2){let option_r2=\u0275\u0275nextContext().$implicit;\u0275\u0275advance(),\u0275\u0275textInterpolate(option_r2.sublabel)}}function ResourceSelectionInputComponent_Conditional_11_For_1_Conditional_0_For_2_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",5)(1,"span",6)(2,"span"),\u0275\u0275text(3),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(4,ResourceSelectionInputComponent_Conditional_11_For_1_Conditional_0_For_2_Conditional_4_Template,2,1,"span",7),\u0275\u0275elementEnd()()),rf&2){let option_r2=ctx.$implicit;\u0275\u0275property("value",option_r2.publicId),\u0275\u0275advance(3),\u0275\u0275textInterpolate(option_r2.label),\u0275\u0275advance(),\u0275\u0275conditional(option_r2.sublabel?4:-1)}}function ResourceSelectionInputComponent_Conditional_11_For_1_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-optgroup",4),\u0275\u0275repeaterCreate(1,ResourceSelectionInputComponent_Conditional_11_For_1_Conditional_0_For_2_Template,5,3,"mat-option",5,_forTrack07),\u0275\u0275elementEnd()),rf&2){let groupOption_r3=\u0275\u0275nextContext().$implicit;\u0275\u0275property("label",groupOption_r3.label),\u0275\u0275advance(),\u0275\u0275repeater(groupOption_r3==null?null:groupOption_r3.options)}}function ResourceSelectionInputComponent_Conditional_11_For_1_Template(rf,ctx){if(rf&1&&\u0275\u0275conditionalCreate(0,ResourceSelectionInputComponent_Conditional_11_For_1_Conditional_0_Template,3,1,"mat-optgroup",4),rf&2){let groupOption_r3=ctx.$implicit,ctx_r0=\u0275\u0275nextContext(2);\u0275\u0275conditional(ctx_r0.isOptionGroup(groupOption_r3)&&groupOption_r3.options.length?0:-1)}}function ResourceSelectionInputComponent_Conditional_11_Template(rf,ctx){if(rf&1&&\u0275\u0275repeaterCreate(0,ResourceSelectionInputComponent_Conditional_11_For_1_Template,1,1,null,null,\u0275\u0275repeaterTrackByIdentity),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275repeater(ctx_r0.groupedOptions)}}function ResourceSelectionInputComponent_Conditional_12_For_1_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",5)(1,"span",6)(2,"span"),\u0275\u0275text(3),\u0275\u0275elementEnd()()()),rf&2){let option_r4=ctx.$implicit;\u0275\u0275property("value",option_r4.publicId),\u0275\u0275advance(3),\u0275\u0275textInterpolate(option_r4.name)}}function ResourceSelectionInputComponent_Conditional_12_Template(rf,ctx){if(rf&1&&\u0275\u0275repeaterCreate(0,ResourceSelectionInputComponent_Conditional_12_For_1_Template,4,2,"mat-option",5,_forTrack12),rf&2){let ctx_r0=\u0275\u0275nextContext();\u0275\u0275repeater(ctx_r0.options)}}function ResourceSelectionInputComponent_Conditional_13_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",3),\u0275\u0275text(1,"__MESSAGE__.REQUIRED"),\u0275\u0275elementEnd())}var ResourceSelectionInputComponent=(()=>{class ResourceSelectionInputComponent3 extends ComponentInputComponent{constructor(){super(...arguments),this.cdRef=inject(ChangeDetectorRef),this.destroy=inject(DestroyRef),this.facade=inject(ResourceSelectionInputFacade),this.groupedOptions=[],this.isGrouped=!1,this.options=[],this.queryFormControl=new FormControl("")}ngOnInit(){this.resourceName=this.field.inputDescription.resource?.type,this.isGrouped=this.facade.isGroupedResource(this.field.inputDescription.resource?.type||""),this.facade.options(this.field,this.queryFormControl).pipe(takeUntilDestroyed(this.destroy)).subscribe(options=>{this.isGrouped&&Array.isArray(options)&&options.length&&"options"in options[0]?this.groupedOptions=options:this.options=options;let initialValue=this.publicIdControl?.value;initialValue&&this.selectionChanged(initialValue),this.cdRef.markForCheck()})}get publicIdControl(){return this.componentFormGroup.get([this.field.inputDescription.key,"publicId"])}selectionChanged(value){let selectedOption;this.isGrouped?(selectedOption=this.groupedOptions.reduce((options,groupedOption)=>options.concat(groupedOption.options),[]).find(option=>option.publicId===value),selectedOption&&"label"in selectedOption&&(this.selectedOptionName=selectedOption?.label||"")):(selectedOption=this.options.find(option=>option.publicId===value),selectedOption&&"name"in selectedOption&&(this.selectedOptionName=selectedOption?.name||""))}isOptionGroup(option){return typeof option=="object"&&option!==null&&"options"in option}static{this.\u0275fac=(()=>{let \u0275ResourceSelectionInputComponent_BaseFactory;return function(__ngFactoryType__){return(\u0275ResourceSelectionInputComponent_BaseFactory||(\u0275ResourceSelectionInputComponent_BaseFactory=\u0275\u0275getInheritedFactory(ResourceSelectionInputComponent3)))(__ngFactoryType__||ResourceSelectionInputComponent3)}})()}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ResourceSelectionInputComponent3,selectors:[["ix-resource-selection-input"]],standalone:!1,features:[\u0275\u0275InheritDefinitionFeature],decls:14,vars:13,consts:[[1,"description",3,"innerHTML"],["panelClass","select-resource-selector-panel",3,"selectionChange","formControl"],[3,"formControl","placeholderLabel","noEntriesFoundLabel"],["translate",""],[3,"label"],[3,"value"],["fxLayout","column"],[1,"sublabel"]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,ResourceSelectionInputComponent_Conditional_0_Template,2,3,"p",0),\u0275\u0275elementStart(1,"mat-form-field")(2,"mat-label"),\u0275\u0275text(3),\u0275\u0275elementEnd(),\u0275\u0275elementStart(4,"mat-select",1),\u0275\u0275listener("selectionChange",function($event){return ctx.selectionChanged($event.value)}),\u0275\u0275elementStart(5,"mat-select-trigger"),\u0275\u0275text(6),\u0275\u0275elementEnd(),\u0275\u0275elementStart(7,"mat-option"),\u0275\u0275element(8,"ngx-mat-select-search",2),\u0275\u0275pipe(9,"translate"),\u0275\u0275pipe(10,"translate"),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(11,ResourceSelectionInputComponent_Conditional_11_Template,2,0)(12,ResourceSelectionInputComponent_Conditional_12_Template,2,0),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(13,ResourceSelectionInputComponent_Conditional_13_Template,2,0,"mat-error",3),\u0275\u0275elementEnd()),rf&2&&(\u0275\u0275conditional(ctx.field.inputDescription.description?0:-1),\u0275\u0275advance(3),\u0275\u0275textInterpolate(ctx.field.inputDescription.label),\u0275\u0275advance(),\u0275\u0275property("formControl",ctx.publicIdControl),\u0275\u0275advance(2),\u0275\u0275textInterpolate1(" ",ctx.selectedOptionName),\u0275\u0275advance(2),\u0275\u0275property("formControl",ctx.queryFormControl)("placeholderLabel",\u0275\u0275pipeBind1(9,9,"SEARCH"))("noEntriesFoundLabel",\u0275\u0275pipeBind1(10,11,"NO_RESULTS_FOUND")),\u0275\u0275advance(3),\u0275\u0275conditional(ctx.isGrouped?11:12),\u0275\u0275advance(2),\u0275\u0275conditional(ctx.inputControl!=null&&ctx.inputControl.hasError("required")?13:-1))},dependencies:[MatSelectSearchComponent,DefaultLayoutDirective,NgControlStatus,FormControlDirective,TranslateDirective,MatOption,MatOptgroup,MatFormField,MatLabel,MatError,MatSelect,MatSelectTrigger,RenderMarkdownPipe,TranslatePipe],styles:["[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{display:block} .mat-mdc-select-panel.select-resource-selector-panel mat-option.mat-mdc-option{line-height:1em} .mat-mdc-select-panel.select-resource-selector-panel mat-option.mat-mdc-option .sublabel{font-size:13px;color:#0000008a}"]})}}return ResourceSelectionInputComponent3})();var ResourceSelectionInput=class extends ComponentPropertiesInput{constructor(input2,value,context3,converter,level){super(input2,value,context3,converter,level),this.setValue(value)}setValue(value){super.setValue(value),this.publicId=value?.publicId}toFormControl(){let required=this.inputDescription.required?Validators.required:null;return new FormGroup({publicId:new FormControl({value:this.publicId,disabled:!!this.inputDescription.disabled},required)})}};function inputConstructor(input2){switch(input2.type){case"Number":return NumberInput;case"Group":return GroupInput;case"List":return ListInput;case"RichText":return RichTextInput;case"Selection":return SelectionInput;case"String":return StringInput;case"Text":return TextInput;default:return ComponentPropertiesInput}}function pageComponentInputConstructor(input2){switch(input2.type){case"AggregatedMetric":return AggregatedMetricInput;case"LiveMetric":return LiveMetricInput;case"RawMetric":return RawMetricInput;case"ResourceSelection":return ResourceSelectionInput;default:return inputConstructor(input2)}}function getComponentType(field){switch(field.inputDescription.type){case"Text":return TextInputComponent;case"Color":return ColorInputComponent;case"Date":return DateInputComponent;case"DateTime":return DateTimeInputComponent;case"File":return FileInputComponent;case"MaterialIcon":return MaterialIconInputComponent;case"Number":return NumberInputComponent;case"Image":return ImageInputComponent;case"Checkbox":return CheckboxInputComponent;case"Selection":return SelectionInputComponent;case"RichText":return RichTextInputComponent;case"Group":return GroupInputComponent;case"List":return ListInputComponent;default:return StringInputComponent}}function getPageComponentComponentType(field){switch(field.inputDescription.type){case"Icon":return IconInputComponent;case"AggregatedMetric":return AggregatedMetricInputComponent;case"LiveMetric":return LiveMetricInputComponent;case"RawMetric":return RawMetricInputComponent;case"ResourceSelection":return ResourceSelectionInputComponent;default:return getComponentType(field)}}function getPendingFormValue(form){return Object.keys(form.controls).reduce((formValue,formControlName)=>{let _control=form.controls[formControlName];return _control instanceof FormGroup?__spreadProps(__spreadValues({},formValue),{[formControlName]:getPendingFormValue(_control)}):_control instanceof FormControl&&_control._pendingDirty?__spreadProps(__spreadValues({},formValue),{[formControlName]:_control._pendingValue}):formValue},form.value)}var ComponentPropertiesFacade=(()=>{class ComponentPropertiesFacade2{constructor(store){this.store=store}manifest(template){return this.store.select(selectEntity2(template.publicId)).pipe(mergeMap(manifest=>manifest?of(manifest):(this.store.dispatch(ensureOne({template})),EMPTY)))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ComponentPropertiesFacade2)(\u0275\u0275inject(Store))}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:ComponentPropertiesFacade2,factory:ComponentPropertiesFacade2.\u0275fac,providedIn:"root"})}}return ComponentPropertiesFacade2})();var ComponentPropertiesComponent=(()=>{class ComponentPropertiesComponent3{constructor(cdRef,inputConverter,facade,contextService){this.cdRef=cdRef,this.inputConverter=inputConverter,this.facade=facade,this.contextService=contextService,this.afterViewInit$=new BehaviorSubject(!1),this.component$=new ReplaySubject(1),this.template$=new ReplaySubject(1),this.remove=new EventEmitter,this.update=new EventEmitter,this.unsavedChanges=new EventEmitter,this.form=new FormGroup({},{updateOn:"blur"}),this.destroy=inject(DestroyRef)}ngOnInit(){this.component$.pipe(distinctUntilChanged((a,b)=>a.publicId===b.publicId),pairwise(),takeUntilDestroyed(this.destroy)).subscribe(([previous])=>{this.emitPendingChanges(previous)}),combineLatest([this.component$,this.template$,this.afterViewInit$]).pipe(filter(([,,afterViewInit])=>afterViewInit),mergeMap(([component,template])=>combineLatest([of([component,template]),this.contextService.contextChanges.pipe(map(()=>this.inputConverter.hasFields({component})),distinctUntilChanged())])),filter(([,hasFields2])=>hasFields2),switchMap(([[component,template]])=>template?this.facade.manifest(template).pipe(map(manifest=>({component,manifest}))):of({component,manifest:null})),takeUntilDestroyed(this.destroy)).subscribe(({component,manifest})=>{if(this.currentComponentId===component.publicId)return;this.currentInputs=void 0,this.form.contains("inputs")&&this.form.removeControl("inputs"),this.fields=this.inputConverter.getFields({component},manifest?.inputs??null);let formControls=this.inputConverter.getFormControls(this.fields),inputs=new FormGroup(formControls);this.form.markAsPristine(),this.form.addControl("inputs",inputs),this.formDirective&&(this.formDirective.viewContainerRef.clear(),this.inputConverter.loadComponentInputs(this.fields,inputs,this.formDirective.viewContainerRef)),this.currentComponentId=component.publicId}),this.form.statusChanges.pipe(takeUntilDestroyed(this.destroy)).subscribe(()=>{this.unsavedChanges.emit(this.form.dirty&&this.form.invalid),this.cdRef.markForCheck()}),this.form.valueChanges.pipe(takeUntilDestroyed(this.destroy)).subscribe(data=>{let doSubmit=!1;if(!(!this.form.valid&&this.currentInputs!==void 0)){if("inputs"in data){this.fields.forEach(field=>field.setValue(data.inputs[field.inputDescription.key]));let inputsString=JSON.stringify(data.inputs);inputsString!==this.currentInputs&&(this.currentInputs!==void 0&&(doSubmit=!0),this.currentInputs=inputsString)}doSubmit&&this.submit()}})}ngOnChanges(changes){changes.template&&this.template$.next(this.template),changes.component&&this.component$.next(this.component)}ngAfterViewInit(){setTimeout(()=>{this.afterViewInit$.next(!0)},0)}ngOnDestroy(){this.emitPendingChanges(this.component),this.component$.complete(),this.template$.complete(),this.afterViewInit$.complete()}emitPendingChanges(component){if(component.inputs&&this.form.controls.inputs){let snapshot=cloneDeep_default(this.form.value);this.form.patchValue({inputs:getPendingFormValue(this.form.controls.inputs)},{emitEvent:!1}),!this.form.invalid&&!isEqual_default(snapshot,this.form.value)&&(isEqual_default(this.form.value.inputs,JSON.parse(component.inputs))||this.update.emit({publicId:component.publicId,inputs:JSON.stringify(this.form.value.inputs)}))}}submit(){let formValue=this.form.value.inputs?{inputs:JSON.stringify(this.form.value.inputs)}:{},component=__spreadValues(__spreadValues({},this.component),formValue);this.update.emit(component),this.form.markAsPristine()}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ComponentPropertiesComponent3)(\u0275\u0275directiveInject(ChangeDetectorRef),\u0275\u0275directiveInject(INPUT_CONVERTER_TOKEN),\u0275\u0275directiveInject(ComponentPropertiesFacade),\u0275\u0275directiveInject(ComponentContextService))}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ComponentPropertiesComponent3,selectors:[["ix-page-component-properties"]],viewQuery:function(rf,ctx){if(rf&1&&(\u0275\u0275viewQuery(InputControlFormDirective,5),\u0275\u0275viewQuery(MatExpansionPanel,5)),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.formDirective=_t.first),\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.panelRefs=_t)}},inputs:{template:"template",component:"component"},outputs:{remove:"remove",update:"update",unsavedChanges:"unsavedChanges"},standalone:!1,features:[\u0275\u0275NgOnChangesFeature],decls:3,vars:1,consts:[["autocomplete","off",3,"ngSubmit","formGroup"],["fxLayout","column",1,"more-actions"],["ixInputControlForm",""]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"form",0),\u0275\u0275listener("ngSubmit",function(){return ctx.submit()}),\u0275\u0275elementStart(1,"div",1),\u0275\u0275element(2,"div",2),\u0275\u0275elementEnd()()),rf&2&&\u0275\u0275property("formGroup",ctx.form)},dependencies:[InputControlFormDirective,\u0275NgNoValidate,NgControlStatusGroup,FormGroupDirective,DefaultLayoutDirective],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] form[_ngcontent-%COMP%]{display:flex;flex-direction:column}[_nghost-%COMP%] button[type=submit][_ngcontent-%COMP%]{margin:16px}[_nghost-%COMP%] .mat-expansion-panel[_ngcontent-%COMP%]{background-color:transparent;border-radius:0}[_nghost-%COMP%] .mat-expansion-panel-header-title[_ngcontent-%COMP%]{color:var(--body-color)}[_nghost-%COMP%] .mat-expansion-panel[_ngcontent-%COMP%]:not(.mat-expanded){box-shadow:none!important}[_nghost-%COMP%] .mat-expansion-panel[_ngcontent-%COMP%]:not(.mat-expanded) + .mat-expansion-panel.mat-expanded[_ngcontent-%COMP%]{border-top-left-radius:8px;border-top-right-radius:8px}[_nghost-%COMP%] .mat-expansion-panel.mat-expanded[_ngcontent-%COMP%]{background-color:var(--mat-sys-surface)}[_nghost-%COMP%] .mat-expansion-panel.mat-expanded[_ngcontent-%COMP%] + .mat-expansion-panel.mat-expanded[_ngcontent-%COMP%]{border-top:1px solid var(--mat-sys-outline-variant)}[_nghost-%COMP%] .mat-expansion-panel.border-radius-bottom[_ngcontent-%COMP%]{border-bottom-left-radius:8px!important;border-bottom-right-radius:8px!important}[_nghost-%COMP%] .mat-expansion-panel[_ngcontent-%COMP%] .mat-expansion-panel-header[_ngcontent-%COMP%]{padding:0 20px 0 16px}[_nghost-%COMP%] .mat-expansion-panel[_ngcontent-%COMP%] .mat-expansion-panel-body{padding:0 16px 16px}[_nghost-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{margin-bottom:8px}[_nghost-%COMP%] .more-actions[_ngcontent-%COMP%] .component-property-level-0{border-bottom:1px solid var(--mat-sys-outline-variant);padding:16px}[_nghost-%COMP%] .more-actions[_ngcontent-%COMP%] .mat-icon[_ngcontent-%COMP%]{margin-right:4px}"]})}}return ComponentPropertiesComponent3})();var PERIOD_SPEC_LIST=TIME_RANGE_OPTIONS.map(({code})=>code);var PeriodFieldsetModule=(()=>{class PeriodFieldsetModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PeriodFieldsetModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:PeriodFieldsetModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[SharedModule]})}}return PeriodFieldsetModule2})();var SelectorDialogModule=(()=>{class SelectorDialogModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||SelectorDialogModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:SelectorDialogModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[SharedModule,NgxMatSelectSearchModule]})}}return SelectorDialogModule2})();var SelectorInputModule=(()=>{class SelectorInputModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||SelectorInputModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:SelectorInputModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[SharedModule,SelectorDialogModule]})}}return SelectorInputModule2})();var InputConverterService=class{constructor(){this.injector=inject(Injector)}convertInput(input2,values,context3,level){let constructor=this.getInputConstructor(input2);return new constructor(input2,values?.[input2.key],context3,this,level,this.injector)}getFormControls(inputs){return inputs.reduce((acc,cur)=>__spreadProps(__spreadValues({},acc),{[cur.inputDescription.key]:cur.toFormControl()}),{})}getFields(context3,inputs){let componentInput=this.getInputs(context3);return inputs?.map(input2=>this.convertInput(input2,componentInput,context3,0))||[]}loadComponentInputs(fields,form,ref){for(let field of fields){let componentType=this.getComponentType(field),componentRef=ref.createComponent(componentType);componentRef.instance.field=field,componentRef.instance.componentFormGroup=form,componentRef.location.nativeElement.classList.add(`component-property-level-${field.level}`)}}};var PageComponentInputConverterService=(()=>{class PageComponentInputConverterService2 extends InputConverterService{constructor(){super(...arguments),this.service=inject(ComponentContextService)}getInputs({component}){let context3=this.service.getContext(component);if(context3===void 0)throw Error(`ComponentContext could not be found for component ${component.publicId}.`);let inputs=cloneDeep_default(context3.inputs)||{};return Object.keys(context3._translationKeys).forEach(key=>set_default(inputs,key,context3._translationKeys[key])),inputs}getInputConstructor(input2){return pageComponentInputConstructor(input2)}getComponentType(field){return getPageComponentComponentType(field)}hasFields({component}){return this.service.getContext(component)!==void 0}static{this.\u0275fac=(()=>{let \u0275PageComponentInputConverterService_BaseFactory;return function(__ngFactoryType__){return(\u0275PageComponentInputConverterService_BaseFactory||(\u0275PageComponentInputConverterService_BaseFactory=\u0275\u0275getInheritedFactory(PageComponentInputConverterService2)))(__ngFactoryType__||PageComponentInputConverterService2)}})()}static{this.\u0275prov=\u0275\u0275defineInjectable({token:PageComponentInputConverterService2,factory:PageComponentInputConverterService2.\u0275fac,providedIn:"root"})}}return PageComponentInputConverterService2})();var InputControlModule=(()=>{class InputControlModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||InputControlModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:InputControlModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({providers:[{provide:INPUT_CONVERTER_TOKEN,useClass:PageComponentInputConverterService}],imports:[FileUploadButtonComponent,FileUploadDropContainerComponent,MarkdownModule,MatLuxonDateModule,MaterialIconFieldsetComponent,NgxMatSelectSearchModule,PeriodFieldsetModule,SelectorInputModule,SharedModule,TranslationIconButtonComponent]})}}return InputControlModule2})();var ComponentPropertiesModule=(()=>{class ComponentPropertiesModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ComponentPropertiesModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:ComponentPropertiesModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[InputControlModule,ReactiveFormsModule,FlexModule,InputControlModule]})}}return ComponentPropertiesModule2})();var ComponentContextCleanupDirective=(()=>{class ComponentContextCleanupDirective3{set agentOrAssetId(agentOrAssetId){this.agentOrAssetId$.next(agentOrAssetId)}set pageVersionId(pageVersionId){this.pageVersionId$.next(pageVersionId)}constructor(scopeRef,contextService){this.scopeRef=scopeRef,this.contextService=contextService,this.agentOrAssetId$=new ReplaySubject(1),this.pageVersionId$=new ReplaySubject(1),this.destroy=inject(DestroyRef)}ngOnInit(){combineLatest([this.agentOrAssetId$,this.pageVersionId$]).pipe(filter(ids=>ids.every(Boolean)),distinctUntilChanged(isEqual_default),skip(1),takeUntilDestroyed(this.destroy)).subscribe(()=>{this.contextService.destroyAll(this.scopeRef?.value)})}ngOnDestroy(){this.agentOrAssetId$.complete(),this.pageVersionId$.complete()}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ComponentContextCleanupDirective3)(\u0275\u0275directiveInject(ComponentGridScopeDirective,8),\u0275\u0275directiveInject(ComponentContextService))}}static{this.\u0275dir=\u0275\u0275defineDirective({type:ComponentContextCleanupDirective3,selectors:[["","ixComponentContextCleanup",""]],inputs:{agentOrAssetId:"agentOrAssetId",pageVersionId:"pageVersionId"}})}}return ComponentContextCleanupDirective3})();function getAssetDescendants(assetId,assetEntities){let result=[],stack=[assetId],visited=new Set;for(;stack.length>0;){let currentId=stack.pop();if(visited.has(currentId))continue;visited.add(currentId);let asset=assetEntities[currentId];asset&&(result.push(asset),Object.values(assetEntities).forEach(child=>{child&&!visited.has(child.publicId)&&child.parent?.publicId===currentId&&stack.push(child.publicId)}))}return result}var LoggingDataPrefetcher=(()=>{class LoggingDataPrefetcher2{constructor(store,actions$){this.store=store,this.actions$=actions$}forQueries(agentId,queries){let parsedSelectors=queries.map(query=>query.selector?parseSelector(query.selector):{type:"",target:"",dataSource:"",logType:"",logName:""}).filter(r=>r?.target==="selected"),hasAssetSelectors=parsedSelectors.some(r=>r.type==="Asset"),uniqDataSourceSlugs=compact_default(uniq_default(parsedSelectors.map(r=>r?.dataSource))),uniqDataTagSlugs=compact_default(uniq_default(parsedSelectors.filter(r=>r?.logType==="tag").map(r=>r?.logName))),uniqDataVariableSlugs=compact_default(uniq_default(parsedSelectors.filter(r=>r?.logType==="variable").map(r=>r?.logName)));return combineLatest([this.handleDataSourceSlugs(agentId,uniqDataSourceSlugs),this.handleDataTagSlugs(agentId,uniqDataTagSlugs,hasAssetSelectors),this.handleDataVariableSlugs(agentId,uniqDataVariableSlugs)]).pipe(mergeMap(()=>of(queries)))}handleDataSourceSlugs(agentId,slugs){return agentId&&slugs.length?combineLatest([this.store.select(selectAllLoadedForAgent3(agentId)),this.store.select(selectAllForAgent3(agentId))]).pipe(take(1),mergeMap(([sourcesLoaded,sources])=>{if(sourcesLoaded&&sources.length===0)return of([]);let unmatchedSlugs=slugs.filter(slug=>!sources?.find(s2=>s2?.slug===slug));if(unmatchedSlugs.length){let filters=`in(slug,"${unmatchedSlugs.join('","')}")`,queryTooLarge=("?fields="+AGENT_DATA_SOURCE_LIST_FIELDS.join(",")+"&").length+filters.length+`&page-after=publicid0000&page-size=${4e3}`.length>4096,reference2=`${agentId}_${filters}`;return this.store.dispatch(loadAll2({agentId,filters:queryTooLarge?void 0:filters})),this.actions$.pipe(ofType(loadAllSuccess3,loadAllFailure2),filter(({agentId:agentId2,filters:filters2})=>`${agentId2}_${filters2}`===reference2||queryTooLarge),take(1),map(()=>[]))}return of([])}),map(()=>[])):of([])}handleDataTagSlugs(agentId,slugs,hasAssetSelectors){return agentId&&(slugs.length||hasAssetSelectors)?combineLatest([this.store.select(selectAllLoadedForAgent3(agentId)),this.store.select(selectAllForAgent3(agentId)),this.store.select(selectAllLoadedForAgent2(agentId)),this.store.select(selectAllForAgent2(agentId))]).pipe(take(1),mergeMap(([sourcesLoaded,sources,tagsLoaded,tags])=>{if(sourcesLoaded&&sources.length===0)return of([]);let unmatchedSlugs=slugs.filter(slug=>!tags?.find(t=>t?.slug===slug));if(!tagsLoaded&&(hasAssetSelectors||unmatchedSlugs.length)){let fields=AGENT_DATA_TAG_WITH_VARIABLE_LIST_FIELDS,filters=hasAssetSelectors?void 0:`in(slug,"${unmatchedSlugs.join('","')}")`;filters&&("?fields="+fields.join(",")+"&").length+filters.length+`&page-after=publicid0000&page-size=${4e3}`.length>4096&&(filters=void 0);let reference2=`${agentId}_${filters}`;return this.store.dispatch(loadAll30({agentId,fields,filters})),this.actions$.pipe(ofType(loadAllSuccess31,loadAllFailure30),filter(({agentId:id,filters:f})=>`${id}_${f}`===reference2),take(1),map(()=>[]))}return of([])}),map(()=>[])):of([])}handleDataVariableSlugs(agentId,slugs){return agentId&&slugs.length?this.store.select(selectAllLoadedForAgent(agentId)).pipe(take(1),mergeMap(loaded=>{if(!loaded){let reference2=agentId;return this.store.dispatch(loadAll31({agentId})),this.actions$.pipe(ofType(loadAllSuccess32,loadAllFailure31),filter(({agentId:agentId2})=>agentId2===reference2),take(1),map(()=>[]))}return of([])}),map(()=>[])):of([])}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LoggingDataPrefetcher2)(\u0275\u0275inject(Store),\u0275\u0275inject(Actions))}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:LoggingDataPrefetcher2,factory:LoggingDataPrefetcher2.\u0275fac,providedIn:"root"})}}return LoggingDataPrefetcher2})();var LoggingDataBrokerDirective=(()=>{class LoggingDataBrokerDirective3{constructor(scopeRef,store,activePeriodSpec,authTokenService,localization,loggingDataClient,loggingDataFetcherFactory,loggingDataPrefetcher){this.scopeRef=scopeRef,this.store=store,this.activePeriodSpec=activePeriodSpec,this.authTokenService=authTokenService,this.localization=localization,this.loggingDataClient=loggingDataClient,this.loggingDataFetcherFactory=loggingDataFetcherFactory,this.loggingDataPrefetcher=loggingDataPrefetcher,this.agentOrAssetId$=new ReplaySubject(1),this.agentId=null,this.agentId$=this.agentOrAssetId$.pipe(switchMap(agentOrAssetId=>this.store.select(selectEntities18).pipe(map(entities=>entities[agentOrAssetId]?findClosestAgentToAsset(agentOrAssetId,entities)?.publicId??null:agentOrAssetId),distinctUntilChanged()))),this._authToken$=combineLatest([timer(0,3300*1e3),this.agentId$]).pipe(mergeMap(([,id])=>{let canUseLiveData=this.features.instantCanUse("live-data",{agentId:id}),canUseHistoricalData=this.features.instantCanUse("historical-data",{agentId:id});return id&&(canUseLiveData||canUseHistoricalData)?this.authTokenService.getForData({agents:[{publicId:id}],expiresIn:3600}).pipe(map(response=>response.data.secretId),catchError(()=>EMPTY)):EMPTY}),share()),this.authTokenRequired$=new ReplaySubject(1),this.authToken$=new ReplaySubject(1),this.dataSources$=this.agentId$.pipe(mergeMap(id=>this.store.select(selectAllForAgent3(id)))),this.tags$=this.agentId$.pipe(mergeMap(id=>this.store.select(selectAllForAgent2(id)))),this.variables$=this.agentId$.pipe(mergeMap(id=>this.store.select(selectAllForAgent(id)))),this.assets$=this.agentOrAssetId$.pipe(mergeMap(assetId=>this.store.select(selectEntities18).pipe(map(entities=>getAssetDescendants(assetId,entities))))),this.selectedAssetId$=this.agentOrAssetId$,this.assetAppConfigResources$=this.agentOrAssetId$.pipe(distinctUntilChanged(),mergeMap(assetId=>{if(!assetId)return of([]);let assetTree$=this.store.select(selectEntities18).pipe(map(entities=>getAssetDescendants(assetId,entities)));return this.store.select(selectEntities24).pipe(withLatestFrom(assetTree$),map(([resourceMap,assets])=>{let assetAppConfigs=assets.map(a=>a.appConfigs).flat(),resources=[];return assetAppConfigs.forEach(appConfig=>{let matchingResources=Object.values(resourceMap).filter(res=>!!res&&res.config?.publicId===appConfig?.publicId);resources.push(...matchingResources)}),resources}))})),this.features=inject(PlatformFeaturesService),this.destroy=inject(DestroyRef)}ngOnInit(){this.agentId$.pipe(distinctUntilChanged()).subscribe(agentId=>this.agentId=agentId),this.fetcher=this.loggingDataFetcherFactory.create({agentId:this.agentId$.pipe(distinctUntilChanged()),authToken:this.authToken$.asObservable(),companyId:this.store.select(selectMyCompanyId),locale:this.localization.getLocale(),timeRange:this.activePeriodSpec.asTimeRange(this.scopeRef?.value),timeZone:of(Settings.defaultZone.name),dataSources:this.dataSources$,tags:this.tags$,variables:this.variables$,availabilityStrategy:LoggingDataConfigAvailabilityStrategy.Lazy,scope:this.scopeRef?.value,assetAppConfigResources:this.assetAppConfigResources$,assets:this.assets$,selectedAssetId:this.selectedAssetId$,beforeFetch:queries=>this.agentId?this.loggingDataPrefetcher.forQueries(this.agentId,queries).pipe(mergeMap(queries2=>queries2.some(q=>q.selector?parseSelector(q.selector).logType==="variable":!1)?(this.authTokenRequired$.next(!0),this.authToken$.pipe(take(1),map(()=>queries2))):of(queries2))):of(queries)}),this.authTokenRequired$.pipe(distinctUntilChanged(),switchMap(required=>required?this._authToken$:EMPTY),takeUntilDestroyed(this.destroy)).subscribe(this.authToken$),merge(this.loggingDataClient.onQuery(this.scopeRef?.value),this.loggingDataClient.onDestroy(this.scopeRef?.value)).pipe(bufferDebounceTime(100),mergeMap(buffer2=>{let queries=[],destroyEvents=buffer2.filter(item=>item instanceof CustomEvent);return destroyEvents.length?queries=flatten_default(buffer2.filter(item=>!(item instanceof CustomEvent))).filter(q=>!destroyEvents.some(e=>q._clientRef?.startsWith(e.detail)&&(q._timeStamp?q._timeStamp<e.timeStamp:!0))):queries=flatten_default(buffer2),queries.length?of(queries):EMPTY}),mergeMap(queries=>this.fetcher.fetch(queries)),distinctUntilChanged(),takeUntilDestroyed(this.destroy)).subscribe(metrics=>{this.loggingDataClient.emitMetrics(metrics,this.scopeRef?.value)}),this.loggingDataClient.onExport(this.scopeRef?.value).pipe(mergeMap(({queries,csvDelimiter})=>this.fetcher.export(queries,csvDelimiter)),takeUntilDestroyed(this.destroy)).subscribe(blob=>{this.loggingDataClient.emitBlob(blob,this.scopeRef?.value)})}ngOnChanges(changes){changes.agentOrAssetId&&this.agentOrAssetId&&this.agentOrAssetId$.next(this.agentOrAssetId)}ngOnDestroy(){this.agentOrAssetId$.complete(),this.authToken$.complete(),this.authTokenRequired$.complete(),this.fetcher.destroy()}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LoggingDataBrokerDirective3)(\u0275\u0275directiveInject(ComponentGridScopeDirective,8),\u0275\u0275directiveInject(Store),\u0275\u0275directiveInject(ActivePeriodSpec),\u0275\u0275directiveInject(AuthTokenService),\u0275\u0275directiveInject(LocalizationService),\u0275\u0275directiveInject(LoggingDataClientProxyService),\u0275\u0275directiveInject(LoggingDataFetcherFactory),\u0275\u0275directiveInject(LoggingDataPrefetcher))}}static{this.\u0275dir=\u0275\u0275defineDirective({type:LoggingDataBrokerDirective3,selectors:[["","ixLoggingDataBroker",""]],inputs:{agentOrAssetId:"agentOrAssetId"},features:[\u0275\u0275NgOnChangesFeature]})}}return LoggingDataBrokerDirective3})();var ComponentGridFocusDirective=(()=>{class ComponentGridFocusDirective3{constructor(){this.elRef=inject(ElementRef),this.service=inject(ComponentGridFocusService),this.destroy=inject(DestroyRef)}ngOnInit(){fromEvent(this.elRef.nativeElement,"mousedown").pipe(takeUntilDestroyed(this.destroy)).subscribe(()=>this.service.next())}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ComponentGridFocusDirective3)}}static{this.\u0275dir=\u0275\u0275defineDirective({type:ComponentGridFocusDirective3,selectors:[["","ixComponentGridFocus",""]]})}}return ComponentGridFocusDirective3})();function PeriodBottomSheetComponent_For_4_Template(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-list-item",11),\u0275\u0275listener("click",function(){let range_r2=\u0275\u0275restoreView(_r1).$implicit,ctx_r2=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r2.applyRange(range_r2.code))}),\u0275\u0275text(1),\u0275\u0275pipe(2,"translate"),\u0275\u0275elementEnd()}if(rf&2){let range_r2=ctx.$implicit;\u0275\u0275advance(),\u0275\u0275textInterpolate1(" ",\u0275\u0275pipeBind2(2,1,range_r2.translateKey,range_r2.translateParams)," ")}}function PeriodBottomSheetComponent_Conditional_12_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"FROM_MUST_BE_BEFORE_TO"),\u0275\u0275elementEnd())}function PeriodBottomSheetComponent_Conditional_13_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"__MESSAGE__.MAX_DATE"),\u0275\u0275elementEnd())}function PeriodBottomSheetComponent_Conditional_18_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"TO_MUST_BE_AFTER_FROM"),\u0275\u0275elementEnd())}function PeriodBottomSheetComponent_Conditional_19_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"__MESSAGE__.MAX_DATE"),\u0275\u0275elementEnd())}var PeriodBottomSheetComponent=(()=>{class PeriodBottomSheetComponent2{constructor(){this.data=inject(MAT_BOTTOM_SHEET_DATA),this.ref=inject(MatBottomSheetRef),this.ranges=TIME_RANGE_OPTIONS,this.maxDate=DateTime.now().endOf("day").toISO()}ngOnInit(){let timeRange=toTimeRange(this.data.periodSpec);this.form=new FormGroup({from:new FormControl(DateTime.fromMillis(timeRange.from).set({millisecond:0}).toISO({includeOffset:!1,suppressMilliseconds:!0}),{validators:[Validators.required,DateTimeValidators.maxDate(this.maxDate)],nonNullable:!0}),to:new FormControl(DateTime.fromMillis(timeRange.to).set({millisecond:0}).toISO({includeOffset:!1,suppressMilliseconds:!0}),{validators:[Validators.required,DateTimeValidators.maxDate(this.maxDate)],nonNullable:!0})},{validators:DateTimeValidators.fromToInverted()})}applyRange(range4){this.ref.dismiss(range4)}cancel(){this.ref.dismiss()}submit(){let periodSpec={from:DateTime.fromISO(this.form.controls.from.value).toMillis(),to:DateTime.fromISO(this.form.controls.to.value).toMillis()};this.ref.dismiss(periodSpec)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PeriodBottomSheetComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:PeriodBottomSheetComponent2,selectors:[["ix-period-bottom-sheet"]],decls:27,vars:10,consts:[["fxLayout","column"],[1,"ranges"],["autocomplete","off",3,"ngSubmit","formGroup"],["fxLayout","row","fxLayoutGap","8px"],["fxFlex","grow"],["translate",""],["type","datetime-local","matInput","","formControlName","from","step","1",3,"max"],["type","datetime-local","matInput","","formControlName","to","step","1",3,"min","max"],["fxLayout","row","fxLayoutAlign","end center",1,"actions"],["type","button","mat-button","",3,"click"],["type","submit","mat-button","","color","primary",3,"disabled"],[3,"click"]],template:function(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",0)(1,"div",1)(2,"mat-action-list"),\u0275\u0275repeaterCreate(3,PeriodBottomSheetComponent_For_4_Template,3,4,"mat-list-item",null,\u0275\u0275repeaterTrackByIdentity),\u0275\u0275elementEnd()(),\u0275\u0275element(5,"mat-divider"),\u0275\u0275elementStart(6,"form",2),\u0275\u0275listener("ngSubmit",function(){return ctx.submit()}),\u0275\u0275elementStart(7,"fieldset",3)(8,"mat-form-field",4)(9,"mat-label",5),\u0275\u0275text(10,"FROM__DATE"),\u0275\u0275elementEnd(),\u0275\u0275element(11,"input",6),\u0275\u0275conditionalCreate(12,PeriodBottomSheetComponent_Conditional_12_Template,2,0,"mat-error",5),\u0275\u0275conditionalCreate(13,PeriodBottomSheetComponent_Conditional_13_Template,2,0,"mat-error",5),\u0275\u0275elementEnd(),\u0275\u0275elementStart(14,"mat-form-field",4)(15,"mat-label",5),\u0275\u0275text(16,"TO__DATE"),\u0275\u0275elementEnd(),\u0275\u0275element(17,"input",7),\u0275\u0275conditionalCreate(18,PeriodBottomSheetComponent_Conditional_18_Template,2,0,"mat-error",5),\u0275\u0275conditionalCreate(19,PeriodBottomSheetComponent_Conditional_19_Template,2,0,"mat-error",5),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(20,"div",8)(21,"button",9),\u0275\u0275listener("click",function(){return ctx.cancel()}),\u0275\u0275elementStart(22,"span",5),\u0275\u0275text(23,"CANCEL"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(24,"button",10)(25,"span",5),\u0275\u0275text(26,"APPLY"),\u0275\u0275elementEnd()()()()()),rf&2){let tmp_2_0,tmp_6_0;\u0275\u0275advance(3),\u0275\u0275repeater(ctx.ranges),\u0275\u0275advance(3),\u0275\u0275property("formGroup",ctx.form),\u0275\u0275advance(5),\u0275\u0275property("max",(tmp_2_0=ctx.form.get("to"))==null?null:tmp_2_0.value)("max",ctx.maxDate),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.from.hasError("inverted")?12:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.from.hasError("maxDate")?13:-1),\u0275\u0275advance(4),\u0275\u0275property("min",(tmp_6_0=ctx.form.get("from"))==null?null:tmp_6_0.value)("max",ctx.maxDate),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.to.hasError("inverted")?18:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.to.hasError("maxDate")?19:-1),\u0275\u0275advance(5),\u0275\u0275property("disabled",ctx.form.invalid)}},dependencies:[FlexModule,DefaultLayoutDirective,DefaultLayoutGapDirective,DefaultLayoutAlignDirective,DefaultFlexDirective,MatButtonModule,MatButton,MatDividerModule,MatDivider,MatFormFieldModule,MatFormField,MatLabel,MatError,MatInputModule,MatInput,MatListModule,MatActionList,MatListItem,ReactiveFormsModule,\u0275NgNoValidate,DefaultValueAccessor,NgControlStatus,NgControlStatusGroup,FormGroupDirective,FormControlName,TranslateModule,TranslateDirective,TranslatePipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .ranges[_ngcontent-%COMP%]{max-height:50vh;overflow-y:auto}[_nghost-%COMP%] form[_ngcontent-%COMP%]{display:block;padding-top:16px}[_nghost-%COMP%] form[_ngcontent-%COMP%] fieldset[_ngcontent-%COMP%]{margin:0;padding:0;border:none}[_nghost-%COMP%] form[_ngcontent-%COMP%] fieldset[_ngcontent-%COMP%] .mat-mdc-form-field[_ngcontent-%COMP%]{max-width:calc(50vw - 24px)!important}[_nghost-%COMP%] form[_ngcontent-%COMP%] fieldset[_ngcontent-%COMP%] input[type=datetime-local][_ngcontent-%COMP%]::-webkit-inner-spin-button, [_nghost-%COMP%] form[_ngcontent-%COMP%] fieldset[_ngcontent-%COMP%] input[type=datetime-local][_ngcontent-%COMP%]::-webkit-calendar-picker-indicator{appearance:none;display:none}[_nghost-%COMP%] .actions[_ngcontent-%COMP%]{padding-bottom:8px}[_nghost-%COMP%] .actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{margin-left:8px}"]})}}return PeriodBottomSheetComponent2})();var PERIOD_PANEL_DATA=new InjectionToken("device-board-header-period-panel-data");var import_dayjs4=__toESM(require_dayjs_min()),import_utc=__toESM(require_utc()),import_timezone=__toESM(require_timezone());var PeriodPanelRef=class{constructor(overlayRef){this.overlayRef=overlayRef,this._afterClosed=new Subject}afterClosed(){return this._afterClosed.asObservable()}close(data){this.overlayRef.dispose(),data&&(this._afterClosed.next(data),this._afterClosed.complete())}};function PeriodPanelComponent_Conditional_21_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"button",6)(1,"div",4)(2,"mat-icon"),\u0275\u0275text(3,"public"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(4,"span"),\u0275\u0275text(5),\u0275\u0275pipe(6,"translate"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(7,"span"),\u0275\u0275text(8,":\xA0"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(9,"span"),\u0275\u0275text(10),\u0275\u0275elementEnd(),\u0275\u0275elementStart(11,"mat-icon"),\u0275\u0275text(12,"arrow_drop_down"),\u0275\u0275elementEnd()()()),rf&2){let ctx_r1=\u0275\u0275nextContext(),timeZoneMenu_r3=\u0275\u0275reference(4);\u0275\u0275property("matMenuTriggerFor",timeZoneMenu_r3),\u0275\u0275advance(5),\u0275\u0275textInterpolate(\u0275\u0275pipeBind1(6,3,ctx_r1.timeZoneSpec==="device"?"DEVICE_TIME_ZONE":"MY_TIME_ZONE")),\u0275\u0275advance(5),\u0275\u0275textInterpolate(ctx_r1.timeZoneSpec==="device"?ctx_r1.deviceTimeZone:ctx_r1.myTimeZone)}}function PeriodPanelComponent_Conditional_32_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"FROM_MUST_BE_BEFORE_TO"),\u0275\u0275elementEnd())}function PeriodPanelComponent_Conditional_33_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"__MESSAGE__.MAX_DATE"),\u0275\u0275elementEnd())}function PeriodPanelComponent_Conditional_34_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"__MESSAGE__.INVALID_DATE_AND_TIME"),\u0275\u0275elementEnd())}function PeriodPanelComponent_Conditional_35_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"__MESSAGE__.INVALID_DATE_AND_TIME"),\u0275\u0275elementEnd())}function PeriodPanelComponent_Conditional_41_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"TO_MUST_BE_AFTER_FROM"),\u0275\u0275elementEnd())}function PeriodPanelComponent_Conditional_42_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"__MESSAGE__.MAX_DATE"),\u0275\u0275elementEnd())}function PeriodPanelComponent_Conditional_43_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"__MESSAGE__.INVALID_DATE_AND_TIME"),\u0275\u0275elementEnd())}function PeriodPanelComponent_Conditional_44_Template(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"mat-error",5),\u0275\u0275text(1,"__MESSAGE__.INVALID_DATE_AND_TIME"),\u0275\u0275elementEnd())}function PeriodPanelComponent_For_55_Template(rf,ctx){if(rf&1){let _r4=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-list-item",20),\u0275\u0275listener("click",function(){let range_r5=\u0275\u0275restoreView(_r4).$implicit,ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.applyRange(range_r5.code))}),\u0275\u0275text(1),\u0275\u0275pipe(2,"translate"),\u0275\u0275elementEnd()}if(rf&2){let range_r5=ctx.$implicit;\u0275\u0275advance(),\u0275\u0275textInterpolate1(" ",\u0275\u0275pipeBind2(2,1,range_r5.translateKey,range_r5.translateParams)," ")}}import_dayjs4.default.extend(import_utc.default);import_dayjs4.default.extend(import_timezone.default);var PeriodPanelComponent=(()=>{class PeriodPanelComponent2{constructor(data,formBuilder,localizationService,ref){this.data=data,this.formBuilder=formBuilder,this.localizationService=localizationService,this.ref=ref,this.browserTimeZone=Intl.DateTimeFormat().resolvedOptions().timeZone,this.locale={format:"YYYY-MM-DDTHH:mm:ss.SSSZ",displayFormat:"MM/DD/YYYY",direction:"ltr",weekLabel:"W",daysOfWeek:[Info.weekdays("short")[6],...Info.weekdays("short").slice(0,-1)],monthNames:Info.months("short"),firstDay:1},this.maxISO=DateTime.now().endOf("day").toISO(),this.ranges=TIME_RANGE_OPTIONS,this.myTimeZone=this.localizationService.getTimeZone()}ngOnInit(){this.deviceTimeZone=this.data.deviceTimeZone||null,this.timeZone=Settings.defaultZone.name,this.timeZoneSpec=this.data.timeZoneSpec||"user",this.processRange()}applyRange(range4){this.ref.close(range4)}cancel(){this.ref.close()}choosedDate(selection){this.form.setValue({from:DateTime.fromISO(selection.startDate.toISOString(),{zone:this.browserTimeZone}).setZone(this.timeZone,{keepLocalTime:!0}).toFormat("F"),to:DateTime.fromISO(selection.endDate.toISOString(),{zone:this.browserTimeZone}).setZone(this.timeZone,{keepLocalTime:!0}).toFormat("F")})}submit(){let periodSpec={from:DateTime.fromFormat(this.form.value.from,"F").toMillis(),to:DateTime.fromFormat(this.form.value.to,"F").toMillis()};this.ref.close(periodSpec)}setTimeZoneSpec(timeZoneSpec){this.timeZoneSpec=timeZoneSpec,this.timeZone=timeZoneSpec==="device"&&this.deviceTimeZone?this.deviceTimeZone:this.myTimeZone,this.processRange(),this.data.timeZoneSpecSelected?.emit({name:this.timeZone,spec:timeZoneSpec})}processRange(){let timeRange=toTimeRange(this.data.periodSpec||"yesterday");if(this.selected={startDate:(0,import_dayjs4.default)(DateTime.fromMillis(timeRange.from,{zone:this.timeZone}).setZone(this.browserTimeZone,{keepLocalTime:!0}).toMillis()),endDate:(0,import_dayjs4.default)(DateTime.fromMillis(timeRange.to,{zone:this.timeZone}).setZone(this.browserTimeZone,{keepLocalTime:!0}).toMillis())},this.form)this.form.setValue({from:DateTime.fromMillis(timeRange.from).toFormat("F"),to:DateTime.fromMillis(timeRange.to).toFormat("F")});else{let formatter=value=>DateTime.fromFormat(value,"F");this.form=this.formBuilder.group({from:[DateTime.fromMillis(timeRange.from).toFormat("F"),[Validators.required,DateTimeValidators.format(formatter),DateTimeValidators.maxDate(this.maxISO,formatter)]],to:[DateTime.fromMillis(timeRange.to).toFormat("F"),[Validators.required,DateTimeValidators.format(formatter),DateTimeValidators.maxDate(this.maxISO,formatter)]]},{validators:DateTimeValidators.fromToInverted(formatter)})}}onEscapeHandler(event2){event2.stopPropagation(),event2.preventDefault(),this.ref.close()}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PeriodPanelComponent2)(\u0275\u0275directiveInject(PERIOD_PANEL_DATA),\u0275\u0275directiveInject(FormBuilder),\u0275\u0275directiveInject(LocalizationService),\u0275\u0275directiveInject(PeriodPanelRef))}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:PeriodPanelComponent2,selectors:[["ix-period-panel"]],hostBindings:function(rf,ctx){rf&1&&\u0275\u0275listener("keydown.escape",function($event){return ctx.onEscapeHandler($event)},\u0275\u0275resolveDocument)},decls:56,vars:31,consts:[["timeZoneMenu","matMenu"],["fxFlex","","translate",""],[1,"dense"],["mat-menu-item","",3,"click"],["fxLayout","row","fxLayoutAlign","start center"],["translate",""],["mat-button","",1,"time-zone-select",3,"matMenuTriggerFor"],["fxLayout","row"],["fxFlex","",1,"picker"],[3,"choosedDate","autoApply","linkedCalendars","maxDate","locale","startDate","endDate"],["autocomplete","off",3,"ngSubmit","formGroup"],["fxlayout","row","fxLayoutGap","16px"],["fxFlex","grow"],["matInput","","formControlName","from",3,"placeholder"],["matInput","","formControlName","to",3,"placeholder"],["fxLayout","row","fxLayoutAlign","end center",1,"actions"],["type","button","mat-stroked-button","","color","primary",3,"click"],["type","submit","mat-flat-button","","color","primary",3,"disabled"],[1,"ranges"],["dense",""],[3,"click"]],template:function(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-toolbar")(1,"span",1),\u0275\u0275text(2,"TIME_RANGE_SELECTION"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"mat-menu",2,0)(5,"button",3),\u0275\u0275listener("click",function(){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.setTimeZoneSpec("user"))}),\u0275\u0275elementStart(6,"div",4)(7,"span",5),\u0275\u0275text(8,"MY_TIME_ZONE"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(9,"span"),\u0275\u0275text(10,":\xA0"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(11,"span"),\u0275\u0275text(12),\u0275\u0275elementEnd()()(),\u0275\u0275elementStart(13,"button",3),\u0275\u0275listener("click",function(){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.setTimeZoneSpec("device"))}),\u0275\u0275elementStart(14,"div",4)(15,"span",5),\u0275\u0275text(16,"DEVICE_TIME_ZONE"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(17,"span"),\u0275\u0275text(18,":\xA0"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(19,"span"),\u0275\u0275text(20),\u0275\u0275elementEnd()()()(),\u0275\u0275conditionalCreate(21,PeriodPanelComponent_Conditional_21_Template,13,5,"button",6),\u0275\u0275elementEnd(),\u0275\u0275elementStart(22,"div",7)(23,"div",8)(24,"ngx-daterangepicker-material",9),\u0275\u0275listener("choosedDate",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.choosedDate($event))}),\u0275\u0275elementEnd(),\u0275\u0275elementStart(25,"form",10),\u0275\u0275listener("ngSubmit",function(){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.submit())}),\u0275\u0275elementStart(26,"fieldset",11)(27,"mat-form-field",12)(28,"mat-label",5),\u0275\u0275text(29,"FROM__DATE"),\u0275\u0275elementEnd(),\u0275\u0275element(30,"input",13),\u0275\u0275pipe(31,"translate"),\u0275\u0275conditionalCreate(32,PeriodPanelComponent_Conditional_32_Template,2,0,"mat-error",5),\u0275\u0275conditionalCreate(33,PeriodPanelComponent_Conditional_33_Template,2,0,"mat-error",5),\u0275\u0275conditionalCreate(34,PeriodPanelComponent_Conditional_34_Template,2,0,"mat-error",5),\u0275\u0275conditionalCreate(35,PeriodPanelComponent_Conditional_35_Template,2,0,"mat-error",5),\u0275\u0275elementEnd(),\u0275\u0275elementStart(36,"mat-form-field",12)(37,"mat-label",5),\u0275\u0275text(38,"TO__DATE"),\u0275\u0275elementEnd(),\u0275\u0275element(39,"input",14),\u0275\u0275pipe(40,"translate"),\u0275\u0275conditionalCreate(41,PeriodPanelComponent_Conditional_41_Template,2,0,"mat-error",5),\u0275\u0275conditionalCreate(42,PeriodPanelComponent_Conditional_42_Template,2,0,"mat-error",5),\u0275\u0275conditionalCreate(43,PeriodPanelComponent_Conditional_43_Template,2,0,"mat-error",5),\u0275\u0275conditionalCreate(44,PeriodPanelComponent_Conditional_44_Template,2,0,"mat-error",5),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(45,"div",15)(46,"button",16),\u0275\u0275listener("click",function(){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.cancel())}),\u0275\u0275elementStart(47,"span",5),\u0275\u0275text(48,"CANCEL"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(49,"button",17)(50,"span",5),\u0275\u0275text(51,"APPLY"),\u0275\u0275elementEnd()()()()(),\u0275\u0275elementStart(52,"div",18)(53,"mat-action-list",19),\u0275\u0275repeaterCreate(54,PeriodPanelComponent_For_55_Template,3,4,"mat-list-item",null,\u0275\u0275repeaterTrackByIdentity),\u0275\u0275elementEnd()()()}rf&2&&(\u0275\u0275advance(5),\u0275\u0275classProp("active",ctx.timeZoneSpec==="user"),\u0275\u0275advance(7),\u0275\u0275textInterpolate(ctx.myTimeZone),\u0275\u0275advance(),\u0275\u0275classProp("active",ctx.timeZoneSpec==="device"),\u0275\u0275advance(7),\u0275\u0275textInterpolate(ctx.deviceTimeZone),\u0275\u0275advance(),\u0275\u0275conditional(ctx.deviceTimeZone&&ctx.deviceTimeZone!==ctx.myTimeZone?21:-1),\u0275\u0275advance(3),\u0275\u0275property("autoApply",!0)("linkedCalendars",!0)("maxDate",ctx.maxISO)("locale",ctx.locale)("startDate",ctx.selected.startDate)("endDate",ctx.selected.endDate||null),\u0275\u0275advance(),\u0275\u0275property("formGroup",ctx.form),\u0275\u0275advance(5),\u0275\u0275property("placeholder",\u0275\u0275interpolate(\u0275\u0275pipeBind1(31,27,"FROM__DATE"))),\u0275\u0275advance(2),\u0275\u0275conditional(ctx.form.controls.from.hasError("inverted")?32:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.from.hasError("maxDate")?33:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.from.hasError("unitOutOfRange")?34:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.from.hasError("unparsable")?35:-1),\u0275\u0275advance(4),\u0275\u0275property("placeholder",\u0275\u0275interpolate(\u0275\u0275pipeBind1(40,29,"TO__DATE"))),\u0275\u0275advance(2),\u0275\u0275conditional(ctx.form.controls.to.hasError("inverted")?41:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.to.hasError("maxDate")?42:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.to.hasError("unitOutOfRange")?43:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx.form.controls.to.hasError("unparsable")?44:-1),\u0275\u0275advance(5),\u0275\u0275property("disabled",ctx.form.invalid),\u0275\u0275advance(5),\u0275\u0275repeater(ctx.ranges))},dependencies:[FlexModule,DefaultLayoutDirective,DefaultLayoutGapDirective,DefaultLayoutAlignDirective,DefaultFlexDirective,MatButtonModule,MatButton,MatFormFieldModule,MatFormField,MatLabel,MatError,MatIconModule,MatIcon,MatInputModule,MatInput,MatListModule,MatActionList,MatListItem,MatMenuModule,MatMenu,MatMenuItem,MatMenuTrigger,MatToolbarModule,MatToolbar,NgxDaterangepickerMd,DaterangepickerComponent,ReactiveFormsModule,\u0275NgNoValidate,DefaultValueAccessor,NgControlStatus,NgControlStatusGroup,FormGroupDirective,FormControlName,TranslateModule,TranslateDirective,TranslatePipe],styles:['@keyframes _ngcontent-%COMP%_zoom-in{0%{transform:scale(.75);opacity:.9}to{transform:scale(1);opacity:1}}[_nghost-%COMP%]{min-width:754px;max-height:514px;background-color:var(--mat-sys-surface-container);animation:_ngcontent-%COMP%_zoom-in .14s cubic-bezier(0,0,.2,1) both;border-radius:4px;box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f;transform-origin:top right}[_nghost-%COMP%] .mat-toolbar[_ngcontent-%COMP%]{border-bottom:1px solid var(--mat-sys-outline-variant);--mat-toolbar-container-background-color: var(--mat-sys-surface-container);--mat-toolbar-title-text-size: 14px}[_nghost-%COMP%] .time-zone-select[_ngcontent-%COMP%]{padding:0 4px 0 8px;font-size:12px;color:color-mix(in srgb,transparent,var(--mat-sys-on-surface) 67%)}[_nghost-%COMP%] .time-zone-select[_ngcontent-%COMP%] .mat-icon[_ngcontent-%COMP%]:first-child{height:20px;width:20px;margin-right:4px;font-size:20px}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker{margin-top:0;background-color:var(--mat-sys-surface-container);box-shadow:none;border-radius:0}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker .calendar-table{background-color:var(--mat-sys-surface-container);border-color:var(--mat-sys-surface-container)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.available:hover, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.available:hover{background-color:var(--mat-sys-surface-container-highest)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td{transition-property:none;opacity:1}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.off{color:color-mix(in srgb,transparent,currentcolor 16%)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.off.active:hover{background-color:#eee;border-radius:50%}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.off, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.off.in-range, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.off.start-date, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.off.end-date{background-color:var(--mat-sys-surface-container)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker tbody tr td{height:32px}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.month{font-weight:500;color:color-mix(in srgb,transparent,currentcolor 77%)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.next, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.prev{min-width:28px}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.available.prev, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.available.prev, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.available.next, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.available.next{background-image:none}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.available.prev:after, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.available.prev:after, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.available.next:after, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.available.next:after{content:"";display:block;height:2em;width:2em;background-color:var(--mat-sys-on-surface);background-image:none;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-size:.5em;mask-size:.5em;-webkit-mask-position:center;mask-position:center}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.available.prev:after, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.available.prev:after{-webkit-mask-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB2aWV3Qm94PSIwIDAgMy43IDYiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMCAwIDMuNyA2IiB4bWw6c3BhY2U9InByZXNlcnZlIj4NCjxnPg0KCTxwYXRoIGQ9Ik0zLjcsMC43TDEuNCwzbDIuMywyLjNMMyw2TDAsM2wzLTNMMy43LDAuN3oiLz4NCjwvZz4NCjwvc3ZnPg0K);mask-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB2aWV3Qm94PSIwIDAgMy43IDYiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMCAwIDMuNyA2IiB4bWw6c3BhY2U9InByZXNlcnZlIj4NCjxnPg0KCTxwYXRoIGQ9Ik0zLjcsMC43TDEuNCwzbDIuMywyLjNMMyw2TDAsM2wzLTNMMy43LDAuN3oiLz4NCjwvZz4NCjwvc3ZnPg0K)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.available.next:after, [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker th.available.next:after{-webkit-mask-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB2aWV3Qm94PSIwIDAgMy43IDYiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMCAwIDMuNyA2IiB4bWw6c3BhY2U9InByZXNlcnZlIj4NCjxnPg0KCTxwYXRoIGQ9Ik0zLjcsMC43TDEuNCwzbDIuMywyLjNMMyw2TDAsM2wzLTNMMy43LDAuN3oiLz4NCjwvZz4NCjwvc3ZnPg0K);mask-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB2aWV3Qm94PSIwIDAgMy43IDYiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMCAwIDMuNyA2IiB4bWw6c3BhY2U9InByZXNlcnZlIj4NCjxnPg0KCTxwYXRoIGQ9Ik0zLjcsMC43TDEuNCwzbDIuMywyLjNMMyw2TDAsM2wzLTNMMy43LDAuN3oiLz4NCjwvZz4NCjwvc3ZnPg0K)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker tr.week-days th{font-size:11px;font-weight:400;color:color-mix(in srgb,transparent,currentcolor 38%)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.in-range{background-color:color-mix(in srgb,transparent,var(--mat-sys-primary) 12%);color:color-mix(in srgb,transparent,currentcolor 87%)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.today:not(.active,.in-range,.off){border:1px solid color-mix(in srgb,transparent,currentcolor 38%)}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.active:not(.off), [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.active:not(.off):hover{background-color:var(--mat-sys-primary);color:var(--mat-sys-on-primary);border-radius:50%;opacity:1;transition-property:border-radius}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.active:not(.off).start-date:not(.end-date), [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.active:not(.off):hover.start-date:not(.end-date){border-top-right-radius:0;border-bottom-right-radius:0}[_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.active:not(.off).end-date:not(.start-date), [_nghost-%COMP%] .picker[_ngcontent-%COMP%] .md-drppicker td.active:not(.off):hover.end-date:not(.start-date){border-top-left-radius:0;border-bottom-left-radius:0}[_nghost-%COMP%] .ranges[_ngcontent-%COMP%]{border-left:1px solid var(--mat-sys-outline-variant);height:449px;width:200px;overflow-y:auto}[_nghost-%COMP%] .ranges[_ngcontent-%COMP%] .mat-mdc-action-list[dense][_ngcontent-%COMP%]{padding:4px 0}[_nghost-%COMP%] .ranges[_ngcontent-%COMP%] .mat-mdc-action-list[dense][_ngcontent-%COMP%] .mat-mdc-list-item[_ngcontent-%COMP%]{padding-top:6px;padding-bottom:6px;--mat-list-list-item-one-line-container-height: auto;--mat-list-list-item-label-text-line-height: 14px;--mat-list-list-item-label-text-size: 12px}[_nghost-%COMP%] .ranges[_ngcontent-%COMP%] .mat-mdc-action-list[dense][_ngcontent-%COMP%] .mat-mdc-list-item[_ngcontent-%COMP%] .mdc-list-item__primary-text{white-space:normal}[_nghost-%COMP%] fieldset[_ngcontent-%COMP%]{margin:0;padding:0 16px;border:none}[_nghost-%COMP%] .actions[_ngcontent-%COMP%]{padding:12px 16px}[_nghost-%COMP%] .actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{margin-left:8px}']})}}return PeriodPanelComponent2})();var DEFAULT_CONNECTED_POSITIONS=[{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top",offsetX:0,offsetY:0}],PeriodPanelService=(()=>{class PeriodPanelService2{constructor(){this.injector=inject(Injector),this.overlay=inject(Overlay)}show(origin,data,positions){let overlayRef=this.createOverlay(origin,positions),instance=new PeriodPanelRef(overlayRef);return this.attachPanelContainer(overlayRef,instance,data,this.getTransformOrigin(positions)),instance}getTransformOrigin(positions){if(!positions)return;let positionOriginX=positions[0].originX,originX=positionOriginX==="start"?"left":positionOriginX==="end"?"right":"center",originY=positions[0].originY;return`${originX} ${originY}`}createOverlay(origin,positions){let overlayRef=this.overlay.create(this.getOverlayConfig(origin,positions));return overlayRef.backdropClick().subscribe(()=>overlayRef.dispose()),overlayRef}createInjector(panelRef,data){return Injector.create({providers:[{provide:PeriodPanelRef,useValue:panelRef},{provide:PERIOD_PANEL_DATA,useValue:data}],parent:this.injector})}attachPanelContainer(overlayRef,panelRef,data,transformOrigin){let injector=this.createInjector(panelRef,data),containerPortal=new ComponentPortal(PeriodPanelComponent,null,injector),containerRef=overlayRef.attach(containerPortal);if(transformOrigin){let panelElement=overlayRef.overlayElement.firstElementChild;panelElement.style.transformOrigin=transformOrigin}return containerRef.instance}getOverlayConfig(origin,positions){let positionStrategy=this.overlay.position().flexibleConnectedTo(origin).withPositions(positions||DEFAULT_CONNECTED_POSITIONS);return new OverlayConfig({hasBackdrop:!0,backdropClass:"overlay-transparent-backdrop",panelClass:"ix-period-panel-container",scrollStrategy:this.overlay.scrollStrategies.noop(),positionStrategy})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PeriodPanelService2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:PeriodPanelService2,factory:PeriodPanelService2.\u0275fac,providedIn:"root"})}}return PeriodPanelService2})();function PeriodControlsComponent_Conditional_0_Template(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",2),\u0275\u0275pipe(1,"translate"),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.handleZoomOutButtonClick())}),\u0275\u0275elementStart(2,"mat-icon"),\u0275\u0275text(3,"zoom_out"),\u0275\u0275elementEnd()()}rf&2&&\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(1,1,"ZOOM_OUT"))}var PeriodControlsComponent=(()=>{class PeriodControlsComponent3{get gtSm(){return this.bpObserver.isMatched("(min-width: 960px)")}constructor(bpObserver,bottomSheet,periodPanel,translate){this.bpObserver=bpObserver,this.bottomSheet=bottomSheet,this.periodPanel=periodPanel,this.translate=translate,this.periodSpecSelected=new EventEmitter,this.timeZoneSpecSelected=new EventEmitter}ngOnChanges(changes){changes.periodSpecs&&(this.periodButtonLabel=this.getPeriodButtonLabel(),this.zoomOutIsVisible=this.getZoomOutIsVisible())}handleZoomOutButtonClick(){this.zoomOut()}handlePeriodButtonClick(event2){return this.gtSm?this.openPeriodPanel(event2):this.openPeriodBottomSheet()}openPeriodBottomSheet(){this.periodSpecs&&this.bottomSheet.open(PeriodBottomSheetComponent,{data:{periodSpec:this.periodSpecs.active}}).afterDismissed().subscribe(periodSpec=>{periodSpec&&(this.periodSpecs=__spreadProps(__spreadValues({},this.periodSpecs),{selected:periodSpec}),this.periodSpecSelected.emit(periodSpec))})}openPeriodPanel(event2){this.periodSpecs&&this.periodPanel.show(event2.currentTarget,{periodSpec:this.periodSpecs.active||null,deviceTimeZone:this.deviceTimeZone,timeZoneSpec:this.timeZoneSpec,timeZoneSpecSelected:this.timeZoneSpecSelected}).afterClosed().subscribe(periodSpec=>{periodSpec&&(this.periodSpecs=__spreadProps(__spreadValues({},this.periodSpecs),{selected:periodSpec}),this.periodSpecSelected.emit(periodSpec))})}getPeriodButtonLabel(){return this.periodSpecs?.active?typeof this.periodSpecs.active=="string"?this.translate.instant(getTranslateKeyForPeriod(this.periodSpecs.active),getTranslateParamsForPeriod(this.periodSpecs.active)):toStringTimeRange(this.periodSpecs.active):""}getZoomOutIsVisible(){return this.periodSpecs?!isEqual_default(this.periodSpecs.active,this.periodSpecs.selected):!1}zoomOut(){this.periodSpecSelected.emit(this.periodSpecs.selected)}enterKeyDownHandler(event2){event2.target.blur()}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PeriodControlsComponent3)(\u0275\u0275directiveInject(BreakpointObserver),\u0275\u0275directiveInject(MatBottomSheet),\u0275\u0275directiveInject(PeriodPanelService),\u0275\u0275directiveInject(TranslateService))}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:PeriodControlsComponent3,selectors:[["ix-period-controls"]],inputs:{deviceTimeZone:"deviceTimeZone",periodSpecs:"periodSpecs",timeZoneSpec:"timeZoneSpec",mobile:"mobile"},outputs:{periodSpecSelected:"periodSpecSelected",timeZoneSpecSelected:"timeZoneSpecSelected"},standalone:!1,features:[\u0275\u0275NgOnChangesFeature],decls:3,vars:2,consts:[["mat-stroked-button","",1,"zoom-out-button",3,"matTooltip"],["mat-stroked-button","",3,"keydown.enter","click"],["mat-stroked-button","",1,"zoom-out-button",3,"click","matTooltip"]],template:function(rf,ctx){rf&1&&(\u0275\u0275conditionalCreate(0,PeriodControlsComponent_Conditional_0_Template,4,3,"button",0),\u0275\u0275elementStart(1,"button",1),\u0275\u0275listener("keydown.enter",function($event){return ctx.enterKeyDownHandler($event)})("click",function($event){return ctx.handlePeriodButtonClick($event)}),\u0275\u0275text(2),\u0275\u0275elementEnd()),rf&2&&(\u0275\u0275conditional(ctx.zoomOutIsVisible?0:-1),\u0275\u0275advance(2),\u0275\u0275textInterpolate1(" ",ctx.periodButtonLabel,`
821
- `))},dependencies:[MatButton,MatIcon,MatTooltip,TranslatePipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .zoom-out-button[_ngcontent-%COMP%]{min-width:0;padding:0 7px;margin-right:8px}[_nghost-%COMP%] .zoom-out-button[_ngcontent-%COMP%] .mat-icon[_ngcontent-%COMP%]{margin:0}"],changeDetection:0})}}return PeriodControlsComponent3})();var BackendComponentBrokerDirective=(()=>{class BackendComponentBrokerDirective3{constructor(){this.scopeRef=inject(ComponentGridScopeDirective,{optional:!0}),this.callerFactory=inject(BackendComponentCallerServiceFactory),this.facade=inject(BackendComponentBrokerFacade),this.clientProxy=inject(BackendComponentClientProxyService),this.destroyRef=inject(DestroyRef),this.myCompany$=this.facade.myCompany$,this.myUser$=this.facade.myUser$,this.agentOrAssetId$=new ReplaySubject(1)}set agentOrAssetId(agentOrAssetId){this.agentOrAssetId$.next(agentOrAssetId)}ngOnInit(){combineLatest([this.facade.findAgentAndAsset(this.agentOrAssetId$),this.facade.myCompany$,this.facade.myUser$]).pipe(filter(([,myCompany,myUser])=>!!myCompany&&!!myUser),takeUntilDestroyed(this.destroyRef)).subscribe(([[agent,asset],myCompany,myUser])=>{this.caller=this.callerFactory.create({agent,asset,myCompany,myUser})}),this.clientProxy.onCall(this.scopeRef?.value).pipe(mergeMap(call=>this.facade.resolveTemplateFromPageComponent(call.pageComponentId).pipe(first(),map(result=>({call:call.call,template:{publicId:result}})))),mergeMap(call=>this.caller?this.caller.call(call).pipe(map(result=>({result,call})),catchError(error3=>(this.clientProxy.emitError({call:call.call,data:error3},this.scopeRef?.value),EMPTY))):EMPTY),takeUntilDestroyed(this.destroyRef)).subscribe(({result,call})=>{this.clientProxy.emitResult({call:call.call,data:result.value},this.scopeRef?.value)})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||BackendComponentBrokerDirective3)}}static{this.\u0275dir=\u0275\u0275defineDirective({type:BackendComponentBrokerDirective3,selectors:[["","ixBackendComponentBroker",""]],inputs:{agentOrAssetId:"agentOrAssetId"}})}}return BackendComponentBrokerDirective3})();var PagesModule=(()=>{class PagesModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PagesModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:PagesModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({providers:[ComponentContextService],imports:[SharedModule,NgxDaterangepickerMd,ComponentGridModule,ComponentPropertiesModule,FileSaveModule,PeriodBottomSheetComponent,PeriodPanelComponent,ComponentGridModule,ComponentPropertiesModule]})}}return PagesModule2})();function mutationObservableFactory(target,options){return new Observable(subscriber=>{let observer=new MutationObserver(records=>{subscriber.next(records)});return observer.observe(target,options),function(){observer.disconnect()}})}var _c018=["*"],ButtonToggleComponent=(()=>{class ButtonToggleComponent3{constructor(){this.elRef=inject(ElementRef),this.disabled=!1,this.valueChange=new EventEmitter}getWidth(){return this.elRef.nativeElement.clientWidth??0}getOffset(){return this.elRef.nativeElement.offsetLeft??0}select(){this.selected=!0}unselect(){this.selected=!1}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ButtonToggleComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ButtonToggleComponent3,selectors:[["ix-button-toggle"]],inputs:{value:"value",disabled:"disabled"},outputs:{valueChange:"valueChange"},ngContentSelectors:_c018,decls:2,vars:4,consts:[["role","tab","tabindex","0",1,"button",3,"click"]],template:function(rf,ctx){rf&1&&(\u0275\u0275projectionDef(),\u0275\u0275domElementStart(0,"div",0),\u0275\u0275domListener("click",function(){return ctx.valueChange.emit(ctx.value)}),\u0275\u0275projection(1),\u0275\u0275domElementEnd()),rf&2&&\u0275\u0275classProp("disabled",ctx.disabled)("selected",ctx.selected)},styles:["[_nghost-%COMP%] .button[_ngcontent-%COMP%]{display:flex;flex-direction:row;align-items:center;padding:0 12px;text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;word-wrap:normal;cursor:pointer;font-size:14px;max-width:100%;position:relative;height:34px;color:color-mix(in srgb,currentcolor 50%,transparent);transition:box-shadow .2s cubic-bezier(.4,1,.75,.9);-webkit-user-select:none;user-select:none}[_nghost-%COMP%] .button.selected[_ngcontent-%COMP%]{color:currentcolor;font-weight:500;z-index:1}[_nghost-%COMP%] .button.disabled[_ngcontent-%COMP%]{color:color-mix(in srgb,currentcolor 25%,transparent);pointer-events:none}[_nghost-%COMP%] .button[_ngcontent-%COMP%]:focus{outline:none;outline-offset:0;-moz-outline-radius:0}[_nghost-%COMP%]:hover [_ngcontent-%COMP%]:not(.selected,.disabled){border-bottom:none;color:color-mix(in srgb,currentcolor 75%,transparent);background-color:color-mix(in srgb,currentcolor 4%,transparent)!important;border-radius:12px;box-shadow:none!important;transition:all .2s cubic-bezier(.4,1,.75,.9)}"]})}}return ButtonToggleComponent3})();var _c019=["*"],ButtonToggleGroupComponent=(()=>{class ButtonToggleGroupComponent3{constructor(){this.cdRef=inject(ChangeDetectorRef),this.elRef=inject(ElementRef),this.destroy=inject(DestroyRef),this.ngZone=inject(NgZone),this.indicatorStyle=null,this._animate=!1,mutationObservableFactory(this.elRef.nativeElement,{childList:!0}).pipe(takeUntilDestroyed(this.destroy)).subscribe(()=>{this.animate(),this.cdRef.markForCheck()}),resizeObservableFactory(this.elRef.nativeElement).pipe(skip(1),takeUntilDestroyed(this.destroy)).subscribe(()=>{this.animate(),this.cdRef.markForCheck()})}ngOnChanges(changes){changes.value&&!changes.value.isFirstChange()&&this.animate()}animate(){this._active=this._buttons?.find(segment=>segment.value===this.value)??null,this._active?.select(),this._buttons?.filter(s2=>s2!==this._active).forEach(s2=>s2.unselect()),this.indicatorStyle=this._active?{width:`${this._active.getWidth()}px`,transform:`translateX(${this._active.getOffset()}px)`}:null,this._active&&!this._animate&&this.ngZone.runOutsideAngular(()=>{setTimeout(()=>{this._animate=!0,this.elRef.nativeElement.classList.add("animate")},0)})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ButtonToggleGroupComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ButtonToggleGroupComponent3,selectors:[["ix-button-toggle-group"]],contentQueries:function(rf,ctx,dirIndex){if(rf&1&&\u0275\u0275contentQuery(dirIndex,ButtonToggleComponent,4),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx._buttons=_t)}},inputs:{value:"value"},features:[\u0275\u0275NgOnChangesFeature],ngContentSelectors:_c019,decls:3,vars:2,consts:[["role","tablist",1,"button-list"],[1,"active-indicator"]],template:function(rf,ctx){rf&1&&(\u0275\u0275projectionDef(),\u0275\u0275domElementStart(0,"div",0),\u0275\u0275domElement(1,"div",1),\u0275\u0275projection(2),\u0275\u0275domElementEnd()),rf&2&&(\u0275\u0275advance(),\u0275\u0275styleMap(ctx.indicatorStyle))},styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .button-list[_ngcontent-%COMP%]{align-items:flex-end;border:none;display:flex;flex:0 0 auto;list-style:none;margin:0;padding:0;position:relative;background-color:var(--button-toggle-bg, var(--mat-sys-background));color:var(--button-toggle-color, var(--mat-sys-on-background));box-shadow:0 0 0 1px color-mix(in srgb,transparent,var(--button-toggle-color, var(--mat-sys-on-background)) 24%);border-radius:12px}[_nghost-%COMP%] .button-list[_ngcontent-%COMP%] .active-indicator[_ngcontent-%COMP%]{left:0;pointer-events:none;position:absolute;top:0;transform:translate(0);transition:height,transform,width;transition-duration:0;transition-timing-function:cubic-bezier(.4,1,.75,.9);border-radius:12px;box-shadow:0 0 0 1px var(--button-toggle-color, var(--mat-sys-on-background)),inset 0 0 0 1px var(--button-toggle-color, var(--mat-sys-on-background));height:34px;background-color:var(--button-toggle-bg, var(--mat-sys-background));z-index:1}.animate[_nghost-%COMP%] .button-list[_ngcontent-%COMP%] .active-indicator[_ngcontent-%COMP%]{transition-duration:.2s}"],changeDetection:0})}}return ButtonToggleGroupComponent3})();var ButtonToggleModule=(()=>{class ButtonToggleModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ButtonToggleModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:ButtonToggleModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({})}}return ButtonToggleModule2})();var ReloadOnValueChangeDirective=(()=>{class ReloadOnValueChangeDirective2{constructor(cdRef,templateRef,viewContainer){this.cdRef=cdRef,this.templateRef=templateRef,this.viewContainer=viewContainer,this.changes=new ReplaySubject,this.destroy=inject(DestroyRef)}ngOnInit(){this.viewContainer.createEmbeddedView(this.templateRef),this.changes.pipe(distinctUntilChanged(isEqual_default),takeUntilDestroyed(this.destroy)).subscribe(()=>{this.viewContainer.clear(),this.viewContainer.createEmbeddedView(this.templateRef),this.cdRef.markForCheck()})}ngOnChanges(changes){changes.value.isFirstChange()||this.changes.next(changes.value.currentValue)}ngOnDestroy(){this.changes.complete()}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ReloadOnValueChangeDirective2)(\u0275\u0275directiveInject(ChangeDetectorRef),\u0275\u0275directiveInject(TemplateRef),\u0275\u0275directiveInject(ViewContainerRef))}}static{this.\u0275dir=\u0275\u0275defineDirective({type:ReloadOnValueChangeDirective2,selectors:[["","ixReloadOnValueChange",""]],inputs:{value:[0,"ixReloadOnValueChange","value"]},features:[\u0275\u0275NgOnChangesFeature]})}}return ReloadOnValueChangeDirective2})();var AlertDialogModule=(()=>{class AlertDialogModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||AlertDialogModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:AlertDialogModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[SharedModule]})}}return AlertDialogModule2})();function assetsToAssetTreeOptions(rootId,descendantAssets){let sortedDescendants=sortBy_default(descendantAssets,["order"]),assetDict=Object.fromEntries(sortedDescendants.map(a=>[a.publicId,a])),childrenMap=new Map;sortedDescendants.forEach(asset=>{let parentId=asset.parent?.publicId;parentId&&(childrenMap.has(parentId)||childrenMap.set(parentId,[]),childrenMap.get(parentId)?.push(asset))});let assetDepthMap=new Map(sortedDescendants.map(a=>[a.publicId,_getAssetDepth(a,assetDict)])),directSubAssets=childrenMap.get(rootId)||[];if(directSubAssets.length===0)return[];let flattenedTree=[];return directSubAssets.forEach(asset=>_buildAssetArray(asset,childrenMap,flattenedTree)),flattenedTree.map(a=>{let depth=assetDepthMap.get(a.publicId)??0;return{id:a.publicId,name:a.name??"",depth,match:null}})}function _buildAssetArray(asset,childrenMap,arr){arr.push(asset),(childrenMap.get(asset.publicId)||[]).forEach(child=>_buildAssetArray(child,childrenMap,arr))}function _getAssetDepth(asset,entities,depth=0){let parentId=asset.parent?.publicId;return parentId&&entities[parentId]?_getAssetDepth(entities[parentId],entities,depth+1):depth}var PreviewDeviceSelectFacade=(()=>{class PreviewDeviceSelectFacade2{constructor(){this.store=inject(Store),this.agentsDict$=this.store.select(selectEntities3),this.customPropsDict$=this.store.select(selectAll27).pipe(map(props2=>props2.reduce((dict,p)=>(p.resourceType==="Agent"||p.resourceType==="Asset")&&p.scopeType&&p.slug?__spreadProps(__spreadValues({},dict),{[`${p.resourceType}.custom.${p.scopeType}${p.slug}`]:p}):dict,{}))),this.groupsDict$=this.store.select(selectEntities9)}assetTreeByRootAssetPublicId(rootAssetPublicId){return rootAssetPublicId?this.store.select(selectAllLoadedForRoot(rootAssetPublicId)).pipe(filter(loaded=>loaded),switchMap(()=>this.store.select(selectAllForRoot(rootAssetPublicId))),map(assets=>assetsToAssetTreeOptions(rootAssetPublicId,assets.filter(asset=>!!asset.parent)))):of([])}getRootAssetIdBySubAssetId(subAssetId){return this.store.select(selectEntityWithFields4(subAssetId)(["root"])).pipe(map(asset=>asset?.root?.publicId??null))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PreviewDeviceSelectFacade2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:PreviewDeviceSelectFacade2,factory:PreviewDeviceSelectFacade2.\u0275fac,providedIn:"root"})}}return PreviewDeviceSelectFacade2})();function geoLocationIsEmpty(geoLocation){return geoLocation===null||geoLocation.city==="-"&&geoLocation.country==="-"||geoLocation.latitude==="0.000000"&&geoLocation.longitude==="0.000000"}function mapGeoLocationToName(geoLocation){return geoLocationIsEmpty(geoLocation)?null:geoLocation?.city&&geoLocation?.country?`${geoLocation.city}, ${geoLocation.country}`:geoLocation?.country?geoLocation.country:null}function findAgentOrAssetMatch(a,query,customPropsDict,groupsDict,agentsDict,nullifyName=!0){let q=deburr_default(query.toLowerCase().trim());if((a.name?deburr_default(a.name.toLowerCase()):null)?.includes(q))return nullifyName?null:a.name;if(a.description?.toLowerCase().includes(q))return a.description;if("serialNumber"in a&&a.serialNumber?.toLowerCase().includes(q))return a.serialNumber;let location2="location"in a?a.location?.name||(a.geoLocation?mapGeoLocationToName(a.geoLocation):null):null;if(location2?.toLowerCase().includes(q))return location2;if(groupsDict){let groups=a.memberships?.map(m=>groupsDict[m.group?.publicId]).filter(g=>!!g?.type)??[],groupName=_findBestMatch(groups.map(g=>g.name),q);if(groupName)return groupName}if(customPropsDict){let resType="agent"in a?"Asset":"Agent",customValues=Object.keys(customPropsDict).filter(key=>key.startsWith(`${resType}.`)).map(key=>(a.custom??{})[key.replace(`${resType}.custom.`,"")]).filter(val=>!isNil_default(val)).map(String),customValue=_findBestMatch(customValues,q);if(customValue)return customValue}if(agentsDict&&"agent"in a&&a.agent?.publicId){let linkedAgent=agentsDict[a.agent.publicId];if(linkedAgent)return findAgentOrAssetMatch(linkedAgent,query,customPropsDict,groupsDict,void 0,!1)}}function _findBestMatch(values,q){return values.reduce((best,value)=>{if(!value)return best;let v=deburr_default(value.toLowerCase());if(!v.includes(q))return best;let matchRatio=q.length/v.length;return!best||matchRatio>best.matchRatio?{value,matchRatio}:best},void 0)?.value}var _c020=a0=>[a0],_forTrack08=($index,$item)=>$item.id;function PreviewDeviceSelectComponent_Conditional_10_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",9),\u0275\u0275text(1),\u0275\u0275pipe(2,"translate"),\u0275\u0275elementEnd()),rf&2){let noneOpt_r3=ctx;\u0275\u0275property("value",noneOpt_r3.value),\u0275\u0275advance(),\u0275\u0275textInterpolate(noneOpt_r3.label??\u0275\u0275pipeBind1(2,2,"NONE"))}}function PreviewDeviceSelectComponent_For_12_Conditional_4_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"span",11),\u0275\u0275pipe(1,"highlightText")),rf&2){let option_r4=\u0275\u0275nextContext().$implicit,ctx_r4=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(1,1,option_r4.match,ctx_r4.query()),\u0275\u0275sanitizeHtml)}}function PreviewDeviceSelectComponent_For_12_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",9)(1,"div"),\u0275\u0275element(2,"span",10),\u0275\u0275pipe(3,"highlightText"),\u0275\u0275conditionalCreate(4,PreviewDeviceSelectComponent_For_12_Conditional_4_Template,2,4,"span",11),\u0275\u0275elementEnd()()),rf&2){let option_r4=ctx.$implicit,ctx_r4=\u0275\u0275nextContext();\u0275\u0275property("value",option_r4.id),\u0275\u0275advance(2),\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(3,3,option_r4.name,ctx_r4.query()),\u0275\u0275sanitizeHtml),\u0275\u0275advance(2),\u0275\u0275conditional(option_r4.match?4:-1)}}function PreviewDeviceSelectComponent_Conditional_13_For_14_Conditional_4_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"span",11),\u0275\u0275pipe(1,"highlightText")),rf&2){let option_r8=\u0275\u0275nextContext().$implicit,ctx_r4=\u0275\u0275nextContext(2);\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(1,1,option_r8.match,ctx_r4.query()),\u0275\u0275sanitizeHtml)}}function PreviewDeviceSelectComponent_Conditional_13_For_14_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",9)(1,"div"),\u0275\u0275element(2,"span",10),\u0275\u0275pipe(3,"highlightText"),\u0275\u0275conditionalCreate(4,PreviewDeviceSelectComponent_Conditional_13_For_14_Conditional_4_Template,2,4,"span",11),\u0275\u0275elementEnd()()),rf&2){let option_r8=ctx.$implicit,ctx_r4=\u0275\u0275nextContext(2);\u0275\u0275property("value",option_r8.id),\u0275\u0275advance(2),\u0275\u0275styleProp("padding-left",\u0275\u0275pureFunction1(8,_c020,8*option_r8.depth),"px"),\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(3,5,option_r8.name,ctx_r4.query()),\u0275\u0275sanitizeHtml),\u0275\u0275advance(2),\u0275\u0275conditional(option_r8.match?4:-1)}}function PreviewDeviceSelectComponent_Conditional_13_Template(rf,ctx){if(rf&1){let _r6=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"div")(1,"button",12),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r6);let subAssetSelect_r7=\u0275\u0275reference(4);return \u0275\u0275resetView(subAssetSelect_r7.onContainerClick())}),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"mat-select",13,3),\u0275\u0275listener("closed",function(){\u0275\u0275restoreView(_r6);let ctx_r4=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r4.handleSubAssetSelectClosed())}),\u0275\u0275elementStart(5,"mat-option",7),\u0275\u0275element(6,"ngx-mat-select-search",8),\u0275\u0275pipe(7,"translate"),\u0275\u0275pipe(8,"translate"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(9,"mat-option",9)(10,"span",14),\u0275\u0275text(11,"NONE"),\u0275\u0275elementEnd()(),\u0275\u0275element(12,"mat-divider"),\u0275\u0275repeaterCreate(13,PreviewDeviceSelectComponent_Conditional_13_For_14_Template,5,10,"mat-option",9,_forTrack08),\u0275\u0275elementEnd()()}if(rf&2){let ctx_r4=\u0275\u0275nextContext(),subAssetDialogOptionTemplate_r9=\u0275\u0275reference(17);\u0275\u0275advance(2),\u0275\u0275textInterpolate1(" ",ctx_r4.subAssetSelectTriggerLabel()," "),\u0275\u0275advance(),\u0275\u0275property("formControl",ctx_r4.subAssetControl)("ixSelectDialogOptionTemplate",subAssetDialogOptionTemplate_r9)("ixSelectDialogSearchPredicate",ctx_r4.subAssetSearchPredicate),\u0275\u0275advance(3),\u0275\u0275property("formControl",ctx_r4.queryControl)("placeholderLabel",\u0275\u0275pipeBind1(7,8,"SEARCH"))("noEntriesFoundLabel",\u0275\u0275pipeBind1(8,10,"NO_RESULTS_FOUND")),\u0275\u0275advance(3),\u0275\u0275property("value",null),\u0275\u0275advance(4),\u0275\u0275repeater(ctx_r4.subAssetOptions())}}function PreviewDeviceSelectComponent_ng_template_14_Conditional_5_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"span",11),\u0275\u0275pipe(1,"highlightText")),rf&2){\u0275\u0275nextContext();let query_r10=\u0275\u0275readContextLet(2);\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(1,1,ctx,query_r10),\u0275\u0275sanitizeHtml)}}function PreviewDeviceSelectComponent_ng_template_14_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",15)(1,"div"),\u0275\u0275declareLet(2),\u0275\u0275element(3,"span",10),\u0275\u0275pipe(4,"highlightText"),\u0275\u0275conditionalCreate(5,PreviewDeviceSelectComponent_ng_template_14_Conditional_5_Template,2,4,"span",11),\u0275\u0275elementEnd()()),rf&2){let tmp_5_0,tmp_7_0,option_r11=ctx.$implicit,ctx_r4=\u0275\u0275nextContext();\u0275\u0275advance(2);let query_r12=\u0275\u0275storeLet(((tmp_5_0=ctx_r4.selectDialogTrigger())==null||tmp_5_0.searchQueryControl==null?null:tmp_5_0.searchQueryControl.value)??"");\u0275\u0275advance(),\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(4,3,option_r11.viewValue,query_r12),\u0275\u0275sanitizeHtml),\u0275\u0275advance(2),\u0275\u0275conditional((tmp_7_0=ctx_r4.findOptionMatch("device",option_r11,query_r12))?5:-1,tmp_7_0)}}function PreviewDeviceSelectComponent_ng_template_16_Conditional_5_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"span",11),\u0275\u0275pipe(1,"highlightText")),rf&2){\u0275\u0275nextContext();let query_r13=\u0275\u0275readContextLet(2);\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(1,1,ctx,query_r13),\u0275\u0275sanitizeHtml)}}function PreviewDeviceSelectComponent_ng_template_16_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",15)(1,"div"),\u0275\u0275declareLet(2),\u0275\u0275element(3,"span",10),\u0275\u0275pipe(4,"highlightText"),\u0275\u0275conditionalCreate(5,PreviewDeviceSelectComponent_ng_template_16_Conditional_5_Template,2,4,"span",11),\u0275\u0275elementEnd()()),rf&2){let tmp_5_0,tmp_7_0,option_r14=ctx.$implicit,ctx_r4=\u0275\u0275nextContext();\u0275\u0275advance(2);let query_r15=\u0275\u0275storeLet(((tmp_5_0=ctx_r4.selectDialogTrigger())==null||tmp_5_0.searchQueryControl==null?null:tmp_5_0.searchQueryControl.value)??"");\u0275\u0275advance(),\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(4,3,option_r14.viewValue,query_r15),\u0275\u0275sanitizeHtml),\u0275\u0275advance(2),\u0275\u0275conditional((tmp_7_0=ctx_r4.findOptionMatch("subAsset",option_r14,query_r15))?5:-1,tmp_7_0)}}var PreviewDeviceSelectComponent=(()=>{class PreviewDeviceSelectComponent2{constructor(){this.agentAndRootAssets=input.required(),this.value=input(null),this.noneOption=input(),this.hideSubAssets=input(!1,{transform:booleanAttribute}),this.selectionChange=output(),this.facade=inject(PreviewDeviceSelectFacade),this.translateService=inject(TranslateService),this.selectDialogTrigger=viewChild(SelectDialogTriggerDirective),this.deviceControl=new FormControl(null),this.subAssetControl=new FormControl(null),this.queryControl=new FormControl("",{nonNullable:!0}),this.query=toSignal(this.queryControl.valueChanges,{initialValue:""}),this.agentsDict=toSignal(this.facade.agentsDict$,{requireSync:!0}),this.customPropsDict=toSignal(this.facade.customPropsDict$,{requireSync:!0}),this.groupsDict=toSignal(this.facade.groupsDict$,{requireSync:!0}),this.selectedDevicePublicId=toSignal(this.deviceControl.valueChanges.pipe(tap(()=>this.subAssetControl.setValue(null))),{initialValue:null}),this.selectedSubAssetPublicId=toSignal(this.subAssetControl.valueChanges,{initialValue:null}),this.selectedDeviceIsAsset=computed(()=>{let selectedId=this.selectedDevicePublicId();return selectedId?!(selectedId in this.agentsDict()):!1}),this.deviceOptions=computed(()=>this._getDeviceOptionsByQuery(this.query())),this.subAssetParams=computed(()=>({deviceId:this.selectedDeviceIsAsset()?this.selectedDevicePublicId():null})),this.subAssetOptionsResource=resource({params:this.subAssetParams,loader:({params})=>firstValueFrom(this.facade.assetTreeByRootAssetPublicId(params.deviceId))}),this.subAssetOptions=computed(()=>this._getSubAssetOptionsByQuery(this.query())),this.previewDeviceSelectTriggerLabel=computed(()=>{let publicId=this.selectedDevicePublicId(),emptyLabel=this.translateService.instant("SELECT_DEVICE_FOR_PREVIEW");return publicId?this.agentAndRootAssets().find(opt=>opt.publicId===publicId)?.name??emptyLabel:emptyLabel}),this.subAssetSelectTriggerLabel=computed(()=>{let publicId=this.selectedSubAssetPublicId(),emptyLabel=this.translateService.instant("SELECT_A_SUB_ASSET"),options=this.subAssetOptions();return publicId&&options?options.find(opt=>opt.id===publicId)?.name??emptyLabel:emptyLabel}),this.deviceSearchPredicate=this._optionSearchPredicate.bind(this,"device"),this.subAssetSearchPredicate=this._optionSearchPredicate.bind(this,"subAsset"),effect(()=>__async(this,null,function*(){let initialValue=this.value();if(!initialValue){this.deviceControl.setValue(null),this.subAssetControl.setValue(null);return}if(!this.hideSubAssets()&&!this.agentAndRootAssets().some(a=>a.publicId===initialValue)&&initialValue){let rootAssetId=yield firstValueFrom(this.facade.getRootAssetIdBySubAssetId(initialValue));this.deviceControl.setValue(rootAssetId,{emitModelToViewChange:!0,emitViewToModelChange:!1}),this.subAssetControl.setValue(initialValue,{emitModelToViewChange:!0,emitViewToModelChange:!1});return}this.deviceControl.setValue(initialValue,{emitModelToViewChange:!0,emitViewToModelChange:!1})}))}findOptionMatch(type,option,query){return query?(type==="device"?this._getDeviceOptionsByQuery(query):this._getSubAssetOptionsByQuery(query)).find(opt=>opt.id===option.value)?.match:void 0}handlePreviewDeviceSelectClosed(){return __async(this,null,function*(){let publicId=this.selectedDevicePublicId(),selectedSubAssetPublicId=this.selectedSubAssetPublicId();if(selectedSubAssetPublicId){let rootAssetPublicId=yield firstValueFrom(this.facade.getRootAssetIdBySubAssetId(selectedSubAssetPublicId));if(publicId===rootAssetPublicId)return}publicId&&this.selectionChange.emit(publicId)})}handleSubAssetSelectClosed(){let publicId=this.selectedSubAssetPublicId();if(publicId){this.selectionChange.emit(publicId);return}this.handlePreviewDeviceSelectClosed()}_getDeviceOptionsByQuery(query){let agentAndRootAssets=this.agentAndRootAssets();if(query){let agentsDict=this.agentsDict(),customPropsDict=this.customPropsDict(),groupsDict=this.groupsDict();return agentAndRootAssets.reduce((options,a)=>{let match2=findAgentOrAssetMatch(a,query,customPropsDict,groupsDict,agentsDict);return match2!==void 0?[...options,{id:a.publicId,name:a.name,match:match2}]:options},[])}return this.agentAndRootAssets().map(a=>({id:a.publicId,name:a.name,match:null}))}_getSubAssetOptionsByQuery(query){if(this.hideSubAssets())return[];let options=this.subAssetOptionsResource.value();if(!options)return[];if(options&&query){let agentsDict=this.agentsDict(),customPropsDict=this.customPropsDict(),groupsDict=this.groupsDict();return options.filter(opt=>findAgentOrAssetMatch({publicId:opt.id,name:opt.name},query,customPropsDict,groupsDict,agentsDict)!==void 0)}return options}_optionSearchPredicate(type,option,query){return query?(type==="device"?this._getDeviceOptionsByQuery(query):this._getSubAssetOptionsByQuery(query)).some(opt=>opt.id===option.value):!0}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PreviewDeviceSelectComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:PreviewDeviceSelectComponent2,selectors:[["ix-preview-device-select"]],viewQuery:function(rf,ctx){rf&1&&\u0275\u0275viewQuerySignal(ctx.selectDialogTrigger,SelectDialogTriggerDirective,5),rf&2&&\u0275\u0275queryAdvance()},inputs:{agentAndRootAssets:[1,"agentAndRootAssets"],value:[1,"value"],noneOption:[1,"noneOption"],hideSubAssets:[1,"hideSubAssets"]},outputs:{selectionChange:"selectionChange"},decls:18,vars:13,consts:[["previewDeviceSelect",""],["deviceDialogOptionTemplate",""],["subAssetDialogOptionTemplate",""],["subAssetSelect",""],[1,"button-group"],["matButton","outlined","data-testid","preview-device-select-button",3,"click"],["data-testid","preview-device-select","disableOptionCentering","","panelClass","preview-device-select-button-panel","name","device","ixSelectDialogTrigger","",3,"closed","formControl","ixSelectDialogOptionTemplate","ixSelectDialogSearchPredicate"],[1,"search-option"],[3,"formControl","placeholderLabel","noEntriesFoundLabel"],[3,"value"],[3,"innerHTML"],[1,"match",3,"innerHTML"],["matButton","outlined","data-testid","sub-asset-select-button",3,"click"],["data-testid","sub-asset-select","disableOptionCentering","","panelClass","preview-device-select-button-panel","name","subAsset","ixSelectDialogTrigger","",3,"closed","formControl","ixSelectDialogOptionTemplate","ixSelectDialogSearchPredicate"],["translate",""],[1,"ix-preview-device-dialog-option-template"]],template:function(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"div",4)(1,"div")(2,"button",5),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r1);let previewDeviceSelect_r2=\u0275\u0275reference(5);return \u0275\u0275resetView(previewDeviceSelect_r2.onContainerClick())}),\u0275\u0275text(3),\u0275\u0275elementEnd(),\u0275\u0275elementStart(4,"mat-select",6,0),\u0275\u0275listener("closed",function(){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.handlePreviewDeviceSelectClosed())}),\u0275\u0275elementStart(6,"mat-option",7),\u0275\u0275element(7,"ngx-mat-select-search",8),\u0275\u0275pipe(8,"translate"),\u0275\u0275pipe(9,"translate"),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(10,PreviewDeviceSelectComponent_Conditional_10_Template,3,4,"mat-option",9),\u0275\u0275repeaterCreate(11,PreviewDeviceSelectComponent_For_12_Template,5,6,"mat-option",9,_forTrack08),\u0275\u0275elementEnd()(),\u0275\u0275conditionalCreate(13,PreviewDeviceSelectComponent_Conditional_13_Template,15,12,"div"),\u0275\u0275elementEnd(),\u0275\u0275template(14,PreviewDeviceSelectComponent_ng_template_14_Template,6,6,"ng-template",null,1,\u0275\u0275templateRefExtractor)(16,PreviewDeviceSelectComponent_ng_template_16_Template,6,6,"ng-template",null,2,\u0275\u0275templateRefExtractor)}if(rf&2){let tmp_10_0,deviceDialogOptionTemplate_r16=\u0275\u0275reference(15);\u0275\u0275advance(3),\u0275\u0275textInterpolate1(" ",ctx.previewDeviceSelectTriggerLabel()," "),\u0275\u0275advance(),\u0275\u0275property("formControl",ctx.deviceControl)("ixSelectDialogOptionTemplate",deviceDialogOptionTemplate_r16)("ixSelectDialogSearchPredicate",ctx.deviceSearchPredicate),\u0275\u0275advance(3),\u0275\u0275property("formControl",ctx.queryControl)("placeholderLabel",\u0275\u0275pipeBind1(8,9,"SEARCH"))("noEntriesFoundLabel",\u0275\u0275pipeBind1(9,11,"NO_RESULTS_FOUND")),\u0275\u0275advance(3),\u0275\u0275conditional((tmp_10_0=ctx.noneOption())?10:-1,tmp_10_0),\u0275\u0275advance(),\u0275\u0275repeater(ctx.deviceOptions()),\u0275\u0275advance(2),\u0275\u0275conditional(!ctx.hideSubAssets()&&ctx.selectedDeviceIsAsset()&&ctx.subAssetOptions().length>0?13:-1)}},dependencies:[ReactiveFormsModule,NgControlStatus,FormControlDirective,MatButtonModule,MatButton,MatDividerModule,MatDivider,MatSelectModule,MatSelect,MatOption,NgxMatSelectSearchModule,MatSelectSearchComponent,TranslateModule,TranslateDirective,SelectDialogTriggerDirective,TranslatePipe,HighlightTextPipe],styles:['[_nghost-%COMP%]{display:flex;flex-direction:column;position:relative}[_nghost-%COMP%] .button-group[_ngcontent-%COMP%]{display:flex;padding-right:8px}[_nghost-%COMP%] .button-group[_ngcontent-%COMP%] div[_ngcontent-%COMP%]:first-child:not(:last-child) > .mdc-button[_ngcontent-%COMP%]{padding-left:12px;border-top-right-radius:0;border-bottom-right-radius:0}[_nghost-%COMP%] .button-group[_ngcontent-%COMP%] div[_ngcontent-%COMP%]:not(:first-child) > .mdc-button[_ngcontent-%COMP%]{border-left:0}[_nghost-%COMP%] .button-group[_ngcontent-%COMP%] div[_ngcontent-%COMP%]:last-child:not(:first-child) > .mdc-button[_ngcontent-%COMP%]{border-top-left-radius:0;border-bottom-left-radius:0}[_nghost-%COMP%] .mat-mdc-button-base[_ngcontent-%COMP%]{display:block;padding-left:8px!important;padding-right:24px!important;position:relative}[_nghost-%COMP%] .mat-mdc-button-base[_ngcontent-%COMP%] .mdc-button__label{display:block;overflow-x:hidden;text-overflow:ellipsis}[_nghost-%COMP%] .mat-mdc-button-base[_ngcontent-%COMP%] .mdc-button__label:after{content:"";position:absolute;top:50%;right:8px;margin-top:-2px;border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid currentcolor}[_nghost-%COMP%] .mat-mdc-select[_ngcontent-%COMP%]{position:absolute;visibility:hidden;top:12px;left:0;font-size:14px}@media (min-width: 960px){ .mat-mdc-select-panel.preview-device-select-button-panel{min-width:400px!important;max-width:500px!important}} .mat-mdc-select-panel.preview-device-select-button-panel .mat-mdc-option[role=option]{min-height:32px;padding-top:4px;padding-bottom:4px} .mat-mdc-select-panel.preview-device-select-button-panel .mat-mdc-option div, .ix-preview-device-dialog-option-template div{display:flex;flex-direction:column} .mat-mdc-select-panel.preview-device-select-button-panel .mat-mdc-option span:has(+.match), .ix-preview-device-dialog-option-template span:has(+.match){margin-top:6px;margin-bottom:-2px} .mat-mdc-select-panel.preview-device-select-button-panel .mat-mdc-option .match, .ix-preview-device-dialog-option-template .match{font-size:12px;line-height:14px;margin-bottom:8px;text-wrap:auto}'],changeDetection:0})}}return PreviewDeviceSelectComponent2})();var _c021=()=>[],_c17=()=>({value:"none"});function BuilderComponent_Conditional_0_Conditional_4_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"span"),\u0275\u0275text(1),\u0275\u0275elementEnd()),rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275advance(),\u0275\u0275textInterpolate1(" - ",ctx_r1.componentName)}}function BuilderComponent_Conditional_0_Conditional_14_Template(rf,ctx){if(rf&1){let _r3=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-button-toggle-group",22),\u0275\u0275listener("mousedown",function($event){return \u0275\u0275restoreView(_r3),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementStart(1,"ix-button-toggle",23),\u0275\u0275pipe(2,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r3);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.setPreviewMode($event))}),\u0275\u0275elementStart(3,"mat-icon"),\u0275\u0275text(4,"desktop_windows"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"ix-button-toggle",24),\u0275\u0275pipe(6,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r3);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.setPreviewMode($event))}),\u0275\u0275elementStart(7,"mat-icon"),\u0275\u0275text(8,"smartphone"),\u0275\u0275elementEnd()()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275property("value",ctx_r1.previewMode),\u0275\u0275advance(),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(2,3,"DESKTOP_VIEW")),\u0275\u0275advance(4),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(6,5,"MOBILE_VIEW"))}}function BuilderComponent_Conditional_0_Conditional_15_Template(rf,ctx){if(rf&1){let _r4=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-button-toggle-group",25),\u0275\u0275listener("mousedown",function($event){return \u0275\u0275restoreView(_r4),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementStart(1,"ix-button-toggle",26),\u0275\u0275pipe(2,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r4);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.setOrientation($event))}),\u0275\u0275elementStart(3,"mat-icon"),\u0275\u0275text(4,"crop_portrait"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"ix-button-toggle",27),\u0275\u0275pipe(6,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r4);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.setOrientation($event))}),\u0275\u0275elementStart(7,"mat-icon"),\u0275\u0275text(8,"crop_landscape"),\u0275\u0275elementEnd()()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275property("value",ctx_r1.orientation),\u0275\u0275advance(),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(2,3,"PORTRAIT_ORIENTATION")),\u0275\u0275advance(4),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(6,5,"LANDSCAPE_ORIENTATION"))}}function BuilderComponent_Conditional_0_Conditional_16_Template(rf,ctx){if(rf&1){let _r5=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",28),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r5);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.toggleMode())})("mousedown",function($event){return \u0275\u0275restoreView(_r5),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementStart(1,"mat-icon"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"span"),\u0275\u0275text(4),\u0275\u0275pipe(5,"translate"),\u0275\u0275elementEnd()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r1.mode==="preview"?"edit":"visibility"),\u0275\u0275advance(2),\u0275\u0275textInterpolate(\u0275\u0275pipeBind1(5,2,ctx_r1.mode==="preview"?"EDIT":"PREVIEW"))}}function BuilderComponent_Conditional_0_Conditional_36_Conditional_0_Template(rf,ctx){if(rf&1){let _r6=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-toolbar")(1,"h1"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275element(3,"span",3),\u0275\u0275elementStart(4,"button",30),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r6);let ctx_r1=\u0275\u0275nextContext(3);return \u0275\u0275resetView(ctx_r1.toggleDrawerLock())}),\u0275\u0275elementStart(5,"mat-icon"),\u0275\u0275text(6,"keyboard_arrow_right"),\u0275\u0275elementEnd()()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r1.selectedComponentTemplate==null?null:ctx_r1.selectedComponentTemplate.name)}}function BuilderComponent_Conditional_0_Conditional_36_Conditional_2_Template(rf,ctx){if(rf&1){let _r7=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-page-component-properties",31),\u0275\u0275listener("update",function($event){\u0275\u0275restoreView(_r7);let ctx_r1=\u0275\u0275nextContext(3);return \u0275\u0275resetView(ctx_r1.updateComponent($event))}),\u0275\u0275elementEnd()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275property("component",ctx_r1.selectedComponent)("template",ctx_r1.selectedComponentTemplate)}}function BuilderComponent_Conditional_0_Conditional_36_Template(rf,ctx){if(rf&1&&(\u0275\u0275conditionalCreate(0,BuilderComponent_Conditional_0_Conditional_36_Conditional_0_Template,7,1,"mat-toolbar"),\u0275\u0275elementStart(1,"div",17),\u0275\u0275conditionalCreate(2,BuilderComponent_Conditional_0_Conditional_36_Conditional_2_Template,1,2,"ix-page-component-properties",29),\u0275\u0275elementEnd()),rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275conditional(ctx_r1.selectedComponentTemplate!=null&&ctx_r1.selectedComponentTemplate.name?0:-1),\u0275\u0275advance(2),\u0275\u0275conditional(ctx_r1.selectedComponent?2:-1)}}function BuilderComponent_Conditional_0_Conditional_37_Template(rf,ctx){if(rf&1){let _r8=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",30),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r8);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.toggleDrawerLock())}),\u0275\u0275elementStart(1,"mat-icon"),\u0275\u0275text(2,"keyboard_arrow_left"),\u0275\u0275elementEnd()()}}function BuilderComponent_Conditional_0_Case_39_Template(rf,ctx){if(rf&1&&\u0275\u0275elementContainer(0,21),rf&2){\u0275\u0275nextContext();let standaloneContent_r9=\u0275\u0275reference(42);\u0275\u0275property("ngTemplateOutlet",standaloneContent_r9)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_1_Template(rf,ctx){if(rf&1){let _r10=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-component-grid",38),\u0275\u0275listener("selectionChange",function($event){\u0275\u0275restoreView(_r10);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.handleSelectionChange($event))})("componentChanges",function($event){\u0275\u0275restoreView(_r10);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.handleComponentChanges($event))})("movingGridItem",function($event){\u0275\u0275restoreView(_r10);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.setDrawerIsOpen($event))}),\u0275\u0275elementEnd()}if(rf&2){let pageVersion_r11=\u0275\u0275nextContext(3),ctx_r1=\u0275\u0275nextContext();\u0275\u0275classProp("desktop",ctx_r1.previewMode!=="mobile")("mobile",ctx_r1.previewMode==="mobile"),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(pageVersion_r11.previewAgent==null?null:pageVersion_r11.previewAgent.publicId)||(pageVersion_r11.previewAsset==null?null:pageVersion_r11.previewAsset.publicId)||null)("mobile",ctx_r1.previewMode==="mobile")("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)("selectedComponentId",(ctx_r1.selectedComponent==null?null:ctx_r1.selectedComponent.publicId)||null)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_2_Template(rf,ctx){if(rf&1){let _r12=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-card-component-grid",39),\u0275\u0275listener("componentResize",function($event){\u0275\u0275restoreView(_r12);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.updateComponentSize($event))})("selectionChange",function($event){\u0275\u0275restoreView(_r12);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.handleSelectionChange($event))}),\u0275\u0275elementEnd()}if(rf&2){let pageVersion_r11=\u0275\u0275nextContext(3),ctx_r1=\u0275\u0275nextContext();\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(ctx_r1.previewAgentOrAsset==null?null:ctx_r1.previewAgentOrAsset.publicId)??null)("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)("selectedComponentId",(ctx_r1.selectedComponent==null?null:ctx_r1.selectedComponent.publicId)??null)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_3_ix_component_grid_0_Template(rf,ctx){if(rf&1){let _r13=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-component-grid",41),\u0275\u0275listener("selectionChange",function($event){\u0275\u0275restoreView(_r13);let ctx_r1=\u0275\u0275nextContext(5);return \u0275\u0275resetView(ctx_r1.handleSelectionChange($event))})("componentChanges",function($event){\u0275\u0275restoreView(_r13);let ctx_r1=\u0275\u0275nextContext(5);return \u0275\u0275resetView(ctx_r1.handleComponentChanges($event))})("movingGridItem",function($event){\u0275\u0275restoreView(_r13);let ctx_r1=\u0275\u0275nextContext(5);return \u0275\u0275resetView(ctx_r1.setDrawerIsOpen($event))}),\u0275\u0275elementEnd()}if(rf&2){let pageVersion_r11=\u0275\u0275nextContext(4),ctx_r1=\u0275\u0275nextContext();\u0275\u0275classMap(ctx_r1.orientation),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(pageVersion_r11.previewAgent==null?null:pageVersion_r11.previewAgent.publicId)||(pageVersion_r11.previewAsset==null?null:pageVersion_r11.previewAsset.publicId)||null)("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)("selectedComponentId",(ctx_r1.selectedComponent==null?null:ctx_r1.selectedComponent.publicId)??null)("orientation",ctx_r1.orientation)("mobile",!1)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_3_Template(rf,ctx){if(rf&1&&\u0275\u0275template(0,BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_3_ix_component_grid_0_Template,1,9,"ix-component-grid",40),rf&2){let ctx_r1=\u0275\u0275nextContext(4);\u0275\u0275property("ixReloadOnValueChange",ctx_r1.orientation)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",34),\u0275\u0275conditionalCreate(1,BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_1_Template,1,10,"ix-component-grid",35),\u0275\u0275conditionalCreate(2,BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_2_Template,1,5,"ix-card-component-grid",36),\u0275\u0275conditionalCreate(3,BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_3_Template,1,1,"ix-component-grid",37),\u0275\u0275elementEnd()),rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275classMap(ctx_r1.gridClasses),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="sheet"?1:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="card"?2:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="report"?3:-1)}}function BuilderComponent_Conditional_0_Case_40_Conditional_1_Conditional_1_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",43),\u0275\u0275element(1,"ix-simple-component-grid",45),\u0275\u0275elementEnd()),rf&2){let pageVersion_r11=\u0275\u0275nextContext(3),ctx_r1=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275classMap(ctx_r1.previewMode),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(pageVersion_r11.previewAgent==null?null:pageVersion_r11.previewAgent.publicId)||(pageVersion_r11.previewAsset==null?null:pageVersion_r11.previewAsset.publicId)||null)("mobile",ctx_r1.previewMode==="mobile")("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)}}function BuilderComponent_Conditional_0_Case_40_Conditional_1_Conditional_2_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",44),\u0275\u0275element(1,"ix-simple-card-component-grid",46),\u0275\u0275elementEnd()),rf&2){let pageVersion_r11=\u0275\u0275nextContext(3),ctx_r1=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(pageVersion_r11.previewAgent==null?null:pageVersion_r11.previewAgent.publicId)||(pageVersion_r11.previewAsset==null?null:pageVersion_r11.previewAsset.publicId)||null)("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)}}function BuilderComponent_Conditional_0_Case_40_Conditional_1_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",42),\u0275\u0275conditionalCreate(1,BuilderComponent_Conditional_0_Case_40_Conditional_1_Conditional_1_Template,2,7,"div",43),\u0275\u0275conditionalCreate(2,BuilderComponent_Conditional_0_Case_40_Conditional_1_Conditional_2_Template,2,4,"div",44),\u0275\u0275elementEnd()),rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275classMap(ctx_r1.applicationType),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="sheet"?1:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="card"?2:-1)}}function BuilderComponent_Conditional_0_Case_40_Template(rf,ctx){if(rf&1&&\u0275\u0275conditionalCreate(0,BuilderComponent_Conditional_0_Case_40_Conditional_0_Template,4,5,"div",32)(1,BuilderComponent_Conditional_0_Case_40_Conditional_1_Template,3,4,"div",33),rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275conditional(ctx_r1.mode==="edit"?0:1)}}function BuilderComponent_Conditional_0_ng_template_41_Conditional_0_ix_component_loader_2_Template(rf,ctx){if(rf&1&&\u0275\u0275element(0,"ix-component-loader",50),rf&2){let component_r15=\u0275\u0275nextContext();\u0275\u0275property("component",component_r15)}}function BuilderComponent_Conditional_0_ng_template_41_Conditional_0_Template(rf,ctx){if(rf&1){let _r14=\u0275\u0275getCurrentView();\u0275\u0275elementContainerStart(0,47),\u0275\u0275elementStart(1,"div",48),\u0275\u0275listener("click",function(){let component_r15=\u0275\u0275restoreView(_r14),ctx_r1=\u0275\u0275nextContext(3);return \u0275\u0275resetView(ctx_r1.handleSelectionChange(component_r15.publicId))}),\u0275\u0275template(2,BuilderComponent_Conditional_0_ng_template_41_Conditional_0_ix_component_loader_2_Template,1,1,"ix-component-loader",49),\u0275\u0275elementEnd(),\u0275\u0275elementContainerEnd()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope),\u0275\u0275advance(),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope),\u0275\u0275advance(),\u0275\u0275property("ixReloadOnValueChange",ctx)}}function BuilderComponent_Conditional_0_ng_template_41_Template(rf,ctx){if(rf&1&&(\u0275\u0275conditionalCreate(0,BuilderComponent_Conditional_0_ng_template_41_Conditional_0_Template,3,3,"ng-container",47),\u0275\u0275pipe(1,"async")),rf&2){let tmp_4_0,ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275conditional((tmp_4_0=\u0275\u0275pipeBind1(1,1,ctx_r1.component$))?0:-1,tmp_4_0)}}function BuilderComponent_Conditional_0_Template(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"div",1)(1,"mat-toolbar",2)(2,"h1"),\u0275\u0275text(3," Simulator "),\u0275\u0275conditionalCreate(4,BuilderComponent_Conditional_0_Conditional_4_Template,2,1,"span"),\u0275\u0275elementEnd(),\u0275\u0275element(5,"span",3),\u0275\u0275elementStart(6,"button",4)(7,"mat-icon"),\u0275\u0275text(8,"settings"),\u0275\u0275elementEnd()()(),\u0275\u0275elementStart(9,"mat-toolbar",5)(10,"ix-preview-device-select",6),\u0275\u0275pipe(11,"async"),\u0275\u0275listener("selectionChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.selectPreviewAgentOrAsset($event))})("mousedown",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementEnd(),\u0275\u0275element(12,"div",3),\u0275\u0275elementStart(13,"ix-period-controls",7),\u0275\u0275listener("periodSpecSelected",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.updateSelectedPeriodSpec($event))})("mousedown",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(14,BuilderComponent_Conditional_0_Conditional_14_Template,9,7,"ix-button-toggle-group",8),\u0275\u0275conditionalCreate(15,BuilderComponent_Conditional_0_Conditional_15_Template,9,7,"ix-button-toggle-group",9),\u0275\u0275conditionalCreate(16,BuilderComponent_Conditional_0_Conditional_16_Template,6,4,"button",10),\u0275\u0275elementStart(17,"ix-button-toggle-group",11),\u0275\u0275listener("mousedown",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementStart(18,"ix-button-toggle",12),\u0275\u0275pipe(19,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.setApplicationType($event))}),\u0275\u0275elementStart(20,"mat-icon"),\u0275\u0275text(21,"dashboard"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(22,"ix-button-toggle",13),\u0275\u0275pipe(23,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.setApplicationType($event))}),\u0275\u0275element(24,"mat-icon",14),\u0275\u0275elementEnd(),\u0275\u0275elementStart(25,"ix-button-toggle",15),\u0275\u0275pipe(26,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.setApplicationType($event))}),\u0275\u0275elementStart(27,"mat-icon"),\u0275\u0275text(28,"draft"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(29,"ix-button-toggle",16),\u0275\u0275pipe(30,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.setApplicationType($event))}),\u0275\u0275elementStart(31,"mat-icon"),\u0275\u0275text(32,"fit_screen"),\u0275\u0275elementEnd()()()(),\u0275\u0275elementStart(33,"div",17)(34,"mat-drawer-container")(35,"mat-drawer",18),\u0275\u0275conditionalCreate(36,BuilderComponent_Conditional_0_Conditional_36_Template,3,2)(37,BuilderComponent_Conditional_0_Conditional_37_Template,3,0,"button",19),\u0275\u0275elementEnd(),\u0275\u0275elementStart(38,"mat-drawer-content",20),\u0275\u0275conditionalCreate(39,BuilderComponent_Conditional_0_Case_39_Template,1,1,"ng-container",21)(40,BuilderComponent_Conditional_0_Case_40_Template,2,1),\u0275\u0275template(41,BuilderComponent_Conditional_0_ng_template_41_Template,2,3,"ng-template",null,0,\u0275\u0275templateRefExtractor),\u0275\u0275elementEnd()()()()}if(rf&2){let tmp_21_0,ctx_r1=\u0275\u0275nextContext();\u0275\u0275advance(4),\u0275\u0275conditional(ctx_r1.componentName?4:-1),\u0275\u0275advance(6),\u0275\u0275property("agentAndRootAssets",\u0275\u0275pipeBind1(11,21,ctx_r1.previewAgentsOrAssets$)??\u0275\u0275pureFunction0(31,_c021))("noneOption",\u0275\u0275pureFunction0(32,_c17))("value",(ctx_r1.previewAgentOrAsset==null?null:ctx_r1.previewAgentOrAsset.publicId)??""),\u0275\u0275advance(3),\u0275\u0275property("deviceTimeZone",null)("periodSpecs",ctx_r1.periodSpecs),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="sheet"?14:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="report"?15:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="sheet"||ctx_r1.applicationType==="card"?16:-1),\u0275\u0275advance(),\u0275\u0275property("value",ctx_r1.applicationType),\u0275\u0275advance(),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(19,23,"PAGE")),\u0275\u0275advance(4),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(23,25,"CARD")),\u0275\u0275advance(3),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(26,27,"REPORT")),\u0275\u0275advance(4),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(30,29,"STANDALONE")),\u0275\u0275advance(6),\u0275\u0275classProp("locked-drawer",ctx_r1.drawerLockedClose)("open-drawer",ctx_r1.selectedComponent&&!ctx_r1.drawerLockedClose),\u0275\u0275property("opened",ctx_r1.selectedComponent&&ctx_r1.drawerIsOpen&&ctx_r1.mode==="edit"),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.selectedComponent&&!ctx_r1.drawerLockedClose?36:37),\u0275\u0275advance(3),\u0275\u0275conditional((tmp_21_0=ctx_r1.applicationType)==="standalone"?39:40)}}var BuilderComponent=(()=>{class BuilderComponent2{constructor(){this.activePeriodSpec=inject(ActivePeriodSpec),this.cdRef=inject(ChangeDetectorRef),this.destroy=inject(DestroyRef),this.facade=inject(BuilderFacade),this.sessionStorage=inject(SESSION_STORAGE),this.applicationType=this.sessionStorage.getItem("application-type")||"sheet",this.orientation=this.sessionStorage.getItem("orientation")||"portrait",this.drawerLockedClose=!1,this.gridScope="simulator",this.mode=this.sessionStorage.getItem("mode")||"edit",this.previewMode=this.sessionStorage.getItem("preview-mode")||"desktop",this.drawerIsOpen=!0,this.selectedComponentId$=new BehaviorSubject(null),this.busyUpdating$=this.facade.busyUpdating$,this.component$=this.facade.getComponent(this.pageId),this.pageVersion$=this.facade.draftVersionByPageId(this.pageId),this.previewAgentsOrAssets$=this.facade.previewAgentsOrAssets$,this.previewAgentOrAsset$=this.facade.previewAgentOrAsset(this.pageVersion$)}get gridClasses(){return this.previewMode==="mobile"?["mobile"]:[]}get pageId(){return"page"}ngOnInit(){this.pageVersion$.pipe(takeUntilDestroyed(this.destroy)).subscribe(pageVersion=>{this.pageVersion=pageVersion,this.pageVersionId=pageVersion.publicId,pageVersion.previewAsset&&this.facade.loadOneAsset(pageVersion.previewAsset.publicId)}),this.facade.selectedPeriodSpec(of(this.pageId)).pipe(takeUntilDestroyed(this.destroy)).subscribe(periodSpec=>{this.periodSpecs=__spreadProps(__spreadValues({},this.periodSpecs),{selected:periodSpec}),this.activePeriodSpec.setPeriodSpec(periodSpec,this.gridScope),this.zoomOutIsVisible=this.getZoomOutIsVisible(),this.cdRef.markForCheck()}),this.activePeriodSpec.inScopeOf(this.gridScope).pipe(takeUntilDestroyed(this.destroy)).subscribe(periodSpec=>{this.periodSpecs=__spreadProps(__spreadValues({},this.periodSpecs),{active:periodSpec}),this.zoomOutIsVisible=this.getZoomOutIsVisible(),this.cdRef.markForCheck()}),this.selectedComponentId$.pipe(distinctUntilChanged(),switchMap(id=>combineLatest([this.facade.pageComponent(id),this.facade.pageComponentTemplate(id)])),takeUntilDestroyed(this.destroy)).subscribe(([component,template])=>{this.selectedComponent=component,this.selectedComponentTemplate=template,this.cdRef.markForCheck()}),this.previewAgentOrAsset$.pipe(takeUntilDestroyed(this.destroy)).subscribe(agentOrAsset=>{this.previewAgentOrAsset=agentOrAsset;let rootAssetId=agentOrAsset&&"root"in agentOrAsset?agentOrAsset.root?.publicId||agentOrAsset.publicId:void 0;this.facade.loadAssetsForRoot(rootAssetId),this.cdRef.markForCheck()}),this.facade.getComponentName(this.pageId).pipe(takeUntilDestroyed(this.destroy)).subscribe(name=>{this.componentName=name}),this.facade.loadAgents(),this.facade.loadRootAssets(),this.facade.loadCustomProperties(),this.facade.loadGroups(),this.facade.loadPageComponentTemplates(),this.facade.loadPage(this.pageId),this.facade.loadRoles(),this.destroy.onDestroy(()=>{this.facade.reset()})}handleSelectionChange(componentId){this.selectedComponentId$.next(componentId)}handleComponentChanges(components){let updates=components.reduce((acc,component)=>this.previewMode==="desktop"&&component.dimensions?.type==="sheet"?[...acc,pick_default(component,["publicId","dimensions.type","dimensions.left","dimensions.top","dimensions.rows","dimensions.cols"])]:this.previewMode==="mobile"&&component.dimensions?.type==="sheet"?[...acc,pick_default(component,["publicId","dimensions.type","dimensions.mobileCols","dimensions.mobileHeight","dimensions.mobileLeft","dimensions.mobileOrder"])]:component.dimensions?.type==="report"?[...acc,pick_default(component,["publicId","dimensions.type","dimensions.left","dimensions.top","dimensions.rows","dimensions.cols"])]:acc,[]);updates.length>0&&(updates.length===1?this.facade.updateComponent(updates[0].publicId,omit_default(updates[0],["publicId"])):this.facade.updateComponentList(updates))}updateComponent(component){this.facade.updateComponent(component.publicId,omit_default(component,["publicId"]))}updateComponentSize({componentId,height}){this.facade.updateComponent(componentId,{dimensions:{type:"card",height}})}selectPreviewAgentOrAsset(publicId){this.previewAgentOrAsset?.publicId!==publicId&&this.facade.updatePreviewAgentOrAsset(this.pageVersionId,publicId==="none"?null:publicId)}setApplicationType(newApplicationType){this.applicationType=newApplicationType,this.sessionStorage.setItem("application-type",newApplicationType),this.facade.reloadDimensions(this.pageId,newApplicationType),this.facade.updateApplicationType(this.pageId,newApplicationType);let mode=null,remember=!0;switch(newApplicationType){case"report":mode="edit",remember=!1;break;case"standalone":mode="preview",remember=!1;break}mode||(mode=this.sessionStorage.getItem("mode")||null),mode&&this.setMode(mode,remember)}setPreviewMode(newPreviewMode){this.previewMode=newPreviewMode,this.sessionStorage.setItem("preview-mode",newPreviewMode)}setOrientation(newOrientation){this.orientation=newOrientation,this.sessionStorage.setItem("orientation",newOrientation);let component=this.pageVersion.components?.[0];component?.dimensions?.type==="report"&&this.facade.updateComponent(component.publicId,{dimensions:__spreadProps(__spreadValues({},component.dimensions),{type:"report",left:0,top:3,cols:newOrientation==="landscape"?8:6,rows:6})})}getZoomOutIsVisible(){return this.periodSpecs?!isEqual_default(this.periodSpecs.active,this.periodSpecs.selected):!1}setMode(newMode,rememberMode=!0){this.mode=newMode,rememberMode&&this.sessionStorage.setItem("mode",newMode)}setDrawerIsOpen(gridItemIsMoving){this.drawerIsOpen=!gridItemIsMoving}toggleDrawerLock(){this.drawerLockedClose=!this.drawerLockedClose}toggleMode(){this.setMode(this.mode==="preview"?"edit":"preview")}updateSelectedPeriodSpec(periodSpec){this.facade.updateSelectedPeriodSpec(periodSpec)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||BuilderComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:BuilderComponent2,selectors:[["ix-builder"]],viewQuery:function(rf,ctx){if(rf&1&&\u0275\u0275viewQuery(ComponentGridComponent,5),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.componentGrid=_t.first)}},decls:2,vars:3,consts:[["standaloneContent",""],["fxFlex","","fxLayout","column",1,"ix-surface"],["ixComponentGridFocus",""],["fxFlex",""],["mat-icon-button","","routerLink","/settings","matTooltip","Settings"],["ixComponentGridFocus","",1,"second"],[3,"selectionChange","mousedown","agentAndRootAssets","noneOption","value"],[3,"periodSpecSelected","mousedown","deviceTimeZone","periodSpecs"],[1,"screen-toggle-group",3,"value"],[1,"orientation-toggle-group",3,"value"],["mat-stroked-button","","type","button",1,"mode-button"],[1,"application-type-toggle-group",3,"mousedown","value"],["value","sheet",3,"valueChange","matTooltip"],["value","card",3,"valueChange","matTooltip"],["svgIcon","card_outline"],["value","report",3,"valueChange","matTooltip"],["value","standalone",3,"valueChange","matTooltip"],["fxFlex","",1,"ix-content"],["mode","over","position","end",3,"opened"],["mat-icon-button","","disableRipple","true"],["fxLayout","column"],[3,"ngTemplateOutlet"],[1,"screen-toggle-group",3,"mousedown","value"],["value","desktop",3,"valueChange","matTooltip"],["value","mobile",3,"valueChange","matTooltip"],[1,"orientation-toggle-group",3,"mousedown","value"],["value","portrait",3,"valueChange","matTooltip"],["value","landscape",3,"valueChange","matTooltip"],["mat-stroked-button","","type","button",1,"mode-button",3,"click","mousedown"],[3,"component","template"],["mat-icon-button","","disableRipple","true",3,"click"],[3,"update","component","template"],["ixComponentGridFocus","",1,"grid-container",3,"class"],[1,"preview-grid-container",3,"class"],["ixComponentGridFocus","",1,"grid-container"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage",3,"ixComponentGridScope","agentOrAssetId","mobile","pageId","pageVersionId","selectedComponentId","desktop"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","","ixComponentGridMode","edit","pagePageId","pagepage",3,"ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage","applicationType","report",1,"report-grid","mat-elevation-z2",3,"ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId","class","orientation","mobile"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage",3,"selectionChange","componentChanges","movingGridItem","ixComponentGridScope","agentOrAssetId","mobile","pageId","pageVersionId","selectedComponentId"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","","ixComponentGridMode","edit","pagePageId","pagepage",3,"componentResize","selectionChange","ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage","class","report-grid mat-elevation-z2","applicationType","report",3,"ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId","class","orientation","mobile","selectionChange","componentChanges","movingGridItem",4,"ixReloadOnValueChange"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage","applicationType","report",1,"report-grid","mat-elevation-z2",3,"selectionChange","componentChanges","movingGridItem","ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId","orientation","mobile"],[1,"preview-grid-container"],[1,"ix-large-section","preview"],[1,"preview"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","","ixComponentGridMode","view",3,"ixComponentGridScope","agentOrAssetId","mobile","pageId","pageVersionId"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","","ixComponentGridMode","view",3,"ixComponentGridScope","agentOrAssetId","pageId","pageVersionId"],[3,"ixComponentGridScope"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","",1,"standalone",3,"click","ixComponentGridScope"],[3,"component",4,"ixReloadOnValueChange"],[3,"component"]],template:function(rf,ctx){if(rf&1&&(\u0275\u0275conditionalCreate(0,BuilderComponent_Conditional_0_Template,43,33,"div",1),\u0275\u0275pipe(1,"async")),rf&2){let tmp_0_0;\u0275\u0275conditional((tmp_0_0=\u0275\u0275pipeBind1(1,1,ctx.pageVersion$))?0:-1,tmp_0_0)}},dependencies:[AlertDialogModule,ButtonToggleModule,ButtonToggleComponent,ButtonToggleGroupComponent,ComponentLoaderModule,ComponentLoaderComponent,PreviewDeviceSelectComponent,FlexModule,DefaultLayoutDirective,DefaultFlexDirective,MatButtonModule,MatButton,MatIconButton,MatFormFieldModule,MatIconModule,MatIcon,MatInputModule,MatSidenavModule,MatDrawer,MatDrawerContainer,MatDrawerContent,MatToolbarModule,MatToolbar,MatTooltipModule,MatTooltip,NgTemplateOutlet,PagesModule,ComponentGridComponent,CardComponentGridComponent,SimpleComponentGridComponent,SimpleCardComponentGridComponent,ComponentPropertiesComponent,ComponentGridModeDirective,ComponentGridScopeDirective,ComponentContextCleanupDirective,BackendComponentBrokerDirective,LoggingDataBrokerDirective,ObjectStorageBrokerDirective,ResourceDataBrokerDirective,PeriodControlsComponent,ComponentGridFocusDirective,PeriodFieldsetModule,ReloadOnValueChangeDirective,RouterModule,RouterLink,TranslateModule,AsyncPipe,TranslatePipe],styles:['[_nghost-%COMP%]{height:100%;width:100%}[_nghost-%COMP%] .mat-toolbar[_ngcontent-%COMP%]{border-bottom:1px solid var(--mat-sys-surface-variant)}[_nghost-%COMP%] .mat-toolbar[_ngcontent-%COMP%] h1[_ngcontent-%COMP%]{padding-right:16px}[_nghost-%COMP%] .mat-toolbar[_ngcontent-%COMP%] ix-device-select-button[_ngcontent-%COMP%]{margin-right:8px;max-width:calc(100% - 340px)}[_nghost-%COMP%] .mat-toolbar.second[_ngcontent-%COMP%]{--mat-toolbar-standard-height: 56px;--mat-button-outlined-container-height: 36px;border-bottom:1px solid var(--mat-sys-surface-variant)}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%]{height:100%}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer-backdrop{display:none}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%]{height:100%;width:300px;border-left:1px solid var(--mat-sys-surface-variant)}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%] .mat-drawer-inner-container{height:100%;flex-direction:column}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%] .mat-drawer-inner-container>.mat-toolbar{height:40px!important}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%] .mat-drawer-inner-container>.mat-toolbar h1{color:var(--body-color);font-size:16px;font-weight:400}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer.locked-drawer[_ngcontent-%COMP%]{--mat-sidenav-container-elevation-shadow: 0px 8px 10px -5px rgb(0 0 0 / 20%), 0px 16px 24px 2px rgb(0 0 0 / 14%), 0px 6px 30px 5px rgb(0 0 0 / 12%);width:50px;height:40px;border-top-left-radius:25px;border-bottom-left-radius:25px;border-left:none}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%] .mat-mdc-icon-button[_ngcontent-%COMP%] .mat-mdc-button-focus-overlay{display:none}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%]{height:100%;overflow-x:auto;background-color:#f5f5f5}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] .grid[_ngcontent-%COMP%]{height:100%}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{margin:0 auto;height:100%}@media (min-width: 960px){[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{max-width:970px}}@media (min-width: 1280px){[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{max-width:1200px}}@media (min-width: 1920px){[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{max-width:1600px}}@media screen and (min-width: 2251px){[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{max-width:2000px}}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid.desktop[_ngcontent-%COMP%]{min-width:970px}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid.mobile[_ngcontent-%COMP%]{max-width:480px}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%]{height:100%;width:100%;box-sizing:border-box;overflow-x:auto;display:flex;flex-direction:column;background-color:var(--detail-page-bg);--uic-color-scheme: var(--card-color-scheme);--uic-background: var(--card-bg);--uic-on-background: var(--card-color)}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container.card[_ngcontent-%COMP%]{place-content:center}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container.card[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%]{display:flex;place-items:center}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%]{height:100%}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%] ix-simple-component-grid[_ngcontent-%COMP%]{height:100%;box-sizing:border-box;margin:0 auto}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%] ix-simple-component-grid.desktop[_ngcontent-%COMP%]{min-width:970px}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%] ix-simple-component-grid.mobile[_ngcontent-%COMP%]{max-width:480px;border-left:1px solid rgba(0,0,0,.08);border-right:1px solid rgba(0,0,0,.08)}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%] ix-simple-card-component-grid[_ngcontent-%COMP%]{width:300px;padding:0;margin:0 auto;box-sizing:border-box;background-color:var(--card-bg);color:var(--card-color);color-scheme:var(--card-color-scheme);border:var(--card-border-width) solid var(--card-border-color);border-radius:8px}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .standalone[_ngcontent-%COMP%]{height:100%}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .standalone[_ngcontent-%COMP%] ix-component-loader[_ngcontent-%COMP%]{overflow:auto}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] ix-page-properties[_ngcontent-%COMP%]{padding:20px 16px}[_nghost-%COMP%] .select-button[_ngcontent-%COMP%]{padding-left:8px;padding-right:2px;margin-right:8px}[_nghost-%COMP%] .select-button[_ngcontent-%COMP%] .mat-icon[_ngcontent-%COMP%]:first-child{margin-right:6px}[_nghost-%COMP%] .screen-toggle-group[_ngcontent-%COMP%], [_nghost-%COMP%] .orientation-toggle-group[_ngcontent-%COMP%], [_nghost-%COMP%] .application-type-toggle-group[_ngcontent-%COMP%]{margin-left:12px}[_nghost-%COMP%] .mode-button[_ngcontent-%COMP%]{margin-left:12px}[_nghost-%COMP%] .mode-button[_ngcontent-%COMP%] .mat-icon[_ngcontent-%COMP%]:first-child{margin-right:6px}[_nghost-%COMP%] .report-grid[_ngcontent-%COMP%]{--card-bg: #fff;--card-border-color: rgb(0 0 0 / 12%);--card-border-width: 1px;--card-color: rgb(0 0 0 / 87%);--card-color-scheme: "light";--uic-color-scheme: var(--card-color-scheme);--uic-background: var(--card-bg);--uic-on-background: var(--card-color);margin:16px auto!important;background:#fff;height:842pt!important;width:595pt}[_nghost-%COMP%] .report-grid.landscape[_ngcontent-%COMP%]{height:595pt!important;width:842pt}[_nghost-%COMP%] .report-grid[_ngcontent-%COMP%] .canvas gridster .gridster-row{width:calc(100% - 76px)!important}[_nghost-%COMP%] .report-grid[_ngcontent-%COMP%] .gridster-column, [_nghost-%COMP%] .report-grid[_ngcontent-%COMP%] .gridster-row{border-color:#00000014}'],changeDetection:0})}}return BuilderComponent2})();var BuilderGuard=(()=>{class BuilderGuard2{constructor(){this.store=inject(Store)}canActivate(){return forkJoin([this.getMyUser(),this.getMyCompany()]).pipe(map(()=>!0),take(1))}getMyUser(){return this._loadIfAbsent(selectMyUser,loadMe3())}getMyCompany(){return this._loadIfAbsent(selectMyCompany,loadMe())}_loadIfAbsent(selector3,action){return this.store.select(selector3).pipe(tap(entity=>{entity||this.store.dispatch(action)}),first(entity=>!!entity),map(()=>!0))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||BuilderGuard2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:BuilderGuard2,factory:BuilderGuard2.\u0275fac,providedIn:"root"})}}return BuilderGuard2})();var LoginExpiredComponent=(()=>{class LoginExpiredComponent3{constructor(){this.document=inject(DOCUMENT),this.storage=inject(StorageService)}useMockData(){this.storage.forget("api-data-provider"),this.storage.forget("company"),this.reload()}reload(){this.document.location.href="/"}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LoginExpiredComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:LoginExpiredComponent3,selectors:[["ix-login-expired"]],standalone:!1,decls:18,vars:0,consts:[["fxFlex","","fxLayout","column","fxLayoutAlign","center center",1,"ix-surface"],[1,"ix-status-card"],[1,"ix-status-card__icon"],["type","button","mat-button","","color","primary",3,"click"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"div",0)(1,"mat-card",1)(2,"div",2)(3,"mat-icon"),\u0275\u0275text(4,"error"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"mat-card-header")(6,"mat-card-title"),\u0275\u0275text(7,"Login expired"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(8,"mat-card-subtitle"),\u0275\u0275text(9," Please re-authenticate via the command line "),\u0275\u0275elementStart(10,"pre"),\u0275\u0275text(11,"npx cdk login"),\u0275\u0275elementEnd(),\u0275\u0275text(12," and reload or revert to using API mock data. "),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(13,"mat-card-actions")(14,"button",3),\u0275\u0275listener("click",function(){return ctx.useMockData()}),\u0275\u0275text(15,"Use mock data"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(16,"button",3),\u0275\u0275listener("click",function(){return ctx.reload()}),\u0275\u0275text(17,"Reload"),\u0275\u0275elementEnd()()()())},dependencies:[DefaultLayoutDirective,DefaultLayoutAlignDirective,DefaultFlexDirective,MatButton,MatCard,MatCardActions,MatCardHeader,MatCardSubtitle,MatCardTitle,MatIcon],styles:["[_nghost-%COMP%]{width:100%;height:100%}"],changeDetection:0})}}return LoginExpiredComponent3})();var LoginExpiredCanActivateGuard=(()=>{class LoginExpiredCanActivateGuard2{constructor(){this.router=inject(Router),this.storage=inject(StorageService)}canActivate(route){return this.isAuthenticated(route)}isAuthenticated(route){return of(this.storage.has("auth")).pipe(tap(authenticated=>{if(authenticated)if(route.queryParamMap.has("next")){let next=route.queryParams.next;this.router.navigateByUrl(next).then(success=>{success||this.router.navigate(["/"])})}else this.router.navigate(["/"])}),map(authenticated=>!authenticated))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LoginExpiredCanActivateGuard2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:LoginExpiredCanActivateGuard2,factory:LoginExpiredCanActivateGuard2.\u0275fac,providedIn:"root"})}}return LoginExpiredCanActivateGuard2})();var LoginExpiredModule=(()=>{class LoginExpiredModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LoginExpiredModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:LoginExpiredModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[SharedModule]})}}return LoginExpiredModule2})();var ManifestInvalidComponent=(()=>{class ManifestInvalidComponent3{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ManifestInvalidComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ManifestInvalidComponent3,selectors:[["ix-manifest-invalid"]],standalone:!1,decls:13,vars:0,consts:[["fxFlex","","fxLayout","column","fxLayoutAlign","center center",1,"ix-surface"],[1,"ix-status-card"],[1,"ix-status-card__icon"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"div",0)(1,"mat-card",1)(2,"div",2)(3,"mat-icon"),\u0275\u0275text(4,"error"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"mat-card-header")(6,"mat-card-title"),\u0275\u0275text(7,"Manifest invalid"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(8,"mat-card-subtitle"),\u0275\u0275text(9," Schema validation for the "),\u0275\u0275elementStart(10,"pre"),\u0275\u0275text(11,"manifest.json"),\u0275\u0275elementEnd(),\u0275\u0275text(12," file failed. "),\u0275\u0275elementEnd()()()())},dependencies:[DefaultLayoutDirective,DefaultLayoutAlignDirective,DefaultFlexDirective,MatCard,MatCardHeader,MatCardSubtitle,MatCardTitle,MatIcon],styles:["[_nghost-%COMP%]{width:100%;height:100%}"],changeDetection:0})}}return ManifestInvalidComponent3})();var TwoFactorAuthRequiredComponent=(()=>{class TwoFactorAuthRequiredComponent2{constructor(){this.document=inject(DOCUMENT),this.storage=inject(StorageService)}switchCompany(){this.storage.forget("api-data-provider"),this.storage.forget("company"),this.document.location.href="/settings/general"}useMockData(){this.storage.forget("api-data-provider"),this.storage.forget("company"),this.document.location.href="/"}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||TwoFactorAuthRequiredComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:TwoFactorAuthRequiredComponent2,selectors:[["ix-two-factor-auth-required"]],decls:13,vars:0,consts:[["fxFlex","","fxLayout","column","fxLayoutAlign","center center",1,"ix-surface"],[1,"ix-status-card"],[1,"ix-status-card__icon"],["type","button","mat-button","","color","primary",3,"click"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"div",0)(1,"mat-card",1)(2,"div",2)(3,"mat-icon"),\u0275\u0275text(4,"error"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"mat-card-header")(6,"mat-card-title"),\u0275\u0275text(7,"Two-factor authentication is required"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(8,"mat-card-actions")(9,"button",3),\u0275\u0275listener("click",function(){return ctx.useMockData()}),\u0275\u0275text(10,"Use mock data"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(11,"button",3),\u0275\u0275listener("click",function(){return ctx.switchCompany()}),\u0275\u0275text(12,"Switch company"),\u0275\u0275elementEnd()()()())},dependencies:[FlexModule,DefaultLayoutDirective,DefaultLayoutAlignDirective,DefaultFlexDirective,MatButtonModule,MatButton,MatCardModule,MatCard,MatCardActions,MatCardHeader,MatCardTitle,MatIconModule,MatIcon],styles:["[_nghost-%COMP%]{width:100%;height:100%}"],changeDetection:0})}}return TwoFactorAuthRequiredComponent2})();var routes=[{path:"",canActivate:[AppGuard],children:[{path:"",component:BuilderComponent,canActivate:__use_api_mocks__?[BuilderGuard]:[AuthCompanyGuard,BuilderGuard]},{path:"settings",loadChildren:()=>import("./chunk-AKQNOKY6.js").then(m=>m.SettingsModule)},...__use_api_mocks__?[]:[{path:"login",component:LoginExpiredComponent,canActivate:[LoginExpiredCanActivateGuard]},{path:"my-companies",redirectTo:"settings"},{path:"two-factor-auth-required",component:TwoFactorAuthRequiredComponent}]]},{path:"manifest-invalid",component:ManifestInvalidComponent},{path:"**",redirectTo:""}];var AppRoutingConfig={routerState:RouterState?.Minimal,serializer:CustomRouterStateSerializer};var AppRoutingModule=(()=>{class AppRoutingModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||AppRoutingModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:AppRoutingModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[RouterModule.forRoot(routes,{bindToComponentInputs:!0,onSameUrlNavigation:"reload",preloadingStrategy:CustomPreloadingStrategy}),StoreRouterConnectingModule.forRoot(AppRoutingConfig),RouterModule]})}}return AppRoutingModule2})();var PERFORM_ACTION="PERFORM_ACTION",REFRESH="REFRESH",RESET="RESET",ROLLBACK="ROLLBACK",COMMIT="COMMIT",SWEEP="SWEEP",TOGGLE_ACTION="TOGGLE_ACTION",SET_ACTIONS_ACTIVE="SET_ACTIONS_ACTIVE",JUMP_TO_STATE="JUMP_TO_STATE",JUMP_TO_ACTION="JUMP_TO_ACTION",IMPORT_STATE="IMPORT_STATE",LOCK_CHANGES="LOCK_CHANGES",PAUSE_RECORDING="PAUSE_RECORDING",PerformAction=class{constructor(action,timestamp2){if(this.action=action,this.timestamp=timestamp2,this.type=PERFORM_ACTION,typeof action.type>"u")throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?')}},Refresh=class{constructor(){this.type=REFRESH}},Reset=class{constructor(timestamp2){this.timestamp=timestamp2,this.type=RESET}},Rollback=class{constructor(timestamp2){this.timestamp=timestamp2,this.type=ROLLBACK}},Commit=class{constructor(timestamp2){this.timestamp=timestamp2,this.type=COMMIT}},Sweep=class{constructor(){this.type=SWEEP}},ToggleAction=class{constructor(id){this.id=id,this.type=TOGGLE_ACTION}};var JumpToState=class{constructor(index){this.index=index,this.type=JUMP_TO_STATE}},JumpToAction=class{constructor(actionId){this.actionId=actionId,this.type=JUMP_TO_ACTION}},ImportState=class{constructor(nextLiftedState){this.nextLiftedState=nextLiftedState,this.type=IMPORT_STATE}},LockChanges=class{constructor(status){this.status=status,this.type=LOCK_CHANGES}},PauseRecording=class{constructor(status){this.status=status,this.type=PAUSE_RECORDING}};var STORE_DEVTOOLS_CONFIG=new InjectionToken("@ngrx/store-devtools Options"),INITIAL_OPTIONS=new InjectionToken("@ngrx/store-devtools Initial Config");function noMonitor(){return null}var DEFAULT_NAME="NgRx Store DevTools";function createConfig(optionsInput){let DEFAULT_OPTIONS2={maxAge:!1,monitor:noMonitor,actionSanitizer:void 0,stateSanitizer:void 0,name:DEFAULT_NAME,serialize:!1,logOnly:!1,autoPause:!1,trace:!1,traceLimit:75,features:{pause:!0,lock:!0,persist:!0,export:!0,import:"custom",jump:!0,skip:!0,reorder:!0,dispatch:!0,test:!0},connectInZone:!1},options=typeof optionsInput=="function"?optionsInput():optionsInput,logOnly=options.logOnly?{pause:!0,export:!0,test:!0}:!1,features2=options.features||logOnly||DEFAULT_OPTIONS2.features;features2.import===!0&&(features2.import="custom");let config3=Object.assign({},DEFAULT_OPTIONS2,{features:features2},options);if(config3.maxAge&&config3.maxAge<2)throw new Error(`Devtools 'maxAge' cannot be less than 2, got ${config3.maxAge}`);return config3}function difference(first2,second){return first2.filter(item=>second.indexOf(item)<0)}function unliftState(liftedState){let{computedStates,currentStateIndex}=liftedState;if(currentStateIndex>=computedStates.length){let{state:state2}=computedStates[computedStates.length-1];return state2}let{state}=computedStates[currentStateIndex];return state}function liftAction(action){return new PerformAction(action,+Date.now())}function sanitizeActions(actionSanitizer,actions){return Object.keys(actions).reduce((sanitizedActions,actionIdx)=>{let idx=Number(actionIdx);return sanitizedActions[idx]=sanitizeAction(actionSanitizer,actions[idx],idx),sanitizedActions},{})}function sanitizeAction(actionSanitizer,action,actionIdx){return __spreadProps(__spreadValues({},action),{action:actionSanitizer(action.action,actionIdx)})}function sanitizeStates(stateSanitizer,states){return states.map((computedState,idx)=>({state:sanitizeState(stateSanitizer,computedState.state,idx),error:computedState.error}))}function sanitizeState(stateSanitizer,state,stateIdx){return stateSanitizer(state,stateIdx)}function shouldFilterActions(config3){return config3.predicate||config3.actionsSafelist||config3.actionsBlocklist}function filterLiftedState(liftedState,predicate,safelist,blocklist){let filteredStagedActionIds=[],filteredActionsById={},filteredComputedStates=[];return liftedState.stagedActionIds.forEach((id,idx)=>{let liftedAction=liftedState.actionsById[id];liftedAction&&(idx&&isActionFiltered(liftedState.computedStates[idx],liftedAction,predicate,safelist,blocklist)||(filteredActionsById[id]=liftedAction,filteredStagedActionIds.push(id),filteredComputedStates.push(liftedState.computedStates[idx])))}),__spreadProps(__spreadValues({},liftedState),{stagedActionIds:filteredStagedActionIds,actionsById:filteredActionsById,computedStates:filteredComputedStates})}function isActionFiltered(state,action,predicate,safelist,blockedlist){let predicateMatch=predicate&&!predicate(state,action.action),safelistMatch=safelist&&!action.action.type.match(safelist.map(s2=>escapeRegExp(s2)).join("|")),blocklistMatch=blockedlist&&action.action.type.match(blockedlist.map(s2=>escapeRegExp(s2)).join("|"));return predicateMatch||safelistMatch||blocklistMatch}function escapeRegExp(s2){return s2.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function injectZoneConfig(connectInZone){return{ngZone:connectInZone?inject(NgZone):null,connectInZone}}var DevtoolsDispatcher=(()=>{class DevtoolsDispatcher2 extends ActionsSubject{static{this.\u0275fac=(()=>{let \u0275DevtoolsDispatcher_BaseFactory;return function(__ngFactoryType__){return(\u0275DevtoolsDispatcher_BaseFactory||(\u0275DevtoolsDispatcher_BaseFactory=\u0275\u0275getInheritedFactory(DevtoolsDispatcher2)))(__ngFactoryType__||DevtoolsDispatcher2)}})()}static{this.\u0275prov=\u0275\u0275defineInjectable({token:DevtoolsDispatcher2,factory:DevtoolsDispatcher2.\u0275fac})}}return DevtoolsDispatcher2})(),ExtensionActionTypes={START:"START",DISPATCH:"DISPATCH",STOP:"STOP",ACTION:"ACTION"},REDUX_DEVTOOLS_EXTENSION=new InjectionToken("@ngrx/store-devtools Redux Devtools Extension"),DevtoolsExtension=(()=>{class DevtoolsExtension2{constructor(devtoolsExtension,config3,dispatcher){this.config=config3,this.dispatcher=dispatcher,this.zoneConfig=injectZoneConfig(this.config.connectInZone),this.devtoolsExtension=devtoolsExtension,this.createActionStreams()}notify(action,state){if(this.devtoolsExtension)if(action.type===PERFORM_ACTION){if(state.isLocked||state.isPaused)return;let currentState=unliftState(state);if(shouldFilterActions(this.config)&&isActionFiltered(currentState,action,this.config.predicate,this.config.actionsSafelist,this.config.actionsBlocklist))return;let sanitizedState=this.config.stateSanitizer?sanitizeState(this.config.stateSanitizer,currentState,state.currentStateIndex):currentState,sanitizedAction=this.config.actionSanitizer?sanitizeAction(this.config.actionSanitizer,action,state.nextActionId):action;this.sendToReduxDevtools(()=>this.extensionConnection.send(sanitizedAction,sanitizedState))}else{let sanitizedLiftedState=__spreadProps(__spreadValues({},state),{stagedActionIds:state.stagedActionIds,actionsById:this.config.actionSanitizer?sanitizeActions(this.config.actionSanitizer,state.actionsById):state.actionsById,computedStates:this.config.stateSanitizer?sanitizeStates(this.config.stateSanitizer,state.computedStates):state.computedStates});this.sendToReduxDevtools(()=>this.devtoolsExtension.send(null,sanitizedLiftedState,this.getExtensionConfig(this.config)))}}createChangesObservable(){return this.devtoolsExtension?new Observable(subscriber=>{let connection=this.zoneConfig.connectInZone?this.zoneConfig.ngZone.runOutsideAngular(()=>this.devtoolsExtension.connect(this.getExtensionConfig(this.config))):this.devtoolsExtension.connect(this.getExtensionConfig(this.config));return this.extensionConnection=connection,connection.init(),connection.subscribe(change=>subscriber.next(change)),connection.unsubscribe}):EMPTY}createActionStreams(){let changes$=this.createChangesObservable().pipe(share()),start$=changes$.pipe(filter(change=>change.type===ExtensionActionTypes.START)),stop$=changes$.pipe(filter(change=>change.type===ExtensionActionTypes.STOP)),liftedActions$=changes$.pipe(filter(change=>change.type===ExtensionActionTypes.DISPATCH),map(change=>this.unwrapAction(change.payload)),concatMap(action=>action.type===IMPORT_STATE?this.dispatcher.pipe(filter(action2=>action2.type===UPDATE),timeout(1e3),debounceTime(1e3),map(()=>action),catchError(()=>of(action)),take(1)):of(action))),actionsUntilStop$=changes$.pipe(filter(change=>change.type===ExtensionActionTypes.ACTION),map(change=>this.unwrapAction(change.payload))).pipe(takeUntil(stop$)),liftedUntilStop$=liftedActions$.pipe(takeUntil(stop$));this.start$=start$.pipe(takeUntil(stop$)),this.actions$=this.start$.pipe(switchMap(()=>actionsUntilStop$)),this.liftedActions$=this.start$.pipe(switchMap(()=>liftedUntilStop$))}unwrapAction(action){return typeof action=="string"?(0,eval)(`(${action})`):action}getExtensionConfig(config3){let extensionOptions={name:config3.name,features:config3.features,serialize:config3.serialize,autoPause:config3.autoPause??!1,trace:config3.trace??!1,traceLimit:config3.traceLimit??75};return config3.maxAge!==!1&&(extensionOptions.maxAge=config3.maxAge),extensionOptions}sendToReduxDevtools(send){try{send()}catch(err){console.warn("@ngrx/store-devtools: something went wrong inside the redux devtools",err)}}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||DevtoolsExtension2)(\u0275\u0275inject(REDUX_DEVTOOLS_EXTENSION),\u0275\u0275inject(STORE_DEVTOOLS_CONFIG),\u0275\u0275inject(DevtoolsDispatcher))}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:DevtoolsExtension2,factory:DevtoolsExtension2.\u0275fac})}}return DevtoolsExtension2})(),INIT_ACTION={type:INIT},RECOMPUTE="@ngrx/store-devtools/recompute",RECOMPUTE_ACTION={type:RECOMPUTE};function computeNextEntry(reducer44,action,state,error3,errorHandler){if(error3)return{state,error:"Interrupted by an error up the chain"};let nextState=state,nextError;try{nextState=reducer44(state,action)}catch(err){nextError=err.toString(),errorHandler.handleError(err)}return{state:nextState,error:nextError}}function recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused){if(minInvalidatedStateIndex>=computedStates.length&&computedStates.length===stagedActionIds.length)return computedStates;let nextComputedStates=computedStates.slice(0,minInvalidatedStateIndex),lastIncludedActionId=stagedActionIds.length-(isPaused?1:0);for(let i=minInvalidatedStateIndex;i<lastIncludedActionId;i++){let actionId=stagedActionIds[i],action=actionsById[actionId].action,previousEntry=nextComputedStates[i-1],previousState=previousEntry?previousEntry.state:committedState,previousError=previousEntry?previousEntry.error:void 0,entry=skippedActionIds.indexOf(actionId)>-1?previousEntry:computeNextEntry(reducer44,action,previousState,previousError,errorHandler);nextComputedStates.push(entry)}return isPaused&&nextComputedStates.push(computedStates[computedStates.length-1]),nextComputedStates}function liftInitialState(initialCommittedState,monitorReducer){return{monitorState:monitorReducer(void 0,{}),nextActionId:1,actionsById:{0:liftAction(INIT_ACTION)},stagedActionIds:[0],skippedActionIds:[],committedState:initialCommittedState,currentStateIndex:0,computedStates:[],isLocked:!1,isPaused:!1}}function liftReducerWith(initialCommittedState,initialLiftedState,errorHandler,monitorReducer,options={}){return reducer44=>(liftedState,liftedAction)=>{let{monitorState,actionsById,nextActionId,stagedActionIds,skippedActionIds,committedState,currentStateIndex,computedStates,isLocked,isPaused}=liftedState||initialLiftedState;liftedState||(actionsById=Object.create(actionsById));function commitExcessActions(n2){let excess=n2,idsToDelete=stagedActionIds.slice(1,excess+1);for(let i=0;i<idsToDelete.length;i++)if(computedStates[i+1].error){excess=i,idsToDelete=stagedActionIds.slice(1,excess+1);break}else delete actionsById[idsToDelete[i]];skippedActionIds=skippedActionIds.filter(id=>idsToDelete.indexOf(id)===-1),stagedActionIds=[0,...stagedActionIds.slice(excess+1)],committedState=computedStates[excess].state,computedStates=computedStates.slice(excess),currentStateIndex=currentStateIndex>excess?currentStateIndex-excess:0}function commitChanges(){actionsById={0:liftAction(INIT_ACTION)},nextActionId=1,stagedActionIds=[0],skippedActionIds=[],committedState=computedStates[currentStateIndex].state,currentStateIndex=0,computedStates=[]}let minInvalidatedStateIndex=0;switch(liftedAction.type){case LOCK_CHANGES:{isLocked=liftedAction.status,minInvalidatedStateIndex=1/0;break}case PAUSE_RECORDING:{isPaused=liftedAction.status,isPaused?(stagedActionIds=[...stagedActionIds,nextActionId],actionsById[nextActionId]=new PerformAction({type:"@ngrx/devtools/pause"},+Date.now()),nextActionId++,minInvalidatedStateIndex=stagedActionIds.length-1,computedStates=computedStates.concat(computedStates[computedStates.length-1]),currentStateIndex===stagedActionIds.length-2&&currentStateIndex++,minInvalidatedStateIndex=1/0):commitChanges();break}case RESET:{actionsById={0:liftAction(INIT_ACTION)},nextActionId=1,stagedActionIds=[0],skippedActionIds=[],committedState=initialCommittedState,currentStateIndex=0,computedStates=[];break}case COMMIT:{commitChanges();break}case ROLLBACK:{actionsById={0:liftAction(INIT_ACTION)},nextActionId=1,stagedActionIds=[0],skippedActionIds=[],currentStateIndex=0,computedStates=[];break}case TOGGLE_ACTION:{let{id:actionId}=liftedAction;skippedActionIds.indexOf(actionId)===-1?skippedActionIds=[actionId,...skippedActionIds]:skippedActionIds=skippedActionIds.filter(id=>id!==actionId),minInvalidatedStateIndex=stagedActionIds.indexOf(actionId);break}case SET_ACTIONS_ACTIVE:{let{start:start3,end:end2,active}=liftedAction,actionIds=[];for(let i=start3;i<end2;i++)actionIds.push(i);active?skippedActionIds=difference(skippedActionIds,actionIds):skippedActionIds=[...skippedActionIds,...actionIds],minInvalidatedStateIndex=stagedActionIds.indexOf(start3);break}case JUMP_TO_STATE:{currentStateIndex=liftedAction.index,minInvalidatedStateIndex=1/0;break}case JUMP_TO_ACTION:{let index=stagedActionIds.indexOf(liftedAction.actionId);index!==-1&&(currentStateIndex=index),minInvalidatedStateIndex=1/0;break}case SWEEP:{stagedActionIds=difference(stagedActionIds,skippedActionIds),skippedActionIds=[],currentStateIndex=Math.min(currentStateIndex,stagedActionIds.length-1);break}case PERFORM_ACTION:{if(isLocked)return liftedState||initialLiftedState;if(isPaused||liftedState&&isActionFiltered(liftedState.computedStates[currentStateIndex],liftedAction,options.predicate,options.actionsSafelist,options.actionsBlocklist)){let lastState=computedStates[computedStates.length-1];computedStates=[...computedStates.slice(0,-1),computeNextEntry(reducer44,liftedAction.action,lastState.state,lastState.error,errorHandler)],minInvalidatedStateIndex=1/0;break}options.maxAge&&stagedActionIds.length===options.maxAge&&commitExcessActions(1),currentStateIndex===stagedActionIds.length-1&&currentStateIndex++;let actionId=nextActionId++;actionsById[actionId]=liftedAction,stagedActionIds=[...stagedActionIds,actionId],minInvalidatedStateIndex=stagedActionIds.length-1;break}case IMPORT_STATE:{({monitorState,actionsById,nextActionId,stagedActionIds,skippedActionIds,committedState,currentStateIndex,computedStates,isLocked,isPaused}=liftedAction.nextLiftedState);break}case INIT:{minInvalidatedStateIndex=0,options.maxAge&&stagedActionIds.length>options.maxAge&&(computedStates=recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused),commitExcessActions(stagedActionIds.length-options.maxAge),minInvalidatedStateIndex=1/0);break}case UPDATE:{if(computedStates.filter(state=>state.error).length>0)minInvalidatedStateIndex=0,options.maxAge&&stagedActionIds.length>options.maxAge&&(computedStates=recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused),commitExcessActions(stagedActionIds.length-options.maxAge),minInvalidatedStateIndex=1/0);else{if(!isPaused&&!isLocked){currentStateIndex===stagedActionIds.length-1&&currentStateIndex++;let actionId=nextActionId++;actionsById[actionId]=new PerformAction(liftedAction,+Date.now()),stagedActionIds=[...stagedActionIds,actionId],minInvalidatedStateIndex=stagedActionIds.length-1,computedStates=recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused)}computedStates=computedStates.map(cmp=>__spreadProps(__spreadValues({},cmp),{state:reducer44(cmp.state,RECOMPUTE_ACTION)})),currentStateIndex=stagedActionIds.length-1,options.maxAge&&stagedActionIds.length>options.maxAge&&commitExcessActions(stagedActionIds.length-options.maxAge),minInvalidatedStateIndex=1/0}break}default:{minInvalidatedStateIndex=1/0;break}}return computedStates=recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused),monitorState=monitorReducer(monitorState,liftedAction),{monitorState,actionsById,nextActionId,stagedActionIds,skippedActionIds,committedState,currentStateIndex,computedStates,isLocked,isPaused}}}var StoreDevtools=(()=>{class StoreDevtools2{constructor(dispatcher,actions$,reducers$,extension,scannedActions,errorHandler,initialState48,config3){let liftedInitialState=liftInitialState(initialState48,config3.monitor),liftReducer=liftReducerWith(initialState48,liftedInitialState,errorHandler,config3.monitor,config3),liftedAction$=merge(merge(actions$.asObservable().pipe(skip(1)),extension.actions$).pipe(map(liftAction)),dispatcher,extension.liftedActions$).pipe(observeOn(queueScheduler)),liftedReducer$=reducers$.pipe(map(liftReducer)),zoneConfig=injectZoneConfig(config3.connectInZone),liftedStateSubject=new ReplaySubject(1);this.liftedStateSubscription=liftedAction$.pipe(withLatestFrom(liftedReducer$),emitInZone(zoneConfig),scan(({state:liftedState},[action,reducer44])=>{let reducedLiftedState=reducer44(liftedState,action);return action.type!==PERFORM_ACTION&&shouldFilterActions(config3)&&(reducedLiftedState=filterLiftedState(reducedLiftedState,config3.predicate,config3.actionsSafelist,config3.actionsBlocklist)),extension.notify(action,reducedLiftedState),{state:reducedLiftedState,action}},{state:liftedInitialState,action:null})).subscribe(({state,action})=>{if(liftedStateSubject.next(state),action.type===PERFORM_ACTION){let unliftedAction=action.action;scannedActions.next(unliftedAction)}}),this.extensionStartSubscription=extension.start$.pipe(emitInZone(zoneConfig)).subscribe(()=>{this.refresh()});let liftedState$=liftedStateSubject.asObservable(),state$=liftedState$.pipe(map(unliftState));Object.defineProperty(state$,"state",{value:toSignal(state$,{manualCleanup:!0,requireSync:!0})}),this.dispatcher=dispatcher,this.liftedState=liftedState$,this.state=state$}ngOnDestroy(){this.liftedStateSubscription.unsubscribe(),this.extensionStartSubscription.unsubscribe()}dispatch(action){this.dispatcher.next(action)}next(action){this.dispatcher.next(action)}error(error3){}complete(){}performAction(action){this.dispatch(new PerformAction(action,+Date.now()))}refresh(){this.dispatch(new Refresh)}reset(){this.dispatch(new Reset(+Date.now()))}rollback(){this.dispatch(new Rollback(+Date.now()))}commit(){this.dispatch(new Commit(+Date.now()))}sweep(){this.dispatch(new Sweep)}toggleAction(id){this.dispatch(new ToggleAction(id))}jumpToAction(actionId){this.dispatch(new JumpToAction(actionId))}jumpToState(index){this.dispatch(new JumpToState(index))}importState(nextLiftedState){this.dispatch(new ImportState(nextLiftedState))}lockChanges(status){this.dispatch(new LockChanges(status))}pauseRecording(status){this.dispatch(new PauseRecording(status))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||StoreDevtools2)(\u0275\u0275inject(DevtoolsDispatcher),\u0275\u0275inject(ActionsSubject),\u0275\u0275inject(ReducerObservable),\u0275\u0275inject(DevtoolsExtension),\u0275\u0275inject(ScannedActionsSubject),\u0275\u0275inject(ErrorHandler),\u0275\u0275inject(INITIAL_STATE),\u0275\u0275inject(STORE_DEVTOOLS_CONFIG))}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:StoreDevtools2,factory:StoreDevtools2.\u0275fac})}}return StoreDevtools2})();function emitInZone({ngZone,connectInZone}){return source=>connectInZone?new Observable(subscriber=>source.subscribe({next:value=>ngZone.run(()=>subscriber.next(value)),error:error3=>ngZone.run(()=>subscriber.error(error3)),complete:()=>ngZone.run(()=>subscriber.complete())})):source}var IS_EXTENSION_OR_MONITOR_PRESENT=new InjectionToken("@ngrx/store-devtools Is Devtools Extension or Monitor Present");function createIsExtensionOrMonitorPresent(extension,config3){return!!extension||config3.monitor!==noMonitor}function createReduxDevtoolsExtension(){let extensionKey="__REDUX_DEVTOOLS_EXTENSION__";return typeof window=="object"&&typeof window[extensionKey]<"u"?window[extensionKey]:null}function createStateObservable(devtools){return devtools.state}function provideStoreDevtools(options={}){return makeEnvironmentProviders([DevtoolsExtension,DevtoolsDispatcher,StoreDevtools,{provide:INITIAL_OPTIONS,useValue:options},{provide:IS_EXTENSION_OR_MONITOR_PRESENT,deps:[REDUX_DEVTOOLS_EXTENSION,STORE_DEVTOOLS_CONFIG],useFactory:createIsExtensionOrMonitorPresent},{provide:REDUX_DEVTOOLS_EXTENSION,useFactory:createReduxDevtoolsExtension},{provide:STORE_DEVTOOLS_CONFIG,deps:[INITIAL_OPTIONS],useFactory:createConfig},{provide:StateObservable,deps:[StoreDevtools],useFactory:createStateObservable},{provide:ReducerManagerDispatcher,useExisting:DevtoolsDispatcher}])}var StoreDevtoolsModule=(()=>{class StoreDevtoolsModule2{static instrument(options={}){return{ngModule:StoreDevtoolsModule2,providers:[provideStoreDevtools(options)]}}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||StoreDevtoolsModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:StoreDevtoolsModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({})}}return StoreDevtoolsModule2})();var DEBUG_BUILD=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;var GLOBAL_OBJ=globalThis;var SDK_VERSION="10.5.0";function getMainCarrier(){return getSentryCarrier(GLOBAL_OBJ),GLOBAL_OBJ}function getSentryCarrier(carrier){let __SENTRY__=carrier.__SENTRY__=carrier.__SENTRY__||{};return __SENTRY__.version=__SENTRY__.version||SDK_VERSION,__SENTRY__[SDK_VERSION]=__SENTRY__[SDK_VERSION]||{}}function getGlobalSingleton(name,creator,obj=GLOBAL_OBJ){let __SENTRY__=obj.__SENTRY__=obj.__SENTRY__||{},carrier=__SENTRY__[SDK_VERSION]=__SENTRY__[SDK_VERSION]||{};return carrier[name]||(carrier[name]=creator())}var PREFIX="Sentry Logger ",originalConsoleMethods={};function consoleSandbox(callback){if(!("console"in GLOBAL_OBJ))return callback();let console2=GLOBAL_OBJ.console,wrappedFuncs={},wrappedLevels=Object.keys(originalConsoleMethods);wrappedLevels.forEach(level=>{let originalConsoleMethod=originalConsoleMethods[level];wrappedFuncs[level]=console2[level],console2[level]=originalConsoleMethod});try{return callback()}finally{wrappedLevels.forEach(level=>{console2[level]=wrappedFuncs[level]})}}function enable(){_getLoggerSettings().enabled=!0}function disable(){_getLoggerSettings().enabled=!1}function isEnabled(){return _getLoggerSettings().enabled}function log(...args){_maybeLog("log",...args)}function warn2(...args){_maybeLog("warn",...args)}function error2(...args){_maybeLog("error",...args)}function _maybeLog(level,...args){DEBUG_BUILD&&isEnabled()&&consoleSandbox(()=>{GLOBAL_OBJ.console[level](`${PREFIX}[${level}]:`,...args)})}function _getLoggerSettings(){return DEBUG_BUILD?getGlobalSingleton("loggerSettings",()=>({enabled:!1})):{enabled:!1}}var debug={enable,disable,isEnabled,log,warn:warn2,error:error2};var objectToString=Object.prototype.toString;function isBuiltin(wat,className){return objectToString.call(wat)===`[object ${className}]`}function isPlainObject(wat){return isBuiltin(wat,"Object")}function isThenable(wat){return!!(wat?.then&&typeof wat.then=="function")}function truncate(str,max2=0){return typeof str!="string"||max2===0||str.length<=max2?str:`${str.slice(0,max2)}...`}function addNonEnumerableProperty(obj,name,value){try{Object.defineProperty(obj,name,{value,writable:!0,configurable:!0})}catch{DEBUG_BUILD&&debug.log(`Failed to add non-enumerable property "${name}" to object`,obj)}}function getCrypto(){let gbl=GLOBAL_OBJ;return gbl.crypto||gbl.msCrypto}function uuid4(crypto2=getCrypto()){let getRandomByte=()=>Math.random()*16;try{if(crypto2?.randomUUID)return crypto2.randomUUID().replace(/-/g,"");crypto2?.getRandomValues&&(getRandomByte=()=>{let typedArray=new Uint8Array(1);return crypto2.getRandomValues(typedArray),typedArray[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,c=>(c^(getRandomByte()&15)>>c/4).toString(16))}var ONE_SECOND_IN_MS=1e3;function dateTimestampInSeconds(){return Date.now()/ONE_SECOND_IN_MS}function createUnixTimestampInSecondsFunc(){let{performance:performance2}=GLOBAL_OBJ;if(!performance2?.now||!performance2.timeOrigin)return dateTimestampInSeconds;let timeOrigin=performance2.timeOrigin;return()=>(timeOrigin+performance2.now())/ONE_SECOND_IN_MS}var _cachedTimestampInSeconds;function timestampInSeconds(){return(_cachedTimestampInSeconds??(_cachedTimestampInSeconds=createUnixTimestampInSecondsFunc()))()}function updateSession(session,context3={}){if(context3.user&&(!session.ipAddress&&context3.user.ip_address&&(session.ipAddress=context3.user.ip_address),!session.did&&!context3.did&&(session.did=context3.user.id||context3.user.email||context3.user.username)),session.timestamp=context3.timestamp||timestampInSeconds(),context3.abnormal_mechanism&&(session.abnormal_mechanism=context3.abnormal_mechanism),context3.ignoreDuration&&(session.ignoreDuration=context3.ignoreDuration),context3.sid&&(session.sid=context3.sid.length===32?context3.sid:uuid4()),context3.init!==void 0&&(session.init=context3.init),!session.did&&context3.did&&(session.did=`${context3.did}`),typeof context3.started=="number"&&(session.started=context3.started),session.ignoreDuration)session.duration=void 0;else if(typeof context3.duration=="number")session.duration=context3.duration;else{let duration=session.timestamp-session.started;session.duration=duration>=0?duration:0}context3.release&&(session.release=context3.release),context3.environment&&(session.environment=context3.environment),!session.ipAddress&&context3.ipAddress&&(session.ipAddress=context3.ipAddress),!session.userAgent&&context3.userAgent&&(session.userAgent=context3.userAgent),typeof context3.errors=="number"&&(session.errors=context3.errors),context3.status&&(session.status=context3.status)}function merge3(initialObj,mergeObj,levels=2){if(!mergeObj||typeof mergeObj!="object"||levels<=0)return mergeObj;if(initialObj&&Object.keys(mergeObj).length===0)return initialObj;let output2=__spreadValues({},initialObj);for(let key in mergeObj)Object.prototype.hasOwnProperty.call(mergeObj,key)&&(output2[key]=merge3(output2[key],mergeObj[key],levels-1));return output2}function generateTraceId(){return uuid4()}var SCOPE_SPAN_FIELD="_sentrySpan";function _setSpanForScope(scope,span){span?addNonEnumerableProperty(scope,SCOPE_SPAN_FIELD,span):delete scope[SCOPE_SPAN_FIELD]}function _getSpanForScope(scope){return scope[SCOPE_SPAN_FIELD]}var DEFAULT_MAX_BREADCRUMBS=100,Scope=class _Scope{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:generateTraceId(),sampleRand:Math.random()}}clone(){let newScope=new _Scope;return newScope._breadcrumbs=[...this._breadcrumbs],newScope._tags=__spreadValues({},this._tags),newScope._extra=__spreadValues({},this._extra),newScope._contexts=__spreadValues({},this._contexts),this._contexts.flags&&(newScope._contexts.flags={values:[...this._contexts.flags.values]}),newScope._user=this._user,newScope._level=this._level,newScope._session=this._session,newScope._transactionName=this._transactionName,newScope._fingerprint=this._fingerprint,newScope._eventProcessors=[...this._eventProcessors],newScope._attachments=[...this._attachments],newScope._sdkProcessingMetadata=__spreadValues({},this._sdkProcessingMetadata),newScope._propagationContext=__spreadValues({},this._propagationContext),newScope._client=this._client,newScope._lastEventId=this._lastEventId,_setSpanForScope(newScope,_getSpanForScope(this)),newScope}setClient(client){this._client=client}setLastEventId(lastEventId2){this._lastEventId=lastEventId2}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(callback){this._scopeListeners.push(callback)}addEventProcessor(callback){return this._eventProcessors.push(callback),this}setUser(user){return this._user=user||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&updateSession(this._session,{user}),this._notifyScopeListeners(),this}getUser(){return this._user}setTags(tags){return this._tags=__spreadValues(__spreadValues({},this._tags),tags),this._notifyScopeListeners(),this}setTag(key,value){return this._tags=__spreadProps(__spreadValues({},this._tags),{[key]:value}),this._notifyScopeListeners(),this}setExtras(extras){return this._extra=__spreadValues(__spreadValues({},this._extra),extras),this._notifyScopeListeners(),this}setExtra(key,extra){return this._extra=__spreadProps(__spreadValues({},this._extra),{[key]:extra}),this._notifyScopeListeners(),this}setFingerprint(fingerprint){return this._fingerprint=fingerprint,this._notifyScopeListeners(),this}setLevel(level){return this._level=level,this._notifyScopeListeners(),this}setTransactionName(name){return this._transactionName=name,this._notifyScopeListeners(),this}setContext(key,context3){return context3===null?delete this._contexts[key]:this._contexts[key]=context3,this._notifyScopeListeners(),this}setSession(session){return session?this._session=session:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(captureContext){if(!captureContext)return this;let scopeToMerge=typeof captureContext=="function"?captureContext(this):captureContext,scopeInstance=scopeToMerge instanceof _Scope?scopeToMerge.getScopeData():isPlainObject(scopeToMerge)?captureContext:void 0,{tags,extra,user,contexts,level,fingerprint=[],propagationContext}=scopeInstance||{};return this._tags=__spreadValues(__spreadValues({},this._tags),tags),this._extra=__spreadValues(__spreadValues({},this._extra),extra),this._contexts=__spreadValues(__spreadValues({},this._contexts),contexts),user&&Object.keys(user).length&&(this._user=user),level&&(this._level=level),fingerprint.length&&(this._fingerprint=fingerprint),propagationContext&&(this._propagationContext=propagationContext),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,_setSpanForScope(this,void 0),this._attachments=[],this.setPropagationContext({traceId:generateTraceId(),sampleRand:Math.random()}),this._notifyScopeListeners(),this}addBreadcrumb(breadcrumb,maxBreadcrumbs){let maxCrumbs=typeof maxBreadcrumbs=="number"?maxBreadcrumbs:DEFAULT_MAX_BREADCRUMBS;if(maxCrumbs<=0)return this;let mergedBreadcrumb=__spreadProps(__spreadValues({timestamp:dateTimestampInSeconds()},breadcrumb),{message:breadcrumb.message?truncate(breadcrumb.message,2048):breadcrumb.message});return this._breadcrumbs.push(mergedBreadcrumb),this._breadcrumbs.length>maxCrumbs&&(this._breadcrumbs=this._breadcrumbs.slice(-maxCrumbs),this._client?.recordDroppedEvent("buffer_overflow","log_item")),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(attachment){return this._attachments.push(attachment),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:_getSpanForScope(this)}}setSDKProcessingMetadata(newData){return this._sdkProcessingMetadata=merge3(this._sdkProcessingMetadata,newData,2),this}setPropagationContext(context3){return this._propagationContext=context3,this}getPropagationContext(){return this._propagationContext}captureException(exception,hint){let eventId=hint?.event_id||uuid4();if(!this._client)return DEBUG_BUILD&&debug.warn("No client configured on scope - will not capture exception!"),eventId;let syntheticException=new Error("Sentry syntheticException");return this._client.captureException(exception,__spreadProps(__spreadValues({originalException:exception,syntheticException},hint),{event_id:eventId}),this),eventId}captureMessage(message,level,hint){let eventId=hint?.event_id||uuid4();if(!this._client)return DEBUG_BUILD&&debug.warn("No client configured on scope - will not capture message!"),eventId;let syntheticException=new Error(message);return this._client.captureMessage(message,level,__spreadProps(__spreadValues({originalException:message,syntheticException},hint),{event_id:eventId}),this),eventId}captureEvent(event2,hint){let eventId=hint?.event_id||uuid4();return this._client?(this._client.captureEvent(event2,__spreadProps(__spreadValues({},hint),{event_id:eventId}),this),eventId):(DEBUG_BUILD&&debug.warn("No client configured on scope - will not capture event!"),eventId)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(callback=>{callback(this)}),this._notifyingListeners=!1)}};function getDefaultCurrentScope(){return getGlobalSingleton("defaultCurrentScope",()=>new Scope)}function getDefaultIsolationScope(){return getGlobalSingleton("defaultIsolationScope",()=>new Scope)}var AsyncContextStack=class{constructor(scope,isolationScope){let assignedScope;scope?assignedScope=scope:assignedScope=new Scope;let assignedIsolationScope;isolationScope?assignedIsolationScope=isolationScope:assignedIsolationScope=new Scope,this._stack=[{scope:assignedScope}],this._isolationScope=assignedIsolationScope}withScope(callback){let scope=this._pushScope(),maybePromiseResult;try{maybePromiseResult=callback(scope)}catch(e){throw this._popScope(),e}return isThenable(maybePromiseResult)?maybePromiseResult.then(res=>(this._popScope(),res),e=>{throw this._popScope(),e}):(this._popScope(),maybePromiseResult)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){let scope=this.getScope().clone();return this._stack.push({client:this.getClient(),scope}),scope}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}};function getAsyncContextStack(){let registry=getMainCarrier(),sentry=getSentryCarrier(registry);return sentry.stack=sentry.stack||new AsyncContextStack(getDefaultCurrentScope(),getDefaultIsolationScope())}function withScope(callback){return getAsyncContextStack().withScope(callback)}function withSetScope(scope,callback){let stack=getAsyncContextStack();return stack.withScope(()=>(stack.getStackTop().scope=scope,callback(scope)))}function withIsolationScope(callback){return getAsyncContextStack().withScope(()=>callback(getAsyncContextStack().getIsolationScope()))}function getStackAsyncContextStrategy(){return{withIsolationScope,withScope,withSetScope,withSetIsolationScope:(_isolationScope,callback)=>withIsolationScope(callback),getCurrentScope:()=>getAsyncContextStack().getScope(),getIsolationScope:()=>getAsyncContextStack().getIsolationScope()}}function getAsyncContextStrategy(carrier){let sentry=getSentryCarrier(carrier);return sentry.acs?sentry.acs:getStackAsyncContextStrategy()}function getCurrentScope(){let carrier=getMainCarrier();return getAsyncContextStrategy(carrier).getCurrentScope()}function getIsolationScope(){let carrier=getMainCarrier();return getAsyncContextStrategy(carrier).getIsolationScope()}function getClient(){return getCurrentScope().getClient()}var DEFAULT_BREADCRUMBS=100;function addBreadcrumb(breadcrumb,hint){let client=getClient(),isolationScope=getIsolationScope();if(!client)return;let{beforeBreadcrumb=null,maxBreadcrumbs=DEFAULT_BREADCRUMBS}=client.getOptions();if(maxBreadcrumbs<=0)return;let timestamp2=dateTimestampInSeconds(),mergedBreadcrumb=__spreadValues({timestamp:timestamp2},breadcrumb),finalBreadcrumb=beforeBreadcrumb?consoleSandbox(()=>beforeBreadcrumb(mergedBreadcrumb,hint)):mergedBreadcrumb;finalBreadcrumb!==null&&(client.emit&&client.emit("beforeAddBreadcrumb",finalBreadcrumb,hint),isolationScope.addBreadcrumb(finalBreadcrumb,maxBreadcrumbs))}function sentryNgrxMetaReducer(reducer44){return function(state,action){return addBreadcrumb({category:"ngrx",message:action.type,level:"info"}),reducer44(state,action)}}var reducers={router:routerReducer},metaReducers=environment.production?[sentryNgrxMetaReducer]:[];var AppEffects=(()=>{class AppEffects2{constructor(){this.actions$=inject(Actions),this.location=inject(Location),this.router=inject(Router),this.company2faRequired$=createEffect(()=>this.actions$.pipe(ofType(loadMeFailure),mergeMap(({errors:errors2})=>errors2.some(error3=>error3.message===IxApiRequestErrorMessages.TWO_FACTOR_AUTH_REQUIRED)?of(redirectTo2faRequired()):EMPTY))),this.redirectTo2faRequired$=createEffect(()=>this.actions$.pipe(ofType(redirectTo2faRequired),tap(()=>{this.router.navigate(["/two-factor-auth-required"],{skipLocationChange:!0})})),{dispatch:!1})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||AppEffects2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:AppEffects2,factory:AppEffects2.\u0275fac})}}return AppEffects2})();var AppStateModule=(()=>{class AppStateModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||AppStateModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:AppStateModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[TranslateModule,StoreModule.forRoot(reducers,{metaReducers,runtimeChecks:{strictStateImmutability:!environment.production,strictActionImmutability:!environment.production,strictStateSerializability:!environment.production}}),environment.production?[]:[StoreDevtoolsModule.instrument({maxAge:50,connectInZone:!0})],EffectsModule.forRoot([AppEffects])]})}}return AppStateModule2})();function generateBanner(metadata,translate){let header=document.createElement("div");return header.innerHTML=`
821
+ `))},dependencies:[MatButton,MatIcon,MatTooltip,TranslatePipe],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .zoom-out-button[_ngcontent-%COMP%]{min-width:0;padding:0 7px;margin-right:8px}[_nghost-%COMP%] .zoom-out-button[_ngcontent-%COMP%] .mat-icon[_ngcontent-%COMP%]{margin:0}"],changeDetection:0})}}return PeriodControlsComponent3})();var BackendComponentBrokerDirective=(()=>{class BackendComponentBrokerDirective3{constructor(){this.scopeRef=inject(ComponentGridScopeDirective,{optional:!0}),this.callerFactory=inject(BackendComponentCallerServiceFactory),this.facade=inject(BackendComponentBrokerFacade),this.clientProxy=inject(BackendComponentClientProxyService),this.destroyRef=inject(DestroyRef),this.myCompany$=this.facade.myCompany$,this.myUser$=this.facade.myUser$,this.agentOrAssetId$=new ReplaySubject(1)}set agentOrAssetId(agentOrAssetId){this.agentOrAssetId$.next(agentOrAssetId)}ngOnInit(){combineLatest([this.facade.findAgentAndAsset(this.agentOrAssetId$),this.facade.myCompany$,this.facade.myUser$]).pipe(filter(([,myCompany,myUser])=>!!myCompany&&!!myUser),takeUntilDestroyed(this.destroyRef)).subscribe(([[agent,asset],myCompany,myUser])=>{this.caller=this.callerFactory.create({agent,asset,myCompany,myUser})}),this.clientProxy.onCall(this.scopeRef?.value).pipe(mergeMap(call=>this.facade.resolveTemplateFromPageComponent(call.pageComponentId).pipe(first(),map(result=>({call:call.call,template:{publicId:result}})))),mergeMap(call=>this.caller?this.caller.call(call).pipe(map(result=>({result,call})),catchError(error3=>(this.clientProxy.emitError({call:call.call,data:error3},this.scopeRef?.value),EMPTY))):EMPTY),takeUntilDestroyed(this.destroyRef)).subscribe(({result,call})=>{this.clientProxy.emitResult({call:call.call,data:result.value},this.scopeRef?.value)})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||BackendComponentBrokerDirective3)}}static{this.\u0275dir=\u0275\u0275defineDirective({type:BackendComponentBrokerDirective3,selectors:[["","ixBackendComponentBroker",""]],inputs:{agentOrAssetId:"agentOrAssetId"}})}}return BackendComponentBrokerDirective3})();var PagesModule=(()=>{class PagesModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PagesModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:PagesModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({providers:[ComponentContextService],imports:[SharedModule,NgxDaterangepickerMd,ComponentGridModule,ComponentPropertiesModule,FileSaveModule,PeriodBottomSheetComponent,PeriodPanelComponent,ComponentGridModule,ComponentPropertiesModule]})}}return PagesModule2})();function mutationObservableFactory(target,options){return new Observable(subscriber=>{let observer=new MutationObserver(records=>{subscriber.next(records)});return observer.observe(target,options),function(){observer.disconnect()}})}var _c018=["*"],ButtonToggleComponent=(()=>{class ButtonToggleComponent3{constructor(){this.elRef=inject(ElementRef),this.disabled=!1,this.valueChange=new EventEmitter}getWidth(){return this.elRef.nativeElement.clientWidth??0}getOffset(){return this.elRef.nativeElement.offsetLeft??0}select(){this.selected=!0}unselect(){this.selected=!1}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ButtonToggleComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ButtonToggleComponent3,selectors:[["ix-button-toggle"]],inputs:{value:"value",disabled:"disabled"},outputs:{valueChange:"valueChange"},ngContentSelectors:_c018,decls:2,vars:4,consts:[["role","tab","tabindex","0",1,"button",3,"click"]],template:function(rf,ctx){rf&1&&(\u0275\u0275projectionDef(),\u0275\u0275domElementStart(0,"div",0),\u0275\u0275domListener("click",function(){return ctx.valueChange.emit(ctx.value)}),\u0275\u0275projection(1),\u0275\u0275domElementEnd()),rf&2&&\u0275\u0275classProp("disabled",ctx.disabled)("selected",ctx.selected)},styles:["[_nghost-%COMP%] .button[_ngcontent-%COMP%]{display:flex;flex-direction:row;align-items:center;padding:0 12px;text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;word-wrap:normal;cursor:pointer;font-size:14px;max-width:100%;position:relative;height:34px;color:color-mix(in srgb,currentcolor 50%,transparent);transition:box-shadow .2s cubic-bezier(.4,1,.75,.9);-webkit-user-select:none;user-select:none}[_nghost-%COMP%] .button.selected[_ngcontent-%COMP%]{color:currentcolor;font-weight:500;z-index:1}[_nghost-%COMP%] .button.disabled[_ngcontent-%COMP%]{color:color-mix(in srgb,currentcolor 25%,transparent);pointer-events:none}[_nghost-%COMP%] .button[_ngcontent-%COMP%]:focus{outline:none;outline-offset:0;-moz-outline-radius:0}[_nghost-%COMP%]:hover [_ngcontent-%COMP%]:not(.selected,.disabled){border-bottom:none;color:color-mix(in srgb,currentcolor 75%,transparent);background-color:color-mix(in srgb,currentcolor 4%,transparent)!important;border-radius:12px;box-shadow:none!important;transition:all .2s cubic-bezier(.4,1,.75,.9)}"]})}}return ButtonToggleComponent3})();var _c019=["*"],ButtonToggleGroupComponent=(()=>{class ButtonToggleGroupComponent3{constructor(){this.cdRef=inject(ChangeDetectorRef),this.elRef=inject(ElementRef),this.destroy=inject(DestroyRef),this.ngZone=inject(NgZone),this.indicatorStyle=null,this._animate=!1,mutationObservableFactory(this.elRef.nativeElement,{childList:!0}).pipe(takeUntilDestroyed(this.destroy)).subscribe(()=>{this.animate(),this.cdRef.markForCheck()}),resizeObservableFactory(this.elRef.nativeElement).pipe(skip(1),takeUntilDestroyed(this.destroy)).subscribe(()=>{this.animate(),this.cdRef.markForCheck()})}ngOnChanges(changes){changes.value&&!changes.value.isFirstChange()&&this.animate()}animate(){this._active=this._buttons?.find(segment=>segment.value===this.value)??null,this._active?.select(),this._buttons?.filter(s2=>s2!==this._active).forEach(s2=>s2.unselect()),this.indicatorStyle=this._active?{width:`${this._active.getWidth()}px`,transform:`translateX(${this._active.getOffset()}px)`}:null,this._active&&!this._animate&&this.ngZone.runOutsideAngular(()=>{setTimeout(()=>{this._animate=!0,this.elRef.nativeElement.classList.add("animate")},0)})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ButtonToggleGroupComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ButtonToggleGroupComponent3,selectors:[["ix-button-toggle-group"]],contentQueries:function(rf,ctx,dirIndex){if(rf&1&&\u0275\u0275contentQuery(dirIndex,ButtonToggleComponent,4),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx._buttons=_t)}},inputs:{value:"value"},features:[\u0275\u0275NgOnChangesFeature],ngContentSelectors:_c019,decls:3,vars:2,consts:[["role","tablist",1,"button-list"],[1,"active-indicator"]],template:function(rf,ctx){rf&1&&(\u0275\u0275projectionDef(),\u0275\u0275domElementStart(0,"div",0),\u0275\u0275domElement(1,"div",1),\u0275\u0275projection(2),\u0275\u0275domElementEnd()),rf&2&&(\u0275\u0275advance(),\u0275\u0275styleMap(ctx.indicatorStyle))},styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] .button-list[_ngcontent-%COMP%]{align-items:flex-end;border:none;display:flex;flex:0 0 auto;list-style:none;margin:0;padding:0;position:relative;background-color:var(--button-toggle-bg, var(--mat-sys-background));color:var(--button-toggle-color, var(--mat-sys-on-background));box-shadow:0 0 0 1px color-mix(in srgb,transparent,var(--button-toggle-color, var(--mat-sys-on-background)) 24%);border-radius:12px}[_nghost-%COMP%] .button-list[_ngcontent-%COMP%] .active-indicator[_ngcontent-%COMP%]{left:0;pointer-events:none;position:absolute;top:0;transform:translate(0);transition:height,transform,width;transition-duration:0;transition-timing-function:cubic-bezier(.4,1,.75,.9);border-radius:12px;box-shadow:0 0 0 1px var(--button-toggle-color, var(--mat-sys-on-background)),inset 0 0 0 1px var(--button-toggle-color, var(--mat-sys-on-background));height:34px;background-color:var(--button-toggle-bg, var(--mat-sys-background));z-index:1}.animate[_nghost-%COMP%] .button-list[_ngcontent-%COMP%] .active-indicator[_ngcontent-%COMP%]{transition-duration:.2s}"],changeDetection:0})}}return ButtonToggleGroupComponent3})();var ButtonToggleModule=(()=>{class ButtonToggleModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ButtonToggleModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:ButtonToggleModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({})}}return ButtonToggleModule2})();var ReloadOnValueChangeDirective=(()=>{class ReloadOnValueChangeDirective2{constructor(cdRef,templateRef,viewContainer){this.cdRef=cdRef,this.templateRef=templateRef,this.viewContainer=viewContainer,this.changes=new ReplaySubject,this.destroy=inject(DestroyRef)}ngOnInit(){this.viewContainer.createEmbeddedView(this.templateRef),this.changes.pipe(distinctUntilChanged(isEqual_default),takeUntilDestroyed(this.destroy)).subscribe(()=>{this.viewContainer.clear(),this.viewContainer.createEmbeddedView(this.templateRef),this.cdRef.markForCheck()})}ngOnChanges(changes){changes.value.isFirstChange()||this.changes.next(changes.value.currentValue)}ngOnDestroy(){this.changes.complete()}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ReloadOnValueChangeDirective2)(\u0275\u0275directiveInject(ChangeDetectorRef),\u0275\u0275directiveInject(TemplateRef),\u0275\u0275directiveInject(ViewContainerRef))}}static{this.\u0275dir=\u0275\u0275defineDirective({type:ReloadOnValueChangeDirective2,selectors:[["","ixReloadOnValueChange",""]],inputs:{value:[0,"ixReloadOnValueChange","value"]},features:[\u0275\u0275NgOnChangesFeature]})}}return ReloadOnValueChangeDirective2})();var AlertDialogModule=(()=>{class AlertDialogModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||AlertDialogModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:AlertDialogModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[SharedModule]})}}return AlertDialogModule2})();function assetsToAssetTreeOptions(rootId,descendantAssets){let sortedDescendants=sortBy_default(descendantAssets,["order"]),assetDict=Object.fromEntries(sortedDescendants.map(a=>[a.publicId,a])),childrenMap=new Map;sortedDescendants.forEach(asset=>{let parentId=asset.parent?.publicId;parentId&&(childrenMap.has(parentId)||childrenMap.set(parentId,[]),childrenMap.get(parentId)?.push(asset))});let assetDepthMap=new Map(sortedDescendants.map(a=>[a.publicId,_getAssetDepth(a,assetDict)])),directSubAssets=childrenMap.get(rootId)||[];if(directSubAssets.length===0)return[];let flattenedTree=[];return directSubAssets.forEach(asset=>_buildAssetArray(asset,childrenMap,flattenedTree)),flattenedTree.map(a=>{let depth=assetDepthMap.get(a.publicId)??0;return{id:a.publicId,name:a.name??"",depth,match:null}})}function _buildAssetArray(asset,childrenMap,arr){arr.push(asset),(childrenMap.get(asset.publicId)||[]).forEach(child=>_buildAssetArray(child,childrenMap,arr))}function _getAssetDepth(asset,entities,depth=0){let parentId=asset.parent?.publicId;return parentId&&entities[parentId]?_getAssetDepth(entities[parentId],entities,depth+1):depth}var PreviewDeviceSelectFacade=(()=>{class PreviewDeviceSelectFacade2{constructor(){this.store=inject(Store),this.agentsDict$=this.store.select(selectEntities3),this.customPropsDict$=this.store.select(selectAll27).pipe(map(props2=>props2.reduce((dict,p)=>(p.resourceType==="Agent"||p.resourceType==="Asset")&&p.scopeType&&p.slug?__spreadProps(__spreadValues({},dict),{[`${p.resourceType}.custom.${p.scopeType}${p.slug}`]:p}):dict,{}))),this.groupsDict$=this.store.select(selectEntities9)}assetTreeByRootAssetPublicId(rootAssetPublicId){return rootAssetPublicId?this.store.select(selectAllLoadedForRoot(rootAssetPublicId)).pipe(filter(loaded=>loaded),switchMap(()=>this.store.select(selectAllForRoot(rootAssetPublicId))),map(assets=>assetsToAssetTreeOptions(rootAssetPublicId,assets.filter(asset=>!!asset.parent)))):of([])}getRootAssetIdBySubAssetId(subAssetId){return this.store.select(selectEntityWithFields4(subAssetId)(["root"])).pipe(map(asset=>asset?.root?.publicId??null))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PreviewDeviceSelectFacade2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:PreviewDeviceSelectFacade2,factory:PreviewDeviceSelectFacade2.\u0275fac,providedIn:"root"})}}return PreviewDeviceSelectFacade2})();function geoLocationIsEmpty(geoLocation){return geoLocation===null||geoLocation.city==="-"&&geoLocation.country==="-"||geoLocation.latitude==="0.000000"&&geoLocation.longitude==="0.000000"}function mapGeoLocationToName(geoLocation){return geoLocationIsEmpty(geoLocation)?null:geoLocation?.city&&geoLocation?.country?`${geoLocation.city}, ${geoLocation.country}`:geoLocation?.country?geoLocation.country:null}function findAgentOrAssetMatch(a,query,customPropsDict,groupsDict,agentsDict,nullifyName=!0){let q=deburr_default(query.toLowerCase().trim());if((a.name?deburr_default(a.name.toLowerCase()):null)?.includes(q))return nullifyName?null:a.name;if(a.description?.toLowerCase().includes(q))return a.description;if("serialNumber"in a&&a.serialNumber?.toLowerCase().includes(q))return a.serialNumber;let location2="location"in a?a.location?.name||(a.geoLocation?mapGeoLocationToName(a.geoLocation):null):null;if(location2?.toLowerCase().includes(q))return location2;if(groupsDict){let groups=a.memberships?.map(m=>groupsDict[m.group?.publicId]).filter(g=>!!g?.type)??[],groupName=_findBestMatch(groups.map(g=>g.name),q);if(groupName)return groupName}if(customPropsDict){let resType="agent"in a?"Asset":"Agent",customValues=Object.keys(customPropsDict).filter(key=>key.startsWith(`${resType}.`)).map(key=>(a.custom??{})[key.replace(`${resType}.custom.`,"")]).filter(val=>!isNil_default(val)).map(String),customValue=_findBestMatch(customValues,q);if(customValue)return customValue}if(agentsDict&&"agent"in a&&a.agent?.publicId){let linkedAgent=agentsDict[a.agent.publicId];if(linkedAgent)return findAgentOrAssetMatch(linkedAgent,query,customPropsDict,groupsDict,void 0,!1)}}function _findBestMatch(values,q){return values.reduce((best,value)=>{if(!value)return best;let v=deburr_default(value.toLowerCase());if(!v.includes(q))return best;let matchRatio=q.length/v.length;return!best||matchRatio>best.matchRatio?{value,matchRatio}:best},void 0)?.value}var _c020=a0=>[a0],_forTrack08=($index,$item)=>$item.id;function PreviewDeviceSelectComponent_Conditional_10_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",9),\u0275\u0275text(1),\u0275\u0275pipe(2,"translate"),\u0275\u0275elementEnd()),rf&2){let noneOpt_r3=ctx;\u0275\u0275property("value",noneOpt_r3.value),\u0275\u0275advance(),\u0275\u0275textInterpolate(noneOpt_r3.label??\u0275\u0275pipeBind1(2,2,"NONE"))}}function PreviewDeviceSelectComponent_For_12_Conditional_4_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"span",11),\u0275\u0275pipe(1,"highlightText")),rf&2){let option_r4=\u0275\u0275nextContext().$implicit,ctx_r4=\u0275\u0275nextContext();\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(1,1,option_r4.match,ctx_r4.query()),\u0275\u0275sanitizeHtml)}}function PreviewDeviceSelectComponent_For_12_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",9)(1,"div"),\u0275\u0275element(2,"span",10),\u0275\u0275pipe(3,"highlightText"),\u0275\u0275conditionalCreate(4,PreviewDeviceSelectComponent_For_12_Conditional_4_Template,2,4,"span",11),\u0275\u0275elementEnd()()),rf&2){let option_r4=ctx.$implicit,ctx_r4=\u0275\u0275nextContext();\u0275\u0275property("value",option_r4.id),\u0275\u0275advance(2),\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(3,3,option_r4.name,ctx_r4.query()),\u0275\u0275sanitizeHtml),\u0275\u0275advance(2),\u0275\u0275conditional(option_r4.match?4:-1)}}function PreviewDeviceSelectComponent_Conditional_13_For_14_Conditional_4_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"span",11),\u0275\u0275pipe(1,"highlightText")),rf&2){let option_r8=\u0275\u0275nextContext().$implicit,ctx_r4=\u0275\u0275nextContext(2);\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(1,1,option_r8.match,ctx_r4.query()),\u0275\u0275sanitizeHtml)}}function PreviewDeviceSelectComponent_Conditional_13_For_14_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"mat-option",9)(1,"div"),\u0275\u0275element(2,"span",10),\u0275\u0275pipe(3,"highlightText"),\u0275\u0275conditionalCreate(4,PreviewDeviceSelectComponent_Conditional_13_For_14_Conditional_4_Template,2,4,"span",11),\u0275\u0275elementEnd()()),rf&2){let option_r8=ctx.$implicit,ctx_r4=\u0275\u0275nextContext(2);\u0275\u0275property("value",option_r8.id),\u0275\u0275advance(2),\u0275\u0275styleProp("padding-left",\u0275\u0275pureFunction1(8,_c020,8*option_r8.depth),"px"),\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(3,5,option_r8.name,ctx_r4.query()),\u0275\u0275sanitizeHtml),\u0275\u0275advance(2),\u0275\u0275conditional(option_r8.match?4:-1)}}function PreviewDeviceSelectComponent_Conditional_13_Template(rf,ctx){if(rf&1){let _r6=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"div")(1,"button",12),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r6);let subAssetSelect_r7=\u0275\u0275reference(4);return \u0275\u0275resetView(subAssetSelect_r7.onContainerClick())}),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"mat-select",13,3),\u0275\u0275listener("closed",function(){\u0275\u0275restoreView(_r6);let ctx_r4=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r4.handleSubAssetSelectClosed())}),\u0275\u0275elementStart(5,"mat-option",7),\u0275\u0275element(6,"ngx-mat-select-search",8),\u0275\u0275pipe(7,"translate"),\u0275\u0275pipe(8,"translate"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(9,"mat-option",9)(10,"span",14),\u0275\u0275text(11,"NONE"),\u0275\u0275elementEnd()(),\u0275\u0275element(12,"mat-divider"),\u0275\u0275repeaterCreate(13,PreviewDeviceSelectComponent_Conditional_13_For_14_Template,5,10,"mat-option",9,_forTrack08),\u0275\u0275elementEnd()()}if(rf&2){let ctx_r4=\u0275\u0275nextContext(),subAssetDialogOptionTemplate_r9=\u0275\u0275reference(17);\u0275\u0275advance(2),\u0275\u0275textInterpolate1(" ",ctx_r4.subAssetSelectTriggerLabel()," "),\u0275\u0275advance(),\u0275\u0275property("formControl",ctx_r4.subAssetControl)("ixSelectDialogOptionTemplate",subAssetDialogOptionTemplate_r9)("ixSelectDialogSearchPredicate",ctx_r4.subAssetSearchPredicate),\u0275\u0275advance(3),\u0275\u0275property("formControl",ctx_r4.queryControl)("placeholderLabel",\u0275\u0275pipeBind1(7,8,"SEARCH"))("noEntriesFoundLabel",\u0275\u0275pipeBind1(8,10,"NO_RESULTS_FOUND")),\u0275\u0275advance(3),\u0275\u0275property("value",null),\u0275\u0275advance(4),\u0275\u0275repeater(ctx_r4.subAssetOptions())}}function PreviewDeviceSelectComponent_ng_template_14_Conditional_5_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"span",11),\u0275\u0275pipe(1,"highlightText")),rf&2){\u0275\u0275nextContext();let query_r10=\u0275\u0275readContextLet(2);\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(1,1,ctx,query_r10),\u0275\u0275sanitizeHtml)}}function PreviewDeviceSelectComponent_ng_template_14_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",15)(1,"div"),\u0275\u0275declareLet(2),\u0275\u0275element(3,"span",10),\u0275\u0275pipe(4,"highlightText"),\u0275\u0275conditionalCreate(5,PreviewDeviceSelectComponent_ng_template_14_Conditional_5_Template,2,4,"span",11),\u0275\u0275elementEnd()()),rf&2){let tmp_5_0,tmp_7_0,option_r11=ctx.$implicit,ctx_r4=\u0275\u0275nextContext();\u0275\u0275advance(2);let query_r12=\u0275\u0275storeLet(((tmp_5_0=ctx_r4.selectDialogTrigger())==null||tmp_5_0.searchQueryControl==null?null:tmp_5_0.searchQueryControl.value)??"");\u0275\u0275advance(),\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(4,3,option_r11.viewValue,query_r12),\u0275\u0275sanitizeHtml),\u0275\u0275advance(2),\u0275\u0275conditional((tmp_7_0=ctx_r4.findOptionMatch("device",option_r11,query_r12))?5:-1,tmp_7_0)}}function PreviewDeviceSelectComponent_ng_template_16_Conditional_5_Template(rf,ctx){if(rf&1&&(\u0275\u0275element(0,"span",11),\u0275\u0275pipe(1,"highlightText")),rf&2){\u0275\u0275nextContext();let query_r13=\u0275\u0275readContextLet(2);\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(1,1,ctx,query_r13),\u0275\u0275sanitizeHtml)}}function PreviewDeviceSelectComponent_ng_template_16_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",15)(1,"div"),\u0275\u0275declareLet(2),\u0275\u0275element(3,"span",10),\u0275\u0275pipe(4,"highlightText"),\u0275\u0275conditionalCreate(5,PreviewDeviceSelectComponent_ng_template_16_Conditional_5_Template,2,4,"span",11),\u0275\u0275elementEnd()()),rf&2){let tmp_5_0,tmp_7_0,option_r14=ctx.$implicit,ctx_r4=\u0275\u0275nextContext();\u0275\u0275advance(2);let query_r15=\u0275\u0275storeLet(((tmp_5_0=ctx_r4.selectDialogTrigger())==null||tmp_5_0.searchQueryControl==null?null:tmp_5_0.searchQueryControl.value)??"");\u0275\u0275advance(),\u0275\u0275property("innerHTML",\u0275\u0275pipeBind2(4,3,option_r14.viewValue,query_r15),\u0275\u0275sanitizeHtml),\u0275\u0275advance(2),\u0275\u0275conditional((tmp_7_0=ctx_r4.findOptionMatch("subAsset",option_r14,query_r15))?5:-1,tmp_7_0)}}var PreviewDeviceSelectComponent=(()=>{class PreviewDeviceSelectComponent2{constructor(){this.agentAndRootAssets=input.required(),this.value=input(null),this.noneOption=input(),this.hideSubAssets=input(!1,{transform:booleanAttribute}),this.selectionChange=output(),this.facade=inject(PreviewDeviceSelectFacade),this.translateService=inject(TranslateService),this.selectDialogTrigger=viewChild(SelectDialogTriggerDirective),this.deviceControl=new FormControl(null),this.subAssetControl=new FormControl(null),this.queryControl=new FormControl("",{nonNullable:!0}),this.query=toSignal(this.queryControl.valueChanges,{initialValue:""}),this.agentsDict=toSignal(this.facade.agentsDict$,{requireSync:!0}),this.customPropsDict=toSignal(this.facade.customPropsDict$,{requireSync:!0}),this.groupsDict=toSignal(this.facade.groupsDict$,{requireSync:!0}),this.selectedDevicePublicId=toSignal(this.deviceControl.valueChanges.pipe(tap(()=>this.subAssetControl.setValue(null))),{initialValue:null}),this.selectedSubAssetPublicId=toSignal(this.subAssetControl.valueChanges,{initialValue:null}),this.selectedDeviceIsAsset=computed(()=>{let selectedId=this.selectedDevicePublicId();return selectedId?!(selectedId in this.agentsDict()):!1}),this.deviceOptions=computed(()=>this._getDeviceOptionsByQuery(this.query())),this.subAssetParams=computed(()=>({deviceId:this.selectedDeviceIsAsset()?this.selectedDevicePublicId():null})),this.subAssetOptionsResource=resource({params:this.subAssetParams,loader:({params})=>firstValueFrom(this.facade.assetTreeByRootAssetPublicId(params.deviceId))}),this.subAssetOptions=computed(()=>this._getSubAssetOptionsByQuery(this.query())),this.previewDeviceSelectTriggerLabel=computed(()=>{let publicId=this.selectedDevicePublicId(),emptyLabel=this.translateService.instant("SELECT_DEVICE_FOR_PREVIEW");return publicId?this.agentAndRootAssets().find(opt=>opt.publicId===publicId)?.name??emptyLabel:emptyLabel}),this.subAssetSelectTriggerLabel=computed(()=>{let publicId=this.selectedSubAssetPublicId(),emptyLabel=this.translateService.instant("SELECT_A_SUB_ASSET"),options=this.subAssetOptions();return publicId&&options?options.find(opt=>opt.id===publicId)?.name??emptyLabel:emptyLabel}),this.deviceSearchPredicate=this._optionSearchPredicate.bind(this,"device"),this.subAssetSearchPredicate=this._optionSearchPredicate.bind(this,"subAsset"),effect(()=>__async(this,null,function*(){let initialValue=this.value();if(!initialValue){this.deviceControl.setValue(null),this.subAssetControl.setValue(null);return}if(!this.hideSubAssets()&&!this.agentAndRootAssets().some(a=>a.publicId===initialValue)&&initialValue){let rootAssetId=yield firstValueFrom(this.facade.getRootAssetIdBySubAssetId(initialValue));this.deviceControl.setValue(rootAssetId,{emitModelToViewChange:!0,emitViewToModelChange:!1}),this.subAssetControl.setValue(initialValue,{emitModelToViewChange:!0,emitViewToModelChange:!1});return}this.deviceControl.setValue(initialValue,{emitModelToViewChange:!0,emitViewToModelChange:!1})}))}findOptionMatch(type,option,query){return query?(type==="device"?this._getDeviceOptionsByQuery(query):this._getSubAssetOptionsByQuery(query)).find(opt=>opt.id===option.value)?.match:void 0}handlePreviewDeviceSelectClosed(){return __async(this,null,function*(){let publicId=this.selectedDevicePublicId(),selectedSubAssetPublicId=this.selectedSubAssetPublicId();if(selectedSubAssetPublicId){let rootAssetPublicId=yield firstValueFrom(this.facade.getRootAssetIdBySubAssetId(selectedSubAssetPublicId));if(publicId===rootAssetPublicId)return}publicId&&this.selectionChange.emit(publicId)})}handleSubAssetSelectClosed(){let publicId=this.selectedSubAssetPublicId();if(publicId){this.selectionChange.emit(publicId);return}this.handlePreviewDeviceSelectClosed()}_getDeviceOptionsByQuery(query){let agentAndRootAssets=this.agentAndRootAssets();if(query){let agentsDict=this.agentsDict(),customPropsDict=this.customPropsDict(),groupsDict=this.groupsDict();return agentAndRootAssets.reduce((options,a)=>{let match2=findAgentOrAssetMatch(a,query,customPropsDict,groupsDict,agentsDict);return match2!==void 0?[...options,{id:a.publicId,name:a.name,match:match2}]:options},[])}return this.agentAndRootAssets().map(a=>({id:a.publicId,name:a.name,match:null}))}_getSubAssetOptionsByQuery(query){if(this.hideSubAssets())return[];let options=this.subAssetOptionsResource.value();if(!options)return[];if(options&&query){let agentsDict=this.agentsDict(),customPropsDict=this.customPropsDict(),groupsDict=this.groupsDict();return options.filter(opt=>findAgentOrAssetMatch({publicId:opt.id,name:opt.name},query,customPropsDict,groupsDict,agentsDict)!==void 0)}return options}_optionSearchPredicate(type,option,query){return query?(type==="device"?this._getDeviceOptionsByQuery(query):this._getSubAssetOptionsByQuery(query)).some(opt=>opt.id===option.value):!0}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||PreviewDeviceSelectComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:PreviewDeviceSelectComponent2,selectors:[["ix-preview-device-select"]],viewQuery:function(rf,ctx){rf&1&&\u0275\u0275viewQuerySignal(ctx.selectDialogTrigger,SelectDialogTriggerDirective,5),rf&2&&\u0275\u0275queryAdvance()},inputs:{agentAndRootAssets:[1,"agentAndRootAssets"],value:[1,"value"],noneOption:[1,"noneOption"],hideSubAssets:[1,"hideSubAssets"]},outputs:{selectionChange:"selectionChange"},decls:18,vars:13,consts:[["previewDeviceSelect",""],["deviceDialogOptionTemplate",""],["subAssetDialogOptionTemplate",""],["subAssetSelect",""],[1,"button-group"],["matButton","outlined","data-testid","preview-device-select-button",3,"click"],["data-testid","preview-device-select","disableOptionCentering","","panelClass","preview-device-select-button-panel","name","device","ixSelectDialogTrigger","",3,"closed","formControl","ixSelectDialogOptionTemplate","ixSelectDialogSearchPredicate"],[1,"search-option"],[3,"formControl","placeholderLabel","noEntriesFoundLabel"],[3,"value"],[3,"innerHTML"],[1,"match",3,"innerHTML"],["matButton","outlined","data-testid","sub-asset-select-button",3,"click"],["data-testid","sub-asset-select","disableOptionCentering","","panelClass","preview-device-select-button-panel","name","subAsset","ixSelectDialogTrigger","",3,"closed","formControl","ixSelectDialogOptionTemplate","ixSelectDialogSearchPredicate"],["translate",""],[1,"ix-preview-device-dialog-option-template"]],template:function(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"div",4)(1,"div")(2,"button",5),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r1);let previewDeviceSelect_r2=\u0275\u0275reference(5);return \u0275\u0275resetView(previewDeviceSelect_r2.onContainerClick())}),\u0275\u0275text(3),\u0275\u0275elementEnd(),\u0275\u0275elementStart(4,"mat-select",6,0),\u0275\u0275listener("closed",function(){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView(ctx.handlePreviewDeviceSelectClosed())}),\u0275\u0275elementStart(6,"mat-option",7),\u0275\u0275element(7,"ngx-mat-select-search",8),\u0275\u0275pipe(8,"translate"),\u0275\u0275pipe(9,"translate"),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(10,PreviewDeviceSelectComponent_Conditional_10_Template,3,4,"mat-option",9),\u0275\u0275repeaterCreate(11,PreviewDeviceSelectComponent_For_12_Template,5,6,"mat-option",9,_forTrack08),\u0275\u0275elementEnd()(),\u0275\u0275conditionalCreate(13,PreviewDeviceSelectComponent_Conditional_13_Template,15,12,"div"),\u0275\u0275elementEnd(),\u0275\u0275template(14,PreviewDeviceSelectComponent_ng_template_14_Template,6,6,"ng-template",null,1,\u0275\u0275templateRefExtractor)(16,PreviewDeviceSelectComponent_ng_template_16_Template,6,6,"ng-template",null,2,\u0275\u0275templateRefExtractor)}if(rf&2){let tmp_10_0,deviceDialogOptionTemplate_r16=\u0275\u0275reference(15);\u0275\u0275advance(3),\u0275\u0275textInterpolate1(" ",ctx.previewDeviceSelectTriggerLabel()," "),\u0275\u0275advance(),\u0275\u0275property("formControl",ctx.deviceControl)("ixSelectDialogOptionTemplate",deviceDialogOptionTemplate_r16)("ixSelectDialogSearchPredicate",ctx.deviceSearchPredicate),\u0275\u0275advance(3),\u0275\u0275property("formControl",ctx.queryControl)("placeholderLabel",\u0275\u0275pipeBind1(8,9,"SEARCH"))("noEntriesFoundLabel",\u0275\u0275pipeBind1(9,11,"NO_RESULTS_FOUND")),\u0275\u0275advance(3),\u0275\u0275conditional((tmp_10_0=ctx.noneOption())?10:-1,tmp_10_0),\u0275\u0275advance(),\u0275\u0275repeater(ctx.deviceOptions()),\u0275\u0275advance(2),\u0275\u0275conditional(!ctx.hideSubAssets()&&ctx.selectedDeviceIsAsset()&&ctx.subAssetOptions().length>0?13:-1)}},dependencies:[ReactiveFormsModule,NgControlStatus,FormControlDirective,MatButtonModule,MatButton,MatDividerModule,MatDivider,MatSelectModule,MatSelect,MatOption,NgxMatSelectSearchModule,MatSelectSearchComponent,TranslateModule,TranslateDirective,SelectDialogTriggerDirective,TranslatePipe,HighlightTextPipe],styles:['[_nghost-%COMP%]{display:flex;flex-direction:column;position:relative}[_nghost-%COMP%] .button-group[_ngcontent-%COMP%]{display:flex;padding-right:8px}[_nghost-%COMP%] .button-group[_ngcontent-%COMP%] div[_ngcontent-%COMP%]:first-child:not(:last-child) > .mdc-button[_ngcontent-%COMP%]{padding-left:12px;border-top-right-radius:0;border-bottom-right-radius:0}[_nghost-%COMP%] .button-group[_ngcontent-%COMP%] div[_ngcontent-%COMP%]:not(:first-child) > .mdc-button[_ngcontent-%COMP%]{border-left:0}[_nghost-%COMP%] .button-group[_ngcontent-%COMP%] div[_ngcontent-%COMP%]:last-child:not(:first-child) > .mdc-button[_ngcontent-%COMP%]{border-top-left-radius:0;border-bottom-left-radius:0}[_nghost-%COMP%] .mat-mdc-button-base[_ngcontent-%COMP%]{display:block;padding-left:8px!important;padding-right:24px!important;position:relative}[_nghost-%COMP%] .mat-mdc-button-base[_ngcontent-%COMP%] .mdc-button__label{display:block;overflow-x:hidden;text-overflow:ellipsis}[_nghost-%COMP%] .mat-mdc-button-base[_ngcontent-%COMP%] .mdc-button__label:after{content:"";position:absolute;top:50%;right:8px;margin-top:-2px;border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid currentcolor}[_nghost-%COMP%] .mat-mdc-select[_ngcontent-%COMP%]{position:absolute;visibility:hidden;top:12px;left:0;font-size:14px}@media (min-width: 960px){ .mat-mdc-select-panel.preview-device-select-button-panel{min-width:400px!important;max-width:500px!important}} .mat-mdc-select-panel.preview-device-select-button-panel .mat-mdc-option[role=option]{min-height:32px;padding-top:4px;padding-bottom:4px} .mat-mdc-select-panel.preview-device-select-button-panel .mat-mdc-option div, .ix-preview-device-dialog-option-template div{display:flex;flex-direction:column} .mat-mdc-select-panel.preview-device-select-button-panel .mat-mdc-option span:has(+.match), .ix-preview-device-dialog-option-template span:has(+.match){margin-top:6px;margin-bottom:-2px} .mat-mdc-select-panel.preview-device-select-button-panel .mat-mdc-option .match, .ix-preview-device-dialog-option-template .match{font-size:12px;line-height:14px;margin-bottom:8px;text-wrap:auto}'],changeDetection:0})}}return PreviewDeviceSelectComponent2})();var _c021=()=>[],_c17=()=>({value:"none"});function BuilderComponent_Conditional_0_Conditional_4_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"span"),\u0275\u0275text(1),\u0275\u0275elementEnd()),rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275advance(),\u0275\u0275textInterpolate1(" - ",ctx_r1.componentName)}}function BuilderComponent_Conditional_0_Conditional_14_Template(rf,ctx){if(rf&1){let _r3=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-button-toggle-group",22),\u0275\u0275listener("mousedown",function($event){return \u0275\u0275restoreView(_r3),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementStart(1,"ix-button-toggle",23),\u0275\u0275pipe(2,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r3);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.setPreviewMode($event))}),\u0275\u0275elementStart(3,"mat-icon"),\u0275\u0275text(4,"desktop_windows"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"ix-button-toggle",24),\u0275\u0275pipe(6,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r3);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.setPreviewMode($event))}),\u0275\u0275elementStart(7,"mat-icon"),\u0275\u0275text(8,"smartphone"),\u0275\u0275elementEnd()()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275property("value",ctx_r1.previewMode),\u0275\u0275advance(),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(2,3,"DESKTOP_VIEW")),\u0275\u0275advance(4),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(6,5,"MOBILE_VIEW"))}}function BuilderComponent_Conditional_0_Conditional_15_Template(rf,ctx){if(rf&1){let _r4=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-button-toggle-group",25),\u0275\u0275listener("mousedown",function($event){return \u0275\u0275restoreView(_r4),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementStart(1,"ix-button-toggle",26),\u0275\u0275pipe(2,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r4);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.setOrientation($event))}),\u0275\u0275elementStart(3,"mat-icon"),\u0275\u0275text(4,"crop_portrait"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"ix-button-toggle",27),\u0275\u0275pipe(6,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r4);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.setOrientation($event))}),\u0275\u0275elementStart(7,"mat-icon"),\u0275\u0275text(8,"crop_landscape"),\u0275\u0275elementEnd()()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275property("value",ctx_r1.orientation),\u0275\u0275advance(),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(2,3,"PORTRAIT_ORIENTATION")),\u0275\u0275advance(4),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(6,5,"LANDSCAPE_ORIENTATION"))}}function BuilderComponent_Conditional_0_Conditional_16_Template(rf,ctx){if(rf&1){let _r5=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",28),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r5);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.toggleMode())})("mousedown",function($event){return \u0275\u0275restoreView(_r5),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementStart(1,"mat-icon"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275elementStart(3,"span"),\u0275\u0275text(4),\u0275\u0275pipe(5,"translate"),\u0275\u0275elementEnd()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r1.mode==="preview"?"edit":"visibility"),\u0275\u0275advance(2),\u0275\u0275textInterpolate(\u0275\u0275pipeBind1(5,2,ctx_r1.mode==="preview"?"EDIT":"PREVIEW"))}}function BuilderComponent_Conditional_0_Conditional_36_Conditional_0_Template(rf,ctx){if(rf&1){let _r6=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"mat-toolbar")(1,"h1"),\u0275\u0275text(2),\u0275\u0275elementEnd(),\u0275\u0275element(3,"span",3),\u0275\u0275elementStart(4,"button",30),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r6);let ctx_r1=\u0275\u0275nextContext(3);return \u0275\u0275resetView(ctx_r1.toggleDrawerLock())}),\u0275\u0275elementStart(5,"mat-icon"),\u0275\u0275text(6,"keyboard_arrow_right"),\u0275\u0275elementEnd()()()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275advance(2),\u0275\u0275textInterpolate(ctx_r1.selectedComponentTemplate==null?null:ctx_r1.selectedComponentTemplate.name)}}function BuilderComponent_Conditional_0_Conditional_36_Conditional_2_Template(rf,ctx){if(rf&1){let _r7=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-page-component-properties",31),\u0275\u0275listener("update",function($event){\u0275\u0275restoreView(_r7);let ctx_r1=\u0275\u0275nextContext(3);return \u0275\u0275resetView(ctx_r1.updateComponent($event))}),\u0275\u0275elementEnd()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275property("component",ctx_r1.selectedComponent)("template",ctx_r1.selectedComponentTemplate)}}function BuilderComponent_Conditional_0_Conditional_36_Template(rf,ctx){if(rf&1&&(\u0275\u0275conditionalCreate(0,BuilderComponent_Conditional_0_Conditional_36_Conditional_0_Template,7,1,"mat-toolbar"),\u0275\u0275elementStart(1,"div",17),\u0275\u0275conditionalCreate(2,BuilderComponent_Conditional_0_Conditional_36_Conditional_2_Template,1,2,"ix-page-component-properties",29),\u0275\u0275elementEnd()),rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275conditional(ctx_r1.selectedComponentTemplate!=null&&ctx_r1.selectedComponentTemplate.name?0:-1),\u0275\u0275advance(2),\u0275\u0275conditional(ctx_r1.selectedComponent?2:-1)}}function BuilderComponent_Conditional_0_Conditional_37_Template(rf,ctx){if(rf&1){let _r8=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"button",30),\u0275\u0275listener("click",function(){\u0275\u0275restoreView(_r8);let ctx_r1=\u0275\u0275nextContext(2);return \u0275\u0275resetView(ctx_r1.toggleDrawerLock())}),\u0275\u0275elementStart(1,"mat-icon"),\u0275\u0275text(2,"keyboard_arrow_left"),\u0275\u0275elementEnd()()}}function BuilderComponent_Conditional_0_Case_39_Template(rf,ctx){if(rf&1&&\u0275\u0275elementContainer(0,21),rf&2){\u0275\u0275nextContext();let standaloneContent_r9=\u0275\u0275reference(42);\u0275\u0275property("ngTemplateOutlet",standaloneContent_r9)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_1_Template(rf,ctx){if(rf&1){let _r10=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-component-grid",38),\u0275\u0275listener("selectionChange",function($event){\u0275\u0275restoreView(_r10);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.handleSelectionChange($event))})("componentChanges",function($event){\u0275\u0275restoreView(_r10);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.handleComponentChanges($event))})("movingGridItem",function($event){\u0275\u0275restoreView(_r10);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.setDrawerIsOpen($event))}),\u0275\u0275elementEnd()}if(rf&2){let pageVersion_r11=\u0275\u0275nextContext(3),ctx_r1=\u0275\u0275nextContext();\u0275\u0275classProp("desktop",ctx_r1.previewMode!=="mobile")("mobile",ctx_r1.previewMode==="mobile"),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(pageVersion_r11.previewAgent==null?null:pageVersion_r11.previewAgent.publicId)||(pageVersion_r11.previewAsset==null?null:pageVersion_r11.previewAsset.publicId)||null)("mobile",ctx_r1.previewMode==="mobile")("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)("selectedComponentId",(ctx_r1.selectedComponent==null?null:ctx_r1.selectedComponent.publicId)||null)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_2_Template(rf,ctx){if(rf&1){let _r12=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-card-component-grid",39),\u0275\u0275listener("componentResize",function($event){\u0275\u0275restoreView(_r12);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.updateComponentSize($event))})("selectionChange",function($event){\u0275\u0275restoreView(_r12);let ctx_r1=\u0275\u0275nextContext(4);return \u0275\u0275resetView(ctx_r1.handleSelectionChange($event))}),\u0275\u0275elementEnd()}if(rf&2){let pageVersion_r11=\u0275\u0275nextContext(3),ctx_r1=\u0275\u0275nextContext();\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(ctx_r1.previewAgentOrAsset==null?null:ctx_r1.previewAgentOrAsset.publicId)??null)("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)("selectedComponentId",(ctx_r1.selectedComponent==null?null:ctx_r1.selectedComponent.publicId)??null)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_3_ix_component_grid_0_Template(rf,ctx){if(rf&1){let _r13=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"ix-component-grid",41),\u0275\u0275listener("selectionChange",function($event){\u0275\u0275restoreView(_r13);let ctx_r1=\u0275\u0275nextContext(5);return \u0275\u0275resetView(ctx_r1.handleSelectionChange($event))})("componentChanges",function($event){\u0275\u0275restoreView(_r13);let ctx_r1=\u0275\u0275nextContext(5);return \u0275\u0275resetView(ctx_r1.handleComponentChanges($event))})("movingGridItem",function($event){\u0275\u0275restoreView(_r13);let ctx_r1=\u0275\u0275nextContext(5);return \u0275\u0275resetView(ctx_r1.setDrawerIsOpen($event))}),\u0275\u0275elementEnd()}if(rf&2){let pageVersion_r11=\u0275\u0275nextContext(4),ctx_r1=\u0275\u0275nextContext();\u0275\u0275classMap(ctx_r1.orientation),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(pageVersion_r11.previewAgent==null?null:pageVersion_r11.previewAgent.publicId)||(pageVersion_r11.previewAsset==null?null:pageVersion_r11.previewAsset.publicId)||null)("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)("selectedComponentId",(ctx_r1.selectedComponent==null?null:ctx_r1.selectedComponent.publicId)??null)("orientation",ctx_r1.orientation)("mobile",!1)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_3_Template(rf,ctx){if(rf&1&&\u0275\u0275template(0,BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_3_ix_component_grid_0_Template,1,9,"ix-component-grid",40),rf&2){let ctx_r1=\u0275\u0275nextContext(4);\u0275\u0275property("ixReloadOnValueChange",ctx_r1.orientation)}}function BuilderComponent_Conditional_0_Case_40_Conditional_0_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",34),\u0275\u0275conditionalCreate(1,BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_1_Template,1,10,"ix-component-grid",35),\u0275\u0275conditionalCreate(2,BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_2_Template,1,5,"ix-card-component-grid",36),\u0275\u0275conditionalCreate(3,BuilderComponent_Conditional_0_Case_40_Conditional_0_Conditional_3_Template,1,1,"ix-component-grid",37),\u0275\u0275elementEnd()),rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275classMap(ctx_r1.gridClasses),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="sheet"?1:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="card"?2:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="report"?3:-1)}}function BuilderComponent_Conditional_0_Case_40_Conditional_1_Conditional_1_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",43),\u0275\u0275element(1,"ix-simple-component-grid",45),\u0275\u0275elementEnd()),rf&2){let pageVersion_r11=\u0275\u0275nextContext(3),ctx_r1=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275classMap(ctx_r1.previewMode),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(pageVersion_r11.previewAgent==null?null:pageVersion_r11.previewAgent.publicId)||(pageVersion_r11.previewAsset==null?null:pageVersion_r11.previewAsset.publicId)||null)("mobile",ctx_r1.previewMode==="mobile")("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)}}function BuilderComponent_Conditional_0_Case_40_Conditional_1_Conditional_2_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",44),\u0275\u0275element(1,"ix-simple-card-component-grid",46),\u0275\u0275elementEnd()),rf&2){let pageVersion_r11=\u0275\u0275nextContext(3),ctx_r1=\u0275\u0275nextContext();\u0275\u0275advance(),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope)("agentOrAssetId",(pageVersion_r11.previewAgent==null?null:pageVersion_r11.previewAgent.publicId)||(pageVersion_r11.previewAsset==null?null:pageVersion_r11.previewAsset.publicId)||null)("pageId",ctx_r1.pageId)("pageVersionId",pageVersion_r11.publicId)}}function BuilderComponent_Conditional_0_Case_40_Conditional_1_Template(rf,ctx){if(rf&1&&(\u0275\u0275elementStart(0,"div",42),\u0275\u0275conditionalCreate(1,BuilderComponent_Conditional_0_Case_40_Conditional_1_Conditional_1_Template,2,7,"div",43),\u0275\u0275conditionalCreate(2,BuilderComponent_Conditional_0_Case_40_Conditional_1_Conditional_2_Template,2,4,"div",44),\u0275\u0275elementEnd()),rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275classMap(ctx_r1.applicationType),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="sheet"?1:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="card"?2:-1)}}function BuilderComponent_Conditional_0_Case_40_Template(rf,ctx){if(rf&1&&\u0275\u0275conditionalCreate(0,BuilderComponent_Conditional_0_Case_40_Conditional_0_Template,4,5,"div",32)(1,BuilderComponent_Conditional_0_Case_40_Conditional_1_Template,3,4,"div",33),rf&2){let ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275conditional(ctx_r1.mode==="edit"?0:1)}}function BuilderComponent_Conditional_0_ng_template_41_Conditional_0_ix_component_loader_2_Template(rf,ctx){if(rf&1&&\u0275\u0275element(0,"ix-component-loader",50),rf&2){let component_r15=\u0275\u0275nextContext();\u0275\u0275property("component",component_r15)}}function BuilderComponent_Conditional_0_ng_template_41_Conditional_0_Template(rf,ctx){if(rf&1){let _r14=\u0275\u0275getCurrentView();\u0275\u0275elementContainerStart(0,47),\u0275\u0275elementStart(1,"div",48),\u0275\u0275listener("click",function(){let component_r15=\u0275\u0275restoreView(_r14),ctx_r1=\u0275\u0275nextContext(3);return \u0275\u0275resetView(ctx_r1.handleSelectionChange(component_r15.publicId))}),\u0275\u0275template(2,BuilderComponent_Conditional_0_ng_template_41_Conditional_0_ix_component_loader_2_Template,1,1,"ix-component-loader",49),\u0275\u0275elementEnd(),\u0275\u0275elementContainerEnd()}if(rf&2){let ctx_r1=\u0275\u0275nextContext(3);\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope),\u0275\u0275advance(),\u0275\u0275property("ixComponentGridScope",ctx_r1.gridScope),\u0275\u0275advance(),\u0275\u0275property("ixReloadOnValueChange",ctx)}}function BuilderComponent_Conditional_0_ng_template_41_Template(rf,ctx){if(rf&1&&(\u0275\u0275conditionalCreate(0,BuilderComponent_Conditional_0_ng_template_41_Conditional_0_Template,3,3,"ng-container",47),\u0275\u0275pipe(1,"async")),rf&2){let tmp_4_0,ctx_r1=\u0275\u0275nextContext(2);\u0275\u0275conditional((tmp_4_0=\u0275\u0275pipeBind1(1,1,ctx_r1.component$))?0:-1,tmp_4_0)}}function BuilderComponent_Conditional_0_Template(rf,ctx){if(rf&1){let _r1=\u0275\u0275getCurrentView();\u0275\u0275elementStart(0,"div",1)(1,"mat-toolbar",2)(2,"h1"),\u0275\u0275text(3," Simulator "),\u0275\u0275conditionalCreate(4,BuilderComponent_Conditional_0_Conditional_4_Template,2,1,"span"),\u0275\u0275elementEnd(),\u0275\u0275element(5,"span",3),\u0275\u0275elementStart(6,"button",4)(7,"mat-icon"),\u0275\u0275text(8,"settings"),\u0275\u0275elementEnd()()(),\u0275\u0275elementStart(9,"mat-toolbar",5)(10,"ix-preview-device-select",6),\u0275\u0275pipe(11,"async"),\u0275\u0275listener("selectionChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.selectPreviewAgentOrAsset($event))})("mousedown",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementEnd(),\u0275\u0275element(12,"div",3),\u0275\u0275elementStart(13,"ix-period-controls",7),\u0275\u0275listener("periodSpecSelected",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.updateSelectedPeriodSpec($event))})("mousedown",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementEnd(),\u0275\u0275conditionalCreate(14,BuilderComponent_Conditional_0_Conditional_14_Template,9,7,"ix-button-toggle-group",8),\u0275\u0275conditionalCreate(15,BuilderComponent_Conditional_0_Conditional_15_Template,9,7,"ix-button-toggle-group",9),\u0275\u0275conditionalCreate(16,BuilderComponent_Conditional_0_Conditional_16_Template,6,4,"button",10),\u0275\u0275elementStart(17,"ix-button-toggle-group",11),\u0275\u0275listener("mousedown",function($event){return \u0275\u0275restoreView(_r1),\u0275\u0275resetView($event.stopPropagation())}),\u0275\u0275elementStart(18,"ix-button-toggle",12),\u0275\u0275pipe(19,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.setApplicationType($event))}),\u0275\u0275elementStart(20,"mat-icon"),\u0275\u0275text(21,"dashboard"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(22,"ix-button-toggle",13),\u0275\u0275pipe(23,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.setApplicationType($event))}),\u0275\u0275element(24,"mat-icon",14),\u0275\u0275elementEnd(),\u0275\u0275elementStart(25,"ix-button-toggle",15),\u0275\u0275pipe(26,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.setApplicationType($event))}),\u0275\u0275elementStart(27,"mat-icon"),\u0275\u0275text(28,"draft"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(29,"ix-button-toggle",16),\u0275\u0275pipe(30,"translate"),\u0275\u0275listener("valueChange",function($event){\u0275\u0275restoreView(_r1);let ctx_r1=\u0275\u0275nextContext();return \u0275\u0275resetView(ctx_r1.setApplicationType($event))}),\u0275\u0275elementStart(31,"mat-icon"),\u0275\u0275text(32,"fit_screen"),\u0275\u0275elementEnd()()()(),\u0275\u0275elementStart(33,"div",17)(34,"mat-drawer-container")(35,"mat-drawer",18),\u0275\u0275conditionalCreate(36,BuilderComponent_Conditional_0_Conditional_36_Template,3,2)(37,BuilderComponent_Conditional_0_Conditional_37_Template,3,0,"button",19),\u0275\u0275elementEnd(),\u0275\u0275elementStart(38,"mat-drawer-content",20),\u0275\u0275conditionalCreate(39,BuilderComponent_Conditional_0_Case_39_Template,1,1,"ng-container",21)(40,BuilderComponent_Conditional_0_Case_40_Template,2,1),\u0275\u0275template(41,BuilderComponent_Conditional_0_ng_template_41_Template,2,3,"ng-template",null,0,\u0275\u0275templateRefExtractor),\u0275\u0275elementEnd()()()()}if(rf&2){let tmp_21_0,ctx_r1=\u0275\u0275nextContext();\u0275\u0275advance(4),\u0275\u0275conditional(ctx_r1.componentName?4:-1),\u0275\u0275advance(6),\u0275\u0275property("agentAndRootAssets",\u0275\u0275pipeBind1(11,21,ctx_r1.previewAgentsOrAssets$)??\u0275\u0275pureFunction0(31,_c021))("noneOption",\u0275\u0275pureFunction0(32,_c17))("value",(ctx_r1.previewAgentOrAsset==null?null:ctx_r1.previewAgentOrAsset.publicId)??""),\u0275\u0275advance(3),\u0275\u0275property("deviceTimeZone",null)("periodSpecs",ctx_r1.periodSpecs),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="sheet"?14:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="report"?15:-1),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.applicationType==="sheet"||ctx_r1.applicationType==="card"?16:-1),\u0275\u0275advance(),\u0275\u0275property("value",ctx_r1.applicationType),\u0275\u0275advance(),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(19,23,"PAGE")),\u0275\u0275advance(4),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(23,25,"CARD")),\u0275\u0275advance(3),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(26,27,"REPORT")),\u0275\u0275advance(4),\u0275\u0275property("matTooltip",\u0275\u0275pipeBind1(30,29,"STANDALONE")),\u0275\u0275advance(6),\u0275\u0275classProp("locked-drawer",ctx_r1.drawerLockedClose)("open-drawer",ctx_r1.selectedComponent&&!ctx_r1.drawerLockedClose),\u0275\u0275property("opened",ctx_r1.selectedComponent&&ctx_r1.drawerIsOpen&&ctx_r1.mode==="edit"),\u0275\u0275advance(),\u0275\u0275conditional(ctx_r1.selectedComponent&&!ctx_r1.drawerLockedClose?36:37),\u0275\u0275advance(3),\u0275\u0275conditional((tmp_21_0=ctx_r1.applicationType)==="standalone"?39:40)}}var BuilderComponent=(()=>{class BuilderComponent2{constructor(){this.activePeriodSpec=inject(ActivePeriodSpec),this.cdRef=inject(ChangeDetectorRef),this.destroy=inject(DestroyRef),this.facade=inject(BuilderFacade),this.sessionStorage=inject(SESSION_STORAGE),this.applicationType=this.sessionStorage.getItem("application-type")||"sheet",this.orientation=this.sessionStorage.getItem("orientation")||"portrait",this.drawerLockedClose=!1,this.gridScope="simulator",this.mode=this.sessionStorage.getItem("mode")||"edit",this.previewMode=this.sessionStorage.getItem("preview-mode")||"desktop",this.drawerIsOpen=!0,this.selectedComponentId$=new BehaviorSubject(null),this.busyUpdating$=this.facade.busyUpdating$,this.component$=this.facade.getComponent(this.pageId),this.pageVersion$=this.facade.draftVersionByPageId(this.pageId),this.previewAgentsOrAssets$=this.facade.previewAgentsOrAssets$,this.previewAgentOrAsset$=this.facade.previewAgentOrAsset(this.pageVersion$)}get gridClasses(){return this.previewMode==="mobile"?["mobile"]:[]}get pageId(){return"page"}ngOnInit(){this.pageVersion$.pipe(takeUntilDestroyed(this.destroy)).subscribe(pageVersion=>{this.pageVersion=pageVersion,this.pageVersionId=pageVersion.publicId,pageVersion.previewAsset&&this.facade.loadOneAsset(pageVersion.previewAsset.publicId)}),this.facade.selectedPeriodSpec(of(this.pageId)).pipe(takeUntilDestroyed(this.destroy)).subscribe(periodSpec=>{this.periodSpecs=__spreadProps(__spreadValues({},this.periodSpecs),{selected:periodSpec}),this.activePeriodSpec.setPeriodSpec(periodSpec,this.gridScope),this.zoomOutIsVisible=this.getZoomOutIsVisible(),this.cdRef.markForCheck()}),this.activePeriodSpec.inScopeOf(this.gridScope).pipe(takeUntilDestroyed(this.destroy)).subscribe(periodSpec=>{this.periodSpecs=__spreadProps(__spreadValues({},this.periodSpecs),{active:periodSpec}),this.zoomOutIsVisible=this.getZoomOutIsVisible(),this.cdRef.markForCheck()}),this.selectedComponentId$.pipe(distinctUntilChanged(),switchMap(id=>combineLatest([this.facade.pageComponent(id),this.facade.pageComponentTemplate(id)])),takeUntilDestroyed(this.destroy)).subscribe(([component,template])=>{this.selectedComponent=component,this.selectedComponentTemplate=template,this.cdRef.markForCheck()}),this.previewAgentOrAsset$.pipe(takeUntilDestroyed(this.destroy)).subscribe(agentOrAsset=>{this.previewAgentOrAsset=agentOrAsset;let rootAssetId=agentOrAsset&&"root"in agentOrAsset?agentOrAsset.root?.publicId||agentOrAsset.publicId:void 0;this.facade.loadAssetsForRoot(rootAssetId),this.cdRef.markForCheck()}),this.facade.getComponentName(this.pageId).pipe(takeUntilDestroyed(this.destroy)).subscribe(name=>{this.componentName=name}),this.facade.loadAgents(),this.facade.loadRootAssets(),this.facade.loadCustomProperties(),this.facade.loadGroups(),this.facade.loadPageComponentTemplates(),this.facade.loadPage(this.pageId),this.facade.loadRoles(),this.destroy.onDestroy(()=>{this.facade.reset()})}handleSelectionChange(componentId){this.selectedComponentId$.next(componentId)}handleComponentChanges(components){let updates=components.reduce((acc,component)=>this.previewMode==="desktop"&&component.dimensions?.type==="sheet"?[...acc,pick_default(component,["publicId","dimensions.type","dimensions.left","dimensions.top","dimensions.rows","dimensions.cols"])]:this.previewMode==="mobile"&&component.dimensions?.type==="sheet"?[...acc,pick_default(component,["publicId","dimensions.type","dimensions.mobileCols","dimensions.mobileHeight","dimensions.mobileLeft","dimensions.mobileOrder"])]:component.dimensions?.type==="report"?[...acc,pick_default(component,["publicId","dimensions.type","dimensions.left","dimensions.top","dimensions.rows","dimensions.cols"])]:acc,[]);updates.length>0&&(updates.length===1?this.facade.updateComponent(updates[0].publicId,omit_default(updates[0],["publicId"])):this.facade.updateComponentList(updates))}updateComponent(component){this.facade.updateComponent(component.publicId,omit_default(component,["publicId"]))}updateComponentSize({componentId,height}){this.facade.updateComponent(componentId,{dimensions:{type:"card",height}})}selectPreviewAgentOrAsset(publicId){this.previewAgentOrAsset?.publicId!==publicId&&this.facade.updatePreviewAgentOrAsset(this.pageVersionId,publicId==="none"?null:publicId)}setApplicationType(newApplicationType){this.applicationType=newApplicationType,this.sessionStorage.setItem("application-type",newApplicationType),this.facade.reloadDimensions(this.pageId,newApplicationType),this.facade.updateApplicationType(this.pageId,newApplicationType);let mode=null,remember=!0;switch(newApplicationType){case"report":mode="edit",remember=!1;break;case"standalone":mode="preview",remember=!1;break}mode||(mode=this.sessionStorage.getItem("mode")||null),mode&&this.setMode(mode,remember)}setPreviewMode(newPreviewMode){this.previewMode=newPreviewMode,this.sessionStorage.setItem("preview-mode",newPreviewMode)}setOrientation(newOrientation){this.orientation=newOrientation,this.sessionStorage.setItem("orientation",newOrientation);let component=this.pageVersion.components?.[0];component?.dimensions?.type==="report"&&this.facade.updateComponent(component.publicId,{dimensions:__spreadProps(__spreadValues({},component.dimensions),{type:"report",left:0,top:3,cols:newOrientation==="landscape"?8:6,rows:6})})}getZoomOutIsVisible(){return this.periodSpecs?!isEqual_default(this.periodSpecs.active,this.periodSpecs.selected):!1}setMode(newMode,rememberMode=!0){this.mode=newMode,rememberMode&&this.sessionStorage.setItem("mode",newMode)}setDrawerIsOpen(gridItemIsMoving){this.drawerIsOpen=!gridItemIsMoving}toggleDrawerLock(){this.drawerLockedClose=!this.drawerLockedClose}toggleMode(){this.setMode(this.mode==="preview"?"edit":"preview")}updateSelectedPeriodSpec(periodSpec){this.facade.updateSelectedPeriodSpec(periodSpec)}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||BuilderComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:BuilderComponent2,selectors:[["ix-builder"]],viewQuery:function(rf,ctx){if(rf&1&&\u0275\u0275viewQuery(ComponentGridComponent,5),rf&2){let _t;\u0275\u0275queryRefresh(_t=\u0275\u0275loadQuery())&&(ctx.componentGrid=_t.first)}},decls:2,vars:3,consts:[["standaloneContent",""],["fxFlex","","fxLayout","column",1,"ix-surface"],["ixComponentGridFocus",""],["fxFlex",""],["mat-icon-button","","routerLink","/settings","matTooltip","Settings"],["ixComponentGridFocus","",1,"second"],[3,"selectionChange","mousedown","agentAndRootAssets","noneOption","value"],[3,"periodSpecSelected","mousedown","deviceTimeZone","periodSpecs"],[1,"screen-toggle-group",3,"value"],[1,"orientation-toggle-group",3,"value"],["mat-stroked-button","","type","button",1,"mode-button"],[1,"application-type-toggle-group",3,"mousedown","value"],["value","sheet",3,"valueChange","matTooltip"],["value","card",3,"valueChange","matTooltip"],["svgIcon","card_outline"],["value","report",3,"valueChange","matTooltip"],["value","standalone",3,"valueChange","matTooltip"],["fxFlex","",1,"ix-content"],["mode","over","position","end",3,"opened"],["mat-icon-button","","disableRipple","true"],["fxLayout","column"],[3,"ngTemplateOutlet"],[1,"screen-toggle-group",3,"mousedown","value"],["value","desktop",3,"valueChange","matTooltip"],["value","mobile",3,"valueChange","matTooltip"],[1,"orientation-toggle-group",3,"mousedown","value"],["value","portrait",3,"valueChange","matTooltip"],["value","landscape",3,"valueChange","matTooltip"],["mat-stroked-button","","type","button",1,"mode-button",3,"click","mousedown"],[3,"component","template"],["mat-icon-button","","disableRipple","true",3,"click"],[3,"update","component","template"],["ixComponentGridFocus","",1,"grid-container",3,"class"],[1,"preview-grid-container",3,"class"],["ixComponentGridFocus","",1,"grid-container"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage",3,"ixComponentGridScope","agentOrAssetId","mobile","pageId","pageVersionId","selectedComponentId","desktop"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","","ixComponentGridMode","edit","pagePageId","pagepage",3,"ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage","applicationType","report",1,"report-grid","mat-elevation-z2",3,"ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId","class","orientation","mobile"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage",3,"selectionChange","componentChanges","movingGridItem","ixComponentGridScope","agentOrAssetId","mobile","pageId","pageVersionId","selectedComponentId"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","","ixComponentGridMode","edit","pagePageId","pagepage",3,"componentResize","selectionChange","ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage","class","report-grid mat-elevation-z2","applicationType","report",3,"ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId","class","orientation","mobile","selectionChange","componentChanges","movingGridItem",4,"ixReloadOnValueChange"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentGridMode","edit","ixComponentContextCleanup","","pagePageId","pagepage","applicationType","report",1,"report-grid","mat-elevation-z2",3,"selectionChange","componentChanges","movingGridItem","ixComponentGridScope","agentOrAssetId","pageId","pageVersionId","selectedComponentId","orientation","mobile"],[1,"preview-grid-container"],[1,"ix-large-section","preview"],[1,"preview"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","","ixComponentGridMode","view",3,"ixComponentGridScope","agentOrAssetId","mobile","pageId","pageVersionId"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","","ixComponentGridMode","view",3,"ixComponentGridScope","agentOrAssetId","pageId","pageVersionId"],[3,"ixComponentGridScope"],["ixBackendComponentBroker","","ixLoggingDataBroker","","ixResourceDataBroker","","ixObjectStorageBroker","","ixComponentContextCleanup","",1,"standalone",3,"click","ixComponentGridScope"],[3,"component",4,"ixReloadOnValueChange"],[3,"component"]],template:function(rf,ctx){if(rf&1&&(\u0275\u0275conditionalCreate(0,BuilderComponent_Conditional_0_Template,43,33,"div",1),\u0275\u0275pipe(1,"async")),rf&2){let tmp_0_0;\u0275\u0275conditional((tmp_0_0=\u0275\u0275pipeBind1(1,1,ctx.pageVersion$))?0:-1,tmp_0_0)}},dependencies:[AlertDialogModule,ButtonToggleModule,ButtonToggleComponent,ButtonToggleGroupComponent,ComponentLoaderModule,ComponentLoaderComponent,PreviewDeviceSelectComponent,FlexModule,DefaultLayoutDirective,DefaultFlexDirective,MatButtonModule,MatButton,MatIconButton,MatFormFieldModule,MatIconModule,MatIcon,MatInputModule,MatSidenavModule,MatDrawer,MatDrawerContainer,MatDrawerContent,MatToolbarModule,MatToolbar,MatTooltipModule,MatTooltip,NgTemplateOutlet,PagesModule,ComponentGridComponent,CardComponentGridComponent,SimpleComponentGridComponent,SimpleCardComponentGridComponent,ComponentPropertiesComponent,ComponentGridModeDirective,ComponentGridScopeDirective,ComponentContextCleanupDirective,BackendComponentBrokerDirective,LoggingDataBrokerDirective,ObjectStorageBrokerDirective,ResourceDataBrokerDirective,PeriodControlsComponent,ComponentGridFocusDirective,PeriodFieldsetModule,ReloadOnValueChangeDirective,RouterModule,RouterLink,TranslateModule,AsyncPipe,TranslatePipe],styles:['[_nghost-%COMP%]{height:100%;width:100%}[_nghost-%COMP%] .mat-toolbar[_ngcontent-%COMP%]{border-bottom:1px solid var(--mat-sys-surface-variant)}[_nghost-%COMP%] .mat-toolbar[_ngcontent-%COMP%] h1[_ngcontent-%COMP%]{padding-right:16px}[_nghost-%COMP%] .mat-toolbar[_ngcontent-%COMP%] ix-device-select-button[_ngcontent-%COMP%]{margin-right:8px;max-width:calc(100% - 340px)}[_nghost-%COMP%] .mat-toolbar.second[_ngcontent-%COMP%]{--mat-toolbar-standard-height: 56px;--mat-button-outlined-container-height: 36px;border-bottom:1px solid var(--mat-sys-surface-variant)}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%]{height:100%}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer-backdrop{display:none}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%]{height:100%;width:300px;border-left:1px solid var(--mat-sys-surface-variant)}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%] .mat-drawer-inner-container{height:100%;flex-direction:column}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%] .mat-drawer-inner-container>.mat-toolbar{height:40px!important}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%] .mat-drawer-inner-container>.mat-toolbar h1{color:var(--body-color);font-size:16px;font-weight:400}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer.locked-drawer[_ngcontent-%COMP%]{--mat-sidenav-container-elevation-shadow: 0px 8px 10px -5px rgb(0 0 0 / 20%), 0px 16px 24px 2px rgb(0 0 0 / 14%), 0px 6px 30px 5px rgb(0 0 0 / 12%);width:50px;height:40px;border-top-left-radius:25px;border-bottom-left-radius:25px;border-left:none}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .mat-drawer[_ngcontent-%COMP%] .mat-mdc-icon-button[_ngcontent-%COMP%] .mat-mdc-button-focus-overlay{display:none}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%]{height:100%;overflow-x:auto;background-color:#f5f5f5}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] .grid[_ngcontent-%COMP%]{height:100%}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{margin:0 auto;height:100%}@media (min-width: 960px){[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{max-width:970px}}@media (min-width: 1280px){[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{max-width:1200px}}@media (min-width: 1920px){[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{max-width:1600px}}@media screen and (min-width: 2251px){[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid[_ngcontent-%COMP%]{max-width:2000px}}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid.desktop[_ngcontent-%COMP%]{min-width:970px}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .grid-container[_ngcontent-%COMP%] ix-component-grid.mobile[_ngcontent-%COMP%]{max-width:480px}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%]{height:100%;width:100%;box-sizing:border-box;overflow-x:auto;display:flex;flex-direction:column;background-color:var(--detail-page-bg);--uic-color-scheme: var(--card-color-scheme);--uic-background: var(--card-bg);--uic-on-background: var(--card-color)}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container.card[_ngcontent-%COMP%]{place-content:center}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container.card[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%]{display:flex;place-items:center}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%]{height:100%}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%] ix-simple-component-grid[_ngcontent-%COMP%]{height:100%;box-sizing:border-box;margin:0 auto}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%] ix-simple-component-grid.desktop[_ngcontent-%COMP%]{min-width:970px}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%] ix-simple-component-grid.mobile[_ngcontent-%COMP%]{max-width:480px;border-left:1px solid rgba(0,0,0,.08);border-right:1px solid rgba(0,0,0,.08)}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .preview-grid-container[_ngcontent-%COMP%] .preview[_ngcontent-%COMP%] ix-simple-card-component-grid[_ngcontent-%COMP%]{width:300px;padding:0;margin:0 auto;box-sizing:border-box;background-color:var(--card-bg);color:var(--card-color);color-scheme:var(--card-color-scheme);border:var(--card-border-width) solid var(--card-border-color);border-radius:8px}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .standalone[_ngcontent-%COMP%]{height:100%}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] .standalone[_ngcontent-%COMP%] ix-component-loader[_ngcontent-%COMP%]{overflow:auto}[_nghost-%COMP%] .mat-drawer-container[_ngcontent-%COMP%] ix-page-properties[_ngcontent-%COMP%]{padding:20px 16px}[_nghost-%COMP%] .select-button[_ngcontent-%COMP%]{padding-left:8px;padding-right:2px;margin-right:8px}[_nghost-%COMP%] .select-button[_ngcontent-%COMP%] .mat-icon[_ngcontent-%COMP%]:first-child{margin-right:6px}[_nghost-%COMP%] .screen-toggle-group[_ngcontent-%COMP%], [_nghost-%COMP%] .orientation-toggle-group[_ngcontent-%COMP%], [_nghost-%COMP%] .application-type-toggle-group[_ngcontent-%COMP%]{margin-left:12px}[_nghost-%COMP%] .mode-button[_ngcontent-%COMP%]{margin-left:12px}[_nghost-%COMP%] .mode-button[_ngcontent-%COMP%] .mat-icon[_ngcontent-%COMP%]:first-child{margin-right:6px}[_nghost-%COMP%] .report-grid[_ngcontent-%COMP%]{--card-bg: #fff;--card-border-color: rgb(0 0 0 / 12%);--card-border-width: 1px;--card-color: rgb(0 0 0 / 87%);--card-color-scheme: "light";--uic-color-scheme: var(--card-color-scheme);--uic-background: var(--card-bg);--uic-on-background: var(--card-color);margin:16px auto!important;background:#fff;height:842pt!important;width:595pt}[_nghost-%COMP%] .report-grid.landscape[_ngcontent-%COMP%]{height:595pt!important;width:842pt}[_nghost-%COMP%] .report-grid[_ngcontent-%COMP%] .canvas gridster .gridster-row{width:calc(100% - 76px)!important}[_nghost-%COMP%] .report-grid[_ngcontent-%COMP%] .gridster-column, [_nghost-%COMP%] .report-grid[_ngcontent-%COMP%] .gridster-row{border-color:#00000014}'],changeDetection:0})}}return BuilderComponent2})();var BuilderGuard=(()=>{class BuilderGuard2{constructor(){this.store=inject(Store)}canActivate(){return forkJoin([this.getMyUser(),this.getMyCompany()]).pipe(map(()=>!0),take(1))}getMyUser(){return this._loadIfAbsent(selectMyUser,loadMe3())}getMyCompany(){return this._loadIfAbsent(selectMyCompany,loadMe())}_loadIfAbsent(selector3,action){return this.store.select(selector3).pipe(tap(entity=>{entity||this.store.dispatch(action)}),first(entity=>!!entity),map(()=>!0))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||BuilderGuard2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:BuilderGuard2,factory:BuilderGuard2.\u0275fac,providedIn:"root"})}}return BuilderGuard2})();var LoginExpiredComponent=(()=>{class LoginExpiredComponent3{constructor(){this.document=inject(DOCUMENT),this.storage=inject(StorageService)}useMockData(){this.storage.forget("api-data-provider"),this.storage.forget("company"),this.reload()}reload(){this.document.location.href="/"}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LoginExpiredComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:LoginExpiredComponent3,selectors:[["ix-login-expired"]],standalone:!1,decls:18,vars:0,consts:[["fxFlex","","fxLayout","column","fxLayoutAlign","center center",1,"ix-surface"],[1,"ix-status-card"],[1,"ix-status-card__icon"],["type","button","mat-button","","color","primary",3,"click"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"div",0)(1,"mat-card",1)(2,"div",2)(3,"mat-icon"),\u0275\u0275text(4,"error"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"mat-card-header")(6,"mat-card-title"),\u0275\u0275text(7,"Login expired"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(8,"mat-card-subtitle"),\u0275\u0275text(9," Please re-authenticate via the command line "),\u0275\u0275elementStart(10,"pre"),\u0275\u0275text(11,"npx cdk login"),\u0275\u0275elementEnd(),\u0275\u0275text(12," and reload or revert to using API mock data. "),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(13,"mat-card-actions")(14,"button",3),\u0275\u0275listener("click",function(){return ctx.useMockData()}),\u0275\u0275text(15,"Use mock data"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(16,"button",3),\u0275\u0275listener("click",function(){return ctx.reload()}),\u0275\u0275text(17,"Reload"),\u0275\u0275elementEnd()()()())},dependencies:[DefaultLayoutDirective,DefaultLayoutAlignDirective,DefaultFlexDirective,MatButton,MatCard,MatCardActions,MatCardHeader,MatCardSubtitle,MatCardTitle,MatIcon],styles:["[_nghost-%COMP%]{width:100%;height:100%}"],changeDetection:0})}}return LoginExpiredComponent3})();var LoginExpiredCanActivateGuard=(()=>{class LoginExpiredCanActivateGuard2{constructor(){this.router=inject(Router),this.storage=inject(StorageService)}canActivate(route){return this.isAuthenticated(route)}isAuthenticated(route){return of(this.storage.has("auth")).pipe(tap(authenticated=>{if(authenticated)if(route.queryParamMap.has("next")){let next=route.queryParams.next;this.router.navigateByUrl(next).then(success=>{success||this.router.navigate(["/"])})}else this.router.navigate(["/"])}),map(authenticated=>!authenticated))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LoginExpiredCanActivateGuard2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:LoginExpiredCanActivateGuard2,factory:LoginExpiredCanActivateGuard2.\u0275fac,providedIn:"root"})}}return LoginExpiredCanActivateGuard2})();var LoginExpiredModule=(()=>{class LoginExpiredModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||LoginExpiredModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:LoginExpiredModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[SharedModule]})}}return LoginExpiredModule2})();var ManifestInvalidComponent=(()=>{class ManifestInvalidComponent3{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||ManifestInvalidComponent3)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:ManifestInvalidComponent3,selectors:[["ix-manifest-invalid"]],standalone:!1,decls:13,vars:0,consts:[["fxFlex","","fxLayout","column","fxLayoutAlign","center center",1,"ix-surface"],[1,"ix-status-card"],[1,"ix-status-card__icon"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"div",0)(1,"mat-card",1)(2,"div",2)(3,"mat-icon"),\u0275\u0275text(4,"error"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"mat-card-header")(6,"mat-card-title"),\u0275\u0275text(7,"Manifest invalid"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(8,"mat-card-subtitle"),\u0275\u0275text(9," Schema validation for the "),\u0275\u0275elementStart(10,"pre"),\u0275\u0275text(11,"manifest.json"),\u0275\u0275elementEnd(),\u0275\u0275text(12," file failed. "),\u0275\u0275elementEnd()()()())},dependencies:[DefaultLayoutDirective,DefaultLayoutAlignDirective,DefaultFlexDirective,MatCard,MatCardHeader,MatCardSubtitle,MatCardTitle,MatIcon],styles:["[_nghost-%COMP%]{width:100%;height:100%}"],changeDetection:0})}}return ManifestInvalidComponent3})();var TwoFactorAuthRequiredComponent=(()=>{class TwoFactorAuthRequiredComponent2{constructor(){this.document=inject(DOCUMENT),this.storage=inject(StorageService)}switchCompany(){this.storage.forget("api-data-provider"),this.storage.forget("company"),this.document.location.href="/settings/general"}useMockData(){this.storage.forget("api-data-provider"),this.storage.forget("company"),this.document.location.href="/"}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||TwoFactorAuthRequiredComponent2)}}static{this.\u0275cmp=\u0275\u0275defineComponent({type:TwoFactorAuthRequiredComponent2,selectors:[["ix-two-factor-auth-required"]],decls:13,vars:0,consts:[["fxFlex","","fxLayout","column","fxLayoutAlign","center center",1,"ix-surface"],[1,"ix-status-card"],[1,"ix-status-card__icon"],["type","button","mat-button","","color","primary",3,"click"]],template:function(rf,ctx){rf&1&&(\u0275\u0275elementStart(0,"div",0)(1,"mat-card",1)(2,"div",2)(3,"mat-icon"),\u0275\u0275text(4,"error"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(5,"mat-card-header")(6,"mat-card-title"),\u0275\u0275text(7,"Two-factor authentication is required"),\u0275\u0275elementEnd()(),\u0275\u0275elementStart(8,"mat-card-actions")(9,"button",3),\u0275\u0275listener("click",function(){return ctx.useMockData()}),\u0275\u0275text(10,"Use mock data"),\u0275\u0275elementEnd(),\u0275\u0275elementStart(11,"button",3),\u0275\u0275listener("click",function(){return ctx.switchCompany()}),\u0275\u0275text(12,"Switch company"),\u0275\u0275elementEnd()()()())},dependencies:[FlexModule,DefaultLayoutDirective,DefaultLayoutAlignDirective,DefaultFlexDirective,MatButtonModule,MatButton,MatCardModule,MatCard,MatCardActions,MatCardHeader,MatCardTitle,MatIconModule,MatIcon],styles:["[_nghost-%COMP%]{width:100%;height:100%}"],changeDetection:0})}}return TwoFactorAuthRequiredComponent2})();var routes=[{path:"",canActivate:[AppGuard],children:[{path:"",component:BuilderComponent,canActivate:__use_api_mocks__?[BuilderGuard]:[AuthCompanyGuard,BuilderGuard]},{path:"settings",loadChildren:()=>import("./chunk-TLURIQWS.js").then(m=>m.SettingsModule)},...__use_api_mocks__?[]:[{path:"login",component:LoginExpiredComponent,canActivate:[LoginExpiredCanActivateGuard]},{path:"my-companies",redirectTo:"settings"},{path:"two-factor-auth-required",component:TwoFactorAuthRequiredComponent}]]},{path:"manifest-invalid",component:ManifestInvalidComponent},{path:"**",redirectTo:""}];var AppRoutingConfig={routerState:RouterState?.Minimal,serializer:CustomRouterStateSerializer};var AppRoutingModule=(()=>{class AppRoutingModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||AppRoutingModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:AppRoutingModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[RouterModule.forRoot(routes,{bindToComponentInputs:!0,onSameUrlNavigation:"reload",preloadingStrategy:CustomPreloadingStrategy}),StoreRouterConnectingModule.forRoot(AppRoutingConfig),RouterModule]})}}return AppRoutingModule2})();var PERFORM_ACTION="PERFORM_ACTION",REFRESH="REFRESH",RESET="RESET",ROLLBACK="ROLLBACK",COMMIT="COMMIT",SWEEP="SWEEP",TOGGLE_ACTION="TOGGLE_ACTION",SET_ACTIONS_ACTIVE="SET_ACTIONS_ACTIVE",JUMP_TO_STATE="JUMP_TO_STATE",JUMP_TO_ACTION="JUMP_TO_ACTION",IMPORT_STATE="IMPORT_STATE",LOCK_CHANGES="LOCK_CHANGES",PAUSE_RECORDING="PAUSE_RECORDING",PerformAction=class{constructor(action,timestamp2){if(this.action=action,this.timestamp=timestamp2,this.type=PERFORM_ACTION,typeof action.type>"u")throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?')}},Refresh=class{constructor(){this.type=REFRESH}},Reset=class{constructor(timestamp2){this.timestamp=timestamp2,this.type=RESET}},Rollback=class{constructor(timestamp2){this.timestamp=timestamp2,this.type=ROLLBACK}},Commit=class{constructor(timestamp2){this.timestamp=timestamp2,this.type=COMMIT}},Sweep=class{constructor(){this.type=SWEEP}},ToggleAction=class{constructor(id){this.id=id,this.type=TOGGLE_ACTION}};var JumpToState=class{constructor(index){this.index=index,this.type=JUMP_TO_STATE}},JumpToAction=class{constructor(actionId){this.actionId=actionId,this.type=JUMP_TO_ACTION}},ImportState=class{constructor(nextLiftedState){this.nextLiftedState=nextLiftedState,this.type=IMPORT_STATE}},LockChanges=class{constructor(status){this.status=status,this.type=LOCK_CHANGES}},PauseRecording=class{constructor(status){this.status=status,this.type=PAUSE_RECORDING}};var STORE_DEVTOOLS_CONFIG=new InjectionToken("@ngrx/store-devtools Options"),INITIAL_OPTIONS=new InjectionToken("@ngrx/store-devtools Initial Config");function noMonitor(){return null}var DEFAULT_NAME="NgRx Store DevTools";function createConfig(optionsInput){let DEFAULT_OPTIONS2={maxAge:!1,monitor:noMonitor,actionSanitizer:void 0,stateSanitizer:void 0,name:DEFAULT_NAME,serialize:!1,logOnly:!1,autoPause:!1,trace:!1,traceLimit:75,features:{pause:!0,lock:!0,persist:!0,export:!0,import:"custom",jump:!0,skip:!0,reorder:!0,dispatch:!0,test:!0},connectInZone:!1},options=typeof optionsInput=="function"?optionsInput():optionsInput,logOnly=options.logOnly?{pause:!0,export:!0,test:!0}:!1,features2=options.features||logOnly||DEFAULT_OPTIONS2.features;features2.import===!0&&(features2.import="custom");let config3=Object.assign({},DEFAULT_OPTIONS2,{features:features2},options);if(config3.maxAge&&config3.maxAge<2)throw new Error(`Devtools 'maxAge' cannot be less than 2, got ${config3.maxAge}`);return config3}function difference(first2,second){return first2.filter(item=>second.indexOf(item)<0)}function unliftState(liftedState){let{computedStates,currentStateIndex}=liftedState;if(currentStateIndex>=computedStates.length){let{state:state2}=computedStates[computedStates.length-1];return state2}let{state}=computedStates[currentStateIndex];return state}function liftAction(action){return new PerformAction(action,+Date.now())}function sanitizeActions(actionSanitizer,actions){return Object.keys(actions).reduce((sanitizedActions,actionIdx)=>{let idx=Number(actionIdx);return sanitizedActions[idx]=sanitizeAction(actionSanitizer,actions[idx],idx),sanitizedActions},{})}function sanitizeAction(actionSanitizer,action,actionIdx){return __spreadProps(__spreadValues({},action),{action:actionSanitizer(action.action,actionIdx)})}function sanitizeStates(stateSanitizer,states){return states.map((computedState,idx)=>({state:sanitizeState(stateSanitizer,computedState.state,idx),error:computedState.error}))}function sanitizeState(stateSanitizer,state,stateIdx){return stateSanitizer(state,stateIdx)}function shouldFilterActions(config3){return config3.predicate||config3.actionsSafelist||config3.actionsBlocklist}function filterLiftedState(liftedState,predicate,safelist,blocklist){let filteredStagedActionIds=[],filteredActionsById={},filteredComputedStates=[];return liftedState.stagedActionIds.forEach((id,idx)=>{let liftedAction=liftedState.actionsById[id];liftedAction&&(idx&&isActionFiltered(liftedState.computedStates[idx],liftedAction,predicate,safelist,blocklist)||(filteredActionsById[id]=liftedAction,filteredStagedActionIds.push(id),filteredComputedStates.push(liftedState.computedStates[idx])))}),__spreadProps(__spreadValues({},liftedState),{stagedActionIds:filteredStagedActionIds,actionsById:filteredActionsById,computedStates:filteredComputedStates})}function isActionFiltered(state,action,predicate,safelist,blockedlist){let predicateMatch=predicate&&!predicate(state,action.action),safelistMatch=safelist&&!action.action.type.match(safelist.map(s2=>escapeRegExp(s2)).join("|")),blocklistMatch=blockedlist&&action.action.type.match(blockedlist.map(s2=>escapeRegExp(s2)).join("|"));return predicateMatch||safelistMatch||blocklistMatch}function escapeRegExp(s2){return s2.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function injectZoneConfig(connectInZone){return{ngZone:connectInZone?inject(NgZone):null,connectInZone}}var DevtoolsDispatcher=(()=>{class DevtoolsDispatcher2 extends ActionsSubject{static{this.\u0275fac=(()=>{let \u0275DevtoolsDispatcher_BaseFactory;return function(__ngFactoryType__){return(\u0275DevtoolsDispatcher_BaseFactory||(\u0275DevtoolsDispatcher_BaseFactory=\u0275\u0275getInheritedFactory(DevtoolsDispatcher2)))(__ngFactoryType__||DevtoolsDispatcher2)}})()}static{this.\u0275prov=\u0275\u0275defineInjectable({token:DevtoolsDispatcher2,factory:DevtoolsDispatcher2.\u0275fac})}}return DevtoolsDispatcher2})(),ExtensionActionTypes={START:"START",DISPATCH:"DISPATCH",STOP:"STOP",ACTION:"ACTION"},REDUX_DEVTOOLS_EXTENSION=new InjectionToken("@ngrx/store-devtools Redux Devtools Extension"),DevtoolsExtension=(()=>{class DevtoolsExtension2{constructor(devtoolsExtension,config3,dispatcher){this.config=config3,this.dispatcher=dispatcher,this.zoneConfig=injectZoneConfig(this.config.connectInZone),this.devtoolsExtension=devtoolsExtension,this.createActionStreams()}notify(action,state){if(this.devtoolsExtension)if(action.type===PERFORM_ACTION){if(state.isLocked||state.isPaused)return;let currentState=unliftState(state);if(shouldFilterActions(this.config)&&isActionFiltered(currentState,action,this.config.predicate,this.config.actionsSafelist,this.config.actionsBlocklist))return;let sanitizedState=this.config.stateSanitizer?sanitizeState(this.config.stateSanitizer,currentState,state.currentStateIndex):currentState,sanitizedAction=this.config.actionSanitizer?sanitizeAction(this.config.actionSanitizer,action,state.nextActionId):action;this.sendToReduxDevtools(()=>this.extensionConnection.send(sanitizedAction,sanitizedState))}else{let sanitizedLiftedState=__spreadProps(__spreadValues({},state),{stagedActionIds:state.stagedActionIds,actionsById:this.config.actionSanitizer?sanitizeActions(this.config.actionSanitizer,state.actionsById):state.actionsById,computedStates:this.config.stateSanitizer?sanitizeStates(this.config.stateSanitizer,state.computedStates):state.computedStates});this.sendToReduxDevtools(()=>this.devtoolsExtension.send(null,sanitizedLiftedState,this.getExtensionConfig(this.config)))}}createChangesObservable(){return this.devtoolsExtension?new Observable(subscriber=>{let connection=this.zoneConfig.connectInZone?this.zoneConfig.ngZone.runOutsideAngular(()=>this.devtoolsExtension.connect(this.getExtensionConfig(this.config))):this.devtoolsExtension.connect(this.getExtensionConfig(this.config));return this.extensionConnection=connection,connection.init(),connection.subscribe(change=>subscriber.next(change)),connection.unsubscribe}):EMPTY}createActionStreams(){let changes$=this.createChangesObservable().pipe(share()),start$=changes$.pipe(filter(change=>change.type===ExtensionActionTypes.START)),stop$=changes$.pipe(filter(change=>change.type===ExtensionActionTypes.STOP)),liftedActions$=changes$.pipe(filter(change=>change.type===ExtensionActionTypes.DISPATCH),map(change=>this.unwrapAction(change.payload)),concatMap(action=>action.type===IMPORT_STATE?this.dispatcher.pipe(filter(action2=>action2.type===UPDATE),timeout(1e3),debounceTime(1e3),map(()=>action),catchError(()=>of(action)),take(1)):of(action))),actionsUntilStop$=changes$.pipe(filter(change=>change.type===ExtensionActionTypes.ACTION),map(change=>this.unwrapAction(change.payload))).pipe(takeUntil(stop$)),liftedUntilStop$=liftedActions$.pipe(takeUntil(stop$));this.start$=start$.pipe(takeUntil(stop$)),this.actions$=this.start$.pipe(switchMap(()=>actionsUntilStop$)),this.liftedActions$=this.start$.pipe(switchMap(()=>liftedUntilStop$))}unwrapAction(action){return typeof action=="string"?(0,eval)(`(${action})`):action}getExtensionConfig(config3){let extensionOptions={name:config3.name,features:config3.features,serialize:config3.serialize,autoPause:config3.autoPause??!1,trace:config3.trace??!1,traceLimit:config3.traceLimit??75};return config3.maxAge!==!1&&(extensionOptions.maxAge=config3.maxAge),extensionOptions}sendToReduxDevtools(send){try{send()}catch(err){console.warn("@ngrx/store-devtools: something went wrong inside the redux devtools",err)}}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||DevtoolsExtension2)(\u0275\u0275inject(REDUX_DEVTOOLS_EXTENSION),\u0275\u0275inject(STORE_DEVTOOLS_CONFIG),\u0275\u0275inject(DevtoolsDispatcher))}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:DevtoolsExtension2,factory:DevtoolsExtension2.\u0275fac})}}return DevtoolsExtension2})(),INIT_ACTION={type:INIT},RECOMPUTE="@ngrx/store-devtools/recompute",RECOMPUTE_ACTION={type:RECOMPUTE};function computeNextEntry(reducer44,action,state,error3,errorHandler){if(error3)return{state,error:"Interrupted by an error up the chain"};let nextState=state,nextError;try{nextState=reducer44(state,action)}catch(err){nextError=err.toString(),errorHandler.handleError(err)}return{state:nextState,error:nextError}}function recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused){if(minInvalidatedStateIndex>=computedStates.length&&computedStates.length===stagedActionIds.length)return computedStates;let nextComputedStates=computedStates.slice(0,minInvalidatedStateIndex),lastIncludedActionId=stagedActionIds.length-(isPaused?1:0);for(let i=minInvalidatedStateIndex;i<lastIncludedActionId;i++){let actionId=stagedActionIds[i],action=actionsById[actionId].action,previousEntry=nextComputedStates[i-1],previousState=previousEntry?previousEntry.state:committedState,previousError=previousEntry?previousEntry.error:void 0,entry=skippedActionIds.indexOf(actionId)>-1?previousEntry:computeNextEntry(reducer44,action,previousState,previousError,errorHandler);nextComputedStates.push(entry)}return isPaused&&nextComputedStates.push(computedStates[computedStates.length-1]),nextComputedStates}function liftInitialState(initialCommittedState,monitorReducer){return{monitorState:monitorReducer(void 0,{}),nextActionId:1,actionsById:{0:liftAction(INIT_ACTION)},stagedActionIds:[0],skippedActionIds:[],committedState:initialCommittedState,currentStateIndex:0,computedStates:[],isLocked:!1,isPaused:!1}}function liftReducerWith(initialCommittedState,initialLiftedState,errorHandler,monitorReducer,options={}){return reducer44=>(liftedState,liftedAction)=>{let{monitorState,actionsById,nextActionId,stagedActionIds,skippedActionIds,committedState,currentStateIndex,computedStates,isLocked,isPaused}=liftedState||initialLiftedState;liftedState||(actionsById=Object.create(actionsById));function commitExcessActions(n2){let excess=n2,idsToDelete=stagedActionIds.slice(1,excess+1);for(let i=0;i<idsToDelete.length;i++)if(computedStates[i+1].error){excess=i,idsToDelete=stagedActionIds.slice(1,excess+1);break}else delete actionsById[idsToDelete[i]];skippedActionIds=skippedActionIds.filter(id=>idsToDelete.indexOf(id)===-1),stagedActionIds=[0,...stagedActionIds.slice(excess+1)],committedState=computedStates[excess].state,computedStates=computedStates.slice(excess),currentStateIndex=currentStateIndex>excess?currentStateIndex-excess:0}function commitChanges(){actionsById={0:liftAction(INIT_ACTION)},nextActionId=1,stagedActionIds=[0],skippedActionIds=[],committedState=computedStates[currentStateIndex].state,currentStateIndex=0,computedStates=[]}let minInvalidatedStateIndex=0;switch(liftedAction.type){case LOCK_CHANGES:{isLocked=liftedAction.status,minInvalidatedStateIndex=1/0;break}case PAUSE_RECORDING:{isPaused=liftedAction.status,isPaused?(stagedActionIds=[...stagedActionIds,nextActionId],actionsById[nextActionId]=new PerformAction({type:"@ngrx/devtools/pause"},+Date.now()),nextActionId++,minInvalidatedStateIndex=stagedActionIds.length-1,computedStates=computedStates.concat(computedStates[computedStates.length-1]),currentStateIndex===stagedActionIds.length-2&&currentStateIndex++,minInvalidatedStateIndex=1/0):commitChanges();break}case RESET:{actionsById={0:liftAction(INIT_ACTION)},nextActionId=1,stagedActionIds=[0],skippedActionIds=[],committedState=initialCommittedState,currentStateIndex=0,computedStates=[];break}case COMMIT:{commitChanges();break}case ROLLBACK:{actionsById={0:liftAction(INIT_ACTION)},nextActionId=1,stagedActionIds=[0],skippedActionIds=[],currentStateIndex=0,computedStates=[];break}case TOGGLE_ACTION:{let{id:actionId}=liftedAction;skippedActionIds.indexOf(actionId)===-1?skippedActionIds=[actionId,...skippedActionIds]:skippedActionIds=skippedActionIds.filter(id=>id!==actionId),minInvalidatedStateIndex=stagedActionIds.indexOf(actionId);break}case SET_ACTIONS_ACTIVE:{let{start:start3,end:end2,active}=liftedAction,actionIds=[];for(let i=start3;i<end2;i++)actionIds.push(i);active?skippedActionIds=difference(skippedActionIds,actionIds):skippedActionIds=[...skippedActionIds,...actionIds],minInvalidatedStateIndex=stagedActionIds.indexOf(start3);break}case JUMP_TO_STATE:{currentStateIndex=liftedAction.index,minInvalidatedStateIndex=1/0;break}case JUMP_TO_ACTION:{let index=stagedActionIds.indexOf(liftedAction.actionId);index!==-1&&(currentStateIndex=index),minInvalidatedStateIndex=1/0;break}case SWEEP:{stagedActionIds=difference(stagedActionIds,skippedActionIds),skippedActionIds=[],currentStateIndex=Math.min(currentStateIndex,stagedActionIds.length-1);break}case PERFORM_ACTION:{if(isLocked)return liftedState||initialLiftedState;if(isPaused||liftedState&&isActionFiltered(liftedState.computedStates[currentStateIndex],liftedAction,options.predicate,options.actionsSafelist,options.actionsBlocklist)){let lastState=computedStates[computedStates.length-1];computedStates=[...computedStates.slice(0,-1),computeNextEntry(reducer44,liftedAction.action,lastState.state,lastState.error,errorHandler)],minInvalidatedStateIndex=1/0;break}options.maxAge&&stagedActionIds.length===options.maxAge&&commitExcessActions(1),currentStateIndex===stagedActionIds.length-1&&currentStateIndex++;let actionId=nextActionId++;actionsById[actionId]=liftedAction,stagedActionIds=[...stagedActionIds,actionId],minInvalidatedStateIndex=stagedActionIds.length-1;break}case IMPORT_STATE:{({monitorState,actionsById,nextActionId,stagedActionIds,skippedActionIds,committedState,currentStateIndex,computedStates,isLocked,isPaused}=liftedAction.nextLiftedState);break}case INIT:{minInvalidatedStateIndex=0,options.maxAge&&stagedActionIds.length>options.maxAge&&(computedStates=recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused),commitExcessActions(stagedActionIds.length-options.maxAge),minInvalidatedStateIndex=1/0);break}case UPDATE:{if(computedStates.filter(state=>state.error).length>0)minInvalidatedStateIndex=0,options.maxAge&&stagedActionIds.length>options.maxAge&&(computedStates=recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused),commitExcessActions(stagedActionIds.length-options.maxAge),minInvalidatedStateIndex=1/0);else{if(!isPaused&&!isLocked){currentStateIndex===stagedActionIds.length-1&&currentStateIndex++;let actionId=nextActionId++;actionsById[actionId]=new PerformAction(liftedAction,+Date.now()),stagedActionIds=[...stagedActionIds,actionId],minInvalidatedStateIndex=stagedActionIds.length-1,computedStates=recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused)}computedStates=computedStates.map(cmp=>__spreadProps(__spreadValues({},cmp),{state:reducer44(cmp.state,RECOMPUTE_ACTION)})),currentStateIndex=stagedActionIds.length-1,options.maxAge&&stagedActionIds.length>options.maxAge&&commitExcessActions(stagedActionIds.length-options.maxAge),minInvalidatedStateIndex=1/0}break}default:{minInvalidatedStateIndex=1/0;break}}return computedStates=recomputeStates(computedStates,minInvalidatedStateIndex,reducer44,committedState,actionsById,stagedActionIds,skippedActionIds,errorHandler,isPaused),monitorState=monitorReducer(monitorState,liftedAction),{monitorState,actionsById,nextActionId,stagedActionIds,skippedActionIds,committedState,currentStateIndex,computedStates,isLocked,isPaused}}}var StoreDevtools=(()=>{class StoreDevtools2{constructor(dispatcher,actions$,reducers$,extension,scannedActions,errorHandler,initialState48,config3){let liftedInitialState=liftInitialState(initialState48,config3.monitor),liftReducer=liftReducerWith(initialState48,liftedInitialState,errorHandler,config3.monitor,config3),liftedAction$=merge(merge(actions$.asObservable().pipe(skip(1)),extension.actions$).pipe(map(liftAction)),dispatcher,extension.liftedActions$).pipe(observeOn(queueScheduler)),liftedReducer$=reducers$.pipe(map(liftReducer)),zoneConfig=injectZoneConfig(config3.connectInZone),liftedStateSubject=new ReplaySubject(1);this.liftedStateSubscription=liftedAction$.pipe(withLatestFrom(liftedReducer$),emitInZone(zoneConfig),scan(({state:liftedState},[action,reducer44])=>{let reducedLiftedState=reducer44(liftedState,action);return action.type!==PERFORM_ACTION&&shouldFilterActions(config3)&&(reducedLiftedState=filterLiftedState(reducedLiftedState,config3.predicate,config3.actionsSafelist,config3.actionsBlocklist)),extension.notify(action,reducedLiftedState),{state:reducedLiftedState,action}},{state:liftedInitialState,action:null})).subscribe(({state,action})=>{if(liftedStateSubject.next(state),action.type===PERFORM_ACTION){let unliftedAction=action.action;scannedActions.next(unliftedAction)}}),this.extensionStartSubscription=extension.start$.pipe(emitInZone(zoneConfig)).subscribe(()=>{this.refresh()});let liftedState$=liftedStateSubject.asObservable(),state$=liftedState$.pipe(map(unliftState));Object.defineProperty(state$,"state",{value:toSignal(state$,{manualCleanup:!0,requireSync:!0})}),this.dispatcher=dispatcher,this.liftedState=liftedState$,this.state=state$}ngOnDestroy(){this.liftedStateSubscription.unsubscribe(),this.extensionStartSubscription.unsubscribe()}dispatch(action){this.dispatcher.next(action)}next(action){this.dispatcher.next(action)}error(error3){}complete(){}performAction(action){this.dispatch(new PerformAction(action,+Date.now()))}refresh(){this.dispatch(new Refresh)}reset(){this.dispatch(new Reset(+Date.now()))}rollback(){this.dispatch(new Rollback(+Date.now()))}commit(){this.dispatch(new Commit(+Date.now()))}sweep(){this.dispatch(new Sweep)}toggleAction(id){this.dispatch(new ToggleAction(id))}jumpToAction(actionId){this.dispatch(new JumpToAction(actionId))}jumpToState(index){this.dispatch(new JumpToState(index))}importState(nextLiftedState){this.dispatch(new ImportState(nextLiftedState))}lockChanges(status){this.dispatch(new LockChanges(status))}pauseRecording(status){this.dispatch(new PauseRecording(status))}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||StoreDevtools2)(\u0275\u0275inject(DevtoolsDispatcher),\u0275\u0275inject(ActionsSubject),\u0275\u0275inject(ReducerObservable),\u0275\u0275inject(DevtoolsExtension),\u0275\u0275inject(ScannedActionsSubject),\u0275\u0275inject(ErrorHandler),\u0275\u0275inject(INITIAL_STATE),\u0275\u0275inject(STORE_DEVTOOLS_CONFIG))}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:StoreDevtools2,factory:StoreDevtools2.\u0275fac})}}return StoreDevtools2})();function emitInZone({ngZone,connectInZone}){return source=>connectInZone?new Observable(subscriber=>source.subscribe({next:value=>ngZone.run(()=>subscriber.next(value)),error:error3=>ngZone.run(()=>subscriber.error(error3)),complete:()=>ngZone.run(()=>subscriber.complete())})):source}var IS_EXTENSION_OR_MONITOR_PRESENT=new InjectionToken("@ngrx/store-devtools Is Devtools Extension or Monitor Present");function createIsExtensionOrMonitorPresent(extension,config3){return!!extension||config3.monitor!==noMonitor}function createReduxDevtoolsExtension(){let extensionKey="__REDUX_DEVTOOLS_EXTENSION__";return typeof window=="object"&&typeof window[extensionKey]<"u"?window[extensionKey]:null}function createStateObservable(devtools){return devtools.state}function provideStoreDevtools(options={}){return makeEnvironmentProviders([DevtoolsExtension,DevtoolsDispatcher,StoreDevtools,{provide:INITIAL_OPTIONS,useValue:options},{provide:IS_EXTENSION_OR_MONITOR_PRESENT,deps:[REDUX_DEVTOOLS_EXTENSION,STORE_DEVTOOLS_CONFIG],useFactory:createIsExtensionOrMonitorPresent},{provide:REDUX_DEVTOOLS_EXTENSION,useFactory:createReduxDevtoolsExtension},{provide:STORE_DEVTOOLS_CONFIG,deps:[INITIAL_OPTIONS],useFactory:createConfig},{provide:StateObservable,deps:[StoreDevtools],useFactory:createStateObservable},{provide:ReducerManagerDispatcher,useExisting:DevtoolsDispatcher}])}var StoreDevtoolsModule=(()=>{class StoreDevtoolsModule2{static instrument(options={}){return{ngModule:StoreDevtoolsModule2,providers:[provideStoreDevtools(options)]}}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||StoreDevtoolsModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:StoreDevtoolsModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({})}}return StoreDevtoolsModule2})();var DEBUG_BUILD=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;var GLOBAL_OBJ=globalThis;var SDK_VERSION="10.5.0";function getMainCarrier(){return getSentryCarrier(GLOBAL_OBJ),GLOBAL_OBJ}function getSentryCarrier(carrier){let __SENTRY__=carrier.__SENTRY__=carrier.__SENTRY__||{};return __SENTRY__.version=__SENTRY__.version||SDK_VERSION,__SENTRY__[SDK_VERSION]=__SENTRY__[SDK_VERSION]||{}}function getGlobalSingleton(name,creator,obj=GLOBAL_OBJ){let __SENTRY__=obj.__SENTRY__=obj.__SENTRY__||{},carrier=__SENTRY__[SDK_VERSION]=__SENTRY__[SDK_VERSION]||{};return carrier[name]||(carrier[name]=creator())}var PREFIX="Sentry Logger ",originalConsoleMethods={};function consoleSandbox(callback){if(!("console"in GLOBAL_OBJ))return callback();let console2=GLOBAL_OBJ.console,wrappedFuncs={},wrappedLevels=Object.keys(originalConsoleMethods);wrappedLevels.forEach(level=>{let originalConsoleMethod=originalConsoleMethods[level];wrappedFuncs[level]=console2[level],console2[level]=originalConsoleMethod});try{return callback()}finally{wrappedLevels.forEach(level=>{console2[level]=wrappedFuncs[level]})}}function enable(){_getLoggerSettings().enabled=!0}function disable(){_getLoggerSettings().enabled=!1}function isEnabled(){return _getLoggerSettings().enabled}function log(...args){_maybeLog("log",...args)}function warn2(...args){_maybeLog("warn",...args)}function error2(...args){_maybeLog("error",...args)}function _maybeLog(level,...args){DEBUG_BUILD&&isEnabled()&&consoleSandbox(()=>{GLOBAL_OBJ.console[level](`${PREFIX}[${level}]:`,...args)})}function _getLoggerSettings(){return DEBUG_BUILD?getGlobalSingleton("loggerSettings",()=>({enabled:!1})):{enabled:!1}}var debug={enable,disable,isEnabled,log,warn:warn2,error:error2};var objectToString=Object.prototype.toString;function isBuiltin(wat,className){return objectToString.call(wat)===`[object ${className}]`}function isPlainObject(wat){return isBuiltin(wat,"Object")}function isThenable(wat){return!!(wat?.then&&typeof wat.then=="function")}function truncate(str,max2=0){return typeof str!="string"||max2===0||str.length<=max2?str:`${str.slice(0,max2)}...`}function addNonEnumerableProperty(obj,name,value){try{Object.defineProperty(obj,name,{value,writable:!0,configurable:!0})}catch{DEBUG_BUILD&&debug.log(`Failed to add non-enumerable property "${name}" to object`,obj)}}function getCrypto(){let gbl=GLOBAL_OBJ;return gbl.crypto||gbl.msCrypto}function uuid4(crypto2=getCrypto()){let getRandomByte=()=>Math.random()*16;try{if(crypto2?.randomUUID)return crypto2.randomUUID().replace(/-/g,"");crypto2?.getRandomValues&&(getRandomByte=()=>{let typedArray=new Uint8Array(1);return crypto2.getRandomValues(typedArray),typedArray[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,c=>(c^(getRandomByte()&15)>>c/4).toString(16))}var ONE_SECOND_IN_MS=1e3;function dateTimestampInSeconds(){return Date.now()/ONE_SECOND_IN_MS}function createUnixTimestampInSecondsFunc(){let{performance:performance2}=GLOBAL_OBJ;if(!performance2?.now||!performance2.timeOrigin)return dateTimestampInSeconds;let timeOrigin=performance2.timeOrigin;return()=>(timeOrigin+performance2.now())/ONE_SECOND_IN_MS}var _cachedTimestampInSeconds;function timestampInSeconds(){return(_cachedTimestampInSeconds??(_cachedTimestampInSeconds=createUnixTimestampInSecondsFunc()))()}function updateSession(session,context3={}){if(context3.user&&(!session.ipAddress&&context3.user.ip_address&&(session.ipAddress=context3.user.ip_address),!session.did&&!context3.did&&(session.did=context3.user.id||context3.user.email||context3.user.username)),session.timestamp=context3.timestamp||timestampInSeconds(),context3.abnormal_mechanism&&(session.abnormal_mechanism=context3.abnormal_mechanism),context3.ignoreDuration&&(session.ignoreDuration=context3.ignoreDuration),context3.sid&&(session.sid=context3.sid.length===32?context3.sid:uuid4()),context3.init!==void 0&&(session.init=context3.init),!session.did&&context3.did&&(session.did=`${context3.did}`),typeof context3.started=="number"&&(session.started=context3.started),session.ignoreDuration)session.duration=void 0;else if(typeof context3.duration=="number")session.duration=context3.duration;else{let duration=session.timestamp-session.started;session.duration=duration>=0?duration:0}context3.release&&(session.release=context3.release),context3.environment&&(session.environment=context3.environment),!session.ipAddress&&context3.ipAddress&&(session.ipAddress=context3.ipAddress),!session.userAgent&&context3.userAgent&&(session.userAgent=context3.userAgent),typeof context3.errors=="number"&&(session.errors=context3.errors),context3.status&&(session.status=context3.status)}function merge3(initialObj,mergeObj,levels=2){if(!mergeObj||typeof mergeObj!="object"||levels<=0)return mergeObj;if(initialObj&&Object.keys(mergeObj).length===0)return initialObj;let output2=__spreadValues({},initialObj);for(let key in mergeObj)Object.prototype.hasOwnProperty.call(mergeObj,key)&&(output2[key]=merge3(output2[key],mergeObj[key],levels-1));return output2}function generateTraceId(){return uuid4()}var SCOPE_SPAN_FIELD="_sentrySpan";function _setSpanForScope(scope,span){span?addNonEnumerableProperty(scope,SCOPE_SPAN_FIELD,span):delete scope[SCOPE_SPAN_FIELD]}function _getSpanForScope(scope){return scope[SCOPE_SPAN_FIELD]}var DEFAULT_MAX_BREADCRUMBS=100,Scope=class _Scope{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:generateTraceId(),sampleRand:Math.random()}}clone(){let newScope=new _Scope;return newScope._breadcrumbs=[...this._breadcrumbs],newScope._tags=__spreadValues({},this._tags),newScope._extra=__spreadValues({},this._extra),newScope._contexts=__spreadValues({},this._contexts),this._contexts.flags&&(newScope._contexts.flags={values:[...this._contexts.flags.values]}),newScope._user=this._user,newScope._level=this._level,newScope._session=this._session,newScope._transactionName=this._transactionName,newScope._fingerprint=this._fingerprint,newScope._eventProcessors=[...this._eventProcessors],newScope._attachments=[...this._attachments],newScope._sdkProcessingMetadata=__spreadValues({},this._sdkProcessingMetadata),newScope._propagationContext=__spreadValues({},this._propagationContext),newScope._client=this._client,newScope._lastEventId=this._lastEventId,_setSpanForScope(newScope,_getSpanForScope(this)),newScope}setClient(client){this._client=client}setLastEventId(lastEventId2){this._lastEventId=lastEventId2}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(callback){this._scopeListeners.push(callback)}addEventProcessor(callback){return this._eventProcessors.push(callback),this}setUser(user){return this._user=user||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&updateSession(this._session,{user}),this._notifyScopeListeners(),this}getUser(){return this._user}setTags(tags){return this._tags=__spreadValues(__spreadValues({},this._tags),tags),this._notifyScopeListeners(),this}setTag(key,value){return this._tags=__spreadProps(__spreadValues({},this._tags),{[key]:value}),this._notifyScopeListeners(),this}setExtras(extras){return this._extra=__spreadValues(__spreadValues({},this._extra),extras),this._notifyScopeListeners(),this}setExtra(key,extra){return this._extra=__spreadProps(__spreadValues({},this._extra),{[key]:extra}),this._notifyScopeListeners(),this}setFingerprint(fingerprint){return this._fingerprint=fingerprint,this._notifyScopeListeners(),this}setLevel(level){return this._level=level,this._notifyScopeListeners(),this}setTransactionName(name){return this._transactionName=name,this._notifyScopeListeners(),this}setContext(key,context3){return context3===null?delete this._contexts[key]:this._contexts[key]=context3,this._notifyScopeListeners(),this}setSession(session){return session?this._session=session:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(captureContext){if(!captureContext)return this;let scopeToMerge=typeof captureContext=="function"?captureContext(this):captureContext,scopeInstance=scopeToMerge instanceof _Scope?scopeToMerge.getScopeData():isPlainObject(scopeToMerge)?captureContext:void 0,{tags,extra,user,contexts,level,fingerprint=[],propagationContext}=scopeInstance||{};return this._tags=__spreadValues(__spreadValues({},this._tags),tags),this._extra=__spreadValues(__spreadValues({},this._extra),extra),this._contexts=__spreadValues(__spreadValues({},this._contexts),contexts),user&&Object.keys(user).length&&(this._user=user),level&&(this._level=level),fingerprint.length&&(this._fingerprint=fingerprint),propagationContext&&(this._propagationContext=propagationContext),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,_setSpanForScope(this,void 0),this._attachments=[],this.setPropagationContext({traceId:generateTraceId(),sampleRand:Math.random()}),this._notifyScopeListeners(),this}addBreadcrumb(breadcrumb,maxBreadcrumbs){let maxCrumbs=typeof maxBreadcrumbs=="number"?maxBreadcrumbs:DEFAULT_MAX_BREADCRUMBS;if(maxCrumbs<=0)return this;let mergedBreadcrumb=__spreadProps(__spreadValues({timestamp:dateTimestampInSeconds()},breadcrumb),{message:breadcrumb.message?truncate(breadcrumb.message,2048):breadcrumb.message});return this._breadcrumbs.push(mergedBreadcrumb),this._breadcrumbs.length>maxCrumbs&&(this._breadcrumbs=this._breadcrumbs.slice(-maxCrumbs),this._client?.recordDroppedEvent("buffer_overflow","log_item")),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(attachment){return this._attachments.push(attachment),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:_getSpanForScope(this)}}setSDKProcessingMetadata(newData){return this._sdkProcessingMetadata=merge3(this._sdkProcessingMetadata,newData,2),this}setPropagationContext(context3){return this._propagationContext=context3,this}getPropagationContext(){return this._propagationContext}captureException(exception,hint){let eventId=hint?.event_id||uuid4();if(!this._client)return DEBUG_BUILD&&debug.warn("No client configured on scope - will not capture exception!"),eventId;let syntheticException=new Error("Sentry syntheticException");return this._client.captureException(exception,__spreadProps(__spreadValues({originalException:exception,syntheticException},hint),{event_id:eventId}),this),eventId}captureMessage(message,level,hint){let eventId=hint?.event_id||uuid4();if(!this._client)return DEBUG_BUILD&&debug.warn("No client configured on scope - will not capture message!"),eventId;let syntheticException=new Error(message);return this._client.captureMessage(message,level,__spreadProps(__spreadValues({originalException:message,syntheticException},hint),{event_id:eventId}),this),eventId}captureEvent(event2,hint){let eventId=hint?.event_id||uuid4();return this._client?(this._client.captureEvent(event2,__spreadProps(__spreadValues({},hint),{event_id:eventId}),this),eventId):(DEBUG_BUILD&&debug.warn("No client configured on scope - will not capture event!"),eventId)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(callback=>{callback(this)}),this._notifyingListeners=!1)}};function getDefaultCurrentScope(){return getGlobalSingleton("defaultCurrentScope",()=>new Scope)}function getDefaultIsolationScope(){return getGlobalSingleton("defaultIsolationScope",()=>new Scope)}var AsyncContextStack=class{constructor(scope,isolationScope){let assignedScope;scope?assignedScope=scope:assignedScope=new Scope;let assignedIsolationScope;isolationScope?assignedIsolationScope=isolationScope:assignedIsolationScope=new Scope,this._stack=[{scope:assignedScope}],this._isolationScope=assignedIsolationScope}withScope(callback){let scope=this._pushScope(),maybePromiseResult;try{maybePromiseResult=callback(scope)}catch(e){throw this._popScope(),e}return isThenable(maybePromiseResult)?maybePromiseResult.then(res=>(this._popScope(),res),e=>{throw this._popScope(),e}):(this._popScope(),maybePromiseResult)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){let scope=this.getScope().clone();return this._stack.push({client:this.getClient(),scope}),scope}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}};function getAsyncContextStack(){let registry=getMainCarrier(),sentry=getSentryCarrier(registry);return sentry.stack=sentry.stack||new AsyncContextStack(getDefaultCurrentScope(),getDefaultIsolationScope())}function withScope(callback){return getAsyncContextStack().withScope(callback)}function withSetScope(scope,callback){let stack=getAsyncContextStack();return stack.withScope(()=>(stack.getStackTop().scope=scope,callback(scope)))}function withIsolationScope(callback){return getAsyncContextStack().withScope(()=>callback(getAsyncContextStack().getIsolationScope()))}function getStackAsyncContextStrategy(){return{withIsolationScope,withScope,withSetScope,withSetIsolationScope:(_isolationScope,callback)=>withIsolationScope(callback),getCurrentScope:()=>getAsyncContextStack().getScope(),getIsolationScope:()=>getAsyncContextStack().getIsolationScope()}}function getAsyncContextStrategy(carrier){let sentry=getSentryCarrier(carrier);return sentry.acs?sentry.acs:getStackAsyncContextStrategy()}function getCurrentScope(){let carrier=getMainCarrier();return getAsyncContextStrategy(carrier).getCurrentScope()}function getIsolationScope(){let carrier=getMainCarrier();return getAsyncContextStrategy(carrier).getIsolationScope()}function getClient(){return getCurrentScope().getClient()}var DEFAULT_BREADCRUMBS=100;function addBreadcrumb(breadcrumb,hint){let client=getClient(),isolationScope=getIsolationScope();if(!client)return;let{beforeBreadcrumb=null,maxBreadcrumbs=DEFAULT_BREADCRUMBS}=client.getOptions();if(maxBreadcrumbs<=0)return;let timestamp2=dateTimestampInSeconds(),mergedBreadcrumb=__spreadValues({timestamp:timestamp2},breadcrumb),finalBreadcrumb=beforeBreadcrumb?consoleSandbox(()=>beforeBreadcrumb(mergedBreadcrumb,hint)):mergedBreadcrumb;finalBreadcrumb!==null&&(client.emit&&client.emit("beforeAddBreadcrumb",finalBreadcrumb,hint),isolationScope.addBreadcrumb(finalBreadcrumb,maxBreadcrumbs))}function sentryNgrxMetaReducer(reducer44){return function(state,action){return addBreadcrumb({category:"ngrx",message:action.type,level:"info"}),reducer44(state,action)}}var reducers={router:routerReducer},metaReducers=environment.production?[sentryNgrxMetaReducer]:[];var AppEffects=(()=>{class AppEffects2{constructor(){this.actions$=inject(Actions),this.location=inject(Location),this.router=inject(Router),this.company2faRequired$=createEffect(()=>this.actions$.pipe(ofType(loadMeFailure),mergeMap(({errors:errors2})=>errors2.some(error3=>error3.message===IxApiRequestErrorMessages.TWO_FACTOR_AUTH_REQUIRED)?of(redirectTo2faRequired()):EMPTY))),this.redirectTo2faRequired$=createEffect(()=>this.actions$.pipe(ofType(redirectTo2faRequired),tap(()=>{this.router.navigate(["/two-factor-auth-required"],{skipLocationChange:!0})})),{dispatch:!1})}static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||AppEffects2)}}static{this.\u0275prov=\u0275\u0275defineInjectable({token:AppEffects2,factory:AppEffects2.\u0275fac})}}return AppEffects2})();var AppStateModule=(()=>{class AppStateModule2{static{this.\u0275fac=function(__ngFactoryType__){return new(__ngFactoryType__||AppStateModule2)}}static{this.\u0275mod=\u0275\u0275defineNgModule({type:AppStateModule2})}static{this.\u0275inj=\u0275\u0275defineInjector({imports:[TranslateModule,StoreModule.forRoot(reducers,{metaReducers,runtimeChecks:{strictStateImmutability:!environment.production,strictActionImmutability:!environment.production,strictStateSerializability:!environment.production}}),environment.production?[]:[StoreDevtoolsModule.instrument({maxAge:50,connectInZone:!0})],EffectsModule.forRoot([AppEffects])]})}}return AppStateModule2})();function generateBanner(metadata,translate){let header=document.createElement("div");return header.innerHTML=`
822
822
  <div id="appBanner" style="display: flex; top: 0; left: 0; width: 100%; height: 80px; position: absolute; justify-content: center; background-color: #f2f2f2;">
823
823
  <div style="display: flex; justify-content: flex-start; width: 100vw; color: black;">
824
824
  <div style="justify-content: flex-start; max-width: 330px; display: flex; align-items: center; flex: 1;">