diff --git a/src/components/Feedbacks/ButtonsOptions.tsx b/src/components/Feedbacks/ButtonsOptions.tsx index 9239850..9f5902b 100644 --- a/src/components/Feedbacks/ButtonsOptions.tsx +++ b/src/components/Feedbacks/ButtonsOptions.tsx @@ -40,11 +40,9 @@ export function ButtonsOptions({ const handleClick = (reasonValue: T) => { console.log('handleclick:', 'reasonValue:', reasonValue) if (reasons.includes(reasonValue)) { - // Remove the reason if already selected setReasons(reasons.filter((reason) => reason !== reasonValue)) } else { - // Set a single reason - setReasons([reasonValue]) + setReasons([...reasons, reasonValue]) } } @@ -79,7 +77,3 @@ export function ButtonsOptions({ ) } - -function isOtherReasonButton(reason: string) { - return reason.startsWith('tag-') -}