PageSourceSearch

https://theright.fit/1583.b401afd2019069ae.js

js theright.fit collected 2026-09-24 11:53:10 UTC 27,845 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunktrf_frontend=self.webpackChunktrf_frontend||[]).push([[1583],{4076(e,t,n){n.d(t,{A:()=>a});n(96540);var s=n(74848);const a=({title:e,subtitle:t,jobTitle:n,backUrl:a,children:i,classes:o})=>(0,s.jsx)("div",{className:`trf-header ${o||""}`,children:(0,s.jsx)("div",{className:"trf-header__inner",children:(0,s.jsxs)("div",{className:"trf-header__body align-items-start align-items-sm-center flex-column flex-sm-row",children:[(0,s.jsxs)("div",{className:"trf-header__content",children:[(0,s.jsx)("h2",{className:"trf-header__title",children:e}),(t||n)&&(0,s.jsxs)("span",{className:"trf-header__subtitle",children:[t,n&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("br",{}),n]})]})]}),(0,s.jsx)("div",{className:"trf-header__actions mt-3 mt-sm-0",children:i})]})})})},55668(e,t,n){n.d(t,{k:()=>s.A});var s=n(4076)},65315(e,t,n){n.d(t,{A:()=>r});n(96540);var s=n(3433),a=n(32485),i=n.n(a),o=n(74848);const r=({title:e,subtitle:t,backLink:n,className:a})=>{const r=(0,s.Zp)();return(0,o.jsxs)("div",{className:i()("column-content__header",a),children:[(0,o.jsx)("div",{className:"column-content__back",onClick:()=>{n&&r(n)},children:(0,o.jsx)("i",{className:"fa fa-angle-left","aria-hidden":"true"})}),(0,o.jsx)("h3",{className:"column-content__title",children:e}),(0,o.jsx)("span",{className:"column-content__subtitle",children:t})]})}},62977(e,t,n){n.r(t),n.d(t,{default:()=>c});var s=n(96540),a=n(55668),i=n(61597),o=n(27043),r=n(65315),l=n(74848);const c=()=>{const[e,t]=s.useState(!1);return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(a.k,{classes:"bg-transparent",title:"Settings",subtitle:""}),(0,l.jsx)("div",{className:"main-column",children:(0,l.jsx)("div",{className:"main-column__inner mt-0 profile-setting-social-connect",children:(0,l.jsx)("div",{className:"column-content profile-setting-column-content",children:(0,l.jsx)(o.A,{loading:e,children:(0,l.jsxs)("div",{className:"column-content__inner",children:[(0,l.jsx)(r.A,{title:"Connect Social Accounts",subtitle:"Link your social media profiles so your follower count can stay updated & visible to clients",backLink:"/talent/account/profile-settings"}),(0,l.jsx)("div",{className:"column-content__body",children:(0,l.jsx)(i.A,{isAccountSetting:!0,setIsLoading:t})})]})})})})})]})}},76512(e,t,n){n.d(t,{CA:()=>d,IW:()=>c,WU:()=>l,YK:()=>u,cq:()=>o,gk:()=>r,iV:()=>m,yU:()=>g});var s=n(64476),a=n(49873),i=n(1210);const o=async e=>{const t=(new TextEncoder).encode(e),n=await crypto.subtle.digest("SHA-256",t);return Array.from(new Uint8Array(n)).map(e=>e.toString(16).padStart(2,"0")).join("")},r=e=>({first_name:e.firstName||"",last_name:e.lastName||"",gender_id:e.gender||"",dob:(0,a.A)(e.dob||new Date,"dd-MM-yyyy"),country_id:e.country||"",state_id:e.state||"",provider:"password",bio:"",display_name:"",covid_vaccination:"yes"}),l=e=>({professions:e.professions||[],tags:e.tags||[],from:e.isAccountSetting?"settings":"onboarding"}),c=e=>({avator_image:e.avatar}),d=e=>{const t={};return e.firstName||(t.firstName=i.ERRORS_MAP.required),e.lastName||(t.lastName=i.ERRORS_MAP.required),e.gender||(t.gender=i.ERRORS_MAP.required),e.dob||(t.dob=i.ERRORS_MAP.required),e.dob&&(0,s.A)(new Date,e.dob)<18&&(t.dob="You must be at least 18 years old to register as a creator."),e.country||(t.country=i.ERRORS_MAP.required),e.state||(t.state=i.ERRORS_MAP.required),t},u=e=>{var t,n;const s={};var a,o;(null!=(t=e.professions)&&t.length||(s.professions=i.ERRORS_MAP.select),null!=(n=e.professions)&&n.includes("250ff7a0-ec1c-4154-a4ee-b18213975da2"))&&(null!=(a=e.tags)&&a.length||(s.tags=i.ERRORS_MAP.required),null!=(o=e.tags)&&o.length&&e.tags.length>4&&(s.tags=i.ERRORS_MAP.max));return s},m=e=>{const t={};return e.length||(t.socials=i.ERRORS_MAP.social),t},g=async e=>{const t={};if(e.avatar||(t.avatar=i.ERRORS_MAP.required,t.upload=i.ERRORS_MAP.image),e.avatar instanceof File){const n=new Image,s=await new Promise(t=>{n.src=URL.createObjectURL(e.avatar),n.onload=()=>{t({width:n.width,height:n.height})}});if(URL.revokeObjectURL(n.src),e.avatar.size>1e7){const e="Photo cannot be larger than 10MB";t.avatar=e,t.upload=e}if(s.width<=300||s.height<=300){const e=`Photo must be more than 300 by 300 pixels in size. This image is ${s.width}x${s.height} pixels`;t.avatar=e,t.upload=e}}return t}},61597(e,t,n){n.d(t,{A:()=>pe});var s,a=n(96540),i=n(2543),o=n(20225),r=n(28454),l=n(3433),c=n(61409),d=n(49394),u=n(94580),m=n(51990),g=n(49376),h=n(71468),v=n(68566),p=n(76512),f=n(13838),j=n(32485),b=n.n(j),_=n(27043),x=n(1210),y=n(95695);function w(){return w=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var s in n)({}).hasOwnProperty.call(n,s)&&(e[s]=n[s])}return e},w.apply(null,arguments)}var S=function(e){return a.createElement("svg",w({xmlns:"http://www.w3.org/2000/svg",width:18,height:18,fill:"none",viewBox:"0 0 18 18"},e),s||(s=a.createElement("path",{fill:"#44B07B",fillRule:"evenodd",d:"M9 18A9 9 0 1 0 9 0a9 9 0 0 0 0 18m4.28-11.78a.75.75 0 0 1 0 1.06l-5.25 5.25a.75.75 0 0 1-1.06 0l-3-3a.75.75 0 0 1 1.06-1.06l2.47 2.47 4.72-4.72a.75.75 0 0 1 1.06 0",clipRule:"evenodd"})))};n.p;var N;function C(){return C=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var s in n)({}).hasOwnProperty.call(n,s)&&(e[s]=n[s])}return e},C.apply(null,arguments)}var A=function(e){return a.createElement("svg",C({xmlns:"http://www.w3.org/2000/svg",width:24,height:24,fill:"none",viewBox:"0 0 24 24"},e),N||(N=a.createElement("path",{fill:"#0A144E",fillRule:"evenodd",d:"M12 24c6.627 0 12-5.373 12-12S18.627 0 12 0 0 5.373 0 12s5.373 12 12 12M8.707 7.293a1 1 0 0 0-1.414 1.414L10.586 12l-3.293 3.293a1 1 0 1 0 1.414 1.414L12 13.414l3.293 3.293a1 1 0 0 0 1.414-1.414L13.414 12l3.293-3.293a1 1 0 0 0-1.414-1.414L12 10.586z",clipRule:"evenodd"})))};n.p;var O=n(8121),k=n(74848);const R=({userPermissions:e,isResticted:t})=>(0,k.jsxs)("div",{className:"eligibilityTypeWrapper",children:[(0,k.jsx)("div",{className:"eligibilityTypeContentWrapper",children:(0,k.jsxs)("div",{className:"eligibilityTypeContent",children:[(0,k.jsx)("div",{className:"mb-3",children:(0,k.jsx)(f.o5,{variant:"title6",weight:"500",color:"grey-9",label:"Which types of campaigns are you eligible to apply for?"})}),(0,k.jsxs)("div",{children:[(0,k.jsx)(f.o5,{weight:"400",color:"grey-9",label:"These are the campaigns you\u2019re eligible to apply for, based on your connected social accounts. Your eligibility is refreshed every 24 hours."}),(0,k.jsxs)("div",{className:"mt-2",children:[(0,k.jsx)(f.o5,{variant:"label",weight:"400",color:"grey-9",label:"Something wrong with your eligibility? ",className:"mt-3"}),(0,k.jsx)("a",{href:"https://theright.fit/contact",target:"_blank",rel:"noreferrer",className:"customer-support-link",children:(0,k.jsx)(f.o5,{variant:"label",weight:"400",color:"Brand-Tertiary",label:"Contact customer support.",className:"mt-3"})})]})]})]})}),t&&(0,k.jsx)("div",{children:(0,k.jsx)(O.A,{textOne:"Your account has been restricted. ",textTwo:"Please contact customer support for further details.",hideClose:!0,textClick:()=>window.open("https://theright.fit/contact","_blank"),className:"restrict-user-banner"})}),(0,k.jsx)("div",{className:"eligibleTypeOptionsWrapper",children:[{key:"ugc_opportunities_enabled",activeLabel:"UGC campaigns unlocked \ud83c\udf1f",inactiveLabel:"UGC campaigns"},{key:"influencer_opportunities_enabled",activeLabel:"Influencer campaigns unlocked \ud83d\ude80",inactiveLabel:"Influencer campaigns"}].map(({key:n,activeLabel:s,inactiveLabel:a})=>{const i=e[n]&&!t;return(0,k.jsxs)("div",{className:"eligibleTypeOption "+(i?"active":"deactive"),children:[(0,k.jsx)(f.o5,{variant:"title6",weight:"400",color:"grey-9",label:i?s:a}),i?(0,k.jsx)(S,{height:40,width:40}):(0,k.jsx)(A,{className:"crossCircleIcon",height:40,width:40})]},n)})})]}),P="__NZa4dk",M="__RXGMfu",E="__u9xwyH",F="__uOfaQK",L="__wmUE9v",I="___Hrbq2",V="__f3XG4w",T="__h6CyAx",q="__L2SYfn",$="__i8voqt",U="__kWYf0G",B="__wd9rbg",Y="__ZWKRmy",G="__uUjXAt",W="__N2tGf5",D="__k62Pi2",H=n.p+"Social-connect.41fb43
1cc27546679.png",z="__IkMY8Q",K="__Omu2MH",Z="__dVkVbE",Q="__KT8BTU",J="__g_5It6",X="__UjO6np",ee=()=>(0,k.jsxs)("div",{className:z,children:[(0,k.jsx)("div",{className:K,children:(0,k.jsx)("img",{src:H,alt:"social connect"})}),(0,k.jsxs)("div",{className:Z,children:[(0,k.jsx)("div",{children:(0,k.jsx)(f.o5,{variant:"title6",weight:"500",color:"brand-information",label:"Enjoy Amazing Benefits by Connecting Your Social Media Accounts!",className:Q})}),(0,k.jsxs)("div",{className:J,children:[(0,k.jsxs)("div",{className:X,children:[(0,k.jsx)(f.o5,{weight:"600",color:"grey-9",label:"Showcase your profile"}),(0,k.jsx)(f.o5,{weight:"400",color:"grey-9",label:"Let clients see you in their search."})]}),(0,k.jsxs)("div",{className:X,children:[(0,k.jsx)(f.o5,{weight:"600",color:"grey-9",label:"Job Applications"}),(0,k.jsx)(f.o5,{weight:"400",color:"grey-9",label:"Easily apply for jobs that match your follower count."})]}),(0,k.jsxs)("div",{className:X,children:[(0,k.jsx)(f.o5,{weight:"600",color:"grey-9",label:"Analytics"}),(0,k.jsx)(f.o5,{weight:"400",color:"grey-9",label:"Gain detailed insights into your social media performance and showcase your analytics to potential clients."})]})]})]})]});var te=n(49785);const ne="__TMP1VA",se="__xYomrr",ae="__LfT6Mw",ie="__s_otEQ",oe="__jGmOK5",re="__HyWQBc",le="__zzVmtN",ce="__Dg2BKM",de=({isOTPStep:e,instagramFlow:t,instagramVerifyMutation:n,instagramOtpMutation:s,setState:i,handleManuallyVerify:o,handleResendOtp:r})=>{const[l,c]=(0,a.useState)(!1),[d,u]=(0,a.useState)("initial"),[m,g]=(0,a.useState)(!1),[h,v]=(0,a.useState)("");(0,a.useEffect)(()=>{"otp"===(null==t?void 0:t.step)&&v(t.message||"")},[t]);const{register:p,handleSubmit:j,setValue:b,getValues:_,formState:{errors:x}}=(0,te.mN)({defaultValues:{otp:["","","",""]}}),[y,w]=(0,a.useState)(90),S=(0,a.useRef)(null),N=()=>{S.current=window.setInterval(()=>{w(e=>e-1)},1e3)};(0,a.useEffect)(()=>{0===y&&S.current&&(clearInterval(S.current),u("resend"),w(90))},[y]),(0,a.useEffect)(()=>()=>{S.current&&clearInterval(S.current)},[]),(0,a.useEffect)(()=>{const e=_("otp");g(e.every(e=>""!==e))},[_]);return(0,k.jsx)(f.aF,{show:e,contentClassName:ne,children:(0,k.jsxs)("form",{onSubmit:j(e=>{null==n||n.mutate(e.otp.join(""))}),children:[(0,k.jsxs)("div",{children:[(0,k.jsx)("div",{children:(0,k.jsx)(f.o5,{family:"calluna",variant:"title3",label:"Verification"})}),(0,k.jsx)("div",{children:(()=>{if(h&&h.includes("email")){const e=h.split("email"),t=e[1].split(").");return(0,k.jsxs)("div",{className:se,children:[e[0],(0,k.jsxs)("span",{children:[" ",`email ${t[0]}).`]})," ",t[1]]})}return h})()})]}),(0,k.jsx)("div",{className:ae,children:(0,k.jsxs)("div",{className:ie,children:[(0,k.jsx)(f.o5,{variant:"overline1",label:"One-time Password"}),(0,k.jsx)("div",{className:oe,children:Array.from({length:4},(e,t)=>{var n;return(0,k.jsx)("div",{children:(0,k.jsx)("input",Object.assign({id:`otp_${t}`,className:""+(null!=x&&null!=(n=x.otp)&&n[t]||l?"invalid":""),type:"text",maxLength:1,inputMode:"numeric",onInput:e=>((e,t)=>{const n=e.target.value,s=_("otp");if(/^\d$/.test(n)){if(""!==s[t]&&""!==n)return void b(`otp.${t}`,"");if(b(`otp.${t}`,n),c(!1),n&&t<3){const e=document.getElementById(`otp_${t+1}`);e&&e.focus()}}else b(`otp.${t}`,"");const a=_("otp");g(a.every(e=>""!==e))})(e,t),onPaste:e=>((e,t)=>{e.preventDefault();const n=e.clipboardData.getData("text").split("").slice(0,4);for(let a=0;a<n.length;a++)/^\d$/.test(n[a])&&b(`otp.${t+a}`,n[a]);const s=_("otp");g(s.every(e=>""!==e))})(e,t)},p(`otp.${t}`,{required:"This field is required"})))},t)})})]})}),"initial"===d?(0,k.jsx)("div",{children:(0,k.jsxs)("div",{className:re,children:["Haven\u2019t received the email?"," ",(0,k.jsx)("span",{onClick:()=>{r(),u("timer"),N()},children:"Resend"}),(0,k.jsx)("br",{})," Or ",(0,k.jsx)("span",{onClick:o,children:"manually verify"})," by contacting our support team."]})}):"timer"===d?(0,k.jsx)("div",{children:(0,k.jsxs)("div",{className:re,children:["Your one-time password has been sent. Next could be sent",(0,k.jsx)("br",{})," after ",(0,k.jsx)("span",{children:(e=>{const t=e%60;return`${Math.floor(e/60)}:${t<10?"0":""}${t} minutes`})(y)}),(0,k.jsx)("br",{})," Or ",(0,k.jsx)("span",{onClick:o,children:"manually verify"})," by contacting our support team."]})}):(0,k.jsx)("div",{children:(0,k.jsxs)("div",{className:re,children:[(0,k.jsx)("span",{onClick:()=>{r(),u("timer"),N()},children:"Resend one-time password"}),(0,k.jsx)("br",{})," Or"," ",(0,k.jsxs)("span",{className:`${null!=s&&s.isPending?le:""}`,onClick:o,children:[" ","manually verify."]})," ","by contacting our support team."]})}),l&&(0,k.jsx)("p",{className:"invalid-feedback mt-2 mb-0",children:"Verification Code is invali
1d"}),(0,k.jsx)("div",{className:"d-block text-center",children:(0,k.jsx)(f.$n,{theme:"primary",label:"Verify",className:ce,disabled:!m||(null==n?void 0:n.isPending),isLoading:null==n?void 0:n.isPending})})]})})},ue=n.p+"ugc-jobs-banner.1191b21a4a081431.png",me=n.p+"Influencer-jobs-banner.1ae7232c76a540b8.png",ge={SocialConnectMain:"__uX39HJ",HeaderTitle:"__CYMfQz",SocialConnectRight:"__DGmO4_",benefitsCard:"__EdZ1R8",influencerBenefitsCard:"__igiq2b",benefitsImageWrapper:"__xNZ9nR",benefitsHeader:"__yZeME5",benefitsBody:"__auzDJs"},he=({isAccountSetting:e})=>{const t=[{title:"UGC Campaigns \ud83c\udf1f",followersRequirement:"Connect an account with at least 200 followers",benefits:["Apply to UGC campaigns","Access to creator tools"],imageSrc:ue,reverse:!1},{title:"Influencer Campaigns \ud83d\ude80",followersRequirement:"Connect an account with more than 1K followers",benefits:["Apply to Influencer and UGC campaigns","Priority profile visibility","Access to creator tools"],imageSrc:me,reverse:!1}];return(0,k.jsxs)("div",{className:ge.SocialConnectMain,children:[(0,k.jsx)("div",{className:"pl-0 pt-2",children:(0,k.jsx)(f.o5,{variant:"title6",weight:"500",color:"grey-9",label:"Connect at least one social account to access influencer and UGC campaigns!",className:ge.HeaderTitle})}),(0,k.jsx)("div",{className:ge.SocialConnectRight,children:t.map((e,t)=>(0,k.jsxs)("div",{className:`${ge.benefitsCard} ${e.reverse?ge.influencerBenefitsCard:ge.ugcBenefitsCard}`,children:[!e.reverse&&(0,k.jsx)("div",{className:ge.benefitsImageWrapper,children:(0,k.jsx)("img",{src:e.imageSrc,alt:"social connect"})}),(0,k.jsxs)("div",{className:ge.benefitsHeader,children:[(0,k.jsx)(f.o5,{variant:"title6",weight:"500",color:"grey-9",label:e.title}),(0,k.jsxs)("div",{className:ge.benefitsBody,children:[(0,k.jsx)(f.o5,{weight:"600",color:"grey-9",label:e.followersRequirement}),(0,k.jsx)("ul",{className:"mt-2",children:e.benefits.map((e,t)=>(0,k.jsx)("li",{children:(0,k.jsx)(f.o5,{weight:"400",color:"grey-9",label:e})},t))})]})]}),e.reverse&&(0,k.jsx)("div",{className:ge.benefitsImageWrapper,children:(0,k.jsx)("img",{src:e.imageSrc,alt:"social connect"})})]},t))}),(0,k.jsx)(f.o5,{variant:"title6",weight:"500",color:"grey-9",label:"Still working on building your following? Don\u2019t worry, you can still access the creator tools."})]})};function ve(e){var t,n,s,i,o,l,v,p,j,w,S,N;const C=null==(t=e.state)?void 0:t.instagramFlow,A="username"===(null==C?void 0:C.step),O="otp"===(null==C?void 0:C.step),H="instruction"===(null==C?void 0:C.step),z="manually"===(null==C?void 0:C.step),K="limitExceed"===(null==C?void 0:C.step),Z=(0,h.wA)(),Q=(0,d.IF)(e=>e.talentData.isManualyVerified),J=(0,h.d4)(e=>e.userDetail.data),X=null==J||null==(n=J.professions)?void 0:n.includes("Creator"),te=(null==J?void 0:J.permissions)||{};(0,a.useEffect)(()=>{(H||z||K)&&(null==e.setInstaValidation||e.setInstaValidation(!1))},[H,z,K]);const ne=(0,r.n)({mutationFn:({data:e,type:t})=>"otp"===t?(0,u.pI)(e):(0,u.cw)(e),onSuccess:async(t,{type:n})=>{"manually"===n&&Z((0,g.kO)(!0)),null==e.setState||e.setState(e=>Object.assign({},e,{instagramFlow:Object.assign({},e.instagramFlow,{step:n,message:t.message,error:void 0})}))},onError:t=>{null==e||null==e.setState||e.setState(e=>Object.assign({},e,{instagramFlow:Object.assign({},e.instagramFlow,422===t._status&&{step:"limitExceed"},{error:t._errors})})),c.oR.error(t.message)}}),se=()=>{null==ne||ne.mutate({data:(null==C?void 0:C.username)||"",type:"manually"})};return(0,k.jsx)("div",{children:(0,k.jsxs)("div",{className:P,children:[(0,k.jsx)(_.A,{loading:!e.isAccountSetting&&e.isLoading,children:(0,k.jsxs)("div",{className:M,children:[!e.isAccountSetting&&(0,k.jsx)("div",{className:E,children:(0,k.jsx)("div",{className:F,children:(0,k.jsx)(f.o5,{family:"calluna",variant:"title3",label:"Connect your socials"})})}),(0,k.jsxs)("div",{className:b()(L,e.isAccountSetting&&I),children:[(0,k.jsx)(f.oV,{platform:"instagram",error:(0,x.toErrorString)(null==(s=e.state)?void 0:s.errors,["socials"]),connected:!(null!=(i=e.state)&&i.instructionsSend||Q)&&(null==e.getPlatformConnectionStatus?void 0:e.getPlatformConnectionStatus("instagram")),disabled:(null==(o=e.state)?void 0:o.instructionsSend)||Q,onConnect:()=>null==e.setState?void 0:e.setState(e=>Object.assign({},e,{instagramFlow:Object.assign({},e.instagramFlow,{step:"username"})})),onDisconnect:()=>{var t;return null==(t=e.removeSocialAccountMutation)?void 0:t.mutate("instagram")},className:e.isAccountSetting?T:V}),((null==(l=e.state)?void 0:l.instructionsSend)||Q)&&(0,k.jsx)("div",{className:Y,children:(0,k.jsx)(f.o5,{weight:500,color:"brand-information",variant:"label",label:"We\u2019ve sent instructions to your email to complete the connection. "+(e.isAccountSetting?"":"You can proceed to the next step now and finish the connection later.")})}),(0,k.jsx)(f.oV,{platform:"tiktok",error:(0,x.toErrorString)(null==(v=e.state)?void 0:v.errors,["socials"]),connected:null==e.getPlatformConnectionStatus?void 0:e.getPlatformConnectionStatus("tiktok"),isLoading:null==(p=e.tiktokConnectMutation)?void 0:p.isPending,onConnect:e.onConnectTikTok,onDisconnect:()=>{var t;return null==(t=e.removeSocialAccountMutation)?void 0:t.mutate("tiktok")},className:e.isAccountSetting?T:V}),(0,k.jsx)(f.oV,{platform:"youtube",error:(0,x.toErrorString)(null==(j=e.state)?void 0:j.errors,["socials"]),connected:null==e.getPlatformConnectionStatus?void 0:e.getPlatformConnectionStatus("youtube"),isLoading:null==(w=e.youtubeConnectMutation)?void 0:w.isPending,onConnect:e.onConnectYoutube,onDisconnect:()=>{var t;return null==(t=e.removeSocialAccountMutation)?void 0:t.mutate("youtube")},className:e.isAccountSetting?T:V}),!!(0,x.toErrorString)(null==(S=e.state)?void 0:S.errors,["socials"])&&(0,k.jsx)(f.eK,{label:(0,x.toErrorString)(null==(N=e.state)?void 0:N.errors,["socials"])||"",isError:!0})]}),(null==J?void 0:J.professions.length)>0&&(0,k.jsx)("div",{children:X?(0,k.jsxs)("div",{className:"px-3",children:[e.isAccountSetting?(0,k.jsx)(R,{userPermissions:te,isResticted:null==J?void 0:J.restrict}):"",(0,k.jsx)(he,{isAccountSetting:!0})]}):(0,k.jsx)(ee,{})}),!e.isAccountSetting&&(0,m.q9)((0,k.jsx)("div",{className:y.A.actionsList,children:(0,k.jsx)(f.$n,{theme:"primary",label:"Next",disabled:e.isLoading||e.isSaving,isLoading:e.isSaving,className:y.A.actionsListItem,onClick:e.onSaveOrNext})}))]})}),(0,k.jsx)(f.aF,{show:!!A,onClickOutside:()=>null==e.setState?void 0:e.setState(e=>Object.assign({},e,{instagramFlow:{step:null}})),children:(0,k.jsx)(f.fI,{children:(0,k.jsxs)(f.fv,{className:q,children:[!(null==C||!C.message)&&(0,k.jsx)(f.o5,{variant:"label",weight:"500",label:null==C?void 0:C.message}),!H&&(0,k.jsx)(f.fI,{children:(0,k.jsxs)(f.fv,{style:{rowGap:16},children:[(0,k.jsx)(f.ZQ,{value:A?null==C?void 0:C.username:O?null==C?void 0:C.otp:"",label:A?"Enter Instagram username":O?"Enter Instagram otp":"",error:(0,x.toErrorString)(null==C?void 0:C.error,["username","code"]),onChangeText:(t,n)=>null==e.setState?void 0:e.setState(e=>Object.assign({},e,{instagramFlow:Object.assign({},C,A?{username:n}:O?{otp:n}:{})}))}),(0,k.jsx)(f.$n,{label:A?"Connect":O?"Verify":"",disabled:(null==(ae=e.instagramConnectMutation)?void 0:ae.isPending)||(null==(ie=e.instagramVerifyMutation)?void 0:ie.isPending)||A&&!(null!=C&&C.username),isLoading:(null==(oe=e.instagramConnectMutation)?void 0:oe.isPending)||(null==(re=e.instagramVerifyMutation)?void 0:re.isPending),onClick:()=>{var t,n;return A?null==(t=e.instagramConnectMutation)?void 0:t.mutate((null==C?void 0:C.username)||""):O?null==(n=e.instagramVerifyMutation)?void 0:n.mutate((null==C?void 0:C.otp)||""):void 0}})]})})]})})}),O&&(0,k.jsx)(de,{isOTPStep:O,handleManuallyVerify:se,handleResendOtp:()=>{null==ne||ne.mutate({data:(null==C?void 0:C.username)||"",type:"otp"})},instagramVerifyMutation:e.instagramVerifyMutation,instagramFlow:C,setState:e.setState,instagramOtpMutation:ne}),(0,k.jsx)(f.aF,{show:H||z,onClickOutside:()=>null==e.setState?void 0:e.setState(e=>Object.assign({},e,{instagramFlow:{step:null},instructionsSend:!0})),contentClassName:$,children:(0,k.jsxs)("div",{className:U,children:[(0,k.jsxs)("div",{className:B,children:[(0,k.jsx)(f.o5,{variant:"copy",weight:600,label:H?"We did not find your Instagram contact info":"Complete your connection"}),(0,k.jsx)(f.o5,{weight:500,label:H?"Please manually verify your Instagram account. We have sent instructions to your email.":"We've sent instructions to the email you\u2019re registering with to complete the connection."})]}),(0,k.jsx)(f.$n,{theme:"primary",label:"Got It",onClick:()=>null==e.setState?void 0:e.setState(e=>Object.assign({},e,{instagramFlow:{step:null},instructionsSend:!0}))})]})}),(0,k.jsx)(f.aF,{show:K,onClickOutside:()=>null==e.setState?void 0:e.setState(e=>Object.assign({},e,{instagramFlow:{step:null},instructionsSend:!0})),contentClassName:$,children:(0,k.jsxs)("div",{className:U,children:[(0,k.jsx)("div",{className:B,children:(0,k.jsxs)("div",{className:G,children:[(0,k.jsx)("div",{children:(0,k.jsx)(f.o5,{family:"calluna",variant:"title3",label:"Verification"})}),(0,k.jsx)("div",{children:(0,k.jsxs)("div",{className:W,children:["You have reached the maximum number of one-time password resends. Please try again later or",(0,k.jsxs)("span",{className:`${null!=ne&&ne.isPending?D:""}`,onClick:se,children:[" ","manually verify."]})]})})]})}),(0,k.jsx)(f.$n,{theme:"primary",label:"Got It",onClick:()=>null==e.setState?void 0:e.setState(e=>Object.assign({},e,{instagramFlow:{step:null},instructionsSend:!0}))})]})})]})});var ae,ie,oe,re}function pe(e){const t=(0,l.zy)(),n=(0,l.Zp)(),{professionCategories:s}=(0,d.IF)(e=>e),[f,j]=(0,a.useState)({}),[b,_]=(0,a.useState)(!0),x=(0,h.wA)(),y=(0,o.I)({queryKey:["get-profile-social-accounts"],queryFn:u.BF,refetchOnWindowFocus:!1});(0,a.useEffect)(()=>{const e=y.data;if(null==e||!e.length)return;e[0].is_verified?x((0,g.kO)(!1)):null==j||j(e=>Object.assign({},e,{instagramFlow:{step:null},instructionsSend:!0}))},[y.data]);const w=(0,r.n)({mutationFn:e=>(0,u.dF)(e),onSuccess:async e=>{switch(e.connect_status){case"check_email_for_instructions":x((0,g.kO)(!0)),j(t=>Object.assign({},t,{instagramFlow:Object.assign({},t.instagramFlow,{step:"instruction",message:e.message,error:void 0})}));break;case"in_app_verification_required":j(t=>Object.assign({},t,{instagramFlow:Object.assign({},t.instagramFlow,{step:"otp",message:e.message,error:void 0})}));break;default:await y.refetch(),j(e=>Object.assign({},e,{instagramFlow:void 0,errors:void 0}))}},onError:e=>{c.oR.error(e._message)}}),S=(0,r.n)({mutationFn:e=>(0,u.gA)(e),onSuccess:async()=>{await y.refetch(),await F.refetch(),j(e=>Object.assign({},e,{instagramFlow:{step:null},errors:void 0}))},onError:e=>{j(t=>Object.assign({},t,{instagramFlow:Object.assign({},t.instagramFlow,{error:e._errors})})),c.oR.error(e._message)}}),N=(0,r.n)({mutationFn:e=>(0,u.jE)(e),onSuccess:async()=>{await y.refetch(),await F.refetch()},onError:e=>{j(t=>Object.assign({},t,{errors:e._errors})),c.oR.error(e._message)}}),{mutate:C}=N,A=(0,r.n)({mutationFn:e=>(0,u.s2)(e),onSuccess:async()=>{await y.refetch(),await F.refetch()},onError:e=>{j(t=>Object.assign({},t,{errors:e._errors})),c.oR.error(e._message)}}),{mutate:O}=A,R=(0,r.n)({mutationFn:e=>(0,u._k)(e),onSuccess:async()=>{await y.refetch(),await F.refetch()},onError:e=>{j(t=>Object.assign({},t,{error:e._errors})),c.oR.error(e._message)}}),P=(0,a.useMemo)(()=>s.data.map(e=>({value:e.id.toString(),label:e.name})),[s.data]),M=(0,a.useCallback)(e=>{var t;const n=null==(t=y.data)?void 0:t.find(t=>t.platform===e);return!(null==n||!n.is_verified)},[y]),E=f.isSaving,{fetchProfile:F}=(0,v.d)(),L=y.isFetching||R.isPending||F.isLoading;(0,a.useEffect)(()=>{null==e.setIsLoading||e.setIsLoading(L)},[L]);(0,a.useEffect)(()=>
1{if(t.search){const s=t.search,a=new URLSearchParams(s).get("code")||"";n(e.isAccountSetting?"/talent/account/social-connect":"/talent/signup/connect-socials",{replace:!0});const i=e.isAccountSetting?window.location.origin+"/talent/account/social-connect":window.location.origin+"/talent/signup/connect-socials";C({code:a,redirect_url:i})}if(t.hash){const s="?"+t.hash.slice(1),a=new URLSearchParams(s).get("access_token")||"",i=e.isAccountSetting?"/talent/account/social-connect":"/talent/signup/connect-socials";n(i,{replace:!0}),O(a)}},[t,n,C,O]);const I=Object.assign({},e,{professionCategoriesList:P,state:f,profileSocialAccountsQuery:y,instagramConnectMutation:w,instagramVerifyMutation:S,tiktokConnectMutation:N,youtubeConnectMutation:A,removeSocialAccountMutation:R,isSaving:E,isLoading:L,instavalidation:b,setInstaValidation:_,setState:j,getPlatformConnectionStatus:M,onSaveOrNext:async()=>{let e;F.refetch(),j(e=>Object.assign({},e,{isSaving:!0})),await y.refetch(),e=b?(0,p.iV)(y.data||[]):{},(0,i.isEmpty)(e)?n("/talent/signup/upload-avatar",{state:{direction:1}}):(j(t=>Object.assign({},t,{errors:e})),c.oR.error("You must connect at lease 1 social profile")),j(e=>Object.assign({},e,{isSaving:!1}))},onConnectYoutube:async()=>{const t=e.isAccountSetting?window.location.origin+"/talent/account/social-connect":window.location.origin+"/talent/signup/connect-socials",n=new URL("https://accounts.google.com/o/oauth2/auth");n.searchParams.set("client_id","61372798753-231vpr3h05l2hih7nd563qnfotm200ms.apps.googleusercontent.com"),n.searchParams.set("scope","profile email openid https://www.googleapis.com/auth/youtube.readonly"),n.searchParams.set("redirect_uri",t),n.searchParams.set("response_type","token"),window.location.href=n.toString()},onConnectTikTok:async()=>{const t=e.isAccountSetting?window.location.origin+"/talent/account/social-connect":window.location.origin+"/talent/signup/connect-socials",n=Math.random().toString(36).substring(2),s=(0,m.zE)(),a=await(0,p.cq)(s),i=new URL("https://www.tiktok.com/v2/auth/authorize");i.searchParams.set("client_key","awz167nfcqje6u8h"),i.searchParams.set("scope","user.info.basic,user.info.profile,user.info.stats"),i.searchParams.set("redirect_uri",t),i.searchParams.set("response_type","code"),i.searchParams.set("state",n),i.searchParams.set("code_challenge",a),i.searchParams.set("code_challenge_method","S256"),window.location.href=i.toString()}});return(0,k.jsx)(ve,Object.assign({},I))}},64476(e,t,n){n.d(t,{A:()=>o});var s=n(10123),a=n(70551);var i=n(6982);function o(e,t){(0,a.A)(2,arguments);var n=(0,s.A)(e),o=(0,s.A)(t),r=(0,i.A)(n,o),l=Math.abs(function(e,t){(0,a.A)(2,arguments);var n=(0,s.A)(e),i=(0,s.A)(t);return n.getFullYear()-i.getFullYear()}(n,o));n.setFullYear(1584),o.setFullYear(1584);var c=(0,i.A)(n,o)===-r,d=r*(l-Number(c));return 0===d?0:d}},95695(e,t,n){n.d(t,{A:()=>s});const s={container:"__Jv2NAH",content:"__KbGuVa",contentBody:"__ElfTfA",contentStep:"__q5ZqJD",contentStepHeader:"__lIToB1",contentStepHeaderTitle:"__rgoBMZ",contentHeaderGoBack:"__sRg1yI",contentHeaderSkip:"__chCHLW",contentStepBody:"__ibdPjM",stepProgress:"__TnD9Nj",actionsList:"__DsCdQ9",actionsListItem:"__qIU8vS"}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.