import { Box, Stack, Text, useColorModeValue } from "@chakra-ui/react"; import { useState } from "react"; import { MessageTable } from "src/components/Messages/MessageTable"; import { TrackedTextarea } from "src/components/Survey/TrackedTextarea"; import { TwoColumnsWithCards } from "src/components/Survey/TwoColumnsWithCards"; import { TaskSurveyProps } from "src/components/Tasks/Task"; export const CreateTask = ({ task, taskType, isDisabled, onReplyChanged }: TaskSurveyProps<{ text: string }>) => { const cardColor = useColorModeValue("gray.100", "gray.700"); const titleColor = useColorModeValue("gray.800", "gray.300"); const labelColor = useColorModeValue("gray.600", "gray.400"); const [inputText, setInputText] = useState(""); const textChangeHandler = (event: React.ChangeEvent) => { const text = event.target.value; onReplyChanged({ content: { text }, state: "VALID" }); setInputText(text); }; return (
<> {taskType.label} {taskType.overview} {task.conversation ? ( ) : null} <> {taskType.instruction}
); };