"use client";
import { useForm } from "react-hook-form";

export interface IHeroStepFields {
  key: string;
  title: string;
  description: string;
  button_text: string;
  button_link: string;
}

const useHeroStepPresenter = () => {
  const {
    register,
    handleSubmit,
    formState: { errors },
  } = useForm<IHeroStepFields>();

  const onSubmit = (data: IHeroStepFields) => {
    console.log(data);
  };

  return {
    register,
    handleSubmit,
    errors,
    onSubmit,
  };
};

export default useHeroStepPresenter;
