WhatsAppAdsManagerOnboardingFromSubscriberPoolFlow.react",["AdsAdvertiserSettingsMessageMarketingDefaultSubscriberPoolExitConfirmationModal.react","AdsMessagingControlsLogger","RelayHooks","WhatsAppAdsManagerIntegrationSharedIDs","WhatsAppAdsManagerOnboardingFromSubscriberPoolFlowQuery.graphql","WhatsAppAdsManagerOnboardingUtils","WhatsAppAdsManagerOnboardingWelcomeStepMessages","WhatsAppAdsManagerSubscriberSyncIntroModalFbts","WhatsAppAdsManagerSubscriberSyncModal.react","WhatsAppBizxPlatformAdsManagerOnboardingAudienceNameSetupContainer.react","WhatsAppBizxPlatformAdsManagerOnboardingFinishContainer.react","WhatsAppBizxPlatformAdsManagerOnboardingNoLiftCRMContainer.react","WhatsAppBizxPlatformAdsManagerOnboardingPermissionFinishContainer.react","WhatsAppBizxPlatformComponentFbts","WhatsAppBizxPlatformConfigBuilder","WhatsAppBizxPlatformFeature.enum","WhatsAppBizxPlatformGeoModalDriver.react","WhatsAppBizxPlatformSignupContainerLoadingState.react","WhatsAppBizxPlatformStepType.flow","WhatsAppBizxPlatformWWWLoggerUtils","emptyFunction","gkx","react","uniqueID","useGetWhatsAppAdsManagerBusinessAccountDataQuery","useIsMarketingMessagesAgencyFlow","useUpdateAdAccountNoLiftCRMStatus","useWhatsAppBusinessLazyLoadExistingProfiles"],(function(a,b,c,d,e,f,g){"use strict";var h,i,j=i||(i=d("react"));e=i;var k=e.Suspense,l=e.useRef,m=e.useState,n=c("gkx")("200"),o=h!==void 0?h:h=b("WhatsAppAdsManagerOnboardingFromSubscriberPoolFlowQuery.graphql"),p=c("gkx")("11469"),q={id:c("WhatsAppBizxPlatformStepType.flow").WHATSAPP_ADS_MANAGER_ONBOARDING_SUBSCRIBER_SYNC_INTRO_STEP,label:d("WhatsAppAdsManagerSubscriberSyncIntroModalFbts").SUBSCRIBER_SYNC_INTRO_STEP_LABEL,testId:"WhatsAppAdsManagerOnboardingSubscriberSyncIntroStep"},r={id:c("WhatsAppBizxPlatformStepType.flow").WHATSAPP_ADS_MANAGER_ONBOARDING_MARKETING_MESSAGE_AUDIENCE_NAME_STEP,label:d("WhatsAppAdsManagerOnboardingWelcomeStepMessages").MARKETING_MESSAGE_AUDIENCE_NAME,testId:"WhatsAppAdsManagerOnboardingDefaultSubscriberPoolNameStep"},s={id:c("WhatsAppBizxPlatformStepType.flow").WHATSAPP_ADS_MANAGER_ONBOARDING_PERMISSION_ASSIGNING_STEP,label:d("WhatsAppAdsManagerOnboardingWelcomeStepMessages").PERMISSION_ASSIGNING_LABEL,testId:"WhatsAppAdsManagerOnboardingPermissionAssigningStep"},t={id:c("WhatsAppBizxPlatformStepType.flow").WHATSAPP_ADS_MANAGER_ONBOARDING_NO_LIFT_CRM_STEP,label:d("WhatsAppAdsManagerOnboardingWelcomeStepMessages").NO_LIFT_CRM_LABEL,testId:"WhatsAppAdsManagerOnboardingNoLiftCRMStep"},u={id:c("WhatsAppBizxPlatformStepType.flow").WHATSAPP_ADS_MANAGER_ONBOARDING_FINISHED_STEP,label:d("WhatsAppBizxPlatformComponentFbts").FINISH,testId:"WhatsAppAdsManagerOnboardingFinishStep"},v=d("WhatsAppBizxPlatformWWWLoggerUtils").getSessionLoggingID("AdsManagerOnboarding");function a(a){var b=a.adAccountID,e=a.businessID,f=a.defaultWABAID,g=a.isViewerAdminOfBusiness;g=g===void 0?!0:g;var h=a.onBack,i=a.onCancel,w=a.onFinish,x=a.onHide,y=a.onSubscriberPoolCompleted,z=a.refresh,A=a.setNoLiftCRMEnabled;a=a.showModal;var B=m(!1),C=B[0],D=B[1];B=m(null);var E=B[0],F=B[1],G=c("useIsMarketingMessagesAgencyFlow")((B=b)!=null?B:"",(B=e)!=null?B:""),H=g===!0&&!G;B=d("RelayHooks").useLazyLoadQuery(o,{adAccountID:(B=b)!=null?B:"",businessID:(B=e)!=null?B:""},{fetchPolicy:"store-or-network"});var I=(B=B.ad_account)==null?void 0:(B=B.advertiser_profile_editable_attributes)==null?void 0:(B=B.find(function(a){return a.type==="IS_MESSAGE_MARKETING_DFCA_AUTOMATIC_UPLOAD_ENABLED"}))==null?void 0:(B=B.value)==null?void 0:B.as_boolean;B=c("useGetWhatsAppAdsManagerBusinessAccountDataQuery")(e);var J=B.name,K=c("useUpdateAdAccountNoLiftCRMStatus")(b,e,d("AdsMessagingControlsLogger").MessageControlsActionSource.ONBOARDING,A);B={type:"ADS_MANAGER",businessID:e};A={business:{id:e},whatsappAccount:{id:f}};f=l(!1);B=new(c("WhatsAppBizxPlatformConfigBuilder"))({appID:d("WhatsAppAdsManagerIntegrationSharedIDs").ADS_WHATSAPP_MARKETING_MESSAGE_APP_ID,featureID:c("WhatsAppBizxPlatformFeature.enum").WHATSAPP_ONBOARDING_IN_ADS_MANAGER,platformType:B,deviceType:"WEB",loggerID:v}).withInitialState(A);A=c("useWhatsAppBusinessLazyLoadExistingProfiles")({appID:String(d("WhatsAppAdsManagerIntegrationSharedIDs").ADS_WHATSAPP_MARKETING_MESSAGE_APP_ID),loggingID:v,businessID:e,logEvent:!f.current,fetchKey:c("uniqueID")(),includePhoneProfiles:!0,productType:"ADS_MANAGER",adAccountID:b});f=d("WhatsAppAdsManagerOnboardingUtils").getRegisteredPhoneProfilesFromAllWABAs(A);var L=f.filter(function(a){return(a==null?void 0:a.isContactCollectionAllowedForAdAccount)===!0}),M=f.filter(function(a){return!L.some(function(b){return b.id===a.id})}),N=A.filter(function(a){return a.isAvaliableOnAdsManager!==!0||a.isReusedOnAdsManager===!0});f=B.addStepConfig(babelHelpers["extends"]({},r,{shouldShow:function(){return p},isFullScreen:!0,render:function(a){return j.jsx(k,{fallback:j.jsx(d("WhatsAppBizxPlatformSignupContainerLoadingState.react").WhatsAppBizxPlatformSignupContainerLoadingState,{}),children:j.jsx(c("WhatsAppBizxPlatformAdsManagerOnboardingAudienceNameSetupContainer.react"),babelHelpers["extends"]({},a,{adAccountID:b,businessID:e,defaultSubscriberPoolID:E,businessName:J,onHide:x,needReviewSubscriberPool:!1,refresh:z,setLocalDefaultSubscriberPoolName:c("emptyFunction"),setDefaultSubscriberPoolID:F,onSubscriberPoolCompleted:y}))})}})).addStepConfig(babelHelpers["extends"]({isFullScreen:!0},q,{shouldShow:function(){return G===!1&&M.length>0},render:function(a){return j.jsx(k,{fallback:j.jsx(d("WhatsAppBizxPlatformSignupContainerLoadingState.react").WhatsAppBizxPlatformSignupContainerLoadingState,{}),children:j.jsx(c("WhatsAppAdsManagerSubscriberSyncModal.react"),babelHelpers["extends"]({},a,{adAccountID:b,businessID:e,onHide:w,subscriberSyncWABAs:N}))})}})).addStepConfig(babelHelpers["extends"]({},t,{shouldShow:function(){return G===!1&&d("WhatsAppAdsManagerOnboardingUtils").shouldShowNoLiftCRMStep(n,I,G)},isFullScreen:!0,isDisabled:function(){return!0},render:function(a){return j.jsx(k,{fallback:j.jsx(d("WhatsAppBizxPlatformSignupContainerLoadingState.react").WhatsAppBizxPlatformSignupContainerLoadingState,{}),children:j.jsx(c("WhatsAppBizxPlatformAdsManagerOnboardingNoLiftCRMContainer.react"),babelHelpers["extends"]({},a,{adAccountID:b,businessID:e,onHide:w,onNoLiftUpdate:K}))})}})).addStepConfig(babelHelpers["extends"]({},s,{shouldShow:function(){return H},isFullScreen:!0,isDisabled:function(){return!0},render:function(a){return j.jsx(k,{fallback:j.jsx(d("WhatsAppBizxPlatformSignupContainerLoadingState.react").WhatsAppBizxPlatformSignupContainerLoadingState,{}),children:j.jsx(c("WhatsAppBizxPlatformAdsManagerOnboardingPermissionFinishContainer.react"),babelHelpers["extends"]({},a,{adAccountID:b,subscriberPoolID:E,onHide:w}))})}})).addStepConfig(babelHelpers["extends"]({isFullScreen:!0},u,{render:function(a){var b=L.length>0;return j.jsx(c("WhatsAppBizxPlatformAdsManagerOnboardingFinishContainer.react"),babelHelpers["extends"]({},a,{onHide:w,isSubscriberSyncEnabled:b,isActivationEntry:!0}))}})).build();f.logger.addMetadata({isAdsManager:!0,isViewerAdminOfBusiness:g,isVirtualNumberGKEnabled:!0,isModal:!0,adAccountID:b,businessID:e,isFromSubscriberPool:!0});return p===!1?null:a&&j.jsxs(j.Fragment,{children:[j.jsx(c("AdsAdvertiserSettingsMessageMarketingDefaultSubscriberPoolExitConfirmationModal.react"),{adAccountID:b,businessID:e,isShown:a&&C,onGoBack:function(){D(!1)},onHide:function(){x(),D(!1)}}),j.jsx(c("WhatsAppBizxPlatformGeoModalDriver.react"),{areStepperLabelsHidden:!0,config:f,isShown:a&&C===!1,onCancel:i,onHide:function(a,b){b===c("WhatsAppBizxPlatformStepType.flow").WHATSAPP_ADS_MANAGER_ONBOARDING_MARKETING_MESSAGE_AUDIENCE_NAME_STEP&&E==null?D(!0):(x(),w())},onFinish:w,onBack:h})]})}a.displayName=a.name+" [from "+f.id+"]";g["default"]=a}),98);
-----
WhatsAppAdsManagerOnboardingFromSubscriberPoolFlowQuery_facebookRelayOperation",[],(function(a,b,c,d,e,f){e.exports="9817243791696472"}),null);
-----