itmpwk.ac.id/resources/js/pages/auth/confirm-password.tsx
Yoga Pangestu 5cc8ba26b2
Some checks failed
tests / ci (pull_request) Has been cancelled
feat: update user registration to use username instead of name, add user profile model and migration, and implement gender enum
- Changed user creation to use 'username' instead of 'name'.
- Added UserProfile model with relationships to User and gender enum.
- Updated validation rules for username and email.
- Modified migrations to create user_profiles table and adjust users table.
- Updated seeder to create users with profiles.
- Translated various UI texts to Indonesian and improved layout components.
2026-08-03 13:43:30 +07:00

52 lines
1.9 KiB
TypeScript

import { Form, Head } from '@inertiajs/react';
import InputError from '@/components/input-error';
import PasswordInput from '@/components/password-input';
import { Button } from '@/components/ui/button';
import { Label } from '@/components/ui/label';
import { Spinner } from '@/components/ui/spinner';
import { store } from '@/routes/password/confirm';
export default function ConfirmPassword() {
return (
<>
<Head title="Konfirmasi password" />
<Form {...store.form()} resetOnSuccess={['password']}>
{({ processing, errors }) => (
<div className="space-y-6">
<div className="grid gap-2">
<Label htmlFor="password">Password</Label>
<PasswordInput
id="password"
name="password"
placeholder="Password"
autoComplete="current-password"
autoFocus
/>
<InputError message={errors.password} />
</div>
<div className="flex items-center">
<Button
className="w-full"
disabled={processing}
data-test="confirm-password-button"
>
{processing && <Spinner />}
Konfirmasi password
</Button>
</div>
</div>
)}
</Form>
</>
);
}
ConfirmPassword.layout = {
title: 'Konfirmasi password',
description:
'Ini adalah area aman dari aplikasi. Silakan konfirmasi password Anda sebelum melanjutkan.',
};