diff --git a/src/components/Questionnaire/QuestionTypes/NotesInput.tsx b/src/components/Questionnaire/QuestionTypes/NotesInput.tsx index 10dfe08aa36..e6ec41120c0 100644 --- a/src/components/Questionnaire/QuestionTypes/NotesInput.tsx +++ b/src/components/Questionnaire/QuestionTypes/NotesInput.tsx @@ -1,8 +1,13 @@ import { useState } from "react"; -import CareIcon from "@/CAREUI/icons/CareIcon"; +import { cn } from "@/lib/utils"; import { Button } from "@/components/ui/button"; +import { + Popover, + PopoverContent, + PopoverTrigger, +} from "@/components/ui/popover"; import { Textarea } from "@/components/ui/textarea"; import type { QuestionnaireResponse } from "@/types/questionnaire/form"; @@ -11,48 +16,52 @@ interface NotesInputProps { questionnaireResponse: QuestionnaireResponse; updateQuestionnaireResponseCB: (response: QuestionnaireResponse) => void; disabled?: boolean; + className?: string; } export function NotesInput({ questionnaireResponse, updateQuestionnaireResponseCB, disabled, + className, }: NotesInputProps) { - const [showNotes, setShowNotes] = useState(false); + const [open, setOpen] = useState(false); const notes = questionnaireResponse.note || ""; const hasNotes = notes.length > 0; return ( -
- - {showNotes && ( -