import {useState} from 'react';

const useLogin = navigation => {
  const [email, setEmail] = useState('');
  const [password, setPassword] = useState('');
  const [isPasswordVisible, setIsPasswordVisible] = useState(false);
  const [loading, setLoading] = useState(false);
  const [modalOTP, setModalOTP] = useState({visible: false, loading: false});
  const [otpCode, setOTPCode] = useState('');
  const [error, setError] = useState({});
  const [modalLanguage, setModalLanguage] = useState(false);
  const [modal, setModal] = useState({
    visible: false,
    message: '',
  });

  return {
    email,
    setEmail,
    password,
    setPassword,
    isPasswordVisible,
    setIsPasswordVisible,
    modalOTP,
    setModalOTP,
    otpCode,
    setOTPCode,
    loading,
    error,
    modal,
    setModal,
    setModalLanguage,
    modalLanguage,
  };
};
export default useLogin;
