AdsMetaProWAChatRequestError.react",["AdsHelpTrayPopNavigationStackAction","AdsOsmipMarketingProScheduleCallUtils","CRMMEProgram","GeoBaseText.react","GeoButton.react","GeoCard.react","GeoCardHeader.react","GeoFlexbox.react","GeoSection.react","MetaProEngagementStrings","ProgramsChannelType","geoMargin","getJSEnumSafe","logMetaProImpression","logMetaProXout","react","useSelectedAdAccountID"],(function(a,b,c,d,e,f,g){"use strict";var h,i=h||(h=d("react"));b=h;var j=b.useEffect,k=b.useRef,l={heightAuto:{height:"xt7dq6l",$$css:!0}};function a(a){var b=a.osmipExtraData;a=(a=b==null?void 0:b.isInvalidPhoneNumberError)!=null?a:!1;var e=c("useSelectedAdAccountID")(f.id),g=b==null?void 0:b.leadSource,h=b==null?void 0:b.entryPoint,m=b==null?void 0:b.surface,n=d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo(g,h,m),o={leadSource:n.leadSource,entryPoint:n.entryPoint,surface:n.surface},p=k(null);j(function(){p.current!==n.entryPoint.toString()&&(p.current=n.entryPoint.toString(),c("logMetaProImpression")(o,"error_modal",{ad_account_id:e,channels:[c("ProgramsChannelType").WHATSAPP_ALWAYS_ON_CHAT],program:c("getJSEnumSafe")(c("CRMMEProgram"),b==null?void 0:b.sbgProgramName)}))});return i.jsx(c("GeoFlexbox.react"),{"data-testid":void 0,direction:"column",grow:1,xstyle:c("geoMargin").all16,children:i.jsx(c("GeoCard.react"),{header:i.jsx(c("GeoCardHeader.react"),{heading:a?d("MetaProEngagementStrings").WHATSAPP_CHAT_INVALID_NUMBER_MODAL_HEADER:d("MetaProEngagementStrings").WHATSAPP_GERNERIC_ERROR_HEADER}),xstyle:l.heightAuto,children:i.jsxs(c("GeoSection.react"),{children:[i.jsx(c("GeoBaseText.react"),{color:"value",size:"value",children:a?d("MetaProEngagementStrings").WHATSAPP_CHAT_INVALID_NUMBER_MODAL_DESCRIPTION:d("MetaProEngagementStrings").WHATSAPP_GERNERIC_ERROR_DESCRIPTION}),i.jsx(c("GeoFlexbox.react"),{direction:"column",xstyle:c("geoMargin").vert16,children:i.jsx(c("GeoFlexbox.react"),{gap:8,justifyContent:"space-between",xstyle:c("geoMargin").top8,children:i.jsx(c("GeoButton.react"),{"data-testid":void 0,grow:"fill",label:d("MetaProEngagementStrings").CANCEL_LABEL,variant:"default",onClick:function(){c("logMetaProXout")(o,"error_modal",{ad_account_id:e,channels:[c("ProgramsChannelType").WHATSAPP_ALWAYS_ON_CHAT],program:c("getJSEnumSafe")(c("CRMMEProgram"),b==null?void 0:b.sbgProgramName)}),c("AdsHelpTrayPopNavigationStackAction").dispatch({},{line:"136",module:"AdsMetaProWAChatRequestError.react.js",moduleID:f.id})}},"mp-wa-request-chat-form-cancel-button")})})]})})})}a.displayName=a.name+" [from "+f.id+"]";g["default"]=a}),98);
-----
AdsOsmipMarketingProRescheduleCall.react",["fbt","AdsGuidanceTrayHeader.react","AdsHelpTrayMarketingProUtils","AdsHelpTrayPopNavigationStackAction","AdsHelpTrayUILogger","AdsOsmipMarketingProRescheduleCall_availabilities.graphql","AdsOsmipMarketingProRescheduleCall_details.graphql","AdsOsmipMarketingProScheduleCallUtils","BizKitMarketingExpertRescheduleCallButton.react","BizKitMarketingExpertTimeslotPicker.react","DateTime","GeoBaseText.react","GeoCancelButton.react","GeoCard.react","GeoDatePicker.react","GeoFlexbox.react","GeoHeading.react","GeoSection.react","LocalDate","MarketingExpertWidgetTimezoneSelector.react","MarketingExpertWidgetUtils","RelayHooks","Timezone","bizKitMarketingExpertCallUtil","geoMargin","react"],(function(a,b,c,d,e,f,g,h){"use strict";var i,j,k,l=k||(k=d("react"));e=k;var m=e.useEffect,n=e.useState;function a(a){var e,g,k,o=a.availabilities,p=a.entryPoint,q=a.existingConnectionDetailsKey,r=a.leadSource;a=a.surface;q=d("RelayHooks").useFragment(i!==void 0?i:i=b("AdsOsmipMarketingProRescheduleCall_details.graphql"),q);var s=d("Timezone").getEnvironmentTimezoneID();e=q==null?void 0:(e=q.connection_details)==null?void 0:e.time_frame;g=e==null?void 0:(g=e.start_time)==null?void 0:g.timestamp;e=e==null?void 0:(e=e.end_time)==null?void 0:e.timestamp;o=d("RelayHooks").useFragment(j!==void 0?j:j=b("AdsOsmipMarketingProRescheduleCall_availabilities.graphql"),o);var t=o==null?void 0:(o=o.availabilities[0])==null?void 0:o.slots;o=d("bizKitMarketingExpertCallUtil").getDateToTimeslots(t,s);var u=n(s),v=u[0];u=u[1];var w=o==null?null:c("LocalDate").fromISOString(o[0].dateString);k=o==null?void 0:(k=o[0].timeslot)==null?void 0:k[0];w=n((w=w)!=null?w:c("LocalDate").today(s));var x=w[0],y=w[1];w=n(k);k=w[0];var z=w[1];w=n(o);var A=w[0],B=w[1];m(function(){var a=d("bizKitMarketingExpertCallUtil").getDateToTimeslots(t,v);B(a)},[v,t]);m(function(){var a;a=A==null?void 0:(a=A.find(function(a){return a.dateString===(x==null?void 0:x.toISOString())}))==null?void 0:a.timeslot;a!=null&&z(a[0])},[x,A]);if(g==null||e==null)return null;o=c("DateTime").create(g,s);w=c("DateTime").create(e,s);var C=function(a){var b;b=A==null?void 0:(b=A.find(function(b){return b.dateString===(a==null?void 0:a.toISOString())}))==null?void 0:b.timeslot;b!=null&&z(b[0])};return l.jsxs(l.Fragment,{children:[l.jsx(c("AdsGuidanceTrayHeader.react"),{contentType:"SCHEDULE_MARKETING_CALL",density:"cozy",heading:h._("__JHASH__Pa62H3q0NIx__JHASH__"),showBackButton:!0}),l.jsx(c("GeoCard.react"),{children:l.jsxs(c("GeoSection.react"),{children:[l.jsxs(c("GeoFlexbox.react"),{direction:"column",xstyle:c("geoMargin").all8,children:[l.jsx(c("GeoBaseText.react"),{color:"inherit",size:"valueDescription",weight:"bold",children:h._("__JHASH__oL-awzQRi9J__JHASH__")}),l.jsx(c("GeoHeading.react"),{level:1,children:d("MarketingExpertWidgetUtils").getFormattedDateFbt(o)}),l.jsx(c("GeoBaseText.react"),{color:"inherit",size:"valueDescription",xstyle:c("geoMargin").top8,children:h._("__JHASH__Tb9MOdPoDkS__JHASH__",[h._param("start_time",d("MarketingExpertWidgetUtils").getFormattedTimeFbt(o,s)),h._param("duration",d("AdsHelpTrayMarketingProUtils").getDurationFbt(o,w))])})]}),l.jsxs(c("GeoFlexbox.react"),{alignItems:"end",direction:"row",gap:8,justifyContent:"space-between",xstyle:[c("geoMargin").top16,c("geoMargin").horiz8],children:[l.jsx(c("GeoDatePicker.react"),{label:h._("__JHASH__f5bcKMRtigG__JHASH__"),restraint:function(a){return(A==null?void 0:A.find(function(b){return a.equals(c("LocalDate").fromISOString(b.dateString))}))!=null},value:x,onChange:function(a){C(a);y((a=a)!=null?a:c("LocalDate").today(v))}}),l.jsx(c("MarketingExpertWidgetTimezoneSelector.react"),{value:v,onChange:u})]}),l.jsx(c("GeoFlexbox.react"),{xstyle:[c("geoMargin").top16,c("geoMargin").horiz8],children:l.jsx(c("BizKitMarketingExpertTimeslotPicker.react"),{selectedTimeslot:k,setSelectedTimeslot:z,timeslots:A==null?void 0:(g=A.find(function(a){return a.dateString===(x==null?void 0:x.toISOString())}))==null?void 0:g.timeslot,timezoneID:v})}),l.jsxs(c("GeoFlexbox.react"),{justifyContent:"end",xstyle:[c("geoMargin").top16,c("geoMargin").horiz8],children:[l.jsx(c("GeoCancelButton.react"),{xstyle:c("geoMargin").end8,onClick:function(){d("AdsHelpTrayUILogger").logBackButtonClick("SCHEDULE_MARKETING_CALL"),c("AdsHelpTrayPopNavigationStackAction").dispatch({},{line:"244",module:"AdsOsmipMarketingProRescheduleCall.react.js",moduleID:f.id})}}),l.jsx(c("BizKitMarketingExpertRescheduleCallButton.react"),{connectionID:q==null?void 0:q.id,sourceTracking:d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo(r,p,a),timeslot:k,useAdsToasts:!0,onMutation:function(){return c("AdsHelpTrayPopNavigationStackAction").dispatch({},{line:"257",module:"AdsOsmipMarketingProRescheduleCall.react.js",moduleID:f.id})}})]})]})})]})}a.displayName=a.name+" [from "+f.id+"]";g["default"]=a}),226);
-----
AdsOsmipMarketingProScheduleCallForm.react",["fbt","AdsGuidanceTrayHeader.react","AdsHelpTrayPopNavigationStackAction","AdsOsmipMarketingProScheduleCallForm_availabilities.graphql","AdsOsmipMarketingProScheduleCallForm_prefillData.graphql","AdsOsmipMarketingProScheduleCallUtils","AdsOsmipScheduleMPCallFormSlotPicker.react","BizKitMarketingExpert1ClickCallModalFbts","BizKitMarketingExpertScheduleCallButton.react","CRMMEProgram","GeoAppearanceSelectors","GeoBaseText.react","GeoButton.react","GeoCard.react","GeoColorSelectors","GeoFlexbox.react","GeoScrollableArea.react","GeoSection.react","GeoTextInput.react","GeoTextPairing.react","MarketingExpertWidgetScheduledCallModalFbts","MarketingExpertWidgetUtils","RelayHooks","SBGPrefillField","Timezone","addToSet","bizKitMarketingExpertCallUtil","castToEnum","geoMargin","getJSEnumSafe","isEmail","logMetaProImpression","react","stylex"],(function(a,b,c,d,e,f,g,h){"use strict";var i,j,k,l,m=l||(l=d("react"));e=l;var n=e.useEffect,o=e.useMemo,p=e.useRef,q=e.useState,r={padding:{paddingTop:"xyamay9",paddingEnd:"x1pi30zi",paddingBottom:"x1l90r2v",paddingStart:"x1swvt13",$$css:!0},flexGrow:{flexGrow:"x1iyjqo2",$$css:!0},footer:{bottom:"x1ey2m1c",boxShadow:"x1r1n72o",display:"x78zum5",justifyContent:"x13a6bvl",paddingTop:"xyamay9",paddingEnd:"x1pi30zi",paddingBottom:"x1l90r2v",paddingStart:"x1swvt13",position:"x7wzq59",zIndex:"x1vjfegm",$$css:!0},heightAuto:{height:"xt7dq6l",$$css:!0}},s=d("Timezone").getEnvironmentTimezoneID(),t=6;function a(a){var e,g,l,u=a.accountID,v=a.availabilities,w=a.entryPoint,x=a.leadSource,y=a.sbgPrefillKey,z=a.sbgProgramName,A=a.sbgSubProgramName,B=a.srtJobID,C=a.surface;a=d("RelayHooks").useFragment(i!==void 0?i:i=b("AdsOsmipMarketingProScheduleCallForm_availabilities.graphql"),v);var D=d("RelayHooks").useFragment(j!==void 0?j:j=b("AdsOsmipMarketingProScheduleCallForm_prefillData.graphql"),y);v=o(function(){var b=new Map();D==null?void 0:D.forEach(function(a){var d=c("castToEnum")(a.field,c("SBGPrefillField"));a=a.value;d!=null&&a!=null&&b.set(d,a)});var a=Array.from(b.keys());return{prefilledFieldMap:b,prefilledFields:a}},[D]);y=v.prefilledFieldMap;var E=v.prefilledFields;v=q(new Set());var F=v[0],G=v[1];v=q((v=y.get("FULL_NAME"))!=null?v:"");var H=v[0];v=v[1];e=q((e=y.get("COMPANY_NAME"))!=null?e:"");var I=e[0];e=e[1];g=q((g=y.get("EMAIL"))!=null?g:"");var J=g[0];g=g[1];y=q((y=y.get("PHONE"))!=null?y:"");var K=y[0],L=y[1];y=d("MarketingExpertWidgetUtils").useInputWithValidator(v,function(a){return a.trim().length>0});v=y[0];var M=y[1];y=d("MarketingExpertWidgetUtils").useInputWithValidator(e,function(a){return a.trim().length>0});e=y[0];var N=y[1];y=d("MarketingExpertWidgetUtils").useInputWithValidator(g,c("isEmail"));g=y[0];var O=y[1];y=d("MarketingExpertWidgetUtils").useInputWithValidator(function(a){return L(a.replace(d("MarketingExpertWidgetUtils").ALPHABET_LETTERS_REGEX,""))},function(a){return d("MarketingExpertWidgetUtils").REGEX_PHONE_NUMBER.test(a.replace(d("MarketingExpertWidgetUtils").ALPHABET_LETTERS_REGEX,""))});var P=y[0],Q=y[1];y=a==null?void 0:(y=a.availabilities)==null?void 0:(y=y[0])==null?void 0:y.slots;l=a==null?void 0:(l=a.availabilities)==null?void 0:(l=l[0])==null?void 0:l.duration;var R=y==null?void 0:y.filter(function(a){return((a=a.time_frame)==null?void 0:a.preferred)===!0});y=y==null?void 0:y.filter(function(a){return((a=a.time_frame)==null?void 0:a.preferred)!==!0});y=R==null?void 0:R.concat((R=y)!=null?R:[]);R=y==null?void 0:y.slice(0,t);y=d("bizKitMarketingExpertCallUtil").getDateToTimeslots(R,s);R=q(null);var S=R[0],T=R[1],U=p(!1);n(function(){U.current===!1&&(U.current=!0,c("logMetaProImpression")(d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo(x,w,C),"form",{program:c("getJSEnumSafe")(c("CRMMEProgram"),z),sub_program:A,ad_account_id:u,prefilled_form_fields:E}))},[u,w,x,E,z,A,C]);R=S&&d("MarketingExpertWidgetUtils").validateAllInput(H,I,J,K)?m.jsx(c("BizKitMarketingExpertScheduleCallButton.react"),{adAccountId:u,contactInformation:{advertiserName:H.trim(),companyName:I.trim(),email:J,phoneNumber:K},label:d("BizKitMarketingExpert1ClickCallModalFbts").BIZ_KIT_ME_1CLICK_FBTS.CONFIRM_CALL_BUTTON_FBT,prefilledFields:E,programName:z,sourceTracking:d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo(x,w,C),srtJobID:B,subProgramName:A,timeslot:S,timezoneID:s,updatedFields:Array.from(F),useAdsToasts:!0,onHide:function(){},onMutation:function(){return c("AdsHelpTrayPopNavigationStackAction").dispatch({},{line:"263",module:"AdsOsmipMarketingProScheduleCallForm.react.js",moduleID:f.id})},onReloadWindow:function(){}}):m.jsx(c("GeoButton.react"),{"data-testid":void 0,isDisabled:!0,label:h._("__JHASH__l-NWiw25a6p__JHASH__"),variant:"primary"});return m.jsxs(c("GeoFlexbox.react"),{"data-testid":void 0,direction:"column",grow:1,children:[m.jsx(c("AdsGuidanceTrayHeader.react"),{contentType:"SCHEDULE_MARKETING_CALL",density:"cozy",heading:h._("__JHASH__DbMrx1IS8eZ__JHASH__"),showBackButton:!0}),m.jsx(c("GeoScrollableArea.react"),{xstyle:r.flexGrow,children:m.jsx(c("GeoCard.react"),{xstyle:r.heightAuto,children:m.jsxs(c("GeoSection.react"),{children:[m.jsx(c("GeoTextPairing.react"),{description:h._("__JHASH__KG6yGl5jdvg__JHASH__"),heading:h._("__JHASH__vEoL4zRL3IY__JHASH__"),size:"header3"}),m.jsx(c("GeoFlexbox.react"),{direction:"column",xstyle:c("geoMargin").vert16,children:m.jsx(c("GeoTextInput.react"),{errorMessage:v?null:d("MarketingExpertWidgetScheduledCallModalFbts").SCHEDULED_CALL_MODAL_FBTS.ADVERTISER_NAME_ERROR_FBT,label:h._("__JHASH__eBiV0uClELz__JHASH__"),placeholder:h._("__JHASH__eBiV0uClELz__JHASH__"),value:H,onChange:function(a){M(a),G(c("addToSet")(F,"FULL_NAME"))}})}),m.jsx(c("GeoFlexbox.react"),{direction:"column",xstyle:c("geoMargin").vert16,children:m.jsx(c("GeoTextInput.react"),{errorMessage:e?null:d("MarketingExpertWidgetScheduledCallModalFbts").SCHEDULED_CALL_MODAL_FBTS.COMPANY_NAME_ERROR_FBT,label:h._("__JHASH__IWF4uIkdR2M__JHASH__"),placeholder:h._("__JHASH__IWF4uIkdR2M__JHASH__"),value:I,onChange:function(a){N(a),G(c("addToSet")(F,"COMPANY_NAME"))}})}),m.jsx(c("GeoFlexbox.react"),{direction:"column",xstyle:c("geoMargin").vert16,children:m.jsx(c("GeoTextInput.react"),{errorMessage:g?null:d("MarketingExpertWidgetScheduledCallModalFbts").SCHEDULED_CALL_MODAL_FBTS.EMAIL_ERROR_FBT,label:h._("__JHASH__vBbgp4fhBEy__JHASH__"),placeholder:h._("__JHASH__vBbgp4fhBEy__JHASH__"),value:J,onChange:function(a){O(a),G(c("addToSet")(F,"EMAIL"))}})}),m.jsx(c("GeoFlexbox.react"),{direction:"column",xstyle:c("geoMargin").vert16,children:m.jsx(c("GeoTextInput.react"),{errorMessage:P?null:d("MarketingExpertWidgetScheduledCallModalFbts").SCHEDULED_CALL_MODAL_FBTS.PHONE_NUMBER_ERROR_FBT,label:h._("__JHASH__gueP7THowwu__JHASH__"),placeholder:h._("__JHASH__gueP7THowwu__JHASH__"),value:K,onChange:function(a){Q(a),G(c("addToSet")(F,"PHONE"))}})}),m.jsx(c("GeoBaseText.react"),{color:"inherit",size:"valueDescription",children:d("BizKitMarketingExpert1ClickCallModalFbts").BIZ_KIT_ME_1CLICK_FBTS.TERMS_AND_CONDITIONS_CHAT_DATA_POLICY}),a!=null&&m.jsxs(m.Fragment,{children:[m.jsx(c("GeoTextPairing.react"),{description:h._("__JHASH__BJfp9dkLBU5__JHASH__",[h._param("timezone",d("Timezone").getName(s).replace("_"," ")),h._param("call duration",l)]),heading:h._("__JHASH__7MsDriQE0xG__JHASH__"),size:"header4",xstyle:c("geoMargin").vert16}),m.jsx(c("GeoFlexbox.react"),{direction:"column",children:m.jsxs("div",{className:(k||(k=c("stylex")))(d("GeoColorSelectors").selectStaticBackgroundColor({surface:"wash",isInverted:!1,isMuted:!0}),d("GeoAppearanceSelectors").selectBorderRadius({context:"container"}),r.padding),children:[m.jsx(c("GeoBaseText.react"),{color:"value",display:"block",size:"header4",xstyle:c("geoMargin").bottom8,children:h._("__JHASH__3u2YATaQEwo__JHASH__")}),m.jsx(c("AdsOsmipScheduleMPCallFormSlotPicker.react"),{selectedTimeslot:S,timeslots:d("bizKitMarketingExpertCallUtil").flattenDateToTimeSlots(y),timezoneID:s,onSelect:function(a){T(a||null)}})]})})]}),m.jsx(c("GeoFlexbox.react"),{children:m.jsx(c("GeoBaseText.react"),{color:"inherit",size:"valueDescription",xstyle:c("geoMargin").top16,children:h._("__JHASH__rnvbIWtWpeM__JHASH__")})})]})})}),m.jsx("div",{className:(k||(k=c("stylex")))(r.footer,d("GeoColorSelectors").selectStaticBackgroundColor({surface:"content"})),children:R})]})}a.displayName=a.name+" [from "+f.id+"]";g["default"]=a}),226);
-----
AdsOsmipMarketingProScheduleCallContainer.react",["AdsAccountStore","AdsFluxHooks","AdsOsmipMarketingProScheduleCallContainerQuery.graphql","AdsOsmipMarketingProScheduleCallForm.react","AdsOsmipMarketingProScheduleCallUtils","CurrentUser","JSResourceForInteraction","RelayHooks","XFBSBGEngagementSurfaceUtils.facebook","lazyLoadComponent","nullthrows","react"],(function(a,b,c,d,e,f,g){"use strict";var h,i,j=i||(i=d("react"));e=i;var k=e.useEffect,l=e.useState,m=c("lazyLoadComponent")(c("JSResourceForInteraction")("AdsOsmipMarketingProRescheduleCall.react").__setRef("AdsOsmipMarketingProScheduleCallContainer.react"));function a(a){var e;a=a.osmipExtraData;var f=d("AdsFluxHooks").useAdsSelector(c("AdsAccountStore").getSelectedAccountID),g=c("CurrentUser").getID();e=(e=a==null?void 0:a.isRescheduleCall)!=null?e:!1;var i=a==null?void 0:a.leadSource,n=a==null?void 0:a.entryPoint,o=a==null?void 0:a.surface,p=d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo(i,n,o),q=l(0),r=q[0],s=q[1],t=function(){s(function(a){return a+1})};k(function(){t()},[e]);q=d("RelayHooks").useLazyLoadQuery(h!==void 0?h:h=b("AdsOsmipMarketingProScheduleCallContainerQuery.graphql"),{inputData:{ad_account_id:f,advertiser_user_id:g,source_tracking:{surface:c("nullthrows")(d("XFBSBGEngagementSurfaceUtils.facebook").fromJSEnum(p.surface)),entry_point:p.entryPoint,lead_source:p.leadSource}},advertiserContext:{ad_account_id:f},fields:["FULL_NAME","COMPANY_NAME","EMAIL","PHONE"],isRescheduleCall:e},{fetchKey:r,fetchPolicy:"network-only"});r=(p=(g=q.sbg_engagement_eligible_programs)==null?void 0:g.programs)!=null?p:[];g=r.find(function(a){return a.channels.length>0});p=g==null?void 0:g.sbg_program_name;r=g==null?void 0:g.sub_program_name;g=g==null?void 0:(g=g.channels)==null?void 0:g.find(function(a){return a.type==="SCHEDULE_CALL"});if(e){e=(e=q.sbg_engagement_eligible_programs)==null?void 0:(e=e.existing_connections)==null?void 0:e[0];return j.jsx(m,{availabilities:g,entryPoint:n,existingConnectionDetailsKey:e,leadSource:i,surface:o})}return j.jsx(c("AdsOsmipMarketingProScheduleCallForm.react"),{accountID:(e=f)!=null?e:"",availabilities:g,entryPoint:n,leadSource:i,sbgPrefillKey:q==null?void 0:q.sbg_prefill_data,sbgProgramName:p,sbgSubProgramName:r,srtJobID:a==null?void 0:a.srtJobID,surface:o})}a.displayName=a.name+" [from "+f.id+"]";e=d("AdsFluxHooks").adsFluxContainer(a);g["default"]=e}),98);
-----
AdsHelpTrayContactMarketingProCancelCallButton.react",["fbt","AdsOsmipMarketingProScheduleCallUtils","BizKitMarketingExpertScheduleCallCancelConfirmationModal.react","GeoButton.react","react"],(function(a,b,c,d,e,f,g,h){"use strict";var i,j=i||(i=d("react")),k=i.useState;function a(a){var b=a.adAccountID,e=a.connectionID,f=a.refetch,g=a.sbgEntryPoint,i=a.sbgLeadSource;a=a.surface;var l=k(!1),m=l[0],n=l[1];return j.jsxs(j.Fragment,{children:[j.jsx(c("GeoButton.react"),{grow:"fill",label:h._("Cancel call"),onClick:function(){n(!0)}}),j.jsx(c("BizKitMarketingExpertScheduleCallCancelConfirmationModal.react"),{adAccountID:b,connectionID:e,isShown:m,sourceTracking:d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo(i,g,a),useAdsToasts:!0,onHide:function(){n(!1)},onMutation:f})]})}a.displayName=a.name+" [from "+f.id+"]";g["default"]=a}),226);
-----
AdsHelpTrayContactMarketingPro.react",["AdsHelpTrayContactMarketingProChatAction.react","AdsHelpTrayContactMarketingProExistingCallContent.react","AdsHelpTrayContactMarketingProScheduleCallAction.react","AdsHelpTrayContactMarketingProSolutionFragment.graphql","AdsHelpTrayMetaProDynamicContent","AdsHelpTrayUILogger","AdsOsmipMarketingProScheduleCallUtils","CRMMEProgram","GeoCard.react","GeoFlexbox.react","GeoHeading.react","Image.react","OsmipMiaFalcoEvent","RelayHooks","XFBOSMiPSolutionActionTypesEnumUtils.facebook","XFBOSMiPSolutionChannelsEnumUtils.facebook","adsGetOsmipToSBGChannelMapForLogging","adsOsmipGetCurrentSurfaceForLogging","geoMargin","getJSEnumSafe","logMetaProClick","logMetaProImpression","react"],(function(a,b,c,d,e,f,g){"use strict";var h,i,j=i||(i=d("react"));e=i;var k=e.useEffect,l=e.useRef;function m(a){return a==null?void 0:(a=a.existing_connections)==null?void 0:a[0]}function a(a){var e,f=a.accountID,g=a.marketingProSolutionFragmentKey;a=a.refetch;g=d("RelayHooks").useFragment(h!==void 0?h:h=b("AdsHelpTrayContactMarketingProSolutionFragment.graphql"),g);var i=g==null?void 0:g.solution_channels,n=c("adsOsmipGetCurrentSurfaceForLogging")(),p=l(!1);k(function(){if(i!=null&&p.current===!1){var a,b;p.current=!0;var e=i==null?void 0:i.map(function(a){return d("XFBOSMiPSolutionChannelsEnumUtils.facebook").toJSEnum(a.name)}).filter(Boolean);c("OsmipMiaFalcoEvent").log(function(){return{ad_account_id:f,channels:e,event:"marketing_pro_impression",event_data:{ctas_available:i.map(function(a){return a.label}).filter(Boolean).toString()},event_side:"client_side",objective:"general_help",solutions:["MarketingExpert"],surface:n}});d("AdsHelpTrayUILogger").logMarketingProShown();a=(a=i[0])==null?void 0:a.program_name;b=(b=i[0])==null?void 0:b.sub_program_name;c("logMetaProImpression")(d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo("OSMIP_HT_Entry_Point",void 0,n),"banner",{ad_account_id:f,channels:c("adsGetOsmipToSBGChannelMapForLogging")(e),program:c("getJSEnumSafe")(c("CRMMEProgram"),a),sub_program:b})}},[f,i,n]);if(i==null)return null;a=o(a,i,f,n);e=(e=m(i.find(function(a){return((a=a.action_object)==null?void 0:a.type)===d("XFBOSMiPSolutionActionTypesEnumUtils.facebook").fromJSEnum("schedule_call")})))==null?void 0:e.connection_object;g=babelHelpers["extends"]({},g);var q=g.solution_title,r=g.solution_description;g=g.image;r={description:r,title:q};q=d("AdsHelpTrayMetaProDynamicContent").buildDynamicContentPlugin(r);r=q.getTitle();q=q.getDescription();return j.jsx(c("GeoCard.react"),{xstyle:c("geoMargin").bottom16,children:j.jsxs(c("GeoFlexbox.react"),{direction:"column",gap:16,xstyle:c("geoMargin").all16,children:[j.jsx(c("GeoHeading.react"),{level:3,children:r}),j.jsx(c("GeoFlexbox.react"),{alignItems:"center",children:e!=null?j.jsx(c("AdsHelpTrayContactMarketingProExistingCallContent.react"),{existingConnectionDetailsKey:e}):j.jsxs(c("GeoFlexbox.react"),{alignItems:"center",direction:"row",children:[(g==null?void 0:g.uri)!=null&&j.jsx(c("Image.react"),{className:"x10w6t97 x1emribx x1td3qas",src:g==null?void 0:g.uri}),q]})}),j.jsxs(c("GeoFlexbox.react"),{gap:8,justifyContent:"space-between",children:[a==null?void 0:a[0],a==null?void 0:a[1]]})]})})}a.displayName=a.name+" [from "+f.id+"]";function n(a,b,e,f,g,h,i){d("AdsHelpTrayUILogger").logMarketingProClick(),c("OsmipMiaFalcoEvent").log(function(){var c;return{ad_account_id:a,channels:[e],entry_point:"ads_manager_help_tray",event:"marketing_pro_click",event_data:{cta_clicked:(c=f)!=null?c:"",ctas_available:b.map(function(a){return a.label}).filter(Boolean).toString()},event_side:"client_side",objective:"general_help",solutions:["MarketingExpert"],surface:i}}),c("logMetaProClick")(d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo("OSMIP_HT_Entry_Point",void 0,i),"banner",{ad_account_id:a,program:c("getJSEnumSafe")(c("CRMMEProgram"),g),sub_program:h,ui_element:e==="ALWAYS_ON_CHAT"?"start_chat":"request_call"})}function o(a,b,e,f){return b.map(function(g){var h;switch((h=g.action_object)==null?void 0:h.type){case d("XFBOSMiPSolutionActionTypesEnumUtils.facebook").fromJSEnum("schedule_call"):return j.jsx(c("AdsHelpTrayContactMarketingProScheduleCallAction.react"),{adAccountID:e,connectionID:(h=g.action_object)==null?void 0:(h=h.params)==null?void 0:h.existing_connection_id,ctaLabel:g.label,refetch:a,sbgEntryPoint:"ADS_MANAGER_MIA",sbgLeadSource:"OSMIP_HT_Entry_Point",surface:f,onClickLogging:function(){return n(e,b,"SCHEDULE_CALL",g.label,g.program_name,g.sub_program_name,f)}});case d("XFBOSMiPSolutionActionTypesEnumUtils.facebook").fromJSEnum("request_chat"):return j.jsx(c("AdsHelpTrayContactMarketingProChatAction.react"),{accountID:e,ctaLabel:g.label,existingThreadId:(h=m(g))==null?void 0:h.thread_id,program:c("getJSEnumSafe")(c("CRMMEProgram"),g.program_name),sbgEntryPoint:"ADS_MANAGER_MIA",sbgLeadSource:"OSMIP_HT_Entry_Point",onClick:function(){return n(e,b,"ALWAYS_ON_CHAT",g.label,g.program_name,g.sub_program_name,f)}});default:return null}})}g["default"]=a}),98);
-----
AdsOsmipMarketingProScheduleCallUtils",[],(function(a,b,c,d,e,f){"use strict";function a(a,b,c){a={surface:"ADS_MANAGER",entryPoint:(b=b)!=null?b:"ADS_MANAGER_MIA",leadSource:(b=a)!=null?b:"OSMIP_HT_Entry_Point"};return c!=null?babelHelpers["extends"]({subLeadSource:c},a):a}f.getSourceTrackingInfo=a}),66);
-----
AdsOsmipMarketingProRescheduleCall.react",["fbt","AdsGuidanceTrayHeader.react","AdsHelpTrayMarketingProUtils","AdsHelpTrayPopNavigationStackAction","AdsHelpTrayUILogger","AdsOsmipMarketingProRescheduleCall_availabilities.graphql","AdsOsmipMarketingProRescheduleCall_details.graphql","AdsOsmipMarketingProScheduleCallUtils","BizKitMarketingExpertRescheduleCallButton.react","BizKitMarketingExpertTimeslotPicker.react","DateTime","GeoBaseText.react","GeoCancelButton.react","GeoCard.react","GeoDatePicker.react","GeoFlexbox.react","GeoHeading.react","GeoSection.react","LocalDate","MarketingExpertWidgetTimezoneSelector.react","MarketingExpertWidgetUtils","RelayHooks","Timezone","bizKitMarketingExpertCallUtil","geoMargin","react"],(function(a,b,c,d,e,f,g,h){"use strict";var i,j,k=d("react");e=d("react");var l=e.useEffect,m=e.useState;function a(a){var e,g,n,o=a.existingConnectionDetailsKey,p=a.availabilities;a=a.leadSource;o=d("RelayHooks").useFragment(i!==void 0?i:i=b("AdsOsmipMarketingProRescheduleCall_details.graphql"),o);var q=d("Timezone").getEnvironmentTimezoneID();e=o==null?void 0:(e=o.connection_details)==null?void 0:e.time_frame;g=e==null?void 0:(g=e.start_time)==null?void 0:g.timestamp;e=e==null?void 0:(e=e.end_time)==null?void 0:e.timestamp;p=d("RelayHooks").useFragment(j!==void 0?j:j=b("AdsOsmipMarketingProRescheduleCall_availabilities.graphql"),p);var r=p==null?void 0:(p=p.availabilities[0])==null?void 0:p.slots;p=d("bizKitMarketingExpertCallUtil").getDateToTimeslots(r,q);var s=m(q),t=s[0];s=s[1];var u=p==null?null:c("LocalDate").fromISOString(p[0].dateString);n=p==null?void 0:(n=p[0].timeslot)==null?void 0:n[0];u=m((u=u)!=null?u:c("LocalDate").today(q));var v=u[0],w=u[1];u=m(n);n=u[0];var x=u[1];u=m(p);var y=u[0],z=u[1];l(function(){var a=d("bizKitMarketingExpertCallUtil").getDateToTimeslots(r,t);z(a)},[t,r]);l(function(){var a;a=y==null?void 0:(a=y.find(function(a){return a.dateString===(v==null?void 0:v.toISOString())}))==null?void 0:a.timeslot;a!=null&&x(a[0])},[v,y]);if(g==null||e==null)return null;p=c("DateTime").create(g,q);u=c("DateTime").create(e,q);var A=function(a){var b;b=y==null?void 0:(b=y.find(function(b){return b.dateString===(a==null?void 0:a.toISOString())}))==null?void 0:b.timeslot;b!=null&&x(b[0])};return k.jsxs(k.Fragment,{children:[k.jsx(c("AdsGuidanceTrayHeader.react"),{contentType:"SCHEDULE_MARKETING_CALL",density:"cozy",heading:h._("u91cdu65b0u9884u7ea6 Meta u4e13u4e1au8425u9500u4f19u4f34u901au8bdd"),showBackButton:!0}),k.jsx(c("GeoCard.react"),{children:k.jsxs(c("GeoSection.react"),{children:[k.jsxs(c("GeoFlexbox.react"),{direction:"column",xstyle:c("geoMargin").all8,children:[k.jsx(c("GeoBaseText.react"),{color:"inherit",size:"valueDescription",weight:"bold",children:h._("u5f53u524du9009u62e9")}),k.jsx(c("GeoHeading.react"),{level:1,children:d("MarketingExpertWidgetUtils").getFormattedDateFbt(p)}),k.jsx(c("GeoBaseText.react"),{color:"inherit",size:"valueDescription",xstyle:c("geoMargin").top8,children:h._("{start_time}{duration}",[h._param("start_time",d("MarketingExpertWidgetUtils").getFormattedTimeFbt(p,q)),h._param("duration",d("AdsHelpTrayMarketingProUtils").getDurationFbt(p,u))])})]}),k.jsxs(c("GeoFlexbox.react"),{alignItems:"end",direction:"row",gap:8,justifyContent:"space-between",xstyle:[c("geoMargin").top16,c("geoMargin").horiz8],children:[k.jsx(c("GeoDatePicker.react"),{label:h._("u65e5u671f"),restraint:function(a){return(y==null?void 0:y.find(function(b){return a.equals(c("LocalDate").fromISOString(b.dateString))}))!=null},value:v,onChange:function(a){A(a);w((a=a)!=null?a:c("LocalDate").today(t))}}),k.jsx(c("MarketingExpertWidgetTimezoneSelector.react"),{value:t,onChange:s})]}),k.jsx(c("GeoFlexbox.react"),{xstyle:[c("geoMargin").top16,c("geoMargin").horiz8],children:k.jsx(c("BizKitMarketingExpertTimeslotPicker.react"),{selectedTimeslot:n,setSelectedTimeslot:x,timeslots:y==null?void 0:(g=y.find(function(a){return a.dateString===(v==null?void 0:v.toISOString())}))==null?void 0:g.timeslot,timezoneID:t})}),k.jsxs(c("GeoFlexbox.react"),{justifyContent:"end",xstyle:[c("geoMargin").top16,c("geoMargin").horiz8],children:[k.jsx(c("GeoCancelButton.react"),{xstyle:c("geoMargin").end8,onClick:function(){d("AdsHelpTrayUILogger").logBackButtonClick("SCHEDULE_MARKETING_CALL"),c("AdsHelpTrayPopNavigationStackAction").dispatch({},{line:"245",module:"AdsOsmipMarketingProRescheduleCall.react.js",moduleID:f.id})}}),k.jsx(c("BizKitMarketingExpertRescheduleCallButton.react"),{connectionID:o==null?void 0:o.id,sourceTracking:d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo(a),timeslot:n,useAdsToasts:!0,onMutation:function(){return c("AdsHelpTrayPopNavigationStackAction").dispatch({},{line:"254",module:"AdsOsmipMarketingProRescheduleCall.react.js",moduleID:f.id})}})]})]})})]})}a.displayName=a.name+" [from "+f.id+"]";g["default"]=a}),98);
-----
AdsHelpTrayContactMarketingProCancelCallButton.react",["fbt","AdsOsmipMarketingProScheduleCallUtils","BizKitMarketingExpertScheduleCallCancelConfirmationModal.react","GeoButton.react","react"],(function(a,b,c,d,e,f,g,h){"use strict";var i=d("react"),j=d("react").useState;function a(a){var b=a.adAccountID,e=a.connectionID,f=a.sbgLeadSource;a=a.refetch;var g=j(!1),k=g[0],l=g[1];return i.jsxs(i.Fragment,{children:[i.jsx(c("GeoButton.react"),{grow:"fill",label:h._("u53d6u6d88u901au8bdd"),onClick:function(){l(!0)}}),i.jsx(c("BizKitMarketingExpertScheduleCallCancelConfirmationModal.react"),{adAccountID:b,connectionID:e,isShown:k,sourceTracking:d("AdsOsmipMarketingProScheduleCallUtils").getSourceTrackingInfo(f),useAdsToasts:!0,onHide:function(){l(!1)},onMutation:a})]})}a.displayName=a.name+" [from "+f.id+"]";g["default"]=a}),98);
-----
AdsOsmipMarketingProScheduleCallUtils",[],(function(a,b,c,d,e,f){"use strict";function a(a){return{surface:"ADS_MANAGER",entryPoint:"ADS_MANAGER_MIA",leadSource:(a=a)!=null?a:"OSMIP_HT_Entry_Point"}}f.getSourceTrackingInfo=a}),66);
-----