diff --git a/rsconcept/frontend/src/components/Common/Modal.tsx b/rsconcept/frontend/src/components/Common/Modal.tsx index 404c0429..55a60ed5 100644 --- a/rsconcept/frontend/src/components/Common/Modal.tsx +++ b/rsconcept/frontend/src/components/Common/Modal.tsx @@ -6,6 +6,7 @@ import Button from './Button'; interface ModalProps { title?: string submitText?: string + submitInvalidTooltip?: string readonly?: boolean canSubmit?: boolean hideWindow: () => void @@ -14,7 +15,13 @@ interface ModalProps { children: React.ReactNode } -function Modal({ title, hideWindow, onSubmit, readonly, onCancel, canSubmit, children, submitText = 'Продолжить' }: ModalProps) { +function Modal({ + title, hideWindow, onSubmit, + readonly, onCancel, canSubmit, + submitInvalidTooltip, + children, + submitText = 'Продолжить' +}: ModalProps) { const ref = useRef(null); useEscapeKey(hideWindow); @@ -30,19 +37,20 @@ function Modal({ title, hideWindow, onSubmit, readonly, onCancel, canSubmit, chi return ( <> -
-
+
{ title &&

{title}

} -
+
{children}
- {!readonly &&