import Answers from "@/components/ChatsPath/components/Answers";
import { IAnswer } from "../../../data";
import { useNavigate } from "react-router-dom";
import routes from "@/routes";
import { useUpdateStep } from "@/components/ChatsPath/hooks/useUpdateStep";
import { useTranslations } from "@/hooks/translations";
import { ELocalesPlacement } from "@/locales";

function ParentStatus() {
  const { translate } = useTranslations(ELocalesPlacement.Chats);
  useUpdateStep(5);
  const navigate = useNavigate();

  const handleNext = () => {
    navigate(routes.client.chatsProfileIntro());
  };

  const answers: IAnswer[] = [
    {
      id: 1,
      value: "yes",
      name: translate("yes"),
      questionId: "parentStatus",
      onClick: handleNext,
    },
    {
      id: 2,
      value: "no",
      name: translate("no"),
      questionId: "parentStatus",
      onClick: handleNext,
    },
  ];

  return (
    <>
      <h2 className="chats-answers-title">
        {translate("/quiz/parentStatus.title")}
      </h2>
      <Answers answers={answers} />
    </>
  );
}

export default ParentStatus;
