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 RelationshipStatus() {
  const { translate } = useTranslations(ELocalesPlacement.Chats);
  useUpdateStep(3);
  const navigate = useNavigate();

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

  const answers: IAnswer[] = [
    {
      id: 1,
      value: "single",
      name: translate("/quiz/relationshipStatus.answer_1"),
      questionId: "relationshipStatus",
      onClick: handleNext,
    },
    {
      id: 2,
      value: "relationship",
      name: translate("/quiz/relationshipStatus.answer_2"),
      questionId: "relationshipStatus",
      onClick: handleNext,
    },
    {
      id: 3,
      value: "married",
      name: translate("/quiz/relationshipStatus.answer_3"),
      questionId: "relationshipStatus",
      onClick: handleNext,
    },
    {
      id: 4,
      value: "complicated",
      name: translate("/quiz/relationshipStatus.answer_4"),
      questionId: "relationshipStatus",
      onClick: handleNext,
    },
    {
      id: 5,
      value: "other",
      name: translate("/quiz/relationshipStatus.answer_5"),
      questionId: "relationshipStatus",
      onClick: handleNext,
    },
  ];

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

export default RelationshipStatus;
