{"version":3,"file":"refine-ui27.cjs","sources":["../lib/components/Table/index.tsx"],"sourcesContent":["import * as React from 'react';\r\n\r\nimport { cn } from '@/lib/utils';\r\n\r\nconst Table = React.forwardRef<\r\n  HTMLTableElement,\r\n  React.HTMLAttributes<HTMLTableElement>\r\n>(({ className, ...props }, ref) => (\r\n  <div className='relative w-full overflow-auto'>\r\n    <table\r\n      ref={ref}\r\n      className={cn(\r\n        'w-full overflow-hidden rounded-xl border border-secondary text-sm shadow-sm',\r\n        className\r\n      )}\r\n      {...props}\r\n    />\r\n  </div>\r\n));\r\nTable.displayName = 'Table';\r\n\r\nconst TableHeader = React.forwardRef<\r\n  HTMLTableSectionElement,\r\n  React.HTMLAttributes<HTMLTableSectionElement>\r\n>(({ className, ...props }, ref) => (\r\n  <thead ref={ref} className={cn('bg-secondary', className)} {...props} />\r\n));\r\nTableHeader.displayName = 'TableHeader';\r\n\r\nconst TableBody = React.forwardRef<\r\n  HTMLTableSectionElement,\r\n  React.HTMLAttributes<HTMLTableSectionElement>\r\n>(({ className, ...props }, ref) => (\r\n  <tbody\r\n    ref={ref}\r\n    className={cn('[&_tr:last-child]:border-0', className)}\r\n    {...props}\r\n  />\r\n));\r\nTableBody.displayName = 'TableBody';\r\n\r\nconst TableFooter = React.forwardRef<\r\n  HTMLTableSectionElement,\r\n  React.HTMLAttributes<HTMLTableSectionElement>\r\n>(({ className, ...props }, ref) => (\r\n  <tfoot\r\n    ref={ref}\r\n    className={cn('border-t font-medium [&>tr]:last:border-b-0', className)}\r\n    {...props}\r\n  />\r\n));\r\nTableFooter.displayName = 'TableFooter';\r\n\r\nconst TableRow = React.forwardRef<\r\n  HTMLTableRowElement,\r\n  React.HTMLAttributes<HTMLTableRowElement>\r\n>(({ className, ...props }, ref) => (\r\n  <tr\r\n    ref={ref}\r\n    className={cn(\r\n      'data-[state=selected]:bg-muted border-b border-secondary transition-colors',\r\n      className\r\n    )}\r\n    {...props}\r\n  />\r\n));\r\nTableRow.displayName = 'TableRow';\r\n\r\nconst TableHead = React.forwardRef<\r\n  HTMLTableCellElement,\r\n  React.ThHTMLAttributes<HTMLTableCellElement>\r\n>(({ className, ...props }, ref) => (\r\n  <th\r\n    ref={ref}\r\n    className={cn(\r\n      'px-3xl py-lg text-start text-xs font-medium text-tertiary [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]',\r\n      className\r\n    )}\r\n    {...props}\r\n  />\r\n));\r\nTableHead.displayName = 'TableHead';\r\n\r\nconst TableCell = React.forwardRef<\r\n  HTMLTableCellElement,\r\n  React.TdHTMLAttributes<HTMLTableCellElement>\r\n>(({ className, ...props }, ref) => (\r\n  <td\r\n    ref={ref}\r\n    className={cn(\r\n      'border-none px-3xl py-xl text-start text-xs [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]',\r\n      className\r\n    )}\r\n    {...props}\r\n  />\r\n));\r\nTableCell.displayName = 'TableCell';\r\n\r\nconst TableCaption = React.forwardRef<\r\n  HTMLTableCaptionElement,\r\n  React.HTMLAttributes<HTMLTableCaptionElement>\r\n>(({ className, ...props }, ref) => (\r\n  <caption\r\n    ref={ref}\r\n    className={cn('text-muted-foreground mt-4 text-sm', className)}\r\n    {...props}\r\n  />\r\n));\r\nTableCaption.displayName = 'TableCaption';\r\n\r\nexport {\r\n  Table,\r\n  TableHeader,\r\n  TableBody,\r\n  TableFooter,\r\n  TableHead,\r\n  TableRow,\r\n  TableCell,\r\n  TableCaption,\r\n};\r\n"],"names":["Table","React","className","props","ref","cn","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption"],"mappings":"kaAIMA,EAAQC,EAAM,WAGlB,CAAC,CAAE,UAAAC,EAAW,GAAGC,GAASC,IACzBH,EAAA,cAAA,MAAA,CAAI,UAAU,+BACb,EAAAA,EAAA,cAAC,QAAA,CACC,IAAAG,EACA,UAAWC,EAAA,GACT,8EACAH,CACF,EACC,GAAGC,CAAA,CACN,CACF,CACD,EACDH,EAAM,YAAc,Q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