1import{$a as m,B as S,Ba as B,Bj as T,Cj as g,Cn as Z,Ej as G,Fj as V,Hu as me,Ib as f,Jb as w,Jn as ee,Kn as te,La as R,Ma as M,N as A,Na as x,Nn as ie,Oa as b,On as oe,Pa as r,Po as ne,Qa as s,Qc as U,Qo as re,Ro as ae,Sc as P,Sd as F,Sl as K,Vt as se,W as I,Wb as L,Yb as N,Ym as Q,Yt as ce,Z as n,Zt as pe,ac as z,eb as D,el as X,ev as de,ff as C,gl as H,h as _,k as v,kq as le,l as p,m as y,nd as j,nl as Y,pm as q,s as E,sa as l,t as $,tb as d,ub as u,um as J,v as W,ya as O,za as k}from"./chunk-6VDOBKBI.js";import"./chunk-UNNH6OJB.js";import{h as c}from"./chunk-HE2D45TV.js";function he(o,fe){if(o&1&&(r(0,"ww-display-object-key"),d(1),s(),r(2,"ww-display-object-value"),d(3),s()),o&2){let e=fe.$implicit;l(),u(e.label),l(2),u(e.value)}}var ue=(()=>{class o extends H{constructor(){super(),this.layout=n(de),this.serviceWorkerService=n(V),this.buildInfo=n(X,{optional:!0}),this.accountRx=n(se),this.locationRx=n(pe),this.userRx=n(ce),this.datePipe=n(N),this.wwDialog=n(Z),this.sessionRx=n(me),this.internetStatusLabel$=this.sessionRx.isOnline$.pipe(p(e=>e?$localize`Connected`:$localize`Disconnected`)),this.isServiceWorkerSupported=g(),this.serviceWorkerStatusLabel=this.getServiceWorkerStatusLabel(),this.isServiceWorkerEnabled=T(),this.serviceWorkerProgressLabel$=$(_(this.serviceWorkerService.isServiceWorkerInstalled()),E(1e3).pipe(S(35),A(()=>_(this.serviceWorkerService.isServiceWorkerInstalled())),W(e=>e),S(1))).pipe(p(e=>e?$localize`Offline capabilities are ready.`:$localize`Preparing offline capabilities, this can take up to 30 seconds...`)),this.items$=y([this.accountRx.account$.pipe(F(["id"])),this.locationRx.locationId$,this.userRx.userId$]).pipe(p(([e,t,i])=>[{label:$localize`Date`,value:this.formatBuildDate(this.buildInfo?.buildTimestamp)},{label:$localize`Version`,value:this.buildInfo?.commitHash},C.IOS_VERSION?{label:$localize`App version`,value:C.IOS_VERSION}:null,{label:$localize`Account`,value:e.id},{label:$localize`Location`,value:t},{label:$localize`User`,value:i}].filter(j))),this.layout.setFeatureContext({name:$localize`About`})}getServiceWorkerStatusLabel(){return g()?T()?$localize`Offline capabilities are enabled.`:$localize`Offline capabilities are not enabled.`:$localize`Offline capabilities are not supported in this browser version.`}promptClearCache(){return c(this,null,function*(){let e="DELETE",t=yield v(this.wwDialog.openPrompt({title:$localize`Warning: This will clear your cache`,message:$localize`This function will remove all application data that is stored in your browser. Your current session will be interrupted and you will need to login again. You may also want to restart your browser after using this function.`,confirmType:"warning",controls:[{component:Y(J,{label:$localize`Enter "${e}" to confirm`}),required:!0,validators:[i=>i===e]}]}).afterClosed$,{defaultValue:[]});!t||t[0]!==e||this.clearCache()})}formatBuildDate(e){if(!e)return"No build date found";try{return this.datePipe.transform(e,"Y-MM-dd HH:mm:ss zzzz")??e}catch(t){return e}}clearCache(){return c(this,null,function*(){window.indexedDB&&(yield this.clearIndexedDB()),this.clearCookies(),window.sessionStorage&&sessionStorage.clear(),window.localStorage&&localStorage.clear();try{yield G()}catch(e){}window.location.href="/"})}clearIndexedDB(){return c(this,null,function*(){try{let e=yield window.indexedDB.databases();for(let t of e)t.name&&window.indexedDB.deleteDatabase(t.name)}catch(e){}})}clearCookies(){let e=document.cookie.split("; ");for(let t of e){let i=window.location.hostname.split(".");for(;i.length>0;){let a=encodeURIComponent(t.split(";")[0].split("=")[0])+"=; expires=Thu, 01-Jan-1970 00:00:01 GMT; domain="+i.join(".")+" ;path=",h=location.pathname.split("/");for(document.cookie=a+"/";h.length>0;)document.cookie=a+h.join("/"),h.pop();i.shift()}}}static{this.\u0275fac=function(t){return new(t||o)}}static{this.\u0275cmp=O({type:o,selectors:[["ww-about"]],hostAttrs:[1,"ww-about","block","small:p-6"],standalone:!1,features:[B],decls:19,vars:10,consts:()=>{let e;e=$localize`Build`;let t;t=$localize`Internet`;let i;return i=$localize` Clear cache `,[e,t,i,[1,"flex","flex-col","gap-9"],[3,"bordered"],[1,"items-start","gap-y-4"],[3,"editable","routerLink"],["alignment","left"],["wwButton","","wwBackgroun
1dColor","warning",3,"click"]]},template:function(t,i){t&1&&(r(0,"div",3)(1,"ww-card",4),f(2,"async"),r(3,"ww-section")(4,"ww-section-title"),m(5,0),s(),r(6,"ww-section-content",5)(7,"ww-display-object"),M(8,he,4,2,null,null,R),f(10,"async"),r(11,"ww-display-object-key"),m(12,1),s(),r(13,"ww-display-object-value",6),d(14),f(15,"async"),s()()(),r(16,"ww-section-actions",7)(17,"button",8),D("click",function(){return i.promptClearCache()}),m(18,2),s()()()()()),t&2&&(l(),b("bordered",w(2,4,i.layout.isDesktop$)),l(7),x(w(10,6,i.items$)),l(5),b("editable",!0)("routerLink","/debug"),l(),u(w(15,8,i.internetStatusLabel$)))},dependencies:[U,K,Q,q,ae,ne,re,ee,oe,te,ie,L],encapsulation:2,changeDetection:0})}}return o})();var He=(()=>{class o{static{this.\u0275fac=function(t){return new(t||o)}}static{this.\u0275mod=k({type:o})}static{this.\u0275inj=I({imports:[z,P.forChild([{path:"",component:ue}]),le]})}}return o})();export{ue as WwAboutComponent,He as WwAboutModule}; 2//noopchunk-ACNCCZS5.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.