(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[405],{79497:function(e,t,a){"use strict";var n=a(6355),l=a(11163),r=a(85893);t.Z=function(e){e.className;var t=e.title,a=e.description,s=e.icon,o=e.path,i=e.aosDelay,c=(0,l.useRouter)();return(0,r.jsxs)("div",{className:"rounded-md overflow-hidden p-6 md:p-8 bg-white border shadow-md cursor-pointer flex flex-col group transition-all duration-300 hover:shadow-lg",onClick:function(){return c.push("/musa/".concat(o))},"data-aos":"fade-up","data-aos-delay":i,children:[(0,r.jsx)(n.Z,{className:"w-20 mx-auto",src:s,alt:t}),(0,r.jsx)("h3",{className:"text-3xl font-medium mt-7 mb-4",children:t}),(0,r.jsx)("p",{className:"text-base text-black/60 text-left whitespace-pre-wrap",children:a})]})}},11761:function(e,t,a){"use strict";var n=a(6355),l=a(41664),r=a(11163),s=a(39489),o=a(12481),i=a(85893);t.Z=function(e){e.className;var t=e.title,a=e.cover,c=e.path,u=e.publish,d=e.aosDelay,h=(0,r.useRouter)(),m=(0,s.D1)(c);return(0,i.jsxs)("div",{className:"rounded-md overflow-hidden bg-white border shadow-md cursor-pointer flex flex-col group transition-all duration-300 hover:shadow-lg",onClick:function(){return m?window.open(c):h.push(c)},"data-aos":"fade-up","data-aos-delay":d,children:[(0,i.jsx)("div",{className:" aspect-[2/1]",children:(0,i.jsx)(n.Z,{className:"w-full h-full object-cover",src:a,alt:t})}),(0,i.jsxs)("div",{className:"p-6 md:p-8 flex flex-col h-full",children:[(0,i.jsx)("h3",{className:"text-xl font-medium mb-4 text-left",children:t}),(0,i.jsxs)("div",{className:"text-sm text-black/50 flex items-center justify-between mt-auto",children:[u&&(0,i.jsx)("time",{children:u.replace(" 00:00:00","")}),m?(0,i.jsx)("a",{href:c,target:"_blank",className:"ml-auto mt-auto flex items-center group transition-all duration-300 group-hover:text-primary",children:(0,i.jsx)("div",{className:"w-4 pt-0.5 ml-1.5 transition-transform duration-300 group-hover:translate-x-1",children:(0,i.jsx)(o.Z,{})})}):(0,i.jsx)(l.default,{href:c,children:(0,i.jsx)("a",{className:"ml-auto mt-auto flex items-center group transition-all duration-300 group-hover:text-primary",children:(0,i.jsx)("div",{className:"w-4 pt-0.5 ml-1.5 transition-transform duration-300 group-hover:translate-x-1",children:(0,i.jsx)(o.Z,{})})})})]})]})]})}},80436:function(e,t,a){"use strict";var n=a(6355),l=a(41664),r=a(11163),s=a(39489),o=a(85893);t.Z=function(e){e.className;var t=e.title,a=e.description,i=e.cover,c=e.path,u=e.aosDelay,d=(0,r.useRouter)(),h=(0,s.D1)(c);return(0,o.jsxs)("div",{className:"rounded-md overflow-hidden bg-white border shadow-md cursor-pointer flex flex-col group transition-all duration-300 hover:shadow-lg",onClick:function(){return h?window.open(c):d.push(c)},"data-aos":"fade-up","data-aos-delay":u,children:[h?(0,o.jsxs)("a",{href:c,target:"_blank",className:"aspect-video relative",children:[(0,o.jsx)(n.Z,{className:"w-full h-full object-cover",src:i,alt:t}),(0,o.jsx)(n.Z,{className:"absolute w-8 h-8 top-1/2 left-1/2 -translate-y-1/2 -translate-x-1/2",src:"/image/common/play.svg",alt:"play"})]}):(0,o.jsx)(l.default,{href:c,children:(0,o.jsxs)("a",{className:"aspect-video relative",children:[(0,o.jsx)(n.Z,{className:"w-full h-full object-cover",src:i,alt:t}),(0,o.jsx)(n.Z,{className:"absolute w-8 h-8 top-1/2 left-1/2 -translate-y-1/2 -translate-x-1/2",src:"/image/common/play.svg",alt:"play"})]})}),(0,o.jsxs)("div",{className:"p-6 md:p-8",children:[(0,o.jsx)("h3",{className:"text-2xl font-medium mb-4",children:t}),(0,o.jsx)("p",{className:"text-sm text-black/60 text-left whitespace-pre-wrap",children:a})]})]})}},8353:function(e,t,a){"use strict";a.r(t),a.d(t,{__N_SSP:function(){return b},default:function(){return N}});var n=a(30266),l=a(809),r=a.n(l),s=a(79497),o=a(11761),i=a(97365),c=a(80436),u=a(6355),d=a(85893),h=function(e){e.className;return(0,d.jsxs)("section",{className:"max-h-screen",children:[(0,d.jsx)(u.Z,{className:"w-full h-full object-cover hidden md:block",src:"/image/home/banner.jpg",alt:"banner"}),(0,d.jsx)(u.Z,{className:"w-full h-full object-cover block md:hidden",src:"/image/home/banner-mobile.jpg",alt:"banner"})]})},m=a(33005),g=a(94512),p=a(5152),x=a(67294),f=a(72335),v=function(e,t){return f.ZP.get("".concat(t||"","api/developer/category"),e)},w=function(e,t){return f.ZP.get("".concat(t||"","api/developer/tutorial"),e)},j=(0,p.default)((function(){return Promise.all([a.e(911),a.e(726),a.e(79),a.e(413),a.e(304),a.e(868),a.e(989),a.e(565),a.e(541)]).then(a.bind(a,5451))}),{ssr:!1,loadableGenerated:{webpack:function(){return[5451]},modules:["index.tsx -> components/Sdk/Markdown"]}}),b=!0;function N(e){var t=e.categoryTags,a=e.categorys,l=e.sdks,u=e.news,p=e.afterBannerContent,f=e.afterNewsContent,b=e.afterCategoryContent,N=e.afterTutorialContent,y=e.tutorialTags,Z=e.tutorials,k=(0,x.useState)(a),_=k[0],C=k[1],D=(0,x.useState)(""),S=D[0],T=D[1],I=function(){var e=(0,n.Z)(r().mark((function e(t){var a,n;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(S!=t.value&&t.value){e.next=8;break}return T(""),e.next=4,v({isCommon:!0},window.location.protocol+"//"+window.location.host+"/");case 4:a=e.sent.data.data,C(a),e.next=13;break;case 8:return T(t.value),e.next=11,v({tagId:t.value},window.location.protocol+"//"+window.location.host+"/");case 11:n=e.sent.data.data,C(n);case 13:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),P=(0,x.useState)(Z),E=P[0],R=P[1],K=(0,x.useState)(""),O=K[0],X=K[1],B=function(){var e=(0,n.Z)(r().mark((function e(t){var a,n;return r().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(O!=t.value&&t.value){e.next=8;break}return X(""),e.next=4,w({isCommon:!0},window.location.protocol+"//"+window.location.host+"/");case 4:a=e.sent.data.data,R(a),e.next=13;break;case 8:return X(t.value),e.next=11,w({tagId:t.value},window.location.protocol+"//"+window.location.host+"/");case 11:n=e.sent.data.data,R(n);case 13:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}();return(0,d.jsxs)(m.Z,{children:[(0,d.jsx)(h,{}),p.length>0&&p.map((function(e,t){return(0,d.jsx)(g.Z,{title:e.title,className:t%2==1?"bg-light-gray":"",children:(0,d.jsx)(j,{content:e.content})},t)})),u&&u.length>0&&(0,d.jsx)(g.Z,{className:p.length%2==1?"bg-light-gray":"",title:"\u65b0\u95fb",more:"/news",children:(0,d.jsx)("div",{className:"grid md:grid-cols-3 gap-4",children:u.map((function(e,t){return(0,d.jsx)(o.Z,{title:e.title,cover:e.cover,path:0==e.type?e.content:"/news/".concat(e.newsId),publish:e.publish,aosDelay:50*t},t)}))})}),f&&f.length>0&&f.map((function(e,t){return(0,d.jsx)(g.Z,{title:e.title,className:(p.length+(u&&u.length>0?1:0)+t)%2==1?"bg-light-gray":"",children:(0,d.jsx)(j,{content:e.content})},t)})),_&&_.length>0&&(0,d.jsx)(g.Z,{className:(p.length+(u&&u.length>0?1:0)+f.length)%2==1?"bg-light-gray":"",title:"\u5e38\u7528SDK",more:"/musa",tags:t.map((function(e){return{label:e.title,value:e.tagId}})),activeTag:S,changeTag:I,children:(0,d.jsx)("div",{className:"grid md:grid-cols-3 gap-4",children:_.map((function(e,t){return(0,d.jsx)(s.Z,{title:e.title,description:e.description,icon:e.icon,path:e.path,aosDelay:50*t},t)}))})}),b&&b.length>0&&b.map((function(e,t){return(0,d.jsx)(g.Z,{title:e.title,className:(p.length+(u&&u.length>0?1:0)+f.length+(a&&a.length>0?1:0)+t)%2==1?"bg-light-gray":"",children:(0,d.jsx)(j,{content:e.content})},t)})),E&&E.length>0&&(0,d.jsx)(g.Z,{className:(p.length+(u&&u.length>0?1:0)+f.length+(a&&a.length>0?1:0)+b.length)%2==1?"bg-light-gray":"",title:"\u8bfe\u7a0b",more:"/tutorial",tags:y.map((function(e){return{label:e.title,value:e.tagId}})),activeTag:O,changeTag:B,children:(0,d.jsx)("div",{className:"grid md:grid-cols-3 gap-4",children:E.map((function(e,t){return(0,d.jsx)(c.Z,{title:e.title,cover:e.cover,path:0==e.type?e.content:"/tutorial/".concat(e.tutorialId),description:e.description,aosDelay:50*t},t)}))})}),N&&N.length>0&&N.map((function(e,t){return(0,d.jsx)(g.Z,{title:e.title,className:(p.length+(u&&u.length>0?1:0)+f.length+(a&&a.length>0?1:0)+b.length+(E&&E.length>0?1:0)+t)%2==1?"bg-light-gray":"",children:(0,d.jsx)(j,{content:e.content})},t)})),l&&l.length>0&&(0,d.jsx)(g.Z,{className:"bg-light-gray",title:"SDK\u76ee\u5f55",children:(0,d.jsx)("div",{className:"grid md:grid-cols-4 gap-4",children:l.map((function(e,t){return(0,d.jsx)(i.Z,{title:e.title,description:e.description,tags:e.tags,path:e.link?e.link:"/sdk/".concat(e.path),aosDelay:50*t},t)}))})})]})}},45301:function(e,t,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/",function(){return a(8353)}])}},function(e){e.O(0,[774,593,888,179],(function(){return t=45301,e(e.s=t);var t}));var t=e.O();_N_E=t}]);