import { commonActions } from '@/redux/slices/Common/commonSlice';
import { AppDispatch } from '@/redux/store';
import { LRFFlowContent } from '@/src/types/StaticContent/lrfflow.content.type';
import Image from 'next/image';
import React from 'react';
import { useDispatch } from 'react-redux';
import CheckGif from '../../../../../public/images/check-gif.gif';

const ForgotPasswordSuccess: React.FC<{ CreateProfileContent: LRFFlowContent }> = ({ CreateProfileContent }) => {
    const dispatch = useDispatch<AppDispatch>();

    return (
        <>
            <div className='flex flex-col items-center justify-center'>
                <div
                    className={`w-full max-h-[calc(100vh-260px)] md:max-h-[calc(100vh-260px)] overflow-auto`}
                >
                    <Image
                        className="!w-[100px] !h-[100px] mx-auto mb-4"
                        width={100}
                        height={100}
                        src={CheckGif}
                        alt="profile-created"
                    />
                    <div className="text-center max-w-[450px] mx-auto">
                        <h4 className={`!text-center title !mb-2`}>
                            {CreateProfileContent.PROFILE_SUCCESS_RESET}
                        </h4>
                        {/* <p className={`!text-center fs-16 text-grey667Color`}>
                            Thank you for your submission. We have received your
                            information and will process it shortly. You will
                            receive a confirmation email within the next few
                            minutes.
                        </p> */}
                        <button onClick={() => dispatch(commonActions.setLRFFlow('login'))} className="SecondaryBtn w-full" type='button'>{CreateProfileContent.BACK_TO_LOGIN}</button>
                    </div>
                </div>
            </div>
        </>
    )
}

export default ForgotPasswordSuccess