BusinessAccountSelfDemotionFrictionModal.react",["fbt","$InternalEnum","BusinessAccountFullControlPermissionRemovedWarning.react","BusinessAccountSelfDemotionFrictionAssetsList.react","BusinessAccountSelfDemotionFrictionModalQuery.graphql","CometPlaceholder.react","GeoButton.react","GeoFlexbox.react","GeoGlimmer.react","GeoHStack.react","GeoModal.react","GeoModalFooter.react","GeoModalHeader.react","GeoSection.react","GeoText.react","GeoTextLoadingState.react","GeoVStack.react","RelayHooks","geoMargin","react","react-compiler-runtime","useBizKitSettingsLogger","useCountdownSeconds"],(function(ne,q,n,v,te,y,z,s){"use strict";var p,L,t=L||(L=v("react")),j=L,ie=j.useCallback,re=j.useMemo,V=j.useState,i=q("$InternalEnum").Mirrored(["ASSET_IMPACT","TIMED_FINAL_CONFIRMATION"]);function U(d){var e=v("react-compiler-runtime").c(37),u=d.props,c=d.queries,M=u.businessID,m=u.isLoading,l=u.onConfirm,r=u.onHide,S=u.setSelectedTaskIDs,_=u.updatedTaskIDs,o=Z(M),X=p!==void 0?p:p=q("BusinessAccountSelfDemotionFrictionModalQuery.graphql"),w=v("RelayHooks").usePreloadedQuery(X,c.BusinessAccountSelfDemotionFrictionModalQuery),$=V(i.ASSET_IMPACT),A=$[0],F=$[1],K=V(!1),N=K[0],ee=K[1],I;e[0]!==o||e[1]!==r?(I=function(){F(i.ASSET_IMPACT),r("escape"),o.logCancel({extra_information:{modal_step:i.ASSET_IMPACT}})},e[0]=o,e[1]=r,e[2]=I):I=e[2];var k=I,C;e[3]!==o||e[4]!==r?(C=function(){F(i.ASSET_IMPACT),r("escape"),o.logFlowExit({extra_information:{modal_step:i.ASSET_IMPACT}})},e[3]=o,e[4]=r,e[5]=C):C=e[5];var J=C,x;e[6]!==o?(x=function(){F(i.TIMED_FINAL_CONFIRMATION),o.logFlowContinue({extra_information:{modal_step:i.ASSET_IMPACT}})},e[6]=o,e[7]=x):x=e[7];var b=x,H;e[8]!==o||e[9]!==l||e[10]!==S||e[11]!==_?(H=function(){_!=null&&S(_),l(),o.logFlowSuccess(),o.logFlowContinue({extra_information:{modal_step:i.TIMED_FINAL_CONFIRMATION}})},e[8]=o,e[9]=l,e[10]=S,e[11]=_,e[12]=H):H=e[12];var P=H,a=n("useCountdownSeconds")(W,A===i.TIMED_FINAL_CONFIRMATION?30:null),T;e[13]!==o||e[14]!==r||e[15]!==a?(T=function(){var f;F(i.ASSET_IMPACT),r("escape"),o.logCancel({extra_information:{modal_step:i.TIMED_FINAL_CONFIRMATION,time_remaining:(f=a==null?void 0:a.toString())!=null?f:"0"}})},e[13]=o,e[14]=r,e[15]=a,e[16]=T):T=e[16];var R=T,E;e[17]!==o||e[18]!==r||e[19]!==a?(E=function(){var f;F(i.ASSET_IMPACT),r("escape"),o.logFlowExit({extra_information:{modal_step:i.TIMED_FINAL_CONFIRMATION,time_remaining:(f=a==null?void 0:a.toString())!=null?f:"0"}})},e[17]=o,e[18]=r,e[19]=a,e[20]=E):E=e[20];var O=E,h;e[21]!==P?(h=function(){ee(!0),P()},e[21]=P,e[22]=h):h=e[22];var D=h,G=a!=null&&a>0,B;if(e[23]!==A||e[24]!==D||e[25]!==N||e[26]!==G||e[27]!==m||e[28]!==o||e[29]!==b||e[30]!==k||e[31]!==R||e[32]!==J||e[33]!==O||e[34]!==w||e[35]!==a){var Q;B=A===i.ASSET_IMPACT?t.jsx(n("GeoModal.react"),{footer:t.jsx(n("GeoModalFooter.react"),{primaryButton:t.jsx(n("GeoButton.react"),{label:s._(/*BTDS*/""),onClick:b,variant:"primary"}),secondaryButton:t.jsx(n("GeoButton.react"),{label:s._(/*BTDS*/""),onClick:k})}),header:t.jsx(n("GeoModalHeader.react"),{description:s._(/*BTDS*/""),heading:s._(/*BTDS*/"")}),onEnterComplete:function(){o.logImpression(),o.logFlowEnter()},onHide:J,children:t.jsx(n("GeoSection.react"),{children:t.jsx(n("GeoFlexbox.react"),{xstyle:n("geoMargin").bottom24,children:t.jsx(n("CometPlaceholder.react"),{fallback:t.jsx(Y,{}),name:y.id,children:t.jsx(n("BusinessAccountSelfDemotionFrictionAssetsList.react"),{business:w.business})})})})}):A===i.TIMED_FINAL_CONFIRMATION?t.jsx(n("GeoModal.react"),{footer:t.jsx(n("GeoModalFooter.react"),{primaryButton:t.jsx(n("GeoButton.react"),{"data-testid":void 0,isDisabled:G,isLoading:N||m,label:s._(/*BTDS*/""),onClick:D,variant:"primary"}),secondaryButton:t.jsx(n("GeoButton.react"),{"data-testid":void 0,label:s._(/*BTDS*/""),onClick:R}),startContent:G?t.jsx(n("GeoText.react"),{children:(Q=s._plural(a!=null?a:0),s._(/*BTDS*/"",[Q,s._implicitParam("=m2",t.jsx("strong",{children:s._(/*BTDS*/"",[Q,s._param("timeRemaining",a)])}))]))}):null}),header:t.jsx(n("GeoModalHeader.react"),{description:s._(/*BTDS*/""),heading:s._(/*BTDS*/"")}),onEnterComplete:function(){o.logImpression(),o.logFlowEnter()},onHide:O,children:t.jsx(n("GeoSection.react"),{children:t.jsx(n("BusinessAccountFullControlPermissionRemovedWarning.react"),{})})}):(function(){throw Error("Match: No case succesfully matched. Make exhaustive or add a wildcard case using '_'. Argument: "+A)})(),e[23]=A,e[24]=D,e[25]=N,e[26]=G,e[27]=m,e[28]=o,e[29]=b,e[30]=k,e[31]=R,e[32]=J,e[33]=O,e[34]=w,e[35]=a,e[36]=B}else B=e[36];return B}function W(){}function Y(){var d=v("react-compiler-runtime").c(1),e;return d[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(n("GeoVStack.react"),{children:t.jsxs(n("GeoHStack.react"),{alignItems:"center",context:"component",relation:"unrelated",children:[t.jsx(n("GeoFlexbox.react"),{shrink:0,children:t.jsx(n("GeoGlimmer.react"),{height:48,shape:"rectangle",width:48,loggingName:y.id})}),t.jsx(n("GeoTextLoadingState.react"),{lines:2,loggingName:y.id})]})}),d[0]=e):e=d[0],e}function Z(d){var e=v("react-compiler-runtime").c(3),u=n("useBizKitSettingsLogger")(d),c=u.logEvent,M,m;e[0]===Symbol.for("react.memo_cache_sentinel")?(m={eventLocation:"bizweb_settings_people_tab",flowType:"self_demotion"},e[0]=m):m=e[0],M=m;var l=M,r,S;return e[1]!==c?(S={logCancel:function(o){return c("self_demotion_cancel",l,o)},logFlowContinue:function(o){return c("self_demotion_continue",l,o)},logFlowEnter:function(){return c("self_demotion_start",l)},logFlowExit:function(o){return c("self_demotion_exit",l,o)},logFlowSuccess:function(){return c("self_demotion_success",l)},logImpression:function(){return c("self_demotion_impression",l)}},e[1]=c,e[2]=S):S=e[2],r=S,r}z.default=U}),226);
-----
BusinessAccountSelfDemotionFrictionModalQuery.graphql",["BusinessAccountSelfDemotionFrictionModalQuery_facebookRelayOperation","relay-runtime"],(function(u,n,o,d,r,c){"use strict";var e=(function(){var a=[{defaultValue:["AD_ACCOUNT","PAGE","INSTAGRAM_ACCOUNT_V2","WHATSAPP_BUSINESS_ACCOUNT","BUSINESS_RESOURCE_GROUP"],kind:"LocalArgument",name:"assetTypes"},{defaultValue:null,kind:"LocalArgument",name:"businessID"},{defaultValue:4,kind:"LocalArgument",name:"count"},{defaultValue:null,kind:"LocalArgument",name:"cursor"}],l=[{kind:"Variable",name:"id",variableName:"businessID"}],s=[{kind:"Variable",name:"after",variableName:"cursor"},{kind:"Variable",name:"asset_types",variableName:"assetTypes"},{kind:"Variable",name:"first",variableName:"count"},{fields:[{kind:"Literal",name:"is_owned_by_business",value:!0},{kind:"Literal",name:"is_owned_by_partners",value:!1},{kind:"Variable",name:"owning_business_id",variableName:"businessID"}],kind:"ObjectValue",name:"global_filters"}],i={alias:null,args:null,kind:"ScalarField",name:"id",storageKey:null};return{fragment:{argumentDefinitions:a,kind:"Fragment",metadata:{throwOnFieldError:!0},name:"BusinessAccountSelfDemotionFrictionModalQuery",selections:[{kind:"RequiredField",field:{alias:null,args:l,concreteType:"AdBusiness",kind:"LinkedField",name:"business",plural:!1,selections:[{args:[{kind:"Variable",name:"assetTypes",variableName:"assetTypes"},{kind:"Variable",name:"businessID",variableName:"businessID"},{kind:"Variable",name:"count",variableName:"count"},{kind:"Variable",name:"cursor",variableName:"cursor"}],kind:"FragmentSpread",name:"BusinessAccountSelfDemotionFrictionAssetsList_business"}],storageKey:null},action:"THROW",path:"business"}],type:"Query",abstractKey:null},kind:"Request",operation:{argumentDefinitions:a,kind:"Operation",name:"BusinessAccountSelfDemotionFrictionModalQuery",selections:[{alias:null,args:l,concreteType:"AdBusiness",kind:"LinkedField",name:"business",plural:!1,selections:[{alias:null,args:null,kind:"ScalarField",name:"name",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"profile_picture_url",storageKey:null},{alias:null,args:s,concreteType:"AdBusinessConnectedObjectsConnection",kind:"LinkedField",name:"connected_objects",plural:!1,selections:[{alias:null,args:null,concreteType:"AdBusinessConnectedObjectsEdge",kind:"LinkedField",name:"edges",plural:!0,selections:[{alias:null,args:null,concreteType:null,kind:"LinkedField",name:"node",plural:!1,selections:[{alias:null,args:null,kind:"ScalarField",name:"__typename",storageKey:null},{kind:"InlineFragment",selections:[{alias:null,args:null,kind:"ScalarField",name:"business_asset_type",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"business_object_ui_id",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"business_object_name",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"business_object_picture",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"business_object_is_verified",storageKey:null}],type:"BusinessObjectRenderedInUI",abstractKey:"__isBusinessObjectRenderedInUI"},{kind:"InlineFragment",selections:[i],type:"Node",abstractKey:"__isNode"}],storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"cursor",storageKey:null}],storageKey:null},{alias:null,args:null,concreteType:"PageInfo",kind:"LinkedField",name:"page_info",plural:!1,selections:[{alias:null,args:null,kind:"ScalarField",name:"end_cursor",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"has_next_page",storageKey:null}],storageKey:null}],storageKey:null},{alias:null,args:s,filters:["asset_types","global_filters"],handle:"connection",key:"BusinessAssets_connected_objects",kind:"LinkedHandle",name:"connected_objects"},i],storageKey:null}]},params:{id:n("BusinessAccountSelfDemotionFrictionModalQuery_facebookRelayOperation"),metadata:{},name:"BusinessAccountSelfDemotionFrictionModalQuery",operationKind:"query",text:null}}})();n("relay-runtime").PreloadableQueryRegistry.set(e.params.id,e),r.exports=e}),null);
-----
BusinessAccountSelfDemotionFrictionModal.entrypoint",["BusinessAccountSelfDemotionFrictionModalQuery$Parameters","JSResourceForInteraction"],(function(u,e,o,c,a,l,t){"use strict";var n={getPreloadProps:function(i){var s=i.businessID;return{entryPoints:{},queries:{BusinessAccountSelfDemotionFrictionModalQuery:{parameters:e("BusinessAccountSelfDemotionFrictionModalQuery$Parameters"),variables:{businessID:s,count:4}}}}},root:o("JSResourceForInteraction")("BusinessAccountSelfDemotionFrictionModal.react").__setRef("BusinessAccountSelfDemotionFrictionModal.entrypoint")};t.default=n}),98);
-----
BusinessAccountSelfDemotionFrictionModalQuery$Parameters",["BusinessAccountSelfDemotionFrictionModalQuery_facebookRelayOperation"],(function(i,e,a,r,o,u){"use strict";var n={kind:"PreloadableConcreteRequest",params:{id:e("BusinessAccountSelfDemotionFrictionModalQuery_facebookRelayOperation"),metadata:{},name:"BusinessAccountSelfDemotionFrictionModalQuery",operationKind:"query",text:null}};o.exports=n}),null);
-----
BusinessAccountSelfDemotionFrictionModalQuery_facebookRelayOperation",[],(function(i,n,r,u,e,a){e.exports="9737836402984908"}),null);
-----