FDSCommunityNotesWriteNoteInputDialog.react",["CDSText.react","CometColumn.react","CometColumnItem.react","CometRelay","CommunityNotesLoggings","CommunityNotesStrings","CommunityNotesUtils","FDSCommunityNotesWriteNoteConfirmationDialog.entrypoint","FDSCommunityNotesWriteNoteInputDialogCreateNoteMutation.graphql","FDSCommunityNotesWriteNoteTipsDialog.entrypoint","FDSDialogFooter.react","FDSDialogHeader.react","FDSDialogPage.react","FDSFormTextArea.react","FDSFormTextInput.react","FDSInlinePressableText.react","FDSText.react","isValidURL","react","react-compiler-runtime","usePopPage","usePushPage","useVisibilityObserver"],(function(a,b,c,d,e,f,g){"use strict";var h,i,j=i||(i=d("react"));e=i;e.useCallback;var k=e.useState,l=h!==void 0?h:h=b("FDSCommunityNotesWriteNoteInputDialogCreateNoteMutation.graphql");function a(a){var b=d("react-compiler-runtime").c(55);a=a.props;var e=a.contentId;a=a.onClose;var f=k(!1),g=f[0],h=f[1];b[0]!==e||b[1]!==g?(f=function(){g||(d("CommunityNotesLoggings").logCommunityNotesClientEventsImpression("impression_screen_authoring","ScreenAuthoring",e,String("newsfeed_three_dot_menu")),h(!0))},b[0]=e,b[1]=g,b[2]=f):f=b[2];f=f;var i;b[3]!==f?(i={onVisible:f},b[3]=f,b[4]=i):i=b[4];f=c("useVisibilityObserver")(i);i=k("");var l=i[0],o=i[1];i=k("");var p=i[0],q=i[1];i=k(!1);var r=i[0],s=i[1];i=k(!1);var t=i[0],u=i[1];i=k(!1);var v=i[0],w=i[1];i=k(!1);var x=i[0],y=i[1];i=r&&(l.length>d("CommunityNotesUtils").NOTE_CHAR_LIMIT||l.length===0);b[5]!==t||b[6]!==p?(r=t&&!c("isValidURL")(p),b[5]=t,b[6]=p,b[7]=r):r=b[7];t=r;r=x||i;v=v||t;t=l.length===0||p.length===0||r||v;var z=c("usePopPage")(),A;b[8]!==t||b[9]!==e||b[10]!==l||b[11]!==a||b[12]!==p?(A=j.jsx(n,{buttonDisabled:t,contentId:e,noteText:l,onClose:a,setHasNoteTextServerError:y,setHasSourceUrlServerError:w,sourceUrl:p}),b[8]=t,b[9]=e,b[10]=l,b[11]=a,b[12]=p,b[13]=A):A=b[13];b[14]!==z?(t=function(){z&&z()},b[14]=z,b[15]=t):t=b[15];var B;b[16]!==a||b[17]!==t?(B=j.jsx(c("FDSDialogHeader.react"),{onBack:t,onClose:a,text:d("CommunityNotesStrings").WRITE_COMMUNITY_NOTE,withBackButton:!0,withoutDivider:!0}),b[16]=a,b[17]=t,b[18]=B):B=b[18];b[19]!==e||b[20]!==a?(t=j.jsx(c("CometColumnItem.react"),{paddingTop:16,children:j.jsxs(c("FDSText.react"),{type:"body3",children:[d("CommunityNotesStrings").COMMUNITY_NOTES_ANONYMOUS," ",j.jsx(c("FDSText.react"),{color:"blueLink",type:"bodyLink3",children:j.jsx(m,{contentId:e,onClose:a})})]})}),b[19]=e,b[20]=a,b[21]=t):t=b[21];b[22]===Symbol["for"]("react.memo_cache_sentinel")?(a=function(a){s(!0),y(!1),o(a)},b[22]=a):a=b[22];r=r?"ERROR":null;b[23]!==l||b[24]!==r?(a=j.jsx(c("FDSFormTextArea.react"),{label:d("CommunityNotesStrings").WRITE_NOTE_DIALOG_INPUT_SCREEN_CONTEXT_INPUT_LABEL,onValueChange:a,validationState:r,value:l}),b[23]=l,b[24]=r,b[25]=a):a=b[25];r=i?"negative":"primaryText";b[26]!==l.length?(i=d("CommunityNotesStrings").getWriteNoteDialogInputScreenCharacterLimitLabel(l.length,d("CommunityNotesUtils").NOTE_CHAR_LIMIT),b[26]=l.length,b[27]=i):i=b[27];b[28]!==r||b[29]!==i?(l=j.jsx(c("CometColumnItem.react"),{paddingTop:8,children:j.jsx(c("CDSText.react"),{color:r,textStyle:"meta",children:i})}),b[28]=r,b[29]=i,b[30]=l):l=b[30];b[31]!==a||b[32]!==l?(r=j.jsxs(c("CometColumnItem.react"),{paddingTop:24,children:[a,l]}),b[31]=a,b[32]=l,b[33]=r):r=b[33];b[34]!==x?(i=x&&j.jsx(c("CometColumnItem.react"),{paddingTop:12,children:j.jsx(c("FDSText.react"),{color:"negative",type:"meta4",children:d("CommunityNotesStrings").WRITE_NOTE_DIALOG_INPUT_SCREEN_CONTEXT_INPUT_ERROR_CANNOT_HAVE_LINKS})}),b[34]=x,b[35]=i):i=b[35];b[36]===Symbol["for"]("react.memo_cache_sentinel")?(a=function(a){u(!0),w(!1),q(a)},b[36]=a):a=b[36];l=v?"ERROR":null;b[37]!==p||b[38]!==l?(x=j.jsx(c("FDSFormTextInput.react"),{label:d("CommunityNotesStrings").WRITE_NOTE_DIALOG_INPUT_SCREEN_LINK_INPUT_LABEL,onValueChange:a,validationState:l,value:p}),b[37]=p,b[38]=l,b[39]=x):x=b[39];a=v?d("CommunityNotesStrings").ADD_VALID_URL:null;b[40]!==a?(p=j.jsx(c("CometColumnItem.react"),{paddingTop:8,children:j.jsx(c("CDSText.react"),{color:"negative",textStyle:"meta",children:a})}),b[40]=a,b[41]=p):p=b[41];b[42]!==x||b[43]!==p?(l=j.jsxs(c("CometColumnItem.react"),{paddingVertical:12,children:[x,p]}),b[42]=x,b[43]=p,b[44]=l):l=b[44];b[45]!==r||b[46]!==i||b[47]!==l||b[48]!==t||b[49]!==f?(v=j.jsxs(c("CometColumn.react"),{paddingHorizontal:16,ref:f,children:[t,r,i,l]}),b[45]=r,b[46]=i,b[47]=l,b[48]=t,b[49]=f,b[50]=v):v=b[50];b[51]!==v||b[52]!==A||b[53]!==B?(a=j.jsx(c("FDSDialogPage.react"),{footer:A,header:B,children:v}),b[51]=v,b[52]=A,b[53]=B,b[54]=a):a=b[54];return a}function m(a){var b=d("react-compiler-runtime").c(5),e=a.contentId,f=a.onClose;b[0]===Symbol["for"]("react.memo_cache_sentinel")?(a={},b[0]=a):a=b[0];a=c("usePushPage")(c("FDSCommunityNotesWriteNoteTipsDialog.entrypoint"),a);var g=a[0];b[1]!==e||b[2]!==f||b[3]!==g?(a=j.jsx(c("FDSInlinePressableText.react"),{onPress:function(){return g({contentId:e,onClose:f})},children:d("CommunityNotesStrings").WRITE_NOTE_DIALOG_INPUT_SCREEN_GET_TIPS_BUTTON}),b[1]=e,b[2]=f,b[3]=g,b[4]=a):a=b[4];return a}function n(a){var b=d("react-compiler-runtime").c(13),e=a.buttonDisabled,f=a.contentId,g=a.noteText,h=a.onClose,i=a.setHasNoteTextServerError,k=a.setHasSourceUrlServerError,m=a.sourceUrl;a=d("CometRelay").useMutation(l);var n=a[0];a=a[1];var o;b[0]===Symbol["for"]("react.memo_cache_sentinel")?(o={},b[0]=o):o=b[0];o=c("usePushPage")(c("FDSCommunityNotesWriteNoteConfirmationDialog.entrypoint"),o);var p=o[0];b[1]!==n||b[2]!==f||b[3]!==g||b[4]!==h||b[5]!==p||b[6]!==i||b[7]!==k||b[8]!==m?(o=function(){d("CommunityNotesLoggings").logCommunityNotesClientEventsUserAction("ButtonSubmit",f,"click_button_authoring_submit_note",String("newsfeed_three_dot_menu")),n({onCompleted:function(a,b){var c;if((a==null||(c=a.xfb_community_notes_create_note)==null?void 0:c.success)===!0)p({onClose:h});else{var d;b=a==null||(d=a.xfb_community_notes_create_note)==null?void 0:d.result_codes;if(b!=null){a=b.includes("ERROR_INVALID_URI");k(a);a=b.includes("ERROR_INVALID_CAPTION");i(a)}}},variables:{input:{content_id:f,text:g,uri:m}}})},b[1]=n,b[2]=f,b[3]=g,b[4]=h,b[5]=p,b[6]=i,b[7]=k,b[8]=m,b[9]=o):o=b[9];o=o;e=e||a;b[10]!==o||b[11]!==e?(a=j.jsx(c("FDSDialogFooter.react"),{primary:{disabled:e,label:d("CommunityNotesStrings").WRITE_NOTE_DIALOG_INPUT_SCREEN_SUBMIT_BUTTON,onPress:o}}),b[10]=o,b[11]=e,b[12]=a):a=b[12];return a}g["default"]=a}),98);
-----
FDSCommunityNotesWriteNoteInputDialogCreateNoteMutation.graphql",["FDSCommunityNotesWriteNoteInputDialogCreateNoteMutation_facebookRelayOperation"],(function(a,b,c,d,e,f){"use strict";a=function(){var a=[{defaultValue:null,kind:"LocalArgument",name:"input"}],c=[{alias:null,args:[{kind:"Variable",name:"data",variableName:"input"}],concreteType:"XFBCommunityNotesCreateNoteResponsePayload",kind:"LinkedField",name:"xfb_community_notes_create_note",plural:!1,selections:[{alias:null,args:null,kind:"ScalarField",name:"result_codes",storageKey:null},{alias:null,args:null,kind:"ScalarField",name:"success",storageKey:null}],storageKey:null}];return{fragment:{argumentDefinitions:a,kind:"Fragment",metadata:null,name:"FDSCommunityNotesWriteNoteInputDialogCreateNoteMutation",selections:c,type:"Mutation",abstractKey:null},kind:"Request",operation:{argumentDefinitions:a,kind:"Operation",name:"FDSCommunityNotesWriteNoteInputDialogCreateNoteMutation",selections:c},params:{id:b("FDSCommunityNotesWriteNoteInputDialogCreateNoteMutation_facebookRelayOperation"),metadata:{},name:"FDSCommunityNotesWriteNoteInputDialogCreateNoteMutation",operationKind:"mutation",text:null}}}();e.exports=a}),null);
-----
FDSCommunityNotesWriteNoteInputDialogCreateNoteMutation_facebookRelayOperation",[],(function(a,b,c,d,e,f){e.exports="23985725991086038"}),null);
-----