1import{a as Dt}from"./chunk-U2NOQNPM.js";import{a as xe,b as Ot,c as jt,d as Tt,e as Nt}from"./chunk-2LJNYEXQ.js";import{b as yt,c as Z}from"./chunk-DSVHLRZ2.js";import{a as At,b as wt,c as kt,d as Et,e as Lt}from"./chunk-PZXYG7SP.js";import{a as _e}from"./chunk-JSH52BRB.js";import{b as St}from"./chunk-MQLVWUEX.js";import"./chunk-JBCOKV2K.js";import{a as Oe}from"./chunk-KS7R6D5N.js";import"./chunk-R6WTFZQU.js";import{a as bt}from"./chunk-5WRDJ3KZ.js";import{a as It}from"./chunk-BKKN5ITU.js";import{b as Mt}from"./chunk-DTBJ74TT.js";import"./chunk-C5ML36GO.js";import"./chunk-V2LCGCHA.js";import{A as dt,E as H,F as ft,G as ut,H as gt,K as vt,L as Ct,r as Y,s as st,t as pt,u as lt,w as ct,x as Ce,y as mt,z as Pe}from"./chunk-YL73HO5A.js";import"./chunk-BON6DGXC.js";import{b as xt}from"./chunk-J5RTUER6.js";import{a as ht,b as _t}from"./chunk-RFZRNKEH.js";import{a as he}from"./chunk-EFZT3TDQ.js";import{g as ke,h as at,j as Ee,l as k}from"./chunk-IJOQMYIR.js";import"./chunk-O474YC64.js";import"./chunk-LHDTM7CQ.js";import"./chunk-DIEYCNP2.js";import{d as rt}from"./chunk-TQPKTQAL.js";import"./chunk-PPMQE2JW.js";import"./chunk-2UQAVQ45.js";import{e as fe}from"./chunk-JKUHAAK3.js";import{i as ve}from"./chunk-ZEOBUA47.js";import"./chunk-Z5XG4XOC.js";import"./chunk-OUVQIOMK.js";import{t as Ke}from"./chunk-2VXHONUW.js";import"./chunk-BTWHZXKR.js";import"./chunk-RJGQFZWE.js";import{a as tt,b as it}from"./chunk-RYGMUVZO.js";import"./chunk-6LHHOJ67.js";import{a as et}from"./chunk-YDRZG5W4.js";import"./chunk-C2K24JJO.js";import{a as ot}from"./chunk-SKLK4QB7.js";import"./chunk-AFY537I3.js";import"./chunk-FOX6PFLG.js";import"./chunk-XIR7RIPN.js";import"./chunk-EQEHDPN2.js";import{a as nt}from"./chunk-KQNKCWSB.js";import"./chunk-W3NQXQOX.js";import"./chunk-FN5PQSEI.js";import"./chunk-DORVKHI7.js";import"./chunk-TN75OO2P.js";import"./chunk-YR7EQSKE.js";import"./chunk-7A4O647I.js";import"./chunk-LO6CADJZ.js";import"./chunk-ASA3TRRD.js";import"./chunk-HQANNBNX.js";import"./chunk-AE6ER5EQ.js";import"./chunk-VCDKFT4V.js";import"./chunk-U7DEF5TX.js";import"./chunk-PFMUUSHO.js";import"./chunk-2TFAGBRS.js";import"./chunk-BUYGALCV.js";import{E as Ze}from"./chunk-2QYSD5RO.js";import{a as de}from"./chunk-5PO4QCCX.js";import"./chunk-DMHJZRXD.js";import"./chunk-K4QTA3A5.js";import"./chunk-54W4P7NA.js";import"./chunk-XYUM3QGQ.js";import{D as j,L as Je,g as W}from"./chunk-AJRHK7D2.js";import{a as qe}from"./chunk-QGTBO2LV.js";import"./chunk-BPCMKL7S.js";import{a as Ht}from"./chunk-PCGUCIEY.js";import"./chunk-TBVUQWMS.js";import{f as se,h as b,i as Ye,n as He}from"./chunk-FAGCLODN.js";import{b as Pt}from"./chunk-H4C3KJSV.js";import"./chunk-B5UAHDWW.js";import"./chunk-UIP3OGDT.js";import"./chunk-VUDRL6AY.js";import"./chunk-PNKQO6EM.js";import"./chunk-3DSD7D2T.js";import"./chunk-ROUGUONR.js";import"./chunk-63HL2L7R.js";import{b as ue}from"./chunk-SVLM2ECX.js";import"./chunk-MY5YK5O5.js";import{c as me}from"./chunk-4NGQH4V6.js";import"./chunk-PWQXPZVK.js";import"./chunk-UKHQPMQZ.js";import"./chunk-Y4AYZAWK.js";import{C as ce,I as Xe,v as le,w as Ge}from"./chunk-7WAXKT5I.js";import{e as x}from"./chunk-MHLI7EB3.js";import"./chunk-KIBC2ZGT.js";import{$ as pe}from"./chunk-6K3X73CK.js";import{d as We}from"./chunk-DLTOIL4G.js";import"./chunk-334MXCTX.js";import{a as ge,b as Qe}from"./chunk-U5TOGEJX.js";import{H as z,s as Be,t as ze}from"./chunk-OD4FXCMW.js";import{Ac as O,D as R,E as q,Fa as y,Fc as P,Ga as A,Hc as l,Ib as g,Ja as I,Ob as w,Pb as V,Tb as ae,Tc as we,Td as $e,Ub as Ue,V as U,Wa as Re,Wc as p,Yc as C,_ as Ne,g as Le,hc as c,jc as m,la as v,mc as $,na as _,nc as B,o as N,oc as d,pc as s,pd as D,qc as a,rc as f,ta as re,tb as J,ua as F,ud as K,vc as Fe,wc as Ve,xa as S,xd as Q,y as oe,zb as r}from"./chunk-T2TVCV7P.js";import{a as ie,b as ne,g as Yt}from"./chunk-BBHHUGUF.js";var Rt=()=>({position:"relative","bottom.px":1});function Gt(t,o){if(t&1&&(s(0,"div",4),p(1),K(2,"cpdTime"),a()),t&2){let e=l();r(),C(" ",Q(2,1,e.remainingMin,"hour","sht")," left ")}}function Xt(t,o){if(t&1&&(s(0,"div",4),p(1),K(2,"cpdTime"),a()),t&2){let e=l();r(),C(" ",Q(2,1,e.totalMin,"hour","sht")," of training ")}}function qt(t,o){if(t&1&&(s(0,"div",8)(1,"div",9),f(2,"ap-progress",10),a()()),t&2){let e=l();r(2),d("apInfo",e.apInfo)}}var T=class t{constructor(){this.remainingMin=0;this.totalMin=0}ngOnChanges(o){le(this.allModules,e=>{let{resource:i}=e.passportModule;i&&i.min&&(ce(["complete","expiring"],e.compCal?.fn_status)||(this.remainingMin+=i.min),this.totalMin+=i.min)})}static{this.\u0275fac=function(e){return new(e||t)}}static{this.\u0275cmp=w({type:t,selectors:[["pm-status-display"]],inputs:{allModules:"allModules",apInfo:"apInfo"},features:[Re],decls:12,vars:8,consts:[[1,"pm-status-container","pm-content","d-flex","flex-column","flex-md-row"],[1,"d-flex","flex-row","align-items-center","mt-6","mb-6"],[1,"d-inline-flex","align-items-center","pm-sm-title"],["name","time-clock-circle-alternate","theme","bold","size","f-paragraph","color","text-neutral-700",1,"sl-icon",3,"svgStyle"],[1,"f-small","text-neutral-700","ml-2"],[1,"pm-dot","mx-5"],[1,"d-inline-flex","align-items-center"],["name","controls-play","theme","bold","size","f-paragraph","color","text-neutral-700",1,"sl-icon",3,"svgStyle"],[1,"pm-tabs","mb-4","mb-md-0"],[1,"pm-progress"],[3,"apInfo"]],template:function(e,i){e&1&&(s(0,"div",0)(1,"div",1)(2,"div",2),f(3,"ui-streamline-icon",3),c(4,Gt,3,5,"div",4),c(5,Xt,3,5,"div",4),a(),f(6,"span",5),s(7,"div",6),f(8,"ui-streamline-icon",7),s(9,"div",4),p(10),a()()(),c(11,qt,3,1,"div",8),a()),e&2&&(r(3),d("svgStyle",D(6,Rt)),r(),m(i.remainingMin?4:-1),r(),m(i.remainingMin?-1:5),r(3),d("svgStyle",D(7,Rt)),r(2),C(" ",i.allModules==null?null:i.allModules.length," training activities "),r(),m(i.apInfo?11:-1))},dependencies:[x,Z,yt,he],styles:[".pm-content[_ngcontent-%COMP%]{margin:auto}@media(min-width:576px){.pm-content[_ngcontent-%COMP%]{width:80%}}@media(max-width:575.98px){.pm-content[_ngcontent-%COMP%]{max-width:23rem}}.pm-tabs[_ngcontent-%COMP%]{width:23rem}@media(min-width:576px){.pm-tabs[_ngcontent-%COMP%]{width:100%}}@media(min-width:768px){.pm-tabs[_ngcontent-%COMP%]{width:260px}}
1.pm-dot[_ngcontent-%COMP%]{height:4px;width:4px;background-color:#6f7786;border-radius:50%}.pm-status-container[_ngcontent-%COMP%]{align-items:start}@media(min-width:768px){.pm-status-container[_ngcontent-%COMP%]{justify-content:space-between;align-items:center}}"]})}},Me=class t{static{this.\u0275fac=function(e){return new(e||t)}}static{this.\u0275mod=V({type:t})}static{this.\u0275inj=F({imports:[z,Z,x,ve,T]})}};var Jt=()=>({position:"relative","bottom.px":1}),E=class t{constructor(o,e,i){this.router=o;this.injector=e;this.objService=i;this.navClick=new Le}ngOnInit(){}hideNaviAndNavigate(o,e=!1){this.navClick.next({url:o,leaveNavOpen:e})}hideNav(){this.navClick.next({hideNav:!0})}goToProfilePage(){let o=this.apInfo&&this.apInfo.passport&&this.apInfo.passport.alias;this.objService.setParam(j,"progress"),this.hideNaviAndNavigate(Ee+"/"+o+"/profile")}goToCertificatePage(){let o=this.apInfo&&this.apInfo.passport&&this.apInfo.passport.alias;this.objService.setParam(j,"progress"),this.hideNaviAndNavigate(Ee+"/"+o+"/certificate")}isLinkActive(o){return this.router.url.split("?")[0]===o}static{this.\u0275fac=function(e){return new(e||t)(g(b),g(I),g(W))}}static{this.\u0275cmp=w({type:t,selectors:[["passport-nav"]],inputs:{apInfo:"apInfo"},decls:12,vars:8,consts:[[3,"navClick$","menuBtnName"],["adaptiveMinHeight","",1,"d-flex","align-items-start","nav-container"],[1,"w-100"],[1,"btn","btn-sm","btn-quiet","float-right","close-btn","d-lg-none",3,"click"],["theme","bold","name","close","size","f-caption",3,"svgStyle"],[1,"f-2","ml-7","mt-0","mb-7"],[1,"portfolio-nav","mb-7"],["href","/my-passport/aged-care/profile",1,"portfolio-nav-item",3,"click"],["href","/my-passport/aged-care/certificate",1,"portfolio-nav-item",3,"click"]],template:function(e,i){e&1&&(s(0,"mn-shared-nav",0)(1,"div",1)(2,"div",2)(3,"button",3),P("click",function(){return i.hideNav()}),f(4,"ui-streamline-icon",4),a(),s(5,"h1",5),p(6,"Passport"),a(),s(7,"div",6)(8,"a",7),P("click",function(u){return u.preventDefault(),i.goToProfilePage()}),p(9," Progress "),a(),s(10,"a",8),P("click",function(u){return u.preventDefault(),i.goToCertificatePage()}),p(11," Certificate "),a()()()()()),e&2&&(d("navClick$",i.navClick)("menuBtnName","Passport menu"),r(4),d("svgStyle",D(7,Jt)),r(4),we("is-active",i.isLinkActive("/my-passport/aged-care/profile")),r(2),we("is-active",i.isLinkActive("/my-passport/aged-care/certificate")))},dependencies:[_t,ht,x],styles:[".nav-container[_ngcontent-%COMP%]{width:100%;background-color:#f8f9fb;z-index:6;min-width:287px;width:287px;margin-left:0;padding-right:19px;padding-top:24px;position:sticky;top:65px}@media(max-width:1023.98px){.nav-container[_ngcontent-%COMP%]{min-height:100vh!important;max-height:100vh;overflow:auto}}.portfolio-nav[_ngcontent-%COMP%]{display:flex;width:100%;padding:0 0 1.25rem;text-align:left;flex-direction:column;white-space:normal;max-width:300px;gap:0}.portfolio-nav-item[_ngcontent-%COMP%]{font-weight:600;padding:8px 32px;text-decoration:none;transition:background-color ease-in-out .1s;border-radius:0 30px 30px 0}.portfolio-nav-item[_ngcontent-%COMP%]:hover{background:#edeff2;color:#171d29}.portfolio-nav-item.is-active[_ngcontent-%COMP%]{color:#ac021e;background:#fde3e7}.portfolio-nav-item.sub-item-active[_ngcontent-%COMP%]{background:#edeff2;color:#171d29}"]})}};var ee=(t,o)=>o.passportModule.resourceID;function ii(t,o){t&1&&(s(0,"div",2),f(1,"ui-spinner",4),a())}function ni(t,o){if(t&1&&f(0,"pm-header",1),t&2){let e=l(2);d("apInfo",e.apInfo)}}function oi(t,o){t&1&&(s(0,"div",6)(1,"ui-info-box",14),f(2,"ui-streamline-icon",15),s(3,"div",16)(4,"span",17),p(5," Completing the Ausmed Passport is voluntary for your own professional development except where an organisation has assigned learning for Passport resources to you through the My Organisation portal. "),a()()()()),t&2&&(r(),d("paddingSize",4))}function ri(t,o){t&1&&(s(0,"span",25),p(1,"In progress"),a())}function ai(t,o){if(t&1){let e=O();s(0,"button",30),P("click",function(){y(e);let n=l(3);return A(n.viewNextResource())}),p(1),a()}if(t&2){let e=l(3);r(),C(" ",e.getPMActAction(o)," ")}}function si(t,o){if(t&1){let e=O();s(0,"button",31),P("click",function(){y(e);let n=l(3);return A(n.viewNextResource())}),p(1),a()}if(t&2){let e=l(3);r(),C(" ",e.getPMActAction(o)," ")}}function pi(t,o){if(t&1&&(s(0,"div",7)(1,"div",18),p(2),a(),s(3,"div",19)(4,"div",20)(5,"div"),f(6,"img",21),a(),s(7,"div",22)(8,"div",23)(9,"h4",24),p(10),a(),c(11,ri,2,0,"span",25),a(),s(12,"div",26),p(13),K(14,"cpdTime"),a()(),s(15,"div",27),c(16,ai,2,1,"button",28),a()(),c(17,si,2,1,"button",29),a()()),t&2){let e,i,n=l(2);r(2),C(" ",(n.nextModule.compCal==null?null:n.nextModule.compCal.fn_status)===n.EPMActStatus.pristine?"Get started:":"Continue with:"," "),r(4),d("src",n.getModuleImg(n.injector,n.nextModule),J),r(4),C(" ",n.nextModule.passportModule.resource.title," "),r(),m((n.nextModule.compCal==null?null:n.nextModule.compCal.fn_status)===n.EPMActStatus.inProgress?11:-1),r(2),C(" ",Q(14,7,n.nextModule.passportModule.resource.min,"hour","lng")," "),r(3),m((e=n.nextModule.compCal==null?null:n.nextModule.compCal.fn_status)?16:-1,e),r(),m((i=n.nextModule.compCal==null?null:n.nextModule.compCal.fn_status)?17:-1,i)}}function li(t,o){if(t&1&&(s(0,"div",34),f(1,"pm-act",35),a()),t&2){let e=o.$implicit,i=l(4);r(),d("pm",e)("passport",i.apInfo.passport)}}
1function ci(t,o){if(t&1&&(s(0,"div")(1,"h3",33),p(2,"Not Valid"),a(),$(3,li,2,2,"div",34,ee),a()),t&2){let e=l(3);r(3),B(e.expiredModules)}}function mi(t,o){if(t&1&&(s(0,"div",34),f(1,"pm-act",35),a()),t&2){let e=o.$implicit,i=l(4);r(),d("pm",e)("passport",i.apInfo.passport)}}function di(t,o){if(t&1&&(s(0,"div",32)(1,"h3",33),p(2,"Expiring Soon"),a(),$(3,mi,2,2,"div",34,ee),a()),t&2){let e=l(3);r(3),B(e.expiringModules)}}function fi(t,o){if(t&1&&(s(0,"div",34),f(1,"pm-act",35),a()),t&2){let e=o.$implicit,i=l(4);r(),d("pm",e)("passport",i.apInfo.passport)}}function ui(t,o){if(t&1&&(s(0,"div",32)(1,"h3",33),p(2,"In progress"),a(),$(3,fi,2,2,"div",34,ee),a()),t&2){let e=l(3);r(3),B(e.inProgressModules)}}function gi(t,o){if(t&1&&(s(0,"div",34),f(1,"pm-act",35),a()),t&2){let e=o.$implicit,i=l(4);r(),d("pm",e)("passport",i.apInfo.passport)}}function vi(t,o){if(t&1&&(s(0,"div",32)(1,"h3",33),p(2,"Valid"),a(),$(3,gi,2,2,"div",34,ee),a()),t&2){let e=l(3);r(3),B(e.completeModules)}}function Ci(t,o){if(t&1&&(s(0,"div",8),c(1,ci,5,0,"div"),c(2,di,5,0,"div",32),c(3,ui,5,0,"div",32),c(4,vi,5,0,"div",32),a()),t&2){let e=l(2);r(),m(e.expiredModules!=null&&e.expiredModules.length?1:-1),r(),m(e.expiringModules!=null&&e.expiringModules.length?2:-1),r(),m(e.inProgressModules!=null&&e.inProgressModules.length?3:-1),r(),m(e.completeModules!=null&&e.completeModules.length?4:-1)}}function Pi(t,o){if(t&1&&(s(0,"div",34),f(1,"pm-act",35),a()),t&2){let e=o.$implicit,i=l(4);r(),d("pm",e)("passport",i.apInfo.passport)}}function hi(t,o){if(t&1&&(s(0,"div")(1,"h3",36),p(2),a(),$(3,Pi,2,2,"div",34,ee),a()),t&2){let e=l(3);r(2),C(" ",e.allModules.length," training activities "),r(),B(e.allModules)}}function _i(t,o){if(t&1&&(s(0,"div",8),c(1,hi,5,1,"div"),a()),t&2){let e=l(2);r(),m(e.allModules!=null&&e.allModules.length?1:-1)}}function xi(t,o){t&1&&(s(0,"div",11)(1,"h4",37),p(2,"Earn Your Certificate"),a(),s(3,"p",37),p(4," Complete all modules to earn a certificate of completion. "),a()())}function Mi(t,o){if(t&1){let e=O();s(0,"h4",38),p(1,"Passport Certificate Unlocked"),a(),s(2,"button",39),P("click",function(){y(e);let n=l(2);return A(n.gotoCert())}),p(3,"View my certificate"),a()}}function Ii(t,o){if(t&1){let e=O();s(0,"div",3),c(1,ni,1,1,"pm-header",1),f(2,"pm-status-display",5),c(3,oi,6,1,"div",6),c(4,pi,18,11,"div",7),s(5,"div"),c(6,Ci,5,4,"div",8),c(7,_i,2,1,"div",8),s(8,"div",9),f(9,"ap-check-badge",10),c(10,xi,5,0,"div",11)(11,Mi,4,0),a(),s(12,"div",12)(13,"button",13),P("click",function(){y(e);let n=l();return A(n.unenroll())}),p(14," Click here to manage your Passport enrollment settings "),a()()()()}if(t&2){let e=l();r(),m(e.apInfo?1:-1),r(),d("apInfo",e.apInfo)("allModules",e.allModules),r(),m(e.activeOrgLinks!=null&&e.activeOrgLinks.length?3:-1),r(),m(e.nextModule?4:-1),r(2),m(e.hasCompeletedOnce?6:-1),r(),m(e.hasCompeletedOnce?-1:7),r(3),m(e.remainingMin?10:11)}}var be=class t extends ue(){constructor(e,i,n,u,h,X,M,Ae,Wt,Li,Ni,Ri){super();this.route=e;this.router=i;this.apService=n;this.learningProgressService=u;this.injector=h;this.analytics=X;this.titleService=M;this.objService=Ae;this.userService=Wt;this.dialog=Li;this.toastrService=Ni;this.orgService=Ri;this.expiredModules=[];this.expiringModules=[];this.inProgressModules=[];this.completeModules=[];this.Math=Math;this.remainingMin=0;this.EPMActStatus=ke;this.loaded=!1;this.getModuleImg=gt;this.getPMActAction=Et;this.alias=ft;this.enrolled=!1;this.unenrolled=!1;this.hideDeclinedButton=!0}ngOnInit(){this.titleService.setTitle("Aged Care Training Passport for Workers | Digital Certificate | Ausmed"),this.apService.fetchPassports().pipe(_(e=>{this.allPassports=e;let i=H(e,this.alias);this.passportID=i.passportID}),v(()=>this.apService.fetchEnrollWithComps()),v(e=>(this.ecs=e,this.apService.getProcessedEC$(this.passportID))),this.untilDestroyed()).subscribe(e=>{this.enrolled=Y(e&&e.enrolment),this.unenrolled=e&&e.enrolment&&e.enrolment.status==="Unenrolled",this.hideDeclinedButton=e&&!!e.enrolment,this.enrolled&&(this.enrolmentID=e.enrolment&&e.enrolment.enrolmentID)}),this.route.data.pipe(v(e=>{let i=e.ec,n=i.enrolment.passportID;return this.apService.fetchPassportByID(n).pipe(R(u=>(this.passport=u,u.passportModules&&u.passportModules.length&&(u.passportModules=Xe(u.passportModules,h=>h.order)),Ce(i,u))))}),v(e=>{let i=e&&mt(e.modules);return!i||!i.length?(this.router.navigate(["/dashboard"]),N):(this.apInfo=e,this.hasCompeletedOnce=Pe(e.enrolment),this.learningProgressService.fetchAllProgressWraps())}),this.untilDestroyed()).subscribe(()=>{this.clearData(),this.allModules=this.apInfo.modules.map(e=>ne(ie({},e),{progress:this.learningProgressService.getProgressByID(e.passportModule.resourceID)})),le(this.allModules,e=>{let{resource:i}=e.passportModule;i&&i.min&&(ce(["complete","expiring"],e.compCal?.fn_status)||(this.remainingMin+=i.min));let n=e.compCal.fn_status;this.hasCompeletedOnce&&(n==="expired"?this.expiredModules.push(e):n==="expiring"?this.expiringModules.push(e):n==="inProgress"?this.inProgressModules.push(e):n==="complete"&&this.completeModules.push(e))}),this.trackViewed(),this.nextModule=ct(this.allModules,this.hasCompeletedOnce),this.loaded=!0}),this.orgService.getActiveOrgLinks$().pipe(this.untilDestroyed()).subscribe({next:e=>{this.activeOrgLinks=e},error:e=>{console.error("Error fetching active org links:",e)}})}gotoCert(){let e=this.apInfo&&this.apInfo.passport&&this.apInfo.passport.alias;e&<(this.injector,e,"progress")}
1viewNextResource(){if(!this.nextModule)return;let e=this.nextModule.passportModule.resource;this.analytics.track("AP-resource-viewed",{source:"website",context:"profile",resource:e,alias:this.passport.alias});let i=e.aliasObject&&e.aliasObject.alias||e.resourceID;this.router.navigate(["/cpd/courses/",i])}unenroll(){let e=this.userService.getPlainUser();this.dialog.open(qe,{disableClose:!0,panelClass:"ui-dialog",data:{title:"Unenrol from Passport",message:"You are currently enrolled in the Ausmed Passport.",acceptMessage:"Unenrol"}}).afterClosed().pipe(v(n=>n?this.apService.unEnrol(this.passportID,this.enrolmentID):oe(null))).subscribe(n=>{n&&(ut(this.injector,this.allPassports,n,e&&e.userID),this.analytics.track("AP-enrolment-unenrolled",{source:"website",context:"settings",alias:this.alias}),this.toastrService.clear(),this.toastrService.success("Successfully unenrol"),this.router.navigate(["/my-passport/aged-care"]))},n=>{this.toastrService.clear(),this.toastrService.error("We're sorry, something's not right at our end. Please try again later.")})}trackViewed(){let e=this.apInfo.passportStatus,i=this.objService.getParam(j);this.analytics.track("AP-passport-viewed",{source:"website",status:e,alias:this.apInfo.passport.alias,context:i||void 0,location:"progress"})}clearData(){this.remainingMin=0,this.expiredModules=[],this.expiringModules=[],this.inProgressModules=[],this.completeModules=[],this.nextModule=null}static{this.\u0275fac=function(i){return new(i||t)(g(se),g(b),g(k),g(fe),g(I),g(me),g(We),g(W),g(de),g(pe),g(nt),g(Ke))}}static{this.\u0275cmp=w({type:t,selectors:[["ng-component"]],standalone:!1,features:[ae],decls:4,vars:3,consts:[[1,"d-lg-flex","min-vh-100"],[3,"apInfo"],[1,"mt-4","w-100","text-center","ap-spinner"],[1,"w-100"],["size","xl","color","dark"],[3,"apInfo","allModules"],[1,"pm-content","mb-4"],[1,"pm-content","mt-6","mb-7"],[1,"pm-content"],[1,"pm-content","mt-5","pb-7","d-flex","flex-row","align-items-center"],["status","complete","size","4rem"],[1,"d-flex","flex-column","ml-2"],[1,"align-items-center","d-flex","flex-row","mt-10","pb-7","pm-content"],[1,"f-5","mb-0","ml-2","text-neutral-800","btn","btn-link",3,"click"],["theme","yellow-light",1,"mb-4",3,"paddingSize"],["left-slot","","theme","bold","name","alert-circle","size","f-caption","bottomOffset","2",1,"mr-2"],["header","",1,"d-flex","justify-content-between","w-100"],["header",""],[1,"f-small","text-dark","mb-3","pm-sm-title"],[1,"p-2","next-module-card"],[1,"d-flex","flex-row","align-items-center"],["onerror","this.src='src/images/image-missing.gif';","alt","next module",1,"pm-module-thumbnail","mr-3","mb-2","mb-sm-0",3,"src"],[1,"d-flex","flex-column"],[1,"d-inline-flex","mb-1"],[1,"text-dark","mr-2","mb-0"],[1,"badge","badge-weak-light","d-none","d-md-block","mr-4","next-badge"],[1,"f-small","text-neutral-700"],[1,"ml-sm-auto"],[1,"btn","btn-primary-light","d-none","d-sm-block","text-nowrap"],[1,"btn","btn-primary-light","btn-block","text-nowrap","d-sm-none"],[1,"btn","btn-primary-light","d-none","d-sm-block","text-nowrap",3,"click"],[1,"btn","btn-primary-light","btn-block","text-nowrap","d-sm-none",3,"click"],[1,"mb-5"],[1,"text-dark","pt-5","mb-5"],[1,"mb-3"],[3,"pm","passport"],[1,"text-dark","pt-5","mb-5","pm-sm-title"],[1,"mb-0"],[1,"mb-0","ml-3","flex-grow-1"],[1,"btn","btn-link","btn-large",3,"click"]],template:function(i,n){i&1&&(s(0,"div",0),f(1,"passport-nav",1),c(2,ii,2,0,"div",2),c(3,Ii,15,8,"div",3),a()),i&2&&(r(),d("apInfo",n.apInfo),r(),m(n.loaded?-1:2),r(),m(n.loaded?3:-1))},dependencies:[x,_e,xe,wt,ge,T,E,ot,he],styles:[".pm-content[_ngcontent-%COMP%]{margin:auto}@media(min-width:576px){.pm-content[_ngcontent-%COMP%]{width:80%}}@media(max-width:575.98px){.pm-content[_ngcontent-%COMP%]{max-width:23rem}}.pm-content[_ngcontent-%COMP%] .next-module-card[_ngcontent-%COMP%]{padding:8px;border-radius:12px}.pm-content[_ngcontent-%COMP%] .next-module-card[_ngcontent-%COMP%]:hover{background:#f8f9fb}.pm-content-padding[_ngcontent-%COMP%]{padding-bottom:1rem;padding-top:1rem}.pm-dot[_ngcontent-%COMP%]{height:4px;width:4px;background-color:#6f7786;border-radius:50%}.pm-module-thumbnail[_ngcontent-%COMP%]{height:50px}.pm-module-btn[_ngcontent-%COMP%]{width:84px}.sl-icon[_ngcontent-%COMP%]{padding-bottom:2px}.next-badge[_ngcontent-%COMP%]{height:24px;line-height:unset}@media(max-width:575.98px){.pm-sm-title[_ngcontent-%COMP%]{padding-left:.5rem}}"]})}};var G=class t{constructor(o,e,i){this.router=o;this.apService=e;this.injector=i}resolve(o){let e=o.params.alias;return this.apService.fetchPassports().pipe(U(1),_(n=>{let u=H(n,e);u||this.router.navigate(["/dashboard"]),this.passportID=u.passportID})).pipe(v(()=>this.apService.fetchEnrollWithComps()),v(()=>this.apService.getProcessedEC$(this.passportID)),U(1),_(n=>{Y(n&&n.enrolment)||st(this.injector,e)}))}static{this.\u0275fac=function(e){return new(e||t)(S(b),S(k),S(I))}}static{this.\u0275prov=re({token:t,factory:t.\u0275fac})}};var $t;function Bt(t,o,e){if($t)return N;let i=window.innerWidth<768?"95%":"70%";return t.get(pe).open(Dt,{data:{resourceLink:o,context:e,disableEvent:!0},disableClose:!0,width:i,panelClass:"context-flow-dialog"}).afterClosed().pipe(Ne(()=>$t=!1))}var Te=Yt(Ht());var bi=()=>["/passport/approved-providers"];function Si(t,o){t&1&&(s(0,"div",2),f(1,"ui-spinner",4),a())}function yi(t,o){t&1&&p(0,"resource")}function Ai(t,o){t&1&&p(0,"resources")}function wi(t,o){if(t&1&&(s(0,"div",8),f(1,"img",11),s(2,"h4",12),p(3,"Complete all resources to earn your digital certificate"),a(),s(4,"p"),Fe(5,13),p(6),Ue(7,yi,1,0,"ng-template",14)(8,Ai,1,0,"ng-template",15),Ve(),p(9," to go. "),a()()),t&2){let e=l(2);r(),d("lazyLoad",e.certificateImg),r(4),d("ngPlural",e.remainResources),r(),C(" You have ",e.remainResources," ")}}function ki(t,o){if(t&1&&(s(0,"p"),p(1),a()),t&2){let e=l(3);r(),C("Congratulations on completing the ",e.apInfo.passport.name,"!")}}function Ei(t,o){t&1&&(s(0,"p"),p(1,"To keep your Passport Certificate valid, please review any training activities on a continual basis before they expire."),a())}function Oi(t,o){if(t&1&&(s(0,"a",21),f(1,"img",23),a()),t&2){let e=l(3);d("href",e.linkedinUrl,J)}}function Di(t,o){if(t&1){let e=O();s(0,"div",9)(1,"div",16)(2,"h2"),p(3,"Ausmed Passport\u2122 Certificate"),a(),c(4,ki,2,1,"p"),c(5,Ei,2,0,"p"),s(6,"p"),p(7,"Training activities are valid for 1 year after completion. Renew them before they expire to keep your certificate valid."),a(),s(8,"p"),p(9,"Ausmed will automatically send you email reminders when training is about to expire."),a(),s(10,"a",17),p(11,"Click here to see a list of employers who recognise the Ausmed Passport\u2122"),a(),s(12,"div",18)(13,"a",19),P("click",function(){y(e);let n=l(2);return A(n.downloadPDF())}),p(14,"Download PDF"),a(),s(15,"a",20),P("click",function(){y(e);let n=l(2);return A(n.share())}),p(16,"Share"),a(),c(17,Oi,2,1,"a",21),a()(),s(18,"div"),f(19,"ui-certificate-preview",22),a()()}if(t&2){let e=l(2);r(4),m(e.apInfo.passportStatus===e.EAPPassportStatus.complete?4:-1),r(),m(e.apInfo.passportStatus!==e.EAPPassportStatus.complete?5:-1),r(5),d("routerLink",D(7,bi)),r(3),d("href",e.url,J),r(4),m(e.linkedinUrl?17:-1),r(2),d("user",e.user)("apInfo",e.apInfo)}}function ji(t,o){if(t&1&&(s(0,"div",3),f(1,"pm-header",5)(2,"pm-status-display",6),s(3,"div",7),c(4,wi,10,3,"div",8),c(5,Di,20,8,"div",9),f(6,"passport-act-progress-list",10),a()()),t&2){let e=l();r(),d("apInfo",e.apInfo)("tabNum",1),r(),d("apInfo",e.apInfo)("allModules",e.allModules),r(2),m(e.hasCompletedOnce?-1:4),r(),m(e.hasCompletedOnce?5:-1),r(),d("modules",e.allModules)("passport",e.apInfo.passport)}}var Se=class t extends ue(){constructor(e,i,n,u,h,X,M,Ae,Wt){super();this.route=e;this.router=i;this.userService=n;this.apService=u;
1this.analytics=h;this.injector=X;this.learningProgressService=M;this.cdr=Ae;this.objService=Wt;this.loaded=!1;this.hasCompletedOnce=!0;this.copied=!1;this.valid=!1;this.EAPPassportStatus=at}ngOnInit(){let e=this.userService.getUser().pipe(_(n=>{this.user=n})),i=this.route.data.pipe(v(n=>{let u=n.ec,h=u?u.enrolment.passportID:this.route.snapshot.params.id;return h?this.apService.fetchPassportByID(h).pipe(R(X=>Ce(u,X))):(this.router.navigate(["/dashboard"]),N)}),v(n=>{this.apInfo=n,this.valid=Ct(this.apInfo.passportStatus),this.certificateImg=dt(this.apInfo.passport.alias,"cert");let u=this.apInfo.enrolment&&this.apInfo.enrolment.alias;if(this.externalLink=vt(u),this.linkedinUrl=this.generateLinkedinUrl(this.apInfo),this.hasCompletedOnce=Pe(this.apInfo.enrolment),!this.hasCompletedOnce){let M=this.apInfo.summary;this.remainResources=M.total-M.complete-M.expiring}let h=this.apService.getCertificatePDF(u).pipe(_(M=>this.url=M.url)),X=this.learningProgressService.fetchAllProgressWraps().pipe(_(()=>{this.allModules=Ge(this.apInfo.modules,M=>{let Ae=this.learningProgressService.getProgressByID(M.passportModule.resourceID);return ne(ie({},M),{progress:Ae})}),this.cdr.detectChanges()}));return q([h,X])}));q([e,i]).pipe(this.untilDestroyed()).subscribe(()=>{this.trackViewed(),this.loaded=!0})}clickCopyButton(){this.analytics.track("AP-certificate-shared",{source:"website",context:"certificate page",type:"self",alias:this.apInfo.passport&&this.apInfo.passport.alias}),this.copied=!0,setInterval(()=>{this.copied=!1},2e3)}downloadPDF(){this.analytics.track("AP-certificate-downloaded",{source:"website",status:this.apInfo&&this.apInfo.passportStatus,type:"self",alias:this.apInfo.passport&&this.apInfo.passport.alias})}generateLinkedinUrl(e){let i=e.enrolment?.completionLocalDate&&(0,Te.default)(e.enrolment?.completionLocalDate),n=e.enrolment?.expiryLocalDate&&(0,Te.default)(e.enrolment?.expiryLocalDate);return i&&n?`https://www.linkedin.com/profile/add?startTask=CERTIFICATION_NAME&name=Ausmed%20Passport&organizationId=217896&issueYear=${i.year()}&issueMonth=${i.month()}&expirationYear=${n.year()}&expirationMonth=${n.month()}&certUrl=${encodeURIComponent(this.externalLink)}&certId=${this.apInfo.enrolment?.alias}`:null}share(){this.analytics.track("AP-certificate-shared",{source:"website",context:"certificate page",type:"self",alias:this.apInfo.passport&&this.apInfo.passport.alias}),Bt(this.injector,this.externalLink,{source:"website",context:"certificate page",type:"self",alias:this.apInfo.passport&&this.apInfo.passport.alias})}trackViewed(){let e=this.apInfo.passportStatus,i=this.objService.getParam(j);this.analytics.track("AP-passport-viewed",{source:"website",status:e,alias:this.apInfo.passport.alias,context:i||void 0,location:"certificate"})}static{this.\u0275fac=function(i){return new(i||t)(g(se),g(b),g(de),g(k),g(me),g(I),g(fe),g($e),g(W))}}static{this.\u0275cmp=w({type:t,selectors:[["app-ap-certificate"]],standalone:!1,features:[ae],decls:4,vars:3,consts:[[1,"d-lg-flex","min-vh-100"],[3,"apInfo"],[1,"mt-4","w-100","text-center","ap-spinner"],[1,"w-100"],["size","xl","color","dark"],[3,"apInfo","tabNum"],[3,"apInfo","allModules"],[1,"certificate_wrapper"],[1,"incomplete-certificate","mx-auto","text-center","p-6"],[1,"complete-certificate","mx-auto"],[3,"modules","passport"],["src","./images/image-missing.gif","alt","certificate image",1,"certificate-img",3,"lazyLoad"],[1,"title"],[3,"ngPlural"],["ngPluralCase","1"],["ngPluralCase","other"],[1,"info-block"],["href","javascript:void(0)",3,"routerLink"],[1,"d-flex","flex-md-row","flex-column","flex-wrap"],["target","_blank",1,"btn","btn-primary-light","my-2","mr-md-1",3,"click","href"],[1,"btn","btn-primary","my-2","mr-md-1",3,"click"],["target","_blank",1,"my-2","mx-auto","mx-md-0",3,"href"],[3,"user","apInfo"],["src","https://download.linkedin.com/desktop/add2profile/buttons/en_US.png ","alt","LinkedIn Add to Profile button"]],template:function(i,n){i&1&&(s(0,"div",0),f(1,"passport-nav",1),c(2,Si,2,0,"div",2),c(3,ji,7,8,"div",3),a()),i&2&&(r(),d("apInfo",n.apInfo),r(),m(n.loaded?-1:2),r(),m(n.loaded?3:-1))},dependencies:[Be,ze,Ye,tt,jt,xe,Lt,ge,T,E],styles:[".certificate_wrapper[_ngcontent-%COMP%]{background-color:#fff;padding:32px 16px}@media(min-width:768px){.certificate_wrapper[_ngcontent-%COMP%]{padding:32px}}.certificate_wrapper[_ngcontent-%COMP%] .incomplete-certificate[_ngcontent-%COMP%]{border-radius:12px;background-color:#fff;width:100%;max-width:900px}.certificate_wrapper[_ngcontent-%COMP%] .incomplete-certificate[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-weight:600}.certificate_wrapper[_ngcontent-%COMP%] .incomplete-certificate[_ngcontent-%COMP%] .certificate-img[_ngcontent-%COMP%]{margin:24px;width:120px;max-width:90%;transform:rotate(12deg);box-shadow:0 0 3px #0000001a,0 4px 20px #00000026}.certificate_wrapper[_ngcontent-%COMP%] .complete-certificate[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr;align-items:start;row-gap:16px;width:100%;max-width:850px}@media(min-width:768px){.certificate_wrapper[_ngcontent-%COMP%] .complete-certificate[_ngcontent-%COMP%]{grid-template-columns:1fr minmax(420px,1fr);column-gap:24px}}.certificate_wrapper[_ngcontent-%COMP%] .complete-certificate[_ngcontent-%COMP%] .info-block[_ngcontent-%COMP%]{background-color:#fff;border-radius:12px;padding:16px}.certificate_wrapper[_ngcontent-%COMP%] .complete-certificate[_ngcontent-%COMP%] .info-block[_ngcontent-%COMP%] .split-line[_ngcontent-%COMP%]{text-align:center;border-bottom:1px solid #6F7786;line-height:.1em;margin:10px 0}.certificate_wrapper[_ngcontent-%COMP%] .complete-certificate[_ngcontent-%COMP%] .info-block[_ngcontent-%COMP%] .split-line[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{background-color:#fff;color:#6f7786;padding:0 10px}.certificate_wrapper[_ngcontent-%COMP%] .complete-certificate[_ngcontent-%COMP%] .certificate-block[_ngcontent-%COMP%]{background-color:#fff;box-shadow:0 0 2.14286px #0000001a,0 2.85714px 14.2857px #00000026;padding:16px}"]})}};var te=class t{constructor(o,e,i,n){this.router=o;this.apService=e;this.injector=i;this.authService=n}resolve(o){let e=o.params.alias,i=this.apService.fetchPassports().pipe(U(1),_(u=>{let h=H(u,e);h||this.router.navigate(["/dashboard"]),this.passport=h})),n=this.authService.isAuthenticated()?this.apService.fetchEnrollWithComps():oe(null);return q([i,n]).pipe(v(()=>this.apService.getProcessedEC$(this.passport.passportID)),U(1),R(u=>(Y(u&&u.enrolment)&&pt(this.injector,e),this.passport)))}static{this.\u0275fac=function(e){return new(e||t)(S(b),S(k),S(I),S(Je))}}static{this.\u0275prov=re({token:t,factory:t.\u0275fac})}};var ye=class t{static{this.\u0275fac=function(e){return new(e||t)}}static{this.\u0275mod=V({type:t})}static{this.\u0275inj=F({imports:[z,It,x,bt,E]})}};var Ti=[{path:":alias",loadComponent:()=>import("./chunk-VOJCPV7E.js").then(t=>t.PassportLandingPageComponent),resolve:{passport:te}},{path:":alias/profile",component:be,resolve:{ec:G},canActivate:[Oe]},{path:":alias/certificate",component:Se,resolve:{ec:G},canActivate:[Oe]}],zt=class t{static{this.\u0275fac=function(e){return new(e||t)}}static{this.\u0275mod=V({type:t})}static{this.\u0275inj=F({providers:[G,te],imports:[z,He.forChild(Ti),x,et,xt,_e,Z,it,ve,rt,At,Ze,Mt,Tt,Ot,kt,Nt,St,Qe,Me,ye,Pt]})}};export{zt as AusmedPassportModule};
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.