Skip to content

Open source alternative to Semrush and Ahrefs

Let the modal overlay scroll when the card cannot shrink (#702)

Ben Senescuc6d56c52d64c
diff --git a/src/client/components/Modal.tsx b/src/client/components/Modal.tsx
index e6855fae..0a10d115 100644
--- a/src/client/components/Modal.tsx
+++ b/src/client/components/Modal.tsx
@@ -25,12 +25,12 @@ export function Modal({
}, [onClose]);
return (
- <div className="fixed inset-0 z-50 flex items-center justify-center bg-black/50 p-4">
+ <div className="fixed inset-0 z-50 flex justify-center overflow-y-auto bg-black/50 p-4">
<div
role="dialog"
aria-modal="true"
aria-labelledby={labelledBy}
- className={`card bg-base-100 border border-base-300 w-full ${maxWidth} max-h-full shadow-xl`}
+ className={`card bg-base-100 border border-base-300 m-auto w-full ${maxWidth} max-h-full shadow-xl`}
>
<div className="card-body gap-4 overflow-y-auto">{children}</div>
</div>