(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6191],{47866:function(e,l,s){Promise.resolve().then(s.bind(s,58900))},58900:function(e,l,s){"use strict";s.r(l),s.d(l,{default:function(){return f}});var t=s(29362),n=s(27013),i=s(69755),a=s(57960),c=s(40929),r=s(42536),u=s(64971),d=s(24993),o=s(49267),p=s(48788);function f(){let e=(0,c.useRef)(null),l=(0,a.Z)(e),{data:s,isLoading:f,mutate:x}=(0,r.ZP)("/api/list?type=app",()=>(0,o.mE)({type:"app"})),h=()=>{x()};return(0,t.jsxs)("div",{className:"h-full flex flex-col",children:[(0,t.jsxs)("div",{className:(0,p.cn)("h-16 flex justify-between items-center px-6 border-b",(null==l?void 0:l.top)&&(null==l?void 0:l.top)>0?"border-default":"border-transparent"),children:[(0,t.jsx)(n.X6,{size:"h2",children:"App"}),(0,t.jsx)("div",{className:"flex gap-x-2",children:(0,t.jsx)(u.K,{onSuccess:h,type:"app"})})]}),(0,t.jsxs)("main",{className:"w-full h-full overflow-auto",ref:e,children:[f&&(0,t.jsx)("div",{className:"w-full h-full flex items-center justify-center",children:(0,t.jsx)(i.$,{className:"text-brand"})}),!f&&(null==s?void 0:s.data.length)?(0,t.jsx)("div",{className:"px-6 py-4 grid lg:grid-cols-3 large:grid-cols-4 2xl:grid-cols-5 gap-4 mb-6",children:null==s?void 0:s.data.map(e=>(0,t.jsx)(d.t,{type:"app",...e,onSuccess:h},e.id))}):null,!f&&!(null==s?void 0:s.data.length)&&(0,t.jsxs)("div",{className:"grow w-full h-full flex flex-col justify-center items-center",children:[(0,t.jsx)(n.X6,{size:"h2",children:"Create your first App"}),(0,t.jsx)(n.xv,{size:"sm",color:"subtle",className:"mt-1.5 mb-6",children:"Click button to create a app"}),(0,t.jsx)(u.K,{size:"lg",onSuccess:h,type:"app"})]})]})]})}s(71473)}},function(e){e.O(0,[8164,2798,2578,8708,7407,9006,2536,8707,1421,342,7992,6406,1744],function(){return e(e.s=47866)}),_N_E=e.O()}]);