tried fixing the layout of new CalDav integration

pull/453/head
Peer Richelsen 2021-08-15 13:10:01 +02:00
parent 3fbba351ab
commit a15d05be86
1 changed files with 19 additions and 39 deletions

View File

@ -236,45 +236,25 @@ export default function Home({ integrations }: Props) {
return ( return (
<Dialog open={isOpen}> <Dialog open={isOpen}>
<DialogContent> <DialogContent>
<div className="flex items-end justify-center min-h-screen pt-4 px-4 pb-20 text-center sm:block sm:p-0"> <DialogHeader
<div title="Connect to CalDav Server"
className="fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity" subtitle="Your credentials will be stored and encrypted."
aria-hidden="true"></div> />
<span className="hidden sm:inline-block sm:align-middle sm:h-screen" aria-hidden="true"> <div className="my-4">
&#8203; <AddCalDavIntegration
</span> ref={addCalDavIntegrationRef}
<div className="inline-block align-bottom bg-white rounded-sm px-4 pt-5 pb-4 text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-lg sm:w-full sm:p-6"> onSubmit={handleAddCalDavIntegrationSaveButtonPress}
<div className="sm:flex sm:items-start"> />
<div className="mx-auto flex-shrink-0 flex items-center justify-center h-12 w-12 rounded-full bg-neutral-100 sm:mx-0 sm:h-10 sm:w-10"> </div>
<PlusIcon className="h-6 w-6 text-neutral-900" /> <div className="mt-5 sm:mt-4 sm:flex sm:flex-row-reverse">
</div> <button
<div className="mt-3 text-center sm:mt-0 sm:ml-4 sm:text-left"> onClick={onSubmit}
<h3 className="text-lg leading-6 font-medium text-gray-900" id="modal-title"> className="flex justify-center py-2 px-4 border border-transparent rounded-sm shadow-sm text-sm font-medium text-white bg-neutral-900 hover:bg-neutral-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-neutral-900">
Connect to CalDav Server Save
</h3> </button>
<div> <DialogClose as="button" className="btn btn-white mx-2">
<p className="text-sm text-gray-400">Your credentials will be stored and encrypted.</p> Cancel
</div> </DialogClose>
</div>
</div>
<div className="my-4">
<AddCalDavIntegration
ref={addCalDavIntegrationRef}
onSubmit={handleAddCalDavIntegrationSaveButtonPress}
/>
</div>
<div className="mt-5 sm:mt-4 sm:flex sm:flex-row-reverse">
<button
onClick={onSubmit}
className="flex justify-center py-2 px-4 border border-transparent rounded-sm shadow-sm text-sm font-medium text-white bg-neutral-900 hover:bg-neutral-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-neutral-900">
Save
</button>
<DialogClose as="button" className="btn btn-white mx-2">
Cancel
</DialogClose>
</div>
</div>
</div> </div>
</DialogContent> </DialogContent>
</Dialog> </Dialog>