UNPKG

koval-ui

Version:

React components collection with minimalistic design. Supports theming, layout, and input validation.

1 lines 1.12 kB
{"version":3,"file":"ViewDateCell.cjs","sources":["../../../../../src/lib/DataTable/cells/ViewDateCell.tsx"],"sourcesContent":["import type {ComponentProps, FC} from 'react';\n\nimport {DateTime} from '@/lib/DateTime';\nimport type {Locale} from '@/internal/locale';\n\nimport classes from './Cells.module.css';\nimport type {CellComponent} from './../types.ts';\n\nexport type Props = ComponentProps<CellComponent>;\n\nexport const ViewDateCell: FC<Props> = ({value, cellContext, ...restProps}) => {\n const locale = cellContext.table.options.meta?.locale as Locale;\n return (\n <div className={classes.viewDateCell}>\n <DateTime {...restProps} value={String(value)} locale={locale} />\n </div>\n );\n};\n"],"names":["ViewDateCell","value","cellContext","restProps","locale","_a","jsx","classes","DateTime"],"mappings":"+MAUaA,EAA0B,CAAC,CAAC,MAAAC,EAAO,YAAAC,EAAa,GAAGC,KAAe,OAC3E,MAAMC,GAASC,EAAAH,EAAY,MAAM,QAAQ,OAA1B,YAAAG,EAAgC,OAC/C,OACKC,EAAAA,IAAA,MAAA,CAAI,UAAWC,EAAAA,QAAQ,aACpB,SAACD,EAAA,IAAAE,EAAA,SAAA,CAAU,GAAGL,EAAW,MAAO,OAAOF,CAAK,EAAG,OAAAG,CAAgB,CAAA,EACnE,CAER"}