{"version":3,"file":"export.cjs","names":["extendFeature","slotRender","TOOLBAR_EXTRAS","exportCsv","core","ExportCsvButton","options","props"],"sources":["../src/export.tsx"],"sourcesContent":["import {\n  extendFeature,\n  slotRender,\n  type TableFeature,\n  TOOLBAR_EXTRAS,\n} from \"@adapttable/react/adapter\";\nimport {\n  exportCsv as core,\n  type ExportCsvOptions,\n} from \"@adapttable/react/features\";\n\nimport { ExportCsvButton } from \"./components/toolbarExtras\";\n\n// The options type travels with the factory, as it does on every other kit.\nexport type { ExportCsvOptions };\n\n/**\n * CSV export of the current view, with MUI's own toolbar button.\n *\n * @public\n */\nexport function exportCsv<TRow>(\n  options: boolean | ExportCsvOptions<TRow> = true\n): TableFeature<TRow> {\n  return extendFeature(core(options), [\n    slotRender(TOOLBAR_EXTRAS, (props) => <ExportCsvButton {...props} />),\n  ]);\n}\n"],"mappings":";;;;;;;;;;;;AAqBA,SAAgBG,UACdG,UAA4C,MACxB;CACpB,QAAA,GAAON,0BAAAA,cAAAA,EAAAA,GAAcI,2BAAAA,UAAAA,CAAKE,OAAO,GAAG,EAAA,GAClCL,0BAAAA,WAAAA,CAAWC,0BAAAA,iBAAiBK,UAAU,iBAAA,GAAA,kBAAA,IAAA,CAAC,sBAAA,iBAAD,EAAiB,GAAIA,MAAM,CAAA,CAAG,CAAC,CACtE;AACH"}