(self.webpackChunkraisin_ui=self.webpackChunkraisin_ui||[]).push([[179],{61142:(Z,K,t)=>{"use strict";t.d(K,{Be:()=>n});class s{constructor(){this.patternForZeroOrPositiveDecimalNumber="^0*[1-9]([0-9]){0,6}$"}generateGUID(){for(var P=[],D=0;D<256;D++)P[D]=(D<16?"0":"")+D.toString(16);var I=4294967295*Math.random()|0,T=4294967295*Math.random()|0,a=4294967295*Math.random()|0,y=4294967295*Math.random()|0;return P[255&I]+P[I>>8&255]+P[I>>16&255]+P[I>>24&255]+"-"+P[255&T]+P[T>>8&255]+"-"+P[T>>16&15|64]+P[T>>24&255]+"-"+P[63&a|128]+P[a>>8&255]+"-"+P[a>>16&255]+P[a>>24&255]+P[255&y]+P[y>>8&255]+P[y>>16&255]+P[y>>24&255]}stringFormat(P,D){if(!P)return"";for(var I=0;I<D.length;++I)P=P.replace("{"+I+"}",D[I]);return P}isEmpty(P){for(var D in P)if(P.hasOwnProperty(D))return!1;return!0}activateWidget(P){if(P){var D="twitter-timeline",T=new RegExp("(\"|')"+D+"-social-inactive(\"|')");return P.replace(T,D)}}replace(P,D){if(P)for(var I in D)D.hasOwnProperty(I)&&(P=this.replaceToken(P,I,D[I]));return P}replaceToken(P,D,I){return P.replace(new RegExp("\\{"+D+"\\}","g"),I||"")}parseFloat(P){return/^(\-|\+)?([0-9]+(\.[0-9]+)?|Infinity)$/.test(P)?Number(P):NaN}parseGlobalizedFloat(P,D){try{return P="fr-CA"==D?P.replaceAll(".",""):P,Globalize(D).parseFloat((P||"").toString())}catch{return NaN}}globalize(P,D,I){return Globalize.format(P,D,I)}formatGlobalizedAmount(P,D){return this.globalize(P,"N2",D)}formatCurrency(P,D){return Globalize.currencyFormatter(D)(P)}isEnterKeyPressed(P){return 13==(P.keyCode||P.charCode)}scrollAndFocusOnElement(P){var D=P.parent().parent().parent().find(".ng-invalid");if(D.hasClass("mat-radio-group")){var I=D.find("input:first-of-type").first();setTimeout(()=>I.first().focus())}else D.get(0).focus({preventScroll:!0});const T=$(".site-header").height()+120;let a=P.offset().top-T;$("html,body").animate({scrollTop:a})}scrollToTopOfPageAndFocus(P){$("html,body").animate({scrollTop:0}),P&&$(P).focus()}isRealNumber(P){try{return angular.isNumber(P)&&isFinite(P)}catch{return!1}}convertCurrencyCodeToSymbol(P){switch((P||"").toString().trim().toUpperCase()){case"CAD":case"USD":return"$";case"EUR":return"\u20ac";case"GBP":return"\xa3";default:return null}}removeNullIn(P,D){var I=D[P];if(null==I)delete D[P];else if("object"==typeof I)for(var T in I)this.removeNullIn(T,I)}newGuid(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,P=>{var D=16*Math.random()|0;return("x"==P?D:3&D|8).toString(16)})}removeNulls(P){for(var D in P)this.removeNullIn(D,P)}doNonAngularSetup(P){try{this.loadWidgets(),this.ensureContentBuilderModules()}catch(D){console.log(D)}}loadWidgets(){window.populateWidgets&&window.populateWidgets()}ensureContentBuilderModules(){$('[data-module="slider"], [data-module="video"], [data-module="code"]').each((P,D)=>{const I=$(D);void 0!==I.attr("data-html")&&I.html(decodeURIComponent(I.attr("data-html")))})}luhnCheckCreditCardNumber(P){if(/[^0-9-\s]+/.test(P))return!1;for(var D=0,I=0,T=!1,a=(P=P.replace(/\D/g,"")).length-1;a>=0;a--){var y=P.charAt(a);I=parseInt(y,10),T&&(I*=2)>9&&(I-=9),D+=I,T=!T}return D%10==0}}class e{constructor(){this.fbLanguages=[{raisinId:"en-US",facebookId:"en_US"},{raisinId:"en-CA",facebookId:"en_US"},{raisinId:"fr-CA",facebookId:"fr_CA"},{raisinId:"es-ES",facebookId:"es_ES"},{raisinId:"de-CH",facebookId:"de_DE"}]}findLanguageByRaisinLanguageId(P){return languages.filter(function(D){return D.raisinId.toLocaleLowerCase()==P.toLocaleLowerCase()})[0]}reload(P){this.destroy(),window.fbAsyncInit=function(){window.FB&&window.FB.init({xfbml:!0,version:"v2.2"})};var D=this.fbLanguages.find(function(a){return a.raisinId.toLocaleLowerCase()===P.toLocaleLowerCase()})||this.fbLanguages[0],I=document.getElementsByTagName("script")[0],T=document.createElement("script");T.id="facebook-jssdk",T.src="//connect.facebook.net/"+D.facebookId+"/sdk.js",I.parentNode.insertBefore(T,I)}destroy(){window.FB&&($("#facebook-jssdk, #fb-root").remove(),delete window.FB)}}class _{constructor(){this.Utils=new s,this.FBUtils=new e}}class n{constructor(){this.Angular=new _}}},80762:(Z,K,t)=>{"use strict";t.d(K,{$:()=>u});var s=t(72550),e=t(329),_=t(99397),n=t(76328),i=t(37398),P=t(26028),D=t(40424),I=t(44057),T=t(6990),y=t(80001),f=t(21875),r=t(65879);let u=(()=>{class C{constructor(g,c,l,d,A,S,v){this.authService=g,this.rdd=c,this.cookiesService=l,this.storageService=d,this.environmentService=A,this.constituentService=S,this.breakpointService=v}login(g){return this.authService.login(this.storageService.eventParams,g).pipe((0,_.b)(c=>{this.cookiesService.setCookie(`${P.z1.CookieKeys.participantId}_${this.rdd.subEventId}`,`${c.userId}`)}),(0,n.b)(c=>this.setUpConstituent().pipe((0,i.U)(()=>c))))}logout(){this.authService.logOut();let g=this.constituentService.getConstituentFromStorage();this.breakpointService.isMobile()&&this.cookiesService.removeCookie(".ASPXAUTH"),this.setIsAnonymous(!0),this.constituentService.setAuthRole(g,P.pR.guest),this.constituentService.saveConstituent(g),g=this.constituentService.getConstituentFromStorage();const c=(0,T.cloneDeep)(g.purchaseItems);return g=this.constituentService.clear(g,!0),g.purchaseItems=c,this.constituentService.saveConstituent(g),this.authService.getAnonymousToken(this.storageService.eventParams).pipe((0,i.U)(l=>!(0,T.isEmpty)(l)))}setUpConstituent(){return this.constituentService.getConstituent(this.constituentService.getUserId()).pipe((0,i.U)(g=>{const c=g;return this.constituentService.setAuthRole(c,c.profile.userId>0?P.pR.participant:P.pR.guest),this.setIsAnonymous(!1),this.constituentService.saveConstituent(c),!0}))}setIsAnonymous(g){const c=`${P.z1.CookieKeys.isAnonymous}_${this.rdd.subEventId}`;g?(this.cookiesService.removeCookie(`${P.z1.CookieKeys.participantId}_${this.rdd.subEventId}`),this.cookiesService.removeCookie(c),this.storageService.setJWT(null)):this.cookiesService.setCookie(c,`${g}`),this.rdd.setIsAnonymous(g)}isAuthenticated(){return this.authService.updateAuthData(!this.rdd.useV3ParticipantCentre),this.authService.isLoggedIn()}regenerateToken(){return this.authService.regenerateToken(this.storageService.eventParams)}goToParticipantCentre(g,c,l,d){const A=(0,T.find)(this.rdd.languages,v=>(0,T.toLower)(v.culture)===(0,T.toLower)(c)).url;let S=`${this.environmentService.getEnvironment().baseUrl}/${this.rdd.organizationId}/${A}/login`;S+=`?token=${g}&culture=${c}&roles=${JSON.stringify(l)}&fl=${d}`,window.location.assign(S)}goToMyAccount(){this.goToParticipantCentre(this.authService.getJWT(),this.storageService.getLanguage(),this.authService.getRoles(),this.authService.isFirstLogin())}loggedInStatus(){return this.authService.loggedInStatus.asObservable()}static#t=this.\u0275fac=function(c){return new(c||C)(r.LFG(y.tH),r.LFG(e.n),r.LFG(f.x9),r.LFG(f.V1),r.LFG(s.L$),r.LFG(D.d),r.LFG(I.r))};static#e=this.\u0275prov=r.Yz7({token:C,factory:C.\u0275fac})}return C})()},26028:(Z,K,t)=>{"use strict";t.d(K,{CF:()=>b,Ci:()=>r,D7:()=>L,Ie:()=>A,MQ:()=>n,O1:()=>_,Qj:()=>P,R7:()=>i,RN:()=>g,Re:()=>e,Yg:()=>v,Yr:()=>S,cP:()=>M,fA:()=>d,gM:()=>y,id:()=>D,mP:()=>I,pR:()=>s,pt:()=>C,sB:()=>f,z1:()=>T});var s=function(R){return R.all="*",R.admin="admin",R.participant="participant",R.teamCaptain="teamCaptain",R.guest="guest",R}(s||{});const e={loginSuccess:"auth-login-success",loginFailed:"auth-login-failed",logoutSuccess:"auth-logout-success",sessionTimeout:"auth-session-timeout",notAuthenticated:"auth-not-authenticated",notAuthorized:"auth-not-authorized",closeLogin:"auth-close",responseError:"raisin.auth.response-error"},_={maxCombinedErrorCode:2031,socialIdentityAccountExists:3011},n={SevenDigit:"$1-$2",TenDigit:"$1-$2-$3",FifteenDigit:"$1"},i={Canada:"$1 $2",UnitedStatesTenDigits:"$1-$2"},P={minLength:8,maxLength:20},D={minLength:6,maxLength:20},I={1:"team",2:"equipe"},T={MinYearOfBirth:1900,MaxEcardRecipients:5,MaxPrintedcardRecipients:3,AuthJoinTeamKey:"auth_join_team_",UnlimitedItemQuantity:-1,HtmlRegex:/<[^>]*>/g,EmailRegex:/^( *)(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))( *)$/,ZeroOrPositiveDecimalNumberRegex:/^[0-9]{1,7}(\.[0-9]+)?$/,CanadaPostalCodeRegex:/^[A-Za-z]\d[A-Za-z][ ]?\d[A-Za-z]\d$/,UnitedStatesPostalCodeRegex:/(^\d{5}$)|(^\d{5}-\d{4}$)/,FrancePostalCodeRegex:/^\d{5}$/,OtherPostalCodeRegex:/^([A-Za-z0-9]|-| ){1,20}$/,CanadaOrUSPhoneRegex:/^\(?([0-9]{3})\)?[-. ]?([0-9]{3})[-. ]?([0-9]{4})$/,MinimumPhoneNumberLength:10,InternationalRegex:/^\d{0,15}$/,MaximumPhoneNumberLength:14,EnCurrencyRegex:/^(\$?(\d*|([1-9][0-9]{0,2}(,\d{3})*))(\.\d{1,2})?)$/,FrCurrencyRegex:/^(\d*(,\d{1,2})?\s?\$?)$/,DecimalRegex:/^(\d+\.?\d{0,2}|\.\d{1,2})$/,IntegerRegex:/^\-?\d+$/,PasswordCriteriaRegex:[/[\d]+/,/[a-z]+/,/[A-Z]+/,/[^\dA-Za-z]+/],MinimunDate:"0001-01-01T00:00:00",BaseAPIUrl:"baseAPIUrl",CookieKeys:{subEventId:"rx_seid",isAnonymous:"isAnonymous",participantId:"rx_participantUserId"},KeyboardKeys:{enter:13},FlowConfiguration:[{name:"IndividualRegistration",id:1},{name:"CreateTeamRegistration",id:5},{name:"SponsorParticipant",id:22},{name:"JoinTeamRegistration",id:3},{name:"GeneralDonation",id:29},{name:"VolunteerRegistration",id:80},{name:"Store",id:27}],CCRegex:{Mastercard:"^(5[1-5]|2[2-7])\\d{14}$",Visa:"^4\\d{12}(?:\\d{3})?$",Amex:"^3[47][0-9]{13}$",Dinersclub:"^3(?:0[0-5]|[68][0-9])[0-9]{11}$",Discover:"^6(?:011|5\\d{2})\\d{12}$"},CVVRegex:{Mastercard:"^\\d{3}$",Visa:"^\\d{3}$",Amex:"^\\d{4}$",Dinersclub:"^\\d{3}$",Discover:"^\\d{3}$"},EventTypeTitle:{Pledged:"Pledged",Golf:"Golf",Gala:"Gala",DirectMail:"Direct Mail",GeneralDonation:"General Donation",PersonalPage:"Personal Pages"},PhoneMaskCanadaAndUS:{mask:"(000) 000-0000",promptChar:"_",clearPromptChar:!0},PhoneMaskOther:{mask:"##############",promptChar:" ",clearPromptChar:!0},Donation:{MinForOnlineDonation:1,MaxForOnlineDonation:1e7},Masks:{PostcodeMaskCanada:{mask:"L0L 0L0",promptChar:"_",clearPromptChar:!0},PostcodeMaskUnitedStates:{mask:"00000^0000",rules:{"^":/(-)/},promptChar:"_",clearPromptChar:!0},PostcodeMaskFrance:{mask:"00000",promptChar:"_",clearPromptChar:!0},PostcodeMaskOther:{mask:"PPPPPPPPPPPPPPPPPPPP",rules:{P:/([A-Za-z0-9]|-| )/},promptChar:"_",clearPromptChar:!0}},MonthNamesLong:{"fr-CA":["janvier","f\xe9vrier","mars","avril","mai","juin","juillet","ao\xfbt","septembre","octobre","novembre","d\xe9cembre"],"en-CA":["January","February","March","April","May","June","July","August","September","October","November","December"],"en-US":["January","February","March","April","May","June","July","August","September","October","November","December"],"es-ES":["enero","febrero","marzo","abril","mayo","junio","julio","agosto","septiembre","octubre","noviembre","diciembre"],"de-CH":["Januar","Februar","M\xe4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]},SurveyFormName:"surveyForm",OneAllConnectionTokenKey:"oneAllToken",OpenLoginModalKey:"openLoginModal",ContentRegionParticipantMainSection:6e4,ContentRegionParticipantSideWidgetsSection:60100,ContentRegionTeamMainSection:7e4,ContentRegionTeamSideWidgetsSection:70100},y={userId:0,contactType:0,title:null,firstName:null,middleName:null,lastName:null,emailType:null,email:null,username:null,password:null,confirmPassword:null,organization:null,phoneType:null,phone:null,phoneExtension:null,goal:null,dateOfBirth:null,gender:null,interfaceLanguage:1,correspondanceLanguage:1,customField1:null,customField2:null,customField3:null,customField4:null,customField5:null,address:{addressType:null,line1:null,line2:null,city:null,regionId:null,region:null,postalCode:null,countryId:1,country:null},receiveCommunications:!1,allowDistributionOfDetails:!1,privacy:!1,personalDataUseExplicitConsent:null},f={profile:{userId:0,contactType:0,constituentType:0,title:null,firstName:null,middleName:null,lastName:null,emailType:null,email:null,username:null,password:null,confirmPassword:null,organization:null,phoneType:null,phone:null,phoneExtension:null,goal:null,dateOfBirth:null,gender:null,interfaceLanguage:null,correspondanceLanguage:null,customField1:null,customField2:null,customField3:null,customField4:null,customField5:null,lastModified:"0001-01-01T00:00:00",subEventUserLastModified:"0001-01-01T00:00:00",address:{addressType:null,line1:null,line2:null,city:null,regionId:null,region:null,postalCode:null,countryId:null,country:null},receiveCommunications:!1,allowDistributionOfDetails:!1,privacy:!1,personalDataUseExplicitConsent:null},paymentDetails:{cardType:null,cardNumber:null,cvv:null,cardHolderName:null,cardExpiration:null,paymentMethod:0,payPalToken:null,payPalPayerId:null,payPalTotalAmount:0,payPalCurrency:null,isVisaCheckOutAllowed:!1,reCaptchaError:null},purchaseItems:[],surveys:[],returningUserId:null,importSubEventId:null},r={FinalStep:{Name:"Final Step",Actions:{Success:"Success"},Label:{pageView:"pageView"}},CompleteStep:{Name:"Complete Step",Actions:{continue:"Continue"}},DonationTypeStep:{Name:"Donation Type",Actions:{tabSelect:"Tab Select",frequencySelect:"Frequency Select",adminCosts:"Admin Costs",areaSupport:"Area to Support"},Label:{GeneralDonation:"General Donation",InHonour:"In Honour",InMemory:"In Memory",OneTime:"One Time",Monthly:"Monthly",Quarterly:"Quarterly",Annually:"Annually"}},TributeCard:{Name:"Tribute Type",Actions:{tabSelect:"Tab Select"}},AdminFee:{Name:"Cover Admin Fee",Actions:{selection:"selection"}},DonationDetailsStep:{Name:"Donation Detail",Actions:{selection:"selection"},Label:{Corporate:"corporate",NonCorporate:"non corporate"}},PaymentStep:{Name:"Payment Method",Actions:{paymentType:"PaymentType"},Label:{CreditCard:"creditcard",PayPal:"paypal"}}},C={AccountInformation:["Username","Password","Goal","ParticipantFund"],PersonalInformation:["UserType","Title","FirstName","MiddleName","LastName","CompanyName","EmailType","Email","PhoneType","Phone","PhoneExtension","Gender","DateOfBirth"],AddressInformation:["AutocompleteLocation","AddressType","AddressLine1","AddressLine2","Country","City","Province","PostalCode"],AdditionInfomation:["Privacy","OptOut","OptOutToShare","AllowDistributionOfDetails","PersonalDataUseExplicitConsent","Attribute1","Attribute2","Attribute3","Attribute4","Attribute5"],AdditionInfomationOtherFields:["Privacy","OptOut","OptOutToShare","AllowDistributionOfDetails"],AdditionInfomationCustomFields:["Attribute1","Attribute2","Attribute3","Attribute4","Attribute5"]},L={InputFieldHeight:24,StepFooterHeight:24,SiteHeaderFixedOffset:10,MobileWindowInnerWidthLimit:959},g=".rfx-header .rfx-header__actions ul li a:not(.language-picker)",d="https://www.facebook.com/plugins/like.php?href={{urlToShare}}&width=450&layout=standard&action=like&size=large&share=true&height=35&appId",A={HtmlBlock:"html",DonateNowButton:"rx-donate-now-button",FacebookUi:"ui-facebook",ThermometerWidget:"widget-thermometer",HonourRollWidget:"widget-honourroll",ParticipantStory:"participant-story",ParticipantBadgesWidget:"widget-participant-badges",ParticipantFitnessSummaryWidget:"widget-participant-fitness-summary"},S={successful:"Transaction successful",failed:"Transaction failed",processing:"Transaction processing"},v="text/javascript",b={Hide:"ThermometerHideTemplate",Boot:"BootThermometerTemplate",GoalOnly:"ThermometerGoalOnlyTemplate",RaisedOnly:"ThermometerRaisedOnlyTemplate"},M="Monthly Upsell"},89723:(Z,K,t)=>{"use strict";t.d(K,{Bp:()=>a,Em:()=>g,H8:()=>C,Jk:()=>q,KF:()=>S,Ky:()=>m,MK:()=>v,NI:()=>B,NQ:()=>O,Nq:()=>at,Ox:()=>r,PE:()=>p,PO:()=>A,Qz:()=>f,SQ:()=>P,Sc:()=>T,UB:()=>j,Vc:()=>n,XL:()=>_,bG:()=>b,cH:()=>M,eT:()=>H,fS:()=>e,kD:()=>y,kd:()=>F,lA:()=>nt,m5:()=>et,mQ:()=>R,n_:()=>z,oj:()=>W,po:()=>E,qG:()=>D,sW:()=>u,tw:()=>d,uC:()=>I,uy:()=>L,w$:()=>c});var e=function(o){return o[o.Forward=1]="Forward",o[o.Backward=-1]="Backward",o}(e||{}),_=function(o){return o[o.CreditCard=0]="CreditCard",o[o.PayPal=1]="PayPal",o[o.VisaCheckout=2]="VisaCheckout",o[o.Invoice=3]="Invoice",o[o.MasterPass=4]="MasterPass",o[o.None=5]="None",o[o.BankDebit=6]="BankDebit",o}(_||{}),n=function(o){return o[o.None=0]="None",o[o.Mastercard=1]="Mastercard",o[o.Visa=2]="Visa",o[o.Amex=3]="Amex",o[o.Dinersclub=4]="Dinersclub",o[o.Discover=5]="Discover",o[o.DebitCard=6]="DebitCard",o}(n||{}),P=function(o){return o[o.en_CA=1]="en_CA",o[o.fr_CA=2]="fr_CA",o[o.es_ES=3]="es_ES",o[o.de_CH=4]="de_CH",o[o.en_US=5]="en_US",o}(P||{}),D=function(o){return o[o.GeneralDonation=1]="GeneralDonation",o[o.GeneralDonationMonthly=4]="GeneralDonationMonthly",o[o.GeneralDonationQuarterly=5]="GeneralDonationQuarterly",o[o.GeneralDonationAnnual=6]="GeneralDonationAnnual",o[o.InHonourDonation=2]="InHonourDonation",o[o.InHonourDonationQuarterly=9]="InHonourDonationQuarterly",o[o.InHonourDonationAnnual=10]="InHonourDonationAnnual",o[o.InHonourDonationMonthly=7]="InHonourDonationMonthly",o[o.InMemoryDonation=3]="InMemoryDonation",o[o.InMemoryDonationMonthly=12]="InMemoryDonationMonthly",o[o.InMemoryDonationQuarterly=21]="InMemoryDonationQuarterly",o[o.InMemoryDonationAnnual=22]="InMemoryDonationAnnual",o[o.RegistrationFeeIndividual=8]="RegistrationFeeIndividual",o[o.RegistrationFeeCaptain=11]="RegistrationFeeCaptain",o[o.RegistrationFeeTeamMember=20]="RegistrationFeeTeamMember",o[o.RegistrationVolunteer=35]="RegistrationVolunteer",o[o.GolfRegistration=13]="GolfRegistration",o[o.GolfSponsorship=14]="GolfSponsorship",o[o.GolfTeamRegistration=24]="GolfTeamRegistration",o[o.GolfTeamSponsorship=25]="GolfTeamSponsorship",o[o.GalaTableRegistration=16]="GalaTableRegistration",o[o.GalaRegistration=17]="GalaRegistration",o[o.GalaTableSponsorship=18]="GalaTableSponsorship",o[o.GalaSponsorship=19]="GalaSponsorship",o[o.PersonalPageRegistrationGeneralDonation=26]="PersonalPageRegistrationGeneralDonation",o[o.PersonalPageRegistrationInHonour=27]="PersonalPageRegistrationInHonour",o[o.PersonalPageRegistrationInMemory=28]="PersonalPageRegistrationInMemory",o[o.TicketingIndividualRegistration=31]="TicketingIndividualRegistration",o[o.TicketingIndividualSponsorship=32]="TicketingIndividualSponsorship",o[o.TicketingGroupRegistration=33]="TicketingGroupRegistration",o[o.TicketingGroupSponsorship=34]="TicketingGroupSponsorship",o[o.StoreItem=15]="StoreItem",o[o.PledgeItem=23]="PledgeItem",o[o.AdminFee=29]="AdminFee",o}(D||{}),I=function(o){return o[o.Individual=0]="Individual",o[o.CompanyRepresentative=1]="CompanyRepresentative",o}(I||{}),T=function(o){return o[o.All=0]="All",o[o.Participant=1]="Participant",o[o.Team=2]="Team",o[o.SubeventGroup=3]="SubeventGroup",o}(T||{}),a=function(o){return o[o.Donation=1]="Donation",o[o.Registration=2]="Registration",o[o.Sponsorship=3]="Sponsorship",o[o.Store=4]="Store",o}(a||{}),y=function(o){return o.DonationStart="rx:search",o.Donation="rx:donation",o.RegistrationStart="rx-registration-start",o.Waiver="rx:waiver",o.ReturningParticipant="rx-returning-user",o.UserDetails="rx:user-details",o.Survey="rx:survey",o.Store="rx:store",o.Payment="rx:payment",o.Review="rx:review",o.Finish="rx:finish",o.ParticipantHome="rx:participant-home",o.Sponsor="rx:sponsor",o.JoinTeam="rx:join-team",o.CreateTeam="rx:create-team",o.AdditionalParticipants="rx-additional-participants",o.ForgotPassword="rx:forgot-password",o.ForgotUsername="rx:forgot-username",o}(y||{}),f=function(o){return o[o.PresetVisitorJoinATeam=1]="PresetVisitorJoinATeam",o[o.ReviewEdit=2]="ReviewEdit",o}(f||{}),r=function(o){return o[o.Event=1]="Event",o[o.Team=2]="Team",o[o.Participant=3]="Participant",o[o.Group=4]="Group",o}(r||{}),u=function(o){return o[o.ShowNameAndAmount=1]="ShowNameAndAmount",o[o.ShowNameOnly=2]="ShowNameOnly",o[o.ShowAnonymousAndAmount=3]="ShowAnonymousAndAmount",o[o.Custom=4]="Custom",o}(u||{}),C=function(o){return o[o.Yes=1]="Yes",o[o.No=2]="No",o}(C||{}),L=function(o){return o[o.Participant=1]="Participant",o[o.Donor=2]="Donor",o[o.Volunteer=3]="Volunteer",o[o.DirectMailDonor=4]="DirectMailDonor",o[o.OtherDonor=5]="OtherDonor",o[o.BillingContact=6]="BillingContact",o[o.PurchaserDonor=7]="PurchaserDonor",o[o.OfflineDonorForAdministrator=8]="OfflineDonorForAdministrator",o[o.OfflineDonorForParticipant=9]="OfflineDonorForParticipant",o[o.AdditionalParticipants=10]="AdditionalParticipants",o[o.Attendee=11]="Attendee",o}(L||{}),g=function(o){return o.AdminFee="AdminFeeItem",o.GeneralDonation="GeneralDonationItem",o.RegistrationIndividual="RegistrationIndividualItem",o.RegistrationTeamCaptain="RegistrationTeamCaptainItem",o.RegistrationTeamMember="RegistrationTeamMemberItem",o.RegistrationVolunteer="RegistrationVolunteerItem",o.StoreCart="StoreCartItem",o.TicketingRegistration="TicketingRegistrationItem",o.TicketingSponsorship="TicketingSponsorshipItem",o.None="",o}(g||{}),c=function(o){return o[o.PasswordRequired=1]="PasswordRequired",o[o.AlwaysOpen=2]="AlwaysOpen",o[o.CaptainDecide=3]="CaptainDecide",o}(c||{}),d=function(o){return o[o.UNSPECIFIED=-1]="UNSPECIFIED",o[o.AllTypes=0]="AllTypes",o[o.Pledged=3]="Pledged",o[o.Golf=4]="Golf",o[o.Gala=5]="Gala",o[o.DirectMail=6]="DirectMail",o[o.Donation=7]="Donation",o[o.PersonalPage=8]="PersonalPage",o[o.MultiPledged=9]="MultiPledged",o[o.Ticketing=10]="Ticketing",o[o.Donations=11]="Donations",o}(d||{}),A=function(o){return o[o.NoModule=0]="NoModule",o[o.EventHomePage=8]="EventHomePage",o[o.RegistrationStart=60]="RegistrationStart",o[o.IndividualRegistration=1]="IndividualRegistration",o[o.JoinTeamRegistration=3]="JoinTeamRegistration",o[o.CreateTeamRegistration=5]="CreateTeamRegistration",o[o.PledgeParticipantHomePage=9]="PledgeParticipantHomePage",o[o.PledgeTeamHomePage=10]="PledgeTeamHomePage",o[o.PledgeSponsor=22]="PledgeSponsor",o[o.PledgeVisitorJoinATeam=23]="PledgeVisitorJoinATeam",o[o.Store=27]="Store",o[o.PledgeDonateToEvent=29]="PledgeDonateToEvent",o[o.VolunteerRegistration=80]="VolunteerRegistration",o[o.GroupHomePage=82]="GroupHomePage",o[o.GroupsList=83]="GroupsList",o[o.Pledge_ParticipantAdmin=11]="Pledge_ParticipantAdmin",o[o.TicketingEvent=85]="TicketingEvent",o[o.TicketingDonation=87]="TicketingDonation",o[o.TicketingCart=88]="TicketingCart",o[o.Donations=89]="Donations",o[o.ForgotUsername=90]="ForgotUsername",o[o.ForgotPassword=91]="ForgotPassword",o[o.PasswordReset=92]="PasswordReset",o}(A||{}),S=function(o){return o[o.NotSet=0]="NotSet",o[o.EventHome=3]="EventHome",o[o.ParticipantHome_Pledge=5]="ParticipantHome_Pledge",o[o.TeamHome=7]="TeamHome",o[o.GroupHome=172]="GroupHome",o[o.GroupsList=174]="GroupsList",o[o.Ticketing_YourProfile=202]="Ticketing_YourProfile",o[o.Ticketing_YourPurchases=201]="Ticketing_YourPurchases",o[o.Ticketing_ManageAttendees=203]="Ticketing_ManageAttendees",o[o.Ticketing_Review=70]="Ticketing_Review",o[o.DonationsSuccess=118]="DonationsSuccess",o[o.EventNotAvailable=99]="EventNotAvailable",o[o.ForgotUsername=204]="ForgotUsername",o[o.ForgotPassword=206]="ForgotPassword",o[o.PasswordReset=207]="PasswordReset",o[o.PasswordResetSuccess=208]="PasswordResetSuccess",o}(S||{}),v=function(o){return o[o.Individual=1]="Individual",o[o.TeamCaptain=2]="TeamCaptain",o[o.TeamMember=3]="TeamMember",o[o.SponsorParticipant=4]="SponsorParticipant",o[o.PledgeGeneralDonation=5]="PledgeGeneralDonation",o[o.VolunteerRegistration=6]="VolunteerRegistration",o[o.Store=7]="Store",o[o.TicketingGeneralDonation=8]="TicketingGeneralDonation",o[o.Cart=9]="Cart",o[o.DonationsGeneralDonation=10]="DonationsGeneralDonation",o[o.ForgotUsername=11]="ForgotUsername",o[o.ForgotPassword=12]="ForgotPassword",o[o.PasswordReset=13]="PasswordReset",o[o.StoreLoggedIn=50]="StoreLoggedIn",o}(v||{}),b=function(o){return o[o.Unknown=0]="Unknown",o[o.Declined=1]="Declined",o[o.Accepted=2]="Accepted",o[o.Invoiced=3]="Invoiced",o[o.NotNeeded=4]="NotNeeded",o[o.Submitted=5]="Submitted",o[o.Authorized=6]="Authorized",o[o.RedirectedToHost=7]="RedirectedToHost",o}(b||{}),M=function(o){return o[o.Canada=1]="Canada",o[o.UnitedStates=2]="UnitedStates",o[o.France=74]="France",o}(M||{}),R=function(o){return o.ShowContinueBtn="showContinueBtn",o.ShowAgreeBtn="showAgreeBtn",o.ShowUpdateAndContinueBtn="showUpdateAndContinueBtn",o.ShowProcessPaymentBtn="showProcessPaymentBtn",o.ShowSubmitBtn="showSubmitBtn",o.ShowContinueToReviewBtn="showContinueToReviewBtn",o.ShowSkipThisStep="showSkipThisStep",o}(R||{}),B=function(o){return o.PageNotFound="PageNotFound",o.EventEnded="EventEnded",o.EventNotStarted="EventNotStarted",o.EventNotFound="EventNotFound",o.ParticipantNotFound="err_ParticipantNotExistOrNotActive",o.InvalidsubEventPart="InvalidsubEventPart",o}(B||{}),E=function(o){return o[o.Principal=0]="Principal",o[o.Additional=1]="Additional",o}(E||{}),m=function(o){return o[o.General=1]="General",o[o.InHonour=2]="InHonour",o[o.InMemory=3]="InMemory",o}(m||{}),p=function(o){return o.None="NONE",o.InHonour="IN_HONOUR",o.InMemory="IN_MEMORY",o}(p||{}),O=function(o){return o[o.OneTime=1]="OneTime",o[o.Monthly=2]="Monthly",o[o.Quarterly=3]="Quarterly",o[o.Annually=4]="Annually",o}(O||{}),F=function(o){return o[o.NoCard=0]="NoCard",o[o.PrintedCard=1]="PrintedCard",o[o.ECard=2]="ECard",o}(F||{}),H=function(o){return o[o.InHonourGD=1]="InHonourGD",o[o.InMemoryGD=2]="InMemoryGD",o[o.InHonour=3]="InHonour",o[o.InMemory=4]="InMemory",o[o.tributeCardType=5]="tributeCardType",o}(H||{}),W=function(o){return o[o.UNPROCESSABLE_ENTITY=422]="UNPROCESSABLE_ENTITY",o}(W||{}),j=function(o){return o.Journey="journey",o.Title="title",o.Images="image",o}(j||{}),z=function(o){return o[o.NoRegion=0]="NoRegion",o[o.ParticipantTitle=247]="ParticipantTitle",o[o.ParticipantImages=280]="ParticipantImages",o[o.ParticipantMainImage=19]="ParticipantMainImage",o[o.ParticipantJourney=21]="ParticipantJourney",o[o.TeamTitle=250]="TeamTitle",o[o.TeamImages=281]="TeamImages",o[o.TeamMainImage=23]="TeamMainImage",o[o.TeamJourney=24]="TeamJourney",o[o.LocalSponsors=369]="LocalSponsors",o[o.HeaderRegion=1e4]="HeaderRegion",o[o.FooterRegion=5e4]="FooterRegion",o[o.AboveSystemContentRegion=2e4]="AboveSystemContentRegion",o[o.BelowSystemContentRegion=3e4]="BelowSystemContentRegion",o[o.SideContentRegion=4e4]="SideContentRegion",o}(z||{}),q=function(o){return o[o.Loading=0]="Loading",o[o.Flow=1]="Flow",o[o.System=2]="System",o[o.Cart=3]="Cart",o}(q||{}),at=function(o){return o[o.Facebook=1]="Facebook",o[o.OneAll=2]="OneAll",o[o.Strava=3]="Strava",o}(at||{}),nt=function(o){return o[o.Connected=0]="Connected",o[o.ConnectedAsReturningParticipant=1]="ConnectedAsReturningParticipant",o[o.Disconnected=2]="Disconnected",o[o.InUseError=3]="InUseError",o}(nt||{}),et=function(o){return o[o.General=1]="General",o[o.InHonor=2]="InHonor",o[o.InMemory=3]="InMemory",o}(et||{})},73814:(Z,K,t)=>{"use strict";t.d(K,{T:()=>P});var s=t(96814),e=t(50768),_=t(72550),n=t(65879);t(36169);let P=(()=>{class D{static#t=this.\u0275fac=function(a){return new(a||D)};static#e=this.\u0275mod=n.oAB({type:D});static#i=this.\u0275inj=n.cJS({imports:[e.Bz,_.Dt.forChildren(),s.ez]})}return D})()},47812:(Z,K,t)=>{"use strict";t.d(K,{Y:()=>v});var s=t(6990),e=t(84057),_=t(78356),n=t(72550),i=t(13423),P=t(59773),D=t(81374),I=t(37398),T=t(21631),a=t(21441),y=t(78645),f=t(89723),r=t(46290),u=t(98835),C=t(92841),L=t(52044),g=t(49758),c=t(40374),l=t(65879),d=t(89515),A=t(50768);let S=(()=>{class b{constructor(){}fixHtml(R){return R&&R.replace(/data-toggle/g,"data-bs-toggle").replace(/data-parent/g,"data-bs-parent").replace(/data-target/g,"data-bs-target")}static#t=this.\u0275fac=function(B){return new(B||b)};static#e=this.\u0275prov=l.Yz7({token:b,factory:b.\u0275fac,providedIn:"root"})}return b})(),v=(()=>{class b{constructor(R,B,E,m,p,O,F,H,W,tt,j,z){this.elementRef=R,this.dynamicHTMLRendererService=B,this.placeholderService=E,this.translate=m,this.store=p,this.raisinRouter=O,this.renderer=F,this.router=H,this.widgetService=W,this.notificationService=tt,this.googleAnalyticService=j,this.bootstrapFixerService=z,this.wrapperClass="page-content ",this.isHidden=!1,this.ref=null}ngOnInit(){this.wrapperClass+=` page-content-${this.regionId} region-blocks`,this.destroy$=new y.x,this.raisinRouter.pipe((0,i.Ys)(C.sf),(0,P.R)(this.destroy$),(0,n.FL)()).subscribe(B=>{const E=B?.path?.split("/");this.flowstep=E.join("-")});const R=this.dynamicHTMLRendererService.componentsLoaded$.pipe((0,D.P)(B=>B));(0,s.isNil)(this.html)?this.store.pipe((0,i.Ys)(B=>(0,_.Io)(B,+this.regionId)),(0,n.FL)(),(0,I.U)(B=>B.html),(0,T.z)(B=>R.pipe((0,a.h)(B))),(0,P.R)(this.destroy$)).subscribe(B=>{this.processContent(B)}):R.subscribe(()=>this.processContent(this.html))}onClickTargetBlank(R){R.preventDefault(),window.open(R.currentTarget.getAttribute("targetlink"),"_blank")}processHeaderContent(R){return(R=(R=(R=(R=R.replace(/data-toggle/g,"data-bs-toggle")).replace(/data-target/g,"data-bs-target")).replace(/aria-labelledby="dropdownMenu"/g,"")).replace('id="nav"','id="nav" role="menu"')).replace(/<li class="dropdown clearfix"/g,'<li class="dropdown clearfix" role="menuitem"')}processContent(R){let B=(0,s.replace)((0,s.cloneDeep)(R),new RegExp("(rx|aka):","g"),"$1-");(0,s.forEach)(B.match(/(?=<[^>]+(?=[\s+\"\']btn-donate[\s+\"\']).+)([^>]+>)(Donate Now|Faites un don|\[Donate Now\])<\/a>/gi),m=>{const p=(0,s.cloneDeep)(m).replace('rx-donate-now-button=""',"").replace('href="#"',"").replace("<a","<rx-donate-now-button").replace("</a>","</rx-donate-now-button>").replace('localize=""',"").replace("localize","").replace("class=","css=").replace(/data-toggle/g,"data-bs-toggle").replace(/data-bs-target/g,"data-bs-target");B=B.replace(m,p)}),B=B.replace("[Register now]",this.translate.instant("lnk_RegisterNow")),!(0,s.isNil)(B)&&-1!==B.indexOf("addthis_toolbox")&&(B=this.processSocialShare(B)),this.regionId===f.n_.HeaderRegion&&(B=this.processHeaderContent(B)),(this.regionId===f.n_.AboveSystemContentRegion||this.regionId===f.n_.BelowSystemContentRegion)&&(B=this.placeholderService.replace(B),B=this.bootstrapFixerService.fixHtml(B)),B&&this.elementRef&&(this.destroyRef(),this.ref=this.dynamicHTMLRendererService.renderInnerHTML(this.elementRef,B),this.processLinks(this.elementRef)),(0,s.forEach)(this.elementRef.nativeElement.querySelectorAll('a[target="_blank"]'),m=>{m.setAttribute("targetlink",m.href),m.href="javascript:void(0)",m.addEventListener("click",this.onClickTargetBlank.bind(this))}),(0,s.forEach)(this.elementRef.nativeElement.querySelectorAll("img"),m=>{m.getAttribute("loading")||m.setAttribute("loading","lazy")}),setTimeout(()=>this.runWidgetLoader(),1e3)}runWidgetLoader(){const R=this.router.url;!(/(\/participant\/)(\d+)/.test(R)||/(\/p\/)(([0-9]|[a-z])+([0-9a-z]+))/.test(R)||/(\/team\/)(\d+)/.test(R)||/(\/equipe\/)(\d+)/.test(R)||/(\/t\/)(([0-9]|[a-z])+([0-9a-z]+))/.test(R))&&+this.regionId===f.n_.AboveSystemContentRegion&&this.widgetService.populateWidgets().pipe((0,P.R)(this.destroy$)).subscribe()}processEventDonateClick(R){this.renderer.listen(R,"click",B=>{B.preventDefault()})}processSocialShare(R){return R.replace(/(<!-- AddThis Button BEGIN -->\s*.*<!-- AddThis Button END -->|<div (addthis-toolbox=""|addthis-toolbox) class="addthis_toolbox addthis_default_style (addthis_32x32_style|addthis_32x32_style hidden-xs)">\s*.*<a class="addthis_counter addthis_bubble_style"><\/a> <\/div>)/g,'<rx-social-share use-black-bg-for-twitter="true"></rx-social-share>')}processLinks(R){const B=R.nativeElement.getElementsByTagName("a");if(B){const E=this.getLinkSubEvent(window.location.href);(0,s.map)((0,s.filter)(B,m=>"_blank"!==m.target&&m.host===window.location.host&&(0,s.startsWith)(m.href,m.baseURI)&&E===this.getLinkSubEvent(m.href)),m=>{this.renderer.listen(m,"click",p=>{p.preventDefault();const O=m.href.replace(m.host,"").replace(m.protocol,"").replace("/ui","").replace("//",""),F=this.router.parseUrl(O),H={queryParams:F.queryParams};F.queryParams={},O.startsWith(this.router.url)?this.router.navigateByUrl("/",{skipLocationChange:!0}).then(()=>this.router.navigate([F.toString()],H)):this.router.navigate([F.toString()],H)})}),(0,s.map)((0,s.filter)(B,m=>!(0,s.isNil)(m.attributes["event-donate-click"])),m=>{const p=this.renderer.createElement("button");this.renderer.addClass(p,"btn-link"),this.renderer.setProperty(p,"innerText",m.innerText),this.renderer.setStyle(p,"padding",0),this.renderer.listen(p,"click",O=>(O.preventDefault(),O.stopPropagation(),this.notificationService.notifyListeners(f.Jk.Flow,g.d.DonateToEventClick),!1)),m.replaceWith(p)})}}getLinkSubEvent(R){return(0,s.get)(R.match(/(.+\/ui\/)([^\/]+)/),2)}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete(),this.destroyRef()}ngDoCheck(){this.ref&&this.ref.check()}destroyRef(){this.ref&&(this.ref.destroy(),this.ref=null)}static#t=this.\u0275fac=function(B){return new(B||b)(l.Y36(l.SBq),l.Y36(e.K),l.Y36(r.Q),l.Y36(d.sK),l.Y36(i.yh),l.Y36(i.yh),l.Y36(l.Qsj),l.Y36(A.F0),l.Y36(u.i),l.Y36(L.g),l.Y36(c.Wf),l.Y36(S))};static#e=this.\u0275cmp=l.Xpm({type:b,selectors:[["rx-page-content"]],hostVars:4,hostBindings:function(B,E){2&B&&(l.Ikx("hidden",E.isHidden),l.uIk("flowstep",E.flowstep),l.Tol(E.wrapperClass))},inputs:{regionId:"regionId",regionType:"regionType",html:"html"},decls:1,vars:0,consts:[[1,"region-blocks"]],template:function(B,E){1&B&&l._UZ(0,"section",0)},encapsulation:2})}return b})()},40424:(Z,K,t)=>{"use strict";t.d(K,{d:()=>M});var s=t(89723),e=t(61142),_=t(26028),n=t(6990),P=t(329),D=t(22096),I=t(58504),T=t(36232),a=t(37398),y=t(81374),f=t(92291),r=t(26306),u=t(49758),C=t(20376),L=t(55909),g=t(35297),c=t(52044),l=t(83960),d=t(21875),A=t(40374),S=t(72550),v=t(65879);const b=new e.Be;let M=(()=>{class R{constructor(E,m,p,O,F,H,W,tt,j){this.rdd=E,this.raisinAPI=m,this.storageService=p,this.flowPageValidationService=O,this.cookieService=F,this.notificationService=H,this.errorHandler=W,this.userInteractionRecordingService=tt,this.googleAnalytics=j,this.storageConstituentKey="constituent",this.isStorageDisabled=!1}addNewPurchaseItem(E,m,p){let O;const F=m||this.constituent;if(F&&E){switch(E){case s.Em.AdminFee:O=new l.qo(p);break;case s.Em.GeneralDonation:O=new l.YR(p),O.eventTypeId=this.rdd.subEvent.eventTypeId;break;case s.Em.RegistrationIndividual:O=new l.sw(p);break;case s.Em.RegistrationTeamCaptain:O=new l.zt(p);break;case s.Em.RegistrationTeamMember:O=new l.BR(p);break;case s.Em.RegistrationVolunteer:O=new l.Xn(p);break;case s.Em.StoreCart:O=new l.gk(p);break;case s.Em.TicketingRegistration:O=new l.tv(p);break;case s.Em.TicketingSponsorship:O=new l.U0(p)}O&&this.addPurchaseItem(F,O)}return O}addNewAdminFeeItem(E){return this.addNewPurchaseItem(s.Em.AdminFee,E||this.constituent)}addNewGeneralDonationItem(E){return this.addNewPurchaseItem(s.Em.GeneralDonation,E||this.constituent)}addNewRegistrationIndividualItem(E){return this.addNewPurchaseItem(s.Em.RegistrationIndividual,E||this.constituent)}addNewRegistrationTeamCaptainItem(E){return this.addNewPurchaseItem(s.Em.RegistrationTeamCaptain,E||this.constituent)}addNewRegistrationTeamMemberItem(E){return this.addNewPurchaseItem(s.Em.RegistrationTeamMember,E||this.constituent)}addNewRegistrationVolunteerItem(E){return this.addNewPurchaseItem(s.Em.RegistrationVolunteer,E||this.constituent)}addNewStoreCartItem(E,m){return this.addNewPurchaseItem(s.Em.StoreCart,E||this.constituent,m)}addNewTicketingRegistrationItem(E,m){return this.addNewPurchaseItem(s.Em.TicketingRegistration,E||this.constituent,m)}addNewTicketingSponsorshipItem(E,m){return this.addNewPurchaseItem(s.Em.TicketingSponsorship,E||this.constituent,m)}getStoreTotals(E){const m={sum:0,sumDiscount:0,net:0},p=this.filterPurchaseItemsByItemType(E||this.constituent,s.qG.StoreItem);return p&&p.length>0&&((0,n.forEach)(p,O=>{const F=b.Angular.Utils.parseFloat(O.quantity)||0,H=b.Angular.Utils.parseFloat(O.price)||0,W=O.promoCode&&b.Angular.Utils.parseFloat(O.promoCode.discount)||0,tt=H*F;let j=0;if(tt>0&&W>0){const z=W*F;j=z>tt?tt:z}m.sum+=tt,m.sumDiscount+=j}),m.net+=m.sum-m.sumDiscount),m}clearSurveys(E){return E.surveys=[],E}getDonationTotal(E){let m=0;const p=this.findGeneralDonationPurchaseItem(E||this.constituent);return p&&(m+=b.Angular.Utils.parseFloat(p.donationAmount)||0),m}getRegistrationTotal(E){const m={sum:0,sumDiscount:0,net:0},p=this.findRegistrationPurchaseItem(E||this.constituent);if(p){const O=b.Angular.Utils.parseFloat(p.registrationFee)||0;if(m.sum=O,O>0&&p.promoCode){let F=b.Angular.Utils.parseFloat(p.promoCode.discount)||0;F=F>O?O:F,m.sumDiscount=F}m.net=m.sum-m.sumDiscount}return m}getTicketingTotal(E){const m={sum:0,sumDiscount:0,net:0},p=(0,n.reject)(this.findTicketingPurchaseItem(E||this.constituent),O=>O.type===s.qG.StoreItem);return(0,n.isEmpty)(p)||(0,n.forEach)(p,O=>{const F=b.Angular.Utils.parseFloat(O.price)||0;m.sum+=F;let H=0;O.promoCode&&(H=b.Angular.Utils.parseFloat(O.promoCode.discount)||0,H=H>F?F:H,m.sumDiscount+=H),m.net+=F-H}),m}getItemTotal(E){return this.rdd.subEvent.eventTypeId===s.tw.Ticketing?this.getTicketingTotal(E||this.constituent).net:this.getRegistrationTotal(E||this.constituent).net}getTotalAmount(E){return this.getItemTotal(E||this.constituent)+this.getDonationTotal(E||this.constituent)+this.getStoreTotals(E||this.constituent).net}handleSiteConfig(E){const m=this.getUserId();if(0===m){const p=this.getConstituentFromStorage(),O=(0,n.merge)((0,n.cloneDeep)(_.sB),p);((0,n.isNil)(O?.profile?.address?.countryId)||0===O?.profile?.address?.countryId)&&(O.profile.address.countryId=this.defaultCountryId=E.constituent.profile.address.countryId),this.saveConstituent(O)}else this.getConstituent(m).pipe((0,a.U)(p=>{const O=this.getConstituentFromStorage();this.defaultCountryId=p?.profile?.address?.countryId,this.constituent=(0,n.merge)(this.constituent,_.sB,p,E.constituent,O),this.constituent.profile.address=(0,n.mergeWith)({},this.constituent.profile.address,_.sB.profile&&_.sB.profile.address,p&&p.profile&&p.profile.address,E.constituent&&E.constituent.profile&&E.constituent.profile.address,O&&O.profile&&O.profile.address,(F,H)=>F||H),this.constituent.profile.address.countryId=this.constituent.profile.address.countryId||s.cH.Canada,this.saveConstituent(this.constituent)})).subscribe()}setDonationSettings(E){const m=this.flowPageValidationService.getLocationPath();if((0,n.isNil)(this.flowPageValidationService.isFlowSponsor(m))&&(0,n.isNil)(this.flowPageValidationService.isFlowTicketingDonation(m)))return;const O=this.storageService.getQueryParams(),F=(0,n.isNil)(O)||(0,n.isNil)(O.pid)?null:O.pid,H=this.rdd.getIsAnonymous();this.flowPageValidationService.getFlowPageState().pipe((0,y.P)()).subscribe(W=>{const tt=(0,n.findIndex)(W.steps,{status:L.Z.Started});if(this.constituent=this.getConstituentFromStorage(),E&&E.entityId){!F&&tt<2&&H&&this.clear(this.constituent);const j=this.findGeneralDonationPurchaseItem(this.constituent)||this.addNewGeneralDonationItem(this.constituent);j.type=s.qG.GeneralDonation,j.sponsoredEntityType=E.entityType,j.sponsoredEntityId=E.entityId,j.sponsoredEntityName=E.entityName,this.saveConstituent(this.constituent)}})}getConstituent(E){return(E=E||null)?this.raisinAPI.ConstituentUser.get({userId:E}):this.raisinAPI.Constituent.get()}getConstituentFromStorage(){const E=this.storageService.getData("constituent");return(0,n.isEmpty)(E)&&this.saveConstituent(_.sB),E||this.constituent}update(E){return E?(S.qL.trimStringPropertiesOfObject(E),this.raisinAPI.Constituent.put({},{},E).pipe((0,f.V)(m=>(this.saveConstituent(m),(0,D.of)(m))),(0,r.K)(m=>(this.errorHandler.handleError(m),(0,I._)(m))))):T.E}findRegistrationIndividualPurchaseItem(E){return(0,n.head)(this.filterPurchaseItemsByItemType(E||this.constituent,s.qG.RegistrationFeeIndividual))||null}findRegistrationTeamMemberPurchaseItem(E){return(0,n.head)(this.filterPurchaseItemsByItemType(E||this.constituent,s.qG.RegistrationFeeTeamMember))||null}findRegistrationTeamCaptainPurchaseItem(E){return(0,n.head)(this.filterPurchaseItemsByItemType(E||this.constituent,s.qG.RegistrationFeeCaptain))||null}findGeneralDonationPurchaseItem(E){return(0,n.head)(this.filterPurchaseItemsByItemType(E||this.constituent,s.qG.GeneralDonation))||null}findDonationPurchaseItem(E){return(0,n.head)(this.filterPurchaseItemsByItemTypes(E||this.constituent,[s.qG.GeneralDonation,s.qG.GeneralDonationMonthly,s.qG.GeneralDonationQuarterly,s.qG.GeneralDonationAnnual,s.qG.InHonourDonation,s.qG.InHonourDonationQuarterly,s.qG.InHonourDonationAnnual,s.qG.InHonourDonationMonthly,s.qG.InMemoryDonation,s.qG.InMemoryDonationMonthly,s.qG.InMemoryDonationQuarterly,s.qG.InMemoryDonationAnnual]))||null}findAdminFeePurchaseItem(E){return(0,n.head)(this.filterPurchaseItemsByItemType(E||this.constituent,s.qG.AdminFee))||null}findVolunteerRegistrationPurchaseItem(E){return(0,n.head)(this.filterPurchaseItemsByItemType(E||this.constituent,s.qG.RegistrationVolunteer))}findStorePurchaseItems(E){return this.filterPurchaseItemsByItemType(E||this.constituent,s.qG.StoreItem)}findRegistrationPurchaseItem(E){return(0,n.find)((E||this.constituent).purchaseItems,p=>p.type===s.qG.RegistrationFeeIndividual||p.type===s.qG.RegistrationFeeTeamMember||p.type===s.qG.RegistrationFeeCaptain)}findTicketingPurchaseItem(E){const m=E||this.constituent;return m?(0,n.filter)(m.purchaseItems,p=>p.type===s.qG.TicketingIndividualRegistration||p.type===s.qG.TicketingIndividualSponsorship||p.type===s.qG.TicketingGroupRegistration||p.type===s.qG.TicketingGroupSponsorship||p.type===s.qG.StoreItem):[]}findPurchaseItemsWithTickets(E){return(0,n.filter)((E||this.constituent).purchaseItems,p=>{const O=p;return[s.qG.TicketingGroupRegistration,s.qG.TicketingIndividualRegistration,s.qG.TicketingGroupSponsorship,s.qG.TicketingIndividualSponsorship].includes(p.type)&&!(0,n.isNil)(O.numberOfTickets)&&O.numberOfTickets>0})}findPurchaseItemsByItemId(E,m){return(0,n.filter)((E||this.constituent).purchaseItems,{itemId:m})}filterPurchaseItemsByItemType(E,m){return this.filterPurchaseItemsByItemTypes(E||this.constituent,[m])}filterPurchaseItemsByItemTypes(E,m){return(0,n.filter)((E||this.constituent).purchaseItems,O=>(0,n.includes)(m,O.type))}addNewRegistrationItemToConstituent(E,m){const p=E||this.constituent;return s.qG[m]===s.qG.RegistrationFeeTeamMember?this.addNewRegistrationTeamMemberItem(p):s.qG[m]===s.qG.RegistrationFeeCaptain?this.addNewRegistrationTeamCaptainItem(p):this.addNewRegistrationIndividualItem(p)}addOrUpdateSurvey(E,m){const p=m.surveyId,O=m.pageId;E.surveys=(0,n.get)(E,"surveys",[]);const F=(0,n.findIndex)(E.surveys,H=>H.id===p&&H.pageId===O);F>=0?E.surveys[F]=m:E.surveys.push(m)}maintainSurveys(E){const m=this.getConstituentFromStorage();return E.surveys=m.surveys,E}addPurchaseItem(E,m){return E.purchaseItems=E.purchaseItems||[],m.subEventGroupId=E.subEventGroupId,E.purchaseItems.push(m),m}saveConstituent(E){if(E&&!this.isStorageDisabled){this.ensureCorrespondenceLanguage(E);const m=(0,n.cloneDeep)(E);(0,n.unset)(m,"profile.accountInfo.password"),this.userInteractionRecordingService.logConstituentInfo(m);const p=this.storageService.getLanguages();!(0,n.isNil)(p)&&Array.isArray(p)&&p.forEach(O=>{this.storageService.setData(this.storageConstituentKey,(0,n.omit)(E,"storageService","rdd","paymentDetails.cardExpiration","paymentDetails.cardHolderName","paymentDetails.cardNumber","paymentDetails.cardType","paymentDetails.cvv"),O.url)}),this.storageService.setData(this.storageConstituentKey,(0,n.omit)(E,"storageService","rdd","paymentDetails.cardExpiration","paymentDetails.cardHolderName","paymentDetails.cardNumber","paymentDetails.cardType","paymentDetails.cvv"))}return E}ensureCorrespondenceLanguage(E){E&&(E.profile=E.profile||{},E.profile.correspondanceLanguage=this.rdd.languageId,E.profile.interfaceLanguage=this.rdd.languageId)}maintainUserAccountInfo(E){const m=this.getConstituentFromStorage();return E.profile.accountInfo=m.profile.accountInfo,E}maintainPurchaseItems(E){const m=this.getConstituentFromStorage();return E.purchaseItems=m.purchaseItems,E}maintainTransactionAttribute(E){const m=this.getConstituentFromStorage(),p=(0,n.get)(m,"paymentDetails.transactionAttribute");return(0,n.isNil)(p)||(E.paymentDetails.transactionAttribute=p),E}clearPurchaseItems(E){return E.purchaseItems=[],E}clearAccountInfo(E){return E.profile.accountInfo=null,E}clear(E,m=!1){const p=this.isLoggedIn(E),O=(0,n.cloneDeep)(E);return(0,n.merge)(E,(0,n.cloneDeep)(_.sB)),E.purchaseItems=[],E.failedTransactionUserId=null,E.paymentDetails={},E.surveys=[],E.authorizedRole=null,E.returningUserId=null,E.importSubEventId=null,delete E.userWantsTaxReceipt,delete E.waiverAccepted,(!p||m)&&(E.profile={},E.profile.contactType=0,E.profile.address={},E.profile.address.countryId=O.profile.address&&O.profile.address.countryId||s.cH.Canada,E.profile.accountInfo=null,this.setSubEventGroupId(E,null)),E}addCustomFieldDataToConstituent(E){const m=this.storageService.getQueryParams();if(!(0,n.isNil)(m)){const p={};(0,n.set)(p,"customField1",m.cf1),(0,n.set)(p,"customField2",m.cf2),(0,n.set)(p,"customField3",m.cf3),(0,n.set)(p,"customField4",m.cf4),(0,n.set)(p,"customField5",m.cf5),(0,n.assignIn)(E.profile,p)}return E}getSubEventGroupId(E){if(!(0,n.isNil)(E.subEventGroupId))return E.subEventGroupId;const m=(0,n.find)(E.purchaseItems,p=>p&&p.hasOwnProperty("subEventGroupId")&&!(0,n.isNil)(p.subEventGroupId));return(0,n.get)(m,"subEventGroupId",null)}setSubEventGroupId(E,m){E.subEventGroupId=m,E.purchaseItems=(0,n.map)(E.purchaseItems,p=>((p.type===s.qG.RegistrationFeeIndividual||p.type===s.qG.RegistrationFeeTeamMember||p.type===s.qG.RegistrationFeeCaptain||p.type===s.qG.RegistrationVolunteer||p.type===s.qG.GeneralDonation)&&(p.subEventGroupId=m),p))}setAuthRole(E,m){return(0,n.isNil)(m)||(E.authorizedRole=m),E}getAuthRole(E){return E.authorizedRole||(E.authorizedRole=_.pR.guest),E.authorizedRole}isLoggedIn(E){return b.Angular.Utils.parseFloat((0,n.get)(E,"profile.userId",0))>0}disablePersistence(){this.isStorageDisabled=!0}enablePersistence(){this.isStorageDisabled=!1}doesConstituentExist(E){return this.doesConstituentExistByNameEmail(E.profile.firstName,E.profile.lastName,E.profile.email)}doesConstituentExistByNameEmail(E,m,p){return this.raisinAPI.UserExist.post(null,{firstName:E,lastName:m,email:p},null)}mergeConstituentFromStorage(E){E=E||{};const m=this.getConstituentFromStorage();return(0,n.merge)(E,m)}addToConstituentPurchaseItems(E,m,p){let O=null;switch(p){case s.Bp.Registration:O=this.addNewTicketingRegistrationItem(E,m);break;case s.Bp.Sponsorship:O=this.addNewTicketingSponsorshipItem(E,m);break;case s.Bp.Store:O=this.addNewStoreCartItem(E,m)}O.sessionId=this.storageService.getData("store"),O.itemId=m.itemId,O.type=m.itemTypeId||m.type,O.quantity=1,O.promoCode=m.promoCode,O.price=m.price,O.name=m.name,O.numberOfTickets=m.numberOfTickets,O.quantityMaxAllowed=m.quantityMaxAllowed,O.quantityMinAllowed=m.quantityMinAllowed,O.quantityReservedByMe=m.quantityReservedByMe,O.quantityReservedByOthers=m.quantityReservedByOthers,O.itemTypeGroupTypeId=p,O.quantityOffered=m.quantityOffered}addPurchaseItems(E,m,p){(0,n.forEach)(m,O=>{for(let F=0;F<O.quantity;F++)this.addToConstituentPurchaseItems(E,O,p)}),this.saveConstituent(E),this.notificationService.notifyListeners(s.Jk.Cart,u.d.OpenShoppingCart)}groupItemsByItemId(E){const m=[];return(0,n.forEach)(E,p=>{if((0,n.isNil)((0,n.find)(m,{itemId:p.itemId}))){const O=1===p.type;m.push({...p,quantity:0,price:O?p.donationAmount:p.price,isCartView:!0})}(0,n.find)(m,{itemId:p.itemId}).quantity+=p.quantity}),m}getTicketingItems(E){return this.findTicketingPurchaseItem(E)}clearConstituentFromStorage(E=!0){let m=this.storageService.getData("constituent"),p=(0,n.cloneDeep)(m.purchaseItems);return E&&p.length>0&&(this.googleAnalytics.removeItemsFromCart(p,this.storageService.getSubEventId()),this.clearPurchaseItems(m)),this.rdd.getIsAnonymous()?(m=(0,n.cloneDeep)(_.sB),m.profile.address.countryId=this.defaultCountryId,m.purchaseItems=E?m.purchaseItems:p,this.saveConstituent(m),m):((0,n.isNil)(m)||this.saveConstituent(m),m)}getUserId(E){const m=+this.cookieService.getCookie(`${_.z1.CookieKeys.participantId}_${this.rdd.subEventId}`)||0;if(m>0)return m;const p=E||this.getConstituentFromStorage(),O=(0,n.get)(p,"profile.userId",0);return b.Angular.Utils.parseFloat(O)}setUserId(E,m){E.profile=E.profile||{},E.profile.userId=m||0}static#t=this.\u0275fac=function(m){return new(m||R)(v.LFG(P.n),v.LFG(g.O),v.LFG(d.V1),v.LFG(C.p),v.LFG(d.x9),v.LFG(c.g),v.LFG(v.qLn),v.LFG(A.NJ),v.LFG(A.Wf))};static#e=this.\u0275prov=v.Yz7({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})()},83960:(Z,K,t)=>{"use strict";t.d(K,{BR:()=>I,Bm:()=>C,U0:()=>r,Xn:()=>a,YR:()=>P,gk:()=>y,i4:()=>u,qo:()=>i,sw:()=>D,tv:()=>f,zt:()=>T});var s=t(6990),_=t(89723);class n{constructor(g){this.promoCode=null,this.itemId=null,this.typeLabel="",this.category="",this.category2="",this.category3="",this.registrationFee=0,this.minFundRaisingGoal=0,this.suggestedFundRaisingGoal=0,this.name="",(0,s.assign)(this,g)}}class i extends n{constructor(g){super(g),this.itemId=0,this.type=_.qG.AdminFee,this.$type=_.Em.AdminFee,this.typeLabel="AdminFee",this.category="Admin Fee",(0,s.assign)(this,g)}}class P extends n{constructor(g){super(g),this.itemId=0,this.type=_.qG.GeneralDonation,this.$type=_.Em.GeneralDonation,this.quantity=0,this.donationAmount=0,this.typeLabel="Donation",this.category="Donation",this.isSelfDonation=!1,(0,s.assign)(this,g)}}class D extends n{constructor(g){super(g),this.type=_.qG.RegistrationFeeIndividual,this.$type=_.Em.RegistrationIndividual,this.typeLabel="Ind",this.category="Registration",this.category2="Individual Registration",(0,s.assign)(this,g)}}class I extends D{constructor(g){super(g),this.type=_.qG.RegistrationFeeTeamMember,this.$type=_.Em.RegistrationTeamMember,this.teamInfo=null,this.typeLabel="TM",this.category="Registration",this.category2="Team Member Registration",(0,s.assign)(this,g)}}class T extends I{constructor(g){super(g),this.type=_.qG.RegistrationFeeCaptain,this.$type=_.Em.RegistrationTeamCaptain,this.typeLabel="TC",this.category="Registration",this.category2="Team Captain Registration",(0,s.assign)(this,g)}}class a extends n{constructor(g){super(g),this.itemId=0,this.type=_.qG.RegistrationVolunteer,this.$type=_.Em.RegistrationVolunteer,this.typeLabel="Volunteer",this.category="Volunteer",(0,s.assign)(this,g)}}class y extends n{constructor(g){super(g),this.type=_.qG.StoreItem,this.$type=_.Em.StoreCart,this.itemId=null,this.price=null,this.typeLabel="Store",this.category="Store",(0,s.assign)(this,g),this.altText=(0,s.isEmpty)(this.imageUrl)?"":(0,s.isEmpty)(this.description)?this.name:this.description}}class f extends n{constructor(g){super(g),this.type=_.qG.TicketingIndividualRegistration,this.$type=_.Em.TicketingRegistration,this.category="Ticket Purchase",this.category2="Individual Ticket Item",this.typeLabel="Ticket",(0,s.assign)(this,g)}}class r extends f{constructor(g){super(g),this.type=_.qG.TicketingIndividualSponsorship,this.$type=_.Em.TicketingSponsorship,this.category="Sponsorship Items",this.category2="Individual Ticket Item",this.typeLabel="Sponsorship",(0,s.assign)(this,g)}}class u extends n{constructor(g){super(g),this.type=_.qG.TicketingGroupRegistration,this.$type=_.Em.TicketingRegistration,this.category="Ticket Purchase",this.category2="Group Ticket Item",this.typeLabel="Ticket",(0,s.assign)(this,g)}}class C extends f{constructor(g){super(g),this.type=_.qG.TicketingGroupSponsorship,this.$type=_.Em.TicketingSponsorship,this.category="Sponsorship Items",this.category2="Group Ticket Item",this.typeLabel="Sponsorship",(0,s.assign)(this,g)}}},84057:(Z,K,t)=>{"use strict";t.d(K,{K:()=>I});var s=t(6990),_=t(65619),n=t(96814),i=t(65879),P=t(97969);let I=(()=>{class T{constructor(y,f,r,u,C){this.options=y,this.cfr=f,this.document=r,this.rendererFactory=u,this.injector=C,this.componentsLoaded$=new _.X(!1),this.componentFactories=new Map,this.componentRefs=new Map,this.renderingComponents=[],this.addComponents(this.options.components,!1),this.renderer=u.createRenderer(null,null)}addComponents(y,f=!0){const r=this.renderingComponents.length>0?(0,s.differenceBy)(y,this.renderingComponents,"selector"):y;r?.length>0&&(this.renderingComponents=[...this.renderingComponents,...r],(0,s.map)(r,({selector:u,component:C})=>{let L;L=this.cfr.resolveComponentFactory(C),this.componentFactories.set(u,L)})),f&&this.componentsLoaded$.next(!0)}nameChange(y){return y.replace(/-([a-z])/g,function(f){return f[1].toUpperCase()})}renderInnerHTML(y,f){if(!function D(){return null!=window&&null!=window.document}())return{check:()=>{},destroy:()=>{}};y.nativeElement.innerHTML=f,(0,s.map)(y.nativeElement.querySelectorAll("script"),u=>{let C=this.renderer.createElement("script");u.innerText&&(C.innerText=u.innerText),u.src&&(C.src=u.src),this.renderer.appendChild(this.document.body,C)});const r=[];return(0,s.map)(this.renderingComponents,({selector:u})=>{const C=y.nativeElement.querySelectorAll(u);(0,s.map)(C,L=>{const g=this.componentFactories.get(u).create(this.injector,[],L);L.hasAttributes()&&(0,s.map)(L.attributes,c=>{const l=c.name.match(/\[(.*?)\]/g);g.instance[this.nameChange((0,s.isNil)(l)?c.name:l[0])]=c.value}),g.changeDetectorRef.detectChanges(),L.removeAttribute("ng-version"),r.push(g)})}),this.componentRefs.set(y,r),{check:()=>r.forEach(u=>u.changeDetectorRef.detectChanges()),destroy:()=>{r.forEach(u=>u.destroy()),this.componentRefs.delete(y)}}}static#t=this.\u0275fac=function(f){return new(f||T)(i.LFG(P.W),i.LFG(i._Vd),i.LFG(n.K0),i.LFG(i.FYo),i.LFG(i.zs3))};static#e=this.\u0275prov=i.Yz7({token:T,factory:T.\u0275fac,providedIn:"root"})}return T})()},99163:(Z,K,t)=>{"use strict";t.d(K,{Du:()=>_,Kp:()=>n.K});var s=t(97969),e=t(65879);let _=(()=>{class i{static forRoot(D){return{ngModule:i,providers:[{provide:s.W,useValue:D}]}}static#t=this.\u0275fac=function(I){return new(I||i)};static#e=this.\u0275mod=e.oAB({type:i});static#i=this.\u0275inj=e.cJS({})}return i})();var n=t(84057)},97969:(Z,K,t)=>{"use strict";t.d(K,{W:()=>e});var s=t(65879);let e=(()=>{class _{static#t=this.\u0275fac=function(P){return new(P||_)};static#e=this.\u0275prov=s.Yz7({token:_,factory:_.\u0275fac,providedIn:"root"})}return _})()},49758:(Z,K,t)=>{"use strict";t.d(K,{d:()=>s});var s=function(e){return e.ComponentRegister="component.register",e.ComponentHasData="component.hasData",e.ComponentClearRegistry="component.clearRegistry",e.DisabledProceedButton="setDisabled.proceedButton",e.ShowFlowButtons="show.flowbuttons",e.AreFlowButtonsVisible="areFlowButtonsVisible",e.ShowContinueBtn="showContinueBtn",e.ProcessPayment="processpayment",e.Submit="submit",e.Continue="continue",e.UpdateRegistrationSteps="updateRegistrationSteps",e.PaymentRequired="payment.required",e.CartItemsReserved="cart-items-reserved",e.CartItemsUpdated="cart-items-updated",e.CartInventoryUpdated="cart-inventory-updated",e.CartInventoryUpdatedReview="cart-inventory-updated-review",e.CartInventoryUpdatedAttendees="cart-inventory-updated-attendees",e.OpenShoppingCart="open-shopping-cart",e.EmptyCartItems="empty-cart-items",e.DonateToEventClick="donateToEventClick",e.SwitchFlow="switch-flow",e}(s||{})},51266:(Z,K,t)=>{"use strict";t.d(K,{U:()=>s});var s=function(e){return e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward",e}(s||{})},55909:(Z,K,t)=>{"use strict";t.d(K,{Z:()=>s});var s=function(e){return e[e.NotStarted=0]="NotStarted",e[e.Started=1]="Started",e[e.Review=2]="Review",e[e.Success=3]="Success",e[e.Failed=4]="Failed",e[e.Completed=5]="Completed",e[e.Skip=6]="Skip",e}(s||{})},72905:(Z,K,t)=>{"use strict";t.d(K,{q:()=>s});var s=function(e){return e[e.NotLoaded=0]="NotLoaded",e[e.NotExistInLoadedFlow=1]="NotExistInLoadedFlow",e[e.NotNextStep=2]="NotNextStep",e[e.ValidToProceed=3]="ValidToProceed",e[e.IsFirstPage=4]="IsFirstPage",e[e.ReviewPage=5]="ReviewPage",e[e.SuccessPage=6]="SuccessPage",e[e.FailedPage=7]="FailedPage",e[e.IsJoinTeamFirstPage=8]="IsJoinTeamFirstPage",e}(s||{})},65381:(Z,K,t)=>{"use strict";t.d(K,{J:()=>i});var s=t(89723),e=t(6990);class _{constructor(){this.buttons=new Map,this.keys=Object.values(s.mQ),this.hideAll()}hideAll(){(0,e.forEach)(this.keys,D=>{this.buttons.set(D,!1)})}setVisibleOn(D){this.buttons.set(D,!0)}setVisibleOff(D){this.buttons.set(D,!1)}getVisibility(D){return this.buttons.get(D)||!1}isAnyVisible(){return(0,e.reduce)(this.keys,(D,I)=>D||this.getVisibility(I),!1)}showContinueBtn(){this.setVisibleOn(s.mQ.ShowContinueBtn)}showContinueToReviewBtn(){this.setVisibleOn(s.mQ.ShowContinueToReviewBtn)}showUpdateAndContinue(){this.setVisibleOn(s.mQ.ShowUpdateAndContinueBtn)}showProcessPayment(){this.setVisibleOn(s.mQ.ShowProcessPaymentBtn)}showSubmitBtn(){this.setVisibleOn(s.mQ.ShowSubmitBtn)}}var n=t(65879);let i=(()=>{class P{constructor(){this.areFlowButtonsVisible=!1,this.isProceedButtonDisabled=!1,this.isFirstStepInFlow=!1,this.fbvm=new _}setContinueButtonVisible(I,T=s.mQ.ShowContinueBtn){I?this.fbvm.setVisibleOn(T):this.fbvm.setVisibleOff(T)}setAreFlowButtonsVisible(I){this.areFlowButtonsVisible=I}setIsProceedButtonDisabled(I){this.isProceedButtonDisabled=I}setIsFirstStepInFlow(I){this.isFirstStepInFlow=I,I&&this.fbvm.hideAll()}getIsContinueButtonVisible(){return this.fbvm.isAnyVisible()}getAreFlowButtonsDisabled(){return!this.areFlowButtonsVisible}getAreFlowButtonsVisible(){return this.areFlowButtonsVisible}getIsProceedButtonDisabled(){return this.getAreFlowButtonsDisabled()||this.isProceedButtonDisabled}getIsFirstStepInFlow(){return this.isFirstStepInFlow}areAnyProceedButtonsVisible(){return this.fbvm.isAnyVisible()}getIsBackButtonVisible(){return this.getAreFlowButtonsVisible()&&!this.getIsFirstStepInFlow()}getButtonVisibility(I){return this.fbvm.getVisibility(I)}hideAllFlowButtons(){this.fbvm.hideAll()}setFlowButtonVisible(I){switch(this.fbvm.hideAll(),I.type){case"processpayment":this.fbvm.showProcessPayment();break;case"submit":this.fbvm.showSubmitBtn();break;case"continue":this.fbvm.setVisibleOn(I.key);break;default:this.fbvm.setVisibleOn(s.mQ.ShowContinueBtn)}}static#t=this.\u0275fac=function(T){return new(T||P)};static#e=this.\u0275prov=n.Yz7({token:P,factory:P.\u0275fac,providedIn:"root"})}return P})()},90569:(Z,K,t)=>{"use strict";t.d(K,{n:()=>u});var s=t(22096),e=t(9315),_=t(37398),n=t(26306),i=t(32185),P=t(6990),I=t(89723),T=t(55909),a=t(35297),y=t(21875),f=t(65879),r=t(96814);let u=(()=>{class C{constructor(g,c,l){this.raisinAPI=g,this.storageService=c,this.location=l}searchFlowForRouteUrl(g,c,l){if(!(0,P.isNil)(l)&&60!==l){const A=(0,P.find)(g,{moduleId:l});return(0,P.isNil)(A)||(A.steps=this.filterAndSortSteps(A.steps)),A}const d=(0,P.find)(g,A=>!(0,P.isNil)((0,P.find)(A.steps,S=>(0,P.includes)((0,P.toLower)(S.routingPath),(0,P.toLower)(c)))));return(0,P.isNil)(d)?null:(d.steps=this.filterAndSortSteps(d.steps),d)}getFlowsByRouteUrl(g,c,l){if((0,P.isEmpty)(g)||(0,P.isNil)(g))return(0,s.of)(null);const d=this.storageService.getData("currentFlow");if(!(0,P.isNil)(d)&&!(0,P.isNil)(d[0])&&!l){const A=this.searchFlowForRouteUrl(d,g,c);return(0,P.isNil)(A)||(A.steps=this.filterAndSortSteps(A.steps)),(0,s.of)(A)}return(0,e.D)([this.raisinAPI.FlowsByUrl.get({id:0},{url:g}),this.getSubEventConfigSettings()]).pipe((0,_.U)(A=>{this.settings=A[1],this.storageService.setData("currentFlow",A[0]);const S=this.searchFlowForRouteUrl(A[0],g,c);return(0,P.isNil)(S)||(S.steps=this.filterAndSortSteps(S.steps)),S}),(0,n.K)(()=>(0,s.of)(null)))}getCurrentFlowSteps(g){const c=this.getLocationPath();return this.getFlowSteps(null).pipe((0,_.U)(l=>(0,P.isEmpty)(l)?this.getFlowsByRouteUrl(c).pipe((0,_.U)(d=>d&&d.steps?this.filterAndSortSteps(d.steps):null)):this.filterAndSortSteps(l)),(0,n.K)(()=>[]))}getFlows(){const g=this.storageService.getData("flowConfig");return g?(0,s.of)(g):this.raisinAPI.SiteConfig.get({entityId:null},{Url:null},null).pipe((0,i.j)("flows"),(0,_.U)(c=>c||[]),(0,n.K)(()=>[]))}getSubEventConfigSettings(){return(0,P.isNil)(this.storageService.getData("subEventConfigSettings"))?this.raisinAPI.SubEventSettings.get().pipe((0,_.U)(g=>(this.storageService.setData("subEventConfigSettings",g),g)),(0,n.K)(()=>(0,s.of)([]))):(0,s.of)(this.storageService.getData("subEventConfigSettings"))}filterAndSortViews(g){let c=(0,P.clone)(g);if(null!=this.settings){if(!this.settings.hasWaiver){const l=`<${I.kD.Waiver}></${I.kD.Waiver}>`;c=(0,P.reject)(c,d=>(0,P.isEqual)((0,P.lowerCase)(d.templateView),(0,P.lowerCase)(l)))}if(!this.settings.hasReturningParticipant){const l=`<${I.kD.ReturningParticipant}></${I.kD.ReturningParticipant}>`;c=(0,P.reject)(c,d=>(0,P.isEqual)((0,P.lowerCase)(d.templateView),(0,P.lowerCase)(l)))}}return(0,P.sortBy)(c,["sortOrder"])}filterAndSortSteps(g){g=(0,P.map)(g,l=>(l.views=this.filterAndSortViews(l.views),l));const c=(0,P.reject)(g,l=>(0,P.isEmpty)(l.views));return(0,P.sortBy)(c,["sortOrder"])}getFlowSteps(g){const c=this.getLocationPath();return this.getFlowsByRouteUrl(c,g).pipe((0,_.U)(l=>l&&!(0,P.isEmpty)(l.steps)?this.filterAndSortSteps(l.steps):[]),(0,n.K)(()=>[]))}getCurrentFlow(){const g=this.storageService.getData("currentFlow")||{};return(0,s.of)(g)}getLocationPath(){return this.location.path().split("?")[0].split("/").splice(2).join("/")}getViewForCurrentStep(){return this.getFlowPageState().pipe((0,_.U)(g=>(0,P.find)(g.steps,c=>c.status===T.Z.Started)),(0,_.U)(g=>(0,P.isNil)(g)?[]:this.filterAndSortViews(g.views)),(0,_.U)(g=>(0,P.reduce)(g,(c,l)=>`${c}${l.templateView}`,"")))}getFlowPageState(){return(0,s.of)(this.storageService.getData("flowPageState")||{})}getActiveFlowPageState(){return this.getFlowPageState().pipe((0,_.U)(g=>{const c=(0,P.cloneDeep)(g);return c.steps=(0,P.filter)(g.steps,l=>l.status!==T.Z.Skip),c}))}getStepNameFromRoute(g){const c=g.routingPath;return-1===c.lastIndexOf("/")?"":c.substring(c.lastIndexOf("/")+1)}findStepContainingView(g){return this.getFlowPageState().pipe((0,_.U)(c=>c.steps),(0,_.U)(c=>{const l=`<rx-${g}>`;return(0,P.find)(c,d=>{const A=(0,P.find)(d.views,S=>(0,P.includes)(S.templateView.replace(":","-"),l));return!(0,P.isNil)(A)})}),(0,n.K)(()=>(0,s.of)(null)))}getFlowsByModuleId(g){return this.getFlows().pipe((0,_.U)(c=>{const l=(0,P.find)(c,d=>d.moduleId===g);return(0,P.isNil)(l)?null:l}))}static#t=this.\u0275fac=function(c){return new(c||C)(f.LFG(a.O),f.LFG(y.V1),f.LFG(r.Ye))};static#e=this.\u0275prov=f.Yz7({token:C,factory:C.\u0275fac,providedIn:"root"})}return C})()},36446:(Z,K,t)=>{"use strict";t.d(K,{P:()=>E});var s=t(8891),e=t(49758),_=t(89723),n=t(6990),P=t(61142),D=t(65619),I=t(58504),T=t(22096),a=t(32181),y=t(21631),f=t(99397),r=t(94664),u=t(21441),C=t(26306),L=t(37398),g=t(48180),c=t(55909),l=t(90569),d=t(96814),A=t(51266),S=t(52044),v=t(21875),b=t(65879),M=t(49766),R=t(50768);const B=new P.Be;let E=(()=>{class m{constructor(O,F,H,W,tt,j,z,q){this.document=O,this.validationService=F,this.notificationService=H,this.browserDetectionService=W,this.flowPageManagementService=tt,this.router=j,this.activatedRoute=z,this.storageService=q,this.injectedStepFunction=null,this.triggerForward=new D.X(!1),this.triggerBackward=new D.X(!1),this.forwardSubscription=null,this.backwardSubscription=null,this.isRedirectedToExternalUrl=!1,this.register()}nextStep(){this.triggerForward.next(!0)}previousStep(){this.triggerBackward.next(!0)}register(){const O=[c.Z.Started,c.Z.Review,c.Z.Failed];null===this.forwardSubscription&&(this.forwardSubscription=this.triggerForward.asObservable().pipe((0,a.h)(F=>F)).subscribe(()=>this.go(O,A.U.Forward))),null===this.backwardSubscription&&(this.backwardSubscription=this.triggerBackward.asObservable().pipe((0,a.h)(F=>F)).subscribe(()=>this.go(O,A.U.Backward)))}unregister(){null!==this.forwardSubscription&&this.forwardSubscription.unsubscribe(),null!==this.backwardSubscription&&this.backwardSubscription.unsubscribe()}validationCheck(O){return this.flowPageManagementService.getActiveFlowPageState().pipe((0,y.z)(F=>{const H=[];return O===A.U.Forward&&(0,n.includes)([c.Z.Started,c.Z.Review,c.Z.Failed],F.status)?this.validationService.preValidate().pipe((0,f.b)(W=>H.push(W)),(0,f.b)(W=>console.debug("validationService preValidate",W)),(0,r.w)(W=>W?this.validationService.validate().pipe((0,f.b)(tt=>H.push(tt)),(0,f.b)(tt=>console.debug("validationService validate",tt))):[W]),(0,r.w)(W=>((0,n.merge)(H,W),W?this.validationService.postValidate().pipe((0,f.b)(tt=>H.push(tt)),(0,f.b)(tt=>console.debug("validationService postValidate",tt))):(H.push(W),H))),(0,u.h)(H),(0,C.K)(W=>(console.debug("validationCheck catchError",W),(0,I._)(W)))):(0,T.of)([!0])}),(0,C.K)(F=>(console.debug("validationCheck catchError",F),(0,I._)(F))))}go(O,F){this.notificationService.notifyListeners(_.Jk.Flow,e.d.AreFlowButtonsVisible,{areFlowButtonsVisible:!1},`navigator step => ${F===A.U.Forward?"forward":"backward"} step`),this.validationCheck(F).pipe((0,a.h)(W=>{const tt=(0,n.reduce)(W,(j,z)=>j&&z,!0);return tt||this.failedValidation(F),tt}),(0,L.U)(W=>this.traverseFlow(O,F)),(0,C.K)(W=>(console.debug("validationCheck error",W),this.failedValidation(F),this.traverseFlow(O,F),(0,I._)(W)))).subscribe()}failedValidation(O){const F=O===A.U.Forward?"next":"previous";setTimeout(()=>{const H=$(".system-content").find("mat-error").filter(":first");this.browserDetectionService.isIPhone()?H.get(0).scrollIntoViewIfNeeded():B.Angular.Utils.scrollAndFocusOnElement(H)},1),this.notificationService.notifyListeners(_.Jk.Flow,e.d.AreFlowButtonsVisible,{areFlowButtonsVisible:!0},`failedValidation step => ${F} step error`)}traverseFlow(O,F,H){this.flowPageManagementService.getFlowPageState().pipe((0,f.b)(W=>console.debug("traverseFlow",W.status,W)),(0,L.U)(W=>((0,n.includes)(O,W.status)||(0,I._)(`flow status ${W.status} was not found in the status filters ${O}`),F===A.U.Backward?this.getPreviousStepByCurrentRouteUrl(W):this.getNextStepByCurrentRouteUrl(W))),(0,y.z)(W=>this.routeTransition(W)),(0,C.K)(W=>(console.error(W),(0,T.of)(null)))).subscribe()}goToStep(O,F){this.flowPageManagementService.getFlowPageState().pipe((0,L.U)(H=>(0,n.find)(H.steps,{name:O})),(0,y.z)(H=>this.routeTransition(H)),(0,C.K)(H=>(console.error(H),(0,I._)(H)))).subscribe()}goToFirstStepOfFlow(O){this.flowPageManagementService.getFlowSteps(O).pipe((0,g.q)(1),(0,L.U)(F=>(0,n.first)(F))).subscribe(F=>{this.goToStep(F.name)})}routeTransition(O,F=!1){return this.isRedirectedToExternalUrl?(this.isRedirectedToExternalUrl=!1,(0,T.of)(null)):(this.validationService.stateChangeSuccessHandler(),(0,T.of)(this.router.navigate([`/${O.flowRoute}`],{relativeTo:this.activatedRoute,queryParamsHandling:F?"":"preserve"})))}getNextStepByCurrentRouteUrl(O,F){((0,n.isEmpty)(F)||(0,n.isNil)(F))&&(F=this.flowPageManagementService.getLocationPath());const H=(0,n.reject)(O.steps,{status:c.Z.Skip}),W=(0,n.findIndex)(H,{route:F});if(O.status===c.Z.Review&&!this.hasStartedSteps(H,W+1,(0,n.findIndex)(H,{name:"review"})-1))return(0,n.find)(H,{name:"review"});if(O.status===c.Z.Success)return(0,n.find)(H,{name:"successful"});if(O.status===c.Z.Failed)return(0,n.find)(H,{name:"failed"});const tt=(0,n.find)(O.steps,{route:F});if(-1===W&&"payment"===tt?.name&&tt?.status===c.Z.Skip){const j=(0,n.findIndex)(O.steps,{route:F});return O.steps[j+1]}return W<(0,n.size)(H)?H[W+1]:H[W]}getPreviousStepByCurrentRouteUrl(O,F){if(((0,n.isEmpty)(F)||(0,n.isNil)(F))&&(F=this.flowPageManagementService.getLocationPath()),O.status===c.Z.Success)return null;if(O.status===c.Z.Failed)return(0,n.find)(O.steps,O.moduleId===_.PO.VolunteerRegistration?{name:"registration"}:{name:"review"});const H=(0,n.findIndex)(O.steps,{route:F});return H<(0,n.size)(O.steps)&&H>0?O.steps[H-1].status===c.Z.Skip?O.steps[H-2]:O.steps[H-1]:O.steps[H]}redirectToExternalUrl(O){console.debug(`Redirect to ${O}`),this.isRedirectedToExternalUrl=!0,this.document.location.href=O}navigateTo(O,F=null){const H=(0,n.omit)(F,["token","intrpt","filter","#","logout"]);this.router.navigate([`${this.storageService.eventParams.subEventCustomPart}/${O}`],{relativeTo:this.activatedRoute,queryParams:H})}hasStartedSteps(O,F,H){let W=!1;if((0,n.isEmpty)(O))return W;const tt=Math.max(F,0),j=Math.min(H,O.length-1);if(tt>j)return W;for(let z=tt;z<=j;z++)if(O[z].status===c.Z.Started){W=!0;break}return W}static#t=this.\u0275fac=function(F){return new(F||m)(b.LFG(d.K0),b.LFG(s.R),b.LFG(S.g),b.LFG(M.p),b.LFG(l.n),b.LFG(R.F0),b.LFG(R.gz),b.LFG(v.V1))};static#e=this.\u0275prov=b.Yz7({token:m,factory:m.\u0275fac,providedIn:"root"})}return m})()},59945:(Z,K,t)=>{"use strict";t.d(K,{r:()=>H});var s=t(6990),e=t(36232),_=t(22096),n=t(58504),i=t(52572),P=t(9315),D=t(55909),I=t(90569),T=t(20376),a=t(72905),y=t(94664),f=t(99397),r=t(37398),u=t(26306),C=t(32181),L=t(21631),g=t(329),c=t(89723),l=t(21875),d=t(9058),A=t(40424),S=t(83960),v=t(50101),b=t(87656),M=t(65879);let R=(()=>{class W{constructor(j,z,q,at,nt,et,o){this.storageService=j,this.teamService=z,this.constituentService=q,this.joinTeamService=at,this.rdd=nt,this.registrationStartService=et,this.flowpageManagementService=o}createTeamMemberRegItem(j,z){return new S.BR({itemId:z.itemId,registrationFee:z.price,name:z.name,minFundRaisingGoal:z.minFundraisingGoal||(0,s.get)(this.rdd.subEvent,"minParticipantFundraisingGoal",0),suggestedFundRaisingGoal:z.suggestedFundraisingGoal||(0,s.get)(this.rdd.subEvent,"suggestedParticipantFundraisingGoal",0),teamInfo:j,subEventGroupId:j.subEventGroupId})}setupJoinTeamFlow(j,z){return this.rdd.moduleId=c.PO.JoinTeamRegistration,(0,i.a)([this.teamService.getTeam(+z.tid),this.registrationStartService.loadDataForJoinTeamRegistration(z),this.joinTeamService.UserCanJoinTeam(+z.tid,null,null,null)]).pipe((0,r.U)(([q,at,nt])=>{const et=(0,s.get)(at,"items.length",0);if(0===et)return null;const o=this.createTeamMemberRegItem(q,at.items[0]),mt=this.constituentService.getConstituentFromStorage();this.constituentService.setSubEventGroupId(mt,q.subEventGroupId),this.constituentService.addPurchaseItem(mt,o),this.constituentService.saveConstituent(mt),1===et&&(j.steps[0].status=D.Z.Completed);const ft=(0,s.findIndex)(j.steps,G=>(0,s.startsWith)(G.name,"search"));return nt&&(j.steps[ft].status=D.Z.Skip),j}),(0,u.K)(q=>(console.debug("setupJoinTeamFlow error",q),(0,n._)(q))))}getFlowPageState(){const j=this.storageService.getData("flowPageState")||{};return(0,_.of)(j)}static#t=this.\u0275fac=function(z){return new(z||W)(M.LFG(l.V1),M.LFG(d.U),M.LFG(A.d),M.LFG(b.R),M.LFG(g.n),M.LFG(v.u),M.LFG(I.n))};static#e=this.\u0275prov=M.Yz7({token:W,factory:W.\u0275fac,providedIn:"root"})}return W})();var B=t(65381),E=t(55509),m=t(89365),p=t(80001),O=t(80307),F=t(40374);let H=(()=>{class W{constructor(j,z,q,at,nt,et,o,mt,ft,G,vt){this.storageService=j,this.returningUserService=z,this.flowpageManagementService=q,this.flowPageTrackerSetupService=at,this.constituentService=nt,this.attendeeService=et,this.flowPageValidationService=o,this.flowButtonService=mt,this.jwtAuthService=ft,this.storeService=G,this.googleGtagAnalyticsService=vt}setPageUrlsFromRoute(j){this.toParams=(0,s.merge)((0,s.cloneDeep)(j.params),j.queryParams,{isAuthenticated:j.isAuthenticated}),this.fromPageUrl=this.flowpageManagementService.getLocationPath().split("?")[0];const z=j.path.split("/");this.toPageUrl=z.length>2&&"donations"===z[0]?(0,s.join)((0,s.slice)(z,1,z.length-1),"/"):j.path}trackRouteChange(j,z=!1){z||this.setPageUrlsFromRoute(j);const q=(0,s.omitBy)(this.toParams,s.isNil),at=this.flowPageValidationService.isFlow(this.toPageUrl),nt=this.flowPageValidationService.isFlowStart(this.toPageUrl),et=this.flowPageValidationService.isFlowJoinTeamRegistration(this.toPageUrl,this.toParams),o=this.flowPageValidationService.isFlowTicketing(this.toPageUrl);if((0,s.isNil)(at)){const ft=(0,s.isNil)(o);return this.clearCurrentState(ft),ft?this.storeService.clearCart():e.E}const mt=this.storageService.getJWT();return(0,s.isNil)(mt)?this.jwtAuthService.getAnonymousToken({subEventCustomPart:this.toParams.subEventCustomPart}).pipe((0,y.w)(()=>this.setupFlow(at,nt,et,q,o))):this.setupFlow(at,nt,et,q,o)}setupFlow(j,z,q,at,nt){return this.flowPageValidationService.validateFlowChange(this.toPageUrl).pipe((0,y.w)(et=>{if(et){const o=this.getStartUrl(j,z);return this.resetFlowPageState(o,q)}return(0,_.of)(null)}),(0,y.w)(et=>null!==et?this.initializeFlowState(et,at,this.toParams):this.getFlowPageState()),(0,f.b)(()=>{this.flowButtonService.setIsFirstStepInFlow(z)}),(0,r.U)(et=>{switch(this.flowPageValidationService.isValidToProceed(this.toPageUrl,et)){case a.q.ValidToProceed:case a.q.IsFirstPage:return nt&&this.setTicketingFlowStep(et),this.setFirstCompleted(z,et),this.setFlowStepStatus(et,this.toPageUrl,D.Z.Started),this.saveFlowPageState(et),console.debug("trackRouteChange past 1st step",this.toParams,et),null;case a.q.ReviewPage:return this.setFirstCompleted(z,et),this.setFlowStepStatus(et,this.toPageUrl,D.Z.Started),et.status=D.Z.Review,this.saveFlowPageState(et),console.debug("trackRouteChange review page",this.toParams,et),null;case a.q.SuccessPage:return this.setFirstCompleted(z,et),this.setFlowStepStatus(et,this.toPageUrl,D.Z.Started),et.status=D.Z.Completed,this.saveFlowPageState(et),console.debug("trackRouteChange success page",this.toParams,et),null;case a.q.FailedPage:return this.setFirstCompleted(z,et),et.status=D.Z.Failed,this.setFlowStepStatus(et,this.toPageUrl,D.Z.Started),this.saveFlowPageState(et),console.debug("trackRouteChange failed page",this.toParams,et),null;case a.q.IsJoinTeamFirstPage:console.debug("trackRouteChange join team first page",this.toParams,et);const mt=(0,s.find)(et.steps,{status:D.Z.NotStarted});return mt.status=D.Z.Started,this.saveFlowPageState(et),mt.route;case a.q.NotExistInLoadedFlow:case a.q.NotLoaded:console.debug("trackRouteChange not loaded or not existing in flow",this.toParams,et);const ft=this.getStartUrl(j,z);return this.resetFlowPageState(ft,q),ft;default:console.debug("trackRouteChange not next step or default",this.toParams,et);const G=(0,s.find)(et.steps,{status:D.Z.Started});return(0,s.isNil)(G)?(this.setFlowStepStatus(et,et.steps[0].route,D.Z.Started),this.saveFlowPageState(et),et.steps[0].route):G.route}}),(0,u.K)(et=>(console.debug("trackRouteChange error",et),(0,n._)(et))))}setTicketingFlowStep(j){const z=this.constituentService.getConstituentFromStorage(),q="ticketed/cart/attendees",nt=this.attendeeService.filterTicketedPurchaseItems(z.purchaseItems);if(((0,s.isEmpty)(nt)||!this.attendeeService.isAttendeeInfoRequired())&&(this.setFlowStepStatus(j,q,D.Z.Skip),this.toPageUrl===q)){const o=(0,s.findIndex)(j.steps,{route:q});this.toPageUrl=j.steps[o+1].route}0===this.constituentService.getTotalAmount(z)&&this.setFlowStepStatus(j,"ticketed/cart/payment",D.Z.Skip)}setFirstCompleted(j,z){j||this.setFlowStepStatus(z,this.fromPageUrl,D.Z.Completed)}getStartUrl(j,z){let q=j[0];if(!z){const at=q.split("/");at[at.length-1]="start",q=at.join("/")}return q}setFlowStepStatus(j,z,q){const at=(0,s.find)(j.steps,{route:z});(0,s.isNil)(at)||(at.status=q)}setFlowStepStatusByIndex(j,z,q){j.steps[z].status=q}getFlowPageState(){let j=this.storageService.getData("flowPageState");return null===j&&((0,s.isNil)(this.flowPageValidationService.isFlowVolunteer(this.toPageUrl))?j={}:(j={name:"volunteer",params:(0,s.omitBy)(this.toParams,s.isNil),status:D.Z.Started,subEventPart:this.toParams.subEventCustomPart,moduleId:c.PO.VolunteerRegistration,flowId:c.MK.VolunteerRegistration,steps:[{flowStepId:0,route:(0,s.toLower)(this.toPageUrl),flowRoute:`${this.toParams.subEventCustomPart}/${(0,s.toLower)(this.toPageUrl)}`,status:D.Z.Started,name:"start",pageId:0,sortOrder:0,views:[{flowStepId:0,pageId:0,sortOrder:0,flowTemplateViewId:0,templateView:`<rx-flow-disabled flowtype="${c.MK.VolunteerRegistration}"></rx-flow-disabled>`}]}]},this.saveFlowPageState(j))),(0,_.of)(j)}clearCurrentState(j=!0){if(this.storageService.clearFlowData(),this.googleGtagAnalyticsService.resetGeneralDonation(),this.returningUserService.isReturningUser()){const q=this.constituentService.getConstituentFromStorage();(0,s.set)(q,"surveys",[]),j&&(0,s.set)(q,"purchaseItems",[]),this.constituentService.saveConstituent(q)}else this.constituentService.clearConstituentFromStorage(j)}saveFlowPageState(j){return console.debug("Saved FlowPageState",j),this.storageService.setData("flowPageState",j),j}updateRegFlowPageState(j){const z=this.flowPageValidationService.isFlow(this.toPageUrl),q=this.flowPageValidationService.isFlowStart(this.toPageUrl),at=this.getStartUrl(z,q);return(0,i.a)([this.getFlowPageState(),this.flowpageManagementService.getFlowsByRouteUrl(at,j.mid)]).pipe((0,f.b)(nt=>console.debug("updateRegFlowPageState",nt)),(0,C.h)(([nt,et])=>(0,s.includes)([1,3,5],nt.moduleId)&&nt.moduleId!==et.moduleId),(0,L.z)(([nt,et])=>this.initializeFlowState(et,nt.params,{...j,subEventCustomPart:nt.subEventPart})),(0,r.U)(nt=>(this.setFlowStepStatusByIndex(nt,0,D.Z.Completed),this.setFlowStepStatusByIndex(nt,1,D.Z.Started),this.saveFlowPageState(nt),nt)),(0,u.K)(nt=>(console.debug(nt),(0,n._)(nt))))}updateDonationToEventFlowPageState(){return this.getFlowPageState().pipe((0,r.U)(j=>(j.steps.forEach(z=>{if(![10,20].includes(z.sortOrder)){const q=at=>{const nt=(0,s.toLower)(at);return(0,s.endsWith)(nt,"/sponsor/successful")?(0,s.replace)(nt,"/sponsor/successful","/donation/success"):(0,s.replace)(nt,"/sponsor/","/donation/")};z.route=q(z.route),z.flowRoute=q(z.flowRoute)}}),j.moduleId=c.PO.PledgeDonateToEvent,this.setFlowStepStatusByIndex(j,0,D.Z.Completed),this.setFlowStepStatusByIndex(j,1,D.Z.Skip),this.setFlowStepStatusByIndex(j,2,D.Z.Started),this.saveFlowPageState(j))),(0,f.b)(j=>console.debug("updateDonationToEventFlowPageState",j)),(0,u.K)(j=>(console.debug(j),(0,n._)(j))))}updateFlowStep(j){return this.getFlowPageState().pipe((0,r.U)(z=>{if(z.steps.length>1){let q=(0,s.findIndex)(z.steps,{name:j});"success"===(0,s.toLower)(j)&&-1==q&&(q=(0,s.findIndex)(z.steps,{name:"successful"})),this.setFlowStepStatusByIndex(z,q-1,D.Z.Completed),this.setFlowStepStatusByIndex(z,q,D.Z.Started)}return this.saveFlowPageState(z)}),(0,f.b)(z=>console.debug("updateFlowStep",z)),(0,u.K)(z=>(0,n._)(z)))}initializeFlowState(j,z,q){return this.getFlowPageState().pipe((0,L.z)(at=>{const nt=(0,s.cloneDeep)(at);nt.params=z,nt.status=D.Z.Started,nt.subEventPart=q.subEventCustomPart,nt.moduleId=j.moduleId,nt.flowId=j.flowId,nt.steps=[];const et=null!==this.flowPageValidationService.isFlowTicketingCart(this.toPageUrl);q.isAuthenticated&&et&&(j.steps=(0,s.slice)(j.steps,1),this.toPageUrl=(0,s.toLower)(j.steps[0].routingPath));const o=this.constituentService.getConstituentFromStorage();if(this.flowPageValidationService.isFlowTicketingDonation(this.toPageUrl)){let rt=this.constituentService.findTicketingPurchaseItem(o);(0,s.size)(rt)&&this.flowpageManagementService.getFlowsByRouteUrl("ticketed/cart/start",null,!0).subscribe({next:Y=>{console.debug("tickingCartFlow",Y)}})}if(this.mapFlowToFlowPageState(j,nt),this.constituentService.isLoggedIn(o)){const rt=(0,s.find)(at.steps,{name:"login"});this.setFlowStepStatus(nt,rt?.route,D.Z.Skip)}if(this.flowPageValidationService.isFlowJoinTeamRegistration(this.toPageUrl,q))return this.flowPageTrackerSetupService.setupJoinTeamFlow(nt,q);const G=this.flowPageValidationService.isFlowTicketing(this.toPageUrl),vt=(0,s.filter)(o.purchaseItems,rt=>[c.qG.StoreItem,c.qG.GeneralDonation].includes(rt.type)).length===o.purchaseItems.length;return G&&vt&&this.setFlowStepStatus(nt,"ticketed/cart/start",D.Z.Skip),(0,_.of)(nt)}),(0,r.U)(at=>this.saveFlowPageState(at)))}mapFlowToFlowPageState(j,z){return(0,s.map)(j.steps,q=>{z.steps.push({flowStepId:q.flowStepId,route:(0,s.toLower)(q.routingPath),flowRoute:`${z.subEventPart}/${(0,s.toLower)(q.routingPath)}`,status:D.Z.NotStarted,name:(0,s.toLower)(q.name),pageId:q.pageId,sortOrder:q.sortOrder,views:q.views})}),z}resetFlowPageState(j,z){const q=(0,s.isNil)(this.flowPageValidationService.isFlowTicketingCart(j))&&(0,s.isNil)(this.flowPageValidationService.isFlowTicketingDonation(j));return this.clearCurrentState(q),z?this.flowpageManagementService.getFlowsByRouteUrl(j,c.PO.JoinTeamRegistration):this.flowpageManagementService.getFlowsByRouteUrl(j)}switchLoadedFlow(j){(0,s.isNil)(j.moduleId)?console.debug("switchLoadedFlow: ModuleId is null"):(0,P.D)([this.flowpageManagementService.getFlowsByModuleId(j.moduleId),this.getFlowPageState()]).pipe((0,L.z)(([z,q])=>this.initializeFlowState(z,q.params,{subEventCustomPart:q.subEventPart}))).subscribe({next:z=>this.saveFlowPageState(z)})}static#t=this.\u0275fac=function(z){return new(z||W)(M.LFG(l.V1),M.LFG(E.A),M.LFG(I.n),M.LFG(R),M.LFG(A.d),M.LFG(m.H),M.LFG(T.p),M.LFG(B.J),M.LFG(p.tH),M.LFG(O.d),M.LFG(F.Wf))};static#e=this.\u0275prov=M.Yz7({token:W,factory:W.\u0275fac,providedIn:"root"})}return W})()},20376:(Z,K,t)=>{"use strict";t.d(K,{p:()=>y});var s=t(22096),e=t(37398),_=t(6990),i=t(55909),P=t(72905),D=t(21875),I=t(89723),T=t(65879),a=t(96814);let y=(()=>{class f{constructor(u,C){this.storageService=u,this.location=C,this.isFlowStartRegex=/((pledge|donations|volunteer|store|ticketed)\/(start|.+\/\bstart\b)\/?$)|((forgot-username|forgot-password)$)/i,this.isReviewPageRegex=/(pledge|donations|volunteer|store|ticketed)\/(review|.+\/\breview\b)/i,this.isSuccessfulRegex=/(pledge|donations|volunteer|store|ticketed|forgot-username|forgot-password)\/(\b(success|successful|registered)\b|.+\/\b(success|successful)\b)/i,this.isFailedRegex=/(pledge|donations|volunteer|store|ticketed)\/(failed|.+\/\bfailed\b)/i,this.isFlowRegex=/((pledge|donations|volunteer|store|ticketed|payment-update|donation-update)\/.+|(forgot-username|forgot-password).*)/i,this.isTrackedFlowRegex=/((pledge|donations|volunteer|store|ticketed|payment-update|donation-update)\/.+|(forgot-username|forgot-password|login).*)/i,this.isFlowVolunteerRegex=/(volunteer)\/.+/i,this.isFlowStoreRegex=/(store)\/.+/i,this.isFlowRegistrationRegex=/pledge\/registration\/.+/i,this.isFlowSponsorRegex=/pledge\/(sponsor|donation)\/.+/i,this.isFlowDonationsRegex=/^\/(donations|donations)\/*.+/i,this.isFlowTicketingCartRegex=/ticketed\/cart\/.+/i,this.isFlowTicketingDonationRegex=/ticketed\/donation\/.+/i,this.isFlowTicketingCartAttendeesRegex=/ticketed\/cart\/attendees/i,this.isFlowTicketingRegex=/^(store|tickets|sponsorships|ticketed\/(donation|cart)\/.+)$/i}getFlowPageState(){const u=this.storageService.getData("flowPageState")||{};return(0,s.of)(u)}validateFlowChange(u){return this.getFlowPageState().pipe((0,e.U)(C=>{if(C.status===i.Z.Completed)return!0;const L=(0,_.get)(C,"steps[0].status",i.Z.NotStarted)===i.Z.Completed;return!!(C.moduleId!==I.PO.VolunteerRegistration&&this.isFlowStart(u)&&L||(0,_.isNil)(C.steps))||(0,_.isNil)((0,_.find)(C.steps,{route:u}))}))}getLocationPath(){return this.location.path().split("?")[0].split("/").splice(2).join("/")}isFlowStart(u){const C=u.match(this.isFlowStartRegex);return!(0,_.isNil)(C)}isReviewPage(u){const C=u.match(this.isReviewPageRegex);return!(0,_.isNil)(C)}isSuccessfulPage(u){const C=u.match(this.isSuccessfulRegex);return!(0,_.isNil)(C)}isFailedPage(u){const C=u.match(this.isFailedRegex);return!(0,_.isNil)(C)}isFlow(u){return u.match(this.isFlowRegex)}isTrackedFlow(u){return u.match(this.isTrackedFlowRegex)}isFlowDonations(u){return u.match(this.isFlowDonationsRegex)}isFlowStore(u){return u.match(this.isFlowStoreRegex)}isFlowTicketing(u){return u.match(this.isFlowTicketingRegex)}isFlowSponsor(u){return u.match(this.isFlowSponsorRegex)}isFlowRegistration(u){return u.match(this.isFlowRegistrationRegex)}isFlowVolunteer(u){return u.match(this.isFlowVolunteerRegex)}isFlowTicketingCart(u){return u.match(this.isFlowTicketingCartRegex)}isFlowTicketingCartAttendees(u){return u.match(this.isFlowTicketingCartAttendeesRegex)}isFlowTicketingDonation(u){return u.match(this.isFlowTicketingDonationRegex)}isFlowJoinTeamRegistration(u,C){return!(0,_.isNil)(C)&&this.isFlowStart(u)&&!(0,_.isNil)(this.isFlowRegistration(u))&&+C.tid>0}isValidToProceed(u,C){const L=(0,_.reject)(C.steps,{status:i.Z.Skip});if((0,_.isNil)(C)||(0,_.isEmpty)(C))return P.q.NotLoaded;const g=(0,_.find)(L,{route:u});if((0,_.isNil)(g))return P.q.NotExistInLoadedFlow;if(this.isFlowStart(u)&&C.status!==i.Z.Review)return g.status===i.Z.Completed&&this.isFlowJoinTeamRegistration(u,C.params)?P.q.IsJoinTeamFirstPage:P.q.IsFirstPage;if(C.status===i.Z.Failed&&this.isFailedPage(u))return P.q.FailedPage;if(g.status===i.Z.NotStarted){const c=(0,_.findIndex)(L,g),l=(0,_.findIndex)(C.steps,g),d=C.steps[l-1];if(!(0,_.isNil)(d)&&"payment"===d.name&&d.status===i.Z.Skip)return P.q.ValidToProceed;if(c-1!==(0,_.findIndex)(L,{status:i.Z.Started}))return P.q.NotNextStep}return this.isReviewPage(u)?P.q.ReviewPage:this.isSuccessfulPage(u)?P.q.SuccessPage:P.q.ValidToProceed}static#t=this.\u0275fac=function(C){return new(C||f)(T.LFG(D.V1),T.LFG(a.Ye))};static#e=this.\u0275prov=T.Yz7({token:f,factory:f.\u0275fac,providedIn:"root"})}return f})()},8891:(Z,K,t)=>{"use strict";t.d(K,{R:()=>y});var s=t(22096),e=t(58504),_=t(2459),n=t(9315),i=t(37398),P=t(26306),D=t(6990),T=t(65879);const a=()=>(0,s.of)(!0).toPromise();let y=(()=>{class f{constructor(){this.preValidationPromiseCallbacks=[],this.validationPromiseCallbacks=[],this.postValidationPromiseCallbacks=[]}getSuccess(u,C){if("boolean"!=typeof C)throw new Error(`Validation promise callback returned value of type ${typeof C} but expected boolean`);return u&&C}registerPreValidationPromiseCallback(u){return this.registerPromiseCallback(u,this.preValidationPromiseCallbacks)}registerValidationPromiseCallback(u){return this.registerPromiseCallback(u,this.validationPromiseCallbacks)}registerPostValidationPromiseCallback(u){return this.registerPromiseCallback(u,this.postValidationPromiseCallbacks)}registerPromiseCallback(u,C){if(u){if("function"!=typeof u)throw new Error("Parameter getPromiseCallback must be function");return C.push(u)-1}return-1}unregisterPreValidationPromiseCallback(u){typeof this.preValidationPromiseCallbacks[u]<"u"&&(this.preValidationPromiseCallbacks[u]=a)}unregisterValidationPromiseCallback(u){typeof this.validationPromiseCallbacks[u]<"u"&&(this.validationPromiseCallbacks[u]=a)}unregisterPostValidationPromiseCallback(u){typeof this.postValidationPromiseCallbacks[u]<"u"&&(this.postValidationPromiseCallbacks[u]=a)}execValidationPromiseCallback(u){try{const C=u();if(!(0,D.isObject)(C)&&!(0,D.isFunction)(C)||!(0,D.isFunction)(C.then))throw new Error("Get promise callback function did not return Promise object");return C}catch(C){return(0,s.of)((0,e._)(C)).toPromise()}}validateCallbacks(u){if(u.length>0){const C=u.map(L=>(0,_.D)(this.execValidationPromiseCallback(L)));return(0,n.D)(C).pipe((0,i.U)(L=>(0,D.reduce)(L,this.getSuccess,!0)),(0,P.K)(L=>(console.debug(L),(0,e._)(L))))}return(0,s.of)(!0)}preValidate(){return this.validateCallbacks(this.preValidationPromiseCallbacks)}validate(){return this.validateCallbacks(this.validationPromiseCallbacks)}postValidate(){return this.validateCallbacks(this.postValidationPromiseCallbacks)}countRegisteredValidationPromiseCallbacks(){return this.validationPromiseCallbacks.length}countRegisteredPreValidationPromiseCallbacks(){return this.preValidationPromiseCallbacks.length}countRegisteredPostValidationPromiseCallbacks(){return this.postValidationPromiseCallbacks.length}stateChangeSuccessHandler(){this.validationPromiseCallbacks=[],this.preValidationPromiseCallbacks=[],this.postValidationPromiseCallbacks=[]}static#t=this.\u0275fac=function(C){return new(C||f)};static#e=this.\u0275prov=T.Yz7({token:f,factory:f.\u0275fac,providedIn:"root"})}return f})()},91221:(Z,K,t)=>{"use strict";t.d(K,{_:()=>L});var s=t(89723),e=t(26028),_=t(329),n=t(6990),P=t(22096),D=t(58504),I=t(37398),T=t(26306),a=t(35297),y=t(40424),f=t(21875),r=t(40374),u=t(65879),C=t(89515);let L=(()=>{class g{constructor(l,d,A,S,v,b){this.raisinAPI=l,this.translate=d,this.constituentService=A,this.storageService=S,this.userInteractionPrivacyService=v,this.rdd=b,this.formName="stepForm",this.countryOptions=[],this.provinceOptions=[],this.profileFieldsCollection={}}convertToOptions(l){const d=[];return(0,n.forEach)(l,A=>{const S=(A.text||"").trim(),v=(A.value||"").trim();d.push({value:v,text:S,selected:A.selected||!1})}),d}excludeEmptyOptions(l){const d=(l.value||"").trim(),A=d?parseFloat(d):NaN,S=(0,n.isNumber)(A)&&isFinite(A);return!!d&&(!S||A>0)}storeFieldData(l){if(l){const d=(0,n.find)(l,S=>"Country"===S.fieldKind);this.countryOptions=(0,n.get)(d,"fieldTypeParameter",[]);const A=(0,n.find)(l,S=>"Province"===S.fieldKind);this.provinceOptions=(0,n.get)(A,"fieldTypeParameter",[])}}getConstituentRegistrationItem(l){return this.constituentService.findRegistrationTeamCaptainPurchaseItem(l)||this.constituentService.findRegistrationTeamMemberPurchaseItem(l)||this.constituentService.findRegistrationIndividualPurchaseItem(l)}parseFloat(l){return/^(\-|\+)?([0-9]+(\.[0-9]+)?|Infinity)$/.test(l)?Number(l):NaN}getConstituentCountryId(l){return parseFloat(`${l.profile&&l.profile.address?l.profile.address.countryId:null}`)}getFields(l){return Array.isArray((0,n.get)(this.profileFieldsCollection,[this.rdd.languageId,l]))?(0,P.of)(this.profileFieldsCollection[this.rdd.languageId][l]):this.raisinAPI.FormFields.get({profileTypeId:l},null,null).pipe((0,I.U)(d=>{const A=d.fields;return(0,n.set)(this.profileFieldsCollection,this.rdd.languageId,{[l]:A}),this.storeFieldData(this.profileFieldsCollection[this.rdd.languageId][l]),A}),(0,T.K)(d=>(0,D._)(d)))}createField(l,d){const A=this.constituentService.getConstituentFromStorage(),S={title:l.title,dynamicFieldId:l.dynamicFieldId,id:l.fieldKind,name:l.fieldKind.substring(0,1).toLowerCase()+l.fieldKind.substring(1),subEventDynamicFieldId:l.subEventDynamicFieldId,hideLabel:l.hideLabel,required:l.required,formName:this.formName,sameAs:l.sameAs,unique:l.unique,isHidden:l.isHidden,link:l.link||{}};l.link&&(S.link=l.link),l.autocomplete&&(S.autocomplete=l.autocomplete);const v=this.getConstituentCountryId(A);if("EmailConfirm"===l.fieldKind||"Email"===l.fieldKind)S.type="text",S.pattern=e.z1.EmailRegex;else if("Password"===l.fieldKind||"PasswordConfirm"===l.fieldKind)S.type="password";else if("Phone"===l.fieldKind)S.type="tel",S.pattern=v===s.cH.Canada||v===s.cH.UnitedStates?e.z1.CanadaOrUSPhoneRegex:e.z1.InternationalRegex;else if("PostalCode"===l.fieldKind)S.type="postalCode",S.pattern=v===s.cH.Canada?e.z1.CanadaPostalCodeRegex:v===s.cH.UnitedStates?e.z1.UnitedStatesPostalCodeRegex:v===s.cH.France?e.z1.FrancePostalCodeRegex:e.z1.OtherPostalCodeRegex;else if("Goal"===l.fieldKind){S.required=l.required,S.type="goal",S.globalizedFloat=!0,S.updateOn="change",S.pattern=(0,n.includes)(this.translate.currentLang,"fr")?e.z1.FrCurrencyRegex:e.z1.EnCurrencyRegex,S.min=e.z1.Donation.MinForOnlineDonation,S.max=e.z1.Donation.MaxForOnlineDonation,S.isDecimal=!0;const b=this.getConstituentRegistrationItem(A);b&&(+b.minFundRaisingGoal>S.min&&(S.min=b.minFundRaisingGoal),S.greaterThanOrEqual=b.minFundRaisingGoal,S.suggestedGoal=b.suggestedFundRaisingGoal)}else if(d)S.type=d;else switch(l.templateName||l.fieldType){case"RaisinDynamicTextField_Int32":case"RaisinDynamicTextField_Decimal":case"RaisinDynamicTextField_String":case"TextBox":S.type="text";break;case"AutocompleteLocation":S.type="AutocompleteLocation";break;case"RaisinDynamicDropDownField":case"DropDownList":if(S.type="dropdownlist","Province"===l.fieldKind)S.availableOptions=l.fieldTypeParameter;else{let b=this.convertToOptions(l.fieldTypeParameter);"Country"===l.fieldKind&&(b=b.filter(this.excludeEmptyOptions)),S.availableOptions=b}break;case"ContactType":S.type="contactType",S.databind="this.constituent.profile.contactType",S.availableOptions=this.convertToOptions(l.fieldTypeParameter),S.isHidden=!!S.availableOptions&&!(0,n.isNil)(S.availableOptions)&&!(0,n.isEmpty)(S.availableOptions);break;case"RaisinDynamicTextField_Boolean":case"CheckBox":S.type="checkbox";break;case"RaisinDynamicTextField_DateTime":S.type="datetime";break;case"DateOfBirth":S.type="dob"}return S}getFormInputs(l){const d=this.rdd.subEvent.eventTypeId!==s.tw.Donations;return this.getFields(l).pipe((0,I.U)(A=>(0,n.filter)(A||[],function(v){return!("CorrespondenceLanguage"===v.fieldKind||"InterfaceLanguage"===v.fieldKind||l!==s.uy.Participant&&("Username"===v.fieldKind||"Password"===v.fieldKind||"PasswordConfirm"===v.fieldKind||"Goal"===v.fieldKind||"ParticipantFund"===v.fieldKind))})),(0,I.U)(A=>{let S=[];const v=A.find(m=>"AddressLine1"===m.fieldKind);let b=!1,M=!1;for(let m=0;m<A.length;m++){("Username"===A[m].fieldKind||"Password"===A[m].fieldKind||"PasswordConfirm"===A[m].fieldKind)&&(A[m].autocomplete="off","PasswordConfirm"===A[m].fieldKind&&(A[m].sameAs="this.constituent.profile.accountInfo.password"),A[m].required=!0),A[m].unique="Username"===A[m].fieldKind,"EmailConfirm"===A[m].fieldKind&&(A[m].sameAs="this.constituent.profile.email"),"UserType"===A[m].fieldKind&&(A[m].hideLabel=!0);const p=this.createField(A[m]);if(p.databinding="fields["+m+"]",!p.databind)switch(p.name){case"title":p.sortingOrder=0,p.class=d?"":"input-wrap--half";break;case"firstName":p.sortingOrder=1,p.class=d?"":"input-wrap--double";break;case"middleName":p.sortingOrder=2,b=!0,p.class=d?"":"input-wrap--double end";break;case"lastName":p.sortingOrder=3,b||(p.class=d?"":"input-wrap--double end");break;case"emailType":p.sortingOrder=4,p.class=d?"":"input-wrap--half";break;case"email":p.sortingOrder=5;break;case"phoneType":p.sortingOrder=6;break;case"phone":p.sortingOrder=7,p.class=d?"":"input-wrap--double",p.databind="this.constituent.profile.phone";break;case"phoneExtension":p.sortingOrder=8,M=!0,p.class=d?"":"input-wrap--double end",p.databind="this.constituent.profile.phoneExtension";break;case"gender":p.sortingOrder=9,p.class=d?"":M?"input-wrap--double":"input-wrap--double end",p.databind="this.constituent.profile.gender";break;case"dateOfBirth":p.sortingOrder=10,p.databind="this.constituent.profile.dateOfBirth";break;case"companyName":p.sortingOrder=12,p.databind="this.constituent.profile.organization";break;case"addressType":p.sortingOrder=13;break;case"country":p.sortingOrder=14,p.databind="this.constituent.profile.address.countryId";break;case"addressLine1":p.sortingOrder=15,p.databind="this.constituent.profile.address.line1";break;case"addressLine2":p.sortingOrder=16,p.databind="this.constituent.profile.address.line2",p.title=this.translate.instant("UI.lblAddressLine2");break;case"city":p.sortingOrder=17,p.class=d?"":"input-wrap--double";break;case"province":p.sortingOrder=18,p.databind="this.constituent.profile.address.regionId",p.class=d?"":"input-wrap--double end";break;case"postalCode":p.sortingOrder=19,p.class=d?"":"input-wrap--half",p.databind="this.constituent.profile.address."+p.name;break;case"privacy":p.sortingOrder=20,p.databind="this.constituent.profile.privacy";break;case"optOut":p.sortingOrder=21,p.databind="this.constituent.profile.receiveCommunications";break;case"optOutToShare":p.sortingOrder=22,p.databind="this.constituent.profile.allowDistributionOfDetails";break;case"personalDataUseExplicitConsent":p.sortingOrder=23,p.databind="this.constituent.profile.personalDataUseExplicitConsent";break;case"username":p.min=e.id.minLength,p.max=e.id.maxLength,p.databind="this.constituent.profile.accountInfo."+p.name;break;case"password":case"passwordConfirm":p.min=e.Qj.minLength,p.max=e.Qj.maxLength,p.databind="this.constituent.profile.accountInfo."+p.name;break;case"attribute1":p.sortingOrder=23,p.databind="this.constituent.profile.customField1",p.isExternalLabel=!0;break;case"attribute2":p.sortingOrder=24,p.databind="this.constituent.profile.customField2",p.isExternalLabel=!0;break;case"attribute3":p.sortingOrder=25,p.databind="this.constituent.profile.customField3",p.isExternalLabel=!0;break;case"attribute4":p.sortingOrder=26,p.databind="this.constituent.profile.customField4",p.isExternalLabel=!0;break;case"attribute5":p.sortingOrder=27,p.databind="this.constituent.profile.customField5",p.isExternalLabel=!0;break;default:p.databind="this.constituent.profile."+p.name}p.isPrivateData=this.userInteractionPrivacyService.isPrivateData(p.databind),"userType"===p.name&&(p.sortingOrder=11),p.defaultState={required:p.required,isHidden:p.isHidden,pattern:p.pattern,defaultOptions:(0,n.cloneDeep)(p.availableOptions)},S.push(p)}v||(S=S.filter(m=>"addressLine2"!==m.name));const B=this.getField(S,"UserType");if(B){const m=this.getField(S,"CompanyName");B.link={companyName:!m.required}}const E=this.getField(S,"Country");return E&&(E.link={province:this.getField(S,"Province"),postalCode:this.getField(S,"PostalCode"),phone:this.getField(S,"Phone")}),S}))}getFormInputDataBindingKey(l){return l.databind?l.databind.substring(l.databind.lastIndexOf(".")+1):-1===l.name.lastIndexOf("_")?l.name:l.name.substring(l.name.lastIndexOf("_")+1)}isAnyFormInputRequired(l){if(l)for(let d=0;d<l.length;d++)if(l[d].required)return!0;return!1}getField(l,d){const A=(0,n.find)(l,{id:d});return A&&!(0,n.isNil)(A)?A:(0,n.find)(l,{fieldKind:d})}setPatternPostalCodeElement(l,d){if(l){let A=null;A=d===s.cH.Canada?e.z1.CanadaPostalCodeRegex:d===s.cH.UnitedStates?e.z1.UnitedStatesPostalCodeRegex:d===s.cH.France?e.z1.FrancePostalCodeRegex:e.z1.OtherPostalCodeRegex,l.pattern=A}return l.pattern}setPatternPhoneElement(l,d){return l&&(l.pattern=d===s.cH.Canada||d===s.cH.UnitedStates?e.z1.CanadaOrUSPhoneRegex:e.z1.InternationalRegex),l.pattern}setProvinceElement(l,d){l&&(l.availableOptions=(0,n.filter)(l.defaultState.defaultOptions,{countryId:d}))}getYearOptions(){const l=[];l.push({text:this.translate.instant("str_Year"),value:""});const A=(new Date).getFullYear();for(let S=A;S>A-100;S--)l.push({text:S.toString(),value:S});return l}getLongMonthNameForLocale(l,d){const A=e.z1.MonthNamesLong;return(A[this.translate.currentLang||"en-CA"]||A["en-CA"])[d]}getMonthOptions(){const l=[];l.push({text:this.translate.instant("str_Month"),value:""});for(let A=0;A<12;A++){const S=this.getLongMonthNameForLocale(this.translate.currentLang,A);l.push({text:S,value:A})}return l}getDayOptions(){const l=[];l.push({text:this.translate.instant("str_Day"),value:""});for(let A=1;A<=31;A++)l.push({text:A.toString(),value:A});return l}createAutocompleteLocationInput(){const l={fieldKind:"AutocompleteLocation",fieldType:"AutocompleteLocation",languageId:this.rdd.languageId,order:26,required:!1,title:this.translate.instant("lbl_SearchForAnAddress"),isHidden:!1},d=this.createField(l);return d.sortingOrder=12,d.isHidden=!1,d.hideLabel=!1,d.defaultState={defaultOptions:null,isHidden:null,pattern:null,required:!1},d}getCountryCodeByName(l){if((0,n.isEmpty)(this.countryOptions)||(0,n.isEmpty)(l))return null;const d=(0,n.deburr)((0,n.toLower)((0,n.trim)(l))),A=(0,n.find)(this.countryOptions,S=>(0,n.deburr)((0,n.toLower)((0,n.trim)(S.text)))===d);return A?A.value:null}getProvinceCodeByNameAndCountryId(l,d){if((0,n.isEmpty)(this.provinceOptions)||(0,n.isEmpty)(d))return null;const A=(0,n.filter)(this.provinceOptions,v=>v.countryId===+d);let S=null;if(!(0,n.isEmpty)(l)){const v=(0,n.deburr)((0,n.toLower)((0,n.trim)(l)));S=(0,n.find)(A,b=>(0,n.deburr)((0,n.toLower)((0,n.trim)(b.text)))===v)}return!S&&1===A.length&&(S=A[0]),S?S.value:null}setFieldValuesFromQuery(l,d){const A=(b,M)=>(0,n.isNil)(b)?M:b,S=this.storageService.getQueryParams(),v={cf1:S?.cf1,cf2:S?.cf2,cf3:S?.cf3,cf4:S?.cf4,cf5:S?.cf5,fn:S?.fn,ln:S?.ln,em:S?.em,pc:S?.pc};if(!(0,n.isNil)(v.cf1)){const b=(0,n.find)(d,M=>"attribute1"===M.name);b&&(l.profile.customField1=A(l.profile.customField1,v.cf1),b.value=v.cf1),l.profile.customField1=A(l.profile.customField1,v.cf1)}if(!(0,n.isNil)(v.cf2)){const b=(0,n.find)(d,M=>"attribute2"===M.name);b&&(l.profile.customField2=A(l.profile.customField2,v.cf2),b.value=v.cf2),l.profile.customField2=A(l.profile.customField2,v.cf2)}if(!(0,n.isNil)(v.cf3)){const b=(0,n.find)(d,M=>"attribute3"===M.name);b&&(l.profile.customField3=A(l.profile.customField3,v.cf3),b.value=v.cf3),l.profile.customField3=A(l.profile.customField3,v.cf3)}if(!(0,n.isNil)(v.cf4)){const b=(0,n.find)(d,M=>"attribute4"===M.name);b&&(l.profile.customField4=A(l.profile.customField4,v.cf4),b.value=v.cf4),l.profile.customField4=A(l.profile.customField4,v.cf4)}if(!(0,n.isNil)(v.cf5)){const b=(0,n.find)(d,M=>"attribute5"===M.name);b&&(l.profile.customField5=A(l.profile.customField5,v.cf5),b.value=v.cf5),l.profile.customField5=A(l.profile.customField5,v.cf5)}if(!(0,n.isNil)(v.fn)){const b=(0,n.find)(d,M=>"firstName"===M.name);b&&(l.profile.firstName=A(l.profile.firstName,v.fn),b.value=v.fn),l.profile.firstName=A(l.profile.firstName,v.fn)}if(!(0,n.isNil)(v.ln)){const b=(0,n.find)(d,M=>"lastName"===M.name);b&&(l.profile.lastName=A(l.profile.lastName,v.ln),b.value=v.ln),l.profile.lastName=A(l.profile.lastName,v.ln)}if(!(0,n.isNil)(v.em)){const b=(0,n.find)(d,M=>"email"===M.name);b&&(l.profile.email=A(l.profile.email,v.em),b.value=v.em),l.profile.email=A(l.profile.email,v.em)}if(!(0,n.isNil)(v.pc)){const b=(0,n.find)(d,M=>"postalCode"===M.name);b&&(l.profile.address.postalCode=A(l.profile.address.postalCode,v.pc),b.value=v.pc),l.profile.address.postalCode=A(l.profile.address.postalCode,v.pc)}}maskPhoneNumber4to10(l){if(l){let d=l.replace(/\D/g,"");return d.length>=4&&d.length<=7?d=d.replace(/^(\d{3})(\d{0,4})$/,e.MQ.SevenDigit):d.length<=10&&(d=d.replace(/^(\d{3})(\d{3})(\d{0,4})$/,e.MQ.TenDigit)),d}return""}maskPhoneNumber0to15(l){if(!l)return"";let d=l.replace(/\D/g,"");return d=d.replace(/^(\d{15}).*$/,e.MQ.FifteenDigit),d}getPhoneDataEntryRules(l){switch(l){case s.cH.Canada:case s.cH.UnitedStates:return{validationPattern:e.z1.CanadaOrUSPhoneRegex,mask:this.maskPhoneNumber4to10,isValueValid:d=>isFinite(+d)};default:return{validationPattern:e.z1.InternationalRegex,mask:this.maskPhoneNumber0to15,isValueValid:d=>isFinite(+d)}}}maskPostalCode(l,d){if(l){let A=l;return d===s.cH.Canada?(A=A.replace(/[^A-Za-z0-9]/g,""),A.length>3&&A.length<=6&&(A=A.replace(/^([A-Za-z0-9]{3})([A-Za-z0-9]{1,3})$/,e.R7.Canada)),A):d===s.cH.UnitedStates?(A=A.replace(/\D/g,""),A.length>5&&A.length<=9&&(A=A.replace(/^([A-Za-z0-9]{5})([A-Za-z0-9]{1,4})$/,e.R7.UnitedStatesTenDigits)),A):A.replace(d===s.cH.France?/\D/g:/[^A-Za-z0-9 -]/g,"")}return""}static#t=this.\u0275fac=function(d){return new(d||g)(u.LFG(a.O),u.LFG(C.sK),u.LFG(y.d),u.LFG(f.V1),u.LFG(r.lu),u.LFG(_.n))};static#e=this.\u0275prov=u.Yz7({token:g,factory:g.\u0275fac,providedIn:"root"})}return g})()},73989:(Z,K,t)=>{"use strict";t.d(K,{W:()=>_});var s=t(72550),e=t(65879);let _=(()=>{class n{constructor(P){this.environmentService=P}resolve(P,D){return this.environmentService.getEnvironment()}static#t=this.\u0275fac=function(D){return new(D||n)(e.LFG(s.L$))};static#e=this.\u0275prov=e.Yz7({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})()},92841:(Z,K,t)=>{"use strict";t.d(K,{sf:()=>_});var s=t(13423);const e=i=>i.router,_=(0,s.P1)(e,i=>i?.state);(0,s.P1)(e,i=>i.state.url)},44057:(Z,K,t)=>{"use strict";t.d(K,{r:()=>i});var s=t(6990),_=t(65879),n=t(1462);let i=(()=>{class P{constructor(I){this.mediaObserver=I,this.currentActive().subscribe(T=>{this.mediaChanges=T})}isBreakpoint(I){return 1===(0,s.filter)(this.mediaChanges,T=>T.mqAlias===I).length}isMobile(){return this.isBreakpoint("xs")||this.isBreakpoint("sm")}currentActive(){return this.mediaObserver.asObservable()}static#t=this.\u0275fac=function(T){return new(T||P)(_.LFG(n.u0))};static#e=this.\u0275prov=_.Yz7({token:P,factory:P.\u0275fac,providedIn:"root"})}return P})()},49766:(Z,K,t)=>{"use strict";t.d(K,{p:()=>e});var s=t(65879);let e=(()=>{class _{constructor(){}isIE(){const i=window.navigator.userAgent;return/(?:\b(MS)?IE\s+|\bTrident\/7\.0;.*\s+rv:)(\d+)/i.test(i)}isSafari(){return navigator.vendor&&navigator.vendor.indexOf("Apple")>-1&&navigator.userAgent&&-1===navigator.userAgent.indexOf("CriOS")&&-1===navigator.userAgent.indexOf("FxiOS")}isEdge(){return window.navigator.userAgent.indexOf("Edge")>-1}isIPhone(){return navigator.vendor&&navigator.vendor.indexOf("Apple")>-1&&navigator.userAgent&&navigator.userAgent.indexOf("iPhone")>-1}static#t=this.\u0275fac=function(P){return new(P||_)};static#e=this.\u0275prov=s.Yz7({token:_,factory:_.\u0275fac,providedIn:"root"})}return _})()},85553:(Z,K,t)=>{"use strict";t.d(K,{e:()=>M});var s=t(6990),e=t(91356),_=t(329),n=t(65619),i=t(58504),P=t(37398),D=t(26306),I=t(99397),T=t(20376),a=t(83779),y=t(28021),f=t(21875),r=t(65879);let u=(()=>{class R{constructor(E,m,p){this.rdd=E,this.cookieService=m,this.storageService=p}handleSiteCleanup(){const E=this.rdd.subEventId,m=(0,s.pick)(this.rdd,["subEvent","baseAPIUrl","requestedSubEventId","subEventPart","requestedSubEventPart"]);this.rdd.set("SubEventId",E),this.rdd.subEvent=m.subEvent,this.rdd.baseAPIUrl=m.baseAPIUrl,this.rdd.subEventPart=m.subEventPart}handleSiteConfig(E){this.rdd.currency=E.currency,this.rdd.donation=E.donation,this.rdd.subEvent=E.subEvent,this.rdd.organizationId=E.organizationId,this.rdd.useV3ParticipantCentre=E.useV3ParticipantCentre,this.rdd.cdnSharedImagesURL=E.cdnSharedImagesURL,this.rdd.languages||(this.rdd.languages=E.languages),this.rdd.set("SubEventId",E.subEvent.subEventId),this.rdd.culture=this.storageService.getData("culture");const m=`RaisinCulture_${this.rdd.subEventId}`,p=this.cookieService.getCookie(m);this.cookieService.removeCookie(m,{domain:"",path:"/"}),this.cookieService.setCookie(m,p),this.cookieService.removeCookie(`ViewMobile_${this.rdd.subEventId}`)}handlePageConfig(E){this.rdd.moduleId=E.moduleId||8,this.rdd.pageId=E.pageId||3,this.rdd.pageSettings=E.settings||{},this.rdd.pageSettings.urls=E.pageUrls,this.rdd.facebookCommentsUrl=E.facebookCommentsUrl,this.rdd.team=this.rdd.pageSettings.team?{teamId:this.rdd.pageSettings.team.teamId,subEventGroupId:this.rdd.pageSettings.team.subEventGroupId,teamName:this.rdd.pageSettings.team.teamName,subEventId:this.rdd.subEventId,teamLabel:this.rdd.pageSettings.team.teamLabel,captain:{captainId:this.rdd.pageSettings.team.captainId,name:this.rdd.pageSettings.team.captainName,label:this.rdd.pageSettings.team.captainLabel}}:null,this.rdd.subEventGroup=(0,s.isNil)(this.rdd.pageSettings.subEventGroup)?null:this.rdd.pageSettings.subEventGroup}static#t=this.\u0275fac=function(m){return new(m||R)(r.LFG(_.n),r.LFG(f.x9),r.LFG(f.V1))};static#e=this.\u0275prov=r.Yz7({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})(),C=(()=>{class R{constructor(E,m){this.errorHandler=E,this.rdd=m}handleSiteCleanup(){}handleSiteConfig(E){this.addStylesToPage(E)}handlePageConfig(E){this.addStylesToPage(E)}applyDynamicStyle(E){const m=E.document||window.document;let p="";const O=m.querySelector("#dynamicStyle");for(let F=5;F<101;F+=5)p+=` .is-section-${F} { min-height:${Math.floor(innerHeight*(F/100))}px !important;} `;O.styleSheet?O.styleSheet.cssText=p:""===O.innerText&&O.appendChild(m.createTextNode(p))}addStylesToPage(E){}static#t=this.\u0275fac=function(m){return new(m||R)(r.LFG(r.qLn),r.LFG(_.n))};static#e=this.\u0275prov=r.Yz7({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();var L=t(28742),g=t(40424),c=t(69862),l=t(72550),d=t(89723),A=t(26028),S=t(40374);let v=(()=>{class R{constructor(){this.faviconUrl=""}handleSiteConfig(E){this.faviconUrl=E?E.faviconUrl:"",this.setFavIcon()}setFavIcon(){this.faviconUrl&&(document.getElementById("favIconShortcut")||this.createFavIconElement("favIconShortcut","shortcut icon"),document.getElementById("favIcon")||this.createFavIconElement("favIcon","icon"))}createFavIconElement(E,m){const p=$("head"),O=$(document.createElement("link"));O.attr("type","image/x-icon"),O.attr("rel",m),O.attr("id",E),O.attr("href",this.faviconUrl),p.append(O)}static#t=this.\u0275fac=function(m){return new(m||R)};static#e=this.\u0275prov=r.Yz7({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})();var b=t(96814);let M=(()=>{class R{constructor(E,m,p,O,F,H,W,tt,j,z,q,at,nt,et,o,mt,ft,G){this.releaseName=E,this.oneAllConfigurationService=m,this.stylesService=p,this.subEventGroupService=O,this.languageService=F,this.metadataService=H,this.googleAnalytics=W,this.constituentService=tt,this.favIconService=j,this.rdd=z,this.flowPageValidationService=q,this.rddConfigService=at,this.http=nt,this.environmentService=et,this.userInteractionRecordingService=o,this.apmService=mt,this.storageService=ft,this.location=G,this.logRocketMonitorIsFlowEnabled=!1,this.pageConfigurationCompleted$=new n.X(!1),this.defaultUrl="/"}handleErrorData(E){return 404===E.status?(this.rdd.set("error",E.error),this.rddConfigService.handleSiteConfig({languages:E.error.languages,subEvent:E.error.subEvent,useV3ParticipantCentre:E.error.useV3ParticipantCentre}),this.languageService.handleSiteConfig({languages:E.error.languages}),this.stylesService.handleSiteConfig({styles:E.error.styles}),(0,i._)(E)):(0,s.isNil)((0,s.get)(E,"body"))?E:E.body}doSiteCleanup(){this.rddConfigService.handleSiteCleanup(),this.languageService.handleSiteCleanup(),this.stylesService.handleSiteCleanup(),this.subEventGroupService.handleSiteCleanup(),this.googleAnalytics.clearAccounts(),this.rdd.handleSiteCleanup()}requestSiteConfiguration(E,m){this.doSiteCleanup();const p={url:(0,s.isNil)(E)?this.defaultUrl:E},O={headers:(new c.WM).set("Authorization",`Bearer ${this.storageService.getJWT()}`)};return this.http.get(`${this.environmentService.getEnvironment().raisinEndpointUrl}/config/site/`,{...O,params:p}).pipe((0,P.U)(F=>(this.rddConfigService.handleSiteConfig({cdnSharedImagesURL:F.cdnSharedImagesURL,languages:F.languages,currency:F.currency,donation:F.donation,organizationId:F.organizationId,subEvent:F.subEvent,useV3ParticipantCentre:F.useV3ParticipantCentre}),this.languageService.handleSiteConfig({languages:F.languages,interfaceLanguage:m,localization:F.localization}),this.stylesService.handleSiteConfig({styles:F.styles}),this.rdd.subEvent.isMultiPledge&&this.subEventGroupService.handleSiteConfig({subEventGroupData:F.subEventGroupData}),this.constituentService.handleSiteConfig({constituent:F.constituent}),this.googleAnalytics.registerAccounts(F.googleAnalythicsAccounts||[],this.rdd.culture,F.currency.code,F.subEvent.eventTypeId),this.metadataService.handleSiteConfig(F.subEvent,F.systemContentSettings),this.favIconService.handleSiteConfig(F.subEvent),(0,s.isNil)(F.facebookAppId)||this.oneAllConfigurationService.initFacebookService({appId:F.facebookAppId,version:F.facebookApiVersion}),this.metadataService.setPageTitle(this.rdd.subEvent.name),this.apmService.setInteractionAttributes(this.mapToApmInteractionAttributes(F,m)),this.storageService.setData("upsell",F.donation?.upsell),F)),(0,D.K)(F=>(this.rdd.set("error",F.error),this.stylesService.handleSiteConfig({}),this.handleErrorData(F))))}requestPageConfiguration(E,m,p){const O=`${this.environmentService.getEnvironment().raisinEndpointUrl}/config/page/${E}`+(m&&m!==d.KF.NotSet?`/${m}`:""),F={};return(0,s.forOwn)(p,(H,W)=>{(0,s.isNil)(H)||(F[W]=H)}),this.http.get(O,{params:F}).pipe((0,I.b)(H=>{this.setUpLogRocketMonitor(),this.rddConfigService.handlePageConfig(H),this.rdd.handlePageConfig(H),this.metadataService.setMetadata(H),this.constituentService.setDonationSettings(H?.donationSettings)}),(0,D.K)(H=>(0,i._)(H)))}setUpLogRocketMonitor(){this.logRocketMonitorIsFlowEnabled||(this.logRocketMonitorIsFlowEnabled=!0,this.initLogRocketOnFlow(),this.location.onUrlChange(()=>{this.initLogRocketOnFlow()}))}initLogRocketOnFlow(){const E=this.environmentService.getEnvironment();this.flowPageValidationService.isTrackedFlow(this.flowPageValidationService.getLocationPath())&&!(0,s.isEmpty)(E?.logRocketKey)&&this.userInteractionRecordingService.initialize(E.logRocketKey,this.releaseName)}buildConfigurationArgs(E,m){const p=this.getSanitizedUrlForConfigurationArgs(E),O={url:p,eventError:E.data?.routeToError||!1,moduleId:d.PO.EventHomePage,pageId:d.KF.NotSet},F={url:p};if(!O.eventError){const H=(0,s.get)(E,"data.entityType");H===d.Ox.Participant?this.setConfigurationArgsForParticipantPage(O,F,p):H===d.Ox.Team?this.setConfigurationArgsForTeamPage(O,F,p):(0,s.startsWith)(p,"g/")?this.setConfigurationArgsForGroupPage(O,F,p):m?.moduleId?(O.moduleId=m.moduleId,O.pageId=d.KF.NotSet):(O.moduleId=d.PO.EventHomePage,O.pageId=d.KF.EventHome)}return{siteConfigurationArgs:O,pageConfigurationArgs:F}}getSanitizedUrlForConfigurationArgs(E){const m=E.path.split("/");let p=m.length>2&&"donations"===m[0]?(0,s.join)((0,s.slice)(m,1,m.length-1),"/"):E.path;return p=(0,s.isEmpty)(p)?"/":(0,s.toLower)(p),/^(\/?(password-reset){1}(\/.*)?)$/i.test(p)&&(p="password-reset"),(0,s.includes)(p,"payment-update")?"payment-update":(0,s.includes)(p,"donation-update")?"donation-update":p}setConfigurationArgsForGroupPage(E,m,p){E.url=m.url="g",E.pageId=d.KF.GroupHome,E.moduleId=d.PO.GroupHomePage;const O=(0,s.nth)((0,s.split)(p,"/"),1),F=(0,s.isInteger)((0,s.toNumber)(O));m.entityCustomPart=F?void 0:`${O}`,E.entityId=m.entityId=F?(0,s.toNumber)(O):void 0,E.entityTypeId=m.entityTypeId=d.Ox.Group}setConfigurationArgsForTeamPage(E,m,p){E.url=m.url=(0,s.get)(A.mP,this.rdd.languageId,A.mP[d.SQ.en_CA]),E.pageId=d.KF.TeamHome,E.moduleId=d.PO.PledgeTeamHomePage,E.entityTypeId=m.entityTypeId=d.Ox.Team;const O=(0,s.nth)((0,s.split)(p,"/"),1);m.entityCustomPart=(0,s.startsWith)(p,"t/")?`${O}`:void 0,E.entityId=m.entityId=(0,s.startsWith)(p,"t/")?void 0:(0,s.toNumber)(O)}setConfigurationArgsForParticipantPage(E,m,p){E.url=m.url="participant",E.pageId=d.KF.ParticipantHome_Pledge,E.moduleId=d.PO.PledgeParticipantHomePage,E.entityTypeId=m.entityTypeId=d.Ox.Participant;const O=(0,s.nth)((0,s.split)(p,"/"),1);m.entityCustomPart=(0,s.startsWith)(p,"p/")?`${O}`:void 0,E.entityId=m.entityId=(0,s.startsWith)(p,"p/")?void 0:(0,s.toNumber)(O)}mapToApmInteractionAttributes(E,m){return{organizationId:E?.organizationId>0?E.organizationId:this.storageService.eventParams?.orgId??null,subEventId:E?.subEvent?.subEventId>0?E.subEvent.subEventId:this.storageService.getSubEventId()??null,subEventName:E?.subEvent?.name??null,subEventType:E?.subEvent?.eventTypeId??null,subEventCustomPart:this.storageService.eventParams?.subEventCustomPart??null,language:m??this.storageService.getLanguage()??null,userId:E?.constituent?.profile?.userId>0?E.constituent.profile.userId:null,username:E?.constituent?.profile?`${E.constituent.profile.firstName} ${E.constituent.profile.lastName}`:null,email:E?.constituent?.profile?.email??null}}static#t=this.\u0275fac=function(m){return new(m||R)(r.LFG(f.ZF),r.LFG(a.O),r.LFG(C),r.LFG(L.t),r.LFG(e.T),r.LFG(y.D),r.LFG(S.Wf),r.LFG(g.d),r.LFG(v),r.LFG(_.n),r.LFG(T.p),r.LFG(u),r.LFG(c.eN),r.LFG(l.L$),r.LFG(S.NJ),r.LFG(S.nL),r.LFG(f.V1),r.LFG(b.Ye))};static#e=this.\u0275prov=r.Yz7({token:R,factory:R.\u0275fac,providedIn:"root"})}return R})()},28021:(Z,K,t)=>{"use strict";t.d(K,{D:()=>D});var s=t(329),e=t(6990),n=t(65879),i=t(50768),P=t(89515);let D=(()=>{class I{constructor(a,y,f){this.rdd=a,this.router=y,this.translateService=f}getOrCreateMetaTag(a){const y=$("head"),f=$(document.querySelector(`meta[name="${a}"]`))[0];if(!f){const r=$(document.createElement("meta"));return r.attr("name",a),r.attr("property",a),y.append(r),r}return f}injectHeaderCode(a){a&&(console.info("head",a),this.appendCodeToElement("head",a))}injectFooterCode(a){a&&(console.info("body",a),this.appendCodeToElement("body",a))}appendCodeToElement(a,y){try{if(y){const f=$(y);for(let r=0,u=f.length;r<u;r++){const C=f[r];if("script"===(C.nodeName||"").toLowerCase())if(C.src||C.getAttribute("src"))$(a).append(C);else{let g=C.text||C.textContent||C.innerHTML||"";g=this.replaceDocumentWriteForFloodLight(g,a),$.globalEval(g)}else $(a).append(C)}}}catch(f){console.log(f)}}replaceDocumentWriteForFloodLight(a,y){return a.includes("document.write")?a.replace("document.write",`jQuery('${y}').append`):a}setMetaTags(a){const y=this.getOrCreateMetaTag("title"),f=this.getOrCreateMetaTag("description"),r=this.getOrCreateMetaTag("keywords"),u=(a&&a.title?a.title:null)||this.siteMetaTitle||"";let C=(a&&a.description?a.description:null)||"",L=(a&&a.keywords?a.keywords:null)||"";const g=!C&&!L;C=(g?this.siteMetaDescription:C)||"",L=(g?this.siteMetaKeywords:L)||"",$(y).attr("content",u),$(f).attr("content",C),$(r).attr("content",L)}resetMetaTags(){this.setMetaTags(null)}setFbMetaTags(a){this.fbMetaTags=a;for(let y=0;y<a.length;y++){const f=$("head").find(`meta[property='${a[y].property}']`)[0];if(f)f.content=a[y].content,f.name=a[y].name;else{const r=$(document.createElement("meta"));r.attr("property",a[y].property),r.attr("content",a[y].content),r.attr("name",a[y].property),$("head").append(r)}}}setCanonicalUrl(a){const y=$("head link[rel='canonical']")[0];if(y)a?y.href=a:y.parentNode.removeChild(y);else if(a){const f=$(document.createElement("link"));f.attr("rel","canonical"),f.attr("href",a),$("head").append(f)}}setPageTitle(a){const y=a||"";$("head title").text(y)}setSiteLanguage(a){for(const y of this.rdd.languages)if(y.languageId===a)return void $("html").attr("lang",y.culture.substr(0,2))}clearFbMetaTags(){$("head").find("meta[property]").removeAttr("content")}handleSiteConfig(a,y){this.siteMetaTitle=a.siteMetaTitle,this.siteMetaDescription=a.siteMetaDescription,this.siteMetaKeywords=a.siteMetaKeywords;const r=y&&y[0]?y[0].footerCode:null;this.injectHeaderCode(y&&y[0]?y[0].headerCode:null),this.injectFooterCode(r),this.setSiteLanguage(this.rdd.languageId)}handlePageConfig(a,y){const f=y&&y[0]?y[0].headerCode:null,r=y&&y[0]?y[0].footerCode:null;a?this.setMetaTags(a):this.resetMetaTags(),this.injectHeaderCode(f),this.injectFooterCode(r)}getStepTitleFromUrl(){const y=`FLOWSTEP${this.router.url.replace(new RegExp(`^/${this.rdd.subEventPart}`),"").replace(/\//g,".")}`,f=this.translateService.instant(y);if(f&&f!==y&&!(0,e.isObjectLike)(f))return`${f} ${this.rdd.subEvent.name}`}setMetadata(a){const y=a?.settings?.metaTag,f=a?.systemContentSettings??[],r=(a?.fbMetaTags??[]).filter(d=>"canonicalUrl"!==d.property),u=(0,e.first)((a?.fbMetaTags??[]).filter(d=>"canonicalUrl"===d.property).map(d=>d.content)),C=(0,e.first)(f)?.headerCode,L=(0,e.first)(f)?.footerCode,g=(0,e.find)(r,["property","title"]),c=this.getStepTitleFromUrl()??g?.content,l=(0,e.isEmpty)(c)?this.rdd.subEvent?.name:c;y?this.setMetaTags(y):this.resetMetaTags(),this.clearFbMetaTags(),this.setFbMetaTags(r),this.setCanonicalUrl(u),this.setPageTitle(l),this.injectHeaderCode(C),this.injectFooterCode(L)}static#t=this.\u0275fac=function(y){return new(y||I)(n.LFG(s.n),n.LFG(i.F0),n.LFG(P.sK))};static#e=this.\u0275prov=n.Yz7({token:I,factory:I.\u0275fac,providedIn:"root"})}return I})()},82359:(Z,K,t)=>{"use strict";t.d(K,{Z:()=>y});var s=t(6990),_=t(89723),n=t(329),i=t(9315),P=t(22096),D=t(37398),I=t(26306),T=t(35297),a=t(65879);let y=(()=>{class f{constructor(u,C){this.raisinAPI=u,this.rdd=C}loadPageContent(u){console.debug("loadPageContent start");let C=null;return u.isFlowStep?(console.debug("loadPageContent flow",u),u.moduleId&&(this.rdd.moduleId=u.moduleId),C=this.loadPageRegionsByPageUrl(u.url)):u.entityId?(console.debug("loadEntityRegions flow",u),C=this.loadEntityRegions(+u.entityId,u.url)):u.url?(console.debug("loadPageContent",u),C=this.loadPageRegionsByPageUrl(u.url)):(console.debug("loadPageContent",this.rdd.moduleId,this.rdd.pageId),C=this.loadPageRegions(this.rdd.moduleId,this.rdd.pageId)),(0,i.D)([this.loadHeaderAndFooter(),C])}loadHeaderAndFooter(){return this.pageRegions&&this.pageRegions.header&&this.pageRegions.footer&&this.loadedLanguagePart===this.rdd.requestedSubEventPart?(console.debug("loadHeaderAndFooter is already loaded"),(0,P.of)(null)):(this.loadedLanguagePart=this.rdd.requestedSubEventPart,this.clearProperties(),this.raisinAPI.HeaderAndFooterRegions.get().pipe((0,D.U)(u=>(this.setContent(u),console.debug("loadHeaderAndFooter",u),u)),(0,I.K)(()=>(console.debug("loadHeaderAndFooter catch"),this.pageRegions=null,null))))}loadPageRegionsByPageUrl(u){return u&&u.length>0&&"/"!==u&&((0,s.endsWith)(u,"/")&&(u=(0,s.trimEnd)(u,"/")),(0,s.startsWith)(u,"/")&&(u=(0,s.trimStart)(u,"/"))),this.pageUrl===u?(console.debug("loadPageRegionsByPageUrl is already loaded","pageUrl",u),(0,P.of)(null)):"/"===u?(console.debug("loadPageRegionsByPageUrl is home page","pageUrl",u),this.pageUrl=u,this.loadPageRegions(8,3)):["forgot-username","forgot-password","attendees","purchases","profile"].includes(u)||(0,s.startsWith)(u,"password-reset")?this.loadPageRegions(8,3).pipe((0,D.U)(C=>{switch(this.pageRegions.top=null,u){case"forgot-username":this.moduleId=_.PO.ForgotUsername,this.pageId=_.KF.ForgotUsername,this.pageUrl=u;break;case"forgot-password":this.moduleId=_.PO.ForgotPassword,this.pageId=_.KF.ForgotPassword,this.pageUrl=u;break;case"password-reset":this.moduleId=_.PO.PasswordReset,this.pageId=_.KF.PasswordReset,this.pageUrl=u;break;case"password-reset/success":this.moduleId=_.PO.PasswordReset,this.pageId=_.KF.PasswordResetSuccess,this.pageUrl=u;break;case"attendees":this.moduleId=_.PO.TicketingEvent,this.pageId=_.KF.Ticketing_ManageAttendees,this.pageUrl=u;break;case"purchases":case"profile":this.moduleId=_.PO.TicketingEvent,this.pageId=_.KF.Ticketing_YourPurchases,this.pageUrl=u;break;default:return console.debug("invalid page Url for forgot username/password flow","pageUrl",u),null}return console.debug("forgot username/password flow","moduleId",this.moduleId,"pageId",this.pageId),C})):(0,s.includes)(u,"oneall")?(0,P.of)():(this.clearProperties(),this.raisinAPI.PageRegionsByUrl.get({moduleId:this.rdd.moduleId},{pageUrl:u}).pipe((0,D.U)(C=>(this.setContent(C),console.debug("loadPageRegionsByPageUrl","pageUrl",u,C),this.pageUrl=u,C)),(0,I.K)(()=>(console.debug("loadPageRegionsByPageUrl catch","pageUrl",u),null))))}loadPageRegions(u,C){return this.moduleId===u&&this.pageId===C?(console.debug("loadPageRegions matching","moduleId",u,"pageId",C),(0,P.of)(null)):(this.clearProperties(),this.raisinAPI.PageRegions.get({moduleId:u,pageId:C}).pipe((0,D.U)(L=>(this.setContent(L),console.debug("loadPageRegions get","moduleId",u,"pageId",C),this.moduleId=u,this.pageId=C,L)),(0,I.K)(()=>(console.debug("loadPageRegions catch","moduleId",u,"pageId",C),null))))}loadEntityRegions(u,C){return this.entityId===u&&this.pageUrl===C?(console.debug("loadPageRegions matching","entityId",u,"url",C),(0,P.of)(null)):(this.clearProperties(),this.raisinAPI.EntityRegions.get({entityId:u,url:C}).pipe((0,D.U)(L=>(this.setContent(L),console.debug("loadEntityRegions get","entityId",u,"url",C),this.entityId=u,this.pageUrl=C,L)),(0,I.K)(()=>(console.debug("loadEntityRegions catch","entityId",u,"url",C),null))))}getContent(u){switch(u){case _.n_.HeaderRegion:return this.pageRegions.header?this.pageRegions.header.html:"";case _.n_.FooterRegion:return this.pageRegions.footer?this.pageRegions.footer.html:"";case _.n_.AboveSystemContentRegion:return this.pageRegions.top?this.pageRegions.top.html:"";case _.n_.BelowSystemContentRegion:return this.pageRegions.bottom?this.pageRegions.bottom.html:"";case _.n_.LocalSponsors:return this.pageRegions.localSponsor?this.pageRegions.localSponsor.html:"";case _.n_.SideContentRegion:return this.pageRegions.side?this.pageRegions.side.html:"";case _.n_.ParticipantImages:case _.n_.TeamImages:return this.pageRegions.images?this.pageRegions.images.html:"";case _.n_.ParticipantTitle:case _.n_.TeamTitle:return this.pageRegions.title?this.pageRegions.title.html:"";case _.n_.ParticipantJourney:case _.n_.TeamJourney:return this.pageRegions.journey?this.pageRegions.journey.html:"";default:return""}}postProcessVolunteerFromHeader(){if(this.pageRegions&&this.pageRegions.header&&this.pageRegions.header.html){const u=this.pageRegions.header.html;if(u&&this.rdd.subEvent&&!this.rdd.subEvent.hasVolunteer){const C=$("<div/>").append(u);C.find("#nav li").filter(function(){return 80===$(this).data("mid")}).remove(),this.pageRegions.header.html=C.html()}}}getEntityContent(u){switch(u){case _.UB.Images:const C=this.pageRegions.images;return C?C.html:"";case _.UB.Title:const L=this.pageRegions.title;return L?L.html:"";case _.UB.Journey:const g=this.pageRegions.journey;return g?g.html:"";default:return""}}setContent(u){null!==u&&(this.pageRegions=null==this.pageRegions?u:(0,s.merge)(this.pageRegions,u))}clearProperties(){this.moduleId=0,this.pageId=0,this.pageUrl="",this.entityId=0,console.debug("PageContentService clearProperties")}static#t=this.\u0275fac=function(C){return new(C||f)(a.LFG(T.O),a.LFG(n.n))};static#e=this.\u0275prov=a.Yz7({token:f,factory:f.\u0275fac,providedIn:"root"})}return f})()},46290:(Z,K,t)=>{"use strict";t.d(K,{Q:()=>D});var s=t(329),e=t(6990),n=t(20376),i=t(40424),P=t(65879);let D=(()=>{class I{constructor(a,y,f){this.rdd=a,this.constituentService=y,this.flowPageValidationService=f}replace(a,y){if(a&&this.hasPlaceholder(a)){const f=(0,e.merge)({},y,this.getDefaultPlaceholderHash());for(const r in f)f.hasOwnProperty(r)&&(a=a.replace("["+r+"]",f[r]))}return a}hasPlaceholder(a){return a&&/\[.*\:.*\]/im.test(a)}getDefaultPlaceholderHash(){const a={};return this.appendDataFromRdd(a),this.appendDataFromConstituent(a),a}append(a,y,f){if(a=a||{},!y)throw Error("Missing name");return!a[y]&&f&&(a[y]=f),a}appendDataFromRdd(a){const y=this.rdd.pageSettings,f=this.rdd.txResult;if(a=a||{},y&&(this.append(a,"participant:first-name",y.firstName),this.append(a,"participant:last-name",y.lastName),y.team&&this.append(a,"team:name",y.team.teamName)),f){let r=f.txCode||(f.transaction?f.transaction.txCode:null);r=r||f.transactionCode,r=r||"N/A",this.append(a,"transaction:code",r)}}appendDataFromConstituent(a){a=a||{};const y=this.constituentService.getConstituentFromStorage().profile||{},f=this.flowPageValidationService.getLocationPath(),r=!(0,e.isNil)(this.flowPageValidationService.isFlowRegistration(f)),u=!(0,e.isNil)(this.flowPageValidationService.isFlowSponsor(f)),C=!(0,e.isNil)(this.flowPageValidationService.isFlowDonations(f)),L=!(0,e.isNil)(this.flowPageValidationService.isFlowStore(f));(0,e.isNil)(this.flowPageValidationService.isFlowRegistration(f))?r?(this.append(a,"volunteer:first-name",y.firstName),this.append(a,"volunteer:last-name",y.lastName)):(u||C||L)&&(this.append(a,"donor:first-name",y.firstName),this.append(a,"donor:last-name",y.lastName)):(this.append(a,"participant:first-name",y.firstName),this.append(a,"participant:last-name",y.lastName))}static#t=this.\u0275fac=function(y){return new(y||I)(P.LFG(s.n),P.LFG(i.d),P.LFG(n.p))};static#e=this.\u0275prov=P.Yz7({token:I,factory:I.\u0275fac,providedIn:"root"})}return I})()},35297:(Z,K,t)=>{"use strict";t.d(K,{O:()=>L});var s=t(26028),e=t(61142),_=t(329),n=t(6990),P=t(21875),D=t(26306),I=t(37398),T=t(2664),a=t(58504),y=t(36232),f=t(65879),r=t(69862);const u=new e.Be;let C=(()=>{class g{constructor(l,d,A,S){this.url=l,this.rdd=d,this.httpClient=A,this.storageService=S}getUrl(l,d,A){let S=l||this.url;const v=/{([^}]+)}/g;let b;for(;null!==(b=v.exec(l||this.url));){const E=b[1];E===s.z1.BaseAPIUrl&&null!=this.rdd.baseAPIUrl&&(S=u.Angular.Utils.replaceToken(S,E,this.rdd.baseAPIUrl)),d&&d.hasOwnProperty(E)&&(S=u.Angular.Utils.replaceToken(S,E,d[E])),this.rdd.get(E)&&(S=u.Angular.Utils.replaceToken(S,E,this.rdd.get(E)))}let M="";for(const E in A)if(A.hasOwnProperty(E)){const m=A[E];if(null!==m)if(m instanceof Array)for(const p of m)M+=`&${E}=${encodeURIComponent(p)}`;else M+=`&${E}=${encodeURIComponent(m)}`}S+=M?`?${M.substr(1)}`:"";const R=[];for(;null!==(b=v.exec(S));)R.push(`{${b[1]}}`);if(R.length>0)throw new Error(`The following URL placeholders were not replaced: ${R.join(", ")}`);const B=S.split("://");return B[1]=B[1].replace(/\/\/[\/]*/g,"/"),B.join("://")}catchErrorWithHandler(l,d){return A=>A.pipe((0,D.K)(S=>{if(console.error(d,S),!(0,n.isNil)(l)){const v=l(S);return(0,T.b)(v)?v:(0,a._)(v)}return(0,a._)(S)}))}get(l,d,A){const S=this.getUrl(this.url,l,d);return this.httpClient.get(S).pipe((0,I.U)(v=>(0,n.isNil)(A)?(0,n.isNil)((0,n.get)(v,"body"))?v:v.body:A(v)),this.catchErrorWithHandler(A,"raisinApi get"))}post(l,d,A,S){const v=this.getUrl(this.url,l,d);return this.httpClient.post(v,A).pipe((0,I.U)(b=>(console.debug("raisinApi post response",b),(0,n.isNil)(S)?(0,n.isNil)((0,n.get)(b,"body"))?b:b.body:S(b))),this.catchErrorWithHandler(S,"raisinApi post"))}put(l,d,A,S){const v=this.getUrl(this.url,l,d);return this.httpClient.put(v,A,{observe:"response"}).pipe((0,I.U)(b=>(0,n.isNil)(S)?(0,n.isNil)((0,n.get)(b,"body"))?b:b.body:S(b)),this.catchErrorWithHandler(S,"raisinApi put"))}call(l,d){const A=this.getHttpRequest(l);return A?A.pipe((0,I.U)(S=>{const v=d[S.status]||d.success;return(0,n.isNil)(v)?S.body:v(S)}),(0,D.K)(S=>{console.error("raisinApi call",S);const v=d[S.status]||d.error,b=(0,n.isNil)(v)?S.body:v(S);return(0,a._)(b)})):y.E}getHttpRequest(l){const d=l.routeParams||{},A=l.queryString||{},S=l.data||{};return"get"===l.method?this.httpClient.get(this.getUrl(this.url,d,A),{observe:"response"}):"post"===l.method?this.httpClient.post(this.getUrl(this.url,d,A),S,{observe:"response"}):null}static#t=this.\u0275fac=function(d){f.$Z()};static#e=this.\u0275prov=f.Yz7({token:g,factory:g.\u0275fac,providedIn:"root"})}return g})(),L=(()=>{class g{constructor(l,d,A){this.rdd=l,this.httpClient=d,this.storageService=A,this.createRoutes()}createRoutes(){this.PageConfig=this.createAPIRoute("{BaseAPIUrl}/config/page/{moduleId}/{pageId}"),this.SiteConfig=this.createAPIRoute("{BaseAPIUrl}/config/site/{entityId}"),this.Flows=this.createAPIRoute("{BaseAPIUrl}/config/flow"),this.FlowsByUrl=this.createAPIRoute("{BaseAPIUrl}/config/flow/{moduleId}"),this.ParticipantCenterConfig=this.createAPIRoute("{BaseAPIUrl}/config/participant-center"),this.SurveyDefinition=this.createAPIRoute("{BaseAPIUrl}/surveys/{pageId}"),this.Items=this.createAPIRoute("{BaseAPIUrl}/items/{itemTypeGroupTypeId}"),this.Search=this.createAPIRoute("{BaseAPIUrl}/search/{type}"),this.Payment=this.createAPIRoute("{BaseAPIUrl}/payment/{moduleId}"),this.Constituent=this.createAPIRoute("{BaseAPIUrl}/constituent"),this.ConstituentUser=this.createAPIRoute("{BaseAPIUrl}/constituent/{userId}"),this.ConstituentAdditional=this.createAPIRoute("{BaseAPIUrl}/constituent/additional"),this.Waiver=this.createAPIRoute("{BaseAPIUrl}/waiver"),this.FormFields=this.createAPIRoute("{BaseAPIUrl}/form/{profileTypeId}/fields"),this.Regions=this.createAPIRoute("{BaseAPIUrl}/resources/regions/{countryId}"),this.Titles=this.createAPIRoute("{BaseAPIUrl}/resources/titles"),this.Countries=this.createAPIRoute("{BaseAPIUrl}/resources/countries"),this.EventLanguages=this.createAPIRoute("{BaseAPIUrl}/resources/event/languages"),this.SurveyValidation=this.createAPIRoute("{BaseAPIUrl}/surveys/validate"),this.RaisinStrings=this.createAPIRoute("{BaseAPIUrl}/resources/localize/{languageId}"),this.Store=this.createAPIRoute("{BaseAPIUrl}/store/{cartId}/{moduleId}"),this.PromoCode=this.createAPIRoute("{BaseAPIUrl}/promo"),this.Inventory=this.createAPIRoute("{BaseAPIUrl}/store"),this.ClearCart=this.createAPIRoute("{BaseAPIUrl}/store/{cartId}/clear"),this.ReturningUser=this.createAPIRoute("{BaseAPIUrl}/returning-user/{provider}"),this.Donation=this.createAPIRoute("{BaseAPIUrl}/donation"),this.AddThisConfig=this.createAPIRoute("{BaseAPIUrl}/addThisConfig/{pageId}/{moduleId}"),this.Sponsorship=this.createAPIRoute("{BaseAPIUrl}/sponsorship"),this.WidgetToken=this.createAPIRoute("{BaseAPIUrl}/user/token"),this.GoogleReCaptcha=this.createAPIRoute("{BaseAPIUrl}/google-recaptcha/validate"),this.PayPal=this.createAPIRoute("{BaseAPIUrl}/payment/paypal"),this.UserForgot=this.createAPIRoute("{BaseAPIUrl}/user/forgot"),this.UserExist=this.createAPIRoute("{BaseAPIUrl}/user/exists"),this.UsernameExist=this.createAPIRoute("{BaseAPIUrl}/user/un"),this.JoinTeam=this.createAPIRoute("{BaseAPIUrl}/teams/join/{teamId}"),this.Team=this.createAPIRoute("{BaseAPIUrl}/teams/{teamId}"),this.Attendees=this.createAPIRoute("{BaseAPIUrl}/attendees"),this.TransactionUsers=this.createAPIRoute("{BaseAPIUrl}/transactions/user"),this.TransactionInvoice=this.createAPIRoute("{BaseAPIUrl}/transactions/invoice/{txCode}"),this.TicketsPdf=this.createAPIRoute("{BaseAPIUrl}/pdf/tickets/{transactionId}/{userId}"),this.TaxReceiptSettings=this.createAPIRoute("{BaseAPIUrl}/taxreceipt/settings"),this.PrivateMessageSettings=this.createAPIRoute("{BaseAPIUrl}/privatemessage/settings"),this.PageTracking=this.createAPIRoute("{BaseAPIUrl}/pagetracking/visit/addressbookcontact/{addressBookContactId}"),this.AdminFeeConfig=this.createAPIRoute("{BaseAPIUrl}/config/adminfee"),this.ItemsLimits=this.createAPIRoute("{BaseAPIUrl}/items/limits"),this.ItemIsHonourary=this.createAPIRoute("{BaseAPIUrl}/items/isHonourary/{itemId}"),this.DonationsMatrixTypeSettings=this.createAPIRoute("{BaseAPIUrl}/settings/donations/types"),this.DonationsRecurringStartDate=this.createAPIRoute("{BaseAPIUrl}/settings/donations/recurringStartDate"),this.RecipientDetailsVisible=this.createAPIRoute("{BaseAPIUrl}/settings/donations/recipientDetailsVisiblity"),this.Funds=this.createAPIRoute("{BaseAPIUrl}/settings/donations/funds/{moduleId}"),this.ECards=this.createAPIRoute("{BaseAPIUrl}/cards/ecards"),this.PrintedCards=this.createAPIRoute("{BaseAPIUrl}/cards/printedCards"),this.Flows=this.createAPIRoute("{BaseAPIUrl}/config/flow"),this.PageRegions=this.createAPIRoute("{BaseAPIUrl}/pagecontent/page/{moduleId}/{pageId}"),this.PageRegionsByUrl=this.createAPIRoute("{BaseAPIUrl}/pagecontent/page/{moduleId}"),this.HeaderAndFooterRegions=this.createAPIRoute("{BaseAPIUrl}/pagecontent/headerfooter"),this.EntityRegions=this.createAPIRoute("{BaseAPIUrl}/pagecontent/entity/{url}/{entityId}"),this.IsGuidValid=this.createAPIRoute("{BaseAPIUrl}/password-reset/isGUIDValid/{guid}"),this.UpdatePassword=this.createAPIRoute("{BaseAPIUrl}/password-reset/update/{guid}"),this.GoogleLocationApiKey=this.createAPIRoute("{BaseAPIUrl}/settings/donations/googleLocationApiKey"),this.DoubleTheDonationSettings=this.createAPIRoute("{BaseAPIUrl}/settings/donations/doubleTheDonationSettings"),this.DoubleTheDonationEmployer=this.createAPIRoute("https://doublethedonation.com/api/360matchpro-partners/v1/companies/{employerId}"),this.SubEventSettings=this.createAPIRoute("{BaseAPIUrl}/settings/subevent"),this.UserReferralSettings=this.createAPIRoute("{BaseAPIUrl}/settings/user-referral")}createAPIRoute(l){return new C(l,this.rdd,this.httpClient,this.storageService)}static#t=this.\u0275fac=function(d){return new(d||g)(f.LFG(_.n),f.LFG(r.eN),f.LFG(P.V1))};static#e=this.\u0275prov=f.Yz7({token:g,factory:g.\u0275fac,providedIn:"root"})}return g})()},329:(Z,K,t)=>{"use strict";t.d(K,{n:()=>a});var s=t(6990),_=t(26028),n=t(18054),i=t(89723),P=t(21875),D=t(80001),I=t(65879);const T={SubEventGroupId:null,PageId:3,ModuleId:8,UrlCustomParts:[],Donation:{},APIUseJSON:!0,facebookCommentsUrl:"",TeamId:null,isAngular:!0,WidgetPath:"/sharedimages/widget-templates/template5",SiteType:"Desktop",LanguageId:0,WebRootUrl:"ui/",webRootUrl:"ui/"};let a=(()=>{class y{constructor(r,u,C){this.cookieService=r,this.storageService=u,this.jwtAuthService=C,window.raisin_dd=(0,s.assign)(T,window.raisin_dd)}get subEventId(){return+this.get("SubEventId")||+this.storageService.getData("seId")}set subEventId(r){console.error("Subevent ID is a read only value")}get requestedSubEventId(){return+this.get("RequestedSubEventId")}set requestedSubEventId(r){window.raisin_dd.RequestedSubEventId=+r}get languages(){return this.storageService.getData("languages")}set languages(r){this.storageService.setData("languages",r)}get subEventPart(){return this.get("SubEventPart")||this.storageService.eventParams?.subEventCustomPart}set subEventPart(r){window.raisin_dd.SubEventPart=r}get requestedSubEventPart(){return this.get("RequestedSubEventPart")}set requestedSubEventPart(r){window.raisin_dd.RequestedSubEventPart=r}get organizationId(){return+this.get("OrganizationId")}set organizationId(r){window.raisin_dd.OrganizationId=+r}get cdnSharedImagesURL(){return this.get("CdnSharedImagesURL")}set cdnSharedImagesURL(r){window.raisin_dd.CdnSharedImagesURL=r}get subEventGroupId(){return+this.get("SubEventGroupId")}set subEventGroupId(r){window.raisin_dd.SubEventGroupId=+r}get moduleId(){const r=this.storageService.getData("mid");return(0,s.isNil)(r)||(this.set("ModuleId",+r),this.storageService.setData("mid",+r)),+this.get("ModuleId")}set moduleId(r){window.raisin_dd.ModuleId=+r,this.storageService.setData("mid",+r)}get baseAPIUrl(){const r=this.storageService.getData("baseAPIUrl");return(0,s.isNil)(r)?n.N.raisinEndpointUrl:(this.set(_.z1.BaseAPIUrl,r),this.storageService.setData("baseAPIUrl",r),this.get(_.z1.BaseAPIUrl))}set baseAPIUrl(r){window.raisin_dd.BaseAPIUrl=r,this.storageService.setData("baseAPIUrl",r)}get pageId(){const r=this.storageService.getData("pgid");return(0,s.isNil)(r)||(this.set("PageId",+r),this.storageService.setData("pgid",+r)),+this.get("PageId")}set pageId(r){window.raisin_dd.PageId=+r,this.storageService.setData("pgid",+r)}get profileTypeId(){const r=this.storageService.getData("profileTypeId");return(0,s.isNil)(r)||(this.set("ProfileTypeId",+r),this.storageService.setData("profileTypeId",+r)),+this.get("ProfileTypeId")}set profileTypeId(r){this.set("ProfileTypeId",+r),this.storageService.setData("profileTypeId",+r)}get languageId(){return+this.get("LanguageId")}set languageId(r){console.error("Use languageService to set the language")}get culture(){return this.get("Culture")}set culture(r){window.raisin_dd.Culture=r,window.raisin_dd.LanguageCulture=r}get urlCustomParts(){return this.get("UrlCustomParts")}set urlCustomParts(r){window.raisin_dd.UrlCustomParts=r}get currency(){return this.get("Currency")}set currency(r){this.storageService.setData("currency",r),window.raisin_dd.Currency=r}get donation(){return this.get("Donation")}set donation(r){window.raisin_dd.Donation=r}get token(){return this.get("Token")}set token(r){window.raisin_dd.Token=r}get subEvent(){return this.get("SubEvent")}set subEvent(r){window.raisin_dd.SubEvent=r}get team(){return this.get("Team")}set team(r){window.raisin_dd.Team=r}get subEventGroup(){return this.get("SubEventGroup")}set subEventGroup(r){window.raisin_dd.SubEventGroup=r}get txResult(){const r=this.storageService.getData("txResult");return(0,s.isNil)(r)||(this.set("TxResult",r),this.storageService.setData("txResult",r)),this.get("TxResult")}set txResult(r){const u=(0,s.isNil)(r)?null:r;window.raisin_dd.TxResult=u,this.storageService.setData("txResult",u)}get pageSettings(){return this.get("PageSettings")}set pageSettings(r){window.raisin_dd.PageSettings=r}get lastDonation(){return this.get("LastDonation")}set lastDonation(r){window.raisin_dd.LastDonation=r}get useV3ParticipantCentre(){const r=this.storageService.getData("UseV3ParticipantCentre");return(0,s.isNil)(r)||(this.set("UseV3ParticipantCentre",!!r),this.storageService.setData("UseV3ParticipantCentre",!!r)),!!this.get("UseV3ParticipantCentre")}set useV3ParticipantCentre(r){window.raisin_dd.UseV3ParticipantCentre=!!r,this.storageService.setData("UseV3ParticipantCentre",!!r)}get hasError(){return!!this.get("error")}getOrganizationMinReceiptText(){const r=this.donation||{},u=r.organizationMinReceiptText,C=r.minTaxReceiptableAmount||0,L=this.getCurrencyCode();return u&&C>0?u.replace("{0}",C.toString()+" ("+L+")"):""}getCurrencyCode(){return(this.currency||{}).code||""}get(r){return(0,s.isNil)(r)?null:(0,s.isNil)(window.raisin_dd[r])?(0,s.isNil)(window.raisin_dd[r.substr(0,1).toUpperCase()+r.substr(1)])?null:window.raisin_dd[r.substr(0,1).toUpperCase()+r.substr(1)]:window.raisin_dd[r]}set(r,u){return window.raisin_dd[r]=u}handleSiteCleanup(){const r=window.raisin_dd.SubEvent,u=window.raisin_dd.BaseAPIUrl,C=this.subEventId,L=this.requestedSubEventId,g=this.subEventPart,c=this.requestedSubEventPart;window.raisin_dd=T,window.raisin_dd.SubEvent=r,window.raisin_dd.SubEventId=C,window.raisin_dd.RequestedSubEventId=L,window.raisin_dd.BaseAPIUrl=u,window.raisin_dd.SubEventPart=g,window.raisin_dd.RequestedSubEventPart=c,this.storageService.setData("seId",C)}handleSiteConfig(r){this.currency=r.currency,this.donation=r.donation,this.subEvent=r.subEvent,this.languages=r.languages,this.subEventId=r.subeventId,window.raisin_dd.isAngular=T.isAngular;const u=`RaisinCulture_${this.subEventId}`,C=this.cookieService.getCookie(u);this.cookieService.removeCookie(u,{domain:"",path:"/"}),this.cookieService.setCookie(u,C)}handlePageConfig(r){this.moduleId=r.moduleId||8,this.pageId=r.pageId||3,this.facebookCommentsUrl=r.facebookCommentsUrl,this.pageSettings=r.settings||{},this.pageSettings.urls=r.pageUrls,window.raisin_dd.Team=this.pageSettings.team?{teamId:this.pageSettings.team.teamId,subEventGroupId:this.pageSettings.team.subEventGroupId,teamName:this.pageSettings.team.teamName,subEventId:this.subEventId,teamLabel:this.pageSettings.team.teamLabel,captain:{captainId:this.pageSettings.team.captainId,name:this.pageSettings.team.captainName,label:this.pageSettings.team.captainLabel}}:null,window.raisin_dd.SubEventGroup=this.pageSettings.subEventGroup?this.pageSettings.subEventGroup:null}setIsAnonymous(r){window.raisin_dd.IsAnonymous=r}getIsAnonymous(){let r;return r=(0,s.isNil)(window.raisin_dd.IsAnonymous)?!this.jwtAuthService.isLoggedIn():window.raisin_dd.IsAnonymous,r}getMobileUrl(r){let u=this.subEvent?this.subEvent.mobileAppRoot:null;u||console.error("Mobile App root not configured"),u=(u||"").trim();let C=u;return r&&(r.startsWith("/")||C.endsWith("/")?C+=r:C=C+"/"+r),C}get isPledgeEvent(){return!!this.subEvent&&(this.subEvent.eventTypeId===i.tw.Pledged||this.subEvent.eventTypeId===i.tw.MultiPledged)}static#t=this.\u0275fac=function(u){return new(u||y)(I.LFG(P.x9),I.LFG(P.V1),I.LFG(D.tH))};static#e=this.\u0275prov=I.Yz7({token:y,factory:y.\u0275fac})}return y})()},9058:(Z,K,t)=>{"use strict";t.d(K,{U:()=>D});var s=t(21875),e=t(58504),_=t(26306),n=t(65879),i=t(69862),P=t(89515);let D=(()=>{class I{constructor(a,y,f,r){this.errorHandler=a,this.http=y,this.storageService=f,this.translate=r}getTeam(a){const y=this.storageService.getData("baseAPIUrl");return this.http.get(`${y}/teams/${a}`).pipe((0,_.K)(f=>(this.errorHandler.handleError(f),(0,e._)(this.translate.instant(f.data||"m_str_Error")))))}static#t=this.\u0275fac=function(y){return new(y||I)(n.LFG(n.qLn),n.LFG(i.eN),n.LFG(s.V1),n.LFG(P.sK))};static#e=this.\u0275prov=n.Yz7({token:I,factory:I.\u0275fac,providedIn:"root"})}return I})()},15047:(Z,K,t)=>{"use strict";t.d(K,{q:()=>y});var s=t(89723),e=t(6990),n=t(329),i=t(22096),P=t(58504),D=t(37398),I=t(26306),T=t(65879),a=t(69862);let y=(()=>{class f{constructor(u,C){this.http=u,this.rdd=C,this.checkUrl="/assets/urlcheck/verify"}verifyUrl(u){const L=u.split("/")[1],g=/^\d+$/.test(L),c=/(\/participant\/)(\d+)/.test(u)||/(\/p\/)(([0-9]|[A-Za-z])+([0-9a-z]+))/.test(u),l=/(\/team\/)(\d+)/.test(u)||/(\/equipe\/)(\d+)/.test(u)||/(\/t\/)(([0-9]|[A-Za-z])+([0-9a-z]+))/.test(u);return g||c||l?this.convertUrl(u):(0,i.of)(u)}convertUrl(u){const C=(0,e.isNull)(this.rdd.languageId)||0===this.rdd.languageId?null:this.rdd.languageId,L=u.split("?");let g=this.checkUrl;return g+="?url="+L[0],(0,e.isNil)(C)||(g+="&lang="+C),this.http.get(g,{observe:"response"}).pipe((0,D.U)(c=>1===L.length?c.body.url:`${c.body.url}?${L[1]}`),(0,I.K)(c=>(c&&404===c.status&&(console.log("UrlChecker 404 Error",c),c.data?.hasOwnProperty("errorType")&&c.data?.errorType===s.NI.EventNotFound&&this.rdd.set("error",c.data)),(0,P._)(c))))}static#t=this.\u0275fac=function(C){return new(C||f)(T.LFG(a.eN),T.LFG(n.n))};static#e=this.\u0275prov=T.Yz7({token:f,factory:f.\u0275fac,providedIn:"root"})}return f})()},98835:(Z,K,t)=>{"use strict";t.d(K,{i:()=>f});var s=t(58504),e=t(22096),_=t(99397),n=t(26306),i=t(37398),P=t(72550),D=t(329),I=t(61142),T=t(65879),a=t(69862);const y=new I.Be;let f=(()=>{class r{constructor(C,L,g){this.http=C,this.environmentService=L,this.rdd=g}populateWidgets(){return this.setValidWidgetToken().pipe((0,_.b)(()=>{console.debug("WidgetService populateWidgets render"),y.Angular.Utils.doNonAngularSetup(console.log)}),(0,n.K)(C=>(0,s._)(C)))}setValidWidgetToken(){const C=new Date;return C<this.expiryDate?(0,e.of)(!0):this.http.get(`${this.environmentService.getEnvironment().raisinEndpointUrl}/user/token`).pipe((0,i.U)(L=>(this.rdd.token=L.token,this.expiryDate=C,this.expiryDate.setMinutes(this.expiryDate.getMinutes()+4),!0)))}static#t=this.\u0275fac=function(L){return new(L||r)(T.LFG(a.eN),T.LFG(P.L$),T.LFG(D.n))};static#e=this.\u0275prov=T.Yz7({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})()},87656:(Z,K,t)=>{"use strict";t.d(K,{R:()=>T});var s=t(35297),e=t(58504),_=t(37398),n=t(26306),i=t(6990),D=t(65879),I=t(89515);let T=(()=>{class a{constructor(f,r){this.raisinAPI=f,this.translate=r}UserCanJoinTeam(f,r,u,C){return this.raisinAPI.JoinTeam.get({teamId:f},{userId:r,sgid:u,itemId:C}).pipe((0,_.U)(L=>L),(0,n.K)(L=>(console.error(L),(0,e._)(this.translate.instant(L.error||"m_str_Error")))))}UserCanJoinTeamValidationResult(f,r,u,C){return this.raisinAPI.JoinTeam.get({teamId:f},{userId:r,sgid:u,itemId:C,returnValidationResultObjectInResponse:!0}).pipe((0,_.U)(L=>(0,i.isBoolean)(L)?{success:!!L,message:""}:{success:!!L.success,message:L.message}),(0,n.K)(L=>(console.error(L),(0,e._)(this.translate.instant(L.error||"m_str_Error")))))}JoinTeam(f,r,u){return this.raisinAPI.JoinTeam.post({teamId:f},{userId:r,sgid:u},null).pipe((0,_.U)(()=>!0),(0,n.K)(C=>(console.error(C),(0,e._)(this.translate.instant(C.data||"m_str_Error")))))}static#t=this.\u0275fac=function(r){return new(r||a)(D.LFG(s.O),D.LFG(I.sK))};static#e=this.\u0275prov=D.Yz7({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})()},50101:(Z,K,t)=>{"use strict";t.d(K,{u:()=>f});var s=t(89723),e=t(329),_=t(58504),n=t(37398),i=t(26306),P=t(6990),I=t(35297),T=t(24589),a=t(40424),y=t(65879);let f=(()=>{class r{constructor(C,L,g,c){this.raisinAPI=C,this.constituentService=L,this.purchaseItemService=g,this.rdd=c}loadData(C){const L={itemTypeGroupTypeId:s.Bp.Registration},g={};return(0,P.isEmpty)(C)||((0,P.isNull)(C.tid)||(g.tid=C.tid),(0,P.isNull)(C.sgid)||(g.sgid=C.sgid)),this.raisinAPI.Items.get(L,g).pipe((0,n.U)(c=>c&&c.itemGroups&&c.itemGroups.length>0?(this.regItemsToggleEnabled=c.regItemsToggleEnabled,c.itemGroups):[]),(0,i.K)(c=>(0,_._)(c)))}loadDataForJoinTeamRegistration(C){return this.loadData(C).pipe((0,n.U)(L=>(0,P.find)(L||[],this.isJoinTeamRegistrationGroup)))}isRegItemToggleEnabled(){return this.regItemsToggleEnabled}isJoinTeamRegistrationGroup(C){return C&&C.itemType&&"RegistrationFeeTeamMember"===C.itemType}addNewRegistrationItemToConstituent(C,L){return L===s.qG.RegistrationFeeTeamMember?this.constituentService.addNewRegistrationTeamMemberItem(C):L===s.qG.RegistrationFeeCaptain?this.constituentService.addNewRegistrationTeamCaptainItem(C):this.constituentService.addNewRegistrationIndividualItem(C)}updateEditedRegistrationItem(C,L,g){let c=this.constituentService.findRegistrationPurchaseItem(C);const l=this.rdd.subEventGroupId||this.constituentService.getSubEventGroupId(C),d=this.rdd.subEvent.isMultiPledge&&+l!=+g;if(d||+L.itemId!=+c.itemId)if(d||+s.qG[L.itemType]!=+c.type){C=this.purchaseItemService.removePurchaseItemByItemReference(C,c),this.constituentService.clearSurveys(C);const v=this.addNewRegistrationItemToConstituent(C,L.type);this.constituentService.saveConstituent(C),v.donationAmount=c.donationAmount,v.fundRaisingGoal=c.fundRaisingGoal,v.accountInfo=c.accountInfo,c=v}else c.promoCode=null;return c}static#t=this.\u0275fac=function(L){return new(L||r)(y.LFG(I.O),y.LFG(a.d),y.LFG(T.h),y.LFG(e.n))};static#e=this.\u0275prov=y.Yz7({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})()},55509:(Z,K,t)=>{"use strict";t.d(K,{A:()=>y});var s=t(26306),e=t(37398),_=t(58504),n=t(6990),P=t(35297),D=t(89723),I=t(40424),T=t(40374),a=t(65879);let y=(()=>{class f{constructor(u,C,L){this.constituentService=u,this.raisinAPI=C,this.userInteractionRecordingService=L}loadUser(u,C){return this.getReturningUserData({provider:""},{username:u,password:C},!0)}loadUserByFacebookId(u,C=!0){return this.getReturningUserData({provider:"facebook"},{facebookUserId:u},C)}loadUserByNameAndEmail(u,C,L,g=!0){return this.getReturningUserData({provider:"nameEmail"},{firstName:u,lastName:C,email:L},g)}getReturningUserData(u,C,L){const g=this.constituentService.getConstituentFromStorage();return this.raisinAPI.ReturningUser.call({method:"post",routeParams:u,data:C},{200:c=>{L&&this.addReturningUserDataIntoConstituent(g,c.body);const l=L?g:c.body;return this.constituentService.addCustomFieldDataToConstituent(l),l},202:c=>{L&&this.addReturningUserDataIntoConstituent(g,c.body);const l=L?g:c.body;return this.constituentService.addCustomFieldDataToConstituent(l),l},204:c=>{throw c},401:c=>{throw c},403:c=>{throw c},406:c=>{throw c},409:c=>{throw c},500:c=>{throw c}}).pipe((0,s.K)(c=>{const l=(0,n.get)(c,"status");return(0,n.isNil)(l)?(0,_._)(c):(0,_._)(l)}))}addReturningUserDataIntoConstituent(u,C){const L=u.profile||{};for(const g in C.profile)C.profile.hasOwnProperty(g)&&"userId"!==g&&(L[g]=C.profile[g]||L[g]);this.userInteractionRecordingService.addIdentity(L,C.returningUserId),u.returningUserId=C.returningUserId,u.importSubEventId=C.importSubEventId}createNewUser(u){return this.raisinAPI.Constituent.get().pipe((0,e.U)(C=>{u.profile=C.profile,u.paymentDetails=C.paymentDetails,u.surveys=C.surveys,u.returningUserId=null,u.importSubEventId=null,this.constituentService.addCustomFieldDataToConstituent(u),this.clearFacebookData(u)}))}mergeSocialNetworkUserWithConstituent(u,C){const L=u.profile||{};L.contactType=`${(0,n.get)(u,"profile.contactType",D.uC.Individual)}`,L.firstName=C.givenName||L.firstName,L.lastName=C.familyName||L.lastName,u.profile=L}mergeFacebookLoginStatus(u,C){const L=C?C.authResponse:null,g=L?L.userID:null,c=L?L.accessToken:null;u.profile=u.profile||{},u.profile.accountInfo=u.profile.accountInfo||{},u.profile.accountInfo.facebookId=g,u.profile.accountInfo.facebookToken=c,u.profile.accountInfo.isLoggedWithFacebook=!0}clearFacebookData(u){null!=u.profile.accountInfo&&(u.profile.accountInfo.facebookId=null,u.profile.accountInfo.facebookToken=null,u.profile.accountInfo.isLoggedWithFacebook=!1)}isReturningUser(){const u=this.constituentService.getConstituentFromStorage();return+(0,n.get)(u,"importSubEventId",0)>0&&+(0,n.get)(u,"returningUserId",0)>0}static#t=this.\u0275fac=function(C){return new(C||f)(a.LFG(I.d),a.LFG(P.O),a.LFG(T.NJ))};static#e=this.\u0275prov=a.Yz7({token:f,factory:f.\u0275fac,providedIn:"root"})}return f})()},52044:(Z,K,t)=>{"use strict";t.d(K,{g:()=>P});var s=t(6990),_=t(65619),n=t(89723),i=t(65879);let P=(()=>{class D{constructor(){this.eventListeners={},this.loadingSubject=new _.X(null),this.flowSubject=new _.X(null),this.systemSubject=new _.X(null),this.cartSubject=new _.X(null)}listenToEvent(T,a,y){this.eventListeners[T]||(this.eventListeners[T]={}),this.eventListeners[T][a]||(this.eventListeners[T][a]=y)}notifyEventListeners(T,a){const y=this.eventListeners[T];y&&(0,s.forEach)(y,f=>{f(a)})}removeEventListener(T,a){const y=this.eventListeners[T];y&&(this.eventListeners[T]=y)}listenForEvents(T){switch(T){case n.Jk.Flow:return this.flowSubject.asObservable();case n.Jk.Loading:return this.loadingSubject.asObservable();case n.Jk.Cart:return this.cartSubject.asObservable();default:return this.systemSubject.asObservable()}}notifyListeners(T,a,y,f){const r={name:a,data:y||null,location:f};switch(T){case n.Jk.Flow:this.flowSubject.next(r);break;case n.Jk.Loading:this.loadingSubject.next(r);break;case n.Jk.Cart:this.cartSubject.next(r);break;case n.Jk.System:this.systemSubject.next(r)}}static#t=this.\u0275fac=function(a){return new(a||D)};static#e=this.\u0275prov=i.Yz7({token:D,factory:D.\u0275fac,providedIn:"root"})}return D})()},83779:(Z,K,t)=>{"use strict";t.d(K,{O:()=>R});var s=t(72550),e=t(26028),_=t(34731),n=t(65619),i=t(2459),P=t(22096),D=t(58504),I=t(94664),T=t(37398),a=t(81374),y=t(26306),f=t(32181),r=t(89723),u=t(6990),L=t(329),g=t(40424),c=t(55509),l=t(20376),d=t(55909),A=t(21875),S=t(65879),v=t(21772),b=t(63474);const M=_.ZP`
query socialNetworkUsers($connectionToken: String!, $socialNetworkTypeId: Int!) {
  socialNetworkUsers(connectionToken: $connectionToken, socialNetworkTypeId: $socialNetworkTypeId) {
    displayName,
    givenName,
    familyName,
    socialNetworkType,
    socialUserId,
    token,
    tokenExpiration
  }
}`;let R=(()=>{class B{constructor(m,p,O,F,H,W,tt,j,z){this.rdd=m,this.apollo=p,this.socialConfigService=O,this.constituentService=F,this.returningUserService=H,this.facebookService=W,this.storageService=tt,this.flowPageValidationService=j,this.environmentService=z,this.socialNetworkConnectionSubject=new n.X(null)}initFacebookService(m){this.facebookService.init(m)}logoutFromFacebook(){return(0,i.D)(this.facebookService.getLoginStatus(!0)).pipe((0,I.w)(m=>(this.disconnect(),(0,i.D)(this.facebookService.logout()).pipe((0,T.U)(()=>!0)))))}canProcessConnectionToken(m){return!(0,u.isNil)(m.connectionToken)}processCallback(m){return this.storageService.setData(e.z1.OneAllConnectionTokenKey,m.connectionToken),"true"===(0,u.toLower)(m.isLogin)?(this.storageService.setData(e.z1.OpenLoginModalKey,!0),(0,P.of)([m.subEventCustomPart])):this.flowPageValidationService.getFlowPageState().pipe((0,a.P)(),(0,T.U)(O=>{const F=(0,u.findLast)(O.steps,{status:d.Z.Started});switch(this.rdd.moduleId){case r.PO.IndividualRegistration:case r.PO.CreateTeamRegistration:case r.PO.JoinTeamRegistration:case r.PO.PledgeSponsor:case r.PO.PledgeDonateToEvent:return[`/${F.flowRoute}`]}return[m.subEventCustomPart]}))}socialNetworkConnectionUpdated(){return this.socialNetworkConnectionSubject.asObservable()}updateSocialNetworkConnection(m){this.socialNetworkConnectionSubject.next(m);const p=(0,u.get)(m,"status",r.lA.Disconnected);(p===r.lA.Connected||p===r.lA.ConnectedAsReturningParticipant)&&(0,i.D)(this.facebookService.login()).pipe((0,a.P)()).subscribe()}setUpSocialConfigForOneAll(m){this.isRegistrationFlow=m,this.handleReturningParticipantLoginV3ParticipantCentre(),this.socialConfigService.getOneAllConfig().subscribe(p=>{this.socialConfigSetting=p,this.initOneAllScript();const O=this.storageService.getData(e.z1.OneAllConnectionTokenKey);(0,u.isNil)(O)||(this.oneAllHandlerLogin({connection:{connection_token:O}}),this.storageService.removeData(e.z1.OneAllConnectionTokenKey));const F=this.constituentService.getConstituentFromStorage(),H=!(0,u.isEmpty)((0,u.get)(F,"profile.accountInfo.facebookToken")),W=(0,u.get)(this.socialNetworkConnectionSubject.value,"status");!H&&W!==r.lA.Disconnected&&this.disconnect()})}getSocialNetworkUsers(m){return this.apollo.use("user").query({query:M,variables:{socialNetworkTypeId:r.Nq.OneAll,connectionToken:m}}).pipe((0,T.U)(p=>p.data.socialNetworkUsers),(0,y.K)(p=>(0,u.get)(p,"graphQLErrors[0].extensions.code")===`${e.O1.socialIdentityAccountExists}`?(0,D._)(409):(0,D._)(p)))}oneAllHandlerLogin(m){!(0,u.isNil)(this.socialConfigSetting)&&!(0,u.isNil)(m)&&this.getSocialNetworkUsers(m.connection.connection_token).pipe((0,a.P)(),(0,f.h)(p=>!(0,u.isNil)(p)),(0,T.U)(p=>(0,u.find)(p,{socialNetworkType:r.Nq.Facebook}))).subscribe(p=>{const O=this.constituentService.getConstituentFromStorage(),F=(0,u.get)(O,"profile");if((0,u.isNil)(F)||(this.constituentProfileBackup=(0,u.cloneDeep)(F)),this.isRegistrationFlow){const H=!O.importSubEventId;this.returningUserService.loadUserByFacebookId(p.socialUserId,H).pipe((0,a.P)()).subscribe(W=>{W.profile.accountInfo=W.profile.accountInfo||{},W.profile.accountInfo.isLoggedWithFacebook=H,this.returningUserService.mergeSocialNetworkUserWithConstituent(O,p),this.mergeFacebookLoginStatus(O,p),this.constituentService.maintainPurchaseItems(W),this.constituentService.saveConstituent(W),this.updateSocialNetworkConnection({status:r.lA.ConnectedAsReturningParticipant,displayName:p.displayName})},W=>{204===W?(this.returningUserService.mergeSocialNetworkUserWithConstituent(O,p),this.mergeFacebookLoginStatus(O,p),this.constituentService.saveConstituent(O),this.updateSocialNetworkConnection({status:r.lA.Connected,displayName:p.displayName})):this.handleOneAllHandlerLoginError(W,p.displayName)})}else this.returningUserService.mergeSocialNetworkUserWithConstituent(O,p),this.constituentService.saveConstituent(O),this.updateSocialNetworkConnection({status:r.lA.Connected,displayName:p.displayName})},p=>{this.handleOneAllHandlerLoginError(p)})}handleOneAllHandlerLoginError(m,p){409===m?this.updateSocialNetworkConnection({status:r.lA.InUseError,displayName:p}):console.error(`Unknown error: ${JSON.stringify(m)}`)}mergeFacebookLoginStatus(m,p){const O=p.socialUserId,F=p.token;m.profile=m.profile||{},m.profile.accountInfo=m.profile.accountInfo||{},m.profile.accountInfo.facebookId=O,m.profile.accountInfo.facebookToken=F}initOneAllScript(){if((0,u.isNil)(this.socialConfigSetting))return;const m=this.environmentService.getEnvironment().raisinEndpointUrl,p=this.rdd.organizationId,O=this.rdd.subEventPart,F=window,H=document.getElementsByTagName("head")[0],W=document.createElement("script");W.type="text/javascript",W.async=!0,W.src=`//${this.socialConfigSetting.subDomain}.api.oneall.com/socialize/library.js`,W.onload=tt=>{F.__oneall=F._oneall||[],F.__oneall.push(["social_login","set_providers",["facebook"]]),F.__oneall.push(["social_login","set_event","on_close_popup_ui",j=>this.oneAllHandlerLogin(j)]),F.__oneall.push(["social_login","set_event","on_login_end_success",j=>this.oneAllHandlerLogin(j)]),F.__oneall.push(["social_login","set_event","on_login_redirect",()=>!1]),F.__oneall.push(["social_login","set_callback_uri",`${m}/oneall?orgId=${p}&subEventPart=${O}`]),F.__oneall.push(["social_login","do_render_ui","oa_social_login_wrapper"])},H.appendChild(W)}disconnect(){const m=this.constituentService.getConstituentFromStorage();this.clearFacebookUserReturnedInfo(m),this.undoUpdateConstituent(m),this.clearFacebookInfo(m),this.constituentService.saveConstituent(m),this.updateSocialNetworkConnection({status:r.lA.Disconnected})}clearFacebookUserReturnedInfo(m){(0,u.get)(m,"profile.accountInfo.isLoggedWithFacebook",!1)&&(m.returningUserId=null,m.importSubEventId=null,m.profile.accountInfo.username="")}undoUpdateConstituent(m){this.constituentProfileBackup&&(m.profile=(0,u.cloneDeep)(this.constituentProfileBackup),m.profile.contactType=(0,u.get)(m,"profile.contactType",r.uC.Individual))}clearFacebookInfo(m){(0,u.isNil)((0,u.get)(m,"profile.accountInfo"))||(m.profile.accountInfo.facebookId=null,m.profile.accountInfo.facebookToken=null,m.profile.accountInfo.isLoggedWithFacebook=!1)}handleReturningParticipantLoginV3ParticipantCentre(){if(!this.rdd.useV3ParticipantCentre)return;const m=this.constituentService.getConstituentFromStorage();!(0,u.isNil)((0,u.get)(m,"profile.accountInfo.facebookToken"))&&(0,u.get)(m,"returningUserId",0)>0&&this.updateSocialNetworkConnection({status:r.lA.ConnectedAsReturningParticipant,displayName:`${m.profile.firstName} ${m.profile.lastName}`})}static#t=this.\u0275fac=function(p){return new(p||B)(S.LFG(L.n),S.LFG(v._M),S.LFG(s.V1),S.LFG(g.d),S.LFG(c.A),S.LFG(b.LG),S.LFG(A.V1),S.LFG(l.p),S.LFG(s.L$))};static#e=this.\u0275prov=S.Yz7({token:B,factory:B.\u0275fac,providedIn:"root"})}return B})()},24589:(Z,K,t)=>{"use strict";t.d(K,{h:()=>D});var s=t(6990),_=t(40424),n=t(89723),i=t(83960),P=t(65879);let D=(()=>{class I{constructor(a){this.constituentService=a,this.constituentService=a}removePurchaseItem(a,y){return(0,s.pullAt)(a.purchaseItems,[y]),a}removePurchaseItemByItemReference(a,y){return this.removePurchaseItem(a,(0,s.findIndex)(a.purchaseItems,y))}removeExcessConstituentPurchaseItems(a,y,f){if(f&&f>0){const r=this.constituentService.findPurchaseItemsByItemId(a,y);if(r)for(let u=f,C=r.length;u<C;u++)a=this.removeConstituentPurchaseItems(a,y,!1)}else a=this.removeConstituentPurchaseItems(a,y,!0);return a}removeConstituentPurchaseItems(a,y,f){return f?a.purchaseItems=(0,s.reject)(a.purchaseItems,{itemId:y}):a=this.removePurchaseItem(a,(0,s.findLastIndex)(a.purchaseItems,{itemId:y})),a}createConstituentItemFromItemData(a){switch(a?.itemTypeId){case n.qG.GeneralDonation:case n.qG.GeneralDonationMonthly:case n.qG.GeneralDonationQuarterly:case n.qG.GeneralDonationAnnual:case n.qG.InHonourDonation:case n.qG.InHonourDonationQuarterly:case n.qG.InHonourDonationAnnual:case n.qG.InHonourDonationMonthly:case n.qG.InMemoryDonation:case n.qG.InMemoryDonationMonthly:case n.qG.InMemoryDonationQuarterly:case n.qG.InMemoryDonationAnnual:return new i.YR(a);case n.qG.RegistrationFeeIndividual:return new i.sw(a);case n.qG.RegistrationFeeCaptain:return new i.zt(a);case n.qG.RegistrationFeeTeamMember:return new i.BR(a);case n.qG.RegistrationVolunteer:return new i.Xn(a);case n.qG.TicketingIndividualRegistration:return new i.tv(a);case n.qG.TicketingIndividualSponsorship:return new i.U0(a);case n.qG.TicketingGroupRegistration:return new i.i4(a);case n.qG.TicketingGroupSponsorship:return new i.Bm(a);case n.qG.StoreItem:return new i.gk(a);case n.qG.AdminFee:return new i.qo(a);default:throw new Error(`Unable to create item for unknown item type id: '${a?.itemTypeId}'`)}}static#t=this.\u0275fac=function(y){return new(y||I)(P.LFG(_.d))};static#e=this.\u0275prov=P.Yz7({token:I,factory:I.\u0275fac,providedIn:"root"})}return I})()},28742:(Z,K,t)=>{"use strict";t.d(K,{t:()=>T});var s=t(6990),_=t(72550),n=t(99397),i=t(37398),P=t(22096),D=t(65879),I=t(69862);let T=(()=>{class a{constructor(f,r){this.http=f,this.environmentService=r,this.subEventGroupData={}}handleSiteCleanup(){this.subEventGroupData={}}handleSiteConfig(f){this.subEventGroupData=(0,s.get)(f,"subEventGroupData")??{},this.subEventGroupData.subEventGroups=this.subEventGroupData.subEventGroups||[]}handlePageConfig(f){}getSubEventGroupsFromApi(){if(!(0,s.isEmpty)((0,s.get)(this.subEventGroupData,"subEventGroups")))return(0,P.of)(this.subEventGroupData);const f=`${this.environmentService.getEnvironment().raisinEndpointUrl}/config/site/`;return this.http.get(f).pipe((0,n.b)(r=>this.handleSiteConfig(r)),(0,i.U)(()=>this.subEventGroupData))}getSubEventGroupData(f){return this.filterSubEventGroupData(this.subEventGroupData,f)}getSubEventGroups(){return this.subEventGroupData.subEventGroups}getSubEventGroupById(f){return(0,s.find)(this.subEventGroupData.subEventGroups,{subEventGroupId:f})}hasTag(f,r){return!(0,s.isNil)(f)&&!(0,s.isEmpty)(r)&&!(0,s.isEmpty)(f.contentLang)&&!(0,s.isEmpty)(f.contentLang.tags)&&(0,s.findIndex)(f.contentLang.tags,u=>this.tagsEqual(u,r))>-1}tagsEqual(f,r){return!(0,s.isEmpty)(f)&&!(0,s.isEmpty)(r)&&(0,s.toLower)((0,s.trim)(f))===(0,s.toLower)((0,s.trim)(r))}filterSubEventGroupData(f,r){if(!(0,s.isNil)(r)){const u=(0,s.cloneDeep)(f);if((0,s.isEmpty)(r.tagFilter)||(u.subEventGroups=(0,s.filter)(u.subEventGroups,C=>this.hasTag(C,r.tagFilter)||!(0,s.isNil)(r.tagFilterIncludeSubEventGroupId)&&C.subEventGroupId===r.tagFilterIncludeSubEventGroupId)),r.excludeRegistrationEnded){const C=new Date,L=new Date(C.getFullYear(),C.getMonth(),C.getDate());u.subEventGroups=(0,s.filter)(u.subEventGroups,g=>{const c=(0,s.toString)((0,s.get)(g,"content.registrationEndDate"));return!(!(0,s.isEmpty)(c)&&"0001-01-01T00:00:00"!==c)||new Date(c)>=L})}return u}return f}static#t=this.\u0275fac=function(r){return new(r||a)(D.LFG(I.eN),D.LFG(_.L$))};static#e=this.\u0275prov=D.Yz7({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})()},80307:(Z,K,t)=>{"use strict";t.d(K,{d:()=>d});var s=t(89723),e=t(26028),_=t(61142),n=t(35297),i=t(21875),P=t(24589),D=t(329),I=t(6990),a=t(58504),y=t(22096),f=t(36232),r=t(37398),u=t(99397),C=t(26306),L=t(40424),g=t(65879),c=t(89515);const l=new _.Be;let d=(()=>{class A{constructor(v,b,M,R,B,E){this.raisinAPI=v,this.constituentService=b,this.translate=M,this.storageService=R,this.purchaseItemService=B,this.rdd=E}getCartId(){return this.storageService.getData("store")}setCartId(v){this.storageService.setData("store",v)}mapStore(v){const b=(0,I.size)(v?.items)>0?v.items.map(R=>this.mapStoreItem(R)):[],M={items:b,cartId:v.cartId,messageItemAvailableReachedFormat:"",messageItemMaxAllowedReached:"",messageItemMinAllowedReached:"",messageSoldOut:"",getItemMaxQuantityExceededMessage:R=>M.messageItemMaxAllowedReached.replace("{0}",R.quantityMaxAllowed.toString()),getItemMinQuantityNotMetMessage:R=>M.messageItemMinAllowedReached.replace("{0}",R.quantityMinAllowed.toString()),getItemAvailabilityExceededMessage:R=>M.messageItemAvailableReachedFormat.replace("{0}",(R.quantityOffered-R.quantitySold).toString()),calculateTotalDiscount:()=>{let R=0;for(const B of b)R+=this.getItemTotalDiscount(B);return R},calculateTotalPrice:()=>{let R=0;for(const B of b)R+=this.getItemTotalPrice(B);return R},totalQuantitySoldAndReserved:()=>{let R=0,B=0;for(let E=0;M.items&&E<M.items.length;E++)R+=b[E].quantitySold,B+=b[E].quantity;return R+B},totalTicketsSoldAndReserved:()=>{let R=0,B=0;for(let E=0;b&&E<b.length;E++)R+=b[E].quantitySold*b[E].numberOfTickets,B+=b[E].quantityReservedByOthers*b[E].numberOfTickets;return R+B},isAllSoldOut:()=>{const R=M.totalTicketsSoldAndReserved();return this.rdd.subEvent.maxParticipants-R<=0}};return M}mapStoreItem(v){const b={category:"Store",id:v.itemId,title:v.name,imageUrl:v.imageUrl,quantity:this.parseQuantity(v.quantityReservedByMe,0),price:v.price,description:v.description,displayOrder:v.displayOrder,numberOfTickets:this.parseQuantity(v.numberOfTickets,0),appliedPromoCode:null,quantityOffered:this.parseQuantity(v.quantityOffered,e.z1.UnlimitedItemQuantity),quantitySold:this.parseQuantity(v.quantitySold,0),quantityMaxAllowed:this.parseQuantity(v.quantityMaxAllowed,e.z1.UnlimitedItemQuantity),quantityMinAllowed:this.parseQuantity(v.quantityMinAllowed,0),quantityReservedByOthers:this.parseQuantity(v.quantityReservedByOthers,0),isCartView:v.isCartView,getItemTotalPrice:()=>this.getItemTotalPrice(b),getItemTotalDiscount:()=>this.getItemTotalDiscount(b),getMaxQuantityAvailable:()=>this.getMaxQuantityAvailable(b),isSoldOut:()=>this.isSoldOut(b),isSoldOutIncludingReservedByMe:()=>this.isSoldOutIncludingReservedByMe(b),isMaxQuantityExceeded:()=>this.isMaxQuantityExceeded(b),isMinQuantityNotMet:()=>this.isMinQuantityNotMet(b),isQuantityAvailabilityExceeded:()=>this.isQuantityAvailabilityExceeded(b),hasUnlimitedQuantityAvailable:()=>this.hasUnlimitedQuantityAvailable(b)};return b}getStore(v,b){return(!b||0===b.toString().trim().length)&&(b=l.Angular.Utils.newGuid()),this.raisinAPI.Store.get({moduleId:v,cartId:b}).pipe((0,r.U)(M=>this.mapStore(M)),(0,u.b)(M=>{M.messageItemAvailableReachedFormat=this.translate.instant("err_ItemAvailableReached"),M.messageItemMaxAllowedReached=this.translate.instant("err_ItemMaxAllowedReached"),M.messageItemMinAllowedReached=this.translate.instant("err_ItemMinAllowedReached"),M.messageSoldOut=this.translate.instant("lbl_SoldOut")}),(0,r.U)(M=>{if((0,I.size)(M?.items)>0){const B=this.constituentService.getConstituentFromStorage();(0,I.forEach)(B.purchaseItems,E=>{this.isPurchaseItemStoreItem(E)&&(0,I.forEach)(M?.items,m=>{m.id===E.itemId&&(m.appliedPromoCode=E.promoCode)})}),this.constituentService.saveConstituent(B)}return M}),(0,C.K)(M=>(0,a._)(M)))}saveStore(v){return this.reserveStoreItems(v).pipe((0,r.U)(()=>{const b=this.constituentService.getConstituentFromStorage();return this.removeAllConstituentStorepurchaseItems(b),(0,I.forEach)(v.items,M=>{if(M.quantity>0){const R=this.constituentService.addNewStoreCartItem(b);(0,I.set)(R,"sessionId",v.cartId),(0,I.set)(R,"itemId",M.id),(0,I.set)(R,"type",s.qG.StoreItem),(0,I.set)(R,"quantity",M.quantity),(0,I.set)(R,"promoCode",M.appliedPromoCode),(0,I.set)(R,"price",M.price),(0,I.set)(R,"title",M.title)}}),this.constituentService.saveConstituent(b),!0}),(0,C.K)(b=>(0,a._)(b)))}currentTotal(v){let b=0;return v&&v.items&&v.items.length>0&&v.items.map(M=>{M.quantity>0&&(b+=M.price-(M.appliedPromoCode?M.appliedPromoCode.discount:0))}),b}reserveStoreItems(v){if(v.items&&v.items.length>0){const b=v.items.map(M=>({sessionId:v.cartId,itemId:M.id,itemTypeId:s.qG.StoreItem,quantity:M.quantity,unitPrice:M.price-(M.appliedPromoCode?M.appliedPromoCode.discount:0),numberOfTickets:0}));return this.raisinAPI.Store.post({cartId:v.cartId},{},b)}return(0,y.of)({})}removeAllConstituentStorepurchaseItems(v){for(let b=0;b<v.purchaseItems.length;b++){const M=v.purchaseItems[b];this.isPurchaseItemStoreItem(M)&&M.type!==s.qG.GeneralDonation&&(v=this.purchaseItemService.removePurchaseItem(v,b),b--)}}getPromoCodes(v){return this.raisinAPI.PromoCode.get({},{code:v}).pipe((0,r.U)(b=>{const M=[];return(0,I.isNil)(b)||(0,I.forEach)(b,R=>{M.push({id:R.id,code:R.code,discount:R.discount,description:R.description,itemIds:R.items})}),M}),(0,C.K)(b=>(0,a._)(b)))}getMaxDiscountPromoCode(v){return this.getPromoCodes(v).pipe((0,r.U)(b=>b.length>0?(0,I.orderBy)(b,["discount"],["desc"])[0]:null),(0,C.K)(b=>(0,a._)(b)))}getItemTotalPrice(v){let b=v.quantity>0?v.price*v.quantity:0;if(b>0&&v.appliedPromoCode){const M=v.quantity*v.appliedPromoCode.discount;b=M<=b?b-M:0}return b}getItemTotalDiscount(v){let b=0;if(v.appliedPromoCode){const M=v.quantity>0?v.price*v.quantity:0;if(M>0){const R=v.appliedPromoCode.discount*v.quantity;b=R<=M?R:M}}return b}getMaxQuantityAvailable(v){if(v.quantityOffered!==e.z1.UnlimitedItemQuantity){let b=v.quantityOffered-(v.quantitySold+v.quantityReservedByOthers);return b=b>0?b:0,v.quantityMaxAllowed!==e.z1.UnlimitedItemQuantity?Math.min(b,v.quantityMaxAllowed):b}return v.quantityMaxAllowed}isSoldOut(v){return v.quantityOffered!==e.z1.UnlimitedItemQuantity&&v.quantityOffered<=v.quantitySold+v.quantityReservedByOthers}isSoldOutIncludingReservedByMe(v){return v.quantityOffered!==e.z1.UnlimitedItemQuantity&&v.quantityOffered<=v.quantitySold+v.quantityReservedByOthers+v.quantity}isMaxQuantityExceeded(v){return v.quantityMaxAllowed!==e.z1.UnlimitedItemQuantity&&v.quantity>v.quantityMaxAllowed}isMinQuantityNotMet(v){return 0!==v.quantityMinAllowed&&v.quantity<v.quantityMinAllowed}isQuantityAvailabilityExceeded(v){return v.quantityOffered!==e.z1.UnlimitedItemQuantity&&v.quantityOffered<v.quantitySold+v.quantityReservedByOthers+v.quantity}hasUnlimitedQuantityAvailable(v){return v.getMaxQuantityAvailable()===e.z1.UnlimitedItemQuantity}isPurchaseItemStoreItem(v){return[s.qG.GeneralDonation,s.qG.StoreItem,s.qG.TicketingIndividualRegistration,s.qG.TicketingIndividualSponsorship,s.qG.TicketingGroupRegistration,s.qG.TicketingGroupSponsorship,s.qG.PledgeItem].filter(b=>b===v.type).length>0}applyPromoCode(v,b){return this.getMaxDiscountPromoCode(b).pipe((0,r.U)(M=>(null!==M&&null!==M.itemIds&&((0,I.map)(v.items,R=>{(0,I.includes)(M.itemIds,R.id)&&(null===R.appliedPromoCode||R.appliedPromoCode.discount<M.discount)&&(R.appliedPromoCode=M)}),this.applyPromoCodeToExistingItems(M,v.items)),M)),(0,C.K)(M=>(0,a._)(M)))}applyPromoCodeToExistingItems(v,b){const M=this.constituentService.getConstituentFromStorage(),R=(0,I.get)(v,"itemIds",[]),B=(0,I.map)(b,"id"),E=(0,I.get)(M,"purchaseItems",[]).filter(m=>B.includes(m.itemId)&&R.includes(m.itemId));for(const m of E)(0,I.set)(m,"promoCode",v);E.length&&this.constituentService.saveConstituent(M)}parseQuantity(v,b){return(0,I.isNumber)(v)&&isFinite(+v)?+v:b}clearCart(){const v=this.getCartId();return(0,I.isEmpty)(v)?f.E:this.raisinAPI.ClearCart.post({cartId:v},null,null)}static#t=this.\u0275fac=function(b){return new(b||A)(g.LFG(n.O),g.LFG(L.d),g.LFG(c.sK),g.LFG(i.V1),g.LFG(P.h),g.LFG(D.n))};static#e=this.\u0275prov=g.Yz7({token:A,factory:A.\u0275fac,providedIn:"root"})}return A})()},89365:(Z,K,t)=>{"use strict";t.d(K,{H:()=>r});var s=t(89723),e=t(329),_=t(35297),n=t(6990),P=t(65619),D=t(22096),I=t(26028),T=t(40424),a=t(91221),y=t(99397),f=t(65879);let r=(()=>{class C{constructor(g,c,l,d){this.rdd=g,this.consituentService=c,this.raisinAPI=l,this.formService=d,this.AttendeeSubject=new P.X(null),this.fields=[],this.validateAttendeeSubject=new P.X(null),this.blankAttendee=(0,n.cloneDeep)(I.gM),this.blankAttendee.interfaceLanguage=this.blankAttendee.correspondanceLanguage=this.rdd.languageId,this.doNotCopyConstituentProfileFields=["userId","username","password","confirmPassword","customField1","customField2","customField3","customField4","customField5","receiveCommunications","allowDistributionOfDetails","privacy"],this.attendees=[]}attendeeToValidate(){return this.validateAttendeeSubject.asObservable()}pushAttendeeToValidate(g){this.validateAttendeeSubject.next(g)}setComponentInterface(g){this.isPc=g}loadPurchaseItemsAttendees(){return this.raisinAPI.Attendees.get()}initPurchaseItemsAttendees(g){if(g){this.isPc&&(this.pcPurchseItems=g);for(let c=0;c<g.length;c++){const l=g[c];if(this.isTicketedPurchaseItem(l)){const d=this.getPurchaseItemNumberOfTickets(l);if(0!==d&&this.rdd.subEvent.isAttendeeInfoRequired){const S=this.getPurchaseItemAttendeeCollection(l)||[],v=[];for(let b=0;b<d;b++)S[b]&&(S[b].receiveCommunications=!!S[b].receiveCommunications,S[b].allowDistributionOfDetails=!!S[b].allowDistributionOfDetails,S[b].privacy=!!S[b].privacy,v.push(S[b]));l.attendees=v}else l.attendees=[]}}}}filterTicketedPurchaseItems(g){return(g||[]).filter(c=>c&&this.isTicketedPurchaseItem(c)&&this.getPurchaseItemNumberOfTickets(c)>0)}getPurchaseItemNumberOfTickets(g){let c=0;return g&&g.hasOwnProperty("numberOfTickets")&&(c=(0,n.isNumber)(g.numberOfTickets)&&isFinite(g.numberOfTickets)?(0,n.toNumber)(g.numberOfTickets):0),c}isTicketedPurchaseItem(g){if(g&&g.hasOwnProperty("type")){const c=g.type;return c===s.qG.TicketingIndividualRegistration||c===s.qG.TicketingIndividualSponsorship||c===s.qG.TicketingGroupRegistration||c===s.qG.TicketingGroupSponsorship}return!1}getPurchaseItemAttendeeCollection(g){return g&&g.hasOwnProperty("attendees")?g.attendees:null}create(g){this.constituent=this.consituentService.getConstituentFromStorage(),this.attendees=g,this.AttendeeSubject.next(this.attendees)}update(g){if(this.attendees[g.currentTicketIndex][g.currentAttendeeIndex].attendee=g.attendee,!this.isPc){const l=this.filterTicketedPurchaseItems(this.constituent.purchaseItems)[g.currentTicketIndex];(0,n.isNil)(l.attendees)&&(l.attendees=[],l.attendees.push((0,n.range)(l.numberOfTickets))),l.attendees[g.currentAttendeeIndex]=g.attendee}}save(){this.consituentService.saveConstituent(this.constituent)}getAll(){return this.AttendeeSubject.asObservable()}clearAll(){this.attendees=null,this.AttendeeSubject.next(this.attendees)}copyContsituentProfileToAttendee(g,c){if(g&&c){for(const l in g)g.hasOwnProperty(l)&&this.blankAttendee.hasOwnProperty(l)&&-1===this.doNotCopyConstituentProfileFields.indexOf(l)&&!(0,n.isNil)(g[l])&&null!=g[l]&&(c.attendee[l]=g[l]);c.isValid=!0}this.update(c)}fillConstituentPropertiesToAttendees(g,c,l){if(g&&c){const d=(0,n.flatMap)(c,A=>A);for(const A of d){for(const S of l)(0,n.has)(g,S)&&(0,n.has)(this.blankAttendee,S)&&(0,n.isNil)((0,n.get)(A.attendee,S))&&(0,n.set)(A.attendee,S,(0,n.get)(g,S));this.update(A)}}}bulkAtendeesUpdate(){return console.log(this.pcPurchseItems),(0,n.map)(this.attendees,g=>{(0,n.map)(g,c=>{this.pcPurchseItems[c.currentTicketIndex].attendees[c.currentAttendeeIndex]=c.attendee})}),this.raisinAPI.Attendees.put({},{},this.pcPurchseItems)}isAttendeeInfoRequired(){return this.rdd.subEvent.isAttendeeInfoRequired}attendeeHasRequiredFields(){return this.fields.length>0&&this.formService.isAnyFormInputRequired(this.fields)}getAttendeeFields(){return this.fields.length>0?(0,D.of)(this.fields):this.formService.getFormInputs(s.uy.Attendee).pipe((0,y.b)(g=>this.fields=g))}checkHasMissingFields(g,c=!1){if(0===(0,n.size)(g)||c&&!this.attendeeHasRequiredFields())return!1;const l=(0,n.sumBy)(g,"numberOfTickets");if(0===l)return!1;const d=[];if(g.forEach(b=>{(0,n.has)(b,"attendees")&&d.push(b)}),l>(0,n.sumBy)(g,b=>(0,n.has)(b,"attendees")?b.attendees.length:0))return!0;const S=(0,n.flatten)(d.map(b=>b.attendees)),v=(0,n.map)(S,b=>this.attendeeHasMissingFields(b,c));return(0,n.some)(v,b=>b)}attendeeHasMissingFields(g,c=!1){if(!this.fields.length||!g)return!1;const l=(0,n.cloneDeep)(g),A=(0,n.filter)(this.fields,M=>(M=>!c||M.required)(M)),S=(0,n.get)(l,"address",{});delete l.address;const v={...l,...S},b=(0,n.map)(A,M=>{const R=this.getMappedFieldValue(v,M.name);return!!(0,n.isNil)(R)||((0,n.isBoolean)(R)?!R:!(0,n.isNumber)(R)&&(0,n.isEmpty)(R))});return(0,n.reduce)(b,(M,R)=>M||R,!1)}getMappedFieldValue(g,c){const l=u[c];return l?c=l:(0,n.startsWith)(c,"attribute")&&(c=c.replace("attribute","customField")),(0,n.has)(g,c)?g[c]:(console.error(`Unabled to find field '${c}' on attendee object`),null)}static#t=this.\u0275fac=function(c){return new(c||C)(f.LFG(e.n),f.LFG(T.d),f.LFG(_.O),f.LFG(a._))};static#e=this.\u0275prov=f.Yz7({token:C,factory:C.\u0275fac,providedIn:"root"})}return C})(),u=(()=>{class C{static#t=this.country="countryId";static#e=this.province="regionId";static#i=this.addressLine1="line1";static#n=this.addressLine2="line2";static#s=this.companyName="organization";static#r=this.optOut="receiveCommunications";static#o=this.optOutToShare="allowDistributionOfDetails";static#a=this.userType="contactType"}return C})()},91356:(Z,K,t)=>{"use strict";t.d(K,{T:()=>f});var s=t(6990),_=t(4870),n=t(72550),i=t(329),P=t(22096),D=t(61142),I=t(89723),T=t(21875),a=t(65879);const y=new D.Be;let f=(()=>{class r{constructor(C,L,g,c){this.rdd=C,this.legacyLanguageService=L,this.newLanguageService=g,this.storageService=c}handleSiteCleanup(){return this.legacyLanguageService.handleSiteCleanup()}handleSiteConfig(C){this.setLanguageId(C.interfaceLanguage),this.newLanguageService.configure(C.languages),this.newLanguageService.setInterfaceLanguage(C.interfaceLanguage)}setLanguageId(C){for(const L in I.SQ)if(I.SQ.hasOwnProperty(L)&&L.replace("_","-")===C)return this.rdd.set("LanguageId",+I.SQ[L]),void this.storageService.setData("languageId",+I.SQ[L]);this.rdd.set("LanguageId",I.SQ.en_CA),this.storageService.setData("languageId",I.SQ.en_CA)}getAppLanguage(){return this.rdd.useV3ParticipantCentre?this.legacyLanguageService.getAppLanguage():this.newLanguageService.getInterfaceLanguage()}localize(C,L=null){const g=this.newLanguageService.instant(C);return(0,s.isNil)(L)?(0,P.of)(g).toPromise():(0,P.of)(y.Angular.Utils.stringFormat(g,L)).toPromise()}getLongMonthNameForLocale(C,L){return this.legacyLanguageService.getLongMonthNameForLocale(C,L)}getGoogleReCaptchaLanguageCodeForCurrentLanguage(){return this.legacyLanguageService.getGoogleReCaptchaLanguageCodeForCurrentLanguage()}static#t=this.\u0275fac=function(L){return new(L||r)(a.LFG(i.n),a.LFG(_.G),a.LFG(n.TS),a.LFG(T.V1))};static#e=this.\u0275prov=a.Yz7({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})()},4870:(Z,K,t)=>{"use strict";t.d(K,{G:()=>g});var s=t(89723),e=t(26028),_=t(329),n=t(96814),i=t(22096),P=t(58504),D=t(37398),I=t(26306),T=t(6990),y=t(72550),f=t(21875),r=t(61142),u=t(65879),C=t(69862);const L=new r.Be;let g=(()=>{class c{constructor(d,A,S,v,b,M){this.rdd=d,this.environmentService=A,this.cookieService=S,this.storageService=v,this.http=b,this.document=M,this.isFetchingTranslations=!1,this.waiting=[],this.availableLanguagesShort=[],this.availableCultures=[],this.translationsCache=new Map}getCacheKey(d){const A=d.data,S=d.args;let v=A[d.key]||d.key;if(S)if((0,T.isArray)(S)){for(let b=0;b<S.length;b++)S[b]=A[S[b]]||S[b];v=L.Angular.Utils.stringFormat(v,S)}else v=L.Angular.Utils.stringFormat(v,[A[S]||S]);return v}handleSiteCleanup(){this.isFetchingTranslations=!1,this.waiting=[],this.availableLanguagesShort=[],this.availableCultures=[]}getRaisinStrings(d,A=null){return this.isFetchingTranslations=!0,this.http.get(`${this.environmentService.getEnvironment().raisinEndpointUrl}/resources/localize/${d}`).pipe((0,D.U)(S=>(this.translationsCache.set(d,S),this.isFetchingTranslations=!1,(0,i.of)({data:S,args:A}))),(0,I.K)(S=>(0,P._)(S)))}handleSiteConfig(d){const A=d&&d.languages?d.languages:[];A&&(this.rdd.languages=A);for(let S=0,v=A.length;S<v;S++){const b=A[S];(b.culture===this.rdd.culture||b.shortName===this.rdd.culture||b.culture===this.cookieService.getCurrentCulture())&&(this.rdd.set("LanguageId",b.languageId),this.storageService.setData("languageId",b.languageId),this.cookieService.setCurrentCulture(b.culture)),this.availableLanguagesShort.push(b.shortName),this.availableCultures.push(b.culture)}this.updateRaisinDD(),this.getRaisinStrings(this.rdd.languageId).subscribe()}handlePageConfig(){this.updateRaisinDD()}localize(d,A=null){this.rdd.languageId||this.updateRaisinDD();const S=this.translationsCache.get(this.rdd.languageId)||null;return null==S?this.getRaisinStrings(this.rdd.languageId,A).pipe((0,D.U)(v=>this.getCacheKey({data:v.data,key:d,args:A}))):(0,i.of)(this.getCacheKey({data:S,key:d,args:A}))}getAppLanguage(){let d=this.rdd.culture;return(0,T.isArray)(d)&&(d=d[0]),d||""}getLanguageId(){let d=this.getAppLanguage()||"";(0,T.includes)(d,"-")&&(d=d.replace("-","_"));for(const A in s.SQ)if(s.SQ.hasOwnProperty(A)&&A===d)return+s.SQ[A];return s.SQ.en_CA}updateRaisinDD(){if(!this.rdd.languageId){const d=this.getAppLanguage(),A=this.getLanguageId();this.rdd.set("LanguageId",A),this.storageService.setData("languageId",A),this.cookieService.setCurrentCulture(d)}}getLongMonthNameForLocale(d,A){d=d||this.getAppLanguage()||"en-CA";const S=e.z1.MonthNamesLong;return(S[d]||S["en-CA"])[A]}getGoogleReCaptchaLanguageCodeForCurrentLanguage(){return this.getGoogleReCaptchaLanguageCode(this.getLanguageId())}getGoogleReCaptchaLanguageCode(d){let A="en";return d===s.SQ.fr_CA?A="fr-CA":d===s.SQ.es_ES?A="es":d===s.SQ.de_CH&&(A="de"),A}loadGlobalizeCultureSpecificScripts(d){if(d)for(let A=0,S=d.length;A<S;A++){const v=d[A];if("en-US"===v.culture)continue;const b=`/SharedImages/Mobile/js/libs/globalize/cultures/globalize.culture.${v.culture}.js`,M=this.document.createElement("script");M.type="text/javascript",M.async=!0,M.src=b;const R=this.document.getElementsByTagName("script")[0];R.parentNode.insertBefore(M,R)}}static#t=this.\u0275fac=function(A){return new(A||c)(u.LFG(_.n),u.LFG(y.L$),u.LFG(f.x9),u.LFG(f.V1),u.LFG(C.eN),u.LFG(n.K0))};static#e=this.\u0275prov=u.Yz7({token:c,factory:c.\u0275fac,providedIn:"root"})}return c})()},77892:(Z,K,t)=>{"use strict";t.d(K,{Q:()=>M});var s=t(96814),e=t(38257),_=t(49488),n=t(38034),i=t(26385),P=t(3305),D=t(30617),I=t(73445),T=t(23680),a=t(71657),y=t(42741),f=t(74104),r=t(2032),u=t(64170),C=t(75986),L=t(92596),g=t(32296),c=t(98525),l=t(87466),d=t(55940),A=t(24630),S=t(17700),v=t(95195),b=t(65879);let M=(()=>{class R{static#t=this.\u0275fac=function(m){return new(m||R)};static#e=this.\u0275mod=b.oAB({type:R});static#i=this.\u0275inj=b.cJS({providers:[{provide:T._A,useClass:I.t7},{provide:T.sG,useValue:I.$o}],imports:[s.ez,e.T5,f.Nh,_.vV,r.c,u.lN,C.p9,L.AV,g.ot,c.LD,n.FA,l.Fk,v.QW,D.Ps,a.U5,d.Cq,i.t,A.Bb,S.Is,y.Cl,c.LD,a.U5,e.T5,f.Nh,_.vV,r.c,u.lN,C.p9,L.AV,g.ot,c.LD,n.FA,l.Fk,v.QW,D.Ps,d.Cq,i.t,A.Bb,S.Is,P.To,y.Cl]})}return R})()},26431:(Z,K,t)=>{"use strict";t.d(K,{T:()=>s});class s{constructor(_,n,i){this.pageContentService=_,this.notificationService=n,this.flowPageNavigatorService=i}getPageContent(_){return this.pageContentService.getContent(_)}previousStep(){this.flowPageNavigatorService.previousStep()}nextStep(){this.flowPageNavigatorService.nextStep()}}},18054:(Z,K,t)=>{"use strict";t.d(K,{N:()=>s});const s={production:!0,apiDonationUrl:"https://donations.dm.akaraisin.com/graphql",apiContentUrl:"https://content.dm.akaraisin.com/graphql",apiUserUrl:"https://user.dm.akaraisin.com/graphql",apiEmailUrl:"https://email.dm.akaraisin.com/graphql",apiContactUrl:"https://contact.dm.akaraisin.com/graphql",apiTeamUrl:"https://team.dm.akaraisin.com/graphql",apiQueueUrl:"https://queue.dm.akaraisin.com/graphql",apiUserNotificationUrl:"https://usernotification.dm.akaraisin.com/graphql",apiStatisticsUrl:"https://statistics.dm.akaraisin.com/",claimsUrl:"https://security.dm.akaraisin.com/api/authentication",anonymousClaimsUrl:"https://security.dm.akaraisin.com/api/authentication",regenerateClaimsUrl:"https://security.dm.akaraisin.com/api/authentication/refresh",baseUrl:"",raisinEndpointUrl:"https://api.akaraisin.com/v2",raisinApiV1:"https://api.akaraisin.com/v1",claimsV2ApiUrl:"https://auth.akaraisin.com/assets/claim/{subEvent}/",eventUrl:"{subEvent}",pageSize:100}},77362:(Z,K,t)=>{"use strict";var s=t(6593),e=t(65879),_=t(96814),n=t(56123),i=t(90349),P=t(89515),D=t(18054),I=t(69862),T=t(72550),a=t(35061),y=t(73814),f=t(50768),r=t(6990),u=t(22096);let C=(()=>{class N{constructor(){this.preloadedModules=[]}preload(h,U){if(h.data&&h.data.preload){const w=(0,r.isNil)(h.path)?h?.data?.name:h.path;return this.preloadedModules.push(w),console.debug("Preloaded: "+w),U()}return(0,u.of)(null)}static#t=this.\u0275fac=function(U){return new(U||N)};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();var L=t(89723),g=t(13423),c=t(32181),l=t(99397),d=t(94664),A=t(37398),S=t(80762),v=t(83779),b=t(92841);let M=(()=>{class N{constructor(h,U,w,J){this.authService=h,this.oneAllConfigurationService=U,this.raisinRouter=w,this.router=J}canActivate(h,U){const w=(0,r.cloneDeep)(h.params);return this.oneAllConfigurationService.canProcessConnectionToken(w)?this.raisinRouter.pipe((0,g.Ys)(b.sf),(0,c.h)(J=>!(0,r.isNil)(J)),(0,l.b)(J=>{w.subEventCustomPart=J.params.subEventCustomPart}),(0,d.w)(()=>this.oneAllConfigurationService.processCallback(w)),(0,A.U)(J=>this.router.createUrlTree(J))):(0,u.of)(!1)}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(S.$),e.LFG(v.O),e.LFG(g.yh),e.LFG(f.F0))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();var R=t(59773),B=t(27921),E=t(78645),m=t(329),p=t(52044),O=t(36446),F=t(82359),H=t(26431),W=t(8891),tt=t(40374),j=t(87181),z=t(79344),q=t(47812);let at=(()=>{class N extends H.T{constructor(h,U,w,J,it,pt,Ct,St,At){super(U,w,J),this.loader=h,this.pageContentService=U,this.notificationService=w,this.flowPageNavigatorService=J,this.rdd=it,this.router=pt,this.googleAnalytics=Ct,this.validationService=St,this.googleReCaptchaService=At,this.loadingClass="page-loading",this.eventCssClass=""}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}ngOnInit(){this.ariaLiveAttribute$=this.getAriaLiveAttribute(),this.destroy$=new E.x,this.eventCssClass=this.getEventCSSClass(),this.router.events.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h instanceof f.m2),(0,d.w)(()=>this.googleReCaptchaService.reset())).subscribe(()=>{this.validationService.stateChangeSuccessHandler()}),this.loader.value$.pipe((0,R.R)(this.destroy$),(0,c.h)(r.isEmpty)).subscribe(h=>this.loadingClass="page-loaded")}getSiteConfigError(){return this.rdd.get("error")||null}getEventCSSClass(){if(!(0,r.isNil)((0,r.get)(this.rdd,"subEvent.eventTypeId",null)))switch(this.rdd.subEvent.eventTypeId){case 10:return"ticketing";case 3:case 9:return"pledge";default:return""}return""}getAriaLiveAttribute(){return this.router.events.pipe((0,c.h)(h=>h instanceof f.OD),(0,A.U)(h=>["/transaction/failed","/success","/successful"].some(w=>h.url.endsWith(w))?"polite":"off"),(0,B.O)("off"))}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(z.dL),e.Y36(F.Z),e.Y36(p.g),e.Y36(O.P),e.Y36(m.n),e.Y36(f.F0),e.Y36(tt.Wf),e.Y36(W.R),e.Y36(j.gY))};static#e=this.\u0275cmp=e.Xpm({type:N,selectors:[["rx-base-page"]],hostVars:2,hostBindings:function(U,w){2&U&&e.Tol(w.loadingClass)},features:[e.qOj],decls:5,vars:5,consts:[[1,"container-fluid","no-padding-side","pull-left","full",3,"regionId"],[1,"container-fluid","no-padding-side","pull-left",3,"regionId"],["name","entity"]],template:function(U,w){1&U&&(e._UZ(0,"rx-page-content",0),e.ALo(1,"async"),e._UZ(2,"router-outlet")(3,"rx-page-content",1)(4,"router-outlet",2)),2&U&&(e.Q6J("regionId",2e4),e.uIk("aria-live",e.lcZ(1,3,w.ariaLiveAttribute$)),e.xp6(3),e.Q6J("regionId",3e4))},dependencies:[f.lC,q.Y,_.Ov],encapsulation:2})}return N})(),nt=(()=>{class N{constructor(h){this.authService=h}canActivate(h,U){return"true"!==(0,r.lowerCase)((0,r.get)(h.queryParams,"logout","false"))||this.authService.logout()}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(S.$))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();var et=t(48180),o=t(26306),mt=t(58504),ft=t(26028),G=t(44057),vt=t(40424),rt=t(7019),Y=t(21875),gt=t(33676),ct=t(95195),ot=t(32296);let _t=(()=>{class N{constructor(){this.cssClass=!0,this.registerClicked=new e.vpe}ngOnInit(){}onRegisterClicked(){this.registerClicked.emit()}static#t=this.\u0275fac=function(U){return new(U||N)};static#e=this.\u0275cmp=e.Xpm({type:N,selectors:[["rs-welcome-back"]],hostVars:2,hostBindings:function(U,w){2&U&&e.ekj("welcome-back",w.cssClass)},inputs:{displayName:"displayName"},outputs:{registerClicked:"registerClicked"},decls:14,vars:13,consts:[["appearance","outlined",1,"welcome-back-panel"],["mat-card-title","",1,"welcome-back-panel__heading",3,"innerHTML"],[1,"welcome-back-panel__actions"],["mat-flat-button","","color","primary",1,"login",3,"click"]],template:function(U,w){1&U&&(e.TgZ(0,"mat-card",0),e._UZ(1,"h1",1),e.ALo(2,"translate"),e.TgZ(3,"mat-card-content")(4,"b"),e._uU(5),e.ALo(6,"translate"),e.qZA(),e.TgZ(7,"p"),e._uU(8),e.ALo(9,"translate"),e.qZA()(),e.TgZ(10,"mat-card-actions",2)(11,"button",3),e.NdJ("click",function(){return w.onRegisterClicked()}),e._uU(12),e.ALo(13,"translate"),e.qZA()()()),2&U&&(e.xp6(1),e.Q6J("innerHTML",e.lcZ(2,5,"lblGetStarted"),e.oJD),e.xp6(4),e.AsE("",e.lcZ(6,7,"lblWelcomeBack")," ",w.displayName,"!"),e.xp6(3),e.Oqu(e.lcZ(9,9,"msgWelcomeBack")),e.xp6(4),e.Oqu(e.lcZ(13,11,"txtRegister")))},dependencies:[ct.a8,ct.hq,ct.dn,ct.n5,ot.lW,P.X$],styles:['.accessibly-hide{position:absolute!important;height:1px;width:1px;overflow:hidden;clip:rect(1px,1px,1px,1px)}button[disabled],button.disabled{cursor:not-allowed!important}[mat-flat-button].btn-action{padding:0 30px;border-radius:20px!important;box-sizing:border-box;border:1px solid transparent;letter-spacing:normal;background-color:#61a220;color:#fff}[mat-flat-button].btn-action:disabled:hover{cursor:not-allowed}[mat-flat-button].btn-action:enabled:hover{background-color:#db3a00}[mat-flat-button].btn-primary{padding:0 30px;border-radius:20px!important;box-sizing:border-box;border:1px solid transparent;letter-spacing:normal;background-color:#1975d2!important;color:#fff!important}[mat-flat-button].btn-primary:disabled:hover{cursor:not-allowed}[mat-flat-button].btn-alt{padding:0 30px;border-radius:20px!important;box-sizing:border-box;border:1px solid transparent;letter-spacing:normal;background-color:#fff;border-color:#61a220;color:#264d58}[mat-flat-button].btn-alt:disabled:hover{cursor:not-allowed}[mat-flat-button].btn-alt:enabled:hover{border:1px solid #db3a00}.is-mobile .hide-mobile,.is-desktop .hide-desktop,.is-tablet .hide-tablet,.is-phablet .hide-phablet{display:none!important}.cursor-pointer,.text-button{cursor:pointer}.text-button{font-family:Roboto,sans-serif;font-size:16px;font-size:1.6rem;color:#1975d2;border:none;border-radius:0!important;background:none;padding:0!important;min-width:0!important;text-decoration:underline;margin:0}.text-button--chevron:after{content:">";display:inline-block;padding:0 2px}.mdc-dialog .mdc-dialog__content{color:#000000de}.mdc-dialog__title:before{display:none}mat-card-title.base-header h2,.mat-mdc-card-title.base-header h2{padding-bottom:12px;margin:0 0 12px;border-bottom:2px solid #d5d5d5;line-height:22px}mat-card-title.icons-header,.mat-mdc-card-title.icons-header{display:flex;justify-content:space-between;align-items:center;margin:0 0 12px;padding-bottom:12px;border-bottom:2px solid #d5d5d5}mat-card-title.icons-header h2,.mat-mdc-card-title.icons-header h2{flex:1 1 auto;margin:0;line-height:22px}mat-card-title.icons-header mat-icon,.mat-mdc-card-title.icons-header mat-icon{flex:0 0 auto;margin-left:10px;height:22px;line-height:22px}.welcome-back-panel{width:100%;max-width:300px;padding:25px 25px 30px}.is-mobile .welcome-back-panel{max-width:none}.welcome-back-panel__heading{font-size:13;font-size:1.3rem;line-height:13;line-height:1.3rem;font-weight:700;padding-bottom:18px;border-bottom:1px solid #bababa;margin-bottom:30px}.welcome-back-panel__actions.mat-mdc-card-actions{margin-left:0;padding-top:0}.welcome-back-panel__actions button.mat-mdc-unelevated-button.mat-primary{padding:0 30px;border-radius:20px!important;box-sizing:border-box;border:1px solid transparent;letter-spacing:normal;background-color:#61a220;color:#fff}.welcome-back-panel__actions button.mat-mdc-unelevated-button.mat-primary:disabled:hover{cursor:not-allowed}.welcome-back-panel__actions button.mat-mdc-unelevated-button.mat-primary:enabled:hover{background-color:#db3a00}.welcome-back-panel .mat-mdc-card-content{font-size:10;font-size:1rem;line-height:14;line-height:1.4rem;font-weight:400}\n'],encapsulation:2})}return N})();var V=t(55940);function st(N,ht){if(1&N){const h=e.EpF();e.TgZ(0,"rs-login",4),e.NdJ("closeClicked",function(){e.CHM(h);const w=e.oxw();return e.KtG(w.closeClicked())})("loginClicked",function(w){e.CHM(h);const J=e.oxw();return e.KtG(J.login(w))})("socialClicked",function(w){e.CHM(h);const J=e.oxw();return e.KtG(J.socialLogin(w))}),e.qZA()}if(2&N){const h=e.oxw();e.Q6J("errorMessage",h.errorMessage)}}function dt(N,ht){if(1&N){const h=e.EpF();e.TgZ(0,"rs-welcome-back",5),e.NdJ("registerClicked",function(){e.CHM(h);const w=e.oxw();return e.KtG(w.register())}),e.qZA()}if(2&N){const h=e.oxw();e.Q6J("displayName",h.firstName)}}function ut(N,ht){1&N&&e._UZ(0,"mat-spinner",6),2&N&&e.Q6J("diameter",30)("strokeWidth",4)}const Pt=function(N,ht){return{"is-mobile":N,"modal-arrow":ht}};let bt=(()=>{class N{get onPage(){return!this.inNav}get inModal(){return this.inNav}constructor(h,U,w,J,it,pt,Ct,St,At,Tt){this.authService=h,this.environmentService=U,this.rdd=w,this.constituentService=J,this.breakpointService=it,this.storageService=pt,this.flowPageNavigatorService=Ct,this.oneAllConfigurationService=St,this.tokenService=At,this.googleAnalytics=Tt,this.wrapper="login-modal",this.isLoadingIconVisible=!1,this.environment=this.environmentService.getEnvironment(),this.closeLogin=new e.vpe}ngOnInit(){this.environment.eventUrl=this.environment.eventUrl.replace("{subEvent}",this.rdd.subEventPart);const h=this.storageService.getData(ft.z1.OneAllConnectionTokenKey);(0,r.isEmpty)(h)||(this.storageService.removeData(ft.z1.OneAllConnectionTokenKey),this.storageService.removeData(ft.z1.OpenLoginModalKey),this.socialLogin(h)),!this.inNav&&this.authService.isAuthenticated()&&this.authService.goToMyAccount()}ngOnDestroy(){(0,r.isNil)(this.socialSubscription)||this.socialSubscription.unsubscribe(),this.oneAllConfigurationService.initOneAllScript()}isMobile(){return this.breakpointService.isMobile()}closeClicked(){this.closeLogin.emit()}register(){this.isSocialLogin&&this.oneAllConfigurationService.updateSocialNetworkConnection({status:L.lA.ConnectedAsReturningParticipant,displayName:this.firstName}),this.closeLogin.emit(!0),this.flowPageNavigatorService.navigateTo("pledge/registration/start")}login(h){const U=this.storageService.getData("error");(0,r.includes)([L.NI.EventEnded,L.NI.EventNotStarted,L.NI.PageNotFound],U?.errorType)?this.errorMessage="errInvalidUsernamePassword":(this.isLoadingIconVisible=!0,this.authService.login(h).pipe((0,et.q)(1),(0,o.K)(w=>(0,mt._)(w))).subscribe({next:w=>{this.googleAnalytics.login("raisin"),this.isLoadingIconVisible=!1,this.authService.goToParticipantCentre(w.value,w.culture,w.roles,w.firstLogin)},error:w=>{this.isLoadingIconVisible=!1,this.handleError(w)}}))}socialLogin(h){this.socialSubscription=this.tokenService.getUserToken({orgId:this.rdd.organizationId,subEventCustomPart:this.storageService.eventParams.subEventCustomPart,isLoggedInToFacebook:!0,connectionToken:h}).pipe((0,et.q)(1),(0,o.K)(w=>(0,mt._)(w))).subscribe({next:w=>{this.googleAnalytics.login("Facebook"),this.authService.goToParticipantCentre(w.value,w.culture,w.roles,w.firstLogin)},error:w=>{this.handleError(w,!0)}})}handleError(h,U=!1){const w=h.error;switch(h.status){case 403:this.errorMessage=T.NA.accountLocked;break;case 406:this.errorMessage=T.NA.inactiveAccount;break;case 409:const J=JSON.parse(w);this.firstName=J.profile.firstName,this.isWelcomeBack=!0,this.errorMessage=T.NA.notRegisteredForCurrentEvent;const it=this.constituentService.getConstituentFromStorage();(0,r.merge)(it,J),this.constituentService.saveConstituent(it),this.isSocialLogin=U;break;case 404:this.errorMessage=T.NA.noUserSocialCredentials;break;default:this.errorMessage=T.NA.invalidUsernamePassword}}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(S.$),e.Y36(T.L$),e.Y36(m.n),e.Y36(vt.d),e.Y36(G.r),e.Y36(Y.V1),e.Y36(O.P),e.Y36(v.O),e.Y36(rt.YW),e.Y36(tt.Wf))};static#e=this.\u0275cmp=e.Xpm({type:N,selectors:[["rx-login-modal"]],hostVars:6,hostBindings:function(U,w){2&U&&(e.Tol(w.wrapper),e.ekj("on-page",w.onPage)("in-modal",w.inModal))},inputs:{inNav:"inNav"},outputs:{closeLogin:"closeLogin"},decls:4,vars:7,consts:[[1,"rx-login-container",3,"ngClass"],[3,"errorMessage","closeClicked","loginClicked","socialClicked",4,"ngIf"],[3,"displayName","registerClicked",4,"ngIf"],[3,"diameter","strokeWidth",4,"ngIf"],[3,"errorMessage","closeClicked","loginClicked","socialClicked"],[3,"displayName","registerClicked"],[3,"diameter","strokeWidth"]],template:function(U,w){1&U&&(e.TgZ(0,"div",0),e.YNc(1,st,1,1,"rs-login",1),e.YNc(2,dt,1,1,"rs-welcome-back",2),e.YNc(3,ut,1,2,"mat-spinner",3),e.qZA()),2&U&&(e.Q6J("ngClass",e.WLB(4,Pt,w.isMobile(),w.inNav)),e.xp6(1),e.Q6J("ngIf",!w.isWelcomeBack),e.xp6(1),e.Q6J("ngIf",w.isWelcomeBack),e.xp6(1),e.Q6J("ngIf",w.isLoadingIconVisible))},dependencies:[_.mk,_.O5,gt.G,_t,V.Ou],styles:[".login-modal.on-page{float:left;width:100%}.login-modal.on-page .close{display:none}.login-modal.on-page .login-panel__header{margin-bottom:0!important}.login-modal.on-page h1{font-size:1.3125rem!important;line-height:50px!important;margin-top:22px!important;margin-bottom:8px!important}.in-modal.login-modal .rx-login-container{position:fixed;display:block;z-index:1}@media screen and (max-width: 600px){.in-modal.login-modal .rx-login-container{margin-left:-11.6em}}@media screen and (min-width: 600px) and (max-width: 1024px){.in-modal.login-modal .rx-login-container{margin-left:-11.6em}}@media screen and (min-width: 1024px){.in-modal.login-modal .rx-login-container{margin-left:-17.4em;margin-top:1rem}}.in-modal.login-modal .rx-login-container .mat-form-field-appearance-legacy .mat-form-field-underline{display:none!important}.on-page.login-modal .rx-login-container{margin:auto;width:400px}@media screen and (max-width: 400px){.on-page.login-modal .rx-login-container{width:100%}}.login-modal .rx-login-container .login-panel{padding:16px 25px}.login-modal .rx-login-container .login-panel>div{display:flex;align-items:flex-start}.login-modal .rx-login-container .login-panel__user{width:100%}.login-modal .rx-login-container .login-panel__tools{padding:0}.login-modal .mat-spinner{display:inline-block;top:-130px;left:8em;z-index:1000}\n"],encapsulation:2})}return N})();var Rt=t(15047);let Mt=(()=>{class N{constructor(h,U,w){this.applicationInitStatus=h,this.urlCheckerService=U,this.router=w}canActivateChild(h,U){return this.applicationInitStatus.done?this.urlCheckerService.verifyUrl(U.url).pipe((0,A.U)(w=>w===U.url||this.router.parseUrl(w)),(0,o.K)(w=>(console.error(w),(0,u.of)(!0)))):(0,u.of)(!0)}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(e.CZH),e.LFG(Rt.q),e.LFG(f.F0))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();const Nt=[{path:":subEventCustomPart",pathMatch:"prefix",component:at,canActivate:[nt],children:[{matcher:N=>{if((0,r.isEmpty)(N)||N.length>1)return null;const ht=(0,r.toString)(N[0]);return(0,r.includes)(["login","connexion"],ht)?{consumed:[N[0]]}:null},component:bt,data:{preload:!1}},{matcher:N=>{if((0,r.isNil)(N)||2!==N.length)return null;const ht=(0,r.toString)(N[0]);return(0,r.includes)(["t","team","equipe"],ht)?{consumed:[]}:null},loadChildren:()=>Promise.all([t.e(644),t.e(225),t.e(971),t.e(592),t.e(836)]).then(t.bind(t,84327)).then(N=>N.EntityPageModule),data:{preload:!0,name:"team entity",entity:!0,entityType:L.Ox.Team},canActivateChild:[Mt]},{matcher:N=>{if((0,r.isNil)(N)||2!==N.length)return null;const ht=(0,r.toString)(N[0]);return(0,r.includes)(["p","participant"],ht)?{consumed:[]}:null},loadChildren:()=>Promise.all([t.e(644),t.e(225),t.e(971),t.e(592),t.e(836)]).then(t.bind(t,84327)).then(N=>N.EntityPageModule),data:{preload:!0,name:"participant entity",entity:!0,entityType:L.Ox.Participant},canActivateChild:[Mt]},{matcher:N=>{if((0,r.isNil)(N)||2!==N.length)return null;const ht=(0,r.toString)(N[0]);return(0,r.includes)(["g"],ht)?{consumed:[]}:null},loadChildren:()=>Promise.all([t.e(644),t.e(225),t.e(971),t.e(592),t.e(836)]).then(t.bind(t,84327)).then(N=>N.EntityPageModule),data:{preload:!0,name:"group entity",entity:!0,entityType:L.Ox.Group}},{matcher:N=>{if((0,r.isNil)(N))return null;const ht=(0,r.toString)(N[0]);return(0,r.includes)(["event-not-found","event-not-started","event-ended"],ht)?{consumed:[]}:null},loadChildren:()=>t.e(114).then(t.bind(t,61114)).then(N=>N.EventErrorModule),data:{name:"errors",routeToError:!0}},{matcher:N=>{if((0,r.isNil)(N))return null;const ht=(0,r.toString)(N[0]);return(0,r.includes)(["pc","ticketed"],ht)?{consumed:[]}:null},loadChildren:()=>Promise.all([t.e(644),t.e(225),t.e(971),t.e(922),t.e(592),t.e(28)]).then(t.bind(t,40028)).then(N=>N.TicketingModule),data:{preload:!0,name:"ticketing"}},{matcher:N=>{if((0,r.isNil)(N))return null;const ht=(0,r.toString)(N[0]);return(0,r.includes)(["volunteer"],ht)?{consumed:[]}:null},loadChildren:()=>Promise.all([t.e(644),t.e(225),t.e(971),t.e(922),t.e(592)]).then(t.bind(t,22346)).then(N=>N.FlowRoutingModule),data:{preload:!0,name:"volunteer"}},{matcher:N=>{if((0,r.isEmpty)(N)||N.length>2)return null;const ht=(0,r.toString)(N[0]),h=(0,r.includes)(["store"],ht);return h&&1===N.length?null:h?{consumed:[N[0]]}:null},loadChildren:()=>Promise.all([t.e(644),t.e(225),t.e(971),t.e(922),t.e(592),t.e(203)]).then(t.bind(t,38203)).then(N=>N.RaisinStoreModule)},{path:"pledge",loadChildren:()=>Promise.all([t.e(922),t.e(597)]).then(t.bind(t,63597)).then(N=>N.PledgeRoutingModule),data:{preload:!0}},{path:"donations",loadChildren:()=>Promise.all([t.e(644),t.e(225),t.e(971),t.e(922),t.e(134),t.e(592),t.e(33)]).then(t.bind(t,93033)).then(N=>N.DonationsModule),data:{preload:!0}},{matcher:N=>{if((0,r.isEmpty)(N)||N.length>2)return null;const ht=(0,r.toString)(N[0]);return(0,r.includes)(["forgot-password","forgot-username","password-reset"],ht)?{consumed:[]}:null},loadChildren:()=>Promise.all([t.e(644),t.e(225),t.e(971),t.e(922),t.e(592),t.e(762)]).then(t.bind(t,42762)).then(N=>N.ForgotModule)},{path:"oneall/:connectionToken/:isLogin",component:f.fw,canActivate:[M]},{matcher:N=>({consumed:[]}),loadChildren:()=>Promise.all([t.e(225),t.e(134),t.e(131)]).then(t.bind(t,97131)).then(N=>N.PageLayoutModule)}]}];let Vt=(()=>{class N{static#t=this.\u0275fac=function(U){return new(U||N)};static#e=this.\u0275mod=e.oAB({type:N});static#i=this.\u0275inj=e.cJS({imports:[f.Bz.forRoot(Nt,{scrollPositionRestoration:"top",enableTracing:!1,preloadingStrategy:C,malformedUriErrorHandler:(h,U,w)=>{console.error(`malformedUriError (url=${w}), trying to encode to fix it`);const J=encodeURI(w);return U.parse(J)},errorHandler:h=>{console.debug("RouterModule error ",h)}}),f.Bz]})}return N})();var Ut=t(21441),Bt=t(85553),Dt=t(80001);let zt=(()=>{class N{constructor(h,U,w,J,it,pt,Ct,St,At,Tt,Ae,Zt,xe,be){this.http=h,this.location=U,this.storageService=w,this.environmentService=J,this.configurationService=it,this.jwtAuthService=pt,this.translate=Ct,this.urlCheckerService=St,this.flowPageNavigatorService=At,this.document=Tt,this.apm=Ae,this.rendererFactory=Zt,this.googleReCaptchaService=xe,this.releaseName=be,this.renderer=Zt.createRenderer(null,null),this.CONFIGURATION_URL=`./ui/assets/config/configuration.json?v=${this.releaseName}`}loadConfiguration(){return this.verifyUrl().pipe((0,d.w)(()=>this.fetchToken()),(0,l.b)(h=>this.setAppLanguage(h)),(0,l.b)(h=>console.debug("ConfigurationLoader",h)),(0,l.b)(h=>this.loadStylesAndScripts(h)),(0,l.b)(h=>this.loadExternalScripts()),(0,l.b)(h=>this.loadGlobalizeCultureSpecificScripts()),(0,o.K)(h=>(console.error(h),(0,mt._)(h)))).pipe((0,d.w)(h=>{const U=this.storageService.eventParams.subEventCustomPart,w=this.location.path().replace(`/${U}`,"");return this.configurationService.requestSiteConfiguration(w,h.culture)}),(0,d.w)(h=>{const U=this.environmentService.getEnvironment(),w={currentLang:this.translate.currentLang,errCheckboxCaptchaRequired:this.translate.instant("UI.ERROR.err_reCAPTCHA_required")};return this.googleReCaptchaService.initialize((0,r.get)(h,"subEvent.reCaptchaEnabled"),(0,r.get)(h,"subEvent.reCaptchaEnabledForHppConfig"),(0,r.get)(h,"subEvent.reCaptchaEnterpriseSecretKey"),(0,r.get)(h,"subEvent.reCaptchaEnterpriseCheckboxSecretKey"),U.recaptchaEnterpriseScriptUrl,w)})).toPromise()}setAppLanguage(h){const U=h.culture||"en-CA";this.translate.setDefaultLang(U),this.translate.use(U)}loadStylesAndScripts(h){const{cdnSharedImagesURL:U,organizationId:w,subEventId:J}={...this.configuration,...h},it=`${U}/clients/org_${w}/css/se_${J}.css?v=${(new Date).getTime()}`,pt=this.renderer.createElement("link");pt.id="preloadcss",pt.rel="preload",pt.href=it,pt.as="style",this.renderer.appendChild(this.document.head,pt);const Ct=this.renderer.createElement("link");Ct.id="customcss",Ct.href=it,Ct.rel="stylesheet",Ct.type="text/css",this.renderer.appendChild(this.document.head,Ct);const St=this.renderer.createElement("script");St.src=`${U}/sharedimages/js/jquery.widgetLoader.min.js?v=${this.releaseName}`,St.defer=!0,this.renderer.appendChild(this.document.body,St);const At=this.renderer.createElement("script");At.src=`${U}/sharedimages/js/aka.init.min.js?v=${this.releaseName}`,At.defer=!0,this.renderer.appendChild(this.document.body,At)}loadExternalScripts(){const h=this.renderer.createElement("script");h.type=ft.Yg,h.src="https://connect.facebook.net/en_US/sdk.js",h.defer=!0,this.renderer.appendChild(this.document.body,h)}fetchToken(){const{subEventCustomPart:h,orgId:U}=this.storageService.eventParams,w=this.http.get(this.CONFIGURATION_URL).pipe((0,A.U)(J=>{this.configuration=J,this.environmentService.createEnvironment(J),this.storageService.setData("baseAPIUrl",this.configuration.raisinEndpointUrl),this.apm.setInteractionAttributes({subEventCustomPart:h,organizationId:U,subEventId:this.storageService.getSubEventId(),language:this.storageService.getLanguage()})}));if(!(0,r.isNil)(this.storageService.getJWT())&&!(0,r.isNil)(this.storageService.getSubEventId())&&!(0,r.isNil)(this.storageService.getOrganizationId())){const J={value:this.storageService.getJWT(),subEventId:this.storageService.getSubEventId(),organizationId:this.storageService.getOrganizationId(),culture:this.storageService.getData("culture",h)};return this.storageService.setEventParams({subEventCustomPart:h,orgId:`${J.organizationId}`}),w.pipe((0,Ut.h)(J))}return w.pipe((0,d.w)(()=>this.jwtAuthService.getAnonymousToken(this.storageService.eventParams)))}getSubEventPart(h){return(0,r.trimStart)(h.replace("/ui/","").split("?")[0],"/").split("/")[0]}verifyUrl(){const h=this.location.path();return this.urlCheckerService.verifyUrl(h).pipe((0,A.U)(U=>{const w=this.getSubEventPart(U);return this.storageService.setEventParams({subEventCustomPart:w}),(0,r.isEmpty)(w)?(this.flowPageNavigatorService.redirectToExternalUrl("https://akaraisin.com"),(0,mt._)(new Error("No SubEvent Part in url")).toPromise()):(U!==h&&(console.debug("registerOnBeforeHook is redirecting to",U),this.location.go(U)),!0)}),(0,o.K)(U=>(0,mt._)(U)))}loadGlobalizeCultureSpecificScripts(){const h=this.translate.currentLang,U="https://raisincdn-si.akaraisin.com/sharedimages/mobile/js/libs/globalize/",w=this.renderer.createElement("script");w.src=`${U}globalize.min.js`,w.onload=J=>{const it=`${U}cultures/globalize.culture.${h}.js`,pt=this.renderer.createElement("script");pt.id="globalizeScript"+h,pt.type=ft.Yg,pt.async=!0,pt.src=it,this.renderer.appendChild(this.document.body,pt)},this.renderer.appendChild(this.document.body,w)}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(I.eN),e.LFG(_.Ye),e.LFG(Y.V1),e.LFG(T.L$),e.LFG(Bt.e),e.LFG(Dt.tH),e.LFG(P.sK),e.LFG(Rt.q),e.LFG(O.P),e.LFG(_.K0),e.LFG(tt.nL),e.LFG(e.FYo),e.LFG(j.gY),e.LFG(Y.ZF))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();function Jt(N){return()=>N.loadConfiguration()}let Yt=(()=>{class N{static#t=this.\u0275fac=function(U){return new(U||N)};static#e=this.\u0275mod=e.oAB({type:N});static#i=this.\u0275inj=e.cJS({providers:[{provide:e.ip1,useFactory:Jt,deps:[zt],multi:!0},_.Ye,{provide:_.S$,useClass:_.b0}],imports:[I.JF]})}return N})();var Qt=t(14721),Xt=t(17632),Lt=t(10493),qt=t(9315),te=t(81374),ee=t(21631),It=t(49758),Ft=t(20376),kt=t(90569);let ie=(()=>{class N{constructor(h,U,w){this.flowPageManagementService=h,this.flowPageValidationService=U,this.storageService=w,this.registeredComponents={}}registerComponent(h){this.registeredComponents[h]={state:"pending"}}clearRegistry(){this.registeredComponents={}}deregisterComponent(h){delete this.registeredComponents[h]}getSkipDirection(h){const U=this.flowPageManagementService.getLocationPath();if(!this.flowPageValidationService.isFlow(U)||!h||!this.registeredComponents[h.name])return 0;this.registeredComponents[h.name].state=h.hasData?"ok":"empty";let J=this.storageService.getData("step.direction");(!J||"createAccount"===h.name&&!h.hasData)&&(J=L.fS.Forward,this.storageService.setData("step.direction",L.fS.Forward));for(const it in this.registeredComponents)if(this.registeredComponents.hasOwnProperty(it)&&"empty"!==this.registeredComponents[it].state)return 0;return J}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(kt.n),e.LFG(Ft.p),e.LFG(Y.V1))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();var ne=t(65381),se=t(59945);let re=(()=>{class N{constructor(h,U,w,J,it){this.notificationService=h,this.componentRegistrationService=U,this.flowPageNavigatorService=w,this.flowPageTrackerService=J,this.flowButtonService=it,this.destroy$=new E.x}registerFlowListerners(){this.destroyFlowListerners(),(0,r.isNil)(this.notificationSubscription)&&(this.destroy$=new E.x,this.notificationSubscription=this.notificationService.listenForEvents(L.Jk.Flow).pipe((0,c.h)(h=>!(0,r.isNil)(h)&&!(0,r.isEmpty)(h)))),this.notificationSubscription.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h.name===It.d.ComponentClearRegistry)).subscribe({next:h=>this.componentRegistrationService.clearRegistry()}),this.notificationSubscription.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h.name===It.d.ComponentRegister)).subscribe({next:h=>this.componentRegistrationService.registerComponent(h.data)}),this.notificationSubscription.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h.name===It.d.ComponentHasData)).subscribe({next:h=>{const U=this.componentRegistrationService.getSkipDirection(h.data);(U===L.fS.Forward||U===L.fS.Backward)&&(U===L.fS.Forward?this.flowPageNavigatorService.nextStep():this.flowPageNavigatorService.previousStep())}}),this.notificationSubscription.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h.name===It.d.DisabledProceedButton),(0,l.b)(h=>console.debug(h.name,h.data,h.location))).subscribe({next:h=>this.flowButtonService.setIsProceedButtonDisabled(h.data)}),this.notificationSubscription.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h.name===It.d.ShowFlowButtons),(0,l.b)(h=>console.debug(h.name,h.data,h.location))).subscribe({next:h=>this.flowButtonService.setFlowButtonVisible(h.data)}),this.notificationSubscription.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h.name===It.d.Submit||h.name===It.d.ShowContinueBtn),(0,l.b)(h=>console.debug(h.name,h.data,h.location))).subscribe({next:h=>{this.flowButtonService.setContinueButtonVisible(h.data&&h.data.showContinueButton,h.name===It.d.Submit?L.mQ.ShowSubmitBtn:L.mQ.ShowContinueBtn)}}),this.notificationSubscription.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h.name===It.d.AreFlowButtonsVisible),(0,l.b)(h=>console.debug(h.name,h.data,h.location))).subscribe({next:h=>this.flowButtonService.setAreFlowButtonsVisible(h.data&&h.data.areFlowButtonsVisible)}),this.notificationSubscription.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h.name===It.d.UpdateRegistrationSteps),(0,l.b)(h=>console.debug(h.name,h.data,h.location)),(0,ee.z)(h=>this.flowPageTrackerService.updateRegFlowPageState(h.data))).subscribe(),this.notificationSubscription.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h.name===It.d.SwitchFlow),(0,l.b)(h=>console.debug(h.name,h.data,h.location)),(0,l.b)(h=>this.flowPageTrackerService.switchLoadedFlow(h.data))).subscribe()}destroyFlowListerners(){this.destroy$.next(!0),this.destroy$.complete(),this.notificationSubscription=null}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(p.g),e.LFG(ie),e.LFG(O.P),e.LFG(se.r),e.LFG(ne.J))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();var oe=t(61142),ae=t(92291),le=t(35297);const Kt=new oe.Be;let ce=(()=>{class N{constructor(h,U,w,J){this.errorHandler=h,this.raisinAPI=U,this.storageService=w,this.rdd=J}getQueryStringParameters(){const h=window.location.href;return h.includes("?")?new I.LE({fromString:h.split("?")[1]}):null}processPageVisitTracking(){const h=this.getQueryStringParameters();if(h&&h.get("abcId")&&h.get("TV")){const w=Kt.Angular.Utils.parseFloat(h.get("abcId")),J=Kt.Angular.Utils.parseFloat(h.get("TV"));w>0&&1===J?this.recordPageVisitByAddressBookContactId(w).subscribe():this.errorHandler.handleError("Invalid page tracking parameters abcId "+h.get("abcId")+" and TV "+h.get("TV"))}}recordPageVisitByAddressBookContactId(h){if(!(0,r.isNumber)(h)||!isFinite(h)||h<=0||parseInt(h.toString(),10)!=h)return console.warn("Page visit could not be recorded because of invalid address book contact id"),(0,mt._)("address book contact id invalid");{const w=`pv_abcid_${h}`;return this.storageService.getData(w)?(console.debug("page visit already recorded for sub event "+this.rdd.subEventId+" and address book contact id "+h),(0,mt._)("page visit already recorded")):this.raisinAPI.PageTracking.post({addressBookContactId:h},null,null).pipe((0,ae.V)(()=>(this.storageService.setData(w,new Date),(0,u.of)(!0))),(0,o.K)(it=>(console.error("page visit record failed for sub event "+this.rdd.subEventId+" and address book contact id "+h),this.errorHandler.handleError(it),(0,mt._)(it))))}}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(e.qLn),e.LFG(le.O),e.LFG(Y.V1),e.LFG(m.n))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();var xt=t(78356),de=t(91687),ue=t(92438),he=t(99080),ge=t(30812),me=t(60932),Ot=t(49766);let Wt=(()=>{class N{resetDelta(){this.delta=5,this.deltaCompressed=5}constructor(h,U,w){this.breakpointService=h,this.browserDetectionService=U,this.notificationService=w,this.didScroll=!1,this.lastScroll=0,this.delta=5,this.deltaCompressed=5,this.isHeaderCompressed=!1,this.isAtTop=!0,this.stopPolling=new E.x,this.currentHeaderHeight=0}getElement(h){return function pe(N){return $(N)}(h)}ngOnDestroy(){this.stopPolling.next(!0),this.destroy$.next(!0),this.destroy$.complete()}ngOnInit(){this.destroy$=new E.x}isAtTopOfWindow(){return this.getScrollTop()<20}isRendered(){return this.currentHeaderHeight===this.getHeaderHeight()&&this.getHeaderHeight()>0||(this.currentHeaderHeight=this.getHeaderHeight(),!1)}getScrollTop(){return this.browserDetectionService.isSafari()?this.getScrollTopForSafariAfterVer12_1_2()||this.getScrollTopForSafariPriorToAndIncludingVer12_1_2()||0:$(this.getRootUIViewElement()).scrollTop()}getScrollTopForSafariPriorToAndIncludingVer12_1_2(){return $("body").scrollTop()}getScrollTopForSafariAfterVer12_1_2(){return $(this.getRootUIViewElement()).scrollTop()}padHeaderAndPage(h){this.isHomePage=!!h&&h.isHomePage,this.padHeader&&this.padHeader(),this.handlePaddingOfPage&&this.handlePaddingOfPage()}toggleClass(h,U){const w=this.getElement(h);w&&(w.hasClass(U)?w.removeClass(U):w.addClass(U))}getRootUIViewElement(){return(0,r.isNil)(this.rootElement)&&(this.rootElement=this.getElement("html")),this.rootElement}collapseElement(h){this.getElement(h).collapse("hide")}isMobileHeader(){return this.breakpointService.isMobile()}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(G.r),e.Y36(Ot.p),e.Y36(p.g))};static#e=this.\u0275dir=e.lG2({type:N})}return N})(),Gt=(()=>{class N extends Wt{constructor(h,U,w,J,it){super(h,U,w),this.breakpointService=h,this.browserDetectionService=U,this.notificationService=w,this.element=J,this.renderer=it}ngOnDestroy(){super.ngOnDestroy()}ngOnInit(){super.ngOnInit()}get siteHeader(){return this.element||(0,r.first)(this.getElement(".site-header"))}handlePaddingOfPage(){const h=window,U=this.siteHeader?.nativeElement;(0,r.isNil)(U)||this.renderer.setStyle(U,"width",h.innerWidth),h.innerWidth>=1023&&this.expandHeader()}compressHeader(){const h=this.siteHeader.nativeElement,U=this.getHeaderHeight();this.renderer.addClass(h,"compressedNav");const w=U-this.getElement("#mainNavCont").outerHeight();this.renderer.setStyle(h,"margin-top",`-${w}px`),this.isHeaderCompressed=!0}expandHeader(){const h=this.siteHeader.nativeElement;this.renderer.removeClass(h,"compressedNav"),this.renderer.setStyle(h,"margin-top","0px"),this.isHeaderCompressed=!1}padHeader(){this.collapseElement(".navbar-collapse")}getHeaderHeight(){return this.siteHeader.nativeElement.offsetHeight}onScroll(){if($(window).innerWidth()<1023){this.collapseElement(".navbar-collapse");const U=$(this.getRootUIViewElement()).scrollTop(),w=U>=this.lastScroll;this.isAtTop=U<=25,this.isHeaderCompressed||!w||this.isAtTop?this.isHeaderCompressed&&!w&&this.expandHeader():this.compressHeader(),this.lastScroll=U}}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(G.r),e.Y36(Ot.p),e.Y36(p.g),e.Y36(e.SBq),e.Y36(e.Qsj))};static#e=this.\u0275dir=e.lG2({type:N,features:[e.qOj]})}return N})(),Ht=(()=>{class N extends Wt{constructor(h,U,w,J,it){super(h,U,w),this.breakpointService=h,this.browserDetectionService=U,this.notificationService=w,this.siteHeader=J,this.renderer=it}ngOnDestroy(){super.ngOnDestroy()}ngOnInit(){this.barHeight=0,super.ngOnInit(),this.siteHeader=this.siteHeader||this.getElement(".site-header")}handlePaddingOfPage(){this.isMobileHeader()||this.expandHeader()}getHeaderLogo(){return(0,r.isNil)(this.headerLogo)&&(this.headerLogo=(0,r.first)(this.getElement(".navbar-header.rfx-header__brand"))),this.headerLogo}getHeaderHeight(){return this.isHeaderV3()&&!this.isMobileHeader()?$(this.getHeaderLogo()).outerHeight():this.siteHeader.nativeElement.offsetHeight}onScroll(){const h=this.getScrollTop(),U=h-this.lastScroll;if(this.deltaCompressed>this.siteHeader.nativeElement.offsetHeight&&(this.deltaCompressed=this.siteHeader.nativeElement.offsetHeight),this.isHeaderCompressed&&h<=this.delta-this.deltaCompressed&&this.expandHeader(),Math.abs(U)<=this.delta)return;const w=U>0;!this.isHeaderCompressed&&w?this.compressHeader():this.isHeaderCompressed&&!w&&this.expandHeader(),h<this.delta?this.expandHeaderImage(this.getElement(".rfx-header__brand img")):this.compressHeaderImage(this.getElement(".rfx-header__brand img")),this.lastScroll=h}isMobileHeaderV5(){return this.isMobileHeader()&&this.isHeaderV5()}isHeaderV3(){return $(this.siteHeader.nativeElement).find(".rfx-header.rfx-header--v3").length>0}isHeaderV5(){return $(this.siteHeader.nativeElement).find(".rfx-header.rfx-header--v5.rfx-header--solid").length>0}isHeaderV1(){return $(this.siteHeader.nativeElement).find(".rfx-header.rfx-header--v1").length>0}isV1HeaderBackgroundVisible(){return!this.isHomePage}padHeader(){this.isAtTopOfWindow()&&this.expandHeaderImage(this.getElement(".rfx-header__brand img"));const h=this.getHeaderHeight();if(this.delta<=h&&this.delta!==this.barHeight&&(this.delta=h),this.delta!==this.barHeight&&(this.barHeight=this.delta),this.isMobileHeaderV5()){const U=this.getElement(".rfx-header .rfx-header__actions").height();this.getElement(".base-page").css({"padding-top":U+"px"})}else this.isHeaderV1()&&!this.isV1HeaderBackgroundVisible()&&(this.getElement(".base-page").css({"padding-top":"0px"}),this.getElement('.base-page section[region-type="top"] .is-section.is-box:first-child > .is-boxes').css({"padding-top":this.barHeight+"px"}))}expandHeader(){this.renderer.removeClass(this.siteHeader.nativeElement,"is-scrolled"),this.isHeaderCompressed=!1}compressHeader(){this.renderer.addClass(this.siteHeader.nativeElement,"is-scrolled"),this.renderer.removeClass(this.siteHeader.nativeElement,"menu-open"),this.collapseElement(".rfx-header__menu"),this.getElement(".rfx-header__toggle").removeClass("active"),this.isHeaderCompressed=!0,this.deltaCompressed=this.siteHeader.nativeElement.offsetHeight}compressHeaderImage(h){if(h.length&&!h.hasClass("is-compressed")&&!this.isMobileHeader()){const w=.8*h[0].height,J=.8*h[0].width;h.parent().css("width",J+"px"),h.parent().css("height",w+"px"),h.css("transform","scale(0.8)").addClass("is-compressed")}}expandHeaderImage(h){h.hasClass("is-compressed")&&!this.isMobileHeader()&&(h.parent().removeAttr("style"),h.css("transform","scale(1)"),h.removeClass("is-compressed"))}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(G.r),e.Y36(Ot.p),e.Y36(p.g),e.Y36(e.SBq),e.Y36(e.Qsj))};static#e=this.\u0275dir=e.lG2({type:N,features:[e.qOj]})}return N})(),fe=(()=>{class N{onWindowScroll(h){this.setIsAtTop()}onResize(h){this.headerAffix.resetDelta(),this.setIsAtTop(),this.headerAffix.padHeader(),this.headerAffix.handlePaddingOfPage(),this.isMobile=this.headerAffix.isMobileHeader()}onTouchcroll(h){this.setIsAtTop()}constructor(h,U,w,J,it,pt,Ct,St,At,Tt){this.document=h,this.element=U,this.breakpointService=w,this.browserDetectionService=J,this.notificationService=it,this.renderer=pt,this.store=Ct,this.raisinRouter=St,this.location=At,this.router=Tt,this.isScrolled=!1,this.isTop=!0,this.onHomePage=!1,this.isMobile=!1,this.menuOpen=!1}ngAfterContentInit(){let h=null;(0,de.F)(50).pipe((0,ge.o)(U=>(0,r.isNil)(h)),(0,Ut.h)(this.document.getElementsByClassName("rfx-header__toggle")),(0,A.U)(U=>U?.[0])).subscribe(U=>{h=U,h&&(0,ue.R)(h,"click").pipe((0,R.R)(this.destroy$),(0,me.g)(70)).subscribe(w=>{this.menuOpen=!this.menuOpen,this.menuOpen?this.renderer.addClass(h,"active"):this.renderer.removeClass(h,"active")})})}ngOnDestroy(){this.headerAffix.ngOnDestroy(),this.destroy$.next(!0),this.destroy$.complete()}ngOnInit(){this.destroy$=new E.x,this.store.pipe((0,g.Ys)(h=>(0,xt.Io)(h,1e4)),(0,T.FL)(),(0,A.U)(h=>h?.html),(0,R.R)(this.destroy$)).subscribe(h=>{if((0,r.includes)(h,"rfx-header")){if(this.headerAffix=new Ht(this.breakpointService,this.browserDetectionService,this.notificationService,this.element,this.renderer),(0,r.includes)(h,"rfx-header--v1")){const w=(0,r.trimStart)(this.location.path().replace("/ui/","").split("?")[0],"/");this.onHomePage=1===(0,r.size)(w.split("/"))}}else this.headerAffix=new Gt(this.breakpointService,this.browserDetectionService,this.notificationService,this.element,this.renderer);this.headerAffix.ngOnInit(),this.isMobile=this.headerAffix.isMobileHeader(),(0,he.H)(0,50).pipe((0,R.R)(this.headerAffix.stopPolling)).subscribe(()=>{this.headerAffix.isRendered()&&(this.setHeaderHeight(),this.headerAffix.stopPolling.next(!0))})}),this.raisinRouter.pipe((0,g.Ys)(b.sf),(0,T.FL)(),(0,A.U)(h=>h.url.split("/"))).subscribe(h=>{this.headerAffix instanceof Ht&&(this.onHomePage=1===(0,r.size)(h)&&this.headerAffix.isHeaderV1()),this.setHeaderHeight()}),this.router.events.pipe((0,R.R)(this.destroy$),(0,c.h)(h=>h instanceof f.OD)).subscribe(()=>{this.breakpointService.isMobile()&&($(".rfx-header__menu").collapse("hide"),$(".rfx-header__toggle").removeClass("active"),setTimeout(()=>this.menuOpen=!1,50)),this.setHeaderHeight()})}setHeaderHeight(){this.headerAffix&&(this.headerAffix instanceof Gt?this.headerAffix.padHeaderAndPage():this.headerAffix.padHeaderAndPage({isHomePage:this.onHomePage}))}setIsAtTop(){this.headerAffix&&(this.headerAffix.onScroll(),this.headerAffix.didScroll=!0,this.isTop=this.headerAffix.getScrollTop()<ft.D7.SiteHeaderFixedOffset,this.isScrolled=!this.isTop)}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(_.K0),e.Y36(e.SBq),e.Y36(G.r),e.Y36(Ot.p),e.Y36(p.g),e.Y36(e.Qsj),e.Y36(g.yh),e.Y36(g.yh),e.Y36(_.Ye),e.Y36(f.F0))};static#e=this.\u0275dir=e.lG2({type:N,selectors:[["","affix",""]],hostVars:10,hostBindings:function(U,w){1&U&&e.NdJ("scroll",function(it){return w.onWindowScroll(it)},!1,e.Jf7)("resize",function(it){return w.onResize(it)},!1,e.Jf7)("touchMove",function(it){return w.onTouchcroll(it)},!1,e.Jf7),2&U&&e.ekj("is-scrolled",w.isScrolled)("is-top",w.isTop)("on-home-page",w.onHomePage)("is-mobile",w.isMobile)("menu-open",w.menuOpen)}})}return N})();function ve(N,ht){1&N&&e._UZ(0,"div",1)(1,"div",2)}let _e=(()=>{class N{constructor(h){this.loader=h,this.wrapperClass="ajax-loader",this.destroy$=new E.x}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}ngOnInit(){this.loader.value$.pipe((0,R.R)(this.destroy$)).subscribe(h=>{this.isLoading=!(h<7)&&h<100})}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(z.dL))};static#e=this.\u0275cmp=e.Xpm({type:N,selectors:[["rx-ajax-loader"]],hostVars:2,hostBindings:function(U,w){2&U&&e.Tol(w.wrapperClass)},decls:1,vars:1,consts:[[3,"ngIf"],[1,"ajax-loader__overlay"],[1,"ajax-loader__spinner"]],template:function(U,w){1&U&&e.YNc(0,ve,2,0,"ng-template",0),2&U&&e.Q6J("ngIf",w.isLoading)},dependencies:[_.O5],styles:['.ajax-loader__overlay{position:fixed;top:0;left:0;width:100%;height:100%;z-index:1000;background-color:#dbdbdb;opacity:.8}.ajax-loader__spinner{position:fixed;left:50%;top:50%;margin-left:-23px;margin-top:-23px;display:block}.ajax-loader__spinner{animation:rotate 1.5s infinite;height:25px;width:25px;z-index:2000}.ajax-loader__spinner:before,.ajax-loader__spinner:after{border-radius:50%;content:"";display:block;height:10px;width:10px}.ajax-loader__spinner:before{animation:ball1 1.5s infinite;background-color:#bb3627;box-shadow:15px 0 #bb3627;margin-bottom:5px}.ajax-loader__spinner:after{animation:ball2 1.5s infinite;background-color:#bb3627;box-shadow:15px 0 #bb3627}@keyframes rotate{0%{-webkit-transform:rotate(0deg) scale(1.2);-moz-transform:rotate(0deg) scale(1.2)}50%{-webkit-transform:rotate(360deg) scale(1.2);-moz-transform:rotate(360deg) scale(1.2)}to{-webkit-transform:rotate(720deg) scale(1.2);-moz-transform:rotate(720deg) scale(1.2)}}@keyframes ball1{0%{box-shadow:15px 0 #bb3627}50%{box-shadow:0 0 #bb3627;margin-bottom:0;-webkit-transform:translate(7px,7px);-moz-transform:translate(7px,7px)}to{box-shadow:15px 0 #bb3627;margin-bottom:5px}}@keyframes ball2{0%{box-shadow:15px 0 #bb3627}50%{box-shadow:0 0 #bb3627;margin-top:-10px;-webkit-transform:translate(7px,7px);-moz-transform:translate(7px,7px)}to{box-shadow:15px 0 #bb3627;margin-top:0}}\n'],encapsulation:2})}return N})();var Ee=t(40479);const Ce=["headerContent"],Pe=["flowFocusReset"],Ie=["poweredby"];let Se=(()=>{class N{constructor(h,U,w,J,it,pt,Ct,St,At,Tt,Ae,Zt,xe,be,Qe,Xe){this.document=h,this.flowNotificationService=U,this.store=w,this.raisinRouter=J,this.router=it,this.pageTrackingService=pt,this.configurationService=Ct,this.flowPageManagementService=St,this.flowPageValidationService=At,this.breakpointService=Tt,this.googleAnalytics=Ae,this.storageService=Zt,this.jwtAuthService=xe,this.environmentService=be,this.renderer=Qe,this.dynamicScriptService=Xe,this.destroy$=new E.x,this.resetTimer=!1,this.startTimer=!1}ngOnInit(){this.eventChanged=!0,this.store.dispatch((0,xt._b)()),this.flowNotificationService.registerFlowListerners(),this.raisinRouter.pipe((0,R.R)(this.destroy$),(0,g.Ys)(b.sf),(0,c.h)(h=>!(0,r.isNil)(h)),(0,d.w)(h=>this.onEventChange(h)),(0,d.w)(h=>this.flowPageManagementService.getFlowPageState().pipe((0,l.b)(U=>{const w=null!==this.flowPageValidationService.isFlow(h.path),J=h.path.replace(/\//g,"_");this.aodaMessage=w?`wcag.status.${J}`:"",setTimeout(w?()=>this.flowFocusReset.nativeElement.focus({preventScroll:!0}):()=>this.headerContent.nativeElement.focus({preventScroll:!0}))}),(0,A.U)(U=>(this.setStatusPageConfigurationCompleted(!1),this.configurationService.buildConfigurationArgs(h,U))),this.awaitGuardsCheck(h.url))),(0,c.h)(({siteConfigurationArgs:h})=>this.eventChanged||!h.eventError&&(0,r.toLower)(h.url)!==(0,r.toLower)(this.siteConfig?.url)),(0,l.b)(({siteConfigurationArgs:h})=>this.siteConfig=h),(0,d.w)(({siteConfigurationArgs:h,pageConfigurationArgs:U})=>this.configurationService.requestPageConfiguration(h.moduleId,h.pageId,U).pipe((0,l.b)(w=>{this.aodaMessage=w?.settings?.metaTag?.title??this.aodaMessage}),(0,l.b)(w=>this.dispatchLoadRegions(h,w)),(0,l.b)(()=>this.googleAnalytics.trackPageView()),(0,l.b)(()=>this.pageTrackingService.processPageVisitTracking()),(0,l.b)(()=>this.setStatusPageConfigurationCompleted(!0)),(0,l.b)(()=>{setTimeout(()=>this.renderer.removeClass(this.poweredby.nativeElement,"hide"),125)}),(0,o.K)(w=>(console.error("Page configuration failed",w,h,U),(0,u.of)(null))))),(0,l.b)(()=>this.startTimer=!0),(0,o.K)(h=>(console.error(h),(0,mt._)(h)))).subscribe(),this.applyDynamicStyle(),this.dynamicScriptService.addSlickSliderScript(),this.appendWidgetElementsScript()}setStatusPageConfigurationCompleted(h){this.configurationService.pageConfigurationCompleted$.next(h)}ngOnDestroy(){this.flowNotificationService.destroyFlowListerners(),this.destroy$.next(!0),this.destroy$.complete()}awaitGuardsCheck(h){if(this.eventChanged||h.endsWith("/not-found"))return w=>w;const U=this.router.events.pipe((0,te.P)(w=>w instanceof f.c9&&(0,r.trimStart)(h,"/")===(0,r.trimStart)((0,r.toLower)(w.url),"/")&&w.shouldActivate));return w=>(0,qt.D)([w,U]).pipe((0,A.U)(([J])=>J))}applyDynamicStyle(){this.breakpointService.currentActive().subscribe(h=>{let U="";const w=this.document.querySelector("#dynamicStyle");if(1!==(0,r.filter)(h,it=>"xs"===it.mqAlias).length)for(let it=5;it<101;it+=5)U+=` .is-section-${it} { min-height:${Math.floor(innerHeight*(it/100))}px }`;w?w.innerHTML=U:""===w.innerHTML&&w.appendChild(document.createTextNode(U))})}onSkipToMain(h){this.document.getElementById("base-page-top").focus({preventScroll:!0})}appendWidgetElementsScript(){const h=this.environmentService.getEnvironment(),U=document.createElement("script");U.src=`${h.cdnSharedImagesURL}/raisin/js/raisin-widgets.bundle.js?v=4.4.1810`,U.defer=!0,document.body.appendChild(U)}dispatchLoadRegions(h,U){this.store.dispatch(h.moduleId===L.PO.GroupHomePage?(0,xt.zv)({pageUrl:h.url,entityId:(0,r.get)(U,"settings.subEventGroup.subEventGroupId",h.entityId)}):h.moduleId===L.PO.PledgeParticipantHomePage||h.moduleId===L.PO.PledgeTeamHomePage?(0,xt.ZR)({pageRegions:[{id:L.n_.AboveSystemContentRegion,html:" "},{id:L.n_.BelowSystemContentRegion,html:" "}]}):(0,xt.r8)({pageUrl:h.url}))}onEventChange(h){const{subEventCustomPart:U,orgId:w}=this.storageService.eventParams;let J=(0,r.toLower)(h.params.subEventCustomPart);return J||(J=U),this.eventChanged=U!==J,this.eventChanged?(this.storageService.setEventParams({subEventCustomPart:J}),this.jwtAuthService.getAnonymousToken({subEventCustomPart:J}).pipe((0,d.w)(it=>{const pt=h.url.replace(J,"");return this.configurationService.requestSiteConfiguration(pt,it.culture)}),(0,l.b)(()=>this.store.dispatch((0,xt._b)())),(0,l.b)(()=>this.resetStyles(w)),(0,Ut.h)(h))):(0,u.of)(h)}resetStyles(h){const U=this.environmentService.getEnvironment(),w=this.storageService.getData("subEventId"),J=`${U.cdnSharedImagesURL}/clients/org_${h}/css/se_${w}.css?v=${(new Date).getTime()}`,it=this.document.querySelector("#preloadcss");this.renderer.setProperty(it,"href",J);const pt=this.document.querySelector("#customcss");this.renderer.setProperty(pt,"href",J)}checkTimer(h){!(0,r.isNil)(h.isReset)&&h.isReset&&(this.resetTimer=!1),(0,r.isNil)(h.isRefreshed)||(h.isRefreshed?this.resetTimer=!0:(this.jwtAuthService.logOut(),this.jwtAuthService.getAnonymousToken(this.storageService.eventParams).pipe((0,R.R)(this.destroy$)).subscribe({next:()=>this.resetTimer=!0}))),!(0,r.isNil)(h.hasExpired)&&h.hasExpired&&(this.resetTimer=!0)}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(_.K0),e.Y36(re),e.Y36(g.yh),e.Y36(g.yh),e.Y36(f.F0),e.Y36(ce),e.Y36(Bt.e),e.Y36(kt.n),e.Y36(Ft.p),e.Y36(G.r),e.Y36(tt.Wf),e.Y36(Y.V1),e.Y36(Dt.tH),e.Y36(T.L$),e.Y36(e.Qsj),e.Y36(Y.MR))};static#e=this.\u0275cmp=e.Xpm({type:N,selectors:[["rx-root"]],viewQuery:function(U,w){if(1&U&&(e.Gf(Ce,5),e.Gf(Pe,5),e.Gf(Ie,5)),2&U){let J;e.iGM(J=e.CRH())&&(w.headerContent=J.first),e.iGM(J=e.CRH())&&(w.flowFocusReset=J.first),e.iGM(J=e.CRH())&&(w.poweredby=J.first)}},decls:41,vars:13,consts:[["aria-live","polite",1,"sr-only"],["affix","","tabindex","0",1,"site-header"],["headerContent",""],["href","javascript:void(0)","id","skipElement",1,"skip",3,"click","keydown.enter"],[3,"regionId"],[1,"header-clearfix"],["id","base-page-top","role","main","tabindex","0",1,"base-page"],["flowFocusReset",""],[1,"rfx-footer"],[1,"is-section","is-section-auto","is-align-center","is-box","is-box","region-blocks","rfx-footer__poweredby","hide"],["poweredby",""],[1,"is-boxes"],[1,"container","is-container"],[1,"row","rfx-footer__bottom"],[1,"col-xs-12"],[1,"rfx-footer__poweredby--link"],["href","https://www.akaraisin.com/","target","_blank"],[1,"copy"],[1,"sr-only"],["xmlns","http://www.w3.org/2000/svg",0,"xmlns","xlink","http://www.w3.org/1999/xlink","version","1.1","x","0px","y","0px","viewBox","0 0 105 39.9",0,"xml","space","preserve",1,"logo"],["d","M32.7,8.7v2.6C32,10.4,31.1,9.6,30,9.1c-1.3-0.6-2.6-1-3.9-1c-1.7,0-3.2,0.3-4.6,0.9c-1.4,0.6-2.6,1.5-3.6,2.6   s-1.8,2.4-2.3,3.8c-0.5,1.4-0.8,2.9-0.8,4.5c0,1.6,0.3,3.1,0.8,4.5c0.5,1.4,1.3,2.7,2.3,3.8c1,1.1,2.2,2,3.6,2.6s2.9,0.9,4.6,0.9   c1.3,0,2.6-0.3,3.9-1c1.1-0.6,2-1.3,2.7-2.2v2.6h5.4V8.7H32.7z M26.5,26.8c-0.9,0-1.8-0.2-2.5-0.6c-0.8-0.4-1.4-0.9-2-1.5   s-1-1.3-1.3-2.2c-0.3-0.8-0.4-1.7-0.4-2.6s0.1-1.8,0.4-2.7c0.3-0.8,0.7-1.6,1.3-2.2c0.5-0.6,1.2-1.1,2-1.5s1.6-0.6,2.5-0.6   s1.8,0.2,2.6,0.6c0.8,0.4,1.4,0.9,2,1.5c0.5,0.6,1,1.3,1.3,2.2c0.3,0.8,0.5,1.7,0.5,2.7c0,0.9-0.2,1.8-0.5,2.6   c-0.3,0.8-0.7,1.6-1.3,2.2c-0.5,0.6-1.2,1.1-2,1.5C28.3,26.6,27.4,26.8,26.5,26.8z"],["d","M70.2,24.8c0,1.2-0.2,2.2-0.7,3.1s-1.1,1.6-1.9,2.2s-1.8,1-2.8,1.3c-1.1,0.3-2.2,0.4-3.4,0.4s-2.3-0.2-3.4-0.5   c-1.1-0.4-2-0.9-2.9-1.6c-0.8-0.7-1.5-1.6-2-2.6s-0.7-2.2-0.7-3.5v-0.2h5.3v0.2c0,1.4,0.4,2.4,1.1,2.9c0.8,0.6,1.7,0.9,2.9,0.9   c1,0,1.8-0.2,2.4-0.6c0.6-0.4,0.9-1,0.9-1.9c0-0.5-0.1-0.8-0.4-1.1c-0.3-0.3-0.7-0.6-1.2-0.8c-0.6-0.3-1.3-0.5-2.1-0.8   s-1.8-0.7-3-1.1c-0.8-0.3-1.5-0.6-2.1-0.9S55,19.5,54.5,19s-0.9-1-1.1-1.7c-0.2-0.7-0.4-1.5-0.4-2.5c0-1.1,0.2-2,0.7-2.8   c0.4-0.8,1.1-1.5,1.8-2.1c0.8-0.6,1.6-1,2.6-1.3s2.1-0.4,3.2-0.4c1.2,0,2.3,0.2,3.3,0.6c1,0.4,1.9,0.9,2.7,1.6   c0.8,0.7,1.4,1.5,1.8,2.4c0.5,0.9,0.7,2,0.7,3.1V16h-5.3v-0.2c0-1-0.3-1.8-0.8-2.4c-0.5-0.6-1.4-0.9-2.6-0.9   c-0.8,0-1.6,0.2-2.1,0.6c-0.6,0.4-0.8,0.9-0.8,1.7c0,0.4,0.1,0.8,0.3,1.1s0.6,0.5,1.1,0.8c0.5,0.2,1.1,0.5,1.8,0.7   c0.8,0.3,1.6,0.6,2.6,1c0.7,0.3,1.5,0.6,2.2,0.9s1.4,0.7,2,1.2s1,1.1,1.4,1.8S70.2,23.8,70.2,24.8z"],["x","73.9","y","8.7","width","5.4","height","22.4"],["d","M105,17.9v13.3h-5.4V19.6c0-0.9-0.1-1.8-0.2-2.6c-0.2-0.8-0.4-1.5-0.8-2.1c-0.3-0.6-0.8-1-1.4-1.3   C96.7,13.2,96,13,95.1,13c-1.7,0-3,0.6-3.8,1.9c-0.8,1.2-1.3,2.8-1.3,4.7v11.6h-5.4V8.7H90v2.7c0.7-1,1.5-1.8,2.6-2.3   c1.2-0.6,2.7-0.9,4.3-0.9c1.6,0,3,0.3,4.1,0.8c1.1,0.6,2,1.3,2.6,2.2c0.5,0.8,0.9,1.8,1.1,2.8C104.9,15,105,16.3,105,17.9z"],["x","43.3","y","8.8","width","5.4","height","22.4"],["d","M78.8,0.9C78.2,0.3,77.5,0,76.7,0s-1.5,0.3-2.1,0.9s-0.9,1.3-0.9,2.2c0,0.8,0.3,1.6,0.9,2.2s1.3,0.9,2.1,0.9   c0.8,0,1.6-0.3,2.2-0.9s0.9-1.3,0.9-2.2C79.7,2.2,79.4,1.5,78.8,0.9z"],["d","M48.1,34.7c-0.6-0.6-1.3-0.9-2.2-0.9c-0.8,0-1.5,0.3-2.1,0.9c-0.6,0.6-0.9,1.3-0.9,2.2c0,0.8,0.3,1.6,0.9,2.2   c0.6,0.6,1.3,0.9,2.1,0.9s1.6-0.3,2.2-0.9c0.6-0.6,0.9-1.3,0.9-2.2S48.7,35.3,48.1,34.7z"],["d","M13.6,13.6c-0.4-0.1-0.6-0.2-0.9-0.2c-0.3,0-0.6,0-1,0c-2.2,0-4,0.6-5.1,1.9c-1.2,1.3-1.8,3.4-1.8,6.2v9.7H0    V8.7h4.7v3.6c0.3-0.5,0.6-1,1.1-1.5s1-0.9,1.6-1.3c0.6-0.4,1.3-0.7,2-0.9s1.5-0.3,2.2-0.3c0.8,0,2.2,0.1,2.7,0.3L13.6,13.6z"],[3,"start","reset","tokenRefreshed"]],template:function(U,w){1&U&&(e.TgZ(0,"div",0),e._uU(1),e.ALo(2,"translate"),e.qZA(),e._UZ(3,"rx-ajax-loader"),e.TgZ(4,"header",1,2)(6,"a",3),e.NdJ("click",function(it){return w.onSkipToMain(it)})("keydown.enter",function(it){return w.onSkipToMain(it)}),e._uU(7),e.ALo(8,"translate"),e.qZA(),e._UZ(9,"rx-page-content",4)(10,"div",5),e.qZA(),e.TgZ(11,"div",6,7),e._UZ(13,"router-outlet"),e.qZA(),e.TgZ(14,"footer",8),e._UZ(15,"rx-page-content",4),e.TgZ(16,"div",9,10)(18,"div",11)(19,"div",12)(20,"div",13)(21,"div",14)(22,"div",15)(23,"a",16)(24,"div",17),e._uU(25),e.ALo(26,"translate"),e.qZA(),e.TgZ(27,"div",18),e._uU(28,"Raisin"),e.qZA(),e.O4$(),e.TgZ(29,"svg",19)(30,"g"),e._UZ(31,"path",20)(32,"path",21)(33,"rect",22)(34,"path",23)(35,"rect",24)(36,"path",25)(37,"path",26),e.TgZ(38,"g"),e._UZ(39,"path",27),e.qZA()()()()()()()()()()(),e.kcU(),e.TgZ(40,"token-expiry-check",28),e.NdJ("tokenRefreshed",function(it){return w.checkTimer(it)}),e.qZA()),2&U&&(e.xp6(1),e.Oqu(e.lcZ(2,7,w.aodaMessage)),e.xp6(6),e.Oqu(e.lcZ(8,9,"wcag_skipToMain")),e.xp6(2),e.Q6J("regionId",1e4),e.xp6(6),e.Q6J("regionId",5e4),e.xp6(10),e.hij("",e.lcZ(26,11,"footer.lblPoweredBy")," "),e.xp6(15),e.Q6J("start",w.startTimer)("reset",w.resetTimer))},dependencies:[f.lC,fe,q.Y,_e,Ee.U,P.X$],styles:[".skip{left:-9999px;top:0;padding:8px;position:absolute;z-index:40;color:#000;background-color:#fff;opacity:0}.skip:focus{transform:translate(0);opacity:1;left:0}.rfx-header--v1 .rfx-header__nav{background:transparent!important;border:none}.site-header.is-top:not(.on-home-page),.site-header.is-top.on-home-page.is-mobile{position:relative!important}.site-header.is-top:not(.on-home-page).menu-open,.site-header.is-top.on-home-page.is-mobile.menu-open{position:fixed!important}.site-header:focus{outline:red}header .header-clearfix{clear:both}.close-modal-button:focus{outline:auto}.navbar .dropdown:focus-within ul.dropdown-menu{display:block}\n"],encapsulation:2})}return N})(),jt=(()=>{class N{constructor(h){this.storageService=h}serialize(h){const U={url:(0,r.trimStart)(h.url,"/").toLowerCase(),path:(0,r.first)((0,r.trimStart)(h.url,"/").split("?")).split("/").splice(1).join("/").toLowerCase(),params:wt(h.root,w=>w.params),queryParams:wt(h.root,w=>w.queryParams),data:k(h.root)};return this.storageService.setQueryParams({...U.queryParams}),U}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(Y.V1))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac})}return N})();function wt(N,ht){return N?{...ht(N),...wt(N.children.find(w=>"primary"===w.outlet)||N.firstChild,ht)}:{}}function k(N){return N?{...N.data,...k(N.children.find(U=>"primary"===U.outlet)||N.firstChild)}:{}}var X=t(2076);let x=(()=>{class N{constructor(h){this.translate=h}resolve(h,U){return this.translate.get("btnLogin")}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(P.sK))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();var Q=t(48901);let lt=(()=>{class N{constructor(h,U,w,J){this.rdd=h,this.pageRegions=U,this.storageService=w,this.flowPageNavigatorService=J}intercept(h,U){return U.handle(h).pipe((0,o.K)(w=>this.handleError(w)))}handleError(h){if(!(0,r.isNil)(h.error)&&Q.W.NOT_FOUND===h.status&&L.NI.EventNotFound===h.error.errorType)return this.flowPageNavigatorService.navigateTo("event-not-found"),(0,u.of)(h);if(!(0,r.isNil)(h.error)&&(0,r.includes)([Q.W.FORBIDDEN,Q.W.NOT_FOUND,Q.W.BAD_REQUEST],h.status)&&this.errorRequiresRedirect(h.error)){const U=h.error;return this.storageService.setData("error",U),this.loadRegions(U),this.rdd.subEvent=U.subEvent,U.errorType===L.NI.EventEnded?this.flowPageNavigatorService.navigateTo("event-ended"):U.errorType===L.NI.EventNotStarted?this.flowPageNavigatorService.navigateTo("event-not-started"):(U.errorType===L.NI.PageNotFound||"Unable to find details for url"===h.error.message||U===L.NI.ParticipantNotFound)&&this.flowPageNavigatorService.navigateTo("not-found"),(0,u.of)(h)}return(0,mt._)(h)}errorRequiresRedirect(h){return(0,r.includes)([L.NI.EventEnded,L.NI.EventNotStarted,L.NI.PageNotFound],h.errorType)||"Unable to find details for url"===h.message||h===L.NI.ParticipantNotFound}loadRegions(h){const U=[];(0,r.isNil)(h?.regions)||Object.entries(h.regions).forEach(([w,J])=>{U.push({id:J.templateRegionId,html:J.html})}),this.pageRegions.dispatch((0,xt.ZR)({pageRegions:U}))}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(m.n),e.LFG(g.yh),e.LFG(Y.V1),e.LFG(O.P))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})();var Et=t(56223),yt=t(77892),$t=t(99163);function Le(N,ht){if(1&N){const h=e.EpF();e.TgZ(0,"a",1),e.NdJ("click",function(w){e.CHM(h);const J=e.oxw();return e.KtG(J.getOtherLanguageLocationUrl(w))}),e.TgZ(1,"span",2),e._uU(2),e.qZA(),e.TgZ(3,"span",3),e._uU(4),e.qZA(),e.TgZ(5,"span",4),e._uU(6),e.qZA()()}if(2&N){const h=e.oxw();e.ekj("has-languages",h.showLanguagePicker),e.s9C("lang",h.selectedLanguage.shortName),e.Q6J("target",h.linkTarget),e.xp6(2),e.Oqu(h.selectedLanguage.displayName),e.xp6(2),e.Oqu(h.selectedLanguage.displayName),e.xp6(2),e.Oqu(h.selectedLanguage.shortName)}}let Me=(()=>{class N{constructor(h,U,w,J,it){this.rdd=h,this.flowPageValidationService=U,this.browserDetectionService=w,this.authService=J,this.raisinRouter=it,this.cssClass=!0}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}ngOnInit(){this.destroy$=new E.x,this.rdd.languages&&this.rdd.languages.length>1&&(this.languages=this.getOtherLanguagesAvailable(),this.languages.length>0&&(this.selectedLanguage=this.languages[0])),this.authService.loggedInStatus().pipe((0,R.R)(this.destroy$),(0,c.h)(h=>!h)).subscribe(h=>{const U=this.flowPageValidationService.getLocationPath();this.updateShowLanguagePicker(U,h)}),this.raisinRouter.pipe((0,R.R)(this.destroy$),(0,g.Ys)(b.sf),(0,c.h)(h=>!(0,r.isEmpty)(h?.params)),(0,A.U)(h=>h.path)).subscribe(h=>{this.updateShowLanguagePicker(h,this.authService.isAuthenticated())}),this.linkTarget=this.browserDetectionService.isIE()?"_self":""}getOtherLanguageLocationUrl(h){h.preventDefault();const U=this.getWindowLocation(),w=U.href.split("/");this.rdd.hasError&&(w[w.length-1]="");let J=(0,r.filter)(this.rdd.languages,pt=>pt.languageId!=this.languages[0].languageId)[0];const it=U.pathname.toLowerCase().replace(J.url.toLowerCase(),this.languages[0].url.toLowerCase());this.setLocationHref(window.location,U.href.toLowerCase().replace(U.pathname.toLowerCase(),it))}getWindowLocation(){return window.location}setLocationHref(h,U){h.href=U}getOtherLanguagePageUrl(){return(0,r.filter)((0,r.get)(this.rdd,"pageSettings.urls",[]),h=>h.languageId!==this.rdd.languageId)}getOtherLanguagesAvailable(){return(0,r.filter)(this.rdd.languages||[],h=>h.languageId!==this.rdd.languageId)}updateShowLanguagePicker(h,U){if((0,r.isEmpty)(this.languages)||U)this.showLanguagePicker=!1;else if(this.rdd.hasError)this.showLanguagePicker=!0;else if((0,r.isEmpty)(h)||(0,r.isEmpty)(this.flowPageValidationService.isFlow(h)))this.showLanguagePicker=!0;else{let J=this.flowPageValidationService.isFlowStart(h);this.showLanguagePicker=J}}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(m.n),e.Y36(Ft.p),e.Y36(Ot.p),e.Y36(S.$),e.Y36(g.yh))};static#e=this.\u0275cmp=e.Xpm({type:N,selectors:[["rx-language-picker"]],hostVars:2,hostBindings:function(U,w){2&U&&e.ekj("language-picker-container",w.cssClass)},decls:1,vars:1,consts:[["class","language-picker","href","javascript:void(0)",3,"has-languages","target","lang","click",4,"ngIf"],["href","javascript:void(0)",1,"language-picker",3,"target","lang","click"],[1,"sr-only"],[1,"visible-xs","visible-sm"],[1,"hidden-xs","hidden-sm"]],template:function(U,w){1&U&&e.YNc(0,Le,7,7,"a",0),2&U&&e.Q6J("ngIf",w.showLanguagePicker)},dependencies:[_.O5],encapsulation:2})}return N})();function Ue(N,ht){if(1&N){const h=e.EpF();e.TgZ(0,"rx-login-modal",6),e.NdJ("closeLogin",function(){e.CHM(h);const w=e.oxw(2);return e.KtG(w.toggleLoginModal())}),e.qZA()}}function Fe(N,ht){if(1&N){const h=e.EpF();e.TgZ(0,"div")(1,"a",2),e.NdJ("click",function(){e.CHM(h);const w=e.oxw();return e.KtG(w.toggleLoginModal())}),e.qZA(),e.TgZ(2,"div",3,4),e._uU(4),e.qZA(),e.YNc(5,Ue,1,0,"rx-login-modal",5),e.qZA()}if(2&N){const h=e.oxw();e.xp6(1),e.Q6J("innerHTML",h.rxLoginButtonText,e.oJD),e.xp6(3),e.Oqu(h.loginAriaState),e.xp6(1),e.Q6J("ngIf",h.isLoginModalVisible)}}function we(N,ht){if(1&N){const h=e.EpF();e.TgZ(0,"a",7),e.NdJ("click",function(){e.CHM(h);const w=e.oxw();return e.KtG(w.goToMyAccount())}),e.qZA()}if(2&N){const h=e.oxw();e.Q6J("innerHTML",h.lblManageAccount,e.oJD)}}let Ne=(()=>{class N{constructor(h,U,w,J,it,pt){this.jwtAuthService=h,this.authService=U,this.element=w,this.browserDetectionService=J,this.storageService=it,this.translate=pt,this.$destroy=new E.x}mouseClickOutsideOfElement(h){(!this.element.nativeElement.contains(h.target)||"usernameLink"===(0,r.get)(h.target,"id")||"passwordLink"===(0,r.get)(h.target,"id"))&&this.closeLoginModal()}documentScrolled(){this.browserDetectionService.isIPhone()||(this.closeLoginModal(),this.loginAriaState="")}ngOnInit(){if(this.isLoginModalVisible=this.storageService.getData(ft.z1.OpenLoginModalKey)||!1,this.isLoggedIn=this.jwtAuthService.isLoggedIn(),this.jwtAuthService.loggedInStatus.pipe((0,R.R)(this.$destroy)).subscribe(h=>{this.isLoggedIn=h}),!(0,r.isEmpty)(this.rxLoginButtonText)){const h=this.rxLoginButtonText.replace(/(<([^>]+)>)/gi,"");this.translate.get("lblMyAccount").subscribe(U=>this.lblManageAccount=(0,r.replace)(this.rxLoginButtonText,h,U))}}ngOnDestroy(){this.$destroy.next()}goToMyAccount(){this.authService.goToParticipantCentre(this.jwtAuthService.getJWT(),this.storageService.getLanguage(),this.jwtAuthService.getRoles(),this.jwtAuthService.isFirstLogin())}openLoginModal(){this.isLoginModalVisible=!0,this.loginAriaState=this.translate.instant("wcag.status.login_modal_open")}toggleLoginModal(){this.isLoginModalVisible?(this.closeLoginModal(),this.loginAriaState=this.translate.instant("wcag.status.login_modal_closed")):this.openLoginModal()}closeLoginModal(){this.storageService.removeData(ft.z1.OpenLoginModalKey),this.isLoginModalVisible=!1}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(Dt.tH),e.Y36(S.$),e.Y36(e.SBq),e.Y36(Ot.p),e.Y36(Y.V1),e.Y36(P.sK))};static#e=this.\u0275cmp=e.Xpm({type:N,selectors:[["rx-login-modal-button"]],hostBindings:function(U,w){1&U&&e.NdJ("click",function(it){return w.mouseClickOutsideOfElement(it)},!1,e.evT)("scroll",function(it){return w.documentScrolled(it)},!1,e.evT)},inputs:{rxLoginButtonText:"rxLoginButtonText"},decls:3,vars:2,consts:[[4,"ngIf"],["href","javascript:void(0)","class","rs-header-button my-account-btn",3,"innerHTML","click",4,"ngIf"],["href","javascript:void(0)",1,"rs-header-button","login-btn",3,"innerHTML","click"],["aria-live","assertive",1,"sr-only"],["loginAria",""],["inNav","true",3,"closeLogin",4,"ngIf"],["inNav","true",3,"closeLogin"],["href","javascript:void(0)",1,"rs-header-button","my-account-btn",3,"innerHTML","click"]],template:function(U,w){1&U&&(e.TgZ(0,"div"),e.YNc(1,Fe,6,3,"div",0),e.YNc(2,we,1,1,"a",1),e.qZA()),2&U&&(e.xp6(1),e.Q6J("ngIf",!w.isLoggedIn),e.xp6(1),e.Q6J("ngIf",w.isLoggedIn))},dependencies:[_.O5,bt],styles:[".rs-header-button{display:block;cursor:pointer}\n"],encapsulation:2})}return N})();var Be=t(65619),ke=t(46290),Ke=t(52572);let We=(()=>{class N{constructor(h,U,w){this.rdd=h,this.translate=U,this.placeholderService=w}processRegionDataModule(h){$(h).find("[data-module='slider'], [data-module='video'], [data-module='code']").each(()=>{(0,r.isNil)($(this).attr("data-html"))||$(this).html(decodeURIComponent($(this).attr("data-html").replace(/\+/g,"%20")))})}replacePlaceHolders(h){return this.placeholderService.hasPlaceholder(h)?this.placeholderService.replace(h,null):h||""}processImages(h){return this.placeholderService.hasPlaceholder(h)&&this.placeholderService.replace(h,null),h}setHeaderLinks(h){let U=(0,r.cloneDeep)(h);return(0,Ke.a)([this.translate.get("m_str_Logout"),this.translate.get("str_ParticipantCentre")]).pipe((0,A.U)(([w,J])=>(this.logoutLabel=w,this.pcLinkText=J,U=this.setHeaderLoginLink(U),U=this.setRegistrationLinks(U),U)))}setHeaderLoginLink(h){const w=/<\s*a[^>]* href=".*?\/(login.aspx).*?">(<span>|)([^<]*)(<\/span>|<\/a>)/gm.exec(h);if(w.length>0){const J=(0,r.clone)(w[0]);w[0]=w[0].replace(w[1],"logout.aspx"),w[0]=w[0].replace(w[2]+w[3]+w[4],w[2]+this.logoutLabel+w[4]),h=(h=h.replace(J,w[0])).replace("icon_login.png","icon_logout.png")}return h}setRegistrationLinks(h){let U=/<\s*a[^>]* href="(\/ui\/([^\/]*)\/pledge\/registration\/start).*?">([^<]*)<\/a>/gm,w=U.exec(h);if((0,r.isNil)(w)&&(U=/<\s*a[^>]* href="(\/ui\/([^\/]*)\/pledge\/registration\/start).*?"><span>([^<]*)<\/span><\/a>/gm,w=U.exec(h)),w.length>0){const J=(0,r.clone)(w[0]);w[0]=w[0].replace(w[1],`/Common/Participant/Admin.aspx?seid=${this.rdd.subEventId}`),w[0]=w[0].replace(w[3],this.pcLinkText),w[0]=w[0].replace('class="pcBtnIcon"','class="pcBtnIcon display-inline"'),h=h.replace(J,w[0])}return h}static#t=this.\u0275fac=function(U){return new(U||N)(e.LFG(m.n),e.LFG(P.sK),e.LFG(ke.Q))};static#e=this.\u0275prov=e.Yz7({token:N,factory:N.\u0275fac,providedIn:"root"})}return N})(),Ge=(()=>{class N{constructor(h,U,w,J){this.element=h,this.renderer=U,this.authService=w,this.pageContentProcessingService=J,this.cssClass="rfx-header__actions login-actions",this.isLoggedIn$=new Be.X(this.authService.isAuthenticated())}ngOnDestroy(){this.isLoggedIn$.unsubscribe()}ngOnInit(){this.isLoggedIn$.pipe((0,d.w)(h=>h?this.pageContentProcessingService.setHeaderLinks(this.html):(0,u.of)(this.html))).subscribe(h=>{this.html=h,this.renderer.setProperty(this.element.nativeElement,"innerHTML",h)})}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(e.SBq),e.Y36(e.Qsj),e.Y36(S.$),e.Y36(We))};static#e=this.\u0275cmp=e.Xpm({type:N,selectors:[["rx-login-actions"]],hostVars:2,hostBindings:function(U,w){2&U&&e.Tol(w.cssClass)},inputs:{html:"html"},decls:0,vars:0,template:function(U,w){},styles:[".login-actions{margin:0 auto!important;display:inline-block}.pcBtnIcon.display-inline{display:inline-block!important;height:21px!important}\n"],encapsulation:2})}return N})(),He=(()=>{class N{constructor(){}static#t=this.\u0275fac=function(U){return new(U||N)};static#e=this.\u0275mod=e.oAB({type:N});static#i=this.\u0275inj=e.cJS({providers:[S.$,m.n],imports:[_.ez,T.U1]})}return N})();function je(N,ht){if(1&N&&(e.ynx(0),e._UZ(1,"a",1),e.BQk()),2&N){const h=e.oxw();e.xp6(1),e.s9C("href",h.linkurl,e.LSH),e.Q6J("innerHtml",h.text,e.oJD)}}let $e=(()=>{class N{constructor(h,U){this.jwtAuthService=h,this.storageService=U,this.wrapper="nav-register-button"}ngOnInit(){this.linkurl=`/ui/${this.storageService.eventParams.subEventCustomPart}/pledge/registration/start`,this.showButton$=this.jwtAuthService.loggedInStatus.asObservable().pipe((0,A.U)(h=>!h))}static#t=this.\u0275fac=function(U){return new(U||N)(e.Y36(Dt.tH),e.Y36(Y.V1))};static#e=this.\u0275cmp=e.Xpm({type:N,selectors:[["rx-nav-register-button"]],hostVars:2,hostBindings:function(U,w){2&U&&e.Tol(w.wrapper)},inputs:{text:"text"},decls:2,vars:3,consts:[[4,"ngIf"],[1,"rs-header-button","reg-btn",3,"href","innerHtml"]],template:function(U,w){1&U&&(e.YNc(0,je,2,2,"ng-container",0),e.ALo(1,"async")),2&U&&e.Q6J("ngIf",e.lcZ(1,1,w.showButton$))},dependencies:[_.O5,_.Ov],encapsulation:2})}return N})();var Ze=t(28910),Ve=t(73989),ze=t(399),Je=t(21772);t(36169),t(43520),(0,_.qS)(n.Z,"fr-CA");let Ye=(()=>{class N{static#t=this.\u0275fac=function(U){return new(U||N)};static#e=this.\u0275mod=e.oAB({type:N,bootstrap:[Se]});static#i=this.\u0275inj=e.cJS({providers:[{provide:T.Gv,useValue:D.N},{provide:I.TP,useClass:lt,multi:!0},{provide:Lt.GC,useClass:jt},{provide:e.qLn,useClass:tt.td},{provide:Dt.$h,useClass:Dt.tH},x,T.L$,Ve.W,Y.iv],imports:[s.b2,i.PW,Yt,Vt,Et.u5,Et.UX,yt.Q,I.JF,ze.Al,P.aw.forRoot({loader:{provide:P.Zw,useFactory:h=>new a.w(h,"ui/assets/i18n/",".json?v=4.4.1810"),deps:[I.eN]}}),T.Dt.forRoot(),y.T,g.Aw.forRoot({router:Lt.mg},{metaReducers:[],runtimeChecks:{strictActionImmutability:!0,strictStateImmutability:!0}}),Qt.sQ.forRoot([]),D.N.production?[]:Xt.FT.instrument(),Lt.Qi.forRoot({navigationActionTiming:Lt.R0.PreActivation,serializer:jt}),xt.PS,X.e,He,j.a,Dt.B$.forRoot(!1),T.Dt.forRoot(),$t.Du.forRoot({components:[{component:Me,selector:"rx-language-picker"},{component:Ne,selector:"rx-login-modal-button"},{component:$e,selector:"rx-nav-register-button"},{component:Ge,selector:"rx-login-actions"},{component:T.jL,selector:"rx-social-share"}]}),Ze._,Je.VG,tt.YV]})}return N})();D.N.production&&(0,e.G48)(),s.q6().bootstrapModule(Ye).catch(N=>console.error(N))},78356:(Z,K,t)=>{"use strict";t.d(K,{PS:()=>ft,UA:()=>d,Io:()=>A,zv:()=>n,_b:()=>e,r8:()=>_,ZR:()=>i});var s=t(13423);const e=(0,s.PH)("[PageRegions] Load Header and Footer Regions"),_=(0,s.PH)("[PageRegions] Load Page Content Regions",(0,s.Ky)()),n=(0,s.PH)("[PageRegions] Load Entity Regions",(0,s.Ky)()),i=(0,s.PH)("[PageRegions] Load PageRegions Success",(0,s.Ky)()),P=(0,s.PH)("[PageRegions] Load Header and Footer Regions Success",(0,s.Ky)()),D=(0,s.PH)("[PageRegions] Load PageRegions Failure",(0,s.Ky)());var I=t(36293);const T="pageRegions",a=(0,I.H)(),y=a.getInitialState({loaded:!1}),f=(0,s.Lq)(y,(0,s.on)(e,G=>({...G,loaded:!1,error:null})),(0,s.on)(_,(G,{})=>({...G,loaded:!1,error:null})),(0,s.on)(P,(G,{pageRegions:vt})=>a.upsertMany(vt,{...G,loaded:!0})),(0,s.on)(i,(G,{pageRegions:vt})=>a.upsertMany(vt,{...G,loaded:!0})),(0,s.on)(D,(G,{error:vt})=>({...G,error:vt})));function r(G,vt){return f(G,vt)}const u=(0,s.ZF)(T),{selectAll:C,selectEntities:L}=a.getSelectors(),d=((0,s.P1)(u,G=>G.loaded),(0,s.P1)(u,G=>G.error),(0,s.P1)(u,G=>C(G)),(0,s.P1)(u,G=>L(G))),A=(0,s.P1)(u,(G,vt)=>L(G)[vt]),S=(0,s.P1)(u,G=>G.selectedId);(0,s.P1)(d,S,(G,vt)=>vt&&G[vt]);var b=t(6990),M=t(58504),R=t(22096),B=t(99397),E=t(37398),m=t(26306),p=t(21875),O=function(G){return G[G.NoModule=0]="NoModule",G[G.RegistrationStart=60]="RegistrationStart",G[G.IndividualRegistration=1]="IndividualRegistration",G[G.JoinTeamRegistration=3]="JoinTeamRegistration",G[G.CreateTeamRegistration=5]="CreateTeamRegistration",G[G.PledgeParticipantHomePage=9]="PledgeParticipantHomePage",G[G.PledgeTeamHomePage=10]="PledgeTeamHomePage",G[G.PledgeSponsor=22]="PledgeSponsor",G[G.PledgeVisitorJoinATeam=23]="PledgeVisitorJoinATeam",G[G.Store=27]="Store",G[G.PledgeDonateToEvent=29]="PledgeDonateToEvent",G[G.VolunteerRegistration=80]="VolunteerRegistration",G[G.GroupHomePage=82]="GroupHomePage",G[G.GroupsList=83]="GroupsList",G[G.Pledge_ParticipantAdmin=11]="Pledge_ParticipantAdmin",G[G.TicketingEvent=85]="TicketingEvent",G[G.TicketingDonation=87]="TicketingDonation",G[G.TicketingCart=88]="TicketingCart",G[G.Donations=89]="Donations",G[G.ForgotUsername=90]="ForgotUsername",G[G.ForgotPassword=91]="ForgotPassword",G[G.PasswordReset=92]="PasswordReset",G}(O||{}),F=function(G){return G[G.ParticipantHome_Pledge=5]="ParticipantHome_Pledge",G[G.TeamHome=7]="TeamHome",G[G.GroupHome=172]="GroupHome",G[G.GroupsList=174]="GroupsList",G[G.Ticketing_YourProfile=202]="Ticketing_YourProfile",G[G.Ticketing_YourPurchases=201]="Ticketing_YourPurchases",G[G.Ticketing_ManageAttendees=203]="Ticketing_ManageAttendees",G[G.Ticketing_Review=70]="Ticketing_Review",G[G.DonationsSuccess=118]="DonationsSuccess",G[G.EventNotAvailable=99]="EventNotAvailable",G[G.ForgotUsername=204]="ForgotUsername",G[G.ForgotPassword=206]="ForgotPassword",G[G.PasswordReset=207]="PasswordReset",G[G.PasswordResetSuccess=208]="PasswordResetSuccess",G}(F||{}),H=function(G){return G[G.NoRegion=0]="NoRegion",G[G.ParticipantTitle=247]="ParticipantTitle",G[G.ParticipantImages=280]="ParticipantImages",G[G.ParticipantMainImage=19]="ParticipantMainImage",G[G.ParticipantJourney=21]="ParticipantJourney",G[G.TeamTitle=250]="TeamTitle",G[G.TeamImages=281]="TeamImages",G[G.TeamMainImage=23]="TeamMainImage",G[G.TeamJourney=24]="TeamJourney",G[G.LocalSponsors=369]="LocalSponsors",G[G.HeaderRegion=1e4]="HeaderRegion",G[G.FooterRegion=5e4]="FooterRegion",G[G.AboveSystemContentRegion=2e4]="AboveSystemContentRegion",G[G.BelowSystemContentRegion=3e4]="BelowSystemContentRegion",G[G.SideContentRegion=4e4]="SideContentRegion",G}(H||{}),W=t(65879),tt=t(69862),j=t(89515);let z=(()=>{class G{constructor(rt,Y,gt){this.storageService=rt,this.http=Y,this.translate=gt}get baseAPIUrl(){return this.storageService.getData("baseAPIUrl")||(0,b.get)(window,"raisin_dd.baseAPIUrl")}loadHeaderAndFooter(){return this.http.get(`${this.baseAPIUrl}/pagecontent/headerfooter`).pipe((0,B.b)(rt=>console.debug("loadHeaderAndFooter",rt)),(0,E.U)(rt=>this.convertToEntity(rt)),(0,E.U)(rt=>(0,b.map)(rt,Y=>(Y.id===H.HeaderRegion&&(Y.html=this.processHeader(Y.html)),Y))),(0,m.K)(rt=>(console.debug("loadHeaderAndFooter catch",rt),(0,M._)(rt))))}loadPageRegionsByPageUrl(rt){let Y=rt.pageUrl;return Y&&Y.length>0&&"/"!==Y&&((0,b.endsWith)(Y,"/")&&(Y=(0,b.trimEnd)(Y,"/")),(0,b.startsWith)(Y,"/")&&(Y=(0,b.trimStart)(Y,"/"))),this.pageUrl===Y?(console.debug("loadPageRegionsByPageUrl is already loaded","pageUrl",Y),(0,R.of)(null)):"/"===Y?(console.debug("loadPageRegionsByPageUrl is home page","pageUrl",Y),this.pageUrl=Y,this.loadPageRegions(8,3)):Y?.toLowerCase()?.endsWith("not-found")?(this.pageUrl=Y,this.loadPageRegions(0,182)):["forgot-username","forgot-password","attendees","purchases","profile"].includes(Y)||(0,b.startsWith)(Y,"password-reset")?this.loadPageRegions(8,3).pipe((0,E.U)(gt=>this.clearAboveSystemContentRegion(gt)),(0,B.b)(()=>{switch(Y){case"forgot-username":this.moduleId=O.ForgotUsername,this.pageId=F.ForgotUsername,this.pageUrl=Y;break;case"forgot-password":this.moduleId=O.ForgotPassword,this.pageId=F.ForgotPassword,this.pageUrl=Y;break;case"password-reset":this.moduleId=O.PasswordReset,this.pageId=F.PasswordReset,this.pageUrl=Y;break;case"password-reset/success":this.moduleId=O.PasswordReset,this.pageId=F.PasswordResetSuccess,this.pageUrl=Y;break;case"attendees":this.moduleId=O.TicketingEvent,this.pageId=F.Ticketing_ManageAttendees,this.pageUrl=Y;break;case"purchases":case"profile":this.moduleId=O.TicketingEvent,this.pageId=F.Ticketing_YourPurchases,this.pageUrl=Y;break;default:return void console.debug("invalid page Url for flow","pageUrl",Y)}console.debug("flow","moduleId",this.moduleId,"pageId",this.pageId)})):(0,b.includes)(Y,"oneall")?(0,R.of)():(((0,b.isNil)(this.moduleId)||0===this.moduleId)&&(this.moduleId=this.storageService.getData("mid")),console.debug("loadPageRegionsByPageUrl pageUrl",`${this.baseAPIUrl}/pagecontent/page/${+this.moduleId}`,Y),this.http.get(`${this.baseAPIUrl}/pagecontent/page/${+this.moduleId}`,{params:{pageUrl:Y}}).pipe((0,B.b)(()=>{this.pageUrl=Y,this.moduleId=0,this.pageId=0}),(0,B.b)(gt=>console.debug("loadPageRegionsByPageUrl","pageUrl",Y,gt)),(0,E.U)(gt=>this.convertToEntity(gt)),(0,m.K)(gt=>(console.debug("loadPageRegionsByPageUrl catch","pageUrl",Y),(0,M._)(gt)))))}loadEntityRegions(rt){return this.entityId===rt.entityId&&this.pageUrl===rt.pageUrl?(console.debug("loadPageRegions matching","entityId",rt.entityId,"url",rt.pageUrl),(0,R.of)(null)):(this.clearProperties(),this.http.get(`${this.baseAPIUrl}/pagecontent/entity/${rt.pageUrl}/${rt.entityId}`).pipe((0,B.b)(Y=>{console.debug("loadEntityRegions get","entityId",rt.entityId,"url",rt.pageUrl,Y),this.entityId=rt.entityId,this.pageUrl=rt.pageUrl}),(0,E.U)(Y=>this.convertToEntity(Y)),(0,m.K)(Y=>(console.debug("loadEntityRegions catch","entityId",rt.entityId,"url",rt.pageUrl),(0,M._)(Y)))))}loadPageRegions(rt,Y){const gt=this.storageService.eventParams.subEventCustomPart;return this.moduleId===rt&&this.pageId===Y&&this.subEventPart===gt?(console.debug("loadPageRegions matching","moduleId",rt,"pageId",Y),(0,R.of)(null)):(this.clearProperties(),this.http.get(`${this.baseAPIUrl}/pagecontent/page/${rt}/${Y}`).pipe((0,B.b)(ct=>console.debug("loadPageRegions get","moduleId",rt,"pageId",Y,ct)),(0,B.b)(ct=>{this.moduleId=rt,this.pageId=Y,this.subEventPart=gt}),(0,E.U)(ct=>this.convertToEntity(ct)),(0,m.K)(ct=>(console.debug("loadPageRegions catch","moduleId",rt,"pageId",Y),(0,M._)(ct)))))}convertToEntity(rt){const Y=[];return Object.entries(rt).forEach(([gt,ct])=>{Y.push({id:ct.templateRegionId,html:(0,b.isEmpty)(ct.html)?" ":ct.html})}),Y}clearProperties(){this.moduleId=0,this.pageId=0,this.pageUrl="",this.entityId=0,console.debug("PageRegionsService clearProperties")}clearAboveSystemContentRegion(rt){return(0,b.isEmpty)(rt)?[{id:H.AboveSystemContentRegion,html:" "},{id:H.BelowSystemContentRegion,html:" "}]:(0,b.map)(rt,Y=>((Y.id===H.AboveSystemContentRegion||Y.id===H.BelowSystemContentRegion)&&(Y.html=" "),Y))}processHeader(rt){let Y=(0,b.cloneDeep)(rt);return Y=Y.replace(/<a href="\/Common\/Login\/login\.aspx\?seid=(.+?)>(.*?)<\/a>/,'<rx-login-modal-button rx-login-button-text="$2"></rx-login-modal-button>'),Y=Y.replace(/<a[^>]*href="\/ui\/([^\/]*)\/pledge\/registration\/start"[^>]*>([^~].*?)<\/a>/,'<rx-nav-register-button text="$2"></rx-nav-register-button>'),Y=Y.replace("pull-left rfx-header__lang","pull-right rfx-header__lang"),Y=Y.replace("Toggle Right navigation",this.translate.instant("btn_Mobile_Nav_Toggle")),Y}static#t=this.\u0275fac=function(Y){return new(Y||G)(W.LFG(p.V1),W.LFG(tt.eN),W.LFG(j.sK))};static#e=this.\u0275prov=W.Yz7({token:G,factory:G.\u0275fac,providedIn:"root"})}return G})();var q=t(96814),at=t(14721),nt=t(68298),et=t(32181);let o=(()=>{class G{constructor(rt,Y){this.actions$=rt,this.pageRegionsService=Y,this.loadHeaderFooterRegions$=(0,at.GW)(()=>this.actions$.pipe((0,at.l4)(e),(0,nt.he)({run:gt=>this.pageRegionsService.loadHeaderAndFooter().pipe((0,B.b)(ct=>console.debug("loadHeaderFooterRegions$",ct)),(0,E.U)(ct=>P({pageRegions:ct}))),onError:(gt,ct)=>(console.error("Error",ct),D({error:ct}))}))),this.loadPageContentRegions$=(0,at.GW)(()=>this.actions$.pipe((0,at.l4)(_),(0,nt.he)({run:gt=>this.pageRegionsService.loadPageRegionsByPageUrl(gt).pipe((0,et.h)(ct=>!(0,b.isNil)(ct)),(0,E.U)(ct=>i({pageRegions:ct}))),onError:(gt,ct)=>(console.error("Error",ct),D({error:ct}))}))),this.loadEntityRegions$=(0,at.GW)(()=>this.actions$.pipe((0,at.l4)(n),(0,nt.he)({run:gt=>this.pageRegionsService.loadEntityRegions(gt).pipe((0,et.h)(ct=>!(0,b.isNil)(ct)),(0,E.U)(ct=>i({pageRegions:(0,b.isEmpty)(gt.regions)?ct:(0,b.filter)(ct,ot=>(0,b.includes)(gt.regions,ot.id))}))),onError:(gt,ct)=>(console.error("Error",ct),D({error:ct}))})))}static#t=this.\u0275fac=function(Y){return new(Y||G)(W.LFG(at.eX),W.LFG(z))};static#e=this.\u0275prov=W.Yz7({token:G,factory:G.\u0275fac})}return G})();var mt=t(72550);let ft=(()=>{class G{static#t=this.\u0275fac=function(Y){return new(Y||G)};static#e=this.\u0275mod=W.oAB({type:G});static#i=this.\u0275inj=W.cJS({imports:[tt.JF,mt.U1,q.ez,s.Aw.forFeature(T,r),at.sQ.forFeature([o])]})}return G})()},87181:(Z,K,t)=>{"use strict";t.d(K,{gY:()=>u,a:()=>c,r1:()=>l});var s=t(96814),e=t(69862),_=t(58504),n=t(65619),i=t(22096),P=t(78645),D=t(2459),I=t(6990),T=t(32181),a=t(48180),y=t(94664),f=function(d){return d.paymentValidation="PGValidation",d.constituentSubmission="SubmitConstituent",d.notSet="",d}(f||{}),r=t(65879);let u=(()=>{class d{get grecaptcha(){return window.grecaptcha}constructor(S,v){this.document=S,this.rendererFactory=v,this.action="",this.scriptElementId="recaptchaScript",this.configInitialized$=new n.X(!1),this.renderer=this.rendererFactory.createRenderer(null,null),this.enabled=!1,this.hppEnabled=!1,this.scoreBasedKey="",this.checkboxKey="",this.recaptchaEnterpriseScriptUrl="",this.currentMode="none",this.checkboxWidgetId="",this.langResources={currentLang:"",errCheckboxCaptchaRequired:""},this.captchaError$=new n.X(null),this.checkBoxCaptchaSuccess$=new n.X(null)}initialize(S,v,b,M,R,B){return this.scoreBasedKey=b,this.checkboxKey=M,this.recaptchaEnterpriseScriptUrl=R,this.enabled=S&&!(0,I.isEmpty)(b)&&!(0,I.isEmpty)(R),this.hppEnabled=v,this.langResources=B,this.configInitialized$.next(!0),(0,i.of)(this.enabled)}waitForConfig(){return this.configInitialized$.pipe((0,T.h)(I.identity),(0,a.q)(1))}initializeScoreCaptcha(){if(this.enabled&&this.scoreBasedKey&&this.recaptchaEnterpriseScriptUrl){if("score"===this.currentMode)return console.debug("Score Captcha already initialized"),(0,i.of)(!0);console.debug("Init Score Captcha");const S=`${this.recaptchaEnterpriseScriptUrl}?render=${this.scoreBasedKey}&hl=${this.googleLangCode()}`;return this.appendCaptchaScript(S),this.currentMode="score",(0,i.of)(!0)}return(0,i.of)(!1)}initializeCheckboxCaptcha(S){if(this.enabled&&this.checkboxKey&&this.recaptchaEnterpriseScriptUrl){if(this.action=S,"checkbox"===this.currentMode)return console.debug("Checkbox Captcha already initialized"),this.resetCheckboxToInitialState(),(0,i.of)(!0);if(console.debug("Init Checkbox Captcha"),!this.recaptchaCheckbox?.nativeElement)return console.debug("Could not initialize checkbox captcha because recaptchaCheckbox element is null."),(0,i.of)(!1);const v=this.registerCheckboxCallbackFunction(this.recaptchaCheckbox.nativeElement,this.checkboxKey),b=`${this.recaptchaEnterpriseScriptUrl}?render=explicit&onload=raisinCheckboxCaptchaOnload&hl=${this.googleLangCode()}`;return this.appendCaptchaScript(b),v.pipe((0,y.w)(M=>(this.currentMode="checkbox",this.checkboxWidgetId=M,this.recaptchaCheckbox.nativeElement.classList.add("captcha_ready"),(0,i.of)(!0))))}return(0,i.of)(!1)}resetCheckboxToInitialState(){this.checkBoxCaptchaSuccess$.next(!1),this.renderer.setProperty(this.recaptchaCheckbox?.nativeElement,"style","display: block;"),this.grecaptcha.enterprise.reset(this.checkboxWidgetId)}registerCheckboxCallbackFunction(S,v){const b=new P.x;return window.raisinCheckboxCaptchaOnload=()=>{console.debug("grecaptcha checkbox is ready");const M=this.grecaptcha.enterprise.render(S,{sitekey:v,callback:R=>this.recaptchaCallBackOnSuccess(R)});b.next(M),b.complete()},b}recaptchaCallBackOnSuccess(S){return!(0,I.isEmpty)(S)&&(this.checkBoxCaptchaSuccess$.next(!0),this.action===f.paymentValidation&&this.renderer.setProperty(this.recaptchaCheckbox?.nativeElement,"style","display: none;"),!0)}reset(){return this.emitReCaptchaErrorClear(),this.initializeScoreCaptcha()}execute(S){return"checkbox"===this.currentMode?(this.action=S,(0,i.of)(this.grecaptcha.enterprise.getResponse(this.checkboxWidgetId))):(0,D.D)(this.grecaptcha.enterprise.execute(this.scoreBasedKey,{action:S}))}getReCaptchaErrorCode(S){return(0,I.get)(S,"error.result.data.reCaptchaErrorCode",null)}appendCaptchaScript(S){this.document.getElementById(this.scriptElementId)?.remove();const v=this.renderer.createElement("script");v.id=this.scriptElementId,v.type="text/javascript",v.src=S,v.defer=!0,this.renderer.appendChild(this.document.body,v)}setReCaptchaRetry(S,v){let b=(0,I.cloneDeep)(S);return b=(0,I.set)(b,"error.result.data.reCaptchaMode",this.currentMode),b=(0,I.set)(b,"error.result.data.reCaptchaRetry",v),b}emitReCaptchaErrorClear(){this.captchaError$.next(null)}emitReCaptchaCheckboxRequiredError(S){this.captchaError$.next({message:(0,I.get)(this.langResources,"errCheckboxCaptchaRequired"),errorCode:void 0,reCaptchaErrorCode:this.getReCaptchaErrorCode(S)})}googleLangCode(){return"fr-CA"===(0,I.get)(this.langResources,"currentLang")?"fr-CA":"en"}reCaptchaHppConfigEnabled(){return this.hppEnabled}static#t=this.\u0275fac=function(v){return new(v||d)(r.LFG(s.K0),r.LFG(r.FYo))};static#e=this.\u0275prov=r.Yz7({token:d,factory:d.\u0275fac,providedIn:"root"})}return d})();var C=t(26306),L=function(d){return d[d.None=0]="None",d[d.ScoreNotMet=1]="ScoreNotMet",d[d.ScoreNotValid=2]="ScoreNotValid",d[d.CheckboxScoreNotMet=3]="CheckboxScoreNotMet",d[d.CheckboxNotValid=4]="CheckboxNotValid",d}(L||{});let g=(()=>{class d{constructor(S){this.googleReCaptchaService=S}isPostRequestRequireVerification(S){return(/^(.+?)(\/v2\/(constituent))/gi.test(S.url)||/^(.+?)(\/v2\/(payment\/hpp-config))/gi.test(S.url)&&this.googleReCaptchaService.reCaptchaHppConfigEnabled())&&"POST"===S.method}intercept(S,v){return this.googleReCaptchaService.enabled&&this.isPostRequestRequireVerification(S)?(this.googleReCaptchaService.emitReCaptchaErrorClear(),this.interceptCaptchaPostRequest(S,v).pipe((0,C.K)(b=>{const M=this.googleReCaptchaService.getReCaptchaErrorCode(b);return null!==M&&M!==L.None?this.googleReCaptchaService.initializeCheckboxCaptcha(this.getCaptchaTrigger(S)).pipe((0,y.w)(R=>R?(this.googleReCaptchaService.emitReCaptchaCheckboxRequiredError(b),(0,_._)(this.googleReCaptchaService.setReCaptchaRetry(b,!0))):(0,_._)(b))):(0,_._)(b)}))):v.handle(S)}getCaptchaTrigger(S){return-1!==S.url.indexOf("hpp-config")?f.paymentValidation:f.constituentSubmission}interceptCaptchaPostRequest(S,v){return this.googleReCaptchaService.execute(this.getCaptchaTrigger(S)).pipe((0,y.w)(b=>v.handle(S.clone({headers:S.headers.set("g-token",b).set("g-mode",this.googleReCaptchaService.currentMode)}))))}static#t=this.\u0275fac=function(v){return new(v||d)(r.LFG(u))};static#e=this.\u0275prov=r.Yz7({token:d,factory:d.\u0275fac})}return d})(),c=(()=>{class d{static#t=this.\u0275fac=function(v){return new(v||d)};static#e=this.\u0275mod=r.oAB({type:d});static#i=this.\u0275inj=r.cJS({providers:[{provide:e.TP,useClass:g,multi:!0}],imports:[s.ez]})}return d})();const l=()=>{const d=(0,r.f3M)(u);return d.waitForConfig().pipe((0,y.w)(()=>d.initializeScoreCaptcha()))}},72550:(Z,K,t)=>{"use strict";t.d(K,{Gv:()=>O.Gv,L$:()=>f.L,rj:()=>d,Cy:()=>M.C,MM:()=>b,h$:()=>gt,Ng:()=>rt.N,TS:()=>B,NA:()=>j,d0:()=>Y.d,vV:()=>o,Dt:()=>vt.D,U1:()=>p,fL:()=>tt.f,V1:()=>E.V,jL:()=>ft.j,qL:()=>z,lY:()=>et,FL:()=>at});var s=t(96814),e=t(69862),_=t(50768),n=t(56223),i=t(30617),P=t(89515),D=t(10459),I=t(35961),T=t(63611),a=t(21772),y=t(36459),f=t(9845),r=t(37398),u=t(26306),C=t(32185),L=t(99397),g=t(21875),c=t(65879),l=t(58504);let d=(()=>{class ot{handleApolloError(V){let st,dt={code:"0",message:""};return V&&V.graphQLErrors&&V.graphQLErrors.length>0?(st=`Backend returned code ${V.graphQLErrors[0].extensions.code}, message was: ${V.message}`,dt={code:V.graphQLErrors[0].extensions.code,message:V.message}):st="Unable to get the error details from the response.",console.error(st),(0,l._)(dt)}handleApolloErrors(V){const st=[];return V&&V.graphQLErrors&&V.graphQLErrors.length>0?V.graphQLErrors.forEach(dt=>{const ut=`Backend returned code ${dt.extensions.code}, message was: ${dt.message}`;st.push({code:dt.extensions.code,message:dt.message}),console.error(ut)}):console.error("Unable to get the error details from the response."),(0,l._)(st)}handleError(V){return console.error(V.message,V.stack),(0,l._)(V)}static#t=this.\u0275fac=function(st){return new(st||ot)};static#e=this.\u0275prov=c.Yz7({token:ot,factory:ot.\u0275fac})}return ot})();const A=a.Ps`
query GetRaisinDomain {
  raisinDomain
}`,S=a.Ps`
query GetCloudspongeKey {
  cloudspongeKey
}`;let v=(()=>{class ot{constructor(V,st,dt,ut,Pt){this.apollo=V,this.http=st,this.errorHandlingService=dt,this.environmentService=ut,this.storageService=Pt}getRaisinDomain(){return this.raisinDomain$||(this.raisinDomain$=this.apollo.use("contact").query({query:A,fetchPolicy:"network-only"}).pipe((0,r.U)(V=>V.data.raisinDomain),(0,u.K)(V=>this.errorHandlingService.handleApolloError(V)))),this.raisinDomain$}getCloudspongeKey(){return this.cloudspongeKey$||(this.cloudspongeKey$=this.apollo.use("contact").query({query:S,fetchPolicy:"network-only"}).pipe((0,r.U)(V=>V.data.cloudspongeKey),(0,u.K)(V=>this.errorHandlingService.handleApolloError(V)))),this.cloudspongeKey$}getCurrency(){const V={headers:(new e.WM).set("Authorization",`Bearer ${this.storageService.getJWT()}`)},st=`${this.environmentService.getEnvironment().raisinEndpointUrl}/config/site/`;return this.http.get(st,V).pipe((0,C.j)("currency"),(0,L.b)(dt=>this.storageService.setData("currency",dt)))}static#t=this.\u0275fac=function(st){return new(st||ot)(c.LFG(a._M),c.LFG(e.eN),c.LFG(d),c.LFG(f.L),c.LFG(g.V1))};static#e=this.\u0275prov=c.Yz7({token:ot,factory:ot.\u0275fac})}return ot})(),b=(()=>{class ot{constructor(){}validateAllFields(V){Object.keys(V.controls).forEach(st=>{const dt=V.get(st);dt instanceof n.p4?dt.markAsTouched({onlySelf:!0}):dt instanceof n.nJ&&this.validateAllFields(dt)})}static#t=this.\u0275fac=function(st){return new(st||ot)};static#e=this.\u0275prov=c.Yz7({token:ot,factory:ot.\u0275fac})}return ot})();var M=t(6911),R=t(6990);let B=(()=>{class ot{constructor(V){this.translateService=V}configure(V){this.translateService.addLangs((0,R.map)(V,st=>st.culture)),this.translateService.setDefaultLang((0,R.get)(V,"[0].culture","en-CA"))}setInterfaceLanguage(V){this.translateService.use(V)}getInterfaceLanguage(){return this.translateService.currentLang}instant(V){return this.translateService.instant(V)}static#t=this.\u0275fac=function(st){return new(st||ot)(c.LFG(P.sK))};static#e=this.\u0275prov=c.Yz7({token:ot,factory:ot.\u0275fac,providedIn:"root"})}return ot})();var E=t(60899),m=t(70342);let p=(()=>{class ot{constructor(V){V.startQueue()}static#t=this.\u0275fac=function(st){return new(st||ot)(c.LFG(M.C))};static#e=this.\u0275mod=c.oAB({type:ot});static#i=this.\u0275inj=c.cJS({providers:[v,f.L,d,b,B,E.V,D.N,{provide:a.C1,deps:[y.uG,f.L],useFactory:(V,st)=>{const dt=st.getEnvironment();return{contact:{link:V.create({uri:dt.apiContactUrl}),cache:new I.h,name:"contact"},content:{link:V.create({uri:dt.apiContentUrl}),cache:new I.h({dataIdFromObject:ut=>(0,R.has)(ut,"isImage")?`${ut.id}${ut.url}`:(0,T.uG)(ut)}),name:"content"},user:{link:V.create({uri:dt.apiUserUrl}),cache:new I.h({dataIdFromObject:ut=>(0,R.has)(ut,"userId")?`${ut.userId}`:(0,T.uG)(ut)}),name:"user"},team:{link:V.create({uri:dt.apiTeamUrl}),cache:new I.h,name:"team"},donations:{link:V.create({uri:dt.apiDonationUrl}),cache:new I.h,name:"donations"},statistics:{link:V.create({uri:`${dt.apiStatisticsUrl}graphql`}),cache:new I.h,name:"statistics"},email:{link:V.create({uri:dt.apiEmailUrl}),cache:new I.h({dataIdFromObject:ut=>ut.kind?`${(0,T.uG)(ut)}${ut.kind}`:ut.id}),name:"email"},userNotification:{link:V.create({uri:dt.apiUserNotificationUrl}),cache:new I.h,name:"userNotification"}}}}],imports:[s.ez,_.Bz,n.u5,i.Ps,P.aw,e.JF,m.Iq]})}return ot})();var O=t(67299);const F=[/^\d{1,3}(,\d{3})*(\.\d{2})?$/,/^\d+(\.\d{2})?$/],W={"en-CA":F,"en-US":F,"fr-CA":[/^\d{1,3}([ \.]\d{3})*(\,\d{2})?$/,/^\d+(\,\d{2})?$/]};var tt=t(78666),j=function(ot){return ot.notRegisteredForCurrentEvent="errNotRegisteredForCurrentEvent",ot.invalidUsernamePassword="errInvalidUsernamePassword",ot.accountLocked="errAccountLocked",ot.inactiveAccount="errAccountInactive",ot.noUserSocialCredentials="errorSocialUserDoesNotExist",ot}(j||{});class z{static trimStringPropertiesOfObject(_t){if(!(0,R.isNil)(_t)&&"object"==typeof _t)for(const[V,st]of Object.entries(_t))(0,R.isNil)(st)||("string"==typeof st?_t[V]=st.trim():"object"==typeof st&&this.trimStringPropertiesOfObject(st))}}var q=t(32181);function at(){return ot=>ot.pipe((0,q.h)(_t=>!(0,R.isNil)(_t)&&!(0,R.isEmpty)(_t)))}var nt=t(22096);let et=(()=>{class ot{constructor(V,st,dt){this.http=V,this.storageService=st,this.environmentService=dt}getTwitchToken(){const V="twitchToken",[st,dt]=this.storageService.getData(V)??[];if(!(0,R.isEmpty)(st)&&dt>(new Date).getTime())return(0,nt.of)(st);const ut=this.environmentService.getEnvironment().twitch;return this.http.post(ut.authUrl,void 0,{params:{client_id:ut.clientId,client_secret:ut.clientSecret,grant_type:"client_credentials"}}).pipe((0,L.b)(Pt=>{const bt=new Date((new Date).getTime()+Pt.expires_in);this.storageService.setData(V,[Pt.access_token,bt.getTime()])}),(0,r.U)(Pt=>Pt.access_token))}static#t=this.\u0275fac=function(st){return new(st||ot)(c.LFG(e.eN),c.LFG(g.V1),c.LFG(f.L))};static#e=this.\u0275prov=c.Yz7({token:ot,factory:ot.\u0275fac,providedIn:"root"})}return ot})();class o{static isGlobalnumber(_t,V){return!!((0,R.isEmpty)(_t)&&(0,R.isString)(_t)||(0,R.isNil)(_t))||W[V].some(ut=>ut.test(_t))}static globalNumber(_t,V="globalizedFloat"){return st=>_t?this.isGlobalnumber(st.value,_t)?null:{[V]:!0}:null}}t(18779);var ft=t(32964),vt=(t(7428),t(36169)),rt=t(78701),Y=t(97864);let gt=(()=>{class ot{formatGlobalizedAmount(V,st){return(0,R.isEmpty)(V)&&!(0,R.isFinite)(V)?"":Globalize(st).format((0,R.toFinite)(V),"N2")}parseGlobalizedFloat(V,st){if((0,R.isEmpty)(V))return"";try{return V="fr-CA"===st?V.replace(/\./g,""):V,Globalize(st).parseFloat(V).toString()}catch{return NaN.toString()}}parseAsNumber(V,st){const dt="fr-CA"===st?V.replace(/\./g,""):V;return Globalize(st).parseFloat(dt)}isValidPattern(V,st){return!!((0,R.isEmpty)(V)&&(0,R.isString)(V)||(0,R.isNil)(V))||W[st].some(ut=>ut.test(V))}static#t=this.\u0275fac=function(st){return new(st||ot)};static#e=this.\u0275prov=c.Yz7({token:ot,factory:ot.\u0275fac,providedIn:"root"})}return ot})();t(360)},67299:(Z,K,t)=>{"use strict";t.d(K,{Gv:()=>e,OT:()=>i,nc:()=>n,u1:()=>_});const e=new(t(65879).OlP)("environment"),_=/https:\/\/dev\d+\.raisinlocal\.com/,n=/https:\/\/\S+\.(qa(2)?|rel)\.raisinlocal\.com/,i=/https:\/\/\S+\.(uat|int)\.akaraisin\.com/},78666:(Z,K,t)=>{"use strict";t.d(K,{f:()=>s});const s={sponsorSuccessPage:"sponsor-success-page",donationSuccessPage:"donations-success-page",ticketingSuccessPage:"ticket-success-page",registrationSuccessPage:"registration-success-page",participantPage:"participant-page",teamPage:"team-page",groupPage:"group-page",homePage:"home-page",pcDashboard:"pc-dashboard",pcGetSocial:"pc-get-social"}},18779:(Z,K,t)=>{"use strict";t.d(K,{n:()=>_});var s=t(6911),e=t(65879);let _=(()=>{class n{constructor(P){this.focusManagerService=P,this.targets=[],this.backTargets=[]}ngOnInit(){this.targets||(this.targets=[])}onKeydown(P){"Tab"===P.key&&P.target===P.currentTarget&&this.skipTab(P,P.shiftKey?this.backTargets:this.targets)}skipTab(P,D){this.focusManagerService.focusOnTarget(D)&&P.preventDefault()}static#t=this.\u0275fac=function(D){return new(D||n)(e.Y36(s.C))};static#e=this.\u0275dir=e.lG2({type:n,selectors:[["","rxTabskip",""]],hostBindings:function(D,I){1&D&&e.NdJ("keydown",function(a){return I.onKeydown(a)})},inputs:{targets:["rxTabskip","targets"],backTargets:"backTargets"}})}return n})()},82928:(Z,K,t)=>{"use strict";t.d(K,{O:()=>s});var s=function(e){return e[e.Event=1]="Event",e[e.Team=2]="Team",e[e.Participant=3]="Participant",e[e.Group=4]="Group",e}(s||{})},35560:(Z,K,t)=>{"use strict";t.d(K,{R:()=>n});var s=t(96814),e=t(65879),_=t(89515);let n=(()=>{class i{constructor(D){this.translateService=D}transform(D,I="CAD",T="1.2-2",a=this.translateService.currentLang||this.translateService.defaultLang){return(0,s.xG)(D,a||"en-CA",(0,s.jK)(I,"narrow"),I,T)}static#t=this.\u0275fac=function(I){return new(I||i)(e.Y36(_.sK,16))};static#e=this.\u0275pipe=e.Yjl({name:"customCurrency",type:i,pure:!0});static#i=this.\u0275prov=e.Yz7({token:i,factory:i.\u0275fac})}return i})()},78701:(Z,K,t)=>{"use strict";t.d(K,{N:()=>i});var s=t(96814),e=t(21875),_=t(65879),n=t(89515);let i=(()=>{class P{constructor(I,T){this.translateService=I,this.storageService=T}transform(I,T=this.getCurrencyCode(),a="1.2-2",y=this.translateService.currentLang){return(0,s.xG)(I,y,(0,s.jK)(T,"narrow"),T,a)}parse(I){const T="fr-CA"===this.translateService.currentLang?I.replace(/\./g,""):I;return`${Globalize(this.translateService.currentLang).parseFloat(T)}`}getCurrencyCode(){return(this.storageService.getData("currency")||{}).code||""}static#t=this.\u0275fac=function(T){return new(T||P)(_.Y36(n.sK,16),_.Y36(e.V1,16))};static#e=this.\u0275pipe=_.Yjl({name:"globalizedCurrency",type:P,pure:!0})}return P})()},24607:(Z,K,t)=>{"use strict";t.d(K,{F:()=>n});var s=t(65879),e=t(89515),_=t(96814);let n=(()=>{class i{constructor(D,I){this.translate=D,this.datePipe=I}transform(D,I=[],T=[]){if(!D)return"";let a=this.translate.instant(D);return I?.forEach((y,f)=>{let r=I[f];switch(T[f]){case"fullDate":case"longDate":case"date":r=this.datePipe.transform(r,T[f],void 0,this.translate.currentLang)}a=a.replace(`{${f}}`,r)}),a}static#t=this.\u0275fac=function(I){return new(I||i)(s.Y36(e.sK,16),s.Y36(_.uU,16))};static#e=this.\u0275pipe=s.Yjl({name:"localize",type:i,pure:!0})}return i})()},97864:(Z,K,t)=>{"use strict";t.d(K,{d:()=>n});var s=t(6990),_=t(65879);let n=(()=>{class i{transform(D,I,T=!0){return I&&""!==I.trim()?T?(0,s.toArray)(D).sort((a,y)=>this.orderByComparator(a[I],y[I])):(0,s.toArray)(D).sort((a,y)=>this.orderByComparator(y[I],a[I])):D}orderByComparator(D,I){if(!isNaN(parseFloat(D))&&isFinite(D)&&!isNaN(parseFloat(I))&&isFinite(I)){if(parseFloat(D)<parseFloat(I))return-1;if(parseFloat(D)>parseFloat(I))return 1}return 0}static#t=this.\u0275fac=function(I){return new(I||i)};static#e=this.\u0275pipe=_.Yjl({name:"orderBy",type:i,pure:!0})}return i})()},36169:(Z,K,t)=>{"use strict";t.d(K,{D:()=>D});var s=t(97864),e=t(96814),_=t(78701),n=t(35560),i=t(360),P=t(65879);let D=(()=>{class I{static forRoot(){return{ngModule:I,providers:[s.d,e.uU,e.H9,_.N,n.R,i.A]}}static forChildren(){return{ngModule:I}}static#t=this.\u0275fac=function(y){return new(y||I)};static#e=this.\u0275mod=P.oAB({type:I});static#i=this.\u0275inj=P.cJS({})}return I})()},360:(Z,K,t)=>{"use strict";t.d(K,{A:()=>n});var s=t(6990),_=t(65879);let n=(()=>{class i{transform(D,I){if((0,s.isEmpty)(D)||(0,s.isEmpty)(I))return D;let T=D;return(0,s.forEach)(I,(a,y)=>{T=(0,s.replace)(T,"{{"+y+"}}",a)}),T}static#t=this.\u0275fac=function(I){return new(I||i)};static#e=this.\u0275pipe=_.Yjl({name:"replace",type:i,pure:!0})}return i})()},33409:(Z,K,t)=>{"use strict";t.d(K,{z:()=>_});var s=t(65879),e=t(6593);let _=(()=>{class n{constructor(P){this.sanitizer=P}transform(P){return this.sanitizer.bypassSecurityTrustHtml(P)}static#t=this.\u0275fac=function(D){return new(D||n)(s.Y36(e.H7,16))};static#e=this.\u0275pipe=s.Yjl({name:"safeHtml",type:n,pure:!0})}return n})()},9845:(Z,K,t)=>{"use strict";t.d(K,{L:()=>T});var s=t(96814),e=t(6990),n=t(40787),i=t.n(n),P=t(22096),D=t(67299),I=t(65879);let T=(()=>{class a{constructor(f,r){this.document=f,this.globalEnvironment=r;const u=new(i())(this.document.location.href);if(this.baseUrl=`${u.origin}`,D.u1.test(this.baseUrl)||this.baseUrl.includes("localhost"))this.baseUrl="http://localhost:4200";else if(D.nc.test(this.baseUrl)||D.OT.test(this.baseUrl)){const C=this.getRootDomain(this.baseUrl);this.baseUrl=`https://pc.${C}`}else this.baseUrl="https://pc.akaraisin.com"}getCdnSharedImagesURL(){const r=`${new(i())(this.document.location.href).origin}`;return r.includes("localhost")||D.u1.test(r)||D.nc.test(r)?"https://raisin-si-dev.s3.ca-central-1.amazonaws.com":D.OT.test(r)?"https://raisin-si-uat.s3.ca-central-1.amazonaws.com":"https://raisincdn-si.akaraisin.com"}getEnvironment(){return this.environment||(this.environment=this.createEnvironment()),this.environment}createEnvironment(f){const r=!(0,e.isNil)(f),u=(0,e.cloneDeep)(f||this.globalEnvironment);return u.baseUrl=this.baseUrl,u.eventUrl=new(i())(this.globalEnvironment.eventUrl).toString(),u.cdnSharedImagesURL=this.getCdnSharedImagesURL(),!r&&this.globalEnvironment.production&&(D.nc.test(this.baseUrl)||D.OT.test(this.baseUrl))&&(u.apiDonationUrl=this.convertUrl(this.globalEnvironment.apiDonationUrl),u.apiContentUrl=this.convertUrl(this.globalEnvironment.apiContentUrl),u.apiUserUrl=this.convertUrl(this.globalEnvironment.apiUserUrl),u.apiEmailUrl=this.convertUrl(this.globalEnvironment.apiEmailUrl),u.apiContactUrl=this.convertUrl(this.globalEnvironment.apiContactUrl),u.apiTeamUrl=this.convertUrl(this.globalEnvironment.apiTeamUrl),u.apiStatisticsUrl=this.convertUrl(this.globalEnvironment.apiStatisticsUrl),u.apiQueueUrl=this.convertUrl(this.globalEnvironment.apiQueueUrl),u.apiUserNotificationUrl=this.convertUrl(this.globalEnvironment.apiUserNotificationUrl),u.claimsUrl=this.convertUrl(this.globalEnvironment.claimsUrl),u.anonymousClaimsUrl=this.convertUrl(this.globalEnvironment.anonymousClaimsUrl),u.regenerateClaimsUrl=this.convertUrl(this.globalEnvironment.regenerateClaimsUrl),u.claimsV2ApiUrl=this.convertUrl(this.globalEnvironment.claimsV2ApiUrl),u.raisinEndpointUrl=this.convertUrl(this.globalEnvironment.raisinEndpointUrl),u.raisinApiV1=this.convertUrl(this.globalEnvironment.raisinApiV1),u.supporterPortalUrl=this.convertUrl(this.globalEnvironment.supporterPortalUrl)),r&&(this.environment=u),u}getImportContactsUrl(){return(0,P.of)(this.baseUrl)}convertUrl(f){if(f){let r=new(i())(f);const u=this.getRootDomain(f),C=this.getRootDomain(this.baseUrl);return r=new(i())(`${f.replace(u,C)}${r.pathname}`),r.toString()}return null}getRootDomain(f){return null===f?null:f.split(/\.(.+)/)[1]}static#t=this.\u0275fac=function(r){return new(r||a)(I.LFG(s.K0),I.LFG(D.Gv))};static#e=this.\u0275prov=I.Yz7({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})()},6911:(Z,K,t)=>{"use strict";t.d(K,{C:()=>f});var s=t(6990),_=t(78645),n=t(91687),i=t(92438),P=t(94664),D=t(48180),I=t(32181),T=t(59773),a=t(59636),y=t(65879);let f=(()=>{class r{constructor(){this.queueStarted=!1,this.scheduledElement$=new _.x}queueForFocus(C,L){this.scheduledElement$.next({targets:C,checkEvery:L})}startQueue(){if(this.queueStarted)return null;this.queueStarted=!0;const C=this.scheduledElement$.pipe((0,P.w)(({targets:L,checkEvery:g})=>(0,n.F)(g).pipe((0,D.q)(5),(0,I.h)(()=>!(0,s.isNil)(this.focusOnTarget(L))),(0,D.q)(1),(0,T.R)((0,i.R)(document,"mousedown").pipe((0,D.q)(1))))));return(0,a.n)()(C).connect()}focusOnTarget(C){const L=C.map(c=>document.querySelector(c)).filter(c=>!(0,s.isNil)(c));if(!L.length)return null;const g=L[0];return g.focus(),g}static#t=this.\u0275fac=function(L){return new(L||r)};static#e=this.\u0275prov=y.Yz7({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})()},60899:(Z,K,t)=>{"use strict";t.d(K,{V:()=>T});var s=t(9845),e=t(82928),_=function(a){return a[a.NoModule=0]="NoModule",a[a.EventHomePage=8]="EventHomePage",a[a.RegistrationStart=60]="RegistrationStart",a[a.IndividualRegistration=1]="IndividualRegistration",a[a.JoinTeamRegistration=3]="JoinTeamRegistration",a[a.CreateTeamRegistration=5]="CreateTeamRegistration",a[a.PledgeParticipantHomePage=9]="PledgeParticipantHomePage",a[a.PledgeTeamHomePage=10]="PledgeTeamHomePage",a[a.PledgeSponsor=22]="PledgeSponsor",a[a.PledgeVisitorJoinATeam=23]="PledgeVisitorJoinATeam",a[a.Store=27]="Store",a[a.PledgeDonateToEvent=29]="PledgeDonateToEvent",a[a.VolunteerRegistration=80]="VolunteerRegistration",a[a.GroupHomePage=82]="GroupHomePage",a[a.GroupsList=83]="GroupsList",a[a.Pledge_ParticipantAdmin=11]="Pledge_ParticipantAdmin",a[a.TicketingEvent=85]="TicketingEvent",a[a.TicketingDonation=87]="TicketingDonation",a[a.TicketingCart=88]="TicketingCart",a[a.Donations=89]="Donations",a[a.ForgotUsername=90]="ForgotUsername",a[a.ForgotPassword=91]="ForgotPassword",a[a.PasswordReset=92]="PasswordReset",a}(_||{}),n=function(a){return a[a.NotSet=0]="NotSet",a[a.EventHome=3]="EventHome",a[a.ParticipantHome_Pledge=5]="ParticipantHome_Pledge",a[a.TeamHome=7]="TeamHome",a[a.GroupHome=172]="GroupHome",a[a.GroupsList=174]="GroupsList",a[a.Ticketing_YourProfile=202]="Ticketing_YourProfile",a[a.Ticketing_YourPurchases=201]="Ticketing_YourPurchases",a[a.Ticketing_ManageAttendees=203]="Ticketing_ManageAttendees",a[a.Ticketing_Review=70]="Ticketing_Review",a[a.DonationsSuccess=118]="DonationsSuccess",a[a.EventNotAvailable=99]="EventNotAvailable",a[a.ForgotUsername=204]="ForgotUsername",a[a.ForgotPassword=206]="ForgotPassword",a[a.PasswordReset=207]="PasswordReset",a[a.PasswordResetSuccess=208]="PasswordResetSuccess",a}(n||{}),i=t(37398),P=t(6990),D=t(65879),I=t(69862);let T=(()=>{class a{constructor(f,r){this.http=f,this.environment=r}get languageId(){return(0,P.toNumber)((0,P.get)(window,"raisin_dd.LanguageId"))}get isFrenchLanguage(){return 2===this.languageId}getOneAllConfig(){return this.http.get(`${this.environment.getEnvironment().raisinEndpointUrl}/settings/social`)}getSponsorSocialShareMetaData(f,r,u){let C,L;const g=`${window.location.origin}/ui/`;let c=`${this.environment.getEnvironment().raisinEndpointUrl}/config/page`;switch(r){case e.O.Team:L=this.isFrenchLanguage?"equipe":"team",c=`${c}/${_.PledgeTeamHomePage}/${n.TeamHome}`,C=`${g}${f.subEventCustomPart}/${L}/${u}`;break;case e.O.Participant:L="participant",c=`${c}/${_.PledgeParticipantHomePage}/${n.ParticipantHome_Pledge}`,C=`${g}${f.subEventCustomPart}/${L}/${u}`;break;case e.O.Group:L="g",c=`${c}/${_.GroupHomePage}/${n.GroupHome}`,C=`${g}${f.subEventCustomPart}/${L}/${u}`;break;default:L="/",c=`${c}/${_.EventHomePage}/${n.EventHome}`,C=(0,P.isNil)(f?.subEventCustomPart)?window.location.href:`${g}${f.subEventCustomPart}`}const l={};return l.entityId=u,l.entityTypeId=r,l.url=L,this.http.get(c,{params:l}).pipe((0,i.U)(d=>({link:C,image:(0,P.find)(d.fbMetaTags,{property:"og:image"})?.content,message:(0,P.find)(d.fbMetaTags,{property:"og:title"})?.content})))}static#t=this.\u0275fac=function(r){return new(r||a)(D.LFG(I.eN),D.LFG(s.L))};static#e=this.\u0275prov=D.Yz7({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})()},32964:(Z,K,t)=>{"use strict";t.d(K,{j:()=>d});var s=t(96814),e=t(65879),_=t(6990),n=t(78645),i=t(52572),P=t(22096),D=t(59773),I=t(37398),T=t(99397),a=t(60899),y=t(82928),f=t(40374),r=t(78666),C=t(70342),L=t(89515);const g=function(A){return{"black-bg":A}};function c(A,S){if(1&A){const v=e.EpF();e.TgZ(0,"div",3)(1,"span",4),e.NdJ("click",function(){e.CHM(v);const M=e.oxw();return e.KtG(M.trackSocialTrigger("Facebook"))}),e.ALo(2,"translate"),e.TgZ(3,"span",5),e._UZ(4,"span",6),e.qZA()(),e.TgZ(5,"span",7),e.NdJ("click",function(){e.CHM(v);const M=e.oxw();return e.KtG(M.trackSocialTrigger("Twitter"))}),e.ALo(6,"translate"),e.TgZ(7,"span",8),e._UZ(8,"span",6),e.qZA()(),e.TgZ(9,"span",9),e.NdJ("click",function(){e.CHM(v);const M=e.oxw();return e.KtG(M.trackSocialTrigger("LinkedIn"))}),e.ALo(10,"translate"),e.TgZ(11,"span",5),e._UZ(12,"span",6),e.qZA()()()}if(2&A){const v=e.oxw();e.xp6(1),e.Q6J("id",v.facebookId),e.uIk("aria-label",e.lcZ(2,7,"str_Share_On_Facebook")),e.xp6(4),e.Q6J("id",v.twitterId),e.uIk("aria-label",e.lcZ(6,9,"strShareOnTwitter")),e.xp6(2),e.Q6J("ngClass",e.VKq(13,g,v.useBlackBgForTwitter)),e.xp6(2),e.Q6J("id",v.linkedinId),e.uIk("aria-label",e.lcZ(10,11,"strShareOnLinkedIn"))}}function l(A,S){if(1&A){const v=e.EpF();e.TgZ(0,"div",10)(1,"span",11),e.NdJ("click",function(){e.CHM(v);const M=e.oxw();return e.KtG(M.trackSocialTrigger("WhatsApp"))}),e.ALo(2,"translate"),e.TgZ(3,"span",5),e._UZ(4,"span",6),e.qZA()(),e.TgZ(5,"span",12),e.NdJ("click",function(){e.CHM(v);const M=e.oxw();return e.KtG(M.trackSocialTrigger("CopyLink"))}),e.ALo(6,"translate"),e.TgZ(7,"span",5)(8,"span",13),e.O4$(),e.TgZ(9,"svg",14)(10,"g",15)(11,"g",16)(12,"g",17)(13,"g",18),e._UZ(14,"path",19)(15,"path",20),e.qZA()()()()()()()()()}if(2&A){const v=e.oxw();e.uIk("data-url",null==v.socialShareData?null:v.socialShareData.link)("data-title",null==v.socialShareData?null:v.socialShareData.message),e.xp6(1),e.uIk("aria-label",e.lcZ(2,5,"strShareOnWhatsApp")),e.xp6(4),e.Q6J("cdkCopyToClipboard",null==v.socialShareData?null:v.socialShareData.link),e.uIk("aria-label",e.lcZ(6,7,"strShareCopyLink"))}}let d=(()=>{class A{constructor(v,b,M){this.socialConfigService=v,this.document=b,this.googleAnalyticService=M,this.$destroy=new n.x,this.socialProviderClicked=new e.vpe,this.oneAllIconSize=32,this.hostClass="social-share";const R=(new Date).getTime();this.linkedinId=`share-dialog-linkedin-${R}`,this.twitterId=`share-dialog-twitter-${R}`,this.facebookId=`share-dialog-facebook-${R}`}ngOnInit(){this.enableResize=!!this.resizeIcon,this.resizeRatio=this.resizeIcon/this.oneAllIconSize,this.setUpSocialConfigForOneAll()}setUpSocialConfigForOneAll(){this.isLoaded=!1,(0,i.a)([this.socialConfigService.getOneAllConfig(),this.setMetaData()]).pipe((0,D.R)(this.$destroy),(0,I.U)(([v,b])=>{this.socialConfigSetting=v,this.socialShareData=b,this.initOneAllScript(b)}),(0,T.b)(()=>this.isLoaded=!0)).subscribe()}setMetaData(){let v=this.siteMetaData||{};return v.link=(0,_.isNil)(v.link)?this.document.location.href:v.link,v=this.setGroupPageMetaData(v),v=this.setShareLocationOnSuccessPage(v),(0,_.isEmpty)(v.message)||(0,_.isEmpty)(v.image)?this.socialConfigService.getSponsorSocialShareMetaData(null,y.O.Event).pipe((0,I.U)(b=>(v.message=(0,_.isNil)(v.message)?b.message:v.message,v.image=(0,_.isNil)(v.image)?b.image:v.image,this.referrerUrl=this.referrerUrl||r.f.homePage,v))):(0,P.of)(v)}isGroupUrl(v){return/https:\/\/.*?\/ui\/(.*?)\/g\/(\d+)/g.test(v)}setShareLocationOnSuccessPage(v){return-1!==v.link.indexOf("/pledge/registration/success")&&(v.link=v.link.replace("/pledge/registration/success","/pledge/registration/start"),this.referrerUrl=this.referrerUrl||r.f.registrationSuccessPage),-1!==v.link.indexOf("/ticketed/cart/successful")&&(v.link=v.link.replace("/ticketed/cart/successful",""),this.referrerUrl=this.referrerUrl||r.f.ticketingSuccessPage),v}setGroupPageMetaData(v){if(this.isGroupUrl(this.document.location.href)){const b=$(document.querySelector('meta[property="og:image"]'))[0],M=$(document.querySelector('meta[property="og:title"]'))[0];v.message=M.content,v.image=b.content,this.referrerUrl=this.referrerUrl||r.f.groupPage}return v}initOneAllScript(v){const b=window;if(typeof _oneall>"u"){console.debug("oneall not loaded");const M=document.getElementsByTagName("head")[0],R=document.createElement("script");R.type="text/javascript",R.async=!0,R.src=`//${this.socialConfigSetting.subDomain}.api.oneall.com/socialize/library.js`,R.onload=B=>{_oneall=b._oneall,setTimeout(()=>this.executeOneAllScript(v),200)},M.appendChild(R)}else console.debug("oneall is loaded"),setTimeout(()=>this.executeOneAllScript(v),200)}executeOneAllScript(v){_oneall.push(["share_dialog","set_link",v.link],["share_dialog","set_message",(0,_.get)(v,"message","").replace(new RegExp("\u2019","g"),"'")],["share_dialog","set_image",v.image],["share_dialog","attach_onclick_display",this.linkedinId,"linkedin"],["share_dialog","attach_onclick_display",this.twitterId,"twitter"],["share_dialog","attach_onclick_display",this.facebookId,"facebook"],["social_sharing","do_render_element","oas_box_share"])}ngOnDestroy(){this.$destroy.next()}handleAnalytics(v){this.googleAnalyticService.trackSocial(v,this.referrerUrl)}trackSocialTrigger(v){this.handleAnalytics(v),setTimeout(()=>{this.socialProviderClicked.emit(v)},500)}static#t=this.\u0275fac=function(b){return new(b||A)(e.Y36(a.V),e.Y36(s.K0),e.Y36(f.Wf))};static#e=this.\u0275cmp=e.Xpm({type:A,selectors:[["rx-social-share"]],hostVars:8,hostBindings:function(b,M){2&b&&(e.Tol(M.hostClass),e.Udp("--resize-ratio",M.resizeRatio)("--resize-icon",M.resizeIcon),e.ekj("enable-resize",M.enableResize))},inputs:{resizeIcon:"resizeIcon",siteMetaData:"siteMetaData",referrerUrl:"referrerUrl",useBlackBgForTwitter:"useBlackBgForTwitter"},outputs:{socialProviderClicked:"socialProviderClicked"},decls:3,vars:2,consts:[["rel","stylesheet","type","text/css","href","https://secure.oneallcdn.com/css/api/socialize/sharing/v1/btns_lfnm.css"],["class","oas_box oas_box_btns_lfnm",4,"ngIf"],["class","oas_box oas_box_share oas_box_btns_lfnm",4,"ngIf"],[1,"oas_box","oas_box_btns_lfnm"],[1,"oas_btn","oas_btn_facebook","oas_btn_service",3,"id","click"],[1,"oas_btn_brd"],[1,"oas_btn_ico","oas_icons_white"],[1,"oas_btn","oas_btn_twitter","oas_btn_service",3,"id","click"],[1,"oas_btn_brd",3,"ngClass"],[1,"oas_btn","oas_btn_linkedin","oas_btn_service",3,"id","click"],[1,"oas_box","oas_box_share","oas_box_btns_lfnm"],["id","share-dialog-whatsapp",1,"oas_btn","oas_btn_whatsapp","oas_btn_service",3,"click"],["onKeyPress","trackSocialTrigger('CopyLink')",1,"oas_btn","oas_btn_copy","oas_btn_service",3,"cdkCopyToClipboard","click"],[1,"oas_icons_white"],["width","24px","height","24px","viewBox","0 0 19 19","version","1.1","xmlns","http://www.w3.org/2000/svg",0,"xmlns","xlink","http://www.w3.org/1999/xlink","fit","","preserveAspectRatio","xMidYMid meet","focusable","false"],["stroke","none","stroke-width","1"],["transform","translate(-204.000000, -12.000000)"],["transform","translate(204.000000, 12.000000)"],["transform","translate(0.000532, 0.000376)"],["d","M17.515758,1.46930198 C15.537098,-0.489767327 12.328568,-0.489767327 10.350668,1.46930198 L7.523658,4.26756931 C7.747801,4.24331891 7.973426,4.23303257 8.200533,4.23303257 C8.915997,4.23303257 9.611435,4.34546366 10.270583,4.5622405 L11.872226,2.97645535 C12.422181,2.43121178 13.153985,2.13138802 13.932586,2.13138802 C14.710408,2.13138802 15.442193,2.43121178 15.992946,2.97645535 C16.542901,3.52096525 16.845723,4.24405634 16.845723,5.01566327 C16.845723,5.78578406 16.542901,6.51032366 15.992946,7.05487119 L12.858706,10.1580791 C12.30801,10.7033227 11.576206,11.0031464 10.798346,11.0031464 C10.019042,11.0031464 9.288739,10.7033227 8.737986,10.1580791 C8.470048,9.8942801 8.261504,9.58636723 8.117522,9.25129 C7.760531,9.27113089 7.426549,9.41809871 7.171227,9.67015535 L6.336272,10.4975771 C6.564861,10.9164425 6.858031,11.3117742 7.215022,11.6666979 C9.193682,13.6257672 12.402212,13.6257672 14.380872,11.6666979 L17.515872,8.56198505 C19.493772,6.60366822 19.493772,3.42765832 17.515872,1.46934149 L17.515758,1.46930198 Z","id","Path"],["d","M10.831748,14.5773267 C10.114802,14.5773267 9.412676,14.4626909 8.738708,14.2363614 L7.125931,15.8331703 C6.575976,16.3784139 5.844913,16.6782376 5.066331,16.6782376 C4.288509,16.6782376 3.557465,16.3784139 3.006731,15.8331703 C2.456035,15.2886604 2.153213,14.5648356 2.153213,13.7939624 C2.153213,13.0238416 2.456035,12.299302 3.006731,11.754002 L6.140971,8.65079406 C6.691667,8.10628416 7.421989,7.80719406 8.200571,7.80719406 C8.979875,7.80719406 9.710178,8.10701782 10.260931,8.65079406 C10.528869,8.91607921 10.738154,9.22397327 10.882877,9.5590505 C11.24135,9.54067956 11.576073,9.39224178 11.830654,9.14018515 L12.664127,8.31349703 C12.435538,7.89316436 12.141627,7.49856634 11.783895,7.14362376 C9.805235,5.18455446 6.596705,5.18455446 4.618805,7.14362376 L1.484565,10.2483366 C-0.494855,12.2074059 -0.494855,15.3826634 1.484565,17.3424851 C3.463225,19.3015545 6.670235,19.3015545 8.648895,17.3424851 L11.471345,14.5479802 C11.260559,14.5670855 11.048291,14.5781093 10.8338,14.5781093 L10.831748,14.5773267 Z","id","Path"]],template:function(b,M){1&b&&(e._UZ(0,"link",0),e.YNc(1,c,13,15,"div",1),e.YNc(2,l,16,9,"div",2)),2&b&&(e.xp6(1),e.Q6J("ngIf",M.isLoaded),e.xp6(1),e.Q6J("ngIf",M.isLoaded&&M.socialShareData))},dependencies:[s.mk,s.O5,C.i3,L.X$],styles:["rx-social-share.enable-resize>div.oas_box:nth-of-type(1){display:flex;column-gap:8px}rx-social-share.enable-resize>div.oas_box:nth-of-type(1) .oas_btn,rx-social-share.enable-resize>div.oas_box:nth-of-type(1) .oas_btn_brd,rx-social-share.enable-resize>div.oas_box:nth-of-type(1) .oas_btn_ico{margin:0}rx-social-share.enable-resize>div.oas_box:nth-of-type(1) .oas_btn_brd{height:unset!important;width:unset!important}rx-social-share.enable-resize>div.oas_box:nth-of-type(1) .oas_btn_facebook .oas_btn_ico.oas_icons_white{height:calc(var(--resize-icon) * 1px);width:calc(var(--resize-icon) * 1px);background-size:100%;background-position-y:calc(-988px * var(--resize-ratio))}rx-social-share.enable-resize>div.oas_box:nth-of-type(1) .oas_btn_linkedin .oas_btn_ico.oas_icons_white{height:calc(var(--resize-icon) * 1px);width:calc(var(--resize-icon) * 1px);background-size:100%;background-position-y:calc(-1541px * var(--resize-ratio))}rx-social-share.enable-resize>div.oas_box_share:nth-of-type(2){display:none}.oas_btn_twitter .oas_btn_ico.oas_icons_white{background-image:url(https://raisincdn-si.akaraisin.com/raisin/images/icons8-twitter.svg)!important;background-position:center!important;background-repeat:no-repeat!important;background-size:80%!important}.black-bg{background-color:#000!important}\n"],encapsulation:2})}return A})()},7428:(Z,K,t)=>{"use strict";t.d(K,{f:()=>u});var s=t(6990),_=t(65879),n=t(96814),i=t(30617),P=t(89515);function D(C,L){1&C&&(_.TgZ(0,"mat-icon"),_._uU(1,"done"),_.qZA())}function I(C,L){1&C&&(_.TgZ(0,"mat-icon"),_._uU(1,"close"),_.qZA())}function T(C,L){if(1&C&&(_.TgZ(0,"div",5),_._uU(1),_.ALo(2,"translate"),_.qZA()),2&C){const g=_.oxw();_.xp6(1),_.hij(" ",_.lcZ(2,1,g.successCopyKey)," ")}}function a(C,L){if(1&C&&(_._UZ(0,"p",8),_.ALo(1,"safeHtml"),_.ALo(2,"notEmptyHtml")),2&C){const g=_.oxw(2);_.Q6J("innerHTML",_.lcZ(1,1,_.lcZ(2,3,g.errorDetails.defaultMessage)),_.oJD)}}function y(C,L){if(1&C&&(_.TgZ(0,"span"),_._uU(1),_.ALo(2,"translate"),_.ALo(3,"translate"),_.qZA()),2&C){const g=_.oxw(3);_.xp6(1),_.lnq("",_.lcZ(2,3,"lbl_ErrorCode"),"",_.lcZ(3,5,"Colon")," ",g.error.errorCode,"")}}function f(C,L){if(1&C&&(_.TgZ(0,"div",9),_.YNc(1,y,4,7,"span",2),_.qZA()),2&C){const g=_.oxw(2);_.Q6J("innerHTML",g.errorDetails.errorMessage,_.oJD),_.xp6(1),_.Q6J("ngIf",g.errorDetails.errorCode)}}function r(C,L){if(1&C&&(_.TgZ(0,"div",5),_.YNc(1,a,3,5,"p",6),_.YNc(2,f,2,2,"div",7),_.qZA()),2&C){const g=_.oxw();_.xp6(1),_.Q6J("ngIf",g.errorDetails.defaultMessage),_.xp6(1),_.Q6J("ngIf",g.errorDetails.errorMessage)}}let u=(()=>{class C{constructor(){this.cssClass="update-status-alert"}ngOnInit(){this.status=(0,s.isEmpty)(this.errorDetails?.defaultMessage)&&(0,s.isEmpty)(this.errorDetails?.errorMessage)&&(0,s.isNil)(this.errorDetails?.errorCode)?"success":"fail"}static#t=this.\u0275fac=function(c){return new(c||C)};static#e=this.\u0275cmp=_.Xpm({type:C,selectors:[["rx-status-alert"]],hostVars:2,hostBindings:function(c,l){2&c&&_.Tol(l.cssClass)},inputs:{successCopyKey:"successCopyKey",errorDetails:"errorDetails"},decls:7,vars:5,consts:[["role","alert",1,"statusAlert",3,"ngClass"],[1,"icon"],[4,"ngIf"],[3,"ngIf","ngIfElse"],["failed",""],[1,"copy"],[3,"innerHTML",4,"ngIf"],["class","errorMessage",3,"innerHTML",4,"ngIf"],[3,"innerHTML"],[1,"errorMessage",3,"innerHTML"]],template:function(c,l){if(1&c&&(_.TgZ(0,"div",0)(1,"div",1),_.YNc(2,D,2,0,"mat-icon",2),_.YNc(3,I,2,0,"mat-icon",2),_.qZA(),_.YNc(4,T,3,3,"ng-template",3),_.YNc(5,r,3,2,"ng-template",null,4,_.W1O),_.qZA()),2&c){const d=_.MAs(6);_.Q6J("ngClass",l.status),_.xp6(2),_.Q6J("ngIf","success"===l.status),_.xp6(1),_.Q6J("ngIf","success"!=l.status),_.xp6(1),_.Q6J("ngIf","success"===l.status)("ngIfElse",d)}},dependencies:[n.mk,n.O5,i.Hw,P.X$],styles:[".update-status-alert .statusAlert{box-shadow:0 0 15px #00000040;display:flex;padding:25px;margin:20px 0}@media (min-width: 992px){.update-status-alert .statusAlert{align-items:center}}.update-status-alert .statusAlert.success mat-icon{border:2px solid #8ab134;color:#8ab134}.update-status-alert .statusAlert.fail mat-icon{border:2px solid #E91B0C;color:#e91b0c}.update-status-alert .statusAlert .icon{display:flex;justify-content:center}@media (min-width: 992px){.update-status-alert .statusAlert .icon{align-items:center}}.update-status-alert .statusAlert .icon mat-icon{border-radius:50%;width:38px;height:38px;display:flex;font-size:35px}.update-status-alert .statusAlert .copy{padding:5px 0 0 15px}.update-status-alert .statusAlert .copy p{margin:auto}.update-status-alert .statusAlert .copy .errorMessage a{cursor:pointer}\n"],encapsulation:2})}return C})()},399:(Z,K,t)=>{"use strict";t.d(K,{z2:()=>vt.z,Eq:()=>i.E,DH:()=>n.D,IZ:()=>P.I,Zy:()=>rt.Z,CT:()=>_t.CT,pt:()=>o,VE:()=>z.V,_m:()=>p._,Al:()=>F,uy:()=>mt.u,cw:()=>Y.c,uA:()=>ct});var s=t(96814),e=t(56223),_=t(89515),n=t(59215),i=t(18282),P=t(14583),D=t(24630),I=t(32296),T=t(49488),a=t(95195),y=t(75986),f=t(38034),r=t(17700),u=t(26385),C=t(64170),L=t(2032),g=t(55940),c=t(87466),l=t(98525),d=t(38257),A=t(74104),S=t(92596),v=t(30617),b=t(73445),M=t(23680),R=t(71657),B=t(65879);let E=(()=>{class V{static#t=this.\u0275fac=function(ut){return new(ut||V)};static#e=this.\u0275mod=B.oAB({type:V});static#i=this.\u0275inj=B.cJS({providers:[{provide:M._A,useClass:b.t7},{provide:M.sG,useValue:b.$o}],imports:[s.ez,d.T5,A.Nh,T.vV,L.c,C.lN,y.p9,S.AV,I.ot,l.LD,f.FA,c.Fk,a.QW,v.Ps,R.U5,g.Cq,u.t,D.Bb,r.Is,R.U5,d.T5,A.Nh,T.vV,L.c,C.lN,y.p9,S.AV,I.ot,l.LD,f.FA,c.Fk,a.QW,v.Ps,g.Cq,u.t,D.Bb,r.Is]})}return V})();var m=t(51447),p=t(33058),O=t(72550);let F=(()=>{class V{static forRoot(){return{ngModule:V,providers:[p._,n.D,i.E,P.I]}}static forChildren(){return{ngModule:V}}static#t=this.\u0275fac=function(ut){return new(ut||V)};static#e=this.\u0275mod=B.oAB({type:V});static#i=this.\u0275inj=B.cJS({providers:[p._,n.D,i.E,P.I],imports:[s.ez,E,e.u5,_.aw,e.UX,m.o9,O.Dt,C.lN]})}return V})();t(54517),t(82761),t(56417),t(34985);var z=t(62110);t(60328),t(65343),t(39550),t(3983);const o={AccountInformation:["Username","Password","Goal"],PersonalInformation:["UserType","Title","FirstName","MiddleName","LastName","CompanyName","EmailType","Email","PhoneType","Phone","PhoneExtension","Gender","DateOfBirth","Privacy","OptOut","OptOutToShare","PersonalDataUseExplicitConsent"],AddressInformation:["AutocompleteLocation","AddressType","AddressLine1","AddressLine2","Country","City","Province","PostalCode"],AdditionInformation:["Attribute1","Attribute2","Attribute3","Attribute4","Attribute5"],AdditionInfomationOtherFields:["OptOut","OptOutToShare","AllowDistributionOfDetails"],AdditionInfomationCustomFields:["Attribute1","Attribute2","Attribute3","Attribute4","Attribute5"]};var mt=t(51126),vt=(t(8638),t(16271)),rt=t(40117),Y=t(11147),gt=t(6990);const ct=(V,st)=>dt=>{const ut=dt,Pt=ut.get(V),bt=ut.get(st);if(!(0,gt.isNil)(Pt.value)&&!(0,gt.isNil)(bt.value)){const Rt=Pt.value.toString();if(bt.value.toString()===Rt)return null}return{passwordsMatch:!0}};t(72843);var _t=t(80496)},80496:(Z,K,t)=>{"use strict";t.d(K,{CT:()=>y,I2:()=>e,M7:()=>T,MQ:()=>D,Qj:()=>P,R7:()=>I,Wb:()=>i,id:()=>a,jo:()=>_,z1:()=>s});const s={CCRegex:{Mastercard:"^(5[1-5]|2[2-7])\\d{14}$",Visa:"^4\\d{12}(?:\\d{3})?$",Amex:"^3[47][0-9]{13}$",Dinersclub:"^3(?:0[0-5]|[68][0-9])[0-9]{11}$",Discover:"^6(?:011|5\\d{2})\\d{12}$"},CanadaPostalCodeRegex:/^[A-Za-z]\d[A-Za-z][ ]?\d[A-Za-z]\d$/,UnitedStatesPostalCodeRegex:/(^\d{5}$)|(^\d{5}-\d{4}$)/,FrancePostalCodeRegex:/^\d{5}$/,OtherPostalCodeRegex:/^([A-Za-z0-9]|-| ){1,20}$/,CanadaOrUSPhoneRegex:/^\(?([0-9]{3})\)?[-. ]?([0-9]{3})[-. ]?([0-9]{4})$/,MinimumPhoneNumberLength:10,InternationalRegex:/^\d{0,15}$/,CVVRegex:{Mastercard:"^\\d{3}$",Visa:"^\\d{3}$",Amex:"^\\d{4}$",Dinersclub:"^\\d{3}$",Discover:"^\\d{3}$"},Donation:{MinForOnlineDonation:1,MaxForOnlineDonation:1e7},MergeFieldLookup:/\[\%(.*?)\%\]/g,PasswordCriteriaRegex:[/[\d]+/,/[a-z]+/,/[A-Z]+/,/[^\dA-Za-z]+/],MinYearOfBirth:1900,EmailRegex:/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/},e={inputWrapDouble:"input-wrap--double",inputWrapHalf:"input-wrap--half"},_=new RegExp("^(?!.*(<([^>]+)>)).*$"),i=(new RegExp(['^(([^<>()[\\]\\\\.,;:\\s@\\"]+(\\.[^<>()[\\]\\\\.,;:\\s@\\"]+)*)','|(\\".+\\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.',"[0-9]{1,3}\\])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$"].join("")),{RUSSIA:"Russia"}),P={minLength:8,maxLength:20},D={SevenDigit:"$1-$2",TenDigit:"$1-$2-$3",FifteenDigit:"$1"},I={Canada:"$1 $2",UnitedStatesTenDigits:"$1-$2"},T={DC:"D.C.",DISTRICT_OF_COLUMBIA:"District of Columbia"},a={minLength:6,maxLength:20},y="network-only"},3983:(Z,K,t)=>{"use strict";t.d(K,{U:()=>P});var s=t(97582),e=t(56223),_=t(17715),n=t(32181),i=t(65879);let P=class De{constructor(I){this.ngControl=I}ngOnInit(){this.applyMaskOnChanges()}applyMaskOnChanges(){let I=!1;this.ngControl.control.valueChanges.pipe((0,n.h)(()=>{const T=I;return I=!1,!T}),(0,_.t)(this)).subscribe(T=>{let a=T&&T.replace(/([^0-9, \.])/g,"").trim();T&&0===T.indexOf("-")&&(a=`-${a}`),T!==a&&(I=!0,this.ngControl.control.setValue(a))})}static#t=this.\u0275fac=function(T){return new(T||De)(i.Y36(e.a5))};static#e=this.\u0275dir=i.lG2({type:De,selectors:[["","rxGlobalizedFloatMask","","formControlName",""],["","rxGlobalizedFloatMask","","formControl",""]]})};P=(0,s.gn)([(0,_.c)(),(0,s.w6)("design:paramtypes",[e.a5])],P)},43495:(Z,K,t)=>{"use strict";t.d(K,{B:()=>_});var s=t(65879),e=t(56223);let _=(()=>{class n{constructor(P,D,I){this.el=P,this.formControlNameDir=D,this.formControlDir=I}ngOnInit(){if(this.formControlNameDir){const P=this.formControlNameDir.formDirective;P.form&&(P.getControl(this.formControlNameDir).nativeElement=this.el.nativeElement)}else this.formControlDir&&(this.formControlDir.control.nativeElement=this.el.nativeElement)}static#t=this.\u0275fac=function(D){return new(D||n)(s.Y36(s.SBq),s.Y36(e.u,8),s.Y36(e.oH,8))};static#e=this.\u0275dir=s.lG2({type:n,selectors:[["","formControlName",""],["","formControl",""]]})}return n})()},39550:(Z,K,t)=>{"use strict";t.d(K,{v:()=>P});var s=t(97582),e=t(65879),_=t(56223),n=t(33058),i=t(17715);let P=class Oe{constructor(I,T,a){this.el=I,this.formService=T,this.model=a,this.isChanging=!1}get phoneDataEntryRule(){const I=this.inputField?.link?.countryId;return this.formService.getPhoneDataEntryRules(I)}ngOnInit(){this.model.control.valueChanges.pipe((0,i.t)(this)).subscribe(I=>this.updateMaskedPhoneValue(I)),this.updateMaskedPhoneValue(this.model.control.value)}onKeyPress(I){this.phoneDataEntryRule.isValueValid(I.key)||I.preventDefault()}updateMaskedPhoneValue(I){if(!this.isChanging){this.isChanging=!0;try{const T=this.el.nativeElement.selectionStart,a=this.phoneDataEntryRule.mask(I);a!==this.formGroup.controls.phone.value&&(this.formGroup.controls.phone.patchValue(a),setTimeout(()=>{const y=this.getTransformedCursorPosition(I,a,T);this.el.nativeElement.selectionStart=y,this.el.nativeElement.selectionEnd=y}))}finally{this.isChanging=!1}}}getTransformedCursorPosition(I,T,a){const y=this.phoneDataEntryRule;let f="";for(let C=0;C<a;C++)y.isValueValid(I[C])&&(f+=I[C]);let r=0,u=0;for(;u<T.length&&r<a&&r<f.length;u++)if(y.isValueValid(T[u])){if(T[u]!==f[r])break;r++}return u}static#t=this.\u0275fac=function(T){return new(T||Oe)(e.Y36(e.SBq),e.Y36(n._),e.Y36(_.a5))};static#e=this.\u0275dir=e.lG2({type:Oe,selectors:[["","rxPhoneMask",""]],hostBindings:function(T,a){1&T&&e.NdJ("keypress",function(f){return a.onKeyPress(f)})},inputs:{formGroup:"formGroup",inputField:"inputField"}})};P=(0,s.gn)([(0,i.c)(),(0,s.w6)("design:paramtypes",[e.SBq,n._,_.a5])],P)},65343:(Z,K,t)=>{"use strict";t.d(K,{B:()=>P});var s=t(6990),_=t(33058),n=t(65879),i=t(56223);let P=(()=>{class D{constructor(T,a,y){this.el=T,this.formService=a,this.model=y}onModelChange(T){const a=(0,s.toNumber)((0,s.get)(this.formGroup,"controls.country.value","0")),y=this.formService.maskPostalCode(T,a);this.model.valueAccessor.writeValue(y)}static#t=this.\u0275fac=function(a){return new(a||D)(n.Y36(n.SBq),n.Y36(_._),n.Y36(i.a5))};static#e=this.\u0275dir=n.lG2({type:D,selectors:[["","rxPostalCodeMask",""]],hostBindings:function(a,y){1&a&&n.NdJ("ngModelChange",function(r){return y.onModelChange(r)})},inputs:{formGroup:"formGroup"}})}return D})()},60328:(Z,K,t)=>{"use strict";t.d(K,{c:()=>D});var s=t(72550),e=t(6990),n=t(65879),i=t(56223),P=t(89515);let D=(()=>{class I{constructor(a,y,f,r,u){this.ngControl=a,this.elementRef=y,this.renderer=f,this.translateService=r,this.globalizeUtils=u,this.ngControl.valueAccessor=this}get inputElement(){return this.elementRef.nativeElement}get culture(){return this.translateService.currentLang}onBlur(){this.onTouch()}onInput(){this.value=this.globalizeUtils.isValidPattern(this.inputElement.value,this.culture)?this.convertRawTextToNumber(this.inputElement.value):NaN,this.onChange(this.value)}convertRawTextToNumber(a){if((0,e.isFinite)(a))return a;const y=!(0,e.isEmpty)(a)&&this.globalizeUtils.parseAsNumber(a,this.culture);return(0,e.isFinite)(y)?y:null}writeValue(a){this.value=this.convertRawTextToNumber(a),this.renderer.setProperty(this.inputElement,"value",this.globalizeUtils.formatGlobalizedAmount(this.value,this.culture))}registerOnChange(a){this.onChange=a}registerOnTouched(a){this.onTouch=a}setDisabledState(a){this.renderer.setProperty(this.inputElement,"disabled",a||null)}static#t=this.\u0275fac=function(y){return new(y||I)(n.Y36(i.a5),n.Y36(n.SBq),n.Y36(n.Qsj),n.Y36(P.sK),n.Y36(s.h$))};static#e=this.\u0275dir=n.lG2({type:I,selectors:[["input","type","text","pcTextToNumber",""]],hostBindings:function(y,f){1&y&&n.NdJ("blur",function(){return f.onBlur()})("input",function(){return f.onInput()})}})}return I})()},73712:(Z,K,t)=>{"use strict";t.d(K,{c:()=>s});var s=function(e){return e[e.Canada=1]="Canada",e[e.UnitedStates=2]="UnitedStates",e[e.France=74]="France",e}(s||{})},51126:(Z,K,t)=>{"use strict";t.d(K,{u:()=>s});var s=function(e){return e[e.Participant=1]="Participant",e[e.Donor=2]="Donor",e[e.Volunteer=3]="Volunteer",e[e.DirectMailDonor=4]="DirectMailDonor",e[e.OtherDonor=5]="OtherDonor",e[e.BillingContact=6]="BillingContact",e[e.PurchaserDonor=7]="PurchaserDonor",e[e.OfflineDonorForAdministrator=8]="OfflineDonorForAdministrator",e[e.OfflineDonorForParticipant=9]="OfflineDonorForParticipant",e[e.AdditionalParticipants=10]="AdditionalParticipants",e[e.Attendee=11]="Attendee",e}(s||{})},62110:(Z,K,t)=>{"use strict";t.d(K,{V:()=>m});var s=t(72550),e=t(6990),n=t(65879),i=t(89515),P=t(96814),D=t(24607),I=t(33409);const T=function(p){return[p]};function a(p,O){if(1&p&&(n._UZ(0,"div",2),n.ALo(1,"localize"),n.ALo(2,"localize")),2&p){const F=n.oxw();n.Q6J("innerHtml",n.lcZ(1,1,F.reqMessage)||n.xi3(2,3,"err_IsRequiredField2",n.VKq(6,T,F.fieldTitle)),n.oJD)}}function y(p,O){if(1&p&&(n._UZ(0,"div",2),n.ALo(1,"localize"),n.ALo(2,"localize")),2&p){const F=n.oxw();n.Q6J("innerHtml",n.lcZ(1,1,F.reqMessage)||n.xi3(2,3,"err_IsInvalidField1",n.VKq(6,T,F.fieldTitle)),n.oJD)}}function f(p,O){if(1&p&&(n._UZ(0,"div",3),n.ALo(1,"localize")),2&p){const F=n.oxw();n.Q6J("innerHtml",n.xi3(1,1,F.minMessage,n.VKq(4,T,F.fieldParams[0])),n.oJD)}}function r(p,O){if(1&p&&(n._UZ(0,"div",2),n.ALo(1,"localize")),2&p){const F=n.oxw();n.Q6J("innerHtml",n.xi3(1,1,F.maxMessage,1===F.fieldParams.length?n.VKq(4,T,F.fieldParams[0]):F.fieldParams),n.oJD)}}function u(p,O){1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p&&n.Q6J("innerHtml",n.lcZ(1,1,"err_Password_Format"),n.oJD)}function C(p,O){1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p&&n.Q6J("innerHtml",n.lcZ(1,1,"err_InvalidPassword"),n.oJD)}function L(p,O){1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p&&n.Q6J("innerHtml",n.lcZ(1,1,"err_Username_InUse"),n.oJD)}function g(p,O){1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p&&n.Q6J("innerHtml",n.lcZ(1,1,"err_AlreadyRegisteredParticipant"),n.oJD)}function c(p,O){1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p&&n.Q6J("innerHtml",n.lcZ(1,1,"UI.ERROR.err_Amount_Format"),n.oJD)}function l(p,O){1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p&&n.Q6J("innerHtml",n.lcZ(1,1,"UI.ERROR.err_Amount_Format"),n.oJD)}function d(p,O){1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p&&n.Q6J("innerHtml",n.lcZ(1,1,"donationAmountMessage"),n.oJD)}function A(p,O){1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p&&n.Q6J("innerHtml",n.lcZ(1,1,"err_CantCheckoutCartEmpty"),n.oJD)}function S(p,O){if(1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p){const F=n.oxw();n.Q6J("innerHtml",F.stringFormat(n.lcZ(1,1,"err_Invalid_Promo_Code"),F.fieldParams),n.oJD)}}function v(p,O){if(1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p){const F=n.oxw();n.Q6J("innerHtml",n.xi3(1,1,"err_PromoCodeAppliedGreaterValue",F.fieldParams),n.oJD)}}function b(p,O){if(1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p){const F=n.oxw();n.Q6J("innerHtml",n.xi3(1,1,"err_CardType_Number_Mismatch",F.fieldParams),n.oJD)}}function M(p,O){if(1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p){const F=n.oxw();n.Q6J("innerHtml",n.xi3(1,1,"err_ExpirationDate_Invalid",F.fieldParams),n.oJD)}}function R(p,O){if(1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p){const F=n.oxw();n.Q6J("innerHtml",n.xi3(1,1,"err_IsInvalidField1",F.fieldTitle),n.oJD)}}function B(p,O){1&p&&(n._UZ(0,"div",2),n.ALo(1,"translate")),2&p&&n.Q6J("innerHtml",n.lcZ(1,1,"err_RepeatPassword_Compare"),n.oJD)}function E(p,O){if(1&p&&(n._UZ(0,"div",2),n.ALo(1,"safeHtml")),2&p){const F=n.oxw();n.Q6J("innerHtml",n.lcZ(1,1,F.errors),n.oJD)}}let m=(()=>{class p{get fieldTitle(){return(0,e.isNil)(this.title)||(0,e.isEmpty)(this.title)?(0,e.isNil)(this.field)?"":this.translate.instant(this.field.title):this.translate.instant(this.title)}constructor(F,H){this.translate=F,this.globalizedCurrencyPipe=H,this.cssClass=!0}stringFormat(F,H){if(!F)return"";if(!H)return F;let W=F;for(let tt=0;tt<H.length;++tt)W=W.replace(`{${tt}}`,H[tt]);return W}ngOnChanges(F){if(this.requiredMessage="err_IsRequiredField2",!(0,e.isNil)(F.reqMessage)&&!(0,e.isEmpty)(this.reqMessage)&&(this.requiredMessage=this.reqMessage),this.fieldErrors=(0,e.isEmpty)(this.reqMessage)?this.errors:this.reqMessage,this.isStringError="string"==typeof this.errors,!(0,e.isNil)(F.errors))if((0,e.get)(this.errors,"donationAmount",!1))this.fieldParams=[this.field.min,this.field.max],this.donationAmountMessage=this.stringFormat("err_Amount_Range2",[this.fieldTitle]);else if((0,e.get)(this.errors,"promoCodeNotApplicable",!1)){let H=(0,e.get)(this.errors,"promoCodeNotApplicable.promoCode",null);(0,e.isNil)(H)&&(H=this.fieldTitle),this.fieldParams=[H]}else if(!(0,e.isNil)(this.field))switch(this.field.name){case"password":this.minMessage="err_Password_Length",this.maxMessage="err_Password_Length",this.fieldParams=[this.fieldTitle];break;case"username":this.minMessage="err_Username_Format2",this.maxMessage="err_Username_Format2",this.fieldParams=[this.fieldTitle];break;case"goal":this.minMessage="err_FundraisingGoal_Minimum",this.maxMessage="err_FundraisingGoal_Range",this.fieldParams=[this.globalizedCurrencyPipe.transform(this.field.min),this.globalizedCurrencyPipe.transform(this.field.max)];break;case"store-item":(0,e.get)(this.errors,"min",!1)&&(this.fieldParams=[this.fieldTitle,(0,e.get)(this.errors,"min.min",null)],this.minMessage=this.stringFormat(this.translate.instant("err_LessThanMinimumQuantity"),this.fieldParams)),(0,e.get)(this.errors,"max",!1)&&(this.fieldParams=[this.fieldTitle,(0,e.get)(this.errors,"max.max",null)],this.maxMessage=this.stringFormat(this.translate.instant("err_ExceededMaximumQuantity"),this.fieldParams));break;case"acceptOnBehalf":this.requiredMessage=this.translate.instant("err_AgreeToWaiver");break;case"customHonorRollText":this.maxMessage="err_HonorRollCustomTextIsTooLong";break;default:this.minMessage="err_IsTooShort",this.maxMessage="err_IsTooLong",this.fieldParams=[(0,e.get)(this,"title",(0,e.get)(this.field,"title"))]}}static#t=this.\u0275fac=function(H){return new(H||p)(n.Y36(i.sK),n.Y36(s.Ng))};static#e=this.\u0275cmp=n.Xpm({type:p,selectors:[["rx-errors"]],hostVars:2,hostBindings:function(H,W){2&H&&n.ekj("raisin-errors",W.cssClass)},inputs:{errors:"errors",field:"field",title:"title",reqMessage:"reqMessage"},features:[n.TTD],decls:19,vars:19,consts:[["class","error-message",3,"innerHtml",4,"ngIf"],["class","error-message min",3,"innerHtml",4,"ngIf"],[1,"error-message",3,"innerHtml"],[1,"error-message","min",3,"innerHtml"]],template:function(H,W){1&H&&(n.YNc(0,a,3,8,"div",0),n.YNc(1,y,3,8,"div",0),n.YNc(2,f,2,6,"div",1),n.YNc(3,r,2,6,"div",0),n.YNc(4,u,2,3,"div",0),n.YNc(5,C,2,3,"div",0),n.YNc(6,L,2,3,"div",0),n.YNc(7,g,2,3,"div",0),n.YNc(8,c,2,3,"div",0),n.YNc(9,l,2,3,"div",0),n.YNc(10,d,2,3,"div",0),n.YNc(11,A,2,3,"div",0),n.YNc(12,S,2,3,"div",0),n.YNc(13,v,2,4,"div",0),n.YNc(14,b,2,4,"div",0),n.YNc(15,M,2,4,"div",0),n.YNc(16,R,2,4,"div",0),n.YNc(17,B,2,3,"div",0),n.YNc(18,E,2,3,"div",0)),2&H&&(n.Q6J("ngIf",null==W.errors?null:W.errors.required),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.pattern),n.xp6(1),n.Q6J("ngIf",(null==W.errors?null:W.errors.min)||(null==W.errors?null:W.errors.minlength)),n.xp6(1),n.Q6J("ngIf",(null==W.errors?null:W.errors.max)||(null==W.errors?null:W.errors.maxlength)),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.passwordFormat),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.validPassword),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.usernameExists),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.participantIsNotUnique),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.globalizedCurrency),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.globalizedFloat),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.donationAmount),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.cartItemsRequired),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.promoCodeNotApplicable),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.promoCodeLesserValue),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.inValidCreditCard),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.inValidCreditCardExpiryDate),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.inValidPassword),n.xp6(1),n.Q6J("ngIf",null==W.errors?null:W.errors.passwordsMatch),n.xp6(1),n.Q6J("ngIf",W.errors&&W.isStringError))},dependencies:[P.O5,i.X$,D.F,I.z],styles:[".mat-mdc-form-field-error:before{display:none}.raisin-errors .error-message{display:none}.raisin-errors .error-message:first-child{display:block;margin:0}\n"],encapsulation:2})}return p})()},56417:(Z,K,t)=>{"use strict";t.d(K,{e:()=>wt});var s=t(2032),e=t(98525),_=t(6990),n=t(18282),i=t(65879),P=t(96814),D=t(64170),I=t(75986),T=t(23680),a=t(38034),y=t(87466),f=t(56223),r=t(27509),u=t(62110),C=t(39550),L=t(65343),g=t(60328),c=t(3983),l=t(33058),d=t(37398),A=t(32181),S=t(30812),v=t(59773),b=t(26306),M=t(78645),R=t(99080),B=t(22096);let E=(()=>{class k{constructor(x,Q,lt){this.formService=Q,this.renderer=lt,this.unsubscribe$=new M.x,this.element=x.nativeElement}ngOnInit(){try{this.googleObj.subscribe(x=>{this.initAddressControls();const Q=new x.maps.places.Autocomplete(this.element);x.maps.event.addListener(Q,"place_changed",()=>{this.updateAddressControls(this.getFormattedAddress(Q.getPlace()))})})}catch{console.error("failed to add places autocomplete functionality")}}ngOnDestroy(){this.unsubscribe$.next(),this.unsubscribe$.complete()}get googleObj(){return(0,R.H)(0,2e3).pipe((0,d.U)(()=>window.google),(0,A.h)(x=>x),(0,S.o)(x=>!x,!0),(0,v.R)(this.unsubscribe$))}initAddressControls(){const x=this.addressFormGroup.controls;x&&(this.addressLine1Control=x.addressLine1&&x.addressLine1,this.cityControl=x.city&&x.city,this.provinceControl=x.province&&x.province,this.countryControl=x.country&&x.country,this.postalCodeControl=x.postalCode&&x.postalCode)}getFormattedAddress(x){const Q={city:null,country:null,countryCode:null,formatted_address:null,postalCode:null,province:null,provinceCode:null,streetName:null,streetNumber:null};return x?.address_components?(x.address_components.forEach(lt=>{Q.formatted_address=x.formatted_address,lt.types.indexOf("locality")>-1?Q.city=lt.long_name:lt.types.indexOf("administrative_area_level_1")>-1?(Q.province=lt.long_name,Q.provinceCode=lt.short_name):lt.types.indexOf("street_number")>-1?Q.streetNumber=lt.short_name:lt.types.indexOf("route")>-1?Q.streetName=lt.long_name:lt.types.indexOf("country")>-1?(Q.country=lt.long_name,Q.countryCode=lt.short_name):lt.types.indexOf("postal_code")>-1&&(Q.postalCode=lt.short_name)}),Q):null}updateAddressControls(x){return this.getCountryId(x.country,x.countryCode).then(Q=>this.getProvinceId(Q,x.province,x.provinceCode).then(lt=>(console.log("For country",Q,"province name",x.province,"province code",x.provinceCode,"resolved to ",lt),{countryId:Q,provinceId:lt}))).then(({countryId:Q,provinceId:lt})=>{if(console.log("updating address for country ",Q," and province ",lt),this.addressLine1Control){let Et="";x.streetNumber&&(Et=x.streetNumber),x.streetName&&(Et=`${Et} ${x.streetName}`),this.addressLine1Control.setValue(Et),this.renderer.setProperty(this.element,"value",Et)}this.countryControl&&this.countryControl.setValue(Q?Q.toString():null),this.provinceControl&&this.provinceControl.setValue(lt?lt.toString():null),this.cityControl&&this.cityControl.setValue(x.city),this.postalCodeControl&&this.postalCodeControl.setValue(x.postalCode)})}getCountryId(x,Q){return(0,_.isEmpty)(x)&&(0,_.isEmpty)(Q)?Promise.resolve(null):new Promise(lt=>{const Et=(0,_.isEmpty)(x)?null:this.formService.getCountryCodeByName(x);Et?lt(+Et):this.formService.getCountries(null,x,Q).pipe((0,b.K)(()=>(0,B.of)([]))).toPromise().then(yt=>lt((0,_.isEmpty)(yt)?null:+yt[0].id))})}getProvinceId(x,Q,lt){return!x||(0,_.isEmpty)(Q)&&(0,_.isEmpty)(lt)?Promise.resolve(null):new Promise(Et=>{const yt=(0,_.isEmpty)(Q)?null:this.formService.getProvinceCodeByNameAndCountryId(Q,x.toString());yt?Et(+yt):this.formService.getCountryRegions(x,null,Q,lt).pipe((0,b.K)(()=>(0,B.of)([]))).toPromise().then($t=>Et((0,_.isEmpty)($t)?null:+$t[0].id))})}static#t=this.\u0275fac=function(Q){return new(Q||k)(i.Y36(i.SBq),i.Y36(l._),i.Y36(i.Qsj))};static#e=this.\u0275dir=i.lG2({type:k,selectors:[["","google-place",""]],inputs:{addressFormGroup:"addressFormGroup"}})}return k})();var m=t(43495),p=t(89515),O=t(24607),F=t(33409),H=t(35560);function W(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}function tt(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}function j(k,X){1&k&&i._UZ(0,"mat-option")}function z(k,X){if(1&k&&(i.TgZ(0,"mat-option",23),i._uU(1),i.qZA()),2&k){const x=X.$implicit;i.Q6J("value",x.value),i.xp6(1),i.Oqu(x.text)}}function q(k,X){if(1&k&&(i.TgZ(0,"mat-select",21),i.YNc(1,j,1,0,"mat-option",19),i.YNc(2,z,2,2,"mat-option",22),i.qZA()),2&k){const x=i.oxw(3);i.s9C("aria-label",x.field.title),i.Q6J("formControlName",x.field.name)("id",x.field.name),i.xp6(1),i.Q6J("ngIf",!x.field.required),i.xp6(1),i.Q6J("ngForOf",x.field.availableOptions)}}function at(k,X){if(1&k&&(i.TgZ(0,"option",23),i._uU(1),i.qZA()),2&k){const x=X.$implicit;i.Q6J("value",x.value),i.xp6(1),i.Oqu(x.text)}}function nt(k,X){if(1&k&&(i.TgZ(0,"select",24),i._UZ(1,"option"),i.YNc(2,at,2,2,"option",22),i.qZA()),2&k){const x=i.oxw(3);i.Q6J("formControlName",x.field.name)("id",x.field.name),i.xp6(2),i.Q6J("ngForOf",x.field.availableOptions)}}function et(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function o(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function mt(k,X){if(1&k&&(i.TgZ(0,"div",13),i.YNc(1,W,2,4,"mat-label",14),i.TgZ(2,"mat-form-field",15),i.YNc(3,tt,2,4,"mat-label",14),i.YNc(4,q,3,5,"mat-select",16),i.YNc(5,nt,3,3,"select",17),i.YNc(6,et,3,3,"span",18),i.YNc(7,o,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.uIk("data-private",x.field.isPrivateData),i.xp6(1),i.Q6J("ngIf",x.field.isExternalLabel&&x.isEnabled()),i.xp6(2),i.Q6J("ngIf",!x.field.isExternalLabel),i.xp6(1),i.Q6J("ngIf",!x.isMobile),i.xp6(1),i.Q6J("ngIf",x.isMobile),i.xp6(1),i.Q6J("ngIf",!x.field.required),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function ft(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}function G(k,X){if(1&k&&(i.TgZ(0,"mat-label"),i._uU(1),i.qZA()),2&k){const x=i.oxw(3);i.uIk("for",x.field.name),i.xp6(1),i.Oqu(x.field.title)}}function vt(k,X){if(1&k&&(i.TgZ(0,"div",31),i._uU(1),i.ALo(2,"customCurrency"),i.qZA()),2&k){const x=X.ngIf;i.xp6(1),i.hij(" ",i.lcZ(2,1,x)," ")}}function rt(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function Y(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function gt(k,X){if(1&k&&(i.TgZ(0,"div",27),i.YNc(1,ft,2,4,"mat-label",14),i.TgZ(2,"mat-form-field",28),i.YNc(3,G,2,2,"mat-label",19),i._UZ(4,"input",29),i.YNc(5,vt,3,3,"div",30),i.YNc(6,rt,3,3,"span",18),i.YNc(7,Y,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(1),i.Q6J("ngIf",x.field.isExternalLabel&&x.isEnabled()),i.xp6(2),i.Q6J("ngIf",!x.field.isExternalLabel),i.xp6(1),i.ekj("hide-spinner",x.field.isCurrency),i.Q6J("formControlName",x.field.name)("id",x.field.name)("autocomplete",x.field.autocomplete)("required",x.field.required),i.uIk("aria-label",x.field.title),i.xp6(1),i.Q6J("ngIf",x.field.isCurrency&&(null==x.form.controls[x.field.name]?null:x.form.controls[x.field.name].value)),i.xp6(1),i.Q6J("ngIf",!x.field.required),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function ct(k,X){if(1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.ALo(3,"currency"),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.AsE("",i.lcZ(2,2,"lbl_Suggested_Goal")," ",i.gM2(3,4,x.field.suggestedGoal,"CAD","symbol-narrow","1.0-0"),"")}}function ot(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function _t(k,X){if(1&k&&(i.TgZ(0,"div",27)(1,"mat-form-field",15)(2,"mat-label"),i._uU(3),i.qZA(),i._UZ(4,"input",32),i.YNc(5,ct,4,9,"span",18),i.YNc(6,ot,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(2),i.uIk("for",x.field.name),i.xp6(1),i.Oqu(x.field.title),i.xp6(1),i.Q6J("formControlName",x.field.name)("id",x.field.name)("autocomplete",x.field.autocomplete)("required",x.field.required),i.xp6(1),i.Q6J("ngIf",x.field.suggestedGoal),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function V(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function st(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function dt(k,X){if(1&k&&(i.TgZ(0,"div",33)(1,"mat-form-field",28)(2,"mat-label"),i._uU(3),i.qZA(),i._UZ(4,"input",34),i.YNc(5,V,3,3,"span",18),i.YNc(6,st,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(2),i.uIk("for",x.field.name),i.xp6(1),i.Oqu(x.field.title),i.xp6(1),i.Q6J("formGroup",x.form)("inputField",x.field)("required",x.field.required)("formControlName",x.field.name)("id",x.field.name)("autocomplete",x.field.autocomplete),i.uIk("aria-label",x.field.title),i.xp6(1),i.Q6J("ngIf",!x.field.required),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function ut(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function Pt(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function bt(k,X){if(1&k){const x=i.EpF();i.TgZ(0,"div",27)(1,"mat-form-field",15)(2,"mat-label"),i._uU(3),i.qZA(),i.TgZ(4,"input",35),i.NdJ("blur",function(){i.CHM(x);const lt=i.oxw(2);return i.KtG(lt.onBlur())}),i.qZA(),i.YNc(5,ut,3,3,"span",18),i.YNc(6,Pt,2,2,"mat-error",19),i.qZA()()}if(2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(2),i.uIk("for",x.field.name),i.xp6(1),i.Oqu(x.field.title),i.xp6(1),i.Q6J("formGroup",x.form)("formControlName",x.field.name)("id",x.field.name),i.uIk("aria-label",x.field.title),i.xp6(1),i.Q6J("ngIf",!x.field.required),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function Rt(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}function Mt(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}const Nt=function(k,X){return[k,X]};function Vt(k,X){if(1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"localize"),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.hij(" ",i.xi3(2,1,"txt_AtLeastFromToCharacter",i.WLB(4,Nt,""+x.field.min,""+x.field.max)),"")}}function Ut(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function Bt(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function Dt(k,X){if(1&k){const x=i.EpF();i.TgZ(0,"div",36),i.YNc(1,Rt,2,4,"mat-label",14),i.TgZ(2,"mat-form-field",28),i.YNc(3,Mt,2,4,"mat-label",14),i.TgZ(4,"input",37),i.NdJ("blur",function(){i.CHM(x);const lt=i.oxw(2);return i.KtG(lt.onBlur())}),i.qZA(),i.YNc(5,Vt,3,7,"span",18),i.YNc(6,Ut,3,3,"span",18),i.YNc(7,Bt,2,2,"mat-error",19),i.qZA()()}if(2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.uIk("data-private",x.field.isPrivateData),i.xp6(1),i.Q6J("ngIf",x.field.isExternalLabel&&x.isEnabled()),i.xp6(2),i.Q6J("ngIf",!x.field.isExternalLabel),i.xp6(1),i.Q6J("formControlName",x.field.name)("id",x.field.name)("required",x.hasRequired()),i.uIk("aria-label",x.field.title),i.xp6(1),i.Q6J("ngIf","username"===x.field.name),i.xp6(1),i.Q6J("ngIf",!x.hasRequired()&&"username"!==x.field.name),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function zt(k,X){if(1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"localize"),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.hij(" ",i.xi3(2,1,"txt_AtLeastFromToCharacter",i.WLB(4,Nt,""+x.field.min,""+x.field.max)),"")}}function Jt(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function Yt(k,X){if(1&k&&(i.TgZ(0,"div",27)(1,"mat-form-field",15)(2,"mat-label"),i._uU(3),i.qZA(),i._UZ(4,"input",38),i.YNc(5,zt,3,7,"span",18),i.YNc(6,Jt,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.oxw(2);let Q;i.ekj("input-wrap--long-text-error",x.showErrors(x.field.name)&&(null==(Q=x.getErrors(x.field.name))?null:Q.passwordFormat)),i.Q6J("ngClass",x.field.class),i.xp6(2),i.uIk("for",x.field.name),i.xp6(1),i.Oqu(x.field.title),i.xp6(1),i.Q6J("formControlName",x.field.name)("id",x.field.name),i.uIk("aria-label",x.field.title),i.xp6(1),i.Q6J("ngIf","password"===x.field.name),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function Qt(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}function Xt(k,X){if(1&k&&(i.TgZ(0,"mat-label"),i._uU(1),i.qZA()),2&k){const x=i.oxw(3);i.uIk("for",x.field.name),i.xp6(1),i.Oqu(x.field.title)}}function Lt(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function qt(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function te(k,X){if(1&k&&(i.TgZ(0,"div",27),i.YNc(1,Qt,2,4,"mat-label",14),i.TgZ(2,"mat-form-field",15),i.YNc(3,Xt,2,2,"mat-label",19),i._UZ(4,"input",39),i.YNc(5,Lt,3,3,"span",18),i.YNc(6,qt,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(1),i.Q6J("ngIf",x.field.isExternalLabel&&x.isEnabled()),i.xp6(2),i.Q6J("ngIf",!x.field.isExternalLabel),i.xp6(1),i.Q6J("formControlName",x.field.name)("id",x.field.name),i.uIk("aria-label",x.field.title),i.xp6(1),i.Q6J("ngIf",!x.field.required),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function ee(k,X){if(1&k&&(i._UZ(0,"rx-errors",44),i.ALo(1,"translate")),2&k){const x=i.oxw(4);i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)("reqMessage",i.lcZ(1,3,"UI.ERROR.err_CheckRequired"))}}function It(k,X){if(1&k&&i._UZ(0,"rx-errors",26),2&k){const x=i.oxw(4);i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function Ft(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i.YNc(1,ee,2,5,"rx-errors",42),i.YNc(2,It,1,2,"rx-errors",43),i.qZA()),2&k){const x=i.oxw(3);let Q,lt;i.xp6(1),i.Q6J("ngIf",null==(Q=x.getErrors(x.field.name))?null:Q.required),i.xp6(1),i.Q6J("ngIf",!(null!=(lt=x.getErrors(x.field.name))&&lt.required))}}function kt(k,X){if(1&k&&(i.TgZ(0,"div",40)(1,"mat-checkbox",41),i._UZ(2,"span",20),i.ALo(3,"safeHtml"),i.qZA(),i.YNc(4,Ft,3,2,"mat-error",19),i.qZA()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class)("id",x.field.name),i.xp6(1),i.Q6J("aria-label",x.field.title)("formControlName",x.field.name),i.xp6(1),i.Q6J("innerHtml",i.lcZ(3,6,x.field.title),i.oJD),i.xp6(2),i.Q6J("ngIf",x.showErrors(x.field.name))}}function ie(k,X){if(1&k){const x=i.EpF();i.TgZ(0,"div",45)(1,"mat-checkbox",46),i.NdJ("change",function(lt){i.CHM(x);const Et=i.oxw(2);return i.KtG(Et.checkboxChange(lt))}),i._uU(2),i.qZA()()}if(2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(1),i.Q6J("aria-label",x.field.title)("formControlName",x.field.name),i.xp6(1),i.hij(" ",x.field.title,"")}}function ne(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function se(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function re(k,X){if(1&k&&(i.TgZ(0,"div",47),i._UZ(1,"mat-datepicker-toggle",48),i.TgZ(2,"mat-form-field",15)(3,"mat-label"),i._uU(4),i.qZA(),i._UZ(5,"input",49),i.ALo(6,"translate"),i.YNc(7,ne,3,3,"span",18),i._UZ(8,"mat-datepicker",50,51),i.YNc(10,se,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.MAs(9),Q=i.oxw(2);i.xp6(1),i.Q6J("for",x)("disableRipple",!0),i.xp6(2),i.uIk("for",Q.field.name),i.xp6(1),i.Oqu(Q.field.title),i.xp6(1),i.s9C("placeholder",i.lcZ(6,12,"UI.DateOfBirthPattern")),i.Q6J("matDatepicker",x)("formControlName",Q.field.name)("max",Q.maxDate),i.uIk("aria-label",Q.field.title),i.xp6(2),i.Q6J("ngIf",!Q.field.required),i.xp6(1),i.Q6J("touchUi",Q.isMobile),i.xp6(2),i.Q6J("ngIf",Q.showErrors(Q.field.name))}}function oe(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml"),i.ALo(2,"translate")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,i.lcZ(2,4,x.field.title)),i.oJD),i.uIk("for",x.field.name)}}function ae(k,X){if(1&k&&(i.TgZ(0,"mat-label"),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k){const x=i.oxw(3);i.uIk("for",x.field.name),i.xp6(1),i.Oqu(i.lcZ(2,2,x.field.title))}}function le(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function Kt(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function ce(k,X){if(1&k&&(i.TgZ(0,"div",27),i.YNc(1,oe,3,6,"mat-label",14),i.TgZ(2,"mat-form-field",15),i.YNc(3,ae,3,4,"mat-label",19),i._UZ(4,"input",52,53),i.ALo(6,"translate"),i.YNc(7,le,3,3,"span",18),i.YNc(8,Kt,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(1),i.Q6J("ngIf",x.field.isExternalLabel&&x.isEnabled()),i.xp6(2),i.Q6J("ngIf",!x.field.isExternalLabel),i.xp6(1),i.Q6J("addressFormGroup",x.form)("formControlName",x.field.name)("id",x.field.name),i.uIk("aria-label",i.lcZ(6,9,x.field.title)),i.xp6(3),i.Q6J("ngIf",!x.field.required),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function xt(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}function de(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}function ue(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function he(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function ge(k,X){if(1&k&&(i.TgZ(0,"div",54),i.YNc(1,xt,2,4,"mat-label",14),i.TgZ(2,"mat-form-field",15),i.YNc(3,de,2,4,"mat-label",14),i._UZ(4,"textarea",55),i.YNc(5,ue,3,3,"span",18),i.YNc(6,he,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(1),i.Q6J("ngIf",x.field.isExternalLabel&&x.isEnabled()),i.xp6(2),i.Q6J("ngIf",!x.field.isExternalLabel),i.xp6(1),i.Q6J("mat-autosize",!0)("matAutosizeMinRows",1)("formControlName",x.field.name)("id",x.field.name),i.uIk("aria-label",x.field.title),i.xp6(1),i.Q6J("ngIf",!x.hasRequired()),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function me(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function Ot(k,X){if(1&k&&(i.TgZ(0,"mat-radio-button",23),i._uU(1),i.qZA()),2&k){const x=X.$implicit;i.Q6J("value",x.value),i.xp6(1),i.hij(" ",x.text," ")}}function pe(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function Wt(k,X){if(1&k&&(i.TgZ(0,"div",56)(1,"div",57)(2,"div",58),i._UZ(3,"div",59),i.ALo(4,"safeHtml"),i.YNc(5,me,3,3,"span",18),i.qZA(),i.TgZ(6,"mat-radio-group",60),i.YNc(7,Ot,2,2,"mat-radio-button",22),i.qZA()(),i.YNc(8,pe,2,2,"mat-error",19),i.qZA()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(1),i.ekj("radio-field-wrapper--invalid",x.showErrors(x.field.name)&&x.getErrors(x.field.name)),i.xp6(2),i.Q6J("innerHtml",i.lcZ(4,10,x.field.title),i.oJD),i.xp6(2),i.Q6J("ngIf",!x.hasRequired()),i.xp6(1),i.Q6J("formControlName",x.field.name)("id",x.field.name),i.uIk("aria-label",x.field.title),i.xp6(1),i.Q6J("ngForOf",x.field.availableOptions),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function Gt(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}function Ht(k,X){if(1&k&&(i._UZ(0,"mat-label",20),i.ALo(1,"safeHtml")),2&k){const x=i.oxw(3);i.Q6J("innerHtml",i.lcZ(1,2,x.field.title),i.oJD),i.uIk("for",x.field.name)}}function fe(k,X){if(1&k&&(i.TgZ(0,"mat-option",23),i._uU(1),i.qZA()),2&k){const x=X.$implicit;i.Q6J("value",x.value),i.xp6(1),i.hij("",x.text," ")}}function ve(k,X){if(1&k&&(i.TgZ(0,"mat-select",63),i.YNc(1,fe,2,2,"mat-option",22),i.qZA()),2&k){const x=i.oxw(3);i.Q6J("formControlName",x.field.name)("id",x.field.name),i.uIk("aria-label",x.field.name),i.xp6(1),i.Q6J("ngForOf",x.field.availableOptions)}}function _e(k,X){if(1&k&&(i.TgZ(0,"option",23),i._uU(1),i.qZA()),2&k){const x=X.$implicit;i.Q6J("value",x.value),i.xp6(1),i.hij("",x.text," ")}}function Ee(k,X){if(1&k&&(i.TgZ(0,"select",64),i._UZ(1,"option"),i.YNc(2,_e,2,2,"option",22),i.qZA()),2&k){const x=i.oxw(3);i.Q6J("formControlName",x.field.name)("id",x.field.name),i.xp6(2),i.Q6J("ngForOf",x.field.availableOptions)}}function Ce(k,X){1&k&&(i.TgZ(0,"span",25),i._uU(1),i.ALo(2,"translate"),i.qZA()),2&k&&(i.xp6(1),i.Oqu(i.lcZ(2,1,"lblOptional")))}function Pe(k,X){if(1&k&&(i.TgZ(0,"mat-error"),i._UZ(1,"rx-errors",26),i.qZA()),2&k){const x=i.oxw(3);i.xp6(1),i.Q6J("errors",x.getErrors(x.field.name))("field",x.field)}}function Ie(k,X){if(1&k&&(i.TgZ(0,"div",27),i.YNc(1,Gt,2,4,"mat-label",14),i.TgZ(2,"mat-form-field",15),i.YNc(3,Ht,2,4,"mat-label",14),i.YNc(4,ve,2,4,"mat-select",61),i.YNc(5,Ee,3,3,"select",62),i.YNc(6,Ce,3,3,"span",18),i.YNc(7,Pe,2,2,"mat-error",19),i.qZA()()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(1),i.Q6J("ngIf",x.field.isExternalLabel&&x.isEnabled()),i.xp6(2),i.Q6J("ngIf",!x.field.isExternalLabel),i.xp6(1),i.Q6J("ngIf",!x.isMobile),i.xp6(1),i.Q6J("ngIf",x.isMobile),i.xp6(1),i.Q6J("ngIf",!x.field.required),i.xp6(1),i.Q6J("ngIf",x.showErrors(x.field.name))}}function Se(k,X){if(1&k&&(i.TgZ(0,"div",65),i._UZ(1,"div",66),i.ALo(2,"safeHtml"),i.ALo(3,"translate"),i.qZA()),2&k){const x=i.oxw(2);i.Q6J("ngClass",x.field.class),i.xp6(1),i.Q6J("innerHtml",i.lcZ(2,2,i.lcZ(3,4,x.field.title)),i.oJD)}}function jt(k,X){if(1&k&&(i.TgZ(0,"div",1),i.YNc(1,mt,8,8,"div",2),i.YNc(2,gt,8,13,"div",3),i.YNc(3,_t,7,9,"div",3),i.YNc(4,dt,7,12,"div",4),i.YNc(5,bt,7,9,"div",3),i.YNc(6,Dt,8,11,"div",5),i.YNc(7,Yt,7,10,"div",6),i.YNc(8,te,7,8,"div",3),i.YNc(9,kt,5,8,"div",7),i.YNc(10,ie,3,4,"div",8),i.YNc(11,re,11,14,"div",9),i.YNc(12,ce,9,11,"div",3),i.YNc(13,ge,7,10,"div",10),i.YNc(14,Wt,9,12,"div",11),i.YNc(15,Ie,8,7,"div",3),i.YNc(16,Se,4,6,"div",12),i.qZA()),2&k){const x=i.oxw();i.Q6J("ngSwitch",x.field.type)("formGroup",x.form),i.xp6(1),i.Q6J("ngSwitchCase","dropdownlist"),i.xp6(1),i.Q6J("ngSwitchCase","number"),i.xp6(1),i.Q6J("ngSwitchCase","goal"),i.xp6(1),i.Q6J("ngSwitchCase","tel"),i.xp6(1),i.Q6J("ngSwitchCase","postalCode"),i.xp6(1),i.Q6J("ngSwitchCase","text"),i.xp6(1),i.Q6J("ngSwitchCase","password"),i.xp6(1),i.Q6J("ngSwitchCase","text-masked"),i.xp6(1),i.Q6J("ngSwitchCase","checkbox"),i.xp6(1),i.Q6J("ngSwitchCase","contactType"),i.xp6(1),i.Q6J("ngSwitchCase","dob"),i.xp6(1),i.Q6J("ngSwitchCase","AutocompleteLocation"),i.xp6(1),i.Q6J("ngSwitchCase","textarea"),i.xp6(1),i.Q6J("ngSwitchCase","radio"),i.xp6(1),i.Q6J("ngSwitchCase","checkboxGroup"),i.xp6(1),i.Q6J("ngSwitchCase","info")}}let wt=(()=>{class k{constructor(x,Q,lt){this.viewContainerRef=x,this.fieldDependancyService=Q,this.renderer=lt}ngOnInit(){this.goalFormat=null,this.suggestGoalLabel="UI.lbl_Suggested_Goal",this.isMobile&&(this.goalFormat="1.0-2",this.suggestGoalLabel="UI.lbl_Suggested_Goal_Mobile"),this.maxDate="dob"===this.field.type?new Date:null}ngAfterContentChecked(){"dob"===this.field.type?this.applyDataPrivateAttribute(".mat-datepicker-popup"):"gender"===this.field.name&&this.applyDataPrivateAttribute("#gender-panel")}getErrors(x){return this.form.get(x).errors}checkboxChange(x){"contactType"===this.field.type&&this.fieldDependancyService.setupCompanyNameTrigger(this.form,this.field,x.checked)}hasValue(x){const Q=this.form.get(x);return!(0,_.isNil)(Q.value)&&!(0,_.isEmpty)(Q.value)}clear(x){const Q=this.form.get(x);Q.setValue(null),Q.updateValueAndValidity()}hasRequired(){const x=this.form.get(this.field.name);if(x.validator){const Q=x.validator({});if(Q&&Q.required)return!0}return!1}onBlur(){const x=this.form.get(this.field.name);(0,_.isString)((0,_.get)(x,"value"))&&x.setValue(x.value.trim())}isEnabled(){return this.form.get(this.field.name).enabled}showErrors(x){const Q=this.form.get(x);return Q.invalid&&(Q.dirty||Q.touched)}applyDataPrivateAttribute(x){const Q=this.viewContainerRef.element.nativeElement.ownerDocument.documentElement.querySelector(x);Q&&(Q.getAttribute("data-private")||this.renderer.setAttribute(Q,"data-private","true"))}ngAfterContentInit(){this.focus&&!(0,_.isNil)(this.field.name)&&((0,_.isNil)(this.input)||this.input.focus(),(0,_.isNil)(this.select)||this.select.focus())}static#t=this.\u0275fac=function(Q){return new(Q||k)(i.Y36(i.s_b),i.Y36(n.E),i.Y36(i.Qsj))};static#e=this.\u0275cmp=i.Xpm({type:k,selectors:[["rs-field-input"]],viewQuery:function(Q,lt){if(1&Q&&(i.Gf(s.Nt,5),i.Gf(e.gD,5)),2&Q){let Et;i.iGM(Et=i.CRH())&&(lt.input=Et.first),i.iGM(Et=i.CRH())&&(lt.select=Et.first)}},inputs:{form:"form",field:"field",isMobile:"isMobile",focus:"focus"},decls:1,vars:1,consts:[[3,"ngSwitch","formGroup",4,"ngIf"],[3,"ngSwitch","formGroup"],["class","input-wrap input-wrap--dropdownlist",3,"ngClass",4,"ngSwitchCase"],["class","input-wrap",3,"ngClass",4,"ngSwitchCase"],["class","input-wrap","data-private","",3,"ngClass",4,"ngSwitchCase"],["class","input-wrap text-field",3,"ngClass",4,"ngSwitchCase"],["class","input-wrap",3,"ngClass","input-wrap--long-text-error",4,"ngSwitchCase"],["class","checkbox-wrap checkbox-wrap--margin-bottom",3,"ngClass","id",4,"ngSwitchCase"],["class","checkbox-wrap checkbox-wrap--margin-bottom contact-type","id","contact-type",3,"ngClass",4,"ngSwitchCase"],["class","input-wrap input-wrap--date input-wrap--margin-bottom","data-private","",4,"ngSwitchCase"],["class","input-wrap input-wrap--textarea",3,"ngClass",4,"ngSwitchCase"],["class","input-wrap input-wrap--radio",3,"ngClass",4,"ngSwitchCase"],["class","input-wrap input-wrap--no-response",3,"ngClass",4,"ngSwitchCase"],[1,"input-wrap","input-wrap--dropdownlist",3,"ngClass"],[3,"innerHtml",4,"ngIf"],["appearance","fill"],["aria-live","assertive value",3,"formControlName","id","aria-label",4,"ngIf"],["matNativeControl","","class","matNativeControl",3,"formControlName","id",4,"ngIf"],["matSuffix","","class","optional",4,"ngIf"],[4,"ngIf"],[3,"innerHtml"],["aria-live","assertive value",3,"formControlName","id","aria-label"],[3,"value",4,"ngFor","ngForOf"],[3,"value"],["matNativeControl","",1,"matNativeControl",3,"formControlName","id"],["matSuffix","",1,"optional"],[3,"errors","field"],[1,"input-wrap",3,"ngClass"],["appearance","fill","hideRequiredMarker",""],["matInput","","type","text","pcTextToNumber","",3,"formControlName","id","autocomplete","required"],["class","input-overlay",4,"ngIf"],[1,"input-overlay"],["matInput","","type","text","rxGlobalizedFloatMask","",3,"formControlName","id","autocomplete","required"],["data-private","",1,"input-wrap",3,"ngClass"],["matInput","","rxPhoneMask","","type","tel",3,"formGroup","inputField","required","formControlName","id","autocomplete"],["matInput","","rxPostalCodeMask","","type","text","placeholder","",3,"formGroup","formControlName","id","blur"],[1,"input-wrap","text-field",3,"ngClass"],["matInput","","type","text","placeholder","",3,"formControlName","id","required","blur"],["matInput","","type","password","placeholder","",3,"formControlName","id"],["matInput","","type","text",3,"formControlName","id"],[1,"checkbox-wrap","checkbox-wrap--margin-bottom",3,"ngClass","id"],[3,"aria-label","formControlName"],[3,"errors","field","reqMessage",4,"ngIf"],[3,"errors","field",4,"ngIf"],[3,"errors","field","reqMessage"],["id","contact-type",1,"checkbox-wrap","checkbox-wrap--margin-bottom","contact-type",3,"ngClass"],["disableRipple","true",3,"aria-label","formControlName","change"],["data-private","",1,"input-wrap","input-wrap--date","input-wrap--margin-bottom"],["matPrefix","",3,"for","disableRipple"],["matInput","","id","date-of-birth",3,"matDatepicker","placeholder","formControlName","max"],[3,"touchUi"],["dateOfBirth",""],["matInput","","type","text","google-place","","placeholder","",3,"addressFormGroup","formControlName","id"],["autocompleteLocation",""],[1,"input-wrap","input-wrap--textarea",3,"ngClass"],["matInput","",3,"mat-autosize","matAutosizeMinRows","formControlName","id"],[1,"input-wrap","input-wrap--radio",3,"ngClass"],[1,"radio-field-wrapper"],[1,"radio-label"],[1,"radio-title",3,"innerHtml"],["aria-live","assertive value",1,"radio-group-vertical",3,"formControlName","id"],["multiple","","aria-live","assertive value",3,"formControlName","id",4,"ngIf"],["matNativeControl","","multiple","","aria-live","assertive value","class","matNativeControl",3,"formControlName","id",4,"ngIf"],["multiple","","aria-live","assertive value",3,"formControlName","id"],["matNativeControl","","multiple","","aria-live","assertive value",1,"matNativeControl",3,"formControlName","id"],[1,"input-wrap","input-wrap--no-response",3,"ngClass"],[1,"no-response-title",3,"innerHtml"]],template:function(Q,lt){1&Q&&i.YNc(0,jt,17,18,"div",0),2&Q&&i.Q6J("ngIf",lt.isEnabled())},dependencies:[P.mk,P.sg,P.O5,P.RF,P.n9,s.Nt,D.KE,D.hX,D.TO,D.qo,D.R9,I.oG,e.gD,T.ey,a.Mq,a.hl,a.nW,y.VQ,y.U0,f.YN,f.Kr,f.Fj,f.EJ,f.K7,f.JJ,f.JL,f.Q7,f.sg,f.u,r.oO,u.V,C.v,L.B,g.c,c.U,E,m.B,P.H9,p.X$,O.F,F.z,H.R],styles:["rs-field-input .checkbox-wrap .mat-mdc-form-field-error{font-size:75%}rs-field-input .mat-mdc-checkbox span>p{font-size:inherit!important;color:inherit!important;margin-bottom:0!important}\n"],encapsulation:2})}return k})()},34985:(Z,K,t)=>{"use strict";t.d(K,{n:()=>I});var s=t(65879),e=t(96814),_=t(82761),n=t(89515),i=t(33409);function P(T,a){if(1&T&&(s._UZ(0,"p",4),s.ALo(1,"safeHtml")),2&T){const y=s.oxw(2);s.Q6J("innerHTML",s.lcZ(1,1,y.config.description),s.oJD)}}function D(T,a){if(1&T&&(s.TgZ(0,"section",1)(1,"h2"),s._uU(2),s.ALo(3,"translate"),s.qZA(),s.YNc(4,P,2,3,"p",2),s._UZ(5,"rs-field",3),s.qZA()),2&T){const y=s.oxw();s.xp6(2),s.Oqu(s.lcZ(3,5,y.config.title)),s.xp6(2),s.Q6J("ngIf",y.config.description),s.xp6(1),s.Q6J("isMobile",y.config.isMobile)("formFieldCollection",y.config.fields)("fieldFormGroup",y.config.fieldFormGroup)}}let I=(()=>{class T{constructor(){this.wrapperClass="field-section"}static#t=this.\u0275fac=function(f){return new(f||T)};static#e=this.\u0275cmp=s.Xpm({type:T,selectors:[["rs-field-section"]],hostVars:2,hostBindings:function(f,r){2&f&&s.Tol(r.wrapperClass)},inputs:{config:"config"},decls:1,vars:1,consts:[["class","section-border row clearfix aka-form--fieldset",4,"ngIf"],[1,"section-border","row","clearfix","aka-form--fieldset"],[3,"innerHTML",4,"ngIf"],[3,"isMobile","formFieldCollection","fieldFormGroup"],[3,"innerHTML"]],template:function(f,r){1&f&&s.YNc(0,D,6,7,"section",0),2&f&&s.Q6J("ngIf",r.config)},dependencies:[e.O5,_.C,n.X$,i.z],encapsulation:2})}return T})()},82761:(Z,K,t)=>{"use strict";t.d(K,{C:()=>I});var s=t(65879),e=t(96814),_=t(27509),n=t(56417),i=t(97864);const P=function(T){return{"input-row-end":T}};function D(T,a){if(1&T&&(s.TgZ(0,"div",1),s._UZ(1,"rs-field-input",2),s.qZA()),2&T){const y=a.$implicit,f=s.oxw();s.Tol(null==y?null:y.name),s.Q6J("ngClass",s.VKq(8,P,-1!=(null==y||null==y.class?null:y.class.indexOf(" end")))),s.xp6(1),s.Q6J("form",f.fieldFormGroup)("field",y)("isMobile",f.isMobile)("focus",y.name===f.focusedFieldName)}}let I=(()=>{class T{constructor(){}static#t=this.\u0275fac=function(f){return new(f||T)};static#e=this.\u0275cmp=s.Xpm({type:T,selectors:[["rs-field"]],inputs:{formFieldCollection:"formFieldCollection",fieldFormGroup:"fieldFormGroup",isMobile:"isMobile",focusedFieldName:"focusedFieldName"},decls:2,vars:5,consts:[[3,"ngClass","class",4,"ngFor","ngForOf"],[3,"ngClass"],[3,"form","field","isMobile","focus"]],template:function(f,r){1&f&&(s.YNc(0,D,2,10,"div",0),s.ALo(1,"orderBy")),2&f&&s.Q6J("ngForOf",s.Dn7(1,1,r.formFieldCollection,"sortingOrder",!0))},dependencies:[e.mk,e.sg,_.oO,n.e,i.d],encapsulation:2})}return T})()},54517:(Z,K,t)=>{"use strict";t.d(K,{q:()=>y});var s=t(65879),e=t(56223),_=t(6990),i=t(72550),P=t(89515),D=t(2032),I=t(3983),T=t(43495);const a=["globalizedNumberInput"];let y=(()=>{class f{get currentLang(){return this.translationService.currentLang}constructor(u,C,L){this.translationService=u,this.globalizedCurrencyPipe=C,this.globalizeUtils=L,this.wrapperClass=!0,this.treatNanAsNull=!0,this.clicked=new s.vpe,this.blurred=new s.vpe,this.changed=new s.vpe,this.invalidChange=new s.vpe,this.maskedControl=new e.p4(null,i.vV.globalNumber(this.currentLang))}ngOnInit(){}ngOnChanges(u){const C=(0,_.isNaN)(this.value);this.placeholderTxt=this.placeholder||"lbl_OtherAmount",u.value&&(0,_.isNumber)(this.value)&&!C?this.maskedControl.setValue(this.globalizedCurrencyPipe.transform(+this.value)):(!C||this.treatNanAsNull)&&this.maskedControl.setValue(null),u.focus&&u.focus.currentValue!==u.focus.previousValue&&this.focus&&this.globalizedNumberInput.nativeElement.focus()}onClicked(){0===this.maskedControl?.value&&this.maskedControl.setValue(""),this.clicked.emit()}onValueChanged(u){const C=this.removeAllButLast(this.removeAllButLast(u,"."),",");this.maskedControl.valid?this.changed.emit(this.globalizeUtils.parseGlobalizedFloat(C,this.translationService.currentLang)):this.invalidChange.emit("invalid pattern")}onBlurred(){this.blurred.emit()}removeAllButLast(u,C){if(u.indexOf(C)>=0){const L=u.split(C);return L.slice(0,-1).join("")+C+L.slice(-1)}return u}static#t=this.\u0275fac=function(C){return new(C||f)(s.Y36(P.sK),s.Y36(i.Ng),s.Y36(i.h$))};static#e=this.\u0275cmp=s.Xpm({type:f,selectors:[["rx-globalized-number"]],viewQuery:function(C,L){if(1&C&&s.Gf(a,7),2&C){let g;s.iGM(g=s.CRH())&&(L.globalizedNumberInput=g.first)}},hostVars:2,hostBindings:function(C,L){2&C&&s.ekj("globalized-number",L.wrapperClass)},inputs:{value:"value",placeholder:"placeholder",treatNanAsNull:"treatNanAsNull",focus:"focus"},outputs:{clicked:"clicked",blurred:"blurred",changed:"changed",invalidChange:"invalidChange"},features:[s.TTD],decls:5,vars:7,consts:[[1,"globalized-number-input"],["matInput","","rxGlobalizedFloatMask","","type","text",3,"formControl","placeholder","change","blur","click"],["globalizedNumberInput",""]],template:function(C,L){1&C&&(s.TgZ(0,"div",0)(1,"input",1,2),s.NdJ("change",function(){return L.onValueChanged(L.maskedControl.value)})("blur",function(){return L.onBlurred()})("click",function(){return L.onClicked()}),s.ALo(3,"translate"),s.ALo(4,"translate"),s.qZA()()),2&C&&(s.xp6(1),s.s9C("placeholder",s.lcZ(3,3,L.placeholderTxt)),s.Q6J("formControl",L.maskedControl),s.uIk("aria-label",s.lcZ(4,5,L.placeholderTxt)))},dependencies:[D.Nt,e.Fj,e.JJ,e.oH,I.U,T.B,P.X$],styles:[".globalized-number,.globalized-number .globalized-number-input{display:inline-flex;width:100%}.globalized-number .globalized-number-input input{display:flex;width:100%;text-align:left;text-indent:8px;margin:0;background-color:#fff!important;padding-top:1px;border:none;position:inherit}\n"],encapsulation:2,changeDetection:0})}return f})()},18282:(Z,K,t)=>{"use strict";t.d(K,{E:()=>u});var s=t(56223),e=t(6990),n=t(59215),i=t(59773),P=t(99397),D=t(27921),I=t(63019),T=t(36232),a=t(33058),y=t(73712),f=t(65879),r=t(89515);let u=(()=>{class C{get country(){return this.defaultCountryCode?.toString()??""}get province(){return this.defaultRegionId}constructor(g,c,l){this.formService=g,this.fieldService=c,this.translateService=l}setupCompanyNameTrigger(g,c,l){if("contactType"===(0,e.get)(c,"type")&&c.link.companyName){const d=g.get("companyName");null!==d&&(l?d.setValidators(s.kI.required):d.clearValidators(),d.updateValueAndValidity())}}setupFormTriggers(g,c,l){return(0,I.T)(this.setupCountryTriggers(g,c),this.setupUserTypeTriggers(g,c)).pipe((0,i.R)(l))}setupCountryTriggers(g,c){const l=g.get("country"),d=c.find(S=>"province"===S.name);(0,e.isNil)(this.provinceOptions)&&!(0,e.isNil)(d)&&(this.provinceOptions=(0,e.cloneDeep)(d.availableOptions));const A=+l?.value>0?+l.value:this.getCountryCodeFromFieldSetOptions(c)??this.defaultCountryCode;return this.defaultCountryCode=(0,e.isNil)(this.defaultCountryCode)?A:this.defaultCountryCode,this.setCountryValidators(g,c,A),(0,e.isNil)(l)?T.E:(A&&(0,e.isEmpty)(l.value)&&l.setValue(A.toString()),l.valueChanges.pipe((0,P.b)(S=>{this.setCountryValidators(g,c,+S)})))}getCountryCodeFromFieldSetOptions(g){const c=g.find(d=>"country"===d.name);return c?+((0,e.find)(c.availableOptions,"selected")??(0,e.first)(c.availableOptions))?.value:null}setupUserTypeTriggers(g,c){const l=(0,e.find)(c,{name:"addressLine1"});if(l){const d=l.title,A=this.translateService.instant("lblOrgPossessive",{fieldTitle:d}),S=g.controls.userType;if(S)return S.valueChanges.pipe((0,D.O)(S.value),(0,P.b)(v=>{l.title=v?A:d}));l.title=d}return T.E}setCountryValidators(g,c,l){const d=g.get("postalCode"),A=c.find(M=>"postalCode"===M.name);if(!(0,e.isNil)(d)&&!(0,e.isNil)(A)){const M=this.formService.setPatternPostalCodeElement(d,l),R=this.fieldService.mapValidators(A,M);(0,e.isNil)(d.skip)&&(d.setValidators(R),d.updateValueAndValidity()),d.invalid&&(0,e.includes)((0,e.filter)(Object.values(y.c),e.isNumber),l)&&d.setValue("")}const S=g.get("phone"),v=c.find(M=>"phone"===M.name);if(!(0,e.isNil)(S)&&!(0,e.isNil)(v)){v.link={countryId:l};const M=this.formService.setPatternPhoneElement(S,l),R=this.fieldService.mapValidators(v,M);S.setValidators(R),S.updateValueAndValidity()}const b=c.find(M=>"province"===M.name);!(0,e.isNil)(b)&&!(0,e.isNil)(this.provinceOptions)&&(b.availableOptions=(0,e.cloneDeep)(this.provinceOptions.filter(M=>M.countryId===l)),this.setProvinceValue(g,b))}setPhonePattern(g,c,l){const d=g.find(A=>"phone"===A.name);if(!(0,e.isNil)(c)&&!(0,e.isNil)(d)){const A=this.formService.setPatternPhoneElement(c,l),S=this.fieldService.mapValidators(d,A);c.setValidators(S),c.updateValueAndValidity()}}setPostalCodePattern(g,c,l){if(!(0,e.isNil)(g)){const d=this.formService.setPatternPostalCodeElement(g,c),A=this.fieldService.mapValidators(l.find(S=>"postalCode"===S.name),d);(0,e.isNil)(g.skip)&&(g.setValidators(A),g.updateValueAndValidity()),g.invalid&&(0,e.includes)((0,e.filter)(Object.values(y.c),e.isNumber),c)&&g.setValue("")}}setProvinceValue(g,c){const l=g.get("province");let d=l.value;1===(0,e.size)(c.availableOptions)?(d=(0,e.first)(c.availableOptions).value,l.setValue(d),l.disable()):l.enable();const A=(0,e.find)(c.availableOptions,["value",d]),S=(0,e.isObject)(A);this.defaultRegionId=(0,e.isNil)(this.defaultRegionId)&&S&&A.countryId===this.defaultCountryCode?d:this.defaultRegionId,l.setValue(S?d:"")}hasRequired(g){if(g&&g.validator){const c=g.validator({});if(c&&c.required)return!0}return!1}getFormGroupValues(g){if(!g?.controls)return null;const c=g.value;return!c.province&&g.controls.province?.disabled&&(c.province=g.controls.province.value),c}setHonorRollValidators(g,c){const l=g.get("honourRollShowAmount"),d=g.get("honourRollText");3===c?(l.enable(),d.enable()):(l.disable(),d.disable())}static#t=this.\u0275fac=function(c){return new(c||C)(f.LFG(a._),f.LFG(n.D),f.LFG(r.sK))};static#e=this.\u0275prov=f.Yz7({token:C,factory:C.\u0275fac})}return C})()},14583:(Z,K,t)=>{"use strict";t.d(K,{I:()=>u});var s=t(56223),e=t(6990),n=t(16271),i=t(40117),P=t(11147),D=t(80496),I=t(72843),T=t(16676),a=t.n(T),y=t(72550),f=t(65879),r=t(89515);let u=(()=>{class C{constructor(g,c,l,d){this.translate=g,this.donationAmountValidator=c,this.globalizedCurrencyValidator=l,this.uniqueUsernameValidator=d}getValidators(g,c=null){if((0,e.isNil)(g))return null;const l=[];return"userType"===g.name?null:("number"===g.type&&l.push(this.globalizedCurrencyValidator.nanValidator),"password"===g.name&&l.push((0,P.c)()),g.required&&(l.push("acceptOnBehalf"===g.name||"checkbox"===g.type?s.kI.requiredTrue:s.kI.required),["dropdownlist","checkboxGroup"].includes(g.type)&&l.push(this.multipleChoiceRequiredValidator())),g.pattern||c?l.push(s.kI.pattern(c||g.pattern)):"text"===g.type&&l.push(s.kI.pattern(D.jo)),"goal"===g.name?l.push(this.globalizedCurrencyValidator.globalizedCurrency(this.translate.currentLang,g.min,g.max)):(!(0,e.isNil)(g.min)&&(0,e.isNumber)(g.min)&&+g.min>0&&l.push(s.kI.minLength(g.min)),!(0,e.isNil)(g.max)&&(0,e.isNumber)(g.max)&&+g.max>0&&l.push(s.kI.maxLength(g.max))),"dateOfBirth"===g.name&&l.push(this.dateValidator(d=>d.year()>=D.z1.MinYearOfBirth,"min",`dateOfBirth.year is less than ${D.z1.MinYearOfBirth}`)),g.globalizedFloat&&(l.push(y.vV.globalNumber(this.translate.currentLang)),l.push(this.donationAmountValidator.isValidAmount(this.translate.currentLang))),s.kI.compose(l))}dateValidator(g,c,l){return d=>{if((0,e.isNil)(d.value)||(0,e.isEmpty)(d.value))return null;const A=a().isMoment(d.value)?d.value:a()(d.value);return g(A)?null:{[c]:l}}}getAsyncValidators(g){const c=[];return(0,e.isNil)(g)||g.unique&&c.push(this.uniqueUsernameValidator.isUniqueAsync()),c}createUniqueValidator(g,c){return l=>{const d=g(l)??[],A=(0,e.uniq)(d);return d.length&&d.length!==A.length?{unique:`${c} should be unique`}:null}}multipleChoiceRequiredValidator(){return g=>(0,e.isArray)(g.value)?g.value.filter(l=>""!==l).length?null:{required:!0}:null}static#t=this.\u0275fac=function(c){return new(c||C)(f.LFG(r.sK),f.LFG(n.z),f.LFG(i.Z),f.LFG(I.w))};static#e=this.\u0275prov=f.Yz7({token:C,factory:C.\u0275fac})}return C})()},59215:(Z,K,t)=>{"use strict";t.d(K,{D:()=>I});var s=t(56223),e=t(6990),n=t(8638),i=t(14583),P=t(80496),D=t(65879);let I=(()=>{class T{constructor(y){this.fieldValidatorBuilderService=y}generateFormFields(y){const f={},r=(0,e.reduce)(y,(u,C)=>(u[C.name]={key:C.name,label:C.title,value:C.value||"",type:C.type,options:C.availableOptions||[],updateOn:C.updateOn,validations:this.fieldValidatorBuilderService.getValidators(C)},u),{});for(const u of Object.keys(r)){const C={validators:r[u].validations};["radio","contactType","tel","checkbox"].includes(r[u].type)&&(0,e.set)(C,"updateOn","change"),(0,e.isNil)(r[u].updateOn)||(0,e.set)(C,"updateOn",r[u].updateOn),f[u]=new s.NI(r[u].value,C)}return f}generateTributeFormFields(y=1){const f=[...Array(y)].map(r=>this.generateTributeRecipientFormFields());return{firstName:new s.NI("",s.kI.required),lastName:new s.NI("",s.kI.required),cardType:new s.NI("",s.kI.required),cardDetails:new s.cw({recipients:new s.Oe(f,{updateOn:"change",validators:[this.fieldValidatorBuilderService.createUniqueValidator(r=>(0,e.get)(r,"value",[]).map(C=>(0,e.trim)(C.email)).filter(e.identity),"cardDetail.recipients.email")]}),templateId:new s.NI("",[s.kI.required]),message:new s.NI("",[s.kI.required,s.kI.maxLength(500)]),deliveryDate:new s.NI("",[])})}}generateTributeRecipientFormFields(){return new s.cw({firstName:new s.NI("",[s.kI.required]),lastName:new s.NI("",[s.kI.required]),email:new s.NI("",[s.kI.required,s.kI.pattern(P.z1.EmailRegex)]),country:new s.NI("",[s.kI.required]),addressLine1:new s.NI("",[s.kI.required]),city:new s.NI("",[s.kI.required]),region:new s.NI("",[s.kI.required]),postalCode:new s.NI("",[s.kI.required])})}generatePaymentFormFields(y=!1,f=null,r=!0){const u=[null===f?n.R.validateCreditCardNumber:n.R.allowedCreditCardTypes(f),n.R.ccIsValid()],C=new s.NI("",s.kI.compose(u)),L=[n.R.validateCreditCardVerificationValue(C)],g=[s.kI.minLength(3)];return r&&(u.push(s.kI.required),C.setValidators(s.kI.compose(u)),L.push(s.kI.required),g.push(s.kI.required)),{cardType:new s.NI(""),cardNumber:C,cvv:new s.NI("",s.kI.compose(L)),cardHolderName:new s.NI("",s.kI.compose(g)),cardExpiry:new s.cw({cardExpirationMonth:new s.NI("",r?s.kI.required:[]),cardExpirationYear:new s.NI("",r?s.kI.required:[])},[n.R.validateCreditCardExpiryDate]),paymentMethod:new s.NI(""),payPalToken:new s.NI(""),payPalPayerId:new s.NI(""),payPalTotalAmount:new s.NI(""),payPalCurrency:new s.NI(""),isVisaCheckOutAllowed:new s.NI("")}}mapValidators(y,f=null){return this.fieldValidatorBuilderService.getValidators(y,f)}getUserNameValidator(y){return this.fieldValidatorBuilderService.getAsyncValidators((0,e.find)(y,{name:"username"}))}filterFieldsByFieldSet(y,f){let r=0;const u=[],C=new Map(y.map(L=>[L.id,L]));return f.forEach(L=>{const g=C.get(L);g&&(u.push(g),(0,e.isNil)(g.sortingOrder)&&(g.sortingOrder=r,r++))}),u}getFirstInvalidElement(y){const f=this.getFirstInvalidControl(y,u=>!!u.nativeElement);if(!f)return null;const r=f.nativeElement;return"MAT-CHECKBOX"===r.tagName?r.getElementsByTagName("input").item(0):r}getFirstInvalidControl(y,f){if(!y||y.valid||y.disabled)return null;const r=y;if(!r.controls)return null==f||f(y)?y:null;const u=Object.keys(r.controls);for(const C of u){const L=r.get(C),g=this.getFirstInvalidControl(L,f);if(g)return g}return null}static#t=this.\u0275fac=function(f){return new(f||T)(D.LFG(i.I))};static#e=this.\u0275prov=D.Yz7({token:T,factory:T.\u0275fac})}return T})()},33058:(Z,K,t)=>{"use strict";t.d(K,{_:()=>g});var s=t(6990),_=t(22096),n=t(37398),i=t(26306),P=t(99397),D=t(94664),I=t(72550),T=t(69862),a=t(73712),y=t(51126),f=t(21875),r=t(80496),u=t(40374),C=t(65879),L=t(89515);let g=(()=>{class c{constructor(d,A,S,v,b,M){this.errorHandlingService=d,this.translateService=A,this.http=S,this.storageService=v,this.environmentService=b,this.userInteractionPrivacyService=M,this.formName="stepForm",this.countryOptions=[],this.provinceOptions=[],this.profileFieldsCollection={}}convertToOptions(d){const A=[];return(0,s.forEach)(d,S=>{const v=(S.text||"").trim(),b=(S.value||"").trim();A.push({value:b,text:v,selected:S.selected||!1})}),A}excludeEmptyOptions(d){const A=(d.value||"").trim(),S=(0,s.toNumber)(A),v=(0,s.isNumber)(S)&&isFinite(S);return!!A&&(!v||S>0)}storeFieldData(d){if(d){const A=(0,s.find)(d,v=>"Country"===v.fieldKind);this.countryOptions=(0,s.get)(A,"fieldTypeParameter",[]);const S=(0,s.find)(d,v=>"Province"===v.fieldKind);this.provinceOptions=(0,s.get)(S,"fieldTypeParameter",[])}}getFormFields(d){const A={headers:(new T.WM).set("Authorization",`Bearer ${this.storageService.getJWT()}`)},S=`form/${d}/fields`,v=`${this.environmentService.getEnvironment().raisinEndpointUrl}/${S}`;return this.http.get(v,A).pipe((0,n.U)(b=>b.fields),(0,i.K)(b=>this.errorHandlingService.handleError(b)))}getFields(d){const A=this.translateService.currentLang;return Array.isArray((0,s.get)(this.profileFieldsCollection,[A,d]))?(0,_.of)(this.profileFieldsCollection[A][d]):this.getFormFields(d).pipe((0,P.b)(S=>{(0,s.set)(this.profileFieldsCollection,A,{[d]:S})}))}createField(d,A){const S={title:d.title,dynamicFieldId:d.dynamicFieldId,id:d.fieldKind,name:d.fieldKind.substring(0,1).toLowerCase()+d.fieldKind.substring(1),subEventDynamicFieldId:d.subEventDynamicFieldId,hideLabel:d.hideLabel,required:d.required,formName:this.formName,sameAs:d.sameAs,unique:d.unique,isHidden:d.isHidden,link:d.link||{}};if(d.link&&(S.link=d.link),d.autocomplete&&(S.autocomplete=d.autocomplete),"EmailConfirm"===d.fieldKind||"Email"===d.fieldKind)S.type="text",S.pattern=r.z1.EmailRegex;else if("Password"===d.fieldKind||"PasswordConfirm"===d.fieldKind)S.type="password";else if("Phone"===d.fieldKind)S.type="tel",S.pattern=this.countryId===a.c.Canada||this.countryId===a.c.UnitedStates?r.z1.CanadaOrUSPhoneRegex:r.z1.InternationalRegex;else if("PostalCode"===d.fieldKind)S.type="postalCode",S.pattern=this.countryId===a.c.Canada?r.z1.CanadaPostalCodeRegex:this.countryId===a.c.UnitedStates?r.z1.UnitedStatesPostalCodeRegex:this.countryId===a.c.France?r.z1.FrancePostalCodeRegex:r.z1.OtherPostalCodeRegex;else if(A)S.type=A;else switch(d.templateName||d.fieldType){case"RaisinDynamicTextField_Int32":case"RaisinDynamicTextField_Decimal":case"RaisinDynamicTextField_String":case"TextBox":S.type="text";break;case"AutocompleteLocation":S.type="AutocompleteLocation";break;case"RaisinDynamicDropDownField":case"DropDownList":if(S.type="dropdownlist","Province"===d.fieldKind)S.availableOptions=d.fieldTypeParameter;else{let v=this.convertToOptions(d.fieldTypeParameter);"Country"===d.fieldKind&&(v=v.filter(this.excludeEmptyOptions)),S.availableOptions=v}break;case"ContactType":S.type="contactType",S.databind="this.constituent.profile.contactType",S.availableOptions=this.convertToOptions(d.fieldTypeParameter);break;case"RaisinDynamicTextField_Boolean":case"CheckBox":S.type="checkbox";break;case"RaisinDynamicTextField_DateTime":S.type="datetime";break;case"DateOfBirth":S.type="dob"}return S}getFormInputs(d,A=!1){return(0,_.of)(this.countryId).pipe((0,D.w)(()=>this.getFields(d)),(0,P.b)(v=>{this.storeFieldData(v)}),(0,n.U)(v=>(0,s.filter)(v||[],b=>!(d!==y.u.Participant&&("Username"===b.fieldKind||"Password"===b.fieldKind||"PasswordConfirm"===b.fieldKind||"Goal"===b.fieldKind)))),(0,n.U)(v=>{let b=[];const M=v.find(p=>"AddressLine1"===p.fieldKind);let R=!1;for(let p=0;p<v.length;p++){("Username"===v[p].fieldKind||"Password"===v[p].fieldKind||"PasswordConfirm"===v[p].fieldKind)&&(v[p].autocomplete="off","PasswordConfirm"===v[p].fieldKind&&(v[p].sameAs="this.constituent.profile.accountInfo.password"),v[p].required=!0),v[p].unique="Username"===v[p].fieldKind,"EmailConfirm"===v[p].fieldKind&&(v[p].sameAs="this.constituent.profile.email"),"UserType"===v[p].fieldKind&&(v[p].hideLabel=!0);const O=this.createField(v[p]);if(O.databinding=`fields[${p}]`,!O.databind)switch(O.name){case"title":O.sortingOrder=0,O.class=A?"":r.I2.inputWrapHalf;break;case"firstName":O.sortingOrder=1,O.class=A?"fName":r.I2.inputWrapDouble;break;case"middleName":O.sortingOrder=2,R=!0,O.class=A?"":r.I2.inputWrapDouble+" end";break;case"lastName":O.sortingOrder=3,R||(O.class=A?"":r.I2.inputWrapDouble+" end");break;case"emailType":O.sortingOrder=4,O.class=A?"":r.I2.inputWrapHalf;break;case"email":O.sortingOrder=5;break;case"phoneType":O.sortingOrder=6;break;case"phone":O.sortingOrder=7,O.class=A?"":r.I2.inputWrapDouble,O.databind="this.constituent.profile.phone";break;case"phoneExtension":O.sortingOrder=8,O.class=A?"":r.I2.inputWrapDouble+" end",O.databind="this.constituent.profile.phoneExtension";break;case"gender":O.sortingOrder=9,O.class=A?"":r.I2.inputWrapHalf,O.databind="this.constituent.profile.gender";break;case"dateOfBirth":O.sortingOrder=10,O.databind="this.constituent.profile.dateOfBirth";break;case"companyName":O.sortingOrder=12,O.databind="this.constituent.profile.organization";break;case"addressType":O.sortingOrder=13;break;case"country":O.sortingOrder=14,O.databind="this.constituent.profile.address.countryId";break;case"addressLine1":O.sortingOrder=15,O.databind="this.constituent.profile.address.line1";break;case"addressLine2":O.sortingOrder=16,O.databind="this.constituent.profile.address.line2",O.title="lblAddressLine2"!==this.translateService.instant("lblAddressLine2")?this.translateService.instant("lblAddressLine2"):this.translateService.instant("UI.lblAddressLine2");break;case"city":O.sortingOrder=17,O.class=A?"":r.I2.inputWrapDouble;break;case"province":O.sortingOrder=18,O.databind="this.constituent.profile.address.regionId",O.class=A?"":r.I2.inputWrapDouble+" end";break;case"postalCode":O.sortingOrder=19,O.class=A?"":r.I2.inputWrapHalf,O.databind=`this.constituent.profile.address.${O.name}`;break;case"privacy":O.sortingOrder=20,O.databind="this.constituent.profile.privacy";break;case"optOut":O.sortingOrder=21,O.databind="this.constituent.profile.receiveCommunications";break;case"optOutToShare":O.sortingOrder=22,O.databind="this.constituent.profile.allowDistributionOfDetails";break;case"personalDataUseExplicitConsent":O.sortingOrder=23,O.databind="this.constituent.profile.personalDataUseExplicitConsent";break;case"username":O.min=r.id.minLength,O.max=r.id.maxLength,O.databind=`this.constituent.profile.accountInfo.${O.name}`;break;case"password":case"passwordConfirm":O.min=r.Qj.minLength,O.max=r.Qj.maxLength,O.databind=`this.constituent.profile.accountInfo.${O.name}`;break;case"attribute1":O.sortingOrder=23,O.databind="this.constituent.profile.customField1",O.isExternalLabel=!0;break;case"attribute2":O.sortingOrder=24,O.databind="this.constituent.profile.customField2",O.isExternalLabel=!0;break;case"attribute3":O.sortingOrder=25,O.databind="this.constituent.profile.customField3",O.isExternalLabel=!0;break;case"attribute4":O.sortingOrder=26,O.databind="this.constituent.profile.customField4",O.isExternalLabel=!0;break;case"attribute5":O.sortingOrder=27,O.databind="this.constituent.profile.customField5",O.isExternalLabel=!0;break;default:O.databind=`this.constituent.profile.${O.name}`}O.isPrivateData=this.userInteractionPrivacyService.isPrivateData(O.databind),"userType"===O.name&&(O.sortingOrder=11),O.defaultState={required:O.required,isHidden:O.isHidden,pattern:O.pattern,defaultOptions:(0,s.cloneDeep)(O.availableOptions)},b.push(O)}M||(b=b.filter(p=>"addressLine2"!==p.name));const E=this.getField(b,"UserType");if(E){const p=this.getField(b,"CompanyName");E.link={companyName:!p.required}}const m=this.getField(b,"Country");return m&&(m.link={province:this.getField(b,"Province"),postalCode:this.getField(b,"PostalCode"),phone:this.getField(b,"Phone")}),b}))}getFormInputDataBindingKey(d){return d.databind?d.databind.substring(d.databind.lastIndexOf(".")+1):-1===d.name.lastIndexOf("_")?d.name:d.name.substring(d.name.lastIndexOf("_")+1)}isAnyFormInputRequired(d){if(d)for(const A of d)if(A.required)return!0;return!1}getField(d,A){const S=(0,s.find)(d,{id:A});return S&&!(0,s.isNil)(S)?S:(0,s.find)(d,{fieldKind:A})}setPatternPostalCodeElement(d,A){if(d){let S=null;S=A===a.c.Canada?r.z1.CanadaPostalCodeRegex:A===a.c.UnitedStates?r.z1.UnitedStatesPostalCodeRegex:A===a.c.France?r.z1.FrancePostalCodeRegex:r.z1.OtherPostalCodeRegex,d.pattern=S}return d.pattern}setPatternPhoneElement(d,A){return d&&(d.pattern=A===a.c.Canada||A===a.c.UnitedStates?r.z1.CanadaOrUSPhoneRegex:r.z1.InternationalRegex),d.pattern}setProvinceElement(d,A){d&&(d.availableOptions=(0,s.filter)(d.defaultState.defaultOptions,{countryId:A}))}getCountryCodeByName(d){const A=this.countryOptions.find(S=>S.text===d||(0,s.includes)(S.text,r.Wb.RUSSIA));return A?A.value:null}getProvinceCodeByNameAndCountryId(d,A){const S=this.provinceOptions.find(v=>v.countryId===+A&&(v.text===(0,s.deburr)(d)||"All Regions"===v.text||v.text===r.M7.DC&&d===r.M7.DISTRICT_OF_COLUMBIA));return S?S.value:null}maskPhoneNumber4to10(d){if(d){let A=d.replace(/\D/g,"");return A.length>=4&&A.length<=7?A=A.replace(/^(\d{3})(\d{0,4})$/,r.MQ.SevenDigit):A.length<=10&&(A=A.replace(/^(\d{3})(\d{3})(\d{0,4})$/,r.MQ.TenDigit)),A}return""}maskPhoneNumber0to15(d){if(!d)return"";let A=d.replace(/\D/g,"");return A=A.replace(/^(\d{15}).*$/,r.MQ.FifteenDigit),A}getPhoneDataEntryRules(d){switch(d){case a.c.Canada:case a.c.UnitedStates:return{validationPattern:r.z1.CanadaOrUSPhoneRegex,mask:this.maskPhoneNumber4to10,isValueValid:A=>isFinite(+A)};default:return{validationPattern:r.z1.InternationalRegex,mask:this.maskPhoneNumber0to15,isValueValid:A=>isFinite(+A)}}}maskPostalCode(d,A){if(d){let S=d;return A===a.c.Canada?(S=S.replace(/[^A-Za-z0-9]/g,""),S.length>3&&S.length<=6&&(S=S.replace(/^([A-Za-z0-9]{3})([A-Za-z0-9]{1,3})$/,r.R7.Canada)),S):A===a.c.UnitedStates?(S=S.replace(/\D/g,""),S.length>5&&S.length<=9&&(S=S.replace(/^([A-Za-z0-9]{5})([A-Za-z0-9]{1,4})$/,r.R7.UnitedStatesTenDigits)),S):S.replace(A===a.c.France?/\D/g:/[^A-Za-z0-9 -]/g,"")}return""}getCountryRegions(d,A,S,v){const b={headers:(new T.WM).set("Authorization",`Bearer ${this.storageService.getJWT()}`)};let M=`${this.environmentService.getEnvironment().raisinEndpointUrl}/resources/regions`;return M=this.appendUrlPath(M,d),M=this.appendQueryString(M,{regionId:A,regionName:S,regionCode:v}),this.http.get(M,b).pipe((0,n.U)(R=>R.regions??[]),(0,i.K)(R=>this.errorHandlingService.handleError(R)))}getTitles(d){const A={headers:(new T.WM).set("Authorization",`Bearer ${this.storageService.getJWT()}`)};let S=`${this.environmentService.getEnvironment().raisinEndpointUrl}/resources/titles`;return S=this.appendQueryString(S,{titleId:d}),this.http.get(S,A).pipe((0,n.U)(v=>v??[]),(0,i.K)(v=>this.errorHandlingService.handleError(v)))}getCountries(d,A,S){const v={headers:(new T.WM).set("Authorization",`Bearer ${this.storageService.getJWT()}`)};let b=`${this.environmentService.getEnvironment().raisinEndpointUrl}/resources/countries`;return b=this.appendQueryString(b,{countryId:d,countryName:A,countryCode:S}),this.http.get(b,v).pipe((0,n.U)(M=>M??[]),(0,i.K)(M=>this.errorHandlingService.handleError(M)))}appendUrlPath(d,A){return(0,s.isNil)(A)?d:`${d}/${A}`}appendQueryString(d,A){const S=this.getQueryString(A);return(0,s.isEmpty)(S)?d:`${d}?${S}`}getQueryString(d){return(0,s.join)((0,s.filter)((0,s.map)(d,(A,S)=>(0,s.isNil)(A)?"":`${S}=${A}`),A=>!(0,s.isEmpty)(A)),"&")}static#t=this.\u0275fac=function(A){return new(A||c)(C.LFG(I.rj),C.LFG(L.sK),C.LFG(T.eN),C.LFG(f.V1),C.LFG(I.L$),C.LFG(u.lu))};static#e=this.\u0275prov=C.Yz7({token:c,factory:c.\u0275fac,providedIn:"root"})}return c})()},8638:(Z,K,t)=>{"use strict";t.d(K,{R:()=>n});var s=t(6990),_=t(80496);class n{static allowedCreditCardTypes(P){return D=>{if((0,s.isEmpty)((0,s.get)(D,"value"))||(0,s.isNil)(P)||(0,s.isEmpty)(P))return null;const I=[];return(0,s.forEach)(P,a=>{const y=(0,s.get)(_.z1.CCRegex,(0,s.capitalize)(a.paymentCardName).replace(" ",""));(0,s.isNil)(y)||I.push(y)}),(0,s.some)(I,a=>new RegExp(a).test(D.value))?(D.setErrors({}),null):{inValidCreditCard:!0}}}static validateCreditCardNumber(P){return P.value?(0,s.some)(_.z1.CCRegex,I=>new RegExp(I).test(P.value))?(P.setErrors({}),null):{inValidCreditCard:!0}:null}static validateCreditCardVerificationValue(P){let D=!1;return I=>{if(D||(D=!0,P.valueChanges.subscribe(()=>{I.updateValueAndValidity()})),P.value){const T=(0,s.invertBy)(_.z1.CCRegex,a=>new RegExp(a).test(P.value)).true;if(!(0,s.isNil)(T))return new RegExp((0,s.get)(_.z1.CVVRegex,T)).test(I.value)?(I.setErrors({}),null):{pattern:!0}}return null}}static validateCreditCardExpiryDate(P){const D=P.value;if((0,s.isNil)(D)||(0,s.isEmpty)(D.cardExpirationYear)||(0,s.isEmpty)(D.cardExpirationMonth))return null;const I=(0,s.toNumber)(D.cardExpirationYear),T=(0,s.toNumber)(D.cardExpirationMonth);return(0,s.isNaN)(I)||(0,s.isNaN)(T)?null:new Date(I,T,1)>new Date?(P.setErrors(null),null):{inValidCreditCardExpiryDate:!0}}static ccIsValid(){return P=>{if(P.value){const I=P.value.toString(),T=[[0,1,2,3,4,5,6,7,8,9],[0,2,4,6,8,1,3,5,7,9]];let a=I.length,y=0,f=0;for(;a--;)f+=T[y][parseInt(I.charAt(a),10)],y^=1;return f%10==0&&f>0?null:{inValidCreditCard:!0}}return null}}}},16271:(Z,K,t)=>{"use strict";t.d(K,{z:()=>P});var s=t(6990),_=t(80496),n=t(72550),i=t(65879);let P=(()=>{class D{constructor(T){this.globalizeUtils=T}isValidAmount(T){return a=>{const y=(a.value||"").toString().trim();if(!(0,s.isEmpty)(y)&&(a.touched||a.dirty)){const f=this.globalizeUtils.parseGlobalizedFloat(y,T);if((0,s.isNumber)(f)&&(0,s.isFinite)(f)&&((0,s.lt)(f,_.z1.Donation.MinForOnlineDonation)||(0,s.gt)(f,_.z1.Donation.MaxForOnlineDonation)))return{donationAmount:!0}}return null}}static#t=this.\u0275fac=function(a){return new(a||D)(i.LFG(n.h$))};static#e=this.\u0275prov=i.Yz7({token:D,factory:D.\u0275fac,providedIn:"root"})}return D})()},40117:(Z,K,t)=>{"use strict";t.d(K,{Z:()=>i});var s=t(72550),e=t(6990),n=t(65879);let i=(()=>{class P{constructor(I){this.globalizeUtils=I}globalizedCurrency(I,T=0,a=0){return y=>{const f=(y.value||"").toString().trim();if(!(0,e.isEmpty)(f)&&(y.touched||y.dirty)){const r=this.globalizeUtils.parseAsNumber(f,I);if(!(0,e.isNumber)(r)||!(0,e.isFinite)(r))return{globalizedCurrency:!0};if(T>0&&r<T)return{min:!0};if(a>0&&r>a)return{max:!0}}return null}}nanValidator(I){return(0,e.isNaN)(I.value)?{globalizedFloat:!0}:null}static#t=this.\u0275fac=function(T){return new(T||P)(n.LFG(s.h$))};static#e=this.\u0275prov=n.Yz7({token:P,factory:P.\u0275fac,providedIn:"root"})}return P})()},11147:(Z,K,t)=>{"use strict";t.d(K,{c:()=>e});var s=t(80496);const e=()=>_=>{if(_.value){const i=_.value.toString();let P=0;for(const D of s.z1.PasswordCriteriaRegex)if(P+=new RegExp(D).test(i)?1:0,P>=3)return null}return{passwordFormat:!0}}},72843:(Z,K,t)=>{"use strict";t.d(K,{w:()=>f});var s=t(6990),_=t(22096),n=t(83620),i=t(37398),P=t(26306),D=t(80496),I=t(34731),T=t(65879),a=t(21772);const y=I.ZP`
query UsernameUnique ($username: String!){
  usernameUnique(username: $username)
}`;let f=(()=>{class r{constructor(C){this.apollo=C}isUniqueAsync(){return C=>{const L=(0,s.size)(C.value),g=C.value;return(0,s.inRange)(L,D.id.minLength,D.id.maxLength+1)?this.apollo.use("user").query({query:y,fetchPolicy:D.CT,variables:{username:g}}).pipe((0,n.b)(500),(0,i.U)(c=>c.data.usernameUnique?null:{usernameExists:!0}),(0,P.K)(c=>(0,_.of)(null))):(0,_.of)(null)}}static#t=this.\u0275fac=function(L){return new(L||r)(T.LFG(a._M))};static#e=this.\u0275prov=T.Yz7({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})()},33676:(Z,K,t)=>{"use strict";t.d(K,{G:()=>v});var s=t(97582),e=t(65879),_=t(56223),n=t(72550),i=t(6990),D=t(17715),I=t(21875),T=t(96814),a=t(50768),y=t(2032),f=t(64170),r=t(95195),u=t(32296),C=t(30617),L=t(33409),g=t(89515);const c=["loginCloseButton"];function l(b,M){1&b&&(e.TgZ(0,"mat-error"),e._uU(1),e.ALo(2,"translate"),e.qZA()),2&b&&(e.xp6(1),e.Oqu(e.lcZ(2,1,"errUsernameRequired")))}function d(b,M){1&b&&(e.TgZ(0,"mat-error"),e._uU(1),e.ALo(2,"translate"),e.qZA()),2&b&&(e.xp6(1),e.Oqu(e.lcZ(2,1,"errPasswordRequired")))}function A(b,M){if(1&b&&(e._UZ(0,"div",25),e.ALo(1,"safeHtml"),e.ALo(2,"translate")),2&b){const R=e.oxw();e.Q6J("innerHTML",e.lcZ(1,1,e.xi3(2,3,R.errorMessage,R)),e.oJD)}}const S=function(b){return[b]};let v=class ye{constructor(M,R,B,E){this.formBuilder=M,this.environmentService=R,this.configService=B,this.storageService=E,this.cssClass=!0,this.loginClicked=new e.vpe,this.socialClicked=new e.vpe,this.closeClicked=new e.vpe,this.connectionToken="",this.hidePassword=!0}ngOnInit(){this.usernameControl=new _.p4("",[_.kI.required]),this.passwordControl=new _.p4("",[_.kI.required]),this.loginForm=this.formBuilder.group({username:this.usernameControl,password:this.passwordControl}),this.eventUrl=this.storageService.eventParams.subEventCustomPart,this.eventUrlUsername=`/${this.eventUrl}/forgot-username`,this.eventUrlPassword=`/${this.eventUrl}/forgot-password`,this.setUpSocialConfigForOneAll()}onCloseClicked(){this.closeClicked.emit()}onLoginClicked(){this.loginForm.markAllAsTouched(),this.loginForm.updateValueAndValidity(),this.loginForm.valid&&this.loginClicked.emit({username:this.usernameControl.value,password:this.passwordControl.value,reissue:!0,code:""})}setUpSocialConfigForOneAll(){this.configService.getOneAllConfig().pipe((0,D.t)(this)).subscribe(M=>{this.socialConfigSetting=M,this.initOneAllScript()})}initOneAllScript(){const M=this.environmentService.getEnvironment().raisinEndpointUrl,R=this.storageService.eventParams.orgId,B=this.storageService.eventParams.subEventCustomPart,E=window,m=document.getElementsByTagName("head")[0],p=document.createElement("script");p.type="text/javascript",p.async=!0,p.src=`//${this.socialConfigSetting.subDomain}.api.oneall.com/socialize/library.js`,p.onload=O=>{E.__oneall=E._oneall||[],E.__oneall.push(["social_login","set_providers",["facebook"]]),E.__oneall.push(["social_login","set_event","on_close_popup_ui",F=>this.onSocialLogin(F)]),E.__oneall.push(["social_login","set_event","on_login_end_success",F=>this.onSocialLogin(F)]),E.__oneall.push(["social_login","set_event","on_login_redirect",()=>!1]),E.__oneall.push(["social_login","set_callback_uri",`${M}/oneall?orgId=${R}&subEventPart=${B}&isLogin=true`]),E.__oneall.push(["social_login","do_render_ui","oa_social_login_container"])},m.appendChild(p)}onSocialLogin(M){null!=this.socialConfigSetting&&this.socialClicked.emit(M.connection.connection_token)}formatUrl(M){return`${M}/ui/${this.storageService.eventParams.subEventCustomPart}`}ngOnDestroy(){(0,i.isNil)(this.socialConfigSubscription)||this.socialConfigSubscription.unsubscribe(),(0,i.isNil)(this.initOneAllSubscription)||this.initOneAllSubscription.unsubscribe()}onEscapeKeyHandler(M){this.closeClicked.emit()}goToClose(){this.loginCloseButton.nativeElement.focus()}static#t=this.\u0275fac=function(R){return new(R||ye)(e.Y36(_.qu),e.Y36(n.L$),e.Y36(n.V1),e.Y36(I.V1))};static#e=this.\u0275cmp=e.Xpm({type:ye,selectors:[["rs-login"]],viewQuery:function(R,B){if(1&R&&e.Gf(c,7),2&R){let E;e.iGM(E=e.CRH())&&(B.loginCloseButton=E.first)}},hostVars:2,hostBindings:function(R,B){1&R&&e.NdJ("keydown.escape",function(m){return B.onEscapeKeyHandler(m)},!1,e.evT),2&R&&e.ekj("pc-login",B.cssClass)},inputs:{errorMessage:"errorMessage"},outputs:{loginClicked:"loginClicked",socialClicked:"socialClicked",closeClicked:"closeClicked"},decls:53,vars:61,consts:[["appearance","outlined","data-type","donationLogin","id","loginModal",1,"login-panel","donation"],[1,"login-panel__header"],["mat-card-title","","tabindex","0",1,"login-panel__heading",3,"innerHTML"],["type","button","id","loginCloseButton","aria-label","Close",1,"close","pull-right","loginCloseButton",3,"click"],["loginCloseButton",""],["aria-hidden","true"],["mat-card-content","",3,"formGroup"],[1,"login-panel__user"],[1,"input-wrap"],[1,"username-form-field"],["id","username"],["matInput","","type","text",1,"username",3,"formControl","keydown.enter"],[4,"ngIf"],[1,"password-form-field"],["id","password"],["matInput","",1,"password",3,"type","formControl","keydown.enter"],["mat-icon-button","","matSuffix","",1,"passwordVisible",3,"click"],["aria-live","polite",1,"login-error-message","mat-body-2","mat-error"],["class","login-panel__error-msg",3,"innerHTML",4,"ngIf"],["color","primary",1,"btn","btn-default","btn-flow","btn-block","login",3,"click"],["mat-card-footer","",1,"login-panel__tools"],["id","usernameLink",3,"routerLink"],["id","passwordLink",3,"routerLink","blur"],[1,"login-panel__social"],["id","oa_social_login_container"],[1,"login-panel__error-msg",3,"innerHTML"]],template:function(R,B){1&R&&(e.TgZ(0,"mat-card",0)(1,"div",1),e.ALo(2,"translate"),e._UZ(3,"h1",2),e.ALo(4,"translate"),e.TgZ(5,"button",3,4),e.NdJ("click",function(){return B.onCloseClicked()}),e.TgZ(7,"span",5),e._uU(8,"\xd7"),e.qZA()()(),e.TgZ(9,"div",6)(10,"div",7)(11,"div",8)(12,"mat-form-field",9)(13,"mat-label",10),e._uU(14),e.ALo(15,"translate"),e.qZA(),e.TgZ(16,"input",11),e.NdJ("keydown.enter",function(){return B.onLoginClicked()}),e.ALo(17,"translate"),e.qZA(),e.YNc(18,l,3,3,"mat-error",12),e.qZA()(),e.TgZ(19,"div",8)(20,"mat-form-field",13)(21,"mat-label",14),e._uU(22),e.ALo(23,"translate"),e.qZA(),e.TgZ(24,"input",15),e.NdJ("keydown.enter",function(){return B.onLoginClicked()}),e.ALo(25,"translate"),e.ALo(26,"translate"),e.ALo(27,"translate"),e.qZA(),e.TgZ(28,"button",16),e.NdJ("click",function(){return B.hidePassword=!B.hidePassword}),e.ALo(29,"translate"),e.ALo(30,"translate"),e.ALo(31,"translate"),e.TgZ(32,"mat-icon"),e._uU(33),e.qZA()(),e.YNc(34,d,3,3,"mat-error",12),e.qZA()(),e.TgZ(35,"div",17),e.YNc(36,A,3,6,"div",18),e.qZA(),e.TgZ(37,"button",19),e.NdJ("click",function(){return B.onLoginClicked()}),e.ALo(38,"translate"),e._uU(39),e.ALo(40,"translate"),e.qZA(),e.TgZ(41,"div",20)(42,"a",21),e._uU(43),e.ALo(44,"translate"),e.qZA(),e.TgZ(45,"a",22),e.NdJ("blur",function(){return B.goToClose()}),e._uU(46),e.ALo(47,"translate"),e.qZA()(),e.TgZ(48,"div",23)(49,"p"),e._uU(50),e.ALo(51,"translate"),e.qZA(),e._UZ(52,"div",24),e.qZA()()()()),2&R&&(e.xp6(1),e.uIk("aria-label",e.lcZ(2,25,"lblLoginSection")),e.xp6(2),e.Q6J("innerHTML",e.lcZ(4,27,"headerLogin"),e.oJD),e.xp6(6),e.Q6J("formGroup",B.loginForm),e.xp6(5),e.Oqu(e.lcZ(15,29,"lblLoginUsernameEmail")),e.xp6(2),e.Q6J("formControl",B.usernameControl),e.uIk("aria-label",e.lcZ(17,31,"lblEnterUsername")),e.xp6(2),e.Q6J("ngIf",B.usernameControl.invalid),e.xp6(4),e.Oqu(e.lcZ(23,33,"lblPassword")),e.xp6(2),e.zWS("aria-label","",e.lcZ(25,35,"lblEnterPassword")," ",B.hidePassword?e.lcZ(26,37,"wcag.label.password_hidden"):e.lcZ(27,39,"wcag.label.password_visible"),""),e.Q6J("type",B.hidePassword?"password":"text")("formControl",B.passwordControl),e.xp6(4),e.zWS("aria-label","",e.lcZ(29,41,"lblPasswordShowHide")," ",B.hidePassword?e.lcZ(30,43,"wcag.label.password_hidden"):e.lcZ(31,45,"wcag.label.password_visible"),""),e.uIk("aria-pressed",B.hidePassword),e.xp6(5),e.Oqu(B.hidePassword?"visibility_off":"visibility"),e.xp6(1),e.Q6J("ngIf",B.passwordControl.invalid),e.xp6(2),e.Q6J("ngIf",B.errorMessage),e.xp6(1),e.uIk("aria-label",e.lcZ(38,47,"lblClickLogin")),e.xp6(2),e.hij(" ",e.lcZ(40,49,"btnLogin")," "),e.xp6(3),e.Q6J("routerLink",e.VKq(57,S,B.eventUrlUsername)),e.xp6(1),e.Oqu(e.lcZ(44,51,"linkLoginForgotUsername")),e.xp6(2),e.Q6J("routerLink",e.VKq(59,S,B.eventUrlPassword)),e.xp6(1),e.Oqu(e.lcZ(47,53,"linkLoginForgotPassword")),e.xp6(4),e.Oqu(e.lcZ(51,55,"lblLoginWithFacebook")))},dependencies:[T.O5,a.rH,_.Fj,_.JJ,_.JL,y.Nt,f.KE,f.hX,f.TO,f.R9,r.a8,r.n5,u.RK,_.oH,_.sg,C.Hw,L.z,g.X$],styles:['.accessibly-hide{position:absolute!important;height:1px;width:1px;overflow:hidden;clip:rect(1px,1px,1px,1px)}button[disabled],button.disabled{cursor:not-allowed!important}[mat-flat-button].btn-action{padding:0 30px;border-radius:20px!important;box-sizing:border-box;border:1px solid transparent;letter-spacing:normal;background-color:#61a220;color:#fff}[mat-flat-button].btn-action:disabled:hover{cursor:not-allowed}[mat-flat-button].btn-action:enabled:hover{background-color:#db3a00}[mat-flat-button].btn-primary{padding:0 30px;border-radius:20px!important;box-sizing:border-box;border:1px solid transparent;letter-spacing:normal;background-color:#1975d2!important;color:#fff!important}[mat-flat-button].btn-primary:disabled:hover{cursor:not-allowed}[mat-flat-button].btn-alt{padding:0 30px;border-radius:20px!important;box-sizing:border-box;border:1px solid transparent;letter-spacing:normal;background-color:#fff;border-color:#61a220;color:#264d58}[mat-flat-button].btn-alt:disabled:hover{cursor:not-allowed}[mat-flat-button].btn-alt:enabled:hover{border:1px solid #db3a00}.is-mobile .hide-mobile,.is-desktop .hide-desktop,.is-tablet .hide-tablet,.is-phablet .hide-phablet{display:none!important}.cursor-pointer,.text-button{cursor:pointer}.text-button{font-family:Roboto,sans-serif;font-size:16px;font-size:1.6rem;color:#1975d2;border:none;border-radius:0!important;background:none;padding:0!important;min-width:0!important;text-decoration:underline;margin:0}.text-button--chevron:after{content:">";display:inline-block;padding:0 2px}.mdc-dialog .mdc-dialog__content{color:#000000de}.mdc-dialog__title:before{display:none}mat-card-title.base-header h2,.mat-mdc-card-title.base-header h2{padding-bottom:12px;margin:0 0 12px;border-bottom:2px solid #d5d5d5;line-height:22px}mat-card-title.icons-header,.mat-mdc-card-title.icons-header{display:flex;justify-content:space-between;align-items:center;margin:0 0 12px;padding-bottom:12px;border-bottom:2px solid #d5d5d5}mat-card-title.icons-header h2,.mat-mdc-card-title.icons-header h2{flex:1 1 auto;margin:0;line-height:22px}mat-card-title.icons-header mat-icon,.mat-mdc-card-title.icons-header mat-icon{flex:0 0 auto;margin-left:10px;height:22px;line-height:22px}[data-type=donationLogin].login-panel{padding:16px 25px;width:100%}@media (min-width: 992px){[data-type=donationLogin].login-panel{width:400px}}[data-type=donationLogin] .login-panel__header{justify-content:space-between;align-items:center!important;margin-bottom:15px}[data-type=donationLogin] .login-panel__header .mat-mdc-card-title{line-height:0;margin:0}[data-type=donationLogin] .login-panel__header .close{border-radius:13px;height:26px;width:26px;background-color:#f5f5f5}[data-type=donationLogin] .login-panel__tools{display:flex;justify-content:space-between;padding-top:12px!important}[data-type=donationLogin] .login-panel__tools a#usernameLink,[data-type=donationLogin] .login-panel__tools a#passwordLink{font-size:16px;display:inline-block;text-decoration:none;padding:0!important;border:0px!important}[data-type=donationLogin] .login-panel__tools a#usernameLink:hover:not(.btn),[data-type=donationLogin] .login-panel__tools a#passwordLink:hover:not(.btn){text-decoration:underline!important}@media (min-width: 992px){[data-type=donationLogin] .login-panel__tools a#usernameLink,[data-type=donationLogin] .login-panel__tools a#passwordLink{font-size:18px}}[data-type=donationLogin] .login-panel__social{margin-top:20px;padding-top:20px;border-top:1px solid #bababa;width:100%}@media (min-width: 992px){[data-type=donationLogin] .login-panel__social{margin-top:30px}}[data-type=donationLogin] .login-panel__social p{margin-bottom:5px}[data-type=donationLogin] .login.error-message{margin-bottom:10px;max-width:-moz-fit-content;max-width:fit-content}[data-type=donationLogin] button.btn.btn-default.btn-flow{margin-top:0!important}[data-type=donationLogin] .mat-card-content{margin-bottom:0}.login-panel .login-error-message{margin-bottom:10px;max-width:-moz-fit-content;max-width:fit-content}.login-panel__error-msg{white-space:normal}.login-panel__error-msg>a:not(.btn)#err-reset-username,.login-panel__error-msg>a:not(.btn)#err-reset-password{text-decoration:underline!important;color:inherit!important}.login-panel__header__heading{margin-bottom:10px}.login-panel__user .username-form-field,.login-panel__user .password-form-field{margin-bottom:1.4em}.login-panel__user button.mat-mdc-unelevated-button.mat-primary{padding:0 30px;border-radius:20px!important;box-sizing:border-box;border:1px solid transparent;letter-spacing:normal;background-color:#61a220;color:#fff}.login-panel__user button.mat-mdc-unelevated-button.mat-primary:disabled:hover{cursor:not-allowed}.login-panel__user button.mat-mdc-unelevated-button.mat-primary:enabled:hover{background-color:#db3a00}.rx-login-container .login-panel__tools{padding:0}.mat-mdc-form-field-flex{display:inline-flex!important;flex-direction:row!important}.mat-mdc-form-field-input-control{position:absolute;bottom:4px;background-color:transparent!important}.mdc-line-ripple{display:none}.mat-mdc-form-field-appearance-legacy .mat-mdc-form-field-suffix .passwordVisible{margin-top:16px}.mat-mdc-form-field-appearance-legacy .mat-mdc-form-field-suffix .passwordVisible .mat-button-wrapper .mat-icon{font-size:18px;line-height:1;width:unset;height:unset;vertical-align:unset}\n'],encapsulation:2})};v=(0,s.gn)([(0,D.c)(),(0,s.w6)("design:paramtypes",[_.qu,n.L$,n.V1,I.V1])],v)},21875:(Z,K,t)=>{"use strict";t.d(K,{MR:()=>P,x9:()=>a,ZF:()=>C,HB:()=>u,iv:()=>r,V1:()=>y});var s=t(96814),e=t(65619),_=t(22096),n=t(58504),i=t(65879);let P=(()=>{class L{constructor(c,l,d){this.rendererFactory=c,this.document=l,this.errorHandler=d,this.isGoogleLocationScriptLoaded=!1,this.slickLoaded$=new e.X(!1),this.renderer=this.rendererFactory.createRenderer(null,null)}addGoogleLocationApiScriptToPage(c){if(!c)return(0,n._)("no api key was provided script to load the google location api script");if(this.isGoogleLocationScriptLoaded)return(0,_.of)(c);try{const l=this.createGooglePlacesScriptElement(c);return this.renderer.appendChild(this.document.head,l),(0,_.of)(c)}catch(l){return this.errorHandler.handleError(l),this.isGoogleLocationScriptLoaded=!1,(0,n._)("failed to load the google location api script")}}createGooglePlacesScriptElement(c){const l=`https://maps.googleapis.com/maps/api/js?key=${c}&libraries=places&loading=async`,d=this.renderer.createElement("script");return d.type="text/javascript",d.src=l,d.onload=()=>{const A=setTimeout(()=>{this.isGoogleLocationScriptLoaded=!1,(0,n._)("timed out loading google location script")},1e3);this.getGoogleAutocomplete().getPlacePredictions({input:"Brisbane,Australia",types:["(cities)"]},(v,b)=>{clearTimeout(A),b===google.maps.places.PlacesServiceStatus.OK?this.isGoogleLocationScriptLoaded=!0:(console.error("api key is not valid"),this.isGoogleLocationScriptLoaded=!1,(0,n._)("api key is not valid"))})},d.onerror=()=>{this.isGoogleLocationScriptLoaded=!1,(0,n._)("error loading google location script")},d}getGoogleAutocomplete(){return new google.maps.places.AutocompleteService}addSlickSliderScript(){if(this.checkSlickLoaded())console.debug("script: slick is loaded"),this.slickLoaded$.next(!0);else{console.debug("script: slick is not loaded");const c=this.createSlickScriptElement();this.renderer.appendChild(this.document.body,c)}}createSlickScriptElement(){const c=this.renderer.createElement("script");return c.type="text/javascript",c.src="/ui/assets/scripts/slick.min.js",c.onerror=()=>{console.error("script: error loading slick script")},c.onload=()=>{console.debug("script: slick added to the page"),this.slickLoaded$.next(!0)},c}isSlickLoaded(){return this.slickLoaded$.asObservable()}checkSlickLoaded(){return typeof $.fn.slick<"u"||!!$.fn.slick}static#t=this.\u0275fac=function(l){return new(l||L)(i.LFG(i.FYo),i.LFG(s.K0),i.LFG(i.qLn))};static#e=this.\u0275prov=i.Yz7({token:L,factory:L.\u0275fac,providedIn:"root"})}return L})();var D=t(6990);class I extends Error{constructor(g,c){super(),this.message=`Error on key: ${g||"n/a"}, message: ${c||"n/a"}`,this.name="StorageError"}}var T=t(10459);let a=(()=>{class L{constructor(c){this.ngxCookieService=c,this.immediateAccessCookieStorage={}}getCookie(c){let l;return this.immediateAccessCookieStorage.hasOwnProperty(c)?l=this.immediateAccessCookieStorage[c]:(l=this.ngxCookieService.get(c),this.immediateAccessCookieStorage[c]=l),l}set(c,l,d){this.ngxCookieService.set(c,l,d?.expires,d?.path,d?.domain,d?.secure,d?.sameSite)}setCookie(c,l){const d=new Date;d.setMonth(d.getMonth()+3),this.ngxCookieService.set(c,l,d,"/",this.getCookieDomain()),this.immediateAccessCookieStorage[c]=l}removeCookie(c,l){l?this.ngxCookieService.delete(c,l.path,l.domain):this.ngxCookieService.delete(c,"/",this.getCookieDomain()),this.immediateAccessCookieStorage.hasOwnProperty(c)&&delete this.immediateAccessCookieStorage[c]}getCurrentCulture(){const c=`RaisinCulture_${window.raisin_dd.SubEventId||window.raisin_dd.RequestedSubEventId}`;return this.getCookie(c)}setCurrentCulture(c){window.raisin_dd.Culture=c;const l=`RaisinCulture_${window.raisin_dd.SubEventId||window.raisin_dd.RequestedSubEventId}`;this.setCookie(l,c)}getCookieDomain(){const c=location.hostname.split(".");return(0,D.drop)(c,c.length>2?1:0).join(".")}static#t=this.\u0275fac=function(l){return new(l||L)(i.LFG(T.N))};static#e=this.\u0275prov=i.Yz7({token:L,factory:L.\u0275fac,providedIn:"root"})}return L})(),y=(()=>{class L{get eventParams(){return this.eventParamaters}constructor(c){this.cookieService=c,this.eventParamaters=null,this.STORAGE_SIDE_NAV_COLLAPSED_KEY="sideNavCollapsed",this.STORAGE_JWT_KEY="jwt",this.STORAGE_LANGUAGE_KEY="language",this.STORAGE_ROLES_KEY="roles",this.STORAGE_SUBEVENT_ID_KEY="subEventId",this.STORAGE_ORGANIZATION_ID_KEY="organizationId",this.STORAGE_FIRSTLOGIN_KEY="firstLogin",this.STORAGE_QUERYPARAMS_KEY="queryParams",this.COOKIE_JWT_KEY="jwt",this.COOKIE_CULTURE_KEY="RaisinCulture",this.STORAGE_FLOWPAGESTATE_KEY="flowPageState",this.STORAGE_CURRENTFLOW_KEY="currentFlow",this.STORAGE_ADDITIONAL_PARTICIPANTS_KEY="aps"}setEventParams(c){let l=this.eventParamaters;(0,D.isNil)(l)&&(l={}),!(0,D.isNil)(c)&&!(0,D.isEmpty)(c)&&(this.eventParamaters={...l,...c},this.eventParamaters.subEventCustomPart=this.eventParamaters.subEventCustomPart?.toLowerCase())}setQueryParams(c){(0,D.isEmpty)(c)||(0,D.isNil)(c)?this.removeData(this.STORAGE_QUERYPARAMS_KEY):this.setData(this.STORAGE_QUERYPARAMS_KEY,c)}setSideNavCollapsed(c){this.setData(this.STORAGE_SIDE_NAV_COLLAPSED_KEY,c)}setLanguage(c){this.setData(this.STORAGE_LANGUAGE_KEY,c)}setFirstLogin(c){this.setData(this.STORAGE_FIRSTLOGIN_KEY,c)}setSubEventId(c){this.setData(this.STORAGE_SUBEVENT_ID_KEY,c),this.setOtherLangangeKeys(0!==c,this.STORAGE_SUBEVENT_ID_KEY,c)}setOrganizationId(c){this.setData(this.STORAGE_ORGANIZATION_ID_KEY,c),this.setOtherLangangeKeys(0!==c,this.STORAGE_ORGANIZATION_ID_KEY,c)}setJWT(c,l=!1){this.setData(this.STORAGE_JWT_KEY,c),this.setOtherLangangeKeys(l,this.STORAGE_JWT_KEY,c)}setRoles(c){this.setData(this.STORAGE_ROLES_KEY,c),this.setOtherLangangeKeys(c.length>0,this.STORAGE_ROLES_KEY,c)}getQueryParams(){return this.getData(this.STORAGE_QUERYPARAMS_KEY)}getSideNavCollapsed(){return!!this.getData(this.STORAGE_SIDE_NAV_COLLAPSED_KEY)}getLanguage(){return this.getData(this.STORAGE_LANGUAGE_KEY)}getJWT(){return this.getData(this.STORAGE_JWT_KEY)}getRoles(){return this.getData(this.STORAGE_ROLES_KEY)}isFirstLogin(){return this.getData(this.STORAGE_FIRSTLOGIN_KEY)}getSubEventId(){return this.getData(this.STORAGE_SUBEVENT_ID_KEY)}getOrganizationId(){return this.getData(this.STORAGE_ORGANIZATION_ID_KEY)}getLanguages(){return this.getData("languages")}clear(){(!(0,D.isNil)(this.eventParams)||!(0,D.isEmpty)(this.eventParams))&&(this.removeData(this.STORAGE_SIDE_NAV_COLLAPSED_KEY),this.removeData(this.STORAGE_LANGUAGE_KEY),this.removeData(this.STORAGE_ROLES_KEY),this.removeData(this.STORAGE_FIRSTLOGIN_KEY),this.deleteJWTDataFromCookie())}getData(c,l=null){if((0,D.isNil)(this.eventParams)||(0,D.isEmpty)(this.eventParams)||(0,D.isNil)(c))return null;const d=this.buildKey(l,c),A=sessionStorage.getItem(d);if((0,D.isNil)(A))return["baseAPIUrl","UseV3ParticipantCentre"].includes(c)?(0,D.get)(window,["raisin_dd",c],null):null;try{return A?JSON.parse(A):null}catch{return null}}setData(c,l,d=null){if((0,D.isNil)(this.eventParams))throw new I(c,"eventParams not set");if((0,D.isEmpty)(c))throw new I(c,"key not set");const A=this.buildKey(d,c);sessionStorage.setItem(A,JSON.stringify(l))}removeData(c,l=null){if((0,D.isNil)(this.eventParams)||(0,D.isEmpty)(this.eventParams))throw new I(c,"eventParams not set");if((0,D.isEmpty)(c))throw new I(c,"key not set");const d=this.buildKey(l,c);sessionStorage.removeItem(d)}buildKey(c,l){const d=c||this.eventParams?.subEventCustomPart;return`${l}_${d?.toLowerCase()}`}setCulture(c,l){this.setData("culture",l),this.cookieService.set(`${this.COOKIE_CULTURE_KEY}_${c}`,l,{path:"/",domain:this.getCookieDomain()})}clearFlowData(){this.removeData(this.STORAGE_FLOWPAGESTATE_KEY),this.removeData(this.STORAGE_CURRENTFLOW_KEY),this.removeData(this.STORAGE_ADDITIONAL_PARTICIPANTS_KEY)}updateSessionStorageFromCookie(c){const l=this.getJWTDataInCookie();(0,D.isNil)(l)||(this.setJWT(l.value),this.setRoles(l.roles),this.setLanguage(l.culture),this.setFirstLogin(l.firstLogin),c&&this.deleteJWTDataFromCookie())}setJWTDataInCookie(c){const l=new Date;l.setMinutes(l.getMinutes()+60),this.cookieService.set(`${this.COOKIE_JWT_KEY}_${this.getSubEventId()}`,JSON.stringify(c),{expires:l,path:"/",domain:this.getCookieDomain(),secure:!0,sameSite:"None"})}getJWTDataInCookie(){if((0,D.isNil)(this.eventParams))return null;const c=this.cookieService.getCookie(`${this.COOKIE_JWT_KEY}_${this.getSubEventId()}`);try{return(0,D.isEmpty)(c)?null:JSON.parse(c)}catch{return null}}deleteJWTDataFromCookie(){this.cookieService.removeCookie(`${this.COOKIE_JWT_KEY}_${this.getSubEventId()}`,{path:"/",domain:this.getCookieDomain(),secure:!0,sameSite:"None"})}getCookieDomain(){return(0,D.drop)(location.hostname.split(".")).join(".")}setOtherLangangeKeys(c,l,d){const A=this.getData("languages");if(A&&null!==this.eventParamaters&&!(0,D.isEmpty)(this.eventParamaters)){const S=(0,D.reject)(A,v=>(0,D.toLower)(v.url)===this.eventParamaters?.subEventCustomPart);S.length>0&&S.forEach(v=>{c?this.setData(l,d,v.url):this.removeData(l,v.url)})}}static#t=this.\u0275fac=function(l){return new(l||L)(i.LFG(a))};static#e=this.\u0275prov=i.Yz7({token:L,factory:L.\u0275fac,providedIn:"root"})}return L})();var f=t(50768);let r=(()=>{class L{static#t=this.\u0275fac=function(l){return new(l||L)};static#e=this.\u0275mod=i.oAB({type:L});static#i=this.\u0275inj=i.cJS({providers:[P,y,a],imports:[s.ez,f.Bz]})}return L})();var u=function(L){return L.INDIVIDUAL="Individual",L.TEAM_MEMBER="TeamMember",L.TEAM_CAPTAIN="TeamCaptain",L}(u||{});const C=new i.OlP("release-name",{factory:()=>"4.4.1810"})},4755:(Z,K,t)=>{"use strict";t.d(K,{ET:()=>T,NA:()=>_,SA:()=>n});var s=t(96814),e=t(65879);let _=(()=>{class a{static#t=this.\u0275fac=function(r){return new(r||a)};static#e=this.\u0275mod=e.oAB({type:a});static#i=this.\u0275inj=e.cJS({imports:[s.ez]})}return a})();var n=function(a){return a[a.Unknown=-1]="Unknown",a[a.NotSet=0]="NotSet",a[a.Twitch=1]="Twitch",a[a.Youtube=2]="Youtube",a[a.Facebook=3]="Facebook",a}(n||{}),i=t(22096),P=t(6990);let D=(()=>{class a{load(f){const r=this.getStreamingType(f);return(0,i.of)(r===n.NotSet||r===n.Unknown?{streamingType:r}:{streamingType:r,params:this.getStreamingParams(f)})}getStreamingType(f){const r=(0,P.get)(f,"streamingType");return(0,P.isNil)(r)?n.NotSet:(0,P.isNumber)(r)&&r in n?r:(console.warn(`Unknown streaming type ${r} provided.`),n.Unknown)}getStreamingParams(f){const r=(0,P.get)(f,"streamingParams");if((0,P.isNil)(r))return{};if((0,P.isObject)(r))return{...r};try{const u=JSON.parse(r);return!(0,P.isNil)(u)&&(0,P.isObject)(u)?u:{}}catch{return console.warn("Failed to parse streaming params from string using json deserialization."),{}}}static#t=this.\u0275fac=function(r){return new(r||a)};static#e=this.\u0275prov=e.Yz7({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})();var I=t(65619);let T=(()=>{class a{constructor(f){this.feedConfigDataService=f,this.feedConfigSubject=new I.X({streamingType:n.NotSet}),this.feedConfig$=this.feedConfigSubject.asObservable()}load(f){this.feedConfigDataService.load(f).subscribe(r=>{this.feedConfigSubject.next(r)},r=>{console.error("err",r)})}static#t=this.\u0275fac=function(r){return new(r||a)(e.LFG(D))};static#e=this.\u0275prov=e.Yz7({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})()},28910:(Z,K,t)=>{"use strict";t.d(K,{_:()=>D});var s=t(96814),e=t(4755),_=t(65879);let n=(()=>{class T{static#t=this.\u0275fac=function(f){return new(f||T)};static#e=this.\u0275mod=_.oAB({type:T});static#i=this.\u0275inj=_.cJS({imports:[s.ez]})}return T})();t(67221),t(68910);let D=(()=>{class T{static#t=this.\u0275fac=function(f){return new(f||T)};static#e=this.\u0275mod=_.oAB({type:T});static#i=this.\u0275inj=_.cJS({imports:[s.ez,e.NA,n]})}return T})();t(37647)},37647:(Z,K,t)=>{"use strict";t.d(K,{e:()=>R});var s=t(4755),e=t(6990),_=t(99397),n=t(65879),i=t(96814),P=t(67221),D=t(68910),I=t(56773),T=t(6593);function a(B,E){if(1&B&&n._UZ(0,"iframe",4),2&B){const m=n.oxw(2);n.Q6J("src",m.videoUrl,n.uOi)}}function y(B,E){if(1&B&&n._UZ(0,"iframe",7),2&B){const m=n.oxw(3);n.Q6J("src",m.chatUrl,n.uOi)}}function f(B,E){if(1&B&&(n.TgZ(0,"div",5),n.YNc(1,y,1,1,"iframe",6),n.qZA()),2&B){const m=n.oxw(2);n.xp6(1),n.Q6J("ngIf",m.chatUrl)}}function r(B,E){if(1&B&&(n.TgZ(0,"div")(1,"div",1),n.YNc(2,a,1,1,"iframe",2),n.qZA(),n.YNc(3,f,2,1,"div",3),n.qZA()),2&B){const m=n.oxw();n.Gre("youtube-embed__container layout-",m.layout||m.defaultLayout,""),n.Udp("height",m.height)("width",m.width)("height",m.height,"px")("width",m.width,"px"),n.xp6(2),n.Q6J("ngIf",m.videoUrl),n.xp6(1),n.Q6J("ngIf","video"!=m.layout)}}let u=(()=>{class B{constructor(m){this.domSanitizer=m,this.wrapper="youtube-embed",this.height=I.n0,this.width=I.s4,this.pausePlayer=!1,this.streaming=new n.vpe,this.defaultLayout=I.M8}ngOnChanges(m){m.videoId&&this.videoId&&(this.videoUrl=this.domSanitizer.bypassSecurityTrustResourceUrl(`https://www.youtube.com/embed/${this.videoId}`),this.chatUrl=this.domSanitizer.bypassSecurityTrustResourceUrl(`https://www.youtube.com/live_chat?v=${this.videoId}&embed_domain=${location.hostname}`),this.streaming.emit(!0)),m.height&&(this.height=this.height??I.n0),m.width&&(this.width=this.width??I.s4)}static#t=this.\u0275fac=function(p){return new(p||B)(n.Y36(T.H7))};static#e=this.\u0275cmp=n.Xpm({type:B,selectors:[["streaming-ui-youtube-embed"]],hostVars:2,hostBindings:function(p,O){2&p&&n.Tol(O.wrapper)},inputs:{layout:"layout",videoId:"videoId",height:"height",width:"width",pausePlayer:"pausePlayer"},outputs:{streaming:"streaming"},features:[n.TTD],decls:1,vars:1,consts:[[3,"class","height","width",4,"ngIf"],[1,"youtube-embed__video"],["height","100%","width","100%","title","YouTube video player","allow","accelerometer;\n      autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",3,"src",4,"ngIf"],["class","youtube-embed__chat",4,"ngIf"],["height","100%","width","100%","title","YouTube video player","allow","accelerometer;\n      autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",3,"src"],[1,"youtube-embed__chat"],["height","100%","width","100%","title","YouTube live chat","allow","accelerometer;\n      autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",3,"src",4,"ngIf"],["height","100%","width","100%","title","YouTube live chat","allow","accelerometer;\n      autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",3,"src"]],template:function(p,O){1&p&&n.YNc(0,r,4,13,"div",0),2&p&&n.Q6J("ngIf",!O.pausePlayer)},dependencies:[i.O5],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%]   .youtube-embed__container[_ngcontent-%COMP%]{display:flex}@media (max-width: 767px){[_nghost-%COMP%]   .youtube-embed__container[_ngcontent-%COMP%]{flex-direction:column}[_nghost-%COMP%]   .youtube-embed__container.layout-video-with-chat[_ngcontent-%COMP%]{min-height:600px!important}}[_nghost-%COMP%]   .youtube-embed__video[_ngcontent-%COMP%]{flex:1}[_nghost-%COMP%]   .youtube-embed__chat[_ngcontent-%COMP%]{flex-basis:350px}@media (max-width: 767px){[_nghost-%COMP%]   .youtube-embed__chat[_ngcontent-%COMP%]{flex-grow:1;flex-basis:unset}}"]})}return B})();function C(B,E){if(1&B&&n._UZ(0,"iframe",3),2&B){const m=n.oxw(2);n.Q6J("src",m.iframeSrc,n.uOi)("width",m.width)}}function L(B,E){if(1&B&&(n.TgZ(0,"div",1),n.YNc(1,C,1,2,"iframe",2),n.qZA()),2&B){const m=n.oxw();n.xp6(1),n.Q6J("ngIf",m.iframeSrc)}}let g=(()=>{class B{constructor(m){this.domSantizier=m,this.wrapper="facebook-embed",this.width=I.s4,this.pausePlayer=!1,this.streaming=new n.vpe}ngOnInit(){}ngOnChanges(m){if(m.channel||m.videoId){const p=["https://www.facebook.com/plugins/video.php",`?href=${this.getEncodedUrl()}`,"&show_text=false","&show_captions=true","&width=800px","&height=500px","&appId"].join("");this.iframeSrc=this.domSantizier.bypassSecurityTrustResourceUrl(p),this.streaming.emit(!0)}(m.height||m.width)&&(this.width=this.width??I.s4)}getEncodedUrl(){return encodeURIComponent(`https://www.facebook.com/${this.channel}/videos/${this.videoId}`)}static#t=this.\u0275fac=function(p){return new(p||B)(n.Y36(T.H7))};static#e=this.\u0275cmp=n.Xpm({type:B,selectors:[["streaming-ui-facebook-embed"]],hostVars:2,hostBindings:function(p,O){2&p&&n.Tol(O.wrapper)},inputs:{channel:"channel",videoId:"videoId",width:"width",pausePlayer:"pausePlayer"},outputs:{streaming:"streaming"},features:[n.TTD],decls:1,vars:1,consts:[["class","facebook-embed__container",4,"ngIf"],[1,"facebook-embed__container"],["class","facebook-embed__iframe","title","Facebook video player","style","border:none;overflow:hidden","allow","autoplay; clipboard-write; encrypted-media; picture-in-picture; web-share","allowFullScreen","true",3,"src","width",4,"ngIf"],["title","Facebook video player","allow","autoplay; clipboard-write; encrypted-media; picture-in-picture; web-share","allowFullScreen","true",1,"facebook-embed__iframe",2,"border","none","overflow","hidden",3,"src","width"]],template:function(p,O){1&p&&n.YNc(0,L,2,1,"div",0),2&p&&n.Q6J("ngIf",!O.pausePlayer)},dependencies:[i.O5],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%]   .facebook-embed__iframe[_ngcontent-%COMP%]{aspect-ratio:16/10}"]})}return B})();function c(B,E){if(1&B){const m=n.EpF();n.TgZ(0,"streaming-ui-livestream-header",7),n.NdJ("toggleShowHide",function(O){n.CHM(m);const F=n.oxw(3);return n.KtG(F.pausePlayer=O)}),n.qZA()}if(2&B){const m=n.oxw(2).ngIf,p=n.oxw();n.Q6J("streamingType",m.streamingType)("channel",null==m.params?null:m.params.channel)("videoId",null==m.params?null:m.params.videoId)("labels",p.labels)}}function l(B,E){if(1&B&&(n.TgZ(0,"div",5),n.YNc(1,c,1,4,"streaming-ui-livestream-header",6),n.qZA()),2&B){const m=n.oxw(2);n.xp6(1),n.Q6J("ngIf",m.isStreaming)}}function d(B,E){if(1&B){const m=n.EpF();n.TgZ(0,"streaming-ui-twitch-player",13),n.NdJ("streaming",function(O){n.CHM(m);const F=n.oxw(3);return n.KtG(F.isStreaming=O)}),n.qZA()}if(2&B){const m=n.oxw(2).ngIf,p=n.oxw();n.Q6J("channel",null==m.params?null:m.params.channel)("layout",null==m.params?null:m.params.layout)("width",null==m.params?null:m.params.width)("height",null==m.params?null:m.params.height)("streamWhenOffline",null==m.params?null:m.params.streamWhenOffline)("pause",p.pausePlayer)}}function A(B,E){if(1&B){const m=n.EpF();n.TgZ(0,"streaming-ui-youtube-embed",14),n.NdJ("streaming",function(O){n.CHM(m);const F=n.oxw(3);return n.KtG(F.isStreaming=O)}),n.qZA()}if(2&B){const m=n.oxw(2).ngIf,p=n.oxw();n.Q6J("pausePlayer",p.pausePlayer)("width",null==m.params?null:m.params.width)("height",null==m.params?null:m.params.height)("videoId",null==m.params?null:m.params.videoId)("layout",null==m.params?null:m.params.layout)}}function S(B,E){if(1&B){const m=n.EpF();n.TgZ(0,"streaming-ui-facebook-embed",15),n.NdJ("streaming",function(O){n.CHM(m);const F=n.oxw(3);return n.KtG(F.isStreaming=O)}),n.qZA()}if(2&B){const m=n.oxw(2).ngIf,p=n.oxw();n.Q6J("pausePlayer",p.pausePlayer)("width",null==m.params?null:m.params.width)("videoId",null==m.params?null:m.params.videoId)("channel",null==m.params?null:m.params.channel)}}function v(B,E){if(1&B&&(n.TgZ(0,"div",8),n.ynx(1,9),n.YNc(2,d,1,6,"streaming-ui-twitch-player",10),n.YNc(3,A,1,5,"streaming-ui-youtube-embed",11),n.YNc(4,S,1,4,"streaming-ui-facebook-embed",12),n.BQk(),n.qZA()),2&B){const m=n.oxw().ngIf,p=n.oxw();n.xp6(1),n.Q6J("ngSwitch",m.streamingType),n.xp6(1),n.Q6J("ngSwitchCase",p.streamingType.Twitch),n.xp6(1),n.Q6J("ngSwitchCase",p.streamingType.Youtube),n.xp6(1),n.Q6J("ngSwitchCase",p.streamingType.Facebook)}}function b(B,E){1&B&&n._UZ(0,"div",16)}function M(B,E){if(1&B&&(n.TgZ(0,"div",1),n.YNc(1,l,2,1,"div",2),n.YNc(2,v,5,4,"div",3),n.YNc(3,b,1,0,"div",4),n.qZA()),2&B){const m=n.oxw();n.ekj("streaming",m.isStreaming),n.xp6(1),n.Q6J("ngIf",m.hasHeader),n.xp6(1),n.Q6J("ngIf",m.hasStreamingType),n.xp6(1),n.Q6J("ngIf",m.hasFooter)}}let R=(()=>{class B{constructor(m){this.feedFacade=m,this.hideHeader=!1,this.hideFooter=!1,this.streamingType=s.SA,this.hasStreamingType=!1,this.hasHeader=!1,this.hasFooter=!1,this.isTwitch=!1,this.feedConfig$=this.feedFacade.feedConfig$.pipe((0,_.b)(p=>this.hasStreamingType=!(0,e.includes)([s.SA.NotSet,s.SA.Unknown],p?.streamingType)),(0,_.b)(()=>this.hasHeader=!this.hideHeader&&this.hasStreamingType),(0,_.b)(()=>this.hasFooter=!this.hideFooter&&this.hasStreamingType),(0,_.b)(p=>this.isTwitch=this.hasStreamingType&&p?.streamingType===s.SA.Twitch)),this.isStreaming=!1,this.pausePlayer=!1}ngOnInit(){this.load()}ngOnChanges(m){(0,e.isEqual)(m?.feedConfig?.previousValue,m?.feedConfig?.currentValue)||this.load()}load(){this.feedFacade.load(this.feedConfig)}static#t=this.\u0275fac=function(p){return new(p||B)(n.Y36(s.ET))};static#e=this.\u0275cmp=n.Xpm({type:B,selectors:[["streaming-feed"]],inputs:{feedConfig:"feedConfig",labels:"labels",hideHeader:"hideHeader",hideFooter:"hideFooter"},features:[n.TTD],decls:2,vars:3,consts:[["class","streaming-feed__container",3,"streaming",4,"ngIf"],[1,"streaming-feed__container"],["class","streaming-feed__container-header",4,"ngIf"],["class","streaming-feed__container-player",4,"ngIf"],["class","streaming-feed__container-footer",4,"ngIf"],[1,"streaming-feed__container-header"],[3,"streamingType","channel","videoId","labels","toggleShowHide",4,"ngIf"],[3,"streamingType","channel","videoId","labels","toggleShowHide"],[1,"streaming-feed__container-player"],[3,"ngSwitch"],[3,"channel","layout","width","height","streamWhenOffline","pause","streaming",4,"ngSwitchCase"],[3,"pausePlayer","width","height","videoId","layout","streaming",4,"ngSwitchCase"],[3,"pausePlayer","width","videoId","channel","streaming",4,"ngSwitchCase"],[3,"channel","layout","width","height","streamWhenOffline","pause","streaming"],[3,"pausePlayer","width","height","videoId","layout","streaming"],[3,"pausePlayer","width","videoId","channel","streaming"],[1,"streaming-feed__container-footer"]],template:function(p,O){1&p&&(n.YNc(0,M,4,5,"div",0),n.ALo(1,"async")),2&p&&n.Q6J("ngIf",n.lcZ(1,1,O.feedConfig$))},dependencies:[i.O5,i.RF,i.n9,P.m,D.E,u,g,i.Ov],styles:[".streaming-feed[_ngcontent-%COMP%]{display:flex}.streaming-feed__container[_ngcontent-%COMP%]{width:100%;display:none;flex-direction:column}.streaming-feed__container.streaming[_ngcontent-%COMP%]{display:flex}.streaming-feed__container-header[_ngcontent-%COMP%]{margin-top:15px;margin-bottom:10px}.streaming-feed__container-footer[_ngcontent-%COMP%]{border-bottom:1px solid #979797;margin-top:15px;margin-bottom:25px}"]})}return B})()},56773:(Z,K,t)=>{"use strict";t.d(K,{M8:()=>s,n0:()=>e,s4:()=>_});const s="video-with-chat",e=480,_="100%"},68910:(Z,K,t)=>{"use strict";t.d(K,{E:()=>I});var s=t(65879),e=t(4755),_=t(96814);function n(T,a){1&T&&(s.O4$(),s.TgZ(0,"svg",9),s._UZ(1,"path",10)(2,"path",11),s.qZA())}function i(T,a){1&T&&(s.O4$(),s.TgZ(0,"svg",12),s._UZ(1,"path",13),s.qZA())}function P(T,a){1&T&&(s.O4$(),s.TgZ(0,"svg",14)(1,"title"),s._uU(2,"icon/facebook blue"),s.qZA(),s.TgZ(3,"desc"),s._uU(4,"Created with Sketch."),s.qZA(),s.TgZ(5,"g",15),s._UZ(6,"path",16),s.qZA()())}function D(T,a){if(1&T&&(s.TgZ(0,"a",17),s._uU(1),s.qZA()),2&T){const y=s.oxw();s.Q6J("href",y.linkHref,s.LSH),s.xp6(1),s.AsE("",y.labels.txt_ViewOn," ",y.streamingTypeEnum[y.streamingType],"")}}let I=(()=>{class T{constructor(){this.wrapper="livestream-header",this.channel="",this.videoId="",this.labels={},this.toggleShowHide=new s.vpe,this.hidden=!1,this.streamingTypeEnum=e.SA}ngOnInit(){}ngOnChanges(y){if(y.streamingType||y.channel||y.videoId)switch(this.streamingType){case e.SA.Youtube:this.linkHref=`https://youtu.be/${this.videoId}`;break;case e.SA.Facebook:this.linkHref=`https://www.facebook.com/${this.channel}/videos/${this.videoId}`;break;case e.SA.Twitch:this.linkHref=`https://www.twitch.tv/${this.channel}`}}toggleShowHideClicked(){this.hidden=!this.hidden,this.toggleShowHide.emit(this.hidden)}static#t=this.\u0275fac=function(f){return new(f||T)};static#e=this.\u0275cmp=s.Xpm({type:T,selectors:[["streaming-ui-livestream-header"]],hostVars:2,hostBindings:function(f,r){2&f&&s.Tol(r.wrapper)},inputs:{streamingType:"streamingType",channel:"channel",videoId:"videoId",labels:"labels"},outputs:{toggleShowHide:"toggleShowHide"},features:[s.TTD],decls:12,vars:8,consts:[[1,"streaming-twitch-header"],[1,"streaming-twitch-header-txt-1"],[1,"streaming-twitch-header-txt-2"],[3,"ngSwitch"],["xmlns","http://www.w3.org/2000/svg","fill","currentColor","class","streaming-twitch-header-icon","viewBox","0 0 16 16",4,"ngSwitchCase"],["version","1.1","id","Layer_1","xmlns","http://www.w3.org/2000/svg",0,"xmlns","xlink","http://www.w3.org/1999/xlink","x","0px","class","youtube-icon","y","0px","viewBox","0 0 512 512","style","enable-background:new 0 0 512 512;",0,"xml","space","preserve",4,"ngSwitchCase"],["width","23px","height","23px","viewBox","0 0 23 23","version","1.1","xmlns","http://www.w3.org/2000/svg","class","facebook-icon",0,"xmlns","xlink","http://www.w3.org/1999/xlink",4,"ngSwitchCase"],["class","streaming-twitch-header-view-on","target","_blank","rel","noopener",3,"href",4,"ngIf"],[1,"streaming-twitch-header-showhide","btn",3,"click"],["xmlns","http://www.w3.org/2000/svg","fill","currentColor","viewBox","0 0 16 16",1,"streaming-twitch-header-icon"],["d","M3.857 0 1 2.857v10.286h3.429V16l2.857-2.857H9.57L14.714 8V0H3.857zm9.714 7.429-2.285 2.285H9l-2 2v-2H4.429V1.143h9.142v6.286z"],["d","M11.857 3.143h-1.143V6.57h1.143V3.143zm-3.143 0H7.571V6.57h1.143V3.143z"],["version","1.1","id","Layer_1","xmlns","http://www.w3.org/2000/svg",0,"xmlns","xlink","http://www.w3.org/1999/xlink","x","0px","y","0px","viewBox","0 0 512 512",0,"xml","space","preserve",1,"youtube-icon",2,"enable-background","new 0 0 512 512"],["d","M492.044,106.769c-18.482-21.97-52.604-30.931-117.77-30.931H137.721\n      c-66.657,0-101.358,9.54-119.77,32.93C0,131.572,0,165.174,0,211.681v88.64c0,90.097,21.299,135.842,137.721,135.842h236.554\n      c56.512,0,87.826-7.908,108.085-27.296C503.136,388.985,512,356.522,512,300.321v-88.64\n      C512,162.636,510.611,128.836,492.044,106.769z M328.706,268.238l-107.418,56.14c-2.401,1.255-5.028,1.878-7.65,1.878\n      c-2.97,0-5.933-0.799-8.557-2.388c-4.942-2.994-7.959-8.351-7.959-14.128V197.82c0-5.767,3.009-11.119,7.941-14.115\n      c4.933-2.996,11.069-3.201,16.187-0.542l107.418,55.778c5.465,2.837,8.897,8.479,8.905,14.635\n      C337.58,259.738,334.163,265.388,328.706,268.238z",2,"fill","#D7143A"],["width","23px","height","23px","viewBox","0 0 23 23","version","1.1","xmlns","http://www.w3.org/2000/svg",0,"xmlns","xlink","http://www.w3.org/1999/xlink",1,"facebook-icon"],["id","icon/facebook-blue","stroke","none","stroke-width","1","fill","none","fill-rule","evenodd"],["d","M18.5769231,-2.13162821e-14 L4.42307692,-2.13162821e-14 C2.00512821,-2.13162821e-14 0,2.00512821 0,4.42307692 L0,18.5769231 C0,20.9948718 2.00512821,23 4.42307692,23 L18.5769231,23 C20.9948718,23 23,20.9948718 23,18.5769231 L23,4.42307692 C23,2.00512821 21.0538462,-2.13162821e-14 18.5769231,-2.13162821e-14 Z M13.4972234,7.13390789 L13.4972234,9.44619528 L16.6936207,9.44619528 L16.6936207,11.4184404 L13.4972234,11.4184404 L13.4972234,19.3074209 L11.1169275,19.3074209 L11.1169275,11.4184404 L8.32858097,11.4184404 L8.32858097,9.44619528 L11.1169275,9.44619528 L11.1169275,6.72585717 C11.1169275,5.16166276 12.3410797,3.86950215 13.8372656,3.86950215 L16.6936207,3.86950215 L16.6936207,5.97776419 L14.5173502,5.97776419 C13.9732825,5.97776419 13.4972234,6.52183181 13.4972234,7.13390789 Z","id","facebook","fill","#1975d2"],["target","_blank","rel","noopener",1,"streaming-twitch-header-view-on",3,"href"]],template:function(f,r){1&f&&(s.TgZ(0,"div",0)(1,"span",1),s._uU(2),s.qZA(),s.TgZ(3,"span",2),s._uU(4),s.qZA(),s.ynx(5,3),s.YNc(6,n,3,0,"svg",4),s.YNc(7,i,2,0,"svg",5),s.YNc(8,P,7,0,"svg",6),s.BQk(),s.YNc(9,D,2,3,"a",7),s.TgZ(10,"a",8),s.NdJ("click",function(){return r.toggleShowHideClicked()}),s._uU(11),s.qZA()()),2&f&&(s.xp6(2),s.Oqu(r.labels.txt_LiveStream),s.xp6(2),s.Oqu(r.labels.txt_CurrentlyStreaming),s.xp6(1),s.Q6J("ngSwitch",r.streamingType),s.xp6(1),s.Q6J("ngSwitchCase",r.streamingTypeEnum.Twitch),s.xp6(1),s.Q6J("ngSwitchCase",r.streamingTypeEnum.Youtube),s.xp6(1),s.Q6J("ngSwitchCase",r.streamingTypeEnum.Facebook),s.xp6(1),s.Q6J("ngIf",r.linkHref),s.xp6(2),s.Oqu(r.hidden?r.labels.lbl_Show:r.labels.lbl_Hide))},dependencies:[_.O5,_.RF,_.n9],styles:[".streaming-twitch-header-txt-1[_ngcontent-%COMP%]{font-size:2rem;font-weight:700;margin-right:20px}@media (max-width: 767px){.streaming-twitch-header-txt-1[_ngcontent-%COMP%]{display:block;margin-right:0}}.streaming-twitch-header-txt-2[_ngcontent-%COMP%]{font-size:1rem;padding-right:5px;margin-right:5px;border-right:1px solid #979797}@media (max-width: 767px){.streaming-twitch-header-txt-2[_ngcontent-%COMP%]{display:block;border-right:none;padding-right:0;margin-right:0}}.streaming-twitch-header-icon[_ngcontent-%COMP%]{fill:#6441a5;width:1em;height:1em}.streaming-twitch-header-view-on[_ngcontent-%COMP%]{font-size:1rem;margin-left:10px;text-decoration:underline}.streaming-twitch-header-showhide[_ngcontent-%COMP%]{float:right;color:#1975d2;background-color:#fff;border:1px solid #1975d2;margin:0;font-weight:700}.streaming-twitch-header[_ngcontent-%COMP%]   .youtube-icon[_ngcontent-%COMP%]{height:27px;vertical-align:middle}.streaming-twitch-header[_ngcontent-%COMP%]   .facebook-icon[_ngcontent-%COMP%]{vertical-align:middle}"]})}return T})()},67221:(Z,K,t)=>{"use strict";t.d(K,{m:()=>I});var s=t(65879),e=t(65619),_=t(78645),n=t(6990),i=t(56773);class P{get channel(){return this._channel}get width(){return this._width}set width(a){((0,n.isNumber)(a)&&0!==a||(0,n.isString)(a)&&!(0,n.isEmpty)(a))&&(this._width=a)}get height(){return this._height}set height(a){((0,n.isNumber)(a)&&0!==a||(0,n.isString)(a)&&!(0,n.isEmpty)(a))&&(this._height=a)}get layout(){return this._layout}set layout(a){(0,n.isEmpty)(a)||(this._layout=a)}get autoplay(){return this._autoplay}set autoplay(a){this._autoplay=a}constructor(a){this.defaultLayout=i.M8,this.defaultHeight=i.n0,this.defaultWidth=i.s4,this._width=this.defaultWidth,this._height=this.defaultHeight,this._layout=this.defaultLayout,this._autoplay=!1,this._channel=a}toPlainTwitchObject(){return{channel:this.channel,width:this.width,height:this.height,layout:this.layout,autoplay:this.autoplay}}}var D=t(96814);let I=(()=>{class T{constructor(){this.visibleSubject=new e.X(!1),this.channel="",this.streamWhenOffline=!1,this.pause=!1,this.streaming=new s.vpe,this.defaultLayout=i.M8,this.videoReady=!1,this.videoPlaying=!1,this.$visible=this.visibleSubject.asObservable(),this.scriptLoadedSubject=new _.x,this.scriptLoaded$=this.scriptLoadedSubject.asObservable()}ngOnInit(){this.scriptLoaded$.subscribe(()=>{this.embedTwitchPlayer()}),this.channel&&this.loadScript()}ngOnChanges(y){this.player&&!(0,n.isEqual)(y?.pause?.previousValue,y?.pause?.currentValue)&&(this.pause?(this.player.pause(),this.videoPlaying=!1,this.visibleSubject.next(!1)):(this.player.play(),this.videoPlaying=!0,this.visibleSubject.next(!0)))}ngOnDestroy(){this.scriptLoadedSubject.unsubscribe(),this.onScriptLoadListener&&this.script.removeEventListener("load",this.onScriptLoadListener),this.onVideoReadyListener&&this.embed.removeEventListener(Twitch.Embed.VIDEO_READY,this.onVideoReadyListener),this.onVideoPlayListener&&this.embed.removeEventListener(Twitch.Embed.VIDEO_PLAY,this.onVideoPlayListener)}loadScript(){const y="twitch-embed-js";document.getElementById(y)?this.scriptLoadedSubject.next(!0):(this.script=document.createElement("script"),this.script.type="text/javascript",this.script.id=y,this.script.async=!0,this.script.src="https://embed.twitch.tv/embed/v1.js",this.onScriptLoadListener=()=>this.scriptLoadedSubject.next(!0),this.script.onload=this.onScriptLoadListener,document.head.appendChild(this.script))}embedTwitchPlayer(){const y=new P(this.channel);y.width=this.width,y.height=this.height,y.layout=this.layout,y.autoplay=!1,this.embed=new Twitch.Embed("twitch-embed",y.toPlainTwitchObject()),this.onVideoReadyListener=()=>this.onVideoReady(),this.embed.addEventListener(Twitch.Embed.VIDEO_READY,this.onVideoReadyListener),this.onVideoPlayListener=()=>this.onVideoPlay(),this.embed.addEventListener(Twitch.Embed.VIDEO_PLAY,this.onVideoPlayListener)}onVideoReady(){this.videoReady=!0,this.player=this.embed.getPlayer(),this.player.play(),this.streamWhenOffline&&(this.visibleSubject.next(!0),this.streaming.emit(!0))}onVideoPlay(){this.videoPlaying=!0,this.visibleSubject.next(!0),this.streaming.emit(!0)}static#t=this.\u0275fac=function(f){return new(f||T)};static#e=this.\u0275cmp=s.Xpm({type:T,selectors:[["streaming-ui-twitch-player"]],inputs:{channel:"channel",layout:"layout",width:"width",height:"height",streamWhenOffline:"streamWhenOffline",pause:"pause"},outputs:{streaming:"streaming"},features:[s.TTD],decls:2,vars:7,consts:[["id","twitch-embed"]],template:function(f,r){1&f&&(s.TgZ(0,"div",0),s.ALo(1,"async"),s.qZA()),2&f&&(s.Gre("streaming-twitch-player layout-",r.layout||r.defaultLayout,""),s.ekj("visible",s.lcZ(1,5,r.$visible)))},dependencies:[D.Ov],styles:['.streaming-twitch-player{display:none}.streaming-twitch-player.visible{display:block}@media (max-width: 767px){.streaming-twitch-player.layout-video-with-chat iframe[src*="embed.twitch.tv"]{min-height:580px}}\n'],encapsulation:2})}return T})()},80001:(Z,K,t)=>{"use strict";t.d(K,{$h:()=>n.$,B$:()=>s.B,tH:()=>_.t});var s=t(43520),_=(t(44151),t(11070)),n=t(95809);t(18177),t(25407),t(40479),t(72522)},40479:(Z,K,t)=>{"use strict";t.d(K,{U:()=>C});var s=t(97582),e=t(65879),_=t(17700),n=t(17715),i=t(78645),P=t(22096),D=t(94664),I=t(99397),T=t(59773),a=t(92438);let y=(()=>{class L{constructor(){this.idle$=new i.x,this.wake$=new i.x,this.isIdle=!1,this.idleAfterSeconds=10,(0,a.R)(document,"mousemove").subscribe(()=>this.onInteraction()),(0,a.R)(document,"touchstart").subscribe(()=>this.onInteraction()),(0,a.R)(document,"keydown").subscribe(()=>this.onInteraction())}onInteraction(){this.isIdle&&(this.isIdle=!1,this.wake$.next(!0)),clearTimeout(this.countDown),this.countDown=setTimeout(()=>{this.isIdle=!0,this.idle$.next(!0)},1e3*this.idleAfterSeconds)}static#t=this.\u0275fac=function(l){return new(l||L)};static#e=this.\u0275prov=e.Yz7({token:L,factory:L.\u0275fac,providedIn:"root"})}return L})();var f=t(25407),r=t(72522),u=t(95809);let C=class Te{constructor(g,c,l,d){this.jwtAuthService=g,this.logoutTimer=c,this.idleService=l,this.dialog=d,this.wrapper="token-expiry-check",this.destroyTimers$=new i.x,this.start=!1,this.stop=!1,this.reset=!1,this.redirectIn=5,this.bufferStart=10,this.bufferEnd=5,this.tokenRefreshed=new e.vpe}ngOnChanges(g){g.reset&&g.reset.currentValue!==g.reset.previousValue&&this.reset?(this.logoutTimer.stop(),this.logoutTimer.start(),this.monitoring(),this.tokenRefreshed.emit({isReset:!0})):g.start&&g.start.currentValue!==g.start.previousValue&&this.start?(this.logoutTimer.start(),this.monitoring()):g.stop&&g.stop.currentValue!==g.stop.previousValue&&this.stop&&this.logoutTimer.stop()}monitoring(){this.jwtAuthService.isLoggedIn()?(this.refreshHandler(),this.tokenExpiredHandler(),this.idleHandler()):(console.debug("Timer: anonymous timer start"),this.destroyTimers$.next(!0),this.logoutTimer.tokenHasExpired().pipe((0,n.t)(this),(0,D.w)(()=>(this.jwtAuthService.logOut(),this.jwtAuthService.getAnonymousToken())),(0,I.b)(()=>console.debug("Timer: anonymous token refreshed at:",new Date))).subscribe({next:()=>{this.tokenRefreshed.emit({hasExpired:!0}),this.destroyTimers$.next(!0)}}))}idleHandler(){this.idleService.idle$.pipe((0,n.t)(this),(0,T.R)(this.destroyTimers$)).subscribe({next:g=>console.debug("Timer: Participant is idle since",new Date)}),this.idleService.wake$.pipe((0,n.t)(this),(0,T.R)(this.destroyTimers$),(0,I.b)(()=>console.debug("Timer: Participant is no longer idle since",new Date)),(0,D.w)(()=>{const g=this.logoutTimer.getExpiryDate(),c=new Date(g),l=new Date(g),d=new Date;return l.setMinutes(g.getMinutes()-this.bufferStart),c.setMinutes(g.getMinutes()-this.bufferEnd),console.debug("Timer: in the auto refresh buffer",d.getTime()>l.getTime()&&d.getTime()<c.getTime()),d.getTime()>l.getTime()&&d.getTime()<c.getTime()?this.logoutTimer.refreshToken():(0,P.of)(!1)})).subscribe({next:g=>{g&&(console.debug("Timer: token refreshed at:",new Date),this.tokenRefreshed.emit({isRefreshed:g}),this.destroyTimers$.next(!0))}})}tokenExpiredHandler(){this.logoutTimer.tokenHasExpired().pipe((0,n.t)(this),(0,T.R)(this.destroyTimers$)).subscribe({next:g=>{this.tokenRefreshed.emit({hasExpired:g,redirectIn:this.redirectIn}),g&&this.destroyTimers$.next(!0)}})}refreshHandler(){this.logoutTimer.timeToRefresh().pipe((0,n.t)(this),(0,T.R)(this.destroyTimers$),(0,I.b)(g=>console.debug("Timer: Token expiry dialog opened",g)),(0,D.w)(g=>this.dialog.open(r.j,{disableClose:!0,data:{expiryDate:this.logoutTimer.getExpiryDate(),redirectIn:this.redirectIn}}).afterClosed()),(0,I.b)(g=>console.debug("Timer: Token expiry dialog closed, refresh:",g)),(0,D.w)(g=>g?this.logoutTimer.refreshToken():(0,P.of)(!1))).subscribe({next:g=>{this.tokenRefreshed.emit({isRefreshed:g}),g&&this.destroyTimers$.next(!0)}})}static#t=this.\u0275fac=function(c){return new(c||Te)(e.Y36(u.$),e.Y36(f.W),e.Y36(y),e.Y36(_.uw))};static#e=this.\u0275cmp=e.Xpm({type:Te,selectors:[["token-expiry-check"]],hostVars:2,hostBindings:function(c,l){2&c&&e.Tol(l.wrapper)},inputs:{start:"start",stop:"stop",reset:"reset",redirectIn:"redirectIn",bufferStart:"bufferStart",bufferEnd:"bufferEnd"},outputs:{tokenRefreshed:"tokenRefreshed"},features:[e.TTD],decls:0,vars:0,template:function(c,l){},encapsulation:2})};C=(0,s.gn)([(0,n.c)(),(0,s.w6)("design:paramtypes",[u.$,f.W,y,_.uw])],C)},72522:(Z,K,t)=>{"use strict";t.d(K,{j:()=>M});var s=t(97582),e=t(17700),_=t(78645),n=t(91687),i=t(99397),P=t(59773),D=t(32181),I=t(16676),T=t.n(I),a=t(17715),y=t(6990),r=t(65879),u=t(96814),C=t(32296),L=t(89515);function g(R,B){1&R&&(r.TgZ(0,"h2"),r.ALo(1,"translate"),r._uU(2),r.ALo(3,"translate"),r.qZA()),2&R&&(r.uIk("aria-label",r.lcZ(1,2,"sessionExpiry.title.expiring")),r.xp6(2),r.hij(" ",r.lcZ(3,4,"sessionExpiry.title.expiring")," "))}function c(R,B){1&R&&(r.TgZ(0,"h2"),r.ALo(1,"translate"),r._uU(2),r.ALo(3,"translate"),r.qZA()),2&R&&(r.uIk("aria-label",r.lcZ(1,2,"sessionExpiry.title.expired")),r.xp6(2),r.hij(" ",r.lcZ(3,4,"sessionExpiry.title.expired")," "))}function l(R,B){if(1&R&&(r.TgZ(0,"div",8),r._uU(1),r.ALo(2,"translate"),r.qZA()),2&R){const E=r.oxw();r.xp6(1),r.AsE("",r.lcZ(2,2,"sessionExpiry.timerMessage")," ",E.expiryTimeMessage," ")}}function d(R,B){1&R&&(r.TgZ(0,"div",9),r._uU(1),r.ALo(2,"translate"),r.qZA()),2&R&&(r.xp6(1),r.Oqu(r.lcZ(2,1,"sessionExpiry.stillWorking")))}function A(R,B){if(1&R&&(r.TgZ(0,"div",10),r._uU(1),r.ALo(2,"translate"),r.qZA()),2&R){const E=r.oxw();r.xp6(1),r.Oqu(r.xi3(2,1,"sessionExpiry.expiredAt",E.params))}}function S(R,B){if(1&R&&(r.TgZ(0,"div",10),r._uU(1),r.ALo(2,"translate"),r.qZA()),2&R){const E=r.oxw();r.xp6(1),r.Oqu(r.xi3(2,1,"sessionExpiry.redirectIn",E.params))}}function v(R,B){1&R&&(r.TgZ(0,"div",11)(1,"button",12),r._uU(2),r.ALo(3,"translate"),r.qZA(),r.TgZ(4,"button",13),r._uU(5),r.ALo(6,"translate"),r.qZA()()),2&R&&(r.xp6(1),r.Q6J("mat-dialog-close",!1),r.xp6(1),r.Oqu(r.lcZ(3,4,"sessionExpiry.no")),r.xp6(2),r.Q6J("mat-dialog-close",!0),r.xp6(1),r.Oqu(r.lcZ(6,6,"sessionExpiry.yes")))}function b(R,B){1&R&&(r.TgZ(0,"div",11)(1,"button",13),r._uU(2),r.ALo(3,"translate"),r.qZA()()),2&R&&(r.xp6(1),r.Q6J("mat-dialog-close",!1),r.xp6(1),r.Oqu(r.lcZ(3,2,"sessionExpiry.return")))}let M=class Re{constructor(B,E){this.dialogRef=B,this.data=E,this.wrapper="token-expiry-dialog",this.timerDone$=new _.x,this.isExpired=!1,this.params={}}ngOnInit(){this.params={expiry:T()(this.data.expiryDate).format("h:mm a"),redirectIn:this.data.redirectIn},(0,n.F)(1e3).pipe((0,a.t)(this),(0,i.b)(()=>{this.updateTimer()&&this.timerDone$.next(!0)}),(0,P.R)(this.timerDone$)).subscribe(),this.dialogRef.afterClosed().pipe((0,a.t)(this),(0,D.h)(B=>B)).subscribe({next:B=>this.timerDone$.next(!0)})}updateTimer(){const B=Date.parse(this.data.expiryDate),{minutes:E,seconds:m}=this.buildTimerMessage(B),p=E<=0&&m<=0;return this.isExpired=p,p}buildTimerMessage(B){const m=B-(new Date).getTime(),p=Math.floor(m%36e5/6e4),O=Math.floor(m%6e4/1e3);return this.expiryTimeMessage=`${(0,y.padStart)(String(p),2,"0")}:${(0,y.padStart)(String(O),2,"0")}`,{minutes:p,seconds:O}}static#t=this.\u0275fac=function(E){return new(E||Re)(r.Y36(e.so),r.Y36(e.WI))};static#e=this.\u0275cmp=r.Xpm({type:Re,selectors:[["token-expiry-dialog"]],hostVars:2,hostBindings:function(E,m){2&E&&r.Tol(m.wrapper)},decls:11,vars:8,consts:[["mat-dialog-title","",1,"modal-header","modal-header--border"],[1,"modal-header__inner"],[4,"ngIf"],["mat-dialog-content",""],["class","expiring","aria-live","polite",4,"ngIf"],["class","expiring",4,"ngIf"],["class","expired",4,"ngIf"],["mat-dialog-actions","","class","token-expiry-dialog__actions",4,"ngIf"],["aria-live","polite",1,"expiring"],[1,"expiring"],[1,"expired"],["mat-dialog-actions","",1,"token-expiry-dialog__actions"],["mat-flat-button","",3,"mat-dialog-close"],["mat-stroked-button","","cdkFocusInitial","",3,"mat-dialog-close"]],template:function(E,m){1&E&&(r.TgZ(0,"div",0)(1,"div",1),r.YNc(2,g,4,6,"h2",2),r.YNc(3,c,4,6,"h2",2),r.qZA()(),r.TgZ(4,"div",3),r.YNc(5,l,3,4,"div",4),r.YNc(6,d,3,3,"div",5),r.YNc(7,A,3,4,"div",6),r.YNc(8,S,3,4,"div",6),r.qZA(),r.YNc(9,v,7,8,"div",7),r.YNc(10,b,4,4,"div",7)),2&E&&(r.xp6(2),r.Q6J("ngIf",!m.isExpired),r.xp6(1),r.Q6J("ngIf",m.isExpired),r.xp6(2),r.Q6J("ngIf",!m.isExpired),r.xp6(1),r.Q6J("ngIf",!m.isExpired),r.xp6(1),r.Q6J("ngIf",m.isExpired),r.xp6(1),r.Q6J("ngIf",m.isExpired),r.xp6(1),r.Q6J("ngIf",!m.isExpired),r.xp6(1),r.Q6J("ngIf",m.isExpired))},dependencies:[u.O5,e.ZT,e.uh,e.xY,e.H8,C.lW,L.X$],styles:[".mdc-dialog__container{width:360px}.token-expiry-dialog__actions{padding:11px;justify-content:space-around;flex-flow:row wrap}.token-expiry-dialog__actions button{border-radius:20px}.token-expiry-dialog__actions .mdc-button--outlined{background-color:transparent}.is-mobile .token-expiry-dialog__actions{margin-bottom:-10px}.token-expiry-dialog .modal-header{padding:12px 24px}.token-expiry-dialog .modal-header:before{display:none}.token-expiry-dialog .modal-header__inner{display:flex;justify-content:space-between;align-items:flex-start;height:40px}.token-expiry-dialog .modal-header h2{margin:0;line-height:30px;align-self:flex-end;font-size:18px;font-weight:700;text-transform:uppercase}\n"],encapsulation:2})};M=(0,s.gn)([(0,a.c)(),(0,s.w6)("design:paramtypes",[e.so,Object])],M)},44151:(Z,K,t)=>{"use strict";t.d(K,{s:()=>m});var s=t(78645),e=t(58504),_=t(6990),n=t(26306),i=t(94664),P=t(86547),D=t(60932),I=t(99397),T=t(21631),a=t(64716),y=t(22096);const f=p=>`Tried to load Resource over XHR for ${p} times without success. Giving up`;var g=t(37398),c=t(69862),l=t(48901);var S=t(40787),v=t.n(S),b=t(72550),M=t(11070),R=t(18177),B=t(21875),E=t(65879);let m=(()=>{class p{constructor(F,H,W,tt,j){this.jwtAuthService=F,this.environmentService=H,this.storageService=W,this.twitchTokenService=tt,this.uiAuthService=j,this.refreshSubject=new s.x,this.jwtApiUrls=[]}get eventParams(){return this.storageService.eventParams}intercept(F,H){if(this.isTwitchRequestUrl(F.url))return this.interceptTwitchRequest(F,H);if(!this.isTokenRequestUrl(F.url)&&!this.isCdnRequestUrl(F.url)){this.loadJwtApiUrls();const W=this.storageService.getJWT();if((0,_.some)(this.jwtApiUrls,tt=>(0,_.startsWith)(F.url,tt.replace("{subEvent}/{organization}",""))))return(0,_.isNil)(W)&&!this.isParticipantCentre()?this.handleRequestWithoutToken(F,H):this.handleRequest(F,H,W);if(!(0,_.isNil)(W)){const tt=F.clone({headers:F.headers.set("Authorization",`Bearer ${W}`)});return H.handle(tt).pipe((0,n.K)(j=>this.handleError(j)))}}return H.handle(F)}interceptTwitchRequest(F,H){return this.twitchTokenService.getTwitchToken().pipe((0,i.w)(W=>{const tt=F.headers.set("Authorization",`Bearer ${W}`).set("Client-Id",this.environmentService.getEnvironment().twitch.clientId),j=F.clone({headers:tt});return H.handle(j)}))}ifTokenExpiredOrMissing(){return this.refreshSubject.subscribe({complete:()=>{this.refreshSubject=new s.x}}),1===this.refreshSubject.observers.length&&this.jwtAuthService.getAnonymousToken(this.eventParams).subscribe(this.refreshSubject),this.refreshSubject}updateHeader(F){const H=this.storageService.getJWT();return F.clone({headers:F.headers.set("Authorization",`Bearer ${H}`)})}loadJwtApiUrls(){if((0,_.isEmpty)(this.jwtApiUrls)){const F=this.environmentService.getEnvironment(),H=[];(0,_.forOwn)(F,(W,tt)=>{((0,_.startsWith)(tt,"api")||"raisinEndpointUrl"===tt)&&H.push(W.toString())}),this.jwtApiUrls=H}}handleRequest(F,H,W){let tt=(0,_.cloneDeep)(F);return(0,_.isNil)(W)||(tt=tt.clone({headers:tt.headers.set("Authorization",`Bearer ${W}`)})),H.handle(tt).pipe((0,g.U)(p=>{if(p.type===c.dt.Response){const O=p,F=(0,_.get)(O,"body.errors");if(!(0,_.isNil)(F)&&(0,_.some)(F,H=>(p=>{const O=(0,_.get)(p,"extensions.code");if((0,_.isNil)(O))return!1;if("2"===O)return!0;if("VALIDATION_ERROR"===O){const F=(0,_.get)(p,"extensions.number");if("authorization"===F||"2"===F)return!0}return!1})(H)))throw new c.UA({headers:O.headers,status:l.W.UNAUTHORIZED,statusText:O.statusText,url:O.url})}return p}),function L(p,O=450,F=2){let H=F;return W=>W.pipe((0,P.a)(tt=>tt.pipe((0,D.g)(O),(0,I.b)(j=>console.error(`Request failed, retrying in ${O}ms`)),(0,T.z)(j=>p&&p.find(z=>z===j.status)?(0,e._)(j):H-- >0?(0,y.of)(j):(0,e._)(((p,O)=>O?(O.message=O.message?`${p}. ${O.message}.`:p,O):new Error(p))(f(F),j))),(0,a.x)(()=>console.error(f(F))))))}([l.W.FORBIDDEN,l.W.UNAUTHORIZED,l.W.UNPROCESSABLE_ENTITY,l.W.BAD_REQUEST],void 0,this.getMaxRetriesForRequest(F)),(0,n.K)(j=>(0,_.includes)([l.W.UNPROCESSABLE_ENTITY,l.W.BAD_REQUEST],j.status)||0===this.getMaxRetriesForRequest(F)?(0,e._)(j):this.isParticipantCentre()?this.handleError(j):this.handleRequestWithoutToken(F,H)))}getMaxRetriesForRequest(F){if("post"===F.method.toLowerCase()&&-1===F.url.indexOf("/token"))return 0}handleRequestWithoutToken(F,H){return this.ifTokenExpiredOrMissing().pipe((0,i.w)(()=>H.handle(this.updateHeader(F)).pipe((0,n.K)(W=>this.handleError(W)))))}isParticipantCentre(){return`${new(v())(window.location.href).origin}`===this.environmentService.baseUrl}isTwitchRequestUrl(F){return this.environmentService.getEnvironment().twitch?.usersUrl===F}isTokenRequestUrl(F){return!(0,_.endsWith)(F,"json")&&!(0,_.endsWith)(F,"svg")&&new RegExp("(assets/jwt/token/anonymous|assets/jwt/token|ui/assets/i18n|getApiToken.js|api/authentication)").test(F)}isCdnRequestUrl(F){return new RegExp("^http(s)?://(raisincdn|raisincdn-si|).akaraisin.com/.*$").test(F)||new RegExp("^http(s)?://(raisin-si).*.s3..*.amazonaws.com/.*$").test(F)||new RegExp("^http(s)?://(clientcustomfiles).*.s3..*.amazonaws.com/.*$").test(F)||new RegExp("^http(s)?://.*.cloudfront.net/.*$").test(F)}handleError(F){return(F.status===l.W.UNAUTHORIZED||F.status===l.W.FORBIDDEN)&&(this.jwtAuthService.logOut(),this.uiAuthService.logOut()),(0,e._)(F)}static#t=this.\u0275fac=function(H){return new(H||p)(E.LFG(M.t),E.LFG(b.L$),E.LFG(B.V1),E.LFG(b.lY),E.LFG(R.E))};static#e=this.\u0275prov=E.Yz7({token:p,factory:p.\u0275fac,providedIn:"root"})}return p})()},11070:(Z,K,t)=>{"use strict";t.d(K,{t:()=>T});var s=t(65619),e=t(6990),n=t(99397),i=t(7019),P=t(21875),D=t(95809),I=t(65879);let T=(()=>{class a extends D.${constructor(f,r,u){super(),this.storageService=f,this.tokenService=r,this.jsonWebTokenParserService=u,this.loggedInStatus=new s.X(!1)}isLoggedIn(f){!this.storageService.eventParams&&!(0,e.isNil)(f)&&this.storageService.setEventParams(f);const r=this.getJWT(),u=!(0,e.isNil)(r)&&!this.isAnonymousToken();return this.loggedInStatus.next(u),u}login(f,r){return this.tokenService.getUserToken({orgId:+f.orgId,subEventCustomPart:f.subEventCustomPart,username:r.username,password:r.password,isLoggedInToFacebook:r.isLoggedIntoFacebook,reissue:r.reissue,code:r.code}).pipe((0,n.b)(C=>{this.setJwtResponseVariables(f,C,!0),this.resetCultureForNewLogin(),this.resetLanguagesForNewLogin(),this.loggedInStatus.next(!!C)}))}getAnonymousToken(f=null){return null===f&&(f=this.storageService.eventParams),this.tokenService.getAnonymousToken({orgId:+f.orgId,subEventCustomPart:f.subEventCustomPart}).pipe((0,n.b)(u=>{this.setJwtResponseVariables(f,u)}))}regenerateToken(f=null,r=!1){null===f&&(f=this.storageService.eventParams);const u={orgId:+f.orgId,subEventCustomPart:f.subEventCustomPart,token:this.storageService.getJWT()};return this.tokenService.regenerateToken(u).pipe((0,n.b)(C=>{this.setJwtResponseVariables(f,C),r&&this.storageService.setJWTDataInCookie(C)}))}logOut(){this.storageService.clear(),this.loggedInStatus.next(!1)}getJWT(){return this.storageService.getJWT()}getRoles(){return this.storageService.getRoles()}isFirstLogin(){return this.storageService.isFirstLogin()}resetCultureForNewLogin(){const f=this.storageService.getLanguages();(0,e.isNil)(f)||!Array.isArray(f)||f.forEach(r=>{this.storageService.setData("culture",r.culture,r.url)})}resetLanguagesForNewLogin(){const f=this.storageService.getLanguages();(0,e.isNil)(f)||!Array.isArray(f)||f.forEach(r=>{this.storageService.setData("language",r.culture,r.url)})}updateAuthData(f){this.storageService.updateSessionStorageFromCookie(f)}setJwtResponseVariables(f,r,u=!1){const C=(0,e.cloneDeep)(f);C.orgId=(0,e.get)(f,"orgId",`${r.organizationId}`),this.setJWT(C,r.value,u),this.storageService.setLanguage(r.culture),this.storageService.setRoles(r.roles),this.checkAndSetSubEventIdAndOrganizationId(r),this.storageService.setCulture(r.subEventId,r.culture)}checkAndSetSubEventIdAndOrganizationId(f){!(0,e.isNil)(f.subEventId)&&f.subEventId>=0&&this.storageService.setSubEventId(f.subEventId),!(0,e.isNil)(f.organizationId)&&f.organizationId>=0&&this.storageService.setOrganizationId(f.organizationId)}setJWT(f,r,u=!1){this.storageService.setEventParams(f),this.storageService.setJWT(r,u)}tokenExpired(){return this.jsonWebTokenParserService.isTokenExpired(this.getJWT())}tokenExpiryDate(){return this.jsonWebTokenParserService.getTokenExpirationDate(this.getJWT())}isAnonymousToken(){const f=this.getJWT(),r=this.jsonWebTokenParserService.parseToken(f);return(0,e.isEmpty)((0,e.get)(r,"username"))&&(0,e.isEmpty)((0,e.get)(r,"roles"))}static#t=this.\u0275fac=function(r){return new(r||a)(I.LFG(P.V1),I.LFG(i.YW),I.LFG(i.Kq))};static#e=this.\u0275prov=I.Yz7({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})()},95809:(Z,K,t)=>{"use strict";t.d(K,{$:()=>e});var s=t(65879);let e=(()=>{class _{static#t=this.\u0275fac=function(P){return new(P||_)};static#e=this.\u0275prov=s.Yz7({token:_,factory:_.\u0275fac,providedIn:"root"})}return _})()},25407:(Z,K,t)=>{"use strict";t.d(K,{W:()=>y});var s=t(78645),e=t(99080),_=t(16676),n=t.n(_),i=t(59773),P=t(21441),D=t(99397),I=t(37398),T=t(65879),a=t(95809);let y=(()=>{class f{constructor(u){this.jwtAuthService=u,this.timeToRefreshSubject$=null,this.destroy$=new s.x,this.internalTimerCheck=5}start(){const u=n()(this.jwtAuthService.tokenExpiryDate()).subtract(this.internalTimerCheck,"minutes").toDate();this.timeToRefreshSubject$=(0,e.H)(u).pipe((0,i.R)(this.destroy$),(0,P.h)(this.jwtAuthService.tokenExpired()),(0,D.b)(L=>{L&&this.destroy$.next(!0)})),console.debug("Token: Expiry is",this.jwtAuthService.tokenExpiryDate());const C=n()(this.jwtAuthService.tokenExpiryDate().getTime()).add(2,"seconds").toDate();this.tokenHasExpiredSubject$=(0,e.H)(C).pipe((0,D.b)(L=>console.debug("Token: Expired at",this.jwtAuthService.tokenExpiryDate())),(0,i.R)(this.destroy$),(0,P.h)(this.jwtAuthService.tokenExpired()),(0,D.b)(L=>{L&&this.destroy$.next(!0)}))}stop(){this.destroy$.next(!0),this.timeToRefreshSubject$=null,this.tokenHasExpiredSubject$=null}timeToRefresh(){return this.timeToRefreshSubject$}tokenHasExpired(){return this.tokenHasExpiredSubject$}setCheckTimer(u){this.internalTimerCheck!==u&&(this.internalTimerCheck=u,this.stop(),this.start())}getExpiryDate(){return this.jwtAuthService.tokenExpiryDate()}refreshToken(){return this.jwtAuthService.regenerateToken().pipe((0,I.U)(u=>(this.destroy$.next(!0),!0)))}static#t=this.\u0275fac=function(C){return new(C||f)(T.LFG(a.$))};static#e=this.\u0275prov=T.Yz7({token:f,factory:f.\u0275fac,providedIn:"root"})}return f})()},18177:(Z,K,t)=>{"use strict";t.d(K,{E:()=>n});var s=t(65879),e=t(6990);const n=new s.OlP("UI_AUTH_SERVICE",{factory:()=>({logOut:e.noop})})},43520:(Z,K,t)=>{"use strict";t.d(K,{B:()=>r});var s=t(69862),e=t(72550),_=t(7019),n=t(44151),i=t(11070),P=t(25407),D=t(89515),I=t(96814),T=t(30617),a=t(17700),y=t(32296),f=t(65879);let r=(()=>{class u{static forRoot(L){return L?{ngModule:u,providers:[P.W]}:{ngModule:u,providers:[{provide:s.TP,useClass:n.s,multi:!0},i.t,P.W]}}static#t=this.\u0275fac=function(g){return new(g||u)};static#e=this.\u0275mod=f.oAB({type:u});static#i=this.\u0275inj=f.cJS({imports:[I.ez,_.er,e.U1,D.aw,T.Ps,a.Is,y.ot]})}return u})()},7019:(Z,K,t)=>{"use strict";t.d(K,{Kq:()=>d,YW:()=>S,er:()=>_});var s=t(96814),e=t(65879);let _=(()=>{class v{static#t=this.\u0275fac=function(R){return new(R||v)};static#e=this.\u0275mod=e.oAB({type:v});static#i=this.\u0275inj=e.cJS({imports:[s.ez]})}return v})();var n=t(22096),i=t(58504),P=t(37398),D=t(26306),I=t(21875),T=t(69862);let a=(()=>{class v{get origin(){const M=window.location.origin;return-1===M.indexOf("raisinlocal.com")&&-1===M.indexOf("akaraisin.com")&&-1===M.indexOf("localhost")?"https://raisincdn-si.akaraisin.com/raisin/js/":`${M}/ui/assets/config/`}constructor(M,R){this.releaseName=M,this.http=R,this.CONFIGURATION_URL="configuration.json",this.configuration=null}loadConfig(){return null!==this.configuration?(0,n.of)(this.configuration):this.http.get(`${this.origin}${this.CONFIGURATION_URL}?v=${this.releaseName}`).pipe((0,P.U)(M=>(this.configuration=M,M)),(0,D.K)(M=>(console.error(M),(0,i._)(M))))}static#t=this.\u0275fac=function(R){return new(R||v)(e.LFG(I.ZF),e.LFG(T.eN))};static#e=this.\u0275prov=e.Yz7({token:v,factory:v.\u0275fac,providedIn:"root"})}return v})();class y{}class f extends y{}var r=t(94664);class u{constructor(b,M){this.configurationService=b,this.http=M}}class C extends u{constructor(b,M){super(b,M),this.configurationService=b,this.http=M,this.v1Token=null}getAnonymousToken(b){if(null===b.orgId)throw new Error("orgId is a required parameter.");return null!==this.v1Token?(0,n.of)(this.v1Token):this.configurationService.loadConfig().pipe((0,r.w)(M=>this.http.get(M.claimsV1Url,{params:(new T.LE).set("o",`${b.orgId}`)})),(0,P.U)(M=>(this.v1Token={value:M.token,expiryDate:M.expiryDate},this.v1Token)))}getUserToken(b){throw new Error("Method not implemented.")}regenerateToken(b){throw new Error("Method not implemented.")}refreshToken(){throw new Error("Method not implemented.")}}var c=t(6990),l=t(60703);let d=(()=>{class v{constructor(){this.jwtHelper=new l.N0}parseToken(M){const R=this.jwtHelper.decodeToken(M);return{value:M,culture:this.toCulture((0,c.toNumber)((0,c.get)(R,"LanguageId"))),firstLogin:"true"===(0,c.toLower)((0,c.get)(R,"FirstLogin")),organizationId:(0,c.toNumber)((0,c.get)(R,"OrganizationId")),roles:this.getRoles(R),subEventId:(0,c.toNumber)((0,c.get)(R,"SubEventId")),userId:(0,c.toNumber)((0,c.get)(R,"UserId")),username:(0,c.toString)((0,c.get)(R,"Username"))}}getTokenExpirationDate(M){return this.jwtHelper.getTokenExpirationDate(M)}isTokenExpired(M){return this.jwtHelper.isTokenExpired(M)}toCulture(M){switch(M){case 1:return"en-CA";case 2:return"fr-CA";case 3:return"es-ES";case 4:return"de-CH";case 5:return"en-US";default:return null}}getRoles(M){let R;const B=(0,c.findKey)(M,(m,p)=>p.includes("/claims/role")),E=B?(0,c.get)(M,B):null;return(0,c.isEmpty)(E)?R=[]:(0,c.isString)(E)?R=[this.toRole(E)]:(0,c.isArray)(E)?R=(0,c.map)(E,m=>this.toRole(m)):(console.warn(`JWT token roles '${E}' could not be parsed to ROLE enum.`),R=[]),R=(0,c.filter)(R,m=>!(0,c.isEmpty)(m)),R}toRole(M){const R=(0,c.findKey)(I.HB,B=>(0,c.toString)(B)===(0,c.toString)(M));return R?I.HB[R]:null}static#t=this.\u0275fac=function(R){return new(R||v)};static#e=this.\u0275prov=e.Yz7({token:v,factory:v.\u0275fac,providedIn:"root"})}return v})();class A extends u{constructor(b,M){super(b,M),this.configurationService=b,this.http=M,this.jwt=null,this.jsonWebTokenParserService=new d}getAnonymousToken(b){if(null===b.subEventCustomPart)throw new Error("subEventCustomPart is a required parameter.");return null!==this.jwt?(0,n.of)(this.jwt):this.configurationService.loadConfig().pipe((0,r.w)(M=>this.http.post(M.anonymousClaimsUrl,{organizationId:(0,c.toInteger)(b.orgId),subEventCustomPart:(0,c.toString)(b.subEventCustomPart),hostname:(0,c.toString)(window.location.hostname)},{headers:(new T.WM).set("content-type","application/json"),responseType:"text"})),(0,P.U)(M=>(this.jwt=this.jsonWebTokenParserService.parseToken(M),this.jwt)))}getUserToken(b){if(null===b.subEventCustomPart)throw new Error("subEventCustomPart is a required parameter.");if(null!==this.jwt&&this.jwt.roles.includes(I.HB.INDIVIDUAL))return(0,n.of)(this.jwt);const M=b.isLoggedInToFacebook?{socialLoginToken:b.connectionToken,organizationId:b.orgId,subEventCustomPart:b.subEventCustomPart}:{username:b.username,password:b.password,subEventCustomPart:b.subEventCustomPart};return this.configurationService.loadConfig().pipe((0,r.w)(R=>this.http.post(R.claimsUrl,M,{headers:(new T.WM).set("content-type","application/json"),responseType:"text"})),(0,P.U)(R=>(this.jwt=this.jsonWebTokenParserService.parseToken(R),this.jwt)))}regenerateToken(b){return this.configurationService.loadConfig().pipe((0,r.w)(M=>this.http.post(M.regenerateClaimsUrl,null,{headers:(new T.WM).set("content-type","application/json").set("Authorization",`Bearer ${b.token}`),responseType:"text"})),(0,P.U)(M=>(this.jwt=this.jsonWebTokenParserService.parseToken(M),this.jwt)))}refreshToken(){throw new Error("Method not implemented.")}}let S=(()=>{class v{constructor(M,R){this.configurationService=M,this.http=R}getAnonymousToken(M,R){return this.createService(R).getAnonymousToken(M)}getUserToken(M,R){return this.createService(R).getUserToken(M)}regenerateToken(M,R){return this.createService(R).regenerateToken(M)}refreshToken(M){return this.createService(M).refreshToken()}createService(M){let R;return R=this.createInstance(M===f?C:A),R}createInstance(M){return new M(this.configurationService,this.http)}static#t=this.\u0275fac=function(R){return new(R||v)(e.LFG(a),e.LFG(T.eN))};static#e=this.\u0275prov=e.Yz7({token:v,factory:v.\u0275fac,providedIn:"root"})}return v})()},46700:(Z,K,t)=>{var s={"./af":83274,"./af.js":83274,"./ar":22097,"./ar-dz":61867,"./ar-dz.js":61867,"./ar-kw":17078,"./ar-kw.js":17078,"./ar-ly":77776,"./ar-ly.js":77776,"./ar-ma":56789,"./ar-ma.js":56789,"./ar-ps":73807,"./ar-ps.js":73807,"./ar-sa":6897,"./ar-sa.js":6897,"./ar-tn":71585,"./ar-tn.js":71585,"./ar.js":22097,"./az":15611,"./az.js":15611,"./be":62459,"./be.js":62459,"./bg":91825,"./bg.js":91825,"./bm":75918,"./bm.js":75918,"./bn":34065,"./bn-bd":49683,"./bn-bd.js":49683,"./bn.js":34065,"./bo":11034,"./bo.js":11034,"./br":27671,"./br.js":27671,"./bs":38153,"./bs.js":38153,"./ca":54287,"./ca.js":54287,"./cs":72616,"./cs.js":72616,"./cv":27049,"./cv.js":27049,"./cy":99172,"./cy.js":99172,"./da":20605,"./da.js":20605,"./de":94013,"./de-at":93395,"./de-at.js":93395,"./de-ch":99835,"./de-ch.js":99835,"./de.js":94013,"./dv":14570,"./dv.js":14570,"./el":31859,"./el.js":31859,"./en-au":55785,"./en-au.js":55785,"./en-ca":83792,"./en-ca.js":83792,"./en-gb":57651,"./en-gb.js":57651,"./en-ie":81929,"./en-ie.js":81929,"./en-il":19818,"./en-il.js":19818,"./en-in":6612,"./en-in.js":6612,"./en-nz":24900,"./en-nz.js":24900,"./en-sg":72721,"./en-sg.js":72721,"./eo":95159,"./eo.js":95159,"./es":21954,"./es-do":11780,"./es-do.js":11780,"./es-mx":23468,"./es-mx.js":23468,"./es-us":44938,"./es-us.js":44938,"./es.js":21954,"./et":11453,"./et.js":11453,"./eu":44697,"./eu.js":44697,"./fa":52900,"./fa.js":52900,"./fi":49775,"./fi.js":49775,"./fil":64282,"./fil.js":64282,"./fo":84236,"./fo.js":84236,"./fr":89361,"./fr-ca":92830,"./fr-ca.js":92830,"./fr-ch":21412,"./fr-ch.js":21412,"./fr.js":89361,"./fy":66984,"./fy.js":66984,"./ga":93961,"./ga.js":93961,"./gd":78849,"./gd.js":78849,"./gl":34273,"./gl.js":34273,"./gom-deva":40623,"./gom-deva.js":40623,"./gom-latn":62696,"./gom-latn.js":62696,"./gu":66928,"./gu.js":66928,"./he":24804,"./he.js":24804,"./hi":23015,"./hi.js":23015,"./hr":17134,"./hr.js":17134,"./hu":50670,"./hu.js":50670,"./hy-am":4523,"./hy-am.js":4523,"./id":99233,"./id.js":99233,"./is":94693,"./is.js":94693,"./it":63936,"./it-ch":78118,"./it-ch.js":78118,"./it.js":63936,"./ja":86871,"./ja.js":86871,"./jv":68710,"./jv.js":68710,"./ka":17125,"./ka.js":17125,"./kk":82461,"./kk.js":82461,"./km":77399,"./km.js":77399,"./kn":38720,"./kn.js":38720,"./ko":85306,"./ko.js":85306,"./ku":82995,"./ku-kmr":64852,"./ku-kmr.js":64852,"./ku.js":82995,"./ky":8779,"./ky.js":8779,"./lb":62057,"./lb.js":62057,"./lo":17192,"./lo.js":17192,"./lt":15430,"./lt.js":15430,"./lv":53363,"./lv.js":53363,"./me":72939,"./me.js":72939,"./mi":38212,"./mi.js":38212,"./mk":69718,"./mk.js":69718,"./ml":50561,"./ml.js":50561,"./mn":68929,"./mn.js":68929,"./mr":84880,"./mr.js":84880,"./ms":63193,"./ms-my":42074,"./ms-my.js":42074,"./ms.js":63193,"./mt":54082,"./mt.js":54082,"./my":82261,"./my.js":82261,"./nb":15273,"./nb.js":15273,"./ne":19874,"./ne.js":19874,"./nl":51667,"./nl-be":81484,"./nl-be.js":81484,"./nl.js":51667,"./nn":17262,"./nn.js":17262,"./oc-lnc":19679,"./oc-lnc.js":19679,"./pa-in":96830,"./pa-in.js":96830,"./pl":93616,"./pl.js":93616,"./pt":55138,"./pt-br":32751,"./pt-br.js":32751,"./pt.js":55138,"./ro":17968,"./ro.js":17968,"./ru":81828,"./ru.js":81828,"./sd":62188,"./sd.js":62188,"./se":6562,"./se.js":6562,"./si":87172,"./si.js":87172,"./sk":99966,"./sk.js":99966,"./sl":4287,"./sl.js":4287,"./sq":15291,"./sq.js":15291,"./sr":80450,"./sr-cyrl":37603,"./sr-cyrl.js":37603,"./sr.js":80450,"./ss":30383,"./ss.js":30383,"./sv":37221,"./sv.js":37221,"./sw":51743,"./sw.js":51743,"./ta":6351,"./ta.js":6351,"./te":98118,"./te.js":98118,"./tet":26278,"./tet.js":26278,"./tg":36987,"./tg.js":36987,"./th":39325,"./th.js":39325,"./tk":43485,"./tk.js":43485,"./tl-ph":68148,"./tl-ph.js":68148,"./tlh":59616,"./tlh.js":59616,"./tr":24040,"./tr.js":24040,"./tzl":594,"./tzl.js":594,"./tzm":80673,"./tzm-latn":23226,"./tzm-latn.js":23226,"./tzm.js":80673,"./ug-cn":69580,"./ug-cn.js":69580,"./uk":87270,"./uk.js":87270,"./ur":11656,"./ur.js":11656,"./uz":68364,"./uz-latn":18744,"./uz-latn.js":18744,"./uz.js":68364,"./vi":75049,"./vi.js":75049,"./x-pseudo":15106,"./x-pseudo.js":15106,"./yo":6199,"./yo.js":6199,"./zh-cn":27280,"./zh-cn.js":27280,"./zh-hk":36860,"./zh-hk.js":36860,"./zh-mo":78364,"./zh-mo.js":78364,"./zh-tw":482,"./zh-tw.js":482};function e(n){var i=_(n);return t(i)}function _(n){if(!t.o(s,n)){var i=new Error("Cannot find module '"+n+"'");throw i.code="MODULE_NOT_FOUND",i}return s[n]}e.keys=function(){return Object.keys(s)},e.resolve=_,Z.exports=e,e.id=46700}},Z=>{Z.O(0,[736],()=>Z(Z.s=77362)),Z.O()}]);