diff --git a/striker-ui/hooks/useChecklist.tsx b/striker-ui/hooks/useChecklist.tsx index b8938768..c30cef71 100644 --- a/striker-ui/hooks/useChecklist.tsx +++ b/striker-ui/hooks/useChecklist.tsx @@ -36,11 +36,19 @@ const useChecklist = ({ confirmDialogProps = {}, formSummaryProps = {}, getConfirmDialogTitle, + onProceedAppend, + renderEntry, }) => ({ actionProceedText: 'Delete', content: ( - + ), + onProceedAppend, proceedColour: 'red', titleText: getConfirmDialogTitle(checks.length), ...confirmDialogProps, diff --git a/striker-ui/types/Checklist.d.ts b/striker-ui/types/Checklist.d.ts index 5e5a0f13..e0474620 100644 --- a/striker-ui/types/Checklist.d.ts +++ b/striker-ui/types/Checklist.d.ts @@ -2,11 +2,14 @@ type Checklist = Record; type ArrayChecklist = (keyof Checklist)[]; -type BuildDeleteDialogPropsFunction = (args: { - confirmDialogProps?: Partial>; - formSummaryProps?: Omit, 'entries'>; - getConfirmDialogTitle: (length: number) => ReactNode; -}) => ConfirmDialogProps; +type BuildDeleteDialogPropsFunction = ( + args: { + confirmDialogProps?: Partial>; + formSummaryProps?: Omit, 'entries'>; + getConfirmDialogTitle: (length: number) => ReactNode; + } & Pick & + Pick, 'renderEntry'>, +) => ConfirmDialogProps; type GetCheckFunction = (key: string) => boolean;