diff --git a/resources/js/react/pages/Login.tsx b/resources/js/react/pages/Login.tsx
index 6e84633..fc63613 100644
--- a/resources/js/react/pages/Login.tsx
+++ b/resources/js/react/pages/Login.tsx
@@ -124,7 +124,7 @@ export default function Login() {
{route().has('password.request') && (
{t('Forgot your password?')}
@@ -145,7 +145,7 @@ export default function Login() {
{(page.props.auth as any)?.magic_link_enabled && (
{t('Login with magic link')}
diff --git a/resources/js/react/pages/Register.tsx b/resources/js/react/pages/Register.tsx
index 6579862..6612f6b 100644
--- a/resources/js/react/pages/Register.tsx
+++ b/resources/js/react/pages/Register.tsx
@@ -1,5 +1,6 @@
import { Button } from '@/components/ui/button';
-import { Field, FieldError } from '@/components/ui/field';
+import { Checkbox } from '@/components/ui/checkbox';
+import { Field, FieldError, FieldLabel } from '@/components/ui/field';
import { Input } from '@/components/ui/input';
import { Label } from '@/components/ui/label';
import { useT } from '@/i18n';
@@ -17,6 +18,7 @@ export default function Register() {
email: '',
password: '',
password_confirmation: '',
+ terms: false,
});
const handleSubmit = (e: React.FormEvent) => {
@@ -24,6 +26,12 @@ export default function Register() {
post(route('register'), { preserveScroll: true });
};
+ const canSubmit =
+ data.name.trim() !== '' &&
+ data.email.trim() !== '' &&
+ data.password !== '' &&
+ data.terms;
+
return (
+
+
+ setData('terms', !!checked)
+ }
+ aria-invalid={!!errors.terms}
+ />
+
+ {t('I agree to the')}{' '}
+
+ {t('Terms of Service')}
+ {' '}
+ {t('and the')}{' '}
+
+ {t('Privacy Policy')}
+
+
+
+ {errors.terms && (
+
+ {errors.terms}
+
+ )}
+