"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),r=require("react-virtualized"),t=require("@material-ui/core"),a=t.makeStyles({tableWrapper:{borderTop:"1px solid #5C5C5C",borderBottom:"1px solid #5C5C5C",width:"100%",height:"100%",overflow:"scroll"},table:{"& .ReactVirtualized__Table__headerRow":{textTransform:"none",border:"1px solid rgba(81, 81, 81, 1)"},"& .ReactVirtualized__Table__row":{border:"1px solid rgba(81, 81, 81, 1)"},"& .ReactVirtualized__Table__Grid":{outline:"none"},"& .ReactVirtualized__Table__headerColumn":{outline:"none"}},cell:{width:200}}),i=function(r){var t=r.cellData,i=a();return e.jsx("div",{className:i.cell,children:t})};exports.CsvViewer=function(t){var l=t.fileData,n=a(),o=Object.keys(l[0]||{});return e.jsx("div",{className:n.tableWrapper,children:e.jsx(r.AutoSizer,{children:function(t){var a=t.height;return t.width,function(t){var a=t.height;return e.jsx(r.Table,{className:n.table,width:200*(o.length||10),height:a,headerHeight:40,rowHeight:50,rowCount:l.length,rowGetter:function(e){var r=e.index;return l[r]},children:o.map((function(t){return e.jsx(r.Column,{width:200,flexGrow:1,dataKey:t,label:t,cellRenderer:function(r){var t=r.cellData;return e.jsx(i,{cellData:t})}},t)}))})}({height:a})}})})};
