Skip to content

Commit

Permalink
line ordering
Browse files Browse the repository at this point in the history
  • Loading branch information
efekancakmak committed Feb 15, 2024
1 parent a9556e2 commit 30c9048
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/columns/isoDateColumn.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ IsoDateComponent.displayName = 'IsoDateComponent'
export const isoDateColumn: Partial<Column<string | null, any, string>> = {
component: IsoDateComponent as CellComponent<string | null, any>,
deleteValue: () => null,
// Because the Date constructor works using iso format, we can use it to parse ISO string back to a Date object
copyValue: ({ rowData }) => rowData,
// Because the Date constructor works using iso format, we can use it to parse ISO string back to a Date object
pasteValue: ({ value }) => {
const date = new Date(value.replace(/\.\s?|\//g, '-'))
return isNaN(date.getTime()) ? null : date.toISOString().substr(0, 10)
Expand Down

0 comments on commit 30c9048

Please sign in to comment.