1"use strict";(self.webpackChunkonboarding_app=self.webpackChunkonboarding_app||[]).push([[527],{1527:(I,r,s)=>{s.r(r),s.d(r,{NationalityModule:()=>n});var d=s(6895),t=s(4650),h=s(9841),c=s(2709),v=s(9126),f=s(2930),S=s(1103),y=s(5817),C=s(7744),g=s(4847),u=s(4358);function N(o,e){1&o&&(t.TgZ(0,"alert",3),t._uU(1,"Please select nationality"),t.qZA())}const m="nationality";class l{constructor(e,i){this.store=e,this.stepsService=i,this.next=new t.vpe,this.dictionaries$=this.store.select(c.X),this.member$=this.store.select(c.FC)}ngOnInit(){this.stepsService.setCurrentStep(m),this.currentStepSubscription=this.stepsService.currentStep.subscribe(e=>{this.step=e}),this.memberSubscription=(0,h.a)([this.member$,this.dictionaries$]).subscribe(([e,i])=>{const p=i.dictionaries?.lookupOptions.find(a=>"nationalitylookup"===a.name),z=e.lookups?.find(a=>a.lookupId===p?.lookupId);p&&(this.nationalities=p.options.map(a=>({...a,selected:a.id===z?.id})))})}ngOnDestroy(){this.memberSubscription?.unsubscribe(),this.currentStepSubscription?.unsubscribe()}valid(){return!!this.nationalities?.find(e=>e.selected)}saveState(){const e=this.nationalities?.find(i=>i.selected);e&&this.store.dispatch(v._0.setLookupValue({lookupValue:e}))}goToNextStep(){this.stepsService.submitted(m,this.valid()),this.valid()&&(this.saveState(),this.stepsService.navigateNext(),this.next.emit())}}l.\u0275fac=function(e){return new(e||l)(t.Y36(f.yh),t.Y36(S.K))},l.\u0275cmp=t.Xpm({type:l,selectors:[["app-nationality"]],hostAttrs:[2,"display","contents"],outputs:{next:"next"},decls:4,vars:4,consts:[[3,"nextStepClicked","previousStepClicked"],[1,"d-flex","flex-wrap",3,"items","multiple","header"],["class","d-block mt-2 mb-2","type","danger",4,"ngIf"],["type","danger",1,"d-block","mt-2","mb-2"]],template:function(e,i){1&e&&(t.TgZ(0,"app-wizard-step",0),t.NdJ("nextStepClicked",function(){return i.goToNextStep()})("previousStepClicked",function(){return i.saveState()}),t._UZ(1,"app-step-tip")(2,"app-lookup-editor",1),t.YNc(3,N,2,0,"alert",2),t.qZA()),2&e&&(t.xp6(2),t.Q6J("items",i.nationalities)("multiple",!1)("header",null==i.step?null:i.step.header),t.xp6(1),t.Q6J("ngIf",!i.valid()&&(null==i.step?null:i.step.submitted)))},dependencies:[d.O5,y.G,C.I,g.a,u.wx]});var b=s(4006),x=s(8018),T=s(5688),k=s(4463);class n{}n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=t.oAB({type:n}),n.\u0275inj=t.cJS({imports:[d.ez,T.m,x.Bz.forChild([{path:"",component:l}]),b.UX,u.nM,k.aw]})}}]);
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.