if (self.CavalryLogger) { CavalryLogger.start_js(["vVJOd"]); } __d("ExpirationTypeToExpirationTypeApiMap",[],(function(a,b,c,d,e,f){e.exports={0:"none",1:"expire_and_delete",2:"expire_only",3:"expire_to_only_me"}}),null); __d("InstreamAdsBlockListCategoryMaps",[],(function(a,b,c,d,e,f){e.exports={CategoryTypeToNameMap:{0:"CATEGORY_ARTS",1:"CATEGORY_AUTOS_AND_VEHICLES",2:"CATEGORY_AUTOS",3:"CATEGORY_BOATS",4:"CATEGORY_MOTORCYCLES",5:"CATEGORY_BEAUTY_AND_FASHION",6:"CATEGORY_FASHION",7:"CATEGORY_PERSONAL_CARE",8:"CATEGORY_BOOKS_AND_LITERATURE",9:"CATEGORY_BUSINESS",10:"CATEGORY_SERVICES",11:"CATEGORY_INDUSTRIAL",12:"CATEGORY_SMALL_BUSINESS_DEPRECATED",13:"CATEGORY_COMPUTERS",14:"CATEGORY_DATING",15:"CATEGORY_EDUCATION",16:"CATEGORY_COMPUTERS_AND_ELECTRONICS",17:"CATEGORY_AUDIO_AND_VIDEO_EQUIPMENT",18:"CATEGORY_CAMERA_PHOTO",19:"CATEGORY_GAME_SYSTEMS_DEPRECATED",20:"CATEGORY_PORTABLE_ELECTRONICS",21:"CATEGORY_VIDEO_EQUIPMENT_DEPRECATED",22:"CATEGORY_ARTS_AND_ENTERTAINMENT",23:"CATEGORY_MOVIE",24:"CATEGORY_TELEVISION",25:"CATEGORY_MUSIC",26:"CATEGORY_RADIO",27:"CATEGORY_PERFORMING_ARTS",28:"CATEGORY_EVENT_LISTINGS",29:"CATEGORY_FINANCE",30:"CATEGORY_BANKING",31:"CATEGORY_CREDIT_CARD",32:"CATEGORY_LOANS",33:"CATEGORY_INSURANCE",34:"CATEGORY_INVESTING",35:"CATEGORY_FOOD",36:"CATEGORY_BEVERAGES",37:"CATEGORY_ALCOHOL",38:"CATEGORY_CUISINE",39:"CATEGORY_RESTAURANTS",40:"CATEGORY_GAMBLING",41:"CATEGORY_GAMES",42:"CATEGORY_HEALTH_AND_FITNESS",43:"CATEGORY_DRUGS_AND_SUPPLEMENTS",44:"CATEGORY_REPRODUCTIVE_HEALTH",45:"CATEGORY_FITNESS",46:"CATEGORY_HOBBIES_AND_LEISURE",47:"CATEGORY_SPECIAL_OCCASIONS",48:"CATEGORY_HOME_AND_GARDEN",49:"CATEGORY_INTERNET_TELECOM",50:"CATEGORY_JOBS",51:"CATEGORY_LAW_GOVERNMENT_POLITICS",52:"CATEGORY_NEWS",53:"CATEGORY_PARENTING",54:"CATEGORY_CHILDCARE",55:"CATEGORY_PREGNANCY",56:"CATEGORY_RELIGION_AND_SPIRITUAL",57:"CATEGORY_SOCIAL_ISSUES_AND_ADVOCACY",58:"CATEGORY_PETS_AND_ANIMAL_CARE",59:"CATEGORY_REAL_ESTATE",60:"CATEGORY_SHOPPING",61:"CATEGORY_APPAREL",62:"CATEGORY_JEWELRY_AND_ACCESSORIES",63:"CATEGORY_ACCESSORIES_DEPRECATED",64:"CATEGORY_FOOTWEAR",65:"CATEGORY_ENTERTAINMENT_MEDIA_DEPRECATED",66:"CATEGORY_LUXURY_GOODS_DEPRECATED",67:"CATEGORY_TOYS",68:"CATEGORY_SPORTS",69:"CATEGORY_TRAVEL",70:"CATEGORY_HOTELS",71:"CATEGORY_AIR_TRAVEL",72:"CATEGORY_BUS_RAIL",73:"CATEGORY_CAR_RENTAL_TAXI",74:"CATEGORY_CRUISES",75:"CATEGORY_SPECIALTY_TRAVEL_DEPRECATED",76:"CATEGORY_DESTINATION_SERVICES",77:"CATEGORY_OTHER",78:"CATEGORY_APPLICATIONS_AND_SOFTWARE",79:"CATEGORY_PHONE",80:"CATEGORY_PAYMENT_PROCESSORS",81:"CATEGORY_DIGITAL_GAMES",82:"CATEGORY_NON_DIGITAL_GAMES",83:"CATEGORY_REAL_ESTATE_HOME",84:"CATEGORY_REAL_ESTATE_RENTAL",85:"CATEGORY_GIFT_CARDS_AND_DISCOUNTS",86:"CATEGORY_WEAPONS",87:"CATEGORY_VIOLENCE",88:"CATEGORY_SEXUAL",89:"CATEGORY_MATURE",90:"CATEGORY_DIGITAL_GAMES_CARD",91:"CATEGORY_DIGITAL_GAMES_WORD",92:"CATEGORY_DIGITAL_GAMES_SOCIAL_CASINO",93:"CATEGORY_DIGITAL_GAMES_CASUAL",94:"CATEGORY_DIGITAL_GAMES_DRIVING_RACING",95:"CATEGORY_DIGITAL_GAMES_OTHER",96:"CATEGORY_LAST"},CategoryParentToChildMap:{1:[2,3,4],5:[6,7],9:[10,11],16:[17,18,13,79,20],22:[0,23,24,25,26,27,28],29:[30,31,32,33,34,80],35:[36,37,38,39],42:[43,44,45],53:[54,55],60:[61,62,64,67,85],69:[70,71,72,73,74,76],41:[81,82],59:[83,84],81:[90,91,92,93,94,95],8:[],14:[],15:[],40:[],46:[],47:[],48:[],49:[],50:[],51:[],52:[],56:[],57:[],58:[],68:[],77:[],78:[],86:[],87:[],88:[],89:[]},CategoryChildToParentMap:{2:1,3:1,4:1,6:5,7:5,10:9,11:9,17:16,18:16,13:16,79:16,20:16,0:22,23:22,24:22,25:22,26:22,27:22,28:22,30:29,31:29,32:29,33:29,34:29,80:29,36:35,37:35,38:35,39:35,43:42,44:42,45:42,54:53,55:53,61:60,62:60,64:60,67:60,70:69,71:69,72:69,73:69,74:69,76:69,81:41,82:41,83:59,84:59,85:60,90:81,91:81,92:81,93:81,94:81,95:81},NotCategorized:77,DerivedCreatorSensitiveCategories:{10001:"UNKNOWN",10002:"ALCOHOL_AND_RELATED_BEVERAGES",10003:"POLITICAL_DISCLOSURES",10004:"ADULT_HEALTH"}}}),null); __d("VideoCopyrightMatchValidStates",[],(function(a,b,c,d,e,f){e.exports={UNVERIFIED:"UNVERIFIED",VERIFIED_ALLOWED:"VERIFIED_ALLOWED",MANUAL_REVIEW:"MANUAL_REVIEW",REMOVED_FROM_DASHBOARD:"REMOVED_FROM_DASHBOARD",RESTORED_BY_PUBLISHER:"RESTORED_BY_PUBLISHER",VERIFIED_STAGED:"VERIFIED_STAGED",BLOCKED:"BLOCKED",VERIFIED_CLAIMED:"VERIFIED_CLAIMED",DISPUTED:"DISPUTED",DISPUTED_WITHOUT_UNBLOCKING:"DISPUTED_WITHOUT_UNBLOCKING",APPEALED_WITHOUT_UNBLOCKING:"APPEALED_WITHOUT_UNBLOCKING",DISPUTE_BLOCK:"DISPUTE_BLOCK",CLAIM_RELEASED:"CLAIM_RELEASED",EXPIRED:"EXPIRED",VERIFIED_REPORTED:"VERIFIED_REPORTED",RETRACTED:"RETRACTED",OPS_APPROVE_TAKE_DOWN:"OPS_APPROVE_TAKE_DOWN",APPEALED:"APPEALED",CLAIM_UPHELD:"CLAIM_UPHELD",PENDING_CLAIMED:"PENDING_CLAIMED"}}),null); __d("VideoFeedType",[],(function(a,b,c,d,e,f){e.exports={NOT_HIGHLIGHTED:{name:"NOT_HIGHLIGHTED",index:0},HIGHLIGHTED:{name:"HIGHLIGHTED",index:1}}}),null); __d("AdsCommonTargetingTargetingChangeActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"ADS_COMMON_TARGETING.TARGETING_CHANGE"}}),null); __d("AdsCommonTargetingTargetingClearAllDataActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"ADS_COMMON_TARGETING.TARGETING_CLEAR_ALL"}}),null); __d("AdsCommonTargetingTargetingInitDataActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"ADS_COMMON_TARGETING.TARGETING_INIT"}}),null); __d("AdsCommonTargetingTargetingSetFromExternalDataActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"ADS_COMMON_TARGETING.TARGETING_SET_FROM_EXTERNAL"}}),null); __d("AdsTargetingClearTargetingSpecStoreDataActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"CLEAR_TARGETING_SPEC_STORE"}}),null); __d("AdsTargetingLoadTimeInitTargetingContainerActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"INIT_TARGETING_CONTAINER"}}),null); __d("AdsTargetingResetMixStateComponentDataActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"RESET_MIX_STATE_COMPONENT"}}),null); __d("AdsTargetingSetTargetingApiSpecDataActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"SET_TARGETING_API_SPEC"}}),null); __d("AdsTargetingSetTargetingBulkApiSpecDataActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"SET_TARGETING_BULK_API_SPEC"}}),null); __d("AdsTargetingUpdateTargetingSpecDataActionFlux",[],(function(a,b,c,d,e,f){"use strict";e.exports={actionType:"UPDATE_TARGETING_SPEC"}}),null); __d("PageContentTabExternalCreateAdsFromPostsReducerPlugin",[],(function(a,b,c,d,e,f){"use strict";a={reduce:function(a,b){return a.merge({creationStartLevel:"campaign",isCreationModeChooserShown:!1,quickCreateSource:null,quickCreateStarted:!0})}};e.exports=a}),null); __d("PageContentTabExternalCreateAdsFromPostsAction",["Laminar","AdsCFExternalCreationLoadConfirmationDialogReducerPlugin","AdsCFExternalCreationConfirmationDialogUIDataProvider","PageContentTabExternalCreateAdsFromPostsReducerPlugin","AdsPECreationUIProvider","ifRequired"],(function(a,b,c,d,e,f){"use strict";a=b("Laminar").__createAction(function(){return[b("Laminar").__createReducer(b("AdsCFExternalCreationLoadConfirmationDialogReducerPlugin"),b("AdsCFExternalCreationConfirmationDialogUIDataProvider"),{}),b("Laminar").__createReducer(b("PageContentTabExternalCreateAdsFromPostsReducerPlugin"),b("AdsPECreationUIProvider"),{})]},function(){return[b("ifRequired")("PageContentTabExternalActionLoggerPlugin",function(a){return b("Laminar").__createLogger("PageContentTabExternalActionLoggerPlugin",a,{},["AdsMgmtRegistry"])})]},"PagesContentTab.CREATE_ADS_FROM_POSTS");e.exports=a}),null); __d("ModernScheduledVideoAnnouncementSubscribeMutation.graphql",[],(function(a,b,c,d,e,f){"use strict";a=function(){var a=[{kind:"LocalArgument",name:"input",type:"ScheduledVideoAnnouncementSubscribeData!",defaultValue:null}],b=[{kind:"LinkedField",alias:null,name:"scheduled_video_announcement_subscribe",storageKey:null,args:[{kind:"Variable",name:"data",variableName:"input"}],concreteType:"ScheduledVideoAnnouncementSubscribeResponsePayload",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"subscribed",args:null,storageKey:null}]}];return{kind:"Request",fragment:{kind:"Fragment",name:"ModernScheduledVideoAnnouncementSubscribeMutation",type:"Mutation",metadata:null,argumentDefinitions:a,selections:b},operation:{kind:"Operation",name:"ModernScheduledVideoAnnouncementSubscribeMutation",argumentDefinitions:a,selections:b},params:{operationKind:"mutation",name:"ModernScheduledVideoAnnouncementSubscribeMutation",id:"1625878820778072",text:null,metadata:{}}}}();e.exports=a}),null); __d("PageContentTabPublishedPagePostSearchDataFetcherQuery.graphql",[],(function(a,b,c,d,e,f){"use strict";a=function(){var a=[{kind:"LocalArgument",name:"pageID",type:"ID!",defaultValue:null},{kind:"LocalArgument",name:"count",type:"Int",defaultValue:null},{kind:"LocalArgument",name:"after",type:"ID!",defaultValue:null},{kind:"LocalArgument",name:"message",type:"String",defaultValue:null}],b=[{kind:"Variable",name:"id",variableName:"pageID"}],c=[{kind:"ScalarField",alias:null,name:"uri",args:null,storageKey:null}],d={kind:"LinkedField",alias:null,name:"featurable_image",storageKey:null,args:null,concreteType:"Image",plural:!1,selections:c},e=[{kind:"Variable",name:"after",variableName:"after"},{kind:"Variable",name:"first",variableName:"count"},{kind:"Variable",name:"post_content",variableName:"message"}],f={kind:"LinkedField",alias:null,name:"page_info",storageKey:null,args:null,concreteType:"PageInfo",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"end_cursor",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"has_next_page",args:null,storageKey:null}]},g={kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null},h=[{kind:"ScalarField",alias:null,name:"text",args:null,storageKey:null}],i={kind:"LinkedField",alias:null,name:"title",storageKey:null,args:null,concreteType:"TextWithEntities",plural:!1,selections:h},j={kind:"ScalarField",alias:null,name:"post_id",args:null,storageKey:null},k={kind:"ScalarField",alias:null,name:"creation_time",args:null,storageKey:null},l=[{kind:"Literal",name:"first",value:1}];c={kind:"LinkedField",alias:null,name:"image",storageKey:null,args:null,concreteType:"Image",plural:!1,selections:c};var m={kind:"LinkedField",alias:null,name:"media",storageKey:null,args:null,concreteType:null,plural:!1,selections:[c]},n={kind:"ScalarField",alias:null,name:"name",args:null,storageKey:null},o={kind:"LinkedField",alias:null,name:"edit_history",storageKey:null,args:null,concreteType:"EditHistoryConnection",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"EditAction",plural:!0,selections:[g,{kind:"ScalarField",alias:null,name:"time",args:null,storageKey:null}]}]};h={kind:"LinkedField",alias:null,name:"message",storageKey:null,args:null,concreteType:"TextWithEntities",plural:!1,selections:h};var p={kind:"LinkedField",alias:null,name:"insights",storageKey:null,args:null,concreteType:"StoryInsights",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"engaged_user_count",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"total_reach",args:null,storageKey:null}]},q={kind:"ScalarField",alias:null,name:"__typename",args:null,storageKey:null};c={kind:"LinkedField",alias:null,name:"media",storageKey:null,args:null,concreteType:null,plural:!1,selections:[q,c,g]};return{kind:"Request",fragment:{kind:"Fragment",name:"PageContentTabPublishedPagePostSearchDataFetcherQuery",type:"Query",metadata:null,argumentDefinitions:a,selections:[{kind:"LinkedField",alias:null,name:"page",storageKey:null,args:b,concreteType:"Page",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"profile_photo",storageKey:null,args:null,concreteType:"Photo",plural:!1,selections:[d]},{kind:"LinkedField",alias:null,name:"page_posts_search",storageKey:null,args:e,concreteType:"PagePostsSearchConnection",plural:!1,selections:[f,{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"Story",plural:!0,selections:[g,i,j,k,{kind:"LinkedField",alias:null,name:"attachments",storageKey:null,args:null,concreteType:"StoryAttachment",plural:!0,selections:[{kind:"LinkedField",alias:null,name:"all_subattachments",storageKey:"all_subattachments(first:1)",args:l,concreteType:"SubattachmentsConnection",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"StoryAttachment",plural:!0,selections:[m]}]},m]},{kind:"LinkedField",alias:null,name:"underlying_admin_creator",storageKey:null,args:null,concreteType:null,plural:!1,selections:[n]},o,h,p]}]}]}]},operation:{kind:"Operation",name:"PageContentTabPublishedPagePostSearchDataFetcherQuery",argumentDefinitions:a,selections:[{kind:"LinkedField",alias:null,name:"page",storageKey:null,args:b,concreteType:"Page",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"profile_photo",storageKey:null,args:null,concreteType:"Photo",plural:!1,selections:[d,g]},{kind:"LinkedField",alias:null,name:"page_posts_search",storageKey:null,args:e,concreteType:"PagePostsSearchConnection",plural:!1,selections:[f,{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"Story",plural:!0,selections:[g,i,j,k,{kind:"LinkedField",alias:null,name:"attachments",storageKey:null,args:null,concreteType:"StoryAttachment",plural:!0,selections:[{kind:"LinkedField",alias:null,name:"all_subattachments",storageKey:"all_subattachments(first:1)",args:l,concreteType:"SubattachmentsConnection",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"StoryAttachment",plural:!0,selections:[c]}]},c]},{kind:"LinkedField",alias:null,name:"underlying_admin_creator",storageKey:null,args:null,concreteType:null,plural:!1,selections:[q,n,g]},o,h,p]}]},g]}]},params:{operationKind:"query",name:"PageContentTabPublishedPagePostSearchDataFetcherQuery",id:"2830781920269881",text:null,metadata:{}}}}();e.exports=a}),null); __d("PageContentTabPublishedPostDataFetcherQuery.graphql",[],(function(a,b,c,d,e,f){"use strict";a=function(){var a=[{kind:"LocalArgument",name:"pageID",type:"ID!",defaultValue:null},{kind:"LocalArgument",name:"count",type:"Int",defaultValue:null},{kind:"LocalArgument",name:"after",type:"ID!",defaultValue:null}],b=[{kind:"Variable",name:"id",variableName:"pageID"}],c=[{kind:"ScalarField",alias:null,name:"uri",args:null,storageKey:null}],d={kind:"LinkedField",alias:null,name:"featurable_image",storageKey:null,args:null,concreteType:"Image",plural:!1,selections:c},e=[{kind:"Variable",name:"after",variableName:"after"},{kind:"Variable",name:"first",variableName:"count"}],f={kind:"LinkedField",alias:null,name:"page_info",storageKey:null,args:null,concreteType:"PageInfo",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"end_cursor",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"has_next_page",args:null,storageKey:null}]},g={kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null},h=[{kind:"ScalarField",alias:null,name:"text",args:null,storageKey:null}],i={kind:"LinkedField",alias:null,name:"title",storageKey:null,args:null,concreteType:"TextWithEntities",plural:!1,selections:h},j={kind:"ScalarField",alias:null,name:"post_id",args:null,storageKey:null},k={kind:"ScalarField",alias:null,name:"creation_time",args:null,storageKey:null},l=[{kind:"Literal",name:"first",value:1}];c={kind:"LinkedField",alias:null,name:"image",storageKey:null,args:null,concreteType:"Image",plural:!1,selections:c};var m={kind:"LinkedField",alias:null,name:"media",storageKey:null,args:null,concreteType:null,plural:!1,selections:[c]},n={kind:"ScalarField",alias:null,name:"name",args:null,storageKey:null},o={kind:"LinkedField",alias:null,name:"edit_history",storageKey:null,args:null,concreteType:"EditHistoryConnection",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"EditAction",plural:!0,selections:[g,{kind:"ScalarField",alias:null,name:"time",args:null,storageKey:null}]}]};h={kind:"LinkedField",alias:null,name:"message",storageKey:null,args:null,concreteType:"TextWithEntities",plural:!1,selections:h};var p={kind:"LinkedField",alias:null,name:"insights",storageKey:null,args:null,concreteType:"StoryInsights",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"engaged_user_count",args:null,storageKey:null},{kind:"ScalarField",alias:null,name:"total_reach",args:null,storageKey:null}]},q={kind:"ScalarField",alias:null,name:"__typename",args:null,storageKey:null};c={kind:"LinkedField",alias:null,name:"media",storageKey:null,args:null,concreteType:null,plural:!1,selections:[q,c,g]};return{kind:"Request",fragment:{kind:"Fragment",name:"PageContentTabPublishedPostDataFetcherQuery",type:"Query",metadata:null,argumentDefinitions:a,selections:[{kind:"LinkedField",alias:null,name:"page",storageKey:null,args:b,concreteType:"Page",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"profile_photo",storageKey:null,args:null,concreteType:"Photo",plural:!1,selections:[d]},{kind:"LinkedField",alias:null,name:"published_page_posts",storageKey:null,args:e,concreteType:"PagePublishedPostsConnection",plural:!1,selections:[f,{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"Story",plural:!0,selections:[g,i,j,k,{kind:"LinkedField",alias:null,name:"attachments",storageKey:null,args:null,concreteType:"StoryAttachment",plural:!0,selections:[{kind:"LinkedField",alias:null,name:"all_subattachments",storageKey:"all_subattachments(first:1)",args:l,concreteType:"SubattachmentsConnection",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"StoryAttachment",plural:!0,selections:[m]}]},m]},{kind:"LinkedField",alias:null,name:"underlying_admin_creator",storageKey:null,args:null,concreteType:null,plural:!1,selections:[n]},o,h,p]}]}]}]},operation:{kind:"Operation",name:"PageContentTabPublishedPostDataFetcherQuery",argumentDefinitions:a,selections:[{kind:"LinkedField",alias:null,name:"page",storageKey:null,args:b,concreteType:"Page",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"profile_photo",storageKey:null,args:null,concreteType:"Photo",plural:!1,selections:[d,g]},{kind:"LinkedField",alias:null,name:"published_page_posts",storageKey:null,args:e,concreteType:"PagePublishedPostsConnection",plural:!1,selections:[f,{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"Story",plural:!0,selections:[g,i,j,k,{kind:"LinkedField",alias:null,name:"attachments",storageKey:null,args:null,concreteType:"StoryAttachment",plural:!0,selections:[{kind:"LinkedField",alias:null,name:"all_subattachments",storageKey:"all_subattachments(first:1)",args:l,concreteType:"SubattachmentsConnection",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"nodes",storageKey:null,args:null,concreteType:"StoryAttachment",plural:!0,selections:[c]}]},c]},{kind:"LinkedField",alias:null,name:"underlying_admin_creator",storageKey:null,args:null,concreteType:null,plural:!1,selections:[q,n,g]},o,h,p]}]},g]}]},params:{operationKind:"query",name:"PageContentTabPublishedPostDataFetcherQuery",id:"2910772465606131",text:null,metadata:{}}}}();e.exports=a}),null); __d("PageScheduledLivingRoomCreateMutation.graphql",[],(function(a,b,c,d,e,f){"use strict";a=function(){var a=[{kind:"LocalArgument",name:"input",type:"PageScheduledLivingRoomCreateData!",defaultValue:null}],b=[{kind:"LinkedField",alias:null,name:"page_scheduled_living_room_create",storageKey:null,args:[{kind:"Variable",name:"input",variableName:"input"}],concreteType:"PageScheduledLivingRoomCreateResponsePayload",plural:!1,selections:[{kind:"LinkedField",alias:null,name:"scheduled_living_room_metadata",storageKey:null,args:null,concreteType:"ScheduledLivingRoomMetadata",plural:!1,selections:[{kind:"ScalarField",alias:null,name:"id",args:null,storageKey:null}]}]}];return{kind:"Request",fragment:{kind:"Fragment",name:"PageScheduledLivingRoomCreateMutation",type:"Mutation",metadata:null,argumentDefinitions:a,selections:b},operation:{kind:"Operation",name:"PageScheduledLivingRoomCreateMutation",argumentDefinitions:a,selections:b},params:{operationKind:"mutation",name:"PageScheduledLivingRoomCreateMutation",id:"1325294317595814",text:null,metadata:{}}}}();e.exports=a}),null); __d("AdsGenericFilterOperatorConfigUtil",["AdsGenericFilterOperatorConfig","ex"],(function(a,b,c,d,e,f){function a(a){for(var c in b("AdsGenericFilterOperatorConfig")){var d=b("AdsGenericFilterOperatorConfig")[c];if(a===d.operator)return d}throw new Error(b("ex")('Invalid operator "%s"',a))}c={getConfigByOperator:a};e.exports=c}),null); __d("AdsGenericFilterStoreUtil",["AdsApplicationUtils","AdsCurrencyFormatter","DateTime","Timezone"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=Math.round(b("DateTime").localNow().addYears(10).getUnixTimestamp()/1e3);function h(a,c){c=parseInt(c,10);return isNaN(c)?"":b("AdsCurrencyFormatter").formatCurrencyWithNumberDelimiters(a,c)}function i(a){return a+"%"}function j(a){a=parseFloat(a);return isNaN(a)?"":a+""}function k(a,c){c=n(+c);c=b("DateTime").fromLegacyArgs(c,b("Timezone").UTC);c=c.getEquivalentInTimezone(a);return c.format("F j, Y")}function l(a,c){c=n(+c);c=new(b("DateTime"))(c,a);return c.format("g:ia F jS, Y")}function m(a,c){return""+b("AdsCurrencyFormatter").parseCurrency(a,c)}function n(a){return b("AdsApplicationUtils").isFAME()&&a>g?Math.round(a/1e3):a}a={specializeFieldConfigForAccount:function(a,b){a.valueParser==="parseCurrency"&&(a.valueParser=function(a){return m(b.currency,a)}),a.valueRenderer==="formatCurrency"&&(a.valueRenderer=function(a){return h(b.currency,a)}),a.valueRenderer==="getDateFormatted"&&(a.valueRenderer=function(a){return k(b.timezoneID,a)}),a.valueRenderer==="formatPercentage"&&(a.valueRenderer=function(a){return i(a)}),a.valueParser==="parsePercentage"&&(a.valueParser=function(a){return j(a)}),a.valueRenderer==="getDateTimeFormatted"&&(a.valueRenderer=function(a){return l(b.timezoneID,a)})},getDateTimeFormatted:l};e.exports=a}),null); __d("AdsGenericFilterValueConfigUtil",[],(function(a,b,c,d,e,f){"use strict";__p&&__p();function a(a,b){if(b)for(var c in a){var d=a[c];if(d.value===b)return d}return null}b={getConfigByValue:a};e.exports=b}),null); __d("AdsGenericFilterValueTextUtil",["fbt","invariant","AdsGenericFilterFieldType","AdsGenericFilterValueConfigUtil","AdsManagerNavigationGatingUtils","SearchableEntry","intlList"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=function(a){return a};function a(a,b,c){var d=a.value,e="",f=b.valueRenderer||i;typeof d==="string"||typeof d==="number"?e=j(c,d,f):b.valueSetRenderer?e=b.valueSetRenderer(b.valueRenderer,b.values,d):b.getTokenTextByValue?e=b.getTokenTextByValue(d):Array.isArray(d)?e=k(c,d,f,a,!!b.applyOnly):h(0,1975,d);return e}function j(a,c,d){a=b("AdsGenericFilterValueConfigUtil").getConfigByValue(a,c);return d(a?a.value:String(c))}function k(a,c,d,e,f){__p&&__p();var h="";if(f)h=b("AdsManagerNavigationGatingUtils").getIsOptedInModernization()?g._("{count} selected",[g._param("count",c.length)]):String(c.length);else{c.length===2&&e.field.type===b("AdsGenericFilterFieldType").DATE_RANGE&&(c=[c[0],""+(Number(c[1])-1)]);c=c.map(function(c){var e=c;c instanceof b("SearchableEntry")&&(e=c.getTitle());return j(a,e,d)});switch(e.operator){case"IN_RANGE":case"NOT_IN_RANGE":h=c.join(" - ");break;case"ALL":h=b("intlList")(c,b("intlList").CONJUNCTIONS.AND);break;case"NONE":h=b("intlList")(c,b("intlList").CONJUNCTIONS.NONE);break;default:h=b("intlList")(c,b("intlList").CONJUNCTIONS.OR)}}return h}c={getValueText:a};e.exports=c}),null); __d("AdsCommonTargetingProperties",[],(function(a,b,c,d,e,f){"use strict";a={ageMax:null,ageMin:null,ageMinLimit:null,alternateAutoTargetingOption:null,appInstallState:null,behaviors:null,brandSafetyContentFilterLevels:null,catalogBasedTargeting:null,cities:null,countries:null,connections:null,conjunctiveUserAdclusters:null,contextualTargetingCategories:null,customAudiences:null,prospectingAudience:null,dynamicAudienceIds:null,educationMajors:null,educationSchools:null,educationStatuses:null,ethnicAffinity:null,engagementSpecs:null,excludedBrandSafetyContentTypes:null,excludedConnections:null,excludedCustomAudiences:null,excludedDynamicAudienceIds:null,excludedEngagementSpecs:null,excludedProductAudienceSpecs:null,excludedPublisherCategories:null,excludedPublisherListIDs:null,excludedUserAdclusters:null,excludedUserDevice:null,exclusions:null,familyStatuses:null,fbDealID:null,flexibleSpec:null,friendsOfConnections:null,followProfiles:null,followProfilesNegative:null,gatekeepers:null,genders:null,generation:null,homeOwnership:null,homeType:null,homeValue:null,householdComposition:null,income:null,industries:null,interestedIn:null,interests:null,keywords:null,lifeEvents:null,locTargeting:null,locales:null,maxGradYear:null,minAndroidVersion:null,maxAndroidVersion:null,minGradYear:null,minIosVersion:null,maxIosVersion:null,minWindowsVersion:null,maxWindowsVersion:null,mobileDevices:null,mobileOperatingSystem:null,moms:null,netWorth:null,officeType:null,pageTypes:null,politics:null,productAudienceSpecs:null,radiusIfValid:null,relationshipStatuses:null,regions:null,sex:null,syndicatedCustomAudiencesLibrary:null,targetAllGraduationYears:null,targetingCountry:null,userAdclusters:null,userOs:null,wifiOnly:null,workEmployers:null,workPositions:null,zips:null,geoLocations:null,excludedGeoLocations:null,timezones:null,targetingOptimization:null,placePageSetIDs:null};e.exports=a}),null); __d("AdsFlexibleTargetingMutationMode",["keyMirror"],(function(a,b,c,d,e,f){"use strict";a=b("keyMirror")({ADD_EXCLUDED_ENTRIES:null,ADD_EXCLUSION_BOX:null,ADD_INCLUDED_ENTRIES:null,DELETE_EXCLUSION_BOX:null,DELETE_EXCLUDED_ENTRIES:null,DELETE_INCLUSION_BOX:null,DELETE_INCLUDED_ENTRIES:null});e.exports=a}),null); __d("adsTargetingIsFlexibleSpecDescriptorType",["AdsFlexibleTargetingConstants"],(function(a,b,c,d,e,f){"use strict";var g=b("AdsFlexibleTargetingConstants").ARRAY_TYPE_ENTRIES;function a(a){return!(a in g)}e.exports=a}),null); __d("TargetingContainerMode",["keyMirror"],(function(a,b,c,d,e,f){"use strict";e.exports=b("keyMirror")({BULK:null})}),null); __d("TargetingConditionalReduceStore",["AdsTargetingLoadTimeInitTargetingContainerActionFlux","FluxReduceStore","abstractMethod"],(function(a,b,c,d,e,f){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b,c){b=a.call(this,b)||this;b.$TargetingConditionalReduceStore1=!1;b.$TargetingConditionalReduceStore2=c;return b}var d=c.prototype;d.__getActionTypes=function(){return[b("AdsTargetingLoadTimeInitTargetingContainerActionFlux").actionType]};d.reduce=function(a,c){var d=c.action;switch(d.type){case b("AdsTargetingLoadTimeInitTargetingContainerActionFlux").actionType:this.$TargetingConditionalReduceStore1=this.$TargetingConditionalReduceStore2===d.targetingMode;break;default:break}return this.$TargetingConditionalReduceStore1?this.reduceIfActive(a,c):a};d.isActive=function(){return this.$TargetingConditionalReduceStore1};d.reduceIfActive=function(a,c){return b("abstractMethod")("reduceIfActive","TargetingConditionalReduceStore")};d.getTargetingMode=function(){return this.$TargetingConditionalReduceStore2};return c}(b("FluxReduceStore"));a.__moduleID=e.id;e.exports=a}),null); __d("TargetingViewConfig",["FBLogger"],(function(a,b,c,d,e,f){"use strict";__p&&__p();function a(a){if(!a.targetingSpecFields){b("FBLogger")("ads").mustfix("%s is not a valid component. Please add .targetingSpecFields as a static property on the component.",a.displayName||a.name);return[]}var c=Object.keys(a.targetingSpecFields);(a.displayName==="AdsCommonTargetingConnectionsEditor"||a.displayName==="AdsTargetingConnectionsDeprecationEditorAddNewConnectionWrapper"||a.displayName==="AdsTargetingConnectionsDeprecationEditorDeleteOldConnectionWrapper")&&(c=c.filter(function(a){return a!="customAudiences"&&a!="excludedCustomAudiences"&&a!="geoLocations"}));return c}c={getFieldsForComponent:a};e.exports=c}),null); __d("targetingBulkSpecGetBulkApiSpecFromState",["AdsAggregateTargetingSpecsSchema","AdsBulkValueUtils","AdsCommonTargetingApiTransformer","AdsMixedValue","AdsUniformValue","mapObject","whitelistObjectKeys"],(function(a,b,c,d,e,f){"use strict";__p&&__p();function a(a){__p&&__p();a=a.toJS();var c=Object.values(a).find(function(a){return a instanceof b("AdsMixedValue")});if(!c){var d=b("AdsCommonTargetingApiTransformer").targetingSpecToApi(b("mapObject")(a,function(a){return a.getValue()}));Object.entries(d).forEach(function(a){var c=a[0];a=a[1];d[c]=b("AdsUniformValue").create([a])});return d}c=c;a=b("AdsBulkValueUtils").deaggregateDeep(a,c.getValues().length);a=a.map(b("AdsCommonTargetingApiTransformer").targetingSpecToApi,b("AdsCommonTargetingApiTransformer"));c=new Set(a.reduce(function(a,b){return[].concat(Object.keys(b),a)},[]));return b("AdsBulkValueUtils").aggregateDeep(b("whitelistObjectKeys")(b("AdsAggregateTargetingSpecsSchema"),Array.from(c)),a)}e.exports=a}),null); __d("targetingBulkSpecGetTargetingSpecFromState",["AdsUniformValue"],(function(a,b,c,d,e,f){"use strict";function a(a){var c={};a.forEach(function(a,d){a instanceof b("AdsUniformValue")&&(c[d]=a.getValue())});return c}e.exports=a}),null); __d("targetingBulkSpecGetTargetingApiSpecFromState",["AdsCommonTargetingApiTransformer","targetingBulkSpecGetTargetingSpecFromState"],(function(a,b,c,d,e,f){"use strict";function a(a){a=b("targetingBulkSpecGetTargetingSpecFromState")(a);return b("AdsCommonTargetingApiTransformer").targetingSpecToApi(a)}e.exports=a}),null); __d("targetingBulkSpecGetAllSelectedValuesFromBulkSpec",[],(function(a,b,c,d,e,f){"use strict";__p&&__p();function a(a,b){__p&&__p();if(!a)return[];var c={};a.getValues().filter(Boolean).forEach(function(a){a.forEach(function(a){c[b(a)]=a})});var d=[];Object.keys(c).forEach(function(a){return d.push(c[a])});return d}e.exports=a}),null); __d("targetingBulkSpecProcessSpecChangedOnTokenizedBulkValue",["AdsBulkValueUtils","AdsEmptyValue","AdsUniformValue","nullthrows","targetingBulkSpecGetAllSelectedValuesFromBulkSpec"],(function(a,b,c,d,e,f){"use strict";__p&&__p();function g(a,c,d){return!a||a instanceof b("AdsEmptyValue")?new(b("AdsUniformValue"))(c):b("AdsBulkValueUtils").mapBulkValue(a,function(a){return a?[].concat(a,c.filter(function(b){return!a.some(function(a){return d(a)===d(b)})})):[].concat(c)})}function h(a,c,d){return!a||a instanceof b("AdsEmptyValue")?null:b("AdsBulkValueUtils").mapBulkValue(a,function(a){return!a?a:a.filter(function(a){return!c.some(function(b){return d(b)===d(a)})})})}function a(a,c,d){__p&&__p();var e=a?b("targetingBulkSpecGetAllSelectedValuesFromBulkSpec")(a,d):[],f=new Set(e.map(function(a){return d(a)}));if(e.length===c.length)return a;else if(e.length=0||g(0,3660);return l(a,e,f,d);case b("AdsFlexibleTargetingMutationMode").DELETE_INCLUSION_BOX:case b("AdsFlexibleTargetingMutationMode").DELETE_EXCLUSION_BOX:e!==void 0&&e>0||g(0,3661);return m(a,e,d);case b("AdsFlexibleTargetingMutationMode").ADD_EXCLUSION_BOX:return n(a);case b("AdsFlexibleTargetingMutationMode").ADD_EXCLUDED_ENTRIES:return i(a,f);case b("AdsFlexibleTargetingMutationMode").ADD_INCLUDED_ENTRIES:e!==void 0&&e>=0||g(0,3662);return j(a,e,f)}return a}function i(a,c){return b("AdsBulkValueUtils").mapBulkValue(a,function(a){var d=a?a.slice(0):[];a=b("targetingBulkSpecGetNewSpecOnAddingDetailedTargetingEntries")(a,h.EXCLUDE_ANY,d.length-1,c);d.length===0||d[d.length-1].type===h.INCLUDE_ANY?d.push(a):d[d.length-1]=a;return d})}function j(a,c,d){return b("AdsBulkValueUtils").mapBulkValue(a,function(a){if(!k(a,c))return a;var e=a?a.slice(0):[];a=b("targetingBulkSpecGetNewSpecOnAddingDetailedTargetingEntries")(a,h.INCLUDE_ANY,c,d);e.length===0||e[c].type===h.EXCLUDE_ANY?(c===0||g(0,3663),e.splice(c,0,a)):e[c]=a;return e})}function k(a,b){return b===0?!0:!!a&&!!a[b]&&a[b].type===h.INCLUDE_ANY}function l(a,c,d,e){__p&&__p();e===b("AdsFlexibleTargetingMutationMode").DELETE_EXCLUDED_ENTRIES||e===b("AdsFlexibleTargetingMutationMode").DELETE_INCLUDED_ENTRIES||g(0,3665);var f=d.map(function(a){return a.type+"."+a.id}),i=e===b("AdsFlexibleTargetingMutationMode").DELETE_EXCLUDED_ENTRIES;return b("AdsBulkValueUtils").mapBulkValue(a,function(a){__p&&__p();var d=i?a.length-1:c;if(!a||i&&a[d].type!==h.EXCLUDE_ANY||!i&&(!a[d]||a[d].type===h.EXCLUDE_ANY))return a;var e={};Object.entries(a[d]).forEach(function(c){var h=c[0];c=c[1];if(c instanceof Array){c=c.filter(function(a){a=b("targetingBulkSpecSerializeFlexibleSpecEntry")(a);return!f.includes(h+"."+a)});c.length!==0&&(e[h]=c)}else h==="type"||g(0,3666),e.type=a[d][h]});var j=a.slice(0);j[d]=e;return j})}function m(a,c,d){__p&&__p();return d===b("AdsFlexibleTargetingMutationMode").DELETE_EXCLUSION_BOX?b("AdsBulkValueUtils").mapBulkValue(a,function(a){if(!a||a[a.length-1].type!==h.EXCLUDE_ANY)return a;a=a.slice(0,a.length-1);return a}):b("AdsBulkValueUtils").mapBulkValue(a,function(a){if(!a||!a[c]||a[c].type===h.EXCLUDE_ANY)return a;a=a.slice(0);a.splice(c,1);return a})}function n(a){return b("AdsBulkValueUtils").mapBulkValue(a,function(a){a=a?a.slice(0):[];a[a.length]={type:h.EXCLUDE_ANY};return a})}e.exports=a}),null); __d("targetingBulkSpecProcessSpecChangedOnLocaleBulkValue",["targetingBulkSpecProcessSpecChangedOnTokenizedBulkValue"],(function(a,b,c,d,e,f){"use strict";function a(a,c){return b("targetingBulkSpecProcessSpecChangedOnTokenizedBulkValue")(a,c,function(a){return a.toString()})}e.exports=a}),null); __d("targetingBulkSpecSeparateBulkValueSpecToFlatAndMixed",["AdsBulkValueUtils","AdsMixedValue","AdsUniformValue"],(function(a,b,c,d,e,f){"use strict";function a(a){var c={},d={};Object.entries(a).forEach(function(a){var e=a[0];a=a[1];b("AdsBulkValueUtils").isBulkValue(a)?a instanceof b("AdsMixedValue")?d[e]=a:a instanceof b("AdsUniformValue")&&(c[e]=a.getValue()):c[e]=a});return{flatSpec:c,mixedValueSpec:d}}e.exports=a}),null); __d("TargetingSpecStore",["invariant","AdsAPITargetFields","AdsBulkValueUtils","AdsCommonTargetingApiTransformer","AdsCommonTargetingProperties","AdsCommonTargetingTargetingChangeActionFlux","AdsCommonTargetingTargetingClearAllDataActionFlux","AdsCommonTargetingTargetingInitDataActionFlux","AdsCommonTargetingTargetingSetFromExternalDataActionFlux","AdsDataAtom","AdsEmptyValue","AdsMixedValue","AdsTargetingClearTargetingSpecStoreDataActionFlux","AdsTargetingLoadTimeInitTargetingContainerActionFlux","AdsTargetingResetMixStateComponentDataActionFlux","AdsTargetingSetTargetingApiSpecDataActionFlux","AdsTargetingSetTargetingBulkApiSpecDataActionFlux","AdsTargetingUpdateTargetingSpecDataActionFlux","AdsUniformValue","BrandsAppConfigDynamicFields","TargetingConditionalReduceStore","TargetingContainerMode","TargetingViewConfig","immutable","targetingBulkSpecGetBulkApiSpecFromState","targetingBulkSpecGetTargetingApiSpecFromState","targetingBulkSpecGetTargetingSpecFromState","targetingBulkSpecProcessSpecChangedOnCustomAudienceBulkValue","targetingBulkSpecProcessSpecChangedOnDetailedTargetingBulkValue","targetingBulkSpecProcessSpecChangedOnLocaleBulkValue","targetingBulkSpecSeparateBulkValueSpecToFlatAndMixed","trimObject","whitelistObjectKeys"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.getInitialState=function(){return b("immutable").Map({})};d.__getActionTypes=function(){return[b("AdsTargetingLoadTimeInitTargetingContainerActionFlux").actionType,b("AdsTargetingClearTargetingSpecStoreDataActionFlux").actionType,b("AdsCommonTargetingTargetingInitDataActionFlux").actionType,b("AdsCommonTargetingTargetingClearAllDataActionFlux").actionType,b("AdsTargetingResetMixStateComponentDataActionFlux").actionType,b("AdsTargetingSetTargetingBulkApiSpecDataActionFlux").actionType,b("AdsTargetingSetTargetingApiSpecDataActionFlux").actionType,b("AdsTargetingUpdateTargetingSpecDataActionFlux").actionType,b("AdsCommonTargetingTargetingSetFromExternalDataActionFlux").actionType,b("AdsCommonTargetingTargetingChangeActionFlux").actionType]};d.getValue=function(a){a=this.getState().get(a);return a instanceof b("AdsUniformValue")?a.getValue():void 0};d.getValues=function(a){var b=this;return a.reduce(function(a,c){a[c]=b.getValue(c);return a},{})};d.getBulkApiSpec=function(){return b("targetingBulkSpecGetBulkApiSpecFromState")(this.getState())};d.getTargetingSpec=function(){return b("targetingBulkSpecGetTargetingSpecFromState")(this.getState())};d.getTargetingApiSpec=function(){return b("targetingBulkSpecGetTargetingApiSpecFromState")(this.getState())};d.getBulkSpec=function(){return this.getState().toObject()};d.reduceIfActive=function(a,c){c=c.action;switch(c.type){case b("AdsTargetingClearTargetingSpecStoreDataActionFlux").actionType:case b("AdsCommonTargetingTargetingInitDataActionFlux").actionType:case b("AdsCommonTargetingTargetingClearAllDataActionFlux").actionType:return this.getInitialState();case b("AdsTargetingResetMixStateComponentDataActionFlux").actionType:return this.$TargetingSpecStore1(a,c.component);case b("AdsTargetingSetTargetingBulkApiSpecDataActionFlux").actionType:return this.$TargetingSpecStore2(c.spec,c.behaviors);case b("AdsTargetingSetTargetingApiSpecDataActionFlux").actionType:return this.$TargetingSpecStore3(c.spec,c.behaviors);case b("AdsTargetingUpdateTargetingSpecDataActionFlux").actionType:return this.$TargetingSpecStore4(a,c.spec);case b("AdsCommonTargetingTargetingSetFromExternalDataActionFlux").actionType:case b("AdsCommonTargetingTargetingChangeActionFlux").actionType:return this.$TargetingSpecStore4(a,c);default:return a}};d.$TargetingSpecStore2=function(a,c){__p&&__p();this.$TargetingSpecStore5(a,b("AdsAPITargetFields").FLEXIBLE_SPEC,b("AdsAPITargetFields").EXCLUSIONS);b("BrandsAppConfigDynamicFields").businessCapabilities.can_see_claim_audience_ads_manager&&(this.$TargetingSpecStore5(a,b("AdsAPITargetFields").CUSTOM_AUDIENCES,b("AdsAPITargetFields").DYNAMIC_AUDIENCE_IDS),this.$TargetingSpecStore5(a,b("AdsAPITargetFields").EXCLUDED_CUSTOM_AUDIENCES,b("AdsAPITargetFields").EXCLUDED_DYNAMIC_AUDIENCE_IDS));a=b("targetingBulkSpecSeparateBulkValueSpecToFlatAndMixed")(a);var d=a.flatSpec;a=a.mixedValueSpec;var e=b("AdsCommonTargetingApiTransformer").fromApi(d,c);Object.entries(e).forEach(function(a){var c=a[0];a=a[1];e[c]=b("AdsUniformValue").create([a])});d=this.$TargetingSpecStore6(a,c);return!d?this.getInitialState().merge(e):this.getInitialState().merge(e).merge(d)};d.$TargetingSpecStore5=function(a,c,d){var e=a[c],f=a[d];if(e instanceof b("AdsMixedValue")&&f instanceof b("AdsUniformValue")){var g=e.getValues().length;a[d]=b("AdsMixedValue").create(Array(g).fill(f.getValue()))}else if(e instanceof b("AdsUniformValue")&&f instanceof b("AdsMixedValue")){d=f.getValues().length;a[c]=b("AdsMixedValue").create(Array(d).fill(e.getValue()))}};d.$TargetingSpecStore6=function(a,c){__p&&__p();var d={},e=Object.values(a).length;if(e===0)return null;var f=b("AdsBulkValueUtils").deaggregateDeep(a,a[Object.keys(a)[0]].getValues().length);f=f.map(function(a){return b("trimObject")(b("AdsCommonTargetingApiTransformer").fromApi(a,c,!0))});e=f.reduce(function(a,b){return[].concat(Object.keys(b),a)},[]);new Set(e).forEach(function(a){d[a]=b("AdsMixedValue").create(f.map(function(b){return b[a]}))});return d};d.$TargetingSpecStore3=function(a,c){var d=b("AdsCommonTargetingApiTransformer").fromApi(a,c);Object.entries(d).forEach(function(a){var c=a[0];a=a[1];d[c]=b("AdsUniformValue").create([a])});return this.getInitialState().merge(d)};d.$TargetingSpecStore4=function(a,c){var d=b("whitelistObjectKeys")(c,b("AdsCommonTargetingProperties"));Object.entries(d).forEach(function(e){var f=e[0];e=e[1];c.supportBulkEdit?(e instanceof Array||g(0,2578),f==="locales"?d[f]=b("targetingBulkSpecProcessSpecChangedOnLocaleBulkValue")(a.get(f),e):f==="customAudiences"||f==="excludedCustomAudiences"?d[f]=b("targetingBulkSpecProcessSpecChangedOnCustomAudienceBulkValue")(a.get(f),e):f==="flexibleSpec"?d[f]=b("targetingBulkSpecProcessSpecChangedOnDetailedTargetingBulkValue")(a.get(f),e,c.mutationType,c.boxPosition,c.changedEntries||[]):g(0,2579,f)):c[f]===null?d[f]=b("AdsEmptyValue").instance():d[f]=b("AdsUniformValue").create([e])});return a.merge(d)};d.$TargetingSpecStore1=function(a,c){c=b("TargetingViewConfig").getFieldsForComponent(c);c=c.reduce(function(a,c){a[c]=b("AdsEmptyValue").instance();return a},{});return a.merge(c)};return c}(b("TargetingConditionalReduceStore"));a.__moduleID=e.id;e.exports=new a(b("AdsDataAtom"),b("TargetingContainerMode").BULK)}),null); __d("AdsCFCheckbox.react",["cx","Event","FDSSimplePopover.react","Keys","React","joinClasses"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){__p&&__p();var d;d=a.call(this,c)||this;d.$4=function(a){var c=b("Event").getKeyCode(a);(c===b("Keys").RETURN||c===b("Keys").SPACE)&&d.$2(a)};d.$5=function(){d.state.pressed||d.setState({pressed:!0})};d.$6=function(){d.state.pressed&&d.setState({pressed:!1})};d.$2=function(a){a.preventDefault(),d.props.onChange&&d.props.onChange(!d.props.checked,d.props.name||"",d.props.value)};d.$3=function(){d.setState({focused:!0})};d.$1=function(){d.setState({focused:!1,pressed:!1})};d.state={focused:!1,pressed:!1};return d}var d=c.prototype;d.render=function(){var a=this.props.checked,c=!!this.props.disabled,d=!c&&this.state.focused,e;this.props.helpText!=null&&this.props.helpText!==""&&(e=b("React").createElement(b("FDSSimplePopover.react"),{content:this.props.helpText,contentWidthUseSparingly:368}));var f=!c&&this.state.pressed;d=b("joinClasses")("_5y_b"+(this.props.inline?" _5y_c":"")+(a?" checked":"")+(c?" disabled":"")+(d?" focused":"")+(f?" pressed":""),this.props.className);f=c?-1:0;return b("React").createElement("div",{"aria-checked":a,"aria-disabled":c,"aria-labelledby":this.props.label,className:d,"data-testid":this.props["data-testid"],role:"checkbox",tabIndex:f,onBlur:c?null:this.$1,onClick:c?null:this.$2,onFocus:c?null:this.$3,onKeyUp:c?null:this.$4,onMouseDown:c?null:this.$5,onMouseUp:c?null:this.$6},b("React").createElement("i",{className:"_5y_d"}),b("React").createElement("span",{className:"_5y_a"},this.props.label,e))};return c}(b("React").Component);e.exports=a}),null); __d("InstreamVideosSensitiveAdsBlockListDispatcher",["ExplicitRegistrationReactDispatcher"],(function(a,b,c,d,e,f){"use strict";e.exports=new(b("ExplicitRegistrationReactDispatcher"))({strict:!0})}),null); __d("InstreamVideosSensitiveAdsBlockListActionTypes",["keyMirror"],(function(a,b,c,d,e,f){"use strict";a=b("keyMirror")({BLOCK_LIST_REVIEW_STATUS_LOAD_SUCCESS:"",BLOCK_LIST_REVIEW_STATUS_LOAD_ERROR:"",SENSITIVE_ADS_MODAL_XOUT:""});e.exports=a}),null); __d("XInstreamVideosBumpSensitiveBlockListConfirmationCounterAsyncController",["XController"],(function(a,b,c,d,e,f){e.exports=b("XController").create("/ads/instream_videos/sensitive_block_list_confirmation/bump_counter/",{page_id:{type:"FBID"},business_id:{type:"String"}})}),null); __d("XInstreamVideosFetchSensitiveBlockListConfirmationCounterAsyncController",["XController"],(function(a,b,c,d,e,f){e.exports=b("XController").create("/ads/instream_videos/sensitive_block_list_confirmation/fetch/",{page_id:{type:"FBID"},business_id:{type:"String"}})}),null); __d("InstreamVideosSensitiveAdsBlockListConfirmationDataManager",["AsyncRequest","InstreamVideosSensitiveAdsBlockListActionTypes","InstreamVideosSensitiveAdsBlockListDispatcher","XInstreamVideosBumpSensitiveBlockListConfirmationCounterAsyncController","XInstreamVideosFetchSensitiveBlockListConfirmationCounterAsyncController"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g={blockListConfirmed:function(a){var c=b("XInstreamVideosBumpSensitiveBlockListConfirmationCounterAsyncController").getURIBuilder().getURI();new(b("AsyncRequest"))().setMethod("POST").setURI(c).setData(g.getBackendParams(a)).setReadOnly(!0).setHandler(function(b){return g.sendLoadSuccess(a,b.payload)}).setErrorHandler(function(b){return g.sendLoadError(a,b.getErrorDescription())}).send()},load:function(a){var c=b("XInstreamVideosFetchSensitiveBlockListConfirmationCounterAsyncController").getURIBuilder().getURI();new(b("AsyncRequest"))().setMethod("POST").setURI(c).setData(g.getBackendParams(a)).setHandler(function(b){return g.sendLoadSuccess(a,b.payload)}).setErrorHandler(function(b){return g.sendLoadError(a,b.getErrorDescription())}).send()},sendLoadError:function(a,c){b("InstreamVideosSensitiveAdsBlockListDispatcher").dispatch(babelHelpers["extends"]({type:b("InstreamVideosSensitiveAdsBlockListActionTypes").BLOCK_LIST_REVIEW_STATUS_LOAD_ERROR,error:new Error(c)},a))},sendLoadSuccess:function(a,c){b("InstreamVideosSensitiveAdsBlockListDispatcher").dispatch(babelHelpers["extends"]({type:b("InstreamVideosSensitiveAdsBlockListActionTypes").BLOCK_LIST_REVIEW_STATUS_LOAD_SUCCESS,hasAdBreaksAdminAccess:c.has_ad_breaks_admin_access,isBlockListReviewed:c.is_block_list_reviewed},a))},getBackendParams:function(a){return a.sourceApp==="page"?{page_id:a.pageID,source_app:"page"}:{business_id:String(a.businessID),source_app:"creator_studio"}}};e.exports=g}),null); __d("AdStudyConstants",[],(function(a,b,c,d,e,f){"use strict";__p&&__p();a={SET_SHOW_INTERNAL_TESTS:"setShowInternalTests",SET_STUDIES_DATA:"addStudiesData",SET_STUDY_STATUS_FILTER:"setStudyStatusFilter",SET_DASHBOARD_TABLE_PAGE:"setDashboardTablePage",SET_SEARCH_STRING:"setSearchString",SET_USER_SEARCH_OPTION:"setSearchUserOption",SET_USER_ID:"setUserID",SET_SHOW_DETAILS:"setShowDetails",SET_SHOW_CSV:"setShowCsv",SET_SHOW_UPLOAD_DECK_DIALOG:"setShowUploadDeckDialog",SET_IS_LOADING:"setIsLoading",SET_STUDY_IS_INTERNAL_FLAG:"setStudyIsInternalFlag",WILL_SAVE_DECK_SOURCE:"willSaveDeckSource",DID_SAVE_DECK_SOURCE:"didSaveDeckSource",FAILED_SAVE_DECK_SOURCE:"failedSaveDeckSource",SET_BRAND_LIFT_STUDY_VERSION:"setBrandLiftStudyVersion",SET_BRAND_LIFT_STUDY_V1_STATUS:"setBrandLiftStudyV1Status",SET_BRAND_LIFT_STUDY_V2_STATUS:"setBrandLiftStudyV2Status",SET_BRAND_LIFT_STUDIES_DATA:"setBrandLiftStudiesData"};b={NOT_AVAILABLE:"notAvailable",VERY_LOW:"veryLow",LOW:"low",FAIR:"fair",HIGH:"high"};c={DEFAULT:"DEFAULT",SUCCEED:"SUCCEED",FAILED:"FAILED"};d=20;f=["BRAND","BRANDLIFT"];var g=["SALES","NONSALES","MAI","FTL"],h=1522569600,i=1528614e3,j=1540969200,k=1552633200,l=15395868e5,m=15439104e5,n=0,o=.9;e.exports={ActionType:a,PowerLevel:b,SaveDeckSourceStatus:c,objectValues:function(a){return Object.keys(a).map(function(b){return a[b]})},dashboardPageLength:d,brandLiftObjectiveTypes:f,conversionLiftObjectiveTypes:g,historicalReportsShowBayesianResultsCutOffUnixTimestamp:h,historicalReportsShowBayesianHPDResultsCutOffUnixTimestamp:i,historicalReportsShowAdvancedResultsCutOffUnixTimestamp:j,historicalReportsShowBrandResponseBreakdownsCutOffUnixTimestamp:k,useBayesianStudyConfidenceLevelValue:n,defaultConfidenceLevelValue:o,brandPostAuctionLoggingLaunchTime:l,mixedPostAuctionLoggingLaunchTime:m}}),null); __d("AdBreakPortalInstreamAdsBlockListNameCell.react",["cx","fbt","Link.react","React"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f0&&(n=b("XPagesSettingsInstreamAdsBlockListMutationController").getURIBuilder().setFBID("page_id",a).setFBIDSet("blocked_page_ids",c).setIntSet("blocked_non_derived_categories",d).setIntSet("blocked_derived_categories",e).setString("block_list_name",f).setBool("is_active",g).setBool("is_profile_level",h).setFBID("block_list_id",i).setFBID("business_id",j).setFBIDSet("target_pages",k).setStringSet("restricted_countries",l).setBool("are_restricted_countries_whitelisted",m).getURI());new(b("AsyncRequest"))(n).setHandler(function(a){i!==null&&i!==void 0?b("MediaManagerMonetizationAdBreakTabActions").blockListUpdated(i):b("MediaManagerMonetizationAdBreakTabActions").blockListCreated(a.payload.blockListID),b("PagesSettingsInstreamAdsBlockListContentActions").didUpdateBlockListContent()}).setErrorHandler(function(a){b("MediaManagerMonetizationAdBreakTabActions").blockListCreateOrUpdateError(i),b("PagesSettingsInstreamAdsBlockListContentActions").asyncRequestError(a)}).send()}};e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentStoreState",["fbt","immutable"],(function(a,b,c,d,e,f,g){"use strict";a={allNonDerivedCategories:[],allDerivedCategories:[],allContentLoaded:!1,blockedNonDerivedCategories:[],blockedDerivedCategories:[],blockedPages:[],restrictedCountries:[],blockListId:null,blockListName:String(g._("Default")),businessId:null,enableSubcategories:!1,errorInfo:null,isBusinessLevel:!1,isPageLevel:!0,pageId:null,requestSent:!1,targetPages:[],updatedBlockListContent:!1,restrictedCountriesInWhitelist:!1};c=function(a){babelHelpers.inheritsLoose(b,a);function b(){return a.apply(this,arguments)||this}return b}(b("immutable").Record(a));e.exports=c}),null); __d("PagesSettingsInstreamAdsBlockListContentStore",["fbt","invariant","DerivedCreatorSensitiveAdsBlocklistCategory$FbtEnum","FluxReduceStore","InstreamAdsBlockListCategory$FbtEnum","InstreamAdsBlockListCategoryMaps","PagesSettingsInstreamAdsBlockListContentRequestHandler","PagesSettingsInstreamAdsBlockListContentStoreState","PagesSettingsInstreamAdsBlockListDataTypes","PagesSettingsInstreamAdsBlockListDispatcher","PagesSettingsInstreamAdsBlockListStore","gkx"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=b("InstreamAdsBlockListCategoryMaps").CategoryChildToParentMap,j=b("InstreamAdsBlockListCategoryMaps").CategoryParentToChildMap,k=b("InstreamAdsBlockListCategoryMaps").CategoryTypeToNameMap,l=b("InstreamAdsBlockListCategoryMaps").DerivedCreatorSensitiveCategories,m=b("InstreamAdsBlockListCategoryMaps").NotCategorized,n=b("PagesSettingsInstreamAdsBlockListDataTypes").BlockListActionTypes,o=b("PagesSettingsInstreamAdsBlockListDataTypes").BlockListContentActionTypes;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.getInitialState=function(){return new(b("PagesSettingsInstreamAdsBlockListContentStoreState"))()};d.reduce=function(a,c){__p&&__p();switch(c.type){case o.INIT_CONTENT:return this.$PagesSettingsInstreamAdsBlockListContentStore1(a,c);case o.LOAD_CATEGORIES:return this.$PagesSettingsInstreamAdsBlockListContentStore2(a,c);case o.UPDATE_NAME:return this.$PagesSettingsInstreamAdsBlockListContentStore3(a,c);case o.UPDATE_PAGE_LEVEL_CHECKBOX:return this.$PagesSettingsInstreamAdsBlockListContentStore4(a,c);case o.RECEIVE_CONTENT_DATA:return this.$PagesSettingsInstreamAdsBlockListContentStore5(a,c);case o.ADD_PAGE_TO_UI:return this.$PagesSettingsInstreamAdsBlockListContentStore6(a,c);case o.ADD_COUNTRY_TO_UI:return this.$PagesSettingsInstreamAdsBlockListContentStore7(a,c);case o.REMOVE_COUNTRY_FROM_UI:return this.$PagesSettingsInstreamAdsBlockListContentStore8(a,c);case o.REMOVE_PAGE_FROM_UI:return this.$PagesSettingsInstreamAdsBlockListContentStore9(a,c);case o.ADD_CATEGORY_TO_UI:return this.$PagesSettingsInstreamAdsBlockListContentStore10(a,c);case o.REMOVE_CATEGORY_FROM_UI:return this.$PagesSettingsInstreamAdsBlockListContentStore11(a,c);case o.ADD_TARGET_PAGE_TO_UI:return this.$PagesSettingsInstreamAdsBlockListContentStore12(a,c);case o.REMOVE_TARGET_PAGE_FROM_UI:return this.$PagesSettingsInstreamAdsBlockListContentStore13(a,c);case o.UPDATE_BLOCK_LIST_CONTENT:return this.$PagesSettingsInstreamAdsBlockListContentStore14(a,c);case o.DID_UPDATE_BLOCK_LIST_CONTENT:return this.$PagesSettingsInstreamAdsBlockListContentStore15(a,c);case o.ASYNC_REQUEST_ERROR:return this.$PagesSettingsInstreamAdsBlockListContentStore16(a,c);case o.SET_COUNTRY_RESTRICTIONS:return this.$PagesSettingsInstreamAdsBlockListContentStore17(a,c);case n.SELECT_BLOCK_LIST:b("PagesSettingsInstreamAdsBlockListDispatcher").waitFor([b("PagesSettingsInstreamAdsBlockListStore").getDispatchToken()]);return this.$PagesSettingsInstreamAdsBlockListContentStore18(a,c)}return a};d.$PagesSettingsInstreamAdsBlockListContentStore1=function(a,b){a=this.getInitialState();a=a.set("pageId",b.currentPageId);a=a.set("businessId",b.currentBusinessId);return a};d.$PagesSettingsInstreamAdsBlockListContentStore2=function(a,b){a=a.set("enableSubcategories",b.enableSubcategories);a=a.set("allNonDerivedCategories",this.$PagesSettingsInstreamAdsBlockListContentStore19(b.enableSubcategories));a=a.set("allDerivedCategories",this.$PagesSettingsInstreamAdsBlockListContentStore20());return a};d.$PagesSettingsInstreamAdsBlockListContentStore21=function(a){var b=this.getInitialState();b=b.set("pageId",a.pageId);b=b.set("businessId",a.businessId);b=b.set("enableSubcategories",a.enableSubcategories);b=b.set("allNonDerivedCategories",a.allNonDerivedCategories);b=b.set("allDerivedCategories",a.allDerivedCategories);return b};d.$PagesSettingsInstreamAdsBlockListContentStore3=function(a,b){return a.set("blockListName",b.name)};d.$PagesSettingsInstreamAdsBlockListContentStore4=function(a,b){return a.set("isPageLevel",b.checked)};d.$PagesSettingsInstreamAdsBlockListContentStore18=function(a,c){var d=c.blockList?c.blockList.id:null;a=this.$PagesSettingsInstreamAdsBlockListContentStore21(a);a=a.set("blockListId",d);a.blockListId?(a=a.set("requestSent",!0),a=a.set("allContentLoaded",!1),b("PagesSettingsInstreamAdsBlockListContentRequestHandler").requestBlockListContentData(a.blockListId)):(a=a.set("allContentLoaded",!0),c.isCountryRestriction&&(a=a.set("isPageLevel",!1)));return a};d.$PagesSettingsInstreamAdsBlockListContentStore5=function(a,b){__p&&__p();var c=this;if(!b.data)return a;Array.isArray(b.data.blockedPages)||h(0,6187);a=a.set("requestSent",!1);a=a.set("allContentLoaded",!0);a=a.set("blockedPages",Array.from(b.data.blockedPages));a=a.set("blockedNonDerivedCategories",Array.from(b.data.blockedNonDerivedCategories.map(function(a){return c.$PagesSettingsInstreamAdsBlockListContentStore22(a.toString())})));a=a.set("blockedDerivedCategories",Array.from(b.data.blockedDerivedCategories.map(function(a){return c.$PagesSettingsInstreamAdsBlockListContentStore22(a.toString())})));a=a.set("targetPages",Array.from(b.data.targetPages));a=a.set("blockListName",b.data.blockListName);a=a.set("isPageLevel",b.data.isPageLevel);a=a.set("isBusinessLevel",b.data.isBusinessLevel);b.data.restrictedCountriesInWhitelist!=null&&b.data.restrictedCountries!=null&&(a=a.set("restrictedCountriesInWhitelist",b.data.restrictedCountriesInWhitelist),a=a.set("restrictedCountries",Array.from(b.data.restrictedCountries.map(function(a){return{name:a}}))));return a};d.$PagesSettingsInstreamAdsBlockListContentStore9=function(a,b){var c=Array.from(a.blockedPages).filter(function(a){return a.id!==b.pageId});return a.set("blockedPages",c)};d.$PagesSettingsInstreamAdsBlockListContentStore8=function(a,b){var c=Array.from(a.restrictedCountries).filter(function(a){return a.name!==b.country});return a.set("restrictedCountries",c)};d.$PagesSettingsInstreamAdsBlockListContentStore17=function(a,b){b=b.isWhitelisted;return a.set("restrictedCountriesInWhitelist",b)};d.$PagesSettingsInstreamAdsBlockListContentStore7=function(a,b){var c=Array.from(a.restrictedCountries),d=c.find(function(a){return a.name===b.country});d||c.push({name:b.country});return a.set("restrictedCountries",c)};d.$PagesSettingsInstreamAdsBlockListContentStore6=function(a,b){var c=Array.from(a.blockedPages),d=c.find(function(a){return a.id==b.pageId});d||c.push({id:b.pageId,title:b.pageTitle});return a.set("blockedPages",c)};d.$PagesSettingsInstreamAdsBlockListContentStore11=function(a,b){var c=this,d=this.$PagesSettingsInstreamAdsBlockListContentStore23(b.categoryId),e=Array.from(a.blockedDerivedCategories).filter(function(a){return b.categoryId!==a.id}),f=Array.from(a.blockedNonDerivedCategories).filter(function(a){if(!d)return a.id!==b.categoryId&&a.id!==c.$PagesSettingsInstreamAdsBlockListContentStore24(b.categoryId);else return a.id!==b.categoryId&&!d.includes(a.id)});return a.set("blockedNonDerivedCategories",f).set("blockedDerivedCategories",e)};d.$PagesSettingsInstreamAdsBlockListContentStore10=function(a,b){__p&&__p();var c=this,d=Array.from(a.blockedDerivedCategories);if(!d.includes(this.$PagesSettingsInstreamAdsBlockListContentStore22(b.categoryId))&&Object.prototype.hasOwnProperty.call(l,b.categoryId)){d.push(this.$PagesSettingsInstreamAdsBlockListContentStore22(b.categoryId));return a.set("blockedDerivedCategories",d)}var e=Array.from(a.blockedNonDerivedCategories);d=this.$PagesSettingsInstreamAdsBlockListContentStore23(b.categoryId);var f=e.find(function(a){return a.id==b.categoryId});!f&&d?(e.push(this.$PagesSettingsInstreamAdsBlockListContentStore22(b.categoryId)),d.map(function(a){return e.push(c.$PagesSettingsInstreamAdsBlockListContentStore22(a))})):f||e.push({id:b.categoryId,name:b.categoryName});return a.set("blockedNonDerivedCategories",e)};d.$PagesSettingsInstreamAdsBlockListContentStore13=function(a,b){var c=Array.from(a.targetPages).filter(function(a){return a.id!==b.pageId});return a.set("targetPages",c)};d.$PagesSettingsInstreamAdsBlockListContentStore12=function(a,b){var c=Array.from(a.targetPages),d=c.find(function(a){return a.id==b.pageId});d||c.push({id:b.pageId,title:b.pageTitle});return a.set("targetPages",c)};d.$PagesSettingsInstreamAdsBlockListContentStore14=function(a,c){__p&&__p();if(!a.blockListName||a.blockListName.trim().length===0)return a.set("errorInfo",g._("Failed to update block list. Block list name is required."));if(a.restrictedCountries&&a.restrictedCountries.length>0){c="Target: ";a.restrictedCountriesInWhitelist||(c="Exclude: ");c+=a.restrictedCountries.map(function(a){return a.name}).join(", ");a=a.set("blockListName",c)}a=a.set("requestSent",!0);a=a.set("errorInfo",null);b("PagesSettingsInstreamAdsBlockListContentRequestHandler").createOrUpdateBlockListContent(a.pageId,a.blockedPages.map(function(a){return a.id}),a.blockedNonDerivedCategories.map(function(a){return Number(a.id)}),a.blockedDerivedCategories.map(function(a){return Number(a.id)}),a.blockListName.trim(),!0,a.isPageLevel,a.blockListId,a.businessId,a.targetPages.map(function(a){return a.id}),a.restrictedCountries.map(function(a){return a.name}),a.restrictedCountriesInWhitelist);return a};d.$PagesSettingsInstreamAdsBlockListContentStore15=function(a,b){a=a.set("requestSent",!1);a=a.set("updatedBlockListContent",!0);return a};d.$PagesSettingsInstreamAdsBlockListContentStore16=function(a,b){a=a.set("requestSent",!1);a=a.set("errorInfo",b.response.errorDescription);return a};d.$PagesSettingsInstreamAdsBlockListContentStore19=function(a){__p&&__p();var b=this,c=[];Object.keys(j).sort(function(a,c){if(a===c)return 0;if(parseInt(a,10)===m)return 1;return parseInt(c,10)===m?-1:b.$PagesSettingsInstreamAdsBlockListContentStore22(a).name.toString()0?!1:!0};d.$6=function(){if(this.$4()||!this.props.enableSubcategories)return null;else if(this.props.expand)return b("React").createElement("span",{className:"_61n2"},b("React").createElement(b("SUIGlyphIcon.react"),{onClick:this.$5,srcDefault:g("125305")}));return b("React").createElement("span",{className:"_61n2"},b("React").createElement(b("SUIGlyphIcon.react"),{onClick:this.$5,srcDefault:g("125313")}))};d.$7=function(){return b("React").createElement("div",{className:"_707c"},b("React").createElement("div",{"aria-selected":this.props.highlighted,className:"_61n4",key:this.props.key,onMouseDown:this.$1,onMouseEnter:this.$2,role:this.props.role},this.props.entry.getTitle()),b("React").createElement("div",{className:"_707d"},b("React").createElement(b("FDSHelpMessage.react"),{position:"right",value:k(this.props.entry.getUniqueID())})))};d.render=function(){var a=j[this.props.entry.getUniqueID()],c="_2cal"+(a?"":" _707e")+(this.$3.bind(this)()?" _61n3":"")+(this.props.highlighted&&!this.props.disabled?" _5-rn":"")+(this.props.disabled?" _5-ro":"");return b("React").createElement("div",{className:c},this.$6(),a?this.$7():b("React").createElement("li",{"aria-selected":this.props.highlighted,className:"_61n4",key:this.props.key,onMouseDown:this.$1,onMouseEnter:this.$2,role:this.props.role},this.props.entry.getTitle()))};return c}(b("React").Component);a.defaultProps={role:"option"};e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentCategoryTypeaheadView.react",["cx","PagesSettingsInstreamAdsBlockListContentCategoryTypeaheadItem.react","React"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var c,d;for(var e=arguments.length,f=new Array(e),g=0;g=0,enableSubcategories:d.props.enableSubcategories,entry:a,expand:d.props.expandStates.get(a.getUniqueID()),key:a.getUniqueID(),onSelect:d.props.onSelect,toggleExpand:d.props.toggleExpand})},c)||babelHelpers.assertThisInitialized(d)}var d=c.prototype;d.render=function(){return b("React").createElement("div",{className:"_3rtv"},b("React").createElement("ul",null,this.props.entries.map(this.renderItem,this)))};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentCategoryTypeahead.react",["cx","fbt","InstreamAdsBlockListCategoryMaps","PagesSettingsInstreamAdsBlockListContentCategoryTypeaheadView.react","PagesSettingsInstreamAdsBlockListContentStore","React","SearchableEntry","SearchableTextInput.react","StaticSearchSource"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b){__p&&__p();var c;c=a.call(this,b)||this;c.$4=function(a){c.props.onShowView(),a.stopPropagation()};c.$8=function(a){c.setState({entries:a},function(){return c.$14()})};c.$13=function(a){var b=c.$16(a),d=c.state.expandStates;d.set(a,!d.get(a));b.map(function(a){d.set(a,!d.get(a))});c.setState({expandStates:d},function(){return c.$8(c.state.entries)})};c.$12=function(a){c.props.onSelected&&c.props.onSelected(a.getUniqueID(),a.getTitle())};c.state={entries:c.$1(),entriesToShow:c.$1(),excludedEntries:c.props.blockedCategories,expandStates:c.$2.bind(babelHelpers.assertThisInitialized(c))(),focused:!1,queryString:"",searchSource:c.$3.bind(babelHelpers.assertThisInitialized(c))()};return c}var d=c.prototype;d.render=function(){var a=null;this.props.editable||this.props.isBusinessLevel?a=h._("Search Categories"):a=h._("Only admins can add or remove blocked categories.");return b("React").createElement("div",{onClick:this.$4,role:"presentation"},b("React").createElement("div",{className:"_5-6o"+(this.state.focused?" _5-6p":"")+(!this.props.editable||this.props.processing?" _17g0":"")},b("React").createElement(b("SearchableTextInput.react"),{disabled:!this.props.editable||this.props.processing,onBlur:this.$5.bind(this),onChange:this.$6.bind(this),onClear:this.$7.bind(this),onEntriesFound:this.$8,onFocus:this.$9.bind(this),placeholder:a,queryString:this.state.queryString,searchOnFocus:!0,searchSource:this.state.searchSource})),this.$10.bind(this)())};d.$10=function(){return this.props.viewHidden?null:b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentCategoryTypeaheadView.react"),{entries:this.state.entriesToShow,addedEntries:this.$11(),expandStates:this.state.expandStates,enableSubcategories:this.props.enableSubcategories,onSelect:this.$12,toggleExpand:this.$13})};d.$11=function(){return this.state.excludedEntries.concat(this.props.blockedCategories).map(function(a){return a.id})};d.$14=function(){__p&&__p();var a=this,c=b("InstreamAdsBlockListCategoryMaps").CategoryParentToChildMap,d=b("InstreamAdsBlockListCategoryMaps").DerivedCreatorSensitiveCategories,e=b("PagesSettingsInstreamAdsBlockListContentStore").getAllCategories(),f=this.state.entries.map(function(a){return a.getUniqueID().toString()}),g=[],h=[];e.map(function(e,i){(c[e.id]||d[e.id])&&f.includes(e.id)?(h.push(new(b("SearchableEntry"))({uniqueID:e.id,title:e.name,order:i})),a.state.queryString?a.$15(e.id):null):c[e.id]?a.$16(e.id).some(function(c,d){if(f.includes(c)){h.push(new(b("SearchableEntry"))({uniqueID:e.id,title:e.name,order:i}));a.$15(e.id);g.push(e);return!0}a.$17(e.id);return!1}):f.includes(e.id)&&a.state.expandStates.get(e.id)&&h.push(new(b("SearchableEntry"))({uniqueID:e.id,title:e.name,order:i}))});this.setState({excludedEntries:g,entriesToShow:h})};d.$2=function(){var a=b("PagesSettingsInstreamAdsBlockListContentStore").getAllCategories(),c=new Map();a.map(function(a){c.set(a.id,!1)});return c};d.$15=function(a){var b=this.$16(a),c=this.state.expandStates;c.set(a,!0);b.map(function(a){c.set(a,!0)});this.setState({expandStates:c})};d.$17=function(a){var b=this.$16(a),c=this.state.expandStates;c.set(a,!1);b.map(function(a){c.set(a,!1)});this.setState({expandStates:c})};d.$6=function(a){var b=this.state.expandStates;a.target.value.length===0&&b.forEach(function(a,c){b.set(c,!1)});this.setState({queryString:a.target.value,expandStates:b})};d.$7=function(a){this.setState({queryString:""})};d.$9=function(){this.setState({queryString:"",focused:!0})};d.$5=function(){this.setState({queryString:"",focused:!1})};d.$1=function(){var a=b("PagesSettingsInstreamAdsBlockListContentStore").getAllCategories();return a.map(function(a,c){return new(b("SearchableEntry"))({uniqueID:a.id,title:a.name,order:c})})};d.$3=function(){return new(b("StaticSearchSource"))(this.$1())};d.$16=function(a){return Object.prototype.hasOwnProperty.call(b("InstreamAdsBlockListCategoryMaps").DerivedCreatorSensitiveCategories,a)?[]:b("InstreamAdsBlockListCategoryMaps").CategoryParentToChildMap[a].map(function(a){return a.toString()})};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentCategoryItem.react",["cx","InstreamAdsBlockListCategoryMaps","React","XUICloseButton.react"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b){b=a.call(this,b)||this;b.state={isActive:!1};return b}var d=c.prototype;d.render=function(){var a=null;this.state.isActive&&this.props.editable&&(a=b("React").createElement(b("XUICloseButton.react"),{className:"_19tb",onClick:this.$1.bind(this),size:"small"}));var c="_19ru"+(this.$2.bind(this)()?" _em7":"")+(this.props.disabled?" _em8":"");return b("React").createElement("li",{key:this.props.categoryId,className:c,onMouseEnter:this.$3.bind(this),onMouseLeave:this.$4.bind(this)},b("React").createElement("div",{className:"_19t1"},this.props.name),a)};d.$1=function(){this.props.onDeleteItem(this.props.categoryId)};d.$3=function(){this.setState({isActive:!0})};d.$4=function(){this.setState({isActive:!1})};d.$2=function(){var a=b("InstreamAdsBlockListCategoryMaps").CategoryParentToChildMap,c=b("InstreamAdsBlockListCategoryMaps").DerivedCreatorSensitiveCategories;return a[this.props.categoryId]||c[this.props.categoryId]?!1:!0};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentCategoryView.react",["cx","InstreamAdsBlockListCategoryMaps","PagesSettingsInstreamAdsBlockListContentCategoryItem.react","PagesSettingsInstreamAdsBlockListContentStore","React","ScrollableArea.react"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var c,d;for(var e=arguments.length,f=new Array(e),g=0;g=0,key:a.id,name:a.name,onDeleteItem:d.props.onDeleteItem})},c)||babelHelpers.assertThisInitialized(d)}var d=c.prototype;d.render=function(){return this.props.categories.length===0?null:b("React").createElement(b("ScrollableArea.react"),{className:"_19rq"+(this.props.editable?"":" _17g0"),maxHeight:180,shadow:!1},b("React").createElement("ul",{className:"_19te"},this.$1().map(this.renderItem,this)))};d.$1=function(){__p&&__p();var a=this,c=b("InstreamAdsBlockListCategoryMaps").CategoryParentToChildMap,d=b("PagesSettingsInstreamAdsBlockListContentStore").getAllCategories(),e=this.props.categories.map(function(a){return a.id}),f=[];d.map(function(b,d){c[b.id]&&e.includes(b.id)?f.push(b):c[b.id]?c[b.id].some(function(c,d){if(e.includes(c.toString())&&a.props.enableSubcategories){f.push(b);return!0}return!1}):e.includes(b.id)&&f.push(b)});return f};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentPageTypeahead.react",["cx","fbt","CurrentUser","React","WebAsyncSearchSource","XUITypeahead.react"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b){b=a.call(this,b)||this;b.state={queryString:null,searchSource:b.$1.bind(babelHelpers.assertThisInitialized(b))(),focused:!1};return b}var d=c.prototype;d.render=function(){var a=null;this.props.editable||this.props.isBusinessLevel?a=h._("Search Pages"):a=h._("Only admins can add or remove blocked Pages.");return b("React").createElement("div",{className:"_5-6o"+(this.state.focused?" _5-6p":"")+(!this.props.editable||this.props.processing?" _17g0":"")},b("React").createElement(b("XUITypeahead.react"),{disabled:!this.props.editable||this.props.processing,excludedEntries:this.props.blockedPages.reduce(function(a,b){a[b.id]=b.id;return a},{}),onBlur:this.$2.bind(this),onChange:this.$3.bind(this),onClear:this.$4.bind(this),onFocus:this.$5.bind(this),onSelectAttempt:this.$6.bind(this),placeholder:a,queryString:this.state.queryString,searchSource:this.state.searchSource,viewStyle:"rich"}))};d.$6=function(a){this.props.onSelected&&this.props.onSelected(a.getUniqueID(),a.getTitle()),this.setState({queryString:null})};d.$3=function(a){this.setState({queryString:a.target.value})};d.$4=function(a){this.setState({queryString:null})};d.$5=function(){this.setState({queryString:"",focused:!0})};d.$2=function(){this.setState({queryString:"",focused:!1})};d.$1=function(){var a=this.props.pageId;this.props.businessId&&(a=b("CurrentUser").getID());a={filter:["page"],viewer:a,rsp:"mentions",bsp:"true"};return new(b("WebAsyncSearchSource"))({queryRequests:[{uri:"/ajax/typeahead/search.php",data:babelHelpers["extends"]({is_bootstrap:!1},a)}],bootstrapRequests:[{uri:"/ajax/typeahead/first_degree.php",data:babelHelpers["extends"]({is_bootstrap:!0},a)}],auxiliaryFields:{verified:"is_verified"}})};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentPageItem.react",["cx","React","XUICloseButton.react"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b){b=a.call(this,b)||this;b.state={isActive:!1};return b}var d=c.prototype;d.render=function(){var a=null;this.state.isActive&&this.props.editable&&(a=b("React").createElement(b("XUICloseButton.react"),{className:"_19tb",onClick:this.$1.bind(this),size:"small"}));return b("React").createElement("li",{key:this.props.pageId,className:"_19ru",onMouseEnter:this.$2.bind(this),onMouseLeave:this.$3.bind(this)},b("React").createElement("div",{className:"_19t1"},this.props.title),a)};d.$1=function(){this.props.onDeleteItem(this.props.pageId)};d.$2=function(){this.setState({isActive:!0})};d.$3=function(){this.setState({isActive:!1})};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentPageView.react",["cx","PagesSettingsInstreamAdsBlockListContentPageItem.react","React","ScrollableArea.react"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.renderItem=function(a){return b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentPageItem.react"),{blockListId:this.props.blockListId,editable:this.props.editable,key:a.id,onDeleteItem:this.props.onDeleteItem,pageId:a.id,title:a.title})};d.render=function(){if(this.props.pages.length===0)return null;var a=this.renderItem.bind(this);return b("React").createElement(b("ScrollableArea.react"),{className:"_19rq"+(this.props.editable?"":" _17g0"),maxHeight:180,shadow:!1},b("React").createElement("ul",{className:"_19te"},this.props.pages.map(a)))};return c}(b("React").Component);e.exports=a}),null); __d("XPagesSettingsInstreamAdsBlockListTargetPageQueryController",["XController"],(function(a,b,c,d,e,f){e.exports=b("XController").create("/adbreaks/block_list/query/target_page/",{business_id:{type:"FBID",required:!0},value:{type:"String"},offset:{type:"Int",defaultValue:0},limit:{type:"Int",defaultValue:100}})}),null); __d("PagesSettingsInstreamAdsBlockListContentTargetPageTypeahead.react",["cx","fbt","React","SearchableEntry","WebAsyncSearchSource","XPagesSettingsInstreamAdsBlockListTargetPageQueryController","XUITypeahead.react"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b){b=a.call(this,b)||this;b.state={queryString:null,searchSource:b.$1.bind(babelHelpers.assertThisInitialized(b))(),focused:!1};return b}var d=c.prototype;d.render=function(){var a=null;this.props.editable?a=h._("Search Pages"):a=h._("Only program admins can add or remove blocked Pages.");return b("React").createElement("div",{className:"_5-6o"+(this.state.focused?" _5-6p":"")+(!this.props.editable||this.props.processing?" _17g0":"")},b("React").createElement(b("XUITypeahead.react"),{disabled:!this.props.editable||this.props.processing,excludedEntries:this.props.targetPages.reduce(function(a,b){a[b.id]=b.id;return a},{}),onBlur:this.$2.bind(this),onChange:this.$3.bind(this),onClear:this.$4.bind(this),onFocus:this.$5.bind(this),onSelectAttempt:this.$6.bind(this),placeholder:a,queryString:this.state.queryString,searchSource:this.state.searchSource,showEntriesOnFocus:!0}))};d.$6=function(a){this.props.onSelected&&this.props.onSelected(a.getUniqueID(),a.getTitle()),this.setState({queryString:null})};d.$3=function(a){this.setState({queryString:a.target.value})};d.$4=function(a){this.setState({queryString:null})};d.$5=function(){this.setState({queryString:"",focused:!0})};d.$2=function(){this.setState({queryString:"",focused:!1})};d.$1=function(){var a=b("XPagesSettingsInstreamAdsBlockListTargetPageQueryController").getURIBuilder().setFBID("business_id",this.props.businessId).getURI().toString();return new(b("WebAsyncSearchSource"))({queryRequests:[{uri:a}],bootstrapRequests:[{uri:a}],packageFn:function(a,c){return new(b("SearchableEntry"))({uniqueID:a.uid,title:a.text,photo:a.photo})},getAllForEmptyQuery:!0})};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentView.react",["cx","fbt","ix","AbstractTextInput.react","Image.react","LayerFadeOnHide","Link.react","LoadingDialog.react","PagesSettingsInstreamAdsBlockListContentCategoryTypeahead.react","PagesSettingsInstreamAdsBlockListContentCategoryView.react","PagesSettingsInstreamAdsBlockListContentPageTypeahead.react","PagesSettingsInstreamAdsBlockListContentPageView.react","PagesSettingsInstreamAdsBlockListContentTargetPageTypeahead.react","React","Tooltip.react","XUICheckboxInput.react","XUIDialog.react","XUIDialogBody.react","XUIDialogButton.react","XUIDialogFooter.react","XUIDialogTitle.react","XUIGrayText.react","XUINotice.react","XUIText.react","gkx"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){__p&&__p();var d;d=a.call(this,c)||this;d.$1=b("gkx")("702230");d.$4=function(){d.setState({categoryViewHidden:!0})};d.$5=function(){d.setState({categoryViewHidden:!1})};d.$3=function(){d.setState({categoryViewHidden:!0})};d.state={categoryViewHidden:!0};return d}var d=c.prototype;d.render=function(){if(!this.props.allContentLoaded)return b("React").createElement(b("LoadingDialog.react"),{onToggle:this.props.onToggle});var a=b("React").createElement(b("XUIDialogButton.react"),{action:"cancel",use:"default",label:h._("Cancel")}),c=null;this.$2()?c=b("React").createElement(b("XUIDialogButton.react"),{action:"confirm",use:"confirm",disabled:this.props.requestSent||!this.props.editable,label:h._("Create"),onClick:this.props.onClickConfirmButton}):c=b("React").createElement(b("XUIDialogButton.react"),{action:"confirm",use:"confirm",disabled:this.props.requestSent||!this.props.editable,label:h._("Save"),onClick:this.props.onClickConfirmButton});return b("React").createElement("div",null,b("React").createElement(b("XUIDialog.react"),{shown:!this.props.updatedBlockListContent,behaviors:{LayerFadeOnHide:b("LayerFadeOnHide")},titleID:"block-list-content-dialog-title",width:600,onToggle:this.props.onToggle,layerHideOnBlur:!1},b("React").createElement(b("XUIDialogTitle.react"),null,this.renderTitle.bind(this)()),b("React").createElement(b("XUIDialogBody.react"),{className:"_5-6r",onClick:this.$3},this.renderError.bind(this)(),this.renderDescription.bind(this)(),this.renderBizEditMessage.bind(this)(),this.renderPageContent.bind(this)(),this.renderCategoryContent.bind(this)(),this.renderNameInputContent.bind(this)(),this.renderBusinessFeatures.bind(this)(),this.renderPageLevelCheckbox.bind(this)()),b("React").createElement(b("XUIDialogFooter.react"),null,a,c)))};d.renderTitle=function(){return this.$2()?b("React").createElement("div",null,h._("Create Block List For Ad Breaks")):b("React").createElement("div",null,h._("Edit Block List For Ad Breaks"))};d.renderDescription=function(){return this.props.businessId?b("React").createElement(b("XUIText.react"),{className:"_5-6t"},h._("Prevent ads from specific Pages or categories from appearing in the videos on your Pages. You can add block lists to specific Pages to make it available for your admins to use. Ads for gambling and dating are restricted by default. Ad restrictions don't apply to adjacent content.")):b("React").createElement(b("XUIText.react"),{className:"_5-6t"},h._("Prevent ads from specific Pages or categories from appearing in your videos. Ads for gambling and dating are restricted by default. Ad restrictions don't apply to adjacent content."))};d.renderBizEditMessage=function(){return this.props.businessId||!this.props.isBusinessLevel||this.props.editable?null:b("React").createElement(b("XUINotice.react"),{className:"_17nx",use:"notify",size:"small"},b("React").createElement(b("XUIText.react"),{weight:"bold",size:"header4"},h._("Block List Can't Be Edited")),b("React").createElement("br",null),h._("This block list was added in Business Manager and can only be edited by an admin in Business Manager."))};d.renderPageContent=function(){var a=b("React").createElement("div",{className:"_sup"},b("React").createElement("div",{className:"_5-6y"},h._("Blocked Pages"),this.renderTooltip(h._("This prevents ads from specific Pages from appearing in your videos.")))),c=b("React").createElement("div",{className:"_suq"},b("React").createElement("div",{className:"_sur"},b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentPageView.react"),{allLoaded:this.props.allContentLoaded,blockListId:this.props.blockListId,editable:this.props.editable&&!this.props.requestSent,pages:this.props.blockedPages,onDeleteItem:this.props.onDeletePage}),b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentPageTypeahead.react"),{blockedPages:this.props.blockedPages,blockListId:this.props.blockListId,businessId:this.props.businessId,editable:this.props.editable,isBusinessLevel:this.props.isBusinessLevel,pageId:this.props.pageId,processing:this.props.requestSent,onSelected:this.props.onAddPage})));return b("React").createElement("div",{className:"_5-6z"},a,c)};d.renderCategoryContent=function(){var a=b("React").createElement("div",{className:"_sup"},b("React").createElement("div",{className:"_5-6y"},h._("Blocked Categories"),this.renderTooltip(h._("Prevent ads that contain specific content from appearing in your videos. Choose the categories to block or select \"Not Categorized\" if you want to exclude videos that haven't been categorized yet. We can't guarantee that all videos related to each category can be avoided completely.")))),c=b("React").createElement("div",{className:"_suq"},b("React").createElement("div",{className:"_sur"},b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentCategoryView.react"),{allLoaded:this.props.allContentLoaded,blockListId:this.props.blockListId,categories:this.props.blockedCategories,editable:this.props.editable&&!this.props.requestSent,enableSubcategories:this.props.enableSubcategories,onDeleteItem:this.props.onDeleteCategory}),b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentCategoryTypeahead.react"),{blockedCategories:this.props.blockedCategories,blockListId:this.props.blockListId,businessId:this.props.businessId,editable:this.props.editable,enableSubcategories:this.props.enableSubcategories,isBusinessLevel:this.props.isBusinessLevel,pageId:this.props.pageId,processing:this.props.requestSent,viewHidden:this.state.categoryViewHidden,onHideView:this.$4,onShowView:this.$5,onSelected:this.props.onAddCategory}),this.$1?b("React").createElement("div",{className:"_70_j"},b("React").createElement(b("Link.react"),{href:"https://www.facebook.com/help/publisher/1995382877189247",target:"_blank"},h._("Learn more"),"\xa0"),h._("about these categories.")):null));return b("React").createElement("div",{className:"_5-6z"},a,c)};d.renderBusinessFeatures=function(){if(!this.props.businessId)return null;var a=b("React").createElement("div",{className:"_sup"},b("React").createElement("div",{className:"_5-6y"},h._("Add to Specific Pages"),this.renderTooltip(h._("Add this block list to specific Pages in your business to make it available for your Page admins to use.")))),c=b("React").createElement("div",{className:"_suq"},b("React").createElement("div",{className:"_sur"},b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentPageView.react"),{allLoaded:this.props.allContentLoaded,blockListId:this.props.blockListId,editable:this.props.editable&&!this.props.requestSent,pages:this.props.targetPages,onDeleteItem:this.props.onDeleteTargetPage}),b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentTargetPageTypeahead.react"),{blockListId:this.props.blockListId,businessId:this.props.businessId,editable:this.props.editable,pageId:this.props.pageId,processing:this.props.requestSent,onSelected:this.props.onAddTargetPage,targetPages:this.props.targetPages})));return b("React").createElement("div",{className:"_5-6z"},a,c)};d.renderNameInputContent=function(){var a=b("React").createElement("div",{className:"_sup"},b("React").createElement("div",{className:"_5-6y"},h._("Block List Name"),this.renderTooltip(h._("Give your block list a name that describes the Pages or categories you're blocking.")))),c=b("React").createElement("div",{className:"_suq"},b("React").createElement("div",{className:"_sur"},b("React").createElement(b("AbstractTextInput.react"),{className:"_12hn"+(!this.props.editable||this.props.requestSent?" _17g0":""),disabled:!this.props.editable||this.props.requestSent,placeholder:h._("Enter a name"),useLabel:!1,value:this.props.blockListName,onChange:this.onNameInputChanged.bind(this)})));return b("React").createElement("div",{className:"_5-6z"},a,c)};d.renderPageLevelCheckbox=function(){var a=b("React").createElement("div",{className:"_sup"},b("React").createElement("div",{className:"_5-6y"},b("React").createElement(b("XUICheckboxInput.react"),{checked:this.props.isPageLevel,disabled:this.props.requestSent||!this.props.editable,onChange:this.onCheckboxChanged.bind(this)}))),c=null;this.props.businessId?c=b("React").createElement("div",{className:"_suq"},b("React").createElement("div",{className:"_sur"},b("React").createElement(b("XUIText.react"),{display:"block",size:"meta1",weight:"bold"},h._("Save as a Page-level block list and apply to all videos.")),b("React").createElement(b("XUIGrayText.react"),{display:"block",size:"meta1"},h._({"*":"This block list will be applied to all videos on the Pages you've added.","_1":"This block list will be applied to all videos on the Page you've added."},[h._plural(this.props.targetPages.length)])))):c=b("React").createElement("div",{className:"_suq"},b("React").createElement("div",{className:"_sur"},b("React").createElement(b("XUIText.react"),{display:"block",size:"meta1",weight:"bold"},h._("Make this block list a default for this Page.")),b("React").createElement(b("XUIGrayText.react"),{display:"block",size:"meta1"},h._("Default block lists are automatically applied to all videos on this Page."))));return b("React").createElement("div",{className:"_5-6z"},a,c)};d.renderError=function(){return!this.props.errorInfo?null:b("React").createElement(b("XUINotice.react"),{className:"_17nx",use:"warn",size:"small"},b("React").createElement(b("XUIText.react"),{weight:"bold",size:"header4"},h._("Failed to update block list.")),b("React").createElement("br",null),this.props.errorInfo)};d.renderTooltip=function(a){return b("React").createElement(b("Tooltip.react"),{className:"_2pir",tooltip:a},b("React").createElement(b("Image.react"),{className:"_5-6u",src:i("28631")}))};d.onNameInputChanged=function(a){this.props.onChangeNameInput(a.target.value)};d.onCheckboxChanged=function(a){this.props.onChangePageLevelCheckbox(a.target.checked)};d.$2=function(){return this.props.blockListId===null};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListContentContainer",["FluxContainer","PagesSettingsInstreamAdsBlockListContentActions","PagesSettingsInstreamAdsBlockListContentStore","PagesSettingsInstreamAdsBlockListContentView.react","React"],(function(a,b,c,d,e,f){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}c.getStores=function(){return[b("PagesSettingsInstreamAdsBlockListContentStore")]};c.calculateState=function(a){a=b("PagesSettingsInstreamAdsBlockListContentStore").getState();return{allContentLoaded:a.allContentLoaded,blockedNonDerivedCategories:Array.from(a.blockedNonDerivedCategories),blockedDerivedCategories:Array.from(a.blockedDerivedCategories),blockedPages:Array.from(a.blockedPages),blockListId:a.blockListId,blockListName:a.blockListName,enableSubcategories:a.enableSubcategories,errorInfo:a.errorInfo,isBusinessLevel:a.isBusinessLevel,isPageLevel:a.isPageLevel,pageId:a.pageId,requestSent:a.requestSent,targetPages:Array.from(a.targetPages),updatedBlockListContent:a.updatedBlockListContent}};var d=c.prototype;d.render=function(){return b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentView.react"),{allContentLoaded:this.state.allContentLoaded,blockedCategories:this.state.blockedDerivedCategories.concat(this.state.blockedNonDerivedCategories),blockedPages:this.state.blockedPages,blockListId:this.state.blockListId,blockListName:this.state.blockListName,businessId:this.props.businessId,editable:this.props.editable,enableSubcategories:this.state.enableSubcategories,errorInfo:this.state.errorInfo,isBusinessLevel:this.state.isBusinessLevel,isPageLevel:this.state.isPageLevel,onAddCategory:b("PagesSettingsInstreamAdsBlockListContentActions").addCategoryToUI,onAddPage:b("PagesSettingsInstreamAdsBlockListContentActions").addPageToUI,onAddTargetPage:b("PagesSettingsInstreamAdsBlockListContentActions").addTargetPageToUI,onChangeNameInput:b("PagesSettingsInstreamAdsBlockListContentActions").updateName,onChangePageLevelCheckbox:b("PagesSettingsInstreamAdsBlockListContentActions").updatePageLevelCheckbox,onClickConfirmButton:b("PagesSettingsInstreamAdsBlockListContentActions").createOrUpdateBlockListContent,onDeleteCategory:b("PagesSettingsInstreamAdsBlockListContentActions").removeCategoryFromUI,onDeletePage:b("PagesSettingsInstreamAdsBlockListContentActions").removePageFromUI,onDeleteTargetPage:b("PagesSettingsInstreamAdsBlockListContentActions").removeTargetPageFromUI,onToggle:this.props.onToggle,pageId:this.state.pageId,requestSent:this.state.requestSent,targetPages:this.state.targetPages,updatedBlockListContent:this.state.updatedBlockListContent})};d.UNSAFE_componentWillMount=function(){b("PagesSettingsInstreamAdsBlockListContentActions").loadCategories(this.props.enableSubcategories)};return c}(b("React").Component);e.exports=b("FluxContainer").create(a,{pure:!1})}),null); __d("SUITableSubtitleCell.react",["cx","fbt","FlexLayout.react","React","SUIComponent","SUITableAbstractCell.react","SUITableCellTypes","SUITheme","cxMargin"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=b("SUITableCellTypes").DEFAULT_TABLE_CELL_PROPS;c=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b){return a.call(this,b)||this}var d=c.prototype;d.render=function(){var a=this.props,c=a.errorMessage,d=a.hasBorders,e=a.isModified,f=a.height;a=a.warningMessage;return b("React").createElement(b("SUITableAbstractCell.react"),{className:"_3bfi","data-testid":this.props["data-testid"],content:this.$SUITableSubtitleCell1(),errorMessage:c,hasBorders:d,height:f,isModified:e,warningMessage:a})};d.$SUITableSubtitleCell2=function(a){return typeof a==="string"||a instanceof h||typeof a==="number"};d.$SUITableSubtitleCell1=function(){var a=this.props,c=a.align,d=a.subtitle,e=a.title,f=a.titleIsSummary;a=a.leftIcon;var g=b("SUITheme").get(this).SUITableCell;c=c==="right";var h=this.$SUITableSubtitleCell2(e)?{"data-hover":"tooltip","data-tooltip-content":e,"data-tooltip-display":"overflow","data-tooltip-position":"above"}:null,i=this.$SUITableSubtitleCell2(d)?{"data-hover":"tooltip","data-tooltip-content":d,"data-tooltip-display":"overflow","data-tooltip-position":"above"}:null;f=f!=null?700:g.textStyles.primaryText.fontWeight;f=babelHelpers["extends"]({},g.textStyles.primaryText,{fontWeight:f});f=b("React").createElement(b("FlexLayout.react"),{align:c?"end":"start",className:"_13aw",direction:"vertical",justify:"center"},b("React").createElement("div",babelHelpers["extends"]({className:"ellipsis _13a-"+(c?" _13a_":""),style:f},h),e),b("React").createElement("div",babelHelpers["extends"]({className:"ellipsis _13b0"+(c?" _13a_":""),style:babelHelpers["extends"]({},g.textStyles.secondaryText)},i),d));return a==null?f:b("React").createElement(b("FlexLayout.react"),{align:"stretch",className:"_13aw",direction:"horizontal",justify:"all"},b("React").createElement(b("FlexLayout.react"),{align:"center",className:"_3-90",direction:"vertical",justify:"center"},a),f)};return c}(b("SUIComponent"));c.defaultProps=a;e.exports=c}),null); __d("AdBreakPortalInstreamAdsBlockListView.react",["ix","cx","fbt","AdBreakPortalInstreamAdsBlockListNameCell.react","Date.react","FDSSpinner.react","PagesSettingsInstreamAdsBlockListContentContainer","React","SimpleXUIDialog","SUIButton.react","SUICard.react","SUICardHeader.react","SUIGlyphIcon.react","SUISelector.react","SUISelectorOption.react","SUITableDEPRECATED.react","SUITableTypesDEPRECATED","asset"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();var j=b("SUITableTypesDEPRECATED").ORDER_DIRECTION;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){__p&&__p();var d;d=a.call(this,c)||this;d.$11=function(a){a==="delete"&&d.$12()};d.$6=function(a,b){var c;d.setState({orderBy:a,orderDirection:babelHelpers["extends"]({},d.state.orderDirection,(c={},c[a]=b===j.ASCENDING?j.DESCENDING:j.ASCENDING,c))})};d.$5=function(a){var b=babelHelpers["extends"]({},d.state.isSelectedByItemID);a.map(function(a){return b[a.id]=!0});d.setState({isSelectedByItemID:b})};d.$7=function(a){var b=babelHelpers["extends"]({},d.state.isSelectedByItemID);a.map(function(a){return b[a.id]=!1});d.setState({isSelectedByItemID:b})};d.$13=function(a,c,e){return b("React").createElement(b("AdBreakPortalInstreamAdsBlockListNameCell.react"),{blockList:a,isHovering:e,isSelected:c,onClick:d.$18})};d.$18=function(a){d.props.onSelectBlockList(a),d.setState({showBlockListContentDialog:!0})};d.$19=function(a){d.setState({showBlockListContentDialog:a})};d.$10=function(){d.props.onSelectBlockList(null),d.setState({showBlockListContentDialog:!0})};d.state={showBlockListContentDialog:!1,orderBy:"numPagesApplied",orderDirection:{dateCreated:j.ASCENDING,dateModified:j.ASCENDING,isPageLevel:j.ASCENDING,name:j.ASCENDING,numPagesApplied:j.ASCENDING},isSelectedByItemID:{}};return d}var d=c.prototype;d.render=function(){return b("React").createElement("div",null,this.$1())};d.$1=function(){return this.props.isLoading?b("React").createElement("div",{className:"_5_1x"},b("React").createElement(b("FDSSpinner.react"),null)):b("React").createElement(b("SUICard.react"),null,b("React").createElement(b("SUICardHeader.react"),null,this.$2()),b("React").createElement(b("SUITableDEPRECATED.react"),{borders:["top","inner"],columns:this.$3(),isSelectedByItemID:this.state.isSelectedByItemID,items:this.$4(),noItemsMessage:i._("No block lists created yet!"),selectionType:"rowWithCheckbox",totalItemCount:this.props.blockLists.length,onSelectItems:this.$5,onSortClick:this.$6,onUnselectItems:this.$7}),this.$8())};d.$2=function(){var a=this.$9();a=b("React").createElement(b("SUISelectorOption.react"),{disabled:a===0,value:"delete"},i._("Delete... ({Number of block lists to delete})",[i._param("Number of block lists to delete",a)]));return b("React").createElement("div",null,b("React").createElement(b("SUIButton.react"),{icon:b("React").createElement(b("SUIGlyphIcon.react"),{srcDefault:g("378289"),srcDisabled:g("407431")}),label:i._("Create Block List"),use:"default",onClick:this.$10}),b("React").createElement("div",{className:"_60t-"},b("React").createElement(b("SUISelector.react"),{placeholder:i._("Actions"),value:null,onChange:this.$11},a)))};d.$4=function(){var a=this.state.orderBy,b=this.state.orderDirection[a];return this.props.blockLists.sort(function(c,d){if(b===j.ASCENDING&&a==="name")return c[a].localeCompare(d[a]);else if(a==="name")return d[a].localeCompare(c[a]);else if(b===j.ASCENDING)return c[a]-d[a];else return d[a]-c[a]})};d.$9=function(){var a=this,b=0;Object.keys(this.state.isSelectedByItemID).map(function(c){a.state.isSelectedByItemID[c]&&b++});return b};d.$3=function(){return[{id:"name",label:i._("Name"),renderItem:this.$13,orderBy:"name",orderDirection:this.state.orderDirection.name,widthWeight:2},{id:"numPagesApplied",label:i._("Pages Applied"),widthWeight:1,orderBy:"numPagesApplied",orderDirection:this.state.orderDirection.numPagesApplied,renderItem:this.$14},{id:"isPageLevel",label:i._("Block List Type"),widthWeight:1,orderBy:"isPageLevel",orderDirection:this.state.orderDirection.isPageLevel,renderItem:this.$15},{id:"dateCreated",label:i._("Date Created"),widthWeight:1,orderBy:"dateCreated",orderDirection:this.state.orderDirection.dateCreated,renderItem:this.$16},{id:"dateModified",label:i._("Date Modified"),widthWeight:1,orderBy:"dateModified",orderDirection:this.state.orderDirection.dateModified,renderItem:this.$17}]};d.$14=function(a){return b("React").createElement("div",null,a.numPagesApplied)};d.$15=function(a){var c=null;a.isPageLevel?c=i._("Page"):c=i._("Video");return b("React").createElement("div",null,c)};d.$16=function(a){return b("React").createElement("div",null,b("React").createElement(b("Date.react"),{date:a.dateCreated,format:"M j, Y"}))};d.$17=function(a){return b("React").createElement("div",null,b("React").createElement(b("Date.react"),{date:a.dateModified,format:"M j, Y"}))};d.$8=function(){if(!this.state.showBlockListContentDialog)return null;var a=this.props.editable,c=null;this.props.selectedBlockList&&(a=this.props.selectedBlockList.editable&&this.props.editable,c=this.props.selectedBlockList.id);return b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentContainer"),{blockListId:c,businessId:this.props.businessId,editable:a,enableSubcategories:this.props.enableSubcategories,onToggle:this.$19})};d.$12=function(){var a=this,c=b("React").createElement("div",{className:"_4xfq"},i._({"*":"Are you sure you want to delete {number} block lists?","_1":"Are you sure you want to delete 1 block list?"},[i._plural(this.$9(),"number")]));b("SimpleXUIDialog").showConfirm(c,i._("Delete"),function(b){b&&a.$20()})};d.$20=function(){var a=this,b=[];Object.keys(this.state.isSelectedByItemID).map(function(c){a.state.isSelectedByItemID[c]&&b.push(c)});this.props.onDeleteBlockLists(b);this.setState({isSelectedByItemID:{}})};return c}(b("React").Component);e.exports=a}),null); __d("DistrictTargetingUtils",["fbt"],(function(a,b,c,d,e,f,g){"use strict";a={getComposerNUXContent:function(){return g._("New! Set the visibility of any post so that only people in your district can see it on your Page.")}};e.exports=a}),null); __d("FBMultiSegmentBarTooltip.react",["cx","React"],(function(a,b,c,d,e,f,g){__p&&__p();a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){var a=this.props.position==="above";return b("React").createElement("span",{className:"_3yr-"+(this.props.shown?" _3yr_":"")},b("React").createElement("div",{className:"uiContextualLayer"+(a?"":" uiContextualLayerBelowCenter")+(a?" uiContextualLayerAboveCenter":"")},b("React").createElement("div",{className:"uiTooltipX _3ys4"},b("React").createElement("div",{className:"tooltipContent tooltipText"},this.props.tooltip),b("React").createElement("i",{className:"arrow"}))))};d.show=function(){this.setState({shown:!0})};d.hide=function(){this.setState({shown:!1})};return c}(b("React").Component);a.defaultProps={tooltip:"",shown:!1};e.exports=a}),null); __d("FBMultiSegmentBar.react",["cssVar","cx","FBMultiSegmentBarTooltip.react","React","ShimButton.react","emptyFunction","joinClasses","shallowCompare"],(function(a,b,c,d,e,f,g,h){__p&&__p();a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){__p&&__p();var d;d=a.call(this,c)||this;d.$3=function(a,c){var e={left:d.$2(a.startPercentage)+"%",right:d.$2(100-a.endPercentage)+"%"},f=d.props.hasHighlightedSegment||d.state.hasHighlightedSegment,g=d.props.onSegmentClick||b("emptyFunction");f=a.highlighted||!f?a.highlightedColor||d.props.highlightedSegmentsColor:a.color||d.props.segmentsColor;f={backgroundColor:f};return b("React").createElement("span",{key:"segment_"+c,style:e,className:"_1pud _3kkj",onMouseEnter:d.$4.bind(babelHelpers.assertThisInitialized(d),a),onMouseLeave:d.$5.bind(babelHelpers.assertThisInitialized(d),a)},b("React").createElement(b("FBMultiSegmentBarTooltip.react"),{ref:"tooltip_"+c,tooltip:a.tooltip,position:d.props.tooltipPosition,shown:a.highlighted}),b("React").createElement(b("ShimButton.react"),{className:b("joinClasses")(a.customSegmentClassName,"_3kkt"+(d.props.onSegmentClick?" _5ytw":"")),onClick:function(b){return g(a,b)},style:f}))};d.state={hasHighlightedSegment:!1};return d}var d=c.prototype;d.shouldComponentUpdate=function(a,c){return b("shallowCompare")(this,a,c)};d.UNSAFE_componentWillReceiveProps=function(a){a=a.segments.some(function(a){return a.highlighted});this.setState({hasHighlightedSegment:a})};d.$1=function(a){__p&&__p();var b=-1;a=a.slice(0);a.sort(function(a,b){return a.startPercentage-b.startPercentage});var c=0;for(var d=1;df.endPercentage&&(f.endPercentage=e.endPercentage),e.startPercentage=b):c=d}return a.filter(function(a){return a.startPercentage!==b})};d.$2=function(a){if(a<0)return 0;else if(a>100)return 100;return a};d.$4=function(a){this.props.onSegmentHoverStart?this.props.onSegmentHoverStart(a):a.tooltip&&(a.highlighted=!0,this.setState({hasHighlightedSegment:!0}))};d.$5=function(a){this.props.onSegmentHoverEnd?this.props.onSegmentHoverEnd():this.state.hasHighlightedSegment&&(a.highlighted=!1,this.setState({hasHighlightedSegment:!1}))};d.render=function(){var a=this.props.shouldMergeOverlappingSegments?this.$1(this.props.segments):this.props.segments;return b("React").createElement("div",{className:b("joinClasses")(this.props.className,"_3kku")},a.map(this.$3,this),b("React").createElement("div",{className:"_3kkv"}))};return c}(b("React").Component);a.defaultProps={segments:[],segmentsColor:"#fa3e3e",highlightedSegmentsColor:"#fa3e3e",hasHighlightedSegment:!1,shouldMergeOverlappingSegments:!1};e.exports=a}),null); __d("BUIPresetFilterModes_DEPRECATED",["React"],(function(a,b,c,d,e,f){"use strict";a=b("React").PropTypes;c={DRAWER:"drawer",POPOVER:"popover",propTypes:a.oneOf(["drawer","popover"])};e.exports=c}),null); __d("BUIPresetFiltersHeader_DEPRECATED.react",["cx","BUIPresetFilterModes_DEPRECATED","InlineBlock.react","React"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=b("React").PropTypes;c=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f0};return a}();e.exports=a}),null); __d("BUIPresetFiltersItem_DEPRECATED",["invariant","ClientIDs"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(){__p&&__p();function a(a,c,d,e,f,g){this.$1=a,this.$2=!!c,this.$3=!!d,this.$4=e,this.$5=f,this.$6=g||b("ClientIDs").getNewClientID()}var c=a.prototype;c.getText=function(){return this.$1};c.isChecked=function(){return this.$2};c.isDisabled=function(){return this.$3};c.getFilterReference=function(){return this.$4};c.getID=function(){return this.$6};c.canBeDeleted=function(){return!!this.$5};c.doOnDelete=function(){this.$5||g(0,5355),this.$5(this)};return a}();e.exports=a}),null); __d("BUIPresetFiltersSelectableItem_DEPRECATED.react",["cx","BUIAdoptionCloseButton.react","BUIPresetFilterModes_DEPRECATED","InlineBlock.react","React","XUIContextualDialog.react","XUIContextualDialogBody.react","nullthrows"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=b("React").PropTypes;var h=200;c=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var c,d;for(var e=arguments.length,f=new Array(e),g=0;gj){var d=this.state.prevSelected;d===-1&&a!==0&&(d=0);a=this.state.heightList.set(a,c);d!==-1&&(a=a.set(d,0));this.setState({heightList:a,prevSelected:d})}}};d.$7=function(a){if(!this.$2())return;this.setState({prevSelected:this.state.selected!=null?this.state.selected:-1});if(this.state.selected===a){var b=this.state.heightList.set(a,0);this.setState({heightList:b})}b=this.state.selected===a&&this.state.selected!==void 0?{selected:void 0}:{selected:a};this.setState(b)};return a}(b("React").PureComponent);k.propTypes={className:a.string,filterBlacklist:a.array,filterGroups:a.arrayOf(a.instanceOf(b("BUIPresetFiltersGroup_DEPRECATED"))).isRequired,shouldAnimate:a.bool,uniqueFilters:a.array,mode:b("BUIPresetFilterModes_DEPRECATED").propTypes.isRequired,isSubgroup:a.bool,shouldRenderUniqueFiltersFirst:a.bool,maxWidth:a.string};k.defaultProps=c;var l=function(c){__p&&__p();babelHelpers.inheritsLoose(a,c);function a(){__p&&__p();var a,d;for(var e=arguments.length,f=new Array(e),g=0;gf;h&&!this.state.isHidden&&(e=e.filter(function(b){return a.state.filterIDToRankMap[b.getID()]<=f}),g=this.$7(c));return b("React").createElement(b("BUIPopoverSection_DEPRECATED.react"),{className:this.props.className,filterBlacklist:this.props.filterBlacklist,id:c.getID(),isHidden:this.state.isHidden,isAnyChecked:c.getFilters().some(function(a){return a.isChecked()}),isCollapsible:c.isCollapsible(),onCheckmarkClick:this.$5,onTextClick:this.$2,mode:this.props.mode,shouldAnimate:this.props.shouldAnimate,title:c.getTitle(),renderItems:b("curry")(this.$6,e)},this.state.isHidden?null:d,g)};return a}(b("React").PureComponent);l.propTypes={filterBlacklist:a.array,group:a.instanceOf(b("BUIPresetFiltersGroup_DEPRECATED")).isRequired,isHidden:a.bool,isPrev:a.bool,mode:b("BUIPresetFilterModes_DEPRECATED").propTypes.isRequired,onHeaderClick:a.func,shouldAnimate:a.bool};var m=function(c){__p&&__p();babelHelpers.inheritsLoose(a,c);function a(){var a,b;for(var d=arguments.length,e=new Array(d),f=0;f-1&&g.indexOf(b)>-1){e=!0;break}}i[c]=e;return e}function a(a,c){__p&&__p();var d=c.fieldConfig,e=d?d.field.name:null,f={},i=[],j;if(!d&&a.defaultFilter){var k=a.defaultFilter.field;d=b("AdsGenericFilterFieldConfigUtil").getConfigByField(a.fieldsConfig,k);e=d.field.name}a.filterBlacklist&&a.filterBlacklist.forEach(function(a){a instanceof b("AdsGenericFilter")||g(0,4772),f[a.field.name]=!0});a.validFieldConfigs.forEach(function(a){var b=a.field.name;f[b]||(b===e&&(j=!0),i.push(a))});j||(d=i[0],c.operatorConfig=void 0);d||g(0,4773);c.fieldConfig=d;c.fieldConfigOptions=i;c.fieldValueRenderer=d.valueRenderer||h;c.fieldValueParser=d.valueParser||h}function c(a,c){var d=c.fieldConfig;d||g(0,4774);var e=c.operatorConfig,f=e&&e.operator,h=[],i;!e&&a.defaultFilter&&(f=a.defaultFilter.operator,e=b("AdsGenericFilterOperatorConfigUtil").getConfigByOperator(f));d&&d.operators.forEach(function(a){a.operator===f&&(i=!0),h.push(a)});i||(e=h[0]);c.operatorConfig=e;c.operatorConfigOptions=h}function d(a,b){__p&&__p();var c=b.fieldConfig,d=b.value,e=b.valueField,f=b.valueOperator,g=m(c);if(d===void 0&&a.defaultFilter)d=c.defaultValue||a.defaultFilter.value,e=a.defaultFilter.field,f=a.defaultFilter.operator;else if(c&&!c.isFieldOnly){a=b.operatorConfig.operator;var h=c.field;if(!f||!a||!l(f,a)||!k(e,h)){f=a;e=h;switch(a){case"EQUAL":case"NOT_EQUAL":h=c.values;Array.isArray(h)&&h.length?d=h[0].value:d=g;break;case"IN_RANGE":case"NOT_IN_RANGE":d=[g,g];break;case"IN":case"NOT_IN":d=[];break;case"ANY":case"ALL":case"NONE":d=[];break;default:d=g}}}else d=g;b.value=d;b.valueField=e;b.valueOperator=f}function f(a,b){__p&&__p();var c=b.fieldConfig,d=c.supportedPrefixes;c=b.prefixes;!c&&a.defaultFilter&&(c=a.defaultFilter.prefixes.map(function(a){return a}));!d?c=[]:!c||c.length!==d.length?c=d.map(function(a){return null}):c=c.map(function(a,b){return d[b].prefixes.find(function(b){return a&&b.prefix===a})?a:null});b.prefixes=c;b.prefixHoverShown=b.prefixHoverShown||!1}function m(a){return a.isFieldOnly?a.defaultValue||0:a.field.type===b("AdsGenericFilterFieldType").DATE_RANGE?null:""}a={calibrateFieldState:a,calibrateOperatorState:c,calibrateValueState:d,calibratePrefixState:f};e.exports=a}),null); __d("BUIFilterTokenSearchableInputUtils",["invariant","SearchableEntry"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a={getSUIFieldSearchSource:function(a,c){__p&&__p();var d=this;if(!c)return a.map(function(a){return d.getSearchableEntry(a)});var e=new Map();a.forEach(function(a){var b=a.field.toString();e.has(b)&&g(0,167,b);e.set(b,a)});var f=[];c.forEach(function(a){switch(a.type){case"separator":break;case"item":var c=e.get(a.item);f.push(d.getSearchableEntry(c));break;case"group":a.children.forEach(function(c){c=e.get(c);c&&f.push(new(b("SearchableEntry"))({auxiliaryData:c,title:c.text,type:a.label,uniqueID:c.field.toString()}))});break}});return f},getSearchableEntry:function(a){return new(b("SearchableEntry"))({auxiliaryData:a,title:a.text,uniqueID:a.field.toString()})}};e.exports=a}),null); __d("BUIFilterTokenTextInput.react",["cx","fbt","BUIComponent","ClockFormatConverter","ContextualDialog.react","Keys","React","ReactDOM","focusNode"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=b("React").PropTypes;var i=/^-?\d+\.?\d*$/;c=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){__p&&__p();var d;d=a.call(this,c)||this;d.$BUIFilterTokenTextInput4=function(a){a.keyCode===b("Keys").RETURN&&d.props.onEnter?d.props.onEnter(a):a.keyCode===b("Keys").ESC&&d.props.onEscape&&d.props.onEscape(a)};d.$BUIFilterTokenTextInput7=function(a){__p&&__p();var c=a.target.value,e=d.$BUIFilterTokenTextInput3(c);if(c!==e){a.preventDefault();if(d.state.tooltip===null){var f;switch(d.props.format){case"number":case"percentage":f=h._("Please enter numbers only");break;case"duration":f=h._("Please use clock format (mm {Time Separator} ss)",[h._param("Time Separator",b("ClockFormatConverter").TIME_SEPARATOR)]);break;default:return}d.setState({tooltip:f})}return}d.state.tooltip&&d.setState({tooltip:null});d.$BUIFilterTokenTextInput8()&&d.setState({tempValue:e});d.props.onChange(e)};d.$BUIFilterTokenTextInput5=function(){d.setState({focused:!0})};d.$BUIFilterTokenTextInput6=function(){d.setState(function(b,a){return{focused:!1,tooltip:null,tempValue:d.$BUIFilterTokenTextInput8()?null:b.tempValue}})};d.$BUIFilterTokenTextInput8=function(){return d.props.format==="currency"||d.props.format==="percentage"};d.$BUIFilterTokenTextInput1=null;d.state={focused:!1,tempValue:null,tooltip:null};return d}var d=c.prototype;d.componentDidMount=function(){this.props.shouldFocus&&this.$BUIFilterTokenTextInput2()};d.UNSAFE_componentWillReceiveProps=function(a){a.shouldFocus&&!this.state.focused&&this.$BUIFilterTokenTextInput2()};d.componentWillUnmount=function(){clearTimeout(this.$BUIFilterTokenTextInput1)};d.$BUIFilterTokenTextInput2=function(){var a=this,c=b("ReactDOM").findDOMNode(this.refs.input);c instanceof HTMLElement&&(this.$BUIFilterTokenTextInput1=setTimeout(function(){b("focusNode")(c),a.$BUIFilterTokenTextInput1=null},400))};d.renderLayers=function(){var a=this;if(this.state.tooltip)return b("React").createElement(b("ContextualDialog.react"),{contextRef:function(){return a.refs.main},shown:!0,position:"above",key:"layer"},b("React").createElement("div",{className:"_48f_"},this.state.tooltip));else return null};d.render=function(){var a=this.$BUIFilterTokenTextInput3(this.props.value),c=this.props.placeholder||"",d="_48g0"+(this.state.focused?" _48g1":""),e="_48g2"+(a?" _48g3":"");return b("React").createElement("span",{className:"_4m56"},b("React").createElement("div",{className:d,ref:"main"},b("React").createElement("div",{"aria-hidden":"true",className:"_48g4"},(a||"-").replace(/\s/g,"-")),b("React").createElement("div",{"aria-hidden":"true",className:"_48g5"},c.replace(/\s/g,"-")),b("React").createElement("div",{className:"_48g6"},b("React").createElement("input",{"data-testid":"filter-token-text-input",title:c,placeholder:c,onKeyDown:this.$BUIFilterTokenTextInput4,onFocus:this.$BUIFilterTokenTextInput5,onBlur:this.$BUIFilterTokenTextInput6,onChange:this.$BUIFilterTokenTextInput7,className:e,type:"text",value:this.state.tempValue!==null?this.state.tempValue:a,ref:"input"}))),this.renderLayers())};d.$BUIFilterTokenTextInput3=function(a){if(a)switch(this.props.format){case"number":a=i.test(a)?a:"";break;case"duration":a=b("ClockFormatConverter").validate(a,!0)?a:"";break;case"percentage":var c=parseFloat(a);isNaN(c)&&(a="")}return a};return c}(b("BUIComponent"));c.propTypes={format:a.oneOf(["string","number","currency","duration","percentage"]),label:a.string,shouldFocus:a.bool,value:a.string.isRequired,onChange:a.func.isRequired,onEnter:a.func,onEscape:a.func};e.exports=c}),null); __d("BUIFilterTokenTextSetSelector.react",["cx","fbt","invariant","AdsCFCheckbox.react","BUIComponent","ContextualLayer.react","LayerHideOnBlur","React","ScrollableArea.react","XUIButton.react","joinClasses"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();a=b("React").PropTypes;c=function(a){babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){return b("React").createElement("div",{className:"_25sq","aria-selected":this.props.checked},b("React").createElement(b("AdsCFCheckbox.react"),{name:this.props.optionName,onChange:this.props.onOptionChange,checked:this.props.checked,value:this.props.value,label:this.props.text}))};return c}(b("React").Component);c.propTypes={checked:a.bool.isRequired,text:a.string.isRequired,value:a.oneOfType([a.string,a.number,a.object])};d=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var c,d;for(var e=arguments.length,f=new Array(e),g=0;g-1;return b("React").createElement(q,{value:a.value,key:a.value,text:a.text||c(a.value),checked:e})});return b("React").createElement(b("BUIFilterTokenTextSetSelector.react"),{className:"_5b5s _bm6",onChange:d.$BUIFilterTokenInput51},e)}};d.$BUIFilterTokenInput52=function(a){a=a&&a.length?a:"";d.$BUIFilterTokenInput20({value:a})};d.$BUIFilterTokenInput53=function(){var a=d.state.operatorConfig.operator;switch(a){case"GREATER_THAN":case"LESS_THAN":a=d.state.value;if(!a||!Number(a))return!1;break}return d.$BUIFilterTokenInput54()};d.$BUIFilterTokenInput54=function(){__p&&__p();if(d.state.fieldConfig.isFieldOnly)return!0;var a=d.state.value;if(a){var c=d.state.operatorConfig.operator;switch(c){case"IN_RANGE":case"NOT_IN_RANGE":if(!a[0]||!a[1]||Number(a[1])<=Number(a[0]))return!1;break;case"IN":case"NOT_IN":case"ANY":case"NONE":case"ALL":if(!Array.isArray(a)||!a.length)return!1;break}c=d.state.fieldConfig.field.type;switch(c){case b("AdsGenericFilterFieldType").DURATION:if(!b("ClockFormatConverter").validate(a))return!1;break}return!0}else return!1};d.$BUIFilterTokenInput11=function(){if(d.$BUIFilterTokenInput54()){var a=d.props.defaultFilter?j._("Apply"):j._("Add");return b("React").createElement(b("XUIButton.react"),{className:"_5b5u _5b5v",label:a,use:"default",onClick:d.$BUIFilterTokenInput55})}return null};d.$BUIFilterTokenInput41=function(a){d.$BUIFilterTokenInput54()&&d.$BUIFilterTokenInput55(a)};d.$BUIFilterTokenInput55=function(a){a.preventDefault();a=d.state.fieldConfig.converter;a?d.setState({value:a.toIds(d.state.value)},function(){this.props.onSubmit(this.state.fieldConfig.field,this.state.operatorConfig.operator,this.state.value,this.state.prefixes)}):d.props.onSubmit(d.state.fieldConfig.field,d.state.operatorConfig.operator,d.state.value,d.state.prefixes)};d.$BUIFilterTokenInput56=function(a){a.preventDefault(),d.props.onCancel&&d.props.onCancel()};d.$BUIFilterTokenInput20=function(a){a=babelHelpers["extends"]({},d.state,a);d.setState(d.$BUIFilterTokenInput1(d.props,a))};d.$BUIFilterTokenInput57=function(a){var b=d.state.fieldValueParser;return b(a)};d.$BUIFilterTokenInput34=function(a){d.$BUIFilterTokenInput20({fieldConfig:a.value,shouldFocusInput:!0})};d.$BUIFilterTokenInput35=function(a){d.$BUIFilterTokenInput20({operatorConfig:a.value,shouldFocusInput:!0})};d.$BUIFilterTokenInput33=function(a){d.$BUIFilterTokenInput20({fieldConfig:a,shouldFocusInput:!0})};d.$BUIFilterTokenInput31=function(a){d.$BUIFilterTokenInput20({fieldConfig:a.getAuxiliaryData(),shouldFocusInput:!0})};d.$BUIFilterTokenInput24=function(a){d.$BUIFilterTokenInput20({operatorConfig:a,shouldFocusInput:!0})};d.$BUIFilterTokenInput42=function(a){d.$BUIFilterTokenInput20({value:d.$BUIFilterTokenInput57(a)})};d.$BUIFilterTokenInput46=function(a){a=a.toInstant(d.props.timezoneID)*m;d.$BUIFilterTokenInput20({value:d.$BUIFilterTokenInput57(a)})};d.$BUIFilterTokenInput45=function(a){a=a.interval;var b=a.start.toInstant(d.props.timezoneID)*m;a=a.end.toInstant(d.props.timezoneID)*m;b=[d.$BUIFilterTokenInput57(b),d.$BUIFilterTokenInput57(a)];d.$BUIFilterTokenInput20({value:b})};d.$BUIFilterTokenInput49=function(a){a=a.getUnixTimestampSeconds();d.$BUIFilterTokenInput20({value:d.$BUIFilterTokenInput57(a)})};d.$BUIFilterTokenInput47=function(a){a=a.getUnixTimestampSeconds();d.$BUIFilterTokenInput20({value:[d.$BUIFilterTokenInput57(a),d.state.value[1]]})};d.$BUIFilterTokenInput48=function(a){a=a.getUnixTimestampSeconds();d.$BUIFilterTokenInput20({value:[d.state.value[0],d.$BUIFilterTokenInput57(a)]})};d.$BUIFilterTokenInput43=function(a){d.$BUIFilterTokenInput20({value:[d.$BUIFilterTokenInput57(a),d.state.value[1]],shouldFocusInput:!1})};d.$BUIFilterTokenInput44=function(a){d.$BUIFilterTokenInput20({value:[d.state.value[0],d.$BUIFilterTokenInput57(a)]})};d.$BUIFilterTokenInput50=function(a){d.$BUIFilterTokenInput20({value:d.$BUIFilterTokenInput57(a.value)})};d.$BUIFilterTokenInput51=function(a){d.$BUIFilterTokenInput20({value:a.map(d.$BUIFilterTokenInput57,babelHelpers.assertThisInitialized(d))})};d.$BUIFilterTokenInput58=function(a){__p&&__p();if(!d.props.dismissOnBlur&&!d.props.confirmOnBlur)return;var c=a.target,e=b("ReactDOM").findDOMNode(babelHelpers.assertThisInitialized(d)),f=d.refs.prefixSelector&&b("ReactDOM").findDOMNode(d.refs.prefixSelector);if(b("DOM").contains(e,c)||f&&b("DOM").contains(f,c)||b("Parent").bySelector(c,"._1t-2")||b("Parent").bySelector(c,"._5xr5")||b("Parent").bySelector(c,"._5b5q")||b("Parent").bySelector(c,"._5mwk")||b("Parent").bySelector(c,"._5c02")||b("Parent").bySelector(c,"._58zx"))return;f=c;while(f&&f.nodeType===1){f=f;if(f.getAttribute("role")==="menu")return;f=f.parentNode}f=b("Rect").getElementBounds(e);e=20;f=new(b("Rect"))(f.t-e,f.r+e,f.b+e,f.l-e);e=b("Rect").getElementBounds(c);if(f.contains(e))return;d.setState({shouldFocusInput:!1});d.props.confirmOnBlur&&d.$BUIFilterTokenInput53()?d.$BUIFilterTokenInput55(a):d.props.dismissOnBlur&&d.props.onCancel&&d.props.onCancel()};d.$BUIFilterTokenInput4=function(){d.$BUIFilterTokenInput59||(d.$BUIFilterTokenInput59=b("Event").listen(document,"click",d.$BUIFilterTokenInput58))};d.$BUIFilterTokenInput6=function(){d.$BUIFilterTokenInput59&&(d.$BUIFilterTokenInput59.remove(),d.$BUIFilterTokenInput59=null)};var e=c.applyOnly,f=c.hasInitialFocus;d.state=d.$BUIFilterTokenInput1(c,{shouldFocusInput:f!==void 0?f:!e});return d}var d=c.prototype;d.componentDidMount=function(){this.$BUIFilterTokenInput2=window.setTimeout(this.$BUIFilterTokenInput4,16),this.props.autoOpenFieldSelector&&!this.props.applyOnly&&(this.$BUIFilterTokenInput3=window.setTimeout(this.$BUIFilterTokenInput5,200))};d.componentWillUnmount=function(){window.clearTimeout(this.$BUIFilterTokenInput2),window.clearTimeout(this.$BUIFilterTokenInput3),this.$BUIFilterTokenInput6()};d.UNSAFE_componentWillReceiveProps=function(a){String(a.defaultFilter)!==String(this.props.defaultFilter)?this.setState(this.$BUIFilterTokenInput1(a,{})):this.setState(this.$BUIFilterTokenInput1(a,this.state))};d.render=function(){if(!this.state.fieldConfig)return b("React").createElement("i",{className:"hidden_elem"});var a=b("joinClasses")("_5b5o",this.props.className);if(this.props.applyOnly)return this.$BUIFilterTokenInput7(a);else if(this.state.fieldConfig.isFieldOnly)return this.$BUIFilterTokenInput8(a);else return this.$BUIFilterTokenInput9(a)};d.$BUIFilterTokenInput8=function(a){return b("React").createElement("div",{className:a},this.$BUIFilterTokenInput10(),this.$BUIFilterTokenInput11(),this.$BUIFilterTokenInput12())};d.$BUIFilterTokenInput7=function(a){a=b("joinClasses")(a,"_4cld");return b("React").createElement("div",{className:a},this.$BUIFilterTokenInput13(),this.$BUIFilterTokenInput11())};d.$BUIFilterTokenInput13=function(){!this.props.defaultFilter&&l(0,165);var a=b("AdsGenericFilterFieldConfigUtil").getConfigByField(this.props.fieldsConfig,this.props.defaultFilter.field),c=a.helpText,d=a.iconURI,e=a.largeIcon;a=a.text;var f=this.props.defaultFilter.value;c=c?b("React").createElement(b("SUISimplePopover.react"),{content:c,contentWidthUseSparingly:168,position:"below",theme:b("SUIBusinessTheme")}):null;return b("React").createElement("div",{className:"_5b5t _2d2k"},this.$BUIFilterTokenInput14(d,e),b("React").createElement("div",{className:"_5b5r"},j._("{field}: ({value})",[j._param("field",a),j._param("value",f.length)]),c))};d.$BUIFilterTokenInput9=function(a){return this.props.expandTokenInput?b("React").createElement("div",{className:a},b("React").createElement("div",{className:"_7ouk"},this.$BUIFilterTokenInput10()),b("React").createElement("div",{className:"_7ouk"},this.$BUIFilterTokenInput15()),b("React").createElement("div",{className:"_7ouk"},this.$BUIFilterTokenInput16()),b("React").createElement("div",{className:"_7ouk"},this.props.enableFilterPrefixes&&this.$BUIFilterTokenInput17()),b("React").createElement("div",{className:"_7ouk"},this.$BUIFilterTokenInput11()),b("React").createElement("div",{className:"_7ouk",style:{marginTop:2}},this.$BUIFilterTokenInput12())):b("React").createElement("div",{className:a},b("React").createElement("div",{className:"_7ouk"},this.$BUIFilterTokenInput10()),b("React").createElement("div",{className:"_7ouk"},this.$BUIFilterTokenInput15()),b("React").createElement("div",{className:"_7ouk"},this.$BUIFilterTokenInput16()),b("React").createElement("div",{className:"_7ouk"},this.props.enableFilterPrefixes&&this.$BUIFilterTokenInput17()),b("React").createElement("div",{className:"_7ouk"},this.$BUIFilterTokenInput11()),b("React").createElement("div",{className:"_7ouk"},this.$BUIFilterTokenInput12()))};d.$BUIFilterTokenInput17=function(){return!this.state.fieldConfig.supportedPrefixes||this.state.fieldConfig.supportedPrefixes.length===0?b("React").createElement("span",null):b("React").createElement("div",null,b("React").createElement("span",{ref:"prefixLink",className:b("joinClasses")("_3-8r","_2pir"),onMouseEnter:this.$BUIFilterTokenInput21,onMouseLeave:this.$BUIFilterTokenInput21},b("React").createElement(b("SUIGlyphIcon.react"),{srcDefault:g("540232"),srcHover:g("540233"),hover:this.state.prefixHoverShown,style:{cursor:"pointer",verticalAlign:"middle"}})),b("React").createElement(u,{prefixes:this.state.prefixes,supportedPrefixes:this.state.fieldConfig.supportedPrefixes,onChange:this.$BUIFilterTokenInput19,contextRef:this.$BUIFilterTokenInput18,ref:"prefixSelector"}))};d.$BUIFilterTokenInput14=function(a,c){return!a?null:b("React").createElement(b("Image.react"),{className:"_5b5p"+(c?" _4gem":""),src:a})};d.$BUIFilterTokenInput22=function(a){this.props.useSUI_EXPERIMENTAL||l(0,166);return b("React").createElement(b("SUISelectorButton.react"),{height:"short",label:b("React").createElement("div",{"data-hover":"tooltip","data-tooltip-display":"overflow"},a),style:b("autoFlipStyleProps")({marginRight:"4px"}),textAlign:"center",uniformOverride:{chevron:null,padding:"4px",margins:{label:{right:"0"}}}})};d.$BUIFilterTokenInput23=function(){this.props.useSUI_EXPERIMENTAL||l(0,166);var a=this.state.operatorConfigOptions.map(function(a){return b("React").createElement(b("SUISelectorOption.react"),{value:a,key:"operator_"+a.operator},a.text)});return b("React").createElement(b("SUIBusinessThemeContainer.react"),null,b("React").createElement(b("SUISelector.react"),{button:this.$BUIFilterTokenInput22(this.state.operatorConfig.text),key:"operator_"+this.state.fieldConfig.field.name,maxHeight:400,value:this.state.operatorConfig,onChange:this.$BUIFilterTokenInput24},a))};d.$BUIFilterTokenInput25=function(a,b){b=b.get(a);return!b?null:this.$BUIFilterTokenInput26(b)};d.$BUIFilterTokenInput27=function(a,c){var d=this;switch(a.type){case"separator":return b("React").createElement(b("SUISelectorSeparator.react"),null);case"item":return this.$BUIFilterTokenInput25(a.item,c);case"group":var e=b("compactArray")(a.children.map(function(a){return d.$BUIFilterTokenInput25(a,c)}));return this.$BUIFilterTokenInput28(a.group,a.label,e)}return l(!1,"Unsupported item type: %s",a.type)};d.$BUIFilterTokenInput29=function(a,c){__p&&__p();var d=this;if(!c)return a.map(this.$BUIFilterTokenInput26);var e=new Map();a.forEach(function(a){var b=a.field.toString();e.has(b)&&l(0,167,b);e.set(b,a)});return b("compactArray")(c.map(function(a){return d.$BUIFilterTokenInput27(a,e)}))};d.$BUIFilterTokenInput28=function(a,c,d){return b("React").createElement(b("SUISelectorOptionGroup.react"),{key:a,label:c},d)};d.$BUIFilterTokenInput30=function(){var a=b("BUIFilterTokenSearchableInputUtils").getSUIFieldSearchSource(this.state.fieldConfigOptions,this.props.fieldGroupingConfig),c=b("BUIFilterTokenSearchableInputUtils").getSearchableEntry(this.state.fieldConfig);return b("React").createElement(b("SUISearchableSelector.react"),{areCategoriesCollapsible:!0,button:this.$BUIFilterTokenInput22(this.state.fieldConfig.text),dropdownWidth:240,getTooltipForEntry:function(a){return a.getAuxiliaryData().adsHelpLinkText},hasCategories:!0,height:"short",initiallyExpandedCategories:[a[1].getType()],isDisabled:this.props.disableFieldSelector,maxHeight:400,shouldOpenAutomatically:this.props.autoOpenFieldSelector,theme:b("SUIBusinessTheme"),value:c,searchSource:new(b("StaticSearchSource"))(a),onChange:this.$BUIFilterTokenInput31})};d.$BUIFilterTokenInput32=function(){this.props.useSUI_EXPERIMENTAL||l(0,166);var a=this.$BUIFilterTokenInput29(this.state.fieldConfigOptions,this.props.fieldGroupingConfig);return b("React").createElement(b("SUIBusinessThemeContainer.react"),null,b("React").createElement(b("SUISelector.react"),{button:this.$BUIFilterTokenInput22(this.state.fieldConfig.text),disabled:this.props.disableFieldSelector,dropdownWidth:240,key:"field_"+this.state.fieldConfig.field.toString(),maxHeight:400,shouldOpenAutomatically:this.props.autoOpenFieldSelector,value:this.state.fieldConfig,onChange:this.$BUIFilterTokenInput33},a))};d.$BUIFilterTokenInput10=function(){__p&&__p();var a=this;if(this.props.useSUI_EXPERIMENTAL&&this.props.hasSearchableSelector)return this.$BUIFilterTokenInput30();if(this.props.useSUI_EXPERIMENTAL)return this.$BUIFilterTokenInput32();var c=this.state.fieldConfigOptions.map(function(c){var d=o,e,f;c.iconURI&&(e=a.$BUIFilterTokenInput14(c.iconURI,c.largeIcon));c.isDynamic&&(c.values===void 0&&(d=b("XUIMenuStaticItem.react"),e=b("React").createElement(b("XUISpinner.react"),null)),c.values===null&&(d=b("XUIMenuStaticItem.react"),e=b("React").createElement(b("Image.react"),{className:"_5b5p",src:g("101449")})));c.adsHelpLinkText&&(f=b("React").createElement(b("SUISimplePopover.react"),{content:c.adsHelpLinkText,theme:b("SUIBusinessTheme")}));return b("React").createElement(d,{disabled:c.isStandalone&&!a.props.canAddStandalone,value:c,key:"field_option_"+c.field.toString()},b("React").createElement("div",{className:"_5b5q"},e,b("React").createElement("div",{className:"ellipsis _5b5r","data-hover":"tooltip","data-tooltip-display":"overflow"},c.text,f)))});return b("React").createElement(t,{className:"_5b5s",defaultValue:this.state.fieldConfig,key:"field_"+this.state.fieldConfig.field.toString(),ref:"fieldSelector",disabled:this.props.disableFieldSelector,onChange:this.$BUIFilterTokenInput34},c)};d.$BUIFilterTokenInput15=function(){if(this.props.useSUI_EXPERIMENTAL)return this.$BUIFilterTokenInput23();var a=this.state.operatorConfigOptions.map(function(a){return b("React").createElement(o,{value:a,key:"operator_"+a.operator},b("React").createElement("div",{className:"_5b5q"},a.text))});return b("React").createElement(t,{key:"operator_"+this.state.fieldConfig.field.name,className:"_5b5s",onChange:this.$BUIFilterTokenInput35,defaultValue:this.state.operatorConfig},a)};d.$BUIFilterTokenInput16=function(){__p&&__p();var a=this.state.fieldValueRenderer;switch(this.state.fieldConfig.field.type){case b("AdsGenericFilterFieldType").CURRENCY:return this.$BUIFilterTokenInput36("currency");case b("AdsGenericFilterFieldType").NUMBER:return this.$BUIFilterTokenInput36("number");case b("AdsGenericFilterFieldType").DURATION:return this.$BUIFilterTokenInput36("duration");case b("AdsGenericFilterFieldType").PERCENTAGE:return this.$BUIFilterTokenInput36("percentage");case b("AdsGenericFilterFieldType").STRING_SET:case b("AdsGenericFilterFieldType").NUMBER_SET:return this.$BUIFilterTokenInput37();case b("AdsGenericFilterFieldType").DATE_RANGE:return this.$BUIFilterTokenInput38();case b("AdsGenericFilterFieldType").DATETIME_RANGE:return this.$BUIFilterTokenInput39();case b("AdsGenericFilterFieldType").TOKENIZED_TYPEAHEAD:return this.$BUIFilterTokenInput40();default:return b("React").createElement(b("BUIFilterTokenTextInput.react"),{onEnter:this.$BUIFilterTokenInput41,onEscape:this.props.onCancel,value:a(this.state.value),onChange:this.$BUIFilterTokenInput42,format:"string",shouldFocus:this.state.shouldFocusInput})}};d.$BUIFilterTokenInput36=function(a){if(Array.isArray(this.state.fieldConfig.values))return this.$BUIFilterTokenInput37();var c=this.state.value,d=this.state.fieldValueRenderer;switch(this.state.valueOperator){case"IN_RANGE":case"NOT_IN_RANGE":return b("React").createElement("div",{className:"_5b5t"},b("React").createElement(b("BUIFilterTokenTextInput.react"),{onEnter:this.$BUIFilterTokenInput41,onEscape:this.props.onCancel,value:d(c[0]),onChange:this.$BUIFilterTokenInput43,format:a,shouldFocus:this.state.shouldFocusInput}),b("React").createElement("span",{className:"_60-g"},"\u2013"),b("React").createElement(b("BUIFilterTokenTextInput.react"),{onEnter:this.$BUIFilterTokenInput41,onEscape:this.props.onCancel,value:d(c[1]),onChange:this.$BUIFilterTokenInput44,format:a}));default:return b("React").createElement(b("BUIFilterTokenTextInput.react"),{onEnter:this.$BUIFilterTokenInput41,onEscape:this.props.onCancel,value:d(c),onChange:this.$BUIFilterTokenInput42,format:a,shouldFocus:this.state.shouldFocusInput})}};d.$BUIFilterTokenInput38=function(){this.props.timezoneID==null;if(this.state.operatorConfig.operator==="IN_RANGE"||this.state.operatorConfig.operator==="NOT_IN_RANGE"){var a=null,c=r(this.state.value[0]),d=r(this.state.value[1]);c&&d&&(a=new(b("LocalDateInterval"))(c,d));return b("React").createElement(v,{onChange:this.$BUIFilterTokenInput45,timezoneID:this.props.timezoneID||b("Timezone").UTC,value:{interval:a}})}return b("React").createElement(b("BUIDatePicker.react"),{value:r(this.state.value),onChange:this.$BUIFilterTokenInput46})};d.$BUIFilterTokenInput39=function(){switch(this.state.operatorConfig.operator){case"IN_RANGE":case"NOT_IN_RANGE":var a=s(this.state.value[0],this.props.timezoneID),c=s(this.state.value[1],this.props.timezoneID);return b("React").createElement("div",{className:"_1ogp"},b("React").createElement(b("BUIDateTimePicker.react"),{timezoneID:this.props.timezoneID||b("Timezone").UTC,value:a,onChange:this.$BUIFilterTokenInput47}),b("React").createElement("span",{className:"_60-g"},"\u2013"),b("React").createElement(b("BUIDateTimePicker.react"),{timezoneID:this.props.timezoneID||b("Timezone").UTC,value:c,onChange:this.$BUIFilterTokenInput48}));case"AFTER":case"BEFORE":case"GREATER_THAN":case"LESS_THAN":a=s(this.state.value,this.props.timezoneID);return b("React").createElement(b("BUIDateTimePicker.react"),{timezoneID:this.props.timezoneID||b("Timezone").UTC,value:a,onChange:this.$BUIFilterTokenInput49});default:return l(!1,"Unsupported operator %s for date time range filter",this.state.operatorConfig.operator)}};d.$BUIFilterTokenInput40=function(){var a=this.state.value,c=this.state.fieldConfig.converter;c&&(a=c.toEntries(a,this.state.fieldConfig.values));return b("React").createElement(b("BUIFilterTokenTypeaheadInput.react"),{className:this.state.fieldConfig.className,entries:a||[],onChange:this.$BUIFilterTokenInput52,placeholder:this.state.fieldConfig.placeholder,presenter:this.state.fieldConfig.presenter,searchSource:this.state.fieldConfig.searchSource,searchSourceOptions:this.state.fieldConfig.searchSourceOptions,showEntriesOnFocus:!!this.state.fieldConfig.showEntriesOnFocus})};d.$BUIFilterTokenInput12=function(){return b("React").createElement(b("BUIAdoptionCloseButton.react"),{className_DEPRECATED:"_3-8h",onClick:this.$BUIFilterTokenInput56})};d.$BUIFilterTokenInput1=function(a,c){b("BUIFilterTokenInputHelper").calibrateFieldState(a,c);b("BUIFilterTokenInputHelper").calibrateOperatorState(a,c);b("BUIFilterTokenInputHelper").calibrateValueState(a,c);b("BUIFilterTokenInputHelper").calibratePrefixState(a,c);return c};return c}(b("BUIComponent"));d.propTypes={autoOpenFieldSelector:a.bool,defaultFilter:a.instanceOf(b("AdsGenericFilter")),filterBlacklist:a.array,onSubmit:a.func.isRequired,onCancel:a.func,validFieldConfigs:a.array.isRequired,fieldsConfig:a.object.isRequired,timezoneID:a.number,applyOnly:a.bool.isRequired,confirmOnBlur:a.bool.isRequired,dismissOnBlur:a.bool.isRequired,hideMenuOnSingleItem:a.bool,disableFieldSelector:a.bool,canAddStandalone:a.bool,useSUI_EXPERIMENTAL:a.bool,fieldGroupingConfig:a.array,expandTokenInput:a.bool,hasSearchableSelector:a.bool,enableFilterPrefixes:a.bool};d.defaultProps=c;var t=function(c){__p&&__p();babelHelpers.inheritsLoose(a,c);function a(){return c.apply(this,arguments)||this}var d=a.prototype;d.render=function(){var a=this.props.children.length==1&&this.props.hideMenuOnSingleItem;return b("React").createElement(b("XUISelector.react"),{className:this.props.className,onChange:this.props.onChange,defaultValue:this.props.defaultValue,disabled:a||this.props.disabled,ref:"selector"},b("React").createElement(b("XUISelectorButton.react"),{maxwidth:500,className:"_bm6",haschevron:!1,suppressed:!0}),this.props.children)};d.showMenu=function(){this.refs.selector.showMenu()};return a}(b("React").Component),u=function(c){__p&&__p();babelHelpers.inheritsLoose(a,c);function a(){return c.apply(this,arguments)||this}var d=a.prototype;d.render=function(){var a=this,c=this.props.supportedPrefixes.map(function(c,d){var e=c.prefixes,f=function(b){a.props.onChange(d,b)};return b("React").createElement("div",{className:"_68kn",key:c.key},b("React").createElement(b("SUIText.react"),{display:"block",margin:"_3-8w",size:"meta1",theme:b("SUIBusinessTheme")},c.text),b("React").createElement(b("SUIRadioList.react"),{value:a.props.prefixes[d]||"",onChange:f},b("React").createElement(n,{value:""},j._("Default")),e.map(function(a,c){return b("React").createElement(n,{value:a.prefix,key:a.prefix},a.text)})))});c=b("React").createElement("div",{className:"._68ko"},j._("Change additional options on a per-condition basis. Setting a time range will only apply to the selected condition"),b("React").createElement("br",null),c);return b("React").createElement(b("SUIPopover.react"),{content:c,delay:300,hoverContextRef:this.props.contextRef,linger:200,position:b("PositionEnum").above,theme:b("SUIBusinessTheme"),title:j._("Additional Filter Options")})};return a}(b("React").Component);u.propTypes={prefixes:a.array,supportedPrefixes:a.array,onChange:a.func,contextRef:a.func};var v=function(c){__p&&__p();babelHelpers.inheritsLoose(a,c);function a(b){var d;d=c.call(this,b)||this;d.$2=function(a){d.setState({value:a}),d.props.onChange(a)};d.state={value:a.$1(b)};return d}var d=a.prototype;d.UNSAFE_componentWillReceiveProps=function(b){this.setState(function(c){var d=a.$1(b);return p(c.value.interval,d.interval)?void 0:{value:d}})};a.$1=function(a){a=b("BUIDateRangeUtils").calculateSelectedOption({dateRestraints:a.dateRestraints,defaultIncludeToday:!1,options:b("BUIDateRangePicker.react").defaultProps.options,timezoneID:a.timezoneID,value:a.value&&a.value.interval});return b("BUIDateRangeUtils").rangeSelectionToValue(a)};d.render=function(){return b("React").createElement(b("BUIDateRangePicker.react"),{onChange:this.$2,timezoneID:this.props.timezoneID,value:this.state.value,verbose:"all"})};return a}(b("React").Component);v.propTypes={value:a.shape({interval:a.instanceOf(b("LocalDateInterval"))})};e.exports=d}),null); __d("BUIFilterToken.react",["ix","cx","fbt","invariant","AdsGenericFilter","AdsGenericFilterFieldConfigUtil","AdsGenericFilterOperatorConfigUtil","AdsGenericFilterValueTextUtil","AdsPopoverLink_DEPRECATED.react","BUIAdoptionCloseButton.react","BUIComponent","BUIFilterTokenInput.react","Image.react","React","ReactDOM","cxMargin","fbglyph"],(function(a,b,c,d,e,f,g,h,i,j){"use strict";__p&&__p();a=b("React").PropTypes;var k=4;c=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var b,c;for(var d=arguments.length,e=new Array(d),f=0;f=c.props.filter.prefixes.length)return"";var e=c.props.filter.prefixes[d];d=a.find(function(a){return e&&a.prefix===e});return!d?"":b("React").createElement("span",{key:d.text},d.text," ")});if(this.props.enableFilterPrefixes&&f.find(function(a){return a!==""}))return i._("{field prefixes}{field}{field colon}",[i._param("field prefixes",f),i._param("field",d),i._param("field colon",e)]);else if(this.$BUIFilterToken25())return a.getTokenTextByValue(this.props.filter.value);else return i._("{field}{field colon}",[i._param("field",d),i._param("field colon",e)])};d.$BUIFilterToken23=function(){var a=this.props.filter.operator;a=b("AdsGenericFilterOperatorConfigUtil").getConfigByOperator(a);return a.shortText||""};d.$BUIFilterToken16=function(a,c){if(this.$BUIFilterToken1())return i._("({value})",[i._param("value",c)]);else if(this.$BUIFilterToken24()||this.$BUIFilterToken25())return"";else{a=a?b("React").createElement("span",{className:"_3_lp"},a):"";return i._("{operator}{value}",[i._param("operator",a),i._param("value",c)])}};d.$BUIFilterToken14=function(){__p&&__p();if(!this.refs.filterToken)return;var a=b("ReactDOM").findDOMNode(this.refs.filterToken);if(this.$BUIFilterToken1()&&this.refs.filterTokenInput){var c=b("ReactDOM").findDOMNode(this.refs.filterTokenInput);c=getComputedStyle(c).width;c=parseInt(c,10)+k;a.style.width=c+"px"}else a.style.width="auto"};d.$BUIFilterToken12=function(){var a=this.$BUIFilterToken13();return!!a.deprecationMessage};return c}(b("BUIComponent"));c.propTypes={contentEditable:a.bool.isRequired,disabled:a.bool,confirmOnBlur:a.bool,dismissOnBlur:a.bool.isRequired,index:a.number.isRequired,isReadOnly:a.bool,filter:a.instanceOf(b("AdsGenericFilter")).isRequired,onChange:a.func.isRequired,onRemove:a.func.isRequired,onEditAttempt:a.func,onEditCancelAttempt:a.func,validFieldConfigs:a.array.isRequired,filterConstructor:a.func,fieldsConfig:a.object.isRequired,valuesConfig:a.object.isRequired,theme:a.oneOf(["regular","dark","plain"]).isRequired,timezoneID:a.number,hideMenuOnSingleItem:a.bool,disableFieldSelector:a.bool,canAddStandalone:a.bool,useSUI_EXPERIMENTAL:a.bool,fieldGroupingConfig:a.array,expandTokenInput:a.bool,hasSearchableSelector:a.bool,enableFilterPrefixes:a.bool};c.defaultProps={confirmOnBlur:!1,dismissOnBlur:!0,filterConstructor:b("AdsGenericFilter"),theme:"regular",hasSearchableSelector:!1};e.exports=c}),null); __d("BUIFilterTokenCreateButton.react",["ix","cx","fbt","xuiglyph","BUIComponent","BUIFilterTokenInput.react","Image.react","React","XUIButton.react"],(function(a,b,c,d,e,f,g,h,i,j){"use strict";__p&&__p();a=b("React").PropTypes;c=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f3?g-3:0),i=3;i=b&&a<=c};d.$9=function(){if(!this.state.expirationToggle||!this.props.originalExpirationTimestamp)return!0;var a=this.state.expirationDate.getTime();return a>=this.props.originalExpirationTimestamp||aa&&c0)){b("FBLogger")(n).info("Cannot perform interception. No media attached for a media Attachment type");this.sendResponseToPartner(e);return}var t=b("ReactComposerPagesStore").getComposerEntryPoint(a);if(!t||!Object.values(b("PagesComposerEntryPoint")).includes(t)){b("FBLogger")(n).info("Cannot perform interception. Invalid composer entry point");this.sendResponseToPartner(e);return}var u=b("ReactComposerPagesStore").getCurrentLocale(a);if(!u){b("FBLogger")(n).info("Cannot perform interception. Could not fetch current locale");this.sendResponseToPartner(e);return}k=g(a,k,r,u,d);if(k.length===0){b("FBLogger")(n).info("No product selected for interception");this.sendResponseToPartner(e);return}r={composer_post_text:m,session_id:l,uuid:l,entry_point:j(t),run_interception_for_products:k,placement:d};s.length>0&&(r.photo_ids=s);u=i(a);u&&(r.sponsor_id=u);q!==null&&(r.link_data=q);var v=d==="pages_composer";v||b("PagesComposerActions").setIsRunningInterception(a,!0);m=b("WebGraphQL").exec(new(b("ComposerInterceptionDecisionWebGraphQLQuery"))({target_id:c,param:r}));b("promiseDone")(m,function(c){b("PagesComposerActions").setIsRunningInterception(a,!1),p.receiveGraphQLResponse(c,l,a||"",v,e)},function(c){b("PagesComposerActions").setIsRunningInterception(a,!1);c=(c=c[0])!=null?c.message:c;b("FBLogger")(n).info(c||"");f.sendResponseToPartner(e)})},receiveGraphQLResponse:function(a,c,d,e,f){__p&&__p();a=(a=a)!=null?(a=a.node)!=null?(a=a.composer_interception)!=null?a.decision:a:a:a;if(!a){b("FBLogger")(n).info("Null value received from server for interception response");this.sendResponseToPartner(f);return}e||(o[c]=!0);e=b("PagesComposerWWWInterceptionUtils").interceptionProductTypeToAttachmentType(a.interception_product_type||l("none"));e.map(function(a){return b("PagesComposerWWWInterceptionActions").setInterceptionDetected(d,a)});c={shouldPerformInterception:a.should_perform_interception||!1,bestExtractedTitle:a.best_extracted_title||"",interceptionProductType:a.interception_product_type||l("none"),interceptionType:a.interception_type||k("dialog"),bestExtractedStartTime:a.best_extracted_start_time,bestExtractedEndTime:a.best_extracted_end_time,bestExtractedLink:a.best_extracted_link,bestExtractedLinks:a.best_extracted_links,bestExtractedDescription:a.best_extracted_description,dialogTitle:a.dialog_title,dialogSubtitle:a.dialog_subtitle,dialogContent:a.dialog_content,dialogPrimaryActionTitle:a.dialog_primary_action_title,entityId:a.entity_id,entityFBID:a.entity_fbid};b("PagesComposerWWWInterceptionActions").setInterceptionResponse(d,c);this.sendResponseToPartner(f,c)},sendResponseToPartner:function(a,b){b===void 0&&(b=m),a&&a(b)}};e.exports={PagesComposerWWWInterceptionHandler:p,FBLOGGER_NAME:n}}),null); __d("PagesComposerInterceptionFlowType",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({AUTO_CONVERT:"auto_convert",DIALOG:"dialog",INLINE:"inline",INLINE_DIALOG:"inline_dialog",OPT_OUT_ACTIONABLE_NUX:"opt_out_actionable_nux",OPT_OUT_SIMPLE_NUX:"opt_out_simple_nux"})}),null); __d("PagesComposerInterceptionProductType",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({BRANDAWARENESS:"brandawareness",BRANDTAGGING:"brandtagging",EVENT:"event",FOODDRINK:"fooddrink",INSIGHTS_PHOTO_UPSELL:"insights_photo_upsell",JOB:"job",JOB_GENERIC_LINK:"job_generic_link",JOB_PARTNER_LINK:"job_partner_link",LDP:"ldp",MESSAGEPAGE:"messagepage",MOVIE:"movie",NONE:"none",OFFER:"offer",PAGES_INTEGRITY_FAKE_NEWS:"pages_integrity_fake_news",PAGES_INTEGRITY_UNPUBLISHED_CONTENT:"pages_integrity_unpublished_content",PRODUCT_TAGGING_NUX:"product_tagging",SALESPROMO:"salespromo",SCHEDULE_POST_TIME:"schedule_post_time",SELL:"sell",SELL_MESSAGE:"sell_message",SERVICE:"service"})}),null); __d("PagesComposerWWWInterceptionHandlerUtils",["FBLogger","PagesComposerEntryPoint","PagesComposerInterceptionFlowType","PagesComposerInterceptionProductType","PagesComposerWWWInterceptionHandler","ReactComposerPagesStore","ReactComposerPhotoStore","ReactComposerPortableCTAAttachmentStore","ReactComposerScrapedAttachmentStore","ReactComposerTaggerStore","ReactComposerTaggerType","getJSEnumSafe"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("PagesComposerWWWInterceptionHandler").FBLOGGER_NAME,h=function(a,c,d){for(var e in c)if(c[e]===a)return e;b("FBLogger")(g).mustfix("Invalid enum value provided");return d},i={mapInterceptionEnumProductKeyFromValue:function(a){return h(a,b("PagesComposerInterceptionProductType"),"NONE")},mapInterceptionEnumFlowKeyFromValue:function(a){return h(a,b("PagesComposerInterceptionFlowType"),"DIALOG")},mapInterceptionEnumComposerEntryPointKeyFromValue:function(a){return h(a,b("PagesComposerEntryPoint"),"PAGES_FEED")},getAttachedPhotoIDs:function(a){a=b("ReactComposerPhotoStore").getPhotos(a);var c=[];a&&a.size&&a.forEach(function(a){return c.push(a.id)});return c},evaluatePartnerConfigsForInterception:function(a,b,c,d,e){var f=[];b.forEach(function(b){var g=b.supportedPlacements;g||(g=[]);b.isEligibleForInterception&&g.includes(e)&&(b.supportedLocales.includes(d)||b.supportedLocales.includes(d.split("_")[0]+"_XX"))&&!b.blacklistedAttachmentTypes.includes(c)&&b.whitelistedAttachmentTypes.includes(c)&&i.checkProductBasedConditions(a,b,c)&&f.push(i.mapInterceptionEnumProductKeyFromValue(b.interceptionProductType))});return f},checkProductBasedConditions:function(a,c,d){switch(c.interceptionProductType){case"messagepage":d=b("ReactComposerPortableCTAAttachmentStore").getSelectedCta(a);return d==="MESSAGE_PAGE"?!1:!b("ReactComposerTaggerStore").hasMessagingCTA(a);case"offer":return!b("ReactComposerPagesStore").getIsOfferUpsellAbandoned(a);case"event":c=b("ReactComposerScrapedAttachmentStore").getAttachmentConfig(a);a=(d=c)!=null?d.type:d;return a!==7}return!0},checkProductBasedConditionsForInlineInterception:function(a,c){var d=b("getJSEnumSafe")(b("PagesComposerInterceptionProductType"),c.interceptionProductType);switch(d){case"movie":d=c.entityFBID;if(d===null)return!1;c=b("ReactComposerTaggerStore").getTaggerData(a,b("ReactComposerTaggerType").GET_SHOWTIMES);c=((a=c)!=null?a.external_movie_id:a)||null;return d!==c}return!0},getSponsorID:function(a){a=b("ReactComposerTaggerStore").getTaggerData(a,b("ReactComposerTaggerType").SPONSOR);return a&&a.sponsors&&a.sponsors.length>0?a.sponsors[0].getUniqueID():null}};e.exports=i}),null); __d("PagesComposerWWWInterceptionBrandAwarenessHandler",["PagesComposerInterceptionFlowType"],(function(a,b,c,d,e,f){"use strict";a={handleBrandAwarenessInterceptionResponse:function(a,c,d){c=a.brandAwarenessHandler;a=b("PagesComposerInterceptionFlowType")[d.interceptionType];switch(a){case"dialog":c(d.bestExtractedTitle);break}return}};e.exports=a}),null); __d("PagesComposerWWWInterceptionBrandTaggingHandler",["PagesComposerInterceptionFlowType"],(function(a,b,c,d,e,f){"use strict";a={handleBrandTaggingInterceptionResponse:function(a,c,d){c=a.brandTaggingHandler;a=b("PagesComposerInterceptionFlowType")[d.interceptionType];switch(a){case"dialog":c(d.bestExtractedLink,d.bestExtractedTitle);break}return}};e.exports=a}),null); __d("PagesComposerWWWInterceptionEventHandler",["fbt","PagesComposerInterceptionFlowType","PagesComposerInterceptionProductType"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a={handleEventInterceptionResponse:function(a,c){a=a.eventHandler;var d=b("PagesComposerInterceptionFlowType")[c.interceptionType],e=b("PagesComposerInterceptionProductType")[c.interceptionProductType],f=c.bestExtractedTitle,g=c.bestExtractedDescription,h=c.bestExtractedStartTime,i=c.bestExtractedEndTime;c=c.bestExtractedLink;a(this.convertEventTitleToFbtString(f),this.convertEventDescriptionToFbtString(g),h,i,c,e,d)},convertEventTitleToFbtString:function(a){a=g._("{title string}",[g._param("title string",a)]);return a.toString()},convertEventDescriptionToFbtString:function(a){a=g._("{descrption}",[g._param("descrption",a)]);return a.toString()}};e.exports=a}),null); __d("PagesComposerWWWInterceptionFakeNewsHandler",["PagesComposerInterceptionFlowType"],(function(a,b,c,d,e,f){"use strict";a={handleFakeNewsInterceptionResponse:function(a,c,d){c=a.fakeNewsHandler;a=b("PagesComposerInterceptionFlowType")[d.interceptionType];switch(a){case"dialog":c();break}return}};e.exports=a}),null); __d("PagesComposerWWWInterceptionLdpHandler",["PagesComposerInterceptionFlowType","ReactComposerStatusStore"],(function(a,b,c,d,e,f){"use strict";__p&&__p();a={handleLdpInterceptionResponse:function(a,c,d){a=a.ldpHandler;var e=b("PagesComposerInterceptionFlowType")[d.interceptionType];c=b("ReactComposerStatusStore").getMessageText(c);d=d.bestExtractedTitle;switch(e){case"dialog":a(c,d);break}return}};e.exports=a}),null); __d("PagesComposerWWWInterceptionSellIntentHandler",["PagesComposerInterceptionFlowType","ReactComposerStatusStore"],(function(a,b,c,d,e,f){"use strict";__p&&__p();a={handleSellIntentInterceptionResponse:function(a,c,d){a=a.sellIntentHandler;d=b("PagesComposerInterceptionFlowType")[d.interceptionType];c=b("ReactComposerStatusStore").getMessageText(c);switch(d){case"dialog":a(c);break}return}};e.exports=a}),null); __d("PagesComposerWWWInterceptionSendMessageHandler",["PagesComposerInterceptionFlowType","ReactComposerStatusStore"],(function(a,b,c,d,e,f){"use strict";__p&&__p();a={handleSendMessageInterceptionResponse:function(a,c,d){a=a.sendMessageHandler;d=b("PagesComposerInterceptionFlowType")[d.interceptionType];c=b("ReactComposerStatusStore").getMessageText(c);switch(d){case"dialog":a(c);break}return}};e.exports=a}),null); __d("PagesComposerWWWInterceptionUnpublishedContentHandler",["invariant","PagesComposerInterceptionFlowType","immutable"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a={handleUnpublishedContentInterceptionResponse:function(a,c,d){c=a.unpublishedContentHandler;a=b("PagesComposerInterceptionFlowType")[d.interceptionType];switch(a){case"dialog":d.bestExtractedLinks!=null&&d.bestExtractedLinks.length>0||g(0,13274);d.dialogContent!=null&&d.dialogContent.length>0||g(0,13275);c(b("immutable").Set(d.bestExtractedLinks)||b("immutable").Set([]),d.dialogContent||"");break}return}};e.exports=a}),null); __d("PagesComposerWWWInterceptionUtils",["ActorURI","ComposerXMarauderLogger","FBLogger","PagesComposerInterceptionFlowType","PagesComposerInterceptionProductType","PagesComposerWWWInterceptionBrandAwarenessHandler","PagesComposerWWWInterceptionBrandTaggingHandler","PagesComposerWWWInterceptionEventHandler","PagesComposerWWWInterceptionFakeNewsHandler","PagesComposerWWWInterceptionHandler","PagesComposerWWWInterceptionHandlerUtils","PagesComposerWWWInterceptionJobHandler","PagesComposerWWWInterceptionLdpHandler","PagesComposerWWWInterceptionOfferHandler","PagesComposerWWWInterceptionSellIntentHandler","PagesComposerWWWInterceptionSendMessageHandler","PagesComposerWWWInterceptionUnpublishedContentHandler","ReactComposerActions","ReactComposerAttachmentStore","ReactComposerAttachmentType","ReactComposerOptimisticPostingActions","ReactComposerPagesStore","isEmpty"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("PagesComposerWWWInterceptionHandler").FBLOGGER_NAME,h=b("PagesComposerWWWInterceptionHandler").PagesComposerWWWInterceptionHandler,i=b("PagesComposerWWWInterceptionHandlerUtils").mapInterceptionEnumProductKeyFromValue;a={performInterceptAttemptsAndSendPublishedPostV2:function(a,b,c){var d=this;h.performIntercept(a.composerID,a.targetID,"pages_composer_post_button",function(e){return d._handleInterceptionResponseV2(e,a.composerID,a.targetID,b,c)})},interceptionProductTypeToAttachmentType:function(a){switch(a){case i("messagepage"):return["MESSAGE"];case i("ldp"):return["LOCAL_DEV_PLATFORM"];case i("sell_message"):return["MESSAGE"];case i("insights_photo_upsell"):return["IG_PHOTO_REMINDER","MEDIA"];default:return[]}},logInterceptionEvent:function(a,c,d,e,f,g){var h={};d&&(h.interception_product_type=d);e&&(h.interception_type=e);f&&(h.post_id=f);g&&(h.interception_payload=g);b("ComposerXMarauderLogger").logEvent(c,a,{extraData:h})},_handleInterceptionResponseV2:function(a,c,d,e,f){__p&&__p();if(!Object.prototype.hasOwnProperty.call(b("PagesComposerInterceptionProductType"),a.interceptionProductType)){b("FBLogger")(g).mustfix("Invalid interception product type returned by graphQL");e();return}if(!Object.prototype.hasOwnProperty.call(b("PagesComposerInterceptionFlowType"),a.interceptionType)){b("FBLogger")(g).mustfix("Invalid interception type returned by graphQL");e();return}if(!a.shouldPerformInterception){e();return}var h=b("PagesComposerInterceptionProductType")[a.interceptionProductType];switch(h){case"pages_integrity_fake_news":b("PagesComposerWWWInterceptionFakeNewsHandler").handleFakeNewsInterceptionResponse(f,c,a);break;case"pages_integrity_unpublished_content":b("PagesComposerWWWInterceptionUnpublishedContentHandler").handleUnpublishedContentInterceptionResponse(f,c,a);break;case"job":case"job_generic_link":case"job_partner_link":b("PagesComposerWWWInterceptionJobHandler").handleJobInterceptionResponse(f,c,a);break;case"ldp":b("PagesComposerWWWInterceptionLdpHandler").handleLdpInterceptionResponse(f,c,a);break;case"messagepage":b("PagesComposerWWWInterceptionSendMessageHandler").handleSendMessageInterceptionResponse(f,c,a);break;case"offer":b("PagesComposerWWWInterceptionOfferHandler").handleOfferInterceptionResponse(f,d,a);break;case"event":b("PagesComposerWWWInterceptionEventHandler").handleEventInterceptionResponse(f,a);break;case"brandawareness":b("PagesComposerWWWInterceptionBrandAwarenessHandler").handleBrandAwarenessInterceptionResponse(f,c,a);break;case"brandtagging":b("PagesComposerWWWInterceptionBrandTaggingHandler").handleBrandTaggingInterceptionResponse(f,c,a);break;case"sell_message":b("PagesComposerWWWInterceptionSellIntentHandler").handleSellIntentInterceptionResponse(f,c,a);break;default:e();break}},startPosting:function(a){__p&&__p();var c,d=b("ReactComposerPagesStore").getPagesComposerConfig(a),e=b("ReactComposerPagesStore").getPagesComposerContextConfig(a);if(!d||b("isEmpty")(d)||!e||b("isEmpty")(e))return;var f=e.actorID,g=e.targetID;if(!!((c=e)!=null?(c=c.gks)!=null?c.optimisticPosting:c:c)&&!!((c=e)!=null?(c=c.gks)!=null?c.useNonBlockingMediaUpload:c:c)){c=(e=b("ReactComposerAttachmentStore").getSelectedAttachmentID(a))!=null?e:b("ReactComposerAttachmentType").STATUS;c!==b("ReactComposerAttachmentType").MEDIA&&c!==b("ReactComposerAttachmentType").STATUS&&(c=b("ReactComposerAttachmentType").STATUS);b("ReactComposerOptimisticPostingActions").startOptimisticallyPosting(a,d,c,f,g)}else b("ReactComposerActions").postStarted(a,{actorID:f,config:d,targetID:g})},fetchActorURI:function(a,c){return b("ActorURI").create(a.getURI(),c)}};e.exports=a}),null); __d("XJobInterceptDropoffController",["XController"],(function(a,b,c,d,e,f){e.exports=b("XController").create("/job_posting/intercept_dropoff/",{source:{type:"Enum",enumType:1}})}),null); __d("PagesComposerWWWInterceptionJobHandler",["AsyncRequest","PagesComposerInterceptionFlowType","PagesComposerInterceptionProductType","PagesComposerWWWInterceptionUtils","ReactComposerStatusStore","XJobInterceptDropoffController"],(function(a,b,c,d,e,f){"use strict";__p&&__p();a={handleJobInterceptionResponse:function(a,c,d){a=a.jobHandler;var e=b("PagesComposerInterceptionFlowType")[d.interceptionType],f=b("PagesComposerInterceptionProductType")[d.interceptionProductType];c=b("ReactComposerStatusStore").getMessageText(c);var g=d.bestExtractedTitle;d=d.bestExtractedDescription;a(c,g,d,f,e);return},logDialogAcceptEvent:function(a,c,d){b("PagesComposerWWWInterceptionUtils").logInterceptionEvent(a,"pages_composer_interception_dialog_accept",(a=c)!=null?a:"job",(c=d)!=null?c:"dialog")},publishOriginalPost:function(a,c,d,e,f){if(!a)return;d=(d=d)!=null?d:"job";e=(e=e)!=null?e:"dialog";b("PagesComposerWWWInterceptionUtils").logInterceptionEvent(a,"pages_composer_interception_dialog_reject",d,e);d=b("XJobInterceptDropoffController").getURIBuilder().setEnum("source",c).getURI();new(b("AsyncRequest"))().setURI(d).send();f?f():b("PagesComposerWWWInterceptionUtils").startPosting(a)}};e.exports=a}),null); __d("PageInterceptionDialogDecision",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({BRANDAWARENESS:"brandawareness",EVENT:"event",FOODDRINK:"fooddrink",JOB:"job",MESSAGEPAGE:"messagepage",NONE:"none",OFFER:"offer",SALESPROMO:"salespromo",SELL:"sell",SELL_MESSAGE:"sell_message",SERVICE:"service"})}),null); __d("XPagesInterceptDropoffController",["XController"],(function(a,b,c,d,e,f){e.exports=b("XController").create("/pages/composer/intercept_dropoff/",{vertical:{type:"Enum",required:!0,enumType:1}})}),null); __d("PagesComposerWWWInterceptionOfferHandler",["AsyncRequest","PageInterceptionDialogDecision","PagesComposerActions","PagesComposerInterceptionFlowType","PagesComposerWWWInterceptionUtils","ReactComposerScrapedAttachmentStore","ReactComposerStatusActions","ReactComposerStatusStore","XPageOfferXComposerController","XPagesInterceptDropoffController"],(function(a,b,c,d,e,f){"use strict";__p&&__p();a={handleOfferInterceptionResponse:function(a,c,d){a=a.offerHandler;d=b("PagesComposerInterceptionFlowType")[d.interceptionType];a(c,(a=d)!=null?a:"dialog");return},fetchOfferComposerBaseURI:function(a,c,d,e){var f=b("ReactComposerScrapedAttachmentStore").getAttachmentConfig(a),g=b("ReactComposerStatusStore").getMessage(a);g=b("XPageOfferXComposerController").getURIBuilder().setEnum("referrer","olp_modal_upsell").setString("description",g).setFBIDVector("photo_ids",d).setString("composer_id",a).setString("intercept_session_id",c).setStringVector("photo_urls",f&&f.params&&f.params.images?f.params.images:null).setEnum("interception_flow_type",e);return g},publishOriginalPost:function(a,c){if(!a)return;b("PagesComposerWWWInterceptionUtils").logInterceptionEvent(a,"pages_composer_interception_dialog_reject","offer",c);new(b("AsyncRequest"))(b("XPagesInterceptDropoffController").getURIBuilder().setEnum("vertical",b("PageInterceptionDialogDecision").OFFER).getURI()).send();b("PagesComposerActions").abandonOfferUpsell(a);c=b("ReactComposerStatusStore").getOriginalEditorState(a);c&&b("ReactComposerStatusActions").setEditorState(a,c);b("PagesComposerWWWInterceptionUtils").startPosting(a)},logOfferAcceptInterception:function(a,c){b("PagesComposerWWWInterceptionUtils").logInterceptionEvent(a,"pages_composer_interception_dialog_accept","offer",c)}};e.exports=a}),null); __d("VideoComposerDialogConstants",[],(function(a,b,c,d,e,f){"use strict";a=16/9;b=664;c=20;d=300;f=b-2*c;var g=60,h=1e3,i=60,j=8,k="2509364215780518",l="2385072711587341";l={SIXTEEN_NINE:a,CREATOR_STUDIO_ANNOUNCEMENT_CARD_CHANNEL_ID:l,DIALOG_WIDTH:b+d,SECONDARY_DIALOG_WIDTH:680,LEFT_SECTION_WIDTH:b,LEFT_SECTION_PADDING:c,MAX_TITLE_LENGTH:255,PREMIERE_PROMOTION_TO_VIDEO_UPLOAD_ID:k,RIGHT_SECTION_WIDTH:d,GENERATED_THUMBNAILS:10,MAX_TAG_COUNT:j,PLAYER_HEIGHT:f/a,PLAYER_WIDTH:f,SCHEDULE_TIME_DELTA:3*i*g*h,THUMBNAIL_HEIGHT:100,THUMBNAIL_WIDTH:178};e.exports=l}),null); __d("VideoComposerPublishConfirmDialogBody.react",["ix","cx","FlexLayout.react","Image.react","LeftRight.react","List.react","React","VideoComposerDialogConstants","XUIDialog.react","XUIDialogBody.react","asset"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){return b("React").createElement(b("XUIDialog.react"),{"data-testid":this.props.dialogTestID,isStrictlyControlled:!0,label:this.props.label,shown:this.props.shown,width:b("VideoComposerDialogConstants").SECONDARY_DIALOG_WIDTH},b("React").createElement(b("XUIDialogBody.react"),null,b("React").createElement(b("LeftRight.react"),null,b("React").createElement("div",null),b("React").createElement(b("Image.react"),{"data-testid":this.props.iconDataTestID,style:{cursor:"pointer"},src:g("363596"),onClick:this.props.onCloseClick})),b("React").createElement(b("FlexLayout.react"),{direction:"vertical",align:"center"},b("React").createElement(b("Image.react"),{src:this.props.imageSrc,className:"_6em3"}),b("React").createElement(b("List.react"),{className:"_6eri"},this.props.items.map(function(a,c){return b("React").createElement("li",{key:c},a)})))))};return c}(b("React").Component);e.exports=a}),null); __d("VideoComposerPublishConfirmDialog.react",["cx","fbt","ix","React","VideoComposerPostType","VideoComposerPublishConfirmDialogBody.react","VideoComposerPublishingTypes","clearInterval","formatDate","setInterval"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();var j=b("VideoComposerPostType").VideoComposerPostTypes,k=b("VideoComposerPublishingTypes").PublishingType,l=0,m=100;a=5e3;c=400;var n=a/c,o=m/c;d=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f Video Library or your Page Timeline Tools"))));else if(this.props.scheduleDate)c=i("429287"),a.push(b("React").createElement("div",{className:"_6erg"},h._("Video Post Scheduled Date:"),b("React").createElement("div",{className:"_6erh"},h._("{schedule date}",[h._param("schedule date",this.$6(this.props.scheduleDate))]))));else if(this.props.isReviewableBrandedContent)c=i("425005"),a.push(b("React").createElement("div",{className:"_6erg"},b("React").createElement("div",{"data-testid":"video_post_is_processing_text",className:"_6erh _3-95"},h._("Your video post is pending approval")),b("React").createElement("div",null,h._("Your video post will be published if your tagged business partner chooses to approve your post. You can see the status of your pending post in Publishing Tools > Branded Content > Your Posts."))));else if(this.props.isAdBreakPrereview)c=i("425005"),a.push(b("React").createElement("div",{className:"_6erg"},b("React").createElement("div",{className:"_6erh _3-95"},h._("Your video is being submitted for review")),b("React").createElement("div",null,h._("When the review is complete you will be notified."))));else if(this.props.publishingType===k.PUBLISH_WITH_SHOW_OR_SEASON){c=i("429286");var d=null;this.props.shouldPremiereWithShowOrSeason===!0?d=this.props.uploadingToSeason===!0?h._("Your video has been saved and will premiere when you publish the season it's in."):h._("Your video has been saved and will premiere when you publish the series it's in."):d=this.props.uploadingToSeason===!0?h._("Your video has been saved and will post when you publish the season it's in."):h._("Your video has been saved and will post when you publish the series it's in.");a.push(b("React").createElement("div",{className:"_6erg"},b("React").createElement("div",{className:"_6erh _3-95"},d)))}else c=i("425005"),a.push(this.$5());this.props.expireDate&&a.push(b("React").createElement("div",{className:"_6erg"},h._("Video Post Expire Date:"),b("React").createElement("div",{className:"_6erh"},h._("{expire date}",[h._param("expire date",this.$6(this.props.expireDate))]))));this.props.postEndDate&&a.push(b("React").createElement("div",{className:"_6erg"},h._("News feed Distribution Stop Date:"),b("React").createElement("div",{className:"_6erh"},h._("{post end date}",[h._param("post end date",this.$6(this.props.postEndDate))]))));return b("React").createElement(b("VideoComposerPublishConfirmDialogBody.react"),{dialogTestID:"VIDEO_COMPOSER_CONFIRM_DIALOG",iconDataTestID:"VIDEO_COMPOSER_CONFIRM_DIALOG_BUTTON",imageSrc:c,items:a,label:"confirm dialog",shown:this.props.shown,onCloseClick:this.props.onCloseClick})};d.$6=function(a){return!a?"":b("formatDate")(a,"F jS Y \\a\\t g:ia",{skipPatternLocalization:!0})};return c}(b("React").Component);e.exports=d}),null); __d("InstreamVideosSensitiveAdsBlockListStoreKey",["ImmutableRecordWithV4Types"],(function(a,b,c,d,e,f){"use strict";a=b("ImmutableRecordWithV4Types").Record;c=a({businessID:"0",pageID:"0",sourceApp:"creator_studio",userID:"0"});e.exports={createInstreamVideosSensitiveAdsBlockListStoreKey:c}}),null); __d("InstreamVideosSensitiveAdsBlockListConfirmationDataStore",["FluxLoadObjectStore","InstreamVideosSensitiveAdsBlockListActionTypes","InstreamVideosSensitiveAdsBlockListConfirmationDataManager","InstreamVideosSensitiveAdsBlockListDispatcher","InstreamVideosSensitiveAdsBlockListStoreKey","gkx","immutable"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("InstreamVideosSensitiveAdsBlockListStoreKey").createInstreamVideosSensitiveAdsBlockListStoreKey;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.__getActionTypes=function(){return[this.getActionTypeStartLoad(),b("InstreamVideosSensitiveAdsBlockListActionTypes").BLOCK_LIST_REVIEW_STATUS_LOAD_ERROR,b("InstreamVideosSensitiveAdsBlockListActionTypes").BLOCK_LIST_REVIEW_STATUS_LOAD_SUCCESS,b("InstreamVideosSensitiveAdsBlockListActionTypes").SENSITIVE_ADS_MODAL_XOUT]};d.reduce=function(a,c){switch(c.type){case b("InstreamVideosSensitiveAdsBlockListActionTypes").BLOCK_LIST_REVIEW_STATUS_LOAD_SUCCESS:return this.__handleOne(a,this.buildKey(c),{shouldReviewBlockList:!c.isBlockListReviewed&&c.hasAdBreaksAdminAccess,isDialogDismissed:!1});case b("InstreamVideosSensitiveAdsBlockListActionTypes").BLOCK_LIST_REVIEW_STATUS_LOAD_ERROR:return this.__handleOne(a,this.buildKey(c),c.error);case b("InstreamVideosSensitiveAdsBlockListActionTypes").SENSITIVE_ADS_MODAL_XOUT:var d=this.getReviewStatus(c);return this.__handleOne(a,this.buildKey(c),babelHelpers["extends"]({},d,{isDialogDismissed:!0}));default:return a}};d.__load=function(a){b("InstreamVideosSensitiveAdsBlockListConfirmationDataManager").load(this.getParams(a))};d.getReviewStatus=function(b){b=a.prototype.get.call(this,this.buildKey(b));return b.match({loading:function(){return{isDialogDismissed:!1,shouldReviewBlockList:!1}},error:function(){return{isDialogDismissed:!1,shouldReviewBlockList:!1}},loaded:function(a){return a}})};d.buildKey=function(a){if(a.sourceApp==="creator_studio")return g(babelHelpers["extends"]({},a,{pageID:"0"}));else return g(babelHelpers["extends"]({},a,{businessID:"0"}))};d.getParams=function(a){return{businessID:a.businessID,pageID:a.pageID,userID:a.userID,sourceApp:a.sourceApp}};return c}(b("FluxLoadObjectStore"));a.__moduleID=e.id;e.exports=new a(b("InstreamVideosSensitiveAdsBlockListDispatcher"))}),null); __d("InstreamVideoSensitiveAdsBlocklistReviewNoticeContainer",["AdsFluxContainer","InstreamVideosSensitiveAdsBlockListConfirmationDataManager","InstreamVideosSensitiveAdsBlockListConfirmationDataStore","InstreamVideosSensitiveAdsBlockListDispatcher","JSResource","React","lazyLoadComponent"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("lazyLoadComponent")(b("JSResource")("CreatorSensitiveBlocklistReviewNotice.react").__setRef("InstreamVideoSensitiveAdsBlocklistReviewNoticeContainer"));a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){var d;d=a.call(this,c)||this;d.$1=function(){if(d.props.userID===void 0||d.props.userID===null)return;b("InstreamVideosSensitiveAdsBlockListConfirmationDataManager").blockListConfirmed({businessID:d.props.businessID,pageID:"0",userID:d.props.userID,sourceApp:"creator_studio"})};b("InstreamVideosSensitiveAdsBlockListDispatcher").explicitlyRegisterStores([b("InstreamVideosSensitiveAdsBlockListConfirmationDataStore")]);return d}c.getStores=function(){return[b("InstreamVideosSensitiveAdsBlockListConfirmationDataStore")]};c.calculateState=function(a,c){if(c.userID===void 0||c.userID===null)return{shouldReviewBlocklist:!1};a=b("InstreamVideosSensitiveAdsBlockListConfirmationDataStore").getReviewStatus({businessID:c.businessID,pageID:"0",userID:c.userID,sourceApp:"creator_studio"}).shouldReviewBlockList;return{shouldReviewBlocklist:a}};var d=c.prototype;d.render=function(){return b("React").createElement(b("React").Suspense,{fallback:b("React").createElement("div",null)},b("React").createElement(g,{shouldReviewBlocklist:this.state.shouldReviewBlocklist,onClose:this.$1}))};return c}(b("React").PureComponent);e.exports=b("AdsFluxContainer").create(a,{withProps:!0,name:e.id})}),null); __d("MonetizationAdBreakSharedFunctions",["ix","DateTime","FlexLayout.react","LineClamp.react","React","SUIDateTimeUtil","SUIGlyphIcon.react","SUITableTextCell.react","SUIText.react","Timezone","Tooltip","asset"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();var h=32;function a(a){return b("React").createElement(i,babelHelpers["extends"]({},a,{weight:"bold"}))}function c(a){return b("React").createElement(i,babelHelpers["extends"]({},a,{color:"placeholder",size:"body2"}))}function i(a){var c=a.text,d=a.margin,e=a.weight,f=a.color;a=a.size;return b("React").createElement(b("SUIText.react"),{color:f?f:"primary",margin:d,size:a?a:"body1",weight:e?e:"normal"},c)}f=function(a,c){c===void 0&&(c="M d, Y");a=new(b("DateTime"))(a,b("Timezone").getEnvironmentTimezoneID());return b("React").createElement("span",null,b("SUIDateTimeUtil").getFormattedDay(a,c),"\xa0",b("SUIDateTimeUtil").getTimeOrYear(a))};function d(a){a=a.tooltip!=null?b("React").createElement(b("FlexLayout.react"),{align:"center",direction:"horizontal",justify:a.centerText!=null?"center":"start"},a.text,b("React").createElement("div",{style:{marginLeft:"8px"}},b("React").createElement(b("SUIGlyphIcon.react"),babelHelpers["extends"]({},b("Tooltip").propsFor(a.tooltip.toString()),{srcDefault:g("481013")})))):a.text;a=b("React").createElement(b("LineClamp.react"),{lineHeight:16,lines:1},a);return b("React").createElement(i,{color:"placeholder",size:"body3",text:a,weight:"bold"})}var j=function(a,c){return b("React").createElement(b("SUITableTextCell.react"),{content:a.labels[c],height:h})};e.exports={MonetizationColumnHeader:d,formatTime:f,headerRenderer:j,Subtitle:c,Text:i,Title:a}}),null); __d("PagesSettingsInstreamAdsBlockListGlyphButton.react",["cx","React","SUIGlyphIcon.react","Tooltip"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f0;var f,g;a!=null&&a.restrictedCountries!=null&&(f=j(a.restrictedCountries),a.restrictedCountriesInWhitelist===!0?g=i._("Target: {Country List}",[i._param("Country List",f)]):g=i._("Exclude: {Country List}",[i._param("Country List",f)]));return b("React").createElement(b("SUITableSubtitleCell.react"),{align:"left",height:r,subtitle:d,title:b("React").createElement("div",null,b("React").createElement(n,{margin:"_3-94",text:c&&g!=null?g:a.name}),e)})}function c(a){a=a.isPageLevel?i._("All videos"):i._("{number-of-videos} videos",[i._param("number-of-videos",a.numVideosApplied)]);return b("React").createElement(b("SUITableGenericCell.react"),{align:"left",content:b("React").createElement(m,{text:a}),height:q})}function d(a){var c=a.isPageLevel?b("React").createElement(m,{text:i._("Page-level")}):b("React").createElement(m,{text:i._("Video-level")}),d=b("React").createElement(b("SUIToken.react"),{backgroundColor:"#8D949E",color:"#FFFFFF",label:i._("Business"),tooltip:i._("This block list was added by a Business Manager admin and can't be edited. Contact your Business Manager admin for more info.")});return b("React").createElement(b("SUITableSubtitleCell.react"),{align:"left",height:r,subtitle:a.isBusinessLevel?d:"",title:c})}function f(a){var c=i._("Created {date}",[i._param("date",o(a.dateCreated))]);return b("React").createElement(b("SUITableSubtitleCell.react"),{align:"left",height:r,subtitle:b("React").createElement(l,{text:c}),title:b("React").createElement(m,{text:o(a.dateModified)})})}function h(a){if(a.isBusinessLevel)return null;a=b("React").createElement("div",{style:{marginRight:"12px"}},b("React").createElement(b("FlexLayout.react"),{align:"center",justify:"all"},b("React").createElement("div",null,b("React").createElement(b("PagesSettingsInstreamAdsBlockListGlyphButton.react"),{srcDefault:g("483106"),srcHover:g("484291"),tooltip:i._("Edit"),onClick:a.onEdit})),b("React").createElement("div",{style:{marginLeft:"24px"}},b("React").createElement(b("PagesSettingsInstreamAdsBlockListGlyphButton.react"),{srcDefault:g("491187"),srcHover:g("524061"),tooltip:i._("Delete"),onClick:a.onDelete}))));return b("React").createElement(b("SUITableGenericCell.react"),{align:"right",content:a,height:r})}function v(a){__p&&__p();var c=a.blockLists,d=a.height,e=a.isBodyLoading,f=a.isSinglePageContext;a=a.isCountryRestrictions;if(e)return b("React").createElement(b("SUISpinner.react"),{margin:"_3-9b"});e=s.reduce(function(a,b){return Object.assign(a,(a={},a[b.columnKey]=b.headerLabel,a))},{});a&&(e=t.reduce(function(a,b){return Object.assign(a,(a={},a[b.columnKey]=b.headerLabel,a))},{}));return c.length===0?null:b("React").createElement(b("SUISimpleTable.react"),{borders:"rows",headerProps:{item:{labels:e},height:32},items:c,maxHeight:d,rowHeight:r},s.map(function(a){return a.hiddenOnSinglePageContext&&!f?null:b("React").createElement(b("SUISimpleTableColumn.react"),{cell:a.cellRenderer,columnKey:a.columnKey,flexibleWidth:a.flexibleWidth?a.flexibleWidth:{},header:p,key:a.columnKey})}))}e.exports={BlockListTable:v,SystemGeneratedBlocklistToken:u}}),null); __d("MonetizationAdBreakBlockListsPageTableConfigs",["ix","cx","fbt","ClickableArea.react","FlexLayout.react","MonetizationAdBreakBlockListsTableConfigs","MonetizationAdBreakSharedFunctions","PUIExpandableContent.react","React","SUIButton.react","SUIGlyphIcon.react","SUISimpleTable.react","SUISimpleTableColumn.react","SUITableGenericCell.react","SUITableMediaCell.react","asset","cxMargin"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();var j=b("MonetizationAdBreakBlockListsTableConfigs").BlockListTable;f=b("MonetizationAdBreakSharedFunctions").MonetizationColumnHeader;var k=b("MonetizationAdBreakSharedFunctions").Subtitle,l=b("MonetizationAdBreakSharedFunctions").Title,m=b("MonetizationAdBreakSharedFunctions").headerRenderer,n=45,o=80,p=[{columnKey:"page",flexibleWidth:{basis:"300px",grow:1},headerLabel:b("React").createElement(f,{text:i._("Page")}),cellRenderer:a},{columnKey:"blockList",flexibleWidth:{basis:"650px",grow:1},headerLabel:b("React").createElement(f,{text:i._("Block Lists")}),cellRenderer:c}];function a(a){var c=b("React").createElement(l,{margin:"_3-9a _3-95",text:a.name}),d=i._("{page-category} \/ {follower-count} Followers",[i._param("page-category",a.category),i._param("follower-count",a.totalFollowers)]);d=b("React").createElement(k,{margin:"_3-9a",text:d});return b("React").createElement(b("SUITableMediaCell.react"),{align:"left",height:o,imageHeight:n,imageURI:a.thumbnail,subtitle:d,title:c})}function q(a){var c=a.countryRestrictions.length,d=c===0?i._("No country restrictions"):i._("See country restrictions ({block-list-count})",[i._param("block-list-count",c)]);d=b("React").createElement("div",null,b("React").createElement(l,{margin:"_3-90",text:d}),c>0?b("React").createElement(b("SUIGlyphIcon.react"),{srcDefault:a.isCountryRestrictionsExpanded?g("511152"):g("481880")}):null);c>0&&(d=b("React").createElement(b("ClickableArea.react"),{onClick:a.onExpandCountryRestrictionsButtonClick},b("React").createElement("div",{className:"_6dmj"},d)));c=b("React").createElement(b("SUIButton.react"),{height:"tall",label:b("React").createElement(l,{text:i._("Create Country Restrictions")}),margin:"_3-91",onClick:a.onAddCountryRestrictionsButtonClick});d=b("React").createElement(b("FlexLayout.react"),{align:"center",justify:"all",style:{width:"100%"}},d,c);return b("React").createElement("div",null,b("React").createElement(b("SUITableGenericCell.react"),{align:"left",content:d,height:o}),b("React").createElement(b("PUIExpandableContent.react"),{isExpand:a.isCountryRestrictionsExpanded},b("React").createElement(j,{blockLists:a.countryRestrictions,isCountryRestrictions:!0})))}function c(a){var c=a.blockLists.length,d=c===0?i._("No block lists"):i._("See block lists ({block-list-count})",[i._param("block-list-count",c)]);d=b("React").createElement("div",null,b("React").createElement(l,{margin:"_3-90",text:d}),c>0?b("React").createElement(b("SUIGlyphIcon.react"),{srcDefault:a.isExpanded?g("511152"):g("481880")}):null);c>0&&(d=b("React").createElement(b("ClickableArea.react"),{onClick:a.onExpandClick},b("React").createElement("div",{className:"_6dmj"},d)));c=b("React").createElement(b("SUIButton.react"),{height:"tall",label:b("React").createElement(l,{text:i._("Create Block List")}),margin:"_3-91",onClick:a.onAddButtonClick});d=b("React").createElement(b("FlexLayout.react"),{align:"center",justify:"all",style:{width:"100%"}},d,c);c=a.isPageEligibleForCountryRestrictions;return b("React").createElement("div",null,b("React").createElement(b("SUITableGenericCell.react"),{align:"left",content:d,height:o}),b("React").createElement(b("PUIExpandableContent.react"),{isExpand:a.isExpanded},b("React").createElement(j,{blockLists:a.blockLists})),c&&q(a))}function d(a){var c=a.pages,d=a.height,e=a.isBodyLoading;a=a.rowHeightGetter;var f=p.reduce(function(a,b){return Object.assign(a,(a={},a[b.columnKey]=b.headerLabel,a))},{});return b("React").createElement(b("SUISimpleTable.react"),{borders:"rows",headerProps:{item:{labels:f},height:32},isBodyLoading:e,items:c,loadingRowCount:c.length,maxHeight:d,rowHeight:a},p.map(function(a){return b("React").createElement(b("SUISimpleTableColumn.react"),{cell:a.cellRenderer,columnKey:a.columnKey,flexibleWidth:a.flexibleWidth?a.flexibleWidth:{},header:m})}))}e.exports={PagesTable:d}}),null); __d("MonetizationErrorStateMessage.react",["cx","fbt","ix","CenteredContainer.react","Image.react","React"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();function j(a){switch(a){case"settings":return h._("settings.");case"block_list":return h._("block lists.");default:return h._("information")}}a={notEnoughMESInfo:function(){return b("React").createElement(b("CenteredContainer.react"),{className:"_6ao7",vertical:!0},b("React").createElement(b("Image.react"),{className:"_1ldz",src:i("584093")}),b("React").createElement("div",null,h._("Monetization eligibility status isn't available for Pages that are new to using monetization tools.")),b("React").createElement("div",null,h._("After you've monetized some of your content in your page, you'll be able to see info about your eligibility status here.")))},noAdBreakPagesSelectedErrorForTab:function(a){return b("React").createElement(b("CenteredContainer.react"),{className:"_6ao7",vertical:!0},b("React").createElement(b("Image.react"),{className:"_1ldz",src:i("584093")}),b("React").createElement("div",null,h._("None of the selected Pages are eligible for ad breaks.")),b("React").createElement("div",null,h._("Select a Page that's eligible for ad breaks to see your {sub-tab-name}",[h._param("sub-tab-name",j(a))])))}};e.exports=a}),null); __d("CountryRestrictionsSearchSource.react",["AbstractSearchSource","CountryNamesConfig","SearchableEntry","filterObject","forEachObject"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("CountryNamesConfig").codeToName;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.searchImpl=function(a,c){var d=[];if(a){var e=a.toLowerCase(),f=b("filterObject")(g,function(a){return a.toLowerCase().startsWith(e)}),h=0;b("forEachObject")(f,function(a,c){d.push(new(b("SearchableEntry"))({order:h++,title:a,uniqueID:c.toString()}))})}c(d,a)};return c}(b("AbstractSearchSource"));e.exports=a}),null); __d("PageSettingsTypeahead.react",["cx","CountryRestrictionsSearchSource.react","React","XUITokenizer.react","immutable"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var b,c;for(var d=arguments.length,e=new Array(d),f=0;f0?c.length:1,h=f.length>0?f.length:1,i=d.has(b.id)&&c.length>0,j=b.isPageEligibleForCountryRestrictions,k=j&&e.has(b.id)&&f.length>0;return babelHelpers["extends"]({},b,{blockLists:c,countryRestrictions:f,height:i?a.getSubTableRowHeight(g):o,multiTableHeight:i||k?(i?a.getSubMultiTableRowHeight(g):0)+(k?a.getSubMultiTableRowHeight(h):0):j?p:o,isExpanded:i,isCountryRestrictionsExpanded:k,onExpandClick:function(){a.setState({expandedPageIDs:i?d["delete"](b.id):d.add(b.id)})},onAddButtonClick:function(){a.onClickCreateNewButton(b.id)},onAddCountryRestrictionsButtonClick:function(){a.onClickCreateNewCountryRestrictionButton(b.id)},onExpandCountryRestrictionsButtonClick:function(){a.setState({expandedPageIDsForCountryRestrictions:k?e["delete"](b.id):e.add(b.id)})}})})};d.getSubTableRowHeight=function(a){return a*q+o+n+40};d.getSubMultiTableRowHeight=function(a){return a*q+p+n+40};d.getBlockListsForPageID=function(a){var b=this,c=this.props.blockLists.filter(function(b){b=b.owners;return b==null?!1:!!b.find(function(b){return b==a})});return c.map(function(c){return babelHelpers["extends"]({},c,{onEdit:function(){b.onBlockListEdit(a,c)},onDelete:function(){b.props.setPageIDForDeletion(a),b.onBlockListDelete(c,!1)}})})};d.getCountryRestrictionsForPageID=function(a){var b=this,c=this.props.countryRestrictions.filter(function(b){b=b.owners;return b==null?!1:!!b.find(function(b){return b==a})});return c.map(function(c){return babelHelpers["extends"]({},c,{onEdit:function(){b.onCountryRestrictionEdit(a,c)},onDelete:function(){b.props.setPageIDForDeletion(a),b.onBlockListDelete(c,!0)}})})};d.onBlockListDelete=function(a,c){var d=this,e=b("React").createElement("div",{className:"_4xfq"},h._("Are you sure you want to delete the block list {name}?",[h._param("name",a.name)]));c&&(e=b("React").createElement("div",{className:"_4xfq"},h._("Are you sure you want to delete these country restrictions?"),b("React").createElement("br",null),h._("{name}",[h._param("name",a.name)])));b("SimpleXUIDialog").showConfirm(e,h._("Delete"),function(b){b&&d.props.onDeleteBlockLists([a.id])})};d.onBlockListEdit=function(a,c){this.props.setPageIDForContentDialog(a),this.props.onSelectBlockList(c),b("MediaManagerMonetizationAdBreakTabActions").selectBlockList(c.id),this.setState({showBlockListContentDialog:!0})};d.onCountryRestrictionEdit=function(a,c){this.props.setPageIDForContentDialog(a),this.props.onSelectBlockList(c,!0),b("MediaManagerMonetizationAdBreakTabActions").selectBlockList(c.id),this.setState({showCountryRestrictionsContentDialog:!0})};d.onClickCreateNewButton=function(a){this.props.setPageIDForContentDialog(a),this.props.onSelectBlockList(null),b("MediaManagerMonetizationAdBreakTabActions").selectBlockList(null),this.setState({showBlockListContentDialog:!0})};d.onClickCreateNewCountryRestrictionButton=function(a){this.props.setPageIDForContentDialog(a),this.props.onSelectBlockList(null,!0),b("MediaManagerMonetizationAdBreakTabActions").selectBlockList(null),this.setState({showCountryRestrictionsContentDialog:!0})};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListImportDialog.react",["cx","fbt","FileInput.react","LayerFadeOnHide","LayerFadeOnShow","React","XUIButton.react","XUIDialog.react","XUIDialogBody.react","XUIDialogCancelButton.react","XUIDialogFooter.react","XUIDialogTitle.react","XUIRadioList.react"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=b("XUIRadioList.react").Item;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b){__p&&__p();var c;c=a.call(this,b)||this;c.$2=function(a){a||c.props.onCancel()};c.$3=function(a){var b=!1;c.state.radioState==="replace"&&(b=!0);c.props.onImportBlockLists(b,a.target);c.props.onConfirm()};c.$1=function(a){c.setState({radioState:a})};c.state={radioState:"add"};return c}var d=c.prototype;d.render=function(){if(!this.props.isShown)return null;var a=null;this.props.showRadioList&&(a=b("React").createElement(b("XUIRadioList.react"),{className:"_5_qk",onValueChange:this.$1,selectedValue:this.state.radioState},b("React").createElement(i,{value:"add"},h._("Add as a new block list")),b("React").createElement(i,{value:"replace"},h._("Replace current block lists"))));return b("React").createElement(b("XUIDialog.react"),{behaviors:{LayerFadeOnHide:b("LayerFadeOnHide"),LayerFadeOnShow:b("LayerFadeOnShow")},onToggle:this.$2,shown:this.props.isShown,width:500},b("React").createElement(b("XUIDialogTitle.react"),null,h._("Import Block Lists")),b("React").createElement(b("XUIDialogBody.react"),null,h._("Import an existing block list (.csv) from another Page to use it on this Page."),a),b("React").createElement(b("XUIDialogFooter.react"),null,b("React").createElement(b("XUIDialogCancelButton.react"),null),b("React").createElement(b("FileInput.react"),{ref:"fileInput",onChange:this.$3,name:"csv_file",accept:"text/csv"},b("React").createElement(b("XUIButton.react"),{use:"confirm",label:h._("Upload CSV"),href:"#"}))))};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListItem.react",["ix","cx","fbt","InstreamAdsBlockListState","MonetizationAdBreakBlockListsTableConfigs","PagesSettingsInstreamAdsBlockListGlyphButton.react","React","SimpleXUIDialog","Tooltip","cxMargin","fbglyph","gkx"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();var j=b("MonetizationAdBreakBlockListsTableConfigs").SystemGeneratedBlocklistToken;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b){b=a.call(this,b)||this;b.state={isActive:!1};return b}var d=c.prototype;d.render=function(){__p&&__p();var a=null,c=null,d=null,e=null;if(!this.props.requestSent&&this.state.isActive){var f=this.props.editable?g("126554"):g("126072"),h=this.props.editable?g("128156"):g("127674"),k=this.props.editable?i._("Edit"):i._("Open");c=b("React").createElement("div",{className:"_3-9c"},b("React").createElement(b("PagesSettingsInstreamAdsBlockListGlyphButton.react"),{srcDefault:f,srcHover:h,tooltip:k,onClick:this.$1.bind(this)}));this.props.editable&&(d=b("React").createElement("div",{className:"_3-9c"},b("React").createElement(b("PagesSettingsInstreamAdsBlockListGlyphButton.react"),{srcDefault:g("125921"),srcHover:g("127523"),tooltip:i._("Delete"),onClick:this.$2.bind(this)})));this.props.enableBlockListExportButton&&(e=b("React").createElement(b("PagesSettingsInstreamAdsBlockListGlyphButton.react"),{srcDefault:g("126026"),srcHover:g("127628"),tooltip:i._("Export"),onClick:this.$3.bind(this)}))}if(this.props.appliable){f=this.$4()?g("122578"):g("123261");h=this.props.blockList.isPageLevel;k=null;h||(k=this.$4()?i._("Cancel"):i._("Apply"));a=b("React").createElement(b("PagesSettingsInstreamAdsBlockListGlyphButton.react"),{active:this.$4()||this.$5(),disabled:h,hidden:!this.state.isActive&&!this.$4()&&!this.$5(),srcActive:f,srcDefault:g("125782"),srcHover:g("127384"),tooltip:k,onClick:this.$6.bind(this)})}h=b("gkx")("712154");return b("React").createElement("li",{className:"_apd"+(this.state.isActive?" _2hpc":""),key:this.props.blockList.id,onMouseEnter:this.$7.bind(this),onMouseLeave:this.$8.bind(this)},a,b("React").createElement("div",{className:"_2hpd"},b("React").createElement("div",{className:"_apj"},this.props.blockList.name,h&&this.props.blockList.isSystemGenerated?b("React").createElement(j,{margin:"_3-9a _3-8w"}):null),b("React").createElement("div",{className:"_apk"},this.$9())),e,c,d)};d.$9=function(){if(this.props.blockList.isPageLevel)return b("React").createElement("span",null,this.$10(),i._("Page-level block list")," \xb7 ",i._("Applied to all videos"));else if(this.props.blockList.numVideosApplied>0)return b("React").createElement("span",null,this.$10(),i._({"*":"Applied to {number} videos","_1":"Applied to 1 video"},[i._plural(this.props.blockList.numVideosApplied,"number")]));return b("React").createElement("span",null,this.$10(),i._("Not yet applied"))};d.$10=function(){return!this.props.blockList.isBusinessLevel?null:b("React").createElement("span",babelHelpers["extends"]({className:"_1nt2"},b("Tooltip").propsFor(i._("This block list was added by a Business Manager admin and can't be edited. Contact your Business Manager admin for more info."))),i._("Business"))};d.$7=function(){this.setState({isActive:!0})};d.$8=function(){this.setState({isActive:!1})};d.$3=function(){this.props.onClickExportSingleBlockList(this.props.blockList.id)};d.$1=function(){this.props.onClickItem(this.props.blockList)};d.$2=function(){var a=this,c=b("React").createElement("div",{className:"_4xfq"},i._("Are you sure you want to delete the block list {name}?",[i._param("name",this.props.blockList.name)]));b("SimpleXUIDialog").showConfirm(c,i._("Delete"),function(b){b&&a.props.onDeleteItem(a.props.blockList.id)})};d.$4=function(){return this.props.state===b("InstreamAdsBlockListState").APPLIED||this.props.blockList.isPageLevel};d.$5=function(){return this.props.state===b("InstreamAdsBlockListState").PARTIALLY_APPLIED};d.$6=function(){this.$4()?this.props.onUnapplyBlockList(this.props.blockList.id):this.props.onApplyBlockList(this.props.blockList.id),this.props.onApplyOrUnapply&&this.props.onApplyOrUnapply()};return c}(b("React").Component);e.exports=a}),null); __d("PagesSettingsInstreamAdsBlockListView.react",["ix","cx","fbt","Image.react","InfiniteScroll.react","Link.react","PagesSettingsInstreamAdsBlockListContentContainer","PagesSettingsInstreamAdsBlockListImportDialog.react","PagesSettingsInstreamAdsBlockListItem.react","PopoverMenu.react","React","ReactXUIMenu","SimpleXUIDialog","Tooltip","XUIButton.react","XUIDialogCloseButton.react","XUINotice.react","XUIText.react","XUISpinner.react","fbglyph"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();var j=b("ReactXUIMenu").Item;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){var d;d=a.call(this,c)||this;d.renderBlockListItem=function(a){return b("React").createElement(b("PagesSettingsInstreamAdsBlockListItem.react"),{appliable:d.props.appliable,blockList:a,editable:a.editable,enableBlockListExportButton:d.props.enableBlockListExportButton,key:a.id,requestSent:d.props.requestSent,state:d.props.blockListStates.get(a.id),onApplyBlockList:d.props.onApplyBlockList,onApplyOrUnapply:d.props.onApplyOrUnapply,onClickExportSingleBlockList:d.onClickExportSingleBlockList.bind(babelHelpers.assertThisInitialized(d)),onClickItem:d.onClickBlockListItem.bind(babelHelpers.assertThisInitialized(d)),onDeleteItem:d.onDeleteBlockListItem.bind(babelHelpers.assertThisInitialized(d)),onUnapplyBlockList:d.props.onUnapplyBlockList})};d.state={showBlockListContentDialog:!1,showImportDialog:!1};return d}var d=c.prototype;d.render=function(){return b("React").createElement("div",null,this.renderContent.bind(this)(),this.renderBlockListContentDialog.bind(this)(),this.renderImportDialog.bind(this)())};d.renderContent=function(){__p&&__p();if(!this.props.allBlockListsLoaded)return b("React").createElement("div",{className:"_5-ex"},b("React").createElement(b("XUISpinner.react"),{size:"large"}));if(!this.props.blockLists||this.props.blockLists.length===0){var a=null;this.props.editable||(a=b("Tooltip").propsFor(i._("Only Page admins can create new block lists.")));var c=null;this.props.enableBlockListExportButton&&this.props.editable&&(c=b("React").createElement(b("XUIButton.react"),{label:i._("Import"),use:"default",onClick:this.onClickShowImportDialog.bind(this),type:"button"}));return b("React").createElement("div",null,b("React").createElement(b("XUIButton.react"),babelHelpers["extends"]({action:"button",disabled:!this.props.editable,label:i._("Create New"),type:"button",use:"confirm",onClick:this.onClickCreateNewButton.bind(this)},a)),c)}a=null;c=null;this.props.editable&&(a=b("React").createElement("div",{className:"_ehp"},b("React").createElement(b("Link.react"),{onClick:this.onClickCreateNewButton.bind(this)},i._("Create New"))),c=b("React").createElement(j,{onClick:this.onClickShowImportDialog.bind(this)},i._("Import Block Lists")));var d=null;if(this.props.enableBlockListExportButton){c=b("React").createElement(b("ReactXUIMenu"),null,c,b("React").createElement(j,{onClick:this.onClickExportAllBlockListsButton.bind(this)},i._("Export Block Lists")));d=b("React").createElement(b("PopoverMenu.react"),{alignh:"right",className:"_4y3o",label:"Options",menu:c},b("React").createElement(b("XUIButton.react"),{image:b("React").createElement(b("Image.react"),{src:g("123028")}),label:"Settings",labelIsHidden:!0}))}c=null;this.props.didImportBlockLists&&(c=b("React").createElement(b("XUINotice.react"),{className:"_334k",use:"success"},b("React").createElement(b("XUIText.react"),{size:"header4"},i._("Block Lists Updated")),b("React").createElement("br",null),b("React").createElement(b("XUIText.react"),{size:"meta1"},i._("The CSV has been applied to your block lists."))));var e=null;this.props.showLowFillRateWarning&&(e=b("React").createElement(b("XUINotice.react"),{className:"_334k",size:"small",use:"notify"},i._("Blocking too many Pages or categories could significantly reduce the availability of ads that are eligible for your videos.")));return b("React").createElement("div",null,b("React").createElement("div",null,c,e),b("React").createElement("div",{className:"_ehn _eho"},b("React").createElement(b("InfiniteScroll.react"),{distanceToEnd:5},this.props.blockLists.map(this.renderBlockListItem,this))),b("React").createElement("div",{className:"_3et1"},a,d))};d.renderBlockListContentDialog=function(){if(!this.state.showBlockListContentDialog)return null;var a=this.props.editable,c=null;this.props.selectedBlockList&&(a=this.props.selectedBlockList.editable&&this.props.editable,c=this.props.selectedBlockList.id);return b("React").createElement(b("PagesSettingsInstreamAdsBlockListContentContainer"),{onToggle:this.onToggle.bind(this),editable:a,enableSubcategories:this.props.enableSubcategories,blockListId:c})};d.renderImportDialog=function(){var a=!0;(!this.props.blockLists||this.props.blockLists.length===0)&&(a=!1);return b("React").createElement(b("PagesSettingsInstreamAdsBlockListImportDialog.react"),{isShown:this.state.showImportDialog,onCancel:this.onClickCloseImportDialog.bind(this),onConfirm:this.onClickImportBlockListButton.bind(this),onImportBlockLists:this.props.onImportBlockLists,showRadioList:a})};d.onToggle=function(a){this.setState({showBlockListContentDialog:a})};d.onClickCreateNewButton=function(){this.props.onSelectBlockList(null),this.setState({showBlockListContentDialog:!0})};d.onClickBlockListItem=function(a){this.props.onSelectBlockList(a),this.setState({showBlockListContentDialog:!0})};d.onDeleteBlockListItem=function(a){this.props.onDeleteBlockLists([a])};d.onClickShowImportDialog=function(){this.setState({showImportDialog:!0})};d.onClickCloseImportDialog=function(){this.setState({showImportDialog:!1})};d.onClickImportBlockListButton=function(){this.setState({showImportDialog:!1})};d.onClickExportAllBlockListsButton=function(){this.props.onExportAllBlockLists(),this.showExportDialog()};d.onClickExportSingleBlockList=function(a){this.props.onExportSingleBlockList(a),this.showExportDialog()};d.showExportDialog=function(){var a=i._("The block list is downloading. When it's ready, you can import the CSV file to another Page to use it."),c=b("React").createElement(b("XUIDialogCloseButton.react"),null),d=i._("Export Block Lists");b("SimpleXUIDialog").showEx(a,d,c)};return c}(b("React").Component);e.exports=a}),null); __d("VideoComposerAdBreakBlockListItem.react",["cx","fbt","FBCheckbox.react","GeoblockingTranslationUtils","InstreamAdsBlockListState","Link.react","React","SimpleXUIDialog","Tooltip","XUIGrayText.react","XUIText.react"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=b("GeoblockingTranslationUtils").getCountryList;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var c,d;for(var e=arguments.length,f=new Array(e),g=0;gthis.props.previewCharLimit,d&&!this.state.showingAll&&(c=c.substr(0,this.props.previewCharLimit)+"...");var e=this.props.className||"_1brk";return b("React").createElement("div",{className:e},b("React").createElement("div",{className:this.props.listClassName},this.props.label?b("React").createElement("div",{className:"_1brm"},this.props.label,":"," "):null,c),b("React").createElement(b("CopyrightCountryListToggleLink.react"),{canShowMore:d,showingAll:this.state.showingAll,onToggle:this.$1}))};return c}(b("React").PureComponent);a.defaultProps={previewCharLimit:295};e.exports=a}),null); __d("CopyrightCountrySearchSource",["AbstractSearchSource","CopyrightCountryNames","SearchableEntry","SortedCopyrightCountryCodes"],(function(a,b,c,d,e,f){__p&&__p();a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.getAllCountries=function(){return b("SortedCopyrightCountryCodes").map(function(a,c){return new(b("SearchableEntry"))({order:c,title:b("CopyrightCountryNames")[a],uniqueID:a})})};d.getAllValidCountriesFromInvalid=function(a){return b("SortedCopyrightCountryCodes").filter(function(b,c){return a.indexOf(b)===-1}).map(function(a,c){return new(b("SearchableEntry"))({order:c,title:b("CopyrightCountryNames")[a],uniqueID:a})})};d.getAllValidCountriesFromValid=function(a){return b("SortedCopyrightCountryCodes").filter(function(b,c){return a.indexOf(b)!==-1}).map(function(a,c){return new(b("SearchableEntry"))({order:c,title:b("CopyrightCountryNames")[a],uniqueID:a})})};d.getAllCountryIDs=function(){return b("SortedCopyrightCountryCodes").slice()};d.getCountriesCount=function(){return b("SortedCopyrightCountryCodes").length};d.searchImpl=function(a,b,c){c===void 0&&({});c=this.getAllCountries();return a&&a.length>0?b(c.filter(function(b){return b.getTitle().toLowerCase().startsWith(a.toLowerCase())}),a):b(c,a)};return c}(b("AbstractSearchSource"));e.exports=a}),null); __d("CopyrightCountrySelectorHeader.react",["cx","fbt","Link.react","React","SortedCopyrightCountryCodes","XUIGrayText.react"],(function(a,b,c,d,e,f,g,h){"use strict";a=function(a){var c=h._("Select All"),d=h._("Deselect All");d=a.countryCount===0?b("React").createElement(b("XUIGrayText.react"),null,d):b("React").createElement(b("Link.react"),{onClick:a.onDeselectAll},d);a=a.countryCount===b("SortedCopyrightCountryCodes").length?b("React").createElement(b("XUIGrayText.react"),null,c):b("React").createElement(b("Link.react"),{onClick:a.onSelectAll},c);return b("React").createElement("div",null,a,b("React").createElement("div",{className:"_6mo_"}),d)};e.exports=a}),null); __d("CopyrightCountrySelectorLabel.react",["fbt","React","SortedCopyrightCountryCodes"],(function(a,b,c,d,e,f,g){"use strict";a=function(a){if(a.countryCount===0)return g._("Select countries");else if(a.countryCount===b("SortedCopyrightCountryCodes").length)return g._("All Countries");else return g._({"*":"{number} Countries Selected","_1":"1 Country Selected"},[g._plural(a.countryCount,"number")])};e.exports=a}),null); __d("CopyrightCountrySelector.react",["cx","fbt","CopyrightCountryList.react","CopyrightCountrySearchSource","CopyrightCountrySelectorHeader.react","CopyrightCountrySelectorLabel.react","React","SUIBusinessTheme","SUISearchableSelector.react","XUIText.react","joinClasses"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=new(b("CopyrightCountrySearchSource"))();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var b,c;for(var d=arguments.length,e=new Array(d),f=0;f=0?b.splice(d,1):b.push(a);return c.setCountries(b)},c.$3=function(a){a.stopPropagation(),c.setCountries([])},c.$4=function(a){a.stopPropagation(),c.setCountries(i.getAllCountries())},b)||babelHelpers.assertThisInitialized(c)}var d=c.prototype;d.$1=function(a){__p&&__p();var b=i.getAllCountries(),c=this.props.selectedCountries;if(c===void 0)return[];if(c.length===0)return b;if(a)return b.filter(function(a){return c.indexOf(a.getUniqueID())!==-1});else return b.filter(function(a){return c.indexOf(a.getUniqueID())===-1})};d.setCountries=function(a){this.setState({countries:a.slice()});if(this.props.onChange){var b=a.map(function(a){return a.getUniqueID().toString()}),c=!0;this.props.enableExcludedCountries&&(a.length===i.getCountriesCount()?(c=!0,b=[]):a.length>i.getCountriesCount()/2&&(c=!1,b=i.getAllCountryIDs().filter(function(a){return b.indexOf(a)===-1})));this.props.onChange&&this.props.onChange(b,c)}};d.copyrightCountryList=function(a,c){return b("React").createElement(b("CopyrightCountryList.react"),{className:c,listClassName:this.props.listClassName,countries:a.map(function(a){return a.getUniqueID().toString()}),previewCharLimit:this.props.previewCharLimit})};d.copyrightCountryListSection=function(){if(this.props.showExcludedCountryList){var a=this.state.countries;if(a.length===0||a.length===i.getAllCountries().length)return null;var c=this.$1(!this.props.areCountriesIncluded);return b("React").createElement("div",null,b("React").createElement("div",{className:"_683u"},b("React").createElement(b("XUIText.react"),{color:"primary",weight:"bold"},h._("Included:")),this.copyrightCountryList(a,"_683v")),b("React").createElement("div",{className:"_683u"},b("React").createElement(b("XUIText.react"),{color:"primary",weight:"bold"},h._("Not included:")),this.copyrightCountryList(c,"_683v")))}return b("React").createElement("div",null,this.copyrightCountryList(this.state.countries))};d.render=function(){return b("React").createElement("div",{className:b("joinClasses")(this.props.className,"_2q5q")},b("React").createElement(b("SUISearchableSelector.react"),{canSelectMultiple:!0,customLabel:this.props.customLabel||b("React").createElement(b("CopyrightCountrySelectorLabel.react"),{countryCount:this.state.countries.length}),dropdownWidth:"auto",emptySearchResultsContent:h._("No matching results"),header:b("React").createElement(b("CopyrightCountrySelectorHeader.react"),{countryCount:this.state.countries.length,onDeselectAll:this.$3,onSelectAll:this.$4}),isDisabled:this.props.disabled,onChange:this.$2,placeholder:h._("All countries"),searchPlaceholder:h._("Search countries"),searchSource:i,theme:b("SUIBusinessTheme"),values:this.state.countries,width:"auto"}),this.copyrightCountryListSection())};return c}(b("React").Component);e.exports=a}),null); __d("ComposerVideoUploadContextualTooltip.react",["ix","cx","Image.react","React","XUIContextualDialog.react","XUIContextualDialogBody.react","XUIContextualDialogFooter.react","XUIContextualDialogTitle.react","XUIText.react","fbglyph","joinClasses"],(function(a,b,c,d,e,f,g,h){__p&&__p();a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){var a=this,c;this.props.light?c=g("126340"):c=g("127942");return b("React").createElement("span",null,b("React").createElement(b("Image.react"),{className:b("joinClasses")("_50lr",this.props.className),ref:"infoIcon",src:c}),b("React").createElement(b("XUIContextualDialog.react"),{contextRef:function(){return a.refs.infoIcon},hoverContextRef:function(){return a.refs.infoIcon},position:"right",width:b("XUIContextualDialog.react").WIDTH.NORMAL},b("React").createElement(b("XUIContextualDialogTitle.react"),{className:this.props.className},this.props.contextualTooltipTitle),this.props.contextualTooltipBody&&this.props.contextualTooltipBody.length!==0?b("React").createElement(b("XUIContextualDialogBody.react"),{className:this.props.className},this.props.contextualTooltipBody.map(function(a){return b("React").createElement(b("XUIText.react"),{display:"block",size:"meta1"},a)})):b("React").createElement("div",null),this.props.contextualTooltipFooter?b("React").createElement(b("XUIContextualDialogFooter.react"),{className:this.props.className},this.props.contextualTooltipFooter):b("React").createElement("div",null)))};return c}(b("React").Component);e.exports=a}),null); __d("ComposerVideoUploadTooltip.react",["ix","cx","Image.react","React","Tooltip.react","fbglyph","joinClasses"],(function(a,b,c,d,e,f,g,h){__p&&__p();a=b("React").PropTypes;c=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){var a;this.props.light?a=g("126340"):a=g("127942");return b("React").createElement(b("Tooltip.react"),{alignH:this.props.alignH,position:this.props.alignV,tooltip:this.props.tooltip},b("React").createElement(b("Image.react"),{className:b("joinClasses")("_50lr",this.props.className),src:a}))};return c}(b("React").Component);c.propTypes={alignH:a.string,alignV:a.string,className:a.string,light:a.bool,tooltip:a.any.isRequired};e.exports=c}),null); __d("ComposerVideoUploadSection.react",["cx","ComposerVideoUploadContextualTooltip.react","ComposerVideoUploadTooltip.react","React","XUIGrayText.react","XUIText.react","cxMargin"],(function(a,b,c,d,e,f,g){__p&&__p();a=b("React").PropTypes;c=function(a){"use strict";babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){var a=this.props.contextualTooltipTitle||this.props.contextualTooltipBody||this.props.contextualTooltipFooter;return b("React").createElement("div",{className:this.props.className},b("React").createElement("div",{className:"_1_hd _4qoq"},b("React").createElement(b("XUIText.react"),{size:"meta1",weight:"bold"},this.props.title),this.props.subtitle?b("React").createElement(b("XUIGrayText.react"),{size:"meta1",shade:"light",className:"_3-99"},this.props.subtitle):null,this.props.tooltip?b("React").createElement(b("ComposerVideoUploadTooltip.react"),{tooltip:this.props.tooltip}):a?b("React").createElement(b("ComposerVideoUploadContextualTooltip.react"),{contextualTooltipTitle:this.props.contextualTooltipTitle,contextualTooltipBody:this.props.contextualTooltipBody,contextualTooltipFooter:this.props.contextualTooltipFooter}):null),this.props.children)};return c}(b("React").Component);c.propTypes={className:a.string,title:a.string.isRequired,subtitle:a.node,tooltip:a.string,contextualTooltipTitle:a.string,contextualTooltipBody:a.arrayOf(a.string),contextualTooltipFooter:a.string};e.exports=c}),null); __d("CopyrightReferenceCategorySelector.react",["fbt","AdsSelectorWithTooltips.react","ComposerVideoUploadSection.react","React","VideoCopyrightContentCategoryString","cxMargin"],(function(a,b,c,d,e,f,g){__p&&__p();var h=b("AdsSelectorWithTooltips.react").Option;a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.$1=function(a){return this.props.showCategoryRequiredError&&!a?g._("Required"):null};d.render=function(){var a=[c.defaultCategory.value].concat(Object.keys(b("VideoCopyrightContentCategoryString")));a=a.map(function(a){if(a)var a=b("VideoCopyrightContentCategoryString")[a];else a=c.defaultCategory;return b("React").createElement(h,{tooltip:a.description,tooltipPosition:"right",key:a.value,value:a.value},a.label)});return b("React").createElement(b("ComposerVideoUploadSection.react"),{className:this.props.className||"_3-8-",title:this.props.hideTitleAndTooltip?"":g._("Media Category"),tooltip:this.props.hideTitleAndTooltip?null:g._("Select the format of your reference file. This selection is necessary for taxable ad earnings and can't be changed after you save it.")},b("React").createElement(b("AdsSelectorWithTooltips.react"),{margin:"_3-8w",isDisabled:this.props.disabled,onChange:this.props.onReferenceCategoryChange,value:this.props.selectedCategory||c.defaultCategory.value,placeholder:c.defaultCategory.label,maxHeight:400,errorMessage:this.$1(this.props.selectedCategory),errorTooltipPosition:"right"},a))};return c}(b("React").Component);a.defaultCategory={value:null,label:g._("Choose Category"),description:""};e.exports=a}),null); __d("VideoThumbnailView.react",["cx","Image.react","React"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=function(a){babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){return b("React").createElement("div",{className:"_2o4t"},b("React").createElement(b("Image.react"),{className:"_2o4u",src:this.props.thumbnailUrl}),b("React").createElement("div",null,b("React").createElement("div",{className:"_2o51"}),b("React").createElement("span",{className:"_2o52"},this.props.duration)))};return c}(b("React").Component);e.exports=a}),null); __d("VideoLibrarySelectorChosenItemView.react",["cx","fbt","LeftRight.react","Link.react","React","VideoFormattingUtils","VideoThumbnailView.react","XUICloseButton.react"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){return b("React").createElement("div",{className:"_4gvq"},b("React").createElement(b("LeftRight.react"),{width:342,height:64,direction:"left"},b("React").createElement("div",{className:"_wqj"},b("React").createElement(b("VideoThumbnailView.react"),{thumbnailUrl:this.props.thumbnailUrl,duration:b("VideoFormattingUtils").formatTime(this.props.durationInSeconds)})),b("React").createElement("div",{className:"_wqk"},b("React").createElement("div",{className:"_2wdn"},this.props.title?b("React").createElement("div",{className:"_4xwc"},b("React").createElement("b",null,this.props.title)," ",this.props.description):b("React").createElement("div",{className:"_4xwc"},this.props.description),b("React").createElement(b("Link.react"),{onClick:this.props.onDeselect},h._("Change Video"))),b("React").createElement("div",{className:"_4gvw"},b("React").createElement(b("XUICloseButton.react"),{size:"medium",onClick:this.props.onDeselect})))))};return c}(b("React").Component);e.exports=a}),null); __d("VideoLibrarySelectorRowView.react",["ix","cx","fbt","Image.react","LeftRight.react","React","VideoFormattingUtils","VideoThumbnailView.react","asset","formatDate"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f0?b("React").createElement("ul",{className:"_4mna"},this.state.videos.map(function(c){return b("React").createElement("li",{key:c.id},b("React").createElement(b("VideoLibrarySelectorRowView.react"),{thumbnailUrl:c.picture,durationInSeconds:c.length,creationTime:c.created_time,title:c.title,description:c.description,isSelected:a.state.selectedVideo!=null&&c.id===a.state.selectedVideo.id,onSelected:function(b){a.setState({selectedVideo:b,showSearchResult:!1}),a.props.onSelectionChanged&&a.props.onSelectionChanged(b.id,b.title?b.title:b.description)},videoId:c.id}))})):null))};return c}(b("React").Component);e.exports=a}),null); __d("CopyrightAttributionDestinationSection.react",["ix","cx","fbt","AdsPageDropdownSelector.react","GraphAPI","Image.react","LoadingIndicator.react","React","Tooltip.react","VideoCopyrightUtils","VideoLibrarySelector.react","asset","promiseDone"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();var j=100;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f.99?"_645q":""),colors:a,label:"",scale:b("SpectrumIntegerScale")().domain([0,this.props.maxDuration]),"short":!0,values:[c]}))}return b("React").createElement(b("InsightsBackgroundBar.react"),{className:this.props.className,colors:a,label:b("VideoFormattingUtils").formatTime(this.props.matchedDuration),labelWidth:"34px",scale:b("SpectrumIntegerScale")().domain([0,this.props.maxDuration]),"short":!0,values:[this.props.matchedDuration]})};return c}(b("React").Component);c.propTypes={matchedDuration:a.number.isRequired,maxDuration:a.number.isRequired,className:a.string,colors:a.array,isManualMatch:a.bool,usePercentage:a.bool,videoDuration:a.number};e.exports=c}),null); __d("PageContentTabVideosCopyrightTableWidthsConfig",[],(function(a,b,c,d,e,f){"use strict";a={COMMON:{PUBLISHED_DATE:{maxWidth:180,minWidth:80,width:120},VIDEO_VIEWS:{maxWidth:80,minWidth:60,width:65},OVERLAP:{maxWidth:180,minWidth:80,width:110},REFERENCE_VIDEO:{maxWidth:130,minWidth:60,width:100},LAST_MODIFIED_BY:{maxWidth:120,minWidth:100,width:120},DISPUTE_STATUS:{maxWidth:150,minWidth:100,width:120},TAKEDOWN_STATUS:{maxWidth:150,minWidth:100,width:120}},RULES:{DATE_CREATED:{maxWidth:140,minWidth:100,width:120},VIDEO_AUDIO:{maxWidth:140,minWidth:80,width:100},FILES:{maxWidth:140,minWidth:80,width:100}},SOUND_RECORDINGS:{STATUS:{maxWidth:240,minWidth:100,width:140},DATE_CREATED:{minWidth:100,maxWidth:140,width:120},MATCHES:{maxWidth:100,minWidth:90,width:90},ISRC:{maxWidth:160,minWidth:110,width:120}},PREMIUM_MUSIC_VIDEOS:{STATUS:{maxWidth:240,minWidth:100,width:140},DATE_CREATED:{minWidth:100,maxWidth:140,width:120},MATCHES:{maxWidth:100,minWidth:90,width:90},ISRC:{maxWidth:160,minWidth:110,width:120}},MANUAL_CLAIMS:{DATE_CREATED:{minWidth:100,maxWidth:140,width:120},VIDEO_VIEWS:{maxWidth:160,minWidth:90,width:130},LIKE_COUNT:{maxWidth:160,minWidth:90,width:130},COMMENT_COUNT:{maxWidth:160,minWidth:90,width:130}},REFERENCE_FILES:{PUBLISHED_DATE:{maxWidth:140,minWidth:100,width:120},STATUS:{maxWidth:240,minWidth:100,width:140},NEW_MATCHES:{maxWidth:160,minWidth:90,width:130}},REFERENCE_CONFLICTS:{PUBLISHER:{maxWidth:200,minWidth:100,width:140},OVERLAP:{maxWidth:200,minWidth:80,width:140},CONFLICT_STATUS:{maxWidth:200,minWidth:100,width:160}},ATTRIBUTIONS:{TITLE:{maxWidth:240,minWidth:140,width:180},STATUS:{maxWidth:180,minWidth:100,width:140},DATE_CREATED:{maxWidth:180,minWidth:100,width:140},MATCHES:{maxWidth:180,minWidth:100,width:140},REFERENCES:{maxWidth:180,minWidth:100,width:140}},AUDIO_RELEASES:{ALBUM_NAME:{maxWidth:240,minWidth:140,width:180},ARTIST_NAME:{maxWidth:180,minWidth:100,width:140},DATE_CREATED:{maxWidth:180,minWidth:100,width:110},LABEL_NAME:{maxWidth:180,minWidth:100,width:140},ICPN:{maxWidth:180,minWidth:100,width:140},AVAILABILITY_STATUS:{maxWidth:130,minWidth:130,width:130}}};e.exports=a}),null); __d("PageContentTabVideosCopyrightCommonColumnsConfig",["cx","fbt","FlexLayout.react","LineClamp.react","PageContentTabCellRenderers","PageContentTabConstants","PageContentTabCopyrightsCell.react","PageContentTabLiveStatusIndicator.react","PageContentTabVideosCopyrightOverlapCell.react","PageContentTabVideosCopyrightTableWidthsConfig","React","RightsManagerFbt","VideoCopyrightMatchStatusLabels","VideoCopyrightUtils","XUIGrayText.react"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=b("PageContentTabVideosCopyrightTableWidthsConfig").COMMON;a={getVideoColumn:function(a){return{key:"VIDEO",cellRenderer:function(a,c,d){return b("React").createElement(b("PageContentTabCopyrightsCell.react"),{containsAdBreaks:a.containsAdBreaks,contentID:a.id,contentType:a.contentType,hasAttribution:a.hasAttribution,isReferenceVideo:a.isReferenceVideo,isSelected:d.isSelected,monitoringType:a.monitoringType,pageID:a.pageID,platform:a.platform,referenceAssets:a.referenceAssets,showAttributionsIcon:a.showAttributionsIcon,showLiveStatusIcon:a.showLiveStatusIcon,showMonetizableIcon:a.showMonetizableIcon,showMonitoringTypeIcons:a.showMonitoringTypeIcons,showPlatformIcon:a.showPlatformIcon,showVideoPostIcon:a.showVideoPostIcon,subtitle:a.subtitle,videoDuration:a.duration,videoIsEditing:a.isEditing,videoIsProcessing:a.isProcessing,videoLiveStatus:a.liveStatus,videoThumbnailSrc:a.thumbnailSrc,videoTitle:a.title,width:this.width})},isShown:function(){return!0},label:a?a:h._("Matched Video"),mainColumn:!0}},getDateFoundColumn:function(a){return babelHelpers["extends"]({key:"DATE_FOUND",headerRenderer:a?b("PageContentTabCellRenderers").renderSortableHeader:null,cellRenderer:function(a,c,d){c=a.ownerName;c===null&&((d=a)!=null?(d=d.trustedPartnerInfo)!=null?d.is_trusted_partner_match:d:d)?c=h._("Trusted Partner"):c===null&&a.isBusinessPageMatch&&(c=h._("Business"));return b("React").createElement("div",{className:"_wy2",style:{width:this.width+"px"}},b("React").createElement("div",{className:"_1js2"},a.dateFound),b("React").createElement(b("FlexLayout.react"),null,b("React").createElement("span",{className:"_2tj_"},b("VideoCopyrightUtils").getMatchedOwnerBadge(a.trustedPartnerInfo&&a.trustedPartnerInfo.is_trusted_partner_match,a.isBusinessPageMatch)),b("React").createElement("span",{className:"_1js2"},b("React").createElement(b("XUIGrayText.react"),null,c))))},isShown:function(){return!0},label:h._("Created"),isResizable:!0},i.PUBLISHED_DATE)},getDisputeStatusColumn:function(a){return babelHelpers["extends"]({key:"STATUS",headerRenderer:a?b("PageContentTabCellRenderers").renderSortableHeader:null,cellRenderer:function(a,c,d){return b("React").createElement("div",{className:"_wy2",style:{width:this.width+"px"}},b("React").createElement("div",{className:"_1js2"},a.status),b("React").createElement(b("XUIGrayText.react"),{className:"_1js2",shade:d.isSelected?"dark":"light"},a.ownerName))},isShown:function(){return!0},label:b("RightsManagerFbt").STATUS,isResizable:!0},i.DISPUTE_STATUS)},getTakedownStatusColumn:function(){return babelHelpers["extends"]({key:"STATUS",headerRenderer:b("PageContentTabCellRenderers").renderSortableHeader,cellRenderer:function(a,c,d){return b("React").createElement("div",{className:"_wy2",style:{width:this.width+"px"}},b("React").createElement("div",{className:"_1js2"},b("VideoCopyrightMatchStatusLabels").statusToLabel[a.status]),b("React").createElement(b("XUIGrayText.react"),{className:"_1js2"},a.lastModifiedDate))},isShown:function(){return!0},label:b("RightsManagerFbt").STATUS,isResizable:!0},i.TAKEDOWN_STATUS)},getVideoViewsColumn:function(a){return babelHelpers["extends"]({key:"VIDEO_VIEWS",headerRenderer:a?b("PageContentTabCellRenderers").renderSortableHeader:null,cellRenderer:function(a,c,d){c=b("VideoCopyrightUtils").formatNumber(a.views);return b("React").createElement("div",{className:"_wy2"},c)},isShown:function(){return!0},label:h._("Views"),isResizable:!0,initialSortOrder:b("PageContentTabConstants").SORT_ORDER_DESC},i.VIDEO_VIEWS)},getOverlapColumn:function(a){return babelHelpers["extends"]({key:"OVERLAP",cellRenderer:function(a,c,d){return b("React").createElement("div",{className:"_wy2"},b("React").createElement(b("PageContentTabVideosCopyrightOverlapCell.react"),{className:"_3r-4",isManualMatch:a.isManualMatch,matchedDuration:a.matchedDuration,maxDuration:1,usePercentage:!0,videoDuration:a.videoDuration}))},isShown:function(){return!0},label:h._("Overlap"),headerRenderer:function(c,d,e){var f=h._("The overlapped duration of the matched video");return b("PageContentTabCellRenderers").renderHeaderWithTooltip(c,d,e,a,f)},initialSortOrder:b("PageContentTabConstants").SORT_ORDER_DESC},i.OVERLAP,{isResizable:!0})},getStatusColumn:function(a){return{key:"STATUS",headerRenderer:a?b("PageContentTabCellRenderers").renderSortableHeader:null,cellRenderer:function(a,c,d){return b("React").createElement("div",{className:"_wy2"},a.expires_days)},isShown:function(){return!0},label:h._("Status"),getWidth:function(){return 96}}},getExpiresColumn:function(a){return{key:"EXPIRES_DAYS",headerRenderer:a?b("PageContentTabCellRenderers").renderSortableHeader:null,cellRenderer:function(a,c,d){return b("React").createElement("div",{className:"_wy2"},a.expires_days)},isShown:function(){return!0},label:h._("Expires In"),getWidth:function(){return 81}}},getDisputeExpiresColumn:function(a){return{key:"DISPUTE_EXPIRES_DAYS",headerRenderer:a?b("PageContentTabCellRenderers").renderSortableHeader:null,cellRenderer:function(a,c,d){return b("React").createElement("div",{className:"_wy2"},a.expires_days)},isShown:function(){return!0},label:h._("Expires In"),getWidth:function(){return 81}}},getReferenceVideoColumn:function(a){return babelHelpers["extends"]({key:"REFERENCE_VIDEO",headerRenderer:a?b("PageContentTabCellRenderers").renderSortableHeader:null,cellRenderer:function(a,c,d){if(a.matchCount>1)return b("React").createElement("div",{className:"_4p_m",style:{width:this.width-20+"px"}},b("React").createElement(b("LineClamp.react"),{lines:2,lineHeight:18},h._({"*":"{Number of references} references"},[h._param("Number of references",a.matchCount,[0])])));c=b("React").createElement(b("PageContentTabLiveStatusIndicator.react"),{className:"_1y5d _3-8_",status:a.liveStatus});return b("React").createElement("div",{className:"_4p_m",style:{width:this.width-20+"px"}},b("React").createElement(b("LineClamp.react"),{lines:2,lineHeight:18},c,a.title," ",a.description))},isShown:function(){return!0},label:b("RightsManagerFbt").YOUR_FILE},i.REFERENCE_VIDEO,{isResizable:!0})},getLastModifiedColumn:function(a){return babelHelpers["extends"]({key:"LAST_MODIFIED_BY",cellRenderer:function(a,c,d){return b("React").createElement("div",{className:"_wy2",style:{width:this.width+"px"}},b("React").createElement("div",{className:"_1js2"},a.lastModifiedDate),b("React").createElement(b("XUIGrayText.react"),{className:"_1js2"},a.lastModifiedName))},isShown:function(){return!0},label:a},i.LAST_MODIFIED_BY,{isResizable:!0})},getManualActionColumn:function(a){return babelHelpers["extends"]({key:"MANUAL_REVIEW_ACTION",cellRenderer:function(a,c,d){return b("React").createElement("div",{className:"_wy2",style:{width:this.width+"px"}},b("React").createElement("div",{className:"_1js2"},a.lastModifiedDate),b("React").createElement(b("XUIGrayText.react"),{className:"_1js2"},a.actionName))},isShown:function(){return!0},label:a},i.LAST_MODIFIED_BY,{isResizable:!0})},getLastClaimedColumn:function(a){return babelHelpers["extends"]({key:"LAST_MODIFIED_BY",cellRenderer:function(a,c,d){return b("React").createElement("div",{className:"_wy2",style:{width:this.width+"px"}},b("React").createElement("div",{className:"_1js2"},a.appliedActionsLabel),b("React").createElement(b("XUIGrayText.react"),{className:"_1js2"},a.lastModifiedDate))},isShown:function(){return!0},label:a},i.LAST_MODIFIED_BY,{isResizable:!0})}};e.exports=a}),null); __d("CopyrightAttributionReferenceFilesDialogColumnConfig",["cx","PageContentTabConstants","PageContentTabVideosCopyrightCommonColumnsConfig","React","XUIGrayText.react","XUIText.react","sdk.fbt"],(function(a,b,c,d,e,f,g){"use strict";function a(){return[babelHelpers["extends"]({},b("PageContentTabVideosCopyrightCommonColumnsConfig").getVideoColumn(b("sdk.fbt")._("Reference File")),{isResizable:!1,width:340,minWidth:340,maxWidth:800}),{key:b("PageContentTabConstants").COLUMNS.ATTRIBUTION_TITLE,cellRenderer:function(a,c,d){c=a.attribution?b("React").createElement(b("XUIText.react"),{className:"_3e9m"},a.attribution.title):b("React").createElement(b("XUIGrayText.react"),{className:"_3e9m"},b("sdk.fbt")._("No ownership link"));return b("React").createElement("div",null,c)},isShown:function(){return!0},label:b("sdk.fbt")._("Ownership Link"),isResizable:!1,minWidth:260,width:260},{key:b("PageContentTabConstants").COLUMNS.PUBLISHED_DATE,cellRenderer:function(a,c,d){return!a||a.isProcessing?b("React").createElement("div",null):b("React").createElement("div",{className:"_3e9k"},b("React").createElement("div",{className:"_3e9l"},b("React").createElement("div",{className:"_3e9m"},a.dateAdded),b("React").createElement(b("XUIGrayText.react"),{className:"_3e9m"},a.creatorName)),b("React").createElement("div",{className:"_3e9n"+(d.isSelected?" selected":"")}))},isShown:function(){return!0},label:b("sdk.fbt")._("Added"),isResizable:!1,minWidth:240,width:240}]}e.exports=a}),null); __d("PageContentTabColumnConfig",["cx","FixedDataTableColumn.react","React"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();var h=36;a=791;var i=120;c={defaultHeaderRenderer:function(a,c,d){return b("React").createElement("div",{className:"_2k57",style:{width:d.width+"px"}},a)},getColumns:function(a,c,d,e,f,g,j,k){var l=this,m=c;k&&(m-=h);d.forEach(function(b){!b.mainColumn&&(b.width||b.getWidth)?m-=b.width||b.getWidth(a):b.mainColumn||(m-=i)});return d.map(function(c){var d=i;c.mainColumn?(d=m,c.width=m):(c.width||c.getWidth)&&(d=c.width||c.getWidth(a));return b("React").createElement(b("FixedDataTableColumn.react"),{columnData:{sort:e,onSortChanged:f,columnsInGroup:g.get(c.group),changeSelectedColumns:j,initialSortOrder:c.initialSortOrder,width:d,nux:c.nux},dataKey:c.key,label:c.label,key:c.key,cellRenderer:c.cellRenderer,headerRenderer:c.headerRenderer||l.defaultHeaderRenderer,width:d,minWidth:c.minWidth,maxWidth:c.maxWidth,isResizable:c.isResizable,fixed:c.fixed})})},TABLE_WIDTH:a,CHECKBOX_COLUMN_WIDTH:h,SINGLE_COLUMN_WIDTH:i};e.exports=c}),null); __d("PageContentTabTableMixin",["csx","cx","CSS","FDSCheckboxInput.maintenance.react","FixedDataTableColumn.react","PageContentTabColumnConfig","PageContentTabConstants","React","XUIRadioInput.react","areEqual","emptyFunction"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=b("React").PropTypes;c=b("PageContentTabConstants").COLUMNS;d=b("PageContentTabConstants").COLUMN_GROUPS;var i="select",j=b("PageContentTabColumnConfig").CHECKBOX_COLUMN_WIDTH,k=28,l=7e3,m=55,n=new Map();f={propTypes:{columns:a.arrayOf(a.shape({key:a.oneOf(Object.keys(c)).isRequired,label:a.string.isRequired,isShown:a.func,cellRenderer:a.func,headerRenderer:a.func,getWidth:a.func,group:a.oneOf(Object.keys(d)),initialSortOrder:a.oneOf([b("PageContentTabConstants").SORT_ORDER_ASC,b("PageContentTabConstants").SORT_ORDER_DESC])})).isRequired,className:a.string,createTableRow:a.func.isRequired,customTabState:a.object,page:a.object,posts:a.array.isRequired,rowHeight:a.number,rowClassNameGetter:a.func,headerHeight:a.number,selectedPosts:a.object.isRequired,selectionChanged:a.func,singleSelection:a.bool,showCheckboxColumn:a.bool,tableHeight:a.number,tableWidth:a.number.isRequired,highlightKey:a.string,highlightValue:a.any,onScrollEnd:a.func,onTableRowClick:a.func},getDefaultProps:function(){return{posts:[],selectedPosts:{},selectionChanged:function(){},showCheckboxColumn:!0,page:{}}},_getSize:function(){return{maxHeight:this.props.tableHeight||l,rowHeight:this.props.rowHeight||m,headerHeight:this.props.headerHeight||k,width:this.props.tableWidth}},_createRow:function(a){a=this.props.posts[a];var c=this.props.createTableRow(a,this.props.page,this.props.customTabState);c[i]=a.id;c.query=this.props.query;c.posts=this.props.posts;c.isSelected=!!this.props.selectedPosts[a.id];var d=n.get(a.id);b("areEqual")(c,d)||(n.set(a.id,c),d=c);return d},_selectAll:function(a){a?this.props.selectionChanged(this.props.posts.reduce(function(a,b){a[b.id]=!0;return a},{})):this.props.selectionChanged({})},_selectOne:function(a,b,c){var d;this.props.selectionChanged(Object.assign({},this.props.singleSelection?{}:this.props.selectedPosts,(d={},d[c]=a,d)));b.stopPropagation()},_allSelected:function(){var a=this;return this.props.selectedPosts&&this.props.posts.length>0&&this.props.posts.reduce(function(b,c){return b&&!!a.props.selectedPosts[c.id]},!0)},_handleSelectRowTarget:function(a,c){if(b("CSS").matchesSelector(a,"._4owu")||b("CSS").matchesSelector(a,"._4owv"))return!1;c=a.parentElement;return c&&(b("CSS").matchesSelector(c,"._4owu")||b("CSS").matchesSelector(c,"._4owv"))?!1:!0},_createCheckBoxColumn:function(){var a=this;return b("React").createElement(b("FixedDataTableColumn.react"),{dataKey:i,headerClassName:"_5yj5",headerRenderer:function(){return b("React").createElement("div",{className:"_2pi9"},a.props.singleSelection?null:b("React").createElement(b("FDSCheckboxInput.maintenance.react"),{onChange:a._selectAll,value:a._allSelected()}))},cellRenderer:function(a){var c=this,d=!!this.props.selectedPosts[a];return b("React").createElement("div",{"data-testid":this.props.tab+"checkbox",onClick:function(b){return c._selectOne(!d,b,a)}},this.props.singleSelection?b("React").createElement(b("XUIRadioInput.react"),{checked:d,name:"singleSelectionRadio",onChange:b("emptyFunction")}):b("React").createElement(b("FDSCheckboxInput.maintenance.react"),{onChange:function(b,d){return c._selectOne(b,d,a)},value:d}))}.bind(this),key:i,width:j})},_getRowClassName:function(a){a=this.props.posts[a];var b=this.props.highlightKey;if(this.props.rowClassNameGetter){var c=this.props.rowClassNameGetter(this.props.selectedPosts[a.id],b&&a[b]===this.props.highlightValue);if(c&&c!=="")return c}return(this.props.selectedPosts[a.id]?"":"_m3c")+(this.props.selectedPosts[a.id]?" _30p6":"")+(this.props.selectedPosts[a.id]?" _4qqm":"")+(this.props.selectedPosts[a.id]?" _d_0":"")+(b&&a[b]===this.props.highlightValue?" _hsh":"")},_handleCustomRowClick:function(a){this.props.onTableRowClick&&this.props.onTableRowClick(this.props.posts[a],this.props.page)}};e.exports=f}),null); __d("PageContentGenericTable.react",["cx","FixedDataTable.react","PageContentTabColumnConfig","PageContentTabTableMixin","React","emptyFunction","joinClasses"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=b("React").createClass({displayName:"PageContentGenericTable",mixins:[b("PageContentTabTableMixin")],render:function(){var a=[];this.props.showCheckboxColumn&&a.push(this._createCheckBoxColumn());b("PageContentTabColumnConfig").getColumns("",this.props.tableWidth,this.props.columns,{},b("emptyFunction"),new Map(),function(a,b){},this.props.showCheckboxColumn).forEach(function(b){return a.push(b)});var c=this._getSize();return b("React").createElement("div",{className:b("joinClasses")(this.props.className,"_1v6t")},b("React").createElement(b("FixedDataTable.react"),{headerHeight:c.headerHeight,maxHeight:c.maxHeight,onRowClick:this._onRowClick,onScrollEnd:this.props.onScrollEnd||b("emptyFunction"),overflowX:"hidden",overflowY:"auto",rowsCount:this.props.posts.length,rowHeight:c.rowHeight,rowClassNameGetter:this._getRowClassName,rowGetter:this._createRow,width:c.width},a))},_onRowClick:function(a,b){a=a.target;var c=this.props.posts[b].id;if(a&&!this._handleSelectRowTarget(a,c))return;this._handleCustomRowClick(b)}});e.exports=a}),null); __d("PageContentTabFilter.react",["cx","AdsGenericFilter","AdsGenericFilterSet","AdsGenericFilterSetUtil","AsyncRequest","BUIFilterTokenizer.react","React","Timezone","XBasicFBNuxDismissController","getObjectValues"],(function(a,b,c,d,e,f,g){__p&&__p();a=b("React").PropTypes;var h=4119;c=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var c,d;for(var e=arguments.length,f=new Array(e),g=0;gb)return-1;return 0};d.$2=function(){__p&&__p();var a=this,c=this.$3(),d=[];this.props.savedFilterSets&&this.props.savedFilterSets.length&&d.push(this.$5());for(var e in c){var f=c[e],g=new(b("BUIPresetFiltersGroup_DEPRECATED"))(f.groupName,f.filterFields||[],this.props.onFilterMenuChange);f.subgroups.forEach(function(c){c=new(b("BUIPresetFiltersGroup_DEPRECATED"))(c.groupName,c.filterFields||[],a.props.onFilterMenuChange);g.addSubgroup(c)});d.push(g)}return b("React").createElement(b("BUIPresetFilters_DEPRECATED.react"),{filterGroups:d,mode:b("BUIPresetFilterModes_DEPRECATED").POPOVER})};return c}(b("React").Component);c.propTypes={filterButton:a.object.isRequired,onFilterMenuChange:a.func.isRequired,onToggle:a.func,filterFieldsConfig:a.object,filterMenuVisible:a.bool,filterSet:a.object,savedFilterSets:a.array,onSavedFiltersSelectionChange:a.func,doSavedFilterSetRemove:a.func};e.exports=c}),null); __d("PageContentTabFilterUtils",["AdsGenericFilter","AdsGenericFilterField","AdsGenericFilterFieldType","AdsGenericFilterOperatorConfig","AdsGenericFilterSet","AdsGenericFilterSetUtil"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g={field:new(b("AdsGenericFilterField"))("message",b("AdsGenericFilterFieldType").STRING),operators:[b("AdsGenericFilterOperatorConfig").CONTAIN,b("AdsGenericFilterOperatorConfig").NOT_CONTAIN]};function a(a,c){if(!a)return"";c=c?c.field:g.field;a=b("AdsGenericFilterSetUtil").getFiltersByField(a,c);return a.length?a[0].value:""}function c(a,c,d){var e=c?c.field:g.field;c=c?c.operator:"CONTAIN";e=new(b("AdsGenericFilterSet"))([new(b("AdsGenericFilter"))(e,c,d)]);return a?b("AdsGenericFilterSetUtil").mergeByField(a,e,{overwriteField:!0}):e}d={getSearchTextFromFilterSet:a,addSearchToFilterSet:c};e.exports=d}),null); __d("MMRMFilterValuesConfig",["fbt"],(function(a,b,c,d,e,f,g){"use strict";a={PAGE:{value:"page",label:g._("Page")},VERIFIED_PAGE:{value:"verified_page",label:g._("Verified Page")},PERSON:{value:"person",label:g._("Person")},VIDEO_ONLY:{value:"VIDEO_ONLY"},VIDEO_AND_AUDIO:{value:"VIDEO_AND_AUDIO"},AUDIO_ONLY:{value:"AUDIO_ONLY"},PUBLIC_ONLY:{value:"PUBLIC_ONLY",label:g._("No")},PRIVATE_ONLY:{value:"PRIVATE_ONLY",label:g._("Yes")},IS_FLAGGED_ENTITY:{value:"IS_FLAGGED_ENTITY",label:g._("Yes")},IS_NOT_FLAGGED_ENTITY:{value:"IS_NOT_FLAGGED_ENTITY",label:g._("No")},IS_LIVE_BROADCAST:{value:"IS_LIVE_BROADCAST",label:g._("Is Live")},SCHEDULED_LIVE_BROADCAST:{value:"SCHEDULED_LIVE_BROADCAST",label:g._("Scheduled Live Video")},WAS_LIVE_BROADCAST:{value:"WAS_LIVE_BROADCAST",label:g._("Recorded Live")},NOT_A_BROADCAST:{value:"NOT_A_BROADCAST",label:g._("Not a Live Video")},TRUE:{value:"true"},FALSE:{value:"false"},CONFLICT_DETECTED:{value:"CONFLICT",label:g._("Conflict detected")},DISPUTE_SUBMITTED:{value:"DISPUTE_SUBMITTED",label:g._("Dispute submitted")},OWNERSHIP_DISPUTED:{value:"OWNERSHIP_DISPUTED",label:g._("Ownership disputed")},CONFLICT_EXPIRED:{value:"CONFLICT_EXPIRED",label:g._("Conflict expired")},DISPUTE_ACCEPTED:{value:"DISPUTE_ACCEPTED",label:g._("Dispute accepted")},DISPUTE_ACCEPTED_BY_YOU:{value:"DISPUTE_ACCEPTED_BY_YOU",label:g._("Dispute accepted by you")},DISPUTE_REJECTED:{value:"DISPUTE_REJECTED",label:g._("Dispute rejected")},DISPUTE_REJECTED_BY_YOU:{value:"DISPUTE_REJECTED_BY_YOU",label:g._("Dispute rejected by you")},CONFLICT_RESOLVED:{value:"CONFLICT_RESOLVED",label:g._("Conflict resolved")},DISPUTE_EXPIRED:{value:"DISPUTE_EXPIRED",label:g._("Dispute expired")},BLOCK:{value:"BLOCK"},MONETIZE:{value:"MONETIZE"},MANUAL_REVIEW:{value:"MANUAL_REVIEW"},FB:{value:"FB",label:g._("Facebook")},IG:{value:"IG",label:g._("Instagram")},DISPUTE_REASON_1:{value:"REASON_1",label:g._("Original Content")},DISPUTE_REASON_2:{value:"REASON_2",label:g._("Permission")},DISPUTE_REASON_3:{value:"REASON_3",label:g._("Other")},ACTIVE:{value:"ACTIVE",label:g._("Active")},DISABLED:{value:"DISABLED",label:g._("Disabled")},TRUSTED_PARTNER:{value:"trusted_partner",label:g._("Trusted Partner")},DISPUTABLE:{value:"DISPUTABLE",label:g._("Disputable")},NOT_DISPUTABLE:{value:"NOT_DISPUTABLE",label:g._("Not Disputable")},BUSINESS:{value:"business",label:g._("Business")},PREMIUM_MUSIC_VIDEO:{value:"PREMIUM_MUSIC_VIDEO"},SOUND_RECORDING:{value:"SOUND_RECORDING"}};e.exports=a}),null); __d("MMRMFilterUtils",["AdsGenericFilterStoreUtil","AdStudyConstants","DateTime","MMRMFilterValuesConfig","Timezone"],(function(a,b,c,d,e,f){__p&&__p();var g=b("AdsGenericFilterStoreUtil").getDateTimeFormatted,h=b("AdStudyConstants").objectValues;e.exports={dateRenderer:function(a){if(a==="")return"";a=b("DateTime").fromLegacyArgs(+a,b("Timezone").getEnvironmentTimezoneID());return a.format("F j, Y")},dateTimeRenderer:function(a){return a===""?"":g(b("Timezone").getEnvironmentTimezoneID(),a)},labelRenderer:function(a){var c=h(b("MMRMFilterValuesConfig")).find(function(b){return b.value===a});return c&&c.label||null}}}),null); __d("PageContentTabVideosCopyrightFilterGroups",["fbt"],(function(a,b,c,d,e,f,g){"use strict";a={VIDEO:{key:"video",text:g._("VIDEO DETAILS")},MATCHED_VIDEO:{key:"matched_video",text:g._("MATCH DETAILS")},REFERENCE_VIDEO:{key:"reference_video",text:g._("REFERENCE FILE")},REFERENCE_LIBRARY_VIDEO:{key:"reference_video",text:g._("Reference File")}};e.exports=a}),null); __d("PageContentTabVideosCopyrightFilterValueConfig",["fbt"],(function(a,b,c,d,e,f,g){"use strict";a={PAGE:{value:"page"},VERIFIED_PAGE:{value:"verified_page"},PROFILE:{value:"profile"},VIDEO_ONLY:{value:"VIDEO_ONLY"},VIDEO_AND_AUDIO:{value:"VIDEO_AND_AUDIO"},AUDIO_ONLY:{value:"AUDIO_ONLY"},PUBLIC_ONLY:{value:"PUBLIC_ONLY"},PRIVATE_ONLY:{value:"PRIVATE_ONLY"},IS_LIVE_BROADCAST:{value:"IS_LIVE_BROADCAST"},SCHEDULED_LIVE_BROADCAST:{value:"SCHEDULED_LIVE_BROADCAST"},WAS_LIVE_BROADCAST:{value:"WAS_LIVE_BROADCAST"},NOT_A_BROADCAST:{value:"NOT_A_BROADCAST"},TRUE:{value:"true"},FALSE:{value:"false"},CONFLICT_DETECTED:{value:"CONFLICT"},DISPUTE_SUBMITTED:{value:"DISPUTE_SUBMITTED"},OWNERSHIP_DISPUTED:{value:"OWNERSHIP_DISPUTED"},OWNERSHIP_ASSERTED:{value:"OWNERSHIP_ASSERTED"},CONFLICT_EXPIRED:{value:"CONFLICT_EXPIRED"},DISPUTE_ACCEPTED:{value:"DISPUTE_ACCEPTED"},DISPUTE_ACCEPTED_BY_YOU:{value:"DISPUTE_ACCEPTED_BY_YOU"},DISPUTE_REJECTED:{value:"DISPUTE_REJECTED"},DISPUTE_REJECTED_BY_YOU:{value:"DISPUTE_REJECTED_BY_YOU"},CONFLICT_RESOLVED:{value:"CONFLICT_RESOLVED"},DISPUTE_EXPIRED:{value:"DISPUTE_EXPIRED"},BLOCK:{value:"BLOCK"},MONETIZE:{value:"MONETIZE"},MANUAL_REVIEW:{value:"MANUAL_REVIEW"},FB:{value:"FB"},IG:{value:"IG"},POST:{value:"POST"},STORY:{value:"STORY"},DISPUTE_REASON_1:{value:"REASON_1"},DISPUTE_REASON_2:{value:"REASON_2"},DISPUTE_REASON_3:{value:"REASON_3"},ACTIVE:{value:"ACTIVE",label:g._("Active")},DISABLED:{value:"DISABLED",label:g._("Disabled")},TRUSTED_PARTNER:{value:"trusted_partner"},DISPUTABLE:{value:"true",label:g._("Disputable")},NOT_DISPUTABLE:{value:"false",label:g._("Not Disputable")},BUSINESS:{value:"business",label:g._("Business")},PREMIUM_MUSIC_VIDEO:{value:"PREMIUM_MUSIC_VIDEO"},SOUND_RECORDING:{value:"SOUND_RECORDING"}};e.exports=a}),null); __d("PageContentTabReferenceLibraryFilterFieldConfig",["fbt","AdsGenericFilterField","AdsGenericFilterFieldType","AdsGenericFilterOperatorConfig","MMRMFilterUtils","PageContentTabVideosCopyrightFilterGroups","PageContentTabVideosCopyrightFilterValueConfig","VideoCopyrightMonitoringType"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();var h=b("MMRMFilterUtils").dateRenderer,i=b("PageContentTabVideosCopyrightFilterValueConfig");function a(a){__p&&__p();var c;a.show_attributions_tab&&(c={ATTRIBUTION_TITLE:{text:g._("Attribution Title"),field:new(b("AdsGenericFilterField"))("attribution_title",b("AdsGenericFilterFieldType").STRING),operators:[b("AdsGenericFilterOperatorConfig").CONTAIN],group:b("PageContentTabVideosCopyrightFilterGroups").REFERENCE_LIBRARY_VIDEO}});a=babelHelpers["extends"]({TITLE:{text:g._("Title"),field:new(b("AdsGenericFilterField"))("title",b("AdsGenericFilterFieldType").STRING),operators:[b("AdsGenericFilterOperatorConfig").CONTAIN],group:b("PageContentTabVideosCopyrightFilterGroups").REFERENCE_LIBRARY_VIDEO},PUBLISHED_DATE:{text:g._("Date Added"),field:new(b("AdsGenericFilterField"))("published_time",b("AdsGenericFilterFieldType").DATE_RANGE),operators:[b("AdsGenericFilterOperatorConfig").IN_RANGE],valueRenderer:h,group:b("PageContentTabVideosCopyrightFilterGroups").REFERENCE_LIBRARY_VIDEO},NEW_MATCH_COUNT:{text:g._("Number of Matches"),field:new(b("AdsGenericFilterField"))("displayed_matches_count",b("AdsGenericFilterFieldType").NUMBER),operators:[b("AdsGenericFilterOperatorConfig").GREATER_THAN,b("AdsGenericFilterOperatorConfig").LESS_THAN],group:b("PageContentTabVideosCopyrightFilterGroups").REFERENCE_LIBRARY_VIDEO},MONITORING_TYPE:{text:g._("Monitoring Type"),field:new(b("AdsGenericFilterField"))("monitoring_type",b("AdsGenericFilterFieldType").STRING_SET),operators:[b("AdsGenericFilterOperatorConfig").EQUAL],values:[b("VideoCopyrightMonitoringType").VIDEO_ONLY,b("VideoCopyrightMonitoringType").VIDEO_AND_AUDIO,b("VideoCopyrightMonitoringType").AUDIO_ONLY],valueRenderer:function(a){a=b("VideoCopyrightMonitoringType")[a];return a.label},group:b("PageContentTabVideosCopyrightFilterGroups").REFERENCE_LIBRARY_VIDEO},LIVE_STATUS:{text:g._("Live Status"),field:new(b("AdsGenericFilterField"))("live_status",b("AdsGenericFilterFieldType").STRING_SET),operators:[b("AdsGenericFilterOperatorConfig").EQUAL],values:[i.IS_LIVE_BROADCAST,i.WAS_LIVE_BROADCAST,i.SCHEDULED_LIVE_BROADCAST,i.NOT_A_BROADCAST],valueRenderer:function(a){switch(a){case i.IS_LIVE_BROADCAST.value:return g._("Is Live");case i.WAS_LIVE_BROADCAST.value:return g._("Recorded Live");case i.SCHEDULED_LIVE_BROADCAST.value:return g._("Scheduled Live Video");case i.NOT_A_BROADCAST.value:default:return g._("Not a Live Video")}},group:b("PageContentTabVideosCopyrightFilterGroups").REFERENCE_LIBRARY_VIDEO}},c);return a}e.exports=a}),null); __d("PageContentTabSearchInput.react",["ix","cx","fbt","Event","Image.react","Keys","Link.react","React","XUITextInput.react","fbglyph"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();a=b("React").PropTypes;c=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var c,d;for(var e=arguments.length,f=new Array(e),g=0;g0?a=this._getStatusesFromAppliedActions(h.applied_actions):a=[h.match_status];a.forEach(function(a){a=b("VideoCopyrightUtils")._getTabFromMatchStatus(a,d);b("PageContentTabDispatcher").handlePostRemoved(d.page_id,h.id,a)});b("PageContentTabLoadingDialog").hideWithSuccessMessage(g._("SUCCESS"));return b("VideosCopyrightMatchActions").updateAppliedActions(h.id,b("PageContentTabAccessToken").getAccessToken(),c,e).then(function(a){a.success&&b("promiseDone")(b("VideosCopyrightMatchActions").getMatch(h.id,b("PageContentTabAccessToken").getAccessToken(),d),function(a){var c=f._getStatusesFromAppliedActions(a.applied_actions);c.forEach(function(c){var e=b("mergeDeep")({},a);e.match_status=c;c=b("VideoCopyrightUtils")._getTabFromMatchStatus(c,d);b("PageContentTabDispatcher").handlePostCreated(c,e,d.page_id)})})})["catch"](function(a){f._logError({tab:b("VideoCopyrightUtils")._getTabFromMatchStatus(h.match_status,d),action:b("VideoCopyrightMatchActionTypes").UPDATE_APPLIED_ACTIONS},h.id,a)})},updateMatchState:function(a,c,d){__p&&__p();var e=this;b("PageContentTabLoadingDialog").show();var f=this._getActionData(c,d);f.tab=b("VideoCopyrightUtils")._getTabFromMatchStatus(a[0].match_status,d);c=a.map(function(a){b("PageContentTabDispatcher").handlePostRemoved(d.page_id,a.id,f.tab);return b("VideosCopyrightMatchActions").updateMatchState(a.id,f.state,b("PageContentTabAccessToken").getAccessToken(),f.appliedActions).then(function(c){c.success&&b("promiseDone")(b("VideosCopyrightMatchActions").getMatch(a.id,b("PageContentTabAccessToken").getAccessToken(),d),function(a){f.newTab&&b("PageContentTabDispatcher").handlePostCreated(f.newTab,a,d.page_id)})})["catch"](function(b){e._logError(f,a.id,b)})});a.length===1&&b("PageContentTabLoadingDialog").hideWithSuccessMessage(f.successLabel);return b("Promise").all(c).then(function(){b("PageContentTabLoadingDialog").hideWithSuccessMessage(f.successLabel)})},updateMatchStateWithBulkSelection:function(a,c,d,e,f){__p&&__p();var h=this._getActionData(a,c);a=b("ActorURI").create(b("XVideoCopyrightMatchBulkDeleteController").getURIBuilder().setFBID("page_id",c.page_id).setTypeAssert("filtering",f).getURI(),c.page_id);new(b("AsyncRequest"))().setURI(a).setHandler(function(a){b("PageContentTabLoadingDialog").hide();if(a.payload){a=Object.assign({},c);a.has_bulk_deletion_in_progress=!0;d(a);b("PageContentTabLogger").log("bulk_action_taken",h.tab,{action:b("VideoCopyrightMatchActionTypes").REMOVE_FROM_DASHBOARD,num_posts:e,filter_set:JSON.stringify(f)})}else b("PageContentTabCommonConfig").showErrorDialog(g._("Something Happened"),g._("There was a problem removing the selected matches, please try again later")),b("PageContentTabLogger").log("bulk_action_failed",h.tab,{action:b("VideoCopyrightMatchActionTypes").REMOVE_FROM_DASHBOARD,num_posts:e})}).send();b("PageContentTabLoadingDialog").show()},updateDisputeState:function(a,c,d){__p&&__p();var e=this;b("PageContentTabLoadingDialog").show();var f=this._getActionData(c,d),g=a.map(function(a){b("PageContentTabDispatcher").handlePostRemoved(d.page_id,a.id,f.tab);return b("VideosCopyrightDisputeActions").updateDisputeStatus(a.dispute.id,f.status,b("PageContentTabAccessToken").getAccessToken()).then(function(e){e.success&&(c!==b("VideoCopyrightMatchActionTypes").RELEASE_CLAIM&&b("promiseDone")(b("VideosCopyrightMatchActions").getMatch(a.id,b("PageContentTabAccessToken").getAccessToken(),d),function(a){b("PageContentTabDispatcher").handlePostCreated(f.newTab,a,d.page_id)}))})["catch"](function(b){e._logError(f,a.id,b)})});a.length===1&&b("PageContentTabLoadingDialog").hideWithSuccessMessage(f.successLabel);return b("Promise").all(g).then(function(){b("PageContentTabLoadingDialog").hideWithSuccessMessage(f.successLabel)})},reportMatchError:function(a,c,d,e){var f=a[0],g=f.matched_video_asset,i=f.match_data[0].reference_asset;new(b("RidgeMatchingErrorTypedLogger"))().updateData({error_type:d,match_id:f.id,matched_video_id:g.id,reference_video_id:i.id,segment_type:e,segment_type_string:h[e],source:"DASHBOARD"}).log();return this.updateMatchState(a,b("VideoCopyrightMatchActionTypes").WRONG_MATCH,c)},removeMatchFromReport:function(a,c){var d=this,e=b("VideoCopyrightMatchActionTypes").REMOVE_FROM_REPORT,f=this._getActionData(e,c);b("promiseDone")(b("VideosCopyrightMatchActions").getMatch(a,b("PageContentTabAccessToken").getAccessToken(),c),function(a){return d._moveMatchToTab(a,c.page_id,f.tab,f.newTab)},function(b){return d._logError(f,a,b)})},setMatchReported:function(a,c,d,e){__p&&__p();var f=this;if(a.length==0)return b("Promise").resolve();b("PageContentTabLoadingDialog").show();var g=this._getActionData(c,e);c=[];var h=[],k=a.slice();while(a.length>0){var l=a.splice(0,j);c.push(b("VideosCopyrightMatchActions").getMatches(l,b("PageContentTabAccessToken").getAccessToken(),e).then(function(a){__p&&__p();Object.keys(a).map(function(b){a[b].match_status=g.status});h=h.concat(a);var c=a[0];if(c&&c.dispute){c=c.dispute;c.status===b("VideoCopyrightDisputeStatus").RESOLVED_TAKEDOWN_REQUESTED&&(g.tab=i.DISPUTES)}a.length>0&&(g.tab=i.UNSENT_REPORTS);f._moveMatchesToTab(a,d,g.tab,g.newTab)},function(a){return f._logError(g,l[0],a)}))}return b("Promise").all(c).then(function(){b("PageContentTabLoadingDialog").hide(),b("PageContentTabLogger").log("action_taken_main_view",g.tab,{action:g.action,post_ids:[k],num_posts:k.length,bulk_action:!0},h)})},_moveMatchToTab:function(a,c,d,e){b("PageContentTabDispatcher").handlePostRemoved(c,a.id,d),e&&b("PageContentTabDispatcher").handlePostCreated(e,a,c)},_moveMatchesToTab:function(a,c,d,e){var f=Object.keys(a),g=f.map(function(b){return a[b]});b("PageContentTabDispatcher").handlePostsRemoved(c,f,d);b("PageContentTabDispatcher").handlePostsCreated(e,g,c)},setMatchUpdated:function(a,c){b("PageContentTabDispatcher").handlePostChanged(a,null,c.page_id)},setMatchSeen:function(a,c){var d=this,e=b("VideoCopyrightMatchActionTypes").MARK_SEEN,f=this._getActionData(e,c);a.forEach(function(a){!a.is_viewed&&d._canToggleMatchSeen(a,c)&&b("promiseDone")(b("VideosCopyrightMatchActions").setMatchIsViewed(a.id,b("PageContentTabAccessToken").getAccessToken(),!0),function(d){a.is_viewed=!0,b("PageContentTabDispatcher").handlePostChanged(a,f.tab,c.page_id,!0)},function(b){return d._logError(f,a.id,b)})})},setMatchUnseen:function(a,c){var d=this,e=b("VideoCopyrightMatchActionTypes").MARK_SEEN,f=this._getActionData(e,c);a.forEach(function(a){a.is_viewed&&d._canToggleMatchSeen(a,c)&&b("promiseDone")(b("VideosCopyrightMatchActions").setMatchIsViewed(a.id,b("PageContentTabAccessToken").getAccessToken(),!1),function(d){a.is_viewed=!1,b("PageContentTabDispatcher").handlePostChanged(a,f.tab,c.page_id,!1)},function(b){return d._logError(f,a.id,b)})})},handleUpdateFilter:function(a,c,d){b("PageContentTabDispatcher").handleFilterChanged(c.page_id,d,a),b("PageContentTabDispatcher").handleFilterStatus(c.page_id,d,a!==null)},_logError:function(a,c,d){b("PageContentTabLoadingDialog").hide();b("SimpleXUIDialog").show(d.error_user_msg||g._("There was a problem performing this action. Please try again later"),d.error_user_title||g._("Something Happened"));b("PageContentTabLogger").log("api_error",a.tab||i.VIDEOS_COPYRIGHT,{error:JSON.stringify(d),action:a.action,post_id:c});throw d},_canToggleMatchSeen:function(a,c){return b("PageContentTabRightsManagerStore").getIsRMLite()?b("VideoCopyrightMatchStatus")[a.match_status]===b("VideoCopyrightMatchStatus").MONITORED:b("VideoCopyrightMatchStatus")[a.match_status]===b("VideoCopyrightMatchStatus").MANUAL_REVIEW},_getActionData:function(a,c){__p&&__p();var d,e,f,h,j;c=[];var k=b("PageContentTabRightsManagerStore").getIsRMLite();switch(a){case b("VideoCopyrightMatchActionTypes").ALLOW_MATCH:d=b("VideoCopyrightMatchValidStates").VERIFIED_ALLOWED;h=b("VideoCopyrightMatchStatus").ALLOWED;e=i.NEW_MATCHES;f=i.ALLOWED;j=g._("ADDED TO ALLOWED MATCHES");break;case b("VideoCopyrightMatchActionTypes").TRACK:d=b("VideoCopyrightMatchValidStates").VERIFIED_CLAIMED;h=b("VideoCopyrightMatchStatus").MONITORED;c.push(b("VideoCopyrightRuleActionType").TRACK);e=i.MANUAL_REVIEW;f=i.TRACKED;j=g._("MOVED TO MONITORED MATCHES");break;case b("VideoCopyrightMatchActionTypes").REMOVE_FROM_DASHBOARD:case b("VideoCopyrightMatchActionTypes").WRONG_MATCH:d=b("VideoCopyrightMatchValidStates").REMOVED_FROM_DASHBOARD;j=g._("REMOVED FROM DASHBOARD");break;case b("VideoCopyrightMatchActionTypes").ADD_TO_REPORT:d=b("VideoCopyrightMatchValidStates").VERIFIED_STAGED;h=b("VideoCopyrightMatchStatus").ADDED_MATCH;e=i.MANUAL_REVIEW;f=i.UNSENT_REPORTS;j=g._("ADDED TO TAKEDOWN REPORT");break;case b("VideoCopyrightMatchActionTypes").REMOVE_FROM_REPORT:d=b("VideoCopyrightMatchValidStates").MANUAL_REVIEW;h=b("VideoCopyrightMatchStatus").MANUAL_REVIEW;e=i.UNSENT_REPORTS;f=i.MANUAL_REVIEW;j=g._("MOVED TO MANUAL REVIEW");break;case b("VideoCopyrightMatchActionTypes").REMOVE_FROM_ALLOWED:d=b("VideoCopyrightMatchValidStates").UNVERIFIED;h=b("VideoCopyrightMatchStatus").NEW_MATCH;e=i.ALLOWED;f=i.NEW_MATCHES;j=g._("MOVED TO NEW MATCHES");break;case b("VideoCopyrightMatchActionTypes").MONETIZE:d=b("VideoCopyrightMatchValidStates").VERIFIED_CLAIMED;h=b("VideoCopyrightMatchStatus").CLAIMED;c.push(b("VideoCopyrightRuleActionType").MONETIZE);e=i.MANUAL_REVIEW;f=i.CLAIMED;j=g._("CLAIMED");break;case b("VideoCopyrightMatchActionTypes").WHITELIST_PAGE:e=i.MANUAL_REVIEW;j=g._("WHITELISTED");break;case b("VideoCopyrightMatchActionTypes").REPORT_SENT:case b("VideoCopyrightMatchActionTypes").LIVE_REPORT_SENT:h=b("VideoCopyrightMatchStatus").REPORTED;f=k?i.TAKEDOWNS:i.REPORTED;break;case b("VideoCopyrightMatchActionTypes").MARK_SEEN:case b("VideoCopyrightMatchActionTypes").MARK_UNSEEN:e=i.MANUAL_REVIEW;break;case b("VideoCopyrightMatchActionTypes").RETRACT_REPORTED:d=b("VideoCopyrightMatchValidStates").RETRACTED;h=b("VideoCopyrightMatchStatus").MONITORED;e=k?i.TAKEDOWNS:i.REPORTED;f=i.TRACKED;j=g._("TAKEDOWN REQUEST CANCELED");break;case b("VideoCopyrightMatchActionTypes").RETRACT_TAKEDOWN:d=b("VideoCopyrightMatchValidStates").RESTORED_BY_PUBLISHER;h=b("VideoCopyrightMatchStatus").MONITORED;e=i.TAKEDOWNS;f=i.TRACKED;j=g._("VIDEO SUCCESSFULLY RESTORED");break;case b("VideoCopyrightMatchActionTypes").CONFIRM_CLAIM:h=b("VideoCopyrightDisputeStatus").APPEAL_REJECTED;e=i.DISPUTES;j=g._("CLAIM CONFIRMED");break;case b("VideoCopyrightMatchActionTypes").BLOCK:d=b("VideoCopyrightMatchValidStates").VERIFIED_CLAIMED;h=b("VideoCopyrightMatchStatus").BLOCKED;c.push(b("VideoCopyrightRuleActionType").BLOCK);e=i.MANUAL_REVIEW;f=i.BLOCKED;j=g._("BLOCKED");break;case b("VideoCopyrightMatchActionTypes").UNBLOCK:d=b("VideoCopyrightMatchValidStates").REMOVED_FROM_DASHBOARD;e=i.BLOCKED;j=g._("UNBLOCKED");break;case b("VideoCopyrightMatchActionTypes").RELEASE_CLAIM:h=b("VideoCopyrightDisputeStatus").RESOLVED_CLAIM_RETRACTED;e=i.DISPUTES;j=g._("CLAIM RELEASED");break;case b("VideoCopyrightMatchActionTypes").UPHOLD_CLAIM:h=b("VideoCopyrightDisputeStatus").RESOLVED_CLAIM_UPHELD;e=i.DISPUTES;j=g._("CLAIM UPHELD");break;case b("VideoCopyrightMatchActionTypes").MOVE_TO_MANUAL_REVIEW:d=b("VideoCopyrightMatchValidStates").UNVERIFIED;h=b("VideoCopyrightMatchStatus").NEW_MATCH;f=i.NEW_MATCHES;j=g._("MOVED TO MANUAL REVIEW");break}return{action:a,state:d,status:h,appliedActions:c,tab:e,newTab:f,successLabel:j}}};e.exports=a}),null); __d("PageContentTabCommonActionsConfig",["fbt","AdsConvergenceGatingUtils","AdsManagerNavigationGatingUtils","AdsPERouterHelper","AdsToggleSource","PageContentTabConstants","PageContentTabExternalActions","PageContentTabVideosCopyrightActions","VideoCopyrightMatchActionTypes","VideoCopyrightMatchStatus","VideoCopyrightUtils"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=b("PageContentTabConstants").ACTIONS;var h={ACTIONS_MENU_SEPARATOR:"actions_menu_separator",CREATE_ADS_FROM_POSTS:{allowBatch:!0,getLabel:function(a){return a===1?g._("Create Ad..."):g._("Create Ads...")},isAvailable:function(a,b){return a.some(function(a){a=a.type;return a==="event"})?!1:b==="ADS_PE"},key:a.CREATE_ADS_FROM_POSTS,onClick:function(a){if(b("AdsManagerNavigationGatingUtils").getIsOptedInModernization()&&b("AdsConvergenceGatingUtils").getIsRoutingEnabled()){var c=b("AdsPERouterHelper").getPERouteBuilder();c.action(function(){b("PageContentTabExternalActions").createAdsFromPosts(a)}).tool("MANAGE_ADS").section("L3").context({toggleSource:b("AdsToggleSource").external_quick_create}).setExternalCreation(!0).navigate()}else b("PageContentTabExternalActions").createAdsFromPosts(a)}},getStaticFilterActions:function(){__p&&__p();return[h.ACTIONS_MENU_SEPARATOR,{isHeader:!0,getLabel:function(a,c){a=c&&c[0]&&c[0].status===b("VideoCopyrightMatchStatus").NEW_MATCH;if(a)return g._("VIEW NEW MATCHING VIDEOS");else return g._("VIEW MATCHING VIDEOS")}},{allowBatch:!1,getLabel:function(a,b){return g._("Posted by this Page")},key:b("VideoCopyrightMatchActionTypes").FILTER_BY_MATCH_OWNER,isAvailable:function(a,b,c){b=a[0];return b&&!b.isAnonymous},onClick:function(a,c,d,e){a=b("VideoCopyrightUtils").getMatchedOwnerFilter(a[0]);b("PageContentTabVideosCopyrightActions").handleUpdateFilter(a,c,d);e&&e()}},{allowBatch:!1,getLabel:function(a,b){return g._("For this reference file")},key:b("VideoCopyrightMatchActionTypes").FILTER_BY_REFERENCE_VIDEO,onClick:function(a,c,d,e){a=b("VideoCopyrightUtils").getReferenceVideoFilter(a[0]);b("PageContentTabVideosCopyrightActions").handleUpdateFilter(a,c,d);e&&e()}}]}};e.exports=h}),null); __d("PageContentTabPagingStore",["EventEmitter","PageContentTabConstants","PageContentTabDispatcher"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("PageContentTabConstants").ACTION_TYPES;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var c;c=a.call(this)||this;c.$PageContentTabPagingStore1=new Map();b("PageContentTabDispatcher").register(c.handleDispatcherPayload.bind(babelHelpers.assertThisInitialized(c)));return c}var d=c.prototype;d.getUIPaging=function(a,b,c){a=this.$PageContentTabPagingStore2(a,b,c);return this.$PageContentTabPagingStore1.get(a)||0};d.handleDispatcherPayload=function(a){a=a.action;if(a.actionType!==g.PAGING_CHANGED)return;var b=this.$PageContentTabPagingStore2(a.pageID,a.tab,a.queryKey);this.$PageContentTabPagingStore1.set(b,a.currentPage);this.emit("changed",a.pageID,a.tab,a.queryKey,a.currentPage)};d.$PageContentTabPagingStore2=function(a,b,c){c=c||"";return a+b+c};return c}(b("EventEmitter"));e.exports=new a()}),null); __d("PageContentTabPublishedPagePostSearchDataFetcher",["PageContentTabConfig","RelayAPIConfig","RelayFBEnvironment","RelayModern","PageContentTabPublishedPagePostSearchDataFetcherQuery.graphql"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g,h=b("RelayModern").fetchQuery;b("RelayModern").graphql;var i=b("PageContentTabConfig").posts_per_page;function a(a,c,d){b("RelayAPIConfig").setActorID(a);var e=g||(g=function(){return b("PageContentTabPublishedPagePostSearchDataFetcherQuery.graphql")});a={count:i,pageID:a,after:c,message:d};return h(b("RelayFBEnvironment"),e,a)}e.exports=a}),null); __d("PageContentTabPublishedPostDataFetcher",["PageContentTabConfig","RelayFBEnvironment","RelayModern","PageContentTabPublishedPostDataFetcherQuery.graphql"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g,h=b("RelayModern").fetchQuery;b("RelayModern").graphql;var i=b("PageContentTabConfig").posts_per_page;function a(a,c){var d=g||(g=function(){return b("PageContentTabPublishedPostDataFetcherQuery.graphql")});a={count:i,pageID:a,after:c};return h(b("RelayFBEnvironment"),d,a)}e.exports=a}),null); __d("PageContentTabDataLoader",["PageContentTabConfig","PageContentTabConstants","PageContentTabDispatcher","PageContentTabLogger","PageContentTabPagingStore","PageContentTabPublishedPagePostSearchDataFetcher","PageContentTabPublishedPostDataFetcher"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("PageContentTabConfig").posts_per_page,h=2;a=function(){__p&&__p();function a(){var a=this;this.$1=new Map();this.$2=new Map();this.$3=new Map();this.$4=new Map();b("PageContentTabPagingStore").addListener("changed",function(b,c,d,e){a.fetchNextPosts(c,d,b)})}var c=a.prototype;c.fetchPosts=function(a,b,c,d,e){var f=this.$5(d,b,c);this.$1.set(f,0);this.$2.set(f,a);this.$4.set(f,0);return this.$6(b,c,d,0,e)};c.fetchNextPosts=function(a,b,c){var d=this.$5(c,a,b);if(this.$3.get(d)){d=this.$1.get(d);this.$6(a,b,c,d)}};c.convertGraphQlToGraphApiObj=function(a,b){__p&&__p();var c;if(a==null||a.page==null)return null;c=((c=a)!=null?(c=c.page)!=null?c.published_page_posts:c:c)||((c=a)!=null?(c=c.page)!=null?c.page_posts_search:c:c);var d=((a=a)!=null?(a=a.page)!=null?(a=a.profile_photo)!=null?(a=a.featurable_image)!=null?a.uri:a:a:a:a)||"";a=c!=null&&c.nodes!==null?c.nodes.map(function(a){var c,e;e=[{name:"post_impressions_unique",values:[{value:((e=a)!=null?(e=e.insights)!=null?e.total_reach:e:e)||0}]},{name:"post_engaged_users",values:[{value:((e=a)!=null?(e=e.insights)!=null?e.engaged_user_count:e:e)||0}]}];return{graphQl_story_id:(c=a)!=null?c.id:c,object_id:(c=a)!=null?c.post_id:c,id:b+"_"+(((c=a)!=null?c.post_id:c)||""),created_time:new Date((((c=a)!=null?c.creation_time:c)||0)*1e3).toISOString(),picture:((c=a)!=null?(c=c.attachments)!=null?(c=c[0])!=null?(c=c.media)!=null?(c=c.image)!=null?c.uri:c:c:c:c:c)||((c=a)!=null?(c=c.attachments)!=null?(c=c[0])!=null?(c=c.all_subattachments)!=null?(c=c.nodes)!=null?(c=c[0])!=null?(c=c.media)!=null?(c=c.image)!=null?c.uri:c:c:c:c:c:c:c:c)||d,insights:{data:e},edit_actions:{data:[{editor:{name:(c=a)!=null?(c=c.underlying_admin_creator)!=null?c.name:c:c},edit_time:new Date((((e=a)!=null?(e=e.edit_history)!=null?(e=e.nodes)!=null?(e=e[0])!=null?e.time:e:e:e:e)||0)*1e3).toISOString()}]},message:((c=a)!=null?(c=c.message)!=null?c.text:c:c)||((e=a)!=null?(e=e.title)!=null?e.text:e:e)}}):[];return a};c.$6=function(a,c,d,e,f){__p&&__p();var g=this,h=this.$5(d,a,c),i=this.$2.get(h);this.$3.set(h,!1);var j=Date.now();return i.then(function(i){__p&&__p();if(e!==g.$1.get(h))return;var k=i.data,l=i.next;if(i.page!=null&&a===b("PageContentTabConstants").TABS.PUBLISHED_POSTS){var m;k=g.convertGraphQlToGraphApiObj(i,d);m=((m=i)!=null?(m=m.page)!=null?(m=m.published_page_posts)!=null?(m=m.page_info)!=null?m.end_cursor:m:m:m:m)||((m=i)!=null?(m=m.page)!=null?(m=m.page_posts_search)!=null?(m=m.page_info)!=null?m.end_cursor:m:m:m:m);!f?l=m?b("PageContentTabPublishedPostDataFetcher")(d,m):null:l=m?b("PageContentTabPublishedPagePostSearchDataFetcher")(d,m,f):null}g.$1.set(h,e+1);m=g.$4.get(h);var n=k?k.length:0;g.$4.set(h,m+n);b("PageContentTabDispatcher").handleInitialization(a,c,{posts:k,total_count:i.summary&&i.summary.total_count,unseen_count:i.summary&&i.summary.unseen_count,finished:!l},d);g.$1.set(h,e+1);l&&(typeof l==="function"?g.$2.set(h,i.next()):g.$2.set(h,l),g.$7(d,a,c)?g.$6(a,c,d,e+1):g.$3.set(h,!0));b("PageContentTabLogger").log("data_loaded",a,{num_posts:n,elapsed_time:Date.now()-j})},function(c){b("PageContentTabDispatcher").handleError(a,c,d);b("PageContentTabLogger").log("api_error",a,{error:JSON.stringify(c)});throw c})};c.$7=function(a,c,d){var e=b("PageContentTabPagingStore").getUIPaging(a,c,d);a=this.$5(a,c,d);c=this.$4.get(a);d=(e+h)*g;return d>c};c.$5=function(a,b,c){c=c||"";return a+b+c};return a}();e.exports=new a()}),null); __d("PageContentTabQueryStore",["EventEmitter","PageContentTabConstants","PageContentTabDispatcher"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("PageContentTabConstants").ACTION_TYPES;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var c;c=a.call(this)||this;c.$PageContentTabQueryStore1=new Map();b("PageContentTabDispatcher").register(c.handleDispatcherPayload.bind(babelHelpers.assertThisInitialized(c)));return c}var d=c.prototype;d.$PageContentTabQueryStore2=function(a,b){a=this.$PageContentTabQueryStore3(a,b);return this.$PageContentTabQueryStore1.get(a)||{queryKey:null,query:null,filter:null,sort:null}};d.getQueryKey=function(a,b){a=this.$PageContentTabQueryStore2(a,b);return a.queryKey};d.getQuery=function(a,b){a=this.$PageContentTabQueryStore2(a,b);return a.query};d.getFilter=function(a,b){a=this.$PageContentTabQueryStore2(a,b);return a.filter};d.getSort=function(a,b){a=this.$PageContentTabQueryStore2(a,b);return a.sort};d.handleDispatcherPayload=function(a){__p&&__p();a=a.action;var b=this.$PageContentTabQueryStore2(a.pageID,a.tab),c=!1;switch(a.actionType){case g.QUERY_KEY_CHANGED:b.queryKey=a.queryKey;c=!0;break;case g.QUERY_CHANGED:b.query=a.query;c=!0;break;case g.FILTER_CHANGED:b.filter=a.filter;c=!0;break;case g.SORT_CHANGED:b.sort=a.sort;c=!0;break}if(!c)return;c=this.$PageContentTabQueryStore3(a.pageID,a.tab);this.$PageContentTabQueryStore1.set(c,b);this.emit("change")};d.$PageContentTabQueryStore3=function(a,b){return a+b};return c}(b("EventEmitter"));e.exports=new a()}),null); __d("PageContentTabPostsStore",["EventEmitter","PageContentTabConstants","PageContentTabDispatcher","PageContentTabQueryStore"],(function(a,b,c,d,e,f){__p&&__p();var g=b("PageContentTabConstants").ACTION_TYPES;a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c,d){var e;e=a.call(this)||this;e.$PageContentTabPostsStore1=c;e.$PageContentTabPostsStore2=d;e.clear();b("PageContentTabDispatcher").register(e.$PageContentTabPostsStore3.bind(babelHelpers.assertThisInitialized(e)));return e}var d=c.prototype;d.clear=function(){this.$PageContentTabPostsStore4=!1,this.$PageContentTabPostsStore5=!1,this.$PageContentTabPostsStore6=void 0,this.$PageContentTabPostsStore7=[],this.$PageContentTabPostsStore8=void 0,this.$PageContentTabPostsStore9=void 0,this.$PageContentTabPostsStore10=!1,this.$PageContentTabPostsStore11=!1,this.$PageContentTabPostsStore12=new Map(),this.$PageContentTabPostsStore13=new Map(),this.$PageContentTabPostsStore14={},this.$PageContentTabPostsStore15={},this.$PageContentTabPostsStore16={},this.$PageContentTabPostsStore17=void 0};d.initPosts=function(a){if(a.key){var b=this.$PageContentTabPostsStore12.has(a.key)?this.$PageContentTabPostsStore12.get(a.key):[];this.$PageContentTabPostsStore12.set(a.key,b.concat(a.data.posts));this.$PageContentTabPostsStore13.set(a.key,a.data.total_count);this.$PageContentTabPostsStore14[a.key]=!0;this.$PageContentTabPostsStore15[a.key]=a.data.finished}else this.$PageContentTabPostsStore7=this.$PageContentTabPostsStore7.concat(a.data.posts),this.$PageContentTabPostsStore8=a.data.total_count,this.$PageContentTabPostsStore9=a.data.unseen_count,this.$PageContentTabPostsStore10=!0,this.$PageContentTabPostsStore11=a.data.finished;this.$PageContentTabPostsStore18()};d.getPosts=function(a,b,c,d){__p&&__p();var e=d?this.$PageContentTabPostsStore12.get(d):this.$PageContentTabPostsStore7;e=e||[];if(e.length===0){c([]);return}if(e[a]&&e[b-1]){c(e.slice(a,b));return}d=d?this.$PageContentTabPostsStore15[d]:this.$PageContentTabPostsStore11;d&&(b=Math.min(e.length,b),c(e.slice(a,b)))};d.getAllPosts=function(a){a=a?this.$PageContentTabPostsStore12.get(a):this.$PageContentTabPostsStore7;return a.slice(0)};d.getError=function(){return this.$PageContentTabPostsStore6};d.clearError=function(){this.$PageContentTabPostsStore6=void 0};d.shouldShowStaleContentNotice=function(){return this.$PageContentTabPostsStore4};d.setShowStaleContentNotice=function(a){this.$PageContentTabPostsStore4=a};d.setIsFilterApplied=function(a){this.$PageContentTabPostsStore5=a};d.isFilterApplied=function(){return this.$PageContentTabPostsStore5};d.hasNextPage=function(a,b){var c=b?this.$PageContentTabPostsStore12.get(b):this.$PageContentTabPostsStore7;c=c||[];b=b?this.$PageContentTabPostsStore15[b]:this.$PageContentTabPostsStore11;return c.length>a||!b};d.getPost=function(a){var b=this.$PageContentTabPostsStore7.filter(function(b){return b.id===a});return b.length?b[0]:null};d.$PageContentTabPostsStore19=function(){var a=b("PageContentTabQueryStore").getQueryKey(this.$PageContentTabPostsStore2,this.$PageContentTabPostsStore1);if(!a)return;var c=b("PageContentTabQueryStore").getFilter(this.$PageContentTabPostsStore2,this.$PageContentTabPostsStore1),d=b("PageContentTabQueryStore").getSort(this.$PageContentTabPostsStore2,this.$PageContentTabPostsStore1),e=b("PageContentTabQueryStore").getQuery(this.$PageContentTabPostsStore2,this.$PageContentTabPostsStore1);!c&&!d&&!e&&this.$PageContentTabPostsStore12.set(a,this.$PageContentTabPostsStore7)};d.addNewPost=function(a){this.$PageContentTabPostsStore8++,this.$PageContentTabPostsStore7.unshift(a),this.$PageContentTabPostsStore19(),this.$PageContentTabPostsStore18()};d.addNewPosts=function(a){this.$PageContentTabPostsStore8+=a.length,this.$PageContentTabPostsStore7=a.concat(this.$PageContentTabPostsStore7),this.$PageContentTabPostsStore19(),this.$PageContentTabPostsStore18()};d.bringNewPostToTop=function(a){a.id&&this.removePost(a.id),this.addNewPost(a)};d.removePost=function(a){var b=this,c=this.getPost(a)!==null;this.$PageContentTabPostsStore8=c?this.$PageContentTabPostsStore8-1:this.$PageContentTabPostsStore8;this.$PageContentTabPostsStore7=this.$PageContentTabPostsStore7.filter(function(b){return b.id!==a});this.$PageContentTabPostsStore12.forEach(function(c,d,e){var f=c.filter(function(b){return b.id!==a});f.length Rights Manager."))))),b("React").createElement(b("XUIDialogFooter.react"),null,b("React").createElement(b("XUIDialogButton.react"),{action:"cancel",className:"_3-90",label:h._("Not Now"),use:"default"}),b("React").createElement(b("XUIDialogButton.react"),{action:"confirm",label:h._("Go to Settings"),onClick:function(){b("goURI")(a,!0)},use:"confirm"})))};return c}(b("React").Component);e.exports=a}),null); __d("VideoCopyrightClaimAdEarningsNUXDialog.react",["cx","fbt","ix","Image.react","LayerFadeOnHide","LayerHideOnEscape","LeftRight.react","React","VideoCopyrightClaimAdEarningsText","XUIDialog.react","XUIDialogBody.react","XUIDialogButton.react","XUIDialogFooter.react","XUIDialogTitle.react","XUIText.react","cxMargin","goURI"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();a=function(a){babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){var a=b("VideoCopyrightClaimAdEarningsText").getRightsManagerSettingsURI(this.props.pageID);return b("React").createElement(b("XUIDialog.react"),{behaviors:{LayerHideOnEscape:b("LayerHideOnEscape"),LayerFadeOnHide:b("LayerFadeOnHide")},onToggle:this.props.onToggle,ref:"claimAdsEarningConfirmationDialog",shown:!0,width:658},b("React").createElement(b("XUIDialogTitle.react"),null,b("VideoCopyrightClaimAdEarningsText").getTitle()),b("React").createElement(b("XUIDialogBody.react"),null,b("React").createElement(b("LeftRight.react"),{className:"_3-8h"},b("React").createElement(b("Image.react"),{className:"_3-8w _3-9a",src:i("101755")}),b("React").createElement("div",{className:"_2fi-"},b("React").createElement(b("XUIText.react"),{className:"_3-96",display:"block"},b("VideoCopyrightClaimAdEarningsText").getMessage()),b("React").createElement(b("XUIText.react"),null,h._("To edit how you or your organization would like to be paid, go to {rights-manager-setting}",[h._param("rights-manager-setting",b("React").createElement("a",{onClick:function(){b("goURI")(a,!0)},role:"link",tabIndex:"0"},h._("Settings > Rights Manager"),"."))]))))),b("React").createElement(b("XUIDialogFooter.react"),null,b("React").createElement(b("XUIDialogButton.react"),{action:"cancel",label:h._("Got It"),use:"confirm"})))};return c}(b("React").Component);e.exports=a}),null); __d("VideoCopyrightSendReportInputName",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({PAGE_ID:"page_id",NAME:"name",PHONE:"phone",EMAIL:"email",CONFIRM_EMAIL:"confirm_email",ORGANIZATION_NAME:"video_copyright_contact_client",ORGANIZATION_ADDRESS:"video_copyright_contact_address",ORGANIZATION_EMAIL:"video_copyright_contact_email",REPORTER_NAME:"video_copyright_contact_owner",ORGANIZATION_COUNTRY:"video_copyright_contact_country",STATEMENT_AGREE:"statement_agree",ELECTRONIC_SIG:"signature",SAVE_SETTINGS:"save_settings"})}),null); __d("VideoCopyrightSendReportInputRow.react",["InfoTableRow.react","React","XUITextInput.react"],(function(a,b,c,d,e,f){__p&&__p();a=b("React").PropTypes;c=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){var a=this,c={id:this.props.id,placeholder:this.props.placeholder,value:this.props.value,xuiError:this.props.error,disabled:this.props.disabled,onChange:function(b){return a.props.onChange(a.props.id,b.target.value)}};return b("React").createElement(b("InfoTableRow.react"),{type:"data",label:this.props.label,labelFor:this.props.id},this.props.isTextarea?b("React").createElement("textarea",babelHelpers["extends"]({rows:"4"},c)):b("React").createElement(b("XUITextInput.react"),c))};return c}(b("React").Component);c.propTypes={id:a.string.isRequired,value:a.string,error:a.string,onChange:a.func.isRequired,label:a.string.isRequired,placeholder:a.string,isTextarea:a.bool,disabled:a.bool};c.defaultProps={value:"",error:null,placeholder:"",isTextarea:!1,disabled:!1};e.exports=c}),null); __d("MMRMEmailContactSection.react",["cx","fbt","FDSText.react","InfoTable.react","InfoTableSection.react","React","VideoCopyrightSendReportInputName","VideoCopyrightSendReportInputRow.react"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f0){c=c[0];if(c.action===b("VideoCopyrightRuleActionType").BLOCK)return g._("Block Requested");else if(c.action===b("VideoCopyrightRuleActionType").MONETIZE)return g._("Collect ad earnings Requested");else return g._("Action Requested")}if(h.isTrustedPartnerBlockRequested(a))return g._("Block Requested");c=a.expirationInDays;if(h.isFlaggedEntityActionConfirmable(a)||h.isTrustedPartnerBlockConfirmable(a))return g._("Request expires in {number} days",[g._param("number",c)]);if(h.isFlaggedEntityNoActionTaken(a)||h.isTrustedPartnerNoActionTaken(a))return g._("Expires in {number} days",[g._param("number",c)])},isFlaggedEntityMatch:function(a){var c;return a.trustedPartnerInfo!=null&&((c=a.trustedPartnerInfo)!=null?c.is_flagged_entity_match:c)!=null&&b("nullthrows")((c=a.trustedPartnerInfo)!=null?c.is_flagged_entity_match:c)},isFlaggedEntityActionRequested:function(a){return h.isFlaggedEntityMatch(a)&&!h.canConfirmAction(a)&&a.auditLog!=null&&((a=a.auditLog)!=null?(a=a[0])!=null?a.matchState:a:a)===b("VideoCopyrightMatchValidStates").PENDING_CLAIMED},isFlaggedEntityActionConfirmable:function(a){var c;return h.isFlaggedEntityMatch(a)&&h.canConfirmAction(a)&&a.auditLog!=null&&((c=a.auditLog)!=null?(c=c[0])!=null?c.matchState:c:c)===b("VideoCopyrightMatchValidStates").PENDING_CLAIMED&&((c=a.auditLog)!=null?(c=c[0])!=null?c.matchState:c:c)!==b("VideoCopyrightMatchValidStates").VERIFIED_CLAIMED},isFlaggedEntityActionApplied:function(a){var c;c=(c=a.auditLog)!=null?(c=c[0])!=null?c.appliedActions:c:c;return h.isFlaggedEntityMatch(a)&&a.auditLog!=null&&((a=a.auditLog)!=null?(a=a[0])!=null?a.matchState:a:a)===b("VideoCopyrightMatchValidStates").VERIFIED_CLAIMED&&c!=null&&c.find(function(a){return a.action==="MUTE"||a.action==="BLOCK"||a.action==="MONETIZE"})!=null},isFlaggedEntityNoActionTaken:function(a){return h.isFlaggedEntityMatch(a)&&!h.isFlaggedEntityActionConfirmable(a)&&!h.isFlaggedEntityActionRequested(a)&&a.auditLog!=null&&((a=a.auditLog)!=null?(a=a[0])!=null?a.matchState:a:a)===b("VideoCopyrightMatchValidStates").MANUAL_REVIEW}};e.exports=h}),null); __d("VideoCopyrightGeoActionCountrySelector.react",["ix","cx","fbt","invariant","CopyrightCountryNames","CopyrightCountrySearchSource","CopyrightCountrySelectorHeader.react","CopyrightCountrySelectorLabel.react","FDSText.react","Image.react","React","SortedCopyrightCountryCodes","SUIBusinessTheme","SUISearchableSelector.react","Tooltip","VideoCopyrightRuleActionType","XUIButton.react","asset"],(function(a,b,c,d,e,f,g,h,i,j){"use strict";__p&&__p();var k=new(b("CopyrightCountrySearchSource"))();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){__p&&__p();var d;d=a.call(this,c)||this;d.state={countries:[],selectedIncluded:!0};d.$12=function(){d.state.selectedIncluded||d.setState({selectedIncluded:!0})};d.$13=function(){d.state.selectedIncluded&&d.setState({selectedIncluded:!1})};d.$10=function(a){return d.$1.includes(a.getUniqueID())};d.$9=function(a){if(d.$1.includes(a.getUniqueID()))return b("React").createElement("div",{className:"_6eii"},b("React").createElement(b("Image.react"),babelHelpers["extends"]({src:g("493893")},b("Tooltip").propsFor(i._("You don't own the rights to this video in this country. You can always edit the ownership settings of your reference file."),"right"))));return d.$2.includes(a.getUniqueID())?b("React").createElement("div",{className:"_6eii"},b("React").createElement(b("Image.react"),babelHelpers["extends"]({src:g("597744")},b("Tooltip").propsFor(i._("You're collecting ad earnings in this country. You won't be able to collect ad earnings in this country anymore if you block the video."),"right")))):null};d.$8=function(a){var b=d.state.countries.slice(0),c=b.find(function(b){return b.getUniqueID()===a.getUniqueID()});c=b.indexOf(c);c>=0?b.splice(c,1):b.push(a);return d.setCountries(b)};d.$6=function(a){a.stopPropagation(),d.setCountries([])};d.$7=function(a){a.stopPropagation(),d.setCountries(k.getAllValidCountriesFromInvalid(d.$1))};d.$1=d.$3();d.$2=d.$4();return d}var d=c.prototype;d.componentDidMount=function(){this.setState({countries:this.$5()})};d.render=function(){var a=!1;this.props.isDisabled&&(a=!0);return b("React").createElement("div",{className:"_6eij"},b("React").createElement(b("SUISearchableSelector.react"),{isDisabled:a,canSelectMultiple:!0,customLabel:b("React").createElement(b("CopyrightCountrySelectorLabel.react"),{countryCount:this.state.countries.length}),dropdownWidth:"auto",emptySearchResultsContent:i._("No matching results"),header:b("React").createElement(b("CopyrightCountrySelectorHeader.react"),{countryCount:this.state.countries.length,onDeselectAll:this.$6,onSelectAll:this.$7}),onChange:this.$8,placeholder:i._("Select countries"),searchPlaceholder:i._("Search countries"),getRightContentForEntry:this.$9,getDisableStateForEntry:this.$10,searchSource:k,theme:b("SUIBusinessTheme"),values:this.state.countries}),this.$11())};d.$11=function(){var a=this.state.countries.map(function(a){return a.getUniqueID()});this.state.selectedIncluded?a=b("SortedCopyrightCountryCodes").filter(function(b){return a.indexOf(b)!==-1}):a=b("SortedCopyrightCountryCodes").filter(function(b){return a.indexOf(b)===-1});return b("React").createElement("div",{className:"_6ex4"},b("React").createElement("div",{className:"_6ex6"},b("React").createElement("span",null,b("React").createElement(b("XUIButton.react"),{className:(this.state.selectedIncluded?"":"_6ex7")+" _6ex8 _6ex9",onClick:this.$12,label:i._("Included"),use:"default"})),b("React").createElement("span",null,b("React").createElement(b("XUIButton.react"),{className:(this.state.selectedIncluded?"_6ex7":"")+" _6ex8",onClick:this.$13,label:i._("Not Included"),use:"default"}))),b("React").createElement("div",{className:this.props.countryInfoClassName},b("React").createElement(b("FDSText.react"),{size:"body3",color:"placeholder"},a.map(function(a){return b("CopyrightCountryNames")[a]}).join(", "))))};d.$14=function(a){var b=a.map(function(a){return a.getUniqueID()}),c=this.$2.filter(function(a){return b.indexOf(a)!==-1});c&&c.length>0?this.props.onChange(!0,a.length!==0,b):this.props.onChange(!1,a.length!==0,b)};d.setCountries=function(a){this.setState({countries:a.slice()},this.$14(a))};d.$3=function(){var a=this.$15(this.props.ownershipGeoGate);return b("SortedCopyrightCountryCodes").filter(function(b){return a.indexOf(b)===-1})};d.$4=function(){if(this.props.appliedActions){var a=this.props.appliedActions.filter(function(a){return a.action===b("VideoCopyrightRuleActionType").MONETIZE});a=a[0];if(a)return this.$15(a.geos)}return[]};d.$15=function(a){__p&&__p();if(!a)return[];if(a.included_countries&&a.included_countries.length>0)return a.included_countries;else if(a.excluded_countries&&a.excluded_countries.length>0){var c=a.excluded_countries;c&&c.length>0||j(0,585);return b("SortedCopyrightCountryCodes").filter(function(a){return c.indexOf(a)==-1})}else return b("SortedCopyrightCountryCodes")};d.$5=function(){if(this.props.geoGate){var a=this.$15(this.props.geoGate);return k.getAllValidCountriesFromValid(a)}return k.getAllValidCountriesFromInvalid(this.$1)};d.getActionGeoGate=function(){var a=this.state.countries.map(function(a){return a.getUniqueID()});if(a.length===0)return null;else return{included_countries:a}};d.getHasAdsEarningAlert=function(){var a=this.$4(),b=this.$15(this.props.ownershipGeoGate);this.props.geoGate&&(b=this.$15(this.props.geoGate));a=a.filter(function(a){return b.indexOf(a)!==-1});return a&&a.length>0};return c}(b("React").Component);a.defaultProps={countryInfoClassName:"_6exa"};e.exports=a}),null); __d("VideoCopyrightGeoActionReasonSelector.react",["cx","fbt","FDSText.react","React","SUIBusinessTheme","SUISelector.react","SUISelectorOption.react","SUITooltip.react","VideoCopyrightUtils"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f0?(d=c.props.geoGate.included_countries,e=l.VIEWER_LOCATION,f=m.INCLUDE,c.$4=!0):c.props.geoGate.excluded_countries&&c.props.geoGate.excluded_countries.length>0?(d=c.props.geoGate.excluded_countries,e=l.VIEWER_LOCATION,f=m.EXCLUDE,c.$4=!0):(d=[],e=c.$3?l.WORLDWIDE:l.VIEWER_LOCATION,f=m.INCLUDE,c.$4=!0);c.state={selectedCountries:d,searchSource:new(b("VideoCopyrightGeoActionSearchSource"))(c.$1),selectedGeoOption:e,selectedGatingOption:f};return c}var d=c.prototype;d.componentDidMount=function(){this.props.onInputValidation(this.areCountriesInvalid())};d.componentDidUpdate=function(a,b){(b.selectedGeoOption!==this.state.selectedGeoOption||b.selectedGatingOption!==this.state.selectedGatingOption||b.selectedCountries.length!==this.state.selectedCountries.length)&&(this.setState({ownershipError:this.$6()}),this.props.onChange(this.state.selectedGeoOption===l.WORLDWIDE,this.state.selectedGatingOption===m.INCLUDE,this.state.selectedCountries)),this.props.onInputValidation(this.areCountriesInvalid())};d.$5=function(){__p&&__p();if(!this.props.ownershipGeoGate)this.$1=Object.keys(b("CopyrightCountryNames")),this.$2=[],this.$3=!0;else if(this.props.ownershipGeoGate.included_countries&&this.props.ownershipGeoGate.included_countries.length>0){var a=this.props.ownershipGeoGate.included_countries;a&&a.length>0||i(0,584);this.$1=a;this.$2=Object.keys(b("CopyrightCountryNames")).filter(function(b){return a.indexOf(b)==-1});this.$3=!1}else if(this.props.ownershipGeoGate.excluded_countries&&this.props.ownershipGeoGate.excluded_countries.length>0){var c=this.props.ownershipGeoGate.excluded_countries;c&&c.length>0||i(0,585);this.$1=Object.keys(b("CopyrightCountryNames")).filter(function(a){return c.indexOf(a)==-1});this.$2=c;this.$3=!1}else this.$1=Object.keys(b("CopyrightCountryNames")),this.$2=[],this.$3=!0};d.$7=function(a){this.setState({selectedGeoOption:a})};d.$8=function(a){this.setState({selectedGatingOption:a.value})};d.$9=function(a){this.setState({selectedCountries:a})};d.$10=function(){return this.state.selectedGeoOption!==l.VIEWER_LOCATION?null:b("React").createElement(b("PolicyRuleTokenizedTypeahead.react"),{className:"_40k7",name:"typeahead",onEntriesUpdated:this.$9.bind(this),placeholder:h._("Choose countries"),searchSource:this.state.selectedGatingOption===m.INCLUDE?this.state.searchSource:n,searchSourceLabels:b("CopyrightCountryNames"),value:this.state.selectedCountries.slice(),error:this.state.ownershipError})};d.addAllValidCountries=function(){var a=this.props.ownershipGeoGate;if(this.$3||a==null)this.setState({selectedGeoOption:l.WORLDWIDE});else{var b=a.included_countries&&a.included_countries.length>0;this.setState({selectedGeoOption:l.VIEWER_LOCATION,selectedGatingOption:b?m.INCLUDE:m.EXCLUDE,selectedCountries:b?a.included_countries||[]:a.excluded_countries||[]})}};d.clearSelectedCountries=function(){this.setState({selectedCountries:[],selectedGeoOption:l.VIEWER_LOCATION,selectedGatingOption:m.INCLUDE})};d.getActionGeoGate=function(){if(this.state.selectedGeoOption===l.WORLDWIDE)return{included_countries:[],excluded_countries:[]};else if(this.state.selectedGatingOption===m.EXCLUDE)return{excluded_countries:this.state.selectedCountries};else if(this.state.selectedCountries.length===0)return null;else return{included_countries:this.state.selectedCountries}};d.areCountriesInvalid=function(){var a=this.state.selectedGeoOption!==l.WORLDWIDE&&this.state.selectedCountries.length===0,b=a&&this.state.selectedGatingOption===m.INCLUDE&&this.$4,c=this.state.ownershipError!=null;return a&&!b||c};d.$6=function(){__p&&__p();if(this.state.selectedGeoOption===l.WORLDWIDE)return null;if(this.state.selectedGatingOption===m.INCLUDE&&this.state.selectedCountries.length>0){var a=new(b("StrSet"))(this.$1),c=new(b("StrSet"))(this.state.selectedCountries);a=a.difference(c);if(a.count()>0)return this.$11(a.toArray())}else if(this.state.selectedGatingOption===m.EXCLUDE&&this.state.selectedCountries.length>0){c=new(b("StrSet"))(this.$2);a=new(b("StrSet"))(this.state.selectedCountries);a=a.difference(c);if(a.count()>0)return this.$11(a.toArray())}return null};d.$11=function(a){var c=Math.min(a.length,this.$1.length,this.$2.length);if(c===a.length)return h._("You do not have the rights to this content in the following countries: {List of countries}",[h._param("List of countries",a.map(function(a){return b("CopyrightCountryNames")[a]}).join(", "))]);else if(c===this.$1.length)return h._("You only have the rights to this content in the following countries: {List of countries}",[h._param("List of countries",this.$1.map(function(a){return b("CopyrightCountryNames")[a]}).join(", "))]);else return h._("You do not have the rights to this content in the following countries: {List of countries}",[h._param("List of countries",this.$2.map(function(a){return b("CopyrightCountryNames")[a]}).join(", "))])};d.render=function(){return b("React").createElement("div",{className:b("joinClasses")(this.props.className,"_40k8")},b("React").createElement(b("XUIRadioList.react"),{className:"_40k9",selectedValue:this.state.selectedGeoOption,onValueChange:this.$7.bind(this)},b("React").createElement(j,{className:"_40ka",disabled:this.props.disabled||!this.$3,value:l.WORLDWIDE},h._("Worldwide")),b("React").createElement(j,{className:"_40ka",disabled:this.props.disabled,value:l.VIEWER_LOCATION},h._("Viewer Location"),b("React").createElement(b("XUISingleSelector.react"),{name:"inclusion_selector",className:"_40kb",disabled:this.props.disabled||this.state.selectedGeoOption!==l.VIEWER_LOCATION,onChange:this.$8.bind(this),value:this.state.selectedGatingOption},b("React").createElement(k,{value:m.INCLUDE},h._("Is")),b("React").createElement(k,{value:m.EXCLUDE},h._("Is Not"))))),this.$10())};return c}(b("React").Component);a.defaultProps={onInputValidation:b("emptyFunction")};e.exports=a}),null); __d("VideoCopyrightGeoActionDialog.react",["cx","fbt","CopyrightCountryNames","FDSButton.react","FDSText.react","InfoTable.react","InfoTableRow.react","InfoTableSection.react","LayerFadeOnHide","LayerHideOnEscape","MMRMEmailContactSection.react","MMRMTrustedPartnerController","React","StrSet","VideoCopyrightGeoActionCountrySelector.react","VideoCopyrightGeoActionReasonSelector.react","VideoCopyrightGeoActionSelector.react","VideoCopyrightRuleActionType","VideoCopyrightSendReportInputName","VideoCopyrightSettingsUtil","XUIDialog.react","XUIDialogBody.react","XUIDialogButton.react","XUIDialogFooter.react","XUIDialogTitle.react","XUINotice.react","XUIText.react","cxMargin"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(b){__p&&__p();var c;c=a.call(this,b)||this;c.$7=function(a){c.setState({email:a})};c.$28=function(){c.setState({shown:!1})};var d=b.appliedActions&&b.appliedActions.find(function(a){return a.action===c.props.action}),e;d&&(e=d.geos);b.isMMRM&&b.ownershipGeoGate!=null&&(e=b.ownershipGeoGate);c.state={actionGeoGate:e,shouldDisableSubmitButton:!0,businessPageReasonSelected:!1,businessPageCountrySelected:!0,alert:null,shown:!0,email:""};return c}var d=c.prototype;d.componentDidMount=function(){this.$1()};d.$2=function(){return b("React").createElement("div",null,h._("This video belongs to a trusted partner and will be reviewed before it's blocked. You'll be notified after 3 business days when you can confirm your action."))};d.$3=function(){return b("React").createElement("div",null,h._("This video will be reviewed before the action is taken. You'll be notified after 3 business days when you can confirm your action."))};d.$4=function(){var a=b("React").createElement(b("FDSText.react"),{weight:"bold"},h._("Reason")),c=b("React").createElement(b("FDSText.react"),{weight:"bold"},h._("Location"));return b("React").createElement(b("InfoTable.react"),{className:"_7lzt"},b("React").createElement(b("InfoTableSection.react"),null,this.props.showReason!=null&&this.props.showReason?b("React").createElement(b("InfoTableRow.react"),{label:a},b("React").createElement(b("VideoCopyrightGeoActionReasonSelector.react"),{isMMRM:this.props.isMMRM,rmVersion:this.props.rmVersion,ref:"geoActionReasonSelector",onInputValidation:this.$5.bind(this)})):null,b("React").createElement(b("InfoTableRow.react"),{label:c},b("React").createElement(b("VideoCopyrightGeoActionCountrySelector.react"),{ref:"geoActionSelector",appliedActions:this.props.appliedActions,geoGate:this.state.actionGeoGate,ownershipGeoGate:this.props.ownershipGeoGate,onChange:this.$6.bind(this)}))))};d.$8=function(){var a=this.props.isMMRM;if(a!=null&&a){a=this.props.contactInfo;if(a!=null)return b("React").createElement(b("MMRMEmailContactSection.react"),{contactInfo:a,onInputChange:this.$7})}return null};d.$9=function(){return b("React").createElement(b("XUIDialogFooter.react"),{className:"_zx3"},this.$10())};d.$11=function(){var a=this.props,c=a.match;a=a.action;if(c!=null&&b("MMRMTrustedPartnerController").isFlaggedEntityMatch(c)&&[b("VideoCopyrightRuleActionType").BLOCK,b("VideoCopyrightRuleActionType").MONETIZE].includes(a))return b("React").createElement(b("XUIDialogBody.react"),null,b("React").createElement("div",{className:"_7ppm"},this.$3(),this.$4(),this.$8()));else if(c!=null&&b("MMRMTrustedPartnerController").isTrustedPartner(c)&&a===b("VideoCopyrightRuleActionType").BLOCK)return b("React").createElement(b("XUIDialogBody.react"),null,b("React").createElement("div",{className:"_7ppm"},this.$2(),this.$4(),this.$8()));else if(c!=null)return b("React").createElement(b("XUIDialogBody.react"),null,b("React").createElement("div",null,this.$4()));return null};d.$12=function(){var a=this.props,c=a.match;a=a.action;if(c!=null&&b("MMRMTrustedPartnerController").isFlaggedEntityMatch(c)&&[b("VideoCopyrightRuleActionType").BLOCK,b("VideoCopyrightRuleActionType").MONETIZE].includes(a))return b("React").createElement(b("XUIDialogTitle.react"),null,a===b("VideoCopyrightRuleActionType").BLOCK?h._("Request a block?"):h._("Request to collect ad earnings?"));else if(c!=null&&b("MMRMTrustedPartnerController").isTrustedPartner(c)&&a===b("VideoCopyrightRuleActionType").BLOCK)return b("React").createElement(b("XUIDialogTitle.react"),null,h._("Request a block?"));else return b("React").createElement(b("XUIDialogTitle.react"),null,h._({"Block":"Block by Viewer Location","Collect Ad Earnings":"Collect Ad Earnings by Viewer Location","Monitor":"Monitor by Viewer Location"},[h._enum(this.$13(),{Block:"Block","Collect Ad Earnings":"Collect Ad Earnings",Monitor:"Monitor"})]))};d.render=function(){var a=this.props.isMMRM;if(a!=null&&a)return b("React").createElement(b("XUIDialog.react"),{behaviors:{LayerHideOnEscape:b("LayerHideOnEscape"),LayerFadeOnHide:b("LayerFadeOnHide")},ref:"geoActionDialog",shown:this.state.shown,height:557,width:640},this.$12(),this.$11(),this.$9());else if(this.props.useBusinessPageDialog&&this.props.action===b("VideoCopyrightRuleActionType").BLOCK)return b("React").createElement(b("XUIDialog.react"),{behaviors:{LayerHideOnEscape:b("LayerHideOnEscape"),LayerFadeOnHide:b("LayerFadeOnHide")},ref:"geoActionDialog",shown:!0,width:560},b("React").createElement(b("XUIDialogTitle.react"),null,h._({"Block":"Block by Viewer Location","Collect Ad Earnings":"Collect Ad Earnings by Viewer Location","Monitor":"Monitor by Viewer Location"},[h._enum(this.$13(),{Block:"Block","Collect Ad Earnings":"Collect Ad Earnings",Monitor:"Monitor"})])),b("React").createElement(b("XUIDialogBody.react"),null,b("React").createElement("div",{className:"_6dp5"},b("React").createElement("span",{className:"_6eif"},b("React").createElement(b("XUIText.react"),null,h._("Why are you blocking this video?"))),b("React").createElement("span",{className:"_6eig"},b("React").createElement(b("VideoCopyrightGeoActionReasonSelector.react"),{isMMRM:this.props.isMMRM,ref:"geoActionReasonSelector",onInputValidation:this.$5.bind(this)}))),b("React").createElement("div",{className:"_6eih"},b("React").createElement("span",{className:"_6eif"},b("React").createElement(b("XUIText.react"),null,h._({"block":"Where do you want to block this video:","claim ad earnings for":"Where do you want to claim ad earnings for this video:","monitor":"Where do you want to monitor this video:"},[h._enum(this.$14(),{block:"block","claim ad earnings for":"claim ad earnings for",monitor:"monitor"})]))),b("React").createElement("span",{className:"_6eig"},b("React").createElement(b("VideoCopyrightGeoActionCountrySelector.react"),{ref:"geoActionSelector",appliedActions:this.props.appliedActions,geoGate:this.state.actionGeoGate,ownershipGeoGate:this.props.ownershipGeoGate,onChange:this.$6.bind(this)}))),this.$15()),b("React").createElement(b("XUIDialogFooter.react"),{className:"_zx3"},this.$10()));return b("React").createElement(b("XUIDialog.react"),{behaviors:{LayerHideOnEscape:b("LayerHideOnEscape"),LayerFadeOnHide:b("LayerFadeOnHide")},ref:"geoActionDialog",shown:!0,width:508},b("React").createElement(b("XUIDialogTitle.react"),null,h._({"Block":"Block by Viewer Location","Collect Ad Earnings":"Collect Ad Earnings by Viewer Location","Monitor":"Monitor by Viewer Location"},[h._enum(this.$13(),{Block:"Block","Collect Ad Earnings":"Collect Ad Earnings",Monitor:"Monitor"})])),b("React").createElement(b("XUIDialogBody.react"),null,h._({"block":"Choose where you want to block this video:","claim ad earnings for":"Choose where you want to claim ad earnings for this video:","monitor":"Choose where you want to monitor this video:"},[h._enum(this.$14(),{block:"block","claim ad earnings for":"claim ad earnings for",monitor:"monitor"})]),b("React").createElement(b("VideoCopyrightGeoActionSelector.react"),{ref:"geoActionSelector",geoGate:this.state.actionGeoGate,ownershipGeoGate:this.props.ownershipGeoGate,onInputValidation:this.$16.bind(this),onChange:this.$17.bind(this)}),this.$18()),b("React").createElement(b("XUIDialogFooter.react"),{className:"_zx3",leftContent:this.$19()},this.$10()))};d.$17=function(a,b,c){__p&&__p();var d=this;if(!a&&b&&c.length===0){var e=this.props.appliedActions&&this.props.appliedActions.filter(function(a){return a.action===d.props.action});if(e&&e.length>0){this.setState({alert:h._({"block":"You are removing your action to block this video.","claim ad earnings for":"You are removing your action to claim ad earnings for this video.","monitor":"You are removing your action to monitor this video."},[h._enum(this.$14(),{block:"block","claim ad earnings for":"claim ad earnings for",monitor:"monitor"})])});return}}else{e=this.props.appliedActions&&this.props.appliedActions.filter(function(a){return a.action!==d.props.action});if(e&&e.length>0){a?a=!0:a=this.$20(c,b,e);if(a){this.setState({alert:h._({"Block":{"block":"You are already performing another action in some of your selected countries. Select \"Block\" if you want to block this video in these countries instead.","claim ad earnings for":"You are already performing another action in some of your selected countries. Select \"Block\" if you want to claim ad earnings for this video in these countries instead.","monitor":"You are already performing another action in some of your selected countries. Select \"Block\" if you want to monitor this video in these countries instead."},"Collect Ad Earnings":{"block":"You are already performing another action in some of your selected countries. Select \"Collect Ad Earnings\" if you want to block this video in these countries instead.","claim ad earnings for":"You are already performing another action in some of your selected countries. Select \"Collect Ad Earnings\" if you want to claim ad earnings for this video in these countries instead.","monitor":"You are already performing another action in some of your selected countries. Select \"Collect Ad Earnings\" if you want to monitor this video in these countries instead."},"Monitor":{"block":"You are already performing another action in some of your selected countries. Select \"Monitor\" if you want to block this video in these countries instead.","claim ad earnings for":"You are already performing another action in some of your selected countries. Select \"Monitor\" if you want to claim ad earnings for this video in these countries instead.","monitor":"You are already performing another action in some of your selected countries. Select \"Monitor\" if you want to monitor this video in these countries instead."}},[h._enum(this.$13(),{Block:"Block","Collect Ad Earnings":"Collect Ad Earnings",Monitor:"Monitor"}),h._enum(this.$14(),{block:"block","claim ad earnings for":"claim ad earnings for",monitor:"monitor"})])});return}}}this.setState({alert:null})};d.$6=function(a,b){a&&this.state.alert===null?this.setState({alert:this.$21(!0)}):!a&&this.state.alert!==null&&this.setState({alert:this.$21(!1)}),b!==this.state.businessPageCountrySelected&&this.setState({businessPageCountrySelected:b}),b&&this.state.businessPageReasonSelected&&this.state.shouldDisableSubmitButton?this.setState({shouldDisableSubmitButton:!1}):!b&&!this.state.shouldDisableSubmitButton&&this.setState({shouldDisableSubmitButton:!0})};d.$20=function(a,b,c){__p&&__p();var d=this,e=this.$22(a,b);a=!1;c.forEach(function(b){__p&&__p();b=b.geos;var c;if(!(b&&b.included_countries&&b.included_countries.length)&&!(b&&b.excluded_countries&&b.excluded_countries.length)){a=!0;return}else b.included_countries&&b.included_countries.length?c=d.$22(b.included_countries,!0):b.excluded_countries&&b.excluded_countries.length&&(c=d.$22(b.excluded_countries,!1));if(c&&c.intersect(e).count()>0){a=!0;return}});return a};d.$22=function(a,c){if(c)return new(b("StrSet"))(a);else return new(b("StrSet"))(Object.keys(b("CopyrightCountryNames")).filter(function(b){return a.indexOf(b)==-1}))};d.$13=function(){switch(this.props.action){case b("VideoCopyrightRuleActionType").BLOCK:return"Block";case b("VideoCopyrightRuleActionType").MONETIZE:return"Collect Ad Earnings";case b("VideoCopyrightRuleActionType").TRACK:return"Monitor";default:throw new Error("Invalid action")}};d.$14=function(){switch(this.props.action){case b("VideoCopyrightRuleActionType").BLOCK:return"block";case b("VideoCopyrightRuleActionType").MONETIZE:return"claim ad earnings for";case b("VideoCopyrightRuleActionType").TRACK:return"monitor";default:throw new Error("Invalid action")}};d.$18=function(){return this.state.alert==null||this.state.shouldDisableSubmitButton?null:b("React").createElement(b("XUINotice.react"),{className:"_3zlf"},this.state.alert)};d.$15=function(){return this.state.alert==null?null:b("React").createElement(b("XUINotice.react"),{use:"recommend",className:"_3-8y"},this.state.alert)};d.$23=function(){return h._({"Block":"Block","Collect Ad Earnings":"Collect Ad Earnings","Monitor":"Monitor"},[h._enum(this.$13(),{Block:"Block","Collect Ad Earnings":"Collect Ad Earnings",Monitor:"Monitor"})])};d.$24=function(){this.refs.geoActionSelector.addAllValidCountries()};d.$25=function(){this.refs.geoActionSelector.clearSelectedCountries()};d.$26=function(){__p&&__p();var a=this,c=this.refs.geoActionSelector.getActionGeoGate(),d=this.props.useBusinessPageDialog||this.props.isMMRM&&this.props.showReason!=null&&this.props.showReason?this.refs.geoActionReasonSelector.getActionReason():null;this.refs.geoReasonSelector;var e=(this.props.appliedActions||[]).filter(function(b){return b.action!==a.props.action});c!==null&&((c.included_countries||[]).length==0&&(c.excluded_countries||[]).length===0?e=[{action:this.props.action,geos:c}]:(e=this.$27(e,c),e.push({action:this.props.action,geos:c})));if(this.state.email!==""&&this.props.isMMRM!=null&&this.props.isMMRM){c=this.props;var f=c.contactInfo;c=c.page;if(c!=null&&f!=null){f[b("VideoCopyrightSendReportInputName").ORGANIZATION_EMAIL]=this.state.email;b("VideoCopyrightSettingsUtil").updateContactInfo(c.id,f,function(){return a.props.onSubmit(e,d)});return}}this.props.onSubmit(e,d)};d.$27=function(a,c){__p&&__p();var d=this,e=[],f=!!c.included_countries&&c.included_countries.length>0,g=(f?c.included_countries:c.excluded_countries)||[];a.forEach(function(a){__p&&__p();var c=d.$20(g,f,[a]);if(c){c=a.geos;if(!c||!((c.included_countries||[]).length>0||(c.excluded_countries||[]).length>0))f?c={excluded_countries:g}:c={included_countries:g};else{var h=!!c.included_countries&&c.included_countries.length>0,i=(h?c.included_countries:c.excluded_countries)||[],j=d.$22(g,f);i=d.$22(i,h);h=j.difference(i);if(h.count()===0)return;else{j=Object.keys(b("CopyrightCountryNames")).length;var k=h.toArray();k.length>j/2?c={excluded_countries:Object.keys(b("CopyrightCountryNames")).filter(function(a){return k.indexOf(a)==-1})}:c={included_countries:k}}}e.push({action:a.action,geos:c})}else e.push(a)});return e};d.$19=function(){return b("React").createElement("div",null,b("React").createElement(b("XUIDialogButton.react"),{className:"_3-90",onClick:this.$24.bind(this),label:h._("Add All"),use:"default"}),b("React").createElement(b("XUIDialogButton.react"),{className:"_3-90",label:h._("Clear"),onClick:this.$25.bind(this),use:"default"}))};d.$16=function(a){a!==this.state.shouldDisableSubmitButton&&this.setState({shouldDisableSubmitButton:a})};d.$5=function(a){a!==this.state.businessPageReasonSelected&&this.setState({businessPageReasonSelected:a}),a&&this.state.businessPageCountrySelected&&this.state.shouldDisableSubmitButton?this.setState({shouldDisableSubmitButton:!1}):!a&&!this.state.shouldDisableSubmitButton&&this.setState({shouldDisableSubmitButton:!0})};d.$29=function(){return Boolean(this.props.showReason)&&this.state.shouldDisableSubmitButton&&this.props.action!==b("VideoCopyrightRuleActionType").TRACK};d.$10=function(){return this.props.isMMRM?b("React").createElement("div",null,b("React").createElement("span",{className:"_3-90"},b("React").createElement(b("FDSButton.react"),{label:h._("Cancel"),size:"large",onClick:this.$28})),b("React").createElement(b("FDSButton.react"),{autoFocus:this.props.isMMRM,isDisabled:this.$29(),label:h._("Submit"),onClick:this.$26.bind(this),size:"large",use:"primary"})):b("React").createElement("div",null,b("React").createElement(b("XUIDialogButton.react"),{action:"cancel",className:"_3-90",label:b("React").createElement("fbtc",null,"Cancel"),use:"default"}),b("React").createElement(b("XUIDialogButton.react"),{action:"confirm",disabled:this.state.shouldDisableSubmitButton,label:this.$23(),onClick:this.$26.bind(this),use:"confirm"}))};d.$21=function(a){return!a?null:h._("You've selected countries where you're claiming ad earnings on this video. You won't be able to claim ad earnings in these countries anymore if you block the video.")};d.$1=function(){if(!this.props.useBusinessPageDialog||!this.props.action===b("VideoCopyrightRuleActionType").BLOCK)return;var a=this.refs.geoActionSelector.getHasAdsEarningAlert();(a&&this.state.alert===null||!a&&this.state.alert!==null)&&this.setState({alert:this.$21(a)})};return c}(b("React").Component);e.exports=a}),null); __d("VideoCopyrightTPBlockConfirmationDialog.react",["cx","fbt","React","VideoCopyrightRuleActionType","VideoCopyrightSendReportInputName","VideoCopyrightSettingsUtil","XUIDialog.react","XUIDialogBody.react","XUIDialogButton.react","XUIDialogFooter.react","XUIDialogTitle.react","XUINotice.react","XUITextInput.react","cxMargin"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var c,d;for(var e=arguments.length,f=new Array(e),g=0;g1?" ("+a+")":null;return g._("Unblock {Post count}",[g._param("Post count",b)])},isAvailable:function(a,c,d){return a.every(function(a){return a&&(a.match_status||a.status)===b("VideoCopyrightMatchStatus").BLOCKED})},key:b("VideoCopyrightMatchActionTypes").UNBLOCK,onClick:function(a,c){var d=a.length>1?g._("You're Unblocking These Videos"):g._("You're Unblocking This Video"),e=a.length>1?g._("If you unblock these videos you'll allow them to be posted on Facebook. You will no longer be able to access them in Rights Manager."):g._("If you unblock this video you'll allow it to be posted on Facebook. You will no longer be able to access it in Rights Manager."),f=g._({"*":"Unblock Videos","_1":"Unblock Video"},[g._plural(a.length)]);b("PageContentTabCommonConfig").showConfirmationDialog(d,e,f,function(){b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").UNBLOCK,c)},null)}},MONETIZE:{allowBatch:!1,isDisabled:function(a,b){b=a.filter(function(a){return a.matchedVideoAsset.liveStatus===0||!a.matchedVideoAsset.containsAdBreaks});return b.length!==0},isAvailable:function(a,c,d){if(!d.can_see_rights_manager_monetization_action)return!1;c=a[0];return c&&(c.match_status||c.status)!==b("VideoCopyrightMatchStatus").CLAIMED||d.copyright_geo_actions_enabled},getLabel:function(a,b,c){return g._("Claim ad earnings")},key:b("VideoCopyrightMatchActionTypes").MONETIZE,onClick:function(a,c){__p&&__p();var d=b("DOM").create("div"),e=function(e){b("promiseDone")(b("PageContentTabVideosCopyrightActions").updateAppliedActions(a,e,c)),b("ReactDOM").unmountComponentAtNode(d)},f=function(){if(c.copyright_geo_actions_enabled){var f=a[0];b("ReactDOM").render(b("React").createElement(b("VideoCopyrightGeoActionDialog.react"),{action:b("VideoCopyrightRuleActionType").MONETIZE,appliedActions:f.applied_actions,ownershipGeoGate:f.ownership_countries,onSubmit:e}),d)}else b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").MONETIZE,c)};c.show_claim_ad_earning_dialog_nux?b("ReactDOM").render(b("React").createElement(b("VideoCopyrightClaimAdEarningsNUXDialog.react"),{pageID:c.page_id,onToggle:function(){var a=b("XBasicFBNuxDismissController").getURIBuilder().setInt("nux_id",4598).getURI();new(b("AsyncRequest"))().setURI(a).send();c.show_claim_ad_earning_dialog_nux=!1;f()}}),b("DOM").create("div")):c.is_copyright_monetization_onboarded?f():b("ReactDOM").render(b("React").createElement(b("VideoCopyrightClaimAdEarningsConfirmationDialog.react"),{pageID:c.page_id}),b("DOM").create("div"))}},TRACK:{allowBatch:!0,isAvailable:function(a,c,d){if(d.show_attributions_tab&&!b("PageContentTabRightsManagerStore").getIsRMLite())return!0;c=a[0];return c&&(c.match_status||c.status)!==b("VideoCopyrightMatchStatus").MONITORED},getLabel:function(a,b,c){return a>1?g._("Monitor match {Post count}",[g._param("Post count",a)]):g._("Monitor")},key:b("VideoCopyrightMatchActionTypes").TRACK,onClick:function(a,c){if(c.show_attributions_tab&&!b("PageContentTabRightsManagerStore").getIsRMLite()&&a.length===1){var d=b("DOM").create("div"),e=function(e){b("promiseDone")(b("PageContentTabVideosCopyrightActions").updateAppliedActions(a,e,c)),b("ReactDOM").unmountComponentAtNode(d)},f=a[0];b("ReactDOM").render(b("React").createElement(b("VideoCopyrightGeoActionDialog.react"),{action:b("VideoCopyrightRuleActionType").TRACK,appliedActions:f.applied_actions,onSubmit:e,ownershipGeoGate:f.ownership_countries}),d)}else b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").TRACK,c)}},WHITELIST_PAGE:{allowBatch:!1,isAvailable:function(a,b,c){return c.can_see_rights_manager_whitelist_page_action},getLabel:function(a,b,c){return g._("Give permission...")},key:b("VideoCopyrightMatchActionTypes").WHITELIST_PAGE,onClick:function(a,c){var d=a[0];a=g._("Give this page permission to upload your content?");var e=g._("Rights Manager won't detect any of this Page's content that matches your reference files. You can always change these permissions in your Page settings.");b("PageContentTabCommonConfig").showConfirmationDialog(a,e,g._("Give Permission"),function(){b("PageContentTabVideosCopyrightActions").addMatchOwnerToWhitelist(d,b("VideoCopyrightMatchActionTypes").WHITELIST_PAGE,c)},null)}},SET_SEEN_STATUS:{allowBatch:!0,isAvailable:function(a,c,d){c=a[0];if(b("PageContentTabRightsManagerStore").getIsRMLite())return c&&(c.match_status||c.status)===b("VideoCopyrightMatchStatus").MONITORED;else return c&&(c.match_status||c.status)===b("VideoCopyrightMatchStatus").MANUAL_REVIEW},getLabel:function(a,c,d){d=b("VideoCopyrightUtils").isMajorityUnseen(c);c=a>1?"("+a+")":null;return d?g._("Mark as seen {Post count}",[g._param("Post count",c)]):g._("Mark as unseen {Post count}",[g._param("Post count",c)])},key:b("VideoCopyrightMatchActionTypes").SET_SEEN_STATUS,onClick:function(a,c){var d=b("VideoCopyrightUtils").isMajorityUnseen(a);d?b("PageContentTabVideosCopyrightActions").setMatchSeen(a,c):b("PageContentTabVideosCopyrightActions").setMatchUnseen(a,c)}},WRONG_MATCH:{allowBatch:!1,getLabel:function(a,b,c){return g._("Content doesn't match")},isAvailable:function(a,c,d){return!b("PageContentTabRightsManagerStore").getIsRMLite()},key:b("VideoCopyrightMatchActionTypes").WRONG_MATCH,onClick:function(a,c){a.length===1||h(0,2066);var d=document.createElement("div"),e=b("ReactDOM").render(b("React").createElement(b("PageContentTabVideosCopyrightMatchErrorDialog.react"),{onSave:function(d,f){return b("promiseDone")(b("PageContentTabVideosCopyrightActions").reportMatchError(a,c,d,f),function(){e.showSuccessMessage()})}}),d)}},REMOVE_FROM_ALLOWED:{allowBatch:!0,isAvailable:function(a){a=a[0];return a&&(a.match_status||a.status)===b("VideoCopyrightMatchStatus").ALLOWED},getLabel:function(a,b,c){b=a>1?"("+a+")":null;return g._("Move to New Matches {Post count}",[g._param("Post count",b)])},key:b("VideoCopyrightMatchActionTypes").REMOVE_FROM_ALLOWED,onClick:function(a,c){b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").REMOVE_FROM_ALLOWED,c)}},REMOVE_FROM_DASHBOARD:{allowBatch:!0,allowBulkSelection:!0,getLabel:function(a,b,c){b=a>1?"("+a+")":null;return c&&c.can_see_sound_recordings_tab?g._("Release claim {Post count}",[g._param("Post count",b)]):g._("Remove from matching videos {Post count}",[g._param("Post count",b)])},key:b("VideoCopyrightMatchActionTypes").REMOVE_FROM_DASHBOARD,createConfirmationTitle:function(a){a=g._({"Match?":"Delete Match?","Matches?":"Delete Matches?"},[g._enum(a===1?"Match?":"Matches?",{"Match?":"Match?","Matches?":"Matches?"})]);return a},createConfirmationBody:function(a){a=a===1?g._("This match will be permanently removed from your dashboard."):g._("{num posts} matches will be permanently removed from your dashboard.",[g._param("num posts",a)]);return a},onClick:function(a,c){var d=this.createConfirmationBody(a.length),e=this.createConfirmationTitle(a.length);b("PageContentTabCommonConfig").showConfirmationDialog(e,d,g._("Delete"),function(){b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").REMOVE_FROM_DASHBOARD,c)},null)},onClickWithBulkSelection:function(a,c,d,e){var f=this.createConfirmationBody(c),h=this.createConfirmationTitle(c);b("PageContentTabCommonConfig").showConfirmationDialog(h,f,g._("Delete"),function(){b("PageContentTabVideosCopyrightActions").updateMatchStateWithBulkSelection(b("VideoCopyrightMatchActionTypes").REMOVE_FROM_ALLOWED,a,e,c,d)},null)}},REMOVE_FROM_REPORT:{allowBatch:!0,getLabel:function(a,b,c){b=a>1?"("+a+")":null;return g._("Move to Manual Review {Post count}",[g._param("Post count",b)])},key:b("VideoCopyrightMatchActionTypes").REMOVE_FROM_REPORT,onClick:function(a,c){b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").REMOVE_FROM_REPORT,c)}},RETRACT_REPORTED:{allowBatch:!0,isAvailable:function(a,c,d){return a.every(function(a){return(a.match_status||a.status)===b("VideoCopyrightMatchStatus").REPORTED})},getLabel:function(a,b,c){return a>1?g._("Cancel {Takedown request count} takedown requests",[g._param("Takedown request count",a)]):g._("Cancel takedown request")},key:b("VideoCopyrightMatchActionTypes").RETRACT_REPORTED,onClick:function(a,c){var d=a.length>1?g._("You're Canceling These Takedown Requests"):g._("You're Canceling This Takedown Request"),e=a.length>1?g._("If you cancel these takedown requests you'll allow these videos to be posted on Facebook. You can access these videos again in your \"Monitored\" tab."):g._("If you cancel this takedown request you'll allow this video to be posted on Facebook. You can access this video again in your \"Monitored\" tab."),f=a.length>1?g._("Cancel Takedown Requests"):g._("Cancel Takedown Request"),h=g._("Go Back");b("PageContentTabCommonConfig").showConfirmationDialog(d,e,f,function(){b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").RETRACT_REPORTED,c)},h)}},RETRACT_TAKEDOWN:{allowBatch:!0,isDisabled:function(a,b){return a.some(function(a){return!a.publisherCanRestore})},isAvailable:function(a,c,d){return a.every(function(a){return(a.match_status||a.status)===b("VideoCopyrightMatchStatus").REMOVED})},getLabel:function(a,b,c){b=a>1?"("+a+")":null;return g._({"video":"Restore video {Post count}","videos":"Restore videos {Post count}"},[g._enum(a===1?"video":"videos",{video:"video",videos:"videos"}),g._param("Post count",b)])},key:b("VideoCopyrightMatchActionTypes").RETRACT_TAKEDOWN,onClick:function(a,c){var d=g._({"Video":"Restore Video","Videos":"Restore Videos"},[g._enum(a.length===1?"Video":"Videos",{Video:"Video",Videos:"Videos"})]),e=a.length===1?g._("Restoring the video will make it available again on Facebook. The match will be moved to your \"Monitored\" tab."):g._("Restoring these {Post count} videos will make them available again on Facebook. The matches will be moved to your \"Monitored\" tab.",[g._param("Post count",a.length)]),f=g._({"Video":"Restore Video","Videos":"Restore Videos"},[g._enum(a.length===1?"Video":"Videos",{Video:"Video",Videos:"Videos"})]);b("PageContentTabCommonConfig").showConfirmationDialog(d,e,f,function(){b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").RETRACT_TAKEDOWN,c)},null)}},REQUEST_TAKEDOWN:{allowBatch:!1,isAvailable:function(a,c,d){c=a[0];return!d.rm_can_takedown_stories&&((a=c)!=null?(a=a.matchedVideoAsset)!=null?a.isStory:a:a)?!1:b("PageContentTabRightsManagerStore").getIsRMLite()&&c&&!c.isAnonymous},getLabel:function(a,b){return g._("Request takedown")},key:b("VideoCopyrightMatchActionTypes").REQUEST_TAKEDOWN,onClick:function(a,c){a=b("XVideoCopyrightSendReportDialogController").getURIBuilder().setInt("page_id",c.page_id).setFBID("match_id",a[0].id).setEnum("source","single_takedown").getURI();a=b("ActorURI").create(a,c.page_id);b("AsyncDialog").send(new(b("AsyncRequest"))().setURI(a))}}};e.exports=a}),null); __d("PageContentTabVideosCopyrightActionsConfig",["PageContentTabCommonActionsConfig","PageContentTabVideosCopyrightCommonActionsConfig"],(function(a,b,c,d,e,f){"use strict";a=[b("PageContentTabVideosCopyrightCommonActionsConfig").REMOVE_FROM_ALLOWED,b("PageContentTabVideosCopyrightCommonActionsConfig").TRACK,b("PageContentTabVideosCopyrightCommonActionsConfig").MONETIZE,b("PageContentTabVideosCopyrightCommonActionsConfig").BLOCK,b("PageContentTabVideosCopyrightCommonActionsConfig").ADD_TO_REPORT,b("PageContentTabVideosCopyrightCommonActionsConfig").SET_SEEN_STATUS,b("PageContentTabCommonActionsConfig").ACTIONS_MENU_SEPARATOR,b("PageContentTabVideosCopyrightCommonActionsConfig").WHITELIST_PAGE,b("PageContentTabVideosCopyrightCommonActionsConfig").WRONG_MATCH,b("PageContentTabVideosCopyrightCommonActionsConfig").REMOVE_FROM_DASHBOARD];e.exports=a}),null); __d("PageContentTabVideosCopyrightDisputesActionsConfig",["fbt","ActorURI","AsyncDialog","AsyncRequest","PageContentTabCommonConfig","PageContentTabVideosCopyrightActions","VideoCopyrightDisputeStatus","VideoCopyrightMatchActionTypes","VideoCopyrightMatchValidStates","VideoCopyrightRuleActionType","XVideoCopyrightSendReportDialogController"],(function(a,b,c,d,e,f,g){__p&&__p();var h=!1,i=!1;a=function(a){__p&&__p();var c=[{allowBatch:!1,getLabel:function(b,c){c="("+b+")";return g._({"*":"claims {Number of claims}","_1":" Release claim {Number of claims}"},[g._plural(b),g._param("Number of claims",a?"":c)])},key:b("VideoCopyrightMatchActionTypes").RELEASE_CLAIM,onClick:function(a,c){__p&&__p();var d=a[0],e=d.matched_video_asset.ad_break_offsets_in_ms;e=e&&e.length>0;var f=d.applied_actions||[];d=(d=d)!=null?(d=d.audit_log)!=null?(d=d[0])!=null?d.match_state:d:d:d;f=f.map(function(a){return a.action}).indexOf(b("VideoCopyrightRuleActionType").BLOCK)!==-1;d=[b("VideoCopyrightMatchValidStates").DISPUTED_WITHOUT_UNBLOCKING,b("VideoCopyrightMatchValidStates").APPEALED_WITHOUT_UNBLOCKING].indexOf(d)!==-1;var i=function(){return b("PageContentTabVideosCopyrightActions").updateDisputeState(a,b("VideoCopyrightMatchActionTypes").RELEASE_CLAIM,c)};if(h)i();else{f?e?f=g._({"remain posted on Facebook":"By releasing your claim, you're accepting the uploader's dispute and the video will remain posted on Facebook . You won't receive any ad earnings from this video. This match will no longer appear in Rights Manager.","be unblocked":"By releasing your claim, you're accepting the uploader's dispute and the video will be unblocked . You won't receive any ad earnings from this video. This match will no longer appear in Rights Manager."},[g._enum(d?"be unblocked":"remain posted on Facebook",{"remain posted on Facebook":"remain posted on Facebook","be unblocked":"be unblocked"})]):f=g._({"remain posted":"By releasing your claim, you're accepting the uploader's dispute and the video will remain posted. This match will no longer appear in Rights Manager.","be unblocked":"By releasing your claim, you're accepting the uploader's dispute and the video will be unblocked. This match will no longer appear in Rights Manager."},[g._enum(d?"be unblocked":"remain posted",{"remain posted":"remain posted","be unblocked":"be unblocked"})]):f=g._("By releasing your claim, you're accepting the uploader's dispute. You won't receive any ad earnings from this video. This match will no longer appear in Rights Manager.");b("PageContentTabCommonConfig").showConfirmationDialog(g._("You're Releasing The Claim On This Video"),f,g._("Release Claim"),function(){h=!0,i()},null)}}}];a&&(c=c.concat([{allowBatch:!1,getLabel:function(a,b){return g._("Uphold claim")},isAvailable:function(a){a=a[0];if(a===null)return!1;a=a.dispute;return a===null?!1:a.status!==b("VideoCopyrightDisputeStatus").APPEALED},key:b("VideoCopyrightMatchActionTypes").UPHOLD_CLAIM,onClick:function(a,c){__p&&__p();var d=function(){return b("PageContentTabVideosCopyrightActions").updateDisputeState(a,b("VideoCopyrightMatchActionTypes").UPHOLD_CLAIM,c)};if(i)d();else{var e=a[0],f=e.matched_video_asset,h=f.platform;f=f.ad_break_offsets_in_ms;f=f&&f.length>0;e=e.applied_actions||[];e=e.map(function(a){return a.action}).indexOf(b("VideoCopyrightRuleActionType").BLOCK)!==-1;e?f?e=g._("By upholding this claim, you're blocking this video from being visible on Facebook. They won't receive any ad earnings from this video. The uploader will have 7 days to appeal."):e=g._({"Facebook":"By upholding this claim, you're blocking this video from being visible on Facebook. The uploader will have 7 days to appeal.","Instagram":"By upholding this claim, you're blocking this video from being visible on Instagram. The uploader will have 7 days to appeal."},[g._enum(h==="IG"?"Instagram":"Facebook",{Facebook:"Facebook",Instagram:"Instagram"})]):e=g._("By upholding this claim, you're rejecting the uploader's dispute. They won't receive any ad earnings from this video. The uploader will have 7 days to appeal.");b("PageContentTabCommonConfig").showConfirmationDialog(g._("You're Upholding Your Claim On This Video"),e,g._("Uphold Claim"),function(){i=!0,d()},null)}}},{allowBatch:!1,getLabel:function(a,b){return g._("Request takedown")},isAvailable:function(a,b,c){return!c.can_see_sound_recordings_tab},key:b("VideoCopyrightMatchActionTypes").REQUEST_TAKEDOWN,onClick:function(a,c){a=b("XVideoCopyrightSendReportDialogController").getURIBuilder().setInt("page_id",c.page_id).setFBID("match_id",a[0].id).setEnum("source","single_takedown").getURI();a=b("ActorURI").create(a,c.page_id);b("AsyncDialog").send(new(b("AsyncRequest"))().setURI(a))}},{allowBatch:!1,getLabel:function(a,b){return g._("Confirm claim")},isAvailable:function(a,c,d){c=a[0].dispute;return c===null?!1:d.can_see_sound_recordings_tab&&c.status===b("VideoCopyrightDisputeStatus").APPEALED},key:b("VideoCopyrightMatchActionTypes").CONFIRM_CLAIM,onClick:function(a,c){var d=g._("By confirming this claim, you're confirming you own music used in this video. The video will remain blocked.");b("PageContentTabCommonConfig").showConfirmationDialog(g._("Confirm Your Claim on This Video?"),d,g._("Confirm Claim"),function(){b("PageContentTabVideosCopyrightActions").updateDisputeState(a,b("VideoCopyrightMatchActionTypes").CONFIRM_CLAIM,c)},null)}}]));return c};e.exports=a}),null); __d("PageContentTabVideosCopyrightPendingClaimActionsConfig",["fbt","DOM","PageContentTabCommonConfig","PageContentTabVideosCopyrightActions","React","ReactDOM","VideoCopyrightGeoActionDialog.react","VideoCopyrightMatchActionTypes","VideoCopyrightRuleActionType","promiseDone"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=[{allowBatch:!1,getLabel:function(a,b,c){return g._("Release claim")},key:b("VideoCopyrightMatchActionTypes").CANCEL_CLAIM,onClick:function(a,c){b("PageContentTabCommonConfig").showConfirmationDialog(g._("Delete Match"),g._("This match will be permanently removed from your dashboard."),g._("Delete"),function(){b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").REMOVE_FROM_DASHBOARD,c)},null)}},{allowBatch:!1,getLabel:function(a,b,c){return g._("Confirm block")},isAvailable:function(a,b,c){return!!((b=a[0])!=null?(b=b.trustedPartnerInfo)!=null?b.can_confirm_action:b:b)},key:b("VideoCopyrightMatchActionTypes").CONFIRM_BLOCK,onClick:function(a,c){var d=b("DOM").create("div"),e=function(e,f){b("promiseDone")(b("PageContentTabVideosCopyrightActions").updateAppliedActions(a,e,c,f)),b("ReactDOM").unmountComponentAtNode(d)};if(c.copyright_geo_actions_enabled){var f=a[0];e=b("React").createElement(b("VideoCopyrightGeoActionDialog.react"),{action:b("VideoCopyrightRuleActionType").BLOCK,appliedActions:f.applied_actions,useBusinessPageDialog:c.can_see_is_business_page_match,onSubmit:e,ownershipGeoGate:f.ownership_countries});b("ReactDOM").render(e,d)}else b("PageContentTabVideosCopyrightActions").updateMatchState(a,b("VideoCopyrightMatchActionTypes").BLOCK,c)}}];e.exports=a}),null); __d("PageContentTabVideosCopyrightReportedActionsConfig",["PageContentTabVideosCopyrightCommonActionsConfig"],(function(a,b,c,d,e,f){a=[b("PageContentTabVideosCopyrightCommonActionsConfig").RETRACT_REPORTED];e.exports=a}),null); __d("PageContentTabVideosCopyrightTakedownsActionsConfig",["PageContentTabVideosCopyrightCommonActionsConfig"],(function(a,b,c,d,e,f){a=[b("PageContentTabVideosCopyrightCommonActionsConfig").RETRACT_REPORTED,b("PageContentTabVideosCopyrightCommonActionsConfig").RETRACT_TAKEDOWN];e.exports=a}),null); __d("PageContentTabVideosCopyrightUnsentReportsActionsConfig",["PageContentTabCommonActionsConfig","PageContentTabVideosCopyrightCommonActionsConfig"],(function(a,b,c,d,e,f){a=[b("PageContentTabVideosCopyrightCommonActionsConfig").REMOVE_FROM_REPORT,b("PageContentTabCommonActionsConfig").ACTIONS_MENU_SEPARATOR,b("PageContentTabVideosCopyrightCommonActionsConfig").REMOVE_FROM_DASHBOARD];e.exports=a}),null); __d("VideoCopyrightMatchActionNux",["fbt","React","SimpleNUXMessage","SimpleNUXMessageTypes"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a={_getManualNuxContent:function(a){if(a)return g._("{New label param} You can block or claim ad earnings from this matched video.",[g._param("New label param",b("React").createElement("div",null,b("React").createElement("b",null,g._("New!"))))]);else return g._("{New label param} You can block this matched video.",[g._param("New label param",b("React").createElement("div",null,b("React").createElement("b",null,g._("New!"))))])},_getAutoNuxContent:function(a){if(a)return g._("{New label param} You can create match rules to automatically block or claim ad earnings from matched videos.",[g._param("New label param",b("React").createElement("div",null,b("React").createElement("b",null,g._("New!"))))]);else return g._("{New label param} You can create match rules to automatically block matched videos.",[g._param("New label param",b("React").createElement("div",null,b("React").createElement("b",null,g._("New!"))))])},_onDismiss:function(a,c){a=a==="MATCH_RULES";c&&b("SimpleNUXMessage").markMessageSeenByUser(a?b("SimpleNUXMessageTypes").VIDEO_COPYRIGHT_AUTO_MONETIZE:b("SimpleNUXMessageTypes").VIDEO_COPYRIGHT_MANUAL_MONETIZE);b("SimpleNUXMessage").markMessageSeenByUser(a?b("SimpleNUXMessageTypes").VIDEO_COPYRIGHT_AUTO_BLOCK:b("SimpleNUXMessageTypes").VIDEO_COPYRIGHT_MANUAL_BLOCK)},getActionNuxContent:function(a,b){var c=this;if(b==="MATCH_RULES"&&a.rights_manager_nux_config.auto_action_nux)return{content:this._getAutoNuxContent(a.is_copyright_monetization_onboarded),onDismiss:function(){return c._onDismiss(b,a.is_copyright_monetization_onboarded)}};else if(a.rights_manager_nux_config.manual_action_nux&&(b==="NEW_MATCHES"||b==="TRACKED"||b==="BLOCKED"||b==="MANUAL_REVIEW"||b==="CLAIMED"))return{content:this._getManualNuxContent(a.is_copyright_monetization_onboarded),onDismiss:function(){return c._onDismiss(b,a.is_copyright_monetization_onboarded)}};else return null}};e.exports=a}),null); __d("VideoCopyrightMatchComparisonDialog.react",["cx","fbt","BootloadedComponent.react","JSResource","React","XUIDialog.react","XUIDialogBody.react","XUIDialogTitle.react","XUISpinner.react"],(function(a,b,c,d,e,f,g,h){__p&&__p();var i=754,j=50;a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.$1=function(){return b("React").createElement("div",{className:"_2rjb"},b("React").createElement(b("XUISpinner.react"),{size:"large"}))};d.render=function(){var a;return!this.props.shown?null:b("React").createElement(b("XUIDialog.react"),{shown:!0,width:i,onToggle:this.props.onToggle,fixedTopPosition:j},b("React").createElement(b("XUIDialogTitle.react"),null,((a=this.props)!=null?(a=a.match)!=null?(a=a.matchData)!=null?(a=a[0])!=null?a.isManualMatch:a:a:a:a)?h._("Manual Match Comparison"):b("React").createElement("div",null,h._("Match Details"))),b("React").createElement(b("XUIDialogBody.react"),{fontSize:"inherit",useCustomPadding:!0},b("React").createElement(b("BootloadedComponent.react"),{bootloadLoader:b("JSResource")("VideoCopyrightMatchComparison.react").__setRef("VideoCopyrightMatchComparisonDialog.react"),bootloadPlaceholder:this.$1(),match:this.props.match,matchIndex:this.props.matchIndex,matchesCount:this.props.matchesCount,onMatchNavigation:this.props.onMatchNavigation,originalURI:this.props.originalURI,source:this.props.source,actionsConfig:this.props.actionsConfig,onActionSelected:this.props.onActionSelected,onMatchNotesChanged:this.props.onMatchNotesChanged,onLiveStreamFinished:this.props.onLiveStreamFinished,pageID:this.props.pageID,page:this.props.page,areGeoActionsEnabled:this.props.page.copyright_geo_actions_enabled,canSeeManualBlockNux:this.props.page.can_see_manual_block_nux,nux:this.props.nux})))};return c}(b("React").Component);e.exports=a}),null); __d("PageContentTabVideoCopyrightMatchComparisonDialog.react",["cx","fbt","Event","PageContentTabCommonActionsConfig","PageContentTabConstants","PageContentTabDataLoader","PageContentTabLogger","PageContentTabQueryStore","PageContentTabStoresConfig","PageContentTabVideosCopyrightActions","PageContentTabVideosCopyrightActionsConfig","PageContentTabVideosCopyrightDisputesActionsConfig","PageContentTabVideosCopyrightPendingClaimActionsConfig","PageContentTabVideosCopyrightReportedActionsConfig","PageContentTabVideosCopyrightTakedownsActionsConfig","PageContentTabVideosCopyrightUnsentReportsActionsConfig","React","SimpleNUXMessage","SimpleNUXMessageTypes","URI","VideoCopyrightMatchActionNux","VideoCopyrightMatchActionTypes","VideoCopyrightMatchComparisonDialog.react","VideoCopyrightMatchValidStates","VideoCopyrightUtils","XUIDialog.react","XUIDialogBody.react","XUISpinner.react"],(function(a,b,c,d,e,f,g,h){__p&&__p();var i=b("PageContentTabConstants").TABS,j=5;a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){__p&&__p();var d;d=a.call(this,c)||this;d.$8=function(a){if(a.state&&a.state.copyrightMatchID){var b=window.history.state.copyrightMatchID;a=d.state.matches.findIndex(function(a){return a.id===b});a!==-1&&a!==d.state.matchIndex&&d.$9(a)}else d.$10(!1)};d.$7=function(){__p&&__p();var a=d.state.matchesStore,c=b("PageContentTabQueryStore").getQueryKey(d.props.page.page_id,d.props.tab.id),e=a.isInitialLoadComplete(c);if(!e)return;e=a.getAllPosts(c);a=a.getTotalCount(c);a=e.length)&&(d.state.matchIndex>=0&&d.state.matchIndex=c&&b("PageContentTabDataLoader").fetchNextPosts(d.props.tab.id,d.state.queryKey,d.props.page.page_id);c=d.state.matches[a];var e=d.$6(c);d.setState({matchIndex:a,shown:!0,actionsConfig:e});d.state.shown&&d.setMatchIsViewed(c)};d.$10=function(a){d.setState({shown:a})};d.$11=function(a){var c=d.state.matches[d.state.matchIndex];b("PageContentTabLogger").log("action_taken_overlay",d.props.tab.id,{action:a.key,post_id:c.id,post_ids:[c.id],num_posts:1,bulk_action:!1},[c]);a.onClick([c],d.props.page,d.props.tab.id,d.$10);a=1+d.state.matchIndex;a>=d.state.matches.length&&a0&&(this.$4=b.matches[b.matchIndex]?b.matches[b.matchIndex].id:b.matches[0].id)};d.UNSAFE_componentWillReceiveProps=function(a){var b=this.state.matches.indexOf(a.match);a=this.$6(a.match);b<0&&(b=0);this.setState({matchIndex:b,shown:!0,actionsConfig:a});this.setMatchIsViewed(this.state.matches[b])};d.setMatchIsViewed=function(a){if(!a||!a.id)return;b("PageContentTabVideosCopyrightActions").setMatchSeen([a],this.props.page);b("PageContentTabLogger").log("action_taken_overlay",this.props.tab.id,{action:b("VideoCopyrightMatchActionTypes").MARK_SEEN,post_id:a.id,post_ids:[a.id],num_posts:1,bulk_action:!1},[a])};d.$6=function(a){__p&&__p();if(a.audit_log&&a.audit_log[0].match_state===b("VideoCopyrightMatchValidStates").PENDING_CLAIMED)return b("PageContentTabVideosCopyrightPendingClaimActionsConfig");a=[];var c=!0;switch(this.props.tab.id){case i.NEW_MATCHES:case i.MANUAL_REVIEW:case i.ALLOWED:case i.TRACKED:case i.CLAIMED:case i.BLOCKED:a=b("PageContentTabVideosCopyrightActionsConfig");break;case i.UNSENT_REPORTS:a=b("PageContentTabVideosCopyrightUnsentReportsActionsConfig");break;case i.REPORTED:a=b("PageContentTabVideosCopyrightReportedActionsConfig");break;case i.TAKEDOWNS:a=b("PageContentTabVideosCopyrightTakedownsActionsConfig");break;case i.DISPUTES:a=b("PageContentTabVideosCopyrightDisputesActionsConfig")(!0);c=!1;break;default:return null}this.props.page.show_static_filter_actions&&c&&(a=a.concat(b("PageContentTabCommonActionsConfig").getStaticFilterActions()));return a};d.$14=function(){var a=b("VideoCopyrightMatchActionNux").getActionNuxContent(this.props.page,this.props.tab.id);return a===null?this.$15():a};d.$15=function(){return!this.props.page.can_use_keyboard_to_select_action||b("SimpleNUXMessage").hasUserSeenMessage(b("SimpleNUXMessageTypes").VIDEO_COPYRIGHT_KEYBOARD_SHORTCUTS)?null:{content:h._("{New label param} Speed up your workflow with keyboard shortcuts. {line break} Type '?' to learn more.",[h._param("New label param",b("React").createElement("div",null,b("React").createElement("b",null,h._("New!")))),h._param("line break",b("React").createElement("br",null))]),onDismiss:function(){return b("SimpleNUXMessage").markMessageSeenByUser(b("SimpleNUXMessageTypes").VIDEO_COPYRIGHT_KEYBOARD_SHORTCUTS)}}};d.render=function(){var a=this.state.matches[this.state.matchIndex];if(!a)return b("React").createElement(b("XUIDialog.react"),{shown:this.state.shown,width:108},b("React").createElement(b("XUIDialogBody.react"),{className:"_2pib"},b("React").createElement(b("XUISpinner.react"),{background:"light",className:"_3-8o _3-8v",size:"large"})));a=b("VideoCopyrightUtils").convertGraphAPIMatchToVideoCopyrightMatch(a);return b("React").createElement(b("VideoCopyrightMatchComparisonDialog.react"),{actionsConfig:this.state.actionsConfig,match:a,matchIndex:this.state.matchIndex,matchesCount:this.state.matchesTotalCount,nux:this.$14(),onActionSelected:this.$11,onLiveStreamFinished:this.$13,onMatchNavigation:this.$9,onMatchNotesChanged:this.$12,onToggle:this.$10,originalURI:this.$3,page:this.props.page,pageID:this.props.page.page_id,shown:this.state.shown,source:"dashboard"})};return c}(b("React").Component);e.exports=a}),null); __d("XRightsManagerChangeLogDocAsyncController",["XController"],(function(a,b,c,d,e,f){e.exports=b("XController").create("/CMS Root/Intellectual Property/Blueprint/",{page_id:{type:"FBID",required:!0}})}),null); __d("RightsManagerChangeLogNuxComponent.react",["ix","cx","fbt","ActorURI","AsyncRequest","DOMContainer.react","Grid.react","HTML","Image.react","Link.react","React","SimpleNUXMessageTypes","SimpleNUXMessage","XUIDialog.react","XUIDialogBody.react","XUIDialogTitle.react","XUIDialogFooter.react","XUIDialogButton.react","XRightsManagerChangeLogDocAsyncController","fbglyph"],(function(a,b,c,d,e,f,g,h,i){__p&&__p();var j=b("Grid.react").GridItem;a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){c=a.call(this,c)||this;c.state={nuxShown:!b("SimpleNUXMessage").hasUserSeenMessage(b("SimpleNUXMessageTypes").RIGHTS_MANAGER_CHANGE_LOG),changeLogLink:null};return c}var d=c.prototype;d.UNSAFE_componentWillMount=function(){var a=this,c=b("ActorURI").create(b("XRightsManagerChangeLogDocAsyncController").getURIBuilder().setFBID("page_id",this.props.page.page_id).getURI(),this.props.page.page_id);new(b("AsyncRequest"))(c).setHandler(function(c){return a.setState({changeLogLink:b("HTML").replaceJSONWrapper(c.payload).getRootNode()})}).send()};d.$1=function(){b("SimpleNUXMessage").markMessageSeenByUser(b("SimpleNUXMessageTypes").RIGHTS_MANAGER_CHANGE_LOG),this.setState({nuxShown:!1})};d.$2=function(){this.$1(),window.open("https://facebook.exceedlms.com/student/catalog/show/182065")};d.$3=function(){this.$1()};d.$4=function(){return b("React").createElement(b("Grid.react"),{className:"_3nqj",cols:4,spacing:"phl",alignh:"left",alignv:"top"},b("React").createElement(j,{className:"_3nqk"},b("React").createElement(b("Image.react"),{className:"_3nql",src:g("133779")})),b("React").createElement(j,{className:"_3nqk"},i._("Apply new actions to videos containing content you own: Monitor, Manual Review and Block.")),b("React").createElement(j,{className:"_3nqk"},b("React").createElement(b("Image.react"),{className:"_3nql",src:g("134958")})),b("React").createElement(j,{className:"_3nqk"},i._("See matched videos that are most relevant to you (based on your match rules) in the Manual Review section.")),b("React").createElement(j,{className:"_3nqk"},b("React").createElement(b("Image.react"),{className:"_3nql",src:g("134887")})),b("React").createElement(j,{className:"_3nqk"},i._("Create match rules to only take automatic actions on public or private videos.")),b("React").createElement(j,{className:"_3nqk"},b("React").createElement(b("Image.react"),{className:"_3nql",src:g("133649")})),b("React").createElement(j,{className:"_3nqk"},i._("Go back to find videos you've already applied an action to in the Completed section.")))};d.$5=function(){if(this.state.changeLogLink!=null)return b("React").createElement(b("DOMContainer.react"),null,this.state.changeLogLink);else return b("React").createElement(b("Link.react"),{className:"_3nqw"},i._("Read more about these updates."))};d.$6=function(){return b("React").createElement("div",{className:"_3nqm"},b("React").createElement("div",{className:"_3nqu"},i._("Introducing new actions and a new navigation")),b("React").createElement("div",{className:"_3nqv"},i._("Rights Manager is launching more ways to improve your workflow based on your feedback.")," ",this.$5()))};d.$7=function(){return b("React").createElement("div",{className:"_3nqx"},i._("Take a Blueprint eLearning course to learn about everything you can do in Rights Manager."))};d.render=function(){return!this.props.page.rights_manager_nux_config.changelog_nux?null:b("React").createElement(b("XUIDialog.react"),{width:850,shown:this.state.nuxShown,onToggle:this.$3.bind(this)},b("React").createElement(b("XUIDialogTitle.react"),null,i._("Important Updates to Rights Manager")),b("React").createElement(b("XUIDialogBody.react"),{className:"_3nqy"},this.$6(),this.$4(),this.$7()),b("React").createElement(b("XUIDialogFooter.react"),null,b("React").createElement(b("XUIDialogButton.react"),{action:"confirm",label:i._("Start Course"),onClick:this.$2.bind(this),use:"confirm"})))};return c}(b("React").Component);e.exports=a}),null); __d("VideoCopyrightInstagramOnboardInfoRow.react",["cx","ImageBlock.react","React","XUIText.react"],(function(a,b,c,d,e,f,g){"use strict";function a(a,c){return b("React").createElement(b("ImageBlock.react"),{className:"_1h8-"},b("React").createElement("div",{className:"_1h8_"},a),b("React").createElement(b("XUIText.react"),{className:"_1h90",display:"block"},c))}e.exports=a}),null); __d("VideoCopyrightInstagramOnboardSaveSelection",["regeneratorRuntime","Promise","AsyncRequest","XPagesAdminVideoCopyrightSettingsController"],(function(a,b,c,d,e,f){"use strict";__p&&__p();e.exports={gen:function(a,c){var d;return b("regeneratorRuntime").async(function(e){while(1)switch(e.prev=e.next){case 0:d=b("XPagesAdminVideoCopyrightSettingsController").getURIBuilder().getURI();return e.abrupt("return",new(b("Promise"))(function(e,f){new(b("AsyncRequest"))(d).setMethod("POST").setURI(d).setData({page_id:a,new_settings:{video_copyright_platform:c}}).setHandler(function(a){e(a.payload)}).setErrorHandler(f).send()}));case 2:case"end":return e.stop()}},null,this)}}}),null); __d("VideoCopyrightInstagramOnboardInfo.react",["cx","fbt","regeneratorRuntime","React","SUIBusinessTheme","SUICard.react","SUICardBody.react","SUICardFooter.react","VideoCopyrightInstagramOnboardInfoRow.react","VideoCopyrightInstagramOnboardSaveSelection","XUIButton.react","XUIText.react","cxMargin"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var c,d;for(var e=arguments.length,f=new Array(e),g=0;g0;q=(q?q+" ":"")+(r||"");r=a.added_to_dashboard_time||v;v=r>0?b("formatDate")(new Date(r*k),"M j, Y"):i._("Unknown");r=e.total_match_duration;var A=e.is_manual_match,B=e.monitoring_type!==b("VideoCopyrightMonitoringType").AUDIO_ONLY.value&&(e.video_matched_segments||[]).length>0;e=e.monitoring_type!==b("VideoCopyrightMonitoringType").VIDEO_ONLY.value&&(e.audio_matched_segments||[]).length>0;e=B&&e?b("VideoCopyrightMonitoringType").VIDEO_AND_AUDIO.value:B?b("VideoCopyrightMonitoringType").VIDEO_ONLY.value:b("VideoCopyrightMonitoringType").AUDIO_ONLY.value;q.trim().length===0&&(q=x||m?i._("Private video"):i._("Untitled"));d[j.VIDEO]={id:p,isCopyright:!1,isReferenceVideo:!1,title:q,thumbnailSrc:t,duration:u,hasAttribution:z,liveStatus:y,showAttributionsIcon:c.show_attributions_tab,showLiveStatusIcon:!0,showMonetizableIcon:!0,showMonitoringTypeIcons:!0,containsAdBreaks:f,monitoringType:e,platform:g,showPlatformIcon:c.can_see_ig_matches,referenceAssets:n};d[j.DATE_FOUND]={dateFound:v,ownerName:x||m?null:s,trustedPartnerInfo:a.trusted_partner_info,isBusinessPageMatch:a.is_business_page_match};d[j.VIDEO_VIEWS]={views:w||0,platform:g};d[j.OVERLAP]={matchedDuration:r||0,isManualMatch:A,videoDuration:u};d[j.REFERENCE_VIDEO]={title:l||"",liveStatus:h===null?2:h,matchCount:o};return d},createNewMatchesRow:function(a,c){__p&&__p();var d=a.expiration_days,e=q._createRow(a,c),f=a.trusted_partner_info;if(c.can_see_manual_review_status_column&&f){c=f.can_confirm_action;if(!c&&a.audit_log&&a.audit_log[0].match_state===b("VideoCopyrightMatchValidStates").PENDING_CLAIMED){c=f.confirm_action_time;a=i._("Confirm your request after {date}",[i._param("date",b("formatDate")(c,"M j, Y"))]);d=b("React").createElement("div",null,i._("Block Requested"),b("React").createElement(b("Image.react"),babelHelpers["extends"]({className:"_2mml",src:g("403741")},b("TooltipData").propsFor(a,"above"))))}else d===0?d=i._("Never expires"):d===-1?d="":d=i._({"*":{"*":"Expires in {number} days","_1":"Expires in {number} day"}},[i._param("number",d,[0]),i._plural(d)]);e[j.STATUS]={expires_days:d}}else d===0?d=i._("Never"):d===-1?d="":d=i._({"*":{"*":"{number} days","_1":"{number} day"}},[i._param("number",d,[0]),i._plural(d)]),e[j.EXPIRES_DAYS]={expires_days:d};return e},createManualReviewMatchesRow:function(a,c){c=q.createNewMatchesRow(a,c);var d=a.last_modified_time;a=a.action_requiring_manual_review;a=b("VideoCopyrightUtils").getActionRequiringManualReviewLabel(a);c[j.MANUAL_REVIEW_ACTION]={lastModifiedDate:d?b("formatDate")(new Date(d*k),"M j, Y"):"",actionName:a?a:" ",actionRequiringManualReviewLabel:a};return c},createModifiedRow:function(a,c){c=q.createNewMatchesRow(a,c);var d=a.last_modified_user,e=a.last_modified_time,f=b("VideoCopyrightUtils").getAppliedActionLabel(a.applied_actions||[]);e=e?b("formatDate")(new Date(e*k),"M j, Y"):"";c[j.LAST_MODIFIED_BY]={lastModifiedDate:e,lastModifiedName:d?d.name:" ",appliedActionsLabel:f};c[j.STATUS]={lastModifiedDate:e,status:a.match_status};return c},createDisputesRow:function(a,c){__p&&__p();c=q._createRow(a,c);var d=a.matched_video_asset||{},e=d.is_private,f=a.is_anonymous;d=d.owner_name;var g=a.dispute.time_appealed,h=a.dispute.expiration_time;h=b("VideoCopyrightUtils").getDisputeExpirationLabel(h);a=a.applied_actions.map(function(a){return a.action}).indexOf(b("VideoCopyrightRuleActionType").BLOCK)!==-1;a?g?a=i._("Block Appealed"):a=i._("Block Disputed"):g?a=i._("Claim Appealed"):a=i._("Claim Disputed");h||(h=i._("Expired"));c[j.STATUS]={status:a,ownerName:e||f?null:d};c[j.EXPIRES_DAYS]={expires_days:h};c[j.DISPUTE_EXPIRES_DAYS]={expires_days:h};return c},getLearnMoreText:function(a){a=this.getLearnMoreLink(a);if(a)return b("React").createElement("div",null,b("React").createElement("p",null,i._("You can create match rules to take automatic actions on videos that match your reference file.")),b("React").createElement("p",null,a))},getLearnMoreLink:function(a){a=a.copyright_management_config?a.copyright_management_config.learnMoreURL:null;if(a&&a.length)return b("React").createElement(b("Link.react"),{href:a,target:"_blank"}," ",i._("Learn more about Rights Manager."))},getDataLoadPromise:function(a,c,d,f,g,h){var i=b("VideoCopyrightUtils").getGraphAPIFields(f);return b("GraphAPI")(b("VideoCopyrightUtils").GRAPH_API_VERSION,e.id).object("page",f.page_id).edge("copyright_matches").get({match_status:a,fields:i.concat(c||[]),access_token:d,filtering:g,summary:!0,sort:h,date_format:"U",limit:p})},label:i._("Rights Manager"),maxInsightValue:function(a,b){var c=0;a.forEach(function(a){c=Math.max(c,parseInt(a[b],10))});return c},maxOverlapValue:function(a){var c=0;a.forEach(function(a){a=b("VideoCopyrightUtils").getActiveMatchDataFromMatch(a);a=a.total_match_duration;c=Math.max(c,parseInt(a,10))});return c},searchFilterField:{field:new(b("AdsGenericFilterField"))("summary",b("AdsGenericFilterFieldType").STRING),operator:"CONTAIN"},_hideNux:function(a){var c=b("XBasicFBNuxDismissController").getURIBuilder().setInt("nux_id",l).getURI();new(b("AsyncRequest"))().setURI(c).send();a.show_copyright_tour_nux=!1},clientSortAndFilter:function(a,c,d,e){__p&&__p();try{var f,g;c=!1;if(a.length>=2)if(d&&(d.key===j.VIDEO_VIEWS||d.key===j.OVERLAP))f=d.key,d.order,g=d.order===b("PageContentTabConstants").SORT_ORDER_ASC?1:-1,c=!0;else{e=a[0].match_status;f=d&&d.key?d.key:e===b("VideoCopyrightMatchStatus").NEW_MATCH?m:n;e=d&&d.order?d.order:o;g=e===b("PageContentTabConstants").SORT_ORDER_ASC?1:-1;g*b("VideoCopyrightUtils").sortableColumnToField(f,a[0])>g*b("VideoCopyrightUtils").sortableColumnToField(f,a[1])&&(c=!0)}c&&a.sort(function(a,c){return g*(b("VideoCopyrightUtils").sortableColumnToField(f,a)-b("VideoCopyrightUtils").sortableColumnToField(f,c))})}catch(a){new(b("VideoCopyrightUITypedLogger"))().setEvent("ui_error").setSource("matches_table").setMessage(String(a)).log()}return a},_createPopUpNuxComponent:function(a){if(a.rights_manager_nux_config.changelog_nux)return b("RightsManagerChangeLogNuxComponent.react");return a.rights_manager_nux_config.ig_onboarding_nux?b("VideoCopyrightInstagramOnboard.react"):null},getCommonConfig:function(a){var c=this;return{createNuxComponent:null,onDismissNux:function(){return c._hideNux(a)},maxErrorRetries:3,shouldResetSortOnThirdClick:!0,createPopUpNuxComponent:q._createPopUpNuxComponent(a),hasMinHeight:b("PageContentTabRightsManagerStore").getIsRMLite()}}};e.exports=q}),null); __d("CopyrightAttributionReferenceFilesDialog.react",["ix","cx","fbt","AdsFilterChangeTypes","AdsGenericFilter","AdsGenericFilterField","AdsGenericFilterFieldType","AdsGenericFilterSet","AdsGenericFilterSetUtil","CopyrightAttributionReferenceBulkSelectionMode","CopyrightAttributionReferenceFilesDialogColumnConfig","GraphAPI","Image.react","LayerFadeOnHide","LayerFadeOnShow","LeftRight.react","Link.react","PageContentGenericTable.react","PageContentTabConfig","PageContentTabConstants","PageContentTabFilter.react","PageContentTabFilterMenu.react","PageContentTabFilterUtils","PageContentTabReferenceLibraryFilterFieldConfig","PageContentTabSavedFilterSet","PageContentTabSearchInput.react","PageContentTabVideosCopyrightCommonConfig","PageContentTabVideosCopyrightFilterValueConfig","React","VideoCopyrightUtils","XUIDialog.react","XUIDialogBody.react","XUIDialogCancelButton.react","XUIDialogFooter.react","XUIDialogSaveButton.react","XUIDialogTitle.react","XUIPopoverButton.react","XUISpinner.react","XUIText.react","asset","cxMargin","formatDate","promiseDone"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();var j=b("PageContentTabConstants").COLUMNS,k=806,l=300,m=55,n=28,o=m,p=1e3;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var c,d;for(var e=arguments.length,f=new Array(e),g=0;g0?null:b("React").createElement(b("Image.react"),{className:"_3-90",src:g("480789")}),b("React").createElement(b("XUIText.react"),{className:"_37xp"},c>0?i._({"*":"{number} files selected","_1":"{number} file selected"},[i._param("number",c),i._plural(c)]):i._("No reference files selected")));return b("React").createElement(b("XUIDialog.react"),{className:"_37wn",behaviors:{LayerFadeOnHide:b("LayerFadeOnHide"),LayerFadeOnShow:b("LayerFadeOnShow")},isStrictlyControlled:!0,shown:this.props.isShown,onHide:function(){return a.props.onToggle(!1)},onToggle:function(b){return a.props.onToggle(b)},width:k},b("React").createElement(b("XUIDialogTitle.react"),null,i._("Select Reference Files")),b("React").createElement(b("XUIDialogBody.react"),{className:"_37wo"},b("React").createElement("div",null,this.$12(),this.$13(),this.$14())),b("React").createElement(b("XUIDialogFooter.react"),{leftContent:d},b("React").createElement(b("XUIDialogCancelButton.react"),{className:"_4gcs",size:"large"}),b("React").createElement(b("XUIDialogSaveButton.react"),{className:"_4gcs",use:"confirm",size:"large",onClick:this.$15,disabled:c<=0})))};d.$12=function(){var a=this,c=this.$11()>0?b("React").createElement(b("Link.react"),{className:"_47_l",style:{fontWeight:"bold"},onClick:function(){return a.setState(function(a){return{isViewingSelected:!a.isViewingSelected}})}},this.state.isViewingSelected?i._("View All"):i._("View Selected")):b("React").createElement(b("XUIText.react"),{className:"_47_l _47_n",style:{fontWeight:"bold"}},i._("View Selected")),d=this.state.totalCount>0&&!this.$16();d=d?b("React").createElement(b("Link.react"),{className:"_47_l _3-8i",onClick:this.$17},this.$18()?i._("Select All ({totalNumber})",[i._param("totalNumber",this.state.totalCount)]):i._("Deselect All")):null;var e=b("React").createElement(b("PageContentTabSearchInput.react"),{onSearch:this.$19,query:this.state.searchKeyword}),f=b("React").createElement(b("XUIPopoverButton.react"),{className:"_1pd9",ref:"filterMenuButton",haschevron:!0,label:i._("Filters"),onClick:function(){return a.setState(function(a){return{isFilterMenuShown:!a.isFilterMenuShown}})},size:"medium"}),g=this.refs.filterMenuButton?b("React").createElement(b("PageContentTabFilterMenu.react"),{filterButton:this.refs.filterMenuButton,onFilterMenuChange:this.$20,onToggle:function(b){return a.setState({isFilterMenuShown:b})},filterFieldsConfig:this.$1,filterMenuVisible:this.state.isFilterMenuShown,filterSet:this.state.filterSet,savedFilterSets:this.state.savedFilterSet,onSavedFiltersSelectionChange:this.$21}):null;return b("React").createElement("div",{className:"_37xg"},b("React").createElement(b("LeftRight.react"),null,b("React").createElement("div",{className:this.state.isViewingSelected?"_47_o":""},e,f,g,d),c))};d.$13=function(){return!this.state.isFilterShown||!this.state.filterSet?null:b("React").createElement("div",{className:this.state.isViewingSelected?"_47_o":""},b("React").createElement(b("PageContentTabFilter.react"),{fieldsConfig:this.$1,filterSet:this.state.filterSet,valuesConfig:b("PageContentTabVideosCopyrightFilterValueConfig"),onFilterChange:this.$22,onClear:this.$23,hideAddButton:!0,showNewFilters:!0}))};d.$14=function(){var a=this.state.isViewingSelected?this.state.selectedReferenceFiles:this.state.referenceFiles,c={},d=this.state.isViewingSelected?this.state.isLoadingSelectedRefFiles:this.state.isLoadingRefFiles;Object.keys(this.state.selectedReferenceFiles).map(function(a){c[a]=!0});return b("React").createElement("div",{className:"_1pdd"},d?b("React").createElement("div",{className:"_1pde"},b("React").createElement(b("XUISpinner.react"),{background:"light",className:"_1pdf",size:"large"})):null,b("React").createElement(b("PageContentGenericTable.react"),{className:"_37xi"+(d?" _1pdg":""),columns:this.$2,posts:Object.values(a),selectedPosts:c,showCheckboxColumn:!1,createTableRow:this.$24,tableHeight:l,tableWidth:k,rowHeight:m,headerHeight:n,onTableRowClick:this.$25,onScrollEnd:this.$26}))};d.$24=function(a,c){__p&&__p();var d={},e=a.reference_file,f=a.attribution,g=a.creator,h=e.id,k=e.encoding_status,l;k=k&&k.video_status==="processing";k&&(l=e.thumbnail_url_while_encoding);(!l||!l.length)&&(l=e.thumbnail_url);var m=e.title,n=e.duration_in_sec;e=e.published_time;m=m||"";d[j.VIDEO]={hasAttribution:!!f,id:h,title:m,thumbnailSrc:l,duration:n,isEditing:a.isEditing,isProcessing:k,showAttributionsIcon:!1,showLiveStatusIcon:!1,showMonitoringTypeIcons:!1,showVideoPostIcon:!1,showPlatformIcon:!1,pageID:c.pageID};d[j.ATTRIBUTION_TITLE]={attribution:f};d[j.PUBLISHED_DATE]={dateAdded:e?b("formatDate")(new Date(e*p),"M j, Y"):i._("Not published"),creatorName:g?g.name:null,id:h,isProcessing:k};return d};d.$8=function(a){var c=this,d=b("PageContentTabFilterUtils").addSearchToFilterSet(this.state.filterSet,b("PageContentTabVideosCopyrightCommonConfig").searchFilterField,this.state.searchKeyword);this.setState({isLoadingRefFiles:!0});b("promiseDone")(b("GraphAPI")(b("VideoCopyrightUtils").GRAPH_API_VERSION,e.id).object("page",this.props.pageID).edge("video_media_copyrights").get({access_token:this.props.pageAccessToken,filtering:d?d.toAPI():[],summary:!0,date_format:"U",fields:b("VideoCopyrightUtils").getReferenceFileGraphFields(),sort:"published_time_ordered_descending"}),function(b){var d;return c.setState(babelHelpers["extends"]({isLoadingRefFiles:!1},a?{totalCount:(d=b)!=null?(d=d.summary)!=null?d.total_count:d:d}:{},c.$29(b,!0)))},function(a){return c.setState({isLoadingRefFiles:!1})})};d.$9=function(){var a=this;if(this.props.attributionID){this.setState({isLoadingSelectedRefFiles:!0});var c=new(b("AdsGenericFilterSet"))([new(b("AdsGenericFilter"))(new(b("AdsGenericFilterField"))("attribution_id",b("AdsGenericFilterFieldType").STRING),"EQUAL",String(this.props.attributionID))]);b("promiseDone")(b("GraphAPI")(b("VideoCopyrightUtils").GRAPH_API_VERSION,e.id).object("page",this.props.pageID).edge("video_media_copyrights").get({access_token:this.props.pageAccessToken,filtering:c.toAPI(),summary:!0,date_format:"U",fields:b("VideoCopyrightUtils").getReferenceFileGraphFields(),sort:"published_time_ordered_descending"}),function(b){return a.setState(babelHelpers["extends"]({isLoadingSelectedRefFiles:!1},a.$30(b)))},function(b){return a.setState({isLoadingSelectedRefFiles:!1})})}};d.$28=function(){__p&&__p();var a=this,c,d;if(this.state.isViewingSelected)if(this.state.bulkSelectionType===b("CopyrightAttributionReferenceBulkSelectionMode").SELECT)c=this.$3,d=this.$29;else if(this.state.bulkSelectionType===b("CopyrightAttributionReferenceBulkSelectionMode").DESELECT)return;else if(this.props.attributionID)c=this.$4,d=this.$30;else return;else this.$16()?(c=this.$5,d=this.$29):(c=this.$3,d=this.$29);if(!c)return;c.done(function(b){a.setState(babelHelpers["extends"]({},d(b))),a.forceUpdate()},function(a){})};d.$10=function(){var a=this;this.state.savedFilterSet||b("promiseDone")(b("GraphAPI")(b("PageContentTabConfig").graph_api_version,e.id).object("page",this.props.pageID).edge("saved_filters").get({access_token:this.props.pageAccessToken,fields:["id","display_name","section","filters","time_created"],section:b("PageContentTabConstants").TABS.ALL_REFERENCE_FILES}),function(c){c=c.data.map(function(c){return b("PageContentTabSavedFilterSet").fromAPI(c,a.$1)});a.setState({savedFilterSet:c})},function(b){a.setState({savedFilterSet:null})})};d.$27=function(a){if(this.state.bulkSelectionType===b("CopyrightAttributionReferenceBulkSelectionMode").SELECT)return!0;else if(this.state.bulkSelectionType===b("CopyrightAttributionReferenceBulkSelectionMode").DESELECT)return!1;else{a=(a=a)!=null?(a=a.attribution)!=null?a.id:a:a;return!!a&&a===this.props.attributionID}};d.$31=function(a){return Object.prototype.hasOwnProperty.call(this.$6,a.id)?this.$6[a.id]:this.$27(a)};d.$11=function(){var a=Object.entries(this.$6),c=a.filter(function(a){return a[1]}).length;a=a.filter(function(a){return!a[1]}).length;if(this.state.bulkSelectionType===b("CopyrightAttributionReferenceBulkSelectionMode").SELECT)return this.state.totalCount-a;else if(this.state.bulkSelectionType===b("CopyrightAttributionReferenceBulkSelectionMode").DESELECT)return c;else return this.props.initialSelectedCount+c-a};d.$18=function(){return!(this.state.bulkSelectionType===b("CopyrightAttributionReferenceBulkSelectionMode").SELECT&&Object.keys(this.$6).length===0)};d.$16=function(){var a;a=((a=this.state.filterSet)!=null?(a=a.values)!=null?a.length:a:a)||0;a=a===1&&!this.state.nonDispatchedFilterField||a>1;var b=!!this.state.searchKeyword;return a||b};return c}(b("React").PureComponent);a.defaultProps={initialSelectedCount:0};e.exports=a}),null); __d("CopyrightAttributionReferenceFilesSection.react",["ix","cx","fbt","CopyrightAttributionReferenceFilesDialog.react","Image.react","React","Tooltip.react","XUIButton.react","XUIText.react","asset","cxMargin"],(function(a,b,c,d,e,f,g,h,i){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var b,c;for(var d=arguments.length,e=new Array(d),f=0;f0?null:b("React").createElement(b("Image.react"),{className:"_3-90",src:g("480789")}),b("React").createElement(b("XUIText.react"),null,this.state.selectedCount>0?i._({"*":"{number} reference files selected.","_1":"{number} reference file selected."},[i._param("number",this.state.selectedCount),i._plural(this.state.selectedCount)]):i._("No reference files selected."))),b("React").createElement(b("XUIButton.react"),{className:"_3-8x",label:i._("Select Files"),ref:"button",onClick:function(){return a.setState({isDialogShown:!0})}}),b("React").createElement(b("CopyrightAttributionReferenceFilesDialog.react"),{pageID:this.props.pageID,pageAccessToken:this.props.pageAccessToken,attributionID:this.props.attributionID,onConfirm:function(b,c,d,e){a.setState({selectedCount:e,isDialogShown:!1}),a.props.onSelectionChanged(b,c,d)},onToggle:function(b){return a.setState({isDialogShown:b})},isShown:this.state.isDialogShown,initialSelectedCount:this.props.initialSelectedCount}))};return c}(b("React").Component);a.defaultProps={initialSelectedCount:0};e.exports=a}),null); __d("RightsManagerAttributionTabTypedLogger",["Banzai","GeneratedLoggerUtils","nullthrows"],(function(a,b,c,d,e,f){"use strict";__p&&__p();a=function(){__p&&__p();function a(){this.$1={}}var c=a.prototype;c.log=function(){b("GeneratedLoggerUtils").log("logger:RightsManagerAttributionTabLoggerConfig",this.$1,b("Banzai").BASIC)};c.logVital=function(){b("GeneratedLoggerUtils").log("logger:RightsManagerAttributionTabLoggerConfig",this.$1,b("Banzai").VITAL)};c.logImmediately=function(){b("GeneratedLoggerUtils").log("logger:RightsManagerAttributionTabLoggerConfig",this.$1,{signal:!0})};c.clear=function(){this.$1={};return this};c.getData=function(){return babelHelpers["extends"]({},this.$1)};c.updateData=function(a){this.$1=babelHelpers["extends"]({},this.$1,a);return this};c.setAddedReferenceFileCount=function(a){this.$1.added_reference_file_count=a;return this};c.setAttributionID=function(a){this.$1.attribution_id=a;return this};c.setAttributionType=function(a){this.$1.attribution_type=a;return this};c.setEvent=function(a){this.$1.event=a;return this};c.setPageID=function(a){this.$1.page_id=a;return this};c.setRemovedReferenceFileCount=function(a){this.$1.removed_reference_file_count=a;return this};c.setTime=function(a){this.$1.time=a;return this};c.setVC=function(a){this.$1.vc=a;return this};c.setWeight=function(a){this.$1.weight=a;return this};c.updateExtraData=function(a){a=b("nullthrows")(b("GeneratedLoggerUtils").serializeMap(a));b("GeneratedLoggerUtils").checkExtraDataFieldNames(a,g);this.$1=babelHelpers["extends"]({},this.$1,a);return this};c.addToExtraData=function(a,b){var c={};c[a]=b;return this.updateExtraData(c)};return a}();var g={added_reference_file_count:!0,attribution_id:!0,attribution_type:!0,event:!0,page_id:!0,removed_reference_file_count:!0,time:!0,vc:!0,weight:!0};e.exports=a}),null); __d("CopyrightAttributionDialogV2.react",["cx","fbt","CopyrightAttributionDestinationSection.react","CopyrightAttributionDialogFooter.react","CopyrightAttributionGoalSection.react","CopyrightAttributionPreviewSection.react","CopyrightAttributionReferenceFilesSection.react","FlexLayout.react","GraphAPI","LayerFadeOnHide","LayerFadeOnShow","PageContentTabConstants","PageContentTabDispatcher","PageContentTabLoadingDialog","React","RightsManagerAttributionTabTypedLogger","SUIAnalyticsGriffinTheme","SUIBusinessTheme","SUIPopover.react","SUITextInput.react","SUIToggle.react","VideoCopyrightUtils","XUIDialog.react","XUIDialogTitle.react","promiseDone"],(function(a,b,c,d,e,f,g,h){__p&&__p();a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var c,d;for(var f=arguments.length,g=new Array(f),h=0;h0?null:b.selectedTargetName}})},d.$10=function(){d.setState(function(a,b){return{isEnabled:!a.isEnabled}})},c)||babelHelpers.assertThisInitialized(d)}var d=c.prototype;d.$8=function(a,c){this.setState({isShown:!1});this.props.onClose&&this.props.onClose(a);var d=this.state.selectedAttributionType==="PAGE"?"PAGE":"VIDEO";d=new(b("RightsManagerAttributionTabTypedLogger"))().setPageID(this.props.pageID).setAttributionType(d).setAttributionID(c);!this.props.attributionID?(d.setEvent(a?"create_attribution_finished":"create_attribution_cancelled"),a&&d.setAddedReferenceFileCount(this.$2.length.toString())):(d.setEvent("attribution_updated"),d.setAddedReferenceFileCount(this.$2.length.toString()),d.setRemovedReferenceFileCount(this.$3.length.toString()));d.log()};d.render=function(){var a=this,c=b("React").createElement("div",{className:"_13br"},h._("Direct viewers back to your Pages or videos when people use your content. {link}",[h._param("link",b("React").createElement("div",{className:"_2yg3",ref:function(b){return a.$1=b}},h._("Learn how it works")))]));return b("React").createElement(b("XUIDialog.react"),{behaviors:{LayerFadeOnHide:b("LayerFadeOnHide"),LayerFadeOnShow:b("LayerFadeOnShow")},width:806,height:600,shown:this.state.isShown,isStrictlyControlled:!0,onHide:function(){return a.$8(!1)}},b("React").createElement(b("XUIDialogTitle.react"),null,this.props.attributionID?h._("Edit Ownership Link"):h._("Create Ownership Link")),b("React").createElement(b("FlexLayout.react"),null,b("React").createElement("div",{className:"_2yg4"},c,b("React").createElement(b("SUIPopover.react"),{alignment:"center",content:b("React").createElement("div",null,b("React").createElement("div",{className:"_qzh"},"How do ownership links work"),"When people use your content, ownership links will appear on their videos.",b("React").createElement("p",null,"Choose any of your Pages or videos for the destination of your ownership link. The link will appear on monitored videos that match the reference files you choose.")),contentWidthUseSparingly:320,hoverContextRef:function(){return a.$1},position:"right",theme:b("SUIBusinessTheme")}),this.props.attributionID?b("React").createElement("div",{className:"_13bs"},b("React").createElement("div",{className:"_13bt"},b("React").createElement(b("SUIToggle.react"),{onClick:this.$10,theme:b("SUIAnalyticsGriffinTheme"),value:!!this.state.isEnabled})),b("React").createElement("div",{className:"_13bu"},this.state.isEnabled?h._("ENABLED"):h._("DISABLED"))):null,b("React").createElement("div",{className:"_2yg5"},b("React").createElement(b("SUITextInput.react"),{theme:b("SUIBusinessTheme"),placeholder:this.state.generatedAttributionName||h._("Name this ownership link"),value:this.state.userInputAttributionName,onChange:this.$9})),b("React").createElement(b("CopyrightAttributionGoalSection.react"),{selectedAttributionType:this.state.selectedAttributionType,onSelectionChanged:this.$5}),b("React").createElement(b("CopyrightAttributionDestinationSection.react"),{userAccessToken:this.props.userAccessToken,pageAccessToken:this.props.pageAccessToken,pageID:this.props.pageID,onSelectionChanged:this.$6,selectedAttributionType:this.state.selectedAttributionType,selectedTargetId:this.state.selectedTargetId,selectedTargetType:this.state.selectedTargetType}),b("React").createElement(b("CopyrightAttributionReferenceFilesSection.react"),{pageID:this.props.pageID,pageAccessToken:this.props.pageAccessToken,attributionID:this.props.attributionID||void 0,initialSelectedCount:this.props.initialSelectedReferenceFileCount||void 0,onSelectionChanged:function(b,c,d){a.$2=b,a.$3=c,a.$4=d}})),b("React").createElement(b("CopyrightAttributionPreviewSection.react"),{selectedAttributionType:this.state.selectedAttributionType,linkTitle:this.state.selectedTargetType===this.state.selectedAttributionType?this.state.selectedTargetName:null})),b("React").createElement(b("CopyrightAttributionDialogFooter.react"),{canSubmit:this.state.selectedTargetId!=null&&this.state.selectedTargetType===this.state.selectedAttributionType&&(this.state.generatedAttributionName!=null||this.state.userInputAttributionName!=null&&this.state.userInputAttributionName.trim().length>0),isEditMode:!!this.props.attributionID,onSubmit:this.$7}))};return c}(b("React").Component);a.defaultProps={attributionName:"",attributionTargetName:"",attributionType:"PAGE",isEnabled:!0};e.exports=a}),null); __d("VideoCopyrightAttributionSelector.react",["cx","fbt","AdsSelectorWithTooltips.react","CopyrightAttributionDialogV2.react","GraphAPI","Link.react","LoadingIndicator.react","PageContentTabAccessToken","PageContentTabRightsManagerStore","React","VideoCopyrightUtils","XUIText.react","cxMargin","formatDate","keyMirror","parseISODate","promiseDone"],(function(a,b,c,d,e,f,g,h){__p&&__p();var i=b("keyMirror")({CREATE:null,DEFAULT:null}),j={id:i.CREATE,title:h._("Create new Ownership Link..."),is_enabled:!0},k=30,l=100;a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var b,c;for(var d=arguments.length,e=new Array(d),f=0;f1?c.$7(b[0].id):c.props.selectedAttribution&&c.$7(c.props.selectedAttribution,!0)});this.props.onAttributionLoaded&&this.props.onAttributionLoaded()};d.$3=function(){__p&&__p();var a=this;b("promiseDone")(b("GraphAPI")(b("VideoCopyrightUtils").GRAPH_API_VERSION,e.id).me().edge("accounts").get({access_token:b("PageContentTabRightsManagerStore").getUserAccessToken(),is_promotable:!0,fields:["name"]}),function(c){if(!a.$1)return;var d=c.data.map(function(a){return{attribution_target_name:a.name,attribution_type:"PAGE",id:a.id,is_enabled:!0,title:a.name}}),f=a.props.selectedAttribution;c=d.some(function(a){return a.id===f});f&&!c?b("promiseDone")(b("GraphAPI")(b("VideoCopyrightUtils").GRAPH_API_VERSION,e.id).object("page",f).get({is_promotable:!0,fields:["name"]}),function(b){d.push({id:b.id,title:b.name,is_enabled:!0}),a.$6(!1,d)}):a.$6(!1,d)})};d.$7=function(a,b){var c,d;if(a===i.CREATE){this.$8();return}else a===i.DEFAULT?c=null:(c=a,d=this.state.attributions.find(function(b){return b.id===a}));var e=this.$5();(b||c!==e)&&this.props.onChange(c,d)};d.$10=function(a){if(a&&a.creation_time&&a.attribution_type){var c=a.creation_time;c=c?b("formatDate")(b("parseISODate")(c),"M j, Y"):"-";var d=a.attribution_type==="PAGE"?h._("Follow"):h._("Link");return b("React").createElement("div",{className:"_2pi8 _2pic _2pin"},b("React").createElement("div",null,h._("{=Type}: {attribution type}",[h._param("=Type",b("React").createElement("b",null,h._("Type"))),h._param("attribution type",d)])),b("React").createElement("div",null,h._("{=Created}: {creation date}",[h._param("=Created",b("React").createElement("b",null,h._("Created"))),h._param("creation date",c)])),b("React").createElement("div",{className:"_3-8-"},b("React").createElement("li",null,h._({"*":"{number} connected reference files","_1":"1 connected reference file"},[h._plural(a.copyright_count||0,"number")]))))}return null};d.$8=function(){this.setState({isAttributionDialogShown:!0})};d.render=function(){__p&&__p();var a=this;if(this.state.isLoading)return b("React").createElement(b("LoadingIndicator.react"),{size:"small",color:"white"});var c;this.props.customDefaultLabel?c=this.props.customDefaultLabel:this.$2()?c=h._("Choose Page"):c=h._("Select Ownership Link");c={id:i.DEFAULT,title:c,is_enabled:!0};c=[c].concat(this.state.attributions);var d;this.$2()||(this.props.showCreateNewLink?d=b("React").createElement(b("Link.react"),{onClick:function(){return a.$7(i.CREATE)}},b("React").createElement(b("XUIText.react"),{className:"_2pis",size:"meta1",weight:"bold"},h._("Create New"))):c.push(j));var e=this.$5()||i.DEFAULT;c=c.map(function(c){var d=c.title;d.toString().length>k&&(d=d.toString().substring(0,k)+"...");return b("React").createElement(b("AdsSelectorWithTooltips.react").Option,{key:c.id,value:c.id,tooltip:a.$2()?null:a.$10(c),isDisabled:!c.is_enabled},d)});var f=null;(!this.props.pageAccessTokenPromise||this.state.pageAccessToken!=="")&&(f=b("React").createElement(b("CopyrightAttributionDialogV2.react"),{onClose:this.$11,pageID:this.props.pageID,pageAccessToken:this.state.pageAccessToken!==""?this.state.pageAccessToken:this.props.accessToken||b("PageContentTabAccessToken").getAccessToken(),userAccessToken:b("PageContentTabRightsManagerStore").getUserAccessToken()}));return b("React").createElement("div",{className:this.props.className},b("React").createElement(b("AdsSelectorWithTooltips.react"),{isDisabled:this.props.disabled,onChange:this.$9,value:e,maxHeight:400,errorMessage:this.props.hasError?h._("Your reference file must have a title in order to apply an attribution."):null},c),d,this.state.isAttributionDialogShown?f:null)};return c}(b("React").Component);e.exports=a}),null); __d("VideoCopyrightMonitoringSelector.react",["fbt","PageContentTabRightsManagerStore","React","Tooltip.react","VideoCopyrightMonitoringType","VideoCopyrightUtils","XUISelector.react"],(function(a,b,c,d,e,f,g){__p&&__p();var h=b("XUISelector.react").Option;a=b("React").PropTypes;c=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){var a=this.props.validMonitoringTypes||Object.keys(b("VideoCopyrightMonitoringType")),c=b("PageContentTabRightsManagerStore").getIsRMLite();this.props.rmVersion!=null&&(c=this.props.rmVersion==="LITE");a=a.map(function(a){a=b("VideoCopyrightMonitoringType")[a];return b("React").createElement(h,{key:a.value,value:a.value},a.label)});return b("React").createElement(b("Tooltip.react"),{tooltip:c?g._("Only video content can be monitored"):""},b("React").createElement(b("XUISelector.react"),{className:this.props.className,disabled:this.props.disabled||c,onChange:this.props.onChange,value:this.props.value,defaultValue:b("VideoCopyrightUtils").DEFAULT_MONITORING_TYPE},a))};return c}(b("React").Component);c.propTypes={className:a.string,disabled:a.bool,onChange:a.func,value:a.string,validMonitoringTypes:a.array};e.exports=c}),null); __d("PageContentTabShowsStore",["EventEmitter","GraphAPI","PageContentTabAccessToken","PageContentTabConstants","PageContentTabDispatcher","promiseDone"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("PageContentTabConstants").ACTION_TYPES;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){var c;c=a.call(this)||this;c.$PageContentTabShowsStore1=void 0;c.$PageContentTabShowsStore2={videoListDescription:null,videoListTitle:null,videosCount:0};b("PageContentTabDispatcher").register(c.handleDispatcherPayload.bind(babelHelpers.assertThisInitialized(c)));return c}var d=c.prototype;d.getVideoListID=function(){return this.$PageContentTabShowsStore1};d.getVideoListHeaderInfo=function(){return this.$PageContentTabShowsStore2};d.handleDispatcherPayload=function(a){__p&&__p();a=a.action;switch(a.actionType){case g.SET_VIDEO_LIST_ID:this.$PageContentTabShowsStore1=a.videoListID;break;case g.SET_VIDEO_LIST_HEADER_INFO:this.$PageContentTabShowsStore2=a.headerInfo;break;case g.REQUEST_VIDEO_LIST_HEADER_INFO:this.$PageContentTabShowsStore3(a.tab);break;default:return}this.emit("changed",a.pageID,a.tab)};d.$PageContentTabShowsStore3=function(a){var c=this.$PageContentTabShowsStore1;if(!c)return;b("promiseDone")(b("GraphAPI")("2.8",e.id).object("video_list",c).get({access_token:b("PageContentTabAccessToken").getAccessToken(),fields:["id","videos_count","thumbnail","season_number","description","title"]}).then(function(c){b("PageContentTabDispatcher").handleSetVideoListHeaderInfo(a,{videoListDescription:c.description,videoListTitle:c.title,videosCount:c.videos_count,seasonNumber:c.season_number,thumbnail:c.thumbnail})}))};return c}(b("EventEmitter"));e.exports=new a()}),null); __d("MediaManagerContentActions",["MediaManagerActionTypes","MediaManagerDispatcher"],(function(a,b,c,d,e,f){"use strict";__p&&__p();var g=b("MediaManagerActionTypes").MediaManagerActionTypes;e.exports={selectContentTable:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.SELECT_CONTENT_TABLE,contentTable:a,source:c})},loadMultipleContentTablesStart:function(a){a.forEach(function(a){b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})})},loadContentTableStart:function(a){b("MediaManagerDispatcher").dispatch({type:g.CLEAR_CONTENT_TABLE_FILTERS,table:a}),b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})},clearContentTableSearchString:function(a){b("MediaManagerDispatcher").dispatch({type:g.CLEAR_CONTENT_TABLE_SEARCH_STRING,table:a})},loadContentTableFinished:function(a,c,d,e){b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_FINISHED,table:a,rows:c,nextPagePromise:d,summary:e})},handleSortChanged:function(a,c,d){b("MediaManagerDispatcher").dispatch({type:g.CONTENT_TABLE_SORT_CHANGED,table:a,orderBy:c,defaultOrderDirection:d}),b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})},selectRows:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.CONTENT_TABLE_SELECT_ROWS,table:a,rows:c})},unselectRows:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.CONTENT_TABLE_UNSELECT_ROWS,table:a,rows:c})},refreshRowsStart:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.CONTENT_TABLE_REFRESH_ROWS_START,table:a,rows:c})},refreshRowsFinished:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.CONTENT_TABLE_REFRESH_ROWS_FINISHED,table:a,rowsByIDs:c})},selectStatusFilterOnly:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.SELECT_CONTENT_STATUS_FILTER,table:a,status:c})},selectStatusFilter:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.SELECT_CONTENT_STATUS_FILTER,table:a,status:c}),b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})},selectWagerStatusFilter:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.SELECT_WAGER_STATUS_FILTER,table:a,status:c}),b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})},selectTypeFilter:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.SELECT_CONTENT_TYPE_FILTER,table:a,contentType:c}),b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})},selectCustomFilter:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.SELECT_CONTENT_CUSTOM_FILTER,table:a,field:c})},selectColumnPreset:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.SELECT_COLUMN_PRESET,table:a,selectedPreset:c})},applyCustomFilter:function(a,c,d){b("MediaManagerDispatcher").dispatch({type:g.APPLY_CONTENT_CUSTOM_FILTER,table:a,filters:c,customFilterActionType:d}),b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})},applyCustomFilterWithOptions:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.APPLY_CONTENT_CUSTOM_FILTER_WITH_OPTIONS,table:a,filter:c}),b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})},selectDateRange:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.SELECT_CONTENT_DATE_RANGE,table:a,dateRange:c}),b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})},setSearchString:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.SET_CONTENT_SEARCH_STRING,table:a,searchString:c}),b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_START,table:a})},loadNextPage:function(a){b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_NEXT_PAGE,table:a})},removeRows:function(a,c){a.forEach(function(a){return b("MediaManagerDispatcher").dispatch({type:g.CONTENT_TABLE_REMOVE_ROWS,table:a,rows:c})})},loadContentTableError:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.LOAD_CONTENT_TABLE_ERROR,table:a,error:c})},prependRowToLoad:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.CONTENT_TABLE_PREPEND_ROWS_TO_LOAD,table:a,rowsToLoad:c})},addRowToRefreshingRows:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.ADD_ROW_TO_REFRESHING_ROWS,table:a,rows:c})},dismissNux:function(){b("MediaManagerDispatcher").dispatch({type:g.CONTENT_DISMISS_NUX})},clearTable:function(a){b("MediaManagerDispatcher").dispatch({type:g.CLEAR_CONTENT_TABLE,table:a})},attemptPublishAllDraftNoStoryPMVs:function(a,c){b("MediaManagerDispatcher").dispatch({type:g.PMV_ATTEMPT_PUBLISH_ALL_NO_STORY_DRAFTS,pageID:c})},confirmPublishAllDraftNoStoryPMVs:function(a){b("MediaManagerDispatcher").dispatch({type:g.PMV_CONFIRM_PUBLISH_ALL_NO_STORY_DRAFTS,pageID:a})}}}),null); __d("PostExpireDialog.react",["fbt","PostExpireDialogBody.react","React","ReactLayeredComponentMixin_DEPRECATED","XUIDialog.react","XUIDialogBody.react","XUIDialogTitle.react"],(function(a,b,c,d,e,f,g){"use strict";__p&&__p();a=b("React").PropTypes;var h=343;c=b("React").createClass({displayName:"PostExpireDialog",mixins:[b("ReactLayeredComponentMixin_DEPRECATED")],propTypes:{originalExpirationTimestamp:a.number,originalExpirationType:a.number,timezone:a.string.isRequired,postID:a.number,pageID:a.number,onSubmit:a.func.isRequired,isRepublish:a.bool,submitLabel:a.string,hideExpirationToggle:a.bool},getInitialState:function(){return{shown:!1}},render:function(){return b("React").createElement("div",null)},renderLayers:function(){var a=this.props.isRepublish?g._("Republish"):g._("Edit Expiration");return b("React").createElement(b("XUIDialog.react"),{shown:this.state.shown,width:h},b("React").createElement(b("XUIDialogTitle.react"),null,a),b("React").createElement(b("XUIDialogBody.react"),null,b("React").createElement(b("PostExpireDialogBody.react"),this.props)))},show:function(){this.setState({shown:!0})},hide:function(){this.setState({shown:!1})}});e.exports=c}),null); __d("XVideoEditMakeFeaturedController",["XController"],(function(a,b,c,d,e,f){e.exports=b("XController").create("/video/edit/feature/",{v:{type:"FBID",required:!0},is_videos_tab:{type:"Bool",defaultValue:!1}})}),null); __d("ModernScheduledVideoAnnouncementSubscribeMutation",["RelayModern","ModernScheduledVideoAnnouncementSubscribeMutation.graphql"],(function(a,b,c,d,e,f){"use strict";var g=b("RelayModern").commitMutation;b("RelayModern").graphql;var h=function(){return b("ModernScheduledVideoAnnouncementSubscribeMutation.graphql")};function a(a,b,c){return g(a,{mutation:h,variables:{input:{actor_id:b.actorID,video_announcement_id:b.announcementID,subscribe:b.subscribe}},onCompleted:c&&c.onCompleted,onError:c&&c.onError})}e.exports={commit:a}}),null); __d("ScheduledVideoAnnouncementAttachment.react",["ix","cx","fbt","CssBackgroundImage.react","CurrentUser","Image.react","ModernScheduledVideoAnnouncementSubscribeMutation","React","RelayFBEnvironment","VideoLink.react","XUIButton.react","fbglyph","formatDate"],(function(a,b,c,d,e,f,g,h,i){__p&&__p();a=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){__p&&__p();var d;d=a.call(this,c)||this;d.$1=function(){var a=d.props.announcementID;if(!a)return;b("ModernScheduledVideoAnnouncementSubscribeMutation").commit(b("RelayFBEnvironment"),{actorID:b("CurrentUser").getAccountID(),announcementID:a,subscribe:!d.state.isSubscribed},{onCompleted:function(a){a=((a=a)!=null?(a=a.scheduled_video_announcement_subscribe)!=null?a.subscribed:a:a)||!1;d.setState({buttonDisabled:!1,isSubscribed:a})}})};d.$2=function(){if(d.props.videoLinkData)return;d.setState({buttonDisabled:!0},d.$1)};d.state={buttonDisabled:!1,isSubscribed:c.isSubscribed};return d}var d=c.prototype;d.$3=function(){var a=Boolean(this.props.videoLinkData),c=this.state.isSubscribed,d=null,e=null;a?d=i._("Watch Now"):c?(d=i._("Reminder Set"),e=b("React").createElement(b("Image.react"),{src:g("114568")})):d=i._("Remind Me");c=b("React").createElement(b("XUIButton.react"),{className:"_23za"+(c?" _23zc":"")+(a?" _23zd":""),disabled:this.state.buttonDisabled,image:e,label:d,onClick:this.$2});if(a)return b("React").createElement(b("VideoLink.react"),this.props.videoLinkData,c);else return c};d.$4=function(){return this.props.videoLinkData?i._("Now Released"):b("formatDate")(this.props.scheduledTime,"g:ia M j")};d.$5=function(){return b("React").createElement("div",null,b("React").createElement("div",{className:"_23zh"},b("React").createElement(b("Image.react"),{className:"_23zj",src:this.props.showmarkURI}),b("React").createElement("div",{className:"_23zk"},this.$4()),b("React").createElement("div",{className:"_23zl"},this.props.title)),b("React").createElement("div",{className:"_23zm"},this.$3()))};d.render=function(){return b("React").createElement(b("CssBackgroundImage.react"),{className:"_23zn"+(this.props.isPreview?" _3q2v":""),imageURI:this.props.backgroundImageURI},b("React").createElement("div",{className:"_23zo"},b("React").createElement("div",{className:"_23zp"},this.$5())))};return c}(b("React").Component);e.exports=a}),null); __d("VideoScheduleAnnouncementPostPreview.react",["cx","fbt","CenteredContainer.react","ComposerVideoUploadStore","PrivacyConst","React","ScheduledVideoAnnouncementAttachment.react","StoryProfile.react","XUIGrayText.react","XUIText.react","cxMargin"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){return a.apply(this,arguments)||this}var d=c.prototype;d.render=function(){if(!this.props.showPreview)return b("React").createElement(b("CenteredContainer.react"),{className:"_3xz4",fullHeight:!0,vertical:!0},b("React").createElement(b("XUIGrayText.react"),{size:"meta1"},h._("Select Announcement Post in order to see preview")));var a=this.props.config,c=a.profilePic,d=a.profileURL;a=a.profileName;var e=this.props.composerID,f=b("ComposerVideoUploadStore").getTitle(e);e=b("ComposerVideoUploadStore").getThumbnail(e);return b("React").createElement("div",{className:"_3xz5"},b("React").createElement(b("StoryProfile.react"),{profilePicture:c,profileURL:d,username:a,uploadTime:h._("Just Now"),description:h._("scheduled a new video"),privacySetting:b("PrivacyConst").BaseValue.EVERYONE}),b("React").createElement(b("XUIText.react"),{className:"_3-8o",display:"block"},this.props.title),b("React").createElement(b("ScheduledVideoAnnouncementAttachment.react"),{isSubscribed:!1,scheduledTime:this.props.scheduledTime/1e3,title:f,backgroundImageURI:e.getURL(),isPreview:!0}))};return c}(b("React").Component);e.exports=a}),null); __d("VideoEditMentionsTextArea.react",["cx","AtSignMentionsStrategy","DocumentCompositeMentionsSource","DocumentMentionsSource","EditorState","MentionsInput.react","MentionsInputTypeaheadView.react","MentionsInputUtility","React","getMentionsInputDecorator","joinClasses"],(function(a,b,c,d,e,f,g){__p&&__p();a=b("React").PropTypes;c=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){__p&&__p();var d;d=a.call(this,c)||this;d.$1=function(a){if(d.props.disabled)return;d.setState({editorState:a});d.props.onChange(a)};d.focus=function(){d.refs.mentionsInput.focus()};var e=new(b("DocumentMentionsSource"))(b("AtSignMentionsStrategy"),c.searchSource);e=new(b("DocumentCompositeMentionsSource"))([e]);var f=c.textWithMentions,g;c.editorState?g=c.editorState:f?g=b("MentionsInputUtility").createFromTextWithMentions(f,b("getMentionsInputDecorator")()):g=b("EditorState").createEmpty(b("getMentionsInputDecorator")());c.onChange(g);d.state={compositeMentionsSource:e,editorState:g};return d}var d=c.prototype;d.render=function(){var a=b("joinClasses")("_2oc3",this.props.className);return b("React").createElement(b("MentionsInput.react"),{className:a,editorState:this.state.editorState,mentionsSource:this.state.compositeMentionsSource,placeholder:this.props.placeholder,typeaheadView:b("MentionsInputTypeaheadView.react"),typeaheadViewProps:{},onChange:this.$1,ref:"mentionsInput"})};return c}(b("React").Component);c.propTypes={disabled:a.bool};c.defaultProps={disabled:!1};e.exports=c}),null); __d("VideoScheduleAnnouncementPostSection.react",["cx","fbt","EditorState","Image.react","InputLabel.react","Layout.react","MentionsInputUtility","React","VideoEditMentionsTextArea.react","XUICheckboxInput.react","getMentionsInputDecorator","getMentionsTextForContentState","cxMargin"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=b("Layout.react").Column,j=b("Layout.react").FillColumn;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(c){var d;d=a.call(this,c)||this;d.onMessageChange=function(a){var c=b("getMentionsTextForContentState")(a.getCurrentContent());d.setState({messageEditorState:a});d.props.onChange(d.state.announcementToggle,c)};d.state={announcementToggle:!0,messageEditorState:d.$1(c.message)};return d}var d=c.prototype;d.$1=function(a){return a?b("MentionsInputUtility").createFromTextWithMentions(a,b("getMentionsInputDecorator")()):b("EditorState").createEmpty(b("getMentionsInputDecorator")())};d.render=function(){var a=this,c=b("React").createElement(b("XUICheckboxInput.react"),{checked:this.state.announcementToggle,onChange:function(){a.props.onChange(!a.state.announcementToggle),a.setState({announcementToggle:!a.state.announcementToggle})}});return b("React").createElement("div",{className:"_3-8-"},b("React").createElement(b("InputLabel.react"),{label:h._("Announcement Post")},c),this.$2())};d.$2=function(){return!this.state.announcementToggle?null:b("React").createElement("div",{className:"_3-8x _t0j"},b("React").createElement(b("Layout.react"),{className:"_2rgz"},b("React").createElement(i,{className:"_2rg-"},b("React").createElement(b("Image.react"),{src:this.props.profilePic})),b("React").createElement(j,null,b("React").createElement(b("VideoEditMentionsTextArea.react"),{className:"_2rg_",placeholder:h._("Say something about this upcoming video..."),searchSource:this.props.mentionsSource,editorState:this.state.messageEditorState,onChange:this.onMessageChange,textWithMentions:this.props.message}))))};return c}(b("React").Component);e.exports=a}),null); __d("PostScheduleAndPostEndDialog.react",["ix","cx","fbt","ComposerEntryPointRef","DatePickerRestraints","DateTimeBlock.react","Image.react","InputLabel_DEPRECATED.react","InputLabel.react","InputLabelLabel_DEPRECATED.react","Layout.react","Link.react","PagesComposerWWWInterceptionHandler","PagesComposerWWWInterceptionHandlerUtils","PagesComposerWWWInterceptionUtils","React","ReactComposerAttachmentStore","ReactComposerPagesStore","ReactLayeredComponentMixin_DEPRECATED","SUIBusinessTheme","SUINotice.react","VideoScheduleAnnouncementPostPreview.react","VideoScheduleAnnouncementPostSection.react","XPagesManagerInsightsController","XUIAmbientNUX.react","XUICheckboxInput.react","XUIDateTimePicker.react","XUIDialog.react","XUIDialogBody.react","XUIDialogButton.react","XUIDialogCancelButton.react","XUIDialogFooter.react","XUIDialogTitle.react","XUIGrayText.react","XUINotice.react","XUIRadioInput.react","XUISpinner.react","XUIText.react","fbglyph","cxMargin","getObjectValues"],(function(a,b,c,d,e,f,g,h,i){__p&&__p();var j=b("PagesComposerWWWInterceptionHandler").PagesComposerWWWInterceptionHandler,k=b("PagesComposerWWWInterceptionHandlerUtils").evaluatePartnerConfigsForInterception,l=b("PagesComposerWWWInterceptionHandlerUtils").mapInterceptionEnumProductKeyFromValue,m=b("Layout.react").Column,n=b("Layout.react").FillColumn;a=b("React").PropTypes;var o=60*1e3,p=60*o,q=24*60*60*1e3;c=30;var r=6*c*q,s=11,t=450,u=857,v=325,w=Object.freeze({SUGGESTED:"suggested",CUSTOM:"custom"}),x="ready",y="loading",z="failed";d=b("React").createClass({displayName:"PostScheduleAndPostEndDialog",mixins:[b("ReactLayeredComponentMixin_DEPRECATED")],propTypes:{initialPublishDate:a.instanceOf(Date),initialPostEndDate:a.instanceOf(Date),isReschedule:a.bool,marginTop:a.number,timezoneStr:a.string.isRequired,onSubmit:a.func.isRequired,defaultScheduledTimeDelta:a.number,showPostEndDate:a.bool,showExpire:a.bool,showExpireNux:a.bool,onNuxAcked:a.func,submitLabel:a.string,canCreateAnnouncementPost:a.bool,announcementPostConfig:a.object,composerID:a.string,showComposerFooterRedesign:a.bool,targetID:a.string,entryPoint:a.oneOf(b("getObjectValues")(b("ComposerEntryPointRef")))},getDefaultProps:function(){return{defaultScheduledTimeDelta:s*o,showPostEndDate:!0}},componentDidMount:function(){var a=this;this.isInterceptionEligible()&&(this.setState({scheduleSuggestionState:y}),j.performIntercept(this.props.composerID,this.props.targetID,"composer_schedule_post",function(b){return a.getSuggestedTime(b)}))},getInitialState:function(){return{shown:!1,publishDate:this.props.initialPublishDate?this.props.initialPublishDate:new Date(Date.now()+this.props.defaultScheduledTimeDelta),selectedCustomDate:this.props.initialPublishDate?this.props.initialPublishDate:new Date(Date.now()+this.props.defaultScheduledTimeDelta),selectedSuggestedDate:null,postEndDate:this.props.initialPostEndDate?this.props.initialPostEndDate:new Date(Date.now()+p),scheduleToggle:!0,scheduleType:w.SUGGESTED,postEndToggle:!1,expireDate:new Date(Date.now()+p),expireToggle:!1,expirationType:2,showNux:!1,announcementToggle:this.props.canCreateAnnouncementPost,announcementTitle:this.props.announcementPostConfig?this.props.announcementPostConfig.defaultMessage:""}},isInterceptionEligible:function(){var a=this.props.composerID;if(!a||!this.shouldShowScheduleSuggestions())return!1;var c=b("ReactComposerAttachmentStore").getSelectedAttachmentID(a),d=b("ReactComposerPagesStore").getCurrentLocale(a);if(!c||!d)return!1;a=k(a,b("ReactComposerPagesStore").getInterceptionConfig(a),c,d,"composer_schedule_post");return a.includes(l("schedule_post_time"))},getSuggestedTime:function(a){if(!a.shouldPerformInterception||!a.bestExtractedStartTime)this.setState(function(a){return{publishDate:a.selectedCustomDate,scheduleSuggestionState:z,scheduleType:w.CUSTOM}});else{a=new Date(a.bestExtractedStartTime*1e3);this.setState({scheduleSuggestionState:x,selectedSuggestedDate:a,publishDate:a})}},shouldShowScheduleSuggestions:function(){switch(this.props.entryPoint){case"page_content_tab_published_posts":case"page_content_tab_drafts":case"page_content_tab_scheduled_posts":case"pages_feed":case"pages_posts":return!0;default:return!1}},show:function(){var a=this.getInitialState();a.showNux=this.props.showExpireNux;a.shown=!0;this.setState(a)},_onNuxClose:function(){this.setState({showNux:!1}),this.props.onNuxAcked&&this.props.onNuxAcked()},renderLayers:function(){var a=this.props.isReschedule?i._("Reschedule Post"):i._("Schedule Post"),c=this.props.submitLabel?this.props.submitLabel:this.state.scheduleToggle?this.props.isReschedule?i._("Reschedule"):i._("Schedule"):i._("Publish"),d=null;this.state.showNux&&this.refs.expirationToggle&&(d=b("React").createElement(b("XUIAmbientNUX.react"),{contextRef:this._getContextRef,onCloseButtonClick:this._onNuxClose,position:"left",shown:!0},i._("You can now choose when your post will unpublish.")));var e=this._renderInvalidTimeNotice();return b("React").createElement("div",null,b("React").createElement(b("XUIDialog.react"),{shown:this.state.shown,width:this.props.canCreateAnnouncementPost?u:t,fixedTopPosition:this.props.marginTop||v,className:"_yjl"},b("React").createElement(b("XUIDialogTitle.react"),null,a),b("React").createElement(b("XUIDialogBody.react"),{className:"_hg8"},this._renderBody(e)),b("React").createElement(b("XUIDialogFooter.react"),null,b("React").createElement(b("XUIDialogCancelButton.react"),{className:"_3-90"}),b("React").createElement(b("XUIDialogButton.react"),{action:"confirm",label:c,onClick:this._onSubmitClick,disabled:e!==null,use:"confirm"}))),d)},_renderToolTip:function(){return this.props.showComposerFooterRedesign?b("React").createElement(b("SUINotice.react"),{margin:"_3-96",theme:b("SUIBusinessTheme"),type:"information"},i._("Scheduled posts will only appear on your Page Timeline and on News Feed.")):null},_renderBody:function(a){return this.props.canCreateAnnouncementPost?b("React").createElement(b("Layout.react"),null,b("React").createElement(m,null,this._renderScheduledForm(a)),b("React").createElement(n,null,this._renderAnnouncementPostPreview())):this._renderScheduledForm(a)},_renderAnnouncementPostPreview:function(){return b("React").createElement("div",{className:"_yjn"},b("React").createElement("div",null,b("React").createElement(b("Image.react"),{src:g("126073")}),b("React").createElement(b("XUIGrayText.react"),{size:"meta1",weight:"bold",className:"_yko"},i._("Announcement Preview"))),b("React").createElement(b("VideoScheduleAnnouncementPostPreview.react"),{config:this.props.announcementPostConfig||{},showPreview:this.state.announcementToggle,title:this.state.announcementTitle,scheduledTime:this.state.publishDate.getTime(),composerID:this.props.composerID}))},_renderScheduledForm:function(a){var c=this;return b("React").createElement("div",{className:"_ykp"},this._renderToolTip(),b("React").createElement("div",{className:"_t0h"},b("React").createElement(b("XUIText.react"),{size:"header4",weight:"bold"},i._("Publishing Schedule"))),b("React").createElement(b("InputLabel.react"),{label:i._("Publication")},b("React").createElement(b("XUICheckboxInput.react"),{checked:this.state.scheduleToggle,onChange:function(){return c.setState({scheduleToggle:!c.state.scheduleToggle})}})),b("React").createElement(b("XUIGrayText.react"),{shade:"light",size:"meta1",display:"block",className:"_t0j"},i._("Select a date and time in the future to publish your post.")),this.isInterceptionEligible()?this._renderScheduleAdvanced():this._renderSchedule(),this._renderAnnouncementPostSection(),this._renderExpireSection(),this._renderPostEndSection(),a)},_isPublishTimeValid:function(){if(!this.state.scheduleToggle)return!0;var a=this.state.publishDate.getTime(),b=Date.now()+10*o,c=Date.now()+r;return a>b&&a=c&&a<=d},_renderSchedule:function(){var a=this;return!this.state.scheduleToggle?null:b("React").createElement("div",null,b("React").createElement(b("XUIDateTimePicker.react"),{allowEmpty:!1,dateRestraints:[b("DatePickerRestraints").enforceDateIsNoEarlierThan(new Date(Date.now()-q)),b("DatePickerRestraints").enforceDateIsNoLaterThan(new Date(Date.now()+r))],className:"_3-8x _t0j",date:this.state.publishDate,onChange:function(b){return a.setState({publishDate:b})},timezone:this.props.timezoneStr}))},_renderScheduleAdvanced:function(){return!this.state.scheduleToggle?null:b("React").createElement("div",null,this._renderScheduleSuggested(),this._renderScheduleCustom())},_renderScheduleCustom:function(){var a=this;return b("React").createElement("div",{className:"_8gmd"},b("React").createElement(b("InputLabel.react"),{label:i._("Custom")},b("React").createElement(b("XUIRadioInput.react"),{checked:this.state.scheduleType===w.CUSTOM,onChange:function(){return a.setState(function(a){return{scheduleType:w.CUSTOM,publishDate:a.selectedCustomDate}})},value:w.CUSTOM})),b("React").createElement(b("XUIGrayText.react"),{shade:"light",size:"meta1",display:"block",className:"_t0j"}," ",i._("Choose the date and time you want to publish your post.")),b("React").createElement("div",{className:this.state.scheduleType!==w.CUSTOM?"_8gme":""},b("React").createElement(b("XUIDateTimePicker.react"),{allowEmpty:!1,dateRestraints:[b("DatePickerRestraints").enforceDateIsNoEarlierThan(new Date(Date.now()-q)),b("DatePickerRestraints").enforceDateIsNoLaterThan(new Date(Date.now()+r))],date:this.state.selectedCustomDate,onChange:function(b){return a.setState({publishDate:b,selectedCustomTime:b})},timezone:this.props.timezoneStr})))},_renderScheduleSuggested:function(){var a=this,c=b("XPagesManagerInsightsController").getURIBuilder().setString("page_token",this.props.targetID).setString("section","navPosts").getURI();return b("React").createElement("div",{className:"_8gmf"},b("React").createElement(b("InputLabel.react"),{label:i._("Suggested")},b("React").createElement(b("XUIRadioInput.react"),{checked:this.state.scheduleType===w.SUGGESTED,disabled:this.state.scheduleSuggestionState===z,onChange:function(){return a.setState(function(a){return{scheduleType:w.SUGGESTED,publishDate:a.selectedSuggestedDate}})},value:w.SUGGESTED})),b("React").createElement(b("XUISpinner.react"),{background:"light",className:this.state.scheduleSuggestionState!==y?"hidden_elem":"",size:"small"}),b("React").createElement("div",{className:this.state.scheduleSuggestionState!==z?"hidden_elem":""},b("React").createElement(b("XUIGrayText.react"),{shade:"light",size:"meta1",display:"block",className:"_t0j"}," ",i._("The suggested post time isn't available right now. {=See Details}",[i._param("=See Details",b("React").createElement(b("Link.react"),{target:"_blank",href:c},i._("See Details")))]))),b("React").createElement("div",{className:this.state.scheduleSuggestionState!==x?"hidden_elem":""},b("React").createElement(b("XUIGrayText.react"),{shade:"light",size:"meta1",display:"block",className:"_t0j"}," ",i._("Schedule your post based on when your fans were most active last week. {=See Details}",[i._param("=See Details",b("React").createElement(b("Link.react"),{target:"_blank",href:c},i._("See Details")))])),b("React").createElement(b("DateTimeBlock.react"),{className:"_3-90",dateTime:this.state.selectedSuggestedDate,selectable:!0,selected:!0,onClick:function(a){return{publishDate:a.selectedSuggestedDate}},timezone:this.props.timezoneStr,disabled:this.state.scheduleType!==w.SUGGESTED})))},_renderAnnouncementPostSection:function(){if(!this.props.canCreateAnnouncementPost||!this.state.scheduleToggle)return null;var a=this.props.announcementPostConfig||{};return b("React").createElement(b("VideoScheduleAnnouncementPostSection.react"),{message:this.state.announcementTitle,mentionsSource:a.mentionsSource,profilePic:a.profilePic,onChange:this._onAnnouncementChange})},_onAnnouncementChange:function(a,b){b!==void 0?this.setState({announcementTitle:b,announcementToggle:a}):this.setState({announcementToggle:a})},_renderExpireSection:function(){var a=this;if(!this.props.showExpire)return null;var c=b("React").createElement(b("XUICheckboxInput.react"),{ref:"expirationToggle",checked:this.state.expireToggle,onChange:function(){return a.setState({expireToggle:!a.state.expireToggle,showNux:!1})}});return b("React").createElement("div",{className:"_3-8-"},b("React").createElement(b("InputLabel.react"),{label:i._("Expiration")},c),b("React").createElement("div",null,b("React").createElement(b("XUIGrayText.react"),{shade:"light",size:"meta1",display:"block",className:"_t0j"},i._("When a post expires, it will no longer be visible to the public. Page admins can still view unpublished posts and their Insights."))),this._renderExpire())},_renderExpire:function(){var a=this;return!this.state.expireToggle?null:b("React").createElement("div",{className:"_3-8x _t0j"},b("React").createElement(b("XUIDateTimePicker.react"),{allowEmpty:!1,dateRestraints:[b("DatePickerRestraints").enforceDateIsNoEarlierThan(new Date(Date.now()-q)),b("DatePickerRestraints").enforceDateIsNoLaterThan(new Date(Date.now()+r))],date:this.state.expireDate,onChange:function(b){return a.setState({expireDate:b})},timezone:this.props.timezoneStr}),b("React").createElement(b("InputLabel_DEPRECATED.react"),{className:"_3-8x"},b("React").createElement(b("XUICheckboxInput.react"),{checked:this.state.expirationType===1,onChange:this._handleExpirationTypeChanged}),b("React").createElement(b("InputLabelLabel_DEPRECATED.react"),null,b("React").createElement(b("XUIGrayText.react"),{shade:"light",size:"meta1",weight:"normal"},i._("Delete the post. Permanently remove the post and its insights at the scheduled time.")))))},_renderPostEndSection:function(){var a=this;if(!this.props.showPostEndDate)return null;var c=b("React").createElement(b("XUICheckboxInput.react"),{ref:"postEndToggle",checked:this.state.postEndToggle,onChange:function(){return a.setState({postEndToggle:!a.state.postEndToggle})}});return b("React").createElement("div",null,b("React").createElement("div",{className:"_t0k"},b("React").createElement(b("XUIText.react"),{size:"header4",weight:"bold"},i._("Distribution Schedule"))),b("React").createElement(b("InputLabel.react"),{label:i._("Stop News Feed Distribution")},c),b("React").createElement(b("XUIGrayText.react"),{shade:"light",size:"meta1",display:"block",className:"_t0j"},i._("Select a date and time in the future for when you want your post to stop showing in News Feed. The post will still be visible, but News Feed distribution will end.")),this._renderPostEndDate())},_renderPostEndDate:function(){var a=this;return!this.state.postEndToggle?null:b("React").createElement("div",{className:"_3-8x _t0j"},b("React").createElement(b("XUIDateTimePicker.react"),{allowEmpty:!1,dateRestraints:[b("DatePickerRestraints").enforceDateIsNoEarlierThan(new Date(Date.now()-q)),b("DatePickerRestraints").enforceDateIsNoLaterThan(new Date(Date.now()+r))],date:this.state.postEndDate,onChange:function(b){return a.setState({postEndDate:b})},timezone:this.props.timezoneStr}))},_renderInvalidTimeNotice:function(){var a=this._isPublishTimeValid(),c=!this.state.postEndToggle||this._isPostEndOrExpireTimeValid(this.state.postEndDate.getTime()),d=!this.state.expireToggle||this._isPostEndOrExpireTimeValid(this.state.expireDate.getTime()),e=a&&c&&d;if(e)return null;e=null;!a?e=i._("Scheduled posts need to be shared between 10 minutes and 6 months from when you create them."):!c&&this.state.scheduleToggle?e=i._("News Feed distribution can only end between 10 minutes from when they are published and 6 months from now."):!c?e=i._("News Feed distribution can only end between 10 minutes and 6 months from when you create them."):!d&&this.state.scheduleToggle?e=i._("Posts need to be expired between 10 minutes from when they are published and 6 months from now."):d||(e=i._("Posts need to be expired between 10 minutes and 6 months from when you create them."));return b("React").createElement(b("XUINotice.react"),{use:"warn",className:"_3-8y"},e)},render:function(){return b("React").createElement("div",null)},_handleExpirationTypeChanged:function(a){a=a.target.checked?1:2;this.setState({expirationType:a})},_onSubmitClick:function(){__p&&__p();var a=null,c=null,d=null,e=null,f=null;if(this.state.scheduleToggle){a=this.state.publishDate;this.props.canCreateAnnouncementPost&&this.state.announcementToggle&&(f=this.state.announcementTitle);var g=this.props.composerID;g&&this.state.scheduleSuggestionState===x&&(this.state.scheduleType===w.SUGGESTED?b("PagesComposerWWWInterceptionUtils").logInterceptionEvent(g,"pages_composer_interception_post_create","schedule_post_time","inline",null,{suggested_schedule_time:this.state.selectedSuggestedDate}):b("PagesComposerWWWInterceptionUtils").logInterceptionEvent(g,"pages_composer_interception_dialog_reject","schedule_post_time","inline",null,{suggested_schedule_time:this.state.selectedSuggestedDate,actual_schedule_time:this.state.publishDate}))}this.state.postEndToggle&&(c=this.state.postEndDate);this.state.expireToggle&&(d=this.state.expireDate,e=this.state.expirationType);this.props.onSubmit(a,c,d,e,f);this.setState({shown:!1})},_getContextRef:function(){return this.refs.expirationToggle}});e.exports=d}),null); __d("WatchPartyAdsPlacement",[],(function(a,b,c,d,e,f){e.exports=Object.freeze({PRE_ROLL:"pre_roll",MID_ROLL:"mid_roll",POST_ROLL:"post_roll",NON_INTERRUPTIVE:"non_interruptive"})}),null); __d("PageScheduledLivingRoomCreateMutation",["LivingRoomActorUtils","RelayFBEnvironment","RelayModern","WatchPartyAdsPlacement","PageScheduledLivingRoomCreateMutation.graphql"],(function(a,b,c,d,e,f){"use strict";var g=b("LivingRoomActorUtils").runWithActorID,h=b("RelayModern").commitMutation;b("RelayModern").graphql;var i=function(){return b("PageScheduledLivingRoomCreateMutation.graphql")};function a(a,c,d){return g(a.target_id,function(){return h(b("RelayFBEnvironment"),{mutation:i,variables:{input:{target_id:a.target_id,custom_name:a.custom_name,video_ids:a.video_ids,creation_source:a.creation_source,scheduled_time:a.scheduled_time,background_image:a.background_image?"background_image":null,live_post_message:a.live_post_message,enabled_ads:a.has_preroll?[b("WatchPartyAdsPlacement").PRE_ROLL]:[]}},uploadables:a.background_image?{background_image:a.background_image}:{},onCompleted:c,onError:d})})}e.exports={commit:a}}),null); __d("ScheduleLivingRoomDialogContainer.react",["cx","fbt","Arbiter","DatePickerRestraints","EditorState","FileInput.react","FluxContainer","Image.react","LivingRoomComposerActions","LivingRoomComposerLogger","LivingRoomComposerStore","LivingRoomHostFunnelLogger","MentionsInput.react","PageScheduledLivingRoomCreateMutation","React","ReactComposerActions","ReactComposerPostButton.react","ReactComposerStatusStore","SimpleXUIDialog","XUIButton.react","XUIDateTimePicker.react","XUIDialog.react","XUIDialogBody.react","XUIDialogButton.react","XUIDialogFooter.react","XUIDialogTitle.react","XUIGrayText.react","XUINotice.react","XUIText.react","XUITypeaheadView.react","cxMargin","getMentionsInputDecorator","getMentionsTextForContentState","gkx","nullthrows"],(function(a,b,c,d,e,f,g,h){__p&&__p();var i=60*1e3,j=24*60*60*1e3;a=30;var k=6*a*j,l=450,m=325;c=function(a){"use strict";__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var c,d;for(var e=arguments.length,f=new Array(e),g=0;gb&&a0&&!b("SimpleNUXMessage").hasUserSeenMessage(b("SimpleNUXMessageTypes").POLITICAL_DISTRICT_TARGETING_COMPOSER_OPTION)},d.$7=function(a){setTimeout(function(){return d.setState({dialogShown:a})},0)},d.$9=function(a,c){var e=b("ReactComposerTargetingUtils").getDataFromComposerTaggerStore(d.context.composerID);e=Object.assign({},e);e.gating=a;e.gatingSentences=c;d.setState({gatingSentences:c});b("ReactComposerTargetingUtils").setData(d.context.composerID,e)},d.$8=function(){d.$9(null,null)},c)||babelHelpers.assertThisInitialized(d)}var d=c.prototype;d.$1=function(){var a=this.context.composerID;a=b("ReactComposerPoliticalInfoUtils").getPoliticalDistrict(a);if(a)return this.$2(a);else if(this.state.gatingSentences)return q;else return p};d.$3=function(a){a.stopPropagation()};d.$4=function(a){var c=j.isTrayBasedPagesComposer(this.props.composerEntryPointRef);if(this.props.useSelectorLink){var d=this.state.gatingSentences?h._("Custom"):h._("Public");d=b("React").createElement(b("Link.react"),{className:"_36w_",onClick:this.$3},d,b("React").createElement(b("Image.react"),{className:"_3-99",src:i("562285")}));return b("React").createElement(b("PopoverMenu.react"),{alignv:"bottom",menu:a,position:c?"above":"below"},">",d)}d=this.state.gatingSentences?o:n;d=b("React").createElement(b("XUISelectorButton.react"),{image:b("React").createElement(b("Image.react"),{src:d}),size:c?"xlarge":"medium",suppressed:!0});return b("React").createElement(b("PopoverMenu.react"),{menu:a,position:c?"above":"below"},d)};d.$2=function(a){return r.concat(a)};d.$5=function(){var a=this,c=[],d=this.props.defaultDemographicsList;d&&d.length>0&&(c.push(b("React").createElement(b("XUIMenuSeparator.react"),null)),d.forEach(function(d){var e=d.targeting_spec.political_district;c.push(b("React").createElement(l,{icon:b("React").createElement(b("Image.react"),{src:o}),onclick:function(){return a.$6(d)},value:a.$2(e)},d.name))}));d=[];this.props.targetingEnabled&&d.push(b("React").createElement(b("XUIMenuSeparator.react"),null),b("React").createElement(b("XUIMenuStaticItem.react"),null,b("React").createElement(b("XUIGrayText.react"),{shade:"light"},h._("Limit Audience By:"))),b("React").createElement(l,{icon:b("React").createElement(b("Image.react"),{src:o}),onclick:function(){a.$7(!0)},value:q},h._("Demographics")));return[b("React").createElement(l,{icon:b("React").createElement(b("Image.react"),{src:n}),onclick:this.$8,value:p},h._("Public"))].concat(c).concat(d)};d.$6=function(a){this.$9(null,b("React").createElement("span",null,a.name))};d.$10=function(){var a=this;return b("React").createElement(b("XUIAmbientNUX.react"),{contextRef:function(){return a},key:"districtTargetingNUX",offsetX:14,onCloseButtonClick:function(){b("SimpleNUXMessage").markMessageSeenByUser(b("SimpleNUXMessageTypes").POLITICAL_DISTRICT_TARGETING_COMPOSER_OPTION),a.setState({showDistrictTargetingNux:!1})},position:"above",shown:this.state.showDistrictTargetingNux},b("DistrictTargetingUtils").getComposerNUXContent())};d.$11=function(a,c){a=c.item.getValue();c=!1;if(a&&a.startsWith(r)){c=!0;a=a.replace(r,"");b("ReactComposerPoliticalInfoUtils").setData(this.context.composerID,this.context.targetID,{isDistrictTargeting:c,politicalDistrict:a});new(b("DistrictTargetingTypedLogger"))().setEvent("audience_option_select").setPageID(this.context.targetID).setDistrictID(a).log()}else b("ReactComposerPoliticalInfoUtils").clear(this.context.composerID,this.context.targetID)};d.render=function(){var a=this;if(this.state.dialogShown)return b("React").createElement(b("PagesComposerAudiences.react"),{enableLanguageGating:this.props.enableLanguageGating,enableLocationExclusionGating:this.props.enableLocationExclusionGating,hideFeedTargeting:this.props.hideFeedTargeting,hideGating:this.props.hideGating,initialActiveKey:m.GATING,onGatingChange:this.$9,onSave:function(){return a.$7(!1)},onToggle:this.$7,shown:this.state.dialogShown,useFromLegacyComposer:this.props.isVideoDialog,useTargetingAsFilter:this.props.useTargetingAsFilter});var c=this.$1(),d=b("ReactSelectorUtils").processMenuItems(this.$5(),c);c=b("React").createElement(k,{onItemClick:function(b,c){return a.$11(b,c)},value:c},d.items);return b("React").createElement(b("Tooltip.react"),{tooltip:this.state.gatingSentences},b("React").createElement("div",{className:"_5dd8"},this.$4(c),this.$10()))};return c}(b("React").PureComponent);a.contextTypes=b("ReactComposerContextTypes");e.exports=a}),null); __d("TargetingGatingUtils",[],(function(a,b,c,d,e,f){"use strict";a={convertConnectionsToInterestsFromApiToTargetingSpec:function(a){a&&a.connections&&!a.fan_of&&(a.fan_of=a.connections,delete a.connections);return a},convertInterestsToConnectionsFromTargetingSpecToApi:function(a){a&&a.fan_of&&!a.connections&&(a.connections=a.fan_of,delete a.fan_of);return a}};e.exports=a}),null); __d("PagesComposerGatingDialog.react",["cx","fbt","JSResource","LayerFadeOnHide","React","ReactComposerContextTypes","ReactComposerTargetingUtils","SUIBusinessTheme","SUINotice.react","TargetingGatingUtils","XUIDialog.react","XUIDialogBody.react","XUIDialogCancelButton.react","XUIDialogFooter.react","XUIDialogSaveButton.react","XUIDialogTitle.react","XUISpinner.react","XUIText.react","areEqual","gkx","isEmpty","lazyLoadComponent"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=b("gkx")("678710"),j=13,k=587,l=b("lazyLoadComponent")(b("JSResource")("PagesComposerGating.react").__setRef("PagesComposerGatingDialog.react"));a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var c,d;for(var e=arguments.length,f=new Array(e),g=0;g=1e3?d.setState({fetching:!1,gating:a,gatingSentences:b("React").createElement("span",null,h._("{=Location - Living in:}",[h._param("=Location - Living in:",b("React").createElement(b("XUIText.react"),{weight:"bold"},h._("Location - Living in:")))]),b("React").createElement(b("XUIText.react"),{weight:"bold"}," \u2026"))}):b("ReactComposerTargetingUtils").fetchMetadata(a,d.context.targetID,d.$3)},d.$3=function(a,c){d.setState({fetching:!1,gating:a,gatingSentences:c}),b("isEmpty")(a)||b("isEmpty")(c.props.children)?d.props.onGatingChange&&d.props.onGatingChange(null,null):d.props.onGatingChange&&d.props.onGatingChange(a,c)},c)||babelHelpers.assertThisInitialized(d)}var d=c.prototype;d.getInitialGatingData=function(){var a=this.getInitialSavedData("gating");if(!a)return{age_min:j};a.age_min=a.age_min||j;return a};d.getInitialSavedData=function(a){var c={};c=this.getSavedSpec(a,this.context.composerID);return b("TargetingGatingUtils").convertInterestsToConnectionsFromTargetingSpecToApi(c)};d.getSavedSpec=function(a,c){c=b("ReactComposerTargetingUtils").getDataFromComposerTaggerStore(c);return c?c[a]:null};d.render=function(){return b("React").createElement(b("XUIDialog.react"),{behaviors:{LayerFadeOnHide:b("LayerFadeOnHide")},layerHideOnBlur:!1,onToggle:this.props.onToggle,shown:this.props.shown,width:k},b("React").createElement(b("XUIDialogTitle.react"),null,h._("Restricted Audience")),b("React").createElement(b("XUIDialogBody.react"),null,b("React").createElement(b("React").Suspense,{fallback:b("React").createElement("div",{className:"_1220"},b("React").createElement(b("XUISpinner.react"),null))},this.props.showToolTip?b("React").createElement(b("SUINotice.react"),{theme:b("SUIBusinessTheme"),type:"information"},h._("Only the audience you select will see this post in News Feed.")):null,b("React").createElement(l,{enableLanguageGating:!!this.props.enableLanguageGating,enableLocationExclusionGating:!!this.props.enableLocationExclusionGating,initialGatingSpec:this.state.gating||{},onGatingChange:this.$2}))),b("React").createElement(b("XUIDialogFooter.react"),null,b("React").createElement(b("XUIDialogCancelButton.react"),{use:"default"}),b("React").createElement(b("XUIDialogSaveButton.react"),{action:"confirm",className:"_2uyv",disabled:this.state.fetching,onClick:this.$1,use:"confirm"})))};return c}(b("React").PureComponent);a.contextTypes=b("ReactComposerContextTypes");e.exports=a}),null); __d("PagesComposerTargetingDialog.react",["cx","fbt","ActorURI","BanzaiODS","BootloadedComponent.react","JSResource","LayerFadeOnHide","Link.react","PageComposerAccessToken","React","ReactComposerContextTypes","ReactComposerTargetingUtils","TargetingGatingUtils","TargetingSpecStore","WebApiApplication","XAsyncRequest","XPageOrganicTargetingSettingAsyncController","XUIButton.react","XUIDialog.react","XUIDialogBody.react","XUIDialogCancelButton.react","XUIDialogFooter.react","XUIDialogSaveButton.react","XUIDialogTitle.react","XUISpinner.react","XUIText.react","areEqual","gkx","isEmpty"],(function(a,b,c,d,e,f,g,h){"use strict";__p&&__p();var i=b("gkx")("678710"),j=587;a=function(a){__p&&__p();babelHelpers.inheritsLoose(c,a);function c(){__p&&__p();var c,d;for(var e=arguments.length,f=new Array(e),g=0;g0?b("React").createElement(b("ReactComposerPagesPrivacyContainer.react"),{composerEntryPointRef:c.composerType,defaultDemographicsList:a,enableLanguageGating:g&&g.enableLanguageGating,enableLocationExclusionGating:g&&g.enableLocationExclusionGating,hideAudienceSelector:g&&g.hideAudienceSelector,hideFeedTargeting:g&&g.targetingKillswitch,hideGating:g&&g.gatingKillswitch,key:"privacy_selector",lockToPrivacy:f,newsSubscriberPageID:g&&g.newsSubscriberPageID,showNewsSubscribersGating:g&&g.showNewsSubscribersGating,showToolTip:c.gks.showPagesComposerFooterRedesign,showVideoCreatorTopFanGating:g&&g.showVideoCreatorTopFanGating,showWoodhengeGating:g&&g.showWoodhengeGating,targetingEnabled:d,useNewTargetingUI:e||c.gks.showPagesDestinationPicker,useTargetingAsFilter:!0,videoCreatorTopFanPageID:g&&g.videoCreatorTopFanPageID,woodhengeTiers:g&&g.woodhengeTiers}):null},showScheduleLivingRoomDialog:function(a,c,d,e,f){f===void 0&&(f=null),this._scheduledLivingRoomDialog&&this._scheduledLivingRoomDialog.hide(),this._scheduledLivingRoomDialog=b("ReactDOM").render(b("React").createElement(b("ScheduleLivingRoomDialogContainer.react"),{actorID:d,config:e,defaultScheduledTimeDelta:a,onChangeScheduledTime:f,timezoneStr:c}),b("DOM").create("div")),this._scheduledLivingRoomDialog.show()},showScheduledPostDialog:function(a,c,d){__p&&__p();b("PagesPublishingLoggingActions").click(b("PagePublishingFunnelClickTarget").SCHEDULE_POST_BUTTON);a=a.postButtonConfig;if(b("ReactComposerTaggerStore").hasData(c.composerID,b("ReactComposerTaggerType").BREAKING_NEWS))b("ReactDOM").render(b("React").createElement(b("XUIDialog.react"),{behaviors:{LayerFadeOnHide:b("LayerFadeOnHide"),LayerFadeOnShow:b("LayerFadeOnShow")},shown:!0,width:445},b("React").createElement(b("XUIDialogTitle.react"),null,"Error"),b("React").createElement(b("XUIDialogBody.react"),null,b("React").createElement("div",null,g._("The breaking news indicator can't be applied to a scheduled post. Apply the indicator when you publish the post."))),b("React").createElement(b("XUIDialogFooter.react"),null,b("React").createElement(b("XUIDialogOkayButton.react"),{action:"cancel",use:"confirm"}))),b("DOM").create("div"));else if(a){var e=a.defaultScheduledTimeDelta;a=a.timezoneString;e=b("ReactDOM").render(b("React").createElement(b("PostScheduleAndPostEndDialog.react"),{composerID:c.composerID,defaultScheduledTimeDelta:e,entryPoint:c.composerType,onSubmit:d,showComposerFooterRedesign:c.gks.showPagesComposerFooterRedesign,targetID:c.targetID,timezoneStr:a}),b("DOM").create("div"));e instanceof b("PostScheduleAndPostEndDialog.react")||h(0,1818);e.show()}},renderBackDateDialog:function(a,c,d){b("PagesPublishingLoggingActions").click(b("PagePublishingFunnelClickTarget").BACKDATE_BUTTON);a=b("dotAccess")(a,"postButtonConfig.minBackdateTime");a=b("ReactDOM").render(b("React").createElement(b("PostBackdateDialog.react"),{maxTime:Date.now()/1e3,minTime:a,onSubmit:d,showComposerFooterRedesign:c.gks.showPagesComposerFooterRedesign}),b("DOM").create("div"));a instanceof b("PostBackdateDialog.react")||h(0,1818);a.show()}};e.exports=j}),null); /** * License: https://www.facebook.com/legal/license/MDzNl_j9yvg/ */ __d("color-name-1.1.3",[],(function(a,b,c,d,e,f){"use strict";__p&&__p();a={};var g={exports:a};function h(){g.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}}var i=!1,j=function(){i||(i=!0,h());return g.exports};b=function(a){switch(a){case void 0:return j()}};e.exports=b}),null); /** * License: https://www.facebook.com/legal/license/MDzNl_j9yvg/ */ __d("color-convert-1.9.1",["color-name-1.1.3"],(function(a,b,c,d,e,f){"use strict";__p&&__p();function a(a){return a&&typeof a==="object"&&"default"in a?a["default"]:a}var g=a(b("color-name-1.1.3"));c={};var h={exports:c};function i(){__p&&__p();var a=g(),b={};for(var c in a)a.hasOwnProperty(c)&&(b[a[c]]=c);var d=h.exports={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};for(var e in d)if(d.hasOwnProperty(e)){if(!("channels"in d[e]))throw new Error("missing channels property: "+e);if(!("labels"in d[e]))throw new Error("missing channel labels property: "+e);if(d[e].labels.length!==d[e].channels)throw new Error("channel and label counts mismatch: "+e);var f=d[e].channels,i=d[e].labels;delete d[e].channels;delete d[e].labels;Object.defineProperty(d[e],"channels",{value:f});Object.defineProperty(d[e],"labels",{value:i})}d.rgb.hsl=function(a){var b=a[0]/255,c=a[1]/255;a=a[2]/255;var d=Math.min(b,c,a),e=Math.max(b,c,a),f=e-d,g;e===d?g=0:b===e?g=(c-a)/f:c===e?g=2+(a-b)/f:a===e&&(g=4+(b-c)/f);g=Math.min(g*60,360);g<0&&(g+=360);a=(d+e)/2;e===d?b=0:a<=.5?b=f/(e+d):b=f/(2-e-d);return[g,b*100,a*100]};d.rgb.hsv=function(a){var b=a[0],c=a[1];a=a[2];var d=Math.min(b,c,a),e=Math.max(b,c,a),f=e-d,g,h;e===0?h=0:h=f/e*1e3/10;e===d?g=0:b===e?g=(c-a)/f:c===e?g=2+(a-b)/f:a===e&&(g=4+(b-c)/f);g=Math.min(g*60,360);g<0&&(g+=360);d=e/255*1e3/10;return[g,h,d]};d.rgb.hwb=function(a){var b=a[0],c=a[1],e=a[2];a=d.rgb.hsl(a)[0];var f=1/255*Math.min(b,Math.min(c,e));e=1-1/255*Math.max(b,Math.max(c,e));return[a,f*100,e*100]};d.rgb.cmyk=function(a){var b=a[0]/255,c=a[1]/255;a=a[2]/255;var d;d=Math.min(1-b,1-c,1-a);b=(1-b-d)/(1-d)||0;c=(1-c-d)/(1-d)||0;a=(1-a-d)/(1-d)||0;return[b*100,c*100,a*100,d*100]};function j(a,b){return Math.pow(a[0]-b[0],2)+Math.pow(a[1]-b[1],2)+Math.pow(a[2]-b[2],2)}d.rgb.keyword=function(c){__p&&__p();var d=b[c];if(d)return d;d=Infinity;var e;for(var f in a)if(a.hasOwnProperty(f)){var g=a[f];g=j(c,g);g.04045?Math.pow((b+.055)/1.055,2.4):b/12.92;c=c>.04045?Math.pow((c+.055)/1.055,2.4):c/12.92;a=a>.04045?Math.pow((a+.055)/1.055,2.4):a/12.92;var d=b*.4124+c*.3576+a*.1805,e=b*.2126+c*.7152+a*.0722;b=b*.0193+c*.1192+a*.9505;return[d*100,e*100,b*100]};d.rgb.lab=function(a){__p&&__p();a=d.rgb.xyz(a);var b=a[0],c=a[1];a=a[2];var e;b/=95.047;c/=100;a/=108.883;b=b>.008856?Math.pow(b,1/3):7.787*b+16/116;c=c>.008856?Math.pow(c,1/3):7.787*c+16/116;a=a>.008856?Math.pow(a,1/3):7.787*a+16/116;e=116*c-16;b=500*(b-c);c=200*(c-a);return[e,b,c]};d.hsl.rgb=function(a){__p&&__p();var b=a[0]/360,c=a[1]/100;a=a[2]/100;var d,e,f;if(c===0){f=a*255;return[f,f,f]}a<.5?d=a*(1+c):d=a+c-a*c;c=2*a-d;a=[0,0,0];for(var g=0;g<3;g++)e=b+1/3*-(g-1),e<0&&e++,e>1&&e--,6*e<1?f=c+(d-c)*6*e:2*e<1?f=d:3*e<2?f=c+(d-c)*(2/3-e)*6:f=c,a[g]=f*255;return a};d.hsl.hsv=function(a){var b=a[0],c=a[1]/100;a=a[2]/100;var d=c,e=Math.max(a,.01),f;a*=2;c*=a<=1?a:2-a;d*=e<=1?e:2-e;f=(a+c)/2;e=a===0?2*d/(e+d):2*c/(a+c);return[b,e*100,f*100]};d.hsv.rgb=function(a){__p&&__p();var b=a[0]/60,c=a[1]/100;a=a[2]/100;var d=Math.floor(b)%6;b=b-Math.floor(b);var e=255*a*(1-c),f=255*a*(1-c*b);c=255*a*(1-c*(1-b));a*=255;switch(d){case 0:return[a,c,e];case 1:return[f,a,e];case 2:return[e,a,c];case 3:return[e,f,a];case 4:return[c,e,a];case 5:return[a,e,f]}};d.hsv.hsl=function(a){__p&&__p();var b=a[0],c=a[1]/100;a=a[2]/100;var d=Math.max(a,.01),e;a=(2-c)*a;e=(2-c)*d;c=c*d;c/=e<=1?e:2-e;c=c||0;a/=2;return[b,c*100,a*100]};d.hwb.rgb=function(a){__p&&__p();var b=a[0]/360,c=a[1]/100;a=a[2]/100;var d=c+a;d>1&&(c/=d,a/=d);d=Math.floor(6*b);a=1-a;b=6*b-d;(d&1)!==0&&(b=1-b);b=c+b*(a-c);var e,f,g;switch(d){default:case 6:case 0:e=a;f=b;g=c;break;case 1:e=b;f=a;g=c;break;case 2:e=c;f=a;g=b;break;case 3:e=c;f=b;g=a;break;case 4:e=b;f=c;g=a;break;case 5:e=a;f=c;g=b;break}return[e*255,f*255,g*255]};d.cmyk.rgb=function(a){var b=a[0]/100,c=a[1]/100,d=a[2]/100;a=a[3]/100;b=1-Math.min(1,b*(1-a)+a);c=1-Math.min(1,c*(1-a)+a);d=1-Math.min(1,d*(1-a)+a);return[b*255,c*255,d*255]};d.xyz.rgb=function(a){__p&&__p();var b=a[0]/100,c=a[1]/100;a=a[2]/100;var d,e;d=b*3.2406+c*-1.5372+a*-.4986;e=b*-.9689+c*1.8758+a*.0415;b=b*.0557+c*-.204+a*1.057;d=d>.0031308?1.055*Math.pow(d,1/2.4)-.055:d*12.92;e=e>.0031308?1.055*Math.pow(e,1/2.4)-.055:e*12.92;b=b>.0031308?1.055*Math.pow(b,1/2.4)-.055:b*12.92;d=Math.min(Math.max(0,d),1);e=Math.min(Math.max(0,e),1);b=Math.min(Math.max(0,b),1);return[d*255,e*255,b*255]};d.xyz.lab=function(a){__p&&__p();var b=a[0],c=a[1];a=a[2];var d;b/=95.047;c/=100;a/=108.883;b=b>.008856?Math.pow(b,1/3):7.787*b+16/116;c=c>.008856?Math.pow(c,1/3):7.787*c+16/116;a=a>.008856?Math.pow(a,1/3):7.787*a+16/116;d=116*c-16;b=500*(b-c);c=200*(c-a);return[d,b,c]};d.lab.xyz=function(a){__p&&__p();var b=a[0],c=a[1];a=a[2];b=(b+16)/116;c=c/500+b;a=b-a/200;var d=Math.pow(b,3),e=Math.pow(c,3),f=Math.pow(a,3);b=d>.008856?d:(b-16/116)/7.787;c=e>.008856?e:(c-16/116)/7.787;a=f>.008856?f:(a-16/116)/7.787;c*=95.047;b*=100;a*=108.883;return[c,b,a]};d.lab.lch=function(a){var b=a[0],c=a[1];a=a[2];var d;d=Math.atan2(a,c);d=d*360/2/Math.PI;d<0&&(d+=360);c=Math.sqrt(c*c+a*a);return[b,c,d]};d.lch.lab=function(a){var b=a[0],c=a[1];a=a[2];var d;a=a/360*2*Math.PI;d=c*Math.cos(a);c=c*Math.sin(a);return[b,d,c]};d.rgb.ansi16=function(a){var b=a[0],c=a[1],e=a[2],f=1 in arguments?arguments[1]:d.rgb.hsv(a)[2];f=Math.round(f/50);if(f===0)return 30;var g=30+(Math.round(e/255)<<2|Math.round(c/255)<<1|Math.round(b/255));f===2&&(g+=60);return g};d.hsv.ansi16=function(a){return d.rgb.ansi16(d.hsv.rgb(a),a[2])};d.rgb.ansi256=function(a){var b=a[0],c=a[1];a=a[2];if(b===c&&c===a){if(b<8)return 16;return b>248?231:Math.round((b-8)/247*24)+232}b=16+36*Math.round(b/255*5)+6*Math.round(c/255*5)+Math.round(a/255*5);return b};d.ansi16.rgb=function(a){__p&&__p();var b=a%10;if(b===0||b===7){a>50&&(b+=3.5);b=b/10.5*255;return[b,b,b]}a=(~~(a>50)+1)*.5;var c=(b&1)*a*255,d=(b>>1&1)*a*255;b=(b>>2&1)*a*255;return[c,d,b]};d.ansi256.rgb=function(a){if(a>=232){var b=(a-232)*10+8;return[b,b,b]}a-=16;b=Math.floor(a/36)/5*255;var c=Math.floor((a=a%36)/6)/5*255;a=a%6/5*255;return[b,c,a]};d.rgb.hex=function(a){a=((Math.round(a[0])&255)<<16)+((Math.round(a[1])&255)<<8)+(Math.round(a[2])&255);a=a.toString(16).toUpperCase();return"000000".substring(a.length)+a};d.hex.rgb=function(a){__p&&__p();a=a.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!a)return[0,0,0];var b=a[0];a[0].length===3&&(b=b.split("").map(function(a){return a+a}).join(""));a=parseInt(b,16);b=a>>16&255;var c=a>>8&255;a=a&255;return[b,c,a]};d.rgb.hcg=function(a){var b=a[0]/255,c=a[1]/255;a=a[2]/255;var d=Math.max(Math.max(b,c),a),e=Math.min(Math.min(b,c),a),f=d-e,g;f<1?e=e/(1-f):e=0;f<=0?g=0:d===b?g=(c-a)/f%6:d===c?g=2+(a-b)/f:g=4+(b-c)/f+4;g/=6;g%=1;return[g*360,f*100,e*100]};d.hsl.hcg=function(a){var b=a[1]/100,c=a[2]/100,d,e=0;c<.5?d=2*b*c:d=2*b*(1-c);d<1&&(e=(c-.5*d)/(1-d));return[a[0],d*100,e*100]};d.hsv.hcg=function(a){var b=a[1]/100,c=a[2]/100;b=b*c;var d=0;b<1&&(d=(c-b)/(1-b));return[a[0],b*100,d*100]};d.hcg.rgb=function(a){__p&&__p();var b=a[0]/360,c=a[1]/100;a=a[2]/100;if(c===0)return[a*255,a*255,a*255];var d=[0,0,0];b=b%1*6;var e=b%1,f=1-e;switch(Math.floor(b)){case 0:d[0]=1;d[1]=e;d[2]=0;break;case 1:d[0]=f;d[1]=1;d[2]=0;break;case 2:d[0]=0;d[1]=1;d[2]=e;break;case 3:d[0]=0;d[1]=f;d[2]=1;break;case 4:d[0]=e;d[1]=0;d[2]=1;break;default:d[0]=1,d[1]=0,d[2]=f}b=(1-c)*a;return[(c*d[0]+b)*255,(c*d[1]+b)*255,(c*d[2]+b)*255]};d.hcg.hsv=function(a){var b=a[1]/100,c=a[2]/100;c=b+c*(1-b);var d=0;c>0&&(d=b/c);return[a[0],d*100,c*100]};d.hcg.hsl=function(a){var b=a[1]/100,c=a[2]/100;c=c*(1-b)+.5*b;var d=0;c>0&&c<.5?d=b/(2*c):c>=.5&&c<1&&(d=b/(2*(1-c)));return[a[0],d*100,c*100]};d.hcg.hwb=function(a){var b=a[1]/100,c=a[2]/100;c=b+c*(1-b);return[a[0],(c-b)*100,(1-c)*100]};d.hwb.hcg=function(a){var b=a[1]/100,c=a[2]/100;c=1-c;b=c-b;var d=0;b<1&&(d=(c-b)/(1-b));return[a[0],b*100,d*100]};d.apple.rgb=function(a){return[a[0]/65535*255,a[1]/65535*255,a[2]/65535*255]};d.rgb.apple=function(a){return[a[0]/255*65535,a[1]/255*65535,a[2]/255*65535]};d.gray.rgb=function(a){return[a[0]/100*255,a[0]/100*255,a[0]/100*255]};d.gray.hsl=d.gray.hsv=function(a){return[0,0,a[0]]};d.gray.hwb=function(a){return[0,100,a[0]]};d.gray.cmyk=function(a){return[0,0,0,a[0]]};d.gray.lab=function(a){return[a[0],0,0]};d.gray.hex=function(a){a=Math.round(a[0]/100*255)&255;a=(a<<16)+(a<<8)+a;a=a.toString(16).toUpperCase();return"000000".substring(a.length)+a};d.rgb.gray=function(a){a=(a[0]+a[1]+a[2])/3;return[a/255*100]}}var j=!1,k=function(){j||(j=!0,i());return h.exports};d={};var l={exports:d};function m(){__p&&__p();var a=k();function b(){var b={},c=Object.keys(a);for(var d=c.length,e=0;e1&&(b=Array.prototype.slice.call(arguments));return a(b)};"conversion"in a&&(b.conversion=a.conversion);return b}function f(a){__p&&__p();var b=function(b){if(b===void 0||b===null)return b;arguments.length>1&&(b=Array.prototype.slice.call(arguments));var c=a(b);if(typeof c==="object")for(var d=c.length,e=0;e=0&&(a.splice instanceof Function||Object.getOwnPropertyDescriptor(a,a.length-1)&&a.constructor.name!=="String")}}var i=!1,j=function(){i||(i=!0,h());return g.exports};b=function(a){switch(a){case void 0:return j()}};e.exports=b}),null); /** * License: https://www.facebook.com/legal/license/MDzNl_j9yvg/ */ __d("simple-swizzle-0.2.2",["is-arrayish-0.3.1"],(function(a,b,c,d,e,f){"use strict";__p&&__p();function a(a){return a&&typeof a==="object"&&"default"in a?a["default"]:a}var g=a(b("is-arrayish-0.3.1"));c={};var h={exports:c};function i(){__p&&__p();var a=g(),b=Array.prototype.concat,c=Array.prototype.slice,d=h.exports=function(d){var e=[];for(var f=0,g=d.length;f=4&&a[3]!==1&&(c=", "+a[3]);return"hwb("+a[0]+", "+a[1]+"%, "+a[2]+"%"+c+")"};e.to.keyword=function(a){return c[a.slice(0,3)]};function f(a,b,c){return Math.min(Math.max(b,a),c)}function j(a){a=a.toString(16).toUpperCase();return a.length<2?"0"+a:a}}var k=!1,l=function(){k||(k=!0,j());return i.exports};d=function(a){switch(a){case void 0:return l()}};e.exports=d}),null); /** * License: https://www.facebook.com/legal/license/MDzNl_j9yvg/ */ __d("color-3.0.0",["color-string-1.5.2","color-convert-1.9.1"],(function(a,b,c,d,e,f){"use strict";__p&&__p();function a(a){return a&&typeof a==="object"&&"default"in a?a["default"]:a}var g=a(b("color-string-1.5.2")),h=a(b("color-convert-1.9.1"));c={};var i={exports:c};function j(){__p&&__p();var a=g(),b=h(),c=[].slice,d=["keyword","gray","hex"],e={};Object.keys(b).forEach(function(a){e[c.call(b[a].labels).sort().join("")]=a});var f={};function j(g,h){__p&&__p();if(!(this instanceof j))return new j(g,h);h&&h in d&&(h=null);if(h&&!(h in b))throw new Error("Unknown model: "+h);var i,k;if(!g)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(g instanceof j)this.model=g.model,this.color=g.color.slice(),this.valpha=g.valpha;else if(typeof g==="string"){var l=a.get(g);if(l===null)throw new Error("Unable to parse color from string: "+g);this.model=l.model;k=b[this.model].channels;this.color=l.value.slice(0,k);this.valpha=typeof l.value[k]==="number"?l.value[k]:1}else if(g.length){this.model=h||"rgb";k=b[this.model].channels;l=c.call(g,0,k);this.color=p(l,k);this.valpha=typeof g[k]==="number"?g[k]:1}else if(typeof g==="number")g&=16777215,this.model="rgb",this.color=[g>>16&255,g>>8&255,g&255],this.valpha=1;else{this.valpha=1;h=Object.keys(g);"alpha"in g&&(h.splice(h.indexOf("alpha"),1),this.valpha=typeof g.alpha==="number"?g.alpha:0);l=h.sort().join("");if(!(l in e))throw new Error("Unable to parse color from object: "+JSON.stringify(g));this.model=e[l];h=b[this.model].labels;l=[];for(i=0;ia?(b+.05)/(a+.05):(a+.05)/(b+.05)},level:function(a){a=this.contrast(a);return a>=7.1?"AAA":a>=4.5?"AA":""},isDark:function(){var a=this.rgb().color;a=(a[0]*299+a[1]*587+a[2]*114)/1e3;return a<128},isLight:function(){return!this.isDark()},negate:function(){var a=this.rgb();for(var b=0;b<3;b++)a.color[b]=255-a.color[b];return a},lighten:function(a){var b=this.hsl();b.color[2]+=b.color[2]*a;return b},darken:function(a){var b=this.hsl();b.color[2]-=b.color[2]*a;return b},saturate:function(a){var b=this.hsl();b.color[1]+=b.color[1]*a;return b},desaturate:function(a){var b=this.hsl();b.color[1]-=b.color[1]*a;return b},whiten:function(a){var b=this.hwb();b.color[1]+=b.color[1]*a;return b},blacken:function(a){var b=this.hwb();b.color[2]+=b.color[2]*a;return b},grayscale:function(){var a=this.rgb().color;a=a[0]*.3+a[1]*.59+a[2]*.11;return j.rgb(a,a,a)},fade:function(a){return this.alpha(this.valpha-this.valpha*a)},opaquer:function(a){return this.alpha(this.valpha+this.valpha*a)},rotate:function(a){var b=this.hsl(),c=b.color[0];c=(c+a)%360;c=c<0?360+c:c;b.color[0]=c;return b},mix:function(a,b){a=a.rgb();var c=this.rgb();b=b===void 0?.5:b;var d=2*b-1,e=a.alpha()-c.alpha();d=((d*e===-1?d:(d+e)/(1+d*e))+1)/2;e=1-d;return j.rgb(d*a.red()+e*c.red(),d*a.green()+e*c.green(),d*a.blue()+e*c.blue(),a.alpha()*b+c.alpha()*(1-b))}};Object.keys(b).forEach(function(a){__p&&__p();if(d.indexOf(a)!==-1)return;var e=b[a].channels;j.prototype[a]=function(){if(this.model===a)return new j(this);if(arguments.length)return new j(arguments,a);var c=typeof arguments[e]==="number"?e:this.valpha;return new j(o(b[this.model][a].raw(this.color)).concat(c),a)};j[a]=function(b){typeof b==="number"&&(b=p(c.call(arguments),e));return new j(b,a)}});function k(a,b){return Number(a.toFixed(b))}function l(a){return function(b){return k(b,a)}}function m(a,b,c){__p&&__p();a=Array.isArray(a)?a:[a];a.forEach(function(a){(f[a]||(f[a]=[]))[b]=c});a=a[0];return function(d){__p&&__p();var e;if(arguments.length){c&&(d=c(d));e=this[a]();e.color[b]=d;return e}e=this[a]().color[b];c&&(e=c(e));return e}}function n(a){return function(b){return Math.max(0,Math.min(a,b))}}function o(a){return Array.isArray(a)?a:[a]}function p(a,b){for(var c=0;c