feat: Ajout de la gestion des fichier d'inscription [#1]

This commit is contained in:
Luc SORIGNET
2025-01-11 16:14:03 +01:00
parent fb5d485ce1
commit 3c27133cdb
16 changed files with 469 additions and 143 deletions

View File

@ -7,23 +7,26 @@ const Modal = ({ isOpen, setIsOpen, title, ContentComponent, size }) => {
<Dialog.Portal>
<Dialog.Overlay className="fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity" />
<Dialog.Content className="fixed inset-0 flex items-center justify-center">
<div className={`inline-block align-bottom bg-white rounded-lg px-4 pt-5 pb-4 text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-4xl sm:p-6 ${size ? size : 'sm:w-full' }`}>
<Dialog.Title className="text-lg font-medium text-gray-900">
{title}
</Dialog.Title>
<div className={`inline-block align-bottom bg-white rounded-lg px-4 pt-5 pb-4 text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-4xl sm:p-6 ${size ? size : 'sm:w-full' }`} style={{ minWidth: '300px', width: 'auto' }}>
<div className="flex justify-between items-start">
<Dialog.Title className="text-xl font-medium text-gray-900">
{title}
</Dialog.Title>
<Dialog.Close asChild>
<button
onClick={() => setIsOpen(false)}
className="text-gray-400 hover:text-gray-500 ml-4 focus:outline-none"
>
<span className="sr-only">Fermer</span>
<svg className="h-6 w-6" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor">
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M6 18L18 6M6 6l12 12" />
</svg>
</button>
</Dialog.Close>
</div>
<div className="mt-2">
<ContentComponent />
</div>
<div className="mt-4 flex justify-end space-x-4">
<Dialog.Close asChild>
<Button text="Fermer"
onClick={() => setIsOpen(false)}
className="px-4 py-2 rounded-md shadow-sm focus:outline-none bg-gray-300 text-gray-700 hover:bg-gray-400"
secondary
type="submit"
name="Create" />
</Dialog.Close>
</div>
</div>
</Dialog.Content>
</Dialog.Portal>