<script setup lang="ts">
const { login } = useAuthConnexion();
const fields = [
  {
    name: "username",
    type: "text" as const,
    label: "Courriel",
    placeholder: "Entrez votre courriel",
    required: true,
  },
  {
    name: "password",
    label: "Mot de passe",
    type: "password" as const,
    placeholder: "Entrez votre mot de passe",
    required: true,
  },
];
</script>

<template>
  <UAuthForm
    :schema="authLoginFormSchema"
    :fields="fields"
    title="Connexion"
    description="Veuillez vous identifier."
    loading-auto
    @submit="login"
  />
</template>
