(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[671],{26998:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return I}});var r=t(66282),i=t.n(r),l=t(67971),a=t(69955),d=t(10919),o=t(84201),s=t(11754),c=t(86673),u=t(93506),f=t.n(u);function h(e){return e.children}h.propTypes={afterChildren:f().node,beforeChildren:f().node,children:f().node.isRequired,disabled:f().bool,label:f().string.isRequired};var b=t(22771),m=t(67996),x=t(93461),p=t(19711),j=t(31969),v=t(2005),g=t(49125),y=t(73942),C=t(16436),Z=m.default.div.withConfig({displayName:"Tabs__TabHeaderContainerStyle",componentId:"sc-rojme5-0"})(["",""],(function(e){return e.containerWidthPercentage&&"\n    width: ".concat(e.containerWidthPercentage,"%;\n  ")})),_=m.default.div.withConfig({displayName:"Tabs__TabHeader",componentId:"sc-rojme5-1"})(["border-top-left-radius:","px;border-top-right-radius:","px;margin-right:","px;position:relative;z-index:2;"," "," ",""],y.BG,y.BG,6*g.iI,(function(e){return e.noBottomBorder&&"\n    border-bottom: none;\n  "}),(function(e){return e.active&&"\n    border-bottom: ".concat(g.cd,"px solid;\n    border-color: ").concat((e.theme.interactive||j.Z.interactive).linkPrimary,";\n  ")}),(function(e){return e.fullWidth&&"\n    width: 100%;\n  "})),k=m.default.div.withConfig({displayName:"Tabs__LinkStyle",componentId:"sc-rojme5-2"})(["align-items:center;display:flex;"," "," ",""],(function(e){return e.bold&&"\n    font-family: ".concat(v.nF,";\n  ")}),(function(e){return e.fullWidth&&"\n    justify-content: center;\n  "}),(function(e){return!e.disabled&&"\n    &:hover {\n      path {\n        fill: ".concat((e.theme.content||j.Z.interactive).linkPrimary," !important;\n      }\n    }\n  ")}));var P=function(e){var n=e.actionEl,t=e.bold,r=e.children,i=e.containerWidthPercentage,a=e.currentTab,o=e.defaultKey,s=e.fullWidth,u=e.large,f=e.noBottomBorder,h=e.onChange,m=Array.isArray(r)?r.filter((function(e){return!!e})):[r],j=b.Children.map(m,(function(e){return e.key})),v=(0,b.useState)(o||j[0]),y=v[0],P=v[1],T=a||y;return(0,b.useEffect)((function(){P(o)}),[o]),(0,C.jsxs)(C.Fragment,{children:[(0,C.jsx)(Z,{containerWidthPercentage:i,children:(0,C.jsxs)(l.Z,{justifyContent:s?"center":null,children:[n&&(0,C.jsx)(x.Z,{flex:"1",children:n}),b.Children.map(m,(function(e){var n=e.key,r=e.props,i=T===n,l={default:!i,disabled:r.disabled,size:2*g.iI};return(0,C.jsx)(x.Z,{flex:s?"1":null,children:(0,C.jsx)(d.Z,{block:!0,default:!i,disabled:r.disabled,flex:1,large:u,noHoverUnderline:!0,noOutline:!0,onClick:function(){h&&h(n),P(n)},preventDefault:!0,sameColorAsText:i,children:(0,C.jsx)(_,{active:i,fullWidth:s,noBottomBorder:f,children:(0,C.jsxs)(k,{bold:t&&i,disabled:r.disabled,fullWidth:s,large:u,children:[r.beforeChildren&&b.cloneElement(r.beforeChildren,l),(0,C.jsx)(c.Z,{ml:r.beforeChildren?1:0,mr:r.afterChildren?1:0,children:(0,C.jsx)(p.ZP,{bold:t,large:u,children:r.label})}),r.afterChildren&&b.cloneElement(r.afterChildren,l)]})})})},n)}))]})}),m.filter((function(e){return e.key===T}))]})},T=t(50079),w=t(10512),W=["Bad","Worse","Worst"],B=function(e){return W.includes(e)},N=t(60254),E=t(28183),I=function(){var e=T.ZP.feature_sets.list().data,n=e?(0,E.YC)(e,(function(e){return e.id}),{ascending:!1}):[];return(0,C.jsx)(a.Z,{centerAlign:!0,header:(0,C.jsx)(c.Z,{mt:g.iI}),pageTitle:"Dataset Dashboard",children:(0,C.jsx)(P,{bold:!0,defaultKey:"datasets",large:!0,children:(0,C.jsx)(h,{label:"Datasets",children:(0,C.jsx)(c.Z,{pb:3,pt:3,children:(0,C.jsx)(s.Z,{headerDetails:(0,N._6)("dataset",null===n||void 0===n?void 0:n.length),headerTitle:"datasets",children:(null===n||void 0===n?void 0:n.length)>0?null===n||void 0===n?void 0:n.map((function(e,t){var r=e||{},a=r.id,s=r.metadata||{},u=s.column_types,f=void 0===u?{}:u,h=s.name,b=void 0===h?"dataset_".concat(a):h,m=s.statistics||{},x=m.count,j=m.quality,v=f?Object.keys(f).length:0;return(0,C.jsxs)(o.Z,{columnFlexNumbers:[4,1,1,1],last:t===n.length-1,children:[(0,C.jsxs)(l.Z,{alignItems:"center",children:[(0,C.jsx)(w.$B,{secondary:!0}),(0,C.jsx)(c.Z,{mr:1}),(0,C.jsx)(d.Z,{noHoverUnderline:!0,onClick:function(){return i().push("datasets/".concat(a))},preventDefault:!0,sameColorAsText:!0,children:b})]}),(0,C.jsxs)(p.ZP,{children:[v," features"]}),(0,C.jsxs)(p.ZP,{children:[x," rows"]}),(0,C.jsx)(p.ZP,{bold:B(j),danger:B(j),children:j})]},a)})):(0,C.jsx)(c.Z,{p:2,children:(0,C.jsx)(p.ZP,{children:"No datasets available. Add one to get started."})})})})},"datasets")})})}},11246:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/datasets",function(){return t(26998)}])}},function(e){e.O(0,[303,489,774,888,179],(function(){return n=11246,e(e.s=n);var n}));var n=e.O();_N_E=n}]);