import { useState } from "react"; import { Box, Typography, FormControlLabel, Checkbox } from "@mui/material"; import { styled, useTheme } from "@mui/material/styles"; import SettingsIcon from '@mui/icons-material/Settings'; import { CheckBoxOutlineBlank, CheckBoxOutlined } from "@mui/icons-material"; import Modal from "../../../components/Modal/Modal"; import { PrimaryButton } from "../../../components/Button"; import { DecimalBigNumber } from "../../../helpers/DecimalBigNumber"; import { formatNumber } from "../../../helpers"; import { purchaseBond } from "../../../hooks/bonds"; import { claim } from "../../../hooks/staking"; const StyledBox = styled(Box, { shouldForwardProp: prop => prop !== "template", })(({ theme }) => { return { root: {}, }; }); const WarmupConfirmModal = ({ chainId, address, warmupLength, isOpen, handleConfirmClose, setPreClaimConfirmed }) => { const theme = useTheme(); const [isChecked, setIsChecked] = useState(false); const onSubmit = () => { setPreClaimConfirmed(); handleConfirmClose(); } return ( {warmupLength < 0 ? setIsChecked(event.target.checked)} icon={} checkedIcon={} /> } label={`I acknowledge that I am releasing warmup funds for the bonding contract on behalf of the collective.`} /> : `Bonding address is in a warm-up period and cannot be claimed now. It'll be available for claim in ${warmupLength} epochs.` } {warmupLength < 0 && Confirm } ); }; export default WarmupConfirmModal;