1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[692],{533:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/apps/submit",function(){return n(2742)}])},1312:function(e,t,n){"use strict";var i=n(8945),r=n(7790);let a=e=>{let t=e.status,n="Request error";switch(t){case 400:n="Request error";break;case 401:n="Unauthorized";break;case 403:n="Access denied";break;case 404:n="Resource not found";break;case 408:n="Request timeout";break;case 500:n="Internal server error";break;case 501:n="Service not implemented";break;case 502:n="Gateway error";break;case 503:n="Service is not available";break;case 504:n="Gateway timeout";break;case 505:n="HTTP version is not supported";break;default:n="Unknown error"}return n},l=i.Z.create({baseURL:"https://backend.kcc.network/api/v1",timeout:1e4});l.interceptors.request.use(async e=>e),l.interceptors.response.use(async e=>{if(200===e.status)return 500===e.data.code&&r.ZP.error(e.data.msg),Promise.resolve(e);{let t=a(e);return r.ZP.error(t),Promise.reject(Error(t))}},e=>{let t=e.message||"";if((null==e?void 0:e.message)&&(t=e.message),null==e?void 0:e.response){var n,i;console.log(null==e?void 0:e.response),t=null!==(i=e.response.data.message)&&void 0!==i?i:null===(n=e.response)||void 0===n?void 0:n.data}return(null==t?void 0:t.indexOf("timeout"))>=0&&(t="timeout"),r.ZP.error(t),Promise.reject(Error(t))}),t.Z=l},2337:function(e,t,n){"use strict";n.d(t,{p:function(){return r}});var i=n(1312);class r{static categoryList(){return(0,i.Z)({method:"get",url:"".concat(this.baseUrl,"/category?page=1&page_size=100")})}static dappList(e,t,n){let r="".concat(this.baseUrl,"?page=").concat(e,"&page_size=").concat(t);return n&&(r+="&category=".concat(n)),(0,i.Z)({method:"get",url:r})}static addApp(e){return(0,i.Z)({method:"post",url:"".concat(this.baseUrl,"/submit"),data:e})}}r.baseUrl="/dapp"},3509:function(e,t,n){"use strict";var i=n(7297),r=n(5893),a=n(7790),l=n(7294),o=n(4589),s=n(5233),c=n(1206);function d(){let e=(0,i.Z)([""]);return d=function(){return e},e}let u=o.ZP.div.withConfig({componentId:"sc-5f354d1c-0"})(d()),p=!1,m=e=>{let{setToken:t,token:n,refreshTag:i}=e,{t:o}=(0,s.$G)(),[d,m]=l.useState(-1),h=l.useCallback(()=>{if(c.C5){let e=window.document.getElementById("captcha");if(console.log("captchaId",d),!n&&e&&(null==window?void 0:window.grecaptcha)&&!p){var t;let i=null==window?void 0:null===(t=window.grecaptcha)||void 0===t?void 0:t.render("captcha",{sitekey:"6LeOBWgjAAAAABbXn2QM7GtdTu7ugAQwOJRPCuzG"});p=!0,m(()=>i)}}},[d,n]),g=l.useCallback(()=>{{let e=window.document.getElementById("captcha");e&&(null==window||window.grecaptcha.reset(d))}},[d]),f=l.useCallback(async()=>{var e;let n=null==window?void 0:null===(e=window.grecaptcha)||void 0===e?void 0:e.getResponse(d);n?(console.log("code",n),t(n)):(a.ZP.error(o("Invalid captcha")),g())},[d,g,t,o]);return l.useEffect(()=>{i>0&&f()},[f,i]),l.useEffect(()=>{c.C5&&h()},[h]),(0,r.jsx)(u,{children:(0,r.jsx)("div",{id:"captcha"})})};t.Z=m},9507:function(e,t,n){"use strict";var i=n(7297),r=n(5893),a=n(4589);n(7294);var l=n(888);function o(){let e=(0,i.Z)(["\n position: fixed;\n top: 0;\n left: 0;\n width: 100vw;\n height: 100vh;\n background: #21c397;\n z-index: 999;\n opacity: 1;\n display: ",";\n justify-content: center;\n align-items: center;\n"]);return o=function(){return e},e}let s=a.ZP.div.withConfig({componentId:"sc-14bc857e-0"})(o(),e=>{let{show:t}=e;return t?"flex":"none"}),c=e=>{let{show:t}=e;return(0,r.jsx)(s,{show:t,children:(0,r.jsx)(l.Z,{style:{fontSize:"36px",color:"#fff"}})})};t.Z=c},2742:function(e,t,n){"use strict";n.r(t),n.d(t,{__N_SSG:function(){return J},default:function(){return Y}});var i,r,a,l,o=n(7297),s=n(5893),c=n(289),d=n(2894),u=n(5537),p=n(1424),m=n(5403),h=n(78),g=n(543),f=n(1577),x=n(7294),b=n(4589),w=n(5233),j=n(2279),v=n(2337),Z=n(2490),k=n(9473);(i=a||(a={}))[i["New submission"]=0]="New submission",i[i["Update dApp information"]=1]="Update dApp information",(r=l||(l={}))[r.Live=0]="Live",r[r["Work in progress"]=1]="Work in progress";var y=n(4969),_=n(5675),C=n.n(_),I=n(3509),P=n(5157),R=n(7790);let E=(e,t,n)=>(console.log("file",e),new Promise(function(i){let r=new FileReader;r.onload=function(e){var r;let a=null===(r=e.target)||void 0===r?void 0:r.result,l=new Image;l.onload=function(){let e=l.width,r=l.height;e!==t||r!==n?i(!1):i(!0)},l.src=a}
1,r.readAsDataURL(null==e?void 0:e.originFileObj)})),U=e=>Number(e)/1024,L=e=>new Promise((t,n)=>{let i=new FileReader;i.readAsDataURL(null==e?void 0:e.originFileObj),i.onload=()=>t(i.result),i.onerror=e=>n(e)}),T=async(e,t)=>{let n=await E(e,t.width,t.height),i=U(1024);if(!n||!i)return R.ZP.error(null===w.ag||void 0===w.ag?void 0:w.ag.t("Unacceptable img size"),3),null;w.ag&&R.ZP.info(w.ag.t("Uploading"),0);let r=await L(e);return R.ZP.destroy(),w.ag&&R.ZP.success(w.ag.t("Upload success")),r};var A=n(1206);function S(){let e=(0,o.Z)(["\n width: 100%;\n height: 100%;\n background: #fff;\n"]);return S=function(){return e},e}function V(){let e=(0,o.Z)(["\n width: 540px;\n height: 100%;\n margin: 0 auto;\n margin-top: 80px;\n padding-top: 50px;\n padding-bottom: 100px;\n @media (max-width: 768px) {\n width: 100%;\n padding: 80px 24px 80px 24px;\n box-sizing: border-box;\n }\n"]);return V=function(){return e},e}function q(){let e=(0,o.Z)(["\n font-family: 'Poppins';\n font-style: normal;\n font-weight: 700;\n font-size: 36px;\n display: flex;\n align-items: center;\n color: #000;\n margin-bottom: 20px;\n"]);return q=function(){return e},e}function z(){let e=(0,o.Z)(["\n .ant-form-item {\n font-family: 'Poppins';\n font-size: 24px;\n font-weight: 500;\n }\n"]);return z=function(){return e},e}let{Option:F}=d.Z,N={name:"",request:a["New submission"],project_status:l.Live,
1website:"",category_ids:"",brief_introduction:"",detail_description:"",base64_image_content:"",smart_contract_address:"",token_symbol:"",project_email:"",token_contract_address:"",tvl_interface:"",github:"",twitter:"",telegram:"",coinmarketcap:"",coingecko:"",token:""},G=b.ZP.div.withConfig({componentId:"sc-61587791-0"})(S()),O=b.ZP.div.withConfig({componentId:"sc-61587791-1"})(V()),D=b.ZP.div.withConfig({componentId:"sc-61587791-2"})(q()),W=(0,b.ZP)(u.Z).withConfig({componentId:"sc-61587791-3"})(z()),B={labelCol:{span:24},wrapperCol:{span:24}},K=()=>{let{t:e}=(0,w.$G)(),{isMobile:t}=(0,P.F)(),[n]=u.Z.useForm(),[i,r]=x.useState([]),[o,c]=x.useState(!1),[b,_]=x.useState(""),[R,E]=x.useState(""),[U,S]=x.useState(0),[V,q]=x.useState(!1),z=x.useMemo(()=>({wrapperCol:{offset:t?0:8,span:t?24:16}}),[t]),K=x.useCallback(e=>{n.setFieldValue("token",e)},[n]),X=(0,j.u)(),M=(0,k.I0)();x.useEffect(()=>{async function e(){let e=await v.p.categoryList();M((0,Z.X)({list:e.data.data.list}))}X.length<1&&e()},[X,M]);let Q=x.useCallback(()=>{n.resetFields()},[n]),$=async e=>{var t;e.url||e.preview||(e.preview=await L(e)),_(e.url||e.preview),c(!0),E(null!==(t=e.originFileObj.name)&&void 0!==t?t:e.url)},H=()=>c(!1),J=(0,s.jsxs)("div",{children:[(0,s.jsx)(y.Z,{}),(0,s.jsx)("div",{style:{marginTop:8},children:e("Upload")})]}),Y=(0,s.jsxs)("div",{children:[(0,s.jsx)("span",{style:{marginRight:"10px"},children:e("Logo")}),(0,s.jsxs)("span",{style:{fontSize:"12px",color:"#737E8D"},children:[e("Image Size"),": 256*256px"]})]});return(0,s.jsx)(G,{children:(0,s.jsxs)(O,{children:[(0,s.jsx)(D,{children:e("Submit Project")}),(0,s.jsxs)(W,{...B,form:n,name:"control-hooks",disabled:!0,children:[(0,s.jsx)(u.Z.Item,{name:"name",label:e("Name"),rules:[{required:!0},{min:3,max:30}],initialValue:N.name,children:(0,s.jsx)(p.Z,{})}),(0,s.jsx)(u.Z.Item,{name:"request",label:e("Request Type"),rules:[{required:!0}],initialValue:N.request,children:(0,s.jsxs)(m.ZP.Group,{children:[(0,s.jsx)(m.ZP,{value:a["New submission"],children:e(a[0])}),(0,s.jsx)(m.ZP,{value:a["Update dApp information"],children:e(a[1])})]})}),(0,s.jsx)(u.Z.Item,{name:"project_status",label:e("Project Status"),rules:[{required:!0}],initialValue:N.project_status,children:(0,s.jsxs)(m.ZP.Group,{children:[(0,s.jsx)(m.ZP,{value:l.Live,children:e(l[0])}),(0,s.jsx)(m.ZP,{value:l["Work in progress"],children:e(l[1])})]})}),(0,s.jsx)(u.Z.Item,{name:"website",label:e("Website"),rules:[{required:!0}],initialValue:N.website,children:(0,s.jsx)(p.Z,{placeholder:e("Enter official website URL")})}),(0,s.jsx)(u.Z.Item,{name:"category_ids",label:e("Categories"),rules:[{required:!0}],children:(0,s.jsx)(d.Z,{mode:"multiple",children:X.map((e,t)=>(0,s.jsx)(F,{value:e.id,children:e.name},t))})}),(0,s.jsx)(u.Z.Item,{name:"brief_introduction",label:e("Brief Introduction"),rules:[{required:!0},{max:50}],initialValue:N.brief_introduction,children:(0,s.jsx)(p.Z.TextArea,{placeholder:e("One sentence description of the project"),rows:2})}),(0,s.jsx)(u.Z.Item,{name:"detail_description",label:e("Detail Description"),rules:[{max:500}],initialValue:N.detail_description,children:(0,s.jsx)(p.Z.TextArea,{placeholder:e("A detailed summary about your project"),rows:4})}),(0,s.jsx)(u.Z.Item,{name:"base64_image_content",label:Y,rules:[{required:!0}],children:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(h.Z,{listType:"picture-card",className:"avatar-uploader",showUploadList:!0,onPreview:$,customRequest(e){let t=e.file,i=new FileReader;i.readAsDataURL(t),i.onload=()=>{let e=i.result;n.setFieldValue("base64_image_content",e)}},onRemove(e){let t=i.indexOf(e),n=i.slice();n.splice(t,1),r(n)},accept:"image/*",fileList:i,async onChange(e){if(!e.fileList.length)return!1;let t=await T(e.file,{width:256,height:256});t?(n.setFieldValue("base64_image_content",t),r(()=>[{...e.file.originFileObj,url:t}])):r(()=>[])},children:i.length>0?null:J}),(0,s.jsx)(g.Z,{open:o,title:R,footer:null,onCancel:H,children:(0,s.jsx)(C(),{alt:"preview",width:256,height:256,src:b})})]})}),(0,s.jsx)(u.Z.Item,{name:"smart_contract_address",label:e("Contract Address"),initialValue:N.smart_contract_address,children:(0,s.jsx)(p.Z,{placeholder:e("Enter smart contract address")})}),(0,s.jsx)(u.Z.Item,{name:"token_symbol",label:e("Token Symbol"),initialValue:N.token_symbol,children:(0,s.jsx)(p.Z,{placeholder:e("Enter the Token Symbol")})}),(0,s.jsx)(u.Z.Item,{name:"project_email",label:e("Project Email"),rules:[{required:!0},{type:"email",min:6}],initialValue:N.project_email,children:(0,s.jsx)(p.Z,{placeholder:e("Enter the Email for contact")})}),(0,s.jsx)(u.Z.Item,{name:"token_contract_address",label:e("Token Contract Address"),initialValue:N.token_contract_address,children:(0,s.jsx)(p.Z,{placeholder:e("Enter the Token Contract Address")})}),(0,s.jsx)(u.Z.Item,{name:"tvl_interface",label:e("Tvl Interface"),rules:[{type:"url"}],initialValue:N.tvl_interface,children:(0,s.jsx)(p.Z,{placeholder:"e.g.: https://api.thegraph.com/subgraphs/name/uniswap/uniswap-v2"})}),(0,s.jsx)(u.Z.Item,{name:"github",label:e("Github"),rules:[{type:"url"}],initialValue:N.github,children:(0,s.jsx)(p.Z,{placeholder:"e.g.: https://github.com/kcc-community"})}),(0,s.jsx)(u.Z.Item,{name:"twitter",label:e("Twitter"),rules:[{type:"url"}],initialValue:N.twitter,children:(0,s.jsx)(p.Z,{placeholder:e("Enter project twitter URL")})}),(0,s.jsx)(u.Z.Item,{name:"telegram",label:e("Telegram"),rules:[{type:"url"}],initialValue:N.telegram,children:(0,s.jsx)(p.Z,{placeholder:e("Enter project telegram URL")})}),(0,s.jsx)(u.Z.Item,{name:"coinmarketcap",label:e("Coinmarketcap"),rules:[{type:"url"}],initialValue:N.coinmarketcap,children:(0,s.jsx)(p.Z,{placeholder:e("Enter project CoinMarketCap page URL")})}),(0,s.jsx)(u.Z.Item,{name:"coingecko",label:e("Coingecko"),rules:[{type:"url"}],initialValue:N.coingecko,children:(0,s.jsx)(p.Z,{placeholder:e("Enter project CoinGecko page URL")})}),(0,s.jsx)(u.Z.Item,{label:e("Google Captcha"),initialValue:N.token,children:A.C5&&(null==window?void 0:window.grecaptcha)&&(0,s.jsx)(I.Z,{token:n.getFieldValue("token"),setToken:K,refreshTag:U})}),(0,s.jsxs)(u.Z.Item,{...z,style:{width:"100%"},children:[(0,s.jsx)(f.Z,{type:"primary",htmlType:"submit",loading:V,size:"large",style:{marginRight:"20px",borderRadius:"24px",padding:"0 20px"},children:e("Submit")}),(0,s.jsx)(f.Z,{size:"large",htmlType:"button",onClick:Q,style:{borderRadius:"24px",padding:"0 20px"},children:e("Reset")})]})]})]})})};var X=n(9008),M=n.n(X),Q=n(9507);function $(){let e=(0,o.Z)(["\n padding-top: 0px;\n margin: 0;\n padding: 0;\n position: relative;\n background: #000;\n border: 1px solid #000;\n"]);return $=function(){return e},e}let H=b.ZP.div.withConfig({componentId:"sc-b06a15ca-0"})($());var J=!0;
1function Y(){let[e,t]=x.useState(!0);return x.useEffect(()=>{window.setTimeout(()=>{t(()=>!1)},500)},[]),(0,s.jsxs)(H,{children:[(0,s.jsxs)(M(),{children:[(0,s.jsx)("title",{children:"KCC Official AppsPage - KuCoin Community Chain"}),(0,s.jsx)("meta",{name:"description",content:"KCC is a high performance decentralized public chain built by the fans of KCS and KuCoin. We aim to provide community users with faster, more convenient and low-cost experience."})]}),e?(0,s.jsx)(Q.Z,{show:e}):(0,s.jsx)(K,{})]})}Y.getLayout=function(e){return(0,s.jsx)(c.Z,{children:e})}},2279:function(e,t,n){"use strict";n.d(t,{u:function(){return r}});var i=n(9473);function r(){return(0,i.v9)(e=>e.apps.appCategoryList)}}},function(e){e.O(0,[316,550,537,588,289,774,888,179],function(){return e(e.s=533)}),_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.