more
This commit is contained in:
@@ -23,9 +23,11 @@ const ConfirmModal = ({
|
||||
cancelButtonText,
|
||||
}) => {
|
||||
const [inputValue, setInputValue] = useState("");
|
||||
const [codeError, setCodeError] = useState("");
|
||||
const title = titleText ? titleText : "Confirmation";
|
||||
const handleConfirm = (code) => {
|
||||
if (!code) {
|
||||
setCodeError("Please enter a code");
|
||||
return;
|
||||
}
|
||||
onConfirm(code);
|
||||
@@ -70,6 +72,13 @@ const ConfirmModal = ({
|
||||
: "Description of issue"
|
||||
}
|
||||
/>
|
||||
<div className="confirm-error-box">
|
||||
{codeError ? (
|
||||
<p className="confirm-error-text">{codeError}</p>
|
||||
) : (
|
||||
<></>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
) : (
|
||||
<></>
|
||||
|
||||
@@ -34,7 +34,14 @@
|
||||
color: red;
|
||||
}
|
||||
}
|
||||
|
||||
.confirm-error-box {
|
||||
margin-top: -6px;
|
||||
}
|
||||
.confirm-error-text {
|
||||
font-size: 14px;
|
||||
color: red;
|
||||
margin-left: 12px;
|
||||
}
|
||||
.upload-header-bold {
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user