import React, { useEffect, useRef, useState } from 'react'; import InputError from '@/Components/Defaults/InputError'; import InputLabel from '@/Components/Defaults/InputLabel'; import PrimaryButton from '@/Components/Defaults/PrimaryButton'; import TextInput from '@/Components/Defaults/TextInput'; import { Link, useForm, usePage } from '@inertiajs/react'; import { Transition } from '@headlessui/react'; export default function UpdateProfileInformation({ mustVerifyEmail, status, className }) { const user = usePage().props.auth.user; const { data, setData, patch, errors, processing, recentlySuccessful } = useForm({ username: user.username, email: user.email, }); const submit = (e) => { e.preventDefault(); patch(route('profile.update')); }; return (

Profile Information

Update your account's profile information and email address.

setData('username', e.target.value)} required autofocus autocomplete="name" />
setData('email', e.target.value)} required autocomplete="email" />
{mustVerifyEmail && user.email_verified_at === null && (

Your email address is unverified. Click here to re-send the verification email.

{status === 'verification-link-sent' && (
A new verification link has been sent to your email address.
)}
)}
Save

Saved.

); }