diff --git a/README.md b/README.md index dc093b1..d0c3abc 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ Currently, there is no documentation or wiki available but there will be one add This will be published on the site some time soon but for now, the roadmap will be listed here. -- [ ] Finish adding started at date feature +- [x] Finish adding started at date field - [x] Pagination for Audit Logs page - [ ] Board sorting options (Boards Page) - [ ] Add real-time collaboration diff --git a/actions/update-card/index.ts b/actions/update-card/index.ts index f63b8d1..d2560dc 100644 --- a/actions/update-card/index.ts +++ b/actions/update-card/index.ts @@ -32,6 +32,7 @@ const handler = async (data: InputType): Promise => { data: { ...values, dueDate: dueDate, + startedAt: startedAt, }, }); diff --git a/app/(platform)/(dashboard)/board/[boardId]/_components/card-item.tsx b/app/(platform)/(dashboard)/board/[boardId]/_components/card-item.tsx index c8911f8..fc789d6 100644 --- a/app/(platform)/(dashboard)/board/[boardId]/_components/card-item.tsx +++ b/app/(platform)/(dashboard)/board/[boardId]/_components/card-item.tsx @@ -24,15 +24,21 @@ export const CardItem = ({ index, data }: CardItemProps) => { ref={provided.innerRef} role='button' onClick={() => cardModal.onOpen(data.id)} - className='truncate rounded-md border-2 border-transparent bg-white px-3 py-2 text-sm shadow-sm hover:border-black' + className='space-y-2 truncate rounded-md border-2 border-transparent bg-white px-3 py-2 text-sm shadow-sm hover:border-black' > {data.title} -
- - {data?.dueDate - ? 'Due: ' + format(data.dueDate, 'PP') - : 'No Due Date'} -
+ {data?.dueDate && ( +
+ + Due: {format(data.dueDate, 'PP')} +
+ )} + {data?.startedAt && ( +
+ + Started: {format(data.startedAt, 'PP')} +
+ )} )} diff --git a/components/modals/card-modal/actions.tsx b/components/modals/card-modal/actions.tsx index c6306b9..1384b41 100644 --- a/components/modals/card-modal/actions.tsx +++ b/components/modals/card-modal/actions.tsx @@ -80,6 +80,7 @@ export const Actions = ({ data }: ActionsProps) => { Copy { boardId={params.boardId as string} card={data} /> +