1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7699],{58337:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/account/creator/edit",function(){return r(16822)}])},99361:function(e,t,r){"use strict";r.d(t,{X:function(){return u}});var n=r(85893),a=r(704),c=r(15080),l=r(67294),o=r(91824);r(2304),r(96391);let u=(0,l.forwardRef)((e,t)=>{let{className:r,label:l,typography:u="body2",...i}=e;return(0,n.jsxs)(o.k,{className:(0,c.f)("_10havsl0",r),children:[(0,n.jsx)("input",{className:"_10havsl1",ref:t,type:"checkbox",...i}),l&&(0,n.jsx)("label",{className:"".concat("_10havsl2"," ").concat(a.cp[u]),htmlFor:i.id,children:l})]})})},42073:function(e,t,r){"use strict";r.d(t,{B:function(){return l}});var n=r(85893),a=r(704),c=r(15080);r(2304),r(47002);let l=e=>{let{className:t,fieldError:r,message:l,typography:o="body2",...u}=e;return r&&(0,n.jsx)("p",{className:(0,c.f)("".concat("_1480szc0"," ").concat(a.cp[o]),t),...u,children:null!=l?l:r.message})}},87076:function(e,t,r){"use strict";r.d(t,{_:function(){return o}});var n=r(85893),a=r(704),c=r(15080),l=r(67421);r(2304),r(18338);let o=e=>{let{hideStatus:t,required:r,onChained:o,typography:u="title2",className:i,children:s,...d}=e,{t:v}=(0,l.$G)(),f=v("components.label.required");return o&&(f=v("components.label.required_not_edit")),(0,n.jsxs)("label",{className:(0,c.f)(a.cp[u],i),...d,children:[s,!t&&(r?(0,n.jsxs)("span",{className:"_12m4kve0",children:["ï¼",f,"ï¼"]}):(0,n.jsx)("span",{className:"_12m4kve1",children:v("components.label.not_required")}))]})}},9787:function(e,t,r){"use strict";r.d(t,{n:function(){return l}});var n=r(85893),a=r(15080),c=r(67294);r(2304),r(6456);let l=(0,c.forwardRef)((e,t)=>{let{className:r,...c}=e;return(0,n.jsx)("input",{ref:t,type:"text",...c,className:(0,a.f)("_14ft1kg0 _16e3s7l21",r)})})},16822:function(e,t,r){"use strict";r.r(t),r.d(t,{default:function(){return P}});var n=r(85893),a=r(80759),c=r(82695),l=r(59601),o=r(14413);r(2304),r(88509);var u=r(91825),i=r(31252),s=r(93033),d=r(11163);let v=()=>{var e,t,r;let n=(0,d.useRouter)(),{currentUser:a}=(0,i.x)(),{role:c}=(0,s.q)(),{data:l,isValidating:o}=(0,u.nJ)(null!==(r=null==a?void 0:null===(e=a.user)||void 0===e?void 0:e.selectedWalletAddress)&&void 0!==r?r:"",{swr:{enabled:!!(null==a?void 0:null===(t=a.user)||void 0===t?void 0:t.selectedWalletAddress),revalidateOnMount:!0}});return{role:c,router:n,currentUser:a,data:l,isValidating:o}};var f=r(99373),p=r(99361),h=r(42073),m=r(87076),_=r(9787),x=r(191),y=r(87536);r(99564);var b=r(98080),j=r(56312),N=r(1604),g=r(40979);let w=N.z.object({walletAddress:N.z.string(),creatorTypes:N.z.array(N.z.enum(g.y2)).min(1,"å°ãªãã¨ã1ã¤é¸æãã¦ãã ãã"),otherCreatorType:N.z.string().trim().max(256,b.q$("ãã®ä»",256)),tagName:N.z.string().optional()}),T=e=>{let{walletAddress:t,creatorTypes:r,tagName:n}=e,a=(0,g.aX)(r);return(0,y.cI)({defaultValues:{walletAddress:t,creatorTypes:r.map(e=>(0,g.Fe)(e)),otherCreatorType:null!=a?a:"",tagName:n},mode:"onSubmit",resolver:(0,j.F)(w)})},k=()=>(0,y.Gc)(),C=()=>{let{watch:e,register:t}=k(),r=e("creatorTypes").includes("other");return(0,n.jsx)(_.n,{disabled:!r,...t("otherCreatorType")})};var z=r(49901),E=r(67294),q=r(67421);let S=e=>({creatorType:e.creatorTypes.map(t=>"other"===t?e.otherCreatorType:t),tagName:e.tagName}),A=e=>{let{walletAddress:t,creatorTypes:r,tagName:n}=e,a=(0,d.useRouter)(),[c,l]=(0,E.useState)(!1),{refreshCurrentUser:o}=(0,i.x)(),{t:u}=(0,q.$G)(),s=T({walletAddress:t,creatorTypes:r,tagName:n});return{onSubmit:s.handleSubmit(async e=>{l(!0);let r=S(e);try{await (0,z.Kz)(t,r)}catch(e){l(!1);return}o(),a.replace("/setting/account")}),methods:s,isSending:c,t:u}},X=e=>{let{walletAddress:t,introduction:r,creatorTypes:l,tagName:o}=e,{methods:u,onSubmit:i,isSending:s,t:d}=A({walletAddress:t,introduction:r,creatorTypes:l,tagName:o}),{register:v,formState:{errors:b}}=u;return(0,n.jsx)(y.RV,{...u,children:(0,n.jsxs)(c.K,{className:"_1t5uhkw0",children:[(0,n.jsxs)(c.K,{className:"_1t5uhkw1",children:[(0,n.jsx)(m._,{required:!0,children:d("account.creator.edit.headline")}),(0,n.jsx)(x.Z,{variant:"caption2",children:d("account.creator.edit.allow_multiple_selection")}),g.TC.map(e=>(0,n.jsx)(p.X,{id:e.value,label:d(e.label),value:e.value,...v("creatorTypes")},e.value)),(0,n.jsx)(C,{}),(0,n.jsx)(h.B,{fieldError:b.creatorTypes}),(0,n.jsx)(h.B,{fieldError:b.otherCreatorType}),(0,n.jsx)(m._,{children:d("account.creator.edit.hash_tag")}),(0,n.jsx)(_.n,{...v("tagName")}
1),(0,n.jsx)(h.B,{fieldError:b.tagName})]}),(0,n.jsx)(f.z,{className:"_1t5uhkw2",colorTheme:"submit",typography:"title2",onClick:i,disabled:s,children:s?(0,n.jsx)(a.g,{}):d("account.creator.edit.register")})]})})};function P(){var e,t,r,o,u,i,s,d,f;let{role:p,router:h,currentUser:m,data:_,isValidating:x}=v();return(""===p&&h.push("/login"),"user"===p&&h.push("/account/creator/create"),x||!_)?(0,n.jsx)(a.g,{}):(0,n.jsxs)(c.K,{className:"_5hi3990",children:[(0,n.jsx)(l.P,{back:!0,avatar:!0}),(0,n.jsx)(X,{walletAddress:null!==(i=null==m?void 0:null===(t=m.user)||void 0===t?void 0:null===(e=t.selectedAccount)||void 0===e?void 0:e.walletAddress)&&void 0!==i?i:"",introduction:null!==(s=null===(r=_.result.creator)||void 0===r?void 0:r.introduction)&&void 0!==s?s:"",creatorTypes:null!==(d=null===(o=_.result.creator)||void 0===o?void 0:o.creatorType)&&void 0!==d?d:[],tagName:null!==(f=null===(u=_.result.creator)||void 0===u?void 0:u.tagName)&&void 0!==f?f:""})]})}P.getLayout=o.pY},40979:function(e,t,r){"use strict";r.d(t,{Fe:function(){return l},TC:function(){return c},aX:function(){return u},hQ:function(){return o},y2:function(){return a}});var n=r(36609);let a=["musician","illustrator","artist","videoStreamer","eventPlanner","influencer","other"],c=[{value:"musician",label:"account.creator.edit.creator_types.musician"},{value:"illustrator",label:"account.creator.edit.creator_types.illustrator"},{value:"artist",label:"account.creator.edit.creator_types.painter"},{value:"videoStreamer",label:"account.creator.edit.creator_types.video_uploader_streamer"},{value:"eventPlanner",label:"account.creator.edit.creator_types.eventer"},{value:"influencer",label:"account.creator.edit.creator_types.influencer"},{value:"other",label:"account.creator.edit.creator_types.other"}];function l(e){var t;return null!==(t=a.find(t=>t===e))&&void 0!==t?t:"other"}function o(e){var t;let r=null===(t=c.find(t=>t.value===e))||void 0===t?void 0:t.label;return r?(0,n.t)(r):e}function u(e){return e.find(e=>!a.find(t=>"other"!==t&&t===e))}},98080:function(e,t,r){"use strict";r.d(t,{_w:function(){return o},h5:function(){return a},q$:function(){return c},wq:function(){return l},xW:function(){return n}});let n=e=>"".concat(e,"ã¯å¿
é é
ç®ã§ã"),a=(e,t)=>"".concat(e,"ã¯").concat(t,"æå以ä¸ã§ã"),c=(e,t)=>"".concat(e,"ã¯").concat(t,"æå以ä¸ã§ã"),l=(e,t)=>"".concat(e,"ã¯").concat(t,"å以ä¸ã§ã"),o=(e,t)=>"".concat(e,"ã¯").concat(t,"å以ä¸ã§ã")},96391:function(){},47002:function(){},18338:function(){},6456:function(){},88509:function(){},99564:function(){}},function(e){e.O(0,[5675,2989,3760,3133,9601,1825,2888,9774,179],function(){return e(e.s=58337)}),_N_E=e.O()}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.