small fixes
This commit is contained in:
@@ -21,11 +21,11 @@ const Modal = ({ open, onClose, title, subtitle, children, size = 'md' }) => {
|
||||
lg: 'max-w-4xl',
|
||||
};
|
||||
|
||||
// Note: clicking the backdrop does NOT close the modal anymore.
|
||||
// Use the X button or the Escape key instead. This avoids accidental
|
||||
// dismissal when the user is in the middle of editing settings.
|
||||
return (
|
||||
<div
|
||||
className="fixed inset-0 z-30 bg-gray-900/40 backdrop-blur-sm flex items-start justify-center p-4 sm:p-8 overflow-y-auto"
|
||||
onClick={(e) => { if (e.target === e.currentTarget) onClose(); }}
|
||||
>
|
||||
<div className="fixed inset-0 z-30 bg-gray-900/40 backdrop-blur-sm flex items-start justify-center p-4 sm:p-8 overflow-y-auto">
|
||||
<div className={`bg-white rounded-xl shadow-xl border border-gray-200 w-full ${widths[size]} my-8`}>
|
||||
<div className="flex items-start justify-between px-6 py-4 border-b border-gray-100">
|
||||
<div>
|
||||
@@ -36,6 +36,7 @@ const Modal = ({ open, onClose, title, subtitle, children, size = 'md' }) => {
|
||||
onClick={onClose}
|
||||
className="text-gray-400 hover:text-gray-700 p-1 rounded-lg hover:bg-gray-100 transition-colors"
|
||||
aria-label="Close"
|
||||
title="Close (Esc)"
|
||||
>
|
||||
<FiX className="w-5 h-5" />
|
||||
</button>
|
||||
@@ -46,4 +47,4 @@ const Modal = ({ open, onClose, title, subtitle, children, size = 'md' }) => {
|
||||
);
|
||||
};
|
||||
|
||||
export default Modal;
|
||||
export default Modal;
|
||||
Reference in New Issue
Block a user