OCAccountLocaleMutation",["OCAccountLocaleMutation.graphql","OCRelayModern","Promise","RelayFBEnvironment"],(function(a,b,c,d,e,f,g){"use strict";var h,i,j=h!==void 0?h:h=b("OCAccountLocaleMutation.graphql");function a(a){return new(i||(i=b("Promise")))(function(b,d){return c("OCRelayModern").commitMutation(c("RelayFBEnvironment"),{mutation:j,variables:{input:{locale:a.locale}},onCompleted:function(a){return b(a)},onError:function(a){return d(a)}})})}g.commit=a}),98);
-----
OCAccountChangeLocaleForm.react",["fbt","OCAccountLocaleMutation","OCDSButton.react","OCDSSelector.react","OCDSSelectorItem.react","OCDSSpacer.react","OCDSText.react","OCShopLocalizationSettingsUpdateLocaleMutation","OCSiteConstants","RelayFBEnvironment","asyncToGeneratorRuntime","react"],(function(a,b,c,d,e,f,g,h){"use strict";var i,j=i||(i=d("react")),k=i.useState,l={headerMargin:{marginBottom:"xyorhqc",$$css:!0},errorMargin:{marginTop:"x1gslohp",$$css:!0}};function a(a){var e=a.currentLocale,f=a.onSuccess;a=k(d("OCSiteConstants").localeToDisplayNamesMap[e]);var g=a[0];a=a[1];var i=k(!1),m=i[0],n=i[1];i=k(!1);var o=i[0],p=i[1];function q(a){n(!1),a!=null&&p(!0)}function r(a){return s.apply(this,arguments)}function s(){s=b("asyncToGeneratorRuntime").asyncToGenerator(function*(a){a.preventDefault();n(!0);a={locale:g};try{yield d("OCAccountLocaleMutation").commit(a),d("OCShopLocalizationSettingsUpdateLocaleMutation").commitOCShopLocalizationSettingsUpdateLocaleMutation(c("RelayFBEnvironment"),{input:{locale:g,site_type:"OCULUS"}},function(a){location.reload()},function(a){}),n(!1),f(g)}catch(a){q(a)}});return s.apply(this,arguments)}return j.jsxs("div",{className:"xbaz6xv",children:[j.jsx(c("OCDSText.react"),{display:"block",type:"body2",weight:"bold",xstyle:l.headerMargin,children:h._("u5e10u6237u8bedu8a00")}),j.jsx(c("OCDSSelector.react"),{placeholder:d("OCSiteConstants").localeToDisplayNamesMap[e],value:g,onChange:a,children:Object.keys(d("OCSiteConstants").localeToDisplayNamesMap).map(function(a){return j.jsx(c("OCDSSelectorItem.react"),{label:d("OCSiteConstants").localeToDisplayNamesMap[a],value:a},a)})}),o&&j.jsx(c("OCDSText.react"),{color:"error",display:"block",type:"body2",xstyle:l.errorMargin,children:h._("u66f4u65b0u8bedu8a00u65f6u51fau9519uff0cu8bf7u91cdu8bd5u3002")}),j.jsx(c("OCDSSpacer.react"),{topSize:"xsmall"}),j.jsx(c("OCDSButton.react"),{"data-testid":void 0,isDisabled:m,isLoading:m,label:h._("u4fddu5b58"),type:"secondary",variant:"outline",onClick:r})]})}a.displayName=a.name+" [from "+f.id+"]";g["default"]=a}),226);
-----
OCAccountLocaleMutation.graphql",["OCAccountLocaleMutation_oculusRelayOperation"],(function(a,b,c,d,e,f){"use strict";a=function(){var a=[{defaultValue:null,kind:"LocalArgument",name:"input"}],c=[{kind:"Variable",name:"data",variableName:"input"}],d={alias:null,args:null,kind:"ScalarField",name:"locale",storageKey:null};return{fragment:{argumentDefinitions:a,kind:"Fragment",metadata:null,name:"OCAccountLocaleMutation",selections:[{alias:null,args:c,concreteType:"UserEditResponsePayload",kind:"LinkedField",name:"user_edit",plural:!1,selections:[{alias:null,args:null,concreteType:"User",kind:"LinkedField",name:"user",plural:!1,selections:[d],storageKey:null}],storageKey:null}],type:"Mutation",abstractKey:null},kind:"Request",operation:{argumentDefinitions:a,kind:"Operation",name:"OCAccountLocaleMutation",selections:[{alias:null,args:c,concreteType:"UserEditResponsePayload",kind:"LinkedField",name:"user_edit",plural:!1,selections:[{alias:null,args:null,concreteType:"User",kind:"LinkedField",name:"user",plural:!1,selections:[d,{alias:null,args:null,kind:"ScalarField",name:"id",storageKey:null}],storageKey:null}],storageKey:null}]},params:{id:b("OCAccountLocaleMutation_oculusRelayOperation"),metadata:{},name:"OCAccountLocaleMutation",operationKind:"mutation",text:null}}}();e.exports=a}),null);
-----
OCAccountLocaleMutation_oculusRelayOperation",[],(function(a,b,c,d,e,f){e.exports="4653974164730204"}),null);
-----
OCAccountLocaleMutation",["OCAccountLocaleMutation.graphql","OCRelayModern","Promise","RelayFBEnvironment"],(function(a,b,c,d,e,f,g){"use strict";var h,i=h!==void 0?h:h=b("OCAccountLocaleMutation.graphql");function a(a){return new(b("Promise"))(function(b,d){return c("OCRelayModern").commitMutation(c("RelayFBEnvironment"),{mutation:i,variables:{input:{locale:a.locale}},onCompleted:function(a){return b(a)},onError:function(a){return d(a)}})})}g.commit=a}),98);
-----
OCAccountChangeLocaleForm.react",["fbt","OCAccountLocaleMutation","OCDSButton.react","OCDSSelector.react","OCDSSelectorItem.react","OCDSSpacer.react","OCDSText.react","OCShopLocalizationSettingsUpdateLocaleMutation","OCSiteConstants","RelayFBEnvironment","react","regeneratorRuntime"],(function(a,b,c,d,e,f,g,h){"use strict";var i=d("react"),j=d("react").useState,k={container:{paddingBottom:"xbaz6xv",$$css:!0},headerMargin:{marginBottom:"xyorhqc",$$css:!0},errorMargin:{marginTop:"x1gslohp",$$css:!0}};function a(a){var e=a.currentLocale,f=a.onSuccess;a=j(d("OCSiteConstants").localeToDisplayNamesMap[e]);var g=a[0];a=a[1];var l=j(!1),m=l[0],n=l[1];l=j(!1);var o=l[0],p=l[1];function q(a){n(!1),a!=null&&p(!0)}function r(a){var e;return b("regeneratorRuntime").async(function(h){while(1)switch(h.prev=h.next){case 0:a.preventDefault();n(!0);e={locale:g};h.prev=3;h.next=6;return b("regeneratorRuntime").awrap(d("OCAccountLocaleMutation").commit(e));case 6:d("OCShopLocalizationSettingsUpdateLocaleMutation").commitOCShopLocalizationSettingsUpdateLocaleMutation(c("RelayFBEnvironment"),{input:{locale:g,site_type:"OCULUS"}},function(a){location.reload()},function(a){});n(!1);f(g);h.next=14;break;case 11:h.prev=11,h.t0=h["catch"](3),q(h.t0);case 14:case"end":return h.stop()}},null,this,[[3,11]])}return i.jsxs("div",{className:"xbaz6xv",children:[i.jsx(c("OCDSText.react"),{display:"block",type:"body2",weight:"bold",xstyle:k.headerMargin,children:h._("u5e10u6237u8bedu8a00")}),i.jsx(c("OCDSSelector.react"),{placeholder:d("OCSiteConstants").localeToDisplayNamesMap[e],value:g,onChange:a,children:Object.keys(d("OCSiteConstants").localeToDisplayNamesMap).map(function(a){return i.jsx(c("OCDSSelectorItem.react"),{label:d("OCSiteConstants").localeToDisplayNamesMap[a],value:a},a)})}),o&&i.jsx(c("OCDSText.react"),{color:"error",display:"block",type:"body2",xstyle:k.errorMargin,children:h._("u66f4u65b0u8bedu8a00u65f6u51fau9519uff0cu8bf7u91cdu8bd5u3002")}),i.jsx(c("OCDSSpacer.react"),{topSize:"xsmall"}),i.jsx(c("OCDSButton.react"),{"data-testid":void 0,isDisabled:m,isLoading:m,label:h._("u4fddu5b58"),type:"secondary",variant:"outline",onClick:r})]})}a.displayName=a.name+" [from "+f.id+"]";g["default"]=a}),98);
-----
OCAccountLocaleMutation.graphql",["OCAccountLocaleMutation_oculusRelayOperation"],(function(a,b,c,d,e,f){"use strict";a=function(){var a=[{defaultValue:null,kind:"LocalArgument",name:"input"}],c=[{kind:"Variable",name:"data",variableName:"input"}],d={alias:null,args:null,kind:"ScalarField",name:"locale",storageKey:null};return{fragment:{argumentDefinitions:a,kind:"Fragment",metadata:null,name:"OCAccountLocaleMutation",selections:[{alias:null,args:c,concreteType:"UserEditResponsePayload",kind:"LinkedField",name:"user_edit",plural:!1,selections:[{alias:null,args:null,concreteType:"User",kind:"LinkedField",name:"user",plural:!1,selections:[d],storageKey:null}],storageKey:null}],type:"Mutation",abstractKey:null},kind:"Request",operation:{argumentDefinitions:a,kind:"Operation",name:"OCAccountLocaleMutation",selections:[{alias:null,args:c,concreteType:"UserEditResponsePayload",kind:"LinkedField",name:"user_edit",plural:!1,selections:[{alias:null,args:null,concreteType:"User",kind:"LinkedField",name:"user",plural:!1,selections:[d,{alias:null,args:null,kind:"ScalarField",name:"id",storageKey:null}],storageKey:null}],storageKey:null}]},params:{id:b("OCAccountLocaleMutation_oculusRelayOperation"),metadata:{},name:"OCAccountLocaleMutation",operationKind:"mutation",text:null}}}();e.exports=a}),null);
-----
OCAccountLocaleMutation_oculusRelayOperation",[],(function(a,b,c,d,e,f){e.exports="4653974164730204"}),null);
-----